@myop/vue 0.0.29 → 0.0.30
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +357 -348
- package/dist/index.umd.cjs +7 -7
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -1,42 +1,42 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { containerStyleObject as
|
|
3
|
-
import { CloudRepository as
|
|
4
|
-
const
|
|
1
|
+
import { defineComponent as Z, useSlots as ee, computed as y, createElementBlock as M, openBlock as S, normalizeStyle as B, renderSlot as H, unref as ye, ref as p, shallowRef as ft, watch as ce, onMounted as Te, onUnmounted as pt, createElementVNode as Me, createBlock as Fe, createCommentVNode as de, withCtx as $e, markRaw as Re, useAttrs as dt, getCurrentInstance as mt, reactive as ht, watchEffect as gt, Fragment as yt, mergeProps as _t } from "vue";
|
|
2
|
+
import { containerStyleObject as Ct, loaderStyleObject as vt, getMyopLogoHtml as He, fallbackStyleObject as Et, hostSDK as ze } from "@myop/sdk/host";
|
|
3
|
+
import { CloudRepository as te } from "@myop/sdk/helpers";
|
|
4
|
+
const Nt = ["innerHTML"], bt = /* @__PURE__ */ Z({
|
|
5
5
|
__name: "MyopLoader",
|
|
6
6
|
props: {
|
|
7
7
|
opacity: { default: 1 },
|
|
8
8
|
fadeDuration: { default: 200 }
|
|
9
9
|
},
|
|
10
10
|
setup(e) {
|
|
11
|
-
const t = e, n =
|
|
11
|
+
const t = e, n = ee(), o = (l) => !l || l.length === 0 ? !1 : l.some((c) => typeof c.children == "string" ? c.children.trim() !== "" : Array.isArray(c.children) ? o(c.children) : !!(c.type && typeof c.type != "symbol" || c.children)), s = y(() => {
|
|
12
12
|
const l = n.default;
|
|
13
13
|
if (!l) return !1;
|
|
14
14
|
const c = l();
|
|
15
15
|
return o(c);
|
|
16
16
|
}), r = y(() => ({
|
|
17
|
-
...
|
|
17
|
+
...Ct,
|
|
18
18
|
opacity: t.opacity,
|
|
19
19
|
transition: `opacity ${t.fadeDuration}ms ease-out`
|
|
20
20
|
})), i = y(() => ({
|
|
21
|
-
...
|
|
21
|
+
...vt,
|
|
22
22
|
opacity: t.opacity,
|
|
23
23
|
transition: `opacity ${t.fadeDuration}ms ease-out`
|
|
24
|
-
})), a =
|
|
25
|
-
return (l, c) => s.value ? (
|
|
24
|
+
})), a = He();
|
|
25
|
+
return (l, c) => s.value ? (S(), M("div", {
|
|
26
26
|
key: 0,
|
|
27
|
-
style:
|
|
27
|
+
style: B(r.value)
|
|
28
28
|
}, [
|
|
29
|
-
|
|
30
|
-
], 4)) : (
|
|
29
|
+
H(l.$slots, "default")
|
|
30
|
+
], 4)) : (S(), M("div", {
|
|
31
31
|
key: 1,
|
|
32
|
-
style:
|
|
33
|
-
innerHTML:
|
|
34
|
-
}, null, 12,
|
|
32
|
+
style: B(i.value),
|
|
33
|
+
innerHTML: ye(a)
|
|
34
|
+
}, null, 12, Nt));
|
|
35
35
|
}
|
|
36
|
-
}),
|
|
36
|
+
}), St = ["innerHTML"], wt = /* @__PURE__ */ Z({
|
|
37
37
|
__name: "MyopFallback",
|
|
38
38
|
setup(e) {
|
|
39
|
-
const t =
|
|
39
|
+
const t = ee(), n = (a) => !a || a.length === 0 ? !1 : a.some((l) => typeof l.children == "string" ? l.children.trim() !== "" : Array.isArray(l.children) ? n(l.children) : !!(l.type && typeof l.type != "symbol" || l.children)), o = y(() => {
|
|
40
40
|
const a = t.default;
|
|
41
41
|
if (!a) return !1;
|
|
42
42
|
const l = a();
|
|
@@ -48,20 +48,20 @@ const yt = ["innerHTML"], _t = /* @__PURE__ */ Q({
|
|
|
48
48
|
right: "0",
|
|
49
49
|
bottom: "0"
|
|
50
50
|
}, r = {
|
|
51
|
-
...
|
|
52
|
-
}, i =
|
|
53
|
-
return (a, l) => o.value ? (
|
|
51
|
+
...Et
|
|
52
|
+
}, i = He();
|
|
53
|
+
return (a, l) => o.value ? (S(), M("div", {
|
|
54
54
|
key: 0,
|
|
55
55
|
style: s
|
|
56
56
|
}, [
|
|
57
|
-
|
|
58
|
-
])) : (
|
|
57
|
+
H(a.$slots, "default")
|
|
58
|
+
])) : (S(), M("div", {
|
|
59
59
|
key: 1,
|
|
60
60
|
style: r,
|
|
61
|
-
innerHTML:
|
|
62
|
-
}, null, 8,
|
|
61
|
+
innerHTML: ye(i)
|
|
62
|
+
}, null, 8, St));
|
|
63
63
|
}
|
|
64
|
-
}),
|
|
64
|
+
}), kn = /* @__PURE__ */ Z({
|
|
65
65
|
name: "MyopComponent",
|
|
66
66
|
__name: "MyopComponent",
|
|
67
67
|
props: {
|
|
@@ -69,14 +69,14 @@ const yt = ["innerHTML"], _t = /* @__PURE__ */ Q({
|
|
|
69
69
|
componentConfig: {},
|
|
70
70
|
data: {},
|
|
71
71
|
fadeDuration: { default: 200 },
|
|
72
|
-
autoSize: { type: Boolean, default: !
|
|
72
|
+
autoSize: { type: Boolean, default: !0 },
|
|
73
73
|
environment: {},
|
|
74
74
|
preview: { type: Boolean },
|
|
75
75
|
on: {}
|
|
76
76
|
},
|
|
77
77
|
emits: ["load", "error", "sizeChange", "cta"],
|
|
78
78
|
setup(e, { expose: t, emit: n }) {
|
|
79
|
-
const o =
|
|
79
|
+
const o = ee(), s = (u) => !u || u.length === 0 ? !1 : u.some((f) => typeof f.children == "string" ? f.children.trim() !== "" : Array.isArray(f.children) ? s(f.children) : !!(f.type && typeof f.type != "symbol" || f.children)), r = y(() => {
|
|
80
80
|
const u = o.loader;
|
|
81
81
|
if (!u) return !1;
|
|
82
82
|
const f = u();
|
|
@@ -88,17 +88,17 @@ const yt = ["innerHTML"], _t = /* @__PURE__ */ Q({
|
|
|
88
88
|
const f = u();
|
|
89
89
|
return s(f);
|
|
90
90
|
});
|
|
91
|
-
const i = e, a = n, l =
|
|
92
|
-
let
|
|
93
|
-
const
|
|
91
|
+
const i = e, a = n, l = p(null), c = ft(null), d = i.componentId ? En(i.componentId) : !1, g = p(!d), V = p(1), E = p(!1), I = p(!1), D = p(void 0), Se = p({ fillWidth: !1, fillHeight: !1 }), se = p(!1), L = p(null);
|
|
92
|
+
let $ = null;
|
|
93
|
+
const ie = () => {
|
|
94
94
|
V.value = 0, setTimeout(() => {
|
|
95
95
|
g.value = !1;
|
|
96
96
|
}, i.fadeDuration);
|
|
97
|
-
},
|
|
98
|
-
console.error("[MyopComponent] Error:", u),
|
|
99
|
-
},
|
|
100
|
-
var N,
|
|
101
|
-
|
|
97
|
+
}, le = (u) => {
|
|
98
|
+
console.error("[MyopComponent] Error:", u), ie(), E.value = !0, a("error", u);
|
|
99
|
+
}, ae = async (u) => {
|
|
100
|
+
var N, U, Oe;
|
|
101
|
+
se.value = !0;
|
|
102
102
|
let f = !1;
|
|
103
103
|
try {
|
|
104
104
|
const m = JSON.parse(JSON.stringify({
|
|
@@ -109,143 +109,152 @@ const yt = ["innerHTML"], _t = /* @__PURE__ */ Q({
|
|
|
109
109
|
autoSize: u.autoSize
|
|
110
110
|
}));
|
|
111
111
|
if (!m.componentId && !u.componentConfig) {
|
|
112
|
-
|
|
112
|
+
le("No component configuration provided");
|
|
113
113
|
return;
|
|
114
114
|
}
|
|
115
|
-
const
|
|
115
|
+
const at = m.preview === !0 ? !0 : void 0, ct = u.componentConfig ? JSON.parse(JSON.stringify(u.componentConfig)) : await vn().fetchComponentV2(
|
|
116
116
|
m.componentId,
|
|
117
117
|
m.environment,
|
|
118
|
-
|
|
118
|
+
at
|
|
119
119
|
);
|
|
120
120
|
if (!l.value) {
|
|
121
|
-
|
|
121
|
+
le("Container element not found");
|
|
122
122
|
return;
|
|
123
123
|
}
|
|
124
|
-
const
|
|
124
|
+
const ut = Re({
|
|
125
125
|
data: m.data,
|
|
126
126
|
_environment: {
|
|
127
127
|
props: m
|
|
128
128
|
}
|
|
129
|
-
}),
|
|
130
|
-
|
|
129
|
+
}), ke = await ze.loadComponent(
|
|
130
|
+
ct,
|
|
131
131
|
l.value,
|
|
132
|
-
|
|
132
|
+
ut
|
|
133
133
|
);
|
|
134
134
|
if (f) {
|
|
135
|
-
|
|
135
|
+
ke.dispose();
|
|
136
136
|
return;
|
|
137
137
|
}
|
|
138
|
-
if (c.value =
|
|
138
|
+
if (c.value = Re(ke), await c.value.initiated(), f) {
|
|
139
139
|
(N = c.value) == null || N.dispose();
|
|
140
140
|
return;
|
|
141
141
|
}
|
|
142
|
-
if (await new Promise((
|
|
142
|
+
if (await new Promise((J) => requestAnimationFrame(J)), f || !c.value || c.value.markedForDisposed) {
|
|
143
143
|
c.value && !c.value.markedForDisposed && c.value.dispose();
|
|
144
144
|
return;
|
|
145
145
|
}
|
|
146
|
-
|
|
147
|
-
|
|
146
|
+
I.value = !0;
|
|
147
|
+
const R = (U = c.value) == null ? void 0 : U.sizeMeta, Ve = (R == null ? void 0 : R.width) === "100%", Ie = (R == null ? void 0 : R.height) === "100%";
|
|
148
|
+
Se.value = { fillWidth: Ve, fillHeight: Ie }, (!(i.autoSize ?? !0) || Ve && Ie) && ie(), (Oe = c.value) != null && Oe.props && (c.value.props.myop_cta_handler = (J, De) => {
|
|
149
|
+
i.on && i.on(J, De), a("cta", J, De);
|
|
148
150
|
}), a("load", c.value);
|
|
149
151
|
} catch (m) {
|
|
150
|
-
f ||
|
|
152
|
+
f || le((m == null ? void 0 : m.message) || "Unknown error");
|
|
151
153
|
} finally {
|
|
152
|
-
if (
|
|
153
|
-
const m =
|
|
154
|
-
|
|
154
|
+
if (se.value = !1, L.value !== null && !f) {
|
|
155
|
+
const m = L.value;
|
|
156
|
+
L.value = null, await ae(m);
|
|
155
157
|
}
|
|
156
158
|
}
|
|
157
159
|
return () => {
|
|
158
160
|
f = !0;
|
|
159
161
|
};
|
|
160
|
-
},
|
|
162
|
+
}, st = () => {
|
|
161
163
|
var f;
|
|
162
|
-
if (!
|
|
164
|
+
if (!I.value || !((f = c.value) != null && f.observeAutoSize))
|
|
163
165
|
return;
|
|
164
166
|
let u = !0;
|
|
165
|
-
|
|
167
|
+
$ = c.value.observeAutoSize({
|
|
168
|
+
// SDK resolves: host props → sizeMeta → defaults (width: "100%", height: auto-size)
|
|
166
169
|
explicitWidth: void 0,
|
|
167
170
|
explicitHeight: void 0,
|
|
168
|
-
forceAutoSize: i.autoSize,
|
|
171
|
+
forceAutoSize: i.autoSize ?? !0,
|
|
169
172
|
loaderMinHeight: 50,
|
|
170
173
|
onSizeChange: (N) => {
|
|
171
|
-
a("sizeChange", N),
|
|
174
|
+
a("sizeChange", N), D.value = N, u && (u = !1, ie());
|
|
172
175
|
}
|
|
173
176
|
});
|
|
174
177
|
};
|
|
175
|
-
|
|
178
|
+
ce(
|
|
176
179
|
() => i.componentId,
|
|
177
180
|
async (u, f) => {
|
|
178
|
-
u !== f && (
|
|
181
|
+
u !== f && (I.value = !1, E.value = !1, g.value = !0, V.value = 1, c.value && (c.value.dispose(), c.value = null), $ && ($(), $ = null), se.value ? L.value = { ...i } : await ae(i));
|
|
179
182
|
}
|
|
180
|
-
),
|
|
183
|
+
), ce(
|
|
181
184
|
() => i.data,
|
|
182
185
|
(u) => {
|
|
183
186
|
var f;
|
|
184
|
-
if (
|
|
187
|
+
if (I.value && u !== void 0 && c.value) {
|
|
185
188
|
const N = (f = c.value.props) == null ? void 0 : f.myop_init_interface;
|
|
186
189
|
if (N) {
|
|
187
|
-
const
|
|
188
|
-
N(
|
|
190
|
+
const U = JSON.parse(JSON.stringify(u));
|
|
191
|
+
N(U);
|
|
189
192
|
}
|
|
190
193
|
}
|
|
191
194
|
},
|
|
192
195
|
{ deep: !0 }
|
|
193
|
-
),
|
|
194
|
-
() =>
|
|
196
|
+
), ce(
|
|
197
|
+
() => I.value,
|
|
195
198
|
(u) => {
|
|
196
|
-
u &&
|
|
199
|
+
u && st();
|
|
197
200
|
}
|
|
198
|
-
),
|
|
199
|
-
(i.componentId || i.componentConfig) && await
|
|
200
|
-
}),
|
|
201
|
-
|
|
201
|
+
), Te(async () => {
|
|
202
|
+
(i.componentId || i.componentConfig) && await ae(i);
|
|
203
|
+
}), pt(() => {
|
|
204
|
+
$ && $(), c.value && c.value.dispose();
|
|
202
205
|
});
|
|
203
|
-
const
|
|
204
|
-
() =>
|
|
205
|
-
|
|
206
|
-
return ((u = I.value) == null ? void 0 : u.autoSizingWidth) || ((f = I.value) == null ? void 0 : f.autoSizingHeight);
|
|
207
|
-
}
|
|
208
|
-
), Se = y(() => g.value ? 50 : void 0), tt = y(() => {
|
|
206
|
+
const j = y(() => g.value ? 50 : void 0), we = y(
|
|
207
|
+
() => !(i.autoSize ?? !0) || !I.value || Se.value.fillHeight
|
|
208
|
+
), it = y(() => {
|
|
209
209
|
var u, f;
|
|
210
|
-
return {
|
|
210
|
+
return we.value ? {
|
|
211
|
+
position: "relative",
|
|
212
|
+
width: "100%",
|
|
213
|
+
height: "100%",
|
|
214
|
+
minHeight: j.value ? `${j.value}px` : void 0
|
|
215
|
+
} : {
|
|
211
216
|
position: "relative",
|
|
212
|
-
width: (u =
|
|
213
|
-
height: (f =
|
|
214
|
-
minHeight:
|
|
215
|
-
overflow: Ne.value ? "hidden" : "inherit"
|
|
217
|
+
width: (u = D.value) != null && u.autoSizingWidth ? `${D.value.width}px` : "100%",
|
|
218
|
+
height: (f = D.value) != null && f.height ? `${D.value.height}px` : void 0,
|
|
219
|
+
minHeight: j.value ? `${j.value}px` : void 0
|
|
216
220
|
};
|
|
217
|
-
}),
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
221
|
+
}), lt = y(() => {
|
|
222
|
+
var u;
|
|
223
|
+
return we.value ? {
|
|
224
|
+
position: "absolute",
|
|
225
|
+
inset: "0"
|
|
226
|
+
} : {
|
|
227
|
+
width: "100%",
|
|
228
|
+
height: (u = D.value) != null && u.height ? `${D.value.height}px` : void 0
|
|
229
|
+
};
|
|
230
|
+
});
|
|
222
231
|
return t({
|
|
223
232
|
myopComponent: c,
|
|
224
|
-
isLoaded:
|
|
225
|
-
}), (u, f) => (
|
|
226
|
-
style:
|
|
233
|
+
isLoaded: I
|
|
234
|
+
}), (u, f) => (S(), M("div", {
|
|
235
|
+
style: B(it.value)
|
|
227
236
|
}, [
|
|
228
|
-
|
|
237
|
+
Me("div", {
|
|
229
238
|
ref_key: "myopContainer",
|
|
230
239
|
ref: l,
|
|
231
|
-
style:
|
|
240
|
+
style: B(lt.value)
|
|
232
241
|
}, null, 4),
|
|
233
|
-
g.value && r.value ? (
|
|
242
|
+
g.value && r.value ? (S(), Fe(bt, {
|
|
234
243
|
key: 0,
|
|
235
244
|
opacity: V.value,
|
|
236
245
|
"fade-duration": e.fadeDuration
|
|
237
246
|
}, {
|
|
238
|
-
default:
|
|
239
|
-
|
|
247
|
+
default: $e(() => [
|
|
248
|
+
H(u.$slots, "loader")
|
|
240
249
|
]),
|
|
241
250
|
_: 3
|
|
242
|
-
}, 8, ["opacity", "fade-duration"])) :
|
|
243
|
-
|
|
244
|
-
default:
|
|
245
|
-
|
|
251
|
+
}, 8, ["opacity", "fade-duration"])) : de("", !0),
|
|
252
|
+
E.value ? (S(), Fe(wt, { key: 1 }, {
|
|
253
|
+
default: $e(() => [
|
|
254
|
+
H(u.$slots, "fallback")
|
|
246
255
|
]),
|
|
247
256
|
_: 3
|
|
248
|
-
})) :
|
|
257
|
+
})) : de("", !0)
|
|
249
258
|
], 4));
|
|
250
259
|
}
|
|
251
260
|
});
|
|
@@ -254,51 +263,51 @@ const yt = ["innerHTML"], _t = /* @__PURE__ */ Q({
|
|
|
254
263
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
255
264
|
* @license MIT
|
|
256
265
|
**/
|
|
257
|
-
const
|
|
266
|
+
const Ot = process.env.NODE_ENV !== "production" ? Object.freeze({}) : {};
|
|
258
267
|
process.env.NODE_ENV !== "production" && Object.freeze([]);
|
|
259
|
-
const
|
|
260
|
-
},
|
|
261
|
-
(e.charCodeAt(2) > 122 || e.charCodeAt(2) < 97),
|
|
268
|
+
const Pe = () => {
|
|
269
|
+
}, kt = (e) => e.charCodeAt(0) === 111 && e.charCodeAt(1) === 110 && // uppercase letter
|
|
270
|
+
(e.charCodeAt(2) > 122 || e.charCodeAt(2) < 97), _e = Object.assign, C = Array.isArray, _ = (e) => typeof e == "function", w = (e) => typeof e == "string", Vt = (e) => typeof e == "symbol", z = (e) => e !== null && typeof e == "object", It = (e) => (z(e) || _(e)) && _(e.then) && _(e.catch), Le = (e) => {
|
|
262
271
|
const t = /* @__PURE__ */ Object.create(null);
|
|
263
272
|
return ((n) => t[n] || (t[n] = e(n)));
|
|
264
|
-
},
|
|
265
|
-
(e) => e ? `on${
|
|
273
|
+
}, Dt = Le((e) => e.charAt(0).toUpperCase() + e.slice(1)), Ft = Le(
|
|
274
|
+
(e) => e ? `on${Dt(e)}` : ""
|
|
266
275
|
);
|
|
267
|
-
let
|
|
268
|
-
const
|
|
269
|
-
function
|
|
276
|
+
let xe;
|
|
277
|
+
const ne = () => xe || (xe = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : typeof global < "u" ? global : {});
|
|
278
|
+
function Ce(e) {
|
|
270
279
|
if (C(e)) {
|
|
271
280
|
const t = {};
|
|
272
281
|
for (let n = 0; n < e.length; n++) {
|
|
273
|
-
const o = e[n], s = w(o) ?
|
|
282
|
+
const o = e[n], s = w(o) ? At(o) : Ce(o);
|
|
274
283
|
if (s)
|
|
275
284
|
for (const r in s)
|
|
276
285
|
t[r] = s[r];
|
|
277
286
|
}
|
|
278
287
|
return t;
|
|
279
|
-
} else if (w(e) ||
|
|
288
|
+
} else if (w(e) || z(e))
|
|
280
289
|
return e;
|
|
281
290
|
}
|
|
282
|
-
const
|
|
283
|
-
function
|
|
291
|
+
const $t = /;(?![^(]*\))/g, Rt = /:([^]+)/, xt = /\/\*[^]*?\*\//g;
|
|
292
|
+
function At(e) {
|
|
284
293
|
const t = {};
|
|
285
|
-
return e.replace(
|
|
294
|
+
return e.replace(xt, "").split($t).forEach((n) => {
|
|
286
295
|
if (n) {
|
|
287
|
-
const o = n.split(
|
|
296
|
+
const o = n.split(Rt);
|
|
288
297
|
o.length > 1 && (t[o[0].trim()] = o[1].trim());
|
|
289
298
|
}
|
|
290
299
|
}), t;
|
|
291
300
|
}
|
|
292
|
-
function
|
|
301
|
+
function ve(e) {
|
|
293
302
|
let t = "";
|
|
294
303
|
if (w(e))
|
|
295
304
|
t = e;
|
|
296
305
|
else if (C(e))
|
|
297
306
|
for (let n = 0; n < e.length; n++) {
|
|
298
|
-
const o =
|
|
307
|
+
const o = ve(e[n]);
|
|
299
308
|
o && (t += o + " ");
|
|
300
309
|
}
|
|
301
|
-
else if (
|
|
310
|
+
else if (z(e))
|
|
302
311
|
for (const n in e)
|
|
303
312
|
e[n] && (t += n + " ");
|
|
304
313
|
return t.trim();
|
|
@@ -312,19 +321,19 @@ process.env.NODE_ENV;
|
|
|
312
321
|
process.env.NODE_ENV;
|
|
313
322
|
process.env.NODE_ENV;
|
|
314
323
|
new Set(
|
|
315
|
-
/* @__PURE__ */ Object.getOwnPropertyNames(Symbol).filter((e) => e !== "arguments" && e !== "caller").map((e) => Symbol[e]).filter(
|
|
324
|
+
/* @__PURE__ */ Object.getOwnPropertyNames(Symbol).filter((e) => e !== "arguments" && e !== "caller").map((e) => Symbol[e]).filter(Vt)
|
|
316
325
|
);
|
|
317
326
|
// @__NO_SIDE_EFFECTS__
|
|
318
|
-
function
|
|
327
|
+
function me(e) {
|
|
319
328
|
return e ? !!e.__v_raw : !1;
|
|
320
329
|
}
|
|
321
330
|
// @__NO_SIDE_EFFECTS__
|
|
322
|
-
function
|
|
331
|
+
function K(e) {
|
|
323
332
|
const t = e && e.__v_raw;
|
|
324
|
-
return t ? /* @__PURE__ */
|
|
333
|
+
return t ? /* @__PURE__ */ K(t) : e;
|
|
325
334
|
}
|
|
326
335
|
// @__NO_SIDE_EFFECTS__
|
|
327
|
-
function
|
|
336
|
+
function je(e) {
|
|
328
337
|
return e ? e.__v_isRef === !0 : !1;
|
|
329
338
|
}
|
|
330
339
|
/**
|
|
@@ -332,20 +341,20 @@ function Me(e) {
|
|
|
332
341
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
333
342
|
* @license MIT
|
|
334
343
|
**/
|
|
335
|
-
const
|
|
336
|
-
function
|
|
337
|
-
|
|
344
|
+
const F = [];
|
|
345
|
+
function Tt(e) {
|
|
346
|
+
F.push(e);
|
|
338
347
|
}
|
|
339
|
-
function
|
|
340
|
-
|
|
348
|
+
function Mt() {
|
|
349
|
+
F.pop();
|
|
341
350
|
}
|
|
342
|
-
let
|
|
351
|
+
let ue = !1;
|
|
343
352
|
function O(e, ...t) {
|
|
344
|
-
if (
|
|
345
|
-
|
|
346
|
-
const n =
|
|
353
|
+
if (ue) return;
|
|
354
|
+
ue = !0;
|
|
355
|
+
const n = F.length ? F[F.length - 1].component : null, o = n && n.appContext.config.warnHandler, s = Ht();
|
|
347
356
|
if (o)
|
|
348
|
-
|
|
357
|
+
oe(
|
|
349
358
|
o,
|
|
350
359
|
n,
|
|
351
360
|
11,
|
|
@@ -357,7 +366,7 @@ function O(e, ...t) {
|
|
|
357
366
|
}).join(""),
|
|
358
367
|
n && n.proxy,
|
|
359
368
|
s.map(
|
|
360
|
-
({ vnode: r }) => `at <${
|
|
369
|
+
({ vnode: r }) => `at <${ot(n, r.type)}>`
|
|
361
370
|
).join(`
|
|
362
371
|
`),
|
|
363
372
|
s
|
|
@@ -366,12 +375,12 @@ function O(e, ...t) {
|
|
|
366
375
|
else {
|
|
367
376
|
const r = [`[Vue warn]: ${e}`, ...t];
|
|
368
377
|
s.length && r.push(`
|
|
369
|
-
`, ...
|
|
378
|
+
`, ...zt(s)), console.warn(...r);
|
|
370
379
|
}
|
|
371
|
-
|
|
380
|
+
ue = !1;
|
|
372
381
|
}
|
|
373
|
-
function
|
|
374
|
-
let e =
|
|
382
|
+
function Ht() {
|
|
383
|
+
let e = F[F.length - 1];
|
|
375
384
|
if (!e)
|
|
376
385
|
return [];
|
|
377
386
|
const t = [];
|
|
@@ -386,31 +395,31 @@ function $t() {
|
|
|
386
395
|
}
|
|
387
396
|
return t;
|
|
388
397
|
}
|
|
389
|
-
function
|
|
398
|
+
function zt(e) {
|
|
390
399
|
const t = [];
|
|
391
400
|
return e.forEach((n, o) => {
|
|
392
401
|
t.push(...o === 0 ? [] : [`
|
|
393
|
-
`], ...
|
|
402
|
+
`], ...Pt(n));
|
|
394
403
|
}), t;
|
|
395
404
|
}
|
|
396
|
-
function
|
|
397
|
-
const n = t > 0 ? `... (${t} recursive calls)` : "", o = e.component ? e.component.parent == null : !1, s = ` at <${
|
|
405
|
+
function Pt({ vnode: e, recurseCount: t }) {
|
|
406
|
+
const n = t > 0 ? `... (${t} recursive calls)` : "", o = e.component ? e.component.parent == null : !1, s = ` at <${ot(
|
|
398
407
|
e.component,
|
|
399
408
|
e.type,
|
|
400
409
|
o
|
|
401
410
|
)}`, r = ">" + n;
|
|
402
|
-
return e.props ? [s, ...
|
|
411
|
+
return e.props ? [s, ...Lt(e.props), r] : [s + r];
|
|
403
412
|
}
|
|
404
|
-
function
|
|
413
|
+
function Lt(e) {
|
|
405
414
|
const t = [], n = Object.keys(e);
|
|
406
415
|
return n.slice(0, 3).forEach((o) => {
|
|
407
|
-
t.push(...
|
|
416
|
+
t.push(...Ue(o, e[o]));
|
|
408
417
|
}), n.length > 3 && t.push(" ..."), t;
|
|
409
418
|
}
|
|
410
|
-
function
|
|
411
|
-
return w(t) ? (t = JSON.stringify(t), n ? t : [`${e}=${t}`]) : typeof t == "number" || typeof t == "boolean" || t == null ? n ? t : [`${e}=${t}`] : /* @__PURE__ */
|
|
419
|
+
function Ue(e, t, n) {
|
|
420
|
+
return w(t) ? (t = JSON.stringify(t), n ? t : [`${e}=${t}`]) : typeof t == "number" || typeof t == "boolean" || t == null ? n ? t : [`${e}=${t}`] : /* @__PURE__ */ je(t) ? (t = Ue(e, /* @__PURE__ */ K(t.value), !0), n ? t : [`${e}=Ref<`, t, ">"]) : _(t) ? [`${e}=fn${t.name ? `<${t.name}>` : ""}`] : (t = /* @__PURE__ */ K(t), n ? t : [`${e}=`, t]);
|
|
412
421
|
}
|
|
413
|
-
const
|
|
422
|
+
const Ee = {
|
|
414
423
|
sp: "serverPrefetch hook",
|
|
415
424
|
bc: "beforeCreate hook",
|
|
416
425
|
c: "created hook",
|
|
@@ -443,45 +452,45 @@ const Ce = {
|
|
|
443
452
|
15: "component update",
|
|
444
453
|
16: "app unmount cleanup function"
|
|
445
454
|
};
|
|
446
|
-
function
|
|
455
|
+
function oe(e, t, n, o) {
|
|
447
456
|
try {
|
|
448
457
|
return o ? e(...o) : e();
|
|
449
458
|
} catch (s) {
|
|
450
|
-
|
|
459
|
+
Ne(s, t, n);
|
|
451
460
|
}
|
|
452
461
|
}
|
|
453
|
-
function
|
|
462
|
+
function Je(e, t, n, o) {
|
|
454
463
|
if (_(e)) {
|
|
455
|
-
const s =
|
|
456
|
-
return s &&
|
|
457
|
-
|
|
464
|
+
const s = oe(e, t, n, o);
|
|
465
|
+
return s && It(s) && s.catch((r) => {
|
|
466
|
+
Ne(r, t, n);
|
|
458
467
|
}), s;
|
|
459
468
|
}
|
|
460
469
|
if (C(e)) {
|
|
461
470
|
const s = [];
|
|
462
471
|
for (let r = 0; r < e.length; r++)
|
|
463
|
-
s.push(
|
|
472
|
+
s.push(Je(e[r], t, n, o));
|
|
464
473
|
return s;
|
|
465
474
|
} else process.env.NODE_ENV !== "production" && O(
|
|
466
475
|
`Invalid value type passed to callWithAsyncErrorHandling(): ${typeof e}`
|
|
467
476
|
);
|
|
468
477
|
}
|
|
469
|
-
function
|
|
470
|
-
const s = t ? t.vnode : null, { errorHandler: r, throwUnhandledErrorInProduction: i } = t && t.appContext.config ||
|
|
478
|
+
function Ne(e, t, n, o = !0) {
|
|
479
|
+
const s = t ? t.vnode : null, { errorHandler: r, throwUnhandledErrorInProduction: i } = t && t.appContext.config || Ot;
|
|
471
480
|
if (t) {
|
|
472
481
|
let a = t.parent;
|
|
473
|
-
const l = t.proxy, c = process.env.NODE_ENV !== "production" ?
|
|
482
|
+
const l = t.proxy, c = process.env.NODE_ENV !== "production" ? Ee[n] : `https://vuejs.org/error-reference/#runtime-${n}`;
|
|
474
483
|
for (; a; ) {
|
|
475
|
-
const
|
|
476
|
-
if (
|
|
477
|
-
for (let g = 0; g <
|
|
478
|
-
if (
|
|
484
|
+
const d = a.ec;
|
|
485
|
+
if (d) {
|
|
486
|
+
for (let g = 0; g < d.length; g++)
|
|
487
|
+
if (d[g](e, l, c) === !1)
|
|
479
488
|
return;
|
|
480
489
|
}
|
|
481
490
|
a = a.parent;
|
|
482
491
|
}
|
|
483
492
|
if (r) {
|
|
484
|
-
|
|
493
|
+
oe(r, null, 10, [
|
|
485
494
|
e,
|
|
486
495
|
l,
|
|
487
496
|
c
|
|
@@ -489,12 +498,12 @@ function Ee(e, t, n, o = !0) {
|
|
|
489
498
|
return;
|
|
490
499
|
}
|
|
491
500
|
}
|
|
492
|
-
|
|
501
|
+
jt(e, n, s, o, i);
|
|
493
502
|
}
|
|
494
|
-
function
|
|
503
|
+
function jt(e, t, n, o = !0, s = !1) {
|
|
495
504
|
if (process.env.NODE_ENV !== "production") {
|
|
496
|
-
const r =
|
|
497
|
-
if (n &&
|
|
505
|
+
const r = Ee[t];
|
|
506
|
+
if (n && Tt(n), O(`Unhandled error${r ? ` during execution of ${r}` : ""}`), n && Mt(), o)
|
|
498
507
|
throw e;
|
|
499
508
|
console.error(e);
|
|
500
509
|
} else {
|
|
@@ -504,60 +513,60 @@ function Mt(e, t, n, o = !0, s = !1) {
|
|
|
504
513
|
}
|
|
505
514
|
}
|
|
506
515
|
const h = [];
|
|
507
|
-
let
|
|
516
|
+
let v = -1;
|
|
508
517
|
const T = [];
|
|
509
|
-
let
|
|
510
|
-
const
|
|
511
|
-
let
|
|
512
|
-
const
|
|
513
|
-
function
|
|
514
|
-
let t =
|
|
518
|
+
let b = null, x = 0;
|
|
519
|
+
const Ut = /* @__PURE__ */ Promise.resolve();
|
|
520
|
+
let he = null;
|
|
521
|
+
const Jt = 100;
|
|
522
|
+
function Wt(e) {
|
|
523
|
+
let t = v + 1, n = h.length;
|
|
515
524
|
for (; t < n; ) {
|
|
516
|
-
const o = t + n >>> 1, s = h[o], r =
|
|
525
|
+
const o = t + n >>> 1, s = h[o], r = P(s);
|
|
517
526
|
r < e || r === e && s.flags & 2 ? t = o + 1 : n = o;
|
|
518
527
|
}
|
|
519
528
|
return t;
|
|
520
529
|
}
|
|
521
|
-
function
|
|
530
|
+
function qt(e) {
|
|
522
531
|
if (!(e.flags & 1)) {
|
|
523
|
-
const t =
|
|
532
|
+
const t = P(e), n = h[h.length - 1];
|
|
524
533
|
!n || // fast path when the job id is larger than the tail
|
|
525
|
-
!(e.flags & 2) && t >=
|
|
534
|
+
!(e.flags & 2) && t >= P(n) ? h.push(e) : h.splice(Wt(t), 0, e), e.flags |= 1, We();
|
|
526
535
|
}
|
|
527
536
|
}
|
|
528
|
-
function
|
|
529
|
-
|
|
537
|
+
function We() {
|
|
538
|
+
he || (he = Ut.then(qe));
|
|
530
539
|
}
|
|
531
|
-
function
|
|
532
|
-
C(e) ? T.push(...e) :
|
|
540
|
+
function Bt(e) {
|
|
541
|
+
C(e) ? T.push(...e) : b && e.id === -1 ? b.splice(x + 1, 0, e) : e.flags & 1 || (T.push(e), e.flags |= 1), We();
|
|
533
542
|
}
|
|
534
|
-
function
|
|
543
|
+
function Kt(e) {
|
|
535
544
|
if (T.length) {
|
|
536
545
|
const t = [...new Set(T)].sort(
|
|
537
|
-
(n, o) =>
|
|
546
|
+
(n, o) => P(n) - P(o)
|
|
538
547
|
);
|
|
539
|
-
if (T.length = 0,
|
|
540
|
-
|
|
548
|
+
if (T.length = 0, b) {
|
|
549
|
+
b.push(...t);
|
|
541
550
|
return;
|
|
542
551
|
}
|
|
543
|
-
for (
|
|
544
|
-
const n =
|
|
545
|
-
process.env.NODE_ENV !== "production" &&
|
|
552
|
+
for (b = t, process.env.NODE_ENV !== "production" && (e = e || /* @__PURE__ */ new Map()), x = 0; x < b.length; x++) {
|
|
553
|
+
const n = b[x];
|
|
554
|
+
process.env.NODE_ENV !== "production" && Be(e, n) || (n.flags & 4 && (n.flags &= -2), n.flags & 8 || n(), n.flags &= -2);
|
|
546
555
|
}
|
|
547
|
-
|
|
556
|
+
b = null, x = 0;
|
|
548
557
|
}
|
|
549
558
|
}
|
|
550
|
-
const
|
|
551
|
-
function
|
|
559
|
+
const P = (e) => e.id == null ? e.flags & 2 ? -1 : 1 / 0 : e.id;
|
|
560
|
+
function qe(e) {
|
|
552
561
|
process.env.NODE_ENV !== "production" && (e = e || /* @__PURE__ */ new Map());
|
|
553
|
-
const t = process.env.NODE_ENV !== "production" ? (n) =>
|
|
562
|
+
const t = process.env.NODE_ENV !== "production" ? (n) => Be(e, n) : Pe;
|
|
554
563
|
try {
|
|
555
|
-
for (
|
|
556
|
-
const n = h[
|
|
564
|
+
for (v = 0; v < h.length; v++) {
|
|
565
|
+
const n = h[v];
|
|
557
566
|
if (n && !(n.flags & 8)) {
|
|
558
567
|
if (process.env.NODE_ENV !== "production" && t(n))
|
|
559
568
|
continue;
|
|
560
|
-
n.flags & 4 && (n.flags &= -2),
|
|
569
|
+
n.flags & 4 && (n.flags &= -2), oe(
|
|
561
570
|
n,
|
|
562
571
|
n.i,
|
|
563
572
|
n.i ? 15 : 14
|
|
@@ -565,18 +574,18 @@ function Le(e) {
|
|
|
565
574
|
}
|
|
566
575
|
}
|
|
567
576
|
} finally {
|
|
568
|
-
for (;
|
|
569
|
-
const n = h[
|
|
577
|
+
for (; v < h.length; v++) {
|
|
578
|
+
const n = h[v];
|
|
570
579
|
n && (n.flags &= -2);
|
|
571
580
|
}
|
|
572
|
-
|
|
581
|
+
v = -1, h.length = 0, Kt(e), he = null, (h.length || T.length) && qe(e);
|
|
573
582
|
}
|
|
574
583
|
}
|
|
575
|
-
function
|
|
584
|
+
function Be(e, t) {
|
|
576
585
|
const n = e.get(t) || 0;
|
|
577
|
-
if (n >
|
|
578
|
-
const o = t.i, s = o &&
|
|
579
|
-
return
|
|
586
|
+
if (n > Jt) {
|
|
587
|
+
const o = t.i, s = o && nt(o.type);
|
|
588
|
+
return Ne(
|
|
580
589
|
`Maximum recursive updates exceeded${s ? ` in component <${s}>` : ""}. This means you have a reactive effect that is mutating its own dependencies and thus recursively triggering itself. Possible sources include component template, render function, updated hook or watcher source function.`,
|
|
581
590
|
null,
|
|
582
591
|
10
|
|
@@ -584,52 +593,52 @@ function je(e, t) {
|
|
|
584
593
|
}
|
|
585
594
|
return e.set(t, n + 1), !1;
|
|
586
595
|
}
|
|
587
|
-
const
|
|
588
|
-
process.env.NODE_ENV !== "production" && (
|
|
589
|
-
createRecord:
|
|
590
|
-
rerender:
|
|
591
|
-
reload:
|
|
596
|
+
const fe = /* @__PURE__ */ new Map();
|
|
597
|
+
process.env.NODE_ENV !== "production" && (ne().__VUE_HMR_RUNTIME__ = {
|
|
598
|
+
createRecord: pe(Yt),
|
|
599
|
+
rerender: pe(Gt),
|
|
600
|
+
reload: pe(Qt)
|
|
592
601
|
});
|
|
593
|
-
const
|
|
594
|
-
function
|
|
595
|
-
return
|
|
596
|
-
initialDef:
|
|
602
|
+
const Y = /* @__PURE__ */ new Map();
|
|
603
|
+
function Yt(e, t) {
|
|
604
|
+
return Y.has(e) ? !1 : (Y.set(e, {
|
|
605
|
+
initialDef: G(t),
|
|
597
606
|
instances: /* @__PURE__ */ new Set()
|
|
598
607
|
}), !0);
|
|
599
608
|
}
|
|
600
|
-
function
|
|
601
|
-
return
|
|
609
|
+
function G(e) {
|
|
610
|
+
return rt(e) ? e.__vccOpts : e;
|
|
602
611
|
}
|
|
603
|
-
function
|
|
604
|
-
const n =
|
|
612
|
+
function Gt(e, t) {
|
|
613
|
+
const n = Y.get(e);
|
|
605
614
|
n && (n.initialDef.render = t, [...n.instances].forEach((o) => {
|
|
606
|
-
t && (o.render = t,
|
|
615
|
+
t && (o.render = t, G(o.type).render = t), o.renderCache = [], o.job.flags & 8 || o.update();
|
|
607
616
|
}));
|
|
608
617
|
}
|
|
609
|
-
function
|
|
610
|
-
const n =
|
|
618
|
+
function Qt(e, t) {
|
|
619
|
+
const n = Y.get(e);
|
|
611
620
|
if (!n) return;
|
|
612
|
-
t =
|
|
621
|
+
t = G(t), Ae(n.initialDef, t);
|
|
613
622
|
const o = [...n.instances];
|
|
614
623
|
for (let s = 0; s < o.length; s++) {
|
|
615
|
-
const r = o[s], i =
|
|
616
|
-
let a =
|
|
617
|
-
a || (i !== n.initialDef &&
|
|
624
|
+
const r = o[s], i = G(r.type);
|
|
625
|
+
let a = fe.get(i);
|
|
626
|
+
a || (i !== n.initialDef && Ae(i, t), fe.set(i, a = /* @__PURE__ */ new Set())), a.add(r), r.appContext.propsCache.delete(r.type), r.appContext.emitsCache.delete(r.type), r.appContext.optionsCache.delete(r.type), r.ceReload ? (a.add(r), r.ceReload(t.styles), a.delete(r)) : r.parent ? qt(() => {
|
|
618
627
|
r.job.flags & 8 || (r.parent.update(), a.delete(r));
|
|
619
628
|
}) : r.appContext.reload ? r.appContext.reload() : typeof window < "u" ? window.location.reload() : console.warn(
|
|
620
629
|
"[HMR] Root or manually mounted instance modified. Full reload required."
|
|
621
630
|
), r.root.ce && r !== r.root && r.root.ce._removeChildStyle(i);
|
|
622
631
|
}
|
|
623
|
-
|
|
624
|
-
|
|
632
|
+
Bt(() => {
|
|
633
|
+
fe.clear();
|
|
625
634
|
});
|
|
626
635
|
}
|
|
627
|
-
function
|
|
628
|
-
|
|
636
|
+
function Ae(e, t) {
|
|
637
|
+
_e(e, t);
|
|
629
638
|
for (const n in e)
|
|
630
639
|
n !== "__file" && !(n in t) && delete e[n];
|
|
631
640
|
}
|
|
632
|
-
function
|
|
641
|
+
function pe(e) {
|
|
633
642
|
return (t, n) => {
|
|
634
643
|
try {
|
|
635
644
|
return e(t, n);
|
|
@@ -640,65 +649,65 @@ function ue(e) {
|
|
|
640
649
|
}
|
|
641
650
|
};
|
|
642
651
|
}
|
|
643
|
-
let
|
|
644
|
-
function
|
|
652
|
+
let A, W = [];
|
|
653
|
+
function Ke(e, t) {
|
|
645
654
|
var n, o;
|
|
646
|
-
|
|
655
|
+
A = e, A ? (A.enabled = !0, W.forEach(({ event: s, args: r }) => A.emit(s, ...r)), W = []) : /* handle late devtools injection - only do this if we are in an actual */ /* browser environment to avoid the timer handle stalling test runner exit */ /* (#4815) */ typeof window < "u" && // some envs mock window but not fully
|
|
647
656
|
window.HTMLElement && // also exclude jsdom
|
|
648
657
|
// eslint-disable-next-line no-restricted-syntax
|
|
649
658
|
!((o = (n = window.navigator) == null ? void 0 : n.userAgent) != null && o.includes("jsdom")) ? ((t.__VUE_DEVTOOLS_HOOK_REPLAY__ = t.__VUE_DEVTOOLS_HOOK_REPLAY__ || []).push((r) => {
|
|
650
|
-
|
|
659
|
+
Ke(r, t);
|
|
651
660
|
}), setTimeout(() => {
|
|
652
|
-
|
|
653
|
-
}, 3e3)) :
|
|
661
|
+
A || (t.__VUE_DEVTOOLS_HOOK_REPLAY__ = null, W = []);
|
|
662
|
+
}, 3e3)) : W = [];
|
|
654
663
|
}
|
|
655
|
-
let
|
|
656
|
-
const
|
|
657
|
-
function
|
|
658
|
-
e.shapeFlag & 6 && e.component ? (e.transition = t,
|
|
664
|
+
let Q = null, Xt = null;
|
|
665
|
+
const Zt = (e) => e.__isTeleport;
|
|
666
|
+
function Ye(e, t) {
|
|
667
|
+
e.shapeFlag & 6 && e.component ? (e.transition = t, Ye(e.component.subTree, t)) : e.shapeFlag & 128 ? (e.ssContent.transition = t.clone(e.ssContent), e.ssFallback.transition = t.clone(e.ssFallback)) : e.transition = t;
|
|
659
668
|
}
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
function
|
|
669
|
+
ne().requestIdleCallback;
|
|
670
|
+
ne().cancelIdleCallback;
|
|
671
|
+
function en(e, t, n = re, o = !1) {
|
|
663
672
|
if (n) {
|
|
664
673
|
const s = n[e] || (n[e] = []), r = t.__weh || (t.__weh = (...i) => {
|
|
665
|
-
const a =
|
|
674
|
+
const a = yn(n), l = Je(t, n, e, i);
|
|
666
675
|
return a(), l;
|
|
667
676
|
});
|
|
668
677
|
return o ? s.unshift(r) : s.push(r), r;
|
|
669
678
|
} else if (process.env.NODE_ENV !== "production") {
|
|
670
|
-
const s =
|
|
679
|
+
const s = Ft(Ee[e].replace(/ hook$/, ""));
|
|
671
680
|
O(
|
|
672
681
|
`${s} is called when there is no active component instance to be associated with. Lifecycle injection APIs can only be used during execution of setup(). If you are using async setup(), make sure to register lifecycle hooks before the first await statement.`
|
|
673
682
|
);
|
|
674
683
|
}
|
|
675
684
|
}
|
|
676
|
-
const
|
|
677
|
-
(!
|
|
678
|
-
},
|
|
679
|
-
process.env.NODE_ENV !== "production" && (
|
|
685
|
+
const tn = (e) => (t, n = re) => {
|
|
686
|
+
(!tt || e === "sp") && en(e, (...o) => t(...o), n);
|
|
687
|
+
}, nn = tn("u"), on = /* @__PURE__ */ Symbol.for("v-ndc"), rn = {};
|
|
688
|
+
process.env.NODE_ENV !== "production" && (rn.ownKeys = (e) => (O(
|
|
680
689
|
"Avoid app logic that relies on enumerating keys on a component instance. The keys will be empty in production mode to avoid performance overhead."
|
|
681
690
|
), Reflect.ownKeys(e)));
|
|
682
|
-
const
|
|
683
|
-
function
|
|
691
|
+
const sn = {}, Ge = (e) => Object.getPrototypeOf(e) === sn, ln = (e) => e.__isSuspense, Qe = /* @__PURE__ */ Symbol.for("v-fgt"), an = /* @__PURE__ */ Symbol.for("v-txt"), cn = /* @__PURE__ */ Symbol.for("v-cmt");
|
|
692
|
+
function un(e) {
|
|
684
693
|
return e ? e.__v_isVNode === !0 : !1;
|
|
685
694
|
}
|
|
686
|
-
const
|
|
695
|
+
const fn = (...e) => Ze(
|
|
687
696
|
...e
|
|
688
|
-
),
|
|
697
|
+
), Xe = ({ key: e }) => e ?? null, q = ({
|
|
689
698
|
ref: e,
|
|
690
699
|
ref_key: t,
|
|
691
700
|
ref_for: n
|
|
692
|
-
}) => (typeof e == "number" && (e = "" + e), e != null ? w(e) || /* @__PURE__ */
|
|
693
|
-
function
|
|
701
|
+
}) => (typeof e == "number" && (e = "" + e), e != null ? w(e) || /* @__PURE__ */ je(e) || _(e) ? { i: Q, r: e, k: t, f: !!n } : e : null);
|
|
702
|
+
function pn(e, t = null, n = null, o = 0, s = null, r = e === Qe ? 0 : 1, i = !1, a = !1) {
|
|
694
703
|
const l = {
|
|
695
704
|
__v_isVNode: !0,
|
|
696
705
|
__v_skip: !0,
|
|
697
706
|
type: e,
|
|
698
707
|
props: t,
|
|
699
|
-
key: t &&
|
|
700
|
-
ref: t &&
|
|
701
|
-
scopeId:
|
|
708
|
+
key: t && Xe(t),
|
|
709
|
+
ref: t && q(t),
|
|
710
|
+
scopeId: Xt,
|
|
702
711
|
slotScopeIds: null,
|
|
703
712
|
children: n,
|
|
704
713
|
component: null,
|
|
@@ -718,33 +727,33 @@ function ln(e, t = null, n = null, o = 0, s = null, r = e === qe ? 0 : 1, i = !1
|
|
|
718
727
|
dynamicProps: s,
|
|
719
728
|
dynamicChildren: null,
|
|
720
729
|
appContext: null,
|
|
721
|
-
ctx:
|
|
730
|
+
ctx: Q
|
|
722
731
|
};
|
|
723
|
-
return a ? (
|
|
732
|
+
return a ? (be(l, n), r & 128 && e.normalize(l)) : n && (l.shapeFlag |= w(n) ? 8 : 16), process.env.NODE_ENV !== "production" && l.key !== l.key && O("VNode created with invalid key (NaN). VNode type:", l.type), l;
|
|
724
733
|
}
|
|
725
|
-
const
|
|
726
|
-
function
|
|
727
|
-
if ((!e || e ===
|
|
728
|
-
const a =
|
|
734
|
+
const dn = process.env.NODE_ENV !== "production" ? fn : Ze;
|
|
735
|
+
function Ze(e, t = null, n = null, o = 0, s = null, r = !1) {
|
|
736
|
+
if ((!e || e === on) && (process.env.NODE_ENV !== "production" && !e && O(`Invalid vnode type when creating vnode: ${e}.`), e = cn), un(e)) {
|
|
737
|
+
const a = X(
|
|
729
738
|
e,
|
|
730
739
|
t,
|
|
731
740
|
!0
|
|
732
741
|
/* mergeRef: true */
|
|
733
742
|
);
|
|
734
|
-
return n &&
|
|
743
|
+
return n && be(a, n), a.patchFlag = -2, a;
|
|
735
744
|
}
|
|
736
|
-
if (
|
|
737
|
-
t =
|
|
745
|
+
if (rt(e) && (e = e.__vccOpts), t) {
|
|
746
|
+
t = mn(t);
|
|
738
747
|
let { class: a, style: l } = t;
|
|
739
|
-
a && !w(a) && (t.class =
|
|
748
|
+
a && !w(a) && (t.class = ve(a)), z(l) && (/* @__PURE__ */ me(l) && !C(l) && (l = _e({}, l)), t.style = Ce(l));
|
|
740
749
|
}
|
|
741
|
-
const i = w(e) ? 1 :
|
|
742
|
-
return process.env.NODE_ENV !== "production" && i & 4 && /* @__PURE__ */
|
|
750
|
+
const i = w(e) ? 1 : ln(e) ? 128 : Zt(e) ? 64 : z(e) ? 4 : _(e) ? 2 : 0;
|
|
751
|
+
return process.env.NODE_ENV !== "production" && i & 4 && /* @__PURE__ */ me(e) && (e = /* @__PURE__ */ K(e), O(
|
|
743
752
|
"Vue received a Component that was made a reactive object. This can lead to unnecessary performance overhead and should be avoided by marking the component with `markRaw` or using `shallowRef` instead of `ref`.",
|
|
744
753
|
`
|
|
745
754
|
Component that was made reactive: `,
|
|
746
755
|
e
|
|
747
|
-
)),
|
|
756
|
+
)), pn(
|
|
748
757
|
e,
|
|
749
758
|
t,
|
|
750
759
|
n,
|
|
@@ -755,25 +764,25 @@ Component that was made reactive: `,
|
|
|
755
764
|
!0
|
|
756
765
|
);
|
|
757
766
|
}
|
|
758
|
-
function
|
|
759
|
-
return e ? /* @__PURE__ */
|
|
767
|
+
function mn(e) {
|
|
768
|
+
return e ? /* @__PURE__ */ me(e) || Ge(e) ? _e({}, e) : e : null;
|
|
760
769
|
}
|
|
761
|
-
function
|
|
762
|
-
const { props: s, ref: r, patchFlag: i, children: a, transition: l } = e, c = t ?
|
|
770
|
+
function X(e, t, n = !1, o = !1) {
|
|
771
|
+
const { props: s, ref: r, patchFlag: i, children: a, transition: l } = e, c = t ? gn(s || {}, t) : s, d = {
|
|
763
772
|
__v_isVNode: !0,
|
|
764
773
|
__v_skip: !0,
|
|
765
774
|
type: e.type,
|
|
766
775
|
props: c,
|
|
767
|
-
key: c &&
|
|
776
|
+
key: c && Xe(c),
|
|
768
777
|
ref: t && t.ref ? (
|
|
769
778
|
// #2078 in the case of <component :is="vnode" ref="extra"/>
|
|
770
779
|
// if the vnode itself already has a ref, cloneVNode will need to merge
|
|
771
780
|
// the refs so the single vnode can be set on multiple refs
|
|
772
|
-
n && r ? C(r) ? r.concat(
|
|
781
|
+
n && r ? C(r) ? r.concat(q(t)) : [r, q(t)] : q(t)
|
|
773
782
|
) : r,
|
|
774
783
|
scopeId: e.scopeId,
|
|
775
784
|
slotScopeIds: e.slotScopeIds,
|
|
776
|
-
children: process.env.NODE_ENV !== "production" && i === -1 && C(a) ? a.map(
|
|
785
|
+
children: process.env.NODE_ENV !== "production" && i === -1 && C(a) ? a.map(et) : a,
|
|
777
786
|
target: e.target,
|
|
778
787
|
targetStart: e.targetStart,
|
|
779
788
|
targetAnchor: e.targetAnchor,
|
|
@@ -783,7 +792,7 @@ function G(e, t, n = !1, o = !1) {
|
|
|
783
792
|
// existing patch flag to be reliable and need to add the FULL_PROPS flag.
|
|
784
793
|
// note: preserve flag for fragments since they use the flag for children
|
|
785
794
|
// fast paths only.
|
|
786
|
-
patchFlag: t && e.type !==
|
|
795
|
+
patchFlag: t && e.type !== Qe ? i === -1 ? 16 : i | 16 : i,
|
|
787
796
|
dynamicProps: e.dynamicProps,
|
|
788
797
|
dynamicChildren: e.dynamicChildren,
|
|
789
798
|
appContext: e.appContext,
|
|
@@ -795,27 +804,27 @@ function G(e, t, n = !1, o = !1) {
|
|
|
795
804
|
// they will simply be overwritten.
|
|
796
805
|
component: e.component,
|
|
797
806
|
suspense: e.suspense,
|
|
798
|
-
ssContent: e.ssContent &&
|
|
799
|
-
ssFallback: e.ssFallback &&
|
|
807
|
+
ssContent: e.ssContent && X(e.ssContent),
|
|
808
|
+
ssFallback: e.ssFallback && X(e.ssFallback),
|
|
800
809
|
placeholder: e.placeholder,
|
|
801
810
|
el: e.el,
|
|
802
811
|
anchor: e.anchor,
|
|
803
812
|
ctx: e.ctx,
|
|
804
813
|
ce: e.ce
|
|
805
814
|
};
|
|
806
|
-
return l && o &&
|
|
807
|
-
|
|
808
|
-
l.clone(
|
|
809
|
-
),
|
|
815
|
+
return l && o && Ye(
|
|
816
|
+
d,
|
|
817
|
+
l.clone(d)
|
|
818
|
+
), d;
|
|
810
819
|
}
|
|
811
|
-
function
|
|
812
|
-
const t =
|
|
813
|
-
return C(e.children) && (t.children = e.children.map(
|
|
820
|
+
function et(e) {
|
|
821
|
+
const t = X(e);
|
|
822
|
+
return C(e.children) && (t.children = e.children.map(et)), t;
|
|
814
823
|
}
|
|
815
|
-
function
|
|
816
|
-
return an
|
|
824
|
+
function hn(e = " ", t = 0) {
|
|
825
|
+
return dn(an, null, e, t);
|
|
817
826
|
}
|
|
818
|
-
function
|
|
827
|
+
function be(e, t) {
|
|
819
828
|
let n = 0;
|
|
820
829
|
const { shapeFlag: o } = e;
|
|
821
830
|
if (t == null)
|
|
@@ -825,59 +834,59 @@ function ve(e, t) {
|
|
|
825
834
|
else if (typeof t == "object")
|
|
826
835
|
if (o & 65) {
|
|
827
836
|
const s = t.default;
|
|
828
|
-
s && (s._c && (s._d = !1),
|
|
837
|
+
s && (s._c && (s._d = !1), be(e, s()), s._c && (s._d = !0));
|
|
829
838
|
return;
|
|
830
839
|
} else
|
|
831
|
-
n = 32, !t._ && !
|
|
832
|
-
else _(t) ? (t = { default: t, _ctx:
|
|
840
|
+
n = 32, !t._ && !Ge(t) && (t._ctx = Q);
|
|
841
|
+
else _(t) ? (t = { default: t, _ctx: Q }, n = 32) : (t = String(t), o & 64 ? (n = 16, t = [hn(t)]) : n = 8);
|
|
833
842
|
e.children = t, e.shapeFlag |= n;
|
|
834
843
|
}
|
|
835
|
-
function
|
|
844
|
+
function gn(...e) {
|
|
836
845
|
const t = {};
|
|
837
846
|
for (let n = 0; n < e.length; n++) {
|
|
838
847
|
const o = e[n];
|
|
839
848
|
for (const s in o)
|
|
840
849
|
if (s === "class")
|
|
841
|
-
t.class !== o.class && (t.class =
|
|
850
|
+
t.class !== o.class && (t.class = ve([t.class, o.class]));
|
|
842
851
|
else if (s === "style")
|
|
843
|
-
t.style =
|
|
844
|
-
else if (
|
|
852
|
+
t.style = Ce([t.style, o.style]);
|
|
853
|
+
else if (kt(s)) {
|
|
845
854
|
const r = t[s], i = o[s];
|
|
846
855
|
i && r !== i && !(C(r) && r.includes(i)) && (t[s] = r ? [].concat(r, i) : i);
|
|
847
856
|
} else s !== "" && (t[s] = o[s]);
|
|
848
857
|
}
|
|
849
858
|
return t;
|
|
850
859
|
}
|
|
851
|
-
let
|
|
860
|
+
let re = null, ge;
|
|
852
861
|
{
|
|
853
|
-
const e =
|
|
862
|
+
const e = ne(), t = (n, o) => {
|
|
854
863
|
let s;
|
|
855
864
|
return (s = e[n]) || (s = e[n] = []), s.push(o), (r) => {
|
|
856
865
|
s.length > 1 ? s.forEach((i) => i(r)) : s[0](r);
|
|
857
866
|
};
|
|
858
867
|
};
|
|
859
|
-
|
|
868
|
+
ge = t(
|
|
860
869
|
"__VUE_INSTANCE_SETTERS__",
|
|
861
|
-
(n) =>
|
|
870
|
+
(n) => re = n
|
|
862
871
|
), t(
|
|
863
872
|
"__VUE_SSR_SETTERS__",
|
|
864
|
-
(n) =>
|
|
873
|
+
(n) => tt = n
|
|
865
874
|
);
|
|
866
875
|
}
|
|
867
|
-
const
|
|
868
|
-
const t =
|
|
869
|
-
return
|
|
870
|
-
e.scope.off(),
|
|
876
|
+
const yn = (e) => {
|
|
877
|
+
const t = re;
|
|
878
|
+
return ge(e), e.scope.on(), () => {
|
|
879
|
+
e.scope.off(), ge(t);
|
|
871
880
|
};
|
|
872
881
|
};
|
|
873
|
-
let
|
|
882
|
+
let tt = !1;
|
|
874
883
|
process.env.NODE_ENV;
|
|
875
|
-
const
|
|
876
|
-
function
|
|
884
|
+
const _n = /(?:^|[-_])\w/g, Cn = (e) => e.replace(_n, (t) => t.toUpperCase()).replace(/[-_]/g, "");
|
|
885
|
+
function nt(e, t = !0) {
|
|
877
886
|
return _(e) ? e.displayName || e.name : e.name || t && e.__name;
|
|
878
887
|
}
|
|
879
|
-
function
|
|
880
|
-
let o =
|
|
888
|
+
function ot(e, t, n = !1) {
|
|
889
|
+
let o = nt(t);
|
|
881
890
|
if (!o && t.__file) {
|
|
882
891
|
const s = t.__file.match(/([^/\\]+)\.\w+$/);
|
|
883
892
|
s && (o = s[1]);
|
|
@@ -892,15 +901,15 @@ function Xe(e, t, n = !1) {
|
|
|
892
901
|
e.parent.type.components
|
|
893
902
|
) || s(e.appContext.components);
|
|
894
903
|
}
|
|
895
|
-
return o ?
|
|
904
|
+
return o ? Cn(o) : n ? "App" : "Anonymous";
|
|
896
905
|
}
|
|
897
|
-
function
|
|
906
|
+
function rt(e) {
|
|
898
907
|
return _(e) && "__vccOpts" in e;
|
|
899
908
|
}
|
|
900
909
|
process.env.NODE_ENV;
|
|
901
910
|
process.env.NODE_ENV;
|
|
902
911
|
process.env.NODE_ENV;
|
|
903
|
-
const
|
|
912
|
+
const Vn = /* @__PURE__ */ Z({
|
|
904
913
|
inheritAttrs: !0,
|
|
905
914
|
__name: "MyopVueComponent",
|
|
906
915
|
props: {
|
|
@@ -909,13 +918,13 @@ const vn = /* @__PURE__ */ Q({
|
|
|
909
918
|
onReady: { type: Function }
|
|
910
919
|
},
|
|
911
920
|
setup(e, { expose: t }) {
|
|
912
|
-
const n = e, o =
|
|
913
|
-
|
|
921
|
+
const n = e, o = dt(), s = ee(), r = p(null), i = p(!0), a = p(null), l = p(null), c = mt(), d = p(null);
|
|
922
|
+
nn(() => {
|
|
914
923
|
l && l.value && l.value(o);
|
|
915
|
-
}),
|
|
924
|
+
}), Te(async () => {
|
|
916
925
|
if (r.value) {
|
|
917
|
-
const V = await
|
|
918
|
-
a.value = await
|
|
926
|
+
const V = await te.Main.fetchComponent(n.componentId, n.flowId);
|
|
927
|
+
a.value = await ze.loadComponent(
|
|
919
928
|
V,
|
|
920
929
|
r == null ? void 0 : r.value,
|
|
921
930
|
{
|
|
@@ -926,53 +935,53 @@ const vn = /* @__PURE__ */ Q({
|
|
|
926
935
|
context: c == null ? void 0 : c.appContext,
|
|
927
936
|
vueContainerRef: r,
|
|
928
937
|
//@ts-ignore
|
|
929
|
-
defineUpdater: (
|
|
930
|
-
l.value =
|
|
938
|
+
defineUpdater: (E) => {
|
|
939
|
+
l.value = E;
|
|
931
940
|
},
|
|
932
941
|
//@ts-ignore
|
|
933
|
-
defineInnerVueComponentRef: (
|
|
934
|
-
|
|
942
|
+
defineInnerVueComponentRef: (E) => {
|
|
943
|
+
d.value = E.value;
|
|
935
944
|
}
|
|
936
945
|
}
|
|
937
946
|
}
|
|
938
|
-
), i.value = !1, n.onReady && n.onReady(a.value,
|
|
947
|
+
), i.value = !1, n.onReady && n.onReady(a.value, d.value);
|
|
939
948
|
}
|
|
940
949
|
});
|
|
941
|
-
const g =
|
|
942
|
-
return t(g),
|
|
943
|
-
Object.assign(g,
|
|
944
|
-
}), (V,
|
|
945
|
-
|
|
950
|
+
const g = ht({});
|
|
951
|
+
return t(g), gt(() => {
|
|
952
|
+
Object.assign(g, d.value);
|
|
953
|
+
}), (V, E) => (S(), M(yt, null, [
|
|
954
|
+
Me("div", _t(ye(o), {
|
|
946
955
|
ref_key: "myopContainer",
|
|
947
956
|
ref: r
|
|
948
957
|
}), null, 16),
|
|
949
|
-
i.value ?
|
|
958
|
+
i.value ? H(V.$slots, "loading", { key: 0 }) : de("", !0)
|
|
950
959
|
], 64));
|
|
951
960
|
}
|
|
952
961
|
});
|
|
953
|
-
let k =
|
|
954
|
-
const
|
|
955
|
-
k = new
|
|
956
|
-
},
|
|
957
|
-
k = new
|
|
958
|
-
},
|
|
962
|
+
let k = te.Main;
|
|
963
|
+
const vn = () => k, En = (e, t, n) => k.isPreloaded(e, t, n), In = (e) => k.getPreloadedParams(e), Dn = () => {
|
|
964
|
+
k = new te("http://localhost:9292");
|
|
965
|
+
}, Fn = (e) => {
|
|
966
|
+
k = new te(e);
|
|
967
|
+
}, $n = (e) => {
|
|
959
968
|
k = e;
|
|
960
|
-
},
|
|
969
|
+
}, Rn = (e) => {
|
|
961
970
|
k.setEnvironment(e);
|
|
962
|
-
},
|
|
971
|
+
}, xn = async (e, t, n) => Promise.allSettled(
|
|
963
972
|
e.map((o) => k.fetchComponentV2(o, t, n))
|
|
964
973
|
);
|
|
965
974
|
export {
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
|
|
972
|
-
|
|
973
|
-
|
|
974
|
-
|
|
975
|
-
|
|
976
|
-
|
|
977
|
-
|
|
975
|
+
kn as MyopComponent,
|
|
976
|
+
Vn as MyopContainer,
|
|
977
|
+
wt as MyopFallback,
|
|
978
|
+
bt as MyopLoader,
|
|
979
|
+
Dn as enableLocalDev,
|
|
980
|
+
vn as getCloudRepository,
|
|
981
|
+
In as getPreloadedParams,
|
|
982
|
+
En as isPreloaded,
|
|
983
|
+
xn as preloadComponents,
|
|
984
|
+
$n as setCloudRepository,
|
|
985
|
+
Fn as setCloudRepositoryUrl,
|
|
986
|
+
Rn as setEnvironment
|
|
978
987
|
};
|