ss-component-new 1.3.714 → 1.3.716

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.
Files changed (94) hide show
  1. package/dist/config.js +1 -1
  2. package/dist/index-0g0DP0Sz.js +1044 -0
  3. package/dist/index-BDCuosQJ.js +50 -0
  4. package/dist/index-BxJpjRsQ.js +50711 -0
  5. package/dist/index-C1ELjCn7.js +181 -0
  6. package/dist/index-CEUQmw5e.js +58 -0
  7. package/dist/index-CndLgFR1.js +35 -0
  8. package/dist/index-DlDwzFUG.js +213 -0
  9. package/dist/{index-ChNfRlIP.js → index-DyhB-cd1.js} +253 -18
  10. package/dist/index-IoMa0kLh.js +27 -0
  11. package/dist/menu-HTA6NZEd.js +5208 -0
  12. package/dist/platform-DoyWecim.js +11429 -0
  13. package/dist/ss-component.css +2 -8
  14. package/dist/ss-component.js +28 -64
  15. package/dist/ss-component2.js +15 -75
  16. package/dist/ss-component3.js +1 -1
  17. package/package.json +10 -8
  18. package/public/config.js +1 -1
  19. package/dist/JSEncrypt-B36c1iN5.js +0 -1983
  20. package/dist/MTLLoader-CkNZudBE.js +0 -657
  21. package/dist/URDFLoader-DIzEVzUD.js +0 -2299
  22. package/dist/__vite-browser-external-DYxpcVy9.js +0 -4
  23. package/dist/animationData-DvL_4GZ5.js +0 -83
  24. package/dist/array-BN2tTnqd.js +0 -1045
  25. package/dist/clone-Dp_gc9ll.js +0 -8
  26. package/dist/eleIcon-qStmsM1q.js +0 -29
  27. package/dist/fileUtil-UOt_otFo.js +0 -20
  28. package/dist/iconfont-BwY2qVoK.js +0 -1030
  29. package/dist/icons/svg/functionList.svg +0 -1
  30. package/dist/icons/svg/method.svg +0 -1
  31. package/dist/index-11kpzK0A.js +0 -209
  32. package/dist/index-5S_ATziA.js +0 -25341
  33. package/dist/index-B0H3C7WG.js +0 -103
  34. package/dist/index-B6ePvQgB.js +0 -83
  35. package/dist/index-BHtNKL1L.js +0 -27
  36. package/dist/index-BbyrFzEO.js +0 -93
  37. package/dist/index-Bej2dPck.js +0 -873
  38. package/dist/index-BooO2Bml.js +0 -78
  39. package/dist/index-BqZj6gM7.js +0 -470
  40. package/dist/index-Bw3sTXPI.js +0 -8993
  41. package/dist/index-BzUgGzuc.js +0 -48
  42. package/dist/index-C9nks7xM.js +0 -30
  43. package/dist/index-CGi0g-VN.js +0 -627
  44. package/dist/index-CV_jQDcg.js +0 -9
  45. package/dist/index-CWOXvFfD.js +0 -44
  46. package/dist/index-CYwlat81.js +0 -20578
  47. package/dist/index-Cflxz2Xv.js +0 -572
  48. package/dist/index-Ch8te5LO.js +0 -411
  49. package/dist/index-Ckqlxqaw.js +0 -119
  50. package/dist/index-CpGn7sfE.js +0 -93
  51. package/dist/index-CydXQbtX.js +0 -622
  52. package/dist/index-DAJxL40d.js +0 -55
  53. package/dist/index-DBsEVMiM.js +0 -201
  54. package/dist/index-DG4hoOWt.js +0 -665
  55. package/dist/index-DUbk5m5P.js +0 -99
  56. package/dist/index-DbHIH067.js +0 -107
  57. package/dist/index-Dhjj5seQ.js +0 -98
  58. package/dist/index-Ds6m_4JJ.js +0 -28500
  59. package/dist/index-DupTchhl.js +0 -1000
  60. package/dist/index-DyCq_odP.js +0 -331
  61. package/dist/index-Ru-cNTPj.js +0 -84
  62. package/dist/index-UB_oCdlo.js +0 -62
  63. package/dist/index-XcH1poa0.js +0 -63306
  64. package/dist/index-YjBTGOkO.js +0 -61
  65. package/dist/index-jbOjjV0j.js +0 -447
  66. package/dist/index-rlStojTL.js +0 -52
  67. package/dist/index-uF-ibwG0.js +0 -9
  68. package/dist/index.vue_vue_type_style_index_0_scoped_05e3a1d8_lang-C2itW9KG.js +0 -137927
  69. package/dist/isString-0ZglyOfu.js +0 -8
  70. package/dist/localIcon-D5UoFBU5.js +0 -76
  71. package/dist/main-BCc8TzAj.js +0 -502
  72. package/dist/menuIndex-BB0uVPRX.js +0 -159
  73. package/dist/obj/model.mtl +0 -42
  74. package/dist/obj/model.obj +0 -26110
  75. package/dist/pyodide-Dc1Mu-0d.js +0 -489
  76. package/dist/request-1RPa2bBn.js +0 -9048
  77. package/dist/threeModel-BXXLFYOy.js +0 -1109
  78. package/dist/threePreview-DUfFZQ5q.js +0 -3091
  79. package/dist/threeSceneView-Dez2tha0.js +0 -1290
  80. package/dist/threeSceneViewForCPMPIP-DDk128w_.js +0 -539
  81. package/dist/threeTrackPathView-DmE9QE_0.js +0 -620
  82. package/dist/threeViewerHost-7g8xu3oh.js +0 -233
  83. package/dist/urdfTree-VRms7Vm3.js +0 -254
  84. package/dist/workpieceTreePanel-DCSz_IDY.js +0 -559
  85. package/public/icons/svg/functionList.svg +0 -1
  86. package/public/icons/svg/method.svg +0 -1
  87. package/public/obj/model.mtl +0 -42
  88. package/public/obj/model.obj +0 -26110
  89. /package/dist/icons/svg/{tableClose.svg → table-close.svg} +0 -0
  90. /package/dist/icons/svg/{tableExpand.svg → table-expand.svg} +0 -0
  91. /package/dist/icons/svg/{Update.svg → update.svg} +0 -0
  92. /package/public/icons/svg/{tableClose.svg → table-close.svg} +0 -0
  93. /package/public/icons/svg/{tableExpand.svg → table-expand.svg} +0 -0
  94. /package/public/icons/svg/{Update.svg → update.svg} +0 -0
