@contentstack/live-preview-utils 4.1.3 → 4.2.0
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/LICENSE +1 -1
- package/README.md +2 -2
- package/dist/legacy/{chunk-HLXJTSQ3.js → chunk-7SRLYDRL.js} +92 -92
- package/dist/legacy/chunk-7SRLYDRL.js.map +1 -0
- package/dist/legacy/light-sdk.cjs +1 -1
- package/dist/legacy/light-sdk.js +1 -1
- package/dist/legacy/livePreview/eventManager/livePreviewEventManager.cjs +91 -91
- package/dist/legacy/livePreview/eventManager/livePreviewEventManager.cjs.map +1 -1
- package/dist/legacy/livePreview/eventManager/livePreviewEventManager.js +1 -1
- package/dist/legacy/livePreview/eventManager/postMessageEvent.hooks.cjs +1 -1
- package/dist/legacy/livePreview/eventManager/postMessageEvent.hooks.js +1 -1
- package/dist/legacy/preview/contentstack-live-preview-HOC.cjs +1 -1
- package/dist/legacy/preview/contentstack-live-preview-HOC.js +1 -1
- package/dist/legacy/timeline/timelinePostMessage/timelinePostMessage.cjs +91 -91
- package/dist/legacy/timeline/timelinePostMessage/timelinePostMessage.cjs.map +1 -1
- package/dist/legacy/timeline/timelinePostMessage/timelinePostMessage.js +1 -1
- package/dist/legacy/visualBuilder/utils/visualBuilderPostMessage.cjs +91 -91
- package/dist/legacy/visualBuilder/utils/visualBuilderPostMessage.cjs.map +1 -1
- package/dist/legacy/visualBuilder/utils/visualBuilderPostMessage.js +1 -1
- package/dist/modern/{chunk-LNSFZGX4.js → chunk-JYE4G3PN.js} +92 -92
- package/dist/modern/chunk-JYE4G3PN.js.map +1 -0
- package/dist/modern/light-sdk.cjs +1 -1
- package/dist/modern/light-sdk.js +1 -1
- package/dist/modern/livePreview/eventManager/livePreviewEventManager.cjs +91 -91
- package/dist/modern/livePreview/eventManager/livePreviewEventManager.cjs.map +1 -1
- package/dist/modern/livePreview/eventManager/livePreviewEventManager.js +1 -1
- package/dist/modern/livePreview/eventManager/postMessageEvent.hooks.cjs +1 -1
- package/dist/modern/livePreview/eventManager/postMessageEvent.hooks.js +1 -1
- package/dist/modern/preview/contentstack-live-preview-HOC.cjs +1 -1
- package/dist/modern/preview/contentstack-live-preview-HOC.js +1 -1
- package/dist/modern/timeline/timelinePostMessage/timelinePostMessage.cjs +91 -91
- package/dist/modern/timeline/timelinePostMessage/timelinePostMessage.cjs.map +1 -1
- package/dist/modern/timeline/timelinePostMessage/timelinePostMessage.js +1 -1
- package/dist/modern/visualBuilder/utils/visualBuilderPostMessage.cjs +91 -91
- package/dist/modern/visualBuilder/utils/visualBuilderPostMessage.cjs.map +1 -1
- package/dist/modern/visualBuilder/utils/visualBuilderPostMessage.js +1 -1
- package/package.json +6 -6
- package/dist/legacy/chunk-HLXJTSQ3.js.map +0 -1
- package/dist/modern/chunk-LNSFZGX4.js.map +0 -1
|
@@ -6,23 +6,23 @@ import {
|
|
|
6
6
|
var require_dist = __commonJS({
|
|
7
7
|
"node_modules/@contentstack/advanced-post-message/dist/index.js"(exports, module) {
|
|
8
8
|
"use strict";
|
|
9
|
-
!function(e, t) {
|
|
9
|
+
!(function(e, t) {
|
|
10
10
|
"object" == typeof exports && "object" == typeof module ? module.exports = t() : "function" == typeof define && define.amd ? define([], t) : "object" == typeof exports ? exports.ContentstackAdvPostMessage = t() : e.ContentstackAdvPostMessage = t();
|
|
11
|
-
}(exports, () => {
|
|
11
|
+
})(exports, (() => {
|
|
12
12
|
return e = { 706: (e2, t2, r) => {
|
|
13
13
|
"use strict";
|
|
14
14
|
Object.defineProperty(t2, "__esModule", { value: true }), t2.Config = void 0;
|
|
15
|
-
var n = r(450), o = r(666), i = r(628), s = function() {
|
|
15
|
+
var n = r(450), o = r(666), i = r(628), s = (function() {
|
|
16
16
|
function e3() {
|
|
17
17
|
this.config = (0, o.getDefaultConfig)();
|
|
18
18
|
}
|
|
19
19
|
return e3.prototype.replace = function(e4) {
|
|
20
|
-
!function(e5, t3) {
|
|
20
|
+
!(function(e5, t3) {
|
|
21
21
|
var r2, o2, s2, u;
|
|
22
22
|
if (t3.debug = null !== (r2 = e5.debug) && void 0 !== r2 ? r2 : t3.debug, "" === e5.channelId) throw new Error((0, i.getErrorMessage)(n.ERROR_MESSAGES.common.channelIdRequired));
|
|
23
23
|
t3.channelId = null !== (o2 = e5.channelId) && void 0 !== o2 ? o2 : t3.channelId, t3.suppressErrors = null !== (s2 = e5.suppressErrors) && void 0 !== s2 ? s2 : t3.suppressErrors, t3.targetOrigin = null !== (u = e5.targetOrigin) && void 0 !== u ? u : t3.targetOrigin, e5.target ? t3.targetWindow = e5.target : window ? t3.targetWindow = window : t3.targetWindow = { postMessage: function() {
|
|
24
24
|
} };
|
|
25
|
-
}(e4, this.config);
|
|
25
|
+
})(e4, this.config);
|
|
26
26
|
}, e3.prototype.set = function(e4, t3) {
|
|
27
27
|
this.config[e4] = t3;
|
|
28
28
|
}, e3.prototype.get = function(e4) {
|
|
@@ -32,7 +32,7 @@ var require_dist = __commonJS({
|
|
|
32
32
|
}, e3.prototype.reset = function() {
|
|
33
33
|
this.config = (0, o.getDefaultConfig)();
|
|
34
34
|
}, e3;
|
|
35
|
-
}();
|
|
35
|
+
})();
|
|
36
36
|
t2.Config = s;
|
|
37
37
|
}, 851: (e2, t2) => {
|
|
38
38
|
"use strict";
|
|
@@ -89,7 +89,7 @@ var require_dist = __commonJS({
|
|
|
89
89
|
}), i = this && this.__exportStar || function(e3, t3) {
|
|
90
90
|
for (var r2 in e3) "default" === r2 || Object.prototype.hasOwnProperty.call(t3, r2) || o(t3, e3, r2);
|
|
91
91
|
}, s = this && this.__awaiter || function(e3, t3, r2, n2) {
|
|
92
|
-
return new (r2 || (r2 = Promise))(function(o2, i2) {
|
|
92
|
+
return new (r2 || (r2 = Promise))((function(o2, i2) {
|
|
93
93
|
function s2(e4) {
|
|
94
94
|
try {
|
|
95
95
|
a2(n2.next(e4));
|
|
@@ -106,12 +106,12 @@ var require_dist = __commonJS({
|
|
|
106
106
|
}
|
|
107
107
|
function a2(e4) {
|
|
108
108
|
var t4;
|
|
109
|
-
e4.done ? o2(e4.value) : (t4 = e4.value, t4 instanceof r2 ? t4 : new r2(function(e5) {
|
|
109
|
+
e4.done ? o2(e4.value) : (t4 = e4.value, t4 instanceof r2 ? t4 : new r2((function(e5) {
|
|
110
110
|
e5(t4);
|
|
111
|
-
})).then(s2, u2);
|
|
111
|
+
}))).then(s2, u2);
|
|
112
112
|
}
|
|
113
113
|
a2((n2 = n2.apply(e3, t3 || [])).next());
|
|
114
|
-
});
|
|
114
|
+
}));
|
|
115
115
|
}, u = this && this.__generator || function(e3, t3) {
|
|
116
116
|
var r2, n2, o2, i2, s2 = { label: 0, sent: function() {
|
|
117
117
|
if (1 & o2[0]) throw o2[1];
|
|
@@ -122,7 +122,7 @@ var require_dist = __commonJS({
|
|
|
122
122
|
}), i2;
|
|
123
123
|
function u2(u3) {
|
|
124
124
|
return function(a2) {
|
|
125
|
-
return function(u4) {
|
|
125
|
+
return (function(u4) {
|
|
126
126
|
if (r2) throw new TypeError("Generator is already executing.");
|
|
127
127
|
for (; i2 && (i2 = 0, u4[0] && (s2 = 0)), s2; ) try {
|
|
128
128
|
if (r2 = 1, n2 && (o2 = 2 & u4[0] ? n2.return : u4[0] ? n2.throw || ((o2 = n2.return) && o2.call(n2), 0) : n2.next) && !(o2 = o2.call(n2, u4[1])).done) return o2;
|
|
@@ -167,30 +167,30 @@ var require_dist = __commonJS({
|
|
|
167
167
|
}
|
|
168
168
|
if (5 & u4[0]) throw u4[1];
|
|
169
169
|
return { value: u4[0] ? u4[1] : void 0, done: true };
|
|
170
|
-
}([u3, a2]);
|
|
170
|
+
})([u3, a2]);
|
|
171
171
|
};
|
|
172
172
|
}
|
|
173
173
|
};
|
|
174
174
|
Object.defineProperty(t2, "__esModule", { value: true }), t2.EventManager = void 0;
|
|
175
|
-
var a = r(834), c = r(706), d = r(450), l = r(897), f = r(628), h = r(768), g = r(610), p = r(574), v = function() {
|
|
175
|
+
var a = r(834), c = r(706), d = r(450), l = r(897), f = r(628), h = r(768), g = r(610), p = r(574), v = (function() {
|
|
176
176
|
function e3(e4, t3) {
|
|
177
177
|
if (void 0 === t3 && (t3 = {}), this.requestMessageHandlers = /* @__PURE__ */ new Map(), this.responseMessageHandlers = /* @__PURE__ */ new Map(), !e4) throw new Error((0, f.getErrorMessage)(d.ERROR_MESSAGES.common.channelIdRequired));
|
|
178
178
|
this.config = new c.Config(), this.config.replace(n(n({}, t3), { channelId: e4 })), this.logger = new f.Logger(this.config), this.postMessage = new l.PostMessage(this.logger, this.config), this.handleIncomingMessage = this.handleIncomingMessage.bind(this), this.send = this.send.bind(this), this.on = this.on.bind(this), this.unregisterEvent = this.unregisterEvent.bind(this), window ? window.addEventListener("message", this.handleIncomingMessage) : this.logger.debug((0, f.getErrorMessage)(d.ERROR_MESSAGES.common.windowNotFound));
|
|
179
179
|
}
|
|
180
180
|
return e3.prototype.handleIncomingMessage = function(e4) {
|
|
181
|
-
return s(this, void 0, void 0, function() {
|
|
181
|
+
return s(this, void 0, void 0, (function() {
|
|
182
182
|
var t3, r2, n2, o2, i2, s2, c2, l2, h2, g2, v2, E, y = this;
|
|
183
|
-
return u(this, function(u2) {
|
|
183
|
+
return u(this, (function(u2) {
|
|
184
184
|
if (t3 = e4.data, r2 = t3.type, n2 = t3.channel, o2 = t3.payload, i2 = t3.eventManager, s2 = t3.metadata, c2 = t3.error, i2 !== d.EVENT_MANAGER_NAME || n2 !== this.config.get("channelId")) return [2];
|
|
185
185
|
switch (l2 = s2.hash, h2 = s2.nature) {
|
|
186
186
|
case p.EditorPostMessageNature.REQUEST:
|
|
187
|
-
return this.logger.debug("REQUEST received", e4.data), this.config.get("targetWindow").closed && this.logger.error((0, f.getErrorMessage)(d.ERROR_MESSAGES.common.windowClosed)), this.postMessage.sendAck({ type: r2, hash: l2 }), this.requestMessageHandlers.has(r2) ? (g2 = this.requestMessageHandlers.get(r2).handler, v2 = { data: o2 }, [2, a.ZalgoPromise.all([a.ZalgoPromise.try(function() {
|
|
187
|
+
return this.logger.debug("REQUEST received", e4.data), this.config.get("targetWindow").closed && this.logger.error((0, f.getErrorMessage)(d.ERROR_MESSAGES.common.windowClosed)), this.postMessage.sendAck({ type: r2, hash: l2 }), this.requestMessageHandlers.has(r2) ? (g2 = this.requestMessageHandlers.get(r2).handler, v2 = { data: o2 }, [2, a.ZalgoPromise.all([a.ZalgoPromise.try((function() {
|
|
188
188
|
return g2(v2);
|
|
189
|
-
}).then(function(e5) {
|
|
189
|
+
})).then((function(e5) {
|
|
190
190
|
y.postMessage.sendResponse({ type: r2, hash: l2, payload: e5, error: void 0 });
|
|
191
|
-
}).catch(function(e5) {
|
|
191
|
+
})).catch((function(e5) {
|
|
192
192
|
y.logger.error((0, f.getErrorMessage)(d.ERROR_MESSAGES.receiveEvent.codeReturnedError), e5);
|
|
193
|
-
})])]) : (this.logger.debug((0, f.getErrorMessage)(d.ERROR_MESSAGES.receiveEvent.noRequestListenerFound(r2))), this.postMessage.sendResponse({ type: r2, hash: l2, payload: void 0, error: { code: d.ERROR_CODES.receiveEvent.noRequestListenerFound, message: (0, f.getErrorMessage)(d.ERROR_MESSAGES.receiveEvent.noRequestListenerFound(r2)) } }), [2]);
|
|
193
|
+
}))])]) : (this.logger.debug((0, f.getErrorMessage)(d.ERROR_MESSAGES.receiveEvent.noRequestListenerFound(r2))), this.postMessage.sendResponse({ type: r2, hash: l2, payload: void 0, error: { code: d.ERROR_CODES.receiveEvent.noRequestListenerFound, message: (0, f.getErrorMessage)(d.ERROR_MESSAGES.receiveEvent.noRequestListenerFound(r2)) } }), [2]);
|
|
194
194
|
case p.EditorPostMessageNature.RESPONSE:
|
|
195
195
|
if (this.logger.debug("RESPONSE received", e4.data), !this.responseMessageHandlers.has(l2)) return this.logger.error((0, f.getErrorMessage)(d.ERROR_MESSAGES.receiveEvent.noResponseListenerFound(l2))), [2];
|
|
196
196
|
E = this.responseMessageHandlers.get(l2), c2 ? E.promise.reject(c2) : E.promise.resolve(o2);
|
|
@@ -203,21 +203,21 @@ var require_dist = __commonJS({
|
|
|
203
203
|
this.logger.error((0, f.getErrorMessage)(d.ERROR_MESSAGES.receiveEvent.unknownNature(h2)), e4.data);
|
|
204
204
|
}
|
|
205
205
|
return [2];
|
|
206
|
-
});
|
|
207
|
-
});
|
|
206
|
+
}));
|
|
207
|
+
}));
|
|
208
208
|
}, e3.prototype.send = function(e4, t3) {
|
|
209
|
-
return s(this, void 0, void 0, function() {
|
|
209
|
+
return s(this, void 0, void 0, (function() {
|
|
210
210
|
var r2, n2, o2, i2, s2, c2 = this;
|
|
211
|
-
return u(this, function(u2) {
|
|
212
|
-
return r2 = new a.ZalgoPromise(), n2 = (0, g.uniqueId)(e4), o2 = { type: e4, promise: r2, hasCancelled: false, hasReceivedAck: false }, this.responseMessageHandlers.set(n2, o2), i2 = 1e3, s2 = (0, h.safeInterval)(function() {
|
|
211
|
+
return u(this, (function(u2) {
|
|
212
|
+
return r2 = new a.ZalgoPromise(), n2 = (0, g.uniqueId)(e4), o2 = { type: e4, promise: r2, hasCancelled: false, hasReceivedAck: false }, this.responseMessageHandlers.set(n2, o2), i2 = 1e3, s2 = (0, h.safeInterval)((function() {
|
|
213
213
|
return c2.config.get("targetWindow").closed ? r2.reject(new Error((0, f.getErrorMessage)(d.ERROR_MESSAGES.common.windowClosed))) : (i2 = Math.max(i2 - d.RESPONSE_CYCLE, 0), !o2.hasReceivedAck && i2 <= 0 ? r2.reject((0, f.getErrorMessage)(d.ERROR_MESSAGES.sendEvent.noAckReceived)) : void 0);
|
|
214
|
-
}, d.RESPONSE_CYCLE), r2.finally(function() {
|
|
214
|
+
}), d.RESPONSE_CYCLE), r2.finally((function() {
|
|
215
215
|
c2.responseMessageHandlers.delete(n2), s2.cancel();
|
|
216
|
-
}).catch(function(e5) {
|
|
216
|
+
})).catch((function(e5) {
|
|
217
217
|
c2.logger.debug((0, f.getErrorMessage)(d.ERROR_MESSAGES.sendEvent.receiverReturnedError), e5);
|
|
218
|
-
}), this.postMessage.sendRequest({ type: e4, hash: n2, error: void 0, payload: t3 }), [2, r2];
|
|
219
|
-
});
|
|
220
|
-
});
|
|
218
|
+
})), this.postMessage.sendRequest({ type: e4, hash: n2, error: void 0, payload: t3 }), [2, r2];
|
|
219
|
+
}));
|
|
220
|
+
}));
|
|
221
221
|
}, e3.prototype.on = function(e4, t3) {
|
|
222
222
|
var r2 = this;
|
|
223
223
|
this.requestMessageHandlers.has(e4) && this.logger.error((0, f.getErrorMessage)(d.ERROR_MESSAGES.registerEvent.eventAlreadyRegistered(e4)));
|
|
@@ -232,7 +232,7 @@ var require_dist = __commonJS({
|
|
|
232
232
|
}, e3.prototype.destroy = function(e4) {
|
|
233
233
|
this.requestMessageHandlers.clear(), this.responseMessageHandlers.clear(), (null == e4 ? void 0 : e4.soft) || window.removeEventListener("message", this.handleIncomingMessage);
|
|
234
234
|
}, e3;
|
|
235
|
-
}();
|
|
235
|
+
})();
|
|
236
236
|
t2.EventManager = v, i(r(574), t2);
|
|
237
237
|
}, 897: function(e2, t2, r) {
|
|
238
238
|
"use strict";
|
|
@@ -243,7 +243,7 @@ var require_dist = __commonJS({
|
|
|
243
243
|
}, n.apply(this, arguments);
|
|
244
244
|
};
|
|
245
245
|
Object.defineProperty(t2, "__esModule", { value: true }), t2.PostMessage = void 0;
|
|
246
|
-
var o = r(574), i = function() {
|
|
246
|
+
var o = r(574), i = (function() {
|
|
247
247
|
function e3(e4, t3) {
|
|
248
248
|
this.logger = e4, this.sendResponse = this.sendResponse.bind(this), this.sendRequest = this.sendRequest.bind(this), this.sendAck = this.sendAck.bind(this), this.getMessage = this.getMessage.bind(this), this.config = t3.getAll();
|
|
249
249
|
}
|
|
@@ -266,7 +266,7 @@ var require_dist = __commonJS({
|
|
|
266
266
|
var t3 = e4.nature, r2 = e4.hash, n2 = e4.payload, o2 = e4.type, i2 = e4.error;
|
|
267
267
|
return { eventManager: "contentstack-adv-post-message", metadata: { hash: r2, nature: t3 }, channel: this.config.channelId, error: i2, payload: n2, type: o2 };
|
|
268
268
|
}, e3;
|
|
269
|
-
}();
|
|
269
|
+
})();
|
|
270
270
|
t2.PostMessage = i;
|
|
271
271
|
}, 255: (e2, t2) => {
|
|
272
272
|
"use strict";
|
|
@@ -291,9 +291,9 @@ var require_dist = __commonJS({
|
|
|
291
291
|
}, 145: (e2, t2) => {
|
|
292
292
|
"use strict";
|
|
293
293
|
var r;
|
|
294
|
-
Object.defineProperty(t2, "__esModule", { value: true }), t2.EditorPostMessageNature = void 0, function(e3) {
|
|
294
|
+
Object.defineProperty(t2, "__esModule", { value: true }), t2.EditorPostMessageNature = void 0, (function(e3) {
|
|
295
295
|
e3.ACK = "ACK", e3.RESPONSE = "RESPONSE", e3.REQUEST = "REQUEST";
|
|
296
|
-
}(r || (t2.EditorPostMessageNature = r = {}));
|
|
296
|
+
})(r || (t2.EditorPostMessageNature = r = {}));
|
|
297
297
|
}, 628: function(e2, t2, r) {
|
|
298
298
|
"use strict";
|
|
299
299
|
var n = this && this.__spreadArray || function(e3, t3, r2) {
|
|
@@ -301,7 +301,7 @@ var require_dist = __commonJS({
|
|
|
301
301
|
return e3.concat(n2 || Array.prototype.slice.call(t3));
|
|
302
302
|
};
|
|
303
303
|
Object.defineProperty(t2, "__esModule", { value: true }), t2.getErrorMessage = t2.Logger = void 0;
|
|
304
|
-
var o = r(450), i = function() {
|
|
304
|
+
var o = r(450), i = (function() {
|
|
305
305
|
function e3(e4) {
|
|
306
306
|
this.config = e4, this.prefix = o.EVENT_MANAGER_NAME, this.log = this.log.bind(this), this.info = this.info.bind(this), this.debug = this.debug.bind(this), this.error = this.error.bind(this);
|
|
307
307
|
}
|
|
@@ -320,7 +320,7 @@ var require_dist = __commonJS({
|
|
|
320
320
|
}, e3.prototype.getDebugOptions = function() {
|
|
321
321
|
return { targetOrigin: this.config.get("targetOrigin"), targetWindow: this.config.get("targetWindow") };
|
|
322
322
|
}, e3;
|
|
323
|
-
}();
|
|
323
|
+
})();
|
|
324
324
|
t2.Logger = i, t2.getErrorMessage = function(e3) {
|
|
325
325
|
return o.EVENT_MANAGER_NAME + ": " + e3;
|
|
326
326
|
};
|
|
@@ -328,11 +328,11 @@ var require_dist = __commonJS({
|
|
|
328
328
|
"use strict";
|
|
329
329
|
Object.defineProperty(t2, "__esModule", { value: true }), t2.safeInterval = void 0, t2.safeInterval = function(e3, t3) {
|
|
330
330
|
var r;
|
|
331
|
-
return function n() {
|
|
332
|
-
r = setTimeout(function() {
|
|
331
|
+
return (function n() {
|
|
332
|
+
r = setTimeout((function() {
|
|
333
333
|
e3(), n();
|
|
334
|
-
}, t3);
|
|
335
|
-
}(), { cancel: function() {
|
|
334
|
+
}), t3);
|
|
335
|
+
})(), { cancel: function() {
|
|
336
336
|
clearTimeout(r);
|
|
337
337
|
} };
|
|
338
338
|
};
|
|
@@ -401,14 +401,14 @@ var require_dist = __commonJS({
|
|
|
401
401
|
e3 = new Uint8Array(t3.length);
|
|
402
402
|
for (let r2 = 0; r2 < t3.length; ++r2) e3[r2] = t3.charCodeAt(r2);
|
|
403
403
|
}
|
|
404
|
-
return function(e4) {
|
|
404
|
+
return (function(e4) {
|
|
405
405
|
const t3 = [], r2 = 32 * e4.length, n2 = "0123456789abcdef";
|
|
406
406
|
for (let o2 = 0; o2 < r2; o2 += 8) {
|
|
407
407
|
const r3 = e4[o2 >> 5] >>> o2 % 32 & 255, i2 = parseInt(n2.charAt(r3 >>> 4 & 15) + n2.charAt(15 & r3), 16);
|
|
408
408
|
t3.push(i2);
|
|
409
409
|
}
|
|
410
410
|
return t3;
|
|
411
|
-
}(function(e4, t3) {
|
|
411
|
+
})((function(e4, t3) {
|
|
412
412
|
e4[t3 >> 5] |= 128 << t3 % 32, e4[r(t3) - 1] = t3;
|
|
413
413
|
let o2 = 1732584193, c = -271733879, d = -1732584194, l = 271733878;
|
|
414
414
|
for (let t4 = 0; t4 < e4.length; t4 += 16) {
|
|
@@ -416,12 +416,12 @@ var require_dist = __commonJS({
|
|
|
416
416
|
o2 = i(o2, c, d, l, e4[t4], 7, -680876936), l = i(l, o2, c, d, e4[t4 + 1], 12, -389564586), d = i(d, l, o2, c, e4[t4 + 2], 17, 606105819), c = i(c, d, l, o2, e4[t4 + 3], 22, -1044525330), o2 = i(o2, c, d, l, e4[t4 + 4], 7, -176418897), l = i(l, o2, c, d, e4[t4 + 5], 12, 1200080426), d = i(d, l, o2, c, e4[t4 + 6], 17, -1473231341), c = i(c, d, l, o2, e4[t4 + 7], 22, -45705983), o2 = i(o2, c, d, l, e4[t4 + 8], 7, 1770035416), l = i(l, o2, c, d, e4[t4 + 9], 12, -1958414417), d = i(d, l, o2, c, e4[t4 + 10], 17, -42063), c = i(c, d, l, o2, e4[t4 + 11], 22, -1990404162), o2 = i(o2, c, d, l, e4[t4 + 12], 7, 1804603682), l = i(l, o2, c, d, e4[t4 + 13], 12, -40341101), d = i(d, l, o2, c, e4[t4 + 14], 17, -1502002290), c = i(c, d, l, o2, e4[t4 + 15], 22, 1236535329), o2 = s(o2, c, d, l, e4[t4 + 1], 5, -165796510), l = s(l, o2, c, d, e4[t4 + 6], 9, -1069501632), d = s(d, l, o2, c, e4[t4 + 11], 14, 643717713), c = s(c, d, l, o2, e4[t4], 20, -373897302), o2 = s(o2, c, d, l, e4[t4 + 5], 5, -701558691), l = s(l, o2, c, d, e4[t4 + 10], 9, 38016083), d = s(d, l, o2, c, e4[t4 + 15], 14, -660478335), c = s(c, d, l, o2, e4[t4 + 4], 20, -405537848), o2 = s(o2, c, d, l, e4[t4 + 9], 5, 568446438), l = s(l, o2, c, d, e4[t4 + 14], 9, -1019803690), d = s(d, l, o2, c, e4[t4 + 3], 14, -187363961), c = s(c, d, l, o2, e4[t4 + 8], 20, 1163531501), o2 = s(o2, c, d, l, e4[t4 + 13], 5, -1444681467), l = s(l, o2, c, d, e4[t4 + 2], 9, -51403784), d = s(d, l, o2, c, e4[t4 + 7], 14, 1735328473), c = s(c, d, l, o2, e4[t4 + 12], 20, -1926607734), o2 = u(o2, c, d, l, e4[t4 + 5], 4, -378558), l = u(l, o2, c, d, e4[t4 + 8], 11, -2022574463), d = u(d, l, o2, c, e4[t4 + 11], 16, 1839030562), c = u(c, d, l, o2, e4[t4 + 14], 23, -35309556), o2 = u(o2, c, d, l, e4[t4 + 1], 4, -1530992060), l = u(l, o2, c, d, e4[t4 + 4], 11, 1272893353), d = u(d, l, o2, c, e4[t4 + 7], 16, -155497632), c = u(c, d, l, o2, e4[t4 + 10], 23, -1094730640), o2 = u(o2, c, d, l, e4[t4 + 13], 4, 681279174), l = u(l, o2, c, d, e4[t4], 11, -358537222), d = u(d, l, o2, c, e4[t4 + 3], 16, -722521979), c = u(c, d, l, o2, e4[t4 + 6], 23, 76029189), o2 = u(o2, c, d, l, e4[t4 + 9], 4, -640364487), l = u(l, o2, c, d, e4[t4 + 12], 11, -421815835), d = u(d, l, o2, c, e4[t4 + 15], 16, 530742520), c = u(c, d, l, o2, e4[t4 + 2], 23, -995338651), o2 = a(o2, c, d, l, e4[t4], 6, -198630844), l = a(l, o2, c, d, e4[t4 + 7], 10, 1126891415), d = a(d, l, o2, c, e4[t4 + 14], 15, -1416354905), c = a(c, d, l, o2, e4[t4 + 5], 21, -57434055), o2 = a(o2, c, d, l, e4[t4 + 12], 6, 1700485571), l = a(l, o2, c, d, e4[t4 + 3], 10, -1894986606), d = a(d, l, o2, c, e4[t4 + 10], 15, -1051523), c = a(c, d, l, o2, e4[t4 + 1], 21, -2054922799), o2 = a(o2, c, d, l, e4[t4 + 8], 6, 1873313359), l = a(l, o2, c, d, e4[t4 + 15], 10, -30611744), d = a(d, l, o2, c, e4[t4 + 6], 15, -1560198380), c = a(c, d, l, o2, e4[t4 + 13], 21, 1309151649), o2 = a(o2, c, d, l, e4[t4 + 4], 6, -145523070), l = a(l, o2, c, d, e4[t4 + 11], 10, -1120210379), d = a(d, l, o2, c, e4[t4 + 2], 15, 718787259), c = a(c, d, l, o2, e4[t4 + 9], 21, -343485551), o2 = n(o2, r2), c = n(c, f), d = n(d, h), l = n(l, g);
|
|
417
417
|
}
|
|
418
418
|
return [o2, c, d, l];
|
|
419
|
-
}(function(e4) {
|
|
419
|
+
})((function(e4) {
|
|
420
420
|
if (0 === e4.length) return [];
|
|
421
421
|
const t3 = 8 * e4.length, n2 = new Uint32Array(r(t3));
|
|
422
422
|
for (let r2 = 0; r2 < t3; r2 += 8) n2[r2 >> 5] |= (255 & e4[r2 / 8]) << r2 % 32;
|
|
423
423
|
return n2;
|
|
424
|
-
}(e3), 8 * e3.length));
|
|
424
|
+
})(e3), 8 * e3.length));
|
|
425
425
|
};
|
|
426
426
|
}, 140: (e2, t2) => {
|
|
427
427
|
"use strict";
|
|
@@ -549,12 +549,12 @@ var require_dist = __commonJS({
|
|
|
549
549
|
Object.defineProperty(t2, "__esModule", { value: true }), t2.URL = t2.DNS = void 0, t2.default = function(e3, t3, r2) {
|
|
550
550
|
function n2(e4, n3, s2, u2) {
|
|
551
551
|
var a;
|
|
552
|
-
if ("string" == typeof e4 && (e4 = function(e5) {
|
|
552
|
+
if ("string" == typeof e4 && (e4 = (function(e5) {
|
|
553
553
|
e5 = unescape(encodeURIComponent(e5));
|
|
554
554
|
const t4 = [];
|
|
555
555
|
for (let r3 = 0; r3 < e5.length; ++r3) t4.push(e5.charCodeAt(r3));
|
|
556
556
|
return t4;
|
|
557
|
-
}(e4)), "string" == typeof n3 && (n3 = (0, i.default)(n3)), 16 !== (null === (a = n3) || void 0 === a ? void 0 : a.length)) throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");
|
|
557
|
+
})(e4)), "string" == typeof n3 && (n3 = (0, i.default)(n3)), 16 !== (null === (a = n3) || void 0 === a ? void 0 : a.length)) throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");
|
|
558
558
|
let c = new Uint8Array(16 + e4.length);
|
|
559
559
|
if (c.set(n3), c.set(e4, n3.length), c = r2(c), c[6] = 15 & c[6] | t3, c[8] = 63 & c[8] | 128, s2) {
|
|
560
560
|
u2 = u2 || 0;
|
|
@@ -616,7 +616,7 @@ var require_dist = __commonJS({
|
|
|
616
616
|
return parseInt(e3.slice(14, 15), 16);
|
|
617
617
|
};
|
|
618
618
|
}, 994: function(e2) {
|
|
619
|
-
"undefined" != typeof self && self, e2.exports = function(e3) {
|
|
619
|
+
"undefined" != typeof self && self, e2.exports = (function(e3) {
|
|
620
620
|
var t2 = {};
|
|
621
621
|
function r(n) {
|
|
622
622
|
if (t2[n]) return t2[n].exports;
|
|
@@ -645,7 +645,7 @@ var require_dist = __commonJS({
|
|
|
645
645
|
}, r.o = function(e4, t3) {
|
|
646
646
|
return {}.hasOwnProperty.call(e4, t3);
|
|
647
647
|
}, r.p = "", r(r.s = 0);
|
|
648
|
-
}([function(e3, t2, r) {
|
|
648
|
+
})([function(e3, t2, r) {
|
|
649
649
|
"use strict";
|
|
650
650
|
function n(e4) {
|
|
651
651
|
try {
|
|
@@ -664,9 +664,9 @@ var require_dist = __commonJS({
|
|
|
664
664
|
}
|
|
665
665
|
return false;
|
|
666
666
|
}
|
|
667
|
-
r.r(t2), r.d(t2, "ZalgoPromise", function() {
|
|
667
|
+
r.r(t2), r.d(t2, "ZalgoPromise", (function() {
|
|
668
668
|
return l;
|
|
669
|
-
});
|
|
669
|
+
}));
|
|
670
670
|
var o, i = [], s = [], u = 0;
|
|
671
671
|
function a() {
|
|
672
672
|
if (!u && o) {
|
|
@@ -680,18 +680,18 @@ var require_dist = __commonJS({
|
|
|
680
680
|
function d() {
|
|
681
681
|
u -= 1, a();
|
|
682
682
|
}
|
|
683
|
-
var l = function() {
|
|
683
|
+
var l = (function() {
|
|
684
684
|
function e4(e5) {
|
|
685
685
|
var t4 = this;
|
|
686
686
|
if (this.resolved = void 0, this.rejected = void 0, this.errorHandled = void 0, this.value = void 0, this.error = void 0, this.handlers = void 0, this.dispatching = void 0, this.stack = void 0, this.resolved = false, this.rejected = false, this.errorHandled = false, this.handlers = [], e5) {
|
|
687
687
|
var r2, n2, o2 = false, i2 = false, s2 = false;
|
|
688
688
|
c();
|
|
689
689
|
try {
|
|
690
|
-
e5(function(e6) {
|
|
690
|
+
e5((function(e6) {
|
|
691
691
|
s2 ? t4.resolve(e6) : (o2 = true, r2 = e6);
|
|
692
|
-
}, function(e6) {
|
|
692
|
+
}), (function(e6) {
|
|
693
693
|
s2 ? t4.reject(e6) : (i2 = true, n2 = e6);
|
|
694
|
-
});
|
|
694
|
+
}));
|
|
695
695
|
} catch (e6) {
|
|
696
696
|
return d(), void this.reject(e6);
|
|
697
697
|
}
|
|
@@ -711,16 +711,16 @@ var require_dist = __commonJS({
|
|
|
711
711
|
var r2 = e5 && "function" == typeof e5.toString ? e5.toString() : {}.toString.call(e5);
|
|
712
712
|
e5 = new Error("Expected reject to be called with Error, got " + r2);
|
|
713
713
|
}
|
|
714
|
-
return this.rejected = true, this.error = e5, this.errorHandled || setTimeout(function() {
|
|
715
|
-
t4.errorHandled || function(e6, t5) {
|
|
714
|
+
return this.rejected = true, this.error = e5, this.errorHandled || setTimeout((function() {
|
|
715
|
+
t4.errorHandled || (function(e6, t5) {
|
|
716
716
|
if (-1 === i.indexOf(e6)) {
|
|
717
|
-
i.push(e6), setTimeout(function() {
|
|
717
|
+
i.push(e6), setTimeout((function() {
|
|
718
718
|
throw e6;
|
|
719
|
-
}, 1);
|
|
719
|
+
}), 1);
|
|
720
720
|
for (var r3 = 0; r3 < s.length; r3++) s[r3](e6, t5);
|
|
721
721
|
}
|
|
722
|
-
}(e5, t4);
|
|
723
|
-
}, 1), this.dispatch(), this;
|
|
722
|
+
})(e5, t4);
|
|
723
|
+
}), 1), this.dispatch(), this;
|
|
724
724
|
}, t3.asyncReject = function(e5) {
|
|
725
725
|
return this.errorHandled = true, this.reject(e5), this;
|
|
726
726
|
}, t3.dispatch = function() {
|
|
@@ -728,11 +728,11 @@ var require_dist = __commonJS({
|
|
|
728
728
|
if (!this.dispatching && (t4 || r2)) {
|
|
729
729
|
this.dispatching = true, c();
|
|
730
730
|
for (var i2 = function(e5, t5) {
|
|
731
|
-
return e5.then(function(e6) {
|
|
731
|
+
return e5.then((function(e6) {
|
|
732
732
|
t5.resolve(e6);
|
|
733
|
-
}, function(e6) {
|
|
733
|
+
}), (function(e6) {
|
|
734
734
|
t5.reject(e6);
|
|
735
|
-
});
|
|
735
|
+
}));
|
|
736
736
|
}, s2 = 0; s2 < o2.length; s2++) {
|
|
737
737
|
var u2 = o2[s2], a2 = u2.onSuccess, l2 = u2.onError, f = u2.promise, h = void 0;
|
|
738
738
|
if (t4) try {
|
|
@@ -769,33 +769,33 @@ var require_dist = __commonJS({
|
|
|
769
769
|
return this.then(void 0, e5);
|
|
770
770
|
}, t3.finally = function(t4) {
|
|
771
771
|
if (t4 && "function" != typeof t4 && !t4.call) throw new Error("Promise.finally expected a function");
|
|
772
|
-
return this.then(function(r2) {
|
|
773
|
-
return e4.try(t4).then(function() {
|
|
772
|
+
return this.then((function(r2) {
|
|
773
|
+
return e4.try(t4).then((function() {
|
|
774
774
|
return r2;
|
|
775
|
-
});
|
|
776
|
-
}, function(r2) {
|
|
777
|
-
return e4.try(t4).then(function() {
|
|
775
|
+
}));
|
|
776
|
+
}), (function(r2) {
|
|
777
|
+
return e4.try(t4).then((function() {
|
|
778
778
|
throw r2;
|
|
779
|
-
});
|
|
780
|
-
});
|
|
779
|
+
}));
|
|
780
|
+
}));
|
|
781
781
|
}, t3.timeout = function(e5, t4) {
|
|
782
782
|
var r2 = this;
|
|
783
783
|
if (this.resolved || this.rejected) return this;
|
|
784
|
-
var n2 = setTimeout(function() {
|
|
784
|
+
var n2 = setTimeout((function() {
|
|
785
785
|
r2.resolved || r2.rejected || r2.reject(t4 || new Error("Promise timed out after " + e5 + "ms"));
|
|
786
|
-
}, e5);
|
|
787
|
-
return this.then(function(e6) {
|
|
786
|
+
}), e5);
|
|
787
|
+
return this.then((function(e6) {
|
|
788
788
|
return clearTimeout(n2), e6;
|
|
789
|
-
});
|
|
789
|
+
}));
|
|
790
790
|
}, t3.toPromise = function() {
|
|
791
791
|
if ("undefined" == typeof Promise) throw new TypeError("Could not find Promise");
|
|
792
792
|
return Promise.resolve(this);
|
|
793
793
|
}, t3.lazy = function() {
|
|
794
794
|
return this.errorHandled = true, this;
|
|
795
795
|
}, e4.resolve = function(t4) {
|
|
796
|
-
return t4 instanceof e4 ? t4 : n(t4) ? new e4(function(e5, r2) {
|
|
796
|
+
return t4 instanceof e4 ? t4 : n(t4) ? new e4((function(e5, r2) {
|
|
797
797
|
return t4.then(e5, r2);
|
|
798
|
-
}) : new e4().resolve(t4);
|
|
798
|
+
})) : new e4().resolve(t4);
|
|
799
799
|
}, e4.reject = function(t4) {
|
|
800
800
|
return new e4().reject(t4);
|
|
801
801
|
}, e4.asyncReject = function(t4) {
|
|
@@ -804,11 +804,11 @@ var require_dist = __commonJS({
|
|
|
804
804
|
var r2 = new e4(), o2 = t4.length, i2 = [].slice();
|
|
805
805
|
if (!o2) return r2.resolve(i2), r2;
|
|
806
806
|
for (var s2 = function(e5, t5, n2) {
|
|
807
|
-
return t5.then(function(t6) {
|
|
807
|
+
return t5.then((function(t6) {
|
|
808
808
|
i2[e5] = t6, 0 == (o2 -= 1) && r2.resolve(i2);
|
|
809
|
-
}, function(e6) {
|
|
809
|
+
}), (function(e6) {
|
|
810
810
|
n2.reject(e6);
|
|
811
|
-
});
|
|
811
|
+
}));
|
|
812
812
|
}, u2 = 0; u2 < t4.length; u2++) {
|
|
813
813
|
var a2 = t4[u2];
|
|
814
814
|
if (a2 instanceof e4) {
|
|
@@ -827,23 +827,23 @@ var require_dist = __commonJS({
|
|
|
827
827
|
var r2 = {}, o2 = [], i2 = function(e5) {
|
|
828
828
|
if (t4.hasOwnProperty(e5)) {
|
|
829
829
|
var i3 = t4[e5];
|
|
830
|
-
n(i3) ? o2.push(i3.then(function(t5) {
|
|
830
|
+
n(i3) ? o2.push(i3.then((function(t5) {
|
|
831
831
|
r2[e5] = t5;
|
|
832
|
-
})) : r2[e5] = i3;
|
|
832
|
+
}))) : r2[e5] = i3;
|
|
833
833
|
}
|
|
834
834
|
};
|
|
835
835
|
for (var s2 in t4) i2(s2);
|
|
836
|
-
return e4.all(o2).then(function() {
|
|
836
|
+
return e4.all(o2).then((function() {
|
|
837
837
|
return r2;
|
|
838
|
-
});
|
|
838
|
+
}));
|
|
839
839
|
}, e4.map = function(t4, r2) {
|
|
840
840
|
return e4.all(t4.map(r2));
|
|
841
841
|
}, e4.onPossiblyUnhandledException = function(e5) {
|
|
842
|
-
return function(e6) {
|
|
842
|
+
return (function(e6) {
|
|
843
843
|
return s.push(e6), { cancel: function() {
|
|
844
844
|
s.splice(s.indexOf(e6), 1);
|
|
845
845
|
} };
|
|
846
|
-
}(e5);
|
|
846
|
+
})(e5);
|
|
847
847
|
}, e4.try = function(t4, r2, n2) {
|
|
848
848
|
if (t4 && "function" != typeof t4 && !t4.call) throw new Error("Promise.try expected a function");
|
|
849
849
|
var o2;
|
|
@@ -855,31 +855,31 @@ var require_dist = __commonJS({
|
|
|
855
855
|
}
|
|
856
856
|
return d(), e4.resolve(o2);
|
|
857
857
|
}, e4.delay = function(t4) {
|
|
858
|
-
return new e4(function(e5) {
|
|
858
|
+
return new e4((function(e5) {
|
|
859
859
|
setTimeout(e5, t4);
|
|
860
|
-
});
|
|
860
|
+
}));
|
|
861
861
|
}, e4.isPromise = function(t4) {
|
|
862
862
|
return !!(t4 && t4 instanceof e4) || n(t4);
|
|
863
863
|
}, e4.flush = function() {
|
|
864
864
|
return t4 = o = o || new e4(), a(), t4;
|
|
865
865
|
var t4;
|
|
866
866
|
}, e4;
|
|
867
|
-
}();
|
|
867
|
+
})();
|
|
868
868
|
}]);
|
|
869
869
|
}, 834: (e2, t2, r) => {
|
|
870
870
|
e2.exports = r(994);
|
|
871
|
-
} }, t = {}, function r(n) {
|
|
871
|
+
} }, t = {}, (function r(n) {
|
|
872
872
|
var o = t[n];
|
|
873
873
|
if (void 0 !== o) return o.exports;
|
|
874
874
|
var i = t[n] = { exports: {} };
|
|
875
875
|
return e[n].call(i.exports, i, i.exports, r), i.exports;
|
|
876
|
-
}(156);
|
|
876
|
+
})(156);
|
|
877
877
|
var e, t;
|
|
878
|
-
});
|
|
878
|
+
}));
|
|
879
879
|
}
|
|
880
880
|
});
|
|
881
881
|
|
|
882
882
|
export {
|
|
883
883
|
require_dist
|
|
884
884
|
};
|
|
885
|
-
//# sourceMappingURL=chunk-
|
|
885
|
+
//# sourceMappingURL=chunk-JYE4G3PN.js.map
|