@soonspacejs/plugin-navigation 2.6.31 → 2.6.33
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.esm.js +1 -1
- package/package.json +3 -3
package/dist/index.esm.js
CHANGED
|
@@ -13,4 +13,4 @@ version: 2.9.0
|
|
|
13
13
|
* @since jsrsasign 2.1
|
|
14
14
|
* @license <a href="https://kjur.github.io/jsrsasign/license/">MIT License</a>
|
|
15
15
|
*/
|
|
16
|
-
var In={};void 0!==In.asn1&&In.asn1||(In.asn1={}),In.asn1.ASN1Util=new function(){this.integerToByteHex=function(t){var e=t.toString(16);return e.length%2==1&&(e="0"+e),e},this.bigIntToMinTwosComplementsHex=function(t){var e=t.toString(16);if("-"!=e.substr(0,1))e.length%2==1?e="0"+e:e.match(/^[0-7]/)||(e="00"+e);else{var n=e.substr(1).length;n%2==1?n+=1:e.match(/^[0-7]/)||(n+=2);for(var r="",i=0;i<n;i++)r+="f";e=new We(r,16).xor(t).add(We.ONE).toString(16).replace(/^-/,"")}return e},this.getPEMStringFromHex=function(t,e){return hextopem(t,e)},this.newObject=function(t){var e=In.asn1,n=e.DERBoolean,r=e.DERInteger,i=e.DERBitString,o=e.DEROctetString,s=e.DERNull,a=e.DERObjectIdentifier,u=e.DEREnumerated,h=e.DERUTF8String,c=e.DERNumericString,l=e.DERPrintableString,f=e.DERTeletexString,p=e.DERIA5String,d=e.DERUTCTime,g=e.DERGeneralizedTime,v=e.DERSequence,y=e.DERSet,m=e.DERTaggedObject,b=e.ASN1Util.newObject,w=Object.keys(t);if(1!=w.length)throw"key of param shall be only one.";var S=w[0];if(-1==":bool:int:bitstr:octstr:null:oid:enum:utf8str:numstr:prnstr:telstr:ia5str:utctime:gentime:seq:set:tag:".indexOf(":"+S+":"))throw"undefined key: "+S;if("bool"==S)return new n(t[S]);if("int"==S)return new r(t[S]);if("bitstr"==S)return new i(t[S]);if("octstr"==S)return new o(t[S]);if("null"==S)return new s(t[S]);if("oid"==S)return new a(t[S]);if("enum"==S)return new u(t[S]);if("utf8str"==S)return new h(t[S]);if("numstr"==S)return new c(t[S]);if("prnstr"==S)return new l(t[S]);if("telstr"==S)return new f(t[S]);if("ia5str"==S)return new p(t[S]);if("utctime"==S)return new d(t[S]);if("gentime"==S)return new g(t[S]);if("seq"==S){for(var T=t[S],E=[],O=0;O<T.length;O++){var I=b(T[O]);E.push(I)}return new v({array:E})}if("set"==S){for(T=t[S],E=[],O=0;O<T.length;O++){I=b(T[O]);E.push(I)}return new y({array:E})}if("tag"==S){var x=t[S];if("[object Array]"===Object.prototype.toString.call(x)&&3==x.length){var D=b(x[2]);return new m({tag:x[0],explicit:x[1],obj:D})}var R={};if(void 0!==x.explicit&&(R.explicit=x.explicit),void 0!==x.tag&&(R.tag=x.tag),void 0===x.obj)throw"obj shall be specified for 'tag'.";return R.obj=b(x.obj),new m(R)}},this.jsonToASN1HEX=function(t){return this.newObject(t).getEncodedHex()}},In.asn1.ASN1Util.oidHexToInt=function(t){for(var e="",n=parseInt(t.substr(0,2),16),r=(e=Math.floor(n/40)+"."+n%40,""),i=2;i<t.length;i+=2){var o=("00000000"+parseInt(t.substr(i,2),16).toString(2)).slice(-8);if(r+=o.substr(1,7),"0"==o.substr(0,1))e=e+"."+new We(r,2).toString(10),r=""}return e},In.asn1.ASN1Util.oidIntToHex=function(t){var e=function(t){var e=t.toString(16);return 1==e.length&&(e="0"+e),e},n=function(t){var n="",r=new We(t,10).toString(2),i=7-r.length%7;7==i&&(i=0);for(var o="",s=0;s<i;s++)o+="0";r=o+r;for(s=0;s<r.length-1;s+=7){var a=r.substr(s,7);s!=r.length-7&&(a="1"+a),n+=e(parseInt(a,2))}return n};if(!t.match(/^[0-9.]+$/))throw"malformed oid string: "+t;var r="",i=t.split("."),o=40*parseInt(i[0])+parseInt(i[1]);r+=e(o),i.splice(0,2);for(var s=0;s<i.length;s++)r+=n(i[s]);return r},In.asn1.ASN1Object=function(){this.getLengthHexFromValue=function(){if(void 0===this.hV||null==this.hV)throw"this.hV is null or undefined.";if(this.hV.length%2==1)throw"value hex must be even length: n="+"".length+",v="+this.hV;var t=this.hV.length/2,e=t.toString(16);if(e.length%2==1&&(e="0"+e),t<128)return e;var n=e.length/2;if(n>15)throw"ASN.1 length too long to represent by 8x: n = "+t.toString(16);return(128+n).toString(16)+e},this.getEncodedHex=function(){return(null==this.hTLV||this.isModified)&&(this.hV=this.getFreshValueHex(),this.hL=this.getLengthHexFromValue(),this.hTLV=this.hT+this.hL+this.hV,this.isModified=!1),this.hTLV},this.getValueHex=function(){return this.getEncodedHex(),this.hV},this.getFreshValueHex=function(){return""}},In.asn1.DERAbstractString=function(t){In.asn1.DERAbstractString.superclass.constructor.call(this),this.getString=function(){return this.s},this.setString=function(t){this.hTLV=null,this.isModified=!0,this.s=t,this.hV=stohex(this.s)},this.setStringHex=function(t){this.hTLV=null,this.isModified=!0,this.s=null,this.hV=t},this.getFreshValueHex=function(){return this.hV},void 0!==t&&("string"==typeof t?this.setString(t):void 0!==t.str?this.setString(t.str):void 0!==t.hex&&this.setStringHex(t.hex))},On.lang.extend(In.asn1.DERAbstractString,In.asn1.ASN1Object),In.asn1.DERAbstractTime=function(t){In.asn1.DERAbstractTime.superclass.constructor.call(this),this.localDateToUTC=function(t){return utc=t.getTime()+6e4*t.getTimezoneOffset(),new Date(utc)},this.formatDate=function(t,e,n){var r=this.zeroPadding,i=this.localDateToUTC(t),o=String(i.getFullYear());"utc"==e&&(o=o.substr(2,2));var s=o+r(String(i.getMonth()+1),2)+r(String(i.getDate()),2)+r(String(i.getHours()),2)+r(String(i.getMinutes()),2)+r(String(i.getSeconds()),2);if(!0===n){var a=i.getMilliseconds();if(0!=a){var u=r(String(a),3);s=s+"."+(u=u.replace(/[0]+$/,""))}}return s+"Z"},this.zeroPadding=function(t,e){return t.length>=e?t:new Array(e-t.length+1).join("0")+t},this.getString=function(){return this.s},this.setString=function(t){this.hTLV=null,this.isModified=!0,this.s=t,this.hV=stohex(t)},this.setByDateValue=function(t,e,n,r,i,o){var s=new Date(Date.UTC(t,e-1,n,r,i,o,0));this.setByDate(s)},this.getFreshValueHex=function(){return this.hV}},On.lang.extend(In.asn1.DERAbstractTime,In.asn1.ASN1Object),In.asn1.DERAbstractStructured=function(t){In.asn1.DERAbstractString.superclass.constructor.call(this),this.setByASN1ObjectArray=function(t){this.hTLV=null,this.isModified=!0,this.asn1Array=t},this.appendASN1Object=function(t){this.hTLV=null,this.isModified=!0,this.asn1Array.push(t)},this.asn1Array=new Array,void 0!==t&&void 0!==t.array&&(this.asn1Array=t.array)},On.lang.extend(In.asn1.DERAbstractStructured,In.asn1.ASN1Object),In.asn1.DERBoolean=function(){In.asn1.DERBoolean.superclass.constructor.call(this),this.hT="01",this.hTLV="0101ff"},On.lang.extend(In.asn1.DERBoolean,In.asn1.ASN1Object),In.asn1.DERInteger=function(t){In.asn1.DERInteger.superclass.constructor.call(this),this.hT="02",this.setByBigInteger=function(t){this.hTLV=null,this.isModified=!0,this.hV=In.asn1.ASN1Util.bigIntToMinTwosComplementsHex(t)},this.setByInteger=function(t){var e=new We(String(t),10);this.setByBigInteger(e)},this.setValueHex=function(t){this.hV=t},this.getFreshValueHex=function(){return this.hV},void 0!==t&&(void 0!==t.bigint?this.setByBigInteger(t.bigint):void 0!==t.int?this.setByInteger(t.int):"number"==typeof t?this.setByInteger(t):void 0!==t.hex&&this.setValueHex(t.hex))},On.lang.extend(In.asn1.DERInteger,In.asn1.ASN1Object),In.asn1.DERBitString=function(t){if(void 0!==t&&void 0!==t.obj){var e=In.asn1.ASN1Util.newObject(t.obj);t.hex="00"+e.getEncodedHex()}In.asn1.DERBitString.superclass.constructor.call(this),this.hT="03",this.setHexValueIncludingUnusedBits=function(t){this.hTLV=null,this.isModified=!0,this.hV=t},this.setUnusedBitsAndHexValue=function(t,e){if(t<0||7<t)throw"unused bits shall be from 0 to 7: u = "+t;var n="0"+t;this.hTLV=null,this.isModified=!0,this.hV=n+e},this.setByBinaryString=function(t){var e=8-(t=t.replace(/0+$/,"")).length%8;8==e&&(e=0);for(var n=0;n<=e;n++)t+="0";var r="";for(n=0;n<t.length-1;n+=8){var i=t.substr(n,8),o=parseInt(i,2).toString(16);1==o.length&&(o="0"+o),r+=o}this.hTLV=null,this.isModified=!0,this.hV="0"+e+r},this.setByBooleanArray=function(t){for(var e="",n=0;n<t.length;n++)1==t[n]?e+="1":e+="0";this.setByBinaryString(e)},this.newFalseArray=function(t){for(var e=new Array(t),n=0;n<t;n++)e[n]=!1;return e},this.getFreshValueHex=function(){return this.hV},void 0!==t&&("string"==typeof t&&t.toLowerCase().match(/^[0-9a-f]+$/)?this.setHexValueIncludingUnusedBits(t):void 0!==t.hex?this.setHexValueIncludingUnusedBits(t.hex):void 0!==t.bin?this.setByBinaryString(t.bin):void 0!==t.array&&this.setByBooleanArray(t.array))},On.lang.extend(In.asn1.DERBitString,In.asn1.ASN1Object),In.asn1.DEROctetString=function(t){if(void 0!==t&&void 0!==t.obj){var e=In.asn1.ASN1Util.newObject(t.obj);t.hex=e.getEncodedHex()}In.asn1.DEROctetString.superclass.constructor.call(this,t),this.hT="04"},On.lang.extend(In.asn1.DEROctetString,In.asn1.DERAbstractString),In.asn1.DERNull=function(){In.asn1.DERNull.superclass.constructor.call(this),this.hT="05",this.hTLV="0500"},On.lang.extend(In.asn1.DERNull,In.asn1.ASN1Object),In.asn1.DERObjectIdentifier=function(t){var e=function(t){var e=t.toString(16);return 1==e.length&&(e="0"+e),e},n=function(t){var n="",r=new We(t,10).toString(2),i=7-r.length%7;7==i&&(i=0);for(var o="",s=0;s<i;s++)o+="0";r=o+r;for(s=0;s<r.length-1;s+=7){var a=r.substr(s,7);s!=r.length-7&&(a="1"+a),n+=e(parseInt(a,2))}return n};In.asn1.DERObjectIdentifier.superclass.constructor.call(this),this.hT="06",this.setValueHex=function(t){this.hTLV=null,this.isModified=!0,this.s=null,this.hV=t},this.setValueOidString=function(t){if(!t.match(/^[0-9.]+$/))throw"malformed oid string: "+t;var r="",i=t.split("."),o=40*parseInt(i[0])+parseInt(i[1]);r+=e(o),i.splice(0,2);for(var s=0;s<i.length;s++)r+=n(i[s]);this.hTLV=null,this.isModified=!0,this.s=null,this.hV=r},this.setValueName=function(t){var e=In.asn1.x509.OID.name2oid(t);if(""===e)throw"DERObjectIdentifier oidName undefined: "+t;this.setValueOidString(e)},this.getFreshValueHex=function(){return this.hV},void 0!==t&&("string"==typeof t?t.match(/^[0-2].[0-9.]+$/)?this.setValueOidString(t):this.setValueName(t):void 0!==t.oid?this.setValueOidString(t.oid):void 0!==t.hex?this.setValueHex(t.hex):void 0!==t.name&&this.setValueName(t.name))},On.lang.extend(In.asn1.DERObjectIdentifier,In.asn1.ASN1Object),In.asn1.DEREnumerated=function(t){In.asn1.DEREnumerated.superclass.constructor.call(this),this.hT="0a",this.setByBigInteger=function(t){this.hTLV=null,this.isModified=!0,this.hV=In.asn1.ASN1Util.bigIntToMinTwosComplementsHex(t)},this.setByInteger=function(t){var e=new We(String(t),10);this.setByBigInteger(e)},this.setValueHex=function(t){this.hV=t},this.getFreshValueHex=function(){return this.hV},void 0!==t&&(void 0!==t.int?this.setByInteger(t.int):"number"==typeof t?this.setByInteger(t):void 0!==t.hex&&this.setValueHex(t.hex))},On.lang.extend(In.asn1.DEREnumerated,In.asn1.ASN1Object),In.asn1.DERUTF8String=function(t){In.asn1.DERUTF8String.superclass.constructor.call(this,t),this.hT="0c"},On.lang.extend(In.asn1.DERUTF8String,In.asn1.DERAbstractString),In.asn1.DERNumericString=function(t){In.asn1.DERNumericString.superclass.constructor.call(this,t),this.hT="12"},On.lang.extend(In.asn1.DERNumericString,In.asn1.DERAbstractString),In.asn1.DERPrintableString=function(t){In.asn1.DERPrintableString.superclass.constructor.call(this,t),this.hT="13"},On.lang.extend(In.asn1.DERPrintableString,In.asn1.DERAbstractString),In.asn1.DERTeletexString=function(t){In.asn1.DERTeletexString.superclass.constructor.call(this,t),this.hT="14"},On.lang.extend(In.asn1.DERTeletexString,In.asn1.DERAbstractString),In.asn1.DERIA5String=function(t){In.asn1.DERIA5String.superclass.constructor.call(this,t),this.hT="16"},On.lang.extend(In.asn1.DERIA5String,In.asn1.DERAbstractString),In.asn1.DERUTCTime=function(t){In.asn1.DERUTCTime.superclass.constructor.call(this,t),this.hT="17",this.setByDate=function(t){this.hTLV=null,this.isModified=!0,this.date=t,this.s=this.formatDate(this.date,"utc"),this.hV=stohex(this.s)},this.getFreshValueHex=function(){return void 0===this.date&&void 0===this.s&&(this.date=new Date,this.s=this.formatDate(this.date,"utc"),this.hV=stohex(this.s)),this.hV},void 0!==t&&(void 0!==t.str?this.setString(t.str):"string"==typeof t&&t.match(/^[0-9]{12}Z$/)?this.setString(t):void 0!==t.hex?this.setStringHex(t.hex):void 0!==t.date&&this.setByDate(t.date))},On.lang.extend(In.asn1.DERUTCTime,In.asn1.DERAbstractTime),In.asn1.DERGeneralizedTime=function(t){In.asn1.DERGeneralizedTime.superclass.constructor.call(this,t),this.hT="18",this.withMillis=!1,this.setByDate=function(t){this.hTLV=null,this.isModified=!0,this.date=t,this.s=this.formatDate(this.date,"gen",this.withMillis),this.hV=stohex(this.s)},this.getFreshValueHex=function(){return void 0===this.date&&void 0===this.s&&(this.date=new Date,this.s=this.formatDate(this.date,"gen",this.withMillis),this.hV=stohex(this.s)),this.hV},void 0!==t&&(void 0!==t.str?this.setString(t.str):"string"==typeof t&&t.match(/^[0-9]{14}Z$/)?this.setString(t):void 0!==t.hex?this.setStringHex(t.hex):void 0!==t.date&&this.setByDate(t.date),!0===t.millis&&(this.withMillis=!0))},On.lang.extend(In.asn1.DERGeneralizedTime,In.asn1.DERAbstractTime),In.asn1.DERSequence=function(t){In.asn1.DERSequence.superclass.constructor.call(this,t),this.hT="30",this.getFreshValueHex=function(){for(var t="",e=0;e<this.asn1Array.length;e++){t+=this.asn1Array[e].getEncodedHex()}return this.hV=t,this.hV}},On.lang.extend(In.asn1.DERSequence,In.asn1.DERAbstractStructured),In.asn1.DERSet=function(t){In.asn1.DERSet.superclass.constructor.call(this,t),this.hT="31",this.sortFlag=!0,this.getFreshValueHex=function(){for(var t=new Array,e=0;e<this.asn1Array.length;e++){var n=this.asn1Array[e];t.push(n.getEncodedHex())}return 1==this.sortFlag&&t.sort(),this.hV=t.join(""),this.hV},void 0!==t&&void 0!==t.sortflag&&0==t.sortflag&&(this.sortFlag=!1)},On.lang.extend(In.asn1.DERSet,In.asn1.DERAbstractStructured),In.asn1.DERTaggedObject=function(t){In.asn1.DERTaggedObject.superclass.constructor.call(this),this.hT="a0",this.hV="",this.isExplicit=!0,this.asn1Object=null,this.setASN1Object=function(t,e,n){this.hT=e,this.isExplicit=t,this.asn1Object=n,this.isExplicit?(this.hV=this.asn1Object.getEncodedHex(),this.hTLV=null,this.isModified=!0):(this.hV=null,this.hTLV=n.getEncodedHex(),this.hTLV=this.hTLV.replace(/^../,e),this.isModified=!1)},this.getFreshValueHex=function(){return this.hV},void 0!==t&&(void 0!==t.tag&&(this.hT=t.tag),void 0!==t.explicit&&(this.isExplicit=t.explicit),void 0!==t.obj&&(this.asn1Object=t.obj,this.setASN1Object(this.isExplicit,this.hT,this.asn1Object)))},On.lang.extend(In.asn1.DERTaggedObject,In.asn1.ASN1Object);var xn,Dn,Rn=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},t(e,n)};return function(e,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();!function(t){function e(n){var r=t.call(this)||this;return n&&("string"==typeof n?r.parseKey(n):(e.hasPrivateKeyProperty(n)||e.hasPublicKeyProperty(n))&&r.parsePropertiesFrom(n)),r}Rn(e,t),e.prototype.parseKey=function(t){try{var e=0,n=0,r=/^\s*(?:[0-9A-Fa-f][0-9A-Fa-f]\s*)+$/.test(t)?Me(t):Ve.unarmor(t),i=Ue.decode(r);if(3===i.sub.length&&(i=i.sub[2].sub[0]),9===i.sub.length){e=i.sub[1].getHexStringValue(),this.n=nn(e,16),n=i.sub[2].getHexStringValue(),this.e=parseInt(n,16);var o=i.sub[3].getHexStringValue();this.d=nn(o,16);var s=i.sub[4].getHexStringValue();this.p=nn(s,16);var a=i.sub[5].getHexStringValue();this.q=nn(a,16);var u=i.sub[6].getHexStringValue();this.dmp1=nn(u,16);var h=i.sub[7].getHexStringValue();this.dmq1=nn(h,16);var c=i.sub[8].getHexStringValue();this.coeff=nn(c,16)}else{if(2!==i.sub.length)return!1;if(i.sub[0].sub){var l=i.sub[1].sub[0];e=l.sub[0].getHexStringValue(),this.n=nn(e,16),n=l.sub[1].getHexStringValue(),this.e=parseInt(n,16)}else e=i.sub[0].getHexStringValue(),this.n=nn(e,16),n=i.sub[1].getHexStringValue(),this.e=parseInt(n,16)}return!0}catch(t){return!1}},e.prototype.getPrivateBaseKey=function(){var t={array:[new In.asn1.DERInteger({int:0}),new In.asn1.DERInteger({bigint:this.n}),new In.asn1.DERInteger({int:this.e}),new In.asn1.DERInteger({bigint:this.d}),new In.asn1.DERInteger({bigint:this.p}),new In.asn1.DERInteger({bigint:this.q}),new In.asn1.DERInteger({bigint:this.dmp1}),new In.asn1.DERInteger({bigint:this.dmq1}),new In.asn1.DERInteger({bigint:this.coeff})]};return new In.asn1.DERSequence(t).getEncodedHex()},e.prototype.getPrivateBaseKeyB64=function(){return Ce(this.getPrivateBaseKey())},e.prototype.getPublicBaseKey=function(){var t=new In.asn1.DERSequence({array:[new In.asn1.DERObjectIdentifier({oid:"1.2.840.113549.1.1.1"}),new In.asn1.DERNull]}),e=new In.asn1.DERSequence({array:[new In.asn1.DERInteger({bigint:this.n}),new In.asn1.DERInteger({int:this.e})]}),n=new In.asn1.DERBitString({hex:"00"+e.getEncodedHex()});return new In.asn1.DERSequence({array:[t,n]}).getEncodedHex()},e.prototype.getPublicBaseKeyB64=function(){return Ce(this.getPublicBaseKey())},e.wordwrap=function(t,e){if(!t)return t;var n="(.{1,"+(e=e||64)+"})( +|$\n?)|(.{1,"+e+"})";return t.match(RegExp(n,"g")).join("\n")},e.prototype.getPrivateKey=function(){var t="-----BEGIN RSA PRIVATE KEY-----\n";return t+=e.wordwrap(this.getPrivateBaseKeyB64())+"\n",t+="-----END RSA PRIVATE KEY-----"},e.prototype.getPublicKey=function(){var t="-----BEGIN PUBLIC KEY-----\n";return t+=e.wordwrap(this.getPublicBaseKeyB64())+"\n",t+="-----END PUBLIC KEY-----"},e.hasPublicKeyProperty=function(t){return(t=t||{}).hasOwnProperty("n")&&t.hasOwnProperty("e")},e.hasPrivateKeyProperty=function(t){return(t=t||{}).hasOwnProperty("n")&&t.hasOwnProperty("e")&&t.hasOwnProperty("d")&&t.hasOwnProperty("p")&&t.hasOwnProperty("q")&&t.hasOwnProperty("dmp1")&&t.hasOwnProperty("dmq1")&&t.hasOwnProperty("coeff")},e.prototype.parsePropertiesFrom=function(t){this.n=t.n,this.e=t.e,t.hasOwnProperty("d")&&(this.d=t.d,this.p=t.p,this.q=t.q,this.dmp1=t.dmp1,this.dmq1=t.dmq1,this.coeff=t.coeff)}}(Tn),void 0!==$&&(null===(xn=$.env)||void 0===xn||xn.npm_package_version),new t.Vector4,new g,new v,function(t){t.sbm="SBM",t.sbmx="SBMX",t.dat="DAT",t.glb="GLB",t.gltf="GLTF",t.fbx="FBX"}(Dn||(Dn={})),new y([0,0,1,0,1,1,1,1,0,1,0,0],2);var Pn=Object.defineProperty,An=(t,e,n)=>(((t,e,n)=>{e in t?Pn(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n})(t,"symbol"!=typeof e?e+"":e,n),n),Bn=(t=>(t[t.x=0]="x",t[t.y=1]="y",t[t.z=2]="z",t))(Bn||{});function Nn(t,e,n){let r=function(t,e){const n=Math.sqrt(t.lengthSq()*e.lengthSq());if(0===n)return 0;let r=t.dot(e)/n;return r=Math.max(-1,Math.min(1,r)),Math.acos(r)}(t,e);return 0===r?r:t.clone().cross(e).dot(n)<0?-r:r}(t=>{t.toKey=function(e){return t[e]},t.toIndex=function(e){return t[e]}})(Bn||(Bn={}));const Ln=180/Math.PI,Cn={yaw:[{name:"前",range:[-15,15]},{name:"左",range:[15,165]},{name:"右",range:[-165,-15]},{name:"后",range:[-180.1,-165]},{name:"后",range:[165,180.1]}],pitch:[{name:"前",range:[-15,15]},{name:"上",range:[15,165]},{name:"下",range:[-165,-15]},{name:"后",range:[-180.1,-165]},{name:"后",range:[165,180.1]}],roll:[{name:"上",range:[-15,15]},{name:"左",range:[15,165]},{name:"右",range:[-165,-15]},{name:"下",range:[-180.1,-165]},{name:"下",range:[165,180.1]}]};const jn={degrees:!0,map:Cn,front:{x:0,y:0,z:1},up:{x:0,y:1,z:0}};class Mn{constructor(t){An(this,"_options"),An(this,"_listMap"),An(this,"_front"),An(this,"_up"),t&&(this.options=t)}static get options(){return this._options??(this.options=jn)}static set options(t){this._options=Object.assign({},structuredClone(Cn),t)}get defaultOptions(){return this.constructor.options}get options(){return this._options??(this.options=this.defaultOptions)}set options(t){this._options=Object.assign({},structuredClone(this.defaultOptions),t),this._listMap=null,this._front=null,this._up=null}get degrees(){return this.options.degrees??(this.options.degrees=this.defaultOptions.degrees??!0)}set degrees(t){this.options.degrees=t}get map(){return this.options.map||(this.map=this.defaultOptions.map),this.options.map}set map(t){const e=structuredClone(this.defaultOptions.map),n=structuredClone(Cn);t=t?{yaw:t.yaw??e.yaw??n.yaw,pitch:t.pitch??e.pitch??n.pitch,roll:t.roll??e.roll??n.roll}:e,this.options.map=t,this._listMap=null}get listMap(){return this._listMap??(this._listMap=function(t){const e={};for(const[n,r]of Object.entries(t))e[n]=Array.isArray(r)?r:Object.entries(r).map((([t,e])=>({name:t,range:e})));return e}(this.map??{}))}get front(){return this._front||(this.front=this.options.front??this.defaultOptions.front??jn.front),this._front}set front(t){this._front=(new e).copy(t)}get up(){return this._up||(this.up=this.options.up??this.defaultOptions.up??jn.up),this._up}set up(t){this._up=(new e).copy(t)}computeAzimuth(t,n,r){const i=(new e).copy(t),o=(new e).copy(n??this.front),s=(new e).copy(r??this.up);let{yaw:a,pitch:u,roll:h}=function(t,e,n){const r=e.clone().negate(),i=n.clone().projectOnPlane(e),o=Nn(e,t.clone().projectOnPlane(i),i),s=e.clone().cross(i);return{yaw:o,pitch:Nn(e,t.clone().projectOnPlane(s),s),roll:Nn(i,t.clone().projectOnPlane(r),r)}}(i,o,s);return this.degrees&&(a*=Ln,u*=Ln,h*=Ln),{yaw:{angle:a,name:this.findAzimuthNames("yaw",a)},pitch:{angle:u,name:this.findAzimuthNames("pitch",u)},roll:{angle:h,name:this.findAzimuthNames("roll",h)}}}findAzimuthNames(t,e){const n=[],r=this.listMap[t];if(!r)return n;for(const{name:t,range:[i,o]}of r)(e>=i&&e<o||e<=i&&e>o)&&n.push(t);return n}}An(Mn,"_options");const Vn=new Mn;new o,new e,new TextDecoder,new TextDecoder,new TextDecoder,a.prototype.computeBoundsTree=I,a.prototype.disposeBoundsTree=x,m.prototype.raycast=D,b.prototype.firstHitOnly=!0,t.ColorManagement.enabled=!0;class Fn{constructor(t,e,n){this.ssp=t,this.nativeCamera=e,this.controlOptions=n,this._isActive=!1,this._controlOptionsCache=null,this.ssp.signals.cameraObjectChange.add((()=>{const t=this.ssp.viewport.cameraManager.currentCamera;this._isActive&&t===this.nativeCamera||(t===this.nativeCamera?(this._onBeforeEnter(),this.onEnter()):this._isActive&&t!==this.nativeCamera&&(this._onBeforeQuit(),this.onQuit()))}))}active(){this.ssp.viewport.cameraManager.setCurrentCamera(this.nativeCamera)}_onBeforeEnter(){this.controlOptions&&(this._controlOptionsCache=Object.assign({},this.ssp.viewport.controls.options),this.ssp.setControlsOptions(this.controlOptions)),this._isActive=!0}_onBeforeQuit(){this._controlOptionsCache&&(this.ssp.setControlsOptions(this._controlOptionsCache),this._controlOptionsCache=null),this._isActive=!1}onEnter(){}onQuit(){}}class Hn extends Fn{get zoom(){return this._zoom}set zoom(t){this._zoom=t,this.events.onResize()}constructor(t,e){const n=new c;super(t,n,e),this.ssp=t,this.events={onResize:()=>{}},this._zoom=.01,n.far=2e5}resizeCamera(){if(this._isActive){const{clientWidth:t,clientHeight:e}=this.ssp.viewport.renderer.domElement,n=t*this.zoom/2,r=e*this.zoom/2;this.nativeCamera.left=-n,this.nativeCamera.right=n,this.nativeCamera.top=r,this.nativeCamera.bottom=-r,this.nativeCamera.updateProjectionMatrix()}}initEvents(){const{signals:t}=this.ssp,e=this.resizeCamera.bind(this);this.events.onResize=e,t.windowResize.add(e)}clearEvents(){const{signals:t}=this.ssp;t.windowResize.remove(this.events.onResize)}onEnter(){console.log("map camera enter"),this.initEvents(),this.resizeCamera()}onQuit(){console.log("map camera quit"),this.clearEvents()}}class kn{constructor(t,e,n,r){this.gyroEvent=null,this.onChange=()=>{},this._isActive=!1,this.defaultBeta=null,this.defaultAlpha=null,this.defaultGamma=null,this.cache=null,this.beta=null,this.alpha=null,this.gamma=null,this.gyroX=null==t||t,this.gyroY=null==e||e,this.gyroZ=null==n||n,this.absolute=null==r||r}requestPermisson(){return new Promise(((t,e)=>{var n;window.DeviceOrientationEvent.requestPermission||t(!0),null===(n=window.DeviceOrientationEvent)||void 0===n||n.requestPermission().then((n=>{"granted"===n?t(!0):e("用户拒绝使用陀螺仪权限")}))}))}async active(){await this.requestPermisson(),this._isActive=!0,this.gyroEvent&&this.inActive(),this.gyroEvent=t=>{const{defaultAlpha:e,defaultBeta:n,defaultGamma:r,gyroX:i,gyroY:o,gyroZ:s}=this,{alpha:a,beta:u,gamma:h}=t,c=o&&null!=a?a:e,l=i&&null!=u?u:n,f=s&&null!=h?h:r;if(this.absolute)this.alpha=c,this.beta=l,this.gamma=f;else if(this.cache){const{alpha:t,beta:e,gamma:n}=this.cache;this.alpha=null===c?null:null===t?c:c-t,this.beta=null===l?null:null===e?l:l-e,this.gamma=null===f?null:null===n?f:f-n}else this.cache={alpha:c,beta:l,gamma:f};this.onChange(this.alpha,this.beta,this.gamma)},window.addEventListener("deviceorientation",this.gyroEvent)}inActive(){this._isActive=!1,this.gyroEvent&&(window.removeEventListener("deviceorientation",this.gyroEvent),this.gyroEvent=null)}}var qn,zn;function Kn(t){const n=new r,s=new i,a=new o;return n.lookAt(new e,t,new e(0,1,0)),s.setFromRotationMatrix(n),a.setFromQuaternion(s),a}function Gn(t){return new e(0,0,-1).applyQuaternion((new i).setFromEuler(t))}function Yn(t){return Gn(t).normalize()}function Un(t,e){return"function"==typeof t?t(e):t}function Xn(t,e){return"function"==typeof t?t(e):t}function Jn(t){var e;const n=t.viewport.cameraManager.mainCamera,r=t.viewport.controls.options;let i=0,s=0;const a=new o(0,0,0,"YXZ"),u=t=>{i=t.touches[0].clientX,s=t.touches[0].clientY,document.addEventListener("touchmove",h),document.removeEventListener("touchend",c)},h=t=>{var e,o;const u=t.touches[0].clientX,h=t.touches[0].clientY;let c=u-i,l=h-s;c*=null!==(e=r.rotateSpeed)&&void 0!==e?e:1,l*=null!==(o=r.rotateSpeed)&&void 0!==o?o:1,a.setFromQuaternion(n.quaternion),a.y-=.01*c,a.x-=.01*l,a.x=Math.max(-Math.PI/2,Math.min(Math.PI/2,a.x)),n.quaternion.setFromEuler(a),i=u,s=h},c=()=>{i=0,s=0,document.removeEventListener("touchmove",h),document.removeEventListener("touchend",c)};return null===(e=t.viewport.renderer.domElement.parentElement)||void 0===e||e.addEventListener("touchstart",u),{touchStart:u,touchMove:h,touchEnd:c}}!function(t){t.FIRST_VISION="first",t.THIRD_VISION="third",t.UP_VISION="up",t.LEFT_VISION="left"}(qn||(qn={})),function(t){t.RELATIVE_ORIENTATION="relative",t.FIXED_ORIENTATION="fixed",t.GYRO_ORIENTATION="gyro"}(zn||(zn={}));const Qn={type:"free",enabled:!1},Wn={type:"free",enabled:!0,enablePan:!1,enableZoom:!1,enableRotate:!0},Zn=Object.freeze({disabledAnimate:!1,fixedOrientation:!1,autoRestoreOrientation:1500,oppositeCamera:!1,oppositeType:{x:!1,y:!0,z:!1},orientationTarget:"main",vision:qn.THIRD_VISION,orientationType:zn.RELATIVE_ORIENTATION,rotationToTarget:new e(0,4,-10),distanceToTarget:1,targetRotationFix:[0,0,0,"XYZ"],targetPositionFix:[0,2,0],enableGyro:!1,gyroX:!1,gyroY:!0,gyroZ:!1,gyroAbsolute:!0,onControlStart:null,onControlRender:null,onControlEnd:null});class _n extends Fn{get position(){return this.nativeCamera.position}get rotation(){return this.nativeCamera.rotation}get quaternion(){return this.nativeCamera.quaternion}get lookAt(){return this.nativeCamera.lookAt.bind(this.nativeCamera)}get enableGyro(){return this._enableGyro}set enableGyro(t){this._enableGyro=t,t?this._gyroListener.active():this._gyroListener.inActive()}get gyroX(){return this._gyroListener.gyroX}set gyroX(t){this._gyroListener.gyroX=t}get gyroY(){return this._gyroListener.gyroY}set gyroY(t){this._gyroListener.gyroY=t}get gyroZ(){return this._gyroListener.gyroZ}set gyroZ(t){this._gyroListener.gyroZ=t}get gyroAbsolute(){return this._gyroListener.absolute}set gyroAbsolute(t){this._gyroListener.absolute=t}get targetRotationAfterFix(){return Xn(this.targetRotationFix)}get targetPositionAfterFix(){return Un(this.targetPositionFix)}get realDistanceToTarget(){return"first"===this.vision?1:this.distanceToTarget}get realRotationToTarget(){switch(this.vision){case"first":return new e(0,0,-1);case"up":return new e(0,1,-.01);case"left":return new e(1,0,0);default:return this.rotationToTarget}}get orientationType(){return this._orientationType}set orientationType(t){this._orientationType=t,t===zn.GYRO_ORIENTATION?this._gyroListener.active():this._gyroListener.inActive(),t===zn.FIXED_ORIENTATION&&this._fixedOrientationRotation.copy(this.followRotation),this.restoreOrientation()}get orientationTarget(){return this._orientationTarget}set orientationTarget(t){this._orientationTarget=t,this.restoreOrientation()}get vision(){return this._vision}set vision(t){this._vision=t,this.followTarget.visible=t!==qn.FIRST_VISION,this.restoreOrientation()}get followTarget(){return this._followTarget}set followTarget(t){this._followTarget=t,this.restoreOrientation()}get followPosition(){const t=new e;return t.fromArray(this.targetPositionAfterFix),this.isFixPositionRelativeTarget&&t.applyEuler(this.followRotation),this.followTarget.position.clone().add(t)}get followRotation(){const[t,e,n,r]=this.followTarget.rotation.toArray(),[i,s,a]=this.targetRotationAfterFix;return new o(t+i,e+s,n+a,r)}get fixedOrientation(){return this._fixedOrientation}set fixedOrientation(t){this._fixedOrientation=t,this.ssp.setControlsOptions(t?Qn:Wn),t||this.restoreOrientation()}constructor(t,e,n,r){const i=null!=e?e:new s(80,1,.1,100);super(t,i,Object.assign(Object.assign({},Wn),r)),this.ssp=t,this.initOptions=Zn,this.cameraKey="navigatorCamera"+~~(1e4*Math.random()),this._events={onRender:()=>{},onMouseDown:t=>{}},this._restoreTimer=void 0,this._positionTween=null,this.autoFollowRender=!0,this._cameraPlaceholder=new w,this.disabledAnimate=Zn.disabledAnimate,this.distanceToTarget=Zn.distanceToTarget,this.rotationToTarget=Zn.rotationToTarget,this.oppositeCamera=Zn.oppositeCamera,this.oppositeType=Zn.oppositeType,this.targetRotationFix=Zn.targetRotationFix,this.isFixPositionRelativeTarget=!1,this.targetPositionFix=Zn.targetPositionFix,this.autoRestoreOrientation=Zn.autoRestoreOrientation,this.onControlStart=null,this.onControlRender=null,this.onControlEnd=null,this._enableGyro=!1,this._gyroRotation=new o,this._orientationType=Zn.orientationType,this._fixedOrientationRotation=new o,this._orientationTarget=Zn.orientationTarget,this._vision=Zn.vision,this._followTarget=new w,this._fixedOrientation=Zn.fixedOrientation,this.initGyroListener();const a=Object.freeze(Object.assign(Object.assign({},Zn),null!=n?n:{}));this.initOptions=a,this.setOptions(a),this.setCamera(i)}initGyroListener(){const t=this.initOptions;this._gyroListener=new kn(t.gyroX,t.gyroY,t.gyroZ,t.gyroAbsolute),this._gyroListener.onChange=(t,e,n)=>{const r=null===t?0:S.degToRad(t),i=null===e?0:S.degToRad(e),s=null===n?0:S.degToRad(n);this._gyroRotation=new o(i,r,s)}}setCameraOrientationOnControl(){const{rotation:t}=this.ssp.viewport.cameraManager.mainCamera,{realDistanceToTarget:e,followPosition:n}=this,r=Yn(t);this.position.copy(n.clone().add(r.multiplyScalar(-e))),this.lookAt(this.followPosition)}updateCameraPlaceholder(){const t=this.getRenderCameraPosition();this._cameraPlaceholder.position.copy(t),this._cameraPlaceholder.lookAt(this.followPosition)}setCameraOrientationOnRender(){this.position.copy(this._cameraPlaceholder.position),this.lookAt(this.followPosition)}getRenderCameraOrientation(){const{_fixedOrientationRotation:t,_orientationType:n,_orientationTarget:r}=this;if(n===zn.GYRO_ORIENTATION)return this._gyroRotation;switch(!0){case"main"===r:return n===zn.FIXED_ORIENTATION?t:this.followRotation;case r instanceof e:return Kn(this.orientationTarget.clone().sub(this.followPosition));case r instanceof w:{const t=r;switch(n){case zn.RELATIVE_ORIENTATION:return t.rotation;case zn.FIXED_ORIENTATION:return Kn(t.position.clone().sub(this.followPosition))}return new o}case r instanceof o:return r}return new o}getRenderCameraPosition(){const t=new e,n=this.getRenderCameraOrientation(),{realDistanceToTarget:r,realRotationToTarget:i}=this;if(t.copy(this.followPosition.clone().add(i.clone().applyEuler(n).normalize().multiplyScalar(r))),this.oppositeCamera){const e=this.followPosition.clone().sub(t).multiplyScalar(2),{x:n,y:r,z:i}=this.oppositeType;[n,r,i].includes(!1)&&[n,r,i].includes(!0)?(n&&(e.x=0),r&&(e.y=0),i&&(e.z=0),t.add(e)):n&&t.add(e)}return t}onRender(){this.followTarget&&(this.updateCameraPlaceholder(),this._positionTween||(this.autoFollowRender||this.fixedOrientation?this.setCameraOrientationOnRender():this.onControlRender?this.onControlRender(this.nativeCamera,this.followTarget):this.setCameraOrientationOnControl()))}onEnter(){console.log("onenter"),this.initEvents()}onQuit(){console.log("onquit"),this.clearEvents(),this._gyroListener.inActive()}resetOptions(){this.setOptions(Object.assign({},this.initOptions))}setOptions(t){const e=this.disabledAnimate;this.disabledAnimate=!0,void 0!==t.targetPositionFix&&(this.targetPositionFix=t.targetPositionFix),void 0!==t.targetRotationFix&&(this.targetRotationFix=t.targetRotationFix),void 0!==t.rotationToTarget&&(this.rotationToTarget=t.rotationToTarget),void 0!==t.distanceToTarget&&(this.distanceToTarget=t.distanceToTarget),void 0!==t.fixedOrientation&&(this.fixedOrientation=t.fixedOrientation),void 0!==t.oppositeCamera&&(this.oppositeCamera=t.oppositeCamera),void 0!==t.oppositeType&&(this.oppositeType=t.oppositeType),void 0!==t.orientationTarget&&(this.orientationTarget=t.orientationTarget),void 0!==t.orientationType&&(this.orientationType=t.orientationType),void 0!==t.vision&&(this.vision=t.vision),void 0!==t.autoRestoreOrientation&&(this.autoRestoreOrientation=t.autoRestoreOrientation),void 0!==t.gyroX&&(this.gyroX=t.gyroX),void 0!==t.gyroY&&(this.gyroY=t.gyroY),void 0!==t.gyroZ&&(this.gyroZ=t.gyroZ),void 0!==t.gyroAbsolute&&(this.gyroAbsolute=t.gyroAbsolute),void 0!==t.enableGyro&&(this.enableGyro=t.enableGyro),void 0!==t.onControlStart&&(this.onControlStart=t.onControlStart),void 0!==t.onControlRender&&(this.onControlRender=t.onControlRender),void 0!==t.onControlEnd&&(this.onControlEnd=t.onControlEnd),this.disabledAnimate=e,void 0!==t.disabledAnimate&&(this.disabledAnimate=t.disabledAnimate)}setCamera(t){return this._isActive&&this.ssp.viewport.cameraManager.removeCamera(this.cameraKey),this.nativeCamera=t,this.ssp.viewport.cameraManager.cameras[this.cameraKey]=t,this._isActive&&this.ssp.viewport.cameraManager.setCurrentCamera(t),this}restoreOrientation(){if(this.followTarget&&!this.fixedOrientation){if(this._positionTween&&(this._positionTween.stop(),this._positionTween=null),this.disabledAnimate)return this.position.copy(this._cameraPlaceholder.position),void this.lookAt(this.followPosition);this.ssp.animation(this.position,this._cameraPlaceholder.position,{duration:1e3},(t=>{this.lookAt(this.followPosition)}),(t=>this._positionTween=t)).finally((()=>{this._positionTween=null}))}}initEvents(){var t;const e=this.ssp.viewport.renderer.domElement,n=this.onRender.bind(this),r=t=>{var e,n;const r=!1===this.autoFollowRender;if(this.autoFollowRender=!1,null===(e=this._positionTween)||void 0===e||e.stop(),window.clearTimeout(this._restoreTimer),document.removeEventListener("mouseup",i),document.removeEventListener("touchend",i),document.addEventListener("mouseup",i,!0),document.addEventListener("touchend",i,!0),r)return;this.ssp.viewport.cameraManager.mainCamera.rotation.copy(this.rotation),null===(n=this.onControlStart)||void 0===n||n.call(this,this.nativeCamera,this.followTarget,t)},i=t=>{const e=()=>{var e;this.restoreOrientation(),this.autoFollowRender=!0,null===(e=this.onControlEnd)||void 0===e||e.call(this,this.nativeCamera,this.followTarget,t),document.removeEventListener("mouseup",i,!0),document.removeEventListener("touchend",i,!0)};"number"==typeof this.autoRestoreOrientation?(window.clearTimeout(this._restoreTimer),this._restoreTimer=setTimeout(e,this.autoRestoreOrientation)):this.autoRestoreOrientation&&e()};this._events.onRender=n,this._events.onMouseDown=r;const o=this.ssp.signals;o.beforeRender.add(n),o.mouseDown.add(r),null===(t=e.parentElement)||void 0===t||t.addEventListener("touchstart",r,!0)}clearEvents(){var t;const{onRender:e,onMouseDown:n}=this._events,r=this.ssp.signals,i=this.ssp.viewport.renderer.domElement;r.beforeRender.remove(e),r.mouseDown.remove(n),null===(t=i.parentElement)||void 0===t||t.removeEventListener("touchstart",n,!0)}}var $n;function tr(t,e){Vn.map={yaw:{left:[20,170],right:[-170,-20]},pitch:{up:[20,170],down:[-170,-20]}};const{yaw:n,pitch:r}=Vn.computeAzimuth(t,e),i=n.name,o=r.name;return i&&o?o?i?`${i}-${o}`:o:i:"straight"}function er(t,e){return e.reverse().map((e=>{t.removeObjectById(e.sid);const n=e.nodes.reverse().map((t=>({id:t.id,position:t.position,graphs:t.graphs})));return t.createTopology(Object.assign(Object.assign({},e.info),{nodes:n}))}))}function nr(t,e,n){if(!e||!n)return"straight";return tr(e.position.clone().sub(t.position),n.position.clone().sub(e.position))}function rr(t){const e=t.nodes,n=t.getLength();let r=0,i=0;return e.reduce(((t,o,s)=>{const a=e[s+1],u=e[s+2],h=a?a.position.clone().distanceTo(o.position):0,c=nr(o,a,u),l=r+h,f=l/n,p={progressArea:[i,f],distanceArea:[r,l],node:o,nextNode:a,distanceToStart:r,distanceToEnd:n-r,distanceToNext:h,frontDirection:c};return r=l,i=f,t.push(p),t}),[])}function ir(t,e){return 0===t?e[0]:100===t?e[e.length-1]:e.find((e=>{const[n,r]=e.progressArea;return t>=n&&t<r}))}function or(t,e){if(!e)return{distanceToStartNode:0,distanceToEndNode:0,distanceToStart:0,distanceToEnd:0};const[n,r]=e.progressArea,{distanceToNext:i,distanceToEnd:o,distanceToStart:s}=e,a=(t-n)/(r-n),u=i*a,h=i*(1-a);return{distanceToStartNode:u,distanceToEndNode:h,distanceToStart:u+s,distanceToEnd:o-h}}!function(t){t.PENDING="pending",t.STOP="stop",t.PLAYING="playing",t.PAUSE="pause",t.FINISHED="finished"}($n||($n={}));class sr{get model(){return this._model}set model(t){this._model=t}get speed(){return this._speed}set speed(t){this._speed=t}get pathProgress(){return this._pathProgress}set pathProgress(t){this._pathProgress=t}get totalProgress(){return this._pathProgress}set totalProgress(t){this._pathProgress=t}get currentPath(){return this.paths[this.currentPathIndex]}get currentPathIndex(){return this._currentPathIndex}get currentRotationVector(){return this._nextNode&&this._currentNode?this._nextNode.clone().sub(this._currentNode):new e}constructor(t,e){this.ssp=t,this.paths=e,this.onPlay=()=>{},this.onStatusChange=()=>{},this.loop=!1,this.autoNext=!0,this.playAfterStart=!1,this.flyToModelAfterStart=!0,this.backStartPointWhenStop=!0,this._model=new w,this._speed=1,this._pathProgress=0,this._totalProgress=0,this._currentPathIndex=0,this._currentNode=null,this._nextNode=null,this._playStatus=$n.PENDING}changeStatus(t){this._playStatus=t,this.onStatusChange(t)}start(){}restart(){this.stop(),this.start()}play(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;this.changeStatus($n.PLAYING),this.paths[t]}pause(){this.changeStatus($n.PAUSE)}stop(){this.changeStatus($n.STOP)}flip(){}over(){this.changeStatus($n.PENDING)}}export{kn as GyroListener,Hn as MapCamera,zn as NAVIGATE_ORIENTATION_TYPE,qn as NAVIGATE_VISION_TYPE,_n as NavigateCamera,sr as Navigator,$n as PLAY_STATUS,Fn as SoonSpaceCamera,Kn as Vector3ToEuler,Gn as eulerToVector3,tr as getDirection,nr as getDirectionByNodes,or as getDistanceInfoByProgress,Xn as getFixEuler,Un as getFixVector,ir as getNavigatorNodeInfoByProgress,rr as getNavigatorNodeInfosByTopology,Jn as initTouchToRotateCamera,Yn as normalizeEuler,er as reverseTopologies};
|
|
16
|
+
var In={};void 0!==In.asn1&&In.asn1||(In.asn1={}),In.asn1.ASN1Util=new function(){this.integerToByteHex=function(t){var e=t.toString(16);return e.length%2==1&&(e="0"+e),e},this.bigIntToMinTwosComplementsHex=function(t){var e=t.toString(16);if("-"!=e.substr(0,1))e.length%2==1?e="0"+e:e.match(/^[0-7]/)||(e="00"+e);else{var n=e.substr(1).length;n%2==1?n+=1:e.match(/^[0-7]/)||(n+=2);for(var r="",i=0;i<n;i++)r+="f";e=new We(r,16).xor(t).add(We.ONE).toString(16).replace(/^-/,"")}return e},this.getPEMStringFromHex=function(t,e){return hextopem(t,e)},this.newObject=function(t){var e=In.asn1,n=e.DERBoolean,r=e.DERInteger,i=e.DERBitString,o=e.DEROctetString,s=e.DERNull,a=e.DERObjectIdentifier,u=e.DEREnumerated,h=e.DERUTF8String,c=e.DERNumericString,l=e.DERPrintableString,f=e.DERTeletexString,p=e.DERIA5String,d=e.DERUTCTime,g=e.DERGeneralizedTime,v=e.DERSequence,y=e.DERSet,m=e.DERTaggedObject,b=e.ASN1Util.newObject,w=Object.keys(t);if(1!=w.length)throw"key of param shall be only one.";var S=w[0];if(-1==":bool:int:bitstr:octstr:null:oid:enum:utf8str:numstr:prnstr:telstr:ia5str:utctime:gentime:seq:set:tag:".indexOf(":"+S+":"))throw"undefined key: "+S;if("bool"==S)return new n(t[S]);if("int"==S)return new r(t[S]);if("bitstr"==S)return new i(t[S]);if("octstr"==S)return new o(t[S]);if("null"==S)return new s(t[S]);if("oid"==S)return new a(t[S]);if("enum"==S)return new u(t[S]);if("utf8str"==S)return new h(t[S]);if("numstr"==S)return new c(t[S]);if("prnstr"==S)return new l(t[S]);if("telstr"==S)return new f(t[S]);if("ia5str"==S)return new p(t[S]);if("utctime"==S)return new d(t[S]);if("gentime"==S)return new g(t[S]);if("seq"==S){for(var T=t[S],E=[],O=0;O<T.length;O++){var I=b(T[O]);E.push(I)}return new v({array:E})}if("set"==S){for(T=t[S],E=[],O=0;O<T.length;O++){I=b(T[O]);E.push(I)}return new y({array:E})}if("tag"==S){var x=t[S];if("[object Array]"===Object.prototype.toString.call(x)&&3==x.length){var D=b(x[2]);return new m({tag:x[0],explicit:x[1],obj:D})}var R={};if(void 0!==x.explicit&&(R.explicit=x.explicit),void 0!==x.tag&&(R.tag=x.tag),void 0===x.obj)throw"obj shall be specified for 'tag'.";return R.obj=b(x.obj),new m(R)}},this.jsonToASN1HEX=function(t){return this.newObject(t).getEncodedHex()}},In.asn1.ASN1Util.oidHexToInt=function(t){for(var e="",n=parseInt(t.substr(0,2),16),r=(e=Math.floor(n/40)+"."+n%40,""),i=2;i<t.length;i+=2){var o=("00000000"+parseInt(t.substr(i,2),16).toString(2)).slice(-8);if(r+=o.substr(1,7),"0"==o.substr(0,1))e=e+"."+new We(r,2).toString(10),r=""}return e},In.asn1.ASN1Util.oidIntToHex=function(t){var e=function(t){var e=t.toString(16);return 1==e.length&&(e="0"+e),e},n=function(t){var n="",r=new We(t,10).toString(2),i=7-r.length%7;7==i&&(i=0);for(var o="",s=0;s<i;s++)o+="0";r=o+r;for(s=0;s<r.length-1;s+=7){var a=r.substr(s,7);s!=r.length-7&&(a="1"+a),n+=e(parseInt(a,2))}return n};if(!t.match(/^[0-9.]+$/))throw"malformed oid string: "+t;var r="",i=t.split("."),o=40*parseInt(i[0])+parseInt(i[1]);r+=e(o),i.splice(0,2);for(var s=0;s<i.length;s++)r+=n(i[s]);return r},In.asn1.ASN1Object=function(){this.getLengthHexFromValue=function(){if(void 0===this.hV||null==this.hV)throw"this.hV is null or undefined.";if(this.hV.length%2==1)throw"value hex must be even length: n="+"".length+",v="+this.hV;var t=this.hV.length/2,e=t.toString(16);if(e.length%2==1&&(e="0"+e),t<128)return e;var n=e.length/2;if(n>15)throw"ASN.1 length too long to represent by 8x: n = "+t.toString(16);return(128+n).toString(16)+e},this.getEncodedHex=function(){return(null==this.hTLV||this.isModified)&&(this.hV=this.getFreshValueHex(),this.hL=this.getLengthHexFromValue(),this.hTLV=this.hT+this.hL+this.hV,this.isModified=!1),this.hTLV},this.getValueHex=function(){return this.getEncodedHex(),this.hV},this.getFreshValueHex=function(){return""}},In.asn1.DERAbstractString=function(t){In.asn1.DERAbstractString.superclass.constructor.call(this),this.getString=function(){return this.s},this.setString=function(t){this.hTLV=null,this.isModified=!0,this.s=t,this.hV=stohex(this.s)},this.setStringHex=function(t){this.hTLV=null,this.isModified=!0,this.s=null,this.hV=t},this.getFreshValueHex=function(){return this.hV},void 0!==t&&("string"==typeof t?this.setString(t):void 0!==t.str?this.setString(t.str):void 0!==t.hex&&this.setStringHex(t.hex))},On.lang.extend(In.asn1.DERAbstractString,In.asn1.ASN1Object),In.asn1.DERAbstractTime=function(t){In.asn1.DERAbstractTime.superclass.constructor.call(this),this.localDateToUTC=function(t){return utc=t.getTime()+6e4*t.getTimezoneOffset(),new Date(utc)},this.formatDate=function(t,e,n){var r=this.zeroPadding,i=this.localDateToUTC(t),o=String(i.getFullYear());"utc"==e&&(o=o.substr(2,2));var s=o+r(String(i.getMonth()+1),2)+r(String(i.getDate()),2)+r(String(i.getHours()),2)+r(String(i.getMinutes()),2)+r(String(i.getSeconds()),2);if(!0===n){var a=i.getMilliseconds();if(0!=a){var u=r(String(a),3);s=s+"."+(u=u.replace(/[0]+$/,""))}}return s+"Z"},this.zeroPadding=function(t,e){return t.length>=e?t:new Array(e-t.length+1).join("0")+t},this.getString=function(){return this.s},this.setString=function(t){this.hTLV=null,this.isModified=!0,this.s=t,this.hV=stohex(t)},this.setByDateValue=function(t,e,n,r,i,o){var s=new Date(Date.UTC(t,e-1,n,r,i,o,0));this.setByDate(s)},this.getFreshValueHex=function(){return this.hV}},On.lang.extend(In.asn1.DERAbstractTime,In.asn1.ASN1Object),In.asn1.DERAbstractStructured=function(t){In.asn1.DERAbstractString.superclass.constructor.call(this),this.setByASN1ObjectArray=function(t){this.hTLV=null,this.isModified=!0,this.asn1Array=t},this.appendASN1Object=function(t){this.hTLV=null,this.isModified=!0,this.asn1Array.push(t)},this.asn1Array=new Array,void 0!==t&&void 0!==t.array&&(this.asn1Array=t.array)},On.lang.extend(In.asn1.DERAbstractStructured,In.asn1.ASN1Object),In.asn1.DERBoolean=function(){In.asn1.DERBoolean.superclass.constructor.call(this),this.hT="01",this.hTLV="0101ff"},On.lang.extend(In.asn1.DERBoolean,In.asn1.ASN1Object),In.asn1.DERInteger=function(t){In.asn1.DERInteger.superclass.constructor.call(this),this.hT="02",this.setByBigInteger=function(t){this.hTLV=null,this.isModified=!0,this.hV=In.asn1.ASN1Util.bigIntToMinTwosComplementsHex(t)},this.setByInteger=function(t){var e=new We(String(t),10);this.setByBigInteger(e)},this.setValueHex=function(t){this.hV=t},this.getFreshValueHex=function(){return this.hV},void 0!==t&&(void 0!==t.bigint?this.setByBigInteger(t.bigint):void 0!==t.int?this.setByInteger(t.int):"number"==typeof t?this.setByInteger(t):void 0!==t.hex&&this.setValueHex(t.hex))},On.lang.extend(In.asn1.DERInteger,In.asn1.ASN1Object),In.asn1.DERBitString=function(t){if(void 0!==t&&void 0!==t.obj){var e=In.asn1.ASN1Util.newObject(t.obj);t.hex="00"+e.getEncodedHex()}In.asn1.DERBitString.superclass.constructor.call(this),this.hT="03",this.setHexValueIncludingUnusedBits=function(t){this.hTLV=null,this.isModified=!0,this.hV=t},this.setUnusedBitsAndHexValue=function(t,e){if(t<0||7<t)throw"unused bits shall be from 0 to 7: u = "+t;var n="0"+t;this.hTLV=null,this.isModified=!0,this.hV=n+e},this.setByBinaryString=function(t){var e=8-(t=t.replace(/0+$/,"")).length%8;8==e&&(e=0);for(var n=0;n<=e;n++)t+="0";var r="";for(n=0;n<t.length-1;n+=8){var i=t.substr(n,8),o=parseInt(i,2).toString(16);1==o.length&&(o="0"+o),r+=o}this.hTLV=null,this.isModified=!0,this.hV="0"+e+r},this.setByBooleanArray=function(t){for(var e="",n=0;n<t.length;n++)1==t[n]?e+="1":e+="0";this.setByBinaryString(e)},this.newFalseArray=function(t){for(var e=new Array(t),n=0;n<t;n++)e[n]=!1;return e},this.getFreshValueHex=function(){return this.hV},void 0!==t&&("string"==typeof t&&t.toLowerCase().match(/^[0-9a-f]+$/)?this.setHexValueIncludingUnusedBits(t):void 0!==t.hex?this.setHexValueIncludingUnusedBits(t.hex):void 0!==t.bin?this.setByBinaryString(t.bin):void 0!==t.array&&this.setByBooleanArray(t.array))},On.lang.extend(In.asn1.DERBitString,In.asn1.ASN1Object),In.asn1.DEROctetString=function(t){if(void 0!==t&&void 0!==t.obj){var e=In.asn1.ASN1Util.newObject(t.obj);t.hex=e.getEncodedHex()}In.asn1.DEROctetString.superclass.constructor.call(this,t),this.hT="04"},On.lang.extend(In.asn1.DEROctetString,In.asn1.DERAbstractString),In.asn1.DERNull=function(){In.asn1.DERNull.superclass.constructor.call(this),this.hT="05",this.hTLV="0500"},On.lang.extend(In.asn1.DERNull,In.asn1.ASN1Object),In.asn1.DERObjectIdentifier=function(t){var e=function(t){var e=t.toString(16);return 1==e.length&&(e="0"+e),e},n=function(t){var n="",r=new We(t,10).toString(2),i=7-r.length%7;7==i&&(i=0);for(var o="",s=0;s<i;s++)o+="0";r=o+r;for(s=0;s<r.length-1;s+=7){var a=r.substr(s,7);s!=r.length-7&&(a="1"+a),n+=e(parseInt(a,2))}return n};In.asn1.DERObjectIdentifier.superclass.constructor.call(this),this.hT="06",this.setValueHex=function(t){this.hTLV=null,this.isModified=!0,this.s=null,this.hV=t},this.setValueOidString=function(t){if(!t.match(/^[0-9.]+$/))throw"malformed oid string: "+t;var r="",i=t.split("."),o=40*parseInt(i[0])+parseInt(i[1]);r+=e(o),i.splice(0,2);for(var s=0;s<i.length;s++)r+=n(i[s]);this.hTLV=null,this.isModified=!0,this.s=null,this.hV=r},this.setValueName=function(t){var e=In.asn1.x509.OID.name2oid(t);if(""===e)throw"DERObjectIdentifier oidName undefined: "+t;this.setValueOidString(e)},this.getFreshValueHex=function(){return this.hV},void 0!==t&&("string"==typeof t?t.match(/^[0-2].[0-9.]+$/)?this.setValueOidString(t):this.setValueName(t):void 0!==t.oid?this.setValueOidString(t.oid):void 0!==t.hex?this.setValueHex(t.hex):void 0!==t.name&&this.setValueName(t.name))},On.lang.extend(In.asn1.DERObjectIdentifier,In.asn1.ASN1Object),In.asn1.DEREnumerated=function(t){In.asn1.DEREnumerated.superclass.constructor.call(this),this.hT="0a",this.setByBigInteger=function(t){this.hTLV=null,this.isModified=!0,this.hV=In.asn1.ASN1Util.bigIntToMinTwosComplementsHex(t)},this.setByInteger=function(t){var e=new We(String(t),10);this.setByBigInteger(e)},this.setValueHex=function(t){this.hV=t},this.getFreshValueHex=function(){return this.hV},void 0!==t&&(void 0!==t.int?this.setByInteger(t.int):"number"==typeof t?this.setByInteger(t):void 0!==t.hex&&this.setValueHex(t.hex))},On.lang.extend(In.asn1.DEREnumerated,In.asn1.ASN1Object),In.asn1.DERUTF8String=function(t){In.asn1.DERUTF8String.superclass.constructor.call(this,t),this.hT="0c"},On.lang.extend(In.asn1.DERUTF8String,In.asn1.DERAbstractString),In.asn1.DERNumericString=function(t){In.asn1.DERNumericString.superclass.constructor.call(this,t),this.hT="12"},On.lang.extend(In.asn1.DERNumericString,In.asn1.DERAbstractString),In.asn1.DERPrintableString=function(t){In.asn1.DERPrintableString.superclass.constructor.call(this,t),this.hT="13"},On.lang.extend(In.asn1.DERPrintableString,In.asn1.DERAbstractString),In.asn1.DERTeletexString=function(t){In.asn1.DERTeletexString.superclass.constructor.call(this,t),this.hT="14"},On.lang.extend(In.asn1.DERTeletexString,In.asn1.DERAbstractString),In.asn1.DERIA5String=function(t){In.asn1.DERIA5String.superclass.constructor.call(this,t),this.hT="16"},On.lang.extend(In.asn1.DERIA5String,In.asn1.DERAbstractString),In.asn1.DERUTCTime=function(t){In.asn1.DERUTCTime.superclass.constructor.call(this,t),this.hT="17",this.setByDate=function(t){this.hTLV=null,this.isModified=!0,this.date=t,this.s=this.formatDate(this.date,"utc"),this.hV=stohex(this.s)},this.getFreshValueHex=function(){return void 0===this.date&&void 0===this.s&&(this.date=new Date,this.s=this.formatDate(this.date,"utc"),this.hV=stohex(this.s)),this.hV},void 0!==t&&(void 0!==t.str?this.setString(t.str):"string"==typeof t&&t.match(/^[0-9]{12}Z$/)?this.setString(t):void 0!==t.hex?this.setStringHex(t.hex):void 0!==t.date&&this.setByDate(t.date))},On.lang.extend(In.asn1.DERUTCTime,In.asn1.DERAbstractTime),In.asn1.DERGeneralizedTime=function(t){In.asn1.DERGeneralizedTime.superclass.constructor.call(this,t),this.hT="18",this.withMillis=!1,this.setByDate=function(t){this.hTLV=null,this.isModified=!0,this.date=t,this.s=this.formatDate(this.date,"gen",this.withMillis),this.hV=stohex(this.s)},this.getFreshValueHex=function(){return void 0===this.date&&void 0===this.s&&(this.date=new Date,this.s=this.formatDate(this.date,"gen",this.withMillis),this.hV=stohex(this.s)),this.hV},void 0!==t&&(void 0!==t.str?this.setString(t.str):"string"==typeof t&&t.match(/^[0-9]{14}Z$/)?this.setString(t):void 0!==t.hex?this.setStringHex(t.hex):void 0!==t.date&&this.setByDate(t.date),!0===t.millis&&(this.withMillis=!0))},On.lang.extend(In.asn1.DERGeneralizedTime,In.asn1.DERAbstractTime),In.asn1.DERSequence=function(t){In.asn1.DERSequence.superclass.constructor.call(this,t),this.hT="30",this.getFreshValueHex=function(){for(var t="",e=0;e<this.asn1Array.length;e++){t+=this.asn1Array[e].getEncodedHex()}return this.hV=t,this.hV}},On.lang.extend(In.asn1.DERSequence,In.asn1.DERAbstractStructured),In.asn1.DERSet=function(t){In.asn1.DERSet.superclass.constructor.call(this,t),this.hT="31",this.sortFlag=!0,this.getFreshValueHex=function(){for(var t=new Array,e=0;e<this.asn1Array.length;e++){var n=this.asn1Array[e];t.push(n.getEncodedHex())}return 1==this.sortFlag&&t.sort(),this.hV=t.join(""),this.hV},void 0!==t&&void 0!==t.sortflag&&0==t.sortflag&&(this.sortFlag=!1)},On.lang.extend(In.asn1.DERSet,In.asn1.DERAbstractStructured),In.asn1.DERTaggedObject=function(t){In.asn1.DERTaggedObject.superclass.constructor.call(this),this.hT="a0",this.hV="",this.isExplicit=!0,this.asn1Object=null,this.setASN1Object=function(t,e,n){this.hT=e,this.isExplicit=t,this.asn1Object=n,this.isExplicit?(this.hV=this.asn1Object.getEncodedHex(),this.hTLV=null,this.isModified=!0):(this.hV=null,this.hTLV=n.getEncodedHex(),this.hTLV=this.hTLV.replace(/^../,e),this.isModified=!1)},this.getFreshValueHex=function(){return this.hV},void 0!==t&&(void 0!==t.tag&&(this.hT=t.tag),void 0!==t.explicit&&(this.isExplicit=t.explicit),void 0!==t.obj&&(this.asn1Object=t.obj,this.setASN1Object(this.isExplicit,this.hT,this.asn1Object)))},On.lang.extend(In.asn1.DERTaggedObject,In.asn1.ASN1Object);var xn,Dn,Rn=function(){var t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},t(e,n)};return function(e,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();!function(t){function e(n){var r=t.call(this)||this;return n&&("string"==typeof n?r.parseKey(n):(e.hasPrivateKeyProperty(n)||e.hasPublicKeyProperty(n))&&r.parsePropertiesFrom(n)),r}Rn(e,t),e.prototype.parseKey=function(t){try{var e=0,n=0,r=/^\s*(?:[0-9A-Fa-f][0-9A-Fa-f]\s*)+$/.test(t)?Me(t):Ve.unarmor(t),i=Ue.decode(r);if(3===i.sub.length&&(i=i.sub[2].sub[0]),9===i.sub.length){e=i.sub[1].getHexStringValue(),this.n=nn(e,16),n=i.sub[2].getHexStringValue(),this.e=parseInt(n,16);var o=i.sub[3].getHexStringValue();this.d=nn(o,16);var s=i.sub[4].getHexStringValue();this.p=nn(s,16);var a=i.sub[5].getHexStringValue();this.q=nn(a,16);var u=i.sub[6].getHexStringValue();this.dmp1=nn(u,16);var h=i.sub[7].getHexStringValue();this.dmq1=nn(h,16);var c=i.sub[8].getHexStringValue();this.coeff=nn(c,16)}else{if(2!==i.sub.length)return!1;if(i.sub[0].sub){var l=i.sub[1].sub[0];e=l.sub[0].getHexStringValue(),this.n=nn(e,16),n=l.sub[1].getHexStringValue(),this.e=parseInt(n,16)}else e=i.sub[0].getHexStringValue(),this.n=nn(e,16),n=i.sub[1].getHexStringValue(),this.e=parseInt(n,16)}return!0}catch(t){return!1}},e.prototype.getPrivateBaseKey=function(){var t={array:[new In.asn1.DERInteger({int:0}),new In.asn1.DERInteger({bigint:this.n}),new In.asn1.DERInteger({int:this.e}),new In.asn1.DERInteger({bigint:this.d}),new In.asn1.DERInteger({bigint:this.p}),new In.asn1.DERInteger({bigint:this.q}),new In.asn1.DERInteger({bigint:this.dmp1}),new In.asn1.DERInteger({bigint:this.dmq1}),new In.asn1.DERInteger({bigint:this.coeff})]};return new In.asn1.DERSequence(t).getEncodedHex()},e.prototype.getPrivateBaseKeyB64=function(){return Ce(this.getPrivateBaseKey())},e.prototype.getPublicBaseKey=function(){var t=new In.asn1.DERSequence({array:[new In.asn1.DERObjectIdentifier({oid:"1.2.840.113549.1.1.1"}),new In.asn1.DERNull]}),e=new In.asn1.DERSequence({array:[new In.asn1.DERInteger({bigint:this.n}),new In.asn1.DERInteger({int:this.e})]}),n=new In.asn1.DERBitString({hex:"00"+e.getEncodedHex()});return new In.asn1.DERSequence({array:[t,n]}).getEncodedHex()},e.prototype.getPublicBaseKeyB64=function(){return Ce(this.getPublicBaseKey())},e.wordwrap=function(t,e){if(!t)return t;var n="(.{1,"+(e=e||64)+"})( +|$\n?)|(.{1,"+e+"})";return t.match(RegExp(n,"g")).join("\n")},e.prototype.getPrivateKey=function(){var t="-----BEGIN RSA PRIVATE KEY-----\n";return t+=e.wordwrap(this.getPrivateBaseKeyB64())+"\n",t+="-----END RSA PRIVATE KEY-----"},e.prototype.getPublicKey=function(){var t="-----BEGIN PUBLIC KEY-----\n";return t+=e.wordwrap(this.getPublicBaseKeyB64())+"\n",t+="-----END PUBLIC KEY-----"},e.hasPublicKeyProperty=function(t){return(t=t||{}).hasOwnProperty("n")&&t.hasOwnProperty("e")},e.hasPrivateKeyProperty=function(t){return(t=t||{}).hasOwnProperty("n")&&t.hasOwnProperty("e")&&t.hasOwnProperty("d")&&t.hasOwnProperty("p")&&t.hasOwnProperty("q")&&t.hasOwnProperty("dmp1")&&t.hasOwnProperty("dmq1")&&t.hasOwnProperty("coeff")},e.prototype.parsePropertiesFrom=function(t){this.n=t.n,this.e=t.e,t.hasOwnProperty("d")&&(this.d=t.d,this.p=t.p,this.q=t.q,this.dmp1=t.dmp1,this.dmq1=t.dmq1,this.coeff=t.coeff)}}(Tn),void 0!==$&&(null===(xn=$.env)||void 0===xn||xn.npm_package_version),new t.Vector4,new g,new v,function(t){t.sbm="SBM",t.sbmx="SBMX",t.dat="DAT",t.glb="GLB",t.gltf="GLTF",t.fbx="FBX"}(Dn||(Dn={})),new y([0,0,1,0,1,1,1,1,0,1,0,0],2);var Pn=Object.defineProperty,An=(t,e,n)=>(((t,e,n)=>{e in t?Pn(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n})(t,"symbol"!=typeof e?e+"":e,n),n),Bn=(t=>(t[t.x=0]="x",t[t.y=1]="y",t[t.z=2]="z",t))(Bn||{});function Nn(t,e,n){let r=function(t,e){const n=Math.sqrt(t.lengthSq()*e.lengthSq());if(0===n)return 0;let r=t.dot(e)/n;return r=Math.max(-1,Math.min(1,r)),Math.acos(r)}(t,e);return 0===r?r:t.clone().cross(e).dot(n)<0?-r:r}(t=>{t.toKey=function(e){return t[e]},t.toIndex=function(e){return t[e]}})(Bn||(Bn={}));const Ln=180/Math.PI,Cn={yaw:[{name:"前",range:[-15,15]},{name:"左",range:[15,165]},{name:"右",range:[-165,-15]},{name:"后",range:[-180.1,-165]},{name:"后",range:[165,180.1]}],pitch:[{name:"前",range:[-15,15]},{name:"上",range:[15,165]},{name:"下",range:[-165,-15]},{name:"后",range:[-180.1,-165]},{name:"后",range:[165,180.1]}],roll:[{name:"上",range:[-15,15]},{name:"左",range:[15,165]},{name:"右",range:[-165,-15]},{name:"下",range:[-180.1,-165]},{name:"下",range:[165,180.1]}]};const jn={degrees:!0,map:Cn,front:{x:0,y:0,z:1},up:{x:0,y:1,z:0}};class Mn{constructor(t){An(this,"_options"),An(this,"_listMap"),An(this,"_front"),An(this,"_up"),t&&(this.options=t)}static get options(){return this._options??(this.options=jn)}static set options(t){this._options=Object.assign({},structuredClone(Cn),t)}get defaultOptions(){return this.constructor.options}get options(){return this._options??(this.options=this.defaultOptions)}set options(t){this._options=Object.assign({},structuredClone(this.defaultOptions),t),this._listMap=null,this._front=null,this._up=null}get degrees(){return this.options.degrees??(this.options.degrees=this.defaultOptions.degrees??!0)}set degrees(t){this.options.degrees=t}get map(){return this.options.map||(this.map=this.defaultOptions.map),this.options.map}set map(t){const e=structuredClone(this.defaultOptions.map),n=structuredClone(Cn);t=t?{yaw:t.yaw??e.yaw??n.yaw,pitch:t.pitch??e.pitch??n.pitch,roll:t.roll??e.roll??n.roll}:e,this.options.map=t,this._listMap=null}get listMap(){return this._listMap??(this._listMap=function(t){const e={};for(const[n,r]of Object.entries(t))e[n]=Array.isArray(r)?r:Object.entries(r).map((([t,e])=>({name:t,range:e})));return e}(this.map??{}))}get front(){return this._front||(this.front=this.options.front??this.defaultOptions.front??jn.front),this._front}set front(t){this._front=(new e).copy(t)}get up(){return this._up||(this.up=this.options.up??this.defaultOptions.up??jn.up),this._up}set up(t){this._up=(new e).copy(t)}computeAzimuth(t,n,r){const i=(new e).copy(t),o=(new e).copy(n??this.front),s=(new e).copy(r??this.up);let{yaw:a,pitch:u,roll:h}=function(t,e,n){const r=e.clone().negate(),i=n.clone().projectOnPlane(e),o=Nn(e,t.clone().projectOnPlane(i),i),s=e.clone().cross(i);return{yaw:o,pitch:Nn(e,t.clone().projectOnPlane(s),s),roll:Nn(i,t.clone().projectOnPlane(r),r)}}(i,o,s);return this.degrees&&(a*=Ln,u*=Ln,h*=Ln),{yaw:{angle:a,name:this.findAzimuthNames("yaw",a)},pitch:{angle:u,name:this.findAzimuthNames("pitch",u)},roll:{angle:h,name:this.findAzimuthNames("roll",h)}}}findAzimuthNames(t,e){const n=[],r=this.listMap[t];if(!r)return n;for(const{name:t,range:[i,o]}of r)(e>=i&&e<o||e<=i&&e>o)&&n.push(t);return n}}An(Mn,"_options");const Vn=new Mn;new o,new e,new TextDecoder,new TextEncoder,new TextDecoder,new TextDecoder,a.prototype.computeBoundsTree=I,a.prototype.disposeBoundsTree=x,m.prototype.raycast=D,b.prototype.firstHitOnly=!0,t.ColorManagement.enabled=!0;class Fn{constructor(t,e,n){this.ssp=t,this.nativeCamera=e,this.controlOptions=n,this._isActive=!1,this._controlOptionsCache=null,this.ssp.signals.cameraObjectChange.add((()=>{const t=this.ssp.viewport.cameraManager.currentCamera;this._isActive&&t===this.nativeCamera||(t===this.nativeCamera?(this._onBeforeEnter(),this.onEnter()):this._isActive&&t!==this.nativeCamera&&(this._onBeforeQuit(),this.onQuit()))}))}active(){this.ssp.viewport.cameraManager.setCurrentCamera(this.nativeCamera)}_onBeforeEnter(){this.controlOptions&&(this._controlOptionsCache=Object.assign({},this.ssp.viewport.controls.options),this.ssp.setControlsOptions(this.controlOptions)),this._isActive=!0}_onBeforeQuit(){this._controlOptionsCache&&(this.ssp.setControlsOptions(this._controlOptionsCache),this._controlOptionsCache=null),this._isActive=!1}onEnter(){}onQuit(){}}class Hn extends Fn{get zoom(){return this._zoom}set zoom(t){this._zoom=t,this.events.onResize()}constructor(t,e){const n=new c;super(t,n,e),this.ssp=t,this.events={onResize:()=>{}},this._zoom=.01,n.far=2e5}resizeCamera(){if(this._isActive){const{clientWidth:t,clientHeight:e}=this.ssp.viewport.renderer.domElement,n=t*this.zoom/2,r=e*this.zoom/2;this.nativeCamera.left=-n,this.nativeCamera.right=n,this.nativeCamera.top=r,this.nativeCamera.bottom=-r,this.nativeCamera.updateProjectionMatrix()}}initEvents(){const{signals:t}=this.ssp,e=this.resizeCamera.bind(this);this.events.onResize=e,t.windowResize.add(e)}clearEvents(){const{signals:t}=this.ssp;t.windowResize.remove(this.events.onResize)}onEnter(){console.log("map camera enter"),this.initEvents(),this.resizeCamera()}onQuit(){console.log("map camera quit"),this.clearEvents()}}class kn{constructor(t,e,n,r){this.gyroEvent=null,this.onChange=()=>{},this._isActive=!1,this.defaultBeta=null,this.defaultAlpha=null,this.defaultGamma=null,this.cache=null,this.beta=null,this.alpha=null,this.gamma=null,this.gyroX=null==t||t,this.gyroY=null==e||e,this.gyroZ=null==n||n,this.absolute=null==r||r}requestPermisson(){return new Promise(((t,e)=>{var n;window.DeviceOrientationEvent.requestPermission||t(!0),null===(n=window.DeviceOrientationEvent)||void 0===n||n.requestPermission().then((n=>{"granted"===n?t(!0):e("用户拒绝使用陀螺仪权限")}))}))}async active(){await this.requestPermisson(),this._isActive=!0,this.gyroEvent&&this.inActive(),this.gyroEvent=t=>{const{defaultAlpha:e,defaultBeta:n,defaultGamma:r,gyroX:i,gyroY:o,gyroZ:s}=this,{alpha:a,beta:u,gamma:h}=t,c=o&&null!=a?a:e,l=i&&null!=u?u:n,f=s&&null!=h?h:r;if(this.absolute)this.alpha=c,this.beta=l,this.gamma=f;else if(this.cache){const{alpha:t,beta:e,gamma:n}=this.cache;this.alpha=null===c?null:null===t?c:c-t,this.beta=null===l?null:null===e?l:l-e,this.gamma=null===f?null:null===n?f:f-n}else this.cache={alpha:c,beta:l,gamma:f};this.onChange(this.alpha,this.beta,this.gamma)},window.addEventListener("deviceorientation",this.gyroEvent)}inActive(){this._isActive=!1,this.gyroEvent&&(window.removeEventListener("deviceorientation",this.gyroEvent),this.gyroEvent=null)}}var qn,zn;function Kn(t){const n=new r,s=new i,a=new o;return n.lookAt(new e,t,new e(0,1,0)),s.setFromRotationMatrix(n),a.setFromQuaternion(s),a}function Gn(t){return new e(0,0,-1).applyQuaternion((new i).setFromEuler(t))}function Yn(t){return Gn(t).normalize()}function Un(t,e){return"function"==typeof t?t(e):t}function Xn(t,e){return"function"==typeof t?t(e):t}function Jn(t){var e;const n=t.viewport.cameraManager.mainCamera,r=t.viewport.controls.options;let i=0,s=0;const a=new o(0,0,0,"YXZ"),u=t=>{i=t.touches[0].clientX,s=t.touches[0].clientY,document.addEventListener("touchmove",h),document.removeEventListener("touchend",c)},h=t=>{var e,o;const u=t.touches[0].clientX,h=t.touches[0].clientY;let c=u-i,l=h-s;c*=null!==(e=r.rotateSpeed)&&void 0!==e?e:1,l*=null!==(o=r.rotateSpeed)&&void 0!==o?o:1,a.setFromQuaternion(n.quaternion),a.y-=.01*c,a.x-=.01*l,a.x=Math.max(-Math.PI/2,Math.min(Math.PI/2,a.x)),n.quaternion.setFromEuler(a),i=u,s=h},c=()=>{i=0,s=0,document.removeEventListener("touchmove",h),document.removeEventListener("touchend",c)};return null===(e=t.viewport.renderer.domElement.parentElement)||void 0===e||e.addEventListener("touchstart",u),{touchStart:u,touchMove:h,touchEnd:c}}!function(t){t.FIRST_VISION="first",t.THIRD_VISION="third",t.UP_VISION="up",t.LEFT_VISION="left"}(qn||(qn={})),function(t){t.RELATIVE_ORIENTATION="relative",t.FIXED_ORIENTATION="fixed",t.GYRO_ORIENTATION="gyro"}(zn||(zn={}));const Qn={type:"free",enabled:!1},Wn={type:"free",enabled:!0,enablePan:!1,enableZoom:!1,enableRotate:!0},Zn=Object.freeze({disabledAnimate:!1,fixedOrientation:!1,autoRestoreOrientation:1500,oppositeCamera:!1,oppositeType:{x:!1,y:!0,z:!1},orientationTarget:"main",vision:qn.THIRD_VISION,orientationType:zn.RELATIVE_ORIENTATION,rotationToTarget:new e(0,4,-10),distanceToTarget:1,targetRotationFix:[0,0,0,"XYZ"],targetPositionFix:[0,2,0],enableGyro:!1,gyroX:!1,gyroY:!0,gyroZ:!1,gyroAbsolute:!0,onControlStart:null,onControlRender:null,onControlEnd:null});class _n extends Fn{get position(){return this.nativeCamera.position}get rotation(){return this.nativeCamera.rotation}get quaternion(){return this.nativeCamera.quaternion}get lookAt(){return this.nativeCamera.lookAt.bind(this.nativeCamera)}get enableGyro(){return this._enableGyro}set enableGyro(t){this._enableGyro=t,t?this._gyroListener.active():this._gyroListener.inActive()}get gyroX(){return this._gyroListener.gyroX}set gyroX(t){this._gyroListener.gyroX=t}get gyroY(){return this._gyroListener.gyroY}set gyroY(t){this._gyroListener.gyroY=t}get gyroZ(){return this._gyroListener.gyroZ}set gyroZ(t){this._gyroListener.gyroZ=t}get gyroAbsolute(){return this._gyroListener.absolute}set gyroAbsolute(t){this._gyroListener.absolute=t}get targetRotationAfterFix(){return Xn(this.targetRotationFix)}get targetPositionAfterFix(){return Un(this.targetPositionFix)}get realDistanceToTarget(){return"first"===this.vision?1:this.distanceToTarget}get realRotationToTarget(){switch(this.vision){case"first":return new e(0,0,-1);case"up":return new e(0,1,-.01);case"left":return new e(1,0,0);default:return this.rotationToTarget}}get orientationType(){return this._orientationType}set orientationType(t){this._orientationType=t,t===zn.GYRO_ORIENTATION?this._gyroListener.active():this._gyroListener.inActive(),t===zn.FIXED_ORIENTATION&&this._fixedOrientationRotation.copy(this.followRotation),this.restoreOrientation()}get orientationTarget(){return this._orientationTarget}set orientationTarget(t){this._orientationTarget=t,this.restoreOrientation()}get vision(){return this._vision}set vision(t){this._vision=t,this.followTarget.visible=t!==qn.FIRST_VISION,this.restoreOrientation()}get followTarget(){return this._followTarget}set followTarget(t){this._followTarget=t,this.restoreOrientation()}get followPosition(){const t=new e;return t.fromArray(this.targetPositionAfterFix),this.isFixPositionRelativeTarget&&t.applyEuler(this.followRotation),this.followTarget.position.clone().add(t)}get followRotation(){const[t,e,n,r]=this.followTarget.rotation.toArray(),[i,s,a]=this.targetRotationAfterFix;return new o(t+i,e+s,n+a,r)}get fixedOrientation(){return this._fixedOrientation}set fixedOrientation(t){this._fixedOrientation=t,this.ssp.setControlsOptions(t?Qn:Wn),t||this.restoreOrientation()}constructor(t,e,n,r){const i=null!=e?e:new s(80,1,.1,100);super(t,i,Object.assign(Object.assign({},Wn),r)),this.ssp=t,this.initOptions=Zn,this.cameraKey="navigatorCamera"+~~(1e4*Math.random()),this._events={onRender:()=>{},onMouseDown:t=>{}},this._restoreTimer=void 0,this._positionTween=null,this.autoFollowRender=!0,this._cameraPlaceholder=new w,this.disabledAnimate=Zn.disabledAnimate,this.distanceToTarget=Zn.distanceToTarget,this.rotationToTarget=Zn.rotationToTarget,this.oppositeCamera=Zn.oppositeCamera,this.oppositeType=Zn.oppositeType,this.targetRotationFix=Zn.targetRotationFix,this.isFixPositionRelativeTarget=!1,this.targetPositionFix=Zn.targetPositionFix,this.autoRestoreOrientation=Zn.autoRestoreOrientation,this.onControlStart=null,this.onControlRender=null,this.onControlEnd=null,this._enableGyro=!1,this._gyroRotation=new o,this._orientationType=Zn.orientationType,this._fixedOrientationRotation=new o,this._orientationTarget=Zn.orientationTarget,this._vision=Zn.vision,this._followTarget=new w,this._fixedOrientation=Zn.fixedOrientation,this.initGyroListener();const a=Object.freeze(Object.assign(Object.assign({},Zn),null!=n?n:{}));this.initOptions=a,this.setOptions(a),this.setCamera(i)}initGyroListener(){const t=this.initOptions;this._gyroListener=new kn(t.gyroX,t.gyroY,t.gyroZ,t.gyroAbsolute),this._gyroListener.onChange=(t,e,n)=>{const r=null===t?0:S.degToRad(t),i=null===e?0:S.degToRad(e),s=null===n?0:S.degToRad(n);this._gyroRotation=new o(i,r,s)}}setCameraOrientationOnControl(){const{rotation:t}=this.ssp.viewport.cameraManager.mainCamera,{realDistanceToTarget:e,followPosition:n}=this,r=Yn(t);this.position.copy(n.clone().add(r.multiplyScalar(-e))),this.lookAt(this.followPosition)}updateCameraPlaceholder(){const t=this.getRenderCameraPosition();this._cameraPlaceholder.position.copy(t),this._cameraPlaceholder.lookAt(this.followPosition)}setCameraOrientationOnRender(){this.position.copy(this._cameraPlaceholder.position),this.lookAt(this.followPosition)}getRenderCameraOrientation(){const{_fixedOrientationRotation:t,_orientationType:n,_orientationTarget:r}=this;if(n===zn.GYRO_ORIENTATION)return this._gyroRotation;switch(!0){case"main"===r:return n===zn.FIXED_ORIENTATION?t:this.followRotation;case r instanceof e:return Kn(this.orientationTarget.clone().sub(this.followPosition));case r instanceof w:{const t=r;switch(n){case zn.RELATIVE_ORIENTATION:return t.rotation;case zn.FIXED_ORIENTATION:return Kn(t.position.clone().sub(this.followPosition))}return new o}case r instanceof o:return r}return new o}getRenderCameraPosition(){const t=new e,n=this.getRenderCameraOrientation(),{realDistanceToTarget:r,realRotationToTarget:i}=this;if(t.copy(this.followPosition.clone().add(i.clone().applyEuler(n).normalize().multiplyScalar(r))),this.oppositeCamera){const e=this.followPosition.clone().sub(t).multiplyScalar(2),{x:n,y:r,z:i}=this.oppositeType;[n,r,i].includes(!1)&&[n,r,i].includes(!0)?(n&&(e.x=0),r&&(e.y=0),i&&(e.z=0),t.add(e)):n&&t.add(e)}return t}onRender(){this.followTarget&&(this.updateCameraPlaceholder(),this._positionTween||(this.autoFollowRender||this.fixedOrientation?this.setCameraOrientationOnRender():this.onControlRender?this.onControlRender(this.nativeCamera,this.followTarget):this.setCameraOrientationOnControl()))}onEnter(){console.log("onenter"),this.initEvents()}onQuit(){console.log("onquit"),this.clearEvents(),this._gyroListener.inActive()}resetOptions(){this.setOptions(Object.assign({},this.initOptions))}setOptions(t){const e=this.disabledAnimate;this.disabledAnimate=!0,void 0!==t.targetPositionFix&&(this.targetPositionFix=t.targetPositionFix),void 0!==t.targetRotationFix&&(this.targetRotationFix=t.targetRotationFix),void 0!==t.rotationToTarget&&(this.rotationToTarget=t.rotationToTarget),void 0!==t.distanceToTarget&&(this.distanceToTarget=t.distanceToTarget),void 0!==t.fixedOrientation&&(this.fixedOrientation=t.fixedOrientation),void 0!==t.oppositeCamera&&(this.oppositeCamera=t.oppositeCamera),void 0!==t.oppositeType&&(this.oppositeType=t.oppositeType),void 0!==t.orientationTarget&&(this.orientationTarget=t.orientationTarget),void 0!==t.orientationType&&(this.orientationType=t.orientationType),void 0!==t.vision&&(this.vision=t.vision),void 0!==t.autoRestoreOrientation&&(this.autoRestoreOrientation=t.autoRestoreOrientation),void 0!==t.gyroX&&(this.gyroX=t.gyroX),void 0!==t.gyroY&&(this.gyroY=t.gyroY),void 0!==t.gyroZ&&(this.gyroZ=t.gyroZ),void 0!==t.gyroAbsolute&&(this.gyroAbsolute=t.gyroAbsolute),void 0!==t.enableGyro&&(this.enableGyro=t.enableGyro),void 0!==t.onControlStart&&(this.onControlStart=t.onControlStart),void 0!==t.onControlRender&&(this.onControlRender=t.onControlRender),void 0!==t.onControlEnd&&(this.onControlEnd=t.onControlEnd),this.disabledAnimate=e,void 0!==t.disabledAnimate&&(this.disabledAnimate=t.disabledAnimate)}setCamera(t){return this._isActive&&this.ssp.viewport.cameraManager.removeCamera(this.cameraKey),this.nativeCamera=t,this.ssp.viewport.cameraManager.cameras[this.cameraKey]=t,this._isActive&&this.ssp.viewport.cameraManager.setCurrentCamera(t),this}restoreOrientation(){if(this.followTarget&&!this.fixedOrientation){if(this._positionTween&&(this._positionTween.stop(),this._positionTween=null),this.disabledAnimate)return this.position.copy(this._cameraPlaceholder.position),void this.lookAt(this.followPosition);this.ssp.animation(this.position,this._cameraPlaceholder.position,{duration:1e3},(t=>{this.lookAt(this.followPosition)}),(t=>this._positionTween=t)).finally((()=>{this._positionTween=null}))}}initEvents(){var t;const e=this.ssp.viewport.renderer.domElement,n=this.onRender.bind(this),r=t=>{var e,n;const r=!1===this.autoFollowRender;if(this.autoFollowRender=!1,null===(e=this._positionTween)||void 0===e||e.stop(),window.clearTimeout(this._restoreTimer),document.removeEventListener("mouseup",i),document.removeEventListener("touchend",i),document.addEventListener("mouseup",i,!0),document.addEventListener("touchend",i,!0),r)return;this.ssp.viewport.cameraManager.mainCamera.rotation.copy(this.rotation),null===(n=this.onControlStart)||void 0===n||n.call(this,this.nativeCamera,this.followTarget,t)},i=t=>{const e=()=>{var e;this.restoreOrientation(),this.autoFollowRender=!0,null===(e=this.onControlEnd)||void 0===e||e.call(this,this.nativeCamera,this.followTarget,t),document.removeEventListener("mouseup",i,!0),document.removeEventListener("touchend",i,!0)};"number"==typeof this.autoRestoreOrientation?(window.clearTimeout(this._restoreTimer),this._restoreTimer=setTimeout(e,this.autoRestoreOrientation)):this.autoRestoreOrientation&&e()};this._events.onRender=n,this._events.onMouseDown=r;const o=this.ssp.signals;o.beforeRender.add(n),o.mouseDown.add(r),null===(t=e.parentElement)||void 0===t||t.addEventListener("touchstart",r,!0)}clearEvents(){var t;const{onRender:e,onMouseDown:n}=this._events,r=this.ssp.signals,i=this.ssp.viewport.renderer.domElement;r.beforeRender.remove(e),r.mouseDown.remove(n),null===(t=i.parentElement)||void 0===t||t.removeEventListener("touchstart",n,!0)}}var $n;function tr(t,e){Vn.map={yaw:{left:[20,170],right:[-170,-20]},pitch:{up:[20,170],down:[-170,-20]}};const{yaw:n,pitch:r}=Vn.computeAzimuth(t,e),i=n.name,o=r.name;return i&&o?o?i?`${i}-${o}`:o:i:"straight"}function er(t,e){return e.reverse().map((e=>{t.removeObjectById(e.sid);const n=e.nodes.reverse().map((t=>({id:t.id,position:t.position,graphs:t.graphs})));return t.createTopology(Object.assign(Object.assign({},e.info),{nodes:n}))}))}function nr(t,e,n){if(!e||!n)return"straight";return tr(e.position.clone().sub(t.position),n.position.clone().sub(e.position))}function rr(t){const e=t.nodes,n=t.getLength();let r=0,i=0;return e.reduce(((t,o,s)=>{const a=e[s+1],u=e[s+2],h=a?a.position.clone().distanceTo(o.position):0,c=nr(o,a,u),l=r+h,f=l/n,p={progressArea:[i,f],distanceArea:[r,l],node:o,nextNode:a,distanceToStart:r,distanceToEnd:n-r,distanceToNext:h,frontDirection:c};return r=l,i=f,t.push(p),t}),[])}function ir(t,e){return 0===t?e[0]:100===t?e[e.length-1]:e.find((e=>{const[n,r]=e.progressArea;return t>=n&&t<r}))}function or(t,e){if(!e)return{distanceToStartNode:0,distanceToEndNode:0,distanceToStart:0,distanceToEnd:0};const[n,r]=e.progressArea,{distanceToNext:i,distanceToEnd:o,distanceToStart:s}=e,a=(t-n)/(r-n),u=i*a,h=i*(1-a);return{distanceToStartNode:u,distanceToEndNode:h,distanceToStart:u+s,distanceToEnd:o-h}}!function(t){t.PENDING="pending",t.STOP="stop",t.PLAYING="playing",t.PAUSE="pause",t.FINISHED="finished"}($n||($n={}));class sr{get model(){return this._model}set model(t){this._model=t}get speed(){return this._speed}set speed(t){this._speed=t}get pathProgress(){return this._pathProgress}set pathProgress(t){this._pathProgress=t}get totalProgress(){return this._pathProgress}set totalProgress(t){this._pathProgress=t}get currentPath(){return this.paths[this.currentPathIndex]}get currentPathIndex(){return this._currentPathIndex}get currentRotationVector(){return this._nextNode&&this._currentNode?this._nextNode.clone().sub(this._currentNode):new e}constructor(t,e){this.ssp=t,this.paths=e,this.onPlay=()=>{},this.onStatusChange=()=>{},this.loop=!1,this.autoNext=!0,this.playAfterStart=!1,this.flyToModelAfterStart=!0,this.backStartPointWhenStop=!0,this._model=new w,this._speed=1,this._pathProgress=0,this._totalProgress=0,this._currentPathIndex=0,this._currentNode=null,this._nextNode=null,this._playStatus=$n.PENDING}changeStatus(t){this._playStatus=t,this.onStatusChange(t)}start(){}restart(){this.stop(),this.start()}play(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;this.changeStatus($n.PLAYING),this.paths[t]}pause(){this.changeStatus($n.PAUSE)}stop(){this.changeStatus($n.STOP)}flip(){}over(){this.changeStatus($n.PENDING)}}export{kn as GyroListener,Hn as MapCamera,zn as NAVIGATE_ORIENTATION_TYPE,qn as NAVIGATE_VISION_TYPE,_n as NavigateCamera,sr as Navigator,$n as PLAY_STATUS,Fn as SoonSpaceCamera,Kn as Vector3ToEuler,Gn as eulerToVector3,tr as getDirection,nr as getDirectionByNodes,or as getDistanceInfoByProgress,Xn as getFixEuler,Un as getFixVector,ir as getNavigatorNodeInfoByProgress,rr as getNavigatorNodeInfosByTopology,Jn as initTouchToRotateCamera,Yn as normalizeEuler,er as reverseTopologies};
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@soonspacejs/plugin-navigation",
|
|
3
3
|
"pluginName": "NavigationPlugin",
|
|
4
|
-
"version": "2.6.
|
|
4
|
+
"version": "2.6.33",
|
|
5
5
|
"description": "Navigation plugin for SoonSpace.js",
|
|
6
6
|
"main": "dist/index.esm.js",
|
|
7
7
|
"module": "dist/index.esm.js",
|
|
@@ -13,8 +13,8 @@
|
|
|
13
13
|
],
|
|
14
14
|
"author": "zhuojian",
|
|
15
15
|
"license": "UNLICENSED",
|
|
16
|
-
"gitHead": "
|
|
16
|
+
"gitHead": "2db4ab083d914bbd93ad273f406a40b6ee3a88e8",
|
|
17
17
|
"peerDependencies": {
|
|
18
|
-
"soonspacejs": "2.6.
|
|
18
|
+
"soonspacejs": "2.6.33"
|
|
19
19
|
}
|
|
20
20
|
}
|