@@ -1,489 +0,0 @@
1
- var Ee = Object.defineProperty, s = (e, t) => Ee(e, "name", { value: t, configurable: !0 }), W = ((e) => typeof require < "u" ? require : typeof Proxy < "u" ? new Proxy(e, { get: (t, r) => (typeof require < "u" ? require : t)[r] }) : e)(function(e) {
2
- if (typeof require < "u") return require.apply(this, arguments);
3
- throw Error('Dynamic require of "' + e + '" is not supported');
4
- }), be = (() => {
5
- for (var e = new Uint8Array(128), t = 0; t < 64; t++) e[t < 26 ? t + 65 : t < 52 ? t + 71 : t < 62 ? t - 4 : t * 4 - 205] = t;
6
- return (r) => {
7
- for (var a = r.length, i = new Uint8Array((a - (r[a - 1] == "=") - (r[a - 2] == "=")) * 3 / 4 | 0), n = 0, o = 0; n < a; ) {
8
- var l = e[r.charCodeAt(n++)], c = e[r.charCodeAt(n++)], u = e[r.charCodeAt(n++)], d = e[r.charCodeAt(n++)];
9
- i[o++] = l << 2 | c >> 4, i[o++] = c << 4 | u >> 2, i[o++] = u << 6 | d;
10
- }
11
- return i;
12
- };
13
- })();
14
- function M(e) {
15
- return !isNaN(parseFloat(e)) && isFinite(e);
16
- }
17
- s(M, "_isNumber");
18
- function g(e) {
19
- return e.charAt(0).toUpperCase() + e.substring(1);
20
- }
21
- s(g, "_capitalize");
22
- function F(e) {
23
- return function() {
24
- return this[e];
25
- };
26
- }
27
- s(F, "_getter");
28
- var N = ["isConstructor", "isEval", "isNative", "isToplevel"], _ = ["columnNumber", "lineNumber"], S = ["fileName", "functionName", "source"], Ne = ["args"], _e = ["evalOrigin"], k = N.concat(_, S, Ne, _e);
29
- function p(e) {
30
- if (e) for (var t = 0; t < k.length; t++) e[k[t]] !== void 0 && this["set" + g(k[t])](e[k[t]]);
31
- }
32
- s(p, "StackFrame");
33
- p.prototype = { getArgs: s(function() {
34
- return this.args;
35
- }, "getArgs"), setArgs: s(function(e) {
36
- if (Object.prototype.toString.call(e) !== "[object Array]") throw new TypeError("Args must be an Array");
37
- this.args = e;
38
- }, "setArgs"), getEvalOrigin: s(function() {
39
- return this.evalOrigin;
40
- }, "getEvalOrigin"), setEvalOrigin: s(function(e) {
41
- if (e instanceof p) this.evalOrigin = e;
42
- else if (e instanceof Object) this.evalOrigin = new p(e);
43
- else throw new TypeError("Eval Origin must be an Object or StackFrame");
44
- }, "setEvalOrigin"), toString: s(function() {
45
- var e = this.getFileName() || "", t = this.getLineNumber() || "", r = this.getColumnNumber() || "", a = this.getFunctionName() || "";
46
- return this.getIsEval() ? e ? "[eval] (" + e + ":" + t + ":" + r + ")" : "[eval]:" + t + ":" + r : a ? a + " (" + e + ":" + t + ":" + r + ")" : e + ":" + t + ":" + r;
47
- }, "toString") };
48
- p.fromString = s(function(e) {
49
- var t = e.indexOf("("), r = e.lastIndexOf(")"), a = e.substring(0, t), i = e.substring(t + 1, r).split(","), n = e.substring(r + 1);
50
- if (n.indexOf("@") === 0) var o = /@(.+?)(?::(\d+))?(?::(\d+))?$/.exec(n, ""), l = o[1], c = o[2], u = o[3];
51
- return new p({ functionName: a, args: i || void 0, fileName: l, lineNumber: c || void 0, columnNumber: u || void 0 });
52
- }, "StackFrame$$fromString");
53
- for (w = 0; w < N.length; w++) p.prototype["get" + g(N[w])] = F(N[w]), p.prototype["set" + g(N[w])] = /* @__PURE__ */ function(e) {
54
- return function(t) {
55
- this[e] = !!t;
56
- };
57
- }(N[w]);
58
- var w;
59
- for (v = 0; v < _.length; v++) p.prototype["get" + g(_[v])] = F(_[v]), p.prototype["set" + g(_[v])] = /* @__PURE__ */ function(e) {
60
- return function(t) {
61
- if (!M(t)) throw new TypeError(e + " must be a Number");
62
- this[e] = Number(t);
63
- };
64
- }(_[v]);
65
- var v;
66
- for (E = 0; E < S.length; E++) p.prototype["get" + g(S[E])] = F(S[E]), p.prototype["set" + g(S[E])] = /* @__PURE__ */ function(e) {
67
- return function(t) {
68
- this[e] = String(t);
69
- };
70
- }(S[E]);
71
- var E, R = p;
72
- function B() {
73
- var e = /^\s*at .*(\S+:\d+|\(native\))/m, t = /^(eval@)?(\[native code])?$/;
74
- return { parse: s(function(r) {
75
- if (r.stack && r.stack.match(e)) return this.parseV8OrIE(r);
76
- if (r.stack) return this.parseFFOrSafari(r);
77
- throw new Error("Cannot parse given Error object");
78
- }, "ErrorStackParser$$parse"), extractLocation: s(function(r) {
79
- if (r.indexOf(":") === -1) return [r];
80
- var a = /(.+?)(?::(\d+))?(?::(\d+))?$/, i = a.exec(r.replace(/[()]/g, ""));
81
- return [i[1], i[2] || void 0, i[3] || void 0];
82
- }, "ErrorStackParser$$extractLocation"), parseV8OrIE: s(function(r) {
83
- var a = r.stack.split(`
84
- `).filter(function(i) {
85
- return !!i.match(e);
86
- }, this);
87
- return a.map(function(i) {
88
- i.indexOf("(eval ") > -1 && (i = i.replace(/eval code/g, "eval").replace(/(\(eval at [^()]*)|(,.*$)/g, ""));
89
- var n = i.replace(/^\s+/, "").replace(/\(eval code/g, "(").replace(/^.*?\s+/, ""), o = n.match(/ (\(.+\)$)/);
90
- n = o ? n.replace(o[0], "") : n;
91
- var l = this.extractLocation(o ? o[1] : n), c = o && n || void 0, u = ["eval", "<anonymous>"].indexOf(l[0]) > -1 ? void 0 : l[0];
92
- return new R({ functionName: c, fileName: u, lineNumber: l[1], columnNumber: l[2], source: i });
93
- }, this);
94
- }, "ErrorStackParser$$parseV8OrIE"), parseFFOrSafari: s(function(r) {
95
- var a = r.stack.split(`
96
- `).filter(function(i) {
97
- return !i.match(t);
98
- }, this);
99
- return a.map(function(i) {
100
- if (i.indexOf(" > eval") > -1 && (i = i.replace(/ line (\d+)(?: > eval line \d+)* > eval:\d+:\d+/g, ":$1")), i.indexOf("@") === -1 && i.indexOf(":") === -1) return new R({ functionName: i });
101
- var n = /((.*".+"[^@]*)?[^@]*)(?:@)/, o = i.match(n), l = o && o[1] ? o[1] : void 0, c = this.extractLocation(i.replace(n, ""));
102
- return new R({ functionName: l, fileName: c[0], lineNumber: c[1], columnNumber: c[2], source: i });
103
- }, this);
104
- }, "ErrorStackParser$$parseFFOrSafari") };
105
- }
106
- s(B, "ErrorStackParser");
107
- var Se = new B(), Ie = Se;
108
- function $() {
109
- var o;
110
- if (typeof API < "u" && API !== globalThis.API) return API.runtimeEnv;
111
- let e = typeof Bun < "u", t = typeof Deno < "u", r = typeof process == "object" && typeof process.versions == "object" && typeof process.versions.node == "string" && !process.browser, a = typeof navigator == "object" && typeof navigator.userAgent == "string" && navigator.userAgent.indexOf("Chrome") === -1 && navigator.userAgent.indexOf("Safari") > -1, i = typeof read == "function" && typeof load == "function", n = typeof navigator == "object" && ((o = navigator.userAgent) == null ? void 0 : o.includes("Cloudflare-Workers"));
112
- return j({ IN_BUN: e, IN_DENO: t, IN_NODE: r, IN_SAFARI: a, IN_SHELL: i, IN_WORKERD: n });
113
- }
114
- s($, "getGlobalRuntimeEnv");
115
- var m = $();
116
- function j(e) {
117
- let t = e.IN_NODE && typeof module < "u" && module.exports && typeof W == "function" && typeof __dirname == "string", r = e.IN_NODE && !t, a = !e.IN_NODE && !e.IN_DENO && !e.IN_BUN, i = a && typeof window < "u" && typeof window.document < "u" && typeof document.createElement == "function" && "sessionStorage" in window && typeof globalThis.importScripts != "function", n = a && typeof globalThis.WorkerGlobalScope < "u" && typeof globalThis.self < "u" && globalThis.self instanceof globalThis.WorkerGlobalScope;
118
- if (n && H()) throw new Error("Classic web workers are not supported");
119
- let o = { ...e, IN_BROWSER: a, IN_BROWSER_MAIN_THREAD: i, IN_BROWSER_WEB_WORKER: n, IN_NODE_COMMONJS: t, IN_NODE_ESM: r };
120
- if (!(o.IN_BROWSER_MAIN_THREAD || o.IN_BROWSER_WEB_WORKER || o.IN_NODE || o.IN_SHELL || o.IN_WORKERD)) throw new Error(`Cannot determine runtime environment: ${JSON.stringify(o)}`);
121
- return o;
122
- }
123
- s(j, "calculateDerivedFlags");
124
- function H() {
125
- try {
126
- return globalThis.importScripts("data:text/javascript,"), !0;
127
- } catch {
128
- return !1;
129
- }
130
- }
131
- s(H, "isClassicWorker");
132
- var J, D, U, x;
133
- async function C() {
134
- if (!m.IN_NODE || (J = (await import("./__vite-browser-external-DYxpcVy9.js")).default, U = await import("./__vite-browser-external-DYxpcVy9.js"), x = await import("./__vite-browser-external-DYxpcVy9.js"), (await import("./__vite-browser-external-DYxpcVy9.js")).default, D = await import("./__vite-browser-external-DYxpcVy9.js"), T = D.sep, typeof W < "u")) return;
135
- let e = U, t = await import("./__vite-browser-external-DYxpcVy9.js"), r = await import("./__vite-browser-external-DYxpcVy9.js"), a = await import("./__vite-browser-external-DYxpcVy9.js"), i = { fs: e, crypto: t, ws: r, child_process: a };
136
- globalThis.require = function(n) {
137
- return i[n];
138
- };
139
- }
140
- s(C, "initNodeModules");
141
- function z(e, t) {
142
- return D.resolve(t || ".", e);
143
- }
144
- s(z, "node_resolvePath");
145
- function V(e, t) {
146
- return t === void 0 && (t = location), new URL(e, t).toString();
147
- }
148
- s(V, "browser_resolvePath");
149
- var O;
150
- m.IN_NODE ? O = z : m.IN_SHELL ? O = s((e) => e, "resolvePath") : O = V;
151
- var T;
152
- m.IN_NODE || (T = "/");
153
- function G(e, t) {
154
- return e.startsWith("file://") && (e = e.slice(7)), e.includes("://") ? { response: fetch(e) } : { binary: x.readFile(e).then((r) => new Uint8Array(r.buffer, r.byteOffset, r.byteLength)) };
155
- }
156
- s(G, "node_getBinaryResponse");
157
- function q(e, t) {
158
- if (e.startsWith("file://") && (e = e.slice(7)), e.includes("://")) throw new Error("Shell cannot fetch urls");
159
- return { binary: Promise.resolve(new Uint8Array(readbuffer(e))) };
160
- }
161
- s(q, "shell_getBinaryResponse");
162
- function K(e, t) {
163
- let r = new URL(e, location);
164
- return { response: fetch(r, t ? { integrity: t } : {}) };
165
- }
166
- s(K, "browser_getBinaryResponse");
167
- var A;
168
- m.IN_NODE ? A = G : m.IN_SHELL ? A = q : A = K;
169
- async function Q(e, t) {
170
- let { response: r, binary: a } = A(e, t);
171
- if (a) return a;
172
- let i = await r;
173
- if (!i.ok) throw new Error(`Failed to load '${e}': request failed.`);
174
- return new Uint8Array(await i.arrayBuffer());
175
- }
176
- s(Q, "loadBinaryFile");
177
- var P;
178
- m.IN_NODE ? P = Y : P = s(async (e) => await import(e), "loadScript");
179
- async function Y(e) {
180
- return e.startsWith("file://") && (e = e.slice(7)), e.includes("://") ? await import(e) : await import(J.pathToFileURL(e).href);
181
- }
182
- s(Y, "nodeLoadScript");
183
- async function X(e) {
184
- if (m.IN_NODE) {
185
- await C();
186
- let t = await x.readFile(e, { encoding: "utf8" });
187
- return JSON.parse(t);
188
- } else if (m.IN_SHELL) {
189
- let t = read(e);
190
- return JSON.parse(t);
191
- } else return await (await fetch(e)).json();
192
- }
193
- s(X, "loadLockFile");
194
- async function Z() {
195
- if (m.IN_NODE_COMMONJS) return __dirname;
196
- let e;
197
- try {
198
- throw new Error();
199
- } catch (a) {
200
- e = a;
201
- }
202
- let t = Ie.parse(e)[0].fileName;
203
- if (m.IN_NODE && !t.startsWith("file://") && (t = `file://${t}`), m.IN_NODE_ESM) {
204
- let a = await import("./__vite-browser-external-DYxpcVy9.js");
205
- return (await import("./__vite-browser-external-DYxpcVy9.js")).fileURLToPath(a.dirname(t));
206
- }
207
- let r = t.lastIndexOf(T);
208
- if (r === -1) throw new Error("Could not extract indexURL path from pyodide module location. Please pass the indexURL explicitly to loadPyodide.");
209
- return t.slice(0, r);
210
- }
211
- s(Z, "calculateDirname");
212
- function ee(e) {
213
- var t;
214
- return e.substring(0, e.lastIndexOf("/") + 1) || ((t = globalThis.location) == null ? void 0 : t.toString()) || ".";
215
- }
216
- s(ee, "calculateInstallBaseUrl");
217
- function te(e) {
218
- let t = e.FS, r = e.FS.filesystems.MEMFS, a = e.PATH, i = { DIR_MODE: 16895, FILE_MODE: 33279, mount: s(function(n) {
219
- if (!n.opts.fileSystemHandle) throw new Error("opts.fileSystemHandle is required");
220
- return r.mount.apply(null, arguments);
221
- }, "mount"), syncfs: s(async (n, o, l) => {
222
- try {
223
- let c = i.getLocalSet(n), u = await i.getRemoteSet(n), d = o ? u : c, y = o ? c : u;
224
- await i.reconcile(n, d, y), l(null);
225
- } catch (c) {
226
- l(c);
227
- }
228
- }, "syncfs"), getLocalSet: s((n) => {
229
- let o = /* @__PURE__ */ Object.create(null);
230
- function l(d) {
231
- return d !== "." && d !== "..";
232
- }
233
- s(l, "isRealDir");
234
- function c(d) {
235
- return (y) => a.join2(d, y);
236
- }
237
- s(c, "toAbsolute");
238
- let u = t.readdir(n.mountpoint).filter(l).map(c(n.mountpoint));
239
- for (; u.length; ) {
240
- let d = u.pop(), y = t.stat(d);
241
- t.isDir(y.mode) && u.push.apply(u, t.readdir(d).filter(l).map(c(d))), o[d] = { timestamp: y.mtime, mode: y.mode };
242
- }
243
- return { type: "local", entries: o };
244
- }, "getLocalSet"), getRemoteSet: s(async (n) => {
245
- let o = /* @__PURE__ */ Object.create(null), l = await Oe(n.opts.fileSystemHandle);
246
- for (let [c, u] of l) c !== "." && (o[a.join2(n.mountpoint, c)] = { timestamp: u.kind === "file" ? new Date((await u.getFile()).lastModified) : /* @__PURE__ */ new Date(), mode: u.kind === "file" ? i.FILE_MODE : i.DIR_MODE });
247
- return { type: "remote", entries: o, handles: l };
248
- }, "getRemoteSet"), loadLocalEntry: s((n) => {
249
- let o = t.lookupPath(n, {}).node, l = t.stat(n);
250
- if (t.isDir(l.mode)) return { timestamp: l.mtime, mode: l.mode };
251
- if (t.isFile(l.mode)) return o.contents = r.getFileDataAsTypedArray(o), { timestamp: l.mtime, mode: l.mode, contents: o.contents };
252
- throw new Error("node type not supported");
253
- }, "loadLocalEntry"), storeLocalEntry: s((n, o) => {
254
- if (t.isDir(o.mode)) t.mkdirTree(n, o.mode);
255
- else if (t.isFile(o.mode)) t.writeFile(n, o.contents, { canOwn: !0 });
256
- else throw new Error("node type not supported");
257
- t.chmod(n, o.mode), t.utime(n, o.timestamp, o.timestamp);
258
- }, "storeLocalEntry"), removeLocalEntry: s((n) => {
259
- var o = t.stat(n);
260
- t.isDir(o.mode) ? t.rmdir(n) : t.isFile(o.mode) && t.unlink(n);
261
- }, "removeLocalEntry"), loadRemoteEntry: s(async (n) => {
262
- if (n.kind === "file") {
263
- let o = await n.getFile();
264
- return { contents: new Uint8Array(await o.arrayBuffer()), mode: i.FILE_MODE, timestamp: new Date(o.lastModified) };
265
- } else {
266
- if (n.kind === "directory") return { mode: i.DIR_MODE, timestamp: /* @__PURE__ */ new Date() };
267
- throw new Error("unknown kind: " + n.kind);
268
- }
269
- }, "loadRemoteEntry"), storeRemoteEntry: s(async (n, o, l) => {
270
- let c = n.get(a.dirname(o)), u = t.isFile(l.mode) ? await c.getFileHandle(a.basename(o), { create: !0 }) : await c.getDirectoryHandle(a.basename(o), { create: !0 });
271
- if (u.kind === "file") {
272
- let d = await u.createWritable();
273
- await d.write(l.contents), await d.close();
274
- }
275
- n.set(o, u);
276
- }, "storeRemoteEntry"), removeRemoteEntry: s(async (n, o) => {
277
- await n.get(a.dirname(o)).removeEntry(a.basename(o)), n.delete(o);
278
- }, "removeRemoteEntry"), reconcile: s(async (n, o, l) => {
279
- let c = 0, u = [];
280
- Object.keys(o.entries).forEach(function(f) {
281
- let h = o.entries[f], b = l.entries[f];
282
- (!b || t.isFile(h.mode) && h.timestamp.getTime() > b.timestamp.getTime()) && (u.push(f), c++);
283
- }), u.sort();
284
- let d = [];
285
- if (Object.keys(l.entries).forEach(function(f) {
286
- o.entries[f] || (d.push(f), c++);
287
- }), d.sort().reverse(), !c) return;
288
- let y = o.type === "remote" ? o.handles : l.handles;
289
- for (let f of u) {
290
- let h = a.normalize(f.replace(n.mountpoint, "/")).substring(1);
291
- if (l.type === "local") {
292
- let b = y.get(h), ve = await i.loadRemoteEntry(b);
293
- i.storeLocalEntry(f, ve);
294
- } else {
295
- let b = i.loadLocalEntry(f);
296
- await i.storeRemoteEntry(y, h, b);
297
- }
298
- }
299
- for (let f of d) if (l.type === "local") i.removeLocalEntry(f);
300
- else {
301
- let h = a.normalize(f.replace(n.mountpoint, "/")).substring(1);
302
- await i.removeRemoteEntry(y, h);
303
- }
304
- }, "reconcile") };
305
- e.FS.filesystems.NATIVEFS_ASYNC = i;
306
- }
307
- s(te, "initializeNativeFS");
308
- var Oe = s(async (e) => {
309
- let t = [];
310
- async function r(i) {
311
- for await (let n of i.values()) t.push(n), n.kind === "directory" && await r(n);
312
- }
313
- s(r, "collect"), await r(e);
314
- let a = /* @__PURE__ */ new Map();
315
- a.set(".", e);
316
- for (let i of t) {
317
- let n = (await e.resolve(i)).join("/");
318
- a.set(n, i);
319
- }
320
- return a;
321
- }, "getFsHandles"), Ae = be("AGFzbQEAAAABDANfAGAAAW9gAW8BfwMDAgECBygCE0pzdl9HZXRFcnJvcl9pbXBvcnQAAA5Kc3ZFcnJvcl9DaGVjawABChMCBwD7AQD7GwsJACAA+xr7FAAL"), ke = async function() {
322
- if (!(globalThis.navigator && (/iPad|iPhone|iPod/.test(navigator.userAgent) || navigator.platform === "MacIntel" && typeof navigator.maxTouchPoints < "u" && navigator.maxTouchPoints > 1))) try {
323
- let e = await WebAssembly.compile(Ae);
324
- return await WebAssembly.instantiate(e);
325
- } catch (e) {
326
- if (e instanceof WebAssembly.CompileError) return;
327
- throw e;
328
- }
329
- }();
330
- async function re() {
331
- let e = await ke;
332
- if (e) return e.exports;
333
- let t = Symbol("error marker");
334
- return { Jsv_GetError_import: s(() => t, "Jsv_GetError_import"), JsvError_Check: s((r) => r === t, "JsvError_Check") };
335
- }
336
- s(re, "getJsvErrorImport");
337
- function ne(e) {
338
- let t = { config: e, runtimeEnv: m }, r = { noImageDecoding: !0, noAudioDecoding: !0, noWasmDecoding: !1, preRun: ce(e), print: e.stdout, printErr: e.stderr, onExit(a) {
339
- r.exitCode = a;
340
- }, thisProgram: e._sysExecutable, arguments: e.args, API: t, locateFile: s((a) => e.indexURL + a, "locateFile"), instantiateWasm: ue(e.indexURL) };
341
- return r;
342
- }
343
- s(ne, "createSettings");
344
- function ie(e) {
345
- return function(t) {
346
- let r = "/";
347
- try {
348
- t.FS.mkdirTree(e);
349
- } catch (a) {
350
- console.error(`Error occurred while making a home directory '${e}':`), console.error(a), console.error(`Using '${r}' for a home directory instead`), e = r;
351
- }
352
- t.FS.chdir(e);
353
- };
354
- }
355
- s(ie, "createHomeDirectory");
356
- function oe(e) {
357
- return function(t) {
358
- Object.assign(t.ENV, e);
359
- };
360
- }
361
- s(oe, "setEnvironment");
362
- function ae(e) {
363
- return e ? [async (t) => {
364
- t.addRunDependency("fsInitHook");
365
- try {
366
- await e(t.FS, { sitePackages: t.API.sitePackages });
367
- } finally {
368
- t.removeRunDependency("fsInitHook");
369
- }
370
- }] : [];
371
- }
372
- s(ae, "callFsInitHook");
373
- function se(e) {
374
- let t = e.HEAPU32[e._Py_Version >>> 2], r = t >>> 24 & 255, a = t >>> 16 & 255, i = t >>> 8 & 255;
375
- return [r, a, i];
376
- }
377
- s(se, "computeVersionTuple");
378
- function le(e) {
379
- let t = Q(e);
380
- return async (r) => {
381
- r.API.pyVersionTuple = se(r);
382
- let [a, i] = r.API.pyVersionTuple;
383
- r.FS.mkdirTree("/lib"), r.API.sitePackages = `/lib/python${a}.${i}/site-packages`, r.FS.mkdirTree(r.API.sitePackages), r.addRunDependency("install-stdlib");
384
- try {
385
- let n = await t;
386
- r.FS.writeFile(`/lib/python${a}${i}.zip`, n);
387
- } catch (n) {
388
- console.error("Error occurred while installing the standard library:"), console.error(n);
389
- } finally {
390
- r.removeRunDependency("install-stdlib");
391
- }
392
- };
393
- }
394
- s(le, "installStdlib");
395
- function ce(e) {
396
- let t;
397
- return e.stdLibURL != null ? t = e.stdLibURL : t = e.indexURL + "python_stdlib.zip", [le(t), ie(e.env.HOME), oe(e.env), te, ...ae(e.fsInit)];
398
- }
399
- s(ce, "getFileSystemInitializationFuncs");
400
- function ue(e) {
401
- if (typeof WasmOffsetConverter < "u") return;
402
- let { binary: t, response: r } = A(e + "pyodide.asm.wasm"), a = re();
403
- return function(i, n) {
404
- return async function() {
405
- let { Jsv_GetError_import: o, JsvError_Check: l } = await a;
406
- i.env.Jsv_GetError_import = o, i.env.JsvError_Check = l;
407
- try {
408
- let c;
409
- r ? c = await WebAssembly.instantiateStreaming(r, i) : c = await WebAssembly.instantiate(await t, i);
410
- let { instance: u, module: d } = c;
411
- n(u, d);
412
- } catch (c) {
413
- console.warn("wasm instantiation failed!"), console.warn(c);
414
- }
415
- }(), {};
416
- };
417
- }
418
- s(ue, "getInstantiateWasmFunc");
419
- var Fe = "314.0.2";
420
- function I(e) {
421
- return e === void 0 || e.endsWith("/") ? e : e + "/";
422
- }
423
- s(I, "withTrailingSlash");
424
- var L = Fe;
425
- async function de(e = {}) {
426
- var i, n;
427
- if (await C(), e.lockFileContents && e.lockFileURL) throw new Error("Can't pass both lockFileContents and lockFileURL");
428
- let t = e.indexURL || await Z();
429
- if (t = I(O(t)), e.packageBaseUrl = I(e.packageBaseUrl), e.cdnUrl = I(e.packageBaseUrl ?? `https://cdn.jsdelivr.net/pyodide/v${L}/full/`), !e.lockFileContents) {
430
- let o = e.lockFileURL ?? t + "pyodide-lock.json";
431
- e.lockFileContents = X(o), e.packageBaseUrl ?? (e.packageBaseUrl = ee(o));
432
- }
433
- e.indexURL = t, e.packageCacheDir && (e.packageCacheDir = I(O(e.packageCacheDir)));
434
- let r = { jsglobals: globalThis, stdin: globalThis.prompt ? () => globalThis.prompt() : void 0, args: [], env: {}, packages: [], packageCacheDir: e.packageBaseUrl, enableRunUntilComplete: !0, checkAPIVersion: !0, BUILD_ID: "a4189f0fe3d610ecd603639c08596362b70a34b106c58c9a93486c22df4c89a5" }, a = Object.assign(r, e);
435
- return (i = a.env).HOME ?? (i.HOME = "/home/pyodide"), (n = a.env).PYTHONINSPECT ?? (n.PYTHONINSPECT = "1"), a;
436
- }
437
- s(de, "initializeConfiguration");
438
- function fe(e) {
439
- let t = ne(e), r = t.API;
440
- return r.lockFilePromise = Promise.resolve(e.lockFileContents), t;
441
- }
442
- s(fe, "createEmscriptenSettings");
443
- async function pe(e) {
444
- if (e.createPyodideModule) return e.createPyodideModule;
445
- let t = `${e.indexURL}pyodide.asm.mjs`;
446
- return (await P(t)).default;
447
- }
448
- s(pe, "loadWasmScript");
449
- async function me(e, t) {
450
- if (!e._loadSnapshot) return;
451
- let r = await e._loadSnapshot, a = ArrayBuffer.isView(r) ? r : new Uint8Array(r);
452
- return t.noInitialRun = !0, t.INITIAL_MEMORY = a.length, a;
453
- }
454
- s(me, "prepareSnapshot");
455
- async function ye(e, t) {
456
- let r = await e(t);
457
- if (t.exitCode !== void 0) throw new r.ExitStatus(t.exitCode);
458
- return r;
459
- }
460
- s(ye, "instantiatePyodideModule");
461
- function ge(e, t) {
462
- let r = e.API;
463
- if (t.pyproxyToStringRepr && r.setPyProxyToStringMethod(!0), t.convertNullToNone && r.setCompatNullToNone(!0), t.toJsLiteralMap && r.setCompatToJsLiteralMap(!0), r.version !== L && t.checkAPIVersion) throw new Error(`Pyodide version does not match: '${L}' <==> '${r.version}'. If you updated the Pyodide version, make sure you also updated the 'indexURL' parameter passed to loadPyodide.`);
464
- e.locateFile = (a) => {
465
- throw a.endsWith(".so") ? new Error(`Failed to find dynamic library "${a}"`) : new Error(`Unexpected call to locateFile("${a}")`);
466
- };
467
- }
468
- s(ge, "configureAPI");
469
- function he(e, t, r) {
470
- let a = e.API, i;
471
- return t && (i = a.restoreSnapshot(t)), a.finalizeBootstrap(i, r._snapshotDeserializer);
472
- }
473
- s(he, "bootstrapPyodide");
474
- async function we(e, t) {
475
- let r = e._api;
476
- return r.sys.path.insert(0, ""), r._pyodide.set_excepthook(), await r.packageIndexReady, r.initializeStreams(t.stdin, t.stdout, t.stderr), e;
477
- }
478
- s(we, "finalizeSetup");
479
- async function Re(e = {}) {
480
- let t = await de(e), r = fe(t), a = await pe(t), i = await me(t, r), n = await ye(a, r);
481
- ge(n, t);
482
- let o = he(n, i, t);
483
- return await we(o, t);
484
- }
485
- s(Re, "loadPyodide");
486
- export {
487
- Re as loadPyodide,
488
- L as version
489
- };