ss-component-new 1.2.136 → 1.2.138
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/{MTLLoader-W2bcC1q8.js → MTLLoader-BQPWZhwJ.js} +1 -1
- package/dist/{MTLLoader-MINcyZJJ.cjs → MTLLoader-rHpbWTI_.cjs} +1 -1
- package/dist/{OrbitControls-DInp3xM3.js → OrbitControls-Bvp2b_M2.js} +1 -1
- package/dist/{OrbitControls-zIDPLP2N.cjs → OrbitControls-D2yX87zU.cjs} +1 -1
- package/dist/{animationData-9Rwp8uyx.js → animationData-B3zZOzAE.js} +3 -3
- package/dist/{animationData-CPq6_wNF.cjs → animationData-CuUj6JDb.cjs} +1 -1
- package/dist/{array-jPdolPpm.js → array-B9gWNnej.js} +1 -1
- package/dist/{array-CYnA_0YM.cjs → array-DXu383Fa.cjs} +1 -1
- package/dist/{dataUtil-B4sGo38_.cjs → dataUtil-Brpg9CSN.cjs} +1 -1
- package/dist/{dataUtil-DQX9rTvE.js → dataUtil-DcGEuoWS.js} +1 -1
- package/dist/{iconfont-Bfcif4Wm.cjs → iconfont-Cd-HtwmG.cjs} +1 -1
- package/dist/{iconfont-BP_QEXyH.js → iconfont-DXGCEldy.js} +2 -2
- package/dist/{index-Ctb0iFbe.cjs → index-0EgOP_zr.cjs} +1 -1
- package/dist/{index-VvTawd2K.cjs → index-1iBK4SOi.cjs} +1 -1
- package/dist/{index-BXRe2SdU.cjs → index-7Z4hH5DN.cjs} +1 -1
- package/dist/{index-DoqCGsXd.js → index-B2rc9xa6.js} +11 -11
- package/dist/{index-4LcggUsv.cjs → index-B8PUJh-M.cjs} +1 -1
- package/dist/{index-D-8Ve1vd.js → index-B8pM9LoP.js} +19 -19
- package/dist/{index-BcdrVmA2.js → index-BE4Ox6_a.js} +2 -2
- package/dist/{index-3WEMy5_p.js → index-BGui0vrG.js} +2 -2
- package/dist/{index-DOZJO31u.cjs → index-BUacsR_l.cjs} +1 -1
- package/dist/{index-D4KRA-ju.js → index-BV8CK8MT.js} +5 -5
- package/dist/{index-C9D1SCzp.js → index-BYCdUxqq.js} +5 -5
- package/dist/{index-CcklBwqU.js → index-Bnmx0uns.js} +2 -2
- package/dist/index-BotH0jHM.cjs +1 -0
- package/dist/{index-CBsOpx33.cjs → index-BqzSSymu.cjs} +1 -1
- package/dist/{index-WjmB2-oN.cjs → index-Bw2f8X7m.cjs} +1 -1
- package/dist/{index-Dc7vS45u.js → index-BxtkLab-.js} +2 -2
- package/dist/{index-Bo9YSg2v.js → index-CBLiY4kf.js} +1 -1
- package/dist/{index-BN4MhImz.js → index-CGeabbQ5.js} +7 -7
- package/dist/{index-CSQJCfDf.js → index-CIoVLl8r.js} +1 -1
- package/dist/{index-BxZ-k8Ww.js → index-CR1PuEcf.js} +1 -1
- package/dist/{index-B21qNg4A.cjs → index-CSUfNuHC.cjs} +1 -1
- package/dist/{index-CGRb8BQx.cjs → index-C_U3JqBH.cjs} +1 -1
- package/dist/{index-CfrzoYYm.js → index-Ck1jmhY4.js} +10 -10
- package/dist/{index-CmVXy6DG.js → index-ClzevDbG.js} +2 -2
- package/dist/{index-Cw3gRBT3.cjs → index-D6ZtjYlX.cjs} +1 -1
- package/dist/{index-sqKsSUMY.js → index-DCkDkfcv.js} +2 -2
- package/dist/{index-a6bC3A9D.cjs → index-DHMUS6aq.cjs} +1 -1
- package/dist/{index-CcwTi2WJ.js → index-DMB7b-Hz.js} +1 -1
- package/dist/{index-BP7w8f-l.cjs → index-DNd_R3Wc.cjs} +1 -1
- package/dist/{index-CXrryrro.js → index-DToa387-.js} +1 -1
- package/dist/{index-DH1jRFsR.js → index-DUvCKtvN.js} +1 -1
- package/dist/{index-eaKFpHpQ.cjs → index-DW4LUPva.cjs} +1 -1
- package/dist/{index-DhufphmT.cjs → index-DWozj8SO.cjs} +1 -1
- package/dist/{index-DRVFz7q3.js → index-DXKmyyiU.js} +2 -2
- package/dist/{index-CcvCPGjx.js → index-DZshon9L.js} +3 -3
- package/dist/{index-h4NtMFJ6.cjs → index-Da-jfSLY.cjs} +1 -1
- package/dist/{index-CqDh73Kp.js → index-DcZT1tEr.js} +3 -3
- package/dist/{index-Duq040ej.js → index-DiaETo4w.js} +5 -5
- package/dist/{index-lQ5itYsF.cjs → index-Dr6BN_zC.cjs} +1 -1
- package/dist/{index-BXfKtvF-.js → index-Dr9Egq23.js} +1 -1
- package/dist/{index-KgwRgulq.cjs → index-Dv2ROWAm.cjs} +1 -1
- package/dist/{index-CJOQxUog.js → index-DzBBqrxe.js} +2 -2
- package/dist/{index-CV2JWX-7.js → index-EqgbW679.js} +1 -1
- package/dist/{index-CUo9Rzi3.cjs → index-F-zgk6uc.cjs} +1 -1
- package/dist/{index-C_paG8gS.cjs → index-GBr-eArU.cjs} +1 -1
- package/dist/{index-DI1_OcYK.js → index-K_jsxywJ.js} +4 -4
- package/dist/{index-C1eL6q7Z.cjs → index-aJ6qSTMl.cjs} +1 -1
- package/dist/{index-8wlioSUm.cjs → index-bzux6PE0.cjs} +1 -1
- package/dist/{index-jYsmQ_MD.js → index-d7FbcLhM.js} +5 -5
- package/dist/{index-PHVmpaM3.cjs → index-dEECSdIC.cjs} +1 -1
- package/dist/{index-dT9Iek_K.cjs → index-eEf1sDte.cjs} +1 -1
- package/dist/{index-DqFTTAE_.cjs → index-h7b-2-4Q.cjs} +1 -1
- package/dist/{index-D3rnfXSB.cjs → index-jvD6GMrr.cjs} +1 -1
- package/dist/{index-yKyLlN3j.cjs → index-kddiRLxz.cjs} +1 -1
- package/dist/{index-DwFpQNpA.cjs → index-mDbSepFg.cjs} +1 -1
- package/dist/{index-DRizRbU3.js → index-u963fvJq.js} +1 -1
- package/dist/{index.vue_vue_type_style_index_0_scoped_0b6f1a18_lang-VeGs2jMN.js → index.vue_vue_type_style_index_0_scoped_0b6f1a18_lang-BPcGKxya.js} +11 -11
- package/dist/{index.vue_vue_type_style_index_0_scoped_0b6f1a18_lang-DKaT8xTU.cjs → index.vue_vue_type_style_index_0_scoped_0b6f1a18_lang-VXj1bZpQ.cjs} +1 -1
- package/dist/{index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-pcyvQAbK.cjs → index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-CSGUG8yi.cjs} +1 -1
- package/dist/{index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-Ca5MAWqT.js → index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-JTfuXDvR.js} +1 -1
- package/dist/{index.vue_vue_type_style_index_0_scoped_92477073_lang-BJWbNR2V.cjs → index.vue_vue_type_style_index_0_scoped_92477073_lang-DSTQwClf.cjs} +1 -1
- package/dist/{index.vue_vue_type_style_index_0_scoped_92477073_lang-gNnmU49-.js → index.vue_vue_type_style_index_0_scoped_92477073_lang-datljWVr.js} +5 -5
- package/dist/{index.vue_vue_type_style_index_1_lang-BqG2FKzs.cjs → index.vue_vue_type_style_index_1_lang-C3Kw83zI.cjs} +1 -1
- package/dist/{index.vue_vue_type_style_index_1_lang-Cg1p_3ne.js → index.vue_vue_type_style_index_1_lang-DCNwSjkL.js} +1414 -1409
- package/dist/{index.vue_vue_type_style_index_1_lang-B8_elAaU.cjs → index.vue_vue_type_style_index_1_lang-_MRLV2pU.cjs} +5 -5
- package/dist/{index.vue_vue_type_style_index_1_lang-DbWCiN56.js → index.vue_vue_type_style_index_1_lang-rhYAIITv.js} +4 -4
- package/dist/{main-DL-OIsZx.js → main-CHpE2HyT.js} +4 -4
- package/dist/{main-rAd7GfHp.cjs → main-Wuj537Hx.cjs} +1 -1
- package/dist/ss-component.cjs +1 -1
- package/dist/ss-component.css +1 -1
- package/dist/ss-component.js +10 -10
- package/dist/ss-component2.cjs +1 -1
- package/dist/ss-component2.js +11 -11
- package/dist/{threeModel-BZ45sbaM.cjs → threeModel-B86bww-L.cjs} +1 -1
- package/dist/{threeModel-Bfr23IA3.js → threeModel-BJx5MH-m.js} +4 -4
- package/dist/{threePreview-n92dat47.js → threePreview-C8oiPD1l.js} +3 -3
- package/dist/{threePreview-DH6gyAm7.cjs → threePreview-DJLDHZlr.cjs} +1 -1
- package/dist/{threeSceneView-Bbv4UqdI.cjs → threeSceneView-8xsyz8QG.cjs} +1 -1
- package/dist/{threeSceneView-C3kjUyQz.js → threeSceneView-gxNGr3MP.js} +10 -10
- package/dist/{threeSceneViewForCPMPIP-CU85SdU2.js → threeSceneViewForCPMPIP-2m5nxgEF.js} +9 -9
- package/dist/{threeSceneViewForCPMPIP-Do8dA3xZ.cjs → threeSceneViewForCPMPIP-CLYeetY9.cjs} +1 -1
- package/dist/{threeTrackPathView-DundgA2K.cjs → threeTrackPathView-B8p4EFO1.cjs} +1 -1
- package/dist/{threeTrackPathView-DWqvizaQ.js → threeTrackPathView-DeQo7Wnu.js} +4 -4
- package/dist/{threeViewerHost-BRhsxthj.cjs → threeViewerHost-BDh0cvdZ.cjs} +2 -2
- package/dist/{threeViewerHost-BX-lA9Q_.js → threeViewerHost-DrxyqlfL.js} +3 -3
- package/dist/{urdfTree-Bd4DPzOI.cjs → urdfTree--UXeuTR1.cjs} +1 -1
- package/dist/{urdfTree-IrNrj52s.js → urdfTree-DlUtmYxX.js} +1 -1
- package/dist/{workpieceTreePanel-BCI9f-jE.cjs → workpieceTreePanel-82bZ2pJM.cjs} +1 -1
- package/dist/{workpieceTreePanel-BD3mDnhg.js → workpieceTreePanel-Tfx49DXu.js} +5 -5
- package/package.json +1 -1
- package/dist/index-O1JbRmM1.cjs +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";var Tdt=Object.defineProperty;var Edt=(r,t,e)=>t in r?Tdt(r,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):r[t]=e;var zr=(r,t,e)=>Edt(r,typeof t!="symbol"?t+"":t,e);const h5=require("./index.vue_vue_type_style_index_1_lang-B8_elAaU.cjs"),xi=require("./index-C8qRkCgn.cjs");function RJ(r,t){return h5.setToString(h5.overRest(r,t,h5.identity),r+"")}function Adt(r,t,e){if(!xi.isObject(e))return!1;var n=typeof t;return(n=="number"?xi.isArrayLike(e)&&xi.isIndex(t,e.length):n=="string"&&t in e)?xi.eq(e[t],r):!1}function Mdt(r){return RJ(function(t,e){var n=-1,i=e.length,a=i>1?e[i-1]:void 0,s=i>2?e[2]:void 0;for(a=r.length>3&&typeof a=="function"?(i--,a):void 0,s&&Adt(e[0],e[1],s)&&(a=i<3?void 0:a,i=1),t=Object(t);++n<i;){var o=e[n];o&&r(t,o,n,a)}return t})}var Cdt="[object Object]",kdt=Function.prototype,Rdt=Object.prototype,DJ=kdt.toString,Ddt=Rdt.hasOwnProperty,Idt=DJ.call(Object);function IJ(r){if(!xi.isObjectLike(r)||xi.baseGetTag(r)!=Cdt)return!1;var t=xi.getPrototype(r);if(t===null)return!0;var e=Ddt.call(t,"constructor")&&t.constructor;return typeof e=="function"&&e instanceof e&&DJ.call(e)==Idt}function Ldt(r){return function(t,e,n){for(var i=-1,a=Object(t),s=n(t),o=s.length;o--;){var l=s[++i];if(e(a[l],l,a)===!1)break}return t}}var LJ=Ldt();function RL(r,t,e){(e!==void 0&&!xi.eq(r[t],e)||e===void 0&&!(t in r))&&xi.baseAssignValue(r,t,e)}function PJ(r){return xi.isObjectLike(r)&&xi.isArrayLike(r)}function DL(r,t){if(!(t==="constructor"&&typeof r[t]=="function")&&t!="__proto__")return r[t]}function Pdt(r){return xi.copyObject(r,xi.keysIn(r))}function Ndt(r,t,e,n,i,a,s){var o=DL(r,e),l=DL(t,e),u=s.get(l);if(u){RL(r,e,u);return}var c=a?a(o,l,e+"",r,t,s):void 0,h=c===void 0;if(h){var f=xi.isArray(l),d=!f&&xi.isBuffer(l),p=!f&&!d&&xi.isTypedArray(l);c=l,f||d||p?xi.isArray(o)?c=o:PJ(o)?c=xi.copyArray(o):d?(h=!1,c=xi.cloneBuffer(l,!0)):p?(h=!1,c=xi.cloneTypedArray(l,!0)):c=[]:IJ(l)||xi.isArguments(l)?(c=o,xi.isArguments(o)?c=Pdt(o):(!xi.isObject(o)||xi.isFunction$1(o))&&(c=xi.initCloneObject(l))):h=!1}h&&(s.set(l,c),i(c,l,n,a,s),s.delete(l)),RL(r,e,c)}function NJ(r,t,e,n,i){r!==t&&LJ(t,function(a,s){if(i||(i=new xi.Stack),xi.isObject(a))Ndt(r,t,s,e,NJ,n,i);else{var o=n?n(DL(r,s),a,s+"",r,t,i):void 0;o===void 0&&(o=a),RL(r,s,o)}},xi.keysIn)}var fp=Mdt(function(r,t,e){NJ(r,t,e)}),Qo=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function u1(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}function Odt(r){if(Object.prototype.hasOwnProperty.call(r,"__esModule"))return r;var t=r.default;if(typeof t=="function"){var e=function n(){return this instanceof n?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};e.prototype=t.prototype}else e={};return Object.defineProperty(e,"__esModule",{value:!0}),Object.keys(r).forEach(function(n){var i=Object.getOwnPropertyDescriptor(r,n);Object.defineProperty(e,n,i.get?i:{enumerable:!0,get:function(){return r[n]}})}),e}var f5={exports:{}},Fdt=f5.exports,Hz;function Bdt(){return Hz||(Hz=1,function(r,t){(function(e,n){r.exports=n()})(Fdt,function(){var e=1e3,n=6e4,i=36e5,a="millisecond",s="second",o="minute",l="hour",u="day",c="week",h="month",f="quarter",d="year",p="date",m="Invalid Date",g=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,y=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,v={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(R){var A=["th","st","nd","rd"],M=R%100;return"["+R+(A[(M-20)%10]||A[M]||A[0])+"]"}},b=function(R,A,M){var D=String(R);return!D||D.length>=A?R:""+Array(A+1-D.length).join(M)+R},w={s:b,z:function(R){var A=-R.utcOffset(),M=Math.abs(A),D=Math.floor(M/60),k=M%60;return(A<=0?"+":"-")+b(D,2,"0")+":"+b(k,2,"0")},m:function R(A,M){if(A.date()<M.date())return-R(M,A);var D=12*(M.year()-A.year())+(M.month()-A.month()),k=A.clone().add(D,h),N=M-k<0,z=A.clone().add(D+(N?-1:1),h);return+(-(D+(M-k)/(N?k-z:z-k))||0)},a:function(R){return R<0?Math.ceil(R)||0:Math.floor(R)},p:function(R){return{M:h,y:d,w:c,d:u,D:p,h:l,m:o,s,ms:a,Q:f}[R]||String(R||"").toLowerCase().replace(/s$/,"")},u:function(R){return R===void 0}},_="en",x={};x[_]=v;var S="$isDayjsObject",T=function(R){return R instanceof B||!(!R||!R[S])},E=function R(A,M,D){var k;if(!A)return _;if(typeof A=="string"){var N=A.toLowerCase();x[N]&&(k=N),M&&(x[N]=M,k=N);var z=A.split("-");if(!k&&z.length>1)return R(z[0])}else{var O=A.name;x[O]=A,k=O}return!D&&k&&(_=k),k||!D&&_},I=function(R,A){if(T(R))return R.clone();var M=typeof A=="object"?A:{};return M.date=R,M.args=arguments,new B(M)},L=w;L.l=E,L.i=T,L.w=function(R,A){return I(R,{locale:A.$L,utc:A.$u,x:A.$x,$offset:A.$offset})};var B=function(){function R(M){this.$L=E(M.locale,null,!0),this.parse(M),this.$x=this.$x||M.x||{},this[S]=!0}var A=R.prototype;return A.parse=function(M){this.$d=function(D){var k=D.date,N=D.utc;if(k===null)return new Date(NaN);if(L.u(k))return new Date;if(k instanceof Date)return new Date(k);if(typeof k=="string"&&!/Z$/i.test(k)){var z=k.match(g);if(z){var O=z[2]-1||0,H=(z[7]||"0").substring(0,3);return N?new Date(Date.UTC(z[1],O,z[3]||1,z[4]||0,z[5]||0,z[6]||0,H)):new Date(z[1],O,z[3]||1,z[4]||0,z[5]||0,z[6]||0,H)}}return new Date(k)}(M),this.init()},A.init=function(){var M=this.$d;this.$y=M.getFullYear(),this.$M=M.getMonth(),this.$D=M.getDate(),this.$W=M.getDay(),this.$H=M.getHours(),this.$m=M.getMinutes(),this.$s=M.getSeconds(),this.$ms=M.getMilliseconds()},A.$utils=function(){return L},A.isValid=function(){return this.$d.toString()!==m},A.isSame=function(M,D){var k=I(M);return this.startOf(D)<=k&&k<=this.endOf(D)},A.isAfter=function(M,D){return I(M)<this.startOf(D)},A.isBefore=function(M,D){return this.endOf(D)<I(M)},A.$g=function(M,D,k){return L.u(M)?this[D]:this.set(k,M)},A.unix=function(){return Math.floor(this.valueOf()/1e3)},A.valueOf=function(){return this.$d.getTime()},A.startOf=function(M,D){var k=this,N=!!L.u(D)||D,z=L.p(M),O=function(gt,rt){var K=L.w(k.$u?Date.UTC(k.$y,rt,gt):new Date(k.$y,rt,gt),k);return N?K:K.endOf(u)},H=function(gt,rt){return L.w(k.toDate()[gt].apply(k.toDate("s"),(N?[0,0,0,0]:[23,59,59,999]).slice(rt)),k)},V=this.$W,G=this.$M,Z=this.$D,Q="set"+(this.$u?"UTC":"");switch(z){case d:return N?O(1,0):O(31,11);case h:return N?O(1,G):O(0,G+1);case c:var yt=this.$locale().weekStart||0,ot=(V<yt?V+7:V)-yt;return O(N?Z-ot:Z+(6-ot),G);case u:case p:return H(Q+"Hours",0);case l:return H(Q+"Minutes",1);case o:return H(Q+"Seconds",2);case s:return H(Q+"Milliseconds",3);default:return this.clone()}},A.endOf=function(M){return this.startOf(M,!1)},A.$set=function(M,D){var k,N=L.p(M),z="set"+(this.$u?"UTC":""),O=(k={},k[u]=z+"Date",k[p]=z+"Date",k[h]=z+"Month",k[d]=z+"FullYear",k[l]=z+"Hours",k[o]=z+"Minutes",k[s]=z+"Seconds",k[a]=z+"Milliseconds",k)[N],H=N===u?this.$D+(D-this.$W):D;if(N===h||N===d){var V=this.clone().set(p,1);V.$d[O](H),V.init(),this.$d=V.set(p,Math.min(this.$D,V.daysInMonth())).$d}else O&&this.$d[O](H);return this.init(),this},A.set=function(M,D){return this.clone().$set(M,D)},A.get=function(M){return this[L.p(M)]()},A.add=function(M,D){var k,N=this;M=Number(M);var z=L.p(D),O=function(G){var Z=I(N);return L.w(Z.date(Z.date()+Math.round(G*M)),N)};if(z===h)return this.set(h,this.$M+M);if(z===d)return this.set(d,this.$y+M);if(z===u)return O(1);if(z===c)return O(7);var H=(k={},k[o]=n,k[l]=i,k[s]=e,k)[z]||1,V=this.$d.getTime()+M*H;return L.w(V,this)},A.subtract=function(M,D){return this.add(-1*M,D)},A.format=function(M){var D=this,k=this.$locale();if(!this.isValid())return k.invalidDate||m;var N=M||"YYYY-MM-DDTHH:mm:ssZ",z=L.z(this),O=this.$H,H=this.$m,V=this.$M,G=k.weekdays,Z=k.months,Q=k.meridiem,yt=function(rt,K,nt,ut){return rt&&(rt[K]||rt(D,N))||nt[K].slice(0,ut)},ot=function(rt){return L.s(O%12||12,rt,"0")},gt=Q||function(rt,K,nt){var ut=rt<12?"AM":"PM";return nt?ut.toLowerCase():ut};return N.replace(y,function(rt,K){return K||function(nt){switch(nt){case"YY":return String(D.$y).slice(-2);case"YYYY":return L.s(D.$y,4,"0");case"M":return V+1;case"MM":return L.s(V+1,2,"0");case"MMM":return yt(k.monthsShort,V,Z,3);case"MMMM":return yt(Z,V);case"D":return D.$D;case"DD":return L.s(D.$D,2,"0");case"d":return String(D.$W);case"dd":return yt(k.weekdaysMin,D.$W,G,2);case"ddd":return yt(k.weekdaysShort,D.$W,G,3);case"dddd":return G[D.$W];case"H":return String(O);case"HH":return L.s(O,2,"0");case"h":return ot(1);case"hh":return ot(2);case"a":return gt(O,H,!0);case"A":return gt(O,H,!1);case"m":return String(H);case"mm":return L.s(H,2,"0");case"s":return String(D.$s);case"ss":return L.s(D.$s,2,"0");case"SSS":return L.s(D.$ms,3,"0");case"Z":return z}return null}(rt)||z.replace(":","")})},A.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},A.diff=function(M,D,k){var N,z=this,O=L.p(D),H=I(M),V=(H.utcOffset()-this.utcOffset())*n,G=this-H,Z=function(){return L.m(z,H)};switch(O){case d:N=Z()/12;break;case h:N=Z();break;case f:N=Z()/3;break;case c:N=(G-V)/6048e5;break;case u:N=(G-V)/864e5;break;case l:N=G/i;break;case o:N=G/n;break;case s:N=G/e;break;default:N=G}return k?N:L.a(N)},A.daysInMonth=function(){return this.endOf(h).$D},A.$locale=function(){return x[this.$L]},A.locale=function(M,D){if(!M)return this.$L;var k=this.clone(),N=E(M,D,!0);return N&&(k.$L=N),k},A.clone=function(){return L.w(this.$d,this)},A.toDate=function(){return new Date(this.valueOf())},A.toJSON=function(){return this.isValid()?this.toISOString():null},A.toISOString=function(){return this.$d.toISOString()},A.toString=function(){return this.$d.toUTCString()},R}(),C=B.prototype;return I.prototype=C,[["$ms",a],["$s",s],["$m",o],["$H",l],["$W",u],["$M",h],["$y",d],["$D",p]].forEach(function(R){C[R[1]]=function(A){return this.$g(A,R[0],R[1])}}),I.extend=function(R,A){return R.$i||(R(A,B,I),R.$i=!0),I},I.locale=E,I.isDayjs=T,I.unix=function(R){return I(1e3*R)},I.en=x[_],I.Ls=x,I.p={},I})}(f5)),f5.exports}var zdt=Bdt();const Udt=u1(zdt),Vdt=xi.useLoginState(xi.pinia),{loginUserInfo:a8}=xi.storeToRefs(Vdt),Hdt=async r=>{var i,a,s,o,l,u,c,h,f,d,p,m,g,y,v,b,w,_;let t=[];(i=r==null?void 0:r.menuSelect)==null||i.forEach(x=>{});let e="";const n=await h5.menuToParent(r==null?void 0:r.menuSelect);if(n==null||n.forEach(x=>{var S,T;(x==null?void 0:x.name)===(((T=(S=r==null?void 0:r.groupSelect)==null?void 0:S[0])==null?void 0:T.replaceAll("'",""))??"")&&(e=x==null?void 0:x.id)}),e!==""){const x=(o=(s=(a=n==null?void 0:n.find(E=>(E==null?void 0:E.id)===e))==null?void 0:a.compData)==null?void 0:s.find(E=>(E==null?void 0:E.key)==="header"))==null?void 0:o.contents;let S=0;x.every(E=>Array.isArray(E))?S=(l=x==null?void 0:x[0])==null?void 0:l.findIndex(E=>{var I,L,B;return(E==null?void 0:E.label)===((B=(L=(I=r==null?void 0:r.groupSelect)==null?void 0:I[1])==null?void 0:L.replaceAll("[",""))==null?void 0:B.replaceAll("]",""))}):S=x==null?void 0:x.findIndex(E=>{var I,L,B;return(E==null?void 0:E.label)===((B=(L=(I=r==null?void 0:r.groupSelect)==null?void 0:I[1])==null?void 0:L.replaceAll("[",""))==null?void 0:B.replaceAll("]",""))});let T=(f=(h=(c=(u=n==null?void 0:n.find(E=>(E==null?void 0:E.id)===e))==null?void 0:u.compData)==null?void 0:c.find(E=>(E==null?void 0:E.key)==="tableContents"))==null?void 0:h.contents)==null?void 0:f.map(E=>(E=E==null?void 0:E.filter(I=>!(I!=null&&I.id)),E));if((r==null?void 0:r.filter)!==""){let E={};E[(p=(d=r==null?void 0:r.filter)==null?void 0:d.split("#"))==null?void 0:p[0]]=(g=(m=r==null?void 0:r.filter)==null?void 0:m.split("#"))==null?void 0:g[1];let I=(v=(y=r==null?void 0:r.filter)==null?void 0:y.split("#"))==null?void 0:v[1];I==="@loginUser"&&(I=((b=a8.value)==null?void 0:b.姓名)||((w=a8.value)==null?void 0:w.account)||((_=a8.value)==null?void 0:_.账号));let L=x==null?void 0:x.findIndex(B=>{var C,R;return(B==null?void 0:B.prop)===((R=(C=Object.keys(E))==null?void 0:C[0])==null?void 0:R.replaceAll("'",""))});T=T==null?void 0:T.filter(B=>(B==null?void 0:B[L])===I)}T==null||T.forEach(E=>{t.push({label:E==null?void 0:E[S],value:E==null?void 0:E[S]})})}return t};/**!
|
|
1
|
+
"use strict";var Tdt=Object.defineProperty;var Edt=(r,t,e)=>t in r?Tdt(r,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):r[t]=e;var zr=(r,t,e)=>Edt(r,typeof t!="symbol"?t+"":t,e);const h5=require("./index.vue_vue_type_style_index_1_lang-_MRLV2pU.cjs"),xi=require("./index-C8qRkCgn.cjs");function RJ(r,t){return h5.setToString(h5.overRest(r,t,h5.identity),r+"")}function Adt(r,t,e){if(!xi.isObject(e))return!1;var n=typeof t;return(n=="number"?xi.isArrayLike(e)&&xi.isIndex(t,e.length):n=="string"&&t in e)?xi.eq(e[t],r):!1}function Mdt(r){return RJ(function(t,e){var n=-1,i=e.length,a=i>1?e[i-1]:void 0,s=i>2?e[2]:void 0;for(a=r.length>3&&typeof a=="function"?(i--,a):void 0,s&&Adt(e[0],e[1],s)&&(a=i<3?void 0:a,i=1),t=Object(t);++n<i;){var o=e[n];o&&r(t,o,n,a)}return t})}var Cdt="[object Object]",kdt=Function.prototype,Rdt=Object.prototype,DJ=kdt.toString,Ddt=Rdt.hasOwnProperty,Idt=DJ.call(Object);function IJ(r){if(!xi.isObjectLike(r)||xi.baseGetTag(r)!=Cdt)return!1;var t=xi.getPrototype(r);if(t===null)return!0;var e=Ddt.call(t,"constructor")&&t.constructor;return typeof e=="function"&&e instanceof e&&DJ.call(e)==Idt}function Ldt(r){return function(t,e,n){for(var i=-1,a=Object(t),s=n(t),o=s.length;o--;){var l=s[++i];if(e(a[l],l,a)===!1)break}return t}}var LJ=Ldt();function RL(r,t,e){(e!==void 0&&!xi.eq(r[t],e)||e===void 0&&!(t in r))&&xi.baseAssignValue(r,t,e)}function PJ(r){return xi.isObjectLike(r)&&xi.isArrayLike(r)}function DL(r,t){if(!(t==="constructor"&&typeof r[t]=="function")&&t!="__proto__")return r[t]}function Pdt(r){return xi.copyObject(r,xi.keysIn(r))}function Ndt(r,t,e,n,i,a,s){var o=DL(r,e),l=DL(t,e),u=s.get(l);if(u){RL(r,e,u);return}var c=a?a(o,l,e+"",r,t,s):void 0,h=c===void 0;if(h){var f=xi.isArray(l),d=!f&&xi.isBuffer(l),p=!f&&!d&&xi.isTypedArray(l);c=l,f||d||p?xi.isArray(o)?c=o:PJ(o)?c=xi.copyArray(o):d?(h=!1,c=xi.cloneBuffer(l,!0)):p?(h=!1,c=xi.cloneTypedArray(l,!0)):c=[]:IJ(l)||xi.isArguments(l)?(c=o,xi.isArguments(o)?c=Pdt(o):(!xi.isObject(o)||xi.isFunction$1(o))&&(c=xi.initCloneObject(l))):h=!1}h&&(s.set(l,c),i(c,l,n,a,s),s.delete(l)),RL(r,e,c)}function NJ(r,t,e,n,i){r!==t&&LJ(t,function(a,s){if(i||(i=new xi.Stack),xi.isObject(a))Ndt(r,t,s,e,NJ,n,i);else{var o=n?n(DL(r,s),a,s+"",r,t,i):void 0;o===void 0&&(o=a),RL(r,s,o)}},xi.keysIn)}var fp=Mdt(function(r,t,e){NJ(r,t,e)}),Qo=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function u1(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}function Odt(r){if(Object.prototype.hasOwnProperty.call(r,"__esModule"))return r;var t=r.default;if(typeof t=="function"){var e=function n(){return this instanceof n?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};e.prototype=t.prototype}else e={};return Object.defineProperty(e,"__esModule",{value:!0}),Object.keys(r).forEach(function(n){var i=Object.getOwnPropertyDescriptor(r,n);Object.defineProperty(e,n,i.get?i:{enumerable:!0,get:function(){return r[n]}})}),e}var f5={exports:{}},Fdt=f5.exports,Hz;function Bdt(){return Hz||(Hz=1,function(r,t){(function(e,n){r.exports=n()})(Fdt,function(){var e=1e3,n=6e4,i=36e5,a="millisecond",s="second",o="minute",l="hour",u="day",c="week",h="month",f="quarter",d="year",p="date",m="Invalid Date",g=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,y=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,v={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(R){var A=["th","st","nd","rd"],M=R%100;return"["+R+(A[(M-20)%10]||A[M]||A[0])+"]"}},b=function(R,A,M){var D=String(R);return!D||D.length>=A?R:""+Array(A+1-D.length).join(M)+R},w={s:b,z:function(R){var A=-R.utcOffset(),M=Math.abs(A),D=Math.floor(M/60),k=M%60;return(A<=0?"+":"-")+b(D,2,"0")+":"+b(k,2,"0")},m:function R(A,M){if(A.date()<M.date())return-R(M,A);var D=12*(M.year()-A.year())+(M.month()-A.month()),k=A.clone().add(D,h),N=M-k<0,z=A.clone().add(D+(N?-1:1),h);return+(-(D+(M-k)/(N?k-z:z-k))||0)},a:function(R){return R<0?Math.ceil(R)||0:Math.floor(R)},p:function(R){return{M:h,y:d,w:c,d:u,D:p,h:l,m:o,s,ms:a,Q:f}[R]||String(R||"").toLowerCase().replace(/s$/,"")},u:function(R){return R===void 0}},_="en",x={};x[_]=v;var S="$isDayjsObject",T=function(R){return R instanceof B||!(!R||!R[S])},E=function R(A,M,D){var k;if(!A)return _;if(typeof A=="string"){var N=A.toLowerCase();x[N]&&(k=N),M&&(x[N]=M,k=N);var z=A.split("-");if(!k&&z.length>1)return R(z[0])}else{var O=A.name;x[O]=A,k=O}return!D&&k&&(_=k),k||!D&&_},I=function(R,A){if(T(R))return R.clone();var M=typeof A=="object"?A:{};return M.date=R,M.args=arguments,new B(M)},L=w;L.l=E,L.i=T,L.w=function(R,A){return I(R,{locale:A.$L,utc:A.$u,x:A.$x,$offset:A.$offset})};var B=function(){function R(M){this.$L=E(M.locale,null,!0),this.parse(M),this.$x=this.$x||M.x||{},this[S]=!0}var A=R.prototype;return A.parse=function(M){this.$d=function(D){var k=D.date,N=D.utc;if(k===null)return new Date(NaN);if(L.u(k))return new Date;if(k instanceof Date)return new Date(k);if(typeof k=="string"&&!/Z$/i.test(k)){var z=k.match(g);if(z){var O=z[2]-1||0,H=(z[7]||"0").substring(0,3);return N?new Date(Date.UTC(z[1],O,z[3]||1,z[4]||0,z[5]||0,z[6]||0,H)):new Date(z[1],O,z[3]||1,z[4]||0,z[5]||0,z[6]||0,H)}}return new Date(k)}(M),this.init()},A.init=function(){var M=this.$d;this.$y=M.getFullYear(),this.$M=M.getMonth(),this.$D=M.getDate(),this.$W=M.getDay(),this.$H=M.getHours(),this.$m=M.getMinutes(),this.$s=M.getSeconds(),this.$ms=M.getMilliseconds()},A.$utils=function(){return L},A.isValid=function(){return this.$d.toString()!==m},A.isSame=function(M,D){var k=I(M);return this.startOf(D)<=k&&k<=this.endOf(D)},A.isAfter=function(M,D){return I(M)<this.startOf(D)},A.isBefore=function(M,D){return this.endOf(D)<I(M)},A.$g=function(M,D,k){return L.u(M)?this[D]:this.set(k,M)},A.unix=function(){return Math.floor(this.valueOf()/1e3)},A.valueOf=function(){return this.$d.getTime()},A.startOf=function(M,D){var k=this,N=!!L.u(D)||D,z=L.p(M),O=function(gt,rt){var K=L.w(k.$u?Date.UTC(k.$y,rt,gt):new Date(k.$y,rt,gt),k);return N?K:K.endOf(u)},H=function(gt,rt){return L.w(k.toDate()[gt].apply(k.toDate("s"),(N?[0,0,0,0]:[23,59,59,999]).slice(rt)),k)},V=this.$W,G=this.$M,Z=this.$D,Q="set"+(this.$u?"UTC":"");switch(z){case d:return N?O(1,0):O(31,11);case h:return N?O(1,G):O(0,G+1);case c:var yt=this.$locale().weekStart||0,ot=(V<yt?V+7:V)-yt;return O(N?Z-ot:Z+(6-ot),G);case u:case p:return H(Q+"Hours",0);case l:return H(Q+"Minutes",1);case o:return H(Q+"Seconds",2);case s:return H(Q+"Milliseconds",3);default:return this.clone()}},A.endOf=function(M){return this.startOf(M,!1)},A.$set=function(M,D){var k,N=L.p(M),z="set"+(this.$u?"UTC":""),O=(k={},k[u]=z+"Date",k[p]=z+"Date",k[h]=z+"Month",k[d]=z+"FullYear",k[l]=z+"Hours",k[o]=z+"Minutes",k[s]=z+"Seconds",k[a]=z+"Milliseconds",k)[N],H=N===u?this.$D+(D-this.$W):D;if(N===h||N===d){var V=this.clone().set(p,1);V.$d[O](H),V.init(),this.$d=V.set(p,Math.min(this.$D,V.daysInMonth())).$d}else O&&this.$d[O](H);return this.init(),this},A.set=function(M,D){return this.clone().$set(M,D)},A.get=function(M){return this[L.p(M)]()},A.add=function(M,D){var k,N=this;M=Number(M);var z=L.p(D),O=function(G){var Z=I(N);return L.w(Z.date(Z.date()+Math.round(G*M)),N)};if(z===h)return this.set(h,this.$M+M);if(z===d)return this.set(d,this.$y+M);if(z===u)return O(1);if(z===c)return O(7);var H=(k={},k[o]=n,k[l]=i,k[s]=e,k)[z]||1,V=this.$d.getTime()+M*H;return L.w(V,this)},A.subtract=function(M,D){return this.add(-1*M,D)},A.format=function(M){var D=this,k=this.$locale();if(!this.isValid())return k.invalidDate||m;var N=M||"YYYY-MM-DDTHH:mm:ssZ",z=L.z(this),O=this.$H,H=this.$m,V=this.$M,G=k.weekdays,Z=k.months,Q=k.meridiem,yt=function(rt,K,nt,ut){return rt&&(rt[K]||rt(D,N))||nt[K].slice(0,ut)},ot=function(rt){return L.s(O%12||12,rt,"0")},gt=Q||function(rt,K,nt){var ut=rt<12?"AM":"PM";return nt?ut.toLowerCase():ut};return N.replace(y,function(rt,K){return K||function(nt){switch(nt){case"YY":return String(D.$y).slice(-2);case"YYYY":return L.s(D.$y,4,"0");case"M":return V+1;case"MM":return L.s(V+1,2,"0");case"MMM":return yt(k.monthsShort,V,Z,3);case"MMMM":return yt(Z,V);case"D":return D.$D;case"DD":return L.s(D.$D,2,"0");case"d":return String(D.$W);case"dd":return yt(k.weekdaysMin,D.$W,G,2);case"ddd":return yt(k.weekdaysShort,D.$W,G,3);case"dddd":return G[D.$W];case"H":return String(O);case"HH":return L.s(O,2,"0");case"h":return ot(1);case"hh":return ot(2);case"a":return gt(O,H,!0);case"A":return gt(O,H,!1);case"m":return String(H);case"mm":return L.s(H,2,"0");case"s":return String(D.$s);case"ss":return L.s(D.$s,2,"0");case"SSS":return L.s(D.$ms,3,"0");case"Z":return z}return null}(rt)||z.replace(":","")})},A.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},A.diff=function(M,D,k){var N,z=this,O=L.p(D),H=I(M),V=(H.utcOffset()-this.utcOffset())*n,G=this-H,Z=function(){return L.m(z,H)};switch(O){case d:N=Z()/12;break;case h:N=Z();break;case f:N=Z()/3;break;case c:N=(G-V)/6048e5;break;case u:N=(G-V)/864e5;break;case l:N=G/i;break;case o:N=G/n;break;case s:N=G/e;break;default:N=G}return k?N:L.a(N)},A.daysInMonth=function(){return this.endOf(h).$D},A.$locale=function(){return x[this.$L]},A.locale=function(M,D){if(!M)return this.$L;var k=this.clone(),N=E(M,D,!0);return N&&(k.$L=N),k},A.clone=function(){return L.w(this.$d,this)},A.toDate=function(){return new Date(this.valueOf())},A.toJSON=function(){return this.isValid()?this.toISOString():null},A.toISOString=function(){return this.$d.toISOString()},A.toString=function(){return this.$d.toUTCString()},R}(),C=B.prototype;return I.prototype=C,[["$ms",a],["$s",s],["$m",o],["$H",l],["$W",u],["$M",h],["$y",d],["$D",p]].forEach(function(R){C[R[1]]=function(A){return this.$g(A,R[0],R[1])}}),I.extend=function(R,A){return R.$i||(R(A,B,I),R.$i=!0),I},I.locale=E,I.isDayjs=T,I.unix=function(R){return I(1e3*R)},I.en=x[_],I.Ls=x,I.p={},I})}(f5)),f5.exports}var zdt=Bdt();const Udt=u1(zdt),Vdt=xi.useLoginState(xi.pinia),{loginUserInfo:a8}=xi.storeToRefs(Vdt),Hdt=async r=>{var i,a,s,o,l,u,c,h,f,d,p,m,g,y,v,b,w,_;let t=[];(i=r==null?void 0:r.menuSelect)==null||i.forEach(x=>{});let e="";const n=await h5.menuToParent(r==null?void 0:r.menuSelect);if(n==null||n.forEach(x=>{var S,T;(x==null?void 0:x.name)===(((T=(S=r==null?void 0:r.groupSelect)==null?void 0:S[0])==null?void 0:T.replaceAll("'",""))??"")&&(e=x==null?void 0:x.id)}),e!==""){const x=(o=(s=(a=n==null?void 0:n.find(E=>(E==null?void 0:E.id)===e))==null?void 0:a.compData)==null?void 0:s.find(E=>(E==null?void 0:E.key)==="header"))==null?void 0:o.contents;let S=0;x.every(E=>Array.isArray(E))?S=(l=x==null?void 0:x[0])==null?void 0:l.findIndex(E=>{var I,L,B;return(E==null?void 0:E.label)===((B=(L=(I=r==null?void 0:r.groupSelect)==null?void 0:I[1])==null?void 0:L.replaceAll("[",""))==null?void 0:B.replaceAll("]",""))}):S=x==null?void 0:x.findIndex(E=>{var I,L,B;return(E==null?void 0:E.label)===((B=(L=(I=r==null?void 0:r.groupSelect)==null?void 0:I[1])==null?void 0:L.replaceAll("[",""))==null?void 0:B.replaceAll("]",""))});let T=(f=(h=(c=(u=n==null?void 0:n.find(E=>(E==null?void 0:E.id)===e))==null?void 0:u.compData)==null?void 0:c.find(E=>(E==null?void 0:E.key)==="tableContents"))==null?void 0:h.contents)==null?void 0:f.map(E=>(E=E==null?void 0:E.filter(I=>!(I!=null&&I.id)),E));if((r==null?void 0:r.filter)!==""){let E={};E[(p=(d=r==null?void 0:r.filter)==null?void 0:d.split("#"))==null?void 0:p[0]]=(g=(m=r==null?void 0:r.filter)==null?void 0:m.split("#"))==null?void 0:g[1];let I=(v=(y=r==null?void 0:r.filter)==null?void 0:y.split("#"))==null?void 0:v[1];I==="@loginUser"&&(I=((b=a8.value)==null?void 0:b.姓名)||((w=a8.value)==null?void 0:w.account)||((_=a8.value)==null?void 0:_.账号));let L=x==null?void 0:x.findIndex(B=>{var C,R;return(B==null?void 0:B.prop)===((R=(C=Object.keys(E))==null?void 0:C[0])==null?void 0:R.replaceAll("'",""))});T=T==null?void 0:T.filter(B=>(B==null?void 0:B[L])===I)}T==null||T.forEach(E=>{t.push({label:E==null?void 0:E[S],value:E==null?void 0:E[S]})})}return t};/**!
|
|
2
2
|
* Sortable 1.15.6
|
|
3
3
|
* @author RubaXa <trash@rubaxa.org>
|
|
4
4
|
* @author owenm <owen23355@gmail.com>
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
var odt = Object.defineProperty;
|
|
2
2
|
var ldt = (r, t, e) => t in r ? odt(r, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : r[t] = e;
|
|
3
3
|
var zr = (r, t, e) => ldt(r, typeof t != "symbol" ? t + "" : t, e);
|
|
4
|
-
import { at as udt, au as cdt, o as hdt, av as fdt } from "./index.vue_vue_type_style_index_1_lang-
|
|
4
|
+
import { at as udt, au as cdt, o as hdt, av as fdt } from "./index.vue_vue_type_style_index_1_lang-DCNwSjkL.js";
|
|
5
5
|
import { k as E7, q as MJ, bQ as ddt, bR as CJ, bS as kJ, bT as pdt, bU as vdt, bV as mdt, w as gdt, bW as RJ, bX as ydt, bY as bdt, i as Oz, bZ as wdt, b_ as _dt, b$ as xdt, c0 as Fz, c1 as Sdt, c2 as Tdt, S as Edt, s as Adt, u as Mdt, p as Cdt, au as A7, c as Gb } from "./index-BUYYl2Pc.js";
|
|
6
6
|
function kdt(r, t) {
|
|
7
7
|
return udt(cdt(r, t, hdt), r + "");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const s=require("vue"),ce=require("./index-BpPyaNFa.cjs"),w=require("./index-C8qRkCgn.cjs");require("./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-
|
|
1
|
+
"use strict";const s=require("vue"),ce=require("./index-BpPyaNFa.cjs"),w=require("./index-C8qRkCgn.cjs");require("./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-CSGUG8yi.cjs");const B=require("./index.vue_vue_type_style_index_1_lang-_MRLV2pU.cjs"),ae=require("./index-DWozj8SO.cjs"),ie=require("vue-router"),A=require("./index-9hspBVrQ.cjs"),pe=require("./index-BotH0jHM.cjs"),P=s.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./index-F-zgk6uc.cjs")).then(v=>v.index));P.install=v=>{v.component("ssMenu",P)};const z={__name:"index",props:{name:String},setup(v){const b=v,S=s.computed(()=>w.ElIcons[b.name]);return s.onMounted(()=>{}),(x,a)=>{const T=s.resolveComponent("el-icon");return s.openBlock(),s.createBlock(T,null,{default:s.withCtx(()=>[(s.openBlock(),s.createBlock(s.resolveDynamicComponent(S.value)))]),_:1})}}};function H(v="menu"){return{name:v,components:{SvgIcon:ce.SvgIcon,ssMenu:P,DynamicIcon:z,ssDialog:ae.ssDialog},setup(b,{emit:S}){const x=s.defineProps({mode:{type:String,default:"vertical"}}),a=B.useMenuState(),T=B.useModelComp(w.pinia),F=s.ref(0),d=ie.useRouter(),{asideMenus:W,menuTriggerType:J,platform:K}=w.storeToRefs(a),L=s.computed(()=>x==null?void 0:x.mode),$=s.computed(()=>{let e=[...W.value];if((e==null?void 0:e.length)===0)return d.push("/"),[];const t=Y(e,Q.value);return t.isFlag||(e=t==null?void 0:t.data),e}),j=async e=>{T.setRouteToChildPath(""),a.setMenuTriggerType("click"),a.setActiveMenuPath(e==null?void 0:e.path),a.setActiveAsideMenu(e),e.isRouter?d.push(e.path):d.push("/"),S("node-click",e)},G=async e=>{const t=w.findNodeByPropInTree($.value,"path",e);a.setActiveAsideMenu(t),T.setRouteToChildPath(""),J.value==="click"?F.value===1?a.setActiveMenuPath(sessionStorage.getItem("pageKey")):a.setActiveMenuPath(e):(a.setMenuTriggerType("click"),a.setActiveMenuPath(e)),e!=null&&e.startsWith("/")?d.push(e):d.push("/"),F.value++},I=e=>{a.setActiveMenuPath(e)},g=e=>{const t=document.documentElement;e==null||e.forEach(o=>{t.style.setProperty(o.name,o.value)})};s.onMounted(()=>{F.value=1});const Q=s.computed(()=>{const e=sessionStorage.getItem("authority");return e?JSON.parse(e):[]});s.watch(()=>K.value,e=>{e==="browser"?g(A.browserVerticalMenuClasses):e==="client"?(g(A.clientHorizontalMenuClasses),g(A.clientVerticalMenuClasses)):e==="three"&&(g(A.threeHorizontalMenuClasses),g(A.threeVerticalMenuClasses))},{immediate:!0});const X=(e,t)=>{function o(u){u==null||u.forEach(n=>{var M,y;const c=(M=n==null?void 0:n.path)!=null&&M.startsWith("/")?(y=n==null?void 0:n.path)==null?void 0:y.substring(1):n==null?void 0:n.path;n.show=t==null?void 0:t.some(f=>f==null?void 0:f.includes(c)),n.children&&o(n.children)})}return o(e),e},Y=(e,t)=>{if(Array.isArray(t)){const o=Array.from(new Set(t==null?void 0:t.map(u=>u.substring(0,u.lastIndexOf("/")))));return{data:X(e,o),isFlag:!1}}else return{isFlag:(t==null?void 0:t.toUpperCase())==="SUPERADMIN"}},p=s.reactive({show:!1,title:"菜单配置",width:"30%",type:"create"}),Z=e=>pe.getComponent(e),ee=s.ref({}),q=s.ref([]),te=async(e,t,o)=>{var y,f,N;if(!(e!=null&&e.structureIds)||((y=e==null?void 0:e.structureIds)==null?void 0:y.length)===0)return;const u=(N=(f=e==null?void 0:e.structureIds)==null?void 0:f.filter(r=>(r==null?void 0:r.key)==="dialogConfig"))==null?void 0:N.map(r=>r==null?void 0:r.id);let n=u==null?void 0:u.map(r=>w.getInsofDataApi({id:r}));const c=await Promise.all(n);if(c==null?void 0:c.every(r=>{var l;return((l=r==null?void 0:r.data)==null?void 0:l.code)===200})){const r=c==null?void 0:c.map(l=>{var _,m,i,k,D,U,V;return{id:(i=(m=(_=l==null?void 0:l.data)==null?void 0:_.result)==null?void 0:m[0])==null?void 0:i.id,...(V=(U=(D=(k=l==null?void 0:l.data)==null?void 0:k.result)==null?void 0:D[0])==null?void 0:U.value)==null?void 0:V.pageData}});t==="create"&&(q.value=r),t==="update"&&(q.value=r==null?void 0:r.map(l=>{var _,m;return((_=l==null?void 0:l.comp)==null?void 0:_.toUpperCase())==="FORM"?{...l,compData:(m=l==null?void 0:l.compData)==null?void 0:m.map(i=>{var k;return(i==null?void 0:i.key)==="formContent"?{...i,contents:(k=i==null?void 0:i.contents)==null?void 0:k.map(D=>({...D,value:o==null?void 0:o.title}))}:i})}:l}))}},C=s.ref({}),h=s.ref({}),se=e=>{switch(e){case"新增":return"create";case"编辑":return"update";case"删除":return"delete"}},E=s.ref({}),O=e=>{a.setCacheInputMenu({type:p.type,data:e}),a.setIsRefreshMenus(!0)},ne=async(e,t)=>{p.type=se(t==null?void 0:t.operateType),await te(t,p.type,e),h.value=e,E.value=t,(t==null?void 0:t.operateType)!=="删除"?(p.show=(t==null?void 0:t.trigger)==="openDialog",p.title=(t==null?void 0:t.operateType)+"菜单"):B.ElMessageBox.confirm(`是否确认要删除【${e==null?void 0:e.title}】`,"",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{O(e)})},re=()=>{p.show=!1},le=e=>e==null?void 0:e.filter(t=>t.allowInherit),oe=()=>{var o,u,n,c,M;let e;p.type==="create"&&(e=((o=h.value)==null?void 0:o.path)+"/"+C.value[(u=C.value)==null?void 0:u.prop]),p.type==="update"&&(e=(n=h.value)==null?void 0:n.path);const t={...h.value,config:le((c=h.value)==null?void 0:c.config),children:[],childMenus:[],title:C.value[(M=C.value)==null?void 0:M.prop],path:e};console.log("clickSubmitForm",E.value,h.value,t),O(t),p.show=!1},ue=e=>{var o,u;const t=(o=e==null?void 0:e.contents)==null?void 0:o.find(n=>n.key==="formContent");t&&(C.value=(u=t==null?void 0:t.contents)==null?void 0:u.reduce((n,c)=>(n[c.key]=c.value,n.prop=c.key,n),{}))},R=s.ref(!1);return{isCollapse:R,handleMenuCollapse:()=>{R.value=!R.value},handleCompChange:ue,dialogForm:ee,dialogRenderComps:q,getComponents:Z,clickSubmitForm:oe,dialogInfo:p,beforeDialogDestroy:re,clickMenuIcon:ne,mode:L,renderMenuList:$,clickMenu:j,openMenu:G,closeMenu:I,changeMenuStyle:g}}}}const ve=s.defineComponent(H());exports._sfc_main=ve;exports._sfc_main$1=z;exports.setComponent=H;exports.ssMenu=P;
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { defineAsyncComponent as ae, computed as D, onMounted as W, resolveComponent as ue, createBlock as z, openBlock as H, withCtx as ce, resolveDynamicComponent as ie, defineComponent as pe, defineProps as ge, ref as g, watch as ve, reactive as fe } from "vue";
|
|
2
2
|
import { S as he } from "./index-BHtNKL1L.js";
|
|
3
3
|
import { bO as Me, p as me, s as Ce, bN as ye, g as de } from "./index-BUYYl2Pc.js";
|
|
4
|
-
import "./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-
|
|
5
|
-
import { u as Ae, a as we, E as ke } from "./index.vue_vue_type_style_index_1_lang-
|
|
6
|
-
import { s as Te } from "./index-
|
|
4
|
+
import "./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-JTfuXDvR.js";
|
|
5
|
+
import { u as Ae, a as we, E as ke } from "./index.vue_vue_type_style_index_1_lang-DCNwSjkL.js";
|
|
6
|
+
import { s as Te } from "./index-u963fvJq.js";
|
|
7
7
|
import { useRouter as Se } from "vue-router";
|
|
8
8
|
import { a as De, e as Pe, f as _e, g as be, h as Fe } from "./index-CAPx0_D4.js";
|
|
9
|
-
import { g as xe } from "./index-
|
|
10
|
-
const x = ae(() => import("./index-
|
|
9
|
+
import { g as xe } from "./index-Ck1jmhY4.js";
|
|
10
|
+
const x = ae(() => import("./index-d7FbcLhM.js").then((p) => p.j));
|
|
11
11
|
x.install = (p) => {
|
|
12
12
|
p.component("ssMenu", x);
|
|
13
13
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const T3=require("./MTLLoader-MINcyZJJ.cjs"),a=require("./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-pcyvQAbK.cjs"),u2=require("./threeViewerHost-BRhsxthj.cjs"),q3=require("./index-C8qRkCgn.cjs"),f2=require("vue"),p2=require("./index.vue_vue_type_style_index_1_lang-B8_elAaU.cjs");class u1 extends a.DataTextureLoader{constructor(C){super(C)}parse(C){function P(x){switch(x.image_type){case $:case V:if(x.colormap_length>256||x.colormap_size!==24||x.colormap_type!==1)throw new Error("THREE.TGALoader: Invalid type colormap data for indexed type.");break;case h:case o:case z:case y:if(x.colormap_type)throw new Error("THREE.TGALoader: Invalid type colormap data for colormap type.");break;case h3:throw new Error("THREE.TGALoader: No data.");default:throw new Error("THREE.TGALoader: Invalid type "+x.image_type)}if(x.width<=0||x.height<=0)throw new Error("THREE.TGALoader: Invalid image size.");if(x.pixel_size!==8&&x.pixel_size!==16&&x.pixel_size!==24&&x.pixel_size!==32)throw new Error("THREE.TGALoader: Invalid pixel size "+x.pixel_size)}function R(x,o3,i3,Q,u3){let Z,s3;const W=i3.pixel_size>>3,D=i3.width*i3.height*W;if(o3&&(s3=u3.subarray(Q,Q+=i3.colormap_length*(i3.colormap_size>>3))),x){Z=new Uint8Array(D);let S,M,B,a3=0;const v=new Uint8Array(W);for(;a3<D;)if(S=u3[Q++],M=(S&127)+1,S&128){for(B=0;B<W;++B)v[B]=u3[Q++];for(B=0;B<M;++B)Z.set(v,a3+B*W);a3+=W*M}else{for(M*=W,B=0;B<M;++B)Z[a3+B]=u3[Q++];a3+=M}}else Z=u3.subarray(Q,Q+=o3?i3.width*i3.height:D);return{pixel_data:Z,palettes:s3}}function l(x,o3,i3,Q,u3,Z,s3,W,D){const S=D;let M,B=0,a3,v;const K=G.width;for(v=o3;v!==Q;v+=i3)for(a3=u3;a3!==s3;a3+=Z,B++)M=W[B],x[(a3+K*v)*4+3]=255,x[(a3+K*v)*4+2]=S[M*3+0],x[(a3+K*v)*4+1]=S[M*3+1],x[(a3+K*v)*4+0]=S[M*3+2];return x}function _(x,o3,i3,Q,u3,Z,s3,W){let D,S=0,M,B;const a3=G.width;for(B=o3;B!==Q;B+=i3)for(M=u3;M!==s3;M+=Z,S+=2)D=W[S+0]+(W[S+1]<<8),x[(M+a3*B)*4+0]=(D&31744)>>7,x[(M+a3*B)*4+1]=(D&992)>>2,x[(M+a3*B)*4+2]=(D&31)<<3,x[(M+a3*B)*4+3]=D&32768?0:255;return x}function J(x,o3,i3,Q,u3,Z,s3,W){let D=0,S,M;const B=G.width;for(M=o3;M!==Q;M+=i3)for(S=u3;S!==s3;S+=Z,D+=3)x[(S+B*M)*4+3]=255,x[(S+B*M)*4+2]=W[D+0],x[(S+B*M)*4+1]=W[D+1],x[(S+B*M)*4+0]=W[D+2];return x}function F(x,o3,i3,Q,u3,Z,s3,W){let D=0,S,M;const B=G.width;for(M=o3;M!==Q;M+=i3)for(S=u3;S!==s3;S+=Z,D+=4)x[(S+B*M)*4+2]=W[D+0],x[(S+B*M)*4+1]=W[D+1],x[(S+B*M)*4+0]=W[D+2],x[(S+B*M)*4+3]=W[D+3];return x}function X(x,o3,i3,Q,u3,Z,s3,W){let D,S=0,M,B;const a3=G.width;for(B=o3;B!==Q;B+=i3)for(M=u3;M!==s3;M+=Z,S++)D=W[S],x[(M+a3*B)*4+0]=D,x[(M+a3*B)*4+1]=D,x[(M+a3*B)*4+2]=D,x[(M+a3*B)*4+3]=255;return x}function l3(x,o3,i3,Q,u3,Z,s3,W){let D=0,S,M;const B=G.width;for(M=o3;M!==Q;M+=i3)for(S=u3;S!==s3;S+=Z,D+=2)x[(S+B*M)*4+0]=W[D+0],x[(S+B*M)*4+1]=W[D+0],x[(S+B*M)*4+2]=W[D+0],x[(S+B*M)*4+3]=W[D+1];return x}function d3(x,o3,i3,Q,u3){let Z,s3,W,D,S,M;switch((G.flags&p)>>f){default:case I:Z=0,W=1,S=o3,s3=0,D=1,M=i3;break;case L:Z=0,W=1,S=o3,s3=i3-1,D=-1,M=-1;break;case O:Z=o3-1,W=-1,S=-1,s3=0,D=1,M=i3;break;case g:Z=o3-1,W=-1,S=-1,s3=i3-1,D=-1,M=-1;break}if(Y)switch(G.pixel_size){case 8:X(x,s3,D,M,Z,W,S,Q);break;case 16:l3(x,s3,D,M,Z,W,S,Q);break;default:throw new Error("THREE.TGALoader: Format not supported.")}else switch(G.pixel_size){case 8:l(x,s3,D,M,Z,W,S,Q,u3);break;case 16:_(x,s3,D,M,Z,W,S,Q);break;case 24:J(x,s3,D,M,Z,W,S,Q);break;case 32:F(x,s3,D,M,Z,W,S,Q);break;default:throw new Error("THREE.TGALoader: Format not supported.")}return x}const h3=0,$=1,h=2,o=3,V=9,z=10,y=11,p=48,f=4,L=0,g=1,I=2,O=3;if(C.length<19)throw new Error("THREE.TGALoader: Not enough data to contain header.");let u=0;const b=new Uint8Array(C),G={id_length:b[u++],colormap_type:b[u++],image_type:b[u++],colormap_index:b[u++]|b[u++]<<8,colormap_length:b[u++]|b[u++]<<8,colormap_size:b[u++],origin:[b[u++]|b[u++]<<8,b[u++]|b[u++]<<8],width:b[u++]|b[u++]<<8,height:b[u++]|b[u++]<<8,pixel_size:b[u++],flags:b[u++]};if(P(G),G.id_length+u>C.length)throw new Error("THREE.TGALoader: No data.");u+=G.id_length;let U=!1,H=!1,Y=!1;switch(G.image_type){case V:U=!0,H=!0;break;case $:H=!0;break;case z:U=!0;break;case h:break;case y:U=!0,Y=!0;break;case o:Y=!0;break}const A3=new Uint8Array(G.width*G.height*4),g3=R(U,H,G,u,b);return d3(A3,G.width,G.height,g3.pixel_data,g3.palettes),{data:A3,width:G.width,height:G.height,flipY:!0,generateMipmaps:!0,minFilter:a.LinearMipmapLinearFilter}}}class m2 extends a.Loader{load(C,P,R,l){const _=this,J=_.path===""?a.LoaderUtils.extractUrlBase(C):_.path,F=new a.FileLoader(_.manager);F.setPath(_.path),F.setRequestHeader(_.requestHeader),F.setWithCredentials(_.withCredentials),F.load(C,function(X){try{P(_.parse(X,J))}catch(l3){l?l(l3):console.error(l3),_.manager.itemError(C)}},R,l)}parse(C,P){function R(t,e){const i=[],n=t.childNodes;for(let s=0,r=n.length;s<r;s++){const c=n[s];c.nodeName===e&&i.push(c)}return i}function l(t){if(t.length===0)return[];const e=t.trim().split(/\s+/),i=new Array(e.length);for(let n=0,s=e.length;n<s;n++)i[n]=e[n];return i}function _(t){if(t.length===0)return[];const e=t.trim().split(/\s+/),i=new Array(e.length);for(let n=0,s=e.length;n<s;n++)i[n]=parseFloat(e[n]);return i}function J(t){if(t.length===0)return[];const e=t.trim().split(/\s+/),i=new Array(e.length);for(let n=0,s=e.length;n<s;n++)i[n]=parseInt(e[n]);return i}function F(t){return t.substring(1)}function X(){return"three_default_"+d2++}function l3(t){return Object.keys(t).length===0}function d3(t){return{unit:h3(R(t,"unit")[0]),upAxis:$(R(t,"up_axis")[0])}}function h3(t){return t!==void 0&&t.hasAttribute("meter")===!0?parseFloat(t.getAttribute("meter")):1}function $(t){return t!==void 0?t.textContent:"Y_UP"}function h(t,e,i,n){const s=R(t,e)[0];if(s!==void 0){const r=R(s,i);for(let c=0;c<r.length;c++)n(r[c])}}function o(t,e){for(const i in t){const n=t[i];n.build=e(t[i])}}function V(t,e){return t.build!==void 0||(t.build=e(t)),t.build}function z(t){const e={sources:{},samplers:{},channels:{}};let i=!1;for(let n=0,s=t.childNodes.length;n<s;n++){const r=t.childNodes[n];if(r.nodeType!==1)continue;let c;switch(r.nodeName){case"source":c=r.getAttribute("id"),e.sources[c]=j3(r);break;case"sampler":c=r.getAttribute("id"),e.samplers[c]=y(r);break;case"channel":c=r.getAttribute("target"),e.channels[c]=p(r);break;case"animation":z(r),i=!0;break;default:console.log(r)}}i===!1&&(j.animations[t.getAttribute("id")||a.MathUtils.generateUUID()]=e)}function y(t){const e={inputs:{}};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"input":const r=F(s.getAttribute("source")),c=s.getAttribute("semantic");e.inputs[c]=r;break}}return e}function p(t){const e={};let n=t.getAttribute("target").split("/");const s=n.shift();let r=n.shift();const c=r.indexOf("(")!==-1,A=r.indexOf(".")!==-1;if(A)n=r.split("."),r=n.shift(),e.member=n.shift();else if(c){const m=r.split("(");r=m.shift();for(let w=0;w<m.length;w++)m[w]=parseInt(m[w].replace(/\)/,""));e.indices=m}return e.id=s,e.sid=r,e.arraySyntax=c,e.memberSyntax=A,e.sampler=F(t.getAttribute("source")),e}function f(t){const e=[],i=t.channels,n=t.samplers,s=t.sources;for(const r in i)if(i.hasOwnProperty(r)){const c=i[r],A=n[c.sampler],m=A.inputs.INPUT,w=A.inputs.OUTPUT,T=s[m],d=s[w],N=g(c,T,d);G(N,e)}return e}function L(t){return V(j.animations[t],f)}function g(t,e,i){const n=j.nodes[t.id],s=B3(n.id),r=n.transforms[t.sid],c=n.matrix.clone().transpose();let A,m,w,T,d,N;const k={};switch(r){case"matrix":for(w=0,T=e.array.length;w<T;w++)if(A=e.array[w],m=w*i.stride,k[A]===void 0&&(k[A]={}),t.arraySyntax===!0){const m3=i.array[m],c3=t.indices[0]+4*t.indices[1];k[A][c3]=m3}else for(d=0,N=i.stride;d<N;d++)k[A][d]=i.array[m+d];break;case"translate":console.warn('THREE.ColladaLoader: Animation transform type "%s" not yet implemented.',r);break;case"rotate":console.warn('THREE.ColladaLoader: Animation transform type "%s" not yet implemented.',r);break;case"scale":console.warn('THREE.ColladaLoader: Animation transform type "%s" not yet implemented.',r);break}const q=I(k,c);return{name:s.uuid,keyframes:q}}function I(t,e){const i=[];for(const s in t)i.push({time:parseFloat(s),value:t[s]});i.sort(n);for(let s=0;s<16;s++)U(i,s,e.elements[s]);return i;function n(s,r){return s.time-r.time}}const O=new a.Vector3,u=new a.Vector3,b=new a.Quaternion;function G(t,e){const i=t.keyframes,n=t.name,s=[],r=[],c=[],A=[];for(let m=0,w=i.length;m<w;m++){const T=i[m],d=T.time,N=T.value;_3.fromArray(N).transpose(),_3.decompose(O,b,u),s.push(d),r.push(O.x,O.y,O.z),c.push(b.x,b.y,b.z,b.w),A.push(u.x,u.y,u.z)}return r.length>0&&e.push(new a.VectorKeyframeTrack(n+".position",s,r)),c.length>0&&e.push(new a.QuaternionKeyframeTrack(n+".quaternion",s,c)),A.length>0&&e.push(new a.VectorKeyframeTrack(n+".scale",s,A)),e}function U(t,e,i){let n,s=!0,r,c;for(r=0,c=t.length;r<c;r++)n=t[r],n.value[e]===void 0?n.value[e]=null:s=!1;if(s===!0)for(r=0,c=t.length;r<c;r++)n=t[r],n.value[e]=i;else H(t,e)}function H(t,e){let i,n;for(let s=0,r=t.length;s<r;s++){const c=t[s];if(c.value[e]===null){if(i=Y(t,s,e),n=A3(t,s,e),i===null){c.value[e]=n.value[e];continue}if(n===null){c.value[e]=i.value[e];continue}g3(c,i,n,e)}}}function Y(t,e,i){for(;e>=0;){const n=t[e];if(n.value[i]!==null)return n;e--}return null}function A3(t,e,i){for(;e<t.length;){const n=t[e];if(n.value[i]!==null)return n;e++}return null}function g3(t,e,i,n){if(i.time-e.time===0){t.value[n]=e.value[n];return}t.value[n]=(t.time-e.time)*(i.value[n]-e.value[n])/(i.time-e.time)+e.value[n]}function x(t){const e={name:t.getAttribute("id")||"default",start:parseFloat(t.getAttribute("start")||0),end:parseFloat(t.getAttribute("end")||0),animations:[]};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"instance_animation":e.animations.push(F(s.getAttribute("url")));break}}j.clips[t.getAttribute("id")]=e}function o3(t){const e=[],i=t.name,n=t.end-t.start||-1,s=t.animations;for(let r=0,c=s.length;r<c;r++){const A=L(s[r]);for(let m=0,w=A.length;m<w;m++)e.push(A[m])}return new a.AnimationClip(i,n,e)}function i3(t){return V(j.clips[t],o3)}function Q(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"skin":e.id=F(s.getAttribute("source")),e.skin=u3(s);break;case"morph":e.id=F(s.getAttribute("source")),console.warn("THREE.ColladaLoader: Morph target animation not supported yet.");break}}j.controllers[t.getAttribute("id")]=e}function u3(t){const e={sources:{}};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"bind_shape_matrix":e.bindShapeMatrix=_(s.textContent);break;case"source":const r=s.getAttribute("id");e.sources[r]=j3(s);break;case"joints":e.joints=Z(s);break;case"vertex_weights":e.vertexWeights=s3(s);break}}return e}function Z(t){const e={inputs:{}};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"input":const r=s.getAttribute("semantic"),c=F(s.getAttribute("source"));e.inputs[r]=c;break}}return e}function s3(t){const e={inputs:{}};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"input":const r=s.getAttribute("semantic"),c=F(s.getAttribute("source")),A=parseInt(s.getAttribute("offset"));e.inputs[r]={id:c,offset:A};break;case"vcount":e.vcount=J(s.textContent);break;case"v":e.v=J(s.textContent);break}}return e}function W(t){const e={id:t.id},i=j.geometries[e.id];return t.skin!==void 0&&(e.skin=D(t.skin),i.sources.skinIndices=e.skin.indices,i.sources.skinWeights=e.skin.weights),e}function D(t){const i={joints:[],indices:{array:[],stride:4},weights:{array:[],stride:4}},n=t.sources,s=t.vertexWeights,r=s.vcount,c=s.v,A=s.inputs.JOINT.offset,m=s.inputs.WEIGHT.offset,w=t.sources[t.joints.inputs.JOINT],T=t.sources[t.joints.inputs.INV_BIND_MATRIX],d=n[s.inputs.WEIGHT.id].array;let N=0,k,q,E;for(k=0,E=r.length;k<E;k++){const c3=r[k],t3=[];for(q=0;q<c3;q++){const n3=c[N+A],H3=c[N+m],k3=d[H3];t3.push({index:n3,weight:k3}),N+=2}for(t3.sort(m3),q=0;q<4;q++){const n3=t3[q];n3!==void 0?(i.indices.array.push(n3.index),i.weights.array.push(n3.weight)):(i.indices.array.push(0),i.weights.array.push(0))}}for(t.bindShapeMatrix?i.bindMatrix=new a.Matrix4().fromArray(t.bindShapeMatrix).transpose():i.bindMatrix=new a.Matrix4().identity(),k=0,E=w.array.length;k<E;k++){const c3=w.array[k],t3=new a.Matrix4().fromArray(T.array,k*T.stride).transpose();i.joints.push({name:c3,boneInverse:t3})}return i;function m3(c3,t3){return t3.weight-c3.weight}}function S(t){return V(j.controllers[t],W)}function M(t){const e={init_from:R(t,"init_from")[0].textContent};j.images[t.getAttribute("id")]=e}function B(t){return t.build!==void 0?t.build:t.init_from}function a3(t){const e=j.images[t];return e!==void 0?V(e,B):(console.warn("THREE.ColladaLoader: Couldn't find image with ID:",t),null)}function v(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"profile_COMMON":e.profile=K(s);break}}j.effects[t.getAttribute("id")]=e}function K(t){const e={surfaces:{},samplers:{}};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"newparam":e3(s,e);break;case"technique":e.technique=r3(s);break;case"extra":e.extra=p3(s);break}}return e}function e3(t,e){const i=t.getAttribute("sid");for(let n=0,s=t.childNodes.length;n<s;n++){const r=t.childNodes[n];if(r.nodeType===1)switch(r.nodeName){case"surface":e.surfaces[i]=f3(r);break;case"sampler2D":e.samplers[i]=x3(r);break}}}function f3(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"init_from":e.init_from=s.textContent;break}}return e}function x3(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"source":e.source=s.textContent;break}}return e}function r3(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"constant":case"lambert":case"blinn":case"phong":e.type=s.nodeName,e.parameters=z3(s);break;case"extra":e.extra=p3(s);break}}return e}function z3(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"emission":case"diffuse":case"specular":case"bump":case"ambient":case"shininess":case"transparency":e[s.nodeName]=L3(s);break;case"transparent":e[s.nodeName]={opaque:s.hasAttribute("opaque")?s.getAttribute("opaque"):"A_ONE",data:L3(s)};break}}return e}function L3(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"color":e[s.nodeName]=_(s.textContent);break;case"float":e[s.nodeName]=parseFloat(s.textContent);break;case"texture":e[s.nodeName]={id:s.getAttribute("texture"),extra:b3(s)};break}}return e}function b3(t){const e={technique:{}};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"extra":M3(s,e);break}}return e}function M3(t,e){for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"technique":y3(s,e);break}}}function y3(t,e){for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"repeatU":case"repeatV":case"offsetU":case"offsetV":e.technique[s.nodeName]=parseFloat(s.textContent);break;case"wrapU":case"wrapV":s.textContent.toUpperCase()==="TRUE"?e.technique[s.nodeName]=1:s.textContent.toUpperCase()==="FALSE"?e.technique[s.nodeName]=0:e.technique[s.nodeName]=parseInt(s.textContent);break;case"bump":e[s.nodeName]=R3(s);break}}}function p3(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"technique":e.technique=N3(s);break}}return e}function N3(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"double_sided":e[s.nodeName]=parseInt(s.textContent);break;case"bump":e[s.nodeName]=R3(s);break}}return e}function R3(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"texture":e[s.nodeName]={id:s.getAttribute("texture"),texcoord:s.getAttribute("texcoord"),extra:b3(s)};break}}return e}function W3(t){return t}function y1(t){return V(j.effects[t],W3)}function w1(t){const e={name:t.getAttribute("name")};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"instance_effect":e.url=F(s.getAttribute("url"));break}}j.materials[t.getAttribute("id")]=e}function v1(t){let e,i=t.slice((t.lastIndexOf(".")-1>>>0)+2);switch(i=i.toLowerCase(),i){case"tga":e=P3;break;default:e=l1}return e}function J3(t){const e=y1(t.url),i=e.profile.technique;let n;switch(i.type){case"phong":case"blinn":n=new a.MeshPhongMaterial;break;case"lambert":n=new a.MeshLambertMaterial;break;default:n=new a.MeshBasicMaterial;break}n.name=t.name||"";function s(m,w=null){const T=e.profile.samplers[m.id];let d=null;if(T!==void 0){const N=e.profile.surfaces[T.source];d=a3(N.init_from)}else console.warn("THREE.ColladaLoader: Undefined sampler. Access image directly (see #12530)."),d=a3(m.id);if(d!==null){const N=v1(d);if(N!==void 0){const k=N.load(d),q=m.extra;if(q!==void 0&&q.technique!==void 0&&l3(q.technique)===!1){const E=q.technique;k.wrapS=E.wrapU?a.RepeatWrapping:a.ClampToEdgeWrapping,k.wrapT=E.wrapV?a.RepeatWrapping:a.ClampToEdgeWrapping,k.offset.set(E.offsetU||0,E.offsetV||0),k.repeat.set(E.repeatU||1,E.repeatV||1)}else k.wrapS=a.RepeatWrapping,k.wrapT=a.RepeatWrapping;return w!==null&&(k.colorSpace=w),k}else return console.warn("THREE.ColladaLoader: Loader for texture %s not found.",d),null}else return console.warn("THREE.ColladaLoader: Couldn't create texture with ID:",m.id),null}const r=i.parameters;for(const m in r){const w=r[m];switch(m){case"diffuse":w.color&&n.color.fromArray(w.color),w.texture&&(n.map=s(w.texture,a.SRGBColorSpace));break;case"specular":w.color&&n.specular&&n.specular.fromArray(w.color),w.texture&&(n.specularMap=s(w.texture));break;case"bump":w.texture&&(n.normalMap=s(w.texture));break;case"ambient":w.texture&&(n.lightMap=s(w.texture,a.SRGBColorSpace));break;case"shininess":w.float&&n.shininess&&(n.shininess=w.float);break;case"emission":w.color&&n.emissive&&n.emissive.fromArray(w.color),w.texture&&(n.emissiveMap=s(w.texture,a.SRGBColorSpace));break}}a.ColorManagement.colorSpaceToWorking(n.color,a.SRGBColorSpace),n.specular&&a.ColorManagement.colorSpaceToWorking(n.specular,a.SRGBColorSpace),n.emissive&&a.ColorManagement.colorSpaceToWorking(n.emissive,a.SRGBColorSpace);let c=r.transparent,A=r.transparency;if(A===void 0&&c&&(A={float:1}),c===void 0&&A&&(c={opaque:"A_ONE",data:{color:[1,1,1,1]}}),c&&A)if(c.data.texture)n.transparent=!0;else{const m=c.data.color;switch(c.opaque){case"A_ONE":n.opacity=m[3]*A.float;break;case"RGB_ZERO":n.opacity=1-m[0]*A.float;break;case"A_ZERO":n.opacity=1-m[3]*A.float;break;case"RGB_ONE":n.opacity=m[0]*A.float;break;default:console.warn('THREE.ColladaLoader: Invalid opaque type "%s" of transparent tag.',c.opaque)}n.opacity<1&&(n.transparent=!0)}if(i.extra!==void 0&&i.extra.technique!==void 0){const m=i.extra.technique;for(const w in m){const T=m[w];switch(w){case"double_sided":n.side=T===1?a.DoubleSide:a.FrontSide;break;case"bump":n.normalMap=s(T.texture),n.normalScale=new a.Vector2(1,1);break}}}return n}function z1(t){return V(j.materials[t],J3)}function M1(t){const e={name:t.getAttribute("name")};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"optics":e.optics=x1(s);break}}j.cameras[t.getAttribute("id")]=e}function x1(t){for(let e=0;e<t.childNodes.length;e++){const i=t.childNodes[e];switch(i.nodeName){case"technique_common":return A1(i)}}return{}}function A1(t){const e={};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];switch(n.nodeName){case"perspective":case"orthographic":e.technique=n.nodeName,e.parameters=L1(n);break}}return e}function L1(t){const e={};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];switch(n.nodeName){case"xfov":case"yfov":case"xmag":case"ymag":case"znear":case"zfar":case"aspect_ratio":e[n.nodeName]=parseFloat(n.textContent);break}}return e}function K3(t){let e;switch(t.optics.technique){case"perspective":e=new a.PerspectiveCamera(t.optics.parameters.yfov,t.optics.parameters.aspect_ratio,t.optics.parameters.znear,t.optics.parameters.zfar);break;case"orthographic":let i=t.optics.parameters.ymag,n=t.optics.parameters.xmag;const s=t.optics.parameters.aspect_ratio;n=n===void 0?i*s:n,i=i===void 0?n/s:i,n*=.5,i*=.5,e=new a.OrthographicCamera(-n,n,i,-i,t.optics.parameters.znear,t.optics.parameters.zfar);break;default:e=new a.PerspectiveCamera;break}return e.name=t.name||"",e}function k1(t){const e=j.cameras[t];return e!==void 0?V(e,K3):(console.warn("THREE.ColladaLoader: Couldn't find camera with ID:",t),null)}function _1(t){let e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"technique_common":e=N1(s);break}}j.lights[t.getAttribute("id")]=e}function N1(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"directional":case"point":case"spot":case"ambient":e.technique=s.nodeName,e.parameters=C1(s)}}return e}function C1(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"color":const r=_(s.textContent);e.color=new a.Color().fromArray(r),a.ColorManagement.colorSpaceToWorking(e.color,a.SRGBColorSpace);break;case"falloff_angle":e.falloffAngle=parseFloat(s.textContent);break;case"quadratic_attenuation":const c=parseFloat(s.textContent);e.distance=c?Math.sqrt(1/c):0;break}}return e}function Y3(t){let e;switch(t.technique){case"directional":e=new a.DirectionalLight;break;case"point":e=new a.PointLight;break;case"spot":e=new a.SpotLight;break;case"ambient":e=new a.AmbientLight;break}return t.parameters.color&&e.color.copy(t.parameters.color),t.parameters.distance&&(e.distance=t.parameters.distance),e}function T1(t){const e=j.lights[t];return e!==void 0?V(e,Y3):(console.warn("THREE.ColladaLoader: Couldn't find light with ID:",t),null)}function H1(t){const e={name:t.getAttribute("name"),sources:{},vertices:{},primitives:[]},i=R(t,"mesh")[0];if(i!==void 0){for(let n=0;n<i.childNodes.length;n++){const s=i.childNodes[n];if(s.nodeType!==1)continue;const r=s.getAttribute("id");switch(s.nodeName){case"source":e.sources[r]=j3(s);break;case"vertices":e.vertices=E1(s);break;case"polygons":console.warn("THREE.ColladaLoader: Unsupported primitive type: ",s.nodeName);break;case"lines":case"linestrips":case"polylist":case"triangles":e.primitives.push(B1(s));break;default:console.log(s)}}j.geometries[t.getAttribute("id")]=e}}function j3(t){const e={array:[],stride:3};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"float_array":e.array=_(n.textContent);break;case"Name_array":e.array=l(n.textContent);break;case"technique_common":const s=R(n,"accessor")[0];s!==void 0&&(e.stride=parseInt(s.getAttribute("stride")));break}}return e}function E1(t){const e={};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];n.nodeType===1&&(e[n.getAttribute("semantic")]=F(n.getAttribute("source")))}return e}function B1(t){const e={type:t.nodeName,material:t.getAttribute("material"),count:parseInt(t.getAttribute("count")),inputs:{},stride:0,hasUV:!1};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"input":const r=F(s.getAttribute("source")),c=s.getAttribute("semantic"),A=parseInt(s.getAttribute("offset")),m=parseInt(s.getAttribute("set")),w=m>0?c+m:c;e.inputs[w]={id:r,offset:A},e.stride=Math.max(e.stride,A+1),c==="TEXCOORD"&&(e.hasUV=!0);break;case"vcount":e.vcount=J(s.textContent);break;case"p":e.p=J(s.textContent);break}}return e}function V1(t){const e={};for(let i=0;i<t.length;i++){const n=t[i];e[n.type]===void 0&&(e[n.type]=[]),e[n.type].push(n)}return e}function S1(t){let e=0;for(let i=0,n=t.length;i<n;i++)t[i].hasUV===!0&&e++;e>0&&e<t.length&&(t.uvsNeedsFix=!0)}function X3(t){const e={},i=t.sources,n=t.vertices,s=t.primitives;if(s.length===0)return{};const r=V1(s);for(const c in r){const A=r[c];S1(A),e[c]=q1(A,i,n)}return e}function q1(t,e,i){const n={},s={array:[],stride:0},r={array:[],stride:0},c={array:[],stride:0},A={array:[],stride:0},m={array:[],stride:0},w={array:[],stride:4},T={array:[],stride:4},d=new a.BufferGeometry,N=[];let k=0;for(let q=0;q<t.length;q++){const E=t[q],m3=E.inputs;let c3=0;switch(E.type){case"lines":case"linestrips":c3=E.count*2;break;case"triangles":c3=E.count*3;break;case"polylist":for(let t3=0;t3<E.count;t3++){const n3=E.vcount[t3];switch(n3){case 3:c3+=3;break;case 4:c3+=6;break;default:c3+=(n3-2)*3;break}}break;default:console.warn("THREE.ColladaLoader: Unknown primitive type:",E.type)}d.addGroup(k,c3,q),k+=c3,E.material&&N.push(E.material);for(const t3 in m3){const n3=m3[t3];switch(t3){case"VERTEX":for(const H3 in i){const k3=i[H3];switch(H3){case"POSITION":const V3=s.array.length;if(C3(E,e[k3],n3.offset,s.array),s.stride=e[k3].stride,e.skinWeights&&e.skinIndices&&(C3(E,e.skinIndices,n3.offset,w.array),C3(E,e.skinWeights,n3.offset,T.array)),E.hasUV===!1&&t.uvsNeedsFix===!0){const h2=(s.array.length-V3)/s.stride;for(let h1=0;h1<h2;h1++)c.array.push(0,0)}break;case"NORMAL":C3(E,e[k3],n3.offset,r.array),r.stride=e[k3].stride;break;case"COLOR":C3(E,e[k3],n3.offset,m.array),m.stride=e[k3].stride;break;case"TEXCOORD":C3(E,e[k3],n3.offset,c.array),c.stride=e[k3].stride;break;case"TEXCOORD1":C3(E,e[k3],n3.offset,A.array),c.stride=e[k3].stride;break;default:console.warn('THREE.ColladaLoader: Semantic "%s" not handled in geometry build process.',H3)}}break;case"NORMAL":C3(E,e[n3.id],n3.offset,r.array),r.stride=e[n3.id].stride;break;case"COLOR":C3(E,e[n3.id],n3.offset,m.array,!0),m.stride=e[n3.id].stride;break;case"TEXCOORD":C3(E,e[n3.id],n3.offset,c.array),c.stride=e[n3.id].stride;break;case"TEXCOORD1":C3(E,e[n3.id],n3.offset,A.array),A.stride=e[n3.id].stride;break}}}return s.array.length>0&&d.setAttribute("position",new a.Float32BufferAttribute(s.array,s.stride)),r.array.length>0&&d.setAttribute("normal",new a.Float32BufferAttribute(r.array,r.stride)),m.array.length>0&&d.setAttribute("color",new a.Float32BufferAttribute(m.array,m.stride)),c.array.length>0&&d.setAttribute("uv",new a.Float32BufferAttribute(c.array,c.stride)),A.array.length>0&&d.setAttribute("uv1",new a.Float32BufferAttribute(A.array,A.stride)),w.array.length>0&&d.setAttribute("skinIndex",new a.Float32BufferAttribute(w.array,w.stride)),T.array.length>0&&d.setAttribute("skinWeight",new a.Float32BufferAttribute(T.array,T.stride)),n.data=d,n.type=t[0].type,n.materialKeys=N,n}function C3(t,e,i,n,s=!1){const r=t.p,c=t.stride,A=t.vcount;function m(d){let N=r[d+i]*T;const k=N+T;for(;N<k;N++)n.push(w[N]);if(s){const q=n.length-T-1;F3.setRGB(n[q+0],n[q+1],n[q+2],a.SRGBColorSpace),n[q+0]=F3.r,n[q+1]=F3.g,n[q+2]=F3.b}}const w=e.array,T=e.stride;if(t.vcount!==void 0){let d=0;for(let N=0,k=A.length;N<k;N++){const q=A[N];if(q===4){const E=d+c*0,m3=d+c*1,c3=d+c*2,t3=d+c*3;m(E),m(m3),m(t3),m(m3),m(c3),m(t3)}else if(q===3){const E=d+c*0,m3=d+c*1,c3=d+c*2;m(E),m(m3),m(c3)}else if(q>4)for(let E=1,m3=q-2;E<=m3;E++){const c3=d+c*0,t3=d+c*E,n3=d+c*(E+1);m(c3),m(t3),m(n3)}d+=c*q}}else for(let d=0,N=r.length;d<N;d+=c)m(d)}function Z3(t){return V(j.geometries[t],X3)}function R1(t){const e={name:t.getAttribute("name")||"",joints:{},links:[]};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"technique_common":O1(n,e);break}}j.kinematicsModels[t.getAttribute("id")]=e}function F1(t){return t.build!==void 0?t.build:t}function I1(t){return V(j.kinematicsModels[t],F1)}function O1(t,e){for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"joint":e.joints[n.getAttribute("sid")]=U1(n);break;case"link":e.links.push(Q3(n));break}}}function U1(t){let e;for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"prismatic":case"revolute":e=j1(n);break}}return e}function j1(t){const e={sid:t.getAttribute("sid"),name:t.getAttribute("name")||"",axis:new a.Vector3,limits:{min:0,max:0},type:t.nodeName,static:!1,zeroPosition:0,middlePosition:0};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"axis":const s=_(n.textContent);e.axis.fromArray(s);break;case"limits":const r=n.getElementsByTagName("max")[0],c=n.getElementsByTagName("min")[0];e.limits.max=parseFloat(r.textContent),e.limits.min=parseFloat(c.textContent);break}}return e.limits.min>=e.limits.max&&(e.static=!0),e.middlePosition=(e.limits.min+e.limits.max)/2,e}function Q3(t){const e={sid:t.getAttribute("sid"),name:t.getAttribute("name")||"",attachments:[],transforms:[]};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"attachment_full":e.attachments.push(D1(n));break;case"matrix":case"translate":case"rotate":e.transforms.push(e1(n));break}}return e}function D1(t){const e={joint:t.getAttribute("joint").split("/").pop(),transforms:[],links:[]};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"link":e.links.push(Q3(n));break;case"matrix":case"translate":case"rotate":e.transforms.push(e1(n));break}}return e}function e1(t){const e={type:t.nodeName},i=_(t.textContent);switch(e.type){case"matrix":e.obj=new a.Matrix4,e.obj.fromArray(i).transpose();break;case"translate":e.obj=new a.Vector3,e.obj.fromArray(i);break;case"rotate":e.obj=new a.Vector3,e.obj.fromArray(i),e.angle=a.MathUtils.degToRad(i[3]);break}return e}function G1(t){const e={name:t.getAttribute("name")||"",rigidBodies:{}};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"rigid_body":e.rigidBodies[n.getAttribute("name")]={},P1(n,e.rigidBodies[n.getAttribute("name")]);break}}j.physicsModels[t.getAttribute("id")]=e}function P1(t,e){for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"technique_common":$1(n,e);break}}}function $1(t,e){for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"inertia":e.inertia=_(n.textContent);break;case"mass":e.mass=_(n.textContent)[0];break}}}function W1(t){const e={bindJointAxis:[]};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"bind_joint_axis":e.bindJointAxis.push(J1(n));break}}j.kinematicsScenes[F(t.getAttribute("url"))]=e}function J1(t){const e={target:t.getAttribute("target").split("/").pop()};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"axis":const s=n.getElementsByTagName("param")[0];e.axis=s.textContent;const r=e.axis.split("inst_").pop().split("axis")[0];e.jointIndex=r.substring(0,r.length-1);break}}return e}function K1(t){return t.build!==void 0?t.build:t}function Y1(t){return V(j.kinematicsScenes[t],K1)}function X1(){const t=Object.keys(j.kinematicsModels)[0],e=Object.keys(j.kinematicsScenes)[0],i=Object.keys(j.visualScenes)[0];if(t===void 0||e===void 0)return;const n=I1(t),s=Y1(e),r=o1(i),c=s.bindJointAxis,A={};for(let T=0,d=c.length;T<d;T++){const N=c[T],k=w3.querySelector('[sid="'+N.target+'"]');if(k){const q=k.parentElement;m(N.jointIndex,q)}}function m(T,d){const N=d.getAttribute("name"),k=n.joints[T];r.traverse(function(q){q.name===N&&(A[T]={object:q,transforms:Z1(d),joint:k,position:k.zeroPosition})})}const w=new a.Matrix4;d1={joints:n&&n.joints,getJointValue:function(T){const d=A[T];if(d)return d.position;console.warn("THREE.ColladaLoader: Joint "+T+" doesn't exist.")},setJointValue:function(T,d){const N=A[T];if(N){const k=N.joint;if(d>k.limits.max||d<k.limits.min)console.warn("THREE.ColladaLoader: Joint "+T+" value "+d+" outside of limits (min: "+k.limits.min+", max: "+k.limits.max+").");else if(k.static)console.warn("THREE.ColladaLoader: Joint "+T+" is static.");else{const q=N.object,E=k.axis,m3=N.transforms;_3.identity();for(let c3=0;c3<m3.length;c3++){const t3=m3[c3];if(t3.sid&&t3.sid.indexOf(T)!==-1)switch(k.type){case"revolute":_3.multiply(w.makeRotationAxis(E,a.MathUtils.degToRad(d)));break;case"prismatic":_3.multiply(w.makeTranslation(E.x*d,E.y*d,E.z*d));break;default:console.warn("THREE.ColladaLoader: Unknown joint type: "+k.type);break}else switch(t3.type){case"matrix":_3.multiply(t3.obj);break;case"translate":_3.multiply(w.makeTranslation(t3.obj.x,t3.obj.y,t3.obj.z));break;case"scale":_3.scale(t3.obj);break;case"rotate":_3.multiply(w.makeRotationAxis(t3.obj,t3.angle));break}}q.matrix.copy(_3),q.matrix.decompose(q.position,q.quaternion,q.scale),A[T].position=d}}else console.log("THREE.ColladaLoader: "+T+" does not exist.")}}}function Z1(t){const e=[],i=w3.querySelector('[id="'+t.id+'"]');for(let n=0;n<i.childNodes.length;n++){const s=i.childNodes[n];if(s.nodeType!==1)continue;let r,c;switch(s.nodeName){case"matrix":r=_(s.textContent);const A=new a.Matrix4().fromArray(r).transpose();e.push({sid:s.getAttribute("sid"),type:s.nodeName,obj:A});break;case"translate":case"scale":r=_(s.textContent),c=new a.Vector3().fromArray(r),e.push({sid:s.getAttribute("sid"),type:s.nodeName,obj:c});break;case"rotate":r=_(s.textContent),c=new a.Vector3().fromArray(r);const m=a.MathUtils.degToRad(r[3]);e.push({sid:s.getAttribute("sid"),type:s.nodeName,obj:c,angle:m});break}}return e}function Q1(t){const e=t.getElementsByTagName("node");for(let i=0;i<e.length;i++){const n=e[i];n.hasAttribute("id")===!1&&n.setAttribute("id",X())}}const _3=new a.Matrix4,E3=new a.Vector3;function D3(t){const e={name:t.getAttribute("name")||"",type:t.getAttribute("type"),id:t.getAttribute("id"),sid:t.getAttribute("sid"),matrix:new a.Matrix4,nodes:[],instanceCameras:[],instanceControllers:[],instanceLights:[],instanceGeometries:[],instanceNodes:[],transforms:{}};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType!==1)continue;let s;switch(n.nodeName){case"node":e.nodes.push(n.getAttribute("id")),D3(n);break;case"instance_camera":e.instanceCameras.push(F(n.getAttribute("url")));break;case"instance_controller":e.instanceControllers.push(t1(n));break;case"instance_light":e.instanceLights.push(F(n.getAttribute("url")));break;case"instance_geometry":e.instanceGeometries.push(t1(n));break;case"instance_node":e.instanceNodes.push(F(n.getAttribute("url")));break;case"matrix":s=_(n.textContent),e.matrix.multiply(_3.fromArray(s).transpose()),e.transforms[n.getAttribute("sid")]=n.nodeName;break;case"translate":s=_(n.textContent),E3.fromArray(s),e.matrix.multiply(_3.makeTranslation(E3.x,E3.y,E3.z)),e.transforms[n.getAttribute("sid")]=n.nodeName;break;case"rotate":s=_(n.textContent);const r=a.MathUtils.degToRad(s[3]);e.matrix.multiply(_3.makeRotationAxis(E3.fromArray(s),r)),e.transforms[n.getAttribute("sid")]=n.nodeName;break;case"scale":s=_(n.textContent),e.matrix.scale(E3.fromArray(s)),e.transforms[n.getAttribute("sid")]=n.nodeName;break;case"extra":break;default:console.log(n)}}return s1(e.id)?console.warn("THREE.ColladaLoader: There is already a node with ID %s. Exclude current node from further processing.",e.id):j.nodes[e.id]=e,e}function t1(t){const e={id:F(t.getAttribute("url")),materials:{},skeletons:[]};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];switch(n.nodeName){case"bind_material":const s=n.getElementsByTagName("instance_material");for(let r=0;r<s.length;r++){const c=s[r],A=c.getAttribute("symbol"),m=c.getAttribute("target");e.materials[A]=F(m)}break;case"skeleton":e.skeletons.push(F(n.textContent));break}}return e}function e2(t,e){const i=[],n=[];let s,r,c;for(s=0;s<t.length;s++){const w=t[s];let T;if(s1(w))T=B3(w),n1(T,e,i);else if(a2(w)){const N=j.visualScenes[w].children;for(let k=0;k<N.length;k++){const q=N[k];if(q.type==="JOINT"){const E=B3(q.id);n1(E,e,i)}}}else console.error("THREE.ColladaLoader: Unable to find root bone of skeleton with ID:",w)}for(s=0;s<e.length;s++)for(r=0;r<i.length;r++)if(c=i[r],c.bone.name===e[s].name){n[s]=c,c.processed=!0;break}for(s=0;s<i.length;s++)c=i[s],c.processed===!1&&(n.push(c),c.processed=!0);const A=[],m=[];for(s=0;s<n.length;s++)c=n[s],A.push(c.bone),m.push(c.boneInverse);return new a.Skeleton(A,m)}function n1(t,e,i){t.traverse(function(n){if(n.isBone===!0){let s;for(let r=0;r<e.length;r++){const c=e[r];if(c.name===n.name){s=c.boneInverse;break}}s===void 0&&(s=new a.Matrix4),i.push({bone:n,boneInverse:s,processed:!1})}})}function t2(t){const e=[],i=t.matrix,n=t.nodes,s=t.type,r=t.instanceCameras,c=t.instanceControllers,A=t.instanceLights,m=t.instanceGeometries,w=t.instanceNodes;for(let d=0,N=n.length;d<N;d++)e.push(B3(n[d]));for(let d=0,N=r.length;d<N;d++){const k=k1(r[d]);k!==null&&e.push(k.clone())}for(let d=0,N=c.length;d<N;d++){const k=c[d],q=S(k.id),E=Z3(q.id),m3=i1(E,k.materials),c3=k.skeletons,t3=q.skin.joints,n3=e2(c3,t3);for(let H3=0,k3=m3.length;H3<k3;H3++){const V3=m3[H3];V3.isSkinnedMesh&&(V3.bind(n3,q.skin.bindMatrix),V3.normalizeSkinWeights()),e.push(V3)}}for(let d=0,N=A.length;d<N;d++){const k=T1(A[d]);k!==null&&e.push(k.clone())}for(let d=0,N=m.length;d<N;d++){const k=m[d],q=Z3(k.id),E=i1(q,k.materials);for(let m3=0,c3=E.length;m3<c3;m3++)e.push(E[m3])}for(let d=0,N=w.length;d<N;d++)e.push(B3(w[d]).clone());let T;if(n.length===0&&e.length===1)T=e[0];else{T=s==="JOINT"?new a.Bone:new a.Group;for(let d=0;d<e.length;d++)T.add(e[d])}return T.name=s==="JOINT"?t.sid:t.name,T.matrix.copy(i),T.matrix.decompose(T.position,T.quaternion,T.scale),T}const n2=new a.MeshBasicMaterial({name:a.Loader.DEFAULT_MATERIAL_NAME,color:16711935});function i2(t,e){const i=[];for(let n=0,s=t.length;n<s;n++){const r=e[t[n]];r===void 0?(console.warn("THREE.ColladaLoader: Material with key %s not found. Apply fallback material.",t[n]),i.push(n2)):i.push(z1(r))}return i}function i1(t,e){const i=[];for(const n in t){const s=t[n],r=i2(s.materialKeys,e);if(r.length===0&&(n==="lines"||n==="linestrips"?r.push(new a.LineBasicMaterial):r.push(new a.MeshPhongMaterial)),n==="lines"||n==="linestrips")for(let w=0,T=r.length;w<T;w++){const d=r[w];if(d.isMeshPhongMaterial===!0||d.isMeshLambertMaterial===!0){const N=new a.LineBasicMaterial;N.color.copy(d.color),N.opacity=d.opacity,N.transparent=d.transparent,r[w]=N}}const c=s.data.attributes.skinIndex!==void 0,A=r.length===1?r[0]:r;let m;switch(n){case"lines":m=new a.LineSegments(s.data,A);break;case"linestrips":m=new a.Line(s.data,A);break;case"triangles":case"polylist":c?m=new a.SkinnedMesh(s.data,A):m=new a.Mesh(s.data,A);break}i.push(m)}return i}function s1(t){return j.nodes[t]!==void 0}function B3(t){return V(j.nodes[t],t2)}function s2(t){const e={name:t.getAttribute("name"),children:[]};Q1(t);const i=R(t,"node");for(let n=0;n<i.length;n++)e.children.push(D3(i[n]));j.visualScenes[t.getAttribute("id")]=e}function a1(t){const e=new a.Group;e.name=t.name;const i=t.children;for(let n=0;n<i.length;n++){const s=i[n];e.add(B3(s.id))}return e}function a2(t){return j.visualScenes[t]!==void 0}function o1(t){return V(j.visualScenes[t],a1)}function o2(t){const e=R(t,"instance_visual_scene")[0];return o1(F(e.getAttribute("url")))}function r2(){const t=j.clips;if(l3(t)===!0){if(l3(j.animations)===!1){const e=[];for(const i in j.animations){const n=L(i);for(let s=0,r=n.length;s<r;s++)e.push(n[s])}I3.push(new a.AnimationClip("default",-1,e))}}else for(const e in t)I3.push(i3(e))}function c2(t){let e="";const i=[t];for(;i.length;){const n=i.shift();n.nodeType===Node.TEXT_NODE?e+=n.textContent:(e+=`
|
|
1
|
+
"use strict";const T3=require("./MTLLoader-rHpbWTI_.cjs"),a=require("./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-CSGUG8yi.cjs"),u2=require("./threeViewerHost-BDh0cvdZ.cjs"),q3=require("./index-C8qRkCgn.cjs"),f2=require("vue"),p2=require("./index.vue_vue_type_style_index_1_lang-_MRLV2pU.cjs");class u1 extends a.DataTextureLoader{constructor(C){super(C)}parse(C){function P(x){switch(x.image_type){case $:case V:if(x.colormap_length>256||x.colormap_size!==24||x.colormap_type!==1)throw new Error("THREE.TGALoader: Invalid type colormap data for indexed type.");break;case h:case o:case z:case y:if(x.colormap_type)throw new Error("THREE.TGALoader: Invalid type colormap data for colormap type.");break;case h3:throw new Error("THREE.TGALoader: No data.");default:throw new Error("THREE.TGALoader: Invalid type "+x.image_type)}if(x.width<=0||x.height<=0)throw new Error("THREE.TGALoader: Invalid image size.");if(x.pixel_size!==8&&x.pixel_size!==16&&x.pixel_size!==24&&x.pixel_size!==32)throw new Error("THREE.TGALoader: Invalid pixel size "+x.pixel_size)}function R(x,o3,i3,Q,u3){let Z,s3;const W=i3.pixel_size>>3,D=i3.width*i3.height*W;if(o3&&(s3=u3.subarray(Q,Q+=i3.colormap_length*(i3.colormap_size>>3))),x){Z=new Uint8Array(D);let S,M,B,a3=0;const v=new Uint8Array(W);for(;a3<D;)if(S=u3[Q++],M=(S&127)+1,S&128){for(B=0;B<W;++B)v[B]=u3[Q++];for(B=0;B<M;++B)Z.set(v,a3+B*W);a3+=W*M}else{for(M*=W,B=0;B<M;++B)Z[a3+B]=u3[Q++];a3+=M}}else Z=u3.subarray(Q,Q+=o3?i3.width*i3.height:D);return{pixel_data:Z,palettes:s3}}function l(x,o3,i3,Q,u3,Z,s3,W,D){const S=D;let M,B=0,a3,v;const K=G.width;for(v=o3;v!==Q;v+=i3)for(a3=u3;a3!==s3;a3+=Z,B++)M=W[B],x[(a3+K*v)*4+3]=255,x[(a3+K*v)*4+2]=S[M*3+0],x[(a3+K*v)*4+1]=S[M*3+1],x[(a3+K*v)*4+0]=S[M*3+2];return x}function _(x,o3,i3,Q,u3,Z,s3,W){let D,S=0,M,B;const a3=G.width;for(B=o3;B!==Q;B+=i3)for(M=u3;M!==s3;M+=Z,S+=2)D=W[S+0]+(W[S+1]<<8),x[(M+a3*B)*4+0]=(D&31744)>>7,x[(M+a3*B)*4+1]=(D&992)>>2,x[(M+a3*B)*4+2]=(D&31)<<3,x[(M+a3*B)*4+3]=D&32768?0:255;return x}function J(x,o3,i3,Q,u3,Z,s3,W){let D=0,S,M;const B=G.width;for(M=o3;M!==Q;M+=i3)for(S=u3;S!==s3;S+=Z,D+=3)x[(S+B*M)*4+3]=255,x[(S+B*M)*4+2]=W[D+0],x[(S+B*M)*4+1]=W[D+1],x[(S+B*M)*4+0]=W[D+2];return x}function F(x,o3,i3,Q,u3,Z,s3,W){let D=0,S,M;const B=G.width;for(M=o3;M!==Q;M+=i3)for(S=u3;S!==s3;S+=Z,D+=4)x[(S+B*M)*4+2]=W[D+0],x[(S+B*M)*4+1]=W[D+1],x[(S+B*M)*4+0]=W[D+2],x[(S+B*M)*4+3]=W[D+3];return x}function X(x,o3,i3,Q,u3,Z,s3,W){let D,S=0,M,B;const a3=G.width;for(B=o3;B!==Q;B+=i3)for(M=u3;M!==s3;M+=Z,S++)D=W[S],x[(M+a3*B)*4+0]=D,x[(M+a3*B)*4+1]=D,x[(M+a3*B)*4+2]=D,x[(M+a3*B)*4+3]=255;return x}function l3(x,o3,i3,Q,u3,Z,s3,W){let D=0,S,M;const B=G.width;for(M=o3;M!==Q;M+=i3)for(S=u3;S!==s3;S+=Z,D+=2)x[(S+B*M)*4+0]=W[D+0],x[(S+B*M)*4+1]=W[D+0],x[(S+B*M)*4+2]=W[D+0],x[(S+B*M)*4+3]=W[D+1];return x}function d3(x,o3,i3,Q,u3){let Z,s3,W,D,S,M;switch((G.flags&p)>>f){default:case I:Z=0,W=1,S=o3,s3=0,D=1,M=i3;break;case L:Z=0,W=1,S=o3,s3=i3-1,D=-1,M=-1;break;case O:Z=o3-1,W=-1,S=-1,s3=0,D=1,M=i3;break;case g:Z=o3-1,W=-1,S=-1,s3=i3-1,D=-1,M=-1;break}if(Y)switch(G.pixel_size){case 8:X(x,s3,D,M,Z,W,S,Q);break;case 16:l3(x,s3,D,M,Z,W,S,Q);break;default:throw new Error("THREE.TGALoader: Format not supported.")}else switch(G.pixel_size){case 8:l(x,s3,D,M,Z,W,S,Q,u3);break;case 16:_(x,s3,D,M,Z,W,S,Q);break;case 24:J(x,s3,D,M,Z,W,S,Q);break;case 32:F(x,s3,D,M,Z,W,S,Q);break;default:throw new Error("THREE.TGALoader: Format not supported.")}return x}const h3=0,$=1,h=2,o=3,V=9,z=10,y=11,p=48,f=4,L=0,g=1,I=2,O=3;if(C.length<19)throw new Error("THREE.TGALoader: Not enough data to contain header.");let u=0;const b=new Uint8Array(C),G={id_length:b[u++],colormap_type:b[u++],image_type:b[u++],colormap_index:b[u++]|b[u++]<<8,colormap_length:b[u++]|b[u++]<<8,colormap_size:b[u++],origin:[b[u++]|b[u++]<<8,b[u++]|b[u++]<<8],width:b[u++]|b[u++]<<8,height:b[u++]|b[u++]<<8,pixel_size:b[u++],flags:b[u++]};if(P(G),G.id_length+u>C.length)throw new Error("THREE.TGALoader: No data.");u+=G.id_length;let U=!1,H=!1,Y=!1;switch(G.image_type){case V:U=!0,H=!0;break;case $:H=!0;break;case z:U=!0;break;case h:break;case y:U=!0,Y=!0;break;case o:Y=!0;break}const A3=new Uint8Array(G.width*G.height*4),g3=R(U,H,G,u,b);return d3(A3,G.width,G.height,g3.pixel_data,g3.palettes),{data:A3,width:G.width,height:G.height,flipY:!0,generateMipmaps:!0,minFilter:a.LinearMipmapLinearFilter}}}class m2 extends a.Loader{load(C,P,R,l){const _=this,J=_.path===""?a.LoaderUtils.extractUrlBase(C):_.path,F=new a.FileLoader(_.manager);F.setPath(_.path),F.setRequestHeader(_.requestHeader),F.setWithCredentials(_.withCredentials),F.load(C,function(X){try{P(_.parse(X,J))}catch(l3){l?l(l3):console.error(l3),_.manager.itemError(C)}},R,l)}parse(C,P){function R(t,e){const i=[],n=t.childNodes;for(let s=0,r=n.length;s<r;s++){const c=n[s];c.nodeName===e&&i.push(c)}return i}function l(t){if(t.length===0)return[];const e=t.trim().split(/\s+/),i=new Array(e.length);for(let n=0,s=e.length;n<s;n++)i[n]=e[n];return i}function _(t){if(t.length===0)return[];const e=t.trim().split(/\s+/),i=new Array(e.length);for(let n=0,s=e.length;n<s;n++)i[n]=parseFloat(e[n]);return i}function J(t){if(t.length===0)return[];const e=t.trim().split(/\s+/),i=new Array(e.length);for(let n=0,s=e.length;n<s;n++)i[n]=parseInt(e[n]);return i}function F(t){return t.substring(1)}function X(){return"three_default_"+d2++}function l3(t){return Object.keys(t).length===0}function d3(t){return{unit:h3(R(t,"unit")[0]),upAxis:$(R(t,"up_axis")[0])}}function h3(t){return t!==void 0&&t.hasAttribute("meter")===!0?parseFloat(t.getAttribute("meter")):1}function $(t){return t!==void 0?t.textContent:"Y_UP"}function h(t,e,i,n){const s=R(t,e)[0];if(s!==void 0){const r=R(s,i);for(let c=0;c<r.length;c++)n(r[c])}}function o(t,e){for(const i in t){const n=t[i];n.build=e(t[i])}}function V(t,e){return t.build!==void 0||(t.build=e(t)),t.build}function z(t){const e={sources:{},samplers:{},channels:{}};let i=!1;for(let n=0,s=t.childNodes.length;n<s;n++){const r=t.childNodes[n];if(r.nodeType!==1)continue;let c;switch(r.nodeName){case"source":c=r.getAttribute("id"),e.sources[c]=j3(r);break;case"sampler":c=r.getAttribute("id"),e.samplers[c]=y(r);break;case"channel":c=r.getAttribute("target"),e.channels[c]=p(r);break;case"animation":z(r),i=!0;break;default:console.log(r)}}i===!1&&(j.animations[t.getAttribute("id")||a.MathUtils.generateUUID()]=e)}function y(t){const e={inputs:{}};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"input":const r=F(s.getAttribute("source")),c=s.getAttribute("semantic");e.inputs[c]=r;break}}return e}function p(t){const e={};let n=t.getAttribute("target").split("/");const s=n.shift();let r=n.shift();const c=r.indexOf("(")!==-1,A=r.indexOf(".")!==-1;if(A)n=r.split("."),r=n.shift(),e.member=n.shift();else if(c){const m=r.split("(");r=m.shift();for(let w=0;w<m.length;w++)m[w]=parseInt(m[w].replace(/\)/,""));e.indices=m}return e.id=s,e.sid=r,e.arraySyntax=c,e.memberSyntax=A,e.sampler=F(t.getAttribute("source")),e}function f(t){const e=[],i=t.channels,n=t.samplers,s=t.sources;for(const r in i)if(i.hasOwnProperty(r)){const c=i[r],A=n[c.sampler],m=A.inputs.INPUT,w=A.inputs.OUTPUT,T=s[m],d=s[w],N=g(c,T,d);G(N,e)}return e}function L(t){return V(j.animations[t],f)}function g(t,e,i){const n=j.nodes[t.id],s=B3(n.id),r=n.transforms[t.sid],c=n.matrix.clone().transpose();let A,m,w,T,d,N;const k={};switch(r){case"matrix":for(w=0,T=e.array.length;w<T;w++)if(A=e.array[w],m=w*i.stride,k[A]===void 0&&(k[A]={}),t.arraySyntax===!0){const m3=i.array[m],c3=t.indices[0]+4*t.indices[1];k[A][c3]=m3}else for(d=0,N=i.stride;d<N;d++)k[A][d]=i.array[m+d];break;case"translate":console.warn('THREE.ColladaLoader: Animation transform type "%s" not yet implemented.',r);break;case"rotate":console.warn('THREE.ColladaLoader: Animation transform type "%s" not yet implemented.',r);break;case"scale":console.warn('THREE.ColladaLoader: Animation transform type "%s" not yet implemented.',r);break}const q=I(k,c);return{name:s.uuid,keyframes:q}}function I(t,e){const i=[];for(const s in t)i.push({time:parseFloat(s),value:t[s]});i.sort(n);for(let s=0;s<16;s++)U(i,s,e.elements[s]);return i;function n(s,r){return s.time-r.time}}const O=new a.Vector3,u=new a.Vector3,b=new a.Quaternion;function G(t,e){const i=t.keyframes,n=t.name,s=[],r=[],c=[],A=[];for(let m=0,w=i.length;m<w;m++){const T=i[m],d=T.time,N=T.value;_3.fromArray(N).transpose(),_3.decompose(O,b,u),s.push(d),r.push(O.x,O.y,O.z),c.push(b.x,b.y,b.z,b.w),A.push(u.x,u.y,u.z)}return r.length>0&&e.push(new a.VectorKeyframeTrack(n+".position",s,r)),c.length>0&&e.push(new a.QuaternionKeyframeTrack(n+".quaternion",s,c)),A.length>0&&e.push(new a.VectorKeyframeTrack(n+".scale",s,A)),e}function U(t,e,i){let n,s=!0,r,c;for(r=0,c=t.length;r<c;r++)n=t[r],n.value[e]===void 0?n.value[e]=null:s=!1;if(s===!0)for(r=0,c=t.length;r<c;r++)n=t[r],n.value[e]=i;else H(t,e)}function H(t,e){let i,n;for(let s=0,r=t.length;s<r;s++){const c=t[s];if(c.value[e]===null){if(i=Y(t,s,e),n=A3(t,s,e),i===null){c.value[e]=n.value[e];continue}if(n===null){c.value[e]=i.value[e];continue}g3(c,i,n,e)}}}function Y(t,e,i){for(;e>=0;){const n=t[e];if(n.value[i]!==null)return n;e--}return null}function A3(t,e,i){for(;e<t.length;){const n=t[e];if(n.value[i]!==null)return n;e++}return null}function g3(t,e,i,n){if(i.time-e.time===0){t.value[n]=e.value[n];return}t.value[n]=(t.time-e.time)*(i.value[n]-e.value[n])/(i.time-e.time)+e.value[n]}function x(t){const e={name:t.getAttribute("id")||"default",start:parseFloat(t.getAttribute("start")||0),end:parseFloat(t.getAttribute("end")||0),animations:[]};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"instance_animation":e.animations.push(F(s.getAttribute("url")));break}}j.clips[t.getAttribute("id")]=e}function o3(t){const e=[],i=t.name,n=t.end-t.start||-1,s=t.animations;for(let r=0,c=s.length;r<c;r++){const A=L(s[r]);for(let m=0,w=A.length;m<w;m++)e.push(A[m])}return new a.AnimationClip(i,n,e)}function i3(t){return V(j.clips[t],o3)}function Q(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"skin":e.id=F(s.getAttribute("source")),e.skin=u3(s);break;case"morph":e.id=F(s.getAttribute("source")),console.warn("THREE.ColladaLoader: Morph target animation not supported yet.");break}}j.controllers[t.getAttribute("id")]=e}function u3(t){const e={sources:{}};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"bind_shape_matrix":e.bindShapeMatrix=_(s.textContent);break;case"source":const r=s.getAttribute("id");e.sources[r]=j3(s);break;case"joints":e.joints=Z(s);break;case"vertex_weights":e.vertexWeights=s3(s);break}}return e}function Z(t){const e={inputs:{}};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"input":const r=s.getAttribute("semantic"),c=F(s.getAttribute("source"));e.inputs[r]=c;break}}return e}function s3(t){const e={inputs:{}};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"input":const r=s.getAttribute("semantic"),c=F(s.getAttribute("source")),A=parseInt(s.getAttribute("offset"));e.inputs[r]={id:c,offset:A};break;case"vcount":e.vcount=J(s.textContent);break;case"v":e.v=J(s.textContent);break}}return e}function W(t){const e={id:t.id},i=j.geometries[e.id];return t.skin!==void 0&&(e.skin=D(t.skin),i.sources.skinIndices=e.skin.indices,i.sources.skinWeights=e.skin.weights),e}function D(t){const i={joints:[],indices:{array:[],stride:4},weights:{array:[],stride:4}},n=t.sources,s=t.vertexWeights,r=s.vcount,c=s.v,A=s.inputs.JOINT.offset,m=s.inputs.WEIGHT.offset,w=t.sources[t.joints.inputs.JOINT],T=t.sources[t.joints.inputs.INV_BIND_MATRIX],d=n[s.inputs.WEIGHT.id].array;let N=0,k,q,E;for(k=0,E=r.length;k<E;k++){const c3=r[k],t3=[];for(q=0;q<c3;q++){const n3=c[N+A],H3=c[N+m],k3=d[H3];t3.push({index:n3,weight:k3}),N+=2}for(t3.sort(m3),q=0;q<4;q++){const n3=t3[q];n3!==void 0?(i.indices.array.push(n3.index),i.weights.array.push(n3.weight)):(i.indices.array.push(0),i.weights.array.push(0))}}for(t.bindShapeMatrix?i.bindMatrix=new a.Matrix4().fromArray(t.bindShapeMatrix).transpose():i.bindMatrix=new a.Matrix4().identity(),k=0,E=w.array.length;k<E;k++){const c3=w.array[k],t3=new a.Matrix4().fromArray(T.array,k*T.stride).transpose();i.joints.push({name:c3,boneInverse:t3})}return i;function m3(c3,t3){return t3.weight-c3.weight}}function S(t){return V(j.controllers[t],W)}function M(t){const e={init_from:R(t,"init_from")[0].textContent};j.images[t.getAttribute("id")]=e}function B(t){return t.build!==void 0?t.build:t.init_from}function a3(t){const e=j.images[t];return e!==void 0?V(e,B):(console.warn("THREE.ColladaLoader: Couldn't find image with ID:",t),null)}function v(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"profile_COMMON":e.profile=K(s);break}}j.effects[t.getAttribute("id")]=e}function K(t){const e={surfaces:{},samplers:{}};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"newparam":e3(s,e);break;case"technique":e.technique=r3(s);break;case"extra":e.extra=p3(s);break}}return e}function e3(t,e){const i=t.getAttribute("sid");for(let n=0,s=t.childNodes.length;n<s;n++){const r=t.childNodes[n];if(r.nodeType===1)switch(r.nodeName){case"surface":e.surfaces[i]=f3(r);break;case"sampler2D":e.samplers[i]=x3(r);break}}}function f3(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"init_from":e.init_from=s.textContent;break}}return e}function x3(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"source":e.source=s.textContent;break}}return e}function r3(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"constant":case"lambert":case"blinn":case"phong":e.type=s.nodeName,e.parameters=z3(s);break;case"extra":e.extra=p3(s);break}}return e}function z3(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"emission":case"diffuse":case"specular":case"bump":case"ambient":case"shininess":case"transparency":e[s.nodeName]=L3(s);break;case"transparent":e[s.nodeName]={opaque:s.hasAttribute("opaque")?s.getAttribute("opaque"):"A_ONE",data:L3(s)};break}}return e}function L3(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"color":e[s.nodeName]=_(s.textContent);break;case"float":e[s.nodeName]=parseFloat(s.textContent);break;case"texture":e[s.nodeName]={id:s.getAttribute("texture"),extra:b3(s)};break}}return e}function b3(t){const e={technique:{}};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"extra":M3(s,e);break}}return e}function M3(t,e){for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"technique":y3(s,e);break}}}function y3(t,e){for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"repeatU":case"repeatV":case"offsetU":case"offsetV":e.technique[s.nodeName]=parseFloat(s.textContent);break;case"wrapU":case"wrapV":s.textContent.toUpperCase()==="TRUE"?e.technique[s.nodeName]=1:s.textContent.toUpperCase()==="FALSE"?e.technique[s.nodeName]=0:e.technique[s.nodeName]=parseInt(s.textContent);break;case"bump":e[s.nodeName]=R3(s);break}}}function p3(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"technique":e.technique=N3(s);break}}return e}function N3(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"double_sided":e[s.nodeName]=parseInt(s.textContent);break;case"bump":e[s.nodeName]=R3(s);break}}return e}function R3(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"texture":e[s.nodeName]={id:s.getAttribute("texture"),texcoord:s.getAttribute("texcoord"),extra:b3(s)};break}}return e}function W3(t){return t}function y1(t){return V(j.effects[t],W3)}function w1(t){const e={name:t.getAttribute("name")};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"instance_effect":e.url=F(s.getAttribute("url"));break}}j.materials[t.getAttribute("id")]=e}function v1(t){let e,i=t.slice((t.lastIndexOf(".")-1>>>0)+2);switch(i=i.toLowerCase(),i){case"tga":e=P3;break;default:e=l1}return e}function J3(t){const e=y1(t.url),i=e.profile.technique;let n;switch(i.type){case"phong":case"blinn":n=new a.MeshPhongMaterial;break;case"lambert":n=new a.MeshLambertMaterial;break;default:n=new a.MeshBasicMaterial;break}n.name=t.name||"";function s(m,w=null){const T=e.profile.samplers[m.id];let d=null;if(T!==void 0){const N=e.profile.surfaces[T.source];d=a3(N.init_from)}else console.warn("THREE.ColladaLoader: Undefined sampler. Access image directly (see #12530)."),d=a3(m.id);if(d!==null){const N=v1(d);if(N!==void 0){const k=N.load(d),q=m.extra;if(q!==void 0&&q.technique!==void 0&&l3(q.technique)===!1){const E=q.technique;k.wrapS=E.wrapU?a.RepeatWrapping:a.ClampToEdgeWrapping,k.wrapT=E.wrapV?a.RepeatWrapping:a.ClampToEdgeWrapping,k.offset.set(E.offsetU||0,E.offsetV||0),k.repeat.set(E.repeatU||1,E.repeatV||1)}else k.wrapS=a.RepeatWrapping,k.wrapT=a.RepeatWrapping;return w!==null&&(k.colorSpace=w),k}else return console.warn("THREE.ColladaLoader: Loader for texture %s not found.",d),null}else return console.warn("THREE.ColladaLoader: Couldn't create texture with ID:",m.id),null}const r=i.parameters;for(const m in r){const w=r[m];switch(m){case"diffuse":w.color&&n.color.fromArray(w.color),w.texture&&(n.map=s(w.texture,a.SRGBColorSpace));break;case"specular":w.color&&n.specular&&n.specular.fromArray(w.color),w.texture&&(n.specularMap=s(w.texture));break;case"bump":w.texture&&(n.normalMap=s(w.texture));break;case"ambient":w.texture&&(n.lightMap=s(w.texture,a.SRGBColorSpace));break;case"shininess":w.float&&n.shininess&&(n.shininess=w.float);break;case"emission":w.color&&n.emissive&&n.emissive.fromArray(w.color),w.texture&&(n.emissiveMap=s(w.texture,a.SRGBColorSpace));break}}a.ColorManagement.colorSpaceToWorking(n.color,a.SRGBColorSpace),n.specular&&a.ColorManagement.colorSpaceToWorking(n.specular,a.SRGBColorSpace),n.emissive&&a.ColorManagement.colorSpaceToWorking(n.emissive,a.SRGBColorSpace);let c=r.transparent,A=r.transparency;if(A===void 0&&c&&(A={float:1}),c===void 0&&A&&(c={opaque:"A_ONE",data:{color:[1,1,1,1]}}),c&&A)if(c.data.texture)n.transparent=!0;else{const m=c.data.color;switch(c.opaque){case"A_ONE":n.opacity=m[3]*A.float;break;case"RGB_ZERO":n.opacity=1-m[0]*A.float;break;case"A_ZERO":n.opacity=1-m[3]*A.float;break;case"RGB_ONE":n.opacity=m[0]*A.float;break;default:console.warn('THREE.ColladaLoader: Invalid opaque type "%s" of transparent tag.',c.opaque)}n.opacity<1&&(n.transparent=!0)}if(i.extra!==void 0&&i.extra.technique!==void 0){const m=i.extra.technique;for(const w in m){const T=m[w];switch(w){case"double_sided":n.side=T===1?a.DoubleSide:a.FrontSide;break;case"bump":n.normalMap=s(T.texture),n.normalScale=new a.Vector2(1,1);break}}}return n}function z1(t){return V(j.materials[t],J3)}function M1(t){const e={name:t.getAttribute("name")};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"optics":e.optics=x1(s);break}}j.cameras[t.getAttribute("id")]=e}function x1(t){for(let e=0;e<t.childNodes.length;e++){const i=t.childNodes[e];switch(i.nodeName){case"technique_common":return A1(i)}}return{}}function A1(t){const e={};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];switch(n.nodeName){case"perspective":case"orthographic":e.technique=n.nodeName,e.parameters=L1(n);break}}return e}function L1(t){const e={};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];switch(n.nodeName){case"xfov":case"yfov":case"xmag":case"ymag":case"znear":case"zfar":case"aspect_ratio":e[n.nodeName]=parseFloat(n.textContent);break}}return e}function K3(t){let e;switch(t.optics.technique){case"perspective":e=new a.PerspectiveCamera(t.optics.parameters.yfov,t.optics.parameters.aspect_ratio,t.optics.parameters.znear,t.optics.parameters.zfar);break;case"orthographic":let i=t.optics.parameters.ymag,n=t.optics.parameters.xmag;const s=t.optics.parameters.aspect_ratio;n=n===void 0?i*s:n,i=i===void 0?n/s:i,n*=.5,i*=.5,e=new a.OrthographicCamera(-n,n,i,-i,t.optics.parameters.znear,t.optics.parameters.zfar);break;default:e=new a.PerspectiveCamera;break}return e.name=t.name||"",e}function k1(t){const e=j.cameras[t];return e!==void 0?V(e,K3):(console.warn("THREE.ColladaLoader: Couldn't find camera with ID:",t),null)}function _1(t){let e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"technique_common":e=N1(s);break}}j.lights[t.getAttribute("id")]=e}function N1(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"directional":case"point":case"spot":case"ambient":e.technique=s.nodeName,e.parameters=C1(s)}}return e}function C1(t){const e={};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"color":const r=_(s.textContent);e.color=new a.Color().fromArray(r),a.ColorManagement.colorSpaceToWorking(e.color,a.SRGBColorSpace);break;case"falloff_angle":e.falloffAngle=parseFloat(s.textContent);break;case"quadratic_attenuation":const c=parseFloat(s.textContent);e.distance=c?Math.sqrt(1/c):0;break}}return e}function Y3(t){let e;switch(t.technique){case"directional":e=new a.DirectionalLight;break;case"point":e=new a.PointLight;break;case"spot":e=new a.SpotLight;break;case"ambient":e=new a.AmbientLight;break}return t.parameters.color&&e.color.copy(t.parameters.color),t.parameters.distance&&(e.distance=t.parameters.distance),e}function T1(t){const e=j.lights[t];return e!==void 0?V(e,Y3):(console.warn("THREE.ColladaLoader: Couldn't find light with ID:",t),null)}function H1(t){const e={name:t.getAttribute("name"),sources:{},vertices:{},primitives:[]},i=R(t,"mesh")[0];if(i!==void 0){for(let n=0;n<i.childNodes.length;n++){const s=i.childNodes[n];if(s.nodeType!==1)continue;const r=s.getAttribute("id");switch(s.nodeName){case"source":e.sources[r]=j3(s);break;case"vertices":e.vertices=E1(s);break;case"polygons":console.warn("THREE.ColladaLoader: Unsupported primitive type: ",s.nodeName);break;case"lines":case"linestrips":case"polylist":case"triangles":e.primitives.push(B1(s));break;default:console.log(s)}}j.geometries[t.getAttribute("id")]=e}}function j3(t){const e={array:[],stride:3};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"float_array":e.array=_(n.textContent);break;case"Name_array":e.array=l(n.textContent);break;case"technique_common":const s=R(n,"accessor")[0];s!==void 0&&(e.stride=parseInt(s.getAttribute("stride")));break}}return e}function E1(t){const e={};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];n.nodeType===1&&(e[n.getAttribute("semantic")]=F(n.getAttribute("source")))}return e}function B1(t){const e={type:t.nodeName,material:t.getAttribute("material"),count:parseInt(t.getAttribute("count")),inputs:{},stride:0,hasUV:!1};for(let i=0,n=t.childNodes.length;i<n;i++){const s=t.childNodes[i];if(s.nodeType===1)switch(s.nodeName){case"input":const r=F(s.getAttribute("source")),c=s.getAttribute("semantic"),A=parseInt(s.getAttribute("offset")),m=parseInt(s.getAttribute("set")),w=m>0?c+m:c;e.inputs[w]={id:r,offset:A},e.stride=Math.max(e.stride,A+1),c==="TEXCOORD"&&(e.hasUV=!0);break;case"vcount":e.vcount=J(s.textContent);break;case"p":e.p=J(s.textContent);break}}return e}function V1(t){const e={};for(let i=0;i<t.length;i++){const n=t[i];e[n.type]===void 0&&(e[n.type]=[]),e[n.type].push(n)}return e}function S1(t){let e=0;for(let i=0,n=t.length;i<n;i++)t[i].hasUV===!0&&e++;e>0&&e<t.length&&(t.uvsNeedsFix=!0)}function X3(t){const e={},i=t.sources,n=t.vertices,s=t.primitives;if(s.length===0)return{};const r=V1(s);for(const c in r){const A=r[c];S1(A),e[c]=q1(A,i,n)}return e}function q1(t,e,i){const n={},s={array:[],stride:0},r={array:[],stride:0},c={array:[],stride:0},A={array:[],stride:0},m={array:[],stride:0},w={array:[],stride:4},T={array:[],stride:4},d=new a.BufferGeometry,N=[];let k=0;for(let q=0;q<t.length;q++){const E=t[q],m3=E.inputs;let c3=0;switch(E.type){case"lines":case"linestrips":c3=E.count*2;break;case"triangles":c3=E.count*3;break;case"polylist":for(let t3=0;t3<E.count;t3++){const n3=E.vcount[t3];switch(n3){case 3:c3+=3;break;case 4:c3+=6;break;default:c3+=(n3-2)*3;break}}break;default:console.warn("THREE.ColladaLoader: Unknown primitive type:",E.type)}d.addGroup(k,c3,q),k+=c3,E.material&&N.push(E.material);for(const t3 in m3){const n3=m3[t3];switch(t3){case"VERTEX":for(const H3 in i){const k3=i[H3];switch(H3){case"POSITION":const V3=s.array.length;if(C3(E,e[k3],n3.offset,s.array),s.stride=e[k3].stride,e.skinWeights&&e.skinIndices&&(C3(E,e.skinIndices,n3.offset,w.array),C3(E,e.skinWeights,n3.offset,T.array)),E.hasUV===!1&&t.uvsNeedsFix===!0){const h2=(s.array.length-V3)/s.stride;for(let h1=0;h1<h2;h1++)c.array.push(0,0)}break;case"NORMAL":C3(E,e[k3],n3.offset,r.array),r.stride=e[k3].stride;break;case"COLOR":C3(E,e[k3],n3.offset,m.array),m.stride=e[k3].stride;break;case"TEXCOORD":C3(E,e[k3],n3.offset,c.array),c.stride=e[k3].stride;break;case"TEXCOORD1":C3(E,e[k3],n3.offset,A.array),c.stride=e[k3].stride;break;default:console.warn('THREE.ColladaLoader: Semantic "%s" not handled in geometry build process.',H3)}}break;case"NORMAL":C3(E,e[n3.id],n3.offset,r.array),r.stride=e[n3.id].stride;break;case"COLOR":C3(E,e[n3.id],n3.offset,m.array,!0),m.stride=e[n3.id].stride;break;case"TEXCOORD":C3(E,e[n3.id],n3.offset,c.array),c.stride=e[n3.id].stride;break;case"TEXCOORD1":C3(E,e[n3.id],n3.offset,A.array),A.stride=e[n3.id].stride;break}}}return s.array.length>0&&d.setAttribute("position",new a.Float32BufferAttribute(s.array,s.stride)),r.array.length>0&&d.setAttribute("normal",new a.Float32BufferAttribute(r.array,r.stride)),m.array.length>0&&d.setAttribute("color",new a.Float32BufferAttribute(m.array,m.stride)),c.array.length>0&&d.setAttribute("uv",new a.Float32BufferAttribute(c.array,c.stride)),A.array.length>0&&d.setAttribute("uv1",new a.Float32BufferAttribute(A.array,A.stride)),w.array.length>0&&d.setAttribute("skinIndex",new a.Float32BufferAttribute(w.array,w.stride)),T.array.length>0&&d.setAttribute("skinWeight",new a.Float32BufferAttribute(T.array,T.stride)),n.data=d,n.type=t[0].type,n.materialKeys=N,n}function C3(t,e,i,n,s=!1){const r=t.p,c=t.stride,A=t.vcount;function m(d){let N=r[d+i]*T;const k=N+T;for(;N<k;N++)n.push(w[N]);if(s){const q=n.length-T-1;F3.setRGB(n[q+0],n[q+1],n[q+2],a.SRGBColorSpace),n[q+0]=F3.r,n[q+1]=F3.g,n[q+2]=F3.b}}const w=e.array,T=e.stride;if(t.vcount!==void 0){let d=0;for(let N=0,k=A.length;N<k;N++){const q=A[N];if(q===4){const E=d+c*0,m3=d+c*1,c3=d+c*2,t3=d+c*3;m(E),m(m3),m(t3),m(m3),m(c3),m(t3)}else if(q===3){const E=d+c*0,m3=d+c*1,c3=d+c*2;m(E),m(m3),m(c3)}else if(q>4)for(let E=1,m3=q-2;E<=m3;E++){const c3=d+c*0,t3=d+c*E,n3=d+c*(E+1);m(c3),m(t3),m(n3)}d+=c*q}}else for(let d=0,N=r.length;d<N;d+=c)m(d)}function Z3(t){return V(j.geometries[t],X3)}function R1(t){const e={name:t.getAttribute("name")||"",joints:{},links:[]};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"technique_common":O1(n,e);break}}j.kinematicsModels[t.getAttribute("id")]=e}function F1(t){return t.build!==void 0?t.build:t}function I1(t){return V(j.kinematicsModels[t],F1)}function O1(t,e){for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"joint":e.joints[n.getAttribute("sid")]=U1(n);break;case"link":e.links.push(Q3(n));break}}}function U1(t){let e;for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"prismatic":case"revolute":e=j1(n);break}}return e}function j1(t){const e={sid:t.getAttribute("sid"),name:t.getAttribute("name")||"",axis:new a.Vector3,limits:{min:0,max:0},type:t.nodeName,static:!1,zeroPosition:0,middlePosition:0};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"axis":const s=_(n.textContent);e.axis.fromArray(s);break;case"limits":const r=n.getElementsByTagName("max")[0],c=n.getElementsByTagName("min")[0];e.limits.max=parseFloat(r.textContent),e.limits.min=parseFloat(c.textContent);break}}return e.limits.min>=e.limits.max&&(e.static=!0),e.middlePosition=(e.limits.min+e.limits.max)/2,e}function Q3(t){const e={sid:t.getAttribute("sid"),name:t.getAttribute("name")||"",attachments:[],transforms:[]};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"attachment_full":e.attachments.push(D1(n));break;case"matrix":case"translate":case"rotate":e.transforms.push(e1(n));break}}return e}function D1(t){const e={joint:t.getAttribute("joint").split("/").pop(),transforms:[],links:[]};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"link":e.links.push(Q3(n));break;case"matrix":case"translate":case"rotate":e.transforms.push(e1(n));break}}return e}function e1(t){const e={type:t.nodeName},i=_(t.textContent);switch(e.type){case"matrix":e.obj=new a.Matrix4,e.obj.fromArray(i).transpose();break;case"translate":e.obj=new a.Vector3,e.obj.fromArray(i);break;case"rotate":e.obj=new a.Vector3,e.obj.fromArray(i),e.angle=a.MathUtils.degToRad(i[3]);break}return e}function G1(t){const e={name:t.getAttribute("name")||"",rigidBodies:{}};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"rigid_body":e.rigidBodies[n.getAttribute("name")]={},P1(n,e.rigidBodies[n.getAttribute("name")]);break}}j.physicsModels[t.getAttribute("id")]=e}function P1(t,e){for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"technique_common":$1(n,e);break}}}function $1(t,e){for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"inertia":e.inertia=_(n.textContent);break;case"mass":e.mass=_(n.textContent)[0];break}}}function W1(t){const e={bindJointAxis:[]};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"bind_joint_axis":e.bindJointAxis.push(J1(n));break}}j.kinematicsScenes[F(t.getAttribute("url"))]=e}function J1(t){const e={target:t.getAttribute("target").split("/").pop()};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType===1)switch(n.nodeName){case"axis":const s=n.getElementsByTagName("param")[0];e.axis=s.textContent;const r=e.axis.split("inst_").pop().split("axis")[0];e.jointIndex=r.substring(0,r.length-1);break}}return e}function K1(t){return t.build!==void 0?t.build:t}function Y1(t){return V(j.kinematicsScenes[t],K1)}function X1(){const t=Object.keys(j.kinematicsModels)[0],e=Object.keys(j.kinematicsScenes)[0],i=Object.keys(j.visualScenes)[0];if(t===void 0||e===void 0)return;const n=I1(t),s=Y1(e),r=o1(i),c=s.bindJointAxis,A={};for(let T=0,d=c.length;T<d;T++){const N=c[T],k=w3.querySelector('[sid="'+N.target+'"]');if(k){const q=k.parentElement;m(N.jointIndex,q)}}function m(T,d){const N=d.getAttribute("name"),k=n.joints[T];r.traverse(function(q){q.name===N&&(A[T]={object:q,transforms:Z1(d),joint:k,position:k.zeroPosition})})}const w=new a.Matrix4;d1={joints:n&&n.joints,getJointValue:function(T){const d=A[T];if(d)return d.position;console.warn("THREE.ColladaLoader: Joint "+T+" doesn't exist.")},setJointValue:function(T,d){const N=A[T];if(N){const k=N.joint;if(d>k.limits.max||d<k.limits.min)console.warn("THREE.ColladaLoader: Joint "+T+" value "+d+" outside of limits (min: "+k.limits.min+", max: "+k.limits.max+").");else if(k.static)console.warn("THREE.ColladaLoader: Joint "+T+" is static.");else{const q=N.object,E=k.axis,m3=N.transforms;_3.identity();for(let c3=0;c3<m3.length;c3++){const t3=m3[c3];if(t3.sid&&t3.sid.indexOf(T)!==-1)switch(k.type){case"revolute":_3.multiply(w.makeRotationAxis(E,a.MathUtils.degToRad(d)));break;case"prismatic":_3.multiply(w.makeTranslation(E.x*d,E.y*d,E.z*d));break;default:console.warn("THREE.ColladaLoader: Unknown joint type: "+k.type);break}else switch(t3.type){case"matrix":_3.multiply(t3.obj);break;case"translate":_3.multiply(w.makeTranslation(t3.obj.x,t3.obj.y,t3.obj.z));break;case"scale":_3.scale(t3.obj);break;case"rotate":_3.multiply(w.makeRotationAxis(t3.obj,t3.angle));break}}q.matrix.copy(_3),q.matrix.decompose(q.position,q.quaternion,q.scale),A[T].position=d}}else console.log("THREE.ColladaLoader: "+T+" does not exist.")}}}function Z1(t){const e=[],i=w3.querySelector('[id="'+t.id+'"]');for(let n=0;n<i.childNodes.length;n++){const s=i.childNodes[n];if(s.nodeType!==1)continue;let r,c;switch(s.nodeName){case"matrix":r=_(s.textContent);const A=new a.Matrix4().fromArray(r).transpose();e.push({sid:s.getAttribute("sid"),type:s.nodeName,obj:A});break;case"translate":case"scale":r=_(s.textContent),c=new a.Vector3().fromArray(r),e.push({sid:s.getAttribute("sid"),type:s.nodeName,obj:c});break;case"rotate":r=_(s.textContent),c=new a.Vector3().fromArray(r);const m=a.MathUtils.degToRad(r[3]);e.push({sid:s.getAttribute("sid"),type:s.nodeName,obj:c,angle:m});break}}return e}function Q1(t){const e=t.getElementsByTagName("node");for(let i=0;i<e.length;i++){const n=e[i];n.hasAttribute("id")===!1&&n.setAttribute("id",X())}}const _3=new a.Matrix4,E3=new a.Vector3;function D3(t){const e={name:t.getAttribute("name")||"",type:t.getAttribute("type"),id:t.getAttribute("id"),sid:t.getAttribute("sid"),matrix:new a.Matrix4,nodes:[],instanceCameras:[],instanceControllers:[],instanceLights:[],instanceGeometries:[],instanceNodes:[],transforms:{}};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];if(n.nodeType!==1)continue;let s;switch(n.nodeName){case"node":e.nodes.push(n.getAttribute("id")),D3(n);break;case"instance_camera":e.instanceCameras.push(F(n.getAttribute("url")));break;case"instance_controller":e.instanceControllers.push(t1(n));break;case"instance_light":e.instanceLights.push(F(n.getAttribute("url")));break;case"instance_geometry":e.instanceGeometries.push(t1(n));break;case"instance_node":e.instanceNodes.push(F(n.getAttribute("url")));break;case"matrix":s=_(n.textContent),e.matrix.multiply(_3.fromArray(s).transpose()),e.transforms[n.getAttribute("sid")]=n.nodeName;break;case"translate":s=_(n.textContent),E3.fromArray(s),e.matrix.multiply(_3.makeTranslation(E3.x,E3.y,E3.z)),e.transforms[n.getAttribute("sid")]=n.nodeName;break;case"rotate":s=_(n.textContent);const r=a.MathUtils.degToRad(s[3]);e.matrix.multiply(_3.makeRotationAxis(E3.fromArray(s),r)),e.transforms[n.getAttribute("sid")]=n.nodeName;break;case"scale":s=_(n.textContent),e.matrix.scale(E3.fromArray(s)),e.transforms[n.getAttribute("sid")]=n.nodeName;break;case"extra":break;default:console.log(n)}}return s1(e.id)?console.warn("THREE.ColladaLoader: There is already a node with ID %s. Exclude current node from further processing.",e.id):j.nodes[e.id]=e,e}function t1(t){const e={id:F(t.getAttribute("url")),materials:{},skeletons:[]};for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];switch(n.nodeName){case"bind_material":const s=n.getElementsByTagName("instance_material");for(let r=0;r<s.length;r++){const c=s[r],A=c.getAttribute("symbol"),m=c.getAttribute("target");e.materials[A]=F(m)}break;case"skeleton":e.skeletons.push(F(n.textContent));break}}return e}function e2(t,e){const i=[],n=[];let s,r,c;for(s=0;s<t.length;s++){const w=t[s];let T;if(s1(w))T=B3(w),n1(T,e,i);else if(a2(w)){const N=j.visualScenes[w].children;for(let k=0;k<N.length;k++){const q=N[k];if(q.type==="JOINT"){const E=B3(q.id);n1(E,e,i)}}}else console.error("THREE.ColladaLoader: Unable to find root bone of skeleton with ID:",w)}for(s=0;s<e.length;s++)for(r=0;r<i.length;r++)if(c=i[r],c.bone.name===e[s].name){n[s]=c,c.processed=!0;break}for(s=0;s<i.length;s++)c=i[s],c.processed===!1&&(n.push(c),c.processed=!0);const A=[],m=[];for(s=0;s<n.length;s++)c=n[s],A.push(c.bone),m.push(c.boneInverse);return new a.Skeleton(A,m)}function n1(t,e,i){t.traverse(function(n){if(n.isBone===!0){let s;for(let r=0;r<e.length;r++){const c=e[r];if(c.name===n.name){s=c.boneInverse;break}}s===void 0&&(s=new a.Matrix4),i.push({bone:n,boneInverse:s,processed:!1})}})}function t2(t){const e=[],i=t.matrix,n=t.nodes,s=t.type,r=t.instanceCameras,c=t.instanceControllers,A=t.instanceLights,m=t.instanceGeometries,w=t.instanceNodes;for(let d=0,N=n.length;d<N;d++)e.push(B3(n[d]));for(let d=0,N=r.length;d<N;d++){const k=k1(r[d]);k!==null&&e.push(k.clone())}for(let d=0,N=c.length;d<N;d++){const k=c[d],q=S(k.id),E=Z3(q.id),m3=i1(E,k.materials),c3=k.skeletons,t3=q.skin.joints,n3=e2(c3,t3);for(let H3=0,k3=m3.length;H3<k3;H3++){const V3=m3[H3];V3.isSkinnedMesh&&(V3.bind(n3,q.skin.bindMatrix),V3.normalizeSkinWeights()),e.push(V3)}}for(let d=0,N=A.length;d<N;d++){const k=T1(A[d]);k!==null&&e.push(k.clone())}for(let d=0,N=m.length;d<N;d++){const k=m[d],q=Z3(k.id),E=i1(q,k.materials);for(let m3=0,c3=E.length;m3<c3;m3++)e.push(E[m3])}for(let d=0,N=w.length;d<N;d++)e.push(B3(w[d]).clone());let T;if(n.length===0&&e.length===1)T=e[0];else{T=s==="JOINT"?new a.Bone:new a.Group;for(let d=0;d<e.length;d++)T.add(e[d])}return T.name=s==="JOINT"?t.sid:t.name,T.matrix.copy(i),T.matrix.decompose(T.position,T.quaternion,T.scale),T}const n2=new a.MeshBasicMaterial({name:a.Loader.DEFAULT_MATERIAL_NAME,color:16711935});function i2(t,e){const i=[];for(let n=0,s=t.length;n<s;n++){const r=e[t[n]];r===void 0?(console.warn("THREE.ColladaLoader: Material with key %s not found. Apply fallback material.",t[n]),i.push(n2)):i.push(z1(r))}return i}function i1(t,e){const i=[];for(const n in t){const s=t[n],r=i2(s.materialKeys,e);if(r.length===0&&(n==="lines"||n==="linestrips"?r.push(new a.LineBasicMaterial):r.push(new a.MeshPhongMaterial)),n==="lines"||n==="linestrips")for(let w=0,T=r.length;w<T;w++){const d=r[w];if(d.isMeshPhongMaterial===!0||d.isMeshLambertMaterial===!0){const N=new a.LineBasicMaterial;N.color.copy(d.color),N.opacity=d.opacity,N.transparent=d.transparent,r[w]=N}}const c=s.data.attributes.skinIndex!==void 0,A=r.length===1?r[0]:r;let m;switch(n){case"lines":m=new a.LineSegments(s.data,A);break;case"linestrips":m=new a.Line(s.data,A);break;case"triangles":case"polylist":c?m=new a.SkinnedMesh(s.data,A):m=new a.Mesh(s.data,A);break}i.push(m)}return i}function s1(t){return j.nodes[t]!==void 0}function B3(t){return V(j.nodes[t],t2)}function s2(t){const e={name:t.getAttribute("name"),children:[]};Q1(t);const i=R(t,"node");for(let n=0;n<i.length;n++)e.children.push(D3(i[n]));j.visualScenes[t.getAttribute("id")]=e}function a1(t){const e=new a.Group;e.name=t.name;const i=t.children;for(let n=0;n<i.length;n++){const s=i[n];e.add(B3(s.id))}return e}function a2(t){return j.visualScenes[t]!==void 0}function o1(t){return V(j.visualScenes[t],a1)}function o2(t){const e=R(t,"instance_visual_scene")[0];return o1(F(e.getAttribute("url")))}function r2(){const t=j.clips;if(l3(t)===!0){if(l3(j.animations)===!1){const e=[];for(const i in j.animations){const n=L(i);for(let s=0,r=n.length;s<r;s++)e.push(n[s])}I3.push(new a.AnimationClip("default",-1,e))}}else for(const e in t)I3.push(i3(e))}function c2(t){let e="";const i=[t];for(;i.length;){const n=i.shift();n.nodeType===Node.TEXT_NODE?e+=n.textContent:(e+=`
|
|
2
2
|
`,i.push(...n.childNodes))}return e.trim()}if(C.length===0)return{scene:new a.Scene};const r1=new DOMParser().parseFromString(C,"application/xml"),w3=R(r1,"COLLADA")[0],G3=r1.getElementsByTagName("parsererror")[0];if(G3!==void 0){const t=R(G3,"div")[0];let e;return t?e=t.textContent:e=c2(G3),console.error(`THREE.ColladaLoader: Failed to parse collada file.
|
|
3
3
|
`,e),null}const l2=w3.getAttribute("version");console.debug("THREE.ColladaLoader: File version",l2);const c1=d3(R(w3,"asset")[0]),l1=new a.TextureLoader(this.manager);l1.setPath(this.resourcePath||P).setCrossOrigin(this.crossOrigin);let P3;u1&&(P3=new u1(this.manager),P3.setPath(this.resourcePath||P));const F3=new a.Color,I3=[];let d1={},d2=0;const j={animations:{},clips:{},controllers:{},images:{},effects:{},materials:{},cameras:{},lights:{},geometries:{},nodes:{},visualScenes:{},kinematicsModels:{},physicsModels:{},kinematicsScenes:{}};h(w3,"library_animations","animation",z),h(w3,"library_animation_clips","animation_clip",x),h(w3,"library_controllers","controller",Q),h(w3,"library_images","image",M),h(w3,"library_effects","effect",v),h(w3,"library_materials","material",w1),h(w3,"library_cameras","camera",M1),h(w3,"library_lights","light",_1),h(w3,"library_geometries","geometry",H1),h(w3,"library_nodes","node",D3),h(w3,"library_visual_scenes","visual_scene",s2),h(w3,"library_kinematics_models","kinematics_model",R1),h(w3,"library_physics_models","physics_model",G1),h(w3,"scene","instance_kinematics_scene",W1),o(j.animations,f),o(j.clips,o3),o(j.controllers,W),o(j.images,B),o(j.effects,W3),o(j.materials,J3),o(j.cameras,K3),o(j.lights,Y3),o(j.geometries,X3),o(j.visualScenes,a1),r2(),X1();const O3=o2(R(w3,"scene")[0]);return O3.animations=I3,c1.upAxis==="Z_UP"&&(console.warn("THREE.ColladaLoader: You are loading an asset with a Z-UP coordinate system. The loader just rotates the asset to transform it into Y-UP. The vertex data are not converted, see #24289."),O3.rotation.set(-Math.PI/2,0,0)),O3.scale.multiplyScalar(c1.unit),{get animations(){return console.warn("THREE.ColladaLoader: Please access animations over scene.animations now."),I3},kinematics:d1,library:j,scene:O3}}}const $3=new a.Quaternion,f1=new a.Euler;function S3(v3){return v3?v3.trim().split(/\s+/g).map(C=>parseFloat(C)):[0,0,0]}function p1(v3,C,P=!1){P||v3.rotation.set(0,0,0),f1.set(C[0],C[1],C[2],"ZYX"),$3.setFromEuler(f1),$3.multiply(v3.quaternion),v3.quaternion.copy($3)}class g1{constructor(C){this.manager=C||a.DefaultLoadingManager,this.loadMeshCb=this.defaultMeshLoader.bind(this),this.parseVisual=!0,this.parseCollision=!1,this.packages="",this.workingPath="",this.fetchOptions={}}loadAsync(C){return new Promise((P,R)=>{this.load(C,P,null,R)})}load(C,P,R,l){const _=this.manager,J=a.LoaderUtils.extractUrlBase(C),F=this.manager.resolveURL(C);_.itemStart(F),fetch(F,this.fetchOptions).then(X=>{if(X.ok)return R&&R(null),X.text();throw new Error(`URDFLoader: Failed to load url '${F}' with error code ${X.status} : ${X.statusText}.`)}).then(X=>{const l3=this.parse(X,this.workingPath||J);P(l3),_.itemEnd(F)}).catch(X=>{l?l(X):console.error("URDFLoader: Error loading file.",X),_.itemError(F),_.itemEnd(F)})}parse(C,P=this.workingPath){const R=this.packages,l=this.loadMeshCb,_=this.parseVisual,J=this.parseCollision,F=this.manager,X={},l3={},d3={};function h3(p){if(!/^package:\/\//.test(p))return P?P+p:p;const[f,L]=p.replace(/^package:\/\//,"").split(/\/(.+)/);if(typeof R=="string")return R.endsWith(f)?R+"/"+L:R+"/"+f+"/"+L;if(R instanceof Function)return R(f)+"/"+L;if(typeof R=="object")return f in R?R[f]+"/"+L:(console.error(`URDFLoader : ${f} not found in provided package list.`),null)}function $(p){let f;p instanceof Document?f=[...p.children]:p instanceof Element?f=[p]:f=[...new DOMParser().parseFromString(p,"text/xml").children];const L=f.filter(g=>g.nodeName==="robot").pop();return h(L)}function h(p){const f=[...p.children],L=f.filter(U=>U.nodeName.toLowerCase()==="link"),g=f.filter(U=>U.nodeName.toLowerCase()==="joint"),I=f.filter(U=>U.nodeName.toLowerCase()==="material"),O=new a.URDFRobot;O.robotName=p.getAttribute("name"),O.urdfRobotNode=p,I.forEach(U=>{const H=U.getAttribute("name");d3[H]=z(U)});const u={},b={};L.forEach(U=>{const H=U.getAttribute("name"),Y=p.querySelector(`child[link="${H}"]`)===null;X[H]=V(U,u,b,Y?O:null)}),g.forEach(U=>{const H=U.getAttribute("name");l3[H]=o(U)}),O.joints=l3,O.links=X,O.colliders=b,O.visual=u;const G=Object.values(l3);return G.forEach(U=>{U instanceof a.URDFMimicJoint&&l3[U.mimicJoint].mimicJoints.push(U)}),G.forEach(U=>{const H=new Set,Y=A3=>{if(H.has(A3))throw new Error("URDFLoader: Detected an infinite loop of mimic joints.");H.add(A3),A3.mimicJoints.forEach(g3=>{Y(g3)})};Y(U)}),O.frames={...b,...u,...X,...l3},O}function o(p){const f=[...p.children],L=p.getAttribute("type");let g;const I=f.find(H=>H.nodeName.toLowerCase()==="mimic");I?(g=new a.URDFMimicJoint,g.mimicJoint=I.getAttribute("joint"),g.multiplier=parseFloat(I.getAttribute("multiplier")||1),g.offset=parseFloat(I.getAttribute("offset")||0)):g=new a.URDFJoint,g.urdfNode=p,g.name=p.getAttribute("name"),g.urdfName=g.name,g.jointType=L;let O=null,u=null,b=[0,0,0],G=[0,0,0];f.forEach(H=>{const Y=H.nodeName.toLowerCase();Y==="origin"?(b=S3(H.getAttribute("xyz")),G=S3(H.getAttribute("rpy"))):Y==="child"?u=X[H.getAttribute("link")]:Y==="parent"?O=X[H.getAttribute("link")]:Y==="limit"&&(g.limit.lower=parseFloat(H.getAttribute("lower")||g.limit.lower),g.limit.upper=parseFloat(H.getAttribute("upper")||g.limit.upper))}),O.add(g),g.add(u),p1(g,G),g.position.set(b[0],b[1],b[2]);const U=f.filter(H=>H.nodeName.toLowerCase()==="axis")[0];if(U){const H=U.getAttribute("xyz").split(/\s+/g).map(Y=>parseFloat(Y));g.axis=new a.Vector3(H[0],H[1],H[2]),g.axis.normalize()}return g}function V(p,f,L,g=null){g===null&&(g=new a.URDFLink);const I=[...p.children];return g.name=p.getAttribute("name"),g.urdfName=g.name,g.urdfNode=p,_&&I.filter(u=>u.nodeName.toLowerCase()==="visual").forEach(u=>{const b=y(u,d3);if(g.add(b),u.hasAttribute("name")){const G=u.getAttribute("name");b.name=G,b.urdfName=G,f[G]=b}}),J&&I.filter(u=>u.nodeName.toLowerCase()==="collision").forEach(u=>{const b=y(u);if(g.add(b),u.hasAttribute("name")){const G=u.getAttribute("name");b.name=G,b.urdfName=G,L[G]=b}}),g}function z(p){const f=[...p.children],L=new a.MeshPhongMaterial;return L.name=p.getAttribute("name")||"",f.forEach(g=>{const I=g.nodeName.toLowerCase();if(I==="color"){const O=g.getAttribute("rgba").split(/\s/g).map(u=>parseFloat(u));L.color.setRGB(O[0],O[1],O[2]),L.opacity=O[3],L.transparent=O[3]<1,L.depthWrite=!L.transparent}else if(I==="texture"){const O=g.getAttribute("filename");if(O){const u=new a.TextureLoader(F),b=h3(O);L.map=u.load(b),L.map.colorSpace=a.SRGBColorSpace}}}),L}function y(p,f={}){const L=p.nodeName.toLowerCase()==="collision",g=[...p.children];let I=null;const O=g.filter(b=>b.nodeName.toLowerCase()==="material")[0];if(O){const b=O.getAttribute("name");b&&b in f?I=f[b]:I=z(O)}else I=new a.MeshPhongMaterial;const u=L?new a.URDFCollider:new a.URDFVisual;return u.urdfNode=p,g.forEach(b=>{const G=b.nodeName.toLowerCase();if(G==="geometry"){const U=b.children[0].nodeName.toLowerCase();if(U==="mesh"){const H=b.children[0].getAttribute("filename"),Y=h3(H);if(Y!==null){const A3=b.children[0].getAttribute("scale");if(A3){const g3=S3(A3);u.scale.set(g3[0],g3[1],g3[2])}l(Y,F,(g3,x)=>{x?console.error("URDFLoader: Error loading mesh.",x):g3&&(g3 instanceof a.Mesh&&(g3.material=I),g3.position.set(0,0,0),g3.quaternion.identity(),u.add(g3))})}}else if(U==="box"){const H=new a.Mesh;H.geometry=new a.BoxGeometry(1,1,1),H.material=I;const Y=S3(b.children[0].getAttribute("size"));H.scale.set(Y[0],Y[1],Y[2]),u.add(H)}else if(U==="sphere"){const H=new a.Mesh;H.geometry=new a.SphereGeometry(1,30,30),H.material=I;const Y=parseFloat(b.children[0].getAttribute("radius"))||0;H.scale.set(Y,Y,Y),u.add(H)}else if(U==="cylinder"){const H=new a.Mesh;H.geometry=new a.CylinderGeometry(1,1,1,30),H.material=I;const Y=parseFloat(b.children[0].getAttribute("radius"))||0,A3=parseFloat(b.children[0].getAttribute("length"))||0;H.scale.set(Y,A3,Y),H.rotation.set(Math.PI/2,0,0),u.add(H)}}else if(G==="origin"){const U=S3(b.getAttribute("xyz")),H=S3(b.getAttribute("rpy"));u.position.set(U[0],U[1],U[2]),u.rotation.set(0,0,0),p1(u,H)}}),u}return $(C)}defaultMeshLoader(C,P,R){/\.stl$/i.test(C)?new T3.STLLoader(P).load(C,_=>{const J=new a.Mesh(_,new a.MeshPhongMaterial);R(J)}):/\.dae$/i.test(C)?new m2(P).load(C,_=>R(_.scene)):console.warn(`URDFLoader: Could not load model at ${C}.
|
|
4
4
|
No loader available`)}}class b2 extends a.Loader{constructor(C){super(C),this.littleEndian=!0}load(C,P,R,l){const _=this,J=new a.FileLoader(_.manager);J.setPath(_.path),J.setResponseType("arraybuffer"),J.setRequestHeader(_.requestHeader),J.setWithCredentials(_.withCredentials),J.load(C,function(F){try{P(_.parse(F))}catch(X){l?l(X):console.error(X),_.manager.itemError(C)}},R,l)}_getDataView(C,P,R,l){switch(R){case"F":return l===8?C.getFloat64(P,this.littleEndian):C.getFloat32(P,this.littleEndian);case"I":return l===1?C.getInt8(P):l===2?C.getInt16(P,this.littleEndian):C.getInt32(P,this.littleEndian);case"U":return l===1?C.getUint8(P):l===2?C.getUint16(P,this.littleEndian):C.getUint32(P,this.littleEndian)}}parse(C){function P(h,o){const V=h.length,z=new Uint8Array(o);let y=0,p=0,f,L,g;do if(f=h[y++],f<32){if(f++,p+f>o)throw new Error("Output buffer is not large enough");if(y+f>V)throw new Error("Invalid compressed data");do z[p++]=h[y++];while(--f)}else{if(L=f>>5,g=p-((f&31)<<8)-1,y>=V)throw new Error("Invalid compressed data");if(L===7&&(L+=h[y++],y>=V))throw new Error("Invalid compressed data");if(g-=h[y++],p+L+2>o)throw new Error("Output buffer is not large enough");if(g<0)throw new Error("Invalid compressed data");if(g>=p)throw new Error("Invalid compressed data");do z[p++]=z[g++];while(--L+2)}while(y<V);return z}function R(h){const o={},V=new Uint8Array(h);let z="",y="",p=0,f=!1;const L=V.length;for(;p<L&&f===!1;){const u=String.fromCharCode(V[p++]);u===`
|