storybook 9.0.0-alpha.13 → 9.0.0-alpha.14
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/actions/decorator.js +46 -47
- package/dist/actions/index.cjs +28 -29
- package/dist/actions/index.d.ts +0 -3
- package/dist/actions/index.js +27 -28
- package/dist/actions/preview.cjs +22 -23
- package/dist/actions/preview.js +18 -19
- package/dist/bin/index.cjs +57 -60
- package/dist/bin/index.js +57 -60
- package/dist/channels/index.cjs +1018 -948
- package/dist/channels/index.js +1194 -1161
- package/dist/cli/bin/index.cjs +1 -1
- package/dist/cli/bin/index.js +1 -1
- package/dist/cli/index.cjs +1860 -1871
- package/dist/cli/index.js +308 -319
- package/dist/common/index.cjs +44 -49
- package/dist/common/index.d.ts +0 -3
- package/dist/common/index.js +44 -49
- package/dist/components/index.cjs +6375 -12708
- package/dist/components/index.d.ts +1 -2
- package/dist/components/index.js +4647 -10782
- package/dist/core-server/index.cjs +13626 -13550
- package/dist/core-server/index.js +13247 -13171
- package/dist/manager/globals-runtime.js +29817 -33554
- package/dist/manager-api/index.cjs +2521 -2333
- package/dist/manager-api/index.js +2432 -2234
- package/dist/preview/runtime.js +18415 -16011
- package/dist/preview-api/index.cjs +619 -603
- package/dist/preview-api/index.d.ts +386 -118
- package/dist/preview-api/index.js +542 -526
- package/dist/server-errors.cjs +66 -67
- package/dist/server-errors.d.ts +0 -1
- package/dist/server-errors.js +68 -69
- package/dist/test/preview.d.ts +6 -0
- package/dist/types/index.d.ts +1 -4
- package/package.json +2 -2
package/dist/channels/index.cjs
CHANGED
|
@@ -1,324 +1,420 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
var
|
|
5
|
-
var
|
|
6
|
-
var
|
|
7
|
-
var
|
|
8
|
-
var
|
|
2
|
+
var Mt = Object.create;
|
|
3
|
+
var Z = Object.defineProperty;
|
|
4
|
+
var Ut = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var Gt = Object.getOwnPropertyNames;
|
|
6
|
+
var kt = Object.getPrototypeOf, Wt = Object.prototype.hasOwnProperty;
|
|
7
|
+
var s = (t, e) => Z(t, "name", { value: e, configurable: !0 });
|
|
8
|
+
var ke = (t, e) => () => (e || t((e = { exports: {} }).exports, e), e.exports), qt = (t, e) => {
|
|
9
9
|
for (var r in e)
|
|
10
|
-
|
|
11
|
-
},
|
|
10
|
+
Z(t, r, { get: e[r], enumerable: !0 });
|
|
11
|
+
}, We = (t, e, r, n) => {
|
|
12
12
|
if (e && typeof e == "object" || typeof e == "function")
|
|
13
|
-
for (let
|
|
14
|
-
!
|
|
13
|
+
for (let o of Gt(e))
|
|
14
|
+
!Wt.call(t, o) && o !== r && Z(t, o, { get: () => e[o], enumerable: !(n = Ut(e, o)) || n.enumerable });
|
|
15
15
|
return t;
|
|
16
16
|
};
|
|
17
|
-
var
|
|
17
|
+
var ee = (t, e, r) => (r = t != null ? Mt(kt(t)) : {}, We(
|
|
18
18
|
// If the importer is in node compatibility mode or this is not an ESM
|
|
19
19
|
// file that has been converted to a CommonJS file using a Babel-
|
|
20
20
|
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
21
21
|
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
22
|
-
e || !t || !t.__esModule ?
|
|
22
|
+
e || !t || !t.__esModule ? Z(r, "default", { value: t, enumerable: !0 }) : r,
|
|
23
23
|
t
|
|
24
|
-
)),
|
|
24
|
+
)), Bt = (t) => We(Z({}, "__esModule", { value: !0 }), t);
|
|
25
25
|
|
|
26
26
|
// ../node_modules/ts-dedent/dist/index.js
|
|
27
|
-
var
|
|
27
|
+
var Be = ke((te) => {
|
|
28
28
|
"use strict";
|
|
29
|
-
Object.defineProperty(
|
|
30
|
-
|
|
31
|
-
function
|
|
29
|
+
Object.defineProperty(te, "__esModule", { value: !0 });
|
|
30
|
+
te.dedent = void 0;
|
|
31
|
+
function qe(t) {
|
|
32
32
|
for (var e = [], r = 1; r < arguments.length; r++)
|
|
33
33
|
e[r - 1] = arguments[r];
|
|
34
34
|
var n = Array.from(typeof t == "string" ? [t] : t);
|
|
35
35
|
n[n.length - 1] = n[n.length - 1].replace(/\r?\n([\t ]*)$/, "");
|
|
36
|
-
var
|
|
37
|
-
var
|
|
38
|
-
return
|
|
36
|
+
var o = n.reduce(function(c, i) {
|
|
37
|
+
var l = i.match(/\n([\t ]+|(?!\s).)/g);
|
|
38
|
+
return l ? c.concat(l.map(function(d) {
|
|
39
39
|
var u, y;
|
|
40
|
-
return (y = (u =
|
|
40
|
+
return (y = (u = d.match(/[\t ]/g)) === null || u === void 0 ? void 0 : u.length) !== null && y !== void 0 ? y : 0;
|
|
41
41
|
})) : c;
|
|
42
42
|
}, []);
|
|
43
|
-
if (
|
|
44
|
-
var
|
|
45
|
-
[ ]{` + Math.min.apply(Math,
|
|
43
|
+
if (o.length) {
|
|
44
|
+
var p = new RegExp(`
|
|
45
|
+
[ ]{` + Math.min.apply(Math, o) + "}", "g");
|
|
46
46
|
n = n.map(function(c) {
|
|
47
|
-
return c.replace(
|
|
47
|
+
return c.replace(p, `
|
|
48
48
|
`);
|
|
49
49
|
});
|
|
50
50
|
}
|
|
51
51
|
n[0] = n[0].replace(/^\r?\n/, "");
|
|
52
|
-
var
|
|
52
|
+
var a = n[0];
|
|
53
53
|
return e.forEach(function(c, i) {
|
|
54
|
-
var
|
|
54
|
+
var l = a.match(/(?:^|\n)( *)$/), d = l ? l[1] : "", u = c;
|
|
55
55
|
typeof c == "string" && c.includes(`
|
|
56
56
|
`) && (u = String(c).split(`
|
|
57
|
-
`).map(function(y,
|
|
58
|
-
return
|
|
57
|
+
`).map(function(y, g) {
|
|
58
|
+
return g === 0 ? y : "" + d + y;
|
|
59
59
|
}).join(`
|
|
60
|
-
`)),
|
|
61
|
-
}),
|
|
60
|
+
`)), a += u + n[i + 1];
|
|
61
|
+
}), a;
|
|
62
62
|
}
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
});
|
|
67
|
-
|
|
68
|
-
// ../node_modules/map-or-similar/src/similar.js
|
|
69
|
-
var de = J((st, ye) => {
|
|
70
|
-
function I() {
|
|
71
|
-
return this.list = [], this.lastItem = void 0, this.size = 0, this;
|
|
72
|
-
}
|
|
73
|
-
o(I, "Similar");
|
|
74
|
-
I.prototype.get = function(t) {
|
|
75
|
-
var e;
|
|
76
|
-
if (this.lastItem && this.isEqual(this.lastItem.key, t))
|
|
77
|
-
return this.lastItem.val;
|
|
78
|
-
if (e = this.indexOf(t), e >= 0)
|
|
79
|
-
return this.lastItem = this.list[e], this.list[e].val;
|
|
80
|
-
};
|
|
81
|
-
I.prototype.set = function(t, e) {
|
|
82
|
-
var r;
|
|
83
|
-
return this.lastItem && this.isEqual(this.lastItem.key, t) ? (this.lastItem.val = e, this) : (r = this.indexOf(t), r >= 0 ? (this.lastItem =
|
|
84
|
-
this.list[r], this.list[r].val = e, this) : (this.lastItem = { key: t, val: e }, this.list.push(this.lastItem), this.size++, this));
|
|
85
|
-
};
|
|
86
|
-
I.prototype.delete = function(t) {
|
|
87
|
-
var e;
|
|
88
|
-
if (this.lastItem && this.isEqual(this.lastItem.key, t) && (this.lastItem = void 0), e = this.indexOf(t), e >= 0)
|
|
89
|
-
return this.size--, this.list.splice(e, 1)[0];
|
|
90
|
-
};
|
|
91
|
-
I.prototype.has = function(t) {
|
|
92
|
-
var e;
|
|
93
|
-
return this.lastItem && this.isEqual(this.lastItem.key, t) ? !0 : (e = this.indexOf(t), e >= 0 ? (this.lastItem = this.list[e], !0) : !1);
|
|
94
|
-
};
|
|
95
|
-
I.prototype.forEach = function(t, e) {
|
|
96
|
-
var r;
|
|
97
|
-
for (r = 0; r < this.size; r++)
|
|
98
|
-
t.call(e || this, this.list[r].val, this.list[r].key, this);
|
|
99
|
-
};
|
|
100
|
-
I.prototype.indexOf = function(t) {
|
|
101
|
-
var e;
|
|
102
|
-
for (e = 0; e < this.size; e++)
|
|
103
|
-
if (this.isEqual(this.list[e].key, t))
|
|
104
|
-
return e;
|
|
105
|
-
return -1;
|
|
106
|
-
};
|
|
107
|
-
I.prototype.isEqual = function(t, e) {
|
|
108
|
-
return t === e || t !== t && e !== e;
|
|
109
|
-
};
|
|
110
|
-
ye.exports = I;
|
|
111
|
-
});
|
|
112
|
-
|
|
113
|
-
// ../node_modules/map-or-similar/src/map-or-similar.js
|
|
114
|
-
var me = J((ct, ge) => {
|
|
115
|
-
ge.exports = function(t) {
|
|
116
|
-
if (typeof Map != "function" || t) {
|
|
117
|
-
var e = de();
|
|
118
|
-
return new e();
|
|
119
|
-
} else
|
|
120
|
-
return /* @__PURE__ */ new Map();
|
|
121
|
-
};
|
|
122
|
-
});
|
|
123
|
-
|
|
124
|
-
// ../node_modules/memoizerific/src/memoizerific.js
|
|
125
|
-
var Ee = J((ut, _e) => {
|
|
126
|
-
var ve = me();
|
|
127
|
-
_e.exports = function(t) {
|
|
128
|
-
var e = new ve(process.env.FORCE_SIMILAR_INSTEAD_OF_MAP === "true"), r = [];
|
|
129
|
-
return function(n) {
|
|
130
|
-
var a = /* @__PURE__ */ o(function() {
|
|
131
|
-
var s = e, l, c, i = arguments.length - 1, h = Array(i + 1), p = !0, u;
|
|
132
|
-
if ((a.numArgs || a.numArgs === 0) && a.numArgs !== i + 1)
|
|
133
|
-
throw new Error("Memoizerific functions should always be called with the same number of arguments");
|
|
134
|
-
for (u = 0; u < i; u++) {
|
|
135
|
-
if (h[u] = {
|
|
136
|
-
cacheItem: s,
|
|
137
|
-
arg: arguments[u]
|
|
138
|
-
}, s.has(arguments[u])) {
|
|
139
|
-
s = s.get(arguments[u]);
|
|
140
|
-
continue;
|
|
141
|
-
}
|
|
142
|
-
p = !1, l = new ve(process.env.FORCE_SIMILAR_INSTEAD_OF_MAP === "true"), s.set(arguments[u], l), s = l;
|
|
143
|
-
}
|
|
144
|
-
return p && (s.has(arguments[i]) ? c = s.get(arguments[i]) : p = !1), p || (c = n.apply(null, arguments), s.set(arguments[i], c)), t >
|
|
145
|
-
0 && (h[i] = {
|
|
146
|
-
cacheItem: s,
|
|
147
|
-
arg: arguments[i]
|
|
148
|
-
}, p ? Ge(r, h) : r.push(h), r.length > t && He(r.shift())), a.wasMemoized = p, a.numArgs = i + 1, c;
|
|
149
|
-
}, "memoizerific");
|
|
150
|
-
return a.limit = t, a.wasMemoized = !1, a.cache = e, a.lru = r, a;
|
|
151
|
-
};
|
|
152
|
-
};
|
|
153
|
-
function Ge(t, e) {
|
|
154
|
-
var r = t.length, n = e.length, a, s, l;
|
|
155
|
-
for (s = 0; s < r; s++) {
|
|
156
|
-
for (a = !0, l = 0; l < n; l++)
|
|
157
|
-
if (!We(t[s][l].arg, e[l].arg)) {
|
|
158
|
-
a = !1;
|
|
159
|
-
break;
|
|
160
|
-
}
|
|
161
|
-
if (a)
|
|
162
|
-
break;
|
|
163
|
-
}
|
|
164
|
-
t.push(t.splice(s, 1)[0]);
|
|
165
|
-
}
|
|
166
|
-
o(Ge, "moveToMostRecentLru");
|
|
167
|
-
function He(t) {
|
|
168
|
-
var e = t.length, r = t[e - 1], n, a;
|
|
169
|
-
for (r.cacheItem.delete(r.arg), a = e - 2; a >= 0 && (r = t[a], n = r.cacheItem.get(r.arg), !n || !n.size); a--)
|
|
170
|
-
r.cacheItem.delete(r.arg);
|
|
171
|
-
}
|
|
172
|
-
o(He, "removeCachedResult");
|
|
173
|
-
function We(t, e) {
|
|
174
|
-
return t === e || t !== t && e !== e;
|
|
175
|
-
}
|
|
176
|
-
o(We, "isEqual");
|
|
63
|
+
s(qe, "dedent");
|
|
64
|
+
te.dedent = qe;
|
|
65
|
+
te.default = qe;
|
|
177
66
|
});
|
|
178
67
|
|
|
179
68
|
// ../node_modules/telejson/dist/index.js
|
|
180
|
-
var
|
|
69
|
+
var Ne = ke((ms, Et) => {
|
|
181
70
|
"use strict";
|
|
182
|
-
var
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
}, "__require"), "__commonJS"), __export = /* @__PURE__ */ o((t, e) => {
|
|
71
|
+
var zt = Object.create, fe = Object.defineProperty, Yt = Object.getOwnPropertyDescriptor, Ke = Object.getOwnPropertyNames, Kt = Object.getPrototypeOf,
|
|
72
|
+
Xt = Object.prototype.hasOwnProperty, f = /* @__PURE__ */ s((t, e) => /* @__PURE__ */ s(function() {
|
|
73
|
+
return e || (0, t[Ke(t)[0]])((e = { exports: {} }).exports, e), e.exports;
|
|
74
|
+
}, "__require"), "__commonJS"), Qt = /* @__PURE__ */ s((t, e) => {
|
|
187
75
|
for (var r in e)
|
|
188
|
-
|
|
189
|
-
}, "__export"),
|
|
76
|
+
fe(t, r, { get: e[r], enumerable: !0 });
|
|
77
|
+
}, "__export"), Xe = /* @__PURE__ */ s((t, e, r, n) => {
|
|
190
78
|
if (e && typeof e == "object" || typeof e == "function")
|
|
191
|
-
for (let
|
|
192
|
-
!
|
|
193
|
-
e, a)) || n.enumerable });
|
|
79
|
+
for (let o of Ke(e))
|
|
80
|
+
!Xt.call(t, o) && o !== r && fe(t, o, { get: /* @__PURE__ */ s(() => e[o], "get"), enumerable: !(n = Yt(e, o)) || n.enumerable });
|
|
194
81
|
return t;
|
|
195
|
-
}, "__copyProps"),
|
|
196
|
-
|
|
82
|
+
}, "__copyProps"), _e = /* @__PURE__ */ s((t, e, r) => (r = t != null ? zt(Kt(t)) : {}, Xe(
|
|
83
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
84
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
85
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
86
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
87
|
+
e || !t || !t.__esModule ? fe(r, "default", { value: t, enumerable: !0 }) : r,
|
|
197
88
|
t
|
|
198
|
-
)), "__toESM"),
|
|
199
|
-
|
|
200
|
-
|
|
89
|
+
)), "__toESM"), Zt = /* @__PURE__ */ s((t) => Xe(fe({}, "__esModule", { value: !0 }), t), "__toCommonJS"), Qe = f({
|
|
90
|
+
"node_modules/.pnpm/es-object-atoms@1.1.1/node_modules/es-object-atoms/index.js"(t, e) {
|
|
91
|
+
"use strict";
|
|
92
|
+
e.exports = Object;
|
|
93
|
+
}
|
|
94
|
+
}), er = f({
|
|
95
|
+
"node_modules/.pnpm/es-errors@1.3.0/node_modules/es-errors/index.js"(t, e) {
|
|
96
|
+
"use strict";
|
|
97
|
+
e.exports = Error;
|
|
98
|
+
}
|
|
99
|
+
}), tr = f({
|
|
100
|
+
"node_modules/.pnpm/es-errors@1.3.0/node_modules/es-errors/eval.js"(t, e) {
|
|
101
|
+
"use strict";
|
|
102
|
+
e.exports = EvalError;
|
|
103
|
+
}
|
|
104
|
+
}), rr = f({
|
|
105
|
+
"node_modules/.pnpm/es-errors@1.3.0/node_modules/es-errors/range.js"(t, e) {
|
|
106
|
+
"use strict";
|
|
107
|
+
e.exports = RangeError;
|
|
108
|
+
}
|
|
109
|
+
}), nr = f({
|
|
110
|
+
"node_modules/.pnpm/es-errors@1.3.0/node_modules/es-errors/ref.js"(t, e) {
|
|
111
|
+
"use strict";
|
|
112
|
+
e.exports = ReferenceError;
|
|
113
|
+
}
|
|
114
|
+
}), or = f({
|
|
115
|
+
"node_modules/.pnpm/es-errors@1.3.0/node_modules/es-errors/syntax.js"(t, e) {
|
|
116
|
+
"use strict";
|
|
117
|
+
e.exports = SyntaxError;
|
|
118
|
+
}
|
|
119
|
+
}), be = f({
|
|
120
|
+
"node_modules/.pnpm/es-errors@1.3.0/node_modules/es-errors/type.js"(t, e) {
|
|
121
|
+
"use strict";
|
|
122
|
+
e.exports = TypeError;
|
|
123
|
+
}
|
|
124
|
+
}), sr = f({
|
|
125
|
+
"node_modules/.pnpm/es-errors@1.3.0/node_modules/es-errors/uri.js"(t, e) {
|
|
126
|
+
"use strict";
|
|
127
|
+
e.exports = URIError;
|
|
128
|
+
}
|
|
129
|
+
}), ir = f({
|
|
130
|
+
"node_modules/.pnpm/math-intrinsics@1.1.0/node_modules/math-intrinsics/abs.js"(t, e) {
|
|
131
|
+
"use strict";
|
|
132
|
+
e.exports = Math.abs;
|
|
133
|
+
}
|
|
134
|
+
}), ar = f({
|
|
135
|
+
"node_modules/.pnpm/math-intrinsics@1.1.0/node_modules/math-intrinsics/floor.js"(t, e) {
|
|
136
|
+
"use strict";
|
|
137
|
+
e.exports = Math.floor;
|
|
138
|
+
}
|
|
139
|
+
}), pr = f({
|
|
140
|
+
"node_modules/.pnpm/math-intrinsics@1.1.0/node_modules/math-intrinsics/max.js"(t, e) {
|
|
141
|
+
"use strict";
|
|
142
|
+
e.exports = Math.max;
|
|
143
|
+
}
|
|
144
|
+
}), cr = f({
|
|
145
|
+
"node_modules/.pnpm/math-intrinsics@1.1.0/node_modules/math-intrinsics/min.js"(t, e) {
|
|
146
|
+
"use strict";
|
|
147
|
+
e.exports = Math.min;
|
|
148
|
+
}
|
|
149
|
+
}), lr = f({
|
|
150
|
+
"node_modules/.pnpm/math-intrinsics@1.1.0/node_modules/math-intrinsics/pow.js"(t, e) {
|
|
151
|
+
"use strict";
|
|
152
|
+
e.exports = Math.pow;
|
|
153
|
+
}
|
|
154
|
+
}), ur = f({
|
|
155
|
+
"node_modules/.pnpm/math-intrinsics@1.1.0/node_modules/math-intrinsics/round.js"(t, e) {
|
|
156
|
+
"use strict";
|
|
157
|
+
e.exports = Math.round;
|
|
158
|
+
}
|
|
159
|
+
}), fr = f({
|
|
160
|
+
"node_modules/.pnpm/math-intrinsics@1.1.0/node_modules/math-intrinsics/isNaN.js"(t, e) {
|
|
161
|
+
"use strict";
|
|
162
|
+
e.exports = Number.isNaN || /* @__PURE__ */ s(function(n) {
|
|
163
|
+
return n !== n;
|
|
164
|
+
}, "isNaN2");
|
|
165
|
+
}
|
|
166
|
+
}), dr = f({
|
|
167
|
+
"node_modules/.pnpm/math-intrinsics@1.1.0/node_modules/math-intrinsics/sign.js"(t, e) {
|
|
168
|
+
"use strict";
|
|
169
|
+
var r = fr();
|
|
170
|
+
e.exports = /* @__PURE__ */ s(function(o) {
|
|
171
|
+
return r(o) || o === 0 ? o : o < 0 ? -1 : 1;
|
|
172
|
+
}, "sign");
|
|
173
|
+
}
|
|
174
|
+
}), yr = f({
|
|
175
|
+
"node_modules/.pnpm/gopd@1.2.0/node_modules/gopd/gOPD.js"(t, e) {
|
|
176
|
+
"use strict";
|
|
177
|
+
e.exports = Object.getOwnPropertyDescriptor;
|
|
178
|
+
}
|
|
179
|
+
}), Se = f({
|
|
180
|
+
"node_modules/.pnpm/gopd@1.2.0/node_modules/gopd/index.js"(t, e) {
|
|
181
|
+
"use strict";
|
|
182
|
+
var r = yr();
|
|
183
|
+
if (r)
|
|
184
|
+
try {
|
|
185
|
+
r([], "length");
|
|
186
|
+
} catch {
|
|
187
|
+
r = null;
|
|
188
|
+
}
|
|
189
|
+
e.exports = r;
|
|
190
|
+
}
|
|
191
|
+
}), hr = f({
|
|
192
|
+
"node_modules/.pnpm/es-define-property@1.0.1/node_modules/es-define-property/index.js"(t, e) {
|
|
193
|
+
"use strict";
|
|
194
|
+
var r = Object.defineProperty || !1;
|
|
195
|
+
if (r)
|
|
196
|
+
try {
|
|
197
|
+
r({}, "a", { value: 1 });
|
|
198
|
+
} catch {
|
|
199
|
+
r = !1;
|
|
200
|
+
}
|
|
201
|
+
e.exports = r;
|
|
202
|
+
}
|
|
203
|
+
}), Ze = f({
|
|
204
|
+
"node_modules/.pnpm/has-symbols@1.1.0/node_modules/has-symbols/shams.js"(t, e) {
|
|
201
205
|
"use strict";
|
|
202
|
-
e.exports = /* @__PURE__ */
|
|
206
|
+
e.exports = /* @__PURE__ */ s(function() {
|
|
203
207
|
if (typeof Symbol != "function" || typeof Object.getOwnPropertySymbols != "function")
|
|
204
208
|
return !1;
|
|
205
209
|
if (typeof Symbol.iterator == "symbol")
|
|
206
210
|
return !0;
|
|
207
|
-
var n = {},
|
|
208
|
-
if (typeof
|
|
211
|
+
var n = {}, o = Symbol("test"), p = Object(o);
|
|
212
|
+
if (typeof o == "string" || Object.prototype.toString.call(o) !== "[object Symbol]" || Object.prototype.toString.call(p) !== "[objec\
|
|
209
213
|
t Symbol]")
|
|
210
214
|
return !1;
|
|
211
|
-
var
|
|
212
|
-
n[
|
|
213
|
-
for (
|
|
215
|
+
var a = 42;
|
|
216
|
+
n[o] = a;
|
|
217
|
+
for (var c in n)
|
|
214
218
|
return !1;
|
|
215
219
|
if (typeof Object.keys == "function" && Object.keys(n).length !== 0 || typeof Object.getOwnPropertyNames == "function" && Object.getOwnPropertyNames(
|
|
216
220
|
n).length !== 0)
|
|
217
221
|
return !1;
|
|
218
|
-
var
|
|
219
|
-
if (
|
|
222
|
+
var i = Object.getOwnPropertySymbols(n);
|
|
223
|
+
if (i.length !== 1 || i[0] !== o || !Object.prototype.propertyIsEnumerable.call(n, o))
|
|
220
224
|
return !1;
|
|
221
225
|
if (typeof Object.getOwnPropertyDescriptor == "function") {
|
|
222
|
-
var
|
|
223
|
-
|
|
226
|
+
var l = (
|
|
227
|
+
/** @type {PropertyDescriptor} */
|
|
228
|
+
Object.getOwnPropertyDescriptor(n, o)
|
|
229
|
+
);
|
|
230
|
+
if (l.value !== a || l.enumerable !== !0)
|
|
224
231
|
return !1;
|
|
225
232
|
}
|
|
226
233
|
return !0;
|
|
227
234
|
}, "hasSymbols");
|
|
228
235
|
}
|
|
229
|
-
}),
|
|
230
|
-
"node_modules/has-symbols/index.js"(t, e) {
|
|
236
|
+
}), et = f({
|
|
237
|
+
"node_modules/.pnpm/has-symbols@1.1.0/node_modules/has-symbols/index.js"(t, e) {
|
|
231
238
|
"use strict";
|
|
232
|
-
var r = typeof Symbol < "u" && Symbol, n =
|
|
233
|
-
e.exports = /* @__PURE__ */
|
|
239
|
+
var r = typeof Symbol < "u" && Symbol, n = Ze();
|
|
240
|
+
e.exports = /* @__PURE__ */ s(function() {
|
|
234
241
|
return typeof r != "function" || typeof Symbol != "function" || typeof r("foo") != "symbol" || typeof Symbol("bar") != "symbol" ? !1 :
|
|
235
242
|
n();
|
|
236
243
|
}, "hasNativeSymbols");
|
|
237
244
|
}
|
|
238
|
-
}),
|
|
239
|
-
"node_modules/
|
|
245
|
+
}), tt = f({
|
|
246
|
+
"node_modules/.pnpm/get-proto@1.0.1/node_modules/get-proto/Reflect.getPrototypeOf.js"(t, e) {
|
|
247
|
+
"use strict";
|
|
248
|
+
e.exports = typeof Reflect < "u" && Reflect.getPrototypeOf || null;
|
|
249
|
+
}
|
|
250
|
+
}), rt = f({
|
|
251
|
+
"node_modules/.pnpm/get-proto@1.0.1/node_modules/get-proto/Object.getPrototypeOf.js"(t, e) {
|
|
240
252
|
"use strict";
|
|
241
|
-
var r =
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
253
|
+
var r = Qe();
|
|
254
|
+
e.exports = r.getPrototypeOf || null;
|
|
255
|
+
}
|
|
256
|
+
}), gr = f({
|
|
257
|
+
"node_modules/.pnpm/function-bind@1.1.2/node_modules/function-bind/implementation.js"(t, e) {
|
|
258
|
+
"use strict";
|
|
259
|
+
var r = "Function.prototype.bind called on incompatible ", n = Object.prototype.toString, o = Math.max, p = "[object Function]", a = /* @__PURE__ */ s(
|
|
260
|
+
function(d, u) {
|
|
261
|
+
for (var y = [], g = 0; g < d.length; g += 1)
|
|
262
|
+
y[g] = d[g];
|
|
263
|
+
for (var h = 0; h < u.length; h += 1)
|
|
264
|
+
y[h + d.length] = u[h];
|
|
265
|
+
return y;
|
|
266
|
+
}, "concatty2"), c = /* @__PURE__ */ s(function(d, u) {
|
|
267
|
+
for (var y = [], g = u || 0, h = 0; g < d.length; g += 1, h += 1)
|
|
268
|
+
y[h] = d[g];
|
|
269
|
+
return y;
|
|
270
|
+
}, "slicy2"), i = /* @__PURE__ */ s(function(l, d) {
|
|
271
|
+
for (var u = "", y = 0; y < l.length; y += 1)
|
|
272
|
+
u += l[y], y + 1 < l.length && (u += d);
|
|
273
|
+
return u;
|
|
274
|
+
}, "joiny");
|
|
275
|
+
e.exports = /* @__PURE__ */ s(function(d) {
|
|
276
|
+
var u = this;
|
|
277
|
+
if (typeof u != "function" || n.apply(u) !== p)
|
|
278
|
+
throw new TypeError(r + u);
|
|
279
|
+
for (var y = c(arguments, 1), g, h = /* @__PURE__ */ s(function() {
|
|
280
|
+
if (this instanceof g) {
|
|
281
|
+
var I = u.apply(
|
|
250
282
|
this,
|
|
251
|
-
|
|
252
|
-
);
|
|
253
|
-
return Object(T) === T ? T : this;
|
|
254
|
-
} else
|
|
255
|
-
return i.apply(
|
|
256
|
-
c,
|
|
257
|
-
h.concat(n.call(arguments))
|
|
283
|
+
a(y, arguments)
|
|
258
284
|
);
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
285
|
+
return Object(I) === I ? I : this;
|
|
286
|
+
}
|
|
287
|
+
return u.apply(
|
|
288
|
+
d,
|
|
289
|
+
a(y, arguments)
|
|
290
|
+
);
|
|
291
|
+
}, "binder"), C = o(0, u.length - y.length), w = [], A = 0; A < C; A++)
|
|
292
|
+
w[A] = "$" + A;
|
|
293
|
+
if (g = Function("binder", "return function (" + i(w, ",") + "){ return binder.apply(this,arguments); }")(h), u.prototype) {
|
|
294
|
+
var L = /* @__PURE__ */ s(function() {
|
|
263
295
|
}, "Empty2");
|
|
264
|
-
|
|
296
|
+
L.prototype = u.prototype, g.prototype = new L(), L.prototype = null;
|
|
265
297
|
}
|
|
266
|
-
return
|
|
298
|
+
return g;
|
|
267
299
|
}, "bind");
|
|
268
300
|
}
|
|
269
|
-
}),
|
|
270
|
-
"node_modules/function-bind/index.js"(t, e) {
|
|
301
|
+
}), de = f({
|
|
302
|
+
"node_modules/.pnpm/function-bind@1.1.2/node_modules/function-bind/index.js"(t, e) {
|
|
271
303
|
"use strict";
|
|
272
|
-
var r =
|
|
304
|
+
var r = gr();
|
|
273
305
|
e.exports = Function.prototype.bind || r;
|
|
274
306
|
}
|
|
275
|
-
}),
|
|
276
|
-
"node_modules/
|
|
307
|
+
}), Te = f({
|
|
308
|
+
"node_modules/.pnpm/call-bind-apply-helpers@1.0.2/node_modules/call-bind-apply-helpers/functionCall.js"(t, e) {
|
|
277
309
|
"use strict";
|
|
278
|
-
|
|
279
|
-
e.exports = r.call(Function.call, Object.prototype.hasOwnProperty);
|
|
310
|
+
e.exports = Function.prototype.call;
|
|
280
311
|
}
|
|
281
|
-
}),
|
|
282
|
-
"node_modules/
|
|
312
|
+
}), nt = f({
|
|
313
|
+
"node_modules/.pnpm/call-bind-apply-helpers@1.0.2/node_modules/call-bind-apply-helpers/functionApply.js"(t, e) {
|
|
283
314
|
"use strict";
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
315
|
+
e.exports = Function.prototype.apply;
|
|
316
|
+
}
|
|
317
|
+
}), mr = f({
|
|
318
|
+
"node_modules/.pnpm/call-bind-apply-helpers@1.0.2/node_modules/call-bind-apply-helpers/reflectApply.js"(t, e) {
|
|
319
|
+
"use strict";
|
|
320
|
+
e.exports = typeof Reflect < "u" && Reflect && Reflect.apply;
|
|
321
|
+
}
|
|
322
|
+
}), vr = f({
|
|
323
|
+
"node_modules/.pnpm/call-bind-apply-helpers@1.0.2/node_modules/call-bind-apply-helpers/actualApply.js"(t, e) {
|
|
324
|
+
"use strict";
|
|
325
|
+
var r = de(), n = nt(), o = Te(), p = mr();
|
|
326
|
+
e.exports = p || r.call(o, n);
|
|
327
|
+
}
|
|
328
|
+
}), ot = f({
|
|
329
|
+
"node_modules/.pnpm/call-bind-apply-helpers@1.0.2/node_modules/call-bind-apply-helpers/index.js"(t, e) {
|
|
330
|
+
"use strict";
|
|
331
|
+
var r = de(), n = be(), o = Te(), p = vr();
|
|
332
|
+
e.exports = /* @__PURE__ */ s(function(c) {
|
|
333
|
+
if (c.length < 1 || typeof c[0] != "function")
|
|
334
|
+
throw new n("a function is required");
|
|
335
|
+
return p(r, o, c);
|
|
336
|
+
}, "callBindBasic");
|
|
337
|
+
}
|
|
338
|
+
}), Er = f({
|
|
339
|
+
"node_modules/.pnpm/dunder-proto@1.0.1/node_modules/dunder-proto/get.js"(t, e) {
|
|
340
|
+
"use strict";
|
|
341
|
+
var r = ot(), n = Se(), o;
|
|
342
|
+
try {
|
|
343
|
+
o = /** @type {{ __proto__?: typeof Array.prototype }} */
|
|
344
|
+
[].__proto__ === Array.prototype;
|
|
345
|
+
} catch (i) {
|
|
346
|
+
if (!i || typeof i != "object" || !("code" in i) || i.code !== "ERR_PROTO_ACCESS")
|
|
347
|
+
throw i;
|
|
348
|
+
}
|
|
349
|
+
var p = !!o && n && n(
|
|
350
|
+
Object.prototype,
|
|
351
|
+
/** @type {keyof typeof Object.prototype} */
|
|
352
|
+
"__proto__"
|
|
353
|
+
), a = Object, c = a.getPrototypeOf;
|
|
354
|
+
e.exports = p && typeof p.get == "function" ? r([p.get]) : typeof c == "function" ? (
|
|
355
|
+
/** @type {import('./get')} */
|
|
356
|
+
/* @__PURE__ */ s(function(l) {
|
|
357
|
+
return c(l == null ? l : a(l));
|
|
358
|
+
}, "getDunder")
|
|
359
|
+
) : !1;
|
|
360
|
+
}
|
|
361
|
+
}), _r = f({
|
|
362
|
+
"node_modules/.pnpm/get-proto@1.0.1/node_modules/get-proto/index.js"(t, e) {
|
|
363
|
+
"use strict";
|
|
364
|
+
var r = tt(), n = rt(), o = Er();
|
|
365
|
+
e.exports = r ? /* @__PURE__ */ s(function(a) {
|
|
366
|
+
return r(a);
|
|
367
|
+
}, "getProto") : n ? /* @__PURE__ */ s(function(a) {
|
|
368
|
+
if (!a || typeof a != "object" && typeof a != "function")
|
|
369
|
+
throw new TypeError("getProto: not an object");
|
|
370
|
+
return n(a);
|
|
371
|
+
}, "getProto") : o ? /* @__PURE__ */ s(function(a) {
|
|
372
|
+
return o(a);
|
|
373
|
+
}, "getProto") : null;
|
|
374
|
+
}
|
|
375
|
+
}), st = f({
|
|
376
|
+
"node_modules/.pnpm/hasown@2.0.2/node_modules/hasown/index.js"(t, e) {
|
|
377
|
+
"use strict";
|
|
378
|
+
var r = Function.prototype.call, n = Object.prototype.hasOwnProperty, o = de();
|
|
379
|
+
e.exports = o.call(r, n);
|
|
380
|
+
}
|
|
381
|
+
}), br = f({
|
|
382
|
+
"node_modules/.pnpm/get-intrinsic@1.3.0/node_modules/get-intrinsic/index.js"(t, e) {
|
|
383
|
+
"use strict";
|
|
384
|
+
var r, n = Qe(), o = er(), p = tr(), a = rr(), c = nr(), i = or(), l = be(), d = sr(), u = ir(), y = ar(), g = pr(), h = cr(), C = lr(),
|
|
385
|
+
w = ur(), A = dr(), L = Function, I = /* @__PURE__ */ s(function(P) {
|
|
291
386
|
try {
|
|
292
|
-
|
|
387
|
+
return L('"use strict"; return (' + P + ").constructor;")();
|
|
293
388
|
} catch {
|
|
294
|
-
c = null;
|
|
295
389
|
}
|
|
296
|
-
|
|
297
|
-
throw new
|
|
298
|
-
}, "throwTypeError"),
|
|
390
|
+
}, "getEvalledConstructor"), Y = Se(), xt = hr(), ge = /* @__PURE__ */ s(function() {
|
|
391
|
+
throw new l();
|
|
392
|
+
}, "throwTypeError"), wt = Y ? function() {
|
|
299
393
|
try {
|
|
300
|
-
return arguments.callee,
|
|
394
|
+
return arguments.callee, ge;
|
|
301
395
|
} catch {
|
|
302
396
|
try {
|
|
303
|
-
return
|
|
397
|
+
return Y(arguments, "callee").get;
|
|
304
398
|
} catch {
|
|
305
|
-
return
|
|
399
|
+
return ge;
|
|
306
400
|
}
|
|
307
401
|
}
|
|
308
|
-
}() :
|
|
309
|
-
|
|
310
|
-
|
|
402
|
+
}() : ge, D = et()(), E = _r(), Pt = rt(), Ot = tt(), Fe = nt(), K = Te(), $ = {}, Ct = typeof Uint8Array > "u" || !E ? r : E(Uint8Array),
|
|
403
|
+
R = {
|
|
404
|
+
__proto__: null,
|
|
311
405
|
"%AggregateError%": typeof AggregateError > "u" ? r : AggregateError,
|
|
312
406
|
"%Array%": Array,
|
|
313
407
|
"%ArrayBuffer%": typeof ArrayBuffer > "u" ? r : ArrayBuffer,
|
|
314
|
-
"%ArrayIteratorPrototype%":
|
|
408
|
+
"%ArrayIteratorPrototype%": D && E ? E([][Symbol.iterator]()) : r,
|
|
315
409
|
"%AsyncFromSyncIteratorPrototype%": r,
|
|
316
|
-
"%AsyncFunction%":
|
|
317
|
-
"%AsyncGenerator%":
|
|
318
|
-
"%AsyncGeneratorFunction%":
|
|
319
|
-
"%AsyncIteratorPrototype%":
|
|
410
|
+
"%AsyncFunction%": $,
|
|
411
|
+
"%AsyncGenerator%": $,
|
|
412
|
+
"%AsyncGeneratorFunction%": $,
|
|
413
|
+
"%AsyncIteratorPrototype%": $,
|
|
320
414
|
"%Atomics%": typeof Atomics > "u" ? r : Atomics,
|
|
321
415
|
"%BigInt%": typeof BigInt > "u" ? r : BigInt,
|
|
416
|
+
"%BigInt64Array%": typeof BigInt64Array > "u" ? r : BigInt64Array,
|
|
417
|
+
"%BigUint64Array%": typeof BigUint64Array > "u" ? r : BigUint64Array,
|
|
322
418
|
"%Boolean%": Boolean,
|
|
323
419
|
"%DataView%": typeof DataView > "u" ? r : DataView,
|
|
324
420
|
"%Date%": Date,
|
|
@@ -326,69 +422,92 @@ tion]";
|
|
|
326
422
|
"%decodeURIComponent%": decodeURIComponent,
|
|
327
423
|
"%encodeURI%": encodeURI,
|
|
328
424
|
"%encodeURIComponent%": encodeURIComponent,
|
|
329
|
-
"%Error%":
|
|
425
|
+
"%Error%": o,
|
|
330
426
|
"%eval%": eval,
|
|
331
|
-
|
|
427
|
+
// eslint-disable-line no-eval
|
|
428
|
+
"%EvalError%": p,
|
|
429
|
+
"%Float16Array%": typeof Float16Array > "u" ? r : Float16Array,
|
|
332
430
|
"%Float32Array%": typeof Float32Array > "u" ? r : Float32Array,
|
|
333
431
|
"%Float64Array%": typeof Float64Array > "u" ? r : Float64Array,
|
|
334
432
|
"%FinalizationRegistry%": typeof FinalizationRegistry > "u" ? r : FinalizationRegistry,
|
|
335
|
-
"%Function%":
|
|
336
|
-
"%GeneratorFunction%":
|
|
433
|
+
"%Function%": L,
|
|
434
|
+
"%GeneratorFunction%": $,
|
|
337
435
|
"%Int8Array%": typeof Int8Array > "u" ? r : Int8Array,
|
|
338
436
|
"%Int16Array%": typeof Int16Array > "u" ? r : Int16Array,
|
|
339
437
|
"%Int32Array%": typeof Int32Array > "u" ? r : Int32Array,
|
|
340
438
|
"%isFinite%": isFinite,
|
|
341
439
|
"%isNaN%": isNaN,
|
|
342
|
-
"%IteratorPrototype%":
|
|
440
|
+
"%IteratorPrototype%": D && E ? E(E([][Symbol.iterator]())) : r,
|
|
343
441
|
"%JSON%": typeof JSON == "object" ? JSON : r,
|
|
344
442
|
"%Map%": typeof Map > "u" ? r : Map,
|
|
345
|
-
"%MapIteratorPrototype%": typeof Map > "u" || !
|
|
443
|
+
"%MapIteratorPrototype%": typeof Map > "u" || !D || !E ? r : E((/* @__PURE__ */ new Map())[Symbol.iterator]()),
|
|
346
444
|
"%Math%": Math,
|
|
347
445
|
"%Number%": Number,
|
|
348
|
-
"%Object%":
|
|
446
|
+
"%Object%": n,
|
|
447
|
+
"%Object.getOwnPropertyDescriptor%": Y,
|
|
349
448
|
"%parseFloat%": parseFloat,
|
|
350
449
|
"%parseInt%": parseInt,
|
|
351
450
|
"%Promise%": typeof Promise > "u" ? r : Promise,
|
|
352
451
|
"%Proxy%": typeof Proxy > "u" ? r : Proxy,
|
|
353
|
-
"%RangeError%":
|
|
354
|
-
"%ReferenceError%":
|
|
452
|
+
"%RangeError%": a,
|
|
453
|
+
"%ReferenceError%": c,
|
|
355
454
|
"%Reflect%": typeof Reflect > "u" ? r : Reflect,
|
|
356
455
|
"%RegExp%": RegExp,
|
|
357
456
|
"%Set%": typeof Set > "u" ? r : Set,
|
|
358
|
-
"%SetIteratorPrototype%": typeof Set > "u" || !
|
|
457
|
+
"%SetIteratorPrototype%": typeof Set > "u" || !D || !E ? r : E((/* @__PURE__ */ new Set())[Symbol.iterator]()),
|
|
359
458
|
"%SharedArrayBuffer%": typeof SharedArrayBuffer > "u" ? r : SharedArrayBuffer,
|
|
360
459
|
"%String%": String,
|
|
361
|
-
"%StringIteratorPrototype%":
|
|
362
|
-
"%Symbol%":
|
|
363
|
-
"%SyntaxError%":
|
|
364
|
-
"%ThrowTypeError%":
|
|
365
|
-
"%TypedArray%":
|
|
366
|
-
"%TypeError%":
|
|
460
|
+
"%StringIteratorPrototype%": D && E ? E(""[Symbol.iterator]()) : r,
|
|
461
|
+
"%Symbol%": D ? Symbol : r,
|
|
462
|
+
"%SyntaxError%": i,
|
|
463
|
+
"%ThrowTypeError%": wt,
|
|
464
|
+
"%TypedArray%": Ct,
|
|
465
|
+
"%TypeError%": l,
|
|
367
466
|
"%Uint8Array%": typeof Uint8Array > "u" ? r : Uint8Array,
|
|
368
467
|
"%Uint8ClampedArray%": typeof Uint8ClampedArray > "u" ? r : Uint8ClampedArray,
|
|
369
468
|
"%Uint16Array%": typeof Uint16Array > "u" ? r : Uint16Array,
|
|
370
469
|
"%Uint32Array%": typeof Uint32Array > "u" ? r : Uint32Array,
|
|
371
|
-
"%URIError%":
|
|
470
|
+
"%URIError%": d,
|
|
372
471
|
"%WeakMap%": typeof WeakMap > "u" ? r : WeakMap,
|
|
373
472
|
"%WeakRef%": typeof WeakRef > "u" ? r : WeakRef,
|
|
374
|
-
"%WeakSet%": typeof WeakSet > "u" ? r : WeakSet
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
473
|
+
"%WeakSet%": typeof WeakSet > "u" ? r : WeakSet,
|
|
474
|
+
"%Function.prototype.call%": K,
|
|
475
|
+
"%Function.prototype.apply%": Fe,
|
|
476
|
+
"%Object.defineProperty%": xt,
|
|
477
|
+
"%Object.getPrototypeOf%": Pt,
|
|
478
|
+
"%Math.abs%": u,
|
|
479
|
+
"%Math.floor%": y,
|
|
480
|
+
"%Math.max%": g,
|
|
481
|
+
"%Math.min%": h,
|
|
482
|
+
"%Math.pow%": C,
|
|
483
|
+
"%Math.round%": w,
|
|
484
|
+
"%Math.sign%": A,
|
|
485
|
+
"%Reflect.getPrototypeOf%": Ot
|
|
486
|
+
};
|
|
487
|
+
if (E)
|
|
488
|
+
try {
|
|
489
|
+
null.error;
|
|
490
|
+
} catch (P) {
|
|
491
|
+
Me = E(E(P)), R["%Error.prototype%"] = Me;
|
|
389
492
|
}
|
|
390
|
-
|
|
391
|
-
|
|
493
|
+
var Me, Nt = /* @__PURE__ */ s(function P(m) {
|
|
494
|
+
var b;
|
|
495
|
+
if (m === "%AsyncFunction%")
|
|
496
|
+
b = I("async function () {}");
|
|
497
|
+
else if (m === "%GeneratorFunction%")
|
|
498
|
+
b = I("function* () {}");
|
|
499
|
+
else if (m === "%AsyncGeneratorFunction%")
|
|
500
|
+
b = I("async function* () {}");
|
|
501
|
+
else if (m === "%AsyncGenerator%") {
|
|
502
|
+
var v = P("%AsyncGeneratorFunction%");
|
|
503
|
+
v && (b = v.prototype);
|
|
504
|
+
} else if (m === "%AsyncIteratorPrototype%") {
|
|
505
|
+
var S = P("%AsyncGenerator%");
|
|
506
|
+
S && E && (b = E(S.prototype));
|
|
507
|
+
}
|
|
508
|
+
return R[m] = b, b;
|
|
509
|
+
}, "doEval2"), Ue = {
|
|
510
|
+
__proto__: null,
|
|
392
511
|
"%ArrayBufferPrototype%": ["ArrayBuffer", "prototype"],
|
|
393
512
|
"%ArrayPrototype%": ["Array", "prototype"],
|
|
394
513
|
"%ArrayProto_entries%": ["Array", "prototype", "entries"],
|
|
@@ -440,270 +559,265 @@ tion]";
|
|
|
440
559
|
"%URIErrorPrototype%": ["URIError", "prototype"],
|
|
441
560
|
"%WeakMapPrototype%": ["WeakMap", "prototype"],
|
|
442
561
|
"%WeakSetPrototype%": ["WeakSet", "prototype"]
|
|
443
|
-
},
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
throw new s("intrinsic " + g + " exists, but is not available. Please file an issue!");
|
|
562
|
+
}, X = de(), se = st(), It = X.call(K, Array.prototype.concat), Rt = X.call(Fe, Array.prototype.splice), Ge = X.call(K, String.prototype.
|
|
563
|
+
replace), ie = X.call(K, String.prototype.slice), jt = X.call(K, RegExp.prototype.exec), Lt = /[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,
|
|
564
|
+
Dt = /\\(\\)?/g, $t = /* @__PURE__ */ s(function(m) {
|
|
565
|
+
var b = ie(m, 0, 1), v = ie(m, -1);
|
|
566
|
+
if (b === "%" && v !== "%")
|
|
567
|
+
throw new i("invalid intrinsic syntax, expected closing `%`");
|
|
568
|
+
if (v === "%" && b !== "%")
|
|
569
|
+
throw new i("invalid intrinsic syntax, expected opening `%`");
|
|
570
|
+
var S = [];
|
|
571
|
+
return Ge(m, Lt, function(O, F, T, ae) {
|
|
572
|
+
S[S.length] = T ? Ge(ae, Dt, "$1") : F || O;
|
|
573
|
+
}), S;
|
|
574
|
+
}, "stringToPath3"), Ft = /* @__PURE__ */ s(function(m, b) {
|
|
575
|
+
var v = m, S;
|
|
576
|
+
if (se(Ue, v) && (S = Ue[v], v = "%" + S[0] + "%"), se(R, v)) {
|
|
577
|
+
var O = R[v];
|
|
578
|
+
if (O === $ && (O = Nt(v)), typeof O > "u" && !b)
|
|
579
|
+
throw new l("intrinsic " + m + " exists, but is not available. Please file an issue!");
|
|
462
580
|
return {
|
|
463
|
-
alias:
|
|
464
|
-
name:
|
|
581
|
+
alias: S,
|
|
582
|
+
name: v,
|
|
465
583
|
value: O
|
|
466
584
|
};
|
|
467
585
|
}
|
|
468
|
-
throw new
|
|
586
|
+
throw new i("intrinsic " + m + " does not exist!");
|
|
469
587
|
}, "getBaseIntrinsic2");
|
|
470
|
-
e.exports = /* @__PURE__ */
|
|
471
|
-
if (typeof
|
|
472
|
-
throw new
|
|
473
|
-
if (arguments.length > 1 && typeof
|
|
474
|
-
throw new
|
|
475
|
-
if (
|
|
476
|
-
throw new
|
|
477
|
-
var
|
|
478
|
-
|
|
479
|
-
for (var
|
|
480
|
-
var
|
|
481
|
-
if ((
|
|
482
|
-
throw new
|
|
483
|
-
if ((
|
|
484
|
-
|
|
485
|
-
else if (
|
|
486
|
-
if (!(
|
|
487
|
-
if (!
|
|
488
|
-
throw new
|
|
588
|
+
e.exports = /* @__PURE__ */ s(function(m, b) {
|
|
589
|
+
if (typeof m != "string" || m.length === 0)
|
|
590
|
+
throw new l("intrinsic name must be a non-empty string");
|
|
591
|
+
if (arguments.length > 1 && typeof b != "boolean")
|
|
592
|
+
throw new l('"allowMissing" argument must be a boolean');
|
|
593
|
+
if (jt(/^%?[^%]*%?$/, m) === null)
|
|
594
|
+
throw new i("`%` may not be present anywhere but at the beginning and end of the intrinsic name");
|
|
595
|
+
var v = $t(m), S = v.length > 0 ? v[0] : "", O = Ft("%" + S + "%", b), F = O.name, T = O.value, ae = !1, me = O.alias;
|
|
596
|
+
me && (S = me[0], Rt(v, It([0, 1], me)));
|
|
597
|
+
for (var pe = 1, Q = !0; pe < v.length; pe += 1) {
|
|
598
|
+
var N = v[pe], ce = ie(N, 0, 1), le = ie(N, -1);
|
|
599
|
+
if ((ce === '"' || ce === "'" || ce === "`" || le === '"' || le === "'" || le === "`") && ce !== le)
|
|
600
|
+
throw new i("property names with quotes must have matching quotes");
|
|
601
|
+
if ((N === "constructor" || !Q) && (ae = !0), S += "." + N, F = "%" + S + "%", se(R, F))
|
|
602
|
+
T = R[F];
|
|
603
|
+
else if (T != null) {
|
|
604
|
+
if (!(N in T)) {
|
|
605
|
+
if (!b)
|
|
606
|
+
throw new l("base intrinsic for " + m + " exists, but the property is not available.");
|
|
489
607
|
return;
|
|
490
608
|
}
|
|
491
|
-
if (
|
|
492
|
-
var
|
|
493
|
-
|
|
609
|
+
if (Y && pe + 1 >= v.length) {
|
|
610
|
+
var ue = Y(T, N);
|
|
611
|
+
Q = !!ue, Q && "get" in ue && !("originalValue" in ue.get) ? T = ue.get : T = T[N];
|
|
494
612
|
} else
|
|
495
|
-
|
|
496
|
-
|
|
613
|
+
Q = se(T, N), T = T[N];
|
|
614
|
+
Q && !ae && (R[F] = T);
|
|
497
615
|
}
|
|
498
616
|
}
|
|
499
|
-
return
|
|
617
|
+
return T;
|
|
500
618
|
}, "GetIntrinsic");
|
|
501
619
|
}
|
|
502
|
-
}),
|
|
503
|
-
"node_modules/call-
|
|
620
|
+
}), Ae = f({
|
|
621
|
+
"node_modules/.pnpm/call-bound@1.0.4/node_modules/call-bound/index.js"(t, e) {
|
|
504
622
|
"use strict";
|
|
505
|
-
var r =
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
var d = l(r, s, arguments);
|
|
516
|
-
if (c && i) {
|
|
517
|
-
var v = c(d, "length");
|
|
518
|
-
v.configurable && i(
|
|
519
|
-
d,
|
|
520
|
-
"length",
|
|
521
|
-
{ value: 1 + h(0, y.length - (arguments.length - 1)) }
|
|
522
|
-
);
|
|
523
|
-
}
|
|
524
|
-
return d;
|
|
525
|
-
}, "callBind");
|
|
526
|
-
var p = /* @__PURE__ */ o(function() {
|
|
527
|
-
return l(r, a, arguments);
|
|
528
|
-
}, "applyBind2");
|
|
529
|
-
i ? i(e.exports, "apply", { value: p }) : e.exports.apply = p;
|
|
530
|
-
}
|
|
531
|
-
}), require_callBound = __commonJS({
|
|
532
|
-
"node_modules/call-bind/callBound.js"(t, e) {
|
|
533
|
-
"use strict";
|
|
534
|
-
var r = require_get_intrinsic(), n = require_call_bind(), a = n(r("String.prototype.indexOf"));
|
|
535
|
-
e.exports = /* @__PURE__ */ o(function(l, c) {
|
|
536
|
-
var i = r(l, !!c);
|
|
537
|
-
return typeof i == "function" && a(l, ".prototype.") > -1 ? n(i) : i;
|
|
623
|
+
var r = br(), n = ot(), o = n([r("%String.prototype.indexOf%")]);
|
|
624
|
+
e.exports = /* @__PURE__ */ s(function(a, c) {
|
|
625
|
+
var i = (
|
|
626
|
+
/** @type {(this: unknown, ...args: unknown[]) => unknown} */
|
|
627
|
+
r(a, !!c)
|
|
628
|
+
);
|
|
629
|
+
return typeof i == "function" && o(a, ".prototype.") > -1 ? n(
|
|
630
|
+
/** @type {const} */
|
|
631
|
+
[i]
|
|
632
|
+
) : i;
|
|
538
633
|
}, "callBoundIntrinsic");
|
|
539
634
|
}
|
|
540
|
-
}),
|
|
541
|
-
"node_modules/has-tostringtag/shams.js"(t, e) {
|
|
635
|
+
}), Sr = f({
|
|
636
|
+
"node_modules/.pnpm/has-tostringtag@1.0.2/node_modules/has-tostringtag/shams.js"(t, e) {
|
|
542
637
|
"use strict";
|
|
543
|
-
var r =
|
|
544
|
-
e.exports = /* @__PURE__ */
|
|
638
|
+
var r = Ze();
|
|
639
|
+
e.exports = /* @__PURE__ */ s(function() {
|
|
545
640
|
return r() && !!Symbol.toStringTag;
|
|
546
641
|
}, "hasToStringTagShams");
|
|
547
642
|
}
|
|
548
|
-
}),
|
|
549
|
-
"node_modules/is-regex/index.js"(t, e) {
|
|
643
|
+
}), it = f({
|
|
644
|
+
"node_modules/.pnpm/is-regex@1.2.1/node_modules/is-regex/index.js"(t, e) {
|
|
550
645
|
"use strict";
|
|
551
|
-
var r =
|
|
552
|
-
n
|
|
553
|
-
throw
|
|
554
|
-
}, "throwRegexMarker"),
|
|
555
|
-
toString:
|
|
556
|
-
valueOf:
|
|
557
|
-
}, typeof Symbol.toPrimitive == "symbol" && (
|
|
558
|
-
|
|
559
|
-
e.exports = /* @__PURE__ */ o(n ? function(d) {
|
|
560
|
-
if (!d || typeof d != "object")
|
|
646
|
+
var r = Ae(), n = Sr()(), o = st(), p = Se(), a;
|
|
647
|
+
n ? (c = r("RegExp.prototype.exec"), i = {}, l = /* @__PURE__ */ s(function() {
|
|
648
|
+
throw i;
|
|
649
|
+
}, "throwRegexMarker"), d = {
|
|
650
|
+
toString: l,
|
|
651
|
+
valueOf: l
|
|
652
|
+
}, typeof Symbol.toPrimitive == "symbol" && (d[Symbol.toPrimitive] = l), a = /* @__PURE__ */ s(function(h) {
|
|
653
|
+
if (!h || typeof h != "object")
|
|
561
654
|
return !1;
|
|
562
|
-
var
|
|
655
|
+
var C = (
|
|
656
|
+
/** @type {NonNullable<typeof gOPD>} */
|
|
657
|
+
p(
|
|
658
|
+
/** @type {{ lastIndex?: unknown }} */
|
|
659
|
+
h,
|
|
660
|
+
"lastIndex"
|
|
661
|
+
)
|
|
662
|
+
), w = C && o(C, "value");
|
|
563
663
|
if (!w)
|
|
564
664
|
return !1;
|
|
565
665
|
try {
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
666
|
+
c(
|
|
667
|
+
h,
|
|
668
|
+
/** @type {string} */
|
|
669
|
+
/** @type {unknown} */
|
|
670
|
+
d
|
|
671
|
+
);
|
|
672
|
+
} catch (A) {
|
|
673
|
+
return A === i;
|
|
569
674
|
}
|
|
570
|
-
} : function(
|
|
571
|
-
return !
|
|
572
|
-
}, "isRegex");
|
|
675
|
+
}, "isRegex")) : (u = r("Object.prototype.toString"), y = "[object RegExp]", a = /* @__PURE__ */ s(function(h) {
|
|
676
|
+
return !h || typeof h != "object" && typeof h != "function" ? !1 : u(h) === y;
|
|
677
|
+
}, "isRegex"));
|
|
678
|
+
var c, i, l, d, u, y;
|
|
679
|
+
e.exports = a;
|
|
573
680
|
}
|
|
574
|
-
}),
|
|
575
|
-
"node_modules/is-function/index.js"(t, e) {
|
|
681
|
+
}), Tr = f({
|
|
682
|
+
"node_modules/.pnpm/is-function@1.0.2/node_modules/is-function/index.js"(t, e) {
|
|
576
683
|
e.exports = n;
|
|
577
684
|
var r = Object.prototype.toString;
|
|
578
|
-
function n(
|
|
579
|
-
if (!
|
|
685
|
+
function n(o) {
|
|
686
|
+
if (!o)
|
|
580
687
|
return !1;
|
|
581
|
-
var
|
|
582
|
-
return
|
|
583
|
-
|
|
688
|
+
var p = r.call(o);
|
|
689
|
+
return p === "[object Function]" || typeof o == "function" && p !== "[object RegExp]" || typeof window < "u" && // IE8 and below
|
|
690
|
+
(o === window.setTimeout || o === window.alert || o === window.confirm || o === window.prompt);
|
|
584
691
|
}
|
|
585
|
-
|
|
692
|
+
s(n, "isFunction3");
|
|
586
693
|
}
|
|
587
|
-
}),
|
|
588
|
-
"node_modules/
|
|
694
|
+
}), Ar = f({
|
|
695
|
+
"node_modules/.pnpm/safe-regex-test@1.1.0/node_modules/safe-regex-test/index.js"(t, e) {
|
|
589
696
|
"use strict";
|
|
590
|
-
var r =
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
697
|
+
var r = Ae(), n = it(), o = r("RegExp.prototype.exec"), p = be();
|
|
698
|
+
e.exports = /* @__PURE__ */ s(function(c) {
|
|
699
|
+
if (!n(c))
|
|
700
|
+
throw new p("`regex` must be a RegExp");
|
|
701
|
+
return /* @__PURE__ */ s(function(l) {
|
|
702
|
+
return o(c, l) !== null;
|
|
703
|
+
}, "test");
|
|
704
|
+
}, "regexTester");
|
|
705
|
+
}
|
|
706
|
+
}), xr = f({
|
|
707
|
+
"node_modules/.pnpm/is-symbol@1.1.1/node_modules/is-symbol/index.js"(t, e) {
|
|
708
|
+
"use strict";
|
|
709
|
+
var r = Ae(), n = r("Object.prototype.toString"), o = et()(), p = Ar();
|
|
710
|
+
o ? (a = r("Symbol.prototype.toString"), c = p(/^Symbol\(.*\)$/), i = /* @__PURE__ */ s(function(d) {
|
|
711
|
+
return typeof d.valueOf() != "symbol" ? !1 : c(a(d));
|
|
712
|
+
}, "isRealSymbolObject"), e.exports = /* @__PURE__ */ s(function(d) {
|
|
713
|
+
if (typeof d == "symbol")
|
|
595
714
|
return !0;
|
|
596
|
-
if (
|
|
715
|
+
if (!d || typeof d != "object" || n(d) !== "[object Symbol]")
|
|
597
716
|
return !1;
|
|
598
717
|
try {
|
|
599
|
-
return
|
|
718
|
+
return i(d);
|
|
600
719
|
} catch {
|
|
601
720
|
return !1;
|
|
602
721
|
}
|
|
603
|
-
}, "isSymbol3")) : e.exports = /* @__PURE__ */
|
|
722
|
+
}, "isSymbol3")) : e.exports = /* @__PURE__ */ s(function(d) {
|
|
604
723
|
return !1;
|
|
605
724
|
}, "isSymbol3");
|
|
606
|
-
var a,
|
|
725
|
+
var a, c, i;
|
|
607
726
|
}
|
|
608
|
-
}),
|
|
609
|
-
|
|
610
|
-
isJSON: /* @__PURE__ */
|
|
611
|
-
parse: /* @__PURE__ */
|
|
612
|
-
replacer: /* @__PURE__ */
|
|
613
|
-
reviver: /* @__PURE__ */
|
|
614
|
-
stringify: /* @__PURE__ */
|
|
727
|
+
}), at = {};
|
|
728
|
+
Qt(at, {
|
|
729
|
+
isJSON: /* @__PURE__ */ s(() => yt, "isJSON"),
|
|
730
|
+
parse: /* @__PURE__ */ s(() => Zo, "parse"),
|
|
731
|
+
replacer: /* @__PURE__ */ s(() => gt, "replacer"),
|
|
732
|
+
reviver: /* @__PURE__ */ s(() => mt, "reviver"),
|
|
733
|
+
stringify: /* @__PURE__ */ s(() => Xo, "stringify")
|
|
615
734
|
});
|
|
616
|
-
|
|
617
|
-
var
|
|
618
|
-
function
|
|
735
|
+
Et.exports = Zt(at);
|
|
736
|
+
var wr = _e(it()), Pr = _e(Tr()), Or = _e(xr());
|
|
737
|
+
function Cr(t) {
|
|
619
738
|
return t != null && typeof t == "object" && Array.isArray(t) === !1;
|
|
620
739
|
}
|
|
621
|
-
|
|
622
|
-
var
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
var e = hasOwnProperty.call(t, symToStringTag), r = t[symToStringTag];
|
|
740
|
+
s(Cr, "isObject");
|
|
741
|
+
var Nr = typeof global == "object" && global && global.Object === Object && global, Ir = Nr, Rr = typeof self == "object" && self && self.
|
|
742
|
+
Object === Object && self, jr = Ir || Rr || Function("return this")(), xe = jr, Lr = xe.Symbol, G = Lr, pt = Object.prototype, Dr = pt.hasOwnProperty,
|
|
743
|
+
$r = pt.toString, re = G ? G.toStringTag : void 0;
|
|
744
|
+
function Fr(t) {
|
|
745
|
+
var e = Dr.call(t, re), r = t[re];
|
|
628
746
|
try {
|
|
629
|
-
t[
|
|
747
|
+
t[re] = void 0;
|
|
630
748
|
var n = !0;
|
|
631
749
|
} catch {
|
|
632
750
|
}
|
|
633
|
-
var
|
|
634
|
-
return n && (e ? t[
|
|
635
|
-
}
|
|
636
|
-
|
|
637
|
-
var
|
|
638
|
-
function
|
|
639
|
-
return
|
|
640
|
-
}
|
|
641
|
-
|
|
642
|
-
var
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
var baseGetTag_default = baseGetTag;
|
|
650
|
-
function isObjectLike(t) {
|
|
751
|
+
var o = $r.call(t);
|
|
752
|
+
return n && (e ? t[re] = r : delete t[re]), o;
|
|
753
|
+
}
|
|
754
|
+
s(Fr, "getRawTag");
|
|
755
|
+
var Mr = Fr, Ur = Object.prototype, Gr = Ur.toString;
|
|
756
|
+
function kr(t) {
|
|
757
|
+
return Gr.call(t);
|
|
758
|
+
}
|
|
759
|
+
s(kr, "objectToString");
|
|
760
|
+
var Wr = kr, qr = "[object Null]", Br = "[object Undefined]", He = G ? G.toStringTag : void 0;
|
|
761
|
+
function Hr(t) {
|
|
762
|
+
return t == null ? t === void 0 ? Br : qr : He && He in Object(t) ? Mr(t) : Wr(t);
|
|
763
|
+
}
|
|
764
|
+
s(Hr, "baseGetTag");
|
|
765
|
+
var ct = Hr;
|
|
766
|
+
function Vr(t) {
|
|
651
767
|
return t != null && typeof t == "object";
|
|
652
768
|
}
|
|
653
|
-
|
|
654
|
-
var
|
|
655
|
-
function
|
|
656
|
-
return typeof t == "symbol" ||
|
|
657
|
-
}
|
|
658
|
-
|
|
659
|
-
var
|
|
660
|
-
function
|
|
661
|
-
for (var r = -1, n = t == null ? 0 : t.length,
|
|
662
|
-
|
|
663
|
-
return
|
|
664
|
-
}
|
|
665
|
-
|
|
666
|
-
var
|
|
667
|
-
|
|
668
|
-
function baseToString(t) {
|
|
769
|
+
s(Vr, "isObjectLike");
|
|
770
|
+
var Jr = Vr, zr = "[object Symbol]";
|
|
771
|
+
function Yr(t) {
|
|
772
|
+
return typeof t == "symbol" || Jr(t) && ct(t) == zr;
|
|
773
|
+
}
|
|
774
|
+
s(Yr, "isSymbol");
|
|
775
|
+
var we = Yr;
|
|
776
|
+
function Kr(t, e) {
|
|
777
|
+
for (var r = -1, n = t == null ? 0 : t.length, o = Array(n); ++r < n; )
|
|
778
|
+
o[r] = e(t[r], r, t);
|
|
779
|
+
return o;
|
|
780
|
+
}
|
|
781
|
+
s(Kr, "arrayMap");
|
|
782
|
+
var Xr = Kr, Qr = Array.isArray, Pe = Qr, Zr = 1 / 0, Ve = G ? G.prototype : void 0, Je = Ve ? Ve.toString : void 0;
|
|
783
|
+
function lt(t) {
|
|
669
784
|
if (typeof t == "string")
|
|
670
785
|
return t;
|
|
671
|
-
if (
|
|
672
|
-
return
|
|
673
|
-
if (
|
|
674
|
-
return
|
|
786
|
+
if (Pe(t))
|
|
787
|
+
return Xr(t, lt) + "";
|
|
788
|
+
if (we(t))
|
|
789
|
+
return Je ? Je.call(t) : "";
|
|
675
790
|
var e = t + "";
|
|
676
|
-
return e == "0" && 1 / t == -
|
|
791
|
+
return e == "0" && 1 / t == -Zr ? "-0" : e;
|
|
677
792
|
}
|
|
678
|
-
|
|
679
|
-
var
|
|
680
|
-
function
|
|
793
|
+
s(lt, "baseToString");
|
|
794
|
+
var en = lt;
|
|
795
|
+
function tn(t) {
|
|
681
796
|
var e = typeof t;
|
|
682
797
|
return t != null && (e == "object" || e == "function");
|
|
683
798
|
}
|
|
684
|
-
|
|
685
|
-
var
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
if (!isObject_default(t))
|
|
799
|
+
s(tn, "isObject2");
|
|
800
|
+
var ut = tn, rn = "[object AsyncFunction]", nn = "[object Function]", on = "[object GeneratorFunction]", sn = "[object Proxy]";
|
|
801
|
+
function an(t) {
|
|
802
|
+
if (!ut(t))
|
|
689
803
|
return !1;
|
|
690
|
-
var e =
|
|
691
|
-
return e ==
|
|
804
|
+
var e = ct(t);
|
|
805
|
+
return e == nn || e == on || e == rn || e == sn;
|
|
692
806
|
}
|
|
693
|
-
|
|
694
|
-
var
|
|
695
|
-
var t = /[^.]+$/.exec(
|
|
807
|
+
s(an, "isFunction");
|
|
808
|
+
var pn = an, cn = xe["__core-js_shared__"], Ee = cn, ze = function() {
|
|
809
|
+
var t = /[^.]+$/.exec(Ee && Ee.keys && Ee.keys.IE_PROTO || "");
|
|
696
810
|
return t ? "Symbol(src)_1." + t : "";
|
|
697
811
|
}();
|
|
698
|
-
function
|
|
699
|
-
return !!
|
|
812
|
+
function ln(t) {
|
|
813
|
+
return !!ze && ze in t;
|
|
700
814
|
}
|
|
701
|
-
|
|
702
|
-
var
|
|
703
|
-
function
|
|
815
|
+
s(ln, "isMasked");
|
|
816
|
+
var un = ln, fn = Function.prototype, dn = fn.toString;
|
|
817
|
+
function yn(t) {
|
|
704
818
|
if (t != null) {
|
|
705
819
|
try {
|
|
706
|
-
return
|
|
820
|
+
return dn.call(t);
|
|
707
821
|
} catch {
|
|
708
822
|
}
|
|
709
823
|
try {
|
|
@@ -713,264 +827,262 @@ tion]";
|
|
|
713
827
|
}
|
|
714
828
|
return "";
|
|
715
829
|
}
|
|
716
|
-
|
|
717
|
-
var
|
|
718
|
-
|
|
719
|
-
"^" +
|
|
720
|
-
"$1.*?") + "$"
|
|
830
|
+
s(yn, "toSource");
|
|
831
|
+
var hn = yn, gn = /[\\^$.*+?()[\]{}|]/g, mn = /^\[object .+?Constructor\]$/, vn = Function.prototype, En = Object.prototype, _n = vn.toString,
|
|
832
|
+
bn = En.hasOwnProperty, Sn = RegExp(
|
|
833
|
+
"^" + _n.call(bn).replace(gn, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
|
|
721
834
|
);
|
|
722
|
-
function
|
|
723
|
-
if (!
|
|
835
|
+
function Tn(t) {
|
|
836
|
+
if (!ut(t) || un(t))
|
|
724
837
|
return !1;
|
|
725
|
-
var e =
|
|
726
|
-
return e.test(
|
|
838
|
+
var e = pn(t) ? Sn : mn;
|
|
839
|
+
return e.test(hn(t));
|
|
727
840
|
}
|
|
728
|
-
|
|
729
|
-
var
|
|
730
|
-
function
|
|
841
|
+
s(Tn, "baseIsNative");
|
|
842
|
+
var An = Tn;
|
|
843
|
+
function xn(t, e) {
|
|
731
844
|
return t?.[e];
|
|
732
845
|
}
|
|
733
|
-
|
|
734
|
-
var
|
|
735
|
-
function
|
|
736
|
-
var r =
|
|
737
|
-
return
|
|
846
|
+
s(xn, "getValue");
|
|
847
|
+
var wn = xn;
|
|
848
|
+
function Pn(t, e) {
|
|
849
|
+
var r = wn(t, e);
|
|
850
|
+
return An(r) ? r : void 0;
|
|
738
851
|
}
|
|
739
|
-
|
|
740
|
-
var
|
|
741
|
-
function
|
|
852
|
+
s(Pn, "getNative");
|
|
853
|
+
var ft = Pn;
|
|
854
|
+
function On(t, e) {
|
|
742
855
|
return t === e || t !== t && e !== e;
|
|
743
856
|
}
|
|
744
|
-
|
|
745
|
-
var
|
|
746
|
-
function
|
|
747
|
-
if (
|
|
857
|
+
s(On, "eq");
|
|
858
|
+
var Cn = On, Nn = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, In = /^\w*$/;
|
|
859
|
+
function Rn(t, e) {
|
|
860
|
+
if (Pe(t))
|
|
748
861
|
return !1;
|
|
749
862
|
var r = typeof t;
|
|
750
|
-
return r == "number" || r == "symbol" || r == "boolean" || t == null ||
|
|
751
|
-
|
|
863
|
+
return r == "number" || r == "symbol" || r == "boolean" || t == null || we(t) ? !0 : In.test(t) || !Nn.test(t) || e != null && t in Object(
|
|
864
|
+
e);
|
|
752
865
|
}
|
|
753
|
-
|
|
754
|
-
var
|
|
755
|
-
function
|
|
756
|
-
this.__data__ =
|
|
866
|
+
s(Rn, "isKey");
|
|
867
|
+
var jn = Rn, Ln = ft(Object, "create"), ne = Ln;
|
|
868
|
+
function Dn() {
|
|
869
|
+
this.__data__ = ne ? ne(null) : {}, this.size = 0;
|
|
757
870
|
}
|
|
758
|
-
|
|
759
|
-
var
|
|
760
|
-
function
|
|
871
|
+
s(Dn, "hashClear");
|
|
872
|
+
var $n = Dn;
|
|
873
|
+
function Fn(t) {
|
|
761
874
|
var e = this.has(t) && delete this.__data__[t];
|
|
762
875
|
return this.size -= e ? 1 : 0, e;
|
|
763
876
|
}
|
|
764
|
-
|
|
765
|
-
var
|
|
766
|
-
|
|
767
|
-
function hashGet(t) {
|
|
877
|
+
s(Fn, "hashDelete");
|
|
878
|
+
var Mn = Fn, Un = "__lodash_hash_undefined__", Gn = Object.prototype, kn = Gn.hasOwnProperty;
|
|
879
|
+
function Wn(t) {
|
|
768
880
|
var e = this.__data__;
|
|
769
|
-
if (
|
|
881
|
+
if (ne) {
|
|
770
882
|
var r = e[t];
|
|
771
|
-
return r ===
|
|
883
|
+
return r === Un ? void 0 : r;
|
|
772
884
|
}
|
|
773
|
-
return
|
|
885
|
+
return kn.call(e, t) ? e[t] : void 0;
|
|
774
886
|
}
|
|
775
|
-
|
|
776
|
-
var
|
|
777
|
-
function
|
|
887
|
+
s(Wn, "hashGet");
|
|
888
|
+
var qn = Wn, Bn = Object.prototype, Hn = Bn.hasOwnProperty;
|
|
889
|
+
function Vn(t) {
|
|
778
890
|
var e = this.__data__;
|
|
779
|
-
return
|
|
891
|
+
return ne ? e[t] !== void 0 : Hn.call(e, t);
|
|
780
892
|
}
|
|
781
|
-
|
|
782
|
-
var
|
|
783
|
-
function
|
|
893
|
+
s(Vn, "hashHas");
|
|
894
|
+
var Jn = Vn, zn = "__lodash_hash_undefined__";
|
|
895
|
+
function Yn(t, e) {
|
|
784
896
|
var r = this.__data__;
|
|
785
|
-
return this.size += this.has(t) ? 0 : 1, r[t] =
|
|
897
|
+
return this.size += this.has(t) ? 0 : 1, r[t] = ne && e === void 0 ? zn : e, this;
|
|
786
898
|
}
|
|
787
|
-
|
|
788
|
-
var
|
|
789
|
-
function
|
|
899
|
+
s(Yn, "hashSet");
|
|
900
|
+
var Kn = Yn;
|
|
901
|
+
function k(t) {
|
|
790
902
|
var e = -1, r = t == null ? 0 : t.length;
|
|
791
903
|
for (this.clear(); ++e < r; ) {
|
|
792
904
|
var n = t[e];
|
|
793
905
|
this.set(n[0], n[1]);
|
|
794
906
|
}
|
|
795
907
|
}
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
var
|
|
803
|
-
function
|
|
908
|
+
s(k, "Hash");
|
|
909
|
+
k.prototype.clear = $n;
|
|
910
|
+
k.prototype.delete = Mn;
|
|
911
|
+
k.prototype.get = qn;
|
|
912
|
+
k.prototype.has = Jn;
|
|
913
|
+
k.prototype.set = Kn;
|
|
914
|
+
var Ye = k;
|
|
915
|
+
function Xn() {
|
|
804
916
|
this.__data__ = [], this.size = 0;
|
|
805
917
|
}
|
|
806
|
-
|
|
807
|
-
var
|
|
808
|
-
function
|
|
918
|
+
s(Xn, "listCacheClear");
|
|
919
|
+
var Qn = Xn;
|
|
920
|
+
function Zn(t, e) {
|
|
809
921
|
for (var r = t.length; r--; )
|
|
810
|
-
if (
|
|
922
|
+
if (Cn(t[r][0], e))
|
|
811
923
|
return r;
|
|
812
924
|
return -1;
|
|
813
925
|
}
|
|
814
|
-
|
|
815
|
-
var
|
|
816
|
-
function
|
|
817
|
-
var e = this.__data__, r =
|
|
926
|
+
s(Zn, "assocIndexOf");
|
|
927
|
+
var ye = Zn, eo = Array.prototype, to = eo.splice;
|
|
928
|
+
function ro(t) {
|
|
929
|
+
var e = this.__data__, r = ye(e, t);
|
|
818
930
|
if (r < 0)
|
|
819
931
|
return !1;
|
|
820
932
|
var n = e.length - 1;
|
|
821
|
-
return r == n ? e.pop() :
|
|
933
|
+
return r == n ? e.pop() : to.call(e, r, 1), --this.size, !0;
|
|
822
934
|
}
|
|
823
|
-
|
|
824
|
-
var
|
|
825
|
-
function
|
|
826
|
-
var e = this.__data__, r =
|
|
935
|
+
s(ro, "listCacheDelete");
|
|
936
|
+
var no = ro;
|
|
937
|
+
function oo(t) {
|
|
938
|
+
var e = this.__data__, r = ye(e, t);
|
|
827
939
|
return r < 0 ? void 0 : e[r][1];
|
|
828
940
|
}
|
|
829
|
-
|
|
830
|
-
var
|
|
831
|
-
function
|
|
832
|
-
return
|
|
941
|
+
s(oo, "listCacheGet");
|
|
942
|
+
var so = oo;
|
|
943
|
+
function io(t) {
|
|
944
|
+
return ye(this.__data__, t) > -1;
|
|
833
945
|
}
|
|
834
|
-
|
|
835
|
-
var
|
|
836
|
-
function
|
|
837
|
-
var r = this.__data__, n =
|
|
946
|
+
s(io, "listCacheHas");
|
|
947
|
+
var ao = io;
|
|
948
|
+
function po(t, e) {
|
|
949
|
+
var r = this.__data__, n = ye(r, t);
|
|
838
950
|
return n < 0 ? (++this.size, r.push([t, e])) : r[n][1] = e, this;
|
|
839
951
|
}
|
|
840
|
-
|
|
841
|
-
var
|
|
842
|
-
function
|
|
952
|
+
s(po, "listCacheSet");
|
|
953
|
+
var co = po;
|
|
954
|
+
function W(t) {
|
|
843
955
|
var e = -1, r = t == null ? 0 : t.length;
|
|
844
956
|
for (this.clear(); ++e < r; ) {
|
|
845
957
|
var n = t[e];
|
|
846
958
|
this.set(n[0], n[1]);
|
|
847
959
|
}
|
|
848
960
|
}
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
var
|
|
856
|
-
function
|
|
961
|
+
s(W, "ListCache");
|
|
962
|
+
W.prototype.clear = Qn;
|
|
963
|
+
W.prototype.delete = no;
|
|
964
|
+
W.prototype.get = so;
|
|
965
|
+
W.prototype.has = ao;
|
|
966
|
+
W.prototype.set = co;
|
|
967
|
+
var lo = W, uo = ft(xe, "Map"), fo = uo;
|
|
968
|
+
function yo() {
|
|
857
969
|
this.size = 0, this.__data__ = {
|
|
858
|
-
hash: new
|
|
859
|
-
map: new (
|
|
860
|
-
string: new
|
|
970
|
+
hash: new Ye(),
|
|
971
|
+
map: new (fo || lo)(),
|
|
972
|
+
string: new Ye()
|
|
861
973
|
};
|
|
862
974
|
}
|
|
863
|
-
|
|
864
|
-
var
|
|
865
|
-
function
|
|
975
|
+
s(yo, "mapCacheClear");
|
|
976
|
+
var ho = yo;
|
|
977
|
+
function go(t) {
|
|
866
978
|
var e = typeof t;
|
|
867
979
|
return e == "string" || e == "number" || e == "symbol" || e == "boolean" ? t !== "__proto__" : t === null;
|
|
868
980
|
}
|
|
869
|
-
|
|
870
|
-
var
|
|
871
|
-
function
|
|
981
|
+
s(go, "isKeyable");
|
|
982
|
+
var mo = go;
|
|
983
|
+
function vo(t, e) {
|
|
872
984
|
var r = t.__data__;
|
|
873
|
-
return
|
|
985
|
+
return mo(e) ? r[typeof e == "string" ? "string" : "hash"] : r.map;
|
|
874
986
|
}
|
|
875
|
-
|
|
876
|
-
var
|
|
877
|
-
function
|
|
878
|
-
var e =
|
|
987
|
+
s(vo, "getMapData");
|
|
988
|
+
var he = vo;
|
|
989
|
+
function Eo(t) {
|
|
990
|
+
var e = he(this, t).delete(t);
|
|
879
991
|
return this.size -= e ? 1 : 0, e;
|
|
880
992
|
}
|
|
881
|
-
|
|
882
|
-
var
|
|
883
|
-
function
|
|
884
|
-
return
|
|
993
|
+
s(Eo, "mapCacheDelete");
|
|
994
|
+
var _o = Eo;
|
|
995
|
+
function bo(t) {
|
|
996
|
+
return he(this, t).get(t);
|
|
885
997
|
}
|
|
886
|
-
|
|
887
|
-
var
|
|
888
|
-
function
|
|
889
|
-
return
|
|
998
|
+
s(bo, "mapCacheGet");
|
|
999
|
+
var So = bo;
|
|
1000
|
+
function To(t) {
|
|
1001
|
+
return he(this, t).has(t);
|
|
890
1002
|
}
|
|
891
|
-
|
|
892
|
-
var
|
|
893
|
-
function
|
|
894
|
-
var r =
|
|
1003
|
+
s(To, "mapCacheHas");
|
|
1004
|
+
var Ao = To;
|
|
1005
|
+
function xo(t, e) {
|
|
1006
|
+
var r = he(this, t), n = r.size;
|
|
895
1007
|
return r.set(t, e), this.size += r.size == n ? 0 : 1, this;
|
|
896
1008
|
}
|
|
897
|
-
|
|
898
|
-
var
|
|
899
|
-
function
|
|
1009
|
+
s(xo, "mapCacheSet");
|
|
1010
|
+
var wo = xo;
|
|
1011
|
+
function q(t) {
|
|
900
1012
|
var e = -1, r = t == null ? 0 : t.length;
|
|
901
1013
|
for (this.clear(); ++e < r; ) {
|
|
902
1014
|
var n = t[e];
|
|
903
1015
|
this.set(n[0], n[1]);
|
|
904
1016
|
}
|
|
905
1017
|
}
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
var
|
|
913
|
-
function
|
|
1018
|
+
s(q, "MapCache");
|
|
1019
|
+
q.prototype.clear = ho;
|
|
1020
|
+
q.prototype.delete = _o;
|
|
1021
|
+
q.prototype.get = So;
|
|
1022
|
+
q.prototype.has = Ao;
|
|
1023
|
+
q.prototype.set = wo;
|
|
1024
|
+
var dt = q, Po = "Expected a function";
|
|
1025
|
+
function Oe(t, e) {
|
|
914
1026
|
if (typeof t != "function" || e != null && typeof e != "function")
|
|
915
|
-
throw new TypeError(
|
|
916
|
-
var r = /* @__PURE__ */
|
|
917
|
-
var n = arguments,
|
|
918
|
-
if (
|
|
919
|
-
return
|
|
920
|
-
var
|
|
921
|
-
return r.cache =
|
|
1027
|
+
throw new TypeError(Po);
|
|
1028
|
+
var r = /* @__PURE__ */ s(function() {
|
|
1029
|
+
var n = arguments, o = e ? e.apply(this, n) : n[0], p = r.cache;
|
|
1030
|
+
if (p.has(o))
|
|
1031
|
+
return p.get(o);
|
|
1032
|
+
var a = t.apply(this, n);
|
|
1033
|
+
return r.cache = p.set(o, a) || p, a;
|
|
922
1034
|
}, "memoized");
|
|
923
|
-
return r.cache = new (
|
|
924
|
-
}
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
var
|
|
928
|
-
function
|
|
929
|
-
var e =
|
|
930
|
-
return r.size ===
|
|
1035
|
+
return r.cache = new (Oe.Cache || dt)(), r;
|
|
1036
|
+
}
|
|
1037
|
+
s(Oe, "memoize");
|
|
1038
|
+
Oe.Cache = dt;
|
|
1039
|
+
var Oo = Oe, Co = 500;
|
|
1040
|
+
function No(t) {
|
|
1041
|
+
var e = Oo(t, function(n) {
|
|
1042
|
+
return r.size === Co && r.clear(), n;
|
|
931
1043
|
}), r = e.cache;
|
|
932
1044
|
return e;
|
|
933
1045
|
}
|
|
934
|
-
|
|
935
|
-
var
|
|
936
|
-
|
|
1046
|
+
s(No, "memoizeCapped");
|
|
1047
|
+
var Io = No, Ro = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g, jo = /\\(\\)?/g, Lo = Io(
|
|
1048
|
+
function(t) {
|
|
937
1049
|
var e = [];
|
|
938
|
-
return t.charCodeAt(0) === 46 && e.push(""), t.replace(
|
|
939
|
-
e.push(
|
|
1050
|
+
return t.charCodeAt(0) === 46 && e.push(""), t.replace(Ro, function(r, n, o, p) {
|
|
1051
|
+
e.push(o ? p.replace(jo, "$1") : n || r);
|
|
940
1052
|
}), e;
|
|
941
|
-
}),
|
|
942
|
-
function
|
|
943
|
-
return t == null ? "" :
|
|
944
|
-
}
|
|
945
|
-
o
|
|
946
|
-
var
|
|
947
|
-
function
|
|
948
|
-
return
|
|
949
|
-
}
|
|
950
|
-
|
|
951
|
-
var
|
|
952
|
-
function
|
|
953
|
-
if (typeof t == "string" ||
|
|
1053
|
+
}), Do = Lo;
|
|
1054
|
+
function $o(t) {
|
|
1055
|
+
return t == null ? "" : en(t);
|
|
1056
|
+
}
|
|
1057
|
+
s($o, "toString");
|
|
1058
|
+
var Fo = $o;
|
|
1059
|
+
function Mo(t, e) {
|
|
1060
|
+
return Pe(t) ? t : jn(t, e) ? [t] : Do(Fo(t));
|
|
1061
|
+
}
|
|
1062
|
+
s(Mo, "castPath");
|
|
1063
|
+
var Uo = Mo, Go = 1 / 0;
|
|
1064
|
+
function ko(t) {
|
|
1065
|
+
if (typeof t == "string" || we(t))
|
|
954
1066
|
return t;
|
|
955
1067
|
var e = t + "";
|
|
956
|
-
return e == "0" && 1 / t == -
|
|
1068
|
+
return e == "0" && 1 / t == -Go ? "-0" : e;
|
|
957
1069
|
}
|
|
958
|
-
|
|
959
|
-
var
|
|
960
|
-
function
|
|
961
|
-
e =
|
|
1070
|
+
s(ko, "toKey");
|
|
1071
|
+
var Wo = ko;
|
|
1072
|
+
function qo(t, e) {
|
|
1073
|
+
e = Uo(e, t);
|
|
962
1074
|
for (var r = 0, n = e.length; t != null && r < n; )
|
|
963
|
-
t = t[
|
|
1075
|
+
t = t[Wo(e[r++])];
|
|
964
1076
|
return r && r == n ? t : void 0;
|
|
965
1077
|
}
|
|
966
|
-
|
|
967
|
-
var
|
|
968
|
-
function
|
|
969
|
-
var n = t == null ? void 0 :
|
|
1078
|
+
s(qo, "baseGet");
|
|
1079
|
+
var Bo = qo;
|
|
1080
|
+
function Ho(t, e, r) {
|
|
1081
|
+
var n = t == null ? void 0 : Bo(t, e);
|
|
970
1082
|
return n === void 0 ? r : n;
|
|
971
1083
|
}
|
|
972
|
-
|
|
973
|
-
var
|
|
1084
|
+
s(Ho, "get");
|
|
1085
|
+
var Vo = Ho, Jo = [
|
|
974
1086
|
"bubbles",
|
|
975
1087
|
"cancelBubble",
|
|
976
1088
|
"cancelable",
|
|
@@ -984,60 +1096,42 @@ tion]";
|
|
|
984
1096
|
"target",
|
|
985
1097
|
"timeStamp",
|
|
986
1098
|
"type"
|
|
987
|
-
],
|
|
988
|
-
function
|
|
989
|
-
let e =
|
|
990
|
-
|
|
991
|
-
|
|
992
|
-
|
|
1099
|
+
], zo = ["detail"];
|
|
1100
|
+
function Yo(t) {
|
|
1101
|
+
let e = Jo.filter((r) => t[r] !== void 0).reduce((r, n) => (r[n] = t[n], r), {});
|
|
1102
|
+
if (t instanceof CustomEvent)
|
|
1103
|
+
for (let r of zo.filter(
|
|
1104
|
+
(n) => t[n] !== void 0
|
|
1105
|
+
))
|
|
1106
|
+
e[r] = t[r];
|
|
1107
|
+
return e;
|
|
993
1108
|
}
|
|
994
|
-
|
|
995
|
-
var
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
!e && !r && !n && !a ? t[l] === '"' || t[l] === "'" || t[l] === "`" ? e = t[l] : t[l] === "/" && t[l + 1] === "*" ? r = !0 : t[l] ===
|
|
1000
|
-
"/" && t[l + 1] === "/" ? n = !0 : t[l] === "/" && t[l + 1] !== "/" && (a = !0) : (e && (t[l] === e && t[l - 1] !== "\\" || t[l] ===
|
|
1001
|
-
`
|
|
1002
|
-
` && e !== "`") && (e = null), a && (t[l] === "/" && t[l - 1] !== "\\" || t[l] === `
|
|
1003
|
-
`) && (a = !1), r && t[l - 1] === "/" && t[l - 2] === "*" && (r = !1), n && t[l] === `
|
|
1004
|
-
` && (n = !1)), !r && !n && (s += t[l]);
|
|
1005
|
-
else
|
|
1006
|
-
s = t;
|
|
1007
|
-
return s;
|
|
1008
|
-
}, "removeCodeComments"), cleanCode = (0, import_memoizerific.default)(1e4)(
|
|
1009
|
-
(t) => removeCodeComments(t).replace(/\n\s*/g, "").trim()
|
|
1010
|
-
), convertShorthandMethods = /* @__PURE__ */ o(function(e, r) {
|
|
1011
|
-
let n = r.slice(0, r.indexOf("{")), a = r.slice(r.indexOf("{"));
|
|
1012
|
-
if (n.includes("=>") || n.includes("function"))
|
|
1013
|
-
return r;
|
|
1014
|
-
let s = n;
|
|
1015
|
-
return s = s.replace(e, "function"), s + a;
|
|
1016
|
-
}, "convertShorthandMethods2"), dateFormat = /^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d{3})?Z$/, isJSON = /* @__PURE__ */ o((t) => t.match(
|
|
1017
|
-
/^[\[\{\"\}].*[\]\}\"]$/), "isJSON");
|
|
1018
|
-
function convertUnconventionalData(t) {
|
|
1019
|
-
if (!isObject3(t))
|
|
1109
|
+
s(Yo, "extractEventHiddenProperties");
|
|
1110
|
+
var Ce = Cr, Ko = /^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d{3})?Z$/, yt = /* @__PURE__ */ s((t) => t.match(/^[\[\{\"\}].*[\]\}\"]$/), "is\
|
|
1111
|
+
JSON");
|
|
1112
|
+
function ht(t) {
|
|
1113
|
+
if (!Ce(t))
|
|
1020
1114
|
return t;
|
|
1021
1115
|
let e = t, r = !1;
|
|
1022
|
-
return typeof Event < "u" && t instanceof Event && (e =
|
|
1116
|
+
return typeof Event < "u" && t instanceof Event && (e = Yo(e), r = !0), e = Object.keys(e).reduce((n, o) => {
|
|
1023
1117
|
try {
|
|
1024
|
-
e[
|
|
1118
|
+
e[o] && e[o].toJSON, n[o] = e[o];
|
|
1025
1119
|
} catch {
|
|
1026
1120
|
r = !0;
|
|
1027
1121
|
}
|
|
1028
1122
|
return n;
|
|
1029
1123
|
}, {}), r ? e : t;
|
|
1030
1124
|
}
|
|
1031
|
-
|
|
1032
|
-
var
|
|
1033
|
-
let r, n,
|
|
1034
|
-
return /* @__PURE__ */
|
|
1125
|
+
s(ht, "convertUnconventionalData");
|
|
1126
|
+
var gt = /* @__PURE__ */ s(function(e) {
|
|
1127
|
+
let r, n, o, p;
|
|
1128
|
+
return /* @__PURE__ */ s(function(c, i) {
|
|
1035
1129
|
try {
|
|
1036
1130
|
if (c === "")
|
|
1037
|
-
return
|
|
1038
|
-
let
|
|
1039
|
-
for (;
|
|
1040
|
-
|
|
1131
|
+
return p = [], r = /* @__PURE__ */ new Map([[i, "[]"]]), n = /* @__PURE__ */ new Map(), o = [], i;
|
|
1132
|
+
let l = n.get(this) || this;
|
|
1133
|
+
for (; o.length && l !== o[0]; )
|
|
1134
|
+
o.shift(), p.pop();
|
|
1041
1135
|
if (typeof i == "boolean")
|
|
1042
1136
|
return i;
|
|
1043
1137
|
if (i === void 0)
|
|
@@ -1045,36 +1139,31 @@ tion]";
|
|
|
1045
1139
|
if (i === null)
|
|
1046
1140
|
return null;
|
|
1047
1141
|
if (typeof i == "number")
|
|
1048
|
-
return i ===
|
|
1142
|
+
return i === Number.NEGATIVE_INFINITY ? "_-Infinity_" : i === Number.POSITIVE_INFINITY ? "_Infinity_" : Number.isNaN(i) ? "_NaN_" :
|
|
1143
|
+
i;
|
|
1049
1144
|
if (typeof i == "bigint")
|
|
1050
1145
|
return `_bigint_${i.toString()}`;
|
|
1051
1146
|
if (typeof i == "string")
|
|
1052
|
-
return
|
|
1053
|
-
if ((0,
|
|
1147
|
+
return Ko.test(i) ? e.allowDate ? `_date_${i}` : void 0 : i;
|
|
1148
|
+
if ((0, wr.default)(i))
|
|
1054
1149
|
return e.allowRegExp ? `_regexp_${i.flags}|${i.source}` : void 0;
|
|
1055
|
-
if ((0,
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
let { name: u } = i, y = i.toString();
|
|
1059
|
-
return y.match(
|
|
1060
|
-
/(\[native code\]|WEBPACK_IMPORTED_MODULE|__webpack_exports__|__webpack_require__)/
|
|
1061
|
-
) ? `_function_${u}|${(() => {
|
|
1062
|
-
}).toString()}` : `_function_${u}|${cleanCode(convertShorthandMethods(c, y))}`;
|
|
1063
|
-
}
|
|
1064
|
-
if ((0, import_is_symbol.default)(i)) {
|
|
1150
|
+
if ((0, Pr.default)(i))
|
|
1151
|
+
return;
|
|
1152
|
+
if ((0, Or.default)(i)) {
|
|
1065
1153
|
if (!e.allowSymbol)
|
|
1066
1154
|
return;
|
|
1067
1155
|
let u = Symbol.keyFor(i);
|
|
1068
1156
|
return u !== void 0 ? `_gsymbol_${u}` : `_symbol_${i.toString().slice(7, -1)}`;
|
|
1069
1157
|
}
|
|
1070
|
-
if (
|
|
1158
|
+
if (o.length >= e.maxDepth)
|
|
1071
1159
|
return Array.isArray(i) ? `[Array(${i.length})]` : "[Object]";
|
|
1072
1160
|
if (i === this)
|
|
1073
|
-
return `_duplicate_${JSON.stringify(
|
|
1161
|
+
return `_duplicate_${JSON.stringify(p)}`;
|
|
1074
1162
|
if (i instanceof Error && e.allowError)
|
|
1075
1163
|
return {
|
|
1076
1164
|
__isConvertedError__: !0,
|
|
1077
1165
|
errorProperties: {
|
|
1166
|
+
// @ts-expect-error cause is not defined in the current tsconfig target(es2020)
|
|
1078
1167
|
...i.cause ? { cause: i.cause } : {},
|
|
1079
1168
|
...i,
|
|
1080
1169
|
name: i.name,
|
|
@@ -1083,120 +1172,108 @@ tion]";
|
|
|
1083
1172
|
"_constructor-name_": i.constructor.name
|
|
1084
1173
|
}
|
|
1085
1174
|
};
|
|
1086
|
-
if (i
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
|
|
1090
|
-
|
|
1091
|
-
|
|
1092
|
-
|
|
1093
|
-
|
|
1094
|
-
|
|
1095
|
-
|
|
1096
|
-
|
|
1175
|
+
if (i?.constructor?.name && i.constructor.name !== "Object" && !Array.isArray(i)) {
|
|
1176
|
+
let u = r.get(i);
|
|
1177
|
+
if (!u) {
|
|
1178
|
+
let y = {
|
|
1179
|
+
__isClassInstance__: !0,
|
|
1180
|
+
__className__: i.constructor.name,
|
|
1181
|
+
...Object.getOwnPropertyNames(i).reduce(
|
|
1182
|
+
(g, h) => {
|
|
1183
|
+
try {
|
|
1184
|
+
g[h] = i[h];
|
|
1185
|
+
} catch {
|
|
1186
|
+
}
|
|
1187
|
+
return g;
|
|
1188
|
+
},
|
|
1189
|
+
{}
|
|
1190
|
+
)
|
|
1191
|
+
};
|
|
1192
|
+
return p.push(c), o.unshift(y), r.set(i, JSON.stringify(p)), i !== y && n.set(i, y), y;
|
|
1193
|
+
}
|
|
1194
|
+
return `_duplicate_${u}`;
|
|
1195
|
+
}
|
|
1196
|
+
let d = r.get(i);
|
|
1197
|
+
if (!d) {
|
|
1198
|
+
let u = Array.isArray(i) ? i : ht(i);
|
|
1199
|
+
return p.push(c), o.unshift(u), r.set(i, JSON.stringify(p)), i !== u && n.set(i, u), u;
|
|
1097
1200
|
}
|
|
1098
|
-
return `_duplicate_${
|
|
1201
|
+
return `_duplicate_${d}`;
|
|
1099
1202
|
} catch {
|
|
1100
1203
|
return;
|
|
1101
1204
|
}
|
|
1102
1205
|
}, "replace");
|
|
1103
|
-
}, "replacer2"),
|
|
1104
|
-
let
|
|
1105
|
-
return /* @__PURE__ */
|
|
1106
|
-
if (
|
|
1107
|
-
let
|
|
1108
|
-
|
|
1109
|
-
})),
|
|
1110
|
-
return
|
|
1111
|
-
if (
|
|
1112
|
-
let { message:
|
|
1113
|
-
return Object.assign(
|
|
1114
|
-
}
|
|
1115
|
-
if (isObject3(value) && value["_constructor-name_"] && options.allowFunction) {
|
|
1116
|
-
let t = value["_constructor-name_"];
|
|
1117
|
-
if (t !== "Object") {
|
|
1118
|
-
let e = new Function(`return function ${t.replace(/[^a-zA-Z0-9$_]+/g, "")}(){}`)();
|
|
1119
|
-
Object.setPrototypeOf(value, new e());
|
|
1120
|
-
}
|
|
1121
|
-
return delete value["_constructor-name_"], value;
|
|
1122
|
-
}
|
|
1123
|
-
if (typeof value == "string" && value.startsWith("_function_") && options.allowFunction) {
|
|
1124
|
-
let [, name, source] = value.match(/_function_([^|]*)\|(.*)/) || [], sourceSanitized = source.replace(/[(\(\))|\\| |\]|`]*$/, "");
|
|
1125
|
-
if (!options.lazyEval)
|
|
1126
|
-
return eval(`(${sourceSanitized})`);
|
|
1127
|
-
let result = /* @__PURE__ */ o((...args) => {
|
|
1128
|
-
let f = eval(`(${sourceSanitized})`);
|
|
1129
|
-
return f(...args);
|
|
1130
|
-
}, "result");
|
|
1131
|
-
return Object.defineProperty(result, "toString", {
|
|
1132
|
-
value: /* @__PURE__ */ o(() => sourceSanitized, "value")
|
|
1133
|
-
}), Object.defineProperty(result, "name", {
|
|
1134
|
-
value: name
|
|
1135
|
-
}), result;
|
|
1206
|
+
}, "replacer2"), mt = /* @__PURE__ */ s(function(e) {
|
|
1207
|
+
let r = [], n;
|
|
1208
|
+
return /* @__PURE__ */ s(function(p, a) {
|
|
1209
|
+
if (p === "" && (n = a, r.forEach(({ target: c, container: i, replacement: l }) => {
|
|
1210
|
+
let d = yt(l) ? JSON.parse(l) : l.split(".");
|
|
1211
|
+
d.length === 0 ? i[c] = n : i[c] = Vo(n, d);
|
|
1212
|
+
})), p === "_constructor-name_")
|
|
1213
|
+
return a;
|
|
1214
|
+
if (Ce(a) && a.__isConvertedError__) {
|
|
1215
|
+
let { message: c, ...i } = a.errorProperties, l = new Error(c);
|
|
1216
|
+
return Object.assign(l, i), l;
|
|
1136
1217
|
}
|
|
1137
|
-
if (typeof
|
|
1138
|
-
let [,
|
|
1139
|
-
return new RegExp(
|
|
1218
|
+
if (typeof a == "string" && a.startsWith("_regexp_") && e.allowRegExp) {
|
|
1219
|
+
let [, c, i] = a.match(/_regexp_([^|]*)\|(.*)/) || [];
|
|
1220
|
+
return new RegExp(i, c);
|
|
1140
1221
|
}
|
|
1141
|
-
return typeof
|
|
1142
|
-
"
|
|
1143
|
-
|
|
1144
|
-
|
|
1145
|
-
|
|
1146
|
-
|
|
1147
|
-
value;
|
|
1222
|
+
return typeof a == "string" && a.startsWith("_date_") && e.allowDate ? new Date(a.replace("_date_", "")) : typeof a == "string" && a.startsWith(
|
|
1223
|
+
"_duplicate_") ? (r.push({ target: p, container: this, replacement: a.replace(/^_duplicate_/, "") }), null) : typeof a == "string" && a.
|
|
1224
|
+
startsWith("_symbol_") && e.allowSymbol ? Symbol(a.replace("_symbol_", "")) : typeof a == "string" && a.startsWith("_gsymbol_") && e.allowSymbol ?
|
|
1225
|
+
Symbol.for(a.replace("_gsymbol_", "")) : typeof a == "string" && a === "_-Infinity_" ? Number.NEGATIVE_INFINITY : typeof a == "string" &&
|
|
1226
|
+
a === "_Infinity_" ? Number.POSITIVE_INFINITY : typeof a == "string" && a === "_NaN_" ? Number.NaN : typeof a == "string" && a.startsWith(
|
|
1227
|
+
"_bigint_") && typeof BigInt == "function" ? BigInt(a.replace("_bigint_", "")) : a;
|
|
1148
1228
|
}, "revive");
|
|
1149
|
-
}, "
|
|
1229
|
+
}, "reviver2"), vt = {
|
|
1150
1230
|
maxDepth: 10,
|
|
1151
1231
|
space: void 0,
|
|
1152
|
-
allowFunction: !0,
|
|
1153
1232
|
allowRegExp: !0,
|
|
1154
1233
|
allowDate: !0,
|
|
1155
|
-
allowClass: !0,
|
|
1156
1234
|
allowError: !0,
|
|
1157
1235
|
allowUndefined: !0,
|
|
1158
|
-
allowSymbol: !0
|
|
1159
|
-
|
|
1160
|
-
|
|
1161
|
-
|
|
1162
|
-
|
|
1163
|
-
}, "stringify"), mutator = /* @__PURE__ */ o(() => {
|
|
1236
|
+
allowSymbol: !0
|
|
1237
|
+
}, Xo = /* @__PURE__ */ s((t, e = {}) => {
|
|
1238
|
+
let r = { ...vt, ...e };
|
|
1239
|
+
return JSON.stringify(ht(t), gt(r), e.space);
|
|
1240
|
+
}, "stringify"), Qo = /* @__PURE__ */ s(() => {
|
|
1164
1241
|
let t = /* @__PURE__ */ new Map();
|
|
1165
|
-
return /* @__PURE__ */
|
|
1166
|
-
|
|
1167
|
-
|
|
1168
|
-
}), Array.isArray(r) && r.forEach((n,
|
|
1169
|
-
n === "_undefined_" ? (t.set(n, !0), r[
|
|
1242
|
+
return /* @__PURE__ */ s(function e(r) {
|
|
1243
|
+
Ce(r) && Object.entries(r).forEach(([n, o]) => {
|
|
1244
|
+
o === "_undefined_" ? r[n] = void 0 : t.get(o) || (t.set(o, !0), e(o));
|
|
1245
|
+
}), Array.isArray(r) && r.forEach((n, o) => {
|
|
1246
|
+
n === "_undefined_" ? (t.set(n, !0), r[o] = void 0) : t.get(n) || (t.set(n, !0), e(n));
|
|
1170
1247
|
});
|
|
1171
1248
|
}, "mutateUndefined");
|
|
1172
|
-
}, "mutator"),
|
|
1173
|
-
let r = { ...
|
|
1174
|
-
return
|
|
1249
|
+
}, "mutator"), Zo = /* @__PURE__ */ s((t, e = {}) => {
|
|
1250
|
+
let r = { ...vt, ...e }, n = JSON.parse(t, mt(r));
|
|
1251
|
+
return Qo()(n), n;
|
|
1175
1252
|
}, "parse");
|
|
1176
1253
|
});
|
|
1177
1254
|
|
|
1178
1255
|
// src/channels/index.ts
|
|
1179
|
-
var
|
|
1180
|
-
|
|
1181
|
-
Channel: () =>
|
|
1182
|
-
HEARTBEAT_INTERVAL: () =>
|
|
1183
|
-
HEARTBEAT_MAX_LATENCY: () =>
|
|
1184
|
-
PostMessageTransport: () =>
|
|
1185
|
-
WebsocketTransport: () =>
|
|
1186
|
-
createBrowserChannel: () =>
|
|
1187
|
-
default: () =>
|
|
1256
|
+
var as = {};
|
|
1257
|
+
qt(as, {
|
|
1258
|
+
Channel: () => U,
|
|
1259
|
+
HEARTBEAT_INTERVAL: () => De,
|
|
1260
|
+
HEARTBEAT_MAX_LATENCY: () => $e,
|
|
1261
|
+
PostMessageTransport: () => H,
|
|
1262
|
+
WebsocketTransport: () => J,
|
|
1263
|
+
createBrowserChannel: () => is,
|
|
1264
|
+
default: () => ss
|
|
1188
1265
|
});
|
|
1189
|
-
module.exports =
|
|
1190
|
-
var
|
|
1266
|
+
module.exports = Bt(as);
|
|
1267
|
+
var At = require("@storybook/global");
|
|
1191
1268
|
|
|
1192
1269
|
// src/shared/universal-store/index.ts
|
|
1193
|
-
var
|
|
1270
|
+
var j = ee(Be(), 1);
|
|
1194
1271
|
|
|
1195
1272
|
// src/shared/universal-store/instances.ts
|
|
1196
|
-
var
|
|
1273
|
+
var ve = /* @__PURE__ */ new Map();
|
|
1197
1274
|
|
|
1198
1275
|
// src/shared/universal-store/index.ts
|
|
1199
|
-
var
|
|
1276
|
+
var Ht = "UNIVERSAL_STORE:", x = {
|
|
1200
1277
|
PENDING: "PENDING",
|
|
1201
1278
|
RESOLVED: "RESOLVED",
|
|
1202
1279
|
REJECTED: "REJECTED"
|
|
@@ -1207,28 +1284,28 @@ var Ue = "UNIVERSAL_STORE:", C = {
|
|
|
1207
1284
|
// TODO: narrow type of listeners based on event type
|
|
1208
1285
|
this.listeners = /* @__PURE__ */ new Map([["*", /* @__PURE__ */ new Set()]]);
|
|
1209
1286
|
/** Gets the current state */
|
|
1210
|
-
this.getState = /* @__PURE__ */
|
|
1287
|
+
this.getState = /* @__PURE__ */ s(() => (this.debug("getState", { state: this.state }), this.state), "getState");
|
|
1211
1288
|
/**
|
|
1212
1289
|
* Subscribes to store events
|
|
1213
1290
|
*
|
|
1214
1291
|
* @returns A function to unsubscribe
|
|
1215
1292
|
*/
|
|
1216
|
-
this.subscribe = /* @__PURE__ */
|
|
1217
|
-
let n = typeof e == "function",
|
|
1218
|
-
if (this.debug("subscribe", { eventType:
|
|
1293
|
+
this.subscribe = /* @__PURE__ */ s((e, r) => {
|
|
1294
|
+
let n = typeof e == "function", o = n ? "*" : e, p = n ? e : r;
|
|
1295
|
+
if (this.debug("subscribe", { eventType: o, listener: p }), !p)
|
|
1219
1296
|
throw new TypeError(
|
|
1220
1297
|
`Missing first subscribe argument, or second if first is the event type, when subscribing to a UniversalStore with id '${this.id}'`
|
|
1221
1298
|
);
|
|
1222
|
-
return this.listeners.has(
|
|
1223
|
-
this.debug("unsubscribe", { eventType:
|
|
1224
|
-
get(
|
|
1299
|
+
return this.listeners.has(o) || this.listeners.set(o, /* @__PURE__ */ new Set()), this.listeners.get(o).add(p), () => {
|
|
1300
|
+
this.debug("unsubscribe", { eventType: o, listener: p }), this.listeners.has(o) && (this.listeners.get(o).delete(p), this.listeners.
|
|
1301
|
+
get(o)?.size === 0 && this.listeners.delete(o));
|
|
1225
1302
|
};
|
|
1226
1303
|
}, "subscribe");
|
|
1227
1304
|
/** Sends a custom event to the other stores */
|
|
1228
|
-
this.send = /* @__PURE__ */
|
|
1305
|
+
this.send = /* @__PURE__ */ s((e) => {
|
|
1229
1306
|
if (this.debug("send", { event: e }), this.status !== t.Status.READY)
|
|
1230
1307
|
throw new TypeError(
|
|
1231
|
-
|
|
1308
|
+
j.dedent`Cannot send event before store is ready. You can get the current status with store.status,
|
|
1232
1309
|
or await store.readyPromise to wait for the store to be ready before sending events.
|
|
1233
1310
|
${JSON.stringify(
|
|
1234
1311
|
{
|
|
@@ -1248,29 +1325,29 @@ var Ue = "UNIVERSAL_STORE:", C = {
|
|
|
1248
1325
|
"UniversalStore is not constructable - use UniversalStore.create() instead"
|
|
1249
1326
|
);
|
|
1250
1327
|
if (t.isInternalConstructing = !1, this.id = e.id, this.actorId = Date.now().toString(36) + Math.random().toString(36).substring(2), this.
|
|
1251
|
-
actorType = e.leader ? t.ActorType.LEADER : t.ActorType.FOLLOWER, this.state = e.initialState, this.channelEventName = `${
|
|
1328
|
+
actorType = e.leader ? t.ActorType.LEADER : t.ActorType.FOLLOWER, this.state = e.initialState, this.channelEventName = `${Ht}${this.id}`,
|
|
1252
1329
|
this.debug("constructor", {
|
|
1253
1330
|
options: e,
|
|
1254
1331
|
environmentOverrides: r,
|
|
1255
1332
|
channelEventName: this.channelEventName
|
|
1256
1333
|
}), this.actor.type === t.ActorType.LEADER)
|
|
1257
1334
|
this.syncing = {
|
|
1258
|
-
state:
|
|
1335
|
+
state: x.RESOLVED,
|
|
1259
1336
|
promise: Promise.resolve()
|
|
1260
1337
|
};
|
|
1261
1338
|
else {
|
|
1262
|
-
let n,
|
|
1263
|
-
n = /* @__PURE__ */
|
|
1264
|
-
this.syncing.state ===
|
|
1265
|
-
}, "syncingResolve"),
|
|
1266
|
-
this.syncing.state ===
|
|
1339
|
+
let n, o, p = new Promise((a, c) => {
|
|
1340
|
+
n = /* @__PURE__ */ s(() => {
|
|
1341
|
+
this.syncing.state === x.PENDING && (this.syncing.state = x.RESOLVED, a());
|
|
1342
|
+
}, "syncingResolve"), o = /* @__PURE__ */ s((i) => {
|
|
1343
|
+
this.syncing.state === x.PENDING && (this.syncing.state = x.REJECTED, c(i));
|
|
1267
1344
|
}, "syncingReject");
|
|
1268
1345
|
});
|
|
1269
1346
|
this.syncing = {
|
|
1270
|
-
state:
|
|
1271
|
-
promise:
|
|
1347
|
+
state: x.PENDING,
|
|
1348
|
+
promise: p,
|
|
1272
1349
|
resolve: n,
|
|
1273
|
-
reject:
|
|
1350
|
+
reject: o
|
|
1274
1351
|
};
|
|
1275
1352
|
}
|
|
1276
1353
|
this.getState = this.getState.bind(this), this.setState = this.setState.bind(this), this.subscribe = this.subscribe.bind(this), this.onStateChange =
|
|
@@ -1281,7 +1358,7 @@ var Ue = "UNIVERSAL_STORE:", C = {
|
|
|
1281
1358
|
{ channel: this.channel, environment: this.environment })) : t.preparation.promise.then(this.prepareThis);
|
|
1282
1359
|
}
|
|
1283
1360
|
static {
|
|
1284
|
-
|
|
1361
|
+
s(this, "UniversalStore");
|
|
1285
1362
|
}
|
|
1286
1363
|
static {
|
|
1287
1364
|
/**
|
|
@@ -1339,11 +1416,11 @@ var Ue = "UNIVERSAL_STORE:", C = {
|
|
|
1339
1416
|
}
|
|
1340
1417
|
static setupPreparationPromise() {
|
|
1341
1418
|
let e, r, n = new Promise(
|
|
1342
|
-
(
|
|
1343
|
-
e = /* @__PURE__ */
|
|
1344
|
-
a
|
|
1345
|
-
}, "resolveRef"), r = /* @__PURE__ */
|
|
1346
|
-
|
|
1419
|
+
(o, p) => {
|
|
1420
|
+
e = /* @__PURE__ */ s((a) => {
|
|
1421
|
+
o(a);
|
|
1422
|
+
}, "resolveRef"), r = /* @__PURE__ */ s((...a) => {
|
|
1423
|
+
p(a);
|
|
1347
1424
|
}, "rejectRef");
|
|
1348
1425
|
}
|
|
1349
1426
|
);
|
|
@@ -1369,12 +1446,12 @@ var Ue = "UNIVERSAL_STORE:", C = {
|
|
|
1369
1446
|
if (!this.channel || !this.environment)
|
|
1370
1447
|
return t.Status.UNPREPARED;
|
|
1371
1448
|
switch (this.syncing?.state) {
|
|
1372
|
-
case
|
|
1449
|
+
case x.PENDING:
|
|
1373
1450
|
case void 0:
|
|
1374
1451
|
return t.Status.SYNCING;
|
|
1375
|
-
case
|
|
1452
|
+
case x.REJECTED:
|
|
1376
1453
|
return t.Status.ERROR;
|
|
1377
|
-
case
|
|
1454
|
+
case x.RESOLVED:
|
|
1378
1455
|
default:
|
|
1379
1456
|
return t.Status.READY;
|
|
1380
1457
|
}
|
|
@@ -1394,17 +1471,17 @@ var Ue = "UNIVERSAL_STORE:", C = {
|
|
|
1394
1471
|
if (!e || typeof e?.id != "string")
|
|
1395
1472
|
throw new TypeError("id is required and must be a string, when creating a UniversalStore");
|
|
1396
1473
|
e.debug && console.debug(
|
|
1397
|
-
|
|
1474
|
+
j.dedent`[UniversalStore]
|
|
1398
1475
|
create`,
|
|
1399
1476
|
{ options: e }
|
|
1400
1477
|
);
|
|
1401
|
-
let r =
|
|
1478
|
+
let r = ve.get(e.id);
|
|
1402
1479
|
if (r)
|
|
1403
|
-
return console.warn(
|
|
1480
|
+
return console.warn(j.dedent`UniversalStore with id "${e.id}" already exists in this environment, re-using existing.
|
|
1404
1481
|
You should reuse the existing instance instead of trying to create a new one.`), r;
|
|
1405
1482
|
t.isInternalConstructing = !0;
|
|
1406
1483
|
let n = new t(e);
|
|
1407
|
-
return
|
|
1484
|
+
return ve.set(e.id, n), n;
|
|
1408
1485
|
}
|
|
1409
1486
|
/**
|
|
1410
1487
|
* Used by Storybook to set the channel for all instances of UniversalStore in the given
|
|
@@ -1424,7 +1501,7 @@ var Ue = "UNIVERSAL_STORE:", C = {
|
|
|
1424
1501
|
let r = this.state, n = typeof e == "function" ? e(r) : e;
|
|
1425
1502
|
if (this.debug("setState", { newState: n, previousState: r, updater: e }), this.status !== t.Status.READY)
|
|
1426
1503
|
throw new TypeError(
|
|
1427
|
-
|
|
1504
|
+
j.dedent`Cannot set state before store is ready. You can get the current status with store.status,
|
|
1428
1505
|
or await store.readyPromise to wait for the store to be ready before sending events.
|
|
1429
1506
|
${JSON.stringify(
|
|
1430
1507
|
{
|
|
@@ -1438,14 +1515,14 @@ var Ue = "UNIVERSAL_STORE:", C = {
|
|
|
1438
1515
|
)}`
|
|
1439
1516
|
);
|
|
1440
1517
|
this.state = n;
|
|
1441
|
-
let
|
|
1518
|
+
let o = {
|
|
1442
1519
|
type: t.InternalEventType.SET_STATE,
|
|
1443
1520
|
payload: {
|
|
1444
1521
|
state: n,
|
|
1445
1522
|
previousState: r
|
|
1446
1523
|
}
|
|
1447
1524
|
};
|
|
1448
|
-
this.emitToChannel(
|
|
1525
|
+
this.emitToChannel(o, { actor: this.actor }), this.emitToListeners(o, { actor: this.actor });
|
|
1449
1526
|
}
|
|
1450
1527
|
/**
|
|
1451
1528
|
* Subscribes to state changes
|
|
@@ -1490,14 +1567,14 @@ var Ue = "UNIVERSAL_STORE:", C = {
|
|
|
1490
1567
|
}, 1e3));
|
|
1491
1568
|
}
|
|
1492
1569
|
emitToListeners(e, r) {
|
|
1493
|
-
let n = this.listeners.get(e.type),
|
|
1570
|
+
let n = this.listeners.get(e.type), o = this.listeners.get("*");
|
|
1494
1571
|
this.debug("emitToListeners", {
|
|
1495
1572
|
event: e,
|
|
1496
1573
|
eventInfo: r,
|
|
1497
1574
|
eventTypeListeners: n,
|
|
1498
|
-
everythingListeners:
|
|
1499
|
-
}), [...n ?? [], ...
|
|
1500
|
-
(
|
|
1575
|
+
everythingListeners: o
|
|
1576
|
+
}), [...n ?? [], ...o ?? []].forEach(
|
|
1577
|
+
(p) => p(e, r)
|
|
1501
1578
|
);
|
|
1502
1579
|
}
|
|
1503
1580
|
handleChannelEvents(e) {
|
|
@@ -1505,28 +1582,28 @@ var Ue = "UNIVERSAL_STORE:", C = {
|
|
|
1505
1582
|
if ([n.actor.id, n.forwardingActor?.id].includes(this.actor.id)) {
|
|
1506
1583
|
this.debug("handleChannelEvents: Ignoring event from self", { channelEvent: e });
|
|
1507
1584
|
return;
|
|
1508
|
-
} else if (this.syncing?.state ===
|
|
1585
|
+
} else if (this.syncing?.state === x.PENDING && r.type !== t.InternalEventType.EXISTING_STATE_RESPONSE) {
|
|
1509
1586
|
this.debug("handleChannelEvents: Ignoring event while syncing", { channelEvent: e });
|
|
1510
1587
|
return;
|
|
1511
1588
|
}
|
|
1512
1589
|
if (this.debug("handleChannelEvents", { channelEvent: e }), this.actor.type === t.ActorType.LEADER) {
|
|
1513
|
-
let
|
|
1590
|
+
let o = !0;
|
|
1514
1591
|
switch (r.type) {
|
|
1515
1592
|
case t.InternalEventType.EXISTING_STATE_REQUEST:
|
|
1516
|
-
|
|
1517
|
-
let
|
|
1593
|
+
o = !1;
|
|
1594
|
+
let p = {
|
|
1518
1595
|
type: t.InternalEventType.EXISTING_STATE_RESPONSE,
|
|
1519
1596
|
payload: this.state
|
|
1520
1597
|
};
|
|
1521
1598
|
this.debug("handleChannelEvents: responding to existing state request", {
|
|
1522
|
-
responseEvent:
|
|
1523
|
-
}), this.emitToChannel(
|
|
1599
|
+
responseEvent: p
|
|
1600
|
+
}), this.emitToChannel(p, { actor: this.actor }), this.emitToListeners(p, { actor: this.actor });
|
|
1524
1601
|
break;
|
|
1525
1602
|
case t.InternalEventType.LEADER_CREATED:
|
|
1526
|
-
|
|
1603
|
+
o = !1, this.syncing.state = x.REJECTED, this.debug("handleChannelEvents: erroring due to second leader being created", {
|
|
1527
1604
|
event: r
|
|
1528
1605
|
}), console.error(
|
|
1529
|
-
|
|
1606
|
+
j.dedent`Detected multiple UniversalStore leaders created with the same id "${this.id}".
|
|
1530
1607
|
Only one leader can exists at a time, your stores are now in an invalid state.
|
|
1531
1608
|
Leaders detected:
|
|
1532
1609
|
this: ${JSON.stringify(this.actor, null, 2)}
|
|
@@ -1534,7 +1611,7 @@ var Ue = "UNIVERSAL_STORE:", C = {
|
|
|
1534
1611
|
);
|
|
1535
1612
|
break;
|
|
1536
1613
|
}
|
|
1537
|
-
|
|
1614
|
+
o && (this.debug("handleChannelEvents: forwarding event", { channelEvent: e }), this.emitToChannel(r, { actor: n.actor, forwardingActor: this.
|
|
1538
1615
|
actor }));
|
|
1539
1616
|
}
|
|
1540
1617
|
if (this.actor.type === t.ActorType.FOLLOWER)
|
|
@@ -1542,17 +1619,17 @@ var Ue = "UNIVERSAL_STORE:", C = {
|
|
|
1542
1619
|
case t.InternalEventType.EXISTING_STATE_RESPONSE:
|
|
1543
1620
|
if (this.debug("handleChannelEvents: Setting state from leader's existing state response", {
|
|
1544
1621
|
event: r
|
|
1545
|
-
}), this.syncing?.state !==
|
|
1622
|
+
}), this.syncing?.state !== x.PENDING)
|
|
1546
1623
|
break;
|
|
1547
1624
|
this.syncing.resolve?.();
|
|
1548
|
-
let
|
|
1625
|
+
let o = {
|
|
1549
1626
|
type: t.InternalEventType.SET_STATE,
|
|
1550
1627
|
payload: {
|
|
1551
1628
|
state: r.payload,
|
|
1552
1629
|
previousState: this.state
|
|
1553
1630
|
}
|
|
1554
1631
|
};
|
|
1555
|
-
this.state = r.payload, this.emitToListeners(
|
|
1632
|
+
this.state = r.payload, this.emitToListeners(o, n);
|
|
1556
1633
|
break;
|
|
1557
1634
|
}
|
|
1558
1635
|
switch (r.type) {
|
|
@@ -1564,7 +1641,7 @@ var Ue = "UNIVERSAL_STORE:", C = {
|
|
|
1564
1641
|
}
|
|
1565
1642
|
debug(e, r) {
|
|
1566
1643
|
this.debugging && console.debug(
|
|
1567
|
-
|
|
1644
|
+
j.dedent`[UniversalStore::${this.id}::${this.environment ?? t.Environment.UNKNOWN}]
|
|
1568
1645
|
${e}`,
|
|
1569
1646
|
JSON.stringify(
|
|
1570
1647
|
{
|
|
@@ -1589,21 +1666,21 @@ var Ue = "UNIVERSAL_STORE:", C = {
|
|
|
1589
1666
|
};
|
|
1590
1667
|
|
|
1591
1668
|
// src/channels/main.ts
|
|
1592
|
-
var
|
|
1593
|
-
nerateRandomId"),
|
|
1669
|
+
var Vt = /* @__PURE__ */ s((t) => t.transports !== void 0, "isMulti"), Jt = /* @__PURE__ */ s(() => Math.random().toString(16).slice(2), "ge\
|
|
1670
|
+
nerateRandomId"), U = class {
|
|
1594
1671
|
constructor(e = {}) {
|
|
1595
|
-
this.sender =
|
|
1672
|
+
this.sender = Jt();
|
|
1596
1673
|
this.events = {};
|
|
1597
1674
|
this.data = {};
|
|
1598
1675
|
this.transports = [];
|
|
1599
|
-
this.isAsync = e.async || !1,
|
|
1676
|
+
this.isAsync = e.async || !1, Vt(e) ? (this.transports = e.transports || [], this.transports.forEach((r) => {
|
|
1600
1677
|
r.setHandler((n) => this.handleEvent(n));
|
|
1601
1678
|
})) : this.transports = e.transport ? [e.transport] : [], this.transports.forEach((r) => {
|
|
1602
1679
|
r.setHandler((n) => this.handleEvent(n));
|
|
1603
1680
|
});
|
|
1604
1681
|
}
|
|
1605
1682
|
static {
|
|
1606
|
-
|
|
1683
|
+
s(this, "Channel");
|
|
1607
1684
|
}
|
|
1608
1685
|
get hasTransport() {
|
|
1609
1686
|
return this.transports.length > 0;
|
|
@@ -1612,14 +1689,14 @@ nerateRandomId"), F = class {
|
|
|
1612
1689
|
this.events[e] = this.events[e] || [], this.events[e].push(r);
|
|
1613
1690
|
}
|
|
1614
1691
|
emit(e, ...r) {
|
|
1615
|
-
let n = { type: e, args: r, from: this.sender },
|
|
1616
|
-
r.length >= 1 && r[0] && r[0].options && (
|
|
1617
|
-
let
|
|
1618
|
-
this.transports.forEach((
|
|
1619
|
-
|
|
1692
|
+
let n = { type: e, args: r, from: this.sender }, o = {};
|
|
1693
|
+
r.length >= 1 && r[0] && r[0].options && (o = r[0].options);
|
|
1694
|
+
let p = /* @__PURE__ */ s(() => {
|
|
1695
|
+
this.transports.forEach((a) => {
|
|
1696
|
+
a.send(n, o);
|
|
1620
1697
|
}), this.handleEvent(n);
|
|
1621
1698
|
}, "handler");
|
|
1622
|
-
this.isAsync ? setImmediate(
|
|
1699
|
+
this.isAsync ? setImmediate(p) : p();
|
|
1623
1700
|
}
|
|
1624
1701
|
last(e) {
|
|
1625
1702
|
return this.data[e];
|
|
@@ -1643,7 +1720,7 @@ nerateRandomId"), F = class {
|
|
|
1643
1720
|
}
|
|
1644
1721
|
removeListener(e, r) {
|
|
1645
1722
|
let n = this.listeners(e);
|
|
1646
|
-
n && (this.events[e] = n.filter((
|
|
1723
|
+
n && (this.events[e] = n.filter((o) => o !== r));
|
|
1647
1724
|
}
|
|
1648
1725
|
on(e, r) {
|
|
1649
1726
|
this.addListener(e, r);
|
|
@@ -1658,60 +1735,60 @@ nerateRandomId"), F = class {
|
|
|
1658
1735
|
}), this.data[e.type] = e.args;
|
|
1659
1736
|
}
|
|
1660
1737
|
onceListener(e, r) {
|
|
1661
|
-
let n = /* @__PURE__ */
|
|
1738
|
+
let n = /* @__PURE__ */ s((...o) => (this.removeListener(e, n), r(...o)), "onceListener");
|
|
1662
1739
|
return n;
|
|
1663
1740
|
}
|
|
1664
1741
|
};
|
|
1665
1742
|
|
|
1666
1743
|
// src/channels/postmessage/index.ts
|
|
1667
|
-
var
|
|
1668
|
-
|
|
1744
|
+
var B = require("storybook/internal/client-logger"), ts = ee(require("storybook/internal/core-events"), 1), _ = require("@storybook/global"),
|
|
1745
|
+
V = ee(Ne(), 1);
|
|
1669
1746
|
|
|
1670
1747
|
// ../node_modules/tiny-invariant/dist/esm/tiny-invariant.js
|
|
1671
|
-
var
|
|
1672
|
-
function
|
|
1748
|
+
var es = process.env.NODE_ENV === "production", Ie = "Invariant failed";
|
|
1749
|
+
function oe(t, e) {
|
|
1673
1750
|
if (!t) {
|
|
1674
|
-
if (
|
|
1675
|
-
throw new Error(
|
|
1676
|
-
var r = typeof e == "function" ? e() : e, n = r ? "".concat(
|
|
1751
|
+
if (es)
|
|
1752
|
+
throw new Error(Ie);
|
|
1753
|
+
var r = typeof e == "function" ? e() : e, n = r ? "".concat(Ie, ": ").concat(r) : Ie;
|
|
1677
1754
|
throw new Error(n);
|
|
1678
1755
|
}
|
|
1679
1756
|
}
|
|
1680
|
-
|
|
1757
|
+
s(oe, "invariant");
|
|
1681
1758
|
|
|
1682
1759
|
// src/channels/postmessage/getEventSourceUrl.ts
|
|
1683
|
-
var
|
|
1684
|
-
var
|
|
1760
|
+
var _t = require("storybook/internal/client-logger");
|
|
1761
|
+
var bt = /* @__PURE__ */ s((t) => {
|
|
1685
1762
|
let e = Array.from(
|
|
1686
1763
|
document.querySelectorAll("iframe[data-is-storybook]")
|
|
1687
|
-
), [r, ...n] = e.filter((
|
|
1764
|
+
), [r, ...n] = e.filter((p) => {
|
|
1688
1765
|
try {
|
|
1689
|
-
return
|
|
1766
|
+
return p.contentWindow?.location.origin === t.source.location.origin && p.contentWindow?.location.pathname === t.source.location.pathname;
|
|
1690
1767
|
} catch {
|
|
1691
1768
|
}
|
|
1692
1769
|
try {
|
|
1693
|
-
return
|
|
1770
|
+
return p.contentWindow === t.source;
|
|
1694
1771
|
} catch {
|
|
1695
1772
|
}
|
|
1696
|
-
let
|
|
1773
|
+
let a = p.getAttribute("src"), c;
|
|
1697
1774
|
try {
|
|
1698
|
-
if (!
|
|
1775
|
+
if (!a)
|
|
1699
1776
|
return !1;
|
|
1700
|
-
({ origin: c } = new URL(
|
|
1777
|
+
({ origin: c } = new URL(a, document.location.toString()));
|
|
1701
1778
|
} catch {
|
|
1702
1779
|
return !1;
|
|
1703
1780
|
}
|
|
1704
1781
|
return c === t.origin;
|
|
1705
|
-
}),
|
|
1706
|
-
if (
|
|
1707
|
-
let { protocol:
|
|
1708
|
-
return `${
|
|
1782
|
+
}), o = r?.getAttribute("src");
|
|
1783
|
+
if (o && n.length === 0) {
|
|
1784
|
+
let { protocol: p, host: a, pathname: c } = new URL(o, document.location.toString());
|
|
1785
|
+
return `${p}//${a}${c}`;
|
|
1709
1786
|
}
|
|
1710
|
-
return n.length > 0 &&
|
|
1787
|
+
return n.length > 0 && _t.logger.error("found multiple candidates for event source"), null;
|
|
1711
1788
|
}, "getEventSourceUrl");
|
|
1712
1789
|
|
|
1713
1790
|
// src/channels/postmessage/index.ts
|
|
1714
|
-
var { document:
|
|
1791
|
+
var { document: Re, location: je } = _.global, St = "storybook-channel", rs = { maxDepth: 25 }, H = class {
|
|
1715
1792
|
constructor(e) {
|
|
1716
1793
|
this.config = e;
|
|
1717
1794
|
this.connected = !1;
|
|
@@ -1720,7 +1797,7 @@ var { document: oe, location: ie } = _.global, Te = "storybook-channel", ze = {
|
|
|
1720
1797
|
throw new Error(`postmsg-channel: "config.page" cannot be "${e.page}"`);
|
|
1721
1798
|
}
|
|
1722
1799
|
static {
|
|
1723
|
-
|
|
1800
|
+
s(this, "PostMessageTransport");
|
|
1724
1801
|
}
|
|
1725
1802
|
setHandler(e) {
|
|
1726
1803
|
this.handler = (...r) => {
|
|
@@ -1737,49 +1814,43 @@ var { document: oe, location: ie } = _.global, Te = "storybook-channel", ze = {
|
|
|
1737
1814
|
let {
|
|
1738
1815
|
target: n,
|
|
1739
1816
|
// telejson options
|
|
1740
|
-
allowRegExp:
|
|
1741
|
-
|
|
1742
|
-
|
|
1743
|
-
|
|
1744
|
-
|
|
1745
|
-
|
|
1746
|
-
|
|
1747
|
-
|
|
1748
|
-
space: y,
|
|
1749
|
-
lazyEval: d
|
|
1750
|
-
} = r || {}, v = Object.fromEntries(
|
|
1817
|
+
allowRegExp: o,
|
|
1818
|
+
allowSymbol: p,
|
|
1819
|
+
allowDate: a,
|
|
1820
|
+
allowError: c,
|
|
1821
|
+
allowUndefined: i,
|
|
1822
|
+
maxDepth: l,
|
|
1823
|
+
space: d
|
|
1824
|
+
} = r || {}, u = Object.fromEntries(
|
|
1751
1825
|
Object.entries({
|
|
1752
|
-
allowRegExp:
|
|
1753
|
-
|
|
1754
|
-
|
|
1755
|
-
|
|
1756
|
-
|
|
1757
|
-
|
|
1758
|
-
|
|
1759
|
-
|
|
1760
|
-
|
|
1761
|
-
|
|
1762
|
-
}).filter(([j, L]) => typeof L < "u")
|
|
1763
|
-
), w = {
|
|
1764
|
-
...ze,
|
|
1826
|
+
allowRegExp: o,
|
|
1827
|
+
allowSymbol: p,
|
|
1828
|
+
allowDate: a,
|
|
1829
|
+
allowError: c,
|
|
1830
|
+
allowUndefined: i,
|
|
1831
|
+
maxDepth: l,
|
|
1832
|
+
space: d
|
|
1833
|
+
}).filter(([w, A]) => typeof A < "u")
|
|
1834
|
+
), y = {
|
|
1835
|
+
...rs,
|
|
1765
1836
|
..._.global.CHANNEL_OPTIONS || {},
|
|
1766
|
-
...
|
|
1767
|
-
},
|
|
1837
|
+
...u
|
|
1838
|
+
}, g = this.getFrames(n), h = new URLSearchParams(je?.search || ""), C = (0, V.stringify)(
|
|
1768
1839
|
{
|
|
1769
|
-
key:
|
|
1840
|
+
key: St,
|
|
1770
1841
|
event: e,
|
|
1771
|
-
refId:
|
|
1842
|
+
refId: h.get("refId")
|
|
1772
1843
|
},
|
|
1773
|
-
|
|
1844
|
+
y
|
|
1774
1845
|
);
|
|
1775
|
-
return
|
|
1846
|
+
return g.length ? (this.buffer.length && this.flush(), g.forEach((w) => {
|
|
1776
1847
|
try {
|
|
1777
|
-
|
|
1848
|
+
w.postMessage(C, "*");
|
|
1778
1849
|
} catch {
|
|
1779
|
-
|
|
1850
|
+
B.logger.error("sending over postmessage fail");
|
|
1780
1851
|
}
|
|
1781
|
-
}), Promise.resolve(null)) : new Promise((
|
|
1782
|
-
this.buffer.push({ event: e, resolve:
|
|
1852
|
+
}), Promise.resolve(null)) : new Promise((w, A) => {
|
|
1853
|
+
this.buffer.push({ event: e, resolve: w, reject: A });
|
|
1783
1854
|
});
|
|
1784
1855
|
}
|
|
1785
1856
|
flush() {
|
|
@@ -1791,10 +1862,10 @@ var { document: oe, location: ie } = _.global, Te = "storybook-channel", ze = {
|
|
|
1791
1862
|
getFrames(e) {
|
|
1792
1863
|
if (this.config.page === "manager") {
|
|
1793
1864
|
let n = Array.from(
|
|
1794
|
-
|
|
1795
|
-
).flatMap((
|
|
1865
|
+
Re.querySelectorAll("iframe[data-is-storybook][data-is-loaded]")
|
|
1866
|
+
).flatMap((o) => {
|
|
1796
1867
|
try {
|
|
1797
|
-
return
|
|
1868
|
+
return o.contentWindow && o.dataset.isStorybook !== void 0 && o.id === e ? [o.contentWindow] : [];
|
|
1798
1869
|
} catch {
|
|
1799
1870
|
return [];
|
|
1800
1871
|
}
|
|
@@ -1805,71 +1876,71 @@ var { document: oe, location: ie } = _.global, Te = "storybook-channel", ze = {
|
|
|
1805
1876
|
}
|
|
1806
1877
|
getCurrentFrames() {
|
|
1807
1878
|
return this.config.page === "manager" ? Array.from(
|
|
1808
|
-
|
|
1879
|
+
Re.querySelectorAll('[data-is-storybook="true"]')
|
|
1809
1880
|
).flatMap((r) => r.contentWindow ? [r.contentWindow] : []) : _.global && _.global.parent ? [_.global.parent] : [];
|
|
1810
1881
|
}
|
|
1811
1882
|
getLocalFrame() {
|
|
1812
1883
|
return this.config.page === "manager" ? Array.from(
|
|
1813
|
-
|
|
1884
|
+
Re.querySelectorAll("#storybook-preview-iframe")
|
|
1814
1885
|
).flatMap((r) => r.contentWindow ? [r.contentWindow] : []) : _.global && _.global.parent ? [_.global.parent] : [];
|
|
1815
1886
|
}
|
|
1816
1887
|
handleEvent(e) {
|
|
1817
1888
|
try {
|
|
1818
|
-
let { data: r } = e, { key: n, event:
|
|
1889
|
+
let { data: r } = e, { key: n, event: o, refId: p } = typeof r == "string" && (0, V.isJSON)(r) ? (0, V.parse)(r, _.global.CHANNEL_OPTIONS ||
|
|
1819
1890
|
{}) : r;
|
|
1820
|
-
if (n ===
|
|
1821
|
-
let
|
|
1822
|
-
1EA7FD; background: black"> preview </span>', c = Object.values(
|
|
1823
|
-
pan style="color: #FFAE00">${
|
|
1824
|
-
if (
|
|
1825
|
-
|
|
1826
|
-
`${
|
|
1891
|
+
if (n === St) {
|
|
1892
|
+
let a = this.config.page === "manager" ? '<span style="color: #37D5D3; background: black"> manager </span>' : '<span style="color: #\
|
|
1893
|
+
1EA7FD; background: black"> preview </span>', c = Object.values(ts).includes(o.type) ? `<span style="color: #FF4785">${o.type}</span>` : `<s\
|
|
1894
|
+
pan style="color: #FFAE00">${o.type}</span>`;
|
|
1895
|
+
if (p && (o.refId = p), o.source = this.config.page === "preview" ? e.origin : bt(e), !o.source) {
|
|
1896
|
+
B.pretty.error(
|
|
1897
|
+
`${a} received ${c} but was unable to determine the source of the event`
|
|
1827
1898
|
);
|
|
1828
1899
|
return;
|
|
1829
1900
|
}
|
|
1830
|
-
let i = `${
|
|
1831
|
-
|
|
1832
|
-
|
|
1833
|
-
...
|
|
1834
|
-
),
|
|
1901
|
+
let i = `${a} received ${c} (${r.length})`;
|
|
1902
|
+
B.pretty.debug(
|
|
1903
|
+
je.origin !== o.source ? i : `${i} <span style="color: gray">(on ${je.origin} from ${o.source})</span>`,
|
|
1904
|
+
...o.args
|
|
1905
|
+
), oe(this.handler, "ChannelHandler should be set"), this.handler(o);
|
|
1835
1906
|
}
|
|
1836
1907
|
} catch (r) {
|
|
1837
|
-
|
|
1908
|
+
B.logger.error(r);
|
|
1838
1909
|
}
|
|
1839
1910
|
}
|
|
1840
1911
|
};
|
|
1841
1912
|
|
|
1842
1913
|
// src/channels/websocket/index.ts
|
|
1843
|
-
var
|
|
1844
|
-
var { WebSocket:
|
|
1914
|
+
var Tt = ee(require("storybook/internal/core-events"), 1), Le = require("@storybook/global"), z = ee(Ne(), 1);
|
|
1915
|
+
var { WebSocket: ns } = Le.global, De = 15e3, $e = 5e3, J = class {
|
|
1845
1916
|
constructor({ url: e, onError: r, page: n }) {
|
|
1846
1917
|
this.buffer = [];
|
|
1847
1918
|
this.isReady = !1;
|
|
1848
1919
|
this.isClosed = !1;
|
|
1849
1920
|
this.pingTimeout = 0;
|
|
1850
|
-
this.socket = new
|
|
1921
|
+
this.socket = new ns(e), this.socket.onopen = () => {
|
|
1851
1922
|
this.isReady = !0, this.heartbeat(), this.flush();
|
|
1852
|
-
}, this.socket.onmessage = ({ data:
|
|
1853
|
-
let
|
|
1854
|
-
|
|
1923
|
+
}, this.socket.onmessage = ({ data: o }) => {
|
|
1924
|
+
let p = typeof o == "string" && (0, z.isJSON)(o) ? (0, z.parse)(o) : o;
|
|
1925
|
+
oe(this.handler, "WebsocketTransport handler should be set"), this.handler(p), p.type === "ping" && (this.heartbeat(), this.send({ type: "\
|
|
1855
1926
|
pong" }));
|
|
1856
|
-
}, this.socket.onerror = (
|
|
1857
|
-
r && r(
|
|
1858
|
-
}, this.socket.onclose = (
|
|
1859
|
-
|
|
1860
|
-
type:
|
|
1861
|
-
args: [{ reason:
|
|
1927
|
+
}, this.socket.onerror = (o) => {
|
|
1928
|
+
r && r(o);
|
|
1929
|
+
}, this.socket.onclose = (o) => {
|
|
1930
|
+
oe(this.handler, "WebsocketTransport handler should be set"), this.handler({
|
|
1931
|
+
type: Tt.CHANNEL_WS_DISCONNECT,
|
|
1932
|
+
args: [{ reason: o.reason, code: o.code }],
|
|
1862
1933
|
from: n || "preview"
|
|
1863
1934
|
}), this.isClosed = !0, clearTimeout(this.pingTimeout);
|
|
1864
1935
|
};
|
|
1865
1936
|
}
|
|
1866
1937
|
static {
|
|
1867
|
-
|
|
1938
|
+
s(this, "WebsocketTransport");
|
|
1868
1939
|
}
|
|
1869
1940
|
heartbeat() {
|
|
1870
1941
|
clearTimeout(this.pingTimeout), this.pingTimeout = setTimeout(() => {
|
|
1871
1942
|
this.socket.close(3008, "timeout");
|
|
1872
|
-
},
|
|
1943
|
+
}, De + $e);
|
|
1873
1944
|
}
|
|
1874
1945
|
setHandler(e) {
|
|
1875
1946
|
this.handler = e;
|
|
@@ -1881,10 +1952,9 @@ pong" }));
|
|
|
1881
1952
|
this.buffer.push(e);
|
|
1882
1953
|
}
|
|
1883
1954
|
sendNow(e) {
|
|
1884
|
-
let r = (0,
|
|
1955
|
+
let r = (0, z.stringify)(e, {
|
|
1885
1956
|
maxDepth: 15,
|
|
1886
|
-
|
|
1887
|
-
...se.global.CHANNEL_OPTIONS
|
|
1957
|
+
...Le.global.CHANNEL_OPTIONS
|
|
1888
1958
|
});
|
|
1889
1959
|
this.socket.send(r);
|
|
1890
1960
|
}
|
|
@@ -1895,19 +1965,19 @@ pong" }));
|
|
|
1895
1965
|
};
|
|
1896
1966
|
|
|
1897
1967
|
// src/channels/index.ts
|
|
1898
|
-
var { CONFIG_TYPE:
|
|
1899
|
-
function
|
|
1900
|
-
let r = [new
|
|
1901
|
-
if (
|
|
1902
|
-
let
|
|
1968
|
+
var { CONFIG_TYPE: os } = At.global, ss = U;
|
|
1969
|
+
function is({ page: t, extraTransports: e = [] }) {
|
|
1970
|
+
let r = [new H({ page: t }), ...e];
|
|
1971
|
+
if (os === "DEVELOPMENT") {
|
|
1972
|
+
let o = window.location.protocol === "http:" ? "ws" : "wss", { hostname: p, port: a } = window.location, c = `${o}://${p}:${a}/storybook\
|
|
1903
1973
|
-server-channel`;
|
|
1904
|
-
r.push(new
|
|
1974
|
+
r.push(new J({ url: c, onError: /* @__PURE__ */ s(() => {
|
|
1905
1975
|
}, "onError"), page: t }));
|
|
1906
1976
|
}
|
|
1907
|
-
let n = new
|
|
1977
|
+
let n = new U({ transports: r });
|
|
1908
1978
|
return M.__prepare(
|
|
1909
1979
|
n,
|
|
1910
1980
|
t === "manager" ? M.Environment.MANAGER : M.Environment.PREVIEW
|
|
1911
1981
|
), n;
|
|
1912
1982
|
}
|
|
1913
|
-
|
|
1983
|
+
s(is, "createBrowserChannel");
|