@bimdata/viewer 2.15.0-beta.6 → 2.15.0-beta.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1381,7 +1381,7 @@ Fragment shader:
1381
1381
  } catch (error) {
1382
1382
  console.error(error);
1383
1383
  throw error;
1384
- }`}function GX(t,e=!0,i){const o=i||new Set;if(t){if(KX(t))o.add(t);else if(KX(t.buffer))o.add(t.buffer);else if(!ArrayBuffer.isView(t)&&e&&typeof t=="object")for(const n in t)GX(t[n],e,o)}return i===void 0?Array.from(o):[]}function KX(t){return t?t instanceof ArrayBuffer||typeof MessagePort<"u"&&t instanceof MessagePort||typeof ImageBitmap<"u"&&t instanceof ImageBitmap||typeof OffscreenCanvas<"u"&&t instanceof OffscreenCanvas:!1}const LI=()=>{};class _I{name;source;url;terminated=!1;worker;onMessage;onError;_loadableURL="";static isSupported(){return typeof Worker<"u"&&qa||typeof DI<"u"&&!qa}constructor(e){const{name:i,source:o,url:n}=e;Ac(o||n),this.name=i,this.source=o,this.url=n,this.onMessage=LI,this.onError=r=>console.log(r),this.worker=qa?this._createBrowserWorker():this._createNodeWorker()}destroy(){this.onMessage=LI,this.onError=LI,this.worker.terminate(),this.terminated=!0}get isRunning(){return!!this.onMessage}postMessage(e,i){i=i||GX(e),this.worker.postMessage(e,i)}_getErrorFromErrorEvent(e){let i="Failed to load ";return i+=`worker ${this.name} from ${this.url}. `,e.message&&(i+=`${e.message} in `),e.lineno&&(i+=`:${e.lineno}:${e.colno}`),new Error(i)}_createBrowserWorker(){this._loadableURL=LPt({source:this.source,url:this.url});const e=new Worker(this._loadableURL,{name:this.name});return e.onmessage=i=>{i.data?this.onMessage(i.data):this.onError(new Error("No data received"))},e.onerror=i=>{this.onError(this._getErrorFromErrorEvent(i)),this.terminated=!0},e.onmessageerror=i=>console.error(i),e}_createNodeWorker(){let e;if(this.url){const i=this.url.includes(":/")||this.url.startsWith("/")?this.url:`./${this.url}`;e=new DI(i,{eval:!1})}else if(this.source)e=new DI(this.source,{eval:!0});else throw new Error("no worker");return e.on("message",i=>{this.onMessage(i)}),e.on("error",i=>{this.onError(i)}),e.on("exit",i=>{}),e}}class OPt{name="unnamed";source;url;maxConcurrency=1;maxMobileConcurrency=1;onDebug=()=>{};reuseWorkers=!0;props={};jobQueue=[];idleQueue=[];count=0;isDestroyed=!1;static isSupported(){return _I.isSupported()}constructor(e){this.source=e.source,this.url=e.url,this.setProps(e)}destroy(){this.idleQueue.forEach(e=>e.destroy()),this.isDestroyed=!0}setProps(e){this.props={...this.props,...e},e.name!==void 0&&(this.name=e.name),e.maxConcurrency!==void 0&&(this.maxConcurrency=e.maxConcurrency),e.maxMobileConcurrency!==void 0&&(this.maxMobileConcurrency=e.maxMobileConcurrency),e.reuseWorkers!==void 0&&(this.reuseWorkers=e.reuseWorkers),e.onDebug!==void 0&&(this.onDebug=e.onDebug)}async startJob(e,i=(n,r,a)=>n.done(a),o=(n,r)=>n.error(r)){const n=new Promise(r=>(this.jobQueue.push({name:e,onMessage:i,onError:o,onStart:r}),this));return this._startQueuedJob(),await n}async _startQueuedJob(){if(!this.jobQueue.length)return;const e=this._getAvailableWorker();if(!e)return;const i=this.jobQueue.shift();if(i){this.onDebug({message:"Starting job",name:i.name,workerThread:e,backlog:this.jobQueue.length});const o=new RPt(i.name,e);e.onMessage=n=>i.onMessage(o,n.type,n.payload),e.onError=n=>i.onError(o,n),i.onStart(o);try{await o.result}catch(n){console.error(`Worker exception: ${n}`)}finally{this.returnWorkerToQueue(e)}}}returnWorkerToQueue(e){!qa||this.isDestroyed||!this.reuseWorkers||this.count>this._getMaxConcurrency()?(e.destroy(),this.count--):this.idleQueue.push(e),this.isDestroyed||this._startQueuedJob()}_getAvailableWorker(){if(this.idleQueue.length>0)return this.idleQueue.shift()||null;if(this.count<this._getMaxConcurrency()){this.count++;const e=`${this.name.toLowerCase()} (#${this.count} of ${this.maxConcurrency})`;return new _I({name:e,source:this.source,url:this.url})}return null}_getMaxConcurrency(){return DPt?this.maxMobileConcurrency:this.maxConcurrency}}const UPt={maxConcurrency:3,maxMobileConcurrency:1,reuseWorkers:!0,onDebug:()=>{}};class hu{props;workerPools=new Map;static _workerFarm;static isSupported(){return _I.isSupported()}static getWorkerFarm(e={}){return hu._workerFarm=hu._workerFarm||new hu({}),hu._workerFarm.setProps(e),hu._workerFarm}constructor(e){this.props={...UPt},this.setProps(e),this.workerPools=new Map}destroy(){for(const e of this.workerPools.values())e.destroy();this.workerPools=new Map}setProps(e){this.props={...this.props,...e};for(const i of this.workerPools.values())i.setProps(this._getWorkerPoolProps())}getWorkerPool(e){const{name:i,source:o,url:n}=e;let r=this.workerPools.get(i);return r||(r=new OPt({name:i,source:o,url:n}),r.setProps(this._getWorkerPoolProps()),this.workerPools.set(i,r)),r}_getWorkerPoolProps(){return{maxConcurrency:this.props.maxConcurrency,maxMobileConcurrency:this.props.maxMobileConcurrency,reuseWorkers:this.props.reuseWorkers,onDebug:this.props.onDebug}}}function NPt(t,e={}){const i=e[t.id]||{},o=qa?`${t.id}-worker.js`:`${t.id}-worker-node.js`;let n=i.workerUrl;if(!n&&t.id==="compression"&&(n=e.workerUrl),e._workerType==="test"&&(qa?n=`modules/${t.module}/dist/${o}`:n=`modules/${t.module}/src/workers/${t.id}-worker-node.ts`),!n){let r=t.version;r==="latest"&&(r=SPt);const a=r?`@${r}`:"";n=`https://unpkg.com/@loaders.gl/${t.module}${a}/dist/${o}`}return Ac(n),n}function jPt(t,e=zX){Ac(t,"no worker provided");const i=t.version;return!(!e||!i)}const FI={};async function vh(t,e=null,i={},o=null){return e&&(t=VPt(t,e,i,o)),FI[t]=FI[t]||HPt(t),await FI[t]}function VPt(t,e,i={},o=null){if(!i.useLocalLibraries&&t.startsWith("http"))return t;o=o||t;const n=i.modules||{};return n[o]?n[o]:qa?i.CDN?(Ac(i.CDN.startsWith("http")),`${i.CDN}/${e}@${zX}/dist/libs/${o}`):TI?`../src/libs/${o}`:`modules/${e}/src/libs/${o}`:`modules/${e}/dist/libs/${o}`}async function HPt(t){if(t.endsWith("wasm"))return await qPt(t);if(!qa)try{const{requireFromFile:i}=globalThis.loaders||{};return await i?.(t)}catch(i){return console.error(i),null}if(TI)return importScripts(t);const e=await QPt(t);return zPt(e,t)}function zPt(t,e){if(!qa){const{requireFromString:o}=globalThis.loaders||{};return o?.(t,e)}if(TI)return eval.call(globalThis,t),null;const i=document.createElement("script");i.id=e;try{i.appendChild(document.createTextNode(t))}catch{i.text=t}return document.body.appendChild(i),null}async function qPt(t){const{readFileAsArrayBuffer:e}=globalThis.loaders||{};return qa||!e||t.startsWith("http")?await(await fetch(t)).arrayBuffer():await e(t)}async function QPt(t){const{readFileAsText:e}=globalThis.loaders||{};return qa||!e||t.startsWith("http")?await(await fetch(t)).text():await e(t)}function GPt(t,e){return!hu.isSupported()||!qa&&!e?._nodeWorkers?!1:t.worker&&e?.worker}async function KPt(t,e,i,o,n){const r=t.id,a=NPt(t,i),s=hu.getWorkerFarm(i).getWorkerPool({name:r,url:a});i=JSON.parse(JSON.stringify(i)),o=JSON.parse(JSON.stringify(o||{}));const l=await s.startJob("process-on-worker",JPt.bind(null,n));return l.postMessage("process",{input:e,options:i,context:o}),await(await l.result).result}async function JPt(t,e,i,o){switch(i){case"done":e.done(o);break;case"error":e.error(new Error(o.error));break;case"process":const{id:n,input:r,options:a}=o;try{const s=await t(r,a);e.postMessage("done",{id:n,result:s})}catch(s){const l=s instanceof Error?s.message:"unknown error";e.postMessage("error",{id:n,error:l})}break;default:console.warn(`parse-with-worker unknown message ${i}`)}}function ZPt(t,e=5){return typeof t=="string"?t.slice(0,e):ArrayBuffer.isView(t)?JX(t.buffer,t.byteOffset,e):t instanceof ArrayBuffer?JX(t,0,e):""}function JX(t,e,i){if(t.byteLength<=e+i)return"";const o=new DataView(t);let n="";for(let r=0;r<i;r++)n+=String.fromCharCode(o.getUint8(e+r));return n}function WPt(t){try{return JSON.parse(t)}catch{throw new Error(`Failed to parse JSON from data starting with "${ZPt(t)}"`)}}function YPt(t,e,i){if(i=i||t.byteLength,t.byteLength<i||e.byteLength<i)return!1;const o=new Uint8Array(t),n=new Uint8Array(e);for(let r=0;r<o.length;++r)if(o[r]!==n[r])return!1;return!0}function XPt(...t){return $Pt(t)}function $Pt(t){const e=t.map(r=>r instanceof ArrayBuffer?new Uint8Array(r):r),i=e.reduce((r,a)=>r+a.byteLength,0),o=new Uint8Array(i);let n=0;for(const r of e)o.set(r,n),n+=r.byteLength;return o.buffer}function ZX(t,e,i){const o=i!==void 0?new Uint8Array(t).subarray(e,e+i):new Uint8Array(t).subarray(e);return new Uint8Array(o).buffer}function I3(t,e){return fc(t>=0),fc(e>0),t+(e-1)&-4}function eIt(t,e,i){let o;if(t instanceof ArrayBuffer)o=new Uint8Array(t);else{const n=t.byteOffset,r=t.byteLength;o=new Uint8Array(t.buffer||t.arrayBuffer,n,r)}return e.set(o,i),i+I3(o.byteLength,4)}async function tIt(t){const e=[];for await(const i of t)e.push(i);return XPt(...e)}let iIt="";const WX={};function oIt(t){for(const e in WX)if(t.startsWith(e)){const i=WX[e];t=t.replace(e,i)}return!t.startsWith("http://")&&!t.startsWith("https://")&&(t=`${iIt}${t}`),t}function rIt(t){return t&&typeof t=="object"&&t.isBuffer}function YX(t){if(rIt(t)||t instanceof ArrayBuffer)return t;if(ArrayBuffer.isView(t))return t.byteOffset===0&&t.byteLength===t.buffer.byteLength?t.buffer:t.buffer.slice(t.byteOffset,t.byteOffset+t.byteLength);if(typeof t=="string"){const e=t;return new TextEncoder().encode(e).buffer}if(t&&typeof t=="object"&&t._toArrayBuffer)return t._toArrayBuffer();throw new Error("toArrayBuffer")}function XX(t){const e=t?t.lastIndexOf("/"):-1;return e>=0?t.substr(e+1):""}function nIt(t){const e=t?t.lastIndexOf("/"):-1;return e>=0?t.substr(0,e):""}const aIt=t=>typeof t=="boolean",S3=t=>typeof t=="function",T3=t=>t!==null&&typeof t=="object",$X=t=>T3(t)&&t.constructor==={}.constructor,sIt=t=>!!t&&typeof t[Symbol.iterator]=="function",lIt=t=>t&&typeof t[Symbol.asyncIterator]=="function",yh=t=>typeof Response<"u"&&t instanceof Response||t&&t.arrayBuffer&&t.text&&t.json,U1=t=>typeof Blob<"u"&&t instanceof Blob,cIt=t=>t&&typeof t=="object"&&t.isBuffer,dIt=t=>typeof ReadableStream<"u"&&t instanceof ReadableStream||T3(t)&&S3(t.tee)&&S3(t.cancel)&&S3(t.getReader),uIt=t=>T3(t)&&S3(t.read)&&S3(t.pipe)&&aIt(t.readable),e$=t=>dIt(t)||uIt(t);class hIt extends Error{constructor(e,i){super(e),this.reason=i.reason,this.url=i.url,this.response=i.response}reason;url;response}const pIt=/^data:([-\w.]+\/[-\w.+]+)(;|,)/,fIt=/^([-\w.]+\/[-\w.+]+)/;function t$(t,e){return t.toLowerCase()===e.toLowerCase()}function AIt(t){const e=fIt.exec(t);return e?e[1]:t}function i$(t){const e=pIt.exec(t);return e?e[1]:""}const o$=/\?.*/;function gIt(t){const e=t.match(o$);return e&&e[0]}function OI(t){return t.replace(o$,"")}function mIt(t){if(t.length<50)return t;const e=t.slice(t.length-15);return`${t.substr(0,32)}...${e}`}function f9(t){return yh(t)?t.url:U1(t)?t.name||"":typeof t=="string"?t:""}function UI(t){if(yh(t)){const e=t,i=e.headers.get("content-type")||"",o=OI(e.url);return AIt(i)||i$(o)}return U1(t)?t.type||"":typeof t=="string"?i$(t):""}function vIt(t){return yh(t)?t.headers["content-length"]||-1:U1(t)?t.size:typeof t=="string"?t.length:t instanceof ArrayBuffer||ArrayBuffer.isView(t)?t.byteLength:-1}async function r$(t){if(yh(t))return t;const e={},i=vIt(t);i>=0&&(e["content-length"]=String(i));const o=f9(t),n=UI(t);n&&(e["content-type"]=n);const r=await wIt(t);r&&(e["x-first-bytes"]=r),typeof t=="string"&&(t=new TextEncoder().encode(t));const a=new Response(t,{headers:e});return Object.defineProperty(a,"url",{value:o}),a}async function yIt(t){if(!t.ok)throw await bIt(t)}async function bIt(t){const e=mIt(t.url);let i=`Failed to fetch resource (${t.status}) ${t.statusText}: ${e}`;i=i.length>100?`${i.slice(0,100)}...`:i;const o={reason:t.statusText,url:t.url,response:t};try{const n=t.headers.get("Content-Type");o.reason=!t.bodyUsed&&n?.includes("application/json")?await t.json():await t.text()}catch{}return new hIt(i,o)}async function wIt(t){if(typeof t=="string")return`data:,${t.slice(0,5)}`;if(t instanceof Blob){const e=t.slice(0,5);return await new Promise(i=>{const o=new FileReader;o.onload=n=>i(n?.target?.result),o.readAsDataURL(e)})}if(t instanceof ArrayBuffer){const e=t.slice(0,5);return`data:base64,${CIt(e)}`}return null}function CIt(t){let e="";const i=new Uint8Array(t);for(let o=0;o<i.byteLength;o++)e+=String.fromCharCode(i[o]);return btoa(e)}function xIt(t){return!kIt(t)&&!MIt(t)}function kIt(t){return t.startsWith("http:")||t.startsWith("https:")}function MIt(t){return t.startsWith("data:")}async function n$(t,e){if(typeof t=="string"){const i=oIt(t);return xIt(i)&&globalThis.loaders?.fetchNode?globalThis.loaders?.fetchNode(i,e):await fetch(i,e)}return await r$(t)}const a$=new II({id:"loaders.gl"});class BIt{log(){return()=>{}}info(){return()=>{}}warn(){return()=>{}}error(){return()=>{}}}class EIt{console;constructor(){this.console=console}log(...e){return this.console.log.bind(this.console,...e)}info(...e){return this.console.info.bind(this.console,...e)}warn(...e){return this.console.warn.bind(this.console,...e)}error(...e){return this.console.error.bind(this.console,...e)}}const s$={fetch:null,mimeType:void 0,nothrow:!1,log:new EIt,useLocalLibraries:!1,CDN:"https://unpkg.com/@loaders.gl",worker:!0,maxConcurrency:3,maxMobileConcurrency:1,reuseWorkers:h9,_nodeWorkers:!1,_workerType:"",limit:0,_limitMB:0,batchSize:"auto",batchDebounceMs:0,metadata:!1,transforms:[]},PIt={throws:"nothrow",dataType:"(no longer used)",uri:"baseUri",method:"fetch.method",headers:"fetch.headers",body:"fetch.body",mode:"fetch.mode",credentials:"fetch.credentials",cache:"fetch.cache",redirect:"fetch.redirect",referrer:"fetch.referrer",referrerPolicy:"fetch.referrerPolicy",integrity:"fetch.integrity",keepalive:"fetch.keepalive",signal:"fetch.signal"};function l$(){globalThis.loaders=globalThis.loaders||{};const{loaders:t}=globalThis;return t._state||(t._state={}),t._state}function c$(){const t=l$();return t.globalOptions=t.globalOptions||{...s$},t.globalOptions}function IIt(t,e,i,o){return i=i||[],i=Array.isArray(i)?i:[i],SIt(t,i),DIt(e,t,o)}function SIt(t,e){d$(t,null,s$,PIt,e);for(const i of e){const o=t&&t[i.id]||{},n=i.options&&i.options[i.id]||{},r=i.deprecatedOptions&&i.deprecatedOptions[i.id]||{};d$(o,i.id,n,r,e)}}function d$(t,e,i,o,n){const r=e||"Top level",a=e?`${e}.`:"";for(const s in t){const l=!e&&T3(t[s]),c=s==="baseUri"&&!e,d=s==="workerUrl"&&e;if(!(s in i)&&!c&&!d){if(s in o)a$.warn(`${r} loader option '${a}${s}' no longer supported, use '${o[s]}'`)();else if(!l){const u=TIt(s,n);a$.warn(`${r} loader option '${a}${s}' not recognized. ${u}`)()}}}}function TIt(t,e){const i=t.toLowerCase();let o="";for(const n of e)for(const r in n.options){if(t===r)return`Did you mean '${n.id}.${r}'?`;const a=r.toLowerCase();(i.startsWith(a)||a.startsWith(i))&&(o=o||`Did you mean '${n.id}.${r}'?`)}return o}function DIt(t,e,i){const o={...t.options||{}};return RIt(o,i),o.log===null&&(o.log=new BIt),u$(o,c$()),u$(o,e),o}function u$(t,e){for(const i in e)if(i in e){const o=e[i];$X(o)&&$X(t[i])?t[i]={...t[i],...e[i]}:t[i]=e[i]}}function RIt(t,e){e&&!("baseUri"in t)&&(t.baseUri=e)}function h$(t){return t?(Array.isArray(t)&&(t=t[0]),Array.isArray(t?.extensions)):!1}function p$(t){fc(t,"null loader"),fc(h$(t),"invalid loader");let e;return Array.isArray(t)&&(e=t[1],t=t[0],t={...t,options:{...t.options,...e}}),(t?.parseTextSync||t?.parseText)&&(t.text=!0),t.text||(t.binary=!0),t}const LIt=()=>{const t=l$();return t.loaderRegistry=t.loaderRegistry||[],t.loaderRegistry};function _It(){return LIt()}const FIt=/\.([^.]+)$/;async function OIt(t,e=[],i,o){if(!A$(t))return null;let n=f$(t,e,{...i,nothrow:!0},o);if(n)return n;if(U1(t)&&(t=await t.slice(0,10).arrayBuffer(),n=f$(t,e,i,o)),!n&&!i?.nothrow)throw new Error(g$(t));return n}function f$(t,e=[],i,o){if(!A$(t))return null;if(e&&!Array.isArray(e))return p$(e);let n=[];e&&(n=n.concat(e)),i?.ignoreRegisteredLoaders||n.push(..._It()),NIt(n);const r=UIt(t,n,i,o);if(!r&&!i?.nothrow)throw new Error(g$(t));return r}function UIt(t,e,i,o){const n=f9(t),r=UI(t),a=OI(n)||o?.url;let s=null,l="";return i?.mimeType&&(s=NI(e,i?.mimeType),l=`match forced by supplied MIME type ${i?.mimeType}`),s=s||jIt(e,a),l=l||(s?`matched url ${a}`:""),s=s||NI(e,r),l=l||(s?`matched MIME type ${r}`:""),s=s||HIt(e,t),l=l||(s?`matched initial data ${v$(t)}`:""),i?.fallbackMimeType&&(s=s||NI(e,i?.fallbackMimeType),l=l||(s?`matched fallback MIME type ${r}`:"")),l&&BPt.log(1,`selectLoader selected ${s?.name}: ${l}.`),s}function A$(t){return!(t instanceof Response&&t.status===204)}function g$(t){const e=f9(t),i=UI(t);let o="No valid loader found (";o+=e?`${XX(e)}, `:"no url provided, ",o+=`MIME type: ${i?`"${i}"`:"not provided"}, `;const n=t?v$(t):"";return o+=n?` first bytes: "${n}"`:"first bytes: not available",o+=")",o}function NIt(t){for(const e of t)p$(e)}function jIt(t,e){const i=e&&FIt.exec(e),o=i&&i[1];return o?VIt(t,o):null}function VIt(t,e){e=e.toLowerCase();for(const i of t)for(const o of i.extensions)if(o.toLowerCase()===e)return i;return null}function NI(t,e){for(const i of t)if(i.mimeTypes?.some(o=>t$(e,o))||t$(e,`application/x.${i.id}`))return i;return null}function HIt(t,e){if(!e)return null;for(const i of t)if(typeof e=="string"){if(zIt(e,i))return i}else if(ArrayBuffer.isView(e)){if(m$(e.buffer,e.byteOffset,i))return i}else if(e instanceof ArrayBuffer&&m$(e,0,i))return i;return null}function zIt(t,e){return e.testText?e.testText(t):(Array.isArray(e.tests)?e.tests:[e.tests]).some(i=>t.startsWith(i))}function m$(t,e,i){return(Array.isArray(i.tests)?i.tests:[i.tests]).some(o=>qIt(t,e,i,o))}function qIt(t,e,i,o){if(o instanceof ArrayBuffer)return YPt(o,t,o.byteLength);switch(typeof o){case"function":return o(t);case"string":const n=jI(t,e,o.length);return o===n;default:return!1}}function v$(t,e=5){return typeof t=="string"?t.slice(0,e):ArrayBuffer.isView(t)?jI(t.buffer,t.byteOffset,e):t instanceof ArrayBuffer?jI(t,0,e):""}function jI(t,e,i){if(t.byteLength<e+i)return"";const o=new DataView(t);let n="";for(let r=0;r<i;r++)n+=String.fromCharCode(o.getUint8(e+r));return n}const QIt=256*1024;function*GIt(t,e){const i=e?.chunkSize||QIt;let o=0;const n=new TextEncoder;for(;o<t.length;){const r=Math.min(t.length-o,i),a=t.slice(o,o+r);o+=r,yield n.encode(a)}}const KIt=256*1024;function*JIt(t,e={}){const{chunkSize:i=KIt}=e;let o=0;for(;o<t.byteLength;){const n=Math.min(t.byteLength-o,i),r=new ArrayBuffer(n),a=new Uint8Array(t,o,n);new Uint8Array(r).set(a),o+=n,yield r}}const ZIt=1024*1024;async function*WIt(t,e){const i=e?.chunkSize||ZIt;let o=0;for(;o<t.size;){const n=o+i,r=await t.slice(o,n).arrayBuffer();o=n,yield r}}function y$(t,e){return h9?YIt(t,e):XIt(t)}async function*YIt(t,e){const i=t.getReader();let o;try{for(;;){const n=o||i.read();e?._streamReadAhead&&(o=i.read());const{done:r,value:a}=await n;if(r)return;yield YX(a)}}catch{i.releaseLock()}}async function*XIt(t,e){for await(const i of t)yield YX(i)}function $It(t,e){if(typeof t=="string")return GIt(t,e);if(t instanceof ArrayBuffer)return JIt(t,e);if(U1(t))return WIt(t,e);if(e$(t))return y$(t,e);if(yh(t))return y$(t.body,e);throw new Error("makeIterator")}const b$="Cannot convert supplied data type";function eSt(t,e,i){if(e.text&&typeof t=="string")return t;if(cIt(t)&&(t=t.buffer),t instanceof ArrayBuffer){const o=t;return e.text&&!e.binary?new TextDecoder("utf8").decode(o):o}if(ArrayBuffer.isView(t)){if(e.text&&!e.binary)return new TextDecoder("utf8").decode(t);let o=t.buffer;const n=t.byteLength||t.length;return(t.byteOffset!==0||n!==o.byteLength)&&(o=o.slice(t.byteOffset,t.byteOffset+n)),o}throw new Error(b$)}async function tSt(t,e,i){const o=t instanceof ArrayBuffer||ArrayBuffer.isView(t);if(typeof t=="string"||o)return eSt(t,e);if(U1(t)&&(t=await r$(t)),yh(t)){const n=t;return await yIt(n),e.binary?await n.arrayBuffer():await n.text()}if(e$(t)&&(t=$It(t,i)),sIt(t)||lIt(t))return tIt(t);throw new Error(b$)}function iSt(t,e){const i=c$(),o=t||i;return typeof o.fetch=="function"?o.fetch:T3(o.fetch)?n=>n$(n,o.fetch):e?.fetch?e?.fetch:n$}function oSt(t,e,i){if(i)return i;const o={fetch:iSt(e,t),...t};if(o.url){const n=OI(o.url);o.baseUrl=n,o.queryString=gIt(o.url),o.filename=XX(n),o.baseUrl=nIt(n)}return Array.isArray(o.loaders)||(o.loaders=null),o}function rSt(t,e){if(t&&!Array.isArray(t))return t;let i;if(t&&(i=Array.isArray(t)?t:[t]),e&&e.loaders){const o=Array.isArray(e.loaders)?e.loaders:[e.loaders];i=i?[...i,...o]:o}return i&&i.length?i:void 0}async function VI(t,e,i,o){e&&!Array.isArray(e)&&!h$(e)&&(o=void 0,i=e,e=void 0),t=await t,i=i||{};const n=f9(t),r=rSt(e,o),a=await OIt(t,r,i);return a?(i=IIt(i,a,r,n),o=oSt({url:n,_parse:VI,loaders:r},i,o||null),await nSt(a,t,i,o)):null}async function nSt(t,e,i,o){if(jPt(t),i=EPt(t.options,i),yh(e)){const r=e,{ok:a,redirected:s,status:l,statusText:c,type:d,url:u}=r,h=Object.fromEntries(r.headers.entries());o.response={headers:h,ok:a,redirected:s,status:l,statusText:c,type:d,url:u}}e=await tSt(e,t,i);const n=t;if(n.parseTextSync&&typeof e=="string")return n.parseTextSync(e,i,o);if(GPt(t,i))return await KPt(t,e,i,o,VI);if(n.parseText&&typeof e=="string")return await n.parseText(e,i,o);if(n.parse)return await n.parse(e,i,o);throw Ac(!n.parseSync),new Error(`${t.id} loader - no parser found and worker is disabled`)}function aSt(t){switch(t.constructor){case Int8Array:return"int8";case Uint8Array:case Uint8ClampedArray:return"uint8";case Int16Array:return"int16";case Uint16Array:return"uint16";case Int32Array:return"int32";case Uint32Array:return"uint32";case Float32Array:return"float32";case Float64Array:return"float64";default:return"null"}}function sSt(t){let e=1/0,i=1/0,o=1/0,n=-1/0,r=-1/0,a=-1/0;const s=t.POSITION?t.POSITION.value:[],l=s&&s.length;for(let c=0;c<l;c+=3){const d=s[c],u=s[c+1],h=s[c+2];e=d<e?d:e,i=u<i?u:i,o=h<o?h:o,n=d>n?d:n,r=u>r?u:r,a=h>a?h:a}return[[e,i,o],[n,r,a]]}function lSt(t,e,i){const o=aSt(e.value),n=i||cSt(e);return{name:t,type:{type:"fixed-size-list",listSize:e.size,children:[{name:"value",type:o}]},nullable:!1,metadata:n}}function cSt(t){const e={};return"byteOffset"in t&&(e.byteOffset=t.byteOffset.toString(10)),"byteStride"in t&&(e.byteStride=t.byteStride.toString(10)),"normalized"in t&&(e.normalized=t.normalized.toString()),e}const dSt="4.3.3",uSt=globalThis.loaders?.parseImageNode,HI=typeof Image<"u",zI=typeof ImageBitmap<"u",hSt=!!uSt,qI=h9?!0:hSt;function pSt(t){switch(t){case"auto":return zI||HI||qI;case"imagebitmap":return zI;case"image":return HI;case"data":return qI;default:throw new Error(`@loaders.gl/images: image ${t} not supported in this environment`)}}function fSt(){if(zI)return"imagebitmap";if(HI)return"image";if(qI)return"data";throw new Error("Install '@loaders.gl/polyfills' to parse images under Node.js")}function ASt(t){const e=gSt(t);if(!e)throw new Error("Not an image");return e}function w$(t){switch(ASt(t)){case"data":return t;case"image":case"imagebitmap":const e=document.createElement("canvas"),i=e.getContext("2d");if(!i)throw new Error("getImageData");return e.width=t.width,e.height=t.height,i.drawImage(t,0,0),i.getImageData(0,0,t.width,t.height);default:throw new Error("getImageData")}}function gSt(t){return typeof ImageBitmap<"u"&&t instanceof ImageBitmap?"imagebitmap":typeof Image<"u"&&t instanceof Image?"image":t&&typeof t=="object"&&t.data&&t.width&&t.height?"data":null}const mSt=/^data:image\/svg\+xml/,vSt=/\.svg((\?|#).*)?$/;function QI(t){return t&&(mSt.test(t)||vSt.test(t))}function ySt(t,e){if(QI(e)){let i=new TextDecoder().decode(t);try{typeof unescape=="function"&&typeof encodeURIComponent=="function"&&(i=unescape(encodeURIComponent(i)))}catch(o){throw new Error(o.message)}return`data:image/svg+xml;base64,${btoa(i)}`}return C$(t,e)}function C$(t,e){if(QI(e))throw new Error("SVG cannot be parsed directly to imagebitmap");return new Blob([new Uint8Array(t)])}async function x$(t,e,i){const o=ySt(t,i),n=self.URL||self.webkitURL,r=typeof o!="string"&&n.createObjectURL(o);try{return await bSt(r||o,e)}finally{r&&n.revokeObjectURL(r)}}async function bSt(t,e){const i=new Image;return i.src=t,e.image&&e.image.decode&&i.decode?(await i.decode(),i):await new Promise((o,n)=>{try{i.onload=()=>o(i),i.onerror=r=>{const a=r instanceof Error?r.message:"error";n(new Error(a))}}catch(r){n(r)}})}const wSt={};let k$=!0;async function CSt(t,e,i){let o;QI(i)?o=await x$(t,e,i):o=C$(t,i);const n=e&&e.imagebitmap;return await xSt(o,n)}async function xSt(t,e=null){if((kSt(e)||!k$)&&(e=null),e)try{return await createImageBitmap(t,e)}catch(i){console.warn(i),k$=!1}return await createImageBitmap(t)}function kSt(t){for(const e in t||wSt)return!1;return!0}function MSt(t){return!ISt(t,"ftyp",4)||(t[8]&96)===0?null:BSt(t)}function BSt(t){switch(ESt(t,8,12).replace("\0"," ").trim()){case"avif":case"avis":return{extension:"avif",mimeType:"image/avif"};default:return null}}function ESt(t,e,i){return String.fromCharCode(...t.slice(e,i))}function PSt(t){return[...t].map(e=>e.charCodeAt(0))}function ISt(t,e,i=0){const o=PSt(e);for(let n=0;n<o.length;++n)if(o[n]!==t[n+i])return!1;return!0}const Al=!1,D3=!0;function GI(t){const e=R3(t);return TSt(e)||LSt(e)||DSt(e)||RSt(e)||SSt(e)}function SSt(t){const e=new Uint8Array(t instanceof DataView?t.buffer:t),i=MSt(e);return i?{mimeType:i.mimeType,width:0,height:0}:null}function TSt(t){const e=R3(t);return e.byteLength>=24&&e.getUint32(0,Al)===2303741511?{mimeType:"image/png",width:e.getUint32(16,Al),height:e.getUint32(20,Al)}:null}function DSt(t){const e=R3(t);return e.byteLength>=10&&e.getUint32(0,Al)===1195984440?{mimeType:"image/gif",width:e.getUint16(6,D3),height:e.getUint16(8,D3)}:null}function RSt(t){const e=R3(t);return e.byteLength>=14&&e.getUint16(0,Al)===16973&&e.getUint32(2,D3)===e.byteLength?{mimeType:"image/bmp",width:e.getUint32(18,D3),height:e.getUint32(22,D3)}:null}function LSt(t){const e=R3(t);if(!(e.byteLength>=3&&e.getUint16(0,Al)===65496&&e.getUint8(2)===255))return null;const{tableMarkers:i,sofMarkers:o}=_St();let n=2;for(;n+9<e.byteLength;){const r=e.getUint16(n,Al);if(o.has(r))return{mimeType:"image/jpeg",height:e.getUint16(n+5,Al),width:e.getUint16(n+7,Al)};if(!i.has(r))return null;n+=2,n+=e.getUint16(n,Al)}return null}function _St(){const t=new Set([65499,65476,65484,65501,65534]);for(let e=65504;e<65520;++e)t.add(e);return{tableMarkers:t,sofMarkers:new Set([65472,65473,65474,65475,65477,65478,65479,65481,65482,65483,65485,65486,65487,65502])}}function R3(t){if(t instanceof DataView)return t;if(ArrayBuffer.isView(t))return new DataView(t.buffer);if(t instanceof ArrayBuffer)return new DataView(t);throw new Error("toDataView")}async function FSt(t,e){const{mimeType:i}=GI(t)||{},o=globalThis.loaders?.parseImageNode;return fc(o),await o(t,i)}async function OSt(t,e,i){e=e||{};const o=(e.image||{}).type||"auto",{url:n}=i||{},r=USt(o);let a;switch(r){case"imagebitmap":a=await CSt(t,e,n);break;case"image":a=await x$(t,e,n);break;case"data":a=await FSt(t);break;default:fc(!1)}return o==="data"&&(a=w$(a)),a}function USt(t){switch(t){case"auto":case"data":return fSt();default:return pSt(t),t}}const NSt=["png","jpg","jpeg","gif","webp","bmp","ico","svg","avif"],jSt=["image/png","image/jpeg","image/gif","image/webp","image/avif","image/bmp","image/vnd.microsoft.icon","image/svg+xml"],VSt={image:{type:"auto",decode:!0}},HSt={dataType:null,batchType:null,id:"image",module:"images",name:"Images",version:dSt,mimeTypes:jSt,extensions:NSt,parse:OSt,tests:[t=>!!GI(new DataView(t))],options:VSt},KI={};function zSt(t){if(KI[t]===void 0){const e=h9?QSt(t):qSt(t);KI[t]=e}return KI[t]}function qSt(t){const e=["image/png","image/jpeg","image/gif"],i=globalThis.loaders?.imageFormatsNode||e;return!!globalThis.loaders?.parseImageNode&&i.includes(t)}function QSt(t){switch(t){case"image/avif":case"image/webp":return GSt(t);default:return!0}}function GSt(t){try{return document.createElement("canvas").toDataURL(t).indexOf(`data:${t}`)===0}catch{return!1}}function ya(t,e){if(!t)throw new Error(e||"assert failed: gltf")}const M$={SCALAR:1,VEC2:2,VEC3:3,VEC4:4,MAT2:4,MAT3:9,MAT4:16},B$={5120:1,5121:1,5122:2,5123:2,5125:4,5126:4},E$=["SCALAR","VEC2","VEC3","VEC4"],KSt=[[Int8Array,5120],[Uint8Array,5121],[Int16Array,5122],[Uint16Array,5123],[Uint32Array,5125],[Float32Array,5126],[Float64Array,5130]],JSt=new Map(KSt),ZSt={SCALAR:1,VEC2:2,VEC3:3,VEC4:4,MAT2:4,MAT3:9,MAT4:16},WSt={5120:1,5121:1,5122:2,5123:2,5125:4,5126:4},YSt={5120:Int8Array,5121:Uint8Array,5122:Int16Array,5123:Uint16Array,5125:Uint32Array,5126:Float32Array};function P$(t){return E$[t-1]||E$[0]}function A9(t){const e=JSt.get(t.constructor);if(!e)throw new Error("Illegal typed array");return e}function JI(t,e){const i=YSt[t.componentType],o=ZSt[t.type],n=WSt[t.componentType],r=t.count*o,a=t.count*o*n;ya(a>=0&&a<=e.byteLength);const s=B$[t.componentType],l=M$[t.type];return{ArrayType:i,length:r,byteLength:a,componentByteSize:s,numberOfComponentsInElement:l}}function XSt(t,e,i){const o=t.bufferViews[i];ya(o);const n=o.buffer,r=e[n];ya(r);const a=(o.byteOffset||0)+r.byteOffset;return new Uint8Array(r.arrayBuffer,a,o.byteLength)}function $St(t,e,i){const o=typeof i=="number"?t.accessors?.[i]:i;if(!o)throw new Error(`No gltf accessor ${JSON.stringify(i)}`);const n=t.bufferViews?.[o.bufferView||0];if(!n)throw new Error(`No gltf buffer view for accessor ${n}`);const{arrayBuffer:r,byteOffset:a}=e[n.buffer],s=(a||0)+(o.byteOffset||0)+(n.byteOffset||0),{ArrayType:l,length:c,componentByteSize:d,numberOfComponentsInElement:u}=JI(o,n),h=d*u,p=n.byteStride||h;if(typeof n.byteStride>"u"||n.byteStride===h)return new l(r,s,c);const A=new l(c);for(let f=0;f<o.count;f++){const m=new l(r,s+f*p,u);A.set(m,f*u)}return A}function eTt(){return{asset:{version:"2.0",generator:"loaders.gl"},buffers:[],extensions:{},extensionsRequired:[],extensionsUsed:[]}}class Er{gltf;sourceBuffers;byteLength;constructor(e){this.gltf={json:e?.json||eTt(),buffers:e?.buffers||[],images:e?.images||[]},this.sourceBuffers=[],this.byteLength=0,this.gltf.buffers&&this.gltf.buffers[0]&&(this.byteLength=this.gltf.buffers[0].byteLength,this.sourceBuffers=[this.gltf.buffers[0]])}get json(){return this.gltf.json}getApplicationData(e){return this.json[e]}getExtraData(e){return(this.json.extras||{})[e]}hasExtension(e){const i=this.getUsedExtensions().find(n=>n===e),o=this.getRequiredExtensions().find(n=>n===e);return typeof i=="string"||typeof o=="string"}getExtension(e){const i=this.getUsedExtensions().find(n=>n===e),o=this.json.extensions||{};return i?o[e]:null}getRequiredExtension(e){return this.getRequiredExtensions().find(i=>i===e)?this.getExtension(e):null}getRequiredExtensions(){return this.json.extensionsRequired||[]}getUsedExtensions(){return this.json.extensionsUsed||[]}getRemovedExtensions(){return this.json.extensionsRemoved||[]}getObjectExtension(e,i){return(e.extensions||{})[i]}getScene(e){return this.getObject("scenes",e)}getNode(e){return this.getObject("nodes",e)}getSkin(e){return this.getObject("skins",e)}getMesh(e){return this.getObject("meshes",e)}getMaterial(e){return this.getObject("materials",e)}getAccessor(e){return this.getObject("accessors",e)}getTexture(e){return this.getObject("textures",e)}getSampler(e){return this.getObject("samplers",e)}getImage(e){return this.getObject("images",e)}getBufferView(e){return this.getObject("bufferViews",e)}getBuffer(e){return this.getObject("buffers",e)}getObject(e,i){if(typeof i=="object")return i;const o=this.json[e]&&this.json[e][i];if(!o)throw new Error(`glTF file error: Could not find ${e}[${i}]`);return o}getTypedArrayForBufferView(e){e=this.getBufferView(e);const i=e.buffer,o=this.gltf.buffers[i];ya(o);const n=(e.byteOffset||0)+o.byteOffset;return new Uint8Array(o.arrayBuffer,n,e.byteLength)}getTypedArrayForAccessor(e){const i=this.getAccessor(e);return $St(this.gltf.json,this.gltf.buffers,i)}getTypedArrayForImageData(e){e=this.getAccessor(e);const i=this.getBufferView(e.bufferView),o=this.getBuffer(i.buffer).data,n=i.byteOffset||0;return new Uint8Array(o,n,i.byteLength)}addApplicationData(e,i){return this.json[e]=i,this}addExtraData(e,i){return this.json.extras=this.json.extras||{},this.json.extras[e]=i,this}addObjectExtension(e,i,o){return e.extensions=e.extensions||{},e.extensions[i]=o,this.registerUsedExtension(i),this}setObjectExtension(e,i,o){const n=e.extensions||{};n[i]=o}removeObjectExtension(e,i){const o=e?.extensions||{};if(o[i]){this.json.extensionsRemoved=this.json.extensionsRemoved||[];const n=this.json.extensionsRemoved;n.includes(i)||n.push(i)}delete o[i]}addExtension(e,i={}){return ya(i),this.json.extensions=this.json.extensions||{},this.json.extensions[e]=i,this.registerUsedExtension(e),i}addRequiredExtension(e,i={}){return ya(i),this.addExtension(e,i),this.registerRequiredExtension(e),i}registerUsedExtension(e){this.json.extensionsUsed=this.json.extensionsUsed||[],this.json.extensionsUsed.find(i=>i===e)||this.json.extensionsUsed.push(e)}registerRequiredExtension(e){this.registerUsedExtension(e),this.json.extensionsRequired=this.json.extensionsRequired||[],this.json.extensionsRequired.find(i=>i===e)||this.json.extensionsRequired.push(e)}removeExtension(e){if(this.json.extensions?.[e]){this.json.extensionsRemoved=this.json.extensionsRemoved||[];const i=this.json.extensionsRemoved;i.includes(e)||i.push(e)}this.json.extensions&&delete this.json.extensions[e],this.json.extensionsRequired&&this._removeStringFromArray(this.json.extensionsRequired,e),this.json.extensionsUsed&&this._removeStringFromArray(this.json.extensionsUsed,e)}setDefaultScene(e){this.json.scene=e}addScene(e){const{nodeIndices:i}=e;return this.json.scenes=this.json.scenes||[],this.json.scenes.push({nodes:i}),this.json.scenes.length-1}addNode(e){const{meshIndex:i,matrix:o}=e;this.json.nodes=this.json.nodes||[];const n={mesh:i};return o&&(n.matrix=o),this.json.nodes.push(n),this.json.nodes.length-1}addMesh(e){const{attributes:i,indices:o,material:n,mode:r=4}=e,a={primitives:[{attributes:this._addAttributes(i),mode:r}]};if(o){const s=this._addIndices(o);a.primitives[0].indices=s}return Number.isFinite(n)&&(a.primitives[0].material=n),this.json.meshes=this.json.meshes||[],this.json.meshes.push(a),this.json.meshes.length-1}addPointCloud(e){const i={primitives:[{attributes:this._addAttributes(e),mode:0}]};return this.json.meshes=this.json.meshes||[],this.json.meshes.push(i),this.json.meshes.length-1}addImage(e,i){const o=GI(e),n=i||o?.mimeType,r={bufferView:this.addBufferView(e),mimeType:n};return this.json.images=this.json.images||[],this.json.images.push(r),this.json.images.length-1}addBufferView(e,i=0,o=this.byteLength){const n=e.byteLength;ya(Number.isFinite(n)),this.sourceBuffers=this.sourceBuffers||[],this.sourceBuffers.push(e);const r={buffer:i,byteOffset:o,byteLength:n};return this.byteLength+=I3(n,4),this.json.bufferViews=this.json.bufferViews||[],this.json.bufferViews.push(r),this.json.bufferViews.length-1}addAccessor(e,i){const o={bufferView:e,type:P$(i.size),componentType:i.componentType,count:i.count,max:i.max,min:i.min};return this.json.accessors=this.json.accessors||[],this.json.accessors.push(o),this.json.accessors.length-1}addBinaryBuffer(e,i={size:3}){const o=this.addBufferView(e);let n={min:i.min,max:i.max};(!n.min||!n.max)&&(n=this._getAccessorMinMax(e,i.size));const r={size:i.size,componentType:A9(e),count:Math.round(e.length/i.size),min:n.min,max:n.max};return this.addAccessor(o,Object.assign(r,i))}addTexture(e){const{imageIndex:i}=e,o={source:i};return this.json.textures=this.json.textures||[],this.json.textures.push(o),this.json.textures.length-1}addMaterial(e){return this.json.materials=this.json.materials||[],this.json.materials.push(e),this.json.materials.length-1}createBinaryChunk(){const e=this.byteLength,i=new ArrayBuffer(e),o=new Uint8Array(i);let n=0;for(const r of this.sourceBuffers||[])n=eIt(r,o,n);this.json?.buffers?.[0]?this.json.buffers[0].byteLength=e:this.json.buffers=[{byteLength:e}],this.gltf.binary=i,this.sourceBuffers=[i],this.gltf.buffers=[{arrayBuffer:i,byteOffset:0,byteLength:i.byteLength}]}_removeStringFromArray(e,i){let o=!0;for(;o;){const n=e.indexOf(i);n>-1?e.splice(n,1):o=!1}}_addAttributes(e={}){const i={};for(const o in e){const n=e[o],r=this._getGltfAttributeName(o),a=this.addBinaryBuffer(n.value,n);i[r]=a}return i}_addIndices(e){return this.addBinaryBuffer(e,{size:1})}_getGltfAttributeName(e){switch(e.toLowerCase()){case"position":case"positions":case"vertices":return"POSITION";case"normal":case"normals":return"NORMAL";case"color":case"colors":return"COLOR_0";case"texcoord":case"texcoords":return"TEXCOORD_0";default:return e}}_getAccessorMinMax(e,i){const o={min:null,max:null};if(e.length<i)return o;o.min=[],o.max=[];const n=e.subarray(0,i);for(const r of n)o.min.push(r),o.max.push(r);for(let r=i;r<e.length;r+=i)for(let a=0;a<i;a++)o.min[0+a]=Math.min(o.min[0+a],e[r+a]),o.max[0+a]=Math.max(o.max[0+a],e[r+a]);return o}}function I$(t){return(t%1+1)%1}const S$={SCALAR:1,VEC2:2,VEC3:3,VEC4:4,MAT2:4,MAT3:9,MAT4:16,BOOLEAN:1,STRING:1,ENUM:1},tTt={INT8:Int8Array,UINT8:Uint8Array,INT16:Int16Array,UINT16:Uint16Array,INT32:Int32Array,UINT32:Uint32Array,INT64:BigInt64Array,UINT64:BigUint64Array,FLOAT32:Float32Array,FLOAT64:Float64Array},T$={INT8:1,UINT8:1,INT16:2,UINT16:2,INT32:4,UINT32:4,INT64:8,UINT64:8,FLOAT32:4,FLOAT64:8};function ZI(t,e){return T$[e]*S$[t]}function g9(t,e,i,o){if(i!=="UINT8"&&i!=="UINT16"&&i!=="UINT32"&&i!=="UINT64")return null;const n=t.getTypedArrayForBufferView(e),r=m9(n,"SCALAR",i,o+1);return r instanceof BigInt64Array||r instanceof BigUint64Array?null:r}function m9(t,e,i,o=1){const n=S$[e],r=tTt[i],a=T$[i],s=o*n,l=s*a;let c=t.buffer,d=t.byteOffset;return d%a!==0&&(c=new Uint8Array(c).slice(d,d+l).buffer,d=0),new r(c,d,s)}function WI(t,e,i){const o=`TEXCOORD_${e.texCoord||0}`,n=i.attributes[o],r=t.getTypedArrayForAccessor(n),a=t.gltf.json,s=e.index,l=a.textures?.[s]?.source;if(typeof l<"u"){const c=a.images?.[l]?.mimeType,d=t.gltf.images?.[l];if(d&&typeof d.width<"u"){const u=[];for(let h=0;h<r.length;h+=2){const p=iTt(d,c,r,h,e.channels);u.push(p)}return u}}return[]}function D$(t,e,i,o,n){if(!i?.length)return;const r=[];for(const d of i){let u=o.findIndex(h=>h===d);u===-1&&(u=o.push(d)-1),r.push(u)}const a=new Uint32Array(r),s=t.gltf.buffers.push({arrayBuffer:a.buffer,byteOffset:a.byteOffset,byteLength:a.byteLength})-1,l=t.addBufferView(a,s,0),c=t.addAccessor(l,{size:1,componentType:A9(a),count:a.length});n.attributes[e]=c}function iTt(t,e,i,o,n=[0]){const r={r:{offset:0,shift:0},g:{offset:1,shift:8},b:{offset:2,shift:16},a:{offset:3,shift:24}},a=i[o],s=i[o+1];let l=1;e&&(e.indexOf("image/jpeg")!==-1||e.indexOf("image/png")!==-1)&&(l=4);const c=oTt(a,s,t,l);let d=0;for(const u of n){const h=typeof u=="number"?Object.values(r)[u]:r[u],p=c+h.offset,A=w$(t);if(A.data.length<=p)throw new Error(`${A.data.length} <= ${p}`);const f=A.data[p];d|=f<<h.shift}return d}function oTt(t,e,i,o=1){const n=i.width,r=I$(t)*(n-1),a=Math.round(r),s=i.height,l=I$(e)*(s-1),c=Math.round(l),d=i.components?i.components:o;return(c*n+a)*d}function R$(t,e,i,o,n){const r=[];for(let a=0;a<e;a++){const s=i[a],l=i[a+1]-i[a];if(l+s>o)break;const c=s/n,d=l/n;r.push(t.slice(c,c+d))}return r}function L$(t,e,i){const o=[];for(let n=0;n<e;n++){const r=n*i;o.push(t.slice(r,r+i))}return o}function _$(t,e,i,o){if(i)throw new Error("Not implemented - arrayOffsets for strings is specified");if(o){const n=[],r=new TextDecoder("utf8");let a=0;for(let s=0;s<t;s++){const l=o[s+1]-o[s];if(l+a<=e.length){const c=e.subarray(a,l+a),d=r.decode(c);n.push(d),a+=l}}return n}return[]}const N1="EXT_mesh_features",rTt=N1;async function nTt(t,e){const i=new Er(t);sTt(i,e)}function aTt(t,e){const i=new Er(t);return cTt(i),i.createBinaryChunk(),i.gltf}function sTt(t,e){const i=t.gltf.json;if(i.meshes)for(const o of i.meshes)for(const n of o.primitives)lTt(t,n,e)}function lTt(t,e,i){if(!i?.gltf?.loadBuffers)return;const o=e.extensions?.[N1]?.featureIds;if(o)for(const n of o){let r;if(typeof n.attribute<"u"){const a=`_FEATURE_ID_${n.attribute}`,s=e.attributes[a];r=t.getTypedArrayForAccessor(s)}else typeof n.texture<"u"&&i?.gltf?.loadImages?r=WI(t,n.texture,e):r=[];n.data=r}}function cTt(t,e){const i=t.gltf.json.meshes;if(i)for(const o of i)for(const n of o.primitives)uTt(t,n)}function dTt(t,e,i,o){e.extensions||(e.extensions={});let n=e.extensions[N1];n||(n={featureIds:[]},e.extensions[N1]=n);const{featureIds:r}=n,a={featureCount:i.length,propertyTable:o,data:i};r.push(a),t.addObjectExtension(e,N1,n)}function uTt(t,e){const i=e.extensions?.[N1];if(!i)return;const o=i.featureIds;o.forEach((n,r)=>{if(n.data){const{accessorKey:a,index:s}=hTt(e.attributes),l=new Uint32Array(n.data);o[r]={featureCount:l.length,propertyTable:n.propertyTable,attribute:s},t.gltf.buffers.push({arrayBuffer:l.buffer,byteOffset:l.byteOffset,byteLength:l.byteLength});const c=t.addBufferView(l),d=t.addAccessor(c,{size:1,componentType:A9(l),count:l.length});e.attributes[a]=d}})}function hTt(t){const e="_FEATURE_ID_",i=Object.keys(t).filter(n=>n.indexOf(e)===0);let o=-1;for(const n of i){const r=Number(n.substring(e.length));r>o&&(o=r)}return o++,{accessorKey:`${e}${o}`,index:o}}const pTt=Object.freeze(Object.defineProperty({__proto__:null,createExtMeshFeatures:dTt,decode:nTt,encode:aTt,name:rTt},Symbol.toStringTag,{value:"Module"})),j1="EXT_structural_metadata",fTt=j1;async function ATt(t,e){const i=new Er(t);mTt(i,e)}function gTt(t,e){const i=new Er(t);return RTt(i),i.createBinaryChunk(),i.gltf}function mTt(t,e){if(!e.gltf?.loadBuffers)return;const i=t.getExtension(j1);i&&(e.gltf?.loadImages&&vTt(t,i),yTt(t,i))}function vTt(t,e){const i=e.propertyTextures,o=t.gltf.json;if(i&&o.meshes)for(const n of o.meshes)for(const r of n.primitives)wTt(t,i,r,e)}function yTt(t,e){const i=e.schema;if(!i)return;const o=i.classes,n=e.propertyTables;if(o&&n)for(const r in o){const a=bTt(n,r);a&&xTt(t,i,a)}}function bTt(t,e){for(const i of t)if(i.class===e)return i;return null}function wTt(t,e,i,o){if(!e)return;const n=i.extensions?.[j1]?.propertyTextures;if(n)for(const r of n){const a=e[r];CTt(t,a,i,o)}}function CTt(t,e,i,o){if(!e.properties)return;o.dataAttributeNames||(o.dataAttributeNames=[]);const n=e.class;for(const r in e.properties){const a=`${n}_${r}`,s=e.properties?.[r];if(!s)continue;s.data||(s.data=[]);const l=s.data,c=WI(t,s,i);c!==null&&(D$(t,a,c,l,i),s.data=l,o.dataAttributeNames.push(a))}}function xTt(t,e,i){const o=e.classes?.[i.class];if(!o)throw new Error(`Incorrect data in the EXT_structural_metadata extension: no schema class with name ${i.class}`);const n=i.count;for(const r in o.properties){const a=o.properties[r],s=i.properties?.[r];if(s){const l=kTt(t,e,a,n,s);s.data=l}}}function kTt(t,e,i,o,n){let r=[];const a=n.values,s=t.getTypedArrayForBufferView(a),l=MTt(t,i,n,o),c=BTt(t,n,o);switch(i.type){case"SCALAR":case"VEC2":case"VEC3":case"VEC4":case"MAT2":case"MAT3":case"MAT4":{r=ETt(i,o,s,l);break}case"BOOLEAN":throw new Error(`Not implemented - classProperty.type=${i.type}`);case"STRING":{r=_$(o,s,l,c);break}case"ENUM":{r=PTt(e,i,o,s,l);break}default:throw new Error(`Unknown classProperty type ${i.type}`)}return r}function MTt(t,e,i,o){return e.array&&typeof e.count>"u"&&typeof i.arrayOffsets<"u"?g9(t,i.arrayOffsets,i.arrayOffsetType||"UINT32",o):null}function BTt(t,e,i){return typeof e.stringOffsets<"u"?g9(t,e.stringOffsets,e.stringOffsetType||"UINT32",i):null}function ETt(t,e,i,o){const n=t.array,r=t.count,a=ZI(t.type,t.componentType),s=i.byteLength/a;let l;return t.componentType?l=m9(i,t.type,t.componentType,s):l=i,n?o?R$(l,e,o,i.length,a):r?L$(l,e,r):[]:l}function PTt(t,e,i,o,n){const r=e.enumType;if(!r)throw new Error("Incorrect data in the EXT_structural_metadata extension: classProperty.enumType is not set for type ENUM");const a=t.enums?.[r];if(!a)throw new Error(`Incorrect data in the EXT_structural_metadata extension: schema.enums does't contain ${r}`);const s=a.valueType||"UINT16",l=ZI(e.type,s),c=o.byteLength/l;let d=m9(o,e.type,s,c);if(d||(d=o),e.array){if(n)return ITt({valuesData:d,numberOfElements:i,arrayOffsets:n,valuesDataBytesLength:o.length,elementSize:l,enumEntry:a});const u=e.count;return u?STt(d,i,u,a):[]}return YI(d,0,i,a)}function ITt(t){const{valuesData:e,numberOfElements:i,arrayOffsets:o,valuesDataBytesLength:n,elementSize:r,enumEntry:a}=t,s=[];for(let l=0;l<i;l++){const c=o[l],d=o[l+1]-o[l];if(d+c>n)break;const u=c/r,h=d/r,p=YI(e,u,h,a);s.push(p)}return s}function STt(t,e,i,o){const n=[];for(let r=0;r<e;r++){const a=i*r,s=YI(t,a,i,o);n.push(s)}return n}function YI(t,e,i,o){const n=[];for(let r=0;r<i;r++)if(t instanceof BigInt64Array||t instanceof BigUint64Array)n.push("");else{const a=t[e+r],s=TTt(o,a);s?n.push(s.name):n.push("")}return n}function TTt(t,e){for(const i of t.values)if(i.value===e)return i;return null}const DTt="schemaClassId";function RTt(t,e){const i=t.getExtension(j1);if(i&&i.propertyTables)for(const o of i.propertyTables){const n=o.class,r=i.schema?.classes?.[n];o.properties&&r&&LTt(o,r,t)}}function LTt(t,e,i){for(const o in t.properties){const n=t.properties[o].data;if(n){const r=e.properties[o];if(r){const a=UTt(n,r,i);t.properties[o]=a}}}}function _Tt(t,e,i=DTt){let o=t.getExtension(j1);o||(o=t.addExtension(j1)),o.schema=FTt(e,i,o.schema);const n=OTt(e,i,o.schema);return o.propertyTables||(o.propertyTables=[]),o.propertyTables.push(n)-1}function FTt(t,e,i){const o=i??{id:"schema_id"},n={properties:{}};for(const r of t){const a={type:r.elementType,componentType:r.componentType};n.properties[r.name]=a}return o.classes={},o.classes[e]=n,o}function OTt(t,e,i){const o={class:e,count:0};let n=0;const r=i.classes?.[e];for(const a of t){if(n===0&&(n=a.values.length),n!==a.values.length&&a.values.length)throw new Error("Illegal values in attributes");r?.properties[a.name]&&(o.properties||(o.properties={}),o.properties[a.name]={values:0,data:a.values})}return o.count=n,o}function UTt(t,e,i){const o={values:0};if(e.type==="STRING"){const{stringData:n,stringOffsets:r}=VTt(t);o.stringOffsets=XI(r,i),o.values=XI(n,i)}else if(e.type==="SCALAR"&&e.componentType){const n=jTt(t,e.componentType);o.values=XI(n,i)}return o}const NTt={INT8:Int8Array,UINT8:Uint8Array,INT16:Int16Array,UINT16:Uint16Array,INT32:Int32Array,UINT32:Uint32Array,INT64:Int32Array,UINT64:Uint32Array,FLOAT32:Float32Array,FLOAT64:Float64Array};function jTt(t,e){const i=[];for(const n of t)i.push(Number(n));const o=NTt[e];if(!o)throw new Error("Illegal component type");return new o(i)}function VTt(t){const e=new TextEncoder,i=[];let o=0;for(const l of t){const c=e.encode(l);o+=c.length,i.push(c)}const n=new Uint8Array(o),r=[];let a=0;for(const l of i)n.set(l,a),r.push(a),a+=l.length;r.push(a);const s=new Uint32Array(r);return{stringData:n,stringOffsets:s}}function XI(t,e){return e.gltf.buffers.push({arrayBuffer:t.buffer,byteOffset:t.byteOffset,byteLength:t.byteLength}),e.addBufferView(t)}const HTt=Object.freeze(Object.defineProperty({__proto__:null,createExtStructuralMetadata:_Tt,decode:ATt,encode:gTt,name:fTt},Symbol.toStringTag,{value:"Module"})),F$="EXT_feature_metadata",zTt=F$;async function qTt(t,e){const i=new Er(t);QTt(i,e)}function QTt(t,e){if(!e.gltf?.loadBuffers)return;const i=t.getExtension(F$);i&&(e.gltf?.loadImages&&GTt(t,i),KTt(t,i))}function GTt(t,e){const i=e.schema;if(!i)return;const o=i.classes,{featureTextures:n}=e;if(o&&n)for(const r in o){const a=o[r],s=ZTt(n,r);s&&YTt(t,s,a)}}function KTt(t,e){const i=e.schema;if(!i)return;const o=i.classes,n=e.featureTables;if(o&&n)for(const r in o){const a=JTt(n,r);a&&WTt(t,i,a)}}function JTt(t,e){for(const i in t){const o=t[i];if(o.class===e)return o}return null}function ZTt(t,e){for(const i in t){const o=t[i];if(o.class===e)return o}return null}function WTt(t,e,i){if(!i.class)return;const o=e.classes?.[i.class];if(!o)throw new Error(`Incorrect data in the EXT_structural_metadata extension: no schema class with name ${i.class}`);const n=i.count;for(const r in o.properties){const a=o.properties[r],s=i.properties?.[r];if(s){const l=XTt(t,e,a,n,s);s.data=l}}}function YTt(t,e,i){const o=e.class;for(const n in i.properties){const r=e?.properties?.[n];if(r){const a=oDt(t,r,o);r.data=a}}}function XTt(t,e,i,o,n){let r=[];const a=n.bufferView,s=t.getTypedArrayForBufferView(a),l=$Tt(t,i,n,o),c=eDt(t,i,n,o);return i.type==="STRING"||i.componentType==="STRING"?r=_$(o,s,l,c):tDt(i)&&(r=iDt(i,o,s,l)),r}function $Tt(t,e,i,o){return e.type==="ARRAY"&&typeof e.componentCount>"u"&&typeof i.arrayOffsetBufferView<"u"?g9(t,i.arrayOffsetBufferView,i.offsetType||"UINT32",o):null}function eDt(t,e,i,o){return typeof i.stringOffsetBufferView<"u"?g9(t,i.stringOffsetBufferView,i.offsetType||"UINT32",o):null}function tDt(t){const e=["UINT8","INT16","UINT16","INT32","UINT32","INT64","UINT64","FLOAT32","FLOAT64"];return e.includes(t.type)||typeof t.componentType<"u"&&e.includes(t.componentType)}function iDt(t,e,i,o){const n=t.type==="ARRAY",r=t.componentCount,a="SCALAR",s=t.componentType||t.type,l=ZI(a,s),c=i.byteLength/l,d=m9(i,a,s,c);return n?o?R$(d,e,o,i.length,l):r?L$(d,e,r):[]:d}function oDt(t,e,i){const o=t.gltf.json;if(!o.meshes)return[];const n=[];for(const r of o.meshes)for(const a of r.primitives)rDt(t,i,e,n,a);return n}function rDt(t,e,i,o,n){const r={channels:i.channels,...i.texture},a=WI(t,r,n);a&&D$(t,e,a,o,n)}const nDt=Object.freeze(Object.defineProperty({__proto__:null,decode:qTt,name:zTt},Symbol.toStringTag,{value:"Module"})),aDt="4.3.3",sDt="4.3.3",v9={TRANSCODER:"basis_transcoder.js",TRANSCODER_WASM:"basis_transcoder.wasm",ENCODER:"basis_encoder.js",ENCODER_WASM:"basis_encoder.wasm"};let O$;async function U$(t){return PPt(t.modules),IPt("basis")||(O$||=lDt(t),await O$)}async function lDt(t){let e=null,i=null;return[e,i]=await Promise.all([await vh(v9.TRANSCODER,"textures",t),await vh(v9.TRANSCODER_WASM,"textures",t)]),e=e||globalThis.BASIS,await cDt(e,i)}function cDt(t,e){const i={};return e&&(i.wasmBinary=e),new Promise(o=>{t(i).then(n=>{const{BasisFile:r,initializeBasis:a}=n;a(),o({BasisFile:r})})})}let $I;async function N$(t){const e=t.modules||{};return e.basisEncoder?e.basisEncoder:($I=$I||dDt(t),await $I)}async function dDt(t){let e=null,i=null;return[e,i]=await Promise.all([await vh(v9.ENCODER,"textures",t),await vh(v9.ENCODER_WASM,"textures",t)]),e=e||globalThis.BASIS,await uDt(e,i)}function uDt(t,e){const i={};return e&&(i.wasmBinary=e),new Promise(o=>{t(i).then(n=>{const{BasisFile:r,KTX2File:a,initializeBasis:s,BasisEncoder:l}=n;s(),o({BasisFile:r,KTX2File:a,BasisEncoder:l})})})}const V1={COMPRESSED_RGB_S3TC_DXT1_EXT:33776,COMPRESSED_RGBA_S3TC_DXT5_EXT:33779,COMPRESSED_RGB_PVRTC_4BPPV1_IMG:35840,COMPRESSED_RGBA_PVRTC_4BPPV1_IMG:35842,COMPRESSED_RGB_ETC1_WEBGL:36196,COMPRESSED_RGBA_ASTC_4X4_KHR:37808},hDt=["","WEBKIT_","MOZ_"],j$={WEBGL_compressed_texture_s3tc:"dxt",WEBGL_compressed_texture_s3tc_srgb:"dxt-srgb",WEBGL_compressed_texture_etc1:"etc1",WEBGL_compressed_texture_etc:"etc2",WEBGL_compressed_texture_pvrtc:"pvrtc",WEBGL_compressed_texture_atc:"atc",WEBGL_compressed_texture_astc:"astc",EXT_texture_compression_rgtc:"rgtc"};let y9=null;function pDt(t){if(!y9){t=t||fDt()||void 0,y9=new Set;for(const e of hDt)for(const i in j$)if(t&&t.getExtension(`${e}${i}`)){const o=j$[i];y9.add(o)}}return y9}function fDt(){try{return document.createElement("canvas").getContext("webgl")}catch{return null}}const ba=[171,75,84,88,32,50,48,187,13,10,26,10];function ADt(t){const e=new Uint8Array(t);return!(e.byteLength<ba.length||e[0]!==ba[0]||e[1]!==ba[1]||e[2]!==ba[2]||e[3]!==ba[3]||e[4]!==ba[4]||e[5]!==ba[5]||e[6]!==ba[6]||e[7]!==ba[7]||e[8]!==ba[8]||e[9]!==ba[9]||e[10]!==ba[10]||e[11]!==ba[11])}const gDt={etc1:{basisFormat:0,compressed:!0,format:V1.COMPRESSED_RGB_ETC1_WEBGL},etc2:{basisFormat:1,compressed:!0},bc1:{basisFormat:2,compressed:!0,format:V1.COMPRESSED_RGB_S3TC_DXT1_EXT},bc3:{basisFormat:3,compressed:!0,format:V1.COMPRESSED_RGBA_S3TC_DXT5_EXT},bc4:{basisFormat:4,compressed:!0},bc5:{basisFormat:5,compressed:!0},"bc7-m6-opaque-only":{basisFormat:6,compressed:!0},"bc7-m5":{basisFormat:7,compressed:!0},"pvrtc1-4-rgb":{basisFormat:8,compressed:!0,format:V1.COMPRESSED_RGB_PVRTC_4BPPV1_IMG},"pvrtc1-4-rgba":{basisFormat:9,compressed:!0,format:V1.COMPRESSED_RGBA_PVRTC_4BPPV1_IMG},"astc-4x4":{basisFormat:10,compressed:!0,format:V1.COMPRESSED_RGBA_ASTC_4X4_KHR},"atc-rgb":{basisFormat:11,compressed:!0},"atc-rgba-interpolated-alpha":{basisFormat:12,compressed:!0},rgba32:{basisFormat:13,compressed:!1},rgb565:{basisFormat:14,compressed:!1},bgr565:{basisFormat:15,compressed:!1},rgba4444:{basisFormat:16,compressed:!1}};async function mDt(t,e){if(e.basis.containerFormat==="auto"){if(ADt(t)){const o=await N$(e);return V$(o.KTX2File,t,e)}const{BasisFile:i}=await U$(e);return eS(i,t,e)}switch(e.basis.module){case"encoder":const i=await N$(e);switch(e.basis.containerFormat){case"ktx2":return V$(i.KTX2File,t,e);case"basis":default:return eS(i.BasisFile,t,e)}case"transcoder":default:const{BasisFile:o}=await U$(e);return eS(o,t,e)}}function eS(t,e,i){const o=new t(new Uint8Array(e));try{if(!o.startTranscoding())throw new Error("Failed to start basis transcoding");const n=o.getNumImages(),r=[];for(let a=0;a<n;a++){const s=o.getNumLevels(a),l=[];for(let c=0;c<s;c++)l.push(vDt(o,a,c,i));r.push(l)}return r}finally{o.close(),o.delete()}}function vDt(t,e,i,o){const n=t.getImageWidth(e,i),r=t.getImageHeight(e,i),a=t.getHasAlpha(),{compressed:s,format:l,basisFormat:c}=H$(o,a),d=t.getImageTranscodedSizeInBytes(e,i,c),u=new Uint8Array(d);if(!t.transcodeImage(u,e,i,c,0,0))throw new Error("failed to start Basis transcoding");return{width:n,height:r,data:u,compressed:s,format:l,hasAlpha:a}}function V$(t,e,i){const o=new t(new Uint8Array(e));try{if(!o.startTranscoding())throw new Error("failed to start KTX2 transcoding");const n=o.getLevels(),r=[];for(let a=0;a<n;a++)r.push(yDt(o,a,i));return[r]}finally{o.close(),o.delete()}}function yDt(t,e,i){const{alphaFlag:o,height:n,width:r}=t.getImageLevelInfo(e,0,0),{compressed:a,format:s,basisFormat:l}=H$(i,o),c=t.getImageTranscodedSizeInBytes(e,0,0,l),d=new Uint8Array(c);if(!t.transcodeImage(d,e,0,0,l,0,-1,-1))throw new Error("Failed to transcode KTX2 image");return{width:r,height:n,data:d,compressed:a,levelSize:c,hasAlpha:o,format:s}}function H$(t,e){let i=t&&t.basis&&t.basis.format;return i==="auto"&&(i=z$()),typeof i=="object"&&(i=e?i.alpha:i.noAlpha),i=i.toLowerCase(),gDt[i]}function z$(){const t=pDt();return t.has("astc")?"astc-4x4":t.has("dxt")?{alpha:"bc3",noAlpha:"bc1"}:t.has("pvrtc")?{alpha:"pvrtc1-4-rgba",noAlpha:"pvrtc1-4-rgb"}:t.has("etc1")?"etc1":t.has("etc2")?"etc2":"rgb565"}const bDt={dataType:null,batchType:null,name:"Basis",id:"basis",module:"textures",version:sDt,worker:!0,extensions:["basis","ktx2"],mimeTypes:["application/octet-stream","image/ktx2"],tests:["sB"],binary:!0,options:{basis:{format:"auto",libraryPath:"libs/",containerFormat:"auto",module:"transcoder"}}},wDt={...bDt,parse:mDt},H1=!0,q$=1735152710,tS=12,b9=8,CDt=1313821514,xDt=5130562,kDt=0,MDt=0,BDt=1;function EDt(t,e=0){return`${String.fromCharCode(t.getUint8(e+0))}${String.fromCharCode(t.getUint8(e+1))}${String.fromCharCode(t.getUint8(e+2))}${String.fromCharCode(t.getUint8(e+3))}`}function PDt(t,e=0,i={}){const o=new DataView(t),{magic:n=q$}=i,r=o.getUint32(e,!1);return r===n||r===q$}function IDt(t,e,i=0,o={}){const n=new DataView(e),r=EDt(n,i+0),a=n.getUint32(i+4,H1),s=n.getUint32(i+8,H1);switch(Object.assign(t,{header:{byteOffset:i,byteLength:s,hasBinChunk:!1},type:r,version:a,json:{},binChunks:[]}),i+=tS,t.version){case 1:return SDt(t,n,i);case 2:return TDt(t,n,i,o={});default:throw new Error(`Invalid GLB version ${t.version}. Only supports version 1 and 2.`)}}function SDt(t,e,i){fc(t.header.byteLength>tS+b9);const o=e.getUint32(i+0,H1),n=e.getUint32(i+4,H1);return i+=b9,fc(n===kDt),iS(t,e,i,o),i+=o,i+=oS(t,e,i,t.header.byteLength),i}function TDt(t,e,i,o){return fc(t.header.byteLength>tS+b9),DDt(t,e,i,o),i+t.header.byteLength}function DDt(t,e,i,o){for(;i+8<=t.header.byteLength;){const n=e.getUint32(i+0,H1),r=e.getUint32(i+4,H1);switch(i+=b9,r){case CDt:iS(t,e,i,n);break;case xDt:oS(t,e,i,n);break;case MDt:o.strict||iS(t,e,i,n);break;case BDt:o.strict||oS(t,e,i,n);break}i+=I3(n,4)}return i}function iS(t,e,i,o){const n=new Uint8Array(e.buffer,i,o),r=new TextDecoder("utf8").decode(n);return t.json=JSON.parse(r),I3(o,4)}function oS(t,e,i,o){return t.header.hasBinChunk=!0,t.binChunks.push({byteOffset:i,byteLength:o,arrayBuffer:e.buffer}),I3(o,4)}function Q$(t,e){if(t.startsWith("data:")||t.startsWith("http:")||t.startsWith("https:"))return t;const i=e.baseUri||e.uri;if(!i)throw new Error(`'baseUri' must be provided to resolve relative url ${t}`);return i.substr(0,i.lastIndexOf("/")+1)+t}const RDt="B9h9z9tFBBBF8fL9gBB9gLaaaaaFa9gEaaaB9gFaFa9gEaaaFaEMcBFFFGGGEIIILF9wFFFLEFBFKNFaFCx/IFMO/LFVK9tv9t9vq95GBt9f9f939h9z9t9f9j9h9s9s9f9jW9vq9zBBp9tv9z9o9v9wW9f9kv9j9v9kv9WvqWv94h919m9mvqBF8Z9tv9z9o9v9wW9f9kv9j9v9kv9J9u9kv94h919m9mvqBGy9tv9z9o9v9wW9f9kv9j9v9kv9J9u9kv949TvZ91v9u9jvBEn9tv9z9o9v9wW9f9kv9j9v9kv69p9sWvq9P9jWBIi9tv9z9o9v9wW9f9kv9j9v9kv69p9sWvq9R919hWBLn9tv9z9o9v9wW9f9kv9j9v9kv69p9sWvq9F949wBKI9z9iqlBOc+x8ycGBM/qQFTa8jUUUUBCU/EBlHL8kUUUUBC9+RKGXAGCFJAI9LQBCaRKAE2BBC+gF9HQBALAEAIJHOAGlAGTkUUUBRNCUoBAG9uC/wgBZHKCUGAKCUG9JyRVAECFJRICBRcGXEXAcAF9PQFAVAFAclAcAVJAF9JyRMGXGXAG9FQBAMCbJHKC9wZRSAKCIrCEJCGrRQANCUGJRfCBRbAIRTEXGXAOATlAQ9PQBCBRISEMATAQJRIGXAS9FQBCBRtCBREEXGXAOAIlCi9PQBCBRISLMANCU/CBJAEJRKGXGXGXGXGXATAECKrJ2BBAtCKZrCEZfIBFGEBMAKhB83EBAKCNJhB83EBSEMAKAI2BIAI2BBHmCKrHYAYCE6HYy86BBAKCFJAICIJAYJHY2BBAmCIrCEZHPAPCE6HPy86BBAKCGJAYAPJHY2BBAmCGrCEZHPAPCE6HPy86BBAKCEJAYAPJHY2BBAmCEZHmAmCE6Hmy86BBAKCIJAYAmJHY2BBAI2BFHmCKrHPAPCE6HPy86BBAKCLJAYAPJHY2BBAmCIrCEZHPAPCE6HPy86BBAKCKJAYAPJHY2BBAmCGrCEZHPAPCE6HPy86BBAKCOJAYAPJHY2BBAmCEZHmAmCE6Hmy86BBAKCNJAYAmJHY2BBAI2BGHmCKrHPAPCE6HPy86BBAKCVJAYAPJHY2BBAmCIrCEZHPAPCE6HPy86BBAKCcJAYAPJHY2BBAmCGrCEZHPAPCE6HPy86BBAKCMJAYAPJHY2BBAmCEZHmAmCE6Hmy86BBAKCSJAYAmJHm2BBAI2BEHICKrHYAYCE6HYy86BBAKCQJAmAYJHm2BBAICIrCEZHYAYCE6HYy86BBAKCfJAmAYJHm2BBAICGrCEZHYAYCE6HYy86BBAKCbJAmAYJHK2BBAICEZHIAICE6HIy86BBAKAIJRISGMAKAI2BNAI2BBHmCIrHYAYCb6HYy86BBAKCFJAICNJAYJHY2BBAmCbZHmAmCb6Hmy86BBAKCGJAYAmJHm2BBAI2BFHYCIrHPAPCb6HPy86BBAKCEJAmAPJHm2BBAYCbZHYAYCb6HYy86BBAKCIJAmAYJHm2BBAI2BGHYCIrHPAPCb6HPy86BBAKCLJAmAPJHm2BBAYCbZHYAYCb6HYy86BBAKCKJAmAYJHm2BBAI2BEHYCIrHPAPCb6HPy86BBAKCOJAmAPJHm2BBAYCbZHYAYCb6HYy86BBAKCNJAmAYJHm2BBAI2BIHYCIrHPAPCb6HPy86BBAKCVJAmAPJHm2BBAYCbZHYAYCb6HYy86BBAKCcJAmAYJHm2BBAI2BLHYCIrHPAPCb6HPy86BBAKCMJAmAPJHm2BBAYCbZHYAYCb6HYy86BBAKCSJAmAYJHm2BBAI2BKHYCIrHPAPCb6HPy86BBAKCQJAmAPJHm2BBAYCbZHYAYCb6HYy86BBAKCfJAmAYJHm2BBAI2BOHICIrHYAYCb6HYy86BBAKCbJAmAYJHK2BBAICbZHIAICb6HIy86BBAKAIJRISFMAKAI8pBB83BBAKCNJAICNJ8pBB83BBAICTJRIMAtCGJRtAECTJHEAS9JQBMMGXAIQBCBRISEMGXAM9FQBANAbJ2BBRtCBRKAfREEXAEANCU/CBJAKJ2BBHTCFrCBATCFZl9zAtJHt86BBAEAGJREAKCFJHKAM9HQBMMAfCFJRfAIRTAbCFJHbAG9HQBMMABAcAG9sJANCUGJAMAG9sTkUUUBpANANCUGJAMCaJAG9sJAGTkUUUBpMAMCBAIyAcJRcAIQBMC9+RKSFMCBC99AOAIlAGCAAGCA9Ly6yRKMALCU/EBJ8kUUUUBAKM+OmFTa8jUUUUBCoFlHL8kUUUUBC9+RKGXAFCE9uHOCtJAI9LQBCaRKAE2BBHNC/wFZC/gF9HQBANCbZHVCF9LQBALCoBJCgFCUFT+JUUUBpALC84Jha83EBALC8wJha83EBALC8oJha83EBALCAJha83EBALCiJha83EBALCTJha83EBALha83ENALha83EBAEAIJC9wJRcAECFJHNAOJRMGXAF9FQBCQCbAVCF6yRSABRECBRVCBRQCBRfCBRICBRKEXGXAMAcuQBC9+RKSEMGXGXAN2BBHOC/vF9LQBALCoBJAOCIrCa9zAKJCbZCEWJHb8oGIRTAb8oGBRtGXAOCbZHbAS9PQBALAOCa9zAIJCbZCGWJ8oGBAVAbyROAb9FRbGXGXAGCG9HQBABAt87FBABCIJAO87FBABCGJAT87FBSFMAEAtjGBAECNJAOjGBAECIJATjGBMAVAbJRVALCoBJAKCEWJHmAOjGBAmATjGIALAICGWJAOjGBALCoBJAKCFJCbZHKCEWJHTAtjGBATAOjGIAIAbJRIAKCFJRKSGMGXGXAbCb6QBAQAbJAbC989zJCFJRQSFMAM1BBHbCgFZROGXGXAbCa9MQBAMCFJRMSFMAM1BFHbCgBZCOWAOCgBZqROGXAbCa9MQBAMCGJRMSFMAM1BGHbCgBZCfWAOqROGXAbCa9MQBAMCEJRMSFMAM1BEHbCgBZCdWAOqROGXAbCa9MQBAMCIJRMSFMAM2BIC8cWAOqROAMCLJRMMAOCFrCBAOCFZl9zAQJRQMGXGXAGCG9HQBABAt87FBABCIJAQ87FBABCGJAT87FBSFMAEAtjGBAECNJAQjGBAECIJATjGBMALCoBJAKCEWJHOAQjGBAOATjGIALAICGWJAQjGBALCoBJAKCFJCbZHKCEWJHOAtjGBAOAQjGIAICFJRIAKCFJRKSFMGXAOCDF9LQBALAIAcAOCbZJ2BBHbCIrHTlCbZCGWJ8oGBAVCFJHtATyROALAIAblCbZCGWJ8oGBAtAT9FHmJHtAbCbZHTyRbAT9FRTGXGXAGCG9HQBABAV87FBABCIJAb87FBABCGJAO87FBSFMAEAVjGBAECNJAbjGBAECIJAOjGBMALAICGWJAVjGBALCoBJAKCEWJHYAOjGBAYAVjGIALAICFJHICbZCGWJAOjGBALCoBJAKCFJCbZCEWJHYAbjGBAYAOjGIALAIAmJCbZHICGWJAbjGBALCoBJAKCGJCbZHKCEWJHOAVjGBAOAbjGIAKCFJRKAIATJRIAtATJRVSFMAVCBAM2BBHYyHTAOC/+F6HPJROAYCbZRtGXGXAYCIrHmQBAOCFJRbSFMAORbALAIAmlCbZCGWJ8oGBROMGXGXAtQBAbCFJRVSFMAbRVALAIAYlCbZCGWJ8oGBRbMGXGXAP9FQBAMCFJRYSFMAM1BFHYCgFZRTGXGXAYCa9MQBAMCGJRYSFMAM1BGHYCgBZCOWATCgBZqRTGXAYCa9MQBAMCEJRYSFMAM1BEHYCgBZCfWATqRTGXAYCa9MQBAMCIJRYSFMAM1BIHYCgBZCdWATqRTGXAYCa9MQBAMCLJRYSFMAMCKJRYAM2BLC8cWATqRTMATCFrCBATCFZl9zAQJHQRTMGXGXAmCb6QBAYRPSFMAY1BBHMCgFZROGXGXAMCa9MQBAYCFJRPSFMAY1BFHMCgBZCOWAOCgBZqROGXAMCa9MQBAYCGJRPSFMAY1BGHMCgBZCfWAOqROGXAMCa9MQBAYCEJRPSFMAY1BEHMCgBZCdWAOqROGXAMCa9MQBAYCIJRPSFMAYCLJRPAY2BIC8cWAOqROMAOCFrCBAOCFZl9zAQJHQROMGXGXAtCb6QBAPRMSFMAP1BBHMCgFZRbGXGXAMCa9MQBAPCFJRMSFMAP1BFHMCgBZCOWAbCgBZqRbGXAMCa9MQBAPCGJRMSFMAP1BGHMCgBZCfWAbqRbGXAMCa9MQBAPCEJRMSFMAP1BEHMCgBZCdWAbqRbGXAMCa9MQBAPCIJRMSFMAPCLJRMAP2BIC8cWAbqRbMAbCFrCBAbCFZl9zAQJHQRbMGXGXAGCG9HQBABAT87FBABCIJAb87FBABCGJAO87FBSFMAEATjGBAECNJAbjGBAECIJAOjGBMALCoBJAKCEWJHYAOjGBAYATjGIALAICGWJATjGBALCoBJAKCFJCbZCEWJHYAbjGBAYAOjGIALAICFJHICbZCGWJAOjGBALCoBJAKCGJCbZCEWJHOATjGBAOAbjGIALAIAm9FAmCb6qJHICbZCGWJAbjGBAIAt9FAtCb6qJRIAKCEJRKMANCFJRNABCKJRBAECSJREAKCbZRKAICbZRIAfCEJHfAF9JQBMMCBC99AMAc6yRKMALCoFJ8kUUUUBAKM/tIFGa8jUUUUBCTlRLC9+RKGXAFCLJAI9LQBCaRKAE2BBC/+FZC/QF9HQBALhB83ENAECFJRKAEAIJC98JREGXAF9FQBGXAGCG6QBEXGXAKAE9JQBC9+bMAK1BBHGCgFZRIGXGXAGCa9MQBAKCFJRKSFMAK1BFHGCgBZCOWAICgBZqRIGXAGCa9MQBAKCGJRKSFMAK1BGHGCgBZCfWAIqRIGXAGCa9MQBAKCEJRKSFMAK1BEHGCgBZCdWAIqRIGXAGCa9MQBAKCIJRKSFMAK2BIC8cWAIqRIAKCLJRKMALCNJAICFZCGWqHGAICGrCBAICFrCFZl9zAG8oGBJHIjGBABAIjGBABCIJRBAFCaJHFQBSGMMEXGXAKAE9JQBC9+bMAK1BBHGCgFZRIGXGXAGCa9MQBAKCFJRKSFMAK1BFHGCgBZCOWAICgBZqRIGXAGCa9MQBAKCGJRKSFMAK1BGHGCgBZCfWAIqRIGXAGCa9MQBAKCEJRKSFMAK1BEHGCgBZCdWAIqRIGXAGCa9MQBAKCIJRKSFMAK2BIC8cWAIqRIAKCLJRKMABAICGrCBAICFrCFZl9zALCNJAICFZCGWqHI8oGBJHG87FBAIAGjGBABCGJRBAFCaJHFQBMMCBC99AKAE6yRKMAKM+lLKFaF99GaG99FaG99GXGXAGCI9HQBAF9FQFEXGXGX9DBBB8/9DBBB+/ABCGJHG1BB+yAB1BBHE+yHI+L+TABCFJHL1BBHK+yHO+L+THN9DBBBB9gHVyAN9DBB/+hANAN+U9DBBBBANAVyHcAc+MHMAECa3yAI+SHIAI+UAcAMAKCa3yAO+SHcAc+U+S+S+R+VHO+U+SHN+L9DBBB9P9d9FQBAN+oRESFMCUUUU94REMAGAE86BBGXGX9DBBB8/9DBBB+/Ac9DBBBB9gyAcAO+U+SHN+L9DBBB9P9d9FQBAN+oRGSFMCUUUU94RGMALAG86BBGXGX9DBBB8/9DBBB+/AI9DBBBB9gyAIAO+U+SHN+L9DBBB9P9d9FQBAN+oRGSFMCUUUU94RGMABAG86BBABCIJRBAFCaJHFQBSGMMAF9FQBEXGXGX9DBBB8/9DBBB+/ABCIJHG8uFB+yAB8uFBHE+yHI+L+TABCGJHL8uFBHK+yHO+L+THN9DBBBB9gHVyAN9DB/+g6ANAN+U9DBBBBANAVyHcAc+MHMAECa3yAI+SHIAI+UAcAMAKCa3yAO+SHcAc+U+S+S+R+VHO+U+SHN+L9DBBB9P9d9FQBAN+oRESFMCUUUU94REMAGAE87FBGXGX9DBBB8/9DBBB+/Ac9DBBBB9gyAcAO+U+SHN+L9DBBB9P9d9FQBAN+oRGSFMCUUUU94RGMALAG87FBGXGX9DBBB8/9DBBB+/AI9DBBBB9gyAIAO+U+SHN+L9DBBB9P9d9FQBAN+oRGSFMCUUUU94RGMABAG87FBABCNJRBAFCaJHFQBMMM/SEIEaE99EaF99GXAF9FQBCBREABRIEXGXGX9D/zI818/AICKJ8uFBHLCEq+y+VHKAI8uFB+y+UHO9DB/+g6+U9DBBB8/9DBBB+/AO9DBBBB9gy+SHN+L9DBBB9P9d9FQBAN+oRVSFMCUUUU94RVMAICIJ8uFBRcAICGJ8uFBRMABALCFJCEZAEqCFWJAV87FBGXGXAKAM+y+UHN9DB/+g6+U9DBBB8/9DBBB+/AN9DBBBB9gy+SHS+L9DBBB9P9d9FQBAS+oRMSFMCUUUU94RMMABALCGJCEZAEqCFWJAM87FBGXGXAKAc+y+UHK9DB/+g6+U9DBBB8/9DBBB+/AK9DBBBB9gy+SHS+L9DBBB9P9d9FQBAS+oRcSFMCUUUU94RcMABALCaJCEZAEqCFWJAc87FBGXGX9DBBU8/AOAO+U+TANAN+U+TAKAK+U+THO9DBBBBAO9DBBBB9gy+R9DB/+g6+U9DBBB8/+SHO+L9DBBB9P9d9FQBAO+oRcSFMCUUUU94RcMABALCEZAEqCFWJAc87FBAICNJRIAECIJREAFCaJHFQBMMM9JBGXAGCGrAF9sHF9FQBEXABAB8oGBHGCNWCN91+yAGCi91CnWCUUU/8EJ+++U84GBABCIJRBAFCaJHFQBMMM9TFEaCBCB8oGUkUUBHFABCEJC98ZJHBjGUkUUBGXGXAB8/BCTWHGuQBCaREABAGlCggEJCTrXBCa6QFMAFREMAEM/lFFFaGXGXAFABqCEZ9FQBABRESFMGXGXAGCT9PQBABRESFMABREEXAEAF8oGBjGBAECIJAFCIJ8oGBjGBAECNJAFCNJ8oGBjGBAECSJAFCSJ8oGBjGBAECTJREAFCTJRFAGC9wJHGCb9LQBMMAGCI9JQBEXAEAF8oGBjGBAFCIJRFAECIJREAGC98JHGCE9LQBMMGXAG9FQBEXAEAF2BB86BBAECFJREAFCFJRFAGCaJHGQBMMABMoFFGaGXGXABCEZ9FQBABRESFMAFCgFZC+BwsN9sRIGXGXAGCT9PQBABRESFMABREEXAEAIjGBAECSJAIjGBAECNJAIjGBAECIJAIjGBAECTJREAGC9wJHGCb9LQBMMAGCI9JQBEXAEAIjGBAECIJREAGC98JHGCE9LQBMMGXAG9FQBEXAEAF86BBAECFJREAGCaJHGQBMMABMMMFBCUNMIT9kBB",LDt="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",_Dt=new Uint8Array([0,97,115,109,1,0,0,0,1,4,1,96,0,0,3,3,2,0,0,5,3,1,0,1,12,1,0,10,22,2,12,0,65,0,65,0,65,0,252,10,0,0,11,7,0,65,0,253,15,26,11]),FDt=new Uint8Array([32,0,65,253,3,1,2,34,4,106,6,5,11,8,7,20,13,33,12,16,128,9,116,64,19,113,127,15,10,21,22,14,255,66,24,54,136,107,18,23,192,26,114,118,132,17,77,101,130,144,27,87,131,44,45,74,156,154,70,167]),ODt={0:"",1:"meshopt_decodeFilterOct",2:"meshopt_decodeFilterQuat",3:"meshopt_decodeFilterExp",NONE:"",OCTAHEDRAL:"meshopt_decodeFilterOct",QUATERNION:"meshopt_decodeFilterQuat",EXPONENTIAL:"meshopt_decodeFilterExp"},UDt={0:"meshopt_decodeVertexBuffer",1:"meshopt_decodeIndexBuffer",2:"meshopt_decodeIndexSequence",ATTRIBUTES:"meshopt_decodeVertexBuffer",TRIANGLES:"meshopt_decodeIndexBuffer",INDICES:"meshopt_decodeIndexSequence"};async function NDt(t,e,i,o,n,r="NONE"){const a=await jDt();zDt(a,a.exports[UDt[n]],t,e,i,o,a.exports[ODt[r||"NONE"]])}let rS;async function jDt(){return rS||(rS=VDt()),rS}async function VDt(){let t=RDt;WebAssembly.validate(_Dt)&&(t=LDt,console.log("Warning: meshopt_decoder is using experimental SIMD support"));const e=await WebAssembly.instantiate(HDt(t),{});return await e.instance.exports.__wasm_call_ctors(),e.instance}function HDt(t){const e=new Uint8Array(t.length);for(let o=0;o<t.length;++o){const n=t.charCodeAt(o);e[o]=n>96?n-71:n>64?n-65:n>47?n+4:n>46?63:62}let i=0;for(let o=0;o<t.length;++o)e[i++]=e[o]<60?FDt[e[o]]:(e[o]-60)*64+e[++o];return e.buffer.slice(0,i)}function zDt(t,e,i,o,n,r,a){const s=t.exports.sbrk,l=o+3&-4,c=s(l*n),d=s(r.length),u=new Uint8Array(t.exports.memory.buffer);u.set(r,d);const h=e(c,o,n,d,r.length);if(h===0&&a&&a(c,l,n),i.set(u.subarray(c,c+o*n)),s(c-s(0)),h!==0)throw new Error(`Malformed buffer data: ${h}`)}const w9="EXT_meshopt_compression",qDt=w9;async function QDt(t,e){const i=new Er(t);if(!e?.gltf?.decompressMeshes||!e.gltf?.loadBuffers)return;const o=[];for(const n of t.json.bufferViews||[])o.push(GDt(i,n));await Promise.all(o),i.removeExtension(w9)}async function GDt(t,e){const i=t.getObjectExtension(e,w9);if(i){const{byteOffset:o=0,byteLength:n=0,byteStride:r,count:a,mode:s,filter:l="NONE",buffer:c}=i,d=t.gltf.buffers[c],u=new Uint8Array(d.arrayBuffer,d.byteOffset+o,n),h=new Uint8Array(t.gltf.buffers[e.buffer].arrayBuffer,e.byteOffset,e.byteLength);await NDt(h,a,r,u,s,l),t.removeObjectExtension(e,w9)}}const KDt=Object.freeze(Object.defineProperty({__proto__:null,decode:QDt,name:qDt},Symbol.toStringTag,{value:"Module"})),z1="EXT_texture_webp",JDt=z1;function ZDt(t,e){const i=new Er(t);if(!zSt("image/webp")){if(i.getRequiredExtensions().includes(z1))throw new Error(`gltf: Required extension ${z1} not supported by browser`);return}const{json:o}=i;for(const n of o.textures||[]){const r=i.getObjectExtension(n,z1);r&&(n.source=r.source),i.removeObjectExtension(n,z1)}i.removeExtension(z1)}const WDt=Object.freeze(Object.defineProperty({__proto__:null,name:JDt,preprocess:ZDt},Symbol.toStringTag,{value:"Module"})),C9="KHR_texture_basisu",YDt=C9;function XDt(t,e){const i=new Er(t),{json:o}=i;for(const n of o.textures||[]){const r=i.getObjectExtension(n,C9);r&&(n.source=r.source,i.removeObjectExtension(n,C9))}i.removeExtension(C9)}const $Dt=Object.freeze(Object.defineProperty({__proto__:null,name:YDt,preprocess:XDt},Symbol.toStringTag,{value:"Module"})),eRt="4.3.3",tRt={dataType:null,batchType:null,name:"Draco",id:"draco",module:"draco",version:eRt,worker:!0,extensions:["drc"],mimeTypes:["application/octet-stream"],binary:!0,tests:["DRACO"],options:{draco:{decoderType:typeof WebAssembly=="object"?"wasm":"js",libraryPath:"libs/",extraAttributes:{},attributeNameEntry:void 0}}};function iRt(t,e,i){const o=K$(e.metadata),n=[],r=oRt(e.attributes);for(const a in t){const s=t[a],l=G$(a,s,r[a]);n.push(l)}if(i){const a=G$("indices",i);n.push(a)}return{fields:n,metadata:o}}function oRt(t){const e={};for(const i in t){const o=t[i];e[o.name||"undefined"]=o}return e}function G$(t,e,i){const o=i?K$(i.metadata):void 0;return lSt(t,e,o)}function K$(t){Object.entries(t);const e={};for(const i in t)e[`${i}.string`]=JSON.stringify(t[i]);return e}const J$={POSITION:"POSITION",NORMAL:"NORMAL",COLOR:"COLOR_0",TEX_COORD:"TEXCOORD_0"},rRt={1:Int8Array,2:Uint8Array,3:Int16Array,4:Uint16Array,5:Int32Array,6:Uint32Array,9:Float32Array},nRt=4;class aRt{draco;decoder;metadataQuerier;constructor(e){this.draco=e,this.decoder=new this.draco.Decoder,this.metadataQuerier=new this.draco.MetadataQuerier}destroy(){this.draco.destroy(this.decoder),this.draco.destroy(this.metadataQuerier)}parseSync(e,i={}){const o=new this.draco.DecoderBuffer;o.Init(new Int8Array(e),e.byteLength),this._disableAttributeTransforms(i);const n=this.decoder.GetEncodedGeometryType(o),r=n===this.draco.TRIANGULAR_MESH?new this.draco.Mesh:new this.draco.PointCloud;try{let a;switch(n){case this.draco.TRIANGULAR_MESH:a=this.decoder.DecodeBufferToMesh(o,r);break;case this.draco.POINT_CLOUD:a=this.decoder.DecodeBufferToPointCloud(o,r);break;default:throw new Error("DRACO: Unknown geometry type.")}if(!a.ok()||!r.ptr){const u=`DRACO decompression failed: ${a.error_msg()}`;throw new Error(u)}const s=this._getDracoLoaderData(r,n,i),l=this._getMeshData(r,s,i),c=sSt(l.attributes),d=iRt(l.attributes,s,l.indices);return{loader:"draco",loaderData:s,header:{vertexCount:r.num_points(),boundingBox:c},...l,schema:d}}finally{this.draco.destroy(o),r&&this.draco.destroy(r)}}_getDracoLoaderData(e,i,o){const n=this._getTopLevelMetadata(e),r=this._getDracoAttributes(e,o);return{geometry_type:i,num_attributes:e.num_attributes(),num_points:e.num_points(),num_faces:e instanceof this.draco.Mesh?e.num_faces():0,metadata:n,attributes:r}}_getDracoAttributes(e,i){const o={};for(let n=0;n<e.num_attributes();n++){const r=this.decoder.GetAttribute(e,n),a=this._getAttributeMetadata(e,n);o[r.unique_id()]={unique_id:r.unique_id(),attribute_type:r.attribute_type(),data_type:r.data_type(),num_components:r.num_components(),byte_offset:r.byte_offset(),byte_stride:r.byte_stride(),normalized:r.normalized(),attribute_index:n,metadata:a};const s=this._getQuantizationTransform(r,i);s&&(o[r.unique_id()].quantization_transform=s);const l=this._getOctahedronTransform(r,i);l&&(o[r.unique_id()].octahedron_transform=l)}return o}_getMeshData(e,i,o){const n=this._getMeshAttributes(i,e,o);if(!n.POSITION)throw new Error("DRACO: No position attribute found.");if(e instanceof this.draco.Mesh)switch(o.topology){case"triangle-strip":return{topology:"triangle-strip",mode:4,attributes:n,indices:{value:this._getTriangleStripIndices(e),size:1}};case"triangle-list":default:return{topology:"triangle-list",mode:5,attributes:n,indices:{value:this._getTriangleListIndices(e),size:1}}}return{topology:"point-list",mode:0,attributes:n}}_getMeshAttributes(e,i,o){const n={};for(const r of Object.values(e.attributes)){const a=this._deduceAttributeName(r,o);r.name=a;const s=this._getAttributeValues(i,r);if(s){const{value:l,size:c}=s;n[a]={value:l,size:c,byteOffset:r.byte_offset,byteStride:r.byte_stride,normalized:r.normalized}}}return n}_getTriangleListIndices(e){const i=e.num_faces()*3,o=i*nRt,n=this.draco._malloc(o);try{return this.decoder.GetTrianglesUInt32Array(e,o,n),new Uint32Array(this.draco.HEAPF32.buffer,n,i).slice()}finally{this.draco._free(n)}}_getTriangleStripIndices(e){const i=new this.draco.DracoInt32Array;try{return this.decoder.GetTriangleStripsFromMesh(e,i),cRt(i)}finally{this.draco.destroy(i)}}_getAttributeValues(e,i){const o=rRt[i.data_type];if(!o)return console.warn(`DRACO: Unsupported attribute type ${i.data_type}`),null;const n=i.num_components,r=e.num_points()*n,a=r*o.BYTES_PER_ELEMENT,s=sRt(this.draco,o);let l;const c=this.draco._malloc(a);try{const d=this.decoder.GetAttribute(e,i.attribute_index);this.decoder.GetAttributeDataArrayForAllPoints(e,d,s,a,c),l=new o(this.draco.HEAPF32.buffer,c,r).slice()}finally{this.draco._free(c)}return{value:l,size:n}}_deduceAttributeName(e,i){const o=e.unique_id;for(const[a,s]of Object.entries(i.extraAttributes||{}))if(s===o)return a;const n=e.attribute_type;for(const a in J$)if(this.draco[a]===n)return J$[a];const r=i.attributeNameEntry||"name";return e.metadata[r]?e.metadata[r].string:`CUSTOM_ATTRIBUTE_${o}`}_getTopLevelMetadata(e){const i=this.decoder.GetMetadata(e);return this._getDracoMetadata(i)}_getAttributeMetadata(e,i){const o=this.decoder.GetAttributeMetadata(e,i);return this._getDracoMetadata(o)}_getDracoMetadata(e){if(!e||!e.ptr)return{};const i={},o=this.metadataQuerier.NumEntries(e);for(let n=0;n<o;n++){const r=this.metadataQuerier.GetEntryName(e,n);i[r]=this._getDracoMetadataField(e,r)}return i}_getDracoMetadataField(e,i){const o=new this.draco.DracoInt32Array;try{this.metadataQuerier.GetIntEntryArray(e,i,o);const n=lRt(o);return{int:this.metadataQuerier.GetIntEntry(e,i),string:this.metadataQuerier.GetStringEntry(e,i),double:this.metadataQuerier.GetDoubleEntry(e,i),intArray:n}}finally{this.draco.destroy(o)}}_disableAttributeTransforms(e){const{quantizedAttributes:i=[],octahedronAttributes:o=[]}=e,n=[...i,...o];for(const r of n)this.decoder.SkipAttributeTransform(this.draco[r])}_getQuantizationTransform(e,i){const{quantizedAttributes:o=[]}=i,n=e.attribute_type();if(o.map(r=>this.decoder[r]).includes(n)){const r=new this.draco.AttributeQuantizationTransform;try{if(r.InitFromAttribute(e))return{quantization_bits:r.quantization_bits(),range:r.range(),min_values:new Float32Array([1,2,3]).map(a=>r.min_value(a))}}finally{this.draco.destroy(r)}}return null}_getOctahedronTransform(e,i){const{octahedronAttributes:o=[]}=i,n=e.attribute_type();if(o.map(r=>this.decoder[r]).includes(n)){const r=new this.draco.AttributeQuantizationTransform;try{if(r.InitFromAttribute(e))return{quantization_bits:r.quantization_bits()}}finally{this.draco.destroy(r)}}return null}}function sRt(t,e){switch(e){case Float32Array:return t.DT_FLOAT32;case Int8Array:return t.DT_INT8;case Int16Array:return t.DT_INT16;case Int32Array:return t.DT_INT32;case Uint8Array:return t.DT_UINT8;case Uint16Array:return t.DT_UINT16;case Uint32Array:return t.DT_UINT32;default:return t.DT_INVALID}}function lRt(t){const e=t.size(),i=new Int32Array(e);for(let o=0;o<e;o++)i[o]=t.GetValue(o);return i}function cRt(t){const e=t.size(),i=new Int32Array(e);for(let o=0;o<e;o++)i[o]=t.GetValue(o);return i}const dRt="1.5.6",uRt="1.4.1",nS=`https://www.gstatic.com/draco/versioned/decoders/${dRt}`,$n={DECODER:"draco_wasm_wrapper.js",DECODER_WASM:"draco_decoder.wasm",FALLBACK_DECODER:"draco_decoder.js",ENCODER:"draco_encoder.js"},aS={[$n.DECODER]:`${nS}/${$n.DECODER}`,[$n.DECODER_WASM]:`${nS}/${$n.DECODER_WASM}`,[$n.FALLBACK_DECODER]:`${nS}/${$n.FALLBACK_DECODER}`,[$n.ENCODER]:`https://raw.githubusercontent.com/google/draco/${uRt}/javascript/${$n.ENCODER}`};let sS;async function hRt(t){const e=t.modules||{};return e.draco3d?sS||=e.draco3d.createDecoderModule({}).then(i=>({draco:i})):sS||=pRt(t),await sS}async function pRt(t){let e,i;switch(t.draco&&t.draco.decoderType){case"js":e=await vh(aS[$n.FALLBACK_DECODER],"draco",t,$n.FALLBACK_DECODER);break;case"wasm":default:[e,i]=await Promise.all([await vh(aS[$n.DECODER],"draco",t,$n.DECODER),await vh(aS[$n.DECODER_WASM],"draco",t,$n.DECODER_WASM)])}return e=e||globalThis.DracoDecoderModule,await fRt(e,i)}function fRt(t,e){const i={};return e&&(i.wasmBinary=e),new Promise(o=>{t({...i,onModuleLoaded:n=>o({draco:n})})})}const ARt={...tRt,parse:gRt};async function gRt(t,e){const{draco:i}=await hRt(e),o=new aRt(i);try{return o.parseSync(t,e?.draco)}finally{o.destroy()}}function mRt(t){const e={};for(const i in t){const o=t[i];if(i!=="indices"){const n=Z$(o);e[i]=n}}return e}function Z$(t){const{buffer:e,size:i,count:o}=vRt(t);return{value:e,size:i,byteOffset:0,count:o,type:P$(i),componentType:A9(e)}}function vRt(t){let e=t,i=1,o=0;return t&&t.value&&(e=t.value,i=t.size||1),e&&(ArrayBuffer.isView(e)||(e=yRt(e,Float32Array)),o=e.length/i),{buffer:e,size:i,count:o}}function yRt(t,e,i=!1){return t?Array.isArray(t)?new e(t):i&&!(t instanceof e)?new e(t):t:null}const Od="KHR_draco_mesh_compression",bRt=Od;function wRt(t,e,i){const o=new Er(t);for(const n of W$(o))o.getObjectExtension(n,Od)}async function CRt(t,e,i){if(!e?.gltf?.decompressMeshes)return;const o=new Er(t),n=[];for(const r of W$(o))o.getObjectExtension(r,Od)&&n.push(kRt(o,r,e,i));await Promise.all(n),o.removeExtension(Od)}function xRt(t,e={}){const i=new Er(t);for(const o of i.json.meshes||[])MRt(o),i.addRequiredExtension(Od)}async function kRt(t,e,i,o){const n=t.getObjectExtension(e,Od);if(!n)return;const r=t.getTypedArrayForBufferView(n.bufferView),a=ZX(r.buffer,r.byteOffset),s={...i};delete s["3d-tiles"];const l=await DX(a,ARt,s,o),c=mRt(l.attributes);for(const[d,u]of Object.entries(c))if(d in e.attributes){const h=e.attributes[d],p=t.getAccessor(h);p?.min&&p?.max&&(u.min=p.min,u.max=p.max)}e.attributes=c,l.indices&&(e.indices=Z$(l.indices)),t.removeObjectExtension(e,Od),BRt(e)}function MRt(t,e,i=4,o,n){if(!o.DracoWriter)throw new Error("options.gltf.DracoWriter not provided");const r=o.DracoWriter.encodeSync({attributes:t}),a=n?.parseSync?.({attributes:t}),s=o._addFauxAttributes(a.attributes),l=o.addBufferView(r);return{primitives:[{attributes:s,mode:i,extensions:{[Od]:{bufferView:l,attributes:s}}}]}}function BRt(t){if(!t.attributes&&Object.keys(t.attributes).length>0)throw new Error("glTF: Empty primitive detected: Draco decompression failure?")}function*W$(t){for(const e of t.json.meshes||[])for(const i of e.primitives)yield i}const ERt=Object.freeze(Object.defineProperty({__proto__:null,decode:CRt,encode:xRt,name:bRt,preprocess:wRt},Symbol.toStringTag,{value:"Module"})),PRt={EPSILON:1e-12,debug:!1,precision:4,printTypes:!1,printDegrees:!1,printRowMajor:!0,_cartographicRadians:!1};globalThis.mathgl=globalThis.mathgl||{config:{...PRt}};const Qa=globalThis.mathgl.config;function IRt(t,{precision:e=Qa.precision}={}){return t=SRt(t),`${parseFloat(t.toPrecision(e))}`}function x9(t){return Array.isArray(t)||ArrayBuffer.isView(t)&&!(t instanceof DataView)}function Y$(t,e,i){const o=Qa.EPSILON;try{if(t===e)return!0;if(x9(t)&&x9(e)){if(t.length!==e.length)return!1;for(let n=0;n<t.length;++n)if(!Y$(t[n],e[n]))return!1;return!0}return t&&t.equals?t.equals(e):e&&e.equals?e.equals(t):typeof t=="number"&&typeof e=="number"?Math.abs(t-e)<=Qa.EPSILON*Math.max(1,Math.abs(t),Math.abs(e)):!1}finally{Qa.EPSILON=o}}function SRt(t){return Math.round(t/Qa.EPSILON)*Qa.EPSILON}class X$ extends Array{clone(){return new this.constructor().copy(this)}fromArray(e,i=0){for(let o=0;o<this.ELEMENTS;++o)this[o]=e[o+i];return this.check()}toArray(e=[],i=0){for(let o=0;o<this.ELEMENTS;++o)e[i+o]=this[o];return e}toObject(e){return e}from(e){return Array.isArray(e)?this.copy(e):this.fromObject(e)}to(e){return e===this?this:x9(e)?this.toArray(e):this.toObject(e)}toTarget(e){return e?this.to(e):this}toFloat32Array(){return new Float32Array(this)}toString(){return this.formatString(Qa)}formatString(e){let i="";for(let o=0;o<this.ELEMENTS;++o)i+=(o>0?", ":"")+IRt(this[o],e);return`${e.printTypes?this.constructor.name:""}[${i}]`}equals(e){if(!e||this.length!==e.length)return!1;for(let i=0;i<this.ELEMENTS;++i)if(!Y$(this[i],e[i]))return!1;return!0}exactEquals(e){if(!e||this.length!==e.length)return!1;for(let i=0;i<this.ELEMENTS;++i)if(this[i]!==e[i])return!1;return!0}negate(){for(let e=0;e<this.ELEMENTS;++e)this[e]=-this[e];return this.check()}lerp(e,i,o){if(o===void 0)return this.lerp(this,e,i);for(let n=0;n<this.ELEMENTS;++n){const r=e[n],a=typeof i=="number"?i:i[n];this[n]=r+o*(a-r)}return this.check()}min(e){for(let i=0;i<this.ELEMENTS;++i)this[i]=Math.min(e[i],this[i]);return this.check()}max(e){for(let i=0;i<this.ELEMENTS;++i)this[i]=Math.max(e[i],this[i]);return this.check()}clamp(e,i){for(let o=0;o<this.ELEMENTS;++o)this[o]=Math.min(Math.max(this[o],e[o]),i[o]);return this.check()}add(...e){for(const i of e)for(let o=0;o<this.ELEMENTS;++o)this[o]+=i[o];return this.check()}subtract(...e){for(const i of e)for(let o=0;o<this.ELEMENTS;++o)this[o]-=i[o];return this.check()}scale(e){if(typeof e=="number")for(let i=0;i<this.ELEMENTS;++i)this[i]*=e;else for(let i=0;i<this.ELEMENTS&&i<e.length;++i)this[i]*=e[i];return this.check()}multiplyByScalar(e){for(let i=0;i<this.ELEMENTS;++i)this[i]*=e;return this.check()}check(){if(Qa.debug&&!this.validate())throw new Error(`math.gl: ${this.constructor.name} some fields set to invalid numbers'`);return this}validate(){let e=this.length===this.ELEMENTS;for(let i=0;i<this.ELEMENTS;++i)e=e&&Number.isFinite(this[i]);return e}sub(e){return this.subtract(e)}setScalar(e){for(let i=0;i<this.ELEMENTS;++i)this[i]=e;return this.check()}addScalar(e){for(let i=0;i<this.ELEMENTS;++i)this[i]+=e;return this.check()}subScalar(e){return this.addScalar(-e)}multiplyScalar(e){for(let i=0;i<this.ELEMENTS;++i)this[i]*=e;return this.check()}divideScalar(e){return this.multiplyByScalar(1/e)}clampScalar(e,i){for(let o=0;o<this.ELEMENTS;++o)this[o]=Math.min(Math.max(this[o],e),i);return this.check()}get elements(){return this}}function TRt(t,e){if(t.length!==e)return!1;for(let i=0;i<t.length;++i)if(!Number.isFinite(t[i]))return!1;return!0}function wa(t){if(!Number.isFinite(t))throw new Error(`Invalid number ${JSON.stringify(t)}`);return t}function DRt(t,e,i=""){if(Qa.debug&&!TRt(t,e))throw new Error(`math.gl: ${i} some fields set to invalid numbers'`);return t}function $$(t,e){if(!t)throw new Error(`math.gl assertion ${e}`)}class RRt extends X${get x(){return this[0]}set x(e){this[0]=wa(e)}get y(){return this[1]}set y(e){this[1]=wa(e)}len(){return Math.sqrt(this.lengthSquared())}magnitude(){return this.len()}lengthSquared(){let e=0;for(let i=0;i<this.ELEMENTS;++i)e+=this[i]*this[i];return e}magnitudeSquared(){return this.lengthSquared()}distance(e){return Math.sqrt(this.distanceSquared(e))}distanceSquared(e){let i=0;for(let o=0;o<this.ELEMENTS;++o){const n=this[o]-e[o];i+=n*n}return wa(i)}dot(e){let i=0;for(let o=0;o<this.ELEMENTS;++o)i+=this[o]*e[o];return wa(i)}normalize(){const e=this.magnitude();if(e!==0)for(let i=0;i<this.ELEMENTS;++i)this[i]/=e;return this.check()}multiply(...e){for(const i of e)for(let o=0;o<this.ELEMENTS;++o)this[o]*=i[o];return this.check()}divide(...e){for(const i of e)for(let o=0;o<this.ELEMENTS;++o)this[o]/=i[o];return this.check()}lengthSq(){return this.lengthSquared()}distanceTo(e){return this.distance(e)}distanceToSquared(e){return this.distanceSquared(e)}getComponent(e){return $$(e>=0&&e<this.ELEMENTS,"index is out of range"),wa(this[e])}setComponent(e,i){return $$(e>=0&&e<this.ELEMENTS,"index is out of range"),this[e]=i,this.check()}addVectors(e,i){return this.copy(e).add(i)}subVectors(e,i){return this.copy(e).subtract(i)}multiplyVectors(e,i){return this.copy(e).multiply(i)}addScaledVector(e,i){return this.add(new this.constructor(e).multiplyScalar(i))}}let k9=typeof Float32Array<"u"?Float32Array:Array;function LRt(){const t=new k9(2);return k9!=Float32Array&&(t[0]=0,t[1]=0),t}function _Rt(t,e,i){const o=e[0],n=e[1];return t[0]=i[0]*o+i[3]*n+i[6],t[1]=i[1]*o+i[4]*n+i[7],t}(function(){const t=LRt();return function(e,i,o,n,r,a){let s,l;for(i||(i=2),o||(o=0),n?l=Math.min(n*i+o,e.length):l=e.length,s=o;s<l;s+=i)t[0]=e[s],t[1]=e[s+1],r(t,t,a),e[s]=t[0],e[s+1]=t[1];return e}})();function FRt(t,e,i){const o=e[0],n=e[1],r=e[2],a=i[3]*o+i[7]*n+i[11]*r||1;return t[0]=(i[0]*o+i[4]*n+i[8]*r)/a,t[1]=(i[1]*o+i[5]*n+i[9]*r)/a,t[2]=(i[2]*o+i[6]*n+i[10]*r)/a,t}function ORt(t,e,i){const o=e[0],n=e[1];return t[0]=i[0]*o+i[2]*n,t[1]=i[1]*o+i[3]*n,t[2]=e[2],t}function URt(t,e,i){const o=e[0],n=e[1],r=e[2];return t[0]=i[0]*o+i[3]*n+i[6]*r,t[1]=i[1]*o+i[4]*n+i[7]*r,t[2]=i[2]*o+i[5]*n+i[8]*r,t[3]=e[3],t}function NRt(){const t=new k9(3);return k9!=Float32Array&&(t[0]=0,t[1]=0,t[2]=0),t}function jRt(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]}function VRt(t,e,i){const o=e[0],n=e[1],r=e[2],a=i[0],s=i[1],l=i[2];return t[0]=n*l-r*s,t[1]=r*a-o*l,t[2]=o*s-n*a,t}function HRt(t,e,i){const o=e[0],n=e[1],r=e[2];let a=i[3]*o+i[7]*n+i[11]*r+i[15];return a=a||1,t[0]=(i[0]*o+i[4]*n+i[8]*r+i[12])/a,t[1]=(i[1]*o+i[5]*n+i[9]*r+i[13])/a,t[2]=(i[2]*o+i[6]*n+i[10]*r+i[14])/a,t}function eee(t,e,i){const o=e[0],n=e[1],r=e[2];return t[0]=o*i[0]+n*i[3]+r*i[6],t[1]=o*i[1]+n*i[4]+r*i[7],t[2]=o*i[2]+n*i[5]+r*i[8],t}function zRt(t,e,i){const o=i[0],n=i[1],r=i[2],a=i[3],s=e[0],l=e[1],c=e[2];let d=n*c-r*l,u=r*s-o*c,h=o*l-n*s,p=n*h-r*u,A=r*d-o*h,f=o*u-n*d;const m=a*2;return d*=m,u*=m,h*=m,p*=2,A*=2,f*=2,t[0]=s+d+p,t[1]=l+u+A,t[2]=c+h+f,t}function qRt(t,e,i,o){const n=[],r=[];return n[0]=e[0]-i[0],n[1]=e[1]-i[1],n[2]=e[2]-i[2],r[0]=n[0],r[1]=n[1]*Math.cos(o)-n[2]*Math.sin(o),r[2]=n[1]*Math.sin(o)+n[2]*Math.cos(o),t[0]=r[0]+i[0],t[1]=r[1]+i[1],t[2]=r[2]+i[2],t}function QRt(t,e,i,o){const n=[],r=[];return n[0]=e[0]-i[0],n[1]=e[1]-i[1],n[2]=e[2]-i[2],r[0]=n[2]*Math.sin(o)+n[0]*Math.cos(o),r[1]=n[1],r[2]=n[2]*Math.cos(o)-n[0]*Math.sin(o),t[0]=r[0]+i[0],t[1]=r[1]+i[1],t[2]=r[2]+i[2],t}function GRt(t,e,i,o){const n=[],r=[];return n[0]=e[0]-i[0],n[1]=e[1]-i[1],n[2]=e[2]-i[2],r[0]=n[0]*Math.cos(o)-n[1]*Math.sin(o),r[1]=n[0]*Math.sin(o)+n[1]*Math.cos(o),r[2]=n[2],t[0]=r[0]+i[0],t[1]=r[1]+i[1],t[2]=r[2]+i[2],t}function KRt(t,e){const i=t[0],o=t[1],n=t[2],r=e[0],a=e[1],s=e[2],l=Math.sqrt((i*i+o*o+n*n)*(r*r+a*a+s*s)),c=l&&jRt(t,e)/l;return Math.acos(Math.min(Math.max(c,-1),1))}(function(){const t=NRt();return function(e,i,o,n,r,a){let s,l;for(i||(i=3),o||(o=0),n?l=Math.min(n*i+o,e.length):l=e.length,s=o;s<l;s+=i)t[0]=e[s],t[1]=e[s+1],t[2]=e[s+2],r(t,t,a),e[s]=t[0],e[s+1]=t[1],e[s+2]=t[2];return e}})();const lS=[0,0,0];let M9,JRt=class eAe extends RRt{static get ZERO(){return M9||(M9=new eAe(0,0,0),Object.freeze(M9)),M9}constructor(e=0,i=0,o=0){super(-0,-0,-0),arguments.length===1&&x9(e)?this.copy(e):(Qa.debug&&(wa(e),wa(i),wa(o)),this[0]=e,this[1]=i,this[2]=o)}set(e,i,o){return this[0]=e,this[1]=i,this[2]=o,this.check()}copy(e){return this[0]=e[0],this[1]=e[1],this[2]=e[2],this.check()}fromObject(e){return Qa.debug&&(wa(e.x),wa(e.y),wa(e.z)),this[0]=e.x,this[1]=e.y,this[2]=e.z,this.check()}toObject(e){return e.x=this[0],e.y=this[1],e.z=this[2],e}get ELEMENTS(){return 3}get z(){return this[2]}set z(e){this[2]=wa(e)}angle(e){return KRt(this,e)}cross(e){return VRt(this,this,e),this.check()}rotateX({radians:e,origin:i=lS}){return qRt(this,this,i,e),this.check()}rotateY({radians:e,origin:i=lS}){return QRt(this,this,i,e),this.check()}rotateZ({radians:e,origin:i=lS}){return GRt(this,this,i,e),this.check()}transform(e){return this.transformAsPoint(e)}transformAsPoint(e){return HRt(this,this,e),this.check()}transformAsVector(e){return FRt(this,this,e),this.check()}transformByMatrix3(e){return eee(this,this,e),this.check()}transformByMatrix2(e){return ORt(this,this,e),this.check()}transformByQuaternion(e){return zRt(this,this,e),this.check()}};class ZRt extends X${toString(){let e="[";if(Qa.printRowMajor){e+="row-major:";for(let i=0;i<this.RANK;++i)for(let o=0;o<this.RANK;++o)e+=` ${this[o*this.RANK+i]}`}else{e+="column-major:";for(let i=0;i<this.ELEMENTS;++i)e+=` ${this[i]}`}return e+="]",e}getElementIndex(e,i){return i*this.RANK+e}getElement(e,i){return this[i*this.RANK+e]}setElement(e,i,o){return this[i*this.RANK+e]=wa(o),this}getColumn(e,i=new Array(this.RANK).fill(-0)){const o=e*this.RANK;for(let n=0;n<this.RANK;++n)i[n]=this[o+n];return i}setColumn(e,i){const o=e*this.RANK;for(let n=0;n<this.RANK;++n)this[o+n]=i[n];return this}}function WRt(t,e){if(t===e){const i=e[1],o=e[2],n=e[5];t[1]=e[3],t[2]=e[6],t[3]=i,t[5]=e[7],t[6]=o,t[7]=n}else t[0]=e[0],t[1]=e[3],t[2]=e[6],t[3]=e[1],t[4]=e[4],t[5]=e[7],t[6]=e[2],t[7]=e[5],t[8]=e[8];return t}function YRt(t,e){const i=e[0],o=e[1],n=e[2],r=e[3],a=e[4],s=e[5],l=e[6],c=e[7],d=e[8],u=d*a-s*c,h=-d*r+s*l,p=c*r-a*l;let A=i*u+o*h+n*p;return A?(A=1/A,t[0]=u*A,t[1]=(-d*o+n*c)*A,t[2]=(s*o-n*a)*A,t[3]=h*A,t[4]=(d*i-n*l)*A,t[5]=(-s*i+n*r)*A,t[6]=p*A,t[7]=(-c*i+o*l)*A,t[8]=(a*i-o*r)*A,t):null}function XRt(t){const e=t[0],i=t[1],o=t[2],n=t[3],r=t[4],a=t[5],s=t[6],l=t[7],c=t[8];return e*(c*r-a*l)+i*(-c*n+a*s)+o*(l*n-r*s)}function tee(t,e,i){const o=e[0],n=e[1],r=e[2],a=e[3],s=e[4],l=e[5],c=e[6],d=e[7],u=e[8],h=i[0],p=i[1],A=i[2],f=i[3],m=i[4],g=i[5],y=i[6],v=i[7],w=i[8];return t[0]=h*o+p*a+A*c,t[1]=h*n+p*s+A*d,t[2]=h*r+p*l+A*u,t[3]=f*o+m*a+g*c,t[4]=f*n+m*s+g*d,t[5]=f*r+m*l+g*u,t[6]=y*o+v*a+w*c,t[7]=y*n+v*s+w*d,t[8]=y*r+v*l+w*u,t}function $Rt(t,e,i){const o=e[0],n=e[1],r=e[2],a=e[3],s=e[4],l=e[5],c=e[6],d=e[7],u=e[8],h=i[0],p=i[1];return t[0]=o,t[1]=n,t[2]=r,t[3]=a,t[4]=s,t[5]=l,t[6]=h*o+p*a+c,t[7]=h*n+p*s+d,t[8]=h*r+p*l+u,t}function eLt(t,e,i){const o=e[0],n=e[1],r=e[2],a=e[3],s=e[4],l=e[5],c=e[6],d=e[7],u=e[8],h=Math.sin(i),p=Math.cos(i);return t[0]=p*o+h*a,t[1]=p*n+h*s,t[2]=p*r+h*l,t[3]=p*a-h*o,t[4]=p*s-h*n,t[5]=p*l-h*r,t[6]=c,t[7]=d,t[8]=u,t}function iee(t,e,i){const o=i[0],n=i[1];return t[0]=o*e[0],t[1]=o*e[1],t[2]=o*e[2],t[3]=n*e[3],t[4]=n*e[4],t[5]=n*e[5],t[6]=e[6],t[7]=e[7],t[8]=e[8],t}function tLt(t,e){const i=e[0],o=e[1],n=e[2],r=e[3],a=i+i,s=o+o,l=n+n,c=i*a,d=o*a,u=o*s,h=n*a,p=n*s,A=n*l,f=r*a,m=r*s,g=r*l;return t[0]=1-u-A,t[3]=d-g,t[6]=h+m,t[1]=d+g,t[4]=1-c-A,t[7]=p-f,t[2]=h-m,t[5]=p+f,t[8]=1-c-u,t}var cS;(function(t){t[t.COL0ROW0=0]="COL0ROW0",t[t.COL0ROW1=1]="COL0ROW1",t[t.COL0ROW2=2]="COL0ROW2",t[t.COL1ROW0=3]="COL1ROW0",t[t.COL1ROW1=4]="COL1ROW1",t[t.COL1ROW2=5]="COL1ROW2",t[t.COL2ROW0=6]="COL2ROW0",t[t.COL2ROW1=7]="COL2ROW1",t[t.COL2ROW2=8]="COL2ROW2"})(cS||(cS={}));const iLt=Object.freeze([1,0,0,0,1,0,0,0,1]);let L3=class extends ZRt{static get IDENTITY(){return rLt()}static get ZERO(){return oLt()}get ELEMENTS(){return 9}get RANK(){return 3}get INDICES(){return cS}constructor(t,...e){super(-0,-0,-0,-0,-0,-0,-0,-0,-0),arguments.length===1&&Array.isArray(t)?this.copy(t):e.length>0?this.copy([t,...e]):this.identity()}copy(t){return this[0]=t[0],this[1]=t[1],this[2]=t[2],this[3]=t[3],this[4]=t[4],this[5]=t[5],this[6]=t[6],this[7]=t[7],this[8]=t[8],this.check()}identity(){return this.copy(iLt)}fromObject(t){return this.check()}fromQuaternion(t){return tLt(this,t),this.check()}set(t,e,i,o,n,r,a,s,l){return this[0]=t,this[1]=e,this[2]=i,this[3]=o,this[4]=n,this[5]=r,this[6]=a,this[7]=s,this[8]=l,this.check()}setRowMajor(t,e,i,o,n,r,a,s,l){return this[0]=t,this[1]=o,this[2]=a,this[3]=e,this[4]=n,this[5]=s,this[6]=i,this[7]=r,this[8]=l,this.check()}determinant(){return XRt(this)}transpose(){return WRt(this,this),this.check()}invert(){return YRt(this,this),this.check()}multiplyLeft(t){return tee(this,t,this),this.check()}multiplyRight(t){return tee(this,this,t),this.check()}rotate(t){return eLt(this,this,t),this.check()}scale(t){return Array.isArray(t)?iee(this,this,t):iee(this,this,[t,t]),this.check()}translate(t){return $Rt(this,this,t),this.check()}transform(t,e){let i;switch(t.length){case 2:i=_Rt(e||[-0,-0],t,this);break;case 3:i=eee(e||[-0,-0,-0],t,this);break;case 4:i=URt(e||[-0,-0,-0,-0],t,this);break;default:throw new Error("Illegal vector")}return DRt(i,t.length),i}transformVector(t,e){return this.transform(t,e)}transformVector2(t,e){return this.transform(t,e)}transformVector3(t,e){return this.transform(t,e)}},B9,E9=null;function oLt(){return B9||(B9=new L3([0,0,0,0,0,0,0,0,0]),Object.freeze(B9)),B9}function rLt(){return E9||(E9=new L3,Object.freeze(E9)),E9}const P9="KHR_texture_transform",nLt=P9,I9=new JRt,aLt=new L3,sLt=new L3;async function lLt(t,e){if(!new Er(t).hasExtension(P9)||!e.gltf?.loadBuffers)return;const i=t.json.materials||[];for(let o=0;o<i.length;o++)cLt(o,t)}function cLt(t,e){const i=e.json.materials?.[t],o=[i?.pbrMetallicRoughness?.baseColorTexture,i?.emissiveTexture,i?.normalTexture,i?.occlusionTexture,i?.pbrMetallicRoughness?.metallicRoughnessTexture],n=[];for(const r of o)r&&r?.extensions?.[P9]&&dLt(e,t,r,n)}function dLt(t,e,i,o){const n=uLt(i,o);if(!n)return;const r=t.json.meshes||[];for(const a of r)for(const s of a.primitives){const l=s.material;Number.isFinite(l)&&e===l&&hLt(t,s,n)}}function uLt(t,e){const i=t.extensions?.[P9],{texCoord:o=0}=t,{texCoord:n=o}=i;if(e.findIndex(([r,a])=>r===o&&a===n)===-1){const r=ALt(i);return o!==n&&(t.texCoord=n),e.push([o,n]),{originalTexCoord:o,texCoord:n,matrix:r}}return null}function hLt(t,e,i){const{originalTexCoord:o,texCoord:n,matrix:r}=i,a=e.attributes[`TEXCOORD_${o}`];if(Number.isFinite(a)){const s=t.json.accessors?.[a];if(s&&s.bufferView){const l=t.json.bufferViews?.[s.bufferView];if(l){const{arrayBuffer:c,byteOffset:d}=t.buffers[l.buffer],u=(d||0)+(s.byteOffset||0)+(l.byteOffset||0),{ArrayType:h,length:p}=JI(s,l),A=B$[s.componentType],f=M$[s.type],m=l.byteStride||A*f,g=new Float32Array(p);for(let y=0;y<s.count;y++){const v=new h(c,u+y*m,2);I9.set(v[0],v[1],1),I9.transformByMatrix3(r),g.set([I9[0],I9[1]],y*f)}o===n?pLt(s,l,t.buffers,g):fLt(n,s,e,t,g)}}}}function pLt(t,e,i,o){t.componentType=5126,i.push({arrayBuffer:o.buffer,byteOffset:0,byteLength:o.buffer.byteLength}),e.buffer=i.length-1,e.byteLength=o.buffer.byteLength,e.byteOffset=0,delete e.byteStride}function fLt(t,e,i,o,n){o.buffers.push({arrayBuffer:n.buffer,byteOffset:0,byteLength:n.buffer.byteLength});const r=o.json.bufferViews;if(!r)return;r.push({buffer:o.buffers.length-1,byteLength:n.buffer.byteLength,byteOffset:0});const a=o.json.accessors;a&&(a.push({bufferView:r?.length-1,byteOffset:0,componentType:5126,count:e.count,type:"VEC2"}),i.attributes[`TEXCOORD_${t}`]=a.length-1)}function ALt(t){const{offset:e=[0,0],rotation:i=0,scale:o=[1,1]}=t,n=new L3().set(1,0,0,0,1,0,e[0],e[1],1),r=aLt.set(Math.cos(i),Math.sin(i),0,-Math.sin(i),Math.cos(i),0,0,0,1),a=sLt.set(o[0],0,0,0,o[1],0,0,0,1);return n.multiplyRight(r).multiplyRight(a)}const gLt=Object.freeze(Object.defineProperty({__proto__:null,decode:lLt,name:nLt},Symbol.toStringTag,{value:"Module"})),bh="KHR_lights_punctual",mLt=bh;async function vLt(t){const e=new Er(t),{json:i}=e,o=e.getExtension(bh);o&&(e.json.lights=o.lights,e.removeExtension(bh));for(const n of i.nodes||[]){const r=e.getObjectExtension(n,bh);r&&(n.light=r.light),e.removeObjectExtension(n,bh)}}async function yLt(t){const e=new Er(t),{json:i}=e;if(i.lights){const o=e.addExtension(bh);ya(!o.lights),o.lights=i.lights,delete i.lights}if(e.json.lights){for(const o of e.json.lights){const n=o.node;e.addObjectExtension(n,bh,o)}delete e.json.lights}}const bLt=Object.freeze(Object.defineProperty({__proto__:null,decode:vLt,encode:yLt,name:mLt},Symbol.toStringTag,{value:"Module"})),_3="KHR_materials_unlit",wLt=_3;async function CLt(t){const e=new Er(t),{json:i}=e;for(const o of i.materials||[])o.extensions&&o.extensions.KHR_materials_unlit&&(o.unlit=!0),e.removeObjectExtension(o,_3);e.removeExtension(_3)}function xLt(t){const e=new Er(t),{json:i}=e;if(e.materials)for(const o of i.materials||[])o.unlit&&(delete o.unlit,e.addObjectExtension(o,_3,{}),e.addExtension(_3))}const kLt=Object.freeze(Object.defineProperty({__proto__:null,decode:CLt,encode:xLt,name:wLt},Symbol.toStringTag,{value:"Module"})),F3="KHR_techniques_webgl",MLt=F3;async function BLt(t){const e=new Er(t),{json:i}=e,o=e.getExtension(F3);if(o){const n=PLt(o,e);for(const r of i.materials||[]){const a=e.getObjectExtension(r,F3);a&&(r.technique=Object.assign({},a,n[a.technique]),r.technique.values=ILt(r.technique,e)),e.removeObjectExtension(r,F3)}e.removeExtension(F3)}}async function ELt(t,e){}function PLt(t,e){const{programs:i=[],shaders:o=[],techniques:n=[]}=t,r=new TextDecoder;return o.forEach(a=>{if(Number.isFinite(a.bufferView))a.code=r.decode(e.getTypedArrayForBufferView(a.bufferView));else throw new Error("KHR_techniques_webgl: no shader code")}),i.forEach(a=>{a.fragmentShader=o[a.fragmentShader],a.vertexShader=o[a.vertexShader]}),n.forEach(a=>{a.program=i[a.program]}),n}function ILt(t,e){const i=Object.assign({},t.values);return Object.keys(t.uniforms||{}).forEach(o=>{t.uniforms[o].value&&!(o in i)&&(i[o]=t.uniforms[o].value)}),Object.keys(i).forEach(o=>{typeof i[o]=="object"&&i[o].index!==void 0&&(i[o].texture=e.getTexture(i[o].index))}),i}const SLt=Object.freeze(Object.defineProperty({__proto__:null,decode:BLt,encode:ELt,name:MLt},Symbol.toStringTag,{value:"Module"})),oee=[HTt,pTt,KDt,WDt,$Dt,ERt,bLt,kLt,SLt,gLt,nDt];function TLt(t,e={},i){const o=oee.filter(n=>ree(n.name,e));for(const n of o)n.preprocess?.(t,e,i)}async function DLt(t,e={},i){const o=oee.filter(n=>ree(n.name,e));for(const n of o)await n.decode?.(t,e,i)}function ree(t,e){const i=e?.gltf?.excludeExtensions||{};return!(t in i&&!i[t])}const dS="KHR_binary_glTF";function RLt(t){const e=new Er(t),{json:i}=e;for(const o of i.images||[]){const n=e.getObjectExtension(o,dS);n&&Object.assign(o,n),e.removeObjectExtension(o,dS)}i.buffers&&i.buffers[0]&&delete i.buffers[0].uri,e.removeExtension(dS)}const nee={accessors:"accessor",animations:"animation",buffers:"buffer",bufferViews:"bufferView",images:"image",materials:"material",meshes:"mesh",nodes:"node",samplers:"sampler",scenes:"scene",skins:"skin",textures:"texture"},LLt={accessor:"accessors",animations:"animation",buffer:"buffers",bufferView:"bufferViews",image:"images",material:"materials",mesh:"meshes",node:"nodes",sampler:"samplers",scene:"scenes",skin:"skins",texture:"textures"};class _Lt{idToIndexMap={animations:{},accessors:{},buffers:{},bufferViews:{},images:{},materials:{},meshes:{},nodes:{},samplers:{},scenes:{},skins:{},textures:{}};json;normalize(e,i){this.json=e.json;const o=e.json;switch(o.asset&&o.asset.version){case"2.0":return;case void 0:case"1.0":break;default:console.warn(`glTF: Unknown version ${o.asset.version}`);return}if(!i.normalize)throw new Error("glTF v1 is not supported.");console.warn("Converting glTF v1 to glTF v2 format. This is experimental and may fail."),this._addAsset(o),this._convertTopLevelObjectsToArrays(o),RLt(e),this._convertObjectIdsToArrayIndices(o),this._updateObjects(o),this._updateMaterial(o)}_addAsset(e){e.asset=e.asset||{},e.asset.version="2.0",e.asset.generator=e.asset.generator||"Normalized to glTF 2.0 by loaders.gl"}_convertTopLevelObjectsToArrays(e){for(const i in nee)this._convertTopLevelObjectToArray(e,i)}_convertTopLevelObjectToArray(e,i){const o=e[i];if(!(!o||Array.isArray(o))){e[i]=[];for(const n in o){const r=o[n];r.id=r.id||n;const a=e[i].length;e[i].push(r),this.idToIndexMap[i][n]=a}}}_convertObjectIdsToArrayIndices(e){for(const i in nee)this._convertIdsToIndices(e,i);"scene"in e&&(e.scene=this._convertIdToIndex(e.scene,"scene"));for(const i of e.textures)this._convertTextureIds(i);for(const i of e.meshes)this._convertMeshIds(i);for(const i of e.nodes)this._convertNodeIds(i);for(const i of e.scenes)this._convertSceneIds(i)}_convertTextureIds(e){e.source&&(e.source=this._convertIdToIndex(e.source,"image"))}_convertMeshIds(e){for(const i of e.primitives){const{attributes:o,indices:n,material:r}=i;for(const a in o)o[a]=this._convertIdToIndex(o[a],"accessor");n&&(i.indices=this._convertIdToIndex(n,"accessor")),r&&(i.material=this._convertIdToIndex(r,"material"))}}_convertNodeIds(e){e.children&&(e.children=e.children.map(i=>this._convertIdToIndex(i,"node"))),e.meshes&&(e.meshes=e.meshes.map(i=>this._convertIdToIndex(i,"mesh")))}_convertSceneIds(e){e.nodes&&(e.nodes=e.nodes.map(i=>this._convertIdToIndex(i,"node")))}_convertIdsToIndices(e,i){e[i]||(console.warn(`gltf v1: json doesn't contain attribute ${i}`),e[i]=[]);for(const o of e[i])for(const n in o){const r=o[n],a=this._convertIdToIndex(r,n);o[n]=a}}_convertIdToIndex(e,i){const o=LLt[i];if(o in this.idToIndexMap){const n=this.idToIndexMap[o][e];if(!Number.isFinite(n))throw new Error(`gltf v1: failed to resolve ${i} with id ${e}`);return n}return e}_updateObjects(e){for(const i of this.json.buffers)delete i.type}_updateMaterial(e){for(const i of e.materials){i.pbrMetallicRoughness={baseColorFactor:[1,1,1,1],metallicFactor:1,roughnessFactor:1};const o=i.values?.tex||i.values?.texture2d_0||i.values?.diffuseTex,n=e.textures.findIndex(r=>r.id===o);n!==-1&&(i.pbrMetallicRoughness.baseColorTexture={index:n})}}}function FLt(t,e={}){return new _Lt().normalize(t,e)}async function OLt(t,e,i=0,o,n){return ULt(t,e,i,o),FLt(t,{normalize:o?.gltf?.normalize}),TLt(t,o,n),o?.gltf?.loadBuffers&&t.json.buffers&&await NLt(t,o,n),o?.gltf?.loadImages&&await jLt(t,o,n),await DLt(t,o,n),t}function ULt(t,e,i,o){if(o.uri&&(t.baseUri=o.uri),e instanceof ArrayBuffer&&!PDt(e,i,o)&&(e=new TextDecoder().decode(e)),typeof e=="string")t.json=WPt(e);else if(e instanceof ArrayBuffer){const a={};i=IDt(a,e,i,o.glb),ya(a.type==="glTF",`Invalid GLB magic string ${a.type}`),t._glb=a,t.json=a.json}else ya(!1,"GLTF: must be ArrayBuffer or string");const n=t.json.buffers||[];if(t.buffers=new Array(n.length).fill(null),t._glb&&t._glb.header.hasBinChunk){const{binChunks:a}=t._glb;t.buffers[0]={arrayBuffer:a[0].arrayBuffer,byteOffset:a[0].byteOffset,byteLength:a[0].byteLength}}const r=t.json.images||[];t.images=new Array(r.length).fill({})}async function NLt(t,e,i){const o=t.json.buffers||[];for(let n=0;n<o.length;++n){const r=o[n];if(r.uri){const{fetch:a}=i;ya(a);const s=Q$(r.uri,e),l=await(await i?.fetch?.(s))?.arrayBuffer?.();t.buffers[n]={arrayBuffer:l,byteOffset:0,byteLength:l.byteLength},delete r.uri}else t.buffers[n]===null&&(t.buffers[n]={arrayBuffer:new ArrayBuffer(r.byteLength),byteOffset:0,byteLength:r.byteLength})}}async function jLt(t,e,i){const o=VLt(t),n=t.json.images||[],r=[];for(const a of o)r.push(HLt(t,n[a],a,e,i));return await Promise.all(r)}function VLt(t){const e=new Set,i=t.json.textures||[];for(const o of i)o.source!==void 0&&e.add(o.source);return Array.from(e).sort()}async function HLt(t,e,i,o,n){let r;if(e.uri&&!e.hasOwnProperty("bufferView")){const s=Q$(e.uri,o),{fetch:l}=n;r=await(await l(s)).arrayBuffer(),e.bufferView={data:r}}if(Number.isFinite(e.bufferView)){const s=XSt(t.json,t.buffers,e.bufferView);r=ZX(s.buffer,s.byteOffset,s.byteLength)}ya(r,"glTF image has no data");let a=await DX(r,[HSt,wDt],{...o,mimeType:e.mimeType,basis:o.basis||{format:z$()}},n);a&&a[0]&&(a={compressed:!0,mipmaps:!1,width:a[0].width,height:a[0].height,data:a[0]}),t.images=t.images||[],t.images[i]=a}const uS={dataType:null,batchType:null,name:"glTF",id:"gltf",module:"gltf",version:aDt,extensions:["gltf","glb"],mimeTypes:["model/gltf+json","model/gltf-binary"],text:!0,binary:!0,tests:["glTF"],parse:zLt,options:{gltf:{normalize:!0,loadBuffers:!0,loadImages:!0,decompressMeshes:!0},log:console}};async function zLt(t,e={},i){e={...uS.options,...e},e.gltf={...uS.options.gltf,...e.gltf};const{byteOffset:o=0}=e;return await OLt({},t,o,e,i)}const qLt={SCALAR:1,VEC2:2,VEC3:3,VEC4:4,MAT2:4,MAT3:9,MAT4:16},QLt={5120:1,5121:1,5122:2,5123:2,5125:4,5126:4},Ga={TEXTURE_MAG_FILTER:10240,TEXTURE_MIN_FILTER:10241,TEXTURE_WRAP_S:10242,TEXTURE_WRAP_T:10243,REPEAT:10497,LINEAR:9729,NEAREST_MIPMAP_LINEAR:9986},GLt={magFilter:Ga.TEXTURE_MAG_FILTER,minFilter:Ga.TEXTURE_MIN_FILTER,wrapS:Ga.TEXTURE_WRAP_S,wrapT:Ga.TEXTURE_WRAP_T},KLt={[Ga.TEXTURE_MAG_FILTER]:Ga.LINEAR,[Ga.TEXTURE_MIN_FILTER]:Ga.NEAREST_MIPMAP_LINEAR,[Ga.TEXTURE_WRAP_S]:Ga.REPEAT,[Ga.TEXTURE_WRAP_T]:Ga.REPEAT};function JLt(){return{id:"default-sampler",parameters:KLt}}function ZLt(t){return QLt[t]}function WLt(t){return qLt[t]}class YLt{baseUri="";jsonUnprocessed;json;buffers=[];images=[];postProcess(e,i={}){const{json:o,buffers:n=[],images:r=[]}=e,{baseUri:a=""}=e;return ya(o),this.baseUri=a,this.buffers=n,this.images=r,this.jsonUnprocessed=o,this.json=this._resolveTree(e.json,i),this.json}_resolveTree(e,i={}){const o={...e};return this.json=o,e.bufferViews&&(o.bufferViews=e.bufferViews.map((n,r)=>this._resolveBufferView(n,r))),e.images&&(o.images=e.images.map((n,r)=>this._resolveImage(n,r))),e.samplers&&(o.samplers=e.samplers.map((n,r)=>this._resolveSampler(n,r))),e.textures&&(o.textures=e.textures.map((n,r)=>this._resolveTexture(n,r))),e.accessors&&(o.accessors=e.accessors.map((n,r)=>this._resolveAccessor(n,r))),e.materials&&(o.materials=e.materials.map((n,r)=>this._resolveMaterial(n,r))),e.meshes&&(o.meshes=e.meshes.map((n,r)=>this._resolveMesh(n,r))),e.nodes&&(o.nodes=e.nodes.map((n,r)=>this._resolveNode(n,r)),o.nodes=o.nodes.map((n,r)=>this._resolveNodeChildren(n))),e.skins&&(o.skins=e.skins.map((n,r)=>this._resolveSkin(n,r))),e.scenes&&(o.scenes=e.scenes.map((n,r)=>this._resolveScene(n,r))),typeof this.json.scene=="number"&&o.scenes&&(o.scene=o.scenes[this.json.scene]),o}getScene(e){return this._get(this.json.scenes,e)}getNode(e){return this._get(this.json.nodes,e)}getSkin(e){return this._get(this.json.skins,e)}getMesh(e){return this._get(this.json.meshes,e)}getMaterial(e){return this._get(this.json.materials,e)}getAccessor(e){return this._get(this.json.accessors,e)}getCamera(e){return this._get(this.json.cameras,e)}getTexture(e){return this._get(this.json.textures,e)}getSampler(e){return this._get(this.json.samplers,e)}getImage(e){return this._get(this.json.images,e)}getBufferView(e){return this._get(this.json.bufferViews,e)}getBuffer(e){return this._get(this.json.buffers,e)}_get(e,i){if(typeof i=="object")return i;const o=e&&e[i];return o||console.warn(`glTF file error: Could not find ${e}[${i}]`),o}_resolveScene(e,i){return{...e,id:e.id||`scene-${i}`,nodes:(e.nodes||[]).map(o=>this.getNode(o))}}_resolveNode(e,i){const o={...e,id:e?.id||`node-${i}`};return e.mesh!==void 0&&(o.mesh=this.getMesh(e.mesh)),e.camera!==void 0&&(o.camera=this.getCamera(e.camera)),e.skin!==void 0&&(o.skin=this.getSkin(e.skin)),e.meshes!==void 0&&e.meshes.length&&(o.mesh=e.meshes.reduce((n,r)=>{const a=this.getMesh(r);return n.id=a.id,n.primitives=n.primitives.concat(a.primitives),n},{primitives:[]})),o}_resolveNodeChildren(e){return e.children&&(e.children=e.children.map(i=>this.getNode(i))),e}_resolveSkin(e,i){const o=typeof e.inverseBindMatrices=="number"?this.getAccessor(e.inverseBindMatrices):void 0;return{...e,id:e.id||`skin-${i}`,inverseBindMatrices:o}}_resolveMesh(e,i){const o={...e,id:e.id||`mesh-${i}`,primitives:[]};return e.primitives&&(o.primitives=e.primitives.map(n=>{const r={...n,attributes:{},indices:void 0,material:void 0},a=n.attributes;for(const s in a)r.attributes[s]=this.getAccessor(a[s]);return n.indices!==void 0&&(r.indices=this.getAccessor(n.indices)),n.material!==void 0&&(r.material=this.getMaterial(n.material)),r})),o}_resolveMaterial(e,i){const o={...e,id:e.id||`material-${i}`};if(o.normalTexture&&(o.normalTexture={...o.normalTexture},o.normalTexture.texture=this.getTexture(o.normalTexture.index)),o.occlusionTexture&&(o.occlusionTexture={...o.occlusionTexture},o.occlusionTexture.texture=this.getTexture(o.occlusionTexture.index)),o.emissiveTexture&&(o.emissiveTexture={...o.emissiveTexture},o.emissiveTexture.texture=this.getTexture(o.emissiveTexture.index)),o.emissiveFactor||(o.emissiveFactor=o.emissiveTexture?[1,1,1]:[0,0,0]),o.pbrMetallicRoughness){o.pbrMetallicRoughness={...o.pbrMetallicRoughness};const n=o.pbrMetallicRoughness;n.baseColorTexture&&(n.baseColorTexture={...n.baseColorTexture},n.baseColorTexture.texture=this.getTexture(n.baseColorTexture.index)),n.metallicRoughnessTexture&&(n.metallicRoughnessTexture={...n.metallicRoughnessTexture},n.metallicRoughnessTexture.texture=this.getTexture(n.metallicRoughnessTexture.index))}return o}_resolveAccessor(e,i){const o=ZLt(e.componentType),n=WLt(e.type),r=o*n,a={...e,id:e.id||`accessor-${i}`,bytesPerComponent:o,components:n,bytesPerElement:r,value:void 0,bufferView:void 0,sparse:void 0};if(e.bufferView!==void 0&&(a.bufferView=this.getBufferView(e.bufferView)),a.bufferView){const s=a.bufferView.buffer,{ArrayType:l,byteLength:c}=JI(a,a.bufferView),d=(a.bufferView.byteOffset||0)+(a.byteOffset||0)+s.byteOffset;let u=s.arrayBuffer.slice(d,d+c);a.bufferView.byteStride&&(u=this._getValueFromInterleavedBuffer(s,d,a.bufferView.byteStride,a.bytesPerElement,a.count)),a.value=new l(u)}return a}_getValueFromInterleavedBuffer(e,i,o,n,r){const a=new Uint8Array(r*n);for(let s=0;s<r;s++){const l=i+s*o;a.set(new Uint8Array(e.arrayBuffer.slice(l,l+n)),s*n)}return a.buffer}_resolveTexture(e,i){return{...e,id:e.id||`texture-${i}`,sampler:typeof e.sampler=="number"?this.getSampler(e.sampler):JLt(),source:typeof e.source=="number"?this.getImage(e.source):void 0}}_resolveSampler(e,i){const o={id:e.id||`sampler-${i}`,...e,parameters:{}};for(const n in o){const r=this._enumSamplerParameter(n);r!==void 0&&(o.parameters[r]=o[n])}return o}_enumSamplerParameter(e){return GLt[e]}_resolveImage(e,i){const o={...e,id:e.id||`image-${i}`,image:null,bufferView:e.bufferView!==void 0?this.getBufferView(e.bufferView):void 0},n=this.images[i];return n&&(o.image=n),o}_resolveBufferView(e,i){const o=e.buffer,n=this.buffers[o].arrayBuffer;let r=this.buffers[o].byteOffset||0;return e.byteOffset&&(r+=e.byteOffset),{id:`bufferView-${i}`,...e,buffer:this.buffers[o],data:new Uint8Array(n,r,e.byteLength)}}_resolveCamera(e,i){const o={...e,id:e.id||`camera-${i}`};return o.perspective,o.orthographic,o}}function XLt(t,e){return new YLt().postProcess(t,e)}class $Lt{constructor(e){}load(e,i,o,n,r,a,s){n=n||{},e_t(e,i,o,n,r,function(){uo.scheduleTask(function(){r.scene.fire("modelLoaded",r.id),r.fire("loaded",!0,!1)}),a&&a()},function(l){e.error(l),s&&s(l),r.fire("error",l)})}parse(e,i,o,n,r,a,s){n=n||{},hS(e,"",i,o,n,r,function(){r.scene.fire("modelLoaded",r.id),r.fire("loaded",!0,!1),a&&a()},function(l){r.error(l),r.fire("error",l),s&&s(l)})}}function e_t(t,e,i,o,n,r,a){const s=t.viewer.scene.canvas.spinner;s.processes++,e.split(".").pop()==="glb"?t.dataSource.getGLB(e,l=>{o.basePath=aee(e),hS(t,e,l,i,o,n,r,a),s.processes--},l=>{s.processes--,a(l)}):t.dataSource.getGLTF(e,l=>{o.basePath=aee(e),hS(t,e,l,i,o,n,r,a),s.processes--},l=>{s.processes--,a(l)})}function aee(t){const e=t.lastIndexOf("/");return e!==0?t.substring(0,e+1):""}function hS(t,e,i,o,n,r,a,s){const l=t.viewer.scene.canvas.spinner;l.processes++,VI(i,uS,{baseUri:n.basePath}).then(c=>{const d=XLt(c),u={entityId:n.entityId,autoMetaModel:n.autoMetaModel,globalizeObjectIds:n.globalizeObjectIds,metaObjects:[],loadBuffer:n.loadBuffer,basePath:n.basePath,handlenode:n.handlenode,backfaces:!!n.backfaces,gltfData:d,scene:r.scene,plugin:t,sceneModel:r,numObjects:0,nextId:0};t_t(u),o_t(u),n.autoMetaModel&&u.metaObjects.push({id:r.id,type:"Default",name:r.id}),a_t(u),r.finalize(),n.autoMetaModel&&t.viewer.metaScene.createMetaModel(r.id,{metaObjects:u.metaObjects}),l.processes--,a()}).catch(c=>{s&&s(c)})}function t_t(t){const e=t.gltfData.textures;if(e)for(let i=0,o=e.length;i<o;i++)i_t(t,e[i])}function i_t(t,e){if(!e.source||!e.source.image)return;const i=`texture-${t.nextId++}`;let o=f1;switch(e.sampler.minFilter){case 9728:o=dh;break;case 9729:o=cn;break;case 9984:o=Kv;break;case 9985:o=Jv;break;case 9986:o=f1;break;case 9987:o=A1;break}let n=cn;switch(e.sampler.magFilter){case 9728:n=dh;break;case 9729:n=cn;break}let r=wo;switch(e.sampler.wrapS){case 33071:r=ln;break;case 33648:r=nc;break;case 10497:r=wo;break}let a=wo;switch(e.sampler.wrapT){case 33071:a=ln;break;case 33648:a=nc;break;case 10497:a=wo;break}let s=wo;switch(e.sampler.wrapR){case 33071:s=ln;break;case 33648:s=nc;break;case 10497:s=wo;break}t.sceneModel.createTexture({id:i,image:e.source.image,flipY:!!e.flipY,minFilter:o,magFilter:n,wrapS:r,wrapT:a,wrapR:s,encoding:ho}),e._textureId=i}function o_t(t){const e=t.gltfData.materials;if(e)for(let i=0,o=e.length;i<o;i++){const n=e[i];n._textureSetId=r_t(t,n),n._attributes=n_t(t,n)}}function r_t(t,e){const i={};switch(e.normalTexture&&(i.normalTextureId=e.normalTexture.texture._textureId),e.occlusionTexture&&(i.occlusionTextureId=e.occlusionTexture.texture._textureId),e.emissiveTexture&&(i.emissiveTextureId=e.emissiveTexture.texture._textureId),e.alphaMode){case"OPAQUE":break;case"MASK":const r=e.alphaCutoff;i.alphaCutoff=r!==void 0?r:.5;break}const o=e.pbrMetallicRoughness;if(e.pbrMetallicRoughness){const r=e.pbrMetallicRoughness,a=r.baseColorTexture||r.colorTexture;a&&(a.texture?i.colorTextureId=a.texture._textureId:i.colorTextureId=t.gltfData.textures[a.index]._textureId),o.metallicRoughnessTexture&&(i.metallicRoughnessTextureId=o.metallicRoughnessTexture.texture._textureId)}const n=e.extensions;if(n){const r=n.KHR_materials_pbrSpecularGlossiness;if(r){r.specularTexture;const a=r.specularColorTexture;a!=null&&(i.colorTextureId=t.gltfData.textures[a.index]._textureId)}}return i.normalTextureId!==void 0||i.occlusionTextureId!==void 0||i.emissiveTextureId!==void 0||i.colorTextureId!==void 0||i.metallicRoughnessTextureId!==void 0?(i.id=`textureSet-${t.nextId++};`,t.sceneModel.createTextureSet(i),i.id):null}function n_t(t,e){const i=e.extensions,o={color:new Float32Array([1,1,1,1]),opacity:1,metallic:0,roughness:1,doubleSided:!0};if(i){const r=i.KHR_materials_pbrSpecularGlossiness;if(r){const s=r.diffuseFactor;s!=null&&o.color.set(s)}const a=i.KHR_materials_common;if(a){const s=a.technique,l=a.values||{},c=s==="BLINN",d=s==="PHONG",u=s==="LAMBERT",h=l.diffuse;h&&(c||d||u)&&(mt.isString(h)||o.color.set(h));const p=l.transparency;p!=null&&(o.opacity=p);const A=l.transparent;A!=null&&(o.opacity=A)}}const n=e.pbrMetallicRoughness;if(n){const r=n.baseColorFactor;r&&(o.color[0]=r[0],o.color[1]=r[1],o.color[2]=r[2],o.opacity=r[3]);const a=n.metallicFactor;a!=null&&(o.metallic=a);const s=n.roughnessFactor;s!=null&&(o.roughness=s)}return o.doubleSided=e.doubleSided!==!1,o}function a_t(t){const e=t.gltfData,i=e.scene||e.scenes[0];if(!i){c_t(t,"glTF has no default scene");return}const o=i.nodes;if(!o)return;(function a(s){s.forEach(l=>{const c=l.mesh;c&&(c.instances||=0,c.instances+=1),l.children&&a(l.children)})})(o);const n=[];let r=null;(function a(s,l,c){s.forEach(d=>{const u=d.name;let h=u!=null&&u||l===0&&"entity-"+t.nextId++;if(h){for(;t.sceneModel.objects[h];)h="entity-"+t.nextId++;n.push(r),r=[]}const p=s_t(d,c);if(d.mesh&&l_t(d,t,p,r),d.children&&a(d.children,l+1,p),h){if(r.length>0){const A=t.globalizeObjectIds?C.globalizeObjectId(t.sceneModel.id,h):h;t.sceneModel.createEntity({id:A,meshIds:r,isObject:!0}),t.autoMetaModel&&t.metaObjects.push({id:A,type:"Default",name:A,parent:t.sceneModel.id})}r=n.pop()}})})(o,0,null)}function s_t(t,e){let i;return t.matrix&&(i=t.matrix,e?e=C.mulMat4(e,i,C.mat4()):e=i),t.translation&&(i=C.translationMat4v(t.translation),e?e=C.mulMat4(e,i,C.mat4()):e=i),t.rotation&&(i=C.quaternionToMat4(t.rotation),e?e=C.mulMat4(e,i,C.mat4()):e=i),t.scale&&(i=C.scalingMat4v(t.scale),e?e=C.mulMat4(e,i,C.mat4()):e=i),e}function l_t(t,e,i,o){const n=t.mesh;if(!n)return;const r=n.primitives.length;if(r>0)for(let a=0;a<r;a++){const s=n.primitives[a];if(s.mode<4)continue;const l={id:e.sceneModel.id+"."+e.numObjects++},c=s.material;c?(l.textureSetId=c._textureSetId,l.color=c._attributes.color,l.opacity=c._attributes.opacity,l.metallic=c._attributes.metallic,l.roughness=c._attributes.roughness):(l.color=new Float32Array([1,1,1]),l.opacity=1);const d=e.backfaces!==!1||c&&c.doubleSided!==!1;switch(s.mode){case 0:l.primitive="points";break;case 1:l.primitive="lines";break;case 2:l.primitive="lines";break;case 3:l.primitive="lines";break;case 4:l.primitive=d?"triangles":"solid";break;case 5:l.primitive=d?"triangles":"solid";break;case 6:l.primitive=d?"triangles":"solid";break;default:l.primitive=d?"triangles":"solid"}const u=s.attributes.POSITION;if(!u)continue;l.localPositions=u.value,l.positions=new Float64Array(l.localPositions.length),s.attributes.NORMAL&&(l.normals=s.attributes.NORMAL.value),s.attributes.TEXCOORD_0&&(l.uv=s.attributes.TEXCOORD_0.value),s.indices&&(l.indices=s.indices.value),i?C.transformPositions3(i,l.localPositions,l.positions):l.positions.set(l.localPositions);const h=C.vec3();o7(l.positions,l.positions,h)&&(l.origin=h),e.sceneModel.createMesh(l),o.push(l.id)}}function c_t(t,e){t.plugin.error(e)}const see={DEFAULT:{}};class pS extends Ha{constructor(e,i={}){super("GLTFLoader",e,i),this._sceneModelLoader=new $Lt(this,i),this.dataSource=i.dataSource,this.objectDefaults=i.objectDefaults}set dataSource(e){this._dataSource=e||new TX}get dataSource(){return this._dataSource}set objectDefaults(e){this._objectDefaults=e||see}get objectDefaults(){return this._objectDefaults}load(e={}){e.id&&this.viewer.scene.components[e.id]&&(this.error("Component with this ID already exists in viewer: "+e.id+" - will autogenerate this ID"),delete e.id);const i=new g3(this.viewer.scene,mt.apply(e,{isModel:!0,dtxEnabled:e.dtxEnabled})),o=i.id;if(!e.src&&!e.gltf)return this.error("load() param expected: src or gltf"),i;if(e.metaModelSrc||e.metaModelJSON){const n=r=>{this.viewer.metaScene.createMetaModel(o,r,{}),this.viewer.scene.canvas.spinner.processes--,e.src?this._sceneModelLoader.load(this,e.src,r,e,i):this._sceneModelLoader.parse(this,e.gltf,r,e,i)};if(e.metaModelSrc){const r=e.metaModelSrc;this.viewer.scene.canvas.spinner.processes++,this._dataSource.getMetaModel(r,a=>{this.viewer.scene.canvas.spinner.processes--,n(a)},a=>{this.error(`load(): Failed to load model metadata for model '${o} from '${r}' - ${a}`),this.viewer.scene.canvas.spinner.processes--})}else e.metaModelJSON&&n(e.metaModelJSON)}else e.src?this._sceneModelLoader.load(this,e.src,null,e,i):this._sceneModelLoader.parse(this,e.gltf,null,e,i);return i.once("destroyed",()=>{this.viewer.metaScene.destroyMetaModel(o)}),i}destroy(){super.destroy()}}function d_t(t,e,i={}){const o="lightgrey",n=i.hoverColor||"rgba(0,0,0,0.4)",r=i.textColor||"black",a=i.canvasElement||document.body,s=500,l=s+s/3,c=l/24,d=[{boundary:[6,6,6,6],color:i.frontColor||i.color||"#55FF55"},{boundary:[18,6,6,6],color:i.backColor||i.color||"#55FF55"},{boundary:[12,6,6,6],color:i.rightColor||i.color||"#FF5555"},{boundary:[0,6,6,6],color:i.leftColor||i.color||"#FF5555"},{boundary:[6,0,6,6],color:i.topColor||i.color||"#7777FF"},{boundary:[6,12,6,6],color:i.bottomColor||i.color||"#7777FF"}],u=[{label:"NavCube.front",boundaries:[[7,7,4,4]],dir:[0,1,0],up:[0,0,1]},{label:"NavCube.back",boundaries:[[19,7,4,4]],dir:[0,-1,0],up:[0,0,1]},{label:"NavCube.right",boundaries:[[13,7,4,4]],dir:[-1,0,0],up:[0,0,1]},{label:"NavCube.left",boundaries:[[1,7,4,4]],dir:[1,0,0],up:[0,0,1]},{label:"NavCube.top",boundaries:[[7,1,4,4]],dir:[0,0,-1],up:[0,1,0]},{label:"NavCube.bottom",boundaries:[[7,13,4,4]],dir:[0,0,1],up:[0,-1,0]},{boundaries:[[7,5,4,2]],dir:[0,1,-1],up:[0,1,1]},{boundaries:[[1,6,4,1],[6,1,1,4]],dir:[1,0,-1],up:[1,0,1]},{boundaries:[[7,0,4,1],[19,6,4,1]],dir:[0,-1,-1],up:[0,-1,1]},{boundaries:[[13,6,4,1],[11,1,1,4]],dir:[-1,0,-1],up:[-1,0,1]},{boundaries:[[7,11,4,2]],dir:[0,1,1],up:[0,-1,1]},{boundaries:[[1,11,4,1],[6,13,1,4]],dir:[1,0,1],up:[-1,0,1]},{boundaries:[[7,17,4,1],[19,11,4,1]],dir:[0,-1,1],up:[0,1,1]},{boundaries:[[13,11,4,1],[11,13,1,4]],dir:[-1,0,1],up:[1,0,1]},{boundaries:[[5,7,2,4]],dir:[1,1,0],up:[0,0,1]},{boundaries:[[11,7,2,4]],dir:[-1,1,0],up:[0,0,1]},{boundaries:[[17,7,2,4]],dir:[-1,-1,0],up:[0,0,1]},{boundaries:[[0,7,1,4],[23,7,1,4]],dir:[1,-1,0],up:[0,0,1]},{boundaries:[[5,11,2,2]],dir:[1,1,1],up:[-1,-1,1]},{boundaries:[[23,11,1,1],[6,17,1,1],[0,11,1,1]],dir:[1,-1,1],up:[-1,1,1]},{boundaries:[[5,5,2,2]],dir:[1,1,-1],up:[1,1,1]},{boundaries:[[11,17,1,1],[17,11,2,1]],dir:[-1,-1,1],up:[1,1,1]},{boundaries:[[17,6,2,1],[11,0,1,1]],dir:[-1,-1,-1],up:[-1,-1,1]},{boundaries:[[11,11,2,2]],dir:[-1,1,1],up:[1,-1,1]},{boundaries:[[0,6,1,1],[6,0,1,1],[23,6,1,1]],dir:[1,-1,-1],up:[1,-1,1]},{boundaries:[[11,5,2,2]],dir:[-1,1,-1],up:[-1,1,1]}];i.frontColor||i.color,i.backColor||i.color,i.rightColor||i.color,i.leftColor||i.color,i.topColor||i.color,i.bottomColor||i.color;const h=[{yUp:"",label:"NavCube.front",boundaries:[[7,7,4,4]],dir:[0,0,-1],up:[0,1,0]},{label:"NavCube.back",boundaries:[[19,7,4,4]],dir:[0,0,1],up:[0,1,0]},{label:"NavCube.right",boundaries:[[13,7,4,4]],dir:[-1,0,0],up:[0,1,0]},{label:"NavCube.left",boundaries:[[1,7,4,4]],dir:[1,0,0],up:[0,1,0]},{label:"NavCube.top",boundaries:[[7,1,4,4]],dir:[0,-1,0],up:[0,0,-1]},{label:"NavCube.bottom",boundaries:[[7,13,4,4]],dir:[0,1,0],up:[0,0,1]},{boundaries:[[7,5,4,2]],dir:[0,-.7071,-.7071],up:[0,.7071,-.7071]},{boundaries:[[1,6,4,1],[6,1,1,4]],dir:[1,-1,0],up:[1,1,0]},{boundaries:[[7,0,4,1],[19,6,4,1]],dir:[0,-.7071,.7071],up:[0,.7071,.7071]},{boundaries:[[13,6,4,1],[11,1,1,4]],dir:[-1,-1,0],up:[-1,1,0]},{boundaries:[[7,11,4,2]],dir:[0,1,-1],up:[0,1,1]},{boundaries:[[1,11,4,1],[6,13,1,4]],dir:[1,1,0],up:[-1,1,0]},{boundaries:[[7,17,4,1],[19,11,4,1]],dir:[0,1,1],up:[0,1,-1]},{boundaries:[[13,11,4,1],[11,13,1,4]],dir:[-1,1,0],up:[1,1,0]},{boundaries:[[5,7,2,4]],dir:[1,0,-1],up:[0,1,0]},{boundaries:[[11,7,2,4]],dir:[-1,0,-1],up:[0,1,0]},{boundaries:[[17,7,2,4]],dir:[-1,0,1],up:[0,1,0]},{boundaries:[[0,7,1,4],[23,7,1,4]],dir:[1,0,1],up:[0,1,0]},{boundaries:[[5,11,2,2]],dir:[.5,.7071,-.5],up:[-.5,.7071,.5]},{boundaries:[[23,11,1,1],[6,17,1,1],[0,11,1,1]],dir:[.5,.7071,.5],up:[-.5,.7071,-.5]},{boundaries:[[5,5,2,2]],dir:[.5,-.7071,-.5],up:[.5,.7071,-.5]},{boundaries:[[11,17,1,1],[17,11,2,1]],dir:[-.5,.7071,.5],up:[.5,.7071,-.5]},{boundaries:[[17,6,2,1],[11,0,1,1]],dir:[-.5,-.7071,.5],up:[-.5,.7071,.5]},{boundaries:[[11,11,2,2]],dir:[-.5,.7071,-.5],up:[.5,.7071,.5]},{boundaries:[[0,6,1,1],[6,0,1,1],[23,6,1,1]],dir:[.5,-.7071,.5],up:[.5,.7071,.5]},{boundaries:[[11,5,2,2]],dir:[-.5,-.7071,-.5],up:[-.5,.7071,-.5]}];for(let y=0,v=u.length;y<v;y++)C.normalizeVec3(u[y].dir,u[y].dir),C.normalizeVec3(u[y].up,u[y].up);for(let y=0,v=h.length;y<v;y++)C.normalizeVec3(h[y].dir,h[y].dir),C.normalizeVec3(h[y].up,h[y].up);var p=h;this._textureCanvas=document.createElement("canvas"),this._textureCanvas.width=l,this._textureCanvas.height=s,this._textureCanvas.style.width=l+"px",this._textureCanvas.style.height=s+"px",this._textureCanvas.style.padding="0",this._textureCanvas.style.margin="0",this._textureCanvas.style.top="0",this._textureCanvas.style.background=o,this._textureCanvas.style.position="absolute",this._textureCanvas.style.opacity="1.0",this._textureCanvas.style.visibility="hidden",this._textureCanvas.style["z-index"]=2e6,a.appendChild(this._textureCanvas);const A=this._textureCanvas.getContext("2d");let f=!1;function m(){for(let k=0,B=d.length;k<B;k++){const P=d[k],E=P.boundary,T=Math.round(E[0]*c),S=Math.round(E[1]*c),R=Math.round(E[2]*c),F=Math.round(E[3]*c);A.fillStyle=P.color,A.fillRect(T,S,R,F)}for(let k=0,B=p.length;k<B;k++){let P,E,T,S;const R=p[k],F=R.boundaries;for(var y=0,v=F.length;y<v;y++){const U=F[y];P=Math.round(U[0]*c),E=Math.round(U[1]*c),T=Math.round(U[2]*c),S=Math.round(U[3]*c),R.highlighted&&(A.fillStyle=R.highlighted?n:R.color||o,A.fillRect(P,E,T,S))}if(R.label){A.fillStyle=r,A.font="60px sans-serif",A.textAlign="center";var w=P+T*.5,x=E+S*.7;A.fillText(g(R.label),w,x,80)}}e.glRedraw()}const g=(function(){const y={"NavCube.front":"NavCube.front","NavCube.back":"NavCube.back","NavCube.right":"NavCube.right","NavCube.left":"NavCube.left","NavCube.top":"NavCube.top","NavCube.bottom":"NavCube.bottom"},v={"NavCube.front":"NavCube.front","NavCube.back":"NavCube.back","NavCube.right":"NavCube.right","NavCube.left":"NavCube.left","NavCube.top":"NavCube.top","NavCube.bottom":"NavCube.bottom"},w={"NavCube.front":"FRONT","NavCube.back":"BACK","NavCube.right":"RIGHT","NavCube.left":"LEFT","NavCube.top":"TOP","NavCube.bottom":"BOTTOM"};return function(x){const k=f?v:y,B=k?k[x]:null;return B?t.localeService.translate(B)||w[B]||B:x}})();this.setZUp=function(){f=!0,p=u,this.clear()},this.setYUp=function(){f=!1,p=h,this.clear()},this.clear=function(){A.fillStyle=o,A.fillRect(0,0,l,s);for(var y=0,v=p.length;y<v;y++){const w=p[y];w.highlighted=!1}m()},this.getArea=function(y){const v=y[0]*l,w=s-y[1]*s;for(var x=0,k=p.length;x<k;x++){const E=p[x].boundaries;for(var B=0,P=E.length;B<P;B++){const T=E[B];if(v>=T[0]*c&&v<=(T[0]+T[2])*c&&w>=T[1]*c&&w<=(T[1]+T[3])*c)return x}}return-1},this.setAreaHighlighted=function(y,v){var w=p[y];if(!w)throw"Area not found: "+y;w.highlighted=!!v,m()},this.getAreaDir=function(y){var v=p[y];if(!v)throw"Unknown area: "+y;return v.dir},this.getAreaUp=function(y){var v=p[y];if(!v)throw"Unknown area: "+y;return v.up},this.getImage=function(){return this._textureCanvas},this.destroy=function(){this._textureCanvas&&(this._textureCanvas.parentNode.removeChild(this._textureCanvas),this._textureCanvas=null)}}const lee=C.vec3(),cee=C.vec3();C.mat4();class fS extends Ha{constructor(e,i={}){super("NavCube",e,i),e.navCube=this;try{this._navCubeScene=new z7(e,{canvasId:i.canvasId,canvasElement:i.canvasElement,transparent:!0}),this._navCubeCanvas=this._navCubeScene.canvas.canvas,this._navCubeScene.input.keyboardEnabled=!1}catch(g){this.error(g);return}const o=this._navCubeScene;o.clearLights(),new ws(o,{dir:[.4,-.4,.8],color:[.8,1,1],intensity:1,space:"view"}),new ws(o,{dir:[-.8,-.3,-.4],color:[.8,.8,.8],intensity:1,space:"view"}),new ws(o,{dir:[.8,-.6,-.8],color:[1,1,1],intensity:1,space:"view"}),this._navCubeCamera=o.camera,this._navCubeCamera.ortho.scale=7,this._navCubeCamera.ortho.near=.1,this._navCubeCamera.ortho.far=2e3,o.edgeMaterial.edgeColor=[.2,.2,.2],o.edgeMaterial.edgeAlpha=.6,this._zUp=!!e.camera.zUp;var n=this;this.setIsProjectNorth(i.isProjectNorth),this.setProjectNorthOffsetAngle(i.projectNorthOffsetAngle);const r=(function(){const g=C.mat4();return function(y,v,w){return C.identityMat4(g),C.rotationMat4v(y*n._projectNorthOffsetAngle*C.DEGTORAD,[0,1,0],g),C.transformVec3(g,v,w)}})();this._synchCamera=(function(){var g=C.rotationMat4c(-90*C.DEGTORAD,1,0,0),y=C.vec3(),v=C.vec3(),w=C.vec3();return function(){var x=e.camera.eye,k=e.camera.look,B=e.camera.up;y=C.mulVec3Scalar(C.normalizeVec3(C.subVec3(x,k,y)),5),n._isProjectNorth&&n._projectNorthOffsetAngle&&(y=r(-1,y,lee),B=r(-1,B,cee)),n._zUp?(C.transformVec3(g,y,v),C.transformVec3(g,B,w),n._navCubeCamera.look=[0,0,0],n._navCubeCamera.eye=C.transformVec3(g,y,v),n._navCubeCamera.up=C.transformPoint3(g,B,w)):(n._navCubeCamera.look=[0,0,0],n._navCubeCamera.eye=y,n._navCubeCamera.up=B)}})(),this._cubeTextureCanvas=new d_t(e,o,i),this._cubeSampler=new g1(o,{image:this._cubeTextureCanvas.getImage(),flipY:!0,wrapS:ln,wrapT:ln}),this._cubeMesh=new mi(o,{geometry:new Ao(o,{primitive:"triangles",normals:[0,0,1,0,0,1,0,0,1,0,0,1,1,0,0,1,0,0,1,0,0,1,0,0,0,1,0,0,1,0,0,1,0,0,1,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,0,-1,0,0,-1,0,0,-1,0,0,-1],positions:[1,1,1,-1,1,1,-1,-1,1,1,-1,1,1,1,1,1,-1,1,1,-1,-1,1,1,-1,1,1,1,1,1,-1,-1,1,-1,-1,1,1,-1,1,1,-1,1,-1,-1,-1,-1,-1,-1,1,-1,-1,-1,1,-1,-1,1,-1,1,-1,-1,1,1,-1,-1,-1,-1,-1,-1,1,-1,1,1,-1],uv:[.5,.6666,.25,.6666,.25,.3333,.5,.3333,.5,.6666,.5,.3333,.75,.3333,.75,.6666,.5,.6666,.5,1,.25,1,.25,.6666,.25,.6666,0,.6666,0,.3333,.25,.3333,.25,0,.5,0,.5,.3333,.25,.3333,.75,.3333,1,.3333,1,.6666,.75,.6666],indices:[0,1,2,0,2,3,4,5,6,4,6,7,8,9,10,8,10,11,12,13,14,12,14,15,16,17,18,16,18,19,20,21,22,20,22,23]}),material:new go(o,{diffuse:[.4,.4,.4],specular:[.4,.4,.4],emissive:[.6,.6,.6],diffuseMap:this._cubeSampler,emissiveMap:this._cubeSampler}),visible:!0,edges:!0}),this._shadow=i.shadowVisible===!1?null:new mi(o,{geometry:new Ao(o,u1({center:[0,0,0],radiusTop:.001,radiusBottom:1.4,height:.01,radialSegments:20,heightSegments:1,openEnded:!0})),material:new go(o,{diffuse:[0,0,0],specular:[0,0,0],emissive:[0,0,0],alpha:.5}),position:[0,-1.5,0],visible:!0,pickable:!1,backfaces:!1}),this._onCameraMatrix=e.camera.on("matrix",this._synchCamera),this._onCameraWorldAxis=e.camera.on("worldAxis",()=>{e.camera.zUp?(this._zUp=!0,this._cubeTextureCanvas.setZUp(),this._repaint(),this._synchCamera()):e.camera.yUp&&(this._zUp=!1,this._cubeTextureCanvas.setYUp(),this._repaint(),this._synchCamera())}),this._onCameraFOV=e.camera.perspective.on("fov",g=>{this._synchProjection&&(this._navCubeCamera.perspective.fov=g)}),this._onCameraProjection=e.camera.on("projection",g=>{this._synchProjection&&(this._navCubeCamera.projection=g==="ortho"||g==="perspective"?g:"perspective")});var a=-1;function s(g,y){var v=(g-A)*-p,w=(y-f)*-p;e.camera.orbitYaw(v),e.camera.orbitPitch(-w),A=g,f=y}function l(g){const{left:y,top:v}=n._navCubeCanvas.getBoundingClientRect();return[g.clientX-y,g.clientY-v]}{var c=null,d=null,u=!1,h=!1,p=.5,A,f;n._navCubeCanvas.addEventListener("mouseenter",n._onMouseEnter=function(g){h=!0}),n._navCubeCanvas.addEventListener("mouseleave",n._onMouseLeave=function(g){h=!1}),n._navCubeCanvas.addEventListener("mousedown",n._onMouseDown=function(g){if(g.which===1){c=g.x,d=g.y,A=g.clientX,f=g.clientY;var y=l({clientX:g.clientX,clientY:g.clientY}),v=o.pick({canvasPos:y});v?u=!0:u=!1}}),n._navCubeCanvas.addEventListener("mouseup",n._onMouseUp=function(g){if(g.which===1&&(u=!1,c!==null)){var y=l({clientX:g.clientX,clientY:g.clientY}),v=o.pick({canvasPos:y,pickSurface:!0});if(v&&v.uv){var w=n._cubeTextureCanvas.getArea(v.uv);if(w>=0&&(n._navCubeCanvas.style.cursor="pointer",a>=0&&(n._cubeTextureCanvas.setAreaHighlighted(a,!1),n._repaint(),a=-1),w>=0)){if(n._cubeTextureCanvas.setAreaHighlighted(w,!0),a=w,n._repaint(),g.x<c-3||g.x>c+3||g.y<d-3||g.y>d+3)return;var x=n._cubeTextureCanvas.getAreaDir(w);if(x){var k=n._cubeTextureCanvas.getAreaUp(w);n._isProjectNorth&&n._projectNorthOffsetAngle&&(x=r(1,x,lee),k=r(1,k,cee)),m(x,k,function(){a>=0&&(n._cubeTextureCanvas.setAreaHighlighted(a,!1),n._repaint(),a=-1),n._navCubeCanvas.style.cursor="pointer",a>=0&&(n._cubeTextureCanvas.setAreaHighlighted(a,!1),n._repaint(),a=-1),w>=0&&(n._cubeTextureCanvas.setAreaHighlighted(w,!1),a=-1,n._repaint())})}}}}}),n._navCubeCanvas.addEventListener("mousemove",n._onMouseMove=function(g){if(a>=0&&(n._cubeTextureCanvas.setAreaHighlighted(a,!1),n._repaint(),a=-1),!(g.buttons===1&&!u)){if(u){var y=g.clientX,v=g.clientY;n._navCubeCanvas.style.cursor="move",s(y,v);return}if(h){var w=l({clientX:g.clientX,clientY:g.clientY}),x=o.pick({canvasPos:w,pickSurface:!0});if(x){if(x.uv){n._navCubeCanvas.style.cursor="pointer";var k=n._cubeTextureCanvas.getArea(x.uv);if(k===a)return;a>=0&&n._cubeTextureCanvas.setAreaHighlighted(a,!1),k>=0&&(n._cubeTextureCanvas.setAreaHighlighted(k,!0),n._repaint(),a=k)}}else n._navCubeCanvas.style.cursor="default",a>=0&&(n._cubeTextureCanvas.setAreaHighlighted(a,!1),n._repaint(),a=-1)}}}),n._navCubeCanvas.addEventListener("touchstart",n._onTouchStart=function(g){if(g.touches.length>0){c=g.touches[0].clientX,d=g.touches[0].clientY,A=g.touches[0].clientX,f=g.touches[0].clientY;var y=l({clientX:g.touches[0].clientX,clientY:g.touches[0].clientY}),v=o.pick({canvasPos:y});v?u=!0:u=!1}},{passive:!1}),n._navCubeCanvas.addEventListener("touchmove",n._onTouchMove=function(g){g.preventDefault();var y=g.touches[0],v=y.clientX,w=y.clientY,x=document.elementFromPoint(v,w);if(h=n._navCubeCanvas===x,!!h&&u){s(v,w);return}},{passive:!1}),n._navCubeCanvas.addEventListener("touchend",n._onTouchEnd=function(g){u=!1});var m=(function(){var g=C.vec3();return function(y,v,w){var x=n._fitVisible?e.scene.getAABB(e.scene.visibleObjectIds):e.scene.aabb,k=C.getAABB3Diag(x);C.getAABB3Center(x,g);var B=Math.abs(k/Math.tan(n._cameraFitFOV*C.DEGTORAD));e.cameraControl.pivotPos=g,n._cameraFly?e.cameraFlight.flyTo({look:g,eye:[g[0]-B*y[0],g[1]-B*y[1],g[2]-B*y[2]],up:v||[0,1,0],orthoScale:k*1.1,fitFOV:n._cameraFitFOV,duration:n._cameraFlyDuration},w):e.cameraFlight.jumpTo({look:g,eye:[g[0]-B*y[0],g[1]-B*y[1],g[2]-B*y[2]],up:v||[0,1,0],orthoScale:k*1.1,fitFOV:n._cameraFitFOV},w)}})()}this._onUpdated=e.localeService.on("updated",()=>{this._cubeTextureCanvas.clear(),this._repaint()}),this.setVisible(i.visible),this.setCameraFitFOV(i.cameraFitFOV),this.setCameraFly(i.cameraFly),this.setCameraFlyDuration(i.cameraFlyDuration),this.setFitVisible(i.fitVisible),this.setSynchProjection(i.synchProjection)}send(e,i){switch(e){case"language":this._cubeTextureCanvas.clear(),this._repaint();break}}_repaint(){const e=this._cubeTextureCanvas.getImage();this._cubeMesh.material.diffuseMap.image=e,this._cubeMesh.material.emissiveMap.image=e}setVisible(e=!0){this._navCubeCanvas&&(this._cubeMesh.visible=e,this._shadow&&(this._shadow.visible=e),this._navCubeCanvas.style.visibility=e?"visible":"hidden")}getVisible(){return this._navCubeCanvas?this._cubeMesh.visible:!1}setFitVisible(e=!1){this._fitVisible=e}getFitVisible(){return this._fitVisible}setCameraFly(e=!0){this._cameraFly=e}getCameraFly(){return this._cameraFly}setCameraFitFOV(e=45){this._cameraFitFOV=e}getCameraFitFOV(){return this._cameraFitFOV}setCameraFlyDuration(e=.5){this._cameraFlyDuration=e}getCameraFlyDuration(){return this._cameraFlyDuration}setSynchProjection(e=!1){this._synchProjection=e}getSynchProjection(){return this._synchProjection}setIsProjectNorth(e=!1){this._isProjectNorth=e}getIsProjectNorth(){return this._isProjectNorth}setProjectNorthOffsetAngle(e){this._projectNorthOffsetAngle=e}getProjectNorthOffsetAngle(){return this._projectNorthOffsetAngle}destroy(){this._navCubeCanvas&&(this.viewer.localeService.off(this._onUpdated),this.viewer.camera.off(this._onCameraMatrix),this.viewer.camera.off(this._onCameraWorldAxis),this.viewer.camera.perspective.off(this._onCameraFOV),this.viewer.camera.off(this._onCameraProjection),this._navCubeCanvas.removeEventListener("mouseenter",this._onMouseEnter),this._navCubeCanvas.removeEventListener("mouseleave",this._onMouseLeave),this._navCubeCanvas.removeEventListener("mousedown",this._onMouseDown),this._navCubeCanvas.removeEventListener("mousemove",this._onMouseMove),this._navCubeCanvas.removeEventListener("mouseup",this._onMouseUp),this._navCubeCanvas.removeEventListener("touchstart",this._onTouchStart),this._navCubeCanvas.removeEventListener("touchmove",this._onTouchMove),this._navCubeCanvas.removeEventListener("touchend",this._onTouchEnd),this._navCubeCanvas=null,this._cubeTextureCanvas.destroy(),this._cubeTextureCanvas=null,this._onMouseEnter=null,this._onMouseLeave=null,this._onMouseDown=null,this._onMouseMove=null,this._onMouseUp=null,this._onTouchStart=null,this._onTouchMove=null,this._onTouchEnd=null),this._navCubeScene.destroy(),this._navCubeScene=null,this._cubeMesh=null,this._shadow=null,super.destroy()}}class u_t{constructor(e){const i=e.cameraControl,o=e.scene,n=o.canvas.canvas,r=!1,a=1,s=.09,l=.01,c=new Gv(o,{position:[0,0,0],scale:[5,5,5],isObject:!1}),d=C.vec3();this._setPosition=(function(){const x=C.vec3(),k=C.vec3();return function(B){d.set(B),ch(B,x,k),c.origin=x,c.position=k}})(),this._setQuaternion=x=>{c.quaternion=x};const u=(x,k)=>new Ao(c,u1({radiusTop:.001,radiusBottom:x,radialSegments:32,heightSegments:1,height:k,openEnded:!1})),h=(x,k,B)=>new Ao(c,u1({radiusTop:x,radiusBottom:x,radialSegments:B,heightSegments:1,height:k,openEnded:!1})),p=(x,k,B)=>new Ao(c,GE({radius:a-.2,tube:x,radialSegments:64,tubeSegments:B,arc:Math.PI*2*k})),A={curve:p(l,.25,14),curveHandle:p(s,.25,14),hoop:p(l,1,8),arrowHead:u(.07,.2),arrowHeadBig:u(.09,.25),arrowHeadHandle:h(s,.37,8),axis:h(l,a,20),axisHandle:h(s,a,20)},f=x=>new go(c,{diffuse:x,emissive:x,ambient:[0,0,0],specular:[.6,.6,.3],shininess:80,lineWidth:2}),m=(x,k)=>new cc(c,{edges:!1,fill:!0,fillColor:x,fillAlpha:k}),g=new go(c,{diffuse:[1,1,0],alpha:0,alphaMode:"blend"}),y={},v=(x,k)=>{C.mulVec3Scalar(x,-1,C.vec3());const B=f(x),P=C.quaternionToRotationMat4(k,C.identityMat4());C.mulMat4(C.rotationMat4v(Math.PI,[0,1,0],C.mat4()),P,P);const E=C.scaleMat4v([.6,.6,.6],C.identityMat4()),T=(ee,ae)=>{const Ee=C.translateMat4v(ee,C.identityMat4()),pe=C.identityMat4();return C.mulMat4(Ee,ae,pe),C.mulMat4(P,pe,pe),C.mulMat4(pe,E,C.identityMat4())},S=c.addChild(new mi(c,{geometry:A.curve,material:B,matrix:P,pickable:!1,collidable:!0,clippable:!1,backfaces:!0,visible:!1,isUI:!0,isObject:!1}),r),R=c.addChild(new mi(c,{geometry:A.curveHandle,material:g,matrix:P,pickable:!0,collidable:!0,clippable:!1,backfaces:!0,visible:!1,isUI:!0,isObject:!1}),r),F=c.addChild(new mi(c,{geometry:A.arrowHead,material:B,matrix:T([.8,.07,0],C.rotationMat4v(180*C.DEGTORAD,[0,0,1],C.identityMat4())),pickable:!0,collidable:!0,clippable:!1,visible:!1,isUI:!0,isObject:!1}),r),U=c.addChild(new mi(c,{geometry:A.arrowHead,material:B,matrix:T([.07,.8,0],C.rotationMat4v(90*C.DEGTORAD,[0,0,1],C.identityMat4())),pickable:!0,collidable:!0,clippable:!1,visible:!1,isUI:!0,isObject:!1}),r),q=c.addChild(new mi(c,{geometry:A.hoop,material:B,highlighted:!0,highlightMaterial:m(x,.6),matrix:P,pickable:!1,collidable:!0,clippable:!1,visible:!1,isUI:!0,isObject:!1}),r),V=C.quaternionToRotationMat4(C.vec3PairToQuaternion([0,1,0],x),C.identityMat4());C.mulMat4(C.rotationMat4v(Math.PI,[0,1,0],C.mat4()),V,V);const W=ee=>C.mulMat4(V,C.translateMat4c(0,ee,0,C.identityMat4()),C.identityMat4()),Y=W(a+.1),$=W(a/2),fe=c.addChild(new mi(c,{geometry:A.arrowHead,material:B,matrix:Y,pickable:!1,collidable:!0,clippable:!1,visible:!1,isUI:!0,isObject:!1}),r),Me=c.addChild(new mi(c,{geometry:A.arrowHeadHandle,material:g,matrix:Y,pickable:!0,collidable:!0,clippable:!1,visible:!1,isUI:!0,isObject:!1}),r),Se=c.addChild(new mi(c,{geometry:A.axis,material:B,matrix:$,pickable:!1,collidable:!0,clippable:!1,visible:!1,isUI:!0,isObject:!1}),r),qe=c.addChild(new mi(c,{geometry:A.axisHandle,material:g,matrix:$,pickable:!0,collidable:!0,clippable:!1,visible:!1,isUI:!0,isObject:!1}),r),Qe=c.addChild(new mi(c,{geometry:A.arrowHeadBig,material:B,matrix:Y,pickable:!1,collidable:!0,clippable:!1,visible:!1,isUI:!0,isObject:!1}),r),Ce=(ee,ae)=>C.vec3ApplyQuaternion(c.quaternion,ee,ae),Le=(function(){const ee=C.vec3(),ae=C.vec3(),Ee=C.vec3();return(pe,Q)=>{Ce(x,ee);const Z=d,ie=ee;C.canvasPosToWorldRay(n,o.camera.viewMatrix,o.camera.projMatrix,o.camera.projection,pe,ae,Ee);const re=C.dotVec3(ie,Ee),ne=C.subVec3(ae,Z,Q),G=C.dotVec3(ne,ie),K=C.dotVec3(ne,Ee),ue=1-re*re;if(Math.abs(ue)>1e-10){const xe=(G-re*K)/ue;return C.addVec3(Z,C.mulVec3Scalar(ie,xe,Q),Q),!0}else return!1}})(),Fe=C.vec3(),ve=C.vec3();y[Me.id]=y[qe.id]={setActivated:ee=>Qe.visible=ee,initDragAction:ee=>Le(ee,Fe)&&C.subVec3(Fe,d,Fe)&&(ae=>{Le(ae,ve)&&(C.subVec3(ve,Fe,ve),this._setPosition(ve),this._handlers&&this._handlers.onPosition(ve))})},y[R.id]={setActivated:ee=>q.visible=ee,initDragAction:ee=>{const ae=(function(){const pe=o.camera.projectWorldPos(d);Ce(x,ve),C.transformVec3(o.camera.normalMatrix,ve,ve);const Q=Math.sign(ve[2]);return Z=>{const ie=Z[0]-pe[0],re=Z[1]-pe[1];return Q*Math.atan2(-re,ie)}})();let Ee=ae(ee);return pe=>{const Q=ae(pe);c.rotate(x,(Q-Ee)*180/Math.PI),this._handlers&&this._handlers.onQuaternion(c.quaternion),Ee=Q}}};let me=!1,we=!1,Re=!1;const We=()=>{const ee=Re&&me;Me.visible=qe.visible=fe.visible=Se.visible=!!ee,ee||(Qe.visible=!1)},H=()=>{const ee=Re&&we;R.visible=S.visible=F.visible=U.visible=!!ee,ee||(q.visible=!1)};return{setPositionActive:ee=>{me=ee,We()},setRotationActive:ee=>{we=ee,H()},set visible(ee){Re=ee,We(),H()}}};this._displayMeshes={center:c.addChild(new mi(c,{geometry:new Ao(c,h1({radius:.05})),material:new go(c,{diffuse:[0,0,0],emissive:[0,0,0],ambient:[0,0,0],specular:[.6,.6,.3],shininess:80}),pickable:!1,collidable:!0,clippable:!1,visible:!1,isObject:!1}),r),x:v([1,0,0],C.vec3PairToQuaternion([1,0,0],[0,0,1])),y:v([0,1,0],C.eulerToQuaternion([90,0,0],"XYZ")),z:v([0,0,1],C.identityQuaternion())};const w=[];{let x=-1;const k=P=>{c.scale[0]!==P&&(c.scale=[P,P,P],this._handlers&&this._handlers.onScreenScale&&this._handlers.onScreenScale(c.scale))},B=o.on("tick",()=>{const P=o.camera,E=Math.abs(C.distVec3(P.eye,d));P.projection==="perspective"?E!==x&&k(.07*E*Math.tan(P.perspective.fov*C.DEGTORAD)):P.projection==="ortho"&&k(P.ortho.scale/10),x=E});w.push(()=>o.off(B))}{let x=null,k=null;w.push(()=>{k&&k.cleanup()});const B=C.vec2(),P=(F,U)=>{U[0]=F.pageX,U[1]=F.pageY,hl(n.ownerDocument.documentElement,n,U)},E=F=>{P(F,B);const U=o.pick({canvasPos:B}),q=U&&U.entity,V=q&&q.id;return V in y&&y[V]},T=(F,U)=>{const q=E(U(F));if(q){k&&k.cleanup();const V=q.initDragAction(B);return V&&(i.pointerEnabled=!1,q.setActivated(!0),k={onChange:W=>{const Y=U(W);Y&&(P(Y,B),V(B))},cleanup:function(){k=null,i.pointerEnabled=!0,q.setActivated(!1)}}),!!V}else return!1},S=(F,U)=>{n.addEventListener(F,U),w.push(()=>n.removeEventListener(F,U))},R=F=>{F.preventDefault(),F.stopPropagation(),F.stopImmediatePropagation()};S("mousedown",F=>{F.which===1&&T(F,U=>U.which===1&&U)&&R(F)}),S("mousemove",F=>{if(k)k.onChange(F),R(F);else{x&&x();const U=E(F);U?(U.setActivated(!0),x=()=>U.setActivated(!1)):x=null}}),S("mouseup",F=>{k&&(k.onChange(F),k.cleanup())}),S("touchstart",F=>{if(F.preventDefault(),F.touches.length===1){const U=F.touches[0].identifier;T(F,q=>[...q.changedTouches].find(V=>V.identifier===U))&&R(F)}}),S("touchmove",F=>{k&&(k.onChange(F),R(F))}),S("touchend",F=>{k&&(k.onChange(F),k.cleanup())})}this.__destroy=()=>{w.forEach(x=>x()),c.destroy();for(let x in y)delete y[x]}}destroy(){this.__destroy()}setHandlers(e){Object.values(this._displayMeshes).forEach(i=>i.visible=!!e),this._handlers=e,this._displayMeshes.x.setPositionActive(e&&e.onPosition),this._displayMeshes.y.setPositionActive(e&&e.onPosition),this._displayMeshes.z.setPositionActive(e&&e.onPosition),this._displayMeshes.x.setRotationActive(e&&e.onQuaternion),this._displayMeshes.y.setRotationActive(e&&e.onQuaternion),this._displayMeshes.z.setRotationActive(e&&e.onQuaternion)}setPosition(e){this._setPosition(e)}setQuaternion(e){this._setQuaternion(e)}}let h_t=class{constructor(t,e,i){this.id=i.id,this._sectionPlane=i,this._mesh=new mi(e,{id:i.id,geometry:new Ao(e,zE({xSize:.5,ySize:.5,zSize:.001})),material:new go(e,{emissive:[1,1,1],diffuse:[0,0,0],backfaces:!1}),edgeMaterial:new bP(e,{edgeColor:[0,0,0],edgeAlpha:1,edgeWidth:1}),highlightMaterial:new cc(e,{fill:!0,fillColor:[.5,1,.5],fillAlpha:.7,edges:!0,edgeColor:[0,0,0],edgeAlpha:1,edgeWidth:1}),selectedMaterial:new cc(e,{fill:!0,fillColor:[0,0,1],fillAlpha:.7,edges:!0,edgeColor:[1,0,0],edgeAlpha:1,edgeWidth:1}),highlighted:!0,scale:[3,3,3],position:[0,0,0],rotation:[0,0,0],opacity:.3,edges:!0});{const o=C.vec3([0,0,0]),n=C.vec3(),r=C.vec3([0,0,1]),a=C.vec4(4),s=C.vec3(),l=()=>{const c=this._sectionPlane.scene.center,d=[-this._sectionPlane.dir[0],-this._sectionPlane.dir[1],-this._sectionPlane.dir[2]];C.subVec3(c,this._sectionPlane.pos,o);const u=-C.dotVec3(d,o);C.normalizeVec3(d),C.mulVec3Scalar(d,u,n);const h=C.vec3PairToQuaternion(r,this._sectionPlane.dir,a);s[0]=n[0]*.1,s[1]=n[1]*.1,s[2]=n[2]*.1,this._mesh.quaternion=h,this._mesh.position=s};this._onSectionPlanePos=this._sectionPlane.on("pos",l),this._onSectionPlaneDir=this._sectionPlane.on("dir",l)}this._highlighted=!1,this._selected=!1}setHighlighted(t){this._highlighted=!!t,this._mesh.highlighted=this._highlighted,this._mesh.highlightMaterial.fillColor=t?[0,.7,0]:[0,0,0]}getHighlighted(){return this._highlighted}setSelected(t){this._selected=!!t,this._mesh.edgeMaterial.edgeWidth=t?3:1,this._mesh.highlightMaterial.edgeWidth=t?3:1}getSelected(){return this._selected}destroy(){this._sectionPlane.off(this._onSectionPlanePos),this._sectionPlane.off(this._onSectionPlaneDir),this._mesh.destroy()}};class p_t{constructor(e,i){if(!i.onHoverEnterPlane||!i.onHoverLeavePlane||!i.onClickedNothing||!i.onClickedPlane)throw"Missing config(s): onHoverEnterPlane, onHoverLeavePlane, onClickedNothing || onClickedPlane";this.plugin=e,this._viewer=e.viewer,this._onHoverEnterPlane=i.onHoverEnterPlane,this._onHoverLeavePlane=i.onHoverLeavePlane,this._onClickedNothing=i.onClickedNothing,this._onClickedPlane=i.onClickedPlane,this._visible=!0,this._planes={},this._canvas=i.overviewCanvas,this._scene=new z7(this._viewer,{canvasId:this._canvas.id,transparent:!0}),this._scene.clearLights(),new ws(this._scene,{dir:[.4,-.4,.8],color:[.8,1,1],intensity:1,space:"view"}),new ws(this._scene,{dir:[-.8,-.3,-.4],color:[.8,.8,.8],intensity:1,space:"view"}),new ws(this._scene,{dir:[.8,-.6,-.8],color:[1,1,1],intensity:1,space:"view"}),this._scene.camera,this._scene.camera.perspective.fov=70,this._zUp=!1;{const n=this._scene.camera,r=C.rotationMat4c(-90*C.DEGTORAD,1,0,0),a=C.vec3(),s=C.vec3(),l=C.vec3();this._synchCamera=()=>{const c=this._viewer.camera.eye,d=this._viewer.camera.look,u=this._viewer.camera.up;C.mulVec3Scalar(C.normalizeVec3(C.subVec3(c,d,a)),7),this._zUp?(C.transformVec3(r,a,s),C.transformVec3(r,u,l),n.look=[0,0,0],n.eye=C.transformVec3(r,a,s),n.up=C.transformPoint3(r,u,l)):(n.look=[0,0,0],n.eye=a,n.up=u)}}this._onViewerCameraMatrix=this._viewer.camera.on("matrix",this._synchCamera),this._onViewerCameraWorldAxis=this._viewer.camera.on("worldAxis",this._synchCamera),this._onViewerCameraFOV=this._viewer.camera.perspective.on("fov",n=>{this._scene.camera.perspective.fov=n});{var o=null;this._onInputMouseMove=this._scene.input.on("mousemove",n=>{const r=this._scene.pick({canvasPos:n});r?(!o||r.entity.id!==o.id)&&(o&&this._planes[o.id]&&this._onHoverLeavePlane(o.id),o=r.entity,this._planes[o.id]&&this._onHoverEnterPlane(o.id)):o&&(this._onHoverLeavePlane(o.id),o=null)}),this._scene.canvas.canvas.addEventListener("mouseup",this._onCanvasMouseUp=()=>{o?this._planes[o.id]&&this._onClickedPlane(o.id):this._onClickedNothing()}),this._scene.canvas.canvas.addEventListener("mouseout",this._onCanvasMouseOut=()=>{o&&(this._onHoverLeavePlane(o.id),o=null)})}this.setVisible(i.overviewVisible)}addSectionPlane(e){this._planes[e.id]=new h_t(this,this._scene,e)}setPlaneHighlighted(e,i){const o=this._planes[e];o&&o.setHighlighted(i)}setPlaneSelected(e,i){const o=this._planes[e];o&&o.setSelected(i)}removeSectionPlane(e){const i=this._planes[e.id];i&&(i.destroy(),delete this._planes[e.id])}setVisible(e=!0){this._visible=e,this._canvas.style.visibility=e?"visible":"hidden"}getVisible(){return this._visible}destroy(){this._viewer.camera.off(this._onViewerCameraMatrix),this._viewer.camera.off(this._onViewerCameraWorldAxis),this._viewer.camera.perspective.off(this._onViewerCameraFOV),this._scene.input.off(this._onInputMouseMove),this._scene.canvas.canvas.removeEventListener("mouseup",this._onCanvasMouseUp),this._scene.canvas.canvas.removeEventListener("mouseout",this._onCanvasMouseOut),this._scene.destroy()}}const gc=C.AABB3(),wh=C.vec3();class f_t extends Ha{constructor(e,i={}){if(super("SectionPlanes",e),this._freeControls=[],this._sectionPlanes=e.scene.sectionPlanes,this._controls={},this._shownControlId=null,i.overviewCanvasId!==null&&i.overviewCanvasId!==void 0){const o=document.getElementById(i.overviewCanvasId);o?this._overview=new p_t(this,{overviewCanvas:o,visible:i.overviewVisible,onHoverEnterPlane:(n=>{this._overview.setPlaneHighlighted(n,!0)}),onHoverLeavePlane:(n=>{this._overview.setPlaneHighlighted(n,!1)}),onClickedPlane:(n=>{if(this.getShownControl()===n){this.hideControl();return}this.showControl(n);const r=this.sectionPlanes[n].pos;gc.set(this.viewer.scene.aabb),C.getAABB3Center(gc,wh),gc[0]+=r[0]-wh[0],gc[1]+=r[1]-wh[1],gc[2]+=r[2]-wh[2],gc[3]+=r[0]-wh[0],gc[4]+=r[1]-wh[1],gc[5]+=r[2]-wh[2],this.viewer.cameraFlight.flyTo({aabb:gc,fitFOV:65})}),onClickedNothing:(()=>{this.hideControl()})}):this.warn("Can't find overview canvas: '"+i.overviewCanvasId+"' - will create plugin without overview")}this._onSceneSectionPlaneCreated=e.scene.on("sectionPlaneCreated",o=>{this._sectionPlaneCreated(o)})}setOverviewVisible(e){this._overview&&this._overview.setVisible(e)}getOverviewVisible(){if(this._overview)return this._overview.getVisible()}get sectionPlanes(){return this._sectionPlanes}createSectionPlane(e={}){return e.id!==void 0&&e.id!==null&&this.viewer.scene.components[e.id]&&(this.error("Viewer component with this ID already exists: "+e.id),delete e.id),new XP(this.viewer.scene,{id:e.id,pos:e.pos,dir:e.dir,active:!0})}_sectionPlaneCreated(e){const i=this._freeControls.length>0?this._freeControls.pop():(()=>{const o=this.viewer.scene,n=(function(){const u=new Gv(o,{isObject:!1});return u.addChild(new mi(u,{geometry:new Ao(u,{primitive:"triangles",positions:[.5,.5,0,.5,-.5,0,-.5,-.5,0,-.5,.5,0,.5,.5,-0,.5,-.5,-0,-.5,-.5,-0,-.5,.5,-0],indices:[0,1,2,2,3,0]}),material:new go(u,{emissive:[0,0,0],diffuse:[0,0,0],backfaces:!0}),opacity:.6,ghosted:!0,ghostMaterial:new cc(u,{edges:!1,filled:!0,fillColor:[1,1,0],edgeColor:[0,0,0],fillAlpha:.1,backfaces:!0}),pickable:!1,collidable:!0,clippable:!1,visible:!1,scale:[2.4,2.4,1],isObject:!1})),u.addChild(new mi(u,{geometry:new Ao(u,GE({center:[0,0,0],radius:1.7,tube:.02,radialSegments:4,tubeSegments:4,arc:Math.PI*2})),material:new go(u,{emissive:[0,0,0],diffuse:[0,0,0],specular:[0,0,0],shininess:0}),highlightMaterial:new cc(u,{edges:!1,edgeColor:[0,0,0],filled:!0,fillColor:[.8,.8,.8],fillAlpha:1}),pickable:!1,collidable:!1,clippable:!1,visible:!1,scale:[1,1,.1],rotation:[0,0,45],isObject:!1})),{setPosition:(function(){const h=C.vec3(),p=C.vec3();return function(A){ch(A,h,p),u.origin=h,u.position=p}})(),setQuaternion:h=>{u.quaternion=h},setScale:h=>{u.scale=h},setVisible:h=>{u.visible=h},destroy:()=>{u.destroy()}}})();let r=()=>{};const a=new u_t(this.viewer);let s=!1,l=!1,c=null;const d=()=>{const u=l&&!s;n.setVisible(u),a.setHandlers(u&&c)};return{_destroy:()=>{r(),a.destroy(),n.destroy()},setCulled:u=>{s=u,d()},setVisible:u=>{l=u,d()},_setSectionPlane:u=>{if(r(),u){let h=!1;c={onPosition:g=>{n.setPosition(g),u.pos=g},onQuaternion:g=>{n.setQuaternion(g),h=!0,u.quaternion=g},onScreenScale:g=>{n.setScale(g)}};const p=()=>{n.setPosition(u.pos),a.setPosition(u.pos)},A=()=>{n.setQuaternion(u.quaternion),a.setQuaternion(u.quaternion)};p(),A();const f=u.on("pos",p),m=u.on("dir",()=>{h?h=!1:A()});r=()=>{u.off(f),u.off(m),r=()=>{}}}}}})();i._setSectionPlane(e),i.setVisible(!1),this._controls[e.id]=i,this._overview&&this._overview.addSectionPlane(e),e.once("destroyed",()=>{this._sectionPlaneDestroyed(e)})}flipSectionPlanes(){const e=this.viewer.scene.sectionPlanes;for(let i in e)e[i].flipDir()}showControl(e){const i=this._controls[e];if(!i){this.error("Control not found: "+e);return}this.hideControl(),i.setVisible(!0),this._overview&&this._overview.setPlaneSelected(e,!0),this._shownControlId=e}getShownControl(){return this._shownControlId}hideControl(){for(var e in this._controls)this._controls.hasOwnProperty(e)&&(this._controls[e].setVisible(!1),this._overview&&this._overview.setPlaneSelected(e,!1));this._shownControlId=null}destroySectionPlane(e){var i=this.viewer.scene.sectionPlanes[e];if(!i){this.error("SectionPlane not found: "+e);return}this._sectionPlaneDestroyed(i),i.destroy(),e===this._shownControlId&&(this._shownControlId=null)}_sectionPlaneDestroyed(e){this._overview&&this._overview.removeSectionPlane(e);const i=this._controls[e.id];i&&(i.setVisible(!1),i._setSectionPlane(null),delete this._controls[e.id],this._freeControls.push(i))}clear(){const e=Object.keys(this._sectionPlanes);for(var i=0,o=e.length;i<o;i++)this.destroySectionPlane(e[i])}send(e,i){switch(e){case"snapshotStarting":for(let o in this._controls)this._controls.hasOwnProperty(o)&&this._controls[o].setCulled(!0);break;case"snapshotFinished":for(let o in this._controls)this._controls.hasOwnProperty(o)&&this._controls[o].setCulled(!1);break;case"clearSectionPlanes":this.clear();break}}destroy(){this.clear(),this._overview&&this._overview.destroy(),this._destroyFreeControls(),super.destroy()}_destroyFreeControls(){for(var e=this._freeControls.pop();e;)e._destroy(),e=this._freeControls.pop();this.viewer.scene.off(this._onSceneSectionPlaneCreated)}}class dee{constructor(e={}){this.cacheBuster=e.cacheBuster!==!1}_cacheBusterURL(e){if(!this.cacheBuster)return e;const i=new Date().getTime();return e.indexOf("?")>-1?e+"&_="+i:e+"?_="+i}getManifest(e,i,o){mt.loadJSON(this._cacheBusterURL(e),n=>{i(n)},function(n){o(n)})}getMetaModel(e,i,o){mt.loadJSON(this._cacheBusterURL(e),n=>{i(n)},function(n){o(n)})}getXKT(e,i,o){var n=()=>{};i=i||n,o=o||n;const r=/^data:(.*?)(;base64)?,(.*)$/,a=e.match(r);if(a){const c=!!a[2];var s=a[3];s=window.decodeURIComponent(s),c&&(s=window.atob(s));try{const d=new ArrayBuffer(s.length),u=new Uint8Array(d);for(var l=0;l<s.length;l++)u[l]=s.charCodeAt(l);i(d)}catch(d){o(d)}}else{const c=new XMLHttpRequest;c.open("GET",this._cacheBusterURL(e),!0),c.responseType="arraybuffer",c.onreadystatechange=function(){c.readyState===4&&(c.status===200?i(c.response):o("getXKT error : "+c.response))},c.send(null)}}}var S9={exports:{}},A_t=S9.exports,uee;function g_t(){return uee||(uee=1,(function(t,e){(function(i,o){o(e)})(A_t,(function(i){function o(L){let X=L.length;for(;--X>=0;)L[X]=0}const n=256,r=286,a=30,s=15,l=new Uint8Array([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0]),c=new Uint8Array([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13]),d=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7]),u=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),h=new Array(576);o(h);const p=new Array(60);o(p);const A=new Array(512);o(A);const f=new Array(256);o(f);const m=new Array(29);o(m);const g=new Array(a);function y(L,X,O,ke,ye){this.static_tree=L,this.extra_bits=X,this.extra_base=O,this.elems=ke,this.max_length=ye,this.has_stree=L&&L.length}let v,w,x;function k(L,X){this.dyn_tree=L,this.max_code=0,this.stat_desc=X}o(g);const B=L=>L<256?A[L]:A[256+(L>>>7)],P=(L,X)=>{L.pending_buf[L.pending++]=255&X,L.pending_buf[L.pending++]=X>>>8&255},E=(L,X,O)=>{L.bi_valid>16-O?(L.bi_buf|=X<<L.bi_valid&65535,P(L,L.bi_buf),L.bi_buf=X>>16-L.bi_valid,L.bi_valid+=O-16):(L.bi_buf|=X<<L.bi_valid&65535,L.bi_valid+=O)},T=(L,X,O)=>{E(L,O[2*X],O[2*X+1])},S=(L,X)=>{let O=0;do O|=1&L,L>>>=1,O<<=1;while(--X>0);return O>>>1},R=(L,X,O)=>{const ke=new Array(16);let ye,ge,tt=0;for(ye=1;ye<=s;ye++)tt=tt+O[ye-1]<<1,ke[ye]=tt;for(ge=0;ge<=X;ge++){let Oe=L[2*ge+1];Oe!==0&&(L[2*ge]=S(ke[Oe]++,Oe))}},F=L=>{let X;for(X=0;X<r;X++)L.dyn_ltree[2*X]=0;for(X=0;X<a;X++)L.dyn_dtree[2*X]=0;for(X=0;X<19;X++)L.bl_tree[2*X]=0;L.dyn_ltree[512]=1,L.opt_len=L.static_len=0,L.sym_next=L.matches=0},U=L=>{L.bi_valid>8?P(L,L.bi_buf):L.bi_valid>0&&(L.pending_buf[L.pending++]=L.bi_buf),L.bi_buf=0,L.bi_valid=0},q=(L,X,O,ke)=>{const ye=2*X,ge=2*O;return L[ye]<L[ge]||L[ye]===L[ge]&&ke[X]<=ke[O]},V=(L,X,O)=>{const ke=L.heap[O];let ye=O<<1;for(;ye<=L.heap_len&&(ye<L.heap_len&&q(X,L.heap[ye+1],L.heap[ye],L.depth)&&ye++,!q(X,ke,L.heap[ye],L.depth));)L.heap[O]=L.heap[ye],O=ye,ye<<=1;L.heap[O]=ke},W=(L,X,O)=>{let ke,ye,ge,tt,Oe=0;if(L.sym_next!==0)do ke=255&L.pending_buf[L.sym_buf+Oe++],ke+=(255&L.pending_buf[L.sym_buf+Oe++])<<8,ye=L.pending_buf[L.sym_buf+Oe++],ke===0?T(L,ye,X):(ge=f[ye],T(L,ge+n+1,X),tt=l[ge],tt!==0&&(ye-=m[ge],E(L,ye,tt)),ke--,ge=B(ke),T(L,ge,O),tt=c[ge],tt!==0&&(ke-=g[ge],E(L,ke,tt)));while(Oe<L.sym_next);T(L,256,X)},Y=(L,X)=>{const O=X.dyn_tree,ke=X.stat_desc.static_tree,ye=X.stat_desc.has_stree,ge=X.stat_desc.elems;let tt,Oe,wt,Ve=-1;for(L.heap_len=0,L.heap_max=573,tt=0;tt<ge;tt++)O[2*tt]!==0?(L.heap[++L.heap_len]=Ve=tt,L.depth[tt]=0):O[2*tt+1]=0;for(;L.heap_len<2;)wt=L.heap[++L.heap_len]=Ve<2?++Ve:0,O[2*wt]=1,L.depth[wt]=0,L.opt_len--,ye&&(L.static_len-=ke[2*wt+1]);for(X.max_code=Ve,tt=L.heap_len>>1;tt>=1;tt--)V(L,O,tt);wt=ge;do tt=L.heap[1],L.heap[1]=L.heap[L.heap_len--],V(L,O,1),Oe=L.heap[1],L.heap[--L.heap_max]=tt,L.heap[--L.heap_max]=Oe,O[2*wt]=O[2*tt]+O[2*Oe],L.depth[wt]=(L.depth[tt]>=L.depth[Oe]?L.depth[tt]:L.depth[Oe])+1,O[2*tt+1]=O[2*Oe+1]=wt,L.heap[1]=wt++,V(L,O,1);while(L.heap_len>=2);L.heap[--L.heap_max]=L.heap[1],((et,ii)=>{const Ht=ii.dyn_tree,Ct=ii.max_code,Xo=ii.stat_desc.static_tree,Si=ii.stat_desc.has_stree,Qt=ii.stat_desc.extra_bits,Oi=ii.stat_desc.extra_base,ti=ii.stat_desc.max_length;let kt,ei,Ui,Pt,Ei,oi,Gt=0;for(Pt=0;Pt<=s;Pt++)et.bl_count[Pt]=0;for(Ht[2*et.heap[et.heap_max]+1]=0,kt=et.heap_max+1;kt<573;kt++)ei=et.heap[kt],Pt=Ht[2*Ht[2*ei+1]+1]+1,Pt>ti&&(Pt=ti,Gt++),Ht[2*ei+1]=Pt,ei>Ct||(et.bl_count[Pt]++,Ei=0,ei>=Oi&&(Ei=Qt[ei-Oi]),oi=Ht[2*ei],et.opt_len+=oi*(Pt+Ei),Si&&(et.static_len+=oi*(Xo[2*ei+1]+Ei)));if(Gt!==0){do{for(Pt=ti-1;et.bl_count[Pt]===0;)Pt--;et.bl_count[Pt]--,et.bl_count[Pt+1]+=2,et.bl_count[ti]--,Gt-=2}while(Gt>0);for(Pt=ti;Pt!==0;Pt--)for(ei=et.bl_count[Pt];ei!==0;)Ui=et.heap[--kt],Ui>Ct||(Ht[2*Ui+1]!==Pt&&(et.opt_len+=(Pt-Ht[2*Ui+1])*Ht[2*Ui],Ht[2*Ui+1]=Pt),ei--)}})(L,X),R(O,Ve,L.bl_count)},$=(L,X,O)=>{let ke,ye,ge=-1,tt=X[1],Oe=0,wt=7,Ve=4;for(tt===0&&(wt=138,Ve=3),X[2*(O+1)+1]=65535,ke=0;ke<=O;ke++)ye=tt,tt=X[2*(ke+1)+1],++Oe<wt&&ye===tt||(Oe<Ve?L.bl_tree[2*ye]+=Oe:ye!==0?(ye!==ge&&L.bl_tree[2*ye]++,L.bl_tree[32]++):Oe<=10?L.bl_tree[34]++:L.bl_tree[36]++,Oe=0,ge=ye,tt===0?(wt=138,Ve=3):ye===tt?(wt=6,Ve=3):(wt=7,Ve=4))},fe=(L,X,O)=>{let ke,ye,ge=-1,tt=X[1],Oe=0,wt=7,Ve=4;for(tt===0&&(wt=138,Ve=3),ke=0;ke<=O;ke++)if(ye=tt,tt=X[2*(ke+1)+1],!(++Oe<wt&&ye===tt)){if(Oe<Ve)do T(L,ye,L.bl_tree);while(--Oe!=0);else ye!==0?(ye!==ge&&(T(L,ye,L.bl_tree),Oe--),T(L,16,L.bl_tree),E(L,Oe-3,2)):Oe<=10?(T(L,17,L.bl_tree),E(L,Oe-3,3)):(T(L,18,L.bl_tree),E(L,Oe-11,7));Oe=0,ge=ye,tt===0?(wt=138,Ve=3):ye===tt?(wt=6,Ve=3):(wt=7,Ve=4)}};let Me=!1;const Se=(L,X,O,ke)=>{E(L,0+(ke?1:0),3),U(L),P(L,O),P(L,~O),O&&L.pending_buf.set(L.window.subarray(X,X+O),L.pending),L.pending+=O};var qe=(L,X,O,ke)=>{let ye,ge,tt=0;L.level>0?(L.strm.data_type===2&&(L.strm.data_type=(Oe=>{let wt,Ve=4093624447;for(wt=0;wt<=31;wt++,Ve>>>=1)if(1&Ve&&Oe.dyn_ltree[2*wt]!==0)return 0;if(Oe.dyn_ltree[18]!==0||Oe.dyn_ltree[20]!==0||Oe.dyn_ltree[26]!==0)return 1;for(wt=32;wt<n;wt++)if(Oe.dyn_ltree[2*wt]!==0)return 1;return 0})(L)),Y(L,L.l_desc),Y(L,L.d_desc),tt=(Oe=>{let wt;for($(Oe,Oe.dyn_ltree,Oe.l_desc.max_code),$(Oe,Oe.dyn_dtree,Oe.d_desc.max_code),Y(Oe,Oe.bl_desc),wt=18;wt>=3&&Oe.bl_tree[2*u[wt]+1]===0;wt--);return Oe.opt_len+=3*(wt+1)+5+5+4,wt})(L),ye=L.opt_len+3+7>>>3,ge=L.static_len+3+7>>>3,ge<=ye&&(ye=ge)):ye=ge=O+5,O+4<=ye&&X!==-1?Se(L,X,O,ke):L.strategy===4||ge===ye?(E(L,2+(ke?1:0),3),W(L,h,p)):(E(L,4+(ke?1:0),3),((Oe,wt,Ve,et)=>{let ii;for(E(Oe,wt-257,5),E(Oe,Ve-1,5),E(Oe,et-4,4),ii=0;ii<et;ii++)E(Oe,Oe.bl_tree[2*u[ii]+1],3);fe(Oe,Oe.dyn_ltree,wt-1),fe(Oe,Oe.dyn_dtree,Ve-1)})(L,L.l_desc.max_code+1,L.d_desc.max_code+1,tt+1),W(L,L.dyn_ltree,L.dyn_dtree)),F(L),ke&&U(L)},Qe={_tr_init:L=>{Me||((()=>{let X,O,ke,ye,ge;const tt=new Array(16);for(ke=0,ye=0;ye<28;ye++)for(m[ye]=ke,X=0;X<1<<l[ye];X++)f[ke++]=ye;for(f[ke-1]=ye,ge=0,ye=0;ye<16;ye++)for(g[ye]=ge,X=0;X<1<<c[ye];X++)A[ge++]=ye;for(ge>>=7;ye<a;ye++)for(g[ye]=ge<<7,X=0;X<1<<c[ye]-7;X++)A[256+ge++]=ye;for(O=0;O<=s;O++)tt[O]=0;for(X=0;X<=143;)h[2*X+1]=8,X++,tt[8]++;for(;X<=255;)h[2*X+1]=9,X++,tt[9]++;for(;X<=279;)h[2*X+1]=7,X++,tt[7]++;for(;X<=287;)h[2*X+1]=8,X++,tt[8]++;for(R(h,287,tt),X=0;X<a;X++)p[2*X+1]=5,p[2*X]=S(X,5);v=new y(h,l,257,r,s),w=new y(p,c,0,a,s),x=new y(new Array(0),d,0,19,7)})(),Me=!0),L.l_desc=new k(L.dyn_ltree,v),L.d_desc=new k(L.dyn_dtree,w),L.bl_desc=new k(L.bl_tree,x),L.bi_buf=0,L.bi_valid=0,F(L)},_tr_stored_block:Se,_tr_flush_block:qe,_tr_tally:(L,X,O)=>(L.pending_buf[L.sym_buf+L.sym_next++]=X,L.pending_buf[L.sym_buf+L.sym_next++]=X>>8,L.pending_buf[L.sym_buf+L.sym_next++]=O,X===0?L.dyn_ltree[2*O]++:(L.matches++,X--,L.dyn_ltree[2*(f[O]+n+1)]++,L.dyn_dtree[2*B(X)]++),L.sym_next===L.sym_end),_tr_align:L=>{E(L,2,3),T(L,256,h),(X=>{X.bi_valid===16?(P(X,X.bi_buf),X.bi_buf=0,X.bi_valid=0):X.bi_valid>=8&&(X.pending_buf[X.pending++]=255&X.bi_buf,X.bi_buf>>=8,X.bi_valid-=8)})(L)}},Ce=(L,X,O,ke)=>{let ye=65535&L|0,ge=L>>>16&65535|0,tt=0;for(;O!==0;){tt=O>2e3?2e3:O,O-=tt;do ye=ye+X[ke++]|0,ge=ge+ye|0;while(--tt);ye%=65521,ge%=65521}return ye|ge<<16|0};const Le=new Uint32Array((()=>{let L,X=[];for(var O=0;O<256;O++){L=O;for(var ke=0;ke<8;ke++)L=1&L?3988292384^L>>>1:L>>>1;X[O]=L}return X})());var Fe=(L,X,O,ke)=>{const ye=Le,ge=ke+O;L^=-1;for(let tt=ke;tt<ge;tt++)L=L>>>8^ye[255&(L^X[tt])];return-1^L},ve={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"},me={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_MEM_ERROR:-4,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8};const{_tr_init:we,_tr_stored_block:Re,_tr_flush_block:We,_tr_tally:H,_tr_align:ee}=Qe,{Z_NO_FLUSH:ae,Z_PARTIAL_FLUSH:Ee,Z_FULL_FLUSH:pe,Z_FINISH:Q,Z_BLOCK:Z,Z_OK:ie,Z_STREAM_END:re,Z_STREAM_ERROR:ne,Z_DATA_ERROR:G,Z_BUF_ERROR:K,Z_DEFAULT_COMPRESSION:ue,Z_FILTERED:xe,Z_HUFFMAN_ONLY:oe,Z_RLE:Be,Z_FIXED:je,Z_DEFAULT_STRATEGY:he,Z_UNKNOWN:Ne,Z_DEFLATED:Pe}=me,ze=258,rt=262,At=42,ft=113,lt=666,ut=(L,X)=>(L.msg=ve[X],X),Te=L=>2*L-(L>4?9:0),st=L=>{let X=L.length;for(;--X>=0;)L[X]=0},dt=L=>{let X,O,ke,ye=L.w_size;X=L.hash_size,ke=X;do O=L.head[--ke],L.head[ke]=O>=ye?O-ye:0;while(--X);X=ye,ke=X;do O=L.prev[--ke],L.prev[ke]=O>=ye?O-ye:0;while(--X)};let Ye=(L,X,O)=>(X<<L.hash_shift^O)&L.hash_mask;const Ae=L=>{const X=L.state;let O=X.pending;O>L.avail_out&&(O=L.avail_out),O!==0&&(L.output.set(X.pending_buf.subarray(X.pending_out,X.pending_out+O),L.next_out),L.next_out+=O,X.pending_out+=O,L.total_out+=O,L.avail_out-=O,X.pending-=O,X.pending===0&&(X.pending_out=0))},be=(L,X)=>{We(L,L.block_start>=0?L.block_start:-1,L.strstart-L.block_start,X),L.block_start=L.strstart,Ae(L.strm)},$e=(L,X)=>{L.pending_buf[L.pending++]=X},ht=(L,X)=>{L.pending_buf[L.pending++]=X>>>8&255,L.pending_buf[L.pending++]=255&X},St=(L,X,O,ke)=>{let ye=L.avail_in;return ye>ke&&(ye=ke),ye===0?0:(L.avail_in-=ye,X.set(L.input.subarray(L.next_in,L.next_in+ye),O),L.state.wrap===1?L.adler=Ce(L.adler,X,ye,O):L.state.wrap===2&&(L.adler=Fe(L.adler,X,ye,O)),L.next_in+=ye,L.total_in+=ye,ye)},xt=(L,X)=>{let O,ke,ye=L.max_chain_length,ge=L.strstart,tt=L.prev_length,Oe=L.nice_match;const wt=L.strstart>L.w_size-rt?L.strstart-(L.w_size-rt):0,Ve=L.window,et=L.w_mask,ii=L.prev,Ht=L.strstart+ze;let Ct=Ve[ge+tt-1],Xo=Ve[ge+tt];L.prev_length>=L.good_match&&(ye>>=2),Oe>L.lookahead&&(Oe=L.lookahead);do if(O=X,Ve[O+tt]===Xo&&Ve[O+tt-1]===Ct&&Ve[O]===Ve[ge]&&Ve[++O]===Ve[ge+1]){ge+=2,O++;do;while(Ve[++ge]===Ve[++O]&&Ve[++ge]===Ve[++O]&&Ve[++ge]===Ve[++O]&&Ve[++ge]===Ve[++O]&&Ve[++ge]===Ve[++O]&&Ve[++ge]===Ve[++O]&&Ve[++ge]===Ve[++O]&&Ve[++ge]===Ve[++O]&&ge<Ht);if(ke=ze-(Ht-ge),ge=Ht-ze,ke>tt){if(L.match_start=X,tt=ke,ke>=Oe)break;Ct=Ve[ge+tt-1],Xo=Ve[ge+tt]}}while((X=ii[X&et])>wt&&--ye!=0);return tt<=L.lookahead?tt:L.lookahead},vi=L=>{const X=L.w_size;let O,ke,ye;do{if(ke=L.window_size-L.lookahead-L.strstart,L.strstart>=X+(X-rt)&&(L.window.set(L.window.subarray(X,X+X-ke),0),L.match_start-=X,L.strstart-=X,L.block_start-=X,L.insert>L.strstart&&(L.insert=L.strstart),dt(L),ke+=X),L.strm.avail_in===0)break;if(O=St(L.strm,L.window,L.strstart+L.lookahead,ke),L.lookahead+=O,L.lookahead+L.insert>=3)for(ye=L.strstart-L.insert,L.ins_h=L.window[ye],L.ins_h=Ye(L,L.ins_h,L.window[ye+1]);L.insert&&(L.ins_h=Ye(L,L.ins_h,L.window[ye+3-1]),L.prev[ye&L.w_mask]=L.head[L.ins_h],L.head[L.ins_h]=ye,ye++,L.insert--,!(L.lookahead+L.insert<3)););}while(L.lookahead<rt&&L.strm.avail_in!==0)},Gi=(L,X)=>{let O,ke,ye,ge=L.pending_buf_size-5>L.w_size?L.w_size:L.pending_buf_size-5,tt=0,Oe=L.strm.avail_in;do{if(O=65535,ye=L.bi_valid+42>>3,L.strm.avail_out<ye||(ye=L.strm.avail_out-ye,ke=L.strstart-L.block_start,O>ke+L.strm.avail_in&&(O=ke+L.strm.avail_in),O>ye&&(O=ye),O<ge&&(O===0&&X!==Q||X===ae||O!==ke+L.strm.avail_in)))break;tt=X===Q&&O===ke+L.strm.avail_in?1:0,Re(L,0,0,tt),L.pending_buf[L.pending-4]=O,L.pending_buf[L.pending-3]=O>>8,L.pending_buf[L.pending-2]=~O,L.pending_buf[L.pending-1]=~O>>8,Ae(L.strm),ke&&(ke>O&&(ke=O),L.strm.output.set(L.window.subarray(L.block_start,L.block_start+ke),L.strm.next_out),L.strm.next_out+=ke,L.strm.avail_out-=ke,L.strm.total_out+=ke,L.block_start+=ke,O-=ke),O&&(St(L.strm,L.strm.output,L.strm.next_out,O),L.strm.next_out+=O,L.strm.avail_out-=O,L.strm.total_out+=O)}while(tt===0);return Oe-=L.strm.avail_in,Oe&&(Oe>=L.w_size?(L.matches=2,L.window.set(L.strm.input.subarray(L.strm.next_in-L.w_size,L.strm.next_in),0),L.strstart=L.w_size,L.insert=L.strstart):(L.window_size-L.strstart<=Oe&&(L.strstart-=L.w_size,L.window.set(L.window.subarray(L.w_size,L.w_size+L.strstart),0),L.matches<2&&L.matches++,L.insert>L.strstart&&(L.insert=L.strstart)),L.window.set(L.strm.input.subarray(L.strm.next_in-Oe,L.strm.next_in),L.strstart),L.strstart+=Oe,L.insert+=Oe>L.w_size-L.insert?L.w_size-L.insert:Oe),L.block_start=L.strstart),L.high_water<L.strstart&&(L.high_water=L.strstart),tt?4:X!==ae&&X!==Q&&L.strm.avail_in===0&&L.strstart===L.block_start?2:(ye=L.window_size-L.strstart,L.strm.avail_in>ye&&L.block_start>=L.w_size&&(L.block_start-=L.w_size,L.strstart-=L.w_size,L.window.set(L.window.subarray(L.w_size,L.w_size+L.strstart),0),L.matches<2&&L.matches++,ye+=L.w_size,L.insert>L.strstart&&(L.insert=L.strstart)),ye>L.strm.avail_in&&(ye=L.strm.avail_in),ye&&(St(L.strm,L.window,L.strstart,ye),L.strstart+=ye,L.insert+=ye>L.w_size-L.insert?L.w_size-L.insert:ye),L.high_water<L.strstart&&(L.high_water=L.strstart),ye=L.bi_valid+42>>3,ye=L.pending_buf_size-ye>65535?65535:L.pending_buf_size-ye,ge=ye>L.w_size?L.w_size:ye,ke=L.strstart-L.block_start,(ke>=ge||(ke||X===Q)&&X!==ae&&L.strm.avail_in===0&&ke<=ye)&&(O=ke>ye?ye:ke,tt=X===Q&&L.strm.avail_in===0&&O===ke?1:0,Re(L,L.block_start,O,tt),L.block_start+=O,Ae(L.strm)),tt?3:1)},So=(L,X)=>{let O,ke;for(;;){if(L.lookahead<rt){if(vi(L),L.lookahead<rt&&X===ae)return 1;if(L.lookahead===0)break}if(O=0,L.lookahead>=3&&(L.ins_h=Ye(L,L.ins_h,L.window[L.strstart+3-1]),O=L.prev[L.strstart&L.w_mask]=L.head[L.ins_h],L.head[L.ins_h]=L.strstart),O!==0&&L.strstart-O<=L.w_size-rt&&(L.match_length=xt(L,O)),L.match_length>=3)if(ke=H(L,L.strstart-L.match_start,L.match_length-3),L.lookahead-=L.match_length,L.match_length<=L.max_lazy_match&&L.lookahead>=3){L.match_length--;do L.strstart++,L.ins_h=Ye(L,L.ins_h,L.window[L.strstart+3-1]),O=L.prev[L.strstart&L.w_mask]=L.head[L.ins_h],L.head[L.ins_h]=L.strstart;while(--L.match_length!=0);L.strstart++}else L.strstart+=L.match_length,L.match_length=0,L.ins_h=L.window[L.strstart],L.ins_h=Ye(L,L.ins_h,L.window[L.strstart+1]);else ke=H(L,0,L.window[L.strstart]),L.lookahead--,L.strstart++;if(ke&&(be(L,!1),L.strm.avail_out===0))return 1}return L.insert=L.strstart<2?L.strstart:2,X===Q?(be(L,!0),L.strm.avail_out===0?3:4):L.sym_next&&(be(L,!1),L.strm.avail_out===0)?1:2},ao=(L,X)=>{let O,ke,ye;for(;;){if(L.lookahead<rt){if(vi(L),L.lookahead<rt&&X===ae)return 1;if(L.lookahead===0)break}if(O=0,L.lookahead>=3&&(L.ins_h=Ye(L,L.ins_h,L.window[L.strstart+3-1]),O=L.prev[L.strstart&L.w_mask]=L.head[L.ins_h],L.head[L.ins_h]=L.strstart),L.prev_length=L.match_length,L.prev_match=L.match_start,L.match_length=2,O!==0&&L.prev_length<L.max_lazy_match&&L.strstart-O<=L.w_size-rt&&(L.match_length=xt(L,O),L.match_length<=5&&(L.strategy===xe||L.match_length===3&&L.strstart-L.match_start>4096)&&(L.match_length=2)),L.prev_length>=3&&L.match_length<=L.prev_length){ye=L.strstart+L.lookahead-3,ke=H(L,L.strstart-1-L.prev_match,L.prev_length-3),L.lookahead-=L.prev_length-1,L.prev_length-=2;do++L.strstart<=ye&&(L.ins_h=Ye(L,L.ins_h,L.window[L.strstart+3-1]),O=L.prev[L.strstart&L.w_mask]=L.head[L.ins_h],L.head[L.ins_h]=L.strstart);while(--L.prev_length!=0);if(L.match_available=0,L.match_length=2,L.strstart++,ke&&(be(L,!1),L.strm.avail_out===0))return 1}else if(L.match_available){if(ke=H(L,0,L.window[L.strstart-1]),ke&&be(L,!1),L.strstart++,L.lookahead--,L.strm.avail_out===0)return 1}else L.match_available=1,L.strstart++,L.lookahead--}return L.match_available&&(ke=H(L,0,L.window[L.strstart-1]),L.match_available=0),L.insert=L.strstart<2?L.strstart:2,X===Q?(be(L,!0),L.strm.avail_out===0?3:4):L.sym_next&&(be(L,!1),L.strm.avail_out===0)?1:2};function Ar(L,X,O,ke,ye){this.good_length=L,this.max_lazy=X,this.nice_length=O,this.max_chain=ke,this.func=ye}const Ki=[new Ar(0,0,0,0,Gi),new Ar(4,4,8,4,So),new Ar(4,5,16,8,So),new Ar(4,6,32,32,So),new Ar(4,4,16,16,ao),new Ar(8,16,32,32,ao),new Ar(8,16,128,128,ao),new Ar(8,32,128,256,ao),new Ar(32,128,258,1024,ao),new Ar(32,258,258,4096,ao)];function Kh(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=Pe,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new Uint16Array(1146),this.dyn_dtree=new Uint16Array(122),this.bl_tree=new Uint16Array(78),st(this.dyn_ltree),st(this.dyn_dtree),st(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new Uint16Array(16),this.heap=new Uint16Array(573),st(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new Uint16Array(573),st(this.depth),this.sym_buf=0,this.lit_bufsize=0,this.sym_next=0,this.sym_end=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}const _s=L=>{if(!L)return 1;const X=L.state;return!X||X.strm!==L||X.status!==At&&X.status!==57&&X.status!==69&&X.status!==73&&X.status!==91&&X.status!==103&&X.status!==ft&&X.status!==lt?1:0},om=L=>{if(_s(L))return ut(L,ne);L.total_in=L.total_out=0,L.data_type=Ne;const X=L.state;return X.pending=0,X.pending_out=0,X.wrap<0&&(X.wrap=-X.wrap),X.status=X.wrap===2?57:X.wrap?At:ft,L.adler=X.wrap===2?0:1,X.last_flush=-2,we(X),ie},pu=L=>{const X=om(L);var O;return X===ie&&((O=L.state).window_size=2*O.w_size,st(O.head),O.max_lazy_match=Ki[O.level].max_lazy,O.good_match=Ki[O.level].good_length,O.nice_match=Ki[O.level].nice_length,O.max_chain_length=Ki[O.level].max_chain,O.strstart=0,O.block_start=0,O.lookahead=0,O.insert=0,O.match_length=O.prev_length=2,O.match_available=0,O.ins_h=0),X},rm=(L,X,O,ke,ye,ge)=>{if(!L)return ne;let tt=1;if(X===ue&&(X=6),ke<0?(tt=0,ke=-ke):ke>15&&(tt=2,ke-=16),ye<1||ye>9||O!==Pe||ke<8||ke>15||X<0||X>9||ge<0||ge>je||ke===8&&tt!==1)return ut(L,ne);ke===8&&(ke=9);const Oe=new Kh;return L.state=Oe,Oe.strm=L,Oe.status=At,Oe.wrap=tt,Oe.gzhead=null,Oe.w_bits=ke,Oe.w_size=1<<Oe.w_bits,Oe.w_mask=Oe.w_size-1,Oe.hash_bits=ye+7,Oe.hash_size=1<<Oe.hash_bits,Oe.hash_mask=Oe.hash_size-1,Oe.hash_shift=~~((Oe.hash_bits+3-1)/3),Oe.window=new Uint8Array(2*Oe.w_size),Oe.head=new Uint16Array(Oe.hash_size),Oe.prev=new Uint16Array(Oe.w_size),Oe.lit_bufsize=1<<ye+6,Oe.pending_buf_size=4*Oe.lit_bufsize,Oe.pending_buf=new Uint8Array(Oe.pending_buf_size),Oe.sym_buf=Oe.lit_bufsize,Oe.sym_end=3*(Oe.lit_bufsize-1),Oe.level=X,Oe.strategy=ge,Oe.method=O,pu(L)};var Nc={deflateInit:(L,X)=>rm(L,X,Pe,15,8,he),deflateInit2:rm,deflateReset:pu,deflateResetKeep:om,deflateSetHeader:(L,X)=>_s(L)||L.state.wrap!==2?ne:(L.state.gzhead=X,ie),deflate:(L,X)=>{if(_s(L)||X>Z||X<0)return L?ut(L,ne):ne;const O=L.state;if(!L.output||L.avail_in!==0&&!L.input||O.status===lt&&X!==Q)return ut(L,L.avail_out===0?K:ne);const ke=O.last_flush;if(O.last_flush=X,O.pending!==0){if(Ae(L),L.avail_out===0)return O.last_flush=-1,ie}else if(L.avail_in===0&&Te(X)<=Te(ke)&&X!==Q)return ut(L,K);if(O.status===lt&&L.avail_in!==0)return ut(L,K);if(O.status===At&&O.wrap===0&&(O.status=ft),O.status===At){let ye=Pe+(O.w_bits-8<<4)<<8,ge=-1;if(ge=O.strategy>=oe||O.level<2?0:O.level<6?1:O.level===6?2:3,ye|=ge<<6,O.strstart!==0&&(ye|=32),ye+=31-ye%31,ht(O,ye),O.strstart!==0&&(ht(O,L.adler>>>16),ht(O,65535&L.adler)),L.adler=1,O.status=ft,Ae(L),O.pending!==0)return O.last_flush=-1,ie}if(O.status===57){if(L.adler=0,$e(O,31),$e(O,139),$e(O,8),O.gzhead)$e(O,(O.gzhead.text?1:0)+(O.gzhead.hcrc?2:0)+(O.gzhead.extra?4:0)+(O.gzhead.name?8:0)+(O.gzhead.comment?16:0)),$e(O,255&O.gzhead.time),$e(O,O.gzhead.time>>8&255),$e(O,O.gzhead.time>>16&255),$e(O,O.gzhead.time>>24&255),$e(O,O.level===9?2:O.strategy>=oe||O.level<2?4:0),$e(O,255&O.gzhead.os),O.gzhead.extra&&O.gzhead.extra.length&&($e(O,255&O.gzhead.extra.length),$e(O,O.gzhead.extra.length>>8&255)),O.gzhead.hcrc&&(L.adler=Fe(L.adler,O.pending_buf,O.pending,0)),O.gzindex=0,O.status=69;else if($e(O,0),$e(O,0),$e(O,0),$e(O,0),$e(O,0),$e(O,O.level===9?2:O.strategy>=oe||O.level<2?4:0),$e(O,3),O.status=ft,Ae(L),O.pending!==0)return O.last_flush=-1,ie}if(O.status===69){if(O.gzhead.extra){let ye=O.pending,ge=(65535&O.gzhead.extra.length)-O.gzindex;for(;O.pending+ge>O.pending_buf_size;){let Oe=O.pending_buf_size-O.pending;if(O.pending_buf.set(O.gzhead.extra.subarray(O.gzindex,O.gzindex+Oe),O.pending),O.pending=O.pending_buf_size,O.gzhead.hcrc&&O.pending>ye&&(L.adler=Fe(L.adler,O.pending_buf,O.pending-ye,ye)),O.gzindex+=Oe,Ae(L),O.pending!==0)return O.last_flush=-1,ie;ye=0,ge-=Oe}let tt=new Uint8Array(O.gzhead.extra);O.pending_buf.set(tt.subarray(O.gzindex,O.gzindex+ge),O.pending),O.pending+=ge,O.gzhead.hcrc&&O.pending>ye&&(L.adler=Fe(L.adler,O.pending_buf,O.pending-ye,ye)),O.gzindex=0}O.status=73}if(O.status===73){if(O.gzhead.name){let ye,ge=O.pending;do{if(O.pending===O.pending_buf_size){if(O.gzhead.hcrc&&O.pending>ge&&(L.adler=Fe(L.adler,O.pending_buf,O.pending-ge,ge)),Ae(L),O.pending!==0)return O.last_flush=-1,ie;ge=0}ye=O.gzindex<O.gzhead.name.length?255&O.gzhead.name.charCodeAt(O.gzindex++):0,$e(O,ye)}while(ye!==0);O.gzhead.hcrc&&O.pending>ge&&(L.adler=Fe(L.adler,O.pending_buf,O.pending-ge,ge)),O.gzindex=0}O.status=91}if(O.status===91){if(O.gzhead.comment){let ye,ge=O.pending;do{if(O.pending===O.pending_buf_size){if(O.gzhead.hcrc&&O.pending>ge&&(L.adler=Fe(L.adler,O.pending_buf,O.pending-ge,ge)),Ae(L),O.pending!==0)return O.last_flush=-1,ie;ge=0}ye=O.gzindex<O.gzhead.comment.length?255&O.gzhead.comment.charCodeAt(O.gzindex++):0,$e(O,ye)}while(ye!==0);O.gzhead.hcrc&&O.pending>ge&&(L.adler=Fe(L.adler,O.pending_buf,O.pending-ge,ge))}O.status=103}if(O.status===103){if(O.gzhead.hcrc){if(O.pending+2>O.pending_buf_size&&(Ae(L),O.pending!==0))return O.last_flush=-1,ie;$e(O,255&L.adler),$e(O,L.adler>>8&255),L.adler=0}if(O.status=ft,Ae(L),O.pending!==0)return O.last_flush=-1,ie}if(L.avail_in!==0||O.lookahead!==0||X!==ae&&O.status!==lt){let ye=O.level===0?Gi(O,X):O.strategy===oe?((ge,tt)=>{let Oe;for(;;){if(ge.lookahead===0&&(vi(ge),ge.lookahead===0)){if(tt===ae)return 1;break}if(ge.match_length=0,Oe=H(ge,0,ge.window[ge.strstart]),ge.lookahead--,ge.strstart++,Oe&&(be(ge,!1),ge.strm.avail_out===0))return 1}return ge.insert=0,tt===Q?(be(ge,!0),ge.strm.avail_out===0?3:4):ge.sym_next&&(be(ge,!1),ge.strm.avail_out===0)?1:2})(O,X):O.strategy===Be?((ge,tt)=>{let Oe,wt,Ve,et;const ii=ge.window;for(;;){if(ge.lookahead<=ze){if(vi(ge),ge.lookahead<=ze&&tt===ae)return 1;if(ge.lookahead===0)break}if(ge.match_length=0,ge.lookahead>=3&&ge.strstart>0&&(Ve=ge.strstart-1,wt=ii[Ve],wt===ii[++Ve]&&wt===ii[++Ve]&&wt===ii[++Ve])){et=ge.strstart+ze;do;while(wt===ii[++Ve]&&wt===ii[++Ve]&&wt===ii[++Ve]&&wt===ii[++Ve]&&wt===ii[++Ve]&&wt===ii[++Ve]&&wt===ii[++Ve]&&wt===ii[++Ve]&&Ve<et);ge.match_length=ze-(et-Ve),ge.match_length>ge.lookahead&&(ge.match_length=ge.lookahead)}if(ge.match_length>=3?(Oe=H(ge,1,ge.match_length-3),ge.lookahead-=ge.match_length,ge.strstart+=ge.match_length,ge.match_length=0):(Oe=H(ge,0,ge.window[ge.strstart]),ge.lookahead--,ge.strstart++),Oe&&(be(ge,!1),ge.strm.avail_out===0))return 1}return ge.insert=0,tt===Q?(be(ge,!0),ge.strm.avail_out===0?3:4):ge.sym_next&&(be(ge,!1),ge.strm.avail_out===0)?1:2})(O,X):Ki[O.level].func(O,X);if(ye!==3&&ye!==4||(O.status=lt),ye===1||ye===3)return L.avail_out===0&&(O.last_flush=-1),ie;if(ye===2&&(X===Ee?ee(O):X!==Z&&(Re(O,0,0,!1),X===pe&&(st(O.head),O.lookahead===0&&(O.strstart=0,O.block_start=0,O.insert=0))),Ae(L),L.avail_out===0))return O.last_flush=-1,ie}return X!==Q?ie:O.wrap<=0?re:(O.wrap===2?($e(O,255&L.adler),$e(O,L.adler>>8&255),$e(O,L.adler>>16&255),$e(O,L.adler>>24&255),$e(O,255&L.total_in),$e(O,L.total_in>>8&255),$e(O,L.total_in>>16&255),$e(O,L.total_in>>24&255)):(ht(O,L.adler>>>16),ht(O,65535&L.adler)),Ae(L),O.wrap>0&&(O.wrap=-O.wrap),O.pending!==0?ie:re)},deflateEnd:L=>{if(_s(L))return ne;const X=L.state.status;return L.state=null,X===ft?ut(L,G):ie},deflateSetDictionary:(L,X)=>{let O=X.length;if(_s(L))return ne;const ke=L.state,ye=ke.wrap;if(ye===2||ye===1&&ke.status!==At||ke.lookahead)return ne;if(ye===1&&(L.adler=Ce(L.adler,X,O,0)),ke.wrap=0,O>=ke.w_size){ye===0&&(st(ke.head),ke.strstart=0,ke.block_start=0,ke.insert=0);let wt=new Uint8Array(ke.w_size);wt.set(X.subarray(O-ke.w_size,O),0),X=wt,O=ke.w_size}const ge=L.avail_in,tt=L.next_in,Oe=L.input;for(L.avail_in=O,L.next_in=0,L.input=X,vi(ke);ke.lookahead>=3;){let wt=ke.strstart,Ve=ke.lookahead-2;do ke.ins_h=Ye(ke,ke.ins_h,ke.window[wt+3-1]),ke.prev[wt&ke.w_mask]=ke.head[ke.ins_h],ke.head[ke.ins_h]=wt,wt++;while(--Ve);ke.strstart=wt,ke.lookahead=2,vi(ke)}return ke.strstart+=ke.lookahead,ke.block_start=ke.strstart,ke.insert=ke.lookahead,ke.lookahead=0,ke.match_length=ke.prev_length=2,ke.match_available=0,L.next_in=tt,L.input=Oe,L.avail_in=ge,ke.wrap=ye,ie},deflateInfo:"pako deflate (from Nodeca project)"};const gw=(L,X)=>Object.prototype.hasOwnProperty.call(L,X);var K4=function(L){const X=Array.prototype.slice.call(arguments,1);for(;X.length;){const O=X.shift();if(O){if(typeof O!="object")throw new TypeError(O+"must be non-object");for(const ke in O)gw(O,ke)&&(L[ke]=O[ke])}}return L},J4=L=>{let X=0;for(let ke=0,ye=L.length;ke<ye;ke++)X+=L[ke].length;const O=new Uint8Array(X);for(let ke=0,ye=0,ge=L.length;ke<ge;ke++){let tt=L[ke];O.set(tt,ye),ye+=tt.length}return O};let Z4=!0;try{String.fromCharCode.apply(null,new Uint8Array(1))}catch{Z4=!1}const fu=new Uint8Array(256);for(let L=0;L<256;L++)fu[L]=L>=252?6:L>=248?5:L>=240?4:L>=224?3:L>=192?2:1;fu[254]=fu[254]=1;var nm=L=>{if(typeof TextEncoder=="function"&&TextEncoder.prototype.encode)return new TextEncoder().encode(L);let X,O,ke,ye,ge,tt=L.length,Oe=0;for(ye=0;ye<tt;ye++)O=L.charCodeAt(ye),(64512&O)==55296&&ye+1<tt&&(ke=L.charCodeAt(ye+1),(64512&ke)==56320&&(O=65536+(O-55296<<10)+(ke-56320),ye++)),Oe+=O<128?1:O<2048?2:O<65536?3:4;for(X=new Uint8Array(Oe),ge=0,ye=0;ge<Oe;ye++)O=L.charCodeAt(ye),(64512&O)==55296&&ye+1<tt&&(ke=L.charCodeAt(ye+1),(64512&ke)==56320&&(O=65536+(O-55296<<10)+(ke-56320),ye++)),O<128?X[ge++]=O:O<2048?(X[ge++]=192|O>>>6,X[ge++]=128|63&O):O<65536?(X[ge++]=224|O>>>12,X[ge++]=128|O>>>6&63,X[ge++]=128|63&O):(X[ge++]=240|O>>>18,X[ge++]=128|O>>>12&63,X[ge++]=128|O>>>6&63,X[ge++]=128|63&O);return X},se=(L,X)=>{const O=X||L.length;if(typeof TextDecoder=="function"&&TextDecoder.prototype.decode)return new TextDecoder().decode(L.subarray(0,X));let ke,ye;const ge=new Array(2*O);for(ye=0,ke=0;ke<O;){let tt=L[ke++];if(tt<128){ge[ye++]=tt;continue}let Oe=fu[tt];if(Oe>4)ge[ye++]=65533,ke+=Oe-1;else{for(tt&=Oe===2?31:Oe===3?15:7;Oe>1&&ke<O;)tt=tt<<6|63&L[ke++],Oe--;Oe>1?ge[ye++]=65533:tt<65536?ge[ye++]=tt:(tt-=65536,ge[ye++]=55296|tt>>10&1023,ge[ye++]=56320|1023&tt)}}return((tt,Oe)=>{if(Oe<65534&&tt.subarray&&Z4)return String.fromCharCode.apply(null,tt.length===Oe?tt:tt.subarray(0,Oe));let wt="";for(let Ve=0;Ve<Oe;Ve++)wt+=String.fromCharCode(tt[Ve]);return wt})(ge,ye)},Ke=(L,X)=>{(X=X||L.length)>L.length&&(X=L.length);let O=X-1;for(;O>=0&&(192&L[O])==128;)O--;return O<0||O===0?X:O+fu[L[O]]>X?O:X},nt=function(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0};const at=Object.prototype.toString,{Z_NO_FLUSH:Ge,Z_SYNC_FLUSH:bt,Z_FULL_FLUSH:Lt,Z_FINISH:Ut,Z_OK:Ot,Z_STREAM_END:Yt,Z_DEFAULT_COMPRESSION:$t,Z_DEFAULT_STRATEGY:Xt,Z_DEFLATED:Bi}=me;function Fi(L){this.options=K4({level:$t,method:Bi,chunkSize:16384,windowBits:15,memLevel:8,strategy:Xt},L||{});let X=this.options;X.raw&&X.windowBits>0?X.windowBits=-X.windowBits:X.gzip&&X.windowBits>0&&X.windowBits<16&&(X.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new nt,this.strm.avail_out=0;let O=Nc.deflateInit2(this.strm,X.level,X.method,X.windowBits,X.memLevel,X.strategy);if(O!==Ot)throw new Error(ve[O]);if(X.header&&Nc.deflateSetHeader(this.strm,X.header),X.dictionary){let ke;if(ke=typeof X.dictionary=="string"?nm(X.dictionary):at.call(X.dictionary)==="[object ArrayBuffer]"?new Uint8Array(X.dictionary):X.dictionary,O=Nc.deflateSetDictionary(this.strm,ke),O!==Ot)throw new Error(ve[O]);this._dict_set=!0}}function to(L,X){const O=new Fi(X);if(O.push(L,!0),O.err)throw O.msg||ve[O.err];return O.result}Fi.prototype.push=function(L,X){const O=this.strm,ke=this.options.chunkSize;let ye,ge;if(this.ended)return!1;for(ge=X===~~X?X:X===!0?Ut:Ge,typeof L=="string"?O.input=nm(L):at.call(L)==="[object ArrayBuffer]"?O.input=new Uint8Array(L):O.input=L,O.next_in=0,O.avail_in=O.input.length;;)if(O.avail_out===0&&(O.output=new Uint8Array(ke),O.next_out=0,O.avail_out=ke),(ge===bt||ge===Lt)&&O.avail_out<=6)this.onData(O.output.subarray(0,O.next_out)),O.avail_out=0;else{if(ye=Nc.deflate(O,ge),ye===Yt)return O.next_out>0&&this.onData(O.output.subarray(0,O.next_out)),ye=Nc.deflateEnd(this.strm),this.onEnd(ye),this.ended=!0,ye===Ot;if(O.avail_out!==0){if(ge>0&&O.next_out>0)this.onData(O.output.subarray(0,O.next_out)),O.avail_out=0;else if(O.avail_in===0)break}else this.onData(O.output)}return!0},Fi.prototype.onData=function(L){this.chunks.push(L)},Fi.prototype.onEnd=function(L){L===Ot&&(this.result=J4(this.chunks)),this.chunks=[],this.err=L,this.msg=this.strm.msg};var xo={Deflate:Fi,deflate:to,deflateRaw:function(L,X){return(X=X||{}).raw=!0,to(L,X)},gzip:function(L,X){return(X=X||{}).gzip=!0,to(L,X)}};const ji=16209;var qt=function(L,X){let O,ke,ye,ge,tt,Oe,wt,Ve,et,ii,Ht,Ct,Xo,Si,Qt,Oi,ti,kt,ei,Ui,Pt,Ei,oi,Gt;const fi=L.state;O=L.next_in,oi=L.input,ke=O+(L.avail_in-5),ye=L.next_out,Gt=L.output,ge=ye-(X-L.avail_out),tt=ye+(L.avail_out-257),Oe=fi.dmax,wt=fi.wsize,Ve=fi.whave,et=fi.wnext,ii=fi.window,Ht=fi.hold,Ct=fi.bits,Xo=fi.lencode,Si=fi.distcode,Qt=(1<<fi.lenbits)-1,Oi=(1<<fi.distbits)-1;e:do{Ct<15&&(Ht+=oi[O++]<<Ct,Ct+=8,Ht+=oi[O++]<<Ct,Ct+=8),ti=Xo[Ht&Qt];t:for(;;){if(kt=ti>>>24,Ht>>>=kt,Ct-=kt,kt=ti>>>16&255,kt===0)Gt[ye++]=65535&ti;else{if(!(16&kt)){if((64&kt)==0){ti=Xo[(65535&ti)+(Ht&(1<<kt)-1)];continue t}if(32&kt){fi.mode=16191;break e}L.msg="invalid literal/length code",fi.mode=ji;break e}ei=65535&ti,kt&=15,kt&&(Ct<kt&&(Ht+=oi[O++]<<Ct,Ct+=8),ei+=Ht&(1<<kt)-1,Ht>>>=kt,Ct-=kt),Ct<15&&(Ht+=oi[O++]<<Ct,Ct+=8,Ht+=oi[O++]<<Ct,Ct+=8),ti=Si[Ht&Oi];i:for(;;){if(kt=ti>>>24,Ht>>>=kt,Ct-=kt,kt=ti>>>16&255,!(16&kt)){if((64&kt)==0){ti=Si[(65535&ti)+(Ht&(1<<kt)-1)];continue i}L.msg="invalid distance code",fi.mode=ji;break e}if(Ui=65535&ti,kt&=15,Ct<kt&&(Ht+=oi[O++]<<Ct,Ct+=8,Ct<kt&&(Ht+=oi[O++]<<Ct,Ct+=8)),Ui+=Ht&(1<<kt)-1,Ui>Oe){L.msg="invalid distance too far back",fi.mode=ji;break e}if(Ht>>>=kt,Ct-=kt,kt=ye-ge,Ui>kt){if(kt=Ui-kt,kt>Ve&&fi.sane){L.msg="invalid distance too far back",fi.mode=ji;break e}if(Pt=0,Ei=ii,et===0){if(Pt+=wt-kt,kt<ei){ei-=kt;do Gt[ye++]=ii[Pt++];while(--kt);Pt=ye-Ui,Ei=Gt}}else if(et<kt){if(Pt+=wt+et-kt,kt-=et,kt<ei){ei-=kt;do Gt[ye++]=ii[Pt++];while(--kt);if(Pt=0,et<ei){kt=et,ei-=kt;do Gt[ye++]=ii[Pt++];while(--kt);Pt=ye-Ui,Ei=Gt}}}else if(Pt+=et-kt,kt<ei){ei-=kt;do Gt[ye++]=ii[Pt++];while(--kt);Pt=ye-Ui,Ei=Gt}for(;ei>2;)Gt[ye++]=Ei[Pt++],Gt[ye++]=Ei[Pt++],Gt[ye++]=Ei[Pt++],ei-=3;ei&&(Gt[ye++]=Ei[Pt++],ei>1&&(Gt[ye++]=Ei[Pt++]))}else{Pt=ye-Ui;do Gt[ye++]=Gt[Pt++],Gt[ye++]=Gt[Pt++],Gt[ye++]=Gt[Pt++],ei-=3;while(ei>2);ei&&(Gt[ye++]=Gt[Pt++],ei>1&&(Gt[ye++]=Gt[Pt++]))}break}}break}}while(O<ke&&ye<tt);ei=Ct>>3,O-=ei,Ct-=ei<<3,Ht&=(1<<Ct)-1,L.next_in=O,L.next_out=ye,L.avail_in=O<ke?ke-O+5:5-(O-ke),L.avail_out=ye<tt?tt-ye+257:257-(ye-tt),fi.hold=Ht,fi.bits=Ct};const Ho=15,es=new Uint16Array([3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0]),oa=new Uint8Array([16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78]),jc=new Uint16Array([1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0]),fn=new Uint8Array([16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64]);var ts=(L,X,O,ke,ye,ge,tt,Oe)=>{const wt=Oe.bits;let Ve,et,ii,Ht,Ct,Xo,Si=0,Qt=0,Oi=0,ti=0,kt=0,ei=0,Ui=0,Pt=0,Ei=0,oi=0,Gt=null;const fi=new Uint16Array(16),An=new Uint16Array(16);let cm,e5,t5,i5=null;for(Si=0;Si<=Ho;Si++)fi[Si]=0;for(Qt=0;Qt<ke;Qt++)fi[X[O+Qt]]++;for(kt=wt,ti=Ho;ti>=1&&fi[ti]===0;ti--);if(kt>ti&&(kt=ti),ti===0)return ye[ge++]=20971520,ye[ge++]=20971520,Oe.bits=1,0;for(Oi=1;Oi<ti&&fi[Oi]===0;Oi++);for(kt<Oi&&(kt=Oi),Pt=1,Si=1;Si<=Ho;Si++)if(Pt<<=1,Pt-=fi[Si],Pt<0)return-1;if(Pt>0&&(L===0||ti!==1))return-1;for(An[1]=0,Si=1;Si<Ho;Si++)An[Si+1]=An[Si]+fi[Si];for(Qt=0;Qt<ke;Qt++)X[O+Qt]!==0&&(tt[An[X[O+Qt]]++]=Qt);if(L===0?(Gt=i5=tt,Xo=20):L===1?(Gt=es,i5=oa,Xo=257):(Gt=jc,i5=fn,Xo=0),oi=0,Qt=0,Si=Oi,Ct=ge,ei=kt,Ui=0,ii=-1,Ei=1<<kt,Ht=Ei-1,L===1&&Ei>852||L===2&&Ei>592)return 1;for(;;){cm=Si-Ui,tt[Qt]+1<Xo?(e5=0,t5=tt[Qt]):tt[Qt]>=Xo?(e5=i5[tt[Qt]-Xo],t5=Gt[tt[Qt]-Xo]):(e5=96,t5=0),Ve=1<<Si-Ui,et=1<<ei,Oi=et;do et-=Ve,ye[Ct+(oi>>Ui)+et]=cm<<24|e5<<16|t5|0;while(et!==0);for(Ve=1<<Si-1;oi&Ve;)Ve>>=1;if(Ve!==0?(oi&=Ve-1,oi+=Ve):oi=0,Qt++,--fi[Si]==0){if(Si===ti)break;Si=X[O+tt[Qt]]}if(Si>kt&&(oi&Ht)!==ii){for(Ui===0&&(Ui=kt),Ct+=Oi,ei=Si-Ui,Pt=1<<ei;ei+Ui<ti&&(Pt-=fi[ei+Ui],!(Pt<=0));)ei++,Pt<<=1;if(Ei+=1<<ei,L===1&&Ei>852||L===2&&Ei>592)return 1;ii=oi&Ht,ye[ii]=kt<<24|ei<<16|Ct-ge|0}}return oi!==0&&(ye[Ct+oi]=Si-Ui<<24|64<<16|0),Oe.bits=kt,0};const{Z_FINISH:mo,Z_BLOCK:Nn,Z_TREES:_r,Z_OK:ko,Z_STREAM_END:ra,Z_NEED_DICT:am,Z_STREAM_ERROR:sr,Z_DATA_ERROR:D_,Z_MEM_ERROR:R_,Z_BUF_ERROR:OAe,Z_DEFLATED:L_}=me,W4=16180,Y4=16190,Il=16191,mw=16192,vw=16194,X4=16199,$4=16200,yw=16206,To=16209,__=L=>(L>>>24&255)+(L>>>8&65280)+((65280&L)<<8)+((255&L)<<24);function UAe(){this.strm=null,this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new Uint16Array(320),this.work=new Uint16Array(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}const Au=L=>{if(!L)return 1;const X=L.state;return!X||X.strm!==L||X.mode<W4||X.mode>16211?1:0},F_=L=>{if(Au(L))return sr;const X=L.state;return L.total_in=L.total_out=X.total=0,L.msg="",X.wrap&&(L.adler=1&X.wrap),X.mode=W4,X.last=0,X.havedict=0,X.flags=-1,X.dmax=32768,X.head=null,X.hold=0,X.bits=0,X.lencode=X.lendyn=new Int32Array(852),X.distcode=X.distdyn=new Int32Array(592),X.sane=1,X.back=-1,ko},O_=L=>{if(Au(L))return sr;const X=L.state;return X.wsize=0,X.whave=0,X.wnext=0,F_(L)},U_=(L,X)=>{let O;if(Au(L))return sr;const ke=L.state;return X<0?(O=0,X=-X):(O=5+(X>>4),X<48&&(X&=15)),X&&(X<8||X>15)?sr:(ke.window!==null&&ke.wbits!==X&&(ke.window=null),ke.wrap=O,ke.wbits=X,O_(L))},N_=(L,X)=>{if(!L)return sr;const O=new UAe;L.state=O,O.strm=L,O.window=null,O.mode=W4;const ke=U_(L,X);return ke!==ko&&(L.state=null),ke};let bw,ww,j_=!0;const NAe=L=>{if(j_){bw=new Int32Array(512),ww=new Int32Array(32);let X=0;for(;X<144;)L.lens[X++]=8;for(;X<256;)L.lens[X++]=9;for(;X<280;)L.lens[X++]=7;for(;X<288;)L.lens[X++]=8;for(ts(1,L.lens,0,288,bw,0,L.work,{bits:9}),X=0;X<32;)L.lens[X++]=5;ts(2,L.lens,0,32,ww,0,L.work,{bits:5}),j_=!1}L.lencode=bw,L.lenbits=9,L.distcode=ww,L.distbits=5},V_=(L,X,O,ke)=>{let ye;const ge=L.state;return ge.window===null&&(ge.wsize=1<<ge.wbits,ge.wnext=0,ge.whave=0,ge.window=new Uint8Array(ge.wsize)),ke>=ge.wsize?(ge.window.set(X.subarray(O-ge.wsize,O),0),ge.wnext=0,ge.whave=ge.wsize):(ye=ge.wsize-ge.wnext,ye>ke&&(ye=ke),ge.window.set(X.subarray(O-ke,O-ke+ye),ge.wnext),(ke-=ye)?(ge.window.set(X.subarray(O-ke,O),0),ge.wnext=ke,ge.whave=ge.wsize):(ge.wnext+=ye,ge.wnext===ge.wsize&&(ge.wnext=0),ge.whave<ge.wsize&&(ge.whave+=ye))),0};var Sl={inflateReset:O_,inflateReset2:U_,inflateResetKeep:F_,inflateInit:L=>N_(L,15),inflateInit2:N_,inflate:(L,X)=>{let O,ke,ye,ge,tt,Oe,wt,Ve,et,ii,Ht,Ct,Xo,Si,Qt,Oi,ti,kt,ei,Ui,Pt,Ei,oi=0;const Gt=new Uint8Array(4);let fi,An;const cm=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]);if(Au(L)||!L.output||!L.input&&L.avail_in!==0)return sr;O=L.state,O.mode===Il&&(O.mode=mw),tt=L.next_out,ye=L.output,wt=L.avail_out,ge=L.next_in,ke=L.input,Oe=L.avail_in,Ve=O.hold,et=O.bits,ii=Oe,Ht=wt,Ei=ko;e:for(;;)switch(O.mode){case W4:if(O.wrap===0){O.mode=mw;break}for(;et<16;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}if(2&O.wrap&&Ve===35615){O.wbits===0&&(O.wbits=15),O.check=0,Gt[0]=255&Ve,Gt[1]=Ve>>>8&255,O.check=Fe(O.check,Gt,2,0),Ve=0,et=0,O.mode=16181;break}if(O.head&&(O.head.done=!1),!(1&O.wrap)||(((255&Ve)<<8)+(Ve>>8))%31){L.msg="incorrect header check",O.mode=To;break}if((15&Ve)!==L_){L.msg="unknown compression method",O.mode=To;break}if(Ve>>>=4,et-=4,Pt=8+(15&Ve),O.wbits===0&&(O.wbits=Pt),Pt>15||Pt>O.wbits){L.msg="invalid window size",O.mode=To;break}O.dmax=1<<O.wbits,O.flags=0,L.adler=O.check=1,O.mode=512&Ve?16189:Il,Ve=0,et=0;break;case 16181:for(;et<16;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}if(O.flags=Ve,(255&O.flags)!==L_){L.msg="unknown compression method",O.mode=To;break}if(57344&O.flags){L.msg="unknown header flags set",O.mode=To;break}O.head&&(O.head.text=Ve>>8&1),512&O.flags&&4&O.wrap&&(Gt[0]=255&Ve,Gt[1]=Ve>>>8&255,O.check=Fe(O.check,Gt,2,0)),Ve=0,et=0,O.mode=16182;case 16182:for(;et<32;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}O.head&&(O.head.time=Ve),512&O.flags&&4&O.wrap&&(Gt[0]=255&Ve,Gt[1]=Ve>>>8&255,Gt[2]=Ve>>>16&255,Gt[3]=Ve>>>24&255,O.check=Fe(O.check,Gt,4,0)),Ve=0,et=0,O.mode=16183;case 16183:for(;et<16;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}O.head&&(O.head.xflags=255&Ve,O.head.os=Ve>>8),512&O.flags&&4&O.wrap&&(Gt[0]=255&Ve,Gt[1]=Ve>>>8&255,O.check=Fe(O.check,Gt,2,0)),Ve=0,et=0,O.mode=16184;case 16184:if(1024&O.flags){for(;et<16;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}O.length=Ve,O.head&&(O.head.extra_len=Ve),512&O.flags&&4&O.wrap&&(Gt[0]=255&Ve,Gt[1]=Ve>>>8&255,O.check=Fe(O.check,Gt,2,0)),Ve=0,et=0}else O.head&&(O.head.extra=null);O.mode=16185;case 16185:if(1024&O.flags&&(Ct=O.length,Ct>Oe&&(Ct=Oe),Ct&&(O.head&&(Pt=O.head.extra_len-O.length,O.head.extra||(O.head.extra=new Uint8Array(O.head.extra_len)),O.head.extra.set(ke.subarray(ge,ge+Ct),Pt)),512&O.flags&&4&O.wrap&&(O.check=Fe(O.check,ke,Ct,ge)),Oe-=Ct,ge+=Ct,O.length-=Ct),O.length))break e;O.length=0,O.mode=16186;case 16186:if(2048&O.flags){if(Oe===0)break e;Ct=0;do Pt=ke[ge+Ct++],O.head&&Pt&&O.length<65536&&(O.head.name+=String.fromCharCode(Pt));while(Pt&&Ct<Oe);if(512&O.flags&&4&O.wrap&&(O.check=Fe(O.check,ke,Ct,ge)),Oe-=Ct,ge+=Ct,Pt)break e}else O.head&&(O.head.name=null);O.length=0,O.mode=16187;case 16187:if(4096&O.flags){if(Oe===0)break e;Ct=0;do Pt=ke[ge+Ct++],O.head&&Pt&&O.length<65536&&(O.head.comment+=String.fromCharCode(Pt));while(Pt&&Ct<Oe);if(512&O.flags&&4&O.wrap&&(O.check=Fe(O.check,ke,Ct,ge)),Oe-=Ct,ge+=Ct,Pt)break e}else O.head&&(O.head.comment=null);O.mode=16188;case 16188:if(512&O.flags){for(;et<16;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}if(4&O.wrap&&Ve!==(65535&O.check)){L.msg="header crc mismatch",O.mode=To;break}Ve=0,et=0}O.head&&(O.head.hcrc=O.flags>>9&1,O.head.done=!0),L.adler=O.check=0,O.mode=Il;break;case 16189:for(;et<32;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}L.adler=O.check=__(Ve),Ve=0,et=0,O.mode=Y4;case Y4:if(O.havedict===0)return L.next_out=tt,L.avail_out=wt,L.next_in=ge,L.avail_in=Oe,O.hold=Ve,O.bits=et,am;L.adler=O.check=1,O.mode=Il;case Il:if(X===Nn||X===_r)break e;case mw:if(O.last){Ve>>>=7&et,et-=7&et,O.mode=yw;break}for(;et<3;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}switch(O.last=1&Ve,Ve>>>=1,et-=1,3&Ve){case 0:O.mode=16193;break;case 1:if(NAe(O),O.mode=X4,X===_r){Ve>>>=2,et-=2;break e}break;case 2:O.mode=16196;break;case 3:L.msg="invalid block type",O.mode=To}Ve>>>=2,et-=2;break;case 16193:for(Ve>>>=7&et,et-=7&et;et<32;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}if((65535&Ve)!=(Ve>>>16^65535)){L.msg="invalid stored block lengths",O.mode=To;break}if(O.length=65535&Ve,Ve=0,et=0,O.mode=vw,X===_r)break e;case vw:O.mode=16195;case 16195:if(Ct=O.length,Ct){if(Ct>Oe&&(Ct=Oe),Ct>wt&&(Ct=wt),Ct===0)break e;ye.set(ke.subarray(ge,ge+Ct),tt),Oe-=Ct,ge+=Ct,wt-=Ct,tt+=Ct,O.length-=Ct;break}O.mode=Il;break;case 16196:for(;et<14;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}if(O.nlen=257+(31&Ve),Ve>>>=5,et-=5,O.ndist=1+(31&Ve),Ve>>>=5,et-=5,O.ncode=4+(15&Ve),Ve>>>=4,et-=4,O.nlen>286||O.ndist>30){L.msg="too many length or distance symbols",O.mode=To;break}O.have=0,O.mode=16197;case 16197:for(;O.have<O.ncode;){for(;et<3;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}O.lens[cm[O.have++]]=7&Ve,Ve>>>=3,et-=3}for(;O.have<19;)O.lens[cm[O.have++]]=0;if(O.lencode=O.lendyn,O.lenbits=7,fi={bits:O.lenbits},Ei=ts(0,O.lens,0,19,O.lencode,0,O.work,fi),O.lenbits=fi.bits,Ei){L.msg="invalid code lengths set",O.mode=To;break}O.have=0,O.mode=16198;case 16198:for(;O.have<O.nlen+O.ndist;){for(;oi=O.lencode[Ve&(1<<O.lenbits)-1],Qt=oi>>>24,Oi=oi>>>16&255,ti=65535&oi,!(Qt<=et);){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}if(ti<16)Ve>>>=Qt,et-=Qt,O.lens[O.have++]=ti;else{if(ti===16){for(An=Qt+2;et<An;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}if(Ve>>>=Qt,et-=Qt,O.have===0){L.msg="invalid bit length repeat",O.mode=To;break}Pt=O.lens[O.have-1],Ct=3+(3&Ve),Ve>>>=2,et-=2}else if(ti===17){for(An=Qt+3;et<An;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}Ve>>>=Qt,et-=Qt,Pt=0,Ct=3+(7&Ve),Ve>>>=3,et-=3}else{for(An=Qt+7;et<An;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}Ve>>>=Qt,et-=Qt,Pt=0,Ct=11+(127&Ve),Ve>>>=7,et-=7}if(O.have+Ct>O.nlen+O.ndist){L.msg="invalid bit length repeat",O.mode=To;break}for(;Ct--;)O.lens[O.have++]=Pt}}if(O.mode===To)break;if(O.lens[256]===0){L.msg="invalid code -- missing end-of-block",O.mode=To;break}if(O.lenbits=9,fi={bits:O.lenbits},Ei=ts(1,O.lens,0,O.nlen,O.lencode,0,O.work,fi),O.lenbits=fi.bits,Ei){L.msg="invalid literal/lengths set",O.mode=To;break}if(O.distbits=6,O.distcode=O.distdyn,fi={bits:O.distbits},Ei=ts(2,O.lens,O.nlen,O.ndist,O.distcode,0,O.work,fi),O.distbits=fi.bits,Ei){L.msg="invalid distances set",O.mode=To;break}if(O.mode=X4,X===_r)break e;case X4:O.mode=$4;case $4:if(Oe>=6&&wt>=258){L.next_out=tt,L.avail_out=wt,L.next_in=ge,L.avail_in=Oe,O.hold=Ve,O.bits=et,qt(L,Ht),tt=L.next_out,ye=L.output,wt=L.avail_out,ge=L.next_in,ke=L.input,Oe=L.avail_in,Ve=O.hold,et=O.bits,O.mode===Il&&(O.back=-1);break}for(O.back=0;oi=O.lencode[Ve&(1<<O.lenbits)-1],Qt=oi>>>24,Oi=oi>>>16&255,ti=65535&oi,!(Qt<=et);){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}if(Oi&&(240&Oi)==0){for(kt=Qt,ei=Oi,Ui=ti;oi=O.lencode[Ui+((Ve&(1<<kt+ei)-1)>>kt)],Qt=oi>>>24,Oi=oi>>>16&255,ti=65535&oi,!(kt+Qt<=et);){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}Ve>>>=kt,et-=kt,O.back+=kt}if(Ve>>>=Qt,et-=Qt,O.back+=Qt,O.length=ti,Oi===0){O.mode=16205;break}if(32&Oi){O.back=-1,O.mode=Il;break}if(64&Oi){L.msg="invalid literal/length code",O.mode=To;break}O.extra=15&Oi,O.mode=16201;case 16201:if(O.extra){for(An=O.extra;et<An;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}O.length+=Ve&(1<<O.extra)-1,Ve>>>=O.extra,et-=O.extra,O.back+=O.extra}O.was=O.length,O.mode=16202;case 16202:for(;oi=O.distcode[Ve&(1<<O.distbits)-1],Qt=oi>>>24,Oi=oi>>>16&255,ti=65535&oi,!(Qt<=et);){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}if((240&Oi)==0){for(kt=Qt,ei=Oi,Ui=ti;oi=O.distcode[Ui+((Ve&(1<<kt+ei)-1)>>kt)],Qt=oi>>>24,Oi=oi>>>16&255,ti=65535&oi,!(kt+Qt<=et);){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}Ve>>>=kt,et-=kt,O.back+=kt}if(Ve>>>=Qt,et-=Qt,O.back+=Qt,64&Oi){L.msg="invalid distance code",O.mode=To;break}O.offset=ti,O.extra=15&Oi,O.mode=16203;case 16203:if(O.extra){for(An=O.extra;et<An;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}O.offset+=Ve&(1<<O.extra)-1,Ve>>>=O.extra,et-=O.extra,O.back+=O.extra}if(O.offset>O.dmax){L.msg="invalid distance too far back",O.mode=To;break}O.mode=16204;case 16204:if(wt===0)break e;if(Ct=Ht-wt,O.offset>Ct){if(Ct=O.offset-Ct,Ct>O.whave&&O.sane){L.msg="invalid distance too far back",O.mode=To;break}Ct>O.wnext?(Ct-=O.wnext,Xo=O.wsize-Ct):Xo=O.wnext-Ct,Ct>O.length&&(Ct=O.length),Si=O.window}else Si=ye,Xo=tt-O.offset,Ct=O.length;Ct>wt&&(Ct=wt),wt-=Ct,O.length-=Ct;do ye[tt++]=Si[Xo++];while(--Ct);O.length===0&&(O.mode=$4);break;case 16205:if(wt===0)break e;ye[tt++]=O.length,wt--,O.mode=$4;break;case yw:if(O.wrap){for(;et<32;){if(Oe===0)break e;Oe--,Ve|=ke[ge++]<<et,et+=8}if(Ht-=wt,L.total_out+=Ht,O.total+=Ht,4&O.wrap&&Ht&&(L.adler=O.check=O.flags?Fe(O.check,ye,Ht,tt-Ht):Ce(O.check,ye,Ht,tt-Ht)),Ht=wt,4&O.wrap&&(O.flags?Ve:__(Ve))!==O.check){L.msg="incorrect data check",O.mode=To;break}Ve=0,et=0}O.mode=16207;case 16207:if(O.wrap&&O.flags){for(;et<32;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}if(4&O.wrap&&Ve!==(4294967295&O.total)){L.msg="incorrect length check",O.mode=To;break}Ve=0,et=0}O.mode=16208;case 16208:Ei=ra;break e;case To:Ei=D_;break e;case 16210:return R_;default:return sr}return L.next_out=tt,L.avail_out=wt,L.next_in=ge,L.avail_in=Oe,O.hold=Ve,O.bits=et,(O.wsize||Ht!==L.avail_out&&O.mode<To&&(O.mode<yw||X!==mo))&&V_(L,L.output,L.next_out,Ht-L.avail_out),ii-=L.avail_in,Ht-=L.avail_out,L.total_in+=ii,L.total_out+=Ht,O.total+=Ht,4&O.wrap&&Ht&&(L.adler=O.check=O.flags?Fe(O.check,ye,Ht,L.next_out-Ht):Ce(O.check,ye,Ht,L.next_out-Ht)),L.data_type=O.bits+(O.last?64:0)+(O.mode===Il?128:0)+(O.mode===X4||O.mode===vw?256:0),(ii===0&&Ht===0||X===mo)&&Ei===ko&&(Ei=OAe),Ei},inflateEnd:L=>{if(Au(L))return sr;let X=L.state;return X.window&&(X.window=null),L.state=null,ko},inflateGetHeader:(L,X)=>{if(Au(L))return sr;const O=L.state;return(2&O.wrap)==0?sr:(O.head=X,X.done=!1,ko)},inflateSetDictionary:(L,X)=>{const O=X.length;let ke,ye,ge;return Au(L)?sr:(ke=L.state,ke.wrap!==0&&ke.mode!==Y4?sr:ke.mode===Y4&&(ye=1,ye=Ce(ye,X,O,0),ye!==ke.check)?D_:(ge=V_(L,X,O,O),ge?(ke.mode=16210,R_):(ke.havedict=1,ko)))},inflateInfo:"pako inflate (from Nodeca project)"},jAe=function(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1};const H_=Object.prototype.toString,{Z_NO_FLUSH:VAe,Z_FINISH:HAe,Z_OK:sm,Z_STREAM_END:Cw,Z_NEED_DICT:xw,Z_STREAM_ERROR:zAe,Z_DATA_ERROR:z_,Z_MEM_ERROR:qAe}=me;function lm(L){this.options=K4({chunkSize:65536,windowBits:15,to:""},L||{});const X=this.options;X.raw&&X.windowBits>=0&&X.windowBits<16&&(X.windowBits=-X.windowBits,X.windowBits===0&&(X.windowBits=-15)),!(X.windowBits>=0&&X.windowBits<16)||L&&L.windowBits||(X.windowBits+=32),X.windowBits>15&&X.windowBits<48&&(15&X.windowBits)==0&&(X.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new nt,this.strm.avail_out=0;let O=Sl.inflateInit2(this.strm,X.windowBits);if(O!==sm)throw new Error(ve[O]);if(this.header=new jAe,Sl.inflateGetHeader(this.strm,this.header),X.dictionary&&(typeof X.dictionary=="string"?X.dictionary=nm(X.dictionary):H_.call(X.dictionary)==="[object ArrayBuffer]"&&(X.dictionary=new Uint8Array(X.dictionary)),X.raw&&(O=Sl.inflateSetDictionary(this.strm,X.dictionary),O!==sm)))throw new Error(ve[O])}function kw(L,X){const O=new lm(X);if(O.push(L),O.err)throw O.msg||ve[O.err];return O.result}lm.prototype.push=function(L,X){const O=this.strm,ke=this.options.chunkSize,ye=this.options.dictionary;let ge,tt,Oe;if(this.ended)return!1;for(tt=X===~~X?X:X===!0?HAe:VAe,H_.call(L)==="[object ArrayBuffer]"?O.input=new Uint8Array(L):O.input=L,O.next_in=0,O.avail_in=O.input.length;;){for(O.avail_out===0&&(O.output=new Uint8Array(ke),O.next_out=0,O.avail_out=ke),ge=Sl.inflate(O,tt),ge===xw&&ye&&(ge=Sl.inflateSetDictionary(O,ye),ge===sm?ge=Sl.inflate(O,tt):ge===z_&&(ge=xw));O.avail_in>0&&ge===Cw&&O.state.wrap>0&&L[O.next_in]!==0;)Sl.inflateReset(O),ge=Sl.inflate(O,tt);switch(ge){case zAe:case z_:case xw:case qAe:return this.onEnd(ge),this.ended=!0,!1}if(Oe=O.avail_out,O.next_out&&(O.avail_out===0||ge===Cw))if(this.options.to==="string"){let wt=Ke(O.output,O.next_out),Ve=O.next_out-wt,et=se(O.output,wt);O.next_out=Ve,O.avail_out=ke-Ve,Ve&&O.output.set(O.output.subarray(wt,wt+Ve),0),this.onData(et)}else this.onData(O.output.length===O.next_out?O.output:O.output.subarray(0,O.next_out));if(ge!==sm||Oe!==0){if(ge===Cw)return ge=Sl.inflateEnd(this.strm),this.onEnd(ge),this.ended=!0,!0;if(O.avail_in===0)break}}return!0},lm.prototype.onData=function(L){this.chunks.push(L)},lm.prototype.onEnd=function(L){L===sm&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=J4(this.chunks)),this.chunks=[],this.err=L,this.msg=this.strm.msg};var QAe={Inflate:lm,inflate:kw,inflateRaw:function(L,X){return(X=X||{}).raw=!0,kw(L,X)},ungzip:kw};const{Deflate:GAe,deflate:KAe,deflateRaw:JAe,gzip:ZAe}=xo,{Inflate:WAe,inflate:YAe,inflateRaw:XAe,ungzip:$Ae}=QAe;var q_=GAe,Q_=KAe,G_=JAe,K_=ZAe,J_=WAe,Z_=YAe,W_=XAe,Y_=$Ae,X_=me,ege={Deflate:q_,deflate:Q_,deflateRaw:G_,gzip:K_,Inflate:J_,inflate:Z_,inflateRaw:W_,ungzip:Y_,constants:X_};i.Deflate=q_,i.Inflate=J_,i.constants=X_,i.default=ege,i.deflate=Q_,i.deflateRaw=G_,i.gzip=K_,i.inflate=Z_,i.inflateRaw=W_,i.ungzip=Y_,Object.defineProperty(i,"__esModule",{value:!0})}))})(S9,S9.exports)),S9.exports}var hee=g_t();const m_t=Jm(hee),ks=tge({__proto__:null,default:m_t},[hee]);let Dn=window.pako||ks;Dn.inflate||(Dn=Dn.default);const v_t=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();function y_t(t){return{positions:t[0],normals:t[1],indices:t[2],edgeIndices:t[3],meshPositions:t[4],meshIndices:t[5],meshEdgesIndices:t[6],meshColors:t[7],entityIDs:t[8],entityMeshes:t[9],entityIsObjects:t[10],positionsDecodeMatrix:t[11]}}function b_t(t){return{positions:new Uint16Array(Dn.inflate(t.positions).buffer),normals:new Int8Array(Dn.inflate(t.normals).buffer),indices:new Uint32Array(Dn.inflate(t.indices).buffer),edgeIndices:new Uint32Array(Dn.inflate(t.edgeIndices).buffer),meshPositions:new Uint32Array(Dn.inflate(t.meshPositions).buffer),meshIndices:new Uint32Array(Dn.inflate(t.meshIndices).buffer),meshEdgesIndices:new Uint32Array(Dn.inflate(t.meshEdgesIndices).buffer),meshColors:new Uint8Array(Dn.inflate(t.meshColors).buffer),entityIDs:Dn.inflate(t.entityIDs,{to:"string"}),entityMeshes:new Uint32Array(Dn.inflate(t.entityMeshes).buffer),entityIsObjects:new Uint8Array(Dn.inflate(t.entityIsObjects).buffer),positionsDecodeMatrix:new Float32Array(Dn.inflate(t.positionsDecodeMatrix).buffer)}}function w_t(t,e,i,o,n,r){r.getNextId(),o.positionsCompression="precompressed",o.normalsCompression="precompressed";const a=i.positions,s=i.normals,l=i.indices,c=i.edgeIndices,d=i.meshPositions,u=i.meshIndices,h=i.meshEdgesIndices,p=i.meshColors,A=JSON.parse(i.entityIDs),f=i.entityMeshes,m=i.entityIsObjects,g=d.length,y=f.length;for(let v=0;v<y;v++){const w=A[v],x=e.globalizeObjectIds?C.globalizeObjectId(o.id,w):w,k=t.metaScene.metaObjects[x],B={},P={};if(k){if(e.excludeTypesMap&&k.type&&e.excludeTypesMap[k.type]||e.includeTypesMap&&k.type&&!e.includeTypesMap[k.type])continue;const S=e.objectDefaults?e.objectDefaults[k.type]||e.objectDefaults.DEFAULT:null;S&&(S.visible===!1&&(B.visible=!1),S.pickable===!1&&(B.pickable=!1),S.colorize&&(P.color=S.colorize),S.opacity!==void 0&&S.opacity!==null&&(P.opacity=S.opacity))}else if(e.excludeUnclassifiedObjects)continue;const E=v===y-1,T=[];for(let S=f[v],R=E?f.length:f[v+1];S<R;S++){const F=S===g-1,U=x+".mesh."+S,q=v_t(p.subarray(S*4,S*4+3)),V=p[S*4+3]/255;o.createMesh(mt.apply(P,{id:U,primitive:"triangles",positionsCompressed:a.subarray(d[S],F?a.length:d[S+1]),normalsCompressed:s.subarray(d[S],F?a.length:d[S+1]),indices:l.subarray(u[S],F?l.length:u[S+1]),edgeIndices:c.subarray(h[S],F?c.length:h[S+1]),positionsDecodeMatrix:i.positionsDecodeMatrix,color:q,opacity:V})),T.push(U)}o.createEntity(mt.apply(B,{id:x,isObject:m[v]===1,meshIds:T}))}}const pee={version:1,parse:function(t,e,i,o,n,r){const a=y_t(i),s=b_t(a);w_t(t,e,s,o,n,r)}};let Pr=window.pako||ks;Pr.inflate||(Pr=Pr.default);function C_t(t){return{positions:t[0],normals:t[1],indices:t[2],edgeIndices:t[3],meshPositions:t[4],meshIndices:t[5],meshEdgesIndices:t[6],meshColors:t[7],entityIDs:t[8],entityMeshes:t[9],entityIsObjects:t[10],positionsDecodeMatrix:t[11],entityMeshIds:t[12],entityMatrices:t[13],entityUsesInstancing:t[14]}}function x_t(t){return{positions:new Uint16Array(Pr.inflate(t.positions).buffer),normals:new Int8Array(Pr.inflate(t.normals).buffer),indices:new Uint32Array(Pr.inflate(t.indices).buffer),edgeIndices:new Uint32Array(Pr.inflate(t.edgeIndices).buffer),meshPositions:new Uint32Array(Pr.inflate(t.meshPositions).buffer),meshIndices:new Uint32Array(Pr.inflate(t.meshIndices).buffer),meshEdgesIndices:new Uint32Array(Pr.inflate(t.meshEdgesIndices).buffer),meshColors:new Uint8Array(Pr.inflate(t.meshColors).buffer),entityIDs:Pr.inflate(t.entityIDs,{to:"string"}),entityMeshes:new Uint32Array(Pr.inflate(t.entityMeshes).buffer),entityIsObjects:new Uint8Array(Pr.inflate(t.entityIsObjects).buffer),positionsDecodeMatrix:new Float32Array(Pr.inflate(t.positionsDecodeMatrix).buffer),entityMeshIds:new Uint32Array(Pr.inflate(t.entityMeshIds).buffer),entityMatrices:new Float32Array(Pr.inflate(t.entityMatrices).buffer),entityUsesInstancing:new Uint8Array(Pr.inflate(t.entityUsesInstancing).buffer)}}const k_t=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();function M_t(t,e,i,o,n,r){const a=r.getNextId();o.positionsCompression="precompressed",o.normalsCompression="precompressed";const s=i.positions,l=i.normals,c=i.indices,d=i.edgeIndices,u=i.meshPositions,h=i.meshIndices,p=i.meshEdgesIndices,A=i.meshColors,f=JSON.parse(i.entityIDs),m=i.entityMeshes,g=i.entityIsObjects,y=i.entityMeshIds,v=i.entityMatrices,w=i.entityUsesInstancing,x=u.length,k=m.length,B={};for(let P=0;P<k;P++){const E=f[P],T=e.globalizeObjectIds?C.globalizeObjectId(o.id,E):E,S=t.metaScene.metaObjects[T],R={},F={},U=v.subarray(P*16,P*16+16);if(S){if(e.excludeTypesMap&&S.type&&e.excludeTypesMap[S.type]||e.includeTypesMap&&S.type&&!e.includeTypesMap[S.type])continue;const W=e.objectDefaults?e.objectDefaults[S.type]||e.objectDefaults.DEFAULT:null;W&&(W.visible===!1&&(R.visible=!1),W.pickable===!1&&(R.pickable=!1),W.colorize&&(F.color=W.colorize),W.opacity!==void 0&&W.opacity!==null&&(F.opacity=W.opacity))}else if(e.excludeUnclassifiedObjects)continue;const q=P===k-1,V=[];for(let W=m[P],Y=q?y.length:m[P+1];W<Y;W++){const $=y[W],fe=$===x-1,Me=r.getNextId(),Se=k_t(A.subarray($*4,$*4+3)),qe=A[$*4+3]/255,Qe=s.subarray(u[$],fe?s.length:u[$+1]),Ce=l.subarray(u[$],fe?s.length:u[$+1]),Le=c.subarray(h[$],fe?c.length:h[$+1]),Fe=d.subarray(p[$],fe?d.length:p[$+1]);if(w[P]===1){const ve=`${a}.geometry.${Me}.${$}`;ve in B||(o.createGeometry({id:ve,positionsCompressed:Qe,normalsCompressed:Ce,indices:Le,edgeIndices:Fe,primitive:"triangles",positionsDecodeMatrix:i.positionsDecodeMatrix}),B[ve]=!0),o.createMesh(mt.apply(F,{id:Me,color:Se,opacity:qe,matrix:U,geometryId:ve})),V.push(Me)}else o.createMesh(mt.apply(F,{id:Me,primitive:"triangles",positionsCompressed:Qe,normalsCompressed:Ce,indices:Le,edgeIndices:Fe,positionsDecodeMatrix:i.positionsDecodeMatrix,color:Se,opacity:qe})),V.push(Me)}V.length&&o.createEntity(mt.apply(R,{id:T,isObject:g[P]===1,meshIds:V}))}}const fee={version:2,parse:function(t,e,i,o,n,r){const a=C_t(i),s=x_t(a);M_t(t,e,s,o,n,r)}};let yr=window.pako||ks;yr.inflate||(yr=yr.default);function B_t(t){return{positions:t[0],normals:t[1],indices:t[2],edgeIndices:t[3],meshPositions:t[4],meshIndices:t[5],meshEdgesIndices:t[6],meshColors:t[7],entityIDs:t[8],entityMeshes:t[9],entityIsObjects:t[10],instancedPositionsDecodeMatrix:t[11],batchedPositionsDecodeMatrix:t[12],entityMeshIds:t[13],entityMatrices:t[14],entityUsesInstancing:t[15]}}function E_t(t){return{positions:new Uint16Array(yr.inflate(t.positions).buffer),normals:new Int8Array(yr.inflate(t.normals).buffer),indices:new Uint32Array(yr.inflate(t.indices).buffer),edgeIndices:new Uint32Array(yr.inflate(t.edgeIndices).buffer),meshPositions:new Uint32Array(yr.inflate(t.meshPositions).buffer),meshIndices:new Uint32Array(yr.inflate(t.meshIndices).buffer),meshEdgesIndices:new Uint32Array(yr.inflate(t.meshEdgesIndices).buffer),meshColors:new Uint8Array(yr.inflate(t.meshColors).buffer),entityIDs:yr.inflate(t.entityIDs,{to:"string"}),entityMeshes:new Uint32Array(yr.inflate(t.entityMeshes).buffer),entityIsObjects:new Uint8Array(yr.inflate(t.entityIsObjects).buffer),instancedPositionsDecodeMatrix:new Float32Array(yr.inflate(t.instancedPositionsDecodeMatrix).buffer),batchedPositionsDecodeMatrix:new Float32Array(yr.inflate(t.batchedPositionsDecodeMatrix).buffer),entityMeshIds:new Uint32Array(yr.inflate(t.entityMeshIds).buffer),entityMatrices:new Float32Array(yr.inflate(t.entityMatrices).buffer),entityUsesInstancing:new Uint8Array(yr.inflate(t.entityUsesInstancing).buffer)}}const P_t=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();function I_t(t,e,i,o,n,r){const a=r.getNextId();o.positionsCompression="precompressed",o.normalsCompression="precompressed";const s=i.positions,l=i.normals,c=i.indices,d=i.edgeIndices,u=i.meshPositions,h=i.meshIndices,p=i.meshEdgesIndices,A=i.meshColors,f=JSON.parse(i.entityIDs),m=i.entityMeshes,g=i.entityIsObjects,y=i.entityMeshIds,v=i.entityMatrices,w=i.entityUsesInstancing,x=u.length,k=m.length,B={};for(let F=0;F<k;F++){const U=f[F],q=e.globalizeObjectIds?C.globalizeObjectId(o.id,U):U,V=t.metaScene.metaObjects[q],W={},Y={},$=v.subarray(F*16,F*16+16);if(V){if(e.excludeTypesMap&&V.type&&e.excludeTypesMap[V.type]||e.includeTypesMap&&V.type&&!e.includeTypesMap[V.type])continue;const Se=e.objectDefaults?e.objectDefaults[V.type]||e.objectDefaults.DEFAULT:null;Se&&(Se.visible===!1&&(W.visible=!1),Se.pickable===!1&&(W.pickable=!1),Se.colorize&&(Y.color=Se.colorize),Se.opacity!==void 0&&Se.opacity!==null&&(Y.opacity=Se.opacity))}else if(e.excludeUnclassifiedObjects)continue;const fe=F===k-1,Me=[];for(let Se=m[F],qe=fe?y.length:m[F+1];Se<qe;Se++){var P=y[Se];const Qe=P===x-1,Ce=`${a}.${q}.mesh.${P}`,Le=P_t(A.subarray(P*4,P*4+3)),Fe=A[P*4+3]/255;var E=s.subarray(u[P],Qe?s.length:u[P+1]),T=l.subarray(u[P],Qe?s.length:u[P+1]),S=c.subarray(h[P],Qe?c.length:h[P+1]),R=d.subarray(p[P],Qe?d.length:p[P+1]);if(w[F]===1){const ve=`${a}.geometry.${Ce}.${P}`;ve in B||(o.createGeometry({id:ve,positionsCompressed:E,normalsCompressed:T,indices:S,edgeIndices:R,primitive:"triangles",positionsDecodeMatrix:i.instancedPositionsDecodeMatrix}),B[ve]=!0),o.createMesh(mt.apply(Y,{id:Ce,color:Le,opacity:Fe,matrix:$,geometryId:ve})),Me.push(Ce)}else o.createMesh(mt.apply(Y,{id:Ce,primitive:"triangles",positionsCompressed:E,normalsCompressed:T,indices:S,edgeIndices:R,positionsDecodeMatrix:i.batchedPositionsDecodeMatrix,color:Le,opacity:Fe})),Me.push(Ce)}Me.length&&o.createEntity(mt.apply(W,{id:q,isObject:g[F]===1,meshIds:Me}))}}const Aee={version:3,parse:function(t,e,i,o,n,r){const a=B_t(i),s=E_t(a);I_t(t,e,s,o,n,r)}};let Ir=window.pako||ks;Ir.inflate||(Ir=Ir.default);function S_t(t){return{positions:t[0],normals:t[1],indices:t[2],edgeIndices:t[3],decodeMatrices:t[4],matrices:t[5],eachPrimitivePositionsAndNormalsPortion:t[6],eachPrimitiveIndicesPortion:t[7],eachPrimitiveEdgeIndicesPortion:t[8],eachPrimitiveDecodeMatricesPortion:t[9],eachPrimitiveColor:t[10],primitiveInstances:t[11],eachEntityId:t[12],eachEntityPrimitiveInstancesPortion:t[13],eachEntityMatricesPortion:t[14],eachEntityMatrix:t[15]}}function T_t(t){return{positions:new Uint16Array(Ir.inflate(t.positions).buffer),normals:new Int8Array(Ir.inflate(t.normals).buffer),indices:new Uint32Array(Ir.inflate(t.indices).buffer),edgeIndices:new Uint32Array(Ir.inflate(t.edgeIndices).buffer),decodeMatrices:new Float32Array(Ir.inflate(t.decodeMatrices).buffer),matrices:new Float32Array(Ir.inflate(t.matrices).buffer),eachPrimitivePositionsAndNormalsPortion:new Uint32Array(Ir.inflate(t.eachPrimitivePositionsAndNormalsPortion).buffer),eachPrimitiveIndicesPortion:new Uint32Array(Ir.inflate(t.eachPrimitiveIndicesPortion).buffer),eachPrimitiveEdgeIndicesPortion:new Uint32Array(Ir.inflate(t.eachPrimitiveEdgeIndicesPortion).buffer),eachPrimitiveDecodeMatricesPortion:new Uint32Array(Ir.inflate(t.eachPrimitiveDecodeMatricesPortion).buffer),eachPrimitiveColor:new Uint8Array(Ir.inflate(t.eachPrimitiveColor).buffer),primitiveInstances:new Uint32Array(Ir.inflate(t.primitiveInstances).buffer),eachEntityId:Ir.inflate(t.eachEntityId,{to:"string"}),eachEntityPrimitiveInstancesPortion:new Uint32Array(Ir.inflate(t.eachEntityPrimitiveInstancesPortion).buffer),eachEntityMatricesPortion:new Uint32Array(Ir.inflate(t.eachEntityMatricesPortion).buffer)}}const D_t=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();function R_t(t,e,i,o,n,r){const a=r.getNextId();o.positionsCompression="precompressed",o.normalsCompression="precompressed";const s=i.positions,l=i.normals,c=i.indices,d=i.edgeIndices,u=i.decodeMatrices,h=i.matrices,p=i.eachPrimitivePositionsAndNormalsPortion,A=i.eachPrimitiveIndicesPortion,f=i.eachPrimitiveEdgeIndicesPortion,m=i.eachPrimitiveDecodeMatricesPortion,g=i.eachPrimitiveColor,y=i.primitiveInstances,v=JSON.parse(i.eachEntityId),w=i.eachEntityPrimitiveInstancesPortion,x=i.eachEntityMatricesPortion,k=p.length,B=y.length,P=new Uint8Array(k),E=new Uint32Array(k),T=v.length;for(let F=0;F<k;F++)E[F]=F;E.sort((F,U)=>m[F]<m[U]?-1:m[F]>m[U]?1:0);for(let F=0;F<B;F++){const U=y[F];P[U]++}const S={};for(let F=0;F<T;F++){const U=T-1,q=F===U,V=w[F],W=q?w[U]:w[F+1];for(let Y=V;Y<W;Y++){const $=y[Y];P[$]>1||(S[$]=F)}}for(let F=0;F<k;F++){const U=E[F],q=U===k-1,V=P[U]>1,W=D_t(g.subarray(U*4,U*4+3)),Y=g[U*4+3]/255,$=s.subarray(p[U],q?s.length:p[U+1]),fe=l.subarray(p[U],q?l.length:p[U+1]),Me=c.subarray(A[U],q?c.length:A[U+1]),Se=d.subarray(f[U],q?d.length:f[U+1]),qe=u.subarray(m[U],m[U]+16);if(V){const Qe=`${a}-geometry.${U}`;o.createGeometry({id:Qe,primitive:"triangles",positionsCompressed:$,normalsCompressed:fe,indices:Me,edgeIndices:Se,positionsDecodeMatrix:qe})}else{const Qe=`${a}-${U}`,Ce=S[U];v[Ce];const Le={};o.createMesh(mt.apply(Le,{id:Qe,primitive:"triangles",positionsCompressed:$,normalsCompressed:fe,indices:Me,edgeIndices:Se,positionsDecodeMatrix:qe,color:W,opacity:Y}))}}let R=0;for(let F=0;F<T;F++){const U=T-1,q=F===U,V=v[F],W=w[F],Y=q?w[U]:w[F+1],$=[];for(let fe=W;fe<Y;fe++){const Me=y[fe];if(P[Me]>1){const Se={},qe=`${a}-instance.${R++}`,Qe=`${a}-geometry.${Me}`,Ce=x[F]*16,Le=h.subarray(Ce,Ce+16);o.createMesh(mt.apply(Se,{id:qe,geometryId:Qe,matrix:Le})),$.push(qe)}else $.push(Me)}if($.length>0){const fe={};o.createEntity(mt.apply(fe,{id:V,isObject:!0,meshIds:$}))}}}const gee={version:4,parse:function(t,e,i,o,n,r){const a=S_t(i),s=T_t(a);R_t(t,e,s,o,n,r)}};let un=window.pako||ks;un.inflate||(un=un.default);function L_t(t){return{positions:t[0],normals:t[1],indices:t[2],edgeIndices:t[3],matrices:t[4],eachPrimitivePositionsAndNormalsPortion:t[5],eachPrimitiveIndicesPortion:t[6],eachPrimitiveEdgeIndicesPortion:t[7],eachPrimitiveColor:t[8],primitiveInstances:t[9],eachEntityId:t[10],eachEntityPrimitiveInstancesPortion:t[11],eachEntityMatricesPortion:t[12]}}function __t(t){return{positions:new Float32Array(un.inflate(t.positions).buffer),normals:new Int8Array(un.inflate(t.normals).buffer),indices:new Uint32Array(un.inflate(t.indices).buffer),edgeIndices:new Uint32Array(un.inflate(t.edgeIndices).buffer),matrices:new Float32Array(un.inflate(t.matrices).buffer),eachPrimitivePositionsAndNormalsPortion:new Uint32Array(un.inflate(t.eachPrimitivePositionsAndNormalsPortion).buffer),eachPrimitiveIndicesPortion:new Uint32Array(un.inflate(t.eachPrimitiveIndicesPortion).buffer),eachPrimitiveEdgeIndicesPortion:new Uint32Array(un.inflate(t.eachPrimitiveEdgeIndicesPortion).buffer),eachPrimitiveColor:new Uint8Array(un.inflate(t.eachPrimitiveColor).buffer),primitiveInstances:new Uint32Array(un.inflate(t.primitiveInstances).buffer),eachEntityId:un.inflate(t.eachEntityId,{to:"string"}),eachEntityPrimitiveInstancesPortion:new Uint32Array(un.inflate(t.eachEntityPrimitiveInstancesPortion).buffer),eachEntityMatricesPortion:new Uint32Array(un.inflate(t.eachEntityMatricesPortion).buffer)}}const F_t=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();function O_t(t,e,i,o,n,r){const a=r.getNextId();o.positionsCompression="disabled",o.normalsCompression="precompressed";const s=i.positions,l=i.normals,c=i.indices,d=i.edgeIndices,u=i.matrices,h=i.eachPrimitivePositionsAndNormalsPortion,p=i.eachPrimitiveIndicesPortion,A=i.eachPrimitiveEdgeIndicesPortion,f=i.eachPrimitiveColor,m=i.primitiveInstances,g=JSON.parse(i.eachEntityId),y=i.eachEntityPrimitiveInstancesPortion,v=i.eachEntityMatricesPortion,w=h.length,x=m.length,k=new Uint8Array(w),B=g.length;for(let T=0;T<x;T++){const S=m[T];k[S]++}const P={};for(let T=0;T<B;T++){const S=B-1,R=T===S,F=y[T],U=R?y[S]:y[T+1];for(let q=F;q<U;q++){const V=m[q];k[V]>1||(P[V]=T)}}for(let T=0;T<w;T++){const S=T===w-1,R=k[T]>1,F=F_t(f.subarray(T*4,T*4+3)),U=f[T*4+3]/255,q=s.subarray(h[T],S?s.length:h[T+1]),V=l.subarray(h[T],S?l.length:h[T+1]),W=c.subarray(p[T],S?c.length:p[T+1]),Y=d.subarray(A[T],S?d.length:A[T+1]);if(R){const $=`${a}-geometry.${T}`;o.createGeometry({id:$,primitive:"triangles",positionsCompressed:q,normalsCompressed:V,indices:W,edgeIndices:Y})}else{const $=T,fe=P[T];g[fe];const Me={};o.createMesh(mt.apply(Me,{id:$,primitive:"triangles",positionsCompressed:q,normalsCompressed:V,indices:W,edgeIndices:Y,color:F,opacity:U}))}}let E=0;for(let T=0;T<B;T++){const S=B-1,R=T===S,F=g[T],U=y[T],q=R?y[S]:y[T+1],V=[];for(let W=U;W<q;W++){const Y=m[W];if(k[Y]>1){const $={},fe="instance."+E++,Me="geometry"+Y,Se=v[T]*16,qe=u.subarray(Se,Se+16);o.createMesh(mt.apply($,{id:fe,geometryId:Me,matrix:qe})),V.push(fe)}else V.push(Y)}if(V.length>0){const W={};o.createEntity(mt.apply(W,{id:F,isObject:!0,meshIds:V}))}}}const mee={version:5,parse:function(t,e,i,o,n,r){const a=L_t(i),s=__t(a);O_t(t,e,s,o,n,r)}};let O3=window.pako||ks;O3.inflate||(O3=O3.default);function U_t(t){return{positions:t[0],normals:t[1],indices:t[2],edgeIndices:t[3],matrices:t[4],reusedPrimitivesDecodeMatrix:t[5],eachPrimitivePositionsAndNormalsPortion:t[6],eachPrimitiveIndicesPortion:t[7],eachPrimitiveEdgeIndicesPortion:t[8],eachPrimitiveColorAndOpacity:t[9],primitiveInstances:t[10],eachEntityId:t[11],eachEntityPrimitiveInstancesPortion:t[12],eachEntityMatricesPortion:t[13],eachTileAABB:t[14],eachTileEntitiesPortion:t[15]}}function N_t(t){function e(i,o){return i.length===0?[]:O3.inflate(i,o).buffer}return{positions:new Uint16Array(e(t.positions)),normals:new Int8Array(e(t.normals)),indices:new Uint32Array(e(t.indices)),edgeIndices:new Uint32Array(e(t.edgeIndices)),matrices:new Float32Array(e(t.matrices)),reusedPrimitivesDecodeMatrix:new Float32Array(e(t.reusedPrimitivesDecodeMatrix)),eachPrimitivePositionsAndNormalsPortion:new Uint32Array(e(t.eachPrimitivePositionsAndNormalsPortion)),eachPrimitiveIndicesPortion:new Uint32Array(e(t.eachPrimitiveIndicesPortion)),eachPrimitiveEdgeIndicesPortion:new Uint32Array(e(t.eachPrimitiveEdgeIndicesPortion)),eachPrimitiveColorAndOpacity:new Uint8Array(e(t.eachPrimitiveColorAndOpacity)),primitiveInstances:new Uint32Array(e(t.primitiveInstances)),eachEntityId:O3.inflate(t.eachEntityId,{to:"string"}),eachEntityPrimitiveInstancesPortion:new Uint32Array(e(t.eachEntityPrimitiveInstancesPortion)),eachEntityMatricesPortion:new Uint32Array(e(t.eachEntityMatricesPortion)),eachTileAABB:new Float64Array(e(t.eachTileAABB)),eachTileEntitiesPortion:new Uint32Array(e(t.eachTileEntitiesPortion))}}const j_t=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();function V_t(t,e,i,o,n,r){const a=r.getNextId(),s=i.positions,l=i.normals,c=i.indices,d=i.edgeIndices,u=i.matrices,h=i.reusedPrimitivesDecodeMatrix,p=i.eachPrimitivePositionsAndNormalsPortion,A=i.eachPrimitiveIndicesPortion,f=i.eachPrimitiveEdgeIndicesPortion,m=i.eachPrimitiveColorAndOpacity,g=i.primitiveInstances,y=JSON.parse(i.eachEntityId),v=i.eachEntityPrimitiveInstancesPortion,w=i.eachEntityMatricesPortion,x=i.eachTileAABB,k=i.eachTileEntitiesPortion,B=p.length,P=g.length,E=y.length,T=k.length,S=new Uint32Array(B);for(let U=0;U<P;U++){const q=g[U];S[q]!==void 0?S[q]++:S[q]=1}const R=C.vec3(),F=C.AABB3();for(let U=0;U<T;U++){const q=T-1,V=U===q,W=k[U],Y=V?E:k[U+1],$=U*6,fe=x.subarray($,$+6);C.getAABB3Center(fe,R),F[0]=fe[0]-R[0],F[1]=fe[1]-R[1],F[2]=fe[2]-R[2],F[3]=fe[3]-R[0],F[4]=fe[4]-R[1],F[5]=fe[5]-R[2];const Me=Jt.createPositionsDecodeMatrix(F),Se={};for(let qe=W;qe<Y;qe++){const Qe=y[qe],Ce=e.globalizeObjectIds?C.globalizeObjectId(o.id,Qe):Qe,Le=w[qe],Fe=u.slice(Le,Le+16),ve=E-1,me=qe===ve,we=v[qe],Re=me?g.length:v[qe+1],We=[],H=t.metaScene.metaObjects[Ce],ee={},ae={};if(H){if(e.excludeTypesMap&&H.type&&e.excludeTypesMap[H.type]||e.includeTypesMap&&H.type&&!e.includeTypesMap[H.type]||e.includeIdsMap&&H.id&&!e.includeIdsMap[H.id])continue;const Ee=e.objectDefaults?e.objectDefaults[H.type]||e.objectDefaults.DEFAULT:null;Ee&&(Ee.visible===!1&&(ee.visible=!1),Ee.pickable===!1&&(ee.pickable=!1),Ee.colorize&&(ae.color=Ee.colorize),Ee.opacity!==void 0&&Ee.opacity!==null&&(ae.opacity=Ee.opacity))}else if(e.excludeUnclassifiedObjects)continue;for(let Ee=we;Ee<Re;Ee++){const pe=g[Ee],Q=S[pe]>1,Z=pe===B-1,ie=s.subarray(p[pe],Z?s.length:p[pe+1]),re=l.subarray(p[pe],Z?l.length:p[pe+1]),ne=c.subarray(A[pe],Z?c.length:A[pe+1]),G=d.subarray(f[pe],Z?d.length:f[pe+1]),K=j_t(m.subarray(pe*4,pe*4+3)),ue=m[pe*4+3]/255,xe=r.getNextId();if(Q){const oe=`${a}-geometry.${U}.${pe}`;Se[oe]||(o.createGeometry({id:oe,primitive:"triangles",positionsCompressed:ie,indices:ne,edgeIndices:G,positionsDecodeMatrix:h}),Se[oe]=!0),o.createMesh(mt.apply(ae,{id:xe,geometryId:oe,origin:R,matrix:Fe,color:K,opacity:ue})),We.push(xe)}else o.createMesh(mt.apply(ae,{id:xe,origin:R,primitive:"triangles",positionsCompressed:ie,normalsCompressed:re,indices:ne,edgeIndices:G,positionsDecodeMatrix:Me,color:K,opacity:ue})),We.push(xe)}We.length>0&&o.createEntity(mt.apply(ee,{id:Ce,isObject:!0,meshIds:We}))}}}const vee={version:6,parse:function(t,e,i,o,n,r){const a=U_t(i),s=N_t(a);V_t(t,e,s,o,n,r)}};let U3=window.pako||ks;U3.inflate||(U3=U3.default);function H_t(t){return{positions:t[0],normals:t[1],colors:t[2],indices:t[3],edgeIndices:t[4],matrices:t[5],reusedGeometriesDecodeMatrix:t[6],eachGeometryPrimitiveType:t[7],eachGeometryPositionsPortion:t[8],eachGeometryNormalsPortion:t[9],eachGeometryColorsPortion:t[10],eachGeometryIndicesPortion:t[11],eachGeometryEdgeIndicesPortion:t[12],eachMeshGeometriesPortion:t[13],eachMeshMatricesPortion:t[14],eachMeshMaterial:t[15],eachEntityId:t[16],eachEntityMeshesPortion:t[17],eachTileAABB:t[18],eachTileEntitiesPortion:t[19]}}function z_t(t){function e(i,o){return i.length===0?[]:U3.inflate(i,o).buffer}return{positions:new Uint16Array(e(t.positions)),normals:new Int8Array(e(t.normals)),colors:new Uint8Array(e(t.colors)),indices:new Uint32Array(e(t.indices)),edgeIndices:new Uint32Array(e(t.edgeIndices)),matrices:new Float32Array(e(t.matrices)),reusedGeometriesDecodeMatrix:new Float32Array(e(t.reusedGeometriesDecodeMatrix)),eachGeometryPrimitiveType:new Uint8Array(e(t.eachGeometryPrimitiveType)),eachGeometryPositionsPortion:new Uint32Array(e(t.eachGeometryPositionsPortion)),eachGeometryNormalsPortion:new Uint32Array(e(t.eachGeometryNormalsPortion)),eachGeometryColorsPortion:new Uint32Array(e(t.eachGeometryColorsPortion)),eachGeometryIndicesPortion:new Uint32Array(e(t.eachGeometryIndicesPortion)),eachGeometryEdgeIndicesPortion:new Uint32Array(e(t.eachGeometryEdgeIndicesPortion)),eachMeshGeometriesPortion:new Uint32Array(e(t.eachMeshGeometriesPortion)),eachMeshMatricesPortion:new Uint32Array(e(t.eachMeshMatricesPortion)),eachMeshMaterial:new Uint8Array(e(t.eachMeshMaterial)),eachEntityId:U3.inflate(t.eachEntityId,{to:"string"}),eachEntityMeshesPortion:new Uint32Array(e(t.eachEntityMeshesPortion)),eachTileAABB:new Float64Array(e(t.eachTileAABB)),eachTileEntitiesPortion:new Uint32Array(e(t.eachTileEntitiesPortion))}}const q_t=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();function yee(t){const e=[];for(let i=0,o=t.length;i<o;i+=3)e.push(t[i]),e.push(t[i+1]),e.push(t[i+2]),e.push(1);return e}function Q_t(t,e,i,o,n,r){const a=r.getNextId(),s=i.positions,l=i.normals,c=i.colors,d=i.indices,u=i.edgeIndices,h=i.matrices,p=i.reusedGeometriesDecodeMatrix,A=i.eachGeometryPrimitiveType,f=i.eachGeometryPositionsPortion,m=i.eachGeometryNormalsPortion,g=i.eachGeometryColorsPortion,y=i.eachGeometryIndicesPortion,v=i.eachGeometryEdgeIndicesPortion,w=i.eachMeshGeometriesPortion,x=i.eachMeshMatricesPortion,k=i.eachMeshMaterial,B=JSON.parse(i.eachEntityId),P=i.eachEntityMeshesPortion,E=i.eachTileAABB,T=i.eachTileEntitiesPortion,S=f.length,R=w.length,F=B.length,U=T.length,q=new Uint32Array(S);for(let Y=0;Y<R;Y++){const $=w[Y];q[$]!==void 0?q[$]++:q[$]=1}const V=C.vec3(),W=C.AABB3();for(let Y=0;Y<U;Y++){const $=U-1,fe=Y===$,Me=T[Y],Se=fe?F:T[Y+1],qe=Y*6,Qe=E.subarray(qe,qe+6);C.getAABB3Center(Qe,V),W[0]=Qe[0]-V[0],W[1]=Qe[1]-V[1],W[2]=Qe[2]-V[2],W[3]=Qe[3]-V[0],W[4]=Qe[4]-V[1],W[5]=Qe[5]-V[2];const Ce=Jt.createPositionsDecodeMatrix(W),Le={};for(let Fe=Me;Fe<Se;Fe++){const ve=B[Fe],me=e.globalizeObjectIds?C.globalizeObjectId(o.id,ve):ve,we=F-1,Re=Fe===we,We=P[Fe],H=Re?w.length:P[Fe+1],ee=[],ae=t.metaScene.metaObjects[me],Ee={},pe={};if(ae){if(e.excludeTypesMap&&ae.type&&e.excludeTypesMap[ae.type]||e.includeTypesMap&&ae.type&&!e.includeTypesMap[ae.type]||e.includeIdsMap&&ae.id&&!e.includeIdsMap[ae.id])continue;const Q=e.objectDefaults?e.objectDefaults[ae.type]||e.objectDefaults.DEFAULT:null;Q&&(Q.visible===!1&&(Ee.visible=!1),Q.pickable===!1&&(Ee.pickable=!1),Q.colorize&&(pe.color=Q.colorize),Q.opacity!==void 0&&Q.opacity!==null&&(pe.opacity=Q.opacity),Q.metallic!==void 0&&Q.metallic!==null&&(pe.metallic=Q.metallic),Q.roughness!==void 0&&Q.roughness!==null&&(pe.roughness=Q.roughness))}else if(e.excludeUnclassifiedObjects)continue;for(let Q=We;Q<H;Q++){const Z=w[Q],ie=q[Z]>1,re=Z===S-1,ne=q_t(k.subarray(Q*6,Q*6+3)),G=k[Q*6+3]/255,K=k[Q*6+4]/255,ue=k[Q*6+5]/255,xe=r.getNextId();if(ie){const oe=x[Q],Be=h.slice(oe,oe+16),je=`${a}-geometry.${Y}.${Z}`;if(!Le[je]){const he=A[Z];let Ne,Pe,ze,rt,At,ft;switch(he){case 0:Ne="solid",Pe=s.subarray(f[Z],re?s.length:f[Z+1]),ze=l.subarray(m[Z],re?l.length:m[Z+1]),At=d.subarray(y[Z],re?d.length:y[Z+1]),ft=u.subarray(v[Z],re?u.length:v[Z+1]);break;case 1:Ne="surface",Pe=s.subarray(f[Z],re?s.length:f[Z+1]),ze=l.subarray(m[Z],re?l.length:m[Z+1]),At=d.subarray(y[Z],re?d.length:y[Z+1]),ft=u.subarray(v[Z],re?u.length:v[Z+1]);break;case 2:Ne="points",Pe=s.subarray(f[Z],re?s.length:f[Z+1]),rt=yee(c.subarray(g[Z],re?c.length:g[Z+1]));break;case 3:Ne="lines",Pe=s.subarray(f[Z],re?s.length:f[Z+1]),At=d.subarray(y[Z],re?d.length:y[Z+1]);break;default:continue}o.createGeometry({id:je,primitive:Ne,positionsCompressed:Pe,normalsCompressed:ze,colors:rt,indices:At,edgeIndices:ft,positionsDecodeMatrix:p}),Le[je]=!0}o.createMesh(mt.apply(pe,{id:xe,geometryId:je,origin:V,matrix:Be,color:ne,metallic:K,roughness:ue,opacity:G})),ee.push(xe)}else{const oe=A[Z];let Be,je,he,Ne,Pe,ze;switch(oe){case 0:Be="solid",je=s.subarray(f[Z],re?s.length:f[Z+1]),he=l.subarray(m[Z],re?l.length:m[Z+1]),Pe=d.subarray(y[Z],re?d.length:y[Z+1]),ze=u.subarray(v[Z],re?u.length:v[Z+1]);break;case 1:Be="surface",je=s.subarray(f[Z],re?s.length:f[Z+1]),he=l.subarray(m[Z],re?l.length:m[Z+1]),Pe=d.subarray(y[Z],re?d.length:y[Z+1]),ze=u.subarray(v[Z],re?u.length:v[Z+1]);break;case 2:Be="points",je=s.subarray(f[Z],re?s.length:f[Z+1]),Ne=yee(c.subarray(g[Z],re?c.length:g[Z+1]));break;case 3:Be="lines",je=s.subarray(f[Z],re?s.length:f[Z+1]),Pe=d.subarray(y[Z],re?d.length:y[Z+1]);break;default:continue}o.createMesh(mt.apply(pe,{id:xe,origin:V,primitive:Be,positionsCompressed:je,normalsCompressed:he,colors:Ne,indices:Pe,edgeIndices:ze,positionsDecodeMatrix:Ce,color:ne,metallic:K,roughness:ue,opacity:G})),ee.push(xe)}}ee.length>0&&o.createEntity(mt.apply(Ee,{id:me,isObject:!0,meshIds:ee}))}}}const bee={version:7,parse:function(t,e,i,o,n,r){const a=H_t(i),s=z_t(a);Q_t(t,e,s,o,n,r)}};let Ch=window.pako||ks;Ch.inflate||(Ch=Ch.default);const mc=C.vec4(),wee=C.vec4();function G_t(t){return{types:t[0],eachMetaObjectId:t[1],eachMetaObjectType:t[2],eachMetaObjectName:t[3],eachMetaObjectParent:t[4],positions:t[5],normals:t[6],colors:t[7],indices:t[8],edgeIndices:t[9],matrices:t[10],reusedGeometriesDecodeMatrix:t[11],eachGeometryPrimitiveType:t[12],eachGeometryPositionsPortion:t[13],eachGeometryNormalsPortion:t[14],eachGeometryColorsPortion:t[15],eachGeometryIndicesPortion:t[16],eachGeometryEdgeIndicesPortion:t[17],eachMeshGeometriesPortion:t[18],eachMeshMatricesPortion:t[19],eachMeshMaterial:t[20],eachEntityMetaObject:t[21],eachEntityMeshesPortion:t[22],eachTileAABB:t[23],eachTileEntitiesPortion:t[24]}}function K_t(t){function e(i,o){return i.length===0?[]:Ch.inflate(i,o).buffer}return{types:Ch.inflate(t.types,{to:"string"}),eachMetaObjectId:Ch.inflate(t.eachMetaObjectId,{to:"string"}),eachMetaObjectType:new Uint32Array(e(t.eachMetaObjectType)),eachMetaObjectName:Ch.inflate(t.eachMetaObjectName,{to:"string"}),eachMetaObjectParent:new Uint32Array(e(t.eachMetaObjectParent)),positions:new Uint16Array(e(t.positions)),normals:new Int8Array(e(t.normals)),colors:new Uint8Array(e(t.colors)),indices:new Uint32Array(e(t.indices)),edgeIndices:new Uint32Array(e(t.edgeIndices)),matrices:new Float32Array(e(t.matrices)),reusedGeometriesDecodeMatrix:new Float32Array(e(t.reusedGeometriesDecodeMatrix)),eachGeometryPrimitiveType:new Uint8Array(e(t.eachGeometryPrimitiveType)),eachGeometryPositionsPortion:new Uint32Array(e(t.eachGeometryPositionsPortion)),eachGeometryNormalsPortion:new Uint32Array(e(t.eachGeometryNormalsPortion)),eachGeometryColorsPortion:new Uint32Array(e(t.eachGeometryColorsPortion)),eachGeometryIndicesPortion:new Uint32Array(e(t.eachGeometryIndicesPortion)),eachGeometryEdgeIndicesPortion:new Uint32Array(e(t.eachGeometryEdgeIndicesPortion)),eachMeshGeometriesPortion:new Uint32Array(e(t.eachMeshGeometriesPortion)),eachMeshMatricesPortion:new Uint32Array(e(t.eachMeshMatricesPortion)),eachMeshMaterial:new Uint8Array(e(t.eachMeshMaterial)),eachEntityMetaObject:new Uint32Array(e(t.eachEntityMetaObject)),eachEntityMeshesPortion:new Uint32Array(e(t.eachEntityMeshesPortion)),eachTileAABB:new Float64Array(e(t.eachTileAABB)),eachTileEntitiesPortion:new Uint32Array(e(t.eachTileEntitiesPortion))}}const J_t=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();function Cee(t){const e=[];for(let i=0,o=t.length;i<o;i+=3)e.push(t[i]),e.push(t[i+1]),e.push(t[i+2]),e.push(1);return e}function Z_t(t,e,i,o,n,r){const a=r.getNextId(),s=JSON.parse(i.types),l=JSON.parse(i.eachMetaObjectId),c=i.eachMetaObjectType,d=JSON.parse(i.eachMetaObjectName),u=i.eachMetaObjectParent,h=i.positions,p=i.normals,A=i.colors,f=i.indices,m=i.edgeIndices,g=i.matrices,y=i.reusedGeometriesDecodeMatrix,v=i.eachGeometryPrimitiveType,w=i.eachGeometryPositionsPortion,x=i.eachGeometryNormalsPortion,k=i.eachGeometryColorsPortion,B=i.eachGeometryIndicesPortion,P=i.eachGeometryEdgeIndicesPortion,E=i.eachMeshGeometriesPortion,T=i.eachMeshMatricesPortion,S=i.eachMeshMaterial,R=i.eachEntityMetaObject,F=i.eachEntityMeshesPortion,U=i.eachTileAABB,q=i.eachTileEntitiesPortion,V=l.length,W=w.length,Y=E.length,$=R.length,fe=q.length;if(n){const Ce={metaObjects:[]};for(let Le=0;Le<V;Le++){const Fe=l[Le],ve=c[Le],me=s[ve]||"default",we=d[Le],Re=u[Le],We=Re!==Le?l[Re]:null;Ce.metaObjects.push({id:Fe,type:me,name:we,parent:We})}n.loadData(Ce,{includeTypes:e.includeTypes,excludeTypes:e.excludeTypes,globalizeObjectIds:e.globalizeObjectIds})}const Me=new Uint32Array(W);for(let Ce=0;Ce<Y;Ce++){const Le=E[Ce];Me[Le]!==void 0?Me[Le]++:Me[Le]=1}const Se=C.vec3(),qe=C.AABB3(),Qe={};for(let Ce=0;Ce<fe;Ce++){const Le=fe-1,Fe=Ce===Le,ve=q[Ce],me=Fe?$:q[Ce+1],we=Ce*6,Re=U.subarray(we,we+6);C.getAABB3Center(Re,Se),qe[0]=Re[0]-Se[0],qe[1]=Re[1]-Se[1],qe[2]=Re[2]-Se[2],qe[3]=Re[3]-Se[0],qe[4]=Re[4]-Se[1],qe[5]=Re[5]-Se[2];const We=Jt.createPositionsDecodeMatrix(qe),H={};for(let ee=ve;ee<me;ee++){const ae=R[ee],Ee=l[ae],pe=e.globalizeObjectIds?C.globalizeObjectId(o.id,Ee):Ee,Q=$-1,Z=ee===Q,ie=F[ee],re=Z?E.length:F[ee+1],ne=[],G=t.metaScene.metaObjects[pe],K={},ue={};if(G){if(e.excludeTypesMap&&G.type&&e.excludeTypesMap[G.type]||e.includeTypesMap&&G.type&&!e.includeTypesMap[G.type]||e.includeIdsMap&&G.id&&!e.includeIdsMap[G.id])continue;const xe=e.objectDefaults?e.objectDefaults[G.type]||e.objectDefaults.DEFAULT:null;xe&&(xe.visible===!1&&(K.visible=!1),xe.pickable===!1&&(K.pickable=!1),xe.colorize&&(ue.color=xe.colorize),xe.opacity!==void 0&&xe.opacity!==null&&(ue.opacity=xe.opacity),xe.metallic!==void 0&&xe.metallic!==null&&(ue.metallic=xe.metallic),xe.roughness!==void 0&&xe.roughness!==null&&(ue.roughness=xe.roughness))}else if(e.excludeUnclassifiedObjects)continue;for(let xe=ie;xe<re;xe++){const oe=E[xe],Be=Me[oe]>1,je=oe===W-1,he=J_t(S.subarray(xe*6,xe*6+3)),Ne=S[xe*6+3]/255,Pe=S[xe*6+4]/255,ze=S[xe*6+5]/255,rt=r.getNextId();if(Be){const At=T[xe],ft=g.slice(At,At+16),lt=`${a}-geometry.${Ce}.${oe}`;let ut=Qe[lt];if(!ut){ut={batchThisMesh:!e.reuseGeometries};const Te=v[oe];let st=!1;switch(Te){case 0:ut.primitiveName="solid",ut.geometryPositions=h.subarray(w[oe],je?h.length:w[oe+1]),ut.geometryNormals=p.subarray(x[oe],je?p.length:x[oe+1]),ut.geometryIndices=f.subarray(B[oe],je?f.length:B[oe+1]),ut.geometryEdgeIndices=m.subarray(P[oe],je?m.length:P[oe+1]),st=ut.geometryPositions.length>0&&ut.geometryIndices.length>0;break;case 1:ut.primitiveName="surface",ut.geometryPositions=h.subarray(w[oe],je?h.length:w[oe+1]),ut.geometryNormals=p.subarray(x[oe],je?p.length:x[oe+1]),ut.geometryIndices=f.subarray(B[oe],je?f.length:B[oe+1]),ut.geometryEdgeIndices=m.subarray(P[oe],je?m.length:P[oe+1]),st=ut.geometryPositions.length>0&&ut.geometryIndices.length>0;break;case 2:ut.primitiveName="points",ut.geometryPositions=h.subarray(w[oe],je?h.length:w[oe+1]),ut.geometryColors=Cee(A.subarray(k[oe],je?A.length:k[oe+1])),st=ut.geometryPositions.length>0;break;case 3:ut.primitiveName="lines",ut.geometryPositions=h.subarray(w[oe],je?h.length:w[oe+1]),ut.geometryIndices=f.subarray(B[oe],je?f.length:B[oe+1]),st=ut.geometryPositions.length>0&&ut.geometryIndices.length>0;break;default:continue}if(st||(ut=null),ut&&(ut.geometryPositions.length>1e3,ut.batchThisMesh)){ut.decompressedPositions=new Float32Array(ut.geometryPositions.length);const dt=ut.geometryPositions,Ye=ut.decompressedPositions;for(let Ae=0,be=dt.length;Ae<be;Ae+=3)Ye[Ae+0]=dt[Ae+0]*y[0]+y[12],Ye[Ae+1]=dt[Ae+1]*y[5]+y[13],Ye[Ae+2]=dt[Ae+2]*y[10]+y[14];ut.geometryPositions=null,Qe[lt]=ut}}if(ut)if(ut.batchThisMesh){const Te=ut.decompressedPositions,st=new Uint16Array(Te.length);for(let dt=0,Ye=Te.length;dt<Ye;dt+=3)mc[0]=Te[dt+0],mc[1]=Te[dt+1],mc[2]=Te[dt+2],mc[3]=1,C.transformVec4(ft,mc,wee),Jt.compressPosition(wee,qe,mc),st[dt+0]=mc[0],st[dt+1]=mc[1],st[dt+2]=mc[2];o.createMesh(mt.apply(ue,{id:rt,origin:Se,primitive:ut.primitiveName,positionsCompressed:st,normalsCompressed:ut.geometryNormals,colorsCompressed:ut.geometryColors,indices:ut.geometryIndices,edgeIndices:ut.geometryEdgeIndices,positionsDecodeMatrix:We,color:he,metallic:Pe,roughness:ze,opacity:Ne})),ne.push(rt)}else H[lt]||(o.createGeometry({id:lt,primitive:ut.primitiveName,positionsCompressed:ut.geometryPositions,normalsCompressed:ut.geometryNormals,colorsCompressed:ut.geometryColors,indices:ut.geometryIndices,edgeIndices:ut.geometryEdgeIndices,positionsDecodeMatrix:y}),H[lt]=!0),o.createMesh(mt.apply(ue,{id:rt,geometryId:lt,origin:Se,matrix:ft,color:he,metallic:Pe,roughness:ze,opacity:Ne})),ne.push(rt)}else{const At=v[oe];let ft,lt,ut,Te,st,dt,Ye=!1;switch(At){case 0:ft="solid",lt=h.subarray(w[oe],je?h.length:w[oe+1]),ut=p.subarray(x[oe],je?p.length:x[oe+1]),st=f.subarray(B[oe],je?f.length:B[oe+1]),dt=m.subarray(P[oe],je?m.length:P[oe+1]),Ye=lt.length>0&&st.length>0;break;case 1:ft="surface",lt=h.subarray(w[oe],je?h.length:w[oe+1]),ut=p.subarray(x[oe],je?p.length:x[oe+1]),st=f.subarray(B[oe],je?f.length:B[oe+1]),dt=m.subarray(P[oe],je?m.length:P[oe+1]),Ye=lt.length>0&&st.length>0;break;case 2:ft="points",lt=h.subarray(w[oe],je?h.length:w[oe+1]),Te=Cee(A.subarray(k[oe],je?A.length:k[oe+1])),Ye=lt.length>0;break;case 3:ft="lines",lt=h.subarray(w[oe],je?h.length:w[oe+1]),st=f.subarray(B[oe],je?f.length:B[oe+1]),Ye=lt.length>0&&st.length>0;break;default:continue}Ye&&(o.createMesh(mt.apply(ue,{id:rt,origin:Se,primitive:ft,positionsCompressed:lt,normalsCompressed:ut,colorsCompressed:Te,indices:st,edgeIndices:dt,positionsDecodeMatrix:We,color:he,metallic:Pe,roughness:ze,opacity:Ne})),ne.push(rt))}}ne.length>0&&o.createEntity(mt.apply(K,{id:pe,isObject:!0,meshIds:ne}))}}}const xee={version:8,parse:function(t,e,i,o,n,r){const a=G_t(i),s=K_t(a);Z_t(t,e,s,o,n,r)}};let q1=window.pako||ks;q1.inflate||(q1=q1.default);const vc=C.vec4(),kee=C.vec4();function W_t(t){return{metadata:t[0],positions:t[1],normals:t[2],colors:t[3],indices:t[4],edgeIndices:t[5],matrices:t[6],reusedGeometriesDecodeMatrix:t[7],eachGeometryPrimitiveType:t[8],eachGeometryPositionsPortion:t[9],eachGeometryNormalsPortion:t[10],eachGeometryColorsPortion:t[11],eachGeometryIndicesPortion:t[12],eachGeometryEdgeIndicesPortion:t[13],eachMeshGeometriesPortion:t[14],eachMeshMatricesPortion:t[15],eachMeshMaterial:t[16],eachEntityId:t[17],eachEntityMeshesPortion:t[18],eachTileAABB:t[19],eachTileEntitiesPortion:t[20]}}function Y_t(t){function e(i,o){return i.length===0?[]:q1.inflate(i,o).buffer}return{metadata:JSON.parse(q1.inflate(t.metadata,{to:"string"})),positions:new Uint16Array(e(t.positions)),normals:new Int8Array(e(t.normals)),colors:new Uint8Array(e(t.colors)),indices:new Uint32Array(e(t.indices)),edgeIndices:new Uint32Array(e(t.edgeIndices)),matrices:new Float32Array(e(t.matrices)),reusedGeometriesDecodeMatrix:new Float32Array(e(t.reusedGeometriesDecodeMatrix)),eachGeometryPrimitiveType:new Uint8Array(e(t.eachGeometryPrimitiveType)),eachGeometryPositionsPortion:new Uint32Array(e(t.eachGeometryPositionsPortion)),eachGeometryNormalsPortion:new Uint32Array(e(t.eachGeometryNormalsPortion)),eachGeometryColorsPortion:new Uint32Array(e(t.eachGeometryColorsPortion)),eachGeometryIndicesPortion:new Uint32Array(e(t.eachGeometryIndicesPortion)),eachGeometryEdgeIndicesPortion:new Uint32Array(e(t.eachGeometryEdgeIndicesPortion)),eachMeshGeometriesPortion:new Uint32Array(e(t.eachMeshGeometriesPortion)),eachMeshMatricesPortion:new Uint32Array(e(t.eachMeshMatricesPortion)),eachMeshMaterial:new Uint8Array(e(t.eachMeshMaterial)),eachEntityId:JSON.parse(q1.inflate(t.eachEntityId,{to:"string"})),eachEntityMeshesPortion:new Uint32Array(e(t.eachEntityMeshesPortion)),eachTileAABB:new Float64Array(e(t.eachTileAABB)),eachTileEntitiesPortion:new Uint32Array(e(t.eachTileEntitiesPortion))}}const X_t=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();function $_t(t,e,i,o,n,r){const a=r.getNextId(),s=i.metadata,l=i.positions,c=i.normals,d=i.colors,u=i.indices,h=i.edgeIndices,p=i.matrices,A=i.reusedGeometriesDecodeMatrix,f=i.eachGeometryPrimitiveType,m=i.eachGeometryPositionsPortion,g=i.eachGeometryNormalsPortion,y=i.eachGeometryColorsPortion,v=i.eachGeometryIndicesPortion,w=i.eachGeometryEdgeIndicesPortion,x=i.eachMeshGeometriesPortion,k=i.eachMeshMatricesPortion,B=i.eachMeshMaterial,P=i.eachEntityId,E=i.eachEntityMeshesPortion,T=i.eachTileAABB,S=i.eachTileEntitiesPortion,R=m.length,F=x.length,U=E.length,q=S.length;n&&n.loadData(s,{includeTypes:e.includeTypes,excludeTypes:e.excludeTypes,globalizeObjectIds:e.globalizeObjectIds});const V=new Uint32Array(R);for(let fe=0;fe<F;fe++){const Me=x[fe];V[Me]!==void 0?V[Me]++:V[Me]=1}const W=C.vec3(),Y=C.AABB3(),$={};for(let fe=0;fe<q;fe++){const Me=q-1,Se=fe===Me,qe=S[fe],Qe=Se?U-1:S[fe+1]-1,Ce=fe*6,Le=T.subarray(Ce,Ce+6);C.getAABB3Center(Le,W),Y[0]=Le[0]-W[0],Y[1]=Le[1]-W[1],Y[2]=Le[2]-W[2],Y[3]=Le[3]-W[0],Y[4]=Le[4]-W[1],Y[5]=Le[5]-W[2];const Fe=Jt.createPositionsDecodeMatrix(Y),ve={};for(let me=qe;me<=Qe;me++){const we=P[me],Re=e.globalizeObjectIds?C.globalizeObjectId(o.id,we):we,We=U-1,H=me===We,ee=E[me],ae=H?x.length-1:E[me+1]-1,Ee=[],pe=t.metaScene.metaObjects[Re],Q={},Z={};if(!(e.includeIdsMap&&we&&!e.includeIdsMap[we])){if(pe){if(e.excludeTypesMap&&pe.type&&e.excludeTypesMap[pe.type]||e.includeTypesMap&&pe.type&&!e.includeTypesMap[pe.type]||e.includeIdsMap&&pe.id&&!e.includeIdsMap[pe.id])continue;const ie=e.objectDefaults?e.objectDefaults[pe.type]||e.objectDefaults.DEFAULT:null;ie&&(ie.visible===!1&&(Q.visible=!1),ie.pickable===!1&&(Q.pickable=!1),ie.colorize&&(Z.color=ie.colorize),ie.opacity!==void 0&&ie.opacity!==null&&(Z.opacity=ie.opacity),ie.metallic!==void 0&&ie.metallic!==null&&(Z.metallic=ie.metallic),ie.roughness!==void 0&&ie.roughness!==null&&(Z.roughness=ie.roughness))}else if(e.excludeUnclassifiedObjects)continue;for(let ie=ee;ie<=ae;ie++){const re=x[ie],ne=V[re]>1,G=re===R-1,K=X_t(B.subarray(ie*6,ie*6+3)),ue=B[ie*6+3]/255,xe=B[ie*6+4]/255,oe=B[ie*6+5]/255,Be=r.getNextId();if(ne){const je=k[ie],he=p.slice(je,je+16),Ne=`${a}-geometry.${fe}.${re}`;let Pe=$[Ne];if(!Pe){Pe={batchThisMesh:!e.reuseGeometries};const ze=f[re];let rt=!1;switch(ze){case 0:Pe.primitiveName="solid",Pe.geometryPositions=l.subarray(m[re],G?l.length:m[re+1]),Pe.geometryNormals=c.subarray(g[re],G?c.length:g[re+1]),Pe.geometryIndices=u.subarray(v[re],G?u.length:v[re+1]),Pe.geometryEdgeIndices=h.subarray(w[re],G?h.length:w[re+1]),rt=Pe.geometryPositions.length>0&&Pe.geometryIndices.length>0;break;case 1:Pe.primitiveName="surface",Pe.geometryPositions=l.subarray(m[re],G?l.length:m[re+1]),Pe.geometryNormals=c.subarray(g[re],G?c.length:g[re+1]),Pe.geometryIndices=u.subarray(v[re],G?u.length:v[re+1]),Pe.geometryEdgeIndices=h.subarray(w[re],G?h.length:w[re+1]),rt=Pe.geometryPositions.length>0&&Pe.geometryIndices.length>0;break;case 2:Pe.primitiveName="points",Pe.geometryPositions=l.subarray(m[re],G?l.length:m[re+1]),Pe.geometryColors=d.subarray(y[re],G?d.length:y[re+1]),rt=Pe.geometryPositions.length>0;break;case 3:Pe.primitiveName="lines",Pe.geometryPositions=l.subarray(m[re],G?l.length:m[re+1]),Pe.geometryIndices=u.subarray(v[re],G?u.length:v[re+1]),rt=Pe.geometryPositions.length>0&&Pe.geometryIndices.length>0;break;default:continue}if(rt||(Pe=null),Pe&&(Pe.geometryPositions.length>1e3,Pe.batchThisMesh)){Pe.decompressedPositions=new Float32Array(Pe.geometryPositions.length),Pe.transformedAndRecompressedPositions=new Uint16Array(Pe.geometryPositions.length);const At=Pe.geometryPositions,ft=Pe.decompressedPositions;for(let lt=0,ut=At.length;lt<ut;lt+=3)ft[lt+0]=At[lt+0]*A[0]+A[12],ft[lt+1]=At[lt+1]*A[5]+A[13],ft[lt+2]=At[lt+2]*A[10]+A[14];Pe.geometryPositions=null,$[Ne]=Pe}}if(Pe)if(Pe.batchThisMesh){const ze=Pe.decompressedPositions,rt=Pe.transformedAndRecompressedPositions;for(let At=0,ft=ze.length;At<ft;At+=3)vc[0]=ze[At+0],vc[1]=ze[At+1],vc[2]=ze[At+2],vc[3]=1,C.transformVec4(he,vc,kee),Jt.compressPosition(kee,Y,vc),rt[At+0]=vc[0],rt[At+1]=vc[1],rt[At+2]=vc[2];o.createMesh(mt.apply(Z,{id:Be,origin:W,primitive:Pe.primitiveName,positionsCompressed:rt,normalsCompressed:Pe.geometryNormals,colorsCompressed:Pe.geometryColors,indices:Pe.geometryIndices,edgeIndices:Pe.geometryEdgeIndices,positionsDecodeMatrix:Fe,color:K,metallic:xe,roughness:oe,opacity:ue})),Ee.push(Be)}else ve[Ne]||(o.createGeometry({id:Ne,primitive:Pe.primitiveName,positionsCompressed:Pe.geometryPositions,normalsCompressed:Pe.geometryNormals,colorsCompressed:Pe.geometryColors,indices:Pe.geometryIndices,edgeIndices:Pe.geometryEdgeIndices,positionsDecodeMatrix:A}),ve[Ne]=!0),o.createMesh(mt.apply(Z,{id:Be,geometryId:Ne,origin:W,matrix:he,color:K,metallic:xe,roughness:oe,opacity:ue})),Ee.push(Be)}else{const je=f[re];let he,Ne,Pe,ze,rt,At,ft=!1;switch(je){case 0:he="solid",Ne=l.subarray(m[re],G?l.length:m[re+1]),Pe=c.subarray(g[re],G?c.length:g[re+1]),rt=u.subarray(v[re],G?u.length:v[re+1]),At=h.subarray(w[re],G?h.length:w[re+1]),ft=Ne.length>0&&rt.length>0;break;case 1:he="surface",Ne=l.subarray(m[re],G?l.length:m[re+1]),Pe=c.subarray(g[re],G?c.length:g[re+1]),rt=u.subarray(v[re],G?u.length:v[re+1]),At=h.subarray(w[re],G?h.length:w[re+1]),ft=Ne.length>0&&rt.length>0;break;case 2:he="points",Ne=l.subarray(m[re],G?l.length:m[re+1]),ze=d.subarray(y[re],G?d.length:y[re+1]),ft=Ne.length>0;break;case 3:he="lines",Ne=l.subarray(m[re],G?l.length:m[re+1]),rt=u.subarray(v[re],G?u.length:v[re+1]),ft=Ne.length>0&&rt.length>0;break;default:continue}ft&&(o.createMesh(mt.apply(Z,{id:Be,origin:W,primitive:he,positionsCompressed:Ne,normalsCompressed:Pe,colorsCompressed:ze,indices:rt,edgeIndices:At,positionsDecodeMatrix:Fe,color:K,metallic:xe,roughness:oe,opacity:ue})),Ee.push(Be))}}Ee.length>0&&o.createEntity(mt.apply(Q,{id:Re,isObject:!0,meshIds:Ee}))}}}}const Mee={version:9,parse:function(t,e,i,o,n,r){const a=W_t(i),s=Y_t(a);$_t(t,e,s,o,n,r)}};let Q1=window.pako||ks;Q1.inflate||(Q1=Q1.default);const yc=C.vec4(),Bee=C.vec4(),eFt=9;function tFt(t){let e=0;return{metadata:t[e++],textureData:t[e++],eachTextureDataPortion:t[e++],eachTextureAttributes:t[e++],positions:t[e++],normals:t[e++],colors:t[e++],uvs:t[e++],indices:t[e++],edgeIndices:t[e++],eachTextureSetTextures:t[e++],matrices:t[e++],reusedGeometriesDecodeMatrix:t[e++],eachGeometryPrimitiveType:t[e++],eachGeometryPositionsPortion:t[e++],eachGeometryNormalsPortion:t[e++],eachGeometryColorsPortion:t[e++],eachGeometryUVsPortion:t[e++],eachGeometryIndicesPortion:t[e++],eachGeometryEdgeIndicesPortion:t[e++],eachMeshGeometriesPortion:t[e++],eachMeshMatricesPortion:t[e++],eachMeshTextureSet:t[e++],eachMeshMaterialAttributes:t[e++],eachEntityId:t[e++],eachEntityMeshesPortion:t[e++],eachTileAABB:t[e++],eachTileEntitiesPortion:t[e++]}}function iFt(t){function e(i,o){return i.length===0?[]:Q1.inflate(i,o).buffer}return{metadata:JSON.parse(Q1.inflate(t.metadata,{to:"string"})),textureData:new Uint8Array(e(t.textureData)),eachTextureDataPortion:new Uint32Array(e(t.eachTextureDataPortion)),eachTextureAttributes:new Uint16Array(e(t.eachTextureAttributes)),positions:new Uint16Array(e(t.positions)),normals:new Int8Array(e(t.normals)),colors:new Uint8Array(e(t.colors)),uvs:new Float32Array(e(t.uvs)),indices:new Uint32Array(e(t.indices)),edgeIndices:new Uint32Array(e(t.edgeIndices)),eachTextureSetTextures:new Int32Array(e(t.eachTextureSetTextures)),matrices:new Float32Array(e(t.matrices)),reusedGeometriesDecodeMatrix:new Float32Array(e(t.reusedGeometriesDecodeMatrix)),eachGeometryPrimitiveType:new Uint8Array(e(t.eachGeometryPrimitiveType)),eachGeometryPositionsPortion:new Uint32Array(e(t.eachGeometryPositionsPortion)),eachGeometryNormalsPortion:new Uint32Array(e(t.eachGeometryNormalsPortion)),eachGeometryColorsPortion:new Uint32Array(e(t.eachGeometryColorsPortion)),eachGeometryUVsPortion:new Uint32Array(e(t.eachGeometryUVsPortion)),eachGeometryIndicesPortion:new Uint32Array(e(t.eachGeometryIndicesPortion)),eachGeometryEdgeIndicesPortion:new Uint32Array(e(t.eachGeometryEdgeIndicesPortion)),eachMeshGeometriesPortion:new Uint32Array(e(t.eachMeshGeometriesPortion)),eachMeshMatricesPortion:new Uint32Array(e(t.eachMeshMatricesPortion)),eachMeshTextureSet:new Int32Array(e(t.eachMeshTextureSet)),eachMeshMaterialAttributes:new Uint8Array(e(t.eachMeshMaterialAttributes)),eachEntityId:JSON.parse(Q1.inflate(t.eachEntityId,{to:"string"})),eachEntityMeshesPortion:new Uint32Array(e(t.eachEntityMeshesPortion)),eachTileAABB:new Float64Array(e(t.eachTileAABB)),eachTileEntitiesPortion:new Uint32Array(e(t.eachTileEntitiesPortion))}}const oFt=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();(function(){const t=document.createElement("canvas"),e=t.getContext("2d");return function(i){return t.width=i.width,t.height=i.height,e.putImageData(i,0,0),t.toDataURL()}})();function rFt(t,e,i,o,n,r){const a=r.getNextId(),s=i.metadata,l=i.textureData,c=i.eachTextureDataPortion,d=i.eachTextureAttributes,u=i.positions,h=i.normals,p=i.colors,A=i.uvs,f=i.indices,m=i.edgeIndices,g=i.eachTextureSetTextures,y=i.matrices,v=i.reusedGeometriesDecodeMatrix,w=i.eachGeometryPrimitiveType,x=i.eachGeometryPositionsPortion,k=i.eachGeometryNormalsPortion,B=i.eachGeometryColorsPortion,P=i.eachGeometryUVsPortion,E=i.eachGeometryIndicesPortion,T=i.eachGeometryEdgeIndicesPortion,S=i.eachMeshGeometriesPortion,R=i.eachMeshMatricesPortion,F=i.eachMeshTextureSet,U=i.eachMeshMaterialAttributes,q=i.eachEntityId,V=i.eachEntityMeshesPortion,W=i.eachTileAABB,Y=i.eachTileEntitiesPortion,$=c.length,fe=g.length/5,Me=x.length,Se=S.length,qe=V.length,Qe=Y.length;n&&n.loadData(s,{includeTypes:e.includeTypes,excludeTypes:e.excludeTypes,globalizeObjectIds:e.globalizeObjectIds});for(let me=0;me<$;me++){const we=me===$-1,Re=c[me],We=we?l.length:c[me+1],H=We-Re>0,ee=me*eFt,ae=d[ee+0]===1,Ee=d[ee+1];d[ee+2],d[ee+3];const pe=d[ee+4],Q=d[ee+5],Z=d[ee+6],ie=d[ee+7],re=d[ee+8];if(H){const ne=new Uint8Array(l.subarray(Re,We)).buffer,G=`${a}-texture-${me}`;if(ae)o.createTexture({id:G,buffers:[ne],minFilter:pe,magFilter:Q,wrapS:Z,wrapT:ie,wrapR:re});else{const K=Ee===h7?"image/jpeg":Ee===p7?"image/png":"image/gif",ue=new Blob([ne],{type:K}),xe=(window.URL||window.webkitURL).createObjectURL(ue),oe=document.createElement("img");oe.src=xe,o.createTexture({id:G,image:oe,minFilter:pe,magFilter:Q,wrapS:Z,wrapT:ie,wrapR:re})}}}for(let me=0;me<fe;me++){const we=me*5,Re=`${a}-textureSet-${me}`,We=g[we+0],H=g[we+1],ee=g[we+2],ae=g[we+3],Ee=g[we+4];o.createTextureSet({id:Re,colorTextureId:We>=0?`${a}-texture-${We}`:null,normalsTextureId:ee>=0?`${a}-texture-${ee}`:null,metallicRoughnessTextureId:H>=0?`${a}-texture-${H}`:null,emissiveTextureId:ae>=0?`${a}-texture-${ae}`:null,occlusionTextureId:Ee>=0?`${a}-texture-${Ee}`:null})}const Ce=new Uint32Array(Me);for(let me=0;me<Se;me++){const we=S[me];Ce[we]!==void 0?Ce[we]++:Ce[we]=1}const Le=C.vec3(),Fe=C.AABB3(),ve={};for(let me=0;me<Qe;me++){const we=Qe-1,Re=me===we,We=Y[me],H=Re?qe-1:Y[me+1]-1,ee=me*6,ae=W.subarray(ee,ee+6);C.getAABB3Center(ae,Le),Fe[0]=ae[0]-Le[0],Fe[1]=ae[1]-Le[1],Fe[2]=ae[2]-Le[2],Fe[3]=ae[3]-Le[0],Fe[4]=ae[4]-Le[1],Fe[5]=ae[5]-Le[2];const Ee=Jt.createPositionsDecodeMatrix(Fe),pe={};for(let Q=We;Q<=H;Q++){const Z=q[Q],ie=e.globalizeObjectIds?C.globalizeObjectId(o.id,Z):Z,re=qe-1,ne=Q===re,G=V[Q],K=ne?S.length-1:V[Q+1]-1,ue=[],xe=t.metaScene.metaObjects[ie],oe={},Be={};if(!(e.includeIdsMap&&Z&&!e.includeIdsMap[Z])){if(xe){if(e.excludeTypesMap&&xe.type&&e.excludeTypesMap[xe.type]||e.includeTypesMap&&xe.type&&!e.includeTypesMap[xe.type]||e.includeIdsMap&&xe.id&&!e.includeIdsMap[xe.id])continue;const je=e.objectDefaults?e.objectDefaults[xe.type]||e.objectDefaults.DEFAULT:null;je&&(je.visible===!1&&(oe.visible=!1),je.pickable===!1&&(oe.pickable=!1),je.colorize&&(Be.color=je.colorize),je.opacity!==void 0&&je.opacity!==null&&(Be.opacity=je.opacity),je.metallic!==void 0&&je.metallic!==null&&(Be.metallic=je.metallic),je.roughness!==void 0&&je.roughness!==null&&(Be.roughness=je.roughness))}else if(e.excludeUnclassifiedObjects)continue;for(let je=G;je<=K;je++){const he=S[je],Ne=Ce[he]>1,Pe=he===Me-1,ze=F[je],rt=ze>=0?`${a}-textureSet-${ze}`:null,At=oFt(U.subarray(je*6,je*6+3)),ft=U[je*6+3]/255,lt=U[je*6+4]/255,ut=U[je*6+5]/255,Te=r.getNextId();if(Ne){const st=R[je],dt=y.slice(st,st+16),Ye=`${a}-geometry.${me}.${he}`;let Ae=ve[Ye];if(!Ae){Ae={batchThisMesh:!e.reuseGeometries};const be=w[he];let $e=!1;switch(be){case 0:Ae.primitiveName="solid",Ae.geometryPositions=u.subarray(x[he],Pe?u.length:x[he+1]),Ae.geometryNormals=h.subarray(k[he],Pe?h.length:k[he+1]),Ae.geometryUVs=A.subarray(P[he],Pe?A.length:P[he+1]),Ae.geometryIndices=f.subarray(E[he],Pe?f.length:E[he+1]),Ae.geometryEdgeIndices=m.subarray(T[he],Pe?m.length:T[he+1]),$e=Ae.geometryPositions.length>0&&Ae.geometryIndices.length>0;break;case 1:Ae.primitiveName="surface",Ae.geometryPositions=u.subarray(x[he],Pe?u.length:x[he+1]),Ae.geometryNormals=h.subarray(k[he],Pe?h.length:k[he+1]),Ae.geometryUVs=A.subarray(P[he],Pe?A.length:P[he+1]),Ae.geometryIndices=f.subarray(E[he],Pe?f.length:E[he+1]),Ae.geometryEdgeIndices=m.subarray(T[he],Pe?m.length:T[he+1]),$e=Ae.geometryPositions.length>0&&Ae.geometryIndices.length>0;break;case 2:Ae.primitiveName="points",Ae.geometryPositions=u.subarray(x[he],Pe?u.length:x[he+1]),Ae.geometryColors=p.subarray(B[he],Pe?p.length:B[he+1]),$e=Ae.geometryPositions.length>0;break;case 3:Ae.primitiveName="lines",Ae.geometryPositions=u.subarray(x[he],Pe?u.length:x[he+1]),Ae.geometryIndices=f.subarray(E[he],Pe?f.length:E[he+1]),$e=Ae.geometryPositions.length>0&&Ae.geometryIndices.length>0;break;case 4:Ae.primitiveName="lines",Ae.geometryPositions=u.subarray(x[he],Pe?u.length:x[he+1]),Ae.geometryIndices=Eee(Ae.geometryPositions,f.subarray(E[he],Pe?f.length:E[he+1])),$e=Ae.geometryPositions.length>0&&Ae.geometryIndices.length>0;break;default:continue}if($e||(Ae=null),Ae&&(Ae.geometryPositions.length>1e3,Ae.batchThisMesh)){Ae.decompressedPositions=new Float32Array(Ae.geometryPositions.length),Ae.transformedAndRecompressedPositions=new Uint16Array(Ae.geometryPositions.length);const ht=Ae.geometryPositions,St=Ae.decompressedPositions;for(let xt=0,vi=ht.length;xt<vi;xt+=3)St[xt+0]=ht[xt+0]*v[0]+v[12],St[xt+1]=ht[xt+1]*v[5]+v[13],St[xt+2]=ht[xt+2]*v[10]+v[14];Ae.geometryPositions=null,ve[Ye]=Ae}}if(Ae)if(Ae.batchThisMesh){const be=Ae.decompressedPositions,$e=Ae.transformedAndRecompressedPositions;for(let ht=0,St=be.length;ht<St;ht+=3)yc[0]=be[ht+0],yc[1]=be[ht+1],yc[2]=be[ht+2],yc[3]=1,C.transformVec4(dt,yc,Bee),Jt.compressPosition(Bee,Fe,yc),$e[ht+0]=yc[0],$e[ht+1]=yc[1],$e[ht+2]=yc[2];o.createMesh(mt.apply(Be,{id:Te,textureSetId:rt,origin:Le,primitive:Ae.primitiveName,positionsCompressed:$e,normalsCompressed:Ae.geometryNormals,uv:Ae.geometryUVs,colorsCompressed:Ae.geometryColors,indices:Ae.geometryIndices,edgeIndices:Ae.geometryEdgeIndices,positionsDecodeMatrix:Ee,color:At,metallic:lt,roughness:ut,opacity:ft})),ue.push(Te)}else pe[Ye]||(o.createGeometry({id:Ye,primitive:Ae.primitiveName,positionsCompressed:Ae.geometryPositions,normalsCompressed:Ae.geometryNormals,uv:Ae.geometryUVs,colorsCompressed:Ae.geometryColors,indices:Ae.geometryIndices,edgeIndices:Ae.geometryEdgeIndices,positionsDecodeMatrix:v}),pe[Ye]=!0),o.createMesh(mt.apply(Be,{id:Te,geometryId:Ye,textureSetId:rt,matrix:dt,color:At,metallic:lt,roughness:ut,opacity:ft,origin:Le})),ue.push(Te)}else{const st=w[he];let dt,Ye,Ae,be,$e,ht,St,xt=!1;switch(st){case 0:dt="solid",Ye=u.subarray(x[he],Pe?u.length:x[he+1]),Ae=h.subarray(k[he],Pe?h.length:k[he+1]),be=A.subarray(P[he],Pe?A.length:P[he+1]),ht=f.subarray(E[he],Pe?f.length:E[he+1]),St=m.subarray(T[he],Pe?m.length:T[he+1]),xt=Ye.length>0&&ht.length>0;break;case 1:dt="surface",Ye=u.subarray(x[he],Pe?u.length:x[he+1]),Ae=h.subarray(k[he],Pe?h.length:k[he+1]),be=A.subarray(P[he],Pe?A.length:P[he+1]),ht=f.subarray(E[he],Pe?f.length:E[he+1]),St=m.subarray(T[he],Pe?m.length:T[he+1]),xt=Ye.length>0&&ht.length>0;break;case 2:dt="points",Ye=u.subarray(x[he],Pe?u.length:x[he+1]),$e=p.subarray(B[he],Pe?p.length:B[he+1]),xt=Ye.length>0;break;case 3:dt="lines",Ye=u.subarray(x[he],Pe?u.length:x[he+1]),ht=f.subarray(E[he],Pe?f.length:E[he+1]),xt=Ye.length>0&&ht.length>0;break;case 4:dt="lines",Ye=u.subarray(x[he],Pe?u.length:x[he+1]),ht=Eee(Ye,f.subarray(E[he],Pe?f.length:E[he+1])),xt=Ye.length>0&&ht.length>0;break;default:continue}xt&&(o.createMesh(mt.apply(Be,{id:Te,textureSetId:rt,origin:Le,primitive:dt,positionsCompressed:Ye,normalsCompressed:Ae,uv:be&&be.length>0?be:null,colorsCompressed:$e,indices:ht,edgeIndices:St,positionsDecodeMatrix:Ee,color:At,metallic:lt,roughness:ut,opacity:ft})),ue.push(Te))}}ue.length>0&&o.createEntity(mt.apply(oe,{id:ie,isObject:!0,meshIds:ue}))}}}}function Eee(t,e){const i=[];if(e.length>1)for(let o=0,n=e.length-1;o<n;o++)i.push(e[o]),i.push(e[o+1]);else if(t.length>1)for(let o=0,n=t.length/3-1;o<n;o++)i.push(o),i.push(o+1);return i}const Pee={version:10,parse:function(t,e,i,o,n,r){const a=tFt(i),s=iFt(a);rFt(t,e,s,o,n,r)}},bc=C.vec4(),Iee=C.vec4(),nFt=9;function aFt(t){const e=(function(){const n=new ArrayBuffer(2);return new Uint16Array(n)[0]=1,new Uint8Array(n)[0]!==1})(),i=(function(){let n=0;const r=new DataView(t);return function(a){const s=1+2*n++,l=r.getUint32(s*4,!0),c=r.getUint32((s+1)*4,!0),d=a.BYTES_PER_ELEMENT;if(e&&d>1){const u=new Uint8Array(t,l,c),h=d/2,p=u.length/d;for(let A=0;A<p;A++){const f=A*d;for(let m=0;m<h;m++){const g=f+m,y=f-m+d-1,v=u[g];u[g]=u[y],u[y]=v}}}return new a(t,l,c/d)}})(),o=(function(){const n=new TextDecoder;return()=>JSON.parse(n.decode(i(Uint8Array)))})();return{metadata:o(),textureData:i(Uint8Array),eachTextureDataPortion:i(Uint32Array),eachTextureAttributes:i(Uint16Array),positions:i(Uint16Array),normals:i(Int8Array),colors:i(Uint8Array),uvs:i(Float32Array),indices:i(Uint32Array),edgeIndices:i(Uint32Array),eachTextureSetTextures:i(Int32Array),matrices:i(Float32Array),reusedGeometriesDecodeMatrix:i(Float32Array),eachGeometryPrimitiveType:i(Uint8Array),eachGeometryPositionsPortion:i(Uint32Array),eachGeometryNormalsPortion:i(Uint32Array),eachGeometryColorsPortion:i(Uint32Array),eachGeometryUVsPortion:i(Uint32Array),eachGeometryIndicesPortion:i(Uint32Array),eachGeometryEdgeIndicesPortion:i(Uint32Array),eachMeshGeometriesPortion:i(Uint32Array),eachMeshMatricesPortion:i(Uint32Array),eachMeshTextureSet:i(Int32Array),eachMeshMaterialAttributes:i(Uint8Array),eachEntityId:o(),eachEntityMeshesPortion:i(Uint32Array),eachTileAABB:i(Float64Array),eachTileEntitiesPortion:i(Uint32Array)}}const sFt=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();(function(){const t=document.createElement("canvas"),e=t.getContext("2d");return function(i){return t.width=i.width,t.height=i.height,e.putImageData(i,0,0),t.toDataURL()}})();function lFt(t,e,i,o,n,r){const a=r.getNextId(),s=i.metadata,l=i.textureData,c=i.eachTextureDataPortion,d=i.eachTextureAttributes,u=i.positions,h=i.normals,p=i.colors,A=i.uvs,f=i.indices,m=i.edgeIndices,g=i.eachTextureSetTextures,y=i.matrices,v=i.reusedGeometriesDecodeMatrix,w=i.eachGeometryPrimitiveType,x=i.eachGeometryPositionsPortion,k=i.eachGeometryNormalsPortion,B=i.eachGeometryColorsPortion,P=i.eachGeometryUVsPortion,E=i.eachGeometryIndicesPortion,T=i.eachGeometryEdgeIndicesPortion,S=i.eachMeshGeometriesPortion,R=i.eachMeshMatricesPortion,F=i.eachMeshTextureSet,U=i.eachMeshMaterialAttributes,q=i.eachEntityId,V=i.eachEntityMeshesPortion,W=i.eachTileAABB,Y=i.eachTileEntitiesPortion,$=c.length,fe=g.length/5,Me=x.length,Se=S.length,qe=V.length,Qe=Y.length;n&&n.loadData(s,{includeTypes:e.includeTypes,excludeTypes:e.excludeTypes,globalizeObjectIds:e.globalizeObjectIds});for(let me=0;me<$;me++){const we=me===$-1,Re=c[me],We=we?l.length:c[me+1],H=We-Re>0,ee=me*nFt,ae=d[ee+0]===1,Ee=d[ee+1];d[ee+2],d[ee+3];const pe=d[ee+4],Q=d[ee+5],Z=d[ee+6],ie=d[ee+7],re=d[ee+8];if(H){const ne=new Uint8Array(l.subarray(Re,We)).buffer,G=`${a}-texture-${me}`;if(ae)o.createTexture({id:G,buffers:[ne],minFilter:pe,magFilter:Q,wrapS:Z,wrapT:ie,wrapR:re});else{const K=Ee===h7?"image/jpeg":Ee===p7?"image/png":"image/gif",ue=new Blob([ne],{type:K}),xe=(window.URL||window.webkitURL).createObjectURL(ue),oe=document.createElement("img");oe.src=xe,o.createTexture({id:G,image:oe,minFilter:pe,magFilter:Q,wrapS:Z,wrapT:ie,wrapR:re})}}}for(let me=0;me<fe;me++){const we=me*5,Re=`${a}-textureSet-${me}`,We=g[we+0],H=g[we+1],ee=g[we+2],ae=g[we+3],Ee=g[we+4];o.createTextureSet({id:Re,colorTextureId:We>=0?`${a}-texture-${We}`:null,normalsTextureId:ee>=0?`${a}-texture-${ee}`:null,metallicRoughnessTextureId:H>=0?`${a}-texture-${H}`:null,emissiveTextureId:ae>=0?`${a}-texture-${ae}`:null,occlusionTextureId:Ee>=0?`${a}-texture-${Ee}`:null})}const Ce=new Uint32Array(Me);for(let me=0;me<Se;me++){const we=S[me];Ce[we]!==void 0?Ce[we]++:Ce[we]=1}const Le=C.vec3(),Fe=C.AABB3(),ve={};for(let me=0;me<Qe;me++){const we=Qe-1,Re=me===we,We=Y[me],H=Re?qe-1:Y[me+1]-1,ee=me*6,ae=W.subarray(ee,ee+6);C.getAABB3Center(ae,Le),Fe[0]=ae[0]-Le[0],Fe[1]=ae[1]-Le[1],Fe[2]=ae[2]-Le[2],Fe[3]=ae[3]-Le[0],Fe[4]=ae[4]-Le[1],Fe[5]=ae[5]-Le[2];const Ee=Jt.createPositionsDecodeMatrix(Fe),pe={};for(let Q=We;Q<=H;Q++){const Z=q[Q],ie=e.globalizeObjectIds?C.globalizeObjectId(o.id,Z):Z,re=qe-1,ne=Q===re,G=V[Q],K=ne?S.length-1:V[Q+1]-1,ue=[],xe=t.metaScene.metaObjects[ie],oe={},Be={};if(!(e.includeIdsMap&&Z&&!e.includeIdsMap[Z])){if(xe){if(e.excludeTypesMap&&xe.type&&e.excludeTypesMap[xe.type]||e.includeTypesMap&&xe.type&&!e.includeTypesMap[xe.type]||e.includeIdsMap&&xe.id&&!e.includeIdsMap[xe.id])continue;const je=e.objectDefaults?e.objectDefaults[xe.type]||e.objectDefaults.DEFAULT:null;je&&(je.visible===!1&&(oe.visible=!1),je.pickable===!1&&(oe.pickable=!1),je.colorize&&(Be.color=je.colorize),je.opacity!==void 0&&je.opacity!==null&&(Be.opacity=je.opacity),je.metallic!==void 0&&je.metallic!==null&&(Be.metallic=je.metallic),je.roughness!==void 0&&je.roughness!==null&&(Be.roughness=je.roughness))}else if(e.excludeUnclassifiedObjects)continue;for(let je=G;je<=K;je++){const he=S[je],Ne=Ce[he]>1,Pe=he===Me-1,ze=F[je],rt=ze>=0?`${a}-textureSet-${ze}`:null,At=sFt(U.subarray(je*6,je*6+3)),ft=U[je*6+3]/255,lt=U[je*6+4]/255,ut=U[je*6+5]/255,Te=r.getNextId();if(Ne){const st=R[je],dt=y.slice(st,st+16),Ye=`${a}-geometry.${me}.${he}`;let Ae=ve[Ye];if(!Ae){Ae={batchThisMesh:!e.reuseGeometries};const be=w[he];let $e=!1;switch(be){case 0:Ae.primitiveName="solid",Ae.geometryPositions=u.subarray(x[he],Pe?u.length:x[he+1]),Ae.geometryNormals=h.subarray(k[he],Pe?h.length:k[he+1]),Ae.geometryUVs=A.subarray(P[he],Pe?A.length:P[he+1]),Ae.geometryIndices=f.subarray(E[he],Pe?f.length:E[he+1]),Ae.geometryEdgeIndices=m.subarray(T[he],Pe?m.length:T[he+1]),$e=Ae.geometryPositions.length>0&&Ae.geometryIndices.length>0;break;case 1:Ae.primitiveName="surface",Ae.geometryPositions=u.subarray(x[he],Pe?u.length:x[he+1]),Ae.geometryNormals=h.subarray(k[he],Pe?h.length:k[he+1]),Ae.geometryUVs=A.subarray(P[he],Pe?A.length:P[he+1]),Ae.geometryIndices=f.subarray(E[he],Pe?f.length:E[he+1]),Ae.geometryEdgeIndices=m.subarray(T[he],Pe?m.length:T[he+1]),$e=Ae.geometryPositions.length>0&&Ae.geometryIndices.length>0;break;case 2:Ae.primitiveName="points",Ae.geometryPositions=u.subarray(x[he],Pe?u.length:x[he+1]),Ae.geometryColors=p.subarray(B[he],Pe?p.length:B[he+1]),$e=Ae.geometryPositions.length>0;break;case 3:Ae.primitiveName="lines",Ae.geometryPositions=u.subarray(x[he],Pe?u.length:x[he+1]),Ae.geometryIndices=f.subarray(E[he],Pe?f.length:E[he+1]),$e=Ae.geometryPositions.length>0&&Ae.geometryIndices.length>0;break;case 4:Ae.primitiveName="lines",Ae.geometryPositions=u.subarray(x[he],Pe?u.length:x[he+1]),Ae.geometryIndices=See(Ae.geometryPositions,f.subarray(E[he],Pe?f.length:E[he+1])),$e=Ae.geometryPositions.length>0&&Ae.geometryIndices.length>0;break;default:continue}if($e||(Ae=null),Ae&&(Ae.geometryPositions.length>1e3,Ae.batchThisMesh)){Ae.decompressedPositions=new Float32Array(Ae.geometryPositions.length),Ae.transformedAndRecompressedPositions=new Uint16Array(Ae.geometryPositions.length);const ht=Ae.geometryPositions,St=Ae.decompressedPositions;for(let xt=0,vi=ht.length;xt<vi;xt+=3)St[xt+0]=ht[xt+0]*v[0]+v[12],St[xt+1]=ht[xt+1]*v[5]+v[13],St[xt+2]=ht[xt+2]*v[10]+v[14];Ae.geometryPositions=null,ve[Ye]=Ae}}if(Ae)if(Ae.batchThisMesh){const be=Ae.decompressedPositions,$e=Ae.transformedAndRecompressedPositions;for(let ht=0,St=be.length;ht<St;ht+=3)bc[0]=be[ht+0],bc[1]=be[ht+1],bc[2]=be[ht+2],bc[3]=1,C.transformVec4(dt,bc,Iee),Jt.compressPosition(Iee,Fe,bc),$e[ht+0]=bc[0],$e[ht+1]=bc[1],$e[ht+2]=bc[2];o.createMesh(mt.apply(Be,{id:Te,textureSetId:rt,origin:Le,primitive:Ae.primitiveName,positionsCompressed:$e,normalsCompressed:Ae.geometryNormals,uv:Ae.geometryUVs,colorsCompressed:Ae.geometryColors,indices:Ae.geometryIndices,edgeIndices:Ae.geometryEdgeIndices,positionsDecodeMatrix:Ee,color:At,metallic:lt,roughness:ut,opacity:ft})),ue.push(Te)}else pe[Ye]||(o.createGeometry({id:Ye,primitive:Ae.primitiveName,positionsCompressed:Ae.geometryPositions,normalsCompressed:Ae.geometryNormals,uv:Ae.geometryUVs,colorsCompressed:Ae.geometryColors,indices:Ae.geometryIndices,edgeIndices:Ae.geometryEdgeIndices,positionsDecodeMatrix:v}),pe[Ye]=!0),o.createMesh(mt.apply(Be,{id:Te,geometryId:Ye,textureSetId:rt,matrix:dt,color:At,metallic:lt,roughness:ut,opacity:ft,origin:Le})),ue.push(Te)}else{const st=w[he];let dt,Ye,Ae,be,$e,ht,St,xt=!1;switch(st){case 0:dt="solid",Ye=u.subarray(x[he],Pe?u.length:x[he+1]),Ae=h.subarray(k[he],Pe?h.length:k[he+1]),be=A.subarray(P[he],Pe?A.length:P[he+1]),ht=f.subarray(E[he],Pe?f.length:E[he+1]),St=m.subarray(T[he],Pe?m.length:T[he+1]),xt=Ye.length>0&&ht.length>0;break;case 1:dt="surface",Ye=u.subarray(x[he],Pe?u.length:x[he+1]),Ae=h.subarray(k[he],Pe?h.length:k[he+1]),be=A.subarray(P[he],Pe?A.length:P[he+1]),ht=f.subarray(E[he],Pe?f.length:E[he+1]),St=m.subarray(T[he],Pe?m.length:T[he+1]),xt=Ye.length>0&&ht.length>0;break;case 2:dt="points",Ye=u.subarray(x[he],Pe?u.length:x[he+1]),$e=p.subarray(B[he],Pe?p.length:B[he+1]),xt=Ye.length>0;break;case 3:dt="lines",Ye=u.subarray(x[he],Pe?u.length:x[he+1]),ht=f.subarray(E[he],Pe?f.length:E[he+1]),xt=Ye.length>0&&ht.length>0;break;case 4:dt="lines",Ye=u.subarray(x[he],Pe?u.length:x[he+1]),ht=See(Ye,f.subarray(E[he],Pe?f.length:E[he+1])),xt=Ye.length>0&&ht.length>0;break;default:continue}xt&&(o.createMesh(mt.apply(Be,{id:Te,textureSetId:rt,origin:Le,primitive:dt,positionsCompressed:Ye,normalsCompressed:Ae,uv:be&&be.length>0?be:null,colorsCompressed:$e,indices:ht,edgeIndices:St,positionsDecodeMatrix:Ee,color:At,metallic:lt,roughness:ut,opacity:ft})),ue.push(Te))}}ue.length>0&&o.createEntity(mt.apply(oe,{id:ie,isObject:!0,meshIds:ue}))}}}}function See(t,e){const i=[];if(e.length>1)for(let o=0,n=e.length-1;o<n;o++)i.push(e[o]),i.push(e[o+1]);else if(t.length>1)for(let o=0,n=t.length/3-1;o<n;o++)i.push(o),i.push(o+1);return i}const Tee={version:11,parseArrayBuffer:function(t,e,i,o,n,r){const a=aFt(i);lFt(t,e,a,o,n,r)}};let xh=window.pako||ks;xh.inflate||(xh=xh.default);const wc=C.vec4(),Dee=C.vec4(),cFt=9;function dFt(t){const e=(function(){const n=new ArrayBuffer(2);return new Uint16Array(n)[0]=1,new Uint8Array(n)[0]!==1})(),i=(function(){let n=0;const r=new DataView(t);return function(a){const s=1+2*n++,l=r.getUint32(s*4,!0),c=r.getUint32((s+1)*4,!0),d=a.BYTES_PER_ELEMENT;if(e&&d>1){const u=new Uint8Array(t,l,c),h=d/2,p=u.length/d;for(let A=0;A<p;A++){const f=A*d;for(let m=0;m<h;m++){const g=f+m,y=f-m+d-1,v=u[g];u[g]=u[y],u[y]=v}}}return new a(t,l,c/d)}})(),o=(function(){const n=new TextDecoder;return()=>JSON.parse(n.decode(i(Uint8Array)))})();return{metadata:o(),textureData:i(Uint8Array),eachTextureDataPortion:i(Uint32Array),eachTextureAttributes:i(Uint16Array),positions:i(Uint16Array),normals:i(Int8Array),colors:i(Uint8Array),uvs:i(Float32Array),indices:i(Uint32Array),edgeIndices:i(Uint32Array),eachTextureSetTextures:i(Int32Array),matrices:i(Float32Array),reusedGeometriesDecodeMatrix:i(Float32Array),eachGeometryPrimitiveType:i(Uint8Array),eachGeometryAxisLabel:o(),eachGeometryPositionsPortion:i(Uint32Array),eachGeometryNormalsPortion:i(Uint32Array),eachGeometryColorsPortion:i(Uint32Array),eachGeometryUVsPortion:i(Uint32Array),eachGeometryIndicesPortion:i(Uint32Array),eachGeometryEdgeIndicesPortion:i(Uint32Array),eachMeshGeometriesPortion:i(Uint32Array),eachMeshMatricesPortion:i(Uint32Array),eachMeshTextureSet:i(Int32Array),eachMeshMaterialAttributes:i(Uint8Array),eachEntityId:o(),eachEntityMeshesPortion:i(Uint32Array),eachTileAABB:i(Float64Array),eachTileEntitiesPortion:i(Uint32Array)}}function uFt(t){let e=0;return{metadata:t[e++],textureData:t[e++],eachTextureDataPortion:t[e++],eachTextureAttributes:t[e++],positions:t[e++],normals:t[e++],colors:t[e++],uvs:t[e++],indices:t[e++],edgeIndices:t[e++],eachTextureSetTextures:t[e++],matrices:t[e++],reusedGeometriesDecodeMatrix:t[e++],eachGeometryPrimitiveType:t[e++],eachGeometryAxisLabel:t[e++],eachGeometryPositionsPortion:t[e++],eachGeometryNormalsPortion:t[e++],eachGeometryColorsPortion:t[e++],eachGeometryUVsPortion:t[e++],eachGeometryIndicesPortion:t[e++],eachGeometryEdgeIndicesPortion:t[e++],eachMeshGeometriesPortion:t[e++],eachMeshMatricesPortion:t[e++],eachMeshTextureSet:t[e++],eachMeshMaterialAttributes:t[e++],eachEntityId:t[e++],eachEntityMeshesPortion:t[e++],eachTileAABB:t[e++],eachTileEntitiesPortion:t[e++]}}function hFt(t){function e(i,o){return i.length===0?[]:xh.inflate(i,o).buffer}return{metadata:JSON.parse(xh.inflate(t.metadata,{to:"string"})),textureData:new Uint8Array(e(t.textureData)),eachTextureDataPortion:new Uint32Array(e(t.eachTextureDataPortion)),eachTextureAttributes:new Uint16Array(e(t.eachTextureAttributes)),positions:new Uint16Array(e(t.positions)),normals:new Int8Array(e(t.normals)),colors:new Uint8Array(e(t.colors)),uvs:new Float32Array(e(t.uvs)),indices:new Uint32Array(e(t.indices)),edgeIndices:new Uint32Array(e(t.edgeIndices)),eachTextureSetTextures:new Int32Array(e(t.eachTextureSetTextures)),matrices:new Float32Array(e(t.matrices)),reusedGeometriesDecodeMatrix:new Float32Array(e(t.reusedGeometriesDecodeMatrix)),eachGeometryPrimitiveType:new Uint8Array(e(t.eachGeometryPrimitiveType)),eachGeometryAxisLabel:JSON.parse(xh.inflate(t.eachGeometryAxisLabel,{to:"string"})),eachGeometryPositionsPortion:new Uint32Array(e(t.eachGeometryPositionsPortion)),eachGeometryNormalsPortion:new Uint32Array(e(t.eachGeometryNormalsPortion)),eachGeometryColorsPortion:new Uint32Array(e(t.eachGeometryColorsPortion)),eachGeometryUVsPortion:new Uint32Array(e(t.eachGeometryUVsPortion)),eachGeometryIndicesPortion:new Uint32Array(e(t.eachGeometryIndicesPortion)),eachGeometryEdgeIndicesPortion:new Uint32Array(e(t.eachGeometryEdgeIndicesPortion)),eachMeshGeometriesPortion:new Uint32Array(e(t.eachMeshGeometriesPortion)),eachMeshMatricesPortion:new Uint32Array(e(t.eachMeshMatricesPortion)),eachMeshTextureSet:new Int32Array(e(t.eachMeshTextureSet)),eachMeshMaterialAttributes:new Uint8Array(e(t.eachMeshMaterialAttributes)),eachEntityId:JSON.parse(xh.inflate(t.eachEntityId,{to:"string"})),eachEntityMeshesPortion:new Uint32Array(e(t.eachEntityMeshesPortion)),eachTileAABB:new Float64Array(e(t.eachTileAABB)),eachTileEntitiesPortion:new Uint32Array(e(t.eachTileEntitiesPortion))}}const pFt=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();(function(){const t=document.createElement("canvas"),e=t.getContext("2d");return function(i){return t.width=i.width,t.height=i.height,e.putImageData(i,0,0),t.toDataURL()}})();function Ree(t,e,i,o,n,r){const a=r.getNextId(),s=i.metadata,l=i.textureData,c=i.eachTextureDataPortion,d=i.eachTextureAttributes,u=i.positions,h=i.normals,p=i.colors,A=i.uvs,f=i.indices,m=i.edgeIndices,g=i.eachTextureSetTextures,y=i.matrices,v=i.reusedGeometriesDecodeMatrix,w=i.eachGeometryPrimitiveType,x=i.eachGeometryAxisLabel,k=i.eachGeometryPositionsPortion,B=i.eachGeometryNormalsPortion,P=i.eachGeometryColorsPortion,E=i.eachGeometryUVsPortion,T=i.eachGeometryIndicesPortion,S=i.eachGeometryEdgeIndicesPortion,R=i.eachMeshGeometriesPortion,F=i.eachMeshMatricesPortion,U=i.eachMeshTextureSet,q=i.eachMeshMaterialAttributes,V=i.eachEntityId,W=i.eachEntityMeshesPortion,Y=i.eachTileAABB,$=i.eachTileEntitiesPortion,fe=c.length,Me=g.length/5,Se=k.length,qe=R.length,Qe=W.length,Ce=$.length;n&&n.loadData(s,{includeTypes:e.includeTypes,excludeTypes:e.excludeTypes,globalizeObjectIds:e.globalizeObjectIds});for(let we=0;we<fe;we++){const Re=we===fe-1,We=c[we],H=Re?l.length:c[we+1],ee=H-We>0,ae=we*cFt,Ee=d[ae+0]===1,pe=d[ae+1];d[ae+2],d[ae+3];const Q=d[ae+4],Z=d[ae+5],ie=d[ae+6],re=d[ae+7],ne=d[ae+8];if(ee){const G=new Uint8Array(l.subarray(We,H)).buffer,K=`${a}-texture-${we}`;if(Ee)o.createTexture({id:K,buffers:[G],minFilter:Q,magFilter:Z,wrapS:ie,wrapT:re,wrapR:ne});else{const ue=pe===h7?"image/jpeg":pe===p7?"image/png":"image/gif",xe=new Blob([G],{type:ue}),oe=(window.URL||window.webkitURL).createObjectURL(xe),Be=document.createElement("img");Be.src=oe,o.createTexture({id:K,image:Be,minFilter:Q,magFilter:Z,wrapS:ie,wrapT:re,wrapR:ne})}}}for(let we=0;we<Me;we++){const Re=we*5,We=`${a}-textureSet-${we}`,H=g[Re+0],ee=g[Re+1],ae=g[Re+2],Ee=g[Re+3],pe=g[Re+4];o.createTextureSet({id:We,colorTextureId:H>=0?`${a}-texture-${H}`:null,normalsTextureId:ae>=0?`${a}-texture-${ae}`:null,metallicRoughnessTextureId:ee>=0?`${a}-texture-${ee}`:null,emissiveTextureId:Ee>=0?`${a}-texture-${Ee}`:null,occlusionTextureId:pe>=0?`${a}-texture-${pe}`:null})}const Le=new Uint32Array(Se);for(let we=0;we<qe;we++){const Re=R[we];Le[Re]!==void 0?Le[Re]++:Le[Re]=1}const Fe=C.vec3(),ve=C.AABB3(),me={};for(let we=0;we<Ce;we++){const Re=Ce-1,We=we===Re,H=$[we],ee=We?Qe-1:$[we+1]-1,ae=we*6,Ee=Y.subarray(ae,ae+6);C.getAABB3Center(Ee,Fe),ve[0]=Ee[0]-Fe[0],ve[1]=Ee[1]-Fe[1],ve[2]=Ee[2]-Fe[2],ve[3]=Ee[3]-Fe[0],ve[4]=Ee[4]-Fe[1],ve[5]=Ee[5]-Fe[2];const pe=Jt.createPositionsDecodeMatrix(ve),Q={};for(let Z=H;Z<=ee;Z++){const ie=V[Z],re=e.globalizeObjectIds?C.globalizeObjectId(o.id,ie):ie,ne=Qe-1,G=Z===ne,K=W[Z],ue=G?R.length-1:W[Z+1]-1,xe=[],oe=t.metaScene.metaObjects[re],Be={},je={};if(!(e.includeIdsMap&&ie&&!e.includeIdsMap[ie])){if(oe){if(e.excludeTypesMap&&oe.type&&e.excludeTypesMap[oe.type]||e.includeTypesMap&&oe.type&&!e.includeTypesMap[oe.type]||e.includeIdsMap&&oe.id&&!e.includeIdsMap[oe.id])continue;const he=e.objectDefaults?e.objectDefaults[oe.type]||e.objectDefaults.DEFAULT:null;he&&(he.visible===!1&&(Be.visible=!1),he.pickable===!1&&(Be.pickable=!1),he.colorize&&(je.color=he.colorize),he.opacity!==void 0&&he.opacity!==null&&(je.opacity=he.opacity),he.metallic!==void 0&&he.metallic!==null&&(je.metallic=he.metallic),he.roughness!==void 0&&he.roughness!==null&&(je.roughness=he.roughness))}else if(e.excludeUnclassifiedObjects)continue;for(let he=K;he<=ue;he++){const Ne=R[he],Pe=Le[Ne]>1,ze=Ne===Se-1,rt=U[he],At=rt>=0?`${a}-textureSet-${rt}`:null,ft=pFt(q.subarray(he*6,he*6+3)),lt=q[he*6+3]/255,ut=q[he*6+4]/255,Te=q[he*6+5]/255,st=r.getNextId();if(Pe){const dt=F[he],Ye=y.slice(dt,dt+16),Ae=`${a}-geometry.${we}.${Ne}`;let be=me[Ae];if(!be){be={batchThisMesh:!e.reuseGeometries};const $e=w[Ne],ht=x[Ne];let St=!1,xt;switch($e){case 0:be.primitiveName="solid",be.geometryPositions=u.subarray(k[Ne],ze?u.length:k[Ne+1]),be.geometryNormals=h.subarray(B[Ne],ze?h.length:B[Ne+1]),be.geometryUVs=A.subarray(E[Ne],ze?A.length:E[Ne+1]),be.geometryIndices=f.subarray(T[Ne],ze?f.length:T[Ne+1]),be.geometryEdgeIndices=m.subarray(S[Ne],ze?m.length:S[Ne+1]),St=be.geometryPositions.length>0&&be.geometryIndices.length>0;break;case 1:be.primitiveName="surface",be.geometryPositions=u.subarray(k[Ne],ze?u.length:k[Ne+1]),be.geometryNormals=h.subarray(B[Ne],ze?h.length:B[Ne+1]),be.geometryUVs=A.subarray(E[Ne],ze?A.length:E[Ne+1]),be.geometryIndices=f.subarray(T[Ne],ze?f.length:T[Ne+1]),be.geometryEdgeIndices=m.subarray(S[Ne],ze?m.length:S[Ne+1]),St=be.geometryPositions.length>0&&be.geometryIndices.length>0;break;case 2:be.primitiveName="points",be.geometryPositions=u.subarray(k[Ne],ze?u.length:k[Ne+1]),be.geometryColors=p.subarray(P[Ne],ze?p.length:P[Ne+1]),St=be.geometryPositions.length>0;break;case 3:be.primitiveName="lines",be.geometryPositions=u.subarray(k[Ne],ze?u.length:k[Ne+1]),be.geometryIndices=f.subarray(T[Ne],ze?f.length:T[Ne+1]),St=be.geometryPositions.length>0&&be.geometryIndices.length>0;break;case 4:be.primitiveName="lines",be.geometryPositions=u.subarray(k[Ne],ze?u.length:k[Ne+1]),be.geometryIndices=Lee(be.geometryPositions,f.subarray(T[Ne],ze?f.length:T[Ne+1])),St=be.geometryPositions.length>0&&be.geometryIndices.length>0;break;case 7:be.primitiveName="lines",be.geometryPositions=u.subarray(k[Ne],ze?u.length:k[Ne+1]),be.decompressedPositions=Jt.decompressPositions(be.geometryPositions,v),xt=p1({origin:be.decompressedPositions,text:ht,size:2}),be.decompressedPositions=xt.positions,be.geometryIndices=xt.indices,be.geometryPositions=null,St=be.decompressedPositions.length>0&&be.geometryIndices.length>0;break;default:continue}if(St||(be=null),be&&(be.geometryPositions&&be.geometryPositions.length>1e3,be.batchThisMesh)){if($e===7)be.transformedAndRecompressedPositions=new Uint16Array(be.decompressedPositions.length);else{be.decompressedPositions=new Float32Array(be.geometryPositions.length),be.transformedAndRecompressedPositions=new Uint16Array(be.geometryPositions.length);const vi=be.geometryPositions,Gi=be.decompressedPositions;for(let So=0,ao=vi.length;So<ao;So+=3)Gi[So+0]=vi[So+0]*v[0]+v[12],Gi[So+1]=vi[So+1]*v[5]+v[13],Gi[So+2]=vi[So+2]*v[10]+v[14];be.geometryPositions=null}me[Ae]=be}}if(be)if(be.batchThisMesh){const $e=be.decompressedPositions,ht=be.transformedAndRecompressedPositions;for(let St=0,xt=$e.length;St<xt;St+=3)wc[0]=$e[St+0],wc[1]=$e[St+1],wc[2]=$e[St+2],wc[3]=1,C.transformVec4(Ye,wc,Dee),Jt.compressPosition(Dee,ve,wc),ht[St+0]=wc[0],ht[St+1]=wc[1],ht[St+2]=wc[2];o.createMesh(mt.apply(je,{id:st,textureSetId:At,origin:Fe,primitive:be.primitiveName,positionsCompressed:ht,normalsCompressed:be.geometryNormals,uv:be.geometryUVs,colorsCompressed:be.geometryColors,indices:be.geometryIndices,edgeIndices:be.geometryEdgeIndices,positionsDecodeMatrix:pe,color:ft,metallic:ut,roughness:Te,opacity:lt})),xe.push(st)}else{if(!Q[Ae]){let $e={id:Ae,primitive:be.primitiveName,normalsCompressed:be.geometryNormals,uv:be.geometryUVs,colorsCompressed:be.geometryColors,indices:be.geometryIndices,edgeIndices:be.geometryEdgeIndices};be.geometryPositions?$e={...$e,positionsCompressed:be.geometryPositions,positionsDecodeMatrix:v}:$e={...$e,positions:be.decompressedPositions},o.createGeometry($e),Q[Ae]=!0}o.createMesh(mt.apply(je,{id:st,geometryId:Ae,textureSetId:At,matrix:Ye,color:ft,metallic:ut,roughness:Te,opacity:lt,origin:Fe})),xe.push(st)}}else{const dt=w[Ne],Ye=x[Ne];let Ae,be,$e,ht,St,xt,vi,Gi=!1,So;switch(dt){case 0:Ae="solid",be=u.subarray(k[Ne],ze?u.length:k[Ne+1]),$e=h.subarray(B[Ne],ze?h.length:B[Ne+1]),ht=A.subarray(E[Ne],ze?A.length:E[Ne+1]),xt=f.subarray(T[Ne],ze?f.length:T[Ne+1]),vi=m.subarray(S[Ne],ze?m.length:S[Ne+1]),Gi=be.length>0&&xt.length>0;break;case 1:Ae="surface",be=u.subarray(k[Ne],ze?u.length:k[Ne+1]),$e=h.subarray(B[Ne],ze?h.length:B[Ne+1]),ht=A.subarray(E[Ne],ze?A.length:E[Ne+1]),xt=f.subarray(T[Ne],ze?f.length:T[Ne+1]),vi=m.subarray(S[Ne],ze?m.length:S[Ne+1]),Gi=be.length>0&&xt.length>0;break;case 2:Ae="points",be=u.subarray(k[Ne],ze?u.length:k[Ne+1]),St=p.subarray(P[Ne],ze?p.length:P[Ne+1]),Gi=be.length>0;break;case 3:Ae="lines",be=u.subarray(k[Ne],ze?u.length:k[Ne+1]),xt=f.subarray(T[Ne],ze?f.length:T[Ne+1]),Gi=be.length>0&&xt.length>0;break;case 4:Ae="lines",be=u.subarray(k[Ne],ze?u.length:k[Ne+1]),xt=Lee(be,f.subarray(T[Ne],ze?f.length:T[Ne+1])),Gi=be.length>0&&xt.length>0;break;case 7:Ae="lines",be=u.subarray(k[Ne],ze?u.length:k[Ne+1]),be=Jt.decompressPositions(be,pe),So=p1({origin:be,text:Ye,size:2}),be=So.positions,xt=So.indices,Gi=be.length>0&&xt.length>0;break;default:continue}if(Gi){let ao=mt.apply(je,{id:st,textureSetId:At,origin:Fe,primitive:Ae,normalsCompressed:$e,uv:ht&&ht.length>0?ht:null,colorsCompressed:St,indices:xt,edgeIndices:vi,color:ft,metallic:ut,roughness:Te,opacity:lt});dt!==7?ao={...ao,positionsCompressed:be,positionsDecodeMatrix:pe}:ao={...ao,positions:be},o.createMesh(ao),xe.push(st)}}}xe.length>0&&o.createEntity(mt.apply(Be,{id:re,isObject:!0,meshIds:xe}))}}}}function Lee(t,e){const i=[];if(e.length>1)for(let o=0,n=e.length-1;o<n;o++)i.push(e[o]),i.push(e[o+1]);else if(t.length>1)for(let o=0,n=t.length/3-1;o<n;o++)i.push(o),i.push(o+1);return i}const _ee={version:12,parseArrayBuffer:function(t,e,i,o,n,r){const a=dFt(i);Ree(t,e,a,o,n,r)},parse:function(t,e,i,o,n,r){const a=uFt(i),s=hFt(a);Ree(t,e,s,o,n,r)}},Rn={};Rn[pee.version]=pee,Rn[fee.version]=fee,Rn[Aee.version]=Aee,Rn[gee.version]=gee,Rn[mee.version]=mee,Rn[vee.version]=vee,Rn[bee.version]=bee,Rn[xee.version]=xee,Rn[Mee.version]=Mee,Rn[Pee.version]=Pee,Rn[Tee.version]=Tee,Rn[_ee.version]=_ee;class T9 extends Ha{constructor(e,i={}){super("XKTLoader",e,i),this._maxGeometryBatchSize=i.maxGeometryBatchSize,this.textureTranscoder=i.textureTranscoder,this.dataSource=i.dataSource,this.objectDefaults=i.objectDefaults,this.includeTypes=i.includeTypes,this.excludeTypes=i.excludeTypes,this.excludeUnclassifiedObjects=i.excludeUnclassifiedObjects,this.reuseGeometries=i.reuseGeometries}get supportedVersions(){return Object.keys(Rn)}get textureTranscoder(){return this._textureTranscoder}set textureTranscoder(e){this._textureTranscoder=e}get dataSource(){return this._dataSource}set dataSource(e){this._dataSource=e||new dee}get objectDefaults(){return this._objectDefaults}set objectDefaults(e){this._objectDefaults=e||see}get includeTypes(){return this._includeTypes}set includeTypes(e){this._includeTypes=e}get excludeTypes(){return this._excludeTypes}set excludeTypes(e){this._excludeTypes=e}get includeIds(){return this._includeIds}set includeIds(e){this._includeIds=e}get excludeUnclassifiedObjects(){return this._excludeUnclassifiedObjects}set excludeUnclassifiedObjects(e){this._excludeUnclassifiedObjects=!!e}get globalizeObjectIds(){return this._globalizeObjectIds}set globalizeObjectIds(e){this._globalizeObjectIds=!!e}get reuseGeometries(){return this._reuseGeometries}set reuseGeometries(e){this._reuseGeometries=e!==!1}load(e={}){if(e.id&&this.viewer.scene.components[e.id]&&(this.error("Component with this ID already exists in viewer: "+e.id+" - will autogenerate this ID"),delete e.id),!e.src&&!e.xkt&&!e.manifestSrc&&!e.manifest)throw new Error("XKTLoaderPlugin: load() param expected: src, xkt, manifestSrc or manifestData");const i={},o=e.includeTypes||this._includeTypes,n=e.excludeTypes||this._excludeTypes,r=e.includeIds||this._includeIds,a=e.objectDefaults||this._objectDefaults;if(i.reuseGeometries=e.reuseGeometries!==null&&e.reuseGeometries!==void 0?e.reuseGeometries:this._reuseGeometries!==!1,o){i.includeTypesMap={};for(let A=0,f=o.length;A<f;A++)i.includeTypesMap[o[A]]=!0}if(n){i.excludeTypesMap={};for(let A=0,f=n.length;A<f;A++)i.excludeTypesMap[n[A]]=!0}if(r){i.includeIdsMap={};for(let A=0,f=r.length;A<f;A++)i.includeIdsMap[r[A]]=!0}a&&(i.objectDefaults=a),i.excludeUnclassifiedObjects=e.excludeUnclassifiedObjects!==void 0?!!e.excludeUnclassifiedObjects:this._excludeUnclassifiedObjects,i.globalizeObjectIds=e.globalizeObjectIds!==void 0&&e.globalizeObjectIds!==null?!!e.globalizeObjectIds:this._globalizeObjectIds;const s=new g3(this.viewer.scene,mt.apply(e,{isModel:!0,textureTranscoder:this._textureTranscoder,maxGeometryBatchSize:this._maxGeometryBatchSize,origin:e.origin,disableVertexWelding:e.disableVertexWelding||!1,disableIndexRebucketing:e.disableIndexRebucketing||!1,dtxEnabled:e.dtxEnabled,renderOrder:e.renderOrder})),l=s.id,c=new dX({metaScene:this.viewer.metaScene,id:l});this.viewer.scene.canvas.spinner.processes++;const d=()=>{s.destroyed||(s.finalize(),c.finalize(),this.viewer.scene.canvas.spinner.processes--,s.once("destroyed",()=>{this.viewer.metaScene.destroyMetaModel(c.id)}),this.scheduleTask(()=>{s.destroyed||(s.scene.fire("modelLoaded",s.id),s.fire("loaded",!0,!1))}))},u=A=>{this.viewer.scene.canvas.spinner.processes--,this.error(A),s.fire("error",A)};let h=0;const p={getNextId:()=>`${l}.${h++}`};if(e.metaModelSrc||e.metaModelData)if(e.metaModelSrc){const A=e.metaModelSrc;this._dataSource.getMetaModel(A,f=>{s.destroyed||(c.loadData(f,{includeTypes:o,excludeTypes:n,globalizeObjectIds:i.globalizeObjectIds}),e.src?this._loadModel(e.src,i,s,null,p,d,u):(this._parseModel(e.xkt,i,s,null,p),d()))},f=>{u(`load(): Failed to load model metadata for model '${l} from '${A}' - ${f}`)})}else e.metaModelData&&(c.loadData(e.metaModelData,{includeTypes:o,excludeTypes:n,globalizeObjectIds:i.globalizeObjectIds}),e.src?this._loadModel(e.src,i,s,null,p,d,u):(this._parseModel(e.xkt,i,s,null,p),d()));else if(e.src)this._loadModel(e.src,i,s,c,p,d,u);else if(e.xkt)this._parseModel(e.xkt,i,s,c,p),d();else if(e.manifestSrc||e.manifest){const A=e.manifestSrc?fFt(e.manifestSrc):"",f=(y,v,w)=>{let x=0;const k=()=>{s.destroyed||x>=y.length?v():this._dataSource.getMetaModel(`${A}${y[x]}`,B=>{c.loadData(B,{includeTypes:o,excludeTypes:n,globalizeObjectIds:i.globalizeObjectIds}),x++,this.scheduleTask(k,200)},w)};k()},m=(y,v,w)=>{let x=0;const k=()=>{s.destroyed||x>=y.length?v():this._dataSource.getXKT(`${A}${y[x]}`,B=>{this._parseModel(B,i,s,null,p),s.preFinalize(),x++,this.scheduleTask(k,200)},w)};k()},g=(y,v,w)=>{let x=0;const k=()=>{s.destroyed||x>=y.length?v():this._dataSource.getXKT(`${A}${y[x]}`,B=>{this._parseModel(B,i,s,c,p),s.preFinalize(),x++,this.scheduleTask(k,200)},w)};k()};if(e.manifest){const y=e.manifest,v=y.xktFiles;if(!v||v.length===0){u("load(): Failed to load model manifest - manifest not valid");return}const w=y.metaModelFiles;w?f(w,()=>{m(v,d,u)},u):g(v,d,u)}else this._dataSource.getManifest(e.manifestSrc,y=>{if(s.destroyed)return;const v=y.xktFiles;if(!v||v.length===0){u("load(): Failed to load model manifest - manifest not valid");return}const w=y.metaModelFiles;w?f(w,()=>{m(v,d,u)},u):g(v,d,u)},u)}return s}_loadModel(e,i,o,n,r,a,s){this._dataSource.getXKT(e,l=>{this._parseModel(l,i,o,n,r),o.preFinalize(),a()},s)}async _parseModel(e,i,o,n,r){if(o.destroyed)return;const a=new DataView(e),s=new Uint8Array(e),l=a.getUint32(0,!0),c=l&2147483647,d=c<11||c>=12&&l>>>31,u=Rn[c];if(!u){this.error("Unsupported .XKT file version: "+c+" - this XKTLoaderPlugin supports versions "+Object.keys(Rn));return}if(!d){u.parseArrayBuffer(this.viewer,i,e,o,n,r);return}const h=a.getUint32(4,!0),p=[];let A=(h+2)*4;for(let f=0;f<h;f++){const m=a.getUint32((f+2)*4,!0);p.push(s.subarray(A,A+m)),A+=m}u.parse(this.viewer,i,p,o,n,r)}}function fFt(t){t.indexOf("?")>-1&&(t=t.split("?")[0]);const e=t.split("/");return e.pop(),e.join("/")+"/"}let AFt=1;class T_{constructor(e,i,o=null){this.tileset=e,this.computePriority=e.plugin.computePriority,this.distanceFactorToFreeData=e.plugin.distanceFactorToFreeData,this.src=i.content?.uri??null;const n=this.src?new URL(this.src).pathname:null;this.name=`${e.name}_${n?n.substring(n.lastIndexOf("/")+1):`tileWithNoContent_${AFt++}`}`,this.parent=o,this.refine=i.refine,this.data=null,this.fetching=null,this.depth=o?o.depth+1:1,this.model=null,this.loadProcess=null,this.loading=!1,this.currentDistanceFromCamera=null,this._visible=!o,this.priority=1,this.geometricError=i.geometricError;const[r,a,s,l,c,d,u,h,p,A,f,m]=i.boundingVolume.box,g=[r,s,-a];e.rootTransform&&(g[0]+=e.rootTransform[12],g[1]+=e.rootTransform[14],g[2]+=e.rootTransform[13]),this.center=Object.freeze(g);const y=[l,c,d],v=[-u,-h,-p],w=[A,f,m];this.xSize=C.lenVec3(y),this.ySize=C.lenVec3(w),this.zSize=C.lenVec3(v),this.volume=this.xSize*2*this.ySize*2*this.zSize*2,this.children=i.children?.map(x=>new T_(e,x,this))??[],e.tiles.add(this)}get visible(){return this._visible}set visible(e){this._visible!==e&&(this._visible=e,e?this.tileset.visibleTiles.add(this):this.tileset.visibleTiles.delete(this))}get loaded(){return!!this.model}get viewDistance(){return this.tileset.sensitivity*this.geometricError}get isWithinCameraVisibleRange(){return this.currentDistanceFromCamera<=this.viewDistance}updateVisibility(e){this.currentDistanceFromCamera=C.distVec3(this.center,e),this.parent&&(this.visible=this.isWithinCameraVisibleRange,this.currentDistanceFromCamera>this.viewDistance*this.distanceFactorToFreeData&&(this.data=null)),this.visible&&this.children.forEach(i=>i.updateVisibility(e)),this.priority=this.computePriority(this)}fetchData(){return this.data?this.data:this.src?(this.fetching||(this.fetching=new Promise((e,i)=>{fetch(this.src).then(o=>{o.ok?o.arrayBuffer().then(n=>{this.data=n,this.fetching=null,e(this.data)}):i(o)})})),this.fetching):null}showBoundingBox(){const{viewer:e}=this.tileset.plugin,{xSize:i,ySize:o,zSize:n,center:r}=this,a=1/this.depth;this.boxLines=new mi(e.scene,{geometry:new Ao(e.scene,qE({center:r,xSize:i,ySize:o,zSize:n})),material:new go(e.scene,{emissive:[1-a,a,(1-a)/2]})})}async load(){if(this.loading)return this.loadProcess;if(this.loaded)return this.model;if(this.loading=!0,!this.data)try{await this.fetchData()}catch(e){return console.warn(`[Xeokit - TilesetLoaderPlugin] Impossible to fetch data of tile "${this.name}".`,e),this.loading=!1,null}if(!this.visible)return this.loading=!1,null;this.tileset.plugin.debugMode&&this.showBoundingBox();try{const e=new Promise(i=>{const o=this.tileset.plugin.loader.load({id:this.name,xkt:this.data,metaModelData:{metaObjects:[{id:"metaModelRoot"}]}});o.once("loaded",()=>{this.loading=!1,this.loadProcess=null,this.model=o,this.tileset.destroyed||!this.visible?(this.unload(),i(null)):(this.tileset.loadedTiles.add(this),i(o))}),o.once("destroyed",()=>{this.loading=!1,this.loadProcess=null,i(null)})});return this.loadProcess=e,this.loadProcess}catch(e){return console.warn(`[Xeokit - TilesetLoaderPlugin] Impossible to load tile "${this.name}".`,e),null}}unload(){this.boxLines&&(this.boxLines.destroy(),this.boxLines=null),this.model&&(this.model.destroy(),this.model=null),this.tileset.loadedTiles.delete(this),this.children.forEach(e=>{e.loaded&&e.unload()})}}function gFt(t,e,i){const o=Array.from(t),n=o.splice(0,e),r=async a=>{if(await i(a),o.length>0){const s=o.shift();r(s)}};n.forEach(r)}function mFt(t){let e=!1;return{cancel(){e=!0},async run(i){for(let o of t){if(e)break;await new Promise(n=>setTimeout(()=>(i(o)||Promise.resolve()).then(n)))}}}}let vFt=0;class yFt{constructor(e,i){this.plugin=e,this.name=i.name||`tileset-${vFt++}`,this.tiles=new Set,this.visibleTiles=new Set,this.loadedTiles=new Set,this.queue=null,this.renderNeeded=!0,this.destroyed=!1,this._sensitivity=e.sensitivity,i.root.transform&&(this.rootTransform=i.root.transform),this.root=new T_(this,i.root),this.root.load().then(o=>e.viewer.cameraFlight.flyTo(o))}get sensitivity(){return this._sensitivity}set sensitivity(e){this._sensitivity=e,this.updateVisibility()}updateVisibility(){this.tiles.forEach(e=>{e!==this.root&&(e.visible=!1)}),this.root.updateVisibility(this.plugin.viewer.camera.eye),this.renderNeeded=!0}render(){if(!this.renderNeeded)return;this.queue&&this.queue.cancel(),this.loadedTiles.forEach(i=>{i.visible||i.unload()});const e=Array.from(this.visibleTiles).filter(i=>!i.loaded).sort((i,o)=>i.priority-o.priority);gFt(e,40,i=>i.fetchData()),this.queue=mFt(e),this.queue.run(i=>i.load()),this.renderNeeded=!1}destroy(){this.queue&&this.queue.cancel(),this.loadedTiles.forEach(e=>e.unload()),this.destroyed=!0,this.plugin.tilesets.delete(this)}}function bFt(t){return t.depth}class Fee extends Ha{constructor(e,i={}){super("TilesetLoader",e);const{computePriority:o=bFt,sensitivity:n=50,distanceFactorToFreeData:r=3,debugMode:a=!1}=i;this._sensitivity=n,this.distanceFactorToFreeData=r,this.computePriority=o,this.debugMode=a,this.tilesets=new Set,e.camera.on("matrix",this.updateTilesetsVisibilityCallback=()=>this.updateTilesetsVisibility()),e.scene.on("tick",this.renderTilesetsCallback=()=>this.renderTilesets()),this.loader=new T9(e)}load(e){const i=new yFt(this,e);return this.tilesets.add(i),i}updateTilesetsVisibility(){this.tilesets.forEach(e=>e.updateVisibility())}renderTilesets(){this.tilesets.forEach(e=>e.render())}get sensitivity(){return this._sensitivity}set sensitivity(e){this._sensitivity=e,this.tilesets.forEach(i=>i.sensitivity=this._sensitivity)}destroy(){this.viewer.camera.off(this.updateTilesetsVisibilityCallback),this.viewer.scene.off(this.renderTilesetsCallback),this.tilesets.forEach(e=>e.destroy()),super.destroy()}}const wFt="2.6.90";typeof window<"u"&&(window.__XEOKIT__?console.warn("WARNING: Multiple instances of xeokit-sdk being imported."):window.__XEOKIT__=wFt);const Cc=Object.freeze(Object.defineProperty({__proto__:null,AlphaFormat:mZ,AmbientLight:JP,AngleMeasurementEditMouseControl:ZEt,AngleMeasurementEditTouchControl:WEt,AngleMeasurementsControl:CI,AngleMeasurementsMouseControl:bX,AngleMeasurementsPlugin:e9,AngleMeasurementsTouchControl:JEt,AnnotationsPlugin:kI,AxisGizmoPlugin:tPt,BCFViewpointsPlugin:a9,Bitmap:XZ,ByteType:sZ,CameraMemento:jMt,CameraPath:hbt,CameraPathAnimation:Lr,ClampToEdgeWrapping:ln,Component:ai,CompressedMediaType:Fbt,Configs:w7,ContextMenu:I9t,CubicBezierCurve:zMt,Curve:qv,DefaultLoadingManager:rY,DepthFormat:wZ,DepthStencilFormat:CZ,DirLight:ws,DistanceMeasurementEditControl:BI,DistanceMeasurementEditMouseControl:cPt,DistanceMeasurementEditTouchControl:dPt,DistanceMeasurementsControl:MI,DistanceMeasurementsMouseControl:MX,DistanceMeasurementsPlugin:BX,DistanceMeasurementsTouchControl:lPt,EdgeMaterial:bP,EmphasisMaterial:cc,FastNavPlugin:SX,FloatType:hZ,Fresnel:Iwt,Frustum:ga,FrustumPlane:ah,GIFMediaType:_bt,GLTFDefaultDataSource:TX,GLTFLoaderPlugin:pS,HalfFloatType:pZ,ImagePlane:wwt,IntType:dZ,JPEGMediaType:h7,KTX2TextureTranscoder:Rs,LOD:kY,LambertMaterial:Cwt,LightMap:UMt,LineSet:vY,LinearEncoding:Jn,LinearFilter:cn,LinearMipMapLinearFilter:A1,LinearMipMapNearestFilter:Jv,LinearMipmapLinearFilter:uh,LinearMipmapNearestFilter:Lbt,Loader:nY,LoadingManager:oY,LocaleService:VJ,LuminanceAlphaFormat:bZ,LuminanceFormat:yZ,Map:Va,Marker:v3,MarqueePicker:Pl,MarqueePickerMouseControl:ubt,Mesh:mi,MeshSurfaceArea:oW,MeshVolume:eW,MetallicMaterial:Mwt,MirroredRepeatWrapping:nc,ModelMemento:VMt,NavCubePlugin:fS,NearestFilter:dh,NearestMipMapLinearFilter:f1,NearestMipMapNearestFilter:Kv,NearestMipmapLinearFilter:aZ,NearestMipmapNearestFilter:nZ,Node:Gv,ObjectsKdTree3:R9t,ObjectsMemento:HMt,PNGMediaType:p7,Path:qMt,PerformanceModel:GMt,PhongMaterial:go,PickResult:U7,Plugin:Ha,PointLight:_Mt,PointerCircle:OE,PointerLens:S9t,QuadraticBezierCurve:QMt,Queue:TJ,RGBAFormat:Zv,RGBAIntegerFormat:EZ,RGBA_ASTC_10x10_Format:sP,RGBA_ASTC_10x5_Format:rP,RGBA_ASTC_10x6_Format:nP,RGBA_ASTC_10x8_Format:aP,RGBA_ASTC_12x10_Format:lP,RGBA_ASTC_12x12_Format:cP,RGBA_ASTC_4x4_Format:d7,RGBA_ASTC_5x4_Format:YE,RGBA_ASTC_5x5_Format:XE,RGBA_ASTC_6x5_Format:$E,RGBA_ASTC_6x6_Format:eP,RGBA_ASTC_8x5_Format:tP,RGBA_ASTC_8x6_Format:iP,RGBA_ASTC_8x8_Format:oP,RGBA_BPTC_Format:u7,RGBA_ETC2_EAC_Format:c7,RGBA_PVRTC_2BPPV1_Format:ZE,RGBA_PVRTC_4BPPV1_Format:s7,RGBA_S3TC_DXT1_Format:r7,RGBA_S3TC_DXT3_Format:n7,RGBA_S3TC_DXT5_Format:Yv,RGBFormat:vZ,RGB_ETC1_Format:WE,RGB_ETC2_Format:l7,RGB_PVRTC_2BPPV1_Format:JE,RGB_PVRTC_4BPPV1_Format:a7,RGB_S3TC_DXT1_Format:Wv,RGFormat:MZ,RGIntegerFormat:BZ,ReadableGeometry:Ao,RedFormat:xZ,RedIntegerFormat:kZ,ReflectionMap:OMt,RepeatWrapping:wo,SceneModel:g3,SceneModelMesh:nW,SceneModelTransform:uY,SectionPlane:XP,SectionPlanesPlugin:f_t,ShortType:lZ,SpecularMaterial:Pwt,SplineCurve:Xy,SpriteMarker:NMt,Texture:g1,TextureTranscoder:ZMt,TilesetLoaderPlugin:Fee,UnsignedByteType:KE,UnsignedInt248Type:gZ,UnsignedIntType:uZ,UnsignedShort4444Type:fZ,UnsignedShort5551Type:AZ,UnsignedShortType:cZ,VBOGeometry:JJ,VFC:OY,Viewer:yX,WorkerPool:sY,XKTDefaultDataSource:dee,XKTLoaderPlugin:T9,buildBoxGeometry:zE,buildBoxLinesGeometry:qE,buildBoxLinesGeometryFromAABB:Ibt,buildCylinderGeometry:u1,buildGridGeometry:ZJ,buildLineGeometry:YJ,buildPlaneGeometry:QE,buildPolylineGeometry:WJ,buildPolylineGeometryFromCurve:Tbt,buildSphereGeometry:h1,buildTorusGeometry:GE,buildVectorTextGeometry:p1,createCombinedTexture:qEt,createRTCViewMat:Ni,createSkyboxMesh:QEt,createSphereMapMesh:GEt,frustumIntersectsAABB3:Yy,getKTX2TextureTranscoder:lY,getPlaneRTCPos:Wo,isTriangleMeshSolid:$Z,load3DSGeometry:Ebt,loadOBJGeometry:Pbt,math:C,meshSurfaceArea:t3,meshVolume:v1,os:oI,rtcToWorldPos:Rbt,sRGBEncoding:ho,setFrustum:jJ,stats:Ii,utils:mt,worldToRTCPos:ch,worldToRTCPositions:o7},Symbol.toStringTag,{value:"Module"}));function G1(t){let e=t.substring(1);const i=[];let o=null;for(;e.length>0;)o=e.substring(0,2),e=e.substring(2),i.push(parseInt(o,16)/255);return i}function Oee(t){let e="";return e+=Math.round(t[0]*255).toString(16).padStart(2,"0"),e+=Math.round(t[1]*255).toString(16).padStart(2,"0"),e+=Math.round(t[2]*255).toString(16).padStart(2,"0"),`#${e}`}const CFt={class:"annotations-3d"},xFt={__name:"Annotations3D",setup(t){const e=ct("$viewer"),{localContext:i}=e,{xeokit:o}=i.viewer,n=o.scene.canvas.canvas,r=RE(),a=Cr(new WeakSet),s=De(()=>r.value.filter(u=>a.has(u))),l=new Map;pt(r,()=>{r.value.forEach(u=>{if(!l.has(u.id)){const{x:h,y:p,z:A}=u,f=new v3(o.scene,{worldPos:[h,A,p]});l.set(u.id,f);const[m,g]=f.canvasPos;f.style=le(`left: ${m}px; top: ${g}px;`),f.on("canvasPos",([w,x])=>{f.style.value=`left: ${w}px; top: ${x}px;`}),f.on("visible",w=>w?a.add(u):a.delete(u)),f.on("destroyed",()=>{e.state.hub.off(v),e.state.hub.off(y)});const y=e.state.hub.on("annotation-updated",({annotation:w})=>{if(w.id===u.id){const{x,y:k,z:B}=w;f.worldPos=[x,B,k],f._update(),o.scene._renderer._occlusionTester._occlusionTestListDirty=!0}}),v=e.state.hub.on("annotation-removed",({annotation:w})=>{w.id===u.id&&(l.delete(u.id),f.destroy())})}})},{flush:"sync"});const c=(u,h)=>{const{clientX:p,clientY:A}=h,{x:f,y:m}=n.getBoundingClientRect(),g=o.scene.pick({pickSurface:!0,canvasPos:[p-f,A-m]});if(g){const[y,v,w]=g.worldPos;Object.assign(u,{x:y,y:w,z:v})}},d=u=>l.get(u.id).style.value;return(u,h)=>(M(),_("div",CFt,[(M(!0),_(Xe,null,Bt(s.value,p=>(M(),J(LE,{key:p.instanceId,annotation:p,canvas:ot(n),style:de(d(p)),onAnnotationDrag:A=>c(p,A)},null,8,["annotation","canvas","style","onAnnotationDrag"]))),128))]))}},Uee=j(xFt,[["__scopeId","data-v-10ceb001"]]),kFt={setup(){const t=ct("$viewer"),e=t.localContext.pluginComponentInstances.get("viewer3d"),{math:i}=e.xeokitSdk,o=()=>{const r=e.xeokit,a=[0,0,-1],s=r.scene.aabb,l=i.getAABB3Diag(s),c=i.vec3();i.getAABB3Center(s,c);const d=45,u=Math.abs(l/Math.tan(d*i.DEGTORAD));r.cameraControl.pivotPos=c,r.cameraFlight.jumpTo({look:c,eye:[c[0]-u*a[0],c[1]-u*a[1],c[2]-u*a[2]],up:[0,1,0],orthoScale:l*1.1,fitFOV:d})},n=()=>{const r=t.localContext.loadedModels.flatMap(a=>a.objects.filter(s=>s.visible===!1).map(s=>s.id));t.state.showObjects(r)};return{onClick:()=>{o(),n(),e.reintegrateObjects()}}}};function MFt(t,e,i,o,n,r){const a=I("BIMDataIconHome"),s=I("BIMDataButton");return M(),J(s,{color:"default",ghost:"",rounded:"",icon:"",onClick:o.onClick},{default:N(()=>[D(a,{size:"xs"})]),_:1},8,["onClick"])}const BFt=j(kFt,[["render",MFt]]),EFt={computed:{active(){return this.$viewer.localContext.pluginComponentInstances.has("navigationVersionsModel")?this.$viewer.localContext.pluginComponentInstances.get("navigationVersionsModel").isOpen.value:!1}},methods:{onClick(){this.$viewer.localContext.pluginComponentInstances.get("navigationVersionsModel").toggle()}}};function PFt(t,e,i,o,n,r){const a=I("BIMDataIcon"),s=I("BIMDataButton"),l=I("BIMDataTooltip");return M(),J(l,{text:t.$t("navigationVersionsModel.tooltip")},{default:N(()=>[D(s,{class:ce(["bimdata-navigation-versions-model",{active:r.active}]),color:"primary",ghost:"",rounded:"",icon:"",onClick:r.onClick},{default:N(()=>[D(a,{name:"versioning",fill:"",color:"primary",size:"xxs"})]),_:1},8,["class","onClick"])]),_:1},8,["text"])}const IFt=j(EFt,[["render",PFt],["__scopeId","data-v-ced27a96"]]),SFt={key:0,width:"159",height:"116",viewBox:"0 0 159 116",fill:"none",xmlns:"http://www.w3.org/2000/svg"},TFt={key:1,width:"159",height:"116",viewBox:"0 0 159 116",fill:"none",xmlns:"http://www.w3.org/2000/svg"},DFt={__name:"KeyboardNavigate",setup(t){const e=ct("$viewer").i18n.locale==="fr";return(i,o)=>e?(M(),_("svg",SFt,[...o[0]||(o[0]=[$r('<path d="M79 0L87 11H71L79 0Z" fill="#2F374A"></path><path d="M159 79.1111L148 87.1111L148 71.1111L159 79.1111Z" fill="#2F374A"></path><path d="M9.5399e-08 79.1111L11 71.1111L11 87.1111L9.5399e-08 79.1111Z" fill="#2F374A"></path><path d="M79 115.222L71 104.222L87 104.222L79 115.222Z" fill="#2F374A"></path><rect x="61.3333" y="18" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M82.5998 38.834V40H76.6759V38.834H82.5998ZM82.465 32.377L77.2209 40H76.2365V39.0684L81.4982 31.4688H82.465V32.377ZM81.9201 31.4688V32.6406H76.2716V31.4688H81.9201Z" fill="#6B6B6B"></path><rect x="104.667" y="61" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M122.148 83.1111H120.326L120.338 81.9451H122.148C122.676 81.9451 123.117 81.8298 123.473 81.5994C123.832 81.3689 124.101 81.0388 124.281 80.6091C124.465 80.1794 124.557 79.6677 124.557 79.074V78.6111C124.557 78.1501 124.504 77.7419 124.398 77.3865C124.297 77.031 124.144 76.7322 123.941 76.49C123.742 76.2478 123.496 76.0642 123.203 75.9392C122.914 75.8142 122.58 75.7517 122.201 75.7517H120.291V74.5798H122.201C122.767 74.5798 123.285 74.6755 123.754 74.8669C124.223 75.0544 124.627 75.3259 124.967 75.6814C125.31 76.0369 125.574 76.4626 125.758 76.9587C125.941 77.4548 126.033 78.0095 126.033 78.6228V79.074C126.033 79.6873 125.941 80.2419 125.758 80.738C125.574 81.2341 125.31 81.6599 124.967 82.0154C124.623 82.3669 124.213 82.6384 123.736 82.8298C123.264 83.0173 122.734 83.1111 122.148 83.1111ZM121.141 74.5798V83.1111H119.67V74.5798H121.141Z" fill="#6B6B6B"></path><rect x="18" y="61" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M37.3036 81.9744L39.5478 83.7556L38.5927 84.5935L36.3896 82.8298L37.3036 81.9744ZM39.5653 78.6111V79.0798C39.5653 79.7244 39.4814 80.3025 39.3134 80.8142C39.1454 81.3259 38.9052 81.7615 38.5927 82.1208C38.2802 82.4802 37.9071 82.7556 37.4735 82.947C37.04 83.1345 36.5595 83.2283 36.0321 83.2283C35.5087 83.2283 35.0302 83.1345 34.5966 82.947C34.1669 82.7556 33.7939 82.4802 33.4775 82.1208C33.161 81.7615 32.915 81.3259 32.7392 80.8142C32.5673 80.3025 32.4814 79.7244 32.4814 79.0798V78.6111C32.4814 77.9666 32.5673 77.3904 32.7392 76.8826C32.911 76.3708 33.1532 75.9353 33.4657 75.5759C33.7821 75.2126 34.1552 74.9373 34.5849 74.7498C35.0185 74.5583 35.497 74.4626 36.0204 74.4626C36.5478 74.4626 37.0282 74.5583 37.4618 74.7498C37.8993 74.9373 38.2743 75.2126 38.5868 75.5759C38.8993 75.9353 39.1396 76.3708 39.3075 76.8826C39.4794 77.3904 39.5653 77.9666 39.5653 78.6111ZM38.0888 79.0798V78.5994C38.0888 78.1228 38.0419 77.7029 37.9482 77.3396C37.8583 76.9724 37.7235 76.6658 37.5439 76.4197C37.3681 76.1697 37.1513 75.9822 36.8935 75.8572C36.6396 75.7283 36.3485 75.6638 36.0204 75.6638C35.7001 75.6638 35.413 75.7283 35.1591 75.8572C34.9052 75.9822 34.6884 76.1697 34.5087 76.4197C34.329 76.6658 34.1923 76.9724 34.0985 77.3396C34.0048 77.7029 33.9579 78.1228 33.9579 78.5994V79.0798C33.9579 79.5564 34.0048 79.9783 34.0985 80.3455C34.1923 80.7126 34.329 81.0232 34.5087 81.2771C34.6923 81.5271 34.911 81.7166 35.165 81.8455C35.4228 81.9705 35.7118 82.033 36.0321 82.033C36.3603 82.033 36.6513 81.9705 36.9052 81.8455C37.1591 81.7166 37.3739 81.5271 37.5497 81.2771C37.7255 81.0232 37.8583 80.7126 37.9482 80.3455C38.0419 79.9783 38.0888 79.5564 38.0888 79.0798Z" fill="#6B6B6B"></path><rect x="61.3333" y="61.1112" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M81.1115 81.025C81.1115 80.8492 81.0841 80.693 81.0295 80.5563C80.9787 80.4196 80.8869 80.2946 80.7541 80.1813C80.6213 80.068 80.4338 79.9586 80.1916 79.8531C79.9533 79.7438 79.6486 79.6324 79.2775 79.5192C78.8713 79.3942 78.4963 79.2555 78.1525 79.1031C77.8127 78.9469 77.5158 78.7672 77.2619 78.5641C77.008 78.3571 76.8107 78.1207 76.6701 77.8551C76.5295 77.5856 76.4591 77.275 76.4591 76.9235C76.4591 76.5758 76.5314 76.2594 76.6759 75.9742C76.8244 75.6891 77.0334 75.443 77.3029 75.236C77.5763 75.025 77.8986 74.8629 78.2697 74.7496C78.6408 74.6324 79.0509 74.5739 79.5002 74.5739C80.133 74.5739 80.6779 74.691 81.1349 74.9254C81.5959 75.1598 81.9494 75.4742 82.1955 75.8688C82.4455 76.2633 82.5705 76.6989 82.5705 77.1754H81.1115C81.1115 76.8942 81.0509 76.6461 80.9298 76.4313C80.8127 76.2125 80.633 76.0406 80.3908 75.9156C80.1525 75.7906 79.8498 75.7281 79.4826 75.7281C79.1349 75.7281 78.8459 75.7809 78.6154 75.8864C78.3849 75.9918 78.213 76.1344 78.0998 76.3141C77.9865 76.4938 77.9298 76.6969 77.9298 76.9235C77.9298 77.0836 77.967 77.2301 78.0412 77.3629C78.1154 77.4918 78.2287 77.6129 78.381 77.7262C78.5334 77.8356 78.7248 77.9391 78.9552 78.0367C79.1857 78.1344 79.4572 78.2281 79.7697 78.318C80.2423 78.4586 80.6545 78.6149 81.006 78.7867C81.3576 78.9547 81.6505 79.1461 81.8849 79.361C82.1193 79.5758 82.2951 79.8199 82.4123 80.0934C82.5295 80.3629 82.588 80.6696 82.588 81.0133C82.588 81.3727 82.5158 81.6969 82.3713 81.986C82.2267 82.2711 82.0197 82.5153 81.7502 82.7184C81.4845 82.9176 81.1642 83.0719 80.7892 83.1813C80.4181 83.2867 80.0041 83.3395 79.547 83.3395C79.1369 83.3395 78.7326 83.2848 78.3341 83.1754C77.9396 83.066 77.5802 82.9 77.256 82.6774C76.9318 82.4508 76.674 82.1696 76.4826 81.8336C76.2912 81.4938 76.1955 81.0973 76.1955 80.6442H77.6662C77.6662 80.9215 77.713 81.1578 77.8068 81.3531C77.9045 81.5485 78.0392 81.7086 78.2111 81.8336C78.383 81.9547 78.5822 82.0446 78.8088 82.1031C79.0392 82.1617 79.2853 82.191 79.547 82.191C79.8908 82.191 80.1779 82.1422 80.4084 82.0446C80.6427 81.9469 80.8185 81.8102 80.9357 81.6344C81.0529 81.4586 81.1115 81.2555 81.1115 81.025Z" fill="#6B6B6B"></path>',12)])])):(M(),_("svg",TFt,[...o[1]||(o[1]=[$r('<path d="M79 0L87 11H71L79 0Z" fill="#2F374A"></path><path d="M159 79.1111L148 87.1111L148 71.1111L159 79.1111Z" fill="#2F374A"></path><path d="M9.5399e-08 79.1111L11 71.1111L11 87.1111L9.5399e-08 79.1111Z" fill="#2F374A"></path><path d="M79 115.222L71 104.222L87 104.222L79 115.222Z" fill="#2F374A"></path><rect x="61.3333" y="18" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M77.1095 38.084L78.8088 31.4688H79.6994L79.5998 33.1738L77.7834 40H76.8576L77.1095 38.084ZM75.838 31.4688L77.215 38.0312L77.338 40H76.3537L74.3791 31.4688H75.838ZM81.6271 38.0137L82.9865 31.4688H84.4513L82.4767 40H81.4923L81.6271 38.0137ZM80.0451 31.4688L81.7267 38.1016L81.9728 40H81.047L79.2599 33.1738L79.1662 31.4688H80.0451Z" fill="#6B6B6B"></path><rect x="104.667" y="61" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M122.148 83.1111H120.326L120.338 81.9451H122.148C122.676 81.9451 123.117 81.8298 123.473 81.5994C123.832 81.3689 124.101 81.0388 124.281 80.6091C124.465 80.1794 124.557 79.6677 124.557 79.074V78.6111C124.557 78.1501 124.504 77.7419 124.398 77.3865C124.297 77.031 124.144 76.7322 123.941 76.49C123.742 76.2478 123.496 76.0642 123.203 75.9392C122.914 75.8142 122.58 75.7517 122.201 75.7517H120.291V74.5798H122.201C122.767 74.5798 123.285 74.6755 123.754 74.8669C124.223 75.0544 124.627 75.3259 124.967 75.6814C125.31 76.0369 125.574 76.4626 125.758 76.9587C125.941 77.4548 126.033 78.0095 126.033 78.6228V79.074C126.033 79.6873 125.941 80.2419 125.758 80.738C125.574 81.2341 125.31 81.6599 124.967 82.0154C124.623 82.3669 124.213 82.6384 123.736 82.8298C123.264 83.0173 122.734 83.1111 122.148 83.1111ZM121.141 74.5798V83.1111H119.67V74.5798H121.141Z" fill="#6B6B6B"></path><rect x="18" y="61" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M36.2665 75.7166L33.7177 83.1111H32.1767L35.3876 74.5798H36.372L36.2665 75.7166ZM38.3993 83.1111L35.8446 75.7166L35.7333 74.5798H36.7235L39.9462 83.1111H38.3993ZM38.2763 79.947V81.113H33.6357V79.947H38.2763Z" fill="#6B6B6B"></path><rect x="61.3333" y="61.1112" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M81.1115 81.025C81.1115 80.8492 81.0841 80.693 81.0295 80.5563C80.9787 80.4196 80.8869 80.2946 80.7541 80.1813C80.6213 80.068 80.4338 79.9586 80.1916 79.8531C79.9533 79.7438 79.6486 79.6324 79.2775 79.5192C78.8713 79.3942 78.4963 79.2555 78.1525 79.1031C77.8127 78.9469 77.5158 78.7672 77.2619 78.5641C77.008 78.3571 76.8107 78.1207 76.6701 77.8551C76.5295 77.5856 76.4591 77.275 76.4591 76.9235C76.4591 76.5758 76.5314 76.2594 76.6759 75.9742C76.8244 75.6891 77.0334 75.443 77.3029 75.236C77.5763 75.025 77.8986 74.8629 78.2697 74.7496C78.6408 74.6324 79.0509 74.5739 79.5002 74.5739C80.133 74.5739 80.6779 74.691 81.1349 74.9254C81.5959 75.1598 81.9494 75.4742 82.1955 75.8688C82.4455 76.2633 82.5705 76.6989 82.5705 77.1754H81.1115C81.1115 76.8942 81.0509 76.6461 80.9298 76.4313C80.8127 76.2125 80.633 76.0406 80.3908 75.9156C80.1525 75.7906 79.8498 75.7281 79.4826 75.7281C79.1349 75.7281 78.8459 75.7809 78.6154 75.8864C78.3849 75.9918 78.213 76.1344 78.0998 76.3141C77.9865 76.4938 77.9298 76.6969 77.9298 76.9235C77.9298 77.0836 77.967 77.2301 78.0412 77.3629C78.1154 77.4918 78.2287 77.6129 78.381 77.7262C78.5334 77.8356 78.7248 77.9391 78.9552 78.0367C79.1857 78.1344 79.4572 78.2281 79.7697 78.318C80.2423 78.4586 80.6545 78.6149 81.006 78.7867C81.3576 78.9547 81.6505 79.1461 81.8849 79.361C82.1193 79.5758 82.2951 79.8199 82.4123 80.0934C82.5295 80.3629 82.588 80.6696 82.588 81.0133C82.588 81.3727 82.5158 81.6969 82.3713 81.986C82.2267 82.2711 82.0197 82.5153 81.7502 82.7184C81.4845 82.9176 81.1642 83.0719 80.7892 83.1813C80.4181 83.2867 80.0041 83.3395 79.547 83.3395C79.1369 83.3395 78.7326 83.2848 78.3341 83.1754C77.9396 83.066 77.5802 82.9 77.256 82.6774C76.9318 82.4508 76.674 82.1696 76.4826 81.8336C76.2912 81.4938 76.1955 81.0973 76.1955 80.6442H77.6662C77.6662 80.9215 77.713 81.1578 77.8068 81.3531C77.9045 81.5485 78.0392 81.7086 78.2111 81.8336C78.383 81.9547 78.5822 82.0446 78.8088 82.1031C79.0392 82.1617 79.2853 82.191 79.547 82.191C79.8908 82.191 80.1779 82.1422 80.4084 82.0446C80.6427 81.9469 80.8185 81.8102 80.9357 81.6344C81.0529 81.4586 81.1115 81.2555 81.1115 81.025Z" fill="#6B6B6B"></path>',12)])]))}},RFt={key:0,width:"37",height:"129",viewBox:"0 0 37 129",fill:"none",xmlns:"http://www.w3.org/2000/svg"},LFt={key:1,width:"37",height:"129",viewBox:"0 0 37 129",fill:"none",xmlns:"http://www.w3.org/2000/svg"},_Ft={__name:"KeyboardStorey",setup(t){const e=ct("$viewer"),i=De(()=>e.i18n.locale==="fr");return(o,n)=>i.value?(M(),_("svg",RFt,[...n[0]||(n[0]=[$r('<rect y="25" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M16.2509 38.4688L18.0614 41.5801L19.872 38.4688H21.5653L18.9872 42.6934L21.6298 47H19.9189L18.0614 43.8301L16.204 47H14.4872L17.1357 42.6934L14.5517 38.4688H16.2509Z" fill="#6B6B6B"></path><rect y="68.1112" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M15.7763 88.3063L17.4755 81.691H18.3661L18.2665 83.3961L16.4501 90.2223H15.5243L15.7763 88.3063ZM14.5048 81.691L15.8817 88.2535L16.0048 90.2223H15.0204L13.0458 81.691H14.5048ZM20.2939 88.236L21.6532 81.691H23.1181L21.1435 90.2223H20.1591L20.2939 88.236ZM18.7118 81.691L20.3935 88.3239L20.6396 90.2223H19.7138L17.9267 83.3961L17.8329 81.691H18.7118Z" fill="#6B6B6B"></path><path d="M18 0L26 11H10L18 0Z" fill="#2F374A"></path><rect x="14" y="13" width="8" height="2" fill="#2F374A"></rect><rect x="14" y="17" width="8" height="4" fill="#2F374A"></rect><path d="M18 129L10 118L26 118L18 129Z" fill="#2F374A"></path><rect x="22" y="116" width="8" height="2" transform="rotate(-180 22 116)" fill="#2F374A"></rect><rect x="22" y="112" width="8" height="4" transform="rotate(-180 22 112)" fill="#2F374A"></rect>',10)])])):(M(),_("svg",LFt,[...n[1]||(n[1]=[$r('<rect y="25" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M16.2509 38.4688L18.0614 41.5801L19.872 38.4688H21.5653L18.9872 42.6934L21.6298 47H19.9189L18.0614 43.8301L16.204 47H14.4872L17.1357 42.6934L14.5517 38.4688H16.2509Z" fill="#6B6B6B"></path><rect y="68.1112" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M21.2665 89.0563V90.2223H15.3427V89.0563H21.2665ZM21.1317 82.5992L15.8876 90.2223H14.9032V89.2906L20.165 81.691H21.1317V82.5992ZM20.5868 81.691V82.8629H14.9384V81.691H20.5868Z" fill="#6B6B6B"></path><path d="M18 0L26 11H10L18 0Z" fill="#2F374A"></path><rect x="14" y="13" width="8" height="2" fill="#2F374A"></rect><rect x="14" y="17" width="8" height="4" fill="#2F374A"></rect><path d="M18 129L10 118L26 118L18 129Z" fill="#2F374A"></path><rect x="22" y="116" width="8" height="2" transform="rotate(-180 22 116)" fill="#2F374A"></rect><rect x="22" y="112" width="8" height="4" transform="rotate(-180 22 112)" fill="#2F374A"></rect>',10)])]))}},FFt={},OFt={width:"174",height:"130",viewBox:"0 0 174 130",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function UFt(t,e){return M(),_("svg",OFt,[...e[0]||(e[0]=[$r('<path d="M33.1118 0.382324H131.606L141.853 99.4882H23.4L33.1118 0.382324Z" fill="#F2F2F2"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M22.9412 99.8706H142.235L131.988 0.305882V0H32.8059L23.0176 99.4882L22.9412 99.8706ZM141.394 99.1059H23.7823L33.4941 0.764706H131.3L141.394 99.1059Z" fill="#9E9E9E"></path><path d="M62.1705 9.86475L60.7941 46.953H103.771V9.86475H62.1705Z" fill="white"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M60.4117 47.3354H104.153H104.229V9.48242H61.8647L60.4117 47.3354ZM103.388 46.5707H61.1764L62.5529 10.2471H103.388V46.5707Z" fill="#9E9E9E"></path><path d="M60.7942 46.9529L64.5412 61.7882H100.1L103.771 46.9529H60.7942Z" fill="white"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M64.2353 62.1706H100.406L104.306 46.5706H60.3353L64.2353 62.1706ZM99.7942 61.4059H64.8471L61.3294 47.3353H103.312L99.7942 61.4059Z" fill="#9E9E9E"></path><path d="M85.2648 34.7939L85.0354 53.8351L90.0825 49.0175L97.806 49.5528L85.2648 34.7939Z" fill="white"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M83.8118 57.5823L83.7354 31.5823L100.406 51.4646L90.3883 49.9352L83.8118 57.5823ZM85.8765 37.3176L85.953 51.9235L89.6236 47.6411L95.2824 48.4823L85.8765 37.3176Z" fill="black"></path><path d="M26.3059 128.241H25.9236C17.5883 128.241 10.7059 121.359 10.7059 113.024V100.253C10.7059 91.9178 17.5883 85.0354 25.9236 85.0354H26.3059C34.6412 85.0354 41.5236 91.9178 41.5236 100.253V113.024C41.5236 121.359 34.6412 128.241 26.3059 128.241Z" fill="white"></path><path d="M137.188 128.241H136.806C128.471 128.241 121.588 121.359 121.588 113.024V100.253C121.588 91.9178 128.471 85.0354 136.806 85.0354H137.188C145.524 85.0354 152.406 91.9178 152.406 100.253V113.024C152.406 121.359 145.524 128.241 137.188 128.241Z" fill="white"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M25.4647 129.159H26.9942C35.6353 129.159 42.6706 122.2 42.5942 113.559V99.6413C42.5942 91.0766 35.6353 84.0413 26.9942 84.0413H25.4647C16.9 84.0413 9.86475 91.0001 9.86475 99.6413V113.559C9.86475 122.124 16.8236 129.159 25.4647 129.159ZM12.1589 99.5648C12.1589 92.2236 18.1236 86.2589 25.4647 86.2589H26.9942C34.3353 86.2589 40.3 92.2236 40.3 99.5648V113.482C40.3 120.824 34.3353 126.788 26.9942 126.788H25.4647C18.1236 126.788 12.1589 120.824 12.1589 113.482V99.5648Z" fill="#30374B"></path><path d="M26.3823 104.459C25.5411 104.459 24.8529 103.771 24.8529 102.929V98.4176C24.8529 97.5764 25.5411 96.8882 26.3823 96.8882C27.2235 96.8882 27.9117 97.5764 27.9117 98.4176V102.929C27.9117 103.771 27.2235 104.459 26.3823 104.459Z" fill="#30374B"></path><path d="M15.3706 84.1177C14.8353 84.1177 14.3765 83.6589 14.3765 83.1236V75.4765C14.3765 74.9412 14.8353 74.4824 15.3706 74.4824C15.9059 74.4824 16.3647 74.9412 16.3647 75.4765V83.1236C16.3647 83.6589 15.9059 84.1177 15.3706 84.1177Z" fill="#F8C62C"></path><path d="M9.63529 90.3884C9.63529 90.9237 9.17647 91.3825 8.64118 91.3825H0.994118C0.458824 91.3825 0 90.9237 0 90.3884C0 89.8531 0.458824 89.3943 0.994118 89.3943H8.64118C9.17647 89.3943 9.63529 89.8531 9.63529 90.3884Z" fill="#F8C62C"></path><path d="M11.9294 86.4117C11.5471 86.7941 10.8589 86.7941 10.4765 86.4117L3.74709 79.6823C3.36474 79.3 3.36474 78.6117 3.74709 78.2294C4.12944 77.847 4.81768 77.847 5.20003 78.2294L11.9294 84.9588C12.3118 85.3412 12.3118 86.0294 11.9294 86.4117Z" fill="#F8C62C"></path><path d="M87.7117 105.682H82.9706V100.941H80.8294V105.682H76.1647V107.747H80.8294V112.488H82.9706V107.747H87.7117V105.682Z" fill="#F8C62C"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M136.194 129.159H137.724C146.365 129.159 153.4 122.2 153.324 113.559V99.6413C153.324 91.0766 146.365 84.0413 137.724 84.0413H136.194C127.629 84.0413 120.594 91.0001 120.594 99.6413V113.559C120.594 122.124 127.553 129.159 136.194 129.159ZM122.888 99.5648C122.888 92.2236 128.853 86.2589 136.194 86.2589H137.724C145.065 86.2589 151.029 92.2236 151.029 99.5648V113.482C151.029 120.824 145.065 126.788 137.724 126.788H136.194C128.853 126.788 122.888 120.824 122.888 113.482V99.5648Z" fill="#30374B"></path><path d="M137.112 104.459C136.271 104.459 135.582 103.771 135.582 102.929V98.4176C135.582 97.5764 136.271 96.8882 137.112 96.8882C137.953 96.8882 138.641 97.5764 138.641 98.4176V102.929C138.641 103.771 137.953 104.459 137.112 104.459Z" fill="#30374B"></path><path d="M102.776 106.753L108.129 101.4C108.588 100.941 108.588 100.253 108.129 99.7941C107.671 99.3352 106.982 99.3352 106.524 99.7941L100.406 105.912C100.176 106.141 100.1 106.447 100.1 106.753C100.1 107.059 100.176 107.365 100.406 107.594L106.524 113.712C106.982 114.171 107.671 114.171 108.129 113.712C108.588 113.253 108.588 112.565 108.129 112.106L102.776 106.753Z" fill="#F8C62C"></path><path d="M171.218 106.753L165.865 101.4C165.406 100.941 165.406 100.253 165.865 99.7941C166.324 99.3352 167.012 99.3352 167.471 99.7941L173.588 105.912C173.818 106.141 173.894 106.447 173.894 106.753C173.894 107.059 173.818 107.365 173.588 107.594L167.471 113.712C167.012 114.171 166.324 114.171 165.865 113.712C165.406 113.253 165.406 112.565 165.865 112.106L171.218 106.753Z" fill="#F8C62C"></path>',20)])])}const NFt=j(FFt,[["render",UFt]]),jFt={},VFt={width:"42",height:"55",viewBox:"0 0 42 55",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function HFt(t,e){return M(),_("svg",VFt,[...e[0]||(e[0]=[$r('<path d="M1.7192 47.4914L0.501465 10.6013H40.8298L40.3284 47.4914H1.7192Z" fill="white"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M1.36104 47.8495H40.6866L41.188 10.2432H0.143311L1.36104 47.8495ZM39.9703 47.1332H2.07735L0.859623 10.9595H40.4717L39.9703 47.1332Z" fill="#9E9E9E"></path><path d="M4.29792 0.429688L0.501465 10.6013H40.8298L37.5348 0.429688H4.29792Z" fill="white"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M0 10.9596H41.3312L37.7496 0H4.01135L0 10.9596ZM40.3284 10.2433H1.00284L4.51277 0.716312H37.2482L40.3284 10.2433Z" fill="#9E9E9E"></path><path d="M18.9312 23.0255C19.4326 23.0255 19.8624 22.5957 19.8624 22.0943V14.9312C19.8624 14.4298 19.4326 14 18.9312 14C18.4298 14 18 14.4298 18 14.9312V22.0943C18 22.5957 18.4298 23.0255 18.9312 23.0255Z" fill="#F8C62C"></path><path d="M24.3035 28.9708C24.3035 29.4722 24.7333 29.902 25.2347 29.902H32.3978C32.8992 29.902 33.329 29.4722 33.329 28.9708C33.329 28.4693 32.8992 28.0395 32.3978 28.0395H25.2347C24.7333 27.9679 24.3035 28.3977 24.3035 28.9708Z" fill="#F8C62C"></path><path d="M22.1546 25.2461C22.5128 25.6043 23.1575 25.6043 23.5156 25.2461L29.8192 18.9426C30.1773 18.5844 30.1773 17.9398 29.8192 17.5816C29.461 17.2234 28.8163 17.2234 28.4582 17.5816L22.1546 23.8852C21.7248 24.2433 21.7248 24.8164 22.1546 25.2461Z" fill="#F8C62C"></path><path d="M21.5855 31.4087L21.3477 51.0688L26.5798 46.0745L34.5865 46.6294L21.5855 31.4087Z" fill="white"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M20.0793 54.9534L20 28L37.2819 48.6114L26.8969 47.0259L20.0793 54.9534ZM22.2197 33.9456L22.299 49.087L26.1041 44.6477L31.9705 45.5197L22.2197 33.9456Z" fill="black"></path>',9)])])}const zFt=j(jFt,[["render",HFt]]),qFt={},QFt={width:"124",height:"152",viewBox:"0 0 124 152",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function GFt(t,e){return M(),_("svg",QFt,[...e[0]||(e[0]=[$r('<path d="M10.5436 0.396484H112.649L123.272 103.216H0.475708L10.5436 0.396484Z" fill="#F2F2F2"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M0 103.612H123.668L113.046 0.317098V0H10.2264L0.0792746 103.216L0 103.612ZM122.876 102.819H0.951324L10.9399 0.792766H112.332L122.876 102.819Z" fill="#9E9E9E"></path><path d="M40.7472 10.2266L39.241 48.6747H83.7933V10.2266H40.7472Z" fill="white"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M38.8446 49.071H84.1897H84.269V9.83008H40.3508L38.8446 49.071ZM83.4762 48.2783H39.7166L41.0643 10.6228H83.4762V48.2783Z" fill="#9E9E9E"></path><path d="M39.2408 48.6748L43.1253 64.0541H79.988L83.7932 48.6748H39.2408Z" fill="white"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M42.8083 64.4503H80.3052L84.3482 48.2783H38.7653L42.8083 64.4503ZM79.671 63.6576H43.4425L39.7958 49.0711H83.3176L79.671 63.6576Z" fill="#9E9E9E"></path><path d="M64.6088 36.1494L64.371 55.8095L69.6031 50.8152L77.6098 51.3701L64.6088 36.1494Z" fill="white"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M63.1026 59.6938L63.0233 32.7405L80.3052 53.3519L69.9202 51.7664L63.1026 59.6938ZM65.243 38.6861L65.3223 53.8275L69.1275 49.3881L74.9938 50.2602L65.243 38.6861Z" fill="black"></path><path d="M61.7549 130.724H61.3585C52.7176 130.724 45.5829 123.589 45.5829 114.948V101.709C45.5829 93.0686 52.7176 85.9338 61.3585 85.9338H61.7549C70.3958 85.9338 77.5306 93.0686 77.5306 101.709V114.948C77.5306 123.589 70.4751 130.724 61.7549 130.724Z" fill="white"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M44.7902 114.79C44.7902 124.144 52.4005 131.754 61.7549 131.754C71.1093 131.754 78.7197 124.065 78.7197 114.79V101.947C78.7197 92.5928 71.1093 84.9824 61.7549 84.9824C52.4005 84.9824 44.7902 92.5928 44.7902 101.947V114.79ZM47.1684 101.868C47.1684 93.8612 53.6689 87.2814 61.7549 87.2814C69.7617 87.2814 76.3415 93.7819 76.3415 101.868V114.71C76.3415 122.717 69.8409 129.297 61.7549 129.297C53.7482 129.297 47.1684 122.796 47.1684 114.71V101.868Z" fill="#30374B"></path><path d="M61.8341 106.069C60.9621 106.069 60.2487 105.356 60.2487 104.484V100.996C60.2487 100.124 60.9621 99.4104 61.8341 99.4104C62.7062 99.4104 63.4196 100.124 63.4196 100.996V104.484C63.4196 105.356 62.7062 106.069 61.8341 106.069Z" fill="#30374B"></path><path d="M61.8341 97.7457C60.9621 97.7457 60.2487 97.0322 60.2487 96.1602C60.2487 95.2882 60.9621 94.5747 61.8341 94.5747C62.7062 94.5747 63.4196 95.2882 63.4196 96.1602C63.4196 97.0322 62.7062 97.7457 61.8341 97.7457Z" fill="#30374B"></path><path d="M61.8341 110.826C60.9621 110.826 60.2487 110.113 60.2487 109.241C60.2487 108.369 60.9621 107.655 61.8341 107.655C62.7062 107.655 63.4196 108.369 63.4196 109.241C63.4196 110.113 62.7062 110.826 61.8341 110.826Z" fill="#30374B"></path><path d="M61.8342 142.298L67.3834 136.749C67.859 136.273 68.5725 136.273 69.0481 136.749C69.5238 137.224 69.5238 137.938 69.0481 138.414L62.7062 144.756C62.4684 144.993 62.1513 145.073 61.8342 145.073C61.5171 145.073 61.2 144.993 60.9621 144.756L54.6202 138.414C54.1445 137.938 54.1445 137.224 54.6202 136.749C55.0958 136.273 55.8093 136.273 56.2849 136.749L61.8342 142.298Z" fill="#F8C62C"></path><path d="M61.8342 149.195L67.3834 143.646C67.859 143.17 68.5725 143.17 69.0481 143.646C69.5238 144.121 69.5238 144.835 69.0481 145.311L62.7062 151.653C62.4684 151.89 62.1513 151.97 61.8342 151.97C61.5171 151.97 61.2 151.89 60.9621 151.653L54.6202 145.311C54.1445 144.835 54.1445 144.121 54.6202 143.646C55.0958 143.17 55.8093 143.17 56.2849 143.646L61.8342 149.195Z" fill="#F8C62C"></path>',15)])])}const KFt=j(qFt,[["render",GFt]]),JFt={name:"FirstPersonViewHelper",components:{KeyboardNavigate:DFt,KeyboardStorey:_Ft,MouseMove:NFt,MouseStorey:zFt,MouseZoom:KFt},emits:["close"],methods:{close(){this.$emit("close")},clear(){localStorage.setItem("firstPersonViewHelper","false"),this.close()}}},ZFt={class:"bimdata-first-person-view-helper"},WFt={class:"bimdata-first-person-view-helper__header"},YFt={class:"bimdata-first-person-view-helper__content"},XFt={class:"bimdata-first-person-view-helper__content__main"},$Ft={class:"bimdata-first-person-view-helper__content__main__left"},eOt={class:"bimdata-first-person-view-helper__content__main__left__element"},tOt={class:"bimdata-first-person-view-helper__content__main__left__element__picture"},iOt={class:"bimdata-first-person-view-helper__content__main__left__element__text"},oOt={class:"bimdata-first-person-view-helper__content__main__left__element__text__tilte"},rOt={class:"bimdata-first-person-view-helper__content__main__left__element__text__list"},nOt={class:"bimdata-first-person-view-helper__content__main__left__element"},aOt={class:"bimdata-first-person-view-helper__content__main__left__element__picture"},sOt={class:"bimdata-first-person-view-helper__content__main__left__element__text"},lOt={class:"bimdata-first-person-view-helper__content__main__left__element__text__tilte"},cOt={class:"bimdata-first-person-view-helper__content__main__left__element__text__list"},dOt={class:"bimdata-first-person-view-helper__content__main__left__element"},uOt={class:"bimdata-first-person-view-helper__content__main__left__element__picture"},hOt={class:"bimdata-first-person-view-helper__content__main__left__element__text"},pOt={class:"bimdata-first-person-view-helper__content__main__left__element__text__tilte"},fOt={class:"bimdata-first-person-view-helper__content__main__left__element__text__list"},AOt={class:"bimdata-first-person-view-helper__content__main__right"},gOt={class:"bimdata-first-person-view-helper__content__main__right__title"},mOt={class:"bimdata-first-person-view-helper__content__main__right__content"},vOt={class:"bimdata-first-person-view-helper__content__main__right__content__picture"},yOt={class:"bimdata-first-person-view-helper__content__main__right__content__picture__element"},bOt={class:"bimdata-first-person-view-helper__content__main__right__content__picture__element"},wOt={class:"bimdata-first-person-view-helper__content__main__right__content__text"},COt={class:"bimdata-first-person-view-helper__content__footer"},xOt={class:"bimdata-first-person-view-helper__footer-buttons"};function kOt(t,e,i,o,n,r){const a=I("KeyboardNavigate"),s=I("MouseMove"),l=I("MouseZoom"),c=I("MouseStorey"),d=I("KeyboardStorey"),u=I("BIMDataButton");return M(),_("div",ZFt,[b("h1",WFt,z(t.$t("viewer3d.firstPersonViewHelper.title")),1),b("div",YFt,[b("div",XFt,[b("div",$Ft,[b("div",eOt,[b("div",tOt,[D(a)]),b("div",iOt,[b("h4",oOt,z(t.$t("viewer3d.firstPersonViewHelper.keyboardUsage")),1),b("ul",rOt,[b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.forward")),1),b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.backward")),1),b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.left")),1),b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.right")),1)])])]),b("div",nOt,[b("div",aOt,[D(s)]),b("div",sOt,[b("h4",lOt,z(t.$t("viewer3d.firstPersonViewHelper.mouseOrientation")),1),b("ul",cOt,[b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.pressLeft")),1),b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.mouseMove")),1),b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.mouseVertical")),1)])])]),b("div",dOt,[b("div",uOt,[D(l)]),b("div",hOt,[b("h4",pOt,z(t.$t("viewer3d.firstPersonViewHelper.mouseZoom")),1),b("ul",fOt,[b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.mouseWheelForward")),1),b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.mouseWheelBackward")),1)])])])]),b("div",AOt,[b("h4",gOt,z(t.$t("viewer3d.firstPersonViewHelper.changeStorey")),1),b("div",mOt,[b("div",vOt,[b("div",yOt,[D(c)]),b("div",bOt,[D(d)])]),b("div",wOt,[b("ul",null,[b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.storeyClick")),1),b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.moveCameraToObject")),1)]),b("ul",null,[b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.keyboardStoreyChange")),1)])])])])]),b("div",COt,z(t.$t("viewer3d.firstPersonViewHelper.contentFooter")),1)]),b("div",xOt,[D(u,{color:"primary",fill:"",radius:"",width:"200px",onClick:r.close},{default:N(()=>[Je(z(t.$t("viewer3d.firstPersonViewHelper.understand")),1)]),_:1},8,["onClick"]),D(u,{color:"primary",outline:"",radius:"",width:"200px",onClick:r.clear},{default:N(()=>[Je(z(t.$t("viewer3d.firstPersonViewHelper.noRecall")),1)]),_:1},8,["onClick"])])])}const Nee=j(JFt,[["render",kOt],["__scopeId","data-v-77cce9d5"]]),MOt={components:{ShortcutsModal:zy,FirstPersonViewHelper:Nee},data(){const t=this.$t;return{tabs:[{id:0,get label(){return t("viewer3d.modals.3d")}},{id:1,get label(){return t("viewer3d.modals.firstPerson")}}],activeTab:0,elements:[{image:"shortcutRotate",title:this.$t("shortcuts-helper.title_rotate"),text:this.$t("shortcuts-helper.text_rotate")},{image:"shortcutZoom",title:this.$t("shortcuts-helper.title_zoom"),text:this.$t("shortcuts-helper.text_zoom")},{image:"shortcutOpen",title:this.$t("shortcuts-helper.title_open"),text:this.$t("shortcuts-helper.text_open")}],shortcuts:[{letter:"F",text:this.$t("context_menu.fit_view")},{letter:"C",text:this.$t("context_menu.select_all")},{letter:"V",text:this.$t("context_menu.deselect_all")},{letter:"H",text:this.$t("context_menu.hide")},{letter:"Y",text:this.$t("context_menu.select_similar")},{letter:"I",text:this.$t("context_menu.isolate")},{letter:"U",text:this.$t("context_menu.reintegrate")},{letter:"R",text:this.$t("context_menu.show_all")},{letter:"1",text:this.$t("shortcuts-helper.shortcut_1")},{letter:"2",text:this.$t("shortcuts-helper.shortcut_2")},{letter:"3",text:this.$t("shortcuts-helper.shortcut_3")},{letter:"4",text:this.$t("shortcuts-helper.shortcut_4")},{letter:"5",text:this.$t("shortcuts-helper.shortcut_5")},{letter:"6",text:this.$t("shortcuts-helper.shortcut_6")},{maj:!0,text:this.$t("shortcuts-helper.shortcut_pan"),illustration:"click"},{alt:!0,text:this.$t("shortcuts-helper.shortcut_open"),illustration:"click"},{shift:!0,text:this.$t("shortcuts-helper.shortcut_multiselect"),illustration:"click"}]}}},BOt={class:"bimdata-shortcuts-helper__header"};function EOt(t,e,i,o,n,r){const a=I("BIMDataTabs"),s=I("ShortcutsModal"),l=I("FirstPersonViewHelper");return M(),_("div",null,[b("div",BOt,[D(a,{tabs:n.tabs,width:"490px",height:"44px",tabSize:"245",onTabSelected:e[0]||(e[0]=c=>n.activeTab=n.tabs.indexOf(c)),selected:n.activeTab},null,8,["tabs","selected"])]),n.activeTab===0?(M(),J(s,{key:0,elements:n.elements,shortcuts:n.shortcuts,onClose:e[1]||(e[1]=c=>t.$emit("close"))},{title:N(()=>[Je(z(t.$t("shortcuts-helper.title_modal")),1)]),_:1},8,["elements","shortcuts"])):(M(),J(l,{key:1,onClose:e[2]||(e[2]=c=>t.$emit("close"))}))])}const POt=j(MOt,[["render",EOt],["__scopeId","data-v-a26872a0"]]),IOt="data:image/svg+xml,%3csvg%20width='44'%20height='44'%20viewBox='0%200%2044%2044'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3ccircle%20cx='22'%20cy='22'%20r='2'%20fill='%232F374A'/%3e%3cpath%20d='M1.20102%2023.5V24.5H2.20102H10.261C11.4116%2029.9278%2016.2295%2034%2022%2034C27.7705%2034%2032.5884%2029.9278%2033.739%2024.5H41.799H42.799V23.5V20.5V19.5H41.799H33.739C32.5884%2014.0722%2027.7705%2010%2022%2010C16.2295%2010%2011.4116%2014.0722%2010.261%2019.5H2.20102H1.20102V20.5V23.5ZM14.619%2022C14.619%2017.9236%2017.9236%2014.619%2022%2014.619C26.0764%2014.619%2029.381%2017.9236%2029.381%2022C29.381%2026.0764%2026.0764%2029.381%2022%2029.381C17.9236%2029.381%2014.619%2026.0764%2014.619%2022Z'%20fill='%232F374A'%20stroke='white'%20stroke-width='2'/%3e%3c/svg%3e",SOt="data:image/svg+xml,%3csvg%20width='44'%20height='44'%20viewBox='0%200%2044%2044'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3ccircle%20cx='22'%20cy='22'%20r='2'%20fill='%232F374A'/%3e%3cpath%20d='M6.23222%2034.2322L5.52512%2034.9393L6.23222%2035.6464L8.35354%2037.7678L9.06065%2038.4749L9.76776%2037.7678L15.4677%2032.0678C17.3477%2033.2898%2019.592%2034%2022%2034C24.408%2034%2026.6523%2033.2898%2028.5323%2032.0678L34.2322%2037.7678L34.9393%2038.4749L35.6464%2037.7678L37.7678%2035.6465L38.4749%2034.9393L37.7678%2034.2322L32.0678%2028.5323C33.2898%2026.6523%2034%2024.408%2034%2022C34%2019.592%2033.2898%2017.3477%2032.0678%2015.4677L37.7678%209.76776L38.4749%209.06065L37.7678%208.35354L35.6464%206.23222L34.9393%205.52512L34.2322%206.23222L28.5322%2011.9322C26.6523%2010.7102%2024.408%2010%2022%2010C19.592%2010%2017.3477%2010.7102%2015.4677%2011.9322L9.76776%206.23224L9.06065%205.52513L8.35354%206.23224L6.23222%208.35356L5.52512%209.06066L6.23222%209.76777L11.9322%2015.4678C10.7102%2017.3477%2010%2019.592%2010%2022C10%2024.408%2010.7102%2026.6523%2011.9322%2028.5323L6.23222%2034.2322ZM14.619%2022C14.619%2017.9236%2017.9236%2014.6191%2022%2014.6191C26.0764%2014.6191%2029.381%2017.9236%2029.381%2022C29.381%2026.0764%2026.0764%2029.381%2022%2029.381C17.9236%2029.381%2014.619%2026.0764%2014.619%2022Z'%20fill='%232F374A'%20stroke='white'%20stroke-width='2'/%3e%3c/svg%3e",TOt="data:image/svg+xml,%3csvg%20width='44'%20height='44'%20viewBox='0%200%2044%2044'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3ccircle%20cx='22'%20cy='22'%20r='2'%20fill='%232F374A'/%3e%3cpath%20d='M14.619%2022C14.619%2017.9236%2017.9236%2014.619%2022%2014.619C26.0764%2014.619%2029.381%2017.9236%2029.381%2022C29.381%2026.0764%2026.0764%2029.381%2022%2029.381C17.9236%2029.381%2014.619%2026.0764%2014.619%2022ZM22%2010C15.3726%2010%2010%2015.3726%2010%2022C10%2028.6274%2015.3726%2034%2022%2034C28.6274%2034%2034%2028.6274%2034%2022C34%2015.3726%2028.6274%2010%2022%2010Z'%20fill='%232F374A'%20stroke='white'%20stroke-width='2'/%3e%3c/svg%3e",DOt="data:image/svg+xml,%3csvg%20width='44'%20height='44'%20viewBox='0%200%2044%2044'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M14.619%2022C14.619%2017.9236%2017.9236%2014.619%2022%2014.619C23.8642%2014.619%2025.5667%2015.3094%2026.8665%2016.4504L14.7593%2023.4405C14.6673%2022.9751%2014.619%2022.4935%2014.619%2022ZM29.381%2022C29.381%2026.0764%2026.0764%2029.381%2022%2029.381C20.0879%2029.381%2018.3459%2028.6547%2017.0341%2027.4608L29.2136%2020.4289C29.3232%2020.9347%2029.381%2021.4602%2029.381%2022ZM22%2010C15.3726%2010%2010%2015.3726%2010%2022C10%2028.6274%2015.3726%2034%2022%2034C28.6274%2034%2034%2028.6274%2034%2022C34%2015.3726%2028.6274%2010%2022%2010Z'%20fill='%232F374A'%20stroke='white'%20stroke-width='2'/%3e%3c/svg%3e",ROt="data:image/svg+xml,%3csvg%20width='33'%20height='33'%20viewBox='0%200%2033%2033'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M1.70001%2016.8667V17.3667H2.20001H7.33335H7.83335V16.8667V16.1333V15.6333H7.33335L2.20001%2015.6333H1.70001V16.1333L1.70001%2016.8667ZM30.8%2017.3667H31.3V16.8667V16.1333V15.6333H30.8L25.6667%2015.6333H25.1667V16.1333V16.8667V17.3667H25.6667H30.8Z'%20fill='%232F374A'%20stroke='white'/%3e%3cpath%20d='M16.1333%201.70001L15.6333%201.70001L15.6333%202.20001L15.6333%207.33335L15.6333%207.83335L16.1333%207.83335L16.8667%207.83335L17.3667%207.83335L17.3667%207.33335L17.3667%202.20001L17.3667%201.70001L16.8667%201.70001L16.1333%201.70001ZM15.6333%2030.8L15.6333%2031.3L16.1333%2031.3L16.8667%2031.3L17.3667%2031.3L17.3667%2030.8L17.3667%2025.6667L17.3667%2025.1667L16.8667%2025.1667L16.1333%2025.1667L15.6333%2025.1667L15.6333%2025.6667L15.6333%2030.8Z'%20fill='%232F374A'%20stroke='white'/%3e%3c/svg%3e",LOt={0:{positions:[36.5625,31.640625,36.5625,19.51171875,36.42067337036133,16.11605453491211,35.99519348144531,13.020120620727539,35.28605651855469,10.223917961120605,34.293270111083984,7.727446556091309,33.01683044433594,5.530706882476807,30.959993362426758,3.3593661785125732,28.725576400756836,1.6479235887527466,26.31357765197754,.39637935161590576,23.723995208740234,-.39526674151420593,20.956830978393555,-.7270146012306213,20.3203125,-.73828125,17.307449340820312,-.5108020901679993,14.569392204284668,.17163534462451935,12.106142044067383,1.3090311288833618,9.917699813842773,2.9013850688934326,8.174575805664062,5.153988838195801,6.733142375946045,7.555612087249756,5.593398094177246,10.106253623962402,4.755343437194824,12.805914878845215,4.218978404998779,15.654594421386719,3.9843032360076904,18.652292251586914,3.97265625,19.51171875,3.97265625,31.640625,4.115384578704834,35.0230827331543,4.543569564819336,38.11090850830078,5.257210731506348,40.904109954833984,6.256308555603027,43.40268325805664,7.540863037109375,45.606624603271484,9.608292579650879,47.79111099243164,11.846480369567871,49.51402282714844,14.255425453186035,50.775352478027344,16.835128784179688,51.57510757446289,19.585588455200195,51.91328811645508,20.25,51.92578125,23.26165771484375,51.697608947753906,25.997068405151367,51.013092041015625,28.456228256225586,49.872230529785156,30.639141082763672,48.2750244140625,32.375572204589844,46.0158576965332,33.81153869628906,43.60895538330078,34.947044372558594,41.0543212890625,35.78208923339844,38.35194778442383,36.31666946411133,35.5018424987793,36.55078887939453,32.50400161743164,36.5625,31.640625,29.63671875,18.10546875,29.63671875,33.1171875,29.450082778930664,36.561954498291016,28.89017677307129,39.497215270996094,27.956998825073242,41.92298126220703,25.967069625854492,44.22639083862305,23.724157333374023,45.72625732421875,21.228260040283203,46.422576904296875,20.25,46.4765625,17.354780197143555,46.07659912109375,14.97888469696045,44.876708984375,13.33356761932373,42.470394134521484,12.110569953918457,39.9057731628418,11.309891700744629,37.1828498840332,10.931534767150879,34.30161666870117,10.8984375,33.1171875,10.8984375,18.10546875,11.085087776184082,14.669450759887695,11.645040512084961,11.733874320983887,12.578293800354004,9.298736572265625,14.569818496704102,6.974865436553955,16.804428100585938,5.454482555389404,19.282119750976562,4.737586975097656,20.3203125,4.67578125,23.212167739868164,5.077450752258301,25.581016540527344,6.282459735870361,27.21183204650879,8.69408893585205,28.425546646118164,11.263723373413086,29.2221622467041,13.991360664367676,29.6016788482666,16.877002716064453],indices:[0,2,1,2,4,3,4,6,5,6,8,7,8,10,9,10,12,11,12,14,13,14,16,15,16,18,17,18,20,19,20,22,21,22,24,23,24,63,62,61,24,62,24,26,25,26,28,27,28,30,29,30,32,31,32,34,33,34,36,35,36,38,37,38,40,39,40,42,41,42,44,43,44,0,45,0,4,2,4,8,6,8,12,10,12,16,14,16,20,18,20,24,22,24,64,63,60,24,61,24,28,26,28,32,30,32,36,34,36,40,38,40,44,42,44,4,0,4,12,8,12,20,16,20,64,24,59,24,60,24,32,28,32,40,36,40,4,44,20,65,64,58,24,59,20,66,65,57,24,58,12,66,20,57,32,24,12,67,66,56,32,57,12,68,67,55,32,56,12,69,68,54,32,55,12,70,69,53,32,54,12,71,70,53,40,32,4,71,12,52,40,53,4,72,71,51,40,52,4,73,72,50,40,51,4,74,73,49,40,50,4,75,74,48,40,49,4,76,75,47,40,48,40,76,4,76,40,47],width:32.58984375},1:{positions:[23.94140625,51.1875,23.94140625,0,17.015625,0,17.015625,44.4375,6.5390625,44.296875,6.5390625,49.2890625],indices:[0,2,1,3,5,4,0,3,2,3,0,5],width:17.40234375},2:{positions:[37.3359375,5.4140625,37.3359375,0,4.1484375,0,4.1484375,4.74609375,20.91796875,23.37890625,23.33412742614746,26.180971145629883,25.239078521728516,28.61744499206543,26.632823944091797,30.68832778930664,27.938528060913086,33.606327056884766,28.560094833374023,36.34145736694336,28.6171875,37.40625,28.23740577697754,40.36100769042969,27.09806251525879,42.90309143066406,24.87748908996582,45.0150146484375,22.4631290435791,46.19827651977539,20.4609375,46.4765625,17.237478256225586,46.17487716674805,14.632962226867676,45.26981735229492,12.647390365600586,43.76138687133789,11.200069427490234,41.599464416503906,10.360716819763184,38.91020965576172,10.125,36.10546875,3.48046875,36.10546875,3.41015625,36.31640625,3.580944538116455,39.24900436401367,4.255249977111816,41.95781326293945,5.433072566986084,44.442840576171875,7.114412784576416,46.704078674316406,9.256887435913086,48.52997589111328,11.61109447479248,49.96455383300781,14.177034378051758,51.007816314697266,16.954708099365234,51.659759521484375,19.944114685058594,51.920387268066406,20.4609375,51.92578125,23.575925827026367,51.698787689208984,26.37569808959961,51.01780319213867,28.86025619506836,49.88283157348633,31.029598236083984,48.29386901855469,32.93091583251953,46.07616424560547,34.31552505493164,43.65195846557617,35.18342971801758,41.0212516784668,35.53462600708008,38.18403625488281,35.54296875,37.65234375,35.271297454833984,34.8802490234375,34.45627975463867,32.10430145263672,33.097923278808594,29.324501037597656,31.655981063842773,27.067161560058594,29.948768615722656,24.73398208618164,27.976285934448242,22.324962615966797,26.12109375,20.25,12.65625,5.58984375,12.7265625,5.4140625],indices:[51,1,0,1,3,2,20,22,21,22,24,23,24,26,25,26,28,27,28,30,29,30,32,31,32,34,33,34,36,35,36,38,37,38,40,39,40,42,41,42,44,43,44,46,45,46,48,47,48,50,49,51,3,1,19,22,20,22,26,24,26,30,28,30,34,32,34,38,36,38,42,40,42,46,44,46,50,48,50,3,51,18,22,19,22,30,26,30,38,34,38,46,42,46,3,50,18,30,22,46,4,3,17,30,18,46,5,4,16,30,17,46,6,5,15,30,16,46,7,6,14,30,15,46,8,7,13,30,14,38,8,46,13,38,30,38,9,8,12,38,13,38,10,9,11,38,12,38,11,10],width:33.92578125},3:{positions:[13.640625,23.37890625,13.640625,28.79296875,19.6875,28.79296875,22.903934478759766,29.15167236328125,25.282482147216797,30.227783203125,26.954715728759766,32.621280670166016,27.896883010864258,35.25688171386719,28.125,37.51171875,27.781084060668945,40.67007064819336,26.749338150024414,43.162776947021484,24.544097900390625,45.051876068115234,22.03769302368164,46.1552734375,19.51171875,46.4765625,16.51466941833496,46.0916633605957,14.03652286529541,44.93696212768555,12.056009292602539,42.62509536743164,10.906388282775879,40.13740539550781,10.58203125,37.79296875,3.9375,37.79296875,3.8671875,38.00390625,4.073190689086914,40.847023010253906,4.870357036590576,43.464176177978516,6.258687496185303,45.85536193847656,8.649903297424316,47.949581146240234,11.105090141296387,49.6024169921875,13.624245643615723,50.81385803222656,16.207372665405273,51.58391189575195,18.854469299316406,51.912574768066406,19.51171875,51.92578125,22.69034194946289,51.71705627441406,25.550539016723633,51.090885162353516,28.09231185913086,50.04726028442383,30.315656661987305,48.58618927001953,32.206153869628906,46.54783248901367,33.6175651550293,44.22849655151367,34.54988479614258,41.62818145751953,35.00312423706055,38.74688720703125,35.05078125,37.37109375,34.68306350708008,34.60222244262695,33.579917907714844,31.84009552001953,31.788928985595703,29.416330337524414,29.652488708496094,27.526569366455078,27.38671875,26.26171875,30.2706241607666,24.998523712158203,32.5009765625,23.31671142578125,34.190120697021484,20.399517059326172,35.28596115112305,17.665790557861328,35.78849792480469,15.115530967712402,35.82421875,14.2734375,35.583168029785156,11.223187446594238,34.860015869140625,8.486950874328613,33.65475845336914,6.064727306365967,31.9674015045166,3.9565165042877197,29.64410972595215,2.185784339904785,27.159265518188477,.8323085308074951,24.512863159179688,-.10391119122505188,21.704906463623047,-.6228747963905334,19.51171875,-.73828125,16.397254943847656,-.535150945186615,13.541664123535156,.07424008101224899,10.9449462890625,1.089891791343689,8.607102394104004,2.5118041038513184,6.504549980163574,4.569301605224609,4.957869052886963,6.847413539886475,3.9670591354370117,9.34614086151123,3.5321204662323,12.065483093261719,3.515625,13.2890625,3.62109375,13.5,10.23046875,13.5,10.628458976745605,10.52513313293457,11.822431564331055,8.080921173095703,14.14232063293457,6.207763671875,16.670166015625,5.072887420654297,19.405969619750977,4.6762919425964355,19.51171875,4.67578125,22.593053817749023,5.02486515045166,25.119962692260742,6.072116374969482,27.08766746520996,8.277663230895996,28.33972930908203,10.727699279785156,28.876150131225586,13.422224998474121,28.8984375,14.1328125,28.579307556152344,17.37627601623535,27.621917724609375,19.90043067932129,25.462261199951172,21.754257202148438,22.976253509521484,22.91082000732422,20.163896560668945,23.3701229095459,19.6875,23.37890625],indices:[86,1,0,16,18,17,18,20,19,20,22,21,22,24,23,24,26,25,26,28,27,28,30,29,30,32,31,32,34,33,34,36,35,36,38,37,38,40,39,40,42,41,42,44,43,44,46,45,46,48,47,48,50,49,50,52,51,52,54,53,54,56,55,56,58,57,58,60,59,60,62,61,62,64,63,64,66,65,66,68,67,85,1,86,15,18,16,18,22,20,22,26,24,26,30,28,30,34,32,34,38,36,38,42,40,42,46,44,46,50,48,50,54,52,54,58,56,58,62,60,62,66,64,66,69,68,84,1,85,14,18,15,18,26,22,26,34,30,34,42,38,42,50,46,50,58,54,58,66,62,66,70,69,83,1,84,14,26,18,58,70,66,83,2,1,13,26,14,58,71,70,82,2,83,12,26,13,58,72,71,82,3,2,11,26,12,58,73,72,82,4,3,10,26,11,58,74,73,81,4,82,10,34,26,58,75,74,9,34,10,50,75,58,8,34,9,50,76,75,7,34,8,50,77,76,6,34,7,50,78,77,5,34,6,50,79,78,5,42,34,50,80,79,4,42,5,50,81,80,81,42,4,42,81,50],width:32.30859375},4:{positions:[31.81640625,51.1875,31.81640625,17.2265625,38.8828125,17.2265625,38.8828125,11.8125,31.81640625,11.8125,31.81640625,0,24.92578125,0,24.92578125,11.8125,1.93359375,11.8125,1.93359375,15.71484375,24.50390625,51.1875,31.81640625,51.1875,24.046875,39.515625,9.31640625,17.2265625,24.92578125,17.2265625,24.92578125,41.23828125,24.71484375,41.2734375],indices:[1,3,2,4,6,5,7,9,8,9,14,13,16,13,12,13,10,9,10,1,0,1,4,3,4,7,6,7,14,9,16,10,13,10,4,1,4,14,7,15,10,16,4,15,14,15,4,10],width:36.94921875},5:{positions:[11.91796875,22.5,6.15234375,23.09765625,9.10546875,51.1875,34.734375,51.1875,34.734375,45.03515625,14.9765625,45.03515625,13.2890625,30.65625,14.99853515625,31.75048828125,16.892578125,32.642578125,19.03271484375,33.25341796875,21.48046875,33.50390625,21.48046875,33.50390625,24.524171829223633,33.29277038574219,27.260135650634766,32.595733642578125,29.6883602142334,31.412792205810547,31.808847427368164,29.743946075439453,33.53106689453125,27.481525421142578,34.8779411315918,25.034576416015625,35.84947204589844,22.40309715270996,36.44565963745117,19.58709144592285,36.66650390625,16.586557388305664,36.66796875,16.3125,36.47660446166992,13.1383056640625,35.90251541137695,10.244234085083008,34.94569778442383,7.630287170410156,33.60615158081055,5.296463966369629,31.54420280456543,3.2312631607055664,29.28870391845703,1.597025990486145,26.839656829833984,.3937528729438782,24.197057723999023,-.3785564601421356,21.360912322998047,-.7199019193649292,20.49609375,-.73828125,17.404800415039062,-.5199803113937378,14.58151912689209,.13492262363433838,12.026251792907715,1.226427435874939,9.738997459411621,2.7545342445373535,7.902623653411865,4.662389278411865,6.586172580718994,6.943535327911377,5.78964376449585,9.59797191619873,5.513038158416748,12.625699043273926,5.51953125,13.25390625,5.58984375,13.46484375,11.84765625,13.46484375,12.231374740600586,10.424592018127441,13.382529258728027,7.983725547790527,15.769926071166992,6.059262275695801,18.29474449157715,4.960567474365234,20.49609375,4.67578125,23.407373428344727,5.077446937561035,25.80744171142578,6.282444000244141,27.603513717651367,8.744783401489258,28.85628890991211,11.317317962646484,29.565767288208008,14.000046730041504,29.7421875,16.2421875,29.464466094970703,19.35067367553711,28.631298065185547,22.06241226196289,26.50613021850586,24.628503799438477,24.30402374267578,26.380647659301758,22.024982452392578,27.31884002685547,20.49609375,27.4921875,17.11406707763672,27.2115478515625,14.758378028869629,26.369632720947266,13.049945831298828,24.7330322265625],indices:[2,4,3,6,8,7,12,14,13,14,16,15,16,18,17,18,20,19,20,22,21,22,24,23,24,26,25,26,28,27,28,30,29,30,32,31,32,34,33,34,36,35,36,38,37,38,40,39,40,42,41,2,5,4,6,9,8,12,16,14,16,20,18,20,24,22,24,28,26,28,32,30,32,36,34,36,40,38,40,43,42,1,5,2,12,20,16,20,28,24,28,36,32,36,43,40,1,6,5,36,44,43,1,9,6,36,45,44,28,45,36,28,46,45,28,47,46,28,48,47,28,49,48,20,49,28,20,50,49,20,51,50,20,52,51,20,53,52,20,54,53,20,55,54,12,55,20,12,56,55,12,57,56,12,58,57,12,59,58,12,60,59,12,61,60,1,11,9,11,61,12,62,1,0,1,61,11,61,1,62],width:31.154930591583252},6:{positions:[23.73046875,51.92578125,23.73046875,51.92578125,26.35400390625,51.7763671875,28.951171875,51.328125,31.31103515625,50.6513671875,33.22265625,49.81640625,33.22265625,49.81640625,31.74609375,44.5078125,29.98388671875,45.30322265625,28.142578125,45.931640625,26.09912109375,46.34033203125,23.73046875,46.4765625,23.73046875,46.4765625,20.900758743286133,46.15056610107422,18.386611938476562,45.17258071899414,16.18802833557129,43.5426025390625,14.465424537658691,41.076210021972656,13.138894081115723,38.50679397583008,12.208439826965332,35.8343505859375,11.67405891418457,33.05888366699219,11.53125,30.62109375,11.53125,29.8125,13.904020309448242,31.542055130004883,16.591995239257812,32.85417938232422,19.408527374267578,33.66147994995117,22.372249603271484,33.98829650878906,22.921875,33.99609375,25.913307189941406,33.7476806640625,28.614002227783203,33.002437591552734,31.023962020874023,31.7603702545166,33.143184661865234,30.021472930908203,34.91127014160156,27.67707633972168,36.273963928222656,25.183759689331055,37.23126983642578,22.541519165039062,37.783180236816406,19.750356674194336,37.93359375,17.2265625,37.749637603759766,14.08007526397705,37.19777297973633,11.182336807250977,36.27799606323242,8.533347129821777,34.99031066894531,6.1331071853637695,32.81218719482422,3.8232548236846924,30.5310001373291,1.9849358797073364,28.146751403808594,.6181499361991882,25.65943717956543,-.2771027684211731,23.069063186645508,-.7008222937583923,22.0078125,-.73828125,19.07733154296875,-.5163767337799072,16.358732223510742,.14933684468269348,13.852017402648926,1.2588595151901245,11.557185173034668,2.8121912479400635,9.638298988342285,5.0737128257751465,8.030496597290039,7.450648784637451,6.733777046203613,9.942998886108398,5.748140335083008,12.550763130187988,5.073586463928223,15.273941993713379,4.710115432739258,18.112533569335938,4.640625,20.07421875,4.640625,29.84765625,4.791966915130615,33.015262603759766,5.245992183685303,35.97719955444336,6.0027008056640625,38.73346710205078,7.062093257904053,41.28406524658203,8.424168586730957,43.62899398803711,10.08892822265625,45.768253326416016,12.196839332580566,47.81597900390625,14.478988647460938,49.4511604309082,16.93537712097168,50.673797607421875,19.56600570678711,51.483890533447266,22.370872497558594,51.881439208984375,21.375,28.828125,21.375,28.828125,18.29266357421875,28.514667510986328,15.669046401977539,27.57429313659668,13.216089248657227,25.754901885986328,11.53125,23.5546875,11.53125,23.5546875,11.53125,19.40625,11.72034740447998,16.05575180053711,12.287637710571289,13.114592552185059,13.233122825622559,10.582772254943848,15.422850608825684,7.959404945373535,17.641748428344727,6.1007585525512695,19.889812469482422,5.006833076477051,22.0078125,4.67578125,24.755970001220703,5.117502212524414,27.043012619018555,6.4426655769348145,28.768321990966797,9.139809608459473,30.00419807434082,11.825053215026855,30.75064468383789,14.498397827148438,31.007658004760742,17.15984344482422,31.0078125,17.2265625,30.737268447875977,20.334959030151367,29.925634384155273,23.062726974487305,28.57291030883789,25.409866333007812,26.557069778442383,27.331403732299805,24.112672805786133,28.470571517944336],indices:[2,4,3,21,23,22,23,25,24,25,27,26,27,29,28,29,31,30,31,33,32,33,35,34,35,37,36,37,39,38,39,41,40,41,43,42,43,45,44,45,47,46,47,49,48,49,51,50,51,53,52,53,55,54,55,57,56,57,59,58,59,61,60,61,63,62,63,65,64,65,67,66,21,25,23,25,29,27,29,33,31,33,37,35,37,41,39,41,45,43,45,49,47,49,53,51,53,57,55,57,61,59,61,65,63,65,68,67,21,29,25,29,37,33,37,45,41,45,53,49,57,65,61,57,68,65,73,57,74,68,2,1,2,6,4,6,8,7,53,75,57,72,57,73,68,6,2,6,9,8,53,76,75,71,57,72,68,9,6,53,77,76,70,57,71,68,10,9,53,78,77,68,12,10,53,79,78,68,13,12,45,79,53,68,14,13,45,80,79,68,15,14,45,81,80,57,15,68,45,82,81,57,16,15,45,83,82,57,17,16,45,84,83,57,18,17,37,84,45,57,19,18,37,85,84,57,20,19,37,86,85,57,21,20,37,87,86,70,21,57,37,88,87,70,29,21,37,89,88,95,29,70,37,90,89,94,29,95,29,90,37,93,29,94,29,91,90,92,29,93,29,92,91],width:33.29296875},7:{positions:[37.3359375,51.1875,37.3359375,45.73828125,35.06884002685547,42.96620559692383,32.99747848510742,40.27573776245117,31.121856689453125,37.666873931884766,29.441970825195312,35.13961410522461,27.957822799682617,32.6939582824707,26.669410705566406,30.329906463623047,25.576738357543945,28.047460556030273,24.585519790649414,25.34857940673828,23.679515838623047,22.592660903930664,22.85872459411621,19.779708862304688,22.123149871826172,16.909719467163086,21.47278594970703,13.982696533203125,20.907638549804688,10.998638153076172,20.427703857421875,7.957544803619385,20.109375,5.51953125,19.546875,0,12.62109375,0,13.18359375,5.51953125,13.624162673950195,8.682632446289062,14.162458419799805,11.7554292678833,14.798481941223145,14.737921714782715,15.532232284545898,17.630107879638672,16.363710403442383,20.431991577148438,17.29291534423828,23.14356803894043,18.319847106933594,25.764841079711914,19.59184455871582,28.50404167175293,20.94556999206543,31.184146881103516,22.381019592285156,33.80515670776367,23.898197174072266,36.367069244384766,25.497098922729492,38.86988830566406,27.17772674560547,41.31361389160156,28.940080642700195,43.6982421875,30.55078125,45.73828125,2.70703125,45.73828125,2.70703125,51.1875],indices:[36,1,0,16,18,17,18,20,19,20,22,21,22,24,23,24,26,25,26,28,27,28,30,29,30,32,31,32,34,33,34,36,35,15,18,16,18,22,20,22,26,24,26,30,28,30,34,32,34,1,36,14,18,15,18,26,22,26,34,30,34,2,1,13,18,14,18,34,26,34,3,2,12,18,13,34,4,3,11,18,12,34,5,4,10,18,11,34,6,5,9,18,10,34,7,6,8,18,9,34,8,7,8,34,18],width:34.62890625},8:{positions:[35.5078125,37.828125,35.5078125,37.828125,35.171749114990234,34.87995147705078,34.16355895996094,32.23108673095703,32.111854553222656,29.74087905883789,29.926387786865234,27.833354949951172,27.60715675354004,26.50851058959961,27.17578125,26.33203125,29.95149040222168,25.094419479370117,32.32651901245117,23.460092544555664,34.43555450439453,20.72713279724121,35.900413513183594,18.128986358642578,36.721099853515625,15.665656089782715,36.9140625,13.8515625,36.669769287109375,10.764041900634766,35.936893463134766,8.031349182128906,34.71543502807617,5.653482913970947,33.00539016723633,3.630444288253784,30.672534942626953,1.9876797199249268,28.159135818481445,.7305349111557007,25.465194702148438,-.14099019765853882,22.590709686279297,-.6268956065177917,20.28515625,-.73828125,17.073928833007812,-.5518752932548523,14.154998779296875,.007342617027461529,11.52836799621582,.9393724799156189,9.194035530090332,2.2442142963409424,7.087226867675781,4.249664306640625,5.474374294281006,6.483748912811279,4.355478763580322,8.946466445922852,3.730539560317993,11.637818336486816,3.5859375,13.8515625,3.9077277183532715,16.76708984375,4.873098373413086,19.430402755737305,6.983664512634277,21.999971389770508,9.1663179397583,24.03520965576172,11.421058654785156,25.536113739013672,13.21875,26.33203125,10.521642684936523,27.690086364746094,8.310940742492676,29.498327255249023,6.554880142211914,32.2148551940918,5.462681293487549,34.86786651611328,5.034343719482422,37.45735549926758,5.02734375,37.828125,5.274991512298584,40.936737060546875,6.0179338455200195,43.679622650146484,7.256171703338623,46.056785583496094,8.989704132080078,48.0682258605957,11.195730209350586,49.67716598510742,13.679861068725586,50.85453796386719,16.442096710205078,51.60033416748047,19.482437133789062,51.914554595947266,20.21484375,51.92578125,23.33972930908203,51.71018600463867,26.17371940612793,51.06340789794922,28.716812133789062,49.98543930053711,30.96900749206543,48.476287841796875,32.855812072753906,46.481101989746094,34.23870849609375,44.16929626464844,35.11769485473633,41.54087829589844,35.49277114868164,38.5958366394043,30.0234375,13.9921875,30.0234375,13.9921875,29.64218521118164,16.91078758239746,28.498428344726562,19.414352416992188,26.08045768737793,21.54735565185547,23.622779846191406,22.934738159179688,21.125396728515625,23.576496124267578,20.21484375,23.625,17.24955177307129,23.25731658935547,14.728343963623047,22.15427017211914,12.576437950134277,19.76153564453125,11.184748649597168,17.31914710998535,10.553275108337402,14.827102661132812,10.51171875,13.9921875,10.887092590332031,10.988458633422852,12.013215065002441,8.51321792602539,14.405669212341309,6.533318519592285,16.906885147094727,5.263905048370361,19.516860961914062,4.704977512359619,20.28515625,4.67578125,23.29867172241211,5.026233196258545,25.858081817626953,6.077588081359863,28.013742446899414,8.338984489440918,29.392438888549805,10.737264633178711,29.994173049926758,13.27242660522461,28.58203125,37.6875,28.58203125,37.6875,28.174694061279297,40.610374450683594,26.952680587768555,43.08668899536133,24.61227035522461,45.108375549316406,22.137697219848633,46.228328704833984,20.21484375,46.4765625,17.313322067260742,46.03565979003906,14.926724433898926,44.71294403076172,13.154691696166992,42.36640930175781,12.172061920166016,39.77567672729492,11.953125,37.6875,12.353304862976074,34.70274353027344,13.553845405578613,32.25563430786133,15.877814292907715,30.335918426513672,18.399682998657227,29.288454055786133,20.28515625,29.07421875,23.187891006469727,29.511512756347656,25.59459114074707,30.82339859008789,27.39614486694336,33.1435661315918,28.379940032958984,35.7212028503418],indices:[96,43,97,43,45,44,45,47,46,47,49,48,49,51,50,51,53,52,53,55,54,55,57,56,57,59,58,59,1,60,1,3,2,3,5,4,5,7,6,7,9,8,9,11,10,11,13,12,13,15,14,15,17,16,17,19,18,19,21,20,21,23,22,23,25,24,25,27,26,27,29,28,29,31,30,31,75,74,73,31,74,31,33,32,33,35,34,35,37,36,37,39,38,39,41,40,41,43,42,43,98,97,95,43,96,43,47,45,47,51,49,51,55,53,55,59,57,59,3,1,3,7,5,7,11,9,11,15,13,15,19,17,19,23,21,23,27,25,27,31,29,31,76,75,72,31,73,31,35,33,37,41,39,41,98,43,94,43,95,43,51,47,51,59,55,59,7,3,7,15,11,15,23,19,23,31,27,31,77,76,71,31,72,31,37,35,37,98,41,94,51,43,23,77,31,70,31,71,37,99,98,93,51,94,23,78,77,70,37,31,37,100,99,92,51,93,23,79,78,69,37,70,37,101,100,91,51,92,23,80,79,68,37,69,37,102,101,90,51,91,23,81,80,67,37,68,37,103,102,89,51,90,15,81,23,66,37,67,89,59,51,15,82,81,66,103,37,88,59,89,15,83,82,65,103,66,87,59,88,15,84,83,64,103,65,106,59,87,15,85,84,64,104,103,105,59,106,15,62,85,63,104,64,104,59,105,15,63,62,104,7,59,7,63,15,63,7,104],width:33.328125},9:{positions:[17.96484375,4.67578125,17.96484375,4.67578125,20.832611083984375,5.023819923400879,23.333181381225586,6.067935943603516,25.466554641723633,7.80812931060791,26.91764259338379,9.993691444396973,28.0020751953125,12.483912467956543,28.7198543548584,15.278792381286621,29.070980072021484,18.378332138061523,29.109375,19.8984375,29.109375,22.21875,27.17138671875,20.02587890625,24.802734375,18.439453125,22.097061157226562,17.482282638549805,19.10603904724121,17.156333923339844,19.0546875,17.15625,15.962648391723633,17.374753952026367,13.161947250366211,18.030263900756836,10.65258502960205,19.12278175354004,8.43455982208252,20.652305603027344,6.556478023529053,22.870075225830078,5.067807197570801,25.25521469116211,3.968548536300659,27.80772590637207,3.2587015628814697,30.527606964111328,2.9382660388946533,33.414859771728516,2.91796875,34.3828125,3.1171858310699463,37.45964050292969,3.7148373126983643,40.29710006713867,4.710922718048096,42.89520263671875,6.105442523956299,45.253936767578125,8.45276927947998,47.5704231262207,10.840720176696777,49.39479446411133,13.269293785095215,50.72705078125,15.738492012023926,51.56719207763672,18.248313903808594,51.915218353271484,18.7734375,51.92578125,21.87710189819336,51.72084045410156,24.703197479248047,51.10601806640625,27.25172233581543,50.0813102722168,29.52267837524414,48.646724700927734,31.40683364868164,46.456634521484375,32.97002410888672,44.11880111694336,34.212249755859375,41.63322067260742,35.133514404296875,38.99989700317383,35.73381423950195,36.21882629394531,36.01314926147461,33.29001235961914,36.03515625,32.16796875,36.03515625,19.96875,35.885276794433594,16.642547607421875,35.435638427734375,13.59611988067627,34.686241149902344,10.8294677734375,33.6370849609375,8.34259033203125,32.28816604614258,6.135488033294678,30.066654205322266,3.964623212814331,27.738887786865234,2.2044835090637207,25.30486488342285,.8550683259963989,22.764589309692383,-.08362190425395966,20.118059158325195,-.6115872859954834,17.96484375,-.73828125,15.23583984375,-.61083984375,12.462890625,-.228515625,9.81298828125,.41748046875,7.453125,1.3359375,7.453125,1.3359375,8.5078125,6.64453125,10.62158203125,5.71728515625,12.814453125,5.115234375,15.21826171875,4.78564453125,17.96484375,4.67578125,19.0546875,22.5703125,19.0546875,22.5703125,22.15691566467285,22.88543701171875,24.769695281982422,23.830808639526367,27.256725311279297,25.793380737304688,28.883312225341797,27.970977783203125,29.109375,28.44140625,29.109375,32.87109375,28.917926788330078,36.28435516357422,28.34358024597168,39.213134765625,27.386337280273438,41.657432556152344,25.37175941467285,43.94849395751953,23.127288818359375,45.50687026977539,20.652921676635742,46.33256530761719,18.984375,46.4765625,16.33090591430664,46.012935638427734,13.984920501708984,44.62206268310547,12.139910697937012,42.07911682128906,10.835031509399414,39.48687744140625,10.070281982421875,36.84534454345703,9.84375,34.3828125,10.09748363494873,31.21339988708496,10.858684539794922,28.454280853271484,12.127352714538574,26.105453491210938,14.162574768066406,24.085222244262695,16.57485580444336,22.90838050842285],indices:[60,63,61,63,65,64,10,12,11,12,14,13,14,16,15,16,18,17,18,20,19,20,22,21,22,24,23,24,89,25,88,25,89,25,27,26,27,29,28,29,31,30,31,33,32,33,35,34,35,37,36,37,39,38,39,41,40,41,43,42,43,45,44,45,47,46,47,49,48,49,51,50,51,53,52,53,55,54,55,57,56,57,59,58,59,63,60,63,66,65,10,14,12,14,18,16,18,22,20,22,89,24,87,25,88,25,29,27,29,33,31,33,37,35,37,41,39,41,45,43,45,49,47,49,53,51,53,57,55,57,63,59,63,67,66,10,18,14,18,89,22,86,25,87,25,33,29,33,41,37,41,49,45,49,57,53,57,67,63,18,90,89,85,25,86,57,1,67,18,91,90,85,33,25,57,2,1,18,92,91,84,33,85,57,3,2,18,93,92,83,33,84,49,3,57,18,94,93,82,33,83,49,4,3,18,70,94,81,33,82,49,5,4,10,70,18,80,33,81,49,6,5,10,71,70,80,41,33,49,7,6,10,72,71,79,41,80,41,7,49,10,73,72,78,41,79,41,8,7,10,74,73,77,41,78,41,9,8,10,75,74,76,41,77,41,10,9,75,41,76,41,75,10],width:33.1171875},".":{positions:[12.5859375,7.1015625,12.5859375,0,5.66015625,0,5.66015625,7.1015625],indices:[3,1,0,1,3,2],width:6.92578125},m:{positions:[5.02734375,38.0390625,11.21484375,38.0390625,11.70703125,33.046875,13.634581565856934,35.28191375732422,15.986680030822754,37.00302505493164,18.700471878051758,38.111698150634766,21.567134857177734,38.6696662902832,23.09765625,38.7421875,26.139192581176758,38.42292022705078,28.791221618652344,37.465118408203125,31.15591812133789,35.599586486816406,32.90284729003906,33.37240219116211,33.71484375,31.7109375,35.408084869384766,34.171592712402344,37.503177642822266,36.16951370239258,40.22900390625,37.6488037109375,42.961280822753906,38.50468063354492,45.3515625,38.7421875,48.32835006713867,38.446842193603516,50.9460334777832,37.5608024597168,53.204620361328125,36.084068298339844,54.8843879699707,33.86517333984375,56.19401931762695,31.434070587158203,57.133506774902344,28.79076385498047,57.70286178588867,25.93524932861328,57.90207290649414,22.867528915405273,57.90234375,22.74609375,57.90234375,0,50.9765625,0,50.9765625,22.81640625,50.74445724487305,26.319555282592773,50.04814529418945,29.033550262451172,47.956382751464844,31.33014678955078,45.659942626953125,32.691036224365234,43.27734375,33.1171875,40.4267463684082,32.6451530456543,38.09538650512695,31.229045867919922,36.33670425415039,28.815231323242188,35.26606750488281,26.190664291381836,34.9453125,24.43359375,34.9453125,24.15234375,34.9453125,0,27.984375,0,27.984375,22.81640625,27.73810386657715,26.2243709564209,26.99928855895996,28.921852111816406,24.89556121826172,31.278352737426758,22.623031616210938,32.67652893066406,20.28515625,33.1171875,17.40234375,32.7919921875,15.08203125,31.81640625,13.2802734375,30.251953125,11.953125,28.16015625,11.953125,28.16015625,11.953125,0,5.02734375,0],indices:[55,1,0,2,4,3,4,6,5,6,8,7,8,10,9,10,12,11,12,14,13,14,16,15,16,18,17,18,20,19,20,22,21,22,24,23,24,26,25,26,28,27,40,42,41,54,1,55,2,6,4,6,10,8,12,16,14,16,20,18,20,24,22,24,28,26,39,42,40,54,2,1,2,10,6,12,20,16,20,28,24,38,42,39,20,29,28,38,43,42,20,30,29,37,43,38,20,31,30,36,43,37,20,32,31,36,44,43,20,33,32,35,44,36,20,34,33,35,45,44,12,34,20,12,35,34,12,45,35,10,45,12,10,46,45,10,47,46,10,48,47,2,48,10,2,49,48,2,50,49,2,51,50,2,53,51,53,2,54],width:52.875},c:{positions:[20.49609375,4.67578125,20.49609375,4.67578125,23.36757469177246,5.087423801422119,25.919267654418945,6.322350978851318,28.055252075195312,8.557517051696777,29.08038330078125,10.95840835571289,29.1796875,12.0234375,35.40234375,12.0234375,35.47265625,11.8125,35.209197998046875,9.178794860839844,34.224666595458984,6.713964939117432,32.519065856933594,4.418010711669922,29.943574905395508,2.4374680519104004,27.361528396606445,.9345490336418152,24.772926330566406,-.0907462015748024,22.177766799926758,-.6384177803993225,20.49609375,-.73828125,17.386640548706055,-.5293084979057312,14.578433990478516,.09760986268520355,12.071474075317383,1.142473816871643,9.86575984954834,2.605283260345459,7.9612932205200195,4.4860382080078125,6.3618083000183105,6.765913009643555,5.107275009155273,9.241913795471191,4.197693824768066,11.914040565490723,3.633063793182373,14.782294273376465,3.4133858680725098,17.8466739654541,3.41015625,18.28125,3.41015625,19.7578125,3.5838754177093506,22.87480926513672,4.105032920837402,25.780019760131836,4.973628997802734,28.473445892333984,6.189663410186768,30.95508575439453,7.753136157989502,33.22494125366211,9.646564483642578,35.16857147216797,11.828062057495117,36.69178771972656,14.297628402709961,37.79460144042969,17.05526351928711,38.47700500488281,20.100967407226562,38.73899841308594,20.49609375,38.7421875,23.570213317871094,38.5140495300293,26.36119842529297,37.82963943481445,28.869049072265625,36.6889533996582,31.093765258789062,35.09199523925781,33.085479736328125,32.87481689453125,34.484825134277344,30.467679977416992,35.29180145263672,27.87058448791504,35.5078125,25.13671875,35.4375,24.92578125,29.1796875,24.92578125,28.72093391418457,27.737882614135742,27.34467315673828,30.163320541381836,24.98297119140625,32.04195022583008,22.43872833251953,33.074039459228516,20.49609375,33.29296875,17.510202407836914,32.94111633300781,15.082853317260742,31.88556480407715,13.214049339294434,30.12630844116211,11.89155101776123,27.541250228881836,10.979540824890137,24.808610916137695,10.478017807006836,21.928388595581055,10.37109375,19.7578125,10.37109375,18.28125,10.565627098083496,15.065240859985352,11.149227142333984,12.176401138305664,12.121894836425781,9.614731788635254,13.855029106140137,7.324370861053467,15.960027694702148,5.741883754730225,18.4368896484375,4.867271423339844],indices:[5,7,6,7,9,8,9,11,10,11,13,12,13,15,14,15,17,16,17,19,18,19,21,20,21,23,22,23,25,24,25,27,26,27,29,28,29,31,30,31,33,32,33,35,34,35,37,36,37,39,38,39,41,40,41,43,42,43,45,44,45,47,46,47,49,48,4,7,5,7,11,9,11,15,13,15,19,17,19,23,21,23,27,25,27,31,29,31,35,33,35,39,37,39,43,41,43,47,45,47,50,49,3,7,4,7,15,11,15,23,19,23,31,27,31,39,35,39,47,43,47,51,50,3,15,7,39,51,47,2,15,3,39,52,51,39,53,52,39,54,53,39,55,54,31,55,39,31,56,55,31,57,56,31,58,57,23,58,31,23,59,58,23,60,59,23,61,60,23,62,61,23,63,62,23,64,63,23,65,64,23,66,65,15,66,23,15,67,66,15,68,67,15,1,68,1,15,2],width:32.09765625},k:{positions:[28.828125,0,16.48828125,17.54296875,11.98828125,17.54296875,11.98828125,0,5.0625,0,5.0625,54.84375,11.98828125,54.84375,11.98828125,23.0625,16.41796875,23.0625,26.82421875,38.0390625,35.12109375,38.0390625,22.11328125,20.7421875,36.984375,0],indices:[12,1,0,2,4,3,4,6,5,8,10,9,11,1,12,4,7,6,8,11,10,11,2,1,2,7,4,7,11,8,11,7,2],width:31.921875},t:{positions:[0,0,30,0],indices:[0,2,1],width:30}," ":{width:16,positions:[],indices:[]}};function _Ot({text:t,size:e=1,zOffset:i=0}){const o=[],n=[];let r=0,a=0;const s=10;e/=100;for(const l of t){const c=LOt[l];if(!c)throw new Error("Unknown character: "+l);const d=a;for(let h=0;h<c.positions.length;h+=2)o.push(c.positions[h]*e+d,c.positions[h+1]*e,i);const u=r===0?0:r+1;for(const h of c.indices)n.push(h+u),r=Math.max(r,h+u);a+=(c.width+s)*e}return{positions:o,indices:n,primitive:"triangles"}}function jee(t,{content:e,size:i,matrix:o,offset:n=0}){const{material:r,origin:a,plugin:s}=t,{textSizeRatio:l,textBottomMarginRatio:c,xeokitSdk:d,viewer:u}=s,{Mesh:h,VBOGeometry:p,math:A}=d,{scene:f}=u,{primitive:m,positions:g,indices:y}=_Ot({text:e,size:i*l,zOffset:n});let v=g[0],w=g[0];for(let E=0;E<g.length;E+=3){const T=g[E];T<v&&(v=T),T>w&&(w=T)}const x=-(w-v)/2,k=A.mat4(),B=A.translationMat4v([x,i*c,0]);A.mulMat4(o,A.rotationMat4v(Math.PI,[0,1,0],A.mat4()),k),A.mulMat4(o,B),A.mulMat4(k,B);const P=new p(f,{primitive:m,positions:g,indices:y});return[new h(f,{geometry:P,material:r,pickable:!1,origin:a,matrix:o}),new h(f,{geometry:P,material:r,pickable:!1,origin:a,matrix:k})]}class FOt{constructor(e,i,o){this.plugin=e;const{viewer:n}=e;this.line=null,this.texts=null,this.length=0;const{math:r,worldToRTCPos:a,Node:s,PhongMaterial:l}=e.xeokitSdk,c=r.vec3(),d=r.vec3();a(i,d,c),this.material=new l(n.scene,{emissive:G1(e.defaultColor)}),this.node=new s(n.scene,{pickable:!1,origin:d,children:[]}),this.origin=d,this.p1=c,this.normal=o}move(e,i){const{arrowSizeRatio:o,offsetRatio:n,xeokitSdk:r,viewer:a}=this.plugin,{math:s,Mesh:l,VBOGeometry:c}=r,{scene:d}=a,u=this.p1;this.p2=s.subVec3(e,this.origin),this.node.removeChildren(),this.line?.destroy();const h=s.subVec3(e,u,s.vec3());if(h.every(Ce=>Ce===0))return;const p=s.normalizeVec3(h,s.vec3()),A=s.mulVec3Scalar(p,-1,s.vec3()),f=s.lenVec3(h);this.length=f;const m=n*f;let g=0;const y=s.mulVec3Scalar(h,.5,s.vec3()),v=s.addVec3(u,y,s.vec3());let w=s.normalizeVec3(s.cross3Vec3(i,s.normalizeVec3(h,s.vec3()),s.vec3()));const x=s.dotVec3(i,this.normal)>.999,k=s.vec3([0,1,0]),B=s.dotVec3(p,k);if(x){const Ce=Math.abs(B)<.01;g=m;let Le=null;if(Ce){const{look:Fe,up:ve,eye:me}=d.camera,we=s.normalizeVec3(s.subVec3(Fe,me,s.vec3())),Re=s.cross3Vec3(we,ve);Le=s.dotVec3(p,Re)}else{const Fe=s.cross3Vec3(k,i,s.vec3());Le=s.dotVec3(p,Fe)}Le<0&&(w=s.negateVec3(w),g=-g)}else if(Math.abs(B)>.99){const{look:Ce,eye:Le}=d.camera,Fe=s.normalizeVec3(s.subVec3(Ce,Le,s.vec3()));w=s.normalizeVec3(s.cross3Vec3(p,Fe,s.vec3())),i=s.normalizeVec3(s.cross3Vec3(w,p,s.vec3()))}else i=s.normalizeVec3(s.cross3Vec3(k,p,s.vec3())),w=s.normalizeVec3(s.cross3Vec3(p,i,s.vec3())),s.dotVec3(w,k)<0&&(w=s.negateVec3(w));const P=s.negateVec3(w,s.vec3()),E=s.mulVec3Scalar(w,f*o,s.vec3()),T=s.mulVec3Scalar(P,f*o,s.vec3()),S=s.addVec3(u,E,s.vec3()),R=s.addVec3(u,T,s.vec3()),F=s.addVec3(e,E,s.vec3()),U=s.addVec3(e,T,s.vec3()),q=s.mulVec3Scalar(s.normalizeVec3(s.addVec3(w,p,s.vec3())),f*o*Math.SQRT2),V=s.addVec3(u,q,s.vec3()),W=s.mulVec3Scalar(s.normalizeVec3(s.addVec3(P,p,s.vec3())),f*o*Math.SQRT2),Y=s.addVec3(u,W,s.vec3()),$=s.mulVec3Scalar(s.normalizeVec3(s.addVec3(w,A,s.vec3())),f*o*Math.SQRT2),fe=s.addVec3(e,$,s.vec3()),Me=s.mulVec3Scalar(s.normalizeVec3(s.addVec3(P,A,s.vec3())),f*o*Math.SQRT2),Se=s.addVec3(e,Me,s.vec3()),qe=s.translationMat4v(s.mulVec3Scalar(i,m,s.vec3()));this.line=new l(a.scene,{geometry:new c(a.scene,{primitive:"lines",positions:[...u,...e,...S,...R,...F,...U,...V,...Y,...fe,...Se],indices:[0,1,0,2,0,3,0,6,0,7,1,4,1,5,1,8,1,9]}),material:this.material,matrix:qe,pickable:!1,origin:this.origin}),this.node.addChild(this.line),this.texts?.forEach(Ce=>Ce.destroy());const Qe=s.mat4([...p,0,...w,0,...i,0,...v,1]);this.texts=this._makeTexts(f.toFixed(2)+" m",f,Qe,g),this.texts.forEach(Ce=>this.node.addChild(Ce))}_makeTexts(e,i,o,n=0){return jee(this,{content:e,size:i,matrix:o,offset:n})}destroy(){this.node.destroy(),this.line?.destroy(),this.texts?.forEach(e=>e.destroy()),this.plugin.measurements=this.plugin.measurements.filter(e=>e!==this)}get visible(){return this.node.visible}set visible(e){this.node.visible=e}get color(){return Oee(this.material.emissive)}set color(e=this.plugin.defaultColor){this.material.emissive=G1(e)}}class Vee{constructor(e,i,o={}){this.viewer=e,this.xeokitSdk=i,this.arrowSizeRatio=o.arrowSizeRatio??.04,this.textSizeRatio=o.textSizeRatio??.1,this.textBottomMarginRatio=o.textBottomMarginRatio??.02,this.offsetRatio=o.offsetRatio??.003,this.snapPickRadius=o.snapPickRadius??15,this.defaultColor=o.defaultColor??"#ffffff";const n=document.createElement("img"),r=e.scene.canvas.canvas;r.parentNode.insertBefore(n,r),n.style.width="28px",n.style.height="28px",n.style.position="absolute",n.style.pointerEvents="none",n.style.transform="translate(-50%, -50%)",n.style.display="none",this.imgElement=n,this.measurements=[],this.measurementEndCallbackId=0,this.measurementEndCallbacks={},this.control=new OOt(this)}on(e,i){if(e==="measurementEnd")return this.measurementEndCallbacks[this.measurementEndCallbackId++]=i,this.measurementEndCallbackId}off(e){this.measurementEndCallbacks[e]=null}}class OOt{constructor(e){this.plugin=e,this.currentMeasurement=null,this.lastPosition=null,this.mouseDown=!1,this.dragging=!1,this.activated=!1}_updateCursor(e){const{imgElement:i,viewer:o}=this.plugin,{scene:n}=o;n.canvas.canvas.style.cursor=`url("${ROt}") 16 16, auto`;const r=n.pick({canvasPos:e,snapRadius:this.plugin.snapPickRadius,snapToEdge:!0,snapToVertex:!0});if(r?.snappedWorldPos||r?.worldPos){if(r.snappedCanvasPos)i.style.left=`${r.snappedCanvasPos[0]}px`,i.style.top=`${r.snappedCanvasPos[1]}px`,i.src=r.snapType==="vertex"?SOt:IOt;else{const a=r.canvasPos;i.style.left=`${a[0]}px`,i.style.top=`${a[1]}px`,i.src=TOt}this.lastPosition=r.snappedWorldPos??r.worldPos,this.lastPosition.worldNormal=r.snappedWorldNormal??r.worldNormal}else i.style.left=`${e[0]}px`,i.style.top=`${e[1]}px`,i.src=DOt,this.lastPosition=null}_onMouseMove(e){this.mouseDown&&(this.dragging=!0),e.preventDefault(),this._updateCursor([e.offsetX,e.offsetY]),this.lastPosition&&this.currentMeasurement?.move(this.lastPosition,this.lastPosition.worldNormal)}_onMouseDown(){this.mouseDown=!0}_onMouseUp(){this.mouseDown=!1;const e=this.dragging;this.dragging=!1,!e&&this.lastPosition&&(this.currentMeasurement?(this.plugin.measurements.push(this.currentMeasurement),Object.values(this.plugin.measurementEndCallbacks).forEach(i=>i?.(this.currentMeasurement)),this.currentMeasurement=null):this.currentMeasurement=new FOt(this.plugin,this.lastPosition,this.lastPosition.worldNormal))}activate(){if(this.activated)return;const{canvas:e}=this.plugin.viewer.scene.canvas;this.plugin.imgElement.style.display="block";const i=this._onMouseMove.bind(this),o=this._onMouseDown.bind(this),n=this._onMouseUp.bind(this);e.addEventListener("mousemove",i),e.addEventListener("mousedown",o),document.addEventListener("mouseup",n),this._unsubscribe=()=>{e.removeEventListener("mousemove",i),e.removeEventListener("mousedown",o),document.removeEventListener("mouseup",n)},this.activated=!0}deactivate(){this.activated&&(this._unsubscribe?.(),this.currentMeasurement?.destroy(),this.currentMeasurement=null,this.lastPosition=null,this.plugin.imgElement.style.display="none",this.activated=!1)}}class UOt{constructor(e,i){this.plugin=e;const{xeokitSdk:o,viewer:n}=e,{Mesh:r,ReadableGeometry:a,buildSphereGeometry:s,PhongMaterial:l,Node:c,math:d,worldToRTCPos:u}=o,h=d.vec3(),p=d.vec3();this._length=0;const{entity:A,worldPos:f}=i;u(f,p,h);const m=new l(n.scene,{emissive:G1(e.defaultColor),diffuse:[0,0,0]}),g=(k=!0)=>new r(n.scene,{geometry:new a(n.scene,s({radius:.03})),material:m,pickable:!1,visible:k,origin:p}),y=g(),v=g(!1),w=new r(n.scene,{geometry:new a(n.scene,{primitive:"lines",positions:[0,0,0,0,0,0],indices:[0,1]}),material:m,pickable:!1,visible:!1,origin:p}),x=new c(n.scene,{pickable:!1,visible:!0,position:h,origin:p,children:[y,w,v]});this.origin=p,this.modelId=A.model.id,this.node=x,this.toSphere=v,this.fromSphere=y,this.line=w,this.material=m}show(e){const{node:i,fromSphere:o,toSphere:n,line:r,texts:a,plugin:s}=this,{math:l}=s.xeokitSdk;i.position=l.subVec3(e.worldPos,i.origin,l.vec3()),i.visible=!0;const{viewer:c}=s,d=c.scene.pick({pickSurface:!0,origin:e.worldPos,direction:e.worldNormal});if(a&&(a.forEach(u=>u.destroy()),this.texts=null),d){n.visible=!0,r.visible=!0,n.position=l.subVec3(d.worldPos,n.origin,l.vec3()),n.position=l.subVec3(n.position,i.position,l.vec3()),r.position=l.vec3().set(i.position),r.geometry.positions=[0,0,0,...n.position];const u=l.lenVec3(n.position);this._length=u;const h=o.position,p=n.position,A=l.subVec3(p,h,l.vec3()),f=l.normalizeVec3(A,l.vec3()),m=l.mulVec3Scalar(A,.5,l.vec3()),g=l.addVec3(h,m,l.vec3()),y=[0,1,0],v=l.dotVec3(f,y),w=Math.abs(v)>.9;let x;if(w){const k=l.normalizeVec3(l.subVec3(c.scene.camera.eye,c.scene.camera.look,l.vec3()),l.vec3()),B=l.normalizeVec3(l.cross3Vec3(k,f,l.vec3()),l.vec3()),P=l.normalizeVec3(l.cross3Vec3(B,f,l.vec3()),l.vec3());x=l.mat4([...f,0,...B,0,...P,0,...g,1])}else{const k=l.normalizeVec3(l.cross3Vec3(y,f,l.vec3()),l.vec3()),B=l.normalizeVec3(l.cross3Vec3(f,k,l.vec3()),l.vec3());x=l.mat4([...f,0,...B,0,...k,0,...g,1])}this.texts=this._makeTexts(u.toFixed(2)+" m",u,x),this.texts.forEach(k=>i.addChild(k))}else n.visible=!1,r.visible=!1,this._length=0}hide(){this.node.visible=!1}destroy(){this.node.destroy(),this.line.destroy(),this.fromSphere.destroy(),this.toSphere.destroy(),this.texts?.forEach(e=>e.destroy())}set length(e){this._length=e}get length(){return this.visible?this._length:0}get visible(){return this.node.visible===!0}set visible(e){this.node.visible=!!e}get color(){return Oee(this.material.emissive)}set color(e=this.plugin.defaultColor){this.material.emissive=G1(e)}_makeTexts(e,i,o){return jee(this,{content:e,size:i,matrix:o})}}class Hee{constructor(e,i,o={}){this.viewer=e,this.xeokitSdk=i,this.textSizeRatio=o.textSizeRatio??.1,this.textBottomMarginRatio=o.textBottomMarginRatio??.01,this.defaultColor=o.defaultColor??"#ffffff",this.measurements=[],this.measurementEndCallbackId=0,this.measurementEndCallbacks={},this.control=new NOt(this)}on(e,i){if(e==="measurementEnd")return this.measurementEndCallbacks[this.measurementEndCallbackId++]=i,this.measurementEndCallbackId}off(e){this.measurementEndCallbacks[e]=null}}class NOt{constructor(e){this.plugin=e,this.currentMeasure=null,this.pickedSpaceMeasureSubscription=null,this.hitHelperMouseMoveSubscription=null}activate(){const{plugin:e}=this,{viewer:i}=e;this.pickedSpaceMeasureSubscription=i.scene.input.on("mouseclicked",()=>{if(!this.currentMeasure?.length)return;const o=this.currentMeasure;this.currentMeasure=null,Object.values(this.plugin.measurementEndCallbacks).forEach(n=>n(o))}),this.hitHelperMouseMoveSubscription=i.scene.input.on("mousemove",o=>{const n=i.scene.pick({canvasPos:o,pickSurface:!0});n?.entity?.model&&(n?((!this.currentMeasure||this.currentMeasure.modelId!==n.entity.model.id)&&(this.currentMeasure?.destroy(),this.currentMeasure=new UOt(this.plugin,n)),this.currentMeasure.show(n)):this.currentMeasure?.hide())})}deactivate(){const{viewer:e}=this.plugin;this.currentMeasure?.destroy(),this.currentMeasure=null,e.scene.input.off(this.pickedSpaceMeasureSubscription),e.scene.input.off(this.hitHelperMouseMoveSubscription)}}const jOt=`onmessage = async event => {
1384
+ }`}function GX(t,e=!0,i){const o=i||new Set;if(t){if(KX(t))o.add(t);else if(KX(t.buffer))o.add(t.buffer);else if(!ArrayBuffer.isView(t)&&e&&typeof t=="object")for(const n in t)GX(t[n],e,o)}return i===void 0?Array.from(o):[]}function KX(t){return t?t instanceof ArrayBuffer||typeof MessagePort<"u"&&t instanceof MessagePort||typeof ImageBitmap<"u"&&t instanceof ImageBitmap||typeof OffscreenCanvas<"u"&&t instanceof OffscreenCanvas:!1}const LI=()=>{};class _I{name;source;url;terminated=!1;worker;onMessage;onError;_loadableURL="";static isSupported(){return typeof Worker<"u"&&qa||typeof DI<"u"&&!qa}constructor(e){const{name:i,source:o,url:n}=e;Ac(o||n),this.name=i,this.source=o,this.url=n,this.onMessage=LI,this.onError=r=>console.log(r),this.worker=qa?this._createBrowserWorker():this._createNodeWorker()}destroy(){this.onMessage=LI,this.onError=LI,this.worker.terminate(),this.terminated=!0}get isRunning(){return!!this.onMessage}postMessage(e,i){i=i||GX(e),this.worker.postMessage(e,i)}_getErrorFromErrorEvent(e){let i="Failed to load ";return i+=`worker ${this.name} from ${this.url}. `,e.message&&(i+=`${e.message} in `),e.lineno&&(i+=`:${e.lineno}:${e.colno}`),new Error(i)}_createBrowserWorker(){this._loadableURL=LPt({source:this.source,url:this.url});const e=new Worker(this._loadableURL,{name:this.name});return e.onmessage=i=>{i.data?this.onMessage(i.data):this.onError(new Error("No data received"))},e.onerror=i=>{this.onError(this._getErrorFromErrorEvent(i)),this.terminated=!0},e.onmessageerror=i=>console.error(i),e}_createNodeWorker(){let e;if(this.url){const i=this.url.includes(":/")||this.url.startsWith("/")?this.url:`./${this.url}`;e=new DI(i,{eval:!1})}else if(this.source)e=new DI(this.source,{eval:!0});else throw new Error("no worker");return e.on("message",i=>{this.onMessage(i)}),e.on("error",i=>{this.onError(i)}),e.on("exit",i=>{}),e}}class OPt{name="unnamed";source;url;maxConcurrency=1;maxMobileConcurrency=1;onDebug=()=>{};reuseWorkers=!0;props={};jobQueue=[];idleQueue=[];count=0;isDestroyed=!1;static isSupported(){return _I.isSupported()}constructor(e){this.source=e.source,this.url=e.url,this.setProps(e)}destroy(){this.idleQueue.forEach(e=>e.destroy()),this.isDestroyed=!0}setProps(e){this.props={...this.props,...e},e.name!==void 0&&(this.name=e.name),e.maxConcurrency!==void 0&&(this.maxConcurrency=e.maxConcurrency),e.maxMobileConcurrency!==void 0&&(this.maxMobileConcurrency=e.maxMobileConcurrency),e.reuseWorkers!==void 0&&(this.reuseWorkers=e.reuseWorkers),e.onDebug!==void 0&&(this.onDebug=e.onDebug)}async startJob(e,i=(n,r,a)=>n.done(a),o=(n,r)=>n.error(r)){const n=new Promise(r=>(this.jobQueue.push({name:e,onMessage:i,onError:o,onStart:r}),this));return this._startQueuedJob(),await n}async _startQueuedJob(){if(!this.jobQueue.length)return;const e=this._getAvailableWorker();if(!e)return;const i=this.jobQueue.shift();if(i){this.onDebug({message:"Starting job",name:i.name,workerThread:e,backlog:this.jobQueue.length});const o=new RPt(i.name,e);e.onMessage=n=>i.onMessage(o,n.type,n.payload),e.onError=n=>i.onError(o,n),i.onStart(o);try{await o.result}catch(n){console.error(`Worker exception: ${n}`)}finally{this.returnWorkerToQueue(e)}}}returnWorkerToQueue(e){!qa||this.isDestroyed||!this.reuseWorkers||this.count>this._getMaxConcurrency()?(e.destroy(),this.count--):this.idleQueue.push(e),this.isDestroyed||this._startQueuedJob()}_getAvailableWorker(){if(this.idleQueue.length>0)return this.idleQueue.shift()||null;if(this.count<this._getMaxConcurrency()){this.count++;const e=`${this.name.toLowerCase()} (#${this.count} of ${this.maxConcurrency})`;return new _I({name:e,source:this.source,url:this.url})}return null}_getMaxConcurrency(){return DPt?this.maxMobileConcurrency:this.maxConcurrency}}const UPt={maxConcurrency:3,maxMobileConcurrency:1,reuseWorkers:!0,onDebug:()=>{}};class hu{props;workerPools=new Map;static _workerFarm;static isSupported(){return _I.isSupported()}static getWorkerFarm(e={}){return hu._workerFarm=hu._workerFarm||new hu({}),hu._workerFarm.setProps(e),hu._workerFarm}constructor(e){this.props={...UPt},this.setProps(e),this.workerPools=new Map}destroy(){for(const e of this.workerPools.values())e.destroy();this.workerPools=new Map}setProps(e){this.props={...this.props,...e};for(const i of this.workerPools.values())i.setProps(this._getWorkerPoolProps())}getWorkerPool(e){const{name:i,source:o,url:n}=e;let r=this.workerPools.get(i);return r||(r=new OPt({name:i,source:o,url:n}),r.setProps(this._getWorkerPoolProps()),this.workerPools.set(i,r)),r}_getWorkerPoolProps(){return{maxConcurrency:this.props.maxConcurrency,maxMobileConcurrency:this.props.maxMobileConcurrency,reuseWorkers:this.props.reuseWorkers,onDebug:this.props.onDebug}}}function NPt(t,e={}){const i=e[t.id]||{},o=qa?`${t.id}-worker.js`:`${t.id}-worker-node.js`;let n=i.workerUrl;if(!n&&t.id==="compression"&&(n=e.workerUrl),e._workerType==="test"&&(qa?n=`modules/${t.module}/dist/${o}`:n=`modules/${t.module}/src/workers/${t.id}-worker-node.ts`),!n){let r=t.version;r==="latest"&&(r=SPt);const a=r?`@${r}`:"";n=`https://unpkg.com/@loaders.gl/${t.module}${a}/dist/${o}`}return Ac(n),n}function jPt(t,e=zX){Ac(t,"no worker provided");const i=t.version;return!(!e||!i)}const FI={};async function vh(t,e=null,i={},o=null){return e&&(t=VPt(t,e,i,o)),FI[t]=FI[t]||HPt(t),await FI[t]}function VPt(t,e,i={},o=null){if(!i.useLocalLibraries&&t.startsWith("http"))return t;o=o||t;const n=i.modules||{};return n[o]?n[o]:qa?i.CDN?(Ac(i.CDN.startsWith("http")),`${i.CDN}/${e}@${zX}/dist/libs/${o}`):TI?`../src/libs/${o}`:`modules/${e}/src/libs/${o}`:`modules/${e}/dist/libs/${o}`}async function HPt(t){if(t.endsWith("wasm"))return await qPt(t);if(!qa)try{const{requireFromFile:i}=globalThis.loaders||{};return await i?.(t)}catch(i){return console.error(i),null}if(TI)return importScripts(t);const e=await QPt(t);return zPt(e,t)}function zPt(t,e){if(!qa){const{requireFromString:o}=globalThis.loaders||{};return o?.(t,e)}if(TI)return eval.call(globalThis,t),null;const i=document.createElement("script");i.id=e;try{i.appendChild(document.createTextNode(t))}catch{i.text=t}return document.body.appendChild(i),null}async function qPt(t){const{readFileAsArrayBuffer:e}=globalThis.loaders||{};return qa||!e||t.startsWith("http")?await(await fetch(t)).arrayBuffer():await e(t)}async function QPt(t){const{readFileAsText:e}=globalThis.loaders||{};return qa||!e||t.startsWith("http")?await(await fetch(t)).text():await e(t)}function GPt(t,e){return!hu.isSupported()||!qa&&!e?._nodeWorkers?!1:t.worker&&e?.worker}async function KPt(t,e,i,o,n){const r=t.id,a=NPt(t,i),s=hu.getWorkerFarm(i).getWorkerPool({name:r,url:a});i=JSON.parse(JSON.stringify(i)),o=JSON.parse(JSON.stringify(o||{}));const l=await s.startJob("process-on-worker",JPt.bind(null,n));return l.postMessage("process",{input:e,options:i,context:o}),await(await l.result).result}async function JPt(t,e,i,o){switch(i){case"done":e.done(o);break;case"error":e.error(new Error(o.error));break;case"process":const{id:n,input:r,options:a}=o;try{const s=await t(r,a);e.postMessage("done",{id:n,result:s})}catch(s){const l=s instanceof Error?s.message:"unknown error";e.postMessage("error",{id:n,error:l})}break;default:console.warn(`parse-with-worker unknown message ${i}`)}}function ZPt(t,e=5){return typeof t=="string"?t.slice(0,e):ArrayBuffer.isView(t)?JX(t.buffer,t.byteOffset,e):t instanceof ArrayBuffer?JX(t,0,e):""}function JX(t,e,i){if(t.byteLength<=e+i)return"";const o=new DataView(t);let n="";for(let r=0;r<i;r++)n+=String.fromCharCode(o.getUint8(e+r));return n}function WPt(t){try{return JSON.parse(t)}catch{throw new Error(`Failed to parse JSON from data starting with "${ZPt(t)}"`)}}function YPt(t,e,i){if(i=i||t.byteLength,t.byteLength<i||e.byteLength<i)return!1;const o=new Uint8Array(t),n=new Uint8Array(e);for(let r=0;r<o.length;++r)if(o[r]!==n[r])return!1;return!0}function XPt(...t){return $Pt(t)}function $Pt(t){const e=t.map(r=>r instanceof ArrayBuffer?new Uint8Array(r):r),i=e.reduce((r,a)=>r+a.byteLength,0),o=new Uint8Array(i);let n=0;for(const r of e)o.set(r,n),n+=r.byteLength;return o.buffer}function ZX(t,e,i){const o=i!==void 0?new Uint8Array(t).subarray(e,e+i):new Uint8Array(t).subarray(e);return new Uint8Array(o).buffer}function I3(t,e){return fc(t>=0),fc(e>0),t+(e-1)&-4}function eIt(t,e,i){let o;if(t instanceof ArrayBuffer)o=new Uint8Array(t);else{const n=t.byteOffset,r=t.byteLength;o=new Uint8Array(t.buffer||t.arrayBuffer,n,r)}return e.set(o,i),i+I3(o.byteLength,4)}async function tIt(t){const e=[];for await(const i of t)e.push(i);return XPt(...e)}let iIt="";const WX={};function oIt(t){for(const e in WX)if(t.startsWith(e)){const i=WX[e];t=t.replace(e,i)}return!t.startsWith("http://")&&!t.startsWith("https://")&&(t=`${iIt}${t}`),t}function rIt(t){return t&&typeof t=="object"&&t.isBuffer}function YX(t){if(rIt(t)||t instanceof ArrayBuffer)return t;if(ArrayBuffer.isView(t))return t.byteOffset===0&&t.byteLength===t.buffer.byteLength?t.buffer:t.buffer.slice(t.byteOffset,t.byteOffset+t.byteLength);if(typeof t=="string"){const e=t;return new TextEncoder().encode(e).buffer}if(t&&typeof t=="object"&&t._toArrayBuffer)return t._toArrayBuffer();throw new Error("toArrayBuffer")}function XX(t){const e=t?t.lastIndexOf("/"):-1;return e>=0?t.substr(e+1):""}function nIt(t){const e=t?t.lastIndexOf("/"):-1;return e>=0?t.substr(0,e):""}const aIt=t=>typeof t=="boolean",S3=t=>typeof t=="function",T3=t=>t!==null&&typeof t=="object",$X=t=>T3(t)&&t.constructor==={}.constructor,sIt=t=>!!t&&typeof t[Symbol.iterator]=="function",lIt=t=>t&&typeof t[Symbol.asyncIterator]=="function",yh=t=>typeof Response<"u"&&t instanceof Response||t&&t.arrayBuffer&&t.text&&t.json,U1=t=>typeof Blob<"u"&&t instanceof Blob,cIt=t=>t&&typeof t=="object"&&t.isBuffer,dIt=t=>typeof ReadableStream<"u"&&t instanceof ReadableStream||T3(t)&&S3(t.tee)&&S3(t.cancel)&&S3(t.getReader),uIt=t=>T3(t)&&S3(t.read)&&S3(t.pipe)&&aIt(t.readable),e$=t=>dIt(t)||uIt(t);class hIt extends Error{constructor(e,i){super(e),this.reason=i.reason,this.url=i.url,this.response=i.response}reason;url;response}const pIt=/^data:([-\w.]+\/[-\w.+]+)(;|,)/,fIt=/^([-\w.]+\/[-\w.+]+)/;function t$(t,e){return t.toLowerCase()===e.toLowerCase()}function AIt(t){const e=fIt.exec(t);return e?e[1]:t}function i$(t){const e=pIt.exec(t);return e?e[1]:""}const o$=/\?.*/;function gIt(t){const e=t.match(o$);return e&&e[0]}function OI(t){return t.replace(o$,"")}function mIt(t){if(t.length<50)return t;const e=t.slice(t.length-15);return`${t.substr(0,32)}...${e}`}function f9(t){return yh(t)?t.url:U1(t)?t.name||"":typeof t=="string"?t:""}function UI(t){if(yh(t)){const e=t,i=e.headers.get("content-type")||"",o=OI(e.url);return AIt(i)||i$(o)}return U1(t)?t.type||"":typeof t=="string"?i$(t):""}function vIt(t){return yh(t)?t.headers["content-length"]||-1:U1(t)?t.size:typeof t=="string"?t.length:t instanceof ArrayBuffer||ArrayBuffer.isView(t)?t.byteLength:-1}async function r$(t){if(yh(t))return t;const e={},i=vIt(t);i>=0&&(e["content-length"]=String(i));const o=f9(t),n=UI(t);n&&(e["content-type"]=n);const r=await wIt(t);r&&(e["x-first-bytes"]=r),typeof t=="string"&&(t=new TextEncoder().encode(t));const a=new Response(t,{headers:e});return Object.defineProperty(a,"url",{value:o}),a}async function yIt(t){if(!t.ok)throw await bIt(t)}async function bIt(t){const e=mIt(t.url);let i=`Failed to fetch resource (${t.status}) ${t.statusText}: ${e}`;i=i.length>100?`${i.slice(0,100)}...`:i;const o={reason:t.statusText,url:t.url,response:t};try{const n=t.headers.get("Content-Type");o.reason=!t.bodyUsed&&n?.includes("application/json")?await t.json():await t.text()}catch{}return new hIt(i,o)}async function wIt(t){if(typeof t=="string")return`data:,${t.slice(0,5)}`;if(t instanceof Blob){const e=t.slice(0,5);return await new Promise(i=>{const o=new FileReader;o.onload=n=>i(n?.target?.result),o.readAsDataURL(e)})}if(t instanceof ArrayBuffer){const e=t.slice(0,5);return`data:base64,${CIt(e)}`}return null}function CIt(t){let e="";const i=new Uint8Array(t);for(let o=0;o<i.byteLength;o++)e+=String.fromCharCode(i[o]);return btoa(e)}function xIt(t){return!kIt(t)&&!MIt(t)}function kIt(t){return t.startsWith("http:")||t.startsWith("https:")}function MIt(t){return t.startsWith("data:")}async function n$(t,e){if(typeof t=="string"){const i=oIt(t);return xIt(i)&&globalThis.loaders?.fetchNode?globalThis.loaders?.fetchNode(i,e):await fetch(i,e)}return await r$(t)}const a$=new II({id:"loaders.gl"});class BIt{log(){return()=>{}}info(){return()=>{}}warn(){return()=>{}}error(){return()=>{}}}class EIt{console;constructor(){this.console=console}log(...e){return this.console.log.bind(this.console,...e)}info(...e){return this.console.info.bind(this.console,...e)}warn(...e){return this.console.warn.bind(this.console,...e)}error(...e){return this.console.error.bind(this.console,...e)}}const s$={fetch:null,mimeType:void 0,nothrow:!1,log:new EIt,useLocalLibraries:!1,CDN:"https://unpkg.com/@loaders.gl",worker:!0,maxConcurrency:3,maxMobileConcurrency:1,reuseWorkers:h9,_nodeWorkers:!1,_workerType:"",limit:0,_limitMB:0,batchSize:"auto",batchDebounceMs:0,metadata:!1,transforms:[]},PIt={throws:"nothrow",dataType:"(no longer used)",uri:"baseUri",method:"fetch.method",headers:"fetch.headers",body:"fetch.body",mode:"fetch.mode",credentials:"fetch.credentials",cache:"fetch.cache",redirect:"fetch.redirect",referrer:"fetch.referrer",referrerPolicy:"fetch.referrerPolicy",integrity:"fetch.integrity",keepalive:"fetch.keepalive",signal:"fetch.signal"};function l$(){globalThis.loaders=globalThis.loaders||{};const{loaders:t}=globalThis;return t._state||(t._state={}),t._state}function c$(){const t=l$();return t.globalOptions=t.globalOptions||{...s$},t.globalOptions}function IIt(t,e,i,o){return i=i||[],i=Array.isArray(i)?i:[i],SIt(t,i),DIt(e,t,o)}function SIt(t,e){d$(t,null,s$,PIt,e);for(const i of e){const o=t&&t[i.id]||{},n=i.options&&i.options[i.id]||{},r=i.deprecatedOptions&&i.deprecatedOptions[i.id]||{};d$(o,i.id,n,r,e)}}function d$(t,e,i,o,n){const r=e||"Top level",a=e?`${e}.`:"";for(const s in t){const l=!e&&T3(t[s]),c=s==="baseUri"&&!e,d=s==="workerUrl"&&e;if(!(s in i)&&!c&&!d){if(s in o)a$.warn(`${r} loader option '${a}${s}' no longer supported, use '${o[s]}'`)();else if(!l){const u=TIt(s,n);a$.warn(`${r} loader option '${a}${s}' not recognized. ${u}`)()}}}}function TIt(t,e){const i=t.toLowerCase();let o="";for(const n of e)for(const r in n.options){if(t===r)return`Did you mean '${n.id}.${r}'?`;const a=r.toLowerCase();(i.startsWith(a)||a.startsWith(i))&&(o=o||`Did you mean '${n.id}.${r}'?`)}return o}function DIt(t,e,i){const o={...t.options||{}};return RIt(o,i),o.log===null&&(o.log=new BIt),u$(o,c$()),u$(o,e),o}function u$(t,e){for(const i in e)if(i in e){const o=e[i];$X(o)&&$X(t[i])?t[i]={...t[i],...e[i]}:t[i]=e[i]}}function RIt(t,e){e&&!("baseUri"in t)&&(t.baseUri=e)}function h$(t){return t?(Array.isArray(t)&&(t=t[0]),Array.isArray(t?.extensions)):!1}function p$(t){fc(t,"null loader"),fc(h$(t),"invalid loader");let e;return Array.isArray(t)&&(e=t[1],t=t[0],t={...t,options:{...t.options,...e}}),(t?.parseTextSync||t?.parseText)&&(t.text=!0),t.text||(t.binary=!0),t}const LIt=()=>{const t=l$();return t.loaderRegistry=t.loaderRegistry||[],t.loaderRegistry};function _It(){return LIt()}const FIt=/\.([^.]+)$/;async function OIt(t,e=[],i,o){if(!A$(t))return null;let n=f$(t,e,{...i,nothrow:!0},o);if(n)return n;if(U1(t)&&(t=await t.slice(0,10).arrayBuffer(),n=f$(t,e,i,o)),!n&&!i?.nothrow)throw new Error(g$(t));return n}function f$(t,e=[],i,o){if(!A$(t))return null;if(e&&!Array.isArray(e))return p$(e);let n=[];e&&(n=n.concat(e)),i?.ignoreRegisteredLoaders||n.push(..._It()),NIt(n);const r=UIt(t,n,i,o);if(!r&&!i?.nothrow)throw new Error(g$(t));return r}function UIt(t,e,i,o){const n=f9(t),r=UI(t),a=OI(n)||o?.url;let s=null,l="";return i?.mimeType&&(s=NI(e,i?.mimeType),l=`match forced by supplied MIME type ${i?.mimeType}`),s=s||jIt(e,a),l=l||(s?`matched url ${a}`:""),s=s||NI(e,r),l=l||(s?`matched MIME type ${r}`:""),s=s||HIt(e,t),l=l||(s?`matched initial data ${v$(t)}`:""),i?.fallbackMimeType&&(s=s||NI(e,i?.fallbackMimeType),l=l||(s?`matched fallback MIME type ${r}`:"")),l&&BPt.log(1,`selectLoader selected ${s?.name}: ${l}.`),s}function A$(t){return!(t instanceof Response&&t.status===204)}function g$(t){const e=f9(t),i=UI(t);let o="No valid loader found (";o+=e?`${XX(e)}, `:"no url provided, ",o+=`MIME type: ${i?`"${i}"`:"not provided"}, `;const n=t?v$(t):"";return o+=n?` first bytes: "${n}"`:"first bytes: not available",o+=")",o}function NIt(t){for(const e of t)p$(e)}function jIt(t,e){const i=e&&FIt.exec(e),o=i&&i[1];return o?VIt(t,o):null}function VIt(t,e){e=e.toLowerCase();for(const i of t)for(const o of i.extensions)if(o.toLowerCase()===e)return i;return null}function NI(t,e){for(const i of t)if(i.mimeTypes?.some(o=>t$(e,o))||t$(e,`application/x.${i.id}`))return i;return null}function HIt(t,e){if(!e)return null;for(const i of t)if(typeof e=="string"){if(zIt(e,i))return i}else if(ArrayBuffer.isView(e)){if(m$(e.buffer,e.byteOffset,i))return i}else if(e instanceof ArrayBuffer&&m$(e,0,i))return i;return null}function zIt(t,e){return e.testText?e.testText(t):(Array.isArray(e.tests)?e.tests:[e.tests]).some(i=>t.startsWith(i))}function m$(t,e,i){return(Array.isArray(i.tests)?i.tests:[i.tests]).some(o=>qIt(t,e,i,o))}function qIt(t,e,i,o){if(o instanceof ArrayBuffer)return YPt(o,t,o.byteLength);switch(typeof o){case"function":return o(t);case"string":const n=jI(t,e,o.length);return o===n;default:return!1}}function v$(t,e=5){return typeof t=="string"?t.slice(0,e):ArrayBuffer.isView(t)?jI(t.buffer,t.byteOffset,e):t instanceof ArrayBuffer?jI(t,0,e):""}function jI(t,e,i){if(t.byteLength<e+i)return"";const o=new DataView(t);let n="";for(let r=0;r<i;r++)n+=String.fromCharCode(o.getUint8(e+r));return n}const QIt=256*1024;function*GIt(t,e){const i=e?.chunkSize||QIt;let o=0;const n=new TextEncoder;for(;o<t.length;){const r=Math.min(t.length-o,i),a=t.slice(o,o+r);o+=r,yield n.encode(a)}}const KIt=256*1024;function*JIt(t,e={}){const{chunkSize:i=KIt}=e;let o=0;for(;o<t.byteLength;){const n=Math.min(t.byteLength-o,i),r=new ArrayBuffer(n),a=new Uint8Array(t,o,n);new Uint8Array(r).set(a),o+=n,yield r}}const ZIt=1024*1024;async function*WIt(t,e){const i=e?.chunkSize||ZIt;let o=0;for(;o<t.size;){const n=o+i,r=await t.slice(o,n).arrayBuffer();o=n,yield r}}function y$(t,e){return h9?YIt(t,e):XIt(t)}async function*YIt(t,e){const i=t.getReader();let o;try{for(;;){const n=o||i.read();e?._streamReadAhead&&(o=i.read());const{done:r,value:a}=await n;if(r)return;yield YX(a)}}catch{i.releaseLock()}}async function*XIt(t,e){for await(const i of t)yield YX(i)}function $It(t,e){if(typeof t=="string")return GIt(t,e);if(t instanceof ArrayBuffer)return JIt(t,e);if(U1(t))return WIt(t,e);if(e$(t))return y$(t,e);if(yh(t))return y$(t.body,e);throw new Error("makeIterator")}const b$="Cannot convert supplied data type";function eSt(t,e,i){if(e.text&&typeof t=="string")return t;if(cIt(t)&&(t=t.buffer),t instanceof ArrayBuffer){const o=t;return e.text&&!e.binary?new TextDecoder("utf8").decode(o):o}if(ArrayBuffer.isView(t)){if(e.text&&!e.binary)return new TextDecoder("utf8").decode(t);let o=t.buffer;const n=t.byteLength||t.length;return(t.byteOffset!==0||n!==o.byteLength)&&(o=o.slice(t.byteOffset,t.byteOffset+n)),o}throw new Error(b$)}async function tSt(t,e,i){const o=t instanceof ArrayBuffer||ArrayBuffer.isView(t);if(typeof t=="string"||o)return eSt(t,e);if(U1(t)&&(t=await r$(t)),yh(t)){const n=t;return await yIt(n),e.binary?await n.arrayBuffer():await n.text()}if(e$(t)&&(t=$It(t,i)),sIt(t)||lIt(t))return tIt(t);throw new Error(b$)}function iSt(t,e){const i=c$(),o=t||i;return typeof o.fetch=="function"?o.fetch:T3(o.fetch)?n=>n$(n,o.fetch):e?.fetch?e?.fetch:n$}function oSt(t,e,i){if(i)return i;const o={fetch:iSt(e,t),...t};if(o.url){const n=OI(o.url);o.baseUrl=n,o.queryString=gIt(o.url),o.filename=XX(n),o.baseUrl=nIt(n)}return Array.isArray(o.loaders)||(o.loaders=null),o}function rSt(t,e){if(t&&!Array.isArray(t))return t;let i;if(t&&(i=Array.isArray(t)?t:[t]),e&&e.loaders){const o=Array.isArray(e.loaders)?e.loaders:[e.loaders];i=i?[...i,...o]:o}return i&&i.length?i:void 0}async function VI(t,e,i,o){e&&!Array.isArray(e)&&!h$(e)&&(o=void 0,i=e,e=void 0),t=await t,i=i||{};const n=f9(t),r=rSt(e,o),a=await OIt(t,r,i);return a?(i=IIt(i,a,r,n),o=oSt({url:n,_parse:VI,loaders:r},i,o||null),await nSt(a,t,i,o)):null}async function nSt(t,e,i,o){if(jPt(t),i=EPt(t.options,i),yh(e)){const r=e,{ok:a,redirected:s,status:l,statusText:c,type:d,url:u}=r,h=Object.fromEntries(r.headers.entries());o.response={headers:h,ok:a,redirected:s,status:l,statusText:c,type:d,url:u}}e=await tSt(e,t,i);const n=t;if(n.parseTextSync&&typeof e=="string")return n.parseTextSync(e,i,o);if(GPt(t,i))return await KPt(t,e,i,o,VI);if(n.parseText&&typeof e=="string")return await n.parseText(e,i,o);if(n.parse)return await n.parse(e,i,o);throw Ac(!n.parseSync),new Error(`${t.id} loader - no parser found and worker is disabled`)}function aSt(t){switch(t.constructor){case Int8Array:return"int8";case Uint8Array:case Uint8ClampedArray:return"uint8";case Int16Array:return"int16";case Uint16Array:return"uint16";case Int32Array:return"int32";case Uint32Array:return"uint32";case Float32Array:return"float32";case Float64Array:return"float64";default:return"null"}}function sSt(t){let e=1/0,i=1/0,o=1/0,n=-1/0,r=-1/0,a=-1/0;const s=t.POSITION?t.POSITION.value:[],l=s&&s.length;for(let c=0;c<l;c+=3){const d=s[c],u=s[c+1],h=s[c+2];e=d<e?d:e,i=u<i?u:i,o=h<o?h:o,n=d>n?d:n,r=u>r?u:r,a=h>a?h:a}return[[e,i,o],[n,r,a]]}function lSt(t,e,i){const o=aSt(e.value),n=i||cSt(e);return{name:t,type:{type:"fixed-size-list",listSize:e.size,children:[{name:"value",type:o}]},nullable:!1,metadata:n}}function cSt(t){const e={};return"byteOffset"in t&&(e.byteOffset=t.byteOffset.toString(10)),"byteStride"in t&&(e.byteStride=t.byteStride.toString(10)),"normalized"in t&&(e.normalized=t.normalized.toString()),e}const dSt="4.3.3",uSt=globalThis.loaders?.parseImageNode,HI=typeof Image<"u",zI=typeof ImageBitmap<"u",hSt=!!uSt,qI=h9?!0:hSt;function pSt(t){switch(t){case"auto":return zI||HI||qI;case"imagebitmap":return zI;case"image":return HI;case"data":return qI;default:throw new Error(`@loaders.gl/images: image ${t} not supported in this environment`)}}function fSt(){if(zI)return"imagebitmap";if(HI)return"image";if(qI)return"data";throw new Error("Install '@loaders.gl/polyfills' to parse images under Node.js")}function ASt(t){const e=gSt(t);if(!e)throw new Error("Not an image");return e}function w$(t){switch(ASt(t)){case"data":return t;case"image":case"imagebitmap":const e=document.createElement("canvas"),i=e.getContext("2d");if(!i)throw new Error("getImageData");return e.width=t.width,e.height=t.height,i.drawImage(t,0,0),i.getImageData(0,0,t.width,t.height);default:throw new Error("getImageData")}}function gSt(t){return typeof ImageBitmap<"u"&&t instanceof ImageBitmap?"imagebitmap":typeof Image<"u"&&t instanceof Image?"image":t&&typeof t=="object"&&t.data&&t.width&&t.height?"data":null}const mSt=/^data:image\/svg\+xml/,vSt=/\.svg((\?|#).*)?$/;function QI(t){return t&&(mSt.test(t)||vSt.test(t))}function ySt(t,e){if(QI(e)){let i=new TextDecoder().decode(t);try{typeof unescape=="function"&&typeof encodeURIComponent=="function"&&(i=unescape(encodeURIComponent(i)))}catch(o){throw new Error(o.message)}return`data:image/svg+xml;base64,${btoa(i)}`}return C$(t,e)}function C$(t,e){if(QI(e))throw new Error("SVG cannot be parsed directly to imagebitmap");return new Blob([new Uint8Array(t)])}async function x$(t,e,i){const o=ySt(t,i),n=self.URL||self.webkitURL,r=typeof o!="string"&&n.createObjectURL(o);try{return await bSt(r||o,e)}finally{r&&n.revokeObjectURL(r)}}async function bSt(t,e){const i=new Image;return i.src=t,e.image&&e.image.decode&&i.decode?(await i.decode(),i):await new Promise((o,n)=>{try{i.onload=()=>o(i),i.onerror=r=>{const a=r instanceof Error?r.message:"error";n(new Error(a))}}catch(r){n(r)}})}const wSt={};let k$=!0;async function CSt(t,e,i){let o;QI(i)?o=await x$(t,e,i):o=C$(t,i);const n=e&&e.imagebitmap;return await xSt(o,n)}async function xSt(t,e=null){if((kSt(e)||!k$)&&(e=null),e)try{return await createImageBitmap(t,e)}catch(i){console.warn(i),k$=!1}return await createImageBitmap(t)}function kSt(t){for(const e in t||wSt)return!1;return!0}function MSt(t){return!ISt(t,"ftyp",4)||(t[8]&96)===0?null:BSt(t)}function BSt(t){switch(ESt(t,8,12).replace("\0"," ").trim()){case"avif":case"avis":return{extension:"avif",mimeType:"image/avif"};default:return null}}function ESt(t,e,i){return String.fromCharCode(...t.slice(e,i))}function PSt(t){return[...t].map(e=>e.charCodeAt(0))}function ISt(t,e,i=0){const o=PSt(e);for(let n=0;n<o.length;++n)if(o[n]!==t[n+i])return!1;return!0}const Al=!1,D3=!0;function GI(t){const e=R3(t);return TSt(e)||LSt(e)||DSt(e)||RSt(e)||SSt(e)}function SSt(t){const e=new Uint8Array(t instanceof DataView?t.buffer:t),i=MSt(e);return i?{mimeType:i.mimeType,width:0,height:0}:null}function TSt(t){const e=R3(t);return e.byteLength>=24&&e.getUint32(0,Al)===2303741511?{mimeType:"image/png",width:e.getUint32(16,Al),height:e.getUint32(20,Al)}:null}function DSt(t){const e=R3(t);return e.byteLength>=10&&e.getUint32(0,Al)===1195984440?{mimeType:"image/gif",width:e.getUint16(6,D3),height:e.getUint16(8,D3)}:null}function RSt(t){const e=R3(t);return e.byteLength>=14&&e.getUint16(0,Al)===16973&&e.getUint32(2,D3)===e.byteLength?{mimeType:"image/bmp",width:e.getUint32(18,D3),height:e.getUint32(22,D3)}:null}function LSt(t){const e=R3(t);if(!(e.byteLength>=3&&e.getUint16(0,Al)===65496&&e.getUint8(2)===255))return null;const{tableMarkers:i,sofMarkers:o}=_St();let n=2;for(;n+9<e.byteLength;){const r=e.getUint16(n,Al);if(o.has(r))return{mimeType:"image/jpeg",height:e.getUint16(n+5,Al),width:e.getUint16(n+7,Al)};if(!i.has(r))return null;n+=2,n+=e.getUint16(n,Al)}return null}function _St(){const t=new Set([65499,65476,65484,65501,65534]);for(let e=65504;e<65520;++e)t.add(e);return{tableMarkers:t,sofMarkers:new Set([65472,65473,65474,65475,65477,65478,65479,65481,65482,65483,65485,65486,65487,65502])}}function R3(t){if(t instanceof DataView)return t;if(ArrayBuffer.isView(t))return new DataView(t.buffer);if(t instanceof ArrayBuffer)return new DataView(t);throw new Error("toDataView")}async function FSt(t,e){const{mimeType:i}=GI(t)||{},o=globalThis.loaders?.parseImageNode;return fc(o),await o(t,i)}async function OSt(t,e,i){e=e||{};const o=(e.image||{}).type||"auto",{url:n}=i||{},r=USt(o);let a;switch(r){case"imagebitmap":a=await CSt(t,e,n);break;case"image":a=await x$(t,e,n);break;case"data":a=await FSt(t);break;default:fc(!1)}return o==="data"&&(a=w$(a)),a}function USt(t){switch(t){case"auto":case"data":return fSt();default:return pSt(t),t}}const NSt=["png","jpg","jpeg","gif","webp","bmp","ico","svg","avif"],jSt=["image/png","image/jpeg","image/gif","image/webp","image/avif","image/bmp","image/vnd.microsoft.icon","image/svg+xml"],VSt={image:{type:"auto",decode:!0}},HSt={dataType:null,batchType:null,id:"image",module:"images",name:"Images",version:dSt,mimeTypes:jSt,extensions:NSt,parse:OSt,tests:[t=>!!GI(new DataView(t))],options:VSt},KI={};function zSt(t){if(KI[t]===void 0){const e=h9?QSt(t):qSt(t);KI[t]=e}return KI[t]}function qSt(t){const e=["image/png","image/jpeg","image/gif"],i=globalThis.loaders?.imageFormatsNode||e;return!!globalThis.loaders?.parseImageNode&&i.includes(t)}function QSt(t){switch(t){case"image/avif":case"image/webp":return GSt(t);default:return!0}}function GSt(t){try{return document.createElement("canvas").toDataURL(t).indexOf(`data:${t}`)===0}catch{return!1}}function ya(t,e){if(!t)throw new Error(e||"assert failed: gltf")}const M$={SCALAR:1,VEC2:2,VEC3:3,VEC4:4,MAT2:4,MAT3:9,MAT4:16},B$={5120:1,5121:1,5122:2,5123:2,5125:4,5126:4},E$=["SCALAR","VEC2","VEC3","VEC4"],KSt=[[Int8Array,5120],[Uint8Array,5121],[Int16Array,5122],[Uint16Array,5123],[Uint32Array,5125],[Float32Array,5126],[Float64Array,5130]],JSt=new Map(KSt),ZSt={SCALAR:1,VEC2:2,VEC3:3,VEC4:4,MAT2:4,MAT3:9,MAT4:16},WSt={5120:1,5121:1,5122:2,5123:2,5125:4,5126:4},YSt={5120:Int8Array,5121:Uint8Array,5122:Int16Array,5123:Uint16Array,5125:Uint32Array,5126:Float32Array};function P$(t){return E$[t-1]||E$[0]}function A9(t){const e=JSt.get(t.constructor);if(!e)throw new Error("Illegal typed array");return e}function JI(t,e){const i=YSt[t.componentType],o=ZSt[t.type],n=WSt[t.componentType],r=t.count*o,a=t.count*o*n;ya(a>=0&&a<=e.byteLength);const s=B$[t.componentType],l=M$[t.type];return{ArrayType:i,length:r,byteLength:a,componentByteSize:s,numberOfComponentsInElement:l}}function XSt(t,e,i){const o=t.bufferViews[i];ya(o);const n=o.buffer,r=e[n];ya(r);const a=(o.byteOffset||0)+r.byteOffset;return new Uint8Array(r.arrayBuffer,a,o.byteLength)}function $St(t,e,i){const o=typeof i=="number"?t.accessors?.[i]:i;if(!o)throw new Error(`No gltf accessor ${JSON.stringify(i)}`);const n=t.bufferViews?.[o.bufferView||0];if(!n)throw new Error(`No gltf buffer view for accessor ${n}`);const{arrayBuffer:r,byteOffset:a}=e[n.buffer],s=(a||0)+(o.byteOffset||0)+(n.byteOffset||0),{ArrayType:l,length:c,componentByteSize:d,numberOfComponentsInElement:u}=JI(o,n),h=d*u,p=n.byteStride||h;if(typeof n.byteStride>"u"||n.byteStride===h)return new l(r,s,c);const A=new l(c);for(let f=0;f<o.count;f++){const m=new l(r,s+f*p,u);A.set(m,f*u)}return A}function eTt(){return{asset:{version:"2.0",generator:"loaders.gl"},buffers:[],extensions:{},extensionsRequired:[],extensionsUsed:[]}}class Er{gltf;sourceBuffers;byteLength;constructor(e){this.gltf={json:e?.json||eTt(),buffers:e?.buffers||[],images:e?.images||[]},this.sourceBuffers=[],this.byteLength=0,this.gltf.buffers&&this.gltf.buffers[0]&&(this.byteLength=this.gltf.buffers[0].byteLength,this.sourceBuffers=[this.gltf.buffers[0]])}get json(){return this.gltf.json}getApplicationData(e){return this.json[e]}getExtraData(e){return(this.json.extras||{})[e]}hasExtension(e){const i=this.getUsedExtensions().find(n=>n===e),o=this.getRequiredExtensions().find(n=>n===e);return typeof i=="string"||typeof o=="string"}getExtension(e){const i=this.getUsedExtensions().find(n=>n===e),o=this.json.extensions||{};return i?o[e]:null}getRequiredExtension(e){return this.getRequiredExtensions().find(i=>i===e)?this.getExtension(e):null}getRequiredExtensions(){return this.json.extensionsRequired||[]}getUsedExtensions(){return this.json.extensionsUsed||[]}getRemovedExtensions(){return this.json.extensionsRemoved||[]}getObjectExtension(e,i){return(e.extensions||{})[i]}getScene(e){return this.getObject("scenes",e)}getNode(e){return this.getObject("nodes",e)}getSkin(e){return this.getObject("skins",e)}getMesh(e){return this.getObject("meshes",e)}getMaterial(e){return this.getObject("materials",e)}getAccessor(e){return this.getObject("accessors",e)}getTexture(e){return this.getObject("textures",e)}getSampler(e){return this.getObject("samplers",e)}getImage(e){return this.getObject("images",e)}getBufferView(e){return this.getObject("bufferViews",e)}getBuffer(e){return this.getObject("buffers",e)}getObject(e,i){if(typeof i=="object")return i;const o=this.json[e]&&this.json[e][i];if(!o)throw new Error(`glTF file error: Could not find ${e}[${i}]`);return o}getTypedArrayForBufferView(e){e=this.getBufferView(e);const i=e.buffer,o=this.gltf.buffers[i];ya(o);const n=(e.byteOffset||0)+o.byteOffset;return new Uint8Array(o.arrayBuffer,n,e.byteLength)}getTypedArrayForAccessor(e){const i=this.getAccessor(e);return $St(this.gltf.json,this.gltf.buffers,i)}getTypedArrayForImageData(e){e=this.getAccessor(e);const i=this.getBufferView(e.bufferView),o=this.getBuffer(i.buffer).data,n=i.byteOffset||0;return new Uint8Array(o,n,i.byteLength)}addApplicationData(e,i){return this.json[e]=i,this}addExtraData(e,i){return this.json.extras=this.json.extras||{},this.json.extras[e]=i,this}addObjectExtension(e,i,o){return e.extensions=e.extensions||{},e.extensions[i]=o,this.registerUsedExtension(i),this}setObjectExtension(e,i,o){const n=e.extensions||{};n[i]=o}removeObjectExtension(e,i){const o=e?.extensions||{};if(o[i]){this.json.extensionsRemoved=this.json.extensionsRemoved||[];const n=this.json.extensionsRemoved;n.includes(i)||n.push(i)}delete o[i]}addExtension(e,i={}){return ya(i),this.json.extensions=this.json.extensions||{},this.json.extensions[e]=i,this.registerUsedExtension(e),i}addRequiredExtension(e,i={}){return ya(i),this.addExtension(e,i),this.registerRequiredExtension(e),i}registerUsedExtension(e){this.json.extensionsUsed=this.json.extensionsUsed||[],this.json.extensionsUsed.find(i=>i===e)||this.json.extensionsUsed.push(e)}registerRequiredExtension(e){this.registerUsedExtension(e),this.json.extensionsRequired=this.json.extensionsRequired||[],this.json.extensionsRequired.find(i=>i===e)||this.json.extensionsRequired.push(e)}removeExtension(e){if(this.json.extensions?.[e]){this.json.extensionsRemoved=this.json.extensionsRemoved||[];const i=this.json.extensionsRemoved;i.includes(e)||i.push(e)}this.json.extensions&&delete this.json.extensions[e],this.json.extensionsRequired&&this._removeStringFromArray(this.json.extensionsRequired,e),this.json.extensionsUsed&&this._removeStringFromArray(this.json.extensionsUsed,e)}setDefaultScene(e){this.json.scene=e}addScene(e){const{nodeIndices:i}=e;return this.json.scenes=this.json.scenes||[],this.json.scenes.push({nodes:i}),this.json.scenes.length-1}addNode(e){const{meshIndex:i,matrix:o}=e;this.json.nodes=this.json.nodes||[];const n={mesh:i};return o&&(n.matrix=o),this.json.nodes.push(n),this.json.nodes.length-1}addMesh(e){const{attributes:i,indices:o,material:n,mode:r=4}=e,a={primitives:[{attributes:this._addAttributes(i),mode:r}]};if(o){const s=this._addIndices(o);a.primitives[0].indices=s}return Number.isFinite(n)&&(a.primitives[0].material=n),this.json.meshes=this.json.meshes||[],this.json.meshes.push(a),this.json.meshes.length-1}addPointCloud(e){const i={primitives:[{attributes:this._addAttributes(e),mode:0}]};return this.json.meshes=this.json.meshes||[],this.json.meshes.push(i),this.json.meshes.length-1}addImage(e,i){const o=GI(e),n=i||o?.mimeType,r={bufferView:this.addBufferView(e),mimeType:n};return this.json.images=this.json.images||[],this.json.images.push(r),this.json.images.length-1}addBufferView(e,i=0,o=this.byteLength){const n=e.byteLength;ya(Number.isFinite(n)),this.sourceBuffers=this.sourceBuffers||[],this.sourceBuffers.push(e);const r={buffer:i,byteOffset:o,byteLength:n};return this.byteLength+=I3(n,4),this.json.bufferViews=this.json.bufferViews||[],this.json.bufferViews.push(r),this.json.bufferViews.length-1}addAccessor(e,i){const o={bufferView:e,type:P$(i.size),componentType:i.componentType,count:i.count,max:i.max,min:i.min};return this.json.accessors=this.json.accessors||[],this.json.accessors.push(o),this.json.accessors.length-1}addBinaryBuffer(e,i={size:3}){const o=this.addBufferView(e);let n={min:i.min,max:i.max};(!n.min||!n.max)&&(n=this._getAccessorMinMax(e,i.size));const r={size:i.size,componentType:A9(e),count:Math.round(e.length/i.size),min:n.min,max:n.max};return this.addAccessor(o,Object.assign(r,i))}addTexture(e){const{imageIndex:i}=e,o={source:i};return this.json.textures=this.json.textures||[],this.json.textures.push(o),this.json.textures.length-1}addMaterial(e){return this.json.materials=this.json.materials||[],this.json.materials.push(e),this.json.materials.length-1}createBinaryChunk(){const e=this.byteLength,i=new ArrayBuffer(e),o=new Uint8Array(i);let n=0;for(const r of this.sourceBuffers||[])n=eIt(r,o,n);this.json?.buffers?.[0]?this.json.buffers[0].byteLength=e:this.json.buffers=[{byteLength:e}],this.gltf.binary=i,this.sourceBuffers=[i],this.gltf.buffers=[{arrayBuffer:i,byteOffset:0,byteLength:i.byteLength}]}_removeStringFromArray(e,i){let o=!0;for(;o;){const n=e.indexOf(i);n>-1?e.splice(n,1):o=!1}}_addAttributes(e={}){const i={};for(const o in e){const n=e[o],r=this._getGltfAttributeName(o),a=this.addBinaryBuffer(n.value,n);i[r]=a}return i}_addIndices(e){return this.addBinaryBuffer(e,{size:1})}_getGltfAttributeName(e){switch(e.toLowerCase()){case"position":case"positions":case"vertices":return"POSITION";case"normal":case"normals":return"NORMAL";case"color":case"colors":return"COLOR_0";case"texcoord":case"texcoords":return"TEXCOORD_0";default:return e}}_getAccessorMinMax(e,i){const o={min:null,max:null};if(e.length<i)return o;o.min=[],o.max=[];const n=e.subarray(0,i);for(const r of n)o.min.push(r),o.max.push(r);for(let r=i;r<e.length;r+=i)for(let a=0;a<i;a++)o.min[0+a]=Math.min(o.min[0+a],e[r+a]),o.max[0+a]=Math.max(o.max[0+a],e[r+a]);return o}}function I$(t){return(t%1+1)%1}const S$={SCALAR:1,VEC2:2,VEC3:3,VEC4:4,MAT2:4,MAT3:9,MAT4:16,BOOLEAN:1,STRING:1,ENUM:1},tTt={INT8:Int8Array,UINT8:Uint8Array,INT16:Int16Array,UINT16:Uint16Array,INT32:Int32Array,UINT32:Uint32Array,INT64:BigInt64Array,UINT64:BigUint64Array,FLOAT32:Float32Array,FLOAT64:Float64Array},T$={INT8:1,UINT8:1,INT16:2,UINT16:2,INT32:4,UINT32:4,INT64:8,UINT64:8,FLOAT32:4,FLOAT64:8};function ZI(t,e){return T$[e]*S$[t]}function g9(t,e,i,o){if(i!=="UINT8"&&i!=="UINT16"&&i!=="UINT32"&&i!=="UINT64")return null;const n=t.getTypedArrayForBufferView(e),r=m9(n,"SCALAR",i,o+1);return r instanceof BigInt64Array||r instanceof BigUint64Array?null:r}function m9(t,e,i,o=1){const n=S$[e],r=tTt[i],a=T$[i],s=o*n,l=s*a;let c=t.buffer,d=t.byteOffset;return d%a!==0&&(c=new Uint8Array(c).slice(d,d+l).buffer,d=0),new r(c,d,s)}function WI(t,e,i){const o=`TEXCOORD_${e.texCoord||0}`,n=i.attributes[o],r=t.getTypedArrayForAccessor(n),a=t.gltf.json,s=e.index,l=a.textures?.[s]?.source;if(typeof l<"u"){const c=a.images?.[l]?.mimeType,d=t.gltf.images?.[l];if(d&&typeof d.width<"u"){const u=[];for(let h=0;h<r.length;h+=2){const p=iTt(d,c,r,h,e.channels);u.push(p)}return u}}return[]}function D$(t,e,i,o,n){if(!i?.length)return;const r=[];for(const d of i){let u=o.findIndex(h=>h===d);u===-1&&(u=o.push(d)-1),r.push(u)}const a=new Uint32Array(r),s=t.gltf.buffers.push({arrayBuffer:a.buffer,byteOffset:a.byteOffset,byteLength:a.byteLength})-1,l=t.addBufferView(a,s,0),c=t.addAccessor(l,{size:1,componentType:A9(a),count:a.length});n.attributes[e]=c}function iTt(t,e,i,o,n=[0]){const r={r:{offset:0,shift:0},g:{offset:1,shift:8},b:{offset:2,shift:16},a:{offset:3,shift:24}},a=i[o],s=i[o+1];let l=1;e&&(e.indexOf("image/jpeg")!==-1||e.indexOf("image/png")!==-1)&&(l=4);const c=oTt(a,s,t,l);let d=0;for(const u of n){const h=typeof u=="number"?Object.values(r)[u]:r[u],p=c+h.offset,A=w$(t);if(A.data.length<=p)throw new Error(`${A.data.length} <= ${p}`);const f=A.data[p];d|=f<<h.shift}return d}function oTt(t,e,i,o=1){const n=i.width,r=I$(t)*(n-1),a=Math.round(r),s=i.height,l=I$(e)*(s-1),c=Math.round(l),d=i.components?i.components:o;return(c*n+a)*d}function R$(t,e,i,o,n){const r=[];for(let a=0;a<e;a++){const s=i[a],l=i[a+1]-i[a];if(l+s>o)break;const c=s/n,d=l/n;r.push(t.slice(c,c+d))}return r}function L$(t,e,i){const o=[];for(let n=0;n<e;n++){const r=n*i;o.push(t.slice(r,r+i))}return o}function _$(t,e,i,o){if(i)throw new Error("Not implemented - arrayOffsets for strings is specified");if(o){const n=[],r=new TextDecoder("utf8");let a=0;for(let s=0;s<t;s++){const l=o[s+1]-o[s];if(l+a<=e.length){const c=e.subarray(a,l+a),d=r.decode(c);n.push(d),a+=l}}return n}return[]}const N1="EXT_mesh_features",rTt=N1;async function nTt(t,e){const i=new Er(t);sTt(i,e)}function aTt(t,e){const i=new Er(t);return cTt(i),i.createBinaryChunk(),i.gltf}function sTt(t,e){const i=t.gltf.json;if(i.meshes)for(const o of i.meshes)for(const n of o.primitives)lTt(t,n,e)}function lTt(t,e,i){if(!i?.gltf?.loadBuffers)return;const o=e.extensions?.[N1]?.featureIds;if(o)for(const n of o){let r;if(typeof n.attribute<"u"){const a=`_FEATURE_ID_${n.attribute}`,s=e.attributes[a];r=t.getTypedArrayForAccessor(s)}else typeof n.texture<"u"&&i?.gltf?.loadImages?r=WI(t,n.texture,e):r=[];n.data=r}}function cTt(t,e){const i=t.gltf.json.meshes;if(i)for(const o of i)for(const n of o.primitives)uTt(t,n)}function dTt(t,e,i,o){e.extensions||(e.extensions={});let n=e.extensions[N1];n||(n={featureIds:[]},e.extensions[N1]=n);const{featureIds:r}=n,a={featureCount:i.length,propertyTable:o,data:i};r.push(a),t.addObjectExtension(e,N1,n)}function uTt(t,e){const i=e.extensions?.[N1];if(!i)return;const o=i.featureIds;o.forEach((n,r)=>{if(n.data){const{accessorKey:a,index:s}=hTt(e.attributes),l=new Uint32Array(n.data);o[r]={featureCount:l.length,propertyTable:n.propertyTable,attribute:s},t.gltf.buffers.push({arrayBuffer:l.buffer,byteOffset:l.byteOffset,byteLength:l.byteLength});const c=t.addBufferView(l),d=t.addAccessor(c,{size:1,componentType:A9(l),count:l.length});e.attributes[a]=d}})}function hTt(t){const e="_FEATURE_ID_",i=Object.keys(t).filter(n=>n.indexOf(e)===0);let o=-1;for(const n of i){const r=Number(n.substring(e.length));r>o&&(o=r)}return o++,{accessorKey:`${e}${o}`,index:o}}const pTt=Object.freeze(Object.defineProperty({__proto__:null,createExtMeshFeatures:dTt,decode:nTt,encode:aTt,name:rTt},Symbol.toStringTag,{value:"Module"})),j1="EXT_structural_metadata",fTt=j1;async function ATt(t,e){const i=new Er(t);mTt(i,e)}function gTt(t,e){const i=new Er(t);return RTt(i),i.createBinaryChunk(),i.gltf}function mTt(t,e){if(!e.gltf?.loadBuffers)return;const i=t.getExtension(j1);i&&(e.gltf?.loadImages&&vTt(t,i),yTt(t,i))}function vTt(t,e){const i=e.propertyTextures,o=t.gltf.json;if(i&&o.meshes)for(const n of o.meshes)for(const r of n.primitives)wTt(t,i,r,e)}function yTt(t,e){const i=e.schema;if(!i)return;const o=i.classes,n=e.propertyTables;if(o&&n)for(const r in o){const a=bTt(n,r);a&&xTt(t,i,a)}}function bTt(t,e){for(const i of t)if(i.class===e)return i;return null}function wTt(t,e,i,o){if(!e)return;const n=i.extensions?.[j1]?.propertyTextures;if(n)for(const r of n){const a=e[r];CTt(t,a,i,o)}}function CTt(t,e,i,o){if(!e.properties)return;o.dataAttributeNames||(o.dataAttributeNames=[]);const n=e.class;for(const r in e.properties){const a=`${n}_${r}`,s=e.properties?.[r];if(!s)continue;s.data||(s.data=[]);const l=s.data,c=WI(t,s,i);c!==null&&(D$(t,a,c,l,i),s.data=l,o.dataAttributeNames.push(a))}}function xTt(t,e,i){const o=e.classes?.[i.class];if(!o)throw new Error(`Incorrect data in the EXT_structural_metadata extension: no schema class with name ${i.class}`);const n=i.count;for(const r in o.properties){const a=o.properties[r],s=i.properties?.[r];if(s){const l=kTt(t,e,a,n,s);s.data=l}}}function kTt(t,e,i,o,n){let r=[];const a=n.values,s=t.getTypedArrayForBufferView(a),l=MTt(t,i,n,o),c=BTt(t,n,o);switch(i.type){case"SCALAR":case"VEC2":case"VEC3":case"VEC4":case"MAT2":case"MAT3":case"MAT4":{r=ETt(i,o,s,l);break}case"BOOLEAN":throw new Error(`Not implemented - classProperty.type=${i.type}`);case"STRING":{r=_$(o,s,l,c);break}case"ENUM":{r=PTt(e,i,o,s,l);break}default:throw new Error(`Unknown classProperty type ${i.type}`)}return r}function MTt(t,e,i,o){return e.array&&typeof e.count>"u"&&typeof i.arrayOffsets<"u"?g9(t,i.arrayOffsets,i.arrayOffsetType||"UINT32",o):null}function BTt(t,e,i){return typeof e.stringOffsets<"u"?g9(t,e.stringOffsets,e.stringOffsetType||"UINT32",i):null}function ETt(t,e,i,o){const n=t.array,r=t.count,a=ZI(t.type,t.componentType),s=i.byteLength/a;let l;return t.componentType?l=m9(i,t.type,t.componentType,s):l=i,n?o?R$(l,e,o,i.length,a):r?L$(l,e,r):[]:l}function PTt(t,e,i,o,n){const r=e.enumType;if(!r)throw new Error("Incorrect data in the EXT_structural_metadata extension: classProperty.enumType is not set for type ENUM");const a=t.enums?.[r];if(!a)throw new Error(`Incorrect data in the EXT_structural_metadata extension: schema.enums does't contain ${r}`);const s=a.valueType||"UINT16",l=ZI(e.type,s),c=o.byteLength/l;let d=m9(o,e.type,s,c);if(d||(d=o),e.array){if(n)return ITt({valuesData:d,numberOfElements:i,arrayOffsets:n,valuesDataBytesLength:o.length,elementSize:l,enumEntry:a});const u=e.count;return u?STt(d,i,u,a):[]}return YI(d,0,i,a)}function ITt(t){const{valuesData:e,numberOfElements:i,arrayOffsets:o,valuesDataBytesLength:n,elementSize:r,enumEntry:a}=t,s=[];for(let l=0;l<i;l++){const c=o[l],d=o[l+1]-o[l];if(d+c>n)break;const u=c/r,h=d/r,p=YI(e,u,h,a);s.push(p)}return s}function STt(t,e,i,o){const n=[];for(let r=0;r<e;r++){const a=i*r,s=YI(t,a,i,o);n.push(s)}return n}function YI(t,e,i,o){const n=[];for(let r=0;r<i;r++)if(t instanceof BigInt64Array||t instanceof BigUint64Array)n.push("");else{const a=t[e+r],s=TTt(o,a);s?n.push(s.name):n.push("")}return n}function TTt(t,e){for(const i of t.values)if(i.value===e)return i;return null}const DTt="schemaClassId";function RTt(t,e){const i=t.getExtension(j1);if(i&&i.propertyTables)for(const o of i.propertyTables){const n=o.class,r=i.schema?.classes?.[n];o.properties&&r&&LTt(o,r,t)}}function LTt(t,e,i){for(const o in t.properties){const n=t.properties[o].data;if(n){const r=e.properties[o];if(r){const a=UTt(n,r,i);t.properties[o]=a}}}}function _Tt(t,e,i=DTt){let o=t.getExtension(j1);o||(o=t.addExtension(j1)),o.schema=FTt(e,i,o.schema);const n=OTt(e,i,o.schema);return o.propertyTables||(o.propertyTables=[]),o.propertyTables.push(n)-1}function FTt(t,e,i){const o=i??{id:"schema_id"},n={properties:{}};for(const r of t){const a={type:r.elementType,componentType:r.componentType};n.properties[r.name]=a}return o.classes={},o.classes[e]=n,o}function OTt(t,e,i){const o={class:e,count:0};let n=0;const r=i.classes?.[e];for(const a of t){if(n===0&&(n=a.values.length),n!==a.values.length&&a.values.length)throw new Error("Illegal values in attributes");r?.properties[a.name]&&(o.properties||(o.properties={}),o.properties[a.name]={values:0,data:a.values})}return o.count=n,o}function UTt(t,e,i){const o={values:0};if(e.type==="STRING"){const{stringData:n,stringOffsets:r}=VTt(t);o.stringOffsets=XI(r,i),o.values=XI(n,i)}else if(e.type==="SCALAR"&&e.componentType){const n=jTt(t,e.componentType);o.values=XI(n,i)}return o}const NTt={INT8:Int8Array,UINT8:Uint8Array,INT16:Int16Array,UINT16:Uint16Array,INT32:Int32Array,UINT32:Uint32Array,INT64:Int32Array,UINT64:Uint32Array,FLOAT32:Float32Array,FLOAT64:Float64Array};function jTt(t,e){const i=[];for(const n of t)i.push(Number(n));const o=NTt[e];if(!o)throw new Error("Illegal component type");return new o(i)}function VTt(t){const e=new TextEncoder,i=[];let o=0;for(const l of t){const c=e.encode(l);o+=c.length,i.push(c)}const n=new Uint8Array(o),r=[];let a=0;for(const l of i)n.set(l,a),r.push(a),a+=l.length;r.push(a);const s=new Uint32Array(r);return{stringData:n,stringOffsets:s}}function XI(t,e){return e.gltf.buffers.push({arrayBuffer:t.buffer,byteOffset:t.byteOffset,byteLength:t.byteLength}),e.addBufferView(t)}const HTt=Object.freeze(Object.defineProperty({__proto__:null,createExtStructuralMetadata:_Tt,decode:ATt,encode:gTt,name:fTt},Symbol.toStringTag,{value:"Module"})),F$="EXT_feature_metadata",zTt=F$;async function qTt(t,e){const i=new Er(t);QTt(i,e)}function QTt(t,e){if(!e.gltf?.loadBuffers)return;const i=t.getExtension(F$);i&&(e.gltf?.loadImages&&GTt(t,i),KTt(t,i))}function GTt(t,e){const i=e.schema;if(!i)return;const o=i.classes,{featureTextures:n}=e;if(o&&n)for(const r in o){const a=o[r],s=ZTt(n,r);s&&YTt(t,s,a)}}function KTt(t,e){const i=e.schema;if(!i)return;const o=i.classes,n=e.featureTables;if(o&&n)for(const r in o){const a=JTt(n,r);a&&WTt(t,i,a)}}function JTt(t,e){for(const i in t){const o=t[i];if(o.class===e)return o}return null}function ZTt(t,e){for(const i in t){const o=t[i];if(o.class===e)return o}return null}function WTt(t,e,i){if(!i.class)return;const o=e.classes?.[i.class];if(!o)throw new Error(`Incorrect data in the EXT_structural_metadata extension: no schema class with name ${i.class}`);const n=i.count;for(const r in o.properties){const a=o.properties[r],s=i.properties?.[r];if(s){const l=XTt(t,e,a,n,s);s.data=l}}}function YTt(t,e,i){const o=e.class;for(const n in i.properties){const r=e?.properties?.[n];if(r){const a=oDt(t,r,o);r.data=a}}}function XTt(t,e,i,o,n){let r=[];const a=n.bufferView,s=t.getTypedArrayForBufferView(a),l=$Tt(t,i,n,o),c=eDt(t,i,n,o);return i.type==="STRING"||i.componentType==="STRING"?r=_$(o,s,l,c):tDt(i)&&(r=iDt(i,o,s,l)),r}function $Tt(t,e,i,o){return e.type==="ARRAY"&&typeof e.componentCount>"u"&&typeof i.arrayOffsetBufferView<"u"?g9(t,i.arrayOffsetBufferView,i.offsetType||"UINT32",o):null}function eDt(t,e,i,o){return typeof i.stringOffsetBufferView<"u"?g9(t,i.stringOffsetBufferView,i.offsetType||"UINT32",o):null}function tDt(t){const e=["UINT8","INT16","UINT16","INT32","UINT32","INT64","UINT64","FLOAT32","FLOAT64"];return e.includes(t.type)||typeof t.componentType<"u"&&e.includes(t.componentType)}function iDt(t,e,i,o){const n=t.type==="ARRAY",r=t.componentCount,a="SCALAR",s=t.componentType||t.type,l=ZI(a,s),c=i.byteLength/l,d=m9(i,a,s,c);return n?o?R$(d,e,o,i.length,l):r?L$(d,e,r):[]:d}function oDt(t,e,i){const o=t.gltf.json;if(!o.meshes)return[];const n=[];for(const r of o.meshes)for(const a of r.primitives)rDt(t,i,e,n,a);return n}function rDt(t,e,i,o,n){const r={channels:i.channels,...i.texture},a=WI(t,r,n);a&&D$(t,e,a,o,n)}const nDt=Object.freeze(Object.defineProperty({__proto__:null,decode:qTt,name:zTt},Symbol.toStringTag,{value:"Module"})),aDt="4.3.3",sDt="4.3.3",v9={TRANSCODER:"basis_transcoder.js",TRANSCODER_WASM:"basis_transcoder.wasm",ENCODER:"basis_encoder.js",ENCODER_WASM:"basis_encoder.wasm"};let O$;async function U$(t){return PPt(t.modules),IPt("basis")||(O$||=lDt(t),await O$)}async function lDt(t){let e=null,i=null;return[e,i]=await Promise.all([await vh(v9.TRANSCODER,"textures",t),await vh(v9.TRANSCODER_WASM,"textures",t)]),e=e||globalThis.BASIS,await cDt(e,i)}function cDt(t,e){const i={};return e&&(i.wasmBinary=e),new Promise(o=>{t(i).then(n=>{const{BasisFile:r,initializeBasis:a}=n;a(),o({BasisFile:r})})})}let $I;async function N$(t){const e=t.modules||{};return e.basisEncoder?e.basisEncoder:($I=$I||dDt(t),await $I)}async function dDt(t){let e=null,i=null;return[e,i]=await Promise.all([await vh(v9.ENCODER,"textures",t),await vh(v9.ENCODER_WASM,"textures",t)]),e=e||globalThis.BASIS,await uDt(e,i)}function uDt(t,e){const i={};return e&&(i.wasmBinary=e),new Promise(o=>{t(i).then(n=>{const{BasisFile:r,KTX2File:a,initializeBasis:s,BasisEncoder:l}=n;s(),o({BasisFile:r,KTX2File:a,BasisEncoder:l})})})}const V1={COMPRESSED_RGB_S3TC_DXT1_EXT:33776,COMPRESSED_RGBA_S3TC_DXT5_EXT:33779,COMPRESSED_RGB_PVRTC_4BPPV1_IMG:35840,COMPRESSED_RGBA_PVRTC_4BPPV1_IMG:35842,COMPRESSED_RGB_ETC1_WEBGL:36196,COMPRESSED_RGBA_ASTC_4X4_KHR:37808},hDt=["","WEBKIT_","MOZ_"],j$={WEBGL_compressed_texture_s3tc:"dxt",WEBGL_compressed_texture_s3tc_srgb:"dxt-srgb",WEBGL_compressed_texture_etc1:"etc1",WEBGL_compressed_texture_etc:"etc2",WEBGL_compressed_texture_pvrtc:"pvrtc",WEBGL_compressed_texture_atc:"atc",WEBGL_compressed_texture_astc:"astc",EXT_texture_compression_rgtc:"rgtc"};let y9=null;function pDt(t){if(!y9){t=t||fDt()||void 0,y9=new Set;for(const e of hDt)for(const i in j$)if(t&&t.getExtension(`${e}${i}`)){const o=j$[i];y9.add(o)}}return y9}function fDt(){try{return document.createElement("canvas").getContext("webgl")}catch{return null}}const ba=[171,75,84,88,32,50,48,187,13,10,26,10];function ADt(t){const e=new Uint8Array(t);return!(e.byteLength<ba.length||e[0]!==ba[0]||e[1]!==ba[1]||e[2]!==ba[2]||e[3]!==ba[3]||e[4]!==ba[4]||e[5]!==ba[5]||e[6]!==ba[6]||e[7]!==ba[7]||e[8]!==ba[8]||e[9]!==ba[9]||e[10]!==ba[10]||e[11]!==ba[11])}const gDt={etc1:{basisFormat:0,compressed:!0,format:V1.COMPRESSED_RGB_ETC1_WEBGL},etc2:{basisFormat:1,compressed:!0},bc1:{basisFormat:2,compressed:!0,format:V1.COMPRESSED_RGB_S3TC_DXT1_EXT},bc3:{basisFormat:3,compressed:!0,format:V1.COMPRESSED_RGBA_S3TC_DXT5_EXT},bc4:{basisFormat:4,compressed:!0},bc5:{basisFormat:5,compressed:!0},"bc7-m6-opaque-only":{basisFormat:6,compressed:!0},"bc7-m5":{basisFormat:7,compressed:!0},"pvrtc1-4-rgb":{basisFormat:8,compressed:!0,format:V1.COMPRESSED_RGB_PVRTC_4BPPV1_IMG},"pvrtc1-4-rgba":{basisFormat:9,compressed:!0,format:V1.COMPRESSED_RGBA_PVRTC_4BPPV1_IMG},"astc-4x4":{basisFormat:10,compressed:!0,format:V1.COMPRESSED_RGBA_ASTC_4X4_KHR},"atc-rgb":{basisFormat:11,compressed:!0},"atc-rgba-interpolated-alpha":{basisFormat:12,compressed:!0},rgba32:{basisFormat:13,compressed:!1},rgb565:{basisFormat:14,compressed:!1},bgr565:{basisFormat:15,compressed:!1},rgba4444:{basisFormat:16,compressed:!1}};async function mDt(t,e){if(e.basis.containerFormat==="auto"){if(ADt(t)){const o=await N$(e);return V$(o.KTX2File,t,e)}const{BasisFile:i}=await U$(e);return eS(i,t,e)}switch(e.basis.module){case"encoder":const i=await N$(e);switch(e.basis.containerFormat){case"ktx2":return V$(i.KTX2File,t,e);case"basis":default:return eS(i.BasisFile,t,e)}case"transcoder":default:const{BasisFile:o}=await U$(e);return eS(o,t,e)}}function eS(t,e,i){const o=new t(new Uint8Array(e));try{if(!o.startTranscoding())throw new Error("Failed to start basis transcoding");const n=o.getNumImages(),r=[];for(let a=0;a<n;a++){const s=o.getNumLevels(a),l=[];for(let c=0;c<s;c++)l.push(vDt(o,a,c,i));r.push(l)}return r}finally{o.close(),o.delete()}}function vDt(t,e,i,o){const n=t.getImageWidth(e,i),r=t.getImageHeight(e,i),a=t.getHasAlpha(),{compressed:s,format:l,basisFormat:c}=H$(o,a),d=t.getImageTranscodedSizeInBytes(e,i,c),u=new Uint8Array(d);if(!t.transcodeImage(u,e,i,c,0,0))throw new Error("failed to start Basis transcoding");return{width:n,height:r,data:u,compressed:s,format:l,hasAlpha:a}}function V$(t,e,i){const o=new t(new Uint8Array(e));try{if(!o.startTranscoding())throw new Error("failed to start KTX2 transcoding");const n=o.getLevels(),r=[];for(let a=0;a<n;a++)r.push(yDt(o,a,i));return[r]}finally{o.close(),o.delete()}}function yDt(t,e,i){const{alphaFlag:o,height:n,width:r}=t.getImageLevelInfo(e,0,0),{compressed:a,format:s,basisFormat:l}=H$(i,o),c=t.getImageTranscodedSizeInBytes(e,0,0,l),d=new Uint8Array(c);if(!t.transcodeImage(d,e,0,0,l,0,-1,-1))throw new Error("Failed to transcode KTX2 image");return{width:r,height:n,data:d,compressed:a,levelSize:c,hasAlpha:o,format:s}}function H$(t,e){let i=t&&t.basis&&t.basis.format;return i==="auto"&&(i=z$()),typeof i=="object"&&(i=e?i.alpha:i.noAlpha),i=i.toLowerCase(),gDt[i]}function z$(){const t=pDt();return t.has("astc")?"astc-4x4":t.has("dxt")?{alpha:"bc3",noAlpha:"bc1"}:t.has("pvrtc")?{alpha:"pvrtc1-4-rgba",noAlpha:"pvrtc1-4-rgb"}:t.has("etc1")?"etc1":t.has("etc2")?"etc2":"rgb565"}const bDt={dataType:null,batchType:null,name:"Basis",id:"basis",module:"textures",version:sDt,worker:!0,extensions:["basis","ktx2"],mimeTypes:["application/octet-stream","image/ktx2"],tests:["sB"],binary:!0,options:{basis:{format:"auto",libraryPath:"libs/",containerFormat:"auto",module:"transcoder"}}},wDt={...bDt,parse:mDt},H1=!0,q$=1735152710,tS=12,b9=8,CDt=1313821514,xDt=5130562,kDt=0,MDt=0,BDt=1;function EDt(t,e=0){return`${String.fromCharCode(t.getUint8(e+0))}${String.fromCharCode(t.getUint8(e+1))}${String.fromCharCode(t.getUint8(e+2))}${String.fromCharCode(t.getUint8(e+3))}`}function PDt(t,e=0,i={}){const o=new DataView(t),{magic:n=q$}=i,r=o.getUint32(e,!1);return r===n||r===q$}function IDt(t,e,i=0,o={}){const n=new DataView(e),r=EDt(n,i+0),a=n.getUint32(i+4,H1),s=n.getUint32(i+8,H1);switch(Object.assign(t,{header:{byteOffset:i,byteLength:s,hasBinChunk:!1},type:r,version:a,json:{},binChunks:[]}),i+=tS,t.version){case 1:return SDt(t,n,i);case 2:return TDt(t,n,i,o={});default:throw new Error(`Invalid GLB version ${t.version}. Only supports version 1 and 2.`)}}function SDt(t,e,i){fc(t.header.byteLength>tS+b9);const o=e.getUint32(i+0,H1),n=e.getUint32(i+4,H1);return i+=b9,fc(n===kDt),iS(t,e,i,o),i+=o,i+=oS(t,e,i,t.header.byteLength),i}function TDt(t,e,i,o){return fc(t.header.byteLength>tS+b9),DDt(t,e,i,o),i+t.header.byteLength}function DDt(t,e,i,o){for(;i+8<=t.header.byteLength;){const n=e.getUint32(i+0,H1),r=e.getUint32(i+4,H1);switch(i+=b9,r){case CDt:iS(t,e,i,n);break;case xDt:oS(t,e,i,n);break;case MDt:o.strict||iS(t,e,i,n);break;case BDt:o.strict||oS(t,e,i,n);break}i+=I3(n,4)}return i}function iS(t,e,i,o){const n=new Uint8Array(e.buffer,i,o),r=new TextDecoder("utf8").decode(n);return t.json=JSON.parse(r),I3(o,4)}function oS(t,e,i,o){return t.header.hasBinChunk=!0,t.binChunks.push({byteOffset:i,byteLength:o,arrayBuffer:e.buffer}),I3(o,4)}function Q$(t,e){if(t.startsWith("data:")||t.startsWith("http:")||t.startsWith("https:"))return t;const i=e.baseUri||e.uri;if(!i)throw new Error(`'baseUri' must be provided to resolve relative url ${t}`);return i.substr(0,i.lastIndexOf("/")+1)+t}const RDt="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",LDt="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",_Dt=new Uint8Array([0,97,115,109,1,0,0,0,1,4,1,96,0,0,3,3,2,0,0,5,3,1,0,1,12,1,0,10,22,2,12,0,65,0,65,0,65,0,252,10,0,0,11,7,0,65,0,253,15,26,11]),FDt=new Uint8Array([32,0,65,253,3,1,2,34,4,106,6,5,11,8,7,20,13,33,12,16,128,9,116,64,19,113,127,15,10,21,22,14,255,66,24,54,136,107,18,23,192,26,114,118,132,17,77,101,130,144,27,87,131,44,45,74,156,154,70,167]),ODt={0:"",1:"meshopt_decodeFilterOct",2:"meshopt_decodeFilterQuat",3:"meshopt_decodeFilterExp",NONE:"",OCTAHEDRAL:"meshopt_decodeFilterOct",QUATERNION:"meshopt_decodeFilterQuat",EXPONENTIAL:"meshopt_decodeFilterExp"},UDt={0:"meshopt_decodeVertexBuffer",1:"meshopt_decodeIndexBuffer",2:"meshopt_decodeIndexSequence",ATTRIBUTES:"meshopt_decodeVertexBuffer",TRIANGLES:"meshopt_decodeIndexBuffer",INDICES:"meshopt_decodeIndexSequence"};async function NDt(t,e,i,o,n,r="NONE"){const a=await jDt();zDt(a,a.exports[UDt[n]],t,e,i,o,a.exports[ODt[r||"NONE"]])}let rS;async function jDt(){return rS||(rS=VDt()),rS}async function VDt(){let t=RDt;WebAssembly.validate(_Dt)&&(t=LDt,console.log("Warning: meshopt_decoder is using experimental SIMD support"));const e=await WebAssembly.instantiate(HDt(t),{});return await e.instance.exports.__wasm_call_ctors(),e.instance}function HDt(t){const e=new Uint8Array(t.length);for(let o=0;o<t.length;++o){const n=t.charCodeAt(o);e[o]=n>96?n-71:n>64?n-65:n>47?n+4:n>46?63:62}let i=0;for(let o=0;o<t.length;++o)e[i++]=e[o]<60?FDt[e[o]]:(e[o]-60)*64+e[++o];return e.buffer.slice(0,i)}function zDt(t,e,i,o,n,r,a){const s=t.exports.sbrk,l=o+3&-4,c=s(l*n),d=s(r.length),u=new Uint8Array(t.exports.memory.buffer);u.set(r,d);const h=e(c,o,n,d,r.length);if(h===0&&a&&a(c,l,n),i.set(u.subarray(c,c+o*n)),s(c-s(0)),h!==0)throw new Error(`Malformed buffer data: ${h}`)}const w9="EXT_meshopt_compression",qDt=w9;async function QDt(t,e){const i=new Er(t);if(!e?.gltf?.decompressMeshes||!e.gltf?.loadBuffers)return;const o=[];for(const n of t.json.bufferViews||[])o.push(GDt(i,n));await Promise.all(o),i.removeExtension(w9)}async function GDt(t,e){const i=t.getObjectExtension(e,w9);if(i){const{byteOffset:o=0,byteLength:n=0,byteStride:r,count:a,mode:s,filter:l="NONE",buffer:c}=i,d=t.gltf.buffers[c],u=new Uint8Array(d.arrayBuffer,d.byteOffset+o,n),h=new Uint8Array(t.gltf.buffers[e.buffer].arrayBuffer,e.byteOffset,e.byteLength);await NDt(h,a,r,u,s,l),t.removeObjectExtension(e,w9)}}const KDt=Object.freeze(Object.defineProperty({__proto__:null,decode:QDt,name:qDt},Symbol.toStringTag,{value:"Module"})),z1="EXT_texture_webp",JDt=z1;function ZDt(t,e){const i=new Er(t);if(!zSt("image/webp")){if(i.getRequiredExtensions().includes(z1))throw new Error(`gltf: Required extension ${z1} not supported by browser`);return}const{json:o}=i;for(const n of o.textures||[]){const r=i.getObjectExtension(n,z1);r&&(n.source=r.source),i.removeObjectExtension(n,z1)}i.removeExtension(z1)}const WDt=Object.freeze(Object.defineProperty({__proto__:null,name:JDt,preprocess:ZDt},Symbol.toStringTag,{value:"Module"})),C9="KHR_texture_basisu",YDt=C9;function XDt(t,e){const i=new Er(t),{json:o}=i;for(const n of o.textures||[]){const r=i.getObjectExtension(n,C9);r&&(n.source=r.source,i.removeObjectExtension(n,C9))}i.removeExtension(C9)}const $Dt=Object.freeze(Object.defineProperty({__proto__:null,name:YDt,preprocess:XDt},Symbol.toStringTag,{value:"Module"})),eRt="4.3.3",tRt={dataType:null,batchType:null,name:"Draco",id:"draco",module:"draco",version:eRt,worker:!0,extensions:["drc"],mimeTypes:["application/octet-stream"],binary:!0,tests:["DRACO"],options:{draco:{decoderType:typeof WebAssembly=="object"?"wasm":"js",libraryPath:"libs/",extraAttributes:{},attributeNameEntry:void 0}}};function iRt(t,e,i){const o=K$(e.metadata),n=[],r=oRt(e.attributes);for(const a in t){const s=t[a],l=G$(a,s,r[a]);n.push(l)}if(i){const a=G$("indices",i);n.push(a)}return{fields:n,metadata:o}}function oRt(t){const e={};for(const i in t){const o=t[i];e[o.name||"undefined"]=o}return e}function G$(t,e,i){const o=i?K$(i.metadata):void 0;return lSt(t,e,o)}function K$(t){Object.entries(t);const e={};for(const i in t)e[`${i}.string`]=JSON.stringify(t[i]);return e}const J$={POSITION:"POSITION",NORMAL:"NORMAL",COLOR:"COLOR_0",TEX_COORD:"TEXCOORD_0"},rRt={1:Int8Array,2:Uint8Array,3:Int16Array,4:Uint16Array,5:Int32Array,6:Uint32Array,9:Float32Array},nRt=4;class aRt{draco;decoder;metadataQuerier;constructor(e){this.draco=e,this.decoder=new this.draco.Decoder,this.metadataQuerier=new this.draco.MetadataQuerier}destroy(){this.draco.destroy(this.decoder),this.draco.destroy(this.metadataQuerier)}parseSync(e,i={}){const o=new this.draco.DecoderBuffer;o.Init(new Int8Array(e),e.byteLength),this._disableAttributeTransforms(i);const n=this.decoder.GetEncodedGeometryType(o),r=n===this.draco.TRIANGULAR_MESH?new this.draco.Mesh:new this.draco.PointCloud;try{let a;switch(n){case this.draco.TRIANGULAR_MESH:a=this.decoder.DecodeBufferToMesh(o,r);break;case this.draco.POINT_CLOUD:a=this.decoder.DecodeBufferToPointCloud(o,r);break;default:throw new Error("DRACO: Unknown geometry type.")}if(!a.ok()||!r.ptr){const u=`DRACO decompression failed: ${a.error_msg()}`;throw new Error(u)}const s=this._getDracoLoaderData(r,n,i),l=this._getMeshData(r,s,i),c=sSt(l.attributes),d=iRt(l.attributes,s,l.indices);return{loader:"draco",loaderData:s,header:{vertexCount:r.num_points(),boundingBox:c},...l,schema:d}}finally{this.draco.destroy(o),r&&this.draco.destroy(r)}}_getDracoLoaderData(e,i,o){const n=this._getTopLevelMetadata(e),r=this._getDracoAttributes(e,o);return{geometry_type:i,num_attributes:e.num_attributes(),num_points:e.num_points(),num_faces:e instanceof this.draco.Mesh?e.num_faces():0,metadata:n,attributes:r}}_getDracoAttributes(e,i){const o={};for(let n=0;n<e.num_attributes();n++){const r=this.decoder.GetAttribute(e,n),a=this._getAttributeMetadata(e,n);o[r.unique_id()]={unique_id:r.unique_id(),attribute_type:r.attribute_type(),data_type:r.data_type(),num_components:r.num_components(),byte_offset:r.byte_offset(),byte_stride:r.byte_stride(),normalized:r.normalized(),attribute_index:n,metadata:a};const s=this._getQuantizationTransform(r,i);s&&(o[r.unique_id()].quantization_transform=s);const l=this._getOctahedronTransform(r,i);l&&(o[r.unique_id()].octahedron_transform=l)}return o}_getMeshData(e,i,o){const n=this._getMeshAttributes(i,e,o);if(!n.POSITION)throw new Error("DRACO: No position attribute found.");if(e instanceof this.draco.Mesh)switch(o.topology){case"triangle-strip":return{topology:"triangle-strip",mode:4,attributes:n,indices:{value:this._getTriangleStripIndices(e),size:1}};case"triangle-list":default:return{topology:"triangle-list",mode:5,attributes:n,indices:{value:this._getTriangleListIndices(e),size:1}}}return{topology:"point-list",mode:0,attributes:n}}_getMeshAttributes(e,i,o){const n={};for(const r of Object.values(e.attributes)){const a=this._deduceAttributeName(r,o);r.name=a;const s=this._getAttributeValues(i,r);if(s){const{value:l,size:c}=s;n[a]={value:l,size:c,byteOffset:r.byte_offset,byteStride:r.byte_stride,normalized:r.normalized}}}return n}_getTriangleListIndices(e){const i=e.num_faces()*3,o=i*nRt,n=this.draco._malloc(o);try{return this.decoder.GetTrianglesUInt32Array(e,o,n),new Uint32Array(this.draco.HEAPF32.buffer,n,i).slice()}finally{this.draco._free(n)}}_getTriangleStripIndices(e){const i=new this.draco.DracoInt32Array;try{return this.decoder.GetTriangleStripsFromMesh(e,i),cRt(i)}finally{this.draco.destroy(i)}}_getAttributeValues(e,i){const o=rRt[i.data_type];if(!o)return console.warn(`DRACO: Unsupported attribute type ${i.data_type}`),null;const n=i.num_components,r=e.num_points()*n,a=r*o.BYTES_PER_ELEMENT,s=sRt(this.draco,o);let l;const c=this.draco._malloc(a);try{const d=this.decoder.GetAttribute(e,i.attribute_index);this.decoder.GetAttributeDataArrayForAllPoints(e,d,s,a,c),l=new o(this.draco.HEAPF32.buffer,c,r).slice()}finally{this.draco._free(c)}return{value:l,size:n}}_deduceAttributeName(e,i){const o=e.unique_id;for(const[a,s]of Object.entries(i.extraAttributes||{}))if(s===o)return a;const n=e.attribute_type;for(const a in J$)if(this.draco[a]===n)return J$[a];const r=i.attributeNameEntry||"name";return e.metadata[r]?e.metadata[r].string:`CUSTOM_ATTRIBUTE_${o}`}_getTopLevelMetadata(e){const i=this.decoder.GetMetadata(e);return this._getDracoMetadata(i)}_getAttributeMetadata(e,i){const o=this.decoder.GetAttributeMetadata(e,i);return this._getDracoMetadata(o)}_getDracoMetadata(e){if(!e||!e.ptr)return{};const i={},o=this.metadataQuerier.NumEntries(e);for(let n=0;n<o;n++){const r=this.metadataQuerier.GetEntryName(e,n);i[r]=this._getDracoMetadataField(e,r)}return i}_getDracoMetadataField(e,i){const o=new this.draco.DracoInt32Array;try{this.metadataQuerier.GetIntEntryArray(e,i,o);const n=lRt(o);return{int:this.metadataQuerier.GetIntEntry(e,i),string:this.metadataQuerier.GetStringEntry(e,i),double:this.metadataQuerier.GetDoubleEntry(e,i),intArray:n}}finally{this.draco.destroy(o)}}_disableAttributeTransforms(e){const{quantizedAttributes:i=[],octahedronAttributes:o=[]}=e,n=[...i,...o];for(const r of n)this.decoder.SkipAttributeTransform(this.draco[r])}_getQuantizationTransform(e,i){const{quantizedAttributes:o=[]}=i,n=e.attribute_type();if(o.map(r=>this.decoder[r]).includes(n)){const r=new this.draco.AttributeQuantizationTransform;try{if(r.InitFromAttribute(e))return{quantization_bits:r.quantization_bits(),range:r.range(),min_values:new Float32Array([1,2,3]).map(a=>r.min_value(a))}}finally{this.draco.destroy(r)}}return null}_getOctahedronTransform(e,i){const{octahedronAttributes:o=[]}=i,n=e.attribute_type();if(o.map(r=>this.decoder[r]).includes(n)){const r=new this.draco.AttributeQuantizationTransform;try{if(r.InitFromAttribute(e))return{quantization_bits:r.quantization_bits()}}finally{this.draco.destroy(r)}}return null}}function sRt(t,e){switch(e){case Float32Array:return t.DT_FLOAT32;case Int8Array:return t.DT_INT8;case Int16Array:return t.DT_INT16;case Int32Array:return t.DT_INT32;case Uint8Array:return t.DT_UINT8;case Uint16Array:return t.DT_UINT16;case Uint32Array:return t.DT_UINT32;default:return t.DT_INVALID}}function lRt(t){const e=t.size(),i=new Int32Array(e);for(let o=0;o<e;o++)i[o]=t.GetValue(o);return i}function cRt(t){const e=t.size(),i=new Int32Array(e);for(let o=0;o<e;o++)i[o]=t.GetValue(o);return i}const dRt="1.5.6",uRt="1.4.1",nS=`https://www.gstatic.com/draco/versioned/decoders/${dRt}`,$n={DECODER:"draco_wasm_wrapper.js",DECODER_WASM:"draco_decoder.wasm",FALLBACK_DECODER:"draco_decoder.js",ENCODER:"draco_encoder.js"},aS={[$n.DECODER]:`${nS}/${$n.DECODER}`,[$n.DECODER_WASM]:`${nS}/${$n.DECODER_WASM}`,[$n.FALLBACK_DECODER]:`${nS}/${$n.FALLBACK_DECODER}`,[$n.ENCODER]:`https://raw.githubusercontent.com/google/draco/${uRt}/javascript/${$n.ENCODER}`};let sS;async function hRt(t){const e=t.modules||{};return e.draco3d?sS||=e.draco3d.createDecoderModule({}).then(i=>({draco:i})):sS||=pRt(t),await sS}async function pRt(t){let e,i;switch(t.draco&&t.draco.decoderType){case"js":e=await vh(aS[$n.FALLBACK_DECODER],"draco",t,$n.FALLBACK_DECODER);break;case"wasm":default:[e,i]=await Promise.all([await vh(aS[$n.DECODER],"draco",t,$n.DECODER),await vh(aS[$n.DECODER_WASM],"draco",t,$n.DECODER_WASM)])}return e=e||globalThis.DracoDecoderModule,await fRt(e,i)}function fRt(t,e){const i={};return e&&(i.wasmBinary=e),new Promise(o=>{t({...i,onModuleLoaded:n=>o({draco:n})})})}const ARt={...tRt,parse:gRt};async function gRt(t,e){const{draco:i}=await hRt(e),o=new aRt(i);try{return o.parseSync(t,e?.draco)}finally{o.destroy()}}function mRt(t){const e={};for(const i in t){const o=t[i];if(i!=="indices"){const n=Z$(o);e[i]=n}}return e}function Z$(t){const{buffer:e,size:i,count:o}=vRt(t);return{value:e,size:i,byteOffset:0,count:o,type:P$(i),componentType:A9(e)}}function vRt(t){let e=t,i=1,o=0;return t&&t.value&&(e=t.value,i=t.size||1),e&&(ArrayBuffer.isView(e)||(e=yRt(e,Float32Array)),o=e.length/i),{buffer:e,size:i,count:o}}function yRt(t,e,i=!1){return t?Array.isArray(t)?new e(t):i&&!(t instanceof e)?new e(t):t:null}const Od="KHR_draco_mesh_compression",bRt=Od;function wRt(t,e,i){const o=new Er(t);for(const n of W$(o))o.getObjectExtension(n,Od)}async function CRt(t,e,i){if(!e?.gltf?.decompressMeshes)return;const o=new Er(t),n=[];for(const r of W$(o))o.getObjectExtension(r,Od)&&n.push(kRt(o,r,e,i));await Promise.all(n),o.removeExtension(Od)}function xRt(t,e={}){const i=new Er(t);for(const o of i.json.meshes||[])MRt(o),i.addRequiredExtension(Od)}async function kRt(t,e,i,o){const n=t.getObjectExtension(e,Od);if(!n)return;const r=t.getTypedArrayForBufferView(n.bufferView),a=ZX(r.buffer,r.byteOffset),s={...i};delete s["3d-tiles"];const l=await DX(a,ARt,s,o),c=mRt(l.attributes);for(const[d,u]of Object.entries(c))if(d in e.attributes){const h=e.attributes[d],p=t.getAccessor(h);p?.min&&p?.max&&(u.min=p.min,u.max=p.max)}e.attributes=c,l.indices&&(e.indices=Z$(l.indices)),t.removeObjectExtension(e,Od),BRt(e)}function MRt(t,e,i=4,o,n){if(!o.DracoWriter)throw new Error("options.gltf.DracoWriter not provided");const r=o.DracoWriter.encodeSync({attributes:t}),a=n?.parseSync?.({attributes:t}),s=o._addFauxAttributes(a.attributes),l=o.addBufferView(r);return{primitives:[{attributes:s,mode:i,extensions:{[Od]:{bufferView:l,attributes:s}}}]}}function BRt(t){if(!t.attributes&&Object.keys(t.attributes).length>0)throw new Error("glTF: Empty primitive detected: Draco decompression failure?")}function*W$(t){for(const e of t.json.meshes||[])for(const i of e.primitives)yield i}const ERt=Object.freeze(Object.defineProperty({__proto__:null,decode:CRt,encode:xRt,name:bRt,preprocess:wRt},Symbol.toStringTag,{value:"Module"})),PRt={EPSILON:1e-12,debug:!1,precision:4,printTypes:!1,printDegrees:!1,printRowMajor:!0,_cartographicRadians:!1};globalThis.mathgl=globalThis.mathgl||{config:{...PRt}};const Qa=globalThis.mathgl.config;function IRt(t,{precision:e=Qa.precision}={}){return t=SRt(t),`${parseFloat(t.toPrecision(e))}`}function x9(t){return Array.isArray(t)||ArrayBuffer.isView(t)&&!(t instanceof DataView)}function Y$(t,e,i){const o=Qa.EPSILON;try{if(t===e)return!0;if(x9(t)&&x9(e)){if(t.length!==e.length)return!1;for(let n=0;n<t.length;++n)if(!Y$(t[n],e[n]))return!1;return!0}return t&&t.equals?t.equals(e):e&&e.equals?e.equals(t):typeof t=="number"&&typeof e=="number"?Math.abs(t-e)<=Qa.EPSILON*Math.max(1,Math.abs(t),Math.abs(e)):!1}finally{Qa.EPSILON=o}}function SRt(t){return Math.round(t/Qa.EPSILON)*Qa.EPSILON}class X$ extends Array{clone(){return new this.constructor().copy(this)}fromArray(e,i=0){for(let o=0;o<this.ELEMENTS;++o)this[o]=e[o+i];return this.check()}toArray(e=[],i=0){for(let o=0;o<this.ELEMENTS;++o)e[i+o]=this[o];return e}toObject(e){return e}from(e){return Array.isArray(e)?this.copy(e):this.fromObject(e)}to(e){return e===this?this:x9(e)?this.toArray(e):this.toObject(e)}toTarget(e){return e?this.to(e):this}toFloat32Array(){return new Float32Array(this)}toString(){return this.formatString(Qa)}formatString(e){let i="";for(let o=0;o<this.ELEMENTS;++o)i+=(o>0?", ":"")+IRt(this[o],e);return`${e.printTypes?this.constructor.name:""}[${i}]`}equals(e){if(!e||this.length!==e.length)return!1;for(let i=0;i<this.ELEMENTS;++i)if(!Y$(this[i],e[i]))return!1;return!0}exactEquals(e){if(!e||this.length!==e.length)return!1;for(let i=0;i<this.ELEMENTS;++i)if(this[i]!==e[i])return!1;return!0}negate(){for(let e=0;e<this.ELEMENTS;++e)this[e]=-this[e];return this.check()}lerp(e,i,o){if(o===void 0)return this.lerp(this,e,i);for(let n=0;n<this.ELEMENTS;++n){const r=e[n],a=typeof i=="number"?i:i[n];this[n]=r+o*(a-r)}return this.check()}min(e){for(let i=0;i<this.ELEMENTS;++i)this[i]=Math.min(e[i],this[i]);return this.check()}max(e){for(let i=0;i<this.ELEMENTS;++i)this[i]=Math.max(e[i],this[i]);return this.check()}clamp(e,i){for(let o=0;o<this.ELEMENTS;++o)this[o]=Math.min(Math.max(this[o],e[o]),i[o]);return this.check()}add(...e){for(const i of e)for(let o=0;o<this.ELEMENTS;++o)this[o]+=i[o];return this.check()}subtract(...e){for(const i of e)for(let o=0;o<this.ELEMENTS;++o)this[o]-=i[o];return this.check()}scale(e){if(typeof e=="number")for(let i=0;i<this.ELEMENTS;++i)this[i]*=e;else for(let i=0;i<this.ELEMENTS&&i<e.length;++i)this[i]*=e[i];return this.check()}multiplyByScalar(e){for(let i=0;i<this.ELEMENTS;++i)this[i]*=e;return this.check()}check(){if(Qa.debug&&!this.validate())throw new Error(`math.gl: ${this.constructor.name} some fields set to invalid numbers'`);return this}validate(){let e=this.length===this.ELEMENTS;for(let i=0;i<this.ELEMENTS;++i)e=e&&Number.isFinite(this[i]);return e}sub(e){return this.subtract(e)}setScalar(e){for(let i=0;i<this.ELEMENTS;++i)this[i]=e;return this.check()}addScalar(e){for(let i=0;i<this.ELEMENTS;++i)this[i]+=e;return this.check()}subScalar(e){return this.addScalar(-e)}multiplyScalar(e){for(let i=0;i<this.ELEMENTS;++i)this[i]*=e;return this.check()}divideScalar(e){return this.multiplyByScalar(1/e)}clampScalar(e,i){for(let o=0;o<this.ELEMENTS;++o)this[o]=Math.min(Math.max(this[o],e),i);return this.check()}get elements(){return this}}function TRt(t,e){if(t.length!==e)return!1;for(let i=0;i<t.length;++i)if(!Number.isFinite(t[i]))return!1;return!0}function wa(t){if(!Number.isFinite(t))throw new Error(`Invalid number ${JSON.stringify(t)}`);return t}function DRt(t,e,i=""){if(Qa.debug&&!TRt(t,e))throw new Error(`math.gl: ${i} some fields set to invalid numbers'`);return t}function $$(t,e){if(!t)throw new Error(`math.gl assertion ${e}`)}class RRt extends X${get x(){return this[0]}set x(e){this[0]=wa(e)}get y(){return this[1]}set y(e){this[1]=wa(e)}len(){return Math.sqrt(this.lengthSquared())}magnitude(){return this.len()}lengthSquared(){let e=0;for(let i=0;i<this.ELEMENTS;++i)e+=this[i]*this[i];return e}magnitudeSquared(){return this.lengthSquared()}distance(e){return Math.sqrt(this.distanceSquared(e))}distanceSquared(e){let i=0;for(let o=0;o<this.ELEMENTS;++o){const n=this[o]-e[o];i+=n*n}return wa(i)}dot(e){let i=0;for(let o=0;o<this.ELEMENTS;++o)i+=this[o]*e[o];return wa(i)}normalize(){const e=this.magnitude();if(e!==0)for(let i=0;i<this.ELEMENTS;++i)this[i]/=e;return this.check()}multiply(...e){for(const i of e)for(let o=0;o<this.ELEMENTS;++o)this[o]*=i[o];return this.check()}divide(...e){for(const i of e)for(let o=0;o<this.ELEMENTS;++o)this[o]/=i[o];return this.check()}lengthSq(){return this.lengthSquared()}distanceTo(e){return this.distance(e)}distanceToSquared(e){return this.distanceSquared(e)}getComponent(e){return $$(e>=0&&e<this.ELEMENTS,"index is out of range"),wa(this[e])}setComponent(e,i){return $$(e>=0&&e<this.ELEMENTS,"index is out of range"),this[e]=i,this.check()}addVectors(e,i){return this.copy(e).add(i)}subVectors(e,i){return this.copy(e).subtract(i)}multiplyVectors(e,i){return this.copy(e).multiply(i)}addScaledVector(e,i){return this.add(new this.constructor(e).multiplyScalar(i))}}let k9=typeof Float32Array<"u"?Float32Array:Array;function LRt(){const t=new k9(2);return k9!=Float32Array&&(t[0]=0,t[1]=0),t}function _Rt(t,e,i){const o=e[0],n=e[1];return t[0]=i[0]*o+i[3]*n+i[6],t[1]=i[1]*o+i[4]*n+i[7],t}(function(){const t=LRt();return function(e,i,o,n,r,a){let s,l;for(i||(i=2),o||(o=0),n?l=Math.min(n*i+o,e.length):l=e.length,s=o;s<l;s+=i)t[0]=e[s],t[1]=e[s+1],r(t,t,a),e[s]=t[0],e[s+1]=t[1];return e}})();function FRt(t,e,i){const o=e[0],n=e[1],r=e[2],a=i[3]*o+i[7]*n+i[11]*r||1;return t[0]=(i[0]*o+i[4]*n+i[8]*r)/a,t[1]=(i[1]*o+i[5]*n+i[9]*r)/a,t[2]=(i[2]*o+i[6]*n+i[10]*r)/a,t}function ORt(t,e,i){const o=e[0],n=e[1];return t[0]=i[0]*o+i[2]*n,t[1]=i[1]*o+i[3]*n,t[2]=e[2],t}function URt(t,e,i){const o=e[0],n=e[1],r=e[2];return t[0]=i[0]*o+i[3]*n+i[6]*r,t[1]=i[1]*o+i[4]*n+i[7]*r,t[2]=i[2]*o+i[5]*n+i[8]*r,t[3]=e[3],t}function NRt(){const t=new k9(3);return k9!=Float32Array&&(t[0]=0,t[1]=0,t[2]=0),t}function jRt(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]}function VRt(t,e,i){const o=e[0],n=e[1],r=e[2],a=i[0],s=i[1],l=i[2];return t[0]=n*l-r*s,t[1]=r*a-o*l,t[2]=o*s-n*a,t}function HRt(t,e,i){const o=e[0],n=e[1],r=e[2];let a=i[3]*o+i[7]*n+i[11]*r+i[15];return a=a||1,t[0]=(i[0]*o+i[4]*n+i[8]*r+i[12])/a,t[1]=(i[1]*o+i[5]*n+i[9]*r+i[13])/a,t[2]=(i[2]*o+i[6]*n+i[10]*r+i[14])/a,t}function eee(t,e,i){const o=e[0],n=e[1],r=e[2];return t[0]=o*i[0]+n*i[3]+r*i[6],t[1]=o*i[1]+n*i[4]+r*i[7],t[2]=o*i[2]+n*i[5]+r*i[8],t}function zRt(t,e,i){const o=i[0],n=i[1],r=i[2],a=i[3],s=e[0],l=e[1],c=e[2];let d=n*c-r*l,u=r*s-o*c,h=o*l-n*s,p=n*h-r*u,A=r*d-o*h,f=o*u-n*d;const m=a*2;return d*=m,u*=m,h*=m,p*=2,A*=2,f*=2,t[0]=s+d+p,t[1]=l+u+A,t[2]=c+h+f,t}function qRt(t,e,i,o){const n=[],r=[];return n[0]=e[0]-i[0],n[1]=e[1]-i[1],n[2]=e[2]-i[2],r[0]=n[0],r[1]=n[1]*Math.cos(o)-n[2]*Math.sin(o),r[2]=n[1]*Math.sin(o)+n[2]*Math.cos(o),t[0]=r[0]+i[0],t[1]=r[1]+i[1],t[2]=r[2]+i[2],t}function QRt(t,e,i,o){const n=[],r=[];return n[0]=e[0]-i[0],n[1]=e[1]-i[1],n[2]=e[2]-i[2],r[0]=n[2]*Math.sin(o)+n[0]*Math.cos(o),r[1]=n[1],r[2]=n[2]*Math.cos(o)-n[0]*Math.sin(o),t[0]=r[0]+i[0],t[1]=r[1]+i[1],t[2]=r[2]+i[2],t}function GRt(t,e,i,o){const n=[],r=[];return n[0]=e[0]-i[0],n[1]=e[1]-i[1],n[2]=e[2]-i[2],r[0]=n[0]*Math.cos(o)-n[1]*Math.sin(o),r[1]=n[0]*Math.sin(o)+n[1]*Math.cos(o),r[2]=n[2],t[0]=r[0]+i[0],t[1]=r[1]+i[1],t[2]=r[2]+i[2],t}function KRt(t,e){const i=t[0],o=t[1],n=t[2],r=e[0],a=e[1],s=e[2],l=Math.sqrt((i*i+o*o+n*n)*(r*r+a*a+s*s)),c=l&&jRt(t,e)/l;return Math.acos(Math.min(Math.max(c,-1),1))}(function(){const t=NRt();return function(e,i,o,n,r,a){let s,l;for(i||(i=3),o||(o=0),n?l=Math.min(n*i+o,e.length):l=e.length,s=o;s<l;s+=i)t[0]=e[s],t[1]=e[s+1],t[2]=e[s+2],r(t,t,a),e[s]=t[0],e[s+1]=t[1],e[s+2]=t[2];return e}})();const lS=[0,0,0];let M9,JRt=class eAe extends RRt{static get ZERO(){return M9||(M9=new eAe(0,0,0),Object.freeze(M9)),M9}constructor(e=0,i=0,o=0){super(-0,-0,-0),arguments.length===1&&x9(e)?this.copy(e):(Qa.debug&&(wa(e),wa(i),wa(o)),this[0]=e,this[1]=i,this[2]=o)}set(e,i,o){return this[0]=e,this[1]=i,this[2]=o,this.check()}copy(e){return this[0]=e[0],this[1]=e[1],this[2]=e[2],this.check()}fromObject(e){return Qa.debug&&(wa(e.x),wa(e.y),wa(e.z)),this[0]=e.x,this[1]=e.y,this[2]=e.z,this.check()}toObject(e){return e.x=this[0],e.y=this[1],e.z=this[2],e}get ELEMENTS(){return 3}get z(){return this[2]}set z(e){this[2]=wa(e)}angle(e){return KRt(this,e)}cross(e){return VRt(this,this,e),this.check()}rotateX({radians:e,origin:i=lS}){return qRt(this,this,i,e),this.check()}rotateY({radians:e,origin:i=lS}){return QRt(this,this,i,e),this.check()}rotateZ({radians:e,origin:i=lS}){return GRt(this,this,i,e),this.check()}transform(e){return this.transformAsPoint(e)}transformAsPoint(e){return HRt(this,this,e),this.check()}transformAsVector(e){return FRt(this,this,e),this.check()}transformByMatrix3(e){return eee(this,this,e),this.check()}transformByMatrix2(e){return ORt(this,this,e),this.check()}transformByQuaternion(e){return zRt(this,this,e),this.check()}};class ZRt extends X${toString(){let e="[";if(Qa.printRowMajor){e+="row-major:";for(let i=0;i<this.RANK;++i)for(let o=0;o<this.RANK;++o)e+=` ${this[o*this.RANK+i]}`}else{e+="column-major:";for(let i=0;i<this.ELEMENTS;++i)e+=` ${this[i]}`}return e+="]",e}getElementIndex(e,i){return i*this.RANK+e}getElement(e,i){return this[i*this.RANK+e]}setElement(e,i,o){return this[i*this.RANK+e]=wa(o),this}getColumn(e,i=new Array(this.RANK).fill(-0)){const o=e*this.RANK;for(let n=0;n<this.RANK;++n)i[n]=this[o+n];return i}setColumn(e,i){const o=e*this.RANK;for(let n=0;n<this.RANK;++n)this[o+n]=i[n];return this}}function WRt(t,e){if(t===e){const i=e[1],o=e[2],n=e[5];t[1]=e[3],t[2]=e[6],t[3]=i,t[5]=e[7],t[6]=o,t[7]=n}else t[0]=e[0],t[1]=e[3],t[2]=e[6],t[3]=e[1],t[4]=e[4],t[5]=e[7],t[6]=e[2],t[7]=e[5],t[8]=e[8];return t}function YRt(t,e){const i=e[0],o=e[1],n=e[2],r=e[3],a=e[4],s=e[5],l=e[6],c=e[7],d=e[8],u=d*a-s*c,h=-d*r+s*l,p=c*r-a*l;let A=i*u+o*h+n*p;return A?(A=1/A,t[0]=u*A,t[1]=(-d*o+n*c)*A,t[2]=(s*o-n*a)*A,t[3]=h*A,t[4]=(d*i-n*l)*A,t[5]=(-s*i+n*r)*A,t[6]=p*A,t[7]=(-c*i+o*l)*A,t[8]=(a*i-o*r)*A,t):null}function XRt(t){const e=t[0],i=t[1],o=t[2],n=t[3],r=t[4],a=t[5],s=t[6],l=t[7],c=t[8];return e*(c*r-a*l)+i*(-c*n+a*s)+o*(l*n-r*s)}function tee(t,e,i){const o=e[0],n=e[1],r=e[2],a=e[3],s=e[4],l=e[5],c=e[6],d=e[7],u=e[8],h=i[0],p=i[1],A=i[2],f=i[3],m=i[4],g=i[5],y=i[6],v=i[7],w=i[8];return t[0]=h*o+p*a+A*c,t[1]=h*n+p*s+A*d,t[2]=h*r+p*l+A*u,t[3]=f*o+m*a+g*c,t[4]=f*n+m*s+g*d,t[5]=f*r+m*l+g*u,t[6]=y*o+v*a+w*c,t[7]=y*n+v*s+w*d,t[8]=y*r+v*l+w*u,t}function $Rt(t,e,i){const o=e[0],n=e[1],r=e[2],a=e[3],s=e[4],l=e[5],c=e[6],d=e[7],u=e[8],h=i[0],p=i[1];return t[0]=o,t[1]=n,t[2]=r,t[3]=a,t[4]=s,t[5]=l,t[6]=h*o+p*a+c,t[7]=h*n+p*s+d,t[8]=h*r+p*l+u,t}function eLt(t,e,i){const o=e[0],n=e[1],r=e[2],a=e[3],s=e[4],l=e[5],c=e[6],d=e[7],u=e[8],h=Math.sin(i),p=Math.cos(i);return t[0]=p*o+h*a,t[1]=p*n+h*s,t[2]=p*r+h*l,t[3]=p*a-h*o,t[4]=p*s-h*n,t[5]=p*l-h*r,t[6]=c,t[7]=d,t[8]=u,t}function iee(t,e,i){const o=i[0],n=i[1];return t[0]=o*e[0],t[1]=o*e[1],t[2]=o*e[2],t[3]=n*e[3],t[4]=n*e[4],t[5]=n*e[5],t[6]=e[6],t[7]=e[7],t[8]=e[8],t}function tLt(t,e){const i=e[0],o=e[1],n=e[2],r=e[3],a=i+i,s=o+o,l=n+n,c=i*a,d=o*a,u=o*s,h=n*a,p=n*s,A=n*l,f=r*a,m=r*s,g=r*l;return t[0]=1-u-A,t[3]=d-g,t[6]=h+m,t[1]=d+g,t[4]=1-c-A,t[7]=p-f,t[2]=h-m,t[5]=p+f,t[8]=1-c-u,t}var cS;(function(t){t[t.COL0ROW0=0]="COL0ROW0",t[t.COL0ROW1=1]="COL0ROW1",t[t.COL0ROW2=2]="COL0ROW2",t[t.COL1ROW0=3]="COL1ROW0",t[t.COL1ROW1=4]="COL1ROW1",t[t.COL1ROW2=5]="COL1ROW2",t[t.COL2ROW0=6]="COL2ROW0",t[t.COL2ROW1=7]="COL2ROW1",t[t.COL2ROW2=8]="COL2ROW2"})(cS||(cS={}));const iLt=Object.freeze([1,0,0,0,1,0,0,0,1]);let L3=class extends ZRt{static get IDENTITY(){return rLt()}static get ZERO(){return oLt()}get ELEMENTS(){return 9}get RANK(){return 3}get INDICES(){return cS}constructor(t,...e){super(-0,-0,-0,-0,-0,-0,-0,-0,-0),arguments.length===1&&Array.isArray(t)?this.copy(t):e.length>0?this.copy([t,...e]):this.identity()}copy(t){return this[0]=t[0],this[1]=t[1],this[2]=t[2],this[3]=t[3],this[4]=t[4],this[5]=t[5],this[6]=t[6],this[7]=t[7],this[8]=t[8],this.check()}identity(){return this.copy(iLt)}fromObject(t){return this.check()}fromQuaternion(t){return tLt(this,t),this.check()}set(t,e,i,o,n,r,a,s,l){return this[0]=t,this[1]=e,this[2]=i,this[3]=o,this[4]=n,this[5]=r,this[6]=a,this[7]=s,this[8]=l,this.check()}setRowMajor(t,e,i,o,n,r,a,s,l){return this[0]=t,this[1]=o,this[2]=a,this[3]=e,this[4]=n,this[5]=s,this[6]=i,this[7]=r,this[8]=l,this.check()}determinant(){return XRt(this)}transpose(){return WRt(this,this),this.check()}invert(){return YRt(this,this),this.check()}multiplyLeft(t){return tee(this,t,this),this.check()}multiplyRight(t){return tee(this,this,t),this.check()}rotate(t){return eLt(this,this,t),this.check()}scale(t){return Array.isArray(t)?iee(this,this,t):iee(this,this,[t,t]),this.check()}translate(t){return $Rt(this,this,t),this.check()}transform(t,e){let i;switch(t.length){case 2:i=_Rt(e||[-0,-0],t,this);break;case 3:i=eee(e||[-0,-0,-0],t,this);break;case 4:i=URt(e||[-0,-0,-0,-0],t,this);break;default:throw new Error("Illegal vector")}return DRt(i,t.length),i}transformVector(t,e){return this.transform(t,e)}transformVector2(t,e){return this.transform(t,e)}transformVector3(t,e){return this.transform(t,e)}},B9,E9=null;function oLt(){return B9||(B9=new L3([0,0,0,0,0,0,0,0,0]),Object.freeze(B9)),B9}function rLt(){return E9||(E9=new L3,Object.freeze(E9)),E9}const P9="KHR_texture_transform",nLt=P9,I9=new JRt,aLt=new L3,sLt=new L3;async function lLt(t,e){if(!new Er(t).hasExtension(P9)||!e.gltf?.loadBuffers)return;const i=t.json.materials||[];for(let o=0;o<i.length;o++)cLt(o,t)}function cLt(t,e){const i=e.json.materials?.[t],o=[i?.pbrMetallicRoughness?.baseColorTexture,i?.emissiveTexture,i?.normalTexture,i?.occlusionTexture,i?.pbrMetallicRoughness?.metallicRoughnessTexture],n=[];for(const r of o)r&&r?.extensions?.[P9]&&dLt(e,t,r,n)}function dLt(t,e,i,o){const n=uLt(i,o);if(!n)return;const r=t.json.meshes||[];for(const a of r)for(const s of a.primitives){const l=s.material;Number.isFinite(l)&&e===l&&hLt(t,s,n)}}function uLt(t,e){const i=t.extensions?.[P9],{texCoord:o=0}=t,{texCoord:n=o}=i;if(e.findIndex(([r,a])=>r===o&&a===n)===-1){const r=ALt(i);return o!==n&&(t.texCoord=n),e.push([o,n]),{originalTexCoord:o,texCoord:n,matrix:r}}return null}function hLt(t,e,i){const{originalTexCoord:o,texCoord:n,matrix:r}=i,a=e.attributes[`TEXCOORD_${o}`];if(Number.isFinite(a)){const s=t.json.accessors?.[a];if(s&&s.bufferView){const l=t.json.bufferViews?.[s.bufferView];if(l){const{arrayBuffer:c,byteOffset:d}=t.buffers[l.buffer],u=(d||0)+(s.byteOffset||0)+(l.byteOffset||0),{ArrayType:h,length:p}=JI(s,l),A=B$[s.componentType],f=M$[s.type],m=l.byteStride||A*f,g=new Float32Array(p);for(let y=0;y<s.count;y++){const v=new h(c,u+y*m,2);I9.set(v[0],v[1],1),I9.transformByMatrix3(r),g.set([I9[0],I9[1]],y*f)}o===n?pLt(s,l,t.buffers,g):fLt(n,s,e,t,g)}}}}function pLt(t,e,i,o){t.componentType=5126,i.push({arrayBuffer:o.buffer,byteOffset:0,byteLength:o.buffer.byteLength}),e.buffer=i.length-1,e.byteLength=o.buffer.byteLength,e.byteOffset=0,delete e.byteStride}function fLt(t,e,i,o,n){o.buffers.push({arrayBuffer:n.buffer,byteOffset:0,byteLength:n.buffer.byteLength});const r=o.json.bufferViews;if(!r)return;r.push({buffer:o.buffers.length-1,byteLength:n.buffer.byteLength,byteOffset:0});const a=o.json.accessors;a&&(a.push({bufferView:r?.length-1,byteOffset:0,componentType:5126,count:e.count,type:"VEC2"}),i.attributes[`TEXCOORD_${t}`]=a.length-1)}function ALt(t){const{offset:e=[0,0],rotation:i=0,scale:o=[1,1]}=t,n=new L3().set(1,0,0,0,1,0,e[0],e[1],1),r=aLt.set(Math.cos(i),Math.sin(i),0,-Math.sin(i),Math.cos(i),0,0,0,1),a=sLt.set(o[0],0,0,0,o[1],0,0,0,1);return n.multiplyRight(r).multiplyRight(a)}const gLt=Object.freeze(Object.defineProperty({__proto__:null,decode:lLt,name:nLt},Symbol.toStringTag,{value:"Module"})),bh="KHR_lights_punctual",mLt=bh;async function vLt(t){const e=new Er(t),{json:i}=e,o=e.getExtension(bh);o&&(e.json.lights=o.lights,e.removeExtension(bh));for(const n of i.nodes||[]){const r=e.getObjectExtension(n,bh);r&&(n.light=r.light),e.removeObjectExtension(n,bh)}}async function yLt(t){const e=new Er(t),{json:i}=e;if(i.lights){const o=e.addExtension(bh);ya(!o.lights),o.lights=i.lights,delete i.lights}if(e.json.lights){for(const o of e.json.lights){const n=o.node;e.addObjectExtension(n,bh,o)}delete e.json.lights}}const bLt=Object.freeze(Object.defineProperty({__proto__:null,decode:vLt,encode:yLt,name:mLt},Symbol.toStringTag,{value:"Module"})),_3="KHR_materials_unlit",wLt=_3;async function CLt(t){const e=new Er(t),{json:i}=e;for(const o of i.materials||[])o.extensions&&o.extensions.KHR_materials_unlit&&(o.unlit=!0),e.removeObjectExtension(o,_3);e.removeExtension(_3)}function xLt(t){const e=new Er(t),{json:i}=e;if(e.materials)for(const o of i.materials||[])o.unlit&&(delete o.unlit,e.addObjectExtension(o,_3,{}),e.addExtension(_3))}const kLt=Object.freeze(Object.defineProperty({__proto__:null,decode:CLt,encode:xLt,name:wLt},Symbol.toStringTag,{value:"Module"})),F3="KHR_techniques_webgl",MLt=F3;async function BLt(t){const e=new Er(t),{json:i}=e,o=e.getExtension(F3);if(o){const n=PLt(o,e);for(const r of i.materials||[]){const a=e.getObjectExtension(r,F3);a&&(r.technique=Object.assign({},a,n[a.technique]),r.technique.values=ILt(r.technique,e)),e.removeObjectExtension(r,F3)}e.removeExtension(F3)}}async function ELt(t,e){}function PLt(t,e){const{programs:i=[],shaders:o=[],techniques:n=[]}=t,r=new TextDecoder;return o.forEach(a=>{if(Number.isFinite(a.bufferView))a.code=r.decode(e.getTypedArrayForBufferView(a.bufferView));else throw new Error("KHR_techniques_webgl: no shader code")}),i.forEach(a=>{a.fragmentShader=o[a.fragmentShader],a.vertexShader=o[a.vertexShader]}),n.forEach(a=>{a.program=i[a.program]}),n}function ILt(t,e){const i=Object.assign({},t.values);return Object.keys(t.uniforms||{}).forEach(o=>{t.uniforms[o].value&&!(o in i)&&(i[o]=t.uniforms[o].value)}),Object.keys(i).forEach(o=>{typeof i[o]=="object"&&i[o].index!==void 0&&(i[o].texture=e.getTexture(i[o].index))}),i}const SLt=Object.freeze(Object.defineProperty({__proto__:null,decode:BLt,encode:ELt,name:MLt},Symbol.toStringTag,{value:"Module"})),oee=[HTt,pTt,KDt,WDt,$Dt,ERt,bLt,kLt,SLt,gLt,nDt];function TLt(t,e={},i){const o=oee.filter(n=>ree(n.name,e));for(const n of o)n.preprocess?.(t,e,i)}async function DLt(t,e={},i){const o=oee.filter(n=>ree(n.name,e));for(const n of o)await n.decode?.(t,e,i)}function ree(t,e){const i=e?.gltf?.excludeExtensions||{};return!(t in i&&!i[t])}const dS="KHR_binary_glTF";function RLt(t){const e=new Er(t),{json:i}=e;for(const o of i.images||[]){const n=e.getObjectExtension(o,dS);n&&Object.assign(o,n),e.removeObjectExtension(o,dS)}i.buffers&&i.buffers[0]&&delete i.buffers[0].uri,e.removeExtension(dS)}const nee={accessors:"accessor",animations:"animation",buffers:"buffer",bufferViews:"bufferView",images:"image",materials:"material",meshes:"mesh",nodes:"node",samplers:"sampler",scenes:"scene",skins:"skin",textures:"texture"},LLt={accessor:"accessors",animations:"animation",buffer:"buffers",bufferView:"bufferViews",image:"images",material:"materials",mesh:"meshes",node:"nodes",sampler:"samplers",scene:"scenes",skin:"skins",texture:"textures"};class _Lt{idToIndexMap={animations:{},accessors:{},buffers:{},bufferViews:{},images:{},materials:{},meshes:{},nodes:{},samplers:{},scenes:{},skins:{},textures:{}};json;normalize(e,i){this.json=e.json;const o=e.json;switch(o.asset&&o.asset.version){case"2.0":return;case void 0:case"1.0":break;default:console.warn(`glTF: Unknown version ${o.asset.version}`);return}if(!i.normalize)throw new Error("glTF v1 is not supported.");console.warn("Converting glTF v1 to glTF v2 format. This is experimental and may fail."),this._addAsset(o),this._convertTopLevelObjectsToArrays(o),RLt(e),this._convertObjectIdsToArrayIndices(o),this._updateObjects(o),this._updateMaterial(o)}_addAsset(e){e.asset=e.asset||{},e.asset.version="2.0",e.asset.generator=e.asset.generator||"Normalized to glTF 2.0 by loaders.gl"}_convertTopLevelObjectsToArrays(e){for(const i in nee)this._convertTopLevelObjectToArray(e,i)}_convertTopLevelObjectToArray(e,i){const o=e[i];if(!(!o||Array.isArray(o))){e[i]=[];for(const n in o){const r=o[n];r.id=r.id||n;const a=e[i].length;e[i].push(r),this.idToIndexMap[i][n]=a}}}_convertObjectIdsToArrayIndices(e){for(const i in nee)this._convertIdsToIndices(e,i);"scene"in e&&(e.scene=this._convertIdToIndex(e.scene,"scene"));for(const i of e.textures)this._convertTextureIds(i);for(const i of e.meshes)this._convertMeshIds(i);for(const i of e.nodes)this._convertNodeIds(i);for(const i of e.scenes)this._convertSceneIds(i)}_convertTextureIds(e){e.source&&(e.source=this._convertIdToIndex(e.source,"image"))}_convertMeshIds(e){for(const i of e.primitives){const{attributes:o,indices:n,material:r}=i;for(const a in o)o[a]=this._convertIdToIndex(o[a],"accessor");n&&(i.indices=this._convertIdToIndex(n,"accessor")),r&&(i.material=this._convertIdToIndex(r,"material"))}}_convertNodeIds(e){e.children&&(e.children=e.children.map(i=>this._convertIdToIndex(i,"node"))),e.meshes&&(e.meshes=e.meshes.map(i=>this._convertIdToIndex(i,"mesh")))}_convertSceneIds(e){e.nodes&&(e.nodes=e.nodes.map(i=>this._convertIdToIndex(i,"node")))}_convertIdsToIndices(e,i){e[i]||(console.warn(`gltf v1: json doesn't contain attribute ${i}`),e[i]=[]);for(const o of e[i])for(const n in o){const r=o[n],a=this._convertIdToIndex(r,n);o[n]=a}}_convertIdToIndex(e,i){const o=LLt[i];if(o in this.idToIndexMap){const n=this.idToIndexMap[o][e];if(!Number.isFinite(n))throw new Error(`gltf v1: failed to resolve ${i} with id ${e}`);return n}return e}_updateObjects(e){for(const i of this.json.buffers)delete i.type}_updateMaterial(e){for(const i of e.materials){i.pbrMetallicRoughness={baseColorFactor:[1,1,1,1],metallicFactor:1,roughnessFactor:1};const o=i.values?.tex||i.values?.texture2d_0||i.values?.diffuseTex,n=e.textures.findIndex(r=>r.id===o);n!==-1&&(i.pbrMetallicRoughness.baseColorTexture={index:n})}}}function FLt(t,e={}){return new _Lt().normalize(t,e)}async function OLt(t,e,i=0,o,n){return ULt(t,e,i,o),FLt(t,{normalize:o?.gltf?.normalize}),TLt(t,o,n),o?.gltf?.loadBuffers&&t.json.buffers&&await NLt(t,o,n),o?.gltf?.loadImages&&await jLt(t,o,n),await DLt(t,o,n),t}function ULt(t,e,i,o){if(o.uri&&(t.baseUri=o.uri),e instanceof ArrayBuffer&&!PDt(e,i,o)&&(e=new TextDecoder().decode(e)),typeof e=="string")t.json=WPt(e);else if(e instanceof ArrayBuffer){const a={};i=IDt(a,e,i,o.glb),ya(a.type==="glTF",`Invalid GLB magic string ${a.type}`),t._glb=a,t.json=a.json}else ya(!1,"GLTF: must be ArrayBuffer or string");const n=t.json.buffers||[];if(t.buffers=new Array(n.length).fill(null),t._glb&&t._glb.header.hasBinChunk){const{binChunks:a}=t._glb;t.buffers[0]={arrayBuffer:a[0].arrayBuffer,byteOffset:a[0].byteOffset,byteLength:a[0].byteLength}}const r=t.json.images||[];t.images=new Array(r.length).fill({})}async function NLt(t,e,i){const o=t.json.buffers||[];for(let n=0;n<o.length;++n){const r=o[n];if(r.uri){const{fetch:a}=i;ya(a);const s=Q$(r.uri,e),l=await(await i?.fetch?.(s))?.arrayBuffer?.();t.buffers[n]={arrayBuffer:l,byteOffset:0,byteLength:l.byteLength},delete r.uri}else t.buffers[n]===null&&(t.buffers[n]={arrayBuffer:new ArrayBuffer(r.byteLength),byteOffset:0,byteLength:r.byteLength})}}async function jLt(t,e,i){const o=VLt(t),n=t.json.images||[],r=[];for(const a of o)r.push(HLt(t,n[a],a,e,i));return await Promise.all(r)}function VLt(t){const e=new Set,i=t.json.textures||[];for(const o of i)o.source!==void 0&&e.add(o.source);return Array.from(e).sort()}async function HLt(t,e,i,o,n){let r;if(e.uri&&!e.hasOwnProperty("bufferView")){const s=Q$(e.uri,o),{fetch:l}=n;r=await(await l(s)).arrayBuffer(),e.bufferView={data:r}}if(Number.isFinite(e.bufferView)){const s=XSt(t.json,t.buffers,e.bufferView);r=ZX(s.buffer,s.byteOffset,s.byteLength)}ya(r,"glTF image has no data");let a=await DX(r,[HSt,wDt],{...o,mimeType:e.mimeType,basis:o.basis||{format:z$()}},n);a&&a[0]&&(a={compressed:!0,mipmaps:!1,width:a[0].width,height:a[0].height,data:a[0]}),t.images=t.images||[],t.images[i]=a}const uS={dataType:null,batchType:null,name:"glTF",id:"gltf",module:"gltf",version:aDt,extensions:["gltf","glb"],mimeTypes:["model/gltf+json","model/gltf-binary"],text:!0,binary:!0,tests:["glTF"],parse:zLt,options:{gltf:{normalize:!0,loadBuffers:!0,loadImages:!0,decompressMeshes:!0},log:console}};async function zLt(t,e={},i){e={...uS.options,...e},e.gltf={...uS.options.gltf,...e.gltf};const{byteOffset:o=0}=e;return await OLt({},t,o,e,i)}const qLt={SCALAR:1,VEC2:2,VEC3:3,VEC4:4,MAT2:4,MAT3:9,MAT4:16},QLt={5120:1,5121:1,5122:2,5123:2,5125:4,5126:4},Ga={TEXTURE_MAG_FILTER:10240,TEXTURE_MIN_FILTER:10241,TEXTURE_WRAP_S:10242,TEXTURE_WRAP_T:10243,REPEAT:10497,LINEAR:9729,NEAREST_MIPMAP_LINEAR:9986},GLt={magFilter:Ga.TEXTURE_MAG_FILTER,minFilter:Ga.TEXTURE_MIN_FILTER,wrapS:Ga.TEXTURE_WRAP_S,wrapT:Ga.TEXTURE_WRAP_T},KLt={[Ga.TEXTURE_MAG_FILTER]:Ga.LINEAR,[Ga.TEXTURE_MIN_FILTER]:Ga.NEAREST_MIPMAP_LINEAR,[Ga.TEXTURE_WRAP_S]:Ga.REPEAT,[Ga.TEXTURE_WRAP_T]:Ga.REPEAT};function JLt(){return{id:"default-sampler",parameters:KLt}}function ZLt(t){return QLt[t]}function WLt(t){return qLt[t]}class YLt{baseUri="";jsonUnprocessed;json;buffers=[];images=[];postProcess(e,i={}){const{json:o,buffers:n=[],images:r=[]}=e,{baseUri:a=""}=e;return ya(o),this.baseUri=a,this.buffers=n,this.images=r,this.jsonUnprocessed=o,this.json=this._resolveTree(e.json,i),this.json}_resolveTree(e,i={}){const o={...e};return this.json=o,e.bufferViews&&(o.bufferViews=e.bufferViews.map((n,r)=>this._resolveBufferView(n,r))),e.images&&(o.images=e.images.map((n,r)=>this._resolveImage(n,r))),e.samplers&&(o.samplers=e.samplers.map((n,r)=>this._resolveSampler(n,r))),e.textures&&(o.textures=e.textures.map((n,r)=>this._resolveTexture(n,r))),e.accessors&&(o.accessors=e.accessors.map((n,r)=>this._resolveAccessor(n,r))),e.materials&&(o.materials=e.materials.map((n,r)=>this._resolveMaterial(n,r))),e.meshes&&(o.meshes=e.meshes.map((n,r)=>this._resolveMesh(n,r))),e.nodes&&(o.nodes=e.nodes.map((n,r)=>this._resolveNode(n,r)),o.nodes=o.nodes.map((n,r)=>this._resolveNodeChildren(n))),e.skins&&(o.skins=e.skins.map((n,r)=>this._resolveSkin(n,r))),e.scenes&&(o.scenes=e.scenes.map((n,r)=>this._resolveScene(n,r))),typeof this.json.scene=="number"&&o.scenes&&(o.scene=o.scenes[this.json.scene]),o}getScene(e){return this._get(this.json.scenes,e)}getNode(e){return this._get(this.json.nodes,e)}getSkin(e){return this._get(this.json.skins,e)}getMesh(e){return this._get(this.json.meshes,e)}getMaterial(e){return this._get(this.json.materials,e)}getAccessor(e){return this._get(this.json.accessors,e)}getCamera(e){return this._get(this.json.cameras,e)}getTexture(e){return this._get(this.json.textures,e)}getSampler(e){return this._get(this.json.samplers,e)}getImage(e){return this._get(this.json.images,e)}getBufferView(e){return this._get(this.json.bufferViews,e)}getBuffer(e){return this._get(this.json.buffers,e)}_get(e,i){if(typeof i=="object")return i;const o=e&&e[i];return o||console.warn(`glTF file error: Could not find ${e}[${i}]`),o}_resolveScene(e,i){return{...e,id:e.id||`scene-${i}`,nodes:(e.nodes||[]).map(o=>this.getNode(o))}}_resolveNode(e,i){const o={...e,id:e?.id||`node-${i}`};return e.mesh!==void 0&&(o.mesh=this.getMesh(e.mesh)),e.camera!==void 0&&(o.camera=this.getCamera(e.camera)),e.skin!==void 0&&(o.skin=this.getSkin(e.skin)),e.meshes!==void 0&&e.meshes.length&&(o.mesh=e.meshes.reduce((n,r)=>{const a=this.getMesh(r);return n.id=a.id,n.primitives=n.primitives.concat(a.primitives),n},{primitives:[]})),o}_resolveNodeChildren(e){return e.children&&(e.children=e.children.map(i=>this.getNode(i))),e}_resolveSkin(e,i){const o=typeof e.inverseBindMatrices=="number"?this.getAccessor(e.inverseBindMatrices):void 0;return{...e,id:e.id||`skin-${i}`,inverseBindMatrices:o}}_resolveMesh(e,i){const o={...e,id:e.id||`mesh-${i}`,primitives:[]};return e.primitives&&(o.primitives=e.primitives.map(n=>{const r={...n,attributes:{},indices:void 0,material:void 0},a=n.attributes;for(const s in a)r.attributes[s]=this.getAccessor(a[s]);return n.indices!==void 0&&(r.indices=this.getAccessor(n.indices)),n.material!==void 0&&(r.material=this.getMaterial(n.material)),r})),o}_resolveMaterial(e,i){const o={...e,id:e.id||`material-${i}`};if(o.normalTexture&&(o.normalTexture={...o.normalTexture},o.normalTexture.texture=this.getTexture(o.normalTexture.index)),o.occlusionTexture&&(o.occlusionTexture={...o.occlusionTexture},o.occlusionTexture.texture=this.getTexture(o.occlusionTexture.index)),o.emissiveTexture&&(o.emissiveTexture={...o.emissiveTexture},o.emissiveTexture.texture=this.getTexture(o.emissiveTexture.index)),o.emissiveFactor||(o.emissiveFactor=o.emissiveTexture?[1,1,1]:[0,0,0]),o.pbrMetallicRoughness){o.pbrMetallicRoughness={...o.pbrMetallicRoughness};const n=o.pbrMetallicRoughness;n.baseColorTexture&&(n.baseColorTexture={...n.baseColorTexture},n.baseColorTexture.texture=this.getTexture(n.baseColorTexture.index)),n.metallicRoughnessTexture&&(n.metallicRoughnessTexture={...n.metallicRoughnessTexture},n.metallicRoughnessTexture.texture=this.getTexture(n.metallicRoughnessTexture.index))}return o}_resolveAccessor(e,i){const o=ZLt(e.componentType),n=WLt(e.type),r=o*n,a={...e,id:e.id||`accessor-${i}`,bytesPerComponent:o,components:n,bytesPerElement:r,value:void 0,bufferView:void 0,sparse:void 0};if(e.bufferView!==void 0&&(a.bufferView=this.getBufferView(e.bufferView)),a.bufferView){const s=a.bufferView.buffer,{ArrayType:l,byteLength:c}=JI(a,a.bufferView),d=(a.bufferView.byteOffset||0)+(a.byteOffset||0)+s.byteOffset;let u=s.arrayBuffer.slice(d,d+c);a.bufferView.byteStride&&(u=this._getValueFromInterleavedBuffer(s,d,a.bufferView.byteStride,a.bytesPerElement,a.count)),a.value=new l(u)}return a}_getValueFromInterleavedBuffer(e,i,o,n,r){const a=new Uint8Array(r*n);for(let s=0;s<r;s++){const l=i+s*o;a.set(new Uint8Array(e.arrayBuffer.slice(l,l+n)),s*n)}return a.buffer}_resolveTexture(e,i){return{...e,id:e.id||`texture-${i}`,sampler:typeof e.sampler=="number"?this.getSampler(e.sampler):JLt(),source:typeof e.source=="number"?this.getImage(e.source):void 0}}_resolveSampler(e,i){const o={id:e.id||`sampler-${i}`,...e,parameters:{}};for(const n in o){const r=this._enumSamplerParameter(n);r!==void 0&&(o.parameters[r]=o[n])}return o}_enumSamplerParameter(e){return GLt[e]}_resolveImage(e,i){const o={...e,id:e.id||`image-${i}`,image:null,bufferView:e.bufferView!==void 0?this.getBufferView(e.bufferView):void 0},n=this.images[i];return n&&(o.image=n),o}_resolveBufferView(e,i){const o=e.buffer,n=this.buffers[o].arrayBuffer;let r=this.buffers[o].byteOffset||0;return e.byteOffset&&(r+=e.byteOffset),{id:`bufferView-${i}`,...e,buffer:this.buffers[o],data:new Uint8Array(n,r,e.byteLength)}}_resolveCamera(e,i){const o={...e,id:e.id||`camera-${i}`};return o.perspective,o.orthographic,o}}function XLt(t,e){return new YLt().postProcess(t,e)}class $Lt{constructor(e){}load(e,i,o,n,r,a,s){n=n||{},e_t(e,i,o,n,r,function(){uo.scheduleTask(function(){r.scene.fire("modelLoaded",r.id),r.fire("loaded",!0,!1)}),a&&a()},function(l){e.error(l),s&&s(l),r.fire("error",l)})}parse(e,i,o,n,r,a,s){n=n||{},hS(e,"",i,o,n,r,function(){r.scene.fire("modelLoaded",r.id),r.fire("loaded",!0,!1),a&&a()},function(l){r.error(l),r.fire("error",l),s&&s(l)})}}function e_t(t,e,i,o,n,r,a){const s=t.viewer.scene.canvas.spinner;s.processes++,e.split(".").pop()==="glb"?t.dataSource.getGLB(e,l=>{o.basePath=aee(e),hS(t,e,l,i,o,n,r,a),s.processes--},l=>{s.processes--,a(l)}):t.dataSource.getGLTF(e,l=>{o.basePath=aee(e),hS(t,e,l,i,o,n,r,a),s.processes--},l=>{s.processes--,a(l)})}function aee(t){const e=t.lastIndexOf("/");return e!==0?t.substring(0,e+1):""}function hS(t,e,i,o,n,r,a,s){const l=t.viewer.scene.canvas.spinner;l.processes++,VI(i,uS,{baseUri:n.basePath}).then(c=>{const d=XLt(c),u={entityId:n.entityId,autoMetaModel:n.autoMetaModel,globalizeObjectIds:n.globalizeObjectIds,metaObjects:[],loadBuffer:n.loadBuffer,basePath:n.basePath,handlenode:n.handlenode,backfaces:!!n.backfaces,gltfData:d,scene:r.scene,plugin:t,sceneModel:r,numObjects:0,nextId:0};t_t(u),o_t(u),n.autoMetaModel&&u.metaObjects.push({id:r.id,type:"Default",name:r.id}),a_t(u),r.finalize(),n.autoMetaModel&&t.viewer.metaScene.createMetaModel(r.id,{metaObjects:u.metaObjects}),l.processes--,a()}).catch(c=>{s&&s(c)})}function t_t(t){const e=t.gltfData.textures;if(e)for(let i=0,o=e.length;i<o;i++)i_t(t,e[i])}function i_t(t,e){if(!e.source||!e.source.image)return;const i=`texture-${t.nextId++}`;let o=f1;switch(e.sampler.minFilter){case 9728:o=dh;break;case 9729:o=cn;break;case 9984:o=Kv;break;case 9985:o=Jv;break;case 9986:o=f1;break;case 9987:o=A1;break}let n=cn;switch(e.sampler.magFilter){case 9728:n=dh;break;case 9729:n=cn;break}let r=wo;switch(e.sampler.wrapS){case 33071:r=ln;break;case 33648:r=nc;break;case 10497:r=wo;break}let a=wo;switch(e.sampler.wrapT){case 33071:a=ln;break;case 33648:a=nc;break;case 10497:a=wo;break}let s=wo;switch(e.sampler.wrapR){case 33071:s=ln;break;case 33648:s=nc;break;case 10497:s=wo;break}t.sceneModel.createTexture({id:i,image:e.source.image,flipY:!!e.flipY,minFilter:o,magFilter:n,wrapS:r,wrapT:a,wrapR:s,encoding:ho}),e._textureId=i}function o_t(t){const e=t.gltfData.materials;if(e)for(let i=0,o=e.length;i<o;i++){const n=e[i];n._textureSetId=r_t(t,n),n._attributes=n_t(t,n)}}function r_t(t,e){const i={};switch(e.normalTexture&&(i.normalTextureId=e.normalTexture.texture._textureId),e.occlusionTexture&&(i.occlusionTextureId=e.occlusionTexture.texture._textureId),e.emissiveTexture&&(i.emissiveTextureId=e.emissiveTexture.texture._textureId),e.alphaMode){case"OPAQUE":break;case"MASK":const r=e.alphaCutoff;i.alphaCutoff=r!==void 0?r:.5;break}const o=e.pbrMetallicRoughness;if(e.pbrMetallicRoughness){const r=e.pbrMetallicRoughness,a=r.baseColorTexture||r.colorTexture;a&&(a.texture?i.colorTextureId=a.texture._textureId:i.colorTextureId=t.gltfData.textures[a.index]._textureId),o.metallicRoughnessTexture&&(i.metallicRoughnessTextureId=o.metallicRoughnessTexture.texture._textureId)}const n=e.extensions;if(n){const r=n.KHR_materials_pbrSpecularGlossiness;if(r){r.specularTexture;const a=r.specularColorTexture;a!=null&&(i.colorTextureId=t.gltfData.textures[a.index]._textureId)}}return i.normalTextureId!==void 0||i.occlusionTextureId!==void 0||i.emissiveTextureId!==void 0||i.colorTextureId!==void 0||i.metallicRoughnessTextureId!==void 0?(i.id=`textureSet-${t.nextId++};`,t.sceneModel.createTextureSet(i),i.id):null}function n_t(t,e){const i=e.extensions,o={color:new Float32Array([1,1,1,1]),opacity:1,metallic:0,roughness:1,doubleSided:!0};if(i){const r=i.KHR_materials_pbrSpecularGlossiness;if(r){const s=r.diffuseFactor;s!=null&&o.color.set(s)}const a=i.KHR_materials_common;if(a){const s=a.technique,l=a.values||{},c=s==="BLINN",d=s==="PHONG",u=s==="LAMBERT",h=l.diffuse;h&&(c||d||u)&&(mt.isString(h)||o.color.set(h));const p=l.transparency;p!=null&&(o.opacity=p);const A=l.transparent;A!=null&&(o.opacity=A)}}const n=e.pbrMetallicRoughness;if(n){const r=n.baseColorFactor;r&&(o.color[0]=r[0],o.color[1]=r[1],o.color[2]=r[2],o.opacity=r[3]);const a=n.metallicFactor;a!=null&&(o.metallic=a);const s=n.roughnessFactor;s!=null&&(o.roughness=s)}return o.doubleSided=e.doubleSided!==!1,o}function a_t(t){const e=t.gltfData,i=e.scene||e.scenes[0];if(!i){c_t(t,"glTF has no default scene");return}const o=i.nodes;if(!o)return;(function a(s){s.forEach(l=>{const c=l.mesh;c&&(c.instances||=0,c.instances+=1),l.children&&a(l.children)})})(o);const n=[];let r=null;(function a(s,l,c){s.forEach(d=>{const u=d.name;let h=u!=null&&u||l===0&&"entity-"+t.nextId++;if(h){for(;t.sceneModel.objects[h];)h="entity-"+t.nextId++;n.push(r),r=[]}const p=s_t(d,c);if(d.mesh&&l_t(d,t,p,r),d.children&&a(d.children,l+1,p),h){if(r.length>0){const A=t.globalizeObjectIds?C.globalizeObjectId(t.sceneModel.id,h):h;t.sceneModel.createEntity({id:A,meshIds:r,isObject:!0}),t.autoMetaModel&&t.metaObjects.push({id:A,type:"Default",name:A,parent:t.sceneModel.id})}r=n.pop()}})})(o,0,null)}function s_t(t,e){let i;return t.matrix&&(i=t.matrix,e?e=C.mulMat4(e,i,C.mat4()):e=i),t.translation&&(i=C.translationMat4v(t.translation),e?e=C.mulMat4(e,i,C.mat4()):e=i),t.rotation&&(i=C.quaternionToMat4(t.rotation),e?e=C.mulMat4(e,i,C.mat4()):e=i),t.scale&&(i=C.scalingMat4v(t.scale),e?e=C.mulMat4(e,i,C.mat4()):e=i),e}function l_t(t,e,i,o){const n=t.mesh;if(!n)return;const r=n.primitives.length;if(r>0)for(let a=0;a<r;a++){const s=n.primitives[a];if(s.mode<4)continue;const l={id:e.sceneModel.id+"."+e.numObjects++},c=s.material;c?(l.textureSetId=c._textureSetId,l.color=c._attributes.color,l.opacity=c._attributes.opacity,l.metallic=c._attributes.metallic,l.roughness=c._attributes.roughness):(l.color=new Float32Array([1,1,1]),l.opacity=1);const d=e.backfaces!==!1||c&&c.doubleSided!==!1;switch(s.mode){case 0:l.primitive="points";break;case 1:l.primitive="lines";break;case 2:l.primitive="lines";break;case 3:l.primitive="lines";break;case 4:l.primitive=d?"triangles":"solid";break;case 5:l.primitive=d?"triangles":"solid";break;case 6:l.primitive=d?"triangles":"solid";break;default:l.primitive=d?"triangles":"solid"}const u=s.attributes.POSITION;if(!u)continue;l.localPositions=u.value,l.positions=new Float64Array(l.localPositions.length),s.attributes.NORMAL&&(l.normals=s.attributes.NORMAL.value),s.attributes.TEXCOORD_0&&(l.uv=s.attributes.TEXCOORD_0.value),s.indices&&(l.indices=s.indices.value),i?C.transformPositions3(i,l.localPositions,l.positions):l.positions.set(l.localPositions);const h=C.vec3();o7(l.positions,l.positions,h)&&(l.origin=h),e.sceneModel.createMesh(l),o.push(l.id)}}function c_t(t,e){t.plugin.error(e)}const see={DEFAULT:{}};class pS extends Ha{constructor(e,i={}){super("GLTFLoader",e,i),this._sceneModelLoader=new $Lt(this,i),this.dataSource=i.dataSource,this.objectDefaults=i.objectDefaults}set dataSource(e){this._dataSource=e||new TX}get dataSource(){return this._dataSource}set objectDefaults(e){this._objectDefaults=e||see}get objectDefaults(){return this._objectDefaults}load(e={}){e.id&&this.viewer.scene.components[e.id]&&(this.error("Component with this ID already exists in viewer: "+e.id+" - will autogenerate this ID"),delete e.id);const i=new g3(this.viewer.scene,mt.apply(e,{isModel:!0,dtxEnabled:e.dtxEnabled})),o=i.id;if(!e.src&&!e.gltf)return this.error("load() param expected: src or gltf"),i;if(e.metaModelSrc||e.metaModelJSON){const n=r=>{this.viewer.metaScene.createMetaModel(o,r,{}),this.viewer.scene.canvas.spinner.processes--,e.src?this._sceneModelLoader.load(this,e.src,r,e,i):this._sceneModelLoader.parse(this,e.gltf,r,e,i)};if(e.metaModelSrc){const r=e.metaModelSrc;this.viewer.scene.canvas.spinner.processes++,this._dataSource.getMetaModel(r,a=>{this.viewer.scene.canvas.spinner.processes--,n(a)},a=>{this.error(`load(): Failed to load model metadata for model '${o} from '${r}' - ${a}`),this.viewer.scene.canvas.spinner.processes--})}else e.metaModelJSON&&n(e.metaModelJSON)}else e.src?this._sceneModelLoader.load(this,e.src,null,e,i):this._sceneModelLoader.parse(this,e.gltf,null,e,i);return i.once("destroyed",()=>{this.viewer.metaScene.destroyMetaModel(o)}),i}destroy(){super.destroy()}}function d_t(t,e,i={}){const o="lightgrey",n=i.hoverColor||"rgba(0,0,0,0.4)",r=i.textColor||"black",a=i.canvasElement||document.body,s=500,l=s+s/3,c=l/24,d=[{boundary:[6,6,6,6],color:i.frontColor||i.color||"#55FF55"},{boundary:[18,6,6,6],color:i.backColor||i.color||"#55FF55"},{boundary:[12,6,6,6],color:i.rightColor||i.color||"#FF5555"},{boundary:[0,6,6,6],color:i.leftColor||i.color||"#FF5555"},{boundary:[6,0,6,6],color:i.topColor||i.color||"#7777FF"},{boundary:[6,12,6,6],color:i.bottomColor||i.color||"#7777FF"}],u=[{label:"NavCube.front",boundaries:[[7,7,4,4]],dir:[0,1,0],up:[0,0,1]},{label:"NavCube.back",boundaries:[[19,7,4,4]],dir:[0,-1,0],up:[0,0,1]},{label:"NavCube.right",boundaries:[[13,7,4,4]],dir:[-1,0,0],up:[0,0,1]},{label:"NavCube.left",boundaries:[[1,7,4,4]],dir:[1,0,0],up:[0,0,1]},{label:"NavCube.top",boundaries:[[7,1,4,4]],dir:[0,0,-1],up:[0,1,0]},{label:"NavCube.bottom",boundaries:[[7,13,4,4]],dir:[0,0,1],up:[0,-1,0]},{boundaries:[[7,5,4,2]],dir:[0,1,-1],up:[0,1,1]},{boundaries:[[1,6,4,1],[6,1,1,4]],dir:[1,0,-1],up:[1,0,1]},{boundaries:[[7,0,4,1],[19,6,4,1]],dir:[0,-1,-1],up:[0,-1,1]},{boundaries:[[13,6,4,1],[11,1,1,4]],dir:[-1,0,-1],up:[-1,0,1]},{boundaries:[[7,11,4,2]],dir:[0,1,1],up:[0,-1,1]},{boundaries:[[1,11,4,1],[6,13,1,4]],dir:[1,0,1],up:[-1,0,1]},{boundaries:[[7,17,4,1],[19,11,4,1]],dir:[0,-1,1],up:[0,1,1]},{boundaries:[[13,11,4,1],[11,13,1,4]],dir:[-1,0,1],up:[1,0,1]},{boundaries:[[5,7,2,4]],dir:[1,1,0],up:[0,0,1]},{boundaries:[[11,7,2,4]],dir:[-1,1,0],up:[0,0,1]},{boundaries:[[17,7,2,4]],dir:[-1,-1,0],up:[0,0,1]},{boundaries:[[0,7,1,4],[23,7,1,4]],dir:[1,-1,0],up:[0,0,1]},{boundaries:[[5,11,2,2]],dir:[1,1,1],up:[-1,-1,1]},{boundaries:[[23,11,1,1],[6,17,1,1],[0,11,1,1]],dir:[1,-1,1],up:[-1,1,1]},{boundaries:[[5,5,2,2]],dir:[1,1,-1],up:[1,1,1]},{boundaries:[[11,17,1,1],[17,11,2,1]],dir:[-1,-1,1],up:[1,1,1]},{boundaries:[[17,6,2,1],[11,0,1,1]],dir:[-1,-1,-1],up:[-1,-1,1]},{boundaries:[[11,11,2,2]],dir:[-1,1,1],up:[1,-1,1]},{boundaries:[[0,6,1,1],[6,0,1,1],[23,6,1,1]],dir:[1,-1,-1],up:[1,-1,1]},{boundaries:[[11,5,2,2]],dir:[-1,1,-1],up:[-1,1,1]}];i.frontColor||i.color,i.backColor||i.color,i.rightColor||i.color,i.leftColor||i.color,i.topColor||i.color,i.bottomColor||i.color;const h=[{yUp:"",label:"NavCube.front",boundaries:[[7,7,4,4]],dir:[0,0,-1],up:[0,1,0]},{label:"NavCube.back",boundaries:[[19,7,4,4]],dir:[0,0,1],up:[0,1,0]},{label:"NavCube.right",boundaries:[[13,7,4,4]],dir:[-1,0,0],up:[0,1,0]},{label:"NavCube.left",boundaries:[[1,7,4,4]],dir:[1,0,0],up:[0,1,0]},{label:"NavCube.top",boundaries:[[7,1,4,4]],dir:[0,-1,0],up:[0,0,-1]},{label:"NavCube.bottom",boundaries:[[7,13,4,4]],dir:[0,1,0],up:[0,0,1]},{boundaries:[[7,5,4,2]],dir:[0,-.7071,-.7071],up:[0,.7071,-.7071]},{boundaries:[[1,6,4,1],[6,1,1,4]],dir:[1,-1,0],up:[1,1,0]},{boundaries:[[7,0,4,1],[19,6,4,1]],dir:[0,-.7071,.7071],up:[0,.7071,.7071]},{boundaries:[[13,6,4,1],[11,1,1,4]],dir:[-1,-1,0],up:[-1,1,0]},{boundaries:[[7,11,4,2]],dir:[0,1,-1],up:[0,1,1]},{boundaries:[[1,11,4,1],[6,13,1,4]],dir:[1,1,0],up:[-1,1,0]},{boundaries:[[7,17,4,1],[19,11,4,1]],dir:[0,1,1],up:[0,1,-1]},{boundaries:[[13,11,4,1],[11,13,1,4]],dir:[-1,1,0],up:[1,1,0]},{boundaries:[[5,7,2,4]],dir:[1,0,-1],up:[0,1,0]},{boundaries:[[11,7,2,4]],dir:[-1,0,-1],up:[0,1,0]},{boundaries:[[17,7,2,4]],dir:[-1,0,1],up:[0,1,0]},{boundaries:[[0,7,1,4],[23,7,1,4]],dir:[1,0,1],up:[0,1,0]},{boundaries:[[5,11,2,2]],dir:[.5,.7071,-.5],up:[-.5,.7071,.5]},{boundaries:[[23,11,1,1],[6,17,1,1],[0,11,1,1]],dir:[.5,.7071,.5],up:[-.5,.7071,-.5]},{boundaries:[[5,5,2,2]],dir:[.5,-.7071,-.5],up:[.5,.7071,-.5]},{boundaries:[[11,17,1,1],[17,11,2,1]],dir:[-.5,.7071,.5],up:[.5,.7071,-.5]},{boundaries:[[17,6,2,1],[11,0,1,1]],dir:[-.5,-.7071,.5],up:[-.5,.7071,.5]},{boundaries:[[11,11,2,2]],dir:[-.5,.7071,-.5],up:[.5,.7071,.5]},{boundaries:[[0,6,1,1],[6,0,1,1],[23,6,1,1]],dir:[.5,-.7071,.5],up:[.5,.7071,.5]},{boundaries:[[11,5,2,2]],dir:[-.5,-.7071,-.5],up:[-.5,.7071,-.5]}];for(let y=0,v=u.length;y<v;y++)C.normalizeVec3(u[y].dir,u[y].dir),C.normalizeVec3(u[y].up,u[y].up);for(let y=0,v=h.length;y<v;y++)C.normalizeVec3(h[y].dir,h[y].dir),C.normalizeVec3(h[y].up,h[y].up);var p=h;this._textureCanvas=document.createElement("canvas"),this._textureCanvas.width=l,this._textureCanvas.height=s,this._textureCanvas.style.width=l+"px",this._textureCanvas.style.height=s+"px",this._textureCanvas.style.padding="0",this._textureCanvas.style.margin="0",this._textureCanvas.style.top="0",this._textureCanvas.style.background=o,this._textureCanvas.style.position="absolute",this._textureCanvas.style.opacity="1.0",this._textureCanvas.style.visibility="hidden",this._textureCanvas.style["z-index"]=2e6,a.appendChild(this._textureCanvas);const A=this._textureCanvas.getContext("2d");let f=!1;function m(){for(let k=0,B=d.length;k<B;k++){const P=d[k],E=P.boundary,T=Math.round(E[0]*c),S=Math.round(E[1]*c),R=Math.round(E[2]*c),F=Math.round(E[3]*c);A.fillStyle=P.color,A.fillRect(T,S,R,F)}for(let k=0,B=p.length;k<B;k++){let P,E,T,S;const R=p[k],F=R.boundaries;for(var y=0,v=F.length;y<v;y++){const U=F[y];P=Math.round(U[0]*c),E=Math.round(U[1]*c),T=Math.round(U[2]*c),S=Math.round(U[3]*c),R.highlighted&&(A.fillStyle=R.highlighted?n:R.color||o,A.fillRect(P,E,T,S))}if(R.label){A.fillStyle=r,A.font="60px sans-serif",A.textAlign="center";var w=P+T*.5,x=E+S*.7;A.fillText(g(R.label),w,x,80)}}e.glRedraw()}const g=(function(){const y={"NavCube.front":"NavCube.front","NavCube.back":"NavCube.back","NavCube.right":"NavCube.right","NavCube.left":"NavCube.left","NavCube.top":"NavCube.top","NavCube.bottom":"NavCube.bottom"},v={"NavCube.front":"NavCube.front","NavCube.back":"NavCube.back","NavCube.right":"NavCube.right","NavCube.left":"NavCube.left","NavCube.top":"NavCube.top","NavCube.bottom":"NavCube.bottom"},w={"NavCube.front":"FRONT","NavCube.back":"BACK","NavCube.right":"RIGHT","NavCube.left":"LEFT","NavCube.top":"TOP","NavCube.bottom":"BOTTOM"};return function(x){const k=f?v:y,B=k?k[x]:null;return B?t.localeService.translate(B)||w[B]||B:x}})();this.setZUp=function(){f=!0,p=u,this.clear()},this.setYUp=function(){f=!1,p=h,this.clear()},this.clear=function(){A.fillStyle=o,A.fillRect(0,0,l,s);for(var y=0,v=p.length;y<v;y++){const w=p[y];w.highlighted=!1}m()},this.getArea=function(y){const v=y[0]*l,w=s-y[1]*s;for(var x=0,k=p.length;x<k;x++){const E=p[x].boundaries;for(var B=0,P=E.length;B<P;B++){const T=E[B];if(v>=T[0]*c&&v<=(T[0]+T[2])*c&&w>=T[1]*c&&w<=(T[1]+T[3])*c)return x}}return-1},this.setAreaHighlighted=function(y,v){var w=p[y];if(!w)throw"Area not found: "+y;w.highlighted=!!v,m()},this.getAreaDir=function(y){var v=p[y];if(!v)throw"Unknown area: "+y;return v.dir},this.getAreaUp=function(y){var v=p[y];if(!v)throw"Unknown area: "+y;return v.up},this.getImage=function(){return this._textureCanvas},this.destroy=function(){this._textureCanvas&&(this._textureCanvas.parentNode.removeChild(this._textureCanvas),this._textureCanvas=null)}}const lee=C.vec3(),cee=C.vec3();C.mat4();class fS extends Ha{constructor(e,i={}){super("NavCube",e,i),e.navCube=this;try{this._navCubeScene=new z7(e,{canvasId:i.canvasId,canvasElement:i.canvasElement,transparent:!0}),this._navCubeCanvas=this._navCubeScene.canvas.canvas,this._navCubeScene.input.keyboardEnabled=!1}catch(g){this.error(g);return}const o=this._navCubeScene;o.clearLights(),new ws(o,{dir:[.4,-.4,.8],color:[.8,1,1],intensity:1,space:"view"}),new ws(o,{dir:[-.8,-.3,-.4],color:[.8,.8,.8],intensity:1,space:"view"}),new ws(o,{dir:[.8,-.6,-.8],color:[1,1,1],intensity:1,space:"view"}),this._navCubeCamera=o.camera,this._navCubeCamera.ortho.scale=7,this._navCubeCamera.ortho.near=.1,this._navCubeCamera.ortho.far=2e3,o.edgeMaterial.edgeColor=[.2,.2,.2],o.edgeMaterial.edgeAlpha=.6,this._zUp=!!e.camera.zUp;var n=this;this.setIsProjectNorth(i.isProjectNorth),this.setProjectNorthOffsetAngle(i.projectNorthOffsetAngle);const r=(function(){const g=C.mat4();return function(y,v,w){return C.identityMat4(g),C.rotationMat4v(y*n._projectNorthOffsetAngle*C.DEGTORAD,[0,1,0],g),C.transformVec3(g,v,w)}})();this._synchCamera=(function(){var g=C.rotationMat4c(-90*C.DEGTORAD,1,0,0),y=C.vec3(),v=C.vec3(),w=C.vec3();return function(){var x=e.camera.eye,k=e.camera.look,B=e.camera.up;y=C.mulVec3Scalar(C.normalizeVec3(C.subVec3(x,k,y)),5),n._isProjectNorth&&n._projectNorthOffsetAngle&&(y=r(-1,y,lee),B=r(-1,B,cee)),n._zUp?(C.transformVec3(g,y,v),C.transformVec3(g,B,w),n._navCubeCamera.look=[0,0,0],n._navCubeCamera.eye=C.transformVec3(g,y,v),n._navCubeCamera.up=C.transformPoint3(g,B,w)):(n._navCubeCamera.look=[0,0,0],n._navCubeCamera.eye=y,n._navCubeCamera.up=B)}})(),this._cubeTextureCanvas=new d_t(e,o,i),this._cubeSampler=new g1(o,{image:this._cubeTextureCanvas.getImage(),flipY:!0,wrapS:ln,wrapT:ln}),this._cubeMesh=new mi(o,{geometry:new Ao(o,{primitive:"triangles",normals:[0,0,1,0,0,1,0,0,1,0,0,1,1,0,0,1,0,0,1,0,0,1,0,0,0,1,0,0,1,0,0,1,0,0,1,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,0,-1,0,0,-1,0,0,-1,0,0,-1],positions:[1,1,1,-1,1,1,-1,-1,1,1,-1,1,1,1,1,1,-1,1,1,-1,-1,1,1,-1,1,1,1,1,1,-1,-1,1,-1,-1,1,1,-1,1,1,-1,1,-1,-1,-1,-1,-1,-1,1,-1,-1,-1,1,-1,-1,1,-1,1,-1,-1,1,1,-1,-1,-1,-1,-1,-1,1,-1,1,1,-1],uv:[.5,.6666,.25,.6666,.25,.3333,.5,.3333,.5,.6666,.5,.3333,.75,.3333,.75,.6666,.5,.6666,.5,1,.25,1,.25,.6666,.25,.6666,0,.6666,0,.3333,.25,.3333,.25,0,.5,0,.5,.3333,.25,.3333,.75,.3333,1,.3333,1,.6666,.75,.6666],indices:[0,1,2,0,2,3,4,5,6,4,6,7,8,9,10,8,10,11,12,13,14,12,14,15,16,17,18,16,18,19,20,21,22,20,22,23]}),material:new go(o,{diffuse:[.4,.4,.4],specular:[.4,.4,.4],emissive:[.6,.6,.6],diffuseMap:this._cubeSampler,emissiveMap:this._cubeSampler}),visible:!0,edges:!0}),this._shadow=i.shadowVisible===!1?null:new mi(o,{geometry:new Ao(o,u1({center:[0,0,0],radiusTop:.001,radiusBottom:1.4,height:.01,radialSegments:20,heightSegments:1,openEnded:!0})),material:new go(o,{diffuse:[0,0,0],specular:[0,0,0],emissive:[0,0,0],alpha:.5}),position:[0,-1.5,0],visible:!0,pickable:!1,backfaces:!1}),this._onCameraMatrix=e.camera.on("matrix",this._synchCamera),this._onCameraWorldAxis=e.camera.on("worldAxis",()=>{e.camera.zUp?(this._zUp=!0,this._cubeTextureCanvas.setZUp(),this._repaint(),this._synchCamera()):e.camera.yUp&&(this._zUp=!1,this._cubeTextureCanvas.setYUp(),this._repaint(),this._synchCamera())}),this._onCameraFOV=e.camera.perspective.on("fov",g=>{this._synchProjection&&(this._navCubeCamera.perspective.fov=g)}),this._onCameraProjection=e.camera.on("projection",g=>{this._synchProjection&&(this._navCubeCamera.projection=g==="ortho"||g==="perspective"?g:"perspective")});var a=-1;function s(g,y){var v=(g-A)*-p,w=(y-f)*-p;e.camera.orbitYaw(v),e.camera.orbitPitch(-w),A=g,f=y}function l(g){const{left:y,top:v}=n._navCubeCanvas.getBoundingClientRect();return[g.clientX-y,g.clientY-v]}{var c=null,d=null,u=!1,h=!1,p=.5,A,f;n._navCubeCanvas.addEventListener("mouseenter",n._onMouseEnter=function(g){h=!0}),n._navCubeCanvas.addEventListener("mouseleave",n._onMouseLeave=function(g){h=!1}),n._navCubeCanvas.addEventListener("mousedown",n._onMouseDown=function(g){if(g.which===1){c=g.x,d=g.y,A=g.clientX,f=g.clientY;var y=l({clientX:g.clientX,clientY:g.clientY}),v=o.pick({canvasPos:y});v?u=!0:u=!1}}),n._navCubeCanvas.addEventListener("mouseup",n._onMouseUp=function(g){if(g.which===1&&(u=!1,c!==null)){var y=l({clientX:g.clientX,clientY:g.clientY}),v=o.pick({canvasPos:y,pickSurface:!0});if(v&&v.uv){var w=n._cubeTextureCanvas.getArea(v.uv);if(w>=0&&(n._navCubeCanvas.style.cursor="pointer",a>=0&&(n._cubeTextureCanvas.setAreaHighlighted(a,!1),n._repaint(),a=-1),w>=0)){if(n._cubeTextureCanvas.setAreaHighlighted(w,!0),a=w,n._repaint(),g.x<c-3||g.x>c+3||g.y<d-3||g.y>d+3)return;var x=n._cubeTextureCanvas.getAreaDir(w);if(x){var k=n._cubeTextureCanvas.getAreaUp(w);n._isProjectNorth&&n._projectNorthOffsetAngle&&(x=r(1,x,lee),k=r(1,k,cee)),m(x,k,function(){a>=0&&(n._cubeTextureCanvas.setAreaHighlighted(a,!1),n._repaint(),a=-1),n._navCubeCanvas.style.cursor="pointer",a>=0&&(n._cubeTextureCanvas.setAreaHighlighted(a,!1),n._repaint(),a=-1),w>=0&&(n._cubeTextureCanvas.setAreaHighlighted(w,!1),a=-1,n._repaint())})}}}}}),n._navCubeCanvas.addEventListener("mousemove",n._onMouseMove=function(g){if(a>=0&&(n._cubeTextureCanvas.setAreaHighlighted(a,!1),n._repaint(),a=-1),!(g.buttons===1&&!u)){if(u){var y=g.clientX,v=g.clientY;n._navCubeCanvas.style.cursor="move",s(y,v);return}if(h){var w=l({clientX:g.clientX,clientY:g.clientY}),x=o.pick({canvasPos:w,pickSurface:!0});if(x){if(x.uv){n._navCubeCanvas.style.cursor="pointer";var k=n._cubeTextureCanvas.getArea(x.uv);if(k===a)return;a>=0&&n._cubeTextureCanvas.setAreaHighlighted(a,!1),k>=0&&(n._cubeTextureCanvas.setAreaHighlighted(k,!0),n._repaint(),a=k)}}else n._navCubeCanvas.style.cursor="default",a>=0&&(n._cubeTextureCanvas.setAreaHighlighted(a,!1),n._repaint(),a=-1)}}}),n._navCubeCanvas.addEventListener("touchstart",n._onTouchStart=function(g){if(g.touches.length>0){c=g.touches[0].clientX,d=g.touches[0].clientY,A=g.touches[0].clientX,f=g.touches[0].clientY;var y=l({clientX:g.touches[0].clientX,clientY:g.touches[0].clientY}),v=o.pick({canvasPos:y});v?u=!0:u=!1}},{passive:!1}),n._navCubeCanvas.addEventListener("touchmove",n._onTouchMove=function(g){g.preventDefault();var y=g.touches[0],v=y.clientX,w=y.clientY,x=document.elementFromPoint(v,w);if(h=n._navCubeCanvas===x,!!h&&u){s(v,w);return}},{passive:!1}),n._navCubeCanvas.addEventListener("touchend",n._onTouchEnd=function(g){u=!1});var m=(function(){var g=C.vec3();return function(y,v,w){var x=n._fitVisible?e.scene.getAABB(e.scene.visibleObjectIds):e.scene.aabb,k=C.getAABB3Diag(x);C.getAABB3Center(x,g);var B=Math.abs(k/Math.tan(n._cameraFitFOV*C.DEGTORAD));e.cameraControl.pivotPos=g,n._cameraFly?e.cameraFlight.flyTo({look:g,eye:[g[0]-B*y[0],g[1]-B*y[1],g[2]-B*y[2]],up:v||[0,1,0],orthoScale:k*1.1,fitFOV:n._cameraFitFOV,duration:n._cameraFlyDuration},w):e.cameraFlight.jumpTo({look:g,eye:[g[0]-B*y[0],g[1]-B*y[1],g[2]-B*y[2]],up:v||[0,1,0],orthoScale:k*1.1,fitFOV:n._cameraFitFOV},w)}})()}this._onUpdated=e.localeService.on("updated",()=>{this._cubeTextureCanvas.clear(),this._repaint()}),this.setVisible(i.visible),this.setCameraFitFOV(i.cameraFitFOV),this.setCameraFly(i.cameraFly),this.setCameraFlyDuration(i.cameraFlyDuration),this.setFitVisible(i.fitVisible),this.setSynchProjection(i.synchProjection)}send(e,i){switch(e){case"language":this._cubeTextureCanvas.clear(),this._repaint();break}}_repaint(){const e=this._cubeTextureCanvas.getImage();this._cubeMesh.material.diffuseMap.image=e,this._cubeMesh.material.emissiveMap.image=e}setVisible(e=!0){this._navCubeCanvas&&(this._cubeMesh.visible=e,this._shadow&&(this._shadow.visible=e),this._navCubeCanvas.style.visibility=e?"visible":"hidden")}getVisible(){return this._navCubeCanvas?this._cubeMesh.visible:!1}setFitVisible(e=!1){this._fitVisible=e}getFitVisible(){return this._fitVisible}setCameraFly(e=!0){this._cameraFly=e}getCameraFly(){return this._cameraFly}setCameraFitFOV(e=45){this._cameraFitFOV=e}getCameraFitFOV(){return this._cameraFitFOV}setCameraFlyDuration(e=.5){this._cameraFlyDuration=e}getCameraFlyDuration(){return this._cameraFlyDuration}setSynchProjection(e=!1){this._synchProjection=e}getSynchProjection(){return this._synchProjection}setIsProjectNorth(e=!1){this._isProjectNorth=e}getIsProjectNorth(){return this._isProjectNorth}setProjectNorthOffsetAngle(e){this._projectNorthOffsetAngle=e}getProjectNorthOffsetAngle(){return this._projectNorthOffsetAngle}destroy(){this._navCubeCanvas&&(this.viewer.localeService.off(this._onUpdated),this.viewer.camera.off(this._onCameraMatrix),this.viewer.camera.off(this._onCameraWorldAxis),this.viewer.camera.perspective.off(this._onCameraFOV),this.viewer.camera.off(this._onCameraProjection),this._navCubeCanvas.removeEventListener("mouseenter",this._onMouseEnter),this._navCubeCanvas.removeEventListener("mouseleave",this._onMouseLeave),this._navCubeCanvas.removeEventListener("mousedown",this._onMouseDown),this._navCubeCanvas.removeEventListener("mousemove",this._onMouseMove),this._navCubeCanvas.removeEventListener("mouseup",this._onMouseUp),this._navCubeCanvas.removeEventListener("touchstart",this._onTouchStart),this._navCubeCanvas.removeEventListener("touchmove",this._onTouchMove),this._navCubeCanvas.removeEventListener("touchend",this._onTouchEnd),this._navCubeCanvas=null,this._cubeTextureCanvas.destroy(),this._cubeTextureCanvas=null,this._onMouseEnter=null,this._onMouseLeave=null,this._onMouseDown=null,this._onMouseMove=null,this._onMouseUp=null,this._onTouchStart=null,this._onTouchMove=null,this._onTouchEnd=null),this._navCubeScene.destroy(),this._navCubeScene=null,this._cubeMesh=null,this._shadow=null,super.destroy()}}class u_t{constructor(e){const i=e.cameraControl,o=e.scene,n=o.canvas.canvas,r=!1,a=1,s=.09,l=.01,c=new Gv(o,{position:[0,0,0],scale:[5,5,5],isObject:!1}),d=C.vec3();this._setPosition=(function(){const x=C.vec3(),k=C.vec3();return function(B){d.set(B),ch(B,x,k),c.origin=x,c.position=k}})(),this._setQuaternion=x=>{c.quaternion=x};const u=(x,k)=>new Ao(c,u1({radiusTop:.001,radiusBottom:x,radialSegments:32,heightSegments:1,height:k,openEnded:!1})),h=(x,k,B)=>new Ao(c,u1({radiusTop:x,radiusBottom:x,radialSegments:B,heightSegments:1,height:k,openEnded:!1})),p=(x,k,B)=>new Ao(c,GE({radius:a-.2,tube:x,radialSegments:64,tubeSegments:B,arc:Math.PI*2*k})),A={curve:p(l,.25,14),curveHandle:p(s,.25,14),hoop:p(l,1,8),arrowHead:u(.07,.2),arrowHeadBig:u(.09,.25),arrowHeadHandle:h(s,.37,8),axis:h(l,a,20),axisHandle:h(s,a,20)},f=x=>new go(c,{diffuse:x,emissive:x,ambient:[0,0,0],specular:[.6,.6,.3],shininess:80,lineWidth:2}),m=(x,k)=>new cc(c,{edges:!1,fill:!0,fillColor:x,fillAlpha:k}),g=new go(c,{diffuse:[1,1,0],alpha:0,alphaMode:"blend"}),y={},v=(x,k)=>{C.mulVec3Scalar(x,-1,C.vec3());const B=f(x),P=C.quaternionToRotationMat4(k,C.identityMat4());C.mulMat4(C.rotationMat4v(Math.PI,[0,1,0],C.mat4()),P,P);const E=C.scaleMat4v([.6,.6,.6],C.identityMat4()),T=(ee,ae)=>{const Ee=C.translateMat4v(ee,C.identityMat4()),pe=C.identityMat4();return C.mulMat4(Ee,ae,pe),C.mulMat4(P,pe,pe),C.mulMat4(pe,E,C.identityMat4())},S=c.addChild(new mi(c,{geometry:A.curve,material:B,matrix:P,pickable:!1,collidable:!0,clippable:!1,backfaces:!0,visible:!1,isUI:!0,isObject:!1}),r),R=c.addChild(new mi(c,{geometry:A.curveHandle,material:g,matrix:P,pickable:!0,collidable:!0,clippable:!1,backfaces:!0,visible:!1,isUI:!0,isObject:!1}),r),F=c.addChild(new mi(c,{geometry:A.arrowHead,material:B,matrix:T([.8,.07,0],C.rotationMat4v(180*C.DEGTORAD,[0,0,1],C.identityMat4())),pickable:!0,collidable:!0,clippable:!1,visible:!1,isUI:!0,isObject:!1}),r),U=c.addChild(new mi(c,{geometry:A.arrowHead,material:B,matrix:T([.07,.8,0],C.rotationMat4v(90*C.DEGTORAD,[0,0,1],C.identityMat4())),pickable:!0,collidable:!0,clippable:!1,visible:!1,isUI:!0,isObject:!1}),r),q=c.addChild(new mi(c,{geometry:A.hoop,material:B,highlighted:!0,highlightMaterial:m(x,.6),matrix:P,pickable:!1,collidable:!0,clippable:!1,visible:!1,isUI:!0,isObject:!1}),r),V=C.quaternionToRotationMat4(C.vec3PairToQuaternion([0,1,0],x),C.identityMat4());C.mulMat4(C.rotationMat4v(Math.PI,[0,1,0],C.mat4()),V,V);const W=ee=>C.mulMat4(V,C.translateMat4c(0,ee,0,C.identityMat4()),C.identityMat4()),Y=W(a+.1),$=W(a/2),fe=c.addChild(new mi(c,{geometry:A.arrowHead,material:B,matrix:Y,pickable:!1,collidable:!0,clippable:!1,visible:!1,isUI:!0,isObject:!1}),r),Me=c.addChild(new mi(c,{geometry:A.arrowHeadHandle,material:g,matrix:Y,pickable:!0,collidable:!0,clippable:!1,visible:!1,isUI:!0,isObject:!1}),r),Se=c.addChild(new mi(c,{geometry:A.axis,material:B,matrix:$,pickable:!1,collidable:!0,clippable:!1,visible:!1,isUI:!0,isObject:!1}),r),qe=c.addChild(new mi(c,{geometry:A.axisHandle,material:g,matrix:$,pickable:!0,collidable:!0,clippable:!1,visible:!1,isUI:!0,isObject:!1}),r),Qe=c.addChild(new mi(c,{geometry:A.arrowHeadBig,material:B,matrix:Y,pickable:!1,collidable:!0,clippable:!1,visible:!1,isUI:!0,isObject:!1}),r),Ce=(ee,ae)=>C.vec3ApplyQuaternion(c.quaternion,ee,ae),Le=(function(){const ee=C.vec3(),ae=C.vec3(),Ee=C.vec3();return(pe,Q)=>{Ce(x,ee);const Z=d,ie=ee;C.canvasPosToWorldRay(n,o.camera.viewMatrix,o.camera.projMatrix,o.camera.projection,pe,ae,Ee);const re=C.dotVec3(ie,Ee),ne=C.subVec3(ae,Z,Q),G=C.dotVec3(ne,ie),K=C.dotVec3(ne,Ee),ue=1-re*re;if(Math.abs(ue)>1e-10){const xe=(G-re*K)/ue;return C.addVec3(Z,C.mulVec3Scalar(ie,xe,Q),Q),!0}else return!1}})(),Fe=C.vec3(),ve=C.vec3();y[Me.id]=y[qe.id]={setActivated:ee=>Qe.visible=ee,initDragAction:ee=>Le(ee,Fe)&&C.subVec3(Fe,d,Fe)&&(ae=>{Le(ae,ve)&&(C.subVec3(ve,Fe,ve),this._setPosition(ve),this._handlers&&this._handlers.onPosition(ve))})},y[R.id]={setActivated:ee=>q.visible=ee,initDragAction:ee=>{const ae=(function(){const pe=o.camera.projectWorldPos(d);Ce(x,ve),C.transformVec3(o.camera.normalMatrix,ve,ve);const Q=Math.sign(ve[2]);return Z=>{const ie=Z[0]-pe[0],re=Z[1]-pe[1];return Q*Math.atan2(-re,ie)}})();let Ee=ae(ee);return pe=>{const Q=ae(pe);c.rotate(x,(Q-Ee)*180/Math.PI),this._handlers&&this._handlers.onQuaternion(c.quaternion),Ee=Q}}};let me=!1,we=!1,Re=!1;const We=()=>{const ee=Re&&me;Me.visible=qe.visible=fe.visible=Se.visible=!!ee,ee||(Qe.visible=!1)},H=()=>{const ee=Re&&we;R.visible=S.visible=F.visible=U.visible=!!ee,ee||(q.visible=!1)};return{setPositionActive:ee=>{me=ee,We()},setRotationActive:ee=>{we=ee,H()},set visible(ee){Re=ee,We(),H()}}};this._displayMeshes={center:c.addChild(new mi(c,{geometry:new Ao(c,h1({radius:.05})),material:new go(c,{diffuse:[0,0,0],emissive:[0,0,0],ambient:[0,0,0],specular:[.6,.6,.3],shininess:80}),pickable:!1,collidable:!0,clippable:!1,visible:!1,isObject:!1}),r),x:v([1,0,0],C.vec3PairToQuaternion([1,0,0],[0,0,1])),y:v([0,1,0],C.eulerToQuaternion([90,0,0],"XYZ")),z:v([0,0,1],C.identityQuaternion())};const w=[];{let x=-1;const k=P=>{c.scale[0]!==P&&(c.scale=[P,P,P],this._handlers&&this._handlers.onScreenScale&&this._handlers.onScreenScale(c.scale))},B=o.on("tick",()=>{const P=o.camera,E=Math.abs(C.distVec3(P.eye,d));P.projection==="perspective"?E!==x&&k(.07*E*Math.tan(P.perspective.fov*C.DEGTORAD)):P.projection==="ortho"&&k(P.ortho.scale/10),x=E});w.push(()=>o.off(B))}{let x=null,k=null;w.push(()=>{k&&k.cleanup()});const B=C.vec2(),P=(F,U)=>{U[0]=F.pageX,U[1]=F.pageY,hl(n.ownerDocument.documentElement,n,U)},E=F=>{P(F,B);const U=o.pick({canvasPos:B}),q=U&&U.entity,V=q&&q.id;return V in y&&y[V]},T=(F,U)=>{const q=E(U(F));if(q){k&&k.cleanup();const V=q.initDragAction(B);return V&&(i.pointerEnabled=!1,q.setActivated(!0),k={onChange:W=>{const Y=U(W);Y&&(P(Y,B),V(B))},cleanup:function(){k=null,i.pointerEnabled=!0,q.setActivated(!1)}}),!!V}else return!1},S=(F,U)=>{n.addEventListener(F,U),w.push(()=>n.removeEventListener(F,U))},R=F=>{F.preventDefault(),F.stopPropagation(),F.stopImmediatePropagation()};S("mousedown",F=>{F.which===1&&T(F,U=>U.which===1&&U)&&R(F)}),S("mousemove",F=>{if(k)k.onChange(F),R(F);else{x&&x();const U=E(F);U?(U.setActivated(!0),x=()=>U.setActivated(!1)):x=null}}),S("mouseup",F=>{k&&(k.onChange(F),k.cleanup())}),S("touchstart",F=>{if(F.preventDefault(),F.touches.length===1){const U=F.touches[0].identifier;T(F,q=>[...q.changedTouches].find(V=>V.identifier===U))&&R(F)}}),S("touchmove",F=>{k&&(k.onChange(F),R(F))}),S("touchend",F=>{k&&(k.onChange(F),k.cleanup())})}this.__destroy=()=>{w.forEach(x=>x()),c.destroy();for(let x in y)delete y[x]}}destroy(){this.__destroy()}setHandlers(e){Object.values(this._displayMeshes).forEach(i=>i.visible=!!e),this._handlers=e,this._displayMeshes.x.setPositionActive(e&&e.onPosition),this._displayMeshes.y.setPositionActive(e&&e.onPosition),this._displayMeshes.z.setPositionActive(e&&e.onPosition),this._displayMeshes.x.setRotationActive(e&&e.onQuaternion),this._displayMeshes.y.setRotationActive(e&&e.onQuaternion),this._displayMeshes.z.setRotationActive(e&&e.onQuaternion)}setPosition(e){this._setPosition(e)}setQuaternion(e){this._setQuaternion(e)}}let h_t=class{constructor(t,e,i){this.id=i.id,this._sectionPlane=i,this._mesh=new mi(e,{id:i.id,geometry:new Ao(e,zE({xSize:.5,ySize:.5,zSize:.001})),material:new go(e,{emissive:[1,1,1],diffuse:[0,0,0],backfaces:!1}),edgeMaterial:new bP(e,{edgeColor:[0,0,0],edgeAlpha:1,edgeWidth:1}),highlightMaterial:new cc(e,{fill:!0,fillColor:[.5,1,.5],fillAlpha:.7,edges:!0,edgeColor:[0,0,0],edgeAlpha:1,edgeWidth:1}),selectedMaterial:new cc(e,{fill:!0,fillColor:[0,0,1],fillAlpha:.7,edges:!0,edgeColor:[1,0,0],edgeAlpha:1,edgeWidth:1}),highlighted:!0,scale:[3,3,3],position:[0,0,0],rotation:[0,0,0],opacity:.3,edges:!0});{const o=C.vec3([0,0,0]),n=C.vec3(),r=C.vec3([0,0,1]),a=C.vec4(4),s=C.vec3(),l=()=>{const c=this._sectionPlane.scene.center,d=[-this._sectionPlane.dir[0],-this._sectionPlane.dir[1],-this._sectionPlane.dir[2]];C.subVec3(c,this._sectionPlane.pos,o);const u=-C.dotVec3(d,o);C.normalizeVec3(d),C.mulVec3Scalar(d,u,n);const h=C.vec3PairToQuaternion(r,this._sectionPlane.dir,a);s[0]=n[0]*.1,s[1]=n[1]*.1,s[2]=n[2]*.1,this._mesh.quaternion=h,this._mesh.position=s};this._onSectionPlanePos=this._sectionPlane.on("pos",l),this._onSectionPlaneDir=this._sectionPlane.on("dir",l)}this._highlighted=!1,this._selected=!1}setHighlighted(t){this._highlighted=!!t,this._mesh.highlighted=this._highlighted,this._mesh.highlightMaterial.fillColor=t?[0,.7,0]:[0,0,0]}getHighlighted(){return this._highlighted}setSelected(t){this._selected=!!t,this._mesh.edgeMaterial.edgeWidth=t?3:1,this._mesh.highlightMaterial.edgeWidth=t?3:1}getSelected(){return this._selected}destroy(){this._sectionPlane.off(this._onSectionPlanePos),this._sectionPlane.off(this._onSectionPlaneDir),this._mesh.destroy()}};class p_t{constructor(e,i){if(!i.onHoverEnterPlane||!i.onHoverLeavePlane||!i.onClickedNothing||!i.onClickedPlane)throw"Missing config(s): onHoverEnterPlane, onHoverLeavePlane, onClickedNothing || onClickedPlane";this.plugin=e,this._viewer=e.viewer,this._onHoverEnterPlane=i.onHoverEnterPlane,this._onHoverLeavePlane=i.onHoverLeavePlane,this._onClickedNothing=i.onClickedNothing,this._onClickedPlane=i.onClickedPlane,this._visible=!0,this._planes={},this._canvas=i.overviewCanvas,this._scene=new z7(this._viewer,{canvasId:this._canvas.id,transparent:!0}),this._scene.clearLights(),new ws(this._scene,{dir:[.4,-.4,.8],color:[.8,1,1],intensity:1,space:"view"}),new ws(this._scene,{dir:[-.8,-.3,-.4],color:[.8,.8,.8],intensity:1,space:"view"}),new ws(this._scene,{dir:[.8,-.6,-.8],color:[1,1,1],intensity:1,space:"view"}),this._scene.camera,this._scene.camera.perspective.fov=70,this._zUp=!1;{const n=this._scene.camera,r=C.rotationMat4c(-90*C.DEGTORAD,1,0,0),a=C.vec3(),s=C.vec3(),l=C.vec3();this._synchCamera=()=>{const c=this._viewer.camera.eye,d=this._viewer.camera.look,u=this._viewer.camera.up;C.mulVec3Scalar(C.normalizeVec3(C.subVec3(c,d,a)),7),this._zUp?(C.transformVec3(r,a,s),C.transformVec3(r,u,l),n.look=[0,0,0],n.eye=C.transformVec3(r,a,s),n.up=C.transformPoint3(r,u,l)):(n.look=[0,0,0],n.eye=a,n.up=u)}}this._onViewerCameraMatrix=this._viewer.camera.on("matrix",this._synchCamera),this._onViewerCameraWorldAxis=this._viewer.camera.on("worldAxis",this._synchCamera),this._onViewerCameraFOV=this._viewer.camera.perspective.on("fov",n=>{this._scene.camera.perspective.fov=n});{var o=null;this._onInputMouseMove=this._scene.input.on("mousemove",n=>{const r=this._scene.pick({canvasPos:n});r?(!o||r.entity.id!==o.id)&&(o&&this._planes[o.id]&&this._onHoverLeavePlane(o.id),o=r.entity,this._planes[o.id]&&this._onHoverEnterPlane(o.id)):o&&(this._onHoverLeavePlane(o.id),o=null)}),this._scene.canvas.canvas.addEventListener("mouseup",this._onCanvasMouseUp=()=>{o?this._planes[o.id]&&this._onClickedPlane(o.id):this._onClickedNothing()}),this._scene.canvas.canvas.addEventListener("mouseout",this._onCanvasMouseOut=()=>{o&&(this._onHoverLeavePlane(o.id),o=null)})}this.setVisible(i.overviewVisible)}addSectionPlane(e){this._planes[e.id]=new h_t(this,this._scene,e)}setPlaneHighlighted(e,i){const o=this._planes[e];o&&o.setHighlighted(i)}setPlaneSelected(e,i){const o=this._planes[e];o&&o.setSelected(i)}removeSectionPlane(e){const i=this._planes[e.id];i&&(i.destroy(),delete this._planes[e.id])}setVisible(e=!0){this._visible=e,this._canvas.style.visibility=e?"visible":"hidden"}getVisible(){return this._visible}destroy(){this._viewer.camera.off(this._onViewerCameraMatrix),this._viewer.camera.off(this._onViewerCameraWorldAxis),this._viewer.camera.perspective.off(this._onViewerCameraFOV),this._scene.input.off(this._onInputMouseMove),this._scene.canvas.canvas.removeEventListener("mouseup",this._onCanvasMouseUp),this._scene.canvas.canvas.removeEventListener("mouseout",this._onCanvasMouseOut),this._scene.destroy()}}const gc=C.AABB3(),wh=C.vec3();class f_t extends Ha{constructor(e,i={}){if(super("SectionPlanes",e),this._freeControls=[],this._sectionPlanes=e.scene.sectionPlanes,this._controls={},this._shownControlId=null,i.overviewCanvasId!==null&&i.overviewCanvasId!==void 0){const o=document.getElementById(i.overviewCanvasId);o?this._overview=new p_t(this,{overviewCanvas:o,visible:i.overviewVisible,onHoverEnterPlane:(n=>{this._overview.setPlaneHighlighted(n,!0)}),onHoverLeavePlane:(n=>{this._overview.setPlaneHighlighted(n,!1)}),onClickedPlane:(n=>{if(this.getShownControl()===n){this.hideControl();return}this.showControl(n);const r=this.sectionPlanes[n].pos;gc.set(this.viewer.scene.aabb),C.getAABB3Center(gc,wh),gc[0]+=r[0]-wh[0],gc[1]+=r[1]-wh[1],gc[2]+=r[2]-wh[2],gc[3]+=r[0]-wh[0],gc[4]+=r[1]-wh[1],gc[5]+=r[2]-wh[2],this.viewer.cameraFlight.flyTo({aabb:gc,fitFOV:65})}),onClickedNothing:(()=>{this.hideControl()})}):this.warn("Can't find overview canvas: '"+i.overviewCanvasId+"' - will create plugin without overview")}this._onSceneSectionPlaneCreated=e.scene.on("sectionPlaneCreated",o=>{this._sectionPlaneCreated(o)})}setOverviewVisible(e){this._overview&&this._overview.setVisible(e)}getOverviewVisible(){if(this._overview)return this._overview.getVisible()}get sectionPlanes(){return this._sectionPlanes}createSectionPlane(e={}){return e.id!==void 0&&e.id!==null&&this.viewer.scene.components[e.id]&&(this.error("Viewer component with this ID already exists: "+e.id),delete e.id),new XP(this.viewer.scene,{id:e.id,pos:e.pos,dir:e.dir,active:!0})}_sectionPlaneCreated(e){const i=this._freeControls.length>0?this._freeControls.pop():(()=>{const o=this.viewer.scene,n=(function(){const u=new Gv(o,{isObject:!1});return u.addChild(new mi(u,{geometry:new Ao(u,{primitive:"triangles",positions:[.5,.5,0,.5,-.5,0,-.5,-.5,0,-.5,.5,0,.5,.5,-0,.5,-.5,-0,-.5,-.5,-0,-.5,.5,-0],indices:[0,1,2,2,3,0]}),material:new go(u,{emissive:[0,0,0],diffuse:[0,0,0],backfaces:!0}),opacity:.6,ghosted:!0,ghostMaterial:new cc(u,{edges:!1,filled:!0,fillColor:[1,1,0],edgeColor:[0,0,0],fillAlpha:.1,backfaces:!0}),pickable:!1,collidable:!0,clippable:!1,visible:!1,scale:[2.4,2.4,1],isObject:!1})),u.addChild(new mi(u,{geometry:new Ao(u,GE({center:[0,0,0],radius:1.7,tube:.02,radialSegments:4,tubeSegments:4,arc:Math.PI*2})),material:new go(u,{emissive:[0,0,0],diffuse:[0,0,0],specular:[0,0,0],shininess:0}),highlightMaterial:new cc(u,{edges:!1,edgeColor:[0,0,0],filled:!0,fillColor:[.8,.8,.8],fillAlpha:1}),pickable:!1,collidable:!1,clippable:!1,visible:!1,scale:[1,1,.1],rotation:[0,0,45],isObject:!1})),{setPosition:(function(){const h=C.vec3(),p=C.vec3();return function(A){ch(A,h,p),u.origin=h,u.position=p}})(),setQuaternion:h=>{u.quaternion=h},setScale:h=>{u.scale=h},setVisible:h=>{u.visible=h},destroy:()=>{u.destroy()}}})();let r=()=>{};const a=new u_t(this.viewer);let s=!1,l=!1,c=null;const d=()=>{const u=l&&!s;n.setVisible(u),a.setHandlers(u&&c)};return{_destroy:()=>{r(),a.destroy(),n.destroy()},setCulled:u=>{s=u,d()},setVisible:u=>{l=u,d()},_setSectionPlane:u=>{if(r(),u){let h=!1;c={onPosition:g=>{n.setPosition(g),u.pos=g},onQuaternion:g=>{n.setQuaternion(g),h=!0,u.quaternion=g},onScreenScale:g=>{n.setScale(g)}};const p=()=>{n.setPosition(u.pos),a.setPosition(u.pos)},A=()=>{n.setQuaternion(u.quaternion),a.setQuaternion(u.quaternion)};p(),A();const f=u.on("pos",p),m=u.on("dir",()=>{h?h=!1:A()});r=()=>{u.off(f),u.off(m),r=()=>{}}}}}})();i._setSectionPlane(e),i.setVisible(!1),this._controls[e.id]=i,this._overview&&this._overview.addSectionPlane(e),e.once("destroyed",()=>{this._sectionPlaneDestroyed(e)})}flipSectionPlanes(){const e=this.viewer.scene.sectionPlanes;for(let i in e)e[i].flipDir()}showControl(e){const i=this._controls[e];if(!i){this.error("Control not found: "+e);return}this.hideControl(),i.setVisible(!0),this._overview&&this._overview.setPlaneSelected(e,!0),this._shownControlId=e}getShownControl(){return this._shownControlId}hideControl(){for(var e in this._controls)this._controls.hasOwnProperty(e)&&(this._controls[e].setVisible(!1),this._overview&&this._overview.setPlaneSelected(e,!1));this._shownControlId=null}destroySectionPlane(e){var i=this.viewer.scene.sectionPlanes[e];if(!i){this.error("SectionPlane not found: "+e);return}this._sectionPlaneDestroyed(i),i.destroy(),e===this._shownControlId&&(this._shownControlId=null)}_sectionPlaneDestroyed(e){this._overview&&this._overview.removeSectionPlane(e);const i=this._controls[e.id];i&&(i.setVisible(!1),i._setSectionPlane(null),delete this._controls[e.id],this._freeControls.push(i))}clear(){const e=Object.keys(this._sectionPlanes);for(var i=0,o=e.length;i<o;i++)this.destroySectionPlane(e[i])}send(e,i){switch(e){case"snapshotStarting":for(let o in this._controls)this._controls.hasOwnProperty(o)&&this._controls[o].setCulled(!0);break;case"snapshotFinished":for(let o in this._controls)this._controls.hasOwnProperty(o)&&this._controls[o].setCulled(!1);break;case"clearSectionPlanes":this.clear();break}}destroy(){this.clear(),this._overview&&this._overview.destroy(),this._destroyFreeControls(),super.destroy()}_destroyFreeControls(){for(var e=this._freeControls.pop();e;)e._destroy(),e=this._freeControls.pop();this.viewer.scene.off(this._onSceneSectionPlaneCreated)}}class dee{constructor(e={}){this.cacheBuster=e.cacheBuster!==!1}_cacheBusterURL(e){if(!this.cacheBuster)return e;const i=new Date().getTime();return e.indexOf("?")>-1?e+"&_="+i:e+"?_="+i}getManifest(e,i,o){mt.loadJSON(this._cacheBusterURL(e),n=>{i(n)},function(n){o(n)})}getMetaModel(e,i,o){mt.loadJSON(this._cacheBusterURL(e),n=>{i(n)},function(n){o(n)})}getXKT(e,i,o){var n=()=>{};i=i||n,o=o||n;const r=/^data:(.*?)(;base64)?,(.*)$/,a=e.match(r);if(a){const c=!!a[2];var s=a[3];s=window.decodeURIComponent(s),c&&(s=window.atob(s));try{const d=new ArrayBuffer(s.length),u=new Uint8Array(d);for(var l=0;l<s.length;l++)u[l]=s.charCodeAt(l);i(d)}catch(d){o(d)}}else{const c=new XMLHttpRequest;c.open("GET",this._cacheBusterURL(e),!0),c.responseType="arraybuffer",c.onreadystatechange=function(){c.readyState===4&&(c.status===200?i(c.response):o("getXKT error : "+c.response))},c.send(null)}}}var S9={exports:{}},A_t=S9.exports,uee;function g_t(){return uee||(uee=1,(function(t,e){(function(i,o){o(e)})(A_t,(function(i){function o(L){let X=L.length;for(;--X>=0;)L[X]=0}const n=256,r=286,a=30,s=15,l=new Uint8Array([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0]),c=new Uint8Array([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13]),d=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7]),u=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),h=new Array(576);o(h);const p=new Array(60);o(p);const A=new Array(512);o(A);const f=new Array(256);o(f);const m=new Array(29);o(m);const g=new Array(a);function y(L,X,O,ke,ye){this.static_tree=L,this.extra_bits=X,this.extra_base=O,this.elems=ke,this.max_length=ye,this.has_stree=L&&L.length}let v,w,x;function k(L,X){this.dyn_tree=L,this.max_code=0,this.stat_desc=X}o(g);const B=L=>L<256?A[L]:A[256+(L>>>7)],P=(L,X)=>{L.pending_buf[L.pending++]=255&X,L.pending_buf[L.pending++]=X>>>8&255},E=(L,X,O)=>{L.bi_valid>16-O?(L.bi_buf|=X<<L.bi_valid&65535,P(L,L.bi_buf),L.bi_buf=X>>16-L.bi_valid,L.bi_valid+=O-16):(L.bi_buf|=X<<L.bi_valid&65535,L.bi_valid+=O)},T=(L,X,O)=>{E(L,O[2*X],O[2*X+1])},S=(L,X)=>{let O=0;do O|=1&L,L>>>=1,O<<=1;while(--X>0);return O>>>1},R=(L,X,O)=>{const ke=new Array(16);let ye,ge,tt=0;for(ye=1;ye<=s;ye++)tt=tt+O[ye-1]<<1,ke[ye]=tt;for(ge=0;ge<=X;ge++){let Oe=L[2*ge+1];Oe!==0&&(L[2*ge]=S(ke[Oe]++,Oe))}},F=L=>{let X;for(X=0;X<r;X++)L.dyn_ltree[2*X]=0;for(X=0;X<a;X++)L.dyn_dtree[2*X]=0;for(X=0;X<19;X++)L.bl_tree[2*X]=0;L.dyn_ltree[512]=1,L.opt_len=L.static_len=0,L.sym_next=L.matches=0},U=L=>{L.bi_valid>8?P(L,L.bi_buf):L.bi_valid>0&&(L.pending_buf[L.pending++]=L.bi_buf),L.bi_buf=0,L.bi_valid=0},q=(L,X,O,ke)=>{const ye=2*X,ge=2*O;return L[ye]<L[ge]||L[ye]===L[ge]&&ke[X]<=ke[O]},V=(L,X,O)=>{const ke=L.heap[O];let ye=O<<1;for(;ye<=L.heap_len&&(ye<L.heap_len&&q(X,L.heap[ye+1],L.heap[ye],L.depth)&&ye++,!q(X,ke,L.heap[ye],L.depth));)L.heap[O]=L.heap[ye],O=ye,ye<<=1;L.heap[O]=ke},W=(L,X,O)=>{let ke,ye,ge,tt,Oe=0;if(L.sym_next!==0)do ke=255&L.pending_buf[L.sym_buf+Oe++],ke+=(255&L.pending_buf[L.sym_buf+Oe++])<<8,ye=L.pending_buf[L.sym_buf+Oe++],ke===0?T(L,ye,X):(ge=f[ye],T(L,ge+n+1,X),tt=l[ge],tt!==0&&(ye-=m[ge],E(L,ye,tt)),ke--,ge=B(ke),T(L,ge,O),tt=c[ge],tt!==0&&(ke-=g[ge],E(L,ke,tt)));while(Oe<L.sym_next);T(L,256,X)},Y=(L,X)=>{const O=X.dyn_tree,ke=X.stat_desc.static_tree,ye=X.stat_desc.has_stree,ge=X.stat_desc.elems;let tt,Oe,wt,Ve=-1;for(L.heap_len=0,L.heap_max=573,tt=0;tt<ge;tt++)O[2*tt]!==0?(L.heap[++L.heap_len]=Ve=tt,L.depth[tt]=0):O[2*tt+1]=0;for(;L.heap_len<2;)wt=L.heap[++L.heap_len]=Ve<2?++Ve:0,O[2*wt]=1,L.depth[wt]=0,L.opt_len--,ye&&(L.static_len-=ke[2*wt+1]);for(X.max_code=Ve,tt=L.heap_len>>1;tt>=1;tt--)V(L,O,tt);wt=ge;do tt=L.heap[1],L.heap[1]=L.heap[L.heap_len--],V(L,O,1),Oe=L.heap[1],L.heap[--L.heap_max]=tt,L.heap[--L.heap_max]=Oe,O[2*wt]=O[2*tt]+O[2*Oe],L.depth[wt]=(L.depth[tt]>=L.depth[Oe]?L.depth[tt]:L.depth[Oe])+1,O[2*tt+1]=O[2*Oe+1]=wt,L.heap[1]=wt++,V(L,O,1);while(L.heap_len>=2);L.heap[--L.heap_max]=L.heap[1],((et,ii)=>{const Ht=ii.dyn_tree,Ct=ii.max_code,Xo=ii.stat_desc.static_tree,Si=ii.stat_desc.has_stree,Qt=ii.stat_desc.extra_bits,Oi=ii.stat_desc.extra_base,ti=ii.stat_desc.max_length;let kt,ei,Ui,Pt,Ei,oi,Gt=0;for(Pt=0;Pt<=s;Pt++)et.bl_count[Pt]=0;for(Ht[2*et.heap[et.heap_max]+1]=0,kt=et.heap_max+1;kt<573;kt++)ei=et.heap[kt],Pt=Ht[2*Ht[2*ei+1]+1]+1,Pt>ti&&(Pt=ti,Gt++),Ht[2*ei+1]=Pt,ei>Ct||(et.bl_count[Pt]++,Ei=0,ei>=Oi&&(Ei=Qt[ei-Oi]),oi=Ht[2*ei],et.opt_len+=oi*(Pt+Ei),Si&&(et.static_len+=oi*(Xo[2*ei+1]+Ei)));if(Gt!==0){do{for(Pt=ti-1;et.bl_count[Pt]===0;)Pt--;et.bl_count[Pt]--,et.bl_count[Pt+1]+=2,et.bl_count[ti]--,Gt-=2}while(Gt>0);for(Pt=ti;Pt!==0;Pt--)for(ei=et.bl_count[Pt];ei!==0;)Ui=et.heap[--kt],Ui>Ct||(Ht[2*Ui+1]!==Pt&&(et.opt_len+=(Pt-Ht[2*Ui+1])*Ht[2*Ui],Ht[2*Ui+1]=Pt),ei--)}})(L,X),R(O,Ve,L.bl_count)},$=(L,X,O)=>{let ke,ye,ge=-1,tt=X[1],Oe=0,wt=7,Ve=4;for(tt===0&&(wt=138,Ve=3),X[2*(O+1)+1]=65535,ke=0;ke<=O;ke++)ye=tt,tt=X[2*(ke+1)+1],++Oe<wt&&ye===tt||(Oe<Ve?L.bl_tree[2*ye]+=Oe:ye!==0?(ye!==ge&&L.bl_tree[2*ye]++,L.bl_tree[32]++):Oe<=10?L.bl_tree[34]++:L.bl_tree[36]++,Oe=0,ge=ye,tt===0?(wt=138,Ve=3):ye===tt?(wt=6,Ve=3):(wt=7,Ve=4))},fe=(L,X,O)=>{let ke,ye,ge=-1,tt=X[1],Oe=0,wt=7,Ve=4;for(tt===0&&(wt=138,Ve=3),ke=0;ke<=O;ke++)if(ye=tt,tt=X[2*(ke+1)+1],!(++Oe<wt&&ye===tt)){if(Oe<Ve)do T(L,ye,L.bl_tree);while(--Oe!=0);else ye!==0?(ye!==ge&&(T(L,ye,L.bl_tree),Oe--),T(L,16,L.bl_tree),E(L,Oe-3,2)):Oe<=10?(T(L,17,L.bl_tree),E(L,Oe-3,3)):(T(L,18,L.bl_tree),E(L,Oe-11,7));Oe=0,ge=ye,tt===0?(wt=138,Ve=3):ye===tt?(wt=6,Ve=3):(wt=7,Ve=4)}};let Me=!1;const Se=(L,X,O,ke)=>{E(L,0+(ke?1:0),3),U(L),P(L,O),P(L,~O),O&&L.pending_buf.set(L.window.subarray(X,X+O),L.pending),L.pending+=O};var qe=(L,X,O,ke)=>{let ye,ge,tt=0;L.level>0?(L.strm.data_type===2&&(L.strm.data_type=(Oe=>{let wt,Ve=4093624447;for(wt=0;wt<=31;wt++,Ve>>>=1)if(1&Ve&&Oe.dyn_ltree[2*wt]!==0)return 0;if(Oe.dyn_ltree[18]!==0||Oe.dyn_ltree[20]!==0||Oe.dyn_ltree[26]!==0)return 1;for(wt=32;wt<n;wt++)if(Oe.dyn_ltree[2*wt]!==0)return 1;return 0})(L)),Y(L,L.l_desc),Y(L,L.d_desc),tt=(Oe=>{let wt;for($(Oe,Oe.dyn_ltree,Oe.l_desc.max_code),$(Oe,Oe.dyn_dtree,Oe.d_desc.max_code),Y(Oe,Oe.bl_desc),wt=18;wt>=3&&Oe.bl_tree[2*u[wt]+1]===0;wt--);return Oe.opt_len+=3*(wt+1)+5+5+4,wt})(L),ye=L.opt_len+3+7>>>3,ge=L.static_len+3+7>>>3,ge<=ye&&(ye=ge)):ye=ge=O+5,O+4<=ye&&X!==-1?Se(L,X,O,ke):L.strategy===4||ge===ye?(E(L,2+(ke?1:0),3),W(L,h,p)):(E(L,4+(ke?1:0),3),((Oe,wt,Ve,et)=>{let ii;for(E(Oe,wt-257,5),E(Oe,Ve-1,5),E(Oe,et-4,4),ii=0;ii<et;ii++)E(Oe,Oe.bl_tree[2*u[ii]+1],3);fe(Oe,Oe.dyn_ltree,wt-1),fe(Oe,Oe.dyn_dtree,Ve-1)})(L,L.l_desc.max_code+1,L.d_desc.max_code+1,tt+1),W(L,L.dyn_ltree,L.dyn_dtree)),F(L),ke&&U(L)},Qe={_tr_init:L=>{Me||((()=>{let X,O,ke,ye,ge;const tt=new Array(16);for(ke=0,ye=0;ye<28;ye++)for(m[ye]=ke,X=0;X<1<<l[ye];X++)f[ke++]=ye;for(f[ke-1]=ye,ge=0,ye=0;ye<16;ye++)for(g[ye]=ge,X=0;X<1<<c[ye];X++)A[ge++]=ye;for(ge>>=7;ye<a;ye++)for(g[ye]=ge<<7,X=0;X<1<<c[ye]-7;X++)A[256+ge++]=ye;for(O=0;O<=s;O++)tt[O]=0;for(X=0;X<=143;)h[2*X+1]=8,X++,tt[8]++;for(;X<=255;)h[2*X+1]=9,X++,tt[9]++;for(;X<=279;)h[2*X+1]=7,X++,tt[7]++;for(;X<=287;)h[2*X+1]=8,X++,tt[8]++;for(R(h,287,tt),X=0;X<a;X++)p[2*X+1]=5,p[2*X]=S(X,5);v=new y(h,l,257,r,s),w=new y(p,c,0,a,s),x=new y(new Array(0),d,0,19,7)})(),Me=!0),L.l_desc=new k(L.dyn_ltree,v),L.d_desc=new k(L.dyn_dtree,w),L.bl_desc=new k(L.bl_tree,x),L.bi_buf=0,L.bi_valid=0,F(L)},_tr_stored_block:Se,_tr_flush_block:qe,_tr_tally:(L,X,O)=>(L.pending_buf[L.sym_buf+L.sym_next++]=X,L.pending_buf[L.sym_buf+L.sym_next++]=X>>8,L.pending_buf[L.sym_buf+L.sym_next++]=O,X===0?L.dyn_ltree[2*O]++:(L.matches++,X--,L.dyn_ltree[2*(f[O]+n+1)]++,L.dyn_dtree[2*B(X)]++),L.sym_next===L.sym_end),_tr_align:L=>{E(L,2,3),T(L,256,h),(X=>{X.bi_valid===16?(P(X,X.bi_buf),X.bi_buf=0,X.bi_valid=0):X.bi_valid>=8&&(X.pending_buf[X.pending++]=255&X.bi_buf,X.bi_buf>>=8,X.bi_valid-=8)})(L)}},Ce=(L,X,O,ke)=>{let ye=65535&L|0,ge=L>>>16&65535|0,tt=0;for(;O!==0;){tt=O>2e3?2e3:O,O-=tt;do ye=ye+X[ke++]|0,ge=ge+ye|0;while(--tt);ye%=65521,ge%=65521}return ye|ge<<16|0};const Le=new Uint32Array((()=>{let L,X=[];for(var O=0;O<256;O++){L=O;for(var ke=0;ke<8;ke++)L=1&L?3988292384^L>>>1:L>>>1;X[O]=L}return X})());var Fe=(L,X,O,ke)=>{const ye=Le,ge=ke+O;L^=-1;for(let tt=ke;tt<ge;tt++)L=L>>>8^ye[255&(L^X[tt])];return-1^L},ve={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"},me={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_MEM_ERROR:-4,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8};const{_tr_init:we,_tr_stored_block:Re,_tr_flush_block:We,_tr_tally:H,_tr_align:ee}=Qe,{Z_NO_FLUSH:ae,Z_PARTIAL_FLUSH:Ee,Z_FULL_FLUSH:pe,Z_FINISH:Q,Z_BLOCK:Z,Z_OK:ie,Z_STREAM_END:re,Z_STREAM_ERROR:ne,Z_DATA_ERROR:G,Z_BUF_ERROR:K,Z_DEFAULT_COMPRESSION:ue,Z_FILTERED:xe,Z_HUFFMAN_ONLY:oe,Z_RLE:Be,Z_FIXED:je,Z_DEFAULT_STRATEGY:he,Z_UNKNOWN:Ne,Z_DEFLATED:Pe}=me,ze=258,rt=262,At=42,ft=113,lt=666,ut=(L,X)=>(L.msg=ve[X],X),Te=L=>2*L-(L>4?9:0),st=L=>{let X=L.length;for(;--X>=0;)L[X]=0},dt=L=>{let X,O,ke,ye=L.w_size;X=L.hash_size,ke=X;do O=L.head[--ke],L.head[ke]=O>=ye?O-ye:0;while(--X);X=ye,ke=X;do O=L.prev[--ke],L.prev[ke]=O>=ye?O-ye:0;while(--X)};let Ye=(L,X,O)=>(X<<L.hash_shift^O)&L.hash_mask;const Ae=L=>{const X=L.state;let O=X.pending;O>L.avail_out&&(O=L.avail_out),O!==0&&(L.output.set(X.pending_buf.subarray(X.pending_out,X.pending_out+O),L.next_out),L.next_out+=O,X.pending_out+=O,L.total_out+=O,L.avail_out-=O,X.pending-=O,X.pending===0&&(X.pending_out=0))},be=(L,X)=>{We(L,L.block_start>=0?L.block_start:-1,L.strstart-L.block_start,X),L.block_start=L.strstart,Ae(L.strm)},$e=(L,X)=>{L.pending_buf[L.pending++]=X},ht=(L,X)=>{L.pending_buf[L.pending++]=X>>>8&255,L.pending_buf[L.pending++]=255&X},St=(L,X,O,ke)=>{let ye=L.avail_in;return ye>ke&&(ye=ke),ye===0?0:(L.avail_in-=ye,X.set(L.input.subarray(L.next_in,L.next_in+ye),O),L.state.wrap===1?L.adler=Ce(L.adler,X,ye,O):L.state.wrap===2&&(L.adler=Fe(L.adler,X,ye,O)),L.next_in+=ye,L.total_in+=ye,ye)},xt=(L,X)=>{let O,ke,ye=L.max_chain_length,ge=L.strstart,tt=L.prev_length,Oe=L.nice_match;const wt=L.strstart>L.w_size-rt?L.strstart-(L.w_size-rt):0,Ve=L.window,et=L.w_mask,ii=L.prev,Ht=L.strstart+ze;let Ct=Ve[ge+tt-1],Xo=Ve[ge+tt];L.prev_length>=L.good_match&&(ye>>=2),Oe>L.lookahead&&(Oe=L.lookahead);do if(O=X,Ve[O+tt]===Xo&&Ve[O+tt-1]===Ct&&Ve[O]===Ve[ge]&&Ve[++O]===Ve[ge+1]){ge+=2,O++;do;while(Ve[++ge]===Ve[++O]&&Ve[++ge]===Ve[++O]&&Ve[++ge]===Ve[++O]&&Ve[++ge]===Ve[++O]&&Ve[++ge]===Ve[++O]&&Ve[++ge]===Ve[++O]&&Ve[++ge]===Ve[++O]&&Ve[++ge]===Ve[++O]&&ge<Ht);if(ke=ze-(Ht-ge),ge=Ht-ze,ke>tt){if(L.match_start=X,tt=ke,ke>=Oe)break;Ct=Ve[ge+tt-1],Xo=Ve[ge+tt]}}while((X=ii[X&et])>wt&&--ye!=0);return tt<=L.lookahead?tt:L.lookahead},vi=L=>{const X=L.w_size;let O,ke,ye;do{if(ke=L.window_size-L.lookahead-L.strstart,L.strstart>=X+(X-rt)&&(L.window.set(L.window.subarray(X,X+X-ke),0),L.match_start-=X,L.strstart-=X,L.block_start-=X,L.insert>L.strstart&&(L.insert=L.strstart),dt(L),ke+=X),L.strm.avail_in===0)break;if(O=St(L.strm,L.window,L.strstart+L.lookahead,ke),L.lookahead+=O,L.lookahead+L.insert>=3)for(ye=L.strstart-L.insert,L.ins_h=L.window[ye],L.ins_h=Ye(L,L.ins_h,L.window[ye+1]);L.insert&&(L.ins_h=Ye(L,L.ins_h,L.window[ye+3-1]),L.prev[ye&L.w_mask]=L.head[L.ins_h],L.head[L.ins_h]=ye,ye++,L.insert--,!(L.lookahead+L.insert<3)););}while(L.lookahead<rt&&L.strm.avail_in!==0)},Gi=(L,X)=>{let O,ke,ye,ge=L.pending_buf_size-5>L.w_size?L.w_size:L.pending_buf_size-5,tt=0,Oe=L.strm.avail_in;do{if(O=65535,ye=L.bi_valid+42>>3,L.strm.avail_out<ye||(ye=L.strm.avail_out-ye,ke=L.strstart-L.block_start,O>ke+L.strm.avail_in&&(O=ke+L.strm.avail_in),O>ye&&(O=ye),O<ge&&(O===0&&X!==Q||X===ae||O!==ke+L.strm.avail_in)))break;tt=X===Q&&O===ke+L.strm.avail_in?1:0,Re(L,0,0,tt),L.pending_buf[L.pending-4]=O,L.pending_buf[L.pending-3]=O>>8,L.pending_buf[L.pending-2]=~O,L.pending_buf[L.pending-1]=~O>>8,Ae(L.strm),ke&&(ke>O&&(ke=O),L.strm.output.set(L.window.subarray(L.block_start,L.block_start+ke),L.strm.next_out),L.strm.next_out+=ke,L.strm.avail_out-=ke,L.strm.total_out+=ke,L.block_start+=ke,O-=ke),O&&(St(L.strm,L.strm.output,L.strm.next_out,O),L.strm.next_out+=O,L.strm.avail_out-=O,L.strm.total_out+=O)}while(tt===0);return Oe-=L.strm.avail_in,Oe&&(Oe>=L.w_size?(L.matches=2,L.window.set(L.strm.input.subarray(L.strm.next_in-L.w_size,L.strm.next_in),0),L.strstart=L.w_size,L.insert=L.strstart):(L.window_size-L.strstart<=Oe&&(L.strstart-=L.w_size,L.window.set(L.window.subarray(L.w_size,L.w_size+L.strstart),0),L.matches<2&&L.matches++,L.insert>L.strstart&&(L.insert=L.strstart)),L.window.set(L.strm.input.subarray(L.strm.next_in-Oe,L.strm.next_in),L.strstart),L.strstart+=Oe,L.insert+=Oe>L.w_size-L.insert?L.w_size-L.insert:Oe),L.block_start=L.strstart),L.high_water<L.strstart&&(L.high_water=L.strstart),tt?4:X!==ae&&X!==Q&&L.strm.avail_in===0&&L.strstart===L.block_start?2:(ye=L.window_size-L.strstart,L.strm.avail_in>ye&&L.block_start>=L.w_size&&(L.block_start-=L.w_size,L.strstart-=L.w_size,L.window.set(L.window.subarray(L.w_size,L.w_size+L.strstart),0),L.matches<2&&L.matches++,ye+=L.w_size,L.insert>L.strstart&&(L.insert=L.strstart)),ye>L.strm.avail_in&&(ye=L.strm.avail_in),ye&&(St(L.strm,L.window,L.strstart,ye),L.strstart+=ye,L.insert+=ye>L.w_size-L.insert?L.w_size-L.insert:ye),L.high_water<L.strstart&&(L.high_water=L.strstart),ye=L.bi_valid+42>>3,ye=L.pending_buf_size-ye>65535?65535:L.pending_buf_size-ye,ge=ye>L.w_size?L.w_size:ye,ke=L.strstart-L.block_start,(ke>=ge||(ke||X===Q)&&X!==ae&&L.strm.avail_in===0&&ke<=ye)&&(O=ke>ye?ye:ke,tt=X===Q&&L.strm.avail_in===0&&O===ke?1:0,Re(L,L.block_start,O,tt),L.block_start+=O,Ae(L.strm)),tt?3:1)},So=(L,X)=>{let O,ke;for(;;){if(L.lookahead<rt){if(vi(L),L.lookahead<rt&&X===ae)return 1;if(L.lookahead===0)break}if(O=0,L.lookahead>=3&&(L.ins_h=Ye(L,L.ins_h,L.window[L.strstart+3-1]),O=L.prev[L.strstart&L.w_mask]=L.head[L.ins_h],L.head[L.ins_h]=L.strstart),O!==0&&L.strstart-O<=L.w_size-rt&&(L.match_length=xt(L,O)),L.match_length>=3)if(ke=H(L,L.strstart-L.match_start,L.match_length-3),L.lookahead-=L.match_length,L.match_length<=L.max_lazy_match&&L.lookahead>=3){L.match_length--;do L.strstart++,L.ins_h=Ye(L,L.ins_h,L.window[L.strstart+3-1]),O=L.prev[L.strstart&L.w_mask]=L.head[L.ins_h],L.head[L.ins_h]=L.strstart;while(--L.match_length!=0);L.strstart++}else L.strstart+=L.match_length,L.match_length=0,L.ins_h=L.window[L.strstart],L.ins_h=Ye(L,L.ins_h,L.window[L.strstart+1]);else ke=H(L,0,L.window[L.strstart]),L.lookahead--,L.strstart++;if(ke&&(be(L,!1),L.strm.avail_out===0))return 1}return L.insert=L.strstart<2?L.strstart:2,X===Q?(be(L,!0),L.strm.avail_out===0?3:4):L.sym_next&&(be(L,!1),L.strm.avail_out===0)?1:2},ao=(L,X)=>{let O,ke,ye;for(;;){if(L.lookahead<rt){if(vi(L),L.lookahead<rt&&X===ae)return 1;if(L.lookahead===0)break}if(O=0,L.lookahead>=3&&(L.ins_h=Ye(L,L.ins_h,L.window[L.strstart+3-1]),O=L.prev[L.strstart&L.w_mask]=L.head[L.ins_h],L.head[L.ins_h]=L.strstart),L.prev_length=L.match_length,L.prev_match=L.match_start,L.match_length=2,O!==0&&L.prev_length<L.max_lazy_match&&L.strstart-O<=L.w_size-rt&&(L.match_length=xt(L,O),L.match_length<=5&&(L.strategy===xe||L.match_length===3&&L.strstart-L.match_start>4096)&&(L.match_length=2)),L.prev_length>=3&&L.match_length<=L.prev_length){ye=L.strstart+L.lookahead-3,ke=H(L,L.strstart-1-L.prev_match,L.prev_length-3),L.lookahead-=L.prev_length-1,L.prev_length-=2;do++L.strstart<=ye&&(L.ins_h=Ye(L,L.ins_h,L.window[L.strstart+3-1]),O=L.prev[L.strstart&L.w_mask]=L.head[L.ins_h],L.head[L.ins_h]=L.strstart);while(--L.prev_length!=0);if(L.match_available=0,L.match_length=2,L.strstart++,ke&&(be(L,!1),L.strm.avail_out===0))return 1}else if(L.match_available){if(ke=H(L,0,L.window[L.strstart-1]),ke&&be(L,!1),L.strstart++,L.lookahead--,L.strm.avail_out===0)return 1}else L.match_available=1,L.strstart++,L.lookahead--}return L.match_available&&(ke=H(L,0,L.window[L.strstart-1]),L.match_available=0),L.insert=L.strstart<2?L.strstart:2,X===Q?(be(L,!0),L.strm.avail_out===0?3:4):L.sym_next&&(be(L,!1),L.strm.avail_out===0)?1:2};function Ar(L,X,O,ke,ye){this.good_length=L,this.max_lazy=X,this.nice_length=O,this.max_chain=ke,this.func=ye}const Ki=[new Ar(0,0,0,0,Gi),new Ar(4,4,8,4,So),new Ar(4,5,16,8,So),new Ar(4,6,32,32,So),new Ar(4,4,16,16,ao),new Ar(8,16,32,32,ao),new Ar(8,16,128,128,ao),new Ar(8,32,128,256,ao),new Ar(32,128,258,1024,ao),new Ar(32,258,258,4096,ao)];function Kh(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=Pe,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new Uint16Array(1146),this.dyn_dtree=new Uint16Array(122),this.bl_tree=new Uint16Array(78),st(this.dyn_ltree),st(this.dyn_dtree),st(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new Uint16Array(16),this.heap=new Uint16Array(573),st(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new Uint16Array(573),st(this.depth),this.sym_buf=0,this.lit_bufsize=0,this.sym_next=0,this.sym_end=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}const _s=L=>{if(!L)return 1;const X=L.state;return!X||X.strm!==L||X.status!==At&&X.status!==57&&X.status!==69&&X.status!==73&&X.status!==91&&X.status!==103&&X.status!==ft&&X.status!==lt?1:0},om=L=>{if(_s(L))return ut(L,ne);L.total_in=L.total_out=0,L.data_type=Ne;const X=L.state;return X.pending=0,X.pending_out=0,X.wrap<0&&(X.wrap=-X.wrap),X.status=X.wrap===2?57:X.wrap?At:ft,L.adler=X.wrap===2?0:1,X.last_flush=-2,we(X),ie},pu=L=>{const X=om(L);var O;return X===ie&&((O=L.state).window_size=2*O.w_size,st(O.head),O.max_lazy_match=Ki[O.level].max_lazy,O.good_match=Ki[O.level].good_length,O.nice_match=Ki[O.level].nice_length,O.max_chain_length=Ki[O.level].max_chain,O.strstart=0,O.block_start=0,O.lookahead=0,O.insert=0,O.match_length=O.prev_length=2,O.match_available=0,O.ins_h=0),X},rm=(L,X,O,ke,ye,ge)=>{if(!L)return ne;let tt=1;if(X===ue&&(X=6),ke<0?(tt=0,ke=-ke):ke>15&&(tt=2,ke-=16),ye<1||ye>9||O!==Pe||ke<8||ke>15||X<0||X>9||ge<0||ge>je||ke===8&&tt!==1)return ut(L,ne);ke===8&&(ke=9);const Oe=new Kh;return L.state=Oe,Oe.strm=L,Oe.status=At,Oe.wrap=tt,Oe.gzhead=null,Oe.w_bits=ke,Oe.w_size=1<<Oe.w_bits,Oe.w_mask=Oe.w_size-1,Oe.hash_bits=ye+7,Oe.hash_size=1<<Oe.hash_bits,Oe.hash_mask=Oe.hash_size-1,Oe.hash_shift=~~((Oe.hash_bits+3-1)/3),Oe.window=new Uint8Array(2*Oe.w_size),Oe.head=new Uint16Array(Oe.hash_size),Oe.prev=new Uint16Array(Oe.w_size),Oe.lit_bufsize=1<<ye+6,Oe.pending_buf_size=4*Oe.lit_bufsize,Oe.pending_buf=new Uint8Array(Oe.pending_buf_size),Oe.sym_buf=Oe.lit_bufsize,Oe.sym_end=3*(Oe.lit_bufsize-1),Oe.level=X,Oe.strategy=ge,Oe.method=O,pu(L)};var Nc={deflateInit:(L,X)=>rm(L,X,Pe,15,8,he),deflateInit2:rm,deflateReset:pu,deflateResetKeep:om,deflateSetHeader:(L,X)=>_s(L)||L.state.wrap!==2?ne:(L.state.gzhead=X,ie),deflate:(L,X)=>{if(_s(L)||X>Z||X<0)return L?ut(L,ne):ne;const O=L.state;if(!L.output||L.avail_in!==0&&!L.input||O.status===lt&&X!==Q)return ut(L,L.avail_out===0?K:ne);const ke=O.last_flush;if(O.last_flush=X,O.pending!==0){if(Ae(L),L.avail_out===0)return O.last_flush=-1,ie}else if(L.avail_in===0&&Te(X)<=Te(ke)&&X!==Q)return ut(L,K);if(O.status===lt&&L.avail_in!==0)return ut(L,K);if(O.status===At&&O.wrap===0&&(O.status=ft),O.status===At){let ye=Pe+(O.w_bits-8<<4)<<8,ge=-1;if(ge=O.strategy>=oe||O.level<2?0:O.level<6?1:O.level===6?2:3,ye|=ge<<6,O.strstart!==0&&(ye|=32),ye+=31-ye%31,ht(O,ye),O.strstart!==0&&(ht(O,L.adler>>>16),ht(O,65535&L.adler)),L.adler=1,O.status=ft,Ae(L),O.pending!==0)return O.last_flush=-1,ie}if(O.status===57){if(L.adler=0,$e(O,31),$e(O,139),$e(O,8),O.gzhead)$e(O,(O.gzhead.text?1:0)+(O.gzhead.hcrc?2:0)+(O.gzhead.extra?4:0)+(O.gzhead.name?8:0)+(O.gzhead.comment?16:0)),$e(O,255&O.gzhead.time),$e(O,O.gzhead.time>>8&255),$e(O,O.gzhead.time>>16&255),$e(O,O.gzhead.time>>24&255),$e(O,O.level===9?2:O.strategy>=oe||O.level<2?4:0),$e(O,255&O.gzhead.os),O.gzhead.extra&&O.gzhead.extra.length&&($e(O,255&O.gzhead.extra.length),$e(O,O.gzhead.extra.length>>8&255)),O.gzhead.hcrc&&(L.adler=Fe(L.adler,O.pending_buf,O.pending,0)),O.gzindex=0,O.status=69;else if($e(O,0),$e(O,0),$e(O,0),$e(O,0),$e(O,0),$e(O,O.level===9?2:O.strategy>=oe||O.level<2?4:0),$e(O,3),O.status=ft,Ae(L),O.pending!==0)return O.last_flush=-1,ie}if(O.status===69){if(O.gzhead.extra){let ye=O.pending,ge=(65535&O.gzhead.extra.length)-O.gzindex;for(;O.pending+ge>O.pending_buf_size;){let Oe=O.pending_buf_size-O.pending;if(O.pending_buf.set(O.gzhead.extra.subarray(O.gzindex,O.gzindex+Oe),O.pending),O.pending=O.pending_buf_size,O.gzhead.hcrc&&O.pending>ye&&(L.adler=Fe(L.adler,O.pending_buf,O.pending-ye,ye)),O.gzindex+=Oe,Ae(L),O.pending!==0)return O.last_flush=-1,ie;ye=0,ge-=Oe}let tt=new Uint8Array(O.gzhead.extra);O.pending_buf.set(tt.subarray(O.gzindex,O.gzindex+ge),O.pending),O.pending+=ge,O.gzhead.hcrc&&O.pending>ye&&(L.adler=Fe(L.adler,O.pending_buf,O.pending-ye,ye)),O.gzindex=0}O.status=73}if(O.status===73){if(O.gzhead.name){let ye,ge=O.pending;do{if(O.pending===O.pending_buf_size){if(O.gzhead.hcrc&&O.pending>ge&&(L.adler=Fe(L.adler,O.pending_buf,O.pending-ge,ge)),Ae(L),O.pending!==0)return O.last_flush=-1,ie;ge=0}ye=O.gzindex<O.gzhead.name.length?255&O.gzhead.name.charCodeAt(O.gzindex++):0,$e(O,ye)}while(ye!==0);O.gzhead.hcrc&&O.pending>ge&&(L.adler=Fe(L.adler,O.pending_buf,O.pending-ge,ge)),O.gzindex=0}O.status=91}if(O.status===91){if(O.gzhead.comment){let ye,ge=O.pending;do{if(O.pending===O.pending_buf_size){if(O.gzhead.hcrc&&O.pending>ge&&(L.adler=Fe(L.adler,O.pending_buf,O.pending-ge,ge)),Ae(L),O.pending!==0)return O.last_flush=-1,ie;ge=0}ye=O.gzindex<O.gzhead.comment.length?255&O.gzhead.comment.charCodeAt(O.gzindex++):0,$e(O,ye)}while(ye!==0);O.gzhead.hcrc&&O.pending>ge&&(L.adler=Fe(L.adler,O.pending_buf,O.pending-ge,ge))}O.status=103}if(O.status===103){if(O.gzhead.hcrc){if(O.pending+2>O.pending_buf_size&&(Ae(L),O.pending!==0))return O.last_flush=-1,ie;$e(O,255&L.adler),$e(O,L.adler>>8&255),L.adler=0}if(O.status=ft,Ae(L),O.pending!==0)return O.last_flush=-1,ie}if(L.avail_in!==0||O.lookahead!==0||X!==ae&&O.status!==lt){let ye=O.level===0?Gi(O,X):O.strategy===oe?((ge,tt)=>{let Oe;for(;;){if(ge.lookahead===0&&(vi(ge),ge.lookahead===0)){if(tt===ae)return 1;break}if(ge.match_length=0,Oe=H(ge,0,ge.window[ge.strstart]),ge.lookahead--,ge.strstart++,Oe&&(be(ge,!1),ge.strm.avail_out===0))return 1}return ge.insert=0,tt===Q?(be(ge,!0),ge.strm.avail_out===0?3:4):ge.sym_next&&(be(ge,!1),ge.strm.avail_out===0)?1:2})(O,X):O.strategy===Be?((ge,tt)=>{let Oe,wt,Ve,et;const ii=ge.window;for(;;){if(ge.lookahead<=ze){if(vi(ge),ge.lookahead<=ze&&tt===ae)return 1;if(ge.lookahead===0)break}if(ge.match_length=0,ge.lookahead>=3&&ge.strstart>0&&(Ve=ge.strstart-1,wt=ii[Ve],wt===ii[++Ve]&&wt===ii[++Ve]&&wt===ii[++Ve])){et=ge.strstart+ze;do;while(wt===ii[++Ve]&&wt===ii[++Ve]&&wt===ii[++Ve]&&wt===ii[++Ve]&&wt===ii[++Ve]&&wt===ii[++Ve]&&wt===ii[++Ve]&&wt===ii[++Ve]&&Ve<et);ge.match_length=ze-(et-Ve),ge.match_length>ge.lookahead&&(ge.match_length=ge.lookahead)}if(ge.match_length>=3?(Oe=H(ge,1,ge.match_length-3),ge.lookahead-=ge.match_length,ge.strstart+=ge.match_length,ge.match_length=0):(Oe=H(ge,0,ge.window[ge.strstart]),ge.lookahead--,ge.strstart++),Oe&&(be(ge,!1),ge.strm.avail_out===0))return 1}return ge.insert=0,tt===Q?(be(ge,!0),ge.strm.avail_out===0?3:4):ge.sym_next&&(be(ge,!1),ge.strm.avail_out===0)?1:2})(O,X):Ki[O.level].func(O,X);if(ye!==3&&ye!==4||(O.status=lt),ye===1||ye===3)return L.avail_out===0&&(O.last_flush=-1),ie;if(ye===2&&(X===Ee?ee(O):X!==Z&&(Re(O,0,0,!1),X===pe&&(st(O.head),O.lookahead===0&&(O.strstart=0,O.block_start=0,O.insert=0))),Ae(L),L.avail_out===0))return O.last_flush=-1,ie}return X!==Q?ie:O.wrap<=0?re:(O.wrap===2?($e(O,255&L.adler),$e(O,L.adler>>8&255),$e(O,L.adler>>16&255),$e(O,L.adler>>24&255),$e(O,255&L.total_in),$e(O,L.total_in>>8&255),$e(O,L.total_in>>16&255),$e(O,L.total_in>>24&255)):(ht(O,L.adler>>>16),ht(O,65535&L.adler)),Ae(L),O.wrap>0&&(O.wrap=-O.wrap),O.pending!==0?ie:re)},deflateEnd:L=>{if(_s(L))return ne;const X=L.state.status;return L.state=null,X===ft?ut(L,G):ie},deflateSetDictionary:(L,X)=>{let O=X.length;if(_s(L))return ne;const ke=L.state,ye=ke.wrap;if(ye===2||ye===1&&ke.status!==At||ke.lookahead)return ne;if(ye===1&&(L.adler=Ce(L.adler,X,O,0)),ke.wrap=0,O>=ke.w_size){ye===0&&(st(ke.head),ke.strstart=0,ke.block_start=0,ke.insert=0);let wt=new Uint8Array(ke.w_size);wt.set(X.subarray(O-ke.w_size,O),0),X=wt,O=ke.w_size}const ge=L.avail_in,tt=L.next_in,Oe=L.input;for(L.avail_in=O,L.next_in=0,L.input=X,vi(ke);ke.lookahead>=3;){let wt=ke.strstart,Ve=ke.lookahead-2;do ke.ins_h=Ye(ke,ke.ins_h,ke.window[wt+3-1]),ke.prev[wt&ke.w_mask]=ke.head[ke.ins_h],ke.head[ke.ins_h]=wt,wt++;while(--Ve);ke.strstart=wt,ke.lookahead=2,vi(ke)}return ke.strstart+=ke.lookahead,ke.block_start=ke.strstart,ke.insert=ke.lookahead,ke.lookahead=0,ke.match_length=ke.prev_length=2,ke.match_available=0,L.next_in=tt,L.input=Oe,L.avail_in=ge,ke.wrap=ye,ie},deflateInfo:"pako deflate (from Nodeca project)"};const gw=(L,X)=>Object.prototype.hasOwnProperty.call(L,X);var K4=function(L){const X=Array.prototype.slice.call(arguments,1);for(;X.length;){const O=X.shift();if(O){if(typeof O!="object")throw new TypeError(O+"must be non-object");for(const ke in O)gw(O,ke)&&(L[ke]=O[ke])}}return L},J4=L=>{let X=0;for(let ke=0,ye=L.length;ke<ye;ke++)X+=L[ke].length;const O=new Uint8Array(X);for(let ke=0,ye=0,ge=L.length;ke<ge;ke++){let tt=L[ke];O.set(tt,ye),ye+=tt.length}return O};let Z4=!0;try{String.fromCharCode.apply(null,new Uint8Array(1))}catch{Z4=!1}const fu=new Uint8Array(256);for(let L=0;L<256;L++)fu[L]=L>=252?6:L>=248?5:L>=240?4:L>=224?3:L>=192?2:1;fu[254]=fu[254]=1;var nm=L=>{if(typeof TextEncoder=="function"&&TextEncoder.prototype.encode)return new TextEncoder().encode(L);let X,O,ke,ye,ge,tt=L.length,Oe=0;for(ye=0;ye<tt;ye++)O=L.charCodeAt(ye),(64512&O)==55296&&ye+1<tt&&(ke=L.charCodeAt(ye+1),(64512&ke)==56320&&(O=65536+(O-55296<<10)+(ke-56320),ye++)),Oe+=O<128?1:O<2048?2:O<65536?3:4;for(X=new Uint8Array(Oe),ge=0,ye=0;ge<Oe;ye++)O=L.charCodeAt(ye),(64512&O)==55296&&ye+1<tt&&(ke=L.charCodeAt(ye+1),(64512&ke)==56320&&(O=65536+(O-55296<<10)+(ke-56320),ye++)),O<128?X[ge++]=O:O<2048?(X[ge++]=192|O>>>6,X[ge++]=128|63&O):O<65536?(X[ge++]=224|O>>>12,X[ge++]=128|O>>>6&63,X[ge++]=128|63&O):(X[ge++]=240|O>>>18,X[ge++]=128|O>>>12&63,X[ge++]=128|O>>>6&63,X[ge++]=128|63&O);return X},se=(L,X)=>{const O=X||L.length;if(typeof TextDecoder=="function"&&TextDecoder.prototype.decode)return new TextDecoder().decode(L.subarray(0,X));let ke,ye;const ge=new Array(2*O);for(ye=0,ke=0;ke<O;){let tt=L[ke++];if(tt<128){ge[ye++]=tt;continue}let Oe=fu[tt];if(Oe>4)ge[ye++]=65533,ke+=Oe-1;else{for(tt&=Oe===2?31:Oe===3?15:7;Oe>1&&ke<O;)tt=tt<<6|63&L[ke++],Oe--;Oe>1?ge[ye++]=65533:tt<65536?ge[ye++]=tt:(tt-=65536,ge[ye++]=55296|tt>>10&1023,ge[ye++]=56320|1023&tt)}}return((tt,Oe)=>{if(Oe<65534&&tt.subarray&&Z4)return String.fromCharCode.apply(null,tt.length===Oe?tt:tt.subarray(0,Oe));let wt="";for(let Ve=0;Ve<Oe;Ve++)wt+=String.fromCharCode(tt[Ve]);return wt})(ge,ye)},Ke=(L,X)=>{(X=X||L.length)>L.length&&(X=L.length);let O=X-1;for(;O>=0&&(192&L[O])==128;)O--;return O<0||O===0?X:O+fu[L[O]]>X?O:X},nt=function(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0};const at=Object.prototype.toString,{Z_NO_FLUSH:Ge,Z_SYNC_FLUSH:bt,Z_FULL_FLUSH:Lt,Z_FINISH:Ut,Z_OK:Ot,Z_STREAM_END:Yt,Z_DEFAULT_COMPRESSION:$t,Z_DEFAULT_STRATEGY:Xt,Z_DEFLATED:Bi}=me;function Fi(L){this.options=K4({level:$t,method:Bi,chunkSize:16384,windowBits:15,memLevel:8,strategy:Xt},L||{});let X=this.options;X.raw&&X.windowBits>0?X.windowBits=-X.windowBits:X.gzip&&X.windowBits>0&&X.windowBits<16&&(X.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new nt,this.strm.avail_out=0;let O=Nc.deflateInit2(this.strm,X.level,X.method,X.windowBits,X.memLevel,X.strategy);if(O!==Ot)throw new Error(ve[O]);if(X.header&&Nc.deflateSetHeader(this.strm,X.header),X.dictionary){let ke;if(ke=typeof X.dictionary=="string"?nm(X.dictionary):at.call(X.dictionary)==="[object ArrayBuffer]"?new Uint8Array(X.dictionary):X.dictionary,O=Nc.deflateSetDictionary(this.strm,ke),O!==Ot)throw new Error(ve[O]);this._dict_set=!0}}function to(L,X){const O=new Fi(X);if(O.push(L,!0),O.err)throw O.msg||ve[O.err];return O.result}Fi.prototype.push=function(L,X){const O=this.strm,ke=this.options.chunkSize;let ye,ge;if(this.ended)return!1;for(ge=X===~~X?X:X===!0?Ut:Ge,typeof L=="string"?O.input=nm(L):at.call(L)==="[object ArrayBuffer]"?O.input=new Uint8Array(L):O.input=L,O.next_in=0,O.avail_in=O.input.length;;)if(O.avail_out===0&&(O.output=new Uint8Array(ke),O.next_out=0,O.avail_out=ke),(ge===bt||ge===Lt)&&O.avail_out<=6)this.onData(O.output.subarray(0,O.next_out)),O.avail_out=0;else{if(ye=Nc.deflate(O,ge),ye===Yt)return O.next_out>0&&this.onData(O.output.subarray(0,O.next_out)),ye=Nc.deflateEnd(this.strm),this.onEnd(ye),this.ended=!0,ye===Ot;if(O.avail_out!==0){if(ge>0&&O.next_out>0)this.onData(O.output.subarray(0,O.next_out)),O.avail_out=0;else if(O.avail_in===0)break}else this.onData(O.output)}return!0},Fi.prototype.onData=function(L){this.chunks.push(L)},Fi.prototype.onEnd=function(L){L===Ot&&(this.result=J4(this.chunks)),this.chunks=[],this.err=L,this.msg=this.strm.msg};var xo={Deflate:Fi,deflate:to,deflateRaw:function(L,X){return(X=X||{}).raw=!0,to(L,X)},gzip:function(L,X){return(X=X||{}).gzip=!0,to(L,X)}};const ji=16209;var qt=function(L,X){let O,ke,ye,ge,tt,Oe,wt,Ve,et,ii,Ht,Ct,Xo,Si,Qt,Oi,ti,kt,ei,Ui,Pt,Ei,oi,Gt;const fi=L.state;O=L.next_in,oi=L.input,ke=O+(L.avail_in-5),ye=L.next_out,Gt=L.output,ge=ye-(X-L.avail_out),tt=ye+(L.avail_out-257),Oe=fi.dmax,wt=fi.wsize,Ve=fi.whave,et=fi.wnext,ii=fi.window,Ht=fi.hold,Ct=fi.bits,Xo=fi.lencode,Si=fi.distcode,Qt=(1<<fi.lenbits)-1,Oi=(1<<fi.distbits)-1;e:do{Ct<15&&(Ht+=oi[O++]<<Ct,Ct+=8,Ht+=oi[O++]<<Ct,Ct+=8),ti=Xo[Ht&Qt];t:for(;;){if(kt=ti>>>24,Ht>>>=kt,Ct-=kt,kt=ti>>>16&255,kt===0)Gt[ye++]=65535&ti;else{if(!(16&kt)){if((64&kt)==0){ti=Xo[(65535&ti)+(Ht&(1<<kt)-1)];continue t}if(32&kt){fi.mode=16191;break e}L.msg="invalid literal/length code",fi.mode=ji;break e}ei=65535&ti,kt&=15,kt&&(Ct<kt&&(Ht+=oi[O++]<<Ct,Ct+=8),ei+=Ht&(1<<kt)-1,Ht>>>=kt,Ct-=kt),Ct<15&&(Ht+=oi[O++]<<Ct,Ct+=8,Ht+=oi[O++]<<Ct,Ct+=8),ti=Si[Ht&Oi];i:for(;;){if(kt=ti>>>24,Ht>>>=kt,Ct-=kt,kt=ti>>>16&255,!(16&kt)){if((64&kt)==0){ti=Si[(65535&ti)+(Ht&(1<<kt)-1)];continue i}L.msg="invalid distance code",fi.mode=ji;break e}if(Ui=65535&ti,kt&=15,Ct<kt&&(Ht+=oi[O++]<<Ct,Ct+=8,Ct<kt&&(Ht+=oi[O++]<<Ct,Ct+=8)),Ui+=Ht&(1<<kt)-1,Ui>Oe){L.msg="invalid distance too far back",fi.mode=ji;break e}if(Ht>>>=kt,Ct-=kt,kt=ye-ge,Ui>kt){if(kt=Ui-kt,kt>Ve&&fi.sane){L.msg="invalid distance too far back",fi.mode=ji;break e}if(Pt=0,Ei=ii,et===0){if(Pt+=wt-kt,kt<ei){ei-=kt;do Gt[ye++]=ii[Pt++];while(--kt);Pt=ye-Ui,Ei=Gt}}else if(et<kt){if(Pt+=wt+et-kt,kt-=et,kt<ei){ei-=kt;do Gt[ye++]=ii[Pt++];while(--kt);if(Pt=0,et<ei){kt=et,ei-=kt;do Gt[ye++]=ii[Pt++];while(--kt);Pt=ye-Ui,Ei=Gt}}}else if(Pt+=et-kt,kt<ei){ei-=kt;do Gt[ye++]=ii[Pt++];while(--kt);Pt=ye-Ui,Ei=Gt}for(;ei>2;)Gt[ye++]=Ei[Pt++],Gt[ye++]=Ei[Pt++],Gt[ye++]=Ei[Pt++],ei-=3;ei&&(Gt[ye++]=Ei[Pt++],ei>1&&(Gt[ye++]=Ei[Pt++]))}else{Pt=ye-Ui;do Gt[ye++]=Gt[Pt++],Gt[ye++]=Gt[Pt++],Gt[ye++]=Gt[Pt++],ei-=3;while(ei>2);ei&&(Gt[ye++]=Gt[Pt++],ei>1&&(Gt[ye++]=Gt[Pt++]))}break}}break}}while(O<ke&&ye<tt);ei=Ct>>3,O-=ei,Ct-=ei<<3,Ht&=(1<<Ct)-1,L.next_in=O,L.next_out=ye,L.avail_in=O<ke?ke-O+5:5-(O-ke),L.avail_out=ye<tt?tt-ye+257:257-(ye-tt),fi.hold=Ht,fi.bits=Ct};const Ho=15,es=new Uint16Array([3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0]),oa=new Uint8Array([16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78]),jc=new Uint16Array([1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0]),fn=new Uint8Array([16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64]);var ts=(L,X,O,ke,ye,ge,tt,Oe)=>{const wt=Oe.bits;let Ve,et,ii,Ht,Ct,Xo,Si=0,Qt=0,Oi=0,ti=0,kt=0,ei=0,Ui=0,Pt=0,Ei=0,oi=0,Gt=null;const fi=new Uint16Array(16),An=new Uint16Array(16);let cm,e5,t5,i5=null;for(Si=0;Si<=Ho;Si++)fi[Si]=0;for(Qt=0;Qt<ke;Qt++)fi[X[O+Qt]]++;for(kt=wt,ti=Ho;ti>=1&&fi[ti]===0;ti--);if(kt>ti&&(kt=ti),ti===0)return ye[ge++]=20971520,ye[ge++]=20971520,Oe.bits=1,0;for(Oi=1;Oi<ti&&fi[Oi]===0;Oi++);for(kt<Oi&&(kt=Oi),Pt=1,Si=1;Si<=Ho;Si++)if(Pt<<=1,Pt-=fi[Si],Pt<0)return-1;if(Pt>0&&(L===0||ti!==1))return-1;for(An[1]=0,Si=1;Si<Ho;Si++)An[Si+1]=An[Si]+fi[Si];for(Qt=0;Qt<ke;Qt++)X[O+Qt]!==0&&(tt[An[X[O+Qt]]++]=Qt);if(L===0?(Gt=i5=tt,Xo=20):L===1?(Gt=es,i5=oa,Xo=257):(Gt=jc,i5=fn,Xo=0),oi=0,Qt=0,Si=Oi,Ct=ge,ei=kt,Ui=0,ii=-1,Ei=1<<kt,Ht=Ei-1,L===1&&Ei>852||L===2&&Ei>592)return 1;for(;;){cm=Si-Ui,tt[Qt]+1<Xo?(e5=0,t5=tt[Qt]):tt[Qt]>=Xo?(e5=i5[tt[Qt]-Xo],t5=Gt[tt[Qt]-Xo]):(e5=96,t5=0),Ve=1<<Si-Ui,et=1<<ei,Oi=et;do et-=Ve,ye[Ct+(oi>>Ui)+et]=cm<<24|e5<<16|t5|0;while(et!==0);for(Ve=1<<Si-1;oi&Ve;)Ve>>=1;if(Ve!==0?(oi&=Ve-1,oi+=Ve):oi=0,Qt++,--fi[Si]==0){if(Si===ti)break;Si=X[O+tt[Qt]]}if(Si>kt&&(oi&Ht)!==ii){for(Ui===0&&(Ui=kt),Ct+=Oi,ei=Si-Ui,Pt=1<<ei;ei+Ui<ti&&(Pt-=fi[ei+Ui],!(Pt<=0));)ei++,Pt<<=1;if(Ei+=1<<ei,L===1&&Ei>852||L===2&&Ei>592)return 1;ii=oi&Ht,ye[ii]=kt<<24|ei<<16|Ct-ge|0}}return oi!==0&&(ye[Ct+oi]=Si-Ui<<24|64<<16|0),Oe.bits=kt,0};const{Z_FINISH:mo,Z_BLOCK:Nn,Z_TREES:_r,Z_OK:ko,Z_STREAM_END:ra,Z_NEED_DICT:am,Z_STREAM_ERROR:sr,Z_DATA_ERROR:D_,Z_MEM_ERROR:R_,Z_BUF_ERROR:OAe,Z_DEFLATED:L_}=me,W4=16180,Y4=16190,Il=16191,mw=16192,vw=16194,X4=16199,$4=16200,yw=16206,To=16209,__=L=>(L>>>24&255)+(L>>>8&65280)+((65280&L)<<8)+((255&L)<<24);function UAe(){this.strm=null,this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new Uint16Array(320),this.work=new Uint16Array(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}const Au=L=>{if(!L)return 1;const X=L.state;return!X||X.strm!==L||X.mode<W4||X.mode>16211?1:0},F_=L=>{if(Au(L))return sr;const X=L.state;return L.total_in=L.total_out=X.total=0,L.msg="",X.wrap&&(L.adler=1&X.wrap),X.mode=W4,X.last=0,X.havedict=0,X.flags=-1,X.dmax=32768,X.head=null,X.hold=0,X.bits=0,X.lencode=X.lendyn=new Int32Array(852),X.distcode=X.distdyn=new Int32Array(592),X.sane=1,X.back=-1,ko},O_=L=>{if(Au(L))return sr;const X=L.state;return X.wsize=0,X.whave=0,X.wnext=0,F_(L)},U_=(L,X)=>{let O;if(Au(L))return sr;const ke=L.state;return X<0?(O=0,X=-X):(O=5+(X>>4),X<48&&(X&=15)),X&&(X<8||X>15)?sr:(ke.window!==null&&ke.wbits!==X&&(ke.window=null),ke.wrap=O,ke.wbits=X,O_(L))},N_=(L,X)=>{if(!L)return sr;const O=new UAe;L.state=O,O.strm=L,O.window=null,O.mode=W4;const ke=U_(L,X);return ke!==ko&&(L.state=null),ke};let bw,ww,j_=!0;const NAe=L=>{if(j_){bw=new Int32Array(512),ww=new Int32Array(32);let X=0;for(;X<144;)L.lens[X++]=8;for(;X<256;)L.lens[X++]=9;for(;X<280;)L.lens[X++]=7;for(;X<288;)L.lens[X++]=8;for(ts(1,L.lens,0,288,bw,0,L.work,{bits:9}),X=0;X<32;)L.lens[X++]=5;ts(2,L.lens,0,32,ww,0,L.work,{bits:5}),j_=!1}L.lencode=bw,L.lenbits=9,L.distcode=ww,L.distbits=5},V_=(L,X,O,ke)=>{let ye;const ge=L.state;return ge.window===null&&(ge.wsize=1<<ge.wbits,ge.wnext=0,ge.whave=0,ge.window=new Uint8Array(ge.wsize)),ke>=ge.wsize?(ge.window.set(X.subarray(O-ge.wsize,O),0),ge.wnext=0,ge.whave=ge.wsize):(ye=ge.wsize-ge.wnext,ye>ke&&(ye=ke),ge.window.set(X.subarray(O-ke,O-ke+ye),ge.wnext),(ke-=ye)?(ge.window.set(X.subarray(O-ke,O),0),ge.wnext=ke,ge.whave=ge.wsize):(ge.wnext+=ye,ge.wnext===ge.wsize&&(ge.wnext=0),ge.whave<ge.wsize&&(ge.whave+=ye))),0};var Sl={inflateReset:O_,inflateReset2:U_,inflateResetKeep:F_,inflateInit:L=>N_(L,15),inflateInit2:N_,inflate:(L,X)=>{let O,ke,ye,ge,tt,Oe,wt,Ve,et,ii,Ht,Ct,Xo,Si,Qt,Oi,ti,kt,ei,Ui,Pt,Ei,oi=0;const Gt=new Uint8Array(4);let fi,An;const cm=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]);if(Au(L)||!L.output||!L.input&&L.avail_in!==0)return sr;O=L.state,O.mode===Il&&(O.mode=mw),tt=L.next_out,ye=L.output,wt=L.avail_out,ge=L.next_in,ke=L.input,Oe=L.avail_in,Ve=O.hold,et=O.bits,ii=Oe,Ht=wt,Ei=ko;e:for(;;)switch(O.mode){case W4:if(O.wrap===0){O.mode=mw;break}for(;et<16;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}if(2&O.wrap&&Ve===35615){O.wbits===0&&(O.wbits=15),O.check=0,Gt[0]=255&Ve,Gt[1]=Ve>>>8&255,O.check=Fe(O.check,Gt,2,0),Ve=0,et=0,O.mode=16181;break}if(O.head&&(O.head.done=!1),!(1&O.wrap)||(((255&Ve)<<8)+(Ve>>8))%31){L.msg="incorrect header check",O.mode=To;break}if((15&Ve)!==L_){L.msg="unknown compression method",O.mode=To;break}if(Ve>>>=4,et-=4,Pt=8+(15&Ve),O.wbits===0&&(O.wbits=Pt),Pt>15||Pt>O.wbits){L.msg="invalid window size",O.mode=To;break}O.dmax=1<<O.wbits,O.flags=0,L.adler=O.check=1,O.mode=512&Ve?16189:Il,Ve=0,et=0;break;case 16181:for(;et<16;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}if(O.flags=Ve,(255&O.flags)!==L_){L.msg="unknown compression method",O.mode=To;break}if(57344&O.flags){L.msg="unknown header flags set",O.mode=To;break}O.head&&(O.head.text=Ve>>8&1),512&O.flags&&4&O.wrap&&(Gt[0]=255&Ve,Gt[1]=Ve>>>8&255,O.check=Fe(O.check,Gt,2,0)),Ve=0,et=0,O.mode=16182;case 16182:for(;et<32;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}O.head&&(O.head.time=Ve),512&O.flags&&4&O.wrap&&(Gt[0]=255&Ve,Gt[1]=Ve>>>8&255,Gt[2]=Ve>>>16&255,Gt[3]=Ve>>>24&255,O.check=Fe(O.check,Gt,4,0)),Ve=0,et=0,O.mode=16183;case 16183:for(;et<16;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}O.head&&(O.head.xflags=255&Ve,O.head.os=Ve>>8),512&O.flags&&4&O.wrap&&(Gt[0]=255&Ve,Gt[1]=Ve>>>8&255,O.check=Fe(O.check,Gt,2,0)),Ve=0,et=0,O.mode=16184;case 16184:if(1024&O.flags){for(;et<16;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}O.length=Ve,O.head&&(O.head.extra_len=Ve),512&O.flags&&4&O.wrap&&(Gt[0]=255&Ve,Gt[1]=Ve>>>8&255,O.check=Fe(O.check,Gt,2,0)),Ve=0,et=0}else O.head&&(O.head.extra=null);O.mode=16185;case 16185:if(1024&O.flags&&(Ct=O.length,Ct>Oe&&(Ct=Oe),Ct&&(O.head&&(Pt=O.head.extra_len-O.length,O.head.extra||(O.head.extra=new Uint8Array(O.head.extra_len)),O.head.extra.set(ke.subarray(ge,ge+Ct),Pt)),512&O.flags&&4&O.wrap&&(O.check=Fe(O.check,ke,Ct,ge)),Oe-=Ct,ge+=Ct,O.length-=Ct),O.length))break e;O.length=0,O.mode=16186;case 16186:if(2048&O.flags){if(Oe===0)break e;Ct=0;do Pt=ke[ge+Ct++],O.head&&Pt&&O.length<65536&&(O.head.name+=String.fromCharCode(Pt));while(Pt&&Ct<Oe);if(512&O.flags&&4&O.wrap&&(O.check=Fe(O.check,ke,Ct,ge)),Oe-=Ct,ge+=Ct,Pt)break e}else O.head&&(O.head.name=null);O.length=0,O.mode=16187;case 16187:if(4096&O.flags){if(Oe===0)break e;Ct=0;do Pt=ke[ge+Ct++],O.head&&Pt&&O.length<65536&&(O.head.comment+=String.fromCharCode(Pt));while(Pt&&Ct<Oe);if(512&O.flags&&4&O.wrap&&(O.check=Fe(O.check,ke,Ct,ge)),Oe-=Ct,ge+=Ct,Pt)break e}else O.head&&(O.head.comment=null);O.mode=16188;case 16188:if(512&O.flags){for(;et<16;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}if(4&O.wrap&&Ve!==(65535&O.check)){L.msg="header crc mismatch",O.mode=To;break}Ve=0,et=0}O.head&&(O.head.hcrc=O.flags>>9&1,O.head.done=!0),L.adler=O.check=0,O.mode=Il;break;case 16189:for(;et<32;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}L.adler=O.check=__(Ve),Ve=0,et=0,O.mode=Y4;case Y4:if(O.havedict===0)return L.next_out=tt,L.avail_out=wt,L.next_in=ge,L.avail_in=Oe,O.hold=Ve,O.bits=et,am;L.adler=O.check=1,O.mode=Il;case Il:if(X===Nn||X===_r)break e;case mw:if(O.last){Ve>>>=7&et,et-=7&et,O.mode=yw;break}for(;et<3;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}switch(O.last=1&Ve,Ve>>>=1,et-=1,3&Ve){case 0:O.mode=16193;break;case 1:if(NAe(O),O.mode=X4,X===_r){Ve>>>=2,et-=2;break e}break;case 2:O.mode=16196;break;case 3:L.msg="invalid block type",O.mode=To}Ve>>>=2,et-=2;break;case 16193:for(Ve>>>=7&et,et-=7&et;et<32;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}if((65535&Ve)!=(Ve>>>16^65535)){L.msg="invalid stored block lengths",O.mode=To;break}if(O.length=65535&Ve,Ve=0,et=0,O.mode=vw,X===_r)break e;case vw:O.mode=16195;case 16195:if(Ct=O.length,Ct){if(Ct>Oe&&(Ct=Oe),Ct>wt&&(Ct=wt),Ct===0)break e;ye.set(ke.subarray(ge,ge+Ct),tt),Oe-=Ct,ge+=Ct,wt-=Ct,tt+=Ct,O.length-=Ct;break}O.mode=Il;break;case 16196:for(;et<14;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}if(O.nlen=257+(31&Ve),Ve>>>=5,et-=5,O.ndist=1+(31&Ve),Ve>>>=5,et-=5,O.ncode=4+(15&Ve),Ve>>>=4,et-=4,O.nlen>286||O.ndist>30){L.msg="too many length or distance symbols",O.mode=To;break}O.have=0,O.mode=16197;case 16197:for(;O.have<O.ncode;){for(;et<3;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}O.lens[cm[O.have++]]=7&Ve,Ve>>>=3,et-=3}for(;O.have<19;)O.lens[cm[O.have++]]=0;if(O.lencode=O.lendyn,O.lenbits=7,fi={bits:O.lenbits},Ei=ts(0,O.lens,0,19,O.lencode,0,O.work,fi),O.lenbits=fi.bits,Ei){L.msg="invalid code lengths set",O.mode=To;break}O.have=0,O.mode=16198;case 16198:for(;O.have<O.nlen+O.ndist;){for(;oi=O.lencode[Ve&(1<<O.lenbits)-1],Qt=oi>>>24,Oi=oi>>>16&255,ti=65535&oi,!(Qt<=et);){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}if(ti<16)Ve>>>=Qt,et-=Qt,O.lens[O.have++]=ti;else{if(ti===16){for(An=Qt+2;et<An;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}if(Ve>>>=Qt,et-=Qt,O.have===0){L.msg="invalid bit length repeat",O.mode=To;break}Pt=O.lens[O.have-1],Ct=3+(3&Ve),Ve>>>=2,et-=2}else if(ti===17){for(An=Qt+3;et<An;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}Ve>>>=Qt,et-=Qt,Pt=0,Ct=3+(7&Ve),Ve>>>=3,et-=3}else{for(An=Qt+7;et<An;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}Ve>>>=Qt,et-=Qt,Pt=0,Ct=11+(127&Ve),Ve>>>=7,et-=7}if(O.have+Ct>O.nlen+O.ndist){L.msg="invalid bit length repeat",O.mode=To;break}for(;Ct--;)O.lens[O.have++]=Pt}}if(O.mode===To)break;if(O.lens[256]===0){L.msg="invalid code -- missing end-of-block",O.mode=To;break}if(O.lenbits=9,fi={bits:O.lenbits},Ei=ts(1,O.lens,0,O.nlen,O.lencode,0,O.work,fi),O.lenbits=fi.bits,Ei){L.msg="invalid literal/lengths set",O.mode=To;break}if(O.distbits=6,O.distcode=O.distdyn,fi={bits:O.distbits},Ei=ts(2,O.lens,O.nlen,O.ndist,O.distcode,0,O.work,fi),O.distbits=fi.bits,Ei){L.msg="invalid distances set",O.mode=To;break}if(O.mode=X4,X===_r)break e;case X4:O.mode=$4;case $4:if(Oe>=6&&wt>=258){L.next_out=tt,L.avail_out=wt,L.next_in=ge,L.avail_in=Oe,O.hold=Ve,O.bits=et,qt(L,Ht),tt=L.next_out,ye=L.output,wt=L.avail_out,ge=L.next_in,ke=L.input,Oe=L.avail_in,Ve=O.hold,et=O.bits,O.mode===Il&&(O.back=-1);break}for(O.back=0;oi=O.lencode[Ve&(1<<O.lenbits)-1],Qt=oi>>>24,Oi=oi>>>16&255,ti=65535&oi,!(Qt<=et);){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}if(Oi&&(240&Oi)==0){for(kt=Qt,ei=Oi,Ui=ti;oi=O.lencode[Ui+((Ve&(1<<kt+ei)-1)>>kt)],Qt=oi>>>24,Oi=oi>>>16&255,ti=65535&oi,!(kt+Qt<=et);){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}Ve>>>=kt,et-=kt,O.back+=kt}if(Ve>>>=Qt,et-=Qt,O.back+=Qt,O.length=ti,Oi===0){O.mode=16205;break}if(32&Oi){O.back=-1,O.mode=Il;break}if(64&Oi){L.msg="invalid literal/length code",O.mode=To;break}O.extra=15&Oi,O.mode=16201;case 16201:if(O.extra){for(An=O.extra;et<An;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}O.length+=Ve&(1<<O.extra)-1,Ve>>>=O.extra,et-=O.extra,O.back+=O.extra}O.was=O.length,O.mode=16202;case 16202:for(;oi=O.distcode[Ve&(1<<O.distbits)-1],Qt=oi>>>24,Oi=oi>>>16&255,ti=65535&oi,!(Qt<=et);){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}if((240&Oi)==0){for(kt=Qt,ei=Oi,Ui=ti;oi=O.distcode[Ui+((Ve&(1<<kt+ei)-1)>>kt)],Qt=oi>>>24,Oi=oi>>>16&255,ti=65535&oi,!(kt+Qt<=et);){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}Ve>>>=kt,et-=kt,O.back+=kt}if(Ve>>>=Qt,et-=Qt,O.back+=Qt,64&Oi){L.msg="invalid distance code",O.mode=To;break}O.offset=ti,O.extra=15&Oi,O.mode=16203;case 16203:if(O.extra){for(An=O.extra;et<An;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}O.offset+=Ve&(1<<O.extra)-1,Ve>>>=O.extra,et-=O.extra,O.back+=O.extra}if(O.offset>O.dmax){L.msg="invalid distance too far back",O.mode=To;break}O.mode=16204;case 16204:if(wt===0)break e;if(Ct=Ht-wt,O.offset>Ct){if(Ct=O.offset-Ct,Ct>O.whave&&O.sane){L.msg="invalid distance too far back",O.mode=To;break}Ct>O.wnext?(Ct-=O.wnext,Xo=O.wsize-Ct):Xo=O.wnext-Ct,Ct>O.length&&(Ct=O.length),Si=O.window}else Si=ye,Xo=tt-O.offset,Ct=O.length;Ct>wt&&(Ct=wt),wt-=Ct,O.length-=Ct;do ye[tt++]=Si[Xo++];while(--Ct);O.length===0&&(O.mode=$4);break;case 16205:if(wt===0)break e;ye[tt++]=O.length,wt--,O.mode=$4;break;case yw:if(O.wrap){for(;et<32;){if(Oe===0)break e;Oe--,Ve|=ke[ge++]<<et,et+=8}if(Ht-=wt,L.total_out+=Ht,O.total+=Ht,4&O.wrap&&Ht&&(L.adler=O.check=O.flags?Fe(O.check,ye,Ht,tt-Ht):Ce(O.check,ye,Ht,tt-Ht)),Ht=wt,4&O.wrap&&(O.flags?Ve:__(Ve))!==O.check){L.msg="incorrect data check",O.mode=To;break}Ve=0,et=0}O.mode=16207;case 16207:if(O.wrap&&O.flags){for(;et<32;){if(Oe===0)break e;Oe--,Ve+=ke[ge++]<<et,et+=8}if(4&O.wrap&&Ve!==(4294967295&O.total)){L.msg="incorrect length check",O.mode=To;break}Ve=0,et=0}O.mode=16208;case 16208:Ei=ra;break e;case To:Ei=D_;break e;case 16210:return R_;default:return sr}return L.next_out=tt,L.avail_out=wt,L.next_in=ge,L.avail_in=Oe,O.hold=Ve,O.bits=et,(O.wsize||Ht!==L.avail_out&&O.mode<To&&(O.mode<yw||X!==mo))&&V_(L,L.output,L.next_out,Ht-L.avail_out),ii-=L.avail_in,Ht-=L.avail_out,L.total_in+=ii,L.total_out+=Ht,O.total+=Ht,4&O.wrap&&Ht&&(L.adler=O.check=O.flags?Fe(O.check,ye,Ht,L.next_out-Ht):Ce(O.check,ye,Ht,L.next_out-Ht)),L.data_type=O.bits+(O.last?64:0)+(O.mode===Il?128:0)+(O.mode===X4||O.mode===vw?256:0),(ii===0&&Ht===0||X===mo)&&Ei===ko&&(Ei=OAe),Ei},inflateEnd:L=>{if(Au(L))return sr;let X=L.state;return X.window&&(X.window=null),L.state=null,ko},inflateGetHeader:(L,X)=>{if(Au(L))return sr;const O=L.state;return(2&O.wrap)==0?sr:(O.head=X,X.done=!1,ko)},inflateSetDictionary:(L,X)=>{const O=X.length;let ke,ye,ge;return Au(L)?sr:(ke=L.state,ke.wrap!==0&&ke.mode!==Y4?sr:ke.mode===Y4&&(ye=1,ye=Ce(ye,X,O,0),ye!==ke.check)?D_:(ge=V_(L,X,O,O),ge?(ke.mode=16210,R_):(ke.havedict=1,ko)))},inflateInfo:"pako inflate (from Nodeca project)"},jAe=function(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1};const H_=Object.prototype.toString,{Z_NO_FLUSH:VAe,Z_FINISH:HAe,Z_OK:sm,Z_STREAM_END:Cw,Z_NEED_DICT:xw,Z_STREAM_ERROR:zAe,Z_DATA_ERROR:z_,Z_MEM_ERROR:qAe}=me;function lm(L){this.options=K4({chunkSize:65536,windowBits:15,to:""},L||{});const X=this.options;X.raw&&X.windowBits>=0&&X.windowBits<16&&(X.windowBits=-X.windowBits,X.windowBits===0&&(X.windowBits=-15)),!(X.windowBits>=0&&X.windowBits<16)||L&&L.windowBits||(X.windowBits+=32),X.windowBits>15&&X.windowBits<48&&(15&X.windowBits)==0&&(X.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new nt,this.strm.avail_out=0;let O=Sl.inflateInit2(this.strm,X.windowBits);if(O!==sm)throw new Error(ve[O]);if(this.header=new jAe,Sl.inflateGetHeader(this.strm,this.header),X.dictionary&&(typeof X.dictionary=="string"?X.dictionary=nm(X.dictionary):H_.call(X.dictionary)==="[object ArrayBuffer]"&&(X.dictionary=new Uint8Array(X.dictionary)),X.raw&&(O=Sl.inflateSetDictionary(this.strm,X.dictionary),O!==sm)))throw new Error(ve[O])}function kw(L,X){const O=new lm(X);if(O.push(L),O.err)throw O.msg||ve[O.err];return O.result}lm.prototype.push=function(L,X){const O=this.strm,ke=this.options.chunkSize,ye=this.options.dictionary;let ge,tt,Oe;if(this.ended)return!1;for(tt=X===~~X?X:X===!0?HAe:VAe,H_.call(L)==="[object ArrayBuffer]"?O.input=new Uint8Array(L):O.input=L,O.next_in=0,O.avail_in=O.input.length;;){for(O.avail_out===0&&(O.output=new Uint8Array(ke),O.next_out=0,O.avail_out=ke),ge=Sl.inflate(O,tt),ge===xw&&ye&&(ge=Sl.inflateSetDictionary(O,ye),ge===sm?ge=Sl.inflate(O,tt):ge===z_&&(ge=xw));O.avail_in>0&&ge===Cw&&O.state.wrap>0&&L[O.next_in]!==0;)Sl.inflateReset(O),ge=Sl.inflate(O,tt);switch(ge){case zAe:case z_:case xw:case qAe:return this.onEnd(ge),this.ended=!0,!1}if(Oe=O.avail_out,O.next_out&&(O.avail_out===0||ge===Cw))if(this.options.to==="string"){let wt=Ke(O.output,O.next_out),Ve=O.next_out-wt,et=se(O.output,wt);O.next_out=Ve,O.avail_out=ke-Ve,Ve&&O.output.set(O.output.subarray(wt,wt+Ve),0),this.onData(et)}else this.onData(O.output.length===O.next_out?O.output:O.output.subarray(0,O.next_out));if(ge!==sm||Oe!==0){if(ge===Cw)return ge=Sl.inflateEnd(this.strm),this.onEnd(ge),this.ended=!0,!0;if(O.avail_in===0)break}}return!0},lm.prototype.onData=function(L){this.chunks.push(L)},lm.prototype.onEnd=function(L){L===sm&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=J4(this.chunks)),this.chunks=[],this.err=L,this.msg=this.strm.msg};var QAe={Inflate:lm,inflate:kw,inflateRaw:function(L,X){return(X=X||{}).raw=!0,kw(L,X)},ungzip:kw};const{Deflate:GAe,deflate:KAe,deflateRaw:JAe,gzip:ZAe}=xo,{Inflate:WAe,inflate:YAe,inflateRaw:XAe,ungzip:$Ae}=QAe;var q_=GAe,Q_=KAe,G_=JAe,K_=ZAe,J_=WAe,Z_=YAe,W_=XAe,Y_=$Ae,X_=me,ege={Deflate:q_,deflate:Q_,deflateRaw:G_,gzip:K_,Inflate:J_,inflate:Z_,inflateRaw:W_,ungzip:Y_,constants:X_};i.Deflate=q_,i.Inflate=J_,i.constants=X_,i.default=ege,i.deflate=Q_,i.deflateRaw=G_,i.gzip=K_,i.inflate=Z_,i.inflateRaw=W_,i.ungzip=Y_,Object.defineProperty(i,"__esModule",{value:!0})}))})(S9,S9.exports)),S9.exports}var hee=g_t();const m_t=Jm(hee),ks=tge({__proto__:null,default:m_t},[hee]);let Dn=window.pako||ks;Dn.inflate||(Dn=Dn.default);const v_t=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();function y_t(t){return{positions:t[0],normals:t[1],indices:t[2],edgeIndices:t[3],meshPositions:t[4],meshIndices:t[5],meshEdgesIndices:t[6],meshColors:t[7],entityIDs:t[8],entityMeshes:t[9],entityIsObjects:t[10],positionsDecodeMatrix:t[11]}}function b_t(t){return{positions:new Uint16Array(Dn.inflate(t.positions).buffer),normals:new Int8Array(Dn.inflate(t.normals).buffer),indices:new Uint32Array(Dn.inflate(t.indices).buffer),edgeIndices:new Uint32Array(Dn.inflate(t.edgeIndices).buffer),meshPositions:new Uint32Array(Dn.inflate(t.meshPositions).buffer),meshIndices:new Uint32Array(Dn.inflate(t.meshIndices).buffer),meshEdgesIndices:new Uint32Array(Dn.inflate(t.meshEdgesIndices).buffer),meshColors:new Uint8Array(Dn.inflate(t.meshColors).buffer),entityIDs:Dn.inflate(t.entityIDs,{to:"string"}),entityMeshes:new Uint32Array(Dn.inflate(t.entityMeshes).buffer),entityIsObjects:new Uint8Array(Dn.inflate(t.entityIsObjects).buffer),positionsDecodeMatrix:new Float32Array(Dn.inflate(t.positionsDecodeMatrix).buffer)}}function w_t(t,e,i,o,n,r){r.getNextId(),o.positionsCompression="precompressed",o.normalsCompression="precompressed";const a=i.positions,s=i.normals,l=i.indices,c=i.edgeIndices,d=i.meshPositions,u=i.meshIndices,h=i.meshEdgesIndices,p=i.meshColors,A=JSON.parse(i.entityIDs),f=i.entityMeshes,m=i.entityIsObjects,g=d.length,y=f.length;for(let v=0;v<y;v++){const w=A[v],x=e.globalizeObjectIds?C.globalizeObjectId(o.id,w):w,k=t.metaScene.metaObjects[x],B={},P={};if(k){if(e.excludeTypesMap&&k.type&&e.excludeTypesMap[k.type]||e.includeTypesMap&&k.type&&!e.includeTypesMap[k.type])continue;const S=e.objectDefaults?e.objectDefaults[k.type]||e.objectDefaults.DEFAULT:null;S&&(S.visible===!1&&(B.visible=!1),S.pickable===!1&&(B.pickable=!1),S.colorize&&(P.color=S.colorize),S.opacity!==void 0&&S.opacity!==null&&(P.opacity=S.opacity))}else if(e.excludeUnclassifiedObjects)continue;const E=v===y-1,T=[];for(let S=f[v],R=E?f.length:f[v+1];S<R;S++){const F=S===g-1,U=x+".mesh."+S,q=v_t(p.subarray(S*4,S*4+3)),V=p[S*4+3]/255;o.createMesh(mt.apply(P,{id:U,primitive:"triangles",positionsCompressed:a.subarray(d[S],F?a.length:d[S+1]),normalsCompressed:s.subarray(d[S],F?a.length:d[S+1]),indices:l.subarray(u[S],F?l.length:u[S+1]),edgeIndices:c.subarray(h[S],F?c.length:h[S+1]),positionsDecodeMatrix:i.positionsDecodeMatrix,color:q,opacity:V})),T.push(U)}o.createEntity(mt.apply(B,{id:x,isObject:m[v]===1,meshIds:T}))}}const pee={version:1,parse:function(t,e,i,o,n,r){const a=y_t(i),s=b_t(a);w_t(t,e,s,o,n,r)}};let Pr=window.pako||ks;Pr.inflate||(Pr=Pr.default);function C_t(t){return{positions:t[0],normals:t[1],indices:t[2],edgeIndices:t[3],meshPositions:t[4],meshIndices:t[5],meshEdgesIndices:t[6],meshColors:t[7],entityIDs:t[8],entityMeshes:t[9],entityIsObjects:t[10],positionsDecodeMatrix:t[11],entityMeshIds:t[12],entityMatrices:t[13],entityUsesInstancing:t[14]}}function x_t(t){return{positions:new Uint16Array(Pr.inflate(t.positions).buffer),normals:new Int8Array(Pr.inflate(t.normals).buffer),indices:new Uint32Array(Pr.inflate(t.indices).buffer),edgeIndices:new Uint32Array(Pr.inflate(t.edgeIndices).buffer),meshPositions:new Uint32Array(Pr.inflate(t.meshPositions).buffer),meshIndices:new Uint32Array(Pr.inflate(t.meshIndices).buffer),meshEdgesIndices:new Uint32Array(Pr.inflate(t.meshEdgesIndices).buffer),meshColors:new Uint8Array(Pr.inflate(t.meshColors).buffer),entityIDs:Pr.inflate(t.entityIDs,{to:"string"}),entityMeshes:new Uint32Array(Pr.inflate(t.entityMeshes).buffer),entityIsObjects:new Uint8Array(Pr.inflate(t.entityIsObjects).buffer),positionsDecodeMatrix:new Float32Array(Pr.inflate(t.positionsDecodeMatrix).buffer),entityMeshIds:new Uint32Array(Pr.inflate(t.entityMeshIds).buffer),entityMatrices:new Float32Array(Pr.inflate(t.entityMatrices).buffer),entityUsesInstancing:new Uint8Array(Pr.inflate(t.entityUsesInstancing).buffer)}}const k_t=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();function M_t(t,e,i,o,n,r){const a=r.getNextId();o.positionsCompression="precompressed",o.normalsCompression="precompressed";const s=i.positions,l=i.normals,c=i.indices,d=i.edgeIndices,u=i.meshPositions,h=i.meshIndices,p=i.meshEdgesIndices,A=i.meshColors,f=JSON.parse(i.entityIDs),m=i.entityMeshes,g=i.entityIsObjects,y=i.entityMeshIds,v=i.entityMatrices,w=i.entityUsesInstancing,x=u.length,k=m.length,B={};for(let P=0;P<k;P++){const E=f[P],T=e.globalizeObjectIds?C.globalizeObjectId(o.id,E):E,S=t.metaScene.metaObjects[T],R={},F={},U=v.subarray(P*16,P*16+16);if(S){if(e.excludeTypesMap&&S.type&&e.excludeTypesMap[S.type]||e.includeTypesMap&&S.type&&!e.includeTypesMap[S.type])continue;const W=e.objectDefaults?e.objectDefaults[S.type]||e.objectDefaults.DEFAULT:null;W&&(W.visible===!1&&(R.visible=!1),W.pickable===!1&&(R.pickable=!1),W.colorize&&(F.color=W.colorize),W.opacity!==void 0&&W.opacity!==null&&(F.opacity=W.opacity))}else if(e.excludeUnclassifiedObjects)continue;const q=P===k-1,V=[];for(let W=m[P],Y=q?y.length:m[P+1];W<Y;W++){const $=y[W],fe=$===x-1,Me=r.getNextId(),Se=k_t(A.subarray($*4,$*4+3)),qe=A[$*4+3]/255,Qe=s.subarray(u[$],fe?s.length:u[$+1]),Ce=l.subarray(u[$],fe?s.length:u[$+1]),Le=c.subarray(h[$],fe?c.length:h[$+1]),Fe=d.subarray(p[$],fe?d.length:p[$+1]);if(w[P]===1){const ve=`${a}.geometry.${Me}.${$}`;ve in B||(o.createGeometry({id:ve,positionsCompressed:Qe,normalsCompressed:Ce,indices:Le,edgeIndices:Fe,primitive:"triangles",positionsDecodeMatrix:i.positionsDecodeMatrix}),B[ve]=!0),o.createMesh(mt.apply(F,{id:Me,color:Se,opacity:qe,matrix:U,geometryId:ve})),V.push(Me)}else o.createMesh(mt.apply(F,{id:Me,primitive:"triangles",positionsCompressed:Qe,normalsCompressed:Ce,indices:Le,edgeIndices:Fe,positionsDecodeMatrix:i.positionsDecodeMatrix,color:Se,opacity:qe})),V.push(Me)}V.length&&o.createEntity(mt.apply(R,{id:T,isObject:g[P]===1,meshIds:V}))}}const fee={version:2,parse:function(t,e,i,o,n,r){const a=C_t(i),s=x_t(a);M_t(t,e,s,o,n,r)}};let yr=window.pako||ks;yr.inflate||(yr=yr.default);function B_t(t){return{positions:t[0],normals:t[1],indices:t[2],edgeIndices:t[3],meshPositions:t[4],meshIndices:t[5],meshEdgesIndices:t[6],meshColors:t[7],entityIDs:t[8],entityMeshes:t[9],entityIsObjects:t[10],instancedPositionsDecodeMatrix:t[11],batchedPositionsDecodeMatrix:t[12],entityMeshIds:t[13],entityMatrices:t[14],entityUsesInstancing:t[15]}}function E_t(t){return{positions:new Uint16Array(yr.inflate(t.positions).buffer),normals:new Int8Array(yr.inflate(t.normals).buffer),indices:new Uint32Array(yr.inflate(t.indices).buffer),edgeIndices:new Uint32Array(yr.inflate(t.edgeIndices).buffer),meshPositions:new Uint32Array(yr.inflate(t.meshPositions).buffer),meshIndices:new Uint32Array(yr.inflate(t.meshIndices).buffer),meshEdgesIndices:new Uint32Array(yr.inflate(t.meshEdgesIndices).buffer),meshColors:new Uint8Array(yr.inflate(t.meshColors).buffer),entityIDs:yr.inflate(t.entityIDs,{to:"string"}),entityMeshes:new Uint32Array(yr.inflate(t.entityMeshes).buffer),entityIsObjects:new Uint8Array(yr.inflate(t.entityIsObjects).buffer),instancedPositionsDecodeMatrix:new Float32Array(yr.inflate(t.instancedPositionsDecodeMatrix).buffer),batchedPositionsDecodeMatrix:new Float32Array(yr.inflate(t.batchedPositionsDecodeMatrix).buffer),entityMeshIds:new Uint32Array(yr.inflate(t.entityMeshIds).buffer),entityMatrices:new Float32Array(yr.inflate(t.entityMatrices).buffer),entityUsesInstancing:new Uint8Array(yr.inflate(t.entityUsesInstancing).buffer)}}const P_t=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();function I_t(t,e,i,o,n,r){const a=r.getNextId();o.positionsCompression="precompressed",o.normalsCompression="precompressed";const s=i.positions,l=i.normals,c=i.indices,d=i.edgeIndices,u=i.meshPositions,h=i.meshIndices,p=i.meshEdgesIndices,A=i.meshColors,f=JSON.parse(i.entityIDs),m=i.entityMeshes,g=i.entityIsObjects,y=i.entityMeshIds,v=i.entityMatrices,w=i.entityUsesInstancing,x=u.length,k=m.length,B={};for(let F=0;F<k;F++){const U=f[F],q=e.globalizeObjectIds?C.globalizeObjectId(o.id,U):U,V=t.metaScene.metaObjects[q],W={},Y={},$=v.subarray(F*16,F*16+16);if(V){if(e.excludeTypesMap&&V.type&&e.excludeTypesMap[V.type]||e.includeTypesMap&&V.type&&!e.includeTypesMap[V.type])continue;const Se=e.objectDefaults?e.objectDefaults[V.type]||e.objectDefaults.DEFAULT:null;Se&&(Se.visible===!1&&(W.visible=!1),Se.pickable===!1&&(W.pickable=!1),Se.colorize&&(Y.color=Se.colorize),Se.opacity!==void 0&&Se.opacity!==null&&(Y.opacity=Se.opacity))}else if(e.excludeUnclassifiedObjects)continue;const fe=F===k-1,Me=[];for(let Se=m[F],qe=fe?y.length:m[F+1];Se<qe;Se++){var P=y[Se];const Qe=P===x-1,Ce=`${a}.${q}.mesh.${P}`,Le=P_t(A.subarray(P*4,P*4+3)),Fe=A[P*4+3]/255;var E=s.subarray(u[P],Qe?s.length:u[P+1]),T=l.subarray(u[P],Qe?s.length:u[P+1]),S=c.subarray(h[P],Qe?c.length:h[P+1]),R=d.subarray(p[P],Qe?d.length:p[P+1]);if(w[F]===1){const ve=`${a}.geometry.${Ce}.${P}`;ve in B||(o.createGeometry({id:ve,positionsCompressed:E,normalsCompressed:T,indices:S,edgeIndices:R,primitive:"triangles",positionsDecodeMatrix:i.instancedPositionsDecodeMatrix}),B[ve]=!0),o.createMesh(mt.apply(Y,{id:Ce,color:Le,opacity:Fe,matrix:$,geometryId:ve})),Me.push(Ce)}else o.createMesh(mt.apply(Y,{id:Ce,primitive:"triangles",positionsCompressed:E,normalsCompressed:T,indices:S,edgeIndices:R,positionsDecodeMatrix:i.batchedPositionsDecodeMatrix,color:Le,opacity:Fe})),Me.push(Ce)}Me.length&&o.createEntity(mt.apply(W,{id:q,isObject:g[F]===1,meshIds:Me}))}}const Aee={version:3,parse:function(t,e,i,o,n,r){const a=B_t(i),s=E_t(a);I_t(t,e,s,o,n,r)}};let Ir=window.pako||ks;Ir.inflate||(Ir=Ir.default);function S_t(t){return{positions:t[0],normals:t[1],indices:t[2],edgeIndices:t[3],decodeMatrices:t[4],matrices:t[5],eachPrimitivePositionsAndNormalsPortion:t[6],eachPrimitiveIndicesPortion:t[7],eachPrimitiveEdgeIndicesPortion:t[8],eachPrimitiveDecodeMatricesPortion:t[9],eachPrimitiveColor:t[10],primitiveInstances:t[11],eachEntityId:t[12],eachEntityPrimitiveInstancesPortion:t[13],eachEntityMatricesPortion:t[14],eachEntityMatrix:t[15]}}function T_t(t){return{positions:new Uint16Array(Ir.inflate(t.positions).buffer),normals:new Int8Array(Ir.inflate(t.normals).buffer),indices:new Uint32Array(Ir.inflate(t.indices).buffer),edgeIndices:new Uint32Array(Ir.inflate(t.edgeIndices).buffer),decodeMatrices:new Float32Array(Ir.inflate(t.decodeMatrices).buffer),matrices:new Float32Array(Ir.inflate(t.matrices).buffer),eachPrimitivePositionsAndNormalsPortion:new Uint32Array(Ir.inflate(t.eachPrimitivePositionsAndNormalsPortion).buffer),eachPrimitiveIndicesPortion:new Uint32Array(Ir.inflate(t.eachPrimitiveIndicesPortion).buffer),eachPrimitiveEdgeIndicesPortion:new Uint32Array(Ir.inflate(t.eachPrimitiveEdgeIndicesPortion).buffer),eachPrimitiveDecodeMatricesPortion:new Uint32Array(Ir.inflate(t.eachPrimitiveDecodeMatricesPortion).buffer),eachPrimitiveColor:new Uint8Array(Ir.inflate(t.eachPrimitiveColor).buffer),primitiveInstances:new Uint32Array(Ir.inflate(t.primitiveInstances).buffer),eachEntityId:Ir.inflate(t.eachEntityId,{to:"string"}),eachEntityPrimitiveInstancesPortion:new Uint32Array(Ir.inflate(t.eachEntityPrimitiveInstancesPortion).buffer),eachEntityMatricesPortion:new Uint32Array(Ir.inflate(t.eachEntityMatricesPortion).buffer)}}const D_t=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();function R_t(t,e,i,o,n,r){const a=r.getNextId();o.positionsCompression="precompressed",o.normalsCompression="precompressed";const s=i.positions,l=i.normals,c=i.indices,d=i.edgeIndices,u=i.decodeMatrices,h=i.matrices,p=i.eachPrimitivePositionsAndNormalsPortion,A=i.eachPrimitiveIndicesPortion,f=i.eachPrimitiveEdgeIndicesPortion,m=i.eachPrimitiveDecodeMatricesPortion,g=i.eachPrimitiveColor,y=i.primitiveInstances,v=JSON.parse(i.eachEntityId),w=i.eachEntityPrimitiveInstancesPortion,x=i.eachEntityMatricesPortion,k=p.length,B=y.length,P=new Uint8Array(k),E=new Uint32Array(k),T=v.length;for(let F=0;F<k;F++)E[F]=F;E.sort((F,U)=>m[F]<m[U]?-1:m[F]>m[U]?1:0);for(let F=0;F<B;F++){const U=y[F];P[U]++}const S={};for(let F=0;F<T;F++){const U=T-1,q=F===U,V=w[F],W=q?w[U]:w[F+1];for(let Y=V;Y<W;Y++){const $=y[Y];P[$]>1||(S[$]=F)}}for(let F=0;F<k;F++){const U=E[F],q=U===k-1,V=P[U]>1,W=D_t(g.subarray(U*4,U*4+3)),Y=g[U*4+3]/255,$=s.subarray(p[U],q?s.length:p[U+1]),fe=l.subarray(p[U],q?l.length:p[U+1]),Me=c.subarray(A[U],q?c.length:A[U+1]),Se=d.subarray(f[U],q?d.length:f[U+1]),qe=u.subarray(m[U],m[U]+16);if(V){const Qe=`${a}-geometry.${U}`;o.createGeometry({id:Qe,primitive:"triangles",positionsCompressed:$,normalsCompressed:fe,indices:Me,edgeIndices:Se,positionsDecodeMatrix:qe})}else{const Qe=`${a}-${U}`,Ce=S[U];v[Ce];const Le={};o.createMesh(mt.apply(Le,{id:Qe,primitive:"triangles",positionsCompressed:$,normalsCompressed:fe,indices:Me,edgeIndices:Se,positionsDecodeMatrix:qe,color:W,opacity:Y}))}}let R=0;for(let F=0;F<T;F++){const U=T-1,q=F===U,V=v[F],W=w[F],Y=q?w[U]:w[F+1],$=[];for(let fe=W;fe<Y;fe++){const Me=y[fe];if(P[Me]>1){const Se={},qe=`${a}-instance.${R++}`,Qe=`${a}-geometry.${Me}`,Ce=x[F]*16,Le=h.subarray(Ce,Ce+16);o.createMesh(mt.apply(Se,{id:qe,geometryId:Qe,matrix:Le})),$.push(qe)}else $.push(Me)}if($.length>0){const fe={};o.createEntity(mt.apply(fe,{id:V,isObject:!0,meshIds:$}))}}}const gee={version:4,parse:function(t,e,i,o,n,r){const a=S_t(i),s=T_t(a);R_t(t,e,s,o,n,r)}};let un=window.pako||ks;un.inflate||(un=un.default);function L_t(t){return{positions:t[0],normals:t[1],indices:t[2],edgeIndices:t[3],matrices:t[4],eachPrimitivePositionsAndNormalsPortion:t[5],eachPrimitiveIndicesPortion:t[6],eachPrimitiveEdgeIndicesPortion:t[7],eachPrimitiveColor:t[8],primitiveInstances:t[9],eachEntityId:t[10],eachEntityPrimitiveInstancesPortion:t[11],eachEntityMatricesPortion:t[12]}}function __t(t){return{positions:new Float32Array(un.inflate(t.positions).buffer),normals:new Int8Array(un.inflate(t.normals).buffer),indices:new Uint32Array(un.inflate(t.indices).buffer),edgeIndices:new Uint32Array(un.inflate(t.edgeIndices).buffer),matrices:new Float32Array(un.inflate(t.matrices).buffer),eachPrimitivePositionsAndNormalsPortion:new Uint32Array(un.inflate(t.eachPrimitivePositionsAndNormalsPortion).buffer),eachPrimitiveIndicesPortion:new Uint32Array(un.inflate(t.eachPrimitiveIndicesPortion).buffer),eachPrimitiveEdgeIndicesPortion:new Uint32Array(un.inflate(t.eachPrimitiveEdgeIndicesPortion).buffer),eachPrimitiveColor:new Uint8Array(un.inflate(t.eachPrimitiveColor).buffer),primitiveInstances:new Uint32Array(un.inflate(t.primitiveInstances).buffer),eachEntityId:un.inflate(t.eachEntityId,{to:"string"}),eachEntityPrimitiveInstancesPortion:new Uint32Array(un.inflate(t.eachEntityPrimitiveInstancesPortion).buffer),eachEntityMatricesPortion:new Uint32Array(un.inflate(t.eachEntityMatricesPortion).buffer)}}const F_t=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();function O_t(t,e,i,o,n,r){const a=r.getNextId();o.positionsCompression="disabled",o.normalsCompression="precompressed";const s=i.positions,l=i.normals,c=i.indices,d=i.edgeIndices,u=i.matrices,h=i.eachPrimitivePositionsAndNormalsPortion,p=i.eachPrimitiveIndicesPortion,A=i.eachPrimitiveEdgeIndicesPortion,f=i.eachPrimitiveColor,m=i.primitiveInstances,g=JSON.parse(i.eachEntityId),y=i.eachEntityPrimitiveInstancesPortion,v=i.eachEntityMatricesPortion,w=h.length,x=m.length,k=new Uint8Array(w),B=g.length;for(let T=0;T<x;T++){const S=m[T];k[S]++}const P={};for(let T=0;T<B;T++){const S=B-1,R=T===S,F=y[T],U=R?y[S]:y[T+1];for(let q=F;q<U;q++){const V=m[q];k[V]>1||(P[V]=T)}}for(let T=0;T<w;T++){const S=T===w-1,R=k[T]>1,F=F_t(f.subarray(T*4,T*4+3)),U=f[T*4+3]/255,q=s.subarray(h[T],S?s.length:h[T+1]),V=l.subarray(h[T],S?l.length:h[T+1]),W=c.subarray(p[T],S?c.length:p[T+1]),Y=d.subarray(A[T],S?d.length:A[T+1]);if(R){const $=`${a}-geometry.${T}`;o.createGeometry({id:$,primitive:"triangles",positionsCompressed:q,normalsCompressed:V,indices:W,edgeIndices:Y})}else{const $=T,fe=P[T];g[fe];const Me={};o.createMesh(mt.apply(Me,{id:$,primitive:"triangles",positionsCompressed:q,normalsCompressed:V,indices:W,edgeIndices:Y,color:F,opacity:U}))}}let E=0;for(let T=0;T<B;T++){const S=B-1,R=T===S,F=g[T],U=y[T],q=R?y[S]:y[T+1],V=[];for(let W=U;W<q;W++){const Y=m[W];if(k[Y]>1){const $={},fe="instance."+E++,Me="geometry"+Y,Se=v[T]*16,qe=u.subarray(Se,Se+16);o.createMesh(mt.apply($,{id:fe,geometryId:Me,matrix:qe})),V.push(fe)}else V.push(Y)}if(V.length>0){const W={};o.createEntity(mt.apply(W,{id:F,isObject:!0,meshIds:V}))}}}const mee={version:5,parse:function(t,e,i,o,n,r){const a=L_t(i),s=__t(a);O_t(t,e,s,o,n,r)}};let O3=window.pako||ks;O3.inflate||(O3=O3.default);function U_t(t){return{positions:t[0],normals:t[1],indices:t[2],edgeIndices:t[3],matrices:t[4],reusedPrimitivesDecodeMatrix:t[5],eachPrimitivePositionsAndNormalsPortion:t[6],eachPrimitiveIndicesPortion:t[7],eachPrimitiveEdgeIndicesPortion:t[8],eachPrimitiveColorAndOpacity:t[9],primitiveInstances:t[10],eachEntityId:t[11],eachEntityPrimitiveInstancesPortion:t[12],eachEntityMatricesPortion:t[13],eachTileAABB:t[14],eachTileEntitiesPortion:t[15]}}function N_t(t){function e(i,o){return i.length===0?[]:O3.inflate(i,o).buffer}return{positions:new Uint16Array(e(t.positions)),normals:new Int8Array(e(t.normals)),indices:new Uint32Array(e(t.indices)),edgeIndices:new Uint32Array(e(t.edgeIndices)),matrices:new Float32Array(e(t.matrices)),reusedPrimitivesDecodeMatrix:new Float32Array(e(t.reusedPrimitivesDecodeMatrix)),eachPrimitivePositionsAndNormalsPortion:new Uint32Array(e(t.eachPrimitivePositionsAndNormalsPortion)),eachPrimitiveIndicesPortion:new Uint32Array(e(t.eachPrimitiveIndicesPortion)),eachPrimitiveEdgeIndicesPortion:new Uint32Array(e(t.eachPrimitiveEdgeIndicesPortion)),eachPrimitiveColorAndOpacity:new Uint8Array(e(t.eachPrimitiveColorAndOpacity)),primitiveInstances:new Uint32Array(e(t.primitiveInstances)),eachEntityId:O3.inflate(t.eachEntityId,{to:"string"}),eachEntityPrimitiveInstancesPortion:new Uint32Array(e(t.eachEntityPrimitiveInstancesPortion)),eachEntityMatricesPortion:new Uint32Array(e(t.eachEntityMatricesPortion)),eachTileAABB:new Float64Array(e(t.eachTileAABB)),eachTileEntitiesPortion:new Uint32Array(e(t.eachTileEntitiesPortion))}}const j_t=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();function V_t(t,e,i,o,n,r){const a=r.getNextId(),s=i.positions,l=i.normals,c=i.indices,d=i.edgeIndices,u=i.matrices,h=i.reusedPrimitivesDecodeMatrix,p=i.eachPrimitivePositionsAndNormalsPortion,A=i.eachPrimitiveIndicesPortion,f=i.eachPrimitiveEdgeIndicesPortion,m=i.eachPrimitiveColorAndOpacity,g=i.primitiveInstances,y=JSON.parse(i.eachEntityId),v=i.eachEntityPrimitiveInstancesPortion,w=i.eachEntityMatricesPortion,x=i.eachTileAABB,k=i.eachTileEntitiesPortion,B=p.length,P=g.length,E=y.length,T=k.length,S=new Uint32Array(B);for(let U=0;U<P;U++){const q=g[U];S[q]!==void 0?S[q]++:S[q]=1}const R=C.vec3(),F=C.AABB3();for(let U=0;U<T;U++){const q=T-1,V=U===q,W=k[U],Y=V?E:k[U+1],$=U*6,fe=x.subarray($,$+6);C.getAABB3Center(fe,R),F[0]=fe[0]-R[0],F[1]=fe[1]-R[1],F[2]=fe[2]-R[2],F[3]=fe[3]-R[0],F[4]=fe[4]-R[1],F[5]=fe[5]-R[2];const Me=Jt.createPositionsDecodeMatrix(F),Se={};for(let qe=W;qe<Y;qe++){const Qe=y[qe],Ce=e.globalizeObjectIds?C.globalizeObjectId(o.id,Qe):Qe,Le=w[qe],Fe=u.slice(Le,Le+16),ve=E-1,me=qe===ve,we=v[qe],Re=me?g.length:v[qe+1],We=[],H=t.metaScene.metaObjects[Ce],ee={},ae={};if(H){if(e.excludeTypesMap&&H.type&&e.excludeTypesMap[H.type]||e.includeTypesMap&&H.type&&!e.includeTypesMap[H.type]||e.includeIdsMap&&H.id&&!e.includeIdsMap[H.id])continue;const Ee=e.objectDefaults?e.objectDefaults[H.type]||e.objectDefaults.DEFAULT:null;Ee&&(Ee.visible===!1&&(ee.visible=!1),Ee.pickable===!1&&(ee.pickable=!1),Ee.colorize&&(ae.color=Ee.colorize),Ee.opacity!==void 0&&Ee.opacity!==null&&(ae.opacity=Ee.opacity))}else if(e.excludeUnclassifiedObjects)continue;for(let Ee=we;Ee<Re;Ee++){const pe=g[Ee],Q=S[pe]>1,Z=pe===B-1,ie=s.subarray(p[pe],Z?s.length:p[pe+1]),re=l.subarray(p[pe],Z?l.length:p[pe+1]),ne=c.subarray(A[pe],Z?c.length:A[pe+1]),G=d.subarray(f[pe],Z?d.length:f[pe+1]),K=j_t(m.subarray(pe*4,pe*4+3)),ue=m[pe*4+3]/255,xe=r.getNextId();if(Q){const oe=`${a}-geometry.${U}.${pe}`;Se[oe]||(o.createGeometry({id:oe,primitive:"triangles",positionsCompressed:ie,indices:ne,edgeIndices:G,positionsDecodeMatrix:h}),Se[oe]=!0),o.createMesh(mt.apply(ae,{id:xe,geometryId:oe,origin:R,matrix:Fe,color:K,opacity:ue})),We.push(xe)}else o.createMesh(mt.apply(ae,{id:xe,origin:R,primitive:"triangles",positionsCompressed:ie,normalsCompressed:re,indices:ne,edgeIndices:G,positionsDecodeMatrix:Me,color:K,opacity:ue})),We.push(xe)}We.length>0&&o.createEntity(mt.apply(ee,{id:Ce,isObject:!0,meshIds:We}))}}}const vee={version:6,parse:function(t,e,i,o,n,r){const a=U_t(i),s=N_t(a);V_t(t,e,s,o,n,r)}};let U3=window.pako||ks;U3.inflate||(U3=U3.default);function H_t(t){return{positions:t[0],normals:t[1],colors:t[2],indices:t[3],edgeIndices:t[4],matrices:t[5],reusedGeometriesDecodeMatrix:t[6],eachGeometryPrimitiveType:t[7],eachGeometryPositionsPortion:t[8],eachGeometryNormalsPortion:t[9],eachGeometryColorsPortion:t[10],eachGeometryIndicesPortion:t[11],eachGeometryEdgeIndicesPortion:t[12],eachMeshGeometriesPortion:t[13],eachMeshMatricesPortion:t[14],eachMeshMaterial:t[15],eachEntityId:t[16],eachEntityMeshesPortion:t[17],eachTileAABB:t[18],eachTileEntitiesPortion:t[19]}}function z_t(t){function e(i,o){return i.length===0?[]:U3.inflate(i,o).buffer}return{positions:new Uint16Array(e(t.positions)),normals:new Int8Array(e(t.normals)),colors:new Uint8Array(e(t.colors)),indices:new Uint32Array(e(t.indices)),edgeIndices:new Uint32Array(e(t.edgeIndices)),matrices:new Float32Array(e(t.matrices)),reusedGeometriesDecodeMatrix:new Float32Array(e(t.reusedGeometriesDecodeMatrix)),eachGeometryPrimitiveType:new Uint8Array(e(t.eachGeometryPrimitiveType)),eachGeometryPositionsPortion:new Uint32Array(e(t.eachGeometryPositionsPortion)),eachGeometryNormalsPortion:new Uint32Array(e(t.eachGeometryNormalsPortion)),eachGeometryColorsPortion:new Uint32Array(e(t.eachGeometryColorsPortion)),eachGeometryIndicesPortion:new Uint32Array(e(t.eachGeometryIndicesPortion)),eachGeometryEdgeIndicesPortion:new Uint32Array(e(t.eachGeometryEdgeIndicesPortion)),eachMeshGeometriesPortion:new Uint32Array(e(t.eachMeshGeometriesPortion)),eachMeshMatricesPortion:new Uint32Array(e(t.eachMeshMatricesPortion)),eachMeshMaterial:new Uint8Array(e(t.eachMeshMaterial)),eachEntityId:U3.inflate(t.eachEntityId,{to:"string"}),eachEntityMeshesPortion:new Uint32Array(e(t.eachEntityMeshesPortion)),eachTileAABB:new Float64Array(e(t.eachTileAABB)),eachTileEntitiesPortion:new Uint32Array(e(t.eachTileEntitiesPortion))}}const q_t=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();function yee(t){const e=[];for(let i=0,o=t.length;i<o;i+=3)e.push(t[i]),e.push(t[i+1]),e.push(t[i+2]),e.push(1);return e}function Q_t(t,e,i,o,n,r){const a=r.getNextId(),s=i.positions,l=i.normals,c=i.colors,d=i.indices,u=i.edgeIndices,h=i.matrices,p=i.reusedGeometriesDecodeMatrix,A=i.eachGeometryPrimitiveType,f=i.eachGeometryPositionsPortion,m=i.eachGeometryNormalsPortion,g=i.eachGeometryColorsPortion,y=i.eachGeometryIndicesPortion,v=i.eachGeometryEdgeIndicesPortion,w=i.eachMeshGeometriesPortion,x=i.eachMeshMatricesPortion,k=i.eachMeshMaterial,B=JSON.parse(i.eachEntityId),P=i.eachEntityMeshesPortion,E=i.eachTileAABB,T=i.eachTileEntitiesPortion,S=f.length,R=w.length,F=B.length,U=T.length,q=new Uint32Array(S);for(let Y=0;Y<R;Y++){const $=w[Y];q[$]!==void 0?q[$]++:q[$]=1}const V=C.vec3(),W=C.AABB3();for(let Y=0;Y<U;Y++){const $=U-1,fe=Y===$,Me=T[Y],Se=fe?F:T[Y+1],qe=Y*6,Qe=E.subarray(qe,qe+6);C.getAABB3Center(Qe,V),W[0]=Qe[0]-V[0],W[1]=Qe[1]-V[1],W[2]=Qe[2]-V[2],W[3]=Qe[3]-V[0],W[4]=Qe[4]-V[1],W[5]=Qe[5]-V[2];const Ce=Jt.createPositionsDecodeMatrix(W),Le={};for(let Fe=Me;Fe<Se;Fe++){const ve=B[Fe],me=e.globalizeObjectIds?C.globalizeObjectId(o.id,ve):ve,we=F-1,Re=Fe===we,We=P[Fe],H=Re?w.length:P[Fe+1],ee=[],ae=t.metaScene.metaObjects[me],Ee={},pe={};if(ae){if(e.excludeTypesMap&&ae.type&&e.excludeTypesMap[ae.type]||e.includeTypesMap&&ae.type&&!e.includeTypesMap[ae.type]||e.includeIdsMap&&ae.id&&!e.includeIdsMap[ae.id])continue;const Q=e.objectDefaults?e.objectDefaults[ae.type]||e.objectDefaults.DEFAULT:null;Q&&(Q.visible===!1&&(Ee.visible=!1),Q.pickable===!1&&(Ee.pickable=!1),Q.colorize&&(pe.color=Q.colorize),Q.opacity!==void 0&&Q.opacity!==null&&(pe.opacity=Q.opacity),Q.metallic!==void 0&&Q.metallic!==null&&(pe.metallic=Q.metallic),Q.roughness!==void 0&&Q.roughness!==null&&(pe.roughness=Q.roughness))}else if(e.excludeUnclassifiedObjects)continue;for(let Q=We;Q<H;Q++){const Z=w[Q],ie=q[Z]>1,re=Z===S-1,ne=q_t(k.subarray(Q*6,Q*6+3)),G=k[Q*6+3]/255,K=k[Q*6+4]/255,ue=k[Q*6+5]/255,xe=r.getNextId();if(ie){const oe=x[Q],Be=h.slice(oe,oe+16),je=`${a}-geometry.${Y}.${Z}`;if(!Le[je]){const he=A[Z];let Ne,Pe,ze,rt,At,ft;switch(he){case 0:Ne="solid",Pe=s.subarray(f[Z],re?s.length:f[Z+1]),ze=l.subarray(m[Z],re?l.length:m[Z+1]),At=d.subarray(y[Z],re?d.length:y[Z+1]),ft=u.subarray(v[Z],re?u.length:v[Z+1]);break;case 1:Ne="surface",Pe=s.subarray(f[Z],re?s.length:f[Z+1]),ze=l.subarray(m[Z],re?l.length:m[Z+1]),At=d.subarray(y[Z],re?d.length:y[Z+1]),ft=u.subarray(v[Z],re?u.length:v[Z+1]);break;case 2:Ne="points",Pe=s.subarray(f[Z],re?s.length:f[Z+1]),rt=yee(c.subarray(g[Z],re?c.length:g[Z+1]));break;case 3:Ne="lines",Pe=s.subarray(f[Z],re?s.length:f[Z+1]),At=d.subarray(y[Z],re?d.length:y[Z+1]);break;default:continue}o.createGeometry({id:je,primitive:Ne,positionsCompressed:Pe,normalsCompressed:ze,colors:rt,indices:At,edgeIndices:ft,positionsDecodeMatrix:p}),Le[je]=!0}o.createMesh(mt.apply(pe,{id:xe,geometryId:je,origin:V,matrix:Be,color:ne,metallic:K,roughness:ue,opacity:G})),ee.push(xe)}else{const oe=A[Z];let Be,je,he,Ne,Pe,ze;switch(oe){case 0:Be="solid",je=s.subarray(f[Z],re?s.length:f[Z+1]),he=l.subarray(m[Z],re?l.length:m[Z+1]),Pe=d.subarray(y[Z],re?d.length:y[Z+1]),ze=u.subarray(v[Z],re?u.length:v[Z+1]);break;case 1:Be="surface",je=s.subarray(f[Z],re?s.length:f[Z+1]),he=l.subarray(m[Z],re?l.length:m[Z+1]),Pe=d.subarray(y[Z],re?d.length:y[Z+1]),ze=u.subarray(v[Z],re?u.length:v[Z+1]);break;case 2:Be="points",je=s.subarray(f[Z],re?s.length:f[Z+1]),Ne=yee(c.subarray(g[Z],re?c.length:g[Z+1]));break;case 3:Be="lines",je=s.subarray(f[Z],re?s.length:f[Z+1]),Pe=d.subarray(y[Z],re?d.length:y[Z+1]);break;default:continue}o.createMesh(mt.apply(pe,{id:xe,origin:V,primitive:Be,positionsCompressed:je,normalsCompressed:he,colors:Ne,indices:Pe,edgeIndices:ze,positionsDecodeMatrix:Ce,color:ne,metallic:K,roughness:ue,opacity:G})),ee.push(xe)}}ee.length>0&&o.createEntity(mt.apply(Ee,{id:me,isObject:!0,meshIds:ee}))}}}const bee={version:7,parse:function(t,e,i,o,n,r){const a=H_t(i),s=z_t(a);Q_t(t,e,s,o,n,r)}};let Ch=window.pako||ks;Ch.inflate||(Ch=Ch.default);const mc=C.vec4(),wee=C.vec4();function G_t(t){return{types:t[0],eachMetaObjectId:t[1],eachMetaObjectType:t[2],eachMetaObjectName:t[3],eachMetaObjectParent:t[4],positions:t[5],normals:t[6],colors:t[7],indices:t[8],edgeIndices:t[9],matrices:t[10],reusedGeometriesDecodeMatrix:t[11],eachGeometryPrimitiveType:t[12],eachGeometryPositionsPortion:t[13],eachGeometryNormalsPortion:t[14],eachGeometryColorsPortion:t[15],eachGeometryIndicesPortion:t[16],eachGeometryEdgeIndicesPortion:t[17],eachMeshGeometriesPortion:t[18],eachMeshMatricesPortion:t[19],eachMeshMaterial:t[20],eachEntityMetaObject:t[21],eachEntityMeshesPortion:t[22],eachTileAABB:t[23],eachTileEntitiesPortion:t[24]}}function K_t(t){function e(i,o){return i.length===0?[]:Ch.inflate(i,o).buffer}return{types:Ch.inflate(t.types,{to:"string"}),eachMetaObjectId:Ch.inflate(t.eachMetaObjectId,{to:"string"}),eachMetaObjectType:new Uint32Array(e(t.eachMetaObjectType)),eachMetaObjectName:Ch.inflate(t.eachMetaObjectName,{to:"string"}),eachMetaObjectParent:new Uint32Array(e(t.eachMetaObjectParent)),positions:new Uint16Array(e(t.positions)),normals:new Int8Array(e(t.normals)),colors:new Uint8Array(e(t.colors)),indices:new Uint32Array(e(t.indices)),edgeIndices:new Uint32Array(e(t.edgeIndices)),matrices:new Float32Array(e(t.matrices)),reusedGeometriesDecodeMatrix:new Float32Array(e(t.reusedGeometriesDecodeMatrix)),eachGeometryPrimitiveType:new Uint8Array(e(t.eachGeometryPrimitiveType)),eachGeometryPositionsPortion:new Uint32Array(e(t.eachGeometryPositionsPortion)),eachGeometryNormalsPortion:new Uint32Array(e(t.eachGeometryNormalsPortion)),eachGeometryColorsPortion:new Uint32Array(e(t.eachGeometryColorsPortion)),eachGeometryIndicesPortion:new Uint32Array(e(t.eachGeometryIndicesPortion)),eachGeometryEdgeIndicesPortion:new Uint32Array(e(t.eachGeometryEdgeIndicesPortion)),eachMeshGeometriesPortion:new Uint32Array(e(t.eachMeshGeometriesPortion)),eachMeshMatricesPortion:new Uint32Array(e(t.eachMeshMatricesPortion)),eachMeshMaterial:new Uint8Array(e(t.eachMeshMaterial)),eachEntityMetaObject:new Uint32Array(e(t.eachEntityMetaObject)),eachEntityMeshesPortion:new Uint32Array(e(t.eachEntityMeshesPortion)),eachTileAABB:new Float64Array(e(t.eachTileAABB)),eachTileEntitiesPortion:new Uint32Array(e(t.eachTileEntitiesPortion))}}const J_t=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();function Cee(t){const e=[];for(let i=0,o=t.length;i<o;i+=3)e.push(t[i]),e.push(t[i+1]),e.push(t[i+2]),e.push(1);return e}function Z_t(t,e,i,o,n,r){const a=r.getNextId(),s=JSON.parse(i.types),l=JSON.parse(i.eachMetaObjectId),c=i.eachMetaObjectType,d=JSON.parse(i.eachMetaObjectName),u=i.eachMetaObjectParent,h=i.positions,p=i.normals,A=i.colors,f=i.indices,m=i.edgeIndices,g=i.matrices,y=i.reusedGeometriesDecodeMatrix,v=i.eachGeometryPrimitiveType,w=i.eachGeometryPositionsPortion,x=i.eachGeometryNormalsPortion,k=i.eachGeometryColorsPortion,B=i.eachGeometryIndicesPortion,P=i.eachGeometryEdgeIndicesPortion,E=i.eachMeshGeometriesPortion,T=i.eachMeshMatricesPortion,S=i.eachMeshMaterial,R=i.eachEntityMetaObject,F=i.eachEntityMeshesPortion,U=i.eachTileAABB,q=i.eachTileEntitiesPortion,V=l.length,W=w.length,Y=E.length,$=R.length,fe=q.length;if(n){const Ce={metaObjects:[]};for(let Le=0;Le<V;Le++){const Fe=l[Le],ve=c[Le],me=s[ve]||"default",we=d[Le],Re=u[Le],We=Re!==Le?l[Re]:null;Ce.metaObjects.push({id:Fe,type:me,name:we,parent:We})}n.loadData(Ce,{includeTypes:e.includeTypes,excludeTypes:e.excludeTypes,globalizeObjectIds:e.globalizeObjectIds})}const Me=new Uint32Array(W);for(let Ce=0;Ce<Y;Ce++){const Le=E[Ce];Me[Le]!==void 0?Me[Le]++:Me[Le]=1}const Se=C.vec3(),qe=C.AABB3(),Qe={};for(let Ce=0;Ce<fe;Ce++){const Le=fe-1,Fe=Ce===Le,ve=q[Ce],me=Fe?$:q[Ce+1],we=Ce*6,Re=U.subarray(we,we+6);C.getAABB3Center(Re,Se),qe[0]=Re[0]-Se[0],qe[1]=Re[1]-Se[1],qe[2]=Re[2]-Se[2],qe[3]=Re[3]-Se[0],qe[4]=Re[4]-Se[1],qe[5]=Re[5]-Se[2];const We=Jt.createPositionsDecodeMatrix(qe),H={};for(let ee=ve;ee<me;ee++){const ae=R[ee],Ee=l[ae],pe=e.globalizeObjectIds?C.globalizeObjectId(o.id,Ee):Ee,Q=$-1,Z=ee===Q,ie=F[ee],re=Z?E.length:F[ee+1],ne=[],G=t.metaScene.metaObjects[pe],K={},ue={};if(G){if(e.excludeTypesMap&&G.type&&e.excludeTypesMap[G.type]||e.includeTypesMap&&G.type&&!e.includeTypesMap[G.type]||e.includeIdsMap&&G.id&&!e.includeIdsMap[G.id])continue;const xe=e.objectDefaults?e.objectDefaults[G.type]||e.objectDefaults.DEFAULT:null;xe&&(xe.visible===!1&&(K.visible=!1),xe.pickable===!1&&(K.pickable=!1),xe.colorize&&(ue.color=xe.colorize),xe.opacity!==void 0&&xe.opacity!==null&&(ue.opacity=xe.opacity),xe.metallic!==void 0&&xe.metallic!==null&&(ue.metallic=xe.metallic),xe.roughness!==void 0&&xe.roughness!==null&&(ue.roughness=xe.roughness))}else if(e.excludeUnclassifiedObjects)continue;for(let xe=ie;xe<re;xe++){const oe=E[xe],Be=Me[oe]>1,je=oe===W-1,he=J_t(S.subarray(xe*6,xe*6+3)),Ne=S[xe*6+3]/255,Pe=S[xe*6+4]/255,ze=S[xe*6+5]/255,rt=r.getNextId();if(Be){const At=T[xe],ft=g.slice(At,At+16),lt=`${a}-geometry.${Ce}.${oe}`;let ut=Qe[lt];if(!ut){ut={batchThisMesh:!e.reuseGeometries};const Te=v[oe];let st=!1;switch(Te){case 0:ut.primitiveName="solid",ut.geometryPositions=h.subarray(w[oe],je?h.length:w[oe+1]),ut.geometryNormals=p.subarray(x[oe],je?p.length:x[oe+1]),ut.geometryIndices=f.subarray(B[oe],je?f.length:B[oe+1]),ut.geometryEdgeIndices=m.subarray(P[oe],je?m.length:P[oe+1]),st=ut.geometryPositions.length>0&&ut.geometryIndices.length>0;break;case 1:ut.primitiveName="surface",ut.geometryPositions=h.subarray(w[oe],je?h.length:w[oe+1]),ut.geometryNormals=p.subarray(x[oe],je?p.length:x[oe+1]),ut.geometryIndices=f.subarray(B[oe],je?f.length:B[oe+1]),ut.geometryEdgeIndices=m.subarray(P[oe],je?m.length:P[oe+1]),st=ut.geometryPositions.length>0&&ut.geometryIndices.length>0;break;case 2:ut.primitiveName="points",ut.geometryPositions=h.subarray(w[oe],je?h.length:w[oe+1]),ut.geometryColors=Cee(A.subarray(k[oe],je?A.length:k[oe+1])),st=ut.geometryPositions.length>0;break;case 3:ut.primitiveName="lines",ut.geometryPositions=h.subarray(w[oe],je?h.length:w[oe+1]),ut.geometryIndices=f.subarray(B[oe],je?f.length:B[oe+1]),st=ut.geometryPositions.length>0&&ut.geometryIndices.length>0;break;default:continue}if(st||(ut=null),ut&&(ut.geometryPositions.length>1e3,ut.batchThisMesh)){ut.decompressedPositions=new Float32Array(ut.geometryPositions.length);const dt=ut.geometryPositions,Ye=ut.decompressedPositions;for(let Ae=0,be=dt.length;Ae<be;Ae+=3)Ye[Ae+0]=dt[Ae+0]*y[0]+y[12],Ye[Ae+1]=dt[Ae+1]*y[5]+y[13],Ye[Ae+2]=dt[Ae+2]*y[10]+y[14];ut.geometryPositions=null,Qe[lt]=ut}}if(ut)if(ut.batchThisMesh){const Te=ut.decompressedPositions,st=new Uint16Array(Te.length);for(let dt=0,Ye=Te.length;dt<Ye;dt+=3)mc[0]=Te[dt+0],mc[1]=Te[dt+1],mc[2]=Te[dt+2],mc[3]=1,C.transformVec4(ft,mc,wee),Jt.compressPosition(wee,qe,mc),st[dt+0]=mc[0],st[dt+1]=mc[1],st[dt+2]=mc[2];o.createMesh(mt.apply(ue,{id:rt,origin:Se,primitive:ut.primitiveName,positionsCompressed:st,normalsCompressed:ut.geometryNormals,colorsCompressed:ut.geometryColors,indices:ut.geometryIndices,edgeIndices:ut.geometryEdgeIndices,positionsDecodeMatrix:We,color:he,metallic:Pe,roughness:ze,opacity:Ne})),ne.push(rt)}else H[lt]||(o.createGeometry({id:lt,primitive:ut.primitiveName,positionsCompressed:ut.geometryPositions,normalsCompressed:ut.geometryNormals,colorsCompressed:ut.geometryColors,indices:ut.geometryIndices,edgeIndices:ut.geometryEdgeIndices,positionsDecodeMatrix:y}),H[lt]=!0),o.createMesh(mt.apply(ue,{id:rt,geometryId:lt,origin:Se,matrix:ft,color:he,metallic:Pe,roughness:ze,opacity:Ne})),ne.push(rt)}else{const At=v[oe];let ft,lt,ut,Te,st,dt,Ye=!1;switch(At){case 0:ft="solid",lt=h.subarray(w[oe],je?h.length:w[oe+1]),ut=p.subarray(x[oe],je?p.length:x[oe+1]),st=f.subarray(B[oe],je?f.length:B[oe+1]),dt=m.subarray(P[oe],je?m.length:P[oe+1]),Ye=lt.length>0&&st.length>0;break;case 1:ft="surface",lt=h.subarray(w[oe],je?h.length:w[oe+1]),ut=p.subarray(x[oe],je?p.length:x[oe+1]),st=f.subarray(B[oe],je?f.length:B[oe+1]),dt=m.subarray(P[oe],je?m.length:P[oe+1]),Ye=lt.length>0&&st.length>0;break;case 2:ft="points",lt=h.subarray(w[oe],je?h.length:w[oe+1]),Te=Cee(A.subarray(k[oe],je?A.length:k[oe+1])),Ye=lt.length>0;break;case 3:ft="lines",lt=h.subarray(w[oe],je?h.length:w[oe+1]),st=f.subarray(B[oe],je?f.length:B[oe+1]),Ye=lt.length>0&&st.length>0;break;default:continue}Ye&&(o.createMesh(mt.apply(ue,{id:rt,origin:Se,primitive:ft,positionsCompressed:lt,normalsCompressed:ut,colorsCompressed:Te,indices:st,edgeIndices:dt,positionsDecodeMatrix:We,color:he,metallic:Pe,roughness:ze,opacity:Ne})),ne.push(rt))}}ne.length>0&&o.createEntity(mt.apply(K,{id:pe,isObject:!0,meshIds:ne}))}}}const xee={version:8,parse:function(t,e,i,o,n,r){const a=G_t(i),s=K_t(a);Z_t(t,e,s,o,n,r)}};let q1=window.pako||ks;q1.inflate||(q1=q1.default);const vc=C.vec4(),kee=C.vec4();function W_t(t){return{metadata:t[0],positions:t[1],normals:t[2],colors:t[3],indices:t[4],edgeIndices:t[5],matrices:t[6],reusedGeometriesDecodeMatrix:t[7],eachGeometryPrimitiveType:t[8],eachGeometryPositionsPortion:t[9],eachGeometryNormalsPortion:t[10],eachGeometryColorsPortion:t[11],eachGeometryIndicesPortion:t[12],eachGeometryEdgeIndicesPortion:t[13],eachMeshGeometriesPortion:t[14],eachMeshMatricesPortion:t[15],eachMeshMaterial:t[16],eachEntityId:t[17],eachEntityMeshesPortion:t[18],eachTileAABB:t[19],eachTileEntitiesPortion:t[20]}}function Y_t(t){function e(i,o){return i.length===0?[]:q1.inflate(i,o).buffer}return{metadata:JSON.parse(q1.inflate(t.metadata,{to:"string"})),positions:new Uint16Array(e(t.positions)),normals:new Int8Array(e(t.normals)),colors:new Uint8Array(e(t.colors)),indices:new Uint32Array(e(t.indices)),edgeIndices:new Uint32Array(e(t.edgeIndices)),matrices:new Float32Array(e(t.matrices)),reusedGeometriesDecodeMatrix:new Float32Array(e(t.reusedGeometriesDecodeMatrix)),eachGeometryPrimitiveType:new Uint8Array(e(t.eachGeometryPrimitiveType)),eachGeometryPositionsPortion:new Uint32Array(e(t.eachGeometryPositionsPortion)),eachGeometryNormalsPortion:new Uint32Array(e(t.eachGeometryNormalsPortion)),eachGeometryColorsPortion:new Uint32Array(e(t.eachGeometryColorsPortion)),eachGeometryIndicesPortion:new Uint32Array(e(t.eachGeometryIndicesPortion)),eachGeometryEdgeIndicesPortion:new Uint32Array(e(t.eachGeometryEdgeIndicesPortion)),eachMeshGeometriesPortion:new Uint32Array(e(t.eachMeshGeometriesPortion)),eachMeshMatricesPortion:new Uint32Array(e(t.eachMeshMatricesPortion)),eachMeshMaterial:new Uint8Array(e(t.eachMeshMaterial)),eachEntityId:JSON.parse(q1.inflate(t.eachEntityId,{to:"string"})),eachEntityMeshesPortion:new Uint32Array(e(t.eachEntityMeshesPortion)),eachTileAABB:new Float64Array(e(t.eachTileAABB)),eachTileEntitiesPortion:new Uint32Array(e(t.eachTileEntitiesPortion))}}const X_t=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();function $_t(t,e,i,o,n,r){const a=r.getNextId(),s=i.metadata,l=i.positions,c=i.normals,d=i.colors,u=i.indices,h=i.edgeIndices,p=i.matrices,A=i.reusedGeometriesDecodeMatrix,f=i.eachGeometryPrimitiveType,m=i.eachGeometryPositionsPortion,g=i.eachGeometryNormalsPortion,y=i.eachGeometryColorsPortion,v=i.eachGeometryIndicesPortion,w=i.eachGeometryEdgeIndicesPortion,x=i.eachMeshGeometriesPortion,k=i.eachMeshMatricesPortion,B=i.eachMeshMaterial,P=i.eachEntityId,E=i.eachEntityMeshesPortion,T=i.eachTileAABB,S=i.eachTileEntitiesPortion,R=m.length,F=x.length,U=E.length,q=S.length;n&&n.loadData(s,{includeTypes:e.includeTypes,excludeTypes:e.excludeTypes,globalizeObjectIds:e.globalizeObjectIds});const V=new Uint32Array(R);for(let fe=0;fe<F;fe++){const Me=x[fe];V[Me]!==void 0?V[Me]++:V[Me]=1}const W=C.vec3(),Y=C.AABB3(),$={};for(let fe=0;fe<q;fe++){const Me=q-1,Se=fe===Me,qe=S[fe],Qe=Se?U-1:S[fe+1]-1,Ce=fe*6,Le=T.subarray(Ce,Ce+6);C.getAABB3Center(Le,W),Y[0]=Le[0]-W[0],Y[1]=Le[1]-W[1],Y[2]=Le[2]-W[2],Y[3]=Le[3]-W[0],Y[4]=Le[4]-W[1],Y[5]=Le[5]-W[2];const Fe=Jt.createPositionsDecodeMatrix(Y),ve={};for(let me=qe;me<=Qe;me++){const we=P[me],Re=e.globalizeObjectIds?C.globalizeObjectId(o.id,we):we,We=U-1,H=me===We,ee=E[me],ae=H?x.length-1:E[me+1]-1,Ee=[],pe=t.metaScene.metaObjects[Re],Q={},Z={};if(!(e.includeIdsMap&&we&&!e.includeIdsMap[we])){if(pe){if(e.excludeTypesMap&&pe.type&&e.excludeTypesMap[pe.type]||e.includeTypesMap&&pe.type&&!e.includeTypesMap[pe.type]||e.includeIdsMap&&pe.id&&!e.includeIdsMap[pe.id])continue;const ie=e.objectDefaults?e.objectDefaults[pe.type]||e.objectDefaults.DEFAULT:null;ie&&(ie.visible===!1&&(Q.visible=!1),ie.pickable===!1&&(Q.pickable=!1),ie.colorize&&(Z.color=ie.colorize),ie.opacity!==void 0&&ie.opacity!==null&&(Z.opacity=ie.opacity),ie.metallic!==void 0&&ie.metallic!==null&&(Z.metallic=ie.metallic),ie.roughness!==void 0&&ie.roughness!==null&&(Z.roughness=ie.roughness))}else if(e.excludeUnclassifiedObjects)continue;for(let ie=ee;ie<=ae;ie++){const re=x[ie],ne=V[re]>1,G=re===R-1,K=X_t(B.subarray(ie*6,ie*6+3)),ue=B[ie*6+3]/255,xe=B[ie*6+4]/255,oe=B[ie*6+5]/255,Be=r.getNextId();if(ne){const je=k[ie],he=p.slice(je,je+16),Ne=`${a}-geometry.${fe}.${re}`;let Pe=$[Ne];if(!Pe){Pe={batchThisMesh:!e.reuseGeometries};const ze=f[re];let rt=!1;switch(ze){case 0:Pe.primitiveName="solid",Pe.geometryPositions=l.subarray(m[re],G?l.length:m[re+1]),Pe.geometryNormals=c.subarray(g[re],G?c.length:g[re+1]),Pe.geometryIndices=u.subarray(v[re],G?u.length:v[re+1]),Pe.geometryEdgeIndices=h.subarray(w[re],G?h.length:w[re+1]),rt=Pe.geometryPositions.length>0&&Pe.geometryIndices.length>0;break;case 1:Pe.primitiveName="surface",Pe.geometryPositions=l.subarray(m[re],G?l.length:m[re+1]),Pe.geometryNormals=c.subarray(g[re],G?c.length:g[re+1]),Pe.geometryIndices=u.subarray(v[re],G?u.length:v[re+1]),Pe.geometryEdgeIndices=h.subarray(w[re],G?h.length:w[re+1]),rt=Pe.geometryPositions.length>0&&Pe.geometryIndices.length>0;break;case 2:Pe.primitiveName="points",Pe.geometryPositions=l.subarray(m[re],G?l.length:m[re+1]),Pe.geometryColors=d.subarray(y[re],G?d.length:y[re+1]),rt=Pe.geometryPositions.length>0;break;case 3:Pe.primitiveName="lines",Pe.geometryPositions=l.subarray(m[re],G?l.length:m[re+1]),Pe.geometryIndices=u.subarray(v[re],G?u.length:v[re+1]),rt=Pe.geometryPositions.length>0&&Pe.geometryIndices.length>0;break;default:continue}if(rt||(Pe=null),Pe&&(Pe.geometryPositions.length>1e3,Pe.batchThisMesh)){Pe.decompressedPositions=new Float32Array(Pe.geometryPositions.length),Pe.transformedAndRecompressedPositions=new Uint16Array(Pe.geometryPositions.length);const At=Pe.geometryPositions,ft=Pe.decompressedPositions;for(let lt=0,ut=At.length;lt<ut;lt+=3)ft[lt+0]=At[lt+0]*A[0]+A[12],ft[lt+1]=At[lt+1]*A[5]+A[13],ft[lt+2]=At[lt+2]*A[10]+A[14];Pe.geometryPositions=null,$[Ne]=Pe}}if(Pe)if(Pe.batchThisMesh){const ze=Pe.decompressedPositions,rt=Pe.transformedAndRecompressedPositions;for(let At=0,ft=ze.length;At<ft;At+=3)vc[0]=ze[At+0],vc[1]=ze[At+1],vc[2]=ze[At+2],vc[3]=1,C.transformVec4(he,vc,kee),Jt.compressPosition(kee,Y,vc),rt[At+0]=vc[0],rt[At+1]=vc[1],rt[At+2]=vc[2];o.createMesh(mt.apply(Z,{id:Be,origin:W,primitive:Pe.primitiveName,positionsCompressed:rt,normalsCompressed:Pe.geometryNormals,colorsCompressed:Pe.geometryColors,indices:Pe.geometryIndices,edgeIndices:Pe.geometryEdgeIndices,positionsDecodeMatrix:Fe,color:K,metallic:xe,roughness:oe,opacity:ue})),Ee.push(Be)}else ve[Ne]||(o.createGeometry({id:Ne,primitive:Pe.primitiveName,positionsCompressed:Pe.geometryPositions,normalsCompressed:Pe.geometryNormals,colorsCompressed:Pe.geometryColors,indices:Pe.geometryIndices,edgeIndices:Pe.geometryEdgeIndices,positionsDecodeMatrix:A}),ve[Ne]=!0),o.createMesh(mt.apply(Z,{id:Be,geometryId:Ne,origin:W,matrix:he,color:K,metallic:xe,roughness:oe,opacity:ue})),Ee.push(Be)}else{const je=f[re];let he,Ne,Pe,ze,rt,At,ft=!1;switch(je){case 0:he="solid",Ne=l.subarray(m[re],G?l.length:m[re+1]),Pe=c.subarray(g[re],G?c.length:g[re+1]),rt=u.subarray(v[re],G?u.length:v[re+1]),At=h.subarray(w[re],G?h.length:w[re+1]),ft=Ne.length>0&&rt.length>0;break;case 1:he="surface",Ne=l.subarray(m[re],G?l.length:m[re+1]),Pe=c.subarray(g[re],G?c.length:g[re+1]),rt=u.subarray(v[re],G?u.length:v[re+1]),At=h.subarray(w[re],G?h.length:w[re+1]),ft=Ne.length>0&&rt.length>0;break;case 2:he="points",Ne=l.subarray(m[re],G?l.length:m[re+1]),ze=d.subarray(y[re],G?d.length:y[re+1]),ft=Ne.length>0;break;case 3:he="lines",Ne=l.subarray(m[re],G?l.length:m[re+1]),rt=u.subarray(v[re],G?u.length:v[re+1]),ft=Ne.length>0&&rt.length>0;break;default:continue}ft&&(o.createMesh(mt.apply(Z,{id:Be,origin:W,primitive:he,positionsCompressed:Ne,normalsCompressed:Pe,colorsCompressed:ze,indices:rt,edgeIndices:At,positionsDecodeMatrix:Fe,color:K,metallic:xe,roughness:oe,opacity:ue})),Ee.push(Be))}}Ee.length>0&&o.createEntity(mt.apply(Q,{id:Re,isObject:!0,meshIds:Ee}))}}}}const Mee={version:9,parse:function(t,e,i,o,n,r){const a=W_t(i),s=Y_t(a);$_t(t,e,s,o,n,r)}};let Q1=window.pako||ks;Q1.inflate||(Q1=Q1.default);const yc=C.vec4(),Bee=C.vec4(),eFt=9;function tFt(t){let e=0;return{metadata:t[e++],textureData:t[e++],eachTextureDataPortion:t[e++],eachTextureAttributes:t[e++],positions:t[e++],normals:t[e++],colors:t[e++],uvs:t[e++],indices:t[e++],edgeIndices:t[e++],eachTextureSetTextures:t[e++],matrices:t[e++],reusedGeometriesDecodeMatrix:t[e++],eachGeometryPrimitiveType:t[e++],eachGeometryPositionsPortion:t[e++],eachGeometryNormalsPortion:t[e++],eachGeometryColorsPortion:t[e++],eachGeometryUVsPortion:t[e++],eachGeometryIndicesPortion:t[e++],eachGeometryEdgeIndicesPortion:t[e++],eachMeshGeometriesPortion:t[e++],eachMeshMatricesPortion:t[e++],eachMeshTextureSet:t[e++],eachMeshMaterialAttributes:t[e++],eachEntityId:t[e++],eachEntityMeshesPortion:t[e++],eachTileAABB:t[e++],eachTileEntitiesPortion:t[e++]}}function iFt(t){function e(i,o){return i.length===0?[]:Q1.inflate(i,o).buffer}return{metadata:JSON.parse(Q1.inflate(t.metadata,{to:"string"})),textureData:new Uint8Array(e(t.textureData)),eachTextureDataPortion:new Uint32Array(e(t.eachTextureDataPortion)),eachTextureAttributes:new Uint16Array(e(t.eachTextureAttributes)),positions:new Uint16Array(e(t.positions)),normals:new Int8Array(e(t.normals)),colors:new Uint8Array(e(t.colors)),uvs:new Float32Array(e(t.uvs)),indices:new Uint32Array(e(t.indices)),edgeIndices:new Uint32Array(e(t.edgeIndices)),eachTextureSetTextures:new Int32Array(e(t.eachTextureSetTextures)),matrices:new Float32Array(e(t.matrices)),reusedGeometriesDecodeMatrix:new Float32Array(e(t.reusedGeometriesDecodeMatrix)),eachGeometryPrimitiveType:new Uint8Array(e(t.eachGeometryPrimitiveType)),eachGeometryPositionsPortion:new Uint32Array(e(t.eachGeometryPositionsPortion)),eachGeometryNormalsPortion:new Uint32Array(e(t.eachGeometryNormalsPortion)),eachGeometryColorsPortion:new Uint32Array(e(t.eachGeometryColorsPortion)),eachGeometryUVsPortion:new Uint32Array(e(t.eachGeometryUVsPortion)),eachGeometryIndicesPortion:new Uint32Array(e(t.eachGeometryIndicesPortion)),eachGeometryEdgeIndicesPortion:new Uint32Array(e(t.eachGeometryEdgeIndicesPortion)),eachMeshGeometriesPortion:new Uint32Array(e(t.eachMeshGeometriesPortion)),eachMeshMatricesPortion:new Uint32Array(e(t.eachMeshMatricesPortion)),eachMeshTextureSet:new Int32Array(e(t.eachMeshTextureSet)),eachMeshMaterialAttributes:new Uint8Array(e(t.eachMeshMaterialAttributes)),eachEntityId:JSON.parse(Q1.inflate(t.eachEntityId,{to:"string"})),eachEntityMeshesPortion:new Uint32Array(e(t.eachEntityMeshesPortion)),eachTileAABB:new Float64Array(e(t.eachTileAABB)),eachTileEntitiesPortion:new Uint32Array(e(t.eachTileEntitiesPortion))}}const oFt=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();(function(){const t=document.createElement("canvas"),e=t.getContext("2d");return function(i){return t.width=i.width,t.height=i.height,e.putImageData(i,0,0),t.toDataURL()}})();function rFt(t,e,i,o,n,r){const a=r.getNextId(),s=i.metadata,l=i.textureData,c=i.eachTextureDataPortion,d=i.eachTextureAttributes,u=i.positions,h=i.normals,p=i.colors,A=i.uvs,f=i.indices,m=i.edgeIndices,g=i.eachTextureSetTextures,y=i.matrices,v=i.reusedGeometriesDecodeMatrix,w=i.eachGeometryPrimitiveType,x=i.eachGeometryPositionsPortion,k=i.eachGeometryNormalsPortion,B=i.eachGeometryColorsPortion,P=i.eachGeometryUVsPortion,E=i.eachGeometryIndicesPortion,T=i.eachGeometryEdgeIndicesPortion,S=i.eachMeshGeometriesPortion,R=i.eachMeshMatricesPortion,F=i.eachMeshTextureSet,U=i.eachMeshMaterialAttributes,q=i.eachEntityId,V=i.eachEntityMeshesPortion,W=i.eachTileAABB,Y=i.eachTileEntitiesPortion,$=c.length,fe=g.length/5,Me=x.length,Se=S.length,qe=V.length,Qe=Y.length;n&&n.loadData(s,{includeTypes:e.includeTypes,excludeTypes:e.excludeTypes,globalizeObjectIds:e.globalizeObjectIds});for(let me=0;me<$;me++){const we=me===$-1,Re=c[me],We=we?l.length:c[me+1],H=We-Re>0,ee=me*eFt,ae=d[ee+0]===1,Ee=d[ee+1];d[ee+2],d[ee+3];const pe=d[ee+4],Q=d[ee+5],Z=d[ee+6],ie=d[ee+7],re=d[ee+8];if(H){const ne=new Uint8Array(l.subarray(Re,We)).buffer,G=`${a}-texture-${me}`;if(ae)o.createTexture({id:G,buffers:[ne],minFilter:pe,magFilter:Q,wrapS:Z,wrapT:ie,wrapR:re});else{const K=Ee===h7?"image/jpeg":Ee===p7?"image/png":"image/gif",ue=new Blob([ne],{type:K}),xe=(window.URL||window.webkitURL).createObjectURL(ue),oe=document.createElement("img");oe.src=xe,o.createTexture({id:G,image:oe,minFilter:pe,magFilter:Q,wrapS:Z,wrapT:ie,wrapR:re})}}}for(let me=0;me<fe;me++){const we=me*5,Re=`${a}-textureSet-${me}`,We=g[we+0],H=g[we+1],ee=g[we+2],ae=g[we+3],Ee=g[we+4];o.createTextureSet({id:Re,colorTextureId:We>=0?`${a}-texture-${We}`:null,normalsTextureId:ee>=0?`${a}-texture-${ee}`:null,metallicRoughnessTextureId:H>=0?`${a}-texture-${H}`:null,emissiveTextureId:ae>=0?`${a}-texture-${ae}`:null,occlusionTextureId:Ee>=0?`${a}-texture-${Ee}`:null})}const Ce=new Uint32Array(Me);for(let me=0;me<Se;me++){const we=S[me];Ce[we]!==void 0?Ce[we]++:Ce[we]=1}const Le=C.vec3(),Fe=C.AABB3(),ve={};for(let me=0;me<Qe;me++){const we=Qe-1,Re=me===we,We=Y[me],H=Re?qe-1:Y[me+1]-1,ee=me*6,ae=W.subarray(ee,ee+6);C.getAABB3Center(ae,Le),Fe[0]=ae[0]-Le[0],Fe[1]=ae[1]-Le[1],Fe[2]=ae[2]-Le[2],Fe[3]=ae[3]-Le[0],Fe[4]=ae[4]-Le[1],Fe[5]=ae[5]-Le[2];const Ee=Jt.createPositionsDecodeMatrix(Fe),pe={};for(let Q=We;Q<=H;Q++){const Z=q[Q],ie=e.globalizeObjectIds?C.globalizeObjectId(o.id,Z):Z,re=qe-1,ne=Q===re,G=V[Q],K=ne?S.length-1:V[Q+1]-1,ue=[],xe=t.metaScene.metaObjects[ie],oe={},Be={};if(!(e.includeIdsMap&&Z&&!e.includeIdsMap[Z])){if(xe){if(e.excludeTypesMap&&xe.type&&e.excludeTypesMap[xe.type]||e.includeTypesMap&&xe.type&&!e.includeTypesMap[xe.type]||e.includeIdsMap&&xe.id&&!e.includeIdsMap[xe.id])continue;const je=e.objectDefaults?e.objectDefaults[xe.type]||e.objectDefaults.DEFAULT:null;je&&(je.visible===!1&&(oe.visible=!1),je.pickable===!1&&(oe.pickable=!1),je.colorize&&(Be.color=je.colorize),je.opacity!==void 0&&je.opacity!==null&&(Be.opacity=je.opacity),je.metallic!==void 0&&je.metallic!==null&&(Be.metallic=je.metallic),je.roughness!==void 0&&je.roughness!==null&&(Be.roughness=je.roughness))}else if(e.excludeUnclassifiedObjects)continue;for(let je=G;je<=K;je++){const he=S[je],Ne=Ce[he]>1,Pe=he===Me-1,ze=F[je],rt=ze>=0?`${a}-textureSet-${ze}`:null,At=oFt(U.subarray(je*6,je*6+3)),ft=U[je*6+3]/255,lt=U[je*6+4]/255,ut=U[je*6+5]/255,Te=r.getNextId();if(Ne){const st=R[je],dt=y.slice(st,st+16),Ye=`${a}-geometry.${me}.${he}`;let Ae=ve[Ye];if(!Ae){Ae={batchThisMesh:!e.reuseGeometries};const be=w[he];let $e=!1;switch(be){case 0:Ae.primitiveName="solid",Ae.geometryPositions=u.subarray(x[he],Pe?u.length:x[he+1]),Ae.geometryNormals=h.subarray(k[he],Pe?h.length:k[he+1]),Ae.geometryUVs=A.subarray(P[he],Pe?A.length:P[he+1]),Ae.geometryIndices=f.subarray(E[he],Pe?f.length:E[he+1]),Ae.geometryEdgeIndices=m.subarray(T[he],Pe?m.length:T[he+1]),$e=Ae.geometryPositions.length>0&&Ae.geometryIndices.length>0;break;case 1:Ae.primitiveName="surface",Ae.geometryPositions=u.subarray(x[he],Pe?u.length:x[he+1]),Ae.geometryNormals=h.subarray(k[he],Pe?h.length:k[he+1]),Ae.geometryUVs=A.subarray(P[he],Pe?A.length:P[he+1]),Ae.geometryIndices=f.subarray(E[he],Pe?f.length:E[he+1]),Ae.geometryEdgeIndices=m.subarray(T[he],Pe?m.length:T[he+1]),$e=Ae.geometryPositions.length>0&&Ae.geometryIndices.length>0;break;case 2:Ae.primitiveName="points",Ae.geometryPositions=u.subarray(x[he],Pe?u.length:x[he+1]),Ae.geometryColors=p.subarray(B[he],Pe?p.length:B[he+1]),$e=Ae.geometryPositions.length>0;break;case 3:Ae.primitiveName="lines",Ae.geometryPositions=u.subarray(x[he],Pe?u.length:x[he+1]),Ae.geometryIndices=f.subarray(E[he],Pe?f.length:E[he+1]),$e=Ae.geometryPositions.length>0&&Ae.geometryIndices.length>0;break;case 4:Ae.primitiveName="lines",Ae.geometryPositions=u.subarray(x[he],Pe?u.length:x[he+1]),Ae.geometryIndices=Eee(Ae.geometryPositions,f.subarray(E[he],Pe?f.length:E[he+1])),$e=Ae.geometryPositions.length>0&&Ae.geometryIndices.length>0;break;default:continue}if($e||(Ae=null),Ae&&(Ae.geometryPositions.length>1e3,Ae.batchThisMesh)){Ae.decompressedPositions=new Float32Array(Ae.geometryPositions.length),Ae.transformedAndRecompressedPositions=new Uint16Array(Ae.geometryPositions.length);const ht=Ae.geometryPositions,St=Ae.decompressedPositions;for(let xt=0,vi=ht.length;xt<vi;xt+=3)St[xt+0]=ht[xt+0]*v[0]+v[12],St[xt+1]=ht[xt+1]*v[5]+v[13],St[xt+2]=ht[xt+2]*v[10]+v[14];Ae.geometryPositions=null,ve[Ye]=Ae}}if(Ae)if(Ae.batchThisMesh){const be=Ae.decompressedPositions,$e=Ae.transformedAndRecompressedPositions;for(let ht=0,St=be.length;ht<St;ht+=3)yc[0]=be[ht+0],yc[1]=be[ht+1],yc[2]=be[ht+2],yc[3]=1,C.transformVec4(dt,yc,Bee),Jt.compressPosition(Bee,Fe,yc),$e[ht+0]=yc[0],$e[ht+1]=yc[1],$e[ht+2]=yc[2];o.createMesh(mt.apply(Be,{id:Te,textureSetId:rt,origin:Le,primitive:Ae.primitiveName,positionsCompressed:$e,normalsCompressed:Ae.geometryNormals,uv:Ae.geometryUVs,colorsCompressed:Ae.geometryColors,indices:Ae.geometryIndices,edgeIndices:Ae.geometryEdgeIndices,positionsDecodeMatrix:Ee,color:At,metallic:lt,roughness:ut,opacity:ft})),ue.push(Te)}else pe[Ye]||(o.createGeometry({id:Ye,primitive:Ae.primitiveName,positionsCompressed:Ae.geometryPositions,normalsCompressed:Ae.geometryNormals,uv:Ae.geometryUVs,colorsCompressed:Ae.geometryColors,indices:Ae.geometryIndices,edgeIndices:Ae.geometryEdgeIndices,positionsDecodeMatrix:v}),pe[Ye]=!0),o.createMesh(mt.apply(Be,{id:Te,geometryId:Ye,textureSetId:rt,matrix:dt,color:At,metallic:lt,roughness:ut,opacity:ft,origin:Le})),ue.push(Te)}else{const st=w[he];let dt,Ye,Ae,be,$e,ht,St,xt=!1;switch(st){case 0:dt="solid",Ye=u.subarray(x[he],Pe?u.length:x[he+1]),Ae=h.subarray(k[he],Pe?h.length:k[he+1]),be=A.subarray(P[he],Pe?A.length:P[he+1]),ht=f.subarray(E[he],Pe?f.length:E[he+1]),St=m.subarray(T[he],Pe?m.length:T[he+1]),xt=Ye.length>0&&ht.length>0;break;case 1:dt="surface",Ye=u.subarray(x[he],Pe?u.length:x[he+1]),Ae=h.subarray(k[he],Pe?h.length:k[he+1]),be=A.subarray(P[he],Pe?A.length:P[he+1]),ht=f.subarray(E[he],Pe?f.length:E[he+1]),St=m.subarray(T[he],Pe?m.length:T[he+1]),xt=Ye.length>0&&ht.length>0;break;case 2:dt="points",Ye=u.subarray(x[he],Pe?u.length:x[he+1]),$e=p.subarray(B[he],Pe?p.length:B[he+1]),xt=Ye.length>0;break;case 3:dt="lines",Ye=u.subarray(x[he],Pe?u.length:x[he+1]),ht=f.subarray(E[he],Pe?f.length:E[he+1]),xt=Ye.length>0&&ht.length>0;break;case 4:dt="lines",Ye=u.subarray(x[he],Pe?u.length:x[he+1]),ht=Eee(Ye,f.subarray(E[he],Pe?f.length:E[he+1])),xt=Ye.length>0&&ht.length>0;break;default:continue}xt&&(o.createMesh(mt.apply(Be,{id:Te,textureSetId:rt,origin:Le,primitive:dt,positionsCompressed:Ye,normalsCompressed:Ae,uv:be&&be.length>0?be:null,colorsCompressed:$e,indices:ht,edgeIndices:St,positionsDecodeMatrix:Ee,color:At,metallic:lt,roughness:ut,opacity:ft})),ue.push(Te))}}ue.length>0&&o.createEntity(mt.apply(oe,{id:ie,isObject:!0,meshIds:ue}))}}}}function Eee(t,e){const i=[];if(e.length>1)for(let o=0,n=e.length-1;o<n;o++)i.push(e[o]),i.push(e[o+1]);else if(t.length>1)for(let o=0,n=t.length/3-1;o<n;o++)i.push(o),i.push(o+1);return i}const Pee={version:10,parse:function(t,e,i,o,n,r){const a=tFt(i),s=iFt(a);rFt(t,e,s,o,n,r)}},bc=C.vec4(),Iee=C.vec4(),nFt=9;function aFt(t){const e=(function(){const n=new ArrayBuffer(2);return new Uint16Array(n)[0]=1,new Uint8Array(n)[0]!==1})(),i=(function(){let n=0;const r=new DataView(t);return function(a){const s=1+2*n++,l=r.getUint32(s*4,!0),c=r.getUint32((s+1)*4,!0),d=a.BYTES_PER_ELEMENT;if(e&&d>1){const u=new Uint8Array(t,l,c),h=d/2,p=u.length/d;for(let A=0;A<p;A++){const f=A*d;for(let m=0;m<h;m++){const g=f+m,y=f-m+d-1,v=u[g];u[g]=u[y],u[y]=v}}}return new a(t,l,c/d)}})(),o=(function(){const n=new TextDecoder;return()=>JSON.parse(n.decode(i(Uint8Array)))})();return{metadata:o(),textureData:i(Uint8Array),eachTextureDataPortion:i(Uint32Array),eachTextureAttributes:i(Uint16Array),positions:i(Uint16Array),normals:i(Int8Array),colors:i(Uint8Array),uvs:i(Float32Array),indices:i(Uint32Array),edgeIndices:i(Uint32Array),eachTextureSetTextures:i(Int32Array),matrices:i(Float32Array),reusedGeometriesDecodeMatrix:i(Float32Array),eachGeometryPrimitiveType:i(Uint8Array),eachGeometryPositionsPortion:i(Uint32Array),eachGeometryNormalsPortion:i(Uint32Array),eachGeometryColorsPortion:i(Uint32Array),eachGeometryUVsPortion:i(Uint32Array),eachGeometryIndicesPortion:i(Uint32Array),eachGeometryEdgeIndicesPortion:i(Uint32Array),eachMeshGeometriesPortion:i(Uint32Array),eachMeshMatricesPortion:i(Uint32Array),eachMeshTextureSet:i(Int32Array),eachMeshMaterialAttributes:i(Uint8Array),eachEntityId:o(),eachEntityMeshesPortion:i(Uint32Array),eachTileAABB:i(Float64Array),eachTileEntitiesPortion:i(Uint32Array)}}const sFt=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();(function(){const t=document.createElement("canvas"),e=t.getContext("2d");return function(i){return t.width=i.width,t.height=i.height,e.putImageData(i,0,0),t.toDataURL()}})();function lFt(t,e,i,o,n,r){const a=r.getNextId(),s=i.metadata,l=i.textureData,c=i.eachTextureDataPortion,d=i.eachTextureAttributes,u=i.positions,h=i.normals,p=i.colors,A=i.uvs,f=i.indices,m=i.edgeIndices,g=i.eachTextureSetTextures,y=i.matrices,v=i.reusedGeometriesDecodeMatrix,w=i.eachGeometryPrimitiveType,x=i.eachGeometryPositionsPortion,k=i.eachGeometryNormalsPortion,B=i.eachGeometryColorsPortion,P=i.eachGeometryUVsPortion,E=i.eachGeometryIndicesPortion,T=i.eachGeometryEdgeIndicesPortion,S=i.eachMeshGeometriesPortion,R=i.eachMeshMatricesPortion,F=i.eachMeshTextureSet,U=i.eachMeshMaterialAttributes,q=i.eachEntityId,V=i.eachEntityMeshesPortion,W=i.eachTileAABB,Y=i.eachTileEntitiesPortion,$=c.length,fe=g.length/5,Me=x.length,Se=S.length,qe=V.length,Qe=Y.length;n&&n.loadData(s,{includeTypes:e.includeTypes,excludeTypes:e.excludeTypes,globalizeObjectIds:e.globalizeObjectIds});for(let me=0;me<$;me++){const we=me===$-1,Re=c[me],We=we?l.length:c[me+1],H=We-Re>0,ee=me*nFt,ae=d[ee+0]===1,Ee=d[ee+1];d[ee+2],d[ee+3];const pe=d[ee+4],Q=d[ee+5],Z=d[ee+6],ie=d[ee+7],re=d[ee+8];if(H){const ne=new Uint8Array(l.subarray(Re,We)).buffer,G=`${a}-texture-${me}`;if(ae)o.createTexture({id:G,buffers:[ne],minFilter:pe,magFilter:Q,wrapS:Z,wrapT:ie,wrapR:re});else{const K=Ee===h7?"image/jpeg":Ee===p7?"image/png":"image/gif",ue=new Blob([ne],{type:K}),xe=(window.URL||window.webkitURL).createObjectURL(ue),oe=document.createElement("img");oe.src=xe,o.createTexture({id:G,image:oe,minFilter:pe,magFilter:Q,wrapS:Z,wrapT:ie,wrapR:re})}}}for(let me=0;me<fe;me++){const we=me*5,Re=`${a}-textureSet-${me}`,We=g[we+0],H=g[we+1],ee=g[we+2],ae=g[we+3],Ee=g[we+4];o.createTextureSet({id:Re,colorTextureId:We>=0?`${a}-texture-${We}`:null,normalsTextureId:ee>=0?`${a}-texture-${ee}`:null,metallicRoughnessTextureId:H>=0?`${a}-texture-${H}`:null,emissiveTextureId:ae>=0?`${a}-texture-${ae}`:null,occlusionTextureId:Ee>=0?`${a}-texture-${Ee}`:null})}const Ce=new Uint32Array(Me);for(let me=0;me<Se;me++){const we=S[me];Ce[we]!==void 0?Ce[we]++:Ce[we]=1}const Le=C.vec3(),Fe=C.AABB3(),ve={};for(let me=0;me<Qe;me++){const we=Qe-1,Re=me===we,We=Y[me],H=Re?qe-1:Y[me+1]-1,ee=me*6,ae=W.subarray(ee,ee+6);C.getAABB3Center(ae,Le),Fe[0]=ae[0]-Le[0],Fe[1]=ae[1]-Le[1],Fe[2]=ae[2]-Le[2],Fe[3]=ae[3]-Le[0],Fe[4]=ae[4]-Le[1],Fe[5]=ae[5]-Le[2];const Ee=Jt.createPositionsDecodeMatrix(Fe),pe={};for(let Q=We;Q<=H;Q++){const Z=q[Q],ie=e.globalizeObjectIds?C.globalizeObjectId(o.id,Z):Z,re=qe-1,ne=Q===re,G=V[Q],K=ne?S.length-1:V[Q+1]-1,ue=[],xe=t.metaScene.metaObjects[ie],oe={},Be={};if(!(e.includeIdsMap&&Z&&!e.includeIdsMap[Z])){if(xe){if(e.excludeTypesMap&&xe.type&&e.excludeTypesMap[xe.type]||e.includeTypesMap&&xe.type&&!e.includeTypesMap[xe.type]||e.includeIdsMap&&xe.id&&!e.includeIdsMap[xe.id])continue;const je=e.objectDefaults?e.objectDefaults[xe.type]||e.objectDefaults.DEFAULT:null;je&&(je.visible===!1&&(oe.visible=!1),je.pickable===!1&&(oe.pickable=!1),je.colorize&&(Be.color=je.colorize),je.opacity!==void 0&&je.opacity!==null&&(Be.opacity=je.opacity),je.metallic!==void 0&&je.metallic!==null&&(Be.metallic=je.metallic),je.roughness!==void 0&&je.roughness!==null&&(Be.roughness=je.roughness))}else if(e.excludeUnclassifiedObjects)continue;for(let je=G;je<=K;je++){const he=S[je],Ne=Ce[he]>1,Pe=he===Me-1,ze=F[je],rt=ze>=0?`${a}-textureSet-${ze}`:null,At=sFt(U.subarray(je*6,je*6+3)),ft=U[je*6+3]/255,lt=U[je*6+4]/255,ut=U[je*6+5]/255,Te=r.getNextId();if(Ne){const st=R[je],dt=y.slice(st,st+16),Ye=`${a}-geometry.${me}.${he}`;let Ae=ve[Ye];if(!Ae){Ae={batchThisMesh:!e.reuseGeometries};const be=w[he];let $e=!1;switch(be){case 0:Ae.primitiveName="solid",Ae.geometryPositions=u.subarray(x[he],Pe?u.length:x[he+1]),Ae.geometryNormals=h.subarray(k[he],Pe?h.length:k[he+1]),Ae.geometryUVs=A.subarray(P[he],Pe?A.length:P[he+1]),Ae.geometryIndices=f.subarray(E[he],Pe?f.length:E[he+1]),Ae.geometryEdgeIndices=m.subarray(T[he],Pe?m.length:T[he+1]),$e=Ae.geometryPositions.length>0&&Ae.geometryIndices.length>0;break;case 1:Ae.primitiveName="surface",Ae.geometryPositions=u.subarray(x[he],Pe?u.length:x[he+1]),Ae.geometryNormals=h.subarray(k[he],Pe?h.length:k[he+1]),Ae.geometryUVs=A.subarray(P[he],Pe?A.length:P[he+1]),Ae.geometryIndices=f.subarray(E[he],Pe?f.length:E[he+1]),Ae.geometryEdgeIndices=m.subarray(T[he],Pe?m.length:T[he+1]),$e=Ae.geometryPositions.length>0&&Ae.geometryIndices.length>0;break;case 2:Ae.primitiveName="points",Ae.geometryPositions=u.subarray(x[he],Pe?u.length:x[he+1]),Ae.geometryColors=p.subarray(B[he],Pe?p.length:B[he+1]),$e=Ae.geometryPositions.length>0;break;case 3:Ae.primitiveName="lines",Ae.geometryPositions=u.subarray(x[he],Pe?u.length:x[he+1]),Ae.geometryIndices=f.subarray(E[he],Pe?f.length:E[he+1]),$e=Ae.geometryPositions.length>0&&Ae.geometryIndices.length>0;break;case 4:Ae.primitiveName="lines",Ae.geometryPositions=u.subarray(x[he],Pe?u.length:x[he+1]),Ae.geometryIndices=See(Ae.geometryPositions,f.subarray(E[he],Pe?f.length:E[he+1])),$e=Ae.geometryPositions.length>0&&Ae.geometryIndices.length>0;break;default:continue}if($e||(Ae=null),Ae&&(Ae.geometryPositions.length>1e3,Ae.batchThisMesh)){Ae.decompressedPositions=new Float32Array(Ae.geometryPositions.length),Ae.transformedAndRecompressedPositions=new Uint16Array(Ae.geometryPositions.length);const ht=Ae.geometryPositions,St=Ae.decompressedPositions;for(let xt=0,vi=ht.length;xt<vi;xt+=3)St[xt+0]=ht[xt+0]*v[0]+v[12],St[xt+1]=ht[xt+1]*v[5]+v[13],St[xt+2]=ht[xt+2]*v[10]+v[14];Ae.geometryPositions=null,ve[Ye]=Ae}}if(Ae)if(Ae.batchThisMesh){const be=Ae.decompressedPositions,$e=Ae.transformedAndRecompressedPositions;for(let ht=0,St=be.length;ht<St;ht+=3)bc[0]=be[ht+0],bc[1]=be[ht+1],bc[2]=be[ht+2],bc[3]=1,C.transformVec4(dt,bc,Iee),Jt.compressPosition(Iee,Fe,bc),$e[ht+0]=bc[0],$e[ht+1]=bc[1],$e[ht+2]=bc[2];o.createMesh(mt.apply(Be,{id:Te,textureSetId:rt,origin:Le,primitive:Ae.primitiveName,positionsCompressed:$e,normalsCompressed:Ae.geometryNormals,uv:Ae.geometryUVs,colorsCompressed:Ae.geometryColors,indices:Ae.geometryIndices,edgeIndices:Ae.geometryEdgeIndices,positionsDecodeMatrix:Ee,color:At,metallic:lt,roughness:ut,opacity:ft})),ue.push(Te)}else pe[Ye]||(o.createGeometry({id:Ye,primitive:Ae.primitiveName,positionsCompressed:Ae.geometryPositions,normalsCompressed:Ae.geometryNormals,uv:Ae.geometryUVs,colorsCompressed:Ae.geometryColors,indices:Ae.geometryIndices,edgeIndices:Ae.geometryEdgeIndices,positionsDecodeMatrix:v}),pe[Ye]=!0),o.createMesh(mt.apply(Be,{id:Te,geometryId:Ye,textureSetId:rt,matrix:dt,color:At,metallic:lt,roughness:ut,opacity:ft,origin:Le})),ue.push(Te)}else{const st=w[he];let dt,Ye,Ae,be,$e,ht,St,xt=!1;switch(st){case 0:dt="solid",Ye=u.subarray(x[he],Pe?u.length:x[he+1]),Ae=h.subarray(k[he],Pe?h.length:k[he+1]),be=A.subarray(P[he],Pe?A.length:P[he+1]),ht=f.subarray(E[he],Pe?f.length:E[he+1]),St=m.subarray(T[he],Pe?m.length:T[he+1]),xt=Ye.length>0&&ht.length>0;break;case 1:dt="surface",Ye=u.subarray(x[he],Pe?u.length:x[he+1]),Ae=h.subarray(k[he],Pe?h.length:k[he+1]),be=A.subarray(P[he],Pe?A.length:P[he+1]),ht=f.subarray(E[he],Pe?f.length:E[he+1]),St=m.subarray(T[he],Pe?m.length:T[he+1]),xt=Ye.length>0&&ht.length>0;break;case 2:dt="points",Ye=u.subarray(x[he],Pe?u.length:x[he+1]),$e=p.subarray(B[he],Pe?p.length:B[he+1]),xt=Ye.length>0;break;case 3:dt="lines",Ye=u.subarray(x[he],Pe?u.length:x[he+1]),ht=f.subarray(E[he],Pe?f.length:E[he+1]),xt=Ye.length>0&&ht.length>0;break;case 4:dt="lines",Ye=u.subarray(x[he],Pe?u.length:x[he+1]),ht=See(Ye,f.subarray(E[he],Pe?f.length:E[he+1])),xt=Ye.length>0&&ht.length>0;break;default:continue}xt&&(o.createMesh(mt.apply(Be,{id:Te,textureSetId:rt,origin:Le,primitive:dt,positionsCompressed:Ye,normalsCompressed:Ae,uv:be&&be.length>0?be:null,colorsCompressed:$e,indices:ht,edgeIndices:St,positionsDecodeMatrix:Ee,color:At,metallic:lt,roughness:ut,opacity:ft})),ue.push(Te))}}ue.length>0&&o.createEntity(mt.apply(oe,{id:ie,isObject:!0,meshIds:ue}))}}}}function See(t,e){const i=[];if(e.length>1)for(let o=0,n=e.length-1;o<n;o++)i.push(e[o]),i.push(e[o+1]);else if(t.length>1)for(let o=0,n=t.length/3-1;o<n;o++)i.push(o),i.push(o+1);return i}const Tee={version:11,parseArrayBuffer:function(t,e,i,o,n,r){const a=aFt(i);lFt(t,e,a,o,n,r)}};let xh=window.pako||ks;xh.inflate||(xh=xh.default);const wc=C.vec4(),Dee=C.vec4(),cFt=9;function dFt(t){const e=(function(){const n=new ArrayBuffer(2);return new Uint16Array(n)[0]=1,new Uint8Array(n)[0]!==1})(),i=(function(){let n=0;const r=new DataView(t);return function(a){const s=1+2*n++,l=r.getUint32(s*4,!0),c=r.getUint32((s+1)*4,!0),d=a.BYTES_PER_ELEMENT;if(e&&d>1){const u=new Uint8Array(t,l,c),h=d/2,p=u.length/d;for(let A=0;A<p;A++){const f=A*d;for(let m=0;m<h;m++){const g=f+m,y=f-m+d-1,v=u[g];u[g]=u[y],u[y]=v}}}return new a(t,l,c/d)}})(),o=(function(){const n=new TextDecoder;return()=>JSON.parse(n.decode(i(Uint8Array)))})();return{metadata:o(),textureData:i(Uint8Array),eachTextureDataPortion:i(Uint32Array),eachTextureAttributes:i(Uint16Array),positions:i(Uint16Array),normals:i(Int8Array),colors:i(Uint8Array),uvs:i(Float32Array),indices:i(Uint32Array),edgeIndices:i(Uint32Array),eachTextureSetTextures:i(Int32Array),matrices:i(Float32Array),reusedGeometriesDecodeMatrix:i(Float32Array),eachGeometryPrimitiveType:i(Uint8Array),eachGeometryAxisLabel:o(),eachGeometryPositionsPortion:i(Uint32Array),eachGeometryNormalsPortion:i(Uint32Array),eachGeometryColorsPortion:i(Uint32Array),eachGeometryUVsPortion:i(Uint32Array),eachGeometryIndicesPortion:i(Uint32Array),eachGeometryEdgeIndicesPortion:i(Uint32Array),eachMeshGeometriesPortion:i(Uint32Array),eachMeshMatricesPortion:i(Uint32Array),eachMeshTextureSet:i(Int32Array),eachMeshMaterialAttributes:i(Uint8Array),eachEntityId:o(),eachEntityMeshesPortion:i(Uint32Array),eachTileAABB:i(Float64Array),eachTileEntitiesPortion:i(Uint32Array)}}function uFt(t){let e=0;return{metadata:t[e++],textureData:t[e++],eachTextureDataPortion:t[e++],eachTextureAttributes:t[e++],positions:t[e++],normals:t[e++],colors:t[e++],uvs:t[e++],indices:t[e++],edgeIndices:t[e++],eachTextureSetTextures:t[e++],matrices:t[e++],reusedGeometriesDecodeMatrix:t[e++],eachGeometryPrimitiveType:t[e++],eachGeometryAxisLabel:t[e++],eachGeometryPositionsPortion:t[e++],eachGeometryNormalsPortion:t[e++],eachGeometryColorsPortion:t[e++],eachGeometryUVsPortion:t[e++],eachGeometryIndicesPortion:t[e++],eachGeometryEdgeIndicesPortion:t[e++],eachMeshGeometriesPortion:t[e++],eachMeshMatricesPortion:t[e++],eachMeshTextureSet:t[e++],eachMeshMaterialAttributes:t[e++],eachEntityId:t[e++],eachEntityMeshesPortion:t[e++],eachTileAABB:t[e++],eachTileEntitiesPortion:t[e++]}}function hFt(t){function e(i,o){return i.length===0?[]:xh.inflate(i,o).buffer}return{metadata:JSON.parse(xh.inflate(t.metadata,{to:"string"})),textureData:new Uint8Array(e(t.textureData)),eachTextureDataPortion:new Uint32Array(e(t.eachTextureDataPortion)),eachTextureAttributes:new Uint16Array(e(t.eachTextureAttributes)),positions:new Uint16Array(e(t.positions)),normals:new Int8Array(e(t.normals)),colors:new Uint8Array(e(t.colors)),uvs:new Float32Array(e(t.uvs)),indices:new Uint32Array(e(t.indices)),edgeIndices:new Uint32Array(e(t.edgeIndices)),eachTextureSetTextures:new Int32Array(e(t.eachTextureSetTextures)),matrices:new Float32Array(e(t.matrices)),reusedGeometriesDecodeMatrix:new Float32Array(e(t.reusedGeometriesDecodeMatrix)),eachGeometryPrimitiveType:new Uint8Array(e(t.eachGeometryPrimitiveType)),eachGeometryAxisLabel:JSON.parse(xh.inflate(t.eachGeometryAxisLabel,{to:"string"})),eachGeometryPositionsPortion:new Uint32Array(e(t.eachGeometryPositionsPortion)),eachGeometryNormalsPortion:new Uint32Array(e(t.eachGeometryNormalsPortion)),eachGeometryColorsPortion:new Uint32Array(e(t.eachGeometryColorsPortion)),eachGeometryUVsPortion:new Uint32Array(e(t.eachGeometryUVsPortion)),eachGeometryIndicesPortion:new Uint32Array(e(t.eachGeometryIndicesPortion)),eachGeometryEdgeIndicesPortion:new Uint32Array(e(t.eachGeometryEdgeIndicesPortion)),eachMeshGeometriesPortion:new Uint32Array(e(t.eachMeshGeometriesPortion)),eachMeshMatricesPortion:new Uint32Array(e(t.eachMeshMatricesPortion)),eachMeshTextureSet:new Int32Array(e(t.eachMeshTextureSet)),eachMeshMaterialAttributes:new Uint8Array(e(t.eachMeshMaterialAttributes)),eachEntityId:JSON.parse(xh.inflate(t.eachEntityId,{to:"string"})),eachEntityMeshesPortion:new Uint32Array(e(t.eachEntityMeshesPortion)),eachTileAABB:new Float64Array(e(t.eachTileAABB)),eachTileEntitiesPortion:new Uint32Array(e(t.eachTileEntitiesPortion))}}const pFt=(function(){const t=new Float32Array(3);return function(e){return t[0]=e[0]/255,t[1]=e[1]/255,t[2]=e[2]/255,t}})();(function(){const t=document.createElement("canvas"),e=t.getContext("2d");return function(i){return t.width=i.width,t.height=i.height,e.putImageData(i,0,0),t.toDataURL()}})();function Ree(t,e,i,o,n,r){const a=r.getNextId(),s=i.metadata,l=i.textureData,c=i.eachTextureDataPortion,d=i.eachTextureAttributes,u=i.positions,h=i.normals,p=i.colors,A=i.uvs,f=i.indices,m=i.edgeIndices,g=i.eachTextureSetTextures,y=i.matrices,v=i.reusedGeometriesDecodeMatrix,w=i.eachGeometryPrimitiveType,x=i.eachGeometryAxisLabel,k=i.eachGeometryPositionsPortion,B=i.eachGeometryNormalsPortion,P=i.eachGeometryColorsPortion,E=i.eachGeometryUVsPortion,T=i.eachGeometryIndicesPortion,S=i.eachGeometryEdgeIndicesPortion,R=i.eachMeshGeometriesPortion,F=i.eachMeshMatricesPortion,U=i.eachMeshTextureSet,q=i.eachMeshMaterialAttributes,V=i.eachEntityId,W=i.eachEntityMeshesPortion,Y=i.eachTileAABB,$=i.eachTileEntitiesPortion,fe=c.length,Me=g.length/5,Se=k.length,qe=R.length,Qe=W.length,Ce=$.length;n&&n.loadData(s,{includeTypes:e.includeTypes,excludeTypes:e.excludeTypes,globalizeObjectIds:e.globalizeObjectIds});for(let we=0;we<fe;we++){const Re=we===fe-1,We=c[we],H=Re?l.length:c[we+1],ee=H-We>0,ae=we*cFt,Ee=d[ae+0]===1,pe=d[ae+1];d[ae+2],d[ae+3];const Q=d[ae+4],Z=d[ae+5],ie=d[ae+6],re=d[ae+7],ne=d[ae+8];if(ee){const G=new Uint8Array(l.subarray(We,H)).buffer,K=`${a}-texture-${we}`;if(Ee)o.createTexture({id:K,buffers:[G],minFilter:Q,magFilter:Z,wrapS:ie,wrapT:re,wrapR:ne});else{const ue=pe===h7?"image/jpeg":pe===p7?"image/png":"image/gif",xe=new Blob([G],{type:ue}),oe=(window.URL||window.webkitURL).createObjectURL(xe),Be=document.createElement("img");Be.src=oe,o.createTexture({id:K,image:Be,minFilter:Q,magFilter:Z,wrapS:ie,wrapT:re,wrapR:ne})}}}for(let we=0;we<Me;we++){const Re=we*5,We=`${a}-textureSet-${we}`,H=g[Re+0],ee=g[Re+1],ae=g[Re+2],Ee=g[Re+3],pe=g[Re+4];o.createTextureSet({id:We,colorTextureId:H>=0?`${a}-texture-${H}`:null,normalsTextureId:ae>=0?`${a}-texture-${ae}`:null,metallicRoughnessTextureId:ee>=0?`${a}-texture-${ee}`:null,emissiveTextureId:Ee>=0?`${a}-texture-${Ee}`:null,occlusionTextureId:pe>=0?`${a}-texture-${pe}`:null})}const Le=new Uint32Array(Se);for(let we=0;we<qe;we++){const Re=R[we];Le[Re]!==void 0?Le[Re]++:Le[Re]=1}const Fe=C.vec3(),ve=C.AABB3(),me={};for(let we=0;we<Ce;we++){const Re=Ce-1,We=we===Re,H=$[we],ee=We?Qe-1:$[we+1]-1,ae=we*6,Ee=Y.subarray(ae,ae+6);C.getAABB3Center(Ee,Fe),ve[0]=Ee[0]-Fe[0],ve[1]=Ee[1]-Fe[1],ve[2]=Ee[2]-Fe[2],ve[3]=Ee[3]-Fe[0],ve[4]=Ee[4]-Fe[1],ve[5]=Ee[5]-Fe[2];const pe=Jt.createPositionsDecodeMatrix(ve),Q={};for(let Z=H;Z<=ee;Z++){const ie=V[Z],re=e.globalizeObjectIds?C.globalizeObjectId(o.id,ie):ie,ne=Qe-1,G=Z===ne,K=W[Z],ue=G?R.length-1:W[Z+1]-1,xe=[],oe=t.metaScene.metaObjects[re],Be={},je={};if(!(e.includeIdsMap&&ie&&!e.includeIdsMap[ie])){if(oe){if(e.excludeTypesMap&&oe.type&&e.excludeTypesMap[oe.type]||e.includeTypesMap&&oe.type&&!e.includeTypesMap[oe.type]||e.includeIdsMap&&oe.id&&!e.includeIdsMap[oe.id])continue;const he=e.objectDefaults?e.objectDefaults[oe.type]||e.objectDefaults.DEFAULT:null;he&&(he.visible===!1&&(Be.visible=!1),he.pickable===!1&&(Be.pickable=!1),he.colorize&&(je.color=he.colorize),he.opacity!==void 0&&he.opacity!==null&&(je.opacity=he.opacity),he.metallic!==void 0&&he.metallic!==null&&(je.metallic=he.metallic),he.roughness!==void 0&&he.roughness!==null&&(je.roughness=he.roughness))}else if(e.excludeUnclassifiedObjects)continue;for(let he=K;he<=ue;he++){const Ne=R[he],Pe=Le[Ne]>1,ze=Ne===Se-1,rt=U[he],At=rt>=0?`${a}-textureSet-${rt}`:null,ft=pFt(q.subarray(he*6,he*6+3)),lt=q[he*6+3]/255,ut=q[he*6+4]/255,Te=q[he*6+5]/255,st=r.getNextId();if(Pe){const dt=F[he],Ye=y.slice(dt,dt+16),Ae=`${a}-geometry.${we}.${Ne}`;let be=me[Ae];if(!be){be={batchThisMesh:!e.reuseGeometries};const $e=w[Ne],ht=x[Ne];let St=!1,xt;switch($e){case 0:be.primitiveName="solid",be.geometryPositions=u.subarray(k[Ne],ze?u.length:k[Ne+1]),be.geometryNormals=h.subarray(B[Ne],ze?h.length:B[Ne+1]),be.geometryUVs=A.subarray(E[Ne],ze?A.length:E[Ne+1]),be.geometryIndices=f.subarray(T[Ne],ze?f.length:T[Ne+1]),be.geometryEdgeIndices=m.subarray(S[Ne],ze?m.length:S[Ne+1]),St=be.geometryPositions.length>0&&be.geometryIndices.length>0;break;case 1:be.primitiveName="surface",be.geometryPositions=u.subarray(k[Ne],ze?u.length:k[Ne+1]),be.geometryNormals=h.subarray(B[Ne],ze?h.length:B[Ne+1]),be.geometryUVs=A.subarray(E[Ne],ze?A.length:E[Ne+1]),be.geometryIndices=f.subarray(T[Ne],ze?f.length:T[Ne+1]),be.geometryEdgeIndices=m.subarray(S[Ne],ze?m.length:S[Ne+1]),St=be.geometryPositions.length>0&&be.geometryIndices.length>0;break;case 2:be.primitiveName="points",be.geometryPositions=u.subarray(k[Ne],ze?u.length:k[Ne+1]),be.geometryColors=p.subarray(P[Ne],ze?p.length:P[Ne+1]),St=be.geometryPositions.length>0;break;case 3:be.primitiveName="lines",be.geometryPositions=u.subarray(k[Ne],ze?u.length:k[Ne+1]),be.geometryIndices=f.subarray(T[Ne],ze?f.length:T[Ne+1]),St=be.geometryPositions.length>0&&be.geometryIndices.length>0;break;case 4:be.primitiveName="lines",be.geometryPositions=u.subarray(k[Ne],ze?u.length:k[Ne+1]),be.geometryIndices=Lee(be.geometryPositions,f.subarray(T[Ne],ze?f.length:T[Ne+1])),St=be.geometryPositions.length>0&&be.geometryIndices.length>0;break;case 7:be.primitiveName="lines",be.geometryPositions=u.subarray(k[Ne],ze?u.length:k[Ne+1]),be.decompressedPositions=Jt.decompressPositions(be.geometryPositions,v),xt=p1({origin:be.decompressedPositions,text:ht,size:2}),be.decompressedPositions=xt.positions,be.geometryIndices=xt.indices,be.geometryPositions=null,St=be.decompressedPositions.length>0&&be.geometryIndices.length>0;break;default:continue}if(St||(be=null),be&&(be.geometryPositions&&be.geometryPositions.length>1e3,be.batchThisMesh)){if($e===7)be.transformedAndRecompressedPositions=new Uint16Array(be.decompressedPositions.length);else{be.decompressedPositions=new Float32Array(be.geometryPositions.length),be.transformedAndRecompressedPositions=new Uint16Array(be.geometryPositions.length);const vi=be.geometryPositions,Gi=be.decompressedPositions;for(let So=0,ao=vi.length;So<ao;So+=3)Gi[So+0]=vi[So+0]*v[0]+v[12],Gi[So+1]=vi[So+1]*v[5]+v[13],Gi[So+2]=vi[So+2]*v[10]+v[14];be.geometryPositions=null}me[Ae]=be}}if(be)if(be.batchThisMesh){const $e=be.decompressedPositions,ht=be.transformedAndRecompressedPositions;for(let St=0,xt=$e.length;St<xt;St+=3)wc[0]=$e[St+0],wc[1]=$e[St+1],wc[2]=$e[St+2],wc[3]=1,C.transformVec4(Ye,wc,Dee),Jt.compressPosition(Dee,ve,wc),ht[St+0]=wc[0],ht[St+1]=wc[1],ht[St+2]=wc[2];o.createMesh(mt.apply(je,{id:st,textureSetId:At,origin:Fe,primitive:be.primitiveName,positionsCompressed:ht,normalsCompressed:be.geometryNormals,uv:be.geometryUVs,colorsCompressed:be.geometryColors,indices:be.geometryIndices,edgeIndices:be.geometryEdgeIndices,positionsDecodeMatrix:pe,color:ft,metallic:ut,roughness:Te,opacity:lt})),xe.push(st)}else{if(!Q[Ae]){let $e={id:Ae,primitive:be.primitiveName,normalsCompressed:be.geometryNormals,uv:be.geometryUVs,colorsCompressed:be.geometryColors,indices:be.geometryIndices,edgeIndices:be.geometryEdgeIndices};be.geometryPositions?$e={...$e,positionsCompressed:be.geometryPositions,positionsDecodeMatrix:v}:$e={...$e,positions:be.decompressedPositions},o.createGeometry($e),Q[Ae]=!0}o.createMesh(mt.apply(je,{id:st,geometryId:Ae,textureSetId:At,matrix:Ye,color:ft,metallic:ut,roughness:Te,opacity:lt,origin:Fe})),xe.push(st)}}else{const dt=w[Ne],Ye=x[Ne];let Ae,be,$e,ht,St,xt,vi,Gi=!1,So;switch(dt){case 0:Ae="solid",be=u.subarray(k[Ne],ze?u.length:k[Ne+1]),$e=h.subarray(B[Ne],ze?h.length:B[Ne+1]),ht=A.subarray(E[Ne],ze?A.length:E[Ne+1]),xt=f.subarray(T[Ne],ze?f.length:T[Ne+1]),vi=m.subarray(S[Ne],ze?m.length:S[Ne+1]),Gi=be.length>0&&xt.length>0;break;case 1:Ae="surface",be=u.subarray(k[Ne],ze?u.length:k[Ne+1]),$e=h.subarray(B[Ne],ze?h.length:B[Ne+1]),ht=A.subarray(E[Ne],ze?A.length:E[Ne+1]),xt=f.subarray(T[Ne],ze?f.length:T[Ne+1]),vi=m.subarray(S[Ne],ze?m.length:S[Ne+1]),Gi=be.length>0&&xt.length>0;break;case 2:Ae="points",be=u.subarray(k[Ne],ze?u.length:k[Ne+1]),St=p.subarray(P[Ne],ze?p.length:P[Ne+1]),Gi=be.length>0;break;case 3:Ae="lines",be=u.subarray(k[Ne],ze?u.length:k[Ne+1]),xt=f.subarray(T[Ne],ze?f.length:T[Ne+1]),Gi=be.length>0&&xt.length>0;break;case 4:Ae="lines",be=u.subarray(k[Ne],ze?u.length:k[Ne+1]),xt=Lee(be,f.subarray(T[Ne],ze?f.length:T[Ne+1])),Gi=be.length>0&&xt.length>0;break;case 7:Ae="lines",be=u.subarray(k[Ne],ze?u.length:k[Ne+1]),be=Jt.decompressPositions(be,pe),So=p1({origin:be,text:Ye,size:2}),be=So.positions,xt=So.indices,Gi=be.length>0&&xt.length>0;break;default:continue}if(Gi){let ao=mt.apply(je,{id:st,textureSetId:At,origin:Fe,primitive:Ae,normalsCompressed:$e,uv:ht&&ht.length>0?ht:null,colorsCompressed:St,indices:xt,edgeIndices:vi,color:ft,metallic:ut,roughness:Te,opacity:lt});dt!==7?ao={...ao,positionsCompressed:be,positionsDecodeMatrix:pe}:ao={...ao,positions:be},o.createMesh(ao),xe.push(st)}}}xe.length>0&&o.createEntity(mt.apply(Be,{id:re,isObject:!0,meshIds:xe}))}}}}function Lee(t,e){const i=[];if(e.length>1)for(let o=0,n=e.length-1;o<n;o++)i.push(e[o]),i.push(e[o+1]);else if(t.length>1)for(let o=0,n=t.length/3-1;o<n;o++)i.push(o),i.push(o+1);return i}const _ee={version:12,parseArrayBuffer:function(t,e,i,o,n,r){const a=dFt(i);Ree(t,e,a,o,n,r)},parse:function(t,e,i,o,n,r){const a=uFt(i),s=hFt(a);Ree(t,e,s,o,n,r)}},Rn={};Rn[pee.version]=pee,Rn[fee.version]=fee,Rn[Aee.version]=Aee,Rn[gee.version]=gee,Rn[mee.version]=mee,Rn[vee.version]=vee,Rn[bee.version]=bee,Rn[xee.version]=xee,Rn[Mee.version]=Mee,Rn[Pee.version]=Pee,Rn[Tee.version]=Tee,Rn[_ee.version]=_ee;class T9 extends Ha{constructor(e,i={}){super("XKTLoader",e,i),this._maxGeometryBatchSize=i.maxGeometryBatchSize,this.textureTranscoder=i.textureTranscoder,this.dataSource=i.dataSource,this.objectDefaults=i.objectDefaults,this.includeTypes=i.includeTypes,this.excludeTypes=i.excludeTypes,this.excludeUnclassifiedObjects=i.excludeUnclassifiedObjects,this.reuseGeometries=i.reuseGeometries}get supportedVersions(){return Object.keys(Rn)}get textureTranscoder(){return this._textureTranscoder}set textureTranscoder(e){this._textureTranscoder=e}get dataSource(){return this._dataSource}set dataSource(e){this._dataSource=e||new dee}get objectDefaults(){return this._objectDefaults}set objectDefaults(e){this._objectDefaults=e||see}get includeTypes(){return this._includeTypes}set includeTypes(e){this._includeTypes=e}get excludeTypes(){return this._excludeTypes}set excludeTypes(e){this._excludeTypes=e}get includeIds(){return this._includeIds}set includeIds(e){this._includeIds=e}get excludeUnclassifiedObjects(){return this._excludeUnclassifiedObjects}set excludeUnclassifiedObjects(e){this._excludeUnclassifiedObjects=!!e}get globalizeObjectIds(){return this._globalizeObjectIds}set globalizeObjectIds(e){this._globalizeObjectIds=!!e}get reuseGeometries(){return this._reuseGeometries}set reuseGeometries(e){this._reuseGeometries=e!==!1}load(e={}){if(e.id&&this.viewer.scene.components[e.id]&&(this.error("Component with this ID already exists in viewer: "+e.id+" - will autogenerate this ID"),delete e.id),!e.src&&!e.xkt&&!e.manifestSrc&&!e.manifest)throw new Error("XKTLoaderPlugin: load() param expected: src, xkt, manifestSrc or manifestData");const i={},o=e.includeTypes||this._includeTypes,n=e.excludeTypes||this._excludeTypes,r=e.includeIds||this._includeIds,a=e.objectDefaults||this._objectDefaults;if(i.reuseGeometries=e.reuseGeometries!==null&&e.reuseGeometries!==void 0?e.reuseGeometries:this._reuseGeometries!==!1,o){i.includeTypesMap={};for(let A=0,f=o.length;A<f;A++)i.includeTypesMap[o[A]]=!0}if(n){i.excludeTypesMap={};for(let A=0,f=n.length;A<f;A++)i.excludeTypesMap[n[A]]=!0}if(r){i.includeIdsMap={};for(let A=0,f=r.length;A<f;A++)i.includeIdsMap[r[A]]=!0}a&&(i.objectDefaults=a),i.excludeUnclassifiedObjects=e.excludeUnclassifiedObjects!==void 0?!!e.excludeUnclassifiedObjects:this._excludeUnclassifiedObjects,i.globalizeObjectIds=e.globalizeObjectIds!==void 0&&e.globalizeObjectIds!==null?!!e.globalizeObjectIds:this._globalizeObjectIds;const s=new g3(this.viewer.scene,mt.apply(e,{isModel:!0,textureTranscoder:this._textureTranscoder,maxGeometryBatchSize:this._maxGeometryBatchSize,origin:e.origin,disableVertexWelding:e.disableVertexWelding||!1,disableIndexRebucketing:e.disableIndexRebucketing||!1,dtxEnabled:e.dtxEnabled,renderOrder:e.renderOrder})),l=s.id,c=new dX({metaScene:this.viewer.metaScene,id:l});this.viewer.scene.canvas.spinner.processes++;const d=()=>{s.destroyed||(s.finalize(),c.finalize(),this.viewer.scene.canvas.spinner.processes--,s.once("destroyed",()=>{this.viewer.metaScene.destroyMetaModel(c.id)}),this.scheduleTask(()=>{s.destroyed||(s.scene.fire("modelLoaded",s.id),s.fire("loaded",!0,!1))}))},u=A=>{this.viewer.scene.canvas.spinner.processes--,this.error(A),s.fire("error",A)};let h=0;const p={getNextId:()=>`${l}.${h++}`};if(e.metaModelSrc||e.metaModelData)if(e.metaModelSrc){const A=e.metaModelSrc;this._dataSource.getMetaModel(A,f=>{s.destroyed||(c.loadData(f,{includeTypes:o,excludeTypes:n,globalizeObjectIds:i.globalizeObjectIds}),e.src?this._loadModel(e.src,i,s,null,p,d,u):(this._parseModel(e.xkt,i,s,null,p),d()))},f=>{u(`load(): Failed to load model metadata for model '${l} from '${A}' - ${f}`)})}else e.metaModelData&&(c.loadData(e.metaModelData,{includeTypes:o,excludeTypes:n,globalizeObjectIds:i.globalizeObjectIds}),e.src?this._loadModel(e.src,i,s,null,p,d,u):(this._parseModel(e.xkt,i,s,null,p),d()));else if(e.src)this._loadModel(e.src,i,s,c,p,d,u);else if(e.xkt)this._parseModel(e.xkt,i,s,c,p),d();else if(e.manifestSrc||e.manifest){const A=e.manifestSrc?fFt(e.manifestSrc):"",f=(y,v,w)=>{let x=0;const k=()=>{s.destroyed||x>=y.length?v():this._dataSource.getMetaModel(`${A}${y[x]}`,B=>{c.loadData(B,{includeTypes:o,excludeTypes:n,globalizeObjectIds:i.globalizeObjectIds}),x++,this.scheduleTask(k,200)},w)};k()},m=(y,v,w)=>{let x=0;const k=()=>{s.destroyed||x>=y.length?v():this._dataSource.getXKT(`${A}${y[x]}`,B=>{this._parseModel(B,i,s,null,p),s.preFinalize(),x++,this.scheduleTask(k,200)},w)};k()},g=(y,v,w)=>{let x=0;const k=()=>{s.destroyed||x>=y.length?v():this._dataSource.getXKT(`${A}${y[x]}`,B=>{this._parseModel(B,i,s,c,p),s.preFinalize(),x++,this.scheduleTask(k,200)},w)};k()};if(e.manifest){const y=e.manifest,v=y.xktFiles;if(!v||v.length===0){u("load(): Failed to load model manifest - manifest not valid");return}const w=y.metaModelFiles;w?f(w,()=>{m(v,d,u)},u):g(v,d,u)}else this._dataSource.getManifest(e.manifestSrc,y=>{if(s.destroyed)return;const v=y.xktFiles;if(!v||v.length===0){u("load(): Failed to load model manifest - manifest not valid");return}const w=y.metaModelFiles;w?f(w,()=>{m(v,d,u)},u):g(v,d,u)},u)}return s}_loadModel(e,i,o,n,r,a,s){this._dataSource.getXKT(e,l=>{this._parseModel(l,i,o,n,r),o.preFinalize(),a()},s)}async _parseModel(e,i,o,n,r){if(o.destroyed)return;const a=new DataView(e),s=new Uint8Array(e),l=a.getUint32(0,!0),c=l&2147483647,d=c<11||c>=12&&l>>>31,u=Rn[c];if(!u){this.error("Unsupported .XKT file version: "+c+" - this XKTLoaderPlugin supports versions "+Object.keys(Rn));return}if(!d){u.parseArrayBuffer(this.viewer,i,e,o,n,r);return}const h=a.getUint32(4,!0),p=[];let A=(h+2)*4;for(let f=0;f<h;f++){const m=a.getUint32((f+2)*4,!0);p.push(s.subarray(A,A+m)),A+=m}u.parse(this.viewer,i,p,o,n,r)}}function fFt(t){t.indexOf("?")>-1&&(t=t.split("?")[0]);const e=t.split("/");return e.pop(),e.join("/")+"/"}let AFt=1;class T_{constructor(e,i,o=null){this.tileset=e,this.computePriority=e.plugin.computePriority,this.distanceFactorToFreeData=e.plugin.distanceFactorToFreeData,this.src=i.content?.uri??null;const n=this.src?new URL(this.src).pathname:null;this.name=`${e.name}_${n?n.substring(n.lastIndexOf("/")+1):`tileWithNoContent_${AFt++}`}`,this.parent=o,this.refine=i.refine,this.data=null,this.fetching=null,this.depth=o?o.depth+1:1,this.model=null,this.loadProcess=null,this.loading=!1,this.currentDistanceFromCamera=null,this._visible=!o,this.priority=1,this.geometricError=i.geometricError;const[r,a,s,l,c,d,u,h,p,A,f,m]=i.boundingVolume.box,g=[r,s,-a];e.rootTransform&&(g[0]+=e.rootTransform[12],g[1]+=e.rootTransform[14],g[2]-=e.rootTransform[13]),this.center=Object.freeze(g);const y=[l,c,d],v=[-u,-h,-p],w=[A,f,m];this.xSize=C.lenVec3(y),this.ySize=C.lenVec3(w),this.zSize=C.lenVec3(v),this.volume=this.xSize*2*this.ySize*2*this.zSize*2,this.children=i.children?.map(x=>new T_(e,x,this))??[],e.tiles.add(this)}get visible(){return this._visible}set visible(e){this._visible!==e&&(this._visible=e,e?this.tileset.visibleTiles.add(this):this.tileset.visibleTiles.delete(this))}get loaded(){return!!this.model}get viewDistance(){return this.tileset.sensitivity*this.geometricError}get isWithinCameraVisibleRange(){return this.currentDistanceFromCamera<=this.viewDistance}updateVisibility(e){this.currentDistanceFromCamera=C.distVec3(this.center,e),this.parent&&(this.visible=this.isWithinCameraVisibleRange,this.currentDistanceFromCamera>this.viewDistance*this.distanceFactorToFreeData&&(this.data=null)),this.visible&&this.children.forEach(i=>i.updateVisibility(e)),this.priority=this.computePriority(this)}fetchData(){return this.data?this.data:this.src?(this.fetching||(this.fetching=new Promise((e,i)=>{fetch(this.src).then(o=>{o.ok?o.arrayBuffer().then(n=>{this.data=n,this.fetching=null,e(this.data)}):i(o)})})),this.fetching):null}showBoundingBox(){const{viewer:e}=this.tileset.plugin,{xSize:i,ySize:o,zSize:n,center:r}=this,a=1/this.depth;this.boxLines=new mi(e.scene,{geometry:new Ao(e.scene,qE({center:r,xSize:i,ySize:o,zSize:n})),material:new go(e.scene,{emissive:[1-a,a,(1-a)/2]})})}async load(){if(this.loading)return this.loadProcess;if(this.loaded)return this.model;if(this.loading=!0,!this.data)try{await this.fetchData()}catch(e){return console.warn(`[Xeokit - TilesetLoaderPlugin] Impossible to fetch data of tile "${this.name}".`,e),this.loading=!1,null}if(!this.visible)return this.loading=!1,null;this.tileset.plugin.debugMode&&this.showBoundingBox();try{const e=new Promise(i=>{const o=this.tileset.plugin.loader.load({id:this.name,xkt:this.data,metaModelData:{metaObjects:[{id:"metaModelRoot"}]}});o.once("loaded",()=>{this.loading=!1,this.loadProcess=null,this.model=o,this.tileset.destroyed||!this.visible?(this.unload(),i(null)):(this.tileset.loadedTiles.add(this),i(o))}),o.once("destroyed",()=>{this.loading=!1,this.loadProcess=null,i(null)})});return this.loadProcess=e,this.loadProcess}catch(e){return console.warn(`[Xeokit - TilesetLoaderPlugin] Impossible to load tile "${this.name}".`,e),null}}unload(){this.boxLines&&(this.boxLines.destroy(),this.boxLines=null),this.model&&(this.model.destroy(),this.model=null),this.tileset.loadedTiles.delete(this),this.children.forEach(e=>{e.loaded&&e.unload()})}}function gFt(t,e,i){const o=Array.from(t),n=o.splice(0,e),r=async a=>{if(await i(a),o.length>0){const s=o.shift();r(s)}};n.forEach(r)}function mFt(t){let e=!1;return{cancel(){e=!0},async run(i){for(let o of t){if(e)break;await new Promise(n=>setTimeout(()=>(i(o)||Promise.resolve()).then(n)))}}}}let vFt=0;class yFt{constructor(e,i){this.plugin=e,this.name=i.name||`tileset-${vFt++}`,this.tiles=new Set,this.visibleTiles=new Set,this.loadedTiles=new Set,this.queue=null,this.renderNeeded=!0,this.destroyed=!1,this._sensitivity=e.sensitivity,i.root.transform&&(this.rootTransform=i.root.transform),this.root=new T_(this,i.root),this.root.load().then(o=>e.viewer.cameraFlight.flyTo(o))}get sensitivity(){return this._sensitivity}set sensitivity(e){this._sensitivity=e,this.updateVisibility()}updateVisibility(){this.tiles.forEach(e=>{e!==this.root&&(e.visible=!1)}),this.root.updateVisibility(this.plugin.viewer.camera.eye),this.renderNeeded=!0}render(){if(!this.renderNeeded)return;this.queue&&this.queue.cancel(),this.loadedTiles.forEach(i=>{i.visible||i.unload()});const e=Array.from(this.visibleTiles).filter(i=>!i.loaded).sort((i,o)=>i.priority-o.priority);gFt(e,40,i=>i.fetchData()),this.queue=mFt(e),this.queue.run(i=>i.load()),this.renderNeeded=!1}destroy(){this.queue&&this.queue.cancel(),this.loadedTiles.forEach(e=>e.unload()),this.destroyed=!0,this.plugin.tilesets.delete(this)}}function bFt(t){return t.depth}class Fee extends Ha{constructor(e,i={}){super("TilesetLoader",e);const{computePriority:o=bFt,sensitivity:n=50,distanceFactorToFreeData:r=3,debugMode:a=!1}=i;this._sensitivity=n,this.distanceFactorToFreeData=r,this.computePriority=o,this.debugMode=a,this.tilesets=new Set,e.camera.on("matrix",this.updateTilesetsVisibilityCallback=()=>this.updateTilesetsVisibility()),e.scene.on("tick",this.renderTilesetsCallback=()=>this.renderTilesets()),this.loader=new T9(e)}load(e){const i=new yFt(this,e);return this.tilesets.add(i),i}updateTilesetsVisibility(){this.tilesets.forEach(e=>e.updateVisibility())}renderTilesets(){this.tilesets.forEach(e=>e.render())}get sensitivity(){return this._sensitivity}set sensitivity(e){this._sensitivity=e,this.tilesets.forEach(i=>i.sensitivity=this._sensitivity)}destroy(){this.viewer.camera.off(this.updateTilesetsVisibilityCallback),this.viewer.scene.off(this.renderTilesetsCallback),this.tilesets.forEach(e=>e.destroy()),super.destroy()}}const wFt="2.6.90";typeof window<"u"&&(window.__XEOKIT__?console.warn("WARNING: Multiple instances of xeokit-sdk being imported."):window.__XEOKIT__=wFt);const Cc=Object.freeze(Object.defineProperty({__proto__:null,AlphaFormat:mZ,AmbientLight:JP,AngleMeasurementEditMouseControl:ZEt,AngleMeasurementEditTouchControl:WEt,AngleMeasurementsControl:CI,AngleMeasurementsMouseControl:bX,AngleMeasurementsPlugin:e9,AngleMeasurementsTouchControl:JEt,AnnotationsPlugin:kI,AxisGizmoPlugin:tPt,BCFViewpointsPlugin:a9,Bitmap:XZ,ByteType:sZ,CameraMemento:jMt,CameraPath:hbt,CameraPathAnimation:Lr,ClampToEdgeWrapping:ln,Component:ai,CompressedMediaType:Fbt,Configs:w7,ContextMenu:I9t,CubicBezierCurve:zMt,Curve:qv,DefaultLoadingManager:rY,DepthFormat:wZ,DepthStencilFormat:CZ,DirLight:ws,DistanceMeasurementEditControl:BI,DistanceMeasurementEditMouseControl:cPt,DistanceMeasurementEditTouchControl:dPt,DistanceMeasurementsControl:MI,DistanceMeasurementsMouseControl:MX,DistanceMeasurementsPlugin:BX,DistanceMeasurementsTouchControl:lPt,EdgeMaterial:bP,EmphasisMaterial:cc,FastNavPlugin:SX,FloatType:hZ,Fresnel:Iwt,Frustum:ga,FrustumPlane:ah,GIFMediaType:_bt,GLTFDefaultDataSource:TX,GLTFLoaderPlugin:pS,HalfFloatType:pZ,ImagePlane:wwt,IntType:dZ,JPEGMediaType:h7,KTX2TextureTranscoder:Rs,LOD:kY,LambertMaterial:Cwt,LightMap:UMt,LineSet:vY,LinearEncoding:Jn,LinearFilter:cn,LinearMipMapLinearFilter:A1,LinearMipMapNearestFilter:Jv,LinearMipmapLinearFilter:uh,LinearMipmapNearestFilter:Lbt,Loader:nY,LoadingManager:oY,LocaleService:VJ,LuminanceAlphaFormat:bZ,LuminanceFormat:yZ,Map:Va,Marker:v3,MarqueePicker:Pl,MarqueePickerMouseControl:ubt,Mesh:mi,MeshSurfaceArea:oW,MeshVolume:eW,MetallicMaterial:Mwt,MirroredRepeatWrapping:nc,ModelMemento:VMt,NavCubePlugin:fS,NearestFilter:dh,NearestMipMapLinearFilter:f1,NearestMipMapNearestFilter:Kv,NearestMipmapLinearFilter:aZ,NearestMipmapNearestFilter:nZ,Node:Gv,ObjectsKdTree3:R9t,ObjectsMemento:HMt,PNGMediaType:p7,Path:qMt,PerformanceModel:GMt,PhongMaterial:go,PickResult:U7,Plugin:Ha,PointLight:_Mt,PointerCircle:OE,PointerLens:S9t,QuadraticBezierCurve:QMt,Queue:TJ,RGBAFormat:Zv,RGBAIntegerFormat:EZ,RGBA_ASTC_10x10_Format:sP,RGBA_ASTC_10x5_Format:rP,RGBA_ASTC_10x6_Format:nP,RGBA_ASTC_10x8_Format:aP,RGBA_ASTC_12x10_Format:lP,RGBA_ASTC_12x12_Format:cP,RGBA_ASTC_4x4_Format:d7,RGBA_ASTC_5x4_Format:YE,RGBA_ASTC_5x5_Format:XE,RGBA_ASTC_6x5_Format:$E,RGBA_ASTC_6x6_Format:eP,RGBA_ASTC_8x5_Format:tP,RGBA_ASTC_8x6_Format:iP,RGBA_ASTC_8x8_Format:oP,RGBA_BPTC_Format:u7,RGBA_ETC2_EAC_Format:c7,RGBA_PVRTC_2BPPV1_Format:ZE,RGBA_PVRTC_4BPPV1_Format:s7,RGBA_S3TC_DXT1_Format:r7,RGBA_S3TC_DXT3_Format:n7,RGBA_S3TC_DXT5_Format:Yv,RGBFormat:vZ,RGB_ETC1_Format:WE,RGB_ETC2_Format:l7,RGB_PVRTC_2BPPV1_Format:JE,RGB_PVRTC_4BPPV1_Format:a7,RGB_S3TC_DXT1_Format:Wv,RGFormat:MZ,RGIntegerFormat:BZ,ReadableGeometry:Ao,RedFormat:xZ,RedIntegerFormat:kZ,ReflectionMap:OMt,RepeatWrapping:wo,SceneModel:g3,SceneModelMesh:nW,SceneModelTransform:uY,SectionPlane:XP,SectionPlanesPlugin:f_t,ShortType:lZ,SpecularMaterial:Pwt,SplineCurve:Xy,SpriteMarker:NMt,Texture:g1,TextureTranscoder:ZMt,TilesetLoaderPlugin:Fee,UnsignedByteType:KE,UnsignedInt248Type:gZ,UnsignedIntType:uZ,UnsignedShort4444Type:fZ,UnsignedShort5551Type:AZ,UnsignedShortType:cZ,VBOGeometry:JJ,VFC:OY,Viewer:yX,WorkerPool:sY,XKTDefaultDataSource:dee,XKTLoaderPlugin:T9,buildBoxGeometry:zE,buildBoxLinesGeometry:qE,buildBoxLinesGeometryFromAABB:Ibt,buildCylinderGeometry:u1,buildGridGeometry:ZJ,buildLineGeometry:YJ,buildPlaneGeometry:QE,buildPolylineGeometry:WJ,buildPolylineGeometryFromCurve:Tbt,buildSphereGeometry:h1,buildTorusGeometry:GE,buildVectorTextGeometry:p1,createCombinedTexture:qEt,createRTCViewMat:Ni,createSkyboxMesh:QEt,createSphereMapMesh:GEt,frustumIntersectsAABB3:Yy,getKTX2TextureTranscoder:lY,getPlaneRTCPos:Wo,isTriangleMeshSolid:$Z,load3DSGeometry:Ebt,loadOBJGeometry:Pbt,math:C,meshSurfaceArea:t3,meshVolume:v1,os:oI,rtcToWorldPos:Rbt,sRGBEncoding:ho,setFrustum:jJ,stats:Ii,utils:mt,worldToRTCPos:ch,worldToRTCPositions:o7},Symbol.toStringTag,{value:"Module"}));function G1(t){let e=t.substring(1);const i=[];let o=null;for(;e.length>0;)o=e.substring(0,2),e=e.substring(2),i.push(parseInt(o,16)/255);return i}function Oee(t){let e="";return e+=Math.round(t[0]*255).toString(16).padStart(2,"0"),e+=Math.round(t[1]*255).toString(16).padStart(2,"0"),e+=Math.round(t[2]*255).toString(16).padStart(2,"0"),`#${e}`}const CFt={class:"annotations-3d"},xFt={__name:"Annotations3D",setup(t){const e=ct("$viewer"),{localContext:i}=e,{xeokit:o}=i.viewer,n=o.scene.canvas.canvas,r=RE(),a=Cr(new WeakSet),s=De(()=>r.value.filter(u=>a.has(u))),l=new Map;pt(r,()=>{r.value.forEach(u=>{if(!l.has(u.id)){const{x:h,y:p,z:A}=u,f=new v3(o.scene,{worldPos:[h,A,p]});l.set(u.id,f);const[m,g]=f.canvasPos;f.style=le(`left: ${m}px; top: ${g}px;`),f.on("canvasPos",([w,x])=>{f.style.value=`left: ${w}px; top: ${x}px;`}),f.on("visible",w=>w?a.add(u):a.delete(u)),f.on("destroyed",()=>{e.state.hub.off(v),e.state.hub.off(y)});const y=e.state.hub.on("annotation-updated",({annotation:w})=>{if(w.id===u.id){const{x,y:k,z:B}=w;f.worldPos=[x,B,k],f._update(),o.scene._renderer._occlusionTester._occlusionTestListDirty=!0}}),v=e.state.hub.on("annotation-removed",({annotation:w})=>{w.id===u.id&&(l.delete(u.id),f.destroy())})}})},{flush:"sync"});const c=(u,h)=>{const{clientX:p,clientY:A}=h,{x:f,y:m}=n.getBoundingClientRect(),g=o.scene.pick({pickSurface:!0,canvasPos:[p-f,A-m]});if(g){const[y,v,w]=g.worldPos;Object.assign(u,{x:y,y:w,z:v})}},d=u=>l.get(u.id).style.value;return(u,h)=>(M(),_("div",CFt,[(M(!0),_(Xe,null,Bt(s.value,p=>(M(),J(LE,{key:p.instanceId,annotation:p,canvas:ot(n),style:de(d(p)),onAnnotationDrag:A=>c(p,A)},null,8,["annotation","canvas","style","onAnnotationDrag"]))),128))]))}},Uee=j(xFt,[["__scopeId","data-v-10ceb001"]]),kFt={setup(){const t=ct("$viewer"),e=t.localContext.pluginComponentInstances.get("viewer3d"),{math:i}=e.xeokitSdk,o=()=>{const r=e.xeokit,a=[0,0,-1],s=r.scene.aabb,l=i.getAABB3Diag(s),c=i.vec3();i.getAABB3Center(s,c);const d=45,u=Math.abs(l/Math.tan(d*i.DEGTORAD));r.cameraControl.pivotPos=c,r.cameraFlight.jumpTo({look:c,eye:[c[0]-u*a[0],c[1]-u*a[1],c[2]-u*a[2]],up:[0,1,0],orthoScale:l*1.1,fitFOV:d})},n=()=>{const r=t.localContext.loadedModels.flatMap(a=>a.objects.filter(s=>s.visible===!1).map(s=>s.id));t.state.showObjects(r)};return{onClick:()=>{o(),n(),e.reintegrateObjects()}}}};function MFt(t,e,i,o,n,r){const a=I("BIMDataIconHome"),s=I("BIMDataButton");return M(),J(s,{color:"default",ghost:"",rounded:"",icon:"",onClick:o.onClick},{default:N(()=>[D(a,{size:"xs"})]),_:1},8,["onClick"])}const BFt=j(kFt,[["render",MFt]]),EFt={computed:{active(){return this.$viewer.localContext.pluginComponentInstances.has("navigationVersionsModel")?this.$viewer.localContext.pluginComponentInstances.get("navigationVersionsModel").isOpen.value:!1}},methods:{onClick(){this.$viewer.localContext.pluginComponentInstances.get("navigationVersionsModel").toggle()}}};function PFt(t,e,i,o,n,r){const a=I("BIMDataIcon"),s=I("BIMDataButton"),l=I("BIMDataTooltip");return M(),J(l,{text:t.$t("navigationVersionsModel.tooltip")},{default:N(()=>[D(s,{class:ce(["bimdata-navigation-versions-model",{active:r.active}]),color:"primary",ghost:"",rounded:"",icon:"",onClick:r.onClick},{default:N(()=>[D(a,{name:"versioning",fill:"",color:"primary",size:"xxs"})]),_:1},8,["class","onClick"])]),_:1},8,["text"])}const IFt=j(EFt,[["render",PFt],["__scopeId","data-v-ced27a96"]]),SFt={key:0,width:"159",height:"116",viewBox:"0 0 159 116",fill:"none",xmlns:"http://www.w3.org/2000/svg"},TFt={key:1,width:"159",height:"116",viewBox:"0 0 159 116",fill:"none",xmlns:"http://www.w3.org/2000/svg"},DFt={__name:"KeyboardNavigate",setup(t){const e=ct("$viewer").i18n.locale==="fr";return(i,o)=>e?(M(),_("svg",SFt,[...o[0]||(o[0]=[$r('<path d="M79 0L87 11H71L79 0Z" fill="#2F374A"></path><path d="M159 79.1111L148 87.1111L148 71.1111L159 79.1111Z" fill="#2F374A"></path><path d="M9.5399e-08 79.1111L11 71.1111L11 87.1111L9.5399e-08 79.1111Z" fill="#2F374A"></path><path d="M79 115.222L71 104.222L87 104.222L79 115.222Z" fill="#2F374A"></path><rect x="61.3333" y="18" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M82.5998 38.834V40H76.6759V38.834H82.5998ZM82.465 32.377L77.2209 40H76.2365V39.0684L81.4982 31.4688H82.465V32.377ZM81.9201 31.4688V32.6406H76.2716V31.4688H81.9201Z" fill="#6B6B6B"></path><rect x="104.667" y="61" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M122.148 83.1111H120.326L120.338 81.9451H122.148C122.676 81.9451 123.117 81.8298 123.473 81.5994C123.832 81.3689 124.101 81.0388 124.281 80.6091C124.465 80.1794 124.557 79.6677 124.557 79.074V78.6111C124.557 78.1501 124.504 77.7419 124.398 77.3865C124.297 77.031 124.144 76.7322 123.941 76.49C123.742 76.2478 123.496 76.0642 123.203 75.9392C122.914 75.8142 122.58 75.7517 122.201 75.7517H120.291V74.5798H122.201C122.767 74.5798 123.285 74.6755 123.754 74.8669C124.223 75.0544 124.627 75.3259 124.967 75.6814C125.31 76.0369 125.574 76.4626 125.758 76.9587C125.941 77.4548 126.033 78.0095 126.033 78.6228V79.074C126.033 79.6873 125.941 80.2419 125.758 80.738C125.574 81.2341 125.31 81.6599 124.967 82.0154C124.623 82.3669 124.213 82.6384 123.736 82.8298C123.264 83.0173 122.734 83.1111 122.148 83.1111ZM121.141 74.5798V83.1111H119.67V74.5798H121.141Z" fill="#6B6B6B"></path><rect x="18" y="61" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M37.3036 81.9744L39.5478 83.7556L38.5927 84.5935L36.3896 82.8298L37.3036 81.9744ZM39.5653 78.6111V79.0798C39.5653 79.7244 39.4814 80.3025 39.3134 80.8142C39.1454 81.3259 38.9052 81.7615 38.5927 82.1208C38.2802 82.4802 37.9071 82.7556 37.4735 82.947C37.04 83.1345 36.5595 83.2283 36.0321 83.2283C35.5087 83.2283 35.0302 83.1345 34.5966 82.947C34.1669 82.7556 33.7939 82.4802 33.4775 82.1208C33.161 81.7615 32.915 81.3259 32.7392 80.8142C32.5673 80.3025 32.4814 79.7244 32.4814 79.0798V78.6111C32.4814 77.9666 32.5673 77.3904 32.7392 76.8826C32.911 76.3708 33.1532 75.9353 33.4657 75.5759C33.7821 75.2126 34.1552 74.9373 34.5849 74.7498C35.0185 74.5583 35.497 74.4626 36.0204 74.4626C36.5478 74.4626 37.0282 74.5583 37.4618 74.7498C37.8993 74.9373 38.2743 75.2126 38.5868 75.5759C38.8993 75.9353 39.1396 76.3708 39.3075 76.8826C39.4794 77.3904 39.5653 77.9666 39.5653 78.6111ZM38.0888 79.0798V78.5994C38.0888 78.1228 38.0419 77.7029 37.9482 77.3396C37.8583 76.9724 37.7235 76.6658 37.5439 76.4197C37.3681 76.1697 37.1513 75.9822 36.8935 75.8572C36.6396 75.7283 36.3485 75.6638 36.0204 75.6638C35.7001 75.6638 35.413 75.7283 35.1591 75.8572C34.9052 75.9822 34.6884 76.1697 34.5087 76.4197C34.329 76.6658 34.1923 76.9724 34.0985 77.3396C34.0048 77.7029 33.9579 78.1228 33.9579 78.5994V79.0798C33.9579 79.5564 34.0048 79.9783 34.0985 80.3455C34.1923 80.7126 34.329 81.0232 34.5087 81.2771C34.6923 81.5271 34.911 81.7166 35.165 81.8455C35.4228 81.9705 35.7118 82.033 36.0321 82.033C36.3603 82.033 36.6513 81.9705 36.9052 81.8455C37.1591 81.7166 37.3739 81.5271 37.5497 81.2771C37.7255 81.0232 37.8583 80.7126 37.9482 80.3455C38.0419 79.9783 38.0888 79.5564 38.0888 79.0798Z" fill="#6B6B6B"></path><rect x="61.3333" y="61.1112" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M81.1115 81.025C81.1115 80.8492 81.0841 80.693 81.0295 80.5563C80.9787 80.4196 80.8869 80.2946 80.7541 80.1813C80.6213 80.068 80.4338 79.9586 80.1916 79.8531C79.9533 79.7438 79.6486 79.6324 79.2775 79.5192C78.8713 79.3942 78.4963 79.2555 78.1525 79.1031C77.8127 78.9469 77.5158 78.7672 77.2619 78.5641C77.008 78.3571 76.8107 78.1207 76.6701 77.8551C76.5295 77.5856 76.4591 77.275 76.4591 76.9235C76.4591 76.5758 76.5314 76.2594 76.6759 75.9742C76.8244 75.6891 77.0334 75.443 77.3029 75.236C77.5763 75.025 77.8986 74.8629 78.2697 74.7496C78.6408 74.6324 79.0509 74.5739 79.5002 74.5739C80.133 74.5739 80.6779 74.691 81.1349 74.9254C81.5959 75.1598 81.9494 75.4742 82.1955 75.8688C82.4455 76.2633 82.5705 76.6989 82.5705 77.1754H81.1115C81.1115 76.8942 81.0509 76.6461 80.9298 76.4313C80.8127 76.2125 80.633 76.0406 80.3908 75.9156C80.1525 75.7906 79.8498 75.7281 79.4826 75.7281C79.1349 75.7281 78.8459 75.7809 78.6154 75.8864C78.3849 75.9918 78.213 76.1344 78.0998 76.3141C77.9865 76.4938 77.9298 76.6969 77.9298 76.9235C77.9298 77.0836 77.967 77.2301 78.0412 77.3629C78.1154 77.4918 78.2287 77.6129 78.381 77.7262C78.5334 77.8356 78.7248 77.9391 78.9552 78.0367C79.1857 78.1344 79.4572 78.2281 79.7697 78.318C80.2423 78.4586 80.6545 78.6149 81.006 78.7867C81.3576 78.9547 81.6505 79.1461 81.8849 79.361C82.1193 79.5758 82.2951 79.8199 82.4123 80.0934C82.5295 80.3629 82.588 80.6696 82.588 81.0133C82.588 81.3727 82.5158 81.6969 82.3713 81.986C82.2267 82.2711 82.0197 82.5153 81.7502 82.7184C81.4845 82.9176 81.1642 83.0719 80.7892 83.1813C80.4181 83.2867 80.0041 83.3395 79.547 83.3395C79.1369 83.3395 78.7326 83.2848 78.3341 83.1754C77.9396 83.066 77.5802 82.9 77.256 82.6774C76.9318 82.4508 76.674 82.1696 76.4826 81.8336C76.2912 81.4938 76.1955 81.0973 76.1955 80.6442H77.6662C77.6662 80.9215 77.713 81.1578 77.8068 81.3531C77.9045 81.5485 78.0392 81.7086 78.2111 81.8336C78.383 81.9547 78.5822 82.0446 78.8088 82.1031C79.0392 82.1617 79.2853 82.191 79.547 82.191C79.8908 82.191 80.1779 82.1422 80.4084 82.0446C80.6427 81.9469 80.8185 81.8102 80.9357 81.6344C81.0529 81.4586 81.1115 81.2555 81.1115 81.025Z" fill="#6B6B6B"></path>',12)])])):(M(),_("svg",TFt,[...o[1]||(o[1]=[$r('<path d="M79 0L87 11H71L79 0Z" fill="#2F374A"></path><path d="M159 79.1111L148 87.1111L148 71.1111L159 79.1111Z" fill="#2F374A"></path><path d="M9.5399e-08 79.1111L11 71.1111L11 87.1111L9.5399e-08 79.1111Z" fill="#2F374A"></path><path d="M79 115.222L71 104.222L87 104.222L79 115.222Z" fill="#2F374A"></path><rect x="61.3333" y="18" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M77.1095 38.084L78.8088 31.4688H79.6994L79.5998 33.1738L77.7834 40H76.8576L77.1095 38.084ZM75.838 31.4688L77.215 38.0312L77.338 40H76.3537L74.3791 31.4688H75.838ZM81.6271 38.0137L82.9865 31.4688H84.4513L82.4767 40H81.4923L81.6271 38.0137ZM80.0451 31.4688L81.7267 38.1016L81.9728 40H81.047L79.2599 33.1738L79.1662 31.4688H80.0451Z" fill="#6B6B6B"></path><rect x="104.667" y="61" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M122.148 83.1111H120.326L120.338 81.9451H122.148C122.676 81.9451 123.117 81.8298 123.473 81.5994C123.832 81.3689 124.101 81.0388 124.281 80.6091C124.465 80.1794 124.557 79.6677 124.557 79.074V78.6111C124.557 78.1501 124.504 77.7419 124.398 77.3865C124.297 77.031 124.144 76.7322 123.941 76.49C123.742 76.2478 123.496 76.0642 123.203 75.9392C122.914 75.8142 122.58 75.7517 122.201 75.7517H120.291V74.5798H122.201C122.767 74.5798 123.285 74.6755 123.754 74.8669C124.223 75.0544 124.627 75.3259 124.967 75.6814C125.31 76.0369 125.574 76.4626 125.758 76.9587C125.941 77.4548 126.033 78.0095 126.033 78.6228V79.074C126.033 79.6873 125.941 80.2419 125.758 80.738C125.574 81.2341 125.31 81.6599 124.967 82.0154C124.623 82.3669 124.213 82.6384 123.736 82.8298C123.264 83.0173 122.734 83.1111 122.148 83.1111ZM121.141 74.5798V83.1111H119.67V74.5798H121.141Z" fill="#6B6B6B"></path><rect x="18" y="61" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M36.2665 75.7166L33.7177 83.1111H32.1767L35.3876 74.5798H36.372L36.2665 75.7166ZM38.3993 83.1111L35.8446 75.7166L35.7333 74.5798H36.7235L39.9462 83.1111H38.3993ZM38.2763 79.947V81.113H33.6357V79.947H38.2763Z" fill="#6B6B6B"></path><rect x="61.3333" y="61.1112" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M81.1115 81.025C81.1115 80.8492 81.0841 80.693 81.0295 80.5563C80.9787 80.4196 80.8869 80.2946 80.7541 80.1813C80.6213 80.068 80.4338 79.9586 80.1916 79.8531C79.9533 79.7438 79.6486 79.6324 79.2775 79.5192C78.8713 79.3942 78.4963 79.2555 78.1525 79.1031C77.8127 78.9469 77.5158 78.7672 77.2619 78.5641C77.008 78.3571 76.8107 78.1207 76.6701 77.8551C76.5295 77.5856 76.4591 77.275 76.4591 76.9235C76.4591 76.5758 76.5314 76.2594 76.6759 75.9742C76.8244 75.6891 77.0334 75.443 77.3029 75.236C77.5763 75.025 77.8986 74.8629 78.2697 74.7496C78.6408 74.6324 79.0509 74.5739 79.5002 74.5739C80.133 74.5739 80.6779 74.691 81.1349 74.9254C81.5959 75.1598 81.9494 75.4742 82.1955 75.8688C82.4455 76.2633 82.5705 76.6989 82.5705 77.1754H81.1115C81.1115 76.8942 81.0509 76.6461 80.9298 76.4313C80.8127 76.2125 80.633 76.0406 80.3908 75.9156C80.1525 75.7906 79.8498 75.7281 79.4826 75.7281C79.1349 75.7281 78.8459 75.7809 78.6154 75.8864C78.3849 75.9918 78.213 76.1344 78.0998 76.3141C77.9865 76.4938 77.9298 76.6969 77.9298 76.9235C77.9298 77.0836 77.967 77.2301 78.0412 77.3629C78.1154 77.4918 78.2287 77.6129 78.381 77.7262C78.5334 77.8356 78.7248 77.9391 78.9552 78.0367C79.1857 78.1344 79.4572 78.2281 79.7697 78.318C80.2423 78.4586 80.6545 78.6149 81.006 78.7867C81.3576 78.9547 81.6505 79.1461 81.8849 79.361C82.1193 79.5758 82.2951 79.8199 82.4123 80.0934C82.5295 80.3629 82.588 80.6696 82.588 81.0133C82.588 81.3727 82.5158 81.6969 82.3713 81.986C82.2267 82.2711 82.0197 82.5153 81.7502 82.7184C81.4845 82.9176 81.1642 83.0719 80.7892 83.1813C80.4181 83.2867 80.0041 83.3395 79.547 83.3395C79.1369 83.3395 78.7326 83.2848 78.3341 83.1754C77.9396 83.066 77.5802 82.9 77.256 82.6774C76.9318 82.4508 76.674 82.1696 76.4826 81.8336C76.2912 81.4938 76.1955 81.0973 76.1955 80.6442H77.6662C77.6662 80.9215 77.713 81.1578 77.8068 81.3531C77.9045 81.5485 78.0392 81.7086 78.2111 81.8336C78.383 81.9547 78.5822 82.0446 78.8088 82.1031C79.0392 82.1617 79.2853 82.191 79.547 82.191C79.8908 82.191 80.1779 82.1422 80.4084 82.0446C80.6427 81.9469 80.8185 81.8102 80.9357 81.6344C81.0529 81.4586 81.1115 81.2555 81.1115 81.025Z" fill="#6B6B6B"></path>',12)])]))}},RFt={key:0,width:"37",height:"129",viewBox:"0 0 37 129",fill:"none",xmlns:"http://www.w3.org/2000/svg"},LFt={key:1,width:"37",height:"129",viewBox:"0 0 37 129",fill:"none",xmlns:"http://www.w3.org/2000/svg"},_Ft={__name:"KeyboardStorey",setup(t){const e=ct("$viewer"),i=De(()=>e.i18n.locale==="fr");return(o,n)=>i.value?(M(),_("svg",RFt,[...n[0]||(n[0]=[$r('<rect y="25" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M16.2509 38.4688L18.0614 41.5801L19.872 38.4688H21.5653L18.9872 42.6934L21.6298 47H19.9189L18.0614 43.8301L16.204 47H14.4872L17.1357 42.6934L14.5517 38.4688H16.2509Z" fill="#6B6B6B"></path><rect y="68.1112" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M15.7763 88.3063L17.4755 81.691H18.3661L18.2665 83.3961L16.4501 90.2223H15.5243L15.7763 88.3063ZM14.5048 81.691L15.8817 88.2535L16.0048 90.2223H15.0204L13.0458 81.691H14.5048ZM20.2939 88.236L21.6532 81.691H23.1181L21.1435 90.2223H20.1591L20.2939 88.236ZM18.7118 81.691L20.3935 88.3239L20.6396 90.2223H19.7138L17.9267 83.3961L17.8329 81.691H18.7118Z" fill="#6B6B6B"></path><path d="M18 0L26 11H10L18 0Z" fill="#2F374A"></path><rect x="14" y="13" width="8" height="2" fill="#2F374A"></rect><rect x="14" y="17" width="8" height="4" fill="#2F374A"></rect><path d="M18 129L10 118L26 118L18 129Z" fill="#2F374A"></path><rect x="22" y="116" width="8" height="2" transform="rotate(-180 22 116)" fill="#2F374A"></rect><rect x="22" y="112" width="8" height="4" transform="rotate(-180 22 112)" fill="#2F374A"></rect>',10)])])):(M(),_("svg",LFt,[...n[1]||(n[1]=[$r('<rect y="25" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M16.2509 38.4688L18.0614 41.5801L19.872 38.4688H21.5653L18.9872 42.6934L21.6298 47H19.9189L18.0614 43.8301L16.204 47H14.4872L17.1357 42.6934L14.5517 38.4688H16.2509Z" fill="#6B6B6B"></path><rect y="68.1112" width="36.1112" height="36.1112" rx="5" fill="#D8D8D8"></rect><path d="M21.2665 89.0563V90.2223H15.3427V89.0563H21.2665ZM21.1317 82.5992L15.8876 90.2223H14.9032V89.2906L20.165 81.691H21.1317V82.5992ZM20.5868 81.691V82.8629H14.9384V81.691H20.5868Z" fill="#6B6B6B"></path><path d="M18 0L26 11H10L18 0Z" fill="#2F374A"></path><rect x="14" y="13" width="8" height="2" fill="#2F374A"></rect><rect x="14" y="17" width="8" height="4" fill="#2F374A"></rect><path d="M18 129L10 118L26 118L18 129Z" fill="#2F374A"></path><rect x="22" y="116" width="8" height="2" transform="rotate(-180 22 116)" fill="#2F374A"></rect><rect x="22" y="112" width="8" height="4" transform="rotate(-180 22 112)" fill="#2F374A"></rect>',10)])]))}},FFt={},OFt={width:"174",height:"130",viewBox:"0 0 174 130",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function UFt(t,e){return M(),_("svg",OFt,[...e[0]||(e[0]=[$r('<path d="M33.1118 0.382324H131.606L141.853 99.4882H23.4L33.1118 0.382324Z" fill="#F2F2F2"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M22.9412 99.8706H142.235L131.988 0.305882V0H32.8059L23.0176 99.4882L22.9412 99.8706ZM141.394 99.1059H23.7823L33.4941 0.764706H131.3L141.394 99.1059Z" fill="#9E9E9E"></path><path d="M62.1705 9.86475L60.7941 46.953H103.771V9.86475H62.1705Z" fill="white"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M60.4117 47.3354H104.153H104.229V9.48242H61.8647L60.4117 47.3354ZM103.388 46.5707H61.1764L62.5529 10.2471H103.388V46.5707Z" fill="#9E9E9E"></path><path d="M60.7942 46.9529L64.5412 61.7882H100.1L103.771 46.9529H60.7942Z" fill="white"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M64.2353 62.1706H100.406L104.306 46.5706H60.3353L64.2353 62.1706ZM99.7942 61.4059H64.8471L61.3294 47.3353H103.312L99.7942 61.4059Z" fill="#9E9E9E"></path><path d="M85.2648 34.7939L85.0354 53.8351L90.0825 49.0175L97.806 49.5528L85.2648 34.7939Z" fill="white"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M83.8118 57.5823L83.7354 31.5823L100.406 51.4646L90.3883 49.9352L83.8118 57.5823ZM85.8765 37.3176L85.953 51.9235L89.6236 47.6411L95.2824 48.4823L85.8765 37.3176Z" fill="black"></path><path d="M26.3059 128.241H25.9236C17.5883 128.241 10.7059 121.359 10.7059 113.024V100.253C10.7059 91.9178 17.5883 85.0354 25.9236 85.0354H26.3059C34.6412 85.0354 41.5236 91.9178 41.5236 100.253V113.024C41.5236 121.359 34.6412 128.241 26.3059 128.241Z" fill="white"></path><path d="M137.188 128.241H136.806C128.471 128.241 121.588 121.359 121.588 113.024V100.253C121.588 91.9178 128.471 85.0354 136.806 85.0354H137.188C145.524 85.0354 152.406 91.9178 152.406 100.253V113.024C152.406 121.359 145.524 128.241 137.188 128.241Z" fill="white"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M25.4647 129.159H26.9942C35.6353 129.159 42.6706 122.2 42.5942 113.559V99.6413C42.5942 91.0766 35.6353 84.0413 26.9942 84.0413H25.4647C16.9 84.0413 9.86475 91.0001 9.86475 99.6413V113.559C9.86475 122.124 16.8236 129.159 25.4647 129.159ZM12.1589 99.5648C12.1589 92.2236 18.1236 86.2589 25.4647 86.2589H26.9942C34.3353 86.2589 40.3 92.2236 40.3 99.5648V113.482C40.3 120.824 34.3353 126.788 26.9942 126.788H25.4647C18.1236 126.788 12.1589 120.824 12.1589 113.482V99.5648Z" fill="#30374B"></path><path d="M26.3823 104.459C25.5411 104.459 24.8529 103.771 24.8529 102.929V98.4176C24.8529 97.5764 25.5411 96.8882 26.3823 96.8882C27.2235 96.8882 27.9117 97.5764 27.9117 98.4176V102.929C27.9117 103.771 27.2235 104.459 26.3823 104.459Z" fill="#30374B"></path><path d="M15.3706 84.1177C14.8353 84.1177 14.3765 83.6589 14.3765 83.1236V75.4765C14.3765 74.9412 14.8353 74.4824 15.3706 74.4824C15.9059 74.4824 16.3647 74.9412 16.3647 75.4765V83.1236C16.3647 83.6589 15.9059 84.1177 15.3706 84.1177Z" fill="#F8C62C"></path><path d="M9.63529 90.3884C9.63529 90.9237 9.17647 91.3825 8.64118 91.3825H0.994118C0.458824 91.3825 0 90.9237 0 90.3884C0 89.8531 0.458824 89.3943 0.994118 89.3943H8.64118C9.17647 89.3943 9.63529 89.8531 9.63529 90.3884Z" fill="#F8C62C"></path><path d="M11.9294 86.4117C11.5471 86.7941 10.8589 86.7941 10.4765 86.4117L3.74709 79.6823C3.36474 79.3 3.36474 78.6117 3.74709 78.2294C4.12944 77.847 4.81768 77.847 5.20003 78.2294L11.9294 84.9588C12.3118 85.3412 12.3118 86.0294 11.9294 86.4117Z" fill="#F8C62C"></path><path d="M87.7117 105.682H82.9706V100.941H80.8294V105.682H76.1647V107.747H80.8294V112.488H82.9706V107.747H87.7117V105.682Z" fill="#F8C62C"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M136.194 129.159H137.724C146.365 129.159 153.4 122.2 153.324 113.559V99.6413C153.324 91.0766 146.365 84.0413 137.724 84.0413H136.194C127.629 84.0413 120.594 91.0001 120.594 99.6413V113.559C120.594 122.124 127.553 129.159 136.194 129.159ZM122.888 99.5648C122.888 92.2236 128.853 86.2589 136.194 86.2589H137.724C145.065 86.2589 151.029 92.2236 151.029 99.5648V113.482C151.029 120.824 145.065 126.788 137.724 126.788H136.194C128.853 126.788 122.888 120.824 122.888 113.482V99.5648Z" fill="#30374B"></path><path d="M137.112 104.459C136.271 104.459 135.582 103.771 135.582 102.929V98.4176C135.582 97.5764 136.271 96.8882 137.112 96.8882C137.953 96.8882 138.641 97.5764 138.641 98.4176V102.929C138.641 103.771 137.953 104.459 137.112 104.459Z" fill="#30374B"></path><path d="M102.776 106.753L108.129 101.4C108.588 100.941 108.588 100.253 108.129 99.7941C107.671 99.3352 106.982 99.3352 106.524 99.7941L100.406 105.912C100.176 106.141 100.1 106.447 100.1 106.753C100.1 107.059 100.176 107.365 100.406 107.594L106.524 113.712C106.982 114.171 107.671 114.171 108.129 113.712C108.588 113.253 108.588 112.565 108.129 112.106L102.776 106.753Z" fill="#F8C62C"></path><path d="M171.218 106.753L165.865 101.4C165.406 100.941 165.406 100.253 165.865 99.7941C166.324 99.3352 167.012 99.3352 167.471 99.7941L173.588 105.912C173.818 106.141 173.894 106.447 173.894 106.753C173.894 107.059 173.818 107.365 173.588 107.594L167.471 113.712C167.012 114.171 166.324 114.171 165.865 113.712C165.406 113.253 165.406 112.565 165.865 112.106L171.218 106.753Z" fill="#F8C62C"></path>',20)])])}const NFt=j(FFt,[["render",UFt]]),jFt={},VFt={width:"42",height:"55",viewBox:"0 0 42 55",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function HFt(t,e){return M(),_("svg",VFt,[...e[0]||(e[0]=[$r('<path d="M1.7192 47.4914L0.501465 10.6013H40.8298L40.3284 47.4914H1.7192Z" fill="white"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M1.36104 47.8495H40.6866L41.188 10.2432H0.143311L1.36104 47.8495ZM39.9703 47.1332H2.07735L0.859623 10.9595H40.4717L39.9703 47.1332Z" fill="#9E9E9E"></path><path d="M4.29792 0.429688L0.501465 10.6013H40.8298L37.5348 0.429688H4.29792Z" fill="white"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M0 10.9596H41.3312L37.7496 0H4.01135L0 10.9596ZM40.3284 10.2433H1.00284L4.51277 0.716312H37.2482L40.3284 10.2433Z" fill="#9E9E9E"></path><path d="M18.9312 23.0255C19.4326 23.0255 19.8624 22.5957 19.8624 22.0943V14.9312C19.8624 14.4298 19.4326 14 18.9312 14C18.4298 14 18 14.4298 18 14.9312V22.0943C18 22.5957 18.4298 23.0255 18.9312 23.0255Z" fill="#F8C62C"></path><path d="M24.3035 28.9708C24.3035 29.4722 24.7333 29.902 25.2347 29.902H32.3978C32.8992 29.902 33.329 29.4722 33.329 28.9708C33.329 28.4693 32.8992 28.0395 32.3978 28.0395H25.2347C24.7333 27.9679 24.3035 28.3977 24.3035 28.9708Z" fill="#F8C62C"></path><path d="M22.1546 25.2461C22.5128 25.6043 23.1575 25.6043 23.5156 25.2461L29.8192 18.9426C30.1773 18.5844 30.1773 17.9398 29.8192 17.5816C29.461 17.2234 28.8163 17.2234 28.4582 17.5816L22.1546 23.8852C21.7248 24.2433 21.7248 24.8164 22.1546 25.2461Z" fill="#F8C62C"></path><path d="M21.5855 31.4087L21.3477 51.0688L26.5798 46.0745L34.5865 46.6294L21.5855 31.4087Z" fill="white"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M20.0793 54.9534L20 28L37.2819 48.6114L26.8969 47.0259L20.0793 54.9534ZM22.2197 33.9456L22.299 49.087L26.1041 44.6477L31.9705 45.5197L22.2197 33.9456Z" fill="black"></path>',9)])])}const zFt=j(jFt,[["render",HFt]]),qFt={},QFt={width:"124",height:"152",viewBox:"0 0 124 152",fill:"none",xmlns:"http://www.w3.org/2000/svg"};function GFt(t,e){return M(),_("svg",QFt,[...e[0]||(e[0]=[$r('<path d="M10.5436 0.396484H112.649L123.272 103.216H0.475708L10.5436 0.396484Z" fill="#F2F2F2"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M0 103.612H123.668L113.046 0.317098V0H10.2264L0.0792746 103.216L0 103.612ZM122.876 102.819H0.951324L10.9399 0.792766H112.332L122.876 102.819Z" fill="#9E9E9E"></path><path d="M40.7472 10.2266L39.241 48.6747H83.7933V10.2266H40.7472Z" fill="white"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M38.8446 49.071H84.1897H84.269V9.83008H40.3508L38.8446 49.071ZM83.4762 48.2783H39.7166L41.0643 10.6228H83.4762V48.2783Z" fill="#9E9E9E"></path><path d="M39.2408 48.6748L43.1253 64.0541H79.988L83.7932 48.6748H39.2408Z" fill="white"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M42.8083 64.4503H80.3052L84.3482 48.2783H38.7653L42.8083 64.4503ZM79.671 63.6576H43.4425L39.7958 49.0711H83.3176L79.671 63.6576Z" fill="#9E9E9E"></path><path d="M64.6088 36.1494L64.371 55.8095L69.6031 50.8152L77.6098 51.3701L64.6088 36.1494Z" fill="white"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M63.1026 59.6938L63.0233 32.7405L80.3052 53.3519L69.9202 51.7664L63.1026 59.6938ZM65.243 38.6861L65.3223 53.8275L69.1275 49.3881L74.9938 50.2602L65.243 38.6861Z" fill="black"></path><path d="M61.7549 130.724H61.3585C52.7176 130.724 45.5829 123.589 45.5829 114.948V101.709C45.5829 93.0686 52.7176 85.9338 61.3585 85.9338H61.7549C70.3958 85.9338 77.5306 93.0686 77.5306 101.709V114.948C77.5306 123.589 70.4751 130.724 61.7549 130.724Z" fill="white"></path><path fill-rule="evenodd" clip-rule="evenodd" d="M44.7902 114.79C44.7902 124.144 52.4005 131.754 61.7549 131.754C71.1093 131.754 78.7197 124.065 78.7197 114.79V101.947C78.7197 92.5928 71.1093 84.9824 61.7549 84.9824C52.4005 84.9824 44.7902 92.5928 44.7902 101.947V114.79ZM47.1684 101.868C47.1684 93.8612 53.6689 87.2814 61.7549 87.2814C69.7617 87.2814 76.3415 93.7819 76.3415 101.868V114.71C76.3415 122.717 69.8409 129.297 61.7549 129.297C53.7482 129.297 47.1684 122.796 47.1684 114.71V101.868Z" fill="#30374B"></path><path d="M61.8341 106.069C60.9621 106.069 60.2487 105.356 60.2487 104.484V100.996C60.2487 100.124 60.9621 99.4104 61.8341 99.4104C62.7062 99.4104 63.4196 100.124 63.4196 100.996V104.484C63.4196 105.356 62.7062 106.069 61.8341 106.069Z" fill="#30374B"></path><path d="M61.8341 97.7457C60.9621 97.7457 60.2487 97.0322 60.2487 96.1602C60.2487 95.2882 60.9621 94.5747 61.8341 94.5747C62.7062 94.5747 63.4196 95.2882 63.4196 96.1602C63.4196 97.0322 62.7062 97.7457 61.8341 97.7457Z" fill="#30374B"></path><path d="M61.8341 110.826C60.9621 110.826 60.2487 110.113 60.2487 109.241C60.2487 108.369 60.9621 107.655 61.8341 107.655C62.7062 107.655 63.4196 108.369 63.4196 109.241C63.4196 110.113 62.7062 110.826 61.8341 110.826Z" fill="#30374B"></path><path d="M61.8342 142.298L67.3834 136.749C67.859 136.273 68.5725 136.273 69.0481 136.749C69.5238 137.224 69.5238 137.938 69.0481 138.414L62.7062 144.756C62.4684 144.993 62.1513 145.073 61.8342 145.073C61.5171 145.073 61.2 144.993 60.9621 144.756L54.6202 138.414C54.1445 137.938 54.1445 137.224 54.6202 136.749C55.0958 136.273 55.8093 136.273 56.2849 136.749L61.8342 142.298Z" fill="#F8C62C"></path><path d="M61.8342 149.195L67.3834 143.646C67.859 143.17 68.5725 143.17 69.0481 143.646C69.5238 144.121 69.5238 144.835 69.0481 145.311L62.7062 151.653C62.4684 151.89 62.1513 151.97 61.8342 151.97C61.5171 151.97 61.2 151.89 60.9621 151.653L54.6202 145.311C54.1445 144.835 54.1445 144.121 54.6202 143.646C55.0958 143.17 55.8093 143.17 56.2849 143.646L61.8342 149.195Z" fill="#F8C62C"></path>',15)])])}const KFt=j(qFt,[["render",GFt]]),JFt={name:"FirstPersonViewHelper",components:{KeyboardNavigate:DFt,KeyboardStorey:_Ft,MouseMove:NFt,MouseStorey:zFt,MouseZoom:KFt},emits:["close"],methods:{close(){this.$emit("close")},clear(){localStorage.setItem("firstPersonViewHelper","false"),this.close()}}},ZFt={class:"bimdata-first-person-view-helper"},WFt={class:"bimdata-first-person-view-helper__header"},YFt={class:"bimdata-first-person-view-helper__content"},XFt={class:"bimdata-first-person-view-helper__content__main"},$Ft={class:"bimdata-first-person-view-helper__content__main__left"},eOt={class:"bimdata-first-person-view-helper__content__main__left__element"},tOt={class:"bimdata-first-person-view-helper__content__main__left__element__picture"},iOt={class:"bimdata-first-person-view-helper__content__main__left__element__text"},oOt={class:"bimdata-first-person-view-helper__content__main__left__element__text__tilte"},rOt={class:"bimdata-first-person-view-helper__content__main__left__element__text__list"},nOt={class:"bimdata-first-person-view-helper__content__main__left__element"},aOt={class:"bimdata-first-person-view-helper__content__main__left__element__picture"},sOt={class:"bimdata-first-person-view-helper__content__main__left__element__text"},lOt={class:"bimdata-first-person-view-helper__content__main__left__element__text__tilte"},cOt={class:"bimdata-first-person-view-helper__content__main__left__element__text__list"},dOt={class:"bimdata-first-person-view-helper__content__main__left__element"},uOt={class:"bimdata-first-person-view-helper__content__main__left__element__picture"},hOt={class:"bimdata-first-person-view-helper__content__main__left__element__text"},pOt={class:"bimdata-first-person-view-helper__content__main__left__element__text__tilte"},fOt={class:"bimdata-first-person-view-helper__content__main__left__element__text__list"},AOt={class:"bimdata-first-person-view-helper__content__main__right"},gOt={class:"bimdata-first-person-view-helper__content__main__right__title"},mOt={class:"bimdata-first-person-view-helper__content__main__right__content"},vOt={class:"bimdata-first-person-view-helper__content__main__right__content__picture"},yOt={class:"bimdata-first-person-view-helper__content__main__right__content__picture__element"},bOt={class:"bimdata-first-person-view-helper__content__main__right__content__picture__element"},wOt={class:"bimdata-first-person-view-helper__content__main__right__content__text"},COt={class:"bimdata-first-person-view-helper__content__footer"},xOt={class:"bimdata-first-person-view-helper__footer-buttons"};function kOt(t,e,i,o,n,r){const a=I("KeyboardNavigate"),s=I("MouseMove"),l=I("MouseZoom"),c=I("MouseStorey"),d=I("KeyboardStorey"),u=I("BIMDataButton");return M(),_("div",ZFt,[b("h1",WFt,z(t.$t("viewer3d.firstPersonViewHelper.title")),1),b("div",YFt,[b("div",XFt,[b("div",$Ft,[b("div",eOt,[b("div",tOt,[D(a)]),b("div",iOt,[b("h4",oOt,z(t.$t("viewer3d.firstPersonViewHelper.keyboardUsage")),1),b("ul",rOt,[b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.forward")),1),b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.backward")),1),b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.left")),1),b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.right")),1)])])]),b("div",nOt,[b("div",aOt,[D(s)]),b("div",sOt,[b("h4",lOt,z(t.$t("viewer3d.firstPersonViewHelper.mouseOrientation")),1),b("ul",cOt,[b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.pressLeft")),1),b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.mouseMove")),1),b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.mouseVertical")),1)])])]),b("div",dOt,[b("div",uOt,[D(l)]),b("div",hOt,[b("h4",pOt,z(t.$t("viewer3d.firstPersonViewHelper.mouseZoom")),1),b("ul",fOt,[b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.mouseWheelForward")),1),b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.mouseWheelBackward")),1)])])])]),b("div",AOt,[b("h4",gOt,z(t.$t("viewer3d.firstPersonViewHelper.changeStorey")),1),b("div",mOt,[b("div",vOt,[b("div",yOt,[D(c)]),b("div",bOt,[D(d)])]),b("div",wOt,[b("ul",null,[b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.storeyClick")),1),b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.moveCameraToObject")),1)]),b("ul",null,[b("li",null,z(t.$t("viewer3d.firstPersonViewHelper.keyboardStoreyChange")),1)])])])])]),b("div",COt,z(t.$t("viewer3d.firstPersonViewHelper.contentFooter")),1)]),b("div",xOt,[D(u,{color:"primary",fill:"",radius:"",width:"200px",onClick:r.close},{default:N(()=>[Je(z(t.$t("viewer3d.firstPersonViewHelper.understand")),1)]),_:1},8,["onClick"]),D(u,{color:"primary",outline:"",radius:"",width:"200px",onClick:r.clear},{default:N(()=>[Je(z(t.$t("viewer3d.firstPersonViewHelper.noRecall")),1)]),_:1},8,["onClick"])])])}const Nee=j(JFt,[["render",kOt],["__scopeId","data-v-77cce9d5"]]),MOt={components:{ShortcutsModal:zy,FirstPersonViewHelper:Nee},data(){const t=this.$t;return{tabs:[{id:0,get label(){return t("viewer3d.modals.3d")}},{id:1,get label(){return t("viewer3d.modals.firstPerson")}}],activeTab:0,elements:[{image:"shortcutRotate",title:this.$t("shortcuts-helper.title_rotate"),text:this.$t("shortcuts-helper.text_rotate")},{image:"shortcutZoom",title:this.$t("shortcuts-helper.title_zoom"),text:this.$t("shortcuts-helper.text_zoom")},{image:"shortcutOpen",title:this.$t("shortcuts-helper.title_open"),text:this.$t("shortcuts-helper.text_open")}],shortcuts:[{letter:"F",text:this.$t("context_menu.fit_view")},{letter:"C",text:this.$t("context_menu.select_all")},{letter:"V",text:this.$t("context_menu.deselect_all")},{letter:"H",text:this.$t("context_menu.hide")},{letter:"Y",text:this.$t("context_menu.select_similar")},{letter:"I",text:this.$t("context_menu.isolate")},{letter:"U",text:this.$t("context_menu.reintegrate")},{letter:"R",text:this.$t("context_menu.show_all")},{letter:"1",text:this.$t("shortcuts-helper.shortcut_1")},{letter:"2",text:this.$t("shortcuts-helper.shortcut_2")},{letter:"3",text:this.$t("shortcuts-helper.shortcut_3")},{letter:"4",text:this.$t("shortcuts-helper.shortcut_4")},{letter:"5",text:this.$t("shortcuts-helper.shortcut_5")},{letter:"6",text:this.$t("shortcuts-helper.shortcut_6")},{maj:!0,text:this.$t("shortcuts-helper.shortcut_pan"),illustration:"click"},{alt:!0,text:this.$t("shortcuts-helper.shortcut_open"),illustration:"click"},{shift:!0,text:this.$t("shortcuts-helper.shortcut_multiselect"),illustration:"click"}]}}},BOt={class:"bimdata-shortcuts-helper__header"};function EOt(t,e,i,o,n,r){const a=I("BIMDataTabs"),s=I("ShortcutsModal"),l=I("FirstPersonViewHelper");return M(),_("div",null,[b("div",BOt,[D(a,{tabs:n.tabs,width:"490px",height:"44px",tabSize:"245",onTabSelected:e[0]||(e[0]=c=>n.activeTab=n.tabs.indexOf(c)),selected:n.activeTab},null,8,["tabs","selected"])]),n.activeTab===0?(M(),J(s,{key:0,elements:n.elements,shortcuts:n.shortcuts,onClose:e[1]||(e[1]=c=>t.$emit("close"))},{title:N(()=>[Je(z(t.$t("shortcuts-helper.title_modal")),1)]),_:1},8,["elements","shortcuts"])):(M(),J(l,{key:1,onClose:e[2]||(e[2]=c=>t.$emit("close"))}))])}const POt=j(MOt,[["render",EOt],["__scopeId","data-v-a26872a0"]]),IOt="data:image/svg+xml,%3csvg%20width='44'%20height='44'%20viewBox='0%200%2044%2044'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3ccircle%20cx='22'%20cy='22'%20r='2'%20fill='%232F374A'/%3e%3cpath%20d='M1.20102%2023.5V24.5H2.20102H10.261C11.4116%2029.9278%2016.2295%2034%2022%2034C27.7705%2034%2032.5884%2029.9278%2033.739%2024.5H41.799H42.799V23.5V20.5V19.5H41.799H33.739C32.5884%2014.0722%2027.7705%2010%2022%2010C16.2295%2010%2011.4116%2014.0722%2010.261%2019.5H2.20102H1.20102V20.5V23.5ZM14.619%2022C14.619%2017.9236%2017.9236%2014.619%2022%2014.619C26.0764%2014.619%2029.381%2017.9236%2029.381%2022C29.381%2026.0764%2026.0764%2029.381%2022%2029.381C17.9236%2029.381%2014.619%2026.0764%2014.619%2022Z'%20fill='%232F374A'%20stroke='white'%20stroke-width='2'/%3e%3c/svg%3e",SOt="data:image/svg+xml,%3csvg%20width='44'%20height='44'%20viewBox='0%200%2044%2044'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3ccircle%20cx='22'%20cy='22'%20r='2'%20fill='%232F374A'/%3e%3cpath%20d='M6.23222%2034.2322L5.52512%2034.9393L6.23222%2035.6464L8.35354%2037.7678L9.06065%2038.4749L9.76776%2037.7678L15.4677%2032.0678C17.3477%2033.2898%2019.592%2034%2022%2034C24.408%2034%2026.6523%2033.2898%2028.5323%2032.0678L34.2322%2037.7678L34.9393%2038.4749L35.6464%2037.7678L37.7678%2035.6465L38.4749%2034.9393L37.7678%2034.2322L32.0678%2028.5323C33.2898%2026.6523%2034%2024.408%2034%2022C34%2019.592%2033.2898%2017.3477%2032.0678%2015.4677L37.7678%209.76776L38.4749%209.06065L37.7678%208.35354L35.6464%206.23222L34.9393%205.52512L34.2322%206.23222L28.5322%2011.9322C26.6523%2010.7102%2024.408%2010%2022%2010C19.592%2010%2017.3477%2010.7102%2015.4677%2011.9322L9.76776%206.23224L9.06065%205.52513L8.35354%206.23224L6.23222%208.35356L5.52512%209.06066L6.23222%209.76777L11.9322%2015.4678C10.7102%2017.3477%2010%2019.592%2010%2022C10%2024.408%2010.7102%2026.6523%2011.9322%2028.5323L6.23222%2034.2322ZM14.619%2022C14.619%2017.9236%2017.9236%2014.6191%2022%2014.6191C26.0764%2014.6191%2029.381%2017.9236%2029.381%2022C29.381%2026.0764%2026.0764%2029.381%2022%2029.381C17.9236%2029.381%2014.619%2026.0764%2014.619%2022Z'%20fill='%232F374A'%20stroke='white'%20stroke-width='2'/%3e%3c/svg%3e",TOt="data:image/svg+xml,%3csvg%20width='44'%20height='44'%20viewBox='0%200%2044%2044'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3ccircle%20cx='22'%20cy='22'%20r='2'%20fill='%232F374A'/%3e%3cpath%20d='M14.619%2022C14.619%2017.9236%2017.9236%2014.619%2022%2014.619C26.0764%2014.619%2029.381%2017.9236%2029.381%2022C29.381%2026.0764%2026.0764%2029.381%2022%2029.381C17.9236%2029.381%2014.619%2026.0764%2014.619%2022ZM22%2010C15.3726%2010%2010%2015.3726%2010%2022C10%2028.6274%2015.3726%2034%2022%2034C28.6274%2034%2034%2028.6274%2034%2022C34%2015.3726%2028.6274%2010%2022%2010Z'%20fill='%232F374A'%20stroke='white'%20stroke-width='2'/%3e%3c/svg%3e",DOt="data:image/svg+xml,%3csvg%20width='44'%20height='44'%20viewBox='0%200%2044%2044'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M14.619%2022C14.619%2017.9236%2017.9236%2014.619%2022%2014.619C23.8642%2014.619%2025.5667%2015.3094%2026.8665%2016.4504L14.7593%2023.4405C14.6673%2022.9751%2014.619%2022.4935%2014.619%2022ZM29.381%2022C29.381%2026.0764%2026.0764%2029.381%2022%2029.381C20.0879%2029.381%2018.3459%2028.6547%2017.0341%2027.4608L29.2136%2020.4289C29.3232%2020.9347%2029.381%2021.4602%2029.381%2022ZM22%2010C15.3726%2010%2010%2015.3726%2010%2022C10%2028.6274%2015.3726%2034%2022%2034C28.6274%2034%2034%2028.6274%2034%2022C34%2015.3726%2028.6274%2010%2022%2010Z'%20fill='%232F374A'%20stroke='white'%20stroke-width='2'/%3e%3c/svg%3e",ROt="data:image/svg+xml,%3csvg%20width='33'%20height='33'%20viewBox='0%200%2033%2033'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M1.70001%2016.8667V17.3667H2.20001H7.33335H7.83335V16.8667V16.1333V15.6333H7.33335L2.20001%2015.6333H1.70001V16.1333L1.70001%2016.8667ZM30.8%2017.3667H31.3V16.8667V16.1333V15.6333H30.8L25.6667%2015.6333H25.1667V16.1333V16.8667V17.3667H25.6667H30.8Z'%20fill='%232F374A'%20stroke='white'/%3e%3cpath%20d='M16.1333%201.70001L15.6333%201.70001L15.6333%202.20001L15.6333%207.33335L15.6333%207.83335L16.1333%207.83335L16.8667%207.83335L17.3667%207.83335L17.3667%207.33335L17.3667%202.20001L17.3667%201.70001L16.8667%201.70001L16.1333%201.70001ZM15.6333%2030.8L15.6333%2031.3L16.1333%2031.3L16.8667%2031.3L17.3667%2031.3L17.3667%2030.8L17.3667%2025.6667L17.3667%2025.1667L16.8667%2025.1667L16.1333%2025.1667L15.6333%2025.1667L15.6333%2025.6667L15.6333%2030.8Z'%20fill='%232F374A'%20stroke='white'/%3e%3c/svg%3e",LOt={0:{positions:[36.5625,31.640625,36.5625,19.51171875,36.42067337036133,16.11605453491211,35.99519348144531,13.020120620727539,35.28605651855469,10.223917961120605,34.293270111083984,7.727446556091309,33.01683044433594,5.530706882476807,30.959993362426758,3.3593661785125732,28.725576400756836,1.6479235887527466,26.31357765197754,.39637935161590576,23.723995208740234,-.39526674151420593,20.956830978393555,-.7270146012306213,20.3203125,-.73828125,17.307449340820312,-.5108020901679993,14.569392204284668,.17163534462451935,12.106142044067383,1.3090311288833618,9.917699813842773,2.9013850688934326,8.174575805664062,5.153988838195801,6.733142375946045,7.555612087249756,5.593398094177246,10.106253623962402,4.755343437194824,12.805914878845215,4.218978404998779,15.654594421386719,3.9843032360076904,18.652292251586914,3.97265625,19.51171875,3.97265625,31.640625,4.115384578704834,35.0230827331543,4.543569564819336,38.11090850830078,5.257210731506348,40.904109954833984,6.256308555603027,43.40268325805664,7.540863037109375,45.606624603271484,9.608292579650879,47.79111099243164,11.846480369567871,49.51402282714844,14.255425453186035,50.775352478027344,16.835128784179688,51.57510757446289,19.585588455200195,51.91328811645508,20.25,51.92578125,23.26165771484375,51.697608947753906,25.997068405151367,51.013092041015625,28.456228256225586,49.872230529785156,30.639141082763672,48.2750244140625,32.375572204589844,46.0158576965332,33.81153869628906,43.60895538330078,34.947044372558594,41.0543212890625,35.78208923339844,38.35194778442383,36.31666946411133,35.5018424987793,36.55078887939453,32.50400161743164,36.5625,31.640625,29.63671875,18.10546875,29.63671875,33.1171875,29.450082778930664,36.561954498291016,28.89017677307129,39.497215270996094,27.956998825073242,41.92298126220703,25.967069625854492,44.22639083862305,23.724157333374023,45.72625732421875,21.228260040283203,46.422576904296875,20.25,46.4765625,17.354780197143555,46.07659912109375,14.97888469696045,44.876708984375,13.33356761932373,42.470394134521484,12.110569953918457,39.9057731628418,11.309891700744629,37.1828498840332,10.931534767150879,34.30161666870117,10.8984375,33.1171875,10.8984375,18.10546875,11.085087776184082,14.669450759887695,11.645040512084961,11.733874320983887,12.578293800354004,9.298736572265625,14.569818496704102,6.974865436553955,16.804428100585938,5.454482555389404,19.282119750976562,4.737586975097656,20.3203125,4.67578125,23.212167739868164,5.077450752258301,25.581016540527344,6.282459735870361,27.21183204650879,8.69408893585205,28.425546646118164,11.263723373413086,29.2221622467041,13.991360664367676,29.6016788482666,16.877002716064453],indices:[0,2,1,2,4,3,4,6,5,6,8,7,8,10,9,10,12,11,12,14,13,14,16,15,16,18,17,18,20,19,20,22,21,22,24,23,24,63,62,61,24,62,24,26,25,26,28,27,28,30,29,30,32,31,32,34,33,34,36,35,36,38,37,38,40,39,40,42,41,42,44,43,44,0,45,0,4,2,4,8,6,8,12,10,12,16,14,16,20,18,20,24,22,24,64,63,60,24,61,24,28,26,28,32,30,32,36,34,36,40,38,40,44,42,44,4,0,4,12,8,12,20,16,20,64,24,59,24,60,24,32,28,32,40,36,40,4,44,20,65,64,58,24,59,20,66,65,57,24,58,12,66,20,57,32,24,12,67,66,56,32,57,12,68,67,55,32,56,12,69,68,54,32,55,12,70,69,53,32,54,12,71,70,53,40,32,4,71,12,52,40,53,4,72,71,51,40,52,4,73,72,50,40,51,4,74,73,49,40,50,4,75,74,48,40,49,4,76,75,47,40,48,40,76,4,76,40,47],width:32.58984375},1:{positions:[23.94140625,51.1875,23.94140625,0,17.015625,0,17.015625,44.4375,6.5390625,44.296875,6.5390625,49.2890625],indices:[0,2,1,3,5,4,0,3,2,3,0,5],width:17.40234375},2:{positions:[37.3359375,5.4140625,37.3359375,0,4.1484375,0,4.1484375,4.74609375,20.91796875,23.37890625,23.33412742614746,26.180971145629883,25.239078521728516,28.61744499206543,26.632823944091797,30.68832778930664,27.938528060913086,33.606327056884766,28.560094833374023,36.34145736694336,28.6171875,37.40625,28.23740577697754,40.36100769042969,27.09806251525879,42.90309143066406,24.87748908996582,45.0150146484375,22.4631290435791,46.19827651977539,20.4609375,46.4765625,17.237478256225586,46.17487716674805,14.632962226867676,45.26981735229492,12.647390365600586,43.76138687133789,11.200069427490234,41.599464416503906,10.360716819763184,38.91020965576172,10.125,36.10546875,3.48046875,36.10546875,3.41015625,36.31640625,3.580944538116455,39.24900436401367,4.255249977111816,41.95781326293945,5.433072566986084,44.442840576171875,7.114412784576416,46.704078674316406,9.256887435913086,48.52997589111328,11.61109447479248,49.96455383300781,14.177034378051758,51.007816314697266,16.954708099365234,51.659759521484375,19.944114685058594,51.920387268066406,20.4609375,51.92578125,23.575925827026367,51.698787689208984,26.37569808959961,51.01780319213867,28.86025619506836,49.88283157348633,31.029598236083984,48.29386901855469,32.93091583251953,46.07616424560547,34.31552505493164,43.65195846557617,35.18342971801758,41.0212516784668,35.53462600708008,38.18403625488281,35.54296875,37.65234375,35.271297454833984,34.8802490234375,34.45627975463867,32.10430145263672,33.097923278808594,29.324501037597656,31.655981063842773,27.067161560058594,29.948768615722656,24.73398208618164,27.976285934448242,22.324962615966797,26.12109375,20.25,12.65625,5.58984375,12.7265625,5.4140625],indices:[51,1,0,1,3,2,20,22,21,22,24,23,24,26,25,26,28,27,28,30,29,30,32,31,32,34,33,34,36,35,36,38,37,38,40,39,40,42,41,42,44,43,44,46,45,46,48,47,48,50,49,51,3,1,19,22,20,22,26,24,26,30,28,30,34,32,34,38,36,38,42,40,42,46,44,46,50,48,50,3,51,18,22,19,22,30,26,30,38,34,38,46,42,46,3,50,18,30,22,46,4,3,17,30,18,46,5,4,16,30,17,46,6,5,15,30,16,46,7,6,14,30,15,46,8,7,13,30,14,38,8,46,13,38,30,38,9,8,12,38,13,38,10,9,11,38,12,38,11,10],width:33.92578125},3:{positions:[13.640625,23.37890625,13.640625,28.79296875,19.6875,28.79296875,22.903934478759766,29.15167236328125,25.282482147216797,30.227783203125,26.954715728759766,32.621280670166016,27.896883010864258,35.25688171386719,28.125,37.51171875,27.781084060668945,40.67007064819336,26.749338150024414,43.162776947021484,24.544097900390625,45.051876068115234,22.03769302368164,46.1552734375,19.51171875,46.4765625,16.51466941833496,46.0916633605957,14.03652286529541,44.93696212768555,12.056009292602539,42.62509536743164,10.906388282775879,40.13740539550781,10.58203125,37.79296875,3.9375,37.79296875,3.8671875,38.00390625,4.073190689086914,40.847023010253906,4.870357036590576,43.464176177978516,6.258687496185303,45.85536193847656,8.649903297424316,47.949581146240234,11.105090141296387,49.6024169921875,13.624245643615723,50.81385803222656,16.207372665405273,51.58391189575195,18.854469299316406,51.912574768066406,19.51171875,51.92578125,22.69034194946289,51.71705627441406,25.550539016723633,51.090885162353516,28.09231185913086,50.04726028442383,30.315656661987305,48.58618927001953,32.206153869628906,46.54783248901367,33.6175651550293,44.22849655151367,34.54988479614258,41.62818145751953,35.00312423706055,38.74688720703125,35.05078125,37.37109375,34.68306350708008,34.60222244262695,33.579917907714844,31.84009552001953,31.788928985595703,29.416330337524414,29.652488708496094,27.526569366455078,27.38671875,26.26171875,30.2706241607666,24.998523712158203,32.5009765625,23.31671142578125,34.190120697021484,20.399517059326172,35.28596115112305,17.665790557861328,35.78849792480469,15.115530967712402,35.82421875,14.2734375,35.583168029785156,11.223187446594238,34.860015869140625,8.486950874328613,33.65475845336914,6.064727306365967,31.9674015045166,3.9565165042877197,29.64410972595215,2.185784339904785,27.159265518188477,.8323085308074951,24.512863159179688,-.10391119122505188,21.704906463623047,-.6228747963905334,19.51171875,-.73828125,16.397254943847656,-.535150945186615,13.541664123535156,.07424008101224899,10.9449462890625,1.089891791343689,8.607102394104004,2.5118041038513184,6.504549980163574,4.569301605224609,4.957869052886963,6.847413539886475,3.9670591354370117,9.34614086151123,3.5321204662323,12.065483093261719,3.515625,13.2890625,3.62109375,13.5,10.23046875,13.5,10.628458976745605,10.52513313293457,11.822431564331055,8.080921173095703,14.14232063293457,6.207763671875,16.670166015625,5.072887420654297,19.405969619750977,4.6762919425964355,19.51171875,4.67578125,22.593053817749023,5.02486515045166,25.119962692260742,6.072116374969482,27.08766746520996,8.277663230895996,28.33972930908203,10.727699279785156,28.876150131225586,13.422224998474121,28.8984375,14.1328125,28.579307556152344,17.37627601623535,27.621917724609375,19.90043067932129,25.462261199951172,21.754257202148438,22.976253509521484,22.91082000732422,20.163896560668945,23.3701229095459,19.6875,23.37890625],indices:[86,1,0,16,18,17,18,20,19,20,22,21,22,24,23,24,26,25,26,28,27,28,30,29,30,32,31,32,34,33,34,36,35,36,38,37,38,40,39,40,42,41,42,44,43,44,46,45,46,48,47,48,50,49,50,52,51,52,54,53,54,56,55,56,58,57,58,60,59,60,62,61,62,64,63,64,66,65,66,68,67,85,1,86,15,18,16,18,22,20,22,26,24,26,30,28,30,34,32,34,38,36,38,42,40,42,46,44,46,50,48,50,54,52,54,58,56,58,62,60,62,66,64,66,69,68,84,1,85,14,18,15,18,26,22,26,34,30,34,42,38,42,50,46,50,58,54,58,66,62,66,70,69,83,1,84,14,26,18,58,70,66,83,2,1,13,26,14,58,71,70,82,2,83,12,26,13,58,72,71,82,3,2,11,26,12,58,73,72,82,4,3,10,26,11,58,74,73,81,4,82,10,34,26,58,75,74,9,34,10,50,75,58,8,34,9,50,76,75,7,34,8,50,77,76,6,34,7,50,78,77,5,34,6,50,79,78,5,42,34,50,80,79,4,42,5,50,81,80,81,42,4,42,81,50],width:32.30859375},4:{positions:[31.81640625,51.1875,31.81640625,17.2265625,38.8828125,17.2265625,38.8828125,11.8125,31.81640625,11.8125,31.81640625,0,24.92578125,0,24.92578125,11.8125,1.93359375,11.8125,1.93359375,15.71484375,24.50390625,51.1875,31.81640625,51.1875,24.046875,39.515625,9.31640625,17.2265625,24.92578125,17.2265625,24.92578125,41.23828125,24.71484375,41.2734375],indices:[1,3,2,4,6,5,7,9,8,9,14,13,16,13,12,13,10,9,10,1,0,1,4,3,4,7,6,7,14,9,16,10,13,10,4,1,4,14,7,15,10,16,4,15,14,15,4,10],width:36.94921875},5:{positions:[11.91796875,22.5,6.15234375,23.09765625,9.10546875,51.1875,34.734375,51.1875,34.734375,45.03515625,14.9765625,45.03515625,13.2890625,30.65625,14.99853515625,31.75048828125,16.892578125,32.642578125,19.03271484375,33.25341796875,21.48046875,33.50390625,21.48046875,33.50390625,24.524171829223633,33.29277038574219,27.260135650634766,32.595733642578125,29.6883602142334,31.412792205810547,31.808847427368164,29.743946075439453,33.53106689453125,27.481525421142578,34.8779411315918,25.034576416015625,35.84947204589844,22.40309715270996,36.44565963745117,19.58709144592285,36.66650390625,16.586557388305664,36.66796875,16.3125,36.47660446166992,13.1383056640625,35.90251541137695,10.244234085083008,34.94569778442383,7.630287170410156,33.60615158081055,5.296463966369629,31.54420280456543,3.2312631607055664,29.28870391845703,1.597025990486145,26.839656829833984,.3937528729438782,24.197057723999023,-.3785564601421356,21.360912322998047,-.7199019193649292,20.49609375,-.73828125,17.404800415039062,-.5199803113937378,14.58151912689209,.13492262363433838,12.026251792907715,1.226427435874939,9.738997459411621,2.7545342445373535,7.902623653411865,4.662389278411865,6.586172580718994,6.943535327911377,5.78964376449585,9.59797191619873,5.513038158416748,12.625699043273926,5.51953125,13.25390625,5.58984375,13.46484375,11.84765625,13.46484375,12.231374740600586,10.424592018127441,13.382529258728027,7.983725547790527,15.769926071166992,6.059262275695801,18.29474449157715,4.960567474365234,20.49609375,4.67578125,23.407373428344727,5.077446937561035,25.80744171142578,6.282444000244141,27.603513717651367,8.744783401489258,28.85628890991211,11.317317962646484,29.565767288208008,14.000046730041504,29.7421875,16.2421875,29.464466094970703,19.35067367553711,28.631298065185547,22.06241226196289,26.50613021850586,24.628503799438477,24.30402374267578,26.380647659301758,22.024982452392578,27.31884002685547,20.49609375,27.4921875,17.11406707763672,27.2115478515625,14.758378028869629,26.369632720947266,13.049945831298828,24.7330322265625],indices:[2,4,3,6,8,7,12,14,13,14,16,15,16,18,17,18,20,19,20,22,21,22,24,23,24,26,25,26,28,27,28,30,29,30,32,31,32,34,33,34,36,35,36,38,37,38,40,39,40,42,41,2,5,4,6,9,8,12,16,14,16,20,18,20,24,22,24,28,26,28,32,30,32,36,34,36,40,38,40,43,42,1,5,2,12,20,16,20,28,24,28,36,32,36,43,40,1,6,5,36,44,43,1,9,6,36,45,44,28,45,36,28,46,45,28,47,46,28,48,47,28,49,48,20,49,28,20,50,49,20,51,50,20,52,51,20,53,52,20,54,53,20,55,54,12,55,20,12,56,55,12,57,56,12,58,57,12,59,58,12,60,59,12,61,60,1,11,9,11,61,12,62,1,0,1,61,11,61,1,62],width:31.154930591583252},6:{positions:[23.73046875,51.92578125,23.73046875,51.92578125,26.35400390625,51.7763671875,28.951171875,51.328125,31.31103515625,50.6513671875,33.22265625,49.81640625,33.22265625,49.81640625,31.74609375,44.5078125,29.98388671875,45.30322265625,28.142578125,45.931640625,26.09912109375,46.34033203125,23.73046875,46.4765625,23.73046875,46.4765625,20.900758743286133,46.15056610107422,18.386611938476562,45.17258071899414,16.18802833557129,43.5426025390625,14.465424537658691,41.076210021972656,13.138894081115723,38.50679397583008,12.208439826965332,35.8343505859375,11.67405891418457,33.05888366699219,11.53125,30.62109375,11.53125,29.8125,13.904020309448242,31.542055130004883,16.591995239257812,32.85417938232422,19.408527374267578,33.66147994995117,22.372249603271484,33.98829650878906,22.921875,33.99609375,25.913307189941406,33.7476806640625,28.614002227783203,33.002437591552734,31.023962020874023,31.7603702545166,33.143184661865234,30.021472930908203,34.91127014160156,27.67707633972168,36.273963928222656,25.183759689331055,37.23126983642578,22.541519165039062,37.783180236816406,19.750356674194336,37.93359375,17.2265625,37.749637603759766,14.08007526397705,37.19777297973633,11.182336807250977,36.27799606323242,8.533347129821777,34.99031066894531,6.1331071853637695,32.81218719482422,3.8232548236846924,30.5310001373291,1.9849358797073364,28.146751403808594,.6181499361991882,25.65943717956543,-.2771027684211731,23.069063186645508,-.7008222937583923,22.0078125,-.73828125,19.07733154296875,-.5163767337799072,16.358732223510742,.14933684468269348,13.852017402648926,1.2588595151901245,11.557185173034668,2.8121912479400635,9.638298988342285,5.0737128257751465,8.030496597290039,7.450648784637451,6.733777046203613,9.942998886108398,5.748140335083008,12.550763130187988,5.073586463928223,15.273941993713379,4.710115432739258,18.112533569335938,4.640625,20.07421875,4.640625,29.84765625,4.791966915130615,33.015262603759766,5.245992183685303,35.97719955444336,6.0027008056640625,38.73346710205078,7.062093257904053,41.28406524658203,8.424168586730957,43.62899398803711,10.08892822265625,45.768253326416016,12.196839332580566,47.81597900390625,14.478988647460938,49.4511604309082,16.93537712097168,50.673797607421875,19.56600570678711,51.483890533447266,22.370872497558594,51.881439208984375,21.375,28.828125,21.375,28.828125,18.29266357421875,28.514667510986328,15.669046401977539,27.57429313659668,13.216089248657227,25.754901885986328,11.53125,23.5546875,11.53125,23.5546875,11.53125,19.40625,11.72034740447998,16.05575180053711,12.287637710571289,13.114592552185059,13.233122825622559,10.582772254943848,15.422850608825684,7.959404945373535,17.641748428344727,6.1007585525512695,19.889812469482422,5.006833076477051,22.0078125,4.67578125,24.755970001220703,5.117502212524414,27.043012619018555,6.4426655769348145,28.768321990966797,9.139809608459473,30.00419807434082,11.825053215026855,30.75064468383789,14.498397827148438,31.007658004760742,17.15984344482422,31.0078125,17.2265625,30.737268447875977,20.334959030151367,29.925634384155273,23.062726974487305,28.57291030883789,25.409866333007812,26.557069778442383,27.331403732299805,24.112672805786133,28.470571517944336],indices:[2,4,3,21,23,22,23,25,24,25,27,26,27,29,28,29,31,30,31,33,32,33,35,34,35,37,36,37,39,38,39,41,40,41,43,42,43,45,44,45,47,46,47,49,48,49,51,50,51,53,52,53,55,54,55,57,56,57,59,58,59,61,60,61,63,62,63,65,64,65,67,66,21,25,23,25,29,27,29,33,31,33,37,35,37,41,39,41,45,43,45,49,47,49,53,51,53,57,55,57,61,59,61,65,63,65,68,67,21,29,25,29,37,33,37,45,41,45,53,49,57,65,61,57,68,65,73,57,74,68,2,1,2,6,4,6,8,7,53,75,57,72,57,73,68,6,2,6,9,8,53,76,75,71,57,72,68,9,6,53,77,76,70,57,71,68,10,9,53,78,77,68,12,10,53,79,78,68,13,12,45,79,53,68,14,13,45,80,79,68,15,14,45,81,80,57,15,68,45,82,81,57,16,15,45,83,82,57,17,16,45,84,83,57,18,17,37,84,45,57,19,18,37,85,84,57,20,19,37,86,85,57,21,20,37,87,86,70,21,57,37,88,87,70,29,21,37,89,88,95,29,70,37,90,89,94,29,95,29,90,37,93,29,94,29,91,90,92,29,93,29,92,91],width:33.29296875},7:{positions:[37.3359375,51.1875,37.3359375,45.73828125,35.06884002685547,42.96620559692383,32.99747848510742,40.27573776245117,31.121856689453125,37.666873931884766,29.441970825195312,35.13961410522461,27.957822799682617,32.6939582824707,26.669410705566406,30.329906463623047,25.576738357543945,28.047460556030273,24.585519790649414,25.34857940673828,23.679515838623047,22.592660903930664,22.85872459411621,19.779708862304688,22.123149871826172,16.909719467163086,21.47278594970703,13.982696533203125,20.907638549804688,10.998638153076172,20.427703857421875,7.957544803619385,20.109375,5.51953125,19.546875,0,12.62109375,0,13.18359375,5.51953125,13.624162673950195,8.682632446289062,14.162458419799805,11.7554292678833,14.798481941223145,14.737921714782715,15.532232284545898,17.630107879638672,16.363710403442383,20.431991577148438,17.29291534423828,23.14356803894043,18.319847106933594,25.764841079711914,19.59184455871582,28.50404167175293,20.94556999206543,31.184146881103516,22.381019592285156,33.80515670776367,23.898197174072266,36.367069244384766,25.497098922729492,38.86988830566406,27.17772674560547,41.31361389160156,28.940080642700195,43.6982421875,30.55078125,45.73828125,2.70703125,45.73828125,2.70703125,51.1875],indices:[36,1,0,16,18,17,18,20,19,20,22,21,22,24,23,24,26,25,26,28,27,28,30,29,30,32,31,32,34,33,34,36,35,15,18,16,18,22,20,22,26,24,26,30,28,30,34,32,34,1,36,14,18,15,18,26,22,26,34,30,34,2,1,13,18,14,18,34,26,34,3,2,12,18,13,34,4,3,11,18,12,34,5,4,10,18,11,34,6,5,9,18,10,34,7,6,8,18,9,34,8,7,8,34,18],width:34.62890625},8:{positions:[35.5078125,37.828125,35.5078125,37.828125,35.171749114990234,34.87995147705078,34.16355895996094,32.23108673095703,32.111854553222656,29.74087905883789,29.926387786865234,27.833354949951172,27.60715675354004,26.50851058959961,27.17578125,26.33203125,29.95149040222168,25.094419479370117,32.32651901245117,23.460092544555664,34.43555450439453,20.72713279724121,35.900413513183594,18.128986358642578,36.721099853515625,15.665656089782715,36.9140625,13.8515625,36.669769287109375,10.764041900634766,35.936893463134766,8.031349182128906,34.71543502807617,5.653482913970947,33.00539016723633,3.630444288253784,30.672534942626953,1.9876797199249268,28.159135818481445,.7305349111557007,25.465194702148438,-.14099019765853882,22.590709686279297,-.6268956065177917,20.28515625,-.73828125,17.073928833007812,-.5518752932548523,14.154998779296875,.007342617027461529,11.52836799621582,.9393724799156189,9.194035530090332,2.2442142963409424,7.087226867675781,4.249664306640625,5.474374294281006,6.483748912811279,4.355478763580322,8.946466445922852,3.730539560317993,11.637818336486816,3.5859375,13.8515625,3.9077277183532715,16.76708984375,4.873098373413086,19.430402755737305,6.983664512634277,21.999971389770508,9.1663179397583,24.03520965576172,11.421058654785156,25.536113739013672,13.21875,26.33203125,10.521642684936523,27.690086364746094,8.310940742492676,29.498327255249023,6.554880142211914,32.2148551940918,5.462681293487549,34.86786651611328,5.034343719482422,37.45735549926758,5.02734375,37.828125,5.274991512298584,40.936737060546875,6.0179338455200195,43.679622650146484,7.256171703338623,46.056785583496094,8.989704132080078,48.0682258605957,11.195730209350586,49.67716598510742,13.679861068725586,50.85453796386719,16.442096710205078,51.60033416748047,19.482437133789062,51.914554595947266,20.21484375,51.92578125,23.33972930908203,51.71018600463867,26.17371940612793,51.06340789794922,28.716812133789062,49.98543930053711,30.96900749206543,48.476287841796875,32.855812072753906,46.481101989746094,34.23870849609375,44.16929626464844,35.11769485473633,41.54087829589844,35.49277114868164,38.5958366394043,30.0234375,13.9921875,30.0234375,13.9921875,29.64218521118164,16.91078758239746,28.498428344726562,19.414352416992188,26.08045768737793,21.54735565185547,23.622779846191406,22.934738159179688,21.125396728515625,23.576496124267578,20.21484375,23.625,17.24955177307129,23.25731658935547,14.728343963623047,22.15427017211914,12.576437950134277,19.76153564453125,11.184748649597168,17.31914710998535,10.553275108337402,14.827102661132812,10.51171875,13.9921875,10.887092590332031,10.988458633422852,12.013215065002441,8.51321792602539,14.405669212341309,6.533318519592285,16.906885147094727,5.263905048370361,19.516860961914062,4.704977512359619,20.28515625,4.67578125,23.29867172241211,5.026233196258545,25.858081817626953,6.077588081359863,28.013742446899414,8.338984489440918,29.392438888549805,10.737264633178711,29.994173049926758,13.27242660522461,28.58203125,37.6875,28.58203125,37.6875,28.174694061279297,40.610374450683594,26.952680587768555,43.08668899536133,24.61227035522461,45.108375549316406,22.137697219848633,46.228328704833984,20.21484375,46.4765625,17.313322067260742,46.03565979003906,14.926724433898926,44.71294403076172,13.154691696166992,42.36640930175781,12.172061920166016,39.77567672729492,11.953125,37.6875,12.353304862976074,34.70274353027344,13.553845405578613,32.25563430786133,15.877814292907715,30.335918426513672,18.399682998657227,29.288454055786133,20.28515625,29.07421875,23.187891006469727,29.511512756347656,25.59459114074707,30.82339859008789,27.39614486694336,33.1435661315918,28.379940032958984,35.7212028503418],indices:[96,43,97,43,45,44,45,47,46,47,49,48,49,51,50,51,53,52,53,55,54,55,57,56,57,59,58,59,1,60,1,3,2,3,5,4,5,7,6,7,9,8,9,11,10,11,13,12,13,15,14,15,17,16,17,19,18,19,21,20,21,23,22,23,25,24,25,27,26,27,29,28,29,31,30,31,75,74,73,31,74,31,33,32,33,35,34,35,37,36,37,39,38,39,41,40,41,43,42,43,98,97,95,43,96,43,47,45,47,51,49,51,55,53,55,59,57,59,3,1,3,7,5,7,11,9,11,15,13,15,19,17,19,23,21,23,27,25,27,31,29,31,76,75,72,31,73,31,35,33,37,41,39,41,98,43,94,43,95,43,51,47,51,59,55,59,7,3,7,15,11,15,23,19,23,31,27,31,77,76,71,31,72,31,37,35,37,98,41,94,51,43,23,77,31,70,31,71,37,99,98,93,51,94,23,78,77,70,37,31,37,100,99,92,51,93,23,79,78,69,37,70,37,101,100,91,51,92,23,80,79,68,37,69,37,102,101,90,51,91,23,81,80,67,37,68,37,103,102,89,51,90,15,81,23,66,37,67,89,59,51,15,82,81,66,103,37,88,59,89,15,83,82,65,103,66,87,59,88,15,84,83,64,103,65,106,59,87,15,85,84,64,104,103,105,59,106,15,62,85,63,104,64,104,59,105,15,63,62,104,7,59,7,63,15,63,7,104],width:33.328125},9:{positions:[17.96484375,4.67578125,17.96484375,4.67578125,20.832611083984375,5.023819923400879,23.333181381225586,6.067935943603516,25.466554641723633,7.80812931060791,26.91764259338379,9.993691444396973,28.0020751953125,12.483912467956543,28.7198543548584,15.278792381286621,29.070980072021484,18.378332138061523,29.109375,19.8984375,29.109375,22.21875,27.17138671875,20.02587890625,24.802734375,18.439453125,22.097061157226562,17.482282638549805,19.10603904724121,17.156333923339844,19.0546875,17.15625,15.962648391723633,17.374753952026367,13.161947250366211,18.030263900756836,10.65258502960205,19.12278175354004,8.43455982208252,20.652305603027344,6.556478023529053,22.870075225830078,5.067807197570801,25.25521469116211,3.968548536300659,27.80772590637207,3.2587015628814697,30.527606964111328,2.9382660388946533,33.414859771728516,2.91796875,34.3828125,3.1171858310699463,37.45964050292969,3.7148373126983643,40.29710006713867,4.710922718048096,42.89520263671875,6.105442523956299,45.253936767578125,8.45276927947998,47.5704231262207,10.840720176696777,49.39479446411133,13.269293785095215,50.72705078125,15.738492012023926,51.56719207763672,18.248313903808594,51.915218353271484,18.7734375,51.92578125,21.87710189819336,51.72084045410156,24.703197479248047,51.10601806640625,27.25172233581543,50.0813102722168,29.52267837524414,48.646724700927734,31.40683364868164,46.456634521484375,32.97002410888672,44.11880111694336,34.212249755859375,41.63322067260742,35.133514404296875,38.99989700317383,35.73381423950195,36.21882629394531,36.01314926147461,33.29001235961914,36.03515625,32.16796875,36.03515625,19.96875,35.885276794433594,16.642547607421875,35.435638427734375,13.59611988067627,34.686241149902344,10.8294677734375,33.6370849609375,8.34259033203125,32.28816604614258,6.135488033294678,30.066654205322266,3.964623212814331,27.738887786865234,2.2044835090637207,25.30486488342285,.8550683259963989,22.764589309692383,-.08362190425395966,20.118059158325195,-.6115872859954834,17.96484375,-.73828125,15.23583984375,-.61083984375,12.462890625,-.228515625,9.81298828125,.41748046875,7.453125,1.3359375,7.453125,1.3359375,8.5078125,6.64453125,10.62158203125,5.71728515625,12.814453125,5.115234375,15.21826171875,4.78564453125,17.96484375,4.67578125,19.0546875,22.5703125,19.0546875,22.5703125,22.15691566467285,22.88543701171875,24.769695281982422,23.830808639526367,27.256725311279297,25.793380737304688,28.883312225341797,27.970977783203125,29.109375,28.44140625,29.109375,32.87109375,28.917926788330078,36.28435516357422,28.34358024597168,39.213134765625,27.386337280273438,41.657432556152344,25.37175941467285,43.94849395751953,23.127288818359375,45.50687026977539,20.652921676635742,46.33256530761719,18.984375,46.4765625,16.33090591430664,46.012935638427734,13.984920501708984,44.62206268310547,12.139910697937012,42.07911682128906,10.835031509399414,39.48687744140625,10.070281982421875,36.84534454345703,9.84375,34.3828125,10.09748363494873,31.21339988708496,10.858684539794922,28.454280853271484,12.127352714538574,26.105453491210938,14.162574768066406,24.085222244262695,16.57485580444336,22.90838050842285],indices:[60,63,61,63,65,64,10,12,11,12,14,13,14,16,15,16,18,17,18,20,19,20,22,21,22,24,23,24,89,25,88,25,89,25,27,26,27,29,28,29,31,30,31,33,32,33,35,34,35,37,36,37,39,38,39,41,40,41,43,42,43,45,44,45,47,46,47,49,48,49,51,50,51,53,52,53,55,54,55,57,56,57,59,58,59,63,60,63,66,65,10,14,12,14,18,16,18,22,20,22,89,24,87,25,88,25,29,27,29,33,31,33,37,35,37,41,39,41,45,43,45,49,47,49,53,51,53,57,55,57,63,59,63,67,66,10,18,14,18,89,22,86,25,87,25,33,29,33,41,37,41,49,45,49,57,53,57,67,63,18,90,89,85,25,86,57,1,67,18,91,90,85,33,25,57,2,1,18,92,91,84,33,85,57,3,2,18,93,92,83,33,84,49,3,57,18,94,93,82,33,83,49,4,3,18,70,94,81,33,82,49,5,4,10,70,18,80,33,81,49,6,5,10,71,70,80,41,33,49,7,6,10,72,71,79,41,80,41,7,49,10,73,72,78,41,79,41,8,7,10,74,73,77,41,78,41,9,8,10,75,74,76,41,77,41,10,9,75,41,76,41,75,10],width:33.1171875},".":{positions:[12.5859375,7.1015625,12.5859375,0,5.66015625,0,5.66015625,7.1015625],indices:[3,1,0,1,3,2],width:6.92578125},m:{positions:[5.02734375,38.0390625,11.21484375,38.0390625,11.70703125,33.046875,13.634581565856934,35.28191375732422,15.986680030822754,37.00302505493164,18.700471878051758,38.111698150634766,21.567134857177734,38.6696662902832,23.09765625,38.7421875,26.139192581176758,38.42292022705078,28.791221618652344,37.465118408203125,31.15591812133789,35.599586486816406,32.90284729003906,33.37240219116211,33.71484375,31.7109375,35.408084869384766,34.171592712402344,37.503177642822266,36.16951370239258,40.22900390625,37.6488037109375,42.961280822753906,38.50468063354492,45.3515625,38.7421875,48.32835006713867,38.446842193603516,50.9460334777832,37.5608024597168,53.204620361328125,36.084068298339844,54.8843879699707,33.86517333984375,56.19401931762695,31.434070587158203,57.133506774902344,28.79076385498047,57.70286178588867,25.93524932861328,57.90207290649414,22.867528915405273,57.90234375,22.74609375,57.90234375,0,50.9765625,0,50.9765625,22.81640625,50.74445724487305,26.319555282592773,50.04814529418945,29.033550262451172,47.956382751464844,31.33014678955078,45.659942626953125,32.691036224365234,43.27734375,33.1171875,40.4267463684082,32.6451530456543,38.09538650512695,31.229045867919922,36.33670425415039,28.815231323242188,35.26606750488281,26.190664291381836,34.9453125,24.43359375,34.9453125,24.15234375,34.9453125,0,27.984375,0,27.984375,22.81640625,27.73810386657715,26.2243709564209,26.99928855895996,28.921852111816406,24.89556121826172,31.278352737426758,22.623031616210938,32.67652893066406,20.28515625,33.1171875,17.40234375,32.7919921875,15.08203125,31.81640625,13.2802734375,30.251953125,11.953125,28.16015625,11.953125,28.16015625,11.953125,0,5.02734375,0],indices:[55,1,0,2,4,3,4,6,5,6,8,7,8,10,9,10,12,11,12,14,13,14,16,15,16,18,17,18,20,19,20,22,21,22,24,23,24,26,25,26,28,27,40,42,41,54,1,55,2,6,4,6,10,8,12,16,14,16,20,18,20,24,22,24,28,26,39,42,40,54,2,1,2,10,6,12,20,16,20,28,24,38,42,39,20,29,28,38,43,42,20,30,29,37,43,38,20,31,30,36,43,37,20,32,31,36,44,43,20,33,32,35,44,36,20,34,33,35,45,44,12,34,20,12,35,34,12,45,35,10,45,12,10,46,45,10,47,46,10,48,47,2,48,10,2,49,48,2,50,49,2,51,50,2,53,51,53,2,54],width:52.875},c:{positions:[20.49609375,4.67578125,20.49609375,4.67578125,23.36757469177246,5.087423801422119,25.919267654418945,6.322350978851318,28.055252075195312,8.557517051696777,29.08038330078125,10.95840835571289,29.1796875,12.0234375,35.40234375,12.0234375,35.47265625,11.8125,35.209197998046875,9.178794860839844,34.224666595458984,6.713964939117432,32.519065856933594,4.418010711669922,29.943574905395508,2.4374680519104004,27.361528396606445,.9345490336418152,24.772926330566406,-.0907462015748024,22.177766799926758,-.6384177803993225,20.49609375,-.73828125,17.386640548706055,-.5293084979057312,14.578433990478516,.09760986268520355,12.071474075317383,1.142473816871643,9.86575984954834,2.605283260345459,7.9612932205200195,4.4860382080078125,6.3618083000183105,6.765913009643555,5.107275009155273,9.241913795471191,4.197693824768066,11.914040565490723,3.633063793182373,14.782294273376465,3.4133858680725098,17.8466739654541,3.41015625,18.28125,3.41015625,19.7578125,3.5838754177093506,22.87480926513672,4.105032920837402,25.780019760131836,4.973628997802734,28.473445892333984,6.189663410186768,30.95508575439453,7.753136157989502,33.22494125366211,9.646564483642578,35.16857147216797,11.828062057495117,36.69178771972656,14.297628402709961,37.79460144042969,17.05526351928711,38.47700500488281,20.100967407226562,38.73899841308594,20.49609375,38.7421875,23.570213317871094,38.5140495300293,26.36119842529297,37.82963943481445,28.869049072265625,36.6889533996582,31.093765258789062,35.09199523925781,33.085479736328125,32.87481689453125,34.484825134277344,30.467679977416992,35.29180145263672,27.87058448791504,35.5078125,25.13671875,35.4375,24.92578125,29.1796875,24.92578125,28.72093391418457,27.737882614135742,27.34467315673828,30.163320541381836,24.98297119140625,32.04195022583008,22.43872833251953,33.074039459228516,20.49609375,33.29296875,17.510202407836914,32.94111633300781,15.082853317260742,31.88556480407715,13.214049339294434,30.12630844116211,11.89155101776123,27.541250228881836,10.979540824890137,24.808610916137695,10.478017807006836,21.928388595581055,10.37109375,19.7578125,10.37109375,18.28125,10.565627098083496,15.065240859985352,11.149227142333984,12.176401138305664,12.121894836425781,9.614731788635254,13.855029106140137,7.324370861053467,15.960027694702148,5.741883754730225,18.4368896484375,4.867271423339844],indices:[5,7,6,7,9,8,9,11,10,11,13,12,13,15,14,15,17,16,17,19,18,19,21,20,21,23,22,23,25,24,25,27,26,27,29,28,29,31,30,31,33,32,33,35,34,35,37,36,37,39,38,39,41,40,41,43,42,43,45,44,45,47,46,47,49,48,4,7,5,7,11,9,11,15,13,15,19,17,19,23,21,23,27,25,27,31,29,31,35,33,35,39,37,39,43,41,43,47,45,47,50,49,3,7,4,7,15,11,15,23,19,23,31,27,31,39,35,39,47,43,47,51,50,3,15,7,39,51,47,2,15,3,39,52,51,39,53,52,39,54,53,39,55,54,31,55,39,31,56,55,31,57,56,31,58,57,23,58,31,23,59,58,23,60,59,23,61,60,23,62,61,23,63,62,23,64,63,23,65,64,23,66,65,15,66,23,15,67,66,15,68,67,15,1,68,1,15,2],width:32.09765625},k:{positions:[28.828125,0,16.48828125,17.54296875,11.98828125,17.54296875,11.98828125,0,5.0625,0,5.0625,54.84375,11.98828125,54.84375,11.98828125,23.0625,16.41796875,23.0625,26.82421875,38.0390625,35.12109375,38.0390625,22.11328125,20.7421875,36.984375,0],indices:[12,1,0,2,4,3,4,6,5,8,10,9,11,1,12,4,7,6,8,11,10,11,2,1,2,7,4,7,11,8,11,7,2],width:31.921875},t:{positions:[0,0,30,0],indices:[0,2,1],width:30}," ":{width:16,positions:[],indices:[]}};function _Ot({text:t,size:e=1,zOffset:i=0}){const o=[],n=[];let r=0,a=0;const s=10;e/=100;for(const l of t){const c=LOt[l];if(!c)throw new Error("Unknown character: "+l);const d=a;for(let h=0;h<c.positions.length;h+=2)o.push(c.positions[h]*e+d,c.positions[h+1]*e,i);const u=r===0?0:r+1;for(const h of c.indices)n.push(h+u),r=Math.max(r,h+u);a+=(c.width+s)*e}return{positions:o,indices:n,primitive:"triangles"}}function jee(t,{content:e,size:i,matrix:o,offset:n=0}){const{material:r,origin:a,plugin:s}=t,{textSizeRatio:l,textBottomMarginRatio:c,xeokitSdk:d,viewer:u}=s,{Mesh:h,VBOGeometry:p,math:A}=d,{scene:f}=u,{primitive:m,positions:g,indices:y}=_Ot({text:e,size:i*l,zOffset:n});let v=g[0],w=g[0];for(let E=0;E<g.length;E+=3){const T=g[E];T<v&&(v=T),T>w&&(w=T)}const x=-(w-v)/2,k=A.mat4(),B=A.translationMat4v([x,i*c,0]);A.mulMat4(o,A.rotationMat4v(Math.PI,[0,1,0],A.mat4()),k),A.mulMat4(o,B),A.mulMat4(k,B);const P=new p(f,{primitive:m,positions:g,indices:y});return[new h(f,{geometry:P,material:r,pickable:!1,origin:a,matrix:o}),new h(f,{geometry:P,material:r,pickable:!1,origin:a,matrix:k})]}class FOt{constructor(e,i,o){this.plugin=e;const{viewer:n}=e;this.line=null,this.texts=null,this.length=0;const{math:r,worldToRTCPos:a,Node:s,PhongMaterial:l}=e.xeokitSdk,c=r.vec3(),d=r.vec3();a(i,d,c),this.material=new l(n.scene,{emissive:G1(e.defaultColor)}),this.node=new s(n.scene,{pickable:!1,origin:d,children:[]}),this.origin=d,this.p1=c,this.normal=o}move(e,i){const{arrowSizeRatio:o,offsetRatio:n,xeokitSdk:r,viewer:a}=this.plugin,{math:s,Mesh:l,VBOGeometry:c}=r,{scene:d}=a,u=this.p1;this.p2=s.subVec3(e,this.origin),this.node.removeChildren(),this.line?.destroy();const h=s.subVec3(e,u,s.vec3());if(h.every(Ce=>Ce===0))return;const p=s.normalizeVec3(h,s.vec3()),A=s.mulVec3Scalar(p,-1,s.vec3()),f=s.lenVec3(h);this.length=f;const m=n*f;let g=0;const y=s.mulVec3Scalar(h,.5,s.vec3()),v=s.addVec3(u,y,s.vec3());let w=s.normalizeVec3(s.cross3Vec3(i,s.normalizeVec3(h,s.vec3()),s.vec3()));const x=s.dotVec3(i,this.normal)>.999,k=s.vec3([0,1,0]),B=s.dotVec3(p,k);if(x){const Ce=Math.abs(B)<.01;g=m;let Le=null;if(Ce){const{look:Fe,up:ve,eye:me}=d.camera,we=s.normalizeVec3(s.subVec3(Fe,me,s.vec3())),Re=s.cross3Vec3(we,ve);Le=s.dotVec3(p,Re)}else{const Fe=s.cross3Vec3(k,i,s.vec3());Le=s.dotVec3(p,Fe)}Le<0&&(w=s.negateVec3(w),g=-g)}else if(Math.abs(B)>.99){const{look:Ce,eye:Le}=d.camera,Fe=s.normalizeVec3(s.subVec3(Ce,Le,s.vec3()));w=s.normalizeVec3(s.cross3Vec3(p,Fe,s.vec3())),i=s.normalizeVec3(s.cross3Vec3(w,p,s.vec3()))}else i=s.normalizeVec3(s.cross3Vec3(k,p,s.vec3())),w=s.normalizeVec3(s.cross3Vec3(p,i,s.vec3())),s.dotVec3(w,k)<0&&(w=s.negateVec3(w));const P=s.negateVec3(w,s.vec3()),E=s.mulVec3Scalar(w,f*o,s.vec3()),T=s.mulVec3Scalar(P,f*o,s.vec3()),S=s.addVec3(u,E,s.vec3()),R=s.addVec3(u,T,s.vec3()),F=s.addVec3(e,E,s.vec3()),U=s.addVec3(e,T,s.vec3()),q=s.mulVec3Scalar(s.normalizeVec3(s.addVec3(w,p,s.vec3())),f*o*Math.SQRT2),V=s.addVec3(u,q,s.vec3()),W=s.mulVec3Scalar(s.normalizeVec3(s.addVec3(P,p,s.vec3())),f*o*Math.SQRT2),Y=s.addVec3(u,W,s.vec3()),$=s.mulVec3Scalar(s.normalizeVec3(s.addVec3(w,A,s.vec3())),f*o*Math.SQRT2),fe=s.addVec3(e,$,s.vec3()),Me=s.mulVec3Scalar(s.normalizeVec3(s.addVec3(P,A,s.vec3())),f*o*Math.SQRT2),Se=s.addVec3(e,Me,s.vec3()),qe=s.translationMat4v(s.mulVec3Scalar(i,m,s.vec3()));this.line=new l(a.scene,{geometry:new c(a.scene,{primitive:"lines",positions:[...u,...e,...S,...R,...F,...U,...V,...Y,...fe,...Se],indices:[0,1,0,2,0,3,0,6,0,7,1,4,1,5,1,8,1,9]}),material:this.material,matrix:qe,pickable:!1,origin:this.origin}),this.node.addChild(this.line),this.texts?.forEach(Ce=>Ce.destroy());const Qe=s.mat4([...p,0,...w,0,...i,0,...v,1]);this.texts=this._makeTexts(f.toFixed(2)+" m",f,Qe,g),this.texts.forEach(Ce=>this.node.addChild(Ce))}_makeTexts(e,i,o,n=0){return jee(this,{content:e,size:i,matrix:o,offset:n})}destroy(){this.node.destroy(),this.line?.destroy(),this.texts?.forEach(e=>e.destroy()),this.plugin.measurements=this.plugin.measurements.filter(e=>e!==this)}get visible(){return this.node.visible}set visible(e){this.node.visible=e}get color(){return Oee(this.material.emissive)}set color(e=this.plugin.defaultColor){this.material.emissive=G1(e)}}class Vee{constructor(e,i,o={}){this.viewer=e,this.xeokitSdk=i,this.arrowSizeRatio=o.arrowSizeRatio??.04,this.textSizeRatio=o.textSizeRatio??.1,this.textBottomMarginRatio=o.textBottomMarginRatio??.02,this.offsetRatio=o.offsetRatio??.003,this.snapPickRadius=o.snapPickRadius??15,this.defaultColor=o.defaultColor??"#ffffff";const n=document.createElement("img"),r=e.scene.canvas.canvas;r.parentNode.insertBefore(n,r),n.style.width="28px",n.style.height="28px",n.style.position="absolute",n.style.pointerEvents="none",n.style.transform="translate(-50%, -50%)",n.style.display="none",this.imgElement=n,this.measurements=[],this.measurementEndCallbackId=0,this.measurementEndCallbacks={},this.control=new OOt(this)}on(e,i){if(e==="measurementEnd")return this.measurementEndCallbacks[this.measurementEndCallbackId++]=i,this.measurementEndCallbackId}off(e){this.measurementEndCallbacks[e]=null}}class OOt{constructor(e){this.plugin=e,this.currentMeasurement=null,this.lastPosition=null,this.mouseDown=!1,this.dragging=!1,this.activated=!1}_updateCursor(e){const{imgElement:i,viewer:o}=this.plugin,{scene:n}=o;n.canvas.canvas.style.cursor=`url("${ROt}") 16 16, auto`;const r=n.pick({canvasPos:e,snapRadius:this.plugin.snapPickRadius,snapToEdge:!0,snapToVertex:!0});if(r?.snappedWorldPos||r?.worldPos){if(r.snappedCanvasPos)i.style.left=`${r.snappedCanvasPos[0]}px`,i.style.top=`${r.snappedCanvasPos[1]}px`,i.src=r.snapType==="vertex"?SOt:IOt;else{const a=r.canvasPos;i.style.left=`${a[0]}px`,i.style.top=`${a[1]}px`,i.src=TOt}this.lastPosition=r.snappedWorldPos??r.worldPos,this.lastPosition.worldNormal=r.snappedWorldNormal??r.worldNormal}else i.style.left=`${e[0]}px`,i.style.top=`${e[1]}px`,i.src=DOt,this.lastPosition=null}_onMouseMove(e){this.mouseDown&&(this.dragging=!0),e.preventDefault(),this._updateCursor([e.offsetX,e.offsetY]),this.lastPosition&&this.currentMeasurement?.move(this.lastPosition,this.lastPosition.worldNormal)}_onMouseDown(){this.mouseDown=!0}_onMouseUp(){this.mouseDown=!1;const e=this.dragging;this.dragging=!1,!e&&this.lastPosition&&(this.currentMeasurement?(this.plugin.measurements.push(this.currentMeasurement),Object.values(this.plugin.measurementEndCallbacks).forEach(i=>i?.(this.currentMeasurement)),this.currentMeasurement=null):this.currentMeasurement=new FOt(this.plugin,this.lastPosition,this.lastPosition.worldNormal))}activate(){if(this.activated)return;const{canvas:e}=this.plugin.viewer.scene.canvas;this.plugin.imgElement.style.display="block";const i=this._onMouseMove.bind(this),o=this._onMouseDown.bind(this),n=this._onMouseUp.bind(this);e.addEventListener("mousemove",i),e.addEventListener("mousedown",o),document.addEventListener("mouseup",n),this._unsubscribe=()=>{e.removeEventListener("mousemove",i),e.removeEventListener("mousedown",o),document.removeEventListener("mouseup",n)},this.activated=!0}deactivate(){this.activated&&(this._unsubscribe?.(),this.currentMeasurement?.destroy(),this.currentMeasurement=null,this.lastPosition=null,this.plugin.imgElement.style.display="none",this.activated=!1)}}class UOt{constructor(e,i){this.plugin=e;const{xeokitSdk:o,viewer:n}=e,{Mesh:r,ReadableGeometry:a,buildSphereGeometry:s,PhongMaterial:l,Node:c,math:d,worldToRTCPos:u}=o,h=d.vec3(),p=d.vec3();this._length=0;const{entity:A,worldPos:f}=i;u(f,p,h);const m=new l(n.scene,{emissive:G1(e.defaultColor),diffuse:[0,0,0]}),g=(k=!0)=>new r(n.scene,{geometry:new a(n.scene,s({radius:.03})),material:m,pickable:!1,visible:k,origin:p}),y=g(),v=g(!1),w=new r(n.scene,{geometry:new a(n.scene,{primitive:"lines",positions:[0,0,0,0,0,0],indices:[0,1]}),material:m,pickable:!1,visible:!1,origin:p}),x=new c(n.scene,{pickable:!1,visible:!0,position:h,origin:p,children:[y,w,v]});this.origin=p,this.modelId=A.model.id,this.node=x,this.toSphere=v,this.fromSphere=y,this.line=w,this.material=m}show(e){const{node:i,fromSphere:o,toSphere:n,line:r,texts:a,plugin:s}=this,{math:l}=s.xeokitSdk;i.position=l.subVec3(e.worldPos,i.origin,l.vec3()),i.visible=!0;const{viewer:c}=s,d=c.scene.pick({pickSurface:!0,origin:e.worldPos,direction:e.worldNormal});if(a&&(a.forEach(u=>u.destroy()),this.texts=null),d){n.visible=!0,r.visible=!0,n.position=l.subVec3(d.worldPos,n.origin,l.vec3()),n.position=l.subVec3(n.position,i.position,l.vec3()),r.position=l.vec3().set(i.position),r.geometry.positions=[0,0,0,...n.position];const u=l.lenVec3(n.position);this._length=u;const h=o.position,p=n.position,A=l.subVec3(p,h,l.vec3()),f=l.normalizeVec3(A,l.vec3()),m=l.mulVec3Scalar(A,.5,l.vec3()),g=l.addVec3(h,m,l.vec3()),y=[0,1,0],v=l.dotVec3(f,y),w=Math.abs(v)>.9;let x;if(w){const k=l.normalizeVec3(l.subVec3(c.scene.camera.eye,c.scene.camera.look,l.vec3()),l.vec3()),B=l.normalizeVec3(l.cross3Vec3(k,f,l.vec3()),l.vec3()),P=l.normalizeVec3(l.cross3Vec3(B,f,l.vec3()),l.vec3());x=l.mat4([...f,0,...B,0,...P,0,...g,1])}else{const k=l.normalizeVec3(l.cross3Vec3(y,f,l.vec3()),l.vec3()),B=l.normalizeVec3(l.cross3Vec3(f,k,l.vec3()),l.vec3());x=l.mat4([...f,0,...B,0,...k,0,...g,1])}this.texts=this._makeTexts(u.toFixed(2)+" m",u,x),this.texts.forEach(k=>i.addChild(k))}else n.visible=!1,r.visible=!1,this._length=0}hide(){this.node.visible=!1}destroy(){this.node.destroy(),this.line.destroy(),this.fromSphere.destroy(),this.toSphere.destroy(),this.texts?.forEach(e=>e.destroy())}set length(e){this._length=e}get length(){return this.visible?this._length:0}get visible(){return this.node.visible===!0}set visible(e){this.node.visible=!!e}get color(){return Oee(this.material.emissive)}set color(e=this.plugin.defaultColor){this.material.emissive=G1(e)}_makeTexts(e,i,o){return jee(this,{content:e,size:i,matrix:o})}}class Hee{constructor(e,i,o={}){this.viewer=e,this.xeokitSdk=i,this.textSizeRatio=o.textSizeRatio??.1,this.textBottomMarginRatio=o.textBottomMarginRatio??.01,this.defaultColor=o.defaultColor??"#ffffff",this.measurements=[],this.measurementEndCallbackId=0,this.measurementEndCallbacks={},this.control=new NOt(this)}on(e,i){if(e==="measurementEnd")return this.measurementEndCallbacks[this.measurementEndCallbackId++]=i,this.measurementEndCallbackId}off(e){this.measurementEndCallbacks[e]=null}}class NOt{constructor(e){this.plugin=e,this.currentMeasure=null,this.pickedSpaceMeasureSubscription=null,this.hitHelperMouseMoveSubscription=null}activate(){const{plugin:e}=this,{viewer:i}=e;this.pickedSpaceMeasureSubscription=i.scene.input.on("mouseclicked",()=>{if(!this.currentMeasure?.length)return;const o=this.currentMeasure;this.currentMeasure=null,Object.values(this.plugin.measurementEndCallbacks).forEach(n=>n(o))}),this.hitHelperMouseMoveSubscription=i.scene.input.on("mousemove",o=>{const n=i.scene.pick({canvasPos:o,pickSurface:!0});n?.entity?.model&&(n?((!this.currentMeasure||this.currentMeasure.modelId!==n.entity.model.id)&&(this.currentMeasure?.destroy(),this.currentMeasure=new UOt(this.plugin,n)),this.currentMeasure.show(n)):this.currentMeasure?.hide())})}deactivate(){const{viewer:e}=this.plugin;this.currentMeasure?.destroy(),this.currentMeasure=null,e.scene.input.off(this.pickedSpaceMeasureSubscription),e.scene.input.off(this.hitHelperMouseMoveSubscription)}}const jOt=`onmessage = async event => {
1385
1385
  const sources = event.data;
1386
1386
  for (const source of sources) {
1387
1387
  const response = await fetch(source);
@@ -5314,5 +5314,5 @@ void main() {
5314
5314
  --bimdata-local-context-width: ${o.width}px;
5315
5315
  --bimdata-local-context-center-width: ${o.centerWidth}px;
5316
5316
  --bimdata-local-context-resolution: ${o.resolution};
5317
- `),onMouseenter:e[0]||(e[0]=(...h)=>o.onMouseEnter&&o.onMouseEnter(...h)),onMouseleave:e[1]||(e[1]=(...h)=>o.onMouseLeave&&o.onMouseLeave(...h))},[D(a,{ref:"modalManagerTemplateRef"},null,512),b("div",P6i,[o.windowPlugins.leftSidePanel?(M(),J(s,{key:0,plugin:o.windowPlugins.leftSidePanel},null,8,["plugin"])):te("",!0),b("div",I6i,[(M(!0),_(Xe,null,Bt(o.windowPlugins.free,h=>(M(),J(l,{key:h.name,class:ce({"window-container__content__center__viewer":h.isViewer}),plugin:h},null,8,["class","plugin"]))),128)),D(c,{position:"left",plugins:o.windowPlugins.leftButtonColumn},null,8,["plugins"]),D(c,{position:"right",plugins:o.windowPlugins.rightButtonColumn},null,8,["plugins"])]),o.windowPlugins.rightSidePanel?(M(),J(s,{key:1,plugin:o.windowPlugins.rightSidePanel},null,8,["plugin"])):te("",!0)]),o.loading?(M(),_("div",S6i,[o.spinner&&o.spinner.component?(M(),J(Mo(o.spinner.component),Ia(Cn({key:0},o.spinner.props)),null,16)):(M(),J(d,{key:1,size:"20px",border:"3px"}))])):te("",!0),o.layoutSettingsDisplayed?(M(),_("div",T6i,[D(u)])):te("",!0)],36)}const R6i=j(E6i,[["render",D6i],["__scopeId","data-v-485f288e"]]);class L6i{constructor(e=!0){const i=w5i(hV,null,{resizable:e});i.registerContent("default",R6i),this.settings=Cr({edit:!1,swap:!1,full:!1}),this.areas=i}get resizable(){return this.areas.resizable}set resizable(e){this.areas.resizable=e}apply(e=null){this.areas.layout=e?C5i(e):null}copy(e,i=!0){return x5i(this.areas.layout,e,i)}open({ratio:e,direction:i,insertAfter:o,windowName:n=null,windowState:r=null,localContextId:a=null}={}){const s=n?{options:{windowName:n,windowState:r}}:null;return a===null?this.areas.splitLayout(e,i,o,s):this.areas.split(a,e,i,o,s)}swap(e,i){return this.areas.swap(e,i)}close(e){return this.areas.delete(e)}compare(e,i){if(!e&&!i)return!0;if(!e||!i)return!1;if(typeof e=="string"&&typeof i=="string")return e===i;if(typeof e=="string"||typeof i=="string")return!1;if(e.windowName&&i.windowName){if(e.windowName!==i.windowName)return!1;const o=new Set(e.windowState?.modelIds),n=new Set(i.windowState?.modelIds);return o.size===n.size&&[...o].every(r=>n.has(r))}return e.windowName||i.windowName||e.direction!==i.direction||e.children.length!==i.children.length?!1:e.children.every((o,n)=>this.compare(o,i.children[n]))}}const _6i="2.15.0-beta.6",F6i={version:_6i};let O6i=1;class U6i{constructor({plugins:e,api:i,ui:o,locale:n="fr"}){this.instanceId=O6i++,this.pluginManager=new cmi(e),this.windowManager=new umi,this.windowManager.registerAndAddPluginsToWindows([...this.pluginManager.registeredPlugins.values()]),this.api=new E4i(i),this.globalContext=new u6e(this),this.state=j4i(this),this.shortcutManager=rge(this.state),this.uiSettings=o||{},this.i18n=new c6e(n),this._contextMenu=null,this.layout=new L6i(this.uiSettings.resizable!==!1),this._darkTheme=le(o?.darkTheme??!1),this.localContext=null,window.$viewer=this}get darkTheme(){return this._darkTheme.value}set darkTheme(e){this._darkTheme.value=e}get version(){return F6i.version}get locale(){return this.i18n.locale}get contextMenu(){return this._contextMenu||ige}set contextMenu(e){this._contextMenu=e}get registeredWindows(){return[...this.windowManager.registeredWindows.keys()]}get registeredPlugins(){return[...this.pluginManager.registeredPlugins.keys()]}get pluginsCfg(){return this.pluginManager.cfg}registerPlugin(e){this.pluginManager.registerPlugin(e),this.windowManager.registerAndAddPluginsToWindows([e])}}function N6i(t,e={}){e.backgroundColor&&(t.style.setProperty("--bimdata-viewer-background-color",e.backgroundColor),e.backgroundColor==="transparent"&&t.style.setProperty("--areas-separator-color","transparent")),e.colorPrimary&&t.style.setProperty("--color-primary",e.colorPrimary),e.colorPrimaryLighter&&t.style.setProperty("--color-primary-lighter",e.colorPrimaryLighter),e.colorPrimaryLight&&t.style.setProperty("--color-primary-light",e.colorPrimaryLight),e.colorPrimaryDark&&t.style.setProperty("--color-primary-dark",e.colorPrimaryDark),e.colorSecondary&&t.style.setProperty("--color-secondary",e.colorSecondary),e.colorSecondaryLighter&&t.style.setProperty("--color-secondary-lighter",e.colorSecondaryLighter),e.colorSecondaryLight&&t.style.setProperty("--color-secondary-light",e.colorSecondaryLight),e.colorSecondaryDark&&t.style.setProperty("--color-secondary-dark",e.colorSecondaryDark),e.colorSilverLight&&t.style.setProperty("--color-silver-light",e.colorSilverLight),e.colorSilver&&t.style.setProperty("--color-silver",e.colorSilver),e.colorSilverDark&&t.style.setProperty("--color-silver-dark",e.colorSilverDark),e.colorGraniteLight&&t.style.setProperty("--color-granite-light",e.colorGraniteLight),e.colorGranite&&t.style.setProperty("--color-granite",e.colorGranite),e.colorSuccess&&t.style.setProperty("--color-success",e.colorSuccess),e.colorSuccessLighter&&t.style.setProperty("--color-success-Lighter",e.colorSuccessLighter),e.colorSuccessLight&&t.style.setProperty("--color-success-Light",e.colorSuccessLight),e.colorSuccessDark&&t.style.setProperty("--color-success-Dark",e.colorSuccessDark),e.colorWarning&&t.style.setProperty("--color-warning",e.colorWarning),e.colorWarningLighter&&t.style.setProperty("--color-warning-Lighter",e.colorWarningLighter),e.colorWarningLight&&t.style.setProperty("--color-warning-Light",e.colorWarningLight),e.colorWarningDark&&t.style.setProperty("--color-warning-Dark",e.colorWarningDark),e.colorHigh&&t.style.setProperty("--color-high",e.colorHigh),e.colorHighLighter&&t.style.setProperty("--color-high-lighter",e.colorHighLighter),e.colorHighLight&&t.style.setProperty("--color-high-light",e.colorHighLight),e.colorHighDark&&t.style.setProperty("--color-high-dark",e.colorHighDark),e.colorText&&t.style.setProperty("--color-text",e.colorText),(!e.backgroundColor||e.backgroundColor!=="transparent")&&t.style.setProperty("--areas-separator-color","rgba(216, 216, 216, 1)"),e.headerHeight!=null&&t.style.setProperty("--bimdata-viewer-header-height",e.headerHeight),t.style.setProperty("--areas-background-color","transparent")}const j6i=Object.freeze({25:"GUEST",50:"USER",100:"ADMIN"}),tm=Object.freeze({READ:"read",WRITE:"write"});function Nfe(t){const e={};return t.forEach(i=>{const[o,n]=i.split(":");e[o]?e[o].push(n):e[o]=[n]}),e}const V6i={token_scopes:[],usable_scopes:[],user_role:25};function jfe(t=V6i){const e=Nfe(t.token_scopes),i=Nfe(t.usable_scopes);return{...dG(t),tokenScopes:e,usableScopes:i,userRole:j6i[t.user_role],user:t.user?dG(t.user):null,hasBcfReadPermission:i.bcf?.includes(tm.READ)??!1,hasBcfWritePermission:i.bcf?.includes(tm.WRITE)??!1,hasModelReadPermission:i.model?.includes(tm.READ)??!1,hasModelWritePermission:i.model?.includes(tm.WRITE)??!1,hasDocReadPermission:i.document?.includes(tm.READ)??!1,hasDocWritePermission:i.document?.includes(tm.WRITE)??!1}}const H6i={back:"Zur\xFCck",BcfFilters:{filtersButton:"Filter",filtersTitle:"Filter",priorityLabel:"Priorit\xE4t",statusLabel:"Status",stageLabel:"Phase",assignedToLabel:"Zugewiesen an",creatorsLabel:"Erstellt von",tagsLabel:"Tags",resetButton:"Zur\xFCcksetzen",searchButton:"Suchen",undefined:"Nicht definiert",datePlaceholder:"Erstellungsdatum"},BcfSettings:{title:"BCF-Parameter",text:"Erstellen, f\xFCllen und listen Sie die BCF-Einstellungen auf, die Sie f\xFCr dieses Projekt haben m\xF6chten.",validateButton:"Die BCF-Parameter anerkennen"},BcfStatistics:{emptyText:"F\xFCgen Sie Fragen hinzu, um zugeh\xF6rige Statistiken hier anzuzeigen.",issues:"Probleme",extension:{Priority:"Priorit\xE4t",PriorityNotDefined:"Keine Priorit\xE4t",PriorityTitle:"Priorit\xE4ten",Status:"Status",StatusNotDefined:"Kein Status",StatusTitle:"Status"}},BcfTopicCard:{priority:"Priorit\xE4t",noPriority:"Keine",assignedTo:"Zugewiesen an",elements:"Elemente",notSpecified:"Nicht definiert",see:"Anzeigen"},BcfTopicCreationCard:{text:"Ein neues BCF-Thema erstellen",createBcfSideTitle:"Ein Problem melden"},BcfTopicForm:{dragDropImageText:"Bitte w\xE4hlen Sie eine Datei aus.",addObjectButton:"Objekt",addAnnotationButton:"Annotation",annotationButtonTooltip:"Zu diesem Thema gibt es derzeit keine Ansichten.",addPictureButton:"F\xFCgen Sie ein Bild hinzu.",titlePlaceholder:"Titel *",titleErrorMessage:"Titel fehlt",typeLabel:"Typ",priorityLabel:"Priorit\xE4t",statusLabel:"Status",stageLabel:"Phase",assignedToLabel:"Zugewiesen an",dueDateLabel:"F\xE4lligkeitsdatum (TT.MM.JJJJ)",descriptionLabel:"Beschreibung",labelsLabel:"Tags",createButton:"Best\xE4tigen",updateButton:"\xC4nderungen \xFCbernehmen",modalText:"Sie sind dabei, die Bearbeitung der Ausgabe {Name} zu beenden, aber es gibt noch ungespeicherte \xC4nderungen.",cancelButton:"\xC4nderungen verwerfen",continueButton:"\xC4nderungen fortsetzen",createTitle:"Ein Problem melden",dragDropImageTextTablet:"Foto machen",takeSnapshot:"Mach einen Schnappschuss",importFile:"Eine Datei importieren",searchPlaceholder:"Suchen",emptySearch:"kein Ergebnis",documentsLabel:"Dokumente",documentsCount:"Dokumente \u2013 {count} ausgew\xE4hlte Dokumente",groupsLabel:"Berechtigungen",groupsCount:"Berechtigungen \u2013 {count} ausgew\xE4hlte Gruppen",groupsText:"W\xE4hlen Sie die Benutzergruppen aus, die dieses Thema sehen und damit interagieren d\xFCrfen.",validate:"Best\xE4tigen"},BcfTopicOverview:{openViewer:"Im Viewer \xF6ffnen",openViewerNoModels:"Es sind keine Vorlagen zur Ansicht bereit",elements:"{count} Elemente",noElements:"kein Element",type:"Typ",noTypeSpecified:"Kein Typ angegeben",description:"Beschreibung",noDescriptionProvided:"Keine Beschreibung angegeben",assignedTo:"Zugeteilt an",notAssigned:"Nicht zugewiesen",dueDate:"F\xE4lligkeitsdatum",noDueDate:"Kein F\xE4lligkeitsdatum",informations:"Informationen",status:"Status",noStatusSpecified:"Kein Status angegeben",stage:"Phase",noStageProvided:"Keine Phase angegeben",priority:"Priorit\xE4t",priorityNotDefined:"Nicht definiert",tags:"Tags",noTags:"Keine Tags",commentButton:"Ein Kommentar ver\xF6ffentlichen",deleteText:"Sie l\xF6schen jetzt {Name}",deleteBcfButton:"Dieses BCF l\xF6schen",keepBcfButton:"Dieses BCF beibehalten",author:"Autor"},BcfTopicsTable:{headers:{index:"#",priority:"Priorit\xE4t",status:"Status",title:"Titel",creator:"Autor",date:"Datum"}},BcfTopicActionsCell:{seeButton:"Anzeigen"},BcfTopicComments:{commentButton:"Ein Kommentar verfassen",commentLabel:"Ein Kommentar verfassen",commentText:"Kommentar",cancelButton:"Abbrechen",publishButton:"Ver\xF6ffentlichen",commentsText:"Kommentare",deleteCommentText:"Diesen Kommentar l\xF6schen?",deleteButton:"L\xF6schen",takeSnapshot:"Mach einen Schnappschuss",edited:"bearbeitet"},BcfTopicPriorityCell:{noPriority:"Keine"},SettingCard:{addButton:"ein Element hinzuf\xFCgen",cancelButton:"Abbrechen",validateButton:"Best\xE4tigen",deleteExtensionText:"Diesen Parameter l\xF6schen",deleteButton:"L\xF6schen",title:{Priority:"Priorit\xE4ten",Label:"Tags",Status:"Status",Type:"Typen",Stage:"Phasen"},input:{Priority:"Eine neue Priorit\xE4t hinzuf\xFCgen",Label:"Ein neues Etikett hinzuf\xFCgen",Status:"Einen neuen Status hinzuf\xFCgen",Type:"Einen neuen Typ hinzuf\xFCgen",Stage:"Eine neue Phase hinzuf\xFCgen"},text:{Priority:"Liste der Priorit\xE4ten",Label:"Liste von Tags",Status:"Liste der Status",Type:"Liste der Typen",Stage:"Liste der Phasen"}}},z6i={BcfComponents:H6i},q6i={back:"Back",BcfFilters:{filtersButton:"Filters",filtersTitle:"Filters",priorityLabel:"Priority",statusLabel:"Status",stageLabel:"Stage",assignedToLabel:"Assigned to",creatorsLabel:"Created by",tagsLabel:"Tags",resetButton:"Reset",searchButton:"Search",undefined:"Not defined",datePlaceholder:"Creation date"},BcfSettings:{title:"BCF Settings",text:"Create, enter in, and list the BCF settings you would like to have for this project",validateButton:"Validate BCF settings"},BcfStatistics:{emptyText:"Add BCF Topics to start to have some stats here.",issues:"issues",extension:{Priority:"Priority",PriorityNotDefined:"No priority",PriorityTitle:"Priorities",Status:"Status",StatusNotDefined:"No status",StatusTitle:"Status"}},BcfTopicCard:{priority:"Priority",noPriority:"None",assignedTo:"Assigned to",elements:"Elements",notSpecified:"Not specified",see:"See"},BcfTopicCreationCard:{text:"Create a new BCF topic",createBcfSideTitle:"Report a problem"},BcfTopicForm:{dragDropImageText:"Please select a file",addObjectButton:"Object",addAnnotationButton:"Annotation",annotationButtonTooltip:"This topic has no viewpoint",addPictureButton:"Add a picture",titlePlaceholder:"Title *",titleErrorMessage:"Missing title",typeLabel:"Type",priorityLabel:"Priority",statusLabel:"Status",stageLabel:"Stage",assignedToLabel:"Assigned to",dueDateLabel:"Due date",descriptionLabel:"Description",labelsLabel:"Tags",createButton:"Validate",updateButton:"Modify this BCF",modalText:"You are about to quit editing issue {name} but there are unsaved changes.",cancelButton:"Discard changes",continueButton:"Continue editing",createTitle:"Report a problem",dragDropImageTextTablet:"Take a picture",takeSnapshot:"Take a snapshot",importFile:"Import a file",searchPlaceholder:"Search",emptySearch:"No result",documentsLabel:"Add a file",documentsCount:"Files - {count} selected files",groupsLabel:"Permissions",groupsCount:"Permissions - {count} selected groups",groupsText:"You are now setting the access rights: choose the user group(s) that will be exclusively authorized to see and interact with this topic.",validate:"Validate"},BcfTopicOverview:{openViewer:"Open in viewer",openViewerNoModels:"No model to open",elements:"{count} Elements",noElements:"No element",type:"Type",noTypeSpecified:"No type specified",description:"Description",noDescriptionProvided:"No description provided",assignedTo:"Assigned to",notAssigned:"Not assigned",dueDate:"Due date",noDueDate:"No due date",informations:"Informations",status:"Status",noStatusSpecified:"No status specified",stage:"Stage",noStageProvided:"No stage provided",priority:"Priority",priorityNotDefined:"Not defined",tags:"Tags",noTags:"No tags",commentButton:"Post a comment",deleteText:"You are about to delete {name}",deleteBcfButton:"Delete this BCF",keepBcfButton:"Keep this BCF",author:"Author"},BcfTopicsTable:{headers:{index:"#",priority:"Priority",status:"Status",title:"Title",creator:"Author",date:"Date"}},BcfTopicActionsCell:{seeButton:"See"},BcfTopicComments:{commentButton:"Post a comment",commentLabel:"Post a comment",commentText:"Comment",cancelButton:"Cancel",publishButton:"Publish",commentsText:"Comments",deleteCommentText:"Delete this comment ?",deleteButton:"Delete",takeSnapshot:"Take a snapshot",edited:"edited"},BcfTopicPriorityCell:{noPriority:"None"},SettingCard:{addButton:"add an element",cancelButton:"Cancel",validateButton:"Validate",deleteExtensionText:"Remove this setting",deleteButton:"Delete",title:{Priority:"Priorities",Label:"Labels",Status:"Status",Type:"Types",Stage:"Stages"},input:{Priority:"Add a new priority",Label:"Add a new label",Status:"Add new status",Type:"Add a new type",Stage:"Add a new stage"},text:{Priority:"Priority list",Label:"Labels list",Status:"Status list",Type:"Type list",Stage:"Stage list"}}},Q6i={BcfComponents:q6i},G6i={back:"Volver",BcfFilters:{filtersButton:"Filtros",filtersTitle:"Filtros",priorityLabel:"Prioridad",statusLabel:"Estado",stageLabel:"Fase",assignedToLabel:"Asignado a",creatorsLabel:"Creado por",tagsLabel:"Etiquetas:",resetButton:"Restablecer",searchButton:"Buscar en",undefined:"No definido",datePlaceholder:"Fecha de creaci\xF3n"},BcfSettings:{title:"Par\xE1metros del BCF",text:"Cree, rellene y enumere los par\xE1metros del BCF que desea tener en este proyecto",validateButton:"Validar los par\xE1metros del BCF"},BcfStatistics:{emptyText:"A\xF1ada preguntas para ver las estad\xEDsticas asociadas aqu\xED.",issues:"problemas",extension:{Priority:"Prioridad",PriorityNotDefined:"Sin prioridad",PriorityTitle:"Prioridades",Status:"Estado",StatusNotDefined:"Sin estado",StatusTitle:"Estatutos"}},BcfTopicCard:{priority:"Prioridad",noPriority:"Sin",assignedTo:"Asignado a",elements:"Elementos",notSpecified:"No definido",see:"Ver"},BcfTopicCreationCard:{text:"Crear un nuevo tema BCF",createBcfSideTitle:"Informar de un problema"},BcfTopicForm:{dragDropImageText:"Seleccione un archivo",addObjectButton:"Objeto",addAnnotationButton:"Anotaci\xF3n",annotationButtonTooltip:"Actualmente este tema no posee ning\xFAn punto de vista",addPictureButton:"A\xF1adir una imagen",titlePlaceholder:"T\xEDtulo *",titleErrorMessage:"Falta el t\xEDtulo",typeLabel:"Tipo",priorityLabel:"Prioridad",statusLabel:"Estado",stageLabel:"Fase",assignedToLabel:"Asignado a",dueDateLabel:"Fecha de vencimiento (DD/MM/AAAA)",descriptionLabel:"Descripci\xF3n",labelsLabel:"Etiquetas",createButton:"Validar",updateButton:"Modificar este BCF",modalText:"Est\xE1 a punto de salir de la edici\xF3n del problema de {name} pero hay cambios sin guardar.",cancelButton:"Cancelar los cambios",continueButton:"Continuar con los cambios",createTitle:"Informar de un problema",dragDropImageTextTablet:"Tomar una fotograf\xEDa",takeSnapshot:"Tomar un snapshot",importFile:"Importar un archivo",searchPlaceholder:"Buscar",emptySearch:"No hay resultados"},BcfTopicOverview:{openViewer:"Abrir en el visor",openViewerNoModels:"No hay ning\xFAn modelo listo para la visualizaci\xF3n",elements:"{count} Elementos",noElements:"Ning\xFAn elemento",type:"Tipo",noTypeSpecified:"No se especifica el tipo",description:"Descripci\xF3n",noDescriptionProvided:"No hay descripci\xF3n",assignedTo:"Asignado a",notAssigned:"No asignado",dueDate:"Plazo",noDueDate:"Sin fecha de vencimiento",informations:"Informaci\xF3n",status:"Estado",noStatusSpecified:"No se especifica el estado",stage:"Fase",noStageProvided:"No se indica ninguna fase",priority:"Prioridad",priorityNotDefined:"No definido",tags:"Etiquetas",noTags:"Sin etiquetas",commentButton:"Publicar un comentario",deleteText:"Est\xE1s a punto de borrar {name}",deleteBcfButton:"Borrar este BCF",keepBcfButton:"Mantenga este BCF",author:"Autor"},BcfTopicsTable:{headers:{index:"#",priority:"Prioridad",status:"Estado",title:"T\xEDtulo",creator:"Autor",date:"Fecha"}},BcfTopicActionsCell:{seeButton:"Ver"},BcfTopicComments:{commentButton:"Publicar un comentario",commentLabel:"Publicar un comentario",commentText:"Comentario",cancelButton:"Cancelar",publishButton:"Publicar",commentsText:"comentarios",deleteCommentText:"\xBFBorrar este comentario?",deleteButton:"Borrar",takeSnapshot:"Tomar un snapshot"},BcfTopicPriorityCell:{noPriority:"Sin"},SettingCard:{addButton:"a\xF1adir un elemento",cancelButton:"Cancelar",validateButton:"Validar",deleteExtensionText:"Borrar esta configuraci\xF3n",deleteButton:"Borrar",title:{Priority:"Prioridades",Label:"Etiquetas:",Status:"Estatutos",Type:"Tipos",Stage:"Fases"},input:{Priority:"A\xF1adir una nueva prioridad",Label:"A\xF1adir una nueva etiqueta",Status:"A\xF1adir un nuevo estado",Type:"A\xF1adir un nuevo tipo",Stage:"A\xF1adir una nueva fase"},text:{Priority:"Lista de prioridades",Label:"Lista de etiquetas",Status:"Lista de estatutos",Type:"Lista de tipos",Stage:"Lista de fases"}}},K6i={BcfComponents:G6i},J6i={back:"Retour",BcfFilters:{filtersButton:"Filtres",filtersTitle:"Filtres",priorityLabel:"Priorit\xE9",statusLabel:"Statut",stageLabel:"Phase",assignedToLabel:"Assign\xE9 \xE0",creatorsLabel:"Cr\xE9\xE9 par",tagsLabel:"Tags",resetButton:"R\xE9initialiser",searchButton:"Rechercher",undefined:"Non d\xE9fini",datePlaceholder:"Date de cr\xE9ation"},BcfSettings:{title:"Param\xE8tres BCF",text:"Cr\xE9ez, renseignez et listez les param\xE8tres BCF que vous souhaitez avoir sur ce projet",validateButton:"Valider les param\xE8tres BCF"},BcfStatistics:{emptyText:"Ajoutez des questions pour voir les statistiques associ\xE9es ici.",issues:"probl\xE8mes",extension:{Priority:"Priorit\xE9",PriorityNotDefined:"Aucune priorit\xE9",PriorityTitle:"Priorit\xE9s",Status:"Statut",StatusNotDefined:"Aucun statut",StatusTitle:"Statuts"}},BcfTopicCard:{priority:"Priorit\xE9",noPriority:"Aucune",assignedTo:"Assign\xE9 \xE0",elements:"{n} \xC9lements",notSpecified:"Non d\xE9fini",see:"Voir"},BcfTopicCreationCard:{text:"Cr\xE9er un nouveau topic BCF",createBcfSideTitle:"Signaler un probl\xE8me"},BcfTopicForm:{dragDropImageText:"Veuillez s\xE9lectionner un fichier",addObjectButton:"Objet",addAnnotationButton:"Annotation",annotationButtonTooltip:"Ce topic ne poss\xE8de actuellement aucun point de vue",addPictureButton:"Ajouter une image",titlePlaceholder:"Titre *",titleErrorMessage:"Titre manquant",typeLabel:"Type",priorityLabel:"Priorit\xE9",statusLabel:"Statut",stageLabel:"Phase",assignedToLabel:"Assign\xE9 \xE0",dueDateLabel:"Date d'\xE9ch\xE9ance",descriptionLabel:"Description",labelsLabel:"Tags",createButton:"Valider",updateButton:"Modifier ce BCF",modalText:"Vous \xEAtes sur le point de quitter l'\xE9dition de l'issue {name} mais il y'a des modifications non enregistr\xE9es.",cancelButton:"Annuler les modifications",continueButton:"Continuer les modifications",createTitle:"Signaler un probl\xE8me",dragDropImageTextTablet:"Prendre une photo",takeSnapshot:"Prendre un snapshot",importFile:"Importer un fichier",searchPlaceholder:"Rechercher",emptySearch:"Pas de r\xE9sultat",documentsLabel:"Documents",documentsCount:"Documents - {count} documents s\xE9lectionn\xE9s",groupsLabel:"Permissions",groupsCount:"Permissions - {count} groupes s\xE9lectionn\xE9s",groupsText:"S\xE9lectionner les groupes utilisateur qui peuvent voir ce topic et int\xE9ragir avec.",validate:"Valider"},BcfTopicOverview:{openViewer:"Ouvrir dans le viewer",openViewerNoModels:"Il n'y a aucun mod\xE8le pr\xEAt pour une visualisation",elements:"{count} \xC9lements",noElements:"Aucun \xE9l\xE9ment concern\xE9",type:"Type",noTypeSpecified:"Pas de type sp\xE9cifi\xE9",description:"Description",noDescriptionProvided:"Pas de description renseign\xE9e",assignedTo:"Assign\xE9 \xE0",notAssigned:"Non assign\xE9",dueDate:"\xC9ch\xE9ance",noDueDate:"Pas de date d'\xE9ch\xE9ance",informations:"Informations",status:"Statut",noStatusSpecified:"Pas de statut sp\xE9cifi\xE9",stage:"Phase",noStageProvided:"Pas de phase renseign\xE9e",priority:"Priorit\xE9",priorityNotDefined:"Non d\xE9fini",tags:"Tags",noTags:"Pas de tags",commentButton:"Poster un commentaire",deleteText:"Vous \xEAtes sur le point de supprimer {name}",deleteBcfButton:"Supprimer ce BCF",keepBcfButton:"Conserver ce BCF",author:"Auteur"},BcfTopicsTable:{headers:{index:"#",priority:"Priorit\xE9",status:"Statut",title:"Titre",creator:"Auteur",date:"Date"}},BcfTopicActionsCell:{seeButton:"Voir"},BcfTopicComments:{commentButton:"Poster un commentaire",commentLabel:"Poster un commentaire",commentText:"Commentaire",cancelButton:"Annuler",publishButton:"Publier",commentsText:"commentaires",deleteCommentText:"Supprimer ce commentaire ?",deleteButton:"Supprimer",takeSnapshot:"Prendre un snapshot",edited:"edit\xE9"},BcfTopicPriorityCell:{noPriority:"Aucune"},SettingCard:{addButton:"ajouter un \xE9l\xE9ment",cancelButton:"Annuler",validateButton:"Valider",deleteExtensionText:"Supprimmer ce param\xE8tre",deleteButton:"Supprimer",title:{Priority:"Priorit\xE9s",Label:"Tags",Status:"Statuts",Type:"Types",Stage:"Phases"},input:{Priority:"Ajouter une nouvelle priorit\xE9",Label:"Ajouter un nouveau label",Status:"Ajouter un nouveau statut",Type:"Ajouter un nouveau type",Stage:"Ajouter une nouvelle phase"},text:{Priority:"Liste des priorit\xE9s",Label:"Liste des tags",Status:"Liste des statuts",Type:"Liste des types",Stage:"Liste des phases"}}},Z6i={BcfComponents:J6i},W6i={back:"Indietro",BcfFilters:{filtersButton:"Filtri",filtersTitle:"Filtri",priorityLabel:"Priorit\xE0",statusLabel:"Stato",stageLabel:"Fase",datePlaceholder:"Data di creazione",assignedToLabel:"Assegnato a",creatorsLabel:"Creato da",tagsLabel:"Etichette",resetButton:"Ripristina",searchButton:"Cerca",undefined:"Non definito"},BcfSettings:{title:"Parametri BCF",text:"Creare, notificare e elencare i parametri BCF che si desidera avere su questo progetto",validateButton:"Conferma i parametri BCF"},BcfStatistics:{emptyText:"Aggiungi delle domande per vedere le statistiche associate qui.",issues:"problemi",extension:{Priority:"Priorit\xE0",PriorityNotDefined:"Nessuna priorit\xE0",PriorityTitle:"Priorit\xE0",Status:"Stato",StatusNotDefined:"Nessuno stato",StatusTitle:"Stati"}},BcfTopicCard:{priority:"Priorit\xE0",noPriority:"Nessuno",assignedTo:"Assegnato a",elements:"Elementi",noElements:"0 elementi",notSpecified:"Non definito",see:"Visualizza"},BcfTopicCreationCard:{text:"Crea un nuovo topic BCF",createBcfSideTitle:"Segnala un problema"},BcfTopicForm:{dragDropImageText:"Selezionare un file",addObjectButton:"Oggetto",addAnnotationButton:"Annotazione",annotationButtonTooltip:"Attualmente questo argomento non presenta alcun punto di vista",addPictureButton:"Aggiungere un'immagine",titlePlaceholder:"Titolo *",titleErrorMessage:"Titolo mancante",typeLabel:"Tipo",priorityLabel:"Priorit\xE0",statusLabel:"Stato",stageLabel:"Fase",assignedToLabel:"Assegnato a",dueDateLabel:"Data di scadenza",descriptionLabel:"Descrizione",labelsLabel:"Tag",createButton:"Conferma",updateButton:"Modificare questo BCF",modalText:"State per abbandonare la modifica di {name} ma ci sono modifiche non salvate.",cancelButton:"Annullare le modifiche",continueButton:"Continuare le modifiche",createTitle:"Segnala un problema"},BcfTopicOverview:{openViewer:"Apri nel visualizzatore",openViewerNoModels:"Non esistono modelli pronti per la visualizzazione",elements:"{count} Elementi",noElements:"Nessun elemento",type:"Tipo",noTypeSpecified:"Nessun tipo specificato",description:"Descrizione",noDescriptionProvided:"Nessuna descrizione inserita",assignedTo:"Assegnato a",notAssigned:"Non assegnato",dueDate:"Scadenza",noDueDate:"Nessuna data di scadenza",informations:"Informazioni",status:"Stato",noStatusSpecified:"Nessuno stato specificato",stage:"Fase",noStageProvided:"Nessuna fase inserita",priority:"Priorit\xE0",priorityNotDefined:"Non definita",tags:"Etichette",noTags:"Nessuna etichetta",commentButton:"Pubblica un commento",deleteText:"Stai per eliminare {name}",deleteBcfButton:"Elimina questo BCF",keepBcfButton:"Conserva questo BCF",author:"Autore"},BcfTopicsTable:{headers:{index:"#",priority:"Priorit\xE0",status:"Stato",title:"Titolo",creator:"Autore",date:"Data"}},BcfTopicActionsCell:{seeButton:"Visualizza"},BcfTopicComments:{commentButton:"Pubblica un commento",commentLabel:"Pubblica un commento",commentText:"Commento",cancelButton:"Annulla",publishButton:"Pubblica",commentsText:"commenti",deleteCommentText:"Eliminare questo commento?",deleteButton:"Elimina"},BcfTopicPriorityCell:{noPriority:"Nessuno"},SettingCard:{addButton:"aggiungi un elemento",cancelButton:"Annulla",validateButton:"Conferma",deleteExtensionText:"Elimina questo parametro",deleteButton:"Elimina",title:{Priority:"Priorit\xE0",Label:"Etichette",Status:"Stati",Type:"Tipi",Stage:"Fasi"},input:{Priority:"Aggiungi una nuova priorit\xE0",Label:"Aggiungi una nuova etichetta",Status:"Aggiungi un nuovo stato",Type:"Aggiungi un nuovo tipo",Stage:"Aggiungi una nuova fase"},text:{Priority:"Elenco delle priorit\xE0",Label:"Elenco delle etichette",Status:"Elenco degli stati",Type:"Elenco dei tipi",Stage:"Elenco delle fasi"}}},Y6i={BcfComponents:W6i},X6i={de:z6i,en:Q6i,es:K6i,fr:Z6i,it:Y6i},$6i=({apiClient:t,fetchUsers:e,i18nPlugin:i}={})=>({install(o){t?Di.setup({apiClient:t,fetchUsers:e}):console.error("[BCF Components Plugin] No api client provided. You must provide an api client for the components to work properly."),i?Object.entries(X6i).forEach(([n,r])=>{i.global.mergeLocaleMessage(n,r)}):console.warn("[BCF Components Plugin] No i18n instance provided. You should either provide an i18n instance or define your own translations in order have text displayed properly."),Object.entries(iwe).forEach(([n,r])=>{o.component(n,r)})}}),e8i={title:"Building Maker",back:"Zur\xFCck",list:{text:"Erstellen und bearbeiten Sie die Etagen und laden Sie anschlie\xDFend Ihre PDFs herunter.",createButton:"Neues Projekt",updateButton:"Umbenennen",deleteButton:"L\xF6schen"},form:{text:"Erstellen und bearbeiten Sie die Etagen und laden Sie anschlie\xDFend Ihre PDFs herunter.",input:"Name des Geb\xE4udes",error:"Ung\xFCltiger Name",createButton:"Erstellen",updateButton:"Best\xE4tigen"},view:{addStoreyButton:"Etage",addPlanButton:"Grundriss",closeButton:"Fertigstellen",submitFilesButton:"Best\xE4tigen"},storeyForm:{title:"Neue Etage",input:"Name",error:"Ung\xFCltiger Name",cancelButton:"Abbrechen",submitButton:"Best\xE4tigen"}},t8i={creationFormTitle:"Ordner erstellen",renameFormPlaceholder:"Datei- / Ordnernam",nameInputPlaceholder:"Ordnername",emptyFolder:"Dieser Ordner ist leer",newFolderSuccess:"Neuer Ordner erstellt",renameFolderSuccess:"Umbenannter Ordner",deleteFolderSuccess:"Ordner gel\xF6scht",newFileSuccess:"Datei hinzugef\xFCgt",renameFileSuccess:"Umbenannte Datei",deleteFileSuccess:"Datei gel\xF6scht",nameInputErrorMessage:"Ung\xFCltiger name",cancel:"Abbrechen",submit:"Best\xE4tigen",buttonText:"Neuer Ordner",addFileButtonText:"Datei laden",rename:"Umbenennen",view:"Sehen",download:"Herunterladen",delete:"L\xF6schen",deleteTitle:"Dateien l\xF6schen",deleteDetail:"Sie sind im Begriff, die folgenden Dateien / Ordner endg\xFCltig zu l\xF6schen"},i8i={BuildingMaker:e8i,FileManager:t8i},o8i={t:{back:"Back",cancel:"Cancel",create:"Create",delete:"Delete",download:"Download",finish:"Finish",rename:"Rename",search:"Search",see:"View",storey:"Storey",validate:"Validate"}},r8i={title:"Building Maker",list:{text:"Create and edit storeys, then download your PDFs.",new:"New project"},form:{input:"Building name",error:"Invalid"},view:{addStorey:"Add Storey",addFile:"Add File",addPlan:"Add Plan"},storeyForm:{title:"New storey",input:"Name",error:"Invalid name"}},n8i={creationFormTitle:"Create folder",renameFormPlaceholder:"Folder/File name",nameInputPlaceholder:"Folder name",emptyFolder:"This folder is empty",newFolderSuccess:"New folder created",renameFolderSuccess:"Folder renamed",deleteFolderSuccess:"Folder deleted",newFileSuccess:"File added",renameFileSuccess:"File renamed",deleteFileSuccess:"File deleted",nameInputErrorMessage:"Invalid name",buttonText:"New folder",addFileButtonText:"Upload a file",deleteTitle:"Deleting Files",deleteDetail:"You are about to permanently delete the following files / folders",dmsRoot:"Root of the project's DMS",pdfPageSelectorTitle:"Select a page"},a8i={title:"Meta-Building Structure",tab:{structure:"Structure",zones:"Zones",equipments:"Equipments"},StoreySelector:{placeholder:"Select a storey"}},s8i={title:"Photosphere Building"},l8i={BIMDataComponents:o8i,BuildingMaker:r8i,FileManager:n8i,MetaBuildingStructure:a8i,PhotosphereBuilding:s8i},c8i={title:"Building Maker",back:"Vuelta",list:{text:"Cree y edite los pisos despu\xE9s cargue los PDF.",createButton:"Nuevo proyecto",updateButton:"Renombrar",deleteButton:"Suprimir"},form:{text:"Cree y edite los pisos despu\xE9s cargue los PDF.",input:"Nombre del edificio",error:"Nombre no v\xE1lido",createButton:"Crear",updateButton:"Validar"},view:{addStoreyButton:"Piso",addPlanButton:"Plano",closeButton:"Terminar",submitFilesButton:"Validar"},storeyForm:{title:"Nuevo piso",input:"Nombre",error:"Nombre no v\xE1lido",cancelButton:"Anular",submitButton:"Validar"}},d8i={creationFormTitle:"Crear un archivo",renameFormPlaceholder:"Nombre de archivo / carpeta",nameInputPlaceholder:"Nombre de la carpeta",emptyFolder:"Esta carpeta est\xE1 vac\xEDa",newFolderSuccess:"Nueva carpeta creada",renameFolderSuccess:"Carpeta renombrada",deleteFolderSuccess:"Carpeta eliminada",newFileSuccess:"Archivo agregado",renameFileSuccess:"Archivo renombrado",deleteFileSuccess:"Archivo eliminado",nameInputErrorMessage:"Nombre inv\xE1lida",cancel:"Cancelar",submit:"Validar",buttonText:"Carpeta nueva",addFileButtonText:"Cargar un archivo",rename:"Renombrar",view:"Ver",download:"Descargar",delete:"Borrar",deleteTitle:"Eliminar archivos",deleteDetail:"Est\xE1 a punto de eliminar permanentemente los siguientes archivos / carpetas"},u8i={BuildingMaker:c8i,FileManager:d8i},h8i={t:{back:"Retour",cancel:"Annuler",create:"Cr\xE9er",delete:"Supprimer",download:"T\xE9l\xE9charger",finish:"Terminer",rename:"Renommer",search:"Rechercher",see:"Voir",storey:"\xC9tage",validate:"Valider"}},p8i={title:"Building Maker",list:{text:"Cr\xE9ez et \xE9ditez les \xE9tages puis t\xE9l\xE9chagez vos PDF.",new:"Nouveau projet"},form:{input:"Nom du b\xE2timent",error:"Nom invalide"},view:{addStorey:"Ajouter un \xC9tage",addFile:"Ajouter un fichier",addPlan:"Ajouter un plan"},storeyForm:{title:"Nouvel \xE9tage",input:"Nom",error:"Nom invalide"}},f8i={creationFormTitle:"Cr\xE9er un dossier",renameFormPlaceholder:"Nom du fichier/dosier",nameInputPlaceholder:"Nom du dossier",emptyFolder:"Ce dossier est vide",newFolderSuccess:"Nouveau dossier cr\xE9\xE9",renameFolderSuccess:"Dossier renomm\xE9",deleteFolderSuccess:"Dossier supprim\xE9",newFileSuccess:"Fichier ajout\xE9",renameFileSuccess:"Fichier renomm\xE9",deleteFileSuccess:"Fichier supprim\xE9",nameInputErrorMessage:"Nom invalide",buttonText:"Nouveau dossier",addFileButtonText:"Charger un fichier",deleteTitle:"Supression de fichiers",deleteDetail:"Vous \xEAtes sur le point de supprimer d\xE9finitivement les fichiers/dossiers suivants",dmsRoot:"Racine de la GED du projet",pdfPageSelectorTitle:"S\xE9lectionner une page"},A8i={title:"Structure M\xE9ta-Building",tab:{structure:"Structure",zones:"Zones",equipments:"\xC9quipements"},StoreySelector:{placeholder:"S\xE9lectionner un \xE9tage"}},g8i={title:"Photosph\xE8re Building"},m8i={BIMDataComponents:h8i,BuildingMaker:p8i,FileManager:f8i,MetaBuildingStructure:A8i,PhotosphereBuilding:g8i},v8i={title:"Building Maker",back:"Reso",list:{text:"Crea e modifica i piani e poi scarica i tuoi PDF.",createButton:"Nuovo progetto",updateButton:"Rinominare",deleteButton:"Eliminare"},form:{text:"Crea e modifica i piani e poi scarica i tuoi PDF.",input:"Nome della costruzione",error:"Nome non corretto",createButton:"Creare",updateButton:"Convalidare"},view:{addStoreyButton:"Piano",addPlanButton:"Mappa",closeButton:"Finire",submitFilesButton:"Convalidare"},storeyForm:{title:"Nuovo piano",input:"Nome",error:"Nome non corretto",cancelButton:"Annullare",submitButton:"Convalidare"}},y8i={creationFormTitle:"Crea una cartella",renameFormPlaceholder:"Nome file/cartella",nameInputPlaceholder:"Nome della cartella",emptyFolder:"Questa cartella \xE8 vuota",newFolderSuccess:"Nuova cartella creata",renameFolderSuccess:"Cartella rinominata",deleteFolderSuccess:"Cartella eliminata",newFileSuccess:"File aggiunto",renameFileSuccess:"File rinominato",deleteFileSuccess:"File cancellato",nameInputErrorMessage:"Nome non valido",cancel:"Annulla",submit:"Invia",buttonText:"Nuova cartella",addFileButtonText:"Carica un file",rename:"Rinominare",view:"Vedere",download:"Scaricare",delete:"Cancellare",deleteTitle:"Eliminazione di file",deleteDetail:"Stai per eliminare definitivamente i seguenti file/cartelle"},b8i={BuildingMaker:v8i,FileManager:y8i},w8i={de:i8i,en:l8i,es:u8i,fr:m8i,it:b8i},C8i=({i18nPlugin:t}={})=>({install(e){t?Object.entries(w8i).forEach(([i,o])=>{t.global.mergeLocaleMessage(i,o)}):console.warn("[BIMData Components Plugin] No i18n instance provided. You should either provide an i18n instance or define your own translations in order have text displayed properly."),Object.entries(y$t).forEach(([i,o])=>{e.component(i,o)})}}),x8i={beforeMount(t,e){if(typeof e.value!="function")throw Error(`click away directive needs function, got ${typeof e.value}`);t.clickAwayHandler=i=>{(i.path||i.composedPath&&i.composedPath()).find(o=>o===t)||e.value()},window.addEventListener("mousedown",t.clickAwayHandler,!0)},unmounted(t){window.removeEventListener("mousedown",t.clickAwayHandler,!0),delete t.clickAwayHandler}},k8i=Object.freeze(Object.defineProperty({__proto__:null,BIMDataClickAway:Zs,BIMDataClickInputAway:x8i},Symbol.toStringTag,{value:"Module"})),M8i=t=>({install(e){Object.entries(GXe).forEach(([i,o])=>{e.component(i,o)}),Object.entries(k8i).forEach(([i,o])=>e.directive(i.split("BIMData")[1],o))}}),B8i={name:"LiWrapper",render(){return Qo("li",this.$slots.default())}};function E8i(t,e){var i=new Set([]);return t.forEach(o=>{e.has(o)||i.add(o)}),i}const Ml=Zr("id"),P8i=({contextMenu:t,objects:e=[],state:i=t.$viewer.state,pictos:o})=>[{name:"selectAll",get group(){return t.groupPositions.select},position:1,get label(){return t.$t("context_menu.select_all")},get picto(){return o.get(this.name)},execute:()=>i.selectObjects(e.filter(Fs(Pi("visible"),gu("selected"))).map(Ml)),predicate:()=>e.some(Fs(Pi("visible"),gu("selected")))},{name:"deselectAll",get group(){return t.groupPositions.select},position:2,get label(){return t.$t("context_menu.deselect_all")},get picto(){return o.get(this.name)},execute:()=>i.deselectObjects(e.filter(Pi("selected")).map(Ml)),predicate:()=>e.some(Pi("selected"))},{name:"selectSimilar",get group(){return t.groupPositions.select},position:3,get label(){return t.$t("context_menu.select_similar")},get picto(){return o.get(this.name)},execute(){const n=e.filter(r=>r.visible&&r.type===this.selectedObject.type&&r.id!==this.selectedObject.id).map(Ml);i.selectObjects(n)},selectedObject:null,predicate(){const n=e.filter(Fs(Pi("visible"),Pi("selected")));return n.length===1&&n[0].type!==void 0?(this.selectedObject=n[0],!0):(this.selectedObject=null,!1)}},{name:"reverseSelection",get label(){return t.$t("context_menu.reverse_selection")},get group(){return t.groupPositions.select},position:4,execute:()=>{const n=new Set(e.filter(Pi("selected")).map(Ml)),r=new Set(e.filter(Pi("visible")).map(Ml));i.selectObjects(Array.from(E8i(r,n)),{exclusive:!0})},predicate:()=>e.some(Fs(gu("selected"),Pi("visible")))&&e.some(Fs(Pi("selected"),Pi("visible")))},{name:"showAll",get group(){return t.groupPositions.visibility},position:1,get label(){return t.$t("context_menu.show_all")},get picto(){return o.get(this.name)},execute:()=>i.showObjects(e.filter(gu("visible")).map(Ml)),predicate:()=>e.some(gu("visible"))},{name:"hide",get group(){return t.groupPositions.visibility},position:2,get label(){return t.$t("context_menu.hide")},get picto(){return o.get(this.name)},objectsToHide:null,execute(){const n=this.objectsToHide.filter(Pi("selected"));n.length>0&&i.deselectObjects(n.map(Ml)),i.hideObjects(this.objectsToHide.map(Ml))},predicate(){return this.objectsToHide=e.filter(Fs(Pi("selected"),Pi("visible"))),this.objectsToHide.length>0}},{name:"hideAll",get group(){return t.groupPositions.visibility},position:3,get label(){return t.$t("context_menu.hide_all")},execute:()=>{const n=e.filter(Pi("visible"));n.some(Pi("selected"))&&i.deselectObjects(n.filter(Pi("selected")).map(Ml)),i.hideObjects(n.map(Ml))},predicate:()=>e.some(Pi("visible"))}].filter(n=>n.predicate()),I8i={components:{LiWrapper:B8i},inject:["$viewer"],data(){return{defaultPrevented:!1,displayed:!1,top:null,bottom:null,left:null,width:200,nextCommandId:1,currentCommands:[],contextCommands:[],registeredCommands:[],groupPositions:{select:10,visibility:20},asyncPredicateRunning:!1}},computed:{position(){return{top:this.top?this.top+"px":"unset",bottom:this.bottom?this.bottom+"px":"unset",left:this.left+"px",width:this.width+"px"}}},watch:{displayed(t){t?document.addEventListener("keydown",this.onKeyDown):document.removeEventListener("keydown",this.onKeyDown)}},created(){this.$viewer.contextMenu=this,this.asyncPredicates=new Set},methods:{onKeyDown(t){t.key==="Escape"&&this.away()},setPosition(t){const e=(document.fullscreenElement?document.fullscreenElement:this.$parent.$el).getBoundingClientRect();this.left=t.clientX-e.left,this.top=t.clientY-e.top,this.left+this.width>e.width&&(this.left=this.left-this.width),t.clientY>e.top+e.height/2?(this.bottom=e.height-this.top,this.top=null):this.bottom=null},typeCheckCommand(t={}){let e=null;if((!t.execute||typeof t.execute!="function")&!t.component&&(e="Cannot register context menu command. A command must have an execute function or a component property."),t.label||(e="Cannot register context menu command. A command must have a label."),e)throw console.error(e),new Error(e);return t.id=this.nextCommandId++,t},open(t){this.currentCommands=[],this.setPosition(t),this.originEvent=t,t.preventDefault(),this.setCurrentCommands(),this.groupCurrentCommands(),this.defaultPrevented=!1,this.displayed=!0,document.fullscreenElement?(this.$el.parentElement.removeChild(this.$el),this.adoptiveParent=document.fullscreenElement,this.adoptiveParent.appendChild(this.$el)):this.adoptiveParent&&this.adoptiveParent!==this.$viewer.globalContext.el&&(this.adoptiveParent.removeChild(this.$el),this.$viewer.globalContext.el.appendChild(this.$el),this.adoptiveParent=null)},setCurrentCommands(){this.asyncPredicates.clear(),this.asyncPredicateRunning=!1,this.defaultPrevented||this.registeredCommands.forEach(async t=>{if(typeof t.predicate=="function"){const e=t.predicate(this.$viewer.globalContext.activeLocalContext);if(e===!0)this.currentCommands.push(t);else if(typeof e?.then=="function"){this.asyncPredicates.add(e),this.asyncPredicateRunning=!0;const i=await e;this.asyncPredicates.has(e)&&(this.asyncPredicates.delete(e),this.asyncPredicateRunning=this.asyncPredicates.size>0,i===!0&&this.currentCommands.push(t))}}else this.currentCommands.push(t)}),this.currentCommands.push(...this.contextCommands),this.contextCommands=[]},getDefaultCommands({objects:t=[],state:e=this.$viewer.state,context:i=null}){const o=new Map;return i&&this.$viewer.shortcutManager.getShortcuts(i).forEach(n=>o.set(n.name,n.key)),P8i({contextMenu:this,objects:t,state:e,pictos:o})},executeCommand(t){if(t.execute&&(t.execute(this.originEvent),this.displayed=!1),t.component&&!t.menu)throw new Error("Command with component property must have a `menu` property")},away(){this.displayed=!1},groupCurrentCommands(){const t=new Map;this.currentCommands.forEach(i=>{(i.group===null||i.group===void 0)&&(i.group=0),t.has(i.group)?t.get(i.group).push(i):t.set(i.group,[i])}),t.forEach(i=>i.sort((o,n)=>(o.position=o.position||0,n.position=n.position||0,o.position-n.position)));const e=[...t.keys()].sort((i,o)=>i-o).map(i=>t.get(i)).flat();this.currentCommands=e},isGroupIntersection(t){if(t===0)return!1;const e=this.currentCommands[t-1],i=this.currentCommands[t];return e.group<i.group},registerContextCommand(t){const e=this.typeCheckCommand(t);return this.contextCommands.push(e),t.id},registerCommand(t){const e=this.typeCheckCommand(t);return this.registeredCommands.push(e),t.id},unregisterCommand(t){return this.registeredCommands.find(e=>e.id===t)?(this.registeredCommands=this.registeredCommands.filter(e=>e.id!==t),!0):!1},preventDefault(){this.defaultPrevented=!0}}},S8i={key:0,class:"separator"},T8i={class:"menu-text"},D8i={key:1,class:"menu-picto"},R8i={key:0,class:"context-menu__spinner"};function L8i(t,e,i,o,n,r){const a=I("BIMDataIconChevron"),s=I("LiWrapper"),l=I("BIMDataSpinner"),c=li("click-away");return n.displayed&&(n.currentCommands.length||n.asyncPredicateRunning)?yt((M(),_("ul",{key:0,class:"bimdata-list context-menu",style:de(r.position)},[(M(!0),_(Xe,null,Bt(n.currentCommands,(d,u)=>(M(),J(s,{key:d.label,class:"context-menu__element",onClick:h=>r.executeCommand(d)},{default:N(()=>[r.isGroupIntersection(u)?(M(),_("div",S8i)):te("",!0),b("div",T8i,z(d.label),1),!d.component&&d.picto?(M(),_("span",D8i,z(d.picto),1)):d.component?(M(),J(a,{key:2,size:"xxs",class:"fill-primary"})):te("",!0)]),_:2},1032,["onClick"]))),128)),n.asyncPredicateRunning?(M(),_("li",R8i,[D(l)])):te("",!0)],4)),[[c,r.away]]):te("",!0)}const _8i=j(I8i,[["render",L8i],["__scopeId","data-v-5b87d4a3"]]),F8i={name:"ViewerHeader",inject:["$viewer"],props:{visible:{type:Boolean,default:!0}},setup(){const t=ct("$viewer"),e=Cr(new Map),i=n=>{if(!n.name)throw new TypeError("[Viewer Header] Content must have a name");if(e.has(n.name))throw new Error(`[Viewer Header] Content with name ${n.name} already exists`);e.set(n.name,n)},o=n=>e.has(n)?(e.delete(n),!0):!1;return{logo:t.uiSettings.bimdataLogo!==!1,version:t.uiSettings.version!==!1?t.version:null,headerContent:e,headerRightContentComponents:De(()=>Array.from(e.values()).filter(n=>n.position==="right").sort((n,r)=>n.order-r.order).map(n=>n.component)),headerLeftContentComponents:De(()=>Array.from(e.values()).filter(n=>n.position==="left").sort((n,r)=>n.order-r.order).map(n=>n.component)),addContent:i,removeContent:o}}},O8i={class:"viewer-header"},U8i={class:"viewer-header__content"},N8i={class:"viewer-header__content__left"},j8i={class:"viewer-header__content__right"},V8i={key:0,class:"m-l-6 flex items-center"},H8i={key:1,class:"viewer-header__version"};function z8i(t,e,i,o,n,r){const a=I("BIMDataIllustration");return yt((M(),_("div",O8i,[b("div",U8i,[b("div",N8i,[(M(!0),_(Xe,null,Bt(o.headerLeftContentComponents,s=>(M(),J(Mo(s),{key:s.name}))),128))]),b("div",j8i,[(M(!0),_(Xe,null,Bt(o.headerRightContentComponents,s=>(M(),J(Mo(s),{key:s.name}))),128))])]),o.logo||o.version?(M(),_("div",V8i,[o.logo?(M(),J(a,{key:0,name:"logo",width:"30px",height:"30px"})):te("",!0),o.version?(M(),_("div",H8i,z(o.version),1)):te("",!0)])):te("",!0)],512)),[[zt,i.visible]])}const q8i=j(F8i,[["render",z8i],["__scopeId","data-v-5c9ea6b6"]]),Q8i={emits:["resize"],setup(t,{emit:e}){return{onResizerMousedown:i=>{i.preventDefault();let o=i.clientX;const n=a=>{a.preventDefault();const s=a.clientX-o;o=a.clientX,e("resize",s)},r=a=>{a.preventDefault(),window.removeEventListener("mousemove",n),window.removeEventListener("mouseup",r)};window.addEventListener("mousemove",n),window.addEventListener("mouseup",r)}}}},G8i={class:"bimdata-separator"};function K8i(t,e,i,o,n,r){return M(),_("div",G8i,[e[1]||(e[1]=b("div",{class:"bimdata-separator__line"},null,-1)),b("div",{class:"bimdata-separator__resizer",onMousedown:e[0]||(e[0]=(...a)=>o.onResizerMousedown&&o.onResizerMousedown(...a))},null,32)])}const J8i=j(Q8i,[["render",K8i],["__scopeId","data-v-79a3b3af"]]),Z8i={components:{Separator:J8i},props:{position:{type:String,required:!0,validator(t){return["left","right"].includes(t)}},sidePanel:{type:Object,required:!0,validator(t){if(t.width&&(typeof t.width!="number"||t.width<0))return console.error(`[GlobalSidePanel] sidePanel.width must be a strictly positive number, received ${typeof t.width}`),!1;const e=typeof t?.component=="object";return e||console.error("[GlobalSidePanel] sidePanel must have a component property"),e}}},setup(t){const e=le(null),i=le(t.sidePanel.width??400),o=(n,r=1)=>{const a=i.value+n*r;i.value=Math.max(0,a)};return pt(()=>t.sidePanel,()=>{Object.defineProperty(t.sidePanel,"width",{get(){return i.value},set(n){if(typeof n!="number"||n<=0){console.error(`[GlobalSidePanel] sidePanel.width must be a strictly positive number, received ${typeof n}`);return}i.value=n}}),Object.defineProperty(t.sidePanel,"componentInstance",{get(){return e.value},enumerable:!0})},{immediate:!0}),{componentInstance:e,width:i,onResize:o}}},W8i={class:"bimdata-global-side-panel__component"};function Y8i(t,e,i,o,n,r){const a=I("Separator");return M(),_("div",{class:"bimdata-global-side-panel",style:de(`width: ${o.width}px`)},[i.sidePanel.resizable&&i.position==="right"?(M(),J(a,{key:0,onResize:e[0]||(e[0]=s=>o.onResize(s,-1))})):te("",!0),b("div",W8i,[(M(),J(Mo(i.sidePanel.component),{ref:"componentInstance"},null,512))]),i.sidePanel.resizable&&i.position==="left"?(M(),J(a,{key:1,onResize:e[1]||(e[1]=s=>o.onResize(s))})):te("",!0)],4)}const X8i=j(Z8i,[["render",Y8i],["__scopeId","data-v-82d0d4cb"]]),$8i={name:"BimdataViewer",components:{ContextMenu:_8i,ViewerHeader:q8i,ModalManager:Ffe,GlobalSidePanel:X8i},setup(){const t=ct("$viewer"),{globalContext:e,shortcutManager:i}=t;wi(()=>{i&&i.destroy(),e.hub.clear()}),si(()=>{t.pluginManager.runPluginsScripts(t)});const o=De(()=>t.uiSettings.bimdataLogo!==!1&&(e.localContexts.length!==1||e.localContexts[0].window?.logoAndVersion)),n=De(()=>t.uiSettings.version!==!1&&(e.localContexts.length!==1||e.localContexts[0].window?.logoAndVersion)?t.version:null),r=De(()=>e.leftSidePanel),a=De(()=>e.rightSidePanel),s=De(()=>{const p=t.uiSettings.header!==!1,A=e.localContexts.length===1&&e.localContexts[0].window?.header===!1,f=!!(r.value||a.value);return p&&(!A||f)}),l=t.uiSettings.contextMenu!==!1,c=le(null);function d(p){l&&c.value.open(p)}function u(){t.shortcutManager.active=!0}function h(){t.shortcutManager.active=!1}return{Layout:t.layout.areas.component,onContextMenu:d,onMouseenter:u,onMouseleave:h,isHeaderVisible:s,viewerTemplateRef:e.templateRef,modalManagerTemplateRef:e.modalManagerTemplateRef,headerTemplateRef:e.headerTemplateRef,contextMenuTemplateRef:c,contextMenuEnabled:l,bimdataLogoOnSingleWindow:o,viewerVersionOnSingleWindow:n,version:t.version,loading:De(()=>e.loading),spinner:De(()=>e.spinner),leftSidePanel:r,rightSidePanel:a}}},eyi={key:1,class:"bimdata-context-loading-overlay",style:{"z-index":"3"}},tyi={key:2,class:"viewer__logo"},iyi={key:1,class:"version m-t-6"};function oyi(t,e,i,o,n,r){const a=I("ModalManager"),s=I("ContextMenu"),l=I("ViewerHeader"),c=I("GlobalSidePanel"),d=I("BIMDataSpinner"),u=I("BIMDataIllustration");return M(),_("div",{id:"bimdata-viewer",ref:"viewerTemplateRef",class:"bimdata-viewer bimdata-design-system bimdata-scrollbar",onContextmenu:e[0]||(e[0]=(...h)=>o.onContextMenu&&o.onContextMenu(...h)),onMouseenter:e[1]||(e[1]=(...h)=>o.onMouseenter&&o.onMouseenter(...h)),onMouseleave:e[2]||(e[2]=(...h)=>o.onMouseleave&&o.onMouseleave(...h))},[D(a,{ref:"modalManagerTemplateRef"},null,512),o.contextMenuEnabled?(M(),J(s,{key:0,ref:"contextMenuTemplateRef"},null,512)):te("",!0),D(l,{ref:"headerTemplateRef",visible:o.isHeaderVisible},null,8,["visible"]),b("div",{class:"bimdata-viewer__content",style:de(o.isHeaderVisible?"height: calc(100% - var(--bimdata-viewer-header-height, 40px))":"height: 100%")},[o.leftSidePanel?(M(),J(c,{key:0,"side-panel":o.leftSidePanel,position:"left"},null,8,["side-panel"])):te("",!0),(M(),J(Mo(o.Layout),{style:"height: 100%; flex-grow: 1;"})),o.rightSidePanel?(M(),J(c,{key:1,"side-panel":o.rightSidePanel,position:"right"},null,8,["side-panel"])):te("",!0)],4),o.loading?(M(),_("div",eyi,[o.spinner&&o.spinner.component?(M(),J(Mo(o.spinner.component),Ia(Cn({key:0},o.spinner.props)),null,16)):(M(),J(d,{key:1,size:"40px",border:"5px"}))])):te("",!0),!o.isHeaderVisible&&(o.bimdataLogoOnSingleWindow||o.viewerVersionOnSingleWindow)?(M(),_("div",tyi,[o.bimdataLogoOnSingleWindow?(M(),J(u,{key:0,name:"logo"})):te("",!0),o.viewerVersionOnSingleWindow?(M(),_("div",iyi,z(o.version),1)):te("",!0)])):te("",!0)],544)}const ryi=j($8i,[["render",oyi],["__scopeId","data-v-0c1c941a"]]),nyi=["src"],ayi={class:"bimdata-models__header"},syi={key:0,class:"bimdata-models__header__loader"},lyi={class:"bimdata-models__header__picto"},cyi={class:"bimdata-models__header__name"},dyi={key:0,class:"bimdata-models__header__name--empty"},uyi={key:1,class:"bimdata-models__header__name--empty"},hyi={key:3},pyi=["onMousemove","onClick"],fyi={__name:"Models",props:{preview:{type:Boolean,default:!1},windowPositioning:{type:Boolean,default:!0},customFilter:{type:Function,default:null},width:{type:String,default:"350px"}},setup(t){const e=t,i=ct("$viewer"),o=le(),n=le(0),r=le(0),a=le(),s=gi([]),l=le(!1),c=De(()=>i.localContext.loadedModels),d=De(()=>i.localContext.loadedModelIds),u=De(()=>i.localContext.loadingModelIds),h=De(()=>i.localContext.multiModel),p=De(()=>(e.customFilter?s.value.filter(e.customFilter):s.value).map(k=>c.value.find(B=>B.document?.head_id!=null&&B.document.head_id===k.document.id)??k)),A=k=>d.value.includes(k),f=k=>u.value.includes(k),m=De(()=>{const{x:k,y:B}=a.value?.getBoundingClientRect()??{x:0,y:0};return`top:${r.value-B}px; left:${n.value-k}px;`}),g=k=>{!h.value&&A(k.id)||u.value.length>0||(i.localContext.loadedModelIds.includes(k.id)?i.localContext.unloadModels([k.id]):i.localContext.loadModels([k.id]))},y=k=>{switch(k){case"C":return"success";case"E":return"failed";case"P":case"I":return"sandglass"}},v=(k,B)=>{k?.viewer_360_file&&(n.value=B.clientX,r.value=B.clientY),o.value=k?.viewer_360_file},w=async k=>{l.value=!0;try{return(await i.api.apiClient.modelApi.getModels(i.api.cloudId,i.api.projectId,void 0,void 0,k)).filter(B=>i.state.models.some(P=>P.archived)||!B.archived).sort($s("updated_at",!1))}catch(B){console.error("[Models] Cannot get project models. Error: ",B)}finally{l.value=!1}return[]},x=k=>k.children?.some(B=>A(B.id))??!1;return w(i.localContext.modelTypes).then(k=>{s.value=k}),(k,B)=>{const P=I("BIMDataSpinner"),E=I("BIMDataIconModel3D"),T=I("BIMDataTextbox"),S=I("BIMDataCheckbox"),R=I("BIMDataRadio"),F=I("BIMDataIcon"),U=I("BIMDataDropdownList");return M(),_("div",{ref_key:"templateRef",ref:a,class:ce(["bimdata-models",{"bimdata-models--window-positioning":t.windowPositioning}])},[o.value?(M(),_("div",{key:0,class:"bimdata-models__preview",style:de(m.value)},[b("img",{src:o.value},null,8,nyi)],4)):te("",!0),D(U,{style:de(`--bimdata-models-width: ${t.width};`),width:t.width,list:p.value,"element-key":"id","per-page":40,loading:l.value,class:"bimdata-models__list",disabled:p.value.length===0,onElementClick:g},{header:N(({isOpen:q})=>[b("div",ayi,[l.value||u.value.length>0?(M(),_("div",syi,[D(P)])):(M(),_(Xe,{key:1},[b("div",lyi,[D(E)]),b("div",{class:ce(["bimdata-models__header__number bimdata-info-length",{"bimdata-models__header__number--empty":d.value.length===0}])},[b("span",null,z(d.value.length),1)],2),b("div",cyi,[p.value.length===0?(M(),_("span",dyi,z(k.$t("model.no_model")),1)):d.value.length===0?(M(),_("span",uyi,z(k.$t("model.no_loaded_model")),1)):d.value.length===1?(M(),J(T,{key:2,text:c.value[0].name,tooltip:!q},null,8,["text","tooltip"])):d.value.length>1?(M(),_("span",hyi,z(k.$t("model.selected_models")),1)):te("",!0)])],64))])]),element:N(({element:q,close:V})=>[b("div",{class:"bimdata-models__model",onMousemove:W=>t.preview&&v(q,W),onMouseout:B[0]||(B[0]=W=>t.preview&&v()),onClick:()=>{!h.value&&!A(q.id)&&V()}},[h.value?(M(),J(S,{key:0,"model-value":A(q.id)||x(q),disabled:q.status!=="C"||u.value.length>0},null,8,["model-value","disabled"])):(M(),J(R,{key:1,"model-value":A(q.id)||x(q),disabled:q.status!=="C"||u.value.length>0},null,8,["model-value","disabled"])),D(F,{margin:"0 calc(var(--spacing-unit) / 2)",name:y(q.status),size:"xs",class:ce({"fill-success":q.status==="C","fill-high":q.status==="E"})},null,8,["name","class"]),D(T,{class:ce({"bimdata-models__model__name":!0,"bimdata-models__model__name--disabled":q.status!=="C"||u.value.length>0}),text:q.name,width:`calc(100% -
5317
+ `),onMouseenter:e[0]||(e[0]=(...h)=>o.onMouseEnter&&o.onMouseEnter(...h)),onMouseleave:e[1]||(e[1]=(...h)=>o.onMouseLeave&&o.onMouseLeave(...h))},[D(a,{ref:"modalManagerTemplateRef"},null,512),b("div",P6i,[o.windowPlugins.leftSidePanel?(M(),J(s,{key:0,plugin:o.windowPlugins.leftSidePanel},null,8,["plugin"])):te("",!0),b("div",I6i,[(M(!0),_(Xe,null,Bt(o.windowPlugins.free,h=>(M(),J(l,{key:h.name,class:ce({"window-container__content__center__viewer":h.isViewer}),plugin:h},null,8,["class","plugin"]))),128)),D(c,{position:"left",plugins:o.windowPlugins.leftButtonColumn},null,8,["plugins"]),D(c,{position:"right",plugins:o.windowPlugins.rightButtonColumn},null,8,["plugins"])]),o.windowPlugins.rightSidePanel?(M(),J(s,{key:1,plugin:o.windowPlugins.rightSidePanel},null,8,["plugin"])):te("",!0)]),o.loading?(M(),_("div",S6i,[o.spinner&&o.spinner.component?(M(),J(Mo(o.spinner.component),Ia(Cn({key:0},o.spinner.props)),null,16)):(M(),J(d,{key:1,size:"20px",border:"3px"}))])):te("",!0),o.layoutSettingsDisplayed?(M(),_("div",T6i,[D(u)])):te("",!0)],36)}const R6i=j(E6i,[["render",D6i],["__scopeId","data-v-485f288e"]]);class L6i{constructor(e=!0){const i=w5i(hV,null,{resizable:e});i.registerContent("default",R6i),this.settings=Cr({edit:!1,swap:!1,full:!1}),this.areas=i}get resizable(){return this.areas.resizable}set resizable(e){this.areas.resizable=e}apply(e=null){this.areas.layout=e?C5i(e):null}copy(e,i=!0){return x5i(this.areas.layout,e,i)}open({ratio:e,direction:i,insertAfter:o,windowName:n=null,windowState:r=null,localContextId:a=null}={}){const s=n?{options:{windowName:n,windowState:r}}:null;return a===null?this.areas.splitLayout(e,i,o,s):this.areas.split(a,e,i,o,s)}swap(e,i){return this.areas.swap(e,i)}close(e){return this.areas.delete(e)}compare(e,i){if(!e&&!i)return!0;if(!e||!i)return!1;if(typeof e=="string"&&typeof i=="string")return e===i;if(typeof e=="string"||typeof i=="string")return!1;if(e.windowName&&i.windowName){if(e.windowName!==i.windowName)return!1;const o=new Set(e.windowState?.modelIds),n=new Set(i.windowState?.modelIds);return o.size===n.size&&[...o].every(r=>n.has(r))}return e.windowName||i.windowName||e.direction!==i.direction||e.children.length!==i.children.length?!1:e.children.every((o,n)=>this.compare(o,i.children[n]))}}const _6i="2.15.0-beta.7",F6i={version:_6i};let O6i=1;class U6i{constructor({plugins:e,api:i,ui:o,locale:n="fr"}){this.instanceId=O6i++,this.pluginManager=new cmi(e),this.windowManager=new umi,this.windowManager.registerAndAddPluginsToWindows([...this.pluginManager.registeredPlugins.values()]),this.api=new E4i(i),this.globalContext=new u6e(this),this.state=j4i(this),this.shortcutManager=rge(this.state),this.uiSettings=o||{},this.i18n=new c6e(n),this._contextMenu=null,this.layout=new L6i(this.uiSettings.resizable!==!1),this._darkTheme=le(o?.darkTheme??!1),this.localContext=null,window.$viewer=this}get darkTheme(){return this._darkTheme.value}set darkTheme(e){this._darkTheme.value=e}get version(){return F6i.version}get locale(){return this.i18n.locale}get contextMenu(){return this._contextMenu||ige}set contextMenu(e){this._contextMenu=e}get registeredWindows(){return[...this.windowManager.registeredWindows.keys()]}get registeredPlugins(){return[...this.pluginManager.registeredPlugins.keys()]}get pluginsCfg(){return this.pluginManager.cfg}registerPlugin(e){this.pluginManager.registerPlugin(e),this.windowManager.registerAndAddPluginsToWindows([e])}}function N6i(t,e={}){e.backgroundColor&&(t.style.setProperty("--bimdata-viewer-background-color",e.backgroundColor),e.backgroundColor==="transparent"&&t.style.setProperty("--areas-separator-color","transparent")),e.colorPrimary&&t.style.setProperty("--color-primary",e.colorPrimary),e.colorPrimaryLighter&&t.style.setProperty("--color-primary-lighter",e.colorPrimaryLighter),e.colorPrimaryLight&&t.style.setProperty("--color-primary-light",e.colorPrimaryLight),e.colorPrimaryDark&&t.style.setProperty("--color-primary-dark",e.colorPrimaryDark),e.colorSecondary&&t.style.setProperty("--color-secondary",e.colorSecondary),e.colorSecondaryLighter&&t.style.setProperty("--color-secondary-lighter",e.colorSecondaryLighter),e.colorSecondaryLight&&t.style.setProperty("--color-secondary-light",e.colorSecondaryLight),e.colorSecondaryDark&&t.style.setProperty("--color-secondary-dark",e.colorSecondaryDark),e.colorSilverLight&&t.style.setProperty("--color-silver-light",e.colorSilverLight),e.colorSilver&&t.style.setProperty("--color-silver",e.colorSilver),e.colorSilverDark&&t.style.setProperty("--color-silver-dark",e.colorSilverDark),e.colorGraniteLight&&t.style.setProperty("--color-granite-light",e.colorGraniteLight),e.colorGranite&&t.style.setProperty("--color-granite",e.colorGranite),e.colorSuccess&&t.style.setProperty("--color-success",e.colorSuccess),e.colorSuccessLighter&&t.style.setProperty("--color-success-Lighter",e.colorSuccessLighter),e.colorSuccessLight&&t.style.setProperty("--color-success-Light",e.colorSuccessLight),e.colorSuccessDark&&t.style.setProperty("--color-success-Dark",e.colorSuccessDark),e.colorWarning&&t.style.setProperty("--color-warning",e.colorWarning),e.colorWarningLighter&&t.style.setProperty("--color-warning-Lighter",e.colorWarningLighter),e.colorWarningLight&&t.style.setProperty("--color-warning-Light",e.colorWarningLight),e.colorWarningDark&&t.style.setProperty("--color-warning-Dark",e.colorWarningDark),e.colorHigh&&t.style.setProperty("--color-high",e.colorHigh),e.colorHighLighter&&t.style.setProperty("--color-high-lighter",e.colorHighLighter),e.colorHighLight&&t.style.setProperty("--color-high-light",e.colorHighLight),e.colorHighDark&&t.style.setProperty("--color-high-dark",e.colorHighDark),e.colorText&&t.style.setProperty("--color-text",e.colorText),(!e.backgroundColor||e.backgroundColor!=="transparent")&&t.style.setProperty("--areas-separator-color","rgba(216, 216, 216, 1)"),e.headerHeight!=null&&t.style.setProperty("--bimdata-viewer-header-height",e.headerHeight),t.style.setProperty("--areas-background-color","transparent")}const j6i=Object.freeze({25:"GUEST",50:"USER",100:"ADMIN"}),tm=Object.freeze({READ:"read",WRITE:"write"});function Nfe(t){const e={};return t.forEach(i=>{const[o,n]=i.split(":");e[o]?e[o].push(n):e[o]=[n]}),e}const V6i={token_scopes:[],usable_scopes:[],user_role:25};function jfe(t=V6i){const e=Nfe(t.token_scopes),i=Nfe(t.usable_scopes);return{...dG(t),tokenScopes:e,usableScopes:i,userRole:j6i[t.user_role],user:t.user?dG(t.user):null,hasBcfReadPermission:i.bcf?.includes(tm.READ)??!1,hasBcfWritePermission:i.bcf?.includes(tm.WRITE)??!1,hasModelReadPermission:i.model?.includes(tm.READ)??!1,hasModelWritePermission:i.model?.includes(tm.WRITE)??!1,hasDocReadPermission:i.document?.includes(tm.READ)??!1,hasDocWritePermission:i.document?.includes(tm.WRITE)??!1}}const H6i={back:"Zur\xFCck",BcfFilters:{filtersButton:"Filter",filtersTitle:"Filter",priorityLabel:"Priorit\xE4t",statusLabel:"Status",stageLabel:"Phase",assignedToLabel:"Zugewiesen an",creatorsLabel:"Erstellt von",tagsLabel:"Tags",resetButton:"Zur\xFCcksetzen",searchButton:"Suchen",undefined:"Nicht definiert",datePlaceholder:"Erstellungsdatum"},BcfSettings:{title:"BCF-Parameter",text:"Erstellen, f\xFCllen und listen Sie die BCF-Einstellungen auf, die Sie f\xFCr dieses Projekt haben m\xF6chten.",validateButton:"Die BCF-Parameter anerkennen"},BcfStatistics:{emptyText:"F\xFCgen Sie Fragen hinzu, um zugeh\xF6rige Statistiken hier anzuzeigen.",issues:"Probleme",extension:{Priority:"Priorit\xE4t",PriorityNotDefined:"Keine Priorit\xE4t",PriorityTitle:"Priorit\xE4ten",Status:"Status",StatusNotDefined:"Kein Status",StatusTitle:"Status"}},BcfTopicCard:{priority:"Priorit\xE4t",noPriority:"Keine",assignedTo:"Zugewiesen an",elements:"Elemente",notSpecified:"Nicht definiert",see:"Anzeigen"},BcfTopicCreationCard:{text:"Ein neues BCF-Thema erstellen",createBcfSideTitle:"Ein Problem melden"},BcfTopicForm:{dragDropImageText:"Bitte w\xE4hlen Sie eine Datei aus.",addObjectButton:"Objekt",addAnnotationButton:"Annotation",annotationButtonTooltip:"Zu diesem Thema gibt es derzeit keine Ansichten.",addPictureButton:"F\xFCgen Sie ein Bild hinzu.",titlePlaceholder:"Titel *",titleErrorMessage:"Titel fehlt",typeLabel:"Typ",priorityLabel:"Priorit\xE4t",statusLabel:"Status",stageLabel:"Phase",assignedToLabel:"Zugewiesen an",dueDateLabel:"F\xE4lligkeitsdatum (TT.MM.JJJJ)",descriptionLabel:"Beschreibung",labelsLabel:"Tags",createButton:"Best\xE4tigen",updateButton:"\xC4nderungen \xFCbernehmen",modalText:"Sie sind dabei, die Bearbeitung der Ausgabe {Name} zu beenden, aber es gibt noch ungespeicherte \xC4nderungen.",cancelButton:"\xC4nderungen verwerfen",continueButton:"\xC4nderungen fortsetzen",createTitle:"Ein Problem melden",dragDropImageTextTablet:"Foto machen",takeSnapshot:"Mach einen Schnappschuss",importFile:"Eine Datei importieren",searchPlaceholder:"Suchen",emptySearch:"kein Ergebnis",documentsLabel:"Dokumente",documentsCount:"Dokumente \u2013 {count} ausgew\xE4hlte Dokumente",groupsLabel:"Berechtigungen",groupsCount:"Berechtigungen \u2013 {count} ausgew\xE4hlte Gruppen",groupsText:"W\xE4hlen Sie die Benutzergruppen aus, die dieses Thema sehen und damit interagieren d\xFCrfen.",validate:"Best\xE4tigen"},BcfTopicOverview:{openViewer:"Im Viewer \xF6ffnen",openViewerNoModels:"Es sind keine Vorlagen zur Ansicht bereit",elements:"{count} Elemente",noElements:"kein Element",type:"Typ",noTypeSpecified:"Kein Typ angegeben",description:"Beschreibung",noDescriptionProvided:"Keine Beschreibung angegeben",assignedTo:"Zugeteilt an",notAssigned:"Nicht zugewiesen",dueDate:"F\xE4lligkeitsdatum",noDueDate:"Kein F\xE4lligkeitsdatum",informations:"Informationen",status:"Status",noStatusSpecified:"Kein Status angegeben",stage:"Phase",noStageProvided:"Keine Phase angegeben",priority:"Priorit\xE4t",priorityNotDefined:"Nicht definiert",tags:"Tags",noTags:"Keine Tags",commentButton:"Ein Kommentar ver\xF6ffentlichen",deleteText:"Sie l\xF6schen jetzt {Name}",deleteBcfButton:"Dieses BCF l\xF6schen",keepBcfButton:"Dieses BCF beibehalten",author:"Autor"},BcfTopicsTable:{headers:{index:"#",priority:"Priorit\xE4t",status:"Status",title:"Titel",creator:"Autor",date:"Datum"}},BcfTopicActionsCell:{seeButton:"Anzeigen"},BcfTopicComments:{commentButton:"Ein Kommentar verfassen",commentLabel:"Ein Kommentar verfassen",commentText:"Kommentar",cancelButton:"Abbrechen",publishButton:"Ver\xF6ffentlichen",commentsText:"Kommentare",deleteCommentText:"Diesen Kommentar l\xF6schen?",deleteButton:"L\xF6schen",takeSnapshot:"Mach einen Schnappschuss",edited:"bearbeitet"},BcfTopicPriorityCell:{noPriority:"Keine"},SettingCard:{addButton:"ein Element hinzuf\xFCgen",cancelButton:"Abbrechen",validateButton:"Best\xE4tigen",deleteExtensionText:"Diesen Parameter l\xF6schen",deleteButton:"L\xF6schen",title:{Priority:"Priorit\xE4ten",Label:"Tags",Status:"Status",Type:"Typen",Stage:"Phasen"},input:{Priority:"Eine neue Priorit\xE4t hinzuf\xFCgen",Label:"Ein neues Etikett hinzuf\xFCgen",Status:"Einen neuen Status hinzuf\xFCgen",Type:"Einen neuen Typ hinzuf\xFCgen",Stage:"Eine neue Phase hinzuf\xFCgen"},text:{Priority:"Liste der Priorit\xE4ten",Label:"Liste von Tags",Status:"Liste der Status",Type:"Liste der Typen",Stage:"Liste der Phasen"}}},z6i={BcfComponents:H6i},q6i={back:"Back",BcfFilters:{filtersButton:"Filters",filtersTitle:"Filters",priorityLabel:"Priority",statusLabel:"Status",stageLabel:"Stage",assignedToLabel:"Assigned to",creatorsLabel:"Created by",tagsLabel:"Tags",resetButton:"Reset",searchButton:"Search",undefined:"Not defined",datePlaceholder:"Creation date"},BcfSettings:{title:"BCF Settings",text:"Create, enter in, and list the BCF settings you would like to have for this project",validateButton:"Validate BCF settings"},BcfStatistics:{emptyText:"Add BCF Topics to start to have some stats here.",issues:"issues",extension:{Priority:"Priority",PriorityNotDefined:"No priority",PriorityTitle:"Priorities",Status:"Status",StatusNotDefined:"No status",StatusTitle:"Status"}},BcfTopicCard:{priority:"Priority",noPriority:"None",assignedTo:"Assigned to",elements:"Elements",notSpecified:"Not specified",see:"See"},BcfTopicCreationCard:{text:"Create a new BCF topic",createBcfSideTitle:"Report a problem"},BcfTopicForm:{dragDropImageText:"Please select a file",addObjectButton:"Object",addAnnotationButton:"Annotation",annotationButtonTooltip:"This topic has no viewpoint",addPictureButton:"Add a picture",titlePlaceholder:"Title *",titleErrorMessage:"Missing title",typeLabel:"Type",priorityLabel:"Priority",statusLabel:"Status",stageLabel:"Stage",assignedToLabel:"Assigned to",dueDateLabel:"Due date",descriptionLabel:"Description",labelsLabel:"Tags",createButton:"Validate",updateButton:"Modify this BCF",modalText:"You are about to quit editing issue {name} but there are unsaved changes.",cancelButton:"Discard changes",continueButton:"Continue editing",createTitle:"Report a problem",dragDropImageTextTablet:"Take a picture",takeSnapshot:"Take a snapshot",importFile:"Import a file",searchPlaceholder:"Search",emptySearch:"No result",documentsLabel:"Add a file",documentsCount:"Files - {count} selected files",groupsLabel:"Permissions",groupsCount:"Permissions - {count} selected groups",groupsText:"You are now setting the access rights: choose the user group(s) that will be exclusively authorized to see and interact with this topic.",validate:"Validate"},BcfTopicOverview:{openViewer:"Open in viewer",openViewerNoModels:"No model to open",elements:"{count} Elements",noElements:"No element",type:"Type",noTypeSpecified:"No type specified",description:"Description",noDescriptionProvided:"No description provided",assignedTo:"Assigned to",notAssigned:"Not assigned",dueDate:"Due date",noDueDate:"No due date",informations:"Informations",status:"Status",noStatusSpecified:"No status specified",stage:"Stage",noStageProvided:"No stage provided",priority:"Priority",priorityNotDefined:"Not defined",tags:"Tags",noTags:"No tags",commentButton:"Post a comment",deleteText:"You are about to delete {name}",deleteBcfButton:"Delete this BCF",keepBcfButton:"Keep this BCF",author:"Author"},BcfTopicsTable:{headers:{index:"#",priority:"Priority",status:"Status",title:"Title",creator:"Author",date:"Date"}},BcfTopicActionsCell:{seeButton:"See"},BcfTopicComments:{commentButton:"Post a comment",commentLabel:"Post a comment",commentText:"Comment",cancelButton:"Cancel",publishButton:"Publish",commentsText:"Comments",deleteCommentText:"Delete this comment ?",deleteButton:"Delete",takeSnapshot:"Take a snapshot",edited:"edited"},BcfTopicPriorityCell:{noPriority:"None"},SettingCard:{addButton:"add an element",cancelButton:"Cancel",validateButton:"Validate",deleteExtensionText:"Remove this setting",deleteButton:"Delete",title:{Priority:"Priorities",Label:"Labels",Status:"Status",Type:"Types",Stage:"Stages"},input:{Priority:"Add a new priority",Label:"Add a new label",Status:"Add new status",Type:"Add a new type",Stage:"Add a new stage"},text:{Priority:"Priority list",Label:"Labels list",Status:"Status list",Type:"Type list",Stage:"Stage list"}}},Q6i={BcfComponents:q6i},G6i={back:"Volver",BcfFilters:{filtersButton:"Filtros",filtersTitle:"Filtros",priorityLabel:"Prioridad",statusLabel:"Estado",stageLabel:"Fase",assignedToLabel:"Asignado a",creatorsLabel:"Creado por",tagsLabel:"Etiquetas:",resetButton:"Restablecer",searchButton:"Buscar en",undefined:"No definido",datePlaceholder:"Fecha de creaci\xF3n"},BcfSettings:{title:"Par\xE1metros del BCF",text:"Cree, rellene y enumere los par\xE1metros del BCF que desea tener en este proyecto",validateButton:"Validar los par\xE1metros del BCF"},BcfStatistics:{emptyText:"A\xF1ada preguntas para ver las estad\xEDsticas asociadas aqu\xED.",issues:"problemas",extension:{Priority:"Prioridad",PriorityNotDefined:"Sin prioridad",PriorityTitle:"Prioridades",Status:"Estado",StatusNotDefined:"Sin estado",StatusTitle:"Estatutos"}},BcfTopicCard:{priority:"Prioridad",noPriority:"Sin",assignedTo:"Asignado a",elements:"Elementos",notSpecified:"No definido",see:"Ver"},BcfTopicCreationCard:{text:"Crear un nuevo tema BCF",createBcfSideTitle:"Informar de un problema"},BcfTopicForm:{dragDropImageText:"Seleccione un archivo",addObjectButton:"Objeto",addAnnotationButton:"Anotaci\xF3n",annotationButtonTooltip:"Actualmente este tema no posee ning\xFAn punto de vista",addPictureButton:"A\xF1adir una imagen",titlePlaceholder:"T\xEDtulo *",titleErrorMessage:"Falta el t\xEDtulo",typeLabel:"Tipo",priorityLabel:"Prioridad",statusLabel:"Estado",stageLabel:"Fase",assignedToLabel:"Asignado a",dueDateLabel:"Fecha de vencimiento (DD/MM/AAAA)",descriptionLabel:"Descripci\xF3n",labelsLabel:"Etiquetas",createButton:"Validar",updateButton:"Modificar este BCF",modalText:"Est\xE1 a punto de salir de la edici\xF3n del problema de {name} pero hay cambios sin guardar.",cancelButton:"Cancelar los cambios",continueButton:"Continuar con los cambios",createTitle:"Informar de un problema",dragDropImageTextTablet:"Tomar una fotograf\xEDa",takeSnapshot:"Tomar un snapshot",importFile:"Importar un archivo",searchPlaceholder:"Buscar",emptySearch:"No hay resultados"},BcfTopicOverview:{openViewer:"Abrir en el visor",openViewerNoModels:"No hay ning\xFAn modelo listo para la visualizaci\xF3n",elements:"{count} Elementos",noElements:"Ning\xFAn elemento",type:"Tipo",noTypeSpecified:"No se especifica el tipo",description:"Descripci\xF3n",noDescriptionProvided:"No hay descripci\xF3n",assignedTo:"Asignado a",notAssigned:"No asignado",dueDate:"Plazo",noDueDate:"Sin fecha de vencimiento",informations:"Informaci\xF3n",status:"Estado",noStatusSpecified:"No se especifica el estado",stage:"Fase",noStageProvided:"No se indica ninguna fase",priority:"Prioridad",priorityNotDefined:"No definido",tags:"Etiquetas",noTags:"Sin etiquetas",commentButton:"Publicar un comentario",deleteText:"Est\xE1s a punto de borrar {name}",deleteBcfButton:"Borrar este BCF",keepBcfButton:"Mantenga este BCF",author:"Autor"},BcfTopicsTable:{headers:{index:"#",priority:"Prioridad",status:"Estado",title:"T\xEDtulo",creator:"Autor",date:"Fecha"}},BcfTopicActionsCell:{seeButton:"Ver"},BcfTopicComments:{commentButton:"Publicar un comentario",commentLabel:"Publicar un comentario",commentText:"Comentario",cancelButton:"Cancelar",publishButton:"Publicar",commentsText:"comentarios",deleteCommentText:"\xBFBorrar este comentario?",deleteButton:"Borrar",takeSnapshot:"Tomar un snapshot"},BcfTopicPriorityCell:{noPriority:"Sin"},SettingCard:{addButton:"a\xF1adir un elemento",cancelButton:"Cancelar",validateButton:"Validar",deleteExtensionText:"Borrar esta configuraci\xF3n",deleteButton:"Borrar",title:{Priority:"Prioridades",Label:"Etiquetas:",Status:"Estatutos",Type:"Tipos",Stage:"Fases"},input:{Priority:"A\xF1adir una nueva prioridad",Label:"A\xF1adir una nueva etiqueta",Status:"A\xF1adir un nuevo estado",Type:"A\xF1adir un nuevo tipo",Stage:"A\xF1adir una nueva fase"},text:{Priority:"Lista de prioridades",Label:"Lista de etiquetas",Status:"Lista de estatutos",Type:"Lista de tipos",Stage:"Lista de fases"}}},K6i={BcfComponents:G6i},J6i={back:"Retour",BcfFilters:{filtersButton:"Filtres",filtersTitle:"Filtres",priorityLabel:"Priorit\xE9",statusLabel:"Statut",stageLabel:"Phase",assignedToLabel:"Assign\xE9 \xE0",creatorsLabel:"Cr\xE9\xE9 par",tagsLabel:"Tags",resetButton:"R\xE9initialiser",searchButton:"Rechercher",undefined:"Non d\xE9fini",datePlaceholder:"Date de cr\xE9ation"},BcfSettings:{title:"Param\xE8tres BCF",text:"Cr\xE9ez, renseignez et listez les param\xE8tres BCF que vous souhaitez avoir sur ce projet",validateButton:"Valider les param\xE8tres BCF"},BcfStatistics:{emptyText:"Ajoutez des questions pour voir les statistiques associ\xE9es ici.",issues:"probl\xE8mes",extension:{Priority:"Priorit\xE9",PriorityNotDefined:"Aucune priorit\xE9",PriorityTitle:"Priorit\xE9s",Status:"Statut",StatusNotDefined:"Aucun statut",StatusTitle:"Statuts"}},BcfTopicCard:{priority:"Priorit\xE9",noPriority:"Aucune",assignedTo:"Assign\xE9 \xE0",elements:"{n} \xC9lements",notSpecified:"Non d\xE9fini",see:"Voir"},BcfTopicCreationCard:{text:"Cr\xE9er un nouveau topic BCF",createBcfSideTitle:"Signaler un probl\xE8me"},BcfTopicForm:{dragDropImageText:"Veuillez s\xE9lectionner un fichier",addObjectButton:"Objet",addAnnotationButton:"Annotation",annotationButtonTooltip:"Ce topic ne poss\xE8de actuellement aucun point de vue",addPictureButton:"Ajouter une image",titlePlaceholder:"Titre *",titleErrorMessage:"Titre manquant",typeLabel:"Type",priorityLabel:"Priorit\xE9",statusLabel:"Statut",stageLabel:"Phase",assignedToLabel:"Assign\xE9 \xE0",dueDateLabel:"Date d'\xE9ch\xE9ance",descriptionLabel:"Description",labelsLabel:"Tags",createButton:"Valider",updateButton:"Modifier ce BCF",modalText:"Vous \xEAtes sur le point de quitter l'\xE9dition de l'issue {name} mais il y'a des modifications non enregistr\xE9es.",cancelButton:"Annuler les modifications",continueButton:"Continuer les modifications",createTitle:"Signaler un probl\xE8me",dragDropImageTextTablet:"Prendre une photo",takeSnapshot:"Prendre un snapshot",importFile:"Importer un fichier",searchPlaceholder:"Rechercher",emptySearch:"Pas de r\xE9sultat",documentsLabel:"Documents",documentsCount:"Documents - {count} documents s\xE9lectionn\xE9s",groupsLabel:"Permissions",groupsCount:"Permissions - {count} groupes s\xE9lectionn\xE9s",groupsText:"S\xE9lectionner les groupes utilisateur qui peuvent voir ce topic et int\xE9ragir avec.",validate:"Valider"},BcfTopicOverview:{openViewer:"Ouvrir dans le viewer",openViewerNoModels:"Il n'y a aucun mod\xE8le pr\xEAt pour une visualisation",elements:"{count} \xC9lements",noElements:"Aucun \xE9l\xE9ment concern\xE9",type:"Type",noTypeSpecified:"Pas de type sp\xE9cifi\xE9",description:"Description",noDescriptionProvided:"Pas de description renseign\xE9e",assignedTo:"Assign\xE9 \xE0",notAssigned:"Non assign\xE9",dueDate:"\xC9ch\xE9ance",noDueDate:"Pas de date d'\xE9ch\xE9ance",informations:"Informations",status:"Statut",noStatusSpecified:"Pas de statut sp\xE9cifi\xE9",stage:"Phase",noStageProvided:"Pas de phase renseign\xE9e",priority:"Priorit\xE9",priorityNotDefined:"Non d\xE9fini",tags:"Tags",noTags:"Pas de tags",commentButton:"Poster un commentaire",deleteText:"Vous \xEAtes sur le point de supprimer {name}",deleteBcfButton:"Supprimer ce BCF",keepBcfButton:"Conserver ce BCF",author:"Auteur"},BcfTopicsTable:{headers:{index:"#",priority:"Priorit\xE9",status:"Statut",title:"Titre",creator:"Auteur",date:"Date"}},BcfTopicActionsCell:{seeButton:"Voir"},BcfTopicComments:{commentButton:"Poster un commentaire",commentLabel:"Poster un commentaire",commentText:"Commentaire",cancelButton:"Annuler",publishButton:"Publier",commentsText:"commentaires",deleteCommentText:"Supprimer ce commentaire ?",deleteButton:"Supprimer",takeSnapshot:"Prendre un snapshot",edited:"edit\xE9"},BcfTopicPriorityCell:{noPriority:"Aucune"},SettingCard:{addButton:"ajouter un \xE9l\xE9ment",cancelButton:"Annuler",validateButton:"Valider",deleteExtensionText:"Supprimmer ce param\xE8tre",deleteButton:"Supprimer",title:{Priority:"Priorit\xE9s",Label:"Tags",Status:"Statuts",Type:"Types",Stage:"Phases"},input:{Priority:"Ajouter une nouvelle priorit\xE9",Label:"Ajouter un nouveau label",Status:"Ajouter un nouveau statut",Type:"Ajouter un nouveau type",Stage:"Ajouter une nouvelle phase"},text:{Priority:"Liste des priorit\xE9s",Label:"Liste des tags",Status:"Liste des statuts",Type:"Liste des types",Stage:"Liste des phases"}}},Z6i={BcfComponents:J6i},W6i={back:"Indietro",BcfFilters:{filtersButton:"Filtri",filtersTitle:"Filtri",priorityLabel:"Priorit\xE0",statusLabel:"Stato",stageLabel:"Fase",datePlaceholder:"Data di creazione",assignedToLabel:"Assegnato a",creatorsLabel:"Creato da",tagsLabel:"Etichette",resetButton:"Ripristina",searchButton:"Cerca",undefined:"Non definito"},BcfSettings:{title:"Parametri BCF",text:"Creare, notificare e elencare i parametri BCF che si desidera avere su questo progetto",validateButton:"Conferma i parametri BCF"},BcfStatistics:{emptyText:"Aggiungi delle domande per vedere le statistiche associate qui.",issues:"problemi",extension:{Priority:"Priorit\xE0",PriorityNotDefined:"Nessuna priorit\xE0",PriorityTitle:"Priorit\xE0",Status:"Stato",StatusNotDefined:"Nessuno stato",StatusTitle:"Stati"}},BcfTopicCard:{priority:"Priorit\xE0",noPriority:"Nessuno",assignedTo:"Assegnato a",elements:"Elementi",noElements:"0 elementi",notSpecified:"Non definito",see:"Visualizza"},BcfTopicCreationCard:{text:"Crea un nuovo topic BCF",createBcfSideTitle:"Segnala un problema"},BcfTopicForm:{dragDropImageText:"Selezionare un file",addObjectButton:"Oggetto",addAnnotationButton:"Annotazione",annotationButtonTooltip:"Attualmente questo argomento non presenta alcun punto di vista",addPictureButton:"Aggiungere un'immagine",titlePlaceholder:"Titolo *",titleErrorMessage:"Titolo mancante",typeLabel:"Tipo",priorityLabel:"Priorit\xE0",statusLabel:"Stato",stageLabel:"Fase",assignedToLabel:"Assegnato a",dueDateLabel:"Data di scadenza",descriptionLabel:"Descrizione",labelsLabel:"Tag",createButton:"Conferma",updateButton:"Modificare questo BCF",modalText:"State per abbandonare la modifica di {name} ma ci sono modifiche non salvate.",cancelButton:"Annullare le modifiche",continueButton:"Continuare le modifiche",createTitle:"Segnala un problema"},BcfTopicOverview:{openViewer:"Apri nel visualizzatore",openViewerNoModels:"Non esistono modelli pronti per la visualizzazione",elements:"{count} Elementi",noElements:"Nessun elemento",type:"Tipo",noTypeSpecified:"Nessun tipo specificato",description:"Descrizione",noDescriptionProvided:"Nessuna descrizione inserita",assignedTo:"Assegnato a",notAssigned:"Non assegnato",dueDate:"Scadenza",noDueDate:"Nessuna data di scadenza",informations:"Informazioni",status:"Stato",noStatusSpecified:"Nessuno stato specificato",stage:"Fase",noStageProvided:"Nessuna fase inserita",priority:"Priorit\xE0",priorityNotDefined:"Non definita",tags:"Etichette",noTags:"Nessuna etichetta",commentButton:"Pubblica un commento",deleteText:"Stai per eliminare {name}",deleteBcfButton:"Elimina questo BCF",keepBcfButton:"Conserva questo BCF",author:"Autore"},BcfTopicsTable:{headers:{index:"#",priority:"Priorit\xE0",status:"Stato",title:"Titolo",creator:"Autore",date:"Data"}},BcfTopicActionsCell:{seeButton:"Visualizza"},BcfTopicComments:{commentButton:"Pubblica un commento",commentLabel:"Pubblica un commento",commentText:"Commento",cancelButton:"Annulla",publishButton:"Pubblica",commentsText:"commenti",deleteCommentText:"Eliminare questo commento?",deleteButton:"Elimina"},BcfTopicPriorityCell:{noPriority:"Nessuno"},SettingCard:{addButton:"aggiungi un elemento",cancelButton:"Annulla",validateButton:"Conferma",deleteExtensionText:"Elimina questo parametro",deleteButton:"Elimina",title:{Priority:"Priorit\xE0",Label:"Etichette",Status:"Stati",Type:"Tipi",Stage:"Fasi"},input:{Priority:"Aggiungi una nuova priorit\xE0",Label:"Aggiungi una nuova etichetta",Status:"Aggiungi un nuovo stato",Type:"Aggiungi un nuovo tipo",Stage:"Aggiungi una nuova fase"},text:{Priority:"Elenco delle priorit\xE0",Label:"Elenco delle etichette",Status:"Elenco degli stati",Type:"Elenco dei tipi",Stage:"Elenco delle fasi"}}},Y6i={BcfComponents:W6i},X6i={de:z6i,en:Q6i,es:K6i,fr:Z6i,it:Y6i},$6i=({apiClient:t,fetchUsers:e,i18nPlugin:i}={})=>({install(o){t?Di.setup({apiClient:t,fetchUsers:e}):console.error("[BCF Components Plugin] No api client provided. You must provide an api client for the components to work properly."),i?Object.entries(X6i).forEach(([n,r])=>{i.global.mergeLocaleMessage(n,r)}):console.warn("[BCF Components Plugin] No i18n instance provided. You should either provide an i18n instance or define your own translations in order have text displayed properly."),Object.entries(iwe).forEach(([n,r])=>{o.component(n,r)})}}),e8i={title:"Building Maker",back:"Zur\xFCck",list:{text:"Erstellen und bearbeiten Sie die Etagen und laden Sie anschlie\xDFend Ihre PDFs herunter.",createButton:"Neues Projekt",updateButton:"Umbenennen",deleteButton:"L\xF6schen"},form:{text:"Erstellen und bearbeiten Sie die Etagen und laden Sie anschlie\xDFend Ihre PDFs herunter.",input:"Name des Geb\xE4udes",error:"Ung\xFCltiger Name",createButton:"Erstellen",updateButton:"Best\xE4tigen"},view:{addStoreyButton:"Etage",addPlanButton:"Grundriss",closeButton:"Fertigstellen",submitFilesButton:"Best\xE4tigen"},storeyForm:{title:"Neue Etage",input:"Name",error:"Ung\xFCltiger Name",cancelButton:"Abbrechen",submitButton:"Best\xE4tigen"}},t8i={creationFormTitle:"Ordner erstellen",renameFormPlaceholder:"Datei- / Ordnernam",nameInputPlaceholder:"Ordnername",emptyFolder:"Dieser Ordner ist leer",newFolderSuccess:"Neuer Ordner erstellt",renameFolderSuccess:"Umbenannter Ordner",deleteFolderSuccess:"Ordner gel\xF6scht",newFileSuccess:"Datei hinzugef\xFCgt",renameFileSuccess:"Umbenannte Datei",deleteFileSuccess:"Datei gel\xF6scht",nameInputErrorMessage:"Ung\xFCltiger name",cancel:"Abbrechen",submit:"Best\xE4tigen",buttonText:"Neuer Ordner",addFileButtonText:"Datei laden",rename:"Umbenennen",view:"Sehen",download:"Herunterladen",delete:"L\xF6schen",deleteTitle:"Dateien l\xF6schen",deleteDetail:"Sie sind im Begriff, die folgenden Dateien / Ordner endg\xFCltig zu l\xF6schen"},i8i={BuildingMaker:e8i,FileManager:t8i},o8i={t:{back:"Back",cancel:"Cancel",create:"Create",delete:"Delete",download:"Download",finish:"Finish",rename:"Rename",search:"Search",see:"View",storey:"Storey",validate:"Validate"}},r8i={title:"Building Maker",list:{text:"Create and edit storeys, then download your PDFs.",new:"New project"},form:{input:"Building name",error:"Invalid"},view:{addStorey:"Add Storey",addFile:"Add File",addPlan:"Add Plan"},storeyForm:{title:"New storey",input:"Name",error:"Invalid name"}},n8i={creationFormTitle:"Create folder",renameFormPlaceholder:"Folder/File name",nameInputPlaceholder:"Folder name",emptyFolder:"This folder is empty",newFolderSuccess:"New folder created",renameFolderSuccess:"Folder renamed",deleteFolderSuccess:"Folder deleted",newFileSuccess:"File added",renameFileSuccess:"File renamed",deleteFileSuccess:"File deleted",nameInputErrorMessage:"Invalid name",buttonText:"New folder",addFileButtonText:"Upload a file",deleteTitle:"Deleting Files",deleteDetail:"You are about to permanently delete the following files / folders",dmsRoot:"Root of the project's DMS",pdfPageSelectorTitle:"Select a page"},a8i={title:"Meta-Building Structure",tab:{structure:"Structure",zones:"Zones",equipments:"Equipments"},StoreySelector:{placeholder:"Select a storey"}},s8i={title:"Photosphere Building"},l8i={BIMDataComponents:o8i,BuildingMaker:r8i,FileManager:n8i,MetaBuildingStructure:a8i,PhotosphereBuilding:s8i},c8i={title:"Building Maker",back:"Vuelta",list:{text:"Cree y edite los pisos despu\xE9s cargue los PDF.",createButton:"Nuevo proyecto",updateButton:"Renombrar",deleteButton:"Suprimir"},form:{text:"Cree y edite los pisos despu\xE9s cargue los PDF.",input:"Nombre del edificio",error:"Nombre no v\xE1lido",createButton:"Crear",updateButton:"Validar"},view:{addStoreyButton:"Piso",addPlanButton:"Plano",closeButton:"Terminar",submitFilesButton:"Validar"},storeyForm:{title:"Nuevo piso",input:"Nombre",error:"Nombre no v\xE1lido",cancelButton:"Anular",submitButton:"Validar"}},d8i={creationFormTitle:"Crear un archivo",renameFormPlaceholder:"Nombre de archivo / carpeta",nameInputPlaceholder:"Nombre de la carpeta",emptyFolder:"Esta carpeta est\xE1 vac\xEDa",newFolderSuccess:"Nueva carpeta creada",renameFolderSuccess:"Carpeta renombrada",deleteFolderSuccess:"Carpeta eliminada",newFileSuccess:"Archivo agregado",renameFileSuccess:"Archivo renombrado",deleteFileSuccess:"Archivo eliminado",nameInputErrorMessage:"Nombre inv\xE1lida",cancel:"Cancelar",submit:"Validar",buttonText:"Carpeta nueva",addFileButtonText:"Cargar un archivo",rename:"Renombrar",view:"Ver",download:"Descargar",delete:"Borrar",deleteTitle:"Eliminar archivos",deleteDetail:"Est\xE1 a punto de eliminar permanentemente los siguientes archivos / carpetas"},u8i={BuildingMaker:c8i,FileManager:d8i},h8i={t:{back:"Retour",cancel:"Annuler",create:"Cr\xE9er",delete:"Supprimer",download:"T\xE9l\xE9charger",finish:"Terminer",rename:"Renommer",search:"Rechercher",see:"Voir",storey:"\xC9tage",validate:"Valider"}},p8i={title:"Building Maker",list:{text:"Cr\xE9ez et \xE9ditez les \xE9tages puis t\xE9l\xE9chagez vos PDF.",new:"Nouveau projet"},form:{input:"Nom du b\xE2timent",error:"Nom invalide"},view:{addStorey:"Ajouter un \xC9tage",addFile:"Ajouter un fichier",addPlan:"Ajouter un plan"},storeyForm:{title:"Nouvel \xE9tage",input:"Nom",error:"Nom invalide"}},f8i={creationFormTitle:"Cr\xE9er un dossier",renameFormPlaceholder:"Nom du fichier/dosier",nameInputPlaceholder:"Nom du dossier",emptyFolder:"Ce dossier est vide",newFolderSuccess:"Nouveau dossier cr\xE9\xE9",renameFolderSuccess:"Dossier renomm\xE9",deleteFolderSuccess:"Dossier supprim\xE9",newFileSuccess:"Fichier ajout\xE9",renameFileSuccess:"Fichier renomm\xE9",deleteFileSuccess:"Fichier supprim\xE9",nameInputErrorMessage:"Nom invalide",buttonText:"Nouveau dossier",addFileButtonText:"Charger un fichier",deleteTitle:"Supression de fichiers",deleteDetail:"Vous \xEAtes sur le point de supprimer d\xE9finitivement les fichiers/dossiers suivants",dmsRoot:"Racine de la GED du projet",pdfPageSelectorTitle:"S\xE9lectionner une page"},A8i={title:"Structure M\xE9ta-Building",tab:{structure:"Structure",zones:"Zones",equipments:"\xC9quipements"},StoreySelector:{placeholder:"S\xE9lectionner un \xE9tage"}},g8i={title:"Photosph\xE8re Building"},m8i={BIMDataComponents:h8i,BuildingMaker:p8i,FileManager:f8i,MetaBuildingStructure:A8i,PhotosphereBuilding:g8i},v8i={title:"Building Maker",back:"Reso",list:{text:"Crea e modifica i piani e poi scarica i tuoi PDF.",createButton:"Nuovo progetto",updateButton:"Rinominare",deleteButton:"Eliminare"},form:{text:"Crea e modifica i piani e poi scarica i tuoi PDF.",input:"Nome della costruzione",error:"Nome non corretto",createButton:"Creare",updateButton:"Convalidare"},view:{addStoreyButton:"Piano",addPlanButton:"Mappa",closeButton:"Finire",submitFilesButton:"Convalidare"},storeyForm:{title:"Nuovo piano",input:"Nome",error:"Nome non corretto",cancelButton:"Annullare",submitButton:"Convalidare"}},y8i={creationFormTitle:"Crea una cartella",renameFormPlaceholder:"Nome file/cartella",nameInputPlaceholder:"Nome della cartella",emptyFolder:"Questa cartella \xE8 vuota",newFolderSuccess:"Nuova cartella creata",renameFolderSuccess:"Cartella rinominata",deleteFolderSuccess:"Cartella eliminata",newFileSuccess:"File aggiunto",renameFileSuccess:"File rinominato",deleteFileSuccess:"File cancellato",nameInputErrorMessage:"Nome non valido",cancel:"Annulla",submit:"Invia",buttonText:"Nuova cartella",addFileButtonText:"Carica un file",rename:"Rinominare",view:"Vedere",download:"Scaricare",delete:"Cancellare",deleteTitle:"Eliminazione di file",deleteDetail:"Stai per eliminare definitivamente i seguenti file/cartelle"},b8i={BuildingMaker:v8i,FileManager:y8i},w8i={de:i8i,en:l8i,es:u8i,fr:m8i,it:b8i},C8i=({i18nPlugin:t}={})=>({install(e){t?Object.entries(w8i).forEach(([i,o])=>{t.global.mergeLocaleMessage(i,o)}):console.warn("[BIMData Components Plugin] No i18n instance provided. You should either provide an i18n instance or define your own translations in order have text displayed properly."),Object.entries(y$t).forEach(([i,o])=>{e.component(i,o)})}}),x8i={beforeMount(t,e){if(typeof e.value!="function")throw Error(`click away directive needs function, got ${typeof e.value}`);t.clickAwayHandler=i=>{(i.path||i.composedPath&&i.composedPath()).find(o=>o===t)||e.value()},window.addEventListener("mousedown",t.clickAwayHandler,!0)},unmounted(t){window.removeEventListener("mousedown",t.clickAwayHandler,!0),delete t.clickAwayHandler}},k8i=Object.freeze(Object.defineProperty({__proto__:null,BIMDataClickAway:Zs,BIMDataClickInputAway:x8i},Symbol.toStringTag,{value:"Module"})),M8i=t=>({install(e){Object.entries(GXe).forEach(([i,o])=>{e.component(i,o)}),Object.entries(k8i).forEach(([i,o])=>e.directive(i.split("BIMData")[1],o))}}),B8i={name:"LiWrapper",render(){return Qo("li",this.$slots.default())}};function E8i(t,e){var i=new Set([]);return t.forEach(o=>{e.has(o)||i.add(o)}),i}const Ml=Zr("id"),P8i=({contextMenu:t,objects:e=[],state:i=t.$viewer.state,pictos:o})=>[{name:"selectAll",get group(){return t.groupPositions.select},position:1,get label(){return t.$t("context_menu.select_all")},get picto(){return o.get(this.name)},execute:()=>i.selectObjects(e.filter(Fs(Pi("visible"),gu("selected"))).map(Ml)),predicate:()=>e.some(Fs(Pi("visible"),gu("selected")))},{name:"deselectAll",get group(){return t.groupPositions.select},position:2,get label(){return t.$t("context_menu.deselect_all")},get picto(){return o.get(this.name)},execute:()=>i.deselectObjects(e.filter(Pi("selected")).map(Ml)),predicate:()=>e.some(Pi("selected"))},{name:"selectSimilar",get group(){return t.groupPositions.select},position:3,get label(){return t.$t("context_menu.select_similar")},get picto(){return o.get(this.name)},execute(){const n=e.filter(r=>r.visible&&r.type===this.selectedObject.type&&r.id!==this.selectedObject.id).map(Ml);i.selectObjects(n)},selectedObject:null,predicate(){const n=e.filter(Fs(Pi("visible"),Pi("selected")));return n.length===1&&n[0].type!==void 0?(this.selectedObject=n[0],!0):(this.selectedObject=null,!1)}},{name:"reverseSelection",get label(){return t.$t("context_menu.reverse_selection")},get group(){return t.groupPositions.select},position:4,execute:()=>{const n=new Set(e.filter(Pi("selected")).map(Ml)),r=new Set(e.filter(Pi("visible")).map(Ml));i.selectObjects(Array.from(E8i(r,n)),{exclusive:!0})},predicate:()=>e.some(Fs(gu("selected"),Pi("visible")))&&e.some(Fs(Pi("selected"),Pi("visible")))},{name:"showAll",get group(){return t.groupPositions.visibility},position:1,get label(){return t.$t("context_menu.show_all")},get picto(){return o.get(this.name)},execute:()=>i.showObjects(e.filter(gu("visible")).map(Ml)),predicate:()=>e.some(gu("visible"))},{name:"hide",get group(){return t.groupPositions.visibility},position:2,get label(){return t.$t("context_menu.hide")},get picto(){return o.get(this.name)},objectsToHide:null,execute(){const n=this.objectsToHide.filter(Pi("selected"));n.length>0&&i.deselectObjects(n.map(Ml)),i.hideObjects(this.objectsToHide.map(Ml))},predicate(){return this.objectsToHide=e.filter(Fs(Pi("selected"),Pi("visible"))),this.objectsToHide.length>0}},{name:"hideAll",get group(){return t.groupPositions.visibility},position:3,get label(){return t.$t("context_menu.hide_all")},execute:()=>{const n=e.filter(Pi("visible"));n.some(Pi("selected"))&&i.deselectObjects(n.filter(Pi("selected")).map(Ml)),i.hideObjects(n.map(Ml))},predicate:()=>e.some(Pi("visible"))}].filter(n=>n.predicate()),I8i={components:{LiWrapper:B8i},inject:["$viewer"],data(){return{defaultPrevented:!1,displayed:!1,top:null,bottom:null,left:null,width:200,nextCommandId:1,currentCommands:[],contextCommands:[],registeredCommands:[],groupPositions:{select:10,visibility:20},asyncPredicateRunning:!1}},computed:{position(){return{top:this.top?this.top+"px":"unset",bottom:this.bottom?this.bottom+"px":"unset",left:this.left+"px",width:this.width+"px"}}},watch:{displayed(t){t?document.addEventListener("keydown",this.onKeyDown):document.removeEventListener("keydown",this.onKeyDown)}},created(){this.$viewer.contextMenu=this,this.asyncPredicates=new Set},methods:{onKeyDown(t){t.key==="Escape"&&this.away()},setPosition(t){const e=(document.fullscreenElement?document.fullscreenElement:this.$parent.$el).getBoundingClientRect();this.left=t.clientX-e.left,this.top=t.clientY-e.top,this.left+this.width>e.width&&(this.left=this.left-this.width),t.clientY>e.top+e.height/2?(this.bottom=e.height-this.top,this.top=null):this.bottom=null},typeCheckCommand(t={}){let e=null;if((!t.execute||typeof t.execute!="function")&!t.component&&(e="Cannot register context menu command. A command must have an execute function or a component property."),t.label||(e="Cannot register context menu command. A command must have a label."),e)throw console.error(e),new Error(e);return t.id=this.nextCommandId++,t},open(t){this.currentCommands=[],this.setPosition(t),this.originEvent=t,t.preventDefault(),this.setCurrentCommands(),this.groupCurrentCommands(),this.defaultPrevented=!1,this.displayed=!0,document.fullscreenElement?(this.$el.parentElement.removeChild(this.$el),this.adoptiveParent=document.fullscreenElement,this.adoptiveParent.appendChild(this.$el)):this.adoptiveParent&&this.adoptiveParent!==this.$viewer.globalContext.el&&(this.adoptiveParent.removeChild(this.$el),this.$viewer.globalContext.el.appendChild(this.$el),this.adoptiveParent=null)},setCurrentCommands(){this.asyncPredicates.clear(),this.asyncPredicateRunning=!1,this.defaultPrevented||this.registeredCommands.forEach(async t=>{if(typeof t.predicate=="function"){const e=t.predicate(this.$viewer.globalContext.activeLocalContext);if(e===!0)this.currentCommands.push(t);else if(typeof e?.then=="function"){this.asyncPredicates.add(e),this.asyncPredicateRunning=!0;const i=await e;this.asyncPredicates.has(e)&&(this.asyncPredicates.delete(e),this.asyncPredicateRunning=this.asyncPredicates.size>0,i===!0&&this.currentCommands.push(t))}}else this.currentCommands.push(t)}),this.currentCommands.push(...this.contextCommands),this.contextCommands=[]},getDefaultCommands({objects:t=[],state:e=this.$viewer.state,context:i=null}){const o=new Map;return i&&this.$viewer.shortcutManager.getShortcuts(i).forEach(n=>o.set(n.name,n.key)),P8i({contextMenu:this,objects:t,state:e,pictos:o})},executeCommand(t){if(t.execute&&(t.execute(this.originEvent),this.displayed=!1),t.component&&!t.menu)throw new Error("Command with component property must have a `menu` property")},away(){this.displayed=!1},groupCurrentCommands(){const t=new Map;this.currentCommands.forEach(i=>{(i.group===null||i.group===void 0)&&(i.group=0),t.has(i.group)?t.get(i.group).push(i):t.set(i.group,[i])}),t.forEach(i=>i.sort((o,n)=>(o.position=o.position||0,n.position=n.position||0,o.position-n.position)));const e=[...t.keys()].sort((i,o)=>i-o).map(i=>t.get(i)).flat();this.currentCommands=e},isGroupIntersection(t){if(t===0)return!1;const e=this.currentCommands[t-1],i=this.currentCommands[t];return e.group<i.group},registerContextCommand(t){const e=this.typeCheckCommand(t);return this.contextCommands.push(e),t.id},registerCommand(t){const e=this.typeCheckCommand(t);return this.registeredCommands.push(e),t.id},unregisterCommand(t){return this.registeredCommands.find(e=>e.id===t)?(this.registeredCommands=this.registeredCommands.filter(e=>e.id!==t),!0):!1},preventDefault(){this.defaultPrevented=!0}}},S8i={key:0,class:"separator"},T8i={class:"menu-text"},D8i={key:1,class:"menu-picto"},R8i={key:0,class:"context-menu__spinner"};function L8i(t,e,i,o,n,r){const a=I("BIMDataIconChevron"),s=I("LiWrapper"),l=I("BIMDataSpinner"),c=li("click-away");return n.displayed&&(n.currentCommands.length||n.asyncPredicateRunning)?yt((M(),_("ul",{key:0,class:"bimdata-list context-menu",style:de(r.position)},[(M(!0),_(Xe,null,Bt(n.currentCommands,(d,u)=>(M(),J(s,{key:d.label,class:"context-menu__element",onClick:h=>r.executeCommand(d)},{default:N(()=>[r.isGroupIntersection(u)?(M(),_("div",S8i)):te("",!0),b("div",T8i,z(d.label),1),!d.component&&d.picto?(M(),_("span",D8i,z(d.picto),1)):d.component?(M(),J(a,{key:2,size:"xxs",class:"fill-primary"})):te("",!0)]),_:2},1032,["onClick"]))),128)),n.asyncPredicateRunning?(M(),_("li",R8i,[D(l)])):te("",!0)],4)),[[c,r.away]]):te("",!0)}const _8i=j(I8i,[["render",L8i],["__scopeId","data-v-5b87d4a3"]]),F8i={name:"ViewerHeader",inject:["$viewer"],props:{visible:{type:Boolean,default:!0}},setup(){const t=ct("$viewer"),e=Cr(new Map),i=n=>{if(!n.name)throw new TypeError("[Viewer Header] Content must have a name");if(e.has(n.name))throw new Error(`[Viewer Header] Content with name ${n.name} already exists`);e.set(n.name,n)},o=n=>e.has(n)?(e.delete(n),!0):!1;return{logo:t.uiSettings.bimdataLogo!==!1,version:t.uiSettings.version!==!1?t.version:null,headerContent:e,headerRightContentComponents:De(()=>Array.from(e.values()).filter(n=>n.position==="right").sort((n,r)=>n.order-r.order).map(n=>n.component)),headerLeftContentComponents:De(()=>Array.from(e.values()).filter(n=>n.position==="left").sort((n,r)=>n.order-r.order).map(n=>n.component)),addContent:i,removeContent:o}}},O8i={class:"viewer-header"},U8i={class:"viewer-header__content"},N8i={class:"viewer-header__content__left"},j8i={class:"viewer-header__content__right"},V8i={key:0,class:"m-l-6 flex items-center"},H8i={key:1,class:"viewer-header__version"};function z8i(t,e,i,o,n,r){const a=I("BIMDataIllustration");return yt((M(),_("div",O8i,[b("div",U8i,[b("div",N8i,[(M(!0),_(Xe,null,Bt(o.headerLeftContentComponents,s=>(M(),J(Mo(s),{key:s.name}))),128))]),b("div",j8i,[(M(!0),_(Xe,null,Bt(o.headerRightContentComponents,s=>(M(),J(Mo(s),{key:s.name}))),128))])]),o.logo||o.version?(M(),_("div",V8i,[o.logo?(M(),J(a,{key:0,name:"logo",width:"30px",height:"30px"})):te("",!0),o.version?(M(),_("div",H8i,z(o.version),1)):te("",!0)])):te("",!0)],512)),[[zt,i.visible]])}const q8i=j(F8i,[["render",z8i],["__scopeId","data-v-5c9ea6b6"]]),Q8i={emits:["resize"],setup(t,{emit:e}){return{onResizerMousedown:i=>{i.preventDefault();let o=i.clientX;const n=a=>{a.preventDefault();const s=a.clientX-o;o=a.clientX,e("resize",s)},r=a=>{a.preventDefault(),window.removeEventListener("mousemove",n),window.removeEventListener("mouseup",r)};window.addEventListener("mousemove",n),window.addEventListener("mouseup",r)}}}},G8i={class:"bimdata-separator"};function K8i(t,e,i,o,n,r){return M(),_("div",G8i,[e[1]||(e[1]=b("div",{class:"bimdata-separator__line"},null,-1)),b("div",{class:"bimdata-separator__resizer",onMousedown:e[0]||(e[0]=(...a)=>o.onResizerMousedown&&o.onResizerMousedown(...a))},null,32)])}const J8i=j(Q8i,[["render",K8i],["__scopeId","data-v-79a3b3af"]]),Z8i={components:{Separator:J8i},props:{position:{type:String,required:!0,validator(t){return["left","right"].includes(t)}},sidePanel:{type:Object,required:!0,validator(t){if(t.width&&(typeof t.width!="number"||t.width<0))return console.error(`[GlobalSidePanel] sidePanel.width must be a strictly positive number, received ${typeof t.width}`),!1;const e=typeof t?.component=="object";return e||console.error("[GlobalSidePanel] sidePanel must have a component property"),e}}},setup(t){const e=le(null),i=le(t.sidePanel.width??400),o=(n,r=1)=>{const a=i.value+n*r;i.value=Math.max(0,a)};return pt(()=>t.sidePanel,()=>{Object.defineProperty(t.sidePanel,"width",{get(){return i.value},set(n){if(typeof n!="number"||n<=0){console.error(`[GlobalSidePanel] sidePanel.width must be a strictly positive number, received ${typeof n}`);return}i.value=n}}),Object.defineProperty(t.sidePanel,"componentInstance",{get(){return e.value},enumerable:!0})},{immediate:!0}),{componentInstance:e,width:i,onResize:o}}},W8i={class:"bimdata-global-side-panel__component"};function Y8i(t,e,i,o,n,r){const a=I("Separator");return M(),_("div",{class:"bimdata-global-side-panel",style:de(`width: ${o.width}px`)},[i.sidePanel.resizable&&i.position==="right"?(M(),J(a,{key:0,onResize:e[0]||(e[0]=s=>o.onResize(s,-1))})):te("",!0),b("div",W8i,[(M(),J(Mo(i.sidePanel.component),{ref:"componentInstance"},null,512))]),i.sidePanel.resizable&&i.position==="left"?(M(),J(a,{key:1,onResize:e[1]||(e[1]=s=>o.onResize(s))})):te("",!0)],4)}const X8i=j(Z8i,[["render",Y8i],["__scopeId","data-v-82d0d4cb"]]),$8i={name:"BimdataViewer",components:{ContextMenu:_8i,ViewerHeader:q8i,ModalManager:Ffe,GlobalSidePanel:X8i},setup(){const t=ct("$viewer"),{globalContext:e,shortcutManager:i}=t;wi(()=>{i&&i.destroy(),e.hub.clear()}),si(()=>{t.pluginManager.runPluginsScripts(t)});const o=De(()=>t.uiSettings.bimdataLogo!==!1&&(e.localContexts.length!==1||e.localContexts[0].window?.logoAndVersion)),n=De(()=>t.uiSettings.version!==!1&&(e.localContexts.length!==1||e.localContexts[0].window?.logoAndVersion)?t.version:null),r=De(()=>e.leftSidePanel),a=De(()=>e.rightSidePanel),s=De(()=>{const p=t.uiSettings.header!==!1,A=e.localContexts.length===1&&e.localContexts[0].window?.header===!1,f=!!(r.value||a.value);return p&&(!A||f)}),l=t.uiSettings.contextMenu!==!1,c=le(null);function d(p){l&&c.value.open(p)}function u(){t.shortcutManager.active=!0}function h(){t.shortcutManager.active=!1}return{Layout:t.layout.areas.component,onContextMenu:d,onMouseenter:u,onMouseleave:h,isHeaderVisible:s,viewerTemplateRef:e.templateRef,modalManagerTemplateRef:e.modalManagerTemplateRef,headerTemplateRef:e.headerTemplateRef,contextMenuTemplateRef:c,contextMenuEnabled:l,bimdataLogoOnSingleWindow:o,viewerVersionOnSingleWindow:n,version:t.version,loading:De(()=>e.loading),spinner:De(()=>e.spinner),leftSidePanel:r,rightSidePanel:a}}},eyi={key:1,class:"bimdata-context-loading-overlay",style:{"z-index":"3"}},tyi={key:2,class:"viewer__logo"},iyi={key:1,class:"version m-t-6"};function oyi(t,e,i,o,n,r){const a=I("ModalManager"),s=I("ContextMenu"),l=I("ViewerHeader"),c=I("GlobalSidePanel"),d=I("BIMDataSpinner"),u=I("BIMDataIllustration");return M(),_("div",{id:"bimdata-viewer",ref:"viewerTemplateRef",class:"bimdata-viewer bimdata-design-system bimdata-scrollbar",onContextmenu:e[0]||(e[0]=(...h)=>o.onContextMenu&&o.onContextMenu(...h)),onMouseenter:e[1]||(e[1]=(...h)=>o.onMouseenter&&o.onMouseenter(...h)),onMouseleave:e[2]||(e[2]=(...h)=>o.onMouseleave&&o.onMouseleave(...h))},[D(a,{ref:"modalManagerTemplateRef"},null,512),o.contextMenuEnabled?(M(),J(s,{key:0,ref:"contextMenuTemplateRef"},null,512)):te("",!0),D(l,{ref:"headerTemplateRef",visible:o.isHeaderVisible},null,8,["visible"]),b("div",{class:"bimdata-viewer__content",style:de(o.isHeaderVisible?"height: calc(100% - var(--bimdata-viewer-header-height, 40px))":"height: 100%")},[o.leftSidePanel?(M(),J(c,{key:0,"side-panel":o.leftSidePanel,position:"left"},null,8,["side-panel"])):te("",!0),(M(),J(Mo(o.Layout),{style:"height: 100%; flex-grow: 1;"})),o.rightSidePanel?(M(),J(c,{key:1,"side-panel":o.rightSidePanel,position:"right"},null,8,["side-panel"])):te("",!0)],4),o.loading?(M(),_("div",eyi,[o.spinner&&o.spinner.component?(M(),J(Mo(o.spinner.component),Ia(Cn({key:0},o.spinner.props)),null,16)):(M(),J(d,{key:1,size:"40px",border:"5px"}))])):te("",!0),!o.isHeaderVisible&&(o.bimdataLogoOnSingleWindow||o.viewerVersionOnSingleWindow)?(M(),_("div",tyi,[o.bimdataLogoOnSingleWindow?(M(),J(u,{key:0,name:"logo"})):te("",!0),o.viewerVersionOnSingleWindow?(M(),_("div",iyi,z(o.version),1)):te("",!0)])):te("",!0)],544)}const ryi=j($8i,[["render",oyi],["__scopeId","data-v-0c1c941a"]]),nyi=["src"],ayi={class:"bimdata-models__header"},syi={key:0,class:"bimdata-models__header__loader"},lyi={class:"bimdata-models__header__picto"},cyi={class:"bimdata-models__header__name"},dyi={key:0,class:"bimdata-models__header__name--empty"},uyi={key:1,class:"bimdata-models__header__name--empty"},hyi={key:3},pyi=["onMousemove","onClick"],fyi={__name:"Models",props:{preview:{type:Boolean,default:!1},windowPositioning:{type:Boolean,default:!0},customFilter:{type:Function,default:null},width:{type:String,default:"350px"}},setup(t){const e=t,i=ct("$viewer"),o=le(),n=le(0),r=le(0),a=le(),s=gi([]),l=le(!1),c=De(()=>i.localContext.loadedModels),d=De(()=>i.localContext.loadedModelIds),u=De(()=>i.localContext.loadingModelIds),h=De(()=>i.localContext.multiModel),p=De(()=>(e.customFilter?s.value.filter(e.customFilter):s.value).map(k=>c.value.find(B=>B.document?.head_id!=null&&B.document.head_id===k.document.id)??k)),A=k=>d.value.includes(k),f=k=>u.value.includes(k),m=De(()=>{const{x:k,y:B}=a.value?.getBoundingClientRect()??{x:0,y:0};return`top:${r.value-B}px; left:${n.value-k}px;`}),g=k=>{!h.value&&A(k.id)||u.value.length>0||(i.localContext.loadedModelIds.includes(k.id)?i.localContext.unloadModels([k.id]):i.localContext.loadModels([k.id]))},y=k=>{switch(k){case"C":return"success";case"E":return"failed";case"P":case"I":return"sandglass"}},v=(k,B)=>{k?.viewer_360_file&&(n.value=B.clientX,r.value=B.clientY),o.value=k?.viewer_360_file},w=async k=>{l.value=!0;try{return(await i.api.apiClient.modelApi.getModels(i.api.cloudId,i.api.projectId,void 0,void 0,k)).filter(B=>i.state.models.some(P=>P.archived)||!B.archived).sort($s("updated_at",!1))}catch(B){console.error("[Models] Cannot get project models. Error: ",B)}finally{l.value=!1}return[]},x=k=>k.children?.some(B=>A(B.id))??!1;return w(i.localContext.modelTypes).then(k=>{s.value=k}),(k,B)=>{const P=I("BIMDataSpinner"),E=I("BIMDataIconModel3D"),T=I("BIMDataTextbox"),S=I("BIMDataCheckbox"),R=I("BIMDataRadio"),F=I("BIMDataIcon"),U=I("BIMDataDropdownList");return M(),_("div",{ref_key:"templateRef",ref:a,class:ce(["bimdata-models",{"bimdata-models--window-positioning":t.windowPositioning}])},[o.value?(M(),_("div",{key:0,class:"bimdata-models__preview",style:de(m.value)},[b("img",{src:o.value},null,8,nyi)],4)):te("",!0),D(U,{style:de(`--bimdata-models-width: ${t.width};`),width:t.width,list:p.value,"element-key":"id","per-page":40,loading:l.value,class:"bimdata-models__list",disabled:p.value.length===0,onElementClick:g},{header:N(({isOpen:q})=>[b("div",ayi,[l.value||u.value.length>0?(M(),_("div",syi,[D(P)])):(M(),_(Xe,{key:1},[b("div",lyi,[D(E)]),b("div",{class:ce(["bimdata-models__header__number bimdata-info-length",{"bimdata-models__header__number--empty":d.value.length===0}])},[b("span",null,z(d.value.length),1)],2),b("div",cyi,[p.value.length===0?(M(),_("span",dyi,z(k.$t("model.no_model")),1)):d.value.length===0?(M(),_("span",uyi,z(k.$t("model.no_loaded_model")),1)):d.value.length===1?(M(),J(T,{key:2,text:c.value[0].name,tooltip:!q},null,8,["text","tooltip"])):d.value.length>1?(M(),_("span",hyi,z(k.$t("model.selected_models")),1)):te("",!0)])],64))])]),element:N(({element:q,close:V})=>[b("div",{class:"bimdata-models__model",onMousemove:W=>t.preview&&v(q,W),onMouseout:B[0]||(B[0]=W=>t.preview&&v()),onClick:()=>{!h.value&&!A(q.id)&&V()}},[h.value?(M(),J(S,{key:0,"model-value":A(q.id)||x(q),disabled:q.status!=="C"||u.value.length>0},null,8,["model-value","disabled"])):(M(),J(R,{key:1,"model-value":A(q.id)||x(q),disabled:q.status!=="C"||u.value.length>0},null,8,["model-value","disabled"])),D(F,{margin:"0 calc(var(--spacing-unit) / 2)",name:y(q.status),size:"xs",class:ce({"fill-success":q.status==="C","fill-high":q.status==="E"})},null,8,["name","class"]),D(T,{class:ce({"bimdata-models__model__name":!0,"bimdata-models__model__name--disabled":q.status!=="C"||u.value.length>0}),text:q.name,width:`calc(100% -
5318
5318
  ${h.value?13:23}px - 2 * 6px - 16px)`},null,8,["class","text","width"]),q.document&&!q.document.is_head_version?(M(),J(F,{key:2,name:"versioning",fill:"",color:"default",size:"xs",margin:"0 0 0 6px"})):te("",!0)],40,pyi),f(q.id)?(M(),J(P,{key:0,class:"bimdata-models__model__spinner"})):te("",!0)]),_:1},8,["style","width","list","loading","disabled"])],2)}}},Vfe=j(fyi,[["__scopeId","data-v-34c2cf79"]]),Ayi="data:image/svg+xml,%3csvg%20width='16'%20height='21'%20viewBox='0%200%2016%2021'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M7.47193%202.76644C7.65699%202.84439%207.77716%203.02565%207.777%203.22661L7.77339%207.94624C7.77318%208.22238%207.54916%208.44655%207.27301%208.44693L2.4192%208.45366C2.21569%208.45394%202.03258%208.33085%201.95617%208.1424C1.87975%207.95394%201.92528%207.73773%202.07129%207.59566L6.92872%202.86931C7.0729%202.72902%207.28688%202.6885%207.47193%202.76644ZM3.65141%207.45195L6.77378%207.44762L6.7761%204.41157L3.65141%207.45195ZM5.81657%200.893911L6.02338%200.893274L13.3879%200.870595C14.679%200.866619%2015.7208%201.91642%2015.722%203.20083L15.2221%203.20237L15.722%203.20052L15.722%203.20083L15.745%2017.8999L15.745%2017.9002C15.7462%2019.1846%2014.7063%2020.2408%2013.4153%2020.2448L2.35929%2020.2788C1.07114%2020.2828%200.0171799%2019.2362%200.0159721%2017.9486L0.00563138%206.92409L0.00543684%206.71668L0.152103%206.56972L5.67032%201.04045L5.81657%200.893911ZM6.23113%201.89264L1.00582%207.12841L1.01597%2017.9455C1.01666%2018.6791%201.62068%2019.2811%202.35835%2019.2788L13.4143%2019.2448C14.1484%2019.2425%2014.7456%2018.6402%2014.745%2017.9035C14.745%2017.9034%2014.745%2017.9033%2014.745%2017.9033L14.722%203.20423L14.722%203.20391C14.7213%202.46716%2014.123%201.86833%2013.3888%201.87059L6.23113%201.89264Z'%20fill='%232F374A'/%3e%3c/svg%3e",gyi=["src"],myi={key:0,class:"bimdata-multi-model-loader__header-container"},vyi={key:0,class:"bimdata-multi-model-loader__header__loader"},yyi={class:"bimdata-multi-model-loader__header__picto"},byi=["src"],wyi={class:"bimdata-multi-model-loader__header__name"},Cyi={key:0,class:"bimdata-multi-model-loader__header__name--empty"},xyi={key:1,class:"bimdata-multi-model-loader__header__name--empty"},kyi={key:3},Myi={key:1,class:"bimdata-multi-model-loader__main"},Byi=["onMousemove","onClick"],Eyi={__name:"BIMDataMultiModelLoader",props:{preview:{type:Boolean,default:!1},windowPositioning:{type:Boolean,default:!0},customFilter:{type:Function,default:null},width:{type:String,default:"350px"}},setup(t){const e=t,i=ct("$viewer"),o=le(),n=le(0),r=le(0),a=le(),s=gi([]),l=le(!1),c=le(!0),d=R=>{R.key==="Escape"?c.value=!0:R.key==="Enter"&&P()};pt(c,R=>{R?(window.removeEventListener("keydown",d),v.clear(),y.clear(),o.value=null):window.addEventListener("keydown",d)});const u=De(()=>i.localContext.loadedModels),h=De(()=>i.localContext.loadedModelIds),p=De(()=>i.localContext.loadingModelIds),A=De(()=>i.localContext.multiModel),f=De(()=>(e.customFilter?s.value.filter(e.customFilter):s.value).map(R=>u.value.find(F=>F.document?.head_id!=null&&F.document.head_id===R.document.id)??R)),m=R=>h.value.includes(R),g=R=>p.value.includes(R),y=Cr(new Set),v=Cr(new Set),w=R=>R.children?.some(F=>m(F.id))??!1,x=R=>(m(R.id)||w(R)||y.has(R))&&!v.has(R),k=De(()=>{const{x:R,y:F}=a.value.getBoundingClientRect();return`top:${r.value-F}px; left:${n.value-R}px;`}),B=R=>{R.status==="C"&&(!A.value&&m(R.id)||(m(R.id)?v.has(R)?v.delete(R):v.add(R):y.has(R)?y.delete(R):y.add(R)))},P=()=>{y.size>0&&i.localContext.loadModels(Array.from(y).map(R=>R.id)),v.size>0&&i.localContext.unloadModels(Array.from(v).map(R=>R.id)),c.value=!0},E=R=>{switch(R){case"C":return"success";case"E":return"failed";case"P":case"I":return"sandglass"}},T=R=>R.document&&!R.document.is_head_version,S=(R,F)=>{!e.preview||c.value||(R?.viewer_360_file&&(n.value=F.clientX,r.value=F.clientY),o.value=R?.viewer_360_file)};return(async R=>{l.value=!0;try{return(await i.api.apiClient.modelApi.getModels(i.api.cloudId,i.api.projectId,void 0,void 0,R)).filter(F=>i.state.models.some(U=>U.archived)||!F.archived).sort($s("updated_at",!1))}catch(F){console.error("[Models] Cannot get project models. Error: ",F)}finally{l.value=!1}return[]})(i.localContext.modelTypes).then(R=>{s.value=R}),(R,F)=>{const U=I("BIMDataSpinner"),q=I("BIMDataTextbox"),V=I("BIMDataIconChevron"),W=I("BIMDataButton"),Y=I("BIMDataIconFileIfcPolychrome"),$=I("BIMDataCheckbox"),fe=I("BIMDataRadio"),Me=I("BIMDataIcon"),Se=I("BIMDataPaginatedList"),qe=li("click-away");return M(),_("div",{ref_key:"templateRef",ref:a,class:ce(["bimdata-multi-model-loader",{"bimdata-multi-model-loader--window-positioning":t.windowPositioning}])},[o.value?(M(),_("div",{key:0,class:"bimdata-multi-model-loader__preview",style:de(k.value)},[b("img",{src:o.value},null,8,gyi)],4)):te("",!0),D(pi,{name:"fade",mode:"out-in"},{default:N(()=>[c.value?(M(),_("div",myi,[gt(R.$slots,"left",{},void 0,!0),b("div",{class:"bimdata-multi-model-loader__header",onClick:F[0]||(F[0]=Qe=>c.value=!1)},[l.value||p.value.length>0?(M(),_("div",vyi,[D(U)])):(M(),_(Xe,{key:1},[b("div",yyi,[b("img",{src:ot(Ayi),alt:"file icon"},null,8,byi)]),b("div",{class:ce(["bimdata-multi-model-loader__header__number bimdata-info-length",{"bimdata-multi-model-loader__header__number--empty":h.value.length===0}])},[b("span",null,z(h.value.length),1)],2),b("div",wyi,[f.value.length===0?(M(),_("span",Cyi,z(R.$t("model.no_model")),1)):h.value.length===0?(M(),_("span",xyi,z(R.$t("model.no_loaded_model")),1)):h.value.length===1?(M(),J(q,{key:2,text:u.value[0].name,tooltip:c.value,width:"233px"},null,8,["text","tooltip"])):h.value.length>1?(M(),_("span",kyi,z(R.$t("model.selected_models")),1)):te("",!0)]),D(W,{color:"default",icon:"",radius:"",fill:"",width:"21px",height:"21px"},{default:N(()=>[D(V,{size:"xxxs"})]),_:1})],64))]),gt(R.$slots,"right",{},void 0,!0)])):yt((M(),_("div",Myi,[D(Se,{list:f.value,"per-page":10},{element:N(({element:Qe})=>[b("div",{class:ce(["bimdata-multi-model-loader__main__model",{"bimdata-multi-model-loader__main__model--disabled":Qe.status!=="C"}]),onMousemove:Ce=>S(Qe,Ce),onMouseout:F[1]||(F[1]=Ce=>S()),onClick:Ce=>B(Qe)},[D(Y,{fill:"",color:"default",size:"xs"}),A.value?(M(),J($,{key:0,"model-value":x(Qe),disabled:Qe.status!=="C"},null,8,["model-value","disabled"])):(M(),J(fe,{key:1,"model-value":x(Qe),disabled:Qe.status!=="C"},null,8,["model-value","disabled"])),D(q,{class:ce({"bimdata-multi-model-loader__main__model__name":!0,"bimdata-multi-model-loader__main__model__name--disabled":Qe.status!=="C"}),text:Qe.name,width:T(Qe)?"333px":"363px"},null,8,["class","text","width"]),T(Qe)?(M(),J(Me,{key:2,name:"versioning",fill:"",color:"default",size:"xs",margin:"0 0 0 6px"})):te("",!0),g(Qe.id)?(M(),J(U,{key:3,class:"bimdata-multi-model-loader__main__model__spinner"})):(M(),J(Me,{key:4,name:E(Qe.status),size:"xs",class:ce({"fill-success":Qe.status==="C","fill-high":Qe.status==="E"})},null,8,["name","class"]))],42,Byi)]),_:1},8,["list"]),D(W,{class:"bimdata-multi-model-loader__main__validate",width:"93px",color:"primary",fill:"",radius:"",disabled:ot(y).size===0&&ot(v).size===0,onClick:P},{default:N(()=>[Je(z(R.$t("global.validate")),1)]),_:1},8,["disabled"])])),[[qe,()=>c.value=!0]])]),_:3})],2)}}},Pyi=j(Eyi,[["__scopeId","data-v-44e6af66"]]),Iyi={data(){return{shown:!1}},mounted(){setTimeout(()=>{this.shown=!0},500)}};function Syi(t,e,i,o,n,r){const a=I("BIMDataIllustration");return M(),_("div",{class:"bimdata__no-model",style:de({"--no-model--opacity":n.shown?1:0})},[D(a,{name:"emptyViewer",x:"90",y:"90"}),b("span",null,z(t.$t("model.select_model")),1)],4)}const Hfe=j(Iyi,[["render",Syi],["__scopeId","data-v-5ffd9bc0"]]);window.BIMDataViewerVue=hV;class Tyi{constructor(e={}){const{api:i={},ui:o}=e;this.uiCfg=o,i.apiUrl||(console.info("[BIMData Viewer] INFO - Viewer config - `apiUrl` not set, use 'https://api.bimdata.io' by default."),i.apiUrl="https://api.bimdata.io"),i.archiveUrl||(console.info("[BIMData Viewer] INFO - Viewer config - `archiveUrl` not set, use 'https://archive.bimdata.io' by default."),i.archiveUrl="https://archive.bimdata.io"),i.pdfBackendUrl||(console.info("[BIMData Viewer] INFO - Viewer config - `pdfBackendUrl` not set, use 'https://pdf-backend.bimdata.io' by default."),i.pdfBackendUrl="https://pdf-backend.bimdata.io"),i.ifcIds&&(console.warn("[BIMData Viewer] DEPRECATED - Viewer config - please use the `modelIds` property instead of `ifcIds`."),i.modelIds===void 0&&(i.modelIds=i.ifcIds)),i.modelIds||(i.modelIds=[]),i.offline?.dataFile&&(i.offline.data=i.offline.dataFile),this.$viewer=new U6i(e),i.offline?.enabled?this.$viewer.api.enableOfflineMode(i.offline.data,i.offline.options).then(()=>this.state.loadModels(i.modelIds)):(this.$viewer.globalContext.loadingProcessStart(),this.state.loadModels(i.modelIds).finally(()=>this.$viewer.globalContext.loadingProcessEnd())),this.vueApp=null}get state(){return this.$viewer.state}get api(){return this.$viewer.api}async mount(e,i="3d"){const{$viewer:o}=this;await o.api.ready;try{const d=await o.api.apiClient.collaborationApi.checkProjectAccess(o.api.cloudId,o.api.projectId);o.api.permissions=jfe(d)}catch{o.api.permissions=jfe()}const n=this.api.accessToken,{i18n:r}=o;r.registerTranslations(o.pluginManager.pluginTranslations),o.layout.apply(i);const a={i18n:r.i18nVuePlugin,data(){return{accessToken:n}},render(){return Qo(ryi,{style:"height: 100%"})}},s=_m(a).use(r.i18nVuePlugin).use(M8i()).use(C8i({i18nPlugin:r.i18nVuePlugin})).use($6i({apiClient:o.api.apiClient,i18nPlugin:r.i18nVuePlugin}));s.provide("$viewer",o),s.provide("BIMDATA_DESIGN_SYSTEM_DARK_THEME",De(()=>o.darkTheme)),s.component("BIMDataModelLoader",Vfe),s.component("BIMDataMultiModelLoader",Pyi),s.component("BIMDataNoModelWindowPlaceHolder",Hfe),s.component("BIMDataStoreySelector",_E),s.component("ModelsLoader",Vfe),s.component("NoModelWindowPlaceHolder",Hfe);const l=e instanceof HTMLElement?e:document.querySelector(e);l&&(l.style.height="100%");const c=s.mount(e);return c.$viewer=o,N6i(c.$el,this.uiCfg?.style),typeof window<"u"&&(window.bimdataViewer=c),this.vueApp=s,c}destroy(){this.vueApp?.unmount()}setLocale(e){if(!IV.includes(e))throw new Error(`Viewer available locales are ${IV.join(", ")}.`);this.$viewer.i18n.locale=e}registerPlugin(e){this.$viewer.registerPlugin(e)}registerWindow(e){return this.$viewer.windowManager.registerWindow(e)}unregisterWindow(e){return this.$viewer.windowManager.unregisterWindow(e)}setAccessToken(e){this.api.accessToken=e}async loadModels(e){this.$viewer.globalContext.loadingProcessStart();const i=await this.state.loadModels(e);return this.$viewer.globalContext.loadingProcessEnd(),i}loadIfcs(e){return console.warn("[BIMData Viewer] DEPRECATED - Viewer - please use the loadModels method instead of loadIfcs."),this.loadModels(e)}}const zfe=(t={})=>new Tyi(t);window.makeBIMDataViewer=zfe;export{zfe as default};