ss-component-new 1.1.522 → 1.1.523

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.
@@ -0,0 +1,1173 @@
1
+ import { resolveComponent as y, createBlock as T, openBlock as u, withCtx as n, createVNode as a, createElementVNode as f, toDisplayString as ae, ref as d, onMounted as gt, watch as U, createElementBlock as M, Fragment as we, renderList as Pe, createCommentVNode as N, normalizeStyle as vt, defineComponent as Je, computed as be, resolveDirective as We, withDirectives as Re, unref as o, createTextVNode as z, renderSlot as _e, vShow as Te, resolveDynamicComponent as Qe, nextTick as yt } from "vue";
2
+ import { m as De, a as je, b as Ve } from "./index-CIIEhoPK.js";
3
+ import Ye from "./index-DEe2zsga.js";
4
+ import { _ as Ct, o as Ze, c as et, a as tt, b as at, d as ot, s as te, g as nt, e as lt, f as it, h as st, i as wt, j as Bt } from "./index.vue_vue_type_style_index_0_scoped_b9caa997_lang-hmqNLVAu.js";
5
+ import { _ as ge } from "./_plugin-vue_export-helper-CHgC5LLL.js";
6
+ import { p as H, s as q, u as Ae, e as rt, c as Se, d as Ce, g as kt } from "./menu-C2j1i_cN.js";
7
+ import { u as ut } from "./crypto-CMXGCdQv.js";
8
+ import { S as fe } from "./index-BHtNKL1L.js";
9
+ import { u as $e } from "./threeModel.vue_vue_type_style_index_0_scoped_4a248817_lang-D9glQKd6.js";
10
+ import { u as Ne, a as Ft, l as ct, g as bt, b as Rt } from "./index-C2cfRaP7.js";
11
+ import { _ as dt, a as Tt, s as St } from "./index-CaZmDQQH.js";
12
+ import { _ as mt } from "./index.vue_vue_type_script_setup_true_lang-Bk3kThxx.js";
13
+ import qe from "./threeModel-CkbHdhYr.js";
14
+ import { u as At } from "./index-Dt0W4n11.js";
15
+ import { d as He } from "./index-CL2WV4Ur.js";
16
+ import "vue-router";
17
+ import { a as $t } from "./array-Ba5TFfWm.js";
18
+ import { c as Mt, b as xt } from "./index.vue_vue_type_style_index_0_scoped_ed9fe0f5_lang-B1zL6TmK.js";
19
+ function Pt(k, Y, e, C, S, E) {
20
+ const i = y("svg-icon"), I = y("ssMenu");
21
+ return u(), T(I, {
22
+ mode: k.mode,
23
+ menuList: k.renderMenuList,
24
+ onClickMenu: k.clickMenu,
25
+ onOpenMenu: k.openMenu,
26
+ onCloseMenu: k.closeMenu
27
+ }, {
28
+ title: n(({ menu: x }) => [
29
+ a(i, {
30
+ name: x.icon ?? "Fold",
31
+ style: { width: "clamp(16px, 1.25rem, 20px)", height: "clamp(16px, 1.25rem, 20px)", "margin-right": "8px" }
32
+ }, null, 8, ["name"]),
33
+ f("span", null, ae(x.title ?? ""), 1)
34
+ ]),
35
+ _: 1
36
+ }, 8, ["mode", "menuList", "onClickMenu", "onOpenMenu", "onCloseMenu"]);
37
+ }
38
+ const pt = /* @__PURE__ */ ge(Ct, [["render", Pt], ["__scopeId", "data-v-5c2d7ed2"]]), Dt = { class: "bread-content" }, jt = ["onClick"], Vt = {
39
+ key: 0,
40
+ class: "split-title"
41
+ }, Nt = {
42
+ __name: "index",
43
+ props: {
44
+ breadArray: {
45
+ type: Array,
46
+ default: () => []
47
+ }
48
+ },
49
+ emits: ["click"],
50
+ setup(k, { emit: Y }) {
51
+ const e = k, C = d([]), S = Y;
52
+ gt(() => {
53
+ C.value = e == null ? void 0 : e.breadArray;
54
+ }), U(
55
+ () => e == null ? void 0 : e.breadArray,
56
+ () => {
57
+ C.value = e == null ? void 0 : e.breadArray;
58
+ },
59
+ { deep: !0, immediate: !0 }
60
+ );
61
+ const E = (i) => {
62
+ S("click", i);
63
+ };
64
+ return (i, I) => (u(), M("div", Dt, [
65
+ (u(!0), M(we, null, Pe(C.value, (x, A) => {
66
+ var oe;
67
+ return u(), M("div", {
68
+ key: A,
69
+ class: "bread-item"
70
+ }, [
71
+ f("div", {
72
+ class: "bread-title",
73
+ onClick: (Z) => E(x),
74
+ style: vt({ opacity: ((oe = C.value) == null ? void 0 : oe.length) - 1 === A ? "0.7" : "1" })
75
+ }, ae(x.value), 13, jt),
76
+ A !== C.value.length - 1 && Array.isArray(C.value) ? (u(), M("div", Vt, ae("/"))) : N("", !0)
77
+ ]);
78
+ }), 128))
79
+ ]));
80
+ }
81
+ }, ht = /* @__PURE__ */ ge(Nt, [["__scopeId", "data-v-ded7e2bd"]]), Ut = { class: "structure-buttons" }, Et = { class: "structure-paths" }, It = { class: "client-header-user" }, Ot = { class: "model-select" }, Lt = { class: "model-show" }, Kt = { class: "model-fill" }, zt = { class: "client-header-menu" }, Gt = { class: "client-header-user" }, Xt = { class: "drop-menu" }, qt = { class: "client-main-operate" }, Ht = {
82
+ key: 0,
83
+ class: "item-view-group"
84
+ }, Jt = /* @__PURE__ */ Je({
85
+ __name: "index2",
86
+ props: {
87
+ windowConfig: {
88
+ type: Object,
89
+ default: () => {
90
+ }
91
+ },
92
+ showButton: {
93
+ type: Boolean,
94
+ default: !0
95
+ }
96
+ },
97
+ setup(k) {
98
+ const Y = Ne(H), { selectTitle: e } = q(Y), C = ut(), { loginUserInfo: S } = q(C), E = $e(H), { isEdit: i, routeToChildPath: I } = q(E), x = Ae(H), { importLoading: A, activeTopMenuPath: oe, activeAsideMenu: Z } = q(x), F = d(""), P = be(() => Z.value.isRouter), J = () => {
99
+ sessionStorage.clear(), window.location.reload();
100
+ }, W = () => {
101
+ x.setActiveMenuPath(I.value), E.setRouteToChildPath("");
102
+ };
103
+ return (G, c) => {
104
+ const R = y("el-button"), ve = y("el-avatar"), ce = y("el-header"), X = y("el-container"), Be = y("el-icon"), de = y("el-input"), me = y("ss-button"), h = y("el-aside"), D = y("router-view"), b = y("el-main"), $ = We("loading");
105
+ return u(), M(we, null, [
106
+ Re(a(X, { class: "client-container" }, {
107
+ default: n(() => [
108
+ a(ce, { class: "client-structure-header" }, {
109
+ default: n(() => {
110
+ var w;
111
+ return [
112
+ f("div", Ut, [
113
+ a(R, {
114
+ id: "transparentBgButton",
115
+ onClick: o(Ze)
116
+ }, {
117
+ default: n(() => c[2] || (c[2] = [
118
+ z(" 返回页面 ")
119
+ ])),
120
+ _: 1,
121
+ __: [2]
122
+ }, 8, ["onClick"]),
123
+ a(R, {
124
+ id: "transparentBgButton",
125
+ onClick: c[0] || (c[0] = (l) => {
126
+ var O, L;
127
+ return o(et)((L = (O = o(e)) == null ? void 0 : O.map((pe) => pe.value)) == null ? void 0 : L.join("/"));
128
+ })
129
+ }, {
130
+ icon: n(() => [
131
+ a(fe, { name: "Store" })
132
+ ]),
133
+ default: n(() => [
134
+ c[3] || (c[3] = z(" 保存页面 "))
135
+ ]),
136
+ _: 1,
137
+ __: [3]
138
+ })
139
+ ]),
140
+ f("div", Et, [
141
+ (u(), T(ht, {
142
+ key: o(e),
143
+ breadArray: o(e),
144
+ onClick: o(tt)
145
+ }, null, 8, ["breadArray", "onClick"]))
146
+ ]),
147
+ f("div", It, [
148
+ _e(G.$slots, "default", {}, void 0, !0),
149
+ a(ve, {
150
+ size: 35,
151
+ src: (w = o(S)) == null ? void 0 : w.avatarUrl
152
+ }, {
153
+ default: n(() => {
154
+ var l;
155
+ return [
156
+ z(ae(((l = o(S)) == null ? void 0 : l.account) ?? "未知"), 1)
157
+ ];
158
+ }),
159
+ _: 1
160
+ }, 8, ["src"])
161
+ ])
162
+ ];
163
+ }),
164
+ _: 3
165
+ }),
166
+ o(i) === "edit" ? (u(), T(X, {
167
+ key: 0,
168
+ class: "model-operate",
169
+ style: { "margin-top": "10px", height: "0px" }
170
+ }, {
171
+ default: n(() => [
172
+ f("div", Ot, [
173
+ a(De)
174
+ ]),
175
+ f("div", Lt, [
176
+ a(je)
177
+ ]),
178
+ f("div", Kt, [
179
+ a(Ve)
180
+ ])
181
+ ]),
182
+ _: 1
183
+ })) : N("", !0)
184
+ ]),
185
+ _: 3
186
+ }, 512), [
187
+ [Te, o(i) === "edit"]
188
+ ]),
189
+ Re((u(), T(X, {
190
+ class: "client-container",
191
+ "element-loading-text": "正在加载页面数据..."
192
+ }, {
193
+ default: n(() => [
194
+ a(ce, { class: "client-header" }, {
195
+ default: n(() => [
196
+ c[6] || (c[6] = f("div", { class: "client-header-logo" }, " ISIP ", -1)),
197
+ f("div", zt, [
198
+ a(pt, { mode: "horizontal" })
199
+ ]),
200
+ f("div", Gt, [
201
+ a(de, {
202
+ modelValue: F.value,
203
+ "onUpdate:modelValue": c[1] || (c[1] = (w) => F.value = w),
204
+ clearable: "",
205
+ placeholder: "搜索",
206
+ style: { width: "130px" }
207
+ }, {
208
+ prefix: n(() => [
209
+ a(Be, { class: "el-input__icon" }, {
210
+ default: n(() => [
211
+ a(o(rt))
212
+ ]),
213
+ _: 1
214
+ })
215
+ ]),
216
+ _: 1
217
+ }, 8, ["modelValue"]),
218
+ k.showButton ? (u(), T(R, {
219
+ key: 0,
220
+ id: "transparentBgButton",
221
+ onClick: o(at)
222
+ }, {
223
+ icon: n(() => [
224
+ a(fe, { name: "App" })
225
+ ]),
226
+ default: n(() => [
227
+ c[4] || (c[4] = z(" 生成APP "))
228
+ ]),
229
+ _: 1,
230
+ __: [4]
231
+ }, 8, ["onClick"])) : N("", !0),
232
+ k.showButton && o(i) === "view" ? (u(), T(R, {
233
+ key: 1,
234
+ id: "transparentBgButton",
235
+ onClick: o(ot)
236
+ }, {
237
+ icon: n(() => [
238
+ a(fe, { name: "write" })
239
+ ]),
240
+ default: n(() => [
241
+ c[5] || (c[5] = z(" 修改布局 "))
242
+ ]),
243
+ _: 1,
244
+ __: [5]
245
+ }, 8, ["onClick"])) : N("", !0),
246
+ _e(G.$slots, "default", {}, void 0, !0),
247
+ a(dt, null, {
248
+ dropTitle: n(() => {
249
+ var w;
250
+ return [
251
+ a(mt, {
252
+ size: "35",
253
+ avatarUrl: (w = o(S)) == null ? void 0 : w.avatarUrl,
254
+ showCropper: !1,
255
+ banClick: !0
256
+ }, {
257
+ avatarDefault: n(() => {
258
+ var l;
259
+ return [
260
+ z(ae(((l = o(S)) == null ? void 0 : l.account) ?? "未知"), 1)
261
+ ];
262
+ }),
263
+ _: 1
264
+ }, 8, ["avatarUrl"])
265
+ ];
266
+ }),
267
+ dropMenu: n(() => [
268
+ f("div", Xt, [
269
+ a(me, {
270
+ emptyColor: !0,
271
+ class: "menu-button",
272
+ onClickTrigger: J,
273
+ modelValue: "退出登录",
274
+ buttonType: ""
275
+ })
276
+ ])
277
+ ]),
278
+ _: 1
279
+ })
280
+ ])
281
+ ]),
282
+ _: 3,
283
+ __: [6]
284
+ }),
285
+ a(X, { class: "client-body" }, {
286
+ default: n(() => [
287
+ a(b, { class: "client-main" }, {
288
+ default: n(() => {
289
+ var w;
290
+ return [
291
+ a(h, { class: "client-aside" }, {
292
+ default: n(() => [
293
+ a(Ye, { mode: "vertical" })
294
+ ]),
295
+ _: 1
296
+ }),
297
+ f("div", qt, [
298
+ P.value ? (u(), T(D, { key: 0 })) : N("", !0),
299
+ o(I) !== "" ? (u(), T(me, {
300
+ key: 1,
301
+ class: "calculator-content back-content",
302
+ onClickTrigger: W,
303
+ modelValue: "返回"
304
+ })) : N("", !0),
305
+ P.value ? N("", !0) : (u(!0), M(we, { key: 2 }, Pe((w = o(Se)(o(te))) == null ? void 0 : w.filter((l) => l.comp !== "FormTop"), (l, O) => {
306
+ var L;
307
+ return u(), M("div", {
308
+ class: "item-view-content",
309
+ key: O
310
+ }, [
311
+ ((L = l == null ? void 0 : l.comp) == null ? void 0 : L.toUpperCase()) !== "TABLE" && l.name ? (u(), M("div", Ht, ae(l.name), 1)) : N("", !0),
312
+ (u(), T(Qe(o(nt)(l.comp)), {
313
+ compName: l.name,
314
+ itemData: l == null ? void 0 : l.compData,
315
+ childItemData: l == null ? void 0 : l.itemChildData,
316
+ key: (l == null ? void 0 : l.id) ?? O,
317
+ onChange: o(st),
318
+ index: (l == null ? void 0 : l.id) ?? O,
319
+ onContentChange: o(it),
320
+ onPageChange: o(lt)
321
+ }, null, 40, ["compName", "itemData", "childItemData", "onChange", "index", "onContentChange", "onPageChange"]))
322
+ ]);
323
+ }), 128))
324
+ ])
325
+ ];
326
+ }),
327
+ _: 1
328
+ })
329
+ ]),
330
+ _: 1
331
+ })
332
+ ]),
333
+ _: 3
334
+ })), [
335
+ [Te, o(i) === "view"],
336
+ [$, o(A)]
337
+ ])
338
+ ], 64);
339
+ };
340
+ }
341
+ }), Wt = /* @__PURE__ */ ge(Jt, [["__scopeId", "data-v-1c30d678"]]), Me = [
342
+ {
343
+ key: "FitCurve_Eleven",
344
+ value: "http://139.196.154.85:20024/api/algorithmRun/verificationAlgorithm/35326658522693",
345
+ resources: "http://139.196.154.85:20024/api/algorithmRun/allFilesByFolderName/35326658522693",
346
+ download: "http://139.196.154.85:20024/api/algorithmRun/downloadFileByFileName/35326658522693/outputResources"
347
+ },
348
+ {
349
+ key: "MakeShape",
350
+ value: "http://139.196.154.85:20024/api/algorithmRun/verificationAlgorithm/35018179530309",
351
+ resources: "http://139.196.154.85:20024/api/algorithmRun/allFilesByFolderName/35018179530309",
352
+ download: "http://139.196.154.85:20024/api/algorithmRun/downloadFileByFileName/35018179530309/outputResources"
353
+ },
354
+ {
355
+ key: "FillEmpty",
356
+ value: "http://139.196.154.85:20024/api/algorithmRun/verificationAlgorithm/35018289382469",
357
+ resources: "http://139.196.154.85:20024/api/algorithmRun/allFilesByFolderName/35018289382469",
358
+ download: "http://139.196.154.85:20024/api/algorithmRun/downloadFileByFileName/35018289382469/outputResources"
359
+ },
360
+ {
361
+ key: "ToolPathFakeFast",
362
+ value: "http://139.196.154.85:20024/api/algorithmRun/verificationAlgorithm/35484063607109",
363
+ resources: "http://139.196.154.85:20024/api/algorithmRun/allFilesByFolderName/35484063607109",
364
+ download: "http://139.196.154.85:20024/api/algorithmRun/downloadFileByFileName/35484063607109/outputResources"
365
+ },
366
+ {
367
+ key: "FiveAxisCalculator",
368
+ value: "http://139.196.154.85:20024/api/algorithmRun/verificationAlgorithm/35237389477957",
369
+ resources: "http://139.196.154.85:20024/api/algorithmRun/allFilesByFolderName/35237389477957",
370
+ download: "http://139.196.154.85:20024/api/algorithmRun/downloadFileByFileName/35237389477957/outputResources"
371
+ },
372
+ {
373
+ key: "DetectionAlgorithm",
374
+ value: "http://139.196.154.85:20024/api/algorithmRun/verificationAlgorithm/35459977498949",
375
+ resources: "http://139.196.154.85:20024/api/algorithmRun/allFilesByFolderName/35459977498949",
376
+ download: "http://139.196.154.85:20024/api/algorithmRun/downloadFileByFileName/35459977498949/outputResources"
377
+ },
378
+ {
379
+ key: "FeatureSelectionAlgorithm_FFS",
380
+ value: "http://139.196.154.85:20024/api/algorithmRun/verificationAlgorithm/35277984187973",
381
+ resources: "http://139.196.154.85:20024/api/algorithmRun/allFilesByFolderName/35277984187973",
382
+ download: "http://139.196.154.85:20024/api/algorithmRun/downloadFileByFileName/35277984187973/outputResources"
383
+ },
384
+ {
385
+ key: "AIParameterOptimization",
386
+ value: "http://139.196.154.85:20024/api/algorithmRun/verificationAlgorithm/35788169784389",
387
+ resources: "http://139.196.154.85:20024/api/algorithmRun/allFilesByFolderName/35788169784389"
388
+ }
389
+ ], xe = [
390
+ {
391
+ key: "型线生成",
392
+ value: "http://139.196.154.85:20024/api/algorithmRun/downloadFileByFileName/35326658522693/outputResources/sampling_points_20.cpt"
393
+ },
394
+ {
395
+ key: "曲面生成",
396
+ value: "http://139.196.154.85:20024/api/algorithmRun/downloadFileByFileName/35018179530309/outputResources/output.obj"
397
+ },
398
+ {
399
+ key: "叶片生成",
400
+ value: "http://139.196.154.85:20024/api/algorithmRun/downloadFileByFileName/35018289382469/outputResources/output_TwoSections_completed.obj"
401
+ },
402
+ {
403
+ key: "轨迹规划",
404
+ value: "http://139.196.154.85:20024/api/algorithmRun/downloadFileByFileName/35484063607109/outputResources/complete_data.txt"
405
+ },
406
+ {
407
+ key: "加工规划",
408
+ value: "http://139.196.154.85:20024/api/algorithmRun/downloadFileByFileName/35237389477957/outputResources/NC_BC.NC"
409
+ },
410
+ {
411
+ key: "产品检测",
412
+ value: "http://139.196.154.85:20024/api/algorithmRun/downloadFileByFileName/35459977498949/outputResources/source.pcd,http://139.196.154.85:20024/api/algorithmRun/downloadFileByFileName/35459977498949/outputResources/target.pcd"
413
+ },
414
+ {
415
+ key: "参数筛选训练方法",
416
+ value: "http://139.196.154.85:20024/api/algorithmRun/downloadFileByFileName/35277984187973/outputResources/fitness_iteration.png"
417
+ }
418
+ // {
419
+ // key: "参数筛选推理",
420
+ // value: "http://139.196.154.85:20024/api/algorithmRun/downloadFileByFileName/35277984187973/outputResources/fitness_iteration.png"
421
+ // }
422
+ ], Qt = { class: "structure-buttons" }, Yt = { class: "structure-paths" }, Zt = { class: "client-header-user" }, ea = { class: "model-select" }, ta = { class: "model-show" }, aa = { class: "model-fill" }, oa = { class: "client-header-menu" }, na = { class: "client-header-user" }, la = { class: "drop-menu" }, ia = { class: "client-main-operate" }, sa = {
423
+ key: 0,
424
+ class: "item-view-group"
425
+ }, ra = /* @__PURE__ */ Je({
426
+ __name: "index2",
427
+ props: {
428
+ windowConfig: {
429
+ type: Object,
430
+ default: () => {
431
+ }
432
+ },
433
+ showButton: {
434
+ type: Boolean,
435
+ default: !0
436
+ }
437
+ },
438
+ emits: ["showChild", "buildContent"],
439
+ setup(k, { emit: Y }) {
440
+ const e = Ne(H), C = d(!1);
441
+ d(0), d(!1);
442
+ const { selectTitle: S } = q(e), E = d(!1), i = d(!1);
443
+ d(!1);
444
+ const I = Ft(H), x = d(!1), { tableShowThree: A } = q(I), oe = ut(), { loginUserInfo: Z } = q(oe);
445
+ d(null);
446
+ const F = $e(H), { isEdit: P } = q(F), J = Ae(H), W = At(H), { objUrl: G, blobUrls: c } = q(W), R = d(null);
447
+ d(!1);
448
+ const ve = d(!0);
449
+ d(!1);
450
+ const { importLoading: ce, activeMenuPath: X, activeTopMenuPath: Be, platName: de, activeAsideMenu: me } = q(J), h = d(!1), D = d(!1), b = d(!1), $ = Y;
451
+ U(() => X.value, async (t) => {
452
+ t && (b.value = !0), t === "弯管仿真加工管理/仿真动画生成" ? h.value = !0 : h.value = !1, t === "弯管仿真加工管理/程序输出" ? D.value = !0 : D.value = !1, xe != null && xe.find((s) => {
453
+ var B;
454
+ return (s == null ? void 0 : s.key) === ((B = t == null ? void 0 : t.split("/")) == null ? void 0 : B[(t == null ? void 0 : t.split("/").length) - 1]);
455
+ }) ? x.value = !0 : x.value = !1;
456
+ }, { immediate: !0 });
457
+ const w = (t) => {
458
+ if ((t == null ? void 0 : t.type) === "table") {
459
+ let s = Object.values(t == null ? void 0 : t.row), B = s == null ? void 0 : s.find((g) => typeof g == "string" && ((g == null ? void 0 : g.includes(".urdf")) || (g == null ? void 0 : g.includes(".obj"))));
460
+ B && $("showChild", {
461
+ url: B,
462
+ row: t == null ? void 0 : t.row
463
+ });
464
+ }
465
+ }, l = async () => {
466
+ sessionStorage.clear(), window.location.reload(), await yt();
467
+ }, O = async (t) => {
468
+ var g, _, v, r, K, Q, m;
469
+ const s = (g = t == null ? void 0 : t.split("/")) == null ? void 0 : g[0], B = await kt({
470
+ key: {
471
+ type: "mainEquip",
472
+ systemKey: sessionStorage.getItem("systemKey"),
473
+ pageKey: s
474
+ }
475
+ });
476
+ return ((_ = B == null ? void 0 : B.data) == null ? void 0 : _.type) === "success" ? ((m = (Q = (K = (r = (v = B == null ? void 0 : B.data) == null ? void 0 : v.result) == null ? void 0 : r[0]) == null ? void 0 : K.value) == null ? void 0 : Q.tableData) == null ? void 0 : m.隐藏三维显示) !== !0 : !0;
477
+ };
478
+ U(
479
+ () => te.value,
480
+ () => {
481
+ var t, s, B, g, _;
482
+ if (((t = te.value) == null ? void 0 : t.length) === 2 && ((s = te.value) != null && s.find((v) => (v == null ? void 0 : v.name) === "输入")) && ((B = te.value) != null && B.find((v) => (v == null ? void 0 : v.name) === "输出"))) {
483
+ const v = (g = te.value) == null ? void 0 : g.find((r) => (r == null ? void 0 : r.name) === "输出");
484
+ i.value = ((_ = v == null ? void 0 : v.comp) == null ? void 0 : _.toUpperCase()) === "FORM", E.value = !0;
485
+ } else
486
+ E.value = !1, i.value = !1;
487
+ },
488
+ { deep: !0, immediate: !0 }
489
+ ), U(
490
+ () => X.value,
491
+ async () => {
492
+ X.value && (ve.value = await O(X.value));
493
+ },
494
+ { deep: !0, immediate: !0 }
495
+ ), U(
496
+ () => [G.value, R.value],
497
+ () => {
498
+ var t;
499
+ ((t = G.value) == null ? void 0 : t.length) > 0 && R.value && R.value.addModelsFromUrls(G.value);
500
+ },
501
+ { immediate: !0, deep: !0 }
502
+ ), U(
503
+ () => c == null ? void 0 : c.value,
504
+ async () => {
505
+ var t, s, B, g;
506
+ if (c != null && c.value && ((t = c == null ? void 0 : c.value) == null ? void 0 : t.length) > 0 && !x.value && !((s = te.value) != null && s.find((_) => (_ == null ? void 0 : _.name) === "输入") && ((B = te.value) != null && B.find((_) => (_ == null ? void 0 : _.name) === "输出")))) {
507
+ let _ = [];
508
+ const v = await ((g = Se(c == null ? void 0 : c.value)) == null ? void 0 : g.map(async (r) => {
509
+ var le, ke, V, p, ne, ie, Fe, Ue, Ee, Ie;
510
+ let K, Q, m;
511
+ r != null && r.blob.includes("undefined") ? m = (ke = (le = r == null ? void 0 : r.blob) == null ? void 0 : le.split("undefined,")) == null ? void 0 : ke[1] : m = r == null ? void 0 : r.blob;
512
+ let ee = m == null ? void 0 : m.split(",");
513
+ if ((ee == null ? void 0 : ee.length) > 1) {
514
+ let ue = await (ee == null ? void 0 : ee.map(async (j) => {
515
+ var se, Oe, Le, Ke, ze, Ge;
516
+ K = await Ce.get(j, {
517
+ responseType: "blob",
518
+ headers: {
519
+ "Content-Type": "application/json"
520
+ }
521
+ });
522
+ let he = [];
523
+ if (((se = r == null ? void 0 : r.mtlBlobs) == null ? void 0 : se.length) > 0) {
524
+ let ft = await ((Oe = r == null ? void 0 : r.mtlBlobs) == null ? void 0 : Oe.map(async (_t) => {
525
+ let Xe = await Ce.get(_t, {
526
+ responseType: "blob",
527
+ headers: {
528
+ "Content-Type": "application/json"
529
+ }
530
+ });
531
+ return he.push(new Blob([Xe.data], {
532
+ type: "application/octet-stream;charset=UTF-8"
533
+ })), Xe;
534
+ }));
535
+ await Promise.all(ft);
536
+ }
537
+ return ((Ke = j == null ? void 0 : j.split(".")) == null ? void 0 : Ke[((Le = j == null ? void 0 : j.split(".")) == null ? void 0 : Le.length) - 1]) !== "undefined" && _.push({
538
+ suffix: "." + ((Ge = j == null ? void 0 : j.split(".")) == null ? void 0 : Ge[((ze = j == null ? void 0 : j.split(".")) == null ? void 0 : ze.length) - 1]),
539
+ blob: new Blob([K.data], {
540
+ type: "application/octet-stream;charset=UTF-8"
541
+ }),
542
+ mtlBlobs: he
543
+ }), K;
544
+ }));
545
+ await Promise.all(ue);
546
+ } else if (!(m != null && m.includes("https://")) && !(m != null && m.includes("http://"))) {
547
+ K = await He({
548
+ url: m
549
+ });
550
+ let ue = [];
551
+ if (((V = r == null ? void 0 : r.mtlBlobs) == null ? void 0 : V.length) > 0) {
552
+ let j = await ((p = r == null ? void 0 : r.mtlBlobs) == null ? void 0 : p.map(async (he) => {
553
+ let se = await He({
554
+ url: he
555
+ });
556
+ return ue.push(new Blob([se.data], {
557
+ type: "application/octet-stream;charset=UTF-8"
558
+ })), se;
559
+ }));
560
+ await Promise.all(j);
561
+ }
562
+ Q = {
563
+ suffix: "." + ((ie = m == null ? void 0 : m.split(".")) == null ? void 0 : ie[((ne = m == null ? void 0 : m.split(".")) == null ? void 0 : ne.length) - 1]),
564
+ blob: new Blob([K.data], {
565
+ type: "application/octet-stream;charset=UTF-8"
566
+ }),
567
+ mtlBlobs: ue
568
+ };
569
+ } else {
570
+ K = await Ce.get(m, {
571
+ responseType: "blob",
572
+ headers: {
573
+ "Content-Type": "application/json"
574
+ }
575
+ });
576
+ let ue = [];
577
+ if (((Fe = r == null ? void 0 : r.mtlBlobs) == null ? void 0 : Fe.length) > 0) {
578
+ let j = await ((Ue = r == null ? void 0 : r.mtlBlobs) == null ? void 0 : Ue.map(async (he) => {
579
+ let se = await Ce.get(he, {
580
+ responseType: "blob",
581
+ headers: {
582
+ "Content-Type": "application/json"
583
+ }
584
+ });
585
+ return ue.push(new Blob([se.data], {
586
+ type: "application/octet-stream;charset=UTF-8"
587
+ })), se;
588
+ }));
589
+ await Promise.all(j);
590
+ }
591
+ Q = {
592
+ suffix: "." + ((Ie = m == null ? void 0 : m.split(".")) == null ? void 0 : Ie[((Ee = m == null ? void 0 : m.split(".")) == null ? void 0 : Ee.length) - 1]),
593
+ blob: new Blob([K.data], {
594
+ type: "application/octet-stream;charset=UTF-8"
595
+ }),
596
+ mtlBlobs: ue
597
+ };
598
+ }
599
+ Q && _.push(Q);
600
+ }));
601
+ await Promise.all(v), (_ == null ? void 0 : _.length) !== 0 && (C.value = !0, R.value.loadModelByDefaultPath(_));
602
+ }
603
+ },
604
+ { immediate: !0, deep: !0 }
605
+ ), U(
606
+ () => A.value,
607
+ async () => {
608
+ var s, B, g, _;
609
+ if (A.value !== "" && A.value) {
610
+ let v = (s = X.value) == null ? void 0 : s.split("/"), r = v[(v == null ? void 0 : v.length) - 2];
611
+ const Q = (((B = Me == null ? void 0 : Me.find((le) => (le == null ? void 0 : le.key) === r)) == null ? void 0 : B.download) ?? "") + "/" + A.value, m = sessionStorage.getItem("magicToken") === "" ? "123456" : sessionStorage.getItem("magicToken"), ee = await Ce.post(Q, null, {
612
+ responseType: "blob",
613
+ // 必须设置
614
+ headers: {
615
+ Authorization: m,
616
+ baseURL: "http://139.196.154.85:20025",
617
+ "Content-Type": "application/json"
618
+ }
619
+ });
620
+ var t = new Blob([ee.data], {
621
+ type: "application/octet-stream;charset=UTF-8"
622
+ });
623
+ "" + ((_ = (g = A.value) == null ? void 0 : g.split(".")) == null ? void 0 : _[1]);
624
+ }
625
+ },
626
+ { deep: !0, immediate: !0 }
627
+ );
628
+ const L = d("");
629
+ d("open"), d("open"), d(!1), be(() => te.value);
630
+ const pe = be(() => me.value.isRouter), re = d(!1), ye = () => {
631
+ re.value = !0, setTimeout(() => {
632
+ R.value.loadModelByDefaultPath([{ suffix: ".urdf" }]);
633
+ }, 1e3);
634
+ };
635
+ return (t, s) => {
636
+ const B = y("el-dialog"), g = y("el-button"), _ = y("el-avatar"), v = y("el-header"), r = y("el-container"), K = y("el-icon"), Q = y("el-input"), m = y("el-aside"), ee = y("router-view"), le = y("el-main"), ke = We("loading");
637
+ return u(), M(we, null, [
638
+ a(B, {
639
+ modelValue: re.value,
640
+ "onUpdate:modelValue": s[0] || (s[0] = (V) => re.value = V),
641
+ style: { height: "700px", width: "1800px" }
642
+ }, {
643
+ default: n(() => [
644
+ a(qe, {
645
+ ref_key: "threeModelRef",
646
+ ref: R
647
+ }, null, 512)
648
+ ]),
649
+ _: 1
650
+ }, 8, ["modelValue"]),
651
+ Re(a(r, { class: "client-container" }, {
652
+ default: n(() => [
653
+ a(v, { class: "client-structure-header" }, {
654
+ default: n(() => {
655
+ var V;
656
+ return [
657
+ f("div", Qt, [
658
+ a(g, {
659
+ id: "transparentBgButton",
660
+ onClick: o(Ze)
661
+ }, {
662
+ default: n(() => s[4] || (s[4] = [
663
+ z(" 返回页面 ")
664
+ ])),
665
+ _: 1,
666
+ __: [4]
667
+ }, 8, ["onClick"]),
668
+ a(g, {
669
+ id: "transparentBgButton",
670
+ onClick: s[1] || (s[1] = (p) => {
671
+ var ne, ie;
672
+ return o(et)((ie = (ne = o(S)) == null ? void 0 : ne.map((Fe) => Fe.value)) == null ? void 0 : ie.join("/"));
673
+ })
674
+ }, {
675
+ icon: n(() => [
676
+ a(fe, { name: "Store" })
677
+ ]),
678
+ default: n(() => [
679
+ s[5] || (s[5] = z(" 保存页面 "))
680
+ ]),
681
+ _: 1,
682
+ __: [5]
683
+ })
684
+ ]),
685
+ f("div", Yt, [
686
+ a(ht, {
687
+ breadArray: o(S),
688
+ onClick: o(tt)
689
+ }, null, 8, ["breadArray", "onClick"])
690
+ ]),
691
+ f("div", Zt, [
692
+ _e(t.$slots, "default", {}, void 0, !0),
693
+ a(_, {
694
+ size: 35,
695
+ src: (V = o(Z)) == null ? void 0 : V.avatarUrl
696
+ }, {
697
+ default: n(() => {
698
+ var p;
699
+ return [
700
+ z(ae(((p = o(Z)) == null ? void 0 : p.account) ?? "未知"), 1)
701
+ ];
702
+ }),
703
+ _: 1
704
+ }, 8, ["src"])
705
+ ])
706
+ ];
707
+ }),
708
+ _: 3
709
+ }),
710
+ o(P) === "edit" ? (u(), T(r, {
711
+ key: 0,
712
+ class: "model-operate",
713
+ style: { "margin-top": "10px", height: "0px" }
714
+ }, {
715
+ default: n(() => [
716
+ f("div", ea, [
717
+ a(De)
718
+ ]),
719
+ f("div", ta, [
720
+ a(je)
721
+ ]),
722
+ f("div", aa, [
723
+ a(Ve)
724
+ ])
725
+ ]),
726
+ _: 1
727
+ })) : N("", !0)
728
+ ]),
729
+ _: 3
730
+ }, 512), [
731
+ [Te, o(P) === "edit"]
732
+ ]),
733
+ Re((u(), T(r, {
734
+ class: "client-container",
735
+ "element-loading-text": "正在加载页面数据..."
736
+ }, {
737
+ default: n(() => [
738
+ a(v, { class: "client-header" }, {
739
+ default: n(() => [
740
+ f("div", {
741
+ class: "client-header-logo",
742
+ onClick: ye
743
+ }, ae(o(de) === "" ? "CPMPIP" : o(de)), 1),
744
+ f("div", oa, [
745
+ a(pt, { mode: "horizontal" })
746
+ ]),
747
+ f("div", na, [
748
+ a(Q, {
749
+ modelValue: L.value,
750
+ "onUpdate:modelValue": s[2] || (s[2] = (V) => L.value = V),
751
+ clearable: "",
752
+ placeholder: "搜索",
753
+ style: { width: "130px" }
754
+ }, {
755
+ prefix: n(() => [
756
+ a(K, { class: "el-input__icon" }, {
757
+ default: n(() => [
758
+ a(o(rt))
759
+ ]),
760
+ _: 1
761
+ })
762
+ ]),
763
+ _: 1
764
+ }, 8, ["modelValue"]),
765
+ k.showButton ? (u(), T(g, {
766
+ key: 0,
767
+ id: "transparentBgButton",
768
+ onClick: o(at)
769
+ }, {
770
+ icon: n(() => [
771
+ a(fe, { name: "App" })
772
+ ]),
773
+ default: n(() => [
774
+ s[6] || (s[6] = z(" 生成APP "))
775
+ ]),
776
+ _: 1,
777
+ __: [6]
778
+ }, 8, ["onClick"])) : N("", !0),
779
+ k.showButton && o(P) === "view" ? (u(), T(g, {
780
+ key: 1,
781
+ id: "transparentBgButton",
782
+ onClick: o(ot)
783
+ }, {
784
+ icon: n(() => [
785
+ a(fe, { name: "write" })
786
+ ]),
787
+ default: n(() => [
788
+ s[7] || (s[7] = z(" 修改布局 "))
789
+ ]),
790
+ _: 1,
791
+ __: [7]
792
+ }, 8, ["onClick"])) : N("", !0),
793
+ _e(t.$slots, "default", {}, void 0, !0),
794
+ a(dt, null, {
795
+ dropTitle: n(() => {
796
+ var V;
797
+ return [
798
+ a(mt, {
799
+ size: "35",
800
+ avatarUrl: (V = o(Z)) == null ? void 0 : V.avatarUrl,
801
+ showCropper: !1,
802
+ banClick: !0
803
+ }, {
804
+ avatarDefault: n(() => {
805
+ var p;
806
+ return [
807
+ z(ae(((p = o(Z)) == null ? void 0 : p.account) ?? "未知"), 1)
808
+ ];
809
+ }),
810
+ _: 1
811
+ }, 8, ["avatarUrl"])
812
+ ];
813
+ }),
814
+ dropMenu: n(() => [
815
+ f("div", la, [
816
+ a(Tt, {
817
+ emptyColor: !0,
818
+ class: "menu-button",
819
+ onClickTrigger: l,
820
+ modelValue: "退出登录",
821
+ buttonType: ""
822
+ })
823
+ ])
824
+ ]),
825
+ _: 1
826
+ })
827
+ ])
828
+ ]),
829
+ _: 3
830
+ }),
831
+ a(r, { class: "client-body" }, {
832
+ default: n(() => [
833
+ a(le, { class: "client-main" }, {
834
+ default: n(() => {
835
+ var V;
836
+ return [
837
+ a(m, { class: "client-aside" }, {
838
+ default: n(() => [
839
+ a(Ye, { mode: "vertical" })
840
+ ]),
841
+ _: 1
842
+ }),
843
+ f("div", ia, [
844
+ pe.value ? (u(), T(ee, { key: 0 })) : (u(!0), M(we, { key: 1 }, Pe((V = o(Se)(o(te))) == null ? void 0 : V.filter((p) => p.comp !== "FormTop"), (p, ne) => {
845
+ var ie;
846
+ return u(), M("div", {
847
+ class: "item-view-content",
848
+ key: ne
849
+ }, [
850
+ ((ie = p == null ? void 0 : p.comp) == null ? void 0 : ie.toUpperCase()) !== "TABLE" && p.name ? (u(), M("div", sa, ae(p.name), 1)) : N("", !0),
851
+ (u(), T(Qe(o(nt)(p.comp)), {
852
+ compName: p.name,
853
+ itemData: p == null ? void 0 : p.compData,
854
+ childItemData: p == null ? void 0 : p.itemChildData,
855
+ key: (p == null ? void 0 : p.id) ?? ne,
856
+ onChange: o(st),
857
+ index: (p == null ? void 0 : p.id) ?? ne,
858
+ onContentChange: o(it),
859
+ onPageChange: o(lt),
860
+ onRowClick: w
861
+ }, null, 40, ["compName", "itemData", "childItemData", "onChange", "index", "onContentChange", "onPageChange"]))
862
+ ]);
863
+ }), 128))
864
+ ])
865
+ ];
866
+ }),
867
+ _: 1
868
+ })
869
+ ]),
870
+ _: 1
871
+ })
872
+ ]),
873
+ _: 3
874
+ })), [
875
+ [Te, o(P) === "view"],
876
+ [ke, o(ce)]
877
+ ]),
878
+ f("div", null, [
879
+ a(St, {
880
+ visible: C.value,
881
+ onBeforeDestroy: s[3] || (s[3] = (V) => C.value = !1),
882
+ style: { height: "700px", width: "1000px" }
883
+ }, {
884
+ default: n(() => [
885
+ a(qe, {
886
+ ref_key: "threeModelRef",
887
+ ref: R
888
+ }, null, 512)
889
+ ]),
890
+ _: 1
891
+ }, 8, ["visible"])
892
+ ])
893
+ ], 64);
894
+ };
895
+ }
896
+ }), ua = /* @__PURE__ */ ge(ra, [["__scopeId", "data-v-782cdc9e"]]), ca = { class: "system-wrap" }, da = {
897
+ __name: "index",
898
+ props: {
899
+ windowConfig: {
900
+ type: Object,
901
+ default: () => {
902
+ }
903
+ },
904
+ platform: {
905
+ type: String,
906
+ default: "browser"
907
+ },
908
+ showButton: {
909
+ type: Boolean,
910
+ default: !0
911
+ },
912
+ content: String,
913
+ jsonContents: Array
914
+ },
915
+ emits: ["buildContent", "showChild"],
916
+ setup(k, { emit: Y }) {
917
+ const e = $e(H), C = Ne(H), S = Ae();
918
+ d(!1);
919
+ const E = d(!0), i = k, I = Y, x = (F) => {
920
+ I("showChild", F);
921
+ }, A = be(() => {
922
+ switch (i == null ? void 0 : i.platform) {
923
+ case "browser":
924
+ return xt;
925
+ case "client":
926
+ return Mt;
927
+ }
928
+ }), oe = (F) => {
929
+ const P = document.documentElement;
930
+ F == null || F.forEach((J) => {
931
+ P.style.setProperty(J.name, J.value);
932
+ });
933
+ };
934
+ U(() => i.platform, (F, P) => {
935
+ F && oe(A.value);
936
+ }, { immediate: !0 });
937
+ const Z = () => {
938
+ I("buildContent");
939
+ };
940
+ return U(
941
+ () => [i == null ? void 0 : i.content, i == null ? void 0 : i.jsonContents],
942
+ async () => {
943
+ var J, W, G, c;
944
+ if (((J = i == null ? void 0 : i.jsonContents) == null ? void 0 : J.length) > 0) {
945
+ e.setOriginalData(i == null ? void 0 : i.jsonContents);
946
+ return;
947
+ }
948
+ if (!(i != null && i.content) || ((W = i == null ? void 0 : i.content) == null ? void 0 : W.length) === 0) return;
949
+ E.value = !0, S.setImportLoading(!0);
950
+ let F = [], P = [];
951
+ C.setSelectTitle([]), C.setSelectIndex(""), C.setSelectMenu(""), (c = (G = i == null ? void 0 : i.content) == null ? void 0 : G.filter((R) => R !== "")) == null || c.forEach((R) => {
952
+ P.push(wt(R));
953
+ }), F = P == null ? void 0 : P[0], await Bt(F), await ct(), e.setOriginalData(F), S.setImportLoading(!1);
954
+ },
955
+ { deep: !0, immediate: !0 }
956
+ ), (F, P) => (u(), M("div", ca, [
957
+ k.platform === "browser" ? (u(), T(Wt, {
958
+ key: 0,
959
+ showButton: k.showButton
960
+ }, {
961
+ default: n(() => [
962
+ _e(F.$slots, "default", {}, void 0, !0)
963
+ ]),
964
+ _: 3
965
+ }, 8, ["showButton"])) : (u(), T(ua, {
966
+ key: 1,
967
+ windowConfig: k.windowConfig,
968
+ showButton: k.showButton,
969
+ onBuildContent: Z,
970
+ onShowChild: x
971
+ }, {
972
+ default: n(() => [
973
+ _e(F.$slots, "default", {}, void 0, !0)
974
+ ]),
975
+ _: 3
976
+ }, 8, ["windowConfig", "showButton"]))
977
+ ]));
978
+ }
979
+ }, ma = /* @__PURE__ */ ge(da, [["__scopeId", "data-v-5e89b0de"]]), pa = { class: "add-model-content" }, ha = {
980
+ key: 0,
981
+ class: "model-operate"
982
+ }, fa = { class: "model-select" }, _a = { class: "model-fill" }, ga = {
983
+ key: 1,
984
+ class: "model-view"
985
+ }, va = {
986
+ __name: "index",
987
+ props: {
988
+ mode: {
989
+ type: String,
990
+ default: "view"
991
+ },
992
+ content: {
993
+ type: String,
994
+ default: ""
995
+ },
996
+ jsonContents: {
997
+ type: Array,
998
+ default: () => []
999
+ },
1000
+ showButton: {
1001
+ type: Boolean,
1002
+ default: !0
1003
+ },
1004
+ pathContent: {
1005
+ type: String,
1006
+ default: ""
1007
+ },
1008
+ pageKey: {
1009
+ type: String,
1010
+ default: ""
1011
+ }
1012
+ },
1013
+ emits: ["change", "contentChange", "buildContent", "openThreeBuild", "threeData"],
1014
+ setup(k, { emit: Y }) {
1015
+ const e = k, C = Y, S = d([]), E = d(0), i = d([]), I = d([]), x = d(0), A = $e(H), oe = Ae(H), { itemData: Z, originalData: F } = q(A), { activeMenuPath: P, platform: J } = q(oe), W = d(null), G = d(0), c = d([]);
1016
+ d("");
1017
+ const R = d(0), ve = () => {
1018
+ C("buildContent");
1019
+ };
1020
+ U(
1021
+ () => e == null ? void 0 : e.pageKey,
1022
+ async () => {
1023
+ if ((e == null ? void 0 : e.pageKey) !== "") {
1024
+ let h = [];
1025
+ const D = await bt(e == null ? void 0 : e.pageKey, sessionStorage.getItem("systemKey"), "", e == null ? void 0 : e.pageKey);
1026
+ D == null || D.forEach((b) => {
1027
+ var $, w, l, O, L, pe;
1028
+ if ((b == null ? void 0 : b.comp) === "Table") {
1029
+ let re = (l = (w = ($ = b == null ? void 0 : b.compData) == null ? void 0 : $.find((t) => (t == null ? void 0 : t.key) === "header")) == null ? void 0 : w.contents) == null ? void 0 : l.map((t) => t == null ? void 0 : t.label), ye = (pe = (L = (O = b == null ? void 0 : b.compData) == null ? void 0 : O.find((t) => (t == null ? void 0 : t.key) === "tableContents")) == null ? void 0 : L.contents) == null ? void 0 : pe.map((t) => (t = t == null ? void 0 : t.filter((s) => !(s != null && s.id)), t));
1030
+ ye == null || ye.forEach((t) => {
1031
+ h.push(Rt(t, re == null ? void 0 : re.filter((s) => s !== "操作")));
1032
+ });
1033
+ }
1034
+ }), C("threeData", h);
1035
+ }
1036
+ },
1037
+ { deep: !0, immediate: !0 }
1038
+ );
1039
+ const ce = (h) => {
1040
+ C("openThreeBuild", h);
1041
+ };
1042
+ U(
1043
+ () => e == null ? void 0 : e.pathContent,
1044
+ () => {
1045
+ (e == null ? void 0 : e.pathContent) !== "" && A.setSystemPath(e == null ? void 0 : e.pathContent);
1046
+ },
1047
+ {
1048
+ deep: !0,
1049
+ immediate: !0
1050
+ }
1051
+ );
1052
+ const X = (h) => {
1053
+ C("contentChange", h);
1054
+ }, Be = (h) => {
1055
+ var b;
1056
+ const D = (b = Se(h == null ? void 0 : h.wholeValue)) == null ? void 0 : b.map(($) => {
1057
+ var w;
1058
+ return ($ == null ? void 0 : $.comp) === "Form" && ($.compData = (w = $.compData) == null ? void 0 : w.map((l) => ((l == null ? void 0 : l.key) === "formContent" && (l.contents = $t(l == null ? void 0 : l.contents)), l))), $;
1059
+ });
1060
+ C("change", {
1061
+ originalContents: F.value,
1062
+ currentContents: h == null ? void 0 : h.wholeValue,
1063
+ editContent: h == null ? void 0 : h.editValue,
1064
+ arrayToContents: D
1065
+ });
1066
+ };
1067
+ U(
1068
+ () => i.value,
1069
+ () => {
1070
+ R.value === i.value.length && i.value.length !== 0 && (S.value = i.value);
1071
+ },
1072
+ { deep: !0, immediate: !0 }
1073
+ );
1074
+ const de = () => {
1075
+ W.value !== null && W.value.click();
1076
+ }, me = async (h) => {
1077
+ const D = h.target.files;
1078
+ if (!D) return;
1079
+ new FileReader(), S.value = [], i.value = [], R.value = D.length;
1080
+ const b = Array.from(D).map(async ($) => await new Promise((w) => {
1081
+ const l = new FileReader();
1082
+ l.onload = (O) => {
1083
+ try {
1084
+ i.value.push(O.target.result), G.value++;
1085
+ } catch (L) {
1086
+ console.error("解析失败:", L);
1087
+ return;
1088
+ }
1089
+ }, l.onerror = () => w(`读取 ${$.name} 失败`), l.readAsText($), h.target.value = "", W.value = null, E.value++;
1090
+ }));
1091
+ await Promise.all(b);
1092
+ };
1093
+ return U(
1094
+ () => [e == null ? void 0 : e.content, e == null ? void 0 : e.jsonContents],
1095
+ async () => {
1096
+ await ct(), S.value = e.content, I.value = e == null ? void 0 : e.jsonContents;
1097
+ },
1098
+ { deep: !0, immediate: !0 }
1099
+ ), U(
1100
+ () => G.value,
1101
+ () => {
1102
+ var h;
1103
+ ((h = c.value) == null ? void 0 : h.length) !== 0 && (A.setOriginalData(c.value), A.setItemData(c.value));
1104
+ },
1105
+ { deep: !0, immediate: !0 }
1106
+ ), (h, D) => {
1107
+ const b = y("svg-icon"), $ = y("el-button");
1108
+ return u(), M("div", pa, [
1109
+ (e == null ? void 0 : e.mode) === "edit" ? (u(), M("div", ha, [
1110
+ f("div", fa, [
1111
+ a(De)
1112
+ ]),
1113
+ (u(), M("div", {
1114
+ class: "model-show",
1115
+ key: x.value
1116
+ }, [
1117
+ a(je)
1118
+ ])),
1119
+ f("div", _a, [
1120
+ a(Ve)
1121
+ ])
1122
+ ])) : N("", !0),
1123
+ (e == null ? void 0 : e.mode) === "view" ? (u(), M("div", ga, [
1124
+ (u(), T(ma, {
1125
+ showButton: k.showButton,
1126
+ platform: o(J),
1127
+ content: S.value,
1128
+ onChange: Be,
1129
+ jsonContents: I.value,
1130
+ onContentChange: X,
1131
+ onBuildContent: ve,
1132
+ key: x.value,
1133
+ onShowChild: ce
1134
+ }, {
1135
+ default: n(() => {
1136
+ var w;
1137
+ return [
1138
+ ((w = e == null ? void 0 : e.jsonContents) == null ? void 0 : w.length) === 0 && (e != null && e.showButton) ? (u(), T($, {
1139
+ key: 0,
1140
+ id: "transparentBgButton",
1141
+ onClick: de
1142
+ }, {
1143
+ icon: n(() => [
1144
+ a(b, { name: "import" })
1145
+ ]),
1146
+ default: n(() => [
1147
+ (u(), M("input", {
1148
+ type: "file",
1149
+ key: E.value,
1150
+ ref_key: "fileInput",
1151
+ ref: W,
1152
+ accept: ".txt, .inm, .iml, .imd",
1153
+ onChange: me,
1154
+ style: { display: "none" },
1155
+ multiple: ""
1156
+ }, null, 32)),
1157
+ D[0] || (D[0] = z(" 导入模型 "))
1158
+ ]),
1159
+ _: 1,
1160
+ __: [0]
1161
+ })) : N("", !0)
1162
+ ];
1163
+ }),
1164
+ _: 1
1165
+ }, 8, ["showButton", "platform", "content", "jsonContents"]))
1166
+ ])) : N("", !0)
1167
+ ]);
1168
+ };
1169
+ }
1170
+ }, Na = /* @__PURE__ */ ge(va, [["__scopeId", "data-v-b9caa997"]]);
1171
+ export {
1172
+ Na as default
1173
+ };