@xtctwins/tctwins-bimx-viewer 1.0.6 → 1.0.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.
|
@@ -34,7 +34,7 @@ INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
|
34
34
|
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
35
35
|
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
36
36
|
PERFORMANCE OF THIS SOFTWARE.
|
|
37
|
-
***************************************************************************** */var bA=function(e,t){return bA=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i])},bA(e,t)};function wA(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function i(){this.constructor=e}bA(e,t),e.prototype=null===t?Object.create(t):(i.prototype=t.prototype,new i)}var xA=function(){return xA=Object.assign||function(e){for(var t,i=1,r=arguments.length;i<r;i++)for(var n in t=arguments[i])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e},xA.apply(this,arguments)};function BA(e,t,i,r){return new(i||(i=Promise))(function(n,s){function o(e){try{l(r.next(e))}catch(e){s(e)}}function a(e){try{l(r.throw(e))}catch(e){s(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof i?t:new i(function(e){e(t)})).then(o,a)}l((r=r.apply(e,t||[])).next())})}function PA(e,t){var i,r,n,s,o={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(s){return function(a){return function(s){if(i)throw new TypeError("Generator is already executing.");for(;o;)try{if(i=1,r&&(n=2&s[0]?r.return:s[0]?r.throw||((n=r.return)&&n.call(r),0):r.next)&&!(n=n.call(r,s[1])).done)return n;switch(r=0,n&&(s=[2&s[0],n.value]),s[0]){case 0:case 1:n=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!(n=o.trys,(n=n.length>0&&n[n.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!n||s[1]>n[0]&&s[1]<n[3])){o.label=s[1];break}if(6===s[0]&&o.label<n[1]){o.label=n[1],n=s;break}if(n&&o.label<n[2]){o.label=n[2],o.ops.push(s);break}n[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],r=0}finally{i=n=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,a])}}}function CA(e,t,i){if(i||2===arguments.length)for(var r,n=0,s=t.length;n<s;n++)!r&&n in t||(r||(r=Array.prototype.slice.call(t,0,n)),r[n]=t[n]);return e.concat(r||t)}for(var MA=function(){function e(e,t,i,r){this.left=e,this.top=t,this.width=i,this.height=r}return e.prototype.add=function(t,i,r,n){return new e(this.left+t,this.top+i,this.width+r,this.height+n)},e.fromClientRect=function(t,i){return new e(i.left+t.windowBounds.left,i.top+t.windowBounds.top,i.width,i.height)},e.fromDOMRectList=function(t,i){var r=Array.from(i).find(function(e){return 0!==e.width});return r?new e(r.left+t.windowBounds.left,r.top+t.windowBounds.top,r.width,r.height):e.EMPTY},e.EMPTY=new e(0,0,0,0),e}(),kA=function(e,t){return MA.fromClientRect(e,t.getBoundingClientRect())},EA=function(e){for(var t=[],i=0,r=e.length;i<r;){var n=e.charCodeAt(i++);if(n>=55296&&n<=56319&&i<r){var s=e.charCodeAt(i++);56320==(64512&s)?t.push(((1023&n)<<10)+(1023&s)+65536):(t.push(n),i--)}else t.push(n)}return t},SA=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];if(String.fromCodePoint)return String.fromCodePoint.apply(String,e);var i=e.length;if(!i)return"";for(var r=[],n=-1,s="";++n<i;){var o=e[n];o<=65535?r.push(o):(o-=65536,r.push(55296+(o>>10),o%1024+56320)),(n+1===i||r.length>16384)&&(s+=String.fromCharCode.apply(String,r),r.length=0)}return s},TA="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",IA="undefined"==typeof Uint8Array?[]:new Uint8Array(256),FA=0;FA<64;FA++)IA[TA.charCodeAt(FA)]=FA;for(var DA="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",RA="undefined"==typeof Uint8Array?[]:new Uint8Array(256),OA=0;OA<64;OA++)RA[DA.charCodeAt(OA)]=OA;for(var LA=function(e,t,i){return e.slice?e.slice(t,i):new Uint16Array(Array.prototype.slice.call(e,t,i))},jA=function(){function e(e,t,i,r,n,s){this.initialValue=e,this.errorValue=t,this.highStart=i,this.highValueIndex=r,this.index=n,this.data=s}return e.prototype.get=function(e){var t;if(e>=0){if(e<55296||e>56319&&e<=65535)return t=((t=this.index[e>>5])<<2)+(31&e),this.data[t];if(e<=65535)return t=((t=this.index[2048+(e-55296>>5)])<<2)+(31&e),this.data[t];if(e<this.highStart)return t=2080+(e>>11),t=this.index[t],t+=e>>5&63,t=((t=this.index[t])<<2)+(31&e),this.data[t];if(e<=1114111)return this.data[this.highValueIndex]}return this.errorValue},e}(),UA="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",NA="undefined"==typeof Uint8Array?[]:new Uint8Array(256),VA=0;VA<64;VA++)NA[UA.charCodeAt(VA)]=VA;var QA=10,HA=13,GA=15,zA=17,WA=18,KA=19,XA=20,qA=21,YA=22,JA=24,ZA=25,$A=26,ed=27,td=28,id=30,rd=32,nd=33,sd=34,od=35,ad=37,ld=38,ud=39,cd=40,hd=42,Ad=[9001,65288],dd="×",pd="÷",fd=function(e){var t,i,r,n=function(e){var t,i,r,n,s,o=.75*e.length,a=e.length,l=0;"="===e[e.length-1]&&(o--,"="===e[e.length-2]&&o--);var u="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof Uint8Array&&void 0!==Uint8Array.prototype.slice?new ArrayBuffer(o):new Array(o),c=Array.isArray(u)?u:new Uint8Array(u);for(t=0;t<a;t+=4)i=RA[e.charCodeAt(t)],r=RA[e.charCodeAt(t+1)],n=RA[e.charCodeAt(t+2)],s=RA[e.charCodeAt(t+3)],c[l++]=i<<2|r>>4,c[l++]=(15&r)<<4|n>>2,c[l++]=(3&n)<<6|63&s;return u}(e),s=Array.isArray(n)?function(e){for(var t=e.length,i=[],r=0;r<t;r+=4)i.push(e[r+3]<<24|e[r+2]<<16|e[r+1]<<8|e[r]);return i}(n):new Uint32Array(n),o=Array.isArray(n)?function(e){for(var t=e.length,i=[],r=0;r<t;r+=2)i.push(e[r+1]<<8|e[r]);return i}(n):new Uint16Array(n),a=LA(o,12,s[4]/2),l=2===s[5]?LA(o,(24+s[4])/2):(t=s,i=Math.ceil((24+s[4])/4),t.slice?t.slice(i,r):new Uint32Array(Array.prototype.slice.call(t,i,r)));return new jA(s[0],s[1],s[2],s[3],a,l)}("KwAAAAAAAAAACA4AUD0AADAgAAACAAAAAAAIABAAGABAAEgAUABYAGAAaABgAGgAYgBqAF8AZwBgAGgAcQB5AHUAfQCFAI0AlQCdAKIAqgCyALoAYABoAGAAaABgAGgAwgDKAGAAaADGAM4A0wDbAOEA6QDxAPkAAQEJAQ8BFwF1AH0AHAEkASwBNAE6AUIBQQFJAVEBWQFhAWgBcAF4ATAAgAGGAY4BlQGXAZ8BpwGvAbUBvQHFAc0B0wHbAeMB6wHxAfkBAQIJAvEBEQIZAiECKQIxAjgCQAJGAk4CVgJeAmQCbAJ0AnwCgQKJApECmQKgAqgCsAK4ArwCxAIwAMwC0wLbAjAA4wLrAvMC+AIAAwcDDwMwABcDHQMlAy0DNQN1AD0DQQNJA0kDSQNRA1EDVwNZA1kD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ywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAdgAGAALAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAdbB2MHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsB2kH0gZwB64EdQB1AHUAdQB1AHUAdQB1AHUHfQdgAIUHjQd1AHUAlQedB2AAYAClB6sHYACzB7YHvgfGB3UAzgfWBzMB3gfmB1EB7gf1B/0HlQENAQUIDQh1ABUIHQglCBcDLQg1CD0IRQhNCEEDUwh1AHUAdQBbCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZ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MAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAALAcsBywHLAcsBywHLAcsBywHLAcsB4oILAcsB44I0gaWCJ4Ipgh1AHUAqgiyCHUAdQB1AHUAdQB1AHUAdQB1AHUAtwh8AXUAvwh1AMUIyQjRCNkI4AjoCHUAdQB1AO4I9gj+CAYJDgkTCS0HGwkjCYIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiAAIAAAAFAAYABgAGIAXwBgAHEAdQBFAJUAogCyAKAAYABgAEIA4ABGANMA4QDxAMEBDwE1AFwBLAE6AQEBUQF4QkhCmEKoQrhCgAHIQsAB0MLAAcABwAHAAeDC6ABoAHDCwMMAAcABwAHAAdDDGMMAAcAB6MM4wwjDWMNow3jDaABoAGgAaABoAGgAaABoAGgAaABoAGgAaABoAGgAaABoAGgAaABoAEjDqABWw6bDqABpg6gAaABoAHcDvwOPA+gAaABfA/8DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DpcPAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcAB9cPKwkyCToJMAB1AHUAdQBCCUoJTQl1AFUJXAljCWcJawkwADAAMAAwAHMJdQB2CX4JdQCECYoJjgmWCXUAngkwAGAAYABxAHUApgn3A64JtAl1ALkJdQDACTAAMAAwADAAdQB1AHUAdQB1AHUAdQB1AHUAowYNBMUIMAAwADAAMADICcsJ0wnZCRUE4QkwAOkJ8An4CTAAMAB1AAAKvwh1AAgKDwoXCh8KdQAwACcKLgp1ADYKqAmICT4KRgowADAAdQB1AE4KMAB1AFYKdQBeCnUAZQowADAAMAAwADAAMAAwADAAMAAVBHUAbQowADAAdQC5CXUKMAAwAHwBxAijBogEMgF9CoQKiASMCpQKmgqIBKIKqgquCogEDQG2Cr4KxgrLCjAAMADTCtsKC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csBywHLAcsBywHdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AA0EMAC9DDAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAsBywHLAcsBywHLAcsBywHLQcwAMEMyAwsBywHLAcsBywHLAcsBywHLAcsBywHzAwwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwAHUAdQB1ANQM2QzhDDAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMABgAGAAYABgAGAAYABgAOkMYADxDGAA+AwADQYNYABhCWAAYAAODTAAMAAwADAAFg1gAGAAHg37AzAAMAAwADAAYABgACYNYAAsDTQNPA1gAEMNPg1LDWAAYABgAGAAYABgAGAAYABgAGAAUg1aDYsGVglhDV0NcQBnDW0NdQ15DWAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAlQCBDZUAiA2PDZcNMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAnw2nDTAAMAAwADAAMAAwAHUArw23DTAAMAAwADAAMAAwADAAMAAwADAAMAB1AL8NMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAB1AHUAdQB1AHUAdQDHDTAAYABgAM8NMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAA1w11ANwNMAAwAD0B5A0wADAAMAAwADAAMADsDfQN/A0EDgwOFA4wABsOMAAwADAAMAAwADAAMAAwANIG0gbSBtIG0gbSBtIG0gYjDigOwQUuDsEFMw7SBjoO0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtI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ABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABABLAEsASwBLAEsASwBLAEsASwBLABoAGQAZAB4AUABQAAQAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQABMAUAAEAAQABAAEAAQABAAEAB4AHgAEAAQABAAEAAQABABQAFAABAAEAB4ABAAEAAQABABQAFAASwBLAEsASwBLAEsASwBLAEsASwBQAFAAUAAeAB4AUAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwAeAFAABABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAFAAKwArACsAKwArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQAUABQAB4AHgAYABMAUAArACsABAAbABsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAFAABAAEAAQABAAEAFAABAAEAAQAUAAEAAQABAAEAAQAKwArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAArACsAHgArAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArACsAKwArACsAKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAB4ABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAUAAEAAQABAAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQAFAABAAEAA0ADQBLAEsASwBLAEsASwBLAEsASwBLAB4AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAArAFAAUABQAFAAUABQAFAAUAArACsAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUAArACsAKwBQAFAAUABQACsAKwAEAFAABAAEAAQABAAEAAQABAArACsABAAEACsAKwAEAAQABABQACsAKwArACsAKwArACsAKwAEACsAKwArACsAUABQACsAUABQAFAABAAEACsAKwBLAEsASwBLAEsASwBLAEsASwBLAFAAUAAaABoAUABQAFAAUABQAEwAHgAbAFAAHgAEACsAKwAEAAQABAArAFAAUABQAFAAUABQACsAKwArACsAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQACsAUABQACsAUABQACsAKwAEACsABAAEAAQABAAEACsAKwArACsABAAEACsAKwAEAAQABAArACsAKwAEACsAKwArACsAKwArACsAUABQAFAAUAArAFAAKwArACsAKwArACsAKwBLAEsASwBLAEsASwBLAEsASwBLAAQABABQAFAAUAAEAB4AKwArACsAKwArACsAKwArACsAKwAEAAQABAArAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQACsAUABQAFAAUABQACsAKwAEAFAABAAEAAQABAAEAAQABAAEACsABAAEAAQAKwAEAAQABAArACsAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAABAAEACsAKwBLAEsASwBLAEsASwBLAEsASwBLAB4AGwArACsAKwArACsAKwArAFAABAAEAAQABAAEAAQAKwAEAAQABAArAFAAUABQAFAAUABQAFAAUAArACsAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAArACsABAAEACsAKwAEAAQABAArACsAKwArACsAKwArAAQABAAEACsAKwArACsAUABQACsAUABQAFAABAAEACsAKwBLAEsASwBLAEsASwBLAEsASwBLAB4AUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArAAQAUAArAFAAUABQAFAAUABQACsAKwArAFAAUABQACsAUABQAFAAUAArACsAKwBQAFAAKwBQACsAUABQACsAKwArAFAAUAArACsAKwBQAFAAUAArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArAAQABAAEAAQABAArACsAKwAEAAQABAArAAQABAAEAAQAKwArAFAAKwArACsAKwArACsABAArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAUABQAFAAHgAeAB4AHgAeAB4AGwAeACsAKwArACsAKwAEAAQABAAEAAQAUABQAFAAUABQAFAAUABQACsAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAUAAEAAQABAAEAAQABAAEACsABAAEAAQAKwAEAAQABAAEACsAKwArACsAKwArACsABAAEACsAUABQAFAAKwArACsAKwArAFAAUAAEAAQAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAKwAOAFAAUABQAFAAUABQAFAAHgBQAAQABAAEAA4AUABQAFAAUABQAFAAUABQACsAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAKwArAAQAUAAEAAQABAAEAAQABAAEACsABAAEAAQAKwAEAAQABAAEACsAKwArACsAKwArACsABAAEACsAKwArACsAKwArACsAUAArAFAAUAAEAAQAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwBQAFAAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAFAABAAEAAQABAAEAAQABAArAAQABAAEACsABAAEAAQABABQAB4AKwArACsAKwBQAFAAUAAEAFAAUABQAFAAUABQAFAAUABQAFAABAAEACsAKwBLAEsASwBLAEsASwBLAEsASwBLAFAAUABQAFAAUABQAFAAUABQABoAUABQAFAAUABQAFAAKwAEAAQABAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQACsAUAArACsAUABQAFAAUABQAFAAUAArACsAKwAEACsAKwArACsABAAEAAQABAAEAAQAKwAEACsABAAEAAQABAAEAAQABAAEACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArAAQABAAeACsAKwArACsAKwArACsAKwArACsAKwArAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXAAqAFwAXAAqACoAKgAqACoAKgAqACsAKwArACsAGwBcAFwAXABcAFwAXABcACoAKgAqACoAKgAqACoAKgAeAEsASwBLAEsASwBLAEsASwBLAEsADQANACsAKwArACsAKwBcAFwAKwBcACsAXABcAFwAXABcACsAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACsAXAArAFwAXABcAFwAXABcAFwAXABcAFwAKgBcAFwAKgAqACoAKgAqACoAKgAqACoAXAArACsAXABcAFwAXABcACsAXAArACoAKgAqACoAKgAqACsAKwBLAEsASwBLAEsASwBLAEsASwBLACsAKwBcAFwAXABcAFAADgAOAA4ADgAeAA4ADgAJAA4ADgANAAkAEwATABMAEwATAAkAHgATAB4AHgAeAAQABAAeAB4AHgAeAB4AHgBLAEsASwBLAEsASwBLAEsASwBLAFAAUABQAFAAUABQAFAAUABQAFAADQAEAB4ABAAeAAQAFgARABYAEQAEAAQAUABQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQADQAEAAQABAAEAAQADQAEAAQAUABQAFAAUABQAAQABAAEAAQABAAEAAQABAAEAAQABAArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAArAA0ADQAeAB4AHgAeAB4AHgAEAB4AHgAeAB4AHgAeACsAHgAeAA4ADgANAA4AHgAeAB4AHgAeAAkACQArACsAKwArACsAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgBcAEsASwBLAEsASwBLAEsASwBLAEsADQANAB4AHgAeAB4AXABcAFwAXABcAFwAKgAqACoAKgBcAFwAXABcACoAKgAqAFwAKgAqACoAXABcACoAKgAqACoAKgAqACoAXABcAFwAKgAqACoAKgBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACoAKgAqACoAKgAqACoAKgAqACoAKgAqAFwAKgBLAEsASwBLAEsASwBLAEsASwBLACoAKgAqACoAKgAqAFAAUABQAFAAUABQACsAUAArACsAKwArACsAUAArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgBQAFAAUABQAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAUAArACsAUABQAFAAUABQAFAAUAArAFAAKwBQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAKwArAFAAUABQAFAAUABQAFAAKwBQACsAUABQAFAAUAArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsABAAEAAQAHgANAB4AHgAeAB4AHgAeAB4AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUAArACsADQBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAANAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAWABEAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAA0ADQANAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAAQABAAEACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAANAA0AKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUAArAAQABAArACsAKwArACsAKwArACsAKwArACsAKwBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqAA0ADQAVAFwADQAeAA0AGwBcACoAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwAeAB4AEwATAA0ADQAOAB4AEwATAB4ABAAEAAQACQArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUAAEAAQAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQAUAArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAArACsAKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArACsAHgArACsAKwATABMASwBLAEsASwBLAEsASwBLAEsASwBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXAArACsAXABcAFwAXABcACsAKwArACsAKwArACsAKwArACsAKwBcAFwAXABcAFwAXABcAFwAXABcAFwAXAArACsAKwArAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAXAArACsAKwAqACoAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAArACsAHgAeAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACoAKgAqACoAKgAqACoAKgAqACoAKwAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKwArAAQASwBLAEsASwBLAEsASwBLAEsASwArACsAKwArACsAKwBLAEsASwBLAEsASwBLAEsASwBLACsAKwArACsAKwArACoAKgAqACoAKgAqACoAXAAqACoAKgAqACoAKgArACsABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsABAAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABABQAFAAUABQAFAAUABQACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwANAA0AHgANAA0ADQANAB4AHgAeAB4AHgAeAB4AHgAeAB4ABAAEAAQABAAEAAQABAAEAAQAHgAeAB4AHgAeAB4AHgAeAB4AKwArACsABAAEAAQAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABABQAFAASwBLAEsASwBLAEsASwBLAEsASwBQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwAeAB4AHgAeAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArAA0ADQANAA0ADQBLAEsASwBLAEsASwBLAEsASwBLACsAKwArAFAAUABQAEsASwBLAEsASwBLAEsASwBLAEsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAA0ADQBQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUAAeAB4AHgAeAB4AHgAeAB4AKwArACsAKwArACsAKwArAAQABAAEAB4ABAAEAAQABAAEAAQABAAEAAQABAAEAAQABABQAFAAUABQAAQAUABQAFAAUABQAFAABABQAFAABAAEAAQAUAArACsAKwArACsABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsABAAEAAQABAAEAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwArAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAKwBQACsAUAArAFAAKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeACsAKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeA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AeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AUABQAFAAUAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAEAAQABAAeAB4AKwArACsAKwArABMADQANAA0AUAATAA0AUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAUAANACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXAA0ADQANAA0ADQANAA0ADQAeAA0AFgANAB4AHgAXABcAHgAeABcAFwAWABEAFgARABYAEQAWABEADQANAA0ADQATAFAADQANAB4ADQANAB4AHgAeAB4AHgAMAAwADQANAA0AHgANAA0AFgANAA0ADQANAA0ADQANAA0AHgANAB4ADQANAB4AHgAeACsAKwArACsAKwArACsAKwArACsAKwArACsAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACsAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAKwArACsAKwArACsAKwArACsAKwArACsAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAlACUAJQAlACUAJQAlACUAJQAlACUAJQArACsAKwArAA0AEQARACUAJQBHAFcAVwA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ArACsAKwAeAB4AUABQAFAAUABQAFAAUABQAFAAUABQAAQAUABQAFAABABQAFAAUABQAAQAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAAeAB4AHgAeAAQAKwArACsAUABQAFAAUABQAFAAHgAeABoAHgArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAADgAOABMAEwArACsAKwArACsAKwArACsABAAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwANAA0ASwBLAEsASwBLAEsASwBLAEsASwArACsAKwArACsAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABABQAFAAUABQAFAAUAAeAB4AHgBQAA4AUABQAAQAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAA0ADQBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArACsAKwArACsAKwArACsAKwArAB4AWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYACsAKwArAAQAHgAeAB4AHgAeAB4ADQANAA0AHgAeAB4AHgArAFAASwBLAEsASwBLAEsASwBLAEsASwArACsAKwArAB4AHgBcAFwAXABcAFwAKgBcAFwAXABcAFwAXABcAFwAXABcAEsASwBLAEsASwBLAEsASwBLAEsAXABcAFwAXABcACsAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwArAFAAUABQAAQAUABQAFAAUABQAFAAUABQAAQABAArACsASwBLAEsASwBLAEsASwBLAEsASwArACsAHgANAA0ADQBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAKgAqACoAXAAqACoAKgBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXAAqAFwAKgAqACoAXABcACoAKgBcAFwAXABcAFwAKgAqAFwAKgBcACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFwAXABcACoAKgBQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAA0ADQBQAFAAUAAEAAQAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUAArACsAUABQAFAAUABQAFAAKwArAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQADQAEAAQAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAVABVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBUAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVACsAKwArACsAKwArACsAKwArACsAKwArAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAKwArACsAKwBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAKwArACsAKwAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXACUAJQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAJQAlACUAJQAlACUAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAKwArACsAKwArAFYABABWAFYAVgBWAFYAVgBWAFYAVgBWAB4AVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgArAFYAVgBWAFYAVgArAFYAKwBWAFYAKwBWAFYAKwBWAFYAVgBWAFYAVgBWAFYAVgBWAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAEQAWAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUAAaAB4AKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAGAARABEAGAAYABMAEwAWABEAFAArACsAKwArACsAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACUAJQAlACUAJQAWABEAFgARABYAEQAWABEAFgARABYAEQAlACUAFgARACUAJQAlACUAJQAlACUAEQAlABEAKwAVABUAEwATACUAFgARABYAEQAWABEAJQAlACUAJQAlACUAJQAlACsAJQAbABoAJQArACsAKwArAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAAcAKwATACUAJQAbABoAJQAlABYAEQAlACUAEQAlABEAJQBXAFcAVwBXAFcAVwBXAFcAVwBXABUAFQAlACUAJQATACUAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXABYAJQARACUAJQAlAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwAWACUAEQAlABYAEQARABYAEQARABUAVwBRAFEAUQBRAFEAUQBRAFEAUQBRAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAEcARwArACsAVwBXAFcAVwBXAFcAKwArAFcAVwBXAFcAVwBXACsAKwBXAFcAVwBXAFcAVwArACsAVwBXAFcAKwArACsAGgAbACUAJQAlABsAGwArAB4AHgAeAB4AHgAeAB4AKwArACsAKwArACsAKwArACsAKwAEAAQABAAQAB0AKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsADQANAA0AKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArAB4AHgAeAB4AHgAeAB4AHgAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgBQAFAAHgAeAB4AKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAAQAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAA0AUABQAFAAUAArACsAKwArAFAAUABQAFAAUABQAFAAUAANAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwAeACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAKwArAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUAArACsAKwBQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwANAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAeAB4AUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUAArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArAA0AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAUABQAFAAUABQAAQABAAEACsABAAEACsAKwArACsAKwAEAAQABAAEAFAAUABQAFAAKwBQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAAQABAAEACsAKwArACsABABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAA0ADQANAA0ADQANAA0ADQAeACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAeAFAAUABQAFAAUABQAFAAUAAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAArACsAKwArAFAAUABQAFAAUAANAA0ADQANAA0ADQAUACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsADQANAA0ADQANAA0ADQBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAB4AHgAeAB4AKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAAQABAAEAAQAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUAArAAQABAANACsAKwBQAFAAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAAQABAAEAAQABAAEAAQABAAEAAQABABQAFAAUABQAB4AHgAeAB4AHgArACsAKwArACsAKwAEAAQABAAEAAQABAAEAA0ADQAeAB4AHgAeAB4AKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsABABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAAEAAQABAAEAAQABAAeAB4AHgANAA0ADQANACsAKwArACsAKwArACsAKwArACsAKwAeACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArACsAKwBLAEsASwBLAEsASwBLAEsASwBLACsAKwArACsAKwArAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsASwBLAEsASwBLAEsASwBLAEsASwANAA0ADQANAFAABAAEAFAAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAeAA4AUAArACsAKwArACsAKwArACsAKwAEAFAAUABQAFAADQANAB4ADQAEAAQABAAEAB4ABAAEAEsASwBLAEsASwBLAEsASwBLAEsAUAAOAFAADQANAA0AKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAANAA0AHgANAA0AHgAEACsAUABQAFAAUABQAFAAUAArAFAAKwBQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAA0AKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsABAAEAAQABAArAFAAUABQAFAAUABQAFAAUAArACsAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQACsAUABQAFAAUABQACsABAAEAFAABAAEAAQABAAEAAQABAArACsABAAEACsAKwAEAAQABAArACsAUAArACsAKwArACsAKwAEACsAKwArACsAKwBQAFAAUABQAFAABAAEACsAKwAEAAQABAAEAAQABAAEACsAKwArAAQABAAEAAQABAArACsAKwArACsAKwArACsAKwArACsABAAEAAQABAAEAAQABABQAFAAUABQAA0ADQANAA0AHgBLAEsASwBLAEsASwBLAEsASwBLAA0ADQArAB4ABABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAAQABAAEAFAAUAAeAFAAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAArACsABAAEAAQABAAEAAQABAAEAAQADgANAA0AEwATAB4AHgAeAA0ADQANAA0ADQANAA0ADQANAA0ADQANAA0ADQANAFAAUABQAFAABAAEACsAKwAEAA0ADQAeAFAAKwArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAFAAKwArACsAKwArACsAKwBLAEsASwBLAEsASwBLAEsASwBLACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAKwArACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwBcAFwADQANAA0AKgBQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAeACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwBQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAKwArAFAAKwArAFAAUABQAFAAUABQAFAAUAArAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQAKwAEAAQAKwArAAQABAAEAAQAUAAEAFAABAAEAA0ADQANACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAArACsABAAEAAQABAAEAAQABABQAA4AUAAEACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAABAAEAAQABAAEAAQABAAEAAQABABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAFAABAAEAAQABAAOAB4ADQANAA0ADQAOAB4ABAArACsAKwArACsAKwArACsAUAAEAAQABAAEAAQABAAEAAQABAAEAAQAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAA0ADQANAFAADgAOAA4ADQANACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEACsABAAEAAQABAAEAAQABAAEAFAADQANAA0ADQANACsAKwArACsAKwArACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwAOABMAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQACsAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAArACsAKwAEACsABAAEACsABAAEAAQABAAEAAQABABQAAQAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAKwBQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQAKwAEAAQAKwAEAAQABAAEAAQAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAeAB4AKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAB4AHgAeAB4AHgAeAB4AHgAaABoAGgAaAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwArACsAKwArACsAKwArAA0AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsADQANAA0ADQANACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAASABIAEgAQwBDAEMAUABQAFAAUABDAFAAUABQAEgAQwBIAEMAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAASABDAEMAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwAJAAkACQAJAAkACQAJABYAEQArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABIAEMAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwANAA0AKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAAQABAAEAAQABAANACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAA0ADQANAB4AHgAeAB4AHgAeAFAAUABQAFAADQAeACsAKwArACsAKwArACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwArAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAANAA0AHgAeACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwAEAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArACsAKwArACsAKwAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAARwBHABUARwAJACsAKwArACsAKwArACsAKwArACsAKwAEAAQAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXACsAKwArACsAKwArACsAKwBXAFcAVwBXAFcAVwBXAFcAVwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUQBRAFEAKwArACsAKwArACsAKwArACsAKwArACsAKwBRAFEAUQBRACsAKwArACsAKwArACsAKwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUAArACsAHgAEAAQADQAEAAQABAAEACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwArACsAKwArAB4AHgAeAB4AHgAeAB4AKwArAB4AHgAeAB4AHgAeAB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AAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgBQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAB4AHgAeAB4AHgAeAB4AHgAeACsAKwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAeAB4AHgAeAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAeAB4AHgAeAB4AHgAeAB4ABAAeAB4AHgAeAB4AHgAeAB4AHgAeAAQAHgAeAA0ADQANAA0AHgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAAQABAAEAAQAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAAQABAAEAAQABAAEAAQAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArAAQABAAEAAQABAAEAAQAKwAEAAQAKwAEAAQABAAEAAQAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwAEAAQABAAEAAQABAAEAFAAUABQAFAAUABQAFAAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwBQAB4AKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArABsAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwArAB4AHgAeAB4ABAAEAAQABAAEAAQABABQACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwArACsAKwArABYAFgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAGgBQAFAAUAAaAFAAUABQAFAAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAKwBQACsAKwBQACsAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAKwBQACsAUAArACsAKwArACsAKwBQACsAKwArACsAUAArAFAAKwBQACsAUABQAFAAKwBQAFAAKwBQACsAKwBQACsAUAArAFAAKwBQACsAUAArAFAAUAArAFAAKwArAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQAFAAUAArAFAAUABQAFAAKwBQACsAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAUABQAFAAKwBQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAeAB4AKwArACsAKwArACsAKwArACsAKwArACsAKwArAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8AJQAlACUAHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHgAeAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB4AHgAeACUAJQAlAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQApACkAKQApACkAKQApACkAKQApACkAKQApACkAKQApACkAKQApACkAKQApACkAKQApACkAJQAlACUAJQAlACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAeAB4AJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlAB4AHgAlACUAJQAlACUAHgAlACUAJQAlACUAIAAgACAAJQAlACAAJQAlACAAIAAgACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACEAIQAhACEAIQAlACUAIAAgACUAJQAgACAAIAAgACAAIAAgACAAIAAgACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAJQAlACUAIAAlACUAJQAlACAAIAAgACUAIAAgACAAJQAlACUAJQAlACUAJQAgACUAIAAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAHgAlAB4AJQAeACUAJQAlACUAJQAgACUAJQAlACUAHgAlAB4AHgAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlAB4AHgAeAB4AHgAeAB4AJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAeAB4AHgAeAB4AHgAeAB4AHgAeACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACAAIAAlACUAJQAlACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACAAJQAlACUAJQAgACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAHgAeAB4AHgAeAB4AHgAeACUAJQAlACUAJQAlACUAJQAlACUAJQAlACU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ArACsAKwArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAKwArAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXACUAJQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwAlACUAJQAlACUAJQAlACUAJQAlACUAVwBXACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAKwAEACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAA=="),gd=[id,36],md=[1,2,3,5],vd=[QA,8],_d=[ed,$A],yd=md.concat(vd),bd=[ld,ud,cd,sd,od],wd=[GA,HA],xd=function(e,t,i,r){var n=r[i];if(Array.isArray(e)?-1!==e.indexOf(n):e===n)for(var s=i;s<=r.length;){if((l=r[++s])===t)return!0;if(l!==QA)break}if(n===QA)for(s=i;s>0;){var o=r[--s];if(Array.isArray(e)?-1!==e.indexOf(o):e===o)for(var a=i;a<=r.length;){var l;if((l=r[++a])===t)return!0;if(l!==QA)break}if(o!==QA)break}return!1},Bd=function(e,t){for(var i=e;i>=0;){var r=t[i];if(r!==QA)return r;i--}return 0},Pd=function(e,t,i,r,n){if(0===i[r])return dd;var s=r-1;if(Array.isArray(n)&&!0===n[s])return dd;var o=s-1,a=s+1,l=t[s],u=o>=0?t[o]:0,c=t[a];if(2===l&&3===c)return dd;if(-1!==md.indexOf(l))return"!";if(-1!==md.indexOf(c))return dd;if(-1!==vd.indexOf(c))return dd;if(8===Bd(s,t))return pd;if(11===fd.get(e[s]))return dd;if((l===rd||l===nd)&&11===fd.get(e[a]))return dd;if(7===l||7===c)return dd;if(9===l)return dd;if(-1===[QA,HA,GA].indexOf(l)&&9===c)return dd;if(-1!==[zA,WA,KA,JA,td].indexOf(c))return dd;if(Bd(s,t)===YA)return dd;if(xd(23,YA,s,t))return dd;if(xd([zA,WA],qA,s,t))return dd;if(xd(12,12,s,t))return dd;if(l===QA)return pd;if(23===l||23===c)return dd;if(16===c||16===l)return pd;if(-1!==[HA,GA,qA].indexOf(c)||14===l)return dd;if(36===u&&-1!==wd.indexOf(l))return dd;if(l===td&&36===c)return dd;if(c===XA)return dd;if(-1!==gd.indexOf(c)&&l===ZA||-1!==gd.indexOf(l)&&c===ZA)return dd;if(l===ed&&-1!==[ad,rd,nd].indexOf(c)||-1!==[ad,rd,nd].indexOf(l)&&c===$A)return dd;if(-1!==gd.indexOf(l)&&-1!==_d.indexOf(c)||-1!==_d.indexOf(l)&&-1!==gd.indexOf(c))return dd;if(-1!==[ed,$A].indexOf(l)&&(c===ZA||-1!==[YA,GA].indexOf(c)&&t[a+1]===ZA)||-1!==[YA,GA].indexOf(l)&&c===ZA||l===ZA&&-1!==[ZA,td,JA].indexOf(c))return dd;if(-1!==[ZA,td,JA,zA,WA].indexOf(c))for(var h=s;h>=0;){if((A=t[h])===ZA)return dd;if(-1===[td,JA].indexOf(A))break;h--}if(-1!==[ed,$A].indexOf(c))for(h=-1!==[zA,WA].indexOf(l)?o:s;h>=0;){var A;if((A=t[h])===ZA)return dd;if(-1===[td,JA].indexOf(A))break;h--}if(ld===l&&-1!==[ld,ud,sd,od].indexOf(c)||-1!==[ud,sd].indexOf(l)&&-1!==[ud,cd].indexOf(c)||-1!==[cd,od].indexOf(l)&&c===cd)return dd;if(-1!==bd.indexOf(l)&&-1!==[XA,$A].indexOf(c)||-1!==bd.indexOf(c)&&l===ed)return dd;if(-1!==gd.indexOf(l)&&-1!==gd.indexOf(c))return dd;if(l===JA&&-1!==gd.indexOf(c))return dd;if(-1!==gd.concat(ZA).indexOf(l)&&c===YA&&-1===Ad.indexOf(e[a])||-1!==gd.concat(ZA).indexOf(c)&&l===WA)return dd;if(41===l&&41===c){for(var d=i[s],p=1;d>0&&41===t[--d];)p++;if(p%2!=0)return dd}return l===rd&&c===nd?dd:pd},Cd=function(e,t){t||(t={lineBreak:"normal",wordBreak:"normal"});var i=function(e,t){void 0===t&&(t="strict");var i=[],r=[],n=[];return e.forEach(function(e,s){var o=fd.get(e);if(o>50?(n.push(!0),o-=50):n.push(!1),-1!==["normal","auto","loose"].indexOf(t)&&-1!==[8208,8211,12316,12448].indexOf(e))return r.push(s),i.push(16);if(4===o||11===o){if(0===s)return r.push(s),i.push(id);var a=i[s-1];return-1===yd.indexOf(a)?(r.push(r[s-1]),i.push(a)):(r.push(s),i.push(id))}return r.push(s),31===o?i.push("strict"===t?qA:ad):o===hd||29===o?i.push(id):43===o?e>=131072&&e<=196605||e>=196608&&e<=262141?i.push(ad):i.push(id):void i.push(o)}),[r,i,n]}(e,t.lineBreak),r=i[0],n=i[1],s=i[2];"break-all"!==t.wordBreak&&"break-word"!==t.wordBreak||(n=n.map(function(e){return-1!==[ZA,id,hd].indexOf(e)?ad:e}));var o="keep-all"===t.wordBreak?s.map(function(t,i){return t&&e[i]>=19968&&e[i]<=40959}):void 0;return[r,n,o]},Md=function(){function e(e,t,i,r){this.codePoints=e,this.required="!"===t,this.start=i,this.end=r}return e.prototype.slice=function(){return SA.apply(void 0,this.codePoints.slice(this.start,this.end))},e}(),kd=45,Ed=43,Sd=-1,Td=function(e){return e>=48&&e<=57},Id=function(e){return Td(e)||e>=65&&e<=70||e>=97&&e<=102},Fd=function(e){return 10===e||9===e||32===e},Dd=function(e){return function(e){return function(e){return e>=97&&e<=122}(e)||function(e){return e>=65&&e<=90}(e)}(e)||function(e){return e>=128}(e)||95===e},Rd=function(e){return Dd(e)||Td(e)||e===kd},Od=function(e){return e>=0&&e<=8||11===e||e>=14&&e<=31||127===e},Ld=function(e,t){return 92===e&&10!==t},jd=function(e,t,i){return e===kd?Dd(t)||Ld(t,i):!!Dd(e)||!(92!==e||!Ld(e,t))},Ud=function(e,t,i){return e===Ed||e===kd?!!Td(t)||46===t&&Td(i):Td(46===e?t:e)},Nd=function(e){var t=0,i=1;e[t]!==Ed&&e[t]!==kd||(e[t]===kd&&(i=-1),t++);for(var r=[];Td(e[t]);)r.push(e[t++]);var n=r.length?parseInt(SA.apply(void 0,r),10):0;46===e[t]&&t++;for(var s=[];Td(e[t]);)s.push(e[t++]);var o=s.length,a=o?parseInt(SA.apply(void 0,s),10):0;69!==e[t]&&101!==e[t]||t++;var l=1;e[t]!==Ed&&e[t]!==kd||(e[t]===kd&&(l=-1),t++);for(var u=[];Td(e[t]);)u.push(e[t++]);var c=u.length?parseInt(SA.apply(void 0,u),10):0;return i*(n+a*Math.pow(10,-o))*Math.pow(10,l*c)},Vd={type:2},Qd={type:3},Hd={type:4},Gd={type:13},zd={type:8},Wd={type:21},Kd={type:9},Xd={type:10},qd={type:11},Yd={type:12},Jd={type:14},Zd={type:23},$d={type:1},ep={type:25},tp={type:24},ip={type:26},rp={type:27},np={type:28},sp={type:29},op={type:31},ap={type:32},lp=function(){function e(){this._value=[]}return e.prototype.write=function(e){this._value=this._value.concat(EA(e))},e.prototype.read=function(){for(var e=[],t=this.consumeToken();t!==ap;)e.push(t),t=this.consumeToken();return e},e.prototype.consumeToken=function(){var e=this.consumeCodePoint();switch(e){case 34:return this.consumeStringToken(34);case 35:var t=this.peekCodePoint(0),i=this.peekCodePoint(1),r=this.peekCodePoint(2);if(Rd(t)||Ld(i,r)){var n=jd(t,i,r)?2:1;return{type:5,value:this.consumeName(),flags:n}}break;case 36:if(61===this.peekCodePoint(0))return this.consumeCodePoint(),Gd;break;case 39:return this.consumeStringToken(39);case 40:return Vd;case 41:return Qd;case 42:if(61===this.peekCodePoint(0))return this.consumeCodePoint(),Jd;break;case Ed:if(Ud(e,this.peekCodePoint(0),this.peekCodePoint(1)))return this.reconsumeCodePoint(e),this.consumeNumericToken();break;case 44:return Hd;case kd:var s=e,o=this.peekCodePoint(0),a=this.peekCodePoint(1);if(Ud(s,o,a))return this.reconsumeCodePoint(e),this.consumeNumericToken();if(jd(s,o,a))return this.reconsumeCodePoint(e),this.consumeIdentLikeToken();if(o===kd&&62===a)return this.consumeCodePoint(),this.consumeCodePoint(),tp;break;case 46:if(Ud(e,this.peekCodePoint(0),this.peekCodePoint(1)))return this.reconsumeCodePoint(e),this.consumeNumericToken();break;case 47:if(42===this.peekCodePoint(0))for(this.consumeCodePoint();;){var l=this.consumeCodePoint();if(42===l&&47===(l=this.consumeCodePoint()))return this.consumeToken();if(l===Sd)return this.consumeToken()}break;case 58:return ip;case 59:return rp;case 60:if(33===this.peekCodePoint(0)&&this.peekCodePoint(1)===kd&&this.peekCodePoint(2)===kd)return this.consumeCodePoint(),this.consumeCodePoint(),ep;break;case 64:var u=this.peekCodePoint(0),c=this.peekCodePoint(1),h=this.peekCodePoint(2);if(jd(u,c,h))return{type:7,value:this.consumeName()};break;case 91:return np;case 92:if(Ld(e,this.peekCodePoint(0)))return this.reconsumeCodePoint(e),this.consumeIdentLikeToken();break;case 93:return sp;case 61:if(61===this.peekCodePoint(0))return this.consumeCodePoint(),zd;break;case 123:return qd;case 125:return Yd;case 117:case 85:var A=this.peekCodePoint(0),d=this.peekCodePoint(1);return A!==Ed||!Id(d)&&63!==d||(this.consumeCodePoint(),this.consumeUnicodeRangeToken()),this.reconsumeCodePoint(e),this.consumeIdentLikeToken();case 124:if(61===this.peekCodePoint(0))return this.consumeCodePoint(),Kd;if(124===this.peekCodePoint(0))return this.consumeCodePoint(),Wd;break;case 126:if(61===this.peekCodePoint(0))return this.consumeCodePoint(),Xd;break;case Sd:return ap}return Fd(e)?(this.consumeWhiteSpace(),op):Td(e)?(this.reconsumeCodePoint(e),this.consumeNumericToken()):Dd(e)?(this.reconsumeCodePoint(e),this.consumeIdentLikeToken()):{type:6,value:SA(e)}},e.prototype.consumeCodePoint=function(){var e=this._value.shift();return void 0===e?-1:e},e.prototype.reconsumeCodePoint=function(e){this._value.unshift(e)},e.prototype.peekCodePoint=function(e){return e>=this._value.length?-1:this._value[e]},e.prototype.consumeUnicodeRangeToken=function(){for(var e=[],t=this.consumeCodePoint();Id(t)&&e.length<6;)e.push(t),t=this.consumeCodePoint();for(var i=!1;63===t&&e.length<6;)e.push(t),t=this.consumeCodePoint(),i=!0;if(i)return{type:30,start:parseInt(SA.apply(void 0,e.map(function(e){return 63===e?48:e})),16),end:parseInt(SA.apply(void 0,e.map(function(e){return 63===e?70:e})),16)};var r=parseInt(SA.apply(void 0,e),16);if(this.peekCodePoint(0)===kd&&Id(this.peekCodePoint(1))){this.consumeCodePoint(),t=this.consumeCodePoint();for(var n=[];Id(t)&&n.length<6;)n.push(t),t=this.consumeCodePoint();return{type:30,start:r,end:parseInt(SA.apply(void 0,n),16)}}return{type:30,start:r,end:r}},e.prototype.consumeIdentLikeToken=function(){var e=this.consumeName();return"url"===e.toLowerCase()&&40===this.peekCodePoint(0)?(this.consumeCodePoint(),this.consumeUrlToken()):40===this.peekCodePoint(0)?(this.consumeCodePoint(),{type:19,value:e}):{type:20,value:e}},e.prototype.consumeUrlToken=function(){var e=[];if(this.consumeWhiteSpace(),this.peekCodePoint(0)===Sd)return{type:22,value:""};var t=this.peekCodePoint(0);if(39===t||34===t){var i=this.consumeStringToken(this.consumeCodePoint());return 0===i.type&&(this.consumeWhiteSpace(),this.peekCodePoint(0)===Sd||41===this.peekCodePoint(0))?(this.consumeCodePoint(),{type:22,value:i.value}):(this.consumeBadUrlRemnants(),Zd)}for(;;){var r=this.consumeCodePoint();if(r===Sd||41===r)return{type:22,value:SA.apply(void 0,e)};if(Fd(r))return this.consumeWhiteSpace(),this.peekCodePoint(0)===Sd||41===this.peekCodePoint(0)?(this.consumeCodePoint(),{type:22,value:SA.apply(void 0,e)}):(this.consumeBadUrlRemnants(),Zd);if(34===r||39===r||40===r||Od(r))return this.consumeBadUrlRemnants(),Zd;if(92===r){if(!Ld(r,this.peekCodePoint(0)))return this.consumeBadUrlRemnants(),Zd;e.push(this.consumeEscapedCodePoint())}else e.push(r)}},e.prototype.consumeWhiteSpace=function(){for(;Fd(this.peekCodePoint(0));)this.consumeCodePoint()},e.prototype.consumeBadUrlRemnants=function(){for(;;){var e=this.consumeCodePoint();if(41===e||e===Sd)return;Ld(e,this.peekCodePoint(0))&&this.consumeEscapedCodePoint()}},e.prototype.consumeStringSlice=function(e){for(var t="";e>0;){var i=Math.min(5e4,e);t+=SA.apply(void 0,this._value.splice(0,i)),e-=i}return this._value.shift(),t},e.prototype.consumeStringToken=function(e){for(var t="",i=0;;){var r=this._value[i];if(r===Sd||void 0===r||r===e)return{type:0,value:t+=this.consumeStringSlice(i)};if(10===r)return this._value.splice(0,i),$d;if(92===r){var n=this._value[i+1];n!==Sd&&void 0!==n&&(10===n?(t+=this.consumeStringSlice(i),i=-1,this._value.shift()):Ld(r,n)&&(t+=this.consumeStringSlice(i),t+=SA(this.consumeEscapedCodePoint()),i=-1))}i++}},e.prototype.consumeNumber=function(){var e=[],t=4,i=this.peekCodePoint(0);for(i!==Ed&&i!==kd||e.push(this.consumeCodePoint());Td(this.peekCodePoint(0));)e.push(this.consumeCodePoint());i=this.peekCodePoint(0);var r=this.peekCodePoint(1);if(46===i&&Td(r))for(e.push(this.consumeCodePoint(),this.consumeCodePoint()),t=8;Td(this.peekCodePoint(0));)e.push(this.consumeCodePoint());i=this.peekCodePoint(0),r=this.peekCodePoint(1);var n=this.peekCodePoint(2);if((69===i||101===i)&&((r===Ed||r===kd)&&Td(n)||Td(r)))for(e.push(this.consumeCodePoint(),this.consumeCodePoint()),t=8;Td(this.peekCodePoint(0));)e.push(this.consumeCodePoint());return[Nd(e),t]},e.prototype.consumeNumericToken=function(){var e=this.consumeNumber(),t=e[0],i=e[1],r=this.peekCodePoint(0),n=this.peekCodePoint(1),s=this.peekCodePoint(2);return jd(r,n,s)?{type:15,number:t,flags:i,unit:this.consumeName()}:37===r?(this.consumeCodePoint(),{type:16,number:t,flags:i}):{type:17,number:t,flags:i}},e.prototype.consumeEscapedCodePoint=function(){var e=this.consumeCodePoint();if(Id(e)){for(var t=SA(e);Id(this.peekCodePoint(0))&&t.length<6;)t+=SA(this.consumeCodePoint());Fd(this.peekCodePoint(0))&&this.consumeCodePoint();var i=parseInt(t,16);return 0===i||function(e){return e>=55296&&e<=57343}(i)||i>1114111?65533:i}return e===Sd?65533:e},e.prototype.consumeName=function(){for(var e="";;){var t=this.consumeCodePoint();if(Rd(t))e+=SA(t);else{if(!Ld(t,this.peekCodePoint(0)))return this.reconsumeCodePoint(t),e;e+=SA(this.consumeEscapedCodePoint())}}},e}(),up=function(){function e(e){this._tokens=e}return e.create=function(t){var i=new lp;return i.write(t),new e(i.read())},e.parseValue=function(t){return e.create(t).parseComponentValue()},e.parseValues=function(t){return e.create(t).parseComponentValues()},e.prototype.parseComponentValue=function(){for(var e=this.consumeToken();31===e.type;)e=this.consumeToken();if(32===e.type)throw new SyntaxError("Error parsing CSS component value, unexpected EOF");this.reconsumeToken(e);var t=this.consumeComponentValue();do{e=this.consumeToken()}while(31===e.type);if(32===e.type)return t;throw new SyntaxError("Error parsing CSS component value, multiple values found when expecting only one")},e.prototype.parseComponentValues=function(){for(var e=[];;){var t=this.consumeComponentValue();if(32===t.type)return e;e.push(t),e.push()}},e.prototype.consumeComponentValue=function(){var e=this.consumeToken();switch(e.type){case 11:case 28:case 2:return this.consumeSimpleBlock(e.type);case 19:return this.consumeFunction(e)}return e},e.prototype.consumeSimpleBlock=function(e){for(var t={type:e,values:[]},i=this.consumeToken();;){if(32===i.type||vp(i,e))return t;this.reconsumeToken(i),t.values.push(this.consumeComponentValue()),i=this.consumeToken()}},e.prototype.consumeFunction=function(e){for(var t={name:e.value,values:[],type:18};;){var i=this.consumeToken();if(32===i.type||3===i.type)return t;this.reconsumeToken(i),t.values.push(this.consumeComponentValue())}},e.prototype.consumeToken=function(){var e=this._tokens.shift();return void 0===e?ap:e},e.prototype.reconsumeToken=function(e){this._tokens.unshift(e)},e}(),cp=function(e){return 15===e.type},hp=function(e){return 17===e.type},Ap=function(e){return 20===e.type},dp=function(e){return 0===e.type},pp=function(e,t){return Ap(e)&&e.value===t},fp=function(e){return 31!==e.type},gp=function(e){return 31!==e.type&&4!==e.type},mp=function(e){var t=[],i=[];return e.forEach(function(e){if(4===e.type){if(0===i.length)throw new Error("Error parsing function args, zero tokens for arg");return t.push(i),void(i=[])}31!==e.type&&i.push(e)}),i.length&&t.push(i),t},vp=function(e,t){return 11===t&&12===e.type||(28===t&&29===e.type||2===t&&3===e.type)},_p=function(e){return 17===e.type||15===e.type},yp=function(e){return 16===e.type||_p(e)},bp=function(e){return e.length>1?[e[0],e[1]]:[e[0]]},wp={type:17,number:0,flags:4},xp={type:16,number:50,flags:4},Bp={type:16,number:100,flags:4},Pp=function(e,t,i){var r=e[0],n=e[1];return[Cp(r,t),Cp(void 0!==n?n:r,i)]},Cp=function(e,t){if(16===e.type)return e.number/100*t;if(cp(e))switch(e.unit){case"rem":case"em":return 16*e.number;default:return e.number}return e.number},Mp="grad",kp="turn",Ep=function(e,t){if(15===t.type)switch(t.unit){case"deg":return Math.PI*t.number/180;case Mp:return Math.PI/200*t.number;case"rad":return t.number;case kp:return 2*Math.PI*t.number}throw new Error("Unsupported angle type")},Sp=function(e){return 15===e.type&&("deg"===e.unit||e.unit===Mp||"rad"===e.unit||e.unit===kp)},Tp=function(e){switch(e.filter(Ap).map(function(e){return e.value}).join(" ")){case"to bottom right":case"to right bottom":case"left top":case"top left":return[wp,wp];case"to top":case"bottom":return Ip(0);case"to bottom left":case"to left bottom":case"right top":case"top right":return[wp,Bp];case"to right":case"left":return Ip(90);case"to top left":case"to left top":case"right bottom":case"bottom right":return[Bp,Bp];case"to bottom":case"top":return Ip(180);case"to top right":case"to right top":case"left bottom":case"bottom left":return[Bp,wp];case"to left":case"right":return Ip(270)}return 0},Ip=function(e){return Math.PI*e/180},Fp=function(e,t){if(18===t.type){var i=Vp[t.name];if(void 0===i)throw new Error('Attempting to parse an unsupported color function "'+t.name+'"');return i(e,t.values)}if(5===t.type){if(3===t.value.length){var r=t.value.substring(0,1),n=t.value.substring(1,2),s=t.value.substring(2,3);return Op(parseInt(r+r,16),parseInt(n+n,16),parseInt(s+s,16),1)}if(4===t.value.length){r=t.value.substring(0,1),n=t.value.substring(1,2),s=t.value.substring(2,3);var o=t.value.substring(3,4);return Op(parseInt(r+r,16),parseInt(n+n,16),parseInt(s+s,16),parseInt(o+o,16)/255)}if(6===t.value.length){r=t.value.substring(0,2),n=t.value.substring(2,4),s=t.value.substring(4,6);return Op(parseInt(r,16),parseInt(n,16),parseInt(s,16),1)}if(8===t.value.length){r=t.value.substring(0,2),n=t.value.substring(2,4),s=t.value.substring(4,6),o=t.value.substring(6,8);return Op(parseInt(r,16),parseInt(n,16),parseInt(s,16),parseInt(o,16)/255)}}if(20===t.type){var a=Hp[t.value.toUpperCase()];if(void 0!==a)return a}return Hp.TRANSPARENT},Dp=function(e){return!(255&e)},Rp=function(e){var t=255&e,i=255&e>>8,r=255&e>>16,n=255&e>>24;return t<255?"rgba("+n+","+r+","+i+","+t/255+")":"rgb("+n+","+r+","+i+")"},Op=function(e,t,i,r){return(e<<24|t<<16|i<<8|Math.round(255*r))>>>0},Lp=function(e,t){if(17===e.type)return e.number;if(16===e.type){var i=3===t?1:255;return 3===t?e.number/100*i:Math.round(e.number/100*i)}return 0},jp=function(e,t){var i=t.filter(gp);if(3===i.length){var r=i.map(Lp),n=r[0],s=r[1],o=r[2];return Op(n,s,o,1)}if(4===i.length){var a=i.map(Lp),l=(n=a[0],s=a[1],o=a[2],a[3]);return Op(n,s,o,l)}return 0};function Up(e,t,i){return i<0&&(i+=1),i>=1&&(i-=1),i<1/6?(t-e)*i*6+e:i<.5?t:i<2/3?6*(t-e)*(2/3-i)+e:e}var Np=function(e,t){var i=t.filter(gp),r=i[0],n=i[1],s=i[2],o=i[3],a=(17===r.type?Ip(r.number):Ep(e,r))/(2*Math.PI),l=yp(n)?n.number/100:0,u=yp(s)?s.number/100:0,c=void 0!==o&&yp(o)?Cp(o,1):1;if(0===l)return Op(255*u,255*u,255*u,1);var h=u<=.5?u*(l+1):u+l-u*l,A=2*u-h,d=Up(A,h,a+1/3),p=Up(A,h,a),f=Up(A,h,a-1/3);return Op(255*d,255*p,255*f,c)},Vp={hsl:Np,hsla:Np,rgb:jp,rgba:jp},Qp=function(e,t){return Fp(e,up.create(t).parseComponentValue())},Hp={ALICEBLUE:4042850303,ANTIQUEWHITE:4209760255,AQUA:16777215,AQUAMARINE:2147472639,AZURE:4043309055,BEIGE:4126530815,BISQUE:4293182719,BLACK:255,BLANCHEDALMOND:4293643775,BLUE:65535,BLUEVIOLET:2318131967,BROWN:2771004159,BURLYWOOD:3736635391,CADETBLUE:1604231423,CHARTREUSE:2147418367,CHOCOLATE:3530104575,CORAL:4286533887,CORNFLOWERBLUE:1687547391,CORNSILK:4294499583,CRIMSON:3692313855,CYAN:16777215,DARKBLUE:35839,DARKCYAN:9145343,DARKGOLDENROD:3095837695,DARKGRAY:2846468607,DARKGREEN:6553855,DARKGREY:2846468607,DARKKHAKI:3182914559,DARKMAGENTA:2332068863,DARKOLIVEGREEN:1433087999,DARKORANGE:4287365375,DARKORCHID:2570243327,DARKRED:2332033279,DARKSALMON:3918953215,DARKSEAGREEN:2411499519,DARKSLATEBLUE:1211993087,DARKSLATEGRAY:793726975,DARKSLATEGREY:793726975,DARKTURQUOISE:13554175,DARKVIOLET:2483082239,DEEPPINK:4279538687,DEEPSKYBLUE:12582911,DIMGRAY:1768516095,DIMGREY:1768516095,DODGERBLUE:512819199,FIREBRICK:2988581631,FLORALWHITE:4294635775,FORESTGREEN:579543807,FUCHSIA:4278255615,GAINSBORO:3705462015,GHOSTWHITE:4177068031,GOLD:4292280575,GOLDENROD:3668254975,GRAY:2155905279,GREEN:8388863,GREENYELLOW:2919182335,GREY:2155905279,HONEYDEW:4043305215,HOTPINK:4285117695,INDIANRED:3445382399,INDIGO:1258324735,IVORY:4294963455,KHAKI:4041641215,LAVENDER:3873897215,LAVENDERBLUSH:4293981695,LAWNGREEN:2096890111,LEMONCHIFFON:4294626815,LIGHTBLUE:2916673279,LIGHTCORAL:4034953471,LIGHTCYAN:3774873599,LIGHTGOLDENRODYELLOW:4210742015,LIGHTGRAY:3553874943,LIGHTGREEN:2431553791,LIGHTGREY:3553874943,LIGHTPINK:4290167295,LIGHTSALMON:4288707327,LIGHTSEAGREEN:548580095,LIGHTSKYBLUE:2278488831,LIGHTSLATEGRAY:2005441023,LIGHTSLATEGREY:2005441023,LIGHTSTEELBLUE:2965692159,LIGHTYELLOW:4294959359,LIME:16711935,LIMEGREEN:852308735,LINEN:4210091775,MAGENTA:4278255615,MAROON:2147483903,MEDIUMAQUAMARINE:1724754687,MEDIUMBLUE:52735,MEDIUMORCHID:3126187007,MEDIUMPURPLE:2473647103,MEDIUMSEAGREEN:1018393087,MEDIUMSLATEBLUE:2070474495,MEDIUMSPRINGGREEN:16423679,MEDIUMTURQUOISE:1221709055,MEDIUMVIOLETRED:3340076543,MIDNIGHTBLUE:421097727,MINTCREAM:4127193855,MISTYROSE:4293190143,MOCCASIN:4293178879,NAVAJOWHITE:4292783615,NAVY:33023,OLDLACE:4260751103,OLIVE:2155872511,OLIVEDRAB:1804477439,ORANGE:4289003775,ORANGERED:4282712319,ORCHID:3664828159,PALEGOLDENROD:4008225535,PALEGREEN:2566625535,PALETURQUOISE:2951671551,PALEVIOLETRED:3681588223,PAPAYAWHIP:4293907967,PEACHPUFF:4292524543,PERU:3448061951,PINK:4290825215,PLUM:3718307327,POWDERBLUE:2967529215,PURPLE:2147516671,REBECCAPURPLE:1714657791,RED:4278190335,ROSYBROWN:3163525119,ROYALBLUE:1097458175,SADDLEBROWN:2336560127,SALMON:4202722047,SANDYBROWN:4104413439,SEAGREEN:780883967,SEASHELL:4294307583,SIENNA:2689740287,SILVER:3233857791,SKYBLUE:2278484991,SLATEBLUE:1784335871,SLATEGRAY:1887473919,SLATEGREY:1887473919,SNOW:4294638335,SPRINGGREEN:16744447,STEELBLUE:1182971135,TAN:3535047935,TEAL:8421631,THISTLE:3636451583,TOMATO:4284696575,TRANSPARENT:0,TURQUOISE:1088475391,VIOLET:4001558271,WHEAT:4125012991,WHITE:4294967295,WHITESMOKE:4126537215,YELLOW:4294902015,YELLOWGREEN:2597139199},Gp={name:"background-clip",initialValue:"border-box",prefix:!1,type:1,parse:function(e,t){return t.map(function(e){if(Ap(e))switch(e.value){case"padding-box":return 1;case"content-box":return 2}return 0})}},zp={name:"background-color",initialValue:"transparent",prefix:!1,type:3,format:"color"},Wp=function(e,t){var i=Fp(e,t[0]),r=t[1];return r&&yp(r)?{color:i,stop:r}:{color:i,stop:null}},Kp=function(e,t){var i=e[0],r=e[e.length-1];null===i.stop&&(i.stop=wp),null===r.stop&&(r.stop=Bp);for(var n=[],s=0,o=0;o<e.length;o++){var a=e[o].stop;if(null!==a){var l=Cp(a,t);l>s?n.push(l):n.push(s),s=l}else n.push(null)}var u=null;for(o=0;o<n.length;o++){var c=n[o];if(null===c)null===u&&(u=o);else if(null!==u){for(var h=o-u,A=(c-n[u-1])/(h+1),d=1;d<=h;d++)n[u+d-1]=A*d;u=null}}return e.map(function(e,i){return{color:e.color,stop:Math.max(Math.min(1,n[i]/t),0)}})},Xp=function(e,t,i){var r="number"==typeof e?e:function(e,t,i){var r=t/2,n=i/2,s=Cp(e[0],t)-r,o=n-Cp(e[1],i);return(Math.atan2(o,s)+2*Math.PI)%(2*Math.PI)}(e,t,i),n=Math.abs(t*Math.sin(r))+Math.abs(i*Math.cos(r)),s=t/2,o=i/2,a=n/2,l=Math.sin(r-Math.PI/2)*a,u=Math.cos(r-Math.PI/2)*a;return[n,s-u,s+u,o-l,o+l]},qp=function(e,t){return Math.sqrt(e*e+t*t)},Yp=function(e,t,i,r,n){return[[0,0],[0,t],[e,0],[e,t]].reduce(function(e,t){var s=t[0],o=t[1],a=qp(i-s,r-o);return(n?a<e.optimumDistance:a>e.optimumDistance)?{optimumCorner:t,optimumDistance:a}:e},{optimumDistance:n?1/0:-1/0,optimumCorner:null}).optimumCorner},Jp=function(e,t){var i=Ip(180),r=[];return mp(t).forEach(function(t,n){if(0===n){var s=t[0];if(20===s.type&&-1!==["top","left","right","bottom"].indexOf(s.value))return void(i=Tp(t));if(Sp(s))return void(i=(Ep(e,s)+Ip(270))%Ip(360))}var o=Wp(e,t);r.push(o)}),{angle:i,stops:r,type:1}},Zp="closest-side",$p="farthest-side",ef="closest-corner",tf="farthest-corner",rf="circle",nf="ellipse",sf="cover",of="contain",af=function(e,t){var i=0,r=3,n=[],s=[];return mp(t).forEach(function(t,o){var a=!0;if(0===o?a=t.reduce(function(e,t){if(Ap(t))switch(t.value){case"center":return s.push(xp),!1;case"top":case"left":return s.push(wp),!1;case"right":case"bottom":return s.push(Bp),!1}else if(yp(t)||_p(t))return s.push(t),!1;return e},a):1===o&&(a=t.reduce(function(e,t){if(Ap(t))switch(t.value){case rf:return i=0,!1;case nf:return i=1,!1;case of:case Zp:return r=0,!1;case $p:return r=1,!1;case ef:return r=2,!1;case sf:case tf:return r=3,!1}else if(_p(t)||yp(t))return Array.isArray(r)||(r=[]),r.push(t),!1;return e},a)),a){var l=Wp(e,t);n.push(l)}}),{size:r,shape:i,stops:n,position:s,type:2}},lf=function(e,t){if(22===t.type){var i={url:t.value,type:0};return e.cache.addImage(t.value),i}if(18===t.type){var r=cf[t.name];if(void 0===r)throw new Error('Attempting to parse an unsupported image function "'+t.name+'"');return r(e,t.values)}throw new Error("Unsupported image type "+t.type)};var uf,cf={"linear-gradient":function(e,t){var i=Ip(180),r=[];return mp(t).forEach(function(t,n){if(0===n){var s=t[0];if(20===s.type&&"to"===s.value)return void(i=Tp(t));if(Sp(s))return void(i=Ep(e,s))}var o=Wp(e,t);r.push(o)}),{angle:i,stops:r,type:1}},"-moz-linear-gradient":Jp,"-ms-linear-gradient":Jp,"-o-linear-gradient":Jp,"-webkit-linear-gradient":Jp,"radial-gradient":function(e,t){var i=0,r=3,n=[],s=[];return mp(t).forEach(function(t,o){var a=!0;if(0===o){var l=!1;a=t.reduce(function(e,t){if(l)if(Ap(t))switch(t.value){case"center":return s.push(xp),e;case"top":case"left":return s.push(wp),e;case"right":case"bottom":return s.push(Bp),e}else(yp(t)||_p(t))&&s.push(t);else if(Ap(t))switch(t.value){case rf:return i=0,!1;case nf:return i=1,!1;case"at":return l=!0,!1;case Zp:return r=0,!1;case sf:case $p:return r=1,!1;case of:case ef:return r=2,!1;case tf:return r=3,!1}else if(_p(t)||yp(t))return Array.isArray(r)||(r=[]),r.push(t),!1;return e},a)}if(a){var u=Wp(e,t);n.push(u)}}),{size:r,shape:i,stops:n,position:s,type:2}},"-moz-radial-gradient":af,"-ms-radial-gradient":af,"-o-radial-gradient":af,"-webkit-radial-gradient":af,"-webkit-gradient":function(e,t){var i=Ip(180),r=[],n=1;return mp(t).forEach(function(t,i){var s=t[0];if(0===i){if(Ap(s)&&"linear"===s.value)return void(n=1);if(Ap(s)&&"radial"===s.value)return void(n=2)}if(18===s.type)if("from"===s.name){var o=Fp(e,s.values[0]);r.push({stop:wp,color:o})}else if("to"===s.name){o=Fp(e,s.values[0]);r.push({stop:Bp,color:o})}else if("color-stop"===s.name){var a=s.values.filter(gp);if(2===a.length){o=Fp(e,a[1]);var l=a[0];hp(l)&&r.push({stop:{type:16,number:100*l.number,flags:l.flags},color:o})}}}),1===n?{angle:(i+Ip(180))%Ip(360),stops:r,type:n}:{size:3,shape:0,stops:r,position:[],type:n}}},hf={name:"background-image",initialValue:"none",type:1,prefix:!1,parse:function(e,t){if(0===t.length)return[];var i=t[0];return 20===i.type&&"none"===i.value?[]:t.filter(function(e){return gp(e)&&function(e){return!(20===e.type&&"none"===e.value||18===e.type&&!cf[e.name])}(e)}).map(function(t){return lf(e,t)})}},Af={name:"background-origin",initialValue:"border-box",prefix:!1,type:1,parse:function(e,t){return t.map(function(e){if(Ap(e))switch(e.value){case"padding-box":return 1;case"content-box":return 2}return 0})}},df={name:"background-position",initialValue:"0% 0%",type:1,prefix:!1,parse:function(e,t){return mp(t).map(function(e){return e.filter(yp)}).map(bp)}},pf={name:"background-repeat",initialValue:"repeat",prefix:!1,type:1,parse:function(e,t){return mp(t).map(function(e){return e.filter(Ap).map(function(e){return e.value}).join(" ")}).map(ff)}},ff=function(e){switch(e){case"no-repeat":return 1;case"repeat-x":case"repeat no-repeat":return 2;case"repeat-y":case"no-repeat repeat":return 3;default:return 0}};!function(e){e.AUTO="auto",e.CONTAIN="contain",e.COVER="cover"}(uf||(uf={}));var gf,mf={name:"background-size",initialValue:"0",prefix:!1,type:1,parse:function(e,t){return mp(t).map(function(e){return e.filter(vf)})}},vf=function(e){return Ap(e)||yp(e)},_f=function(e){return{name:"border-"+e+"-color",initialValue:"transparent",prefix:!1,type:3,format:"color"}},yf=_f("top"),bf=_f("right"),wf=_f("bottom"),xf=_f("left"),Bf=function(e){return{name:"border-radius-"+e,initialValue:"0 0",prefix:!1,type:1,parse:function(e,t){return bp(t.filter(yp))}}},Pf=Bf("top-left"),Cf=Bf("top-right"),Mf=Bf("bottom-right"),kf=Bf("bottom-left"),Ef=function(e){return{name:"border-"+e+"-style",initialValue:"solid",prefix:!1,type:2,parse:function(e,t){switch(t){case"none":return 0;case"dashed":return 2;case"dotted":return 3;case"double":return 4}return 1}}},Sf=Ef("top"),Tf=Ef("right"),If=Ef("bottom"),Ff=Ef("left"),Df=function(e){return{name:"border-"+e+"-width",initialValue:"0",type:0,prefix:!1,parse:function(e,t){return cp(t)?t.number:0}}},Rf=Df("top"),Of=Df("right"),Lf=Df("bottom"),jf=Df("left"),Uf={name:"color",initialValue:"transparent",prefix:!1,type:3,format:"color"},Nf={name:"direction",initialValue:"ltr",prefix:!1,type:2,parse:function(e,t){return"rtl"===t?1:0}},Vf={name:"display",initialValue:"inline-block",prefix:!1,type:1,parse:function(e,t){return t.filter(Ap).reduce(function(e,t){return e|Qf(t.value)},0)}},Qf=function(e){switch(e){case"block":case"-webkit-box":return 2;case"inline":return 4;case"run-in":return 8;case"flow":return 16;case"flow-root":return 32;case"table":return 64;case"flex":case"-webkit-flex":return 128;case"grid":case"-ms-grid":return 256;case"ruby":return 512;case"subgrid":return 1024;case"list-item":return 2048;case"table-row-group":return 4096;case"table-header-group":return 8192;case"table-footer-group":return 16384;case"table-row":return 32768;case"table-cell":return 65536;case"table-column-group":return 131072;case"table-column":return 262144;case"table-caption":return 524288;case"ruby-base":return 1048576;case"ruby-text":return 2097152;case"ruby-base-container":return 4194304;case"ruby-text-container":return 8388608;case"contents":return 16777216;case"inline-block":return 33554432;case"inline-list-item":return 67108864;case"inline-table":return 134217728;case"inline-flex":return 268435456;case"inline-grid":return 536870912}return 0},Hf={name:"float",initialValue:"none",prefix:!1,type:2,parse:function(e,t){switch(t){case"left":return 1;case"right":return 2;case"inline-start":return 3;case"inline-end":return 4}return 0}},Gf={name:"letter-spacing",initialValue:"0",prefix:!1,type:0,parse:function(e,t){return 20===t.type&&"normal"===t.value?0:17===t.type||15===t.type?t.number:0}};!function(e){e.NORMAL="normal",e.STRICT="strict"}(gf||(gf={}));var zf,Wf={name:"line-break",initialValue:"normal",prefix:!1,type:2,parse:function(e,t){return"strict"===t?gf.STRICT:gf.NORMAL}},Kf={name:"line-height",initialValue:"normal",prefix:!1,type:4},Xf=function(e,t){return Ap(e)&&"normal"===e.value?1.2*t:17===e.type?t*e.number:yp(e)?Cp(e,t):t},qf={name:"list-style-image",initialValue:"none",type:0,prefix:!1,parse:function(e,t){return 20===t.type&&"none"===t.value?null:lf(e,t)}},Yf={name:"list-style-position",initialValue:"outside",prefix:!1,type:2,parse:function(e,t){return"inside"===t?0:1}},Jf={name:"list-style-type",initialValue:"none",prefix:!1,type:2,parse:function(e,t){switch(t){case"disc":return 0;case"circle":return 1;case"square":return 2;case"decimal":return 3;case"cjk-decimal":return 4;case"decimal-leading-zero":return 5;case"lower-roman":return 6;case"upper-roman":return 7;case"lower-greek":return 8;case"lower-alpha":return 9;case"upper-alpha":return 10;case"arabic-indic":return 11;case"armenian":return 12;case"bengali":return 13;case"cambodian":return 14;case"cjk-earthly-branch":return 15;case"cjk-heavenly-stem":return 16;case"cjk-ideographic":return 17;case"devanagari":return 18;case"ethiopic-numeric":return 19;case"georgian":return 20;case"gujarati":return 21;case"gurmukhi":case"hebrew":return 22;case"hiragana":return 23;case"hiragana-iroha":return 24;case"japanese-formal":return 25;case"japanese-informal":return 26;case"kannada":return 27;case"katakana":return 28;case"katakana-iroha":return 29;case"khmer":return 30;case"korean-hangul-formal":return 31;case"korean-hanja-formal":return 32;case"korean-hanja-informal":return 33;case"lao":return 34;case"lower-armenian":return 35;case"malayalam":return 36;case"mongolian":return 37;case"myanmar":return 38;case"oriya":return 39;case"persian":return 40;case"simp-chinese-formal":return 41;case"simp-chinese-informal":return 42;case"tamil":return 43;case"telugu":return 44;case"thai":return 45;case"tibetan":return 46;case"trad-chinese-formal":return 47;case"trad-chinese-informal":return 48;case"upper-armenian":return 49;case"disclosure-open":return 50;case"disclosure-closed":return 51;default:return-1}}},Zf=function(e){return{name:"margin-"+e,initialValue:"0",prefix:!1,type:4}},$f=Zf("top"),eg=Zf("right"),tg=Zf("bottom"),ig=Zf("left"),rg={name:"overflow",initialValue:"visible",prefix:!1,type:1,parse:function(e,t){return t.filter(Ap).map(function(e){switch(e.value){case"hidden":return 1;case"scroll":return 2;case"clip":return 3;case"auto":return 4;default:return 0}})}},ng={name:"overflow-wrap",initialValue:"normal",prefix:!1,type:2,parse:function(e,t){return"break-word"===t?"break-word":"normal"}},sg=function(e){return{name:"padding-"+e,initialValue:"0",prefix:!1,type:3,format:"length-percentage"}},og=sg("top"),ag=sg("right"),lg=sg("bottom"),ug=sg("left"),cg={name:"text-align",initialValue:"left",prefix:!1,type:2,parse:function(e,t){switch(t){case"right":return 2;case"center":case"justify":return 1;default:return 0}}},hg={name:"position",initialValue:"static",prefix:!1,type:2,parse:function(e,t){switch(t){case"relative":return 1;case"absolute":return 2;case"fixed":return 3;case"sticky":return 4}return 0}},Ag={name:"text-shadow",initialValue:"none",type:1,prefix:!1,parse:function(e,t){return 1===t.length&&pp(t[0],"none")?[]:mp(t).map(function(t){for(var i={color:Hp.TRANSPARENT,offsetX:wp,offsetY:wp,blur:wp},r=0,n=0;n<t.length;n++){var s=t[n];_p(s)?(0===r?i.offsetX=s:1===r?i.offsetY=s:i.blur=s,r++):i.color=Fp(e,s)}return i})}},dg={name:"text-transform",initialValue:"none",prefix:!1,type:2,parse:function(e,t){switch(t){case"uppercase":return 2;case"lowercase":return 1;case"capitalize":return 3}return 0}},pg={name:"transform",initialValue:"none",prefix:!0,type:0,parse:function(e,t){if(20===t.type&&"none"===t.value)return null;if(18===t.type){var i=fg[t.name];if(void 0===i)throw new Error('Attempting to parse an unsupported transform function "'+t.name+'"');return i(t.values)}return null}},fg={matrix:function(e){var t=e.filter(function(e){return 17===e.type}).map(function(e){return e.number});return 6===t.length?t:null},matrix3d:function(e){var t=e.filter(function(e){return 17===e.type}).map(function(e){return e.number}),i=t[0],r=t[1];t[2],t[3];var n=t[4],s=t[5];t[6],t[7],t[8],t[9],t[10],t[11];var o=t[12],a=t[13];return t[14],t[15],16===t.length?[i,r,n,s,o,a]:null}},gg={type:16,number:50,flags:4},mg=[gg,gg],vg={name:"transform-origin",initialValue:"50% 50%",prefix:!0,type:1,parse:function(e,t){var i=t.filter(yp);return 2!==i.length?mg:[i[0],i[1]]}},_g={name:"visible",initialValue:"none",prefix:!1,type:2,parse:function(e,t){switch(t){case"hidden":return 1;case"collapse":return 2;default:return 0}}};!function(e){e.NORMAL="normal",e.BREAK_ALL="break-all",e.KEEP_ALL="keep-all"}(zf||(zf={}));for(var yg={name:"word-break",initialValue:"normal",prefix:!1,type:2,parse:function(e,t){switch(t){case"break-all":return zf.BREAK_ALL;case"keep-all":return zf.KEEP_ALL;default:return zf.NORMAL}}},bg={name:"z-index",initialValue:"auto",prefix:!1,type:0,parse:function(e,t){if(20===t.type)return{auto:!0,order:0};if(hp(t))return{auto:!1,order:t.number};throw new Error("Invalid z-index number parsed")}},wg=function(e,t){if(15===t.type)switch(t.unit.toLowerCase()){case"s":return 1e3*t.number;case"ms":return t.number}throw new Error("Unsupported time type")},xg={name:"opacity",initialValue:"1",type:0,prefix:!1,parse:function(e,t){return hp(t)?t.number:1}},Bg={name:"text-decoration-color",initialValue:"transparent",prefix:!1,type:3,format:"color"},Pg={name:"text-decoration-line",initialValue:"none",prefix:!1,type:1,parse:function(e,t){return t.filter(Ap).map(function(e){switch(e.value){case"underline":return 1;case"overline":return 2;case"line-through":return 3;case"none":return 4}return 0}).filter(function(e){return 0!==e})}},Cg={name:"font-family",initialValue:"",prefix:!1,type:1,parse:function(e,t){var i=[],r=[];return t.forEach(function(e){switch(e.type){case 20:case 0:i.push(e.value);break;case 17:i.push(e.number.toString());break;case 4:r.push(i.join(" ")),i.length=0}}),i.length&&r.push(i.join(" ")),r.map(function(e){return-1===e.indexOf(" ")?e:"'"+e+"'"})}},Mg={name:"font-size",initialValue:"0",prefix:!1,type:3,format:"length"},kg={name:"font-weight",initialValue:"normal",type:0,prefix:!1,parse:function(e,t){return hp(t)?t.number:Ap(t)&&"bold"===t.value?700:400}},Eg={name:"font-variant",initialValue:"none",type:1,prefix:!1,parse:function(e,t){return t.filter(Ap).map(function(e){return e.value})}},Sg={name:"font-style",initialValue:"normal",prefix:!1,type:2,parse:function(e,t){switch(t){case"oblique":return"oblique";case"italic":return"italic";default:return"normal"}}},Tg=function(e,t){return 0!==(e&t)},Ig={name:"content",initialValue:"none",type:1,prefix:!1,parse:function(e,t){if(0===t.length)return[];var i=t[0];return 20===i.type&&"none"===i.value?[]:t}},Fg={name:"counter-increment",initialValue:"none",prefix:!0,type:1,parse:function(e,t){if(0===t.length)return null;var i=t[0];if(20===i.type&&"none"===i.value)return null;for(var r=[],n=t.filter(fp),s=0;s<n.length;s++){var o=n[s],a=n[s+1];if(20===o.type){var l=a&&hp(a)?a.number:1;r.push({counter:o.value,increment:l})}}return r}},Dg={name:"counter-reset",initialValue:"none",prefix:!0,type:1,parse:function(e,t){if(0===t.length)return[];for(var i=[],r=t.filter(fp),n=0;n<r.length;n++){var s=r[n],o=r[n+1];if(Ap(s)&&"none"!==s.value){var a=o&&hp(o)?o.number:0;i.push({counter:s.value,reset:a})}}return i}},Rg={name:"duration",initialValue:"0s",prefix:!1,type:1,parse:function(e,t){return t.filter(cp).map(function(t){return wg(e,t)})}},Og={name:"quotes",initialValue:"none",prefix:!0,type:1,parse:function(e,t){if(0===t.length)return null;var i=t[0];if(20===i.type&&"none"===i.value)return null;var r=[],n=t.filter(dp);if(n.length%2!=0)return null;for(var s=0;s<n.length;s+=2){var o=n[s].value,a=n[s+1].value;r.push({open:o,close:a})}return r}},Lg=function(e,t,i){if(!e)return"";var r=e[Math.min(t,e.length-1)];return r?i?r.open:r.close:""},jg={name:"box-shadow",initialValue:"none",type:1,prefix:!1,parse:function(e,t){return 1===t.length&&pp(t[0],"none")?[]:mp(t).map(function(t){for(var i={color:255,offsetX:wp,offsetY:wp,blur:wp,spread:wp,inset:!1},r=0,n=0;n<t.length;n++){var s=t[n];pp(s,"inset")?i.inset=!0:_p(s)?(0===r?i.offsetX=s:1===r?i.offsetY=s:2===r?i.blur=s:i.spread=s,r++):i.color=Fp(e,s)}return i})}},Ug={name:"paint-order",initialValue:"normal",prefix:!1,type:1,parse:function(e,t){var i=[];return t.filter(Ap).forEach(function(e){switch(e.value){case"stroke":i.push(1);break;case"fill":i.push(0);break;case"markers":i.push(2)}}),[0,1,2].forEach(function(e){-1===i.indexOf(e)&&i.push(e)}),i}},Ng={name:"-webkit-text-stroke-color",initialValue:"currentcolor",prefix:!1,type:3,format:"color"},Vg={name:"-webkit-text-stroke-width",initialValue:"0",type:0,prefix:!1,parse:function(e,t){return cp(t)?t.number:0}},Qg=function(){function e(e,t){var i,r;this.animationDuration=zg(e,Rg,t.animationDuration),this.backgroundClip=zg(e,Gp,t.backgroundClip),this.backgroundColor=zg(e,zp,t.backgroundColor),this.backgroundImage=zg(e,hf,t.backgroundImage),this.backgroundOrigin=zg(e,Af,t.backgroundOrigin),this.backgroundPosition=zg(e,df,t.backgroundPosition),this.backgroundRepeat=zg(e,pf,t.backgroundRepeat),this.backgroundSize=zg(e,mf,t.backgroundSize),this.borderTopColor=zg(e,yf,t.borderTopColor),this.borderRightColor=zg(e,bf,t.borderRightColor),this.borderBottomColor=zg(e,wf,t.borderBottomColor),this.borderLeftColor=zg(e,xf,t.borderLeftColor),this.borderTopLeftRadius=zg(e,Pf,t.borderTopLeftRadius),this.borderTopRightRadius=zg(e,Cf,t.borderTopRightRadius),this.borderBottomRightRadius=zg(e,Mf,t.borderBottomRightRadius),this.borderBottomLeftRadius=zg(e,kf,t.borderBottomLeftRadius),this.borderTopStyle=zg(e,Sf,t.borderTopStyle),this.borderRightStyle=zg(e,Tf,t.borderRightStyle),this.borderBottomStyle=zg(e,If,t.borderBottomStyle),this.borderLeftStyle=zg(e,Ff,t.borderLeftStyle),this.borderTopWidth=zg(e,Rf,t.borderTopWidth),this.borderRightWidth=zg(e,Of,t.borderRightWidth),this.borderBottomWidth=zg(e,Lf,t.borderBottomWidth),this.borderLeftWidth=zg(e,jf,t.borderLeftWidth),this.boxShadow=zg(e,jg,t.boxShadow),this.color=zg(e,Uf,t.color),this.direction=zg(e,Nf,t.direction),this.display=zg(e,Vf,t.display),this.float=zg(e,Hf,t.cssFloat),this.fontFamily=zg(e,Cg,t.fontFamily),this.fontSize=zg(e,Mg,t.fontSize),this.fontStyle=zg(e,Sg,t.fontStyle),this.fontVariant=zg(e,Eg,t.fontVariant),this.fontWeight=zg(e,kg,t.fontWeight),this.letterSpacing=zg(e,Gf,t.letterSpacing),this.lineBreak=zg(e,Wf,t.lineBreak),this.lineHeight=zg(e,Kf,t.lineHeight),this.listStyleImage=zg(e,qf,t.listStyleImage),this.listStylePosition=zg(e,Yf,t.listStylePosition),this.listStyleType=zg(e,Jf,t.listStyleType),this.marginTop=zg(e,$f,t.marginTop),this.marginRight=zg(e,eg,t.marginRight),this.marginBottom=zg(e,tg,t.marginBottom),this.marginLeft=zg(e,ig,t.marginLeft),this.opacity=zg(e,xg,t.opacity);var n=zg(e,rg,t.overflow);this.overflowX=n[0],this.overflowY=n[n.length>1?1:0],this.overflowWrap=zg(e,ng,t.overflowWrap),this.paddingTop=zg(e,og,t.paddingTop),this.paddingRight=zg(e,ag,t.paddingRight),this.paddingBottom=zg(e,lg,t.paddingBottom),this.paddingLeft=zg(e,ug,t.paddingLeft),this.paintOrder=zg(e,Ug,t.paintOrder),this.position=zg(e,hg,t.position),this.textAlign=zg(e,cg,t.textAlign),this.textDecorationColor=zg(e,Bg,null!==(i=t.textDecorationColor)&&void 0!==i?i:t.color),this.textDecorationLine=zg(e,Pg,null!==(r=t.textDecorationLine)&&void 0!==r?r:t.textDecoration),this.textShadow=zg(e,Ag,t.textShadow),this.textTransform=zg(e,dg,t.textTransform),this.transform=zg(e,pg,t.transform),this.transformOrigin=zg(e,vg,t.transformOrigin),this.visibility=zg(e,_g,t.visibility),this.webkitTextStrokeColor=zg(e,Ng,t.webkitTextStrokeColor),this.webkitTextStrokeWidth=zg(e,Vg,t.webkitTextStrokeWidth),this.wordBreak=zg(e,yg,t.wordBreak),this.zIndex=zg(e,bg,t.zIndex)}return e.prototype.isVisible=function(){return this.display>0&&this.opacity>0&&0===this.visibility},e.prototype.isTransparent=function(){return Dp(this.backgroundColor)},e.prototype.isTransformed=function(){return null!==this.transform},e.prototype.isPositioned=function(){return 0!==this.position},e.prototype.isPositionedWithZIndex=function(){return this.isPositioned()&&!this.zIndex.auto},e.prototype.isFloating=function(){return 0!==this.float},e.prototype.isInlineLevel=function(){return Tg(this.display,4)||Tg(this.display,33554432)||Tg(this.display,268435456)||Tg(this.display,536870912)||Tg(this.display,67108864)||Tg(this.display,134217728)},e}(),Hg=function(e,t){this.content=zg(e,Ig,t.content),this.quotes=zg(e,Og,t.quotes)},Gg=function(e,t){this.counterIncrement=zg(e,Fg,t.counterIncrement),this.counterReset=zg(e,Dg,t.counterReset)},zg=function(e,t,i){var r=new lp,n=null!=i?i.toString():t.initialValue;r.write(n);var s=new up(r.read());switch(t.type){case 2:var o=s.parseComponentValue();return t.parse(e,Ap(o)?o.value:t.initialValue);case 0:return t.parse(e,s.parseComponentValue());case 1:return t.parse(e,s.parseComponentValues());case 4:return s.parseComponentValue();case 3:switch(t.format){case"angle":return Ep(e,s.parseComponentValue());case"color":return Fp(e,s.parseComponentValue());case"image":return lf(e,s.parseComponentValue());case"length":var a=s.parseComponentValue();return _p(a)?a:wp;case"length-percentage":var l=s.parseComponentValue();return yp(l)?l:wp;case"time":return wg(e,s.parseComponentValue())}}},Wg=function(e,t){var i=function(e){switch(e.getAttribute("data-html2canvas-debug")){case"all":return 1;case"clone":return 2;case"parse":return 3;case"render":return 4;default:return 0}}(e);return 1===i||t===i},Kg=function(e,t){this.context=e,this.textNodes=[],this.elements=[],this.flags=0,Wg(t,3),this.styles=new Qg(e,window.getComputedStyle(t,null)),Jm(t)&&(this.styles.animationDuration.some(function(e){return e>0})&&(t.style.animationDuration="0s"),null!==this.styles.transform&&(t.style.transform="none")),this.bounds=kA(this.context,t),Wg(t,4)&&(this.flags|=16)},Xg="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",qg="undefined"==typeof Uint8Array?[]:new Uint8Array(256),Yg=0;Yg<64;Yg++)qg[Xg.charCodeAt(Yg)]=Yg;for(var Jg=function(e,t,i){return e.slice?e.slice(t,i):new Uint16Array(Array.prototype.slice.call(e,t,i))},Zg=function(){function e(e,t,i,r,n,s){this.initialValue=e,this.errorValue=t,this.highStart=i,this.highValueIndex=r,this.index=n,this.data=s}return e.prototype.get=function(e){var t;if(e>=0){if(e<55296||e>56319&&e<=65535)return t=((t=this.index[e>>5])<<2)+(31&e),this.data[t];if(e<=65535)return t=((t=this.index[2048+(e-55296>>5)])<<2)+(31&e),this.data[t];if(e<this.highStart)return t=2080+(e>>11),t=this.index[t],t+=e>>5&63,t=((t=this.index[t])<<2)+(31&e),this.data[t];if(e<=1114111)return this.data[this.highValueIndex]}return this.errorValue},e}(),$g="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",em="undefined"==typeof Uint8Array?[]:new Uint8Array(256),tm=0;tm<64;tm++)em[$g.charCodeAt(tm)]=tm;var im,rm=8,nm=9,sm=11,om=12,am=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];if(String.fromCodePoint)return String.fromCodePoint.apply(String,e);var i=e.length;if(!i)return"";for(var r=[],n=-1,s="";++n<i;){var o=e[n];o<=65535?r.push(o):(o-=65536,r.push(55296+(o>>10),o%1024+56320)),(n+1===i||r.length>16384)&&(s+=String.fromCharCode.apply(String,r),r.length=0)}return s},lm=function(e){var t,i,r,n=function(e){var t,i,r,n,s,o=.75*e.length,a=e.length,l=0;"="===e[e.length-1]&&(o--,"="===e[e.length-2]&&o--);var u="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof Uint8Array&&void 0!==Uint8Array.prototype.slice?new ArrayBuffer(o):new Array(o),c=Array.isArray(u)?u:new Uint8Array(u);for(t=0;t<a;t+=4)i=qg[e.charCodeAt(t)],r=qg[e.charCodeAt(t+1)],n=qg[e.charCodeAt(t+2)],s=qg[e.charCodeAt(t+3)],c[l++]=i<<2|r>>4,c[l++]=(15&r)<<4|n>>2,c[l++]=(3&n)<<6|63&s;return u}(e),s=Array.isArray(n)?function(e){for(var t=e.length,i=[],r=0;r<t;r+=4)i.push(e[r+3]<<24|e[r+2]<<16|e[r+1]<<8|e[r]);return i}(n):new Uint32Array(n),o=Array.isArray(n)?function(e){for(var t=e.length,i=[],r=0;r<t;r+=2)i.push(e[r+1]<<8|e[r]);return i}(n):new Uint16Array(n),a=Jg(o,12,s[4]/2),l=2===s[5]?Jg(o,(24+s[4])/2):(t=s,i=Math.ceil((24+s[4])/4),t.slice?t.slice(i,r):new Uint32Array(Array.prototype.slice.call(t,i,r)));return new Zg(s[0],s[1],s[2],s[3],a,l)}("AAAAAAAAAAAAEA4AGBkAAFAaAAACAAAAAAAIABAAGAAwADgACAAQAAgAEAAIABAACAAQAAgAEAAIABAACAAQAAgAEAAIABAAQABIAEQATAAIABAACAAQAAgAEAAIABAAVABcAAgAEAAIABAACAAQAGAAaABwAHgAgACIAI4AlgAIABAAmwCjAKgAsAC2AL4AvQDFAMoA0gBPAVYBWgEIAAgACACMANoAYgFkAWwBdAF8AX0BhQGNAZUBlgGeAaMBlQGWAasBswF8AbsBwwF0AcsBYwHTAQgA2wG/AOMBdAF8AekB8QF0AfkB+wHiAHQBfAEIAAMC5gQIAAsCEgIIAAgAFgIeAggAIgIpAggAMQI5AkACygEIAAgASAJQAlgCYAIIAAgACAAKBQoFCgUTBRMFGQUrBSsFCAAIAAgACAAIAAgACAAIAAgACABdAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABoAmgCrwGvAQgAbgJ2AggAHgEIAAgACADnAXsCCAAIAAgAgwIIAAgACAAIAAgACACKAggAkQKZAggAPADJAAgAoQKkAqwCsgK6AsICCADJAggA0AIIAAgACAAIANYC3gIIAAgACAAIAAgACABAAOYCCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAkASoB+QIEAAgACAA8AEMCCABCBQgACABJBVAFCAAIAAgACAAIAAgACAAIAAgACABTBVoFCAAIAFoFCABfBWUFCAAIAAgACAAIAAgAbQUIAAgACAAIAAgACABzBXsFfQWFBYoFigWKBZEFigWKBYoFmAWfBaYFrgWxBbkFCAAIAAgACAAIAAgACAAIAAgACAAIAMEFCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAMgFCADQBQgACAAIAAgACAAIAAgACAAIAAgACAAIAO4CCAAIAAgAiQAIAAgACABAAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAD0AggACAD8AggACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIANYFCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAC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FOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFIQUoBSwFCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABtAwgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACA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wADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAdQMIAAgACAAIAAgACAAIAMkACAAIAAgAfQMIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACACFA4kDCAAIAAgACAAIAOcBCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAIcDCAAIAAgACAAIAAgACAAIAAgACAAIAJEDCAAIAAgACADFAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABgBAgAZgQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAbAQCBXIECAAIAHkECAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABAAJwEQACjBKoEsgQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAC6BMIECAAIAAgACAAIAAgACABmBAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAxwQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAGYECAAIAAgAzgQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAigWKBYoFigWKBYoFigWKBd0FXwUIAOIF6gXxBYoF3gT5BQAGCAaKBYoFigWKBYoFigWKBYoFigWKBYoFigXWBIoFigWKBYoFigWKBYoFigWKBYsFEA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OAA4ADgAOAA4AAAAAAAAAAAAAAAAAAAAAAA4ADgAOAA4ADgAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4AAAAOAA4ADgAOAA4ADgAAAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4AAAAAAAAAAAA="),um="×",cm=function(e){return lm.get(e)},hm=function(e,t,i){var r=i-2,n=t[r],s=t[i-1],o=t[i];if(2===s&&3===o)return um;if(2===s||3===s||4===s)return"÷";if(2===o||3===o||4===o)return"÷";if(s===rm&&-1!==[rm,nm,sm,om].indexOf(o))return um;if(!(s!==sm&&s!==nm||o!==nm&&10!==o))return um;if((s===om||10===s)&&10===o)return um;if(13===o||5===o)return um;if(7===o)return um;if(1===s)return um;if(13===s&&14===o){for(;5===n;)n=t[--r];if(14===n)return um}if(15===s&&15===o){for(var a=0;15===n;)a++,n=t[--r];if(a%2==0)return um}return"÷"},Am=function(e){var t=function(e){for(var t=[],i=0,r=e.length;i<r;){var n=e.charCodeAt(i++);if(n>=55296&&n<=56319&&i<r){var s=e.charCodeAt(i++);56320==(64512&s)?t.push(((1023&n)<<10)+(1023&s)+65536):(t.push(n),i--)}else t.push(n)}return t}(e),i=t.length,r=0,n=0,s=t.map(cm);return{next:function(){if(r>=i)return{done:!0,value:null};for(var e=um;r<i&&(e=hm(0,s,++r))===um;);if(e!==um||r===i){var o=am.apply(null,t.slice(n,r));return n=r,{value:o,done:!1}}return{done:!0,value:null}}}},dm=function(e){return 0===e[0]&&255===e[1]&&0===e[2]&&255===e[3]},pm=function(e,t,i,r,n){var s="http://www.w3.org/2000/svg",o=document.createElementNS(s,"svg"),a=document.createElementNS(s,"foreignObject");return o.setAttributeNS(null,"width",e.toString()),o.setAttributeNS(null,"height",t.toString()),a.setAttributeNS(null,"width","100%"),a.setAttributeNS(null,"height","100%"),a.setAttributeNS(null,"x",i.toString()),a.setAttributeNS(null,"y",r.toString()),a.setAttributeNS(null,"externalResourcesRequired","true"),o.appendChild(a),a.appendChild(n),o},fm=function(e){return new Promise(function(t,i){var r=new Image;r.onload=function(){return t(r)},r.onerror=i,r.src="data:image/svg+xml;charset=utf-8,"+encodeURIComponent((new XMLSerializer).serializeToString(e))})},gm={get SUPPORT_RANGE_BOUNDS(){var e=function(e){if(e.createRange){var t=e.createRange();if(t.getBoundingClientRect){var i=e.createElement("boundtest");i.style.height="123px",i.style.display="block",e.body.appendChild(i),t.selectNode(i);var r=t.getBoundingClientRect(),n=Math.round(r.height);if(e.body.removeChild(i),123===n)return!0}}return!1}(document);return Object.defineProperty(gm,"SUPPORT_RANGE_BOUNDS",{value:e}),e},get SUPPORT_WORD_BREAKING(){var e=gm.SUPPORT_RANGE_BOUNDS&&function(e){var t=e.createElement("boundtest");t.style.width="50px",t.style.display="block",t.style.fontSize="12px",t.style.letterSpacing="0px",t.style.wordSpacing="0px",e.body.appendChild(t);var i=e.createRange();t.innerHTML="function"==typeof"".repeat?"👨".repeat(10):"";var r=t.firstChild,n=EA(r.data).map(function(e){return SA(e)}),s=0,o={},a=n.every(function(e,t){i.setStart(r,s),i.setEnd(r,s+e.length);var n=i.getBoundingClientRect();s+=e.length;var a=n.x>o.x||n.y>o.y;return o=n,0===t||a});return e.body.removeChild(t),a}(document);return Object.defineProperty(gm,"SUPPORT_WORD_BREAKING",{value:e}),e},get SUPPORT_SVG_DRAWING(){var e=function(e){var t=new Image,i=e.createElement("canvas"),r=i.getContext("2d");if(!r)return!1;t.src="data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg'></svg>";try{r.drawImage(t,0,0),i.toDataURL()}catch(e){return!1}return!0}(document);return Object.defineProperty(gm,"SUPPORT_SVG_DRAWING",{value:e}),e},get SUPPORT_FOREIGNOBJECT_DRAWING(){var e="function"==typeof Array.from&&"function"==typeof window.fetch?function(e){var t=e.createElement("canvas"),i=100;t.width=i,t.height=i;var r=t.getContext("2d");if(!r)return Promise.reject(!1);r.fillStyle="rgb(0, 255, 0)",r.fillRect(0,0,i,i);var n=new Image,s=t.toDataURL();n.src=s;var o=pm(i,i,0,0,n);return r.fillStyle="red",r.fillRect(0,0,i,i),fm(o).then(function(t){r.drawImage(t,0,0);var n=r.getImageData(0,0,i,i).data;r.fillStyle="red",r.fillRect(0,0,i,i);var o=e.createElement("div");return o.style.backgroundImage="url("+s+")",o.style.height=i+"px",dm(n)?fm(pm(i,i,0,0,o)):Promise.reject(!1)}).then(function(e){return r.drawImage(e,0,0),dm(r.getImageData(0,0,i,i).data)}).catch(function(){return!1})}(document):Promise.resolve(!1);return Object.defineProperty(gm,"SUPPORT_FOREIGNOBJECT_DRAWING",{value:e}),e},get SUPPORT_CORS_IMAGES(){var e=void 0!==(new Image).crossOrigin;return Object.defineProperty(gm,"SUPPORT_CORS_IMAGES",{value:e}),e},get SUPPORT_RESPONSE_TYPE(){var e="string"==typeof(new XMLHttpRequest).responseType;return Object.defineProperty(gm,"SUPPORT_RESPONSE_TYPE",{value:e}),e},get SUPPORT_CORS_XHR(){var e="withCredentials"in new XMLHttpRequest;return Object.defineProperty(gm,"SUPPORT_CORS_XHR",{value:e}),e},get SUPPORT_NATIVE_TEXT_SEGMENTATION(){var e=!("undefined"==typeof Intl||!Intl.Segmenter);return Object.defineProperty(gm,"SUPPORT_NATIVE_TEXT_SEGMENTATION",{value:e}),e}},mm=function(e,t){this.text=e,this.bounds=t},vm=function(e,t){var i=t.ownerDocument;if(i){var r=i.createElement("html2canvaswrapper");r.appendChild(t.cloneNode(!0));var n=t.parentNode;if(n){n.replaceChild(r,t);var s=kA(e,r);return r.firstChild&&n.replaceChild(r.firstChild,r),s}}return MA.EMPTY},_m=function(e,t,i){var r=e.ownerDocument;if(!r)throw new Error("Node has no owner document");var n=r.createRange();return n.setStart(e,t),n.setEnd(e,t+i),n},ym=function(e){if(gm.SUPPORT_NATIVE_TEXT_SEGMENTATION){var t=new Intl.Segmenter(void 0,{granularity:"grapheme"});return Array.from(t.segment(e)).map(function(e){return e.segment})}return function(e){for(var t,i=Am(e),r=[];!(t=i.next()).done;)t.value&&r.push(t.value.slice());return r}(e)},bm=function(e,t){return 0!==t.letterSpacing?ym(e):function(e,t){if(gm.SUPPORT_NATIVE_TEXT_SEGMENTATION){var i=new Intl.Segmenter(void 0,{granularity:"word"});return Array.from(i.segment(e)).map(function(e){return e.segment})}return xm(e,t)}(e,t)},wm=[32,160,4961,65792,65793,4153,4241],xm=function(e,t){for(var i,r=function(e,t){var i=EA(e),r=Cd(i,t),n=r[0],s=r[1],o=r[2],a=i.length,l=0,u=0;return{next:function(){if(u>=a)return{done:!0,value:null};for(var e=dd;u<a&&(e=Pd(i,s,n,++u,o))===dd;);if(e!==dd||u===a){var t=new Md(i,e,l,u);return l=u,{value:t,done:!1}}return{done:!0,value:null}}}}(e,{lineBreak:t.lineBreak,wordBreak:"break-word"===t.overflowWrap?"break-word":t.wordBreak}),n=[],s=function(){if(i.value){var e=i.value.slice(),t=EA(e),r="";t.forEach(function(e){-1===wm.indexOf(e)?r+=SA(e):(r.length&&n.push(r),n.push(SA(e)),r="")}),r.length&&n.push(r)}};!(i=r.next()).done;)s();return n},Bm=function(e,t,i){this.text=Pm(t.data,i.textTransform),this.textBounds=function(e,t,i,r){var n=bm(t,i),s=[],o=0;return n.forEach(function(t){if(i.textDecorationLine.length||t.trim().length>0)if(gm.SUPPORT_RANGE_BOUNDS){var n=_m(r,o,t.length).getClientRects();if(n.length>1){var a=ym(t),l=0;a.forEach(function(t){s.push(new mm(t,MA.fromDOMRectList(e,_m(r,l+o,t.length).getClientRects()))),l+=t.length})}else s.push(new mm(t,MA.fromDOMRectList(e,n)))}else{var u=r.splitText(t.length);s.push(new mm(t,vm(e,r))),r=u}else gm.SUPPORT_RANGE_BOUNDS||(r=r.splitText(t.length));o+=t.length}),s}(e,this.text,i,t)},Pm=function(e,t){switch(t){case 1:return e.toLowerCase();case 3:return e.replace(Cm,Mm);case 2:return e.toUpperCase();default:return e}},Cm=/(^|\s|:|-|\(|\))([a-z])/g,Mm=function(e,t,i){return e.length>0?t+i.toUpperCase():e},km=function(e){function t(t,i){var r=e.call(this,t,i)||this;return r.src=i.currentSrc||i.src,r.intrinsicWidth=i.naturalWidth,r.intrinsicHeight=i.naturalHeight,r.context.cache.addImage(r.src),r}return wA(t,e),t}(Kg),Em=function(e){function t(t,i){var r=e.call(this,t,i)||this;return r.canvas=i,r.intrinsicWidth=i.width,r.intrinsicHeight=i.height,r}return wA(t,e),t}(Kg),Sm=function(e){function t(t,i){var r=e.call(this,t,i)||this,n=new XMLSerializer,s=kA(t,i);return i.setAttribute("width",s.width+"px"),i.setAttribute("height",s.height+"px"),r.svg="data:image/svg+xml,"+encodeURIComponent(n.serializeToString(i)),r.intrinsicWidth=i.width.baseVal.value,r.intrinsicHeight=i.height.baseVal.value,r.context.cache.addImage(r.svg),r}return wA(t,e),t}(Kg),Tm=function(e){function t(t,i){var r=e.call(this,t,i)||this;return r.value=i.value,r}return wA(t,e),t}(Kg),Im=function(e){function t(t,i){var r=e.call(this,t,i)||this;return r.start=i.start,r.reversed="boolean"==typeof i.reversed&&!0===i.reversed,r}return wA(t,e),t}(Kg),Fm=[{type:15,flags:0,unit:"px",number:3}],Dm=[{type:16,flags:0,number:50}],Rm="checkbox",Om="radio",Lm="password",jm=707406591,Um=function(e){function t(t,i){var r,n=e.call(this,t,i)||this;switch(n.type=i.type.toLowerCase(),n.checked=i.checked,n.value=function(e){var t=e.type===Lm?new Array(e.value.length+1).join("•"):e.value;return 0===t.length?e.placeholder||"":t}(i),n.type!==Rm&&n.type!==Om||(n.styles.backgroundColor=3739148031,n.styles.borderTopColor=n.styles.borderRightColor=n.styles.borderBottomColor=n.styles.borderLeftColor=2779096575,n.styles.borderTopWidth=n.styles.borderRightWidth=n.styles.borderBottomWidth=n.styles.borderLeftWidth=1,n.styles.borderTopStyle=n.styles.borderRightStyle=n.styles.borderBottomStyle=n.styles.borderLeftStyle=1,n.styles.backgroundClip=[0],n.styles.backgroundOrigin=[0],n.bounds=(r=n.bounds).width>r.height?new MA(r.left+(r.width-r.height)/2,r.top,r.height,r.height):r.width<r.height?new MA(r.left,r.top+(r.height-r.width)/2,r.width,r.width):r),n.type){case Rm:n.styles.borderTopRightRadius=n.styles.borderTopLeftRadius=n.styles.borderBottomRightRadius=n.styles.borderBottomLeftRadius=Fm;break;case Om:n.styles.borderTopRightRadius=n.styles.borderTopLeftRadius=n.styles.borderBottomRightRadius=n.styles.borderBottomLeftRadius=Dm}return n}return wA(t,e),t}(Kg),Nm=function(e){function t(t,i){var r=e.call(this,t,i)||this,n=i.options[i.selectedIndex||0];return r.value=n&&n.text||"",r}return wA(t,e),t}(Kg),Vm=function(e){function t(t,i){var r=e.call(this,t,i)||this;return r.value=i.value,r}return wA(t,e),t}(Kg),Qm=function(e){function t(t,i){var r=e.call(this,t,i)||this;r.src=i.src,r.width=parseInt(i.width,10)||0,r.height=parseInt(i.height,10)||0,r.backgroundColor=r.styles.backgroundColor;try{if(i.contentWindow&&i.contentWindow.document&&i.contentWindow.document.documentElement){r.tree=Wm(t,i.contentWindow.document.documentElement);var n=i.contentWindow.document.documentElement?Qp(t,getComputedStyle(i.contentWindow.document.documentElement).backgroundColor):Hp.TRANSPARENT,s=i.contentWindow.document.body?Qp(t,getComputedStyle(i.contentWindow.document.body).backgroundColor):Hp.TRANSPARENT;r.backgroundColor=Dp(n)?Dp(s)?r.styles.backgroundColor:s:n}}catch(e){}return r}return wA(t,e),t}(Kg),Hm=["OL","UL","MENU"],Gm=function(e,t,i,r){for(var n=t.firstChild,s=void 0;n;n=s)if(s=n.nextSibling,qm(n)&&n.data.trim().length>0)i.textNodes.push(new Bm(e,n,i.styles));else if(Ym(n))if(hv(n)&&n.assignedNodes)n.assignedNodes().forEach(function(t){return Gm(e,t,i,r)});else{var o=zm(e,n);o.styles.isVisible()&&(Km(n,o,r)?o.flags|=4:Xm(o.styles)&&(o.flags|=2),-1!==Hm.indexOf(n.tagName)&&(o.flags|=8),i.elements.push(o),n.slot,n.shadowRoot?Gm(e,n.shadowRoot,o,r):uv(n)||iv(n)||cv(n)||Gm(e,n,o,r))}},zm=function(e,t){return ov(t)?new km(e,t):nv(t)?new Em(e,t):iv(t)?new Sm(e,t):$m(t)?new Tm(e,t):ev(t)?new Im(e,t):tv(t)?new Um(e,t):cv(t)?new Nm(e,t):uv(t)?new Vm(e,t):av(t)?new Qm(e,t):new Kg(e,t)},Wm=function(e,t){var i=zm(e,t);return i.flags|=4,Gm(e,t,i,i),i},Km=function(e,t,i){return t.styles.isPositionedWithZIndex()||t.styles.opacity<1||t.styles.isTransformed()||rv(e)&&i.styles.isTransparent()},Xm=function(e){return e.isPositioned()||e.isFloating()},qm=function(e){return e.nodeType===Node.TEXT_NODE},Ym=function(e){return e.nodeType===Node.ELEMENT_NODE},Jm=function(e){return Ym(e)&&void 0!==e.style&&!Zm(e)},Zm=function(e){return"object"===w(e.className)},$m=function(e){return"LI"===e.tagName},ev=function(e){return"OL"===e.tagName},tv=function(e){return"INPUT"===e.tagName},iv=function(e){return"svg"===e.tagName},rv=function(e){return"BODY"===e.tagName},nv=function(e){return"CANVAS"===e.tagName},sv=function(e){return"VIDEO"===e.tagName},ov=function(e){return"IMG"===e.tagName},av=function(e){return"IFRAME"===e.tagName},lv=function(e){return"STYLE"===e.tagName},uv=function(e){return"TEXTAREA"===e.tagName},cv=function(e){return"SELECT"===e.tagName},hv=function(e){return"SLOT"===e.tagName},Av=function(e){return e.tagName.indexOf("-")>0},dv=function(){function e(){this.counters={}}return e.prototype.getCounterValue=function(e){var t=this.counters[e];return t&&t.length?t[t.length-1]:1},e.prototype.getCounterValues=function(e){var t=this.counters[e];return t||[]},e.prototype.pop=function(e){var t=this;e.forEach(function(e){return t.counters[e].pop()})},e.prototype.parse=function(e){var t=this,i=e.counterIncrement,r=e.counterReset,n=!0;null!==i&&i.forEach(function(e){var i=t.counters[e.counter];i&&0!==e.increment&&(n=!1,i.length||i.push(1),i[Math.max(0,i.length-1)]+=e.increment)});var s=[];return n&&r.forEach(function(e){var i=t.counters[e.counter];s.push(e.counter),i||(i=t.counters[e.counter]=[]),i.push(e.reset)}),s},e}(),pv={integers:[1e3,900,500,400,100,90,50,40,10,9,5,4,1],values:["M","CM","D","CD","C","XC","L","XL","X","IX","V","IV","I"]},fv={integers:[9e3,8e3,7e3,6e3,5e3,4e3,3e3,2e3,1e3,900,800,700,600,500,400,300,200,100,90,80,70,60,50,40,30,20,10,9,8,7,6,5,4,3,2,1],values:["Ք","Փ","Ւ","Ց","Ր","Տ","Վ","Ս","Ռ","Ջ","Պ","Չ","Ո","Շ","Ն","Յ","Մ","Ճ","Ղ","Ձ","Հ","Կ","Ծ","Խ","Լ","Ի","Ժ","Թ","Ը","Է","Զ","Ե","Դ","Գ","Բ","Ա"]},gv={integers:[1e4,9e3,8e3,7e3,6e3,5e3,4e3,3e3,2e3,1e3,400,300,200,100,90,80,70,60,50,40,30,20,19,18,17,16,15,10,9,8,7,6,5,4,3,2,1],values:["י׳","ט׳","ח׳","ז׳","ו׳","ה׳","ד׳","ג׳","ב׳","א׳","ת","ש","ר","ק","צ","פ","ע","ס","נ","מ","ל","כ","יט","יח","יז","טז","טו","י","ט","ח","ז","ו","ה","ד","ג","ב","א"]},mv={integers:[1e4,9e3,8e3,7e3,6e3,5e3,4e3,3e3,2e3,1e3,900,800,700,600,500,400,300,200,100,90,80,70,60,50,40,30,20,10,9,8,7,6,5,4,3,2,1],values:["ჵ","ჰ","ჯ","ჴ","ხ","ჭ","წ","ძ","ც","ჩ","შ","ყ","ღ","ქ","ფ","ჳ","ტ","ს","რ","ჟ","პ","ო","ჲ","ნ","მ","ლ","კ","ი","თ","ჱ","ზ","ვ","ე","დ","გ","ბ","ა"]},vv=function(e,t,i,r,n,s){return e<t||e>i?Mv(e,n,s.length>0):r.integers.reduce(function(t,i,n){for(;e>=i;)e-=i,t+=r.values[n];return t},"")+s},_v=function(e,t,i,r){var n="";do{i||e--,n=r(e)+n,e/=t}while(e*t>=t);return n},yv=function(e,t,i,r,n){var s=i-t+1;return(e<0?"-":"")+(_v(Math.abs(e),s,r,function(e){return SA(Math.floor(e%s)+t)})+n)},bv=function(e,t,i){void 0===i&&(i=". ");var r=t.length;return _v(Math.abs(e),r,!1,function(e){return t[Math.floor(e%r)]})+i},wv=function(e,t,i,r,n,s){if(e<-9999||e>9999)return Mv(e,4,n.length>0);var o=Math.abs(e),a=n;if(0===o)return t[0]+a;for(var l=0;o>0&&l<=4;l++){var u=o%10;0===u&&Tg(s,1)&&""!==a?a=t[u]+a:u>1||1===u&&0===l||1===u&&1===l&&Tg(s,2)||1===u&&1===l&&Tg(s,4)&&e>100||1===u&&l>1&&Tg(s,8)?a=t[u]+(l>0?i[l-1]:"")+a:1===u&&l>0&&(a=i[l-1]+a),o=Math.floor(o/10)}return(e<0?r:"")+a},xv="十百千萬",Bv="拾佰仟萬",Pv="マイナス",Cv="마이너스",Mv=function(e,t,i){var r=i?". ":"",n=i?"、":"",s=i?", ":"",o=i?" ":"";switch(t){case 0:return"•"+o;case 1:return"◦"+o;case 2:return"◾"+o;case 5:var a=yv(e,48,57,!0,r);return a.length<4?"0"+a:a;case 4:return bv(e,"〇一二三四五六七八九",n);case 6:return vv(e,1,3999,pv,3,r).toLowerCase();case 7:return vv(e,1,3999,pv,3,r);case 8:return yv(e,945,969,!1,r);case 9:return yv(e,97,122,!1,r);case 10:return yv(e,65,90,!1,r);case 11:return yv(e,1632,1641,!0,r);case 12:case 49:return vv(e,1,9999,fv,3,r);case 35:return vv(e,1,9999,fv,3,r).toLowerCase();case 13:return yv(e,2534,2543,!0,r);case 14:case 30:return yv(e,6112,6121,!0,r);case 15:return bv(e,"子丑寅卯辰巳午未申酉戌亥",n);case 16:return bv(e,"甲乙丙丁戊己庚辛壬癸",n);case 17:case 48:return wv(e,"零一二三四五六七八九",xv,"負",n,14);case 47:return wv(e,"零壹貳參肆伍陸柒捌玖",Bv,"負",n,15);case 42:return wv(e,"零一二三四五六七八九",xv,"负",n,14);case 41:return wv(e,"零壹贰叁肆伍陆柒捌玖",Bv,"负",n,15);case 26:return wv(e,"〇一二三四五六七八九","十百千万",Pv,n,0);case 25:return wv(e,"零壱弐参四伍六七八九","拾百千万",Pv,n,7);case 31:return wv(e,"영일이삼사오육칠팔구","십백천만",Cv,s,7);case 33:return wv(e,"零一二三四五六七八九","十百千萬",Cv,s,0);case 32:return wv(e,"零壹貳參四五六七八九","拾百千",Cv,s,7);case 18:return yv(e,2406,2415,!0,r);case 20:return vv(e,1,19999,mv,3,r);case 21:return yv(e,2790,2799,!0,r);case 22:return yv(e,2662,2671,!0,r);case 22:return vv(e,1,10999,gv,3,r);case 23:return bv(e,"あいうえおかきくけこさしすせそたちつてとなにぬねのはひふへほまみむめもやゆよらりるれろわゐゑをん");case 24:return bv(e,"いろはにほへとちりぬるをわかよたれそつねならむうゐのおくやまけふこえてあさきゆめみしゑひもせす");case 27:return yv(e,3302,3311,!0,r);case 28:return bv(e,"アイウエオカキクケコサシスセソタチツテトナニヌネノハヒフヘホマミムメモヤユヨラリルレロワヰヱヲン",n);case 29:return bv(e,"イロハニホヘトチリヌルヲワカヨタレソツネナラムウヰノオクヤマケフコエテアサキユメミシヱヒモセス",n);case 34:return yv(e,3792,3801,!0,r);case 37:return yv(e,6160,6169,!0,r);case 38:return yv(e,4160,4169,!0,r);case 39:return yv(e,2918,2927,!0,r);case 40:return yv(e,1776,1785,!0,r);case 43:return yv(e,3046,3055,!0,r);case 44:return yv(e,3174,3183,!0,r);case 45:return yv(e,3664,3673,!0,r);case 46:return yv(e,3872,3881,!0,r);default:return yv(e,48,57,!0,r)}},kv="data-html2canvas-ignore",Ev=function(){function e(e,t,i){if(this.context=e,this.options=i,this.scrolledElements=[],this.referenceElement=t,this.counters=new dv,this.quoteDepth=0,!t.ownerDocument)throw new Error("Cloned element does not have an owner document");this.documentElement=this.cloneNode(t.ownerDocument.documentElement,!1)}return e.prototype.toIFrame=function(e,t){var i=this,r=Tv(e,t);if(!r.contentWindow)return Promise.reject("Unable to find iframe window");var n=e.defaultView.pageXOffset,s=e.defaultView.pageYOffset,o=r.contentWindow,a=o.document,l=Dv(r).then(function(){return BA(i,void 0,void 0,function(){var e,i;return PA(this,function(n){switch(n.label){case 0:return this.scrolledElements.forEach(Uv),o&&(o.scrollTo(t.left,t.top),!/(iPad|iPhone|iPod)/g.test(navigator.userAgent)||o.scrollY===t.top&&o.scrollX===t.left||(this.context.logger.warn("Unable to restore scroll position for cloned document"),this.context.windowBounds=this.context.windowBounds.add(o.scrollX-t.left,o.scrollY-t.top,0,0))),e=this.options.onclone,void 0===(i=this.clonedReferenceElement)?[2,Promise.reject("Error finding the "+this.referenceElement.nodeName+" in the cloned document")]:a.fonts&&a.fonts.ready?[4,a.fonts.ready]:[3,2];case 1:n.sent(),n.label=2;case 2:return/(AppleWebKit)/g.test(navigator.userAgent)?[4,Fv(a)]:[3,4];case 3:n.sent(),n.label=4;case 4:return"function"==typeof e?[2,Promise.resolve().then(function(){return e(a,i)}).then(function(){return r})]:[2,r]}})})});return a.open(),a.write(Lv(document.doctype)+"<html></html>"),jv(this.referenceElement.ownerDocument,n,s),a.replaceChild(a.adoptNode(this.documentElement),a.documentElement),a.close(),l},e.prototype.createElementClone=function(e){if(Wg(e,2),nv(e))return this.createCanvasClone(e);if(sv(e))return this.createVideoClone(e);if(lv(e))return this.createStyleClone(e);var t=e.cloneNode(!1);return ov(t)&&(ov(e)&&e.currentSrc&&e.currentSrc!==e.src&&(t.src=e.currentSrc,t.srcset=""),"lazy"===t.loading&&(t.loading="eager")),Av(t)?this.createCustomElementClone(t):t},e.prototype.createCustomElementClone=function(e){var t=document.createElement("html2canvascustomelement");return Ov(e.style,t),t},e.prototype.createStyleClone=function(e){try{var t=e.sheet;if(t&&t.cssRules){var i=[].slice.call(t.cssRules,0).reduce(function(e,t){return t&&"string"==typeof t.cssText?e+t.cssText:e},""),r=e.cloneNode(!1);return r.textContent=i,r}}catch(e){if(this.context.logger.error("Unable to access cssRules property",e),"SecurityError"!==e.name)throw e}return e.cloneNode(!1)},e.prototype.createCanvasClone=function(e){var t;if(this.options.inlineImages&&e.ownerDocument){var i=e.ownerDocument.createElement("img");try{return i.src=e.toDataURL(),i}catch(t){this.context.logger.info("Unable to inline canvas contents, canvas is tainted",e)}}var r=e.cloneNode(!1);try{r.width=e.width,r.height=e.height;var n=e.getContext("2d"),s=r.getContext("2d");if(s)if(!this.options.allowTaint&&n)s.putImageData(n.getImageData(0,0,e.width,e.height),0,0);else{var o=null!==(t=e.getContext("webgl2"))&&void 0!==t?t:e.getContext("webgl");if(o){var a=o.getContextAttributes();!1===(null==a?void 0:a.preserveDrawingBuffer)&&this.context.logger.warn("Unable to clone WebGL context as it has preserveDrawingBuffer=false",e)}s.drawImage(e,0,0)}return r}catch(t){this.context.logger.info("Unable to clone canvas as it is tainted",e)}return r},e.prototype.createVideoClone=function(e){var t=e.ownerDocument.createElement("canvas");t.width=e.offsetWidth,t.height=e.offsetHeight;var i=t.getContext("2d");try{return i&&(i.drawImage(e,0,0,t.width,t.height),this.options.allowTaint||i.getImageData(0,0,t.width,t.height)),t}catch(t){this.context.logger.info("Unable to clone video as it is tainted",e)}var r=e.ownerDocument.createElement("canvas");return r.width=e.offsetWidth,r.height=e.offsetHeight,r},e.prototype.appendChildNode=function(e,t,i){Ym(t)&&(function(e){return"SCRIPT"===e.tagName}(t)||t.hasAttribute(kv)||"function"==typeof this.options.ignoreElements&&this.options.ignoreElements(t))||this.options.copyStyles&&Ym(t)&&lv(t)||e.appendChild(this.cloneNode(t,i))},e.prototype.cloneChildNodes=function(e,t,i){for(var r=this,n=e.shadowRoot?e.shadowRoot.firstChild:e.firstChild;n;n=n.nextSibling)if(Ym(n)&&hv(n)&&"function"==typeof n.assignedNodes){var s=n.assignedNodes();s.length&&s.forEach(function(e){return r.appendChildNode(t,e,i)})}else this.appendChildNode(t,n,i)},e.prototype.cloneNode=function(e,t){if(qm(e))return document.createTextNode(e.data);if(!e.ownerDocument)return e.cloneNode(!1);var i=e.ownerDocument.defaultView;if(i&&Ym(e)&&(Jm(e)||Zm(e))){var r=this.createElementClone(e);r.style.transitionProperty="none";var n=i.getComputedStyle(e),s=i.getComputedStyle(e,":before"),o=i.getComputedStyle(e,":after");this.referenceElement===e&&Jm(r)&&(this.clonedReferenceElement=r),rv(r)&&Hv(r);var a=this.counters.parse(new Gg(this.context,n)),l=this.resolvePseudoContent(e,r,s,im.BEFORE);Av(e)&&(t=!0),sv(e)||this.cloneChildNodes(e,r,t),l&&r.insertBefore(l,r.firstChild);var u=this.resolvePseudoContent(e,r,o,im.AFTER);return u&&r.appendChild(u),this.counters.pop(a),(n&&(this.options.copyStyles||Zm(e))&&!av(e)||t)&&Ov(n,r),0===e.scrollTop&&0===e.scrollLeft||this.scrolledElements.push([r,e.scrollLeft,e.scrollTop]),(uv(e)||cv(e))&&(uv(r)||cv(r))&&(r.value=e.value),r}return e.cloneNode(!1)},e.prototype.resolvePseudoContent=function(e,t,i,r){var n=this;if(i){var s=i.content,o=t.ownerDocument;if(o&&s&&"none"!==s&&"-moz-alt-content"!==s&&"none"!==i.display){this.counters.parse(new Gg(this.context,i));var a=new Hg(this.context,i),l=o.createElement("html2canvaspseudoelement");Ov(i,l),a.content.forEach(function(t){if(0===t.type)l.appendChild(o.createTextNode(t.value));else if(22===t.type){var i=o.createElement("img");i.src=t.value,i.style.opacity="1",l.appendChild(i)}else if(18===t.type){if("attr"===t.name){var r=t.values.filter(Ap);r.length&&l.appendChild(o.createTextNode(e.getAttribute(r[0].value)||""))}else if("counter"===t.name){var s=t.values.filter(gp),u=s[0],c=s[1];if(u&&Ap(u)){var h=n.counters.getCounterValue(u.value),A=c&&Ap(c)?Jf.parse(n.context,c.value):3;l.appendChild(o.createTextNode(Mv(h,A,!1)))}}else if("counters"===t.name){var d=t.values.filter(gp),p=(u=d[0],d[1]);c=d[2];if(u&&Ap(u)){var f=n.counters.getCounterValues(u.value),g=c&&Ap(c)?Jf.parse(n.context,c.value):3,m=p&&0===p.type?p.value:"",v=f.map(function(e){return Mv(e,g,!1)}).join(m);l.appendChild(o.createTextNode(v))}}}else if(20===t.type)switch(t.value){case"open-quote":l.appendChild(o.createTextNode(Lg(a.quotes,n.quoteDepth++,!0)));break;case"close-quote":l.appendChild(o.createTextNode(Lg(a.quotes,--n.quoteDepth,!1)));break;default:l.appendChild(o.createTextNode(t.value))}}),l.className=Nv+" "+Vv;var u=r===im.BEFORE?" "+Nv:" "+Vv;return Zm(t)?t.className.baseValue+=u:t.className+=u,l}}},e.destroy=function(e){return!!e.parentNode&&(e.parentNode.removeChild(e),!0)},e}();!function(e){e[e.BEFORE=0]="BEFORE",e[e.AFTER=1]="AFTER"}(im||(im={}));var Sv,Tv=function(e,t){var i=e.createElement("iframe");return i.className="html2canvas-container",i.style.visibility="hidden",i.style.position="fixed",i.style.left="-10000px",i.style.top="0px",i.style.border="0",i.width=t.width.toString(),i.height=t.height.toString(),i.scrolling="no",i.setAttribute(kv,"true"),e.body.appendChild(i),i},Iv=function(e){return new Promise(function(t){e.complete?t():e.src?(e.onload=t,e.onerror=t):t()})},Fv=function(e){return Promise.all([].slice.call(e.images,0).map(Iv))},Dv=function(e){return new Promise(function(t,i){var r=e.contentWindow;if(!r)return i("No window assigned for iframe");var n=r.document;r.onload=e.onload=function(){r.onload=e.onload=null;var i=setInterval(function(){n.body.childNodes.length>0&&"complete"===n.readyState&&(clearInterval(i),t(e))},50)}})},Rv=["all","d","content"],Ov=function(e,t){for(var i=e.length-1;i>=0;i--){var r=e.item(i);-1===Rv.indexOf(r)&&t.style.setProperty(r,e.getPropertyValue(r))}return t},Lv=function(e){var t="";return e&&(t+="<!DOCTYPE ",e.name&&(t+=e.name),e.internalSubset&&(t+=e.internalSubset),e.publicId&&(t+='"'+e.publicId+'"'),e.systemId&&(t+='"'+e.systemId+'"'),t+=">"),t},jv=function(e,t,i){e&&e.defaultView&&(t!==e.defaultView.pageXOffset||i!==e.defaultView.pageYOffset)&&e.defaultView.scrollTo(t,i)},Uv=function(e){var t=e[0],i=e[1],r=e[2];t.scrollLeft=i,t.scrollTop=r},Nv="___html2canvas___pseudoelement_before",Vv="___html2canvas___pseudoelement_after",Qv='{\n content: "" !important;\n display: none !important;\n}',Hv=function(e){Gv(e,"."+Nv+":before"+Qv+"\n ."+Vv+":after"+Qv)},Gv=function(e,t){var i=e.ownerDocument;if(i){var r=i.createElement("style");r.textContent=t,e.appendChild(r)}},zv=function(){function e(){}return e.getOrigin=function(t){var i=e._link;return i?(i.href=t,i.href=i.href,i.protocol+i.hostname+i.port):"about:blank"},e.isSameOrigin=function(t){return e.getOrigin(t)===e._origin},e.setContext=function(t){e._link=t.document.createElement("a"),e._origin=e.getOrigin(t.location.href)},e._origin="about:blank",e}(),Wv=function(){function e(e,t){this.context=e,this._options=t,this._cache={}}return e.prototype.addImage=function(e){var t=Promise.resolve();return this.has(e)?t:$v(e)||Yv(e)?((this._cache[e]=this.loadImage(e)).catch(function(){}),t):t},e.prototype.match=function(e){return this._cache[e]},e.prototype.loadImage=function(e){return BA(this,void 0,void 0,function(){var t,i,r,n,s=this;return PA(this,function(o){switch(o.label){case 0:return t=zv.isSameOrigin(e),i=!Jv(e)&&!0===this._options.useCORS&&gm.SUPPORT_CORS_IMAGES&&!t,r=!Jv(e)&&!t&&!$v(e)&&"string"==typeof this._options.proxy&&gm.SUPPORT_CORS_XHR&&!i,t||!1!==this._options.allowTaint||Jv(e)||$v(e)||r||i?(n=e,r?[4,this.proxy(n)]:[3,2]):[2];case 1:n=o.sent(),o.label=2;case 2:return this.context.logger.debug("Added image "+e.substring(0,256)),[4,new Promise(function(e,t){var r=new Image;r.onload=function(){return e(r)},r.onerror=t,(Zv(n)||i)&&(r.crossOrigin="anonymous"),r.src=n,!0===r.complete&&setTimeout(function(){return e(r)},500),s._options.imageTimeout>0&&setTimeout(function(){return t("Timed out ("+s._options.imageTimeout+"ms) loading image")},s._options.imageTimeout)})];case 3:return[2,o.sent()]}})})},e.prototype.has=function(e){return void 0!==this._cache[e]},e.prototype.keys=function(){return Promise.resolve(Object.keys(this._cache))},e.prototype.proxy=function(e){var t=this,i=this._options.proxy;if(!i)throw new Error("No proxy defined");var r=e.substring(0,256);return new Promise(function(n,s){var o=gm.SUPPORT_RESPONSE_TYPE?"blob":"text",a=new XMLHttpRequest;a.onload=function(){if(200===a.status)if("text"===o)n(a.response);else{var e=new FileReader;e.addEventListener("load",function(){return n(e.result)},!1),e.addEventListener("error",function(e){return s(e)},!1),e.readAsDataURL(a.response)}else s("Failed to proxy resource "+r+" with status code "+a.status)},a.onerror=s;var l=i.indexOf("?")>-1?"&":"?";if(a.open("GET",""+i+l+"url="+encodeURIComponent(e)+"&responseType="+o),"text"!==o&&a instanceof XMLHttpRequest&&(a.responseType=o),t._options.imageTimeout){var u=t._options.imageTimeout;a.timeout=u,a.ontimeout=function(){return s("Timed out ("+u+"ms) proxying "+r)}}a.send()})},e}(),Kv=/^data:image\/svg\+xml/i,Xv=/^data:image\/.*;base64,/i,qv=/^data:image\/.*/i,Yv=function(e){return gm.SUPPORT_SVG_DRAWING||!e_(e)},Jv=function(e){return qv.test(e)},Zv=function(e){return Xv.test(e)},$v=function(e){return"blob"===e.substr(0,4)},e_=function(e){return"svg"===e.substr(-3).toLowerCase()||Kv.test(e)},t_=function(){function e(e,t){this.type=0,this.x=e,this.y=t}return e.prototype.add=function(t,i){return new e(this.x+t,this.y+i)},e}(),i_=function(e,t,i){return new t_(e.x+(t.x-e.x)*i,e.y+(t.y-e.y)*i)},r_=function(){function e(e,t,i,r){this.type=1,this.start=e,this.startControl=t,this.endControl=i,this.end=r}return e.prototype.subdivide=function(t,i){var r=i_(this.start,this.startControl,t),n=i_(this.startControl,this.endControl,t),s=i_(this.endControl,this.end,t),o=i_(r,n,t),a=i_(n,s,t),l=i_(o,a,t);return i?new e(this.start,r,o,l):new e(l,a,s,this.end)},e.prototype.add=function(t,i){return new e(this.start.add(t,i),this.startControl.add(t,i),this.endControl.add(t,i),this.end.add(t,i))},e.prototype.reverse=function(){return new e(this.end,this.endControl,this.startControl,this.start)},e}(),n_=function(e){return 1===e.type},s_=function(e){var t=e.styles,i=e.bounds,r=Pp(t.borderTopLeftRadius,i.width,i.height),n=r[0],s=r[1],o=Pp(t.borderTopRightRadius,i.width,i.height),a=o[0],l=o[1],u=Pp(t.borderBottomRightRadius,i.width,i.height),c=u[0],h=u[1],A=Pp(t.borderBottomLeftRadius,i.width,i.height),d=A[0],p=A[1],f=[];f.push((n+a)/i.width),f.push((d+c)/i.width),f.push((s+p)/i.height),f.push((l+h)/i.height);var g=Math.max.apply(Math,f);g>1&&(n/=g,s/=g,a/=g,l/=g,c/=g,h/=g,d/=g,p/=g);var m=i.width-a,v=i.height-h,_=i.width-c,y=i.height-p,b=t.borderTopWidth,w=t.borderRightWidth,x=t.borderBottomWidth,B=t.borderLeftWidth,P=Cp(t.paddingTop,e.bounds.width),C=Cp(t.paddingRight,e.bounds.width),M=Cp(t.paddingBottom,e.bounds.width),k=Cp(t.paddingLeft,e.bounds.width);this.topLeftBorderDoubleOuterBox=n>0||s>0?o_(i.left+B/3,i.top+b/3,n-B/3,s-b/3,Sv.TOP_LEFT):new t_(i.left+B/3,i.top+b/3),this.topRightBorderDoubleOuterBox=n>0||s>0?o_(i.left+m,i.top+b/3,a-w/3,l-b/3,Sv.TOP_RIGHT):new t_(i.left+i.width-w/3,i.top+b/3),this.bottomRightBorderDoubleOuterBox=c>0||h>0?o_(i.left+_,i.top+v,c-w/3,h-x/3,Sv.BOTTOM_RIGHT):new t_(i.left+i.width-w/3,i.top+i.height-x/3),this.bottomLeftBorderDoubleOuterBox=d>0||p>0?o_(i.left+B/3,i.top+y,d-B/3,p-x/3,Sv.BOTTOM_LEFT):new t_(i.left+B/3,i.top+i.height-x/3),this.topLeftBorderDoubleInnerBox=n>0||s>0?o_(i.left+2*B/3,i.top+2*b/3,n-2*B/3,s-2*b/3,Sv.TOP_LEFT):new t_(i.left+2*B/3,i.top+2*b/3),this.topRightBorderDoubleInnerBox=n>0||s>0?o_(i.left+m,i.top+2*b/3,a-2*w/3,l-2*b/3,Sv.TOP_RIGHT):new t_(i.left+i.width-2*w/3,i.top+2*b/3),this.bottomRightBorderDoubleInnerBox=c>0||h>0?o_(i.left+_,i.top+v,c-2*w/3,h-2*x/3,Sv.BOTTOM_RIGHT):new t_(i.left+i.width-2*w/3,i.top+i.height-2*x/3),this.bottomLeftBorderDoubleInnerBox=d>0||p>0?o_(i.left+2*B/3,i.top+y,d-2*B/3,p-2*x/3,Sv.BOTTOM_LEFT):new t_(i.left+2*B/3,i.top+i.height-2*x/3),this.topLeftBorderStroke=n>0||s>0?o_(i.left+B/2,i.top+b/2,n-B/2,s-b/2,Sv.TOP_LEFT):new t_(i.left+B/2,i.top+b/2),this.topRightBorderStroke=n>0||s>0?o_(i.left+m,i.top+b/2,a-w/2,l-b/2,Sv.TOP_RIGHT):new t_(i.left+i.width-w/2,i.top+b/2),this.bottomRightBorderStroke=c>0||h>0?o_(i.left+_,i.top+v,c-w/2,h-x/2,Sv.BOTTOM_RIGHT):new t_(i.left+i.width-w/2,i.top+i.height-x/2),this.bottomLeftBorderStroke=d>0||p>0?o_(i.left+B/2,i.top+y,d-B/2,p-x/2,Sv.BOTTOM_LEFT):new t_(i.left+B/2,i.top+i.height-x/2),this.topLeftBorderBox=n>0||s>0?o_(i.left,i.top,n,s,Sv.TOP_LEFT):new t_(i.left,i.top),this.topRightBorderBox=a>0||l>0?o_(i.left+m,i.top,a,l,Sv.TOP_RIGHT):new t_(i.left+i.width,i.top),this.bottomRightBorderBox=c>0||h>0?o_(i.left+_,i.top+v,c,h,Sv.BOTTOM_RIGHT):new t_(i.left+i.width,i.top+i.height),this.bottomLeftBorderBox=d>0||p>0?o_(i.left,i.top+y,d,p,Sv.BOTTOM_LEFT):new t_(i.left,i.top+i.height),this.topLeftPaddingBox=n>0||s>0?o_(i.left+B,i.top+b,Math.max(0,n-B),Math.max(0,s-b),Sv.TOP_LEFT):new t_(i.left+B,i.top+b),this.topRightPaddingBox=a>0||l>0?o_(i.left+Math.min(m,i.width-w),i.top+b,m>i.width+w?0:Math.max(0,a-w),Math.max(0,l-b),Sv.TOP_RIGHT):new t_(i.left+i.width-w,i.top+b),this.bottomRightPaddingBox=c>0||h>0?o_(i.left+Math.min(_,i.width-B),i.top+Math.min(v,i.height-x),Math.max(0,c-w),Math.max(0,h-x),Sv.BOTTOM_RIGHT):new t_(i.left+i.width-w,i.top+i.height-x),this.bottomLeftPaddingBox=d>0||p>0?o_(i.left+B,i.top+Math.min(y,i.height-x),Math.max(0,d-B),Math.max(0,p-x),Sv.BOTTOM_LEFT):new t_(i.left+B,i.top+i.height-x),this.topLeftContentBox=n>0||s>0?o_(i.left+B+k,i.top+b+P,Math.max(0,n-(B+k)),Math.max(0,s-(b+P)),Sv.TOP_LEFT):new t_(i.left+B+k,i.top+b+P),this.topRightContentBox=a>0||l>0?o_(i.left+Math.min(m,i.width+B+k),i.top+b+P,m>i.width+B+k?0:a-B+k,l-(b+P),Sv.TOP_RIGHT):new t_(i.left+i.width-(w+C),i.top+b+P),this.bottomRightContentBox=c>0||h>0?o_(i.left+Math.min(_,i.width-(B+k)),i.top+Math.min(v,i.height+b+P),Math.max(0,c-(w+C)),h-(x+M),Sv.BOTTOM_RIGHT):new t_(i.left+i.width-(w+C),i.top+i.height-(x+M)),this.bottomLeftContentBox=d>0||p>0?o_(i.left+B+k,i.top+y,Math.max(0,d-(B+k)),p-(x+M),Sv.BOTTOM_LEFT):new t_(i.left+B+k,i.top+i.height-(x+M))};!function(e){e[e.TOP_LEFT=0]="TOP_LEFT",e[e.TOP_RIGHT=1]="TOP_RIGHT",e[e.BOTTOM_RIGHT=2]="BOTTOM_RIGHT",e[e.BOTTOM_LEFT=3]="BOTTOM_LEFT"}(Sv||(Sv={}));var o_=function(e,t,i,r,n){var s=(Math.sqrt(2)-1)/3*4,o=i*s,a=r*s,l=e+i,u=t+r;switch(n){case Sv.TOP_LEFT:return new r_(new t_(e,u),new t_(e,u-a),new t_(l-o,t),new t_(l,t));case Sv.TOP_RIGHT:return new r_(new t_(e,t),new t_(e+o,t),new t_(l,u-a),new t_(l,u));case Sv.BOTTOM_RIGHT:return new r_(new t_(l,t),new t_(l,t+a),new t_(e+o,u),new t_(e,u));case Sv.BOTTOM_LEFT:default:return new r_(new t_(l,u),new t_(l-o,u),new t_(e,t+a),new t_(e,t))}},a_=function(e){return[e.topLeftBorderBox,e.topRightBorderBox,e.bottomRightBorderBox,e.bottomLeftBorderBox]},l_=function(e){return[e.topLeftPaddingBox,e.topRightPaddingBox,e.bottomRightPaddingBox,e.bottomLeftPaddingBox]},u_=function(e,t,i){this.offsetX=e,this.offsetY=t,this.matrix=i,this.type=0,this.target=6},c_=function(e,t){this.path=e,this.target=t,this.type=1},h_=function(e){this.opacity=e,this.type=2,this.target=6},A_=function(e){return 1===e.type},d_=function(e,t){return e.length===t.length&&e.some(function(e,i){return e===t[i]})},p_=function(e){this.element=e,this.inlineLevel=[],this.nonInlineLevel=[],this.negativeZIndex=[],this.zeroOrAutoZIndexOrTransformedOrOpacity=[],this.positiveZIndex=[],this.nonPositionedFloats=[],this.nonPositionedInlineLevel=[]},f_=function(){function e(e,t){if(this.container=e,this.parent=t,this.effects=[],this.curves=new s_(this.container),this.container.styles.opacity<1&&this.effects.push(new h_(this.container.styles.opacity)),null!==this.container.styles.transform){var i=this.container.bounds.left+this.container.styles.transformOrigin[0].number,r=this.container.bounds.top+this.container.styles.transformOrigin[1].number,n=this.container.styles.transform;this.effects.push(new u_(i,r,n))}if(0!==this.container.styles.overflowX){var s=a_(this.curves),o=l_(this.curves);d_(s,o)?this.effects.push(new c_(s,6)):(this.effects.push(new c_(s,2)),this.effects.push(new c_(o,4)))}}return e.prototype.getEffects=function(e){for(var t=-1===[2,3].indexOf(this.container.styles.position),i=this.parent,r=this.effects.slice(0);i;){var n=i.effects.filter(function(e){return!A_(e)});if(t||0!==i.container.styles.position||!i.parent){if(r.unshift.apply(r,n),t=-1===[2,3].indexOf(i.container.styles.position),0!==i.container.styles.overflowX){var s=a_(i.curves),o=l_(i.curves);d_(s,o)||r.unshift(new c_(o,6))}}else r.unshift.apply(r,n);i=i.parent}return r.filter(function(t){return Tg(t.target,e)})},e}(),g_=function(e,t,i,r){e.container.elements.forEach(function(n){var s=Tg(n.flags,4),o=Tg(n.flags,2),a=new f_(n,e);Tg(n.styles.display,2048)&&r.push(a);var l=Tg(n.flags,8)?[]:r;if(s||o){var u=s||n.styles.isPositioned()?i:t,c=new p_(a);if(n.styles.isPositioned()||n.styles.opacity<1||n.styles.isTransformed()){var h=n.styles.zIndex.order;if(h<0){var A=0;u.negativeZIndex.some(function(e,t){return h>e.element.container.styles.zIndex.order?(A=t,!1):A>0}),u.negativeZIndex.splice(A,0,c)}else if(h>0){var d=0;u.positiveZIndex.some(function(e,t){return h>=e.element.container.styles.zIndex.order?(d=t+1,!1):d>0}),u.positiveZIndex.splice(d,0,c)}else u.zeroOrAutoZIndexOrTransformedOrOpacity.push(c)}else n.styles.isFloating()?u.nonPositionedFloats.push(c):u.nonPositionedInlineLevel.push(c);g_(a,c,s?c:i,l)}else n.styles.isInlineLevel()?t.inlineLevel.push(a):t.nonInlineLevel.push(a),g_(a,t,i,l);Tg(n.flags,8)&&m_(n,l)})},m_=function(e,t){for(var i=e instanceof Im?e.start:1,r=e instanceof Im&&e.reversed,n=0;n<t.length;n++){var s=t[n];s.container instanceof Tm&&"number"==typeof s.container.value&&0!==s.container.value&&(i=s.container.value),s.listValue=Mv(i,s.container.styles.listStyleType,!0),i+=r?-1:1}},v_=function(e,t){switch(t){case 0:return y_(e.topLeftBorderBox,e.topLeftPaddingBox,e.topRightBorderBox,e.topRightPaddingBox);case 1:return y_(e.topRightBorderBox,e.topRightPaddingBox,e.bottomRightBorderBox,e.bottomRightPaddingBox);case 2:return y_(e.bottomRightBorderBox,e.bottomRightPaddingBox,e.bottomLeftBorderBox,e.bottomLeftPaddingBox);default:return y_(e.bottomLeftBorderBox,e.bottomLeftPaddingBox,e.topLeftBorderBox,e.topLeftPaddingBox)}},__=function(e,t){var i=[];return n_(e)?i.push(e.subdivide(.5,!1)):i.push(e),n_(t)?i.push(t.subdivide(.5,!0)):i.push(t),i},y_=function(e,t,i,r){var n=[];return n_(e)?n.push(e.subdivide(.5,!1)):n.push(e),n_(i)?n.push(i.subdivide(.5,!0)):n.push(i),n_(r)?n.push(r.subdivide(.5,!0).reverse()):n.push(r),n_(t)?n.push(t.subdivide(.5,!1).reverse()):n.push(t),n},b_=function(e){var t=e.bounds,i=e.styles;return t.add(i.borderLeftWidth,i.borderTopWidth,-(i.borderRightWidth+i.borderLeftWidth),-(i.borderTopWidth+i.borderBottomWidth))},w_=function(e){var t=e.styles,i=e.bounds,r=Cp(t.paddingLeft,i.width),n=Cp(t.paddingRight,i.width),s=Cp(t.paddingTop,i.width),o=Cp(t.paddingBottom,i.width);return i.add(r+t.borderLeftWidth,s+t.borderTopWidth,-(t.borderRightWidth+t.borderLeftWidth+r+n),-(t.borderTopWidth+t.borderBottomWidth+s+o))},x_=function(e,t,i){var r=function(e,t){return 0===e?t.bounds:2===e?w_(t):b_(t)}(M_(e.styles.backgroundOrigin,t),e),n=function(e,t){return 0===e?t.bounds:2===e?w_(t):b_(t)}(M_(e.styles.backgroundClip,t),e),s=C_(M_(e.styles.backgroundSize,t),i,r),o=s[0],a=s[1],l=Pp(M_(e.styles.backgroundPosition,t),r.width-o,r.height-a);return[k_(M_(e.styles.backgroundRepeat,t),l,s,r,n),Math.round(r.left+l[0]),Math.round(r.top+l[1]),o,a]},B_=function(e){return Ap(e)&&e.value===uf.AUTO},P_=function(e){return"number"==typeof e},C_=function(e,t,i){var r=t[0],n=t[1],s=t[2],o=e[0],a=e[1];if(!o)return[0,0];if(yp(o)&&a&&yp(a))return[Cp(o,i.width),Cp(a,i.height)];var l=P_(s);if(Ap(o)&&(o.value===uf.CONTAIN||o.value===uf.COVER))return P_(s)?i.width/i.height<s!=(o.value===uf.COVER)?[i.width,i.width/s]:[i.height*s,i.height]:[i.width,i.height];var u=P_(r),c=P_(n),h=u||c;if(B_(o)&&(!a||B_(a)))return u&&c?[r,n]:l||h?h&&l?[u?r:n*s,c?n:r/s]:[u?r:i.width,c?n:i.height]:[i.width,i.height];if(l){var A=0,d=0;return yp(o)?A=Cp(o,i.width):yp(a)&&(d=Cp(a,i.height)),B_(o)?A=d*s:a&&!B_(a)||(d=A/s),[A,d]}var p=null,f=null;if(yp(o)?p=Cp(o,i.width):a&&yp(a)&&(f=Cp(a,i.height)),null===p||a&&!B_(a)||(f=u&&c?p/r*n:i.height),null!==f&&B_(o)&&(p=u&&c?f/n*r:i.width),null!==p&&null!==f)return[p,f];throw new Error("Unable to calculate background-size for element")},M_=function(e,t){var i=e[t];return void 0===i?e[0]:i},k_=function(e,t,i,r,n){var s=t[0],o=t[1],a=i[0],l=i[1];switch(e){case 2:return[new t_(Math.round(r.left),Math.round(r.top+o)),new t_(Math.round(r.left+r.width),Math.round(r.top+o)),new t_(Math.round(r.left+r.width),Math.round(l+r.top+o)),new t_(Math.round(r.left),Math.round(l+r.top+o))];case 3:return[new t_(Math.round(r.left+s),Math.round(r.top)),new t_(Math.round(r.left+s+a),Math.round(r.top)),new t_(Math.round(r.left+s+a),Math.round(r.height+r.top)),new t_(Math.round(r.left+s),Math.round(r.height+r.top))];case 1:return[new t_(Math.round(r.left+s),Math.round(r.top+o)),new t_(Math.round(r.left+s+a),Math.round(r.top+o)),new t_(Math.round(r.left+s+a),Math.round(r.top+o+l)),new t_(Math.round(r.left+s),Math.round(r.top+o+l))];default:return[new t_(Math.round(n.left),Math.round(n.top)),new t_(Math.round(n.left+n.width),Math.round(n.top)),new t_(Math.round(n.left+n.width),Math.round(n.height+n.top)),new t_(Math.round(n.left),Math.round(n.height+n.top))]}},E_="Hidden Text",S_=function(){function e(e){this._data={},this._document=e}return e.prototype.parseMetrics=function(e,t){var i=this._document.createElement("div"),r=this._document.createElement("img"),n=this._document.createElement("span"),s=this._document.body;i.style.visibility="hidden",i.style.fontFamily=e,i.style.fontSize=t,i.style.margin="0",i.style.padding="0",i.style.whiteSpace="nowrap",s.appendChild(i),r.src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7",r.width=1,r.height=1,r.style.margin="0",r.style.padding="0",r.style.verticalAlign="baseline",n.style.fontFamily=e,n.style.fontSize=t,n.style.margin="0",n.style.padding="0",n.appendChild(this._document.createTextNode(E_)),i.appendChild(n),i.appendChild(r);var o=r.offsetTop-n.offsetTop+2;i.removeChild(n),i.appendChild(this._document.createTextNode(E_)),i.style.lineHeight="normal",r.style.verticalAlign="super";var a=r.offsetTop-i.offsetTop+2;return s.removeChild(i),{baseline:o,middle:a}},e.prototype.getMetrics=function(e,t){var i=e+" "+t;return void 0===this._data[i]&&(this._data[i]=this.parseMetrics(e,t)),this._data[i]},e}(),T_=function(e,t){this.context=e,this.options=t},I_=function(e){function t(t,i){var r=e.call(this,t,i)||this;return r._activeEffects=[],r.canvas=i.canvas?i.canvas:document.createElement("canvas"),r.ctx=r.canvas.getContext("2d"),i.canvas||(r.canvas.width=Math.floor(i.width*i.scale),r.canvas.height=Math.floor(i.height*i.scale),r.canvas.style.width=i.width+"px",r.canvas.style.height=i.height+"px"),r.fontMetrics=new S_(document),r.ctx.scale(r.options.scale,r.options.scale),r.ctx.translate(-i.x,-i.y),r.ctx.textBaseline="bottom",r._activeEffects=[],r.context.logger.debug("Canvas renderer initialized ("+i.width+"x"+i.height+") with scale "+i.scale),r}return wA(t,e),t.prototype.applyEffects=function(e){for(var t=this;this._activeEffects.length;)this.popEffect();e.forEach(function(e){return t.applyEffect(e)})},t.prototype.applyEffect=function(e){this.ctx.save(),function(e){return 2===e.type}(e)&&(this.ctx.globalAlpha=e.opacity),function(e){return 0===e.type}(e)&&(this.ctx.translate(e.offsetX,e.offsetY),this.ctx.transform(e.matrix[0],e.matrix[1],e.matrix[2],e.matrix[3],e.matrix[4],e.matrix[5]),this.ctx.translate(-e.offsetX,-e.offsetY)),A_(e)&&(this.path(e.path),this.ctx.clip()),this._activeEffects.push(e)},t.prototype.popEffect=function(){this._activeEffects.pop(),this.ctx.restore()},t.prototype.renderStack=function(e){return BA(this,void 0,void 0,function(){return PA(this,function(t){switch(t.label){case 0:return e.element.container.styles.isVisible()?[4,this.renderStackContent(e)]:[3,2];case 1:t.sent(),t.label=2;case 2:return[2]}})})},t.prototype.renderNode=function(e){return BA(this,void 0,void 0,function(){return PA(this,function(t){switch(t.label){case 0:return Tg(e.container.flags,16),e.container.styles.isVisible()?[4,this.renderNodeBackgroundAndBorders(e)]:[3,3];case 1:return t.sent(),[4,this.renderNodeContent(e)];case 2:t.sent(),t.label=3;case 3:return[2]}})})},t.prototype.renderTextWithLetterSpacing=function(e,t,i){var r=this;0===t?this.ctx.fillText(e.text,e.bounds.left,e.bounds.top+i):ym(e.text).reduce(function(t,n){return r.ctx.fillText(n,t,e.bounds.top+i),t+r.ctx.measureText(n).width},e.bounds.left)},t.prototype.createFontStyle=function(e){var t=e.fontVariant.filter(function(e){return"normal"===e||"small-caps"===e}).join(""),i=L_(e.fontFamily).join(", "),r=cp(e.fontSize)?""+e.fontSize.number+e.fontSize.unit:e.fontSize.number+"px";return[[e.fontStyle,t,e.fontWeight,r,i].join(" "),i,r]},t.prototype.renderTextNode=function(e,t){return BA(this,void 0,void 0,function(){var i,r,n,s,o,a,l,u,c=this;return PA(this,function(h){return i=this.createFontStyle(t),r=i[0],n=i[1],s=i[2],this.ctx.font=r,this.ctx.direction=1===t.direction?"rtl":"ltr",this.ctx.textAlign="left",this.ctx.textBaseline="alphabetic",o=this.fontMetrics.getMetrics(n,s),a=o.baseline,l=o.middle,u=t.paintOrder,e.textBounds.forEach(function(e){u.forEach(function(i){switch(i){case 0:c.ctx.fillStyle=Rp(t.color),c.renderTextWithLetterSpacing(e,t.letterSpacing,a);var r=t.textShadow;r.length&&e.text.trim().length&&(r.slice(0).reverse().forEach(function(i){c.ctx.shadowColor=Rp(i.color),c.ctx.shadowOffsetX=i.offsetX.number*c.options.scale,c.ctx.shadowOffsetY=i.offsetY.number*c.options.scale,c.ctx.shadowBlur=i.blur.number,c.renderTextWithLetterSpacing(e,t.letterSpacing,a)}),c.ctx.shadowColor="",c.ctx.shadowOffsetX=0,c.ctx.shadowOffsetY=0,c.ctx.shadowBlur=0),t.textDecorationLine.length&&(c.ctx.fillStyle=Rp(t.textDecorationColor||t.color),t.textDecorationLine.forEach(function(t){switch(t){case 1:c.ctx.fillRect(e.bounds.left,Math.round(e.bounds.top+a),e.bounds.width,1);break;case 2:c.ctx.fillRect(e.bounds.left,Math.round(e.bounds.top),e.bounds.width,1);break;case 3:c.ctx.fillRect(e.bounds.left,Math.ceil(e.bounds.top+l),e.bounds.width,1)}}));break;case 1:t.webkitTextStrokeWidth&&e.text.trim().length&&(c.ctx.strokeStyle=Rp(t.webkitTextStrokeColor),c.ctx.lineWidth=t.webkitTextStrokeWidth,c.ctx.lineJoin=window.chrome?"miter":"round",c.ctx.strokeText(e.text,e.bounds.left,e.bounds.top+a)),c.ctx.strokeStyle="",c.ctx.lineWidth=0,c.ctx.lineJoin="miter"}})}),[2]})})},t.prototype.renderReplacedElement=function(e,t,i){if(i&&e.intrinsicWidth>0&&e.intrinsicHeight>0){var r=w_(e),n=l_(t);this.path(n),this.ctx.save(),this.ctx.clip(),this.ctx.drawImage(i,0,0,e.intrinsicWidth,e.intrinsicHeight,r.left,r.top,r.width,r.height),this.ctx.restore()}},t.prototype.renderNodeContent=function(e){return BA(this,void 0,void 0,function(){var i,r,n,s,o,a,l,u,c,h,A,d,p,f,g,m,v,_;return PA(this,function(y){switch(y.label){case 0:this.applyEffects(e.getEffects(4)),i=e.container,r=e.curves,n=i.styles,s=0,o=i.textNodes,y.label=1;case 1:return s<o.length?(a=o[s],[4,this.renderTextNode(a,n)]):[3,4];case 2:y.sent(),y.label=3;case 3:return s++,[3,1];case 4:if(!(i instanceof km))return[3,8];y.label=5;case 5:return y.trys.push([5,7,,8]),[4,this.context.cache.match(i.src)];case 6:return g=y.sent(),this.renderReplacedElement(i,r,g),[3,8];case 7:return y.sent(),this.context.logger.error("Error loading image "+i.src),[3,8];case 8:if(i instanceof Em&&this.renderReplacedElement(i,r,i.canvas),!(i instanceof Sm))return[3,12];y.label=9;case 9:return y.trys.push([9,11,,12]),[4,this.context.cache.match(i.svg)];case 10:return g=y.sent(),this.renderReplacedElement(i,r,g),[3,12];case 11:return y.sent(),this.context.logger.error("Error loading svg "+i.svg.substring(0,255)),[3,12];case 12:return i instanceof Qm&&i.tree?[4,new t(this.context,{scale:this.options.scale,backgroundColor:i.backgroundColor,x:0,y:0,width:i.width,height:i.height}).render(i.tree)]:[3,14];case 13:l=y.sent(),i.width&&i.height&&this.ctx.drawImage(l,0,0,i.width,i.height,i.bounds.left,i.bounds.top,i.bounds.width,i.bounds.height),y.label=14;case 14:if(i instanceof Um&&(u=Math.min(i.bounds.width,i.bounds.height),i.type===Rm?i.checked&&(this.ctx.save(),this.path([new t_(i.bounds.left+.39363*u,i.bounds.top+.79*u),new t_(i.bounds.left+.16*u,i.bounds.top+.5549*u),new t_(i.bounds.left+.27347*u,i.bounds.top+.44071*u),new t_(i.bounds.left+.39694*u,i.bounds.top+.5649*u),new t_(i.bounds.left+.72983*u,i.bounds.top+.23*u),new t_(i.bounds.left+.84*u,i.bounds.top+.34085*u),new t_(i.bounds.left+.39363*u,i.bounds.top+.79*u)]),this.ctx.fillStyle=Rp(jm),this.ctx.fill(),this.ctx.restore()):i.type===Om&&i.checked&&(this.ctx.save(),this.ctx.beginPath(),this.ctx.arc(i.bounds.left+u/2,i.bounds.top+u/2,u/4,0,2*Math.PI,!0),this.ctx.fillStyle=Rp(jm),this.ctx.fill(),this.ctx.restore())),F_(i)&&i.value.length){switch(c=this.createFontStyle(n),v=c[0],h=c[1],A=this.fontMetrics.getMetrics(v,h).baseline,this.ctx.font=v,this.ctx.fillStyle=Rp(n.color),this.ctx.textBaseline="alphabetic",this.ctx.textAlign=R_(i.styles.textAlign),_=w_(i),d=0,i.styles.textAlign){case 1:d+=_.width/2;break;case 2:d+=_.width}p=_.add(d,0,0,-_.height/2+1),this.ctx.save(),this.path([new t_(_.left,_.top),new t_(_.left+_.width,_.top),new t_(_.left+_.width,_.top+_.height),new t_(_.left,_.top+_.height)]),this.ctx.clip(),this.renderTextWithLetterSpacing(new mm(i.value,p),n.letterSpacing,A),this.ctx.restore(),this.ctx.textBaseline="alphabetic",this.ctx.textAlign="left"}if(!Tg(i.styles.display,2048))return[3,20];if(null===i.styles.listStyleImage)return[3,19];if(0!==(f=i.styles.listStyleImage).type)return[3,18];g=void 0,m=f.url,y.label=15;case 15:return y.trys.push([15,17,,18]),[4,this.context.cache.match(m)];case 16:return g=y.sent(),this.ctx.drawImage(g,i.bounds.left-(g.width+10),i.bounds.top),[3,18];case 17:return y.sent(),this.context.logger.error("Error loading list-style-image "+m),[3,18];case 18:return[3,20];case 19:e.listValue&&-1!==i.styles.listStyleType&&(v=this.createFontStyle(n)[0],this.ctx.font=v,this.ctx.fillStyle=Rp(n.color),this.ctx.textBaseline="middle",this.ctx.textAlign="right",_=new MA(i.bounds.left,i.bounds.top+Cp(i.styles.paddingTop,i.bounds.width),i.bounds.width,Xf(n.lineHeight,n.fontSize.number)/2+1),this.renderTextWithLetterSpacing(new mm(e.listValue,_),n.letterSpacing,Xf(n.lineHeight,n.fontSize.number)/2+2),this.ctx.textBaseline="bottom",this.ctx.textAlign="left"),y.label=20;case 20:return[2]}})})},t.prototype.renderStackContent=function(e){return BA(this,void 0,void 0,function(){var t,i,r,n,s,o,a,l,u,c,h,A,d,p,f;return PA(this,function(g){switch(g.label){case 0:return Tg(e.element.container.flags,16),[4,this.renderNodeBackgroundAndBorders(e.element)];case 1:g.sent(),t=0,i=e.negativeZIndex,g.label=2;case 2:return t<i.length?(f=i[t],[4,this.renderStack(f)]):[3,5];case 3:g.sent(),g.label=4;case 4:return t++,[3,2];case 5:return[4,this.renderNodeContent(e.element)];case 6:g.sent(),r=0,n=e.nonInlineLevel,g.label=7;case 7:return r<n.length?(f=n[r],[4,this.renderNode(f)]):[3,10];case 8:g.sent(),g.label=9;case 9:return r++,[3,7];case 10:s=0,o=e.nonPositionedFloats,g.label=11;case 11:return s<o.length?(f=o[s],[4,this.renderStack(f)]):[3,14];case 12:g.sent(),g.label=13;case 13:return s++,[3,11];case 14:a=0,l=e.nonPositionedInlineLevel,g.label=15;case 15:return a<l.length?(f=l[a],[4,this.renderStack(f)]):[3,18];case 16:g.sent(),g.label=17;case 17:return a++,[3,15];case 18:u=0,c=e.inlineLevel,g.label=19;case 19:return u<c.length?(f=c[u],[4,this.renderNode(f)]):[3,22];case 20:g.sent(),g.label=21;case 21:return u++,[3,19];case 22:h=0,A=e.zeroOrAutoZIndexOrTransformedOrOpacity,g.label=23;case 23:return h<A.length?(f=A[h],[4,this.renderStack(f)]):[3,26];case 24:g.sent(),g.label=25;case 25:return h++,[3,23];case 26:d=0,p=e.positiveZIndex,g.label=27;case 27:return d<p.length?(f=p[d],[4,this.renderStack(f)]):[3,30];case 28:g.sent(),g.label=29;case 29:return d++,[3,27];case 30:return[2]}})})},t.prototype.mask=function(e){this.ctx.beginPath(),this.ctx.moveTo(0,0),this.ctx.lineTo(this.canvas.width,0),this.ctx.lineTo(this.canvas.width,this.canvas.height),this.ctx.lineTo(0,this.canvas.height),this.ctx.lineTo(0,0),this.formatPath(e.slice(0).reverse()),this.ctx.closePath()},t.prototype.path=function(e){this.ctx.beginPath(),this.formatPath(e),this.ctx.closePath()},t.prototype.formatPath=function(e){var t=this;e.forEach(function(e,i){var r=n_(e)?e.start:e;0===i?t.ctx.moveTo(r.x,r.y):t.ctx.lineTo(r.x,r.y),n_(e)&&t.ctx.bezierCurveTo(e.startControl.x,e.startControl.y,e.endControl.x,e.endControl.y,e.end.x,e.end.y)})},t.prototype.renderRepeat=function(e,t,i,r){this.path(e),this.ctx.fillStyle=t,this.ctx.translate(i,r),this.ctx.fill(),this.ctx.translate(-i,-r)},t.prototype.resizeImage=function(e,t,i){var r;if(e.width===t&&e.height===i)return e;var n=(null!==(r=this.canvas.ownerDocument)&&void 0!==r?r:document).createElement("canvas");return n.width=Math.max(1,t),n.height=Math.max(1,i),n.getContext("2d").drawImage(e,0,0,e.width,e.height,0,0,t,i),n},t.prototype.renderBackgroundImage=function(e){return BA(this,void 0,void 0,function(){var t,i,r,n,s,o;return PA(this,function(a){switch(a.label){case 0:t=e.styles.backgroundImage.length-1,i=function(i){var n,s,o,a,l,u,c,h,A,d,p,f,g,m,v,_,y,b,w,x,B,P,C,M,k,E,S,T,I,F,D;return PA(this,function(R){switch(R.label){case 0:if(0!==i.type)return[3,5];n=void 0,s=i.url,R.label=1;case 1:return R.trys.push([1,3,,4]),[4,r.context.cache.match(s)];case 2:return n=R.sent(),[3,4];case 3:return R.sent(),r.context.logger.error("Error loading background-image "+s),[3,4];case 4:return n&&(o=x_(e,t,[n.width,n.height,n.width/n.height]),_=o[0],P=o[1],C=o[2],w=o[3],x=o[4],m=r.ctx.createPattern(r.resizeImage(n,w,x),"repeat"),r.renderRepeat(_,m,P,C)),[3,6];case 5:1===i.type?(a=x_(e,t,[null,null,null]),_=a[0],P=a[1],C=a[2],w=a[3],x=a[4],l=Xp(i.angle,w,x),u=l[0],c=l[1],h=l[2],A=l[3],d=l[4],(p=document.createElement("canvas")).width=w,p.height=x,f=p.getContext("2d"),g=f.createLinearGradient(c,A,h,d),Kp(i.stops,u).forEach(function(e){return g.addColorStop(e.stop,Rp(e.color))}),f.fillStyle=g,f.fillRect(0,0,w,x),w>0&&x>0&&(m=r.ctx.createPattern(p,"repeat"),r.renderRepeat(_,m,P,C))):function(e){return 2===e.type}(i)&&(v=x_(e,t,[null,null,null]),_=v[0],y=v[1],b=v[2],w=v[3],x=v[4],B=0===i.position.length?[xp]:i.position,P=Cp(B[0],w),C=Cp(B[B.length-1],x),M=function(e,t,i,r,n){var s=0,o=0;switch(e.size){case 0:0===e.shape?s=o=Math.min(Math.abs(t),Math.abs(t-r),Math.abs(i),Math.abs(i-n)):1===e.shape&&(s=Math.min(Math.abs(t),Math.abs(t-r)),o=Math.min(Math.abs(i),Math.abs(i-n)));break;case 2:if(0===e.shape)s=o=Math.min(qp(t,i),qp(t,i-n),qp(t-r,i),qp(t-r,i-n));else if(1===e.shape){var a=Math.min(Math.abs(i),Math.abs(i-n))/Math.min(Math.abs(t),Math.abs(t-r)),l=Yp(r,n,t,i,!0),u=l[0],c=l[1];o=a*(s=qp(u-t,(c-i)/a))}break;case 1:0===e.shape?s=o=Math.max(Math.abs(t),Math.abs(t-r),Math.abs(i),Math.abs(i-n)):1===e.shape&&(s=Math.max(Math.abs(t),Math.abs(t-r)),o=Math.max(Math.abs(i),Math.abs(i-n)));break;case 3:if(0===e.shape)s=o=Math.max(qp(t,i),qp(t,i-n),qp(t-r,i),qp(t-r,i-n));else if(1===e.shape){a=Math.max(Math.abs(i),Math.abs(i-n))/Math.max(Math.abs(t),Math.abs(t-r));var h=Yp(r,n,t,i,!1);u=h[0],c=h[1],o=a*(s=qp(u-t,(c-i)/a))}}return Array.isArray(e.size)&&(s=Cp(e.size[0],r),o=2===e.size.length?Cp(e.size[1],n):s),[s,o]}(i,P,C,w,x),k=M[0],E=M[1],k>0&&E>0&&(S=r.ctx.createRadialGradient(y+P,b+C,0,y+P,b+C,k),Kp(i.stops,2*k).forEach(function(e){return S.addColorStop(e.stop,Rp(e.color))}),r.path(_),r.ctx.fillStyle=S,k!==E?(T=e.bounds.left+.5*e.bounds.width,I=e.bounds.top+.5*e.bounds.height,D=1/(F=E/k),r.ctx.save(),r.ctx.translate(T,I),r.ctx.transform(1,0,0,F,0,0),r.ctx.translate(-T,-I),r.ctx.fillRect(y,D*(b-I)+I,w,x*D),r.ctx.restore()):r.ctx.fill())),R.label=6;case 6:return t--,[2]}})},r=this,n=0,s=e.styles.backgroundImage.slice(0).reverse(),a.label=1;case 1:return n<s.length?(o=s[n],[5,i(o)]):[3,4];case 2:a.sent(),a.label=3;case 3:return n++,[3,1];case 4:return[2]}})})},t.prototype.renderSolidBorder=function(e,t,i){return BA(this,void 0,void 0,function(){return PA(this,function(r){return this.path(v_(i,t)),this.ctx.fillStyle=Rp(e),this.ctx.fill(),[2]})})},t.prototype.renderDoubleBorder=function(e,t,i,r){return BA(this,void 0,void 0,function(){var n,s;return PA(this,function(o){switch(o.label){case 0:return t<3?[4,this.renderSolidBorder(e,i,r)]:[3,2];case 1:return o.sent(),[2];case 2:return n=function(e,t){switch(t){case 0:return y_(e.topLeftBorderBox,e.topLeftBorderDoubleOuterBox,e.topRightBorderBox,e.topRightBorderDoubleOuterBox);case 1:return y_(e.topRightBorderBox,e.topRightBorderDoubleOuterBox,e.bottomRightBorderBox,e.bottomRightBorderDoubleOuterBox);case 2:return y_(e.bottomRightBorderBox,e.bottomRightBorderDoubleOuterBox,e.bottomLeftBorderBox,e.bottomLeftBorderDoubleOuterBox);default:return y_(e.bottomLeftBorderBox,e.bottomLeftBorderDoubleOuterBox,e.topLeftBorderBox,e.topLeftBorderDoubleOuterBox)}}(r,i),this.path(n),this.ctx.fillStyle=Rp(e),this.ctx.fill(),s=function(e,t){switch(t){case 0:return y_(e.topLeftBorderDoubleInnerBox,e.topLeftPaddingBox,e.topRightBorderDoubleInnerBox,e.topRightPaddingBox);case 1:return y_(e.topRightBorderDoubleInnerBox,e.topRightPaddingBox,e.bottomRightBorderDoubleInnerBox,e.bottomRightPaddingBox);case 2:return y_(e.bottomRightBorderDoubleInnerBox,e.bottomRightPaddingBox,e.bottomLeftBorderDoubleInnerBox,e.bottomLeftPaddingBox);default:return y_(e.bottomLeftBorderDoubleInnerBox,e.bottomLeftPaddingBox,e.topLeftBorderDoubleInnerBox,e.topLeftPaddingBox)}}(r,i),this.path(s),this.ctx.fill(),[2]}})})},t.prototype.renderNodeBackgroundAndBorders=function(e){return BA(this,void 0,void 0,function(){var t,i,r,n,s,o,a,l,u=this;return PA(this,function(c){switch(c.label){case 0:return this.applyEffects(e.getEffects(2)),t=e.container.styles,i=!Dp(t.backgroundColor)||t.backgroundImage.length,r=[{style:t.borderTopStyle,color:t.borderTopColor,width:t.borderTopWidth},{style:t.borderRightStyle,color:t.borderRightColor,width:t.borderRightWidth},{style:t.borderBottomStyle,color:t.borderBottomColor,width:t.borderBottomWidth},{style:t.borderLeftStyle,color:t.borderLeftColor,width:t.borderLeftWidth}],n=D_(M_(t.backgroundClip,0),e.curves),i||t.boxShadow.length?(this.ctx.save(),this.path(n),this.ctx.clip(),Dp(t.backgroundColor)||(this.ctx.fillStyle=Rp(t.backgroundColor),this.ctx.fill()),[4,this.renderBackgroundImage(e.container)]):[3,2];case 1:c.sent(),this.ctx.restore(),t.boxShadow.slice(0).reverse().forEach(function(t){u.ctx.save();var i,r,n,s,o,a=a_(e.curves),l=t.inset?0:1e4,c=(i=a,r=-l+(t.inset?1:-1)*t.spread.number,n=(t.inset?1:-1)*t.spread.number,s=t.spread.number*(t.inset?-2:2),o=t.spread.number*(t.inset?-2:2),i.map(function(e,t){switch(t){case 0:return e.add(r,n);case 1:return e.add(r+s,n);case 2:return e.add(r+s,n+o);case 3:return e.add(r,n+o)}return e}));t.inset?(u.path(a),u.ctx.clip(),u.mask(c)):(u.mask(a),u.ctx.clip(),u.path(c)),u.ctx.shadowOffsetX=t.offsetX.number+l,u.ctx.shadowOffsetY=t.offsetY.number,u.ctx.shadowColor=Rp(t.color),u.ctx.shadowBlur=t.blur.number,u.ctx.fillStyle=t.inset?Rp(t.color):"rgba(0,0,0,1)",u.ctx.fill(),u.ctx.restore()}),c.label=2;case 2:s=0,o=0,a=r,c.label=3;case 3:return o<a.length?0!==(l=a[o]).style&&!Dp(l.color)&&l.width>0?2!==l.style?[3,5]:[4,this.renderDashedDottedBorder(l.color,l.width,s,e.curves,2)]:[3,11]:[3,13];case 4:return c.sent(),[3,11];case 5:return 3!==l.style?[3,7]:[4,this.renderDashedDottedBorder(l.color,l.width,s,e.curves,3)];case 6:return c.sent(),[3,11];case 7:return 4!==l.style?[3,9]:[4,this.renderDoubleBorder(l.color,l.width,s,e.curves)];case 8:return c.sent(),[3,11];case 9:return[4,this.renderSolidBorder(l.color,s,e.curves)];case 10:c.sent(),c.label=11;case 11:s++,c.label=12;case 12:return o++,[3,3];case 13:return[2]}})})},t.prototype.renderDashedDottedBorder=function(e,t,i,r,n){return BA(this,void 0,void 0,function(){var s,o,a,l,u,c,h,A,d,p,f,g,m,v,_,y;return PA(this,function(b){return this.ctx.save(),s=function(e,t){switch(t){case 0:return __(e.topLeftBorderStroke,e.topRightBorderStroke);case 1:return __(e.topRightBorderStroke,e.bottomRightBorderStroke);case 2:return __(e.bottomRightBorderStroke,e.bottomLeftBorderStroke);default:return __(e.bottomLeftBorderStroke,e.topLeftBorderStroke)}}(r,i),o=v_(r,i),2===n&&(this.path(o),this.ctx.clip()),n_(o[0])?(a=o[0].start.x,l=o[0].start.y):(a=o[0].x,l=o[0].y),n_(o[1])?(u=o[1].end.x,c=o[1].end.y):(u=o[1].x,c=o[1].y),h=0===i||2===i?Math.abs(a-u):Math.abs(l-c),this.ctx.beginPath(),3===n?this.formatPath(s):this.formatPath(o.slice(0,2)),A=t<3?3*t:2*t,d=t<3?2*t:t,3===n&&(A=t,d=t),p=!0,h<=2*A?p=!1:h<=2*A+d?(A*=f=h/(2*A+d),d*=f):(g=Math.floor((h+d)/(A+d)),m=(h-g*A)/(g-1),d=(v=(h-(g+1)*A)/g)<=0||Math.abs(d-m)<Math.abs(d-v)?m:v),p&&(3===n?this.ctx.setLineDash([0,A+d]):this.ctx.setLineDash([A,d])),3===n?(this.ctx.lineCap="round",this.ctx.lineWidth=t):this.ctx.lineWidth=2*t+1.1,this.ctx.strokeStyle=Rp(e),this.ctx.stroke(),this.ctx.setLineDash([]),2===n&&(n_(o[0])&&(_=o[3],y=o[0],this.ctx.beginPath(),this.formatPath([new t_(_.end.x,_.end.y),new t_(y.start.x,y.start.y)]),this.ctx.stroke()),n_(o[1])&&(_=o[1],y=o[2],this.ctx.beginPath(),this.formatPath([new t_(_.end.x,_.end.y),new t_(y.start.x,y.start.y)]),this.ctx.stroke())),this.ctx.restore(),[2]})})},t.prototype.render=function(e){return BA(this,void 0,void 0,function(){var t;return PA(this,function(i){switch(i.label){case 0:return this.options.backgroundColor&&(this.ctx.fillStyle=Rp(this.options.backgroundColor),this.ctx.fillRect(this.options.x,this.options.y,this.options.width,this.options.height)),r=new f_(e,null),n=new p_(r),g_(r,n,n,s=[]),m_(r.container,s),t=n,[4,this.renderStack(t)];case 1:return i.sent(),this.applyEffects([]),[2,this.canvas]}var r,n,s})})},t}(T_),F_=function(e){return e instanceof Vm||(e instanceof Nm||e instanceof Um&&e.type!==Om&&e.type!==Rm)},D_=function(e,t){switch(e){case 0:return a_(t);case 2:return function(e){return[e.topLeftContentBox,e.topRightContentBox,e.bottomRightContentBox,e.bottomLeftContentBox]}(t);default:return l_(t)}},R_=function(e){switch(e){case 1:return"center";case 2:return"right";default:return"left"}},O_=["-apple-system","system-ui"],L_=function(e){return/iPhone OS 15_(0|1)/.test(window.navigator.userAgent)?e.filter(function(e){return-1===O_.indexOf(e)}):e},j_=function(e){function t(t,i){var r=e.call(this,t,i)||this;return r.canvas=i.canvas?i.canvas:document.createElement("canvas"),r.ctx=r.canvas.getContext("2d"),r.options=i,r.canvas.width=Math.floor(i.width*i.scale),r.canvas.height=Math.floor(i.height*i.scale),r.canvas.style.width=i.width+"px",r.canvas.style.height=i.height+"px",r.ctx.scale(r.options.scale,r.options.scale),r.ctx.translate(-i.x,-i.y),r.context.logger.debug("EXPERIMENTAL ForeignObject renderer initialized ("+i.width+"x"+i.height+" at "+i.x+","+i.y+") with scale "+i.scale),r}return wA(t,e),t.prototype.render=function(e){return BA(this,void 0,void 0,function(){var t,i;return PA(this,function(r){switch(r.label){case 0:return t=pm(this.options.width*this.options.scale,this.options.height*this.options.scale,this.options.scale,this.options.scale,e),[4,U_(t)];case 1:return i=r.sent(),this.options.backgroundColor&&(this.ctx.fillStyle=Rp(this.options.backgroundColor),this.ctx.fillRect(0,0,this.options.width*this.options.scale,this.options.height*this.options.scale)),this.ctx.drawImage(i,-this.options.x*this.options.scale,-this.options.y*this.options.scale),[2,this.canvas]}})})},t}(T_),U_=function(e){return new Promise(function(t,i){var r=new Image;r.onload=function(){t(r)},r.onerror=i,r.src="data:image/svg+xml;charset=utf-8,"+encodeURIComponent((new XMLSerializer).serializeToString(e))})},N_=function(){function e(e){var t=e.id,i=e.enabled;this.id=t,this.enabled=i,this.start=Date.now()}return e.prototype.debug=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.enabled&&("undefined"!=typeof window&&window.console&&"function"==typeof console.debug?console.debug.apply(console,CA([this.id,this.getTime()+"ms"],e)):this.info.apply(this,e))},e.prototype.getTime=function(){return Date.now()-this.start},e.prototype.info=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.enabled&&"undefined"!=typeof window&&window.console&&"function"==typeof console.info&&console.info.apply(console,CA([this.id,this.getTime()+"ms"],e))},e.prototype.warn=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.enabled&&("undefined"!=typeof window&&window.console&&"function"==typeof console.warn?console.warn.apply(console,CA([this.id,this.getTime()+"ms"],e)):this.info.apply(this,e))},e.prototype.error=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.enabled&&("undefined"!=typeof window&&window.console&&"function"==typeof console.error?console.error.apply(console,CA([this.id,this.getTime()+"ms"],e)):this.info.apply(this,e))},e.instances={},e}(),V_=function(){function e(t,i){var r;this.windowBounds=i,this.instanceName="#"+e.instanceCount++,this.logger=new N_({id:this.instanceName,enabled:t.logging}),this.cache=null!==(r=t.cache)&&void 0!==r?r:new Wv(this,t)}return e.instanceCount=1,e}(),Q_=function(e,t){return void 0===t&&(t={}),H_(e,t)};"undefined"!=typeof window&&zv.setContext(window);var H_=function(e,t){return BA(void 0,void 0,void 0,function(){var i,r,n,s,o,a,l,u,c,h,A,d,p,f,g,m,v,_,y,b,x,B,P,C,M,k,E,S,T,I,F,D,R,O,L,j,U,N;return PA(this,function(V){switch(V.label){case 0:if(!e||"object"!==w(e))return[2,Promise.reject("Invalid element provided as first argument")];if(!(i=e.ownerDocument))throw new Error("Element is not attached to a Document");if(!(r=i.defaultView))throw new Error("Document is not attached to a Window");return n={allowTaint:null!==(B=t.allowTaint)&&void 0!==B&&B,imageTimeout:null!==(P=t.imageTimeout)&&void 0!==P?P:15e3,proxy:t.proxy,useCORS:null!==(C=t.useCORS)&&void 0!==C&&C},s=xA({logging:null===(M=t.logging)||void 0===M||M,cache:t.cache},n),o={windowWidth:null!==(k=t.windowWidth)&&void 0!==k?k:r.innerWidth,windowHeight:null!==(E=t.windowHeight)&&void 0!==E?E:r.innerHeight,scrollX:null!==(S=t.scrollX)&&void 0!==S?S:r.pageXOffset,scrollY:null!==(T=t.scrollY)&&void 0!==T?T:r.pageYOffset},a=new MA(o.scrollX,o.scrollY,o.windowWidth,o.windowHeight),l=new V_(s,a),u=null!==(I=t.foreignObjectRendering)&&void 0!==I&&I,c={allowTaint:null!==(F=t.allowTaint)&&void 0!==F&&F,onclone:t.onclone,ignoreElements:t.ignoreElements,inlineImages:u,copyStyles:u},l.logger.debug("Starting document clone with size "+a.width+"x"+a.height+" scrolled to "+-a.left+","+-a.top),h=new Ev(l,e,c),(A=h.clonedReferenceElement)?[4,h.toIFrame(i,a)]:[2,Promise.reject("Unable to find element in cloned iframe")];case 1:return d=V.sent(),p=rv(A)||function(e){return"HTML"===e.tagName}(A)?function(e){var t=e.body,i=e.documentElement;if(!t||!i)throw new Error("Unable to get document size");var r=Math.max(Math.max(t.scrollWidth,i.scrollWidth),Math.max(t.offsetWidth,i.offsetWidth),Math.max(t.clientWidth,i.clientWidth)),n=Math.max(Math.max(t.scrollHeight,i.scrollHeight),Math.max(t.offsetHeight,i.offsetHeight),Math.max(t.clientHeight,i.clientHeight));return new MA(0,0,r,n)}(A.ownerDocument):kA(l,A),f=p.width,g=p.height,m=p.left,v=p.top,_=G_(l,A,t.backgroundColor),y={canvas:t.canvas,backgroundColor:_,scale:null!==(R=null!==(D=t.scale)&&void 0!==D?D:r.devicePixelRatio)&&void 0!==R?R:1,x:(null!==(O=t.x)&&void 0!==O?O:0)+m,y:(null!==(L=t.y)&&void 0!==L?L:0)+v,width:null!==(j=t.width)&&void 0!==j?j:Math.ceil(f),height:null!==(U=t.height)&&void 0!==U?U:Math.ceil(g)},u?(l.logger.debug("Document cloned, using foreign object rendering"),[4,new j_(l,y).render(A)]):[3,3];case 2:return b=V.sent(),[3,5];case 3:return l.logger.debug("Document cloned, element located at "+m+","+v+" with size "+f+"x"+g+" using computed rendering"),l.logger.debug("Starting DOM parsing"),x=Wm(l,A),_===x.styles.backgroundColor&&(x.styles.backgroundColor=Hp.TRANSPARENT),l.logger.debug("Starting renderer for element at "+y.x+","+y.y+" with size "+y.width+"x"+y.height),[4,new I_(l,y).render(x)];case 4:b=V.sent(),V.label=5;case 5:return(null===(N=t.removeContainer)||void 0===N||N)&&(Ev.destroy(d)||l.logger.error("Cannot detach cloned iframe as it is not in the DOM anymore")),l.logger.debug("Finished rendering"),[2,b]}})})},G_=function(e,t,i){var r=t.ownerDocument,n=r.documentElement?Qp(e,getComputedStyle(r.documentElement).backgroundColor):Hp.TRANSPARENT,s=r.body?Qp(e,getComputedStyle(r.body).backgroundColor):Hp.TRANSPARENT,o="string"==typeof i?Qp(e,i):null===i?Hp.TRANSPARENT:4294967295;return t===r.documentElement?Dp(n)?Dp(s)?o:s:n:o};function z_(e,t,i){var r=e.getBoundingClientRect(),n=t.getBoundingClientRect();i[0]+=r.left-n.left,i[1]+=r.top-n.top}var W_=function(){return P(function e(t){var i=this;x(this,e),this.container=t.viewerElement,this.language="en",this.localeService=t.localeService||new yh,this.scene=new zi(this,{canvasId:t.canvasId,canvasElement:t.canvasElement,keyboardEventsElement:t.keyboardEventsElement,contextAttr:{preserveDrawingBuffer:!1!==t.preserveDrawingBuffer,premultipliedAlpha:!!t.premultipliedAlpha,antialias:!1!==t.antialias},spinnerElementId:t.spinnerElementId,transparent:!1!==t.transparent,gammaInput:!0,gammaOutput:!1,backgroundColor:t.backgroundColor,backgroundColorFromAmbientLight:t.backgroundColorFromAmbientLight,ticksPerRender:1,ticksPerOcclusionTest:20,units:t.units,scale:t.scale,origin:t.origin,lightIntensity:t.lightIntensity,saoEnabled:t.saoEnabled,alphaDepthMask:!1!==t.alphaDepthMask,entityOffsetsEnabled:!!t.entityOffsetsEnabled,pickSurfacePrecisionEnabled:!!t.pickSurfacePrecisionEnabled,readableGeometryEnabled:!!t.readableGeometryEnabled,logarithmicDepthBufferEnabled:!!t.logarithmicDepthBufferEnabled,pbrEnabled:!!t.pbrEnabled,colorTextureEnabled:!1!==t.colorTextureEnabled,dtxEnabled:!!t.dtxEnabled,edgesEnabled:t.edgesEnabled,markerZOffset:t.markerZOffset,numCachedSectionPlanes:t.numCachedSectionPlanes,lodEnabled:!!t.lodEnabled,resolutionScale:t.resolutionScale,offset:t.offset,worldAxis:t.worldAxis}),this.metaScene=new _A(this,this.scene),this.id=t.id||this.scene.id,this.camera=this.scene.camera,this.cameraFlight=new kh(this.scene,{duration:.5}),this.cameraControl=new fA(this.scene,{snapRadius:t.snapRadius,doublePickFlyTo:!0}),this.scene.canvas.on("boundary",function(e){i.cameraControl.updatePivotElement()}),this._plugins=[],this._eventSubs={}},[{key:"capabilities",get:function(){return this.scene.capabilities}},{key:"on",value:function(e,t){var i=this._eventSubs[e];i||(i=[],this._eventSubs[e]=i),i.push(t)}},{key:"fire",value:function(e,t){var i=this._eventSubs[e];if(i)for(var r=0,n=i.length;r<n;r++)i[r](t)}},{key:"off",value:function(e){}},{key:"log",value:function(e){console.log("[xtctwins viewer ".concat(this.id,"]: ").concat(e))}},{key:"error",value:function(e){console.error("[xtctwins viewer ".concat(this.id,"]: ").concat(e))}},{key:"addPlugin",value:function(e){this._plugins.push(e)}},{key:"removePlugin",value:function(e){for(var t=0,i=this._plugins.length;t<i;t++){var r=this._plugins[t];if(r===e)return r.clear&&r.clear(),void this._plugins.splice(t,1)}}},{key:"sendToPlugins",value:function(e,t){for(var i=0,r=this._plugins.length;i<r;i++){var n=this._plugins[i];n.send&&n.send(e,t)}}},{key:"clear",value:function(){throw'Viewer#clear() no longer implemented - use \'#sendToPlugins("clear") instead'}},{key:"resetView",value:function(){throw"Viewer#resetView() no longer implemented - use CameraMemento & ObjectsMemento classes instead"}},{key:"beginSnapshot",value:function(){this._snapshotBegun||(this.scene._renderer.beginSnapshot(),this._snapshotBegun=!0)}},{key:"getSnapshot",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=!this._snapshotBegun,i=void 0!==e.width&&void 0!==e.height,r=this.scene.canvas.canvas,n=r.clientWidth,s=r.clientHeight,o=e.width?Math.floor(e.width):r.width,a=e.height?Math.floor(e.height):r.height;i&&(r.width=o,r.height=a),this._snapshotBegun||this.beginSnapshot({width:o,height:a}),e.includeGizmos||this.sendToPlugins("snapshotStarting");for(var l={},u=0,c=this._plugins.length;u<c;u++){var h=this._plugins[u];if(h.getContainerElement){var A=h.getContainerElement();A!==document.body&&(l[A.id]||(l[A.id]=!0,Q_(A).then(function(e){document.body.appendChild(e),setTimeout(function(){document.body.removeChild(e)},200)})))}}this.scene.fire("rendering",{},!0),this.scene._renderer.renderSnapshot();var d=this.scene._renderer.readSnapshot(e);return i&&(r.width=n,r.height=s,this.scene.glRedraw()),e.includeGizmos||this.sendToPlugins("snapshotFinished"),t&&this.endSnapshot(),d}},{key:"getSnapshotWithPlugins",value:(e=a(s().mark(function e(){var t,i,r,n,o,a,l,u,c,h,A,d,p,f,g,m,v,_,y,b,w,x=arguments;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:for(t=x.length>0&&void 0!==x[0]?x[0]:{},i=!this._snapshotBegun,r=void 0!==t.width&&void 0!==t.height,n=this.scene.canvas.canvas,o=n.clientWidth,a=n.clientHeight,l=t.width?Math.floor(t.width):n.width,u=t.height?Math.floor(t.height):n.height,r&&(n.width=l,n.height=u),this._snapshotBegun||this.beginSnapshot(),t.includeGizmos||this.sendToPlugins("snapshotStarting"),this.scene._renderer.renderSnapshot(),c=this.scene._renderer.readSnapshotAsCanvas(),r&&(n.width=o,n.height=a,this.scene.glRedraw()),h={},A=[],d=0,p=this._plugins.length;d<p;d++)(f=this._plugins[d]).getContainerElement&&(g=f.getContainerElement())!==document.body&&(h[g.id]||(h[g.id]=!0,A.push(g)));m=0,v=A.length;case 18:if(!(m<v)){e.next=28;break}return _=A[m],y=0==m?c.width/_.clientWidth:1,b=Y.vec2([0,0]),z_(n,_,b),e.next=25,Q_(_,{canvas:c,backgroundColor:null,x:b[0],y:b[1],scale:y});case 25:m++,e.next=18;break;case 28:return t.includeGizmos||this.sendToPlugins("snapshotFinished"),i&&this.endSnapshot(),"jpeg"!==(w=t.format||"png")&&"png"!==w&&"bmp"!==w&&(console.error("Unsupported image format: '"+w+"' - supported types are 'jpeg', 'bmp' and 'png' - defaulting to 'png'"),w="png"),t.includeGizmos||this.sendToPlugins("snapshotFinished"),i&&this.endSnapshot(),e.abrupt("return",c.toDataURL("image/".concat(w)));case 35:case"end":return e.stop()}},e,this)})),function(){return e.apply(this,arguments)})},{key:"endSnapshot",value:function(){this._snapshotBegun&&(this.scene._renderer.endSnapshot(),this.scene._renderer.render({force:!0}),this._snapshotBegun=!1)}},{key:"destroy",value:function(e){var t=this._plugins.slice();if(t.length>0)for(var i=0,r=t.length;i<r;i++){t[i].destroy()}this.cameraControl.destroy(),this.scene.destroy(e)}}]);var e}();function K_(e,t){if(!e)throw new Error(t||"loader assertion failed.")}var X_=Boolean("object"!==("undefined"==typeof process?"undefined":w(process))||"[object process]"!==String(process)||process.browser),q_="undefined"!=typeof process&&process.version&&/v([0-9]*)/.exec(process.version);q_&&parseFloat(q_[1]);function Y_(e,t){if(!e)throw new Error(t||"loaders.gl assertion failed.")}var J_="object"!==("undefined"==typeof process?"undefined":w(process))||"[object process]"!==String(process)||process.browser,Z_="undefined"!=typeof window&&void 0!==window.orientation,$_="undefined"!=typeof process&&process.version&&/v([0-9]*)/.exec(process.version);function ey(e){return ey="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},ey(e)}function ty(e){var t=function(e,t){if("object"!=ey(e)||!e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var r=i.call(e,t||"default");if("object"!=ey(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==ey(t)?t:String(t)}function iy(e,t,i){return(t=ty(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}$_&&parseFloat($_[1]);var ry=function(){return P(function e(t,i){var r=this;x(this,e),iy(this,"name",void 0),iy(this,"workerThread",void 0),iy(this,"isRunning",!0),iy(this,"result",void 0),iy(this,"_resolve",function(){}),iy(this,"_reject",function(){}),this.name=t,this.workerThread=i,this.result=new Promise(function(e,t){r._resolve=e,r._reject=t})},[{key:"postMessage",value:function(e,t){this.workerThread.postMessage({source:"loaders.gl",type:e,payload:t})}},{key:"done",value:function(e){Y_(this.isRunning),this.isRunning=!1,this._resolve(e)}},{key:"error",value:function(e){Y_(this.isRunning),this.isRunning=!1,this._reject(e)}}])}(),ny=function(){return P(function e(){x(this,e)},[{key:"terminate",value:function(){}}])}(),sy=new Map;function oy(e){Y_(e.source&&!e.url||!e.source&&e.url);var t=sy.get(e.source||e.url);return t||(e.url&&(t=function(e){if(!e.startsWith("http"))return e;return ay((t=e,"try {\n importScripts('".concat(t,"');\n} catch (error) {\n console.error(error);\n throw error;\n}")));var t}(e.url),sy.set(e.url,t)),e.source&&(t=ay(e.source),sy.set(e.source,t))),Y_(t),t}function ay(e){var t=new Blob([e],{type:"application/javascript"});return URL.createObjectURL(t)}function ly(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=arguments.length>2?arguments[2]:void 0,r=i||new Set;if(e){if(uy(e))r.add(e);else if(uy(e.buffer))r.add(e.buffer);else if(ArrayBuffer.isView(e));else if(t&&"object"===w(e))for(var n in e)ly(e[n],t,r)}else;return void 0===i?Array.from(r):[]}function uy(e){return!!e&&(e instanceof ArrayBuffer||("undefined"!=typeof MessagePort&&e instanceof MessagePort||("undefined"!=typeof ImageBitmap&&e instanceof ImageBitmap||"undefined"!=typeof OffscreenCanvas&&e instanceof OffscreenCanvas)))}var cy=function(){},hy=function(){return P(function e(t){x(this,e),iy(this,"name",void 0),iy(this,"source",void 0),iy(this,"url",void 0),iy(this,"terminated",!1),iy(this,"worker",void 0),iy(this,"onMessage",void 0),iy(this,"onError",void 0),iy(this,"_loadableURL","");var i=t.name,r=t.source,n=t.url;Y_(r||n),this.name=i,this.source=r,this.url=n,this.onMessage=cy,this.onError=function(e){return console.log(e)},this.worker=J_?this._createBrowserWorker():this._createNodeWorker()},[{key:"destroy",value:function(){this.onMessage=cy,this.onError=cy,this.worker.terminate(),this.terminated=!0}},{key:"isRunning",get:function(){return Boolean(this.onMessage)}},{key:"postMessage",value:function(e,t){t=t||ly(e),this.worker.postMessage(e,t)}},{key:"_getErrorFromErrorEvent",value:function(e){var t="Failed to load ";return t+="worker ".concat(this.name," from ").concat(this.url,". "),e.message&&(t+="".concat(e.message," in ")),e.lineno&&(t+=":".concat(e.lineno,":").concat(e.colno)),new Error(t)}},{key:"_createBrowserWorker",value:function(){var e=this;this._loadableURL=oy({source:this.source,url:this.url});var t=new Worker(this._loadableURL,{name:this.name});return t.onmessage=function(t){t.data?e.onMessage(t.data):e.onError(new Error("No data received"))},t.onerror=function(t){e.onError(e._getErrorFromErrorEvent(t)),e.terminated=!0},t.onmessageerror=function(e){return console.error(e)},t}},{key:"_createNodeWorker",value:function(){var e,t=this;if(this.url){var i=this.url.includes(":/")||this.url.startsWith("/")?this.url:"./".concat(this.url);e=new ny(i,{eval:!1})}else{if(!this.source)throw new Error("no worker");e=new ny(this.source,{eval:!0})}return e.on("message",function(e){t.onMessage(e)}),e.on("error",function(e){t.onError(e)}),e.on("exit",function(e){}),e}}],[{key:"isSupported",value:function(){return"undefined"!=typeof Worker&&J_||void 0!==ny&&!J_}}])}(),Ay=function(){return P(function e(t){x(this,e),iy(this,"name","unnamed"),iy(this,"source",void 0),iy(this,"url",void 0),iy(this,"maxConcurrency",1),iy(this,"maxMobileConcurrency",1),iy(this,"onDebug",function(){}),iy(this,"reuseWorkers",!0),iy(this,"props",{}),iy(this,"jobQueue",[]),iy(this,"idleQueue",[]),iy(this,"count",0),iy(this,"isDestroyed",!1),this.source=t.source,this.url=t.url,this.setProps(t)},[{key:"destroy",value:function(){this.idleQueue.forEach(function(e){return e.destroy()}),this.isDestroyed=!0}},{key:"setProps",value:function(e){this.props=n(n({},this.props),e),void 0!==e.name&&(this.name=e.name),void 0!==e.maxConcurrency&&(this.maxConcurrency=e.maxConcurrency),void 0!==e.maxMobileConcurrency&&(this.maxMobileConcurrency=e.maxMobileConcurrency),void 0!==e.reuseWorkers&&(this.reuseWorkers=e.reuseWorkers),void 0!==e.onDebug&&(this.onDebug=e.onDebug)}},{key:"startJob",value:(t=a(s().mark(function e(t){var i,r,n,o=this,a=arguments;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return i=a.length>1&&void 0!==a[1]?a[1]:function(e,t,i){return e.done(i)},r=a.length>2&&void 0!==a[2]?a[2]:function(e,t){return e.error(t)},n=new Promise(function(e){return o.jobQueue.push({name:t,onMessage:i,onError:r,onStart:e}),o}),this._startQueuedJob(),e.next=6,n;case 6:return e.abrupt("return",e.sent);case 7:case"end":return e.stop()}},e,this)})),function(e){return t.apply(this,arguments)})},{key:"_startQueuedJob",value:(e=a(s().mark(function e(){var t,i,r;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(this.jobQueue.length){e.next=2;break}return e.abrupt("return");case 2:if(t=this._getAvailableWorker()){e.next=5;break}return e.abrupt("return");case 5:if(!(i=this.jobQueue.shift())){e.next=18;break}return this.onDebug({message:"Starting job",name:i.name,workerThread:t,backlog:this.jobQueue.length}),r=new ry(i.name,t),t.onMessage=function(e){return i.onMessage(r,e.type,e.payload)},t.onError=function(e){return i.onError(r,e)},i.onStart(r),e.prev=12,e.next=15,r.result;case 15:return e.prev=15,this.returnWorkerToQueue(t),e.finish(15);case 18:case"end":return e.stop()}},e,this,[[12,,15,18]])})),function(){return e.apply(this,arguments)})},{key:"returnWorkerToQueue",value:function(e){this.isDestroyed||!this.reuseWorkers||this.count>this._getMaxConcurrency()?(e.destroy(),this.count--):this.idleQueue.push(e),this.isDestroyed||this._startQueuedJob()}},{key:"_getAvailableWorker",value:function(){if(this.idleQueue.length>0)return this.idleQueue.shift()||null;if(this.count<this._getMaxConcurrency()){this.count++;var e="".concat(this.name.toLowerCase()," (#").concat(this.count," of ").concat(this.maxConcurrency,")");return new hy({name:e,source:this.source,url:this.url})}return null}},{key:"_getMaxConcurrency",value:function(){return Z_?this.maxMobileConcurrency:this.maxConcurrency}}],[{key:"isSupported",value:function(){return hy.isSupported()}}]);var e,t}(),dy={maxConcurrency:3,maxMobileConcurrency:1,reuseWorkers:!0,onDebug:function(){}},py=function(){function e(t){x(this,e),iy(this,"props",void 0),iy(this,"workerPools",new Map),this.props=n({},dy),this.setProps(t),this.workerPools=new Map}return P(e,[{key:"destroy",value:function(){var e,t=u(this.workerPools.values());try{for(t.s();!(e=t.n()).done;){e.value.destroy()}}catch(e){t.e(e)}finally{t.f()}this.workerPools=new Map}},{key:"setProps",value:function(e){this.props=n(n({},this.props),e);var t,i=u(this.workerPools.values());try{for(i.s();!(t=i.n()).done;){t.value.setProps(this._getWorkerPoolProps())}}catch(e){i.e(e)}finally{i.f()}}},{key:"getWorkerPool",value:function(e){var t=e.name,i=e.source,r=e.url,n=this.workerPools.get(t);return n||((n=new Ay({name:t,source:i,url:r})).setProps(this._getWorkerPoolProps()),this.workerPools.set(t,n)),n}},{key:"_getWorkerPoolProps",value:function(){return{maxConcurrency:this.props.maxConcurrency,maxMobileConcurrency:this.props.maxMobileConcurrency,reuseWorkers:this.props.reuseWorkers,onDebug:this.props.onDebug}}}],[{key:"isSupported",value:function(){return hy.isSupported()}},{key:"getWorkerFarm",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return e._workerFarm=e._workerFarm||new e({}),e._workerFarm.setProps(t),e._workerFarm}}])}();iy(py,"_workerFarm",void 0);function fy(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=t[e.id]||{},r="".concat(e.id,"-worker.js"),n=i.workerUrl;if(n||"compression"!==e.id||(n=t.workerUrl),"test"===t._workerType&&(n="modules/".concat(e.module,"/dist/").concat(r)),!n){var s=e.version;"latest"===s&&(s="latest");var o=s?"@".concat(s):"";n="https://unpkg.com/@loaders.gl/".concat(e.module).concat(o,"/dist/").concat(r)}return Y_(n),n}function gy(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"3.4.15";Y_(e,"no worker provided");var i=e.version;return!(!t||!i)}function my(e,t){return!!py.isSupported()&&(!!(J_||null!=t&&t._nodeWorkers)&&(e.worker&&(null==t?void 0:t.worker)))}function vy(e,t,i,r,n){return _y.apply(this,arguments)}function _y(){return _y=a(s().mark(function e(t,i,r,n,o){var a,l,u,c,h,A;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return a=t.id,l=fy(t,r),u=py.getWorkerFarm(r),c=u.getWorkerPool({name:a,url:l}),r=JSON.parse(JSON.stringify(r)),n=JSON.parse(JSON.stringify(n||{})),e.next=8,c.startJob("process-on-worker",yy.bind(null,o));case 8:return(h=e.sent).postMessage("process",{input:i,options:r,context:n}),e.next=12,h.result;case 12:return A=e.sent,e.next=15,A.result;case 15:return e.abrupt("return",e.sent);case 16:case"end":return e.stop()}},e)})),_y.apply(this,arguments)}function yy(e,t,i,r){return by.apply(this,arguments)}function by(){return(by=a(s().mark(function e(t,i,r,n){var o,a,l,u,c;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:e.t0=r,e.next="done"===e.t0?3:"error"===e.t0?5:"process"===e.t0?7:20;break;case 3:return i.done(n),e.abrupt("break",21);case 5:return i.error(new Error(n.error)),e.abrupt("break",21);case 7:return o=n.id,a=n.input,l=n.options,e.prev=8,e.next=11,t(a,l);case 11:u=e.sent,i.postMessage("done",{id:o,result:u}),e.next=19;break;case 15:e.prev=15,e.t1=e.catch(8),c=e.t1 instanceof Error?e.t1.message:"unknown error",i.postMessage("error",{id:o,error:c});case 19:return e.abrupt("break",21);case 20:console.warn("parse-with-worker unknown message ".concat(r));case 21:case"end":return e.stop()}},e,null,[[8,15]])}))).apply(this,arguments)}function wy(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];var r,n=t.map(function(e){return e instanceof ArrayBuffer?new Uint8Array(e):e}),s=n.reduce(function(e,t){return e+t.byteLength},0),o=new Uint8Array(s),a=0,l=u(n);try{for(l.s();!(r=l.n()).done;){var c=r.value;o.set(c,a),a+=c.byteLength}}catch(e){l.e(e)}finally{l.f()}return o.buffer}function xy(e){return By.apply(this,arguments)}function By(){return(By=a(s().mark(function e(t){var i,r,n,o,a,l,u;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:i=[],r=!1,n=!1,e.prev=3,a=T(t);case 5:return e.next=7,a.next();case 7:if(!(r=!(l=e.sent).done)){e.next=13;break}u=l.value,i.push(u);case 10:r=!1,e.next=5;break;case 13:e.next=19;break;case 15:e.prev=15,e.t0=e.catch(3),n=!0,o=e.t0;case 19:if(e.prev=19,e.prev=20,!r||null==a.return){e.next=24;break}return e.next=24,a.return();case 24:if(e.prev=24,!n){e.next=27;break}throw o;case 27:return e.finish(24);case 28:return e.finish(19);case 29:return e.abrupt("return",wy.apply(void 0,i));case 30:case"end":return e.stop()}},e,null,[[3,15,19,29],[20,,24,28]])}))).apply(this,arguments)}var Py={};function Cy(e){for(var t in Py)if(e.startsWith(t)){var i=Py[t];e=e.replace(t,i)}return e.startsWith("http://")||e.startsWith("https://")||(e="".concat("").concat(e)),e}function My(e){if((t=e)&&"object"===w(t)&&t.isBuffer)return e;var t;if(e instanceof ArrayBuffer)return e;if(ArrayBuffer.isView(e))return 0===e.byteOffset&&e.byteLength===e.buffer.byteLength?e.buffer:e.buffer.slice(e.byteOffset,e.byteOffset+e.byteLength);if("string"==typeof e){var i=e;return(new TextEncoder).encode(i).buffer}if(e&&"object"===w(e)&&e._toArrayBuffer)return e._toArrayBuffer();throw new Error("toArrayBuffer")}function ky(e){var t=e?e.lastIndexOf("/"):-1;return t>=0?e.substr(t+1):""}var Ey=function(e){return"function"==typeof e},Sy=function(e){return null!==e&&"object"===w(e)},Ty=function(e){return Sy(e)&&e.constructor==={}.constructor},Iy=function(e){return e&&"function"==typeof e[Symbol.iterator]},Fy=function(e){return e&&"function"==typeof e[Symbol.asyncIterator]},Dy=function(e){return"undefined"!=typeof Response&&e instanceof Response||e&&e.arrayBuffer&&e.text&&e.json},Ry=function(e){return"undefined"!=typeof Blob&&e instanceof Blob},Oy=function(e){return function(e){return"undefined"!=typeof ReadableStream&&e instanceof ReadableStream||Sy(e)&&Ey(e.tee)&&Ey(e.cancel)&&Ey(e.getReader)}(e)||function(e){return Sy(e)&&Ey(e.read)&&Ey(e.pipe)&&function(e){return"boolean"==typeof e}(e.readable)}(e)},Ly=/^data:([-\w.]+\/[-\w.+]+)(;|,)/,jy=/^([-\w.]+\/[-\w.+]+)/;function Uy(e){var t=Ly.exec(e);return t?t[1]:""}var Ny=/\?.*/;function Vy(e){return e.replace(Ny,"")}function Qy(e){return Dy(e)?e.url:Ry(e)?e.name||"":"string"==typeof e?e:""}function Hy(e){if(Dy(e)){var t=e,i=t.headers.get("content-type")||"",r=Vy(t.url);return function(e){var t=jy.exec(e);return t?t[1]:e}(i)||Uy(r)}return Ry(e)?e.type||"":"string"==typeof e?Uy(e):""}function Gy(e){return Dy(e)?e.headers["content-length"]||-1:Ry(e)?e.size:"string"==typeof e?e.length:e instanceof ArrayBuffer||ArrayBuffer.isView(e)?e.byteLength:-1}function zy(e){return Wy.apply(this,arguments)}function Wy(){return(Wy=a(s().mark(function e(t){var i,r,n,o,a,l;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!Dy(t)){e.next=2;break}return e.abrupt("return",t);case 2:return i={},(r=Gy(t))>=0&&(i["content-length"]=String(r)),n=Qy(t),(o=Hy(t))&&(i["content-type"]=o),e.next=10,Jy(t);case 10:return(a=e.sent)&&(i["x-first-bytes"]=a),"string"==typeof t&&(t=(new TextEncoder).encode(t)),l=new Response(t,{headers:i}),Object.defineProperty(l,"url",{value:n}),e.abrupt("return",l);case 16:case"end":return e.stop()}},e)}))).apply(this,arguments)}function Ky(e){return Xy.apply(this,arguments)}function Xy(){return(Xy=a(s().mark(function e(t){var i;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(t.ok){e.next=5;break}return e.next=3,qy(t);case 3:throw i=e.sent,new Error(i);case 5:case"end":return e.stop()}},e)}))).apply(this,arguments)}function qy(e){return Yy.apply(this,arguments)}function Yy(){return(Yy=a(s().mark(function e(t){var i,r,n;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(i="Failed to fetch resource ".concat(t.url," (").concat(t.status,"): "),e.prev=1,r=t.headers.get("Content-Type"),n=t.statusText,!r.includes("application/json")){e.next=11;break}return e.t0=n,e.t1=" ",e.next=9,t.text();case 9:e.t2=e.sent,n=e.t0+=e.t1.concat.call(e.t1,e.t2);case 11:i=(i+=n).length>60?"".concat(i.slice(0,60),"..."):i,e.next=17;break;case 15:e.prev=15,e.t3=e.catch(1);case 17:return e.abrupt("return",i);case 18:case"end":return e.stop()}},e,null,[[1,15]])}))).apply(this,arguments)}function Jy(e){return Zy.apply(this,arguments)}function Zy(){return(Zy=a(s().mark(function e(t){var i,r,n,o;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(i=5,"string"!=typeof t){e.next=3;break}return e.abrupt("return","data:,".concat(t.slice(0,i)));case 3:if(!(t instanceof Blob)){e.next=8;break}return r=t.slice(0,5),e.next=7,new Promise(function(e){var t=new FileReader;t.onload=function(t){var i;return e(null==t||null===(i=t.target)||void 0===i?void 0:i.result)},t.readAsDataURL(r)});case 7:return e.abrupt("return",e.sent);case 8:if(!(t instanceof ArrayBuffer)){e.next=12;break}return n=t.slice(0,i),o=$y(n),e.abrupt("return","data:base64,".concat(o));case 12:return e.abrupt("return",null);case 13:case"end":return e.stop()}},e)}))).apply(this,arguments)}function $y(e){for(var t="",i=new Uint8Array(e),r=0;r<i.byteLength;r++)t+=String.fromCharCode(i[r]);return btoa(t)}function eb(e,t){return tb.apply(this,arguments)}function tb(){return(tb=a(s().mark(function e(t,i){var r;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if("string"!=typeof t){e.next=7;break}return t=Cy(t),r=i,null!=i&&i.fetch&&"function"!=typeof(null==i?void 0:i.fetch)&&(r=i.fetch),e.next=6,fetch(t,r);case 6:case 9:return e.abrupt("return",e.sent);case 7:return e.next=9,zy(t);case 10:case"end":return e.stop()}},e)}))).apply(this,arguments)}function ib(){return!("object"===("undefined"==typeof process?"undefined":w(process))&&"[object process]"===String(process)&&!process.browser)||function(e){if("undefined"!=typeof window&&"object"===w(window.process)&&"renderer"===window.process.type)return!0;if("undefined"!=typeof process&&"object"===w(process.versions)&&Boolean(process.versions.electron))return!0;var t="object"===("undefined"==typeof navigator?"undefined":w(navigator))&&"string"==typeof navigator.userAgent&&navigator.userAgent,i=e||t;return!!(i&&i.indexOf("Electron")>=0)}()}var rb={self:"undefined"!=typeof self&&self,window:"undefined"!=typeof window&&window,global:"undefined"!=typeof global&&global,document:"undefined"!=typeof document&&document,process:"object"===("undefined"==typeof process?"undefined":w(process))&&process},nb=rb.window||rb.self||rb.global,sb=rb.process||{},ob="undefined"!=typeof __VERSION__?__VERSION__:"untranspiled source";ib();var ab,lb=function(){return P(function e(t,i){x(this,e);var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"sessionStorage";iy(this,"storage",void 0),iy(this,"id",void 0),iy(this,"config",void 0),this.storage=function(e){try{var t=window[e],i="__storage_test__";return t.setItem(i,i),t.removeItem(i),t}catch(e){return null}}(r),this.id=t,this.config=i,this._loadConfiguration()},[{key:"getConfiguration",value:function(){return this.config}},{key:"setConfiguration",value:function(e){if(Object.assign(this.config,e),this.storage){var t=JSON.stringify(this.config);this.storage.setItem(this.id,t)}}},{key:"_loadConfiguration",value:function(){var e={};if(this.storage){var t=this.storage.getItem(this.id);e=t?JSON.parse(t):{}}return Object.assign(this.config,e),this}}])}();function ub(e,t,i){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:600,n=e.src.replace(/\(/g,"%28").replace(/\)/g,"%29");e.width>r&&(i=Math.min(i,r/e.width));var s=e.width*i,o=e.height*i,a=["font-size:1px;","padding:".concat(Math.floor(o/2),"px ").concat(Math.floor(s/2),"px;"),"line-height:".concat(o,"px;"),"background:url(".concat(n,");"),"background-size:".concat(s,"px ").concat(o,"px;"),"color:transparent;"].join("");return["".concat(t," %c+"),a]}function cb(e){return"string"==typeof e?ab[e.toUpperCase()]||ab.WHITE:e}function hb(e,t){if(!e)throw new Error(t||"Assertion failed")}function Ab(){var e,t,i;if(ib&&"performance"in nb)e=null==nb||null===(t=nb.performance)||void 0===t||null===(i=t.now)||void 0===i?void 0:i.call(t);else if("hrtime"in sb){var r,n=null==sb||null===(r=sb.hrtime)||void 0===r?void 0:r.call(sb);e=1e3*n[0]+n[1]/1e6}else e=Date.now();return e}!function(e){e[e.BLACK=30]="BLACK",e[e.RED=31]="RED",e[e.GREEN=32]="GREEN",e[e.YELLOW=33]="YELLOW",e[e.BLUE=34]="BLUE",e[e.MAGENTA=35]="MAGENTA",e[e.CYAN=36]="CYAN",e[e.WHITE=37]="WHITE",e[e.BRIGHT_BLACK=90]="BRIGHT_BLACK",e[e.BRIGHT_RED=91]="BRIGHT_RED",e[e.BRIGHT_GREEN=92]="BRIGHT_GREEN",e[e.BRIGHT_YELLOW=93]="BRIGHT_YELLOW",e[e.BRIGHT_BLUE=94]="BRIGHT_BLUE",e[e.BRIGHT_MAGENTA=95]="BRIGHT_MAGENTA",e[e.BRIGHT_CYAN=96]="BRIGHT_CYAN",e[e.BRIGHT_WHITE=97]="BRIGHT_WHITE"}(ab||(ab={}));var db={debug:ib&&console.debug||console.log,log:console.log,info:console.info,warn:console.warn,error:console.error},pb={enabled:!0,level:0};function fb(){}var gb={},mb={once:!0},vb=function(){return P(function e(){x(this,e);var t=(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{id:""}).id;iy(this,"id",void 0),iy(this,"VERSION",ob),iy(this,"_startTs",Ab()),iy(this,"_deltaTs",Ab()),iy(this,"_storage",void 0),iy(this,"userData",{}),iy(this,"LOG_THROTTLE_TIMEOUT",0),this.id=t,this.userData={},this._storage=new lb("__probe-".concat(this.id,"__"),pb),this.timeStamp("".concat(this.id," started")),function(e){var t,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:["constructor"],r=Object.getPrototypeOf(e),n=u(Object.getOwnPropertyNames(r));try{var s=function(){var r=t.value;"function"==typeof e[r]&&(i.find(function(e){return r===e})||(e[r]=e[r].bind(e)))};for(n.s();!(t=n.n()).done;)s()}catch(e){n.e(e)}finally{n.f()}}(this),Object.seal(this)},[{key:"level",get:function(){return this.getLevel()},set:function(e){this.setLevel(e)}},{key:"isEnabled",value:function(){return this._storage.config.enabled}},{key:"getLevel",value:function(){return this._storage.config.level}},{key:"getTotal",value:function(){return Number((Ab()-this._startTs).toPrecision(10))}},{key:"getDelta",value:function(){return Number((Ab()-this._deltaTs).toPrecision(10))}},{key:"priority",get:function(){return this.level},set:function(e){this.level=e}},{key:"getPriority",value:function(){return this.level}},{key:"enable",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return this._storage.setConfiguration({enabled:e}),this}},{key:"setLevel",value:function(e){return this._storage.setConfiguration({level:e}),this}},{key:"get",value:function(e){return this._storage.config[e]}},{key:"set",value:function(e,t){this._storage.setConfiguration(b({},e,t))}},{key:"settings",value:function(){console.table?console.table(this._storage.config):console.log(this._storage.config)}},{key:"assert",value:function(e,t){hb(e,t)}},{key:"warn",value:function(e){return this._getLogFunction(0,e,db.warn,arguments,mb)}},{key:"error",value:function(e){return this._getLogFunction(0,e,db.error,arguments)}},{key:"deprecated",value:function(e,t){return this.warn("`".concat(e,"` is deprecated and will be removed in a later version. Use `").concat(t,"` instead"))}},{key:"removed",value:function(e,t){return this.error("`".concat(e,"` has been removed. Use `").concat(t,"` instead"))}},{key:"probe",value:function(e,t){return this._getLogFunction(e,t,db.log,arguments,{time:!0,once:!0})}},{key:"log",value:function(e,t){return this._getLogFunction(e,t,db.debug,arguments)}},{key:"info",value:function(e,t){return this._getLogFunction(e,t,console.info,arguments)}},{key:"once",value:function(e,t){for(var i=arguments.length,r=new Array(i>2?i-2:0),n=2;n<i;n++)r[n-2]=arguments[n];return this._getLogFunction(e,t,db.debug||db.info,arguments,mb)}},{key:"table",value:function(e,t,i){return t?this._getLogFunction(e,t,console.table||fb,i&&[i],{tag:bb(t)}):fb}},{key:"image",value:function(e){var t=e.logLevel,i=e.priority,r=e.image,n=e.message,s=void 0===n?"":n,o=e.scale,a=void 0===o?1:o;return this._shouldLog(t||i)?ib?function(e){var t=e.image,i=e.message,r=void 0===i?"":i,n=e.scale,s=void 0===n?1:n;if("string"==typeof t){var o=new Image;return o.onload=function(){var e,t=ub(o,r,s);(e=console).log.apply(e,l(t))},o.src=t,fb}var a=t.nodeName||"";if("img"===a.toLowerCase()){var u;return(u=console).log.apply(u,l(ub(t,r,s))),fb}if("canvas"===a.toLowerCase()){var c=new Image;return c.onload=function(){var e;return(e=console).log.apply(e,l(ub(c,r,s)))},c.src=t.toDataURL(),fb}return fb}({image:r,message:s,scale:a}):(console.warn("removed"),fb):fb}},{key:"time",value:function(e,t){return this._getLogFunction(e,t,console.time?console.time:console.info)}},{key:"timeEnd",value:function(e,t){return this._getLogFunction(e,t,console.timeEnd?console.timeEnd:console.info)}},{key:"timeStamp",value:function(e,t){return this._getLogFunction(e,t,console.timeStamp||fb)}},{key:"group",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{collapsed:!1},r=yb({logLevel:e,message:t,opts:i}),n=i.collapsed;return r.method=(n?console.groupCollapsed:console.group)||console.info,this._getLogFunction(r)}},{key:"groupCollapsed",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this.group(e,t,Object.assign({},i,{collapsed:!0}))}},{key:"groupEnd",value:function(e){return this._getLogFunction(e,"",console.groupEnd||fb)}},{key:"withGroup",value:function(e,t,i){this.group(e,t)();try{i()}finally{this.groupEnd(e)()}}},{key:"trace",value:function(){console.trace&&console.trace()}},{key:"_shouldLog",value:function(e){return this.isEnabled()&&this.getLevel()>=_b(e)}},{key:"_getLogFunction",value:function(e,t,i,r,n){if(this._shouldLog(e)){var s;n=yb({logLevel:e,message:t,args:r,opts:n}),hb(i=i||n.method),n.total=this.getTotal(),n.delta=this.getDelta(),this._deltaTs=Ab();var o=n.tag||n.message;if(n.once){if(gb[o])return fb;gb[o]=Ab()}return t=function(e,t,i){if("string"==typeof t){var r=i.time?function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:8,i=Math.max(t-e.length,0);return"".concat(" ".repeat(i)).concat(e)}((n=i.total)<10?"".concat(n.toFixed(2),"ms"):n<100?"".concat(n.toFixed(1),"ms"):n<1e3?"".concat(n.toFixed(0),"ms"):"".concat((n/1e3).toFixed(2),"s")):"";t=function(e,t,i){return ib||"string"!=typeof e||(t&&(t=cb(t),e="[".concat(t,"m").concat(e,"[39m")),i&&(t=cb(i),e="[".concat(i+10,"m").concat(e,"[49m"))),e}(t=i.time?"".concat(e,": ").concat(r," ").concat(t):"".concat(e,": ").concat(t),i.color,i.background)}var n;return t}(this.id,n.message,n),(s=i).bind.apply(s,[console,t].concat(l(n.args)))}return fb}}])}();function _b(e){if(!e)return 0;var t;switch(w(e)){case"number":t=e;break;case"object":t=e.logLevel||e.priority||0;break;default:return 0}return hb(Number.isFinite(t)&&t>=0),t}function yb(e){var t=e.logLevel,i=e.message;e.logLevel=_b(t);for(var r=e.args?Array.from(e.args):[];r.length&&r.shift()!==i;);switch(w(t)){case"string":case"function":void 0!==i&&r.unshift(i),e.message=t;break;case"object":Object.assign(e,t)}"function"==typeof e.message&&(e.message=e.message());var n=w(e.message);return hb("string"===n||"object"===n),Object.assign(e,{args:r},e.opts)}function bb(e){for(var t in e)for(var i in e[t])return i||"untitled";return"empty"}iy(vb,"VERSION",ob);var wb=new vb({id:"loaders.gl"}),xb=function(){return P(function e(){x(this,e)},[{key:"log",value:function(){return function(){}}},{key:"info",value:function(){return function(){}}},{key:"warn",value:function(){return function(){}}},{key:"error",value:function(){return function(){}}}])}(),Bb={fetch:null,mimeType:void 0,nothrow:!1,log:new(function(){return P(function e(){x(this,e),iy(this,"console",void 0),this.console=console},[{key:"log",value:function(){for(var e,t=arguments.length,i=new Array(t),r=0;r<t;r++)i[r]=arguments[r];return(e=this.console.log).bind.apply(e,[this.console].concat(i))}},{key:"info",value:function(){for(var e,t=arguments.length,i=new Array(t),r=0;r<t;r++)i[r]=arguments[r];return(e=this.console.info).bind.apply(e,[this.console].concat(i))}},{key:"warn",value:function(){for(var e,t=arguments.length,i=new Array(t),r=0;r<t;r++)i[r]=arguments[r];return(e=this.console.warn).bind.apply(e,[this.console].concat(i))}},{key:"error",value:function(){for(var e,t=arguments.length,i=new Array(t),r=0;r<t;r++)i[r]=arguments[r];return(e=this.console.error).bind.apply(e,[this.console].concat(i))}}])}()),CDN:"https://unpkg.com/@loaders.gl",worker:!0,maxConcurrency:3,maxMobileConcurrency:1,reuseWorkers:X_,_nodeWorkers:!1,_workerType:"",limit:0,_limitMB:0,batchSize:"auto",batchDebounceMs:0,metadata:!1,transforms:[]},Pb={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 Cb(){globalThis.loaders=globalThis.loaders||{};var e=globalThis.loaders;return e._state=e._state||{},e._state}var Mb=function(){var e=Cb();return e.globalOptions=e.globalOptions||n({},Bb),e.globalOptions};function kb(e,t,i,r){return i=i||[],function(e,t){Eb(e,null,Bb,Pb,t);var i,r=u(t);try{for(r.s();!(i=r.n()).done;){var n=i.value,s=e&&e[n.id]||{},o=n.options&&n.options[n.id]||{},a=n.deprecatedOptions&&n.deprecatedOptions[n.id]||{};Eb(s,n.id,o,a,t)}}catch(e){r.e(e)}finally{r.f()}}(e,i=Array.isArray(i)?i:[i]),function(e,t,i){var r=e.options||{},s=n({},r);(function(e,t){t&&!("baseUri"in e)&&(e.baseUri=t)})(s,i),null===s.log&&(s.log=new xb);return Tb(s,Mb()),Tb(s,t),s}(t,e,r)}function Eb(e,t,i,r,n){var s=t||"Top level",o=t?"".concat(t,"."):"";for(var a in e){var l=!t&&Sy(e[a]);if(!(a in i)&&!("baseUri"===a&&!t)&&!("workerUrl"===a&&t))if(a in r)wb.warn("".concat(s," loader option '").concat(o).concat(a,"' no longer supported, use '").concat(r[a],"'"))();else if(!l){var u=Sb(a,n);wb.warn("".concat(s," loader option '").concat(o).concat(a,"' not recognized. ").concat(u))()}}}function Sb(e,t){var i,r=e.toLowerCase(),n="",s=u(t);try{for(s.s();!(i=s.n()).done;){var o=i.value;for(var a in o.options){if(e===a)return"Did you mean '".concat(o.id,".").concat(a,"'?");var l=a.toLowerCase();(r.startsWith(l)||l.startsWith(r))&&(n=n||"Did you mean '".concat(o.id,".").concat(a,"'?"))}}}catch(e){s.e(e)}finally{s.f()}return n}function Tb(e,t){for(var i in t)if(i in t){var r=t[i];Ty(r)&&Ty(e[i])?e[i]=n(n({},e[i]),t[i]):e[i]=t[i]}}function Ib(e){var t;return!!e&&(Array.isArray(e)&&(e=e[0]),Array.isArray(null===(t=e)||void 0===t?void 0:t.extensions))}function Fb(e){var t,i,r;return K_(e,"null loader"),K_(Ib(e),"invalid loader"),Array.isArray(e)&&(r=e[1],e=n(n({},e=e[0]),{},{options:n(n({},e.options),r)})),(null!==(t=e)&&void 0!==t&&t.parseTextSync||null!==(i=e)&&void 0!==i&&i.parseText)&&(e.text=!0),e.text||(e.binary=!0),e}function Db(){return(e=Cb()).loaderRegistry=e.loaderRegistry||[],e.loaderRegistry;var e}var Rb=new vb({id:"loaders.gl"}),Ob=/\.([^.]+)$/;function Lb(e){return jb.apply(this,arguments)}function jb(){return jb=a(s().mark(function e(t){var i,r,o,a,l=arguments;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(i=l.length>1&&void 0!==l[1]?l[1]:[],r=l.length>2?l[2]:void 0,o=l.length>3?l[3]:void 0,Nb(t)){e.next=5;break}return e.abrupt("return",null);case 5:if(!(a=Ub(t,i,n(n({},r),{},{nothrow:!0}),o))){e.next=8;break}return e.abrupt("return",a);case 8:if(!Ry(t)){e.next=13;break}return e.next=11,t.slice(0,10).arrayBuffer();case 11:t=e.sent,a=Ub(t,i,r,o);case 13:if(a||null!=r&&r.nothrow){e.next=15;break}throw new Error(Vb(t));case 15:return e.abrupt("return",a);case 16:case"end":return e.stop()}},e)})),jb.apply(this,arguments)}function Ub(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],i=arguments.length>2?arguments[2]:void 0,r=arguments.length>3?arguments[3]:void 0;if(!Nb(e))return null;if(t&&!Array.isArray(t))return Fb(t);var n,s=[];(t&&(s=s.concat(t)),null!=i&&i.ignoreRegisteredLoaders)||(n=s).push.apply(n,l(Db()));!function(e){var t,i=u(e);try{for(i.s();!(t=i.n()).done;){Fb(t.value)}}catch(e){i.e(e)}finally{i.f()}}(s);var o=function(e,t,i,r){var n,s=Qy(e),o=Hy(e),a=Vy(s)||(null==r?void 0:r.url),l=null,c="";null!=i&&i.mimeType&&(l=Qb(t,null==i?void 0:i.mimeType),c="match forced by supplied MIME type ".concat(null==i?void 0:i.mimeType));l=l||function(e,t){var i=t&&Ob.exec(t),r=i&&i[1];return r?function(e,t){t=t.toLowerCase();var i,r=u(e);try{for(r.s();!(i=r.n()).done;){var n,s=i.value,o=u(s.extensions);try{for(o.s();!(n=o.n()).done;){if(n.value.toLowerCase()===t)return s}}catch(e){o.e(e)}finally{o.f()}}}catch(e){r.e(e)}finally{r.f()}return null}(e,r):null}(t,a),c=c||(l?"matched url ".concat(a):""),l=l||Qb(t,o),c=c||(l?"matched MIME type ".concat(o):""),l=l||function(e,t){if(!t)return null;var i,r=u(e);try{for(r.s();!(i=r.n()).done;){var n=i.value;if("string"==typeof t){if(Hb(t,n))return n}else if(ArrayBuffer.isView(t)){if(Gb(t.buffer,t.byteOffset,n))return n}else if(t instanceof ArrayBuffer){if(Gb(t,0,n))return n}}}catch(e){r.e(e)}finally{r.f()}return null}(t,e),c=c||(l?"matched initial data ".concat(zb(e)):""),l=l||Qb(t,null==i?void 0:i.fallbackMimeType),c=c||(l?"matched fallback MIME type ".concat(o):""),c&&Rb.log(1,"selectLoader selected ".concat(null===(n=l)||void 0===n?void 0:n.name,": ").concat(c,"."));return l}(e,s,i,r);if(!(o||null!=i&&i.nothrow))throw new Error(Vb(e));return o}function Nb(e){return!(e instanceof Response&&204===e.status)}function Vb(e){var t=Qy(e),i=Hy(e),r="No valid loader found (";r+=t?"".concat(ky(t),", "):"no url provided, ",r+="MIME type: ".concat(i?'"'.concat(i,'"'):"not provided",", ");var n=e?zb(e):"";return r+=n?' first bytes: "'.concat(n,'"'):"first bytes: not available",r+=")"}function Qb(e,t){var i,r=u(e);try{for(r.s();!(i=r.n()).done;){var n=i.value;if(n.mimeTypes&&n.mimeTypes.includes(t))return n;if(t==="application/x.".concat(n.id))return n}}catch(e){r.e(e)}finally{r.f()}return null}function Hb(e,t){return t.testText?t.testText(e):(Array.isArray(t.tests)?t.tests:[t.tests]).some(function(t){return e.startsWith(t)})}function Gb(e,t,i){return(Array.isArray(i.tests)?i.tests:[i.tests]).some(function(r){return function(e,t,i,r){if(r instanceof ArrayBuffer)return function(e,t,i){if(i=i||e.byteLength,e.byteLength<i||t.byteLength<i)return!1;for(var r=new Uint8Array(e),n=new Uint8Array(t),s=0;s<r.length;++s)if(r[s]!==n[s])return!1;return!0}(r,e,r.byteLength);switch(w(r)){case"function":return r(e,i);case"string":return r===Wb(e,t,r.length);default:return!1}}(e,t,i,r)})}function zb(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:5;if("string"==typeof e)return e.slice(0,t);if(ArrayBuffer.isView(e))return Wb(e.buffer,e.byteOffset,t);if(e instanceof ArrayBuffer){return Wb(e,0,t)}return""}function Wb(e,t,i){if(e.byteLength<t+i)return"";for(var r=new DataView(e),n="",s=0;s<i;s++)n+=String.fromCharCode(r.getUint8(t+s));return n}var Kb=262144;function Xb(e,i){var r,n,o,a,l;return s().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:r=(null==i?void 0:i.chunkSize)||Kb,n=0,o=new TextEncoder;case 3:if(!(n<e.length)){t.next=11;break}return a=Math.min(e.length-n,r),l=e.slice(n,n+a),n+=a,t.next=9,o.encode(l);case 9:t.next=3;break;case 11:case"end":return t.stop()}},t)}function qb(){return(qb=k(s().mark(function e(t,i){var r,n,o,a;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:r=(null==i?void 0:i.chunkSize)||1048576,n=0;case 2:if(!(n<t.size)){e.next=12;break}return o=n+r,e.next=6,M(t.slice(n,o).arrayBuffer());case 6:return a=e.sent,n=o,e.next=10,a;case 10:e.next=2;break;case 12:case"end":return e.stop()}},e)}))).apply(this,arguments)}function Yb(e,t){return X_?function(e,t){return Jb.apply(this,arguments)}(e,t):function(e,t){return Zb.apply(this,arguments)}(e)}function Jb(){return(Jb=k(s().mark(function e(t,i){var r,n,o,a,l,u;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:r=t.getReader(),e.prev=1;case 2:return o=n||r.read(),null!=i&&i._streamReadAhead&&(n=r.read()),e.next=7,M(o);case 7:if(a=e.sent,l=a.done,u=a.value,!l){e.next=12;break}return e.abrupt("return");case 12:return e.next=14,My(u);case 14:e.next=2;break;case 16:e.next=21;break;case 18:e.prev=18,e.t0=e.catch(1),r.releaseLock();case 21:case"end":return e.stop()}},e,null,[[1,18]])}))).apply(this,arguments)}function Zb(){return(Zb=k(s().mark(function e(t,i){var r,n,o,a,l,u;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:r=!1,n=!1,e.prev=2,a=T(t);case 4:return e.next=6,M(a.next());case 6:if(!(r=!(l=e.sent).done)){e.next=13;break}return u=l.value,e.next=10,My(u);case 10:r=!1,e.next=4;break;case 13:e.next=19;break;case 15:e.prev=15,e.t0=e.catch(2),n=!0,o=e.t0;case 19:if(e.prev=19,e.prev=20,!r||null==a.return){e.next=24;break}return e.next=24,M(a.return());case 24:if(e.prev=24,!n){e.next=27;break}throw o;case 27:return e.finish(24);case 28:return e.finish(19);case 29:case"end":return e.stop()}},e,null,[[2,15,19,29],[20,,24,28]])}))).apply(this,arguments)}function $b(e,t){if("string"==typeof e)return Xb(e,t);if(e instanceof ArrayBuffer)return function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return s().mark(function i(){var r,n,o,a,l,u;return s().wrap(function(i){for(;;)switch(i.prev=i.next){case 0:r=t.chunkSize,n=void 0===r?262144:r,o=0;case 2:if(!(o<e.byteLength)){i.next=13;break}return a=Math.min(e.byteLength-o,n),l=new ArrayBuffer(a),u=new Uint8Array(e,o,a),new Uint8Array(l).set(u),o+=a,i.next=11,l;case 11:i.next=2;break;case 13:case"end":return i.stop()}},i)})()}(e,t);if(Ry(e))return function(e,t){return qb.apply(this,arguments)}(e,t);if(Oy(e))return Yb(e,t);if(Dy(e))return Yb(e.body,t);throw new Error("makeIterator")}var ew="Cannot convert supplied data type";function tw(e,t,i){if(t.text&&"string"==typeof e)return e;var r;if((r=e)&&"object"===w(r)&&r.isBuffer&&(e=e.buffer),e instanceof ArrayBuffer){var n=e;return t.text&&!t.binary?new TextDecoder("utf8").decode(n):n}if(ArrayBuffer.isView(e)){if(t.text&&!t.binary)return new TextDecoder("utf8").decode(e);var s=e.buffer,o=e.byteLength||e.length;return 0===e.byteOffset&&o===s.byteLength||(s=s.slice(e.byteOffset,e.byteOffset+o)),s}throw new Error(ew)}function iw(e,t,i){return rw.apply(this,arguments)}function rw(){return rw=a(s().mark(function e(t,i,r){var n,o;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t instanceof ArrayBuffer||ArrayBuffer.isView(t),"string"!=typeof t&&!n){e.next=3;break}return e.abrupt("return",tw(t,i));case 3:if(!Ry(t)){e.next=7;break}return e.next=6,zy(t);case 6:t=e.sent;case 7:if(!Dy(t)){e.next=21;break}return o=t,e.next=11,Ky(o);case 11:if(!i.binary){e.next=17;break}return e.next=14,o.arrayBuffer();case 14:e.t0=e.sent,e.next=20;break;case 17:return e.next=19,o.text();case 19:e.t0=e.sent;case 20:return e.abrupt("return",e.t0);case 21:if(Oy(t)&&(t=$b(t,r)),!Iy(t)&&!Fy(t)){e.next=24;break}return e.abrupt("return",xy(t));case 24:throw new Error(ew);case 25:case"end":return e.stop()}},e)})),rw.apply(this,arguments)}function nw(e,t){var i=Mb(),r=e||i;return"function"==typeof r.fetch?r.fetch:Sy(r.fetch)?function(e){return eb(e,r)}:null!=t&&t.fetch?null==t?void 0:t.fetch:eb}function sw(e,t,i){if(i)return i;var r,s,o=n({fetch:nw(t,e)},e);if(o.url){var a=Vy(o.url);o.baseUrl=a,o.queryString=function(e){var t=e.match(Ny);return t&&t[0]}(o.url),o.filename=ky(a),o.baseUrl=(s=(r=a)?r.lastIndexOf("/"):-1)>=0?r.substr(0,s):""}return Array.isArray(o.loaders)||(o.loaders=null),o}function ow(e,t){if(!t&&e&&!Array.isArray(e))return e;var i;if(e&&(i=Array.isArray(e)?e:[e]),t&&t.loaders){var r=Array.isArray(t.loaders)?t.loaders:[t.loaders];i=i?[].concat(l(i),l(r)):r}return i&&i.length?i:null}function aw(e,t,i,r){return lw.apply(this,arguments)}function lw(){return(lw=a(s().mark(function e(t,i,r,n){var o,a,l;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return Y_(!n||"object"===w(n)),!i||Array.isArray(i)||Ib(i)||(n=void 0,r=i,i=void 0),e.next=4,t;case 4:return t=e.sent,r=r||{},o=Qy(t),a=ow(i,n),e.next=11,Lb(t,a,r);case 11:if(l=e.sent){e.next=14;break}return e.abrupt("return",null);case 14:return r=kb(r,l,a,o),n=sw({url:o,parse:aw,loaders:a},r,n||null),e.next=18,uw(l,t,r,n);case 18:return e.abrupt("return",e.sent);case 19:case"end":return e.stop()}},e)}))).apply(this,arguments)}function uw(e,t,i,r){return cw.apply(this,arguments)}function cw(){return(cw=a(s().mark(function e(t,i,r,n){var o,a,l,u,c,h,A,d;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return gy(t),Dy(i)&&(a=(o=i).ok,l=o.redirected,u=o.status,c=o.statusText,h=o.type,A=o.url,d=Object.fromEntries(o.headers.entries()),n.response={headers:d,ok:a,redirected:l,status:u,statusText:c,type:h,url:A}),e.next=4,iw(i,t,r);case 4:if(i=e.sent,!t.parseTextSync||"string"!=typeof i){e.next=8;break}return r.dataType="text",e.abrupt("return",t.parseTextSync(i,r,n,t));case 8:if(!my(t,r)){e.next=12;break}return e.next=11,vy(t,i,r,n,aw);case 11:case 15:case 19:return e.abrupt("return",e.sent);case 12:if(!t.parseText||"string"!=typeof i){e.next=16;break}return e.next=15,t.parseText(i,r,n,t);case 16:if(!t.parse){e.next=20;break}return e.next=19,t.parse(i,r,n,t);case 20:throw Y_(!t.parseSync),new Error("".concat(t.id," loader - no parser found and worker is disabled"));case 22:case"end":return e.stop()}},e)}))).apply(this,arguments)}var hw={self:"undefined"!=typeof self&&self,window:"undefined"!=typeof window&&window,global:"undefined"!=typeof global&&global,document:"undefined"!=typeof document&&document},Aw=hw.global||hw.self||hw.window||{},dw="object"!==("undefined"==typeof process?"undefined":w(process))||"[object process]"!==String(process)||process.browser,pw="function"==typeof importScripts,fw="undefined"!=typeof process&&process.version&&/v([0-9]*)/.exec(process.version);fw&&parseFloat(fw[1]);var gw=null,mw=Object.freeze({__proto__:null,readFileAsArrayBuffer:null,readFileAsText:null,requireFromFile:gw,requireFromString:null}),vw={};function _w(e){return yw.apply(this,arguments)}function yw(){return yw=a(s().mark(function e(t){var i,r,n=arguments;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return r=n.length>2&&void 0!==n[2]?n[2]:{},(i=n.length>1&&void 0!==n[1]?n[1]:null)&&(t=bw(t,i,r)),vw[t]=vw[t]||ww(t),e.next=6,vw[t];case 6:return e.abrupt("return",e.sent);case 7:case"end":return e.stop()}},e)})),yw.apply(this,arguments)}function bw(e,t,i){if(e.startsWith("http"))return e;var r=i.modules||{};return r[e]?r[e]:dw?i.CDN?(function(e,t){if(!e)throw new Error(t||"loaders.gl assertion failed.")}(i.CDN.startsWith("http")),"".concat(i.CDN,"/").concat(t,"@").concat("3.4.15","/dist/libs/").concat(e)):pw?"../src/libs/".concat(e):"modules/".concat(t,"/src/libs/").concat(e):"modules/".concat(t,"/dist/libs/").concat(e)}function ww(e){return xw.apply(this,arguments)}function xw(){return(xw=a(s().mark(function e(t){var i,r,n;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!t.endsWith("wasm")){e.next=7;break}return e.next=3,fetch(t);case 3:return i=e.sent,e.next=6,i.arrayBuffer();case 6:return e.abrupt("return",e.sent);case 7:if(dw){e.next=20;break}if(e.prev=8,e.t0=mw&&gw,!e.t0){e.next=14;break}return e.next=13,gw(t);case 13:e.t0=e.sent;case 14:return e.abrupt("return",e.t0);case 17:return e.prev=17,e.t1=e.catch(8),e.abrupt("return",null);case 20:if(!pw){e.next=22;break}return e.abrupt("return",importScripts(t));case 22:return e.next=24,fetch(t);case 24:return r=e.sent,e.next=27,r.text();case 27:return n=e.sent,e.abrupt("return",Bw(n,t));case 29:case"end":return e.stop()}},e,null,[[8,17]])}))).apply(this,arguments)}function Bw(e,t){if(!dw)return null;if(pw)return eval.call(Aw,e),null;var i=document.createElement("script");i.id=t;try{i.appendChild(document.createTextNode(e))}catch(t){i.text=e}return document.body.appendChild(i),null}var Pw,Cw,Mw="3.4.15",kw="https://unpkg.com/@loaders.gl/textures@".concat(Mw,"/dist/libs/basis_encoder.wasm"),Ew="https://unpkg.com/@loaders.gl/textures@".concat(Mw,"/dist/libs/basis_encoder.js");function Sw(e){return Tw.apply(this,arguments)}function Tw(){return(Tw=a(s().mark(function e(t){var i;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!(i=t.modules||{}).basis){e.next=3;break}return e.abrupt("return",i.basis);case 3:return Pw=Pw||Iw(t),e.next=6,Pw;case 6:return e.abrupt("return",e.sent);case 7:case"end":return e.stop()}},e)}))).apply(this,arguments)}function Iw(e){return Fw.apply(this,arguments)}function Fw(){return(Fw=a(s().mark(function e(t){var i,r,n,o;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return i=null,r=null,e.t0=Promise,e.next=5,_w("basis_transcoder.js","textures",t);case 5:return e.t1=e.sent,e.next=8,_w("basis_transcoder.wasm","textures",t);case 8:return e.t2=e.sent,e.t3=[e.t1,e.t2],e.next=12,e.t0.all.call(e.t0,e.t3);case 12:return n=e.sent,o=c(n,2),i=o[0],r=o[1],i=i||globalThis.BASIS,e.next=19,Dw(i,r);case 19:return e.abrupt("return",e.sent);case 20:case"end":return e.stop()}},e)}))).apply(this,arguments)}function Dw(e,t){var i={};return t&&(i.wasmBinary=t),new Promise(function(t){e(i).then(function(e){var i=e.BasisFile;(0,e.initializeBasis)(),t({BasisFile:i})})})}function Rw(e){return Ow.apply(this,arguments)}function Ow(){return(Ow=a(s().mark(function e(t){var i;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!(i=t.modules||{}).basisEncoder){e.next=3;break}return e.abrupt("return",i.basisEncoder);case 3:return Cw=Cw||Lw(t),e.next=6,Cw;case 6:return e.abrupt("return",e.sent);case 7:case"end":return e.stop()}},e)}))).apply(this,arguments)}function Lw(e){return jw.apply(this,arguments)}function jw(){return(jw=a(s().mark(function e(t){var i,r,n,o;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return i=null,r=null,e.t0=Promise,e.next=5,_w(Ew,"textures",t);case 5:return e.t1=e.sent,e.next=8,_w(kw,"textures",t);case 8:return e.t2=e.sent,e.t3=[e.t1,e.t2],e.next=12,e.t0.all.call(e.t0,e.t3);case 12:return n=e.sent,o=c(n,2),i=o[0],r=o[1],i=i||globalThis.BASIS,e.next=19,Uw(i,r);case 19:return e.abrupt("return",e.sent);case 20:case"end":return e.stop()}},e)}))).apply(this,arguments)}function Uw(e,t){var i={};return t&&(i.wasmBinary=t),new Promise(function(t){e(i).then(function(e){var i=e.BasisFile,r=e.KTX2File,n=e.initializeBasis,s=e.BasisEncoder;n(),t({BasisFile:i,KTX2File:r,BasisEncoder:s})})})}var Nw,Vw,Qw,Hw,Gw,zw,Ww,Kw,Xw,qw=33776,Yw=33779,Jw=35840,Zw=35842,$w=36196,ex=37808,tx=["","WEBKIT_","MOZ_"],ix={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"},rx=null;function nx(e){if(!rx){e=e||function(){try{return document.createElement("canvas").getContext("webgl")}catch(e){return null}}()||void 0,rx=new Set;var t,i=u(tx);try{for(i.s();!(t=i.n()).done;){var r=t.value;for(var n in ix)if(e&&e.getExtension("".concat(r).concat(n))){var s=ix[n];rx.add(s)}}}catch(e){i.e(e)}finally{i.f()}}return rx}(Xw=Nw||(Nw={}))[Xw.NONE=0]="NONE",Xw[Xw.BASISLZ=1]="BASISLZ",Xw[Xw.ZSTD=2]="ZSTD",Xw[Xw.ZLIB=3]="ZLIB",function(e){e[e.BASICFORMAT=0]="BASICFORMAT"}(Vw||(Vw={})),function(e){e[e.UNSPECIFIED=0]="UNSPECIFIED",e[e.ETC1S=163]="ETC1S",e[e.UASTC=166]="UASTC"}(Qw||(Qw={})),function(e){e[e.UNSPECIFIED=0]="UNSPECIFIED",e[e.SRGB=1]="SRGB"}(Hw||(Hw={})),function(e){e[e.UNSPECIFIED=0]="UNSPECIFIED",e[e.LINEAR=1]="LINEAR",e[e.SRGB=2]="SRGB",e[e.ITU=3]="ITU",e[e.NTSC=4]="NTSC",e[e.SLOG=5]="SLOG",e[e.SLOG2=6]="SLOG2"}(Gw||(Gw={})),function(e){e[e.ALPHA_STRAIGHT=0]="ALPHA_STRAIGHT",e[e.ALPHA_PREMULTIPLIED=1]="ALPHA_PREMULTIPLIED"}(zw||(zw={})),function(e){e[e.RGB=0]="RGB",e[e.RRR=3]="RRR",e[e.GGG=4]="GGG",e[e.AAA=15]="AAA"}(Ww||(Ww={})),function(e){e[e.RGB=0]="RGB",e[e.RGBA=3]="RGBA",e[e.RRR=4]="RRR",e[e.RRRG=5]="RRRG"}(Kw||(Kw={}));var sx=[171,75,84,88,32,50,48,187,13,10,26,10];function ox(e){var t=new Uint8Array(e);return!(t.byteLength<sx.length||t[0]!==sx[0]||t[1]!==sx[1]||t[2]!==sx[2]||t[3]!==sx[3]||t[4]!==sx[4]||t[5]!==sx[5]||t[6]!==sx[6]||t[7]!==sx[7]||t[8]!==sx[8]||t[9]!==sx[9]||t[10]!==sx[10]||t[11]!==sx[11])}var ax={etc1:{basisFormat:0,compressed:!0,format:$w},etc2:{basisFormat:1,compressed:!0},bc1:{basisFormat:2,compressed:!0,format:qw},bc3:{basisFormat:3,compressed:!0,format:Yw},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:Jw},"pvrtc1-4-rgba":{basisFormat:9,compressed:!0,format:Zw},"astc-4x4":{basisFormat:10,compressed:!0,format:ex},"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}};function lx(){return(lx=a(s().mark(function e(t,i){var r,n,o,a,l,u;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if("auto"!==i.basis.containerFormat){e.next=11;break}if(!ox(t)){e.next=6;break}return e.next=4,Rw(i);case 4:return r=e.sent,e.abrupt("return",hx(r.KTX2File,t,i));case 6:return e.next=8,Sw(i);case 8:return n=e.sent,o=n.BasisFile,e.abrupt("return",ux(o,t,i));case 11:e.t0=i.basis.module,e.next="encoder"===e.t0?14:(e.t0,22);break;case 14:return e.next=16,Rw(i);case 16:a=e.sent,e.t1=i.basis.containerFormat,e.next="ktx2"===e.t1?20:(e.t1,21);break;case 20:return e.abrupt("return",hx(a.KTX2File,t,i));case 21:return e.abrupt("return",ux(a.BasisFile,t,i));case 22:return e.next=24,Sw(i);case 24:return l=e.sent,u=l.BasisFile,e.abrupt("return",ux(u,t,i));case 27:case"end":return e.stop()}},e)}))).apply(this,arguments)}function ux(e,t,i){var r=new e(new Uint8Array(t));try{if(!r.startTranscoding())throw new Error("Failed to start basis transcoding");for(var n=r.getNumImages(),s=[],o=0;o<n;o++){for(var a=r.getNumLevels(o),l=[],u=0;u<a;u++)l.push(cx(r,o,u,i));s.push(l)}return s}finally{r.close(),r.delete()}}function cx(e,t,i,r){var n=e.getImageWidth(t,i),s=e.getImageHeight(t,i),o=e.getHasAlpha(),a=dx(r,o),l=a.compressed,u=a.format,c=a.basisFormat,h=e.getImageTranscodedSizeInBytes(t,i,c),A=new Uint8Array(h);if(!e.transcodeImage(A,t,i,c,0,0))throw new Error("failed to start Basis transcoding");return{width:n,height:s,data:A,compressed:l,format:u,hasAlpha:o}}function hx(e,t,i){var r=new e(new Uint8Array(t));try{if(!r.startTranscoding())throw new Error("failed to start KTX2 transcoding");for(var n=r.getLevels(),s=[],o=0;o<n;o++){s.push(Ax(r,o,i));break}return[s]}finally{r.close(),r.delete()}}function Ax(e,t,i){var r=e.getImageLevelInfo(t,0,0),n=r.alphaFlag,s=r.height,o=r.width,a=dx(i,n),l=a.compressed,u=a.format,c=a.basisFormat,h=e.getImageTranscodedSizeInBytes(t,0,0,c),A=new Uint8Array(h);if(!e.transcodeImage(A,t,0,0,c,0,-1,-1))throw new Error("Failed to transcode KTX2 image");return{width:o,height:s,data:A,compressed:l,levelSize:h,hasAlpha:n,format:u}}function dx(e,t){var i=e&&e.basis&&e.basis.format;return"auto"===i&&(i=px()),"object"===w(i)&&(i=t?i.alpha:i.noAlpha),i=i.toLowerCase(),ax[i]}function px(){var e=nx();return e.has("astc")?"astc-4x4":e.has("dxt")?{alpha:"bc3",noAlpha:"bc1"}:e.has("pvrtc")?{alpha:"pvrtc1-4-rgba",noAlpha:"pvrtc1-4-rgb"}:e.has("etc1")?"etc1":e.has("etc2")?"etc2":"rgb565"}var fx=n(n({},{name:"Basis",id:dw?"basis":"basis-nodejs",module:"textures",version:"3.4.15",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"}}}),{},{parse:function(e,t){return lx.apply(this,arguments)}});function gx(e,t){if(!e)throw new Error(t||"loader assertion failed.")}var mx=Boolean("object"!==("undefined"==typeof process?"undefined":w(process))||"[object process]"!==String(process)||process.browser),vx="undefined"!=typeof process&&process.version&&/v([0-9]*)/.exec(process.version);vx&&parseFloat(vx[1]);var _x=globalThis._parseImageNode,yx="undefined"!=typeof Image,bx="undefined"!=typeof ImageBitmap,wx=Boolean(_x),xx=!!mx||wx;function Bx(e){var t=function(e){if("undefined"!=typeof ImageBitmap&&e instanceof ImageBitmap)return"imagebitmap";if("undefined"!=typeof Image&&e instanceof Image)return"image";if(e&&"object"===w(e)&&e.data&&e.width&&e.height)return"data";return null}(e);if(!t)throw new Error("Not an image");return t}function Px(e){switch(Bx(e)){case"data":return e;case"image":case"imagebitmap":var t=document.createElement("canvas"),i=t.getContext("2d");if(!i)throw new Error("getImageData");return t.width=e.width,t.height=e.height,i.drawImage(e,0,0),i.getImageData(0,0,e.width,e.height);default:throw new Error("getImageData")}}var Cx=/^data:image\/svg\+xml/,Mx=/\.svg((\?|#).*)?$/;function kx(e){return e&&(Cx.test(e)||Mx.test(e))}function Ex(e,t){if(kx(t)){var i=(new TextDecoder).decode(e);try{"function"==typeof unescape&&"function"==typeof encodeURIComponent&&(i=unescape(encodeURIComponent(i)))}catch(e){throw new Error(e.message)}return"data:image/svg+xml;base64,".concat(btoa(i))}return Sx(e,t)}function Sx(e,t){if(kx(t))throw new Error("SVG cannot be parsed directly to imagebitmap");return new Blob([new Uint8Array(e)])}function Tx(e,t,i){return Ix.apply(this,arguments)}function Ix(){return(Ix=a(s().mark(function e(t,i,r){var n,o,a;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return n=Ex(t,r),o=self.URL||self.webkitURL,a="string"!=typeof n&&o.createObjectURL(n),e.prev=3,e.next=6,Fx(a||n,i);case 6:return e.abrupt("return",e.sent);case 7:return e.prev=7,a&&o.revokeObjectURL(a),e.finish(7);case 10:case"end":return e.stop()}},e,null,[[3,,7,10]])}))).apply(this,arguments)}function Fx(e,t){return Dx.apply(this,arguments)}function Dx(){return Dx=a(s().mark(function e(t,i){var r;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if((r=new Image).src=t,!(i.image&&i.image.decode&&r.decode)){e.next=6;break}return e.next=5,r.decode();case 5:return e.abrupt("return",r);case 6:return e.next=8,new Promise(function(e,i){try{r.onload=function(){return e(r)},r.onerror=function(e){return i(new Error("Could not load image ".concat(t,": ").concat(e)))}}catch(e){i(e)}});case 8:return e.abrupt("return",e.sent);case 9:case"end":return e.stop()}},e)})),Dx.apply(this,arguments)}var Rx={},Ox=!0;function Lx(e,t,i){return jx.apply(this,arguments)}function jx(){return(jx=a(s().mark(function e(t,i,r){var n,o,a;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!kx(r)){e.next=7;break}return e.next=3,Tx(t,i,r);case 3:o=e.sent,n=o,e.next=8;break;case 7:n=Sx(t,r);case 8:return a=i&&i.imagebitmap,e.next=11,Ux(n,a);case 11:return e.abrupt("return",e.sent);case 12:case"end":return e.stop()}},e)}))).apply(this,arguments)}function Ux(e){return Nx.apply(this,arguments)}function Nx(){return Nx=a(s().mark(function e(t){var i,r=arguments;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!Vx(i=r.length>1&&void 0!==r[1]?r[1]:null)&&Ox||(i=null),!i){e.next=13;break}return e.prev=3,e.next=6,createImageBitmap(t,i);case 6:return e.abrupt("return",e.sent);case 9:e.prev=9,e.t0=e.catch(3),console.warn(e.t0),Ox=!1;case 13:return e.next=15,createImageBitmap(t);case 15:return e.abrupt("return",e.sent);case 16:case"end":return e.stop()}},e,null,[[3,9]])})),Nx.apply(this,arguments)}function Vx(e){for(var t in e||Rx)return!1;return!0}function Qx(e){return function(e,t){for(var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,r=(s=t,l(s).map(function(e){return e.charCodeAt(0)})),n=0;n<r.length;++n)if(r[n]!==e[n+i])return!1;var s;return!0}(e,"ftyp",4)&&96&e[8]?function(e){switch((t=e,i=8,r=12,String.fromCharCode.apply(String,l(t.slice(i,r)))).replace("\0"," ").trim()){case"avif":case"avis":return{extension:"avif",mimeType:"image/avif"};default:return null}var t,i,r}(e):null}var Hx=!1,Gx=!0;function zx(e){var t=Wx(e);return function(e){var t=Wx(e),i=t.byteLength>=24&&2303741511===t.getUint32(0,Hx);if(!i)return null;return{mimeType:"image/png",width:t.getUint32(16,Hx),height:t.getUint32(20,Hx)}}(t)||function(e){var t=Wx(e),i=t.byteLength>=3&&65496===t.getUint16(0,Hx)&&255===t.getUint8(2);if(!i)return null;var r=function(){for(var e=new Set([65499,65476,65484,65501,65534]),t=65504;t<65520;++t)e.add(t);var i=new Set([65472,65473,65474,65475,65477,65478,65479,65481,65482,65483,65485,65486,65487,65502]);return{tableMarkers:e,sofMarkers:i}}(),n=r.tableMarkers,s=r.sofMarkers,o=2;for(;o+9<t.byteLength;){var a=t.getUint16(o,Hx);if(s.has(a))return{mimeType:"image/jpeg",height:t.getUint16(o+5,Hx),width:t.getUint16(o+7,Hx)};if(!n.has(a))return null;o+=2,o+=t.getUint16(o,Hx)}return null}(t)||function(e){var t=Wx(e),i=t.byteLength>=10&&1195984440===t.getUint32(0,Hx);if(!i)return null;return{mimeType:"image/gif",width:t.getUint16(6,Gx),height:t.getUint16(8,Gx)}}(t)||function(e){var t=Wx(e),i=t.byteLength>=14&&16973===t.getUint16(0,Hx)&&t.getUint32(2,Gx)===t.byteLength;if(!i)return null;return{mimeType:"image/bmp",width:t.getUint32(18,Gx),height:t.getUint32(22,Gx)}}(t)||function(e){var t=new Uint8Array(e instanceof DataView?e.buffer:e),i=Qx(t);if(!i)return null;return{mimeType:i.mimeType,width:0,height:0}}(t)}function Wx(e){if(e instanceof DataView)return e;if(ArrayBuffer.isView(e))return new DataView(e.buffer);if(e instanceof ArrayBuffer)return new DataView(e);throw new Error("toDataView")}function Kx(e,t){return Xx.apply(this,arguments)}function Xx(){return Xx=a(s().mark(function e(t,i){var r,n,o;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return r=zx(t)||{},n=r.mimeType,gx(o=globalThis._parseImageNode),e.next=5,o(t,n);case 5:return e.abrupt("return",e.sent);case 6:case"end":return e.stop()}},e)})),Xx.apply(this,arguments)}function qx(){return(qx=a(s().mark(function e(t,i,r){var n,o,a,l,u;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:n=(i=i||{}).image||{},o=n.type||"auto",a=(r||{}).url,l=Yx(o),e.t0=l,e.next="imagebitmap"===e.t0?8:"image"===e.t0?12:"data"===e.t0?16:20;break;case 8:return e.next=10,Lx(t,i,a);case 10:return u=e.sent,e.abrupt("break",21);case 12:return e.next=14,Tx(t,i,a);case 14:return u=e.sent,e.abrupt("break",21);case 16:return e.next=18,Kx(t);case 18:return u=e.sent,e.abrupt("break",21);case 20:gx(!1);case 21:return"data"===o&&(u=Px(u)),e.abrupt("return",u);case 23:case"end":return e.stop()}},e)}))).apply(this,arguments)}function Yx(e){switch(e){case"auto":case"data":return function(){if(bx)return"imagebitmap";if(yx)return"image";if(xx)return"data";throw new Error("Install '@loaders.gl/polyfills' to parse images under Node.js")}();default:return function(e){switch(e){case"auto":return bx||yx||xx;case"imagebitmap":return bx;case"image":return yx;case"data":return xx;default:throw new Error("@loaders.gl/images: image ".concat(e," not supported in this environment"))}}(e),e}}var Jx={id:"image",module:"images",name:"Images",version:"3.4.15",mimeTypes:["image/png","image/jpeg","image/gif","image/webp","image/avif","image/bmp","image/vnd.microsoft.icon","image/svg+xml"],extensions:["png","jpg","jpeg","gif","webp","bmp","ico","svg","avif"],parse:function(e,t,i){return qx.apply(this,arguments)},tests:[function(e){return Boolean(zx(new DataView(e)))}],options:{image:{type:"auto",decode:!0}}},Zx={};function $x(e){if(void 0===Zx[e]){var t=mx?function(e){switch(e){case"image/avif":case"image/webp":return function(e){try{return 0===document.createElement("canvas").toDataURL(e).indexOf("data:".concat(e))}catch(e){return!1}}(e);default:return!0}}(e):function(e){var t=["image/png","image/jpeg","image/gif"],i=globalThis._parseImageNode,r=globalThis._imageFormatsNode,n=void 0===r?t:r;return Boolean(i)&&n.includes(e)}(e);Zx[e]=t}return Zx[e]}function eB(e,t){if(!e)throw new Error(t||"loader assertion failed.")}function tB(e,t,i){if(e.byteLength<=t+i)return"";for(var r=new DataView(e),n="",s=0;s<i;s++)n+=String.fromCharCode(r.getUint8(t+s));return n}function iB(e){try{return JSON.parse(e)}catch(t){throw new Error('Failed to parse JSON from data starting with "'.concat(function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:5;if("string"==typeof e)return e.slice(0,t);if(ArrayBuffer.isView(e))return tB(e.buffer,e.byteOffset,t);if(e instanceof ArrayBuffer)return tB(e,0,t);return""}(e),'"'))}}function rB(e,t,i){var r=void 0!==i?new Uint8Array(e).subarray(t,t+i):new Uint8Array(e).subarray(t);return new Uint8Array(r).buffer}function nB(e,t){return eB(e>=0),eB(t>0),e+(t-1)&~(t-1)}function sB(e,t,i){var r;if(e instanceof ArrayBuffer)r=new Uint8Array(e);else{var n=e.byteOffset,s=e.byteLength;r=new Uint8Array(e.buffer||e.arrayBuffer,n,s)}return t.set(r,i),i+nB(r.byteLength,4)}function oB(e,t){if(!e)throw new Error(t||"assert failed: gltf")}function aB(e,t){if(e.startsWith("data:")||e.startsWith("http:")||e.startsWith("https:"))return e;var i=t.baseUri||t.uri;if(!i)throw new Error("'baseUri' must be provided to resolve relative url ".concat(e));return i.substr(0,i.lastIndexOf("/")+1)+e}function lB(e,t,i){var r=e.bufferViews[i];oB(r);var n=t[r.buffer];oB(n);var s=(r.byteOffset||0)+n.byteOffset;return new Uint8Array(n.arrayBuffer,s,r.byteLength)}var uB=["SCALAR","VEC2","VEC3","VEC4"],cB=[[Int8Array,5120],[Uint8Array,5121],[Int16Array,5122],[Uint16Array,5123],[Uint32Array,5125],[Float32Array,5126],[Float64Array,5130]],hB=new Map(cB),AB={SCALAR:1,VEC2:2,VEC3:3,VEC4:4,MAT2:4,MAT3:9,MAT4:16},dB={5120:1,5121:1,5122:2,5123:2,5125:4,5126:4},pB={5120:Int8Array,5121:Uint8Array,5122:Int16Array,5123:Uint16Array,5125:Uint32Array,5126:Float32Array};function fB(e){return uB[e-1]||uB[0]}function gB(e){var t=hB.get(e.constructor);if(!t)throw new Error("Illegal typed array");return t}function mB(e,t){var i=pB[e.componentType],r=AB[e.type],n=dB[e.componentType],s=e.count*r,o=e.count*r*n;return oB(o>=0&&o<=t.byteLength),{ArrayType:i,length:s,byteLength:o}}var vB,_B={asset:{version:"2.0",generator:"loaders.gl"},buffers:[]},yB=function(){return P(function e(t){x(this,e),iy(this,"gltf",void 0),iy(this,"sourceBuffers",void 0),iy(this,"byteLength",void 0),this.gltf=t||{json:n({},_B),buffers:[]},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]])},[{key:"json",get:function(){return this.gltf.json}},{key:"getApplicationData",value:function(e){return this.json[e]}},{key:"getExtraData",value:function(e){return(this.json.extras||{})[e]}},{key:"getExtension",value:function(e){var t=this.getUsedExtensions().find(function(t){return t===e}),i=this.json.extensions||{};return t?i[e]||!0:null}},{key:"getRequiredExtension",value:function(e){var t=this.getRequiredExtensions().find(function(t){return t===e});return t?this.getExtension(e):null}},{key:"getRequiredExtensions",value:function(){return this.json.extensionsRequired||[]}},{key:"getUsedExtensions",value:function(){return this.json.extensionsUsed||[]}},{key:"getRemovedExtensions",value:function(){return this.json.extensionsRemoved||[]}},{key:"getObjectExtension",value:function(e,t){return(e.extensions||{})[t]}},{key:"getScene",value:function(e){return this.getObject("scenes",e)}},{key:"getNode",value:function(e){return this.getObject("nodes",e)}},{key:"getSkin",value:function(e){return this.getObject("skins",e)}},{key:"getMesh",value:function(e){return this.getObject("meshes",e)}},{key:"getMaterial",value:function(e){return this.getObject("materials",e)}},{key:"getAccessor",value:function(e){return this.getObject("accessors",e)}},{key:"getTexture",value:function(e){return this.getObject("textures",e)}},{key:"getSampler",value:function(e){return this.getObject("samplers",e)}},{key:"getImage",value:function(e){return this.getObject("images",e)}},{key:"getBufferView",value:function(e){return this.getObject("bufferViews",e)}},{key:"getBuffer",value:function(e){return this.getObject("buffers",e)}},{key:"getObject",value:function(e,t){if("object"===w(t))return t;var i=this.json[e]&&this.json[e][t];if(!i)throw new Error("glTF file error: Could not find ".concat(e,"[").concat(t,"]"));return i}},{key:"getTypedArrayForBufferView",value:function(e){var t=(e=this.getBufferView(e)).buffer,i=this.gltf.buffers[t];oB(i);var r=(e.byteOffset||0)+i.byteOffset;return new Uint8Array(i.arrayBuffer,r,e.byteLength)}},{key:"getTypedArrayForAccessor",value:function(e){e=this.getAccessor(e);var t=this.getBufferView(e.bufferView),i=this.getBuffer(t.buffer).data,r=mB(e,t),n=r.ArrayType,s=r.length;return new n(i,t.byteOffset+e.byteOffset,s)}},{key:"getTypedArrayForImageData",value:function(e){e=this.getAccessor(e);var t=this.getBufferView(e.bufferView),i=this.getBuffer(t.buffer).data,r=t.byteOffset||0;return new Uint8Array(i,r,t.byteLength)}},{key:"addApplicationData",value:function(e,t){return this.json[e]=t,this}},{key:"addExtraData",value:function(e,t){return this.json.extras=this.json.extras||{},this.json.extras[e]=t,this}},{key:"addObjectExtension",value:function(e,t,i){return e.extensions=e.extensions||{},e.extensions[t]=i,this.registerUsedExtension(t),this}},{key:"setObjectExtension",value:function(e,t,i){(e.extensions||{})[t]=i}},{key:"removeObjectExtension",value:function(e,t){var i=e.extensions||{},r=i[t];return delete i[t],r}},{key:"addExtension",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return oB(t),this.json.extensions=this.json.extensions||{},this.json.extensions[e]=t,this.registerUsedExtension(e),t}},{key:"addRequiredExtension",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return oB(t),this.addExtension(e,t),this.registerRequiredExtension(e),t}},{key:"registerUsedExtension",value:function(e){this.json.extensionsUsed=this.json.extensionsUsed||[],this.json.extensionsUsed.find(function(t){return t===e})||this.json.extensionsUsed.push(e)}},{key:"registerRequiredExtension",value:function(e){this.registerUsedExtension(e),this.json.extensionsRequired=this.json.extensionsRequired||[],this.json.extensionsRequired.find(function(t){return t===e})||this.json.extensionsRequired.push(e)}},{key:"removeExtension",value:function(e){if(this.getExtension(e)){this.json.extensionsRequired&&this._removeStringFromArray(this.json.extensionsRequired,e),this.json.extensionsUsed&&this._removeStringFromArray(this.json.extensionsUsed,e),this.json.extensions&&delete this.json.extensions[e],Array.isArray(this.json.extensionsRemoved)||(this.json.extensionsRemoved=[]);var t=this.json.extensionsRemoved;t.includes(e)||t.push(e)}}},{key:"setDefaultScene",value:function(e){this.json.scene=e}},{key:"addScene",value:function(e){var t=e.nodeIndices;return this.json.scenes=this.json.scenes||[],this.json.scenes.push({nodes:t}),this.json.scenes.length-1}},{key:"addNode",value:function(e){var t=e.meshIndex,i=e.matrix;this.json.nodes=this.json.nodes||[];var r={mesh:t};return i&&(r.matrix=i),this.json.nodes.push(r),this.json.nodes.length-1}},{key:"addMesh",value:function(e){var t=e.attributes,i=e.indices,r=e.material,n=e.mode,s=void 0===n?4:n,o={primitives:[{attributes:this._addAttributes(t),mode:s}]};if(i){var a=this._addIndices(i);o.primitives[0].indices=a}return Number.isFinite(r)&&(o.primitives[0].material=r),this.json.meshes=this.json.meshes||[],this.json.meshes.push(o),this.json.meshes.length-1}},{key:"addPointCloud",value:function(e){var t={primitives:[{attributes:this._addAttributes(e),mode:0}]};return this.json.meshes=this.json.meshes||[],this.json.meshes.push(t),this.json.meshes.length-1}},{key:"addImage",value:function(e,t){var i=zx(e),r=t||(null==i?void 0:i.mimeType),n={bufferView:this.addBufferView(e),mimeType:r};return this.json.images=this.json.images||[],this.json.images.push(n),this.json.images.length-1}},{key:"addBufferView",value:function(e){var t=e.byteLength;oB(Number.isFinite(t)),this.sourceBuffers=this.sourceBuffers||[],this.sourceBuffers.push(e);var i={buffer:0,byteOffset:this.byteLength,byteLength:t};return this.byteLength+=nB(t,4),this.json.bufferViews=this.json.bufferViews||[],this.json.bufferViews.push(i),this.json.bufferViews.length-1}},{key:"addAccessor",value:function(e,t){var i={bufferView:e,type:fB(t.size),componentType:t.componentType,count:t.count,max:t.max,min:t.min};return this.json.accessors=this.json.accessors||[],this.json.accessors.push(i),this.json.accessors.length-1}},{key:"addBinaryBuffer",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{size:3},i=this.addBufferView(e),r={min:t.min,max:t.max};r.min&&r.max||(r=this._getAccessorMinMax(e,t.size));var n={size:t.size,componentType:gB(e),count:Math.round(e.length/t.size),min:r.min,max:r.max};return this.addAccessor(i,Object.assign(n,t))}},{key:"addTexture",value:function(e){var t={source:e.imageIndex};return this.json.textures=this.json.textures||[],this.json.textures.push(t),this.json.textures.length-1}},{key:"addMaterial",value:function(e){return this.json.materials=this.json.materials||[],this.json.materials.push(e),this.json.materials.length-1}},{key:"createBinaryChunk",value:function(){var e,t;this.gltf.buffers=[];var i,r=this.byteLength,n=new ArrayBuffer(r),s=new Uint8Array(n),o=0,a=u(this.sourceBuffers||[]);try{for(a.s();!(i=a.n()).done;){o=sB(i.value,s,o)}}catch(e){a.e(e)}finally{a.f()}null!==(e=this.json)&&void 0!==e&&null!==(t=e.buffers)&&void 0!==t&&t[0]?this.json.buffers[0].byteLength=r:this.json.buffers=[{byteLength:r}],this.gltf.binary=n,this.sourceBuffers=[n]}},{key:"_removeStringFromArray",value:function(e,t){for(var i=!0;i;){var r=e.indexOf(t);r>-1?e.splice(r,1):i=!1}}},{key:"_addAttributes",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t={};for(var i in e){var r=e[i],n=this._getGltfAttributeName(i),s=this.addBinaryBuffer(r.value,r);t[n]=s}return t}},{key:"_addIndices",value:function(e){return this.addBinaryBuffer(e,{size:1})}},{key:"_getGltfAttributeName",value:function(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}}},{key:"_getAccessorMinMax",value:function(e,t){var i={min:null,max:null};if(e.length<t)return i;i.min=[],i.max=[];var r,n=u(e.subarray(0,t));try{for(n.s();!(r=n.n()).done;){var s=r.value;i.min.push(s),i.max.push(s)}}catch(e){n.e(e)}finally{n.f()}for(var o=t;o<e.length;o+=t)for(var a=0;a<t;a++)i.min[0+a]=Math.min(i.min[0+a],e[o+a]),i.max[0+a]=Math.max(i.max[0+a],e[o+a]);return i}}])}(),bB=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]),wB=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]),xB={0:"",1:"meshopt_decodeFilterOct",2:"meshopt_decodeFilterQuat",3:"meshopt_decodeFilterExp",NONE:"",OCTAHEDRAL:"meshopt_decodeFilterOct",QUATERNION:"meshopt_decodeFilterQuat",EXPONENTIAL:"meshopt_decodeFilterExp"},BB={0:"meshopt_decodeVertexBuffer",1:"meshopt_decodeIndexBuffer",2:"meshopt_decodeIndexSequence",ATTRIBUTES:"meshopt_decodeVertexBuffer",TRIANGLES:"meshopt_decodeIndexBuffer",INDICES:"meshopt_decodeIndexSequence"};function PB(e,t,i,r,n){return CB.apply(this,arguments)}function CB(){return CB=a(s().mark(function e(t,i,r,n,o){var a,l,u=arguments;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return a=u.length>5&&void 0!==u[5]?u[5]:"NONE",e.next=3,MB();case 3:IB(l=e.sent,l.exports[BB[o]],t,i,r,n,l.exports[xB[a||"NONE"]]);case 5:case"end":return e.stop()}},e)})),CB.apply(this,arguments)}function MB(){return kB.apply(this,arguments)}function kB(){return(kB=a(s().mark(function e(){return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return vB||(vB=EB()),e.abrupt("return",vB);case 2:case"end":return e.stop()}},e)}))).apply(this,arguments)}function EB(){return SB.apply(this,arguments)}function SB(){return(SB=a(s().mark(function e(){var t,i;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="B9h9z9tFBBBF8fL9gBB9gLaaaaaFa9gEaaaB9gFaFa9gEaaaFaEMcBFFFGGGEIIILF9wFFFLEFBFKNFaFCx/IFMO/LFVK9tv9t9vq95GBt9f9f939h9z9t9f9j9h9s9s9f9jW9vq9zBBp9tv9z9o9v9wW9f9kv9j9v9kv9WvqWv94h919m9mvqBF8Z9tv9z9o9v9wW9f9kv9j9v9kv9J9u9kv94h919m9mvqBGy9tv9z9o9v9wW9f9kv9j9v9kv9J9u9kv949TvZ91v9u9jvBEn9tv9z9o9v9wW9f9kv9j9v9kv69p9sWvq9P9jWBIi9tv9z9o9v9wW9f9kv9j9v9kv69p9sWvq9R919hWBLn9tv9z9o9v9wW9f9kv9j9v9kv69p9sWvq9F949wBKI9z9iqlBOc+x8ycGBM/qQFTa8jUUUUBCU/EBlHL8kUUUUBC9+RKGXAGCFJAI9LQBCaRKAE2BBC+gF9HQBALAEAIJHOAGlAGTkUUUBRNCUoBAG9uC/wgBZHKCUGAKCUG9JyRVAECFJRICBRcGXEXAcAF9PQFAVAFAclAcAVJAF9JyRMGXGXAG9FQBAMCbJHKC9wZRSAKCIrCEJCGrRQANCUGJRfCBRbAIRTEXGXAOATlAQ9PQBCBRISEMATAQJRIGXAS9FQBCBRtCBREEXGXAOAIlCi9PQBCBRISLMANCU/CBJAEJRKGXGXGXGXGXATAECKrJ2BBAtCKZrCEZfIBFGEBMAKhB83EBAKCNJhB83EBSEMAKAI2BIAI2BBHmCKrHYAYCE6HYy86BBAKCFJAICIJAYJHY2BBAmCIrCEZHPAPCE6HPy86BBAKCGJAYAPJHY2BBAmCGrCEZHPAPCE6HPy86BBAKCEJAYAPJHY2BBAmCEZHmAmCE6Hmy86BBAKCIJAYAmJHY2BBAI2BFHmCKrHPAPCE6HPy86BBAKCLJAYAPJHY2BBAmCIrCEZ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UBGXAIAF9PQBAEAFCEZHLCEWHFJCBCAAFl/8MBAEABAICEWJHBAF/8cBBAEALT+JUUUBABAEAF/8cBBMAECAJ8kUUUUBM/hEIGaF97FaL978jUUUUBCTlRGGXAF9FQBCBREEXAGABDBBBHIABCTJHLDBBBHKDQILKOSQfbPden8c8d8e8fHOCTD+sFHNCID+rFDMIBAB9DBBU8/DY9D/zI818/DYANCEDtD9QD/6FD/nFHNAIAKDQBFGENVcMTtmYi8ZpyHICTD+rFCTD+sFD/6FD/mFHKAKD/mFANAICTD+sFD/6FD/mFHVAVD/mFANAOCTD+rFCTD+sFD/6FD/mFHOAOD/mFD/kFD/kFD/lFCBDtD+4FD/jF9DB/+g6DYHND/mF9DBBX9LDYHID/kFCggEDtHcD9OAVAND/mFAID/kFCTD+rFD9QHVAOAND/mFAID/kFCTD+rFAKAND/mFAID/kFAcD9OD9QHNDQBFTtGEmYILPdKOenHID8dBAGDBIBDyB+t+J83EBABCNJAID8dFAGDBIBDyF+t+J83EBALAVANDQNVi8ZcMpySQ8c8dfb8e8fHND8dBAGDBIBDyG+t+J83EBABCiJAND8dFAGDBIBDyE+t+J83EBABCAJRBAECIJHEAF9JQBMMM/3FGEaF978jUUUUBCoBlREGXAGCGrAF9sHIC98ZHL9FQBCBRGABRFEXAFAFDBBBHKCND+rFCND+sFD/6FAKCiD+sFCnD+rFCUUU/8EDtD+uFD/mFDMBBAFCTJRFAGCIJHGAL9JQBMMGXALAI9PQBAEAICEZHGCGWHFqCBCoBAFl/8MBAEABALCGWJHLAF/8cBBGXAG9FQBAEAEDBIBHKCND+rFCND+sFD/6FAKCiD+sFCnD+rFCUUU/8EDtD+uFD/mFDMIBMALAEAF/8cBBMM9TFEaCBCB8oGUkUUBHFABCEJC98ZJHBjGUkUUBGXGXAB8/BCTWHGuQBCaREABAGlCggEJCTrXBCa6QFMAFREMAEMMMFBCUNMIT9tBB",console.log("Warning: meshopt_decoder is using experimental SIMD support")),e.next=4,WebAssembly.instantiate(TB(t),{});case 4:return i=e.sent,e.next=7,i.instance.exports.__wasm_call_ctors();case 7:return e.abrupt("return",i.instance);case 8:case"end":return e.stop()}},e)}))).apply(this,arguments)}function TB(e){for(var t=new Uint8Array(e.length),i=0;i<e.length;++i){var r=e.charCodeAt(i);t[i]=r>96?r-71:r>64?r-65:r>47?r+4:r>46?63:62}for(var n=0,s=0;s<e.length;++s)t[n++]=t[s]<60?wB[t[s]]:64*(t[s]-60)+t[++s];return t.buffer.slice(0,n)}function IB(e,t,i,r,n,s,o){var a=e.exports.sbrk,l=r+3&-4,u=a(l*n),c=a(s.length),h=new Uint8Array(e.exports.memory.buffer);h.set(s,c);var A=t(u,r,n,c,s.length);if(0===A&&o&&o(u,l,n),i.set(h.subarray(u,u+r*n)),a(u-a(0)),0!==A)throw new Error("Malformed buffer data: ".concat(A))}var FB="EXT_meshopt_compression",DB=FB;function RB(){return(RB=a(s().mark(function e(t,i){var r,n,o,a,l,c;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(n=new yB(t),null!=i&&null!==(r=i.gltf)&&void 0!==r&&r.decompressMeshes){e.next=3;break}return e.abrupt("return");case 3:o=[],a=u(t.json.bufferViews||[]);try{for(a.s();!(l=a.n()).done;)c=l.value,o.push(OB(n,c))}catch(e){a.e(e)}finally{a.f()}return e.next=8,Promise.all(o);case 8:n.removeExtension(FB);case 9:case"end":return e.stop()}},e)}))).apply(this,arguments)}function OB(e,t){return LB.apply(this,arguments)}function LB(){return(LB=a(s().mark(function e(t,i){var r,n,o,a,l,u,c,h,A,d,p,f,g,m;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!(r=t.getObjectExtension(i,FB))){e.next=9;break}return n=r.byteOffset,o=void 0===n?0:n,a=r.byteLength,l=void 0===a?0:a,u=r.byteStride,c=r.count,h=r.mode,A=r.filter,d=void 0===A?"NONE":A,p=r.buffer,f=t.gltf.buffers[p],g=new Uint8Array(f.arrayBuffer,f.byteOffset+o,l),m=new Uint8Array(t.gltf.buffers[i.buffer].arrayBuffer,i.byteOffset,i.byteLength),e.next=8,PB(m,c,u,g,h,d);case 8:return e.abrupt("return",m);case 9:return e.abrupt("return",null);case 10:case"end":return e.stop()}},e)}))).apply(this,arguments)}var jB=Object.freeze({__proto__:null,name:DB,decode:function(e,t){return RB.apply(this,arguments)}}),UB="EXT_texture_webp",NB=UB;var VB=Object.freeze({__proto__:null,name:NB,preprocess:function(e,t){var i=new yB(e);if($x("image/webp")){var r,n=u(i.json.textures||[]);try{for(n.s();!(r=n.n()).done;){var s=r.value,o=i.getObjectExtension(s,UB);o&&(s.source=o.source),i.removeObjectExtension(s,UB)}}catch(e){n.e(e)}finally{n.f()}i.removeExtension(UB)}else if(i.getRequiredExtensions().includes(UB))throw new Error("gltf: Required extension ".concat(UB," not supported by browser"))}}),QB="KHR_texture_basisu",HB=QB;var GB=Object.freeze({__proto__:null,name:HB,preprocess:function(e,t){var i,r=new yB(e),n=u(r.json.textures||[]);try{for(n.s();!(i=n.n()).done;){var s=i.value,o=r.getObjectExtension(s,QB);o&&(s.source=o.source),r.removeObjectExtension(s,QB)}}catch(e){n.e(e)}finally{n.f()}r.removeExtension(QB)}});var zB={self:"undefined"!=typeof self&&self,window:"undefined"!=typeof window&&window,global:"undefined"!=typeof global&&global,document:"undefined"!=typeof document&&document},WB=zB.global||zB.self||zB.window||{},KB="object"!==("undefined"==typeof process?"undefined":w(process))||"[object process]"!==String(process)||process.browser,XB="function"==typeof importScripts,qB="undefined"!=typeof process&&process.version&&/v([0-9]*)/.exec(process.version);qB&&parseFloat(qB[1]);var YB=null,JB=Object.freeze({__proto__:null,readFileAsArrayBuffer:null,readFileAsText:null,requireFromFile:YB,requireFromString:null}),ZB={};function $B(e){return eP.apply(this,arguments)}function eP(){return eP=a(s().mark(function e(t){var i,r,n=arguments;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return r=n.length>2&&void 0!==n[2]?n[2]:{},(i=n.length>1&&void 0!==n[1]?n[1]:null)&&(t=tP(t,i,r)),ZB[t]=ZB[t]||iP(t),e.next=6,ZB[t];case 6:return e.abrupt("return",e.sent);case 7:case"end":return e.stop()}},e)})),eP.apply(this,arguments)}function tP(e,t,i){if(e.startsWith("http"))return e;var r=i.modules||{};return r[e]?r[e]:KB?i.CDN?(function(e,t){if(!e)throw new Error(t||"loaders.gl assertion failed.")}(i.CDN.startsWith("http")),"".concat(i.CDN,"/").concat(t,"@").concat("3.4.15","/dist/libs/").concat(e)):XB?"../src/libs/".concat(e):"modules/".concat(t,"/src/libs/").concat(e):"modules/".concat(t,"/dist/libs/").concat(e)}function iP(e){return rP.apply(this,arguments)}function rP(){return(rP=a(s().mark(function e(t){var i,r,n;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!t.endsWith("wasm")){e.next=7;break}return e.next=3,fetch(t);case 3:return i=e.sent,e.next=6,i.arrayBuffer();case 6:return e.abrupt("return",e.sent);case 7:if(KB){e.next=20;break}if(e.prev=8,e.t0=JB&&YB,!e.t0){e.next=14;break}return e.next=13,YB(t);case 13:e.t0=e.sent;case 14:return e.abrupt("return",e.t0);case 17:return e.prev=17,e.t1=e.catch(8),e.abrupt("return",null);case 20:if(!XB){e.next=22;break}return e.abrupt("return",importScripts(t));case 22:return e.next=24,fetch(t);case 24:return r=e.sent,e.next=27,r.text();case 27:return n=e.sent,e.abrupt("return",nP(n,t));case 29:case"end":return e.stop()}},e,null,[[8,17]])}))).apply(this,arguments)}function nP(e,t){if(!KB)return null;if(XB)return eval.call(WB,e),null;var i=document.createElement("script");i.id=t;try{i.appendChild(document.createTextNode(e))}catch(t){i.text=e}return document.body.appendChild(i),null}var sP={draco:{decoderType:"object"===("undefined"==typeof WebAssembly?"undefined":w(WebAssembly))?"wasm":"js",libraryPath:"libs/",extraAttributes:{},attributeNameEntry:void 0}},oP={name:"Draco",id:KB?"draco":"draco-nodejs",module:"draco",shapes:["mesh"],version:"3.4.15",worker:!0,extensions:["drc"],mimeTypes:["application/octet-stream"],binary:!0,tests:["DRACO"],options:sP};var aP=function(){function e(t,i){x(this,e),iy(this,"fields",void 0),iy(this,"metadata",void 0),function(e,t){if(!e)throw new Error(t||"loader assertion failed.")}(Array.isArray(t)),function(e){var t,i={},r=u(e);try{for(r.s();!(t=r.n()).done;){var n=t.value;i[n.name]&&console.warn("Schema: duplicated field name",n.name,n),i[n.name]=!0}}catch(e){r.e(e)}finally{r.f()}}(t),this.fields=t,this.metadata=i||new Map}return P(e,[{key:"compareTo",value:function(e){if(this.metadata!==e.metadata)return!1;if(this.fields.length!==e.fields.length)return!1;for(var t=0;t<this.fields.length;++t)if(!this.fields[t].compareTo(e.fields[t]))return!1;return!0}},{key:"select",value:function(){for(var t=Object.create(null),i=arguments.length,r=new Array(i),n=0;n<i;n++)r[n]=arguments[n];for(var s=0,o=r;s<o.length;s++){var a=o[s];t[a]=!0}return new e(this.fields.filter(function(e){return t[e.name]}),this.metadata)}},{key:"selectAt",value:function(){for(var t=this,i=arguments.length,r=new Array(i),n=0;n<i;n++)r[n]=arguments[n];return new e(r.map(function(e){return t.fields[e]}).filter(Boolean),this.metadata)}},{key:"assign",value:function(t){var i,r=this.metadata;if(t instanceof e){var n=t;i=n.fields,r=lP(lP(new Map,this.metadata),n.metadata)}else i=t;var s,o=Object.create(null),a=u(this.fields);try{for(a.s();!(s=a.n()).done;){var l=s.value;o[l.name]=l}}catch(e){a.e(e)}finally{a.f()}var c,h=u(i);try{for(h.s();!(c=h.n()).done;){var A=c.value;o[A.name]=A}}catch(e){h.e(e)}finally{h.f()}return new e(Object.values(o),r)}}])}();function lP(e,t){return new Map([].concat(l(e||new Map),l(t||new Map)))}var uP=function(){function e(t,i){x(this,e);var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2],n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:new Map;iy(this,"name",void 0),iy(this,"type",void 0),iy(this,"nullable",void 0),iy(this,"metadata",void 0),this.name=t,this.type=i,this.nullable=r,this.metadata=n}return P(e,[{key:"typeId",get:function(){return this.type&&this.type.typeId}},{key:"clone",value:function(){return new e(this.name,this.type,this.nullable,this.metadata)}},{key:"compareTo",value:function(e){return this.name===e.name&&this.type===e.type&&this.nullable===e.nullable&&this.metadata===e.metadata}},{key:"toString",value:function(){return"".concat(this.type).concat(this.nullable?", nullable":"").concat(this.metadata?", metadata: ".concat(this.metadata):"")}}])}(),cP=function(e){return e[e.NONE=0]="NONE",e[e.Null=1]="Null",e[e.Int=2]="Int",e[e.Float=3]="Float",e[e.Binary=4]="Binary",e[e.Utf8=5]="Utf8",e[e.Bool=6]="Bool",e[e.Decimal=7]="Decimal",e[e.Date=8]="Date",e[e.Time=9]="Time",e[e.Timestamp=10]="Timestamp",e[e.Interval=11]="Interval",e[e.List=12]="List",e[e.Struct=13]="Struct",e[e.Union=14]="Union",e[e.FixedSizeBinary=15]="FixedSizeBinary",e[e.FixedSizeList=16]="FixedSizeList",e[e.Map=17]="Map",e[e.Dictionary=-1]="Dictionary",e[e.Int8=-2]="Int8",e[e.Int16=-3]="Int16",e[e.Int32=-4]="Int32",e[e.Int64=-5]="Int64",e[e.Uint8=-6]="Uint8",e[e.Uint16=-7]="Uint16",e[e.Uint32=-8]="Uint32",e[e.Uint64=-9]="Uint64",e[e.Float16=-10]="Float16",e[e.Float32=-11]="Float32",e[e.Float64=-12]="Float64",e[e.DateDay=-13]="DateDay",e[e.DateMillisecond=-14]="DateMillisecond",e[e.TimestampSecond=-15]="TimestampSecond",e[e.TimestampMillisecond=-16]="TimestampMillisecond",e[e.TimestampMicrosecond=-17]="TimestampMicrosecond",e[e.TimestampNanosecond=-18]="TimestampNanosecond",e[e.TimeSecond=-19]="TimeSecond",e[e.TimeMillisecond=-20]="TimeMillisecond",e[e.TimeMicrosecond=-21]="TimeMicrosecond",e[e.TimeNanosecond=-22]="TimeNanosecond",e[e.DenseUnion=-23]="DenseUnion",e[e.SparseUnion=-24]="SparseUnion",e[e.IntervalDayTime=-25]="IntervalDayTime",e[e.IntervalYearMonth=-26]="IntervalYearMonth",e}({}),hP=function(){return P(function e(){x(this,e)},[{key:"typeId",get:function(){return cP.NONE}},{key:"compareTo",value:function(e){return this===e}}],[{key:"isNull",value:function(e){return e&&e.typeId===cP.Null}},{key:"isInt",value:function(e){return e&&e.typeId===cP.Int}},{key:"isFloat",value:function(e){return e&&e.typeId===cP.Float}},{key:"isBinary",value:function(e){return e&&e.typeId===cP.Binary}},{key:"isUtf8",value:function(e){return e&&e.typeId===cP.Utf8}},{key:"isBool",value:function(e){return e&&e.typeId===cP.Bool}},{key:"isDecimal",value:function(e){return e&&e.typeId===cP.Decimal}},{key:"isDate",value:function(e){return e&&e.typeId===cP.Date}},{key:"isTime",value:function(e){return e&&e.typeId===cP.Time}},{key:"isTimestamp",value:function(e){return e&&e.typeId===cP.Timestamp}},{key:"isInterval",value:function(e){return e&&e.typeId===cP.Interval}},{key:"isList",value:function(e){return e&&e.typeId===cP.List}},{key:"isStruct",value:function(e){return e&&e.typeId===cP.Struct}},{key:"isUnion",value:function(e){return e&&e.typeId===cP.Union}},{key:"isFixedSizeBinary",value:function(e){return e&&e.typeId===cP.FixedSizeBinary}},{key:"isFixedSizeList",value:function(e){return e&&e.typeId===cP.FixedSizeList}},{key:"isMap",value:function(e){return e&&e.typeId===cP.Map}},{key:"isDictionary",value:function(e){return e&&e.typeId===cP.Dictionary}}])}(),AP=function(e,t){function i(e,t){var r;return x(this,i),iy(r=d(this,i),"isSigned",void 0),iy(r,"bitWidth",void 0),r.isSigned=e,r.bitWidth=t,r}return _(i,hP),P(i,[{key:"typeId",get:function(){return cP.Int}},{key:t,get:function(){return"Int"}},{key:"toString",value:function(){return"".concat(this.isSigned?"I":"Ui","nt").concat(this.bitWidth)}}])}(0,Symbol.toStringTag),dP=function(){function e(){return x(this,e),d(this,e,[!0,8])}return _(e,AP),P(e)}(),pP=function(){function e(){return x(this,e),d(this,e,[!0,16])}return _(e,AP),P(e)}(),fP=function(){function e(){return x(this,e),d(this,e,[!0,32])}return _(e,AP),P(e)}(),gP=function(){function e(){return x(this,e),d(this,e,[!1,8])}return _(e,AP),P(e)}(),mP=function(){function e(){return x(this,e),d(this,e,[!1,16])}return _(e,AP),P(e)}(),vP=function(){function e(){return x(this,e),d(this,e,[!1,32])}return _(e,AP),P(e)}(),_P=32,yP=64,bP=function(e,t){function i(e){var t;return x(this,i),iy(t=d(this,i),"precision",void 0),t.precision=e,t}return _(i,hP),P(i,[{key:"typeId",get:function(){return cP.Float}},{key:t,get:function(){return"Float"}},{key:"toString",value:function(){return"Float".concat(this.precision)}}])}(0,Symbol.toStringTag),wP=function(){function e(){return x(this,e),d(this,e,[_P])}return _(e,bP),P(e)}(),xP=function(){function e(){return x(this,e),d(this,e,[yP])}return _(e,bP),P(e)}(),BP=function(e,t){function i(e,t){var r;return x(this,i),iy(r=d(this,i),"listSize",void 0),iy(r,"children",void 0),r.listSize=e,r.children=[t],r}return _(i,hP),P(i,[{key:"typeId",get:function(){return cP.FixedSizeList}},{key:"valueType",get:function(){return this.children[0].type}},{key:"valueField",get:function(){return this.children[0]}},{key:t,get:function(){return"FixedSizeList"}},{key:"toString",value:function(){return"FixedSizeList[".concat(this.listSize,"]<").concat(this.valueType,">")}}])}(0,Symbol.toStringTag);function PP(e,t,i){var r=function(e){switch(e.constructor){case Int8Array:return new dP;case Uint8Array:return new gP;case Int16Array:return new pP;case Uint16Array:return new mP;case Int32Array:return new fP;case Uint32Array:return new vP;case Float32Array:return new wP;case Float64Array:return new xP;default:throw new Error("array type not supported")}}(t.value),n=i||function(e){var t=new Map;"byteOffset"in e&&t.set("byteOffset",e.byteOffset.toString(10));"byteStride"in e&&t.set("byteStride",e.byteStride.toString(10));"normalized"in e&&t.set("normalized",e.normalized.toString());return t}(t);return new uP(e,new BP(t.size,new uP("value",r)),!1,n)}function CP(e,t,i){return PP(e,t,i?MP(i.metadata):void 0)}function MP(e){var t=new Map;for(var i in e)t.set("".concat(i,".string"),JSON.stringify(e[i]));return t}var kP={POSITION:"POSITION",NORMAL:"NORMAL",COLOR:"COLOR_0",TEX_COORD:"TEXCOORD_0"},EP={1:Int8Array,2:Uint8Array,3:Int16Array,4:Uint16Array,5:Int32Array,6:Uint32Array,9:Float32Array},SP=function(){return P(function e(t){x(this,e),iy(this,"draco",void 0),iy(this,"decoder",void 0),iy(this,"metadataQuerier",void 0),this.draco=t,this.decoder=new this.draco.Decoder,this.metadataQuerier=new this.draco.MetadataQuerier},[{key:"destroy",value:function(){this.draco.destroy(this.decoder),this.draco.destroy(this.metadataQuerier)}},{key:"parseSync",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=new this.draco.DecoderBuffer;i.Init(new Int8Array(e),e.byteLength),this._disableAttributeTransforms(t);var r=this.decoder.GetEncodedGeometryType(i),s=r===this.draco.TRIANGULAR_MESH?new this.draco.Mesh:new this.draco.PointCloud;try{var o;switch(r){case this.draco.TRIANGULAR_MESH:o=this.decoder.DecodeBufferToMesh(i,s);break;case this.draco.POINT_CLOUD:o=this.decoder.DecodeBufferToPointCloud(i,s);break;default:throw new Error("DRACO: Unknown geometry type.")}if(!o.ok()||!s.ptr){var a="DRACO decompression failed: ".concat(o.error_msg());throw new Error(a)}var l=this._getDracoLoaderData(s,r,t),u=this._getMeshData(s,l,t),c=function(e){for(var t=1/0,i=1/0,r=1/0,n=-1/0,s=-1/0,o=-1/0,a=e.POSITION?e.POSITION.value:[],l=a&&a.length,u=0;u<l;u+=3){var c=a[u],h=a[u+1],A=a[u+2];t=c<t?c:t,i=h<i?h:i,r=A<r?A:r,n=c>n?c:n,s=h>s?h:s,o=A>o?A:o}return[[t,i,r],[n,s,o]]}(u.attributes),h=function(e,t,i){var r=MP(t.metadata),n=[],s=function(e){var t={};for(var i in e){var r=e[i];t[r.name||"undefined"]=r}return t}(t.attributes);for(var o in e){var a=CP(o,e[o],s[o]);n.push(a)}if(i){var l=CP("indices",i);n.push(l)}return new aP(n,r)}(u.attributes,l,u.indices);return n(n({loader:"draco",loaderData:l,header:{vertexCount:s.num_points(),boundingBox:c}},u),{},{schema:h})}finally{this.draco.destroy(i),s&&this.draco.destroy(s)}}},{key:"_getDracoLoaderData",value:function(e,t,i){var r=this._getTopLevelMetadata(e),n=this._getDracoAttributes(e,i);return{geometry_type:t,num_attributes:e.num_attributes(),num_points:e.num_points(),num_faces:e instanceof this.draco.Mesh?e.num_faces():0,metadata:r,attributes:n}}},{key:"_getDracoAttributes",value:function(e,t){for(var i={},r=0;r<e.num_attributes();r++){var n=this.decoder.GetAttribute(e,r),s=this._getAttributeMetadata(e,r);i[n.unique_id()]={unique_id:n.unique_id(),attribute_type:n.attribute_type(),data_type:n.data_type(),num_components:n.num_components(),byte_offset:n.byte_offset(),byte_stride:n.byte_stride(),normalized:n.normalized(),attribute_index:r,metadata:s};var o=this._getQuantizationTransform(n,t);o&&(i[n.unique_id()].quantization_transform=o);var a=this._getOctahedronTransform(n,t);a&&(i[n.unique_id()].octahedron_transform=a)}return i}},{key:"_getMeshData",value:function(e,t,i){var r=this._getMeshAttributes(t,e,i);if(!r.POSITION)throw new Error("DRACO: No position attribute found.");return e instanceof this.draco.Mesh?"triangle-strip"===i.topology?{topology:"triangle-strip",mode:4,attributes:r,indices:{value:this._getTriangleStripIndices(e),size:1}}:{topology:"triangle-list",mode:5,attributes:r,indices:{value:this._getTriangleListIndices(e),size:1}}:{topology:"point-list",mode:0,attributes:r}}},{key:"_getMeshAttributes",value:function(e,t,i){for(var r={},n=0,s=Object.values(e.attributes);n<s.length;n++){var o=s[n],a=this._deduceAttributeName(o,i);o.name=a;var l=this._getAttributeValues(t,o),u=l.value,c=l.size;r[a]={value:u,size:c,byteOffset:o.byte_offset,byteStride:o.byte_stride,normalized:o.normalized}}return r}},{key:"_getTriangleListIndices",value:function(e){var t=3*e.num_faces(),i=4*t,r=this.draco._malloc(i);try{return this.decoder.GetTrianglesUInt32Array(e,i,r),new Uint32Array(this.draco.HEAPF32.buffer,r,t).slice()}finally{this.draco._free(r)}}},{key:"_getTriangleStripIndices",value:function(e){var t=new this.draco.DracoInt32Array;try{return this.decoder.GetTriangleStripsFromMesh(e,t),function(e){for(var t=e.size(),i=new Int32Array(t),r=0;r<t;r++)i[r]=e.GetValue(r);return i}(t)}finally{this.draco.destroy(t)}}},{key:"_getAttributeValues",value:function(e,t){var i,r=EP[t.data_type],n=t.num_components,s=e.num_points()*n,o=s*r.BYTES_PER_ELEMENT,a=function(e,t){switch(t){case Float32Array:return e.DT_FLOAT32;case Int8Array:return e.DT_INT8;case Int16Array:return e.DT_INT16;case Int32Array:return e.DT_INT32;case Uint8Array:return e.DT_UINT8;case Uint16Array:return e.DT_UINT16;case Uint32Array:return e.DT_UINT32;default:return e.DT_INVALID}}(this.draco,r),l=this.draco._malloc(o);try{var u=this.decoder.GetAttribute(e,t.attribute_index);this.decoder.GetAttributeDataArrayForAllPoints(e,u,a,o,l),i=new r(this.draco.HEAPF32.buffer,l,s).slice()}finally{this.draco._free(l)}return{value:i,size:n}}},{key:"_deduceAttributeName",value:function(e,t){for(var i=e.unique_id,r=0,n=Object.entries(t.extraAttributes||{});r<n.length;r++){var s=c(n[r],2),o=s[0];if(s[1]===i)return o}var a=e.attribute_type;for(var l in kP){if(this.draco[l]===a)return kP[l]}var u=t.attributeNameEntry||"name";return e.metadata[u]?e.metadata[u].string:"CUSTOM_ATTRIBUTE_".concat(i)}},{key:"_getTopLevelMetadata",value:function(e){var t=this.decoder.GetMetadata(e);return this._getDracoMetadata(t)}},{key:"_getAttributeMetadata",value:function(e,t){var i=this.decoder.GetAttributeMetadata(e,t);return this._getDracoMetadata(i)}},{key:"_getDracoMetadata",value:function(e){if(!e||!e.ptr)return{};for(var t={},i=this.metadataQuerier.NumEntries(e),r=0;r<i;r++){var n=this.metadataQuerier.GetEntryName(e,r);t[n]=this._getDracoMetadataField(e,n)}return t}},{key:"_getDracoMetadataField",value:function(e,t){var i=new this.draco.DracoInt32Array;try{this.metadataQuerier.GetIntEntryArray(e,t,i);var r=function(e){for(var t=e.size(),i=new Int32Array(t),r=0;r<t;r++)i[r]=e.GetValue(r);return i}(i);return{int:this.metadataQuerier.GetIntEntry(e,t),string:this.metadataQuerier.GetStringEntry(e,t),double:this.metadataQuerier.GetDoubleEntry(e,t),intArray:r}}finally{this.draco.destroy(i)}}},{key:"_disableAttributeTransforms",value:function(e){var t,i=e.quantizedAttributes,r=void 0===i?[]:i,n=e.octahedronAttributes,s=void 0===n?[]:n,o=u([].concat(l(r),l(s)));try{for(o.s();!(t=o.n()).done;){var a=t.value;this.decoder.SkipAttributeTransform(this.draco[a])}}catch(e){o.e(e)}finally{o.f()}}},{key:"_getQuantizationTransform",value:function(e,t){var i=this,r=t.quantizedAttributes,n=void 0===r?[]:r,s=e.attribute_type();if(n.map(function(e){return i.decoder[e]}).includes(s)){var o=new this.draco.AttributeQuantizationTransform;try{if(o.InitFromAttribute(e))return{quantization_bits:o.quantization_bits(),range:o.range(),min_values:new Float32Array([1,2,3]).map(function(e){return o.min_value(e)})}}finally{this.draco.destroy(o)}}return null}},{key:"_getOctahedronTransform",value:function(e,t){var i=this,r=t.octahedronAttributes,n=void 0===r?[]:r,s=e.attribute_type();if(n.map(function(e){return i.decoder[e]}).includes(s)){var o=new this.draco.AttributeQuantizationTransform;try{if(o.InitFromAttribute(e))return{quantization_bits:o.quantization_bits()}}finally{this.draco.destroy(o)}}return null}}])}();var TP,IP="https://www.gstatic.com/draco/versioned/decoders/".concat("1.5.5"),FP="".concat(IP,"/draco_decoder.js"),DP="".concat(IP,"/draco_wasm_wrapper.js"),RP="".concat(IP,"/draco_decoder.wasm");function OP(e){return LP.apply(this,arguments)}function LP(){return(LP=a(s().mark(function e(t){var i;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return i=t.modules||{},TP=i.draco3d?TP||i.draco3d.createDecoderModule({}).then(function(e){return{draco:e}}):TP||jP(t),e.next=4,TP;case 4:return e.abrupt("return",e.sent);case 5:case"end":return e.stop()}},e)}))).apply(this,arguments)}function jP(e){return UP.apply(this,arguments)}function UP(){return(UP=a(s().mark(function e(t){var i,r,n,o;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:e.t0=t.draco&&t.draco.decoderType,e.next="js"===e.t0?3:(e.t0,7);break;case 3:return e.next=5,$B(FP,"draco",t);case 5:return i=e.sent,e.abrupt("break",21);case 7:return e.t1=Promise,e.next=10,$B(DP,"draco",t);case 10:return e.t2=e.sent,e.next=13,$B(RP,"draco",t);case 13:return e.t3=e.sent,e.t4=[e.t2,e.t3],e.next=17,e.t1.all.call(e.t1,e.t4);case 17:n=e.sent,o=c(n,2),i=o[0],r=o[1];case 21:return i=i||globalThis.DracoDecoderModule,e.next=24,NP(i,r);case 24:return e.abrupt("return",e.sent);case 25:case"end":return e.stop()}},e)}))).apply(this,arguments)}function NP(e,t){var i={};return t&&(i.wasmBinary=t),new Promise(function(t){e(n(n({},i),{},{onModuleLoaded:function(e){return t({draco:e})}}))})}var VP=n(n({},oP),{},{parse:function(e,t){return QP.apply(this,arguments)}});function QP(){return(QP=a(s().mark(function e(t,i){var r,n,o;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,OP(i);case 2:return r=e.sent,n=r.draco,o=new SP(n),e.prev=5,e.abrupt("return",o.parseSync(t,null==i?void 0:i.draco));case 7:return e.prev=7,o.destroy(),e.finish(7);case 10:case"end":return e.stop()}},e,null,[[5,,7,10]])}))).apply(this,arguments)}function HP(e){var t={};for(var i in e){var r=e[i];if("indices"!==i){var n=GP(r);t[i]=n}}return t}function GP(e){var t=function(e){var t=e,i=1,r=0;e&&e.value&&(t=e.value,i=e.size||1);t&&(ArrayBuffer.isView(t)||(t=function(e,t){var i=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(!e)return null;if(Array.isArray(e))return new t(e);if(i&&!(e instanceof t))return new t(e);return e}(t,Float32Array)),r=t.length/i);return{buffer:t,size:i,count:r}}(e),i=t.buffer,r=t.size;return{value:i,size:r,byteOffset:0,count:t.count,type:fB(r),componentType:gB(i)}}var zP="KHR_draco_mesh_compression",WP=zP;function KP(){return(KP=a(s().mark(function e(t,i,r){var n,o,a,l,c,h;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(null!=i&&null!==(n=i.gltf)&&void 0!==n&&n.decompressMeshes){e.next=2;break}return e.abrupt("return");case 2:o=new yB(t),a=[],l=u(ZP(o));try{for(l.s();!(c=l.n()).done;)h=c.value,o.getObjectExtension(h,zP)&&a.push(XP(o,h,i,r))}catch(e){l.e(e)}finally{l.f()}return e.next=8,Promise.all(a);case 8:o.removeExtension(zP);case 9:case"end":return e.stop()}},e)}))).apply(this,arguments)}function XP(e,t,i,r){return qP.apply(this,arguments)}function qP(){return qP=a(s().mark(function e(t,i,r,o){var a,l,u,h,A,d,p,f,g,m,v,_,y,b;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(a=t.getObjectExtension(i,zP)){e.next=3;break}return e.abrupt("return");case 3:return l=t.getTypedArrayForBufferView(a.bufferView),u=rB(l.buffer,l.byteOffset),h=o.parse,delete(A=n({},r))["3d-tiles"],e.next=10,h(u,VP,A,o);case 10:for(d=e.sent,p=HP(d.attributes),f=0,g=Object.entries(p);f<g.length;f++)m=c(g[f],2),v=m[0],_=m[1],v in i.attributes&&(y=i.attributes[v],null!=(b=t.getAccessor(y))&&b.min&&null!=b&&b.max&&(_.min=b.min,_.max=b.max));i.attributes=p,d.indices&&(i.indices=GP(d.indices)),JP(i);case 16:case"end":return e.stop()}},e)})),qP.apply(this,arguments)}function YP(e,t){var i,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:4,n=arguments.length>3?arguments[3]:void 0,s=arguments.length>4?arguments[4]:void 0;if(!n.DracoWriter)throw new Error("options.gltf.DracoWriter not provided");var o=n.DracoWriter.encodeSync({attributes:e}),a=null==s||null===(i=s.parseSync)||void 0===i?void 0:i.call(s,{attributes:e}),l=n._addFauxAttributes(a.attributes),u=n.addBufferView(o);return{primitives:[{attributes:l,mode:r,extensions:b({},zP,{bufferView:u,attributes:l})}]}}function JP(e){if(!e.attributes&&Object.keys(e.attributes).length>0)throw new Error("glTF: Empty primitive detected: Draco decompression failure?")}function ZP(e){var t,r,n,o,a,l;return s().wrap(function(i){for(;;)switch(i.prev=i.next){case 0:t=u(e.json.meshes||[]),i.prev=1,t.s();case 3:if((r=t.n()).done){i.next=24;break}n=r.value,o=u(n.primitives),i.prev=6,o.s();case 8:if((a=o.n()).done){i.next=14;break}return l=a.value,i.next=12,l;case 12:i.next=8;break;case 14:i.next=19;break;case 16:i.prev=16,i.t0=i.catch(6),o.e(i.t0);case 19:return i.prev=19,o.f(),i.finish(19);case 22:i.next=3;break;case 24:i.next=29;break;case 26:i.prev=26,i.t1=i.catch(1),t.e(i.t1);case 29:return i.prev=29,t.f(),i.finish(29);case 32:case"end":return i.stop()}},i,null,[[1,26,29,32],[6,16,19,22]])}var $P=Object.freeze({__proto__:null,name:WP,preprocess:function(e,t,i){var r,n=new yB(e),s=u(ZP(n));try{for(s.s();!(r=s.n()).done;){var o=r.value;n.getObjectExtension(o,zP)}}catch(e){s.e(e)}finally{s.f()}},decode:function(e,t,i){return KP.apply(this,arguments)},encode:function(e){var t,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=new yB(e),n=u(r.json.meshes||[]);try{for(n.s();!(t=n.n()).done;){YP(t.value,i),r.addRequiredExtension(zP)}}catch(e){n.e(e)}finally{n.f()}}});function eC(e,t){if(!e)throw new Error("math.gl assertion ".concat(t))}var tC={EPSILON:1e-12,debug:!1,precision:4,printTypes:!1,printDegrees:!1,printRowMajor:!0};function iC(e){var t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).precision,i=void 0===t?tC.precision:t;return e=function(e){return Math.round(e/tC.EPSILON)*tC.EPSILON}(e),"".concat(parseFloat(e.toPrecision(i)))}function rC(e){return Array.isArray(e)||ArrayBuffer.isView(e)&&!(e instanceof DataView)}function nC(e,t,i){var r=tC.EPSILON;i&&(tC.EPSILON=i);try{if(e===t)return!0;if(rC(e)&&rC(t)){if(e.length!==t.length)return!1;for(var n=0;n<e.length;++n)if(!nC(e[n],t[n]))return!1;return!0}return e&&e.equals?e.equals(t):t&&t.equals?t.equals(e):"number"==typeof e&&"number"==typeof t&&Math.abs(e-t)<=tC.EPSILON*Math.max(1,Math.abs(e),Math.abs(t))}finally{tC.EPSILON=r}}function sC(e){function t(){var t=Reflect.construct(e,Array.from(arguments));return Object.setPrototypeOf(t,Object.getPrototypeOf(this)),t}return t.prototype=Object.create(e.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e,t}var oC=function(){function e(){return x(this,e),d(this,e,arguments)}return _(e,sC(Array)),P(e,[{key:"clone",value:function(){return(new this.constructor).copy(this)}},{key:"fromArray",value:function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=0;i<this.ELEMENTS;++i)this[i]=e[i+t];return this.check()}},{key:"toArray",value:function(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=0;i<this.ELEMENTS;++i)e[t+i]=this[i];return e}},{key:"from",value:function(e){return Array.isArray(e)?this.copy(e):this.fromObject(e)}},{key:"to",value:function(e){return e===this?this:rC(e)?this.toArray(e):this.toObject(e)}},{key:"toTarget",value:function(e){return e?this.to(e):this}},{key:"toFloat32Array",value:function(){return new Float32Array(this)}},{key:"toString",value:function(){return this.formatString(tC)}},{key:"formatString",value:function(e){for(var t="",i=0;i<this.ELEMENTS;++i)t+=(i>0?", ":"")+iC(this[i],e);return"".concat(e.printTypes?this.constructor.name:"","[").concat(t,"]")}},{key:"equals",value:function(e){if(!e||this.length!==e.length)return!1;for(var t=0;t<this.ELEMENTS;++t)if(!nC(this[t],e[t]))return!1;return!0}},{key:"exactEquals",value:function(e){if(!e||this.length!==e.length)return!1;for(var t=0;t<this.ELEMENTS;++t)if(this[t]!==e[t])return!1;return!0}},{key:"negate",value:function(){for(var e=0;e<this.ELEMENTS;++e)this[e]=-this[e];return this.check()}},{key:"lerp",value:function(e,t,i){if(void 0===i)return this.lerp(this,e,t);for(var r=0;r<this.ELEMENTS;++r){var n=e[r];this[r]=n+i*(t[r]-n)}return this.check()}},{key:"min",value:function(e){for(var t=0;t<this.ELEMENTS;++t)this[t]=Math.min(e[t],this[t]);return this.check()}},{key:"max",value:function(e){for(var t=0;t<this.ELEMENTS;++t)this[t]=Math.max(e[t],this[t]);return this.check()}},{key:"clamp",value:function(e,t){for(var i=0;i<this.ELEMENTS;++i)this[i]=Math.min(Math.max(this[i],e[i]),t[i]);return this.check()}},{key:"add",value:function(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];for(var r=0,n=t;r<n.length;r++)for(var s=n[r],o=0;o<this.ELEMENTS;++o)this[o]+=s[o];return this.check()}},{key:"subtract",value:function(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];for(var r=0,n=t;r<n.length;r++)for(var s=n[r],o=0;o<this.ELEMENTS;++o)this[o]-=s[o];return this.check()}},{key:"scale",value:function(e){if("number"==typeof e)for(var t=0;t<this.ELEMENTS;++t)this[t]*=e;else for(var i=0;i<this.ELEMENTS&&i<e.length;++i)this[i]*=e[i];return this.check()}},{key:"multiplyByScalar",value:function(e){for(var t=0;t<this.ELEMENTS;++t)this[t]*=e;return this.check()}},{key:"check",value:function(){if(tC.debug&&!this.validate())throw new Error("math.gl: ".concat(this.constructor.name," some fields set to invalid numbers'"));return this}},{key:"validate",value:function(){for(var e=this.length===this.ELEMENTS,t=0;t<this.ELEMENTS;++t)e=e&&Number.isFinite(this[t]);return e}},{key:"sub",value:function(e){return this.subtract(e)}},{key:"setScalar",value:function(e){for(var t=0;t<this.ELEMENTS;++t)this[t]=e;return this.check()}},{key:"addScalar",value:function(e){for(var t=0;t<this.ELEMENTS;++t)this[t]+=e;return this.check()}},{key:"subScalar",value:function(e){return this.addScalar(-e)}},{key:"multiplyScalar",value:function(e){for(var t=0;t<this.ELEMENTS;++t)this[t]*=e;return this.check()}},{key:"divideScalar",value:function(e){return this.multiplyByScalar(1/e)}},{key:"clampScalar",value:function(e,t){for(var i=0;i<this.ELEMENTS;++i)this[i]=Math.min(Math.max(this[i],e),t);return this.check()}},{key:"elements",get:function(){return this}}])}();function aC(e){if(!Number.isFinite(e))throw new Error("Invalid number ".concat(e));return e}function lC(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"";if(tC.debug&&!function(e,t){if(e.length!==t)return!1;for(var i=0;i<e.length;++i)if(!Number.isFinite(e[i]))return!1;return!0}(e,t))throw new Error("math.gl: ".concat(i," some fields set to invalid numbers'"));return e}var uC=function(){function e(){return x(this,e),d(this,e,arguments)}return _(e,oC),P(e,[{key:"x",get:function(){return this[0]},set:function(e){this[0]=aC(e)}},{key:"y",get:function(){return this[1]},set:function(e){this[1]=aC(e)}},{key:"len",value:function(){return Math.sqrt(this.lengthSquared())}},{key:"magnitude",value:function(){return this.len()}},{key:"lengthSquared",value:function(){for(var e=0,t=0;t<this.ELEMENTS;++t)e+=this[t]*this[t];return e}},{key:"magnitudeSquared",value:function(){return this.lengthSquared()}},{key:"distance",value:function(e){return Math.sqrt(this.distanceSquared(e))}},{key:"distanceSquared",value:function(e){for(var t=0,i=0;i<this.ELEMENTS;++i){var r=this[i]-e[i];t+=r*r}return aC(t)}},{key:"dot",value:function(e){for(var t=0,i=0;i<this.ELEMENTS;++i)t+=this[i]*e[i];return aC(t)}},{key:"normalize",value:function(){var e=this.magnitude();if(0!==e)for(var t=0;t<this.ELEMENTS;++t)this[t]/=e;return this.check()}},{key:"multiply",value:function(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];for(var r=0,n=t;r<n.length;r++)for(var s=n[r],o=0;o<this.ELEMENTS;++o)this[o]*=s[o];return this.check()}},{key:"divide",value:function(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];for(var r=0,n=t;r<n.length;r++)for(var s=n[r],o=0;o<this.ELEMENTS;++o)this[o]/=s[o];return this.check()}},{key:"lengthSq",value:function(){return this.lengthSquared()}},{key:"distanceTo",value:function(e){return this.distance(e)}},{key:"distanceToSquared",value:function(e){return this.distanceSquared(e)}},{key:"getComponent",value:function(e){return eC(e>=0&&e<this.ELEMENTS,"index is out of range"),aC(this[e])}},{key:"setComponent",value:function(e,t){return eC(e>=0&&e<this.ELEMENTS,"index is out of range"),this[e]=t,this.check()}},{key:"addVectors",value:function(e,t){return this.copy(e).add(t)}},{key:"subVectors",value:function(e,t){return this.copy(e).subtract(t)}},{key:"multiplyVectors",value:function(e,t){return this.copy(e).multiply(t)}},{key:"addScaledVector",value:function(e,t){return this.add(new this.constructor(e).multiplyScalar(t))}}])}(),cC="undefined"!=typeof Float32Array?Float32Array:Array;function hC(e,t,i){var r=t[0],n=t[1],s=t[2];return e[0]=r*i[0]+n*i[3]+s*i[6],e[1]=r*i[1]+n*i[4]+s*i[7],e[2]=r*i[2]+n*i[5]+s*i[8],e}Math.hypot||(Math.hypot=function(){for(var e=0,t=arguments.length;t--;)e+=arguments[t]*arguments[t];return Math.sqrt(e)}),function(){var e,t=(e=new cC(2),cC!=Float32Array&&(e[0]=0,e[1]=0),e)}(),function(){var e,t=(e=new cC(3),cC!=Float32Array&&(e[0]=0,e[1]=0,e[2]=0),e)}();var AC,dC,pC=[0,0,0],fC=function(){function e(){var t,i=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;return x(this,e),t=d(this,e,[-0,-0,-0]),1===arguments.length&&rC(i)?t.copy(i):(tC.debug&&(aC(i),aC(r),aC(n)),t[0]=i,t[1]=r,t[2]=n),t}return _(e,uC),P(e,[{key:"set",value:function(e,t,i){return this[0]=e,this[1]=t,this[2]=i,this.check()}},{key:"copy",value:function(e){return this[0]=e[0],this[1]=e[1],this[2]=e[2],this.check()}},{key:"fromObject",value:function(e){return tC.debug&&(aC(e.x),aC(e.y),aC(e.z)),this[0]=e.x,this[1]=e.y,this[2]=e.z,this.check()}},{key:"toObject",value:function(e){return e.x=this[0],e.y=this[1],e.z=this[2],e}},{key:"ELEMENTS",get:function(){return 3}},{key:"z",get:function(){return this[2]},set:function(e){this[2]=aC(e)}},{key:"angle",value:function(e){return function(e,t){var i=e[0],r=e[1],n=e[2],s=t[0],o=t[1],a=t[2],l=Math.sqrt(i*i+r*r+n*n)*Math.sqrt(s*s+o*o+a*a),u=l&&function(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]}(e,t)/l;return Math.acos(Math.min(Math.max(u,-1),1))}(this,e)}},{key:"cross",value:function(e){return function(e,t,i){var r=t[0],n=t[1],s=t[2],o=i[0],a=i[1],l=i[2];e[0]=n*l-s*a,e[1]=s*o-r*l,e[2]=r*a-n*o}(this,this,e),this.check()}},{key:"rotateX",value:function(e){var t=e.radians,i=e.origin;return function(e,t,i,r){var n=[],s=[];n[0]=t[0]-i[0],n[1]=t[1]-i[1],n[2]=t[2]-i[2],s[0]=n[0],s[1]=n[1]*Math.cos(r)-n[2]*Math.sin(r),s[2]=n[1]*Math.sin(r)+n[2]*Math.cos(r),e[0]=s[0]+i[0],e[1]=s[1]+i[1],e[2]=s[2]+i[2]}(this,this,void 0===i?pC:i,t),this.check()}},{key:"rotateY",value:function(e){var t=e.radians,i=e.origin;return function(e,t,i,r){var n=[],s=[];n[0]=t[0]-i[0],n[1]=t[1]-i[1],n[2]=t[2]-i[2],s[0]=n[2]*Math.sin(r)+n[0]*Math.cos(r),s[1]=n[1],s[2]=n[2]*Math.cos(r)-n[0]*Math.sin(r),e[0]=s[0]+i[0],e[1]=s[1]+i[1],e[2]=s[2]+i[2]}(this,this,void 0===i?pC:i,t),this.check()}},{key:"rotateZ",value:function(e){var t=e.radians,i=e.origin;return function(e,t,i,r){var n=[],s=[];n[0]=t[0]-i[0],n[1]=t[1]-i[1],n[2]=t[2]-i[2],s[0]=n[0]*Math.cos(r)-n[1]*Math.sin(r),s[1]=n[0]*Math.sin(r)+n[1]*Math.cos(r),s[2]=n[2],e[0]=s[0]+i[0],e[1]=s[1]+i[1],e[2]=s[2]+i[2]}(this,this,void 0===i?pC:i,t),this.check()}},{key:"transform",value:function(e){return this.transformAsPoint(e)}},{key:"transformAsPoint",value:function(e){return function(e,t,i){var r=t[0],n=t[1],s=t[2],o=i[3]*r+i[7]*n+i[11]*s+i[15];o=o||1,e[0]=(i[0]*r+i[4]*n+i[8]*s+i[12])/o,e[1]=(i[1]*r+i[5]*n+i[9]*s+i[13])/o,e[2]=(i[2]*r+i[6]*n+i[10]*s+i[14])/o}(this,this,e),this.check()}},{key:"transformAsVector",value:function(e){return function(e,t,i){var r=t[0],n=t[1],s=t[2],o=i[3]*r+i[7]*n+i[11]*s||1;e[0]=(i[0]*r+i[4]*n+i[8]*s)/o,e[1]=(i[1]*r+i[5]*n+i[9]*s)/o,e[2]=(i[2]*r+i[6]*n+i[10]*s)/o}(this,this,e),this.check()}},{key:"transformByMatrix3",value:function(e){return hC(this,this,e),this.check()}},{key:"transformByMatrix2",value:function(e){return function(e,t,i){var r=t[0],n=t[1];e[0]=i[0]*r+i[2]*n,e[1]=i[1]*r+i[3]*n,e[2]=t[2]}(this,this,e),this.check()}},{key:"transformByQuaternion",value:function(e){return function(e,t,i){var r=i[0],n=i[1],s=i[2],o=i[3],a=t[0],l=t[1],u=t[2],c=n*u-s*l,h=s*a-r*u,A=r*l-n*a,d=n*A-s*h,p=s*c-r*A,f=r*h-n*c,g=2*o;c*=g,h*=g,A*=g,d*=2,p*=2,f*=2,e[0]=a+c+d,e[1]=l+h+p,e[2]=u+A+f}(this,this,e),this.check()}}],[{key:"ZERO",get:function(){return AC||(AC=new e(0,0,0),Object.freeze(AC)),AC}}])}(),gC=function(){function e(){return x(this,e),d(this,e,arguments)}return _(e,oC),P(e,[{key:"toString",value:function(){var e="[";if(tC.printRowMajor){e+="row-major:";for(var t=0;t<this.RANK;++t)for(var i=0;i<this.RANK;++i)e+=" ".concat(this[i*this.RANK+t])}else{e+="column-major:";for(var r=0;r<this.ELEMENTS;++r)e+=" ".concat(this[r])}return e+="]"}},{key:"getElementIndex",value:function(e,t){return t*this.RANK+e}},{key:"getElement",value:function(e,t){return this[t*this.RANK+e]}},{key:"setElement",value:function(e,t,i){return this[t*this.RANK+e]=aC(i),this}},{key:"getColumn",value:function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:new Array(this.RANK).fill(-0),i=e*this.RANK,r=0;r<this.RANK;++r)t[r]=this[i+r];return t}},{key:"setColumn",value:function(e,t){for(var i=e*this.RANK,r=0;r<this.RANK;++r)this[i+r]=t[r];return this}}])}();function mC(e,t,i){var r=t[0],n=t[1],s=t[2],o=t[3],a=t[4],l=t[5],u=t[6],c=t[7],h=t[8],A=i[0],d=i[1],p=i[2],f=i[3],g=i[4],m=i[5],v=i[6],_=i[7],y=i[8];return e[0]=A*r+d*o+p*u,e[1]=A*n+d*a+p*c,e[2]=A*s+d*l+p*h,e[3]=f*r+g*o+m*u,e[4]=f*n+g*a+m*c,e[5]=f*s+g*l+m*h,e[6]=v*r+_*o+y*u,e[7]=v*n+_*a+y*c,e[8]=v*s+_*l+y*h,e}function vC(e,t,i){var r=i[0],n=i[1];return e[0]=r*t[0],e[1]=r*t[1],e[2]=r*t[2],e[3]=n*t[3],e[4]=n*t[4],e[5]=n*t[5],e[6]=t[6],e[7]=t[7],e[8]=t[8],e}!function(e){e[e.COL0ROW0=0]="COL0ROW0",e[e.COL0ROW1=1]="COL0ROW1",e[e.COL0ROW2=2]="COL0ROW2",e[e.COL1ROW0=3]="COL1ROW0",e[e.COL1ROW1=4]="COL1ROW1",e[e.COL1ROW2=5]="COL1ROW2",e[e.COL2ROW0=6]="COL2ROW0",e[e.COL2ROW1=7]="COL2ROW1",e[e.COL2ROW2=8]="COL2ROW2"}(dC||(dC={}));var _C,yC,bC=Object.freeze([1,0,0,0,1,0,0,0,1]),wC=function(){function e(t){for(var i,r=arguments.length,n=new Array(r>1?r-1:0),s=1;s<r;s++)n[s-1]=arguments[s];return x(this,e),i=d(this,e,[-0,-0,-0,-0,-0,-0,-0,-0,-0]),1===arguments.length&&Array.isArray(t)?i.copy(t):n.length>0?i.copy([t].concat(n)):i.identity(),i}return _(e,gC),P(e,[{key:"ELEMENTS",get:function(){return 9}},{key:"RANK",get:function(){return 3}},{key:"INDICES",get:function(){return dC}},{key:"copy",value:function(e){return this[0]=e[0],this[1]=e[1],this[2]=e[2],this[3]=e[3],this[4]=e[4],this[5]=e[5],this[6]=e[6],this[7]=e[7],this[8]=e[8],this.check()}},{key:"identity",value:function(){return this.copy(bC)}},{key:"fromObject",value:function(e){return this.check()}},{key:"fromQuaternion",value:function(e){return function(e,t){var i=t[0],r=t[1],n=t[2],s=t[3],o=i+i,a=r+r,l=n+n,u=i*o,c=r*o,h=r*a,A=n*o,d=n*a,p=n*l,f=s*o,g=s*a,m=s*l;e[0]=1-h-p,e[3]=c-m,e[6]=A+g,e[1]=c+m,e[4]=1-u-p,e[7]=d-f,e[2]=A-g,e[5]=d+f,e[8]=1-u-h}(this,e),this.check()}},{key:"set",value:function(e,t,i,r,n,s,o,a,l){return this[0]=e,this[1]=t,this[2]=i,this[3]=r,this[4]=n,this[5]=s,this[6]=o,this[7]=a,this[8]=l,this.check()}},{key:"setRowMajor",value:function(e,t,i,r,n,s,o,a,l){return this[0]=e,this[1]=r,this[2]=o,this[3]=t,this[4]=n,this[5]=a,this[6]=i,this[7]=s,this[8]=l,this.check()}},{key:"determinant",value:function(){return function(e){var t=e[0],i=e[1],r=e[2],n=e[3],s=e[4],o=e[5],a=e[6],l=e[7],u=e[8];return t*(u*s-o*l)+i*(-u*n+o*a)+r*(l*n-s*a)}(this)}},{key:"transpose",value:function(){return function(e,t){if(e===t){var i=t[1],r=t[2],n=t[5];e[1]=t[3],e[2]=t[6],e[3]=i,e[5]=t[7],e[6]=r,e[7]=n}else e[0]=t[0],e[1]=t[3],e[2]=t[6],e[3]=t[1],e[4]=t[4],e[5]=t[7],e[6]=t[2],e[7]=t[5],e[8]=t[8]}(this,this),this.check()}},{key:"invert",value:function(){return function(e,t){var i=t[0],r=t[1],n=t[2],s=t[3],o=t[4],a=t[5],l=t[6],u=t[7],c=t[8],h=c*o-a*u,A=-c*s+a*l,d=u*s-o*l,p=i*h+r*A+n*d;p&&(p=1/p,e[0]=h*p,e[1]=(-c*r+n*u)*p,e[2]=(a*r-n*o)*p,e[3]=A*p,e[4]=(c*i-n*l)*p,e[5]=(-a*i+n*s)*p,e[6]=d*p,e[7]=(-u*i+r*l)*p,e[8]=(o*i-r*s)*p)}(this,this),this.check()}},{key:"multiplyLeft",value:function(e){return mC(this,e,this),this.check()}},{key:"multiplyRight",value:function(e){return mC(this,this,e),this.check()}},{key:"rotate",value:function(e){return function(e,t,i){var r=t[0],n=t[1],s=t[2],o=t[3],a=t[4],l=t[5],u=t[6],c=t[7],h=t[8],A=Math.sin(i),d=Math.cos(i);e[0]=d*r+A*o,e[1]=d*n+A*a,e[2]=d*s+A*l,e[3]=d*o-A*r,e[4]=d*a-A*n,e[5]=d*l-A*s,e[6]=u,e[7]=c,e[8]=h}(this,this,e),this.check()}},{key:"scale",value:function(e){return Array.isArray(e)?vC(this,this,e):vC(this,this,[e,e]),this.check()}},{key:"translate",value:function(e){return function(e,t,i){var r=t[0],n=t[1],s=t[2],o=t[3],a=t[4],l=t[5],u=t[6],c=t[7],h=t[8],A=i[0],d=i[1];e[0]=r,e[1]=n,e[2]=s,e[3]=o,e[4]=a,e[5]=l,e[6]=A*r+d*o+u,e[7]=A*n+d*a+c,e[8]=A*s+d*l+h}(this,this,e),this.check()}},{key:"transform",value:function(e,t){var i;switch(e.length){case 2:i=function(e,t,i){var r=t[0],n=t[1];return e[0]=i[0]*r+i[3]*n+i[6],e[1]=i[1]*r+i[4]*n+i[7],e}(t||[-0,-0],e,this);break;case 3:i=hC(t||[-0,-0,-0],e,this);break;case 4:i=function(e,t,i){var r=t[0],n=t[1],s=t[2];return e[0]=i[0]*r+i[3]*n+i[6]*s,e[1]=i[1]*r+i[4]*n+i[7]*s,e[2]=i[2]*r+i[5]*n+i[8]*s,e[3]=t[3],e}(t||[-0,-0,-0,-0],e,this);break;default:throw new Error("Illegal vector")}return lC(i,e.length),i}},{key:"transformVector",value:function(e,t){return this.transform(e,t)}},{key:"transformVector2",value:function(e,t){return this.transform(e,t)}},{key:"transformVector3",value:function(e,t){return this.transform(e,t)}}],[{key:"IDENTITY",get:function(){return BC()}},{key:"ZERO",get:function(){return xC()}}])}();function xC(){return _C||(_C=new wC([0,0,0,0,0,0,0,0,0]),Object.freeze(_C)),_C}function BC(){return yC||(yC=new wC,Object.freeze(yC)),yC}var PC={SCALAR:1,VEC2:2,VEC3:3,VEC4:4,MAT2:4,MAT3:9,MAT4:16},CC={5120:1,5121:1,5122:2,5123:2,5125:4,5126:4},MC="KHR_texture_transform",kC=MC,EC=new fC,SC=new wC,TC=new wC;function IC(){return(IC=a(s().mark(function e(t,i){var r,n,o;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(r=new yB(t),r.getExtension(MC)){e.next=4;break}return e.abrupt("return");case 4:for(n=t.json.materials||[],o=0;o<n.length;o++)FC(o,t);case 6:case"end":return e.stop()}},e)}))).apply(this,arguments)}function FC(e,t){var i,r,n,s=[],o=null===(i=t.json.materials)||void 0===i?void 0:i[e],a=null==o||null===(r=o.pbrMetallicRoughness)||void 0===r?void 0:r.baseColorTexture;a&&DC(t,e,a,s);var l=null==o?void 0:o.emissiveTexture;l&&DC(t,e,l,s);var u=null==o?void 0:o.normalTexture;u&&DC(t,e,u,s);var c=null==o?void 0:o.occlusionTexture;c&&DC(t,e,c,s);var h=null==o||null===(n=o.pbrMetallicRoughness)||void 0===n?void 0:n.metallicRoughnessTexture;h&&DC(t,e,h,s)}function DC(e,t,i,r){var n=function(e,t){var i,r=null===(i=e.extensions)||void 0===i?void 0:i[MC],n=e.texCoord,s=void 0===n?0:n,o=r.texCoord,a=void 0===o?s:o,l=-1!==t.findIndex(function(e){var t=c(e,2),i=t[0],r=t[1];return i===s&&r===a});if(!l){var u=function(e){var t=e.offset,i=void 0===t?[0,0]:t,r=e.rotation,n=void 0===r?0:r,s=e.scale,o=void 0===s?[1,1]:s,a=(new wC).set(1,0,0,0,1,0,i[0],i[1],1),l=SC.set(Math.cos(n),Math.sin(n),0,-Math.sin(n),Math.cos(n),0,0,0,1),u=TC.set(o[0],0,0,0,o[1],0,0,0,1);return a.multiplyRight(l).multiplyRight(u)}(r);return s!==a&&(e.texCoord=a),t.push([s,a]),{originalTexCoord:s,texCoord:a,matrix:u}}return null}(i,r);if(n){var s,o=u(e.json.meshes||[]);try{for(o.s();!(s=o.n()).done;){var a,l=u(s.value.primitives);try{for(l.s();!(a=l.n()).done;){var h=a.value,A=h.material;Number.isFinite(A)&&t===A&&RC(e,h,n)}}catch(e){l.e(e)}finally{l.f()}}}catch(e){o.e(e)}finally{o.f()}}}function RC(e,t,i){var r=i.originalTexCoord,n=i.texCoord,s=i.matrix,o=t.attributes["TEXCOORD_".concat(r)];if(Number.isFinite(o)){var a,l=null===(a=e.json.accessors)||void 0===a?void 0:a[o];if(l&&l.bufferView){var u,c=null===(u=e.json.bufferViews)||void 0===u?void 0:u[l.bufferView];if(c){for(var h=e.buffers[c.buffer],A=h.arrayBuffer,d=(h.byteOffset||0)+(l.byteOffset||0)+(c.byteOffset||0),p=mB(l,c),f=p.ArrayType,g=p.length,m=CC[l.componentType],v=PC[l.type],_=c.byteStride||m*v,y=new Float32Array(g),b=0;b<l.count;b++){var w=new f(A,d+b*_,2);EC.set(w[0],w[1],1),EC.transformByMatrix3(s),y.set([EC[0],EC[1]],b*v)}r===n?function(e,t,i,r){e.componentType=5126,i.push({arrayBuffer:r.buffer,byteOffset:0,byteLength:r.buffer.byteLength}),t.buffer=i.length-1,t.byteLength=r.buffer.byteLength,t.byteOffset=0,delete t.byteStride}(l,c,e.buffers,y):function(e,t,i,r,n){r.buffers.push({arrayBuffer:n.buffer,byteOffset:0,byteLength:n.buffer.byteLength});var s=r.json.bufferViews;if(!s)return;s.push({buffer:r.buffers.length-1,byteLength:n.buffer.byteLength,byteOffset:0});var o=r.json.accessors;if(!o)return;o.push({bufferView:(null==s?void 0:s.length)-1,byteOffset:0,componentType:5126,count:t.count,type:"VEC2"}),i.attributes["TEXCOORD_".concat(e)]=o.length-1}(n,l,t,e,y)}}}}var OC=Object.freeze({__proto__:null,name:kC,decode:function(e,t){return IC.apply(this,arguments)}}),LC="KHR_lights_punctual",jC=LC;function UC(){return(UC=a(s().mark(function e(t){var i,r,n,o,a,l,c;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:i=new yB(t),r=i.json,(n=i.getExtension(LC))&&(i.json.lights=n.lights,i.removeExtension(LC)),o=u(r.nodes||[]);try{for(o.s();!(a=o.n()).done;)l=a.value,(c=i.getObjectExtension(l,LC))&&(l.light=c.light),i.removeObjectExtension(l,LC)}catch(e){o.e(e)}finally{o.f()}case 6:case"end":return e.stop()}},e)}))).apply(this,arguments)}function NC(){return(NC=a(s().mark(function e(t){var i,r,n,o,a,l,c;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(i=new yB(t),(r=i.json).lights&&(oB(!(n=i.addExtension(LC)).lights),n.lights=r.lights,delete r.lights),i.json.lights){o=u(i.json.lights);try{for(o.s();!(a=o.n()).done;)l=a.value,c=l.node,i.addObjectExtension(c,LC,l)}catch(e){o.e(e)}finally{o.f()}delete i.json.lights}case 4:case"end":return e.stop()}},e)}))).apply(this,arguments)}var VC="KHR_materials_unlit",QC=VC;function HC(){return(HC=a(s().mark(function e(t){var i,r,n,o,a;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:i=new yB(t),r=i.json,n=u(r.materials||[]);try{for(n.s();!(o=n.n()).done;)a=o.value,a.extensions&&a.extensions.KHR_materials_unlit&&(a.unlit=!0),i.removeObjectExtension(a,VC)}catch(e){n.e(e)}finally{n.f()}i.removeExtension(VC);case 5:case"end":return e.stop()}},e)}))).apply(this,arguments)}var GC="KHR_techniques_webgl",zC=GC;function WC(){return(WC=a(s().mark(function e(t){var i,r,n,o,a,l,c,h;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(i=new yB(t),r=i.json,n=i.getExtension(GC)){o=XC(n,i),a=u(r.materials||[]);try{for(a.s();!(l=a.n()).done;)c=l.value,(h=i.getObjectExtension(c,GC))&&(c.technique=Object.assign({},h,o[h.technique]),c.technique.values=qC(c.technique,i)),i.removeObjectExtension(c,GC)}catch(e){a.e(e)}finally{a.f()}i.removeExtension(GC)}case 4:case"end":return e.stop()}},e)}))).apply(this,arguments)}function KC(){return(KC=a(s().mark(function e(t,i){return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:case"end":return e.stop()}},e)}))).apply(this,arguments)}function XC(e,t){var i=e.programs,r=void 0===i?[]:i,n=e.shaders,s=void 0===n?[]:n,o=e.techniques,a=void 0===o?[]:o,l=new TextDecoder;return s.forEach(function(e){if(!Number.isFinite(e.bufferView))throw new Error("KHR_techniques_webgl: no shader code");e.code=l.decode(t.getTypedArrayForBufferView(e.bufferView))}),r.forEach(function(e){e.fragmentShader=s[e.fragmentShader],e.vertexShader=s[e.vertexShader]}),a.forEach(function(e){e.program=r[e.program]}),a}function qC(e,t){var i=Object.assign({},e.values);return Object.keys(e.uniforms||{}).forEach(function(t){e.uniforms[t].value&&!(t in i)&&(i[t]=e.uniforms[t].value)}),Object.keys(i).forEach(function(e){"object"===w(i[e])&&void 0!==i[e].index&&(i[e].texture=t.getTexture(i[e].index))}),i}var YC="EXT_feature_metadata",JC=YC;function ZC(){return(ZC=a(s().mark(function e(t){return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:$C(new yB(t));case 2:case"end":return e.stop()}},e)}))).apply(this,arguments)}function $C(e){var t,i=e.getExtension(YC),r=null==i||null===(t=i.schema)||void 0===t?void 0:t.classes,n=null==i?void 0:i.featureTables;if((null==i?void 0:i.featureTextures)&&console.warn('featureTextures is not yet supported in the "EXT_feature_metadata" extension.'),r&&n)for(var s in r){var o=r[s],a=iM(n,s);a&&eM(e,a,o)}}function eM(e,t,i){for(var r in i.properties){var n,s=i.properties[r],o=null==t||null===(n=t.properties)||void 0===n?void 0:n[r],a=t.count;if(o){var l=tM(e,s,a,o);o.data=l}}}function tM(e,t,i,r){var n=r.bufferView,s=e.getTypedArrayForBufferView(n);if("STRING"===t.type){var o=r.stringOffsetBufferView;s=function(e,t,i){for(var r=[],n=new TextDecoder("utf8"),s=0,o=4,a=0;a<i;a++){var l=t[(a+1)*o]-t[a*o],u=e.subarray(s,l+s),c=n.decode(u);r.push(c),s+=l}return r}(s,e.getTypedArrayForBufferView(o),i)}return s}function iM(e,t){for(var i in e){var r=e[i];if(r.class===t)return r}return null}var rM=[jB,VB,GB,$P,Object.freeze({__proto__:null,name:jC,decode:function(e){return UC.apply(this,arguments)},encode:function(e){return NC.apply(this,arguments)}}),Object.freeze({__proto__:null,name:QC,decode:function(e){return HC.apply(this,arguments)},encode:function(e){var t=new yB(e),i=t.json;if(t.materials){var r,n=u(i.materials||[]);try{for(n.s();!(r=n.n()).done;){var s=r.value;s.unlit&&(delete s.unlit,t.addObjectExtension(s,VC,{}),t.addExtension(VC))}}catch(e){n.e(e)}finally{n.f()}}}}),Object.freeze({__proto__:null,name:zC,decode:function(e){return WC.apply(this,arguments)},encode:function(e,t){return KC.apply(this,arguments)}}),OC,Object.freeze({__proto__:null,name:JC,decode:function(e){return ZC.apply(this,arguments)}})];function nM(e){var t,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2?arguments[2]:void 0,n=rM.filter(function(e){return aM(e.name,i)}),s=u(n);try{for(s.s();!(t=s.n()).done;){var o,a=t.value;null===(o=a.preprocess)||void 0===o||o.call(a,e,i,r)}}catch(e){s.e(e)}finally{s.f()}}function sM(e){return oM.apply(this,arguments)}function oM(){return oM=a(s().mark(function e(t){var i,r,n,o,a,l,c,h=arguments;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:i=h.length>1&&void 0!==h[1]?h[1]:{},r=h.length>2?h[2]:void 0,n=rM.filter(function(e){return aM(e.name,i)}),o=u(n),e.prev=4,o.s();case 6:if((a=o.n()).done){e.next=12;break}return l=a.value,e.next=10,null===(c=l.decode)||void 0===c?void 0:c.call(l,t,i,r);case 10:e.next=6;break;case 12:e.next=17;break;case 14:e.prev=14,e.t0=e.catch(4),o.e(e.t0);case 17:return e.prev=17,o.f(),e.finish(17);case 20:case"end":return e.stop()}},e,null,[[4,14,17,20]])})),oM.apply(this,arguments)}function aM(e,t){var i,r=(null==t||null===(i=t.gltf)||void 0===i?void 0:i.excludeExtensions)||{};return!(e in r&&!r[e])}var lM="KHR_binary_glTF";var uM={accessors:"accessor",animations:"animation",buffers:"buffer",bufferViews:"bufferView",images:"image",materials:"material",meshes:"mesh",nodes:"node",samplers:"sampler",scenes:"scene",skins:"skin",textures:"texture"},cM={accessor:"accessors",animations:"animation",buffer:"buffers",bufferView:"bufferViews",image:"images",material:"materials",mesh:"meshes",node:"nodes",sampler:"samplers",scene:"scenes",skin:"skins",texture:"textures"},hM=function(){return P(function e(){x(this,e),iy(this,"idToIndexMap",{animations:{},accessors:{},buffers:{},bufferViews:{},images:{},materials:{},meshes:{},nodes:{},samplers:{},scenes:{},skins:{},textures:{}}),iy(this,"json",void 0)},[{key:"normalize",value:function(e,t){this.json=e.json;var i=e.json;switch(i.asset&&i.asset.version){case"2.0":return;case void 0:case"1.0":break;default:return void console.warn("glTF: Unknown version ".concat(i.asset.version))}if(!t.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(i),this._convertTopLevelObjectsToArrays(i),function(e){var t,i=new yB(e),r=i.json,n=u(r.images||[]);try{for(n.s();!(t=n.n()).done;){var s=t.value,o=i.getObjectExtension(s,lM);o&&Object.assign(s,o),i.removeObjectExtension(s,lM)}}catch(e){n.e(e)}finally{n.f()}r.buffers&&r.buffers[0]&&delete r.buffers[0].uri,i.removeExtension(lM)}(e),this._convertObjectIdsToArrayIndices(i),this._updateObjects(i),this._updateMaterial(i)}},{key:"_addAsset",value:function(e){e.asset=e.asset||{},e.asset.version="2.0",e.asset.generator=e.asset.generator||"Normalized to glTF 2.0 by loaders.gl"}},{key:"_convertTopLevelObjectsToArrays",value:function(e){for(var t in uM)this._convertTopLevelObjectToArray(e,t)}},{key:"_convertTopLevelObjectToArray",value:function(e,t){var i=e[t];if(i&&!Array.isArray(i))for(var r in e[t]=[],i){var n=i[r];n.id=n.id||r;var s=e[t].length;e[t].push(n),this.idToIndexMap[t][r]=s}}},{key:"_convertObjectIdsToArrayIndices",value:function(e){for(var t in uM)this._convertIdsToIndices(e,t);"scene"in e&&(e.scene=this._convertIdToIndex(e.scene,"scene"));var i,r=u(e.textures);try{for(r.s();!(i=r.n()).done;){var n=i.value;this._convertTextureIds(n)}}catch(e){r.e(e)}finally{r.f()}var s,o=u(e.meshes);try{for(o.s();!(s=o.n()).done;){var a=s.value;this._convertMeshIds(a)}}catch(e){o.e(e)}finally{o.f()}var l,c=u(e.nodes);try{for(c.s();!(l=c.n()).done;){var h=l.value;this._convertNodeIds(h)}}catch(e){c.e(e)}finally{c.f()}var A,d=u(e.scenes);try{for(d.s();!(A=d.n()).done;){var p=A.value;this._convertSceneIds(p)}}catch(e){d.e(e)}finally{d.f()}}},{key:"_convertTextureIds",value:function(e){e.source&&(e.source=this._convertIdToIndex(e.source,"image"))}},{key:"_convertMeshIds",value:function(e){var t,i=u(e.primitives);try{for(i.s();!(t=i.n()).done;){var r=t.value,n=r.attributes,s=r.indices,o=r.material;for(var a in n)n[a]=this._convertIdToIndex(n[a],"accessor");s&&(r.indices=this._convertIdToIndex(s,"accessor")),o&&(r.material=this._convertIdToIndex(o,"material"))}}catch(e){i.e(e)}finally{i.f()}}},{key:"_convertNodeIds",value:function(e){var t=this;e.children&&(e.children=e.children.map(function(e){return t._convertIdToIndex(e,"node")})),e.meshes&&(e.meshes=e.meshes.map(function(e){return t._convertIdToIndex(e,"mesh")}))}},{key:"_convertSceneIds",value:function(e){var t=this;e.nodes&&(e.nodes=e.nodes.map(function(e){return t._convertIdToIndex(e,"node")}))}},{key:"_convertIdsToIndices",value:function(e,t){e[t]||(console.warn("gltf v1: json doesn't contain attribute ".concat(t)),e[t]=[]);var i,r=u(e[t]);try{for(r.s();!(i=r.n()).done;){var n=i.value;for(var s in n){var o=n[s],a=this._convertIdToIndex(o,s);n[s]=a}}}catch(e){r.e(e)}finally{r.f()}}},{key:"_convertIdToIndex",value:function(e,t){var i=cM[t];if(i in this.idToIndexMap){var r=this.idToIndexMap[i][e];if(!Number.isFinite(r))throw new Error("gltf v1: failed to resolve ".concat(t," with id ").concat(e));return r}return e}},{key:"_updateObjects",value:function(e){var t,i=u(this.json.buffers);try{for(i.s();!(t=i.n()).done;){delete t.value.type}}catch(e){i.e(e)}finally{i.f()}}},{key:"_updateMaterial",value:function(e){var t,i=u(e.materials);try{var r,n,s,o=function(){var i=t.value;i.pbrMetallicRoughness={baseColorFactor:[1,1,1,1],metallicFactor:1,roughnessFactor:1};var o=(null===(r=i.values)||void 0===r?void 0:r.tex)||(null===(n=i.values)||void 0===n?void 0:n.texture2d_0)||(null===(s=i.values)||void 0===s?void 0:s.diffuseTex),a=e.textures.findIndex(function(e){return e.id===o});-1!==a&&(i.pbrMetallicRoughness.baseColorTexture={index:a})};for(i.s();!(t=i.n()).done;)o()}catch(e){i.e(e)}finally{i.f()}}}])}();function AM(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return(new hM).normalize(e,t)}var dM={SCALAR:1,VEC2:2,VEC3:3,VEC4:4,MAT2:4,MAT3:9,MAT4:16},pM={5120:1,5121:1,5122:2,5123:2,5125:4,5126:4},fM=10240,gM=10241,mM=10242,vM=10243,_M=10497,yM=9986,bM={magFilter:fM,minFilter:gM,wrapS:mM,wrapT:vM},wM=b(b(b(b({},fM,9729),gM,yM),mM,_M),vM,_M);var xM=function(){return P(function e(){x(this,e),iy(this,"baseUri",""),iy(this,"json",{}),iy(this,"buffers",[]),iy(this,"images",[])},[{key:"postProcess",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=e.json,r=e.buffers,n=void 0===r?[]:r,s=e.images,o=void 0===s?[]:s,a=e.baseUri,l=void 0===a?"":a;return oB(i),this.baseUri=l,this.json=i,this.buffers=n,this.images=o,this._resolveTree(this.json,t),this.json}},{key:"_resolveTree",value:function(e){var t=this;e.bufferViews&&(e.bufferViews=e.bufferViews.map(function(e,i){return t._resolveBufferView(e,i)})),e.images&&(e.images=e.images.map(function(e,i){return t._resolveImage(e,i)})),e.samplers&&(e.samplers=e.samplers.map(function(e,i){return t._resolveSampler(e,i)})),e.textures&&(e.textures=e.textures.map(function(e,i){return t._resolveTexture(e,i)})),e.accessors&&(e.accessors=e.accessors.map(function(e,i){return t._resolveAccessor(e,i)})),e.materials&&(e.materials=e.materials.map(function(e,i){return t._resolveMaterial(e,i)})),e.meshes&&(e.meshes=e.meshes.map(function(e,i){return t._resolveMesh(e,i)})),e.nodes&&(e.nodes=e.nodes.map(function(e,i){return t._resolveNode(e,i)})),e.skins&&(e.skins=e.skins.map(function(e,i){return t._resolveSkin(e,i)})),e.scenes&&(e.scenes=e.scenes.map(function(e,i){return t._resolveScene(e,i)})),void 0!==e.scene&&(e.scene=e.scenes[this.json.scene])}},{key:"getScene",value:function(e){return this._get("scenes",e)}},{key:"getNode",value:function(e){return this._get("nodes",e)}},{key:"getSkin",value:function(e){return this._get("skins",e)}},{key:"getMesh",value:function(e){return this._get("meshes",e)}},{key:"getMaterial",value:function(e){return this._get("materials",e)}},{key:"getAccessor",value:function(e){return this._get("accessors",e)}},{key:"getCamera",value:function(e){return null}},{key:"getTexture",value:function(e){return this._get("textures",e)}},{key:"getSampler",value:function(e){return this._get("samplers",e)}},{key:"getImage",value:function(e){return this._get("images",e)}},{key:"getBufferView",value:function(e){return this._get("bufferViews",e)}},{key:"getBuffer",value:function(e){return this._get("buffers",e)}},{key:"_get",value:function(e,t){if("object"===w(t))return t;var i=this.json[e]&&this.json[e][t];return i||console.warn("glTF file error: Could not find ".concat(e,"[").concat(t,"]")),i}},{key:"_resolveScene",value:function(e,t){var i=this;return e.id=e.id||"scene-".concat(t),e.nodes=(e.nodes||[]).map(function(e){return i.getNode(e)}),e}},{key:"_resolveNode",value:function(e,t){var i=this;return e.id=e.id||"node-".concat(t),e.children&&(e.children=e.children.map(function(e){return i.getNode(e)})),void 0!==e.mesh?e.mesh=this.getMesh(e.mesh):void 0!==e.meshes&&e.meshes.length&&(e.mesh=e.meshes.reduce(function(e,t){var r=i.getMesh(t);return e.id=r.id,e.primitives=e.primitives.concat(r.primitives),e},{primitives:[]})),void 0!==e.camera&&(e.camera=this.getCamera(e.camera)),void 0!==e.skin&&(e.skin=this.getSkin(e.skin)),e}},{key:"_resolveSkin",value:function(e,t){return e.id=e.id||"skin-".concat(t),e.inverseBindMatrices=this.getAccessor(e.inverseBindMatrices),e}},{key:"_resolveMesh",value:function(e,t){var i=this;return e.id=e.id||"mesh-".concat(t),e.primitives&&(e.primitives=e.primitives.map(function(e){var t=(e=n({},e)).attributes;for(var r in e.attributes={},t)e.attributes[r]=i.getAccessor(t[r]);return void 0!==e.indices&&(e.indices=i.getAccessor(e.indices)),void 0!==e.material&&(e.material=i.getMaterial(e.material)),e})),e}},{key:"_resolveMaterial",value:function(e,t){if(e.id=e.id||"material-".concat(t),e.normalTexture&&(e.normalTexture=n({},e.normalTexture),e.normalTexture.texture=this.getTexture(e.normalTexture.index)),e.occlusionTexture&&(e.occlustionTexture=n({},e.occlustionTexture),e.occlusionTexture.texture=this.getTexture(e.occlusionTexture.index)),e.emissiveTexture&&(e.emmisiveTexture=n({},e.emmisiveTexture),e.emissiveTexture.texture=this.getTexture(e.emissiveTexture.index)),e.emissiveFactor||(e.emissiveFactor=e.emmisiveTexture?[1,1,1]:[0,0,0]),e.pbrMetallicRoughness){e.pbrMetallicRoughness=n({},e.pbrMetallicRoughness);var i=e.pbrMetallicRoughness;i.baseColorTexture&&(i.baseColorTexture=n({},i.baseColorTexture),i.baseColorTexture.texture=this.getTexture(i.baseColorTexture.index)),i.metallicRoughnessTexture&&(i.metallicRoughnessTexture=n({},i.metallicRoughnessTexture),i.metallicRoughnessTexture.texture=this.getTexture(i.metallicRoughnessTexture.index))}return e}},{key:"_resolveAccessor",value:function(e,t){var i,r;if(e.id=e.id||"accessor-".concat(t),void 0!==e.bufferView&&(e.bufferView=this.getBufferView(e.bufferView)),e.bytesPerComponent=(i=e.componentType,pM[i]),e.components=(r=e.type,dM[r]),e.bytesPerElement=e.bytesPerComponent*e.components,e.bufferView){var n=e.bufferView.buffer,s=mB(e,e.bufferView),o=s.ArrayType,a=s.byteLength,l=(e.bufferView.byteOffset||0)+(e.byteOffset||0)+n.byteOffset,u=n.arrayBuffer.slice(l,l+a);e.bufferView.byteStride&&(u=this._getValueFromInterleavedBuffer(n,l,e.bufferView.byteStride,e.bytesPerElement,e.count)),e.value=new o(u)}return e}},{key:"_getValueFromInterleavedBuffer",value:function(e,t,i,r,n){for(var s=new Uint8Array(n*r),o=0;o<n;o++){var a=t+o*i;s.set(new Uint8Array(e.arrayBuffer.slice(a,a+r)),o*r)}return s.buffer}},{key:"_resolveTexture",value:function(e,t){return e.id=e.id||"texture-".concat(t),e.sampler="sampler"in e?this.getSampler(e.sampler):wM,e.source=this.getImage(e.source),e}},{key:"_resolveSampler",value:function(e,t){for(var i in e.id=e.id||"sampler-".concat(t),e.parameters={},e){var r=this._enumSamplerParameter(i);void 0!==r&&(e.parameters[r]=e[i])}return e}},{key:"_enumSamplerParameter",value:function(e){return bM[e]}},{key:"_resolveImage",value:function(e,t){e.id=e.id||"image-".concat(t),void 0!==e.bufferView&&(e.bufferView=this.getBufferView(e.bufferView));var i=this.images[t];return i&&(e.image=i),e}},{key:"_resolveBufferView",value:function(e,t){var i=e.buffer,r=n(n({id:"bufferView-".concat(t)},e),{},{buffer:this.buffers[i]}),s=this.buffers[i].arrayBuffer,o=this.buffers[i].byteOffset||0;return"byteOffset"in e&&(o+=e.byteOffset),r.data=new Uint8Array(s,o,e.byteLength),r}},{key:"_resolveCamera",value:function(e,t){return e.id=e.id||"camera-".concat(t),e.perspective,e.orthographic,e}}])}();function BM(e,t){return(new xM).postProcess(e,t)}var PM=1735152710,CM=1313821514,MM=5130562,kM=!0;function EM(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,r=new DataView(t),n=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return"".concat(String.fromCharCode(e.getUint8(t+0))).concat(String.fromCharCode(e.getUint8(t+1))).concat(String.fromCharCode(e.getUint8(t+2))).concat(String.fromCharCode(e.getUint8(t+3)))}(r,i+0),s=r.getUint32(i+4,kM),o=r.getUint32(i+8,kM);switch(Object.assign(e,{header:{byteOffset:i,byteLength:o,hasBinChunk:!1},type:n,version:s,json:{},binChunks:[]}),i+=12,e.version){case 1:return function(e,t,i){eB(e.header.byteLength>20);var r=t.getUint32(i+0,kM),n=t.getUint32(i+4,kM);return i+=8,eB(0===n),SM(e,t,i,r),i+=r,i+=TM(e,t,i,e.header.byteLength),i}(e,r,i);case 2:return function(e,t,i,r){return eB(e.header.byteLength>20),function(e,t,i,r){for(;i+8<=e.header.byteLength;){var n=t.getUint32(i+0,kM),s=t.getUint32(i+4,kM);switch(i+=8,s){case CM:SM(e,t,i,n);break;case MM:TM(e,t,i,n);break;case 0:r.strict||SM(e,t,i,n);break;case 1:r.strict||TM(e,t,i,n)}i+=nB(n,4)}}(e,t,i,r),i+e.header.byteLength}(e,r,i,{});default:throw new Error("Invalid GLB version ".concat(e.version,". Only supports v1 and v2."))}}function SM(e,t,i,r){var n=new Uint8Array(t.buffer,i,r),s=new TextDecoder("utf8").decode(n);return e.json=JSON.parse(s),nB(r,4)}function TM(e,t,i,r){return e.header.hasBinChunk=!0,e.binChunks.push({byteOffset:i,byteLength:r,arrayBuffer:t.buffer}),nB(r,4)}function IM(e,t){return FM.apply(this,arguments)}function FM(){return FM=a(s().mark(function e(t,i){var r,n,o,a,l,u,c,h,A,d=arguments;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(u=d.length>4?d[4]:void 0,DM(t,i,d.length>2&&void 0!==d[2]?d[2]:0,l=d.length>3?d[3]:void 0),AM(t,{normalize:null==l||null===(r=l.gltf)||void 0===r?void 0:r.normalize}),nM(t,l,u),c=[],null==l||null===(n=l.gltf)||void 0===n||!n.loadBuffers||!t.json.buffers){e.next=10;break}return e.next=10,RM(t,l,u);case 10:return null!=l&&null!==(o=l.gltf)&&void 0!==o&&o.loadImages&&(h=LM(t,l,u),c.push(h)),A=sM(t,l,u),c.push(A),e.next=15,Promise.all(c);case 15:return e.abrupt("return",null!=l&&null!==(a=l.gltf)&&void 0!==a&&a.postProcess?BM(t,l):t);case 16:case"end":return e.stop()}},e)})),FM.apply(this,arguments)}function DM(e,t,i,r){(r.uri&&(e.baseUri=r.uri),t instanceof ArrayBuffer&&!function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=new DataView(e),n=i.magic,s=void 0===n?PM:n,o=r.getUint32(t,!1);return o===s||o===PM}(t,i,r))&&(t=(new TextDecoder).decode(t));if("string"==typeof t)e.json=iB(t);else if(t instanceof ArrayBuffer){var n={};i=EM(n,t,i,r.glb),oB("glTF"===n.type,"Invalid GLB magic string ".concat(n.type)),e._glb=n,e.json=n.json}else oB(!1,"GLTF: must be ArrayBuffer or string");var s=e.json.buffers||[];if(e.buffers=new Array(s.length).fill(null),e._glb&&e._glb.header.hasBinChunk){var o=e._glb.binChunks;e.buffers[0]={arrayBuffer:o[0].arrayBuffer,byteOffset:o[0].byteOffset,byteLength:o[0].byteLength}}var a=e.json.images||[];e.images=new Array(a.length).fill({})}function RM(e,t,i){return OM.apply(this,arguments)}function OM(){return(OM=a(s().mark(function e(t,i,r){var n,o,a,l,u,c,h,A;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:n=t.json.buffers||[],o=0;case 2:if(!(o<n.length)){e.next=22;break}if(!(a=n[o]).uri){e.next=18;break}return oB(r.fetch),c=aB(a.uri,i),e.next=10,null==r||null===(l=r.fetch)||void 0===l?void 0:l.call(r,c);case 10:return h=e.sent,e.next=13,null==h||null===(u=h.arrayBuffer)||void 0===u?void 0:u.call(h);case 13:A=e.sent,t.buffers[o]={arrayBuffer:A,byteOffset:0,byteLength:A.byteLength},delete a.uri,e.next=19;break;case 18:null===t.buffers[o]&&(t.buffers[o]={arrayBuffer:new ArrayBuffer(a.byteLength),byteOffset:0,byteLength:a.byteLength});case 19:++o,e.next=2;break;case 22:case"end":return e.stop()}},e)}))).apply(this,arguments)}function LM(e,t,i){return jM.apply(this,arguments)}function jM(){return(jM=a(s().mark(function e(t,i,r){var n,o,a,l,c,h;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:n=UM(t),o=t.json.images||[],a=[],l=u(n);try{for(l.s();!(c=l.n()).done;)h=c.value,a.push(NM(t,o[h],h,i,r))}catch(e){l.e(e)}finally{l.f()}return e.next=7,Promise.all(a);case 7:return e.abrupt("return",e.sent);case 8:case"end":return e.stop()}},e)}))).apply(this,arguments)}function UM(e){var t,i=new Set,r=u(e.json.textures||[]);try{for(r.s();!(t=r.n()).done;){var n=t.value;void 0!==n.source&&i.add(n.source)}}catch(e){r.e(e)}finally{r.f()}return Array.from(i).sort()}function NM(e,t,i,r,n){return VM.apply(this,arguments)}function VM(){return VM=a(s().mark(function e(t,i,r,n,o){var a,l,u,c,h,A,d;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(a=o.fetch,l=o.parse,!i.uri||i.hasOwnProperty("bufferView")){e.next=10;break}return c=aB(i.uri,n),e.next=5,a(c);case 5:return h=e.sent,e.next=8,h.arrayBuffer();case 8:u=e.sent,i.bufferView={data:u};case 10:return Number.isFinite(i.bufferView)&&(A=lB(t.json,t.buffers,i.bufferView),u=rB(A.buffer,A.byteOffset,A.byteLength)),oB(u,"glTF image has no data"),e.next=14,l(u,[Jx,fx],{mimeType:i.mimeType,basis:n.basis||{format:px()}},o);case 14:(d=e.sent)&&d[0]&&(d={compressed:!0,mipmaps:!1,width:d[0].width,height:d[0].height,data:d[0]}),t.images=t.images||[],t.images[r]=d;case 18:case"end":return e.stop()}},e)})),VM.apply(this,arguments)}var QM={name:"glTF",id:"gltf",module:"gltf",version:"3.4.15",extensions:["gltf","glb"],mimeTypes:["model/gltf+json","model/gltf-binary"],text:!0,binary:!0,tests:["glTF"],parse:function(e){return HM.apply(this,arguments)},options:{gltf:{normalize:!0,loadBuffers:!0,loadImages:!0,decompressMeshes:!0,postProcess:!0},log:console},deprecatedOptions:{fetchImages:"gltf.loadImages",createImages:"gltf.loadImages",decompress:"gltf.decompressMeshes",postProcess:"gltf.postProcess",gltf:{decompress:"gltf.decompressMeshes"}}};function HM(){return HM=a(s().mark(function e(t){var i,r,o,a,l,u=arguments;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return i=u.length>1&&void 0!==u[1]?u[1]:{},r=u.length>2?u[2]:void 0,(i=n(n({},QM.options),i)).gltf=n(n({},QM.options.gltf),i.gltf),o=i.byteOffset,a=void 0===o?0:o,l={},e.next=8,IM(l,t,a,i,r);case 8:return e.abrupt("return",e.sent);case 9:case"end":return e.stop()}},e)})),HM.apply(this,arguments)}var GM=function(){return P(function e(t){x(this,e)},[{key:"load",value:function(e,t,i,r,n,s,o){!function(e,t,i,r,n,s,o){var a=e.viewer.scene.canvas.spinner;a.processes++;var l="glb"===t.split(".").pop();l?e.dataSource.getGLB(t,function(o){r.basePath=zM(t),WM(e,t,o,i,r,n,s),a.processes--},function(e){a.processes--,o(e)}):e.dataSource.getGLTF(t,function(o){r.basePath=zM(t),WM(e,t,o,i,r,n,s),a.processes--},function(e){a.processes--,o(e)})}(e,t,i,r=r||{},n,function(){Ae.scheduleTask(function(){n.scene.fire("modelLoaded",n.id),n.fire("loaded",!0,!1)}),s&&s()},function(t){e.error(t),o&&o(t),n.fire("error",t)})}},{key:"parse",value:function(e,t,i,r,n,s,o){WM(e,"",t,i,r=r||{},n,function(){n.scene.fire("modelLoaded",n.id),n.fire("loaded",!0,!1),s&&s()})}}])}();function zM(e){var t=e.lastIndexOf("/");return 0!==t?e.substring(0,t+1):""}function WM(e,t,i,r,n,s,o){var a=e.viewer.scene.canvas.spinner;a.processes++,aw(i,QM,{baseUri:n.basePath}).then(function(i){var l={src:t,entityId:n.entityId,metaModelJSON:r,autoMetaModel:n.autoMetaModel,globalizeObjectIds:n.globalizeObjectIds,metaObjects:[],loadBuffer:n.loadBuffer,basePath:n.basePath,handlenode:n.handlenode,backfaces:!!n.backfaces,gltfData:i,scene:s.scene,plugin:e,sceneModel:s,numObjects:0,nodes:[],nextId:0,log:function(t){e.log(t)}};!function(e){var t=e.gltfData,i=t.textures;if(i)for(var r=0,n=i.length;r<n;r++)KM(e,i[r]);else console.log("no texture")}(l),function(e){var t=e.gltfData,i=t.materials;if(i)for(var r=0,n=i.length;r<n;r++){var s=i[r];s._textureSetId=XM(e,s),s._attributes=qM(e,s)}}(l),n.autoMetaModel&&l.metaObjects.push({id:s.id,type:"Default",name:s.id}),function(e){var t=e.gltfData,i=t.scene||t.scenes[0];if(!i)return void function(e,t){e.plugin.error(t)}(e,"glTF has no default scene");var r=i.nodes;if(!r)return;!function e(t){t.forEach(function(t){var i=t.mesh;i&&(i.instances||(i.instances=0),i.instances+=1),t.children&&e(t.children)})}(r);var n=[],s=null;!function t(i,r,o){i.forEach(function(i){var a=i.name,l=null!=a&&a||0===r&&"entity-"+e.nextId++;if(l){for(;e.sceneModel.objects[l];)l="entity-"+e.nextId++;n.push(s),s=[]}var u=function(e,t){var i;e.matrix&&(i=e.matrix,t=t?Y.mulMat4(t,i,Y.mat4()):i);e.translation&&(i=Y.translationMat4v(e.translation),t=t?Y.mulMat4(t,i,Y.mat4()):i);e.rotation&&(i=Y.quaternionToMat4(e.rotation),t=t?Y.mulMat4(t,i,Y.mat4()):i);e.scale&&(i=Y.scalingMat4v(e.scale),t=t?Y.mulMat4(t,i,Y.mat4()):i);return t}(i,o);if(i.mesh&&function(e,t,i,r){var n=e.mesh;if(!n)return;var s=n.primitives.length;if(s>0)for(var o=0;o<s;o++){var a=n.primitives[o];if(!(a.mode<4)){var l={id:t.sceneModel.id+"."+t.numObjects++},u=a.material;u?(l.textureSetId=u._textureSetId,l.color=u._attributes.color,l.opacity=u._attributes.opacity,l.metallic=u._attributes.metallic,l.roughness=u._attributes.roughness):(l.color=new Float32Array([1,1,1]),l.opacity=1);var c=!1!==t.backfaces||u&&!1!==u.doubleSided;switch(a.mode){case 0:l.primitive="points";break;case 1:case 2:case 3:l.primitive="lines";break;default:l.primitive=c?"triangles":"solid"}var h=a.attributes.POSITION;if(h){l.localPositions=h.value,l.positions=new Float64Array(l.localPositions.length),a.attributes.NORMAL&&(l.normals=a.attributes.NORMAL.value),a.attributes.TEXCOORD_0&&(l.uv=a.attributes.TEXCOORD_0.value),a.indices&&(l.indices=a.indices.value),i?Y.transformPositions3(i,l.localPositions,l.positions):l.positions.set(l.localPositions);var A=Y.vec3();we(l.positions,l.positions,A)&&(l.origin=A),t.sceneModel.createMesh(l),r.push(l.id)}}}}(i,e,u,s),i.children&&t(i.children,r+1,u),l){if(s.length>0){var c=e.globalizeObjectIds?Y.globalizeObjectId(e.sceneModel.id,l):l;e.sceneModel.createEntity({id:c,meshIds:s,isObject:!0}),e.autoMetaModel&&e.metaObjects.push({id:c,type:"Default",name:c,parent:e.sceneModel.id})}s=n.pop()}})}(r,0,null)}(l),s.finalize(),n.autoMetaModel&&e.viewer.metaScene.createMetaModel(s.id,{metaObjects:l.metaObjects}),a.processes--,o()})}function KM(e,t){if(t.source&&t.source.image){var i="texture-".concat(e.nextId++),r=Ji;switch(t.sampler.minFilter){case 9728:r=qi;break;case 9729:r=Zi;break;case 9984:r=Yi;break;case 9985:r=$i;break;case 9986:r=Ji;break;case 9987:r=tr}var n=Zi;switch(t.sampler.magFilter){case 9728:n=qi;break;case 9729:n=Zi}var s=Wi;switch(t.sampler.wrapS){case 33071:s=Ki;break;case 33648:s=Xi;break;case 10497:s=Wi}var o=Wi;switch(t.sampler.wrapT){case 33071:o=Ki;break;case 33648:o=Xi;break;case 10497:o=Wi}var a=Wi;switch(t.sampler.wrapR){case 33071:a=Ki;break;case 33648:a=Xi;break;case 10497:a=Wi}e.sceneModel.createTexture({id:i,image:t.source.image,flipY:!!t.flipY,minFilter:r,magFilter:n,wrapS:s,wrapT:o,wrapR:a,encoding:pr}),t._textureId=i}}function XM(e,t){var i={};switch(t.normalTexture&&(i.normalTextureId=t.normalTexture.texture._textureId),t.occlusionTexture&&(i.occlusionTextureId=t.occlusionTexture.texture._textureId),t.emissiveTexture&&(i.emissiveTextureId=t.emissiveTexture.texture._textureId),t.alphaMode){case"OPAQUE":break;case"MASK":var r=t.alphaCutoff;i.alphaCutoff=void 0!==r?r:.5}var n=t.pbrMetallicRoughness;if(t.pbrMetallicRoughness){var s=t.pbrMetallicRoughness,o=s.baseColorTexture||s.colorTexture;o&&(o.texture?i.colorTextureId=o.texture._textureId:i.colorTextureId=e.gltfData.textures[o.index]._textureId),n.metallicRoughnessTexture&&(i.metallicRoughnessTextureId=n.metallicRoughnessTexture.texture._textureId)}var a=t.extensions;if(a){var l=a.KHR_materials_pbrSpecularGlossiness;if(l){l.specularTexture;var u=l.specularColorTexture;null!=u&&(i.colorTextureId=e.gltfData.textures[u.index]._textureId)}}return void 0!==i.normalTextureId||void 0!==i.occlusionTextureId||void 0!==i.emissiveTextureId||void 0!==i.colorTextureId||void 0!==i.metallicRoughnessTextureId?(i.id="textureSet-".concat(e.nextId++,";"),e.sceneModel.createTextureSet(i),i.id):null}function qM(e,t){var i=t.extensions,r={color:new Float32Array([1,1,1,1]),opacity:1,metallic:0,roughness:1,doubleSided:!0};if(i){var n=i.KHR_materials_pbrSpecularGlossiness;if(n){var s=n.diffuseFactor;null!=s&&r.color.set(s)}var o=i.KHR_materials_common;if(o){var a=o.technique,l=o.values||{},u="BLINN"===a,c="PHONG"===a,h="LAMBERT"===a,A=l.diffuse;A&&(u||c||h)&&(ne.isString(A)||r.color.set(A));var d=l.transparency;null!=d&&(r.opacity=d);var p=l.transparent;null!=p&&(r.opacity=p)}}var f=t.pbrMetallicRoughness;if(f){var g=f.baseColorFactor;g&&(r.color[0]=g[0],r.color[1]=g[1],r.color[2]=g[2],r.opacity=g[3]);var m=f.metallicFactor;null!=m&&(r.metallic=m);var v=f.roughnessFactor;null!=v&&(r.roughness=v)}return r.doubleSided=!1!==t.doubleSided,r}var YM={DEFAULT:{}},JM=function(){function e(t){var i,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return x(this,e),(i=d(this,e,["GLTFLoader",t,r]))._sceneModelLoader=new GM(i,r),i.dataSource=r.dataSource,i.objectDefaults=r.objectDefaults,i}return _(e,ge),P(e,[{key:"dataSource",get:function(){return this._dataSource},set:function(e){this._dataSource=e||new _h}},{key:"objectDefaults",get:function(){return this._objectDefaults},set:function(e){this._objectDefaults=e||YM}},{key:"load",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};t.id&&this.viewer.scene.components[t.id]&&(this.error("Component with this ID already exists in viewer: "+t.id+" - will autogenerate this ID"),delete t.id);var i=new $c(this.viewer.scene,ne.apply(t,{isModel:!0,dtxEnabled:t.dtxEnabled})),r=i.id;if(!t.src&&!t.gltf)return this.error("load() param expected: src or gltf"),i;if(t.metaModelSrc||t.metaModelJSON){var n=function(n){e.viewer.metaScene.createMetaModel(r,n,{}),e.viewer.scene.canvas.spinner.processes--,t.src?e._sceneModelLoader.load(e,t.src,n,t,i):e._sceneModelLoader.parse(e,t.gltf,n,t,i)};if(t.metaModelSrc){var s=t.metaModelSrc;this.viewer.scene.canvas.spinner.processes++,this._dataSource.getMetaModel(s,function(t){e.viewer.scene.canvas.spinner.processes--,n(t)},function(t){e.error("load(): Failed to load model metadata for model '".concat(r," from '").concat(s,"' - ").concat(t)),e.viewer.scene.canvas.spinner.processes--})}else t.metaModelJSON&&n(t.metaModelJSON)}else t.src?this._sceneModelLoader.load(this,t.src,null,t,i):this._sceneModelLoader.parse(this,t.gltf,null,t,i);return i.once("destroyed",function(){e.viewer.metaScene.destroyMetaModel(r)}),i}},{key:"destroy",value:function(){g(e,"destroy",this,3)([])}}])}();function ZM(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r="lightgrey",n=i.hoverColor||"rgba(60,120,125,0.3)",s=i.textColor||"rgba(15,75,80,0.8)",o=500,a=o+o/3,l=a/24,u=e.scene.camera.normalUp,c=[{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"}],h=[{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;var A=[{areaId:0,label:"NavCube.front",boundaries:[[7,7,4,4]],dir:[0,0,-1],up:[0,1,0]},{areaId:1,label:"NavCube.back",boundaries:[[19,7,4,4]],dir:[0,0,1],up:[0,1,0]},{areaId:2,label:"NavCube.right",boundaries:[[13,7,4,4]],dir:[-1,0,0],up:[0,1,0]},{areaId:3,label:"NavCube.left",boundaries:[[1,7,4,4]],dir:[1,0,0],up:[0,1,0]},{areaId:4,label:"NavCube.top",boundaries:[[7,1,4,4]],dir:[0,-1,0],up:[0,0,-1]},{areaId:5,label:"NavCube.bottom",boundaries:[[7,13,4,4]],dir:[0,1,0],up:[0,0,1]},{areaId:6,boundaries:[[7,5,4,2]],dir:[0,-.7071,-.7071],up:[0,.7071,-.7071]},{areaId:7,boundaries:[[1,6,4,1],[6,1,1,4]],dir:[1,-1,0],up:[1,1,0]},{areaId:8,boundaries:[[7,0,4,1],[19,6,4,1]],dir:[0,-.7071,.7071],up:[0,.7071,.7071]},{areaId:9,boundaries:[[13,6,4,1],[11,1,1,4]],dir:[-1,-1,0],up:[-1,1,0]},{areaId:10,boundaries:[[7,11,4,2]],dir:[0,1,-1],up:[0,1,1]},{areaId:11,boundaries:[[1,11,4,1],[6,13,1,4]],dir:[1,1,0],up:[-1,1,0]},{areaId:12,boundaries:[[7,17,4,1],[19,11,4,1]],dir:[0,1,1],up:[0,1,-1]},{areaId:13,boundaries:[[13,11,4,1],[11,13,1,4]],dir:[-1,1,0],up:[1,1,0]},{areaId:14,boundaries:[[5,7,2,4]],dir:[1,0,-1],up:[0,1,0]},{areaId:15,boundaries:[[11,7,2,4]],dir:[-1,0,-1],up:[0,1,0]},{areaId:16,boundaries:[[17,7,2,4]],dir:[-1,0,1],up:[0,1,0]},{areaId:17,boundaries:[[0,7,1,4],[23,7,1,4]],dir:[1,0,1],up:[0,1,0]},{areaId:18,boundaries:[[5,11,2,2]],dir:[.5,.7071,-.5],up:[-.5,.7071,.5]},{areaId:19,boundaries:[[23,11,1,1],[6,17,1,1],[0,11,1,1]],dir:[.5,.7071,.5],up:[-.5,.7071,-.5]},{areaId:20,boundaries:[[5,5,2,2]],dir:[.5,-.7071,-.5],up:[.5,.7071,-.5]},{areaId:21,boundaries:[[11,17,1,1],[17,11,2,1]],dir:[-.5,.7071,.5],up:[.5,.7071,-.5]},{areaId:22,boundaries:[[17,6,2,1],[11,0,1,1]],dir:[-.5,-.7071,.5],up:[-.5,.7071,.5]},{areaId:23,boundaries:[[11,11,2,2]],dir:[-.5,.7071,-.5],up:[.5,.7071,.5]},{areaId:24,boundaries:[[0,6,1,1],[6,0,1,1],[23,6,1,1]],dir:[.5,-.7071,.5],up:[.5,.7071,.5]},{areaId:25,boundaries:[[11,5,2,2]],dir:[-.5,-.7071,-.5],up:[-.5,.7071,-.5]}],d=[{areaId:0,label:"NavCube.front",boundaries:[[7,7,4,4]],dir:[0,0,-1],up:[0,-1,0]},{areaId:1,label:"NavCube.back",boundaries:[[19,7,4,4]],dir:[0,0,1],up:[0,-1,0]},{areaId:2,label:"NavCube.right",boundaries:[[13,7,4,4]],dir:[1,0,0],up:[0,-1,0]},{areaId:3,label:"NavCube.left",boundaries:[[1,7,4,4]],dir:[-1,0,0],up:[0,-1,0]},{areaId:4,label:"NavCube.top",boundaries:[[7,1,4,4]],dir:[0,1,0],up:[0,0,-1]},{areaId:5,label:"NavCube.bottom",boundaries:[[7,13,4,4]],dir:[0,-1,0],up:[0,0,1]},{areaId:6,boundaries:[[7,5,4,2]],dir:[0,1,-1],up:[0,1,1]},{areaId:7,boundaries:[[1,6,4,1],[6,1,1,4]],dir:[-1,1,0],up:[1,1,0]},{areaId:8,boundaries:[[7,0,4,1],[19,6,4,1]],dir:[0,1,1],up:[0,1,-1]},{areaId:9,boundaries:[[13,6,4,1],[11,1,1,4]],dir:[1,1,0],up:[-1,1,0]},{areaId:10,boundaries:[[7,11,4,2]],dir:[0,-.7071,-.7071],up:[0,.7071,-.7071]},{areaId:11,boundaries:[[1,11,4,1],[6,13,1,4]],dir:[-1,-1,0],up:[-1,1,0]},{areaId:12,boundaries:[[7,17,4,1],[19,11,4,1]],dir:[0,-.7071,.7071],up:[0,.7071,.7071]},{areaId:13,boundaries:[[13,11,4,1],[11,13,1,4]],dir:[1,-1,0],up:[1,1,0]},{areaId:14,boundaries:[[5,7,2,4]],dir:[-1,0,-1],up:[0,1,0]},{areaId:15,boundaries:[[11,7,2,4]],dir:[1,0,-1],up:[0,1,0]},{areaId:16,boundaries:[[17,7,2,4]],dir:[1,0,1],up:[0,1,0]},{areaId:17,boundaries:[[0,7,1,4],[23,7,1,4]],dir:[-1,0,1],up:[0,1,0]},{areaId:18,boundaries:[[5,11,2,2]],dir:[-.5,-.7071,-.5],up:[-.5,.7071,-.5]},{areaId:19,boundaries:[[23,11,1,1],[6,17,1,1],[0,11,1,1]],dir:[-.5,-.7071,.5],up:[-.5,.7071,.5]},{areaId:20,boundaries:[[5,5,2,2]],dir:[-.5,.7071,-.5],up:[.5,.7071,.5]},{areaId:21,boundaries:[[11,17,1,1],[17,11,2,1]],dir:[.5,-.7071,.5],up:[.5,.7071,.5]},{areaId:22,boundaries:[[17,6,2,1],[11,0,1,1]],dir:[.5,.7071,.5],up:[-.5,.7071,-.5]},{areaId:23,boundaries:[[11,11,2,2]],dir:[.5,-.7071,-.5],up:[.5,.7071,-.5]},{areaId:24,boundaries:[[0,6,1,1],[6,0,1,1],[23,6,1,1]],dir:[-.5,.7071,.5],up:[.5,.7071,-.5]},{areaId:25,boundaries:[[11,5,2,2]],dir:[.5,.7071,-.5],up:[-.5,.7071,.5]}];d.forEach(function(e){e.areaId>5&&(e.up=[-1*e.up[0],-1*e.up[1],-1*e.up[2]])});for(var p=u?A:d,f=0,g=h.length;f<g;f++)Y.normalizeVec3(h[f].dir,h[f].dir),Y.normalizeVec3(h[f].up,h[f].up);for(var m=0,v=p.length;m<v;m++)Y.normalizeVec3(p[m].dir,p[m].dir),Y.normalizeVec3(p[m].up,p[m].up);var _=p;this._textureCanvas=document.createElement("canvas"),this._textureCanvas.width=a,this._textureCanvas.height=o,this._textureCanvas.style.width=a+"px",this._textureCanvas.style.height=o+"px",this._textureCanvas.style.padding="0",this._textureCanvas.style.margin="0",this._textureCanvas.style.top="0",this._textureCanvas.style.background=r,this._textureCanvas.style.position="absolute",this._textureCanvas.style.opacity="1.0",this._textureCanvas.style.display="none",this._textureCanvas.style["z-index"]=-100,this._textureCanvas.setAttribute("id","myNavCubeRenderImage"),this.cubeParentDiv=document.createElement("div"),this.cubeParentDiv.setAttribute("id","myNavCubeRenderImage_parent"),this.cubeContainer=i.viewerElement,this.cubeParentDiv.appendChild(this._textureCanvas),this.cubeContainer.appendChild(this.cubeParentDiv);var y=this._textureCanvas.getContext("2d"),b=!1;function w(){for(var e=0,i=c.length;e<i;e++){var o=c[e],a=o.boundary,u=Math.round(a[0]*l),h=Math.round(a[1]*l),A=Math.round(a[2]*l),d=Math.round(a[3]*l);y.fillStyle=o.color,y.fillRect(u,h,A,d)}for(var p=0,f=_.length;p<f;p++){for(var g=void 0,m=void 0,v=void 0,b=void 0,w=_[p],x=w.boundaries,B=0,P=x.length;B<P;B++){var M=x[B];g=Math.round(M[0]*l),m=Math.round(M[1]*l),v=Math.round(M[2]*l),b=Math.round(M[3]*l),w.highlighted&&(y.fillStyle=w.highlighted?n:w.color||r,y.fillRect(g,m,v,b))}if(w.label){y.fillStyle=s,y.font="60px sans-serif",y.textAlign="center";var k=g+.5*v,E=m+.7*b;y.fillText(C(w.label),k,E,80)}}t.glRedraw()}var x,B,P,C=(x={"NavCube.front":"NavCube.front","NavCube.back":"NavCube.back","NavCube.right":"NavCube.right","NavCube.left":"NavCube.left","NavCube.top":"NavCube.top","NavCube.bottom":"NavCube.bottom"},B={"NavCube.front":"NavCube.front","NavCube.back":"NavCube.back","NavCube.right":"NavCube.right","NavCube.left":"NavCube.left","NavCube.top":"NavCube.top","NavCube.bottom":"NavCube.bottom"},P={"NavCube.front":"FRONT","NavCube.back":"BACK","NavCube.right":"RIGHT","NavCube.left":"LEFT","NavCube.top":"TOP","NavCube.bottom":"BOTTOM"},function(t){var i=b?B:x,r=i?i[t]:null;return r?e.localeService.translate(r)||P[r]||r:t});this.setZUp=function(){b=!0,_=h,this.clear()},this.setYUp=function(){u=e.scene.camera.normalUp,b=!1,_=u?A:d,this.clear()},this.clear=function(){y.fillStyle=r,y.fillRect(0,0,a,o);for(var e=0,t=_.length;e<t;e++){_[e].highlighted=!1}w()},this.getArea=function(e){for(var t=e[0]*a,i=o-e[1]*o,r=0,n=_.length;r<n;r++)for(var s=_[r].boundaries,u=0,c=s.length;u<c;u++){var h=s[u];if(t>=h[0]*l&&t<=(h[0]+h[2])*l&&i>=h[1]*l&&i<=(h[1]+h[3])*l)return r}return-1},this.setAreaHighlighted=function(e,t){var i=_[e];if(!i)throw"Area not found: "+e;i.highlighted=!!t,w()},this.getAreaDir=function(e){var t=_[e];if(!t)throw"Unknown area: "+e;return t.dir},this.getAreaUp=function(e){var t=_[e];if(!t)throw"Unknown area: "+e;return t.up},this.getImage=function(){return this._textureCanvas},this.destroy=function(){this._textureCanvas&&(this._textureCanvas.parentNode.removeChild(this._textureCanvas),this._textureCanvas=null),this.cubeParentDiv&&(this.cubeParentDiv.parentNode.removeChild(this.cubeParentDiv),this.cubeParentDiv=null)}}var $M=Y.vec3(),ek=Y.vec3();Y.mat4();var tk=function(){function e(t){var i,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};x(this,e),i=d(this,e,["NavCube",t,r]),t.navCube=i;try{i._navCubeScene=new zi(t,{canvasId:r.canvasId,canvasElement:r.canvasElement,transparent:!0,spinnerElementId:"navcube_spinner",edgesEnabled:!0,contextAttr:{antialias:!0},resolutionScale:window.devicePixelRatio,worldAxis:t.scene.camera.worldAxis}),i._navCubeCanvas=i._navCubeScene.canvas.canvas,i._navCubeScene.input.keyboardEnabled=!1}catch(e){return i.error(e),p(i)}var n=i._navCubeScene;n.clearLights(),new hi(n,{dir:[.4,-.4,.8],color:[.8,1,1],intensity:.8,space:"view"}),new hi(n,{dir:[-.8,-.3,-.4],color:[.8,.8,.8],intensity:.8,space:"view"}),new hi(n,{dir:[.8,-.6,-.8],color:[1,1,1],intensity:.8,space:"view"}),i._navCubeCamera=n.camera,i._navCubeCamera.ortho.scale=7,i._navCubeCamera.ortho.near=.1,i._navCubeCamera.ortho.far=2e3,n.edgeMaterial.edgeColor=[.47,.62,.67],n.edgeMaterial.edgeAlpha=.2,n.edgeMaterial.edgeWidth=1,i._zUp=Boolean(t.camera.zUp);var s=i;i.mousedown=!1,i.mouseover=!1,i.setIsProjectNorth(r.isProjectNorth),i.setProjectNorthOffsetAngle(r.projectNorthOffsetAngle);var o,a=i.rotateTrueNorth=(o=Y.mat4(),function(e,t,i){return Y.identityMat4(o),Y.rotationMat4v(e*s._projectNorthOffsetAngle*Y.DEGTORAD,[0,1,0],o),Y.transformVec3(o,t,i)}),l=!1;t.scene.on("aabb",function(){l=t.scene.camera.normalUp}),i._synchCamera=function(){var e=Y.rotationMat4c(-90*Y.DEGTORAD,1,0,0),i=Y.vec3(),r=Y.vec3(),n=Y.vec3();return function(){var o=t.camera.eye,u=t.camera.look,c=t.camera.up;i=Y.mulVec3Scalar(Y.normalizeVec3(Y.subVec3(o,u,i)),5),s._isProjectNorth&&s._projectNorthOffsetAngle&&(i=a(-1,i,$M),c=a(-1,c,ek)),s._zUp?(Y.transformVec3(e,i,r),Y.transformVec3(e,c,n),s._navCubeCamera.look=[0,0,0],s._navCubeCamera.eye=Y.transformVec3(e,i,r),s._navCubeCamera.up=Y.transformPoint3(e,c,n)):(s._navCubeCamera.look=[0,0,0],s._navCubeCamera.eye=l?i:Y.mulVec3(i,[-1,-1,1]),s._navCubeCamera.up=l?c:Y.mulVec3Scalar(c,-1))}}(),i._cubeTextureCanvas=new ZM(t,n,r),i._cubeSampler=new En(n,{image:i._cubeTextureCanvas.getImage(),flipY:!0,wrapS:Ki,wrapT:Ki}),i._cubeMesh=new on(n,{geometry:new Ci(n,{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 Ti(n,{diffuse:[.4,.4,.4],specular:[.4,.4,.4],emissive:[.6,.6,.6],diffuseMap:i._cubeSampler,emissiveMap:i._cubeSampler}),visible:!0,edges:!0}),i._shadow=!1===r.shadowVisible?null:new on(n,{geometry:new Ci(n,ln({center:[0,0,0],radiusTop:.001,radiusBottom:1.4,height:.01,radialSegments:20,heightSegments:1,openEnded:!0})),material:new Ti(n,{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}),i._onCameraMatrix=t.camera.on("matrix",i._synchCamera),i._onCameraWorldAxis=t.camera.on("worldAxis",function(){t.camera.zUp?(i._zUp=!0,i._cubeTextureCanvas.setZUp(),i._repaint(),i._synchCamera()):t.camera.yUp&&(i._zUp=!1,i._cubeTextureCanvas.setYUp(),i._repaint(),i._synchCamera()),l=t.scene.camera.normalUp}),i._onCameraFOV=t.camera.perspective.on("fov",function(e){i._synchProjection&&(i._navCubeCamera.perspective.fov=e)}),i._onCameraProjection=t.camera.on("projection",function(e){i._synchProjection&&(i._navCubeCamera.projection="ortho"===e||"perspective"===e?e:"perspective")});var u=-1;function c(e){var t=[0,0];if(e){for(var i=e.target,r=0,n=0;i.offsetParent;)r+=i.offsetLeft,n+=i.offsetTop,i=i.offsetParent;t[0]=e.pageX-r,t[1]=e.pageY-n}else e=window.event,t[0]=e.x,t[1]=e.y;return t}var h=null,A=null,f=!1;s.MOUSEDOWN=!1;var g=!1;s.MOUSEOVER=!1;var m,v,_=.5;s._navCubeCanvas.addEventListener("mouseenter",s._onMouseEnter=function(e){g=!0,s.MOUSEOVER=!0}),s._navCubeCanvas.addEventListener("mouseleave",s._onMouseLeave=function(e){g=!1,s.MOUSEOVER=!1}),s._navCubeCanvas.addEventListener("mousedown",s._onMouseDown=function(e){if(1===e.which){h=e.x,A=e.y,m=e.clientX,v=e.clientY;var t=c(e);n.pick({canvasPos:t})?(f=!0,s.MOUSEDOWN=!0):(f=!1,s.MOUSEDOWN=!1)}}),document.addEventListener("mouseup",s._onMouseUp=function(e){if(1===e.which&&(f=!1,s.MOUSEDOWN=!1,null!==h)){var t=c(e),i=n.pick({canvasPos:t,pickSurface:!0});if(i&&i.uv){var r=s._cubeTextureCanvas.getArea(i.uv);if(r>=0&&(u>=0&&(s._cubeTextureCanvas.setAreaHighlighted(u,!1),s._repaint(),u=-1),r>=0)){if(s._cubeTextureCanvas.setAreaHighlighted(r,!0),u=r,s._repaint(),e.x<h-3||e.x>h+3||e.y<A-3||e.y>A+3)return;var o=s._cubeTextureCanvas.getAreaDir(r);if(o){var l=s._cubeTextureCanvas.getAreaUp(r);s._isProjectNorth&&s._projectNorthOffsetAngle&&(o=a(1,o,$M),l=a(1,l,ek)),y(o,l,function(){u>=0&&(s._cubeTextureCanvas.setAreaHighlighted(u,!1),s._repaint(),u=-1),u>=0&&(s._cubeTextureCanvas.setAreaHighlighted(u,!1),s._repaint(),u=-1),r>=0&&(s._cubeTextureCanvas.setAreaHighlighted(r,!1),u=-1,s._repaint())})}}}}}),document.addEventListener("mousemove",s._onMouseMove=function(e){if(u>=0&&(s._cubeTextureCanvas.setAreaHighlighted(u,!1),s._repaint(),u=-1),1!==e.buttons||f){if(f){var i=e.clientX,r=e.clientY;return document.body.style.cursor="move",void function(e,i){var r=(e-m)*-_,n=(i-v)*-_;t.camera.orbitYaw(r),t.camera.orbitPitch(-n),m=e,v=i}(i,r)}if(g){var o=c(e),a=n.pick({canvasPos:o,pickSurface:!0});if(a){if(a.uv){document.body.style.cursor="pointer";var l=s._cubeTextureCanvas.getArea(a.uv);if(l===u)return;u>=0&&s._cubeTextureCanvas.setAreaHighlighted(u,!1),l>=0&&(s._cubeTextureCanvas.setAreaHighlighted(l,!0),s._repaint(),u=l)}}else document.body.style.cursor="default",u>=0&&(s._cubeTextureCanvas.setAreaHighlighted(u,!1),s._repaint(),u=-1)}}});var y=i.flyTo=function(){var e=Y.vec3();return function(i,r,n){var o=s._fitVisible?t.scene.getAABB(t.scene.visibleObjectIds):t.scene.aabb,a=Y.getAABB3Diag(o);Y.getAABB3Center(o,e);var l=Math.abs(a/Math.tan(s._cameraFitFOV*Y.DEGTORAD));t.cameraControl.pivotPos=e,s._cameraFly?t.cameraFlight.flyTo({look:e,eye:[e[0]-l*i[0],e[1]-l*i[1],e[2]-l*i[2]],up:r||[0,1,0],orthoScale:1.1*a,fitFOV:s._cameraFitFOV,duration:s._cameraFlyDuration},n):t.cameraFlight.jumpTo({look:e,eye:[e[0]-l*i[0],e[1]-l*i[1],e[2]-l*i[2]],up:r||[0,1,0],orthoScale:1.1*a,fitFOV:s._cameraFitFOV},n)}}();return i._onUpdated=t.localeService.on("updated",function(){i._cubeTextureCanvas.clear(),i._repaint()}),i.setVisible(r.visible),i.setCameraFitFOV(r.cameraFitFOV),i.setCameraFly(r.cameraFly),i.setCameraFlyDuration(r.cameraFlyDuration),i.setFitVisible(r.fitVisible),i.setSynchProjection(r.synchProjection),i}return _(e,ge),P(e,[{key:"flyByClick",value:function(e,t){if(e>=0){this._cubeTextureCanvas.setAreaHighlighted(e,!0),this._repaint();var i=this._cubeTextureCanvas.getAreaDir(e);if(i){var r=this._cubeTextureCanvas.getAreaUp(e);this._isProjectNorth&&this._projectNorthOffsetAngle&&(i=this.rotateTrueNorth(1,i,$M),r=this.rotateTrueNorth(1,r,ek)),this.flyTo(i,r,t)}}}},{key:"jumpByClick",value:function(e){this.setCameraFly(!1),this.flyByClick(e),this.setCameraFly(!0)}},{key:"navCubeScene",get:function(){return this._navCubeScene}},{key:"MOUSEDOWN",get:function(){return this.mousedown},set:function(e){this.mousedown=e}},{key:"MOUSEOVER",get:function(){return this.mouseover},set:function(e){this.mouseover=e}},{key:"send",value:function(e,t){if("language"===e)this._cubeTextureCanvas.clear(),this._repaint()}},{key:"_repaint",value:function(){var e=this._cubeTextureCanvas.getImage();this._cubeMesh.material.diffuseMap.image=e,this._cubeMesh.material.emissiveMap.image=e}},{key:"setVisible",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];this._navCubeCanvas&&(this._cubeMesh.visible=e,this._shadow&&(this._shadow.visible=e),this._navCubeCanvas.style.visibility=e?"visible":"hidden")}},{key:"getVisible",value:function(){return!!this._navCubeCanvas&&this._cubeMesh.visible}},{key:"setFitVisible",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this._fitVisible=e}},{key:"getFitVisible",value:function(){return this._fitVisible}},{key:"setCameraFly",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];this._cameraFly=e}},{key:"getCameraFly",value:function(){return this._cameraFly}},{key:"setCameraFitFOV",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:45;this._cameraFitFOV=e}},{key:"getCameraFitFOV",value:function(){return this._cameraFitFOV}},{key:"setCameraFlyDuration",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:.5;this._cameraFlyDuration=e}},{key:"getCameraFlyDuration",value:function(){return this._cameraFlyDuration}},{key:"setSynchProjection",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this._synchProjection=e}},{key:"getSynchProjection",value:function(){return this._synchProjection}},{key:"setIsProjectNorth",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this._isProjectNorth=e}},{key:"getIsProjectNorth",value:function(){return this._isProjectNorth}},{key:"setProjectNorthOffsetAngle",value:function(e){this._projectNorthOffsetAngle=e}},{key:"getProjectNorthOffsetAngle",value:function(){return this._projectNorthOffsetAngle}},{key:"destroy",value:function(){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),document.removeEventListener("mousemove",this._onMouseMove),document.removeEventListener("mouseup",this._onMouseUp),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._navCubeScene.destroy(),this._navCubeScene=null,this._cubeMesh=null,this._shadow=null,g(e,"destroy",this,3)([])}}])}(),ik=new Float64Array([0,0,1]),rk=new Float64Array(4),nk=function(){return P(function e(t){x(this,e),this.id=null,this.type="control",this.plugin=t,this._viewer=t.viewer,this._scene=t.viewer.scene,this._visible=!1,this._pos=Y.vec3(),this._origin=Y.vec3(),this._rtcPos=Y.vec3(),this._baseDir=Y.vec3(),this._rootNode=null,this._displayMeshes=null,this._affordanceMeshes=null,this._ignoreNextSectionPlaneDirUpdate=!1,this._createNodes(),this._bindEvents()},[{key:"_setSectionPlane",value:function(e){var t=this;this._sectionPlane&&(this._sectionPlane.off(this._onSectionPlanePos),this._sectionPlane.off(this._onSectionPlaneDir),this._onSectionPlanePos=null,this._onSectionPlaneDir=null,this._sectionPlane=null),e&&(this.id=e.id,this._setPos(e.pos),this._setDir(e.dir),this._sectionPlane=e,this._onSectionPlanePos=e.on("pos",function(){t._setPos(t._sectionPlane.pos)}),this._onSectionPlaneDir=e.on("dir",function(){t._ignoreNextSectionPlaneDirUpdate?t._ignoreNextSectionPlaneDirUpdate=!1:t._setDir(t._sectionPlane.dir)}))}},{key:"sectionPlane",get:function(){return this._sectionPlane}},{key:"pos",get:function(){return this.posRate},set:function(e){if(!(e<0||e>100)){var t=this._scene.aabb,i=this._scene.camera.look,r=t[3]-t[0],n=t[4]-t[1],s=t[5]-t[2],o=Y.vec3();o[0]=this.pos[0],o[1]=this.pos[1],o[2]=this.pos[2];var a,l=this._sectionPlane.dir;0!=l[0]?(a=e/100*r,o[0]=i[0]-r/2+a):0!=l[1]?(a=e/100*n,o[1]=i[1]-n/2+a):0!=l[2]&&(a=e/100*s,o[2]=i[2]-s/2+a),this._sectionPlane.pos=o}}},{key:"posRate",get:function(){var e=this._scene.aabb,t=this._scene.center,i=e[3]-e[0],r=e[4]-e[1],n=e[5]-e[2],s=this._sectionPlane.pos,o=this._sectionPlane.dir,a=0;if(0!=o[0])a=(s[0]-(t[0]-i/2))/i*100;else if(0!=o[1]){a=(s[1]-(t[1]-r/2))/r*100}else if(0!=o[2]){a=(s[2]-(t[2]-n/2))/n*100}return a=Math.max(0,Math.min(100,a)),parseInt(a)}},{key:"_setPos",value:function(e){this._pos.set(e),be(this._pos,this._origin,this._rtcPos),this._rootNode.origin=this._origin,this._rootNode.position=this._rtcPos}},{key:"_setDir",value:function(e){this._baseDir.set(e),this._rootNode.quaternion=Y.vec3PairToQuaternion(ik,e,rk)}},{key:"_setSectionPlaneDir",value:function(e){this._sectionPlane&&(this._ignoreNextSectionPlaneDirUpdate=!0,this._sectionPlane.dir=e)}},{key:"setVisible",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];if(this._visible!==e){var t;for(t in this._visible=e,this._displayMeshes)this._displayMeshes.hasOwnProperty(t)&&(this._displayMeshes[t].visible=e);if(!e)for(t in this._affordanceMeshes)this._affordanceMeshes.hasOwnProperty(t)&&(this._affordanceMeshes[t].visible=e)}}},{key:"getVisible",value:function(){return this._visible}},{key:"setCulled",value:function(e){var t;for(t in this._displayMeshes)this._displayMeshes.hasOwnProperty(t)&&(this._displayMeshes[t].culled=e);if(!e)for(t in this._affordanceMeshes)this._affordanceMeshes.hasOwnProperty(t)&&(this._affordanceMeshes[t].culled=e)}},{key:"_createNodes",value:function(){var e=!1,t=this._viewer.scene,i=.01;this._rootNode=new yn(t,{id:this.id,position:[0,0,0],scale:[5,5,5],isObject:!1});var r,n,s=this._rootNode,o={arrowHead:new Ci(s,ln({radiusTop:.001,radiusBottom:.07,radialSegments:32,heightSegments:1,height:.2,openEnded:!1})),arrowHeadBig:new Ci(s,ln({radiusTop:.001,radiusBottom:.09,radialSegments:32,heightSegments:1,height:.25,openEnded:!1})),arrowHeadHandle:new Ci(s,ln({radiusTop:.09,radiusBottom:.09,radialSegments:8,heightSegments:1,height:.37,openEnded:!1})),curve:new Ci(s,On({radius:.8,tube:i,radialSegments:64,tubeSegments:14,arc:2*Math.PI/4})),curveHandle:new Ci(s,On({radius:.8,tube:.06,radialSegments:64,tubeSegments:14,arc:2*Math.PI/4})),hoop:new Ci(s,On({radius:.8,tube:i,radialSegments:64,tubeSegments:8,arc:2*Math.PI})),axis:new Ci(s,ln({radiusTop:i,radiusBottom:i,radialSegments:20,heightSegments:1,height:1,openEnded:!1})),axisHandle:new Ci(s,ln({radiusTop:.08,radiusBottom:.08,radialSegments:20,heightSegments:1,height:1,openEnded:!1}))},a={pickable:new Ti(s,{diffuse:[1,1,0],alpha:0,alphaMode:"blend"}),red:new Ti(s,{diffuse:[1,0,0],emissive:[1,0,0],ambient:[0,0,0],specular:[.6,.6,.3],shininess:80,lineWidth:2}),highlightRed:new Fi(s,{edges:!1,fill:!0,fillColor:[1,0,0],fillAlpha:.6}),green:new Ti(s,{diffuse:[0,1,0],emissive:[0,1,0],ambient:[0,0,0],specular:[.6,.6,.3],shininess:80,lineWidth:2}),highlightGreen:new Fi(s,{edges:!1,fill:!0,fillColor:[0,1,0],fillAlpha:.6}),blue:new Ti(s,{diffuse:[0,0,1],emissive:[0,0,1],ambient:[0,0,0],specular:[.6,.6,.3],shininess:80,lineWidth:2}),highlightBlue:new Fi(s,{edges:!1,fill:!0,fillColor:[0,0,1],fillAlpha:.2}),center:new Ti(s,{diffuse:[0,0,0],emissive:[0,0,0],ambient:[0,0,0],specular:[.6,.6,.3],shininess:80}),highlightBall:new Fi(s,{edges:!1,fill:!0,fillColor:[.5,.5,.5],fillAlpha:.5,vertices:!1}),highlightPlane:new Fi(s,{edges:!0,edgeWidth:3,fill:!1,fillColor:[.5,.5,.5],fillAlpha:.5,vertices:!1})};this._displayMeshes={plane:s.addChild(new on(s,{geometry:new Ci(s,{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 Ti(s,{emissive:[0,0,0],diffuse:[0,0,0],backfaces:!0}),opacity:.6,ghosted:!0,ghostMaterial:new Fi(s,{edges:!1,filled:!0,fillColor:[1,1,0],edgeColor:[0,0,0],fillAlpha:.1,backfaces:!0}),pickable:!1,collidable:!1,clippable:!1,visible:!1,scale:[2.4,2.4,1],isObject:!1}),e),planeFrame:s.addChild(new on(s,{geometry:new Ci(s,On({center:[0,0,0],radius:1.7,tube:.02,radialSegments:4,tubeSegments:4,arc:2*Math.PI})),material:new Ti(s,{emissive:[0,0,0],diffuse:[0,0,0],specular:[0,0,0],shininess:0}),highlightMaterial:new Fi(s,{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}),e),xCurve:s.addChild(new on(s,{geometry:o.curve,material:a.red,matrix:(r=Y.rotationMat4v(90*Y.DEGTORAD,[0,1,0],Y.identityMat4()),n=Y.rotationMat4v(270*Y.DEGTORAD,[1,0,0],Y.identityMat4()),Y.mulMat4(n,r,Y.identityMat4())),pickable:!1,collidable:!1,clippable:!1,backfaces:!0,visible:!1,isObject:!1}),e),xCurveHandle:s.addChild(new on(s,{geometry:o.curveHandle,material:a.pickable,matrix:function(){var e=Y.rotationMat4v(90*Y.DEGTORAD,[0,1,0],Y.identityMat4()),t=Y.rotationMat4v(270*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,backfaces:!0,visible:!1,isObject:!1}),e),xCurveArrow1:s.addChild(new on(s,{geometry:o.arrowHead,material:a.red,matrix:function(){var e=Y.translateMat4c(0,-.07,-.8,Y.identityMat4()),t=Y.scaleMat4v([.6,.6,.6],Y.identityMat4()),i=Y.rotationMat4v(0*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(Y.mulMat4(e,t,Y.identityMat4()),i,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),xCurveArrow2:s.addChild(new on(s,{geometry:o.arrowHead,material:a.red,matrix:function(){var e=Y.translateMat4c(0,-.8,-.07,Y.identityMat4()),t=Y.scaleMat4v([.6,.6,.6],Y.identityMat4()),i=Y.rotationMat4v(90*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(Y.mulMat4(e,t,Y.identityMat4()),i,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yCurve:s.addChild(new on(s,{geometry:o.curve,material:a.green,rotation:[-90,0,0],pickable:!1,collidable:!1,clippable:!1,backfaces:!0,visible:!1,isObject:!1}),e),yCurveHandle:s.addChild(new on(s,{geometry:o.curveHandle,material:a.pickable,rotation:[-90,0,0],pickable:!0,collidable:!1,clippable:!1,backfaces:!0,visible:!1,isObject:!1}),e),yCurveArrow1:s.addChild(new on(s,{geometry:o.arrowHead,material:a.green,matrix:function(){var e=Y.translateMat4c(.07,0,-.8,Y.identityMat4()),t=Y.scaleMat4v([.6,.6,.6],Y.identityMat4()),i=Y.rotationMat4v(90*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(Y.mulMat4(e,t,Y.identityMat4()),i,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yCurveArrow2:s.addChild(new on(s,{geometry:o.arrowHead,material:a.green,matrix:function(){var e=Y.translateMat4c(.8,0,-.07,Y.identityMat4()),t=Y.scaleMat4v([.6,.6,.6],Y.identityMat4()),i=Y.rotationMat4v(90*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(Y.mulMat4(e,t,Y.identityMat4()),i,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),center:s.addChild(new on(s,{geometry:new Ci(s,un({radius:.05})),material:a.center,pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),xAxisArrow:s.addChild(new on(s,{geometry:o.arrowHead,material:a.red,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),xAxisArrowHandle:s.addChild(new on(s,{geometry:o.arrowHeadHandle,material:a.pickable,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),xAxis:s.addChild(new on(s,{geometry:o.axis,material:a.red,matrix:function(){var e=Y.translateMat4c(0,.5,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),xAxisHandle:s.addChild(new on(s,{geometry:o.axisHandle,material:a.pickable,matrix:function(){var e=Y.translateMat4c(0,.5,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yAxisArrow:s.addChild(new on(s,{geometry:o.arrowHead,material:a.green,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(180*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yAxisArrowHandle:s.addChild(new on(s,{geometry:o.arrowHeadHandle,material:a.pickable,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(180*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,opacity:.2,isObject:!1}),e),yShaft:s.addChild(new on(s,{geometry:o.axis,material:a.green,position:[0,-.5,0],pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yShaftHandle:s.addChild(new on(s,{geometry:o.axisHandle,material:a.pickable,position:[0,-.5,0],pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),zAxisArrow:s.addChild(new on(s,{geometry:o.arrowHead,material:a.blue,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[.8,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),zAxisArrowHandle:s.addChild(new on(s,{geometry:o.arrowHeadHandle,material:a.pickable,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[.8,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),zShaft:s.addChild(new on(s,{geometry:o.axis,material:a.blue,matrix:function(){var e=Y.translateMat4c(0,.5,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),clippable:!1,pickable:!1,collidable:!1,visible:!1,isObject:!1}),e),zAxisHandle:s.addChild(new on(s,{geometry:o.axisHandle,material:a.pickable,matrix:function(){var e=Y.translateMat4c(0,.5,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),clippable:!1,pickable:!0,collidable:!1,visible:!1,isObject:!1}),e)},this._affordanceMeshes={planeFrame:s.addChild(new on(s,{geometry:new Ci(s,On({center:[0,0,0],radius:2,tube:i,radialSegments:4,tubeSegments:4,arc:2*Math.PI})),material:new Ti(s,{ambient:[1,1,1],diffuse:[0,0,0],emissive:[1,1,0]}),highlighted:!0,highlightMaterial:new Fi(s,{edges:!1,filled:!0,fillColor:[1,1,0],fillAlpha:1}),pickable:!1,collidable:!1,clippable:!1,visible:!1,scale:[1,1,1],rotation:[0,0,45],isObject:!1}),e),xHoop:s.addChild(new on(s,{geometry:o.hoop,material:a.red,highlighted:!0,highlightMaterial:a.highlightRed,matrix:function(){var e=Y.rotationMat4v(90*Y.DEGTORAD,[0,1,0],Y.identityMat4()),t=Y.rotationMat4v(270*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yHoop:s.addChild(new on(s,{geometry:o.hoop,material:a.green,highlighted:!0,highlightMaterial:a.highlightGreen,rotation:[-90,0,0],pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),zHoop:s.addChild(new on(s,{geometry:o.hoop,material:a.blue,highlighted:!0,highlightMaterial:a.highlightBlue,matrix:Y.rotationMat4v(180*Y.DEGTORAD,[1,0,0],Y.identityMat4()),pickable:!1,collidable:!1,clippable:!1,backfaces:!0,visible:!1,isObject:!1}),e),xAxisArrow:s.addChild(new on(s,{geometry:o.arrowHeadBig,material:a.red,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yAxisArrow:s.addChild(new on(s,{geometry:o.arrowHeadBig,material:a.green,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(180*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),zAxisArrow:s.addChild(new on(s,{geometry:o.arrowHeadBig,material:a.blue,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[.8,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e)}}},{key:"_bindEvents",value:function(){var e=this,t=this,i=!1,r=-1,n=0,s=1,o=2,a=3,l=4,u=5,c=this._rootNode,h=null,A=null,d=Y.vec2(),p=Y.vec3([1,0,0]),f=Y.vec3([0,1,0]),g=Y.vec3([0,0,1]),m=this._viewer.scene.canvas.canvas,v=this._viewer.camera,_=this._viewer.scene,y=Y.vec3([0,0,0]),b=-1;this._onCameraViewMatrix=_.camera.on("viewMatrix",function(){}),this._onCameraProjMatrix=_.camera.on("projMatrix",function(){}),this._onSceneTick=_.on("tick",function(){var t=Math.abs(Y.lenVec3(Y.subVec3(_.camera.eye,e._pos,y)));if(t!==b&&"perspective"===v.projection){var i=.07*(Math.tan(v.perspective.fov*Y.DEGTORAD)*t);c.scale=[i,i,i],b=t}if("ortho"===v.projection){var r=v.ortho.scale/10;c.scale=[r,r,r],b=t}});var w,x,B,P,C,M=function(){var e=new Float64Array(2);return function(t){if(t){for(var i=t.target,r=0,n=0;i.offsetParent;)r+=i.offsetLeft,n+=i.offsetTop,i=i.offsetParent;e[0]=t.pageX-r,e[1]=t.pageY-n}else t=window.event,e[0]=t.x,e[1]=t.y;return e}}(),k=function(){var e=new Float64Array(2);return function(t){if(t||(t=window.event),t.touches&&t.touches.length)e[0]=t.touches[0].pageX,e[1]=t.touches[0].pageY;else{for(var i=t.target,r=0,n=0;i.offsetParent;)r+=i.offsetLeft,n+=i.offsetTop,i=i.offsetParent;e[0]=t.pageX-r,e[1]=t.pageY-n}return e}}(),E=function(){var e=Y.mat4();return function(i,r){return Y.quaternionToMat4(t._rootNode.quaternion,e),Y.transformVec3(e,i,r),Y.normalizeVec3(r),r}}(),S=(w=Y.vec3(),function(e){var t=Math.abs(e[0]);return t>Math.abs(e[1])&&t>Math.abs(e[2])?Y.cross3Vec3(e,[0,1,0],w):Y.cross3Vec3(e,[1,0,0],w),Y.cross3Vec3(w,e,w),Y.normalizeVec3(w),w}),T=(x=Y.vec3(),B=Y.vec3(),P=Y.vec4(),function(e,i,r){E(e,P);var n=S(P,i,r);F(i,n,x),F(r,n,B),Y.subVec3(B,x);var s=Y.dotVec3(B,P);t._pos[0]+=P[0]*s*.6,t._pos[1]+=P[1]*s*.6,t._pos[2]+=P[2]*s*.6,t._rootNode.position=t._pos,t._sectionPlane&&(t._sectionPlane.pos=t._pos)}),I=function(){var e=Y.vec4(),i=Y.vec4(),r=Y.vec4(),n=Y.vec4();return function(s,o,a){if(E(s,n),!(F(o,n,e)&&F(a,n,i))){var l=S(n,o,a);F(o,l,e,1),F(a,l,i,1);var u=Y.dotVec3(e,n);e[0]-=u*n[0],e[1]-=u*n[1],e[2]-=u*n[2],u=Y.dotVec3(i,n),i[0]-=u*n[0],i[1]-=u*n[1],i[2]-=u*n[2]}Y.normalizeVec3(e),Y.normalizeVec3(i),u=Y.dotVec3(e,i),u=Y.clamp(u,-1,1);var c=Math.acos(u)*Y.RADTODEG;Y.cross3Vec3(e,i,r),Y.dotVec3(r,n)<0&&(c=-c),t._rootNode.rotate(s,c),D()}}(),F=function(){var e=Y.vec4([0,0,0,1]),i=Y.mat4();return function(r,n,s,o){o=o||0,e[0]=r[0]/m.width*2-1,e[1]=-(r[1]/m.height*2-1),e[2]=0,e[3]=1,Y.mulMat4(v.projMatrix,v.viewMatrix,i),Y.inverseMat4(i),Y.transformVec4(i,e,e),Y.mulVec4Scalar(e,1/e[3]);var a=v.eye;Y.subVec4(e,a,e);var l=t._sectionPlane.pos,u=-Y.dotVec3(l,n)-o,c=Y.dotVec3(n,e);if(Math.abs(c)>.005){var h=-(Y.dotVec3(n,a)+u)/c;return Y.mulVec3Scalar(e,h,s),Y.addVec3(s,a),Y.subVec3(s,l,s),!0}return!1}}(),D=function(){var e=Y.vec3(),i=Y.mat4();return function(){t.sectionPlane&&(Y.quaternionToMat4(c.quaternion,i),Y.transformVec3(i,[0,0,1],e),t._setSectionPlaneDir(e))}}(),R=!1;this._onCameraControlHover=this._viewer.cameraControl.on("hoverEnter",function(t){if(e._visible&&!R){var u;switch(i=!1,C&&(C.visible=!1),t.entity.id){case e._displayMeshes.xAxisArrowHandle.id:case e._displayMeshes.xAxisHandle.id:u=e._affordanceMeshes.xAxisArrow,h=n;break;case e._displayMeshes.yAxisArrowHandle.id:case e._displayMeshes.yShaftHandle.id:u=e._affordanceMeshes.yAxisArrow,h=s;break;case e._displayMeshes.zAxisArrowHandle.id:case e._displayMeshes.zAxisHandle.id:u=e._affordanceMeshes.zAxisArrow,h=o;break;case e._displayMeshes.xCurveHandle.id:u=e._affordanceMeshes.xHoop,h=a;break;case e._displayMeshes.yCurveHandle.id:u=e._affordanceMeshes.yHoop,h=l;break;default:return void(h=r)}u&&(u.visible=!0),C=u,i=!0}}),this._onCameraControlHoverLeave=this._viewer.cameraControl.on("hoverOut",function(t){e._visible&&(C&&(C.visible=!1),C=null,h=r,i=!1)}),m.addEventListener("mousedown",this._canvasMouseDownListener=function(t){if(t.preventDefault(),e._visible&&i&&(e._viewer.cameraControl.pointerEnabled=!1,1===t.which)){R=!0;var r=M(t);A=h,d[0]=r[0],d[1]=r[1],e.plugin.fire("clickPlaneStart")}}),m.addEventListener("mousemove",this._canvasMouseMoveListener=function(t){if(e._visible&&R){var i=M(t),r=i[0],c=i[1];switch(A){case n:T(p,d,i);break;case s:T(f,d,i);break;case o:T(g,d,i);break;case a:I(p,d,i);break;case l:I(f,d,i);break;case u:I(g,d,i)}d[0]=r,d[1]=c}}),m.addEventListener("mouseup",this._canvasMouseUpListener=function(t){e._visible&&(e._viewer.cameraControl.pointerEnabled=!0,R&&(t.which,R=!1,i=!1,e.plugin.fire("clickPlaneEnd")))}),m.addEventListener("wheel",this._canvasWheelListener=function(t){if(e._visible)Math.max(-1,Math.min(1,40*-t.deltaY))}),this._onCameraControlHover=this._viewer.cameraControl.on("touchEntity",function(t){if(e._visible&&!R&&!i){var u;switch(i=!1,C&&(C.visible=!1),t.entity.id){case e._displayMeshes.xAxisArrowHandle.id:case e._displayMeshes.xAxisHandle.id:u=e._affordanceMeshes.xAxisArrow,h=n;break;case e._displayMeshes.yAxisArrowHandle.id:case e._displayMeshes.yShaftHandle.id:u=e._affordanceMeshes.yAxisArrow,h=s;break;case e._displayMeshes.zAxisArrowHandle.id:case e._displayMeshes.zAxisHandle.id:u=e._affordanceMeshes.zAxisArrow,h=o;break;case e._displayMeshes.xCurveHandle.id:u=e._affordanceMeshes.xHoop,h=a;break;case e._displayMeshes.yCurveHandle.id:u=e._affordanceMeshes.yHoop,h=l;break;default:return void(h=r)}u&&(u.visible=!0),C=u,i=!0}}),m.addEventListener("touchstart",this._canvasMouseDownListener=function(t){if(t.preventDefault(),e._visible&&i){e._viewer.cameraControl.pointerEnabled=!1,R=!0;var r=k(t);A=h,d[0]=r[0],d[1]=r[1],e.plugin.fire("touchPlaneStart")}}),m.addEventListener("touchmove",this._canvasMouseMoveListener=function(t){if(e._visible&&R){var i=k(t),r=i[0],c=i[1];switch(A){case n:T(p,d,i);break;case s:T(f,d,i);break;case o:T(g,d,i);break;case a:I(p,d,i);break;case l:I(f,d,i);break;case u:I(g,d,i)}d[0]=r,d[1]=c}}),m.addEventListener("touchend",this._canvasTouchEndListener=function(t){e._visible&&(e._viewer.cameraControl.pointerEnabled=!0,C&&(C.visible=!1),C=null,h=r,R=!1,i=!1,e.plugin.fire("touchPlaneEnd"))}),m.addEventListener("touchcancel",this._canvasTouchEndListener)}},{key:"_destroy",value:function(){this._unbindEvents(),this._destroyNodes()}},{key:"_unbindEvents",value:function(){var e=this._viewer,t=e.scene,i=t.canvas.canvas,r=e.camera,n=e.cameraControl;t.off(this._onSceneTick),i.removeEventListener("mousedown",this._canvasMouseDownListener),i.removeEventListener("mousemove",this._canvasMouseMoveListener),i.removeEventListener("mouseup",this._canvasMouseUpListener),i.removeEventListener("wheel",this._canvasWheelListener),i.removeEventListener("touchend",this._canvasTouchEndListener),i.removeEventListener("touchcancel",this._canvasTouchEndListener),r.off(this._onCameraViewMatrix),r.off(this._onCameraProjMatrix),n.off(this._onCameraControlHover),n.off(this._onCameraControlHoverLeave)}},{key:"_destroyNodes",value:function(){this._setSectionPlane(null),this._rootNode.destroy(),this._displayMeshes={},this._affordanceMeshes={}}}])}(),sk=new Float64Array([0,0,1]),ok=new Float64Array(4),ak=function(){return P(function e(t,i){x(this,e),this.id=i.id,this.type="control",this.plugin=t,this._viewer=t.viewer,this._scene=t.viewer.scene,i||(i={}),this._xColor=i.xColor?i.xColor:[.5,.5,.5],this._yColor=i.yColor?i.yColor:[.5,.5,.5],this._zColor=i.zColor?i.zColor:[.5,.5,.5],this._controlFillColor=i.controlFillColor?i.controlFillColor:[.1,.4,.99],this._planeSize=i.planeSize?i.planeSize:1,this._controlSize=i.controlSize?i.controlSize:.07,this._planeOpacity=i.planeOpacity?i.planeOpacity:.4,this._visible=!1,this._pos=Y.vec3(),this._origin=Y.vec3(),this._rtcPos=Y.vec3(),this._baseDir=Y.vec3(),this._rootNode=null,this._displayMeshes=null,this._affordanceMeshes=null,this._ignoreNextSectionPlaneDirUpdate=!1},[{key:"_createNodes",value:function(){var e=!1,t=this._viewer.scene,i=t.aabb,r=.01,n=i[3]-i[0],s=i[4]-i[1],o=i[5]-i[2];this._rootNode=new yn(t,{id:"sectionControl",position:[0,0,0],scale:[5,5,5],isObject:!1});var a,l,u=this._rootNode,c={arrowHead:new Ci(u,ln({radiusTop:.001,radiusBottom:.04,radialSegments:32,heightSegments:1,height:.15,openEnded:!1})),arrowHeadBig:new Ci(u,ln({radiusTop:.001,radiusBottom:.05,radialSegments:32,heightSegments:1,height:.18,openEnded:!1})),arrowHeadHandle:new Ci(u,ln({radiusTop:.09,radiusBottom:.09,radialSegments:8,heightSegments:1,height:.37,openEnded:!1})),curve:new Ci(u,On({radius:.5,tube:r,radialSegments:32,tubeSegments:7,arc:2*Math.PI/4})),curveHandle:new Ci(u,On({radius:.5,tube:.04,radialSegments:32,tubeSegments:7,arc:2*Math.PI/4})),hoop:new Ci(u,On({radius:.8,tube:r,radialSegments:64,tubeSegments:8,arc:2*Math.PI})),axis:new Ci(u,ln({radiusTop:r,radiusBottom:r,radialSegments:20,heightSegments:1,height:1,openEnded:!1})),axisHandle:new Ci(u,ln({radiusTop:.08,radiusBottom:.08,radialSegments:20,heightSegments:1,height:1,openEnded:!1}))},h={pickable:new Ti(u,{diffuse:[1,1,0],alpha:0,alphaMode:"opaque"}),red:new Ti(u,{diffuse:this._xColor,emissive:this._xColor,ambient:[0,0,0],specular:[.6,.6,.3],shininess:80,lineWidth:1.5}),highlightRed:new Fi(u,{edges:!1,fill:!0,fillColor:[.8,.8,.8],fillAlpha:.6}),green:new Ti(u,{diffuse:this._yColor,emissive:this._yColor,ambient:[0,0,0],specular:[.6,.6,.3],shininess:80,lineWidth:1.5}),highlightGreen:new Fi(u,{edges:!1,fill:!0,fillColor:[.8,.8,.8],fillAlpha:.6}),blue:new Ti(u,{diffuse:this._zColor,emissive:this._zColor,ambient:[0,0,0],specular:[.6,.6,.3],shininess:80,lineWidth:1.5}),highlightBlue:new Fi(u,{edges:!1,fill:!0,fillColor:[.8,.8,.8],fillAlpha:.2}),center:new Ti(u,{diffuse:[0,0,0],emissive:[0,0,0],ambient:[0,0,0],specular:[.6,.6,.3],shininess:80}),highlightBall:new Fi(u,{edges:!1,fill:!0,fillColor:[.5,.5,.5],fillAlpha:.5,vertices:!1}),highlightPlane:new Fi(u,{edges:!0,edgeWidth:3,fill:!1,fillColor:[.5,.5,.5],fillAlpha:.5,vertices:!1})};this._displayMeshes={plane:u.addChild(new on(u,{geometry:new Ci(u,{primitive:"triangles",positions:[10,5,0,10,-5,0,-10,-5,0,-10,5,0],indices:[0,1,2,2,3,0]}),material:new Ti(u,{emissive:[0,0,0],diffuse:this._controlFillColor,backfaces:!0}),opacity:this._planeOpacity,ghosted:!1,ghostMaterial:new Fi(u,{edges:!1,filled:!0,fillColor:this._controlFillColor?this._controlFillColor:[.1,.4,.99],edgeColor:[0,0,0],fillAlpha:.1,backfaces:!0}),pickable:!0,collidable:!1,clippable:!1,visible:!1,scale:[this._planeSize,this._planeSize,this._planeSize],isObject:!1}),e),planeFrame:u.addChild(new on(u,{geometry:new Ci(u,Dn({center:[0,0,0],xSize:.1*n,ySize:.1*s,zSize:.1*o})),material:new Ti(u,{emissive:[.5,.5,.5],diffuse:[.5,.5,.5],specular:[.5,.5,.5],alpha:.2,shininess:10}),highlightMaterial:new Fi(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],isObject:!1}),e),xCurve:u.addChild(new on(u,{geometry:c.curve,material:h.red,matrix:(a=Y.rotationMat4v(90*Y.DEGTORAD,[0,1,0],Y.identityMat4()),l=Y.rotationMat4v(270*Y.DEGTORAD,[1,0,0],Y.identityMat4()),Y.mulMat4(l,a,Y.identityMat4())),pickable:!1,collidable:!1,clippable:!1,backfaces:!0,visible:!1,isObject:!1}),e),xCurveHandle:u.addChild(new on(u,{geometry:c.curveHandle,material:h.pickable,matrix:function(){var e=Y.rotationMat4v(90*Y.DEGTORAD,[0,1,0],Y.identityMat4()),t=Y.rotationMat4v(270*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,backfaces:!0,visible:!1,isObject:!1}),e),yCurve:u.addChild(new on(u,{geometry:c.curve,material:h.green,rotation:[-90,0,0],pickable:!1,collidable:!1,clippable:!1,backfaces:!0,visible:!1,isObject:!1}),e),yCurveHandle:u.addChild(new on(u,{geometry:c.curveHandle,material:h.pickable,rotation:[-90,0,0],pickable:!0,collidable:!1,clippable:!1,backfaces:!0,visible:!1,isObject:!1}),e),center:u.addChild(new on(u,{geometry:new Ci(u,un({radius:.05})),material:h.center,pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),xAxisArrow:u.addChild(new on(u,{geometry:c.arrowHead,material:h.red,matrix:function(){var e=Y.translateMat4c(0,1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),xAxisArrowHandle:u.addChild(new on(u,{geometry:c.arrowHeadHandle,material:h.pickable,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),xAxis:u.addChild(new on(u,{geometry:c.axis,material:h.red,matrix:function(){var e=Y.translateMat4c(0,.5,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),xAxisHandle:u.addChild(new on(u,{geometry:c.axisHandle,material:h.pickable,matrix:function(){var e=Y.translateMat4c(0,.5,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yAxisArrow:u.addChild(new on(u,{geometry:c.arrowHead,material:h.green,matrix:function(){var e=Y.translateMat4c(0,1,0,Y.identityMat4()),t=Y.rotationMat4v(180*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yAxisArrowHandle:u.addChild(new on(u,{geometry:c.arrowHeadHandle,material:h.pickable,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(180*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,opacity:.2,isObject:!1}),e),yShaft:u.addChild(new on(u,{geometry:c.axis,material:h.green,position:[0,-.5,0],pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yShaftHandle:u.addChild(new on(u,{geometry:c.axisHandle,material:h.pickable,position:[0,-.5,0],pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),zAxisArrow:u.addChild(new on(u,{geometry:c.arrowHead,material:h.blue,matrix:function(){var e=Y.translateMat4c(0,1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[2,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),zAxisArrowHandle:u.addChild(new on(u,{geometry:c.arrowHeadHandle,material:h.pickable,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[.8,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),zShaft:u.addChild(new on(u,{geometry:c.axis,material:h.blue,matrix:function(){var e=Y.translateMat4c(0,.5,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),clippable:!1,pickable:!1,collidable:!1,visible:!1,isObject:!1}),e),zAxisHandle:u.addChild(new on(u,{geometry:c.axisHandle,material:h.pickable,matrix:function(){var e=Y.translateMat4c(0,.5,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),clippable:!1,pickable:!0,collidable:!1,visible:!1,isObject:!1}),e)},this._affordanceMeshes={xHoop:u.addChild(new on(u,{geometry:c.hoop,material:h.red,highlighted:!0,highlightMaterial:h.highlightRed,matrix:function(){var e=Y.rotationMat4v(90*Y.DEGTORAD,[0,1,0],Y.identityMat4()),t=Y.rotationMat4v(270*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yHoop:u.addChild(new on(u,{geometry:c.hoop,material:h.green,highlighted:!0,highlightMaterial:h.highlightGreen,rotation:[-90,0,0],pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),zHoop:u.addChild(new on(u,{geometry:c.hoop,material:h.blue,highlighted:!0,highlightMaterial:h.highlightBlue,matrix:Y.rotationMat4v(180*Y.DEGTORAD,[1,0,0],Y.identityMat4()),pickable:!1,collidable:!1,clippable:!1,backfaces:!0,visible:!1,isObject:!1}),e),xAxisArrow:u.addChild(new on(u,{geometry:c.arrowHeadBig,material:h.red,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yAxisArrow:u.addChild(new on(u,{geometry:c.arrowHeadBig,material:h.green,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(180*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),zAxisArrow:u.addChild(new on(u,{geometry:c.arrowHeadBig,material:h.blue,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[.8,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e)}}},{key:"_setSectionPlane",value:function(e){var t=this;this._sectionPlane&&(this._sectionPlane.off(this._onSectionPlanePos),this._sectionPlane.off(this._onSectionPlaneDir),this._onSectionPlanePos=null,this._onSectionPlaneDir=null,this._sectionPlane=null),e&&(this.id=e.controlId,this._createNodes(),this._bindEvents(),this._setPos(e.pos),this._setDir(e.dir),this._sectionPlane=e,this._onSectionPlanePos=e.on("pos",function(){t._setPos(t._sectionPlane.pos)}),this._onSectionPlaneDir=e.on("dir",function(){t._ignoreNextSectionPlaneDirUpdate?t._ignoreNextSectionPlaneDirUpdate=!1:t._setDir(t._sectionPlane.dir)}))}},{key:"sectionPlane",get:function(){return this._sectionPlane}},{key:"pos",get:function(){return this.posRate},set:function(e){if(!(e<0||e>100)){var t=this._scene.aabb,i=this._scene.camera.look,r=t[3]-t[0],n=t[4]-t[1],s=t[5]-t[2],o=Y.vec3();o[0]=this.pos[0],o[1]=this.pos[1],o[2]=this.pos[2];var a,l=this._sectionPlane.dir;0!=l[0]?(a=e/100*r,o[0]=i[0]-r/2+a):0!=l[1]?(a=e/100*n,o[1]=i[1]-n/2+a):0!=l[2]&&(a=e/100*s,o[2]=i[2]-s/2+a),this._sectionPlane.pos=o}}},{key:"posRate",get:function(){var e=this._scene.aabb,t=this._scene.center,i=e[3]-e[0],r=e[4]-e[1],n=e[5]-e[2],s=this._sectionPlane.pos,o=this._sectionPlane.dir,a=0;if(0!=o[0])a=(s[0]-(t[0]-i/2))/i*100;else if(0!=o[1]){a=(s[1]-(t[1]-r/2))/r*100}else if(0!=o[2]){a=(s[2]-(t[2]-n/2))/n*100}return a=Math.max(0,Math.min(100,a)),parseInt(a)}},{key:"_setPos",value:function(e){this._pos.set(e),be(this._pos,this._origin,this._rtcPos),this._rootNode.origin=this._origin,this._rootNode.position=this._rtcPos}},{key:"_setDir",value:function(e){this._baseDir.set(e),this._rootNode.quaternion=Y.vec3PairToQuaternion(sk,e,ok)}},{key:"_setSectionPlaneDir",value:function(e){this._sectionPlane&&(this._ignoreNextSectionPlaneDirUpdate=!0,this._sectionPlane.dir=e)}},{key:"setVisible",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];if(this._visible!==e){var t;for(t in this._visible=e,this._displayMeshes)this._displayMeshes.hasOwnProperty(t)&&(this._displayMeshes[t].visible=e);if(!e)for(t in this._affordanceMeshes)this._affordanceMeshes.hasOwnProperty(t)&&(this._affordanceMeshes[t].visible=e)}}},{key:"getVisible",value:function(){return this._visible}},{key:"setCulled",value:function(e){var t;for(t in this._displayMeshes)this._displayMeshes.hasOwnProperty(t)&&(this._displayMeshes[t].culled=e);if(!e)for(t in this._affordanceMeshes)this._affordanceMeshes.hasOwnProperty(t)&&(this._affordanceMeshes[t].culled=e)}},{key:"_bindEvents",value:function(){var e=this,t=this,i=!1,r=-1,n=0,s=1,o=2,a=3,l=4,u=5,c=this._rootNode,h=null,A=null,d=Y.vec2(),p=Y.vec3([1,0,0]),f=Y.vec3([0,1,0]),g=Y.vec3([0,0,1]),m=this._viewer.scene.canvas.canvas,v=this._viewer.camera,_=this._viewer.scene,y=Y.vec3([0,0,0]),b=-1;this._onCameraViewMatrix=_.camera.on("viewMatrix",function(){}),this._onCameraProjMatrix=_.camera.on("projMatrix",function(){}),this._onSceneTick=_.on("tick",function(){var t=Math.abs(Y.lenVec3(Y.subVec3(_.camera.eye,e._pos,y)));t!==b&&"perspective"===v.projection&&(Math.tan(v.perspective.fov*Y.DEGTORAD),b=t),"ortho"===v.projection&&(v.ortho.scale,b=t)});var w,x,B,P,C,M=function(){var e=new Float64Array(2);return function(t){if(t){for(var i=t.target,r=0,n=0;i.offsetParent;)r+=i.offsetLeft,n+=i.offsetTop,i=i.offsetParent;e[0]=t.pageX-r,e[1]=t.pageY-n}else t=window.event,e[0]=t.x,e[1]=t.y;return e}}(),k=function(){var e=new Float64Array(2);return function(t){if(t||(t=window.event),t.touches&&t.touches.length)e[0]=t.touches[0].pageX,e[1]=t.touches[0].pageY;else{for(var i=t.target,r=0,n=0;i.offsetParent;)r+=i.offsetLeft,n+=i.offsetTop,i=i.offsetParent;e[0]=t.pageX-r,e[1]=t.pageY-n}return e}}(),E=function(){var e=Y.mat4();return function(i,r){return Y.quaternionToMat4(t._rootNode.quaternion,e),Y.transformVec3(e,i,r),Y.normalizeVec3(r),r}}(),S=(w=Y.vec3(),function(e){var t=Math.abs(e[0]);return t>Math.abs(e[1])&&t>Math.abs(e[2])?Y.cross3Vec3(e,[0,1,0],w):Y.cross3Vec3(e,[1,0,0],w),Y.cross3Vec3(w,e,w),Y.normalizeVec3(w),w}),T=(x=Y.vec3(),B=Y.vec3(),P=Y.vec4(),function(e,i,r){E(e,P);var n=S(P,i,r);F(i,n,x),F(r,n,B),Y.subVec3(B,x);var s=Y.dotVec3(B,P);t._pos[0]+=P[0]*s*.6,t._pos[1]+=P[1]*s*.6,t._pos[2]+=P[2]*s*.6,t._rootNode.position=t._pos,t._sectionPlane&&(t._sectionPlane.pos=t._pos)}),I=function(){var e=Y.vec4(),i=Y.vec4(),r=Y.vec4(),n=Y.vec4();return function(s,o,a){if(E(s,n),!(F(o,n,e)&&F(a,n,i))){var l=S(n,o,a);F(o,l,e,1),F(a,l,i,1);var u=Y.dotVec3(e,n);e[0]-=u*n[0],e[1]-=u*n[1],e[2]-=u*n[2],u=Y.dotVec3(i,n),i[0]-=u*n[0],i[1]-=u*n[1],i[2]-=u*n[2]}Y.normalizeVec3(e),Y.normalizeVec3(i),u=Y.dotVec3(e,i),u=Y.clamp(u,-1,1);var c=Math.acos(u)*Y.RADTODEG;Y.cross3Vec3(e,i,r),Y.dotVec3(r,n)<0&&(c=-c),t._rootNode.rotate(s,c),D()}}(),F=function(){var e=Y.vec4([0,0,0,1]),i=Y.mat4();return function(r,n,s,o){o=o||0,e[0]=r[0]/m.width*2-1,e[1]=-(r[1]/m.height*2-1),e[2]=0,e[3]=1,Y.mulMat4(v.projMatrix,v.viewMatrix,i),Y.inverseMat4(i),Y.transformVec4(i,e,e),Y.mulVec4Scalar(e,1/e[3]);var a=v.eye;Y.subVec4(e,a,e);var l=t._sectionPlane.pos,u=-Y.dotVec3(l,n)-o,c=Y.dotVec3(n,e);if(Math.abs(c)>.005){var h=-(Y.dotVec3(n,a)+u)/c;return Y.mulVec3Scalar(e,h,s),Y.addVec3(s,a),Y.subVec3(s,l,s),!0}return!1}}(),D=function(){var e=Y.vec3(),i=Y.mat4();return function(){t.sectionPlane&&(Y.quaternionToMat4(c.quaternion,i),Y.transformVec3(i,[0,0,1],e),t._setSectionPlaneDir(e))}}(),R=!1;this._onCameraControlHover=this._viewer.cameraControl.on("hoverEnter",function(t){if(e._visible&&!R){var u;switch(i=!1,C&&(C.visible=!1),t.entity.id){case e._displayMeshes.xAxisArrowHandle.id:case e._displayMeshes.xAxisHandle.id:u=e._affordanceMeshes.xAxisArrow,h=n;break;case e._displayMeshes.yAxisArrowHandle.id:case e._displayMeshes.yShaftHandle.id:u=e._affordanceMeshes.yAxisArrow,h=s;break;case e._displayMeshes.zAxisArrowHandle.id:case e._displayMeshes.zAxisHandle.id:u=e._affordanceMeshes.zAxisArrow,h=o;break;case e._displayMeshes.xCurveHandle.id:u=e._affordanceMeshes.xHoop,h=a;break;case e._displayMeshes.yCurveHandle.id:u=e._affordanceMeshes.yHoop,h=l;break;default:return void(h=r)}u&&(u.visible=!0),C=u,i=!0}}),this._onCameraControlHoverLeave=this._viewer.cameraControl.on("hoverOut",function(t){e._visible&&(C&&(C.visible=!1),C=null,h=r,i=!1)}),m.addEventListener("mousedown",this._canvasMouseDownListener=function(t){if(t.preventDefault(),e._visible&&i&&(e._viewer.cameraControl.pointerEnabled=!1,1===t.which)){R=!0;var r=M(t);A=h,d[0]=r[0],d[1]=r[1],e.plugin.fire("clickPlaneStart")}}),m.addEventListener("mousemove",this._canvasMouseMoveListener=function(t){if(e._visible&&R&&i){var r=M(t),c=r[0],h=r[1];switch(A){case n:T(p,d,r);break;case s:T(f,d,r);break;case o:T(g,d,r);break;case a:I(p,d,r);break;case l:I(f,d,r);break;case u:I(g,d,r)}d[0]=c,d[1]=h}}),m.addEventListener("mouseup",this._canvasMouseUpListener=function(t){e._visible&&(e._viewer.cameraControl.pointerEnabled=!0,R&&(R=!1,i=!1,e.plugin.fire("clickPlaneEnd")))}),m.addEventListener("wheel",this._canvasWheelListener=function(t){if(e._visible)Math.max(-1,Math.min(1,40*-t.deltaY))}),this._onCameraControlHover=this._viewer.cameraControl.on("touchEntity",function(t){if(e._visible&&!R&&!i){var u;switch(i=!1,C&&(C.visible=!1),t.entity.id){case e._displayMeshes.xAxisArrowHandle.id:case e._displayMeshes.xAxisHandle.id:u=e._affordanceMeshes.xAxisArrow,h=n;break;case e._displayMeshes.yAxisArrowHandle.id:case e._displayMeshes.yShaftHandle.id:u=e._affordanceMeshes.yAxisArrow,h=s;break;case e._displayMeshes.zAxisArrowHandle.id:case e._displayMeshes.zAxisHandle.id:u=e._affordanceMeshes.zAxisArrow,h=o;break;case e._displayMeshes.xCurveHandle.id:u=e._affordanceMeshes.xHoop,h=a;break;case e._displayMeshes.yCurveHandle.id:u=e._affordanceMeshes.yHoop,h=l;break;default:return void(h=r)}u&&(u.visible=!0),C=u,i=!0}}),m.addEventListener("touchstart",this._canvasMouseDownListener=function(t){if(t.preventDefault(),e._visible&&i){e._viewer.cameraControl.pointerEnabled=!1,R=!0;var r=k(t);A=h,d[0]=r[0],d[1]=r[1],e.plugin.fire("touchPlaneStart")}}),m.addEventListener("touchmove",this._canvasMouseMoveListener=function(t){if(e._visible&&R){var i=k(t),r=i[0],c=i[1];switch(A){case n:T(p,d,i);break;case s:T(f,d,i);break;case o:T(g,d,i);break;case a:I(p,d,i);break;case l:I(f,d,i);break;case u:I(g,d,i)}d[0]=r,d[1]=c}}),m.addEventListener("touchend",this._canvasTouchEndListener=function(t){e._visible&&(e._viewer.cameraControl.pointerEnabled=!0,C&&(C.visible=!1),C=null,h=r,R=!1,i=!1,e.plugin.fire("touchPlaneEnd"))}),m.addEventListener("touchcancel",this._canvasTouchEndListener)}},{key:"_destroy",value:function(){this._unbindEvents(),this._destroyNodes()}},{key:"_unbindEvents",value:function(){var e=this._viewer,t=e.scene,i=t.canvas.canvas,r=e.camera,n=e.cameraControl;t.off(this._onSceneTick),i.removeEventListener("mousedown",this._canvasMouseDownListener),i.removeEventListener("mousemove",this._canvasMouseMoveListener),i.removeEventListener("mouseup",this._canvasMouseUpListener),i.removeEventListener("wheel",this._canvasWheelListener),i.removeEventListener("touchend",this._canvasTouchEndListener),i.removeEventListener("touchcancel",this._canvasTouchEndListener),r.off(this._onCameraViewMatrix),r.off(this._onCameraProjMatrix),n.off(this._onCameraControlHover),n.off(this._onCameraControlHoverLeave)}},{key:"_destroyNodes",value:function(){this._setSectionPlane(null),this._rootNode.destroy(),this._displayMeshes={},this._affordanceMeshes={}}}])}(),lk=new Float64Array([0,0,1]),uk=new Float64Array(4),ck=function(){return P(function e(t,i){x(this,e),this.id=i.id,this.type="plane",this.plugin=t,this._viewer=t.viewer,this._scene=t.viewer.scene,i?(this._controlFillColor=i.controlFillColor?i.controlFillColor:[.3,.6,1],this._planeSize=i.planeSize?i.planeSize:1,this._controlSize=i.controlSize?i.controlSize:.07,this._planeOpacity=i.planeOpacity?i.planeOpacity:.4,this._enableClip=!!i.enableClip):(this._controlFillColor=[.3,.6,1],this._planeSize=1,this._controlSize=.07,this._planeOpacity=.4,this._enableClip=!1),this._visible=!1,this._pos=Y.vec3(),this._origin=Y.vec3(),this._rtcPos=Y.vec3(),this._baseDir=Y.vec3(),this._rootNode=null,this._displayMeshes=null,this._affordanceMeshes=null,this._ignoreNextSectionPlaneDirUpdate=!1},[{key:"_createNodes",value:function(){var e=!1,t=this._viewer.scene;this._rootNode=new yn(t,{id:this.id,position:[0,0,0],scale:[1,1,1],isObject:!1});var i,r,n=this._rootNode,s=t.aabb,o=s[3]-s[0],a=s[4]-s[1],l=s[5]-s[2];0!=this.dir[0]?(i=l>0?1*l:1*l*-1,r=a>0?1*a:1*a*-1):0!=this.dir[1]?(i=o>0?1*o:1*o*-1,r=l>0?1*l:1*l*-1):0!=this.dir[2]&&(i=o>0?1*o:1*o*-1,r=a>0?1*a:1*a*-1),i+=0,r+=0,this._displayMeshes={plane:n.addChild(new on(n,{geometry:new Ci(n,{primitive:"triangles",positions:[i/2,r/2,.01,i/2,-r/2,.01,-i/2,-r/2,.01,-i/2,r/2,.01],indices:[0,1,2,2,3,0]}),material:new Ti(n,{emissive:[.1,.1,.1],diffuse:this._controlFillColor,backfaces:!0}),opacity:this._planeOpacity,ghosted:!0,ghostMaterial:new Fi(n,{edges:!1,filled:!0,fillColor:this._controlFillColor,fillAlpha:.1,backfaces:!0}),pickable:this.pickable,collidable:!1,clippable:this._enableClip,visible:!1,scale:[1*this._planeSize,1*this._planeSize,1*this._planeSize],isObject:!1}),e)},this._affordanceMeshes={plane:n.addChild(new on(n,{geometry:new Ci(n,{primitive:"triangles",positions:[i/2,r/2,.012,i/2,-r/2,.012,-i/2,-r/2,.012,-i/2,r/2,.012],indices:[0,1,2,2,3,0]}),material:new Ti(n,{emissive:[.6,.6,5],diffuse:this._controlFillColor,backfaces:!0}),opacity:this._planeOpacity,ghosted:!0,ghostMaterial:new Fi(n,{edges:!1,filled:!0,fillColor:this._controlFillColor,fillAlpha:.1,backfaces:!0}),pickable:!0,collidable:!1,clippable:!0,visible:!1,scale:[1*this._planeSize,1*this._planeSize,1*this._planeSize],isObject:!1}),e)}}},{key:"_setSectionPlane",value:function(e){var t=this;this._sectionPlane&&(this._sectionPlane.off(this._onSectionPlanePos),this._sectionPlane.off(this._onSectionPlaneDir),this._onSectionPlanePos=null,this._onSectionPlaneDir=null,this._sectionPlane=null),e&&(this.id=e.controlId,this.dir=e.dir,this._createNodes(),this._bindEvents(),this._setPos(e.pos),this._setDir(e.dir),this._sectionPlane=e,e.control=this,this._onSectionPlanePos=e.on("pos",function(){t._setPos(t._sectionPlane.pos)}),this._onSectionPlaneDir=e.on("dir",function(){t._ignoreNextSectionPlaneDirUpdate?t._ignoreNextSectionPlaneDirUpdate=!1:t._setDir(t._sectionPlane.dir)}))}},{key:"sectionPlane",get:function(){return this._sectionPlane}},{key:"pos",get:function(){return this._pos},set:function(e){if(!(e<0||e>100)){var t=this._scene.aabb,i=this._scene.center,r=t[3]-t[0],n=t[4]-t[1],s=t[5]-t[2],o=Y.vec3();o[0]=this.pos[0],o[1]=this.pos[1],o[2]=this.pos[2];var a,l=this._sectionPlane.dir;0!=l[0]?(a=e/100*r,o[0]=i[0]-r/2+a):0!=l[1]?(a=e/100*n,o[1]=i[1]-n/2+a):0!=l[2]&&(a=e/100*s,o[2]=i[2]-s/2+a),this._sectionPlane.pos=o}}},{key:"posRate",get:function(){var e=this._scene.aabb,t=this._scene.center,i=e[3]-e[0],r=e[4]-e[1],n=e[5]-e[2],s=this._sectionPlane.pos,o=this._sectionPlane.dir,a=0;if(0!=o[0])a=(s[0]-(t[0]-i/2))/i*100;else if(0!=o[1]){a=(s[1]-(t[1]-r/2))/r*100}else if(0!=o[2]){a=(s[2]-(t[2]-n/2))/n*100}return a=Math.max(0,Math.min(100,a)),parseInt(a)}},{key:"_setPos",value:function(e){this._pos.set(e),be(this._pos,this._origin,this._rtcPos),this._rootNode.origin=this._origin,this._rootNode.position=this._rtcPos}},{key:"_setDir",value:function(e){this._baseDir.set(e),this._rootNode.quaternion=Y.vec3PairToQuaternion(lk,e,uk)}},{key:"_setSectionPlaneDir",value:function(e){this._sectionPlane&&(this._ignoreNextSectionPlaneDirUpdate=!0,this._sectionPlane.dir=e)}},{key:"setVisible",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];if(this._visible!==e){var t;for(t in this._visible=e,this._displayMeshes)this._displayMeshes.hasOwnProperty(t)&&(this._displayMeshes[t].visible=e);if(!e)for(t in this._affordanceMeshes)this._affordanceMeshes.hasOwnProperty(t)&&(this._affordanceMeshes[t].visible=e)}}},{key:"getVisible",value:function(){return this._visible}},{key:"setCulled",value:function(e){var t;for(t in this._displayMeshes)this._displayMeshes.hasOwnProperty(t)&&(this._displayMeshes[t].culled=e);if(!e)for(t in this._affordanceMeshes)this._affordanceMeshes.hasOwnProperty(t)&&(this._affordanceMeshes[t].culled=e)}},{key:"_bindEvents",value:function(){var e=this,t=this,i=!1,r=-1,n=0,s=1,o=2;this._rootNode;var a=null,l=null,u=Y.vec2();this.lastCanvasPos=u;var c=Y.vec3([1,0,0]),h=Y.vec3([0,1,0]),A=Y.vec3([0,0,1]),d=this._viewer.scene.canvas.canvas,p=this._viewer.camera,f=this._viewer.scene;this._onCameraViewMatrix=f.camera.on("viewMatrix",function(){}),this._onCameraProjMatrix=f.camera.on("projMatrix",function(){});var g,m,v,_,y,b=function(){var e=new Float64Array(2);return function(t){if(t){for(var i=t.target,r=0,n=0;i.offsetParent;)r+=i.offsetLeft,n+=i.offsetTop,i=i.offsetParent;e[0]=t.pageX-r,e[1]=t.pageY-n}else t=window.event,e[0]=t.x,e[1]=t.y;return e}}(),w=function(){var e=Y.mat4();return function(i,r){return Y.quaternionToMat4(t._rootNode.quaternion,e),Y.transformVec3(e,i,r),Y.normalizeVec3(r),r}}(),x=(g=Y.vec3(),function(e){var t=Math.abs(e[0]);return t>Math.abs(e[1])&&t>Math.abs(e[2])?Y.cross3Vec3(e,[0,1,0],g):Y.cross3Vec3(e,[1,0,0],g),Y.cross3Vec3(g,e,g),Y.normalizeVec3(g),g}),B=(m=Y.vec3(),v=Y.vec3(),_=Y.vec4(),function(e,i,r){w(e,_);var n=x(_,i,r);P(i,n,m),P(r,n,v),Y.subVec3(v,m);var s,o=Y.dotVec3(v,_),a=t._sectionPlane.dir,l=t._sectionPlane.planeId,u=t._sectionPlane.posRangeMin;if(s=t._sectionPlane.box.boxRanges[(l+3)%6],0!=a[0]){if(a[0]>0){if(s=t._sectionPlane.box.boxRanges[(l+3)%6],t._pos[0]+_[0]*o*.6<u[0]||t._pos[0]+_[0]*o*.6>s[0]-.3)return}else if(t._pos[0]+_[0]*o*.6>u[0]||t._pos[0]+_[0]*o*.6<s[0]+.3)return}else if(0!=a[1]){if(a[1]>0){if(t._pos[1]+_[1]*o*.6<u[1]||t._pos[1]+_[1]*o*.6>s[1]-.3)return}else if(t._pos[1]+_[1]*o*.6>u[1]||t._pos[1]+_[1]*o*.6<s[1]+.3)return}else if(0!=a[2])if(a[2]>0){if(t._pos[2]+_[2]*o*.6<u[2]||t._pos[2]+_[2]*o*.6>s[2]-.3)return}else if(t._pos[2]+_[2]*o*.6>u[2]||t._pos[2]+_[2]*o*.6<s[2]+.3)return;t._pos[0]+=_[0]*o*.6,t._pos[1]+=_[1]*o*.6,t._pos[2]+=_[2]*o*.6,t._rootNode.position=t._pos,t._sectionPlane&&(t._sectionPlane.pos=t._pos)}),P=function(){var e=Y.vec4([0,0,0,1]),i=Y.mat4();return function(r,n,s,o){o=o||0,e[0]=r[0]/d.width*2-1,e[1]=-(r[1]/d.height*2-1),e[2]=0,e[3]=1,Y.mulMat4(p.projMatrix,p.viewMatrix,i),Y.inverseMat4(i),Y.transformVec4(i,e,e),Y.mulVec4Scalar(e,1/e[3]);var a=p.eye;Y.subVec4(e,a,e);var l=t._sectionPlane.pos,u=-Y.dotVec3(l,n)-o,c=Y.dotVec3(n,e);if(Math.abs(c)>.005){var h=-(Y.dotVec3(n,a)+u)/c;return Y.mulVec3Scalar(e,h,s),Y.addVec3(s,a),Y.subVec3(s,l,s),!0}return!1}}(),C=!1;this._onCameraControlHover=this._viewer.cameraControl.on("hoverEnter",function(t){var n;e._visible&&(C||(i=!1,y&&(y.visible=!1),t.entity.id===e._displayMeshes.plane.id?(n=e._affordanceMeshes.plane,a=o,n&&(n.visible=!0),y=n,i=!0):a=r))}),this._onCameraControlHoverLeave=this._viewer.cameraControl.on("hoverOut",function(t){e._visible&&(y&&(y.visible=!1),a=r,i=!1)}),d.addEventListener("mousedown",this._canvasMouseDownListener=function(t){if(t.preventDefault(),e._visible&&i&&(e._viewer.cameraControl.pointerEnabled=!1,1===t.which)){C=!0;var r=b(t);l=a,u[0]=r[0],u[1]=r[1],e.plugin.fire("clickPlaneStart")}}),d.addEventListener("mousemove",this._canvasMouseMoveListener=function(t){if(e._visible&&C){var i=b(t),r=i[0],a=i[1];switch(l){case n:B(c,u,i);break;case s:B(h,u,i);break;case o:B(A,u,i)}u[0]=r,u[1]=a}}),d.addEventListener("mouseup",this._canvasMouseUpListener=function(t){e._visible&&(e._viewer.cameraControl.pointerEnabled=!0,C&&(C=!1,i=!1,e.plugin.fire("clickPlaneEnd")))}),d.addEventListener("wheel",this._canvasWheelListener=function(t){if(e._visible)Math.max(-1,Math.min(1,40*-t.deltaY))})}},{key:"_destroy",value:function(){this._unbindEvents(),this._destroyNodes()}},{key:"_unbindEvents",value:function(){var e=this._viewer,t=e.scene,i=t.canvas.canvas,r=e.camera,n=e.cameraControl;t.off(this._onSceneTick),i.removeEventListener("mousedown",this._canvasMouseDownListener),i.removeEventListener("mousemove",this._canvasMouseMoveListener),i.removeEventListener("mouseup",this._canvasMouseUpListener),i.removeEventListener("wheel",this._canvasWheelListener),i.removeEventListener("touchend",this._canvasTouchEndListener),i.removeEventListener("touchcancel",this._canvasTouchEndListener),r.off(this._onCameraViewMatrix),r.off(this._onCameraProjMatrix),n.off(this._onCameraControlHover),n.off(this._onCameraControlHoverLeave)}},{key:"_destroyNodes",value:function(){this._setSectionPlane(null),this._rootNode.destroy(),this._displayMeshes={},this._affordanceMeshes={}}}])}(),hk=new Float64Array([0,0,1]),Ak=new Float64Array(4),dk=function(){return P(function e(t,i){x(this,e),this.id=null,this.type="plane",this.plugin=t,this._viewer=t.viewer,this._scene=t.viewer.scene,this._controlFillColor=i&&i.controlFillColor?i.controlFillColor:[.1,.4,.99],this._planeSize=i&&i.planeSize?i.planeSize:1,this._controlSize=i&&i.controlSize?i.controlSize:.07,this._planeOpacity=i&&i.planeOpacity?i.planeOpacity:.4,this._visible=!1,this._pos=Y.vec3(),this._origin=Y.vec3(),this._rtcPos=Y.vec3(),this._baseDir=Y.vec3(),this._rootNode=null,this._displayMeshes=null,this._affordanceMeshes=null,this._ignoreNextSectionPlaneDirUpdate=!1,this._createNodes(),this._bindEvents()},[{key:"_createNodes",value:function(){var e=this._viewer.scene;this._rootNode=new yn(e,{position:[0,0,0],scale:[5,5,5],isObject:!1});var t=this._rootNode;this._displayMeshes={plane:t.addChild(new on(t,{geometry:new Ci(t,{primitive:"triangles",positions:[.5,.5,.02,.5,-.5,.02,-.5,-.5,.02,-.5,.5,.02],indices:[0,1,2,2,3,0]}),material:new Ti(t,{emissive:[0,0,0],diffuse:this._controlFillColor,backfaces:!0}),opacity:this._planeOpacity,ghosted:!0,ghostMaterial:new Fi(t,{edges:!1,filled:!0,fillColor:this._controlFillColor?this._controlFillColor:[.1,.4,.99],fillAlpha:.1,backfaces:!0}),pickable:!0,collidable:!1,clippable:!1,visible:!1,scale:[2.4*this._planeSize,2.4*this._planeSize,1*this._planeSize],isObject:!1}),!1)},this._affordanceMeshes={}}},{key:"_setSectionPlane",value:function(e){var t=this;this._sectionPlane&&(this._sectionPlane.off(this._onSectionPlanePos),this._sectionPlane.off(this._onSectionPlaneDir),this._onSectionPlanePos=null,this._onSectionPlaneDir=null,this._sectionPlane=null),e&&(this.id=e.id,this._setPos(e.pos),this._setDir(e.dir),this._sectionPlane=e,e.control=this,this._onSectionPlanePos=e.on("pos",function(){t._setPos(t._sectionPlane.pos)}),this._onSectionPlaneDir=e.on("dir",function(){t._ignoreNextSectionPlaneDirUpdate?t._ignoreNextSectionPlaneDirUpdate=!1:t._setDir(t._sectionPlane.dir)}))}},{key:"sectionPlane",get:function(){return this._sectionPlane}},{key:"pos",get:function(){return this._pos},set:function(e){if(!(e<0||e>100)){var t=this._scene.aabb,i=this._scene.center,r=t[3]-t[0],n=t[4]-t[1],s=t[5]-t[2],o=Y.vec3();o[0]=this.pos[0],o[1]=this.pos[1],o[2]=this.pos[2];var a,l=this._sectionPlane.dir;0!=l[0]?(a=e/100*r,o[0]=i[0]-r/2+a):0!=l[1]?(a=e/100*n,o[1]=i[1]-n/2+a):0!=l[2]&&(a=e/100*s,o[2]=i[2]-s/2+a),this._sectionPlane.pos=o}}},{key:"posRate",get:function(){var e=this._scene.aabb,t=this._scene.center,i=e[3]-e[0],r=e[4]-e[1],n=e[5]-e[2],s=this._sectionPlane.pos,o=this._sectionPlane.dir,a=0;if(0!=o[0])a=(s[0]-(t[0]-i/2))/i*100;else if(0!=o[1]){a=(s[1]-(t[1]-r/2))/r*100}else if(0!=o[2]){a=(s[2]-(t[2]-n/2))/n*100}return a=Math.max(0,Math.min(100,a)),parseInt(a)}},{key:"_setPos",value:function(e){this._pos.set(e),be(this._pos,this._origin,this._rtcPos),this._rootNode.origin=this._origin,this._rootNode.position=this._rtcPos}},{key:"_setDir",value:function(e){this._baseDir.set(e),this._rootNode.quaternion=Y.vec3PairToQuaternion(hk,e,Ak)}},{key:"_setSectionPlaneDir",value:function(e){this._sectionPlane&&(this._ignoreNextSectionPlaneDirUpdate=!0,this._sectionPlane.dir=e)}},{key:"setVisible",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];if(this._visible!==e){var t;for(t in this._visible=e,this._displayMeshes)this._displayMeshes.hasOwnProperty(t)&&(this._displayMeshes[t].visible=e);if(!e)for(t in this._affordanceMeshes)this._affordanceMeshes.hasOwnProperty(t)&&(this._affordanceMeshes[t].visible=e)}}},{key:"getVisible",value:function(){return this._visible}},{key:"setCulled",value:function(e){var t;for(t in this._displayMeshes)this._displayMeshes.hasOwnProperty(t)&&(this._displayMeshes[t].culled=e);if(!e)for(t in this._affordanceMeshes)this._affordanceMeshes.hasOwnProperty(t)&&(this._affordanceMeshes[t].culled=e)}},{key:"_bindEvents",value:function(){var e=this,t=this,i=!1,r=-1,n=0,s=1,o=2;this._rootNode;var a=null,l=null,u=Y.vec2();this.lastCanvasPos=u;var c=Y.vec3([1,0,0]),h=Y.vec3([0,1,0]),A=Y.vec3([0,0,1]),d=this._viewer.scene.canvas.canvas,p=this._viewer.camera,f=this._viewer.scene,g=Y.vec3([0,0,0]),m=-1;this._onCameraViewMatrix=f.camera.on("viewMatrix",function(){}),this._onCameraProjMatrix=f.camera.on("projMatrix",function(){}),this._onSceneTick=f.on("tick",function(){var t=Math.abs(Y.lenVec3(Y.subVec3(f.camera.eye,e._pos,g)));t!==m&&"perspective"===p.projection&&(Math.tan(p.perspective.fov*Y.DEGTORAD),m=t),"ortho"===p.projection&&(p.ortho.scale,m=t)});var v,_,y,b,w=function(){var e=new Float64Array(2);return function(t){if(t){for(var i=t.target,r=0,n=0;i.offsetParent;)r+=i.offsetLeft,n+=i.offsetTop,i=i.offsetParent;e[0]=t.pageX-r,e[1]=t.pageY-n}else t=window.event,e[0]=t.x,e[1]=t.y;return e}}(),x=function(){var e=new Float64Array(2);return function(t){if(t||(t=window.event),t.touches&&t.touches.length)e[0]=t.touches[0].pageX,e[1]=t.touches[0].pageY;else{for(var i=t.target,r=0,n=0;i.offsetParent;)r+=i.offsetLeft,n+=i.offsetTop,i=i.offsetParent;e[0]=t.pageX-r,e[1]=t.pageY-n}return e}}(),B=function(){var e=Y.mat4();return function(i,r){return Y.quaternionToMat4(t._rootNode.quaternion,e),Y.transformVec3(e,i,r),Y.normalizeVec3(r),r}}(),P=(v=Y.vec3(),function(e){var t=Math.abs(e[0]);return t>Math.abs(e[1])&&t>Math.abs(e[2])?Y.cross3Vec3(e,[0,1,0],v):Y.cross3Vec3(e,[1,0,0],v),Y.cross3Vec3(v,e,v),Y.normalizeVec3(v),v}),C=(_=Y.vec3(),y=Y.vec3(),b=Y.vec4(),function(e,i,r){B(e,b);var n=P(b,i,r);M(i,n,_),M(r,n,y),Y.subVec3(y,_);var s=Y.dotVec3(y,b);t._pos[0]+=b[0]*s*.6,t._pos[1]+=b[1]*s*.6,t._pos[2]+=b[2]*s*.6,t._rootNode.position=t._pos,t._sectionPlane&&(t._sectionPlane.pos=t._pos)}),M=function(){var e=Y.vec4([0,0,0,1]),i=Y.mat4();return function(r,n,s,o){o=o||0,e[0]=r[0]/d.width*2-1,e[1]=-(r[1]/d.height*2-1),e[2]=0,e[3]=1,Y.mulMat4(p.projMatrix,p.viewMatrix,i),Y.inverseMat4(i),Y.transformVec4(i,e,e),Y.mulVec4Scalar(e,1/e[3]);var a=p.eye;Y.subVec4(e,a,e);var l=t._sectionPlane.pos,u=-Y.dotVec3(l,n)-o,c=Y.dotVec3(n,e);if(Math.abs(c)>.005){var h=-(Y.dotVec3(n,a)+u)/c;return Y.mulVec3Scalar(e,h,s),Y.addVec3(s,a),Y.subVec3(s,l,s),!0}return!1}}(),k=!1;this._onCameraControlHover=this._viewer.cameraControl.on("hoverEnter",function(t){e._visible&&(k||(i=!1,t.entity.id===e._displayMeshes.plane.id?(a=o,i=!0):a=r))}),this._onCameraControlHoverLeave=this._viewer.cameraControl.on("hoverOut",function(t){e._visible&&(a=r,i=!1)}),d.addEventListener("mousedown",this._canvasMouseDownListener=function(t){if(t.preventDefault(),e._visible&&i&&(e._viewer.cameraControl.pointerEnabled=!1,1===t.which)){k=!0;var r=w(t);l=a,u[0]=r[0],u[1]=r[1],e.plugin.fire("clickPlaneStart")}}),d.addEventListener("mousemove",this._canvasMouseMoveListener=function(t){if(e._visible&&k){var i=w(t),r=i[0],a=i[1];switch(l){case n:C(c,u,i);break;case s:C(h,u,i);break;case o:C(A,u,i)}u[0]=r,u[1]=a}}),d.addEventListener("mouseup",this._canvasMouseUpListener=function(t){e._visible&&(e._viewer.cameraControl.pointerEnabled=!0,k&&(t.which,k=!1,i=!1,e.plugin.fire("clickPlaneEnd")))}),d.addEventListener("wheel",this._canvasWheelListener=function(t){if(e._visible)Math.max(-1,Math.min(1,40*-t.deltaY))}),this._onCameraControlHover=this._viewer.cameraControl.on("touchEntity",function(t){var n;!e._visible||k||i||(t.entity.id===e._displayMeshes.plane.id?(n=e._affordanceMeshes.plane,a=o,n&&(n.visible=!0),i=!0,k=!0):a=r)}),d.addEventListener("touchstart",this._canvasMouseDownListener=function(t){if(t.preventDefault(),e._visible&&i&&k){e._viewer.cameraControl.pointerEnabled=!1;var r=x(t);l=a,u[0]=r[0],u[1]=r[1],e.plugin.fire("touchPlaneStart")}}),d.addEventListener("touchmove",this._canvasMouseMoveListener=function(t){if(e._visible&&k&&i){var r=x(t),a=r[0],d=r[1];switch(l){case n:C(c,u,r);break;case s:C(h,u,r);break;case o:C(A,u,r)}u[0]=a,u[1]=d}}),d.addEventListener("touchend",this._canvasTouchEndListener=function(t){e._visible&&(i&&(e._viewer.cameraControl.pointerEnabled=!0),a=r,k=!1,i=!1,e.plugin.fire("touchPlaneEnd"))}),d.addEventListener("touchcancel",this._canvasTouchEndListener)}},{key:"_destroy",value:function(){this._unbindEvents(),this._destroyNodes()}},{key:"_unbindEvents",value:function(){var e=this._viewer,t=e.scene,i=t.canvas.canvas,r=e.camera,n=e.cameraControl;t.off(this._onSceneTick),i.removeEventListener("mousedown",this._canvasMouseDownListener),i.removeEventListener("mousemove",this._canvasMouseMoveListener),i.removeEventListener("mouseup",this._canvasMouseUpListener),i.removeEventListener("wheel",this._canvasWheelListener),i.removeEventListener("touchend",this._canvasTouchEndListener),i.removeEventListener("touchcancel",this._canvasTouchEndListener),r.off(this._onCameraViewMatrix),r.off(this._onCameraProjMatrix),n.off(this._onCameraControlHover),n.off(this._onCameraControlHoverLeave)}},{key:"_destroyNodes",value:function(){this._setSectionPlane(null),this._rootNode.destroy(),this._displayMeshes={},this._affordanceMeshes={}}}])}(),pk=function(){return P(function e(t,i,r){var n=this;x(this,e),this.id=r.id,this._sectionPlane=r,this._mesh=new on(i,{id:r.id,geometry:new Ci(i,Mi({xSize:.5,ySize:.5,zSize:.001})),material:new Ti(i,{emissive:[1,1,1],diffuse:[0,0,0],backfaces:!1}),edgeMaterial:new Ri(i,{edgeColor:[0,0,0],edgeAlpha:1,edgeWidth:1}),highlightMaterial:new Fi(i,{fill:!0,fillColor:[.5,1,.5],fillAlpha:.7,edges:!0,edgeColor:[0,0,0],edgeAlpha:1,edgeWidth:1}),selectedMaterial:new Fi(i,{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});var s=Y.vec3([0,0,0]),o=Y.vec3(),a=Y.vec3([0,0,1]),l=Y.vec4(4),u=Y.vec3(),c=function(){var e=n._sectionPlane.scene.center,t=[-n._sectionPlane.dir[0],-n._sectionPlane.dir[1],-n._sectionPlane.dir[2]];Y.subVec3(e,n._sectionPlane.pos,s);var i=-Y.dotVec3(t,s);Y.normalizeVec3(t),Y.mulVec3Scalar(t,i,o);var r=Y.vec3PairToQuaternion(a,n._sectionPlane.dir,l);u[0]=.1*o[0],u[1]=.1*o[1],u[2]=.1*o[2],n._mesh.quaternion=r,n._mesh.position=u};this._onSectionPlanePos=this._sectionPlane.on("pos",c),this._onSectionPlaneDir=this._sectionPlane.on("dir",c),this._highlighted=!1,this._selected=!1},[{key:"setHighlighted",value:function(e){this._highlighted=!!e,this._mesh.highlighted=this._highlighted,this._mesh.highlightMaterial.fillColor=e?[0,.7,0]:[0,0,0]}},{key:"getHighlighted",value:function(){return this._highlighted}},{key:"setSelected",value:function(e){this._selected=!!e,this._mesh.edgeMaterial.edgeWidth=e?3:1,this._mesh.highlightMaterial.edgeWidth=e?3:1}},{key:"getSelected",value:function(){return this._selected}},{key:"destroy",value:function(){this._sectionPlane.off(this._onSectionPlanePos),this._sectionPlane.off(this._onSectionPlaneDir),this._mesh.destroy()}}])}(),fk=function(){return P(function e(t,i,r){var n=this;x(this,e),this.id=sectionPlane.id,this._sectionBox=r,this._mesh=new on(i,{id:sectionPlane.id,geometry:new Ci(i,Mi({xSize:.5,ySize:.5,zSize:.001})),material:new Ti(i,{emissive:[1,1,1],diffuse:[0,0,0],backfaces:!1}),edgeMaterial:new Ri(i,{edgeColor:[0,0,0],edgeAlpha:1,edgeWidth:1}),highlightMaterial:new Fi(i,{fill:!0,fillColor:[.5,1,.5],fillAlpha:.7,edges:!0,edgeColor:[0,0,0],edgeAlpha:1,edgeWidth:1}),selectedMaterial:new Fi(i,{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});var s=Y.vec3([0,0,0]),o=Y.vec3(),a=Y.vec3([0,0,1]),l=Y.vec4(4),u=Y.vec3(),c=function(){var e=n._sectionBox.scene.center,t=[-n._sectionBox.dir[0],-n._sectionBox.dir[1],-n._sectionBox.dir[2]];Y.subVec3(e,n._sectionBox.pos,s);var i=-Y.dotVec3(t,s);Y.normalizeVec3(t),Y.mulVec3Scalar(t,i,o);var r=Y.vec3PairToQuaternion(a,n._sectionBox.dir,l);u[0]=.1*o[0],u[1]=.1*o[1],u[2]=.1*o[2],n._mesh.quaternion=r,n._mesh.position=u};this._onSectionPlanePos=this._sectionBox.on("pos",c),this._onSectionPlaneDir=this._sectionBox.on("dir",c),this._highlighted=!1,this._selected=!1},[{key:"setHighlighted",value:function(e){this._highlighted=!!e,this._mesh.highlighted=this._highlighted,this._mesh.highlightMaterial.fillColor=e?[0,.7,0]:[0,0,0]}},{key:"getHighlighted",value:function(){return this._highlighted}},{key:"setSelected",value:function(e){this._selected=!!e,this._mesh.edgeMaterial.edgeWidth=e?3:1,this._mesh.highlightMaterial.edgeWidth=e?3:1}},{key:"getSelected",value:function(){return this._selected}},{key:"destroy",value:function(){this._sectionBox.off(this._onSectionPlanePos),this._sectionBox.off(this._onSectionPlaneDir),this._mesh.destroy()}}])}(),gk=function(){return P(function e(t,i){var r=this;if(x(this,e),!(i.onHoverEnterPlane&&i.onHoverLeavePlane&&i.onClickedNothing&&i.onClickedPlane))throw"Missing config(s): onHoverEnterPlane, onHoverLeavePlane, onClickedNothing || onClickedPlane";this.plugin=t,this._viewer=t.viewer,this._onHoverEnterPlane=i.onHoverEnterPlane,this._onHoverLeavePlane=i.onHoverLeavePlane,this._onClickedNothing=i.onClickedNothing,this._onClickedPlane=i.onClickedPlane,this._visible=!0,this._planes={},this._box=null,this._canvas=i.overviewCanvas,this._scene=new zi(this._viewer,{canvasId:this._canvas.id,transparent:!0,spinnerElementId:"overviewer_spinner"}),this._scene.clearLights(),new hi(this._scene,{dir:[.4,-.4,.8],color:[.8,1,1],intensity:1,space:"view"}),new hi(this._scene,{dir:[-.8,-.3,-.4],color:[.8,.8,.8],intensity:1,space:"view"}),new hi(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;var n=this._scene.camera,s=Y.rotationMat4c(-90*Y.DEGTORAD,1,0,0),o=Y.vec3(),a=Y.vec3(),l=Y.vec3();this._synchCamera=function(){var e=r._viewer.camera.eye,t=r._viewer.camera.look,i=r._viewer.camera.up;Y.mulVec3Scalar(Y.normalizeVec3(Y.subVec3(e,t,o)),7),r._zUp?(Y.transformVec3(s,o,a),Y.transformVec3(s,i,l),n.look=[0,0,0],n.eye=Y.transformVec3(s,o,a),n.up=Y.transformPoint3(s,i,l)):(n.look=[0,0,0],n.eye=o,n.up=i)},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",function(e){r._scene.camera.perspective.fov=e});var u=null;this._onInputMouseMove=this._scene.input.on("mousemove",function(e){var t=r._scene.pick({canvasPos:e});if(t){if(!u||t.entity.id!==u.id){if(u)r._planes[u.id]&&r._onHoverLeavePlane(u.id);u=t.entity,r._planes[u.id]&&r._onHoverEnterPlane(u.id)}}else u&&(r._onHoverLeavePlane(u.id),u=null)}),this._scene.canvas.canvas.addEventListener("mouseup",this._onCanvasMouseUp=function(){u?r._planes[u.id]&&r._onClickedPlane(u.id):r._onClickedNothing()}),this._scene.canvas.canvas.addEventListener("mouseout",this._onCanvasMouseOut=function(){u&&(r._onHoverLeavePlane(u.id),u=null)}),this.setVisible(i.overviewVisible)},[{key:"addSectionPlane",value:function(e){this._planes[e.id]=new pk(this,this._scene,e)}},{key:"setSectionBox",value:function(e){this._box=new fk(this,this._scene,e)}},{key:"setPlaneHighlighted",value:function(e,t){var i=this._planes[e];i&&i.setHighlighted(t)}},{key:"setPlaneSelected",value:function(e,t){var i=this._planes[e];i&&i.setSelected(t)}},{key:"removeSectionPlane",value:function(e){var t=this._planes[e.id];t&&(t.destroy(),delete this._planes[e.id])}},{key:"setVisible",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];this._visible=e,this._canvas.style.visibility=e?"visible":"hidden"}},{key:"getVisible",value:function(){return this._visible}},{key:"destroy",value:function(){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()}}])}(),mk=function(){return P(function e(t){x(this,e),this._viewer=t.viewer,this._scene=t.viewer.scene,this._sectionPlugin=t,this._boxCenter=[0,0,0],this._maxRange=[],this._createNodes()},[{key:"_createNodes",value:function(){var e=this._viewer.scene,t=e.aabb,i=e.center,r=t[3]-t[0],n=t[4]-t[1],s=t[5]-t[2];this._rootNode=new yn(e,{id:"sectionControl",position:i,scale:[1,1,1],isObject:!1});var o=this._rootNode;this._displayMeshes={box:o.addChild(new on(o,{geometry:new Ci(o,Dn({center:this._boxCenter,xSize:.5*(r>0?r:-1*r)+0,ySize:.5*(n>0?n:-1*n)+0,zSize:.5*(s>0?s:-1*s)+0})),material:new Ti(o,{emissive:[.5,6.5,9.5],diffuse:[.5,6.5,9.5],specular:[.5,.5,.5],alpha:.2,shininess:10}),pickable:!1,collidable:!1,clippable:!1,visible:!0,scale:[1,1,1],isObject:!1}),!1)}}},{key:"updateBox",value:function(e,t){if(!(t.length<6)){var i,r,n;i=t[3][0]-t[0][0],r=t[4][1]-t[1][1],n=t[5][2]-t[2][2];var s=this._getGeometryPoisition(e,i,r,n);this._setGeometryPosition(s)}}},{key:"_getGeometryPoisition",value:function(e,t,i,r){var n=.5,s=this._boxCenter;return 0!=e[0]&&(e[0]<0&&(s[0]-=((t>0?t:-1*t)*n+.2)/4),e[0]>0&&(s[0]+=((t>0?t:-1*t)*n+.2)/4)),0!=e[1]&&(e[1]<0&&(s[1]-=((i>0?i:-1*i)*n+.2)/4),e[1]>0&&(s[1]+=((i>0?i:-1*i)*n+.2)/4)),0!=e[2]&&(e[2]<0&&(s[2]-=((r>0?r:-1*r)*n+.2)/4),e[2]>0&&(s[2]+=((r>0?r:-1*r)*n+.2)/4)),Dn({center:s,xSize:(t>0?t:-1*t)*n+.2,ySize:(i>0?i:-1*i)*n+.2,zSize:(r>0?r:-1*r)*n+.2}).positions}},{key:"_setGeometryPosition",value:function(e){this._displayMeshes.box.geometry.positions=e}},{key:"setVisible",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];if(this._visible!==e){var t;for(t in this._visible=e,this._displayMeshes)this._displayMeshes.hasOwnProperty(t)&&(this._displayMeshes[t].visible=e);if(!e)for(t in this._affordanceMeshes)this._affordanceMeshes.hasOwnProperty(t)&&(this._affordanceMeshes[t].visible=e)}}},{key:"getVisible",value:function(){return this._visible}},{key:"_destroy",value:function(){this._rootNode.destroy(),this._displayMeshes={}}}])}(),vk=Y.AABB3(),_k=Y.vec3(),yk=function(){function e(t){var i,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(x(this,e),(i=d(this,e,["SectionPlanes",t]))._freeControls=[],i._controlBox=null,i._singleCtrlBox=null,i._sectionWay=null,i._sectionPlanes=t.scene.sectionPlanes,i._controls={},i._currentControl=null,i._shownControlId=null,i._shownControlIds=[],i._boxPlaneConfig={id:"",planeId:-1,enableClip:!1,controlFillColor:[3,9,9]},null!==r.overviewCanvasId&&void 0!==r.overviewCanvasId){var n=document.getElementById(r.overviewCanvasId);n?i._overview=new gk(i,{overviewCanvas:n,visible:r.overviewVisible,onHoverEnterPlane:function(e){i._overview.setPlaneHighlighted(e,!0)},onHoverLeavePlane:function(e){i._overview.setPlaneHighlighted(e,!1)},onClickedPlane:function(e){if(i.getShownControl()!==e){i.showControl(e);var t=i.sectionPlanes[e].pos;vk.set(i.viewer.scene.aabb),Y.getAABB3Center(vk,_k),vk[0]+=t[0]-_k[0],vk[1]+=t[1]-_k[1],vk[2]+=t[2]-_k[2],vk[3]+=t[0]-_k[0],vk[4]+=t[1]-_k[1],vk[5]+=t[2]-_k[2],i.viewer.cameraFlight.flyTo({aabb:vk,fitFOV:65})}else i.hideControl()},onClickedNothing:function(){i.hideControl()}}):i.warn("Can't find overview canvas: '"+r.overviewCanvasId+"' - will create plugin without overview")}return i._onSceneSectionPlaneCreated=t.scene.on("sectionPlaneCreated",function(e){i._sectionPlaneCreated(e)}),i._onSceneSectionBoxCreated=t.scene.on("sectionBoxCreated",function(e){i._controlBox=e}),i.controlset=r.controlset,i}return _(e,ge),P(e,[{key:"setOverviewVisible",value:function(e){this._overview&&this._overview.setVisible(e)}},{key:"getOverviewVisible",value:function(){if(this._overview)return this._overview.getVisible()}},{key:"sectionPlanes",get:function(){return this._sectionPlanes}},{key:"createSectionPlane",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return void 0!==e.id&&null!==e.id&&this.viewer.scene.components[e.id]&&(this.error("Viewer component with this ID already exists: "+e.id),delete e.id),new cn(this.viewer.scene,{id:e.id,pos:e.pos,dir:e.dir,active:!0})}},{key:"createSectionBox",value:function(){this._sectionWay="box";var e=new mk(this);return new Sh(this.viewer.scene,{id:"sectionBox",active:!0,controlIdName:"sectionBoxPlane_",lineBox:e})}},{key:"createSectionSingle",value:function(){return this._sectionWay="box",new Sh(this.viewer.scene,{id:"sectionBox",active:!0,pickable:!1,enableClip:!1,controlIdName:"sectionBoxPlane_"})}},{key:"_sectionPlaneCreated",value:function(e){var t,i=this;switch(this._sectionWay){case"plane":t=this._freeControls.length>0?this._freeControls.pop():new dk(this,this._controlsConfig);break;case"box":this._boxPlaneConfig.enableClip=e.enableClip,this._boxPlaneConfig.pickable=e.pickable,this._boxPlaneConfig.controlFillColor=e.controlFillColor,t=this._freeControls.length>0?this._freeControls.pop():new ck(this,this._boxPlaneConfig);break;case"singleCtrl":t=this._freeControls.length>0?this._freeControls.pop():new ak(this,this.controlset);break;default:t=new nk(this)}var r=t;r._setSectionPlane(e),r.setVisible(!0),e.control=r,this._currentControl=r,null==e.box&&(this._controls[e.id]=r),this._overview&&this._overview.addSectionPlane(e),e.once("destroyed",function(){i._sectionPlaneDestroyed(e)})}},{key:"isTouch",set:function(e){this._isTouch=e,this.sectionWay=!0===e?"plane":this._sectionWay?this._sectionWay:"control"}},{key:"sectionConfigs",set:function(e){this._controlsConfig=e}},{key:"boxPlaneConfigs",set:function(e){this._boxPlaneConfig=e}},{key:"sectionWay",set:function(e){this._sectionWay=e}},{key:"sectionDirection",set:function(e){var t;switch(this.clear(),e){case 0:t=[0,0,-1];break;case 1:t=[-1,0,0];break;case 2:t=[0,-1,0]}var i=this.viewer.scene.center;this.createSectionPlane({pos:Y.AABB3([i[0],i[1],i[2]]),dir:t})}},{key:"sectionSingleDirection",set:function(e){var t;switch(this.hideControl(),this._sectionWay="singleCtrl",e){case 0:t=[0,0,-1];break;case 1:t=[-1,0,0];break;case 2:t=[0,-1,0]}var i=this.viewer.scene.center;this.createSectionPlane({pos:Y.AABB3([i[0],i[1],i[2]]),dir:t})}},{key:"controlBox",get:function(){return this._controlBox}},{key:"setControlPos",value:function(e){null!=this._currentControl&&(this._currentControl.pos=e)}},{key:"getControlPos",value:function(){return null==this._currentControl?-1:this._currentControl.posRate}},{key:"flipSectionPlanes",value:function(){var e=this.viewer.scene.sectionPlanes;for(var t in e){e[t].flipDir()}}},{key:"showControl",value:function(e){var t=this._controls[e];t?(t.setVisible(!0),this._overview&&this._overview.setPlaneSelected(e,!0),this._shownControlId=e,this._shownControlIds=[e]):this.error("Control not found: "+e)}},{key:"setControlsSize",value:function(e){for(var t in this._controls)this._controls[t].controlSize=e}},{key:"setControlSizeByID",value:function(e,t){this._controls[e]?this._controls[e].controlSize=t:this.error("Control not found: "+e)}},{key:"getShownControl",value:function(){return this._shownControlId}},{key:"getShownControls",value:function(){return this._shownControlIds}},{key:"showAllControl",value:function(){for(var e in this._controls)this._controls.hasOwnProperty(e)&&(this._shownControlIds.push(e),this._controls[e].setVisible(!1),this._overview&&this._overview.setPlaneSelected(e,!1))}},{key:"hideControl",value:function(){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,this._shownControlIds=[]}},{key:"destroySectionPlane",value:function(e){var t=this.viewer.scene.sectionPlanes[e];t?(this._sectionPlaneDestroyed(t),t.destroy(),e===this._shownControlId&&(this._shownControlId=null,this._shownControlIds=[])):this.error("SectionPlane not found: "+e)}},{key:"_sectionPlaneDestroyed",value:function(e){this._overview&&this._overview.removeSectionPlane(e);var t=this._controls[e.id];t&&(t.setVisible(!1),t._setSectionPlane(null),delete this._controls[e.id],this._freeControls.push(t))}},{key:"clear",value:function(){this._controlBox&&this._controlBox.destroy();for(var e=Object.keys(this._sectionPlanes),t=0,i=e.length;t<i;t++)this.destroySectionPlane(e[t])}},{key:"send",value:function(e,t){switch(e){case"snapshotStarting":for(var i in this._controls)this._controls.hasOwnProperty(i)&&this._controls[i].setCulled(!0);break;case"snapshotFinished":for(var r in this._controls)this._controls.hasOwnProperty(r)&&this._controls[r].setCulled(!1);break;case"clearSectionPlanes":this.clear()}}},{key:"destroy",value:function(){this.clear(),this._overview&&this._overview.destroy(),this._destroyFreeControls(),g(e,"destroy",this,3)([])}},{key:"_destroyFreeControls",value:function(){for(var e=this._freeControls.pop();e;)e._destroy(),e=this._freeControls.pop();this.viewer.scene.off(this._onSceneSectionPlaneCreated)}}])}();Y.vec3(),Y.mat4();var bk=function(){function e(t){var i;return x(this,e),(i=d(this,e,["skyboxes",t])).skyboxes={},i._active=!1,i}return _(e,ge),P(e,[{key:"send",value:function(e,t){if("clear"===e)this.clear()}},{key:"createSkybox",value:function(e,t){if(this.viewer.scene.components[e])return this.error("Component with this ID already exists: "+e),this;if(!t.src&&!t.image)return this.error("No legal skybox image or src: "+e),this;if(t.src){var i=new Th(this.viewer.scene,{id:e,size:t.size,scale:t.scale,src:t.src,active:t.active,encoding:3e3});return this.skyboxes[e]=i,i}if(t.image){i=new Th(this.viewer.scene,{id:e,size:t.size,scale:t.scale,image:t.image,active:t.active,encoding:3e3});return this.skyboxes[e]=i,i}}},{key:"setSkyBoxActiveById",value:function(e,t){this.skyboxes[e].active=t}},{key:"active",get:function(){return this._active},set:function(e){this._active=e;for(var t=0;t<this.skyboxes.length;t++)this.skyboxes[t].active=e}},{key:"getSkyBoxById",value:function(e){return this.skyboxes[e]}},{key:"destroySkybox",value:function(e){var t=this.skyboxes[e];t?t.destroy():this.error("Skybox not found: "+e)}},{key:"clear",value:function(){for(var e=Object.keys(this.skyboxes),t=0,i=e.length;t<i;t++)this.destroySkybox(e[t])}},{key:"destroy",value:function(){this.clear()}}])}(),wk=[],xk=function(){function e(t){var i,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};x(this,e),(i=d(this,e,["TreeViewPlugin",t])).errors=[],i.valid=!0;for(var n=0;;n++)if(!wk[n]){wk[n]=i,i._index=n,i._id="tree-".concat(n);break}if(i._metaModels={},i._autoAddModels=!1!==r.autoAddModels,i._autoExpandDepth=r.autoExpandDepth||0,i._sortNodes=!1!==r.sortNodes,i._viewer=t,i._rootElement=null,i._muteSceneEvents=!1,i._muteTreeEvents=!1,i._rootNodes=[],i._objectNodes={},i._nodeNodes={},i._rootNames={},i._sortNodes=r.sortNodes,i._pruneEmptyNodes=r.pruneEmptyNodes,i._showListItemElementId=null,i._onObjectVisibility=i._viewer.scene.on("objectVisibility",function(e){if(!i._muteSceneEvents){var t=e.id,r=i._objectNodes[t];if(r){var n=e.visible;if(n!==r.checked){i._muteTreeEvents=!0,r.checked=n,n?r.numVisibleEntities++:r.numVisibleEntities--;for(var s=r.parent;s;)s.checked=n,n?s.numVisibleEntities++:s.numVisibleEntities--,s=s.parent;i._muteTreeEvents=!1}}}}),i._onObjectXrayed=i._viewer.scene.on("objectXRayed",function(e){if(!i._muteSceneEvents){var t=e.id,r=i._objectNodes[t];if(r){i._muteTreeEvents=!0;var n=e.xrayed;n!==r.xrayed&&(r.xrayed=n,i._muteTreeEvents=!1)}}}),i._hierarchy=r.hierarchy||"containment",i._autoExpandDepth=r.autoExpandDepth||0,i._autoAddModels){for(var s=Object.keys(i.viewer.metaScene.metaModels),o=0,a=s.length;o<a;o++){var l=s[o];i.viewer.metaScene.metaModels[l].finalized&&i.addModel(l)}i.viewer.scene.on("modelLoaded",function(e){i.viewer.metaScene.metaModels[e]&&i.addModel(e)})}return i}return _(e,ge),P(e,[{key:"switchExpandHandler",value:function(e){e.preventDefault(),e.stopPropagation(),e.target,this.fire("ExpandHandler",e)}},{key:"switchCollapseHandler",value:function(e){e.preventDefault(),e.stopPropagation(),this.fire("CollapseHandler",e)}},{key:"checkboxChangeHandler",value:function(e){if(this.fire("checkBoxChanged",e),!this._muteTreeEvents){this._muteSceneEvents=!0;var t=e.target,i=t.checked,r=t.id.replace("checkbox-",""),n=this._nodeNodes[r],s=this._viewer.scene.objects,o=0;this._withNodeTree(n,function(e){var t=e.objectId,r=s[t],n=0===e.children.length;e.numVisibleEntities=i?e.numEntities:0,n&&i!==e.checked&&o++,e.checked=i,function(e,t){var i=document.getElementById("checkbox-".concat(e));i&&t!==i.checked&&(i.checked=t)}(e.nodeId,i),r&&(r.visible=i)});for(var a=n.parent;a;)a.checked=i,i?a.numVisibleEntities+=o:a.numVisibleEntities-=o,l(a.nodeId,a.numVisibleEntities>0),a=a.parent;this._muteSceneEvents=!1}function l(e,t){var i=document.getElementById("checkbox-".concat(e));i&&t!==i.checked&&(i.checked=t)}}},{key:"hierarchy",get:function(){return this._hierarchy},set:function(e){"containment"!==(e=e||"containment")&&"storeys"!==e&&"types"!==e&&(this.error("Unsupported value for `hierarchy' - defaulting to 'containment'"),e="containment"),this._hierarchy!==e&&(this._hierarchy=e,this._createNodes())}},{key:"muteTreeEvents",get:function(){return this._muteTreeEvents},set:function(e){this._muteTreeEvents=e}},{key:"nodeNodes",get:function(){return this._nodeNodes}},{key:"_createNodes",value:function(){this._rootElement&&(this._rootElement.parentNode.removeChild(this._rootElement),this._rootElement=null),this._rootNodes=[],this._objectNodes={},this._nodeNodes={},this._validate(),(this.valid||"storeys"!==this._hierarchy)&&this._createEnabledNodes()}},{key:"_createEnabledNodes",value:function(){switch(this._pruneEmptyNodes&&this._findEmptyNodes(),this._hierarchy){case"storeys":this._createStoreysNodes(),0===this._rootNodes.length&&this.warn("Failed to build storeys hierarchy");break;case"types":this._createTypesNodes();break;default:this._createContainmentNodes()}this._sortNodes&&this._doSortNodes(),this._synchNodesToEntities(),this.fire("nodeNodes_Created",this._nodeNodes),this.fire("rootNodes_Created",this._rootNodes),this.fire("objectNodes_Created",this._objectNodes)}},{key:"_createStoreysNodes",value:function(){var e=this._viewer.metaScene.rootMetaObjects;for(var t in e)this._createStoreysNodes2(e[t],null,null,null)}},{key:"_createStoreysNodes2",value:function(e,t,i,r){if(!this._pruneEmptyNodes||0!==e._countEntities){var n=e.type,s=e.name,o=e.children,a=e.id;if("IfcBuilding"===n)t={nodeId:"".concat(this._id,"-").concat(a),objectId:a,title:0===e.metaModels.length?"na":this._rootNames[e.metaModels[0].id]||(s&&""!==s&&"Undefined"!==s&&"Default"!==s?s:n),type:n,parent:null,numEntities:0,numVisibleEntities:0,checked:!1,xrayed:!1,children:[]},this._rootNodes.push(t),this._objectNodes[t.objectId]=t,this._nodeNodes[t.nodeId]=t;else if("IfcBuildingStorey"===n){if(!t)return void this.error("Failed to build storeys hierarchy for model '"+this.metaModel.id+"' - model does not have an IfcBuilding object, or is not an IFC model");i={nodeId:"".concat(this._id,"-").concat(a),objectId:a,title:s&&""!==s&&"Undefined"!==s&&"Default"!==s?s:n,type:n,parent:t,numEntities:0,numVisibleEntities:0,checked:!1,xrayed:!1,children:[]},t.children.push(i),this._objectNodes[i.objectId]=i,this._nodeNodes[i.nodeId]=i,r={}}else{if(i)if(this._viewer.scene.objects[a]){var l=(r=r||{})[n];l||(l={nodeId:"".concat(this._id,"-").concat(i.objectId,"-").concat(n),objectId:"".concat(i.objectId,"-").concat(n),title:n,type:n,parent:i,numEntities:0,numVisibleEntities:0,checked:!1,xrayed:!1,children:[]},i.children.push(l),this._objectNodes[l.objectId]=l,this._nodeNodes[l.nodeId]=l,r[n]=l);var u={nodeId:"".concat(this._id,"-").concat(a),objectId:a,title:s&&""!==s&&"Undefined"!==s&&"Default"!==s?s:n,type:n,parent:l,numEntities:0,numVisibleEntities:0,checked:!1,xrayed:!1,children:[]};l.children.push(u),this._objectNodes[u.objectId]=u,this._nodeNodes[u.nodeId]=u}}if(o)for(var c=0,h=o.length;c<h;c++){var A=o[c];this._createStoreysNodes2(A,t,i,r)}}}},{key:"_createTypesNodes",value:function(){var e=this._viewer.metaScene.rootMetaObjects;for(var t in e)this._createTypesNodes2(e[t],null,null)}},{key:"_createTypesNodes2",value:function(e,t,i){if(!this._pruneEmptyNodes||0!==e._countEntities){var r=e.type,n=e.name,s=e.children,o=e.id;if(e.parent){if(t)if(this._viewer.scene.objects[o]){var a=i[r];a||(a={nodeId:"".concat(this._id,"-").concat(t.objectId,"-").concat(r),objectId:"".concat(t.objectId,"-").concat(r),title:r,type:r,parent:t,numEntities:0,numVisibleEntities:0,checked:!1,xrayed:!1,children:[]},t.children.push(a),this._objectNodes[a.objectId]=a,this._nodeNodes[a.nodeId]=a,i[r]=a);var l={nodeId:"".concat(this._id,"-").concat(o),objectId:o,title:n&&""!==n&&"Default"!==n?n:r,type:r,parent:a,numEntities:0,numVisibleEntities:0,checked:!1,xrayed:!1,children:[]};a.children.push(l),this._objectNodes[l.objectId]=l,this._nodeNodes[l.nodeId]=l}}else t={nodeId:"".concat(this._id,"-").concat(o),objectId:o,title:0===e.metaModels.length?"na":this._rootNames[e.metaModels[0].id]||(n&&""!==n&&"Undefined"!==n&&"Default"!==n?n:r),type:r,parent:null,numEntities:0,numVisibleEntities:0,checked:!1,xrayed:!1,children:[]},this._rootNodes.push(t),this._objectNodes[t.objectId]=t,this._nodeNodes[t.nodeId]=t,i={};if(s)for(var u=0,c=s.length;u<c;u++){var h=s[u];this._createTypesNodes2(h,t,i)}}}},{key:"_createContainmentNodes",value:function(){var e=this._viewer.metaScene.rootMetaObjects;for(var t in e)this._createContainmentNodes2(e[t],null)}},{key:"_createContainmentNodes2",value:function(e,t){if(!this._pruneEmptyNodes||0!==e._countEntities){var i=e.type,r=e.name||i,n=e.children,s=e.id,o={nodeId:"".concat(this._id,"-").concat(s),objectId:s,title:t?r&&""!==r&&"Undefined"!==r&&"Default"!==r?r:i:0===e.metaModels.length?"na":this._rootNames[e.metaModels[0].id]||r,type:i,parent:t,numEntities:0,numVisibleEntities:0,checked:!1,xrayed:!1,children:[]};if(t?t.children.push(o):this._rootNodes.push(o),this._objectNodes[o.objectId]=o,this._nodeNodes[o.nodeId]=o,n)for(var a=0,l=n.length;a<l;a++){var u=n[a];this._createContainmentNodes2(u,o)}}}},{key:"_synchNodesToEntities",value:function(){for(var e=Object.keys(this.viewer.metaScene.metaObjects),t=this._viewer.metaScene.metaObjects,i=this._viewer.scene.objects,r=0,n=e.length;r<n;r++){var s=e[r];if(t[s]){var o=this._objectNodes[s];if(o){var a=i[s];if(a){var l=a.visible;o.numEntities=1,o.xrayed=a.xrayed,l?(o.numVisibleEntities=1,o.checked=!0):(o.numVisibleEntities=0,o.checked=!1);for(var u=o.parent;u;)u.numEntities++,l&&(u.numVisibleEntities++,u.checked=!0),u=u.parent}}}}}},{key:"_validate",value:function(){if(this.errors=[],"storeys"===this._hierarchy)this.valid=this._validateMetaModelForStoreysHierarchy();else this.valid=this._rootNodes.length>0;return this.valid}},{key:"_validateMetaModelForStoreysHierarchy",value:function(){return!0}},{key:"addModel",value:function(e){var t=this,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=this.viewer.scene.models[e];if(!r)throw"Model not found: "+e;var n=this.viewer.metaScene.metaModels[e];n?this._metaModels[e]?this._metaModels[e]=null:(this._metaModels[e]=n,i&&i.rootName&&(this._rootNames[e]=i.rootName),r.on("destroyed",function(){t.removeModel(r.id)}),this._createNodes()):this.error("MetaModel not found: "+e)}},{key:"removeModel",value:function(e){this._metaModels[e]&&(this._rootNames[e]&&delete this._rootNames[e],delete this._metaModels[e],this._createNodes())}},{key:"showNode",value:function(e){this.unShowNode();var t=this._objectNodes[e];if(t){for(var i=t.nodeId,r=t.parent;r;)r=r.parent;this._showListItemElementId=i}}},{key:"unShowNode",value:function(){this._showListItemElementId&&(this._showListItemElementId=null)}},{key:"withNodeTree",value:function(e,t){t(e);var i=e.children;if(i)for(var r=0,n=i.length;r<n;r++)this.withNodeTree(i[r],t)}},{key:"_withNodeTree",value:function(e,t){t(e);var i=e.children;if(i)for(var r=0,n=i.length;r<n;r++)this._withNodeTree(i[r],t)}},{key:"getChildrenById",value:function(e){return this._nodeNodes[e].children}},{key:"getNodeById",value:function(e){return this._nodeNodes[e]}},{key:"destroy",value:function(){this._metaModels={},this._rootElement&&!this._destroyed&&(this._rootElement.parentNode.removeChild(this._rootElement),this._viewer.scene.off(this._onObjectVisibility),this._destroyed=!0),delete wk[this._index],g(e,"destroy",this,3)([])}},{key:"_findEmptyNodes",value:function(){var e=this._viewer.metaScene.rootMetaObjects;for(var t in e)this._findEmptyNodes2(e[t])}},{key:"_findEmptyNodes2",value:function(e){var t=this.viewer.scene,i=e.children,r=e.id,n=t.objects[r];if(e._countEntities=0,n&&e._countEntities++,i)for(var s=0,o=i.length;s<o;s++){var a=i[s];a._countEntities=this._findEmptyNodes2(a),e._countEntities+=a._countEntities}return e._countEntities}},{key:"_doSortNodes",value:function(){for(var e=0,t=this._rootNodes.length;e<t;e++){var i=this._rootNodes[e];this._sortChildren(i)}}},{key:"_sortChildren",value:function(e){var t=e.children;if(t&&0!==t.length){"storeys"===this._hierarchy&&"IfcBuilding"===e.type?t.sort(this._getSpatialSortFunc()):t.sort(this._alphaSortFunc);for(var i=0,r=t.length;i<r;i++){var n=t[i];this._sortChildren(n)}}}},{key:"_getSpatialSortFunc",value:function(){var e=this.viewer,t=e.scene,i=t.camera,r=e.metaScene;return this._spatialSortFunc||(this._spatialSortFunc=function(e,n){e.aabb&&n.aabb||(e.aabb||(e.aabb=t.getAABB(r.getObjectIDsInSubtree(e.objectId))),n.aabb||(n.aabb=t.getAABB(r.getObjectIDsInSubtree(n.objectId))));var s=0;return s=i.xUp?0:i.yUp?1:2,e.aabb[s]>n.aabb[s]?-1:e.aabb[s]<n.aabb[s]?1:0})}},{key:"_alphaSortFunc",value:function(e,t){var i=e.title.toUpperCase(),r=t.title.toUpperCase();return i<r?-1:i>r?1:0}}])}(),Bk=function(){return P(function e(){x(this,e)},[{key:"getManifest",value:function(e,t,i){ne.loadJSON(e,function(e){t(e)},function(e){i(e)})}},{key:"getMetaModel",value:function(e,t,i){ne.loadJSON(e,function(e){t(e)},function(e){i(e)})}},{key:"getXTC",value:function(e,t,i){var r=function(){};t=t||r,i=i||r;var n=e.match(/^data:(.*?)(;base64)?,(.*)$/);if(n){var s=!!n[2],o=n[3];o=window.decodeURIComponent(o),s&&(o=window.atob(o));try{for(var a=new ArrayBuffer(o.length),l=new Uint8Array(a),u=0;u<o.length;u++)l[u]=o.charCodeAt(u);t(a)}catch(e){i(e)}}else{var c=new XMLHttpRequest;c.open("GET",e,!0),c.responseType="arraybuffer",c.onreadystatechange=function(){4===c.readyState&&(200===c.status?t(c.response):i("getXTC error : "+c.response))},c.send(null)}}}])}();!function(e,t){"object"==("undefined"==typeof exports?"undefined":w(exports))&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).pako={})}(void 0,function(e){function t(e){for(var t=e.length;--t>=0;)e[t]=0}var i=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]),r=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]),n=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7]),s=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),o=new Array(576);t(o);var a=new Array(60);t(a);var l=new Array(512);t(l);var u=new Array(256);t(u);var c=new Array(29);t(c);var h,A,d,p=new Array(30);function f(e,t,i,r,n){this.static_tree=e,this.extra_bits=t,this.extra_base=i,this.elems=r,this.max_length=n,this.has_stree=e&&e.length}function g(e,t){this.dyn_tree=e,this.max_code=0,this.stat_desc=t}t(p);var m=function(e){return e<256?l[e]:l[256+(e>>>7)]},v=function(e,t){e.pending_buf[e.pending++]=255&t,e.pending_buf[e.pending++]=t>>>8&255},_=function(e,t,i){e.bi_valid>16-i?(e.bi_buf|=t<<e.bi_valid&65535,v(e,e.bi_buf),e.bi_buf=t>>16-e.bi_valid,e.bi_valid+=i-16):(e.bi_buf|=t<<e.bi_valid&65535,e.bi_valid+=i)},y=function(e,t,i){_(e,i[2*t],i[2*t+1])},b=function(e,t){var i=0;do{i|=1&e,e>>>=1,i<<=1}while(--t>0);return i>>>1},x=function(e,t,i){var r,n,s=new Array(16),o=0;for(r=1;r<=15;r++)o=o+i[r-1]<<1,s[r]=o;for(n=0;n<=t;n++){var a=e[2*n+1];0!==a&&(e[2*n]=b(s[a]++,a))}},B=function(e){var t;for(t=0;t<286;t++)e.dyn_ltree[2*t]=0;for(t=0;t<30;t++)e.dyn_dtree[2*t]=0;for(t=0;t<19;t++)e.bl_tree[2*t]=0;e.dyn_ltree[512]=1,e.opt_len=e.static_len=0,e.sym_next=e.matches=0},P=function(e){e.bi_valid>8?v(e,e.bi_buf):e.bi_valid>0&&(e.pending_buf[e.pending++]=e.bi_buf),e.bi_buf=0,e.bi_valid=0},C=function(e,t,i,r){var n=2*t,s=2*i;return e[n]<e[s]||e[n]===e[s]&&r[t]<=r[i]},M=function(e,t,i){for(var r=e.heap[i],n=i<<1;n<=e.heap_len&&(n<e.heap_len&&C(t,e.heap[n+1],e.heap[n],e.depth)&&n++,!C(t,r,e.heap[n],e.depth));)e.heap[i]=e.heap[n],i=n,n<<=1;e.heap[i]=r},k=function(e,t,n){var s,o,a,l,h=0;if(0!==e.sym_next)do{s=255&e.pending_buf[e.sym_buf+h++],s+=(255&e.pending_buf[e.sym_buf+h++])<<8,o=e.pending_buf[e.sym_buf+h++],0===s?y(e,o,t):(a=u[o],y(e,a+256+1,t),0!==(l=i[a])&&(o-=c[a],_(e,o,l)),s--,a=m(s),y(e,a,n),0!==(l=r[a])&&(s-=p[a],_(e,s,l)))}while(h<e.sym_next);y(e,256,t)},E=function(e,t){var i,r,n,s=t.dyn_tree,o=t.stat_desc.static_tree,a=t.stat_desc.has_stree,l=t.stat_desc.elems,u=-1;for(e.heap_len=0,e.heap_max=573,i=0;i<l;i++)0!==s[2*i]?(e.heap[++e.heap_len]=u=i,e.depth[i]=0):s[2*i+1]=0;for(;e.heap_len<2;)s[2*(n=e.heap[++e.heap_len]=u<2?++u:0)]=1,e.depth[n]=0,e.opt_len--,a&&(e.static_len-=o[2*n+1]);for(t.max_code=u,i=e.heap_len>>1;i>=1;i--)M(e,s,i);n=l;do{i=e.heap[1],e.heap[1]=e.heap[e.heap_len--],M(e,s,1),r=e.heap[1],e.heap[--e.heap_max]=i,e.heap[--e.heap_max]=r,s[2*n]=s[2*i]+s[2*r],e.depth[n]=(e.depth[i]>=e.depth[r]?e.depth[i]:e.depth[r])+1,s[2*i+1]=s[2*r+1]=n,e.heap[1]=n++,M(e,s,1)}while(e.heap_len>=2);e.heap[--e.heap_max]=e.heap[1],function(e,t){var i,r,n,s,o,a,l=t.dyn_tree,u=t.max_code,c=t.stat_desc.static_tree,h=t.stat_desc.has_stree,A=t.stat_desc.extra_bits,d=t.stat_desc.extra_base,p=t.stat_desc.max_length,f=0;for(s=0;s<=15;s++)e.bl_count[s]=0;for(l[2*e.heap[e.heap_max]+1]=0,i=e.heap_max+1;i<573;i++)(s=l[2*l[2*(r=e.heap[i])+1]+1]+1)>p&&(s=p,f++),l[2*r+1]=s,r>u||(e.bl_count[s]++,o=0,r>=d&&(o=A[r-d]),a=l[2*r],e.opt_len+=a*(s+o),h&&(e.static_len+=a*(c[2*r+1]+o)));if(0!==f){do{for(s=p-1;0===e.bl_count[s];)s--;e.bl_count[s]--,e.bl_count[s+1]+=2,e.bl_count[p]--,f-=2}while(f>0);for(s=p;0!==s;s--)for(r=e.bl_count[s];0!==r;)(n=e.heap[--i])>u||(l[2*n+1]!==s&&(e.opt_len+=(s-l[2*n+1])*l[2*n],l[2*n+1]=s),r--)}}(e,t),x(s,u,e.bl_count)},S=function(e,t,i){var r,n,s=-1,o=t[1],a=0,l=7,u=4;for(0===o&&(l=138,u=3),t[2*(i+1)+1]=65535,r=0;r<=i;r++)n=o,o=t[2*(r+1)+1],++a<l&&n===o||(a<u?e.bl_tree[2*n]+=a:0!==n?(n!==s&&e.bl_tree[2*n]++,e.bl_tree[32]++):a<=10?e.bl_tree[34]++:e.bl_tree[36]++,a=0,s=n,0===o?(l=138,u=3):n===o?(l=6,u=3):(l=7,u=4))},T=function(e,t,i){var r,n,s=-1,o=t[1],a=0,l=7,u=4;for(0===o&&(l=138,u=3),r=0;r<=i;r++)if(n=o,o=t[2*(r+1)+1],!(++a<l&&n===o)){if(a<u)do{y(e,n,e.bl_tree)}while(0!=--a);else 0!==n?(n!==s&&(y(e,n,e.bl_tree),a--),y(e,16,e.bl_tree),_(e,a-3,2)):a<=10?(y(e,17,e.bl_tree),_(e,a-3,3)):(y(e,18,e.bl_tree),_(e,a-11,7));a=0,s=n,0===o?(l=138,u=3):n===o?(l=6,u=3):(l=7,u=4)}},I=!1,F=function(e,t,i,r){_(e,0+(r?1:0),3),P(e),v(e,i),v(e,~i),i&&e.pending_buf.set(e.window.subarray(t,t+i),e.pending),e.pending+=i},D=function(e){I||(function(){var e,t,s,g,m,v=new Array(16);for(s=0,g=0;g<28;g++)for(c[g]=s,e=0;e<1<<i[g];e++)u[s++]=g;for(u[s-1]=g,m=0,g=0;g<16;g++)for(p[g]=m,e=0;e<1<<r[g];e++)l[m++]=g;for(m>>=7;g<30;g++)for(p[g]=m<<7,e=0;e<1<<r[g]-7;e++)l[256+m++]=g;for(t=0;t<=15;t++)v[t]=0;for(e=0;e<=143;)o[2*e+1]=8,e++,v[8]++;for(;e<=255;)o[2*e+1]=9,e++,v[9]++;for(;e<=279;)o[2*e+1]=7,e++,v[7]++;for(;e<=287;)o[2*e+1]=8,e++,v[8]++;for(x(o,287,v),e=0;e<30;e++)a[2*e+1]=5,a[2*e]=b(e,5);h=new f(o,i,257,286,15),A=new f(a,r,0,30,15),d=new f(new Array(0),n,0,19,7)}(),I=!0),e.l_desc=new g(e.dyn_ltree,h),e.d_desc=new g(e.dyn_dtree,A),e.bl_desc=new g(e.bl_tree,d),e.bi_buf=0,e.bi_valid=0,B(e)},R=F,O=function(e,t,i,r){var n,l,u=0;e.level>0?(2===e.strm.data_type&&(e.strm.data_type=function(e){var t,i=4093624447;for(t=0;t<=31;t++,i>>>=1)if(1&i&&0!==e.dyn_ltree[2*t])return 0;if(0!==e.dyn_ltree[18]||0!==e.dyn_ltree[20]||0!==e.dyn_ltree[26])return 1;for(t=32;t<256;t++)if(0!==e.dyn_ltree[2*t])return 1;return 0}(e)),E(e,e.l_desc),E(e,e.d_desc),u=function(e){var t;for(S(e,e.dyn_ltree,e.l_desc.max_code),S(e,e.dyn_dtree,e.d_desc.max_code),E(e,e.bl_desc),t=18;t>=3&&0===e.bl_tree[2*s[t]+1];t--);return e.opt_len+=3*(t+1)+5+5+4,t}(e),n=e.opt_len+3+7>>>3,(l=e.static_len+3+7>>>3)<=n&&(n=l)):n=l=i+5,i+4<=n&&-1!==t?F(e,t,i,r):4===e.strategy||l===n?(_(e,2+(r?1:0),3),k(e,o,a)):(_(e,4+(r?1:0),3),function(e,t,i,r){var n;for(_(e,t-257,5),_(e,i-1,5),_(e,r-4,4),n=0;n<r;n++)_(e,e.bl_tree[2*s[n]+1],3);T(e,e.dyn_ltree,t-1),T(e,e.dyn_dtree,i-1)}(e,e.l_desc.max_code+1,e.d_desc.max_code+1,u+1),k(e,e.dyn_ltree,e.dyn_dtree)),B(e),r&&P(e)},L=function(e,t,i){return e.pending_buf[e.sym_buf+e.sym_next++]=t,e.pending_buf[e.sym_buf+e.sym_next++]=t>>8,e.pending_buf[e.sym_buf+e.sym_next++]=i,0===t?e.dyn_ltree[2*i]++:(e.matches++,t--,e.dyn_ltree[2*(u[i]+256+1)]++,e.dyn_dtree[2*m(t)]++),e.sym_next===e.sym_end},j=function(e){_(e,2,3),y(e,256,o),function(e){16===e.bi_valid?(v(e,e.bi_buf),e.bi_buf=0,e.bi_valid=0):e.bi_valid>=8&&(e.pending_buf[e.pending++]=255&e.bi_buf,e.bi_buf>>=8,e.bi_valid-=8)}(e)},U=function(e,t,i,r){for(var n=65535&e,s=e>>>16&65535,o=0;0!==i;){i-=o=i>2e3?2e3:i;do{s=s+(n=n+t[r++]|0)|0}while(--o);n%=65521,s%=65521}return n|s<<16},N=new Uint32Array(function(){for(var e,t=[],i=0;i<256;i++){e=i;for(var r=0;r<8;r++)e=1&e?3988292384^e>>>1:e>>>1;t[i]=e}return t}()),V=function(e,t,i,r){var n=N,s=r+i;e^=-1;for(var o=r;o<s;o++)e=e>>>8^n[255&(e^t[o])];return-1^e},Q={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"},H={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},G=D,z=R,W=O,K=L,X=j,q=H.Z_NO_FLUSH,Y=H.Z_PARTIAL_FLUSH,J=H.Z_FULL_FLUSH,Z=H.Z_FINISH,$=H.Z_BLOCK,ee=H.Z_OK,te=H.Z_STREAM_END,ie=H.Z_STREAM_ERROR,re=H.Z_DATA_ERROR,ne=H.Z_BUF_ERROR,se=H.Z_DEFAULT_COMPRESSION,oe=H.Z_FILTERED,ae=H.Z_HUFFMAN_ONLY,le=H.Z_RLE,ue=H.Z_FIXED,ce=H.Z_UNKNOWN,he=H.Z_DEFLATED,Ae=258,de=262,pe=42,fe=113,ge=666,me=function(e,t){return e.msg=Q[t],t},ve=function(e){return 2*e-(e>4?9:0)},_e=function(e){for(var t=e.length;--t>=0;)e[t]=0},ye=function(e){var t,i,r,n=e.w_size;r=t=e.hash_size;do{i=e.head[--r],e.head[r]=i>=n?i-n:0}while(--t);r=t=n;do{i=e.prev[--r],e.prev[r]=i>=n?i-n:0}while(--t)},be=function(e,t,i){return(t<<e.hash_shift^i)&e.hash_mask},we=function(e){var t=e.state,i=t.pending;i>e.avail_out&&(i=e.avail_out),0!==i&&(e.output.set(t.pending_buf.subarray(t.pending_out,t.pending_out+i),e.next_out),e.next_out+=i,t.pending_out+=i,e.total_out+=i,e.avail_out-=i,t.pending-=i,0===t.pending&&(t.pending_out=0))},xe=function(e,t){W(e,e.block_start>=0?e.block_start:-1,e.strstart-e.block_start,t),e.block_start=e.strstart,we(e.strm)},Be=function(e,t){e.pending_buf[e.pending++]=t},Pe=function(e,t){e.pending_buf[e.pending++]=t>>>8&255,e.pending_buf[e.pending++]=255&t},Ce=function(e,t,i,r){var n=e.avail_in;return n>r&&(n=r),0===n?0:(e.avail_in-=n,t.set(e.input.subarray(e.next_in,e.next_in+n),i),1===e.state.wrap?e.adler=U(e.adler,t,n,i):2===e.state.wrap&&(e.adler=V(e.adler,t,n,i)),e.next_in+=n,e.total_in+=n,n)},Me=function(e,t){var i,r,n=e.max_chain_length,s=e.strstart,o=e.prev_length,a=e.nice_match,l=e.strstart>e.w_size-de?e.strstart-(e.w_size-de):0,u=e.window,c=e.w_mask,h=e.prev,A=e.strstart+Ae,d=u[s+o-1],p=u[s+o];e.prev_length>=e.good_match&&(n>>=2),a>e.lookahead&&(a=e.lookahead);do{if(u[(i=t)+o]===p&&u[i+o-1]===d&&u[i]===u[s]&&u[++i]===u[s+1]){s+=2,i++;do{}while(u[++s]===u[++i]&&u[++s]===u[++i]&&u[++s]===u[++i]&&u[++s]===u[++i]&&u[++s]===u[++i]&&u[++s]===u[++i]&&u[++s]===u[++i]&&u[++s]===u[++i]&&s<A);if(r=Ae-(A-s),s=A-Ae,r>o){if(e.match_start=t,o=r,r>=a)break;d=u[s+o-1],p=u[s+o]}}}while((t=h[t&c])>l&&0!=--n);return o<=e.lookahead?o:e.lookahead},ke=function(e){var t,i,r,n=e.w_size;do{if(i=e.window_size-e.lookahead-e.strstart,e.strstart>=n+(n-de)&&(e.window.set(e.window.subarray(n,n+n-i),0),e.match_start-=n,e.strstart-=n,e.block_start-=n,e.insert>e.strstart&&(e.insert=e.strstart),ye(e),i+=n),0===e.strm.avail_in)break;if(t=Ce(e.strm,e.window,e.strstart+e.lookahead,i),e.lookahead+=t,e.lookahead+e.insert>=3)for(r=e.strstart-e.insert,e.ins_h=e.window[r],e.ins_h=be(e,e.ins_h,e.window[r+1]);e.insert&&(e.ins_h=be(e,e.ins_h,e.window[r+3-1]),e.prev[r&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=r,r++,e.insert--,!(e.lookahead+e.insert<3)););}while(e.lookahead<de&&0!==e.strm.avail_in)},Ee=function(e,t){var i,r,n,s=e.pending_buf_size-5>e.w_size?e.w_size:e.pending_buf_size-5,o=0,a=e.strm.avail_in;do{if(i=65535,n=e.bi_valid+42>>3,e.strm.avail_out<n)break;if(n=e.strm.avail_out-n,i>(r=e.strstart-e.block_start)+e.strm.avail_in&&(i=r+e.strm.avail_in),i>n&&(i=n),i<s&&(0===i&&t!==Z||t===q||i!==r+e.strm.avail_in))break;o=t===Z&&i===r+e.strm.avail_in?1:0,z(e,0,0,o),e.pending_buf[e.pending-4]=i,e.pending_buf[e.pending-3]=i>>8,e.pending_buf[e.pending-2]=~i,e.pending_buf[e.pending-1]=~i>>8,we(e.strm),r&&(r>i&&(r=i),e.strm.output.set(e.window.subarray(e.block_start,e.block_start+r),e.strm.next_out),e.strm.next_out+=r,e.strm.avail_out-=r,e.strm.total_out+=r,e.block_start+=r,i-=r),i&&(Ce(e.strm,e.strm.output,e.strm.next_out,i),e.strm.next_out+=i,e.strm.avail_out-=i,e.strm.total_out+=i)}while(0===o);return(a-=e.strm.avail_in)&&(a>=e.w_size?(e.matches=2,e.window.set(e.strm.input.subarray(e.strm.next_in-e.w_size,e.strm.next_in),0),e.strstart=e.w_size,e.insert=e.strstart):(e.window_size-e.strstart<=a&&(e.strstart-=e.w_size,e.window.set(e.window.subarray(e.w_size,e.w_size+e.strstart),0),e.matches<2&&e.matches++,e.insert>e.strstart&&(e.insert=e.strstart)),e.window.set(e.strm.input.subarray(e.strm.next_in-a,e.strm.next_in),e.strstart),e.strstart+=a,e.insert+=a>e.w_size-e.insert?e.w_size-e.insert:a),e.block_start=e.strstart),e.high_water<e.strstart&&(e.high_water=e.strstart),o?4:t!==q&&t!==Z&&0===e.strm.avail_in&&e.strstart===e.block_start?2:(n=e.window_size-e.strstart,e.strm.avail_in>n&&e.block_start>=e.w_size&&(e.block_start-=e.w_size,e.strstart-=e.w_size,e.window.set(e.window.subarray(e.w_size,e.w_size+e.strstart),0),e.matches<2&&e.matches++,n+=e.w_size,e.insert>e.strstart&&(e.insert=e.strstart)),n>e.strm.avail_in&&(n=e.strm.avail_in),n&&(Ce(e.strm,e.window,e.strstart,n),e.strstart+=n,e.insert+=n>e.w_size-e.insert?e.w_size-e.insert:n),e.high_water<e.strstart&&(e.high_water=e.strstart),n=e.bi_valid+42>>3,s=(n=e.pending_buf_size-n>65535?65535:e.pending_buf_size-n)>e.w_size?e.w_size:n,((r=e.strstart-e.block_start)>=s||(r||t===Z)&&t!==q&&0===e.strm.avail_in&&r<=n)&&(i=r>n?n:r,o=t===Z&&0===e.strm.avail_in&&i===r?1:0,z(e,e.block_start,i,o),e.block_start+=i,we(e.strm)),o?3:1)},Se=function(e,t){for(var i,r;;){if(e.lookahead<de){if(ke(e),e.lookahead<de&&t===q)return 1;if(0===e.lookahead)break}if(i=0,e.lookahead>=3&&(e.ins_h=be(e,e.ins_h,e.window[e.strstart+3-1]),i=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),0!==i&&e.strstart-i<=e.w_size-de&&(e.match_length=Me(e,i)),e.match_length>=3)if(r=K(e,e.strstart-e.match_start,e.match_length-3),e.lookahead-=e.match_length,e.match_length<=e.max_lazy_match&&e.lookahead>=3){e.match_length--;do{e.strstart++,e.ins_h=be(e,e.ins_h,e.window[e.strstart+3-1]),i=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart}while(0!=--e.match_length);e.strstart++}else e.strstart+=e.match_length,e.match_length=0,e.ins_h=e.window[e.strstart],e.ins_h=be(e,e.ins_h,e.window[e.strstart+1]);else r=K(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++;if(r&&(xe(e,!1),0===e.strm.avail_out))return 1}return e.insert=e.strstart<2?e.strstart:2,t===Z?(xe(e,!0),0===e.strm.avail_out?3:4):e.sym_next&&(xe(e,!1),0===e.strm.avail_out)?1:2},Te=function(e,t){for(var i,r,n;;){if(e.lookahead<de){if(ke(e),e.lookahead<de&&t===q)return 1;if(0===e.lookahead)break}if(i=0,e.lookahead>=3&&(e.ins_h=be(e,e.ins_h,e.window[e.strstart+3-1]),i=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),e.prev_length=e.match_length,e.prev_match=e.match_start,e.match_length=2,0!==i&&e.prev_length<e.max_lazy_match&&e.strstart-i<=e.w_size-de&&(e.match_length=Me(e,i),e.match_length<=5&&(e.strategy===oe||3===e.match_length&&e.strstart-e.match_start>4096)&&(e.match_length=2)),e.prev_length>=3&&e.match_length<=e.prev_length){n=e.strstart+e.lookahead-3,r=K(e,e.strstart-1-e.prev_match,e.prev_length-3),e.lookahead-=e.prev_length-1,e.prev_length-=2;do{++e.strstart<=n&&(e.ins_h=be(e,e.ins_h,e.window[e.strstart+3-1]),i=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart)}while(0!=--e.prev_length);if(e.match_available=0,e.match_length=2,e.strstart++,r&&(xe(e,!1),0===e.strm.avail_out))return 1}else if(e.match_available){if((r=K(e,0,e.window[e.strstart-1]))&&xe(e,!1),e.strstart++,e.lookahead--,0===e.strm.avail_out)return 1}else e.match_available=1,e.strstart++,e.lookahead--}return e.match_available&&(r=K(e,0,e.window[e.strstart-1]),e.match_available=0),e.insert=e.strstart<2?e.strstart:2,t===Z?(xe(e,!0),0===e.strm.avail_out?3:4):e.sym_next&&(xe(e,!1),0===e.strm.avail_out)?1:2};function Ie(e,t,i,r,n){this.good_length=e,this.max_lazy=t,this.nice_length=i,this.max_chain=r,this.func=n}var Fe=[new Ie(0,0,0,0,Ee),new Ie(4,4,8,4,Se),new Ie(4,5,16,8,Se),new Ie(4,6,32,32,Se),new Ie(4,4,16,16,Te),new Ie(8,16,32,32,Te),new Ie(8,16,128,128,Te),new Ie(8,32,128,256,Te),new Ie(32,128,258,1024,Te),new Ie(32,258,258,4096,Te)];function De(){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=he,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),_e(this.dyn_ltree),_e(this.dyn_dtree),_e(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),_e(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new Uint16Array(573),_e(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}var Re=function(e){if(!e)return 1;var t=e.state;return!t||t.strm!==e||t.status!==pe&&57!==t.status&&69!==t.status&&73!==t.status&&91!==t.status&&103!==t.status&&t.status!==fe&&t.status!==ge?1:0},Oe=function(e){if(Re(e))return me(e,ie);e.total_in=e.total_out=0,e.data_type=ce;var t=e.state;return t.pending=0,t.pending_out=0,t.wrap<0&&(t.wrap=-t.wrap),t.status=2===t.wrap?57:t.wrap?pe:fe,e.adler=2===t.wrap?0:1,t.last_flush=-2,G(t),ee},Le=function(e){var t,i=Oe(e);return i===ee&&((t=e.state).window_size=2*t.w_size,_e(t.head),t.max_lazy_match=Fe[t.level].max_lazy,t.good_match=Fe[t.level].good_length,t.nice_match=Fe[t.level].nice_length,t.max_chain_length=Fe[t.level].max_chain,t.strstart=0,t.block_start=0,t.lookahead=0,t.insert=0,t.match_length=t.prev_length=2,t.match_available=0,t.ins_h=0),i},je=function(e,t,i,r,n,s){if(!e)return ie;var o=1;if(t===se&&(t=6),r<0?(o=0,r=-r):r>15&&(o=2,r-=16),n<1||n>9||i!==he||r<8||r>15||t<0||t>9||s<0||s>ue||8===r&&1!==o)return me(e,ie);8===r&&(r=9);var a=new De;return e.state=a,a.strm=e,a.status=pe,a.wrap=o,a.gzhead=null,a.w_bits=r,a.w_size=1<<a.w_bits,a.w_mask=a.w_size-1,a.hash_bits=n+7,a.hash_size=1<<a.hash_bits,a.hash_mask=a.hash_size-1,a.hash_shift=~~((a.hash_bits+3-1)/3),a.window=new Uint8Array(2*a.w_size),a.head=new Uint16Array(a.hash_size),a.prev=new Uint16Array(a.w_size),a.lit_bufsize=1<<n+6,a.pending_buf_size=4*a.lit_bufsize,a.pending_buf=new Uint8Array(a.pending_buf_size),a.sym_buf=a.lit_bufsize,a.sym_end=3*(a.lit_bufsize-1),a.level=t,a.strategy=s,a.method=i,Le(e)},Ue=je,Ne=function(e,t){return Re(e)||2!==e.state.wrap?ie:(e.state.gzhead=t,ee)},Ve=function(e,t){if(Re(e)||t>$||t<0)return e?me(e,ie):ie;var i=e.state;if(!e.output||0!==e.avail_in&&!e.input||i.status===ge&&t!==Z)return me(e,0===e.avail_out?ne:ie);var r=i.last_flush;if(i.last_flush=t,0!==i.pending){if(we(e),0===e.avail_out)return i.last_flush=-1,ee}else if(0===e.avail_in&&ve(t)<=ve(r)&&t!==Z)return me(e,ne);if(i.status===ge&&0!==e.avail_in)return me(e,ne);if(i.status===pe&&0===i.wrap&&(i.status=fe),i.status===pe){var n=he+(i.w_bits-8<<4)<<8;if(n|=(i.strategy>=ae||i.level<2?0:i.level<6?1:6===i.level?2:3)<<6,0!==i.strstart&&(n|=32),Pe(i,n+=31-n%31),0!==i.strstart&&(Pe(i,e.adler>>>16),Pe(i,65535&e.adler)),e.adler=1,i.status=fe,we(e),0!==i.pending)return i.last_flush=-1,ee}if(57===i.status)if(e.adler=0,Be(i,31),Be(i,139),Be(i,8),i.gzhead)Be(i,(i.gzhead.text?1:0)+(i.gzhead.hcrc?2:0)+(i.gzhead.extra?4:0)+(i.gzhead.name?8:0)+(i.gzhead.comment?16:0)),Be(i,255&i.gzhead.time),Be(i,i.gzhead.time>>8&255),Be(i,i.gzhead.time>>16&255),Be(i,i.gzhead.time>>24&255),Be(i,9===i.level?2:i.strategy>=ae||i.level<2?4:0),Be(i,255&i.gzhead.os),i.gzhead.extra&&i.gzhead.extra.length&&(Be(i,255&i.gzhead.extra.length),Be(i,i.gzhead.extra.length>>8&255)),i.gzhead.hcrc&&(e.adler=V(e.adler,i.pending_buf,i.pending,0)),i.gzindex=0,i.status=69;else if(Be(i,0),Be(i,0),Be(i,0),Be(i,0),Be(i,0),Be(i,9===i.level?2:i.strategy>=ae||i.level<2?4:0),Be(i,3),i.status=fe,we(e),0!==i.pending)return i.last_flush=-1,ee;if(69===i.status){if(i.gzhead.extra){for(var s=i.pending,o=(65535&i.gzhead.extra.length)-i.gzindex;i.pending+o>i.pending_buf_size;){var a=i.pending_buf_size-i.pending;if(i.pending_buf.set(i.gzhead.extra.subarray(i.gzindex,i.gzindex+a),i.pending),i.pending=i.pending_buf_size,i.gzhead.hcrc&&i.pending>s&&(e.adler=V(e.adler,i.pending_buf,i.pending-s,s)),i.gzindex+=a,we(e),0!==i.pending)return i.last_flush=-1,ee;s=0,o-=a}var l=new Uint8Array(i.gzhead.extra);i.pending_buf.set(l.subarray(i.gzindex,i.gzindex+o),i.pending),i.pending+=o,i.gzhead.hcrc&&i.pending>s&&(e.adler=V(e.adler,i.pending_buf,i.pending-s,s)),i.gzindex=0}i.status=73}if(73===i.status){if(i.gzhead.name){var u,c=i.pending;do{if(i.pending===i.pending_buf_size){if(i.gzhead.hcrc&&i.pending>c&&(e.adler=V(e.adler,i.pending_buf,i.pending-c,c)),we(e),0!==i.pending)return i.last_flush=-1,ee;c=0}u=i.gzindex<i.gzhead.name.length?255&i.gzhead.name.charCodeAt(i.gzindex++):0,Be(i,u)}while(0!==u);i.gzhead.hcrc&&i.pending>c&&(e.adler=V(e.adler,i.pending_buf,i.pending-c,c)),i.gzindex=0}i.status=91}if(91===i.status){if(i.gzhead.comment){var h,A=i.pending;do{if(i.pending===i.pending_buf_size){if(i.gzhead.hcrc&&i.pending>A&&(e.adler=V(e.adler,i.pending_buf,i.pending-A,A)),we(e),0!==i.pending)return i.last_flush=-1,ee;A=0}h=i.gzindex<i.gzhead.comment.length?255&i.gzhead.comment.charCodeAt(i.gzindex++):0,Be(i,h)}while(0!==h);i.gzhead.hcrc&&i.pending>A&&(e.adler=V(e.adler,i.pending_buf,i.pending-A,A))}i.status=103}if(103===i.status){if(i.gzhead.hcrc){if(i.pending+2>i.pending_buf_size&&(we(e),0!==i.pending))return i.last_flush=-1,ee;Be(i,255&e.adler),Be(i,e.adler>>8&255),e.adler=0}if(i.status=fe,we(e),0!==i.pending)return i.last_flush=-1,ee}if(0!==e.avail_in||0!==i.lookahead||t!==q&&i.status!==ge){var d=0===i.level?Ee(i,t):i.strategy===ae?function(e,t){for(var i;;){if(0===e.lookahead&&(ke(e),0===e.lookahead)){if(t===q)return 1;break}if(e.match_length=0,i=K(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++,i&&(xe(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,t===Z?(xe(e,!0),0===e.strm.avail_out?3:4):e.sym_next&&(xe(e,!1),0===e.strm.avail_out)?1:2}(i,t):i.strategy===le?function(e,t){for(var i,r,n,s,o=e.window;;){if(e.lookahead<=Ae){if(ke(e),e.lookahead<=Ae&&t===q)return 1;if(0===e.lookahead)break}if(e.match_length=0,e.lookahead>=3&&e.strstart>0&&((r=o[n=e.strstart-1])===o[++n]&&r===o[++n]&&r===o[++n])){s=e.strstart+Ae;do{}while(r===o[++n]&&r===o[++n]&&r===o[++n]&&r===o[++n]&&r===o[++n]&&r===o[++n]&&r===o[++n]&&r===o[++n]&&n<s);e.match_length=Ae-(s-n),e.match_length>e.lookahead&&(e.match_length=e.lookahead)}if(e.match_length>=3?(i=K(e,1,e.match_length-3),e.lookahead-=e.match_length,e.strstart+=e.match_length,e.match_length=0):(i=K(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++),i&&(xe(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,t===Z?(xe(e,!0),0===e.strm.avail_out?3:4):e.sym_next&&(xe(e,!1),0===e.strm.avail_out)?1:2}(i,t):Fe[i.level].func(i,t);if(3!==d&&4!==d||(i.status=ge),1===d||3===d)return 0===e.avail_out&&(i.last_flush=-1),ee;if(2===d&&(t===Y?X(i):t!==$&&(z(i,0,0,!1),t===J&&(_e(i.head),0===i.lookahead&&(i.strstart=0,i.block_start=0,i.insert=0))),we(e),0===e.avail_out))return i.last_flush=-1,ee}return t!==Z?ee:i.wrap<=0?te:(2===i.wrap?(Be(i,255&e.adler),Be(i,e.adler>>8&255),Be(i,e.adler>>16&255),Be(i,e.adler>>24&255),Be(i,255&e.total_in),Be(i,e.total_in>>8&255),Be(i,e.total_in>>16&255),Be(i,e.total_in>>24&255)):(Pe(i,e.adler>>>16),Pe(i,65535&e.adler)),we(e),i.wrap>0&&(i.wrap=-i.wrap),0!==i.pending?ee:te)},Qe=function(e){if(Re(e))return ie;var t=e.state.status;return e.state=null,t===fe?me(e,re):ee},He=function(e,t){var i=t.length;if(Re(e))return ie;var r=e.state,n=r.wrap;if(2===n||1===n&&r.status!==pe||r.lookahead)return ie;if(1===n&&(e.adler=U(e.adler,t,i,0)),r.wrap=0,i>=r.w_size){0===n&&(_e(r.head),r.strstart=0,r.block_start=0,r.insert=0);var s=new Uint8Array(r.w_size);s.set(t.subarray(i-r.w_size,i),0),t=s,i=r.w_size}var o=e.avail_in,a=e.next_in,l=e.input;for(e.avail_in=i,e.next_in=0,e.input=t,ke(r);r.lookahead>=3;){var u=r.strstart,c=r.lookahead-2;do{r.ins_h=be(r,r.ins_h,r.window[u+3-1]),r.prev[u&r.w_mask]=r.head[r.ins_h],r.head[r.ins_h]=u,u++}while(--c);r.strstart=u,r.lookahead=2,ke(r)}return r.strstart+=r.lookahead,r.block_start=r.strstart,r.insert=r.lookahead,r.lookahead=0,r.match_length=r.prev_length=2,r.match_available=0,e.next_in=a,e.input=l,e.avail_in=o,r.wrap=n,ee},Ge=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},ze=function(e){for(var t=Array.prototype.slice.call(arguments,1);t.length;){var i=t.shift();if(i){if("object"!=w(i))throw new TypeError(i+"must be non-object");for(var r in i)Ge(i,r)&&(e[r]=i[r])}}return e},We=function(e){for(var t=0,i=0,r=e.length;i<r;i++)t+=e[i].length;for(var n=new Uint8Array(t),s=0,o=0,a=e.length;s<a;s++){var l=e[s];n.set(l,o),o+=l.length}return n},Ke=!0;try{String.fromCharCode.apply(null,new Uint8Array(1))}catch(e){Ke=!1}for(var Xe=new Uint8Array(256),qe=0;qe<256;qe++)Xe[qe]=qe>=252?6:qe>=248?5:qe>=240?4:qe>=224?3:qe>=192?2:1;Xe[254]=Xe[254]=1;var Ye=function(e){if("function"==typeof TextEncoder&&TextEncoder.prototype.encode)return(new TextEncoder).encode(e);var t,i,r,n,s,o=e.length,a=0;for(n=0;n<o;n++)55296==(64512&(i=e.charCodeAt(n)))&&n+1<o&&(56320==(64512&(r=e.charCodeAt(n+1)))&&(i=65536+(i-55296<<10)+(r-56320),n++)),a+=i<128?1:i<2048?2:i<65536?3:4;for(t=new Uint8Array(a),s=0,n=0;s<a;n++)55296==(64512&(i=e.charCodeAt(n)))&&n+1<o&&(56320==(64512&(r=e.charCodeAt(n+1)))&&(i=65536+(i-55296<<10)+(r-56320),n++)),i<128?t[s++]=i:i<2048?(t[s++]=192|i>>>6,t[s++]=128|63&i):i<65536?(t[s++]=224|i>>>12,t[s++]=128|i>>>6&63,t[s++]=128|63&i):(t[s++]=240|i>>>18,t[s++]=128|i>>>12&63,t[s++]=128|i>>>6&63,t[s++]=128|63&i);return t},Je=function(e,t){var i,r,n=t||e.length;if("function"==typeof TextDecoder&&TextDecoder.prototype.decode)return(new TextDecoder).decode(e.subarray(0,t));var s=new Array(2*n);for(r=0,i=0;i<n;){var o=e[i++];if(o<128)s[r++]=o;else{var a=Xe[o];if(a>4)s[r++]=65533,i+=a-1;else{for(o&=2===a?31:3===a?15:7;a>1&&i<n;)o=o<<6|63&e[i++],a--;a>1?s[r++]=65533:o<65536?s[r++]=o:(o-=65536,s[r++]=55296|o>>10&1023,s[r++]=56320|1023&o)}}}return function(e,t){if(t<65534&&e.subarray&&Ke)return String.fromCharCode.apply(null,e.length===t?e:e.subarray(0,t));for(var i="",r=0;r<t;r++)i+=String.fromCharCode(e[r]);return i}(s,r)},Ze=function(e,t){(t=t||e.length)>e.length&&(t=e.length);for(var i=t-1;i>=0&&128==(192&e[i]);)i--;return i<0||0===i?t:i+Xe[e[i]]>t?i:t},$e=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},et=Object.prototype.toString,tt=H.Z_NO_FLUSH,it=H.Z_SYNC_FLUSH,rt=H.Z_FULL_FLUSH,nt=H.Z_FINISH,st=H.Z_OK,ot=H.Z_STREAM_END,at=H.Z_DEFAULT_COMPRESSION,lt=H.Z_DEFAULT_STRATEGY,ut=H.Z_DEFLATED;function ct(e){this.options=ze({level:at,method:ut,chunkSize:16384,windowBits:15,memLevel:8,strategy:lt},e||{});var t=this.options;t.raw&&t.windowBits>0?t.windowBits=-t.windowBits:t.gzip&&t.windowBits>0&&t.windowBits<16&&(t.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new $e,this.strm.avail_out=0;var i=Ue(this.strm,t.level,t.method,t.windowBits,t.memLevel,t.strategy);if(i!==st)throw new Error(Q[i]);if(t.header&&Ne(this.strm,t.header),t.dictionary){var r;if(r="string"==typeof t.dictionary?Ye(t.dictionary):"[object ArrayBuffer]"===et.call(t.dictionary)?new Uint8Array(t.dictionary):t.dictionary,(i=He(this.strm,r))!==st)throw new Error(Q[i]);this._dict_set=!0}}function ht(e,t){var i=new ct(t);if(i.push(e,!0),i.err)throw i.msg||Q[i.err];return i.result}ct.prototype.push=function(e,t){var i,r,n=this.strm,s=this.options.chunkSize;if(this.ended)return!1;for(r=t===~~t?t:!0===t?nt:tt,"string"==typeof e?n.input=Ye(e):"[object ArrayBuffer]"===et.call(e)?n.input=new Uint8Array(e):n.input=e,n.next_in=0,n.avail_in=n.input.length;;)if(0===n.avail_out&&(n.output=new Uint8Array(s),n.next_out=0,n.avail_out=s),(r===it||r===rt)&&n.avail_out<=6)this.onData(n.output.subarray(0,n.next_out)),n.avail_out=0;else{if((i=Ve(n,r))===ot)return n.next_out>0&&this.onData(n.output.subarray(0,n.next_out)),i=Qe(this.strm),this.onEnd(i),this.ended=!0,i===st;if(0!==n.avail_out){if(r>0&&n.next_out>0)this.onData(n.output.subarray(0,n.next_out)),n.avail_out=0;else if(0===n.avail_in)break}else this.onData(n.output)}return!0},ct.prototype.onData=function(e){this.chunks.push(e)},ct.prototype.onEnd=function(e){e===st&&(this.result=We(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg};var At=ct,dt=ht,pt=function(e,t){return(t=t||{}).raw=!0,ht(e,t)},ft=function(e,t){return(t=t||{}).gzip=!0,ht(e,t)},gt=16209,mt=function(e,t){var i,r,n,s,o,a,l,u,c,h,A,d,p,f,g,m,v,_,y,b,w,x,B,P,C=e.state;i=e.next_in,B=e.input,r=i+(e.avail_in-5),n=e.next_out,P=e.output,s=n-(t-e.avail_out),o=n+(e.avail_out-257),a=C.dmax,l=C.wsize,u=C.whave,c=C.wnext,h=C.window,A=C.hold,d=C.bits,p=C.lencode,f=C.distcode,g=(1<<C.lenbits)-1,m=(1<<C.distbits)-1;e:do{d<15&&(A+=B[i++]<<d,d+=8,A+=B[i++]<<d,d+=8),v=p[A&g];t:for(;;){if(A>>>=_=v>>>24,d-=_,0===(_=v>>>16&255))P[n++]=65535&v;else{if(!(16&_)){if(!(64&_)){v=p[(65535&v)+(A&(1<<_)-1)];continue t}if(32&_){C.mode=16191;break e}e.msg="invalid literal/length code",C.mode=gt;break e}y=65535&v,(_&=15)&&(d<_&&(A+=B[i++]<<d,d+=8),y+=A&(1<<_)-1,A>>>=_,d-=_),d<15&&(A+=B[i++]<<d,d+=8,A+=B[i++]<<d,d+=8),v=f[A&m];i:for(;;){if(A>>>=_=v>>>24,d-=_,!(16&(_=v>>>16&255))){if(!(64&_)){v=f[(65535&v)+(A&(1<<_)-1)];continue i}e.msg="invalid distance code",C.mode=gt;break e}if(b=65535&v,d<(_&=15)&&(A+=B[i++]<<d,(d+=8)<_&&(A+=B[i++]<<d,d+=8)),(b+=A&(1<<_)-1)>a){e.msg="invalid distance too far back",C.mode=gt;break e}if(A>>>=_,d-=_,b>(_=n-s)){if((_=b-_)>u&&C.sane){e.msg="invalid distance too far back",C.mode=gt;break e}if(w=0,x=h,0===c){if(w+=l-_,_<y){y-=_;do{P[n++]=h[w++]}while(--_);w=n-b,x=P}}else if(c<_){if(w+=l+c-_,(_-=c)<y){y-=_;do{P[n++]=h[w++]}while(--_);if(w=0,c<y){y-=_=c;do{P[n++]=h[w++]}while(--_);w=n-b,x=P}}}else if(w+=c-_,_<y){y-=_;do{P[n++]=h[w++]}while(--_);w=n-b,x=P}for(;y>2;)P[n++]=x[w++],P[n++]=x[w++],P[n++]=x[w++],y-=3;y&&(P[n++]=x[w++],y>1&&(P[n++]=x[w++]))}else{w=n-b;do{P[n++]=P[w++],P[n++]=P[w++],P[n++]=P[w++],y-=3}while(y>2);y&&(P[n++]=P[w++],y>1&&(P[n++]=P[w++]))}break}}break}}while(i<r&&n<o);i-=y=d>>3,A&=(1<<(d-=y<<3))-1,e.next_in=i,e.next_out=n,e.avail_in=i<r?r-i+5:5-(i-r),e.avail_out=n<o?o-n+257:257-(n-o),C.hold=A,C.bits=d},vt=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]),_t=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]),yt=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]),bt=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]),wt=function(e,t,i,r,n,s,o,a){var l,u,c,h,A,d,p,f,g,m=a.bits,v=0,_=0,y=0,b=0,w=0,x=0,B=0,P=0,C=0,M=0,k=null,E=new Uint16Array(16),S=new Uint16Array(16),T=null;for(v=0;v<=15;v++)E[v]=0;for(_=0;_<r;_++)E[t[i+_]]++;for(w=m,b=15;b>=1&&0===E[b];b--);if(w>b&&(w=b),0===b)return n[s++]=20971520,n[s++]=20971520,a.bits=1,0;for(y=1;y<b&&0===E[y];y++);for(w<y&&(w=y),P=1,v=1;v<=15;v++)if(P<<=1,(P-=E[v])<0)return-1;if(P>0&&(0===e||1!==b))return-1;for(S[1]=0,v=1;v<15;v++)S[v+1]=S[v]+E[v];for(_=0;_<r;_++)0!==t[i+_]&&(o[S[t[i+_]]++]=_);if(0===e?(k=T=o,d=20):1===e?(k=vt,T=_t,d=257):(k=yt,T=bt,d=0),M=0,_=0,v=y,A=s,x=w,B=0,c=-1,h=(C=1<<w)-1,1===e&&C>852||2===e&&C>592)return 1;for(;;){p=v-B,o[_]+1<d?(f=0,g=o[_]):o[_]>=d?(f=T[o[_]-d],g=k[o[_]-d]):(f=96,g=0),l=1<<v-B,y=u=1<<x;do{n[A+(M>>B)+(u-=l)]=p<<24|f<<16|g}while(0!==u);for(l=1<<v-1;M&l;)l>>=1;if(0!==l?(M&=l-1,M+=l):M=0,_++,0==--E[v]){if(v===b)break;v=t[i+o[_]]}if(v>w&&(M&h)!==c){for(0===B&&(B=w),A+=y,P=1<<(x=v-B);x+B<b&&!((P-=E[x+B])<=0);)x++,P<<=1;if(C+=1<<x,1===e&&C>852||2===e&&C>592)return 1;n[c=M&h]=w<<24|x<<16|A-s}}return 0!==M&&(n[A+M]=v-B<<24|64<<16),a.bits=w,0},xt=H.Z_FINISH,Bt=H.Z_BLOCK,Pt=H.Z_TREES,Ct=H.Z_OK,Mt=H.Z_STREAM_END,kt=H.Z_NEED_DICT,Et=H.Z_STREAM_ERROR,St=H.Z_DATA_ERROR,Tt=H.Z_MEM_ERROR,It=H.Z_BUF_ERROR,Ft=H.Z_DEFLATED,Dt=16180,Rt=16190,Ot=16191,Lt=16192,jt=16194,Ut=16199,Nt=16200,Vt=16206,Qt=16209,Ht=function(e){return(e>>>24&255)+(e>>>8&65280)+((65280&e)<<8)+((255&e)<<24)};function Gt(){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}var zt,Wt,Kt=function(e){if(!e)return 1;var t=e.state;return!t||t.strm!==e||t.mode<Dt||t.mode>16211?1:0},Xt=function(e){if(Kt(e))return Et;var t=e.state;return e.total_in=e.total_out=t.total=0,e.msg="",t.wrap&&(e.adler=1&t.wrap),t.mode=Dt,t.last=0,t.havedict=0,t.flags=-1,t.dmax=32768,t.head=null,t.hold=0,t.bits=0,t.lencode=t.lendyn=new Int32Array(852),t.distcode=t.distdyn=new Int32Array(592),t.sane=1,t.back=-1,Ct},qt=function(e){if(Kt(e))return Et;var t=e.state;return t.wsize=0,t.whave=0,t.wnext=0,Xt(e)},Yt=function(e,t){var i;if(Kt(e))return Et;var r=e.state;return t<0?(i=0,t=-t):(i=5+(t>>4),t<48&&(t&=15)),t&&(t<8||t>15)?Et:(null!==r.window&&r.wbits!==t&&(r.window=null),r.wrap=i,r.wbits=t,qt(e))},Jt=function(e,t){if(!e)return Et;var i=new Gt;e.state=i,i.strm=e,i.window=null,i.mode=Dt;var r=Yt(e,t);return r!==Ct&&(e.state=null),r},Zt=!0,$t=function(e){if(Zt){zt=new Int32Array(512),Wt=new Int32Array(32);for(var t=0;t<144;)e.lens[t++]=8;for(;t<256;)e.lens[t++]=9;for(;t<280;)e.lens[t++]=7;for(;t<288;)e.lens[t++]=8;for(wt(1,e.lens,0,288,zt,0,e.work,{bits:9}),t=0;t<32;)e.lens[t++]=5;wt(2,e.lens,0,32,Wt,0,e.work,{bits:5}),Zt=!1}e.lencode=zt,e.lenbits=9,e.distcode=Wt,e.distbits=5},ei=function(e,t,i,r){var n,s=e.state;return null===s.window&&(s.wsize=1<<s.wbits,s.wnext=0,s.whave=0,s.window=new Uint8Array(s.wsize)),r>=s.wsize?(s.window.set(t.subarray(i-s.wsize,i),0),s.wnext=0,s.whave=s.wsize):((n=s.wsize-s.wnext)>r&&(n=r),s.window.set(t.subarray(i-r,i-r+n),s.wnext),(r-=n)?(s.window.set(t.subarray(i-r,i),0),s.wnext=r,s.whave=s.wsize):(s.wnext+=n,s.wnext===s.wsize&&(s.wnext=0),s.whave<s.wsize&&(s.whave+=n))),0},ti=qt,ii=Jt,ri=function(e,t){var i,r,n,s,o,a,l,u,c,h,A,d,p,f,g,m,v,_,y,b,w,x,B,P,C=0,M=new Uint8Array(4),k=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]);if(Kt(e)||!e.output||!e.input&&0!==e.avail_in)return Et;(i=e.state).mode===Ot&&(i.mode=Lt),o=e.next_out,n=e.output,l=e.avail_out,s=e.next_in,r=e.input,a=e.avail_in,u=i.hold,c=i.bits,h=a,A=l,x=Ct;e:for(;;)switch(i.mode){case Dt:if(0===i.wrap){i.mode=Lt;break}for(;c<16;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}if(2&i.wrap&&35615===u){0===i.wbits&&(i.wbits=15),i.check=0,M[0]=255&u,M[1]=u>>>8&255,i.check=V(i.check,M,2,0),u=0,c=0,i.mode=16181;break}if(i.head&&(i.head.done=!1),!(1&i.wrap)||(((255&u)<<8)+(u>>8))%31){e.msg="incorrect header check",i.mode=Qt;break}if((15&u)!==Ft){e.msg="unknown compression method",i.mode=Qt;break}if(c-=4,w=8+(15&(u>>>=4)),0===i.wbits&&(i.wbits=w),w>15||w>i.wbits){e.msg="invalid window size",i.mode=Qt;break}i.dmax=1<<i.wbits,i.flags=0,e.adler=i.check=1,i.mode=512&u?16189:Ot,u=0,c=0;break;case 16181:for(;c<16;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}if(i.flags=u,(255&i.flags)!==Ft){e.msg="unknown compression method",i.mode=Qt;break}if(57344&i.flags){e.msg="unknown header flags set",i.mode=Qt;break}i.head&&(i.head.text=u>>8&1),512&i.flags&&4&i.wrap&&(M[0]=255&u,M[1]=u>>>8&255,i.check=V(i.check,M,2,0)),u=0,c=0,i.mode=16182;case 16182:for(;c<32;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}i.head&&(i.head.time=u),512&i.flags&&4&i.wrap&&(M[0]=255&u,M[1]=u>>>8&255,M[2]=u>>>16&255,M[3]=u>>>24&255,i.check=V(i.check,M,4,0)),u=0,c=0,i.mode=16183;case 16183:for(;c<16;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}i.head&&(i.head.xflags=255&u,i.head.os=u>>8),512&i.flags&&4&i.wrap&&(M[0]=255&u,M[1]=u>>>8&255,i.check=V(i.check,M,2,0)),u=0,c=0,i.mode=16184;case 16184:if(1024&i.flags){for(;c<16;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}i.length=u,i.head&&(i.head.extra_len=u),512&i.flags&&4&i.wrap&&(M[0]=255&u,M[1]=u>>>8&255,i.check=V(i.check,M,2,0)),u=0,c=0}else i.head&&(i.head.extra=null);i.mode=16185;case 16185:if(1024&i.flags&&((d=i.length)>a&&(d=a),d&&(i.head&&(w=i.head.extra_len-i.length,i.head.extra||(i.head.extra=new Uint8Array(i.head.extra_len)),i.head.extra.set(r.subarray(s,s+d),w)),512&i.flags&&4&i.wrap&&(i.check=V(i.check,r,d,s)),a-=d,s+=d,i.length-=d),i.length))break e;i.length=0,i.mode=16186;case 16186:if(2048&i.flags){if(0===a)break e;d=0;do{w=r[s+d++],i.head&&w&&i.length<65536&&(i.head.name+=String.fromCharCode(w))}while(w&&d<a);if(512&i.flags&&4&i.wrap&&(i.check=V(i.check,r,d,s)),a-=d,s+=d,w)break e}else i.head&&(i.head.name=null);i.length=0,i.mode=16187;case 16187:if(4096&i.flags){if(0===a)break e;d=0;do{w=r[s+d++],i.head&&w&&i.length<65536&&(i.head.comment+=String.fromCharCode(w))}while(w&&d<a);if(512&i.flags&&4&i.wrap&&(i.check=V(i.check,r,d,s)),a-=d,s+=d,w)break e}else i.head&&(i.head.comment=null);i.mode=16188;case 16188:if(512&i.flags){for(;c<16;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}if(4&i.wrap&&u!==(65535&i.check)){e.msg="header crc mismatch",i.mode=Qt;break}u=0,c=0}i.head&&(i.head.hcrc=i.flags>>9&1,i.head.done=!0),e.adler=i.check=0,i.mode=Ot;break;case 16189:for(;c<32;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}e.adler=i.check=Ht(u),u=0,c=0,i.mode=Rt;case Rt:if(0===i.havedict)return e.next_out=o,e.avail_out=l,e.next_in=s,e.avail_in=a,i.hold=u,i.bits=c,kt;e.adler=i.check=1,i.mode=Ot;case Ot:if(t===Bt||t===Pt)break e;case Lt:if(i.last){u>>>=7&c,c-=7&c,i.mode=Vt;break}for(;c<3;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}switch(i.last=1&u,c-=1,3&(u>>>=1)){case 0:i.mode=16193;break;case 1:if($t(i),i.mode=Ut,t===Pt){u>>>=2,c-=2;break e}break;case 2:i.mode=16196;break;case 3:e.msg="invalid block type",i.mode=Qt}u>>>=2,c-=2;break;case 16193:for(u>>>=7&c,c-=7&c;c<32;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}if((65535&u)!=(u>>>16^65535)){e.msg="invalid stored block lengths",i.mode=Qt;break}if(i.length=65535&u,u=0,c=0,i.mode=jt,t===Pt)break e;case jt:i.mode=16195;case 16195:if(d=i.length){if(d>a&&(d=a),d>l&&(d=l),0===d)break e;n.set(r.subarray(s,s+d),o),a-=d,s+=d,l-=d,o+=d,i.length-=d;break}i.mode=Ot;break;case 16196:for(;c<14;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}if(i.nlen=257+(31&u),u>>>=5,c-=5,i.ndist=1+(31&u),u>>>=5,c-=5,i.ncode=4+(15&u),u>>>=4,c-=4,i.nlen>286||i.ndist>30){e.msg="too many length or distance symbols",i.mode=Qt;break}i.have=0,i.mode=16197;case 16197:for(;i.have<i.ncode;){for(;c<3;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}i.lens[k[i.have++]]=7&u,u>>>=3,c-=3}for(;i.have<19;)i.lens[k[i.have++]]=0;if(i.lencode=i.lendyn,i.lenbits=7,B={bits:i.lenbits},x=wt(0,i.lens,0,19,i.lencode,0,i.work,B),i.lenbits=B.bits,x){e.msg="invalid code lengths set",i.mode=Qt;break}i.have=0,i.mode=16198;case 16198:for(;i.have<i.nlen+i.ndist;){for(;m=(C=i.lencode[u&(1<<i.lenbits)-1])>>>16&255,v=65535&C,!((g=C>>>24)<=c);){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}if(v<16)u>>>=g,c-=g,i.lens[i.have++]=v;else{if(16===v){for(P=g+2;c<P;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}if(u>>>=g,c-=g,0===i.have){e.msg="invalid bit length repeat",i.mode=Qt;break}w=i.lens[i.have-1],d=3+(3&u),u>>>=2,c-=2}else if(17===v){for(P=g+3;c<P;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}c-=g,w=0,d=3+(7&(u>>>=g)),u>>>=3,c-=3}else{for(P=g+7;c<P;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}c-=g,w=0,d=11+(127&(u>>>=g)),u>>>=7,c-=7}if(i.have+d>i.nlen+i.ndist){e.msg="invalid bit length repeat",i.mode=Qt;break}for(;d--;)i.lens[i.have++]=w}}if(i.mode===Qt)break;if(0===i.lens[256]){e.msg="invalid code -- missing end-of-block",i.mode=Qt;break}if(i.lenbits=9,B={bits:i.lenbits},x=wt(1,i.lens,0,i.nlen,i.lencode,0,i.work,B),i.lenbits=B.bits,x){e.msg="invalid literal/lengths set",i.mode=Qt;break}if(i.distbits=6,i.distcode=i.distdyn,B={bits:i.distbits},x=wt(2,i.lens,i.nlen,i.ndist,i.distcode,0,i.work,B),i.distbits=B.bits,x){e.msg="invalid distances set",i.mode=Qt;break}if(i.mode=Ut,t===Pt)break e;case Ut:i.mode=Nt;case Nt:if(a>=6&&l>=258){e.next_out=o,e.avail_out=l,e.next_in=s,e.avail_in=a,i.hold=u,i.bits=c,mt(e,A),o=e.next_out,n=e.output,l=e.avail_out,s=e.next_in,r=e.input,a=e.avail_in,u=i.hold,c=i.bits,i.mode===Ot&&(i.back=-1);break}for(i.back=0;m=(C=i.lencode[u&(1<<i.lenbits)-1])>>>16&255,v=65535&C,!((g=C>>>24)<=c);){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}if(m&&!(240&m)){for(_=g,y=m,b=v;m=(C=i.lencode[b+((u&(1<<_+y)-1)>>_)])>>>16&255,v=65535&C,!(_+(g=C>>>24)<=c);){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}u>>>=_,c-=_,i.back+=_}if(u>>>=g,c-=g,i.back+=g,i.length=v,0===m){i.mode=16205;break}if(32&m){i.back=-1,i.mode=Ot;break}if(64&m){e.msg="invalid literal/length code",i.mode=Qt;break}i.extra=15&m,i.mode=16201;case 16201:if(i.extra){for(P=i.extra;c<P;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}i.length+=u&(1<<i.extra)-1,u>>>=i.extra,c-=i.extra,i.back+=i.extra}i.was=i.length,i.mode=16202;case 16202:for(;m=(C=i.distcode[u&(1<<i.distbits)-1])>>>16&255,v=65535&C,!((g=C>>>24)<=c);){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}if(!(240&m)){for(_=g,y=m,b=v;m=(C=i.distcode[b+((u&(1<<_+y)-1)>>_)])>>>16&255,v=65535&C,!(_+(g=C>>>24)<=c);){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}u>>>=_,c-=_,i.back+=_}if(u>>>=g,c-=g,i.back+=g,64&m){e.msg="invalid distance code",i.mode=Qt;break}i.offset=v,i.extra=15&m,i.mode=16203;case 16203:if(i.extra){for(P=i.extra;c<P;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}i.offset+=u&(1<<i.extra)-1,u>>>=i.extra,c-=i.extra,i.back+=i.extra}if(i.offset>i.dmax){e.msg="invalid distance too far back",i.mode=Qt;break}i.mode=16204;case 16204:if(0===l)break e;if(d=A-l,i.offset>d){if((d=i.offset-d)>i.whave&&i.sane){e.msg="invalid distance too far back",i.mode=Qt;break}d>i.wnext?(d-=i.wnext,p=i.wsize-d):p=i.wnext-d,d>i.length&&(d=i.length),f=i.window}else f=n,p=o-i.offset,d=i.length;d>l&&(d=l),l-=d,i.length-=d;do{n[o++]=f[p++]}while(--d);0===i.length&&(i.mode=Nt);break;case 16205:if(0===l)break e;n[o++]=i.length,l--,i.mode=Nt;break;case Vt:if(i.wrap){for(;c<32;){if(0===a)break e;a--,u|=r[s++]<<c,c+=8}if(A-=l,e.total_out+=A,i.total+=A,4&i.wrap&&A&&(e.adler=i.check=i.flags?V(i.check,n,A,o-A):U(i.check,n,A,o-A)),A=l,4&i.wrap&&(i.flags?u:Ht(u))!==i.check){e.msg="incorrect data check",i.mode=Qt;break}u=0,c=0}i.mode=16207;case 16207:if(i.wrap&&i.flags){for(;c<32;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}if(4&i.wrap&&u!==(4294967295&i.total)){e.msg="incorrect length check",i.mode=Qt;break}u=0,c=0}i.mode=16208;case 16208:x=Mt;break e;case Qt:x=St;break e;case 16210:return Tt;default:return Et}return e.next_out=o,e.avail_out=l,e.next_in=s,e.avail_in=a,i.hold=u,i.bits=c,(i.wsize||A!==e.avail_out&&i.mode<Qt&&(i.mode<Vt||t!==xt))&&ei(e,e.output,e.next_out,A-e.avail_out),h-=e.avail_in,A-=e.avail_out,e.total_in+=h,e.total_out+=A,i.total+=A,4&i.wrap&&A&&(e.adler=i.check=i.flags?V(i.check,n,A,e.next_out-A):U(i.check,n,A,e.next_out-A)),e.data_type=i.bits+(i.last?64:0)+(i.mode===Ot?128:0)+(i.mode===Ut||i.mode===jt?256:0),(0===h&&0===A||t===xt)&&x===Ct&&(x=It),x},ni=function(e){if(Kt(e))return Et;var t=e.state;return t.window&&(t.window=null),e.state=null,Ct},si=function(e,t){if(Kt(e))return Et;var i=e.state;return 2&i.wrap?(i.head=t,t.done=!1,Ct):Et},oi=function(e,t){var i,r=t.length;return Kt(e)?Et:0!==(i=e.state).wrap&&i.mode!==Rt?Et:i.mode===Rt&&U(1,t,r,0)!==i.check?St:ei(e,t,r,r)?(i.mode=16210,Tt):(i.havedict=1,Ct)},ai=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},li=Object.prototype.toString,ui=H.Z_NO_FLUSH,ci=H.Z_FINISH,hi=H.Z_OK,Ai=H.Z_STREAM_END,di=H.Z_NEED_DICT,pi=H.Z_STREAM_ERROR,fi=H.Z_DATA_ERROR,gi=H.Z_MEM_ERROR;function mi(e){this.options=ze({chunkSize:65536,windowBits:15,to:""},e||{});var t=this.options;t.raw&&t.windowBits>=0&&t.windowBits<16&&(t.windowBits=-t.windowBits,0===t.windowBits&&(t.windowBits=-15)),!(t.windowBits>=0&&t.windowBits<16)||e&&e.windowBits||(t.windowBits+=32),t.windowBits>15&&t.windowBits<48&&!(15&t.windowBits)&&(t.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new $e,this.strm.avail_out=0;var i=ii(this.strm,t.windowBits);if(i!==hi)throw new Error(Q[i]);if(this.header=new ai,si(this.strm,this.header),t.dictionary&&("string"==typeof t.dictionary?t.dictionary=Ye(t.dictionary):"[object ArrayBuffer]"===li.call(t.dictionary)&&(t.dictionary=new Uint8Array(t.dictionary)),t.raw&&(i=oi(this.strm,t.dictionary))!==hi))throw new Error(Q[i])}function vi(e,t){var i=new mi(t);if(i.push(e),i.err)throw i.msg||Q[i.err];return i.result}mi.prototype.push=function(e,t){var i,r,n,s=this.strm,o=this.options.chunkSize,a=this.options.dictionary;if(this.ended)return!1;for(r=t===~~t?t:!0===t?ci:ui,"[object ArrayBuffer]"===li.call(e)?s.input=new Uint8Array(e):s.input=e,s.next_in=0,s.avail_in=s.input.length;;){for(0===s.avail_out&&(s.output=new Uint8Array(o),s.next_out=0,s.avail_out=o),(i=ri(s,r))===di&&a&&((i=oi(s,a))===hi?i=ri(s,r):i===fi&&(i=di));s.avail_in>0&&i===Ai&&s.state.wrap>0&&0!==e[s.next_in];)ti(s),i=ri(s,r);switch(i){case pi:case fi:case di:case gi:return this.onEnd(i),this.ended=!0,!1}if(n=s.avail_out,s.next_out&&(0===s.avail_out||i===Ai))if("string"===this.options.to){var l=Ze(s.output,s.next_out),u=s.next_out-l,c=Je(s.output,l);s.next_out=u,s.avail_out=o-u,u&&s.output.set(s.output.subarray(l,l+u),0),this.onData(c)}else this.onData(s.output.length===s.next_out?s.output:s.output.subarray(0,s.next_out));if(i!==hi||0!==n){if(i===Ai)return i=ni(this.strm),this.onEnd(i),this.ended=!0,!0;if(0===s.avail_in)break}}return!0},mi.prototype.onData=function(e){this.chunks.push(e)},mi.prototype.onEnd=function(e){e===hi&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=We(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg};var _i=function(e,t){return(t=t||{}).raw=!0,vi(e,t)},yi=At,bi=dt,wi=pt,xi=ft,Bi=mi,Pi=vi,Ci=_i,Mi=vi,ki=H,Ei={Deflate:yi,deflate:bi,deflateRaw:wi,gzip:xi,Inflate:Bi,inflate:Pi,inflateRaw:Ci,ungzip:Mi,constants:ki};e.Deflate=yi,e.Inflate=Bi,e.constants=ki,e.default=Ei,e.deflate=bi,e.deflateRaw=wi,e.gzip=xi,e.inflate=Pi,e.inflateRaw=Ci,e.ungzip=Mi,Object.defineProperty(e,"__esModule",{value:!0})});var Pk=Object.freeze({__proto__:null}),Ck=window.pako||Pk;Ck.inflate||(Ck=Ck.default);var Mk=Y.vec4(),kk=Y.vec4();var Ek,Sk=(Ek=new Float32Array(3),function(e){return Ek[0]=e[0]/255,Ek[1]=e[1]/255,Ek[2]=e[2]/255,Ek});function Tk(e,t){var i=[];if(t.length>1)for(var r=0,n=t.length-1;r<n;r++)i.push(t[r]),i.push(t[r+1]);else if(e.length>1)for(var s=0,o=e.length/3-1;s<o;s++)i.push(s),i.push(s+1);return i}!function(){var e=document.createElement("canvas"),t=e.getContext("2d")}();var Ik={version:10,parse:function(e,t,i,r,n,s){var o=function(e){var t=0;return{metadata:e[t++],textureData:e[t++],eachTextureDataPortion:e[t++],eachTextureAttributes:e[t++],positions:e[t++],normals:e[t++],colors:e[t++],uvs:e[t++],indices:e[t++],edgeIndices:e[t++],eachTextureSetTextures:e[t++],matrices:e[t++],reusedGeometriesDecodeMatrix:e[t++],eachGeometryPrimitiveType:e[t++],eachGeometryPositionsPortion:e[t++],eachGeometryNormalsPortion:e[t++],eachGeometryColorsPortion:e[t++],eachGeometryUVsPortion:e[t++],eachGeometryIndicesPortion:e[t++],eachGeometryEdgeIndicesPortion:e[t++],eachMeshGeometriesPortion:e[t++],eachMeshMatricesPortion:e[t++],eachMeshTextureSet:e[t++],eachMeshMaterialAttributes:e[t++],eachEntityId:e[t++],eachEntityMeshesPortion:e[t++],eachTileAABB:e[t++],eachTileEntitiesPortion:e[t++]}}(i),a=function(e){function t(e,t){return 0===e.length?[]:Ck.inflate(e,t).buffer}return{metadata:JSON.parse(Ck.inflate(e.metadata,{to:"string"})),textureData:new Uint8Array(t(e.textureData)),eachTextureDataPortion:new Uint32Array(t(e.eachTextureDataPortion)),eachTextureAttributes:new Uint16Array(t(e.eachTextureAttributes)),positions:new Uint16Array(t(e.positions)),normals:new Int8Array(t(e.normals)),colors:new Uint8Array(t(e.colors)),uvs:new Float32Array(t(e.uvs)),indices:new Uint32Array(t(e.indices)),edgeIndices:new Uint32Array(t(e.edgeIndices)),eachTextureSetTextures:new Int32Array(t(e.eachTextureSetTextures)),matrices:new Float32Array(t(e.matrices)),reusedGeometriesDecodeMatrix:new Float32Array(t(e.reusedGeometriesDecodeMatrix)),eachGeometryPrimitiveType:new Uint8Array(t(e.eachGeometryPrimitiveType)),eachGeometryPositionsPortion:new Uint32Array(t(e.eachGeometryPositionsPortion)),eachGeometryNormalsPortion:new Uint32Array(t(e.eachGeometryNormalsPortion)),eachGeometryColorsPortion:new Uint32Array(t(e.eachGeometryColorsPortion)),eachGeometryUVsPortion:new Uint32Array(t(e.eachGeometryUVsPortion)),eachGeometryIndicesPortion:new Uint32Array(t(e.eachGeometryIndicesPortion)),eachGeometryEdgeIndicesPortion:new Uint32Array(t(e.eachGeometryEdgeIndicesPortion)),eachMeshGeometriesPortion:new Uint32Array(t(e.eachMeshGeometriesPortion)),eachMeshMatricesPortion:new Uint32Array(t(e.eachMeshMatricesPortion)),eachMeshTextureSet:new Int32Array(t(e.eachMeshTextureSet)),eachMeshMaterialAttributes:new Uint8Array(t(e.eachMeshMaterialAttributes)),eachEntityId:JSON.parse(Ck.inflate(e.eachEntityId,{to:"string"})),eachEntityMeshesPortion:new Uint32Array(t(e.eachEntityMeshesPortion)),eachTileAABB:new Float64Array(t(e.eachTileAABB)),eachTileEntitiesPortion:new Uint32Array(t(e.eachTileEntitiesPortion))}}(o);!function(e,t,i,r,n,s){var o=s.getNextId(),a=i.metadata,l=i.textureData,u=i.eachTextureDataPortion,c=i.eachTextureAttributes,h=i.positions,A=i.normals,d=i.colors,p=i.uvs,f=i.indices,g=i.edgeIndices,m=i.eachTextureSetTextures,v=i.matrices,_=i.reusedGeometriesDecodeMatrix,y=i.eachGeometryPrimitiveType,b=i.eachGeometryPositionsPortion,w=i.eachGeometryNormalsPortion,x=i.eachGeometryColorsPortion,B=i.eachGeometryUVsPortion,P=i.eachGeometryIndicesPortion,C=i.eachGeometryEdgeIndicesPortion,M=i.eachMeshGeometriesPortion,k=i.eachMeshMatricesPortion,E=i.eachMeshTextureSet,S=i.eachMeshMaterialAttributes,T=i.eachEntityId,I=i.eachEntityMeshesPortion,F=i.eachTileAABB,D=i.eachTileEntitiesPortion,R=u.length,O=m.length/5,L=b.length,j=M.length,U=I.length,N=D.length;n&&n.loadData(a,{includeTypes:t.includeTypes,excludeTypes:t.excludeTypes,globalizeObjectIds:t.globalizeObjectIds});for(var V=0;V<R;V++){var Q=V===R-1,H=u[V],G=Q?l.length:u[V+1],z=G-H>0,W=9*V,K=1===c[W+0];c[W+1],c[W+2],c[W+3];var X=c[W+4],q=c[W+5],J=c[W+6],Z=c[W+7],$=c[W+8];if(z){var ee=new Uint8Array(l.subarray(H,G)).buffer,te="".concat(o,"-texture-").concat(V);K?r.createTexture({id:te,buffers:[ee],minFilter:X,magFilter:q,wrapS:J,wrapT:Z,wrapR:$}):r.createTexture({id:te,imageBuffer:ee,minFilter:X,magFilter:q,wrapS:J,wrapT:Z,wrapR:$})}}for(var ie=0;ie<O;ie++){var re=5*ie,se="".concat(o,"-textureSet-").concat(ie),oe=m[re+0],ae=m[re+1],le=m[re+2],ue=m[re+3],ce=m[re+4];r.createTextureSet({id:se,colorTextureId:oe>=0?"".concat(o,"-texture-").concat(oe):null,normalsTextureId:le>=0?"".concat(o,"-texture-").concat(le):null,metallicRoughnessTextureId:ae>=0?"".concat(o,"-texture-").concat(ae):null,emissiveTextureId:ue>=0?"".concat(o,"-texture-").concat(ue):null,occlusionTextureId:ce>=0?"".concat(o,"-texture-").concat(ce):null})}for(var he=new Uint32Array(L),Ae=0;Ae<j;Ae++){var de=M[Ae];void 0!==he[de]?he[de]++:he[de]=1}for(var pe=Y.vec3(),fe=Y.AABB3(),ge={},me=0;me<N;me++){var ve=me===N-1,_e=D[me],ye=ve?U-1:D[me+1]-1,be=6*me,we=F.subarray(be,be+6);Y.getAABB3Center(we,pe),fe[0]=we[0]-pe[0],fe[1]=we[1]-pe[1],fe[2]=we[2]-pe[2],fe[3]=we[3]-pe[0],fe[4]=we[4]-pe[1],fe[5]=we[5]-pe[2];for(var xe=xi.createPositionsDecodeMatrix(fe),Be={},Pe=_e;Pe<=ye;Pe++){var Ce=T[Pe],Me=t.globalizeObjectIds?Y.globalizeObjectId(r.id,Ce):Ce,ke=Pe===U-1,Ee=I[Pe],Se=ke?M.length-1:I[Pe+1]-1,Te=[],Ie=e.metaScene.metaObjects[Me],Fe={},De={};if(Ie){if(t.excludeTypesMap&&Ie.type&&t.excludeTypesMap[Ie.type])continue;if(t.includeTypesMap&&Ie.type&&!t.includeTypesMap[Ie.type])continue;var Re=t.objectDefaults?t.objectDefaults[Ie.type]||t.objectDefaults.DEFAULT:null;Re&&(!1===Re.visible&&(Fe.visible=!1),!1===Re.pickable&&(Fe.pickable=!1),Re.colorize&&(De.color=Re.colorize),void 0!==Re.opacity&&null!==Re.opacity&&(De.opacity=Re.opacity),void 0!==Re.metallic&&null!==Re.metallic&&(De.metallic=Re.metallic),void 0!==Re.roughness&&null!==Re.roughness&&(De.roughness=Re.roughness))}else if(t.excludeUnclassifiedObjects)continue;for(var Oe=Ee;Oe<=Se;Oe++){var Le=M[Oe],je=he[Le]>1,Ue=Le===L-1,Ne=E[Oe],Ve=Ne>=0?"".concat(o,"-textureSet-").concat(Ne):null,Qe=Sk(S.subarray(6*Oe,6*Oe+3)),He=S[6*Oe+3]/255,Ge=S[6*Oe+4]/255,ze=S[6*Oe+5]/255,We=s.getNextId();if(je){var Ke=k[Oe],Xe=v.slice(Ke,Ke+16),qe="".concat(o,"-geometry.").concat(me,".").concat(Le),Ye=ge[qe];if(!Ye){Ye={batchThisMesh:!t.reuseGeometries};var Je=!1;switch(y[Le]){case 0:Ye.primitiveName="solid",Ye.geometryPositions=h.subarray(b[Le],Ue?h.length:b[Le+1]),Ye.geometryNormals=A.subarray(w[Le],Ue?A.length:w[Le+1]),Ye.geometryUVs=p.subarray(B[Le],Ue?p.length:B[Le+1]),Ye.geometryIndices=f.subarray(P[Le],Ue?f.length:P[Le+1]),Ye.geometryEdgeIndices=g.subarray(C[Le],Ue?g.length:C[Le+1]),Je=Ye.geometryPositions.length>0&&Ye.geometryIndices.length>0;break;case 1:Ye.primitiveName="surface",Ye.geometryPositions=h.subarray(b[Le],Ue?h.length:b[Le+1]),Ye.geometryNormals=A.subarray(w[Le],Ue?A.length:w[Le+1]),Ye.geometryUVs=p.subarray(B[Le],Ue?p.length:B[Le+1]),Ye.geometryIndices=f.subarray(P[Le],Ue?f.length:P[Le+1]),Ye.geometryEdgeIndices=g.subarray(C[Le],Ue?g.length:C[Le+1]),Je=Ye.geometryPositions.length>0&&Ye.geometryIndices.length>0;break;case 2:Ye.primitiveName="points",Ye.geometryPositions=h.subarray(b[Le],Ue?h.length:b[Le+1]),Ye.geometryColors=d.subarray(x[Le],Ue?d.length:x[Le+1]),Je=Ye.geometryPositions.length>0;break;case 3:Ye.primitiveName="lines",Ye.geometryPositions=h.subarray(b[Le],Ue?h.length:b[Le+1]),Ye.geometryIndices=f.subarray(P[Le],Ue?f.length:P[Le+1]),Je=Ye.geometryPositions.length>0&&Ye.geometryIndices.length>0;break;case 4:Ye.primitiveName="lines",Ye.geometryPositions=h.subarray(b[Le],Ue?h.length:b[Le+1]),Ye.geometryIndices=Tk(Ye.geometryPositions,f.subarray(P[Le],Ue?f.length:P[Le+1])),Je=Ye.geometryPositions.length>0&&Ye.geometryIndices.length>0;break;default:continue}if(Je||(Ye=null),Ye&&(Ye.geometryPositions.length,Ye.batchThisMesh)){Ye.decompressedPositions=new Float32Array(Ye.geometryPositions.length),Ye.transformedAndRecompressedPositions=new Uint16Array(Ye.geometryPositions.length);for(var Ze=Ye.geometryPositions,$e=Ye.decompressedPositions,et=0,tt=Ze.length;et<tt;et+=3)$e[et+0]=Ze[et+0]*_[0]+_[12],$e[et+1]=Ze[et+1]*_[5]+_[13],$e[et+2]=Ze[et+2]*_[10]+_[14];Ye.geometryPositions=null,ge[qe]=Ye}}if(Ye)if(Ye.batchThisMesh){for(var it=Ye.decompressedPositions,rt=Ye.transformedAndRecompressedPositions,nt=0,st=it.length;nt<st;nt+=3)Mk[0]=it[nt+0],Mk[1]=it[nt+1],Mk[2]=it[nt+2],Mk[3]=1,Y.transformVec4(Xe,Mk,kk),xi.compressPosition(kk,fe,Mk),rt[nt+0]=Mk[0],rt[nt+1]=Mk[1],rt[nt+2]=Mk[2];r.createMesh(ne.apply(De,{id:We,textureSetId:Ve,origin:pe,primitive:Ye.primitiveName,positionsCompressed:rt,normalsCompressed:Ye.geometryNormals,uv:Ye.geometryUVs,colorsCompressed:Ye.geometryColors,indices:Ye.geometryIndices,edgeIndices:Ye.geometryEdgeIndices,positionsDecodeMatrix:xe,color:Qe,metallic:Ge,roughness:ze,opacity:He})),Te.push(We)}else Be[qe]||(r.createGeometry({id:qe,primitive:Ye.primitiveName,positionsCompressed:Ye.geometryPositions,normalsCompressed:Ye.geometryNormals,uv:Ye.geometryUVs,colorsCompressed:Ye.geometryColors,indices:Ye.geometryIndices,edgeIndices:Ye.geometryEdgeIndices,positionsDecodeMatrix:_}),Be[qe]=!0),r.createMesh(ne.apply(De,{id:We,geometryId:qe,textureSetId:Ve,matrix:Xe,color:Qe,metallic:Ge,roughness:ze,opacity:He,origin:pe})),Te.push(We)}else{var ot=void 0,at=void 0,lt=void 0,ut=void 0,ct=void 0,ht=void 0,At=void 0,dt=!1;switch(y[Le]){case 0:ot="solid",at=h.subarray(b[Le],Ue?h.length:b[Le+1]),lt=A.subarray(w[Le],Ue?A.length:w[Le+1]),ut=p.subarray(B[Le],Ue?p.length:B[Le+1]),ht=f.subarray(P[Le],Ue?f.length:P[Le+1]),At=g.subarray(C[Le],Ue?g.length:C[Le+1]),dt=at.length>0&&ht.length>0;break;case 1:ot="surface",at=h.subarray(b[Le],Ue?h.length:b[Le+1]),lt=A.subarray(w[Le],Ue?A.length:w[Le+1]),ut=p.subarray(B[Le],Ue?p.length:B[Le+1]),ht=f.subarray(P[Le],Ue?f.length:P[Le+1]),At=g.subarray(C[Le],Ue?g.length:C[Le+1]),dt=at.length>0&&ht.length>0;break;case 2:ot="points",at=h.subarray(b[Le],Ue?h.length:b[Le+1]),ct=d.subarray(x[Le],Ue?d.length:x[Le+1]),dt=at.length>0;break;case 3:ot="lines",at=h.subarray(b[Le],Ue?h.length:b[Le+1]),ht=f.subarray(P[Le],Ue?f.length:P[Le+1]),dt=at.length>0&&ht.length>0;break;case 4:ot="lines",ht=Tk(at=h.subarray(b[Le],Ue?h.length:b[Le+1]),f.subarray(P[Le],Ue?f.length:P[Le+1])),dt=at.length>0&&ht.length>0;break;default:continue}dt&&(r.createMesh(ne.apply(De,{id:We,textureSetId:Ve,origin:pe,primitive:ot,positionsCompressed:at,normalsCompressed:lt,uv:ut&&ut.length>0?ut:null,colorsCompressed:ct,indices:ht&&ht.length>0?ht:null,edgeIndices:At,positionsDecodeMatrix:xe,color:Qe,metallic:Ge,roughness:ze,opacity:He})),Te.push(We))}}Te.length>0&&r.createEntity(ne.apply(Fe,{id:Me,isObject:!0,meshIds:Te}))}}}(e,t,a,r,n,s)},inflateMetadata:function(e){return JSON.parse(Ck.inflate(e,{to:"string"}))}},Fk={};Fk[Ik.version]=Ik;var Dk=function(){function e(t){var i,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return x(this,e),(i=d(this,e,["XTCLoader",t,r]))._maxGeometryBatchSize=r.maxGeometryBatchSize,i.textureTranscoder=r.textureTranscoder,i.dataSource=r.dataSource,i.objectDefaults=r.objectDefaults,i.includeTypes=r.includeTypes,i.excludeTypes=r.excludeTypes,i.excludeUnclassifiedObjects=r.excludeUnclassifiedObjects,i.reuseGeometries=r.reuseGeometries,i}return _(e,ge),P(e,[{key:"supportedVersions",get:function(){return Object.keys(Fk)}},{key:"textureTranscoder",get:function(){return this._textureTranscoder},set:function(e){this._textureTranscoder=e}},{key:"dataSource",get:function(){return this._dataSource},set:function(e){this._dataSource=e||new Bk}},{key:"objectDefaults",get:function(){return this._objectDefaults},set:function(e){this._objectDefaults=e||YM}},{key:"includeTypes",get:function(){return this._includeTypes},set:function(e){this._includeTypes=e}},{key:"excludeTypes",get:function(){return this._excludeTypes},set:function(e){this._excludeTypes=e}},{key:"excludeUnclassifiedObjects",get:function(){return this._excludeUnclassifiedObjects},set:function(e){this._excludeUnclassifiedObjects=!!e}},{key:"globalizeObjectIds",get:function(){return this._globalizeObjectIds},set:function(e){this._globalizeObjectIds=!!e}},{key:"reuseGeometries",get:function(){return this._reuseGeometries},set:function(e){this._reuseGeometries=!1!==e}},{key:"load",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(t.id&&this.viewer.scene.components[t.id]&&(this.error("Component with this ID already exists in viewer: "+t.id+" - will autogenerate this ID"),delete t.id),!(t.src||t.xtc||t.manifestSrc||t.manifest))return this.error("load() param expected: src, xtc, manifestSrc or manifestData"),c;var i={},r=t.includeTypes||this._includeTypes,n=t.excludeTypes||this._excludeTypes,s=t.objectDefaults||this._objectDefaults;if(i.reuseGeometries=null!==t.reuseGeometries&&void 0!==t.reuseGeometries?t.reuseGeometries:!1!==this._reuseGeometries,r){i.includeTypesMap={};for(var o=0,a=r.length;o<a;o++)i.includeTypesMap[r[o]]=!0}if(n){i.excludeTypesMap={};for(var l=0,u=n.length;l<u;l++)i.excludeTypesMap[n[l]]=!0}s&&(i.objectDefaults=s),i.excludeUnclassifiedObjects=void 0!==t.excludeUnclassifiedObjects?!!t.excludeUnclassifiedObjects:this._excludeUnclassifiedObjects,i.globalizeObjectIds=void 0!==t.globalizeObjectIds&&null!==t.globalizeObjectIds?!!t.globalizeObjectIds:this._globalizeObjectIds;var c=new $c(this.viewer.scene,ne.apply(t,{isModel:!0,textureTranscoder:this._textureTranscoder,maxGeometryBatchSize:this._maxGeometryBatchSize,origin:t.origin,disableVertexWelding:t.disableVertexWelding||!1,disableIndexRebucketing:t.disableIndexRebucketing||!1,dtxEnabled:t.dtxEnabled})),h=c.id,A=new vA({metaScene:this.viewer.metaScene,id:h});this.viewer.scene.canvas.spinner.processes++;var d,p,f=function(){c.destroyed||(c.finalize(),A.finalize(),e.viewer.scene.canvas.spinner.processes--,c.once("destroyed",function(){e.viewer.metaScene.destroyMetaModel(A.id)}),e.scheduleTask(function(){c.destroyed||(c.scene.fire("modelLoaded",c.id),c.fire("loaded",!0,!1))}))},g=function(t){e.viewer.scene.canvas.spinner.processes--,e.error(t),c.fire("error",t)},m=0,v={getNextId:function(){return"".concat(h,".").concat(m++)}};if(t.metaModelSrc||t.metaModelData)if(t.metaModelSrc){var _=t.metaModelSrc;this._dataSource.getMetaModel(_,function(s){c.destroyed||(A.loadData(s,{includeTypes:r,excludeTypes:n,globalizeObjectIds:i.globalizeObjectIds}),t.src?e._loadModel(t.src,t,i,c,null,v,f,g):(e._parseModel(t.xtc,t,i,c,null,v),f()))},function(e){g("load(): Failed to load model metadata for model '".concat(h," from '").concat(_,"' - ").concat(e))})}else t.metaModelData&&(A.loadData(t.metaModelData,{includeTypes:r,excludeTypes:n,globalizeObjectIds:i.globalizeObjectIds}),t.src?this._loadModel(t.src,t,i,c,null,v,f,g):(this._parseModel(t.xtc,t,i,c,null,v),f()));else if(t.src)this._loadModel(t.src,t,i,c,A,v,f,g);else if(t.xtc)this._parseModel(t.xtc,t,i,c,A,v),f();else if(t.manifestSrc||t.manifest){var y=t.manifestSrc?(d=t.manifestSrc,(p=d.split("/")).pop(),p.join("/")+"/"):"",b=function(t,s,o){var a=0,l=function(){c.destroyed||a>=t.length?s():e._dataSource.getMetaModel("".concat(y).concat(t[a]),function(t){A.loadData(t,{includeTypes:r,excludeTypes:n,globalizeObjectIds:i.globalizeObjectIds}),a++,e.scheduleTask(l,200)},o)};l()},w=function(r,n,s){var o=0,a=function(){c.destroyed||o>=r.length?n():e._dataSource.getXTC("".concat(y).concat(r[o]),function(r){e._parseModel(r,t,i,c,null,v),c.preFinalize(),o++,e.scheduleTask(a,200)},s)};a()},x=function(r,n,s){var o=0,a=function(){c.destroyed||o>=r.length?n():e._dataSource.getXTC("".concat(y).concat(r[o]),function(r){e._parseModel(r,t,i,c,A,v),c.preFinalize(),o++,e.scheduleTask(a,100)},s)};a()};if(t.manifest){var B=t.manifest,P=B.xtcFiles;if(!P||0===P.length)return void g("load(): Failed to load model manifest - manifest not valid");var C=B.metaModelFiles;C?b(C,function(){w(P,f,g)},g):x(P,f,g)}else this._dataSource.getManifest(t.manifestSrc,function(e){if(!c.destroyed){var t=e.xtcFiles;if(t&&0!==t.length){var i=e.metaModelFiles;i?b(i,function(){w(t,f,g)},g):x(t,f,g)}else g("load(): Failed to load model manifest - manifest not valid")}},g)}return c}},{key:"_loadModel",value:function(e,t,i,r,n,s,o,a){var l=this;this._dataSource.getXTC(t.src,function(e){l._parseModel(e,t,i,r,n,s),r.preFinalize(),o()},a)}},{key:"_parseModel",value:(t=a(s().mark(function e(t,i,r,n,o,a){var l,u,c,h,A,d,p,f,g;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!n.destroyed){e.next=2;break}return e.abrupt("return");case 2:if(l=new DataView(t),u=new Uint8Array(t),c=l.getUint32(0,!0),h=Fk[c]){e.next=9;break}return this.error("Unsupported .XTC file version: "+c+" - this XTCLoaderPlugin supports versions "+Object.keys(Fk)),e.abrupt("return");case 9:for(this.log("Loading .xtc V"+c),A=l.getUint32(4,!0),d=[],p=4*(A+2),f=0;f<A;f++)g=l.getUint32(4*(f+2),!0),d.push(u.subarray(p,p+g)),p+=g;h.parse(this.viewer,r,d,n,o,a);case 15:case"end":return e.stop()}},e,this)})),function(e,i,r,n,s,o){return t.apply(this,arguments)})},{key:"loadMetadata",value:function(e,t,i,r){var n=this;e._finalized=!1;try{this._workerInflate(e,t,i,function(t){t.terminate(),n.fire("metaLoaded",{result:"success",metaModel:e}),"function"==typeof r&&r()},function(t,i){t.terminate(),n.fire("metaLoaded",{result:"failed",message:i,metaModel:e})})}catch(t){this.fire("metaloaded",{result:t,metaModel:e})}}},{key:"_workerInflate",value:function(e,t,i,r,n){var s,o,a=this,l=(s=new Blob(['\n self.importScripts(\'https://cdnjs.cloudflare.com/ajax/libs/pako/1.0.11/pako.min.js\');\n \n function inflateMetadata(deflatedData) {\n\t\t\ttry {\n\t\t\t\treturn JSON.parse(self.pako.inflate(deflatedData, { to: "string" }));\n\t\t\t} catch (error) {\n\t\t\t\tconsole.error("Error inflating metadata:", error);\n\t\t\t\tthrow error;\n\t\t\t} \n\t\t}\n \n self.onmessage = function (e) {\n console.log("start worker:");\n const metaJson = inflateMetadata(e.data.buffer);\n\n self.postMessage({\n metaJson,\n time: new Date().getTime()\n });\n };\n '],{type:"application/javascript"}),o=URL.createObjectURL(s),new Worker(o));l.postMessage({buffer:t}),l.onmessage=function(t){i?e.loadData(t.data.metaJson,function(){e.finalize(),"function"==typeof r?r(l):l.terminate()},function(e){"function"==typeof n&&n(l,e)}):a.fire("metaLoading",function(){e.loadData(t.data.metaJson,function(){e.finalize(),"function"==typeof r?r(l):l.terminate()},function(e){"function"==typeof n&&n(l,e)})})},l.onerror=function(e){"function"==typeof n&&n(l,e.message),l.terminate()}}}]);var t}();var Rk=function(){return P(function e(){x(this,e)},[{key:"getIFC",value:function(e,t,i){var r=function(){};t=t||r,i=i||r;var n=e.match(/^data:(.*?)(;base64)?,(.*)$/);if(n){var s=!!n[2],o=n[3];o=window.decodeURIComponent(o),s&&(o=window.atob(o));try{for(var a=new ArrayBuffer(o.length),l=new Uint8Array(a),u=0;u<o.length;u++)l[u]=o.charCodeAt(u);t(a)}catch(e){i(e)}}else{var c=new XMLHttpRequest;c.open("GET",e,!0),c.responseType="arraybuffer",c.onreadystatechange=function(){4===c.readyState&&(200===c.status?t(c.response):i("getXTC error : "+c.response))},c.send(null)}}}])}(),Ok=function(){function e(t){var i,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return x(this,e),(i=d(this,e,["ifcLoader",t,r])).dataSource=r.dataSource,i.objectDefaults=r.objectDefaults,i.includeTypes=r.includeTypes,i.excludeTypes=r.excludeTypes,i.excludeUnclassifiedObjects=r.excludeUnclassifiedObjects,r.WebIFC&&(i._webIFC=r.WebIFC,i._ifcAPI=r.IfcAPI,i.webIfcFroMOutside=!0),i}return _(e,ge),P(e,[{key:"supportedVersions",get:function(){return["2x3","4"]}},{key:"dataSource",get:function(){return this._dataSource},set:function(e){this._dataSource=e||new Rk}},{key:"objectDefaults",get:function(){return this._objectDefaults},set:function(e){this._objectDefaults=e||YM}},{key:"includeTypes",get:function(){return this._includeTypes},set:function(e){this._includeTypes=e}},{key:"excludeTypes",get:function(){return this._excludeTypes},set:function(e){this._excludeTypes=e}},{key:"excludeUnclassifiedObjects",get:function(){return this._excludeUnclassifiedObjects},set:function(e){this._excludeUnclassifiedObjects=!!e}},{key:"globalizeObjectIds",get:function(){return this._globalizeObjectIds},set:function(e){this._globalizeObjectIds=!!e}},{key:"load",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};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);var t=new $c(this.viewer.scene,ne.apply(e,{isModel:!0}));if(!e.src&&!e.ifc)return this.error("load() param expected: src or IFC"),t;var i={autoNormals:!0};if(!1!==e.loadMetadata){var r=e.includeTypes||this._includeTypes,n=e.excludeTypes||this._excludeTypes,s=e.objectDefaults||this._objectDefaults;if(r){i.includeTypesMap={};for(var o=0,a=r.length;o<a;o++)i.includeTypesMap[r[o]]=!0}if(n){i.excludeTypesMap={};for(var l=0,u=n.length;l<u;l++)i.excludeTypesMap[n[l]]=!0}s&&(i.objectDefaults=s),i.excludeUnclassifiedObjects=void 0!==e.excludeUnclassifiedObjects?!!e.excludeUnclassifiedObjects:this._excludeUnclassifiedObjects,i.globalizeObjectIds=void 0!==e.globalizeObjectIds?!!e.globalizeObjectIds:this._globalizeObjectIds}if(this.webIfcFroMOutside)try{e.src?this._loadModel(e.src,e,i,t):this._parseModel(e.ifc,e,i,t)}catch(e){this.error(e),t.fire("error",e)}return t}},{key:"_loadModel",value:function(e,t,i,r){var n=this,s=this.viewer.scene.canvas.spinner;s.processes++,this._dataSource.getIFC(t.src,function(e){n._parseModel(e,t,i,r),s.processes--},function(e){s.processes--,n.error(e),r.fire("error",e)})}},{key:"_parseModel",value:function(e,t,i,r){if(!r.destroyed){var n=t.stats||{};if(n.sourceFormat="IFC",n.schemaVersion="",n.title="",n.author="",n.created="",n.numMetaObjects=0,n.numPropertySets=0,n.numObjects=0,n.numGeometries=0,n.numTriangles=0,n.numVertices=0,this.webIfcFroMOutside){if(!this._ifcAPI)throw"WebIFCLoaderPlugin has no WebIFC instance configured - please inject via WebIFCLoaderPlugin constructor"}else i.wasmPath&&this._ifcAPI.SetWasmPath(i.wasmPath);var s,o=new Uint8Array(e),a=this._ifcAPI.OpenModel(o),l=this._ifcAPI.GetModelSchema(a),u=this._ifcAPI.GetLineIDsWithType(a,this._webIFC.IFCPROJECT).get(0),c=!1!==t.loadMetadata,h=void 0!==t.metadata&&null!==t.metadata;s=h?t.metadata:null;var A={ifcProjectId:u,modelID:a,modelSchema:l,sceneModel:r,loadMetadata:c,metadata:c?{id:"",projectId:""+u,author:"",createdAt:"",schema:"",creatingApplication:"",metaObjects:[],propertySets:[]}:s,metaObjects:h?r.metaObjects:{},options:i,nextId:0,stats:n};if(c){if(i.includeTypes){A.includeTypes={};for(var d=0,p=i.includeTypes.length;d<p;d++)A.includeTypes[i.includeTypes[d]]=!0}if(i.excludeTypes){A.excludeTypes={};for(var f=0,g=i.excludeTypes.length;f<g;f++)A.excludeTypes[i.excludeTypes[f]]=!0}this._parseMetaObjects(A),this._parsePropertySets(A)}if(this._parseGeometry(A),r.finalize(),c||h){var m=r.id;this.viewer.metaScene.createMetaModel(m,A.metadata,i)}r.scene.once("tick",function(){r.destroyed||(r.scene.fire("modelLoaded",r.id),r.fire("loaded",!0,!1))})}}},{key:"_parseMetaObjects",value:function(e){var t=this._ifcAPI.GetLine(e.modelID,e.ifcProjectId);this._parseSpatialChildren(e,t)}},{key:"_parseSpatialChildren",value:function(e,t,i){var r=this._ifcAPI.GetNameFromTypeCode(t.type);if((!e.includeTypes||e.includeTypes[r])&&(!e.excludeTypes||!e.excludeTypes[r])){this._createMetaObject(e,t,i);var n=t.GlobalId.value;this._parseRelatedItemsOfType(e,t.expressID,"RelatingObject","RelatedObjects",this._webIFC.IFCRELAGGREGATES,n),this._parseRelatedItemsOfType(e,t.expressID,"RelatingStructure","RelatedElements",this._webIFC.IFCRELCONTAINEDINSPATIALSTRUCTURE,n)}}},{key:"_createMetaObject",value:function(e,t,i){var r,n=t.GlobalId.value;r=this.webIfcFroMOutside?this._ifcAPI.GetNameFromTypeCode(t.type):t.__proto__.constructor.name;var s={id:n,name:t.Name&&""!==t.Name.value?t.Name.value:r,type:r,parent:i};e.metadata.metaObjects.push(s),e.metaObjects[n]=s,e.stats.numMetaObjects++}},{key:"_parseRelatedItemsOfType",value:function(e,t,i,r,n,s){for(var o=this,a=this._ifcAPI.GetLineIDsWithType(e.modelID,n),l=0;l<a.size();l++){var u=a.get(l),c=this._ifcAPI.GetLine(e.modelID,u);if(null==c)return;var h=c[i],A=!1;if(Array.isArray(h))A=h.map(function(e){return e.value}).includes(t);else A=h.value===t;if(A){var d=c[r];if(Array.isArray(d))d.forEach(function(t){var i=o._ifcAPI.GetLine(e.modelID,t.value);null!=i&&o._parseSpatialChildren(e,i,s)});else{var p=this._ifcAPI.GetLine(e.modelID,d.value);if(null==p)return;this._parseSpatialChildren(e,p,s)}}}}},{key:"_parsePropertySets",value:function(e){this.log("start parse property...");for(var t=this._ifcAPI.GetLineIDsWithType(e.modelID,this._webIFC.IFCRELDEFINESBYPROPERTIES),i=0;i<t.size();i++){var r=t.get(i),n=this._ifcAPI.GetLine(e.modelID,r,!0);if(n){var s=n.RelatingPropertyDefinition;if(!s)continue;var o=s.GlobalId.value,a=s.HasProperties;if(a&&a.length>0){for(var l=s.Name.value,u=[],c=0,h=a.length;c<h;c++){var A=a[c],d=A.Name,p=A.NominalValue;if(d&&p){var f={name:d.value,type:p.type,value:p.value,valueType:p.valueType};A.Description?f.description=A.Description.value:p.description&&(f.description=p.description),u.push(f)}}var g={id:o,type:"Default",name:l,properties:u};e.metadata.propertySets.push(g),e.stats.numPropertySets++;var m=n.RelatedObjects;if(!m||0===m.length)return;for(var v=0,_=m.length;v<_;v++){var y=m[v].GlobalId.value,b=e.metaObjects[y];b&&(b.propertySetIds||(b.propertySetIds=[]),b.propertySetIds.push(o))}}}}}},{key:"_parseGeometry",value:function(e){var t=this;this.log("start parse geometry"),this._ifcAPI.StreamAllMeshes(e.modelID,function(i){var r=i.expressID,n=i.geometries,s=[],o=t._ifcAPI.GetLine(e.modelID,r);if(null!=o){var a=o.GlobalId.value;if(e.loadMetadata){var l=a,u=e.metaObjects[l];if(e.includeTypes&&(!u||!e.includeTypes[u.type]))return;if(e.excludeTypes&&(!u||e.excludeTypes[u.type]))return}for(var c=Y.mat4(),h=Y.vec3(),A=0,d=n.size();A<d;A++){for(var p=n.get(A),f=t._ifcAPI.GetGeometry(e.modelID,p.geometryExpressID),g=t._ifcAPI.GetVertexArray(f.GetVertexData(),f.GetVertexDataSize()),m=t._ifcAPI.GetIndexArray(f.GetIndexData(),f.GetIndexDataSize()),v=new Float64Array(g.length/2),_=new Float32Array(g.length/2),y=0,b=0,w=g.length/6;y<w;y++,b+=3)v[b+0]=g[6*y+0],v[b+1]=g[6*y+1],v[b+2]=g[6*y+2];c.set(p.flatTransformation),Y.transformPositions3(c,v);var x=we(v,v,h);if(!e.options.autoNormals)for(var B=0,P=0,C=g.length/6;B<C;B++,P+=3)_[P+0]=g[6*B+3],_[P+1]=g[6*B+4],_[P+2]=g[6*B+5];e.stats.numGeometries++,e.stats.numVertices+=v.length/3,e.stats.numTriangles+=m.length/3;var M="mesh"+e.nextId++;e.sceneModel.createMesh({id:M,primitive:"triangles",origin:x?h:null,positions:v,normals:e.options.autoNormals?null:_,indices:m,color:[p.color.x,p.color.y,p.color.z],opacity:p.color.w}),s.push(M)}var k=e.options.globalizeObjectIds?Y.globalizeObjectId(e.sceneModel.id,a):a;e.sceneModel.createEntity({id:k,meshIds:s,isObject:!0}),e.stats.numObjects++}}),this._ifcAPI.StreamAllMeshesWithTypes(e.modelID,[3856911033],function(i,r,n){var s=i.expressID,o=t._ifcAPI.GetLine(e.modelID,s);if(null!=o){for(var a=o.GlobalId.value,l=i.geometries,u=[],c=Y.mat4(),h=Y.vec3(),A=0,d=l.size();A<d;A++){for(var p=l.get(A),f=t._ifcAPI.GetGeometry(e.modelID,p.geometryExpressID),g=t._ifcAPI.GetVertexArray(f.GetVertexData(),f.GetVertexDataSize()),m=t._ifcAPI.GetIndexArray(f.GetIndexData(),f.GetIndexDataSize()),v=new Float64Array(g.length/2),_=new Float32Array(g.length/2),y=0,b=0,w=g.length/6;y<w;y++,b+=3)v[b+0]=g[6*y+0],v[b+1]=g[6*y+1],v[b+2]=g[6*y+2];c.set(p.flatTransformation),Y.transformPositions3(c,v);var x=we(v,v,h);if(!e.options.autoNormals)for(var B=0,P=0,C=g.length/6;B<C;B++,P+=3)_[P+0]=g[6*B+3],_[P+1]=g[6*B+4],_[P+2]=g[6*B+5];e.stats.numGeometries++,e.stats.numVertices+=v.length/3,e.stats.numTriangles+=m.length/3;var M="mesh"+e.nextId++;e.sceneModel.createMesh({id:M,primitive:"triangles",origin:x?h:null,positions:v,normals:e.options.autoNormals?null:_,indices:m,color:[p.color.x,p.color.y,p.color.z],opacity:p.color.w<1?p.color.w:.1}),u.push(M)}var k=e.options.globalizeObjectIds?Y.globalizeObjectId(e.sceneModel.id,a):a;e.sceneModel.createEntity({id:k,meshIds:u,isObject:!0}),e.stats.numObjects++}})}}])}();const Lk={ch:{NavCube:{front:"前",back:"后",top:"上",bottom:"下",left:"左",right:"右"},modelsExplorer:{title:"模型",loadAll:"加载全部",loadAllTip:"加载项目中的所有模型",unloadAll:"卸载全部",unloadAllTip:"卸载所有模型",add:"添加",addTip:"添加模型"},objectsExplorer:{title:"对象",showAll:"显示全部",showAllTip:"显示所有对象",hideAll:"隐藏全部",hideAllTip:"隐藏所有对象"},classesExplorer:{title:"类别",showAll:"显示全部",showAllTip:"显示所有类别",hideAll:"隐藏全部",hideAllTip:"隐藏所有类别"},storeysExplorer:{title:"楼层",showAll:"显示全部",showAllTip:"显示所有楼层",hideAll:"隐藏全部",hideAllTip:"隐藏所有楼层"},propertiesInspector:{title:"属性",noObjectSelectedWarning:"未选中任何对象。右键单击或长按对象,并选择“检查属性”以在此查看其属性。",noPropSetWarning:"未找到此对象的属性集。"},toolbar:{toggleExplorer:"结构树",toggleProperties:"属性",resetViewTip:"重置视图",toggle2d3dTip:"2D/3D",togglePerspectiveTip:"透视/正交",viewFitTip:"适合视图",firstPersonTip:"第一人称",hideObjectsTip:"隐藏对象",annotationObjectsTip:"标注对象",selectObjectsTip:"选择对象",queryObjectsTip:"查询对象",sliceObjectsTip:"切片对象",slicesMenuTip:"切片菜单",showSpacesTip:"显示空间",numSlicesTip:"现有切片数"}},en:{NavCube:{front:"Front",back:"Back",top:"Top",bottom:"Bottom",left:"Left",right:"Right"},modelsExplorer:{title:"Models",loadAll:"Load all",loadAllTip:"Load all models in this project",unloadAll:"Unload all",unloadAllTip:"Unload all models",add:"Add",addTip:"Add a Model"},objectsExplorer:{title:"Objects",showAll:"Show all",showAllTip:"Show all objects",hideAll:"Hide all",hideAllTip:"Hide all objects"},classesExplorer:{title:"Classes",showAll:"Show all",showAllTip:"Show all classes",hideAll:"Hide all",hideAllTip:"Hide all classes"},storeysExplorer:{title:"Storeys",showAll:"Show all",showAllTip:"Show all storeys",hideAll:"Hide all",hideAllTip:"Hide all storeys"},propertiesInspector:{title:"Properties",noObjectSelectedWarning:"No object inspected. Right-click or long-tab an object and select 'Inspect Properties' to view its properties here.",noPropSetWarning:"No property sets found for this object."},toolbar:{toggleExplorer:"Toggle explorer",toggleProperties:"Toggle properties",resetViewTip:"Reset view",toggle2d3dTip:"Toggle 2D/3D",togglePerspectiveTip:"Toggle Perspective/Ortho",viewFitTip:"View fit",firstPersonTip:"Toggle first person navigation mode",hideObjectsTip:"Hide objects",selectObjectsTip:"Select objects",queryObjectsTip:"Query objects",sliceObjectsTip:"Slice objects",slicesMenuTip:"Slices menu",showSpacesTip:"Show IFCSpaces",numSlicesTip:"Number of existing slices"}},de:{NavCube:{front:"Vorne",back:"Hinten",top:"Oben",bottom:"Unten",left:"Links",right:"Rechts"},modelsExplorer:{title:"Modelle",loadAll:"Alle laden",loadAllTip:"Alle Modelle in diesem Projekt laden",unloadAll:"Alle abwählen",unloadAllTip:"Alle Modelle abwählen",add:"Hinzufügen",addTip:"Modell hinzufügen"},objectsExplorer:{title:"Objekte",showAll:"Alle anzeigen",showAllTip:"Alle Objekte anzeigen",hideAll:"Alle ausblenden",hideAllTip:"Alle Objekte ausblenden"},classesExplorer:{title:"Typen",showAll:"Alle anzeigen",showAllTip:"Alle Typen anzeigen",hideAll:"Alle ausblenden",hideAllTip:"Alle Typen ausblenden"},storeysExplorer:{title:"Stockwerke",showAll:"Alle anzeigen",showAllTip:"Alle Stockwerke anzeigen",hideAll:"Alle ausblenden",hideAllTip:"Alle Stockwerke ausblenden"},propertiesInspector:{title:"Eigenschaften",noObjectSelectedWarning:"Kein Objekt inspiziert. Klicken Sie mit der rechten Maustaste auf ein Objekt oder führen Sie einen langen Tabulator aus und wählen Sie 'Eigenschaften prüfen', um die Eigenschaften des Objekts anzuzeigen.",noPropSetWarning:"Keine Eigenschaftssätze für dieses Objekt gefunden."},toolbar:{toggleExplorer:"Explorer ein- und ausblenden",toggleProperties:"Eigenschaften ein- und ausblenden",resetViewTip:"Ansicht zurücksetzen",toggle2d3dTip:"2D/3D umschalten",togglePerspectiveTip:"Orthogonale/Perspektivische Ansicht umschalten",viewFitTip:"In Ansicht einpassen",firstPersonTip:"Ich-Perspektive umschalten",hideObjectsTip:"Objekte ausblenden",selectObjectsTip:"Objekte auswählen",queryObjectsTip:"Abfrageobjekte",sliceObjectsTip:"Objekte schneiden",slicesMenuTip:"Menü Schnittebenen",showSpacesTip:"IFC-Räume anzeigen",numSlicesTip:"Anzahl der Schnittebenen"}},fr:{NavCube:{front:"Face",back:"Arrière",top:"Dessus",bottom:"Dessous",left:"Droite",right:"Gauche"},modelsExplorer:{title:"Modèles",loadAll:"Afficher tout",loadAllTip:"Afficher tous les modèles du projet",unloadAll:"Masquer tout",unloadAllTip:"Masquer tous les modèles",add:"Ajouter",addTip:"Ajouter un modèle"},objectsExplorer:{title:"Conteneurs",showAll:"Afficher tout",showAllTip:"Afficher tous les objets",hideAll:"Masquer tout",hideAllTip:"Masquer tous les objets"},classesExplorer:{title:"Classes IFC",showAll:"Afficher tout",showAllTip:"Affiche toutes les classes",hideAll:"Masquer tout",hideAllTip:"Masquer toutes les classes"},storeysExplorer:{title:"Étages",showAll:"Afficher tout",showAllTip:"Afficher tous les étages",hideAll:"Masquer tout",hideAllTip:"Masquer tous les étages"},propertiesInspector:{title:"Propriétés",noObjectSelectedWarning:"Aucun objet n'a été inspecté. Cliquez avec le bouton droit ou le bouton long sur un objet et sélectionnez 'Inspecter les propriétés' pour afficher ses propriétés ici.",noPropSetWarning:"Aucun ensemble de propriétés n'a été trouvé pour cet objet."},toolbar:{toggleExplorer:"Afficher la structure",toggleProperties:"Afficher les propriétés",resetViewTip:"Réinitialiser la vue",toggle2d3dTip:"Activer 2D/3D",togglePerspectiveTip:"Activer Perspective/Ortho",viewFitTip:"Recadrer la vue",firstPersonTip:"Mode 1ere personne",hideObjectsTip:"Masquer objets",selectObjectsTip:"Sélectionner",queryObjectsTip:"Informations objets",sliceObjectsTip:"Coupes",slicesMenuTip:"Outils de coupe",showSpacesTip:"Afficher les espaces IFC",numSlicesTip:"Nombre de coupes"}},pl:{NavCube:{front:"Przód",back:"Tył",top:"Góra",bottom:"Dół",left:"Lewy",right:"Prawy"},modelsExplorer:{title:"Model",loadAll:"Załaduj",loadAllTip:"Załaduj wszystkie modele",unloadAll:"Zamknij",unloadAllTip:"Zamnij wszystkie modele",add:"Dodaj",addTip:"Dodaj modele"},objectsExplorer:{title:"Obiekty",showAll:"Pokaż",showAllTip:"Pokaż wszystkie obiekty",hideAll:"Ukryj",hideAllTip:"Ukryj wszystkie obiekty"},classesExplorer:{title:"Typy",showAll:"Pokaż",showAllTip:"Pokaż wszystkie typy",hideAll:"Ukryj",hideAllTip:"Ukryj wszystkie typy"},storeysExplorer:{title:"Piętra",showAll:"Pokaż",showAllTip:"Pokaż wszystkie piętra",hideAll:"Ukryj",hideAllTip:"Ukryj wszystkie piętra"},propertiesInspector:{title:"Właściwości",noObjectSelectedWarning:"Nie sprawdzono żadnego obiektu. Kliknij prawym przyciskiem myszy lub kliknij długo na obiekcie i wybierz opcję 'Sprawdź właściwości', aby wyświetlić jego właściwości.",noPropSetWarning:"Nie znaleziono żadnych zestawów właściwości dla tego obiektu."},toolbar:{toggleExplorer:"Przełączanie eksploratora",toggleProperties:"Przełączanie właściwości",resetViewTip:"Resetuj widok",toggle2d3dTip:"Widok 2D/3D",togglePerspectiveTip:"Widok Ortograficzny/Perspektywiczny",viewFitTip:"Dopasowanie do widoku",firstPersonTip:"Widok perspektywy pierwszoosobowej",hideObjectsTip:"Ukryj obiekt",selectObjectsTip:"Zaznacz obiekt",queryObjectsTip:"Wywołaj obiekt",sliceObjectsTip:"Przekroje obiektów",slicesMenuTip:"Menu przekroi",showSpacesTip:"Pokaż przestrzenie IFC",numSlicesTip:"Liczba przekroi"}},ru:{NavCube:{front:"Фронт",back:"Тыл",top:"Верх",bottom:"Низ",left:"Лево",right:"Право"},modelsExplorer:{title:"Модели",loadAll:"Загрузить все",loadAllTip:"Загрузить все модели в этом проекте",unloadAll:"Выгрузить все",unloadAllTip:"Выгрузить все модели",add:"Добавить",addTip:"Добавить модель"},objectsExplorer:{title:"Объекты",showAll:"Показать все",showAllTip:"Показать все объекты",hideAll:"Скрыть все",hideAllTip:"Скрыть все объекты"},classesExplorer:{title:"Классы",showAll:"Показать все",showAllTip:"Показать все классы",hideAll:"Скрыть все",hideAllTip:"Скрыть все классы"},storeysExplorer:{title:"Этажи",showAll:"Показать все",showAllTip:"Показать все этажи",hideAll:"Скрыть все",hideAllTip:"Скрыть все этажи"},propertiesInspector:{title:"Свойства",noObjectSelectedWarning:"Ни один объект не осмотрен. Щелкните правой кнопкой мыши или длинной меткой на объекте и выберите 'Осмотреть свойства', чтобы просмотреть его свойства здесь.",noPropSetWarning:"Для этого объекта не найдено ни одного набора свойств."},toolbar:{toggleExplorer:"Переключить навигатор",toggleProperties:"Переключить Свойства",resetViewTip:"Сбросить вид",toggle2d3dTip:"Переключить 2D/3D",togglePerspectiveTip:"Переключить проекцию перспектива/орто",viewFitTip:"Показать всю модель",firstPersonTip:"Переключить режим навигации от первого лица",hideObjectsTip:"Скрыть объекты",selectObjectsTip:"Выбрать объекты",queryObjectsTip:"Выбрать объекты",sliceObjectsTip:"Рассечь объекты",slicesMenuTip:"Меню сечений",showSpacesTip:"Показать места IFC",numSlicesTip:"Количество существующих сечений"}}};class jk{constructor(){this.events={}}on(e,t){this.events[e]||(this.events[e]=[]),this.events[e].push(t)}off(e,t){this.events[e]&&(this.events[e]=this.events[e].filter(e=>e!==t))}emit(e,...t){this.events[e]&&this.events[e].forEach(e=>{e(...t)})}destroy(){this.events={}}}class Uk{constructor(e=[],t=0){this.items=[],this._lastUniqueId=0,this.items=e||[],this._lastUniqueId=(t||0)+1}addItem(...e){let t;if(2===e.length){const i=e[0];if(t=e[1],this.items[i])throw new Error(`ID clash: '${i}'`);return this.items[i]=t,i}for(t=e[0]||{};;){this._lastUniqueId+=1;const e=this._lastUniqueId;if(!this.items[e])return this.items[e]=t,e}}removeItem(e){const t=this.items[e];return delete this.items[e],t}}class Nk{constructor(e,t={},i=null,r=null){this._children=[],this._subIdMap=null,this._subIdEvents=null,this._eventSubs=null,this._events=null,this._eventCallDepth=0,this._enabled=null,this._active=null,this.destroyed=!1,this.bimViewer=e?e.bimViewer||e:this,this.server=e?e.server:i,this.viewer=e?e.viewer:r,e&&e._children.push(this)}fire(e,t,i=!1){this._events||(this._events={}),this._eventSubs||(this._eventSubs={}),!0!==i&&(this._events[e]=t||!0);const r=this._eventSubs[e];let n;r&&Object.keys(r).forEach(i=>{Object.prototype.hasOwnProperty.call(r,i)&&(n=r[i],this._eventCallDepth+=1,this._eventCallDepth<300?n.callback.call(n.scope,t):this.error(`fire: potential stack overflow from recursive event ${e} - dropping this event`),this._eventCallDepth-=1)})}on(e,t,i=this){this._events||(this._events={}),this._subIdMap||(this._subIdMap=new Uk),this._subIdEvents||(this._subIdEvents={}),this._eventSubs||(this._eventSubs={});let r=this._eventSubs[e];r||(r={},this._eventSubs[e]=r);const n=this._subIdMap.addItem();r[n]={callback:t,scope:i||this},this._subIdEvents[n]=e;const s=this._events[e];return void 0!==s&&t.call(i||this,s),n}off(e){if(null==e)return;if(!this._subIdEvents)return;const t=this._subIdEvents[e];if(t){delete this._subIdEvents[e];const i=this._eventSubs[t];i&&delete i[e],this._subIdMap.removeItem(e)}}once(e,t,i=this){const r=this,n=this.on(e,e=>{r.off(n),t.call(i||this,e)},i)}log(e){e=`[LOG] ${e}`,console.log(e)}warn(e){e=`[LOG] ${e}`,window.console.warn(e)}error(e){e=`[LOG] ${e}`,window.console.error(e)}_mutexActivation(e){e.forEach((t,i)=>{t.on("active",t=>{t&&e.forEach((e,t)=>{t!==i&&e.setActive(!1)})})})}setEnabled(e){this._enabled!==e&&(this._enabled=e,this.fire("enabled",this._enabled))}getEnabled(){return this._enabled}setActive(e){this._active!==e&&(this._active=e,this.fire("active",this._active))}getActive(){return this._active}destroy(){this.destroyed||(this.fire("destroyed",this.destroyed=!0),this._subIdMap=null,this._subIdEvents=null,this._eventSubs=null,this._events=null,this._eventCallDepth=0,this._children.forEach(e=>{e.destroy()}),this._children=[])}}const Vk=Y.vec3();class Qk extends Nk{constructor(e,t={}){super(e,t),this._modelMementos={},this.bimViewer.modelsExplorer.on("modelLoaded",e=>{this.reset()})}reset(e){this._resetCamera(e)}_resetCamera(e){const{viewer:t}=this,{scene:i}=t;let r;r=this.bimViewer.multiModel?i.getAABB(i.visibleObjectIds):i.aabb;const n=Y.getAABB3Diag(r),s=Y.getAABB3Center(r,Vk),{camera:o}=i;o.perspective.fov;const a=Math.abs(n/Math.tan(45*Y.DEGTORAD)),l=Y.normalizeVec3(o.yUp?[-.5,-.7071,-.5]:[-1,1,-1]),u=Y.normalizeVec3(o.yUp?[-.5,.7071,-.5]:[-1,1,1]);t.cameraControl.pivotPos=s,t.cameraControl.planView&&(t.cameraControl.planView=!1),t.cameraFlight.flyTo({look:s,eye:[s[0]-a*l[0],s[1]-a*l[1],s[2]-a*l[2]],up:u,orthoScale:1.3*n,projection:"perspective",duration:1},e)}}Y.vec3();class Hk extends Nk{constructor(e,t={}){super(e,t)}fit(e){const{viewer:t}=this,{scene:i}=t,{center:r}=i;let n;n=this.bimViewer.multiModel?i.getAABB(i.visibleObjectIds):i.aabb;const s=Y.getAABB3Diag(n);t.cameraControl.pivotPos=r,t.cameraControl.planView&&(t.cameraControl.planView=!1),t.cameraFlight.flyTo({aabb:n,orthoScale:1.3*s,duration:1},e)}set fov(e){this.viewer.scene.cameraFlight.fitFOV=e}get fov(){return this.viewer.scene.cameraFlight.fitFOV}set duration(e){this.viewer.scene.cameraFlight.duration=e}get duration(){return this.viewer.scene.cameraFlight.duration}}class Gk extends Nk{constructor(e,t){super(e,t);const{cameraControl:i}=this.viewer,{cameraControlNavModeMediator:r}=t;i.navMode="orbit",i.followPointer=!0,this.cameraControl=i,i.on("personModeSpeedUp",t=>{e.eventTrigger.emit("personModeSpeedUp",t)}),i.on("personModeSpeedDown",t=>{e.eventTrigger.emit("personModeSpeedDown",t)}),this.on("active",e=>{r.setFirstPersonModeActive(e),e&&(i.followPointer=!0)}),this.bimViewer.on("closeAll",()=>{this.setActive(!1)})}setdirectionChangeCancel(){this.goLeft=!1,this.goRight=!1,this.goUp=!1,this.goDown=!1,this.goForward=!1,this.goBackward=!1}speedUp(){this.cameraControl.speedUp()}speedDown(){this.cameraControl.speedDown()}set moveRate(e){this.cameraControl.moveRate=e}get moveRate(){return this.cameraControl.moveRate}set goRight(e){this.cameraControl.goRight=e}set goLeft(e){this.cameraControl.goLeft=e}set goUp(e){this.cameraControl.goUp=e}set goDown(e){this.cameraControl.goDown=e}set goForward(e){this.cameraControl.goForward=e}set goBackward(e){this.cameraControl.goBackward=e}smallCanvas(){const e=new W_({spinnerElementId:"manyou_spinner",canvasId:"canvas_manyou",transparent:!0,resolutionScale:window.devicePixelRatio});e.camera.eye=[-3.933,2.855,27.018],e.camera.look=[4.4,3.724,8.899],e.camera.up=[-.018,.999,.039]}}class zk extends Nk{constructor(e,t){super(e,t),this.on("active",e=>{e?(this.viewer.cameraControl.doublePickFlyTo=!1,this._onPick=this.viewer.cameraControl.on("picked",e=>{e.entity&&(e.entity.visible=!1)})):(this.viewer.cameraControl.doublePickFlyTo=!1,void 0!==this._onPick&&(this.viewer.cameraControl.off(this._onPick),this._onPick=void 0))}),this.bimViewer.on("closeAll",()=>{this.setActive(!1)})}}class Wk extends Nk{constructor(e,t){super(e,t),this._active=!0,e.eventTrigger.on("metaLoaded",t=>{const i=this.spaceObjects;if(0==i.length)return;this.viewer.scene.setObjectsCulled(i,!0),this.setIFCSpaceOpacity(),this.viewer.scene.setObjectsHighlighted(i,!0);const r=this.viewer.scene.models[t.metaModel.id],n=r.exceptionIds.concat(i);r.exceptionIds=n,e.resetView()})}setActive(e,t){this._active!==e&&(this._active=e,e?(this._enterShowSpacesMode(),this.fire("active",this._active)):(this._exitShowSpacesMode(),this.fire("active",this._active)),t&&t())}setIFCSpaceOpacity(){0!=this.spaceObjects.length&&this.viewer.scene.withObjects(this.spaceObjects,e=>{-1!=e.origin_opacity&&(e.opacity=e.opacity<.5?e.opacity:.1)})}_enterShowSpacesMode(){const{viewer:e}=this,{scene:t}=e,{metaScene:i}=e,r=i.getObjectIDsByType("IfcSpace");t.setObjectsCulled(r,!1)}_exitShowSpacesMode(){const{viewer:e}=this,{scene:t}=e,{metaScene:i}=e,r=i.getObjectIDsByType("IfcSpace");t.setObjectsCulled(r,!0)}get spaceObjects(){return this.viewer.metaScene.getObjectIDsByType("IfcSpace")}}class Kk extends Nk{constructor(e,t){super(e,t),this.eventTrigger=e.eventTrigger,this._sectionPlanesPlugin=new yk(this.viewer,{}),this._sectionPlanesPlugin.sectionConfigs={planeSize:1.4,controlSize:.2,planeOpacity:.2,controlFillColor:[.1,.4,.99]},this._sectionPlanesPlugin.setOverviewVisible(!1),this._sectionPlanesPlugin.on("touchPlaneStart",()=>{this.eventTrigger.emit("touchPlaneStart")}),this._sectionPlanesPlugin.on("touchPlaneEnd",()=>{this.eventTrigger.emit("touchPlaneEnd")}),this._sectionPlanesPlugin.on("clickPlaneStart",()=>{this.eventTrigger.emit("clickPlaneStart")}),this._sectionPlanesPlugin.on("clickPlaneEnd",()=>{this.eventTrigger.emit("clickPlaneEnd")}),this._isTouch=!1,this.on("active",e=>{e?this.showControl():this.hideControl()}),this.bimViewer.on("closeAll",()=>{this.setActive(!1)}),this._initSectionMode()}_initSectionMode(){this.viewer.scene.input.on("mouseclicked",e=>{if(!this.getActive())return;const t=this.viewer.scene.pick({canvasPos:e,pickSurface:!0});if(t){const e=this._sectionPlanesPlugin.createSectionPlane({pos:t.worldPos,dir:Y.mulVec3Scalar(t.worldNormal,-1)});this._sectionPlanesPlugin.showControl(e.id),this.eventTrigger.emit("createSection",{position:t.worldPos,direction:Y.mulVec3Scalar(t.worldNormal,-1),id:e.id})}})}set isTouch(e){this._sectionPlanesPlugin.isTouch=e,this._isTouch=e}set sectionWay(e){this._sectionPlanesPlugin.sectionWay=e}set sectionDirection(e){this._sectionPlanesPlugin.sectionDirection=e}setControlPos(e){this._sectionPlanesPlugin.setControlPos(e)}getControlPos(){return this._sectionPlanesPlugin.getControlPos()}set sectionConfigs(e){this._sectionPlanesPlugin.sectionConfigs=e}creatSection(e,t){const i=this._sectionPlanesPlugin.createSectionPlane({pos:e,dir:t});this._sectionPlanesPlugin.showControl(i.id)}getSectionPlanes(){return this._sectionPlanesPlugin.sectionPlanes}getSectionPlane(e){return this.getSectionPlanes()[e]}setSectionEnable(e){this.getSectionPlane(e).active=!0}setSectionDisable(e){this.getSectionPlane(e).active=!1}setSectionPos(e,t){this.getSectionPlane(e).pos=t}flipSection(e){this.getSectionPlane(e).flipDir()}getNumSections(){return Object.keys(this.viewer.scene.sectionPlanes).length}clear(){this._sectionPlanesPlugin.clear()}flipSections(){this._sectionPlanesPlugin.flipSectionPlanes()}getShownControl(){this._sectionPlanesPlugin.getShownControl()}enableSections(){const{sectionPlanes:e}=this.viewer.scene;for(const t in e){e[t].active=!0}}disableSections(){const{sectionPlanes:e}=this.viewer.scene;for(const t in e){e[t].active=!1,this.hideControl()}}hideControl(){this._sectionPlanesPlugin.hideControl()}showControl(){const e=this.getSectionPlanes();for(const t in e)e[t].control.setVisible(!0)}showSectionPlane(e){this._sectionPlanesPlugin.showControl(e)}destroy(){this._sectionPlanesPlugin.destroy(),super.destroy()}destroySectionPlane(e){this._sectionPlanesPlugin.destroySectionPlane(e)}}class Xk extends Nk{constructor(e,t){if(super(e,t),!t.navCubeCanvasElement)throw new Error("Missing config: NavCubeMode navCubeCanvasElement");const{navCubeCanvasElement:i}=t,{viewerElement:r}=t;this._navCubeCanvasElement=i,this._navCubeCanvasElement.oncontextmenu=e=>{e.preventDefault()},this._navCube=new tk(this.viewer,{canvasElement:i,viewerElement:r,fitVisible:!1,color:"#CFCFCF",shadowVisible:!1}),this._navCube.setVisible(this._active),this._visible=!0,this.on("active",e=>{this._navCube.setVisible(e)})}set visible(e){this._visible=e,this._navCubeCanvasElement.style.visibility=e?"visible":"hidden"}get visible(){return this._visible}get fitVisible(){return this._navCube.getFitVisible()}set fitVisible(e){this._navCube.setFitVisible(e)}flyByClick(e){this._navCube.flyByClick(e)}destroy(){this._navCube.destroy(),super.destroy()}}let qk;class Yk{constructor(e,t){this._projectId="",this._modelId="",this._server=e,qk=t.tempVec3a}setProjectId(e){this._projectId=e}setModelId(e){this._modelId=e}getManifest(e,t,i){this._server.getSplitModelManifest(this._projectId,this._modelId,e,t,i)}getMetaModel(e,t,i){this._server.getSplitModelMetadata(this._projectId,this._modelId,e,t,i)}getXTC(e,t,i){this._server.getSplitModelGeometry(this._projectId,this._modelId,e,t,i)}}class Jk extends Nk{constructor(e,t){super(e,t),this._modelFromOutSide=t.modelFromOutSide,this._projectId=t.projectId,this._modelType=t.modelType,this._modelSrc=t.modelSrc,this._eventTrigger=e.eventTrigger,this._dataSource=new Yk(this.server,{tempVec3a:t.tempVec3a}),this._modelConfig=t.modelConfig,this._modelsInfo={},this._numModels=0,this._numModelsLoaded=0}getModelIds(){return Object.keys(this._modelsInfo)}getModelInfo(e){return this._modelsInfo[e]}loadModel(e,t,i=()=>{},r=()=>{},n){if(this._modelType=n.modelType,"ifc"==this._modelType){const i=void 0!==n.IfcAPI&&null!==n.IfcAPI,r=void 0!==n.WebIFC&&null!==n.WebIFC;i&&r&&this.log("载入外部传入webifc..."),this._ifcLoader=new Ok(this.viewer,i&&r?{WebIFC:n.WebIFC,IfcAPI:n.IfcAPI}:{}),this._modelsInfo[e]={id:e,ifc:t,metaBuffer:null,edges:!0,loadMetadata:!1,saoEnabled:!0,pbrEnabled:!0,dtxEnabled:!0}}else"xtc"==this._modelType?(this._xtcLoader=new Dk(this.viewer,{dataSource:this._dataSource}),this._xtcLoader.on("metaLoaded",e=>{this._eventTrigger.emit("metaLoaded",e)}),this._xtcLoader.on("metaLoading",e=>{this._eventTrigger.emit("metaLoading",e)}),this._modelsInfo[e]={id:e,xtc:t,metaBuffer:null,edges:!0,loadMetadata:!1,saoEnabled:!0,pbrEnabled:!0,dtxEnabled:!0}):"glb"==this._modelType&&(this._glbLoader=new JM(this.viewer),this._modelsInfo[e]={id:e,gltf:t,metaBuffer:null,edges:!0,loadMetadata:!1,saoEnabled:!0,pbrEnabled:!0,dtxEnabled:!0});this._loadGeometry(e,i,r)}unloadModel(e){const t=this.viewer.scene.models[e];t?(t.destroy(),this.fire("modelUnloaded",e)):this.error("Model not loaded: "+e)}loadMetadata(e,t,i,r){this._xtcLoader&&(this._modelsInfo[e]&&(this._modelsInfo[e].metaBuffer=t),this._xtcLoader.loadMetadata(this.viewer.metaScene.metaModels[e],t,i,r))}_loadGeometry(e,t,i){const r=this._modelsInfo[e],n=()=>{this._jumpToInitialCamera(),this.fire("modelLoaded",e),t&&t()},s=e=>{this.error(e),i&&i(e)};if("ifc"==this._modelType&&this._ifcLoader)if(this._modelFromOutSide){this.log("正在载入ifc模型...");const e=this._ifcLoader.load(r);e.on("loaded",n),e.on("error",s)}else{this.log("正在载入引擎从本地获取的ifc模型...");const t=this._ifcLoader.load({id:e,src:this._modelSrc,edges:r.edges,loadMetadata:!1,pbrEnabled:r.pbrEnabled,dtxEnabled:r.dtxEnabled});t.on("loaded",n),t.on("error",s)}else if("xtc"===this._modelType&&this._xtcLoader){if(this._modelFromOutSide){this.log("正在载入xtc模型...");const e=this._xtcLoader.load(r);e.on("loaded",n),e.on("error",s)}}else if("glb"===this._modelType&&this._glbLoader&&this._modelFromOutSide){this.log("正在载入glb模型...");const e=this._glbLoader.load(r);e.on("loaded",n),e.on("error",s)}}_jumpToInitialCamera(){const{viewer:e}=this,{scene:t}=e,i=t.getAABB(t.visibleObjectIds),r=Y.getAABB3Diag(i),n=Y.getAABB3Center(i,qk),{camera:s}=t,o=Math.abs(r/Math.tan(45*Y.DEGTORAD)),a=Y.normalizeVec3(s.yUp?[-.5,-.7071,-.5]:[-1,1,-1]),l=Y.normalizeVec3(s.yUp?[-.5,.7071,-.5]:[-1,1,1]);e.cameraControl.pivotPos=n,e.cameraControl.planView&&(e.cameraControl.planView=!1),e.cameraFlight.jumpTo({look:n,eye:[n[0]-o*a[0],n[1]-o*a[1],n[2]-o*a[2]],up:l,orthoScale:1.1*r})}destroy(){super.destroy(),this._xtcLoader&&this._xtcLoader.destroy(),this._ifcLoader&&this._ifcLoader.destroy(),this._glbLoader&&this._glbLoader.destroy()}}class Zk extends Nk{constructor(e,t={}){super(e);const{modelType:i}=t;this.eventTrigger=e.eventTrigger,this._treeView=new xk(this.viewer,{hierarchy:"containment",autoAddModels:!1,pruneEmptyNodes:!0,autoExpandDepth:1}),this._treeView.on("rootNodes_Created",e=>{this._rootNode=e,this.eventTrigger.emit("object_rootNodes",e)}),this._treeView.on("nodeNodes_Created",e=>{this._nodeList=e,this.eventTrigger.emit("object_nodeNodes",e)}),this._treeView.on("objectNodes_Created",e=>{this._objectList=e,this.eventTrigger.emit("object_objectNodes",e)}),this._treeView.on("checkBoxChanged",e=>{this.eventTrigger.emit("object_checkBoxChanged",e)}),"ifc"===i?this._onModelLoaded=this.viewer.scene.on("modelLoaded",e=>{this._treeView.addModel(e,{rootName:e})}):this._onMetaDataLoaded=this.eventTrigger.on("metaLoaded",e=>{"success"===e.result&&(this._treeView.addModel(e.metaModel.id,{rootName:e.metaModel.id}),this.eventTrigger.emit("treeReady"))}),this._onModelUnloaded=this.viewer.scene.on("modelUnloaded",e=>{this.viewer.metaScene.metaModels[e]&&this._treeView.removeModel(e)})}get rootNode(){return this._rootNode}get nodesList(){return this._nodeList}get objectList(){return this._objectList}get treeView(){return this._treeView}getNodeIdByObjectId(e){if(null==this._objectList[e])return null;this._objectList[e].nodeId}getNodeById(e){return this._treeView.getNodeById(e)}getChildrenById(e){this._treeView.getChildrenById(e)}setEnabled(e){}destroy(){super.destroy(),this._treeView.destroy(),this.viewer.scene.off(this._onModelLoaded),this.viewer.scene.off(this._onModelUnloaded),this.viewer.scene.off(this._onMetaDataLoaded)}}class $k extends Nk{constructor(e,t={}){super(e),this.eventTrigger=e.eventTrigger;const{modelType:i}=t;this._treeView=new xk(this.viewer,{hierarchy:"types",autoAddModels:!1,pruneEmptyNodes:!0,autoExpandDepth:1}),this._treeView.on("rootNodes_Created",e=>{this._rootNode=e,this.eventTrigger.emit("classes_rootNodes",e)}),this._treeView.on("nodeNodes_Created",e=>{this._nodeList=e,this.eventTrigger.emit("classes_nodeNodes",e)}),this._treeView.on("objectNodes_Created",e=>{this._objectList=e,this.eventTrigger.emit("classes_objectNodes",e)}),this._treeView.on("checkBoxChanged",e=>{this.eventTrigger.emit("classes_checkBoxChanged",e)}),"ifc"===i?this._onModelLoaded=this.viewer.scene.on("modelLoaded",e=>{this._treeView.addModel(e,{rootName:e})}):this._onMetaDataLoaded=this.eventTrigger.on("metaLoaded",e=>{"success"===e.result&&(this._treeView.addModel(e.metaModel.id,{rootName:e.metaModel.id}),this.eventTrigger.emit("treeReady"))}),this._onModelUnloaded=this.viewer.scene.on("modelUnloaded",e=>{this.viewer.metaScene.metaModels[e]&&this._treeView.removeModel(e)})}get rootNode(){return this._rootNode}get nodesList(){return this._nodeList}get objectList(){return this._objectList}getNodeIdByObjectId(e){return null!=this._objectList[e]?this._objectList[e].nodeId:null}getNodeById(e){return this._treeView.getNodeById(e)}getChildrenById(e){this._treeView.getChildrenById(e)}checkboxChangeHandler(e,t){const i=this._nodeList[e],r=t,{objects:n}=this.viewer.scene;let s=0;this._treeView.withNodeTree(i,e=>{const{objectId:t}=e,i=n[t],o=0===e.children.length;e.numVisibleEntities=r?e.numEntities:0,o&&r!==e.checked&&s++,e.checked=r,i&&(i.visible=r)});let{parent:o}=i;for(;o;)o.checked=r,r?o.numVisibleEntities+=s:o.numVisibleEntities-=s,o=o.parent}nodeTitleClicked(e){const{scene:t}=this.viewer,i=this._nodeList[e],r=[];this._treeView.withNodeTree(i,e=>{e.objectId&&r.push(e.objectId)});const{checked:n}=i;n?(t.setObjectsXRayed(r,!1),t.setObjectsVisible(r,!1),t.setObjectsPickable(r,!0)):(t.setObjectsXRayed(r,!1),t.setObjectsVisible(r,!0),t.setObjectsPickable(r,!0))}setEnabled(e){}expandTreeViewToDepth(e){}showNodeInTreeView(e){this._treeView.showNode(e)}unShowNodeInTreeView(){this._treeView.unShowNode()}destroy(){super.destroy(),this._treeView.destroy(),this.viewer.scene.off(this._onModelLoaded),this.viewer.scene.off(this._onModelUnloaded),this.viewer.scene.off(this._onMetaDataLoaded)}get treeView(){return this._treeView}}const eE=Y.vec3();class tE extends Nk{constructor(e,t={}){super(e);const{modelType:i}=t;this.eventTrigger=e.eventTrigger,this._treeView=new xk(this.viewer,{hierarchy:"storeys",autoAddModels:!1,autoExpandDepth:1}),this._treeView.on("rootNodes_Created",e=>{this._rootNode=e,this.eventTrigger.emit("storeys_rootNodes",e)}),this._treeView.on("nodeNodes_Created",e=>{this._nodeList=e,this.eventTrigger.emit("storeys_nodeNodes",e)}),this._treeView.on("objectNodes_Created",e=>{this._objectList=e,this.eventTrigger.emit("storeys_objectNodes",e)}),this._treeView.on("checkBoxChanged",e=>{this.eventTrigger.emit("storeys_checkBoxChanged",e)}),"ifc"===i?this._onModelLoaded=this.viewer.scene.on("modelLoaded",e=>{this._treeView.addModel(e,{rootName:e})}):this._onMetaDataLoaded=this.eventTrigger.on("metaLoaded",e=>{"success"===e.result&&(this._treeView.addModel(e.metaModel.id,{rootName:e.metaModel.id}),this.eventTrigger.emit("treeReady"))}),this._onModelUnloaded=this.viewer.scene.on("modelUnloaded",e=>{this.viewer.metaScene.metaModels[e]&&this._treeView.removeModel(e)})}get rootNode(){return this._rootNode}get nodesList(){return this._nodeList}get objectList(){return this._objectList}getNodeIdByObjectId(e){if(null==this._objectList[e])return null;this._objectList[e].nodeId}getNodeById(e){return this._treeView.getNodeById(e)}getChildrenById(e){this._treeView.getChildrenById(e)}checkboxChangeHandler(e,t){const i=this._nodeList[e],r=t,{objects:n}=this.viewer.scene;let s=0;this._treeView.withNodeTree(i,e=>{const{objectId:t}=e,i=n[t],o=0===e.children.length;e.numVisibleEntities=r?e.numEntities:0,o&&r!==e.checked&&s++,e.checked=r,i&&(i.visible=r)});let{parent:o}=i;for(;o;)o.checked=r,r?o.numVisibleEntities+=s:o.numVisibleEntities-=s,o=o.parent}nodeTitleClicked(e){const{scene:t}=this.viewer,i=this._nodeList[e],r=[];this._treeView.withNodeTree(i,e=>{e.objectId&&r.push(e.objectId)});const{checked:n}=i;n?(t.setObjectsXRayed(r,!1),t.setObjectsVisible(r,!1),t.setObjectsPickable(r,!0)):(t.setObjectsXRayed(r,!1),t.setObjectsVisible(r,!0),t.setObjectsPickable(r,!0))}setEnabled(e){}_selectObjects(e,t){const{scene:i}=this.viewer,r=i.getAABB(e);this.viewer.cameraControl.pivotPos=Y.getAABB3Center(r,eE),t?(i.setObjectsXRayed(i.objectIds,!0),i.setObjectsVisible(i.objectIds,!0),i.setObjectsPickable(i.objectIds,!1),i.setObjectsSelected(i.selectedObjectIds,!1),i.setObjectsXRayed(e,!1),i.setObjectsVisible(e,!0),i.setObjectsPickable(e,!0),this.viewer.cameraFlight.flyTo({aabb:r},()=>{setTimeout(()=>{i.setObjectsVisible(i.xrayedObjectIds,!1),i.setObjectsXRayed(i.xrayedObjectIds,!1)},500),t()})):(i.setObjectsVisible(i.objectIds,!1),i.setObjectsPickable(i.xrayedObjectIds,!0),i.setObjectsXRayed(i.xrayedObjectIds,!1),i.setObjectsSelected(i.selectedObjectIds,!1),i.setObjectsVisible(e,!0),this.viewer.cameraFlight.jumpTo({aabb:r}))}destroy(){super.destroy(),this._treeView.destroy(),this.viewer.scene.off(this._onModelLoaded),this.viewer.scene.off(this._onModelUnloaded),this.viewer.scene.off(this._onMetaDataLoaded)}expandTreeViewToDepth(e){}showNodeInTreeView(e){this._treeView.showNode(e)}unShowNodeInTreeView(){this._treeView.unShowNode()}selectStorey(e,t){const{metaScene:i}=this.viewer,r=i.metaObjects[e];if(!r)return void this.error(`selectStorey() - object is not found: ${e}`);if("IfcBuildingStorey"!==r.type)return void this.error(`selectStorey() - object is not found: ${e}`);const n=r.getObjectIDsInSubtree();this._selectObjects(n,t)}}const iE=Y.vec3();class rE extends Nk{constructor(e,t){super(e,t),this._saveOrthoActive=null,this._cameraControlNavModeMediator=t.cameraControlNavModeMediator,this._active=!1}setEnabled(e){super.setEnabled(e),this._saveOrthoActive=this.bimViewer.orthoMode.getActive()}setActive(e,t=()=>{}){this._active!==e?(this._active=e,e?this._enterThreeDMode(()=>{this.fire("active",this._active),t&&t()}):this._exitThreeDMode(()=>{this.fire("active",this._active),t&&t()})):t&&t()}_enterThreeDMode(e=()=>{}){const{viewer:t}=this,{scene:i}=t,{aabb:r}=i,n=Y.getAABB3Diag(r),s=Y.getAABB3Center(r,iE),o=Math.abs(n/Math.tan(32.5)),{camera:a}=i,l=a.yUp?[-1,-1,-1]:[1,1,1],u=a.yUp?[-1,1,-1]:[-1,1,1];t.cameraControl.pivotPos=s,this.bimViewer.navCubeMode.setActive(!0),this.bimViewer.firstPersonMode.setEnabled(!0),this._cameraControlNavModeMediator.setThreeDModeActive(!0),this.bimViewer.sectionTool.setEnabled(!0),this.bimViewer.orthoMode.setEnabled(!0),e?t.cameraFlight.flyTo({look:s,eye:[s[0]-o*l[0],s[1]-o*l[1],s[2]-o*l[2]],up:u,orthoScale:1.3*n,duration:1,projection:this._saveOrthoActive?"ortho":"perspective"},()=>{e()}):t.cameraFlight.jumpTo({look:s,eye:[s[0]-o*l[0],s[1]-o*l[1],s[2]-o*l[2]],up:u,orthoScale:1.3*n,projection:this._saveOrthoActive?"ortho":"perspective"})}_exitThreeDMode(e=()=>{}){const{viewer:t}=this,{scene:i}=t,{camera:r}=i,{aabb:n}=i,s=Y.getAABB3Center(n),o=Y.getAABB3Diag(n),a=Math.abs(o/Math.tan(45*Y.DEGTORAD)),l=1.3*o,u=iE;u[0]=s[0]+r.worldUp[0]*a,u[1]=s[1]+r.worldUp[1]*a,u[2]=s[2]+r.worldUp[2]*a;const c=Y.mulVec3Scalar(r.worldForward,-1,[]);this.bimViewer.sectionTool.setActive(!1),this.bimViewer.firstPersonMode.setEnabled(!1),this._saveOrthoActive=this.bimViewer.orthoMode.getActive(),this.bimViewer.orthoMode.setEnabled(!1),this._cameraControlNavModeMediator.setThreeDModeActive(!1),e?t.cameraFlight.flyTo({eye:u,look:s,up:c,orthoScale:l,projection:"ortho"},()=>{this.bimViewer.navCubeMode.setActive(!1)}):(t.cameraFlight.jumpTo({eye:u,look:s,up:c,orthoScale:l,projection:"ortho"}),this.bimViewer.navCubeMode.setActive(!1))}}class nE extends Nk{constructor(e,t){super(e,t),this.viewer.camera.on("projection",()=>{const e="ortho"===this.viewer.camera.projection;this._active=e}),this._active=!1}setActive(e,t=()=>{}){this._active!==e?(this._active=e,e?t?this._enterOrthoMode(()=>{this.fire("active",this._active),t()}):(this._enterOrthoMode(),this.fire("active",this._active)):t?this._exitOrthoMode(()=>{this.fire("active",this._active),t()}):(this._exitOrthoMode(),this.fire("active",this._active))):t&&t()}_enterOrthoMode(e=()=>{}){e?this.viewer.cameraFlight.flyTo({projection:"ortho",duration:.5},e):this.viewer.cameraFlight.jumpTo({projection:"ortho"})}_exitOrthoMode(e=()=>{}){e?this.viewer.cameraFlight.flyTo({projection:"perspective",duration:.5},e):this.viewer.cameraFlight.jumpTo({projection:"perspective"})}}class sE extends Nk{constructor(e,t){if(super(e,t),this._AnnotationList={},this._visible=!0,this._currentType="image",this._modelId=t.modelId,this.eventTrigger=e.eventTrigger,this.imageSrc=new Map,document.getElementById("myAnnotationDiv"))this.annotationWrapper=document.getElementById("myAnnotationDiv");else{this.annotationWrapper=document.createElement("div"),this.annotationWrapper.id="myAnnotationDiv";const{canvas:t}=e.viewer.scene.canvas;t.parentNode.insertBefore(this.annotationWrapper,t)}let i;this.annotationsPlugin=new tt(this.viewer,{markerHTML:"<div class='annotation-marker annotation-marker-{{iconType}} {{iconType}}' id='{{id}}' entityid='{{entityid}}' style='position:absolute;'><img src='{{iconPath}}'></div>",container:this.annotationWrapper,values:{id:"",entityid:"",iconPath:"",iconType:""}}),this.bimViewer.on("closeAll",()=>{this.setActive(!1)}),this.on("active",e=>{}),this.annotationsPlugin.on("markerClicked",e=>{this.eventTrigger.emit("markerClicked",e),i=e}),this.annotationsPlugin.on("markerDoubleClicked",e=>{this.eventTrigger.emit("markerDoubleClicked",e)});const r=e=>{this._active&&("Delete"!==e.key&&8!==e.keyCode||this.eventTrigger.emit("requestDeleteMarker",i.id))};document.addEventListener("keydown",r.bind(this)),this.on("destroy",()=>{document.removeEventListener("keydown",r.bind(this))})}setAllVisible(e=!this._visible){this._visible=e,this.annotationsPlugin.setAllVisible(e)}clickToCreateAnno(e){if(!this.getActive())return;if(!this.getEnabled())return;const t=this.getCanvasPos(e),i=this.viewer.scene.pick({canvasPos:t,pickSurface:!0});if(i){const e=i.entity.id,t=this.generateId(e);this.annotationsPlugin.createAnnotation({id:t,pickResult:i,occludable:!0,markerShown:!0,labelShown:!1,values:{id:t,entityid:e,iconPath:this.getTypeImage(this._currentType),iconType:this._currentType}}),this.currentAnnotation={id:t,modelId:this._modelId,entityId:e,type:this._currentType,content:{worldPos:[i.worldPos[0],i.worldPos[1],i.worldPos[2]],fileContent:[],text:""}},this.eventTrigger.emit("createAnnotation",{type:this._currentType,currentAnnotation:this.currentAnnotation})}else console.log("没有获取到合法的坐标,传入的内容:",e)}generateId(e){const t=Date.now(),i=Math.floor(1e3*performance.now());return`${e}_${this._currentType}_${t}_${i}`}getCanvasPos(e){const t=[];if(e)if("TouchEvent"in window&&e instanceof TouchEvent){if(!e.touches||0===e.touches.length)return;const i=e.touches[0];let r=e.target,n=0,s=0;for(;r.offsetParent;)n+=r.offsetLeft,s+=r.offsetTop,r=r.offsetParent;t[0]=i.pageX-n,t[1]=i.pageY-s}else{let i=this.viewer.scene.canvas.canvas,r=0,n=0;for(;i.offsetParent;)r+=i.offsetLeft,n+=i.offsetTop,i=i.offsetParent;t[0]=e.pageX-r,t[1]=e.pageY-n}else e=window.event,t[0]=e.x,t[1]=e.y;return t}setCurrentType(e){this._currentType=e}showAnnotationList(){this.clear();const e=this._AnnotationList;e.length>0&&e.forEach(e=>{this.addAnnotation(e.id.toString(),e.content.worldPos,e.type)})}addAnnotation(e,t,i){this.annotationsPlugin.createAnnotation({id:e,worldPos:t,occludable:!0,markerShown:this._visible,labelShown:!1,values:{id:e,entityid:e,iconPath:this.getTypeImage(i),iconType:i}})}clear(){this.annotationsPlugin.clear()}get AnnotationList(){return this._AnnotationList}set AnnotationList(e){this._AnnotationList=e}getTypeImage(e){if(this.imageSrc.size<1){let t=document.getElementById(`annotation_tool_btn_img_${e}`);return t&&t instanceof HTMLImageElement&&t.src?t.src:null}return this.imageSrc.get(e)}setTypeImage(e){for(const t in e)this.imageSrc.set(t,e[t])}destroyAnnotationById(e){this.annotationsPlugin.destroyAnnotation(e),this._AnnotationList[e]&&delete this._AnnotationList[e]}getAnnotationById(e){return this.annotationsPlugin.annotations[e]}get annotationPluginList(){return this.annotationsPlugin.annotations}destroy(){var e;this.fire("destroy",!0),this.clear(),this.annotationsPlugin.destroy(),this.annotationWrapper&&(null===(e=this.annotationWrapper.parentNode)||void 0===e||e.removeChild(this.annotationWrapper))}}class oE extends Nk{constructor(e,t){super(e,t),this._offsetX=0,this._offsetY=0,this._isTouch=!1,this._approximate=!0,this._precision=2,this.eventTrigger=e.eventTrigger,this.angleMeasureContainer=document.createElement("div"),this.angleMeasureContainer.id="myAngleMeasuresDiv";const{canvas:i}=e.viewer.scene.canvas;i.parentNode.insertBefore(this.angleMeasureContainer,i),this._angleMeasurementsPlugin=new Ke(this.viewer,{container:this.angleMeasureContainer,defaultColor:"#0065FC"}),this._angleMeasurementsMouseControl=new We(this._angleMeasurementsPlugin,{snapping:!0,offsetX:t.offsetX,offsetY:t.offsetY}),this._angleMeasurementsTouchControl=new qe(this._angleMeasurementsPlugin,{offsetX:t.offsetX,offsetY:t.offsetY}),this._angleMeasurementsSimulateMouseControl=new Ye(this._angleMeasurementsPlugin,{offsetX:t.offsetX,offsetY:t.offsetY,snapping:!0}),this._angleMeasurementsMouseControl.snapping=!0,this.bimViewer.on("closeAll",()=>{this.setActive(!1)}),this._initSettings(),this._initializeMeasure()}setActive(e){this._active=e,e?this.chosedTarget&&this.chosedTarget.setHighlighted(!0):(this.refreshMouseState(),this.setAllHightLighted(!1)),this._isTouch?(this._angleMeasurementsTouchControl.active=e,this._angleMeasurementsSimulateMouseControl.active=e):this._angleMeasurementsMouseControl.active=e}getActive(){return this._active}_initSettings(){this._angleMeasurementsMouseControl.activate(),this._angleMeasurementsMouseControl.active=!1,this._angleMeasurementsTouchControl.activate(),this._angleMeasurementsTouchControl.active=!1,this._angleMeasurementsSimulateMouseControl.activate(),this._angleMeasurementsSimulateMouseControl.active=!1}_initializeMeasure(){this._angleMeasurementsPlugin.on("measurementCreated",e=>{this.eventTrigger.emit("newAngleMeasure",{id:e.id}),this.newMeasure=e,this.chosedTarget=null}),this._angleMeasurementsPlugin.on("measurementEnd",e=>{0!==this.getMeasureResultByID(e.id)?(this.eventTrigger.emit("createAngleMeasure",{id:e.id,result:this.getMeasureResultByID(e.id)}),this.setAllHightLighted(!1),this.chosedTarget=e,this.chosedTarget.setHighlighted(!0),this.newMeasure=null):this.destroyMeasurementById(e.id)}),this._angleMeasurementsPlugin.on("mouseOver",e=>{e.measurement.setHighlighted(!0)}),this._angleMeasurementsPlugin.on("mouseLeave",e=>{e.angleMeasurement==this.chosedTarget&&this._active||e.measurement.setHighlighted(!1)}),this._angleMeasurementsPlugin.on("clickMeasure",e=>{this.chosedTarget&&this.chosedTarget.id!==e.measurement.id&&this.chosedTarget.setHighlighted(!1),this.chosedTarget=e.measurement,this.chosedTarget.setHighlighted(!0),this.eventTrigger.emit("clickAngleMeasure",{id:this.chosedTarget.id,result:this.getMeasureResultByID(this.chosedTarget.id)})}),this._angleMeasurementsPlugin.on("touchMeasure",e=>{this.chosedTarget&&this.chosedTarget.id!==e.measurement.id&&this.chosedTarget.setHighlighted(!1),this.chosedTarget=e.measurement,this.chosedTarget.setHighlighted(!0),this.eventTrigger.emit("clickAngleMeasure",{id:this.chosedTarget.id,result:this.getMeasureResultByID(this.chosedTarget.id)})}),this._angleMeasurementsPlugin.on("measurementDestroyed",e=>{this.eventTrigger.emit("AngleMeasureDestroyed",{id:e.id})});const e=()=>{this._active&&this.chosedTarget&&this.chosedTarget.setHighlighted(!0)},t=e=>{if(this._active&&("Delete"===e.key||8===e.keyCode)){if(!this.chosedTarget)return;this.destroyMeasurementById(this.chosedTarget.id),this._angleMeasurementsPlugin.fire("measureDelete",null),0==this.getNumMeasurements()&&(this.chosedTarget=null)}};document.addEventListener("mousemove",e.bind(this)),document.addEventListener("keydown",t.bind(this)),this.on("destroy",()=>{document.removeEventListener("mousemove",e.bind(this)),document.removeEventListener("keydown",t.bind(this))})}set isTouch(e){this._isTouch=e,e||this._angleMeasurementsMouseControl.deactivate()}get isTouch(){return this._isTouch}set precision(e){this._precision=e,this._angleMeasurementsPlugin.precision=e}get precision(){return this._precision}set offsetX(e){this._offsetX=e,this._isTouch?(this._angleMeasurementsTouchControl.offsetX=e,this._angleMeasurementsSimulateMouseControl.offsetX=e):this._angleMeasurementsMouseControl.offsetX=e}get offsetX(){return this._offsetX}set offsetY(e){this._offsetY=e,this._isTouch?(this._angleMeasurementsTouchControl.offsetY=e,this._angleMeasurementsSimulateMouseControl.offsetY=e):this._angleMeasurementsMouseControl.offsetY=e}get offsetY(){return this._offsetY}refreshMouseState(){this.newMeasure&&(this.destroyMeasurementById(this.newMeasure.id),this.isTouch?(this._angleMeasurementsTouchControl.touchState=0,this._angleMeasurementsSimulateMouseControl.mouseState=0):this._angleMeasurementsMouseControl.mouseState=0,this.setAllHightLighted(!1),this.newMeasure=null)}setAllVisible(e){this._angleMeasurementsPlugin.setMeasurementsShown(e)}setSnappingEnabled(e){return this._angleMeasurementsMouseControl.snapping=e}getNumMeasurements(){return Object.keys(this._angleMeasurementsPlugin.measurements).length}getMeasurementsList(){return this._angleMeasurementsPlugin.measurements}getMeasurementById(e){return this.getMeasurementsList()[e]}getMeasureResultByID(e){const t=this.getMeasurementById(e);return t?t.angle:0}setMeasureColorByID(e,t){this.getMeasurementById(e).color=t}setMeasureClickbleById(e,t){this.getMeasurementById(e).clickable=t}setMeasureHightlighted(e,t){this.getMeasurementById(e).setHighlighted(t)}setAllHightLighted(e){const t=this.getMeasurementsList();for(const i in t)t[i].setHighlighted(e)}setVisibleById(e,t){this.getMeasurementById(e).visible=t}setAngleLabelVisible(e,t){this.getMeasurementById(e).angleVisible=t}destroyMeasurementById(e){this._angleMeasurementsPlugin.destroyMeasurement(e)}onSimulateMousedown(e){this._angleMeasurementsSimulateMouseControl.onMousedown(e)}onSimulateMousemove(e){this._angleMeasurementsSimulateMouseControl.onMousemove(e)}onSimulateMouseup(e){this._angleMeasurementsSimulateMouseControl.onMouseup(e)}clear(){this._angleMeasurementsPlugin.clear()}stop(){this._isTouch?(this._angleMeasurementsTouchControl.deactivate(),this._angleMeasurementsSimulateMouseControl.deactivate()):this._angleMeasurementsMouseControl.deactivate()}destroy(){this.fire("destroy",!0),this.angleMeasureContainer.parentNode&&this.angleMeasureContainer.parentNode.removeChild(this.angleMeasureContainer),this._angleMeasurementsPlugin.destroy(),this._angleMeasurementsMouseControl.destroy(),this._angleMeasurementsTouchControl.destroy(),this._angleMeasurementsSimulateMouseControl.destroy(),super.destroy()}}class aE extends Nk{constructor(e,t){super(e,t),this._offsetX=0,this._offsetY=0,this._isTouch=!1,this._approximate=!0,this._precision=2,this._scale=1,this._unit="m",this.eventTrigger=e.eventTrigger,this.distanceMeasureContainer=document.createElement("div"),this.distanceMeasureContainer.id="myDistanceMeasuresDiv";const{canvas:i}=e.viewer.scene.canvas;i.parentNode.insertBefore(this.distanceMeasureContainer,i),this._distanceMeasurementsPlugin=new gh(this.viewer,{container:this.distanceMeasureContainer,defaultAxisVisible:!1,defaultColor:"#0065FC"}),this._distanceMeasurementsMouseControl=new fh(this._distanceMeasurementsPlugin,{snapping:!0,offsetX:t.offsetX,offsetY:t.offsetY}),this._distanceMeasurementsTouchControl=new mh(this._distanceMeasurementsPlugin,{offsetX:t.offsetX,offsetY:t.offsetY}),this._distanceMeasurementsSimulateMouseControl=new vh(this._distanceMeasurementsPlugin,{offsetX:t.offsetX,offsetY:t.offsetY,snapping:!0}),this._distanceMeasurementsMouseControl.snapping=!0,this.bimViewer.on("closeAll",()=>{this.setActive(!1)}),this._initSettings(),this._initializeMeasure()}setActive(e){this._active=e,e?this.chosedTarget&&this.chosedTarget.setHighlighted(!0):(this.refreshMouseState(),this.setAllHightLighted(!1)),this._isTouch?(this._distanceMeasurementsTouchControl.active=e,this._distanceMeasurementsSimulateMouseControl.active=e):this._distanceMeasurementsMouseControl.active=e}getActive(){return this._active}_initSettings(){this._distanceMeasurementsMouseControl.activate(),this._distanceMeasurementsMouseControl.active=!1,this._distanceMeasurementsTouchControl.activate(),this._distanceMeasurementsTouchControl.active=!1,this._distanceMeasurementsSimulateMouseControl.activate(),this._distanceMeasurementsSimulateMouseControl.active=!1}_initializeMeasure(){this._distanceMeasurementsPlugin.on("measurementCreated",e=>{this.eventTrigger.emit("newDistanceMeasure",{id:e.id}),this.newMeasure=e,this.chosedTarget=null}),this._distanceMeasurementsPlugin.on("measurementEnd",e=>{0!==this.getMeasureResultByID(e.id)?(this.eventTrigger.emit("createDistanceMeasure",{id:e.id,result:this.getMeasureResultByID(e.id),xResult:e.xLabel,yResult:e.yLabel,zResult:e.zLabel}),this.setAllHightLighted(!1),this.chosedTarget=e,this.chosedTarget.setHighlighted(!0),this.newMeasure=null):this.destroyMeasurementById(e.id)}),this._distanceMeasurementsPlugin.on("mouseOver",e=>{e.measurement.setHighlighted(!0)}),this._distanceMeasurementsPlugin.on("mouseLeave",e=>{e.distanceMeasurement==this.chosedTarget&&this._active||e.measurement.setHighlighted(!1)}),this._distanceMeasurementsPlugin.on("clickMeasure",e=>{this.chosedTarget&&this.chosedTarget.id!==e.measurement.id&&this.chosedTarget.setHighlighted(!1),this.chosedTarget=e.measurement,this.chosedTarget.setHighlighted(!0),this.eventTrigger.emit("clickDistanceMeasure",{id:this.chosedTarget.id,result:this.getMeasureResultByID(this.chosedTarget.id)})}),this._distanceMeasurementsPlugin.on("touchMeasure",e=>{this.chosedTarget&&this.chosedTarget.id!==e.measurement.id&&this.chosedTarget.setHighlighted(!1),this.chosedTarget=e.measurement,this.chosedTarget.setHighlighted(!0),this.eventTrigger.emit("clickDistanceMeasure",{id:this.chosedTarget.id,result:this.getMeasureResultByID(this.chosedTarget.id)})}),this._distanceMeasurementsPlugin.on("measurementCancel",e=>{this.eventTrigger.emit("DistanceMeasureCancel",{id:e.id})}),this._distanceMeasurementsPlugin.on("measurementDestroyed",e=>{this.eventTrigger.emit("DistanceMeasureDestroyed",{id:e.id})});const e=()=>{this._active&&this.chosedTarget&&this.chosedTarget.setHighlighted(!0)},t=e=>{if(this._active&&("Delete"===e.key||8===e.keyCode)){if(!this.chosedTarget)return;this.destroyMeasurementById(this.chosedTarget.id),this._distanceMeasurementsPlugin.fire("measureDelete",null),0==this.getNumMeasurements()&&(this.chosedTarget=null)}};document.addEventListener("mousemove",e.bind(this)),document.addEventListener("keydown",t.bind(this)),this.on("destroy",()=>{document.removeEventListener("mousemove",e.bind(this)),document.removeEventListener("keydown",t.bind(this))})}set isTouch(e){this._isTouch=e,e||this._distanceMeasurementsMouseControl.deactivate()}get isTouch(){return this._isTouch}set unit(e){switch(this._unit=e,e){case"m":this.viewer.scene.metrics.units="meters",this.viewer.scene.metrics.scale=1*this._scale;break;case"cm":this.viewer.scene.metrics.units="centimeters",this.viewer.scene.metrics.scale=100*this._scale;break;case"mm":this.viewer.scene.metrics.units="millimeters",this.viewer.scene.metrics.scale=1e3*this._scale}}set scale(e){this._scale=e,this.unit=this._unit}get scale(){return this._scale}set precision(e){this._precision=e,this._distanceMeasurementsPlugin.precision=e}get precision(){return this._precision}set offsetX(e){this._offsetX=e,this._isTouch?(this._distanceMeasurementsTouchControl.offsetX=e,this._distanceMeasurementsSimulateMouseControl.offsetX=e):this._distanceMeasurementsMouseControl.offsetX=e}get offsetX(){return this._offsetX}set offsetY(e){this._offsetY=e,this._isTouch?(this._distanceMeasurementsTouchControl.offsetY=e,this._distanceMeasurementsSimulateMouseControl.offsetY=e):this._distanceMeasurementsMouseControl.offsetY=e}get offsetY(){return this._offsetY}refreshMouseState(){this.newMeasure&&(this.destroyMeasurementById(this.newMeasure.id),this.isTouch?(this._distanceMeasurementsTouchControl.touchState=0,this._distanceMeasurementsSimulateMouseControl.mouseState=0):this._distanceMeasurementsMouseControl.mouseState=0,this.setAllHightLighted(!1),this.newMeasure=null)}setAllVisible(e){this._distanceMeasurementsPlugin.setMeasurementsShown(e)}setSnappingEnabled(e){return this._distanceMeasurementsMouseControl.snapping=e}getNumMeasurements(){return Object.keys(this._distanceMeasurementsPlugin.measurements).length}getMeasurementsList(){return this._distanceMeasurementsPlugin.measurements}getMeasurementById(e){return this.getMeasurementsList()[e]}getMeasureResultByID(e){const t=this.getMeasurementById(e);return t?t.length:0}setMeasureColorByID(e,t){this.getMeasurementById(e).color=t}setMeasureClickbleById(e,t){this.getMeasurementById(e).clickable=t}setMeasureHightlighted(e,t){this.getMeasurementById(e).setHighlighted(t)}setAllHightLighted(e){const t=this.getMeasurementsList();for(const i in t)t[i].setHighlighted(e)}setVisibleById(e,t){this.getMeasurementById(e).visible=t}setLableVisibleById(e,t){this.getMeasurementById(e).labelsVisible=t}destroyMeasurementById(e){this._distanceMeasurementsPlugin.destroyMeasurement(e)}onSimulateMousedown(e){this._distanceMeasurementsSimulateMouseControl.onMousedown(e)}onSimulateMousemove(e){this._distanceMeasurementsSimulateMouseControl.onMousemove(e)}onSimulateMouseup(e){this._distanceMeasurementsSimulateMouseControl.onMouseup(e)}clear(){this._distanceMeasurementsPlugin.clear()}stop(){this._isTouch?(this._distanceMeasurementsTouchControl.deactivate(),this._distanceMeasurementsSimulateMouseControl.deactivate()):this._distanceMeasurementsMouseControl.deactivate()}destroy(){this.fire("destroy",!0),this.distanceMeasureContainer.parentNode&&this.distanceMeasureContainer.parentNode.removeChild(this.distanceMeasureContainer),this._distanceMeasurementsPlugin.destroy(),this._distanceMeasurementsMouseControl.destroy(),this._distanceMeasurementsTouchControl.destroy(),this._distanceMeasurementsSimulateMouseControl.destroy(),super.destroy()}}class lE extends Nk{constructor(e,t){super(e),this._isTouch=!1,this._tools={},this._toolType="distance",this.eventTrigger=e.eventTrigger,this._measure_distance_tool=new aE(e,{}),this._measure_angle_tool=new oE(e,{}),this._tools.distance=this._measure_distance_tool,this._tools.angle=this._measure_angle_tool,this.bimViewer.on("closeAll",()=>{this.setActive(!1)}),this.setActive(!0),this._initEventHandle()}_initEventHandle(){this.eventTrigger.on("clickAngleMeasure",e=>{this._active&&(this.getActiveByType("angle")||this.setActiveByType("angle",!0))}),this.eventTrigger.on("clickDistanceMeasure",e=>{this._active&&(this.getActiveByType("distance")||this.setActiveByType("distance",!0))})}setActive(e=!this._active){this._active=e,this._measure_angle_tool.setEnabled(e),this._measure_distance_tool.setEnabled(e),e||(this._measure_angle_tool.setActive(e),this._measure_distance_tool.setActive(e))}getActive(){return this._active}set isTouch(e){this._isTouch=e,this._measure_angle_tool.isTouch=e,this._measure_distance_tool.isTouch=e}get isTouch(){return this._isTouch}get measureAngleTool(){return this._measure_angle_tool}get measureDistanceTool(){return this._measure_distance_tool}getMeasureToolByType(e){return this._tools[e]}setActiveByType(e,t=!this._tools[e].getActive()){this._toolType=e;for(let i in this._tools)e==i?this._tools[i].setActive(t):this._tools[i].setActive(!1)}getActiveByType(e){return this._tools[e].getActive()}get currentTool(){return this._tools[this._toolType]}SetMeasureAngleActive(e=!this._measure_angle_tool.getActive(),t=()=>{}){this._measure_angle_tool.setActive(e),t(this._measure_angle_tool.getActive())}SetMeasureDistanceActive(e=!this._measure_distance_tool.getActive(),t=()=>{}){this._measure_distance_tool.setActive(e),t(this._measure_distance_tool.getActive())}setAllDisActive(){for(let e in this._tools)this._tools[e].setActive(!1)}setMeasureOffSet(e,t){this.measureAngleTool.offsetX=e,this.measureAngleTool.offsetY=t,this.measureDistanceTool.offsetX=e,this.measureDistanceTool.offsetY=t}setSnapRadius(e){this.viewer.cameraControl.snapRadius=e}destroy(){this._measure_distance_tool.destroy(),this._measure_angle_tool.destroy()}}
|
|
37
|
+
***************************************************************************** */var bA=function(e,t){return bA=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i])},bA(e,t)};function wA(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function i(){this.constructor=e}bA(e,t),e.prototype=null===t?Object.create(t):(i.prototype=t.prototype,new i)}var xA=function(){return xA=Object.assign||function(e){for(var t,i=1,r=arguments.length;i<r;i++)for(var n in t=arguments[i])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e},xA.apply(this,arguments)};function BA(e,t,i,r){return new(i||(i=Promise))(function(n,s){function o(e){try{l(r.next(e))}catch(e){s(e)}}function a(e){try{l(r.throw(e))}catch(e){s(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof i?t:new i(function(e){e(t)})).then(o,a)}l((r=r.apply(e,t||[])).next())})}function PA(e,t){var i,r,n,s,o={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(s){return function(a){return function(s){if(i)throw new TypeError("Generator is already executing.");for(;o;)try{if(i=1,r&&(n=2&s[0]?r.return:s[0]?r.throw||((n=r.return)&&n.call(r),0):r.next)&&!(n=n.call(r,s[1])).done)return n;switch(r=0,n&&(s=[2&s[0],n.value]),s[0]){case 0:case 1:n=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!(n=o.trys,(n=n.length>0&&n[n.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!n||s[1]>n[0]&&s[1]<n[3])){o.label=s[1];break}if(6===s[0]&&o.label<n[1]){o.label=n[1],n=s;break}if(n&&o.label<n[2]){o.label=n[2],o.ops.push(s);break}n[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],r=0}finally{i=n=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,a])}}}function CA(e,t,i){if(i||2===arguments.length)for(var r,n=0,s=t.length;n<s;n++)!r&&n in t||(r||(r=Array.prototype.slice.call(t,0,n)),r[n]=t[n]);return e.concat(r||t)}for(var MA=function(){function e(e,t,i,r){this.left=e,this.top=t,this.width=i,this.height=r}return e.prototype.add=function(t,i,r,n){return new e(this.left+t,this.top+i,this.width+r,this.height+n)},e.fromClientRect=function(t,i){return new e(i.left+t.windowBounds.left,i.top+t.windowBounds.top,i.width,i.height)},e.fromDOMRectList=function(t,i){var r=Array.from(i).find(function(e){return 0!==e.width});return r?new e(r.left+t.windowBounds.left,r.top+t.windowBounds.top,r.width,r.height):e.EMPTY},e.EMPTY=new e(0,0,0,0),e}(),kA=function(e,t){return MA.fromClientRect(e,t.getBoundingClientRect())},EA=function(e){for(var t=[],i=0,r=e.length;i<r;){var n=e.charCodeAt(i++);if(n>=55296&&n<=56319&&i<r){var s=e.charCodeAt(i++);56320==(64512&s)?t.push(((1023&n)<<10)+(1023&s)+65536):(t.push(n),i--)}else t.push(n)}return t},SA=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];if(String.fromCodePoint)return String.fromCodePoint.apply(String,e);var i=e.length;if(!i)return"";for(var r=[],n=-1,s="";++n<i;){var o=e[n];o<=65535?r.push(o):(o-=65536,r.push(55296+(o>>10),o%1024+56320)),(n+1===i||r.length>16384)&&(s+=String.fromCharCode.apply(String,r),r.length=0)}return s},TA="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",IA="undefined"==typeof Uint8Array?[]:new Uint8Array(256),FA=0;FA<64;FA++)IA[TA.charCodeAt(FA)]=FA;for(var DA="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",RA="undefined"==typeof Uint8Array?[]:new Uint8Array(256),OA=0;OA<64;OA++)RA[DA.charCodeAt(OA)]=OA;for(var LA=function(e,t,i){return e.slice?e.slice(t,i):new Uint16Array(Array.prototype.slice.call(e,t,i))},jA=function(){function e(e,t,i,r,n,s){this.initialValue=e,this.errorValue=t,this.highStart=i,this.highValueIndex=r,this.index=n,this.data=s}return e.prototype.get=function(e){var t;if(e>=0){if(e<55296||e>56319&&e<=65535)return t=((t=this.index[e>>5])<<2)+(31&e),this.data[t];if(e<=65535)return t=((t=this.index[2048+(e-55296>>5)])<<2)+(31&e),this.data[t];if(e<this.highStart)return t=2080+(e>>11),t=this.index[t],t+=e>>5&63,t=((t=this.index[t])<<2)+(31&e),this.data[t];if(e<=1114111)return this.data[this.highValueIndex]}return this.errorValue},e}(),UA="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",NA="undefined"==typeof Uint8Array?[]:new Uint8Array(256),VA=0;VA<64;VA++)NA[UA.charCodeAt(VA)]=VA;var QA=10,HA=13,GA=15,zA=17,WA=18,KA=19,XA=20,qA=21,YA=22,JA=24,ZA=25,$A=26,ed=27,td=28,id=30,rd=32,nd=33,sd=34,od=35,ad=37,ld=38,ud=39,cd=40,hd=42,Ad=[9001,65288],dd="×",pd="÷",fd=function(e){var t,i,r,n=function(e){var t,i,r,n,s,o=.75*e.length,a=e.length,l=0;"="===e[e.length-1]&&(o--,"="===e[e.length-2]&&o--);var u="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof Uint8Array&&void 0!==Uint8Array.prototype.slice?new ArrayBuffer(o):new Array(o),c=Array.isArray(u)?u:new Uint8Array(u);for(t=0;t<a;t+=4)i=RA[e.charCodeAt(t)],r=RA[e.charCodeAt(t+1)],n=RA[e.charCodeAt(t+2)],s=RA[e.charCodeAt(t+3)],c[l++]=i<<2|r>>4,c[l++]=(15&r)<<4|n>>2,c[l++]=(3&n)<<6|63&s;return u}(e),s=Array.isArray(n)?function(e){for(var t=e.length,i=[],r=0;r<t;r+=4)i.push(e[r+3]<<24|e[r+2]<<16|e[r+1]<<8|e[r]);return i}(n):new Uint32Array(n),o=Array.isArray(n)?function(e){for(var t=e.length,i=[],r=0;r<t;r+=2)i.push(e[r+1]<<8|e[r]);return i}(n):new Uint16Array(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GYABgAGAAYABgAGAAYABgAGAAYAB4Bn8GhQZgAGAAYAB1AHcDFQSLBmAAYABgAJMGdQA9A3UAmwajBqsGqwaVALMGuwbDBjAAywbSBtIG1QbSBtIG0gbSBtIG0gbdBuMG6wbzBvsGAwcLBxMHAwcbByMHJwcsBywHMQcsB9IGOAdAB0gHTgfSBkgHVgfSBtIG0gbSBtIG0gbSBtIG0gbSBiwHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAdgAGAALAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsB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AMUIyQjRCNkI4AjoCHUAdQB1AO4I9gj+CAYJDgkTCS0HGwkjCYIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiAAIAAAAFAAYABgAGIAXwBgAHEAdQBFAJUAogCyAKAAYABgAEIA4ABGANMA4QDxAMEBDwE1AFwBLAE6AQEBUQF4QkhCmEKoQrhCgAHIQsAB0MLAAcABwAHAAeDC6ABoAHDCwMMAAcABwAHAAdDDGMMAAcAB6MM4wwjDWMNow3jDaABoAGgAaABoAGgAaABoAGgAaABoAGgAaABoAGgAaABoAGgAaABoAEjDqABWw6bDqABpg6gAaABoAHcDvwOPA+gAaABfA/8DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DpcPAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABw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dQB1AEkMdQB1AHUAdQB1AFAMMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwAHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQBYDHUAdQB1AF8MMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUA+wMVBGcMMAAwAHwBbwx1AHcMfwyHDI8MMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAYABgAJcMMAAwADAAdQB1AJ8MlQClDDAAMACtDCwHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsB7UMLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AA0EMAC9DDAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAsBywHLAcsBywHLAcsBywHLQcwAMEMyAwsBywHLAcsBywHLAcsBywHLAcsBywHzAwwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwAHUAdQB1ANQM2QzhDDAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMABgAGAAYABgAGAAYABgAOkMYADxDGAA+AwADQYNYABhCWAAYAAODTAAMAAwADAAFg1gAGAAHg37AzAAMAAwADAAYABgACYNYAAsDTQNPA1gAEMNPg1LDWAAYABgAGAAYABgAGAAYABgAGAAUg1aDYsGVglhDV0NcQBnDW0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AANAAMAAQABAAIABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQACgATABcAHgAbABoAHgAXABYAEgAeABsAGAAPABgAHABLAEsASwBLAEsASwBLAEsASwBLABgAGAAeAB4AHgATAB4AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQABYAGwASAB4AHgAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAWAA0AEQAeAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAAQABAAEAAQABAAFAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAJABYAGgAbABsAGwAeAB0AHQAeAE8AFwAeAA0AHgAeABoAGwBPAE8ADgBQAB0AHQAdAE8ATwAXAE8ATwBPABYAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAdAFAAUABQAFAAUABQAFAAUAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeA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ABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAUAAeAB4AHgAeAB4AHgBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAYAA0AKwArAB4AHgAbACsABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQADQAEAB4ABAAEAB4ABAAEABMABAArACsAKwArACsAKwArACsAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAKwArACsAKwBWAFYAVgBWAB4AHgArACsAKwArACsAKwArACsAKwArACsAHgAeAB4AHgAeAB4AHgAeAB4AGgAaABoAGAAYAB4AHgAEAAQABAAEAAQABAAEAAQABAAEAAQAEwAEACsAEwATAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABABLAEsASwBLAEsASwBLAEsASwBLABoAGQAZAB4AUABQAAQAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQABMAUAAEAAQABAAEAAQABAAEAB4AHgAEAAQABAAEAAQABABQAFAABAAEAB4ABAAEAAQABABQAFAASwBLAEsASwBLAEsASwBLAEsASwBQAFAAUAAeAB4AUAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwAeAFAABABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAFAAKwArACsAKwArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQAUABQAB4AHgAYABMAUAArACsABAAbABsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAFAABAAEAAQABAAEAFAABAAEAAQAUAAEAAQABAAEAAQAKwArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAArACsAHgArAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArACsAKwArACsAKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAB4ABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAUAAEAAQABAAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQAFAABAAEAA0ADQBLAEsASwBLAEsASwBLAEsASwBLAB4AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAArAFAAUABQAFAAUABQAFAAUAArACsAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUAArACsAKwBQAFAAUABQACsAKwAEAFAABAAEAAQABAAEAAQABAArACsABAAEACsAKwAEAAQABABQACsAKwArACsAKwArACsAKwAEACsAKwArACsAUABQACsAUABQAFAABAAEACsAKwBLAEsASwBLAEsASwBLAEsASwBLAFAAUAAaABoAUABQAFAAUABQAEwAHgAbAFAAHgAEACsAKwAEAAQABAArAFAAUABQAFAAUABQACsAKwArACsAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQACsAUABQACsAUABQACsAKwAEACsABAAEAAQABAAEACsAKwArACsABAAEACsAKwAEAAQABAArACsAKwAEACsAKwArACsAKwArACsAUABQAFAAUAArAFAAKwArACsAKwArACsAKwBLAEsASwBLAEsASwBLAEsASwBLAAQABABQAFAAUAAEAB4AKwArACsAKwArACsAKwArACsAKwAEAAQABAArAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQACsAUABQAFAAUABQACsAKwAEAFAABAAEAAQABAAEAAQABAAEACsABAAEAAQAKwAEAAQABAArACsAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAABAAEACsAKwBLAEsASwBLAEsASwBLAEsASwBLAB4AGwArACsAKwArACsAKwArAFAABAAEAAQABAAEAAQAKwAEAAQABAArAFAAUABQAFAAUABQAFAAUAArACsAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAArACsABAAEACsAKwAEAAQABAArACsAKwArACsAKwArAAQABAAEACsAKwArACsAUABQACsAUABQAFAABAAEACsAKwBLAEsASwBLAEsASwBLAEsASwBLAB4AUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArAAQAUAArAFAAUABQAFAAUABQACsAKwArAFAAUABQACsAUABQAFAAUAArACsAKwBQAFAAKwBQACsAUABQACsAKwArAFAAUAArACsAKwBQAFAAUAArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArAAQABAAEAAQABAArACsAKwAEAAQABAArAAQABAAEAAQAKwArAFAAKwArACsAKwArACsABAArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAUABQAFAAHgAeAB4AHgAeAB4AGwAeACsAKwArACsAKwAEAAQABAAEAAQAUABQAFAAUABQAFAAUABQACsAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAUAAEAAQABAAEAAQABAAEACsABAAEAAQAKwAEAAQABAAEACsAKwArACsAKwArACsABAAEACsAUABQAFAAKwArACsAKwArAFAAUAAEAAQAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAKwAOAFAAUABQAFAAUABQAFAAHgBQAAQABAAEAA4AUABQAFAAUABQAFAAUABQACsAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAKwArAAQAUAAEAAQABAAEAAQABAAEACsABAAEAAQAKwAEAAQABAAEACsAKwArACsAKwArACsABAAEACsAKwArACsAKwArACsAUAArAFAAUAAEAAQAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwBQAFAAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAFAABAAEAAQABAAEAAQABAArAAQABAAEACsABAAEAAQABABQAB4AKwArACsAKwBQAFAAUAAEAFAAUABQAFAAUABQAFAAUABQAFAABAAEACsAKwBLAEsASwBLAEsASwBLAEsASwBLAFAAUABQAFAAUABQAFAAUABQABoAUABQAFAAUABQAFAAKwAEAAQABAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQACsAUAArACsAUABQAFAAUABQAFAAUAArACsAKwAEACsAKwArACsABAAEAAQABAAEAAQAKwAEACsABAAEAAQABAAEAAQABAAEACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArAAQABAAeACsAKwArACsAKwArACsAKwArACsAKwArAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXAAqAFwAXAAqACoAKgAqACoAKgAqACsAKwArACsAGwBcAFwAXABcAFwAXABcACoAKgAqACoAKgAqACoAKgAeAEsASwBLAEsASwBLAEsASwBLAEsADQANACsAKwArACsAKwBcAFwAKwBcACsAXABcAFwAXABcACsAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACsAXAArAFwAXABcAFwAXABcAFwAXABcAFwAKgBcAFwAKgAqACoAKgAqACoAKgAqACoAXAArACsAXABcAFwAXABcACsAXAArACoAKgAqACoAKgAqACsAKwBLAEsASwBLAEsASwBLAEsASwBLACsAKwBcAFwAXABcAFAADgAOAA4ADgAeAA4ADgAJAA4ADgANAAkAEwATABMAEwATAAkAHgATAB4AHgAeAAQABAAeAB4AHgAeAB4AHgBLAEsASwBLAEsASwBLAEsASwBLAFAAUABQAFAAUABQAFAAUABQAFAADQAEAB4ABAAeAAQAFgARABYAEQAEAAQAUABQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQADQAEAAQABAAEAAQADQAEAAQAUABQAFAAUABQAAQABAAEAAQABAAEAAQABAAEAAQABAArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAArAA0ADQAeAB4AHgAeAB4AHgAEAB4AHgAeAB4AHgAeACsAHgAeAA4ADgANAA4AHgAeAB4AHgAeAAkACQArACsAKwArACsAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgBcAEsASwBLAEsASwBLAEsASwBLAEsADQANAB4AHgAeAB4AXABcAFwAXABcAFwAKgAqACoAKgBcAFwAXABcACoAKgAqAFwAKgAqACoAXABcACoAKgAqACoAKgAqACoAXABcAFwAKgAqACoAKgBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACoAKgAqACoAKgAqACoAKgAqACoAKgAqAFwAKgBLAEsASwBLAEsASwBLAEsASwBLACoAKgAqACoAKgAqAFAAUABQAFAAUABQACsAUAArACsAKwArACsAUAArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgBQAFAAUABQAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAUAArACsAUABQAFAAUABQAFAAUAArAFAAKwBQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAKwArAFAAUABQAFAAUABQAFAAKwBQACsAUABQAFAAUAArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsABAAEAAQAHgANAB4AHgAeAB4AHgAeAB4AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUAArACsADQBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAANAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAWABEAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAA0ADQANAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAAQABAAEACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAANAA0AKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUAArAAQABAArACsAKwArACsAKwArACsAKwArACsAKwBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqAA0ADQAVAFwADQAeAA0AGwBcACoAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwAeAB4AEwATAA0ADQAOAB4AEwATAB4ABAAEAAQACQArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUAAEAAQAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQAUAArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAArACsAKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArACsAHgArACsAKwATABMASwBLAEsASwBLAEsASwBLAEsASwBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXAArACsAXABcAFwAXABcACsAKwArACsAKwArACsAKwArACsAKwBcAFwAXABcAFwAXABcAFwAXABcAFwAXAArACsAKwArAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAXAArACsAKwAqACoAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAArACsAHgAeAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACoAKgAqACoAKgAqACoAKgAqACoAKwAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKwArAAQASwBLAEsASwBLAEsASwBLAEsASwArACsAKwArACsAKwBLAEsASwBLAEsASwBLAEsASwBLACsAKwArACsAKwArACoAKgAqACoAKgAqACoAXAAqACoAKgAqACoAKgArACsABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsABAAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABABQAFAAUABQAFAAUABQACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwANAA0AHgANAA0ADQANAB4AHgAeAB4AHgAeAB4AHgAeAB4ABAAEAAQABAAEAAQABAAEAAQAHgAeAB4AHgAeAB4AHgAeAB4AKwArACsABAAEAAQAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABABQAFAASwBLAEsASwBLAEsASwBLAEsASwBQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwAeAB4AHgAeAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArAA0ADQANAA0ADQBLAEsASwBLAEsASwBLAEsASwBLACsAKwArAFAAUABQAEsASwBLAEsASwBLAEsASwBLAEsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAA0ADQBQAFAAUABQAFAAUABQAFAAUAArAC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FAAUABQACsAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXAA0ADQANAA0ADQANAA0ADQAeAA0AFgANAB4AHgAXABcAHgAeABcAFwAWABEAFgARABYAEQAWABEADQANAA0ADQATAFAADQANAB4ADQANAB4AHgAeAB4AHgAMAAwADQANAA0AHgANAA0AFgANAA0ADQANAA0ADQANAA0AHgANAB4ADQANAB4AHgAeACsAKwArACsAKwArACsAKwArACsAKwArACsAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACsAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAKwArACsAKwArACsAKwArACsAKwArACsAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAlACUAJQAlACUAJQAlACUAJQAlACUAJQArACsAKwArAA0AEQARACUAJQBHAFcAVwAWABEAFgARABYAEQAWABEAFgARACUAJQAWABEAFgARABYAEQAWABEAFQAWABEAEQAlAFcAVwBXAFcAVwBXAFcAVwBXAAQABAAEAAQABAAEACUAVwBXAFcAVwA2ACUAJQBXAFcAVwBHAEcAJQAlACUAKwBRAFcAUQBXAFEAVwBRAFcAUQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFEAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBRAFcAUQBXAFEAVwBXAFcAVwBXAFcAUQBXAFcAVwBXAFcAVwBRAFEAKwArAAQABAAVABUARwBHAFcAFQBRAFcAUQBXAFEAVwBRAFcAUQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFEAVwBRAF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ArACsAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAFAABAAEAAQABAAeAAQABAAEAAQABAAEAAQABAAEAAQAHgBQAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AUABQAAQABABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAeAA0ADQANAA0ADQArACsAKwArACsAKwArACsAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAFAAUABQAFAAUABQAFAAUABQAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AUAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgBQAB4AHgAeAB4AHgAeAFAAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAHgAeAB4AHgAeAB4AHgAeAB4AKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAeAB4AUABQAFAAUABQAFAAUABQAFAAUABQAAQAUABQAFAABABQAFAAUABQAAQAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAAeAB4AHgAeAAQAKwArACsAUABQAFAAUABQAFAAHgAeABoAHgArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAADgAOABMAEwArACsAKwArACsAKwArACsABAAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwANAA0ASwBLAEsASwBLAEsASwBLAEsASwArACsAKwArACsAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABABQAFAAUABQAFAAUAAeAB4AHgBQAA4AUABQAAQAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAA0ADQBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArACsAKwArACsAKwArACsAKwArAB4AWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYACsAKwArAAQAHgAeAB4AHgAeAB4ADQANAA0AHgAeAB4AHgArAFAASwBLAEsASwBLAEsASwBLAEsASwArACsAKwArAB4AHgBcAFwAXABcAFwAKgBcAFwAXABcAFwAXABcAFwAXABcAEsASwBLAEsASwBLAEsASwBLAEsAXABcAFwAXABcACsAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwArAFAAUABQAAQAUABQAFAAUABQAFAAUABQAAQABAArACsASwBLAEsASwBLAEsASwBLAEsASwArACsAHgANAA0ADQBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAKgAqACoAXAAqACoAKgBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXAAqAFwAKgAqACoAXABcACoAKgBcAFwAXABcAFwAKgAqAFwAKgBcACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFwAXABcACoAKgBQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAA0ADQBQAFAAUAAEAAQAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUAArACsAUABQAFAAUABQAFAAKwArAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQADQAEAAQAKwArAE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KwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUAAaAB4AKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAGAARABEAGAAYABMAEwAWABEAFAArACsAKwArACsAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACUAJQAlACUAJQAWABEAFgARABYAEQAWABEAFgARABYAEQAlACUAFgARACUAJQAlACUAJQAlACUAEQAlABEAKwAVABUAEwATACUAFgARABYAEQAWABEAJQAlACUAJQAlACUAJQAlACsAJQAbABoAJQArACsAKwArAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAAcAKwATACUAJQAbABoAJQAlABYAEQAlACUAEQAlABEAJQBXAFcAVwBXAFcAVwBXAFcAVwBXABUAFQAlACUAJQATACUAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXABYAJQARACUAJQAlAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwAWACUAEQAlABYAEQARABYAEQARABUAVwBRAFEAUQBRAFEAUQBRAFEAUQBRAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAEcARwArACsAVwBXAFcAVwBXAFcAKwArAFcAVwBXAFcAVwBXACsAKwBXAFcAVwBXAFcAVwArACsAVwBXAFcAKwArACsAGgAbACUAJQAlABsAGwArAB4AHgAeAB4AHgAeAB4AKwArACsAKwArACsAKwArACsAKwAEAAQABAAQAB0AKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsADQANAA0AKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArAB4AHgAeAB4AHgAeAB4AHgAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgBQAFAAHgAeAB4AKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAAQAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAA0AUABQAFAAUAArACsAKwArAFAAUABQAFAAUABQAFAAUAANAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwAeACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAKwArAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUAArACsAKwBQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwANAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAeAB4AUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUAArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArAA0AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAUABQAFAAUABQAAQABAAEACsABAAEACsAKwArACsAKwAEAAQABAAEAFAAUABQAFAAKwBQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAAQABAAEACsAKwArACsABABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAA0ADQANAA0ADQANAA0ADQAeACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAeAFAAUABQAFAAUABQAFAAUAAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAArACsAKwArAFAAUABQAFAAUAANAA0ADQANAA0ADQAUACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsADQANAA0ADQANAA0ADQBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAB4AHgAeAB4AKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAAQABAAEAAQAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUAArAAQABAANACsAKwBQAFAAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAAQABAAEAAQABAAEAAQABAAEAAQABABQAFAAUABQAB4AHgAeAB4AHgArACsAKwArACsAKwAEAAQABAAEAAQABAAEAA0ADQAeAB4AHgAeAB4AKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsABABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAAEAAQABAAEAAQABAAeAB4AHgANAA0ADQANACsAKwArACsAKwArACsAKwArACsAKwAeACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArACsAKwBLAEsASwBLAEsASwBLAEsASwBLACsAKwArACsAKwArAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsASwBLAEsASwBLAEsASwBLAEsASwANAA0ADQANAFAABAAEAFAAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAeAA4AUAArACsAKwArACsAKwArACsAKwAEAFAAUABQAFAADQANAB4ADQAEAAQABAAEAB4ABAAEAEsASwBLAEsASwBLAEsASwBLAEsAUAAOAFAADQANAA0AKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAANAA0AHgANAA0AHgAEACsAUABQAFAAUABQAFAAUAArAFAAKwBQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAA0AKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsABAAEAAQABAArAFAAUABQAFAAUABQAFAAUAArACsAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQACsAUABQAFAAUABQACsABAAEAFAABAAEAAQABAAEAAQABAArACsABAAEACsAKwAEAAQABAArACsAUAArACsAKwArACsAKwAEACsAKwArACsAKwBQAFAAUABQAFAABAAEACsAKwAEAAQABAAEAAQABAAEACsAKwArAAQABAAEAAQABAArACsAKwArACsAKwArACsAKwArACsABAAEAAQABAAEAAQABABQAFAAUABQAA0ADQANAA0AHgBLAEsASwBLAEsASwBLAEsASwBLAA0ADQArAB4ABABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAAQABAAEAFAAUAAeAFAAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAArACsABAAEAAQABAAEAAQABAAEAAQADgANAA0AEwATAB4AHgAeAA0ADQANAA0ADQANAA0ADQANAA0ADQANAA0ADQANAFAAUABQAFAABAAEACsAKwAEAA0ADQAeAFAAKwArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAFAAKwArACsAKwArACsAKwBLAEsASwBLAEsASwBLAEsASwBLACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAKwArACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwBcAFwADQANAA0AKgBQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAeACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwBQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAKwArAFAAKwArAFAAUABQAFAAUABQAFAAUAArAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQAKwAEAAQAKwArAAQABAAEAAQAUAAEAFAABAAEAA0ADQANACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAArACsABAAEAAQABAAEAAQABABQAA4AUAAEACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAABAAEAAQABAAEAAQABAAEAAQABABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAFAABAAEAAQABAAOAB4ADQANAA0ADQAOAB4ABAArACsAKwArACsAKwArACsAUAAEAAQABAAEAAQABAAEAAQABAAEAAQAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAA0ADQANAFAADgAOAA4ADQANACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEACsABAAEAAQABAAEAAQABAAEAFAADQANAA0ADQANACsAKwArACsAKwArACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwAOABMAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQACsAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAArACsAKwAEACsABAAEACsABAAEAAQABAAEAAQABABQAAQAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAKwBQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQAKwAEAAQAKwAEAAQABAAEAAQAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAeAB4AKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAB4AHgAeAB4AHgAeAB4AHgAaABoAGgAaAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwArACsAKwArACsAKwArAA0AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsADQANAA0ADQANACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAASABIAEgAQwBDAEMAUABQAFAAUABDAFAAUABQAEgAQwBIAEMAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAASABDAEMAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwAJAAkACQAJAAkACQAJABYAEQArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABIAEMAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwANAA0AKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAAQABAAEAAQABAANACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAA0ADQANAB4AHgAeAB4AHgAeAFAAUABQAFAADQAeACsAKwArACsAKwArACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwArAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAANAA0AHgAeACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwAEAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArACsAKwArACsAKwAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAARwBHABUARwAJACsAKwArACsAKwArACsAKwArACsAKwAEAAQAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXACsAKwArACsAKwArACsAKwBXAFcAVwBXAFcAVwBXAFcAVwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUQBRAFEAKwArACsAKwArACsAKwArACsAKwArACsAKwBRAFEAUQBRACsAKwArACsAKwArACsAKwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUAArACsAHgAEAAQADQAEAAQABAAEACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwArACsAKwArAB4AHgAeAB4AHgAeAB4AKwArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAAQABAAEAAQABAAeAB4AHgAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAB4AHgAEAAQABAAEAAQABAAEAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4ABAAEAAQABAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4ABAAEAAQAHgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwArACsAKwAeAB4AHgAeAB4AH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AHgAeAB4AHgAeAAQAHgAeAA0ADQANAA0AHgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAAQABAAEAAQAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAAQABAAEAAQABAAEAAQAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArAAQABAAEAAQABAAEAAQAKwAEAAQAKwAEAAQABAAEAAQAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwAEAAQABAAEAAQABAAEAFAAUABQAFAAUABQAFAAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwBQAB4AKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArABsAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwArAB4AHgAeAB4ABAAEAAQABAAEAAQABABQACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwArACsAKwArABYAFgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAGgBQAFAAUAAaAFAAUABQAFAAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAKwBQACsAKwBQACsAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAKwBQACsAUAArACsAKwArACsAKwBQACsAKwArACsAUAArAFAAKwBQACsAUABQAFAAKwBQAFAAKwBQACsAKwBQACsAUAArAFAAKwBQACsAUAArAFAAUAArAFAAKwArAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQAFAAUAArAFAAUABQAFAAKwBQACsAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAUABQAFAAKwBQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAeAB4AKwArACsAKwArACsAKwArACsAKwArACsAKwArAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8AJQAlACUAHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHgAeAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB4AHgAeACUAJQAlAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQApACkAKQApACkAKQApACkAKQApACkAKQApACkAKQApACkAKQApACkAKQApACkAKQApACkAJQAlACUAJQAlACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAeAB4AJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlAB4AHgAlACUAJQAlACUAHgAlACUAJQAlACUAIAAgACAAJQAlACAAJQAlACAAIAAgACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACEAIQAhACEAIQAlACUAIAAgACUAJQAgACAAIAAgACAAIAAgACAAIAAgACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAJQAlACUAIAA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QAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAKwAEACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAA=="),gd=[id,36],md=[1,2,3,5],vd=[QA,8],_d=[ed,$A],yd=md.concat(vd),bd=[ld,ud,cd,sd,od],wd=[GA,HA],xd=function(e,t,i,r){var n=r[i];if(Array.isArray(e)?-1!==e.indexOf(n):e===n)for(var s=i;s<=r.length;){if((l=r[++s])===t)return!0;if(l!==QA)break}if(n===QA)for(s=i;s>0;){var o=r[--s];if(Array.isArray(e)?-1!==e.indexOf(o):e===o)for(var a=i;a<=r.length;){var l;if((l=r[++a])===t)return!0;if(l!==QA)break}if(o!==QA)break}return!1},Bd=function(e,t){for(var i=e;i>=0;){var r=t[i];if(r!==QA)return r;i--}return 0},Pd=function(e,t,i,r,n){if(0===i[r])return dd;var s=r-1;if(Array.isArray(n)&&!0===n[s])return dd;var o=s-1,a=s+1,l=t[s],u=o>=0?t[o]:0,c=t[a];if(2===l&&3===c)return dd;if(-1!==md.indexOf(l))return"!";if(-1!==md.indexOf(c))return dd;if(-1!==vd.indexOf(c))return dd;if(8===Bd(s,t))return pd;if(11===fd.get(e[s]))return dd;if((l===rd||l===nd)&&11===fd.get(e[a]))return dd;if(7===l||7===c)return dd;if(9===l)return dd;if(-1===[QA,HA,GA].indexOf(l)&&9===c)return dd;if(-1!==[zA,WA,KA,JA,td].indexOf(c))return dd;if(Bd(s,t)===YA)return dd;if(xd(23,YA,s,t))return dd;if(xd([zA,WA],qA,s,t))return dd;if(xd(12,12,s,t))return dd;if(l===QA)return pd;if(23===l||23===c)return dd;if(16===c||16===l)return pd;if(-1!==[HA,GA,qA].indexOf(c)||14===l)return dd;if(36===u&&-1!==wd.indexOf(l))return dd;if(l===td&&36===c)return dd;if(c===XA)return dd;if(-1!==gd.indexOf(c)&&l===ZA||-1!==gd.indexOf(l)&&c===ZA)return dd;if(l===ed&&-1!==[ad,rd,nd].indexOf(c)||-1!==[ad,rd,nd].indexOf(l)&&c===$A)return dd;if(-1!==gd.indexOf(l)&&-1!==_d.indexOf(c)||-1!==_d.indexOf(l)&&-1!==gd.indexOf(c))return dd;if(-1!==[ed,$A].indexOf(l)&&(c===ZA||-1!==[YA,GA].indexOf(c)&&t[a+1]===ZA)||-1!==[YA,GA].indexOf(l)&&c===ZA||l===ZA&&-1!==[ZA,td,JA].indexOf(c))return dd;if(-1!==[ZA,td,JA,zA,WA].indexOf(c))for(var h=s;h>=0;){if((A=t[h])===ZA)return dd;if(-1===[td,JA].indexOf(A))break;h--}if(-1!==[ed,$A].indexOf(c))for(h=-1!==[zA,WA].indexOf(l)?o:s;h>=0;){var A;if((A=t[h])===ZA)return dd;if(-1===[td,JA].indexOf(A))break;h--}if(ld===l&&-1!==[ld,ud,sd,od].indexOf(c)||-1!==[ud,sd].indexOf(l)&&-1!==[ud,cd].indexOf(c)||-1!==[cd,od].indexOf(l)&&c===cd)return dd;if(-1!==bd.indexOf(l)&&-1!==[XA,$A].indexOf(c)||-1!==bd.indexOf(c)&&l===ed)return dd;if(-1!==gd.indexOf(l)&&-1!==gd.indexOf(c))return dd;if(l===JA&&-1!==gd.indexOf(c))return dd;if(-1!==gd.concat(ZA).indexOf(l)&&c===YA&&-1===Ad.indexOf(e[a])||-1!==gd.concat(ZA).indexOf(c)&&l===WA)return dd;if(41===l&&41===c){for(var d=i[s],p=1;d>0&&41===t[--d];)p++;if(p%2!=0)return dd}return l===rd&&c===nd?dd:pd},Cd=function(e,t){t||(t={lineBreak:"normal",wordBreak:"normal"});var i=function(e,t){void 0===t&&(t="strict");var i=[],r=[],n=[];return e.forEach(function(e,s){var o=fd.get(e);if(o>50?(n.push(!0),o-=50):n.push(!1),-1!==["normal","auto","loose"].indexOf(t)&&-1!==[8208,8211,12316,12448].indexOf(e))return r.push(s),i.push(16);if(4===o||11===o){if(0===s)return r.push(s),i.push(id);var a=i[s-1];return-1===yd.indexOf(a)?(r.push(r[s-1]),i.push(a)):(r.push(s),i.push(id))}return r.push(s),31===o?i.push("strict"===t?qA:ad):o===hd||29===o?i.push(id):43===o?e>=131072&&e<=196605||e>=196608&&e<=262141?i.push(ad):i.push(id):void i.push(o)}),[r,i,n]}(e,t.lineBreak),r=i[0],n=i[1],s=i[2];"break-all"!==t.wordBreak&&"break-word"!==t.wordBreak||(n=n.map(function(e){return-1!==[ZA,id,hd].indexOf(e)?ad:e}));var o="keep-all"===t.wordBreak?s.map(function(t,i){return t&&e[i]>=19968&&e[i]<=40959}):void 0;return[r,n,o]},Md=function(){function e(e,t,i,r){this.codePoints=e,this.required="!"===t,this.start=i,this.end=r}return e.prototype.slice=function(){return SA.apply(void 0,this.codePoints.slice(this.start,this.end))},e}(),kd=45,Ed=43,Sd=-1,Td=function(e){return e>=48&&e<=57},Id=function(e){return Td(e)||e>=65&&e<=70||e>=97&&e<=102},Fd=function(e){return 10===e||9===e||32===e},Dd=function(e){return function(e){return function(e){return e>=97&&e<=122}(e)||function(e){return e>=65&&e<=90}(e)}(e)||function(e){return e>=128}(e)||95===e},Rd=function(e){return Dd(e)||Td(e)||e===kd},Od=function(e){return e>=0&&e<=8||11===e||e>=14&&e<=31||127===e},Ld=function(e,t){return 92===e&&10!==t},jd=function(e,t,i){return e===kd?Dd(t)||Ld(t,i):!!Dd(e)||!(92!==e||!Ld(e,t))},Ud=function(e,t,i){return e===Ed||e===kd?!!Td(t)||46===t&&Td(i):Td(46===e?t:e)},Nd=function(e){var t=0,i=1;e[t]!==Ed&&e[t]!==kd||(e[t]===kd&&(i=-1),t++);for(var r=[];Td(e[t]);)r.push(e[t++]);var n=r.length?parseInt(SA.apply(void 0,r),10):0;46===e[t]&&t++;for(var s=[];Td(e[t]);)s.push(e[t++]);var o=s.length,a=o?parseInt(SA.apply(void 0,s),10):0;69!==e[t]&&101!==e[t]||t++;var l=1;e[t]!==Ed&&e[t]!==kd||(e[t]===kd&&(l=-1),t++);for(var u=[];Td(e[t]);)u.push(e[t++]);var c=u.length?parseInt(SA.apply(void 0,u),10):0;return i*(n+a*Math.pow(10,-o))*Math.pow(10,l*c)},Vd={type:2},Qd={type:3},Hd={type:4},Gd={type:13},zd={type:8},Wd={type:21},Kd={type:9},Xd={type:10},qd={type:11},Yd={type:12},Jd={type:14},Zd={type:23},$d={type:1},ep={type:25},tp={type:24},ip={type:26},rp={type:27},np={type:28},sp={type:29},op={type:31},ap={type:32},lp=function(){function e(){this._value=[]}return e.prototype.write=function(e){this._value=this._value.concat(EA(e))},e.prototype.read=function(){for(var e=[],t=this.consumeToken();t!==ap;)e.push(t),t=this.consumeToken();return e},e.prototype.consumeToken=function(){var e=this.consumeCodePoint();switch(e){case 34:return this.consumeStringToken(34);case 35:var t=this.peekCodePoint(0),i=this.peekCodePoint(1),r=this.peekCodePoint(2);if(Rd(t)||Ld(i,r)){var n=jd(t,i,r)?2:1;return{type:5,value:this.consumeName(),flags:n}}break;case 36:if(61===this.peekCodePoint(0))return this.consumeCodePoint(),Gd;break;case 39:return this.consumeStringToken(39);case 40:return Vd;case 41:return Qd;case 42:if(61===this.peekCodePoint(0))return this.consumeCodePoint(),Jd;break;case Ed:if(Ud(e,this.peekCodePoint(0),this.peekCodePoint(1)))return this.reconsumeCodePoint(e),this.consumeNumericToken();break;case 44:return Hd;case kd:var s=e,o=this.peekCodePoint(0),a=this.peekCodePoint(1);if(Ud(s,o,a))return this.reconsumeCodePoint(e),this.consumeNumericToken();if(jd(s,o,a))return this.reconsumeCodePoint(e),this.consumeIdentLikeToken();if(o===kd&&62===a)return this.consumeCodePoint(),this.consumeCodePoint(),tp;break;case 46:if(Ud(e,this.peekCodePoint(0),this.peekCodePoint(1)))return this.reconsumeCodePoint(e),this.consumeNumericToken();break;case 47:if(42===this.peekCodePoint(0))for(this.consumeCodePoint();;){var l=this.consumeCodePoint();if(42===l&&47===(l=this.consumeCodePoint()))return this.consumeToken();if(l===Sd)return this.consumeToken()}break;case 58:return ip;case 59:return rp;case 60:if(33===this.peekCodePoint(0)&&this.peekCodePoint(1)===kd&&this.peekCodePoint(2)===kd)return this.consumeCodePoint(),this.consumeCodePoint(),ep;break;case 64:var u=this.peekCodePoint(0),c=this.peekCodePoint(1),h=this.peekCodePoint(2);if(jd(u,c,h))return{type:7,value:this.consumeName()};break;case 91:return np;case 92:if(Ld(e,this.peekCodePoint(0)))return this.reconsumeCodePoint(e),this.consumeIdentLikeToken();break;case 93:return sp;case 61:if(61===this.peekCodePoint(0))return this.consumeCodePoint(),zd;break;case 123:return qd;case 125:return Yd;case 117:case 85:var A=this.peekCodePoint(0),d=this.peekCodePoint(1);return A!==Ed||!Id(d)&&63!==d||(this.consumeCodePoint(),this.consumeUnicodeRangeToken()),this.reconsumeCodePoint(e),this.consumeIdentLikeToken();case 124:if(61===this.peekCodePoint(0))return this.consumeCodePoint(),Kd;if(124===this.peekCodePoint(0))return this.consumeCodePoint(),Wd;break;case 126:if(61===this.peekCodePoint(0))return this.consumeCodePoint(),Xd;break;case Sd:return ap}return Fd(e)?(this.consumeWhiteSpace(),op):Td(e)?(this.reconsumeCodePoint(e),this.consumeNumericToken()):Dd(e)?(this.reconsumeCodePoint(e),this.consumeIdentLikeToken()):{type:6,value:SA(e)}},e.prototype.consumeCodePoint=function(){var e=this._value.shift();return void 0===e?-1:e},e.prototype.reconsumeCodePoint=function(e){this._value.unshift(e)},e.prototype.peekCodePoint=function(e){return e>=this._value.length?-1:this._value[e]},e.prototype.consumeUnicodeRangeToken=function(){for(var e=[],t=this.consumeCodePoint();Id(t)&&e.length<6;)e.push(t),t=this.consumeCodePoint();for(var i=!1;63===t&&e.length<6;)e.push(t),t=this.consumeCodePoint(),i=!0;if(i)return{type:30,start:parseInt(SA.apply(void 0,e.map(function(e){return 63===e?48:e})),16),end:parseInt(SA.apply(void 0,e.map(function(e){return 63===e?70:e})),16)};var r=parseInt(SA.apply(void 0,e),16);if(this.peekCodePoint(0)===kd&&Id(this.peekCodePoint(1))){this.consumeCodePoint(),t=this.consumeCodePoint();for(var n=[];Id(t)&&n.length<6;)n.push(t),t=this.consumeCodePoint();return{type:30,start:r,end:parseInt(SA.apply(void 0,n),16)}}return{type:30,start:r,end:r}},e.prototype.consumeIdentLikeToken=function(){var e=this.consumeName();return"url"===e.toLowerCase()&&40===this.peekCodePoint(0)?(this.consumeCodePoint(),this.consumeUrlToken()):40===this.peekCodePoint(0)?(this.consumeCodePoint(),{type:19,value:e}):{type:20,value:e}},e.prototype.consumeUrlToken=function(){var e=[];if(this.consumeWhiteSpace(),this.peekCodePoint(0)===Sd)return{type:22,value:""};var t=this.peekCodePoint(0);if(39===t||34===t){var i=this.consumeStringToken(this.consumeCodePoint());return 0===i.type&&(this.consumeWhiteSpace(),this.peekCodePoint(0)===Sd||41===this.peekCodePoint(0))?(this.consumeCodePoint(),{type:22,value:i.value}):(this.consumeBadUrlRemnants(),Zd)}for(;;){var r=this.consumeCodePoint();if(r===Sd||41===r)return{type:22,value:SA.apply(void 0,e)};if(Fd(r))return this.consumeWhiteSpace(),this.peekCodePoint(0)===Sd||41===this.peekCodePoint(0)?(this.consumeCodePoint(),{type:22,value:SA.apply(void 0,e)}):(this.consumeBadUrlRemnants(),Zd);if(34===r||39===r||40===r||Od(r))return this.consumeBadUrlRemnants(),Zd;if(92===r){if(!Ld(r,this.peekCodePoint(0)))return this.consumeBadUrlRemnants(),Zd;e.push(this.consumeEscapedCodePoint())}else e.push(r)}},e.prototype.consumeWhiteSpace=function(){for(;Fd(this.peekCodePoint(0));)this.consumeCodePoint()},e.prototype.consumeBadUrlRemnants=function(){for(;;){var e=this.consumeCodePoint();if(41===e||e===Sd)return;Ld(e,this.peekCodePoint(0))&&this.consumeEscapedCodePoint()}},e.prototype.consumeStringSlice=function(e){for(var t="";e>0;){var i=Math.min(5e4,e);t+=SA.apply(void 0,this._value.splice(0,i)),e-=i}return this._value.shift(),t},e.prototype.consumeStringToken=function(e){for(var t="",i=0;;){var r=this._value[i];if(r===Sd||void 0===r||r===e)return{type:0,value:t+=this.consumeStringSlice(i)};if(10===r)return this._value.splice(0,i),$d;if(92===r){var n=this._value[i+1];n!==Sd&&void 0!==n&&(10===n?(t+=this.consumeStringSlice(i),i=-1,this._value.shift()):Ld(r,n)&&(t+=this.consumeStringSlice(i),t+=SA(this.consumeEscapedCodePoint()),i=-1))}i++}},e.prototype.consumeNumber=function(){var e=[],t=4,i=this.peekCodePoint(0);for(i!==Ed&&i!==kd||e.push(this.consumeCodePoint());Td(this.peekCodePoint(0));)e.push(this.consumeCodePoint());i=this.peekCodePoint(0);var r=this.peekCodePoint(1);if(46===i&&Td(r))for(e.push(this.consumeCodePoint(),this.consumeCodePoint()),t=8;Td(this.peekCodePoint(0));)e.push(this.consumeCodePoint());i=this.peekCodePoint(0),r=this.peekCodePoint(1);var n=this.peekCodePoint(2);if((69===i||101===i)&&((r===Ed||r===kd)&&Td(n)||Td(r)))for(e.push(this.consumeCodePoint(),this.consumeCodePoint()),t=8;Td(this.peekCodePoint(0));)e.push(this.consumeCodePoint());return[Nd(e),t]},e.prototype.consumeNumericToken=function(){var e=this.consumeNumber(),t=e[0],i=e[1],r=this.peekCodePoint(0),n=this.peekCodePoint(1),s=this.peekCodePoint(2);return jd(r,n,s)?{type:15,number:t,flags:i,unit:this.consumeName()}:37===r?(this.consumeCodePoint(),{type:16,number:t,flags:i}):{type:17,number:t,flags:i}},e.prototype.consumeEscapedCodePoint=function(){var e=this.consumeCodePoint();if(Id(e)){for(var t=SA(e);Id(this.peekCodePoint(0))&&t.length<6;)t+=SA(this.consumeCodePoint());Fd(this.peekCodePoint(0))&&this.consumeCodePoint();var i=parseInt(t,16);return 0===i||function(e){return e>=55296&&e<=57343}(i)||i>1114111?65533:i}return e===Sd?65533:e},e.prototype.consumeName=function(){for(var e="";;){var t=this.consumeCodePoint();if(Rd(t))e+=SA(t);else{if(!Ld(t,this.peekCodePoint(0)))return this.reconsumeCodePoint(t),e;e+=SA(this.consumeEscapedCodePoint())}}},e}(),up=function(){function e(e){this._tokens=e}return e.create=function(t){var i=new lp;return i.write(t),new e(i.read())},e.parseValue=function(t){return e.create(t).parseComponentValue()},e.parseValues=function(t){return e.create(t).parseComponentValues()},e.prototype.parseComponentValue=function(){for(var e=this.consumeToken();31===e.type;)e=this.consumeToken();if(32===e.type)throw new SyntaxError("Error parsing CSS component value, unexpected EOF");this.reconsumeToken(e);var t=this.consumeComponentValue();do{e=this.consumeToken()}while(31===e.type);if(32===e.type)return t;throw new SyntaxError("Error parsing CSS component value, multiple values found when expecting only one")},e.prototype.parseComponentValues=function(){for(var e=[];;){var t=this.consumeComponentValue();if(32===t.type)return e;e.push(t),e.push()}},e.prototype.consumeComponentValue=function(){var e=this.consumeToken();switch(e.type){case 11:case 28:case 2:return this.consumeSimpleBlock(e.type);case 19:return this.consumeFunction(e)}return e},e.prototype.consumeSimpleBlock=function(e){for(var t={type:e,values:[]},i=this.consumeToken();;){if(32===i.type||vp(i,e))return t;this.reconsumeToken(i),t.values.push(this.consumeComponentValue()),i=this.consumeToken()}},e.prototype.consumeFunction=function(e){for(var t={name:e.value,values:[],type:18};;){var i=this.consumeToken();if(32===i.type||3===i.type)return t;this.reconsumeToken(i),t.values.push(this.consumeComponentValue())}},e.prototype.consumeToken=function(){var e=this._tokens.shift();return void 0===e?ap:e},e.prototype.reconsumeToken=function(e){this._tokens.unshift(e)},e}(),cp=function(e){return 15===e.type},hp=function(e){return 17===e.type},Ap=function(e){return 20===e.type},dp=function(e){return 0===e.type},pp=function(e,t){return Ap(e)&&e.value===t},fp=function(e){return 31!==e.type},gp=function(e){return 31!==e.type&&4!==e.type},mp=function(e){var t=[],i=[];return e.forEach(function(e){if(4===e.type){if(0===i.length)throw new Error("Error parsing function args, zero tokens for arg");return t.push(i),void(i=[])}31!==e.type&&i.push(e)}),i.length&&t.push(i),t},vp=function(e,t){return 11===t&&12===e.type||(28===t&&29===e.type||2===t&&3===e.type)},_p=function(e){return 17===e.type||15===e.type},yp=function(e){return 16===e.type||_p(e)},bp=function(e){return e.length>1?[e[0],e[1]]:[e[0]]},wp={type:17,number:0,flags:4},xp={type:16,number:50,flags:4},Bp={type:16,number:100,flags:4},Pp=function(e,t,i){var r=e[0],n=e[1];return[Cp(r,t),Cp(void 0!==n?n:r,i)]},Cp=function(e,t){if(16===e.type)return e.number/100*t;if(cp(e))switch(e.unit){case"rem":case"em":return 16*e.number;default:return e.number}return e.number},Mp="grad",kp="turn",Ep=function(e,t){if(15===t.type)switch(t.unit){case"deg":return Math.PI*t.number/180;case Mp:return Math.PI/200*t.number;case"rad":return t.number;case kp:return 2*Math.PI*t.number}throw new Error("Unsupported angle type")},Sp=function(e){return 15===e.type&&("deg"===e.unit||e.unit===Mp||"rad"===e.unit||e.unit===kp)},Tp=function(e){switch(e.filter(Ap).map(function(e){return e.value}).join(" ")){case"to bottom right":case"to right bottom":case"left top":case"top left":return[wp,wp];case"to top":case"bottom":return Ip(0);case"to bottom left":case"to left bottom":case"right top":case"top right":return[wp,Bp];case"to right":case"left":return Ip(90);case"to top left":case"to left top":case"right bottom":case"bottom right":return[Bp,Bp];case"to bottom":case"top":return Ip(180);case"to top right":case"to right top":case"left bottom":case"bottom left":return[Bp,wp];case"to left":case"right":return Ip(270)}return 0},Ip=function(e){return Math.PI*e/180},Fp=function(e,t){if(18===t.type){var i=Vp[t.name];if(void 0===i)throw new Error('Attempting to parse an unsupported color function "'+t.name+'"');return i(e,t.values)}if(5===t.type){if(3===t.value.length){var r=t.value.substring(0,1),n=t.value.substring(1,2),s=t.value.substring(2,3);return Op(parseInt(r+r,16),parseInt(n+n,16),parseInt(s+s,16),1)}if(4===t.value.length){r=t.value.substring(0,1),n=t.value.substring(1,2),s=t.value.substring(2,3);var o=t.value.substring(3,4);return Op(parseInt(r+r,16),parseInt(n+n,16),parseInt(s+s,16),parseInt(o+o,16)/255)}if(6===t.value.length){r=t.value.substring(0,2),n=t.value.substring(2,4),s=t.value.substring(4,6);return Op(parseInt(r,16),parseInt(n,16),parseInt(s,16),1)}if(8===t.value.length){r=t.value.substring(0,2),n=t.value.substring(2,4),s=t.value.substring(4,6),o=t.value.substring(6,8);return Op(parseInt(r,16),parseInt(n,16),parseInt(s,16),parseInt(o,16)/255)}}if(20===t.type){var a=Hp[t.value.toUpperCase()];if(void 0!==a)return a}return Hp.TRANSPARENT},Dp=function(e){return!(255&e)},Rp=function(e){var t=255&e,i=255&e>>8,r=255&e>>16,n=255&e>>24;return t<255?"rgba("+n+","+r+","+i+","+t/255+")":"rgb("+n+","+r+","+i+")"},Op=function(e,t,i,r){return(e<<24|t<<16|i<<8|Math.round(255*r))>>>0},Lp=function(e,t){if(17===e.type)return e.number;if(16===e.type){var i=3===t?1:255;return 3===t?e.number/100*i:Math.round(e.number/100*i)}return 0},jp=function(e,t){var i=t.filter(gp);if(3===i.length){var r=i.map(Lp),n=r[0],s=r[1],o=r[2];return Op(n,s,o,1)}if(4===i.length){var a=i.map(Lp),l=(n=a[0],s=a[1],o=a[2],a[3]);return Op(n,s,o,l)}return 0};function Up(e,t,i){return i<0&&(i+=1),i>=1&&(i-=1),i<1/6?(t-e)*i*6+e:i<.5?t:i<2/3?6*(t-e)*(2/3-i)+e:e}var Np=function(e,t){var i=t.filter(gp),r=i[0],n=i[1],s=i[2],o=i[3],a=(17===r.type?Ip(r.number):Ep(e,r))/(2*Math.PI),l=yp(n)?n.number/100:0,u=yp(s)?s.number/100:0,c=void 0!==o&&yp(o)?Cp(o,1):1;if(0===l)return Op(255*u,255*u,255*u,1);var h=u<=.5?u*(l+1):u+l-u*l,A=2*u-h,d=Up(A,h,a+1/3),p=Up(A,h,a),f=Up(A,h,a-1/3);return Op(255*d,255*p,255*f,c)},Vp={hsl:Np,hsla:Np,rgb:jp,rgba:jp},Qp=function(e,t){return Fp(e,up.create(t).parseComponentValue())},Hp={ALICEBLUE:4042850303,ANTIQUEWHITE:4209760255,AQUA:16777215,AQUAMARINE:2147472639,AZURE:4043309055,BEIGE:4126530815,BISQUE:4293182719,BLACK:255,BLANCHEDALMOND:4293643775,BLUE:65535,BLUEVIOLET:2318131967,BROWN:2771004159,BURLYWOOD:3736635391,CADETBLUE:1604231423,CHARTREUSE:2147418367,CHOCOLATE:3530104575,CORAL:4286533887,CORNFLOWERBLUE:1687547391,CORNSILK:4294499583,CRIMSON:3692313855,CYAN:16777215,DARKBLUE:35839,DARKCYAN:9145343,DARKGOLDENROD:3095837695,DARKGRAY:2846468607,DARKGREEN:6553855,DARKGREY:2846468607,DARKKHAKI:3182914559,DARKMAGENTA:2332068863,DARKOLIVEGREEN:1433087999,DARKORANGE:4287365375,DARKORCHID:2570243327,DARKRED:2332033279,DARKSALMON:3918953215,DARKSEAGREEN:2411499519,DARKSLATEBLUE:1211993087,DARKSLATEGRAY:793726975,DARKSLATEGREY:793726975,DARKTURQUOISE:13554175,DARKVIOLET:2483082239,DEEPPINK:4279538687,DEEPSKYBLUE:12582911,DIMGRAY:1768516095,DIMGREY:1768516095,DODGERBLUE:512819199,FIREBRICK:2988581631,FLORALWHITE:4294635775,FORESTGREEN:579543807,FUCHSIA:4278255615,GAINSBORO:3705462015,GHOSTWHITE:4177068031,GOLD:4292280575,GOLDENROD:3668254975,GRAY:2155905279,GREEN:8388863,GREENYELLOW:2919182335,GREY:2155905279,HONEYDEW:4043305215,HOTPINK:4285117695,INDIANRED:3445382399,INDIGO:1258324735,IVORY:4294963455,KHAKI:4041641215,LAVENDER:3873897215,LAVENDERBLUSH:4293981695,LAWNGREEN:2096890111,LEMONCHIFFON:4294626815,LIGHTBLUE:2916673279,LIGHTCORAL:4034953471,LIGHTCYAN:3774873599,LIGHTGOLDENRODYELLOW:4210742015,LIGHTGRAY:3553874943,LIGHTGREEN:2431553791,LIGHTGREY:3553874943,LIGHTPINK:4290167295,LIGHTSALMON:4288707327,LIGHTSEAGREEN:548580095,LIGHTSKYBLUE:2278488831,LIGHTSLATEGRAY:2005441023,LIGHTSLATEGREY:2005441023,LIGHTSTEELBLUE:2965692159,LIGHTYELLOW:4294959359,LIME:16711935,LIMEGREEN:852308735,LINEN:4210091775,MAGENTA:4278255615,MAROON:2147483903,MEDIUMAQUAMARINE:1724754687,MEDIUMBLUE:52735,MEDIUMORCHID:3126187007,MEDIUMPURPLE:2473647103,MEDIUMSEAGREEN:1018393087,MEDIUMSLATEBLUE:2070474495,MEDIUMSPRINGGREEN:16423679,MEDIUMTURQUOISE:1221709055,MEDIUMVIOLETRED:3340076543,MIDNIGHTBLUE:421097727,MINTCREAM:4127193855,MISTYROSE:4293190143,MOCCASIN:4293178879,NAVAJOWHITE:4292783615,NAVY:33023,OLDLACE:4260751103,OLIVE:2155872511,OLIVEDRAB:1804477439,ORANGE:4289003775,ORANGERED:4282712319,ORCHID:3664828159,PALEGOLDENROD:4008225535,PALEGREEN:2566625535,PALETURQUOISE:2951671551,PALEVIOLETRED:3681588223,PAPAYAWHIP:4293907967,PEACHPUFF:4292524543,PERU:3448061951,PINK:4290825215,PLUM:3718307327,POWDERBLUE:2967529215,PURPLE:2147516671,REBECCAPURPLE:1714657791,RED:4278190335,ROSYBROWN:3163525119,ROYALBLUE:1097458175,SADDLEBROWN:2336560127,SALMON:4202722047,SANDYBROWN:4104413439,SEAGREEN:780883967,SEASHELL:4294307583,SIENNA:2689740287,SILVER:3233857791,SKYBLUE:2278484991,SLATEBLUE:1784335871,SLATEGRAY:1887473919,SLATEGREY:1887473919,SNOW:4294638335,SPRINGGREEN:16744447,STEELBLUE:1182971135,TAN:3535047935,TEAL:8421631,THISTLE:3636451583,TOMATO:4284696575,TRANSPARENT:0,TURQUOISE:1088475391,VIOLET:4001558271,WHEAT:4125012991,WHITE:4294967295,WHITESMOKE:4126537215,YELLOW:4294902015,YELLOWGREEN:2597139199},Gp={name:"background-clip",initialValue:"border-box",prefix:!1,type:1,parse:function(e,t){return t.map(function(e){if(Ap(e))switch(e.value){case"padding-box":return 1;case"content-box":return 2}return 0})}},zp={name:"background-color",initialValue:"transparent",prefix:!1,type:3,format:"color"},Wp=function(e,t){var i=Fp(e,t[0]),r=t[1];return r&&yp(r)?{color:i,stop:r}:{color:i,stop:null}},Kp=function(e,t){var i=e[0],r=e[e.length-1];null===i.stop&&(i.stop=wp),null===r.stop&&(r.stop=Bp);for(var n=[],s=0,o=0;o<e.length;o++){var a=e[o].stop;if(null!==a){var l=Cp(a,t);l>s?n.push(l):n.push(s),s=l}else n.push(null)}var u=null;for(o=0;o<n.length;o++){var c=n[o];if(null===c)null===u&&(u=o);else if(null!==u){for(var h=o-u,A=(c-n[u-1])/(h+1),d=1;d<=h;d++)n[u+d-1]=A*d;u=null}}return e.map(function(e,i){return{color:e.color,stop:Math.max(Math.min(1,n[i]/t),0)}})},Xp=function(e,t,i){var r="number"==typeof e?e:function(e,t,i){var r=t/2,n=i/2,s=Cp(e[0],t)-r,o=n-Cp(e[1],i);return(Math.atan2(o,s)+2*Math.PI)%(2*Math.PI)}(e,t,i),n=Math.abs(t*Math.sin(r))+Math.abs(i*Math.cos(r)),s=t/2,o=i/2,a=n/2,l=Math.sin(r-Math.PI/2)*a,u=Math.cos(r-Math.PI/2)*a;return[n,s-u,s+u,o-l,o+l]},qp=function(e,t){return Math.sqrt(e*e+t*t)},Yp=function(e,t,i,r,n){return[[0,0],[0,t],[e,0],[e,t]].reduce(function(e,t){var s=t[0],o=t[1],a=qp(i-s,r-o);return(n?a<e.optimumDistance:a>e.optimumDistance)?{optimumCorner:t,optimumDistance:a}:e},{optimumDistance:n?1/0:-1/0,optimumCorner:null}).optimumCorner},Jp=function(e,t){var i=Ip(180),r=[];return mp(t).forEach(function(t,n){if(0===n){var s=t[0];if(20===s.type&&-1!==["top","left","right","bottom"].indexOf(s.value))return void(i=Tp(t));if(Sp(s))return void(i=(Ep(e,s)+Ip(270))%Ip(360))}var o=Wp(e,t);r.push(o)}),{angle:i,stops:r,type:1}},Zp="closest-side",$p="farthest-side",ef="closest-corner",tf="farthest-corner",rf="circle",nf="ellipse",sf="cover",of="contain",af=function(e,t){var i=0,r=3,n=[],s=[];return mp(t).forEach(function(t,o){var a=!0;if(0===o?a=t.reduce(function(e,t){if(Ap(t))switch(t.value){case"center":return s.push(xp),!1;case"top":case"left":return s.push(wp),!1;case"right":case"bottom":return s.push(Bp),!1}else if(yp(t)||_p(t))return s.push(t),!1;return e},a):1===o&&(a=t.reduce(function(e,t){if(Ap(t))switch(t.value){case rf:return i=0,!1;case nf:return i=1,!1;case of:case Zp:return r=0,!1;case $p:return r=1,!1;case ef:return r=2,!1;case sf:case tf:return r=3,!1}else if(_p(t)||yp(t))return Array.isArray(r)||(r=[]),r.push(t),!1;return e},a)),a){var l=Wp(e,t);n.push(l)}}),{size:r,shape:i,stops:n,position:s,type:2}},lf=function(e,t){if(22===t.type){var i={url:t.value,type:0};return e.cache.addImage(t.value),i}if(18===t.type){var r=cf[t.name];if(void 0===r)throw new Error('Attempting to parse an unsupported image function "'+t.name+'"');return r(e,t.values)}throw new Error("Unsupported image type "+t.type)};var uf,cf={"linear-gradient":function(e,t){var i=Ip(180),r=[];return mp(t).forEach(function(t,n){if(0===n){var s=t[0];if(20===s.type&&"to"===s.value)return void(i=Tp(t));if(Sp(s))return void(i=Ep(e,s))}var o=Wp(e,t);r.push(o)}),{angle:i,stops:r,type:1}},"-moz-linear-gradient":Jp,"-ms-linear-gradient":Jp,"-o-linear-gradient":Jp,"-webkit-linear-gradient":Jp,"radial-gradient":function(e,t){var i=0,r=3,n=[],s=[];return mp(t).forEach(function(t,o){var a=!0;if(0===o){var l=!1;a=t.reduce(function(e,t){if(l)if(Ap(t))switch(t.value){case"center":return s.push(xp),e;case"top":case"left":return s.push(wp),e;case"right":case"bottom":return s.push(Bp),e}else(yp(t)||_p(t))&&s.push(t);else if(Ap(t))switch(t.value){case rf:return i=0,!1;case nf:return i=1,!1;case"at":return l=!0,!1;case Zp:return r=0,!1;case sf:case $p:return r=1,!1;case of:case ef:return r=2,!1;case tf:return r=3,!1}else if(_p(t)||yp(t))return Array.isArray(r)||(r=[]),r.push(t),!1;return e},a)}if(a){var u=Wp(e,t);n.push(u)}}),{size:r,shape:i,stops:n,position:s,type:2}},"-moz-radial-gradient":af,"-ms-radial-gradient":af,"-o-radial-gradient":af,"-webkit-radial-gradient":af,"-webkit-gradient":function(e,t){var i=Ip(180),r=[],n=1;return mp(t).forEach(function(t,i){var s=t[0];if(0===i){if(Ap(s)&&"linear"===s.value)return void(n=1);if(Ap(s)&&"radial"===s.value)return void(n=2)}if(18===s.type)if("from"===s.name){var o=Fp(e,s.values[0]);r.push({stop:wp,color:o})}else if("to"===s.name){o=Fp(e,s.values[0]);r.push({stop:Bp,color:o})}else if("color-stop"===s.name){var a=s.values.filter(gp);if(2===a.length){o=Fp(e,a[1]);var l=a[0];hp(l)&&r.push({stop:{type:16,number:100*l.number,flags:l.flags},color:o})}}}),1===n?{angle:(i+Ip(180))%Ip(360),stops:r,type:n}:{size:3,shape:0,stops:r,position:[],type:n}}},hf={name:"background-image",initialValue:"none",type:1,prefix:!1,parse:function(e,t){if(0===t.length)return[];var i=t[0];return 20===i.type&&"none"===i.value?[]:t.filter(function(e){return gp(e)&&function(e){return!(20===e.type&&"none"===e.value||18===e.type&&!cf[e.name])}(e)}).map(function(t){return lf(e,t)})}},Af={name:"background-origin",initialValue:"border-box",prefix:!1,type:1,parse:function(e,t){return t.map(function(e){if(Ap(e))switch(e.value){case"padding-box":return 1;case"content-box":return 2}return 0})}},df={name:"background-position",initialValue:"0% 0%",type:1,prefix:!1,parse:function(e,t){return mp(t).map(function(e){return e.filter(yp)}).map(bp)}},pf={name:"background-repeat",initialValue:"repeat",prefix:!1,type:1,parse:function(e,t){return mp(t).map(function(e){return e.filter(Ap).map(function(e){return e.value}).join(" ")}).map(ff)}},ff=function(e){switch(e){case"no-repeat":return 1;case"repeat-x":case"repeat no-repeat":return 2;case"repeat-y":case"no-repeat repeat":return 3;default:return 0}};!function(e){e.AUTO="auto",e.CONTAIN="contain",e.COVER="cover"}(uf||(uf={}));var gf,mf={name:"background-size",initialValue:"0",prefix:!1,type:1,parse:function(e,t){return mp(t).map(function(e){return e.filter(vf)})}},vf=function(e){return Ap(e)||yp(e)},_f=function(e){return{name:"border-"+e+"-color",initialValue:"transparent",prefix:!1,type:3,format:"color"}},yf=_f("top"),bf=_f("right"),wf=_f("bottom"),xf=_f("left"),Bf=function(e){return{name:"border-radius-"+e,initialValue:"0 0",prefix:!1,type:1,parse:function(e,t){return bp(t.filter(yp))}}},Pf=Bf("top-left"),Cf=Bf("top-right"),Mf=Bf("bottom-right"),kf=Bf("bottom-left"),Ef=function(e){return{name:"border-"+e+"-style",initialValue:"solid",prefix:!1,type:2,parse:function(e,t){switch(t){case"none":return 0;case"dashed":return 2;case"dotted":return 3;case"double":return 4}return 1}}},Sf=Ef("top"),Tf=Ef("right"),If=Ef("bottom"),Ff=Ef("left"),Df=function(e){return{name:"border-"+e+"-width",initialValue:"0",type:0,prefix:!1,parse:function(e,t){return cp(t)?t.number:0}}},Rf=Df("top"),Of=Df("right"),Lf=Df("bottom"),jf=Df("left"),Uf={name:"color",initialValue:"transparent",prefix:!1,type:3,format:"color"},Nf={name:"direction",initialValue:"ltr",prefix:!1,type:2,parse:function(e,t){return"rtl"===t?1:0}},Vf={name:"display",initialValue:"inline-block",prefix:!1,type:1,parse:function(e,t){return t.filter(Ap).reduce(function(e,t){return e|Qf(t.value)},0)}},Qf=function(e){switch(e){case"block":case"-webkit-box":return 2;case"inline":return 4;case"run-in":return 8;case"flow":return 16;case"flow-root":return 32;case"table":return 64;case"flex":case"-webkit-flex":return 128;case"grid":case"-ms-grid":return 256;case"ruby":return 512;case"subgrid":return 1024;case"list-item":return 2048;case"table-row-group":return 4096;case"table-header-group":return 8192;case"table-footer-group":return 16384;case"table-row":return 32768;case"table-cell":return 65536;case"table-column-group":return 131072;case"table-column":return 262144;case"table-caption":return 524288;case"ruby-base":return 1048576;case"ruby-text":return 2097152;case"ruby-base-container":return 4194304;case"ruby-text-container":return 8388608;case"contents":return 16777216;case"inline-block":return 33554432;case"inline-list-item":return 67108864;case"inline-table":return 134217728;case"inline-flex":return 268435456;case"inline-grid":return 536870912}return 0},Hf={name:"float",initialValue:"none",prefix:!1,type:2,parse:function(e,t){switch(t){case"left":return 1;case"right":return 2;case"inline-start":return 3;case"inline-end":return 4}return 0}},Gf={name:"letter-spacing",initialValue:"0",prefix:!1,type:0,parse:function(e,t){return 20===t.type&&"normal"===t.value?0:17===t.type||15===t.type?t.number:0}};!function(e){e.NORMAL="normal",e.STRICT="strict"}(gf||(gf={}));var zf,Wf={name:"line-break",initialValue:"normal",prefix:!1,type:2,parse:function(e,t){return"strict"===t?gf.STRICT:gf.NORMAL}},Kf={name:"line-height",initialValue:"normal",prefix:!1,type:4},Xf=function(e,t){return Ap(e)&&"normal"===e.value?1.2*t:17===e.type?t*e.number:yp(e)?Cp(e,t):t},qf={name:"list-style-image",initialValue:"none",type:0,prefix:!1,parse:function(e,t){return 20===t.type&&"none"===t.value?null:lf(e,t)}},Yf={name:"list-style-position",initialValue:"outside",prefix:!1,type:2,parse:function(e,t){return"inside"===t?0:1}},Jf={name:"list-style-type",initialValue:"none",prefix:!1,type:2,parse:function(e,t){switch(t){case"disc":return 0;case"circle":return 1;case"square":return 2;case"decimal":return 3;case"cjk-decimal":return 4;case"decimal-leading-zero":return 5;case"lower-roman":return 6;case"upper-roman":return 7;case"lower-greek":return 8;case"lower-alpha":return 9;case"upper-alpha":return 10;case"arabic-indic":return 11;case"armenian":return 12;case"bengali":return 13;case"cambodian":return 14;case"cjk-earthly-branch":return 15;case"cjk-heavenly-stem":return 16;case"cjk-ideographic":return 17;case"devanagari":return 18;case"ethiopic-numeric":return 19;case"georgian":return 20;case"gujarati":return 21;case"gurmukhi":case"hebrew":return 22;case"hiragana":return 23;case"hiragana-iroha":return 24;case"japanese-formal":return 25;case"japanese-informal":return 26;case"kannada":return 27;case"katakana":return 28;case"katakana-iroha":return 29;case"khmer":return 30;case"korean-hangul-formal":return 31;case"korean-hanja-formal":return 32;case"korean-hanja-informal":return 33;case"lao":return 34;case"lower-armenian":return 35;case"malayalam":return 36;case"mongolian":return 37;case"myanmar":return 38;case"oriya":return 39;case"persian":return 40;case"simp-chinese-formal":return 41;case"simp-chinese-informal":return 42;case"tamil":return 43;case"telugu":return 44;case"thai":return 45;case"tibetan":return 46;case"trad-chinese-formal":return 47;case"trad-chinese-informal":return 48;case"upper-armenian":return 49;case"disclosure-open":return 50;case"disclosure-closed":return 51;default:return-1}}},Zf=function(e){return{name:"margin-"+e,initialValue:"0",prefix:!1,type:4}},$f=Zf("top"),eg=Zf("right"),tg=Zf("bottom"),ig=Zf("left"),rg={name:"overflow",initialValue:"visible",prefix:!1,type:1,parse:function(e,t){return t.filter(Ap).map(function(e){switch(e.value){case"hidden":return 1;case"scroll":return 2;case"clip":return 3;case"auto":return 4;default:return 0}})}},ng={name:"overflow-wrap",initialValue:"normal",prefix:!1,type:2,parse:function(e,t){return"break-word"===t?"break-word":"normal"}},sg=function(e){return{name:"padding-"+e,initialValue:"0",prefix:!1,type:3,format:"length-percentage"}},og=sg("top"),ag=sg("right"),lg=sg("bottom"),ug=sg("left"),cg={name:"text-align",initialValue:"left",prefix:!1,type:2,parse:function(e,t){switch(t){case"right":return 2;case"center":case"justify":return 1;default:return 0}}},hg={name:"position",initialValue:"static",prefix:!1,type:2,parse:function(e,t){switch(t){case"relative":return 1;case"absolute":return 2;case"fixed":return 3;case"sticky":return 4}return 0}},Ag={name:"text-shadow",initialValue:"none",type:1,prefix:!1,parse:function(e,t){return 1===t.length&&pp(t[0],"none")?[]:mp(t).map(function(t){for(var i={color:Hp.TRANSPARENT,offsetX:wp,offsetY:wp,blur:wp},r=0,n=0;n<t.length;n++){var s=t[n];_p(s)?(0===r?i.offsetX=s:1===r?i.offsetY=s:i.blur=s,r++):i.color=Fp(e,s)}return i})}},dg={name:"text-transform",initialValue:"none",prefix:!1,type:2,parse:function(e,t){switch(t){case"uppercase":return 2;case"lowercase":return 1;case"capitalize":return 3}return 0}},pg={name:"transform",initialValue:"none",prefix:!0,type:0,parse:function(e,t){if(20===t.type&&"none"===t.value)return null;if(18===t.type){var i=fg[t.name];if(void 0===i)throw new Error('Attempting to parse an unsupported transform function "'+t.name+'"');return i(t.values)}return null}},fg={matrix:function(e){var t=e.filter(function(e){return 17===e.type}).map(function(e){return e.number});return 6===t.length?t:null},matrix3d:function(e){var t=e.filter(function(e){return 17===e.type}).map(function(e){return e.number}),i=t[0],r=t[1];t[2],t[3];var n=t[4],s=t[5];t[6],t[7],t[8],t[9],t[10],t[11];var o=t[12],a=t[13];return t[14],t[15],16===t.length?[i,r,n,s,o,a]:null}},gg={type:16,number:50,flags:4},mg=[gg,gg],vg={name:"transform-origin",initialValue:"50% 50%",prefix:!0,type:1,parse:function(e,t){var i=t.filter(yp);return 2!==i.length?mg:[i[0],i[1]]}},_g={name:"visible",initialValue:"none",prefix:!1,type:2,parse:function(e,t){switch(t){case"hidden":return 1;case"collapse":return 2;default:return 0}}};!function(e){e.NORMAL="normal",e.BREAK_ALL="break-all",e.KEEP_ALL="keep-all"}(zf||(zf={}));for(var yg={name:"word-break",initialValue:"normal",prefix:!1,type:2,parse:function(e,t){switch(t){case"break-all":return zf.BREAK_ALL;case"keep-all":return zf.KEEP_ALL;default:return zf.NORMAL}}},bg={name:"z-index",initialValue:"auto",prefix:!1,type:0,parse:function(e,t){if(20===t.type)return{auto:!0,order:0};if(hp(t))return{auto:!1,order:t.number};throw new Error("Invalid z-index number parsed")}},wg=function(e,t){if(15===t.type)switch(t.unit.toLowerCase()){case"s":return 1e3*t.number;case"ms":return t.number}throw new Error("Unsupported time type")},xg={name:"opacity",initialValue:"1",type:0,prefix:!1,parse:function(e,t){return hp(t)?t.number:1}},Bg={name:"text-decoration-color",initialValue:"transparent",prefix:!1,type:3,format:"color"},Pg={name:"text-decoration-line",initialValue:"none",prefix:!1,type:1,parse:function(e,t){return t.filter(Ap).map(function(e){switch(e.value){case"underline":return 1;case"overline":return 2;case"line-through":return 3;case"none":return 4}return 0}).filter(function(e){return 0!==e})}},Cg={name:"font-family",initialValue:"",prefix:!1,type:1,parse:function(e,t){var i=[],r=[];return t.forEach(function(e){switch(e.type){case 20:case 0:i.push(e.value);break;case 17:i.push(e.number.toString());break;case 4:r.push(i.join(" ")),i.length=0}}),i.length&&r.push(i.join(" ")),r.map(function(e){return-1===e.indexOf(" ")?e:"'"+e+"'"})}},Mg={name:"font-size",initialValue:"0",prefix:!1,type:3,format:"length"},kg={name:"font-weight",initialValue:"normal",type:0,prefix:!1,parse:function(e,t){return hp(t)?t.number:Ap(t)&&"bold"===t.value?700:400}},Eg={name:"font-variant",initialValue:"none",type:1,prefix:!1,parse:function(e,t){return t.filter(Ap).map(function(e){return e.value})}},Sg={name:"font-style",initialValue:"normal",prefix:!1,type:2,parse:function(e,t){switch(t){case"oblique":return"oblique";case"italic":return"italic";default:return"normal"}}},Tg=function(e,t){return 0!==(e&t)},Ig={name:"content",initialValue:"none",type:1,prefix:!1,parse:function(e,t){if(0===t.length)return[];var i=t[0];return 20===i.type&&"none"===i.value?[]:t}},Fg={name:"counter-increment",initialValue:"none",prefix:!0,type:1,parse:function(e,t){if(0===t.length)return null;var i=t[0];if(20===i.type&&"none"===i.value)return null;for(var r=[],n=t.filter(fp),s=0;s<n.length;s++){var o=n[s],a=n[s+1];if(20===o.type){var l=a&&hp(a)?a.number:1;r.push({counter:o.value,increment:l})}}return r}},Dg={name:"counter-reset",initialValue:"none",prefix:!0,type:1,parse:function(e,t){if(0===t.length)return[];for(var i=[],r=t.filter(fp),n=0;n<r.length;n++){var s=r[n],o=r[n+1];if(Ap(s)&&"none"!==s.value){var a=o&&hp(o)?o.number:0;i.push({counter:s.value,reset:a})}}return i}},Rg={name:"duration",initialValue:"0s",prefix:!1,type:1,parse:function(e,t){return t.filter(cp).map(function(t){return wg(e,t)})}},Og={name:"quotes",initialValue:"none",prefix:!0,type:1,parse:function(e,t){if(0===t.length)return null;var i=t[0];if(20===i.type&&"none"===i.value)return null;var r=[],n=t.filter(dp);if(n.length%2!=0)return null;for(var s=0;s<n.length;s+=2){var o=n[s].value,a=n[s+1].value;r.push({open:o,close:a})}return r}},Lg=function(e,t,i){if(!e)return"";var r=e[Math.min(t,e.length-1)];return r?i?r.open:r.close:""},jg={name:"box-shadow",initialValue:"none",type:1,prefix:!1,parse:function(e,t){return 1===t.length&&pp(t[0],"none")?[]:mp(t).map(function(t){for(var i={color:255,offsetX:wp,offsetY:wp,blur:wp,spread:wp,inset:!1},r=0,n=0;n<t.length;n++){var s=t[n];pp(s,"inset")?i.inset=!0:_p(s)?(0===r?i.offsetX=s:1===r?i.offsetY=s:2===r?i.blur=s:i.spread=s,r++):i.color=Fp(e,s)}return i})}},Ug={name:"paint-order",initialValue:"normal",prefix:!1,type:1,parse:function(e,t){var i=[];return t.filter(Ap).forEach(function(e){switch(e.value){case"stroke":i.push(1);break;case"fill":i.push(0);break;case"markers":i.push(2)}}),[0,1,2].forEach(function(e){-1===i.indexOf(e)&&i.push(e)}),i}},Ng={name:"-webkit-text-stroke-color",initialValue:"currentcolor",prefix:!1,type:3,format:"color"},Vg={name:"-webkit-text-stroke-width",initialValue:"0",type:0,prefix:!1,parse:function(e,t){return cp(t)?t.number:0}},Qg=function(){function e(e,t){var i,r;this.animationDuration=zg(e,Rg,t.animationDuration),this.backgroundClip=zg(e,Gp,t.backgroundClip),this.backgroundColor=zg(e,zp,t.backgroundColor),this.backgroundImage=zg(e,hf,t.backgroundImage),this.backgroundOrigin=zg(e,Af,t.backgroundOrigin),this.backgroundPosition=zg(e,df,t.backgroundPosition),this.backgroundRepeat=zg(e,pf,t.backgroundRepeat),this.backgroundSize=zg(e,mf,t.backgroundSize),this.borderTopColor=zg(e,yf,t.borderTopColor),this.borderRightColor=zg(e,bf,t.borderRightColor),this.borderBottomColor=zg(e,wf,t.borderBottomColor),this.borderLeftColor=zg(e,xf,t.borderLeftColor),this.borderTopLeftRadius=zg(e,Pf,t.borderTopLeftRadius),this.borderTopRightRadius=zg(e,Cf,t.borderTopRightRadius),this.borderBottomRightRadius=zg(e,Mf,t.borderBottomRightRadius),this.borderBottomLeftRadius=zg(e,kf,t.borderBottomLeftRadius),this.borderTopStyle=zg(e,Sf,t.borderTopStyle),this.borderRightStyle=zg(e,Tf,t.borderRightStyle),this.borderBottomStyle=zg(e,If,t.borderBottomStyle),this.borderLeftStyle=zg(e,Ff,t.borderLeftStyle),this.borderTopWidth=zg(e,Rf,t.borderTopWidth),this.borderRightWidth=zg(e,Of,t.borderRightWidth),this.borderBottomWidth=zg(e,Lf,t.borderBottomWidth),this.borderLeftWidth=zg(e,jf,t.borderLeftWidth),this.boxShadow=zg(e,jg,t.boxShadow),this.color=zg(e,Uf,t.color),this.direction=zg(e,Nf,t.direction),this.display=zg(e,Vf,t.display),this.float=zg(e,Hf,t.cssFloat),this.fontFamily=zg(e,Cg,t.fontFamily),this.fontSize=zg(e,Mg,t.fontSize),this.fontStyle=zg(e,Sg,t.fontStyle),this.fontVariant=zg(e,Eg,t.fontVariant),this.fontWeight=zg(e,kg,t.fontWeight),this.letterSpacing=zg(e,Gf,t.letterSpacing),this.lineBreak=zg(e,Wf,t.lineBreak),this.lineHeight=zg(e,Kf,t.lineHeight),this.listStyleImage=zg(e,qf,t.listStyleImage),this.listStylePosition=zg(e,Yf,t.listStylePosition),this.listStyleType=zg(e,Jf,t.listStyleType),this.marginTop=zg(e,$f,t.marginTop),this.marginRight=zg(e,eg,t.marginRight),this.marginBottom=zg(e,tg,t.marginBottom),this.marginLeft=zg(e,ig,t.marginLeft),this.opacity=zg(e,xg,t.opacity);var n=zg(e,rg,t.overflow);this.overflowX=n[0],this.overflowY=n[n.length>1?1:0],this.overflowWrap=zg(e,ng,t.overflowWrap),this.paddingTop=zg(e,og,t.paddingTop),this.paddingRight=zg(e,ag,t.paddingRight),this.paddingBottom=zg(e,lg,t.paddingBottom),this.paddingLeft=zg(e,ug,t.paddingLeft),this.paintOrder=zg(e,Ug,t.paintOrder),this.position=zg(e,hg,t.position),this.textAlign=zg(e,cg,t.textAlign),this.textDecorationColor=zg(e,Bg,null!==(i=t.textDecorationColor)&&void 0!==i?i:t.color),this.textDecorationLine=zg(e,Pg,null!==(r=t.textDecorationLine)&&void 0!==r?r:t.textDecoration),this.textShadow=zg(e,Ag,t.textShadow),this.textTransform=zg(e,dg,t.textTransform),this.transform=zg(e,pg,t.transform),this.transformOrigin=zg(e,vg,t.transformOrigin),this.visibility=zg(e,_g,t.visibility),this.webkitTextStrokeColor=zg(e,Ng,t.webkitTextStrokeColor),this.webkitTextStrokeWidth=zg(e,Vg,t.webkitTextStrokeWidth),this.wordBreak=zg(e,yg,t.wordBreak),this.zIndex=zg(e,bg,t.zIndex)}return e.prototype.isVisible=function(){return this.display>0&&this.opacity>0&&0===this.visibility},e.prototype.isTransparent=function(){return Dp(this.backgroundColor)},e.prototype.isTransformed=function(){return null!==this.transform},e.prototype.isPositioned=function(){return 0!==this.position},e.prototype.isPositionedWithZIndex=function(){return this.isPositioned()&&!this.zIndex.auto},e.prototype.isFloating=function(){return 0!==this.float},e.prototype.isInlineLevel=function(){return Tg(this.display,4)||Tg(this.display,33554432)||Tg(this.display,268435456)||Tg(this.display,536870912)||Tg(this.display,67108864)||Tg(this.display,134217728)},e}(),Hg=function(e,t){this.content=zg(e,Ig,t.content),this.quotes=zg(e,Og,t.quotes)},Gg=function(e,t){this.counterIncrement=zg(e,Fg,t.counterIncrement),this.counterReset=zg(e,Dg,t.counterReset)},zg=function(e,t,i){var r=new lp,n=null!=i?i.toString():t.initialValue;r.write(n);var s=new up(r.read());switch(t.type){case 2:var o=s.parseComponentValue();return t.parse(e,Ap(o)?o.value:t.initialValue);case 0:return t.parse(e,s.parseComponentValue());case 1:return t.parse(e,s.parseComponentValues());case 4:return s.parseComponentValue();case 3:switch(t.format){case"angle":return Ep(e,s.parseComponentValue());case"color":return Fp(e,s.parseComponentValue());case"image":return lf(e,s.parseComponentValue());case"length":var a=s.parseComponentValue();return _p(a)?a:wp;case"length-percentage":var l=s.parseComponentValue();return yp(l)?l:wp;case"time":return wg(e,s.parseComponentValue())}}},Wg=function(e,t){var i=function(e){switch(e.getAttribute("data-html2canvas-debug")){case"all":return 1;case"clone":return 2;case"parse":return 3;case"render":return 4;default:return 0}}(e);return 1===i||t===i},Kg=function(e,t){this.context=e,this.textNodes=[],this.elements=[],this.flags=0,Wg(t,3),this.styles=new Qg(e,window.getComputedStyle(t,null)),Jm(t)&&(this.styles.animationDuration.some(function(e){return e>0})&&(t.style.animationDuration="0s"),null!==this.styles.transform&&(t.style.transform="none")),this.bounds=kA(this.context,t),Wg(t,4)&&(this.flags|=16)},Xg="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",qg="undefined"==typeof Uint8Array?[]:new Uint8Array(256),Yg=0;Yg<64;Yg++)qg[Xg.charCodeAt(Yg)]=Yg;for(var Jg=function(e,t,i){return e.slice?e.slice(t,i):new Uint16Array(Array.prototype.slice.call(e,t,i))},Zg=function(){function e(e,t,i,r,n,s){this.initialValue=e,this.errorValue=t,this.highStart=i,this.highValueIndex=r,this.index=n,this.data=s}return e.prototype.get=function(e){var t;if(e>=0){if(e<55296||e>56319&&e<=65535)return t=((t=this.index[e>>5])<<2)+(31&e),this.data[t];if(e<=65535)return t=((t=this.index[2048+(e-55296>>5)])<<2)+(31&e),this.data[t];if(e<this.highStart)return t=2080+(e>>11),t=this.index[t],t+=e>>5&63,t=((t=this.index[t])<<2)+(31&e),this.data[t];if(e<=1114111)return this.data[this.highValueIndex]}return this.errorValue},e}(),$g="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",em="undefined"==typeof Uint8Array?[]:new Uint8Array(256),tm=0;tm<64;tm++)em[$g.charCodeAt(tm)]=tm;var im,rm=8,nm=9,sm=11,om=12,am=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];if(String.fromCodePoint)return String.fromCodePoint.apply(String,e);var i=e.length;if(!i)return"";for(var r=[],n=-1,s="";++n<i;){var o=e[n];o<=65535?r.push(o):(o-=65536,r.push(55296+(o>>10),o%1024+56320)),(n+1===i||r.length>16384)&&(s+=String.fromCharCode.apply(String,r),r.length=0)}return s},lm=function(e){var t,i,r,n=function(e){var t,i,r,n,s,o=.75*e.length,a=e.length,l=0;"="===e[e.length-1]&&(o--,"="===e[e.length-2]&&o--);var u="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof Uint8Array&&void 0!==Uint8Array.prototype.slice?new ArrayBuffer(o):new Array(o),c=Array.isArray(u)?u:new Uint8Array(u);for(t=0;t<a;t+=4)i=qg[e.charCodeAt(t)],r=qg[e.charCodeAt(t+1)],n=qg[e.charCodeAt(t+2)],s=qg[e.charCodeAt(t+3)],c[l++]=i<<2|r>>4,c[l++]=(15&r)<<4|n>>2,c[l++]=(3&n)<<6|63&s;return u}(e),s=Array.isArray(n)?function(e){for(var t=e.length,i=[],r=0;r<t;r+=4)i.push(e[r+3]<<24|e[r+2]<<16|e[r+1]<<8|e[r]);return i}(n):new Uint32Array(n),o=Array.isArray(n)?function(e){for(var t=e.length,i=[],r=0;r<t;r+=2)i.push(e[r+1]<<8|e[r]);return i}(n):new Uint16Array(n),a=Jg(o,12,s[4]/2),l=2===s[5]?Jg(o,(24+s[4])/2):(t=s,i=Math.ceil((24+s[4])/4),t.slice?t.slice(i,r):new Uint32Array(Array.prototype.slice.call(t,i,r)));return new Zg(s[0],s[1],s[2],s[3],a,l)}("AAAAAAAAAAAAEA4AGBkAAFAaAAACAAAAAAAIABAAGAAwADgACAAQAAgAEAAIABAACAAQAAgAEAAIABAACAAQAAgAEAAIABAAQABIAEQATAAIABAACAAQAAgAEAAIABAAVABcAAgAEAAIABAACAAQAGAAaABwAHgAgACIAI4AlgAIABAAmwCjAKgAsAC2AL4AvQDFAMoA0gBPAVYBWgEIAAgACACMANoAYgFkAWwBdAF8AX0BhQGNAZUBlgGeAaMBlQGWAasBswF8AbsBwwF0AcsBYwHTAQgA2wG/AOMBdAF8AekB8QF0AfkB+wHiAHQBfAEIAAMC5gQIAAsCEgIIAAgAFgIeAggAIgIpAggAMQI5AkACygEIAAgASAJQAlgCYAIIAAgACAAKBQoFCgUTBRMFGQUrBSsFCAAIAAgACAAIAAgACAAIAAgACABdAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABoAmgCrwGvAQgAbgJ2AggAHgEIAAgACADnAXsCCAAIAAgAgwIIAAgACAAIAAgACACKAggAkQKZAggAPADJAAgAoQKkAqwCsgK6AsICCADJAggA0AIIAAgACAAIANYC3gIIAAgACAAIAAgACABAAOYCCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAkASoB+QIEAAgACAA8AEMCCABCBQgACABJBVAFCAAIAAgACAAIAAgACAAIAAgACABTBVoFCAAIAFoFCABfBWUFCAAIAAgACAAIAAgAbQUIAAgACAAIAAgACABzBXsFfQWFBYoFigWKBZEFigWKBYoFmAWfBaYFrgWxBbkFCAAIAAgACAAIAAgACAAIAAgACAAIAMEFCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAMgFCADQBQgACAAIAAgACAAIAAgACAAIAAgACAAIAO4CCAAIAAgAiQAIAAgACABAAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAD0AggACAD8AggACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIANYFCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAMDvwAIAAgAJAIIAAgACAAIAAgACAAIAAgACwMTAwgACAB9BOsEGwMjAwgAKwMyAwsFYgE3A/MEPwMIAEUDTQNRAwgAWQOsAGEDCAAIAAgACAAIAAgACABpAzQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2B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AAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABtAwgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABMAEwACAAIAAgACAAIABgACAAIAAgACAC/AAgACAAyAQgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACACAAIAAwAAgACAAIAAgACAAIAAgACAAIAAAARABIAAgACAAIABQASAAIAAgAIABwAEAAjgCIABsAqAC2AL0AigDQAtwC+IJIQqVAZUBWQqVAZUBlQGVAZUBlQGrC5UBlQGVAZUBlQGVAZUBlQGVAXsKlQGVAbAK6wsrDGUMpQzlDJUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBl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gACAAIAAgACAAIAAgACAAIAAgACAA4BAgACABABEYECAAIAAgATAQYAQgAVAQIAAgACAAIAAgACAAIAAgACAAIAFoECAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAOQEIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAB+BAcACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAEABhgSMBAgACAAIAAgAlAQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAwAEAAQABAADAAMAAwADAAQABAAEAAQABAAEAAQABHATAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAdQMIAAgACAAIAAgACAAIAMkACAAIAAgAfQMIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACACFA4kDCAAIAAgACAAIAOcBCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAIcDCAAIAAgACAAIAAgACAAIAAgACAAIAJEDCAAIAAgACADFAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABgBAgAZgQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAbAQCBXIECAAIAHkECAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABAAJwEQACjBKoEsgQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAC6BMIECAAIAAgACAAIAAgACABmBAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAxwQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAGYECAAIAAgAzgQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAigWKBYoFigWKBYoFigWKBd0FXwUIAOIF6gXxBYoF3gT5BQAGCAaKBYoFigWKBYoFigWKBYoFigWKBYoFigXWBIoFigWKBYoFigWKBYoFigWKBYsFEAaKBYoFigWKBYoFigWKBRQGCACKBYoFigWKBQgACAAIANEECAAIABgGigUgBggAJgYIAC4GMwaKBYoF0wQ3Bj4GigWKBYoFigWKBYoFigWKBYoFigWKBYoFigUIAAgACAAIAAgACAAIAAgAigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWLBf///////wQABAAEAAQABAAEAAQABAAEAAQAAwAEAAQAAgAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA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4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4AAAAAAA4ADgAOAA4ADgAOAA4ADgAOAAAADgAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4AAAAAAAAAAAAAAAAADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAA4ADgAOAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAA4ADgAOAA4AAAAAAAAAAAAAAAAAAAAAAA4ADgAOAA4ADgAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4AAAAOAA4ADgAOAA4ADgAAAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4AAAAAAAAAAAA="),um="×",cm=function(e){return lm.get(e)},hm=function(e,t,i){var r=i-2,n=t[r],s=t[i-1],o=t[i];if(2===s&&3===o)return um;if(2===s||3===s||4===s)return"÷";if(2===o||3===o||4===o)return"÷";if(s===rm&&-1!==[rm,nm,sm,om].indexOf(o))return um;if(!(s!==sm&&s!==nm||o!==nm&&10!==o))return um;if((s===om||10===s)&&10===o)return um;if(13===o||5===o)return um;if(7===o)return um;if(1===s)return um;if(13===s&&14===o){for(;5===n;)n=t[--r];if(14===n)return um}if(15===s&&15===o){for(var a=0;15===n;)a++,n=t[--r];if(a%2==0)return um}return"÷"},Am=function(e){var t=function(e){for(var t=[],i=0,r=e.length;i<r;){var n=e.charCodeAt(i++);if(n>=55296&&n<=56319&&i<r){var s=e.charCodeAt(i++);56320==(64512&s)?t.push(((1023&n)<<10)+(1023&s)+65536):(t.push(n),i--)}else t.push(n)}return t}(e),i=t.length,r=0,n=0,s=t.map(cm);return{next:function(){if(r>=i)return{done:!0,value:null};for(var e=um;r<i&&(e=hm(0,s,++r))===um;);if(e!==um||r===i){var o=am.apply(null,t.slice(n,r));return n=r,{value:o,done:!1}}return{done:!0,value:null}}}},dm=function(e){return 0===e[0]&&255===e[1]&&0===e[2]&&255===e[3]},pm=function(e,t,i,r,n){var s="http://www.w3.org/2000/svg",o=document.createElementNS(s,"svg"),a=document.createElementNS(s,"foreignObject");return o.setAttributeNS(null,"width",e.toString()),o.setAttributeNS(null,"height",t.toString()),a.setAttributeNS(null,"width","100%"),a.setAttributeNS(null,"height","100%"),a.setAttributeNS(null,"x",i.toString()),a.setAttributeNS(null,"y",r.toString()),a.setAttributeNS(null,"externalResourcesRequired","true"),o.appendChild(a),a.appendChild(n),o},fm=function(e){return new Promise(function(t,i){var r=new Image;r.onload=function(){return t(r)},r.onerror=i,r.src="data:image/svg+xml;charset=utf-8,"+encodeURIComponent((new XMLSerializer).serializeToString(e))})},gm={get SUPPORT_RANGE_BOUNDS(){var e=function(e){if(e.createRange){var t=e.createRange();if(t.getBoundingClientRect){var i=e.createElement("boundtest");i.style.height="123px",i.style.display="block",e.body.appendChild(i),t.selectNode(i);var r=t.getBoundingClientRect(),n=Math.round(r.height);if(e.body.removeChild(i),123===n)return!0}}return!1}(document);return Object.defineProperty(gm,"SUPPORT_RANGE_BOUNDS",{value:e}),e},get SUPPORT_WORD_BREAKING(){var e=gm.SUPPORT_RANGE_BOUNDS&&function(e){var t=e.createElement("boundtest");t.style.width="50px",t.style.display="block",t.style.fontSize="12px",t.style.letterSpacing="0px",t.style.wordSpacing="0px",e.body.appendChild(t);var i=e.createRange();t.innerHTML="function"==typeof"".repeat?"👨".repeat(10):"";var r=t.firstChild,n=EA(r.data).map(function(e){return SA(e)}),s=0,o={},a=n.every(function(e,t){i.setStart(r,s),i.setEnd(r,s+e.length);var n=i.getBoundingClientRect();s+=e.length;var a=n.x>o.x||n.y>o.y;return o=n,0===t||a});return e.body.removeChild(t),a}(document);return Object.defineProperty(gm,"SUPPORT_WORD_BREAKING",{value:e}),e},get SUPPORT_SVG_DRAWING(){var e=function(e){var t=new Image,i=e.createElement("canvas"),r=i.getContext("2d");if(!r)return!1;t.src="data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg'></svg>";try{r.drawImage(t,0,0),i.toDataURL()}catch(e){return!1}return!0}(document);return Object.defineProperty(gm,"SUPPORT_SVG_DRAWING",{value:e}),e},get SUPPORT_FOREIGNOBJECT_DRAWING(){var e="function"==typeof Array.from&&"function"==typeof window.fetch?function(e){var t=e.createElement("canvas"),i=100;t.width=i,t.height=i;var r=t.getContext("2d");if(!r)return Promise.reject(!1);r.fillStyle="rgb(0, 255, 0)",r.fillRect(0,0,i,i);var n=new Image,s=t.toDataURL();n.src=s;var o=pm(i,i,0,0,n);return r.fillStyle="red",r.fillRect(0,0,i,i),fm(o).then(function(t){r.drawImage(t,0,0);var n=r.getImageData(0,0,i,i).data;r.fillStyle="red",r.fillRect(0,0,i,i);var o=e.createElement("div");return o.style.backgroundImage="url("+s+")",o.style.height=i+"px",dm(n)?fm(pm(i,i,0,0,o)):Promise.reject(!1)}).then(function(e){return r.drawImage(e,0,0),dm(r.getImageData(0,0,i,i).data)}).catch(function(){return!1})}(document):Promise.resolve(!1);return Object.defineProperty(gm,"SUPPORT_FOREIGNOBJECT_DRAWING",{value:e}),e},get SUPPORT_CORS_IMAGES(){var e=void 0!==(new Image).crossOrigin;return Object.defineProperty(gm,"SUPPORT_CORS_IMAGES",{value:e}),e},get SUPPORT_RESPONSE_TYPE(){var e="string"==typeof(new XMLHttpRequest).responseType;return Object.defineProperty(gm,"SUPPORT_RESPONSE_TYPE",{value:e}),e},get SUPPORT_CORS_XHR(){var e="withCredentials"in new XMLHttpRequest;return Object.defineProperty(gm,"SUPPORT_CORS_XHR",{value:e}),e},get SUPPORT_NATIVE_TEXT_SEGMENTATION(){var e=!("undefined"==typeof Intl||!Intl.Segmenter);return Object.defineProperty(gm,"SUPPORT_NATIVE_TEXT_SEGMENTATION",{value:e}),e}},mm=function(e,t){this.text=e,this.bounds=t},vm=function(e,t){var i=t.ownerDocument;if(i){var r=i.createElement("html2canvaswrapper");r.appendChild(t.cloneNode(!0));var n=t.parentNode;if(n){n.replaceChild(r,t);var s=kA(e,r);return r.firstChild&&n.replaceChild(r.firstChild,r),s}}return MA.EMPTY},_m=function(e,t,i){var r=e.ownerDocument;if(!r)throw new Error("Node has no owner document");var n=r.createRange();return n.setStart(e,t),n.setEnd(e,t+i),n},ym=function(e){if(gm.SUPPORT_NATIVE_TEXT_SEGMENTATION){var t=new Intl.Segmenter(void 0,{granularity:"grapheme"});return Array.from(t.segment(e)).map(function(e){return e.segment})}return function(e){for(var t,i=Am(e),r=[];!(t=i.next()).done;)t.value&&r.push(t.value.slice());return r}(e)},bm=function(e,t){return 0!==t.letterSpacing?ym(e):function(e,t){if(gm.SUPPORT_NATIVE_TEXT_SEGMENTATION){var i=new Intl.Segmenter(void 0,{granularity:"word"});return Array.from(i.segment(e)).map(function(e){return e.segment})}return xm(e,t)}(e,t)},wm=[32,160,4961,65792,65793,4153,4241],xm=function(e,t){for(var i,r=function(e,t){var i=EA(e),r=Cd(i,t),n=r[0],s=r[1],o=r[2],a=i.length,l=0,u=0;return{next:function(){if(u>=a)return{done:!0,value:null};for(var e=dd;u<a&&(e=Pd(i,s,n,++u,o))===dd;);if(e!==dd||u===a){var t=new Md(i,e,l,u);return l=u,{value:t,done:!1}}return{done:!0,value:null}}}}(e,{lineBreak:t.lineBreak,wordBreak:"break-word"===t.overflowWrap?"break-word":t.wordBreak}),n=[],s=function(){if(i.value){var e=i.value.slice(),t=EA(e),r="";t.forEach(function(e){-1===wm.indexOf(e)?r+=SA(e):(r.length&&n.push(r),n.push(SA(e)),r="")}),r.length&&n.push(r)}};!(i=r.next()).done;)s();return n},Bm=function(e,t,i){this.text=Pm(t.data,i.textTransform),this.textBounds=function(e,t,i,r){var n=bm(t,i),s=[],o=0;return n.forEach(function(t){if(i.textDecorationLine.length||t.trim().length>0)if(gm.SUPPORT_RANGE_BOUNDS){var n=_m(r,o,t.length).getClientRects();if(n.length>1){var a=ym(t),l=0;a.forEach(function(t){s.push(new mm(t,MA.fromDOMRectList(e,_m(r,l+o,t.length).getClientRects()))),l+=t.length})}else s.push(new mm(t,MA.fromDOMRectList(e,n)))}else{var u=r.splitText(t.length);s.push(new mm(t,vm(e,r))),r=u}else gm.SUPPORT_RANGE_BOUNDS||(r=r.splitText(t.length));o+=t.length}),s}(e,this.text,i,t)},Pm=function(e,t){switch(t){case 1:return e.toLowerCase();case 3:return e.replace(Cm,Mm);case 2:return e.toUpperCase();default:return e}},Cm=/(^|\s|:|-|\(|\))([a-z])/g,Mm=function(e,t,i){return e.length>0?t+i.toUpperCase():e},km=function(e){function t(t,i){var r=e.call(this,t,i)||this;return r.src=i.currentSrc||i.src,r.intrinsicWidth=i.naturalWidth,r.intrinsicHeight=i.naturalHeight,r.context.cache.addImage(r.src),r}return wA(t,e),t}(Kg),Em=function(e){function t(t,i){var r=e.call(this,t,i)||this;return r.canvas=i,r.intrinsicWidth=i.width,r.intrinsicHeight=i.height,r}return wA(t,e),t}(Kg),Sm=function(e){function t(t,i){var r=e.call(this,t,i)||this,n=new XMLSerializer,s=kA(t,i);return i.setAttribute("width",s.width+"px"),i.setAttribute("height",s.height+"px"),r.svg="data:image/svg+xml,"+encodeURIComponent(n.serializeToString(i)),r.intrinsicWidth=i.width.baseVal.value,r.intrinsicHeight=i.height.baseVal.value,r.context.cache.addImage(r.svg),r}return wA(t,e),t}(Kg),Tm=function(e){function t(t,i){var r=e.call(this,t,i)||this;return r.value=i.value,r}return wA(t,e),t}(Kg),Im=function(e){function t(t,i){var r=e.call(this,t,i)||this;return r.start=i.start,r.reversed="boolean"==typeof i.reversed&&!0===i.reversed,r}return wA(t,e),t}(Kg),Fm=[{type:15,flags:0,unit:"px",number:3}],Dm=[{type:16,flags:0,number:50}],Rm="checkbox",Om="radio",Lm="password",jm=707406591,Um=function(e){function t(t,i){var r,n=e.call(this,t,i)||this;switch(n.type=i.type.toLowerCase(),n.checked=i.checked,n.value=function(e){var t=e.type===Lm?new Array(e.value.length+1).join("•"):e.value;return 0===t.length?e.placeholder||"":t}(i),n.type!==Rm&&n.type!==Om||(n.styles.backgroundColor=3739148031,n.styles.borderTopColor=n.styles.borderRightColor=n.styles.borderBottomColor=n.styles.borderLeftColor=2779096575,n.styles.borderTopWidth=n.styles.borderRightWidth=n.styles.borderBottomWidth=n.styles.borderLeftWidth=1,n.styles.borderTopStyle=n.styles.borderRightStyle=n.styles.borderBottomStyle=n.styles.borderLeftStyle=1,n.styles.backgroundClip=[0],n.styles.backgroundOrigin=[0],n.bounds=(r=n.bounds).width>r.height?new MA(r.left+(r.width-r.height)/2,r.top,r.height,r.height):r.width<r.height?new MA(r.left,r.top+(r.height-r.width)/2,r.width,r.width):r),n.type){case Rm:n.styles.borderTopRightRadius=n.styles.borderTopLeftRadius=n.styles.borderBottomRightRadius=n.styles.borderBottomLeftRadius=Fm;break;case Om:n.styles.borderTopRightRadius=n.styles.borderTopLeftRadius=n.styles.borderBottomRightRadius=n.styles.borderBottomLeftRadius=Dm}return n}return wA(t,e),t}(Kg),Nm=function(e){function t(t,i){var r=e.call(this,t,i)||this,n=i.options[i.selectedIndex||0];return r.value=n&&n.text||"",r}return wA(t,e),t}(Kg),Vm=function(e){function t(t,i){var r=e.call(this,t,i)||this;return r.value=i.value,r}return wA(t,e),t}(Kg),Qm=function(e){function t(t,i){var r=e.call(this,t,i)||this;r.src=i.src,r.width=parseInt(i.width,10)||0,r.height=parseInt(i.height,10)||0,r.backgroundColor=r.styles.backgroundColor;try{if(i.contentWindow&&i.contentWindow.document&&i.contentWindow.document.documentElement){r.tree=Wm(t,i.contentWindow.document.documentElement);var n=i.contentWindow.document.documentElement?Qp(t,getComputedStyle(i.contentWindow.document.documentElement).backgroundColor):Hp.TRANSPARENT,s=i.contentWindow.document.body?Qp(t,getComputedStyle(i.contentWindow.document.body).backgroundColor):Hp.TRANSPARENT;r.backgroundColor=Dp(n)?Dp(s)?r.styles.backgroundColor:s:n}}catch(e){}return r}return wA(t,e),t}(Kg),Hm=["OL","UL","MENU"],Gm=function(e,t,i,r){for(var n=t.firstChild,s=void 0;n;n=s)if(s=n.nextSibling,qm(n)&&n.data.trim().length>0)i.textNodes.push(new Bm(e,n,i.styles));else if(Ym(n))if(hv(n)&&n.assignedNodes)n.assignedNodes().forEach(function(t){return Gm(e,t,i,r)});else{var o=zm(e,n);o.styles.isVisible()&&(Km(n,o,r)?o.flags|=4:Xm(o.styles)&&(o.flags|=2),-1!==Hm.indexOf(n.tagName)&&(o.flags|=8),i.elements.push(o),n.slot,n.shadowRoot?Gm(e,n.shadowRoot,o,r):uv(n)||iv(n)||cv(n)||Gm(e,n,o,r))}},zm=function(e,t){return ov(t)?new km(e,t):nv(t)?new Em(e,t):iv(t)?new Sm(e,t):$m(t)?new Tm(e,t):ev(t)?new Im(e,t):tv(t)?new Um(e,t):cv(t)?new Nm(e,t):uv(t)?new Vm(e,t):av(t)?new Qm(e,t):new Kg(e,t)},Wm=function(e,t){var i=zm(e,t);return i.flags|=4,Gm(e,t,i,i),i},Km=function(e,t,i){return t.styles.isPositionedWithZIndex()||t.styles.opacity<1||t.styles.isTransformed()||rv(e)&&i.styles.isTransparent()},Xm=function(e){return e.isPositioned()||e.isFloating()},qm=function(e){return e.nodeType===Node.TEXT_NODE},Ym=function(e){return e.nodeType===Node.ELEMENT_NODE},Jm=function(e){return Ym(e)&&void 0!==e.style&&!Zm(e)},Zm=function(e){return"object"===w(e.className)},$m=function(e){return"LI"===e.tagName},ev=function(e){return"OL"===e.tagName},tv=function(e){return"INPUT"===e.tagName},iv=function(e){return"svg"===e.tagName},rv=function(e){return"BODY"===e.tagName},nv=function(e){return"CANVAS"===e.tagName},sv=function(e){return"VIDEO"===e.tagName},ov=function(e){return"IMG"===e.tagName},av=function(e){return"IFRAME"===e.tagName},lv=function(e){return"STYLE"===e.tagName},uv=function(e){return"TEXTAREA"===e.tagName},cv=function(e){return"SELECT"===e.tagName},hv=function(e){return"SLOT"===e.tagName},Av=function(e){return e.tagName.indexOf("-")>0},dv=function(){function e(){this.counters={}}return e.prototype.getCounterValue=function(e){var t=this.counters[e];return t&&t.length?t[t.length-1]:1},e.prototype.getCounterValues=function(e){var t=this.counters[e];return t||[]},e.prototype.pop=function(e){var t=this;e.forEach(function(e){return t.counters[e].pop()})},e.prototype.parse=function(e){var t=this,i=e.counterIncrement,r=e.counterReset,n=!0;null!==i&&i.forEach(function(e){var i=t.counters[e.counter];i&&0!==e.increment&&(n=!1,i.length||i.push(1),i[Math.max(0,i.length-1)]+=e.increment)});var s=[];return n&&r.forEach(function(e){var i=t.counters[e.counter];s.push(e.counter),i||(i=t.counters[e.counter]=[]),i.push(e.reset)}),s},e}(),pv={integers:[1e3,900,500,400,100,90,50,40,10,9,5,4,1],values:["M","CM","D","CD","C","XC","L","XL","X","IX","V","IV","I"]},fv={integers:[9e3,8e3,7e3,6e3,5e3,4e3,3e3,2e3,1e3,900,800,700,600,500,400,300,200,100,90,80,70,60,50,40,30,20,10,9,8,7,6,5,4,3,2,1],values:["Ք","Փ","Ւ","Ց","Ր","Տ","Վ","Ս","Ռ","Ջ","Պ","Չ","Ո","Շ","Ն","Յ","Մ","Ճ","Ղ","Ձ","Հ","Կ","Ծ","Խ","Լ","Ի","Ժ","Թ","Ը","Է","Զ","Ե","Դ","Գ","Բ","Ա"]},gv={integers:[1e4,9e3,8e3,7e3,6e3,5e3,4e3,3e3,2e3,1e3,400,300,200,100,90,80,70,60,50,40,30,20,19,18,17,16,15,10,9,8,7,6,5,4,3,2,1],values:["י׳","ט׳","ח׳","ז׳","ו׳","ה׳","ד׳","ג׳","ב׳","א׳","ת","ש","ר","ק","צ","פ","ע","ס","נ","מ","ל","כ","יט","יח","יז","טז","טו","י","ט","ח","ז","ו","ה","ד","ג","ב","א"]},mv={integers:[1e4,9e3,8e3,7e3,6e3,5e3,4e3,3e3,2e3,1e3,900,800,700,600,500,400,300,200,100,90,80,70,60,50,40,30,20,10,9,8,7,6,5,4,3,2,1],values:["ჵ","ჰ","ჯ","ჴ","ხ","ჭ","წ","ძ","ც","ჩ","შ","ყ","ღ","ქ","ფ","ჳ","ტ","ს","რ","ჟ","პ","ო","ჲ","ნ","მ","ლ","კ","ი","თ","ჱ","ზ","ვ","ე","დ","გ","ბ","ა"]},vv=function(e,t,i,r,n,s){return e<t||e>i?Mv(e,n,s.length>0):r.integers.reduce(function(t,i,n){for(;e>=i;)e-=i,t+=r.values[n];return t},"")+s},_v=function(e,t,i,r){var n="";do{i||e--,n=r(e)+n,e/=t}while(e*t>=t);return n},yv=function(e,t,i,r,n){var s=i-t+1;return(e<0?"-":"")+(_v(Math.abs(e),s,r,function(e){return SA(Math.floor(e%s)+t)})+n)},bv=function(e,t,i){void 0===i&&(i=". ");var r=t.length;return _v(Math.abs(e),r,!1,function(e){return t[Math.floor(e%r)]})+i},wv=function(e,t,i,r,n,s){if(e<-9999||e>9999)return Mv(e,4,n.length>0);var o=Math.abs(e),a=n;if(0===o)return t[0]+a;for(var l=0;o>0&&l<=4;l++){var u=o%10;0===u&&Tg(s,1)&&""!==a?a=t[u]+a:u>1||1===u&&0===l||1===u&&1===l&&Tg(s,2)||1===u&&1===l&&Tg(s,4)&&e>100||1===u&&l>1&&Tg(s,8)?a=t[u]+(l>0?i[l-1]:"")+a:1===u&&l>0&&(a=i[l-1]+a),o=Math.floor(o/10)}return(e<0?r:"")+a},xv="十百千萬",Bv="拾佰仟萬",Pv="マイナス",Cv="마이너스",Mv=function(e,t,i){var r=i?". ":"",n=i?"、":"",s=i?", ":"",o=i?" ":"";switch(t){case 0:return"•"+o;case 1:return"◦"+o;case 2:return"◾"+o;case 5:var a=yv(e,48,57,!0,r);return a.length<4?"0"+a:a;case 4:return bv(e,"〇一二三四五六七八九",n);case 6:return vv(e,1,3999,pv,3,r).toLowerCase();case 7:return vv(e,1,3999,pv,3,r);case 8:return yv(e,945,969,!1,r);case 9:return yv(e,97,122,!1,r);case 10:return yv(e,65,90,!1,r);case 11:return yv(e,1632,1641,!0,r);case 12:case 49:return vv(e,1,9999,fv,3,r);case 35:return vv(e,1,9999,fv,3,r).toLowerCase();case 13:return yv(e,2534,2543,!0,r);case 14:case 30:return yv(e,6112,6121,!0,r);case 15:return bv(e,"子丑寅卯辰巳午未申酉戌亥",n);case 16:return bv(e,"甲乙丙丁戊己庚辛壬癸",n);case 17:case 48:return wv(e,"零一二三四五六七八九",xv,"負",n,14);case 47:return wv(e,"零壹貳參肆伍陸柒捌玖",Bv,"負",n,15);case 42:return wv(e,"零一二三四五六七八九",xv,"负",n,14);case 41:return wv(e,"零壹贰叁肆伍陆柒捌玖",Bv,"负",n,15);case 26:return wv(e,"〇一二三四五六七八九","十百千万",Pv,n,0);case 25:return wv(e,"零壱弐参四伍六七八九","拾百千万",Pv,n,7);case 31:return wv(e,"영일이삼사오육칠팔구","십백천만",Cv,s,7);case 33:return wv(e,"零一二三四五六七八九","十百千萬",Cv,s,0);case 32:return wv(e,"零壹貳參四五六七八九","拾百千",Cv,s,7);case 18:return yv(e,2406,2415,!0,r);case 20:return vv(e,1,19999,mv,3,r);case 21:return yv(e,2790,2799,!0,r);case 22:return yv(e,2662,2671,!0,r);case 22:return vv(e,1,10999,gv,3,r);case 23:return bv(e,"あいうえおかきくけこさしすせそたちつてとなにぬねのはひふへほまみむめもやゆよらりるれろわゐゑをん");case 24:return bv(e,"いろはにほへとちりぬるをわかよたれそつねならむうゐのおくやまけふこえてあさきゆめみしゑひもせす");case 27:return yv(e,3302,3311,!0,r);case 28:return bv(e,"アイウエオカキクケコサシスセソタチツテトナニヌネノハヒフヘホマミムメモヤユヨラリルレロワヰヱヲン",n);case 29:return bv(e,"イロハニホヘトチリヌルヲワカヨタレソツネナラムウヰノオクヤマケフコエテアサキユメミシヱヒモセス",n);case 34:return yv(e,3792,3801,!0,r);case 37:return yv(e,6160,6169,!0,r);case 38:return yv(e,4160,4169,!0,r);case 39:return yv(e,2918,2927,!0,r);case 40:return yv(e,1776,1785,!0,r);case 43:return yv(e,3046,3055,!0,r);case 44:return yv(e,3174,3183,!0,r);case 45:return yv(e,3664,3673,!0,r);case 46:return yv(e,3872,3881,!0,r);default:return yv(e,48,57,!0,r)}},kv="data-html2canvas-ignore",Ev=function(){function e(e,t,i){if(this.context=e,this.options=i,this.scrolledElements=[],this.referenceElement=t,this.counters=new dv,this.quoteDepth=0,!t.ownerDocument)throw new Error("Cloned element does not have an owner document");this.documentElement=this.cloneNode(t.ownerDocument.documentElement,!1)}return e.prototype.toIFrame=function(e,t){var i=this,r=Tv(e,t);if(!r.contentWindow)return Promise.reject("Unable to find iframe window");var n=e.defaultView.pageXOffset,s=e.defaultView.pageYOffset,o=r.contentWindow,a=o.document,l=Dv(r).then(function(){return BA(i,void 0,void 0,function(){var e,i;return PA(this,function(n){switch(n.label){case 0:return this.scrolledElements.forEach(Uv),o&&(o.scrollTo(t.left,t.top),!/(iPad|iPhone|iPod)/g.test(navigator.userAgent)||o.scrollY===t.top&&o.scrollX===t.left||(this.context.logger.warn("Unable to restore scroll position for cloned document"),this.context.windowBounds=this.context.windowBounds.add(o.scrollX-t.left,o.scrollY-t.top,0,0))),e=this.options.onclone,void 0===(i=this.clonedReferenceElement)?[2,Promise.reject("Error finding the "+this.referenceElement.nodeName+" in the cloned document")]:a.fonts&&a.fonts.ready?[4,a.fonts.ready]:[3,2];case 1:n.sent(),n.label=2;case 2:return/(AppleWebKit)/g.test(navigator.userAgent)?[4,Fv(a)]:[3,4];case 3:n.sent(),n.label=4;case 4:return"function"==typeof e?[2,Promise.resolve().then(function(){return e(a,i)}).then(function(){return r})]:[2,r]}})})});return a.open(),a.write(Lv(document.doctype)+"<html></html>"),jv(this.referenceElement.ownerDocument,n,s),a.replaceChild(a.adoptNode(this.documentElement),a.documentElement),a.close(),l},e.prototype.createElementClone=function(e){if(Wg(e,2),nv(e))return this.createCanvasClone(e);if(sv(e))return this.createVideoClone(e);if(lv(e))return this.createStyleClone(e);var t=e.cloneNode(!1);return ov(t)&&(ov(e)&&e.currentSrc&&e.currentSrc!==e.src&&(t.src=e.currentSrc,t.srcset=""),"lazy"===t.loading&&(t.loading="eager")),Av(t)?this.createCustomElementClone(t):t},e.prototype.createCustomElementClone=function(e){var t=document.createElement("html2canvascustomelement");return Ov(e.style,t),t},e.prototype.createStyleClone=function(e){try{var t=e.sheet;if(t&&t.cssRules){var i=[].slice.call(t.cssRules,0).reduce(function(e,t){return t&&"string"==typeof t.cssText?e+t.cssText:e},""),r=e.cloneNode(!1);return r.textContent=i,r}}catch(e){if(this.context.logger.error("Unable to access cssRules property",e),"SecurityError"!==e.name)throw e}return e.cloneNode(!1)},e.prototype.createCanvasClone=function(e){var t;if(this.options.inlineImages&&e.ownerDocument){var i=e.ownerDocument.createElement("img");try{return i.src=e.toDataURL(),i}catch(t){this.context.logger.info("Unable to inline canvas contents, canvas is tainted",e)}}var r=e.cloneNode(!1);try{r.width=e.width,r.height=e.height;var n=e.getContext("2d"),s=r.getContext("2d");if(s)if(!this.options.allowTaint&&n)s.putImageData(n.getImageData(0,0,e.width,e.height),0,0);else{var o=null!==(t=e.getContext("webgl2"))&&void 0!==t?t:e.getContext("webgl");if(o){var a=o.getContextAttributes();!1===(null==a?void 0:a.preserveDrawingBuffer)&&this.context.logger.warn("Unable to clone WebGL context as it has preserveDrawingBuffer=false",e)}s.drawImage(e,0,0)}return r}catch(t){this.context.logger.info("Unable to clone canvas as it is tainted",e)}return r},e.prototype.createVideoClone=function(e){var t=e.ownerDocument.createElement("canvas");t.width=e.offsetWidth,t.height=e.offsetHeight;var i=t.getContext("2d");try{return i&&(i.drawImage(e,0,0,t.width,t.height),this.options.allowTaint||i.getImageData(0,0,t.width,t.height)),t}catch(t){this.context.logger.info("Unable to clone video as it is tainted",e)}var r=e.ownerDocument.createElement("canvas");return r.width=e.offsetWidth,r.height=e.offsetHeight,r},e.prototype.appendChildNode=function(e,t,i){Ym(t)&&(function(e){return"SCRIPT"===e.tagName}(t)||t.hasAttribute(kv)||"function"==typeof this.options.ignoreElements&&this.options.ignoreElements(t))||this.options.copyStyles&&Ym(t)&&lv(t)||e.appendChild(this.cloneNode(t,i))},e.prototype.cloneChildNodes=function(e,t,i){for(var r=this,n=e.shadowRoot?e.shadowRoot.firstChild:e.firstChild;n;n=n.nextSibling)if(Ym(n)&&hv(n)&&"function"==typeof n.assignedNodes){var s=n.assignedNodes();s.length&&s.forEach(function(e){return r.appendChildNode(t,e,i)})}else this.appendChildNode(t,n,i)},e.prototype.cloneNode=function(e,t){if(qm(e))return document.createTextNode(e.data);if(!e.ownerDocument)return e.cloneNode(!1);var i=e.ownerDocument.defaultView;if(i&&Ym(e)&&(Jm(e)||Zm(e))){var r=this.createElementClone(e);r.style.transitionProperty="none";var n=i.getComputedStyle(e),s=i.getComputedStyle(e,":before"),o=i.getComputedStyle(e,":after");this.referenceElement===e&&Jm(r)&&(this.clonedReferenceElement=r),rv(r)&&Hv(r);var a=this.counters.parse(new Gg(this.context,n)),l=this.resolvePseudoContent(e,r,s,im.BEFORE);Av(e)&&(t=!0),sv(e)||this.cloneChildNodes(e,r,t),l&&r.insertBefore(l,r.firstChild);var u=this.resolvePseudoContent(e,r,o,im.AFTER);return u&&r.appendChild(u),this.counters.pop(a),(n&&(this.options.copyStyles||Zm(e))&&!av(e)||t)&&Ov(n,r),0===e.scrollTop&&0===e.scrollLeft||this.scrolledElements.push([r,e.scrollLeft,e.scrollTop]),(uv(e)||cv(e))&&(uv(r)||cv(r))&&(r.value=e.value),r}return e.cloneNode(!1)},e.prototype.resolvePseudoContent=function(e,t,i,r){var n=this;if(i){var s=i.content,o=t.ownerDocument;if(o&&s&&"none"!==s&&"-moz-alt-content"!==s&&"none"!==i.display){this.counters.parse(new Gg(this.context,i));var a=new Hg(this.context,i),l=o.createElement("html2canvaspseudoelement");Ov(i,l),a.content.forEach(function(t){if(0===t.type)l.appendChild(o.createTextNode(t.value));else if(22===t.type){var i=o.createElement("img");i.src=t.value,i.style.opacity="1",l.appendChild(i)}else if(18===t.type){if("attr"===t.name){var r=t.values.filter(Ap);r.length&&l.appendChild(o.createTextNode(e.getAttribute(r[0].value)||""))}else if("counter"===t.name){var s=t.values.filter(gp),u=s[0],c=s[1];if(u&&Ap(u)){var h=n.counters.getCounterValue(u.value),A=c&&Ap(c)?Jf.parse(n.context,c.value):3;l.appendChild(o.createTextNode(Mv(h,A,!1)))}}else if("counters"===t.name){var d=t.values.filter(gp),p=(u=d[0],d[1]);c=d[2];if(u&&Ap(u)){var f=n.counters.getCounterValues(u.value),g=c&&Ap(c)?Jf.parse(n.context,c.value):3,m=p&&0===p.type?p.value:"",v=f.map(function(e){return Mv(e,g,!1)}).join(m);l.appendChild(o.createTextNode(v))}}}else if(20===t.type)switch(t.value){case"open-quote":l.appendChild(o.createTextNode(Lg(a.quotes,n.quoteDepth++,!0)));break;case"close-quote":l.appendChild(o.createTextNode(Lg(a.quotes,--n.quoteDepth,!1)));break;default:l.appendChild(o.createTextNode(t.value))}}),l.className=Nv+" "+Vv;var u=r===im.BEFORE?" "+Nv:" "+Vv;return Zm(t)?t.className.baseValue+=u:t.className+=u,l}}},e.destroy=function(e){return!!e.parentNode&&(e.parentNode.removeChild(e),!0)},e}();!function(e){e[e.BEFORE=0]="BEFORE",e[e.AFTER=1]="AFTER"}(im||(im={}));var Sv,Tv=function(e,t){var i=e.createElement("iframe");return i.className="html2canvas-container",i.style.visibility="hidden",i.style.position="fixed",i.style.left="-10000px",i.style.top="0px",i.style.border="0",i.width=t.width.toString(),i.height=t.height.toString(),i.scrolling="no",i.setAttribute(kv,"true"),e.body.appendChild(i),i},Iv=function(e){return new Promise(function(t){e.complete?t():e.src?(e.onload=t,e.onerror=t):t()})},Fv=function(e){return Promise.all([].slice.call(e.images,0).map(Iv))},Dv=function(e){return new Promise(function(t,i){var r=e.contentWindow;if(!r)return i("No window assigned for iframe");var n=r.document;r.onload=e.onload=function(){r.onload=e.onload=null;var i=setInterval(function(){n.body.childNodes.length>0&&"complete"===n.readyState&&(clearInterval(i),t(e))},50)}})},Rv=["all","d","content"],Ov=function(e,t){for(var i=e.length-1;i>=0;i--){var r=e.item(i);-1===Rv.indexOf(r)&&t.style.setProperty(r,e.getPropertyValue(r))}return t},Lv=function(e){var t="";return e&&(t+="<!DOCTYPE ",e.name&&(t+=e.name),e.internalSubset&&(t+=e.internalSubset),e.publicId&&(t+='"'+e.publicId+'"'),e.systemId&&(t+='"'+e.systemId+'"'),t+=">"),t},jv=function(e,t,i){e&&e.defaultView&&(t!==e.defaultView.pageXOffset||i!==e.defaultView.pageYOffset)&&e.defaultView.scrollTo(t,i)},Uv=function(e){var t=e[0],i=e[1],r=e[2];t.scrollLeft=i,t.scrollTop=r},Nv="___html2canvas___pseudoelement_before",Vv="___html2canvas___pseudoelement_after",Qv='{\n content: "" !important;\n display: none !important;\n}',Hv=function(e){Gv(e,"."+Nv+":before"+Qv+"\n ."+Vv+":after"+Qv)},Gv=function(e,t){var i=e.ownerDocument;if(i){var r=i.createElement("style");r.textContent=t,e.appendChild(r)}},zv=function(){function e(){}return e.getOrigin=function(t){var i=e._link;return i?(i.href=t,i.href=i.href,i.protocol+i.hostname+i.port):"about:blank"},e.isSameOrigin=function(t){return e.getOrigin(t)===e._origin},e.setContext=function(t){e._link=t.document.createElement("a"),e._origin=e.getOrigin(t.location.href)},e._origin="about:blank",e}(),Wv=function(){function e(e,t){this.context=e,this._options=t,this._cache={}}return e.prototype.addImage=function(e){var t=Promise.resolve();return this.has(e)?t:$v(e)||Yv(e)?((this._cache[e]=this.loadImage(e)).catch(function(){}),t):t},e.prototype.match=function(e){return this._cache[e]},e.prototype.loadImage=function(e){return BA(this,void 0,void 0,function(){var t,i,r,n,s=this;return PA(this,function(o){switch(o.label){case 0:return t=zv.isSameOrigin(e),i=!Jv(e)&&!0===this._options.useCORS&&gm.SUPPORT_CORS_IMAGES&&!t,r=!Jv(e)&&!t&&!$v(e)&&"string"==typeof this._options.proxy&&gm.SUPPORT_CORS_XHR&&!i,t||!1!==this._options.allowTaint||Jv(e)||$v(e)||r||i?(n=e,r?[4,this.proxy(n)]:[3,2]):[2];case 1:n=o.sent(),o.label=2;case 2:return this.context.logger.debug("Added image "+e.substring(0,256)),[4,new Promise(function(e,t){var r=new Image;r.onload=function(){return e(r)},r.onerror=t,(Zv(n)||i)&&(r.crossOrigin="anonymous"),r.src=n,!0===r.complete&&setTimeout(function(){return e(r)},500),s._options.imageTimeout>0&&setTimeout(function(){return t("Timed out ("+s._options.imageTimeout+"ms) loading image")},s._options.imageTimeout)})];case 3:return[2,o.sent()]}})})},e.prototype.has=function(e){return void 0!==this._cache[e]},e.prototype.keys=function(){return Promise.resolve(Object.keys(this._cache))},e.prototype.proxy=function(e){var t=this,i=this._options.proxy;if(!i)throw new Error("No proxy defined");var r=e.substring(0,256);return new Promise(function(n,s){var o=gm.SUPPORT_RESPONSE_TYPE?"blob":"text",a=new XMLHttpRequest;a.onload=function(){if(200===a.status)if("text"===o)n(a.response);else{var e=new FileReader;e.addEventListener("load",function(){return n(e.result)},!1),e.addEventListener("error",function(e){return s(e)},!1),e.readAsDataURL(a.response)}else s("Failed to proxy resource "+r+" with status code "+a.status)},a.onerror=s;var l=i.indexOf("?")>-1?"&":"?";if(a.open("GET",""+i+l+"url="+encodeURIComponent(e)+"&responseType="+o),"text"!==o&&a instanceof XMLHttpRequest&&(a.responseType=o),t._options.imageTimeout){var u=t._options.imageTimeout;a.timeout=u,a.ontimeout=function(){return s("Timed out ("+u+"ms) proxying "+r)}}a.send()})},e}(),Kv=/^data:image\/svg\+xml/i,Xv=/^data:image\/.*;base64,/i,qv=/^data:image\/.*/i,Yv=function(e){return gm.SUPPORT_SVG_DRAWING||!e_(e)},Jv=function(e){return qv.test(e)},Zv=function(e){return Xv.test(e)},$v=function(e){return"blob"===e.substr(0,4)},e_=function(e){return"svg"===e.substr(-3).toLowerCase()||Kv.test(e)},t_=function(){function e(e,t){this.type=0,this.x=e,this.y=t}return e.prototype.add=function(t,i){return new e(this.x+t,this.y+i)},e}(),i_=function(e,t,i){return new t_(e.x+(t.x-e.x)*i,e.y+(t.y-e.y)*i)},r_=function(){function e(e,t,i,r){this.type=1,this.start=e,this.startControl=t,this.endControl=i,this.end=r}return e.prototype.subdivide=function(t,i){var r=i_(this.start,this.startControl,t),n=i_(this.startControl,this.endControl,t),s=i_(this.endControl,this.end,t),o=i_(r,n,t),a=i_(n,s,t),l=i_(o,a,t);return i?new e(this.start,r,o,l):new e(l,a,s,this.end)},e.prototype.add=function(t,i){return new e(this.start.add(t,i),this.startControl.add(t,i),this.endControl.add(t,i),this.end.add(t,i))},e.prototype.reverse=function(){return new e(this.end,this.endControl,this.startControl,this.start)},e}(),n_=function(e){return 1===e.type},s_=function(e){var t=e.styles,i=e.bounds,r=Pp(t.borderTopLeftRadius,i.width,i.height),n=r[0],s=r[1],o=Pp(t.borderTopRightRadius,i.width,i.height),a=o[0],l=o[1],u=Pp(t.borderBottomRightRadius,i.width,i.height),c=u[0],h=u[1],A=Pp(t.borderBottomLeftRadius,i.width,i.height),d=A[0],p=A[1],f=[];f.push((n+a)/i.width),f.push((d+c)/i.width),f.push((s+p)/i.height),f.push((l+h)/i.height);var g=Math.max.apply(Math,f);g>1&&(n/=g,s/=g,a/=g,l/=g,c/=g,h/=g,d/=g,p/=g);var m=i.width-a,v=i.height-h,_=i.width-c,y=i.height-p,b=t.borderTopWidth,w=t.borderRightWidth,x=t.borderBottomWidth,B=t.borderLeftWidth,P=Cp(t.paddingTop,e.bounds.width),C=Cp(t.paddingRight,e.bounds.width),M=Cp(t.paddingBottom,e.bounds.width),k=Cp(t.paddingLeft,e.bounds.width);this.topLeftBorderDoubleOuterBox=n>0||s>0?o_(i.left+B/3,i.top+b/3,n-B/3,s-b/3,Sv.TOP_LEFT):new t_(i.left+B/3,i.top+b/3),this.topRightBorderDoubleOuterBox=n>0||s>0?o_(i.left+m,i.top+b/3,a-w/3,l-b/3,Sv.TOP_RIGHT):new t_(i.left+i.width-w/3,i.top+b/3),this.bottomRightBorderDoubleOuterBox=c>0||h>0?o_(i.left+_,i.top+v,c-w/3,h-x/3,Sv.BOTTOM_RIGHT):new t_(i.left+i.width-w/3,i.top+i.height-x/3),this.bottomLeftBorderDoubleOuterBox=d>0||p>0?o_(i.left+B/3,i.top+y,d-B/3,p-x/3,Sv.BOTTOM_LEFT):new t_(i.left+B/3,i.top+i.height-x/3),this.topLeftBorderDoubleInnerBox=n>0||s>0?o_(i.left+2*B/3,i.top+2*b/3,n-2*B/3,s-2*b/3,Sv.TOP_LEFT):new t_(i.left+2*B/3,i.top+2*b/3),this.topRightBorderDoubleInnerBox=n>0||s>0?o_(i.left+m,i.top+2*b/3,a-2*w/3,l-2*b/3,Sv.TOP_RIGHT):new t_(i.left+i.width-2*w/3,i.top+2*b/3),this.bottomRightBorderDoubleInnerBox=c>0||h>0?o_(i.left+_,i.top+v,c-2*w/3,h-2*x/3,Sv.BOTTOM_RIGHT):new t_(i.left+i.width-2*w/3,i.top+i.height-2*x/3),this.bottomLeftBorderDoubleInnerBox=d>0||p>0?o_(i.left+2*B/3,i.top+y,d-2*B/3,p-2*x/3,Sv.BOTTOM_LEFT):new t_(i.left+2*B/3,i.top+i.height-2*x/3),this.topLeftBorderStroke=n>0||s>0?o_(i.left+B/2,i.top+b/2,n-B/2,s-b/2,Sv.TOP_LEFT):new t_(i.left+B/2,i.top+b/2),this.topRightBorderStroke=n>0||s>0?o_(i.left+m,i.top+b/2,a-w/2,l-b/2,Sv.TOP_RIGHT):new t_(i.left+i.width-w/2,i.top+b/2),this.bottomRightBorderStroke=c>0||h>0?o_(i.left+_,i.top+v,c-w/2,h-x/2,Sv.BOTTOM_RIGHT):new t_(i.left+i.width-w/2,i.top+i.height-x/2),this.bottomLeftBorderStroke=d>0||p>0?o_(i.left+B/2,i.top+y,d-B/2,p-x/2,Sv.BOTTOM_LEFT):new t_(i.left+B/2,i.top+i.height-x/2),this.topLeftBorderBox=n>0||s>0?o_(i.left,i.top,n,s,Sv.TOP_LEFT):new t_(i.left,i.top),this.topRightBorderBox=a>0||l>0?o_(i.left+m,i.top,a,l,Sv.TOP_RIGHT):new t_(i.left+i.width,i.top),this.bottomRightBorderBox=c>0||h>0?o_(i.left+_,i.top+v,c,h,Sv.BOTTOM_RIGHT):new t_(i.left+i.width,i.top+i.height),this.bottomLeftBorderBox=d>0||p>0?o_(i.left,i.top+y,d,p,Sv.BOTTOM_LEFT):new t_(i.left,i.top+i.height),this.topLeftPaddingBox=n>0||s>0?o_(i.left+B,i.top+b,Math.max(0,n-B),Math.max(0,s-b),Sv.TOP_LEFT):new t_(i.left+B,i.top+b),this.topRightPaddingBox=a>0||l>0?o_(i.left+Math.min(m,i.width-w),i.top+b,m>i.width+w?0:Math.max(0,a-w),Math.max(0,l-b),Sv.TOP_RIGHT):new t_(i.left+i.width-w,i.top+b),this.bottomRightPaddingBox=c>0||h>0?o_(i.left+Math.min(_,i.width-B),i.top+Math.min(v,i.height-x),Math.max(0,c-w),Math.max(0,h-x),Sv.BOTTOM_RIGHT):new t_(i.left+i.width-w,i.top+i.height-x),this.bottomLeftPaddingBox=d>0||p>0?o_(i.left+B,i.top+Math.min(y,i.height-x),Math.max(0,d-B),Math.max(0,p-x),Sv.BOTTOM_LEFT):new t_(i.left+B,i.top+i.height-x),this.topLeftContentBox=n>0||s>0?o_(i.left+B+k,i.top+b+P,Math.max(0,n-(B+k)),Math.max(0,s-(b+P)),Sv.TOP_LEFT):new t_(i.left+B+k,i.top+b+P),this.topRightContentBox=a>0||l>0?o_(i.left+Math.min(m,i.width+B+k),i.top+b+P,m>i.width+B+k?0:a-B+k,l-(b+P),Sv.TOP_RIGHT):new t_(i.left+i.width-(w+C),i.top+b+P),this.bottomRightContentBox=c>0||h>0?o_(i.left+Math.min(_,i.width-(B+k)),i.top+Math.min(v,i.height+b+P),Math.max(0,c-(w+C)),h-(x+M),Sv.BOTTOM_RIGHT):new t_(i.left+i.width-(w+C),i.top+i.height-(x+M)),this.bottomLeftContentBox=d>0||p>0?o_(i.left+B+k,i.top+y,Math.max(0,d-(B+k)),p-(x+M),Sv.BOTTOM_LEFT):new t_(i.left+B+k,i.top+i.height-(x+M))};!function(e){e[e.TOP_LEFT=0]="TOP_LEFT",e[e.TOP_RIGHT=1]="TOP_RIGHT",e[e.BOTTOM_RIGHT=2]="BOTTOM_RIGHT",e[e.BOTTOM_LEFT=3]="BOTTOM_LEFT"}(Sv||(Sv={}));var o_=function(e,t,i,r,n){var s=(Math.sqrt(2)-1)/3*4,o=i*s,a=r*s,l=e+i,u=t+r;switch(n){case Sv.TOP_LEFT:return new r_(new t_(e,u),new t_(e,u-a),new t_(l-o,t),new t_(l,t));case Sv.TOP_RIGHT:return new r_(new t_(e,t),new t_(e+o,t),new t_(l,u-a),new t_(l,u));case Sv.BOTTOM_RIGHT:return new r_(new t_(l,t),new t_(l,t+a),new t_(e+o,u),new t_(e,u));case Sv.BOTTOM_LEFT:default:return new r_(new t_(l,u),new t_(l-o,u),new t_(e,t+a),new t_(e,t))}},a_=function(e){return[e.topLeftBorderBox,e.topRightBorderBox,e.bottomRightBorderBox,e.bottomLeftBorderBox]},l_=function(e){return[e.topLeftPaddingBox,e.topRightPaddingBox,e.bottomRightPaddingBox,e.bottomLeftPaddingBox]},u_=function(e,t,i){this.offsetX=e,this.offsetY=t,this.matrix=i,this.type=0,this.target=6},c_=function(e,t){this.path=e,this.target=t,this.type=1},h_=function(e){this.opacity=e,this.type=2,this.target=6},A_=function(e){return 1===e.type},d_=function(e,t){return e.length===t.length&&e.some(function(e,i){return e===t[i]})},p_=function(e){this.element=e,this.inlineLevel=[],this.nonInlineLevel=[],this.negativeZIndex=[],this.zeroOrAutoZIndexOrTransformedOrOpacity=[],this.positiveZIndex=[],this.nonPositionedFloats=[],this.nonPositionedInlineLevel=[]},f_=function(){function e(e,t){if(this.container=e,this.parent=t,this.effects=[],this.curves=new s_(this.container),this.container.styles.opacity<1&&this.effects.push(new h_(this.container.styles.opacity)),null!==this.container.styles.transform){var i=this.container.bounds.left+this.container.styles.transformOrigin[0].number,r=this.container.bounds.top+this.container.styles.transformOrigin[1].number,n=this.container.styles.transform;this.effects.push(new u_(i,r,n))}if(0!==this.container.styles.overflowX){var s=a_(this.curves),o=l_(this.curves);d_(s,o)?this.effects.push(new c_(s,6)):(this.effects.push(new c_(s,2)),this.effects.push(new c_(o,4)))}}return e.prototype.getEffects=function(e){for(var t=-1===[2,3].indexOf(this.container.styles.position),i=this.parent,r=this.effects.slice(0);i;){var n=i.effects.filter(function(e){return!A_(e)});if(t||0!==i.container.styles.position||!i.parent){if(r.unshift.apply(r,n),t=-1===[2,3].indexOf(i.container.styles.position),0!==i.container.styles.overflowX){var s=a_(i.curves),o=l_(i.curves);d_(s,o)||r.unshift(new c_(o,6))}}else r.unshift.apply(r,n);i=i.parent}return r.filter(function(t){return Tg(t.target,e)})},e}(),g_=function(e,t,i,r){e.container.elements.forEach(function(n){var s=Tg(n.flags,4),o=Tg(n.flags,2),a=new f_(n,e);Tg(n.styles.display,2048)&&r.push(a);var l=Tg(n.flags,8)?[]:r;if(s||o){var u=s||n.styles.isPositioned()?i:t,c=new p_(a);if(n.styles.isPositioned()||n.styles.opacity<1||n.styles.isTransformed()){var h=n.styles.zIndex.order;if(h<0){var A=0;u.negativeZIndex.some(function(e,t){return h>e.element.container.styles.zIndex.order?(A=t,!1):A>0}),u.negativeZIndex.splice(A,0,c)}else if(h>0){var d=0;u.positiveZIndex.some(function(e,t){return h>=e.element.container.styles.zIndex.order?(d=t+1,!1):d>0}),u.positiveZIndex.splice(d,0,c)}else u.zeroOrAutoZIndexOrTransformedOrOpacity.push(c)}else n.styles.isFloating()?u.nonPositionedFloats.push(c):u.nonPositionedInlineLevel.push(c);g_(a,c,s?c:i,l)}else n.styles.isInlineLevel()?t.inlineLevel.push(a):t.nonInlineLevel.push(a),g_(a,t,i,l);Tg(n.flags,8)&&m_(n,l)})},m_=function(e,t){for(var i=e instanceof Im?e.start:1,r=e instanceof Im&&e.reversed,n=0;n<t.length;n++){var s=t[n];s.container instanceof Tm&&"number"==typeof s.container.value&&0!==s.container.value&&(i=s.container.value),s.listValue=Mv(i,s.container.styles.listStyleType,!0),i+=r?-1:1}},v_=function(e,t){switch(t){case 0:return y_(e.topLeftBorderBox,e.topLeftPaddingBox,e.topRightBorderBox,e.topRightPaddingBox);case 1:return y_(e.topRightBorderBox,e.topRightPaddingBox,e.bottomRightBorderBox,e.bottomRightPaddingBox);case 2:return y_(e.bottomRightBorderBox,e.bottomRightPaddingBox,e.bottomLeftBorderBox,e.bottomLeftPaddingBox);default:return y_(e.bottomLeftBorderBox,e.bottomLeftPaddingBox,e.topLeftBorderBox,e.topLeftPaddingBox)}},__=function(e,t){var i=[];return n_(e)?i.push(e.subdivide(.5,!1)):i.push(e),n_(t)?i.push(t.subdivide(.5,!0)):i.push(t),i},y_=function(e,t,i,r){var n=[];return n_(e)?n.push(e.subdivide(.5,!1)):n.push(e),n_(i)?n.push(i.subdivide(.5,!0)):n.push(i),n_(r)?n.push(r.subdivide(.5,!0).reverse()):n.push(r),n_(t)?n.push(t.subdivide(.5,!1).reverse()):n.push(t),n},b_=function(e){var t=e.bounds,i=e.styles;return t.add(i.borderLeftWidth,i.borderTopWidth,-(i.borderRightWidth+i.borderLeftWidth),-(i.borderTopWidth+i.borderBottomWidth))},w_=function(e){var t=e.styles,i=e.bounds,r=Cp(t.paddingLeft,i.width),n=Cp(t.paddingRight,i.width),s=Cp(t.paddingTop,i.width),o=Cp(t.paddingBottom,i.width);return i.add(r+t.borderLeftWidth,s+t.borderTopWidth,-(t.borderRightWidth+t.borderLeftWidth+r+n),-(t.borderTopWidth+t.borderBottomWidth+s+o))},x_=function(e,t,i){var r=function(e,t){return 0===e?t.bounds:2===e?w_(t):b_(t)}(M_(e.styles.backgroundOrigin,t),e),n=function(e,t){return 0===e?t.bounds:2===e?w_(t):b_(t)}(M_(e.styles.backgroundClip,t),e),s=C_(M_(e.styles.backgroundSize,t),i,r),o=s[0],a=s[1],l=Pp(M_(e.styles.backgroundPosition,t),r.width-o,r.height-a);return[k_(M_(e.styles.backgroundRepeat,t),l,s,r,n),Math.round(r.left+l[0]),Math.round(r.top+l[1]),o,a]},B_=function(e){return Ap(e)&&e.value===uf.AUTO},P_=function(e){return"number"==typeof e},C_=function(e,t,i){var r=t[0],n=t[1],s=t[2],o=e[0],a=e[1];if(!o)return[0,0];if(yp(o)&&a&&yp(a))return[Cp(o,i.width),Cp(a,i.height)];var l=P_(s);if(Ap(o)&&(o.value===uf.CONTAIN||o.value===uf.COVER))return P_(s)?i.width/i.height<s!=(o.value===uf.COVER)?[i.width,i.width/s]:[i.height*s,i.height]:[i.width,i.height];var u=P_(r),c=P_(n),h=u||c;if(B_(o)&&(!a||B_(a)))return u&&c?[r,n]:l||h?h&&l?[u?r:n*s,c?n:r/s]:[u?r:i.width,c?n:i.height]:[i.width,i.height];if(l){var A=0,d=0;return yp(o)?A=Cp(o,i.width):yp(a)&&(d=Cp(a,i.height)),B_(o)?A=d*s:a&&!B_(a)||(d=A/s),[A,d]}var p=null,f=null;if(yp(o)?p=Cp(o,i.width):a&&yp(a)&&(f=Cp(a,i.height)),null===p||a&&!B_(a)||(f=u&&c?p/r*n:i.height),null!==f&&B_(o)&&(p=u&&c?f/n*r:i.width),null!==p&&null!==f)return[p,f];throw new Error("Unable to calculate background-size for element")},M_=function(e,t){var i=e[t];return void 0===i?e[0]:i},k_=function(e,t,i,r,n){var s=t[0],o=t[1],a=i[0],l=i[1];switch(e){case 2:return[new t_(Math.round(r.left),Math.round(r.top+o)),new t_(Math.round(r.left+r.width),Math.round(r.top+o)),new t_(Math.round(r.left+r.width),Math.round(l+r.top+o)),new t_(Math.round(r.left),Math.round(l+r.top+o))];case 3:return[new t_(Math.round(r.left+s),Math.round(r.top)),new t_(Math.round(r.left+s+a),Math.round(r.top)),new t_(Math.round(r.left+s+a),Math.round(r.height+r.top)),new t_(Math.round(r.left+s),Math.round(r.height+r.top))];case 1:return[new t_(Math.round(r.left+s),Math.round(r.top+o)),new t_(Math.round(r.left+s+a),Math.round(r.top+o)),new t_(Math.round(r.left+s+a),Math.round(r.top+o+l)),new t_(Math.round(r.left+s),Math.round(r.top+o+l))];default:return[new t_(Math.round(n.left),Math.round(n.top)),new t_(Math.round(n.left+n.width),Math.round(n.top)),new t_(Math.round(n.left+n.width),Math.round(n.height+n.top)),new t_(Math.round(n.left),Math.round(n.height+n.top))]}},E_="Hidden Text",S_=function(){function e(e){this._data={},this._document=e}return e.prototype.parseMetrics=function(e,t){var i=this._document.createElement("div"),r=this._document.createElement("img"),n=this._document.createElement("span"),s=this._document.body;i.style.visibility="hidden",i.style.fontFamily=e,i.style.fontSize=t,i.style.margin="0",i.style.padding="0",i.style.whiteSpace="nowrap",s.appendChild(i),r.src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7",r.width=1,r.height=1,r.style.margin="0",r.style.padding="0",r.style.verticalAlign="baseline",n.style.fontFamily=e,n.style.fontSize=t,n.style.margin="0",n.style.padding="0",n.appendChild(this._document.createTextNode(E_)),i.appendChild(n),i.appendChild(r);var o=r.offsetTop-n.offsetTop+2;i.removeChild(n),i.appendChild(this._document.createTextNode(E_)),i.style.lineHeight="normal",r.style.verticalAlign="super";var a=r.offsetTop-i.offsetTop+2;return s.removeChild(i),{baseline:o,middle:a}},e.prototype.getMetrics=function(e,t){var i=e+" "+t;return void 0===this._data[i]&&(this._data[i]=this.parseMetrics(e,t)),this._data[i]},e}(),T_=function(e,t){this.context=e,this.options=t},I_=function(e){function t(t,i){var r=e.call(this,t,i)||this;return r._activeEffects=[],r.canvas=i.canvas?i.canvas:document.createElement("canvas"),r.ctx=r.canvas.getContext("2d"),i.canvas||(r.canvas.width=Math.floor(i.width*i.scale),r.canvas.height=Math.floor(i.height*i.scale),r.canvas.style.width=i.width+"px",r.canvas.style.height=i.height+"px"),r.fontMetrics=new S_(document),r.ctx.scale(r.options.scale,r.options.scale),r.ctx.translate(-i.x,-i.y),r.ctx.textBaseline="bottom",r._activeEffects=[],r.context.logger.debug("Canvas renderer initialized ("+i.width+"x"+i.height+") with scale "+i.scale),r}return wA(t,e),t.prototype.applyEffects=function(e){for(var t=this;this._activeEffects.length;)this.popEffect();e.forEach(function(e){return t.applyEffect(e)})},t.prototype.applyEffect=function(e){this.ctx.save(),function(e){return 2===e.type}(e)&&(this.ctx.globalAlpha=e.opacity),function(e){return 0===e.type}(e)&&(this.ctx.translate(e.offsetX,e.offsetY),this.ctx.transform(e.matrix[0],e.matrix[1],e.matrix[2],e.matrix[3],e.matrix[4],e.matrix[5]),this.ctx.translate(-e.offsetX,-e.offsetY)),A_(e)&&(this.path(e.path),this.ctx.clip()),this._activeEffects.push(e)},t.prototype.popEffect=function(){this._activeEffects.pop(),this.ctx.restore()},t.prototype.renderStack=function(e){return BA(this,void 0,void 0,function(){return PA(this,function(t){switch(t.label){case 0:return e.element.container.styles.isVisible()?[4,this.renderStackContent(e)]:[3,2];case 1:t.sent(),t.label=2;case 2:return[2]}})})},t.prototype.renderNode=function(e){return BA(this,void 0,void 0,function(){return PA(this,function(t){switch(t.label){case 0:return Tg(e.container.flags,16),e.container.styles.isVisible()?[4,this.renderNodeBackgroundAndBorders(e)]:[3,3];case 1:return t.sent(),[4,this.renderNodeContent(e)];case 2:t.sent(),t.label=3;case 3:return[2]}})})},t.prototype.renderTextWithLetterSpacing=function(e,t,i){var r=this;0===t?this.ctx.fillText(e.text,e.bounds.left,e.bounds.top+i):ym(e.text).reduce(function(t,n){return r.ctx.fillText(n,t,e.bounds.top+i),t+r.ctx.measureText(n).width},e.bounds.left)},t.prototype.createFontStyle=function(e){var t=e.fontVariant.filter(function(e){return"normal"===e||"small-caps"===e}).join(""),i=L_(e.fontFamily).join(", "),r=cp(e.fontSize)?""+e.fontSize.number+e.fontSize.unit:e.fontSize.number+"px";return[[e.fontStyle,t,e.fontWeight,r,i].join(" "),i,r]},t.prototype.renderTextNode=function(e,t){return BA(this,void 0,void 0,function(){var i,r,n,s,o,a,l,u,c=this;return PA(this,function(h){return i=this.createFontStyle(t),r=i[0],n=i[1],s=i[2],this.ctx.font=r,this.ctx.direction=1===t.direction?"rtl":"ltr",this.ctx.textAlign="left",this.ctx.textBaseline="alphabetic",o=this.fontMetrics.getMetrics(n,s),a=o.baseline,l=o.middle,u=t.paintOrder,e.textBounds.forEach(function(e){u.forEach(function(i){switch(i){case 0:c.ctx.fillStyle=Rp(t.color),c.renderTextWithLetterSpacing(e,t.letterSpacing,a);var r=t.textShadow;r.length&&e.text.trim().length&&(r.slice(0).reverse().forEach(function(i){c.ctx.shadowColor=Rp(i.color),c.ctx.shadowOffsetX=i.offsetX.number*c.options.scale,c.ctx.shadowOffsetY=i.offsetY.number*c.options.scale,c.ctx.shadowBlur=i.blur.number,c.renderTextWithLetterSpacing(e,t.letterSpacing,a)}),c.ctx.shadowColor="",c.ctx.shadowOffsetX=0,c.ctx.shadowOffsetY=0,c.ctx.shadowBlur=0),t.textDecorationLine.length&&(c.ctx.fillStyle=Rp(t.textDecorationColor||t.color),t.textDecorationLine.forEach(function(t){switch(t){case 1:c.ctx.fillRect(e.bounds.left,Math.round(e.bounds.top+a),e.bounds.width,1);break;case 2:c.ctx.fillRect(e.bounds.left,Math.round(e.bounds.top),e.bounds.width,1);break;case 3:c.ctx.fillRect(e.bounds.left,Math.ceil(e.bounds.top+l),e.bounds.width,1)}}));break;case 1:t.webkitTextStrokeWidth&&e.text.trim().length&&(c.ctx.strokeStyle=Rp(t.webkitTextStrokeColor),c.ctx.lineWidth=t.webkitTextStrokeWidth,c.ctx.lineJoin=window.chrome?"miter":"round",c.ctx.strokeText(e.text,e.bounds.left,e.bounds.top+a)),c.ctx.strokeStyle="",c.ctx.lineWidth=0,c.ctx.lineJoin="miter"}})}),[2]})})},t.prototype.renderReplacedElement=function(e,t,i){if(i&&e.intrinsicWidth>0&&e.intrinsicHeight>0){var r=w_(e),n=l_(t);this.path(n),this.ctx.save(),this.ctx.clip(),this.ctx.drawImage(i,0,0,e.intrinsicWidth,e.intrinsicHeight,r.left,r.top,r.width,r.height),this.ctx.restore()}},t.prototype.renderNodeContent=function(e){return BA(this,void 0,void 0,function(){var i,r,n,s,o,a,l,u,c,h,A,d,p,f,g,m,v,_;return PA(this,function(y){switch(y.label){case 0:this.applyEffects(e.getEffects(4)),i=e.container,r=e.curves,n=i.styles,s=0,o=i.textNodes,y.label=1;case 1:return s<o.length?(a=o[s],[4,this.renderTextNode(a,n)]):[3,4];case 2:y.sent(),y.label=3;case 3:return s++,[3,1];case 4:if(!(i instanceof km))return[3,8];y.label=5;case 5:return y.trys.push([5,7,,8]),[4,this.context.cache.match(i.src)];case 6:return g=y.sent(),this.renderReplacedElement(i,r,g),[3,8];case 7:return y.sent(),this.context.logger.error("Error loading image "+i.src),[3,8];case 8:if(i instanceof Em&&this.renderReplacedElement(i,r,i.canvas),!(i instanceof Sm))return[3,12];y.label=9;case 9:return y.trys.push([9,11,,12]),[4,this.context.cache.match(i.svg)];case 10:return g=y.sent(),this.renderReplacedElement(i,r,g),[3,12];case 11:return y.sent(),this.context.logger.error("Error loading svg "+i.svg.substring(0,255)),[3,12];case 12:return i instanceof Qm&&i.tree?[4,new t(this.context,{scale:this.options.scale,backgroundColor:i.backgroundColor,x:0,y:0,width:i.width,height:i.height}).render(i.tree)]:[3,14];case 13:l=y.sent(),i.width&&i.height&&this.ctx.drawImage(l,0,0,i.width,i.height,i.bounds.left,i.bounds.top,i.bounds.width,i.bounds.height),y.label=14;case 14:if(i instanceof Um&&(u=Math.min(i.bounds.width,i.bounds.height),i.type===Rm?i.checked&&(this.ctx.save(),this.path([new t_(i.bounds.left+.39363*u,i.bounds.top+.79*u),new t_(i.bounds.left+.16*u,i.bounds.top+.5549*u),new t_(i.bounds.left+.27347*u,i.bounds.top+.44071*u),new t_(i.bounds.left+.39694*u,i.bounds.top+.5649*u),new t_(i.bounds.left+.72983*u,i.bounds.top+.23*u),new t_(i.bounds.left+.84*u,i.bounds.top+.34085*u),new t_(i.bounds.left+.39363*u,i.bounds.top+.79*u)]),this.ctx.fillStyle=Rp(jm),this.ctx.fill(),this.ctx.restore()):i.type===Om&&i.checked&&(this.ctx.save(),this.ctx.beginPath(),this.ctx.arc(i.bounds.left+u/2,i.bounds.top+u/2,u/4,0,2*Math.PI,!0),this.ctx.fillStyle=Rp(jm),this.ctx.fill(),this.ctx.restore())),F_(i)&&i.value.length){switch(c=this.createFontStyle(n),v=c[0],h=c[1],A=this.fontMetrics.getMetrics(v,h).baseline,this.ctx.font=v,this.ctx.fillStyle=Rp(n.color),this.ctx.textBaseline="alphabetic",this.ctx.textAlign=R_(i.styles.textAlign),_=w_(i),d=0,i.styles.textAlign){case 1:d+=_.width/2;break;case 2:d+=_.width}p=_.add(d,0,0,-_.height/2+1),this.ctx.save(),this.path([new t_(_.left,_.top),new t_(_.left+_.width,_.top),new t_(_.left+_.width,_.top+_.height),new t_(_.left,_.top+_.height)]),this.ctx.clip(),this.renderTextWithLetterSpacing(new mm(i.value,p),n.letterSpacing,A),this.ctx.restore(),this.ctx.textBaseline="alphabetic",this.ctx.textAlign="left"}if(!Tg(i.styles.display,2048))return[3,20];if(null===i.styles.listStyleImage)return[3,19];if(0!==(f=i.styles.listStyleImage).type)return[3,18];g=void 0,m=f.url,y.label=15;case 15:return y.trys.push([15,17,,18]),[4,this.context.cache.match(m)];case 16:return g=y.sent(),this.ctx.drawImage(g,i.bounds.left-(g.width+10),i.bounds.top),[3,18];case 17:return y.sent(),this.context.logger.error("Error loading list-style-image "+m),[3,18];case 18:return[3,20];case 19:e.listValue&&-1!==i.styles.listStyleType&&(v=this.createFontStyle(n)[0],this.ctx.font=v,this.ctx.fillStyle=Rp(n.color),this.ctx.textBaseline="middle",this.ctx.textAlign="right",_=new MA(i.bounds.left,i.bounds.top+Cp(i.styles.paddingTop,i.bounds.width),i.bounds.width,Xf(n.lineHeight,n.fontSize.number)/2+1),this.renderTextWithLetterSpacing(new mm(e.listValue,_),n.letterSpacing,Xf(n.lineHeight,n.fontSize.number)/2+2),this.ctx.textBaseline="bottom",this.ctx.textAlign="left"),y.label=20;case 20:return[2]}})})},t.prototype.renderStackContent=function(e){return BA(this,void 0,void 0,function(){var t,i,r,n,s,o,a,l,u,c,h,A,d,p,f;return PA(this,function(g){switch(g.label){case 0:return Tg(e.element.container.flags,16),[4,this.renderNodeBackgroundAndBorders(e.element)];case 1:g.sent(),t=0,i=e.negativeZIndex,g.label=2;case 2:return t<i.length?(f=i[t],[4,this.renderStack(f)]):[3,5];case 3:g.sent(),g.label=4;case 4:return t++,[3,2];case 5:return[4,this.renderNodeContent(e.element)];case 6:g.sent(),r=0,n=e.nonInlineLevel,g.label=7;case 7:return r<n.length?(f=n[r],[4,this.renderNode(f)]):[3,10];case 8:g.sent(),g.label=9;case 9:return r++,[3,7];case 10:s=0,o=e.nonPositionedFloats,g.label=11;case 11:return s<o.length?(f=o[s],[4,this.renderStack(f)]):[3,14];case 12:g.sent(),g.label=13;case 13:return s++,[3,11];case 14:a=0,l=e.nonPositionedInlineLevel,g.label=15;case 15:return a<l.length?(f=l[a],[4,this.renderStack(f)]):[3,18];case 16:g.sent(),g.label=17;case 17:return a++,[3,15];case 18:u=0,c=e.inlineLevel,g.label=19;case 19:return u<c.length?(f=c[u],[4,this.renderNode(f)]):[3,22];case 20:g.sent(),g.label=21;case 21:return u++,[3,19];case 22:h=0,A=e.zeroOrAutoZIndexOrTransformedOrOpacity,g.label=23;case 23:return h<A.length?(f=A[h],[4,this.renderStack(f)]):[3,26];case 24:g.sent(),g.label=25;case 25:return h++,[3,23];case 26:d=0,p=e.positiveZIndex,g.label=27;case 27:return d<p.length?(f=p[d],[4,this.renderStack(f)]):[3,30];case 28:g.sent(),g.label=29;case 29:return d++,[3,27];case 30:return[2]}})})},t.prototype.mask=function(e){this.ctx.beginPath(),this.ctx.moveTo(0,0),this.ctx.lineTo(this.canvas.width,0),this.ctx.lineTo(this.canvas.width,this.canvas.height),this.ctx.lineTo(0,this.canvas.height),this.ctx.lineTo(0,0),this.formatPath(e.slice(0).reverse()),this.ctx.closePath()},t.prototype.path=function(e){this.ctx.beginPath(),this.formatPath(e),this.ctx.closePath()},t.prototype.formatPath=function(e){var t=this;e.forEach(function(e,i){var r=n_(e)?e.start:e;0===i?t.ctx.moveTo(r.x,r.y):t.ctx.lineTo(r.x,r.y),n_(e)&&t.ctx.bezierCurveTo(e.startControl.x,e.startControl.y,e.endControl.x,e.endControl.y,e.end.x,e.end.y)})},t.prototype.renderRepeat=function(e,t,i,r){this.path(e),this.ctx.fillStyle=t,this.ctx.translate(i,r),this.ctx.fill(),this.ctx.translate(-i,-r)},t.prototype.resizeImage=function(e,t,i){var r;if(e.width===t&&e.height===i)return e;var n=(null!==(r=this.canvas.ownerDocument)&&void 0!==r?r:document).createElement("canvas");return n.width=Math.max(1,t),n.height=Math.max(1,i),n.getContext("2d").drawImage(e,0,0,e.width,e.height,0,0,t,i),n},t.prototype.renderBackgroundImage=function(e){return BA(this,void 0,void 0,function(){var t,i,r,n,s,o;return PA(this,function(a){switch(a.label){case 0:t=e.styles.backgroundImage.length-1,i=function(i){var n,s,o,a,l,u,c,h,A,d,p,f,g,m,v,_,y,b,w,x,B,P,C,M,k,E,S,T,I,F,D;return PA(this,function(R){switch(R.label){case 0:if(0!==i.type)return[3,5];n=void 0,s=i.url,R.label=1;case 1:return R.trys.push([1,3,,4]),[4,r.context.cache.match(s)];case 2:return n=R.sent(),[3,4];case 3:return R.sent(),r.context.logger.error("Error loading background-image "+s),[3,4];case 4:return n&&(o=x_(e,t,[n.width,n.height,n.width/n.height]),_=o[0],P=o[1],C=o[2],w=o[3],x=o[4],m=r.ctx.createPattern(r.resizeImage(n,w,x),"repeat"),r.renderRepeat(_,m,P,C)),[3,6];case 5:1===i.type?(a=x_(e,t,[null,null,null]),_=a[0],P=a[1],C=a[2],w=a[3],x=a[4],l=Xp(i.angle,w,x),u=l[0],c=l[1],h=l[2],A=l[3],d=l[4],(p=document.createElement("canvas")).width=w,p.height=x,f=p.getContext("2d"),g=f.createLinearGradient(c,A,h,d),Kp(i.stops,u).forEach(function(e){return g.addColorStop(e.stop,Rp(e.color))}),f.fillStyle=g,f.fillRect(0,0,w,x),w>0&&x>0&&(m=r.ctx.createPattern(p,"repeat"),r.renderRepeat(_,m,P,C))):function(e){return 2===e.type}(i)&&(v=x_(e,t,[null,null,null]),_=v[0],y=v[1],b=v[2],w=v[3],x=v[4],B=0===i.position.length?[xp]:i.position,P=Cp(B[0],w),C=Cp(B[B.length-1],x),M=function(e,t,i,r,n){var s=0,o=0;switch(e.size){case 0:0===e.shape?s=o=Math.min(Math.abs(t),Math.abs(t-r),Math.abs(i),Math.abs(i-n)):1===e.shape&&(s=Math.min(Math.abs(t),Math.abs(t-r)),o=Math.min(Math.abs(i),Math.abs(i-n)));break;case 2:if(0===e.shape)s=o=Math.min(qp(t,i),qp(t,i-n),qp(t-r,i),qp(t-r,i-n));else if(1===e.shape){var a=Math.min(Math.abs(i),Math.abs(i-n))/Math.min(Math.abs(t),Math.abs(t-r)),l=Yp(r,n,t,i,!0),u=l[0],c=l[1];o=a*(s=qp(u-t,(c-i)/a))}break;case 1:0===e.shape?s=o=Math.max(Math.abs(t),Math.abs(t-r),Math.abs(i),Math.abs(i-n)):1===e.shape&&(s=Math.max(Math.abs(t),Math.abs(t-r)),o=Math.max(Math.abs(i),Math.abs(i-n)));break;case 3:if(0===e.shape)s=o=Math.max(qp(t,i),qp(t,i-n),qp(t-r,i),qp(t-r,i-n));else if(1===e.shape){a=Math.max(Math.abs(i),Math.abs(i-n))/Math.max(Math.abs(t),Math.abs(t-r));var h=Yp(r,n,t,i,!1);u=h[0],c=h[1],o=a*(s=qp(u-t,(c-i)/a))}}return Array.isArray(e.size)&&(s=Cp(e.size[0],r),o=2===e.size.length?Cp(e.size[1],n):s),[s,o]}(i,P,C,w,x),k=M[0],E=M[1],k>0&&E>0&&(S=r.ctx.createRadialGradient(y+P,b+C,0,y+P,b+C,k),Kp(i.stops,2*k).forEach(function(e){return S.addColorStop(e.stop,Rp(e.color))}),r.path(_),r.ctx.fillStyle=S,k!==E?(T=e.bounds.left+.5*e.bounds.width,I=e.bounds.top+.5*e.bounds.height,D=1/(F=E/k),r.ctx.save(),r.ctx.translate(T,I),r.ctx.transform(1,0,0,F,0,0),r.ctx.translate(-T,-I),r.ctx.fillRect(y,D*(b-I)+I,w,x*D),r.ctx.restore()):r.ctx.fill())),R.label=6;case 6:return t--,[2]}})},r=this,n=0,s=e.styles.backgroundImage.slice(0).reverse(),a.label=1;case 1:return n<s.length?(o=s[n],[5,i(o)]):[3,4];case 2:a.sent(),a.label=3;case 3:return n++,[3,1];case 4:return[2]}})})},t.prototype.renderSolidBorder=function(e,t,i){return BA(this,void 0,void 0,function(){return PA(this,function(r){return this.path(v_(i,t)),this.ctx.fillStyle=Rp(e),this.ctx.fill(),[2]})})},t.prototype.renderDoubleBorder=function(e,t,i,r){return BA(this,void 0,void 0,function(){var n,s;return PA(this,function(o){switch(o.label){case 0:return t<3?[4,this.renderSolidBorder(e,i,r)]:[3,2];case 1:return o.sent(),[2];case 2:return n=function(e,t){switch(t){case 0:return y_(e.topLeftBorderBox,e.topLeftBorderDoubleOuterBox,e.topRightBorderBox,e.topRightBorderDoubleOuterBox);case 1:return y_(e.topRightBorderBox,e.topRightBorderDoubleOuterBox,e.bottomRightBorderBox,e.bottomRightBorderDoubleOuterBox);case 2:return y_(e.bottomRightBorderBox,e.bottomRightBorderDoubleOuterBox,e.bottomLeftBorderBox,e.bottomLeftBorderDoubleOuterBox);default:return y_(e.bottomLeftBorderBox,e.bottomLeftBorderDoubleOuterBox,e.topLeftBorderBox,e.topLeftBorderDoubleOuterBox)}}(r,i),this.path(n),this.ctx.fillStyle=Rp(e),this.ctx.fill(),s=function(e,t){switch(t){case 0:return y_(e.topLeftBorderDoubleInnerBox,e.topLeftPaddingBox,e.topRightBorderDoubleInnerBox,e.topRightPaddingBox);case 1:return y_(e.topRightBorderDoubleInnerBox,e.topRightPaddingBox,e.bottomRightBorderDoubleInnerBox,e.bottomRightPaddingBox);case 2:return y_(e.bottomRightBorderDoubleInnerBox,e.bottomRightPaddingBox,e.bottomLeftBorderDoubleInnerBox,e.bottomLeftPaddingBox);default:return y_(e.bottomLeftBorderDoubleInnerBox,e.bottomLeftPaddingBox,e.topLeftBorderDoubleInnerBox,e.topLeftPaddingBox)}}(r,i),this.path(s),this.ctx.fill(),[2]}})})},t.prototype.renderNodeBackgroundAndBorders=function(e){return BA(this,void 0,void 0,function(){var t,i,r,n,s,o,a,l,u=this;return PA(this,function(c){switch(c.label){case 0:return this.applyEffects(e.getEffects(2)),t=e.container.styles,i=!Dp(t.backgroundColor)||t.backgroundImage.length,r=[{style:t.borderTopStyle,color:t.borderTopColor,width:t.borderTopWidth},{style:t.borderRightStyle,color:t.borderRightColor,width:t.borderRightWidth},{style:t.borderBottomStyle,color:t.borderBottomColor,width:t.borderBottomWidth},{style:t.borderLeftStyle,color:t.borderLeftColor,width:t.borderLeftWidth}],n=D_(M_(t.backgroundClip,0),e.curves),i||t.boxShadow.length?(this.ctx.save(),this.path(n),this.ctx.clip(),Dp(t.backgroundColor)||(this.ctx.fillStyle=Rp(t.backgroundColor),this.ctx.fill()),[4,this.renderBackgroundImage(e.container)]):[3,2];case 1:c.sent(),this.ctx.restore(),t.boxShadow.slice(0).reverse().forEach(function(t){u.ctx.save();var i,r,n,s,o,a=a_(e.curves),l=t.inset?0:1e4,c=(i=a,r=-l+(t.inset?1:-1)*t.spread.number,n=(t.inset?1:-1)*t.spread.number,s=t.spread.number*(t.inset?-2:2),o=t.spread.number*(t.inset?-2:2),i.map(function(e,t){switch(t){case 0:return e.add(r,n);case 1:return e.add(r+s,n);case 2:return e.add(r+s,n+o);case 3:return e.add(r,n+o)}return e}));t.inset?(u.path(a),u.ctx.clip(),u.mask(c)):(u.mask(a),u.ctx.clip(),u.path(c)),u.ctx.shadowOffsetX=t.offsetX.number+l,u.ctx.shadowOffsetY=t.offsetY.number,u.ctx.shadowColor=Rp(t.color),u.ctx.shadowBlur=t.blur.number,u.ctx.fillStyle=t.inset?Rp(t.color):"rgba(0,0,0,1)",u.ctx.fill(),u.ctx.restore()}),c.label=2;case 2:s=0,o=0,a=r,c.label=3;case 3:return o<a.length?0!==(l=a[o]).style&&!Dp(l.color)&&l.width>0?2!==l.style?[3,5]:[4,this.renderDashedDottedBorder(l.color,l.width,s,e.curves,2)]:[3,11]:[3,13];case 4:return c.sent(),[3,11];case 5:return 3!==l.style?[3,7]:[4,this.renderDashedDottedBorder(l.color,l.width,s,e.curves,3)];case 6:return c.sent(),[3,11];case 7:return 4!==l.style?[3,9]:[4,this.renderDoubleBorder(l.color,l.width,s,e.curves)];case 8:return c.sent(),[3,11];case 9:return[4,this.renderSolidBorder(l.color,s,e.curves)];case 10:c.sent(),c.label=11;case 11:s++,c.label=12;case 12:return o++,[3,3];case 13:return[2]}})})},t.prototype.renderDashedDottedBorder=function(e,t,i,r,n){return BA(this,void 0,void 0,function(){var s,o,a,l,u,c,h,A,d,p,f,g,m,v,_,y;return PA(this,function(b){return this.ctx.save(),s=function(e,t){switch(t){case 0:return __(e.topLeftBorderStroke,e.topRightBorderStroke);case 1:return __(e.topRightBorderStroke,e.bottomRightBorderStroke);case 2:return __(e.bottomRightBorderStroke,e.bottomLeftBorderStroke);default:return __(e.bottomLeftBorderStroke,e.topLeftBorderStroke)}}(r,i),o=v_(r,i),2===n&&(this.path(o),this.ctx.clip()),n_(o[0])?(a=o[0].start.x,l=o[0].start.y):(a=o[0].x,l=o[0].y),n_(o[1])?(u=o[1].end.x,c=o[1].end.y):(u=o[1].x,c=o[1].y),h=0===i||2===i?Math.abs(a-u):Math.abs(l-c),this.ctx.beginPath(),3===n?this.formatPath(s):this.formatPath(o.slice(0,2)),A=t<3?3*t:2*t,d=t<3?2*t:t,3===n&&(A=t,d=t),p=!0,h<=2*A?p=!1:h<=2*A+d?(A*=f=h/(2*A+d),d*=f):(g=Math.floor((h+d)/(A+d)),m=(h-g*A)/(g-1),d=(v=(h-(g+1)*A)/g)<=0||Math.abs(d-m)<Math.abs(d-v)?m:v),p&&(3===n?this.ctx.setLineDash([0,A+d]):this.ctx.setLineDash([A,d])),3===n?(this.ctx.lineCap="round",this.ctx.lineWidth=t):this.ctx.lineWidth=2*t+1.1,this.ctx.strokeStyle=Rp(e),this.ctx.stroke(),this.ctx.setLineDash([]),2===n&&(n_(o[0])&&(_=o[3],y=o[0],this.ctx.beginPath(),this.formatPath([new t_(_.end.x,_.end.y),new t_(y.start.x,y.start.y)]),this.ctx.stroke()),n_(o[1])&&(_=o[1],y=o[2],this.ctx.beginPath(),this.formatPath([new t_(_.end.x,_.end.y),new t_(y.start.x,y.start.y)]),this.ctx.stroke())),this.ctx.restore(),[2]})})},t.prototype.render=function(e){return BA(this,void 0,void 0,function(){var t;return PA(this,function(i){switch(i.label){case 0:return this.options.backgroundColor&&(this.ctx.fillStyle=Rp(this.options.backgroundColor),this.ctx.fillRect(this.options.x,this.options.y,this.options.width,this.options.height)),r=new f_(e,null),n=new p_(r),g_(r,n,n,s=[]),m_(r.container,s),t=n,[4,this.renderStack(t)];case 1:return i.sent(),this.applyEffects([]),[2,this.canvas]}var r,n,s})})},t}(T_),F_=function(e){return e instanceof Vm||(e instanceof Nm||e instanceof Um&&e.type!==Om&&e.type!==Rm)},D_=function(e,t){switch(e){case 0:return a_(t);case 2:return function(e){return[e.topLeftContentBox,e.topRightContentBox,e.bottomRightContentBox,e.bottomLeftContentBox]}(t);default:return l_(t)}},R_=function(e){switch(e){case 1:return"center";case 2:return"right";default:return"left"}},O_=["-apple-system","system-ui"],L_=function(e){return/iPhone OS 15_(0|1)/.test(window.navigator.userAgent)?e.filter(function(e){return-1===O_.indexOf(e)}):e},j_=function(e){function t(t,i){var r=e.call(this,t,i)||this;return r.canvas=i.canvas?i.canvas:document.createElement("canvas"),r.ctx=r.canvas.getContext("2d"),r.options=i,r.canvas.width=Math.floor(i.width*i.scale),r.canvas.height=Math.floor(i.height*i.scale),r.canvas.style.width=i.width+"px",r.canvas.style.height=i.height+"px",r.ctx.scale(r.options.scale,r.options.scale),r.ctx.translate(-i.x,-i.y),r.context.logger.debug("EXPERIMENTAL ForeignObject renderer initialized ("+i.width+"x"+i.height+" at "+i.x+","+i.y+") with scale "+i.scale),r}return wA(t,e),t.prototype.render=function(e){return BA(this,void 0,void 0,function(){var t,i;return PA(this,function(r){switch(r.label){case 0:return t=pm(this.options.width*this.options.scale,this.options.height*this.options.scale,this.options.scale,this.options.scale,e),[4,U_(t)];case 1:return i=r.sent(),this.options.backgroundColor&&(this.ctx.fillStyle=Rp(this.options.backgroundColor),this.ctx.fillRect(0,0,this.options.width*this.options.scale,this.options.height*this.options.scale)),this.ctx.drawImage(i,-this.options.x*this.options.scale,-this.options.y*this.options.scale),[2,this.canvas]}})})},t}(T_),U_=function(e){return new Promise(function(t,i){var r=new Image;r.onload=function(){t(r)},r.onerror=i,r.src="data:image/svg+xml;charset=utf-8,"+encodeURIComponent((new XMLSerializer).serializeToString(e))})},N_=function(){function e(e){var t=e.id,i=e.enabled;this.id=t,this.enabled=i,this.start=Date.now()}return e.prototype.debug=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.enabled&&("undefined"!=typeof window&&window.console&&"function"==typeof console.debug?console.debug.apply(console,CA([this.id,this.getTime()+"ms"],e)):this.info.apply(this,e))},e.prototype.getTime=function(){return Date.now()-this.start},e.prototype.info=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.enabled&&"undefined"!=typeof window&&window.console&&"function"==typeof console.info&&console.info.apply(console,CA([this.id,this.getTime()+"ms"],e))},e.prototype.warn=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.enabled&&("undefined"!=typeof window&&window.console&&"function"==typeof console.warn?console.warn.apply(console,CA([this.id,this.getTime()+"ms"],e)):this.info.apply(this,e))},e.prototype.error=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.enabled&&("undefined"!=typeof window&&window.console&&"function"==typeof console.error?console.error.apply(console,CA([this.id,this.getTime()+"ms"],e)):this.info.apply(this,e))},e.instances={},e}(),V_=function(){function e(t,i){var r;this.windowBounds=i,this.instanceName="#"+e.instanceCount++,this.logger=new N_({id:this.instanceName,enabled:t.logging}),this.cache=null!==(r=t.cache)&&void 0!==r?r:new Wv(this,t)}return e.instanceCount=1,e}(),Q_=function(e,t){return void 0===t&&(t={}),H_(e,t)};"undefined"!=typeof window&&zv.setContext(window);var H_=function(e,t){return BA(void 0,void 0,void 0,function(){var i,r,n,s,o,a,l,u,c,h,A,d,p,f,g,m,v,_,y,b,x,B,P,C,M,k,E,S,T,I,F,D,R,O,L,j,U,N;return PA(this,function(V){switch(V.label){case 0:if(!e||"object"!==w(e))return[2,Promise.reject("Invalid element provided as first argument")];if(!(i=e.ownerDocument))throw new Error("Element is not attached to a Document");if(!(r=i.defaultView))throw new Error("Document is not attached to a Window");return n={allowTaint:null!==(B=t.allowTaint)&&void 0!==B&&B,imageTimeout:null!==(P=t.imageTimeout)&&void 0!==P?P:15e3,proxy:t.proxy,useCORS:null!==(C=t.useCORS)&&void 0!==C&&C},s=xA({logging:null===(M=t.logging)||void 0===M||M,cache:t.cache},n),o={windowWidth:null!==(k=t.windowWidth)&&void 0!==k?k:r.innerWidth,windowHeight:null!==(E=t.windowHeight)&&void 0!==E?E:r.innerHeight,scrollX:null!==(S=t.scrollX)&&void 0!==S?S:r.pageXOffset,scrollY:null!==(T=t.scrollY)&&void 0!==T?T:r.pageYOffset},a=new MA(o.scrollX,o.scrollY,o.windowWidth,o.windowHeight),l=new V_(s,a),u=null!==(I=t.foreignObjectRendering)&&void 0!==I&&I,c={allowTaint:null!==(F=t.allowTaint)&&void 0!==F&&F,onclone:t.onclone,ignoreElements:t.ignoreElements,inlineImages:u,copyStyles:u},l.logger.debug("Starting document clone with size "+a.width+"x"+a.height+" scrolled to "+-a.left+","+-a.top),h=new Ev(l,e,c),(A=h.clonedReferenceElement)?[4,h.toIFrame(i,a)]:[2,Promise.reject("Unable to find element in cloned iframe")];case 1:return d=V.sent(),p=rv(A)||function(e){return"HTML"===e.tagName}(A)?function(e){var t=e.body,i=e.documentElement;if(!t||!i)throw new Error("Unable to get document size");var r=Math.max(Math.max(t.scrollWidth,i.scrollWidth),Math.max(t.offsetWidth,i.offsetWidth),Math.max(t.clientWidth,i.clientWidth)),n=Math.max(Math.max(t.scrollHeight,i.scrollHeight),Math.max(t.offsetHeight,i.offsetHeight),Math.max(t.clientHeight,i.clientHeight));return new MA(0,0,r,n)}(A.ownerDocument):kA(l,A),f=p.width,g=p.height,m=p.left,v=p.top,_=G_(l,A,t.backgroundColor),y={canvas:t.canvas,backgroundColor:_,scale:null!==(R=null!==(D=t.scale)&&void 0!==D?D:r.devicePixelRatio)&&void 0!==R?R:1,x:(null!==(O=t.x)&&void 0!==O?O:0)+m,y:(null!==(L=t.y)&&void 0!==L?L:0)+v,width:null!==(j=t.width)&&void 0!==j?j:Math.ceil(f),height:null!==(U=t.height)&&void 0!==U?U:Math.ceil(g)},u?(l.logger.debug("Document cloned, using foreign object rendering"),[4,new j_(l,y).render(A)]):[3,3];case 2:return b=V.sent(),[3,5];case 3:return l.logger.debug("Document cloned, element located at "+m+","+v+" with size "+f+"x"+g+" using computed rendering"),l.logger.debug("Starting DOM parsing"),x=Wm(l,A),_===x.styles.backgroundColor&&(x.styles.backgroundColor=Hp.TRANSPARENT),l.logger.debug("Starting renderer for element at "+y.x+","+y.y+" with size "+y.width+"x"+y.height),[4,new I_(l,y).render(x)];case 4:b=V.sent(),V.label=5;case 5:return(null===(N=t.removeContainer)||void 0===N||N)&&(Ev.destroy(d)||l.logger.error("Cannot detach cloned iframe as it is not in the DOM anymore")),l.logger.debug("Finished rendering"),[2,b]}})})},G_=function(e,t,i){var r=t.ownerDocument,n=r.documentElement?Qp(e,getComputedStyle(r.documentElement).backgroundColor):Hp.TRANSPARENT,s=r.body?Qp(e,getComputedStyle(r.body).backgroundColor):Hp.TRANSPARENT,o="string"==typeof i?Qp(e,i):null===i?Hp.TRANSPARENT:4294967295;return t===r.documentElement?Dp(n)?Dp(s)?o:s:n:o};function z_(e,t,i){var r=e.getBoundingClientRect(),n=t.getBoundingClientRect();i[0]+=r.left-n.left,i[1]+=r.top-n.top}var W_=function(){return P(function e(t){var i=this;x(this,e),this.container=t.viewerElement,this.language="en",this.localeService=t.localeService||new yh,this.scene=new zi(this,{canvasId:t.canvasId,canvasElement:t.canvasElement,keyboardEventsElement:t.keyboardEventsElement,contextAttr:{preserveDrawingBuffer:!1!==t.preserveDrawingBuffer,premultipliedAlpha:!!t.premultipliedAlpha,antialias:!1!==t.antialias},spinnerElementId:t.spinnerElementId,transparent:!1!==t.transparent,gammaInput:!0,gammaOutput:!1,backgroundColor:t.backgroundColor,backgroundColorFromAmbientLight:t.backgroundColorFromAmbientLight,ticksPerRender:1,ticksPerOcclusionTest:20,units:t.units,scale:t.scale,origin:t.origin,lightIntensity:t.lightIntensity,saoEnabled:t.saoEnabled,alphaDepthMask:!1!==t.alphaDepthMask,entityOffsetsEnabled:!!t.entityOffsetsEnabled,pickSurfacePrecisionEnabled:!!t.pickSurfacePrecisionEnabled,readableGeometryEnabled:!!t.readableGeometryEnabled,logarithmicDepthBufferEnabled:!!t.logarithmicDepthBufferEnabled,pbrEnabled:!!t.pbrEnabled,colorTextureEnabled:!1!==t.colorTextureEnabled,dtxEnabled:!!t.dtxEnabled,edgesEnabled:t.edgesEnabled,markerZOffset:t.markerZOffset,numCachedSectionPlanes:t.numCachedSectionPlanes,lodEnabled:!!t.lodEnabled,resolutionScale:t.resolutionScale,offset:t.offset,worldAxis:t.worldAxis}),this.metaScene=new _A(this,this.scene),this.id=t.id||this.scene.id,this.camera=this.scene.camera,this.cameraFlight=new kh(this.scene,{duration:.5}),this.cameraControl=new fA(this.scene,{snapRadius:t.snapRadius,doublePickFlyTo:!0}),this.scene.canvas.on("boundary",function(e){i.cameraControl.updatePivotElement()}),this._plugins=[],this._eventSubs={}},[{key:"capabilities",get:function(){return this.scene.capabilities}},{key:"on",value:function(e,t){var i=this._eventSubs[e];i||(i=[],this._eventSubs[e]=i),i.push(t)}},{key:"fire",value:function(e,t){var i=this._eventSubs[e];if(i)for(var r=0,n=i.length;r<n;r++)i[r](t)}},{key:"off",value:function(e){}},{key:"log",value:function(e){console.log("[xtctwins viewer ".concat(this.id,"]: ").concat(e))}},{key:"error",value:function(e){console.error("[xtctwins viewer ".concat(this.id,"]: ").concat(e))}},{key:"addPlugin",value:function(e){this._plugins.push(e)}},{key:"removePlugin",value:function(e){for(var t=0,i=this._plugins.length;t<i;t++){var r=this._plugins[t];if(r===e)return r.clear&&r.clear(),void this._plugins.splice(t,1)}}},{key:"sendToPlugins",value:function(e,t){for(var i=0,r=this._plugins.length;i<r;i++){var n=this._plugins[i];n.send&&n.send(e,t)}}},{key:"clear",value:function(){throw'Viewer#clear() no longer implemented - use \'#sendToPlugins("clear") instead'}},{key:"resetView",value:function(){throw"Viewer#resetView() no longer implemented - use CameraMemento & ObjectsMemento classes instead"}},{key:"beginSnapshot",value:function(){this._snapshotBegun||(this.scene._renderer.beginSnapshot(),this._snapshotBegun=!0)}},{key:"getSnapshot",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=!this._snapshotBegun,i=void 0!==e.width&&void 0!==e.height,r=this.scene.canvas.canvas,n=r.clientWidth,s=r.clientHeight,o=e.width?Math.floor(e.width):r.width,a=e.height?Math.floor(e.height):r.height;i&&(r.width=o,r.height=a),this._snapshotBegun||this.beginSnapshot({width:o,height:a}),e.includeGizmos||this.sendToPlugins("snapshotStarting");for(var l={},u=0,c=this._plugins.length;u<c;u++){var h=this._plugins[u];if(h.getContainerElement){var A=h.getContainerElement();A!==document.body&&(l[A.id]||(l[A.id]=!0,Q_(A).then(function(e){document.body.appendChild(e),setTimeout(function(){document.body.removeChild(e)},200)})))}}this.scene.fire("rendering",{},!0),this.scene._renderer.renderSnapshot();var d=this.scene._renderer.readSnapshot(e);return i&&(r.width=n,r.height=s,this.scene.glRedraw()),e.includeGizmos||this.sendToPlugins("snapshotFinished"),t&&this.endSnapshot(),d}},{key:"getSnapshotWithPlugins",value:(e=a(s().mark(function e(){var t,i,r,n,o,a,l,u,c,h,A,d,p,f,g,m,v,_,y,b,w,x=arguments;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:for(t=x.length>0&&void 0!==x[0]?x[0]:{},i=!this._snapshotBegun,r=void 0!==t.width&&void 0!==t.height,n=this.scene.canvas.canvas,o=n.clientWidth,a=n.clientHeight,l=t.width?Math.floor(t.width):n.width,u=t.height?Math.floor(t.height):n.height,r&&(n.width=l,n.height=u),this._snapshotBegun||this.beginSnapshot(),t.includeGizmos||this.sendToPlugins("snapshotStarting"),this.scene._renderer.renderSnapshot(),c=this.scene._renderer.readSnapshotAsCanvas(),r&&(n.width=o,n.height=a,this.scene.glRedraw()),h={},A=[],d=0,p=this._plugins.length;d<p;d++)(f=this._plugins[d]).getContainerElement&&(g=f.getContainerElement())!==document.body&&(h[g.id]||(h[g.id]=!0,A.push(g)));m=0,v=A.length;case 18:if(!(m<v)){e.next=28;break}return _=A[m],y=0==m?c.width/_.clientWidth:1,b=Y.vec2([0,0]),z_(n,_,b),e.next=25,Q_(_,{canvas:c,backgroundColor:null,x:b[0],y:b[1],scale:y});case 25:m++,e.next=18;break;case 28:return t.includeGizmos||this.sendToPlugins("snapshotFinished"),i&&this.endSnapshot(),"jpeg"!==(w=t.format||"png")&&"png"!==w&&"bmp"!==w&&(console.error("Unsupported image format: '"+w+"' - supported types are 'jpeg', 'bmp' and 'png' - defaulting to 'png'"),w="png"),t.includeGizmos||this.sendToPlugins("snapshotFinished"),i&&this.endSnapshot(),e.abrupt("return",c.toDataURL("image/".concat(w)));case 35:case"end":return e.stop()}},e,this)})),function(){return e.apply(this,arguments)})},{key:"endSnapshot",value:function(){this._snapshotBegun&&(this.scene._renderer.endSnapshot(),this.scene._renderer.render({force:!0}),this._snapshotBegun=!1)}},{key:"destroy",value:function(e){var t=this._plugins.slice();if(t.length>0)for(var i=0,r=t.length;i<r;i++){t[i].destroy()}this.cameraControl.destroy(),this.scene.destroy(e)}}]);var e}();function K_(e,t){if(!e)throw new Error(t||"loader assertion failed.")}var X_=Boolean("object"!==("undefined"==typeof process?"undefined":w(process))||"[object process]"!==String(process)||process.browser),q_="undefined"!=typeof process&&process.version&&/v([0-9]*)/.exec(process.version);q_&&parseFloat(q_[1]);function Y_(e,t){if(!e)throw new Error(t||"loaders.gl assertion failed.")}var J_="object"!==("undefined"==typeof process?"undefined":w(process))||"[object process]"!==String(process)||process.browser,Z_="undefined"!=typeof window&&void 0!==window.orientation,$_="undefined"!=typeof process&&process.version&&/v([0-9]*)/.exec(process.version);function ey(e){return ey="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},ey(e)}function ty(e){var t=function(e,t){if("object"!=ey(e)||!e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var r=i.call(e,t||"default");if("object"!=ey(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==ey(t)?t:String(t)}function iy(e,t,i){return(t=ty(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}$_&&parseFloat($_[1]);var ry=function(){return P(function e(t,i){var r=this;x(this,e),iy(this,"name",void 0),iy(this,"workerThread",void 0),iy(this,"isRunning",!0),iy(this,"result",void 0),iy(this,"_resolve",function(){}),iy(this,"_reject",function(){}),this.name=t,this.workerThread=i,this.result=new Promise(function(e,t){r._resolve=e,r._reject=t})},[{key:"postMessage",value:function(e,t){this.workerThread.postMessage({source:"loaders.gl",type:e,payload:t})}},{key:"done",value:function(e){Y_(this.isRunning),this.isRunning=!1,this._resolve(e)}},{key:"error",value:function(e){Y_(this.isRunning),this.isRunning=!1,this._reject(e)}}])}(),ny=function(){return P(function e(){x(this,e)},[{key:"terminate",value:function(){}}])}(),sy=new Map;function oy(e){Y_(e.source&&!e.url||!e.source&&e.url);var t=sy.get(e.source||e.url);return t||(e.url&&(t=function(e){if(!e.startsWith("http"))return e;return ay((t=e,"try {\n importScripts('".concat(t,"');\n} catch (error) {\n console.error(error);\n throw error;\n}")));var t}(e.url),sy.set(e.url,t)),e.source&&(t=ay(e.source),sy.set(e.source,t))),Y_(t),t}function ay(e){var t=new Blob([e],{type:"application/javascript"});return URL.createObjectURL(t)}function ly(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=arguments.length>2?arguments[2]:void 0,r=i||new Set;if(e){if(uy(e))r.add(e);else if(uy(e.buffer))r.add(e.buffer);else if(ArrayBuffer.isView(e));else if(t&&"object"===w(e))for(var n in e)ly(e[n],t,r)}else;return void 0===i?Array.from(r):[]}function uy(e){return!!e&&(e instanceof ArrayBuffer||("undefined"!=typeof MessagePort&&e instanceof MessagePort||("undefined"!=typeof ImageBitmap&&e instanceof ImageBitmap||"undefined"!=typeof OffscreenCanvas&&e instanceof OffscreenCanvas)))}var cy=function(){},hy=function(){return P(function e(t){x(this,e),iy(this,"name",void 0),iy(this,"source",void 0),iy(this,"url",void 0),iy(this,"terminated",!1),iy(this,"worker",void 0),iy(this,"onMessage",void 0),iy(this,"onError",void 0),iy(this,"_loadableURL","");var i=t.name,r=t.source,n=t.url;Y_(r||n),this.name=i,this.source=r,this.url=n,this.onMessage=cy,this.onError=function(e){return console.log(e)},this.worker=J_?this._createBrowserWorker():this._createNodeWorker()},[{key:"destroy",value:function(){this.onMessage=cy,this.onError=cy,this.worker.terminate(),this.terminated=!0}},{key:"isRunning",get:function(){return Boolean(this.onMessage)}},{key:"postMessage",value:function(e,t){t=t||ly(e),this.worker.postMessage(e,t)}},{key:"_getErrorFromErrorEvent",value:function(e){var t="Failed to load ";return t+="worker ".concat(this.name," from ").concat(this.url,". "),e.message&&(t+="".concat(e.message," in ")),e.lineno&&(t+=":".concat(e.lineno,":").concat(e.colno)),new Error(t)}},{key:"_createBrowserWorker",value:function(){var e=this;this._loadableURL=oy({source:this.source,url:this.url});var t=new Worker(this._loadableURL,{name:this.name});return t.onmessage=function(t){t.data?e.onMessage(t.data):e.onError(new Error("No data received"))},t.onerror=function(t){e.onError(e._getErrorFromErrorEvent(t)),e.terminated=!0},t.onmessageerror=function(e){return console.error(e)},t}},{key:"_createNodeWorker",value:function(){var e,t=this;if(this.url){var i=this.url.includes(":/")||this.url.startsWith("/")?this.url:"./".concat(this.url);e=new ny(i,{eval:!1})}else{if(!this.source)throw new Error("no worker");e=new ny(this.source,{eval:!0})}return e.on("message",function(e){t.onMessage(e)}),e.on("error",function(e){t.onError(e)}),e.on("exit",function(e){}),e}}],[{key:"isSupported",value:function(){return"undefined"!=typeof Worker&&J_||void 0!==ny&&!J_}}])}(),Ay=function(){return P(function e(t){x(this,e),iy(this,"name","unnamed"),iy(this,"source",void 0),iy(this,"url",void 0),iy(this,"maxConcurrency",1),iy(this,"maxMobileConcurrency",1),iy(this,"onDebug",function(){}),iy(this,"reuseWorkers",!0),iy(this,"props",{}),iy(this,"jobQueue",[]),iy(this,"idleQueue",[]),iy(this,"count",0),iy(this,"isDestroyed",!1),this.source=t.source,this.url=t.url,this.setProps(t)},[{key:"destroy",value:function(){this.idleQueue.forEach(function(e){return e.destroy()}),this.isDestroyed=!0}},{key:"setProps",value:function(e){this.props=n(n({},this.props),e),void 0!==e.name&&(this.name=e.name),void 0!==e.maxConcurrency&&(this.maxConcurrency=e.maxConcurrency),void 0!==e.maxMobileConcurrency&&(this.maxMobileConcurrency=e.maxMobileConcurrency),void 0!==e.reuseWorkers&&(this.reuseWorkers=e.reuseWorkers),void 0!==e.onDebug&&(this.onDebug=e.onDebug)}},{key:"startJob",value:(t=a(s().mark(function e(t){var i,r,n,o=this,a=arguments;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return i=a.length>1&&void 0!==a[1]?a[1]:function(e,t,i){return e.done(i)},r=a.length>2&&void 0!==a[2]?a[2]:function(e,t){return e.error(t)},n=new Promise(function(e){return o.jobQueue.push({name:t,onMessage:i,onError:r,onStart:e}),o}),this._startQueuedJob(),e.next=6,n;case 6:return e.abrupt("return",e.sent);case 7:case"end":return e.stop()}},e,this)})),function(e){return t.apply(this,arguments)})},{key:"_startQueuedJob",value:(e=a(s().mark(function e(){var t,i,r;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(this.jobQueue.length){e.next=2;break}return e.abrupt("return");case 2:if(t=this._getAvailableWorker()){e.next=5;break}return e.abrupt("return");case 5:if(!(i=this.jobQueue.shift())){e.next=18;break}return this.onDebug({message:"Starting job",name:i.name,workerThread:t,backlog:this.jobQueue.length}),r=new ry(i.name,t),t.onMessage=function(e){return i.onMessage(r,e.type,e.payload)},t.onError=function(e){return i.onError(r,e)},i.onStart(r),e.prev=12,e.next=15,r.result;case 15:return e.prev=15,this.returnWorkerToQueue(t),e.finish(15);case 18:case"end":return e.stop()}},e,this,[[12,,15,18]])})),function(){return e.apply(this,arguments)})},{key:"returnWorkerToQueue",value:function(e){this.isDestroyed||!this.reuseWorkers||this.count>this._getMaxConcurrency()?(e.destroy(),this.count--):this.idleQueue.push(e),this.isDestroyed||this._startQueuedJob()}},{key:"_getAvailableWorker",value:function(){if(this.idleQueue.length>0)return this.idleQueue.shift()||null;if(this.count<this._getMaxConcurrency()){this.count++;var e="".concat(this.name.toLowerCase()," (#").concat(this.count," of ").concat(this.maxConcurrency,")");return new hy({name:e,source:this.source,url:this.url})}return null}},{key:"_getMaxConcurrency",value:function(){return Z_?this.maxMobileConcurrency:this.maxConcurrency}}],[{key:"isSupported",value:function(){return hy.isSupported()}}]);var e,t}(),dy={maxConcurrency:3,maxMobileConcurrency:1,reuseWorkers:!0,onDebug:function(){}},py=function(){function e(t){x(this,e),iy(this,"props",void 0),iy(this,"workerPools",new Map),this.props=n({},dy),this.setProps(t),this.workerPools=new Map}return P(e,[{key:"destroy",value:function(){var e,t=u(this.workerPools.values());try{for(t.s();!(e=t.n()).done;){e.value.destroy()}}catch(e){t.e(e)}finally{t.f()}this.workerPools=new Map}},{key:"setProps",value:function(e){this.props=n(n({},this.props),e);var t,i=u(this.workerPools.values());try{for(i.s();!(t=i.n()).done;){t.value.setProps(this._getWorkerPoolProps())}}catch(e){i.e(e)}finally{i.f()}}},{key:"getWorkerPool",value:function(e){var t=e.name,i=e.source,r=e.url,n=this.workerPools.get(t);return n||((n=new Ay({name:t,source:i,url:r})).setProps(this._getWorkerPoolProps()),this.workerPools.set(t,n)),n}},{key:"_getWorkerPoolProps",value:function(){return{maxConcurrency:this.props.maxConcurrency,maxMobileConcurrency:this.props.maxMobileConcurrency,reuseWorkers:this.props.reuseWorkers,onDebug:this.props.onDebug}}}],[{key:"isSupported",value:function(){return hy.isSupported()}},{key:"getWorkerFarm",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return e._workerFarm=e._workerFarm||new e({}),e._workerFarm.setProps(t),e._workerFarm}}])}();iy(py,"_workerFarm",void 0);function fy(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=t[e.id]||{},r="".concat(e.id,"-worker.js"),n=i.workerUrl;if(n||"compression"!==e.id||(n=t.workerUrl),"test"===t._workerType&&(n="modules/".concat(e.module,"/dist/").concat(r)),!n){var s=e.version;"latest"===s&&(s="latest");var o=s?"@".concat(s):"";n="https://unpkg.com/@loaders.gl/".concat(e.module).concat(o,"/dist/").concat(r)}return Y_(n),n}function gy(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"3.4.15";Y_(e,"no worker provided");var i=e.version;return!(!t||!i)}function my(e,t){return!!py.isSupported()&&(!!(J_||null!=t&&t._nodeWorkers)&&(e.worker&&(null==t?void 0:t.worker)))}function vy(e,t,i,r,n){return _y.apply(this,arguments)}function _y(){return _y=a(s().mark(function e(t,i,r,n,o){var a,l,u,c,h,A;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return a=t.id,l=fy(t,r),u=py.getWorkerFarm(r),c=u.getWorkerPool({name:a,url:l}),r=JSON.parse(JSON.stringify(r)),n=JSON.parse(JSON.stringify(n||{})),e.next=8,c.startJob("process-on-worker",yy.bind(null,o));case 8:return(h=e.sent).postMessage("process",{input:i,options:r,context:n}),e.next=12,h.result;case 12:return A=e.sent,e.next=15,A.result;case 15:return e.abrupt("return",e.sent);case 16:case"end":return e.stop()}},e)})),_y.apply(this,arguments)}function yy(e,t,i,r){return by.apply(this,arguments)}function by(){return(by=a(s().mark(function e(t,i,r,n){var o,a,l,u,c;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:e.t0=r,e.next="done"===e.t0?3:"error"===e.t0?5:"process"===e.t0?7:20;break;case 3:return i.done(n),e.abrupt("break",21);case 5:return i.error(new Error(n.error)),e.abrupt("break",21);case 7:return o=n.id,a=n.input,l=n.options,e.prev=8,e.next=11,t(a,l);case 11:u=e.sent,i.postMessage("done",{id:o,result:u}),e.next=19;break;case 15:e.prev=15,e.t1=e.catch(8),c=e.t1 instanceof Error?e.t1.message:"unknown error",i.postMessage("error",{id:o,error:c});case 19:return e.abrupt("break",21);case 20:console.warn("parse-with-worker unknown message ".concat(r));case 21:case"end":return e.stop()}},e,null,[[8,15]])}))).apply(this,arguments)}function wy(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];var r,n=t.map(function(e){return e instanceof ArrayBuffer?new Uint8Array(e):e}),s=n.reduce(function(e,t){return e+t.byteLength},0),o=new Uint8Array(s),a=0,l=u(n);try{for(l.s();!(r=l.n()).done;){var c=r.value;o.set(c,a),a+=c.byteLength}}catch(e){l.e(e)}finally{l.f()}return o.buffer}function xy(e){return By.apply(this,arguments)}function By(){return(By=a(s().mark(function e(t){var i,r,n,o,a,l,u;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:i=[],r=!1,n=!1,e.prev=3,a=T(t);case 5:return e.next=7,a.next();case 7:if(!(r=!(l=e.sent).done)){e.next=13;break}u=l.value,i.push(u);case 10:r=!1,e.next=5;break;case 13:e.next=19;break;case 15:e.prev=15,e.t0=e.catch(3),n=!0,o=e.t0;case 19:if(e.prev=19,e.prev=20,!r||null==a.return){e.next=24;break}return e.next=24,a.return();case 24:if(e.prev=24,!n){e.next=27;break}throw o;case 27:return e.finish(24);case 28:return e.finish(19);case 29:return e.abrupt("return",wy.apply(void 0,i));case 30:case"end":return e.stop()}},e,null,[[3,15,19,29],[20,,24,28]])}))).apply(this,arguments)}var Py={};function Cy(e){for(var t in Py)if(e.startsWith(t)){var i=Py[t];e=e.replace(t,i)}return e.startsWith("http://")||e.startsWith("https://")||(e="".concat("").concat(e)),e}function My(e){if((t=e)&&"object"===w(t)&&t.isBuffer)return e;var t;if(e instanceof ArrayBuffer)return e;if(ArrayBuffer.isView(e))return 0===e.byteOffset&&e.byteLength===e.buffer.byteLength?e.buffer:e.buffer.slice(e.byteOffset,e.byteOffset+e.byteLength);if("string"==typeof e){var i=e;return(new TextEncoder).encode(i).buffer}if(e&&"object"===w(e)&&e._toArrayBuffer)return e._toArrayBuffer();throw new Error("toArrayBuffer")}function ky(e){var t=e?e.lastIndexOf("/"):-1;return t>=0?e.substr(t+1):""}var Ey=function(e){return"function"==typeof e},Sy=function(e){return null!==e&&"object"===w(e)},Ty=function(e){return Sy(e)&&e.constructor==={}.constructor},Iy=function(e){return e&&"function"==typeof e[Symbol.iterator]},Fy=function(e){return e&&"function"==typeof e[Symbol.asyncIterator]},Dy=function(e){return"undefined"!=typeof Response&&e instanceof Response||e&&e.arrayBuffer&&e.text&&e.json},Ry=function(e){return"undefined"!=typeof Blob&&e instanceof Blob},Oy=function(e){return function(e){return"undefined"!=typeof ReadableStream&&e instanceof ReadableStream||Sy(e)&&Ey(e.tee)&&Ey(e.cancel)&&Ey(e.getReader)}(e)||function(e){return Sy(e)&&Ey(e.read)&&Ey(e.pipe)&&function(e){return"boolean"==typeof e}(e.readable)}(e)},Ly=/^data:([-\w.]+\/[-\w.+]+)(;|,)/,jy=/^([-\w.]+\/[-\w.+]+)/;function Uy(e){var t=Ly.exec(e);return t?t[1]:""}var Ny=/\?.*/;function Vy(e){return e.replace(Ny,"")}function Qy(e){return Dy(e)?e.url:Ry(e)?e.name||"":"string"==typeof e?e:""}function Hy(e){if(Dy(e)){var t=e,i=t.headers.get("content-type")||"",r=Vy(t.url);return function(e){var t=jy.exec(e);return t?t[1]:e}(i)||Uy(r)}return Ry(e)?e.type||"":"string"==typeof e?Uy(e):""}function Gy(e){return Dy(e)?e.headers["content-length"]||-1:Ry(e)?e.size:"string"==typeof e?e.length:e instanceof ArrayBuffer||ArrayBuffer.isView(e)?e.byteLength:-1}function zy(e){return Wy.apply(this,arguments)}function Wy(){return(Wy=a(s().mark(function e(t){var i,r,n,o,a,l;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!Dy(t)){e.next=2;break}return e.abrupt("return",t);case 2:return i={},(r=Gy(t))>=0&&(i["content-length"]=String(r)),n=Qy(t),(o=Hy(t))&&(i["content-type"]=o),e.next=10,Jy(t);case 10:return(a=e.sent)&&(i["x-first-bytes"]=a),"string"==typeof t&&(t=(new TextEncoder).encode(t)),l=new Response(t,{headers:i}),Object.defineProperty(l,"url",{value:n}),e.abrupt("return",l);case 16:case"end":return e.stop()}},e)}))).apply(this,arguments)}function Ky(e){return Xy.apply(this,arguments)}function Xy(){return(Xy=a(s().mark(function e(t){var i;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(t.ok){e.next=5;break}return e.next=3,qy(t);case 3:throw i=e.sent,new Error(i);case 5:case"end":return e.stop()}},e)}))).apply(this,arguments)}function qy(e){return Yy.apply(this,arguments)}function Yy(){return(Yy=a(s().mark(function e(t){var i,r,n;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(i="Failed to fetch resource ".concat(t.url," (").concat(t.status,"): "),e.prev=1,r=t.headers.get("Content-Type"),n=t.statusText,!r.includes("application/json")){e.next=11;break}return e.t0=n,e.t1=" ",e.next=9,t.text();case 9:e.t2=e.sent,n=e.t0+=e.t1.concat.call(e.t1,e.t2);case 11:i=(i+=n).length>60?"".concat(i.slice(0,60),"..."):i,e.next=17;break;case 15:e.prev=15,e.t3=e.catch(1);case 17:return e.abrupt("return",i);case 18:case"end":return e.stop()}},e,null,[[1,15]])}))).apply(this,arguments)}function Jy(e){return Zy.apply(this,arguments)}function Zy(){return(Zy=a(s().mark(function e(t){var i,r,n,o;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(i=5,"string"!=typeof t){e.next=3;break}return e.abrupt("return","data:,".concat(t.slice(0,i)));case 3:if(!(t instanceof Blob)){e.next=8;break}return r=t.slice(0,5),e.next=7,new Promise(function(e){var t=new FileReader;t.onload=function(t){var i;return e(null==t||null===(i=t.target)||void 0===i?void 0:i.result)},t.readAsDataURL(r)});case 7:return e.abrupt("return",e.sent);case 8:if(!(t instanceof ArrayBuffer)){e.next=12;break}return n=t.slice(0,i),o=$y(n),e.abrupt("return","data:base64,".concat(o));case 12:return e.abrupt("return",null);case 13:case"end":return e.stop()}},e)}))).apply(this,arguments)}function $y(e){for(var t="",i=new Uint8Array(e),r=0;r<i.byteLength;r++)t+=String.fromCharCode(i[r]);return btoa(t)}function eb(e,t){return tb.apply(this,arguments)}function tb(){return(tb=a(s().mark(function e(t,i){var r;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if("string"!=typeof t){e.next=7;break}return t=Cy(t),r=i,null!=i&&i.fetch&&"function"!=typeof(null==i?void 0:i.fetch)&&(r=i.fetch),e.next=6,fetch(t,r);case 6:case 9:return e.abrupt("return",e.sent);case 7:return e.next=9,zy(t);case 10:case"end":return e.stop()}},e)}))).apply(this,arguments)}function ib(){return!("object"===("undefined"==typeof process?"undefined":w(process))&&"[object process]"===String(process)&&!process.browser)||function(e){if("undefined"!=typeof window&&"object"===w(window.process)&&"renderer"===window.process.type)return!0;if("undefined"!=typeof process&&"object"===w(process.versions)&&Boolean(process.versions.electron))return!0;var t="object"===("undefined"==typeof navigator?"undefined":w(navigator))&&"string"==typeof navigator.userAgent&&navigator.userAgent,i=e||t;return!!(i&&i.indexOf("Electron")>=0)}()}var rb={self:"undefined"!=typeof self&&self,window:"undefined"!=typeof window&&window,global:"undefined"!=typeof global&&global,document:"undefined"!=typeof document&&document,process:"object"===("undefined"==typeof process?"undefined":w(process))&&process},nb=rb.window||rb.self||rb.global,sb=rb.process||{},ob="undefined"!=typeof __VERSION__?__VERSION__:"untranspiled source";ib();var ab,lb=function(){return P(function e(t,i){x(this,e);var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"sessionStorage";iy(this,"storage",void 0),iy(this,"id",void 0),iy(this,"config",void 0),this.storage=function(e){try{var t=window[e],i="__storage_test__";return t.setItem(i,i),t.removeItem(i),t}catch(e){return null}}(r),this.id=t,this.config=i,this._loadConfiguration()},[{key:"getConfiguration",value:function(){return this.config}},{key:"setConfiguration",value:function(e){if(Object.assign(this.config,e),this.storage){var t=JSON.stringify(this.config);this.storage.setItem(this.id,t)}}},{key:"_loadConfiguration",value:function(){var e={};if(this.storage){var t=this.storage.getItem(this.id);e=t?JSON.parse(t):{}}return Object.assign(this.config,e),this}}])}();function ub(e,t,i){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:600,n=e.src.replace(/\(/g,"%28").replace(/\)/g,"%29");e.width>r&&(i=Math.min(i,r/e.width));var s=e.width*i,o=e.height*i,a=["font-size:1px;","padding:".concat(Math.floor(o/2),"px ").concat(Math.floor(s/2),"px;"),"line-height:".concat(o,"px;"),"background:url(".concat(n,");"),"background-size:".concat(s,"px ").concat(o,"px;"),"color:transparent;"].join("");return["".concat(t," %c+"),a]}function cb(e){return"string"==typeof e?ab[e.toUpperCase()]||ab.WHITE:e}function hb(e,t){if(!e)throw new Error(t||"Assertion failed")}function Ab(){var e,t,i;if(ib&&"performance"in nb)e=null==nb||null===(t=nb.performance)||void 0===t||null===(i=t.now)||void 0===i?void 0:i.call(t);else if("hrtime"in sb){var r,n=null==sb||null===(r=sb.hrtime)||void 0===r?void 0:r.call(sb);e=1e3*n[0]+n[1]/1e6}else e=Date.now();return e}!function(e){e[e.BLACK=30]="BLACK",e[e.RED=31]="RED",e[e.GREEN=32]="GREEN",e[e.YELLOW=33]="YELLOW",e[e.BLUE=34]="BLUE",e[e.MAGENTA=35]="MAGENTA",e[e.CYAN=36]="CYAN",e[e.WHITE=37]="WHITE",e[e.BRIGHT_BLACK=90]="BRIGHT_BLACK",e[e.BRIGHT_RED=91]="BRIGHT_RED",e[e.BRIGHT_GREEN=92]="BRIGHT_GREEN",e[e.BRIGHT_YELLOW=93]="BRIGHT_YELLOW",e[e.BRIGHT_BLUE=94]="BRIGHT_BLUE",e[e.BRIGHT_MAGENTA=95]="BRIGHT_MAGENTA",e[e.BRIGHT_CYAN=96]="BRIGHT_CYAN",e[e.BRIGHT_WHITE=97]="BRIGHT_WHITE"}(ab||(ab={}));var db={debug:ib&&console.debug||console.log,log:console.log,info:console.info,warn:console.warn,error:console.error},pb={enabled:!0,level:0};function fb(){}var gb={},mb={once:!0},vb=function(){return P(function e(){x(this,e);var t=(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{id:""}).id;iy(this,"id",void 0),iy(this,"VERSION",ob),iy(this,"_startTs",Ab()),iy(this,"_deltaTs",Ab()),iy(this,"_storage",void 0),iy(this,"userData",{}),iy(this,"LOG_THROTTLE_TIMEOUT",0),this.id=t,this.userData={},this._storage=new lb("__probe-".concat(this.id,"__"),pb),this.timeStamp("".concat(this.id," started")),function(e){var t,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:["constructor"],r=Object.getPrototypeOf(e),n=u(Object.getOwnPropertyNames(r));try{var s=function(){var r=t.value;"function"==typeof e[r]&&(i.find(function(e){return r===e})||(e[r]=e[r].bind(e)))};for(n.s();!(t=n.n()).done;)s()}catch(e){n.e(e)}finally{n.f()}}(this),Object.seal(this)},[{key:"level",get:function(){return this.getLevel()},set:function(e){this.setLevel(e)}},{key:"isEnabled",value:function(){return this._storage.config.enabled}},{key:"getLevel",value:function(){return this._storage.config.level}},{key:"getTotal",value:function(){return Number((Ab()-this._startTs).toPrecision(10))}},{key:"getDelta",value:function(){return Number((Ab()-this._deltaTs).toPrecision(10))}},{key:"priority",get:function(){return this.level},set:function(e){this.level=e}},{key:"getPriority",value:function(){return this.level}},{key:"enable",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return this._storage.setConfiguration({enabled:e}),this}},{key:"setLevel",value:function(e){return this._storage.setConfiguration({level:e}),this}},{key:"get",value:function(e){return this._storage.config[e]}},{key:"set",value:function(e,t){this._storage.setConfiguration(b({},e,t))}},{key:"settings",value:function(){console.table?console.table(this._storage.config):console.log(this._storage.config)}},{key:"assert",value:function(e,t){hb(e,t)}},{key:"warn",value:function(e){return this._getLogFunction(0,e,db.warn,arguments,mb)}},{key:"error",value:function(e){return this._getLogFunction(0,e,db.error,arguments)}},{key:"deprecated",value:function(e,t){return this.warn("`".concat(e,"` is deprecated and will be removed in a later version. Use `").concat(t,"` instead"))}},{key:"removed",value:function(e,t){return this.error("`".concat(e,"` has been removed. Use `").concat(t,"` instead"))}},{key:"probe",value:function(e,t){return this._getLogFunction(e,t,db.log,arguments,{time:!0,once:!0})}},{key:"log",value:function(e,t){return this._getLogFunction(e,t,db.debug,arguments)}},{key:"info",value:function(e,t){return this._getLogFunction(e,t,console.info,arguments)}},{key:"once",value:function(e,t){for(var i=arguments.length,r=new Array(i>2?i-2:0),n=2;n<i;n++)r[n-2]=arguments[n];return this._getLogFunction(e,t,db.debug||db.info,arguments,mb)}},{key:"table",value:function(e,t,i){return t?this._getLogFunction(e,t,console.table||fb,i&&[i],{tag:bb(t)}):fb}},{key:"image",value:function(e){var t=e.logLevel,i=e.priority,r=e.image,n=e.message,s=void 0===n?"":n,o=e.scale,a=void 0===o?1:o;return this._shouldLog(t||i)?ib?function(e){var t=e.image,i=e.message,r=void 0===i?"":i,n=e.scale,s=void 0===n?1:n;if("string"==typeof t){var o=new Image;return o.onload=function(){var e,t=ub(o,r,s);(e=console).log.apply(e,l(t))},o.src=t,fb}var a=t.nodeName||"";if("img"===a.toLowerCase()){var u;return(u=console).log.apply(u,l(ub(t,r,s))),fb}if("canvas"===a.toLowerCase()){var c=new Image;return c.onload=function(){var e;return(e=console).log.apply(e,l(ub(c,r,s)))},c.src=t.toDataURL(),fb}return fb}({image:r,message:s,scale:a}):(console.warn("removed"),fb):fb}},{key:"time",value:function(e,t){return this._getLogFunction(e,t,console.time?console.time:console.info)}},{key:"timeEnd",value:function(e,t){return this._getLogFunction(e,t,console.timeEnd?console.timeEnd:console.info)}},{key:"timeStamp",value:function(e,t){return this._getLogFunction(e,t,console.timeStamp||fb)}},{key:"group",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{collapsed:!1},r=yb({logLevel:e,message:t,opts:i}),n=i.collapsed;return r.method=(n?console.groupCollapsed:console.group)||console.info,this._getLogFunction(r)}},{key:"groupCollapsed",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this.group(e,t,Object.assign({},i,{collapsed:!0}))}},{key:"groupEnd",value:function(e){return this._getLogFunction(e,"",console.groupEnd||fb)}},{key:"withGroup",value:function(e,t,i){this.group(e,t)();try{i()}finally{this.groupEnd(e)()}}},{key:"trace",value:function(){console.trace&&console.trace()}},{key:"_shouldLog",value:function(e){return this.isEnabled()&&this.getLevel()>=_b(e)}},{key:"_getLogFunction",value:function(e,t,i,r,n){if(this._shouldLog(e)){var s;n=yb({logLevel:e,message:t,args:r,opts:n}),hb(i=i||n.method),n.total=this.getTotal(),n.delta=this.getDelta(),this._deltaTs=Ab();var o=n.tag||n.message;if(n.once){if(gb[o])return fb;gb[o]=Ab()}return t=function(e,t,i){if("string"==typeof t){var r=i.time?function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:8,i=Math.max(t-e.length,0);return"".concat(" ".repeat(i)).concat(e)}((n=i.total)<10?"".concat(n.toFixed(2),"ms"):n<100?"".concat(n.toFixed(1),"ms"):n<1e3?"".concat(n.toFixed(0),"ms"):"".concat((n/1e3).toFixed(2),"s")):"";t=function(e,t,i){return ib||"string"!=typeof e||(t&&(t=cb(t),e="[".concat(t,"m").concat(e,"[39m")),i&&(t=cb(i),e="[".concat(i+10,"m").concat(e,"[49m"))),e}(t=i.time?"".concat(e,": ").concat(r," ").concat(t):"".concat(e,": ").concat(t),i.color,i.background)}var n;return t}(this.id,n.message,n),(s=i).bind.apply(s,[console,t].concat(l(n.args)))}return fb}}])}();function _b(e){if(!e)return 0;var t;switch(w(e)){case"number":t=e;break;case"object":t=e.logLevel||e.priority||0;break;default:return 0}return hb(Number.isFinite(t)&&t>=0),t}function yb(e){var t=e.logLevel,i=e.message;e.logLevel=_b(t);for(var r=e.args?Array.from(e.args):[];r.length&&r.shift()!==i;);switch(w(t)){case"string":case"function":void 0!==i&&r.unshift(i),e.message=t;break;case"object":Object.assign(e,t)}"function"==typeof e.message&&(e.message=e.message());var n=w(e.message);return hb("string"===n||"object"===n),Object.assign(e,{args:r},e.opts)}function bb(e){for(var t in e)for(var i in e[t])return i||"untitled";return"empty"}iy(vb,"VERSION",ob);var wb=new vb({id:"loaders.gl"}),xb=function(){return P(function e(){x(this,e)},[{key:"log",value:function(){return function(){}}},{key:"info",value:function(){return function(){}}},{key:"warn",value:function(){return function(){}}},{key:"error",value:function(){return function(){}}}])}(),Bb={fetch:null,mimeType:void 0,nothrow:!1,log:new(function(){return P(function e(){x(this,e),iy(this,"console",void 0),this.console=console},[{key:"log",value:function(){for(var e,t=arguments.length,i=new Array(t),r=0;r<t;r++)i[r]=arguments[r];return(e=this.console.log).bind.apply(e,[this.console].concat(i))}},{key:"info",value:function(){for(var e,t=arguments.length,i=new Array(t),r=0;r<t;r++)i[r]=arguments[r];return(e=this.console.info).bind.apply(e,[this.console].concat(i))}},{key:"warn",value:function(){for(var e,t=arguments.length,i=new Array(t),r=0;r<t;r++)i[r]=arguments[r];return(e=this.console.warn).bind.apply(e,[this.console].concat(i))}},{key:"error",value:function(){for(var e,t=arguments.length,i=new Array(t),r=0;r<t;r++)i[r]=arguments[r];return(e=this.console.error).bind.apply(e,[this.console].concat(i))}}])}()),CDN:"https://unpkg.com/@loaders.gl",worker:!0,maxConcurrency:3,maxMobileConcurrency:1,reuseWorkers:X_,_nodeWorkers:!1,_workerType:"",limit:0,_limitMB:0,batchSize:"auto",batchDebounceMs:0,metadata:!1,transforms:[]},Pb={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 Cb(){globalThis.loaders=globalThis.loaders||{};var e=globalThis.loaders;return e._state=e._state||{},e._state}var Mb=function(){var e=Cb();return e.globalOptions=e.globalOptions||n({},Bb),e.globalOptions};function kb(e,t,i,r){return i=i||[],function(e,t){Eb(e,null,Bb,Pb,t);var i,r=u(t);try{for(r.s();!(i=r.n()).done;){var n=i.value,s=e&&e[n.id]||{},o=n.options&&n.options[n.id]||{},a=n.deprecatedOptions&&n.deprecatedOptions[n.id]||{};Eb(s,n.id,o,a,t)}}catch(e){r.e(e)}finally{r.f()}}(e,i=Array.isArray(i)?i:[i]),function(e,t,i){var r=e.options||{},s=n({},r);(function(e,t){t&&!("baseUri"in e)&&(e.baseUri=t)})(s,i),null===s.log&&(s.log=new xb);return Tb(s,Mb()),Tb(s,t),s}(t,e,r)}function Eb(e,t,i,r,n){var s=t||"Top level",o=t?"".concat(t,"."):"";for(var a in e){var l=!t&&Sy(e[a]);if(!(a in i)&&!("baseUri"===a&&!t)&&!("workerUrl"===a&&t))if(a in r)wb.warn("".concat(s," loader option '").concat(o).concat(a,"' no longer supported, use '").concat(r[a],"'"))();else if(!l){var u=Sb(a,n);wb.warn("".concat(s," loader option '").concat(o).concat(a,"' not recognized. ").concat(u))()}}}function Sb(e,t){var i,r=e.toLowerCase(),n="",s=u(t);try{for(s.s();!(i=s.n()).done;){var o=i.value;for(var a in o.options){if(e===a)return"Did you mean '".concat(o.id,".").concat(a,"'?");var l=a.toLowerCase();(r.startsWith(l)||l.startsWith(r))&&(n=n||"Did you mean '".concat(o.id,".").concat(a,"'?"))}}}catch(e){s.e(e)}finally{s.f()}return n}function Tb(e,t){for(var i in t)if(i in t){var r=t[i];Ty(r)&&Ty(e[i])?e[i]=n(n({},e[i]),t[i]):e[i]=t[i]}}function Ib(e){var t;return!!e&&(Array.isArray(e)&&(e=e[0]),Array.isArray(null===(t=e)||void 0===t?void 0:t.extensions))}function Fb(e){var t,i,r;return K_(e,"null loader"),K_(Ib(e),"invalid loader"),Array.isArray(e)&&(r=e[1],e=n(n({},e=e[0]),{},{options:n(n({},e.options),r)})),(null!==(t=e)&&void 0!==t&&t.parseTextSync||null!==(i=e)&&void 0!==i&&i.parseText)&&(e.text=!0),e.text||(e.binary=!0),e}function Db(){return(e=Cb()).loaderRegistry=e.loaderRegistry||[],e.loaderRegistry;var e}var Rb=new vb({id:"loaders.gl"}),Ob=/\.([^.]+)$/;function Lb(e){return jb.apply(this,arguments)}function jb(){return jb=a(s().mark(function e(t){var i,r,o,a,l=arguments;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(i=l.length>1&&void 0!==l[1]?l[1]:[],r=l.length>2?l[2]:void 0,o=l.length>3?l[3]:void 0,Nb(t)){e.next=5;break}return e.abrupt("return",null);case 5:if(!(a=Ub(t,i,n(n({},r),{},{nothrow:!0}),o))){e.next=8;break}return e.abrupt("return",a);case 8:if(!Ry(t)){e.next=13;break}return e.next=11,t.slice(0,10).arrayBuffer();case 11:t=e.sent,a=Ub(t,i,r,o);case 13:if(a||null!=r&&r.nothrow){e.next=15;break}throw new Error(Vb(t));case 15:return e.abrupt("return",a);case 16:case"end":return e.stop()}},e)})),jb.apply(this,arguments)}function Ub(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],i=arguments.length>2?arguments[2]:void 0,r=arguments.length>3?arguments[3]:void 0;if(!Nb(e))return null;if(t&&!Array.isArray(t))return Fb(t);var n,s=[];(t&&(s=s.concat(t)),null!=i&&i.ignoreRegisteredLoaders)||(n=s).push.apply(n,l(Db()));!function(e){var t,i=u(e);try{for(i.s();!(t=i.n()).done;){Fb(t.value)}}catch(e){i.e(e)}finally{i.f()}}(s);var o=function(e,t,i,r){var n,s=Qy(e),o=Hy(e),a=Vy(s)||(null==r?void 0:r.url),l=null,c="";null!=i&&i.mimeType&&(l=Qb(t,null==i?void 0:i.mimeType),c="match forced by supplied MIME type ".concat(null==i?void 0:i.mimeType));l=l||function(e,t){var i=t&&Ob.exec(t),r=i&&i[1];return r?function(e,t){t=t.toLowerCase();var i,r=u(e);try{for(r.s();!(i=r.n()).done;){var n,s=i.value,o=u(s.extensions);try{for(o.s();!(n=o.n()).done;){if(n.value.toLowerCase()===t)return s}}catch(e){o.e(e)}finally{o.f()}}}catch(e){r.e(e)}finally{r.f()}return null}(e,r):null}(t,a),c=c||(l?"matched url ".concat(a):""),l=l||Qb(t,o),c=c||(l?"matched MIME type ".concat(o):""),l=l||function(e,t){if(!t)return null;var i,r=u(e);try{for(r.s();!(i=r.n()).done;){var n=i.value;if("string"==typeof t){if(Hb(t,n))return n}else if(ArrayBuffer.isView(t)){if(Gb(t.buffer,t.byteOffset,n))return n}else if(t instanceof ArrayBuffer){if(Gb(t,0,n))return n}}}catch(e){r.e(e)}finally{r.f()}return null}(t,e),c=c||(l?"matched initial data ".concat(zb(e)):""),l=l||Qb(t,null==i?void 0:i.fallbackMimeType),c=c||(l?"matched fallback MIME type ".concat(o):""),c&&Rb.log(1,"selectLoader selected ".concat(null===(n=l)||void 0===n?void 0:n.name,": ").concat(c,"."));return l}(e,s,i,r);if(!(o||null!=i&&i.nothrow))throw new Error(Vb(e));return o}function Nb(e){return!(e instanceof Response&&204===e.status)}function Vb(e){var t=Qy(e),i=Hy(e),r="No valid loader found (";r+=t?"".concat(ky(t),", "):"no url provided, ",r+="MIME type: ".concat(i?'"'.concat(i,'"'):"not provided",", ");var n=e?zb(e):"";return r+=n?' first bytes: "'.concat(n,'"'):"first bytes: not available",r+=")"}function Qb(e,t){var i,r=u(e);try{for(r.s();!(i=r.n()).done;){var n=i.value;if(n.mimeTypes&&n.mimeTypes.includes(t))return n;if(t==="application/x.".concat(n.id))return n}}catch(e){r.e(e)}finally{r.f()}return null}function Hb(e,t){return t.testText?t.testText(e):(Array.isArray(t.tests)?t.tests:[t.tests]).some(function(t){return e.startsWith(t)})}function Gb(e,t,i){return(Array.isArray(i.tests)?i.tests:[i.tests]).some(function(r){return function(e,t,i,r){if(r instanceof ArrayBuffer)return function(e,t,i){if(i=i||e.byteLength,e.byteLength<i||t.byteLength<i)return!1;for(var r=new Uint8Array(e),n=new Uint8Array(t),s=0;s<r.length;++s)if(r[s]!==n[s])return!1;return!0}(r,e,r.byteLength);switch(w(r)){case"function":return r(e,i);case"string":return r===Wb(e,t,r.length);default:return!1}}(e,t,i,r)})}function zb(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:5;if("string"==typeof e)return e.slice(0,t);if(ArrayBuffer.isView(e))return Wb(e.buffer,e.byteOffset,t);if(e instanceof ArrayBuffer){return Wb(e,0,t)}return""}function Wb(e,t,i){if(e.byteLength<t+i)return"";for(var r=new DataView(e),n="",s=0;s<i;s++)n+=String.fromCharCode(r.getUint8(t+s));return n}var Kb=262144;function Xb(e,i){var r,n,o,a,l;return s().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:r=(null==i?void 0:i.chunkSize)||Kb,n=0,o=new TextEncoder;case 3:if(!(n<e.length)){t.next=11;break}return a=Math.min(e.length-n,r),l=e.slice(n,n+a),n+=a,t.next=9,o.encode(l);case 9:t.next=3;break;case 11:case"end":return t.stop()}},t)}function qb(){return(qb=k(s().mark(function e(t,i){var r,n,o,a;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:r=(null==i?void 0:i.chunkSize)||1048576,n=0;case 2:if(!(n<t.size)){e.next=12;break}return o=n+r,e.next=6,M(t.slice(n,o).arrayBuffer());case 6:return a=e.sent,n=o,e.next=10,a;case 10:e.next=2;break;case 12:case"end":return e.stop()}},e)}))).apply(this,arguments)}function Yb(e,t){return X_?function(e,t){return Jb.apply(this,arguments)}(e,t):function(e,t){return Zb.apply(this,arguments)}(e)}function Jb(){return(Jb=k(s().mark(function e(t,i){var r,n,o,a,l,u;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:r=t.getReader(),e.prev=1;case 2:return o=n||r.read(),null!=i&&i._streamReadAhead&&(n=r.read()),e.next=7,M(o);case 7:if(a=e.sent,l=a.done,u=a.value,!l){e.next=12;break}return e.abrupt("return");case 12:return e.next=14,My(u);case 14:e.next=2;break;case 16:e.next=21;break;case 18:e.prev=18,e.t0=e.catch(1),r.releaseLock();case 21:case"end":return e.stop()}},e,null,[[1,18]])}))).apply(this,arguments)}function Zb(){return(Zb=k(s().mark(function e(t,i){var r,n,o,a,l,u;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:r=!1,n=!1,e.prev=2,a=T(t);case 4:return e.next=6,M(a.next());case 6:if(!(r=!(l=e.sent).done)){e.next=13;break}return u=l.value,e.next=10,My(u);case 10:r=!1,e.next=4;break;case 13:e.next=19;break;case 15:e.prev=15,e.t0=e.catch(2),n=!0,o=e.t0;case 19:if(e.prev=19,e.prev=20,!r||null==a.return){e.next=24;break}return e.next=24,M(a.return());case 24:if(e.prev=24,!n){e.next=27;break}throw o;case 27:return e.finish(24);case 28:return e.finish(19);case 29:case"end":return e.stop()}},e,null,[[2,15,19,29],[20,,24,28]])}))).apply(this,arguments)}function $b(e,t){if("string"==typeof e)return Xb(e,t);if(e instanceof ArrayBuffer)return function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return s().mark(function i(){var r,n,o,a,l,u;return s().wrap(function(i){for(;;)switch(i.prev=i.next){case 0:r=t.chunkSize,n=void 0===r?262144:r,o=0;case 2:if(!(o<e.byteLength)){i.next=13;break}return a=Math.min(e.byteLength-o,n),l=new ArrayBuffer(a),u=new Uint8Array(e,o,a),new Uint8Array(l).set(u),o+=a,i.next=11,l;case 11:i.next=2;break;case 13:case"end":return i.stop()}},i)})()}(e,t);if(Ry(e))return function(e,t){return qb.apply(this,arguments)}(e,t);if(Oy(e))return Yb(e,t);if(Dy(e))return Yb(e.body,t);throw new Error("makeIterator")}var ew="Cannot convert supplied data type";function tw(e,t,i){if(t.text&&"string"==typeof e)return e;var r;if((r=e)&&"object"===w(r)&&r.isBuffer&&(e=e.buffer),e instanceof ArrayBuffer){var n=e;return t.text&&!t.binary?new TextDecoder("utf8").decode(n):n}if(ArrayBuffer.isView(e)){if(t.text&&!t.binary)return new TextDecoder("utf8").decode(e);var s=e.buffer,o=e.byteLength||e.length;return 0===e.byteOffset&&o===s.byteLength||(s=s.slice(e.byteOffset,e.byteOffset+o)),s}throw new Error(ew)}function iw(e,t,i){return rw.apply(this,arguments)}function rw(){return rw=a(s().mark(function e(t,i,r){var n,o;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t instanceof ArrayBuffer||ArrayBuffer.isView(t),"string"!=typeof t&&!n){e.next=3;break}return e.abrupt("return",tw(t,i));case 3:if(!Ry(t)){e.next=7;break}return e.next=6,zy(t);case 6:t=e.sent;case 7:if(!Dy(t)){e.next=21;break}return o=t,e.next=11,Ky(o);case 11:if(!i.binary){e.next=17;break}return e.next=14,o.arrayBuffer();case 14:e.t0=e.sent,e.next=20;break;case 17:return e.next=19,o.text();case 19:e.t0=e.sent;case 20:return e.abrupt("return",e.t0);case 21:if(Oy(t)&&(t=$b(t,r)),!Iy(t)&&!Fy(t)){e.next=24;break}return e.abrupt("return",xy(t));case 24:throw new Error(ew);case 25:case"end":return e.stop()}},e)})),rw.apply(this,arguments)}function nw(e,t){var i=Mb(),r=e||i;return"function"==typeof r.fetch?r.fetch:Sy(r.fetch)?function(e){return eb(e,r)}:null!=t&&t.fetch?null==t?void 0:t.fetch:eb}function sw(e,t,i){if(i)return i;var r,s,o=n({fetch:nw(t,e)},e);if(o.url){var a=Vy(o.url);o.baseUrl=a,o.queryString=function(e){var t=e.match(Ny);return t&&t[0]}(o.url),o.filename=ky(a),o.baseUrl=(s=(r=a)?r.lastIndexOf("/"):-1)>=0?r.substr(0,s):""}return Array.isArray(o.loaders)||(o.loaders=null),o}function ow(e,t){if(!t&&e&&!Array.isArray(e))return e;var i;if(e&&(i=Array.isArray(e)?e:[e]),t&&t.loaders){var r=Array.isArray(t.loaders)?t.loaders:[t.loaders];i=i?[].concat(l(i),l(r)):r}return i&&i.length?i:null}function aw(e,t,i,r){return lw.apply(this,arguments)}function lw(){return(lw=a(s().mark(function e(t,i,r,n){var o,a,l;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return Y_(!n||"object"===w(n)),!i||Array.isArray(i)||Ib(i)||(n=void 0,r=i,i=void 0),e.next=4,t;case 4:return t=e.sent,r=r||{},o=Qy(t),a=ow(i,n),e.next=11,Lb(t,a,r);case 11:if(l=e.sent){e.next=14;break}return e.abrupt("return",null);case 14:return r=kb(r,l,a,o),n=sw({url:o,parse:aw,loaders:a},r,n||null),e.next=18,uw(l,t,r,n);case 18:return e.abrupt("return",e.sent);case 19:case"end":return e.stop()}},e)}))).apply(this,arguments)}function uw(e,t,i,r){return cw.apply(this,arguments)}function cw(){return(cw=a(s().mark(function e(t,i,r,n){var o,a,l,u,c,h,A,d;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return gy(t),Dy(i)&&(a=(o=i).ok,l=o.redirected,u=o.status,c=o.statusText,h=o.type,A=o.url,d=Object.fromEntries(o.headers.entries()),n.response={headers:d,ok:a,redirected:l,status:u,statusText:c,type:h,url:A}),e.next=4,iw(i,t,r);case 4:if(i=e.sent,!t.parseTextSync||"string"!=typeof i){e.next=8;break}return r.dataType="text",e.abrupt("return",t.parseTextSync(i,r,n,t));case 8:if(!my(t,r)){e.next=12;break}return e.next=11,vy(t,i,r,n,aw);case 11:case 15:case 19:return e.abrupt("return",e.sent);case 12:if(!t.parseText||"string"!=typeof i){e.next=16;break}return e.next=15,t.parseText(i,r,n,t);case 16:if(!t.parse){e.next=20;break}return e.next=19,t.parse(i,r,n,t);case 20:throw Y_(!t.parseSync),new Error("".concat(t.id," loader - no parser found and worker is disabled"));case 22:case"end":return e.stop()}},e)}))).apply(this,arguments)}var hw={self:"undefined"!=typeof self&&self,window:"undefined"!=typeof window&&window,global:"undefined"!=typeof global&&global,document:"undefined"!=typeof document&&document},Aw=hw.global||hw.self||hw.window||{},dw="object"!==("undefined"==typeof process?"undefined":w(process))||"[object process]"!==String(process)||process.browser,pw="function"==typeof importScripts,fw="undefined"!=typeof process&&process.version&&/v([0-9]*)/.exec(process.version);fw&&parseFloat(fw[1]);var gw=null,mw=Object.freeze({__proto__:null,readFileAsArrayBuffer:null,readFileAsText:null,requireFromFile:gw,requireFromString:null}),vw={};function _w(e){return yw.apply(this,arguments)}function yw(){return yw=a(s().mark(function e(t){var i,r,n=arguments;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return r=n.length>2&&void 0!==n[2]?n[2]:{},(i=n.length>1&&void 0!==n[1]?n[1]:null)&&(t=bw(t,i,r)),vw[t]=vw[t]||ww(t),e.next=6,vw[t];case 6:return e.abrupt("return",e.sent);case 7:case"end":return e.stop()}},e)})),yw.apply(this,arguments)}function bw(e,t,i){if(e.startsWith("http"))return e;var r=i.modules||{};return r[e]?r[e]:dw?i.CDN?(function(e,t){if(!e)throw new Error(t||"loaders.gl assertion failed.")}(i.CDN.startsWith("http")),"".concat(i.CDN,"/").concat(t,"@").concat("3.4.15","/dist/libs/").concat(e)):pw?"../src/libs/".concat(e):"modules/".concat(t,"/src/libs/").concat(e):"modules/".concat(t,"/dist/libs/").concat(e)}function ww(e){return xw.apply(this,arguments)}function xw(){return(xw=a(s().mark(function e(t){var i,r,n;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!t.endsWith("wasm")){e.next=7;break}return e.next=3,fetch(t);case 3:return i=e.sent,e.next=6,i.arrayBuffer();case 6:return e.abrupt("return",e.sent);case 7:if(dw){e.next=20;break}if(e.prev=8,e.t0=mw&&gw,!e.t0){e.next=14;break}return e.next=13,gw(t);case 13:e.t0=e.sent;case 14:return e.abrupt("return",e.t0);case 17:return e.prev=17,e.t1=e.catch(8),e.abrupt("return",null);case 20:if(!pw){e.next=22;break}return e.abrupt("return",importScripts(t));case 22:return e.next=24,fetch(t);case 24:return r=e.sent,e.next=27,r.text();case 27:return n=e.sent,e.abrupt("return",Bw(n,t));case 29:case"end":return e.stop()}},e,null,[[8,17]])}))).apply(this,arguments)}function Bw(e,t){if(!dw)return null;if(pw)return eval.call(Aw,e),null;var i=document.createElement("script");i.id=t;try{i.appendChild(document.createTextNode(e))}catch(t){i.text=e}return document.body.appendChild(i),null}var Pw,Cw,Mw="3.4.15",kw="https://unpkg.com/@loaders.gl/textures@".concat(Mw,"/dist/libs/basis_encoder.wasm"),Ew="https://unpkg.com/@loaders.gl/textures@".concat(Mw,"/dist/libs/basis_encoder.js");function Sw(e){return Tw.apply(this,arguments)}function Tw(){return(Tw=a(s().mark(function e(t){var i;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!(i=t.modules||{}).basis){e.next=3;break}return e.abrupt("return",i.basis);case 3:return Pw=Pw||Iw(t),e.next=6,Pw;case 6:return e.abrupt("return",e.sent);case 7:case"end":return e.stop()}},e)}))).apply(this,arguments)}function Iw(e){return Fw.apply(this,arguments)}function Fw(){return(Fw=a(s().mark(function e(t){var i,r,n,o;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return i=null,r=null,e.t0=Promise,e.next=5,_w("basis_transcoder.js","textures",t);case 5:return e.t1=e.sent,e.next=8,_w("basis_transcoder.wasm","textures",t);case 8:return e.t2=e.sent,e.t3=[e.t1,e.t2],e.next=12,e.t0.all.call(e.t0,e.t3);case 12:return n=e.sent,o=c(n,2),i=o[0],r=o[1],i=i||globalThis.BASIS,e.next=19,Dw(i,r);case 19:return e.abrupt("return",e.sent);case 20:case"end":return e.stop()}},e)}))).apply(this,arguments)}function Dw(e,t){var i={};return t&&(i.wasmBinary=t),new Promise(function(t){e(i).then(function(e){var i=e.BasisFile;(0,e.initializeBasis)(),t({BasisFile:i})})})}function Rw(e){return Ow.apply(this,arguments)}function Ow(){return(Ow=a(s().mark(function e(t){var i;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!(i=t.modules||{}).basisEncoder){e.next=3;break}return e.abrupt("return",i.basisEncoder);case 3:return Cw=Cw||Lw(t),e.next=6,Cw;case 6:return e.abrupt("return",e.sent);case 7:case"end":return e.stop()}},e)}))).apply(this,arguments)}function Lw(e){return jw.apply(this,arguments)}function jw(){return(jw=a(s().mark(function e(t){var i,r,n,o;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return i=null,r=null,e.t0=Promise,e.next=5,_w(Ew,"textures",t);case 5:return e.t1=e.sent,e.next=8,_w(kw,"textures",t);case 8:return e.t2=e.sent,e.t3=[e.t1,e.t2],e.next=12,e.t0.all.call(e.t0,e.t3);case 12:return n=e.sent,o=c(n,2),i=o[0],r=o[1],i=i||globalThis.BASIS,e.next=19,Uw(i,r);case 19:return e.abrupt("return",e.sent);case 20:case"end":return e.stop()}},e)}))).apply(this,arguments)}function Uw(e,t){var i={};return t&&(i.wasmBinary=t),new Promise(function(t){e(i).then(function(e){var i=e.BasisFile,r=e.KTX2File,n=e.initializeBasis,s=e.BasisEncoder;n(),t({BasisFile:i,KTX2File:r,BasisEncoder:s})})})}var Nw,Vw,Qw,Hw,Gw,zw,Ww,Kw,Xw,qw=33776,Yw=33779,Jw=35840,Zw=35842,$w=36196,ex=37808,tx=["","WEBKIT_","MOZ_"],ix={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"},rx=null;function nx(e){if(!rx){e=e||function(){try{return document.createElement("canvas").getContext("webgl")}catch(e){return null}}()||void 0,rx=new Set;var t,i=u(tx);try{for(i.s();!(t=i.n()).done;){var r=t.value;for(var n in ix)if(e&&e.getExtension("".concat(r).concat(n))){var s=ix[n];rx.add(s)}}}catch(e){i.e(e)}finally{i.f()}}return rx}(Xw=Nw||(Nw={}))[Xw.NONE=0]="NONE",Xw[Xw.BASISLZ=1]="BASISLZ",Xw[Xw.ZSTD=2]="ZSTD",Xw[Xw.ZLIB=3]="ZLIB",function(e){e[e.BASICFORMAT=0]="BASICFORMAT"}(Vw||(Vw={})),function(e){e[e.UNSPECIFIED=0]="UNSPECIFIED",e[e.ETC1S=163]="ETC1S",e[e.UASTC=166]="UASTC"}(Qw||(Qw={})),function(e){e[e.UNSPECIFIED=0]="UNSPECIFIED",e[e.SRGB=1]="SRGB"}(Hw||(Hw={})),function(e){e[e.UNSPECIFIED=0]="UNSPECIFIED",e[e.LINEAR=1]="LINEAR",e[e.SRGB=2]="SRGB",e[e.ITU=3]="ITU",e[e.NTSC=4]="NTSC",e[e.SLOG=5]="SLOG",e[e.SLOG2=6]="SLOG2"}(Gw||(Gw={})),function(e){e[e.ALPHA_STRAIGHT=0]="ALPHA_STRAIGHT",e[e.ALPHA_PREMULTIPLIED=1]="ALPHA_PREMULTIPLIED"}(zw||(zw={})),function(e){e[e.RGB=0]="RGB",e[e.RRR=3]="RRR",e[e.GGG=4]="GGG",e[e.AAA=15]="AAA"}(Ww||(Ww={})),function(e){e[e.RGB=0]="RGB",e[e.RGBA=3]="RGBA",e[e.RRR=4]="RRR",e[e.RRRG=5]="RRRG"}(Kw||(Kw={}));var sx=[171,75,84,88,32,50,48,187,13,10,26,10];function ox(e){var t=new Uint8Array(e);return!(t.byteLength<sx.length||t[0]!==sx[0]||t[1]!==sx[1]||t[2]!==sx[2]||t[3]!==sx[3]||t[4]!==sx[4]||t[5]!==sx[5]||t[6]!==sx[6]||t[7]!==sx[7]||t[8]!==sx[8]||t[9]!==sx[9]||t[10]!==sx[10]||t[11]!==sx[11])}var ax={etc1:{basisFormat:0,compressed:!0,format:$w},etc2:{basisFormat:1,compressed:!0},bc1:{basisFormat:2,compressed:!0,format:qw},bc3:{basisFormat:3,compressed:!0,format:Yw},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:Jw},"pvrtc1-4-rgba":{basisFormat:9,compressed:!0,format:Zw},"astc-4x4":{basisFormat:10,compressed:!0,format:ex},"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}};function lx(){return(lx=a(s().mark(function e(t,i){var r,n,o,a,l,u;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if("auto"!==i.basis.containerFormat){e.next=11;break}if(!ox(t)){e.next=6;break}return e.next=4,Rw(i);case 4:return r=e.sent,e.abrupt("return",hx(r.KTX2File,t,i));case 6:return e.next=8,Sw(i);case 8:return n=e.sent,o=n.BasisFile,e.abrupt("return",ux(o,t,i));case 11:e.t0=i.basis.module,e.next="encoder"===e.t0?14:(e.t0,22);break;case 14:return e.next=16,Rw(i);case 16:a=e.sent,e.t1=i.basis.containerFormat,e.next="ktx2"===e.t1?20:(e.t1,21);break;case 20:return e.abrupt("return",hx(a.KTX2File,t,i));case 21:return e.abrupt("return",ux(a.BasisFile,t,i));case 22:return e.next=24,Sw(i);case 24:return l=e.sent,u=l.BasisFile,e.abrupt("return",ux(u,t,i));case 27:case"end":return e.stop()}},e)}))).apply(this,arguments)}function ux(e,t,i){var r=new e(new Uint8Array(t));try{if(!r.startTranscoding())throw new Error("Failed to start basis transcoding");for(var n=r.getNumImages(),s=[],o=0;o<n;o++){for(var a=r.getNumLevels(o),l=[],u=0;u<a;u++)l.push(cx(r,o,u,i));s.push(l)}return s}finally{r.close(),r.delete()}}function cx(e,t,i,r){var n=e.getImageWidth(t,i),s=e.getImageHeight(t,i),o=e.getHasAlpha(),a=dx(r,o),l=a.compressed,u=a.format,c=a.basisFormat,h=e.getImageTranscodedSizeInBytes(t,i,c),A=new Uint8Array(h);if(!e.transcodeImage(A,t,i,c,0,0))throw new Error("failed to start Basis transcoding");return{width:n,height:s,data:A,compressed:l,format:u,hasAlpha:o}}function hx(e,t,i){var r=new e(new Uint8Array(t));try{if(!r.startTranscoding())throw new Error("failed to start KTX2 transcoding");for(var n=r.getLevels(),s=[],o=0;o<n;o++){s.push(Ax(r,o,i));break}return[s]}finally{r.close(),r.delete()}}function Ax(e,t,i){var r=e.getImageLevelInfo(t,0,0),n=r.alphaFlag,s=r.height,o=r.width,a=dx(i,n),l=a.compressed,u=a.format,c=a.basisFormat,h=e.getImageTranscodedSizeInBytes(t,0,0,c),A=new Uint8Array(h);if(!e.transcodeImage(A,t,0,0,c,0,-1,-1))throw new Error("Failed to transcode KTX2 image");return{width:o,height:s,data:A,compressed:l,levelSize:h,hasAlpha:n,format:u}}function dx(e,t){var i=e&&e.basis&&e.basis.format;return"auto"===i&&(i=px()),"object"===w(i)&&(i=t?i.alpha:i.noAlpha),i=i.toLowerCase(),ax[i]}function px(){var e=nx();return e.has("astc")?"astc-4x4":e.has("dxt")?{alpha:"bc3",noAlpha:"bc1"}:e.has("pvrtc")?{alpha:"pvrtc1-4-rgba",noAlpha:"pvrtc1-4-rgb"}:e.has("etc1")?"etc1":e.has("etc2")?"etc2":"rgb565"}var fx=n(n({},{name:"Basis",id:dw?"basis":"basis-nodejs",module:"textures",version:"3.4.15",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"}}}),{},{parse:function(e,t){return lx.apply(this,arguments)}});function gx(e,t){if(!e)throw new Error(t||"loader assertion failed.")}var mx=Boolean("object"!==("undefined"==typeof process?"undefined":w(process))||"[object process]"!==String(process)||process.browser),vx="undefined"!=typeof process&&process.version&&/v([0-9]*)/.exec(process.version);vx&&parseFloat(vx[1]);var _x=globalThis._parseImageNode,yx="undefined"!=typeof Image,bx="undefined"!=typeof ImageBitmap,wx=Boolean(_x),xx=!!mx||wx;function Bx(e){var t=function(e){if("undefined"!=typeof ImageBitmap&&e instanceof ImageBitmap)return"imagebitmap";if("undefined"!=typeof Image&&e instanceof Image)return"image";if(e&&"object"===w(e)&&e.data&&e.width&&e.height)return"data";return null}(e);if(!t)throw new Error("Not an image");return t}function Px(e){switch(Bx(e)){case"data":return e;case"image":case"imagebitmap":var t=document.createElement("canvas"),i=t.getContext("2d");if(!i)throw new Error("getImageData");return t.width=e.width,t.height=e.height,i.drawImage(e,0,0),i.getImageData(0,0,e.width,e.height);default:throw new Error("getImageData")}}var Cx=/^data:image\/svg\+xml/,Mx=/\.svg((\?|#).*)?$/;function kx(e){return e&&(Cx.test(e)||Mx.test(e))}function Ex(e,t){if(kx(t)){var i=(new TextDecoder).decode(e);try{"function"==typeof unescape&&"function"==typeof encodeURIComponent&&(i=unescape(encodeURIComponent(i)))}catch(e){throw new Error(e.message)}return"data:image/svg+xml;base64,".concat(btoa(i))}return Sx(e,t)}function Sx(e,t){if(kx(t))throw new Error("SVG cannot be parsed directly to imagebitmap");return new Blob([new Uint8Array(e)])}function Tx(e,t,i){return Ix.apply(this,arguments)}function Ix(){return(Ix=a(s().mark(function e(t,i,r){var n,o,a;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return n=Ex(t,r),o=self.URL||self.webkitURL,a="string"!=typeof n&&o.createObjectURL(n),e.prev=3,e.next=6,Fx(a||n,i);case 6:return e.abrupt("return",e.sent);case 7:return e.prev=7,a&&o.revokeObjectURL(a),e.finish(7);case 10:case"end":return e.stop()}},e,null,[[3,,7,10]])}))).apply(this,arguments)}function Fx(e,t){return Dx.apply(this,arguments)}function Dx(){return Dx=a(s().mark(function e(t,i){var r;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if((r=new Image).src=t,!(i.image&&i.image.decode&&r.decode)){e.next=6;break}return e.next=5,r.decode();case 5:return e.abrupt("return",r);case 6:return e.next=8,new Promise(function(e,i){try{r.onload=function(){return e(r)},r.onerror=function(e){return i(new Error("Could not load image ".concat(t,": ").concat(e)))}}catch(e){i(e)}});case 8:return e.abrupt("return",e.sent);case 9:case"end":return e.stop()}},e)})),Dx.apply(this,arguments)}var Rx={},Ox=!0;function Lx(e,t,i){return jx.apply(this,arguments)}function jx(){return(jx=a(s().mark(function e(t,i,r){var n,o,a;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!kx(r)){e.next=7;break}return e.next=3,Tx(t,i,r);case 3:o=e.sent,n=o,e.next=8;break;case 7:n=Sx(t,r);case 8:return a=i&&i.imagebitmap,e.next=11,Ux(n,a);case 11:return e.abrupt("return",e.sent);case 12:case"end":return e.stop()}},e)}))).apply(this,arguments)}function Ux(e){return Nx.apply(this,arguments)}function Nx(){return Nx=a(s().mark(function e(t){var i,r=arguments;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!Vx(i=r.length>1&&void 0!==r[1]?r[1]:null)&&Ox||(i=null),!i){e.next=13;break}return e.prev=3,e.next=6,createImageBitmap(t,i);case 6:return e.abrupt("return",e.sent);case 9:e.prev=9,e.t0=e.catch(3),console.warn(e.t0),Ox=!1;case 13:return e.next=15,createImageBitmap(t);case 15:return e.abrupt("return",e.sent);case 16:case"end":return e.stop()}},e,null,[[3,9]])})),Nx.apply(this,arguments)}function Vx(e){for(var t in e||Rx)return!1;return!0}function Qx(e){return function(e,t){for(var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,r=(s=t,l(s).map(function(e){return e.charCodeAt(0)})),n=0;n<r.length;++n)if(r[n]!==e[n+i])return!1;var s;return!0}(e,"ftyp",4)&&96&e[8]?function(e){switch((t=e,i=8,r=12,String.fromCharCode.apply(String,l(t.slice(i,r)))).replace("\0"," ").trim()){case"avif":case"avis":return{extension:"avif",mimeType:"image/avif"};default:return null}var t,i,r}(e):null}var Hx=!1,Gx=!0;function zx(e){var t=Wx(e);return function(e){var t=Wx(e),i=t.byteLength>=24&&2303741511===t.getUint32(0,Hx);if(!i)return null;return{mimeType:"image/png",width:t.getUint32(16,Hx),height:t.getUint32(20,Hx)}}(t)||function(e){var t=Wx(e),i=t.byteLength>=3&&65496===t.getUint16(0,Hx)&&255===t.getUint8(2);if(!i)return null;var r=function(){for(var e=new Set([65499,65476,65484,65501,65534]),t=65504;t<65520;++t)e.add(t);var i=new Set([65472,65473,65474,65475,65477,65478,65479,65481,65482,65483,65485,65486,65487,65502]);return{tableMarkers:e,sofMarkers:i}}(),n=r.tableMarkers,s=r.sofMarkers,o=2;for(;o+9<t.byteLength;){var a=t.getUint16(o,Hx);if(s.has(a))return{mimeType:"image/jpeg",height:t.getUint16(o+5,Hx),width:t.getUint16(o+7,Hx)};if(!n.has(a))return null;o+=2,o+=t.getUint16(o,Hx)}return null}(t)||function(e){var t=Wx(e),i=t.byteLength>=10&&1195984440===t.getUint32(0,Hx);if(!i)return null;return{mimeType:"image/gif",width:t.getUint16(6,Gx),height:t.getUint16(8,Gx)}}(t)||function(e){var t=Wx(e),i=t.byteLength>=14&&16973===t.getUint16(0,Hx)&&t.getUint32(2,Gx)===t.byteLength;if(!i)return null;return{mimeType:"image/bmp",width:t.getUint32(18,Gx),height:t.getUint32(22,Gx)}}(t)||function(e){var t=new Uint8Array(e instanceof DataView?e.buffer:e),i=Qx(t);if(!i)return null;return{mimeType:i.mimeType,width:0,height:0}}(t)}function Wx(e){if(e instanceof DataView)return e;if(ArrayBuffer.isView(e))return new DataView(e.buffer);if(e instanceof ArrayBuffer)return new DataView(e);throw new Error("toDataView")}function Kx(e,t){return Xx.apply(this,arguments)}function Xx(){return Xx=a(s().mark(function e(t,i){var r,n,o;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return r=zx(t)||{},n=r.mimeType,gx(o=globalThis._parseImageNode),e.next=5,o(t,n);case 5:return e.abrupt("return",e.sent);case 6:case"end":return e.stop()}},e)})),Xx.apply(this,arguments)}function qx(){return(qx=a(s().mark(function e(t,i,r){var n,o,a,l,u;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:n=(i=i||{}).image||{},o=n.type||"auto",a=(r||{}).url,l=Yx(o),e.t0=l,e.next="imagebitmap"===e.t0?8:"image"===e.t0?12:"data"===e.t0?16:20;break;case 8:return e.next=10,Lx(t,i,a);case 10:return u=e.sent,e.abrupt("break",21);case 12:return e.next=14,Tx(t,i,a);case 14:return u=e.sent,e.abrupt("break",21);case 16:return e.next=18,Kx(t);case 18:return u=e.sent,e.abrupt("break",21);case 20:gx(!1);case 21:return"data"===o&&(u=Px(u)),e.abrupt("return",u);case 23:case"end":return e.stop()}},e)}))).apply(this,arguments)}function Yx(e){switch(e){case"auto":case"data":return function(){if(bx)return"imagebitmap";if(yx)return"image";if(xx)return"data";throw new Error("Install '@loaders.gl/polyfills' to parse images under Node.js")}();default:return function(e){switch(e){case"auto":return bx||yx||xx;case"imagebitmap":return bx;case"image":return yx;case"data":return xx;default:throw new Error("@loaders.gl/images: image ".concat(e," not supported in this environment"))}}(e),e}}var Jx={id:"image",module:"images",name:"Images",version:"3.4.15",mimeTypes:["image/png","image/jpeg","image/gif","image/webp","image/avif","image/bmp","image/vnd.microsoft.icon","image/svg+xml"],extensions:["png","jpg","jpeg","gif","webp","bmp","ico","svg","avif"],parse:function(e,t,i){return qx.apply(this,arguments)},tests:[function(e){return Boolean(zx(new DataView(e)))}],options:{image:{type:"auto",decode:!0}}},Zx={};function $x(e){if(void 0===Zx[e]){var t=mx?function(e){switch(e){case"image/avif":case"image/webp":return function(e){try{return 0===document.createElement("canvas").toDataURL(e).indexOf("data:".concat(e))}catch(e){return!1}}(e);default:return!0}}(e):function(e){var t=["image/png","image/jpeg","image/gif"],i=globalThis._parseImageNode,r=globalThis._imageFormatsNode,n=void 0===r?t:r;return Boolean(i)&&n.includes(e)}(e);Zx[e]=t}return Zx[e]}function eB(e,t){if(!e)throw new Error(t||"loader assertion failed.")}function tB(e,t,i){if(e.byteLength<=t+i)return"";for(var r=new DataView(e),n="",s=0;s<i;s++)n+=String.fromCharCode(r.getUint8(t+s));return n}function iB(e){try{return JSON.parse(e)}catch(t){throw new Error('Failed to parse JSON from data starting with "'.concat(function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:5;if("string"==typeof e)return e.slice(0,t);if(ArrayBuffer.isView(e))return tB(e.buffer,e.byteOffset,t);if(e instanceof ArrayBuffer)return tB(e,0,t);return""}(e),'"'))}}function rB(e,t,i){var r=void 0!==i?new Uint8Array(e).subarray(t,t+i):new Uint8Array(e).subarray(t);return new Uint8Array(r).buffer}function nB(e,t){return eB(e>=0),eB(t>0),e+(t-1)&~(t-1)}function sB(e,t,i){var r;if(e instanceof ArrayBuffer)r=new Uint8Array(e);else{var n=e.byteOffset,s=e.byteLength;r=new Uint8Array(e.buffer||e.arrayBuffer,n,s)}return t.set(r,i),i+nB(r.byteLength,4)}function oB(e,t){if(!e)throw new Error(t||"assert failed: gltf")}function aB(e,t){if(e.startsWith("data:")||e.startsWith("http:")||e.startsWith("https:"))return e;var i=t.baseUri||t.uri;if(!i)throw new Error("'baseUri' must be provided to resolve relative url ".concat(e));return i.substr(0,i.lastIndexOf("/")+1)+e}function lB(e,t,i){var r=e.bufferViews[i];oB(r);var n=t[r.buffer];oB(n);var s=(r.byteOffset||0)+n.byteOffset;return new Uint8Array(n.arrayBuffer,s,r.byteLength)}var uB=["SCALAR","VEC2","VEC3","VEC4"],cB=[[Int8Array,5120],[Uint8Array,5121],[Int16Array,5122],[Uint16Array,5123],[Uint32Array,5125],[Float32Array,5126],[Float64Array,5130]],hB=new Map(cB),AB={SCALAR:1,VEC2:2,VEC3:3,VEC4:4,MAT2:4,MAT3:9,MAT4:16},dB={5120:1,5121:1,5122:2,5123:2,5125:4,5126:4},pB={5120:Int8Array,5121:Uint8Array,5122:Int16Array,5123:Uint16Array,5125:Uint32Array,5126:Float32Array};function fB(e){return uB[e-1]||uB[0]}function gB(e){var t=hB.get(e.constructor);if(!t)throw new Error("Illegal typed array");return t}function mB(e,t){var i=pB[e.componentType],r=AB[e.type],n=dB[e.componentType],s=e.count*r,o=e.count*r*n;return oB(o>=0&&o<=t.byteLength),{ArrayType:i,length:s,byteLength:o}}var vB,_B={asset:{version:"2.0",generator:"loaders.gl"},buffers:[]},yB=function(){return P(function e(t){x(this,e),iy(this,"gltf",void 0),iy(this,"sourceBuffers",void 0),iy(this,"byteLength",void 0),this.gltf=t||{json:n({},_B),buffers:[]},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]])},[{key:"json",get:function(){return this.gltf.json}},{key:"getApplicationData",value:function(e){return this.json[e]}},{key:"getExtraData",value:function(e){return(this.json.extras||{})[e]}},{key:"getExtension",value:function(e){var t=this.getUsedExtensions().find(function(t){return t===e}),i=this.json.extensions||{};return t?i[e]||!0:null}},{key:"getRequiredExtension",value:function(e){var t=this.getRequiredExtensions().find(function(t){return t===e});return t?this.getExtension(e):null}},{key:"getRequiredExtensions",value:function(){return this.json.extensionsRequired||[]}},{key:"getUsedExtensions",value:function(){return this.json.extensionsUsed||[]}},{key:"getRemovedExtensions",value:function(){return this.json.extensionsRemoved||[]}},{key:"getObjectExtension",value:function(e,t){return(e.extensions||{})[t]}},{key:"getScene",value:function(e){return this.getObject("scenes",e)}},{key:"getNode",value:function(e){return this.getObject("nodes",e)}},{key:"getSkin",value:function(e){return this.getObject("skins",e)}},{key:"getMesh",value:function(e){return this.getObject("meshes",e)}},{key:"getMaterial",value:function(e){return this.getObject("materials",e)}},{key:"getAccessor",value:function(e){return this.getObject("accessors",e)}},{key:"getTexture",value:function(e){return this.getObject("textures",e)}},{key:"getSampler",value:function(e){return this.getObject("samplers",e)}},{key:"getImage",value:function(e){return this.getObject("images",e)}},{key:"getBufferView",value:function(e){return this.getObject("bufferViews",e)}},{key:"getBuffer",value:function(e){return this.getObject("buffers",e)}},{key:"getObject",value:function(e,t){if("object"===w(t))return t;var i=this.json[e]&&this.json[e][t];if(!i)throw new Error("glTF file error: Could not find ".concat(e,"[").concat(t,"]"));return i}},{key:"getTypedArrayForBufferView",value:function(e){var t=(e=this.getBufferView(e)).buffer,i=this.gltf.buffers[t];oB(i);var r=(e.byteOffset||0)+i.byteOffset;return new Uint8Array(i.arrayBuffer,r,e.byteLength)}},{key:"getTypedArrayForAccessor",value:function(e){e=this.getAccessor(e);var t=this.getBufferView(e.bufferView),i=this.getBuffer(t.buffer).data,r=mB(e,t),n=r.ArrayType,s=r.length;return new n(i,t.byteOffset+e.byteOffset,s)}},{key:"getTypedArrayForImageData",value:function(e){e=this.getAccessor(e);var t=this.getBufferView(e.bufferView),i=this.getBuffer(t.buffer).data,r=t.byteOffset||0;return new Uint8Array(i,r,t.byteLength)}},{key:"addApplicationData",value:function(e,t){return this.json[e]=t,this}},{key:"addExtraData",value:function(e,t){return this.json.extras=this.json.extras||{},this.json.extras[e]=t,this}},{key:"addObjectExtension",value:function(e,t,i){return e.extensions=e.extensions||{},e.extensions[t]=i,this.registerUsedExtension(t),this}},{key:"setObjectExtension",value:function(e,t,i){(e.extensions||{})[t]=i}},{key:"removeObjectExtension",value:function(e,t){var i=e.extensions||{},r=i[t];return delete i[t],r}},{key:"addExtension",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return oB(t),this.json.extensions=this.json.extensions||{},this.json.extensions[e]=t,this.registerUsedExtension(e),t}},{key:"addRequiredExtension",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return oB(t),this.addExtension(e,t),this.registerRequiredExtension(e),t}},{key:"registerUsedExtension",value:function(e){this.json.extensionsUsed=this.json.extensionsUsed||[],this.json.extensionsUsed.find(function(t){return t===e})||this.json.extensionsUsed.push(e)}},{key:"registerRequiredExtension",value:function(e){this.registerUsedExtension(e),this.json.extensionsRequired=this.json.extensionsRequired||[],this.json.extensionsRequired.find(function(t){return t===e})||this.json.extensionsRequired.push(e)}},{key:"removeExtension",value:function(e){if(this.getExtension(e)){this.json.extensionsRequired&&this._removeStringFromArray(this.json.extensionsRequired,e),this.json.extensionsUsed&&this._removeStringFromArray(this.json.extensionsUsed,e),this.json.extensions&&delete this.json.extensions[e],Array.isArray(this.json.extensionsRemoved)||(this.json.extensionsRemoved=[]);var t=this.json.extensionsRemoved;t.includes(e)||t.push(e)}}},{key:"setDefaultScene",value:function(e){this.json.scene=e}},{key:"addScene",value:function(e){var t=e.nodeIndices;return this.json.scenes=this.json.scenes||[],this.json.scenes.push({nodes:t}),this.json.scenes.length-1}},{key:"addNode",value:function(e){var t=e.meshIndex,i=e.matrix;this.json.nodes=this.json.nodes||[];var r={mesh:t};return i&&(r.matrix=i),this.json.nodes.push(r),this.json.nodes.length-1}},{key:"addMesh",value:function(e){var t=e.attributes,i=e.indices,r=e.material,n=e.mode,s=void 0===n?4:n,o={primitives:[{attributes:this._addAttributes(t),mode:s}]};if(i){var a=this._addIndices(i);o.primitives[0].indices=a}return Number.isFinite(r)&&(o.primitives[0].material=r),this.json.meshes=this.json.meshes||[],this.json.meshes.push(o),this.json.meshes.length-1}},{key:"addPointCloud",value:function(e){var t={primitives:[{attributes:this._addAttributes(e),mode:0}]};return this.json.meshes=this.json.meshes||[],this.json.meshes.push(t),this.json.meshes.length-1}},{key:"addImage",value:function(e,t){var i=zx(e),r=t||(null==i?void 0:i.mimeType),n={bufferView:this.addBufferView(e),mimeType:r};return this.json.images=this.json.images||[],this.json.images.push(n),this.json.images.length-1}},{key:"addBufferView",value:function(e){var t=e.byteLength;oB(Number.isFinite(t)),this.sourceBuffers=this.sourceBuffers||[],this.sourceBuffers.push(e);var i={buffer:0,byteOffset:this.byteLength,byteLength:t};return this.byteLength+=nB(t,4),this.json.bufferViews=this.json.bufferViews||[],this.json.bufferViews.push(i),this.json.bufferViews.length-1}},{key:"addAccessor",value:function(e,t){var i={bufferView:e,type:fB(t.size),componentType:t.componentType,count:t.count,max:t.max,min:t.min};return this.json.accessors=this.json.accessors||[],this.json.accessors.push(i),this.json.accessors.length-1}},{key:"addBinaryBuffer",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{size:3},i=this.addBufferView(e),r={min:t.min,max:t.max};r.min&&r.max||(r=this._getAccessorMinMax(e,t.size));var n={size:t.size,componentType:gB(e),count:Math.round(e.length/t.size),min:r.min,max:r.max};return this.addAccessor(i,Object.assign(n,t))}},{key:"addTexture",value:function(e){var t={source:e.imageIndex};return this.json.textures=this.json.textures||[],this.json.textures.push(t),this.json.textures.length-1}},{key:"addMaterial",value:function(e){return this.json.materials=this.json.materials||[],this.json.materials.push(e),this.json.materials.length-1}},{key:"createBinaryChunk",value:function(){var e,t;this.gltf.buffers=[];var i,r=this.byteLength,n=new ArrayBuffer(r),s=new Uint8Array(n),o=0,a=u(this.sourceBuffers||[]);try{for(a.s();!(i=a.n()).done;){o=sB(i.value,s,o)}}catch(e){a.e(e)}finally{a.f()}null!==(e=this.json)&&void 0!==e&&null!==(t=e.buffers)&&void 0!==t&&t[0]?this.json.buffers[0].byteLength=r:this.json.buffers=[{byteLength:r}],this.gltf.binary=n,this.sourceBuffers=[n]}},{key:"_removeStringFromArray",value:function(e,t){for(var i=!0;i;){var r=e.indexOf(t);r>-1?e.splice(r,1):i=!1}}},{key:"_addAttributes",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t={};for(var i in e){var r=e[i],n=this._getGltfAttributeName(i),s=this.addBinaryBuffer(r.value,r);t[n]=s}return t}},{key:"_addIndices",value:function(e){return this.addBinaryBuffer(e,{size:1})}},{key:"_getGltfAttributeName",value:function(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}}},{key:"_getAccessorMinMax",value:function(e,t){var i={min:null,max:null};if(e.length<t)return i;i.min=[],i.max=[];var r,n=u(e.subarray(0,t));try{for(n.s();!(r=n.n()).done;){var s=r.value;i.min.push(s),i.max.push(s)}}catch(e){n.e(e)}finally{n.f()}for(var o=t;o<e.length;o+=t)for(var a=0;a<t;a++)i.min[0+a]=Math.min(i.min[0+a],e[o+a]),i.max[0+a]=Math.max(i.max[0+a],e[o+a]);return i}}])}(),bB=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]),wB=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]),xB={0:"",1:"meshopt_decodeFilterOct",2:"meshopt_decodeFilterQuat",3:"meshopt_decodeFilterExp",NONE:"",OCTAHEDRAL:"meshopt_decodeFilterOct",QUATERNION:"meshopt_decodeFilterQuat",EXPONENTIAL:"meshopt_decodeFilterExp"},BB={0:"meshopt_decodeVertexBuffer",1:"meshopt_decodeIndexBuffer",2:"meshopt_decodeIndexSequence",ATTRIBUTES:"meshopt_decodeVertexBuffer",TRIANGLES:"meshopt_decodeIndexBuffer",INDICES:"meshopt_decodeIndexSequence"};function PB(e,t,i,r,n){return CB.apply(this,arguments)}function CB(){return CB=a(s().mark(function e(t,i,r,n,o){var a,l,u=arguments;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return a=u.length>5&&void 0!==u[5]?u[5]:"NONE",e.next=3,MB();case 3:IB(l=e.sent,l.exports[BB[o]],t,i,r,n,l.exports[xB[a||"NONE"]]);case 5:case"end":return e.stop()}},e)})),CB.apply(this,arguments)}function MB(){return kB.apply(this,arguments)}function kB(){return(kB=a(s().mark(function e(){return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return vB||(vB=EB()),e.abrupt("return",vB);case 2:case"end":return e.stop()}},e)}))).apply(this,arguments)}function EB(){return SB.apply(this,arguments)}function SB(){return(SB=a(s().mark(function e(){var t,i;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t="B9h9z9tFBBBF8fL9gBB9gLaaaaaFa9gEaaaB9gFaFa9gEaaaFaEMcBFFFGGGEIIILF9wFFFLEFBFKNFaFCx/IFMO/LFVK9tv9t9vq95GBt9f9f939h9z9t9f9j9h9s9s9f9jW9vq9zBBp9tv9z9o9v9wW9f9kv9j9v9kv9WvqWv94h919m9mvqBF8Z9tv9z9o9v9wW9f9kv9j9v9kv9J9u9kv94h919m9mvqBGy9tv9z9o9v9wW9f9kv9j9v9kv9J9u9kv949TvZ91v9u9jvBEn9tv9z9o9v9wW9f9kv9j9v9kv69p9sWvq9P9jWBIi9tv9z9o9v9wW9f9kv9j9v9kv69p9sWvq9R919hWBLn9tv9z9o9v9wW9f9kv9j9v9kv69p9sWvq9F949wBKI9z9iqlBOc+x8ycG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83EBABCNJAID8dFAGDBIBDyF+t+J83EBALAVANDQNVi8ZcMpySQ8c8dfb8e8fHND8dBAGDBIBDyG+t+J83EBABCiJAND8dFAGDBIBDyE+t+J83EBABCAJRBAECIJHEAF9JQBMMM/3FGEaF978jUUUUBCoBlREGXAGCGrAF9sHIC98ZHL9FQBCBRGABRFEXAFAFDBBBHKCND+rFCND+sFD/6FAKCiD+sFCnD+rFCUUU/8EDtD+uFD/mFDMBBAFCTJRFAGCIJHGAL9JQBMMGXALAI9PQBAEAICEZHGCGWHFqCBCoBAFl/8MBAEABALCGWJHLAF/8cBBGXAG9FQBAEAEDBIBHKCND+rFCND+sFD/6FAKCiD+sFCnD+rFCUUU/8EDtD+uFD/mFDMIBMALAEAF/8cBBMM9TFEaCBCB8oGUkUUBHFABCEJC98ZJHBjGUkUUBGXGXAB8/BCTWHGuQBCaREABAGlCggEJCTrXBCa6QFMAFREMAEMMMFBCUNMIT9tBB",console.log("Warning: meshopt_decoder is using experimental SIMD support")),e.next=4,WebAssembly.instantiate(TB(t),{});case 4:return i=e.sent,e.next=7,i.instance.exports.__wasm_call_ctors();case 7:return e.abrupt("return",i.instance);case 8:case"end":return e.stop()}},e)}))).apply(this,arguments)}function TB(e){for(var t=new Uint8Array(e.length),i=0;i<e.length;++i){var r=e.charCodeAt(i);t[i]=r>96?r-71:r>64?r-65:r>47?r+4:r>46?63:62}for(var n=0,s=0;s<e.length;++s)t[n++]=t[s]<60?wB[t[s]]:64*(t[s]-60)+t[++s];return t.buffer.slice(0,n)}function IB(e,t,i,r,n,s,o){var a=e.exports.sbrk,l=r+3&-4,u=a(l*n),c=a(s.length),h=new Uint8Array(e.exports.memory.buffer);h.set(s,c);var A=t(u,r,n,c,s.length);if(0===A&&o&&o(u,l,n),i.set(h.subarray(u,u+r*n)),a(u-a(0)),0!==A)throw new Error("Malformed buffer data: ".concat(A))}var FB="EXT_meshopt_compression",DB=FB;function RB(){return(RB=a(s().mark(function e(t,i){var r,n,o,a,l,c;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(n=new yB(t),null!=i&&null!==(r=i.gltf)&&void 0!==r&&r.decompressMeshes){e.next=3;break}return e.abrupt("return");case 3:o=[],a=u(t.json.bufferViews||[]);try{for(a.s();!(l=a.n()).done;)c=l.value,o.push(OB(n,c))}catch(e){a.e(e)}finally{a.f()}return e.next=8,Promise.all(o);case 8:n.removeExtension(FB);case 9:case"end":return e.stop()}},e)}))).apply(this,arguments)}function OB(e,t){return LB.apply(this,arguments)}function LB(){return(LB=a(s().mark(function e(t,i){var r,n,o,a,l,u,c,h,A,d,p,f,g,m;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!(r=t.getObjectExtension(i,FB))){e.next=9;break}return n=r.byteOffset,o=void 0===n?0:n,a=r.byteLength,l=void 0===a?0:a,u=r.byteStride,c=r.count,h=r.mode,A=r.filter,d=void 0===A?"NONE":A,p=r.buffer,f=t.gltf.buffers[p],g=new Uint8Array(f.arrayBuffer,f.byteOffset+o,l),m=new Uint8Array(t.gltf.buffers[i.buffer].arrayBuffer,i.byteOffset,i.byteLength),e.next=8,PB(m,c,u,g,h,d);case 8:return e.abrupt("return",m);case 9:return e.abrupt("return",null);case 10:case"end":return e.stop()}},e)}))).apply(this,arguments)}var jB=Object.freeze({__proto__:null,name:DB,decode:function(e,t){return RB.apply(this,arguments)}}),UB="EXT_texture_webp",NB=UB;var VB=Object.freeze({__proto__:null,name:NB,preprocess:function(e,t){var i=new yB(e);if($x("image/webp")){var r,n=u(i.json.textures||[]);try{for(n.s();!(r=n.n()).done;){var s=r.value,o=i.getObjectExtension(s,UB);o&&(s.source=o.source),i.removeObjectExtension(s,UB)}}catch(e){n.e(e)}finally{n.f()}i.removeExtension(UB)}else if(i.getRequiredExtensions().includes(UB))throw new Error("gltf: Required extension ".concat(UB," not supported by browser"))}}),QB="KHR_texture_basisu",HB=QB;var GB=Object.freeze({__proto__:null,name:HB,preprocess:function(e,t){var i,r=new yB(e),n=u(r.json.textures||[]);try{for(n.s();!(i=n.n()).done;){var s=i.value,o=r.getObjectExtension(s,QB);o&&(s.source=o.source),r.removeObjectExtension(s,QB)}}catch(e){n.e(e)}finally{n.f()}r.removeExtension(QB)}});var zB={self:"undefined"!=typeof self&&self,window:"undefined"!=typeof window&&window,global:"undefined"!=typeof global&&global,document:"undefined"!=typeof document&&document},WB=zB.global||zB.self||zB.window||{},KB="object"!==("undefined"==typeof process?"undefined":w(process))||"[object process]"!==String(process)||process.browser,XB="function"==typeof importScripts,qB="undefined"!=typeof process&&process.version&&/v([0-9]*)/.exec(process.version);qB&&parseFloat(qB[1]);var YB=null,JB=Object.freeze({__proto__:null,readFileAsArrayBuffer:null,readFileAsText:null,requireFromFile:YB,requireFromString:null}),ZB={};function $B(e){return eP.apply(this,arguments)}function eP(){return eP=a(s().mark(function e(t){var i,r,n=arguments;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return r=n.length>2&&void 0!==n[2]?n[2]:{},(i=n.length>1&&void 0!==n[1]?n[1]:null)&&(t=tP(t,i,r)),ZB[t]=ZB[t]||iP(t),e.next=6,ZB[t];case 6:return e.abrupt("return",e.sent);case 7:case"end":return e.stop()}},e)})),eP.apply(this,arguments)}function tP(e,t,i){if(e.startsWith("http"))return e;var r=i.modules||{};return r[e]?r[e]:KB?i.CDN?(function(e,t){if(!e)throw new Error(t||"loaders.gl assertion failed.")}(i.CDN.startsWith("http")),"".concat(i.CDN,"/").concat(t,"@").concat("3.4.15","/dist/libs/").concat(e)):XB?"../src/libs/".concat(e):"modules/".concat(t,"/src/libs/").concat(e):"modules/".concat(t,"/dist/libs/").concat(e)}function iP(e){return rP.apply(this,arguments)}function rP(){return(rP=a(s().mark(function e(t){var i,r,n;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!t.endsWith("wasm")){e.next=7;break}return e.next=3,fetch(t);case 3:return i=e.sent,e.next=6,i.arrayBuffer();case 6:return e.abrupt("return",e.sent);case 7:if(KB){e.next=20;break}if(e.prev=8,e.t0=JB&&YB,!e.t0){e.next=14;break}return e.next=13,YB(t);case 13:e.t0=e.sent;case 14:return e.abrupt("return",e.t0);case 17:return e.prev=17,e.t1=e.catch(8),e.abrupt("return",null);case 20:if(!XB){e.next=22;break}return e.abrupt("return",importScripts(t));case 22:return e.next=24,fetch(t);case 24:return r=e.sent,e.next=27,r.text();case 27:return n=e.sent,e.abrupt("return",nP(n,t));case 29:case"end":return e.stop()}},e,null,[[8,17]])}))).apply(this,arguments)}function nP(e,t){if(!KB)return null;if(XB)return eval.call(WB,e),null;var i=document.createElement("script");i.id=t;try{i.appendChild(document.createTextNode(e))}catch(t){i.text=e}return document.body.appendChild(i),null}var sP={draco:{decoderType:"object"===("undefined"==typeof WebAssembly?"undefined":w(WebAssembly))?"wasm":"js",libraryPath:"libs/",extraAttributes:{},attributeNameEntry:void 0}},oP={name:"Draco",id:KB?"draco":"draco-nodejs",module:"draco",shapes:["mesh"],version:"3.4.15",worker:!0,extensions:["drc"],mimeTypes:["application/octet-stream"],binary:!0,tests:["DRACO"],options:sP};var aP=function(){function e(t,i){x(this,e),iy(this,"fields",void 0),iy(this,"metadata",void 0),function(e,t){if(!e)throw new Error(t||"loader assertion failed.")}(Array.isArray(t)),function(e){var t,i={},r=u(e);try{for(r.s();!(t=r.n()).done;){var n=t.value;i[n.name]&&console.warn("Schema: duplicated field name",n.name,n),i[n.name]=!0}}catch(e){r.e(e)}finally{r.f()}}(t),this.fields=t,this.metadata=i||new Map}return P(e,[{key:"compareTo",value:function(e){if(this.metadata!==e.metadata)return!1;if(this.fields.length!==e.fields.length)return!1;for(var t=0;t<this.fields.length;++t)if(!this.fields[t].compareTo(e.fields[t]))return!1;return!0}},{key:"select",value:function(){for(var t=Object.create(null),i=arguments.length,r=new Array(i),n=0;n<i;n++)r[n]=arguments[n];for(var s=0,o=r;s<o.length;s++){var a=o[s];t[a]=!0}return new e(this.fields.filter(function(e){return t[e.name]}),this.metadata)}},{key:"selectAt",value:function(){for(var t=this,i=arguments.length,r=new Array(i),n=0;n<i;n++)r[n]=arguments[n];return new e(r.map(function(e){return t.fields[e]}).filter(Boolean),this.metadata)}},{key:"assign",value:function(t){var i,r=this.metadata;if(t instanceof e){var n=t;i=n.fields,r=lP(lP(new Map,this.metadata),n.metadata)}else i=t;var s,o=Object.create(null),a=u(this.fields);try{for(a.s();!(s=a.n()).done;){var l=s.value;o[l.name]=l}}catch(e){a.e(e)}finally{a.f()}var c,h=u(i);try{for(h.s();!(c=h.n()).done;){var A=c.value;o[A.name]=A}}catch(e){h.e(e)}finally{h.f()}return new e(Object.values(o),r)}}])}();function lP(e,t){return new Map([].concat(l(e||new Map),l(t||new Map)))}var uP=function(){function e(t,i){x(this,e);var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2],n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:new Map;iy(this,"name",void 0),iy(this,"type",void 0),iy(this,"nullable",void 0),iy(this,"metadata",void 0),this.name=t,this.type=i,this.nullable=r,this.metadata=n}return P(e,[{key:"typeId",get:function(){return this.type&&this.type.typeId}},{key:"clone",value:function(){return new e(this.name,this.type,this.nullable,this.metadata)}},{key:"compareTo",value:function(e){return this.name===e.name&&this.type===e.type&&this.nullable===e.nullable&&this.metadata===e.metadata}},{key:"toString",value:function(){return"".concat(this.type).concat(this.nullable?", nullable":"").concat(this.metadata?", metadata: ".concat(this.metadata):"")}}])}(),cP=function(e){return e[e.NONE=0]="NONE",e[e.Null=1]="Null",e[e.Int=2]="Int",e[e.Float=3]="Float",e[e.Binary=4]="Binary",e[e.Utf8=5]="Utf8",e[e.Bool=6]="Bool",e[e.Decimal=7]="Decimal",e[e.Date=8]="Date",e[e.Time=9]="Time",e[e.Timestamp=10]="Timestamp",e[e.Interval=11]="Interval",e[e.List=12]="List",e[e.Struct=13]="Struct",e[e.Union=14]="Union",e[e.FixedSizeBinary=15]="FixedSizeBinary",e[e.FixedSizeList=16]="FixedSizeList",e[e.Map=17]="Map",e[e.Dictionary=-1]="Dictionary",e[e.Int8=-2]="Int8",e[e.Int16=-3]="Int16",e[e.Int32=-4]="Int32",e[e.Int64=-5]="Int64",e[e.Uint8=-6]="Uint8",e[e.Uint16=-7]="Uint16",e[e.Uint32=-8]="Uint32",e[e.Uint64=-9]="Uint64",e[e.Float16=-10]="Float16",e[e.Float32=-11]="Float32",e[e.Float64=-12]="Float64",e[e.DateDay=-13]="DateDay",e[e.DateMillisecond=-14]="DateMillisecond",e[e.TimestampSecond=-15]="TimestampSecond",e[e.TimestampMillisecond=-16]="TimestampMillisecond",e[e.TimestampMicrosecond=-17]="TimestampMicrosecond",e[e.TimestampNanosecond=-18]="TimestampNanosecond",e[e.TimeSecond=-19]="TimeSecond",e[e.TimeMillisecond=-20]="TimeMillisecond",e[e.TimeMicrosecond=-21]="TimeMicrosecond",e[e.TimeNanosecond=-22]="TimeNanosecond",e[e.DenseUnion=-23]="DenseUnion",e[e.SparseUnion=-24]="SparseUnion",e[e.IntervalDayTime=-25]="IntervalDayTime",e[e.IntervalYearMonth=-26]="IntervalYearMonth",e}({}),hP=function(){return P(function e(){x(this,e)},[{key:"typeId",get:function(){return cP.NONE}},{key:"compareTo",value:function(e){return this===e}}],[{key:"isNull",value:function(e){return e&&e.typeId===cP.Null}},{key:"isInt",value:function(e){return e&&e.typeId===cP.Int}},{key:"isFloat",value:function(e){return e&&e.typeId===cP.Float}},{key:"isBinary",value:function(e){return e&&e.typeId===cP.Binary}},{key:"isUtf8",value:function(e){return e&&e.typeId===cP.Utf8}},{key:"isBool",value:function(e){return e&&e.typeId===cP.Bool}},{key:"isDecimal",value:function(e){return e&&e.typeId===cP.Decimal}},{key:"isDate",value:function(e){return e&&e.typeId===cP.Date}},{key:"isTime",value:function(e){return e&&e.typeId===cP.Time}},{key:"isTimestamp",value:function(e){return e&&e.typeId===cP.Timestamp}},{key:"isInterval",value:function(e){return e&&e.typeId===cP.Interval}},{key:"isList",value:function(e){return e&&e.typeId===cP.List}},{key:"isStruct",value:function(e){return e&&e.typeId===cP.Struct}},{key:"isUnion",value:function(e){return e&&e.typeId===cP.Union}},{key:"isFixedSizeBinary",value:function(e){return e&&e.typeId===cP.FixedSizeBinary}},{key:"isFixedSizeList",value:function(e){return e&&e.typeId===cP.FixedSizeList}},{key:"isMap",value:function(e){return e&&e.typeId===cP.Map}},{key:"isDictionary",value:function(e){return e&&e.typeId===cP.Dictionary}}])}(),AP=function(e,t){function i(e,t){var r;return x(this,i),iy(r=d(this,i),"isSigned",void 0),iy(r,"bitWidth",void 0),r.isSigned=e,r.bitWidth=t,r}return _(i,hP),P(i,[{key:"typeId",get:function(){return cP.Int}},{key:t,get:function(){return"Int"}},{key:"toString",value:function(){return"".concat(this.isSigned?"I":"Ui","nt").concat(this.bitWidth)}}])}(0,Symbol.toStringTag),dP=function(){function e(){return x(this,e),d(this,e,[!0,8])}return _(e,AP),P(e)}(),pP=function(){function e(){return x(this,e),d(this,e,[!0,16])}return _(e,AP),P(e)}(),fP=function(){function e(){return x(this,e),d(this,e,[!0,32])}return _(e,AP),P(e)}(),gP=function(){function e(){return x(this,e),d(this,e,[!1,8])}return _(e,AP),P(e)}(),mP=function(){function e(){return x(this,e),d(this,e,[!1,16])}return _(e,AP),P(e)}(),vP=function(){function e(){return x(this,e),d(this,e,[!1,32])}return _(e,AP),P(e)}(),_P=32,yP=64,bP=function(e,t){function i(e){var t;return x(this,i),iy(t=d(this,i),"precision",void 0),t.precision=e,t}return _(i,hP),P(i,[{key:"typeId",get:function(){return cP.Float}},{key:t,get:function(){return"Float"}},{key:"toString",value:function(){return"Float".concat(this.precision)}}])}(0,Symbol.toStringTag),wP=function(){function e(){return x(this,e),d(this,e,[_P])}return _(e,bP),P(e)}(),xP=function(){function e(){return x(this,e),d(this,e,[yP])}return _(e,bP),P(e)}(),BP=function(e,t){function i(e,t){var r;return x(this,i),iy(r=d(this,i),"listSize",void 0),iy(r,"children",void 0),r.listSize=e,r.children=[t],r}return _(i,hP),P(i,[{key:"typeId",get:function(){return cP.FixedSizeList}},{key:"valueType",get:function(){return this.children[0].type}},{key:"valueField",get:function(){return this.children[0]}},{key:t,get:function(){return"FixedSizeList"}},{key:"toString",value:function(){return"FixedSizeList[".concat(this.listSize,"]<").concat(this.valueType,">")}}])}(0,Symbol.toStringTag);function PP(e,t,i){var r=function(e){switch(e.constructor){case Int8Array:return new dP;case Uint8Array:return new gP;case Int16Array:return new pP;case Uint16Array:return new mP;case Int32Array:return new fP;case Uint32Array:return new vP;case Float32Array:return new wP;case Float64Array:return new xP;default:throw new Error("array type not supported")}}(t.value),n=i||function(e){var t=new Map;"byteOffset"in e&&t.set("byteOffset",e.byteOffset.toString(10));"byteStride"in e&&t.set("byteStride",e.byteStride.toString(10));"normalized"in e&&t.set("normalized",e.normalized.toString());return t}(t);return new uP(e,new BP(t.size,new uP("value",r)),!1,n)}function CP(e,t,i){return PP(e,t,i?MP(i.metadata):void 0)}function MP(e){var t=new Map;for(var i in e)t.set("".concat(i,".string"),JSON.stringify(e[i]));return t}var kP={POSITION:"POSITION",NORMAL:"NORMAL",COLOR:"COLOR_0",TEX_COORD:"TEXCOORD_0"},EP={1:Int8Array,2:Uint8Array,3:Int16Array,4:Uint16Array,5:Int32Array,6:Uint32Array,9:Float32Array},SP=function(){return P(function e(t){x(this,e),iy(this,"draco",void 0),iy(this,"decoder",void 0),iy(this,"metadataQuerier",void 0),this.draco=t,this.decoder=new this.draco.Decoder,this.metadataQuerier=new this.draco.MetadataQuerier},[{key:"destroy",value:function(){this.draco.destroy(this.decoder),this.draco.destroy(this.metadataQuerier)}},{key:"parseSync",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=new this.draco.DecoderBuffer;i.Init(new Int8Array(e),e.byteLength),this._disableAttributeTransforms(t);var r=this.decoder.GetEncodedGeometryType(i),s=r===this.draco.TRIANGULAR_MESH?new this.draco.Mesh:new this.draco.PointCloud;try{var o;switch(r){case this.draco.TRIANGULAR_MESH:o=this.decoder.DecodeBufferToMesh(i,s);break;case this.draco.POINT_CLOUD:o=this.decoder.DecodeBufferToPointCloud(i,s);break;default:throw new Error("DRACO: Unknown geometry type.")}if(!o.ok()||!s.ptr){var a="DRACO decompression failed: ".concat(o.error_msg());throw new Error(a)}var l=this._getDracoLoaderData(s,r,t),u=this._getMeshData(s,l,t),c=function(e){for(var t=1/0,i=1/0,r=1/0,n=-1/0,s=-1/0,o=-1/0,a=e.POSITION?e.POSITION.value:[],l=a&&a.length,u=0;u<l;u+=3){var c=a[u],h=a[u+1],A=a[u+2];t=c<t?c:t,i=h<i?h:i,r=A<r?A:r,n=c>n?c:n,s=h>s?h:s,o=A>o?A:o}return[[t,i,r],[n,s,o]]}(u.attributes),h=function(e,t,i){var r=MP(t.metadata),n=[],s=function(e){var t={};for(var i in e){var r=e[i];t[r.name||"undefined"]=r}return t}(t.attributes);for(var o in e){var a=CP(o,e[o],s[o]);n.push(a)}if(i){var l=CP("indices",i);n.push(l)}return new aP(n,r)}(u.attributes,l,u.indices);return n(n({loader:"draco",loaderData:l,header:{vertexCount:s.num_points(),boundingBox:c}},u),{},{schema:h})}finally{this.draco.destroy(i),s&&this.draco.destroy(s)}}},{key:"_getDracoLoaderData",value:function(e,t,i){var r=this._getTopLevelMetadata(e),n=this._getDracoAttributes(e,i);return{geometry_type:t,num_attributes:e.num_attributes(),num_points:e.num_points(),num_faces:e instanceof this.draco.Mesh?e.num_faces():0,metadata:r,attributes:n}}},{key:"_getDracoAttributes",value:function(e,t){for(var i={},r=0;r<e.num_attributes();r++){var n=this.decoder.GetAttribute(e,r),s=this._getAttributeMetadata(e,r);i[n.unique_id()]={unique_id:n.unique_id(),attribute_type:n.attribute_type(),data_type:n.data_type(),num_components:n.num_components(),byte_offset:n.byte_offset(),byte_stride:n.byte_stride(),normalized:n.normalized(),attribute_index:r,metadata:s};var o=this._getQuantizationTransform(n,t);o&&(i[n.unique_id()].quantization_transform=o);var a=this._getOctahedronTransform(n,t);a&&(i[n.unique_id()].octahedron_transform=a)}return i}},{key:"_getMeshData",value:function(e,t,i){var r=this._getMeshAttributes(t,e,i);if(!r.POSITION)throw new Error("DRACO: No position attribute found.");return e instanceof this.draco.Mesh?"triangle-strip"===i.topology?{topology:"triangle-strip",mode:4,attributes:r,indices:{value:this._getTriangleStripIndices(e),size:1}}:{topology:"triangle-list",mode:5,attributes:r,indices:{value:this._getTriangleListIndices(e),size:1}}:{topology:"point-list",mode:0,attributes:r}}},{key:"_getMeshAttributes",value:function(e,t,i){for(var r={},n=0,s=Object.values(e.attributes);n<s.length;n++){var o=s[n],a=this._deduceAttributeName(o,i);o.name=a;var l=this._getAttributeValues(t,o),u=l.value,c=l.size;r[a]={value:u,size:c,byteOffset:o.byte_offset,byteStride:o.byte_stride,normalized:o.normalized}}return r}},{key:"_getTriangleListIndices",value:function(e){var t=3*e.num_faces(),i=4*t,r=this.draco._malloc(i);try{return this.decoder.GetTrianglesUInt32Array(e,i,r),new Uint32Array(this.draco.HEAPF32.buffer,r,t).slice()}finally{this.draco._free(r)}}},{key:"_getTriangleStripIndices",value:function(e){var t=new this.draco.DracoInt32Array;try{return this.decoder.GetTriangleStripsFromMesh(e,t),function(e){for(var t=e.size(),i=new Int32Array(t),r=0;r<t;r++)i[r]=e.GetValue(r);return i}(t)}finally{this.draco.destroy(t)}}},{key:"_getAttributeValues",value:function(e,t){var i,r=EP[t.data_type],n=t.num_components,s=e.num_points()*n,o=s*r.BYTES_PER_ELEMENT,a=function(e,t){switch(t){case Float32Array:return e.DT_FLOAT32;case Int8Array:return e.DT_INT8;case Int16Array:return e.DT_INT16;case Int32Array:return e.DT_INT32;case Uint8Array:return e.DT_UINT8;case Uint16Array:return e.DT_UINT16;case Uint32Array:return e.DT_UINT32;default:return e.DT_INVALID}}(this.draco,r),l=this.draco._malloc(o);try{var u=this.decoder.GetAttribute(e,t.attribute_index);this.decoder.GetAttributeDataArrayForAllPoints(e,u,a,o,l),i=new r(this.draco.HEAPF32.buffer,l,s).slice()}finally{this.draco._free(l)}return{value:i,size:n}}},{key:"_deduceAttributeName",value:function(e,t){for(var i=e.unique_id,r=0,n=Object.entries(t.extraAttributes||{});r<n.length;r++){var s=c(n[r],2),o=s[0];if(s[1]===i)return o}var a=e.attribute_type;for(var l in kP){if(this.draco[l]===a)return kP[l]}var u=t.attributeNameEntry||"name";return e.metadata[u]?e.metadata[u].string:"CUSTOM_ATTRIBUTE_".concat(i)}},{key:"_getTopLevelMetadata",value:function(e){var t=this.decoder.GetMetadata(e);return this._getDracoMetadata(t)}},{key:"_getAttributeMetadata",value:function(e,t){var i=this.decoder.GetAttributeMetadata(e,t);return this._getDracoMetadata(i)}},{key:"_getDracoMetadata",value:function(e){if(!e||!e.ptr)return{};for(var t={},i=this.metadataQuerier.NumEntries(e),r=0;r<i;r++){var n=this.metadataQuerier.GetEntryName(e,r);t[n]=this._getDracoMetadataField(e,n)}return t}},{key:"_getDracoMetadataField",value:function(e,t){var i=new this.draco.DracoInt32Array;try{this.metadataQuerier.GetIntEntryArray(e,t,i);var r=function(e){for(var t=e.size(),i=new Int32Array(t),r=0;r<t;r++)i[r]=e.GetValue(r);return i}(i);return{int:this.metadataQuerier.GetIntEntry(e,t),string:this.metadataQuerier.GetStringEntry(e,t),double:this.metadataQuerier.GetDoubleEntry(e,t),intArray:r}}finally{this.draco.destroy(i)}}},{key:"_disableAttributeTransforms",value:function(e){var t,i=e.quantizedAttributes,r=void 0===i?[]:i,n=e.octahedronAttributes,s=void 0===n?[]:n,o=u([].concat(l(r),l(s)));try{for(o.s();!(t=o.n()).done;){var a=t.value;this.decoder.SkipAttributeTransform(this.draco[a])}}catch(e){o.e(e)}finally{o.f()}}},{key:"_getQuantizationTransform",value:function(e,t){var i=this,r=t.quantizedAttributes,n=void 0===r?[]:r,s=e.attribute_type();if(n.map(function(e){return i.decoder[e]}).includes(s)){var o=new this.draco.AttributeQuantizationTransform;try{if(o.InitFromAttribute(e))return{quantization_bits:o.quantization_bits(),range:o.range(),min_values:new Float32Array([1,2,3]).map(function(e){return o.min_value(e)})}}finally{this.draco.destroy(o)}}return null}},{key:"_getOctahedronTransform",value:function(e,t){var i=this,r=t.octahedronAttributes,n=void 0===r?[]:r,s=e.attribute_type();if(n.map(function(e){return i.decoder[e]}).includes(s)){var o=new this.draco.AttributeQuantizationTransform;try{if(o.InitFromAttribute(e))return{quantization_bits:o.quantization_bits()}}finally{this.draco.destroy(o)}}return null}}])}();var TP,IP="https://www.gstatic.com/draco/versioned/decoders/".concat("1.5.5"),FP="".concat(IP,"/draco_decoder.js"),DP="".concat(IP,"/draco_wasm_wrapper.js"),RP="".concat(IP,"/draco_decoder.wasm");function OP(e){return LP.apply(this,arguments)}function LP(){return(LP=a(s().mark(function e(t){var i;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return i=t.modules||{},TP=i.draco3d?TP||i.draco3d.createDecoderModule({}).then(function(e){return{draco:e}}):TP||jP(t),e.next=4,TP;case 4:return e.abrupt("return",e.sent);case 5:case"end":return e.stop()}},e)}))).apply(this,arguments)}function jP(e){return UP.apply(this,arguments)}function UP(){return(UP=a(s().mark(function e(t){var i,r,n,o;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:e.t0=t.draco&&t.draco.decoderType,e.next="js"===e.t0?3:(e.t0,7);break;case 3:return e.next=5,$B(FP,"draco",t);case 5:return i=e.sent,e.abrupt("break",21);case 7:return e.t1=Promise,e.next=10,$B(DP,"draco",t);case 10:return e.t2=e.sent,e.next=13,$B(RP,"draco",t);case 13:return e.t3=e.sent,e.t4=[e.t2,e.t3],e.next=17,e.t1.all.call(e.t1,e.t4);case 17:n=e.sent,o=c(n,2),i=o[0],r=o[1];case 21:return i=i||globalThis.DracoDecoderModule,e.next=24,NP(i,r);case 24:return e.abrupt("return",e.sent);case 25:case"end":return e.stop()}},e)}))).apply(this,arguments)}function NP(e,t){var i={};return t&&(i.wasmBinary=t),new Promise(function(t){e(n(n({},i),{},{onModuleLoaded:function(e){return t({draco:e})}}))})}var VP=n(n({},oP),{},{parse:function(e,t){return QP.apply(this,arguments)}});function QP(){return(QP=a(s().mark(function e(t,i){var r,n,o;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,OP(i);case 2:return r=e.sent,n=r.draco,o=new SP(n),e.prev=5,e.abrupt("return",o.parseSync(t,null==i?void 0:i.draco));case 7:return e.prev=7,o.destroy(),e.finish(7);case 10:case"end":return e.stop()}},e,null,[[5,,7,10]])}))).apply(this,arguments)}function HP(e){var t={};for(var i in e){var r=e[i];if("indices"!==i){var n=GP(r);t[i]=n}}return t}function GP(e){var t=function(e){var t=e,i=1,r=0;e&&e.value&&(t=e.value,i=e.size||1);t&&(ArrayBuffer.isView(t)||(t=function(e,t){var i=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(!e)return null;if(Array.isArray(e))return new t(e);if(i&&!(e instanceof t))return new t(e);return e}(t,Float32Array)),r=t.length/i);return{buffer:t,size:i,count:r}}(e),i=t.buffer,r=t.size;return{value:i,size:r,byteOffset:0,count:t.count,type:fB(r),componentType:gB(i)}}var zP="KHR_draco_mesh_compression",WP=zP;function KP(){return(KP=a(s().mark(function e(t,i,r){var n,o,a,l,c,h;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(null!=i&&null!==(n=i.gltf)&&void 0!==n&&n.decompressMeshes){e.next=2;break}return e.abrupt("return");case 2:o=new yB(t),a=[],l=u(ZP(o));try{for(l.s();!(c=l.n()).done;)h=c.value,o.getObjectExtension(h,zP)&&a.push(XP(o,h,i,r))}catch(e){l.e(e)}finally{l.f()}return e.next=8,Promise.all(a);case 8:o.removeExtension(zP);case 9:case"end":return e.stop()}},e)}))).apply(this,arguments)}function XP(e,t,i,r){return qP.apply(this,arguments)}function qP(){return qP=a(s().mark(function e(t,i,r,o){var a,l,u,h,A,d,p,f,g,m,v,_,y,b;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(a=t.getObjectExtension(i,zP)){e.next=3;break}return e.abrupt("return");case 3:return l=t.getTypedArrayForBufferView(a.bufferView),u=rB(l.buffer,l.byteOffset),h=o.parse,delete(A=n({},r))["3d-tiles"],e.next=10,h(u,VP,A,o);case 10:for(d=e.sent,p=HP(d.attributes),f=0,g=Object.entries(p);f<g.length;f++)m=c(g[f],2),v=m[0],_=m[1],v in i.attributes&&(y=i.attributes[v],null!=(b=t.getAccessor(y))&&b.min&&null!=b&&b.max&&(_.min=b.min,_.max=b.max));i.attributes=p,d.indices&&(i.indices=GP(d.indices)),JP(i);case 16:case"end":return e.stop()}},e)})),qP.apply(this,arguments)}function YP(e,t){var i,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:4,n=arguments.length>3?arguments[3]:void 0,s=arguments.length>4?arguments[4]:void 0;if(!n.DracoWriter)throw new Error("options.gltf.DracoWriter not provided");var o=n.DracoWriter.encodeSync({attributes:e}),a=null==s||null===(i=s.parseSync)||void 0===i?void 0:i.call(s,{attributes:e}),l=n._addFauxAttributes(a.attributes),u=n.addBufferView(o);return{primitives:[{attributes:l,mode:r,extensions:b({},zP,{bufferView:u,attributes:l})}]}}function JP(e){if(!e.attributes&&Object.keys(e.attributes).length>0)throw new Error("glTF: Empty primitive detected: Draco decompression failure?")}function ZP(e){var t,r,n,o,a,l;return s().wrap(function(i){for(;;)switch(i.prev=i.next){case 0:t=u(e.json.meshes||[]),i.prev=1,t.s();case 3:if((r=t.n()).done){i.next=24;break}n=r.value,o=u(n.primitives),i.prev=6,o.s();case 8:if((a=o.n()).done){i.next=14;break}return l=a.value,i.next=12,l;case 12:i.next=8;break;case 14:i.next=19;break;case 16:i.prev=16,i.t0=i.catch(6),o.e(i.t0);case 19:return i.prev=19,o.f(),i.finish(19);case 22:i.next=3;break;case 24:i.next=29;break;case 26:i.prev=26,i.t1=i.catch(1),t.e(i.t1);case 29:return i.prev=29,t.f(),i.finish(29);case 32:case"end":return i.stop()}},i,null,[[1,26,29,32],[6,16,19,22]])}var $P=Object.freeze({__proto__:null,name:WP,preprocess:function(e,t,i){var r,n=new yB(e),s=u(ZP(n));try{for(s.s();!(r=s.n()).done;){var o=r.value;n.getObjectExtension(o,zP)}}catch(e){s.e(e)}finally{s.f()}},decode:function(e,t,i){return KP.apply(this,arguments)},encode:function(e){var t,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=new yB(e),n=u(r.json.meshes||[]);try{for(n.s();!(t=n.n()).done;){YP(t.value,i),r.addRequiredExtension(zP)}}catch(e){n.e(e)}finally{n.f()}}});function eC(e,t){if(!e)throw new Error("math.gl assertion ".concat(t))}var tC={EPSILON:1e-12,debug:!1,precision:4,printTypes:!1,printDegrees:!1,printRowMajor:!0};function iC(e){var t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).precision,i=void 0===t?tC.precision:t;return e=function(e){return Math.round(e/tC.EPSILON)*tC.EPSILON}(e),"".concat(parseFloat(e.toPrecision(i)))}function rC(e){return Array.isArray(e)||ArrayBuffer.isView(e)&&!(e instanceof DataView)}function nC(e,t,i){var r=tC.EPSILON;i&&(tC.EPSILON=i);try{if(e===t)return!0;if(rC(e)&&rC(t)){if(e.length!==t.length)return!1;for(var n=0;n<e.length;++n)if(!nC(e[n],t[n]))return!1;return!0}return e&&e.equals?e.equals(t):t&&t.equals?t.equals(e):"number"==typeof e&&"number"==typeof t&&Math.abs(e-t)<=tC.EPSILON*Math.max(1,Math.abs(e),Math.abs(t))}finally{tC.EPSILON=r}}function sC(e){function t(){var t=Reflect.construct(e,Array.from(arguments));return Object.setPrototypeOf(t,Object.getPrototypeOf(this)),t}return t.prototype=Object.create(e.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e,t}var oC=function(){function e(){return x(this,e),d(this,e,arguments)}return _(e,sC(Array)),P(e,[{key:"clone",value:function(){return(new this.constructor).copy(this)}},{key:"fromArray",value:function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=0;i<this.ELEMENTS;++i)this[i]=e[i+t];return this.check()}},{key:"toArray",value:function(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=0;i<this.ELEMENTS;++i)e[t+i]=this[i];return e}},{key:"from",value:function(e){return Array.isArray(e)?this.copy(e):this.fromObject(e)}},{key:"to",value:function(e){return e===this?this:rC(e)?this.toArray(e):this.toObject(e)}},{key:"toTarget",value:function(e){return e?this.to(e):this}},{key:"toFloat32Array",value:function(){return new Float32Array(this)}},{key:"toString",value:function(){return this.formatString(tC)}},{key:"formatString",value:function(e){for(var t="",i=0;i<this.ELEMENTS;++i)t+=(i>0?", ":"")+iC(this[i],e);return"".concat(e.printTypes?this.constructor.name:"","[").concat(t,"]")}},{key:"equals",value:function(e){if(!e||this.length!==e.length)return!1;for(var t=0;t<this.ELEMENTS;++t)if(!nC(this[t],e[t]))return!1;return!0}},{key:"exactEquals",value:function(e){if(!e||this.length!==e.length)return!1;for(var t=0;t<this.ELEMENTS;++t)if(this[t]!==e[t])return!1;return!0}},{key:"negate",value:function(){for(var e=0;e<this.ELEMENTS;++e)this[e]=-this[e];return this.check()}},{key:"lerp",value:function(e,t,i){if(void 0===i)return this.lerp(this,e,t);for(var r=0;r<this.ELEMENTS;++r){var n=e[r];this[r]=n+i*(t[r]-n)}return this.check()}},{key:"min",value:function(e){for(var t=0;t<this.ELEMENTS;++t)this[t]=Math.min(e[t],this[t]);return this.check()}},{key:"max",value:function(e){for(var t=0;t<this.ELEMENTS;++t)this[t]=Math.max(e[t],this[t]);return this.check()}},{key:"clamp",value:function(e,t){for(var i=0;i<this.ELEMENTS;++i)this[i]=Math.min(Math.max(this[i],e[i]),t[i]);return this.check()}},{key:"add",value:function(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];for(var r=0,n=t;r<n.length;r++)for(var s=n[r],o=0;o<this.ELEMENTS;++o)this[o]+=s[o];return this.check()}},{key:"subtract",value:function(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];for(var r=0,n=t;r<n.length;r++)for(var s=n[r],o=0;o<this.ELEMENTS;++o)this[o]-=s[o];return this.check()}},{key:"scale",value:function(e){if("number"==typeof e)for(var t=0;t<this.ELEMENTS;++t)this[t]*=e;else for(var i=0;i<this.ELEMENTS&&i<e.length;++i)this[i]*=e[i];return this.check()}},{key:"multiplyByScalar",value:function(e){for(var t=0;t<this.ELEMENTS;++t)this[t]*=e;return this.check()}},{key:"check",value:function(){if(tC.debug&&!this.validate())throw new Error("math.gl: ".concat(this.constructor.name," some fields set to invalid numbers'"));return this}},{key:"validate",value:function(){for(var e=this.length===this.ELEMENTS,t=0;t<this.ELEMENTS;++t)e=e&&Number.isFinite(this[t]);return e}},{key:"sub",value:function(e){return this.subtract(e)}},{key:"setScalar",value:function(e){for(var t=0;t<this.ELEMENTS;++t)this[t]=e;return this.check()}},{key:"addScalar",value:function(e){for(var t=0;t<this.ELEMENTS;++t)this[t]+=e;return this.check()}},{key:"subScalar",value:function(e){return this.addScalar(-e)}},{key:"multiplyScalar",value:function(e){for(var t=0;t<this.ELEMENTS;++t)this[t]*=e;return this.check()}},{key:"divideScalar",value:function(e){return this.multiplyByScalar(1/e)}},{key:"clampScalar",value:function(e,t){for(var i=0;i<this.ELEMENTS;++i)this[i]=Math.min(Math.max(this[i],e),t);return this.check()}},{key:"elements",get:function(){return this}}])}();function aC(e){if(!Number.isFinite(e))throw new Error("Invalid number ".concat(e));return e}function lC(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"";if(tC.debug&&!function(e,t){if(e.length!==t)return!1;for(var i=0;i<e.length;++i)if(!Number.isFinite(e[i]))return!1;return!0}(e,t))throw new Error("math.gl: ".concat(i," some fields set to invalid numbers'"));return e}var uC=function(){function e(){return x(this,e),d(this,e,arguments)}return _(e,oC),P(e,[{key:"x",get:function(){return this[0]},set:function(e){this[0]=aC(e)}},{key:"y",get:function(){return this[1]},set:function(e){this[1]=aC(e)}},{key:"len",value:function(){return Math.sqrt(this.lengthSquared())}},{key:"magnitude",value:function(){return this.len()}},{key:"lengthSquared",value:function(){for(var e=0,t=0;t<this.ELEMENTS;++t)e+=this[t]*this[t];return e}},{key:"magnitudeSquared",value:function(){return this.lengthSquared()}},{key:"distance",value:function(e){return Math.sqrt(this.distanceSquared(e))}},{key:"distanceSquared",value:function(e){for(var t=0,i=0;i<this.ELEMENTS;++i){var r=this[i]-e[i];t+=r*r}return aC(t)}},{key:"dot",value:function(e){for(var t=0,i=0;i<this.ELEMENTS;++i)t+=this[i]*e[i];return aC(t)}},{key:"normalize",value:function(){var e=this.magnitude();if(0!==e)for(var t=0;t<this.ELEMENTS;++t)this[t]/=e;return this.check()}},{key:"multiply",value:function(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];for(var r=0,n=t;r<n.length;r++)for(var s=n[r],o=0;o<this.ELEMENTS;++o)this[o]*=s[o];return this.check()}},{key:"divide",value:function(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];for(var r=0,n=t;r<n.length;r++)for(var s=n[r],o=0;o<this.ELEMENTS;++o)this[o]/=s[o];return this.check()}},{key:"lengthSq",value:function(){return this.lengthSquared()}},{key:"distanceTo",value:function(e){return this.distance(e)}},{key:"distanceToSquared",value:function(e){return this.distanceSquared(e)}},{key:"getComponent",value:function(e){return eC(e>=0&&e<this.ELEMENTS,"index is out of range"),aC(this[e])}},{key:"setComponent",value:function(e,t){return eC(e>=0&&e<this.ELEMENTS,"index is out of range"),this[e]=t,this.check()}},{key:"addVectors",value:function(e,t){return this.copy(e).add(t)}},{key:"subVectors",value:function(e,t){return this.copy(e).subtract(t)}},{key:"multiplyVectors",value:function(e,t){return this.copy(e).multiply(t)}},{key:"addScaledVector",value:function(e,t){return this.add(new this.constructor(e).multiplyScalar(t))}}])}(),cC="undefined"!=typeof Float32Array?Float32Array:Array;function hC(e,t,i){var r=t[0],n=t[1],s=t[2];return e[0]=r*i[0]+n*i[3]+s*i[6],e[1]=r*i[1]+n*i[4]+s*i[7],e[2]=r*i[2]+n*i[5]+s*i[8],e}Math.hypot||(Math.hypot=function(){for(var e=0,t=arguments.length;t--;)e+=arguments[t]*arguments[t];return Math.sqrt(e)}),function(){var e,t=(e=new cC(2),cC!=Float32Array&&(e[0]=0,e[1]=0),e)}(),function(){var e,t=(e=new cC(3),cC!=Float32Array&&(e[0]=0,e[1]=0,e[2]=0),e)}();var AC,dC,pC=[0,0,0],fC=function(){function e(){var t,i=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;return x(this,e),t=d(this,e,[-0,-0,-0]),1===arguments.length&&rC(i)?t.copy(i):(tC.debug&&(aC(i),aC(r),aC(n)),t[0]=i,t[1]=r,t[2]=n),t}return _(e,uC),P(e,[{key:"set",value:function(e,t,i){return this[0]=e,this[1]=t,this[2]=i,this.check()}},{key:"copy",value:function(e){return this[0]=e[0],this[1]=e[1],this[2]=e[2],this.check()}},{key:"fromObject",value:function(e){return tC.debug&&(aC(e.x),aC(e.y),aC(e.z)),this[0]=e.x,this[1]=e.y,this[2]=e.z,this.check()}},{key:"toObject",value:function(e){return e.x=this[0],e.y=this[1],e.z=this[2],e}},{key:"ELEMENTS",get:function(){return 3}},{key:"z",get:function(){return this[2]},set:function(e){this[2]=aC(e)}},{key:"angle",value:function(e){return function(e,t){var i=e[0],r=e[1],n=e[2],s=t[0],o=t[1],a=t[2],l=Math.sqrt(i*i+r*r+n*n)*Math.sqrt(s*s+o*o+a*a),u=l&&function(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]}(e,t)/l;return Math.acos(Math.min(Math.max(u,-1),1))}(this,e)}},{key:"cross",value:function(e){return function(e,t,i){var r=t[0],n=t[1],s=t[2],o=i[0],a=i[1],l=i[2];e[0]=n*l-s*a,e[1]=s*o-r*l,e[2]=r*a-n*o}(this,this,e),this.check()}},{key:"rotateX",value:function(e){var t=e.radians,i=e.origin;return function(e,t,i,r){var n=[],s=[];n[0]=t[0]-i[0],n[1]=t[1]-i[1],n[2]=t[2]-i[2],s[0]=n[0],s[1]=n[1]*Math.cos(r)-n[2]*Math.sin(r),s[2]=n[1]*Math.sin(r)+n[2]*Math.cos(r),e[0]=s[0]+i[0],e[1]=s[1]+i[1],e[2]=s[2]+i[2]}(this,this,void 0===i?pC:i,t),this.check()}},{key:"rotateY",value:function(e){var t=e.radians,i=e.origin;return function(e,t,i,r){var n=[],s=[];n[0]=t[0]-i[0],n[1]=t[1]-i[1],n[2]=t[2]-i[2],s[0]=n[2]*Math.sin(r)+n[0]*Math.cos(r),s[1]=n[1],s[2]=n[2]*Math.cos(r)-n[0]*Math.sin(r),e[0]=s[0]+i[0],e[1]=s[1]+i[1],e[2]=s[2]+i[2]}(this,this,void 0===i?pC:i,t),this.check()}},{key:"rotateZ",value:function(e){var t=e.radians,i=e.origin;return function(e,t,i,r){var n=[],s=[];n[0]=t[0]-i[0],n[1]=t[1]-i[1],n[2]=t[2]-i[2],s[0]=n[0]*Math.cos(r)-n[1]*Math.sin(r),s[1]=n[0]*Math.sin(r)+n[1]*Math.cos(r),s[2]=n[2],e[0]=s[0]+i[0],e[1]=s[1]+i[1],e[2]=s[2]+i[2]}(this,this,void 0===i?pC:i,t),this.check()}},{key:"transform",value:function(e){return this.transformAsPoint(e)}},{key:"transformAsPoint",value:function(e){return function(e,t,i){var r=t[0],n=t[1],s=t[2],o=i[3]*r+i[7]*n+i[11]*s+i[15];o=o||1,e[0]=(i[0]*r+i[4]*n+i[8]*s+i[12])/o,e[1]=(i[1]*r+i[5]*n+i[9]*s+i[13])/o,e[2]=(i[2]*r+i[6]*n+i[10]*s+i[14])/o}(this,this,e),this.check()}},{key:"transformAsVector",value:function(e){return function(e,t,i){var r=t[0],n=t[1],s=t[2],o=i[3]*r+i[7]*n+i[11]*s||1;e[0]=(i[0]*r+i[4]*n+i[8]*s)/o,e[1]=(i[1]*r+i[5]*n+i[9]*s)/o,e[2]=(i[2]*r+i[6]*n+i[10]*s)/o}(this,this,e),this.check()}},{key:"transformByMatrix3",value:function(e){return hC(this,this,e),this.check()}},{key:"transformByMatrix2",value:function(e){return function(e,t,i){var r=t[0],n=t[1];e[0]=i[0]*r+i[2]*n,e[1]=i[1]*r+i[3]*n,e[2]=t[2]}(this,this,e),this.check()}},{key:"transformByQuaternion",value:function(e){return function(e,t,i){var r=i[0],n=i[1],s=i[2],o=i[3],a=t[0],l=t[1],u=t[2],c=n*u-s*l,h=s*a-r*u,A=r*l-n*a,d=n*A-s*h,p=s*c-r*A,f=r*h-n*c,g=2*o;c*=g,h*=g,A*=g,d*=2,p*=2,f*=2,e[0]=a+c+d,e[1]=l+h+p,e[2]=u+A+f}(this,this,e),this.check()}}],[{key:"ZERO",get:function(){return AC||(AC=new e(0,0,0),Object.freeze(AC)),AC}}])}(),gC=function(){function e(){return x(this,e),d(this,e,arguments)}return _(e,oC),P(e,[{key:"toString",value:function(){var e="[";if(tC.printRowMajor){e+="row-major:";for(var t=0;t<this.RANK;++t)for(var i=0;i<this.RANK;++i)e+=" ".concat(this[i*this.RANK+t])}else{e+="column-major:";for(var r=0;r<this.ELEMENTS;++r)e+=" ".concat(this[r])}return e+="]"}},{key:"getElementIndex",value:function(e,t){return t*this.RANK+e}},{key:"getElement",value:function(e,t){return this[t*this.RANK+e]}},{key:"setElement",value:function(e,t,i){return this[t*this.RANK+e]=aC(i),this}},{key:"getColumn",value:function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:new Array(this.RANK).fill(-0),i=e*this.RANK,r=0;r<this.RANK;++r)t[r]=this[i+r];return t}},{key:"setColumn",value:function(e,t){for(var i=e*this.RANK,r=0;r<this.RANK;++r)this[i+r]=t[r];return this}}])}();function mC(e,t,i){var r=t[0],n=t[1],s=t[2],o=t[3],a=t[4],l=t[5],u=t[6],c=t[7],h=t[8],A=i[0],d=i[1],p=i[2],f=i[3],g=i[4],m=i[5],v=i[6],_=i[7],y=i[8];return e[0]=A*r+d*o+p*u,e[1]=A*n+d*a+p*c,e[2]=A*s+d*l+p*h,e[3]=f*r+g*o+m*u,e[4]=f*n+g*a+m*c,e[5]=f*s+g*l+m*h,e[6]=v*r+_*o+y*u,e[7]=v*n+_*a+y*c,e[8]=v*s+_*l+y*h,e}function vC(e,t,i){var r=i[0],n=i[1];return e[0]=r*t[0],e[1]=r*t[1],e[2]=r*t[2],e[3]=n*t[3],e[4]=n*t[4],e[5]=n*t[5],e[6]=t[6],e[7]=t[7],e[8]=t[8],e}!function(e){e[e.COL0ROW0=0]="COL0ROW0",e[e.COL0ROW1=1]="COL0ROW1",e[e.COL0ROW2=2]="COL0ROW2",e[e.COL1ROW0=3]="COL1ROW0",e[e.COL1ROW1=4]="COL1ROW1",e[e.COL1ROW2=5]="COL1ROW2",e[e.COL2ROW0=6]="COL2ROW0",e[e.COL2ROW1=7]="COL2ROW1",e[e.COL2ROW2=8]="COL2ROW2"}(dC||(dC={}));var _C,yC,bC=Object.freeze([1,0,0,0,1,0,0,0,1]),wC=function(){function e(t){for(var i,r=arguments.length,n=new Array(r>1?r-1:0),s=1;s<r;s++)n[s-1]=arguments[s];return x(this,e),i=d(this,e,[-0,-0,-0,-0,-0,-0,-0,-0,-0]),1===arguments.length&&Array.isArray(t)?i.copy(t):n.length>0?i.copy([t].concat(n)):i.identity(),i}return _(e,gC),P(e,[{key:"ELEMENTS",get:function(){return 9}},{key:"RANK",get:function(){return 3}},{key:"INDICES",get:function(){return dC}},{key:"copy",value:function(e){return this[0]=e[0],this[1]=e[1],this[2]=e[2],this[3]=e[3],this[4]=e[4],this[5]=e[5],this[6]=e[6],this[7]=e[7],this[8]=e[8],this.check()}},{key:"identity",value:function(){return this.copy(bC)}},{key:"fromObject",value:function(e){return this.check()}},{key:"fromQuaternion",value:function(e){return function(e,t){var i=t[0],r=t[1],n=t[2],s=t[3],o=i+i,a=r+r,l=n+n,u=i*o,c=r*o,h=r*a,A=n*o,d=n*a,p=n*l,f=s*o,g=s*a,m=s*l;e[0]=1-h-p,e[3]=c-m,e[6]=A+g,e[1]=c+m,e[4]=1-u-p,e[7]=d-f,e[2]=A-g,e[5]=d+f,e[8]=1-u-h}(this,e),this.check()}},{key:"set",value:function(e,t,i,r,n,s,o,a,l){return this[0]=e,this[1]=t,this[2]=i,this[3]=r,this[4]=n,this[5]=s,this[6]=o,this[7]=a,this[8]=l,this.check()}},{key:"setRowMajor",value:function(e,t,i,r,n,s,o,a,l){return this[0]=e,this[1]=r,this[2]=o,this[3]=t,this[4]=n,this[5]=a,this[6]=i,this[7]=s,this[8]=l,this.check()}},{key:"determinant",value:function(){return function(e){var t=e[0],i=e[1],r=e[2],n=e[3],s=e[4],o=e[5],a=e[6],l=e[7],u=e[8];return t*(u*s-o*l)+i*(-u*n+o*a)+r*(l*n-s*a)}(this)}},{key:"transpose",value:function(){return function(e,t){if(e===t){var i=t[1],r=t[2],n=t[5];e[1]=t[3],e[2]=t[6],e[3]=i,e[5]=t[7],e[6]=r,e[7]=n}else e[0]=t[0],e[1]=t[3],e[2]=t[6],e[3]=t[1],e[4]=t[4],e[5]=t[7],e[6]=t[2],e[7]=t[5],e[8]=t[8]}(this,this),this.check()}},{key:"invert",value:function(){return function(e,t){var i=t[0],r=t[1],n=t[2],s=t[3],o=t[4],a=t[5],l=t[6],u=t[7],c=t[8],h=c*o-a*u,A=-c*s+a*l,d=u*s-o*l,p=i*h+r*A+n*d;p&&(p=1/p,e[0]=h*p,e[1]=(-c*r+n*u)*p,e[2]=(a*r-n*o)*p,e[3]=A*p,e[4]=(c*i-n*l)*p,e[5]=(-a*i+n*s)*p,e[6]=d*p,e[7]=(-u*i+r*l)*p,e[8]=(o*i-r*s)*p)}(this,this),this.check()}},{key:"multiplyLeft",value:function(e){return mC(this,e,this),this.check()}},{key:"multiplyRight",value:function(e){return mC(this,this,e),this.check()}},{key:"rotate",value:function(e){return function(e,t,i){var r=t[0],n=t[1],s=t[2],o=t[3],a=t[4],l=t[5],u=t[6],c=t[7],h=t[8],A=Math.sin(i),d=Math.cos(i);e[0]=d*r+A*o,e[1]=d*n+A*a,e[2]=d*s+A*l,e[3]=d*o-A*r,e[4]=d*a-A*n,e[5]=d*l-A*s,e[6]=u,e[7]=c,e[8]=h}(this,this,e),this.check()}},{key:"scale",value:function(e){return Array.isArray(e)?vC(this,this,e):vC(this,this,[e,e]),this.check()}},{key:"translate",value:function(e){return function(e,t,i){var r=t[0],n=t[1],s=t[2],o=t[3],a=t[4],l=t[5],u=t[6],c=t[7],h=t[8],A=i[0],d=i[1];e[0]=r,e[1]=n,e[2]=s,e[3]=o,e[4]=a,e[5]=l,e[6]=A*r+d*o+u,e[7]=A*n+d*a+c,e[8]=A*s+d*l+h}(this,this,e),this.check()}},{key:"transform",value:function(e,t){var i;switch(e.length){case 2:i=function(e,t,i){var r=t[0],n=t[1];return e[0]=i[0]*r+i[3]*n+i[6],e[1]=i[1]*r+i[4]*n+i[7],e}(t||[-0,-0],e,this);break;case 3:i=hC(t||[-0,-0,-0],e,this);break;case 4:i=function(e,t,i){var r=t[0],n=t[1],s=t[2];return e[0]=i[0]*r+i[3]*n+i[6]*s,e[1]=i[1]*r+i[4]*n+i[7]*s,e[2]=i[2]*r+i[5]*n+i[8]*s,e[3]=t[3],e}(t||[-0,-0,-0,-0],e,this);break;default:throw new Error("Illegal vector")}return lC(i,e.length),i}},{key:"transformVector",value:function(e,t){return this.transform(e,t)}},{key:"transformVector2",value:function(e,t){return this.transform(e,t)}},{key:"transformVector3",value:function(e,t){return this.transform(e,t)}}],[{key:"IDENTITY",get:function(){return BC()}},{key:"ZERO",get:function(){return xC()}}])}();function xC(){return _C||(_C=new wC([0,0,0,0,0,0,0,0,0]),Object.freeze(_C)),_C}function BC(){return yC||(yC=new wC,Object.freeze(yC)),yC}var PC={SCALAR:1,VEC2:2,VEC3:3,VEC4:4,MAT2:4,MAT3:9,MAT4:16},CC={5120:1,5121:1,5122:2,5123:2,5125:4,5126:4},MC="KHR_texture_transform",kC=MC,EC=new fC,SC=new wC,TC=new wC;function IC(){return(IC=a(s().mark(function e(t,i){var r,n,o;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(r=new yB(t),r.getExtension(MC)){e.next=4;break}return e.abrupt("return");case 4:for(n=t.json.materials||[],o=0;o<n.length;o++)FC(o,t);case 6:case"end":return e.stop()}},e)}))).apply(this,arguments)}function FC(e,t){var i,r,n,s=[],o=null===(i=t.json.materials)||void 0===i?void 0:i[e],a=null==o||null===(r=o.pbrMetallicRoughness)||void 0===r?void 0:r.baseColorTexture;a&&DC(t,e,a,s);var l=null==o?void 0:o.emissiveTexture;l&&DC(t,e,l,s);var u=null==o?void 0:o.normalTexture;u&&DC(t,e,u,s);var c=null==o?void 0:o.occlusionTexture;c&&DC(t,e,c,s);var h=null==o||null===(n=o.pbrMetallicRoughness)||void 0===n?void 0:n.metallicRoughnessTexture;h&&DC(t,e,h,s)}function DC(e,t,i,r){var n=function(e,t){var i,r=null===(i=e.extensions)||void 0===i?void 0:i[MC],n=e.texCoord,s=void 0===n?0:n,o=r.texCoord,a=void 0===o?s:o,l=-1!==t.findIndex(function(e){var t=c(e,2),i=t[0],r=t[1];return i===s&&r===a});if(!l){var u=function(e){var t=e.offset,i=void 0===t?[0,0]:t,r=e.rotation,n=void 0===r?0:r,s=e.scale,o=void 0===s?[1,1]:s,a=(new wC).set(1,0,0,0,1,0,i[0],i[1],1),l=SC.set(Math.cos(n),Math.sin(n),0,-Math.sin(n),Math.cos(n),0,0,0,1),u=TC.set(o[0],0,0,0,o[1],0,0,0,1);return a.multiplyRight(l).multiplyRight(u)}(r);return s!==a&&(e.texCoord=a),t.push([s,a]),{originalTexCoord:s,texCoord:a,matrix:u}}return null}(i,r);if(n){var s,o=u(e.json.meshes||[]);try{for(o.s();!(s=o.n()).done;){var a,l=u(s.value.primitives);try{for(l.s();!(a=l.n()).done;){var h=a.value,A=h.material;Number.isFinite(A)&&t===A&&RC(e,h,n)}}catch(e){l.e(e)}finally{l.f()}}}catch(e){o.e(e)}finally{o.f()}}}function RC(e,t,i){var r=i.originalTexCoord,n=i.texCoord,s=i.matrix,o=t.attributes["TEXCOORD_".concat(r)];if(Number.isFinite(o)){var a,l=null===(a=e.json.accessors)||void 0===a?void 0:a[o];if(l&&l.bufferView){var u,c=null===(u=e.json.bufferViews)||void 0===u?void 0:u[l.bufferView];if(c){for(var h=e.buffers[c.buffer],A=h.arrayBuffer,d=(h.byteOffset||0)+(l.byteOffset||0)+(c.byteOffset||0),p=mB(l,c),f=p.ArrayType,g=p.length,m=CC[l.componentType],v=PC[l.type],_=c.byteStride||m*v,y=new Float32Array(g),b=0;b<l.count;b++){var w=new f(A,d+b*_,2);EC.set(w[0],w[1],1),EC.transformByMatrix3(s),y.set([EC[0],EC[1]],b*v)}r===n?function(e,t,i,r){e.componentType=5126,i.push({arrayBuffer:r.buffer,byteOffset:0,byteLength:r.buffer.byteLength}),t.buffer=i.length-1,t.byteLength=r.buffer.byteLength,t.byteOffset=0,delete t.byteStride}(l,c,e.buffers,y):function(e,t,i,r,n){r.buffers.push({arrayBuffer:n.buffer,byteOffset:0,byteLength:n.buffer.byteLength});var s=r.json.bufferViews;if(!s)return;s.push({buffer:r.buffers.length-1,byteLength:n.buffer.byteLength,byteOffset:0});var o=r.json.accessors;if(!o)return;o.push({bufferView:(null==s?void 0:s.length)-1,byteOffset:0,componentType:5126,count:t.count,type:"VEC2"}),i.attributes["TEXCOORD_".concat(e)]=o.length-1}(n,l,t,e,y)}}}}var OC=Object.freeze({__proto__:null,name:kC,decode:function(e,t){return IC.apply(this,arguments)}}),LC="KHR_lights_punctual",jC=LC;function UC(){return(UC=a(s().mark(function e(t){var i,r,n,o,a,l,c;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:i=new yB(t),r=i.json,(n=i.getExtension(LC))&&(i.json.lights=n.lights,i.removeExtension(LC)),o=u(r.nodes||[]);try{for(o.s();!(a=o.n()).done;)l=a.value,(c=i.getObjectExtension(l,LC))&&(l.light=c.light),i.removeObjectExtension(l,LC)}catch(e){o.e(e)}finally{o.f()}case 6:case"end":return e.stop()}},e)}))).apply(this,arguments)}function NC(){return(NC=a(s().mark(function e(t){var i,r,n,o,a,l,c;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(i=new yB(t),(r=i.json).lights&&(oB(!(n=i.addExtension(LC)).lights),n.lights=r.lights,delete r.lights),i.json.lights){o=u(i.json.lights);try{for(o.s();!(a=o.n()).done;)l=a.value,c=l.node,i.addObjectExtension(c,LC,l)}catch(e){o.e(e)}finally{o.f()}delete i.json.lights}case 4:case"end":return e.stop()}},e)}))).apply(this,arguments)}var VC="KHR_materials_unlit",QC=VC;function HC(){return(HC=a(s().mark(function e(t){var i,r,n,o,a;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:i=new yB(t),r=i.json,n=u(r.materials||[]);try{for(n.s();!(o=n.n()).done;)a=o.value,a.extensions&&a.extensions.KHR_materials_unlit&&(a.unlit=!0),i.removeObjectExtension(a,VC)}catch(e){n.e(e)}finally{n.f()}i.removeExtension(VC);case 5:case"end":return e.stop()}},e)}))).apply(this,arguments)}var GC="KHR_techniques_webgl",zC=GC;function WC(){return(WC=a(s().mark(function e(t){var i,r,n,o,a,l,c,h;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(i=new yB(t),r=i.json,n=i.getExtension(GC)){o=XC(n,i),a=u(r.materials||[]);try{for(a.s();!(l=a.n()).done;)c=l.value,(h=i.getObjectExtension(c,GC))&&(c.technique=Object.assign({},h,o[h.technique]),c.technique.values=qC(c.technique,i)),i.removeObjectExtension(c,GC)}catch(e){a.e(e)}finally{a.f()}i.removeExtension(GC)}case 4:case"end":return e.stop()}},e)}))).apply(this,arguments)}function KC(){return(KC=a(s().mark(function e(t,i){return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:case"end":return e.stop()}},e)}))).apply(this,arguments)}function XC(e,t){var i=e.programs,r=void 0===i?[]:i,n=e.shaders,s=void 0===n?[]:n,o=e.techniques,a=void 0===o?[]:o,l=new TextDecoder;return s.forEach(function(e){if(!Number.isFinite(e.bufferView))throw new Error("KHR_techniques_webgl: no shader code");e.code=l.decode(t.getTypedArrayForBufferView(e.bufferView))}),r.forEach(function(e){e.fragmentShader=s[e.fragmentShader],e.vertexShader=s[e.vertexShader]}),a.forEach(function(e){e.program=r[e.program]}),a}function qC(e,t){var i=Object.assign({},e.values);return Object.keys(e.uniforms||{}).forEach(function(t){e.uniforms[t].value&&!(t in i)&&(i[t]=e.uniforms[t].value)}),Object.keys(i).forEach(function(e){"object"===w(i[e])&&void 0!==i[e].index&&(i[e].texture=t.getTexture(i[e].index))}),i}var YC="EXT_feature_metadata",JC=YC;function ZC(){return(ZC=a(s().mark(function e(t){return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:$C(new yB(t));case 2:case"end":return e.stop()}},e)}))).apply(this,arguments)}function $C(e){var t,i=e.getExtension(YC),r=null==i||null===(t=i.schema)||void 0===t?void 0:t.classes,n=null==i?void 0:i.featureTables;if((null==i?void 0:i.featureTextures)&&console.warn('featureTextures is not yet supported in the "EXT_feature_metadata" extension.'),r&&n)for(var s in r){var o=r[s],a=iM(n,s);a&&eM(e,a,o)}}function eM(e,t,i){for(var r in i.properties){var n,s=i.properties[r],o=null==t||null===(n=t.properties)||void 0===n?void 0:n[r],a=t.count;if(o){var l=tM(e,s,a,o);o.data=l}}}function tM(e,t,i,r){var n=r.bufferView,s=e.getTypedArrayForBufferView(n);if("STRING"===t.type){var o=r.stringOffsetBufferView;s=function(e,t,i){for(var r=[],n=new TextDecoder("utf8"),s=0,o=4,a=0;a<i;a++){var l=t[(a+1)*o]-t[a*o],u=e.subarray(s,l+s),c=n.decode(u);r.push(c),s+=l}return r}(s,e.getTypedArrayForBufferView(o),i)}return s}function iM(e,t){for(var i in e){var r=e[i];if(r.class===t)return r}return null}var rM=[jB,VB,GB,$P,Object.freeze({__proto__:null,name:jC,decode:function(e){return UC.apply(this,arguments)},encode:function(e){return NC.apply(this,arguments)}}),Object.freeze({__proto__:null,name:QC,decode:function(e){return HC.apply(this,arguments)},encode:function(e){var t=new yB(e),i=t.json;if(t.materials){var r,n=u(i.materials||[]);try{for(n.s();!(r=n.n()).done;){var s=r.value;s.unlit&&(delete s.unlit,t.addObjectExtension(s,VC,{}),t.addExtension(VC))}}catch(e){n.e(e)}finally{n.f()}}}}),Object.freeze({__proto__:null,name:zC,decode:function(e){return WC.apply(this,arguments)},encode:function(e,t){return KC.apply(this,arguments)}}),OC,Object.freeze({__proto__:null,name:JC,decode:function(e){return ZC.apply(this,arguments)}})];function nM(e){var t,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2?arguments[2]:void 0,n=rM.filter(function(e){return aM(e.name,i)}),s=u(n);try{for(s.s();!(t=s.n()).done;){var o,a=t.value;null===(o=a.preprocess)||void 0===o||o.call(a,e,i,r)}}catch(e){s.e(e)}finally{s.f()}}function sM(e){return oM.apply(this,arguments)}function oM(){return oM=a(s().mark(function e(t){var i,r,n,o,a,l,c,h=arguments;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:i=h.length>1&&void 0!==h[1]?h[1]:{},r=h.length>2?h[2]:void 0,n=rM.filter(function(e){return aM(e.name,i)}),o=u(n),e.prev=4,o.s();case 6:if((a=o.n()).done){e.next=12;break}return l=a.value,e.next=10,null===(c=l.decode)||void 0===c?void 0:c.call(l,t,i,r);case 10:e.next=6;break;case 12:e.next=17;break;case 14:e.prev=14,e.t0=e.catch(4),o.e(e.t0);case 17:return e.prev=17,o.f(),e.finish(17);case 20:case"end":return e.stop()}},e,null,[[4,14,17,20]])})),oM.apply(this,arguments)}function aM(e,t){var i,r=(null==t||null===(i=t.gltf)||void 0===i?void 0:i.excludeExtensions)||{};return!(e in r&&!r[e])}var lM="KHR_binary_glTF";var uM={accessors:"accessor",animations:"animation",buffers:"buffer",bufferViews:"bufferView",images:"image",materials:"material",meshes:"mesh",nodes:"node",samplers:"sampler",scenes:"scene",skins:"skin",textures:"texture"},cM={accessor:"accessors",animations:"animation",buffer:"buffers",bufferView:"bufferViews",image:"images",material:"materials",mesh:"meshes",node:"nodes",sampler:"samplers",scene:"scenes",skin:"skins",texture:"textures"},hM=function(){return P(function e(){x(this,e),iy(this,"idToIndexMap",{animations:{},accessors:{},buffers:{},bufferViews:{},images:{},materials:{},meshes:{},nodes:{},samplers:{},scenes:{},skins:{},textures:{}}),iy(this,"json",void 0)},[{key:"normalize",value:function(e,t){this.json=e.json;var i=e.json;switch(i.asset&&i.asset.version){case"2.0":return;case void 0:case"1.0":break;default:return void console.warn("glTF: Unknown version ".concat(i.asset.version))}if(!t.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(i),this._convertTopLevelObjectsToArrays(i),function(e){var t,i=new yB(e),r=i.json,n=u(r.images||[]);try{for(n.s();!(t=n.n()).done;){var s=t.value,o=i.getObjectExtension(s,lM);o&&Object.assign(s,o),i.removeObjectExtension(s,lM)}}catch(e){n.e(e)}finally{n.f()}r.buffers&&r.buffers[0]&&delete r.buffers[0].uri,i.removeExtension(lM)}(e),this._convertObjectIdsToArrayIndices(i),this._updateObjects(i),this._updateMaterial(i)}},{key:"_addAsset",value:function(e){e.asset=e.asset||{},e.asset.version="2.0",e.asset.generator=e.asset.generator||"Normalized to glTF 2.0 by loaders.gl"}},{key:"_convertTopLevelObjectsToArrays",value:function(e){for(var t in uM)this._convertTopLevelObjectToArray(e,t)}},{key:"_convertTopLevelObjectToArray",value:function(e,t){var i=e[t];if(i&&!Array.isArray(i))for(var r in e[t]=[],i){var n=i[r];n.id=n.id||r;var s=e[t].length;e[t].push(n),this.idToIndexMap[t][r]=s}}},{key:"_convertObjectIdsToArrayIndices",value:function(e){for(var t in uM)this._convertIdsToIndices(e,t);"scene"in e&&(e.scene=this._convertIdToIndex(e.scene,"scene"));var i,r=u(e.textures);try{for(r.s();!(i=r.n()).done;){var n=i.value;this._convertTextureIds(n)}}catch(e){r.e(e)}finally{r.f()}var s,o=u(e.meshes);try{for(o.s();!(s=o.n()).done;){var a=s.value;this._convertMeshIds(a)}}catch(e){o.e(e)}finally{o.f()}var l,c=u(e.nodes);try{for(c.s();!(l=c.n()).done;){var h=l.value;this._convertNodeIds(h)}}catch(e){c.e(e)}finally{c.f()}var A,d=u(e.scenes);try{for(d.s();!(A=d.n()).done;){var p=A.value;this._convertSceneIds(p)}}catch(e){d.e(e)}finally{d.f()}}},{key:"_convertTextureIds",value:function(e){e.source&&(e.source=this._convertIdToIndex(e.source,"image"))}},{key:"_convertMeshIds",value:function(e){var t,i=u(e.primitives);try{for(i.s();!(t=i.n()).done;){var r=t.value,n=r.attributes,s=r.indices,o=r.material;for(var a in n)n[a]=this._convertIdToIndex(n[a],"accessor");s&&(r.indices=this._convertIdToIndex(s,"accessor")),o&&(r.material=this._convertIdToIndex(o,"material"))}}catch(e){i.e(e)}finally{i.f()}}},{key:"_convertNodeIds",value:function(e){var t=this;e.children&&(e.children=e.children.map(function(e){return t._convertIdToIndex(e,"node")})),e.meshes&&(e.meshes=e.meshes.map(function(e){return t._convertIdToIndex(e,"mesh")}))}},{key:"_convertSceneIds",value:function(e){var t=this;e.nodes&&(e.nodes=e.nodes.map(function(e){return t._convertIdToIndex(e,"node")}))}},{key:"_convertIdsToIndices",value:function(e,t){e[t]||(console.warn("gltf v1: json doesn't contain attribute ".concat(t)),e[t]=[]);var i,r=u(e[t]);try{for(r.s();!(i=r.n()).done;){var n=i.value;for(var s in n){var o=n[s],a=this._convertIdToIndex(o,s);n[s]=a}}}catch(e){r.e(e)}finally{r.f()}}},{key:"_convertIdToIndex",value:function(e,t){var i=cM[t];if(i in this.idToIndexMap){var r=this.idToIndexMap[i][e];if(!Number.isFinite(r))throw new Error("gltf v1: failed to resolve ".concat(t," with id ").concat(e));return r}return e}},{key:"_updateObjects",value:function(e){var t,i=u(this.json.buffers);try{for(i.s();!(t=i.n()).done;){delete t.value.type}}catch(e){i.e(e)}finally{i.f()}}},{key:"_updateMaterial",value:function(e){var t,i=u(e.materials);try{var r,n,s,o=function(){var i=t.value;i.pbrMetallicRoughness={baseColorFactor:[1,1,1,1],metallicFactor:1,roughnessFactor:1};var o=(null===(r=i.values)||void 0===r?void 0:r.tex)||(null===(n=i.values)||void 0===n?void 0:n.texture2d_0)||(null===(s=i.values)||void 0===s?void 0:s.diffuseTex),a=e.textures.findIndex(function(e){return e.id===o});-1!==a&&(i.pbrMetallicRoughness.baseColorTexture={index:a})};for(i.s();!(t=i.n()).done;)o()}catch(e){i.e(e)}finally{i.f()}}}])}();function AM(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return(new hM).normalize(e,t)}var dM={SCALAR:1,VEC2:2,VEC3:3,VEC4:4,MAT2:4,MAT3:9,MAT4:16},pM={5120:1,5121:1,5122:2,5123:2,5125:4,5126:4},fM=10240,gM=10241,mM=10242,vM=10243,_M=10497,yM=9986,bM={magFilter:fM,minFilter:gM,wrapS:mM,wrapT:vM},wM=b(b(b(b({},fM,9729),gM,yM),mM,_M),vM,_M);var xM=function(){return P(function e(){x(this,e),iy(this,"baseUri",""),iy(this,"json",{}),iy(this,"buffers",[]),iy(this,"images",[])},[{key:"postProcess",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=e.json,r=e.buffers,n=void 0===r?[]:r,s=e.images,o=void 0===s?[]:s,a=e.baseUri,l=void 0===a?"":a;return oB(i),this.baseUri=l,this.json=i,this.buffers=n,this.images=o,this._resolveTree(this.json,t),this.json}},{key:"_resolveTree",value:function(e){var t=this;e.bufferViews&&(e.bufferViews=e.bufferViews.map(function(e,i){return t._resolveBufferView(e,i)})),e.images&&(e.images=e.images.map(function(e,i){return t._resolveImage(e,i)})),e.samplers&&(e.samplers=e.samplers.map(function(e,i){return t._resolveSampler(e,i)})),e.textures&&(e.textures=e.textures.map(function(e,i){return t._resolveTexture(e,i)})),e.accessors&&(e.accessors=e.accessors.map(function(e,i){return t._resolveAccessor(e,i)})),e.materials&&(e.materials=e.materials.map(function(e,i){return t._resolveMaterial(e,i)})),e.meshes&&(e.meshes=e.meshes.map(function(e,i){return t._resolveMesh(e,i)})),e.nodes&&(e.nodes=e.nodes.map(function(e,i){return t._resolveNode(e,i)})),e.skins&&(e.skins=e.skins.map(function(e,i){return t._resolveSkin(e,i)})),e.scenes&&(e.scenes=e.scenes.map(function(e,i){return t._resolveScene(e,i)})),void 0!==e.scene&&(e.scene=e.scenes[this.json.scene])}},{key:"getScene",value:function(e){return this._get("scenes",e)}},{key:"getNode",value:function(e){return this._get("nodes",e)}},{key:"getSkin",value:function(e){return this._get("skins",e)}},{key:"getMesh",value:function(e){return this._get("meshes",e)}},{key:"getMaterial",value:function(e){return this._get("materials",e)}},{key:"getAccessor",value:function(e){return this._get("accessors",e)}},{key:"getCamera",value:function(e){return null}},{key:"getTexture",value:function(e){return this._get("textures",e)}},{key:"getSampler",value:function(e){return this._get("samplers",e)}},{key:"getImage",value:function(e){return this._get("images",e)}},{key:"getBufferView",value:function(e){return this._get("bufferViews",e)}},{key:"getBuffer",value:function(e){return this._get("buffers",e)}},{key:"_get",value:function(e,t){if("object"===w(t))return t;var i=this.json[e]&&this.json[e][t];return i||console.warn("glTF file error: Could not find ".concat(e,"[").concat(t,"]")),i}},{key:"_resolveScene",value:function(e,t){var i=this;return e.id=e.id||"scene-".concat(t),e.nodes=(e.nodes||[]).map(function(e){return i.getNode(e)}),e}},{key:"_resolveNode",value:function(e,t){var i=this;return e.id=e.id||"node-".concat(t),e.children&&(e.children=e.children.map(function(e){return i.getNode(e)})),void 0!==e.mesh?e.mesh=this.getMesh(e.mesh):void 0!==e.meshes&&e.meshes.length&&(e.mesh=e.meshes.reduce(function(e,t){var r=i.getMesh(t);return e.id=r.id,e.primitives=e.primitives.concat(r.primitives),e},{primitives:[]})),void 0!==e.camera&&(e.camera=this.getCamera(e.camera)),void 0!==e.skin&&(e.skin=this.getSkin(e.skin)),e}},{key:"_resolveSkin",value:function(e,t){return e.id=e.id||"skin-".concat(t),e.inverseBindMatrices=this.getAccessor(e.inverseBindMatrices),e}},{key:"_resolveMesh",value:function(e,t){var i=this;return e.id=e.id||"mesh-".concat(t),e.primitives&&(e.primitives=e.primitives.map(function(e){var t=(e=n({},e)).attributes;for(var r in e.attributes={},t)e.attributes[r]=i.getAccessor(t[r]);return void 0!==e.indices&&(e.indices=i.getAccessor(e.indices)),void 0!==e.material&&(e.material=i.getMaterial(e.material)),e})),e}},{key:"_resolveMaterial",value:function(e,t){if(e.id=e.id||"material-".concat(t),e.normalTexture&&(e.normalTexture=n({},e.normalTexture),e.normalTexture.texture=this.getTexture(e.normalTexture.index)),e.occlusionTexture&&(e.occlustionTexture=n({},e.occlustionTexture),e.occlusionTexture.texture=this.getTexture(e.occlusionTexture.index)),e.emissiveTexture&&(e.emmisiveTexture=n({},e.emmisiveTexture),e.emissiveTexture.texture=this.getTexture(e.emissiveTexture.index)),e.emissiveFactor||(e.emissiveFactor=e.emmisiveTexture?[1,1,1]:[0,0,0]),e.pbrMetallicRoughness){e.pbrMetallicRoughness=n({},e.pbrMetallicRoughness);var i=e.pbrMetallicRoughness;i.baseColorTexture&&(i.baseColorTexture=n({},i.baseColorTexture),i.baseColorTexture.texture=this.getTexture(i.baseColorTexture.index)),i.metallicRoughnessTexture&&(i.metallicRoughnessTexture=n({},i.metallicRoughnessTexture),i.metallicRoughnessTexture.texture=this.getTexture(i.metallicRoughnessTexture.index))}return e}},{key:"_resolveAccessor",value:function(e,t){var i,r;if(e.id=e.id||"accessor-".concat(t),void 0!==e.bufferView&&(e.bufferView=this.getBufferView(e.bufferView)),e.bytesPerComponent=(i=e.componentType,pM[i]),e.components=(r=e.type,dM[r]),e.bytesPerElement=e.bytesPerComponent*e.components,e.bufferView){var n=e.bufferView.buffer,s=mB(e,e.bufferView),o=s.ArrayType,a=s.byteLength,l=(e.bufferView.byteOffset||0)+(e.byteOffset||0)+n.byteOffset,u=n.arrayBuffer.slice(l,l+a);e.bufferView.byteStride&&(u=this._getValueFromInterleavedBuffer(n,l,e.bufferView.byteStride,e.bytesPerElement,e.count)),e.value=new o(u)}return e}},{key:"_getValueFromInterleavedBuffer",value:function(e,t,i,r,n){for(var s=new Uint8Array(n*r),o=0;o<n;o++){var a=t+o*i;s.set(new Uint8Array(e.arrayBuffer.slice(a,a+r)),o*r)}return s.buffer}},{key:"_resolveTexture",value:function(e,t){return e.id=e.id||"texture-".concat(t),e.sampler="sampler"in e?this.getSampler(e.sampler):wM,e.source=this.getImage(e.source),e}},{key:"_resolveSampler",value:function(e,t){for(var i in e.id=e.id||"sampler-".concat(t),e.parameters={},e){var r=this._enumSamplerParameter(i);void 0!==r&&(e.parameters[r]=e[i])}return e}},{key:"_enumSamplerParameter",value:function(e){return bM[e]}},{key:"_resolveImage",value:function(e,t){e.id=e.id||"image-".concat(t),void 0!==e.bufferView&&(e.bufferView=this.getBufferView(e.bufferView));var i=this.images[t];return i&&(e.image=i),e}},{key:"_resolveBufferView",value:function(e,t){var i=e.buffer,r=n(n({id:"bufferView-".concat(t)},e),{},{buffer:this.buffers[i]}),s=this.buffers[i].arrayBuffer,o=this.buffers[i].byteOffset||0;return"byteOffset"in e&&(o+=e.byteOffset),r.data=new Uint8Array(s,o,e.byteLength),r}},{key:"_resolveCamera",value:function(e,t){return e.id=e.id||"camera-".concat(t),e.perspective,e.orthographic,e}}])}();function BM(e,t){return(new xM).postProcess(e,t)}var PM=1735152710,CM=1313821514,MM=5130562,kM=!0;function EM(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,r=new DataView(t),n=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return"".concat(String.fromCharCode(e.getUint8(t+0))).concat(String.fromCharCode(e.getUint8(t+1))).concat(String.fromCharCode(e.getUint8(t+2))).concat(String.fromCharCode(e.getUint8(t+3)))}(r,i+0),s=r.getUint32(i+4,kM),o=r.getUint32(i+8,kM);switch(Object.assign(e,{header:{byteOffset:i,byteLength:o,hasBinChunk:!1},type:n,version:s,json:{},binChunks:[]}),i+=12,e.version){case 1:return function(e,t,i){eB(e.header.byteLength>20);var r=t.getUint32(i+0,kM),n=t.getUint32(i+4,kM);return i+=8,eB(0===n),SM(e,t,i,r),i+=r,i+=TM(e,t,i,e.header.byteLength),i}(e,r,i);case 2:return function(e,t,i,r){return eB(e.header.byteLength>20),function(e,t,i,r){for(;i+8<=e.header.byteLength;){var n=t.getUint32(i+0,kM),s=t.getUint32(i+4,kM);switch(i+=8,s){case CM:SM(e,t,i,n);break;case MM:TM(e,t,i,n);break;case 0:r.strict||SM(e,t,i,n);break;case 1:r.strict||TM(e,t,i,n)}i+=nB(n,4)}}(e,t,i,r),i+e.header.byteLength}(e,r,i,{});default:throw new Error("Invalid GLB version ".concat(e.version,". Only supports v1 and v2."))}}function SM(e,t,i,r){var n=new Uint8Array(t.buffer,i,r),s=new TextDecoder("utf8").decode(n);return e.json=JSON.parse(s),nB(r,4)}function TM(e,t,i,r){return e.header.hasBinChunk=!0,e.binChunks.push({byteOffset:i,byteLength:r,arrayBuffer:t.buffer}),nB(r,4)}function IM(e,t){return FM.apply(this,arguments)}function FM(){return FM=a(s().mark(function e(t,i){var r,n,o,a,l,u,c,h,A,d=arguments;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(u=d.length>4?d[4]:void 0,DM(t,i,d.length>2&&void 0!==d[2]?d[2]:0,l=d.length>3?d[3]:void 0),AM(t,{normalize:null==l||null===(r=l.gltf)||void 0===r?void 0:r.normalize}),nM(t,l,u),c=[],null==l||null===(n=l.gltf)||void 0===n||!n.loadBuffers||!t.json.buffers){e.next=10;break}return e.next=10,RM(t,l,u);case 10:return null!=l&&null!==(o=l.gltf)&&void 0!==o&&o.loadImages&&(h=LM(t,l,u),c.push(h)),A=sM(t,l,u),c.push(A),e.next=15,Promise.all(c);case 15:return e.abrupt("return",null!=l&&null!==(a=l.gltf)&&void 0!==a&&a.postProcess?BM(t,l):t);case 16:case"end":return e.stop()}},e)})),FM.apply(this,arguments)}function DM(e,t,i,r){(r.uri&&(e.baseUri=r.uri),t instanceof ArrayBuffer&&!function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=new DataView(e),n=i.magic,s=void 0===n?PM:n,o=r.getUint32(t,!1);return o===s||o===PM}(t,i,r))&&(t=(new TextDecoder).decode(t));if("string"==typeof t)e.json=iB(t);else if(t instanceof ArrayBuffer){var n={};i=EM(n,t,i,r.glb),oB("glTF"===n.type,"Invalid GLB magic string ".concat(n.type)),e._glb=n,e.json=n.json}else oB(!1,"GLTF: must be ArrayBuffer or string");var s=e.json.buffers||[];if(e.buffers=new Array(s.length).fill(null),e._glb&&e._glb.header.hasBinChunk){var o=e._glb.binChunks;e.buffers[0]={arrayBuffer:o[0].arrayBuffer,byteOffset:o[0].byteOffset,byteLength:o[0].byteLength}}var a=e.json.images||[];e.images=new Array(a.length).fill({})}function RM(e,t,i){return OM.apply(this,arguments)}function OM(){return(OM=a(s().mark(function e(t,i,r){var n,o,a,l,u,c,h,A;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:n=t.json.buffers||[],o=0;case 2:if(!(o<n.length)){e.next=22;break}if(!(a=n[o]).uri){e.next=18;break}return oB(r.fetch),c=aB(a.uri,i),e.next=10,null==r||null===(l=r.fetch)||void 0===l?void 0:l.call(r,c);case 10:return h=e.sent,e.next=13,null==h||null===(u=h.arrayBuffer)||void 0===u?void 0:u.call(h);case 13:A=e.sent,t.buffers[o]={arrayBuffer:A,byteOffset:0,byteLength:A.byteLength},delete a.uri,e.next=19;break;case 18:null===t.buffers[o]&&(t.buffers[o]={arrayBuffer:new ArrayBuffer(a.byteLength),byteOffset:0,byteLength:a.byteLength});case 19:++o,e.next=2;break;case 22:case"end":return e.stop()}},e)}))).apply(this,arguments)}function LM(e,t,i){return jM.apply(this,arguments)}function jM(){return(jM=a(s().mark(function e(t,i,r){var n,o,a,l,c,h;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:n=UM(t),o=t.json.images||[],a=[],l=u(n);try{for(l.s();!(c=l.n()).done;)h=c.value,a.push(NM(t,o[h],h,i,r))}catch(e){l.e(e)}finally{l.f()}return e.next=7,Promise.all(a);case 7:return e.abrupt("return",e.sent);case 8:case"end":return e.stop()}},e)}))).apply(this,arguments)}function UM(e){var t,i=new Set,r=u(e.json.textures||[]);try{for(r.s();!(t=r.n()).done;){var n=t.value;void 0!==n.source&&i.add(n.source)}}catch(e){r.e(e)}finally{r.f()}return Array.from(i).sort()}function NM(e,t,i,r,n){return VM.apply(this,arguments)}function VM(){return VM=a(s().mark(function e(t,i,r,n,o){var a,l,u,c,h,A,d;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(a=o.fetch,l=o.parse,!i.uri||i.hasOwnProperty("bufferView")){e.next=10;break}return c=aB(i.uri,n),e.next=5,a(c);case 5:return h=e.sent,e.next=8,h.arrayBuffer();case 8:u=e.sent,i.bufferView={data:u};case 10:return Number.isFinite(i.bufferView)&&(A=lB(t.json,t.buffers,i.bufferView),u=rB(A.buffer,A.byteOffset,A.byteLength)),oB(u,"glTF image has no data"),e.next=14,l(u,[Jx,fx],{mimeType:i.mimeType,basis:n.basis||{format:px()}},o);case 14:(d=e.sent)&&d[0]&&(d={compressed:!0,mipmaps:!1,width:d[0].width,height:d[0].height,data:d[0]}),t.images=t.images||[],t.images[r]=d;case 18:case"end":return e.stop()}},e)})),VM.apply(this,arguments)}var QM={name:"glTF",id:"gltf",module:"gltf",version:"3.4.15",extensions:["gltf","glb"],mimeTypes:["model/gltf+json","model/gltf-binary"],text:!0,binary:!0,tests:["glTF"],parse:function(e){return HM.apply(this,arguments)},options:{gltf:{normalize:!0,loadBuffers:!0,loadImages:!0,decompressMeshes:!0,postProcess:!0},log:console},deprecatedOptions:{fetchImages:"gltf.loadImages",createImages:"gltf.loadImages",decompress:"gltf.decompressMeshes",postProcess:"gltf.postProcess",gltf:{decompress:"gltf.decompressMeshes"}}};function HM(){return HM=a(s().mark(function e(t){var i,r,o,a,l,u=arguments;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return i=u.length>1&&void 0!==u[1]?u[1]:{},r=u.length>2?u[2]:void 0,(i=n(n({},QM.options),i)).gltf=n(n({},QM.options.gltf),i.gltf),o=i.byteOffset,a=void 0===o?0:o,l={},e.next=8,IM(l,t,a,i,r);case 8:return e.abrupt("return",e.sent);case 9:case"end":return e.stop()}},e)})),HM.apply(this,arguments)}var GM=function(){return P(function e(t){x(this,e)},[{key:"load",value:function(e,t,i,r,n,s,o){!function(e,t,i,r,n,s,o){var a=e.viewer.scene.canvas.spinner;a.processes++;var l="glb"===t.split(".").pop();l?e.dataSource.getGLB(t,function(o){r.basePath=zM(t),WM(e,t,o,i,r,n,s),a.processes--},function(e){a.processes--,o(e)}):e.dataSource.getGLTF(t,function(o){r.basePath=zM(t),WM(e,t,o,i,r,n,s),a.processes--},function(e){a.processes--,o(e)})}(e,t,i,r=r||{},n,function(){Ae.scheduleTask(function(){n.scene.fire("modelLoaded",n.id),n.fire("loaded",!0,!1)}),s&&s()},function(t){e.error(t),o&&o(t),n.fire("error",t)})}},{key:"parse",value:function(e,t,i,r,n,s,o){WM(e,"",t,i,r=r||{},n,function(){n.scene.fire("modelLoaded",n.id),n.fire("loaded",!0,!1),s&&s()})}}])}();function zM(e){var t=e.lastIndexOf("/");return 0!==t?e.substring(0,t+1):""}function WM(e,t,i,r,n,s,o){var a=e.viewer.scene.canvas.spinner;a.processes++,aw(i,QM,{baseUri:n.basePath}).then(function(i){var l={src:t,entityId:n.entityId,metaModelJSON:r,autoMetaModel:n.autoMetaModel,globalizeObjectIds:n.globalizeObjectIds,metaObjects:[],loadBuffer:n.loadBuffer,basePath:n.basePath,handlenode:n.handlenode,backfaces:!!n.backfaces,gltfData:i,scene:s.scene,plugin:e,sceneModel:s,numObjects:0,nodes:[],nextId:0,log:function(t){e.log(t)}};!function(e){var t=e.gltfData,i=t.textures;if(i)for(var r=0,n=i.length;r<n;r++)KM(e,i[r]);else console.log("no texture")}(l),function(e){var t=e.gltfData,i=t.materials;if(i)for(var r=0,n=i.length;r<n;r++){var s=i[r];s._textureSetId=XM(e,s),s._attributes=qM(e,s)}}(l),n.autoMetaModel&&l.metaObjects.push({id:s.id,type:"Default",name:s.id}),function(e){var t=e.gltfData,i=t.scene||t.scenes[0];if(!i)return void function(e,t){e.plugin.error(t)}(e,"glTF has no default scene");var r=i.nodes;if(!r)return;!function e(t){t.forEach(function(t){var i=t.mesh;i&&(i.instances||(i.instances=0),i.instances+=1),t.children&&e(t.children)})}(r);var n=[],s=null;!function t(i,r,o){i.forEach(function(i){var a=i.name,l=null!=a&&a||0===r&&"entity-"+e.nextId++;if(l){for(;e.sceneModel.objects[l];)l="entity-"+e.nextId++;n.push(s),s=[]}var u=function(e,t){var i;e.matrix&&(i=e.matrix,t=t?Y.mulMat4(t,i,Y.mat4()):i);e.translation&&(i=Y.translationMat4v(e.translation),t=t?Y.mulMat4(t,i,Y.mat4()):i);e.rotation&&(i=Y.quaternionToMat4(e.rotation),t=t?Y.mulMat4(t,i,Y.mat4()):i);e.scale&&(i=Y.scalingMat4v(e.scale),t=t?Y.mulMat4(t,i,Y.mat4()):i);return t}(i,o);if(i.mesh&&function(e,t,i,r){var n=e.mesh;if(!n)return;var s=n.primitives.length;if(s>0)for(var o=0;o<s;o++){var a=n.primitives[o];if(!(a.mode<4)){var l={id:t.sceneModel.id+"."+t.numObjects++},u=a.material;u?(l.textureSetId=u._textureSetId,l.color=u._attributes.color,l.opacity=u._attributes.opacity,l.metallic=u._attributes.metallic,l.roughness=u._attributes.roughness):(l.color=new Float32Array([1,1,1]),l.opacity=1);var c=!1!==t.backfaces||u&&!1!==u.doubleSided;switch(a.mode){case 0:l.primitive="points";break;case 1:case 2:case 3:l.primitive="lines";break;default:l.primitive=c?"triangles":"solid"}var h=a.attributes.POSITION;if(h){l.localPositions=h.value,l.positions=new Float64Array(l.localPositions.length),a.attributes.NORMAL&&(l.normals=a.attributes.NORMAL.value),a.attributes.TEXCOORD_0&&(l.uv=a.attributes.TEXCOORD_0.value),a.indices&&(l.indices=a.indices.value),i?Y.transformPositions3(i,l.localPositions,l.positions):l.positions.set(l.localPositions);var A=Y.vec3();we(l.positions,l.positions,A)&&(l.origin=A),t.sceneModel.createMesh(l),r.push(l.id)}}}}(i,e,u,s),i.children&&t(i.children,r+1,u),l){if(s.length>0){var c=e.globalizeObjectIds?Y.globalizeObjectId(e.sceneModel.id,l):l;e.sceneModel.createEntity({id:c,meshIds:s,isObject:!0}),e.autoMetaModel&&e.metaObjects.push({id:c,type:"Default",name:c,parent:e.sceneModel.id})}s=n.pop()}})}(r,0,null)}(l),s.finalize(),n.autoMetaModel&&e.viewer.metaScene.createMetaModel(s.id,{metaObjects:l.metaObjects}),a.processes--,o()})}function KM(e,t){if(t.source&&t.source.image){var i="texture-".concat(e.nextId++),r=Ji;switch(t.sampler.minFilter){case 9728:r=qi;break;case 9729:r=Zi;break;case 9984:r=Yi;break;case 9985:r=$i;break;case 9986:r=Ji;break;case 9987:r=tr}var n=Zi;switch(t.sampler.magFilter){case 9728:n=qi;break;case 9729:n=Zi}var s=Wi;switch(t.sampler.wrapS){case 33071:s=Ki;break;case 33648:s=Xi;break;case 10497:s=Wi}var o=Wi;switch(t.sampler.wrapT){case 33071:o=Ki;break;case 33648:o=Xi;break;case 10497:o=Wi}var a=Wi;switch(t.sampler.wrapR){case 33071:a=Ki;break;case 33648:a=Xi;break;case 10497:a=Wi}e.sceneModel.createTexture({id:i,image:t.source.image,flipY:!!t.flipY,minFilter:r,magFilter:n,wrapS:s,wrapT:o,wrapR:a,encoding:pr}),t._textureId=i}}function XM(e,t){var i={};switch(t.normalTexture&&(i.normalTextureId=t.normalTexture.texture._textureId),t.occlusionTexture&&(i.occlusionTextureId=t.occlusionTexture.texture._textureId),t.emissiveTexture&&(i.emissiveTextureId=t.emissiveTexture.texture._textureId),t.alphaMode){case"OPAQUE":break;case"MASK":var r=t.alphaCutoff;i.alphaCutoff=void 0!==r?r:.5}var n=t.pbrMetallicRoughness;if(t.pbrMetallicRoughness){var s=t.pbrMetallicRoughness,o=s.baseColorTexture||s.colorTexture;o&&(o.texture?i.colorTextureId=o.texture._textureId:i.colorTextureId=e.gltfData.textures[o.index]._textureId),n.metallicRoughnessTexture&&(i.metallicRoughnessTextureId=n.metallicRoughnessTexture.texture._textureId)}var a=t.extensions;if(a){var l=a.KHR_materials_pbrSpecularGlossiness;if(l){l.specularTexture;var u=l.specularColorTexture;null!=u&&(i.colorTextureId=e.gltfData.textures[u.index]._textureId)}}return void 0!==i.normalTextureId||void 0!==i.occlusionTextureId||void 0!==i.emissiveTextureId||void 0!==i.colorTextureId||void 0!==i.metallicRoughnessTextureId?(i.id="textureSet-".concat(e.nextId++,";"),e.sceneModel.createTextureSet(i),i.id):null}function qM(e,t){var i=t.extensions,r={color:new Float32Array([1,1,1,1]),opacity:1,metallic:0,roughness:1,doubleSided:!0};if(i){var n=i.KHR_materials_pbrSpecularGlossiness;if(n){var s=n.diffuseFactor;null!=s&&r.color.set(s)}var o=i.KHR_materials_common;if(o){var a=o.technique,l=o.values||{},u="BLINN"===a,c="PHONG"===a,h="LAMBERT"===a,A=l.diffuse;A&&(u||c||h)&&(ne.isString(A)||r.color.set(A));var d=l.transparency;null!=d&&(r.opacity=d);var p=l.transparent;null!=p&&(r.opacity=p)}}var f=t.pbrMetallicRoughness;if(f){var g=f.baseColorFactor;g&&(r.color[0]=g[0],r.color[1]=g[1],r.color[2]=g[2],r.opacity=g[3]);var m=f.metallicFactor;null!=m&&(r.metallic=m);var v=f.roughnessFactor;null!=v&&(r.roughness=v)}return r.doubleSided=!1!==t.doubleSided,r}var YM={DEFAULT:{}},JM=function(){function e(t){var i,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return x(this,e),(i=d(this,e,["GLTFLoader",t,r]))._sceneModelLoader=new GM(i,r),i.dataSource=r.dataSource,i.objectDefaults=r.objectDefaults,i}return _(e,ge),P(e,[{key:"dataSource",get:function(){return this._dataSource},set:function(e){this._dataSource=e||new _h}},{key:"objectDefaults",get:function(){return this._objectDefaults},set:function(e){this._objectDefaults=e||YM}},{key:"load",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};t.id&&this.viewer.scene.components[t.id]&&(this.error("Component with this ID already exists in viewer: "+t.id+" - will autogenerate this ID"),delete t.id);var i=new $c(this.viewer.scene,ne.apply(t,{isModel:!0,dtxEnabled:t.dtxEnabled})),r=i.id;if(!t.src&&!t.gltf)return this.error("load() param expected: src or gltf"),i;if(t.metaModelSrc||t.metaModelJSON){var n=function(n){e.viewer.metaScene.createMetaModel(r,n,{}),e.viewer.scene.canvas.spinner.processes--,t.src?e._sceneModelLoader.load(e,t.src,n,t,i):e._sceneModelLoader.parse(e,t.gltf,n,t,i)};if(t.metaModelSrc){var s=t.metaModelSrc;this.viewer.scene.canvas.spinner.processes++,this._dataSource.getMetaModel(s,function(t){e.viewer.scene.canvas.spinner.processes--,n(t)},function(t){e.error("load(): Failed to load model metadata for model '".concat(r," from '").concat(s,"' - ").concat(t)),e.viewer.scene.canvas.spinner.processes--})}else t.metaModelJSON&&n(t.metaModelJSON)}else t.src?this._sceneModelLoader.load(this,t.src,null,t,i):this._sceneModelLoader.parse(this,t.gltf,null,t,i);return i.once("destroyed",function(){e.viewer.metaScene.destroyMetaModel(r)}),i}},{key:"destroy",value:function(){g(e,"destroy",this,3)([])}}])}();function ZM(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r="lightgrey",n=i.hoverColor||"rgba(60,120,125,0.3)",s=i.textColor||"rgba(15,75,80,0.8)",o=500,a=o+o/3,l=a/24,u=e.scene.camera.normalUp,c=[{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"}],h=[{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;var A=[{areaId:0,label:"NavCube.front",boundaries:[[7,7,4,4]],dir:[0,0,-1],up:[0,1,0]},{areaId:1,label:"NavCube.back",boundaries:[[19,7,4,4]],dir:[0,0,1],up:[0,1,0]},{areaId:2,label:"NavCube.right",boundaries:[[13,7,4,4]],dir:[-1,0,0],up:[0,1,0]},{areaId:3,label:"NavCube.left",boundaries:[[1,7,4,4]],dir:[1,0,0],up:[0,1,0]},{areaId:4,label:"NavCube.top",boundaries:[[7,1,4,4]],dir:[0,-1,0],up:[0,0,-1]},{areaId:5,label:"NavCube.bottom",boundaries:[[7,13,4,4]],dir:[0,1,0],up:[0,0,1]},{areaId:6,boundaries:[[7,5,4,2]],dir:[0,-.7071,-.7071],up:[0,.7071,-.7071]},{areaId:7,boundaries:[[1,6,4,1],[6,1,1,4]],dir:[1,-1,0],up:[1,1,0]},{areaId:8,boundaries:[[7,0,4,1],[19,6,4,1]],dir:[0,-.7071,.7071],up:[0,.7071,.7071]},{areaId:9,boundaries:[[13,6,4,1],[11,1,1,4]],dir:[-1,-1,0],up:[-1,1,0]},{areaId:10,boundaries:[[7,11,4,2]],dir:[0,1,-1],up:[0,1,1]},{areaId:11,boundaries:[[1,11,4,1],[6,13,1,4]],dir:[1,1,0],up:[-1,1,0]},{areaId:12,boundaries:[[7,17,4,1],[19,11,4,1]],dir:[0,1,1],up:[0,1,-1]},{areaId:13,boundaries:[[13,11,4,1],[11,13,1,4]],dir:[-1,1,0],up:[1,1,0]},{areaId:14,boundaries:[[5,7,2,4]],dir:[1,0,-1],up:[0,1,0]},{areaId:15,boundaries:[[11,7,2,4]],dir:[-1,0,-1],up:[0,1,0]},{areaId:16,boundaries:[[17,7,2,4]],dir:[-1,0,1],up:[0,1,0]},{areaId:17,boundaries:[[0,7,1,4],[23,7,1,4]],dir:[1,0,1],up:[0,1,0]},{areaId:18,boundaries:[[5,11,2,2]],dir:[.5,.7071,-.5],up:[-.5,.7071,.5]},{areaId:19,boundaries:[[23,11,1,1],[6,17,1,1],[0,11,1,1]],dir:[.5,.7071,.5],up:[-.5,.7071,-.5]},{areaId:20,boundaries:[[5,5,2,2]],dir:[.5,-.7071,-.5],up:[.5,.7071,-.5]},{areaId:21,boundaries:[[11,17,1,1],[17,11,2,1]],dir:[-.5,.7071,.5],up:[.5,.7071,-.5]},{areaId:22,boundaries:[[17,6,2,1],[11,0,1,1]],dir:[-.5,-.7071,.5],up:[-.5,.7071,.5]},{areaId:23,boundaries:[[11,11,2,2]],dir:[-.5,.7071,-.5],up:[.5,.7071,.5]},{areaId:24,boundaries:[[0,6,1,1],[6,0,1,1],[23,6,1,1]],dir:[.5,-.7071,.5],up:[.5,.7071,.5]},{areaId:25,boundaries:[[11,5,2,2]],dir:[-.5,-.7071,-.5],up:[-.5,.7071,-.5]}],d=[{areaId:0,label:"NavCube.front",boundaries:[[7,7,4,4]],dir:[0,0,-1],up:[0,-1,0]},{areaId:1,label:"NavCube.back",boundaries:[[19,7,4,4]],dir:[0,0,1],up:[0,-1,0]},{areaId:2,label:"NavCube.right",boundaries:[[13,7,4,4]],dir:[1,0,0],up:[0,-1,0]},{areaId:3,label:"NavCube.left",boundaries:[[1,7,4,4]],dir:[-1,0,0],up:[0,-1,0]},{areaId:4,label:"NavCube.top",boundaries:[[7,1,4,4]],dir:[0,1,0],up:[0,0,-1]},{areaId:5,label:"NavCube.bottom",boundaries:[[7,13,4,4]],dir:[0,-1,0],up:[0,0,1]},{areaId:6,boundaries:[[7,5,4,2]],dir:[0,1,-1],up:[0,1,1]},{areaId:7,boundaries:[[1,6,4,1],[6,1,1,4]],dir:[-1,1,0],up:[1,1,0]},{areaId:8,boundaries:[[7,0,4,1],[19,6,4,1]],dir:[0,1,1],up:[0,1,-1]},{areaId:9,boundaries:[[13,6,4,1],[11,1,1,4]],dir:[1,1,0],up:[-1,1,0]},{areaId:10,boundaries:[[7,11,4,2]],dir:[0,-.7071,-.7071],up:[0,.7071,-.7071]},{areaId:11,boundaries:[[1,11,4,1],[6,13,1,4]],dir:[-1,-1,0],up:[-1,1,0]},{areaId:12,boundaries:[[7,17,4,1],[19,11,4,1]],dir:[0,-.7071,.7071],up:[0,.7071,.7071]},{areaId:13,boundaries:[[13,11,4,1],[11,13,1,4]],dir:[1,-1,0],up:[1,1,0]},{areaId:14,boundaries:[[5,7,2,4]],dir:[-1,0,-1],up:[0,1,0]},{areaId:15,boundaries:[[11,7,2,4]],dir:[1,0,-1],up:[0,1,0]},{areaId:16,boundaries:[[17,7,2,4]],dir:[1,0,1],up:[0,1,0]},{areaId:17,boundaries:[[0,7,1,4],[23,7,1,4]],dir:[-1,0,1],up:[0,1,0]},{areaId:18,boundaries:[[5,11,2,2]],dir:[-.5,-.7071,-.5],up:[-.5,.7071,-.5]},{areaId:19,boundaries:[[23,11,1,1],[6,17,1,1],[0,11,1,1]],dir:[-.5,-.7071,.5],up:[-.5,.7071,.5]},{areaId:20,boundaries:[[5,5,2,2]],dir:[-.5,.7071,-.5],up:[.5,.7071,.5]},{areaId:21,boundaries:[[11,17,1,1],[17,11,2,1]],dir:[.5,-.7071,.5],up:[.5,.7071,.5]},{areaId:22,boundaries:[[17,6,2,1],[11,0,1,1]],dir:[.5,.7071,.5],up:[-.5,.7071,-.5]},{areaId:23,boundaries:[[11,11,2,2]],dir:[.5,-.7071,-.5],up:[.5,.7071,-.5]},{areaId:24,boundaries:[[0,6,1,1],[6,0,1,1],[23,6,1,1]],dir:[-.5,.7071,.5],up:[.5,.7071,-.5]},{areaId:25,boundaries:[[11,5,2,2]],dir:[.5,.7071,-.5],up:[-.5,.7071,.5]}];d.forEach(function(e){e.areaId>5&&(e.up=[-1*e.up[0],-1*e.up[1],-1*e.up[2]])});for(var p=u?A:d,f=0,g=h.length;f<g;f++)Y.normalizeVec3(h[f].dir,h[f].dir),Y.normalizeVec3(h[f].up,h[f].up);for(var m=0,v=p.length;m<v;m++)Y.normalizeVec3(p[m].dir,p[m].dir),Y.normalizeVec3(p[m].up,p[m].up);var _=p;this._textureCanvas=document.createElement("canvas"),this._textureCanvas.width=a,this._textureCanvas.height=o,this._textureCanvas.style.width=a+"px",this._textureCanvas.style.height=o+"px",this._textureCanvas.style.padding="0",this._textureCanvas.style.margin="0",this._textureCanvas.style.top="0",this._textureCanvas.style.background=r,this._textureCanvas.style.position="absolute",this._textureCanvas.style.opacity="1.0",this._textureCanvas.style.display="none",this._textureCanvas.style["z-index"]=-100,this._textureCanvas.setAttribute("id","myNavCubeRenderImage"),this.cubeParentDiv=document.createElement("div"),this.cubeParentDiv.setAttribute("id","myNavCubeRenderImage_parent"),this.cubeContainer=i.viewerElement,this.cubeParentDiv.appendChild(this._textureCanvas),this.cubeContainer.appendChild(this.cubeParentDiv);var y=this._textureCanvas.getContext("2d"),b=!1;function w(){for(var e=0,i=c.length;e<i;e++){var o=c[e],a=o.boundary,u=Math.round(a[0]*l),h=Math.round(a[1]*l),A=Math.round(a[2]*l),d=Math.round(a[3]*l);y.fillStyle=o.color,y.fillRect(u,h,A,d)}for(var p=0,f=_.length;p<f;p++){for(var g=void 0,m=void 0,v=void 0,b=void 0,w=_[p],x=w.boundaries,B=0,P=x.length;B<P;B++){var M=x[B];g=Math.round(M[0]*l),m=Math.round(M[1]*l),v=Math.round(M[2]*l),b=Math.round(M[3]*l),w.highlighted&&(y.fillStyle=w.highlighted?n:w.color||r,y.fillRect(g,m,v,b))}if(w.label){y.fillStyle=s,y.font="60px sans-serif",y.textAlign="center";var k=g+.5*v,E=m+.7*b;y.fillText(C(w.label),k,E,80)}}t.glRedraw()}var x,B,P,C=(x={"NavCube.front":"NavCube.front","NavCube.back":"NavCube.back","NavCube.right":"NavCube.right","NavCube.left":"NavCube.left","NavCube.top":"NavCube.top","NavCube.bottom":"NavCube.bottom"},B={"NavCube.front":"NavCube.front","NavCube.back":"NavCube.back","NavCube.right":"NavCube.right","NavCube.left":"NavCube.left","NavCube.top":"NavCube.top","NavCube.bottom":"NavCube.bottom"},P={"NavCube.front":"FRONT","NavCube.back":"BACK","NavCube.right":"RIGHT","NavCube.left":"LEFT","NavCube.top":"TOP","NavCube.bottom":"BOTTOM"},function(t){var i=b?B:x,r=i?i[t]:null;return r?e.localeService.translate(r)||P[r]||r:t});this.setZUp=function(){b=!0,_=h,this.clear()},this.setYUp=function(){u=e.scene.camera.normalUp,b=!1,_=u?A:d,this.clear()},this.clear=function(){y.fillStyle=r,y.fillRect(0,0,a,o);for(var e=0,t=_.length;e<t;e++){_[e].highlighted=!1}w()},this.getArea=function(e){for(var t=e[0]*a,i=o-e[1]*o,r=0,n=_.length;r<n;r++)for(var s=_[r].boundaries,u=0,c=s.length;u<c;u++){var h=s[u];if(t>=h[0]*l&&t<=(h[0]+h[2])*l&&i>=h[1]*l&&i<=(h[1]+h[3])*l)return r}return-1},this.setAreaHighlighted=function(e,t){var i=_[e];if(!i)throw"Area not found: "+e;i.highlighted=!!t,w()},this.getAreaDir=function(e){var t=_[e];if(!t)throw"Unknown area: "+e;return t.dir},this.getAreaUp=function(e){var t=_[e];if(!t)throw"Unknown area: "+e;return t.up},this.getImage=function(){return this._textureCanvas},this.destroy=function(){this._textureCanvas&&(this._textureCanvas.parentNode.removeChild(this._textureCanvas),this._textureCanvas=null),this.cubeParentDiv&&(this.cubeParentDiv.parentNode.removeChild(this.cubeParentDiv),this.cubeParentDiv=null)}}var $M=Y.vec3(),ek=Y.vec3();Y.mat4();var tk=function(){function e(t){var i,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};x(this,e),i=d(this,e,["NavCube",t,r]),t.navCube=i;try{i._navCubeScene=new zi(t,{canvasId:r.canvasId,canvasElement:r.canvasElement,transparent:!0,spinnerElementId:"navcube_spinner",edgesEnabled:!0,contextAttr:{antialias:!0},resolutionScale:window.devicePixelRatio,worldAxis:t.scene.camera.worldAxis}),i._navCubeCanvas=i._navCubeScene.canvas.canvas,i._navCubeScene.input.keyboardEnabled=!1}catch(e){return i.error(e),p(i)}var n=i._navCubeScene;n.clearLights(),new hi(n,{dir:[.4,-.4,.8],color:[.8,1,1],intensity:.8,space:"view"}),new hi(n,{dir:[-.8,-.3,-.4],color:[.8,.8,.8],intensity:.8,space:"view"}),new hi(n,{dir:[.8,-.6,-.8],color:[1,1,1],intensity:.8,space:"view"}),i._navCubeCamera=n.camera,i._navCubeCamera.ortho.scale=7,i._navCubeCamera.ortho.near=.1,i._navCubeCamera.ortho.far=2e3,n.edgeMaterial.edgeColor=[.47,.62,.67],n.edgeMaterial.edgeAlpha=.2,n.edgeMaterial.edgeWidth=1,i._zUp=Boolean(t.camera.zUp);var s=i;i.mousedown=!1,i.mouseover=!1,i.setIsProjectNorth(r.isProjectNorth),i.setProjectNorthOffsetAngle(r.projectNorthOffsetAngle);var o,a=i.rotateTrueNorth=(o=Y.mat4(),function(e,t,i){return Y.identityMat4(o),Y.rotationMat4v(e*s._projectNorthOffsetAngle*Y.DEGTORAD,[0,1,0],o),Y.transformVec3(o,t,i)}),l=!1;t.scene.on("aabb",function(){l=t.scene.camera.normalUp}),i._synchCamera=function(){var e=Y.rotationMat4c(-90*Y.DEGTORAD,1,0,0),i=Y.vec3(),r=Y.vec3(),n=Y.vec3();return function(){var o=t.camera.eye,u=t.camera.look,c=t.camera.up;i=Y.mulVec3Scalar(Y.normalizeVec3(Y.subVec3(o,u,i)),5),s._isProjectNorth&&s._projectNorthOffsetAngle&&(i=a(-1,i,$M),c=a(-1,c,ek)),s._zUp?(Y.transformVec3(e,i,r),Y.transformVec3(e,c,n),s._navCubeCamera.look=[0,0,0],s._navCubeCamera.eye=Y.transformVec3(e,i,r),s._navCubeCamera.up=Y.transformPoint3(e,c,n)):(s._navCubeCamera.look=[0,0,0],s._navCubeCamera.eye=l?i:Y.mulVec3(i,[-1,-1,1]),s._navCubeCamera.up=l?c:Y.mulVec3Scalar(c,-1))}}(),i._cubeTextureCanvas=new ZM(t,n,r),i._cubeSampler=new En(n,{image:i._cubeTextureCanvas.getImage(),flipY:!0,wrapS:Ki,wrapT:Ki}),i._cubeMesh=new on(n,{geometry:new Ci(n,{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 Ti(n,{diffuse:[.4,.4,.4],specular:[.4,.4,.4],emissive:[.6,.6,.6],diffuseMap:i._cubeSampler,emissiveMap:i._cubeSampler}),visible:!0,edges:!0}),i._shadow=!1===r.shadowVisible?null:new on(n,{geometry:new Ci(n,ln({center:[0,0,0],radiusTop:.001,radiusBottom:1.4,height:.01,radialSegments:20,heightSegments:1,openEnded:!0})),material:new Ti(n,{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}),i._onCameraMatrix=t.camera.on("matrix",i._synchCamera),i._onCameraWorldAxis=t.camera.on("worldAxis",function(){t.camera.zUp?(i._zUp=!0,i._cubeTextureCanvas.setZUp(),i._repaint(),i._synchCamera()):t.camera.yUp&&(i._zUp=!1,i._cubeTextureCanvas.setYUp(),i._repaint(),i._synchCamera()),l=t.scene.camera.normalUp}),i._onCameraFOV=t.camera.perspective.on("fov",function(e){i._synchProjection&&(i._navCubeCamera.perspective.fov=e)}),i._onCameraProjection=t.camera.on("projection",function(e){i._synchProjection&&(i._navCubeCamera.projection="ortho"===e||"perspective"===e?e:"perspective")});var u=-1;function c(e){var t=[0,0];if(e){for(var i=e.target,r=0,n=0;i.offsetParent;)r+=i.offsetLeft,n+=i.offsetTop,i=i.offsetParent;t[0]=e.pageX-r,t[1]=e.pageY-n}else e=window.event,t[0]=e.x,t[1]=e.y;return t}var h=null,A=null,f=!1;s.MOUSEDOWN=!1;var g=!1;s.MOUSEOVER=!1;var m,v,_=.5;s._navCubeCanvas.addEventListener("mouseenter",s._onMouseEnter=function(e){g=!0,s.MOUSEOVER=!0}),s._navCubeCanvas.addEventListener("mouseleave",s._onMouseLeave=function(e){g=!1,s.MOUSEOVER=!1}),s._navCubeCanvas.addEventListener("mousedown",s._onMouseDown=function(e){if(1===e.which){h=e.x,A=e.y,m=e.clientX,v=e.clientY;var t=c(e);n.pick({canvasPos:t})?(f=!0,s.MOUSEDOWN=!0):(f=!1,s.MOUSEDOWN=!1)}}),document.addEventListener("mouseup",s._onMouseUp=function(e){if(1===e.which&&(f=!1,s.MOUSEDOWN=!1,null!==h)){var t=c(e),i=n.pick({canvasPos:t,pickSurface:!0});if(i&&i.uv){var r=s._cubeTextureCanvas.getArea(i.uv);if(r>=0&&(u>=0&&(s._cubeTextureCanvas.setAreaHighlighted(u,!1),s._repaint(),u=-1),r>=0)){if(s._cubeTextureCanvas.setAreaHighlighted(r,!0),u=r,s._repaint(),e.x<h-3||e.x>h+3||e.y<A-3||e.y>A+3)return;var o=s._cubeTextureCanvas.getAreaDir(r);if(o){var l=s._cubeTextureCanvas.getAreaUp(r);s._isProjectNorth&&s._projectNorthOffsetAngle&&(o=a(1,o,$M),l=a(1,l,ek)),y(o,l,function(){u>=0&&(s._cubeTextureCanvas.setAreaHighlighted(u,!1),s._repaint(),u=-1),u>=0&&(s._cubeTextureCanvas.setAreaHighlighted(u,!1),s._repaint(),u=-1),r>=0&&(s._cubeTextureCanvas.setAreaHighlighted(r,!1),u=-1,s._repaint())})}}}}}),document.addEventListener("mousemove",s._onMouseMove=function(e){if(u>=0&&(s._cubeTextureCanvas.setAreaHighlighted(u,!1),s._repaint(),u=-1),1!==e.buttons||f){if(f){var i=e.clientX,r=e.clientY;return document.body.style.cursor="move",void function(e,i){var r=(e-m)*-_,n=(i-v)*-_;t.camera.orbitYaw(r),t.camera.orbitPitch(-n),m=e,v=i}(i,r)}if(g){var o=c(e),a=n.pick({canvasPos:o,pickSurface:!0});if(a){if(a.uv){document.body.style.cursor="pointer";var l=s._cubeTextureCanvas.getArea(a.uv);if(l===u)return;u>=0&&s._cubeTextureCanvas.setAreaHighlighted(u,!1),l>=0&&(s._cubeTextureCanvas.setAreaHighlighted(l,!0),s._repaint(),u=l)}}else document.body.style.cursor="default",u>=0&&(s._cubeTextureCanvas.setAreaHighlighted(u,!1),s._repaint(),u=-1)}}});var y=i.flyTo=function(){var e=Y.vec3();return function(i,r,n){var o=s._fitVisible?t.scene.getAABB(t.scene.visibleObjectIds):t.scene.aabb,a=Y.getAABB3Diag(o);Y.getAABB3Center(o,e);var l=Math.abs(a/Math.tan(s._cameraFitFOV*Y.DEGTORAD));t.cameraControl.pivotPos=e,s._cameraFly?t.cameraFlight.flyTo({look:e,eye:[e[0]-l*i[0],e[1]-l*i[1],e[2]-l*i[2]],up:r||[0,1,0],orthoScale:1.1*a,fitFOV:s._cameraFitFOV,duration:s._cameraFlyDuration},n):t.cameraFlight.jumpTo({look:e,eye:[e[0]-l*i[0],e[1]-l*i[1],e[2]-l*i[2]],up:r||[0,1,0],orthoScale:1.1*a,fitFOV:s._cameraFitFOV},n)}}();return i._onUpdated=t.localeService.on("updated",function(){i._cubeTextureCanvas.clear(),i._repaint()}),i.setVisible(r.visible),i.setCameraFitFOV(r.cameraFitFOV),i.setCameraFly(r.cameraFly),i.setCameraFlyDuration(r.cameraFlyDuration),i.setFitVisible(r.fitVisible),i.setSynchProjection(r.synchProjection),i}return _(e,ge),P(e,[{key:"flyByClick",value:function(e,t){if(e>=0){this._cubeTextureCanvas.setAreaHighlighted(e,!0),this._repaint();var i=this._cubeTextureCanvas.getAreaDir(e);if(i){var r=this._cubeTextureCanvas.getAreaUp(e);this._isProjectNorth&&this._projectNorthOffsetAngle&&(i=this.rotateTrueNorth(1,i,$M),r=this.rotateTrueNorth(1,r,ek)),this.flyTo(i,r,t)}}}},{key:"jumpByClick",value:function(e){this.setCameraFly(!1),this.flyByClick(e),this.setCameraFly(!0)}},{key:"navCubeScene",get:function(){return this._navCubeScene}},{key:"MOUSEDOWN",get:function(){return this.mousedown},set:function(e){this.mousedown=e}},{key:"MOUSEOVER",get:function(){return this.mouseover},set:function(e){this.mouseover=e}},{key:"send",value:function(e,t){if("language"===e)this._cubeTextureCanvas.clear(),this._repaint()}},{key:"_repaint",value:function(){var e=this._cubeTextureCanvas.getImage();this._cubeMesh.material.diffuseMap.image=e,this._cubeMesh.material.emissiveMap.image=e}},{key:"setVisible",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];this._navCubeCanvas&&(this._cubeMesh.visible=e,this._shadow&&(this._shadow.visible=e),this._navCubeCanvas.style.visibility=e?"visible":"hidden")}},{key:"getVisible",value:function(){return!!this._navCubeCanvas&&this._cubeMesh.visible}},{key:"setFitVisible",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this._fitVisible=e}},{key:"getFitVisible",value:function(){return this._fitVisible}},{key:"setCameraFly",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];this._cameraFly=e}},{key:"getCameraFly",value:function(){return this._cameraFly}},{key:"setCameraFitFOV",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:45;this._cameraFitFOV=e}},{key:"getCameraFitFOV",value:function(){return this._cameraFitFOV}},{key:"setCameraFlyDuration",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:.5;this._cameraFlyDuration=e}},{key:"getCameraFlyDuration",value:function(){return this._cameraFlyDuration}},{key:"setSynchProjection",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this._synchProjection=e}},{key:"getSynchProjection",value:function(){return this._synchProjection}},{key:"setIsProjectNorth",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this._isProjectNorth=e}},{key:"getIsProjectNorth",value:function(){return this._isProjectNorth}},{key:"setProjectNorthOffsetAngle",value:function(e){this._projectNorthOffsetAngle=e}},{key:"getProjectNorthOffsetAngle",value:function(){return this._projectNorthOffsetAngle}},{key:"destroy",value:function(){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),document.removeEventListener("mousemove",this._onMouseMove),document.removeEventListener("mouseup",this._onMouseUp),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._navCubeScene.destroy(),this._navCubeScene=null,this._cubeMesh=null,this._shadow=null,g(e,"destroy",this,3)([])}}])}(),ik=new Float64Array([0,0,1]),rk=new Float64Array(4),nk=function(){return P(function e(t){x(this,e),this.id=null,this.type="control",this.plugin=t,this._viewer=t.viewer,this._scene=t.viewer.scene,this._visible=!1,this._pos=Y.vec3(),this._origin=Y.vec3(),this._rtcPos=Y.vec3(),this._baseDir=Y.vec3(),this._rootNode=null,this._displayMeshes=null,this._affordanceMeshes=null,this._ignoreNextSectionPlaneDirUpdate=!1,this._createNodes(),this._bindEvents()},[{key:"_setSectionPlane",value:function(e){var t=this;this._sectionPlane&&(this._sectionPlane.off(this._onSectionPlanePos),this._sectionPlane.off(this._onSectionPlaneDir),this._onSectionPlanePos=null,this._onSectionPlaneDir=null,this._sectionPlane=null),e&&(this.id=e.id,this._setPos(e.pos),this._setDir(e.dir),this._sectionPlane=e,this._onSectionPlanePos=e.on("pos",function(){t._setPos(t._sectionPlane.pos)}),this._onSectionPlaneDir=e.on("dir",function(){t._ignoreNextSectionPlaneDirUpdate?t._ignoreNextSectionPlaneDirUpdate=!1:t._setDir(t._sectionPlane.dir)}))}},{key:"sectionPlane",get:function(){return this._sectionPlane}},{key:"pos",get:function(){return this.posRate},set:function(e){if(!(e<0||e>100)){var t=this._scene.aabb,i=this._scene.camera.look,r=t[3]-t[0],n=t[4]-t[1],s=t[5]-t[2],o=Y.vec3();o[0]=this.pos[0],o[1]=this.pos[1],o[2]=this.pos[2];var a,l=this._sectionPlane.dir;0!=l[0]?(a=e/100*r,o[0]=i[0]-r/2+a):0!=l[1]?(a=e/100*n,o[1]=i[1]-n/2+a):0!=l[2]&&(a=e/100*s,o[2]=i[2]-s/2+a),this._sectionPlane.pos=o}}},{key:"posRate",get:function(){var e=this._scene.aabb,t=this._scene.center,i=e[3]-e[0],r=e[4]-e[1],n=e[5]-e[2],s=this._sectionPlane.pos,o=this._sectionPlane.dir,a=0;if(0!=o[0])a=(s[0]-(t[0]-i/2))/i*100;else if(0!=o[1]){a=(s[1]-(t[1]-r/2))/r*100}else if(0!=o[2]){a=(s[2]-(t[2]-n/2))/n*100}return a=Math.max(0,Math.min(100,a)),parseInt(a)}},{key:"_setPos",value:function(e){this._pos.set(e),be(this._pos,this._origin,this._rtcPos),this._rootNode.origin=this._origin,this._rootNode.position=this._rtcPos}},{key:"_setDir",value:function(e){this._baseDir.set(e),this._rootNode.quaternion=Y.vec3PairToQuaternion(ik,e,rk)}},{key:"_setSectionPlaneDir",value:function(e){this._sectionPlane&&(this._ignoreNextSectionPlaneDirUpdate=!0,this._sectionPlane.dir=e)}},{key:"setVisible",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];if(this._visible!==e){var t;for(t in this._visible=e,this._displayMeshes)this._displayMeshes.hasOwnProperty(t)&&(this._displayMeshes[t].visible=e);if(!e)for(t in this._affordanceMeshes)this._affordanceMeshes.hasOwnProperty(t)&&(this._affordanceMeshes[t].visible=e)}}},{key:"getVisible",value:function(){return this._visible}},{key:"setCulled",value:function(e){var t;for(t in this._displayMeshes)this._displayMeshes.hasOwnProperty(t)&&(this._displayMeshes[t].culled=e);if(!e)for(t in this._affordanceMeshes)this._affordanceMeshes.hasOwnProperty(t)&&(this._affordanceMeshes[t].culled=e)}},{key:"_createNodes",value:function(){var e=!1,t=this._viewer.scene,i=.01;this._rootNode=new yn(t,{id:this.id,position:[0,0,0],scale:[5,5,5],isObject:!1});var r,n,s=this._rootNode,o={arrowHead:new Ci(s,ln({radiusTop:.001,radiusBottom:.07,radialSegments:32,heightSegments:1,height:.2,openEnded:!1})),arrowHeadBig:new Ci(s,ln({radiusTop:.001,radiusBottom:.09,radialSegments:32,heightSegments:1,height:.25,openEnded:!1})),arrowHeadHandle:new Ci(s,ln({radiusTop:.09,radiusBottom:.09,radialSegments:8,heightSegments:1,height:.37,openEnded:!1})),curve:new Ci(s,On({radius:.8,tube:i,radialSegments:64,tubeSegments:14,arc:2*Math.PI/4})),curveHandle:new Ci(s,On({radius:.8,tube:.06,radialSegments:64,tubeSegments:14,arc:2*Math.PI/4})),hoop:new Ci(s,On({radius:.8,tube:i,radialSegments:64,tubeSegments:8,arc:2*Math.PI})),axis:new Ci(s,ln({radiusTop:i,radiusBottom:i,radialSegments:20,heightSegments:1,height:1,openEnded:!1})),axisHandle:new Ci(s,ln({radiusTop:.08,radiusBottom:.08,radialSegments:20,heightSegments:1,height:1,openEnded:!1}))},a={pickable:new Ti(s,{diffuse:[1,1,0],alpha:0,alphaMode:"blend"}),red:new Ti(s,{diffuse:[1,0,0],emissive:[1,0,0],ambient:[0,0,0],specular:[.6,.6,.3],shininess:80,lineWidth:2}),highlightRed:new Fi(s,{edges:!1,fill:!0,fillColor:[1,0,0],fillAlpha:.6}),green:new Ti(s,{diffuse:[0,1,0],emissive:[0,1,0],ambient:[0,0,0],specular:[.6,.6,.3],shininess:80,lineWidth:2}),highlightGreen:new Fi(s,{edges:!1,fill:!0,fillColor:[0,1,0],fillAlpha:.6}),blue:new Ti(s,{diffuse:[0,0,1],emissive:[0,0,1],ambient:[0,0,0],specular:[.6,.6,.3],shininess:80,lineWidth:2}),highlightBlue:new Fi(s,{edges:!1,fill:!0,fillColor:[0,0,1],fillAlpha:.2}),center:new Ti(s,{diffuse:[0,0,0],emissive:[0,0,0],ambient:[0,0,0],specular:[.6,.6,.3],shininess:80}),highlightBall:new Fi(s,{edges:!1,fill:!0,fillColor:[.5,.5,.5],fillAlpha:.5,vertices:!1}),highlightPlane:new Fi(s,{edges:!0,edgeWidth:3,fill:!1,fillColor:[.5,.5,.5],fillAlpha:.5,vertices:!1})};this._displayMeshes={plane:s.addChild(new on(s,{geometry:new Ci(s,{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 Ti(s,{emissive:[0,0,0],diffuse:[0,0,0],backfaces:!0}),opacity:.6,ghosted:!0,ghostMaterial:new Fi(s,{edges:!1,filled:!0,fillColor:[1,1,0],edgeColor:[0,0,0],fillAlpha:.1,backfaces:!0}),pickable:!1,collidable:!1,clippable:!1,visible:!1,scale:[2.4,2.4,1],isObject:!1}),e),planeFrame:s.addChild(new on(s,{geometry:new Ci(s,On({center:[0,0,0],radius:1.7,tube:.02,radialSegments:4,tubeSegments:4,arc:2*Math.PI})),material:new Ti(s,{emissive:[0,0,0],diffuse:[0,0,0],specular:[0,0,0],shininess:0}),highlightMaterial:new Fi(s,{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}),e),xCurve:s.addChild(new on(s,{geometry:o.curve,material:a.red,matrix:(r=Y.rotationMat4v(90*Y.DEGTORAD,[0,1,0],Y.identityMat4()),n=Y.rotationMat4v(270*Y.DEGTORAD,[1,0,0],Y.identityMat4()),Y.mulMat4(n,r,Y.identityMat4())),pickable:!1,collidable:!1,clippable:!1,backfaces:!0,visible:!1,isObject:!1}),e),xCurveHandle:s.addChild(new on(s,{geometry:o.curveHandle,material:a.pickable,matrix:function(){var e=Y.rotationMat4v(90*Y.DEGTORAD,[0,1,0],Y.identityMat4()),t=Y.rotationMat4v(270*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,backfaces:!0,visible:!1,isObject:!1}),e),xCurveArrow1:s.addChild(new on(s,{geometry:o.arrowHead,material:a.red,matrix:function(){var e=Y.translateMat4c(0,-.07,-.8,Y.identityMat4()),t=Y.scaleMat4v([.6,.6,.6],Y.identityMat4()),i=Y.rotationMat4v(0*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(Y.mulMat4(e,t,Y.identityMat4()),i,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),xCurveArrow2:s.addChild(new on(s,{geometry:o.arrowHead,material:a.red,matrix:function(){var e=Y.translateMat4c(0,-.8,-.07,Y.identityMat4()),t=Y.scaleMat4v([.6,.6,.6],Y.identityMat4()),i=Y.rotationMat4v(90*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(Y.mulMat4(e,t,Y.identityMat4()),i,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yCurve:s.addChild(new on(s,{geometry:o.curve,material:a.green,rotation:[-90,0,0],pickable:!1,collidable:!1,clippable:!1,backfaces:!0,visible:!1,isObject:!1}),e),yCurveHandle:s.addChild(new on(s,{geometry:o.curveHandle,material:a.pickable,rotation:[-90,0,0],pickable:!0,collidable:!1,clippable:!1,backfaces:!0,visible:!1,isObject:!1}),e),yCurveArrow1:s.addChild(new on(s,{geometry:o.arrowHead,material:a.green,matrix:function(){var e=Y.translateMat4c(.07,0,-.8,Y.identityMat4()),t=Y.scaleMat4v([.6,.6,.6],Y.identityMat4()),i=Y.rotationMat4v(90*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(Y.mulMat4(e,t,Y.identityMat4()),i,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yCurveArrow2:s.addChild(new on(s,{geometry:o.arrowHead,material:a.green,matrix:function(){var e=Y.translateMat4c(.8,0,-.07,Y.identityMat4()),t=Y.scaleMat4v([.6,.6,.6],Y.identityMat4()),i=Y.rotationMat4v(90*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(Y.mulMat4(e,t,Y.identityMat4()),i,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),center:s.addChild(new on(s,{geometry:new Ci(s,un({radius:.05})),material:a.center,pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),xAxisArrow:s.addChild(new on(s,{geometry:o.arrowHead,material:a.red,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),xAxisArrowHandle:s.addChild(new on(s,{geometry:o.arrowHeadHandle,material:a.pickable,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),xAxis:s.addChild(new on(s,{geometry:o.axis,material:a.red,matrix:function(){var e=Y.translateMat4c(0,.5,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),xAxisHandle:s.addChild(new on(s,{geometry:o.axisHandle,material:a.pickable,matrix:function(){var e=Y.translateMat4c(0,.5,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yAxisArrow:s.addChild(new on(s,{geometry:o.arrowHead,material:a.green,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(180*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yAxisArrowHandle:s.addChild(new on(s,{geometry:o.arrowHeadHandle,material:a.pickable,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(180*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,opacity:.2,isObject:!1}),e),yShaft:s.addChild(new on(s,{geometry:o.axis,material:a.green,position:[0,-.5,0],pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yShaftHandle:s.addChild(new on(s,{geometry:o.axisHandle,material:a.pickable,position:[0,-.5,0],pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),zAxisArrow:s.addChild(new on(s,{geometry:o.arrowHead,material:a.blue,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[.8,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),zAxisArrowHandle:s.addChild(new on(s,{geometry:o.arrowHeadHandle,material:a.pickable,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[.8,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),zShaft:s.addChild(new on(s,{geometry:o.axis,material:a.blue,matrix:function(){var e=Y.translateMat4c(0,.5,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),clippable:!1,pickable:!1,collidable:!1,visible:!1,isObject:!1}),e),zAxisHandle:s.addChild(new on(s,{geometry:o.axisHandle,material:a.pickable,matrix:function(){var e=Y.translateMat4c(0,.5,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),clippable:!1,pickable:!0,collidable:!1,visible:!1,isObject:!1}),e)},this._affordanceMeshes={planeFrame:s.addChild(new on(s,{geometry:new Ci(s,On({center:[0,0,0],radius:2,tube:i,radialSegments:4,tubeSegments:4,arc:2*Math.PI})),material:new Ti(s,{ambient:[1,1,1],diffuse:[0,0,0],emissive:[1,1,0]}),highlighted:!0,highlightMaterial:new Fi(s,{edges:!1,filled:!0,fillColor:[1,1,0],fillAlpha:1}),pickable:!1,collidable:!1,clippable:!1,visible:!1,scale:[1,1,1],rotation:[0,0,45],isObject:!1}),e),xHoop:s.addChild(new on(s,{geometry:o.hoop,material:a.red,highlighted:!0,highlightMaterial:a.highlightRed,matrix:function(){var e=Y.rotationMat4v(90*Y.DEGTORAD,[0,1,0],Y.identityMat4()),t=Y.rotationMat4v(270*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yHoop:s.addChild(new on(s,{geometry:o.hoop,material:a.green,highlighted:!0,highlightMaterial:a.highlightGreen,rotation:[-90,0,0],pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),zHoop:s.addChild(new on(s,{geometry:o.hoop,material:a.blue,highlighted:!0,highlightMaterial:a.highlightBlue,matrix:Y.rotationMat4v(180*Y.DEGTORAD,[1,0,0],Y.identityMat4()),pickable:!1,collidable:!1,clippable:!1,backfaces:!0,visible:!1,isObject:!1}),e),xAxisArrow:s.addChild(new on(s,{geometry:o.arrowHeadBig,material:a.red,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yAxisArrow:s.addChild(new on(s,{geometry:o.arrowHeadBig,material:a.green,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(180*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),zAxisArrow:s.addChild(new on(s,{geometry:o.arrowHeadBig,material:a.blue,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[.8,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e)}}},{key:"_bindEvents",value:function(){var e=this,t=this,i=!1,r=-1,n=0,s=1,o=2,a=3,l=4,u=5,c=this._rootNode,h=null,A=null,d=Y.vec2(),p=Y.vec3([1,0,0]),f=Y.vec3([0,1,0]),g=Y.vec3([0,0,1]),m=this._viewer.scene.canvas.canvas,v=this._viewer.camera,_=this._viewer.scene,y=Y.vec3([0,0,0]),b=-1;this._onCameraViewMatrix=_.camera.on("viewMatrix",function(){}),this._onCameraProjMatrix=_.camera.on("projMatrix",function(){}),this._onSceneTick=_.on("tick",function(){var t=Math.abs(Y.lenVec3(Y.subVec3(_.camera.eye,e._pos,y)));if(t!==b&&"perspective"===v.projection){var i=.07*(Math.tan(v.perspective.fov*Y.DEGTORAD)*t);c.scale=[i,i,i],b=t}if("ortho"===v.projection){var r=v.ortho.scale/10;c.scale=[r,r,r],b=t}});var w,x,B,P,C,M=function(){var e=new Float64Array(2);return function(t){if(t){for(var i=t.target,r=0,n=0;i.offsetParent;)r+=i.offsetLeft,n+=i.offsetTop,i=i.offsetParent;e[0]=t.pageX-r,e[1]=t.pageY-n}else t=window.event,e[0]=t.x,e[1]=t.y;return e}}(),k=function(){var e=new Float64Array(2);return function(t){if(t||(t=window.event),t.touches&&t.touches.length)e[0]=t.touches[0].pageX,e[1]=t.touches[0].pageY;else{for(var i=t.target,r=0,n=0;i.offsetParent;)r+=i.offsetLeft,n+=i.offsetTop,i=i.offsetParent;e[0]=t.pageX-r,e[1]=t.pageY-n}return e}}(),E=function(){var e=Y.mat4();return function(i,r){return Y.quaternionToMat4(t._rootNode.quaternion,e),Y.transformVec3(e,i,r),Y.normalizeVec3(r),r}}(),S=(w=Y.vec3(),function(e){var t=Math.abs(e[0]);return t>Math.abs(e[1])&&t>Math.abs(e[2])?Y.cross3Vec3(e,[0,1,0],w):Y.cross3Vec3(e,[1,0,0],w),Y.cross3Vec3(w,e,w),Y.normalizeVec3(w),w}),T=(x=Y.vec3(),B=Y.vec3(),P=Y.vec4(),function(e,i,r){E(e,P);var n=S(P,i,r);F(i,n,x),F(r,n,B),Y.subVec3(B,x);var s=Y.dotVec3(B,P);t._pos[0]+=P[0]*s*.6,t._pos[1]+=P[1]*s*.6,t._pos[2]+=P[2]*s*.6,t._rootNode.position=t._pos,t._sectionPlane&&(t._sectionPlane.pos=t._pos)}),I=function(){var e=Y.vec4(),i=Y.vec4(),r=Y.vec4(),n=Y.vec4();return function(s,o,a){if(E(s,n),!(F(o,n,e)&&F(a,n,i))){var l=S(n,o,a);F(o,l,e,1),F(a,l,i,1);var u=Y.dotVec3(e,n);e[0]-=u*n[0],e[1]-=u*n[1],e[2]-=u*n[2],u=Y.dotVec3(i,n),i[0]-=u*n[0],i[1]-=u*n[1],i[2]-=u*n[2]}Y.normalizeVec3(e),Y.normalizeVec3(i),u=Y.dotVec3(e,i),u=Y.clamp(u,-1,1);var c=Math.acos(u)*Y.RADTODEG;Y.cross3Vec3(e,i,r),Y.dotVec3(r,n)<0&&(c=-c),t._rootNode.rotate(s,c),D()}}(),F=function(){var e=Y.vec4([0,0,0,1]),i=Y.mat4();return function(r,n,s,o){o=o||0,e[0]=r[0]/m.width*2-1,e[1]=-(r[1]/m.height*2-1),e[2]=0,e[3]=1,Y.mulMat4(v.projMatrix,v.viewMatrix,i),Y.inverseMat4(i),Y.transformVec4(i,e,e),Y.mulVec4Scalar(e,1/e[3]);var a=v.eye;Y.subVec4(e,a,e);var l=t._sectionPlane.pos,u=-Y.dotVec3(l,n)-o,c=Y.dotVec3(n,e);if(Math.abs(c)>.005){var h=-(Y.dotVec3(n,a)+u)/c;return Y.mulVec3Scalar(e,h,s),Y.addVec3(s,a),Y.subVec3(s,l,s),!0}return!1}}(),D=function(){var e=Y.vec3(),i=Y.mat4();return function(){t.sectionPlane&&(Y.quaternionToMat4(c.quaternion,i),Y.transformVec3(i,[0,0,1],e),t._setSectionPlaneDir(e))}}(),R=!1;this._onCameraControlHover=this._viewer.cameraControl.on("hoverEnter",function(t){if(e._visible&&!R){var u;switch(i=!1,C&&(C.visible=!1),t.entity.id){case e._displayMeshes.xAxisArrowHandle.id:case e._displayMeshes.xAxisHandle.id:u=e._affordanceMeshes.xAxisArrow,h=n;break;case e._displayMeshes.yAxisArrowHandle.id:case e._displayMeshes.yShaftHandle.id:u=e._affordanceMeshes.yAxisArrow,h=s;break;case e._displayMeshes.zAxisArrowHandle.id:case e._displayMeshes.zAxisHandle.id:u=e._affordanceMeshes.zAxisArrow,h=o;break;case e._displayMeshes.xCurveHandle.id:u=e._affordanceMeshes.xHoop,h=a;break;case e._displayMeshes.yCurveHandle.id:u=e._affordanceMeshes.yHoop,h=l;break;default:return void(h=r)}u&&(u.visible=!0),C=u,i=!0}}),this._onCameraControlHoverLeave=this._viewer.cameraControl.on("hoverOut",function(t){e._visible&&(C&&(C.visible=!1),C=null,h=r,i=!1)}),m.addEventListener("mousedown",this._canvasMouseDownListener=function(t){if(t.preventDefault(),e._visible&&i&&(e._viewer.cameraControl.pointerEnabled=!1,1===t.which)){R=!0;var r=M(t);A=h,d[0]=r[0],d[1]=r[1],e.plugin.fire("clickPlaneStart")}}),m.addEventListener("mousemove",this._canvasMouseMoveListener=function(t){if(e._visible&&R){var i=M(t),r=i[0],c=i[1];switch(A){case n:T(p,d,i);break;case s:T(f,d,i);break;case o:T(g,d,i);break;case a:I(p,d,i);break;case l:I(f,d,i);break;case u:I(g,d,i)}d[0]=r,d[1]=c}}),m.addEventListener("mouseup",this._canvasMouseUpListener=function(t){e._visible&&(e._viewer.cameraControl.pointerEnabled=!0,R&&(t.which,R=!1,i=!1,e.plugin.fire("clickPlaneEnd")))}),m.addEventListener("wheel",this._canvasWheelListener=function(t){if(e._visible)Math.max(-1,Math.min(1,40*-t.deltaY))}),this._onCameraControlHover=this._viewer.cameraControl.on("touchEntity",function(t){if(e._visible&&!R&&!i){var u;switch(i=!1,C&&(C.visible=!1),t.entity.id){case e._displayMeshes.xAxisArrowHandle.id:case e._displayMeshes.xAxisHandle.id:u=e._affordanceMeshes.xAxisArrow,h=n;break;case e._displayMeshes.yAxisArrowHandle.id:case e._displayMeshes.yShaftHandle.id:u=e._affordanceMeshes.yAxisArrow,h=s;break;case e._displayMeshes.zAxisArrowHandle.id:case e._displayMeshes.zAxisHandle.id:u=e._affordanceMeshes.zAxisArrow,h=o;break;case e._displayMeshes.xCurveHandle.id:u=e._affordanceMeshes.xHoop,h=a;break;case e._displayMeshes.yCurveHandle.id:u=e._affordanceMeshes.yHoop,h=l;break;default:return void(h=r)}u&&(u.visible=!0),C=u,i=!0}}),m.addEventListener("touchstart",this._canvasMouseDownListener=function(t){if(t.preventDefault(),e._visible&&i){e._viewer.cameraControl.pointerEnabled=!1,R=!0;var r=k(t);A=h,d[0]=r[0],d[1]=r[1],e.plugin.fire("touchPlaneStart")}}),m.addEventListener("touchmove",this._canvasMouseMoveListener=function(t){if(e._visible&&R){var i=k(t),r=i[0],c=i[1];switch(A){case n:T(p,d,i);break;case s:T(f,d,i);break;case o:T(g,d,i);break;case a:I(p,d,i);break;case l:I(f,d,i);break;case u:I(g,d,i)}d[0]=r,d[1]=c}}),m.addEventListener("touchend",this._canvasTouchEndListener=function(t){e._visible&&(e._viewer.cameraControl.pointerEnabled=!0,C&&(C.visible=!1),C=null,h=r,R=!1,i=!1,e.plugin.fire("touchPlaneEnd"))}),m.addEventListener("touchcancel",this._canvasTouchEndListener)}},{key:"_destroy",value:function(){this._unbindEvents(),this._destroyNodes()}},{key:"_unbindEvents",value:function(){var e=this._viewer,t=e.scene,i=t.canvas.canvas,r=e.camera,n=e.cameraControl;t.off(this._onSceneTick),i.removeEventListener("mousedown",this._canvasMouseDownListener),i.removeEventListener("mousemove",this._canvasMouseMoveListener),i.removeEventListener("mouseup",this._canvasMouseUpListener),i.removeEventListener("wheel",this._canvasWheelListener),i.removeEventListener("touchend",this._canvasTouchEndListener),i.removeEventListener("touchcancel",this._canvasTouchEndListener),r.off(this._onCameraViewMatrix),r.off(this._onCameraProjMatrix),n.off(this._onCameraControlHover),n.off(this._onCameraControlHoverLeave)}},{key:"_destroyNodes",value:function(){this._setSectionPlane(null),this._rootNode.destroy(),this._displayMeshes={},this._affordanceMeshes={}}}])}(),sk=new Float64Array([0,0,1]),ok=new Float64Array(4),ak=function(){return P(function e(t,i){x(this,e),this.id=i.id,this.type="control",this.plugin=t,this._viewer=t.viewer,this._scene=t.viewer.scene,i||(i={}),this._xColor=i.xColor?i.xColor:[.5,.5,.5],this._yColor=i.yColor?i.yColor:[.5,.5,.5],this._zColor=i.zColor?i.zColor:[.5,.5,.5],this._controlFillColor=i.controlFillColor?i.controlFillColor:[.1,.4,.99],this._planeSize=i.planeSize?i.planeSize:1,this._controlSize=i.controlSize?i.controlSize:.07,this._planeOpacity=i.planeOpacity?i.planeOpacity:.4,this._visible=!1,this._pos=Y.vec3(),this._origin=Y.vec3(),this._rtcPos=Y.vec3(),this._baseDir=Y.vec3(),this._rootNode=null,this._displayMeshes=null,this._affordanceMeshes=null,this._ignoreNextSectionPlaneDirUpdate=!1},[{key:"_createNodes",value:function(){var e=!1,t=this._viewer.scene,i=t.aabb,r=.01,n=i[3]-i[0],s=i[4]-i[1],o=i[5]-i[2];this._rootNode=new yn(t,{id:"sectionControl",position:[0,0,0],scale:[5,5,5],isObject:!1});var a,l,u=this._rootNode,c={arrowHead:new Ci(u,ln({radiusTop:.001,radiusBottom:.04,radialSegments:32,heightSegments:1,height:.15,openEnded:!1})),arrowHeadBig:new Ci(u,ln({radiusTop:.001,radiusBottom:.05,radialSegments:32,heightSegments:1,height:.18,openEnded:!1})),arrowHeadHandle:new Ci(u,ln({radiusTop:.09,radiusBottom:.09,radialSegments:8,heightSegments:1,height:.37,openEnded:!1})),curve:new Ci(u,On({radius:.5,tube:r,radialSegments:32,tubeSegments:7,arc:2*Math.PI/4})),curveHandle:new Ci(u,On({radius:.5,tube:.04,radialSegments:32,tubeSegments:7,arc:2*Math.PI/4})),hoop:new Ci(u,On({radius:.8,tube:r,radialSegments:64,tubeSegments:8,arc:2*Math.PI})),axis:new Ci(u,ln({radiusTop:r,radiusBottom:r,radialSegments:20,heightSegments:1,height:1,openEnded:!1})),axisHandle:new Ci(u,ln({radiusTop:.08,radiusBottom:.08,radialSegments:20,heightSegments:1,height:1,openEnded:!1}))},h={pickable:new Ti(u,{diffuse:[1,1,0],alpha:0,alphaMode:"opaque"}),red:new Ti(u,{diffuse:this._xColor,emissive:this._xColor,ambient:[0,0,0],specular:[.6,.6,.3],shininess:80,lineWidth:1.5}),highlightRed:new Fi(u,{edges:!1,fill:!0,fillColor:[.8,.8,.8],fillAlpha:.6}),green:new Ti(u,{diffuse:this._yColor,emissive:this._yColor,ambient:[0,0,0],specular:[.6,.6,.3],shininess:80,lineWidth:1.5}),highlightGreen:new Fi(u,{edges:!1,fill:!0,fillColor:[.8,.8,.8],fillAlpha:.6}),blue:new Ti(u,{diffuse:this._zColor,emissive:this._zColor,ambient:[0,0,0],specular:[.6,.6,.3],shininess:80,lineWidth:1.5}),highlightBlue:new Fi(u,{edges:!1,fill:!0,fillColor:[.8,.8,.8],fillAlpha:.2}),center:new Ti(u,{diffuse:[0,0,0],emissive:[0,0,0],ambient:[0,0,0],specular:[.6,.6,.3],shininess:80}),highlightBall:new Fi(u,{edges:!1,fill:!0,fillColor:[.5,.5,.5],fillAlpha:.5,vertices:!1}),highlightPlane:new Fi(u,{edges:!0,edgeWidth:3,fill:!1,fillColor:[.5,.5,.5],fillAlpha:.5,vertices:!1})};this._displayMeshes={plane:u.addChild(new on(u,{geometry:new Ci(u,{primitive:"triangles",positions:[10,5,0,10,-5,0,-10,-5,0,-10,5,0],indices:[0,1,2,2,3,0]}),material:new Ti(u,{emissive:[0,0,0],diffuse:this._controlFillColor,backfaces:!0}),opacity:this._planeOpacity,ghosted:!1,ghostMaterial:new Fi(u,{edges:!1,filled:!0,fillColor:this._controlFillColor?this._controlFillColor:[.1,.4,.99],edgeColor:[0,0,0],fillAlpha:.1,backfaces:!0}),pickable:!0,collidable:!1,clippable:!1,visible:!1,scale:[this._planeSize,this._planeSize,this._planeSize],isObject:!1}),e),planeFrame:u.addChild(new on(u,{geometry:new Ci(u,Dn({center:[0,0,0],xSize:.1*n,ySize:.1*s,zSize:.1*o})),material:new Ti(u,{emissive:[.5,.5,.5],diffuse:[.5,.5,.5],specular:[.5,.5,.5],alpha:.2,shininess:10}),highlightMaterial:new Fi(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],isObject:!1}),e),xCurve:u.addChild(new on(u,{geometry:c.curve,material:h.red,matrix:(a=Y.rotationMat4v(90*Y.DEGTORAD,[0,1,0],Y.identityMat4()),l=Y.rotationMat4v(270*Y.DEGTORAD,[1,0,0],Y.identityMat4()),Y.mulMat4(l,a,Y.identityMat4())),pickable:!1,collidable:!1,clippable:!1,backfaces:!0,visible:!1,isObject:!1}),e),xCurveHandle:u.addChild(new on(u,{geometry:c.curveHandle,material:h.pickable,matrix:function(){var e=Y.rotationMat4v(90*Y.DEGTORAD,[0,1,0],Y.identityMat4()),t=Y.rotationMat4v(270*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,backfaces:!0,visible:!1,isObject:!1}),e),yCurve:u.addChild(new on(u,{geometry:c.curve,material:h.green,rotation:[-90,0,0],pickable:!1,collidable:!1,clippable:!1,backfaces:!0,visible:!1,isObject:!1}),e),yCurveHandle:u.addChild(new on(u,{geometry:c.curveHandle,material:h.pickable,rotation:[-90,0,0],pickable:!0,collidable:!1,clippable:!1,backfaces:!0,visible:!1,isObject:!1}),e),center:u.addChild(new on(u,{geometry:new Ci(u,un({radius:.05})),material:h.center,pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),xAxisArrow:u.addChild(new on(u,{geometry:c.arrowHead,material:h.red,matrix:function(){var e=Y.translateMat4c(0,1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),xAxisArrowHandle:u.addChild(new on(u,{geometry:c.arrowHeadHandle,material:h.pickable,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),xAxis:u.addChild(new on(u,{geometry:c.axis,material:h.red,matrix:function(){var e=Y.translateMat4c(0,.5,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),xAxisHandle:u.addChild(new on(u,{geometry:c.axisHandle,material:h.pickable,matrix:function(){var e=Y.translateMat4c(0,.5,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yAxisArrow:u.addChild(new on(u,{geometry:c.arrowHead,material:h.green,matrix:function(){var e=Y.translateMat4c(0,1,0,Y.identityMat4()),t=Y.rotationMat4v(180*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yAxisArrowHandle:u.addChild(new on(u,{geometry:c.arrowHeadHandle,material:h.pickable,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(180*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,opacity:.2,isObject:!1}),e),yShaft:u.addChild(new on(u,{geometry:c.axis,material:h.green,position:[0,-.5,0],pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yShaftHandle:u.addChild(new on(u,{geometry:c.axisHandle,material:h.pickable,position:[0,-.5,0],pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),zAxisArrow:u.addChild(new on(u,{geometry:c.arrowHead,material:h.blue,matrix:function(){var e=Y.translateMat4c(0,1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[2,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),zAxisArrowHandle:u.addChild(new on(u,{geometry:c.arrowHeadHandle,material:h.pickable,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[.8,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!0,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),zShaft:u.addChild(new on(u,{geometry:c.axis,material:h.blue,matrix:function(){var e=Y.translateMat4c(0,.5,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),clippable:!1,pickable:!1,collidable:!1,visible:!1,isObject:!1}),e),zAxisHandle:u.addChild(new on(u,{geometry:c.axisHandle,material:h.pickable,matrix:function(){var e=Y.translateMat4c(0,.5,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),clippable:!1,pickable:!0,collidable:!1,visible:!1,isObject:!1}),e)},this._affordanceMeshes={xHoop:u.addChild(new on(u,{geometry:c.hoop,material:h.red,highlighted:!0,highlightMaterial:h.highlightRed,matrix:function(){var e=Y.rotationMat4v(90*Y.DEGTORAD,[0,1,0],Y.identityMat4()),t=Y.rotationMat4v(270*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yHoop:u.addChild(new on(u,{geometry:c.hoop,material:h.green,highlighted:!0,highlightMaterial:h.highlightGreen,rotation:[-90,0,0],pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),zHoop:u.addChild(new on(u,{geometry:c.hoop,material:h.blue,highlighted:!0,highlightMaterial:h.highlightBlue,matrix:Y.rotationMat4v(180*Y.DEGTORAD,[1,0,0],Y.identityMat4()),pickable:!1,collidable:!1,clippable:!1,backfaces:!0,visible:!1,isObject:!1}),e),xAxisArrow:u.addChild(new on(u,{geometry:c.arrowHeadBig,material:h.red,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[0,0,1],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),yAxisArrow:u.addChild(new on(u,{geometry:c.arrowHeadBig,material:h.green,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(180*Y.DEGTORAD,[1,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e),zAxisArrow:u.addChild(new on(u,{geometry:c.arrowHeadBig,material:h.blue,matrix:function(){var e=Y.translateMat4c(0,1.1,0,Y.identityMat4()),t=Y.rotationMat4v(-90*Y.DEGTORAD,[.8,0,0],Y.identityMat4());return Y.mulMat4(t,e,Y.identityMat4())}(),pickable:!1,collidable:!1,clippable:!1,visible:!1,isObject:!1}),e)}}},{key:"_setSectionPlane",value:function(e){var t=this;this._sectionPlane&&(this._sectionPlane.off(this._onSectionPlanePos),this._sectionPlane.off(this._onSectionPlaneDir),this._onSectionPlanePos=null,this._onSectionPlaneDir=null,this._sectionPlane=null),e&&(this.id=e.controlId,this._createNodes(),this._bindEvents(),this._setPos(e.pos),this._setDir(e.dir),this._sectionPlane=e,this._onSectionPlanePos=e.on("pos",function(){t._setPos(t._sectionPlane.pos)}),this._onSectionPlaneDir=e.on("dir",function(){t._ignoreNextSectionPlaneDirUpdate?t._ignoreNextSectionPlaneDirUpdate=!1:t._setDir(t._sectionPlane.dir)}))}},{key:"sectionPlane",get:function(){return this._sectionPlane}},{key:"pos",get:function(){return this.posRate},set:function(e){if(!(e<0||e>100)){var t=this._scene.aabb,i=this._scene.camera.look,r=t[3]-t[0],n=t[4]-t[1],s=t[5]-t[2],o=Y.vec3();o[0]=this.pos[0],o[1]=this.pos[1],o[2]=this.pos[2];var a,l=this._sectionPlane.dir;0!=l[0]?(a=e/100*r,o[0]=i[0]-r/2+a):0!=l[1]?(a=e/100*n,o[1]=i[1]-n/2+a):0!=l[2]&&(a=e/100*s,o[2]=i[2]-s/2+a),this._sectionPlane.pos=o}}},{key:"posRate",get:function(){var e=this._scene.aabb,t=this._scene.center,i=e[3]-e[0],r=e[4]-e[1],n=e[5]-e[2],s=this._sectionPlane.pos,o=this._sectionPlane.dir,a=0;if(0!=o[0])a=(s[0]-(t[0]-i/2))/i*100;else if(0!=o[1]){a=(s[1]-(t[1]-r/2))/r*100}else if(0!=o[2]){a=(s[2]-(t[2]-n/2))/n*100}return a=Math.max(0,Math.min(100,a)),parseInt(a)}},{key:"_setPos",value:function(e){this._pos.set(e),be(this._pos,this._origin,this._rtcPos),this._rootNode.origin=this._origin,this._rootNode.position=this._rtcPos}},{key:"_setDir",value:function(e){this._baseDir.set(e),this._rootNode.quaternion=Y.vec3PairToQuaternion(sk,e,ok)}},{key:"_setSectionPlaneDir",value:function(e){this._sectionPlane&&(this._ignoreNextSectionPlaneDirUpdate=!0,this._sectionPlane.dir=e)}},{key:"setVisible",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];if(this._visible!==e){var t;for(t in this._visible=e,this._displayMeshes)this._displayMeshes.hasOwnProperty(t)&&(this._displayMeshes[t].visible=e);if(!e)for(t in this._affordanceMeshes)this._affordanceMeshes.hasOwnProperty(t)&&(this._affordanceMeshes[t].visible=e)}}},{key:"getVisible",value:function(){return this._visible}},{key:"setCulled",value:function(e){var t;for(t in this._displayMeshes)this._displayMeshes.hasOwnProperty(t)&&(this._displayMeshes[t].culled=e);if(!e)for(t in this._affordanceMeshes)this._affordanceMeshes.hasOwnProperty(t)&&(this._affordanceMeshes[t].culled=e)}},{key:"_bindEvents",value:function(){var e=this,t=this,i=!1,r=-1,n=0,s=1,o=2,a=3,l=4,u=5,c=this._rootNode,h=null,A=null,d=Y.vec2(),p=Y.vec3([1,0,0]),f=Y.vec3([0,1,0]),g=Y.vec3([0,0,1]),m=this._viewer.scene.canvas.canvas,v=this._viewer.camera,_=this._viewer.scene,y=Y.vec3([0,0,0]),b=-1;this._onCameraViewMatrix=_.camera.on("viewMatrix",function(){}),this._onCameraProjMatrix=_.camera.on("projMatrix",function(){}),this._onSceneTick=_.on("tick",function(){var t=Math.abs(Y.lenVec3(Y.subVec3(_.camera.eye,e._pos,y)));t!==b&&"perspective"===v.projection&&(Math.tan(v.perspective.fov*Y.DEGTORAD),b=t),"ortho"===v.projection&&(v.ortho.scale,b=t)});var w,x,B,P,C,M=function(){var e=new Float64Array(2);return function(t){if(t){for(var i=t.target,r=0,n=0;i.offsetParent;)r+=i.offsetLeft,n+=i.offsetTop,i=i.offsetParent;e[0]=t.pageX-r,e[1]=t.pageY-n}else t=window.event,e[0]=t.x,e[1]=t.y;return e}}(),k=function(){var e=new Float64Array(2);return function(t){if(t||(t=window.event),t.touches&&t.touches.length)e[0]=t.touches[0].pageX,e[1]=t.touches[0].pageY;else{for(var i=t.target,r=0,n=0;i.offsetParent;)r+=i.offsetLeft,n+=i.offsetTop,i=i.offsetParent;e[0]=t.pageX-r,e[1]=t.pageY-n}return e}}(),E=function(){var e=Y.mat4();return function(i,r){return Y.quaternionToMat4(t._rootNode.quaternion,e),Y.transformVec3(e,i,r),Y.normalizeVec3(r),r}}(),S=(w=Y.vec3(),function(e){var t=Math.abs(e[0]);return t>Math.abs(e[1])&&t>Math.abs(e[2])?Y.cross3Vec3(e,[0,1,0],w):Y.cross3Vec3(e,[1,0,0],w),Y.cross3Vec3(w,e,w),Y.normalizeVec3(w),w}),T=(x=Y.vec3(),B=Y.vec3(),P=Y.vec4(),function(e,i,r){E(e,P);var n=S(P,i,r);F(i,n,x),F(r,n,B),Y.subVec3(B,x);var s=Y.dotVec3(B,P);t._pos[0]+=P[0]*s*.6,t._pos[1]+=P[1]*s*.6,t._pos[2]+=P[2]*s*.6,t._rootNode.position=t._pos,t._sectionPlane&&(t._sectionPlane.pos=t._pos)}),I=function(){var e=Y.vec4(),i=Y.vec4(),r=Y.vec4(),n=Y.vec4();return function(s,o,a){if(E(s,n),!(F(o,n,e)&&F(a,n,i))){var l=S(n,o,a);F(o,l,e,1),F(a,l,i,1);var u=Y.dotVec3(e,n);e[0]-=u*n[0],e[1]-=u*n[1],e[2]-=u*n[2],u=Y.dotVec3(i,n),i[0]-=u*n[0],i[1]-=u*n[1],i[2]-=u*n[2]}Y.normalizeVec3(e),Y.normalizeVec3(i),u=Y.dotVec3(e,i),u=Y.clamp(u,-1,1);var c=Math.acos(u)*Y.RADTODEG;Y.cross3Vec3(e,i,r),Y.dotVec3(r,n)<0&&(c=-c),t._rootNode.rotate(s,c),D()}}(),F=function(){var e=Y.vec4([0,0,0,1]),i=Y.mat4();return function(r,n,s,o){o=o||0,e[0]=r[0]/m.width*2-1,e[1]=-(r[1]/m.height*2-1),e[2]=0,e[3]=1,Y.mulMat4(v.projMatrix,v.viewMatrix,i),Y.inverseMat4(i),Y.transformVec4(i,e,e),Y.mulVec4Scalar(e,1/e[3]);var a=v.eye;Y.subVec4(e,a,e);var l=t._sectionPlane.pos,u=-Y.dotVec3(l,n)-o,c=Y.dotVec3(n,e);if(Math.abs(c)>.005){var h=-(Y.dotVec3(n,a)+u)/c;return Y.mulVec3Scalar(e,h,s),Y.addVec3(s,a),Y.subVec3(s,l,s),!0}return!1}}(),D=function(){var e=Y.vec3(),i=Y.mat4();return function(){t.sectionPlane&&(Y.quaternionToMat4(c.quaternion,i),Y.transformVec3(i,[0,0,1],e),t._setSectionPlaneDir(e))}}(),R=!1;this._onCameraControlHover=this._viewer.cameraControl.on("hoverEnter",function(t){if(e._visible&&!R){var u;switch(i=!1,C&&(C.visible=!1),t.entity.id){case e._displayMeshes.xAxisArrowHandle.id:case e._displayMeshes.xAxisHandle.id:u=e._affordanceMeshes.xAxisArrow,h=n;break;case e._displayMeshes.yAxisArrowHandle.id:case e._displayMeshes.yShaftHandle.id:u=e._affordanceMeshes.yAxisArrow,h=s;break;case e._displayMeshes.zAxisArrowHandle.id:case e._displayMeshes.zAxisHandle.id:u=e._affordanceMeshes.zAxisArrow,h=o;break;case e._displayMeshes.xCurveHandle.id:u=e._affordanceMeshes.xHoop,h=a;break;case e._displayMeshes.yCurveHandle.id:u=e._affordanceMeshes.yHoop,h=l;break;default:return void(h=r)}u&&(u.visible=!0),C=u,i=!0}}),this._onCameraControlHoverLeave=this._viewer.cameraControl.on("hoverOut",function(t){e._visible&&(C&&(C.visible=!1),C=null,h=r,i=!1)}),m.addEventListener("mousedown",this._canvasMouseDownListener=function(t){if(t.preventDefault(),e._visible&&i&&(e._viewer.cameraControl.pointerEnabled=!1,1===t.which)){R=!0;var r=M(t);A=h,d[0]=r[0],d[1]=r[1],e.plugin.fire("clickPlaneStart")}}),m.addEventListener("mousemove",this._canvasMouseMoveListener=function(t){if(e._visible&&R&&i){var r=M(t),c=r[0],h=r[1];switch(A){case n:T(p,d,r);break;case s:T(f,d,r);break;case o:T(g,d,r);break;case a:I(p,d,r);break;case l:I(f,d,r);break;case u:I(g,d,r)}d[0]=c,d[1]=h}}),m.addEventListener("mouseup",this._canvasMouseUpListener=function(t){e._visible&&(e._viewer.cameraControl.pointerEnabled=!0,R&&(R=!1,i=!1,e.plugin.fire("clickPlaneEnd")))}),m.addEventListener("wheel",this._canvasWheelListener=function(t){if(e._visible)Math.max(-1,Math.min(1,40*-t.deltaY))}),this._onCameraControlHover=this._viewer.cameraControl.on("touchEntity",function(t){if(e._visible&&!R&&!i){var u;switch(i=!1,C&&(C.visible=!1),t.entity.id){case e._displayMeshes.xAxisArrowHandle.id:case e._displayMeshes.xAxisHandle.id:u=e._affordanceMeshes.xAxisArrow,h=n;break;case e._displayMeshes.yAxisArrowHandle.id:case e._displayMeshes.yShaftHandle.id:u=e._affordanceMeshes.yAxisArrow,h=s;break;case e._displayMeshes.zAxisArrowHandle.id:case e._displayMeshes.zAxisHandle.id:u=e._affordanceMeshes.zAxisArrow,h=o;break;case e._displayMeshes.xCurveHandle.id:u=e._affordanceMeshes.xHoop,h=a;break;case e._displayMeshes.yCurveHandle.id:u=e._affordanceMeshes.yHoop,h=l;break;default:return void(h=r)}u&&(u.visible=!0),C=u,i=!0}}),m.addEventListener("touchstart",this._canvasMouseDownListener=function(t){if(t.preventDefault(),e._visible&&i){e._viewer.cameraControl.pointerEnabled=!1,R=!0;var r=k(t);A=h,d[0]=r[0],d[1]=r[1],e.plugin.fire("touchPlaneStart")}}),m.addEventListener("touchmove",this._canvasMouseMoveListener=function(t){if(e._visible&&R){var i=k(t),r=i[0],c=i[1];switch(A){case n:T(p,d,i);break;case s:T(f,d,i);break;case o:T(g,d,i);break;case a:I(p,d,i);break;case l:I(f,d,i);break;case u:I(g,d,i)}d[0]=r,d[1]=c}}),m.addEventListener("touchend",this._canvasTouchEndListener=function(t){e._visible&&(e._viewer.cameraControl.pointerEnabled=!0,C&&(C.visible=!1),C=null,h=r,R=!1,i=!1,e.plugin.fire("touchPlaneEnd"))}),m.addEventListener("touchcancel",this._canvasTouchEndListener)}},{key:"_destroy",value:function(){this._unbindEvents(),this._destroyNodes()}},{key:"_unbindEvents",value:function(){var e=this._viewer,t=e.scene,i=t.canvas.canvas,r=e.camera,n=e.cameraControl;t.off(this._onSceneTick),i.removeEventListener("mousedown",this._canvasMouseDownListener),i.removeEventListener("mousemove",this._canvasMouseMoveListener),i.removeEventListener("mouseup",this._canvasMouseUpListener),i.removeEventListener("wheel",this._canvasWheelListener),i.removeEventListener("touchend",this._canvasTouchEndListener),i.removeEventListener("touchcancel",this._canvasTouchEndListener),r.off(this._onCameraViewMatrix),r.off(this._onCameraProjMatrix),n.off(this._onCameraControlHover),n.off(this._onCameraControlHoverLeave)}},{key:"_destroyNodes",value:function(){this._setSectionPlane(null),this._rootNode.destroy(),this._displayMeshes={},this._affordanceMeshes={}}}])}(),lk=new Float64Array([0,0,1]),uk=new Float64Array(4),ck=function(){return P(function e(t,i){x(this,e),this.id=i.id,this.type="plane",this.plugin=t,this._viewer=t.viewer,this._scene=t.viewer.scene,i?(this._controlFillColor=i.controlFillColor?i.controlFillColor:[.3,.6,1],this._planeSize=i.planeSize?i.planeSize:1,this._controlSize=i.controlSize?i.controlSize:.07,this._planeOpacity=i.planeOpacity?i.planeOpacity:.4,this._enableClip=!!i.enableClip):(this._controlFillColor=[.3,.6,1],this._planeSize=1,this._controlSize=.07,this._planeOpacity=.4,this._enableClip=!1),this._visible=!1,this._pos=Y.vec3(),this._origin=Y.vec3(),this._rtcPos=Y.vec3(),this._baseDir=Y.vec3(),this._rootNode=null,this._displayMeshes=null,this._affordanceMeshes=null,this._ignoreNextSectionPlaneDirUpdate=!1},[{key:"_createNodes",value:function(){var e=!1,t=this._viewer.scene;this._rootNode=new yn(t,{id:this.id,position:[0,0,0],scale:[1,1,1],isObject:!1});var i,r,n=this._rootNode,s=t.aabb,o=s[3]-s[0],a=s[4]-s[1],l=s[5]-s[2];0!=this.dir[0]?(i=l>0?1*l:1*l*-1,r=a>0?1*a:1*a*-1):0!=this.dir[1]?(i=o>0?1*o:1*o*-1,r=l>0?1*l:1*l*-1):0!=this.dir[2]&&(i=o>0?1*o:1*o*-1,r=a>0?1*a:1*a*-1),i+=0,r+=0,this._displayMeshes={plane:n.addChild(new on(n,{geometry:new Ci(n,{primitive:"triangles",positions:[i/2,r/2,.01,i/2,-r/2,.01,-i/2,-r/2,.01,-i/2,r/2,.01],indices:[0,1,2,2,3,0]}),material:new Ti(n,{emissive:[.1,.1,.1],diffuse:this._controlFillColor,backfaces:!0}),opacity:this._planeOpacity,ghosted:!0,ghostMaterial:new Fi(n,{edges:!1,filled:!0,fillColor:this._controlFillColor,fillAlpha:.1,backfaces:!0}),pickable:this.pickable,collidable:!1,clippable:this._enableClip,visible:!1,scale:[1*this._planeSize,1*this._planeSize,1*this._planeSize],isObject:!1}),e)},this._affordanceMeshes={plane:n.addChild(new on(n,{geometry:new Ci(n,{primitive:"triangles",positions:[i/2,r/2,.012,i/2,-r/2,.012,-i/2,-r/2,.012,-i/2,r/2,.012],indices:[0,1,2,2,3,0]}),material:new Ti(n,{emissive:[.6,.6,5],diffuse:this._controlFillColor,backfaces:!0}),opacity:this._planeOpacity,ghosted:!0,ghostMaterial:new Fi(n,{edges:!1,filled:!0,fillColor:this._controlFillColor,fillAlpha:.1,backfaces:!0}),pickable:!0,collidable:!1,clippable:!0,visible:!1,scale:[1*this._planeSize,1*this._planeSize,1*this._planeSize],isObject:!1}),e)}}},{key:"_setSectionPlane",value:function(e){var t=this;this._sectionPlane&&(this._sectionPlane.off(this._onSectionPlanePos),this._sectionPlane.off(this._onSectionPlaneDir),this._onSectionPlanePos=null,this._onSectionPlaneDir=null,this._sectionPlane=null),e&&(this.id=e.controlId,this.dir=e.dir,this._createNodes(),this._bindEvents(),this._setPos(e.pos),this._setDir(e.dir),this._sectionPlane=e,e.control=this,this._onSectionPlanePos=e.on("pos",function(){t._setPos(t._sectionPlane.pos)}),this._onSectionPlaneDir=e.on("dir",function(){t._ignoreNextSectionPlaneDirUpdate?t._ignoreNextSectionPlaneDirUpdate=!1:t._setDir(t._sectionPlane.dir)}))}},{key:"sectionPlane",get:function(){return this._sectionPlane}},{key:"pos",get:function(){return this._pos},set:function(e){if(!(e<0||e>100)){var t=this._scene.aabb,i=this._scene.center,r=t[3]-t[0],n=t[4]-t[1],s=t[5]-t[2],o=Y.vec3();o[0]=this.pos[0],o[1]=this.pos[1],o[2]=this.pos[2];var a,l=this._sectionPlane.dir;0!=l[0]?(a=e/100*r,o[0]=i[0]-r/2+a):0!=l[1]?(a=e/100*n,o[1]=i[1]-n/2+a):0!=l[2]&&(a=e/100*s,o[2]=i[2]-s/2+a),this._sectionPlane.pos=o}}},{key:"posRate",get:function(){var e=this._scene.aabb,t=this._scene.center,i=e[3]-e[0],r=e[4]-e[1],n=e[5]-e[2],s=this._sectionPlane.pos,o=this._sectionPlane.dir,a=0;if(0!=o[0])a=(s[0]-(t[0]-i/2))/i*100;else if(0!=o[1]){a=(s[1]-(t[1]-r/2))/r*100}else if(0!=o[2]){a=(s[2]-(t[2]-n/2))/n*100}return a=Math.max(0,Math.min(100,a)),parseInt(a)}},{key:"_setPos",value:function(e){this._pos.set(e),be(this._pos,this._origin,this._rtcPos),this._rootNode.origin=this._origin,this._rootNode.position=this._rtcPos}},{key:"_setDir",value:function(e){this._baseDir.set(e),this._rootNode.quaternion=Y.vec3PairToQuaternion(lk,e,uk)}},{key:"_setSectionPlaneDir",value:function(e){this._sectionPlane&&(this._ignoreNextSectionPlaneDirUpdate=!0,this._sectionPlane.dir=e)}},{key:"setVisible",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];if(this._visible!==e){var t;for(t in this._visible=e,this._displayMeshes)this._displayMeshes.hasOwnProperty(t)&&(this._displayMeshes[t].visible=e);if(!e)for(t in this._affordanceMeshes)this._affordanceMeshes.hasOwnProperty(t)&&(this._affordanceMeshes[t].visible=e)}}},{key:"getVisible",value:function(){return this._visible}},{key:"setCulled",value:function(e){var t;for(t in this._displayMeshes)this._displayMeshes.hasOwnProperty(t)&&(this._displayMeshes[t].culled=e);if(!e)for(t in this._affordanceMeshes)this._affordanceMeshes.hasOwnProperty(t)&&(this._affordanceMeshes[t].culled=e)}},{key:"_bindEvents",value:function(){var e=this,t=this,i=!1,r=-1,n=0,s=1,o=2;this._rootNode;var a=null,l=null,u=Y.vec2();this.lastCanvasPos=u;var c=Y.vec3([1,0,0]),h=Y.vec3([0,1,0]),A=Y.vec3([0,0,1]),d=this._viewer.scene.canvas.canvas,p=this._viewer.camera,f=this._viewer.scene;this._onCameraViewMatrix=f.camera.on("viewMatrix",function(){}),this._onCameraProjMatrix=f.camera.on("projMatrix",function(){});var g,m,v,_,y,b=function(){var e=new Float64Array(2);return function(t){if(t){for(var i=t.target,r=0,n=0;i.offsetParent;)r+=i.offsetLeft,n+=i.offsetTop,i=i.offsetParent;e[0]=t.pageX-r,e[1]=t.pageY-n}else t=window.event,e[0]=t.x,e[1]=t.y;return e}}(),w=function(){var e=Y.mat4();return function(i,r){return Y.quaternionToMat4(t._rootNode.quaternion,e),Y.transformVec3(e,i,r),Y.normalizeVec3(r),r}}(),x=(g=Y.vec3(),function(e){var t=Math.abs(e[0]);return t>Math.abs(e[1])&&t>Math.abs(e[2])?Y.cross3Vec3(e,[0,1,0],g):Y.cross3Vec3(e,[1,0,0],g),Y.cross3Vec3(g,e,g),Y.normalizeVec3(g),g}),B=(m=Y.vec3(),v=Y.vec3(),_=Y.vec4(),function(e,i,r){w(e,_);var n=x(_,i,r);P(i,n,m),P(r,n,v),Y.subVec3(v,m);var s,o=Y.dotVec3(v,_),a=t._sectionPlane.dir,l=t._sectionPlane.planeId,u=t._sectionPlane.posRangeMin;if(s=t._sectionPlane.box.boxRanges[(l+3)%6],0!=a[0]){if(a[0]>0){if(s=t._sectionPlane.box.boxRanges[(l+3)%6],t._pos[0]+_[0]*o*.6<u[0]||t._pos[0]+_[0]*o*.6>s[0]-.3)return}else if(t._pos[0]+_[0]*o*.6>u[0]||t._pos[0]+_[0]*o*.6<s[0]+.3)return}else if(0!=a[1]){if(a[1]>0){if(t._pos[1]+_[1]*o*.6<u[1]||t._pos[1]+_[1]*o*.6>s[1]-.3)return}else if(t._pos[1]+_[1]*o*.6>u[1]||t._pos[1]+_[1]*o*.6<s[1]+.3)return}else if(0!=a[2])if(a[2]>0){if(t._pos[2]+_[2]*o*.6<u[2]||t._pos[2]+_[2]*o*.6>s[2]-.3)return}else if(t._pos[2]+_[2]*o*.6>u[2]||t._pos[2]+_[2]*o*.6<s[2]+.3)return;t._pos[0]+=_[0]*o*.6,t._pos[1]+=_[1]*o*.6,t._pos[2]+=_[2]*o*.6,t._rootNode.position=t._pos,t._sectionPlane&&(t._sectionPlane.pos=t._pos)}),P=function(){var e=Y.vec4([0,0,0,1]),i=Y.mat4();return function(r,n,s,o){o=o||0,e[0]=r[0]/d.width*2-1,e[1]=-(r[1]/d.height*2-1),e[2]=0,e[3]=1,Y.mulMat4(p.projMatrix,p.viewMatrix,i),Y.inverseMat4(i),Y.transformVec4(i,e,e),Y.mulVec4Scalar(e,1/e[3]);var a=p.eye;Y.subVec4(e,a,e);var l=t._sectionPlane.pos,u=-Y.dotVec3(l,n)-o,c=Y.dotVec3(n,e);if(Math.abs(c)>.005){var h=-(Y.dotVec3(n,a)+u)/c;return Y.mulVec3Scalar(e,h,s),Y.addVec3(s,a),Y.subVec3(s,l,s),!0}return!1}}(),C=!1;this._onCameraControlHover=this._viewer.cameraControl.on("hoverEnter",function(t){var n;e._visible&&(C||(i=!1,y&&(y.visible=!1),t.entity.id===e._displayMeshes.plane.id?(n=e._affordanceMeshes.plane,a=o,n&&(n.visible=!0),y=n,i=!0):a=r))}),this._onCameraControlHoverLeave=this._viewer.cameraControl.on("hoverOut",function(t){e._visible&&(y&&(y.visible=!1),a=r,i=!1)}),d.addEventListener("mousedown",this._canvasMouseDownListener=function(t){if(t.preventDefault(),e._visible&&i&&(e._viewer.cameraControl.pointerEnabled=!1,1===t.which)){C=!0;var r=b(t);l=a,u[0]=r[0],u[1]=r[1],e.plugin.fire("clickPlaneStart")}}),d.addEventListener("mousemove",this._canvasMouseMoveListener=function(t){if(e._visible&&C){var i=b(t),r=i[0],a=i[1];switch(l){case n:B(c,u,i);break;case s:B(h,u,i);break;case o:B(A,u,i)}u[0]=r,u[1]=a}}),d.addEventListener("mouseup",this._canvasMouseUpListener=function(t){e._visible&&(e._viewer.cameraControl.pointerEnabled=!0,C&&(C=!1,i=!1,e.plugin.fire("clickPlaneEnd")))}),d.addEventListener("wheel",this._canvasWheelListener=function(t){if(e._visible)Math.max(-1,Math.min(1,40*-t.deltaY))})}},{key:"_destroy",value:function(){this._unbindEvents(),this._destroyNodes()}},{key:"_unbindEvents",value:function(){var e=this._viewer,t=e.scene,i=t.canvas.canvas,r=e.camera,n=e.cameraControl;t.off(this._onSceneTick),i.removeEventListener("mousedown",this._canvasMouseDownListener),i.removeEventListener("mousemove",this._canvasMouseMoveListener),i.removeEventListener("mouseup",this._canvasMouseUpListener),i.removeEventListener("wheel",this._canvasWheelListener),i.removeEventListener("touchend",this._canvasTouchEndListener),i.removeEventListener("touchcancel",this._canvasTouchEndListener),r.off(this._onCameraViewMatrix),r.off(this._onCameraProjMatrix),n.off(this._onCameraControlHover),n.off(this._onCameraControlHoverLeave)}},{key:"_destroyNodes",value:function(){this._setSectionPlane(null),this._rootNode.destroy(),this._displayMeshes={},this._affordanceMeshes={}}}])}(),hk=new Float64Array([0,0,1]),Ak=new Float64Array(4),dk=function(){return P(function e(t,i){x(this,e),this.id=null,this.type="plane",this.plugin=t,this._viewer=t.viewer,this._scene=t.viewer.scene,this._controlFillColor=i&&i.controlFillColor?i.controlFillColor:[.1,.4,.99],this._planeSize=i&&i.planeSize?i.planeSize:1,this._controlSize=i&&i.controlSize?i.controlSize:.07,this._planeOpacity=i&&i.planeOpacity?i.planeOpacity:.4,this._visible=!1,this._pos=Y.vec3(),this._origin=Y.vec3(),this._rtcPos=Y.vec3(),this._baseDir=Y.vec3(),this._rootNode=null,this._displayMeshes=null,this._affordanceMeshes=null,this._ignoreNextSectionPlaneDirUpdate=!1,this._createNodes(),this._bindEvents()},[{key:"_createNodes",value:function(){var e=this._viewer.scene;this._rootNode=new yn(e,{position:[0,0,0],scale:[5,5,5],isObject:!1});var t=this._rootNode;this._displayMeshes={plane:t.addChild(new on(t,{geometry:new Ci(t,{primitive:"triangles",positions:[.5,.5,.02,.5,-.5,.02,-.5,-.5,.02,-.5,.5,.02],indices:[0,1,2,2,3,0]}),material:new Ti(t,{emissive:[0,0,0],diffuse:this._controlFillColor,backfaces:!0}),opacity:this._planeOpacity,ghosted:!0,ghostMaterial:new Fi(t,{edges:!1,filled:!0,fillColor:this._controlFillColor?this._controlFillColor:[.1,.4,.99],fillAlpha:.1,backfaces:!0}),pickable:!0,collidable:!1,clippable:!1,visible:!1,scale:[2.4*this._planeSize,2.4*this._planeSize,1*this._planeSize],isObject:!1}),!1)},this._affordanceMeshes={}}},{key:"_setSectionPlane",value:function(e){var t=this;this._sectionPlane&&(this._sectionPlane.off(this._onSectionPlanePos),this._sectionPlane.off(this._onSectionPlaneDir),this._onSectionPlanePos=null,this._onSectionPlaneDir=null,this._sectionPlane=null),e&&(this.id=e.id,this._setPos(e.pos),this._setDir(e.dir),this._sectionPlane=e,e.control=this,this._onSectionPlanePos=e.on("pos",function(){t._setPos(t._sectionPlane.pos)}),this._onSectionPlaneDir=e.on("dir",function(){t._ignoreNextSectionPlaneDirUpdate?t._ignoreNextSectionPlaneDirUpdate=!1:t._setDir(t._sectionPlane.dir)}))}},{key:"sectionPlane",get:function(){return this._sectionPlane}},{key:"pos",get:function(){return this._pos},set:function(e){if(!(e<0||e>100)){var t=this._scene.aabb,i=this._scene.center,r=t[3]-t[0],n=t[4]-t[1],s=t[5]-t[2],o=Y.vec3();o[0]=this.pos[0],o[1]=this.pos[1],o[2]=this.pos[2];var a,l=this._sectionPlane.dir;0!=l[0]?(a=e/100*r,o[0]=i[0]-r/2+a):0!=l[1]?(a=e/100*n,o[1]=i[1]-n/2+a):0!=l[2]&&(a=e/100*s,o[2]=i[2]-s/2+a),this._sectionPlane.pos=o}}},{key:"posRate",get:function(){var e=this._scene.aabb,t=this._scene.center,i=e[3]-e[0],r=e[4]-e[1],n=e[5]-e[2],s=this._sectionPlane.pos,o=this._sectionPlane.dir,a=0;if(0!=o[0])a=(s[0]-(t[0]-i/2))/i*100;else if(0!=o[1]){a=(s[1]-(t[1]-r/2))/r*100}else if(0!=o[2]){a=(s[2]-(t[2]-n/2))/n*100}return a=Math.max(0,Math.min(100,a)),parseInt(a)}},{key:"_setPos",value:function(e){this._pos.set(e),be(this._pos,this._origin,this._rtcPos),this._rootNode.origin=this._origin,this._rootNode.position=this._rtcPos}},{key:"_setDir",value:function(e){this._baseDir.set(e),this._rootNode.quaternion=Y.vec3PairToQuaternion(hk,e,Ak)}},{key:"_setSectionPlaneDir",value:function(e){this._sectionPlane&&(this._ignoreNextSectionPlaneDirUpdate=!0,this._sectionPlane.dir=e)}},{key:"setVisible",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];if(this._visible!==e){var t;for(t in this._visible=e,this._displayMeshes)this._displayMeshes.hasOwnProperty(t)&&(this._displayMeshes[t].visible=e);if(!e)for(t in this._affordanceMeshes)this._affordanceMeshes.hasOwnProperty(t)&&(this._affordanceMeshes[t].visible=e)}}},{key:"getVisible",value:function(){return this._visible}},{key:"setCulled",value:function(e){var t;for(t in this._displayMeshes)this._displayMeshes.hasOwnProperty(t)&&(this._displayMeshes[t].culled=e);if(!e)for(t in this._affordanceMeshes)this._affordanceMeshes.hasOwnProperty(t)&&(this._affordanceMeshes[t].culled=e)}},{key:"_bindEvents",value:function(){var e=this,t=this,i=!1,r=-1,n=0,s=1,o=2;this._rootNode;var a=null,l=null,u=Y.vec2();this.lastCanvasPos=u;var c=Y.vec3([1,0,0]),h=Y.vec3([0,1,0]),A=Y.vec3([0,0,1]),d=this._viewer.scene.canvas.canvas,p=this._viewer.camera,f=this._viewer.scene,g=Y.vec3([0,0,0]),m=-1;this._onCameraViewMatrix=f.camera.on("viewMatrix",function(){}),this._onCameraProjMatrix=f.camera.on("projMatrix",function(){}),this._onSceneTick=f.on("tick",function(){var t=Math.abs(Y.lenVec3(Y.subVec3(f.camera.eye,e._pos,g)));t!==m&&"perspective"===p.projection&&(Math.tan(p.perspective.fov*Y.DEGTORAD),m=t),"ortho"===p.projection&&(p.ortho.scale,m=t)});var v,_,y,b,w=function(){var e=new Float64Array(2);return function(t){if(t){for(var i=t.target,r=0,n=0;i.offsetParent;)r+=i.offsetLeft,n+=i.offsetTop,i=i.offsetParent;e[0]=t.pageX-r,e[1]=t.pageY-n}else t=window.event,e[0]=t.x,e[1]=t.y;return e}}(),x=function(){var e=new Float64Array(2);return function(t){if(t||(t=window.event),t.touches&&t.touches.length)e[0]=t.touches[0].pageX,e[1]=t.touches[0].pageY;else{for(var i=t.target,r=0,n=0;i.offsetParent;)r+=i.offsetLeft,n+=i.offsetTop,i=i.offsetParent;e[0]=t.pageX-r,e[1]=t.pageY-n}return e}}(),B=function(){var e=Y.mat4();return function(i,r){return Y.quaternionToMat4(t._rootNode.quaternion,e),Y.transformVec3(e,i,r),Y.normalizeVec3(r),r}}(),P=(v=Y.vec3(),function(e){var t=Math.abs(e[0]);return t>Math.abs(e[1])&&t>Math.abs(e[2])?Y.cross3Vec3(e,[0,1,0],v):Y.cross3Vec3(e,[1,0,0],v),Y.cross3Vec3(v,e,v),Y.normalizeVec3(v),v}),C=(_=Y.vec3(),y=Y.vec3(),b=Y.vec4(),function(e,i,r){B(e,b);var n=P(b,i,r);M(i,n,_),M(r,n,y),Y.subVec3(y,_);var s=Y.dotVec3(y,b);t._pos[0]+=b[0]*s*.6,t._pos[1]+=b[1]*s*.6,t._pos[2]+=b[2]*s*.6,t._rootNode.position=t._pos,t._sectionPlane&&(t._sectionPlane.pos=t._pos)}),M=function(){var e=Y.vec4([0,0,0,1]),i=Y.mat4();return function(r,n,s,o){o=o||0,e[0]=r[0]/d.width*2-1,e[1]=-(r[1]/d.height*2-1),e[2]=0,e[3]=1,Y.mulMat4(p.projMatrix,p.viewMatrix,i),Y.inverseMat4(i),Y.transformVec4(i,e,e),Y.mulVec4Scalar(e,1/e[3]);var a=p.eye;Y.subVec4(e,a,e);var l=t._sectionPlane.pos,u=-Y.dotVec3(l,n)-o,c=Y.dotVec3(n,e);if(Math.abs(c)>.005){var h=-(Y.dotVec3(n,a)+u)/c;return Y.mulVec3Scalar(e,h,s),Y.addVec3(s,a),Y.subVec3(s,l,s),!0}return!1}}(),k=!1;this._onCameraControlHover=this._viewer.cameraControl.on("hoverEnter",function(t){e._visible&&(k||(i=!1,t.entity.id===e._displayMeshes.plane.id?(a=o,i=!0):a=r))}),this._onCameraControlHoverLeave=this._viewer.cameraControl.on("hoverOut",function(t){e._visible&&(a=r,i=!1)}),d.addEventListener("mousedown",this._canvasMouseDownListener=function(t){if(t.preventDefault(),e._visible&&i&&(e._viewer.cameraControl.pointerEnabled=!1,1===t.which)){k=!0;var r=w(t);l=a,u[0]=r[0],u[1]=r[1],e.plugin.fire("clickPlaneStart")}}),d.addEventListener("mousemove",this._canvasMouseMoveListener=function(t){if(e._visible&&k){var i=w(t),r=i[0],a=i[1];switch(l){case n:C(c,u,i);break;case s:C(h,u,i);break;case o:C(A,u,i)}u[0]=r,u[1]=a}}),d.addEventListener("mouseup",this._canvasMouseUpListener=function(t){e._visible&&(e._viewer.cameraControl.pointerEnabled=!0,k&&(t.which,k=!1,i=!1,e.plugin.fire("clickPlaneEnd")))}),d.addEventListener("wheel",this._canvasWheelListener=function(t){if(e._visible)Math.max(-1,Math.min(1,40*-t.deltaY))}),this._onCameraControlHover=this._viewer.cameraControl.on("touchEntity",function(t){var n;!e._visible||k||i||(t.entity.id===e._displayMeshes.plane.id?(n=e._affordanceMeshes.plane,a=o,n&&(n.visible=!0),i=!0,k=!0):a=r)}),d.addEventListener("touchstart",this._canvasMouseDownListener=function(t){if(t.preventDefault(),e._visible&&i&&k){e._viewer.cameraControl.pointerEnabled=!1;var r=x(t);l=a,u[0]=r[0],u[1]=r[1],e.plugin.fire("touchPlaneStart")}}),d.addEventListener("touchmove",this._canvasMouseMoveListener=function(t){if(e._visible&&k&&i){var r=x(t),a=r[0],d=r[1];switch(l){case n:C(c,u,r);break;case s:C(h,u,r);break;case o:C(A,u,r)}u[0]=a,u[1]=d}}),d.addEventListener("touchend",this._canvasTouchEndListener=function(t){e._visible&&(i&&(e._viewer.cameraControl.pointerEnabled=!0),a=r,k=!1,i=!1,e.plugin.fire("touchPlaneEnd"))}),d.addEventListener("touchcancel",this._canvasTouchEndListener)}},{key:"_destroy",value:function(){this._unbindEvents(),this._destroyNodes()}},{key:"_unbindEvents",value:function(){var e=this._viewer,t=e.scene,i=t.canvas.canvas,r=e.camera,n=e.cameraControl;t.off(this._onSceneTick),i.removeEventListener("mousedown",this._canvasMouseDownListener),i.removeEventListener("mousemove",this._canvasMouseMoveListener),i.removeEventListener("mouseup",this._canvasMouseUpListener),i.removeEventListener("wheel",this._canvasWheelListener),i.removeEventListener("touchend",this._canvasTouchEndListener),i.removeEventListener("touchcancel",this._canvasTouchEndListener),r.off(this._onCameraViewMatrix),r.off(this._onCameraProjMatrix),n.off(this._onCameraControlHover),n.off(this._onCameraControlHoverLeave)}},{key:"_destroyNodes",value:function(){this._setSectionPlane(null),this._rootNode.destroy(),this._displayMeshes={},this._affordanceMeshes={}}}])}(),pk=function(){return P(function e(t,i,r){var n=this;x(this,e),this.id=r.id,this._sectionPlane=r,this._mesh=new on(i,{id:r.id,geometry:new Ci(i,Mi({xSize:.5,ySize:.5,zSize:.001})),material:new Ti(i,{emissive:[1,1,1],diffuse:[0,0,0],backfaces:!1}),edgeMaterial:new Ri(i,{edgeColor:[0,0,0],edgeAlpha:1,edgeWidth:1}),highlightMaterial:new Fi(i,{fill:!0,fillColor:[.5,1,.5],fillAlpha:.7,edges:!0,edgeColor:[0,0,0],edgeAlpha:1,edgeWidth:1}),selectedMaterial:new Fi(i,{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});var s=Y.vec3([0,0,0]),o=Y.vec3(),a=Y.vec3([0,0,1]),l=Y.vec4(4),u=Y.vec3(),c=function(){var e=n._sectionPlane.scene.center,t=[-n._sectionPlane.dir[0],-n._sectionPlane.dir[1],-n._sectionPlane.dir[2]];Y.subVec3(e,n._sectionPlane.pos,s);var i=-Y.dotVec3(t,s);Y.normalizeVec3(t),Y.mulVec3Scalar(t,i,o);var r=Y.vec3PairToQuaternion(a,n._sectionPlane.dir,l);u[0]=.1*o[0],u[1]=.1*o[1],u[2]=.1*o[2],n._mesh.quaternion=r,n._mesh.position=u};this._onSectionPlanePos=this._sectionPlane.on("pos",c),this._onSectionPlaneDir=this._sectionPlane.on("dir",c),this._highlighted=!1,this._selected=!1},[{key:"setHighlighted",value:function(e){this._highlighted=!!e,this._mesh.highlighted=this._highlighted,this._mesh.highlightMaterial.fillColor=e?[0,.7,0]:[0,0,0]}},{key:"getHighlighted",value:function(){return this._highlighted}},{key:"setSelected",value:function(e){this._selected=!!e,this._mesh.edgeMaterial.edgeWidth=e?3:1,this._mesh.highlightMaterial.edgeWidth=e?3:1}},{key:"getSelected",value:function(){return this._selected}},{key:"destroy",value:function(){this._sectionPlane.off(this._onSectionPlanePos),this._sectionPlane.off(this._onSectionPlaneDir),this._mesh.destroy()}}])}(),fk=function(){return P(function e(t,i,r){var n=this;x(this,e),this.id=sectionPlane.id,this._sectionBox=r,this._mesh=new on(i,{id:sectionPlane.id,geometry:new Ci(i,Mi({xSize:.5,ySize:.5,zSize:.001})),material:new Ti(i,{emissive:[1,1,1],diffuse:[0,0,0],backfaces:!1}),edgeMaterial:new Ri(i,{edgeColor:[0,0,0],edgeAlpha:1,edgeWidth:1}),highlightMaterial:new Fi(i,{fill:!0,fillColor:[.5,1,.5],fillAlpha:.7,edges:!0,edgeColor:[0,0,0],edgeAlpha:1,edgeWidth:1}),selectedMaterial:new Fi(i,{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});var s=Y.vec3([0,0,0]),o=Y.vec3(),a=Y.vec3([0,0,1]),l=Y.vec4(4),u=Y.vec3(),c=function(){var e=n._sectionBox.scene.center,t=[-n._sectionBox.dir[0],-n._sectionBox.dir[1],-n._sectionBox.dir[2]];Y.subVec3(e,n._sectionBox.pos,s);var i=-Y.dotVec3(t,s);Y.normalizeVec3(t),Y.mulVec3Scalar(t,i,o);var r=Y.vec3PairToQuaternion(a,n._sectionBox.dir,l);u[0]=.1*o[0],u[1]=.1*o[1],u[2]=.1*o[2],n._mesh.quaternion=r,n._mesh.position=u};this._onSectionPlanePos=this._sectionBox.on("pos",c),this._onSectionPlaneDir=this._sectionBox.on("dir",c),this._highlighted=!1,this._selected=!1},[{key:"setHighlighted",value:function(e){this._highlighted=!!e,this._mesh.highlighted=this._highlighted,this._mesh.highlightMaterial.fillColor=e?[0,.7,0]:[0,0,0]}},{key:"getHighlighted",value:function(){return this._highlighted}},{key:"setSelected",value:function(e){this._selected=!!e,this._mesh.edgeMaterial.edgeWidth=e?3:1,this._mesh.highlightMaterial.edgeWidth=e?3:1}},{key:"getSelected",value:function(){return this._selected}},{key:"destroy",value:function(){this._sectionBox.off(this._onSectionPlanePos),this._sectionBox.off(this._onSectionPlaneDir),this._mesh.destroy()}}])}(),gk=function(){return P(function e(t,i){var r=this;if(x(this,e),!(i.onHoverEnterPlane&&i.onHoverLeavePlane&&i.onClickedNothing&&i.onClickedPlane))throw"Missing config(s): onHoverEnterPlane, onHoverLeavePlane, onClickedNothing || onClickedPlane";this.plugin=t,this._viewer=t.viewer,this._onHoverEnterPlane=i.onHoverEnterPlane,this._onHoverLeavePlane=i.onHoverLeavePlane,this._onClickedNothing=i.onClickedNothing,this._onClickedPlane=i.onClickedPlane,this._visible=!0,this._planes={},this._box=null,this._canvas=i.overviewCanvas,this._scene=new zi(this._viewer,{canvasId:this._canvas.id,transparent:!0,spinnerElementId:"overviewer_spinner"}),this._scene.clearLights(),new hi(this._scene,{dir:[.4,-.4,.8],color:[.8,1,1],intensity:1,space:"view"}),new hi(this._scene,{dir:[-.8,-.3,-.4],color:[.8,.8,.8],intensity:1,space:"view"}),new hi(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;var n=this._scene.camera,s=Y.rotationMat4c(-90*Y.DEGTORAD,1,0,0),o=Y.vec3(),a=Y.vec3(),l=Y.vec3();this._synchCamera=function(){var e=r._viewer.camera.eye,t=r._viewer.camera.look,i=r._viewer.camera.up;Y.mulVec3Scalar(Y.normalizeVec3(Y.subVec3(e,t,o)),7),r._zUp?(Y.transformVec3(s,o,a),Y.transformVec3(s,i,l),n.look=[0,0,0],n.eye=Y.transformVec3(s,o,a),n.up=Y.transformPoint3(s,i,l)):(n.look=[0,0,0],n.eye=o,n.up=i)},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",function(e){r._scene.camera.perspective.fov=e});var u=null;this._onInputMouseMove=this._scene.input.on("mousemove",function(e){var t=r._scene.pick({canvasPos:e});if(t){if(!u||t.entity.id!==u.id){if(u)r._planes[u.id]&&r._onHoverLeavePlane(u.id);u=t.entity,r._planes[u.id]&&r._onHoverEnterPlane(u.id)}}else u&&(r._onHoverLeavePlane(u.id),u=null)}),this._scene.canvas.canvas.addEventListener("mouseup",this._onCanvasMouseUp=function(){u?r._planes[u.id]&&r._onClickedPlane(u.id):r._onClickedNothing()}),this._scene.canvas.canvas.addEventListener("mouseout",this._onCanvasMouseOut=function(){u&&(r._onHoverLeavePlane(u.id),u=null)}),this.setVisible(i.overviewVisible)},[{key:"addSectionPlane",value:function(e){this._planes[e.id]=new pk(this,this._scene,e)}},{key:"setSectionBox",value:function(e){this._box=new fk(this,this._scene,e)}},{key:"setPlaneHighlighted",value:function(e,t){var i=this._planes[e];i&&i.setHighlighted(t)}},{key:"setPlaneSelected",value:function(e,t){var i=this._planes[e];i&&i.setSelected(t)}},{key:"removeSectionPlane",value:function(e){var t=this._planes[e.id];t&&(t.destroy(),delete this._planes[e.id])}},{key:"setVisible",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];this._visible=e,this._canvas.style.visibility=e?"visible":"hidden"}},{key:"getVisible",value:function(){return this._visible}},{key:"destroy",value:function(){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()}}])}(),mk=function(){return P(function e(t){x(this,e),this._viewer=t.viewer,this._scene=t.viewer.scene,this._sectionPlugin=t,this._boxCenter=[0,0,0],this._maxRange=[],this._createNodes()},[{key:"_createNodes",value:function(){var e=this._viewer.scene,t=e.aabb,i=e.center,r=t[3]-t[0],n=t[4]-t[1],s=t[5]-t[2];this._rootNode=new yn(e,{id:"sectionControl",position:i,scale:[1,1,1],isObject:!1});var o=this._rootNode;this._displayMeshes={box:o.addChild(new on(o,{geometry:new Ci(o,Dn({center:this._boxCenter,xSize:.5*(r>0?r:-1*r)+0,ySize:.5*(n>0?n:-1*n)+0,zSize:.5*(s>0?s:-1*s)+0})),material:new Ti(o,{emissive:[.5,6.5,9.5],diffuse:[.5,6.5,9.5],specular:[.5,.5,.5],alpha:.2,shininess:10}),pickable:!1,collidable:!1,clippable:!1,visible:!0,scale:[1,1,1],isObject:!1}),!1)}}},{key:"updateBox",value:function(e,t){if(!(t.length<6)){var i,r,n;i=t[3][0]-t[0][0],r=t[4][1]-t[1][1],n=t[5][2]-t[2][2];var s=this._getGeometryPoisition(e,i,r,n);this._setGeometryPosition(s)}}},{key:"_getGeometryPoisition",value:function(e,t,i,r){var n=.5,s=this._boxCenter;return 0!=e[0]&&(e[0]<0&&(s[0]-=((t>0?t:-1*t)*n+.2)/4),e[0]>0&&(s[0]+=((t>0?t:-1*t)*n+.2)/4)),0!=e[1]&&(e[1]<0&&(s[1]-=((i>0?i:-1*i)*n+.2)/4),e[1]>0&&(s[1]+=((i>0?i:-1*i)*n+.2)/4)),0!=e[2]&&(e[2]<0&&(s[2]-=((r>0?r:-1*r)*n+.2)/4),e[2]>0&&(s[2]+=((r>0?r:-1*r)*n+.2)/4)),Dn({center:s,xSize:(t>0?t:-1*t)*n+.2,ySize:(i>0?i:-1*i)*n+.2,zSize:(r>0?r:-1*r)*n+.2}).positions}},{key:"_setGeometryPosition",value:function(e){this._displayMeshes.box.geometry.positions=e}},{key:"setVisible",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];if(this._visible!==e){var t;for(t in this._visible=e,this._displayMeshes)this._displayMeshes.hasOwnProperty(t)&&(this._displayMeshes[t].visible=e);if(!e)for(t in this._affordanceMeshes)this._affordanceMeshes.hasOwnProperty(t)&&(this._affordanceMeshes[t].visible=e)}}},{key:"getVisible",value:function(){return this._visible}},{key:"_destroy",value:function(){this._rootNode.destroy(),this._displayMeshes={}}}])}(),vk=Y.AABB3(),_k=Y.vec3(),yk=function(){function e(t){var i,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(x(this,e),(i=d(this,e,["SectionPlanes",t]))._freeControls=[],i._controlBox=null,i._singleCtrlBox=null,i._sectionWay=null,i._sectionPlanes=t.scene.sectionPlanes,i._controls={},i._currentControl=null,i._shownControlId=null,i._shownControlIds=[],i._boxPlaneConfig={id:"",planeId:-1,enableClip:!1,controlFillColor:[3,9,9]},null!==r.overviewCanvasId&&void 0!==r.overviewCanvasId){var n=document.getElementById(r.overviewCanvasId);n?i._overview=new gk(i,{overviewCanvas:n,visible:r.overviewVisible,onHoverEnterPlane:function(e){i._overview.setPlaneHighlighted(e,!0)},onHoverLeavePlane:function(e){i._overview.setPlaneHighlighted(e,!1)},onClickedPlane:function(e){if(i.getShownControl()!==e){i.showControl(e);var t=i.sectionPlanes[e].pos;vk.set(i.viewer.scene.aabb),Y.getAABB3Center(vk,_k),vk[0]+=t[0]-_k[0],vk[1]+=t[1]-_k[1],vk[2]+=t[2]-_k[2],vk[3]+=t[0]-_k[0],vk[4]+=t[1]-_k[1],vk[5]+=t[2]-_k[2],i.viewer.cameraFlight.flyTo({aabb:vk,fitFOV:65})}else i.hideControl()},onClickedNothing:function(){i.hideControl()}}):i.warn("Can't find overview canvas: '"+r.overviewCanvasId+"' - will create plugin without overview")}return i._onSceneSectionPlaneCreated=t.scene.on("sectionPlaneCreated",function(e){i._sectionPlaneCreated(e)}),i._onSceneSectionBoxCreated=t.scene.on("sectionBoxCreated",function(e){i._controlBox=e}),i.controlset=r.controlset,i}return _(e,ge),P(e,[{key:"setOverviewVisible",value:function(e){this._overview&&this._overview.setVisible(e)}},{key:"getOverviewVisible",value:function(){if(this._overview)return this._overview.getVisible()}},{key:"sectionPlanes",get:function(){return this._sectionPlanes}},{key:"createSectionPlane",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return void 0!==e.id&&null!==e.id&&this.viewer.scene.components[e.id]&&(this.error("Viewer component with this ID already exists: "+e.id),delete e.id),new cn(this.viewer.scene,{id:e.id,pos:e.pos,dir:e.dir,active:!0})}},{key:"createSectionBox",value:function(){this._sectionWay="box";var e=new mk(this);return new Sh(this.viewer.scene,{id:"sectionBox",active:!0,controlIdName:"sectionBoxPlane_",lineBox:e})}},{key:"createSectionSingle",value:function(){return this._sectionWay="box",new Sh(this.viewer.scene,{id:"sectionBox",active:!0,pickable:!1,enableClip:!1,controlIdName:"sectionBoxPlane_"})}},{key:"_sectionPlaneCreated",value:function(e){var t,i=this;switch(this._sectionWay){case"plane":t=this._freeControls.length>0?this._freeControls.pop():new dk(this,this._controlsConfig);break;case"box":this._boxPlaneConfig.enableClip=e.enableClip,this._boxPlaneConfig.pickable=e.pickable,this._boxPlaneConfig.controlFillColor=e.controlFillColor,t=this._freeControls.length>0?this._freeControls.pop():new ck(this,this._boxPlaneConfig);break;case"singleCtrl":t=this._freeControls.length>0?this._freeControls.pop():new ak(this,this.controlset);break;default:t=new nk(this)}var r=t;r._setSectionPlane(e),r.setVisible(!0),e.control=r,this._currentControl=r,null==e.box&&(this._controls[e.id]=r),this._overview&&this._overview.addSectionPlane(e),e.once("destroyed",function(){i._sectionPlaneDestroyed(e)})}},{key:"isTouch",set:function(e){this._isTouch=e,this.sectionWay=!0===e?"plane":this._sectionWay?this._sectionWay:"control"}},{key:"sectionConfigs",set:function(e){this._controlsConfig=e}},{key:"boxPlaneConfigs",set:function(e){this._boxPlaneConfig=e}},{key:"sectionWay",set:function(e){this._sectionWay=e}},{key:"sectionDirection",set:function(e){var t;switch(this.clear(),e){case 0:t=[0,0,-1];break;case 1:t=[-1,0,0];break;case 2:t=[0,-1,0]}var i=this.viewer.scene.center;this.createSectionPlane({pos:Y.AABB3([i[0],i[1],i[2]]),dir:t})}},{key:"sectionSingleDirection",set:function(e){var t;switch(this.hideControl(),this._sectionWay="singleCtrl",e){case 0:t=[0,0,-1];break;case 1:t=[-1,0,0];break;case 2:t=[0,-1,0]}var i=this.viewer.scene.center;this.createSectionPlane({pos:Y.AABB3([i[0],i[1],i[2]]),dir:t})}},{key:"controlBox",get:function(){return this._controlBox}},{key:"setControlPos",value:function(e){null!=this._currentControl&&(this._currentControl.pos=e)}},{key:"getControlPos",value:function(){return null==this._currentControl?-1:this._currentControl.posRate}},{key:"flipSectionPlanes",value:function(){var e=this.viewer.scene.sectionPlanes;for(var t in e){e[t].flipDir()}}},{key:"showControl",value:function(e){var t=this._controls[e];t?(t.setVisible(!0),this._overview&&this._overview.setPlaneSelected(e,!0),this._shownControlId=e,this._shownControlIds=[e]):this.error("Control not found: "+e)}},{key:"setControlsSize",value:function(e){for(var t in this._controls)this._controls[t].controlSize=e}},{key:"setControlSizeByID",value:function(e,t){this._controls[e]?this._controls[e].controlSize=t:this.error("Control not found: "+e)}},{key:"getShownControl",value:function(){return this._shownControlId}},{key:"getShownControls",value:function(){return this._shownControlIds}},{key:"showAllControl",value:function(){for(var e in this._controls)this._controls.hasOwnProperty(e)&&(this._shownControlIds.push(e),this._controls[e].setVisible(!1),this._overview&&this._overview.setPlaneSelected(e,!1))}},{key:"hideControl",value:function(){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,this._shownControlIds=[]}},{key:"destroySectionPlane",value:function(e){var t=this.viewer.scene.sectionPlanes[e];t?(this._sectionPlaneDestroyed(t),t.destroy(),e===this._shownControlId&&(this._shownControlId=null,this._shownControlIds=[])):this.error("SectionPlane not found: "+e)}},{key:"_sectionPlaneDestroyed",value:function(e){this._overview&&this._overview.removeSectionPlane(e);var t=this._controls[e.id];t&&(t.setVisible(!1),t._setSectionPlane(null),delete this._controls[e.id],this._freeControls.push(t))}},{key:"clear",value:function(){this._controlBox&&this._controlBox.destroy();for(var e=Object.keys(this._sectionPlanes),t=0,i=e.length;t<i;t++)this.destroySectionPlane(e[t])}},{key:"send",value:function(e,t){switch(e){case"snapshotStarting":for(var i in this._controls)this._controls.hasOwnProperty(i)&&this._controls[i].setCulled(!0);break;case"snapshotFinished":for(var r in this._controls)this._controls.hasOwnProperty(r)&&this._controls[r].setCulled(!1);break;case"clearSectionPlanes":this.clear()}}},{key:"destroy",value:function(){this.clear(),this._overview&&this._overview.destroy(),this._destroyFreeControls(),g(e,"destroy",this,3)([])}},{key:"_destroyFreeControls",value:function(){for(var e=this._freeControls.pop();e;)e._destroy(),e=this._freeControls.pop();this.viewer.scene.off(this._onSceneSectionPlaneCreated)}}])}();Y.vec3(),Y.mat4();var bk=function(){function e(t){var i;return x(this,e),(i=d(this,e,["skyboxes",t])).skyboxes={},i._active=!1,i}return _(e,ge),P(e,[{key:"send",value:function(e,t){if("clear"===e)this.clear()}},{key:"createSkybox",value:function(e,t){if(this.viewer.scene.components[e])return this.error("Component with this ID already exists: "+e),this;if(!t.src&&!t.image)return this.error("No legal skybox image or src: "+e),this;if(t.src){var i=new Th(this.viewer.scene,{id:e,size:t.size,scale:t.scale,src:t.src,active:t.active,encoding:3e3});return this.skyboxes[e]=i,i}if(t.image){i=new Th(this.viewer.scene,{id:e,size:t.size,scale:t.scale,image:t.image,active:t.active,encoding:3e3});return this.skyboxes[e]=i,i}}},{key:"setSkyBoxActiveById",value:function(e,t){this.skyboxes[e].active=t}},{key:"active",get:function(){return this._active},set:function(e){this._active=e;for(var t=0;t<this.skyboxes.length;t++)this.skyboxes[t].active=e}},{key:"getSkyBoxById",value:function(e){return this.skyboxes[e]}},{key:"destroySkybox",value:function(e){var t=this.skyboxes[e];t?t.destroy():this.error("Skybox not found: "+e)}},{key:"clear",value:function(){for(var e=Object.keys(this.skyboxes),t=0,i=e.length;t<i;t++)this.destroySkybox(e[t])}},{key:"destroy",value:function(){this.clear()}}])}(),wk=[],xk=function(){function e(t){var i,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};x(this,e),(i=d(this,e,["TreeViewPlugin",t])).errors=[],i.valid=!0;for(var n=0;;n++)if(!wk[n]){wk[n]=i,i._index=n,i._id="tree-".concat(n);break}if(i._metaModels={},i._autoAddModels=!1!==r.autoAddModels,i._autoExpandDepth=r.autoExpandDepth||0,i._sortNodes=!1!==r.sortNodes,i._viewer=t,i._rootElement=null,i._muteSceneEvents=!1,i._muteTreeEvents=!1,i._rootNodes=[],i._objectNodes={},i._nodeNodes={},i._rootNames={},i._sortNodes=r.sortNodes,i._pruneEmptyNodes=r.pruneEmptyNodes,i._showListItemElementId=null,i._onObjectVisibility=i._viewer.scene.on("objectVisibility",function(e){if(!i._muteSceneEvents){var t=e.id,r=i._objectNodes[t];if(r){var n=e.visible;if(n!==r.checked){i._muteTreeEvents=!0,r.checked=n,n?r.numVisibleEntities++:r.numVisibleEntities--;for(var s=r.parent;s;)s.checked=n,n?s.numVisibleEntities++:s.numVisibleEntities--,s=s.parent;i._muteTreeEvents=!1}}}}),i._onObjectXrayed=i._viewer.scene.on("objectXRayed",function(e){if(!i._muteSceneEvents){var t=e.id,r=i._objectNodes[t];if(r){i._muteTreeEvents=!0;var n=e.xrayed;n!==r.xrayed&&(r.xrayed=n,i._muteTreeEvents=!1)}}}),i._hierarchy=r.hierarchy||"containment",i._autoExpandDepth=r.autoExpandDepth||0,i._autoAddModels){for(var s=Object.keys(i.viewer.metaScene.metaModels),o=0,a=s.length;o<a;o++){var l=s[o];i.viewer.metaScene.metaModels[l].finalized&&i.addModel(l)}i.viewer.scene.on("modelLoaded",function(e){i.viewer.metaScene.metaModels[e]&&i.addModel(e)})}return i}return _(e,ge),P(e,[{key:"switchExpandHandler",value:function(e){e.preventDefault(),e.stopPropagation(),e.target,this.fire("ExpandHandler",e)}},{key:"switchCollapseHandler",value:function(e){e.preventDefault(),e.stopPropagation(),this.fire("CollapseHandler",e)}},{key:"checkboxChangeHandler",value:function(e){if(this.fire("checkBoxChanged",e),!this._muteTreeEvents){this._muteSceneEvents=!0;var t=e.target,i=t.checked,r=t.id.replace("checkbox-",""),n=this._nodeNodes[r],s=this._viewer.scene.objects,o=0;this._withNodeTree(n,function(e){var t=e.objectId,r=s[t],n=0===e.children.length;e.numVisibleEntities=i?e.numEntities:0,n&&i!==e.checked&&o++,e.checked=i,function(e,t){var i=document.getElementById("checkbox-".concat(e));i&&t!==i.checked&&(i.checked=t)}(e.nodeId,i),r&&(r.visible=i)});for(var a=n.parent;a;)a.checked=i,i?a.numVisibleEntities+=o:a.numVisibleEntities-=o,l(a.nodeId,a.numVisibleEntities>0),a=a.parent;this._muteSceneEvents=!1}function l(e,t){var i=document.getElementById("checkbox-".concat(e));i&&t!==i.checked&&(i.checked=t)}}},{key:"hierarchy",get:function(){return this._hierarchy},set:function(e){"containment"!==(e=e||"containment")&&"storeys"!==e&&"types"!==e&&(this.error("Unsupported value for `hierarchy' - defaulting to 'containment'"),e="containment"),this._hierarchy!==e&&(this._hierarchy=e,this._createNodes())}},{key:"muteTreeEvents",get:function(){return this._muteTreeEvents},set:function(e){this._muteTreeEvents=e}},{key:"nodeNodes",get:function(){return this._nodeNodes}},{key:"_createNodes",value:function(){this._rootElement&&(this._rootElement.parentNode.removeChild(this._rootElement),this._rootElement=null),this._rootNodes=[],this._objectNodes={},this._nodeNodes={},this._validate(),(this.valid||"storeys"!==this._hierarchy)&&this._createEnabledNodes()}},{key:"_createEnabledNodes",value:function(){switch(this._pruneEmptyNodes&&this._findEmptyNodes(),this._hierarchy){case"storeys":this._createStoreysNodes(),0===this._rootNodes.length&&this.warn("Failed to build storeys hierarchy");break;case"types":this._createTypesNodes();break;default:this._createContainmentNodes()}this._sortNodes&&this._doSortNodes(),this._synchNodesToEntities(),this.fire("nodeNodes_Created",this._nodeNodes),this.fire("rootNodes_Created",this._rootNodes),this.fire("objectNodes_Created",this._objectNodes)}},{key:"_createStoreysNodes",value:function(){var e=this._viewer.metaScene.rootMetaObjects;for(var t in e)this._createStoreysNodes2(e[t],null,null,null)}},{key:"_createStoreysNodes2",value:function(e,t,i,r){if(!this._pruneEmptyNodes||0!==e._countEntities){var n=e.type,s=e.name,o=e.children,a=e.id;if("IfcBuilding"===n)t={nodeId:"".concat(this._id,"-").concat(a),objectId:a,title:0===e.metaModels.length?"na":this._rootNames[e.metaModels[0].id]||(s&&""!==s&&"Undefined"!==s&&"Default"!==s?s:n),type:n,parent:null,numEntities:0,numVisibleEntities:0,checked:!1,xrayed:!1,children:[]},this._rootNodes.push(t),this._objectNodes[t.objectId]=t,this._nodeNodes[t.nodeId]=t;else if("IfcBuildingStorey"===n){if(!t)return void this.error("Failed to build storeys hierarchy for model '"+this.metaModel.id+"' - model does not have an IfcBuilding object, or is not an IFC model");i={nodeId:"".concat(this._id,"-").concat(a),objectId:a,title:s&&""!==s&&"Undefined"!==s&&"Default"!==s?s:n,type:n,parent:t,numEntities:0,numVisibleEntities:0,checked:!1,xrayed:!1,children:[]},t.children.push(i),this._objectNodes[i.objectId]=i,this._nodeNodes[i.nodeId]=i,r={}}else{if(i)if(this._viewer.scene.objects[a]){var l=(r=r||{})[n];l||(l={nodeId:"".concat(this._id,"-").concat(i.objectId,"-").concat(n),objectId:"".concat(i.objectId,"-").concat(n),title:n,type:n,parent:i,numEntities:0,numVisibleEntities:0,checked:!1,xrayed:!1,children:[]},i.children.push(l),this._objectNodes[l.objectId]=l,this._nodeNodes[l.nodeId]=l,r[n]=l);var u={nodeId:"".concat(this._id,"-").concat(a),objectId:a,title:s&&""!==s&&"Undefined"!==s&&"Default"!==s?s:n,type:n,parent:l,numEntities:0,numVisibleEntities:0,checked:!1,xrayed:!1,children:[]};l.children.push(u),this._objectNodes[u.objectId]=u,this._nodeNodes[u.nodeId]=u}}if(o)for(var c=0,h=o.length;c<h;c++){var A=o[c];this._createStoreysNodes2(A,t,i,r)}}}},{key:"_createTypesNodes",value:function(){var e=this._viewer.metaScene.rootMetaObjects;for(var t in e)this._createTypesNodes2(e[t],null,null)}},{key:"_createTypesNodes2",value:function(e,t,i){if(!this._pruneEmptyNodes||0!==e._countEntities){var r=e.type,n=e.name,s=e.children,o=e.id;if(e.parent){if(t)if(this._viewer.scene.objects[o]){var a=i[r];a||(a={nodeId:"".concat(this._id,"-").concat(t.objectId,"-").concat(r),objectId:"".concat(t.objectId,"-").concat(r),title:r,type:r,parent:t,numEntities:0,numVisibleEntities:0,checked:!1,xrayed:!1,children:[]},t.children.push(a),this._objectNodes[a.objectId]=a,this._nodeNodes[a.nodeId]=a,i[r]=a);var l={nodeId:"".concat(this._id,"-").concat(o),objectId:o,title:n&&""!==n&&"Default"!==n?n:r,type:r,parent:a,numEntities:0,numVisibleEntities:0,checked:!1,xrayed:!1,children:[]};a.children.push(l),this._objectNodes[l.objectId]=l,this._nodeNodes[l.nodeId]=l}}else t={nodeId:"".concat(this._id,"-").concat(o),objectId:o,title:0===e.metaModels.length?"na":this._rootNames[e.metaModels[0].id]||(n&&""!==n&&"Undefined"!==n&&"Default"!==n?n:r),type:r,parent:null,numEntities:0,numVisibleEntities:0,checked:!1,xrayed:!1,children:[]},this._rootNodes.push(t),this._objectNodes[t.objectId]=t,this._nodeNodes[t.nodeId]=t,i={};if(s)for(var u=0,c=s.length;u<c;u++){var h=s[u];this._createTypesNodes2(h,t,i)}}}},{key:"_createContainmentNodes",value:function(){var e=this._viewer.metaScene.rootMetaObjects;for(var t in e)this._createContainmentNodes2(e[t],null)}},{key:"_createContainmentNodes2",value:function(e,t){if(!this._pruneEmptyNodes||0!==e._countEntities){var i=e.type,r=e.name||i,n=e.children,s=e.id,o={nodeId:"".concat(this._id,"-").concat(s),objectId:s,title:t?r&&""!==r&&"Undefined"!==r&&"Default"!==r?r:i:0===e.metaModels.length?"na":this._rootNames[e.metaModels[0].id]||r,type:i,parent:t,numEntities:0,numVisibleEntities:0,checked:!1,xrayed:!1,children:[]};if(t?t.children.push(o):this._rootNodes.push(o),this._objectNodes[o.objectId]=o,this._nodeNodes[o.nodeId]=o,n)for(var a=0,l=n.length;a<l;a++){var u=n[a];this._createContainmentNodes2(u,o)}}}},{key:"_synchNodesToEntities",value:function(){for(var e=Object.keys(this.viewer.metaScene.metaObjects),t=this._viewer.metaScene.metaObjects,i=this._viewer.scene.objects,r=0,n=e.length;r<n;r++){var s=e[r];if(t[s]){var o=this._objectNodes[s];if(o){var a=i[s];if(a){var l=a.visible;o.numEntities=1,o.xrayed=a.xrayed,l?(o.numVisibleEntities=1,o.checked=!0):(o.numVisibleEntities=0,o.checked=!1);for(var u=o.parent;u;)u.numEntities++,l&&(u.numVisibleEntities++,u.checked=!0),u=u.parent}}}}}},{key:"_validate",value:function(){if(this.errors=[],"storeys"===this._hierarchy)this.valid=this._validateMetaModelForStoreysHierarchy();else this.valid=this._rootNodes.length>0;return this.valid}},{key:"_validateMetaModelForStoreysHierarchy",value:function(){return!0}},{key:"addModel",value:function(e){var t=this,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=this.viewer.scene.models[e];if(!r)throw"Model not found: "+e;var n=this.viewer.metaScene.metaModels[e];n?this._metaModels[e]?this._metaModels[e]=null:(this._metaModels[e]=n,i&&i.rootName&&(this._rootNames[e]=i.rootName),r.on("destroyed",function(){t.removeModel(r.id)}),this._createNodes()):this.error("MetaModel not found: "+e)}},{key:"removeModel",value:function(e){this._metaModels[e]&&(this._rootNames[e]&&delete this._rootNames[e],delete this._metaModels[e],this._createNodes())}},{key:"showNode",value:function(e){this.unShowNode();var t=this._objectNodes[e];if(t){for(var i=t.nodeId,r=t.parent;r;)r=r.parent;this._showListItemElementId=i}}},{key:"unShowNode",value:function(){this._showListItemElementId&&(this._showListItemElementId=null)}},{key:"withNodeTree",value:function(e,t){t(e);var i=e.children;if(i)for(var r=0,n=i.length;r<n;r++)this.withNodeTree(i[r],t)}},{key:"_withNodeTree",value:function(e,t){t(e);var i=e.children;if(i)for(var r=0,n=i.length;r<n;r++)this._withNodeTree(i[r],t)}},{key:"getChildrenById",value:function(e){return this._nodeNodes[e].children}},{key:"getNodeById",value:function(e){return this._nodeNodes[e]}},{key:"destroy",value:function(){this._metaModels={},this._rootElement&&!this._destroyed&&(this._rootElement.parentNode.removeChild(this._rootElement),this._viewer.scene.off(this._onObjectVisibility),this._destroyed=!0),delete wk[this._index],g(e,"destroy",this,3)([])}},{key:"_findEmptyNodes",value:function(){var e=this._viewer.metaScene.rootMetaObjects;for(var t in e)this._findEmptyNodes2(e[t])}},{key:"_findEmptyNodes2",value:function(e){var t=this.viewer.scene,i=e.children,r=e.id,n=t.objects[r];if(e._countEntities=0,n&&e._countEntities++,i)for(var s=0,o=i.length;s<o;s++){var a=i[s];a._countEntities=this._findEmptyNodes2(a),e._countEntities+=a._countEntities}return e._countEntities}},{key:"_doSortNodes",value:function(){for(var e=0,t=this._rootNodes.length;e<t;e++){var i=this._rootNodes[e];this._sortChildren(i)}}},{key:"_sortChildren",value:function(e){var t=e.children;if(t&&0!==t.length){"storeys"===this._hierarchy&&"IfcBuilding"===e.type?t.sort(this._getSpatialSortFunc()):t.sort(this._alphaSortFunc);for(var i=0,r=t.length;i<r;i++){var n=t[i];this._sortChildren(n)}}}},{key:"_getSpatialSortFunc",value:function(){var e=this.viewer,t=e.scene,i=t.camera,r=e.metaScene;return this._spatialSortFunc||(this._spatialSortFunc=function(e,n){e.aabb&&n.aabb||(e.aabb||(e.aabb=t.getAABB(r.getObjectIDsInSubtree(e.objectId))),n.aabb||(n.aabb=t.getAABB(r.getObjectIDsInSubtree(n.objectId))));var s=0;return s=i.xUp?0:i.yUp?1:2,e.aabb[s]>n.aabb[s]?-1:e.aabb[s]<n.aabb[s]?1:0})}},{key:"_alphaSortFunc",value:function(e,t){var i=e.title.toUpperCase(),r=t.title.toUpperCase();return i<r?-1:i>r?1:0}}])}(),Bk=function(){return P(function e(){x(this,e)},[{key:"getManifest",value:function(e,t,i){ne.loadJSON(e,function(e){t(e)},function(e){i(e)})}},{key:"getMetaModel",value:function(e,t,i){ne.loadJSON(e,function(e){t(e)},function(e){i(e)})}},{key:"getXTC",value:function(e,t,i){var r=function(){};t=t||r,i=i||r;var n=e.match(/^data:(.*?)(;base64)?,(.*)$/);if(n){var s=!!n[2],o=n[3];o=window.decodeURIComponent(o),s&&(o=window.atob(o));try{for(var a=new ArrayBuffer(o.length),l=new Uint8Array(a),u=0;u<o.length;u++)l[u]=o.charCodeAt(u);t(a)}catch(e){i(e)}}else{var c=new XMLHttpRequest;c.open("GET",e,!0),c.responseType="arraybuffer",c.onreadystatechange=function(){4===c.readyState&&(200===c.status?t(c.response):i("getXTC error : "+c.response))},c.send(null)}}}])}();!function(e,t){"object"==("undefined"==typeof exports?"undefined":w(exports))&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).pako={})}(void 0,function(e){function t(e){for(var t=e.length;--t>=0;)e[t]=0}var i=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]),r=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]),n=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7]),s=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),o=new Array(576);t(o);var a=new Array(60);t(a);var l=new Array(512);t(l);var u=new Array(256);t(u);var c=new Array(29);t(c);var h,A,d,p=new Array(30);function f(e,t,i,r,n){this.static_tree=e,this.extra_bits=t,this.extra_base=i,this.elems=r,this.max_length=n,this.has_stree=e&&e.length}function g(e,t){this.dyn_tree=e,this.max_code=0,this.stat_desc=t}t(p);var m=function(e){return e<256?l[e]:l[256+(e>>>7)]},v=function(e,t){e.pending_buf[e.pending++]=255&t,e.pending_buf[e.pending++]=t>>>8&255},_=function(e,t,i){e.bi_valid>16-i?(e.bi_buf|=t<<e.bi_valid&65535,v(e,e.bi_buf),e.bi_buf=t>>16-e.bi_valid,e.bi_valid+=i-16):(e.bi_buf|=t<<e.bi_valid&65535,e.bi_valid+=i)},y=function(e,t,i){_(e,i[2*t],i[2*t+1])},b=function(e,t){var i=0;do{i|=1&e,e>>>=1,i<<=1}while(--t>0);return i>>>1},x=function(e,t,i){var r,n,s=new Array(16),o=0;for(r=1;r<=15;r++)o=o+i[r-1]<<1,s[r]=o;for(n=0;n<=t;n++){var a=e[2*n+1];0!==a&&(e[2*n]=b(s[a]++,a))}},B=function(e){var t;for(t=0;t<286;t++)e.dyn_ltree[2*t]=0;for(t=0;t<30;t++)e.dyn_dtree[2*t]=0;for(t=0;t<19;t++)e.bl_tree[2*t]=0;e.dyn_ltree[512]=1,e.opt_len=e.static_len=0,e.sym_next=e.matches=0},P=function(e){e.bi_valid>8?v(e,e.bi_buf):e.bi_valid>0&&(e.pending_buf[e.pending++]=e.bi_buf),e.bi_buf=0,e.bi_valid=0},C=function(e,t,i,r){var n=2*t,s=2*i;return e[n]<e[s]||e[n]===e[s]&&r[t]<=r[i]},M=function(e,t,i){for(var r=e.heap[i],n=i<<1;n<=e.heap_len&&(n<e.heap_len&&C(t,e.heap[n+1],e.heap[n],e.depth)&&n++,!C(t,r,e.heap[n],e.depth));)e.heap[i]=e.heap[n],i=n,n<<=1;e.heap[i]=r},k=function(e,t,n){var s,o,a,l,h=0;if(0!==e.sym_next)do{s=255&e.pending_buf[e.sym_buf+h++],s+=(255&e.pending_buf[e.sym_buf+h++])<<8,o=e.pending_buf[e.sym_buf+h++],0===s?y(e,o,t):(a=u[o],y(e,a+256+1,t),0!==(l=i[a])&&(o-=c[a],_(e,o,l)),s--,a=m(s),y(e,a,n),0!==(l=r[a])&&(s-=p[a],_(e,s,l)))}while(h<e.sym_next);y(e,256,t)},E=function(e,t){var i,r,n,s=t.dyn_tree,o=t.stat_desc.static_tree,a=t.stat_desc.has_stree,l=t.stat_desc.elems,u=-1;for(e.heap_len=0,e.heap_max=573,i=0;i<l;i++)0!==s[2*i]?(e.heap[++e.heap_len]=u=i,e.depth[i]=0):s[2*i+1]=0;for(;e.heap_len<2;)s[2*(n=e.heap[++e.heap_len]=u<2?++u:0)]=1,e.depth[n]=0,e.opt_len--,a&&(e.static_len-=o[2*n+1]);for(t.max_code=u,i=e.heap_len>>1;i>=1;i--)M(e,s,i);n=l;do{i=e.heap[1],e.heap[1]=e.heap[e.heap_len--],M(e,s,1),r=e.heap[1],e.heap[--e.heap_max]=i,e.heap[--e.heap_max]=r,s[2*n]=s[2*i]+s[2*r],e.depth[n]=(e.depth[i]>=e.depth[r]?e.depth[i]:e.depth[r])+1,s[2*i+1]=s[2*r+1]=n,e.heap[1]=n++,M(e,s,1)}while(e.heap_len>=2);e.heap[--e.heap_max]=e.heap[1],function(e,t){var i,r,n,s,o,a,l=t.dyn_tree,u=t.max_code,c=t.stat_desc.static_tree,h=t.stat_desc.has_stree,A=t.stat_desc.extra_bits,d=t.stat_desc.extra_base,p=t.stat_desc.max_length,f=0;for(s=0;s<=15;s++)e.bl_count[s]=0;for(l[2*e.heap[e.heap_max]+1]=0,i=e.heap_max+1;i<573;i++)(s=l[2*l[2*(r=e.heap[i])+1]+1]+1)>p&&(s=p,f++),l[2*r+1]=s,r>u||(e.bl_count[s]++,o=0,r>=d&&(o=A[r-d]),a=l[2*r],e.opt_len+=a*(s+o),h&&(e.static_len+=a*(c[2*r+1]+o)));if(0!==f){do{for(s=p-1;0===e.bl_count[s];)s--;e.bl_count[s]--,e.bl_count[s+1]+=2,e.bl_count[p]--,f-=2}while(f>0);for(s=p;0!==s;s--)for(r=e.bl_count[s];0!==r;)(n=e.heap[--i])>u||(l[2*n+1]!==s&&(e.opt_len+=(s-l[2*n+1])*l[2*n],l[2*n+1]=s),r--)}}(e,t),x(s,u,e.bl_count)},S=function(e,t,i){var r,n,s=-1,o=t[1],a=0,l=7,u=4;for(0===o&&(l=138,u=3),t[2*(i+1)+1]=65535,r=0;r<=i;r++)n=o,o=t[2*(r+1)+1],++a<l&&n===o||(a<u?e.bl_tree[2*n]+=a:0!==n?(n!==s&&e.bl_tree[2*n]++,e.bl_tree[32]++):a<=10?e.bl_tree[34]++:e.bl_tree[36]++,a=0,s=n,0===o?(l=138,u=3):n===o?(l=6,u=3):(l=7,u=4))},T=function(e,t,i){var r,n,s=-1,o=t[1],a=0,l=7,u=4;for(0===o&&(l=138,u=3),r=0;r<=i;r++)if(n=o,o=t[2*(r+1)+1],!(++a<l&&n===o)){if(a<u)do{y(e,n,e.bl_tree)}while(0!=--a);else 0!==n?(n!==s&&(y(e,n,e.bl_tree),a--),y(e,16,e.bl_tree),_(e,a-3,2)):a<=10?(y(e,17,e.bl_tree),_(e,a-3,3)):(y(e,18,e.bl_tree),_(e,a-11,7));a=0,s=n,0===o?(l=138,u=3):n===o?(l=6,u=3):(l=7,u=4)}},I=!1,F=function(e,t,i,r){_(e,0+(r?1:0),3),P(e),v(e,i),v(e,~i),i&&e.pending_buf.set(e.window.subarray(t,t+i),e.pending),e.pending+=i},D=function(e){I||(function(){var e,t,s,g,m,v=new Array(16);for(s=0,g=0;g<28;g++)for(c[g]=s,e=0;e<1<<i[g];e++)u[s++]=g;for(u[s-1]=g,m=0,g=0;g<16;g++)for(p[g]=m,e=0;e<1<<r[g];e++)l[m++]=g;for(m>>=7;g<30;g++)for(p[g]=m<<7,e=0;e<1<<r[g]-7;e++)l[256+m++]=g;for(t=0;t<=15;t++)v[t]=0;for(e=0;e<=143;)o[2*e+1]=8,e++,v[8]++;for(;e<=255;)o[2*e+1]=9,e++,v[9]++;for(;e<=279;)o[2*e+1]=7,e++,v[7]++;for(;e<=287;)o[2*e+1]=8,e++,v[8]++;for(x(o,287,v),e=0;e<30;e++)a[2*e+1]=5,a[2*e]=b(e,5);h=new f(o,i,257,286,15),A=new f(a,r,0,30,15),d=new f(new Array(0),n,0,19,7)}(),I=!0),e.l_desc=new g(e.dyn_ltree,h),e.d_desc=new g(e.dyn_dtree,A),e.bl_desc=new g(e.bl_tree,d),e.bi_buf=0,e.bi_valid=0,B(e)},R=F,O=function(e,t,i,r){var n,l,u=0;e.level>0?(2===e.strm.data_type&&(e.strm.data_type=function(e){var t,i=4093624447;for(t=0;t<=31;t++,i>>>=1)if(1&i&&0!==e.dyn_ltree[2*t])return 0;if(0!==e.dyn_ltree[18]||0!==e.dyn_ltree[20]||0!==e.dyn_ltree[26])return 1;for(t=32;t<256;t++)if(0!==e.dyn_ltree[2*t])return 1;return 0}(e)),E(e,e.l_desc),E(e,e.d_desc),u=function(e){var t;for(S(e,e.dyn_ltree,e.l_desc.max_code),S(e,e.dyn_dtree,e.d_desc.max_code),E(e,e.bl_desc),t=18;t>=3&&0===e.bl_tree[2*s[t]+1];t--);return e.opt_len+=3*(t+1)+5+5+4,t}(e),n=e.opt_len+3+7>>>3,(l=e.static_len+3+7>>>3)<=n&&(n=l)):n=l=i+5,i+4<=n&&-1!==t?F(e,t,i,r):4===e.strategy||l===n?(_(e,2+(r?1:0),3),k(e,o,a)):(_(e,4+(r?1:0),3),function(e,t,i,r){var n;for(_(e,t-257,5),_(e,i-1,5),_(e,r-4,4),n=0;n<r;n++)_(e,e.bl_tree[2*s[n]+1],3);T(e,e.dyn_ltree,t-1),T(e,e.dyn_dtree,i-1)}(e,e.l_desc.max_code+1,e.d_desc.max_code+1,u+1),k(e,e.dyn_ltree,e.dyn_dtree)),B(e),r&&P(e)},L=function(e,t,i){return e.pending_buf[e.sym_buf+e.sym_next++]=t,e.pending_buf[e.sym_buf+e.sym_next++]=t>>8,e.pending_buf[e.sym_buf+e.sym_next++]=i,0===t?e.dyn_ltree[2*i]++:(e.matches++,t--,e.dyn_ltree[2*(u[i]+256+1)]++,e.dyn_dtree[2*m(t)]++),e.sym_next===e.sym_end},j=function(e){_(e,2,3),y(e,256,o),function(e){16===e.bi_valid?(v(e,e.bi_buf),e.bi_buf=0,e.bi_valid=0):e.bi_valid>=8&&(e.pending_buf[e.pending++]=255&e.bi_buf,e.bi_buf>>=8,e.bi_valid-=8)}(e)},U=function(e,t,i,r){for(var n=65535&e,s=e>>>16&65535,o=0;0!==i;){i-=o=i>2e3?2e3:i;do{s=s+(n=n+t[r++]|0)|0}while(--o);n%=65521,s%=65521}return n|s<<16},N=new Uint32Array(function(){for(var e,t=[],i=0;i<256;i++){e=i;for(var r=0;r<8;r++)e=1&e?3988292384^e>>>1:e>>>1;t[i]=e}return t}()),V=function(e,t,i,r){var n=N,s=r+i;e^=-1;for(var o=r;o<s;o++)e=e>>>8^n[255&(e^t[o])];return-1^e},Q={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"},H={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},G=D,z=R,W=O,K=L,X=j,q=H.Z_NO_FLUSH,Y=H.Z_PARTIAL_FLUSH,J=H.Z_FULL_FLUSH,Z=H.Z_FINISH,$=H.Z_BLOCK,ee=H.Z_OK,te=H.Z_STREAM_END,ie=H.Z_STREAM_ERROR,re=H.Z_DATA_ERROR,ne=H.Z_BUF_ERROR,se=H.Z_DEFAULT_COMPRESSION,oe=H.Z_FILTERED,ae=H.Z_HUFFMAN_ONLY,le=H.Z_RLE,ue=H.Z_FIXED,ce=H.Z_UNKNOWN,he=H.Z_DEFLATED,Ae=258,de=262,pe=42,fe=113,ge=666,me=function(e,t){return e.msg=Q[t],t},ve=function(e){return 2*e-(e>4?9:0)},_e=function(e){for(var t=e.length;--t>=0;)e[t]=0},ye=function(e){var t,i,r,n=e.w_size;r=t=e.hash_size;do{i=e.head[--r],e.head[r]=i>=n?i-n:0}while(--t);r=t=n;do{i=e.prev[--r],e.prev[r]=i>=n?i-n:0}while(--t)},be=function(e,t,i){return(t<<e.hash_shift^i)&e.hash_mask},we=function(e){var t=e.state,i=t.pending;i>e.avail_out&&(i=e.avail_out),0!==i&&(e.output.set(t.pending_buf.subarray(t.pending_out,t.pending_out+i),e.next_out),e.next_out+=i,t.pending_out+=i,e.total_out+=i,e.avail_out-=i,t.pending-=i,0===t.pending&&(t.pending_out=0))},xe=function(e,t){W(e,e.block_start>=0?e.block_start:-1,e.strstart-e.block_start,t),e.block_start=e.strstart,we(e.strm)},Be=function(e,t){e.pending_buf[e.pending++]=t},Pe=function(e,t){e.pending_buf[e.pending++]=t>>>8&255,e.pending_buf[e.pending++]=255&t},Ce=function(e,t,i,r){var n=e.avail_in;return n>r&&(n=r),0===n?0:(e.avail_in-=n,t.set(e.input.subarray(e.next_in,e.next_in+n),i),1===e.state.wrap?e.adler=U(e.adler,t,n,i):2===e.state.wrap&&(e.adler=V(e.adler,t,n,i)),e.next_in+=n,e.total_in+=n,n)},Me=function(e,t){var i,r,n=e.max_chain_length,s=e.strstart,o=e.prev_length,a=e.nice_match,l=e.strstart>e.w_size-de?e.strstart-(e.w_size-de):0,u=e.window,c=e.w_mask,h=e.prev,A=e.strstart+Ae,d=u[s+o-1],p=u[s+o];e.prev_length>=e.good_match&&(n>>=2),a>e.lookahead&&(a=e.lookahead);do{if(u[(i=t)+o]===p&&u[i+o-1]===d&&u[i]===u[s]&&u[++i]===u[s+1]){s+=2,i++;do{}while(u[++s]===u[++i]&&u[++s]===u[++i]&&u[++s]===u[++i]&&u[++s]===u[++i]&&u[++s]===u[++i]&&u[++s]===u[++i]&&u[++s]===u[++i]&&u[++s]===u[++i]&&s<A);if(r=Ae-(A-s),s=A-Ae,r>o){if(e.match_start=t,o=r,r>=a)break;d=u[s+o-1],p=u[s+o]}}}while((t=h[t&c])>l&&0!=--n);return o<=e.lookahead?o:e.lookahead},ke=function(e){var t,i,r,n=e.w_size;do{if(i=e.window_size-e.lookahead-e.strstart,e.strstart>=n+(n-de)&&(e.window.set(e.window.subarray(n,n+n-i),0),e.match_start-=n,e.strstart-=n,e.block_start-=n,e.insert>e.strstart&&(e.insert=e.strstart),ye(e),i+=n),0===e.strm.avail_in)break;if(t=Ce(e.strm,e.window,e.strstart+e.lookahead,i),e.lookahead+=t,e.lookahead+e.insert>=3)for(r=e.strstart-e.insert,e.ins_h=e.window[r],e.ins_h=be(e,e.ins_h,e.window[r+1]);e.insert&&(e.ins_h=be(e,e.ins_h,e.window[r+3-1]),e.prev[r&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=r,r++,e.insert--,!(e.lookahead+e.insert<3)););}while(e.lookahead<de&&0!==e.strm.avail_in)},Ee=function(e,t){var i,r,n,s=e.pending_buf_size-5>e.w_size?e.w_size:e.pending_buf_size-5,o=0,a=e.strm.avail_in;do{if(i=65535,n=e.bi_valid+42>>3,e.strm.avail_out<n)break;if(n=e.strm.avail_out-n,i>(r=e.strstart-e.block_start)+e.strm.avail_in&&(i=r+e.strm.avail_in),i>n&&(i=n),i<s&&(0===i&&t!==Z||t===q||i!==r+e.strm.avail_in))break;o=t===Z&&i===r+e.strm.avail_in?1:0,z(e,0,0,o),e.pending_buf[e.pending-4]=i,e.pending_buf[e.pending-3]=i>>8,e.pending_buf[e.pending-2]=~i,e.pending_buf[e.pending-1]=~i>>8,we(e.strm),r&&(r>i&&(r=i),e.strm.output.set(e.window.subarray(e.block_start,e.block_start+r),e.strm.next_out),e.strm.next_out+=r,e.strm.avail_out-=r,e.strm.total_out+=r,e.block_start+=r,i-=r),i&&(Ce(e.strm,e.strm.output,e.strm.next_out,i),e.strm.next_out+=i,e.strm.avail_out-=i,e.strm.total_out+=i)}while(0===o);return(a-=e.strm.avail_in)&&(a>=e.w_size?(e.matches=2,e.window.set(e.strm.input.subarray(e.strm.next_in-e.w_size,e.strm.next_in),0),e.strstart=e.w_size,e.insert=e.strstart):(e.window_size-e.strstart<=a&&(e.strstart-=e.w_size,e.window.set(e.window.subarray(e.w_size,e.w_size+e.strstart),0),e.matches<2&&e.matches++,e.insert>e.strstart&&(e.insert=e.strstart)),e.window.set(e.strm.input.subarray(e.strm.next_in-a,e.strm.next_in),e.strstart),e.strstart+=a,e.insert+=a>e.w_size-e.insert?e.w_size-e.insert:a),e.block_start=e.strstart),e.high_water<e.strstart&&(e.high_water=e.strstart),o?4:t!==q&&t!==Z&&0===e.strm.avail_in&&e.strstart===e.block_start?2:(n=e.window_size-e.strstart,e.strm.avail_in>n&&e.block_start>=e.w_size&&(e.block_start-=e.w_size,e.strstart-=e.w_size,e.window.set(e.window.subarray(e.w_size,e.w_size+e.strstart),0),e.matches<2&&e.matches++,n+=e.w_size,e.insert>e.strstart&&(e.insert=e.strstart)),n>e.strm.avail_in&&(n=e.strm.avail_in),n&&(Ce(e.strm,e.window,e.strstart,n),e.strstart+=n,e.insert+=n>e.w_size-e.insert?e.w_size-e.insert:n),e.high_water<e.strstart&&(e.high_water=e.strstart),n=e.bi_valid+42>>3,s=(n=e.pending_buf_size-n>65535?65535:e.pending_buf_size-n)>e.w_size?e.w_size:n,((r=e.strstart-e.block_start)>=s||(r||t===Z)&&t!==q&&0===e.strm.avail_in&&r<=n)&&(i=r>n?n:r,o=t===Z&&0===e.strm.avail_in&&i===r?1:0,z(e,e.block_start,i,o),e.block_start+=i,we(e.strm)),o?3:1)},Se=function(e,t){for(var i,r;;){if(e.lookahead<de){if(ke(e),e.lookahead<de&&t===q)return 1;if(0===e.lookahead)break}if(i=0,e.lookahead>=3&&(e.ins_h=be(e,e.ins_h,e.window[e.strstart+3-1]),i=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),0!==i&&e.strstart-i<=e.w_size-de&&(e.match_length=Me(e,i)),e.match_length>=3)if(r=K(e,e.strstart-e.match_start,e.match_length-3),e.lookahead-=e.match_length,e.match_length<=e.max_lazy_match&&e.lookahead>=3){e.match_length--;do{e.strstart++,e.ins_h=be(e,e.ins_h,e.window[e.strstart+3-1]),i=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart}while(0!=--e.match_length);e.strstart++}else e.strstart+=e.match_length,e.match_length=0,e.ins_h=e.window[e.strstart],e.ins_h=be(e,e.ins_h,e.window[e.strstart+1]);else r=K(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++;if(r&&(xe(e,!1),0===e.strm.avail_out))return 1}return e.insert=e.strstart<2?e.strstart:2,t===Z?(xe(e,!0),0===e.strm.avail_out?3:4):e.sym_next&&(xe(e,!1),0===e.strm.avail_out)?1:2},Te=function(e,t){for(var i,r,n;;){if(e.lookahead<de){if(ke(e),e.lookahead<de&&t===q)return 1;if(0===e.lookahead)break}if(i=0,e.lookahead>=3&&(e.ins_h=be(e,e.ins_h,e.window[e.strstart+3-1]),i=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),e.prev_length=e.match_length,e.prev_match=e.match_start,e.match_length=2,0!==i&&e.prev_length<e.max_lazy_match&&e.strstart-i<=e.w_size-de&&(e.match_length=Me(e,i),e.match_length<=5&&(e.strategy===oe||3===e.match_length&&e.strstart-e.match_start>4096)&&(e.match_length=2)),e.prev_length>=3&&e.match_length<=e.prev_length){n=e.strstart+e.lookahead-3,r=K(e,e.strstart-1-e.prev_match,e.prev_length-3),e.lookahead-=e.prev_length-1,e.prev_length-=2;do{++e.strstart<=n&&(e.ins_h=be(e,e.ins_h,e.window[e.strstart+3-1]),i=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart)}while(0!=--e.prev_length);if(e.match_available=0,e.match_length=2,e.strstart++,r&&(xe(e,!1),0===e.strm.avail_out))return 1}else if(e.match_available){if((r=K(e,0,e.window[e.strstart-1]))&&xe(e,!1),e.strstart++,e.lookahead--,0===e.strm.avail_out)return 1}else e.match_available=1,e.strstart++,e.lookahead--}return e.match_available&&(r=K(e,0,e.window[e.strstart-1]),e.match_available=0),e.insert=e.strstart<2?e.strstart:2,t===Z?(xe(e,!0),0===e.strm.avail_out?3:4):e.sym_next&&(xe(e,!1),0===e.strm.avail_out)?1:2};function Ie(e,t,i,r,n){this.good_length=e,this.max_lazy=t,this.nice_length=i,this.max_chain=r,this.func=n}var Fe=[new Ie(0,0,0,0,Ee),new Ie(4,4,8,4,Se),new Ie(4,5,16,8,Se),new Ie(4,6,32,32,Se),new Ie(4,4,16,16,Te),new Ie(8,16,32,32,Te),new Ie(8,16,128,128,Te),new Ie(8,32,128,256,Te),new Ie(32,128,258,1024,Te),new Ie(32,258,258,4096,Te)];function De(){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=he,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),_e(this.dyn_ltree),_e(this.dyn_dtree),_e(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),_e(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new Uint16Array(573),_e(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}var Re=function(e){if(!e)return 1;var t=e.state;return!t||t.strm!==e||t.status!==pe&&57!==t.status&&69!==t.status&&73!==t.status&&91!==t.status&&103!==t.status&&t.status!==fe&&t.status!==ge?1:0},Oe=function(e){if(Re(e))return me(e,ie);e.total_in=e.total_out=0,e.data_type=ce;var t=e.state;return t.pending=0,t.pending_out=0,t.wrap<0&&(t.wrap=-t.wrap),t.status=2===t.wrap?57:t.wrap?pe:fe,e.adler=2===t.wrap?0:1,t.last_flush=-2,G(t),ee},Le=function(e){var t,i=Oe(e);return i===ee&&((t=e.state).window_size=2*t.w_size,_e(t.head),t.max_lazy_match=Fe[t.level].max_lazy,t.good_match=Fe[t.level].good_length,t.nice_match=Fe[t.level].nice_length,t.max_chain_length=Fe[t.level].max_chain,t.strstart=0,t.block_start=0,t.lookahead=0,t.insert=0,t.match_length=t.prev_length=2,t.match_available=0,t.ins_h=0),i},je=function(e,t,i,r,n,s){if(!e)return ie;var o=1;if(t===se&&(t=6),r<0?(o=0,r=-r):r>15&&(o=2,r-=16),n<1||n>9||i!==he||r<8||r>15||t<0||t>9||s<0||s>ue||8===r&&1!==o)return me(e,ie);8===r&&(r=9);var a=new De;return e.state=a,a.strm=e,a.status=pe,a.wrap=o,a.gzhead=null,a.w_bits=r,a.w_size=1<<a.w_bits,a.w_mask=a.w_size-1,a.hash_bits=n+7,a.hash_size=1<<a.hash_bits,a.hash_mask=a.hash_size-1,a.hash_shift=~~((a.hash_bits+3-1)/3),a.window=new Uint8Array(2*a.w_size),a.head=new Uint16Array(a.hash_size),a.prev=new Uint16Array(a.w_size),a.lit_bufsize=1<<n+6,a.pending_buf_size=4*a.lit_bufsize,a.pending_buf=new Uint8Array(a.pending_buf_size),a.sym_buf=a.lit_bufsize,a.sym_end=3*(a.lit_bufsize-1),a.level=t,a.strategy=s,a.method=i,Le(e)},Ue=je,Ne=function(e,t){return Re(e)||2!==e.state.wrap?ie:(e.state.gzhead=t,ee)},Ve=function(e,t){if(Re(e)||t>$||t<0)return e?me(e,ie):ie;var i=e.state;if(!e.output||0!==e.avail_in&&!e.input||i.status===ge&&t!==Z)return me(e,0===e.avail_out?ne:ie);var r=i.last_flush;if(i.last_flush=t,0!==i.pending){if(we(e),0===e.avail_out)return i.last_flush=-1,ee}else if(0===e.avail_in&&ve(t)<=ve(r)&&t!==Z)return me(e,ne);if(i.status===ge&&0!==e.avail_in)return me(e,ne);if(i.status===pe&&0===i.wrap&&(i.status=fe),i.status===pe){var n=he+(i.w_bits-8<<4)<<8;if(n|=(i.strategy>=ae||i.level<2?0:i.level<6?1:6===i.level?2:3)<<6,0!==i.strstart&&(n|=32),Pe(i,n+=31-n%31),0!==i.strstart&&(Pe(i,e.adler>>>16),Pe(i,65535&e.adler)),e.adler=1,i.status=fe,we(e),0!==i.pending)return i.last_flush=-1,ee}if(57===i.status)if(e.adler=0,Be(i,31),Be(i,139),Be(i,8),i.gzhead)Be(i,(i.gzhead.text?1:0)+(i.gzhead.hcrc?2:0)+(i.gzhead.extra?4:0)+(i.gzhead.name?8:0)+(i.gzhead.comment?16:0)),Be(i,255&i.gzhead.time),Be(i,i.gzhead.time>>8&255),Be(i,i.gzhead.time>>16&255),Be(i,i.gzhead.time>>24&255),Be(i,9===i.level?2:i.strategy>=ae||i.level<2?4:0),Be(i,255&i.gzhead.os),i.gzhead.extra&&i.gzhead.extra.length&&(Be(i,255&i.gzhead.extra.length),Be(i,i.gzhead.extra.length>>8&255)),i.gzhead.hcrc&&(e.adler=V(e.adler,i.pending_buf,i.pending,0)),i.gzindex=0,i.status=69;else if(Be(i,0),Be(i,0),Be(i,0),Be(i,0),Be(i,0),Be(i,9===i.level?2:i.strategy>=ae||i.level<2?4:0),Be(i,3),i.status=fe,we(e),0!==i.pending)return i.last_flush=-1,ee;if(69===i.status){if(i.gzhead.extra){for(var s=i.pending,o=(65535&i.gzhead.extra.length)-i.gzindex;i.pending+o>i.pending_buf_size;){var a=i.pending_buf_size-i.pending;if(i.pending_buf.set(i.gzhead.extra.subarray(i.gzindex,i.gzindex+a),i.pending),i.pending=i.pending_buf_size,i.gzhead.hcrc&&i.pending>s&&(e.adler=V(e.adler,i.pending_buf,i.pending-s,s)),i.gzindex+=a,we(e),0!==i.pending)return i.last_flush=-1,ee;s=0,o-=a}var l=new Uint8Array(i.gzhead.extra);i.pending_buf.set(l.subarray(i.gzindex,i.gzindex+o),i.pending),i.pending+=o,i.gzhead.hcrc&&i.pending>s&&(e.adler=V(e.adler,i.pending_buf,i.pending-s,s)),i.gzindex=0}i.status=73}if(73===i.status){if(i.gzhead.name){var u,c=i.pending;do{if(i.pending===i.pending_buf_size){if(i.gzhead.hcrc&&i.pending>c&&(e.adler=V(e.adler,i.pending_buf,i.pending-c,c)),we(e),0!==i.pending)return i.last_flush=-1,ee;c=0}u=i.gzindex<i.gzhead.name.length?255&i.gzhead.name.charCodeAt(i.gzindex++):0,Be(i,u)}while(0!==u);i.gzhead.hcrc&&i.pending>c&&(e.adler=V(e.adler,i.pending_buf,i.pending-c,c)),i.gzindex=0}i.status=91}if(91===i.status){if(i.gzhead.comment){var h,A=i.pending;do{if(i.pending===i.pending_buf_size){if(i.gzhead.hcrc&&i.pending>A&&(e.adler=V(e.adler,i.pending_buf,i.pending-A,A)),we(e),0!==i.pending)return i.last_flush=-1,ee;A=0}h=i.gzindex<i.gzhead.comment.length?255&i.gzhead.comment.charCodeAt(i.gzindex++):0,Be(i,h)}while(0!==h);i.gzhead.hcrc&&i.pending>A&&(e.adler=V(e.adler,i.pending_buf,i.pending-A,A))}i.status=103}if(103===i.status){if(i.gzhead.hcrc){if(i.pending+2>i.pending_buf_size&&(we(e),0!==i.pending))return i.last_flush=-1,ee;Be(i,255&e.adler),Be(i,e.adler>>8&255),e.adler=0}if(i.status=fe,we(e),0!==i.pending)return i.last_flush=-1,ee}if(0!==e.avail_in||0!==i.lookahead||t!==q&&i.status!==ge){var d=0===i.level?Ee(i,t):i.strategy===ae?function(e,t){for(var i;;){if(0===e.lookahead&&(ke(e),0===e.lookahead)){if(t===q)return 1;break}if(e.match_length=0,i=K(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++,i&&(xe(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,t===Z?(xe(e,!0),0===e.strm.avail_out?3:4):e.sym_next&&(xe(e,!1),0===e.strm.avail_out)?1:2}(i,t):i.strategy===le?function(e,t){for(var i,r,n,s,o=e.window;;){if(e.lookahead<=Ae){if(ke(e),e.lookahead<=Ae&&t===q)return 1;if(0===e.lookahead)break}if(e.match_length=0,e.lookahead>=3&&e.strstart>0&&((r=o[n=e.strstart-1])===o[++n]&&r===o[++n]&&r===o[++n])){s=e.strstart+Ae;do{}while(r===o[++n]&&r===o[++n]&&r===o[++n]&&r===o[++n]&&r===o[++n]&&r===o[++n]&&r===o[++n]&&r===o[++n]&&n<s);e.match_length=Ae-(s-n),e.match_length>e.lookahead&&(e.match_length=e.lookahead)}if(e.match_length>=3?(i=K(e,1,e.match_length-3),e.lookahead-=e.match_length,e.strstart+=e.match_length,e.match_length=0):(i=K(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++),i&&(xe(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,t===Z?(xe(e,!0),0===e.strm.avail_out?3:4):e.sym_next&&(xe(e,!1),0===e.strm.avail_out)?1:2}(i,t):Fe[i.level].func(i,t);if(3!==d&&4!==d||(i.status=ge),1===d||3===d)return 0===e.avail_out&&(i.last_flush=-1),ee;if(2===d&&(t===Y?X(i):t!==$&&(z(i,0,0,!1),t===J&&(_e(i.head),0===i.lookahead&&(i.strstart=0,i.block_start=0,i.insert=0))),we(e),0===e.avail_out))return i.last_flush=-1,ee}return t!==Z?ee:i.wrap<=0?te:(2===i.wrap?(Be(i,255&e.adler),Be(i,e.adler>>8&255),Be(i,e.adler>>16&255),Be(i,e.adler>>24&255),Be(i,255&e.total_in),Be(i,e.total_in>>8&255),Be(i,e.total_in>>16&255),Be(i,e.total_in>>24&255)):(Pe(i,e.adler>>>16),Pe(i,65535&e.adler)),we(e),i.wrap>0&&(i.wrap=-i.wrap),0!==i.pending?ee:te)},Qe=function(e){if(Re(e))return ie;var t=e.state.status;return e.state=null,t===fe?me(e,re):ee},He=function(e,t){var i=t.length;if(Re(e))return ie;var r=e.state,n=r.wrap;if(2===n||1===n&&r.status!==pe||r.lookahead)return ie;if(1===n&&(e.adler=U(e.adler,t,i,0)),r.wrap=0,i>=r.w_size){0===n&&(_e(r.head),r.strstart=0,r.block_start=0,r.insert=0);var s=new Uint8Array(r.w_size);s.set(t.subarray(i-r.w_size,i),0),t=s,i=r.w_size}var o=e.avail_in,a=e.next_in,l=e.input;for(e.avail_in=i,e.next_in=0,e.input=t,ke(r);r.lookahead>=3;){var u=r.strstart,c=r.lookahead-2;do{r.ins_h=be(r,r.ins_h,r.window[u+3-1]),r.prev[u&r.w_mask]=r.head[r.ins_h],r.head[r.ins_h]=u,u++}while(--c);r.strstart=u,r.lookahead=2,ke(r)}return r.strstart+=r.lookahead,r.block_start=r.strstart,r.insert=r.lookahead,r.lookahead=0,r.match_length=r.prev_length=2,r.match_available=0,e.next_in=a,e.input=l,e.avail_in=o,r.wrap=n,ee},Ge=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},ze=function(e){for(var t=Array.prototype.slice.call(arguments,1);t.length;){var i=t.shift();if(i){if("object"!=w(i))throw new TypeError(i+"must be non-object");for(var r in i)Ge(i,r)&&(e[r]=i[r])}}return e},We=function(e){for(var t=0,i=0,r=e.length;i<r;i++)t+=e[i].length;for(var n=new Uint8Array(t),s=0,o=0,a=e.length;s<a;s++){var l=e[s];n.set(l,o),o+=l.length}return n},Ke=!0;try{String.fromCharCode.apply(null,new Uint8Array(1))}catch(e){Ke=!1}for(var Xe=new Uint8Array(256),qe=0;qe<256;qe++)Xe[qe]=qe>=252?6:qe>=248?5:qe>=240?4:qe>=224?3:qe>=192?2:1;Xe[254]=Xe[254]=1;var Ye=function(e){if("function"==typeof TextEncoder&&TextEncoder.prototype.encode)return(new TextEncoder).encode(e);var t,i,r,n,s,o=e.length,a=0;for(n=0;n<o;n++)55296==(64512&(i=e.charCodeAt(n)))&&n+1<o&&(56320==(64512&(r=e.charCodeAt(n+1)))&&(i=65536+(i-55296<<10)+(r-56320),n++)),a+=i<128?1:i<2048?2:i<65536?3:4;for(t=new Uint8Array(a),s=0,n=0;s<a;n++)55296==(64512&(i=e.charCodeAt(n)))&&n+1<o&&(56320==(64512&(r=e.charCodeAt(n+1)))&&(i=65536+(i-55296<<10)+(r-56320),n++)),i<128?t[s++]=i:i<2048?(t[s++]=192|i>>>6,t[s++]=128|63&i):i<65536?(t[s++]=224|i>>>12,t[s++]=128|i>>>6&63,t[s++]=128|63&i):(t[s++]=240|i>>>18,t[s++]=128|i>>>12&63,t[s++]=128|i>>>6&63,t[s++]=128|63&i);return t},Je=function(e,t){var i,r,n=t||e.length;if("function"==typeof TextDecoder&&TextDecoder.prototype.decode)return(new TextDecoder).decode(e.subarray(0,t));var s=new Array(2*n);for(r=0,i=0;i<n;){var o=e[i++];if(o<128)s[r++]=o;else{var a=Xe[o];if(a>4)s[r++]=65533,i+=a-1;else{for(o&=2===a?31:3===a?15:7;a>1&&i<n;)o=o<<6|63&e[i++],a--;a>1?s[r++]=65533:o<65536?s[r++]=o:(o-=65536,s[r++]=55296|o>>10&1023,s[r++]=56320|1023&o)}}}return function(e,t){if(t<65534&&e.subarray&&Ke)return String.fromCharCode.apply(null,e.length===t?e:e.subarray(0,t));for(var i="",r=0;r<t;r++)i+=String.fromCharCode(e[r]);return i}(s,r)},Ze=function(e,t){(t=t||e.length)>e.length&&(t=e.length);for(var i=t-1;i>=0&&128==(192&e[i]);)i--;return i<0||0===i?t:i+Xe[e[i]]>t?i:t},$e=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},et=Object.prototype.toString,tt=H.Z_NO_FLUSH,it=H.Z_SYNC_FLUSH,rt=H.Z_FULL_FLUSH,nt=H.Z_FINISH,st=H.Z_OK,ot=H.Z_STREAM_END,at=H.Z_DEFAULT_COMPRESSION,lt=H.Z_DEFAULT_STRATEGY,ut=H.Z_DEFLATED;function ct(e){this.options=ze({level:at,method:ut,chunkSize:16384,windowBits:15,memLevel:8,strategy:lt},e||{});var t=this.options;t.raw&&t.windowBits>0?t.windowBits=-t.windowBits:t.gzip&&t.windowBits>0&&t.windowBits<16&&(t.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new $e,this.strm.avail_out=0;var i=Ue(this.strm,t.level,t.method,t.windowBits,t.memLevel,t.strategy);if(i!==st)throw new Error(Q[i]);if(t.header&&Ne(this.strm,t.header),t.dictionary){var r;if(r="string"==typeof t.dictionary?Ye(t.dictionary):"[object ArrayBuffer]"===et.call(t.dictionary)?new Uint8Array(t.dictionary):t.dictionary,(i=He(this.strm,r))!==st)throw new Error(Q[i]);this._dict_set=!0}}function ht(e,t){var i=new ct(t);if(i.push(e,!0),i.err)throw i.msg||Q[i.err];return i.result}ct.prototype.push=function(e,t){var i,r,n=this.strm,s=this.options.chunkSize;if(this.ended)return!1;for(r=t===~~t?t:!0===t?nt:tt,"string"==typeof e?n.input=Ye(e):"[object ArrayBuffer]"===et.call(e)?n.input=new Uint8Array(e):n.input=e,n.next_in=0,n.avail_in=n.input.length;;)if(0===n.avail_out&&(n.output=new Uint8Array(s),n.next_out=0,n.avail_out=s),(r===it||r===rt)&&n.avail_out<=6)this.onData(n.output.subarray(0,n.next_out)),n.avail_out=0;else{if((i=Ve(n,r))===ot)return n.next_out>0&&this.onData(n.output.subarray(0,n.next_out)),i=Qe(this.strm),this.onEnd(i),this.ended=!0,i===st;if(0!==n.avail_out){if(r>0&&n.next_out>0)this.onData(n.output.subarray(0,n.next_out)),n.avail_out=0;else if(0===n.avail_in)break}else this.onData(n.output)}return!0},ct.prototype.onData=function(e){this.chunks.push(e)},ct.prototype.onEnd=function(e){e===st&&(this.result=We(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg};var At=ct,dt=ht,pt=function(e,t){return(t=t||{}).raw=!0,ht(e,t)},ft=function(e,t){return(t=t||{}).gzip=!0,ht(e,t)},gt=16209,mt=function(e,t){var i,r,n,s,o,a,l,u,c,h,A,d,p,f,g,m,v,_,y,b,w,x,B,P,C=e.state;i=e.next_in,B=e.input,r=i+(e.avail_in-5),n=e.next_out,P=e.output,s=n-(t-e.avail_out),o=n+(e.avail_out-257),a=C.dmax,l=C.wsize,u=C.whave,c=C.wnext,h=C.window,A=C.hold,d=C.bits,p=C.lencode,f=C.distcode,g=(1<<C.lenbits)-1,m=(1<<C.distbits)-1;e:do{d<15&&(A+=B[i++]<<d,d+=8,A+=B[i++]<<d,d+=8),v=p[A&g];t:for(;;){if(A>>>=_=v>>>24,d-=_,0===(_=v>>>16&255))P[n++]=65535&v;else{if(!(16&_)){if(!(64&_)){v=p[(65535&v)+(A&(1<<_)-1)];continue t}if(32&_){C.mode=16191;break e}e.msg="invalid literal/length code",C.mode=gt;break e}y=65535&v,(_&=15)&&(d<_&&(A+=B[i++]<<d,d+=8),y+=A&(1<<_)-1,A>>>=_,d-=_),d<15&&(A+=B[i++]<<d,d+=8,A+=B[i++]<<d,d+=8),v=f[A&m];i:for(;;){if(A>>>=_=v>>>24,d-=_,!(16&(_=v>>>16&255))){if(!(64&_)){v=f[(65535&v)+(A&(1<<_)-1)];continue i}e.msg="invalid distance code",C.mode=gt;break e}if(b=65535&v,d<(_&=15)&&(A+=B[i++]<<d,(d+=8)<_&&(A+=B[i++]<<d,d+=8)),(b+=A&(1<<_)-1)>a){e.msg="invalid distance too far back",C.mode=gt;break e}if(A>>>=_,d-=_,b>(_=n-s)){if((_=b-_)>u&&C.sane){e.msg="invalid distance too far back",C.mode=gt;break e}if(w=0,x=h,0===c){if(w+=l-_,_<y){y-=_;do{P[n++]=h[w++]}while(--_);w=n-b,x=P}}else if(c<_){if(w+=l+c-_,(_-=c)<y){y-=_;do{P[n++]=h[w++]}while(--_);if(w=0,c<y){y-=_=c;do{P[n++]=h[w++]}while(--_);w=n-b,x=P}}}else if(w+=c-_,_<y){y-=_;do{P[n++]=h[w++]}while(--_);w=n-b,x=P}for(;y>2;)P[n++]=x[w++],P[n++]=x[w++],P[n++]=x[w++],y-=3;y&&(P[n++]=x[w++],y>1&&(P[n++]=x[w++]))}else{w=n-b;do{P[n++]=P[w++],P[n++]=P[w++],P[n++]=P[w++],y-=3}while(y>2);y&&(P[n++]=P[w++],y>1&&(P[n++]=P[w++]))}break}}break}}while(i<r&&n<o);i-=y=d>>3,A&=(1<<(d-=y<<3))-1,e.next_in=i,e.next_out=n,e.avail_in=i<r?r-i+5:5-(i-r),e.avail_out=n<o?o-n+257:257-(n-o),C.hold=A,C.bits=d},vt=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]),_t=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]),yt=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]),bt=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]),wt=function(e,t,i,r,n,s,o,a){var l,u,c,h,A,d,p,f,g,m=a.bits,v=0,_=0,y=0,b=0,w=0,x=0,B=0,P=0,C=0,M=0,k=null,E=new Uint16Array(16),S=new Uint16Array(16),T=null;for(v=0;v<=15;v++)E[v]=0;for(_=0;_<r;_++)E[t[i+_]]++;for(w=m,b=15;b>=1&&0===E[b];b--);if(w>b&&(w=b),0===b)return n[s++]=20971520,n[s++]=20971520,a.bits=1,0;for(y=1;y<b&&0===E[y];y++);for(w<y&&(w=y),P=1,v=1;v<=15;v++)if(P<<=1,(P-=E[v])<0)return-1;if(P>0&&(0===e||1!==b))return-1;for(S[1]=0,v=1;v<15;v++)S[v+1]=S[v]+E[v];for(_=0;_<r;_++)0!==t[i+_]&&(o[S[t[i+_]]++]=_);if(0===e?(k=T=o,d=20):1===e?(k=vt,T=_t,d=257):(k=yt,T=bt,d=0),M=0,_=0,v=y,A=s,x=w,B=0,c=-1,h=(C=1<<w)-1,1===e&&C>852||2===e&&C>592)return 1;for(;;){p=v-B,o[_]+1<d?(f=0,g=o[_]):o[_]>=d?(f=T[o[_]-d],g=k[o[_]-d]):(f=96,g=0),l=1<<v-B,y=u=1<<x;do{n[A+(M>>B)+(u-=l)]=p<<24|f<<16|g}while(0!==u);for(l=1<<v-1;M&l;)l>>=1;if(0!==l?(M&=l-1,M+=l):M=0,_++,0==--E[v]){if(v===b)break;v=t[i+o[_]]}if(v>w&&(M&h)!==c){for(0===B&&(B=w),A+=y,P=1<<(x=v-B);x+B<b&&!((P-=E[x+B])<=0);)x++,P<<=1;if(C+=1<<x,1===e&&C>852||2===e&&C>592)return 1;n[c=M&h]=w<<24|x<<16|A-s}}return 0!==M&&(n[A+M]=v-B<<24|64<<16),a.bits=w,0},xt=H.Z_FINISH,Bt=H.Z_BLOCK,Pt=H.Z_TREES,Ct=H.Z_OK,Mt=H.Z_STREAM_END,kt=H.Z_NEED_DICT,Et=H.Z_STREAM_ERROR,St=H.Z_DATA_ERROR,Tt=H.Z_MEM_ERROR,It=H.Z_BUF_ERROR,Ft=H.Z_DEFLATED,Dt=16180,Rt=16190,Ot=16191,Lt=16192,jt=16194,Ut=16199,Nt=16200,Vt=16206,Qt=16209,Ht=function(e){return(e>>>24&255)+(e>>>8&65280)+((65280&e)<<8)+((255&e)<<24)};function Gt(){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}var zt,Wt,Kt=function(e){if(!e)return 1;var t=e.state;return!t||t.strm!==e||t.mode<Dt||t.mode>16211?1:0},Xt=function(e){if(Kt(e))return Et;var t=e.state;return e.total_in=e.total_out=t.total=0,e.msg="",t.wrap&&(e.adler=1&t.wrap),t.mode=Dt,t.last=0,t.havedict=0,t.flags=-1,t.dmax=32768,t.head=null,t.hold=0,t.bits=0,t.lencode=t.lendyn=new Int32Array(852),t.distcode=t.distdyn=new Int32Array(592),t.sane=1,t.back=-1,Ct},qt=function(e){if(Kt(e))return Et;var t=e.state;return t.wsize=0,t.whave=0,t.wnext=0,Xt(e)},Yt=function(e,t){var i;if(Kt(e))return Et;var r=e.state;return t<0?(i=0,t=-t):(i=5+(t>>4),t<48&&(t&=15)),t&&(t<8||t>15)?Et:(null!==r.window&&r.wbits!==t&&(r.window=null),r.wrap=i,r.wbits=t,qt(e))},Jt=function(e,t){if(!e)return Et;var i=new Gt;e.state=i,i.strm=e,i.window=null,i.mode=Dt;var r=Yt(e,t);return r!==Ct&&(e.state=null),r},Zt=!0,$t=function(e){if(Zt){zt=new Int32Array(512),Wt=new Int32Array(32);for(var t=0;t<144;)e.lens[t++]=8;for(;t<256;)e.lens[t++]=9;for(;t<280;)e.lens[t++]=7;for(;t<288;)e.lens[t++]=8;for(wt(1,e.lens,0,288,zt,0,e.work,{bits:9}),t=0;t<32;)e.lens[t++]=5;wt(2,e.lens,0,32,Wt,0,e.work,{bits:5}),Zt=!1}e.lencode=zt,e.lenbits=9,e.distcode=Wt,e.distbits=5},ei=function(e,t,i,r){var n,s=e.state;return null===s.window&&(s.wsize=1<<s.wbits,s.wnext=0,s.whave=0,s.window=new Uint8Array(s.wsize)),r>=s.wsize?(s.window.set(t.subarray(i-s.wsize,i),0),s.wnext=0,s.whave=s.wsize):((n=s.wsize-s.wnext)>r&&(n=r),s.window.set(t.subarray(i-r,i-r+n),s.wnext),(r-=n)?(s.window.set(t.subarray(i-r,i),0),s.wnext=r,s.whave=s.wsize):(s.wnext+=n,s.wnext===s.wsize&&(s.wnext=0),s.whave<s.wsize&&(s.whave+=n))),0},ti=qt,ii=Jt,ri=function(e,t){var i,r,n,s,o,a,l,u,c,h,A,d,p,f,g,m,v,_,y,b,w,x,B,P,C=0,M=new Uint8Array(4),k=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]);if(Kt(e)||!e.output||!e.input&&0!==e.avail_in)return Et;(i=e.state).mode===Ot&&(i.mode=Lt),o=e.next_out,n=e.output,l=e.avail_out,s=e.next_in,r=e.input,a=e.avail_in,u=i.hold,c=i.bits,h=a,A=l,x=Ct;e:for(;;)switch(i.mode){case Dt:if(0===i.wrap){i.mode=Lt;break}for(;c<16;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}if(2&i.wrap&&35615===u){0===i.wbits&&(i.wbits=15),i.check=0,M[0]=255&u,M[1]=u>>>8&255,i.check=V(i.check,M,2,0),u=0,c=0,i.mode=16181;break}if(i.head&&(i.head.done=!1),!(1&i.wrap)||(((255&u)<<8)+(u>>8))%31){e.msg="incorrect header check",i.mode=Qt;break}if((15&u)!==Ft){e.msg="unknown compression method",i.mode=Qt;break}if(c-=4,w=8+(15&(u>>>=4)),0===i.wbits&&(i.wbits=w),w>15||w>i.wbits){e.msg="invalid window size",i.mode=Qt;break}i.dmax=1<<i.wbits,i.flags=0,e.adler=i.check=1,i.mode=512&u?16189:Ot,u=0,c=0;break;case 16181:for(;c<16;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}if(i.flags=u,(255&i.flags)!==Ft){e.msg="unknown compression method",i.mode=Qt;break}if(57344&i.flags){e.msg="unknown header flags set",i.mode=Qt;break}i.head&&(i.head.text=u>>8&1),512&i.flags&&4&i.wrap&&(M[0]=255&u,M[1]=u>>>8&255,i.check=V(i.check,M,2,0)),u=0,c=0,i.mode=16182;case 16182:for(;c<32;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}i.head&&(i.head.time=u),512&i.flags&&4&i.wrap&&(M[0]=255&u,M[1]=u>>>8&255,M[2]=u>>>16&255,M[3]=u>>>24&255,i.check=V(i.check,M,4,0)),u=0,c=0,i.mode=16183;case 16183:for(;c<16;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}i.head&&(i.head.xflags=255&u,i.head.os=u>>8),512&i.flags&&4&i.wrap&&(M[0]=255&u,M[1]=u>>>8&255,i.check=V(i.check,M,2,0)),u=0,c=0,i.mode=16184;case 16184:if(1024&i.flags){for(;c<16;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}i.length=u,i.head&&(i.head.extra_len=u),512&i.flags&&4&i.wrap&&(M[0]=255&u,M[1]=u>>>8&255,i.check=V(i.check,M,2,0)),u=0,c=0}else i.head&&(i.head.extra=null);i.mode=16185;case 16185:if(1024&i.flags&&((d=i.length)>a&&(d=a),d&&(i.head&&(w=i.head.extra_len-i.length,i.head.extra||(i.head.extra=new Uint8Array(i.head.extra_len)),i.head.extra.set(r.subarray(s,s+d),w)),512&i.flags&&4&i.wrap&&(i.check=V(i.check,r,d,s)),a-=d,s+=d,i.length-=d),i.length))break e;i.length=0,i.mode=16186;case 16186:if(2048&i.flags){if(0===a)break e;d=0;do{w=r[s+d++],i.head&&w&&i.length<65536&&(i.head.name+=String.fromCharCode(w))}while(w&&d<a);if(512&i.flags&&4&i.wrap&&(i.check=V(i.check,r,d,s)),a-=d,s+=d,w)break e}else i.head&&(i.head.name=null);i.length=0,i.mode=16187;case 16187:if(4096&i.flags){if(0===a)break e;d=0;do{w=r[s+d++],i.head&&w&&i.length<65536&&(i.head.comment+=String.fromCharCode(w))}while(w&&d<a);if(512&i.flags&&4&i.wrap&&(i.check=V(i.check,r,d,s)),a-=d,s+=d,w)break e}else i.head&&(i.head.comment=null);i.mode=16188;case 16188:if(512&i.flags){for(;c<16;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}if(4&i.wrap&&u!==(65535&i.check)){e.msg="header crc mismatch",i.mode=Qt;break}u=0,c=0}i.head&&(i.head.hcrc=i.flags>>9&1,i.head.done=!0),e.adler=i.check=0,i.mode=Ot;break;case 16189:for(;c<32;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}e.adler=i.check=Ht(u),u=0,c=0,i.mode=Rt;case Rt:if(0===i.havedict)return e.next_out=o,e.avail_out=l,e.next_in=s,e.avail_in=a,i.hold=u,i.bits=c,kt;e.adler=i.check=1,i.mode=Ot;case Ot:if(t===Bt||t===Pt)break e;case Lt:if(i.last){u>>>=7&c,c-=7&c,i.mode=Vt;break}for(;c<3;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}switch(i.last=1&u,c-=1,3&(u>>>=1)){case 0:i.mode=16193;break;case 1:if($t(i),i.mode=Ut,t===Pt){u>>>=2,c-=2;break e}break;case 2:i.mode=16196;break;case 3:e.msg="invalid block type",i.mode=Qt}u>>>=2,c-=2;break;case 16193:for(u>>>=7&c,c-=7&c;c<32;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}if((65535&u)!=(u>>>16^65535)){e.msg="invalid stored block lengths",i.mode=Qt;break}if(i.length=65535&u,u=0,c=0,i.mode=jt,t===Pt)break e;case jt:i.mode=16195;case 16195:if(d=i.length){if(d>a&&(d=a),d>l&&(d=l),0===d)break e;n.set(r.subarray(s,s+d),o),a-=d,s+=d,l-=d,o+=d,i.length-=d;break}i.mode=Ot;break;case 16196:for(;c<14;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}if(i.nlen=257+(31&u),u>>>=5,c-=5,i.ndist=1+(31&u),u>>>=5,c-=5,i.ncode=4+(15&u),u>>>=4,c-=4,i.nlen>286||i.ndist>30){e.msg="too many length or distance symbols",i.mode=Qt;break}i.have=0,i.mode=16197;case 16197:for(;i.have<i.ncode;){for(;c<3;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}i.lens[k[i.have++]]=7&u,u>>>=3,c-=3}for(;i.have<19;)i.lens[k[i.have++]]=0;if(i.lencode=i.lendyn,i.lenbits=7,B={bits:i.lenbits},x=wt(0,i.lens,0,19,i.lencode,0,i.work,B),i.lenbits=B.bits,x){e.msg="invalid code lengths set",i.mode=Qt;break}i.have=0,i.mode=16198;case 16198:for(;i.have<i.nlen+i.ndist;){for(;m=(C=i.lencode[u&(1<<i.lenbits)-1])>>>16&255,v=65535&C,!((g=C>>>24)<=c);){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}if(v<16)u>>>=g,c-=g,i.lens[i.have++]=v;else{if(16===v){for(P=g+2;c<P;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}if(u>>>=g,c-=g,0===i.have){e.msg="invalid bit length repeat",i.mode=Qt;break}w=i.lens[i.have-1],d=3+(3&u),u>>>=2,c-=2}else if(17===v){for(P=g+3;c<P;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}c-=g,w=0,d=3+(7&(u>>>=g)),u>>>=3,c-=3}else{for(P=g+7;c<P;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}c-=g,w=0,d=11+(127&(u>>>=g)),u>>>=7,c-=7}if(i.have+d>i.nlen+i.ndist){e.msg="invalid bit length repeat",i.mode=Qt;break}for(;d--;)i.lens[i.have++]=w}}if(i.mode===Qt)break;if(0===i.lens[256]){e.msg="invalid code -- missing end-of-block",i.mode=Qt;break}if(i.lenbits=9,B={bits:i.lenbits},x=wt(1,i.lens,0,i.nlen,i.lencode,0,i.work,B),i.lenbits=B.bits,x){e.msg="invalid literal/lengths set",i.mode=Qt;break}if(i.distbits=6,i.distcode=i.distdyn,B={bits:i.distbits},x=wt(2,i.lens,i.nlen,i.ndist,i.distcode,0,i.work,B),i.distbits=B.bits,x){e.msg="invalid distances set",i.mode=Qt;break}if(i.mode=Ut,t===Pt)break e;case Ut:i.mode=Nt;case Nt:if(a>=6&&l>=258){e.next_out=o,e.avail_out=l,e.next_in=s,e.avail_in=a,i.hold=u,i.bits=c,mt(e,A),o=e.next_out,n=e.output,l=e.avail_out,s=e.next_in,r=e.input,a=e.avail_in,u=i.hold,c=i.bits,i.mode===Ot&&(i.back=-1);break}for(i.back=0;m=(C=i.lencode[u&(1<<i.lenbits)-1])>>>16&255,v=65535&C,!((g=C>>>24)<=c);){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}if(m&&!(240&m)){for(_=g,y=m,b=v;m=(C=i.lencode[b+((u&(1<<_+y)-1)>>_)])>>>16&255,v=65535&C,!(_+(g=C>>>24)<=c);){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}u>>>=_,c-=_,i.back+=_}if(u>>>=g,c-=g,i.back+=g,i.length=v,0===m){i.mode=16205;break}if(32&m){i.back=-1,i.mode=Ot;break}if(64&m){e.msg="invalid literal/length code",i.mode=Qt;break}i.extra=15&m,i.mode=16201;case 16201:if(i.extra){for(P=i.extra;c<P;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}i.length+=u&(1<<i.extra)-1,u>>>=i.extra,c-=i.extra,i.back+=i.extra}i.was=i.length,i.mode=16202;case 16202:for(;m=(C=i.distcode[u&(1<<i.distbits)-1])>>>16&255,v=65535&C,!((g=C>>>24)<=c);){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}if(!(240&m)){for(_=g,y=m,b=v;m=(C=i.distcode[b+((u&(1<<_+y)-1)>>_)])>>>16&255,v=65535&C,!(_+(g=C>>>24)<=c);){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}u>>>=_,c-=_,i.back+=_}if(u>>>=g,c-=g,i.back+=g,64&m){e.msg="invalid distance code",i.mode=Qt;break}i.offset=v,i.extra=15&m,i.mode=16203;case 16203:if(i.extra){for(P=i.extra;c<P;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}i.offset+=u&(1<<i.extra)-1,u>>>=i.extra,c-=i.extra,i.back+=i.extra}if(i.offset>i.dmax){e.msg="invalid distance too far back",i.mode=Qt;break}i.mode=16204;case 16204:if(0===l)break e;if(d=A-l,i.offset>d){if((d=i.offset-d)>i.whave&&i.sane){e.msg="invalid distance too far back",i.mode=Qt;break}d>i.wnext?(d-=i.wnext,p=i.wsize-d):p=i.wnext-d,d>i.length&&(d=i.length),f=i.window}else f=n,p=o-i.offset,d=i.length;d>l&&(d=l),l-=d,i.length-=d;do{n[o++]=f[p++]}while(--d);0===i.length&&(i.mode=Nt);break;case 16205:if(0===l)break e;n[o++]=i.length,l--,i.mode=Nt;break;case Vt:if(i.wrap){for(;c<32;){if(0===a)break e;a--,u|=r[s++]<<c,c+=8}if(A-=l,e.total_out+=A,i.total+=A,4&i.wrap&&A&&(e.adler=i.check=i.flags?V(i.check,n,A,o-A):U(i.check,n,A,o-A)),A=l,4&i.wrap&&(i.flags?u:Ht(u))!==i.check){e.msg="incorrect data check",i.mode=Qt;break}u=0,c=0}i.mode=16207;case 16207:if(i.wrap&&i.flags){for(;c<32;){if(0===a)break e;a--,u+=r[s++]<<c,c+=8}if(4&i.wrap&&u!==(4294967295&i.total)){e.msg="incorrect length check",i.mode=Qt;break}u=0,c=0}i.mode=16208;case 16208:x=Mt;break e;case Qt:x=St;break e;case 16210:return Tt;default:return Et}return e.next_out=o,e.avail_out=l,e.next_in=s,e.avail_in=a,i.hold=u,i.bits=c,(i.wsize||A!==e.avail_out&&i.mode<Qt&&(i.mode<Vt||t!==xt))&&ei(e,e.output,e.next_out,A-e.avail_out),h-=e.avail_in,A-=e.avail_out,e.total_in+=h,e.total_out+=A,i.total+=A,4&i.wrap&&A&&(e.adler=i.check=i.flags?V(i.check,n,A,e.next_out-A):U(i.check,n,A,e.next_out-A)),e.data_type=i.bits+(i.last?64:0)+(i.mode===Ot?128:0)+(i.mode===Ut||i.mode===jt?256:0),(0===h&&0===A||t===xt)&&x===Ct&&(x=It),x},ni=function(e){if(Kt(e))return Et;var t=e.state;return t.window&&(t.window=null),e.state=null,Ct},si=function(e,t){if(Kt(e))return Et;var i=e.state;return 2&i.wrap?(i.head=t,t.done=!1,Ct):Et},oi=function(e,t){var i,r=t.length;return Kt(e)?Et:0!==(i=e.state).wrap&&i.mode!==Rt?Et:i.mode===Rt&&U(1,t,r,0)!==i.check?St:ei(e,t,r,r)?(i.mode=16210,Tt):(i.havedict=1,Ct)},ai=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},li=Object.prototype.toString,ui=H.Z_NO_FLUSH,ci=H.Z_FINISH,hi=H.Z_OK,Ai=H.Z_STREAM_END,di=H.Z_NEED_DICT,pi=H.Z_STREAM_ERROR,fi=H.Z_DATA_ERROR,gi=H.Z_MEM_ERROR;function mi(e){this.options=ze({chunkSize:65536,windowBits:15,to:""},e||{});var t=this.options;t.raw&&t.windowBits>=0&&t.windowBits<16&&(t.windowBits=-t.windowBits,0===t.windowBits&&(t.windowBits=-15)),!(t.windowBits>=0&&t.windowBits<16)||e&&e.windowBits||(t.windowBits+=32),t.windowBits>15&&t.windowBits<48&&!(15&t.windowBits)&&(t.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new $e,this.strm.avail_out=0;var i=ii(this.strm,t.windowBits);if(i!==hi)throw new Error(Q[i]);if(this.header=new ai,si(this.strm,this.header),t.dictionary&&("string"==typeof t.dictionary?t.dictionary=Ye(t.dictionary):"[object ArrayBuffer]"===li.call(t.dictionary)&&(t.dictionary=new Uint8Array(t.dictionary)),t.raw&&(i=oi(this.strm,t.dictionary))!==hi))throw new Error(Q[i])}function vi(e,t){var i=new mi(t);if(i.push(e),i.err)throw i.msg||Q[i.err];return i.result}mi.prototype.push=function(e,t){var i,r,n,s=this.strm,o=this.options.chunkSize,a=this.options.dictionary;if(this.ended)return!1;for(r=t===~~t?t:!0===t?ci:ui,"[object ArrayBuffer]"===li.call(e)?s.input=new Uint8Array(e):s.input=e,s.next_in=0,s.avail_in=s.input.length;;){for(0===s.avail_out&&(s.output=new Uint8Array(o),s.next_out=0,s.avail_out=o),(i=ri(s,r))===di&&a&&((i=oi(s,a))===hi?i=ri(s,r):i===fi&&(i=di));s.avail_in>0&&i===Ai&&s.state.wrap>0&&0!==e[s.next_in];)ti(s),i=ri(s,r);switch(i){case pi:case fi:case di:case gi:return this.onEnd(i),this.ended=!0,!1}if(n=s.avail_out,s.next_out&&(0===s.avail_out||i===Ai))if("string"===this.options.to){var l=Ze(s.output,s.next_out),u=s.next_out-l,c=Je(s.output,l);s.next_out=u,s.avail_out=o-u,u&&s.output.set(s.output.subarray(l,l+u),0),this.onData(c)}else this.onData(s.output.length===s.next_out?s.output:s.output.subarray(0,s.next_out));if(i!==hi||0!==n){if(i===Ai)return i=ni(this.strm),this.onEnd(i),this.ended=!0,!0;if(0===s.avail_in)break}}return!0},mi.prototype.onData=function(e){this.chunks.push(e)},mi.prototype.onEnd=function(e){e===hi&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=We(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg};var _i=function(e,t){return(t=t||{}).raw=!0,vi(e,t)},yi=At,bi=dt,wi=pt,xi=ft,Bi=mi,Pi=vi,Ci=_i,Mi=vi,ki=H,Ei={Deflate:yi,deflate:bi,deflateRaw:wi,gzip:xi,Inflate:Bi,inflate:Pi,inflateRaw:Ci,ungzip:Mi,constants:ki};e.Deflate=yi,e.Inflate=Bi,e.constants=ki,e.default=Ei,e.deflate=bi,e.deflateRaw=wi,e.gzip=xi,e.inflate=Pi,e.inflateRaw=Ci,e.ungzip=Mi,Object.defineProperty(e,"__esModule",{value:!0})});var Pk=Object.freeze({__proto__:null}),Ck=window.pako||Pk;Ck.inflate||(Ck=Ck.default);var Mk=Y.vec4(),kk=Y.vec4();var Ek,Sk=(Ek=new Float32Array(3),function(e){return Ek[0]=e[0]/255,Ek[1]=e[1]/255,Ek[2]=e[2]/255,Ek});function Tk(e,t){var i=[];if(t.length>1)for(var r=0,n=t.length-1;r<n;r++)i.push(t[r]),i.push(t[r+1]);else if(e.length>1)for(var s=0,o=e.length/3-1;s<o;s++)i.push(s),i.push(s+1);return i}!function(){var e=document.createElement("canvas"),t=e.getContext("2d")}();var Ik={version:10,parse:function(e,t,i,r,n,s){var o=function(e){var t=0;return{metadata:e[t++],textureData:e[t++],eachTextureDataPortion:e[t++],eachTextureAttributes:e[t++],positions:e[t++],normals:e[t++],colors:e[t++],uvs:e[t++],indices:e[t++],edgeIndices:e[t++],eachTextureSetTextures:e[t++],matrices:e[t++],reusedGeometriesDecodeMatrix:e[t++],eachGeometryPrimitiveType:e[t++],eachGeometryPositionsPortion:e[t++],eachGeometryNormalsPortion:e[t++],eachGeometryColorsPortion:e[t++],eachGeometryUVsPortion:e[t++],eachGeometryIndicesPortion:e[t++],eachGeometryEdgeIndicesPortion:e[t++],eachMeshGeometriesPortion:e[t++],eachMeshMatricesPortion:e[t++],eachMeshTextureSet:e[t++],eachMeshMaterialAttributes:e[t++],eachEntityId:e[t++],eachEntityMeshesPortion:e[t++],eachTileAABB:e[t++],eachTileEntitiesPortion:e[t++]}}(i),a=function(e){function t(e,t){return 0===e.length?[]:Ck.inflate(e,t).buffer}return{metadata:JSON.parse(Ck.inflate(e.metadata,{to:"string"})),textureData:new Uint8Array(t(e.textureData)),eachTextureDataPortion:new Uint32Array(t(e.eachTextureDataPortion)),eachTextureAttributes:new Uint16Array(t(e.eachTextureAttributes)),positions:new Uint16Array(t(e.positions)),normals:new Int8Array(t(e.normals)),colors:new Uint8Array(t(e.colors)),uvs:new Float32Array(t(e.uvs)),indices:new Uint32Array(t(e.indices)),edgeIndices:new Uint32Array(t(e.edgeIndices)),eachTextureSetTextures:new Int32Array(t(e.eachTextureSetTextures)),matrices:new Float32Array(t(e.matrices)),reusedGeometriesDecodeMatrix:new Float32Array(t(e.reusedGeometriesDecodeMatrix)),eachGeometryPrimitiveType:new Uint8Array(t(e.eachGeometryPrimitiveType)),eachGeometryPositionsPortion:new Uint32Array(t(e.eachGeometryPositionsPortion)),eachGeometryNormalsPortion:new Uint32Array(t(e.eachGeometryNormalsPortion)),eachGeometryColorsPortion:new Uint32Array(t(e.eachGeometryColorsPortion)),eachGeometryUVsPortion:new Uint32Array(t(e.eachGeometryUVsPortion)),eachGeometryIndicesPortion:new Uint32Array(t(e.eachGeometryIndicesPortion)),eachGeometryEdgeIndicesPortion:new Uint32Array(t(e.eachGeometryEdgeIndicesPortion)),eachMeshGeometriesPortion:new Uint32Array(t(e.eachMeshGeometriesPortion)),eachMeshMatricesPortion:new Uint32Array(t(e.eachMeshMatricesPortion)),eachMeshTextureSet:new Int32Array(t(e.eachMeshTextureSet)),eachMeshMaterialAttributes:new Uint8Array(t(e.eachMeshMaterialAttributes)),eachEntityId:JSON.parse(Ck.inflate(e.eachEntityId,{to:"string"})),eachEntityMeshesPortion:new Uint32Array(t(e.eachEntityMeshesPortion)),eachTileAABB:new Float64Array(t(e.eachTileAABB)),eachTileEntitiesPortion:new Uint32Array(t(e.eachTileEntitiesPortion))}}(o);!function(e,t,i,r,n,s){var o=s.getNextId(),a=i.metadata,l=i.textureData,u=i.eachTextureDataPortion,c=i.eachTextureAttributes,h=i.positions,A=i.normals,d=i.colors,p=i.uvs,f=i.indices,g=i.edgeIndices,m=i.eachTextureSetTextures,v=i.matrices,_=i.reusedGeometriesDecodeMatrix,y=i.eachGeometryPrimitiveType,b=i.eachGeometryPositionsPortion,w=i.eachGeometryNormalsPortion,x=i.eachGeometryColorsPortion,B=i.eachGeometryUVsPortion,P=i.eachGeometryIndicesPortion,C=i.eachGeometryEdgeIndicesPortion,M=i.eachMeshGeometriesPortion,k=i.eachMeshMatricesPortion,E=i.eachMeshTextureSet,S=i.eachMeshMaterialAttributes,T=i.eachEntityId,I=i.eachEntityMeshesPortion,F=i.eachTileAABB,D=i.eachTileEntitiesPortion,R=u.length,O=m.length/5,L=b.length,j=M.length,U=I.length,N=D.length;n&&n.loadData(a,{includeTypes:t.includeTypes,excludeTypes:t.excludeTypes,globalizeObjectIds:t.globalizeObjectIds});for(var V=0;V<R;V++){var Q=V===R-1,H=u[V],G=Q?l.length:u[V+1],z=G-H>0,W=9*V,K=1===c[W+0];c[W+1],c[W+2],c[W+3];var X=c[W+4],q=c[W+5],J=c[W+6],Z=c[W+7],$=c[W+8];if(z){var ee=new Uint8Array(l.subarray(H,G)).buffer,te="".concat(o,"-texture-").concat(V);K?r.createTexture({id:te,buffers:[ee],minFilter:X,magFilter:q,wrapS:J,wrapT:Z,wrapR:$}):r.createTexture({id:te,imageBuffer:ee,minFilter:X,magFilter:q,wrapS:J,wrapT:Z,wrapR:$})}}for(var ie=0;ie<O;ie++){var re=5*ie,se="".concat(o,"-textureSet-").concat(ie),oe=m[re+0],ae=m[re+1],le=m[re+2],ue=m[re+3],ce=m[re+4];r.createTextureSet({id:se,colorTextureId:oe>=0?"".concat(o,"-texture-").concat(oe):null,normalsTextureId:le>=0?"".concat(o,"-texture-").concat(le):null,metallicRoughnessTextureId:ae>=0?"".concat(o,"-texture-").concat(ae):null,emissiveTextureId:ue>=0?"".concat(o,"-texture-").concat(ue):null,occlusionTextureId:ce>=0?"".concat(o,"-texture-").concat(ce):null})}for(var he=new Uint32Array(L),Ae=0;Ae<j;Ae++){var de=M[Ae];void 0!==he[de]?he[de]++:he[de]=1}for(var pe=Y.vec3(),fe=Y.AABB3(),ge={},me=0;me<N;me++){var ve=me===N-1,_e=D[me],ye=ve?U-1:D[me+1]-1,be=6*me,we=F.subarray(be,be+6);Y.getAABB3Center(we,pe),fe[0]=we[0]-pe[0],fe[1]=we[1]-pe[1],fe[2]=we[2]-pe[2],fe[3]=we[3]-pe[0],fe[4]=we[4]-pe[1],fe[5]=we[5]-pe[2];for(var xe=xi.createPositionsDecodeMatrix(fe),Be={},Pe=_e;Pe<=ye;Pe++){var Ce=T[Pe],Me=t.globalizeObjectIds?Y.globalizeObjectId(r.id,Ce):Ce,ke=Pe===U-1,Ee=I[Pe],Se=ke?M.length-1:I[Pe+1]-1,Te=[],Ie=e.metaScene.metaObjects[Me],Fe={},De={};if(Ie){if(t.excludeTypesMap&&Ie.type&&t.excludeTypesMap[Ie.type])continue;if(t.includeTypesMap&&Ie.type&&!t.includeTypesMap[Ie.type])continue;var Re=t.objectDefaults?t.objectDefaults[Ie.type]||t.objectDefaults.DEFAULT:null;Re&&(!1===Re.visible&&(Fe.visible=!1),!1===Re.pickable&&(Fe.pickable=!1),Re.colorize&&(De.color=Re.colorize),void 0!==Re.opacity&&null!==Re.opacity&&(De.opacity=Re.opacity),void 0!==Re.metallic&&null!==Re.metallic&&(De.metallic=Re.metallic),void 0!==Re.roughness&&null!==Re.roughness&&(De.roughness=Re.roughness))}else if(t.excludeUnclassifiedObjects)continue;for(var Oe=Ee;Oe<=Se;Oe++){var Le=M[Oe],je=he[Le]>1,Ue=Le===L-1,Ne=E[Oe],Ve=Ne>=0?"".concat(o,"-textureSet-").concat(Ne):null,Qe=Sk(S.subarray(6*Oe,6*Oe+3)),He=S[6*Oe+3]/255,Ge=S[6*Oe+4]/255,ze=S[6*Oe+5]/255,We=s.getNextId();if(je){var Ke=k[Oe],Xe=v.slice(Ke,Ke+16),qe="".concat(o,"-geometry.").concat(me,".").concat(Le),Ye=ge[qe];if(!Ye){Ye={batchThisMesh:!t.reuseGeometries};var Je=!1;switch(y[Le]){case 0:Ye.primitiveName="solid",Ye.geometryPositions=h.subarray(b[Le],Ue?h.length:b[Le+1]),Ye.geometryNormals=A.subarray(w[Le],Ue?A.length:w[Le+1]),Ye.geometryUVs=p.subarray(B[Le],Ue?p.length:B[Le+1]),Ye.geometryIndices=f.subarray(P[Le],Ue?f.length:P[Le+1]),Ye.geometryEdgeIndices=g.subarray(C[Le],Ue?g.length:C[Le+1]),Je=Ye.geometryPositions.length>0&&Ye.geometryIndices.length>0;break;case 1:Ye.primitiveName="surface",Ye.geometryPositions=h.subarray(b[Le],Ue?h.length:b[Le+1]),Ye.geometryNormals=A.subarray(w[Le],Ue?A.length:w[Le+1]),Ye.geometryUVs=p.subarray(B[Le],Ue?p.length:B[Le+1]),Ye.geometryIndices=f.subarray(P[Le],Ue?f.length:P[Le+1]),Ye.geometryEdgeIndices=g.subarray(C[Le],Ue?g.length:C[Le+1]),Je=Ye.geometryPositions.length>0&&Ye.geometryIndices.length>0;break;case 2:Ye.primitiveName="points",Ye.geometryPositions=h.subarray(b[Le],Ue?h.length:b[Le+1]),Ye.geometryColors=d.subarray(x[Le],Ue?d.length:x[Le+1]),Je=Ye.geometryPositions.length>0;break;case 3:Ye.primitiveName="lines",Ye.geometryPositions=h.subarray(b[Le],Ue?h.length:b[Le+1]),Ye.geometryIndices=f.subarray(P[Le],Ue?f.length:P[Le+1]),Je=Ye.geometryPositions.length>0&&Ye.geometryIndices.length>0;break;case 4:Ye.primitiveName="lines",Ye.geometryPositions=h.subarray(b[Le],Ue?h.length:b[Le+1]),Ye.geometryIndices=Tk(Ye.geometryPositions,f.subarray(P[Le],Ue?f.length:P[Le+1])),Je=Ye.geometryPositions.length>0&&Ye.geometryIndices.length>0;break;default:continue}if(Je||(Ye=null),Ye&&(Ye.geometryPositions.length,Ye.batchThisMesh)){Ye.decompressedPositions=new Float32Array(Ye.geometryPositions.length),Ye.transformedAndRecompressedPositions=new Uint16Array(Ye.geometryPositions.length);for(var Ze=Ye.geometryPositions,$e=Ye.decompressedPositions,et=0,tt=Ze.length;et<tt;et+=3)$e[et+0]=Ze[et+0]*_[0]+_[12],$e[et+1]=Ze[et+1]*_[5]+_[13],$e[et+2]=Ze[et+2]*_[10]+_[14];Ye.geometryPositions=null,ge[qe]=Ye}}if(Ye)if(Ye.batchThisMesh){for(var it=Ye.decompressedPositions,rt=Ye.transformedAndRecompressedPositions,nt=0,st=it.length;nt<st;nt+=3)Mk[0]=it[nt+0],Mk[1]=it[nt+1],Mk[2]=it[nt+2],Mk[3]=1,Y.transformVec4(Xe,Mk,kk),xi.compressPosition(kk,fe,Mk),rt[nt+0]=Mk[0],rt[nt+1]=Mk[1],rt[nt+2]=Mk[2];r.createMesh(ne.apply(De,{id:We,textureSetId:Ve,origin:pe,primitive:Ye.primitiveName,positionsCompressed:rt,normalsCompressed:Ye.geometryNormals,uv:Ye.geometryUVs,colorsCompressed:Ye.geometryColors,indices:Ye.geometryIndices,edgeIndices:Ye.geometryEdgeIndices,positionsDecodeMatrix:xe,color:Qe,metallic:Ge,roughness:ze,opacity:He})),Te.push(We)}else Be[qe]||(r.createGeometry({id:qe,primitive:Ye.primitiveName,positionsCompressed:Ye.geometryPositions,normalsCompressed:Ye.geometryNormals,uv:Ye.geometryUVs,colorsCompressed:Ye.geometryColors,indices:Ye.geometryIndices,edgeIndices:Ye.geometryEdgeIndices,positionsDecodeMatrix:_}),Be[qe]=!0),r.createMesh(ne.apply(De,{id:We,geometryId:qe,textureSetId:Ve,matrix:Xe,color:Qe,metallic:Ge,roughness:ze,opacity:He,origin:pe})),Te.push(We)}else{var ot=void 0,at=void 0,lt=void 0,ut=void 0,ct=void 0,ht=void 0,At=void 0,dt=!1;switch(y[Le]){case 0:ot="solid",at=h.subarray(b[Le],Ue?h.length:b[Le+1]),lt=A.subarray(w[Le],Ue?A.length:w[Le+1]),ut=p.subarray(B[Le],Ue?p.length:B[Le+1]),ht=f.subarray(P[Le],Ue?f.length:P[Le+1]),At=g.subarray(C[Le],Ue?g.length:C[Le+1]),dt=at.length>0&&ht.length>0;break;case 1:ot="surface",at=h.subarray(b[Le],Ue?h.length:b[Le+1]),lt=A.subarray(w[Le],Ue?A.length:w[Le+1]),ut=p.subarray(B[Le],Ue?p.length:B[Le+1]),ht=f.subarray(P[Le],Ue?f.length:P[Le+1]),At=g.subarray(C[Le],Ue?g.length:C[Le+1]),dt=at.length>0&&ht.length>0;break;case 2:ot="points",at=h.subarray(b[Le],Ue?h.length:b[Le+1]),ct=d.subarray(x[Le],Ue?d.length:x[Le+1]),dt=at.length>0;break;case 3:ot="lines",at=h.subarray(b[Le],Ue?h.length:b[Le+1]),ht=f.subarray(P[Le],Ue?f.length:P[Le+1]),dt=at.length>0&&ht.length>0;break;case 4:ot="lines",ht=Tk(at=h.subarray(b[Le],Ue?h.length:b[Le+1]),f.subarray(P[Le],Ue?f.length:P[Le+1])),dt=at.length>0&&ht.length>0;break;default:continue}dt&&(r.createMesh(ne.apply(De,{id:We,textureSetId:Ve,origin:pe,primitive:ot,positionsCompressed:at,normalsCompressed:lt,uv:ut&&ut.length>0?ut:null,colorsCompressed:ct,indices:ht&&ht.length>0?ht:null,edgeIndices:At,positionsDecodeMatrix:xe,color:Qe,metallic:Ge,roughness:ze,opacity:He})),Te.push(We))}}Te.length>0&&r.createEntity(ne.apply(Fe,{id:Me,isObject:!0,meshIds:Te}))}}}(e,t,a,r,n,s)},inflateMetadata:function(e){return JSON.parse(Ck.inflate(e,{to:"string"}))}},Fk={};Fk[Ik.version]=Ik;var Dk=function(){function e(t){var i,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return x(this,e),(i=d(this,e,["XTCLoader",t,r]))._maxGeometryBatchSize=r.maxGeometryBatchSize,i.textureTranscoder=r.textureTranscoder,i.dataSource=r.dataSource,i.objectDefaults=r.objectDefaults,i.includeTypes=r.includeTypes,i.excludeTypes=r.excludeTypes,i.excludeUnclassifiedObjects=r.excludeUnclassifiedObjects,i.reuseGeometries=r.reuseGeometries,i}return _(e,ge),P(e,[{key:"supportedVersions",get:function(){return Object.keys(Fk)}},{key:"textureTranscoder",get:function(){return this._textureTranscoder},set:function(e){this._textureTranscoder=e}},{key:"dataSource",get:function(){return this._dataSource},set:function(e){this._dataSource=e||new Bk}},{key:"objectDefaults",get:function(){return this._objectDefaults},set:function(e){this._objectDefaults=e||YM}},{key:"includeTypes",get:function(){return this._includeTypes},set:function(e){this._includeTypes=e}},{key:"excludeTypes",get:function(){return this._excludeTypes},set:function(e){this._excludeTypes=e}},{key:"excludeUnclassifiedObjects",get:function(){return this._excludeUnclassifiedObjects},set:function(e){this._excludeUnclassifiedObjects=!!e}},{key:"globalizeObjectIds",get:function(){return this._globalizeObjectIds},set:function(e){this._globalizeObjectIds=!!e}},{key:"reuseGeometries",get:function(){return this._reuseGeometries},set:function(e){this._reuseGeometries=!1!==e}},{key:"load",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(t.id&&this.viewer.scene.components[t.id]&&(this.error("Component with this ID already exists in viewer: "+t.id+" - will autogenerate this ID"),delete t.id),!(t.src||t.xtc||t.manifestSrc||t.manifest))return this.error("load() param expected: src, xtc, manifestSrc or manifestData"),c;var i={},r=t.includeTypes||this._includeTypes,n=t.excludeTypes||this._excludeTypes,s=t.objectDefaults||this._objectDefaults;if(i.reuseGeometries=null!==t.reuseGeometries&&void 0!==t.reuseGeometries?t.reuseGeometries:!1!==this._reuseGeometries,r){i.includeTypesMap={};for(var o=0,a=r.length;o<a;o++)i.includeTypesMap[r[o]]=!0}if(n){i.excludeTypesMap={};for(var l=0,u=n.length;l<u;l++)i.excludeTypesMap[n[l]]=!0}s&&(i.objectDefaults=s),i.excludeUnclassifiedObjects=void 0!==t.excludeUnclassifiedObjects?!!t.excludeUnclassifiedObjects:this._excludeUnclassifiedObjects,i.globalizeObjectIds=void 0!==t.globalizeObjectIds&&null!==t.globalizeObjectIds?!!t.globalizeObjectIds:this._globalizeObjectIds;var c=new $c(this.viewer.scene,ne.apply(t,{isModel:!0,textureTranscoder:this._textureTranscoder,maxGeometryBatchSize:this._maxGeometryBatchSize,origin:t.origin,disableVertexWelding:t.disableVertexWelding||!1,disableIndexRebucketing:t.disableIndexRebucketing||!1,dtxEnabled:t.dtxEnabled})),h=c.id,A=new vA({metaScene:this.viewer.metaScene,id:h});this.viewer.scene.canvas.spinner.processes++;var d,p,f=function(){c.destroyed||(c.finalize(),A.finalize(),e.viewer.scene.canvas.spinner.processes--,c.once("destroyed",function(){e.viewer.metaScene.destroyMetaModel(A.id)}),e.scheduleTask(function(){c.destroyed||(c.scene.fire("modelLoaded",c.id),c.fire("loaded",!0,!1))}))},g=function(t){e.viewer.scene.canvas.spinner.processes--,e.error(t),c.fire("error",t)},m=0,v={getNextId:function(){return"".concat(h,".").concat(m++)}};if(t.metaModelSrc||t.metaModelData)if(t.metaModelSrc){var _=t.metaModelSrc;this._dataSource.getMetaModel(_,function(s){c.destroyed||(A.loadData(s,{includeTypes:r,excludeTypes:n,globalizeObjectIds:i.globalizeObjectIds}),t.src?e._loadModel(t.src,t,i,c,null,v,f,g):(e._parseModel(t.xtc,t,i,c,null,v),f()))},function(e){g("load(): Failed to load model metadata for model '".concat(h," from '").concat(_,"' - ").concat(e))})}else t.metaModelData&&(A.loadData(t.metaModelData,{includeTypes:r,excludeTypes:n,globalizeObjectIds:i.globalizeObjectIds}),t.src?this._loadModel(t.src,t,i,c,null,v,f,g):(this._parseModel(t.xtc,t,i,c,null,v),f()));else if(t.src)this._loadModel(t.src,t,i,c,A,v,f,g);else if(t.xtc)this._parseModel(t.xtc,t,i,c,A,v),f();else if(t.manifestSrc||t.manifest){var y=t.manifestSrc?(d=t.manifestSrc,(p=d.split("/")).pop(),p.join("/")+"/"):"",b=function(t,s,o){var a=0,l=function(){c.destroyed||a>=t.length?s():e._dataSource.getMetaModel("".concat(y).concat(t[a]),function(t){A.loadData(t,{includeTypes:r,excludeTypes:n,globalizeObjectIds:i.globalizeObjectIds}),a++,e.scheduleTask(l,200)},o)};l()},w=function(r,n,s){var o=0,a=function(){c.destroyed||o>=r.length?n():e._dataSource.getXTC("".concat(y).concat(r[o]),function(r){e._parseModel(r,t,i,c,null,v),c.preFinalize(),o++,e.scheduleTask(a,200)},s)};a()},x=function(r,n,s){var o=0,a=function(){c.destroyed||o>=r.length?n():e._dataSource.getXTC("".concat(y).concat(r[o]),function(r){e._parseModel(r,t,i,c,A,v),c.preFinalize(),o++,e.scheduleTask(a,100)},s)};a()};if(t.manifest){var B=t.manifest,P=B.xtcFiles;if(!P||0===P.length)return void g("load(): Failed to load model manifest - manifest not valid");var C=B.metaModelFiles;C?b(C,function(){w(P,f,g)},g):x(P,f,g)}else this._dataSource.getManifest(t.manifestSrc,function(e){if(!c.destroyed){var t=e.xtcFiles;if(t&&0!==t.length){var i=e.metaModelFiles;i?b(i,function(){w(t,f,g)},g):x(t,f,g)}else g("load(): Failed to load model manifest - manifest not valid")}},g)}return c}},{key:"_loadModel",value:function(e,t,i,r,n,s,o,a){var l=this;this._dataSource.getXTC(t.src,function(e){l._parseModel(e,t,i,r,n,s),r.preFinalize(),o()},a)}},{key:"_parseModel",value:(t=a(s().mark(function e(t,i,r,n,o,a){var l,u,c,h,A,d,p,f,g;return s().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!n.destroyed){e.next=2;break}return e.abrupt("return");case 2:if(l=new DataView(t),u=new Uint8Array(t),c=l.getUint32(0,!0),h=Fk[c]){e.next=9;break}return this.error("Unsupported .XTC file version: "+c+" - this XTCLoaderPlugin supports versions "+Object.keys(Fk)),e.abrupt("return");case 9:for(this.log("Loading .xtc V"+c),A=l.getUint32(4,!0),d=[],p=4*(A+2),f=0;f<A;f++)g=l.getUint32(4*(f+2),!0),d.push(u.subarray(p,p+g)),p+=g;h.parse(this.viewer,r,d,n,o,a);case 15:case"end":return e.stop()}},e,this)})),function(e,i,r,n,s,o){return t.apply(this,arguments)})},{key:"loadMetadata",value:function(e,t,i,r){var n=this;e._finalized=!1;try{this._workerInflate(e,t,i,function(t){t.terminate(),n.fire("metaLoaded",{result:"success",metaModel:e}),"function"==typeof r&&r()},function(t,i){t.terminate(),n.fire("metaLoaded",{result:"failed",message:i,metaModel:e})})}catch(t){this.fire("metaloaded",{result:t,metaModel:e})}}},{key:"_workerInflate",value:function(e,t,i,r,n){var s,o,a=this,l=(s=new Blob(['\n self.importScripts(\'https://cdnjs.cloudflare.com/ajax/libs/pako/1.0.11/pako.min.js\');\n \n function inflateMetadata(deflatedData) {\n\t\t\ttry {\n\t\t\t\treturn JSON.parse(self.pako.inflate(deflatedData, { to: "string" }));\n\t\t\t} catch (error) {\n\t\t\t\tconsole.error("Error inflating metadata:", error);\n\t\t\t\tthrow error;\n\t\t\t} \n\t\t}\n \n self.onmessage = function (e) {\n console.log("start worker:");\n const metaJson = inflateMetadata(e.data.buffer);\n\n self.postMessage({\n metaJson,\n time: new Date().getTime()\n });\n };\n '],{type:"application/javascript"}),o=URL.createObjectURL(s),new Worker(o));l.postMessage({buffer:t}),l.onmessage=function(t){i?e.loadData(t.data.metaJson,function(){e.finalize(),"function"==typeof r?r(l):l.terminate()},function(e){"function"==typeof n&&n(l,e)}):a.fire("metaLoading",function(){e.loadData(t.data.metaJson,function(){e.finalize(),"function"==typeof r?r(l):l.terminate()},function(e){"function"==typeof n&&n(l,e)})})},l.onerror=function(e){"function"==typeof n&&n(l,e.message),l.terminate()}}}]);var t}();var Rk=function(){return P(function e(){x(this,e)},[{key:"getIFC",value:function(e,t,i){var r=function(){};t=t||r,i=i||r;var n=e.match(/^data:(.*?)(;base64)?,(.*)$/);if(n){var s=!!n[2],o=n[3];o=window.decodeURIComponent(o),s&&(o=window.atob(o));try{for(var a=new ArrayBuffer(o.length),l=new Uint8Array(a),u=0;u<o.length;u++)l[u]=o.charCodeAt(u);t(a)}catch(e){i(e)}}else{var c=new XMLHttpRequest;c.open("GET",e,!0),c.responseType="arraybuffer",c.onreadystatechange=function(){4===c.readyState&&(200===c.status?t(c.response):i("getXTC error : "+c.response))},c.send(null)}}}])}(),Ok=function(){function e(t){var i,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return x(this,e),(i=d(this,e,["ifcLoader",t,r])).dataSource=r.dataSource,i.objectDefaults=r.objectDefaults,i.includeTypes=r.includeTypes,i.excludeTypes=r.excludeTypes,i.excludeUnclassifiedObjects=r.excludeUnclassifiedObjects,r.WebIFC&&(i._webIFC=r.WebIFC,i._ifcAPI=r.IfcAPI,i.webIfcFroMOutside=!0),i}return _(e,ge),P(e,[{key:"supportedVersions",get:function(){return["2x3","4"]}},{key:"dataSource",get:function(){return this._dataSource},set:function(e){this._dataSource=e||new Rk}},{key:"objectDefaults",get:function(){return this._objectDefaults},set:function(e){this._objectDefaults=e||YM}},{key:"includeTypes",get:function(){return this._includeTypes},set:function(e){this._includeTypes=e}},{key:"excludeTypes",get:function(){return this._excludeTypes},set:function(e){this._excludeTypes=e}},{key:"excludeUnclassifiedObjects",get:function(){return this._excludeUnclassifiedObjects},set:function(e){this._excludeUnclassifiedObjects=!!e}},{key:"globalizeObjectIds",get:function(){return this._globalizeObjectIds},set:function(e){this._globalizeObjectIds=!!e}},{key:"load",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};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);var t=new $c(this.viewer.scene,ne.apply(e,{isModel:!0}));if(!e.src&&!e.ifc)return this.error("load() param expected: src or IFC"),t;var i={autoNormals:!0};if(!1!==e.loadMetadata){var r=e.includeTypes||this._includeTypes,n=e.excludeTypes||this._excludeTypes,s=e.objectDefaults||this._objectDefaults;if(r){i.includeTypesMap={};for(var o=0,a=r.length;o<a;o++)i.includeTypesMap[r[o]]=!0}if(n){i.excludeTypesMap={};for(var l=0,u=n.length;l<u;l++)i.excludeTypesMap[n[l]]=!0}s&&(i.objectDefaults=s),i.excludeUnclassifiedObjects=void 0!==e.excludeUnclassifiedObjects?!!e.excludeUnclassifiedObjects:this._excludeUnclassifiedObjects,i.globalizeObjectIds=void 0!==e.globalizeObjectIds?!!e.globalizeObjectIds:this._globalizeObjectIds}if(this.webIfcFroMOutside)try{e.src?this._loadModel(e.src,e,i,t):this._parseModel(e.ifc,e,i,t)}catch(e){this.error(e),t.fire("error",e)}return t}},{key:"_loadModel",value:function(e,t,i,r){var n=this,s=this.viewer.scene.canvas.spinner;s.processes++,this._dataSource.getIFC(t.src,function(e){n._parseModel(e,t,i,r),s.processes--},function(e){s.processes--,n.error(e),r.fire("error",e)})}},{key:"_parseModel",value:function(e,t,i,r){if(!r.destroyed){var n=t.stats||{};if(n.sourceFormat="IFC",n.schemaVersion="",n.title="",n.author="",n.created="",n.numMetaObjects=0,n.numPropertySets=0,n.numObjects=0,n.numGeometries=0,n.numTriangles=0,n.numVertices=0,this.webIfcFroMOutside){if(!this._ifcAPI)throw"WebIFCLoaderPlugin has no WebIFC instance configured - please inject via WebIFCLoaderPlugin constructor"}else i.wasmPath&&this._ifcAPI.SetWasmPath(i.wasmPath);var s,o=new Uint8Array(e),a=this._ifcAPI.OpenModel(o),l=this._ifcAPI.GetModelSchema(a),u=this._ifcAPI.GetLineIDsWithType(a,this._webIFC.IFCPROJECT).get(0),c=!1!==t.loadMetadata,h=void 0!==t.metadata&&null!==t.metadata;s=h?t.metadata:null;var A={ifcProjectId:u,modelID:a,modelSchema:l,sceneModel:r,loadMetadata:c,metadata:c?{id:"",projectId:""+u,author:"",createdAt:"",schema:"",creatingApplication:"",metaObjects:[],propertySets:[]}:s,metaObjects:h?r.metaObjects:{},options:i,nextId:0,stats:n};if(c){if(i.includeTypes){A.includeTypes={};for(var d=0,p=i.includeTypes.length;d<p;d++)A.includeTypes[i.includeTypes[d]]=!0}if(i.excludeTypes){A.excludeTypes={};for(var f=0,g=i.excludeTypes.length;f<g;f++)A.excludeTypes[i.excludeTypes[f]]=!0}this._parseMetaObjects(A),this._parsePropertySets(A)}if(this._parseGeometry(A),r.finalize(),c||h){var m=r.id;this.viewer.metaScene.createMetaModel(m,A.metadata,i)}r.scene.once("tick",function(){r.destroyed||(r.scene.fire("modelLoaded",r.id),r.fire("loaded",!0,!1))})}}},{key:"_parseMetaObjects",value:function(e){var t=this._ifcAPI.GetLine(e.modelID,e.ifcProjectId);this._parseSpatialChildren(e,t)}},{key:"_parseSpatialChildren",value:function(e,t,i){var r=this._ifcAPI.GetNameFromTypeCode(t.type);if((!e.includeTypes||e.includeTypes[r])&&(!e.excludeTypes||!e.excludeTypes[r])){this._createMetaObject(e,t,i);var n=t.GlobalId.value;this._parseRelatedItemsOfType(e,t.expressID,"RelatingObject","RelatedObjects",this._webIFC.IFCRELAGGREGATES,n),this._parseRelatedItemsOfType(e,t.expressID,"RelatingStructure","RelatedElements",this._webIFC.IFCRELCONTAINEDINSPATIALSTRUCTURE,n)}}},{key:"_createMetaObject",value:function(e,t,i){var r,n=t.GlobalId.value;r=this.webIfcFroMOutside?this._ifcAPI.GetNameFromTypeCode(t.type):t.__proto__.constructor.name;var s={id:n,name:t.Name&&""!==t.Name.value?t.Name.value:r,type:r,parent:i};e.metadata.metaObjects.push(s),e.metaObjects[n]=s,e.stats.numMetaObjects++}},{key:"_parseRelatedItemsOfType",value:function(e,t,i,r,n,s){for(var o=this,a=this._ifcAPI.GetLineIDsWithType(e.modelID,n),l=0;l<a.size();l++){var u=a.get(l),c=this._ifcAPI.GetLine(e.modelID,u);if(null==c)return;var h=c[i],A=!1;if(Array.isArray(h))A=h.map(function(e){return e.value}).includes(t);else A=h.value===t;if(A){var d=c[r];if(Array.isArray(d))d.forEach(function(t){var i=o._ifcAPI.GetLine(e.modelID,t.value);null!=i&&o._parseSpatialChildren(e,i,s)});else{var p=this._ifcAPI.GetLine(e.modelID,d.value);if(null==p)return;this._parseSpatialChildren(e,p,s)}}}}},{key:"_parsePropertySets",value:function(e){this.log("start parse property...");for(var t=this._ifcAPI.GetLineIDsWithType(e.modelID,this._webIFC.IFCRELDEFINESBYPROPERTIES),i=0;i<t.size();i++){var r=t.get(i),n=this._ifcAPI.GetLine(e.modelID,r,!0);if(n){var s=n.RelatingPropertyDefinition;if(!s)continue;var o=s.GlobalId.value,a=s.HasProperties;if(a&&a.length>0){for(var l=s.Name.value,u=[],c=0,h=a.length;c<h;c++){var A=a[c],d=A.Name,p=A.NominalValue;if(d&&p){var f={name:d.value,type:p.type,value:p.value,valueType:p.valueType};A.Description?f.description=A.Description.value:p.description&&(f.description=p.description),u.push(f)}}var g={id:o,type:"Default",name:l,properties:u};e.metadata.propertySets.push(g),e.stats.numPropertySets++;var m=n.RelatedObjects;if(!m||0===m.length)return;for(var v=0,_=m.length;v<_;v++){var y=m[v].GlobalId.value,b=e.metaObjects[y];b&&(b.propertySetIds||(b.propertySetIds=[]),b.propertySetIds.push(o))}}}}}},{key:"_parseGeometry",value:function(e){var t=this;this.log("start parse geometry"),this._ifcAPI.StreamAllMeshes(e.modelID,function(i){var r=i.expressID,n=i.geometries,s=[],o=t._ifcAPI.GetLine(e.modelID,r);if(null!=o){var a=o.GlobalId.value;if(e.loadMetadata){var l=a,u=e.metaObjects[l];if(e.includeTypes&&(!u||!e.includeTypes[u.type]))return;if(e.excludeTypes&&(!u||e.excludeTypes[u.type]))return}for(var c=Y.mat4(),h=Y.vec3(),A=0,d=n.size();A<d;A++){for(var p=n.get(A),f=t._ifcAPI.GetGeometry(e.modelID,p.geometryExpressID),g=t._ifcAPI.GetVertexArray(f.GetVertexData(),f.GetVertexDataSize()),m=t._ifcAPI.GetIndexArray(f.GetIndexData(),f.GetIndexDataSize()),v=new Float64Array(g.length/2),_=new Float32Array(g.length/2),y=0,b=0,w=g.length/6;y<w;y++,b+=3)v[b+0]=g[6*y+0],v[b+1]=g[6*y+1],v[b+2]=g[6*y+2];c.set(p.flatTransformation),Y.transformPositions3(c,v);var x=we(v,v,h);if(!e.options.autoNormals)for(var B=0,P=0,C=g.length/6;B<C;B++,P+=3)_[P+0]=g[6*B+3],_[P+1]=g[6*B+4],_[P+2]=g[6*B+5];e.stats.numGeometries++,e.stats.numVertices+=v.length/3,e.stats.numTriangles+=m.length/3;var M="mesh"+e.nextId++;e.sceneModel.createMesh({id:M,primitive:"triangles",origin:x?h:null,positions:v,normals:e.options.autoNormals?null:_,indices:m,color:[p.color.x,p.color.y,p.color.z],opacity:p.color.w}),s.push(M)}var k=e.options.globalizeObjectIds?Y.globalizeObjectId(e.sceneModel.id,a):a;e.sceneModel.createEntity({id:k,meshIds:s,isObject:!0}),e.stats.numObjects++}}),this._ifcAPI.StreamAllMeshesWithTypes(e.modelID,[3856911033],function(i,r,n){var s=i.expressID,o=t._ifcAPI.GetLine(e.modelID,s);if(null!=o){for(var a=o.GlobalId.value,l=i.geometries,u=[],c=Y.mat4(),h=Y.vec3(),A=0,d=l.size();A<d;A++){for(var p=l.get(A),f=t._ifcAPI.GetGeometry(e.modelID,p.geometryExpressID),g=t._ifcAPI.GetVertexArray(f.GetVertexData(),f.GetVertexDataSize()),m=t._ifcAPI.GetIndexArray(f.GetIndexData(),f.GetIndexDataSize()),v=new Float64Array(g.length/2),_=new Float32Array(g.length/2),y=0,b=0,w=g.length/6;y<w;y++,b+=3)v[b+0]=g[6*y+0],v[b+1]=g[6*y+1],v[b+2]=g[6*y+2];c.set(p.flatTransformation),Y.transformPositions3(c,v);var x=we(v,v,h);if(!e.options.autoNormals)for(var B=0,P=0,C=g.length/6;B<C;B++,P+=3)_[P+0]=g[6*B+3],_[P+1]=g[6*B+4],_[P+2]=g[6*B+5];e.stats.numGeometries++,e.stats.numVertices+=v.length/3,e.stats.numTriangles+=m.length/3;var M="mesh"+e.nextId++;e.sceneModel.createMesh({id:M,primitive:"triangles",origin:x?h:null,positions:v,normals:e.options.autoNormals?null:_,indices:m,color:[p.color.x,p.color.y,p.color.z],opacity:p.color.w<1?p.color.w:.1}),u.push(M)}var k=e.options.globalizeObjectIds?Y.globalizeObjectId(e.sceneModel.id,a):a;e.sceneModel.createEntity({id:k,meshIds:u,isObject:!0}),e.stats.numObjects++}})}}])}();const Lk={ch:{NavCube:{front:"前",back:"后",top:"上",bottom:"下",left:"左",right:"右"},modelsExplorer:{title:"模型",loadAll:"加载全部",loadAllTip:"加载项目中的所有模型",unloadAll:"卸载全部",unloadAllTip:"卸载所有模型",add:"添加",addTip:"添加模型"},objectsExplorer:{title:"对象",showAll:"显示全部",showAllTip:"显示所有对象",hideAll:"隐藏全部",hideAllTip:"隐藏所有对象"},classesExplorer:{title:"类别",showAll:"显示全部",showAllTip:"显示所有类别",hideAll:"隐藏全部",hideAllTip:"隐藏所有类别"},storeysExplorer:{title:"楼层",showAll:"显示全部",showAllTip:"显示所有楼层",hideAll:"隐藏全部",hideAllTip:"隐藏所有楼层"},propertiesInspector:{title:"属性",noObjectSelectedWarning:"未选中任何对象。右键单击或长按对象,并选择“检查属性”以在此查看其属性。",noPropSetWarning:"未找到此对象的属性集。"},toolbar:{toggleExplorer:"结构树",toggleProperties:"属性",resetViewTip:"重置视图",toggle2d3dTip:"2D/3D",togglePerspectiveTip:"透视/正交",viewFitTip:"适合视图",firstPersonTip:"第一人称",hideObjectsTip:"隐藏对象",annotationObjectsTip:"标注对象",selectObjectsTip:"选择对象",queryObjectsTip:"查询对象",sliceObjectsTip:"切片对象",slicesMenuTip:"切片菜单",showSpacesTip:"显示空间",numSlicesTip:"现有切片数"}},en:{NavCube:{front:"Front",back:"Back",top:"Top",bottom:"Bottom",left:"Left",right:"Right"},modelsExplorer:{title:"Models",loadAll:"Load all",loadAllTip:"Load all models in this project",unloadAll:"Unload all",unloadAllTip:"Unload all models",add:"Add",addTip:"Add a Model"},objectsExplorer:{title:"Objects",showAll:"Show all",showAllTip:"Show all objects",hideAll:"Hide all",hideAllTip:"Hide all objects"},classesExplorer:{title:"Classes",showAll:"Show all",showAllTip:"Show all classes",hideAll:"Hide all",hideAllTip:"Hide all classes"},storeysExplorer:{title:"Storeys",showAll:"Show all",showAllTip:"Show all storeys",hideAll:"Hide all",hideAllTip:"Hide all storeys"},propertiesInspector:{title:"Properties",noObjectSelectedWarning:"No object inspected. Right-click or long-tab an object and select 'Inspect Properties' to view its properties here.",noPropSetWarning:"No property sets found for this object."},toolbar:{toggleExplorer:"Toggle explorer",toggleProperties:"Toggle properties",resetViewTip:"Reset view",toggle2d3dTip:"Toggle 2D/3D",togglePerspectiveTip:"Toggle Perspective/Ortho",viewFitTip:"View fit",firstPersonTip:"Toggle first person navigation mode",hideObjectsTip:"Hide objects",selectObjectsTip:"Select objects",queryObjectsTip:"Query objects",sliceObjectsTip:"Slice objects",slicesMenuTip:"Slices menu",showSpacesTip:"Show IFCSpaces",numSlicesTip:"Number of existing slices"}},de:{NavCube:{front:"Vorne",back:"Hinten",top:"Oben",bottom:"Unten",left:"Links",right:"Rechts"},modelsExplorer:{title:"Modelle",loadAll:"Alle laden",loadAllTip:"Alle Modelle in diesem Projekt laden",unloadAll:"Alle abwählen",unloadAllTip:"Alle Modelle abwählen",add:"Hinzufügen",addTip:"Modell hinzufügen"},objectsExplorer:{title:"Objekte",showAll:"Alle anzeigen",showAllTip:"Alle Objekte anzeigen",hideAll:"Alle ausblenden",hideAllTip:"Alle Objekte ausblenden"},classesExplorer:{title:"Typen",showAll:"Alle anzeigen",showAllTip:"Alle Typen anzeigen",hideAll:"Alle ausblenden",hideAllTip:"Alle Typen ausblenden"},storeysExplorer:{title:"Stockwerke",showAll:"Alle anzeigen",showAllTip:"Alle Stockwerke anzeigen",hideAll:"Alle ausblenden",hideAllTip:"Alle Stockwerke ausblenden"},propertiesInspector:{title:"Eigenschaften",noObjectSelectedWarning:"Kein Objekt inspiziert. Klicken Sie mit der rechten Maustaste auf ein Objekt oder führen Sie einen langen Tabulator aus und wählen Sie 'Eigenschaften prüfen', um die Eigenschaften des Objekts anzuzeigen.",noPropSetWarning:"Keine Eigenschaftssätze für dieses Objekt gefunden."},toolbar:{toggleExplorer:"Explorer ein- und ausblenden",toggleProperties:"Eigenschaften ein- und ausblenden",resetViewTip:"Ansicht zurücksetzen",toggle2d3dTip:"2D/3D umschalten",togglePerspectiveTip:"Orthogonale/Perspektivische Ansicht umschalten",viewFitTip:"In Ansicht einpassen",firstPersonTip:"Ich-Perspektive umschalten",hideObjectsTip:"Objekte ausblenden",selectObjectsTip:"Objekte auswählen",queryObjectsTip:"Abfrageobjekte",sliceObjectsTip:"Objekte schneiden",slicesMenuTip:"Menü Schnittebenen",showSpacesTip:"IFC-Räume anzeigen",numSlicesTip:"Anzahl der Schnittebenen"}},fr:{NavCube:{front:"Face",back:"Arrière",top:"Dessus",bottom:"Dessous",left:"Droite",right:"Gauche"},modelsExplorer:{title:"Modèles",loadAll:"Afficher tout",loadAllTip:"Afficher tous les modèles du projet",unloadAll:"Masquer tout",unloadAllTip:"Masquer tous les modèles",add:"Ajouter",addTip:"Ajouter un modèle"},objectsExplorer:{title:"Conteneurs",showAll:"Afficher tout",showAllTip:"Afficher tous les objets",hideAll:"Masquer tout",hideAllTip:"Masquer tous les objets"},classesExplorer:{title:"Classes IFC",showAll:"Afficher tout",showAllTip:"Affiche toutes les classes",hideAll:"Masquer tout",hideAllTip:"Masquer toutes les classes"},storeysExplorer:{title:"Étages",showAll:"Afficher tout",showAllTip:"Afficher tous les étages",hideAll:"Masquer tout",hideAllTip:"Masquer tous les étages"},propertiesInspector:{title:"Propriétés",noObjectSelectedWarning:"Aucun objet n'a été inspecté. Cliquez avec le bouton droit ou le bouton long sur un objet et sélectionnez 'Inspecter les propriétés' pour afficher ses propriétés ici.",noPropSetWarning:"Aucun ensemble de propriétés n'a été trouvé pour cet objet."},toolbar:{toggleExplorer:"Afficher la structure",toggleProperties:"Afficher les propriétés",resetViewTip:"Réinitialiser la vue",toggle2d3dTip:"Activer 2D/3D",togglePerspectiveTip:"Activer Perspective/Ortho",viewFitTip:"Recadrer la vue",firstPersonTip:"Mode 1ere personne",hideObjectsTip:"Masquer objets",selectObjectsTip:"Sélectionner",queryObjectsTip:"Informations objets",sliceObjectsTip:"Coupes",slicesMenuTip:"Outils de coupe",showSpacesTip:"Afficher les espaces IFC",numSlicesTip:"Nombre de coupes"}},pl:{NavCube:{front:"Przód",back:"Tył",top:"Góra",bottom:"Dół",left:"Lewy",right:"Prawy"},modelsExplorer:{title:"Model",loadAll:"Załaduj",loadAllTip:"Załaduj wszystkie modele",unloadAll:"Zamknij",unloadAllTip:"Zamnij wszystkie modele",add:"Dodaj",addTip:"Dodaj modele"},objectsExplorer:{title:"Obiekty",showAll:"Pokaż",showAllTip:"Pokaż wszystkie obiekty",hideAll:"Ukryj",hideAllTip:"Ukryj wszystkie obiekty"},classesExplorer:{title:"Typy",showAll:"Pokaż",showAllTip:"Pokaż wszystkie typy",hideAll:"Ukryj",hideAllTip:"Ukryj wszystkie typy"},storeysExplorer:{title:"Piętra",showAll:"Pokaż",showAllTip:"Pokaż wszystkie piętra",hideAll:"Ukryj",hideAllTip:"Ukryj wszystkie piętra"},propertiesInspector:{title:"Właściwości",noObjectSelectedWarning:"Nie sprawdzono żadnego obiektu. Kliknij prawym przyciskiem myszy lub kliknij długo na obiekcie i wybierz opcję 'Sprawdź właściwości', aby wyświetlić jego właściwości.",noPropSetWarning:"Nie znaleziono żadnych zestawów właściwości dla tego obiektu."},toolbar:{toggleExplorer:"Przełączanie eksploratora",toggleProperties:"Przełączanie właściwości",resetViewTip:"Resetuj widok",toggle2d3dTip:"Widok 2D/3D",togglePerspectiveTip:"Widok Ortograficzny/Perspektywiczny",viewFitTip:"Dopasowanie do widoku",firstPersonTip:"Widok perspektywy pierwszoosobowej",hideObjectsTip:"Ukryj obiekt",selectObjectsTip:"Zaznacz obiekt",queryObjectsTip:"Wywołaj obiekt",sliceObjectsTip:"Przekroje obiektów",slicesMenuTip:"Menu przekroi",showSpacesTip:"Pokaż przestrzenie IFC",numSlicesTip:"Liczba przekroi"}},ru:{NavCube:{front:"Фронт",back:"Тыл",top:"Верх",bottom:"Низ",left:"Лево",right:"Право"},modelsExplorer:{title:"Модели",loadAll:"Загрузить все",loadAllTip:"Загрузить все модели в этом проекте",unloadAll:"Выгрузить все",unloadAllTip:"Выгрузить все модели",add:"Добавить",addTip:"Добавить модель"},objectsExplorer:{title:"Объекты",showAll:"Показать все",showAllTip:"Показать все объекты",hideAll:"Скрыть все",hideAllTip:"Скрыть все объекты"},classesExplorer:{title:"Классы",showAll:"Показать все",showAllTip:"Показать все классы",hideAll:"Скрыть все",hideAllTip:"Скрыть все классы"},storeysExplorer:{title:"Этажи",showAll:"Показать все",showAllTip:"Показать все этажи",hideAll:"Скрыть все",hideAllTip:"Скрыть все этажи"},propertiesInspector:{title:"Свойства",noObjectSelectedWarning:"Ни один объект не осмотрен. Щелкните правой кнопкой мыши или длинной меткой на объекте и выберите 'Осмотреть свойства', чтобы просмотреть его свойства здесь.",noPropSetWarning:"Для этого объекта не найдено ни одного набора свойств."},toolbar:{toggleExplorer:"Переключить навигатор",toggleProperties:"Переключить Свойства",resetViewTip:"Сбросить вид",toggle2d3dTip:"Переключить 2D/3D",togglePerspectiveTip:"Переключить проекцию перспектива/орто",viewFitTip:"Показать всю модель",firstPersonTip:"Переключить режим навигации от первого лица",hideObjectsTip:"Скрыть объекты",selectObjectsTip:"Выбрать объекты",queryObjectsTip:"Выбрать объекты",sliceObjectsTip:"Рассечь объекты",slicesMenuTip:"Меню сечений",showSpacesTip:"Показать места IFC",numSlicesTip:"Количество существующих сечений"}}};class jk{constructor(){this.events={}}on(e,t){this.events[e]||(this.events[e]=[]),this.events[e].push(t)}off(e,t){this.events[e]&&(this.events[e]=this.events[e].filter(e=>e!==t))}emit(e,...t){this.events[e]&&this.events[e].forEach(e=>{e(...t)})}destroy(){this.events={}}}class Uk{constructor(e=[],t=0){this.items=[],this._lastUniqueId=0,this.items=e||[],this._lastUniqueId=(t||0)+1}addItem(...e){let t;if(2===e.length){const i=e[0];if(t=e[1],this.items[i])throw new Error(`ID clash: '${i}'`);return this.items[i]=t,i}for(t=e[0]||{};;){this._lastUniqueId+=1;const e=this._lastUniqueId;if(!this.items[e])return this.items[e]=t,e}}removeItem(e){const t=this.items[e];return delete this.items[e],t}}class Nk{constructor(e,t={},i=null,r=null){this._children=[],this._subIdMap=null,this._subIdEvents=null,this._eventSubs=null,this._events=null,this._eventCallDepth=0,this._enabled=null,this._active=null,this.destroyed=!1,this.bimViewer=e?e.bimViewer||e:this,this.server=e?e.server:i,this.viewer=e?e.viewer:r,e&&e._children.push(this)}fire(e,t,i=!1){this._events||(this._events={}),this._eventSubs||(this._eventSubs={}),!0!==i&&(this._events[e]=t||!0);const r=this._eventSubs[e];let n;r&&Object.keys(r).forEach(i=>{Object.prototype.hasOwnProperty.call(r,i)&&(n=r[i],this._eventCallDepth+=1,this._eventCallDepth<300?n.callback.call(n.scope,t):this.error(`fire: potential stack overflow from recursive event ${e} - dropping this event`),this._eventCallDepth-=1)})}on(e,t,i=this){this._events||(this._events={}),this._subIdMap||(this._subIdMap=new Uk),this._subIdEvents||(this._subIdEvents={}),this._eventSubs||(this._eventSubs={});let r=this._eventSubs[e];r||(r={},this._eventSubs[e]=r);const n=this._subIdMap.addItem();r[n]={callback:t,scope:i||this},this._subIdEvents[n]=e;const s=this._events[e];return void 0!==s&&t.call(i||this,s),n}off(e){if(null==e)return;if(!this._subIdEvents)return;const t=this._subIdEvents[e];if(t){delete this._subIdEvents[e];const i=this._eventSubs[t];i&&delete i[e],this._subIdMap.removeItem(e)}}once(e,t,i=this){const r=this,n=this.on(e,e=>{r.off(n),t.call(i||this,e)},i)}log(e){e=`[LOG] ${e}`,console.log(e)}warn(e){e=`[LOG] ${e}`,window.console.warn(e)}error(e){e=`[LOG] ${e}`,window.console.error(e)}_mutexActivation(e){e.forEach((t,i)=>{t.on("active",t=>{t&&e.forEach((e,t)=>{t!==i&&e.setActive(!1)})})})}setEnabled(e){this._enabled!==e&&(this._enabled=e,this.fire("enabled",this._enabled))}getEnabled(){return this._enabled}setActive(e){this._active!==e&&(this._active=e,this.fire("active",this._active))}getActive(){return this._active}destroy(){this.destroyed||(this.fire("destroyed",this.destroyed=!0),this._subIdMap=null,this._subIdEvents=null,this._eventSubs=null,this._events=null,this._eventCallDepth=0,this._children.forEach(e=>{e.destroy()}),this._children=[])}}const Vk=Y.vec3();class Qk extends Nk{constructor(e,t={}){super(e,t),this._modelMementos={},this.bimViewer.modelsExplorer.on("modelLoaded",e=>{this.reset()})}reset(e){this._resetCamera(e)}_resetCamera(e){const{viewer:t}=this,{scene:i}=t;let r;r=this.bimViewer.multiModel?i.getAABB(i.visibleObjectIds):i.aabb;const n=Y.getAABB3Diag(r),s=Y.getAABB3Center(r,Vk),{camera:o}=i;o.perspective.fov;const a=Math.abs(n/Math.tan(45*Y.DEGTORAD)),l=Y.normalizeVec3(o.yUp?[-.5,-.7071,-.5]:[-1,1,-1]),u=Y.normalizeVec3(o.yUp?[-.5,.7071,-.5]:[-1,1,1]);t.cameraControl.pivotPos=s,t.cameraControl.planView&&(t.cameraControl.planView=!1),t.cameraFlight.flyTo({look:s,eye:[s[0]-a*l[0],s[1]-a*l[1],s[2]-a*l[2]],up:u,orthoScale:1.3*n,projection:"perspective",duration:1},e)}}Y.vec3();class Hk extends Nk{constructor(e,t={}){super(e,t)}fit(e){const{viewer:t}=this,{scene:i}=t,{center:r}=i;let n;n=this.bimViewer.multiModel?i.getAABB(i.visibleObjectIds):i.aabb;const s=Y.getAABB3Diag(n);t.cameraControl.pivotPos=r,t.cameraControl.planView&&(t.cameraControl.planView=!1),t.cameraFlight.flyTo({aabb:n,orthoScale:1.3*s,duration:1},e)}set fov(e){this.viewer.scene.cameraFlight.fitFOV=e}get fov(){return this.viewer.scene.cameraFlight.fitFOV}set duration(e){this.viewer.scene.cameraFlight.duration=e}get duration(){return this.viewer.scene.cameraFlight.duration}}class Gk extends Nk{constructor(e,t){super(e,t);const{cameraControl:i}=this.viewer,{cameraControlNavModeMediator:r}=t;i.navMode="orbit",i.followPointer=!0,this.cameraControl=i,i.on("personModeSpeedUp",t=>{e.eventTrigger.emit("personModeSpeedUp",t)}),i.on("personModeSpeedDown",t=>{e.eventTrigger.emit("personModeSpeedDown",t)}),this.on("active",e=>{r.setFirstPersonModeActive(e),e&&(i.followPointer=!0)}),this.bimViewer.on("closeAll",()=>{this.setActive(!1)})}setdirectionChangeCancel(){this.goLeft=!1,this.goRight=!1,this.goUp=!1,this.goDown=!1,this.goForward=!1,this.goBackward=!1}speedUp(){this.cameraControl.speedUp()}speedDown(){this.cameraControl.speedDown()}set moveRate(e){this.cameraControl.moveRate=e}get moveRate(){return this.cameraControl.moveRate}set goRight(e){this.cameraControl.goRight=e}set goLeft(e){this.cameraControl.goLeft=e}set goUp(e){this.cameraControl.goUp=e}set goDown(e){this.cameraControl.goDown=e}set goForward(e){this.cameraControl.goForward=e}set goBackward(e){this.cameraControl.goBackward=e}smallCanvas(){const e=new W_({spinnerElementId:"manyou_spinner",canvasId:"canvas_manyou",transparent:!0,resolutionScale:window.devicePixelRatio});e.camera.eye=[-3.933,2.855,27.018],e.camera.look=[4.4,3.724,8.899],e.camera.up=[-.018,.999,.039]}}class zk extends Nk{constructor(e,t){super(e,t),this.on("active",e=>{e?(this.viewer.cameraControl.doublePickFlyTo=!1,this._onPick=this.viewer.cameraControl.on("picked",e=>{e.entity&&(e.entity.visible=!1)})):(this.viewer.cameraControl.doublePickFlyTo=!1,void 0!==this._onPick&&(this.viewer.cameraControl.off(this._onPick),this._onPick=void 0))}),this.bimViewer.on("closeAll",()=>{this.setActive(!1)})}}class Wk extends Nk{constructor(e,t){super(e,t),this._active=!0,e.eventTrigger.on("metaLoaded",t=>{const i=this.spaceObjects;if(0==i.length)return;this.viewer.scene.setObjectsCulled(i,!0),this.setIFCSpaceOpacity(),this.viewer.scene.setObjectsHighlighted(i,!0);const r=this.viewer.scene.models[t.metaModel.id],n=r.exceptionIds.concat(i);r.exceptionIds=n,e.resetView()})}setActive(e,t){this._active!==e&&(this._active=e,e?(this._enterShowSpacesMode(),this.fire("active",this._active)):(this._exitShowSpacesMode(),this.fire("active",this._active)),t&&t())}setIFCSpaceOpacity(){0!=this.spaceObjects.length&&this.viewer.scene.withObjects(this.spaceObjects,e=>{-1!=e.origin_opacity&&(e.opacity=e.opacity<.5?e.opacity:.1)})}_enterShowSpacesMode(){const{viewer:e}=this,{scene:t}=e,{metaScene:i}=e,r=i.getObjectIDsByType("IfcSpace");t.setObjectsCulled(r,!1)}_exitShowSpacesMode(){const{viewer:e}=this,{scene:t}=e,{metaScene:i}=e,r=i.getObjectIDsByType("IfcSpace");t.setObjectsCulled(r,!0)}get spaceObjects(){return this.viewer.metaScene.getObjectIDsByType("IfcSpace")}}class Kk extends Nk{constructor(e,t){super(e,t),this.eventTrigger=e.eventTrigger,this._sectionPlanesPlugin=new yk(this.viewer,{}),this._sectionPlanesPlugin.sectionConfigs={planeSize:1.4,controlSize:.2,planeOpacity:.2,controlFillColor:[.1,.4,.99]},this._sectionPlanesPlugin.setOverviewVisible(!1),this._sectionPlanesPlugin.on("touchPlaneStart",()=>{this.eventTrigger.emit("touchPlaneStart")}),this._sectionPlanesPlugin.on("touchPlaneEnd",()=>{this.eventTrigger.emit("touchPlaneEnd")}),this._sectionPlanesPlugin.on("clickPlaneStart",()=>{this.eventTrigger.emit("clickPlaneStart")}),this._sectionPlanesPlugin.on("clickPlaneEnd",()=>{this.eventTrigger.emit("clickPlaneEnd")}),this._isTouch=!1,this.on("active",e=>{e?this.showControl():this.hideControl()}),this.bimViewer.on("closeAll",()=>{this.setActive(!1)}),this._initSectionMode()}_initSectionMode(){this.viewer.scene.input.on("mouseclicked",e=>{if(!this.getActive())return;const t=this.viewer.scene.pick({canvasPos:e,pickSurface:!0});if(t){const e=this._sectionPlanesPlugin.createSectionPlane({pos:t.worldPos,dir:Y.mulVec3Scalar(t.worldNormal,-1)});this._sectionPlanesPlugin.showControl(e.id),this.eventTrigger.emit("createSection",{position:t.worldPos,direction:Y.mulVec3Scalar(t.worldNormal,-1),id:e.id})}})}set isTouch(e){this._sectionPlanesPlugin.isTouch=e,this._isTouch=e}set sectionWay(e){this._sectionPlanesPlugin.sectionWay=e}set sectionDirection(e){this._sectionPlanesPlugin.sectionDirection=e}setControlPos(e){this._sectionPlanesPlugin.setControlPos(e)}getControlPos(){return this._sectionPlanesPlugin.getControlPos()}set sectionConfigs(e){this._sectionPlanesPlugin.sectionConfigs=e}creatSection(e,t){const i=this._sectionPlanesPlugin.createSectionPlane({pos:e,dir:t});this._sectionPlanesPlugin.showControl(i.id)}getSectionPlanes(){return this._sectionPlanesPlugin.sectionPlanes}getSectionPlane(e){return this.getSectionPlanes()[e]}setSectionEnable(e){this.getSectionPlane(e).active=!0}setSectionDisable(e){this.getSectionPlane(e).active=!1}setSectionPos(e,t){this.getSectionPlane(e).pos=t}flipSection(e){this.getSectionPlane(e).flipDir()}getNumSections(){return Object.keys(this.viewer.scene.sectionPlanes).length}clear(){this._sectionPlanesPlugin.clear()}flipSections(){this._sectionPlanesPlugin.flipSectionPlanes()}getShownControl(){this._sectionPlanesPlugin.getShownControl()}enableSections(){const{sectionPlanes:e}=this.viewer.scene;for(const t in e){e[t].active=!0}}disableSections(){const{sectionPlanes:e}=this.viewer.scene;for(const t in e){e[t].active=!1,this.hideControl()}}hideControl(){this._sectionPlanesPlugin.hideControl()}showControl(){const e=this.getSectionPlanes();for(const t in e)e[t].control.setVisible(!0)}showSectionPlane(e){this._sectionPlanesPlugin.showControl(e)}destroy(){this._sectionPlanesPlugin.destroy(),super.destroy()}destroySectionPlane(e){this._sectionPlanesPlugin.destroySectionPlane(e)}}class Xk extends Nk{constructor(e,t){if(super(e,t),!t.navCubeCanvasElement)throw new Error("Missing config: NavCubeMode navCubeCanvasElement");const{navCubeCanvasElement:i}=t,{viewerElement:r}=t;this._navCubeCanvasElement=i,this._navCubeCanvasElement.oncontextmenu=e=>{e.preventDefault()},this._navCube=new tk(this.viewer,{canvasElement:i,viewerElement:r,fitVisible:!1,color:"#CFCFCF",shadowVisible:!1}),this._navCube.setVisible(this._active),this._visible=!0,this.on("active",e=>{this._navCube.setVisible(e)})}set visible(e){this._visible=e,this._navCubeCanvasElement.style.visibility=e?"visible":"hidden"}get visible(){return this._visible}get fitVisible(){return this._navCube.getFitVisible()}set fitVisible(e){this._navCube.setFitVisible(e)}flyByClick(e){this._navCube.flyByClick(e)}destroy(){this._navCube.destroy(),super.destroy()}}let qk;class Yk{constructor(e,t){this._projectId="",this._modelId="",this._server=e,qk=t.tempVec3a}setProjectId(e){this._projectId=e}setModelId(e){this._modelId=e}getManifest(e,t,i){this._server.getSplitModelManifest(this._projectId,this._modelId,e,t,i)}getMetaModel(e,t,i){this._server.getSplitModelMetadata(this._projectId,this._modelId,e,t,i)}getXTC(e,t,i){this._server.getSplitModelGeometry(this._projectId,this._modelId,e,t,i)}}class Jk extends Nk{constructor(e,t){super(e,t),this._modelFromOutSide=t.modelFromOutSide,this._projectId=t.projectId,this._modelType=t.modelType,this._modelSrc=t.modelSrc,this._eventTrigger=e.eventTrigger,this._dataSource=new Yk(this.server,{tempVec3a:t.tempVec3a}),this._modelConfig=t.modelConfig,this._modelsInfo={},this._numModels=0,this._numModelsLoaded=0}getModelIds(){return Object.keys(this._modelsInfo)}getModelInfo(e){return this._modelsInfo[e]}loadModel(e,t,i=()=>{},r=()=>{},n){if(this._modelType=n.modelType,"ifc"==this._modelType){const i=void 0!==n.IfcAPI&&null!==n.IfcAPI,r=void 0!==n.WebIFC&&null!==n.WebIFC;i&&r&&this.log("载入外部传入webifc..."),this._ifcLoader=new Ok(this.viewer,i&&r?{WebIFC:n.WebIFC,IfcAPI:n.IfcAPI}:{}),this._modelsInfo[e]={id:e,ifc:t,metaBuffer:null,edges:!0,loadMetadata:!1,saoEnabled:!0,pbrEnabled:!0,dtxEnabled:!0}}else"xtc"==this._modelType?(this._xtcLoader=new Dk(this.viewer,{dataSource:this._dataSource}),this._xtcLoader.on("metaLoaded",e=>{this._eventTrigger.emit("metaLoaded",e)}),this._xtcLoader.on("metaLoading",e=>{this._eventTrigger.emit("metaLoading",e)}),this._modelsInfo[e]={id:e,xtc:t,metaBuffer:null,edges:!0,loadMetadata:!1,saoEnabled:!0,pbrEnabled:!0,dtxEnabled:!0}):"glb"==this._modelType&&(this._glbLoader=new JM(this.viewer),this._modelsInfo[e]={id:e,gltf:t,metaBuffer:null,edges:!0,loadMetadata:!1,saoEnabled:!0,pbrEnabled:!0,dtxEnabled:!0});this._loadGeometry(e,i,r)}unloadModel(e){const t=this.viewer.scene.models[e];t?(t.destroy(),this.fire("modelUnloaded",e)):this.error("Model not loaded: "+e)}loadMetadata(e,t,i,r){this._xtcLoader&&(this._modelsInfo[e]&&(this._modelsInfo[e].metaBuffer=t),this._xtcLoader.loadMetadata(this.viewer.metaScene.metaModels[e],t,i,r))}_loadGeometry(e,t,i){const r=this._modelsInfo[e],n=()=>{this._jumpToInitialCamera(),this.fire("modelLoaded",e),t&&t()},s=e=>{this.error(e),i&&i(e)};if("ifc"==this._modelType&&this._ifcLoader)if(this._modelFromOutSide){this.log("正在载入ifc模型...");const e=this._ifcLoader.load(r);e.on("loaded",n),e.on("error",s)}else{this.log("正在载入引擎从本地获取的ifc模型...");const t=this._ifcLoader.load({id:e,src:this._modelSrc,edges:r.edges,loadMetadata:!1,pbrEnabled:r.pbrEnabled,dtxEnabled:r.dtxEnabled});t.on("loaded",n),t.on("error",s)}else if("xtc"===this._modelType&&this._xtcLoader){if(this._modelFromOutSide){this.log("正在载入xtc模型...");const e=this._xtcLoader.load(r);e.on("loaded",n),e.on("error",s)}}else if("glb"===this._modelType&&this._glbLoader&&this._modelFromOutSide){this.log("正在载入glb模型...");const e=this._glbLoader.load(r);e.on("loaded",n),e.on("error",s)}}_jumpToInitialCamera(){const{viewer:e}=this,{scene:t}=e,i=t.getAABB(t.visibleObjectIds),r=Y.getAABB3Diag(i),n=Y.getAABB3Center(i,qk),{camera:s}=t,o=Math.abs(r/Math.tan(45*Y.DEGTORAD)),a=Y.normalizeVec3(s.yUp?[-.5,-.7071,-.5]:[-1,1,-1]),l=Y.normalizeVec3(s.yUp?[-.5,.7071,-.5]:[-1,1,1]);e.cameraControl.pivotPos=n,e.cameraControl.planView&&(e.cameraControl.planView=!1),e.cameraFlight.jumpTo({look:n,eye:[n[0]-o*a[0],n[1]-o*a[1],n[2]-o*a[2]],up:l,orthoScale:1.1*r})}destroy(){super.destroy(),this._xtcLoader&&this._xtcLoader.destroy(),this._ifcLoader&&this._ifcLoader.destroy(),this._glbLoader&&this._glbLoader.destroy()}}class Zk extends Nk{constructor(e,t={}){super(e);const{modelType:i}=t;this.eventTrigger=e.eventTrigger,this._treeView=new xk(this.viewer,{hierarchy:"containment",autoAddModels:!1,pruneEmptyNodes:!0,autoExpandDepth:1}),this._treeView.on("rootNodes_Created",e=>{this._rootNode=e,this.eventTrigger.emit("object_rootNodes",e)}),this._treeView.on("nodeNodes_Created",e=>{this._nodeList=e,this.eventTrigger.emit("object_nodeNodes",e)}),this._treeView.on("objectNodes_Created",e=>{this._objectList=e,this.eventTrigger.emit("object_objectNodes",e)}),this._treeView.on("checkBoxChanged",e=>{this.eventTrigger.emit("object_checkBoxChanged",e)}),"ifc"===i?this._onModelLoaded=this.viewer.scene.on("modelLoaded",e=>{this._treeView.addModel(e,{rootName:e})}):this._onMetaDataLoaded=this.eventTrigger.on("metaLoaded",e=>{"success"===e.result&&(this._treeView.addModel(e.metaModel.id,{rootName:e.metaModel.id}),this.eventTrigger.emit("treeReady"))}),this._onModelUnloaded=this.viewer.scene.on("modelUnloaded",e=>{this.viewer.metaScene.metaModels[e]&&this._treeView.removeModel(e)})}get rootNode(){return this._rootNode}get nodesList(){return this._nodeList}get objectList(){return this._objectList}get treeView(){return this._treeView}getNodeIdByObjectId(e){if(null==this._objectList[e])return null;this._objectList[e].nodeId}getNodeById(e){return this._treeView.getNodeById(e)}getChildrenById(e){this._treeView.getChildrenById(e)}setEnabled(e){}destroy(){super.destroy(),this._treeView.destroy(),this.viewer.scene.off(this._onModelLoaded),this.viewer.scene.off(this._onModelUnloaded),this.viewer.scene.off(this._onMetaDataLoaded)}}class $k extends Nk{constructor(e,t={}){super(e),this.eventTrigger=e.eventTrigger;const{modelType:i}=t;this._treeView=new xk(this.viewer,{hierarchy:"types",autoAddModels:!1,pruneEmptyNodes:!0,autoExpandDepth:1}),this._treeView.on("rootNodes_Created",e=>{this._rootNode=e,this.eventTrigger.emit("classes_rootNodes",e)}),this._treeView.on("nodeNodes_Created",e=>{this._nodeList=e,this.eventTrigger.emit("classes_nodeNodes",e)}),this._treeView.on("objectNodes_Created",e=>{this._objectList=e,this.eventTrigger.emit("classes_objectNodes",e)}),this._treeView.on("checkBoxChanged",e=>{this.eventTrigger.emit("classes_checkBoxChanged",e)}),"ifc"===i?this._onModelLoaded=this.viewer.scene.on("modelLoaded",e=>{this._treeView.addModel(e,{rootName:e})}):this._onMetaDataLoaded=this.eventTrigger.on("metaLoaded",e=>{"success"===e.result&&(this._treeView.addModel(e.metaModel.id,{rootName:e.metaModel.id}),this.eventTrigger.emit("treeReady"))}),this._onModelUnloaded=this.viewer.scene.on("modelUnloaded",e=>{this.viewer.metaScene.metaModels[e]&&this._treeView.removeModel(e)})}get rootNode(){return this._rootNode}get nodesList(){return this._nodeList}get objectList(){return this._objectList}getNodeIdByObjectId(e){return null!=this._objectList[e]?this._objectList[e].nodeId:null}getNodeById(e){return this._treeView.getNodeById(e)}getChildrenById(e){this._treeView.getChildrenById(e)}checkboxChangeHandler(e,t){const i=this._nodeList[e],r=t,{objects:n}=this.viewer.scene;let s=0;this._treeView.withNodeTree(i,e=>{const{objectId:t}=e,i=n[t],o=0===e.children.length;e.numVisibleEntities=r?e.numEntities:0,o&&r!==e.checked&&s++,e.checked=r,i&&(i.visible=r)});let{parent:o}=i;for(;o;)o.checked=r,r?o.numVisibleEntities+=s:o.numVisibleEntities-=s,o=o.parent}nodeTitleClicked(e){const{scene:t}=this.viewer,i=this._nodeList[e],r=[];this._treeView.withNodeTree(i,e=>{e.objectId&&r.push(e.objectId)});const{checked:n}=i;n?(t.setObjectsXRayed(r,!1),t.setObjectsVisible(r,!1),t.setObjectsPickable(r,!0)):(t.setObjectsXRayed(r,!1),t.setObjectsVisible(r,!0),t.setObjectsPickable(r,!0))}setEnabled(e){}expandTreeViewToDepth(e){}showNodeInTreeView(e){this._treeView.showNode(e)}unShowNodeInTreeView(){this._treeView.unShowNode()}destroy(){super.destroy(),this._treeView.destroy(),this.viewer.scene.off(this._onModelLoaded),this.viewer.scene.off(this._onModelUnloaded),this.viewer.scene.off(this._onMetaDataLoaded)}get treeView(){return this._treeView}}const eE=Y.vec3();class tE extends Nk{constructor(e,t={}){super(e);const{modelType:i}=t;this.eventTrigger=e.eventTrigger,this._treeView=new xk(this.viewer,{hierarchy:"storeys",autoAddModels:!1,autoExpandDepth:1}),this._treeView.on("rootNodes_Created",e=>{this._rootNode=e,this.eventTrigger.emit("storeys_rootNodes",e)}),this._treeView.on("nodeNodes_Created",e=>{this._nodeList=e,this.eventTrigger.emit("storeys_nodeNodes",e)}),this._treeView.on("objectNodes_Created",e=>{this._objectList=e,this.eventTrigger.emit("storeys_objectNodes",e)}),this._treeView.on("checkBoxChanged",e=>{this.eventTrigger.emit("storeys_checkBoxChanged",e)}),"ifc"===i?this._onModelLoaded=this.viewer.scene.on("modelLoaded",e=>{this._treeView.addModel(e,{rootName:e})}):this._onMetaDataLoaded=this.eventTrigger.on("metaLoaded",e=>{"success"===e.result&&(this._treeView.addModel(e.metaModel.id,{rootName:e.metaModel.id}),this.eventTrigger.emit("treeReady"))}),this._onModelUnloaded=this.viewer.scene.on("modelUnloaded",e=>{this.viewer.metaScene.metaModels[e]&&this._treeView.removeModel(e)})}get rootNode(){return this._rootNode}get nodesList(){return this._nodeList}get objectList(){return this._objectList}getNodeIdByObjectId(e){if(null==this._objectList[e])return null;this._objectList[e].nodeId}getNodeById(e){return this._treeView.getNodeById(e)}getChildrenById(e){this._treeView.getChildrenById(e)}checkboxChangeHandler(e,t){const i=this._nodeList[e],r=t,{objects:n}=this.viewer.scene;let s=0;this._treeView.withNodeTree(i,e=>{const{objectId:t}=e,i=n[t],o=0===e.children.length;e.numVisibleEntities=r?e.numEntities:0,o&&r!==e.checked&&s++,e.checked=r,i&&(i.visible=r)});let{parent:o}=i;for(;o;)o.checked=r,r?o.numVisibleEntities+=s:o.numVisibleEntities-=s,o=o.parent}nodeTitleClicked(e){const{scene:t}=this.viewer,i=this._nodeList[e],r=[];this._treeView.withNodeTree(i,e=>{e.objectId&&r.push(e.objectId)});const{checked:n}=i;n?(t.setObjectsXRayed(r,!1),t.setObjectsVisible(r,!1),t.setObjectsPickable(r,!0)):(t.setObjectsXRayed(r,!1),t.setObjectsVisible(r,!0),t.setObjectsPickable(r,!0))}setEnabled(e){}_selectObjects(e,t){const{scene:i}=this.viewer,r=i.getAABB(e);this.viewer.cameraControl.pivotPos=Y.getAABB3Center(r,eE),t?(i.setObjectsXRayed(i.objectIds,!0),i.setObjectsVisible(i.objectIds,!0),i.setObjectsPickable(i.objectIds,!1),i.setObjectsSelected(i.selectedObjectIds,!1),i.setObjectsXRayed(e,!1),i.setObjectsVisible(e,!0),i.setObjectsPickable(e,!0),this.viewer.cameraFlight.flyTo({aabb:r},()=>{setTimeout(()=>{i.setObjectsVisible(i.xrayedObjectIds,!1),i.setObjectsXRayed(i.xrayedObjectIds,!1)},500),t()})):(i.setObjectsVisible(i.objectIds,!1),i.setObjectsPickable(i.xrayedObjectIds,!0),i.setObjectsXRayed(i.xrayedObjectIds,!1),i.setObjectsSelected(i.selectedObjectIds,!1),i.setObjectsVisible(e,!0),this.viewer.cameraFlight.jumpTo({aabb:r}))}destroy(){super.destroy(),this._treeView.destroy(),this.viewer.scene.off(this._onModelLoaded),this.viewer.scene.off(this._onModelUnloaded),this.viewer.scene.off(this._onMetaDataLoaded)}expandTreeViewToDepth(e){}showNodeInTreeView(e){this._treeView.showNode(e)}unShowNodeInTreeView(){this._treeView.unShowNode()}selectStorey(e,t){const{metaScene:i}=this.viewer,r=i.metaObjects[e];if(!r)return void this.error(`selectStorey() - object is not found: ${e}`);if("IfcBuildingStorey"!==r.type)return void this.error(`selectStorey() - object is not found: ${e}`);const n=r.getObjectIDsInSubtree();this._selectObjects(n,t)}}const iE=Y.vec3();class rE extends Nk{constructor(e,t){super(e,t),this._saveOrthoActive=null,this._cameraControlNavModeMediator=t.cameraControlNavModeMediator,this._active=!1}setEnabled(e){super.setEnabled(e),this._saveOrthoActive=this.bimViewer.orthoMode.getActive()}setActive(e,t=()=>{}){this._active!==e?(this._active=e,e?this._enterThreeDMode(()=>{this.fire("active",this._active),t&&t()}):this._exitThreeDMode(()=>{this.fire("active",this._active),t&&t()})):t&&t()}_enterThreeDMode(e=()=>{}){const{viewer:t}=this,{scene:i}=t,{aabb:r}=i,n=Y.getAABB3Diag(r),s=Y.getAABB3Center(r,iE),o=Math.abs(n/Math.tan(32.5)),{camera:a}=i,l=a.yUp?[-1,-1,-1]:[1,1,1],u=a.yUp?[-1,1,-1]:[-1,1,1];t.cameraControl.pivotPos=s,this.bimViewer.navCubeMode.setActive(!0),this.bimViewer.firstPersonMode.setEnabled(!0),this._cameraControlNavModeMediator.setThreeDModeActive(!0),this.bimViewer.sectionTool.setEnabled(!0),this.bimViewer.orthoMode.setEnabled(!0),e?t.cameraFlight.flyTo({look:s,eye:[s[0]-o*l[0],s[1]-o*l[1],s[2]-o*l[2]],up:u,orthoScale:1.3*n,duration:1,projection:this._saveOrthoActive?"ortho":"perspective"},()=>{e()}):t.cameraFlight.jumpTo({look:s,eye:[s[0]-o*l[0],s[1]-o*l[1],s[2]-o*l[2]],up:u,orthoScale:1.3*n,projection:this._saveOrthoActive?"ortho":"perspective"})}_exitThreeDMode(e=()=>{}){const{viewer:t}=this,{scene:i}=t,{camera:r}=i,{aabb:n}=i,s=Y.getAABB3Center(n),o=Y.getAABB3Diag(n),a=Math.abs(o/Math.tan(45*Y.DEGTORAD)),l=1.3*o,u=iE;u[0]=s[0]+r.worldUp[0]*a,u[1]=s[1]+r.worldUp[1]*a,u[2]=s[2]+r.worldUp[2]*a;const c=Y.mulVec3Scalar(r.worldForward,-1,[]);this.bimViewer.sectionTool.setActive(!1),this.bimViewer.firstPersonMode.setEnabled(!1),this._saveOrthoActive=this.bimViewer.orthoMode.getActive(),this.bimViewer.orthoMode.setEnabled(!1),this._cameraControlNavModeMediator.setThreeDModeActive(!1),e?t.cameraFlight.flyTo({eye:u,look:s,up:c,orthoScale:l,projection:"ortho"},()=>{this.bimViewer.navCubeMode.setActive(!1)}):(t.cameraFlight.jumpTo({eye:u,look:s,up:c,orthoScale:l,projection:"ortho"}),this.bimViewer.navCubeMode.setActive(!1))}}class nE extends Nk{constructor(e,t){super(e,t),this.viewer.camera.on("projection",()=>{const e="ortho"===this.viewer.camera.projection;this._active=e}),this._active=!1}setActive(e,t=()=>{}){this._active!==e?(this._active=e,e?t?this._enterOrthoMode(()=>{this.fire("active",this._active),t()}):(this._enterOrthoMode(),this.fire("active",this._active)):t?this._exitOrthoMode(()=>{this.fire("active",this._active),t()}):(this._exitOrthoMode(),this.fire("active",this._active))):t&&t()}_enterOrthoMode(e=()=>{}){e?this.viewer.cameraFlight.flyTo({projection:"ortho",duration:.5},e):this.viewer.cameraFlight.jumpTo({projection:"ortho"})}_exitOrthoMode(e=()=>{}){e?this.viewer.cameraFlight.flyTo({projection:"perspective",duration:.5},e):this.viewer.cameraFlight.jumpTo({projection:"perspective"})}}class sE extends Nk{constructor(e,t){if(super(e,t),this._AnnotationList=[],this._visible=!0,this._currentType="image",this._modelId=t.modelId,this.eventTrigger=e.eventTrigger,this.imageSrc=new Map,document.getElementById("myAnnotationDiv"))this.annotationWrapper=document.getElementById("myAnnotationDiv");else{this.annotationWrapper=document.createElement("div"),this.annotationWrapper.id="myAnnotationDiv";const{canvas:t}=e.viewer.scene.canvas;t.parentNode.insertBefore(this.annotationWrapper,t)}let i;this.annotationsPlugin=new tt(this.viewer,{markerHTML:"<div class='annotation-marker annotation-marker-{{iconType}} {{iconType}}' id='{{id}}' entityid='{{entityid}}' style='position:absolute;'><img src='{{iconPath}}'></div>",container:this.annotationWrapper,values:{id:"",entityid:"",iconPath:"",iconType:""}}),this.bimViewer.on("closeAll",()=>{this.setActive(!1)}),this.on("active",e=>{}),this.annotationsPlugin.on("markerClicked",e=>{this.eventTrigger.emit("markerClicked",e),i=e}),this.annotationsPlugin.on("markerDoubleClicked",e=>{this.eventTrigger.emit("markerDoubleClicked",e)});const r=e=>{this._active&&("Delete"!==e.key&&8!==e.keyCode||this.eventTrigger.emit("requestDeleteMarker",i.id))};document.addEventListener("keydown",r.bind(this)),this.on("destroy",()=>{document.removeEventListener("keydown",r.bind(this))})}setAllVisible(e=!this._visible){this._visible=e,this.annotationsPlugin.setAllVisible(e)}clickToCreateAnno(e){if(!this.getActive())return;if(!this.getEnabled())return;const t=this.getCanvasPos(e),i=this.viewer.scene.pick({canvasPos:t,pickSurface:!0});if(i){const e=i.entity.id,t=this.generateId(e);this.annotationsPlugin.createAnnotation({id:t,pickResult:i,occludable:!0,markerShown:!0,labelShown:!1,values:{id:t,entityid:e,iconPath:this.getTypeImage(this._currentType),iconType:this._currentType}}),this.currentAnnotation={id:t,modelId:this._modelId,entityId:e,type:this._currentType,content:{worldPos:[i.worldPos[0],i.worldPos[1],i.worldPos[2]],fileContent:[],text:""}},this.eventTrigger.emit("createAnnotation",{type:this._currentType,currentAnnotation:this.currentAnnotation}),this._AnnotationList.push(this.currentAnnotation)}else console.log("没有获取到合法的坐标,传入的内容:",e)}generateId(e){const t=Date.now(),i=Math.floor(1e3*performance.now());return`${e}_${this._currentType}_${t}_${i}`}getCanvasPos(e){const t=[];if(e)if("TouchEvent"in window&&e instanceof TouchEvent){if(!e.touches||0===e.touches.length)return;const i=e.touches[0];let r=e.target,n=0,s=0;for(;r.offsetParent;)n+=r.offsetLeft,s+=r.offsetTop,r=r.offsetParent;t[0]=i.pageX-n,t[1]=i.pageY-s}else{let i=this.viewer.scene.canvas.canvas,r=0,n=0;for(;i.offsetParent;)r+=i.offsetLeft,n+=i.offsetTop,i=i.offsetParent;t[0]=e.pageX-r,t[1]=e.pageY-n}else e=window.event,t[0]=e.x,t[1]=e.y;return t}setCurrentType(e){this._currentType=e}showAnnotationList(){this.clear();const e=this._AnnotationList;e.length>0&&e.forEach(e=>{this.addAnnotation(e.id.toString(),e.content.worldPos,e.type)})}addAnnotation(e,t,i){this.annotationsPlugin.createAnnotation({id:e,worldPos:t,occludable:!0,markerShown:this._visible,labelShown:!1,values:{id:e,entityid:e,iconPath:this.getTypeImage(i),iconType:i}})}clear(){this.annotationsPlugin.clear()}get AnnotationList(){return this._AnnotationList}set AnnotationList(e){this._AnnotationList=e}getTypeImage(e){if(this.imageSrc.size<1){let t=document.getElementById(`annotation_tool_btn_img_${e}`);return t&&t instanceof HTMLImageElement&&t.src?t.src:null}return this.imageSrc.get(e)}setTypeImage(e){for(const t in e)this.imageSrc.set(t,e[t])}destroyAnnotationById(e){this.annotationsPlugin.destroyAnnotation(e),this._AnnotationList.forEach((t,i)=>{t.id===e&&this._AnnotationList.splice(i,1)})}getAnnotationById(e){return this.annotationsPlugin.annotations[e]}get annotationPluginList(){return this.annotationsPlugin.annotations}destroy(){var e;this.fire("destroy",!0),this.clear(),this.annotationsPlugin.destroy(),this.annotationWrapper&&(null===(e=this.annotationWrapper.parentNode)||void 0===e||e.removeChild(this.annotationWrapper))}}class oE extends Nk{constructor(e,t){super(e,t),this._offsetX=0,this._offsetY=0,this._isTouch=!1,this._approximate=!0,this._precision=2,this.eventTrigger=e.eventTrigger,this.angleMeasureContainer=document.createElement("div"),this.angleMeasureContainer.id="myAngleMeasuresDiv";const{canvas:i}=e.viewer.scene.canvas;i.parentNode.insertBefore(this.angleMeasureContainer,i),this._angleMeasurementsPlugin=new Ke(this.viewer,{container:this.angleMeasureContainer,defaultColor:"#0065FC"}),this._angleMeasurementsMouseControl=new We(this._angleMeasurementsPlugin,{snapping:!0,offsetX:t.offsetX,offsetY:t.offsetY}),this._angleMeasurementsTouchControl=new qe(this._angleMeasurementsPlugin,{offsetX:t.offsetX,offsetY:t.offsetY}),this._angleMeasurementsSimulateMouseControl=new Ye(this._angleMeasurementsPlugin,{offsetX:t.offsetX,offsetY:t.offsetY,snapping:!0}),this._angleMeasurementsMouseControl.snapping=!0,this.bimViewer.on("closeAll",()=>{this.setActive(!1)}),this._initSettings(),this._initializeMeasure()}setActive(e){this._active=e,e?this.chosedTarget&&this.chosedTarget.setHighlighted(!0):(this.refreshMouseState(),this.setAllHightLighted(!1)),this._isTouch?(this._angleMeasurementsTouchControl.active=e,this._angleMeasurementsSimulateMouseControl.active=e):this._angleMeasurementsMouseControl.active=e}getActive(){return this._active}_initSettings(){this._angleMeasurementsMouseControl.activate(),this._angleMeasurementsMouseControl.active=!1,this._angleMeasurementsTouchControl.activate(),this._angleMeasurementsTouchControl.active=!1,this._angleMeasurementsSimulateMouseControl.activate(),this._angleMeasurementsSimulateMouseControl.active=!1}_initializeMeasure(){this._angleMeasurementsPlugin.on("measurementCreated",e=>{this.eventTrigger.emit("newAngleMeasure",{id:e.id}),this.newMeasure=e,this.chosedTarget=null}),this._angleMeasurementsPlugin.on("measurementEnd",e=>{0!==this.getMeasureResultByID(e.id)?(this.eventTrigger.emit("createAngleMeasure",{id:e.id,result:this.getMeasureResultByID(e.id)}),this.setAllHightLighted(!1),this.chosedTarget=e,this.chosedTarget.setHighlighted(!0),this.newMeasure=null):this.destroyMeasurementById(e.id)}),this._angleMeasurementsPlugin.on("mouseOver",e=>{e.measurement.setHighlighted(!0)}),this._angleMeasurementsPlugin.on("mouseLeave",e=>{e.angleMeasurement==this.chosedTarget&&this._active||e.measurement.setHighlighted(!1)}),this._angleMeasurementsPlugin.on("clickMeasure",e=>{this.chosedTarget&&this.chosedTarget.id!==e.measurement.id&&this.chosedTarget.setHighlighted(!1),this.chosedTarget=e.measurement,this.chosedTarget.setHighlighted(!0),this.eventTrigger.emit("clickAngleMeasure",{id:this.chosedTarget.id,result:this.getMeasureResultByID(this.chosedTarget.id)})}),this._angleMeasurementsPlugin.on("touchMeasure",e=>{this.chosedTarget&&this.chosedTarget.id!==e.measurement.id&&this.chosedTarget.setHighlighted(!1),this.chosedTarget=e.measurement,this.chosedTarget.setHighlighted(!0),this.eventTrigger.emit("clickAngleMeasure",{id:this.chosedTarget.id,result:this.getMeasureResultByID(this.chosedTarget.id)})}),this._angleMeasurementsPlugin.on("measurementDestroyed",e=>{this.eventTrigger.emit("AngleMeasureDestroyed",{id:e.id})});const e=()=>{this._active&&this.chosedTarget&&this.chosedTarget.setHighlighted(!0)},t=e=>{if(this._active&&("Delete"===e.key||8===e.keyCode)){if(!this.chosedTarget)return;this.destroyMeasurementById(this.chosedTarget.id),this._angleMeasurementsPlugin.fire("measureDelete",null),0==this.getNumMeasurements()&&(this.chosedTarget=null)}};document.addEventListener("mousemove",e.bind(this)),document.addEventListener("keydown",t.bind(this)),this.on("destroy",()=>{document.removeEventListener("mousemove",e.bind(this)),document.removeEventListener("keydown",t.bind(this))})}set isTouch(e){this._isTouch=e,e||this._angleMeasurementsMouseControl.deactivate()}get isTouch(){return this._isTouch}set precision(e){this._precision=e,this._angleMeasurementsPlugin.precision=e}get precision(){return this._precision}set offsetX(e){this._offsetX=e,this._isTouch?(this._angleMeasurementsTouchControl.offsetX=e,this._angleMeasurementsSimulateMouseControl.offsetX=e):this._angleMeasurementsMouseControl.offsetX=e}get offsetX(){return this._offsetX}set offsetY(e){this._offsetY=e,this._isTouch?(this._angleMeasurementsTouchControl.offsetY=e,this._angleMeasurementsSimulateMouseControl.offsetY=e):this._angleMeasurementsMouseControl.offsetY=e}get offsetY(){return this._offsetY}refreshMouseState(){this.newMeasure&&(this.destroyMeasurementById(this.newMeasure.id),this.isTouch?(this._angleMeasurementsTouchControl.touchState=0,this._angleMeasurementsSimulateMouseControl.mouseState=0):this._angleMeasurementsMouseControl.mouseState=0,this.setAllHightLighted(!1),this.newMeasure=null)}setAllVisible(e){this._angleMeasurementsPlugin.setMeasurementsShown(e)}setSnappingEnabled(e){return this._angleMeasurementsMouseControl.snapping=e}getNumMeasurements(){return Object.keys(this._angleMeasurementsPlugin.measurements).length}getMeasurementsList(){return this._angleMeasurementsPlugin.measurements}getMeasurementById(e){return this.getMeasurementsList()[e]}getMeasureResultByID(e){const t=this.getMeasurementById(e);return t?t.angle:0}setMeasureColorByID(e,t){this.getMeasurementById(e).color=t}setMeasureClickbleById(e,t){this.getMeasurementById(e).clickable=t}setMeasureHightlighted(e,t){this.getMeasurementById(e).setHighlighted(t)}setAllHightLighted(e){const t=this.getMeasurementsList();for(const i in t)t[i].setHighlighted(e)}setVisibleById(e,t){this.getMeasurementById(e).visible=t}setAngleLabelVisible(e,t){this.getMeasurementById(e).angleVisible=t}destroyMeasurementById(e){this._angleMeasurementsPlugin.destroyMeasurement(e)}onSimulateMousedown(e){this._angleMeasurementsSimulateMouseControl.onMousedown(e)}onSimulateMousemove(e){this._angleMeasurementsSimulateMouseControl.onMousemove(e)}onSimulateMouseup(e){this._angleMeasurementsSimulateMouseControl.onMouseup(e)}clear(){this._angleMeasurementsPlugin.clear()}stop(){this._isTouch?(this._angleMeasurementsTouchControl.deactivate(),this._angleMeasurementsSimulateMouseControl.deactivate()):this._angleMeasurementsMouseControl.deactivate()}destroy(){this.fire("destroy",!0),this.angleMeasureContainer.parentNode&&this.angleMeasureContainer.parentNode.removeChild(this.angleMeasureContainer),this._angleMeasurementsPlugin.destroy(),this._angleMeasurementsMouseControl.destroy(),this._angleMeasurementsTouchControl.destroy(),this._angleMeasurementsSimulateMouseControl.destroy(),super.destroy()}}class aE extends Nk{constructor(e,t){super(e,t),this._offsetX=0,this._offsetY=0,this._isTouch=!1,this._approximate=!0,this._precision=2,this._scale=1,this._unit="m",this.eventTrigger=e.eventTrigger,this.distanceMeasureContainer=document.createElement("div"),this.distanceMeasureContainer.id="myDistanceMeasuresDiv";const{canvas:i}=e.viewer.scene.canvas;i.parentNode.insertBefore(this.distanceMeasureContainer,i),this._distanceMeasurementsPlugin=new gh(this.viewer,{container:this.distanceMeasureContainer,defaultAxisVisible:!1,defaultColor:"#0065FC"}),this._distanceMeasurementsMouseControl=new fh(this._distanceMeasurementsPlugin,{snapping:!0,offsetX:t.offsetX,offsetY:t.offsetY}),this._distanceMeasurementsTouchControl=new mh(this._distanceMeasurementsPlugin,{offsetX:t.offsetX,offsetY:t.offsetY}),this._distanceMeasurementsSimulateMouseControl=new vh(this._distanceMeasurementsPlugin,{offsetX:t.offsetX,offsetY:t.offsetY,snapping:!0}),this._distanceMeasurementsMouseControl.snapping=!0,this.bimViewer.on("closeAll",()=>{this.setActive(!1)}),this._initSettings(),this._initializeMeasure()}setActive(e){this._active=e,e?this.chosedTarget&&this.chosedTarget.setHighlighted(!0):(this.refreshMouseState(),this.setAllHightLighted(!1)),this._isTouch?(this._distanceMeasurementsTouchControl.active=e,this._distanceMeasurementsSimulateMouseControl.active=e):this._distanceMeasurementsMouseControl.active=e}getActive(){return this._active}_initSettings(){this._distanceMeasurementsMouseControl.activate(),this._distanceMeasurementsMouseControl.active=!1,this._distanceMeasurementsTouchControl.activate(),this._distanceMeasurementsTouchControl.active=!1,this._distanceMeasurementsSimulateMouseControl.activate(),this._distanceMeasurementsSimulateMouseControl.active=!1}_initializeMeasure(){this._distanceMeasurementsPlugin.on("measurementCreated",e=>{this.eventTrigger.emit("newDistanceMeasure",{id:e.id}),this.newMeasure=e,this.chosedTarget=null}),this._distanceMeasurementsPlugin.on("measurementEnd",e=>{0!==this.getMeasureResultByID(e.id)?(this.eventTrigger.emit("createDistanceMeasure",{id:e.id,result:this.getMeasureResultByID(e.id),xResult:e.xLabel,yResult:e.yLabel,zResult:e.zLabel}),this.setAllHightLighted(!1),this.chosedTarget=e,this.chosedTarget.setHighlighted(!0),this.newMeasure=null):this.destroyMeasurementById(e.id)}),this._distanceMeasurementsPlugin.on("mouseOver",e=>{e.measurement.setHighlighted(!0)}),this._distanceMeasurementsPlugin.on("mouseLeave",e=>{e.distanceMeasurement==this.chosedTarget&&this._active||e.measurement.setHighlighted(!1)}),this._distanceMeasurementsPlugin.on("clickMeasure",e=>{this.chosedTarget&&this.chosedTarget.id!==e.measurement.id&&this.chosedTarget.setHighlighted(!1),this.chosedTarget=e.measurement,this.chosedTarget.setHighlighted(!0),this.eventTrigger.emit("clickDistanceMeasure",{id:this.chosedTarget.id,result:this.getMeasureResultByID(this.chosedTarget.id)})}),this._distanceMeasurementsPlugin.on("touchMeasure",e=>{this.chosedTarget&&this.chosedTarget.id!==e.measurement.id&&this.chosedTarget.setHighlighted(!1),this.chosedTarget=e.measurement,this.chosedTarget.setHighlighted(!0),this.eventTrigger.emit("clickDistanceMeasure",{id:this.chosedTarget.id,result:this.getMeasureResultByID(this.chosedTarget.id)})}),this._distanceMeasurementsPlugin.on("measurementCancel",e=>{this.eventTrigger.emit("DistanceMeasureCancel",{id:e.id})}),this._distanceMeasurementsPlugin.on("measurementDestroyed",e=>{this.eventTrigger.emit("DistanceMeasureDestroyed",{id:e.id})});const e=()=>{this._active&&this.chosedTarget&&this.chosedTarget.setHighlighted(!0)},t=e=>{if(this._active&&("Delete"===e.key||8===e.keyCode)){if(!this.chosedTarget)return;this.destroyMeasurementById(this.chosedTarget.id),this._distanceMeasurementsPlugin.fire("measureDelete",null),0==this.getNumMeasurements()&&(this.chosedTarget=null)}};document.addEventListener("mousemove",e.bind(this)),document.addEventListener("keydown",t.bind(this)),this.on("destroy",()=>{document.removeEventListener("mousemove",e.bind(this)),document.removeEventListener("keydown",t.bind(this))})}set isTouch(e){this._isTouch=e,e||this._distanceMeasurementsMouseControl.deactivate()}get isTouch(){return this._isTouch}set unit(e){switch(this._unit=e,e){case"m":this.viewer.scene.metrics.units="meters",this.viewer.scene.metrics.scale=1*this._scale;break;case"cm":this.viewer.scene.metrics.units="centimeters",this.viewer.scene.metrics.scale=100*this._scale;break;case"mm":this.viewer.scene.metrics.units="millimeters",this.viewer.scene.metrics.scale=1e3*this._scale}}set scale(e){this._scale=e,this.unit=this._unit}get scale(){return this._scale}set precision(e){this._precision=e,this._distanceMeasurementsPlugin.precision=e}get precision(){return this._precision}set offsetX(e){this._offsetX=e,this._isTouch?(this._distanceMeasurementsTouchControl.offsetX=e,this._distanceMeasurementsSimulateMouseControl.offsetX=e):this._distanceMeasurementsMouseControl.offsetX=e}get offsetX(){return this._offsetX}set offsetY(e){this._offsetY=e,this._isTouch?(this._distanceMeasurementsTouchControl.offsetY=e,this._distanceMeasurementsSimulateMouseControl.offsetY=e):this._distanceMeasurementsMouseControl.offsetY=e}get offsetY(){return this._offsetY}refreshMouseState(){this.newMeasure&&(this.destroyMeasurementById(this.newMeasure.id),this.isTouch?(this._distanceMeasurementsTouchControl.touchState=0,this._distanceMeasurementsSimulateMouseControl.mouseState=0):this._distanceMeasurementsMouseControl.mouseState=0,this.setAllHightLighted(!1),this.newMeasure=null)}setAllVisible(e){this._distanceMeasurementsPlugin.setMeasurementsShown(e)}setSnappingEnabled(e){return this._distanceMeasurementsMouseControl.snapping=e}getNumMeasurements(){return Object.keys(this._distanceMeasurementsPlugin.measurements).length}getMeasurementsList(){return this._distanceMeasurementsPlugin.measurements}getMeasurementById(e){return this.getMeasurementsList()[e]}getMeasureResultByID(e){const t=this.getMeasurementById(e);return t?t.length:0}setMeasureColorByID(e,t){this.getMeasurementById(e).color=t}setMeasureClickbleById(e,t){this.getMeasurementById(e).clickable=t}setMeasureHightlighted(e,t){this.getMeasurementById(e).setHighlighted(t)}setAllHightLighted(e){const t=this.getMeasurementsList();for(const i in t)t[i].setHighlighted(e)}setVisibleById(e,t){this.getMeasurementById(e).visible=t}setLableVisibleById(e,t){this.getMeasurementById(e).labelsVisible=t}destroyMeasurementById(e){this._distanceMeasurementsPlugin.destroyMeasurement(e)}onSimulateMousedown(e){this._distanceMeasurementsSimulateMouseControl.onMousedown(e)}onSimulateMousemove(e){this._distanceMeasurementsSimulateMouseControl.onMousemove(e)}onSimulateMouseup(e){this._distanceMeasurementsSimulateMouseControl.onMouseup(e)}clear(){this._distanceMeasurementsPlugin.clear()}stop(){this._isTouch?(this._distanceMeasurementsTouchControl.deactivate(),this._distanceMeasurementsSimulateMouseControl.deactivate()):this._distanceMeasurementsMouseControl.deactivate()}destroy(){this.fire("destroy",!0),this.distanceMeasureContainer.parentNode&&this.distanceMeasureContainer.parentNode.removeChild(this.distanceMeasureContainer),this._distanceMeasurementsPlugin.destroy(),this._distanceMeasurementsMouseControl.destroy(),this._distanceMeasurementsTouchControl.destroy(),this._distanceMeasurementsSimulateMouseControl.destroy(),super.destroy()}}class lE extends Nk{constructor(e,t){super(e),this._isTouch=!1,this._tools={},this._toolType="distance",this.eventTrigger=e.eventTrigger,this._measure_distance_tool=new aE(e,{}),this._measure_angle_tool=new oE(e,{}),this._tools.distance=this._measure_distance_tool,this._tools.angle=this._measure_angle_tool,this.bimViewer.on("closeAll",()=>{this.setActive(!1)}),this.setActive(!0),this._initEventHandle()}_initEventHandle(){this.eventTrigger.on("clickAngleMeasure",e=>{this._active&&(this.getActiveByType("angle")||this.setActiveByType("angle",!0))}),this.eventTrigger.on("clickDistanceMeasure",e=>{this._active&&(this.getActiveByType("distance")||this.setActiveByType("distance",!0))})}setActive(e=!this._active){this._active=e,this._measure_angle_tool.setEnabled(e),this._measure_distance_tool.setEnabled(e),e||(this._measure_angle_tool.setActive(e),this._measure_distance_tool.setActive(e))}getActive(){return this._active}set isTouch(e){this._isTouch=e,this._measure_angle_tool.isTouch=e,this._measure_distance_tool.isTouch=e}get isTouch(){return this._isTouch}get measureAngleTool(){return this._measure_angle_tool}get measureDistanceTool(){return this._measure_distance_tool}getMeasureToolByType(e){return this._tools[e]}setActiveByType(e,t=!this._tools[e].getActive()){this._toolType=e;for(let i in this._tools)e==i?this._tools[i].setActive(t):this._tools[i].setActive(!1)}getActiveByType(e){return this._tools[e].getActive()}get currentTool(){return this._tools[this._toolType]}SetMeasureAngleActive(e=!this._measure_angle_tool.getActive(),t=()=>{}){this._measure_angle_tool.setActive(e),t(this._measure_angle_tool.getActive())}SetMeasureDistanceActive(e=!this._measure_distance_tool.getActive(),t=()=>{}){this._measure_distance_tool.setActive(e),t(this._measure_distance_tool.getActive())}setAllDisActive(){for(let e in this._tools)this._tools[e].setActive(!1)}setMeasureOffSet(e,t){this.measureAngleTool.offsetX=e,this.measureAngleTool.offsetY=t,this.measureDistanceTool.offsetX=e,this.measureDistanceTool.offsetY=t}setSnapRadius(e){this.viewer.cameraControl.snapRadius=e}destroy(){this._measure_distance_tool.destroy(),this._measure_angle_tool.destroy()}}
|
|
38
38
|
/*!
|
|
39
39
|
* decimal.js v10.6.0
|
|
40
40
|
* An arbitrary-precision Decimal type for JavaScript.
|