@formo/analytics 1.19.8 → 1.19.9
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/cjs/src/FormoAnalytics.d.ts +5 -0
- package/dist/cjs/src/FormoAnalytics.js +77 -32
- package/dist/cjs/src/constants/base.d.ts +1 -0
- package/dist/cjs/src/constants/base.js +2 -1
- package/dist/esm/src/FormoAnalytics.d.ts +5 -0
- package/dist/esm/src/FormoAnalytics.js +78 -33
- package/dist/esm/src/constants/base.d.ts +1 -0
- package/dist/esm/src/constants/base.js +1 -0
- package/dist/index.umd.min.js +1 -1
- package/package.json +1 -1
|
@@ -269,6 +269,11 @@ export declare class FormoAnalytics implements IFormoAnalytics {
|
|
|
269
269
|
* @returns The checksummed address or undefined if invalid
|
|
270
270
|
*/
|
|
271
271
|
private validateAndChecksumAddress;
|
|
272
|
+
/**
|
|
273
|
+
* Helper method to clear the active provider state
|
|
274
|
+
* Centralizes provider clearing logic for consistency
|
|
275
|
+
*/
|
|
276
|
+
private clearActiveProvider;
|
|
272
277
|
/**
|
|
273
278
|
* Helper method to safely add a provider detail to _providers array, ensuring no duplicates
|
|
274
279
|
* @param detail The provider detail to add
|
|
@@ -219,6 +219,7 @@ var FormoAnalytics = /** @class */ (function () {
|
|
|
219
219
|
(0, lib_1.cookie)().remove(constants_1.LOCAL_ANONYMOUS_ID_KEY);
|
|
220
220
|
(0, lib_1.cookie)().remove(constants_1.SESSION_USER_ID_KEY);
|
|
221
221
|
(0, lib_1.cookie)().remove(constants_1.SESSION_WALLET_DETECTED_KEY);
|
|
222
|
+
(0, lib_1.cookie)().remove(constants_1.SESSION_WALLET_IDENTIFIED_KEY);
|
|
222
223
|
};
|
|
223
224
|
/**
|
|
224
225
|
* Emits a connect wallet event.
|
|
@@ -295,7 +296,7 @@ var FormoAnalytics = /** @class */ (function () {
|
|
|
295
296
|
_a.sent();
|
|
296
297
|
this.currentAddress = undefined;
|
|
297
298
|
this.currentChainId = undefined;
|
|
298
|
-
this.
|
|
299
|
+
this.clearActiveProvider();
|
|
299
300
|
lib_1.logger.info("Wallet disconnected: Cleared currentAddress, currentChainId, and provider");
|
|
300
301
|
return [2 /*return*/];
|
|
301
302
|
}
|
|
@@ -406,51 +407,58 @@ var FormoAnalytics = /** @class */ (function () {
|
|
|
406
407
|
*/
|
|
407
408
|
FormoAnalytics.prototype.identify = function (params, properties, context, callback) {
|
|
408
409
|
return __awaiter(this, void 0, void 0, function () {
|
|
409
|
-
var _i, _a, providerDetail, provider, address_2, err_1, userId, address, providerName, rdns, validAddress, e_1;
|
|
410
|
+
var _i, _a, providerDetail, provider, address_2, validAddress_1, err_1, userId, address, providerName, rdns, validAddress, e_1;
|
|
410
411
|
var _b;
|
|
411
412
|
return __generator(this, function (_c) {
|
|
412
413
|
switch (_c.label) {
|
|
413
414
|
case 0:
|
|
414
|
-
_c.trys.push([0,
|
|
415
|
-
if (!!params) return [3 /*break*/,
|
|
415
|
+
_c.trys.push([0, 12, , 13]);
|
|
416
|
+
if (!!params) return [3 /*break*/, 10];
|
|
416
417
|
// If no params provided, auto-identify
|
|
417
418
|
lib_1.logger.info("Auto-identifying with providers:", this._providers.map(function (p) { return p.info.name; }));
|
|
418
419
|
_i = 0, _a = this._providers;
|
|
419
420
|
_c.label = 1;
|
|
420
421
|
case 1:
|
|
421
|
-
if (!(_i < _a.length)) return [3 /*break*/,
|
|
422
|
+
if (!(_i < _a.length)) return [3 /*break*/, 9];
|
|
422
423
|
providerDetail = _a[_i];
|
|
423
424
|
provider = providerDetail.provider;
|
|
424
425
|
if (!provider)
|
|
425
|
-
return [3 /*break*/,
|
|
426
|
+
return [3 /*break*/, 8];
|
|
426
427
|
_c.label = 2;
|
|
427
428
|
case 2:
|
|
428
|
-
_c.trys.push([2,
|
|
429
|
+
_c.trys.push([2, 7, , 8]);
|
|
429
430
|
return [4 /*yield*/, this.getAddress(provider)];
|
|
430
431
|
case 3:
|
|
431
432
|
address_2 = _c.sent();
|
|
432
|
-
if (!address_2) return [3 /*break*/,
|
|
433
|
-
|
|
433
|
+
if (!address_2) return [3 /*break*/, 6];
|
|
434
|
+
validAddress_1 = this.validateAndChecksumAddress(address_2);
|
|
435
|
+
if (!(validAddress_1 && !this.session.isWalletIdentified(validAddress_1, providerDetail.info.rdns))) return [3 /*break*/, 5];
|
|
436
|
+
lib_1.logger.info("Auto-identifying", validAddress_1, providerDetail.info.name, providerDetail.info.rdns);
|
|
434
437
|
// NOTE: do not set this.currentAddress without explicit connect or identify
|
|
435
438
|
return [4 /*yield*/, this.identify({
|
|
436
|
-
address:
|
|
439
|
+
address: validAddress_1,
|
|
437
440
|
providerName: providerDetail.info.name,
|
|
438
441
|
rdns: providerDetail.info.rdns,
|
|
439
442
|
}, properties, context, callback)];
|
|
440
443
|
case 4:
|
|
441
444
|
// NOTE: do not set this.currentAddress without explicit connect or identify
|
|
442
445
|
_c.sent();
|
|
443
|
-
|
|
444
|
-
case 5:
|
|
445
|
-
|
|
446
|
+
return [3 /*break*/, 6];
|
|
447
|
+
case 5:
|
|
448
|
+
if (validAddress_1) {
|
|
449
|
+
lib_1.logger.info("Auto-identify: Skipping already identified wallet", validAddress_1, providerDetail.info.name, providerDetail.info.rdns);
|
|
450
|
+
}
|
|
451
|
+
_c.label = 6;
|
|
452
|
+
case 6: return [3 /*break*/, 8];
|
|
453
|
+
case 7:
|
|
446
454
|
err_1 = _c.sent();
|
|
447
455
|
lib_1.logger.error("Failed to identify provider ".concat(providerDetail.info.name, ":"), err_1);
|
|
448
|
-
return [3 /*break*/,
|
|
449
|
-
case
|
|
456
|
+
return [3 /*break*/, 8];
|
|
457
|
+
case 8:
|
|
450
458
|
_i++;
|
|
451
459
|
return [3 /*break*/, 1];
|
|
452
|
-
case
|
|
453
|
-
case
|
|
460
|
+
case 9: return [2 /*return*/];
|
|
461
|
+
case 10:
|
|
454
462
|
userId = params.userId, address = params.address, providerName = params.providerName, rdns = params.rdns;
|
|
455
463
|
lib_1.logger.info("Identify", address, userId, providerName, rdns);
|
|
456
464
|
validAddress = undefined;
|
|
@@ -468,20 +476,29 @@ var FormoAnalytics = /** @class */ (function () {
|
|
|
468
476
|
this.currentUserId = userId;
|
|
469
477
|
(0, lib_1.cookie)().set(constants_1.SESSION_USER_ID_KEY, userId);
|
|
470
478
|
}
|
|
479
|
+
// Check for duplicate identify events in this session
|
|
480
|
+
if (validAddress && rdns && this.session.isWalletIdentified(validAddress, rdns)) {
|
|
481
|
+
lib_1.logger.warn("Identify: Wallet ".concat(providerName || 'Unknown', " with address ").concat(validAddress, " already identified in this session"));
|
|
482
|
+
return [2 /*return*/];
|
|
483
|
+
}
|
|
484
|
+
// Mark as identified before emitting the event
|
|
485
|
+
if (validAddress && rdns) {
|
|
486
|
+
this.session.markWalletIdentified(validAddress, rdns);
|
|
487
|
+
}
|
|
471
488
|
return [4 /*yield*/, this.trackEvent(constants_1.EventType.IDENTIFY, {
|
|
472
489
|
address: validAddress,
|
|
473
490
|
providerName: providerName,
|
|
474
491
|
userId: userId,
|
|
475
492
|
rdns: rdns,
|
|
476
493
|
}, properties, context, callback)];
|
|
477
|
-
case 10:
|
|
478
|
-
_c.sent();
|
|
479
|
-
return [3 /*break*/, 12];
|
|
480
494
|
case 11:
|
|
495
|
+
_c.sent();
|
|
496
|
+
return [3 /*break*/, 13];
|
|
497
|
+
case 12:
|
|
481
498
|
e_1 = _c.sent();
|
|
482
499
|
lib_1.logger.log("identify error", e_1);
|
|
483
|
-
return [3 /*break*/,
|
|
484
|
-
case
|
|
500
|
+
return [3 /*break*/, 13];
|
|
501
|
+
case 13: return [2 /*return*/];
|
|
485
502
|
}
|
|
486
503
|
});
|
|
487
504
|
});
|
|
@@ -709,7 +726,7 @@ var FormoAnalytics = /** @class */ (function () {
|
|
|
709
726
|
// Emit disconnect for the old provider
|
|
710
727
|
_a.sent();
|
|
711
728
|
// Clear state and let the new provider become active
|
|
712
|
-
this.
|
|
729
|
+
this.clearActiveProvider();
|
|
713
730
|
return [3 /*break*/, 12];
|
|
714
731
|
case 11:
|
|
715
732
|
lib_1.logger.info("OnAccountsChanged: Current provider still has accounts and same address, ignoring new provider", {
|
|
@@ -736,7 +753,7 @@ var FormoAnalytics = /** @class */ (function () {
|
|
|
736
753
|
// Emit disconnect for the old provider that didn't signal properly
|
|
737
754
|
_a.sent();
|
|
738
755
|
// Clear state and let the new provider become active
|
|
739
|
-
this.
|
|
756
|
+
this.clearActiveProvider();
|
|
740
757
|
_a.label = 15;
|
|
741
758
|
case 15: return [3 /*break*/, 18];
|
|
742
759
|
case 16:
|
|
@@ -756,7 +773,7 @@ var FormoAnalytics = /** @class */ (function () {
|
|
|
756
773
|
case 17:
|
|
757
774
|
// If we can't check the current provider, assume it's disconnected
|
|
758
775
|
_a.sent();
|
|
759
|
-
this.
|
|
776
|
+
this.clearActiveProvider();
|
|
760
777
|
return [3 /*break*/, 18];
|
|
761
778
|
case 18:
|
|
762
779
|
// Set provider if none exists (first connection)
|
|
@@ -1722,7 +1739,7 @@ var FormoAnalytics = /** @class */ (function () {
|
|
|
1722
1739
|
this.removeProviderListeners(provider);
|
|
1723
1740
|
this._trackedProviders.delete(provider);
|
|
1724
1741
|
if (this._provider === provider) {
|
|
1725
|
-
this.
|
|
1742
|
+
this.clearActiveProvider();
|
|
1726
1743
|
}
|
|
1727
1744
|
}
|
|
1728
1745
|
catch (e) {
|
|
@@ -1794,6 +1811,13 @@ var FormoAnalytics = /** @class */ (function () {
|
|
|
1794
1811
|
var validAddress = (0, address_1.getValidAddress)(address);
|
|
1795
1812
|
return validAddress ? (0, utils_1.toChecksumAddress)(validAddress) : undefined;
|
|
1796
1813
|
};
|
|
1814
|
+
/**
|
|
1815
|
+
* Helper method to clear the active provider state
|
|
1816
|
+
* Centralizes provider clearing logic for consistency
|
|
1817
|
+
*/
|
|
1818
|
+
FormoAnalytics.prototype.clearActiveProvider = function () {
|
|
1819
|
+
this._provider = undefined;
|
|
1820
|
+
};
|
|
1797
1821
|
/**
|
|
1798
1822
|
* Helper method to safely add a provider detail to _providers array, ensuring no duplicates
|
|
1799
1823
|
* @param detail The provider detail to add
|
|
@@ -1831,12 +1855,33 @@ var FormoAnalyticsSession = /** @class */ (function () {
|
|
|
1831
1855
|
FormoAnalyticsSession.prototype.markWalletDetected = function (rdns) {
|
|
1832
1856
|
var _a;
|
|
1833
1857
|
var rdnses = ((_a = (0, lib_1.cookie)().get(constants_1.SESSION_WALLET_DETECTED_KEY)) === null || _a === void 0 ? void 0 : _a.split(",")) || [];
|
|
1834
|
-
rdnses.
|
|
1835
|
-
|
|
1836
|
-
|
|
1837
|
-
|
|
1838
|
-
|
|
1839
|
-
|
|
1858
|
+
if (!rdnses.includes(rdns)) {
|
|
1859
|
+
rdnses.push(rdns);
|
|
1860
|
+
(0, lib_1.cookie)().set(constants_1.SESSION_WALLET_DETECTED_KEY, rdnses.join(","), {
|
|
1861
|
+
// by the end of the day
|
|
1862
|
+
expires: new Date(Date.now() + 86400 * 1000).toUTCString(),
|
|
1863
|
+
path: "/",
|
|
1864
|
+
});
|
|
1865
|
+
}
|
|
1866
|
+
};
|
|
1867
|
+
FormoAnalyticsSession.prototype.isWalletIdentified = function (address, rdns) {
|
|
1868
|
+
var _a;
|
|
1869
|
+
var identifiedKey = "".concat(address, ":").concat(rdns);
|
|
1870
|
+
var identifiedWallets = ((_a = (0, lib_1.cookie)().get(constants_1.SESSION_WALLET_IDENTIFIED_KEY)) === null || _a === void 0 ? void 0 : _a.split(",")) || [];
|
|
1871
|
+
return identifiedWallets.includes(identifiedKey);
|
|
1872
|
+
};
|
|
1873
|
+
FormoAnalyticsSession.prototype.markWalletIdentified = function (address, rdns) {
|
|
1874
|
+
var _a;
|
|
1875
|
+
var identifiedKey = "".concat(address, ":").concat(rdns);
|
|
1876
|
+
var identifiedWallets = ((_a = (0, lib_1.cookie)().get(constants_1.SESSION_WALLET_IDENTIFIED_KEY)) === null || _a === void 0 ? void 0 : _a.split(",")) || [];
|
|
1877
|
+
if (!identifiedWallets.includes(identifiedKey)) {
|
|
1878
|
+
identifiedWallets.push(identifiedKey);
|
|
1879
|
+
(0, lib_1.cookie)().set(constants_1.SESSION_WALLET_IDENTIFIED_KEY, identifiedWallets.join(","), {
|
|
1880
|
+
// by the end of the day
|
|
1881
|
+
expires: new Date(Date.now() + 86400 * 1000).toUTCString(),
|
|
1882
|
+
path: "/",
|
|
1883
|
+
});
|
|
1884
|
+
}
|
|
1840
1885
|
};
|
|
1841
1886
|
return FormoAnalyticsSession;
|
|
1842
1887
|
}());
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export declare const SESSION_TRAFFIC_SOURCE_KEY = "traffic-source";
|
|
2
2
|
export declare const SESSION_WALLET_DETECTED_KEY = "wallet-detected";
|
|
3
|
+
export declare const SESSION_WALLET_IDENTIFIED_KEY = "wallet-identified";
|
|
3
4
|
export declare const SESSION_CURRENT_URL_KEY = "analytics-current-url";
|
|
4
5
|
export declare const SESSION_USER_ID_KEY = "user-id";
|
|
5
6
|
export declare const LOCAL_ANONYMOUS_ID_KEY = "anonymous-id";
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.DEFAULT_PROVIDER_ICON = exports.LOCAL_ANONYMOUS_ID_KEY = exports.SESSION_USER_ID_KEY = exports.SESSION_CURRENT_URL_KEY = exports.SESSION_WALLET_DETECTED_KEY = exports.SESSION_TRAFFIC_SOURCE_KEY = void 0;
|
|
3
|
+
exports.DEFAULT_PROVIDER_ICON = exports.LOCAL_ANONYMOUS_ID_KEY = exports.SESSION_USER_ID_KEY = exports.SESSION_CURRENT_URL_KEY = exports.SESSION_WALLET_IDENTIFIED_KEY = exports.SESSION_WALLET_DETECTED_KEY = exports.SESSION_TRAFFIC_SOURCE_KEY = void 0;
|
|
4
4
|
exports.SESSION_TRAFFIC_SOURCE_KEY = "traffic-source";
|
|
5
5
|
exports.SESSION_WALLET_DETECTED_KEY = "wallet-detected";
|
|
6
|
+
exports.SESSION_WALLET_IDENTIFIED_KEY = "wallet-identified";
|
|
6
7
|
exports.SESSION_CURRENT_URL_KEY = "analytics-current-url";
|
|
7
8
|
exports.SESSION_USER_ID_KEY = "user-id";
|
|
8
9
|
exports.LOCAL_ANONYMOUS_ID_KEY = "anonymous-id";
|
|
@@ -269,6 +269,11 @@ export declare class FormoAnalytics implements IFormoAnalytics {
|
|
|
269
269
|
* @returns The checksummed address or undefined if invalid
|
|
270
270
|
*/
|
|
271
271
|
private validateAndChecksumAddress;
|
|
272
|
+
/**
|
|
273
|
+
* Helper method to clear the active provider state
|
|
274
|
+
* Centralizes provider clearing logic for consistency
|
|
275
|
+
*/
|
|
276
|
+
private clearActiveProvider;
|
|
272
277
|
/**
|
|
273
278
|
* Helper method to safely add a provider detail to _providers array, ensuring no duplicates
|
|
274
279
|
* @param detail The provider detail to add
|
|
@@ -55,7 +55,7 @@ var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
|
|
|
55
55
|
return to.concat(ar || Array.prototype.slice.call(from));
|
|
56
56
|
};
|
|
57
57
|
import { createStore } from "mipd";
|
|
58
|
-
import { EVENTS_API_URL, EventType, LOCAL_ANONYMOUS_ID_KEY, SESSION_CURRENT_URL_KEY, SESSION_USER_ID_KEY, SESSION_WALLET_DETECTED_KEY, DEFAULT_PROVIDER_ICON, } from "./constants";
|
|
58
|
+
import { EVENTS_API_URL, EventType, LOCAL_ANONYMOUS_ID_KEY, SESSION_CURRENT_URL_KEY, SESSION_USER_ID_KEY, SESSION_WALLET_DETECTED_KEY, SESSION_WALLET_IDENTIFIED_KEY, DEFAULT_PROVIDER_ICON, } from "./constants";
|
|
59
59
|
import { cookie, EventManager, EventQueue, initStorageManager, logger, Logger, } from "./lib";
|
|
60
60
|
import { SignatureStatus, TransactionStatus, WRAPPED_REQUEST_SYMBOL, WRAPPED_REQUEST_REF_SYMBOL, } from "./types";
|
|
61
61
|
import { toChecksumAddress } from "./utils";
|
|
@@ -216,6 +216,7 @@ var FormoAnalytics = /** @class */ (function () {
|
|
|
216
216
|
cookie().remove(LOCAL_ANONYMOUS_ID_KEY);
|
|
217
217
|
cookie().remove(SESSION_USER_ID_KEY);
|
|
218
218
|
cookie().remove(SESSION_WALLET_DETECTED_KEY);
|
|
219
|
+
cookie().remove(SESSION_WALLET_IDENTIFIED_KEY);
|
|
219
220
|
};
|
|
220
221
|
/**
|
|
221
222
|
* Emits a connect wallet event.
|
|
@@ -292,7 +293,7 @@ var FormoAnalytics = /** @class */ (function () {
|
|
|
292
293
|
_a.sent();
|
|
293
294
|
this.currentAddress = undefined;
|
|
294
295
|
this.currentChainId = undefined;
|
|
295
|
-
this.
|
|
296
|
+
this.clearActiveProvider();
|
|
296
297
|
logger.info("Wallet disconnected: Cleared currentAddress, currentChainId, and provider");
|
|
297
298
|
return [2 /*return*/];
|
|
298
299
|
}
|
|
@@ -403,51 +404,58 @@ var FormoAnalytics = /** @class */ (function () {
|
|
|
403
404
|
*/
|
|
404
405
|
FormoAnalytics.prototype.identify = function (params, properties, context, callback) {
|
|
405
406
|
return __awaiter(this, void 0, void 0, function () {
|
|
406
|
-
var _i, _a, providerDetail, provider, address_1, err_1, userId, address, providerName, rdns, validAddress, e_1;
|
|
407
|
+
var _i, _a, providerDetail, provider, address_1, validAddress_1, err_1, userId, address, providerName, rdns, validAddress, e_1;
|
|
407
408
|
var _b;
|
|
408
409
|
return __generator(this, function (_c) {
|
|
409
410
|
switch (_c.label) {
|
|
410
411
|
case 0:
|
|
411
|
-
_c.trys.push([0,
|
|
412
|
-
if (!!params) return [3 /*break*/,
|
|
412
|
+
_c.trys.push([0, 12, , 13]);
|
|
413
|
+
if (!!params) return [3 /*break*/, 10];
|
|
413
414
|
// If no params provided, auto-identify
|
|
414
415
|
logger.info("Auto-identifying with providers:", this._providers.map(function (p) { return p.info.name; }));
|
|
415
416
|
_i = 0, _a = this._providers;
|
|
416
417
|
_c.label = 1;
|
|
417
418
|
case 1:
|
|
418
|
-
if (!(_i < _a.length)) return [3 /*break*/,
|
|
419
|
+
if (!(_i < _a.length)) return [3 /*break*/, 9];
|
|
419
420
|
providerDetail = _a[_i];
|
|
420
421
|
provider = providerDetail.provider;
|
|
421
422
|
if (!provider)
|
|
422
|
-
return [3 /*break*/,
|
|
423
|
+
return [3 /*break*/, 8];
|
|
423
424
|
_c.label = 2;
|
|
424
425
|
case 2:
|
|
425
|
-
_c.trys.push([2,
|
|
426
|
+
_c.trys.push([2, 7, , 8]);
|
|
426
427
|
return [4 /*yield*/, this.getAddress(provider)];
|
|
427
428
|
case 3:
|
|
428
429
|
address_1 = _c.sent();
|
|
429
|
-
if (!address_1) return [3 /*break*/,
|
|
430
|
-
|
|
430
|
+
if (!address_1) return [3 /*break*/, 6];
|
|
431
|
+
validAddress_1 = this.validateAndChecksumAddress(address_1);
|
|
432
|
+
if (!(validAddress_1 && !this.session.isWalletIdentified(validAddress_1, providerDetail.info.rdns))) return [3 /*break*/, 5];
|
|
433
|
+
logger.info("Auto-identifying", validAddress_1, providerDetail.info.name, providerDetail.info.rdns);
|
|
431
434
|
// NOTE: do not set this.currentAddress without explicit connect or identify
|
|
432
435
|
return [4 /*yield*/, this.identify({
|
|
433
|
-
address:
|
|
436
|
+
address: validAddress_1,
|
|
434
437
|
providerName: providerDetail.info.name,
|
|
435
438
|
rdns: providerDetail.info.rdns,
|
|
436
439
|
}, properties, context, callback)];
|
|
437
440
|
case 4:
|
|
438
441
|
// NOTE: do not set this.currentAddress without explicit connect or identify
|
|
439
442
|
_c.sent();
|
|
440
|
-
|
|
441
|
-
case 5:
|
|
442
|
-
|
|
443
|
+
return [3 /*break*/, 6];
|
|
444
|
+
case 5:
|
|
445
|
+
if (validAddress_1) {
|
|
446
|
+
logger.info("Auto-identify: Skipping already identified wallet", validAddress_1, providerDetail.info.name, providerDetail.info.rdns);
|
|
447
|
+
}
|
|
448
|
+
_c.label = 6;
|
|
449
|
+
case 6: return [3 /*break*/, 8];
|
|
450
|
+
case 7:
|
|
443
451
|
err_1 = _c.sent();
|
|
444
452
|
logger.error("Failed to identify provider ".concat(providerDetail.info.name, ":"), err_1);
|
|
445
|
-
return [3 /*break*/,
|
|
446
|
-
case
|
|
453
|
+
return [3 /*break*/, 8];
|
|
454
|
+
case 8:
|
|
447
455
|
_i++;
|
|
448
456
|
return [3 /*break*/, 1];
|
|
449
|
-
case
|
|
450
|
-
case
|
|
457
|
+
case 9: return [2 /*return*/];
|
|
458
|
+
case 10:
|
|
451
459
|
userId = params.userId, address = params.address, providerName = params.providerName, rdns = params.rdns;
|
|
452
460
|
logger.info("Identify", address, userId, providerName, rdns);
|
|
453
461
|
validAddress = undefined;
|
|
@@ -465,20 +473,29 @@ var FormoAnalytics = /** @class */ (function () {
|
|
|
465
473
|
this.currentUserId = userId;
|
|
466
474
|
cookie().set(SESSION_USER_ID_KEY, userId);
|
|
467
475
|
}
|
|
476
|
+
// Check for duplicate identify events in this session
|
|
477
|
+
if (validAddress && rdns && this.session.isWalletIdentified(validAddress, rdns)) {
|
|
478
|
+
logger.warn("Identify: Wallet ".concat(providerName || 'Unknown', " with address ").concat(validAddress, " already identified in this session"));
|
|
479
|
+
return [2 /*return*/];
|
|
480
|
+
}
|
|
481
|
+
// Mark as identified before emitting the event
|
|
482
|
+
if (validAddress && rdns) {
|
|
483
|
+
this.session.markWalletIdentified(validAddress, rdns);
|
|
484
|
+
}
|
|
468
485
|
return [4 /*yield*/, this.trackEvent(EventType.IDENTIFY, {
|
|
469
486
|
address: validAddress,
|
|
470
487
|
providerName: providerName,
|
|
471
488
|
userId: userId,
|
|
472
489
|
rdns: rdns,
|
|
473
490
|
}, properties, context, callback)];
|
|
474
|
-
case 10:
|
|
475
|
-
_c.sent();
|
|
476
|
-
return [3 /*break*/, 12];
|
|
477
491
|
case 11:
|
|
492
|
+
_c.sent();
|
|
493
|
+
return [3 /*break*/, 13];
|
|
494
|
+
case 12:
|
|
478
495
|
e_1 = _c.sent();
|
|
479
496
|
logger.log("identify error", e_1);
|
|
480
|
-
return [3 /*break*/,
|
|
481
|
-
case
|
|
497
|
+
return [3 /*break*/, 13];
|
|
498
|
+
case 13: return [2 /*return*/];
|
|
482
499
|
}
|
|
483
500
|
});
|
|
484
501
|
});
|
|
@@ -706,7 +723,7 @@ var FormoAnalytics = /** @class */ (function () {
|
|
|
706
723
|
// Emit disconnect for the old provider
|
|
707
724
|
_a.sent();
|
|
708
725
|
// Clear state and let the new provider become active
|
|
709
|
-
this.
|
|
726
|
+
this.clearActiveProvider();
|
|
710
727
|
return [3 /*break*/, 12];
|
|
711
728
|
case 11:
|
|
712
729
|
logger.info("OnAccountsChanged: Current provider still has accounts and same address, ignoring new provider", {
|
|
@@ -733,7 +750,7 @@ var FormoAnalytics = /** @class */ (function () {
|
|
|
733
750
|
// Emit disconnect for the old provider that didn't signal properly
|
|
734
751
|
_a.sent();
|
|
735
752
|
// Clear state and let the new provider become active
|
|
736
|
-
this.
|
|
753
|
+
this.clearActiveProvider();
|
|
737
754
|
_a.label = 15;
|
|
738
755
|
case 15: return [3 /*break*/, 18];
|
|
739
756
|
case 16:
|
|
@@ -753,7 +770,7 @@ var FormoAnalytics = /** @class */ (function () {
|
|
|
753
770
|
case 17:
|
|
754
771
|
// If we can't check the current provider, assume it's disconnected
|
|
755
772
|
_a.sent();
|
|
756
|
-
this.
|
|
773
|
+
this.clearActiveProvider();
|
|
757
774
|
return [3 /*break*/, 18];
|
|
758
775
|
case 18:
|
|
759
776
|
// Set provider if none exists (first connection)
|
|
@@ -1719,7 +1736,7 @@ var FormoAnalytics = /** @class */ (function () {
|
|
|
1719
1736
|
this.removeProviderListeners(provider);
|
|
1720
1737
|
this._trackedProviders.delete(provider);
|
|
1721
1738
|
if (this._provider === provider) {
|
|
1722
|
-
this.
|
|
1739
|
+
this.clearActiveProvider();
|
|
1723
1740
|
}
|
|
1724
1741
|
}
|
|
1725
1742
|
catch (e) {
|
|
@@ -1791,6 +1808,13 @@ var FormoAnalytics = /** @class */ (function () {
|
|
|
1791
1808
|
var validAddress = getValidAddress(address);
|
|
1792
1809
|
return validAddress ? toChecksumAddress(validAddress) : undefined;
|
|
1793
1810
|
};
|
|
1811
|
+
/**
|
|
1812
|
+
* Helper method to clear the active provider state
|
|
1813
|
+
* Centralizes provider clearing logic for consistency
|
|
1814
|
+
*/
|
|
1815
|
+
FormoAnalytics.prototype.clearActiveProvider = function () {
|
|
1816
|
+
this._provider = undefined;
|
|
1817
|
+
};
|
|
1794
1818
|
/**
|
|
1795
1819
|
* Helper method to safely add a provider detail to _providers array, ensuring no duplicates
|
|
1796
1820
|
* @param detail The provider detail to add
|
|
@@ -1828,12 +1852,33 @@ var FormoAnalyticsSession = /** @class */ (function () {
|
|
|
1828
1852
|
FormoAnalyticsSession.prototype.markWalletDetected = function (rdns) {
|
|
1829
1853
|
var _a;
|
|
1830
1854
|
var rdnses = ((_a = cookie().get(SESSION_WALLET_DETECTED_KEY)) === null || _a === void 0 ? void 0 : _a.split(",")) || [];
|
|
1831
|
-
rdnses.
|
|
1832
|
-
|
|
1833
|
-
|
|
1834
|
-
|
|
1835
|
-
|
|
1836
|
-
|
|
1855
|
+
if (!rdnses.includes(rdns)) {
|
|
1856
|
+
rdnses.push(rdns);
|
|
1857
|
+
cookie().set(SESSION_WALLET_DETECTED_KEY, rdnses.join(","), {
|
|
1858
|
+
// by the end of the day
|
|
1859
|
+
expires: new Date(Date.now() + 86400 * 1000).toUTCString(),
|
|
1860
|
+
path: "/",
|
|
1861
|
+
});
|
|
1862
|
+
}
|
|
1863
|
+
};
|
|
1864
|
+
FormoAnalyticsSession.prototype.isWalletIdentified = function (address, rdns) {
|
|
1865
|
+
var _a;
|
|
1866
|
+
var identifiedKey = "".concat(address, ":").concat(rdns);
|
|
1867
|
+
var identifiedWallets = ((_a = cookie().get(SESSION_WALLET_IDENTIFIED_KEY)) === null || _a === void 0 ? void 0 : _a.split(",")) || [];
|
|
1868
|
+
return identifiedWallets.includes(identifiedKey);
|
|
1869
|
+
};
|
|
1870
|
+
FormoAnalyticsSession.prototype.markWalletIdentified = function (address, rdns) {
|
|
1871
|
+
var _a;
|
|
1872
|
+
var identifiedKey = "".concat(address, ":").concat(rdns);
|
|
1873
|
+
var identifiedWallets = ((_a = cookie().get(SESSION_WALLET_IDENTIFIED_KEY)) === null || _a === void 0 ? void 0 : _a.split(",")) || [];
|
|
1874
|
+
if (!identifiedWallets.includes(identifiedKey)) {
|
|
1875
|
+
identifiedWallets.push(identifiedKey);
|
|
1876
|
+
cookie().set(SESSION_WALLET_IDENTIFIED_KEY, identifiedWallets.join(","), {
|
|
1877
|
+
// by the end of the day
|
|
1878
|
+
expires: new Date(Date.now() + 86400 * 1000).toUTCString(),
|
|
1879
|
+
path: "/",
|
|
1880
|
+
});
|
|
1881
|
+
}
|
|
1837
1882
|
};
|
|
1838
1883
|
return FormoAnalyticsSession;
|
|
1839
1884
|
}());
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export declare const SESSION_TRAFFIC_SOURCE_KEY = "traffic-source";
|
|
2
2
|
export declare const SESSION_WALLET_DETECTED_KEY = "wallet-detected";
|
|
3
|
+
export declare const SESSION_WALLET_IDENTIFIED_KEY = "wallet-identified";
|
|
3
4
|
export declare const SESSION_CURRENT_URL_KEY = "analytics-current-url";
|
|
4
5
|
export declare const SESSION_USER_ID_KEY = "user-id";
|
|
5
6
|
export declare const LOCAL_ANONYMOUS_ID_KEY = "anonymous-id";
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export var SESSION_TRAFFIC_SOURCE_KEY = "traffic-source";
|
|
2
2
|
export var SESSION_WALLET_DETECTED_KEY = "wallet-detected";
|
|
3
|
+
export var SESSION_WALLET_IDENTIFIED_KEY = "wallet-identified";
|
|
3
4
|
export var SESSION_CURRENT_URL_KEY = "analytics-current-url";
|
|
4
5
|
export var SESSION_USER_ID_KEY = "user-id";
|
|
5
6
|
export var LOCAL_ANONYMOUS_ID_KEY = "anonymous-id";
|
package/dist/index.umd.min.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
/*! For license information please see index.umd.min.js.LICENSE.txt */
|
|
2
|
-
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define("FormoAnalytics",[],t):"object"==typeof exports?exports.FormoAnalytics=t():e.FormoAnalytics=t()}(self,(()=>(()=>{var e={15:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.parseChainId=function(e){return"string"!=typeof e?0:e.startsWith("0x")||e.startsWith("0X")?parseInt(e,16):parseInt(e,10)}},80:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return null!=e&&"object"==typeof e&&!0===e["@@functional/placeholder"]}},654:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return function t(r,n){switch(arguments.length){case 0:return t;case 1:return(0,o.default)(r)?t:(0,i.default)((function(t){return e(r,t)}));default:return(0,o.default)(r)&&(0,o.default)(n)?t:(0,o.default)(r)?(0,i.default)((function(t){return e(t,n)})):(0,o.default)(n)?(0,i.default)((function(t){return e(r,t)})):e(r,n)}}};var i=n(r(4323)),o=n(r(80))},661:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){return Object.prototype.hasOwnProperty.call(t,e)}},689:function(e,t,r){"use strict";var n=this&&this.__assign||function(){return n=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},n.apply(this,arguments)},i=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{c(n.next(e))}catch(e){o(e)}}function s(e){try{c(n.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}c((n=n.apply(e,t||[])).next())}))},o=this&&this.__generator||function(e,t){var r,n,i,o={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return a.next=s(0),a.throw=s(1),a.return=s(2),"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function s(s){return function(c){return function(s){if(r)throw new TypeError("Generator is already executing.");for(;a&&(a=0,s[0]&&(o=0)),o;)try{if(r=1,n&&(i=2&s[0]?n.return:s[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,s[1])).done)return i;switch(n=0,i&&(s=[2&s[0],i.value]),s[0]){case 0:case 1:i=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,n=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((i=(i=o.trys).length>0&&i[i.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!i||s[1]>i[0]&&s[1]<i[3])){o.label=s[1];break}if(6===s[0]&&o.label<i[1]){o.label=i[1],i=s;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(s);break}i[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],n=0}finally{r=i=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,c])}}},a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.EventQueue=void 0;var s=r(9754),c=r(9266),u=r(8177),d=r(6450),l=a(r(4364)),f=function(){},h=function(){function e(e,t){var r=this;this.queue=[],this.payloadHashes=new Set,this.onPageLeave=function(e){var t=!1,r=!1;function n(){t||(t=!0,e(r),setTimeout((function(){t=!1}),0))}globalThis.addEventListener("beforeunload",(function(){r=!1,n()})),globalThis.addEventListener("blur",(function(){r=!0,n()})),globalThis.addEventListener("focus",(function(){t=!1})),document.addEventListener("pagehide",(function(){r="hidden"===document.visibilityState,n()})),document.addEventListener("visibilitychange",(function(){r=!0,"hidden"===document.visibilityState?n():t=!1}))},t=t||{},this.queue=[],this.writeKey=e,this.url=t.url,this.retryCount=(0,c.clampNumber)(t.retryCount||3,5,1),this.flushAt=(0,c.clampNumber)(t.flushAt||20,20,1),this.maxQueueSize=(0,c.clampNumber)(t.maxQueueSize||512e3,512e3,200),this.flushIntervalMs=(0,c.clampNumber)(t.flushInterval||3e4,3e5,1e4),this.flushed=!0,this.errorHandler=t.errorHandler,this.pendingFlush=null,this.timer=null,this.onPageLeave((function(e){return i(r,void 0,void 0,(function(){return o(this,(function(t){switch(t.label){case 0:return!1!==e?[3,2]:[4,this.flush()];case 1:t.sent(),t.label=2;case 2:return[2]}}))}))}))}return e.prototype.generateMessageId=function(e){return i(this,void 0,void 0,(function(){var t,r,i;return o(this,(function(o){return t=(0,c.toDateHourMinute)(new Date(e.original_timestamp)),r=n(n({},e),{original_timestamp:t}),i=JSON.stringify(r),[2,(0,c.hash)(i)]}))}))},e.prototype.enqueue=function(e,t){return i(this,void 0,void 0,(function(){var r,i,a;return o(this,(function(o){switch(o.label){case 0:return t=t||f,[4,this.generateMessageId(e)];case 1:return r=o.sent(),[4,this.isDuplicate(r)];case 2:return o.sent()?(u.logger.warn("Event already enqueued, try again after ".concat((0,c.millisecondsToSecond)(this.flushIntervalMs)," seconds.")),[2]):(this.queue.push({message:n(n({},e),{message_id:r}),callback:t}),u.logger.log("Event enqueued: ".concat((0,c.getActionDescriptor)(e.type,e.properties))),this.flushed?(i=this.queue.length>=this.flushAt,a=this.queue.reduce((function(e,t){return e+JSON.stringify(t).length}),0)>=this.maxQueueSize,i||a?(this.flush(),[2]):(this.flushIntervalMs&&!this.timer&&(this.timer=setTimeout(this.flush.bind(this),this.flushIntervalMs)),[2])):(this.flushed=!0,this.flush(),[2]))}}))}))},e.prototype.flush=function(e){return i(this,void 0,void 0,(function(){var t,r,i,a,s,c=this;return o(this,(function(o){switch(o.label){case 0:if(e=e||f,this.timer&&(clearTimeout(this.timer),this.timer=null),!this.queue.length)return e(),[2,Promise.resolve()];o.label=1;case 1:return o.trys.push([1,4,,5]),this.pendingFlush?[4,this.pendingFlush]:[3,3];case 2:o.sent(),o.label=3;case 3:return[3,5];case 4:throw t=o.sent(),this.pendingFlush=null,t;case 5:return r=this.queue.splice(0,this.flushAt),this.payloadHashes.clear(),i=(new Date).toISOString(),a=r.map((function(e){return n(n({},e.message),{sent_at:i})})),s=function(t){r.forEach((function(e){var r=e.message;return(0,e.callback)(t,r,a)})),e(t,a)},[2,this.pendingFlush=(0,l.default)("".concat(this.url),{headers:(0,d.EVENTS_API_REQUEST_HEADER)(this.writeKey),method:"POST",body:JSON.stringify(a),keepalive:!0,retries:this.retryCount,retryDelay:function(e){return 1e3*Math.pow(2,e)},retryOn:function(e,t){return c.isErrorRetryable(t)}}).then((function(){return s(),Promise.resolve(a)})).catch((function(e){if("function"==typeof c.errorHandler)return s(e),c.errorHandler(e);if(e.response){var t=new Error(e.response.statusText);throw s(t),t}throw s(e),e}))]}}))}))},e.prototype.isErrorRetryable=function(e){var t,r,n;return!!(0,s.isNetworkError)(e)||!!(null==e?void 0:e.response)&&((null===(t=null==e?void 0:e.response)||void 0===t?void 0:t.status)>=500&&(null===(r=null==e?void 0:e.response)||void 0===r?void 0:r.status)<=599||429===(null===(n=null==e?void 0:e.response)||void 0===n?void 0:n.status))},e.prototype.isDuplicate=function(e){return i(this,void 0,void 0,(function(){return o(this,(function(t){return this.payloadHashes.has(e)?[2,!0]:(this.payloadHashes.add(e),[2,!1])}))}))},e}();t.EventQueue=h},724:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isNetworkError=function(e){return!(!e||!n(e)||"TypeError"!==e.name||"string"!=typeof e.message)&&("Load failed"===e.message?void 0===e.stack:i.has(e.message))};var r=Object.prototype.toString,n=function(e){return"[object Error]"===r.call(e)},i=new Set(["network error","Failed to fetch","NetworkError when attempting to fetch resource.","The Internet connection appears to be offline.","Load failed","Network request failed","fetch failed","terminated"])},879:function(e,t,r){"use strict";var n=this&&this.__assign||function(){return n=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},n.apply(this,arguments)},i=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{c(n.next(e))}catch(e){o(e)}}function s(e){try{c(n.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}c((n=n.apply(e,t||[])).next())}))},o=this&&this.__generator||function(e,t){var r,n,i,o={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return a.next=s(0),a.throw=s(1),a.return=s(2),"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function s(s){return function(c){return function(s){if(r)throw new TypeError("Generator is already executing.");for(;a&&(a=0,s[0]&&(o=0)),o;)try{if(r=1,n&&(i=2&s[0]?n.return:s[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,s[1])).done)return i;switch(n=0,i&&(s=[2&s[0],i.value]),s[0]){case 0:case 1:i=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,n=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((i=(i=o.trys).length>0&&i[i.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!i||s[1]>i[0]&&s[1]<i[3])){o.label=s[1];break}if(6===s[0]&&o.label<i[1]){o.label=i[1],i=s;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(s);break}i[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],n=0}finally{r=i=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,c])}}},a=this&&this.__spreadArray||function(e,t,r){if(r||2===arguments.length)for(var n,i=0,o=t.length;i<o;i++)!n&&i in t||(n||(n=Array.prototype.slice.call(t,0,i)),n[i]=t[i]);return e.concat(n||Array.prototype.slice.call(t))};Object.defineProperty(t,"__esModule",{value:!0}),t.FormoAnalytics=void 0;var s=r(4228),c=r(6450),u=r(8568),d=r(3574),l=r(9266),f=r(922),h=r(9754),p=r(15),v=function(){function e(e,t){var r,n;void 0===t&&(t={}),this.writeKey=e,this.options=t,this._providerListenersMap=new Map,this._providers=[],this._trackedProviders=new Set,this._processingAccountsChanged=!1,this._seenProviders=new Set,this.currentUserId="",this.config={writeKey:e},this.options=t,this.session=new g,this.currentUserId=(0,u.cookie)().get(c.SESSION_USER_ID_KEY)||void 0,this.identify=this.identify.bind(this),this.connect=this.connect.bind(this),this.disconnect=this.disconnect.bind(this),this.chain=this.chain.bind(this),this.signature=this.signature.bind(this),this.transaction=this.transaction.bind(this),this.detect=this.detect.bind(this),this.track=this.track.bind(this),u.Logger.init({enabled:(null===(r=t.logger)||void 0===r?void 0:r.enabled)||!1,enabledLevels:(null===(n=t.logger)||void 0===n?void 0:n.levels)||[]}),this.eventManager=new u.EventManager(new u.EventQueue(this.config.writeKey,{url:c.EVENTS_API_URL,flushAt:t.flushAt,retryCount:t.retryCount,maxQueueSize:t.maxQueueSize,flushInterval:t.flushInterval}));var i=void 0,o=t.provider;o?i=o:"undefined"!=typeof window&&window.ethereum&&(i=window.ethereum),i&&this.trackProvider(i),this.trackPageHit(),this.trackPageHits()}return e.prototype.isProviderMismatch=function(e){return null!=this._provider&&this._provider!==e},e.prototype.isProviderInValidState=function(e){return e&&"function"==typeof e.request&&"function"==typeof e.on&&"function"==typeof e.removeListener},e.init=function(t,r){return i(this,void 0,void 0,(function(){var n,i;return o(this,(function(o){switch(o.label){case 0:return(0,u.initStorageManager)(t),n=new e(t,r),i=n,[4,n.getProviders()];case 1:return i._providers=o.sent(),[4,n.detectWallets(n._providers)];case 2:return o.sent(),n.trackProviders(n._providers),[2,n]}}))}))},e.prototype.page=function(e,t,r,n,a){return i(this,void 0,void 0,(function(){return o(this,(function(i){switch(i.label){case 0:return[4,this.trackPageHit(e,t,r,n,a)];case 1:return i.sent(),[2]}}))}))},e.prototype.reset=function(){this.currentUserId=void 0,(0,u.cookie)().remove(c.LOCAL_ANONYMOUS_ID_KEY),(0,u.cookie)().remove(c.SESSION_USER_ID_KEY),(0,u.cookie)().remove(c.SESSION_WALLET_DETECTED_KEY)},e.prototype.connect=function(e,t,r,n){return i(this,arguments,void 0,(function(e,t,r,n){var i,a=e.chainId,s=e.address;return o(this,(function(e){switch(e.label){case 0:return null==a?(u.logger.warn("Connect: Chain ID cannot be null or undefined"),[2]):s?(this.currentChainId=a,(i=this.validateAndChecksumAddress(s))?(this.currentAddress=i,[4,this.trackEvent(c.EventType.CONNECT,{chainId:a,address:this.currentAddress},t,r,n)]):(u.logger.warn('Connect: Invalid address provided ("'.concat(s,'"). Please provide a valid Ethereum address in checksum format.')),[2])):(u.logger.warn("Connect: Address cannot be empty"),[2]);case 1:return e.sent(),[2]}}))}))},e.prototype.disconnect=function(e,t,r,a){return i(this,void 0,void 0,(function(){var i,s,d,l;return o(this,(function(o){switch(o.label){case 0:return i=(null==e?void 0:e.chainId)||this.currentChainId,s=(null==e?void 0:e.address)||this.currentAddress,d=this._provider?this.getProviderInfo(this._provider):null,u.logger.info("Disconnect: Emitting disconnect event with:",{chainId:i,address:s,providerName:null==d?void 0:d.name,rdns:null==d?void 0:d.rdns}),l=n(n({},d&&{providerName:d.name,rdns:d.rdns}),t),[4,this.trackEvent(c.EventType.DISCONNECT,n(n({},i&&{chainId:i}),s&&{address:s}),l,r,a)];case 1:return o.sent(),this.currentAddress=void 0,this.currentChainId=void 0,this._provider=void 0,u.logger.info("Wallet disconnected: Cleared currentAddress, currentChainId, and provider"),[2]}}))}))},e.prototype.chain=function(e,t,r,n){return i(this,arguments,void 0,(function(e,t,r,n){var i=e.chainId,a=e.address;return o(this,(function(e){switch(e.label){case 0:return i&&0!==Number(i)?isNaN(Number(i))?(u.logger.warn("FormoAnalytics::chain: chainId must be a valid decimal number"),[2]):a||this.currentAddress?(this.currentChainId=i,[4,this.trackEvent(c.EventType.CHAIN,{chainId:i,address:a||this.currentAddress},t,r,n)]):(u.logger.warn("FormoAnalytics::chain: address was empty and no previous address has been recorded"),[2]):(u.logger.warn("FormoAnalytics::chain: chainId cannot be empty or 0"),[2]);case 1:return e.sent(),[2]}}))}))},e.prototype.signature=function(e,t,r,a){return i(this,arguments,void 0,(function(e,t,r,i){var a=e.status,s=e.chainId,u=e.address,d=e.message,l=e.signatureHash;return o(this,(function(e){switch(e.label){case 0:return[4,this.trackEvent(c.EventType.SIGNATURE,n({status:a,chainId:s,address:u,message:d},l&&{signatureHash:l}),t,r,i)];case 1:return e.sent(),[2]}}))}))},e.prototype.transaction=function(e,t,r,a){return i(this,arguments,void 0,(function(e,t,r,i){var a=e.status,s=e.chainId,u=e.address,d=e.data,l=e.to,f=e.value,h=e.transactionHash;return o(this,(function(e){switch(e.label){case 0:return[4,this.trackEvent(c.EventType.TRANSACTION,n({status:a,chainId:s,address:u,data:d,to:l,value:f},h&&{transactionHash:h}),t,r,i)];case 1:return e.sent(),[2]}}))}))},e.prototype.identify=function(e,t,r,n){return i(this,void 0,void 0,(function(){var i,a,s,d,l,f,h,p,v,g,y,A,m;return o(this,(function(o){switch(o.label){case 0:if(o.trys.push([0,11,,12]),e)return[3,9];u.logger.info("Auto-identifying with providers:",this._providers.map((function(e){return e.info.name}))),i=0,a=this._providers,o.label=1;case 1:if(!(i<a.length))return[3,8];if(s=a[i],!(d=s.provider))return[3,7];o.label=2;case 2:return o.trys.push([2,6,,7]),[4,this.getAddress(d)];case 3:return(l=o.sent())?(u.logger.info("Auto-identifying",l,s.info.name,s.info.rdns),[4,this.identify({address:l,providerName:s.info.name,rdns:s.info.rdns},t,r,n)]):[3,5];case 4:o.sent(),o.label=5;case 5:return[3,7];case 6:return f=o.sent(),u.logger.error("Failed to identify provider ".concat(s.info.name,":"),f),[3,7];case 7:return i++,[3,1];case 8:return[2];case 9:return h=e.userId,p=e.address,v=e.providerName,g=e.rdns,u.logger.info("Identify",p,h,v,g),y=void 0,p?(y=this.validateAndChecksumAddress(p),this.currentAddress=y||void 0,y||null===(m=u.logger.warn)||void 0===m||m.call(u.logger,"Invalid address provided to identify:",p)):this.currentAddress=void 0,h&&(this.currentUserId=h,(0,u.cookie)().set(c.SESSION_USER_ID_KEY,h)),[4,this.trackEvent(c.EventType.IDENTIFY,{address:y,providerName:v,userId:h,rdns:g},t,r,n)];case 10:return o.sent(),[3,12];case 11:return A=o.sent(),u.logger.log("identify error",A),[3,12];case 12:return[2]}}))}))},e.prototype.detect=function(e,t,r,n){return i(this,arguments,void 0,(function(e,t,r,n){var i=e.providerName,a=e.rdns;return o(this,(function(e){switch(e.label){case 0:return this.session.isWalletDetected(a)?[2,u.logger.warn("Detect: Wallet ".concat(i," already detected in this session"))]:(this.session.markWalletDetected(a),[4,this.trackEvent(c.EventType.DETECT,{providerName:i,rdns:a},t,r,n)]);case 1:return e.sent(),[2]}}))}))},e.prototype.track=function(e,t,r,n){return i(this,void 0,void 0,(function(){return o(this,(function(i){switch(i.label){case 0:return[4,this.trackEvent(c.EventType.TRACK,{event:e},t,r,n)];case 1:return i.sent(),[2]}}))}))},e.prototype.trackProvider=function(e){u.logger.info("trackProvider",e);try{if(!e)return;if(this._trackedProviders.has(e))return void u.logger.warn("TrackProvider: Provider already tracked.");this.registerAccountsChangedListener(e),this.registerChainChangedListener(e),this.registerConnectListener(e),this.registerRequestListeners(e),this.registerDisconnectListener(e),this._trackedProviders.add(e)}catch(e){u.logger.error("Error tracking provider:",e)}},e.prototype.trackProviders=function(e){try{for(var t=0,r=e;t<r.length;t++){var n=r[t],i=null==n?void 0:n.provider;i&&!this._trackedProviders.has(i)&&this.trackProvider(i)}}catch(e){u.logger.error("Failed to track EIP-6963 providers during initialization:",e)}},e.prototype.addProviderListener=function(e,t,r){var n=this._providerListenersMap.get(e)||{};n[t]=r,this._providerListenersMap.set(e,n)},e.prototype.registerAccountsChangedListener=function(e){var t=this;u.logger.info("registerAccountsChangedListener");var r=function(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];return t.onAccountsChanged(e,r[0])};e.on("accountsChanged",r),this.addProviderListener(e,"accountsChanged",r)},e.prototype.onAccountsChanged=function(e,t){return i(this,void 0,void 0,(function(){return o(this,(function(r){switch(r.label){case 0:if(u.logger.info("onAccountsChanged",t),this._processingAccountsChanged)return u.logger.debug("OnAccountsChanged: Already processing accountsChanged, skipping",{provider:this.getProviderInfo(e).name}),[2];this._processingAccountsChanged=!0,r.label=1;case 1:return r.trys.push([1,,3,4]),[4,this._handleAccountsChanged(e,t)];case 2:return r.sent(),[3,4];case 3:return this._processingAccountsChanged=!1,[7];case 4:return[2]}}))}))},e.prototype._handleAccountsChanged=function(e,t){return i(this,void 0,void 0,(function(){var r,n,i,a,s,c,d,l,f,h;return o(this,(function(o){switch(o.label){case 0:if(0!==t.length)return[3,7];if(this._provider!==e)return[3,5];u.logger.info("OnAccountsChanged: Detecting disconnect, current state:",{currentAddress:this.currentAddress,currentChainId:this.currentChainId,providerMatch:this._provider===e}),o.label=1;case 1:return o.trys.push([1,3,,4]),[4,this.disconnect({chainId:this.currentChainId,address:this.currentAddress})];case 2:return o.sent(),[3,4];case 3:return r=o.sent(),u.logger.error("Failed to disconnect provider on accountsChanged",r),[3,4];case 4:return[3,6];case 5:u.logger.info("OnAccountsChanged: Ignoring disconnect for non-active provider"),o.label=6;case 6:return[2];case 7:if(!(n=this.validateAndChecksumAddress(t[0])))return u.logger.warn("onAccountsChanged: Invalid address received",t[0]),[2];if(!this._provider||this._provider===e)return[3,18];i=this.currentAddress,a=this.validateAndChecksumAddress(n),u.logger.info("OnAccountsChanged: Different provider attempting to connect",{activeProvider:this.getProviderInfo(this._provider).name,eventProvider:this.getProviderInfo(e).name,currentStoredAddress:i,newProviderAddress:a}),o.label=8;case 8:return o.trys.push([8,16,,18]),[4,this.getAccounts(this._provider)];case 9:return s=o.sent(),u.logger.info("OnAccountsChanged: Checking current provider accounts",{activeProvider:this.getProviderInfo(this._provider).name,accountsLength:s?s.length:0,accounts:s}),s&&s.length>0?a&&i&&a!==i?(u.logger.info("OnAccountsChanged: Different address detected, switching providers despite current provider having accounts",{activeProvider:this.getProviderInfo(this._provider).name,eventProvider:this.getProviderInfo(e).name,currentAddress:i,newAddress:a,reason:"Address mismatch indicates wallet switch"}),[4,this.disconnect({chainId:this.currentChainId,address:this.currentAddress})]):[3,11]:[3,13];case 10:return o.sent(),this._provider=void 0,[3,12];case 11:return u.logger.info("OnAccountsChanged: Current provider still has accounts and same address, ignoring new provider",{activeProvider:this.getProviderInfo(this._provider).name,eventProvider:this.getProviderInfo(e).name,activeProviderAccountsCount:s.length,currentAddress:i,newAddress:a}),[2];case 12:return[3,15];case 13:return u.logger.info("OnAccountsChanged: Current provider has no accounts, switching to new provider",{oldProvider:this.getProviderInfo(this._provider).name,newProvider:this.getProviderInfo(e).name,reason:"Current provider has no accounts"}),[4,this.disconnect({chainId:this.currentChainId,address:this.currentAddress})];case 14:o.sent(),this._provider=void 0,o.label=15;case 15:return[3,18];case 16:return c=o.sent(),u.logger.warn("OnAccountsChanged: Could not check current provider accounts, switching to new provider",{error:c instanceof Error?c.message:String(c),errorType:c instanceof Error?c.constructor.name:typeof c,oldProvider:this._provider?this.getProviderInfo(this._provider).name:"unknown",newProvider:this.getProviderInfo(e).name,reason:"Could not check current provider accounts"}),[4,this.disconnect({chainId:this.currentChainId,address:this.currentAddress})];case 17:return o.sent(),this._provider=void 0,[3,18];case 18:return this._provider||(this._provider=e),this._provider===e&&n===this.currentAddress?[2]:[4,this.getCurrentChainId(e)];case 19:return d=o.sent(),l=!this.currentAddress,this.currentAddress=n,this.currentChainId=d,f=this.getProviderInfo(e),u.logger.info("OnAccountsChanged: Detected wallet connection, emitting connect event",{chainId:d,address:n,wasDisconnected:l,providerName:f.name,rdns:f.rdns,hasChainId:!!d}),0===(h=d||0)&&u.logger.info("OnAccountsChanged: Using fallback chainId 0 for connect event"),this.connect({chainId:h,address:n},{providerName:f.name,rdns:f.rdns}).catch((function(e){u.logger.error("Failed to track connect event during account change:",e)})),[2]}}))}))},e.prototype.registerChainChangedListener=function(e){var t=this;u.logger.info("registerChainChangedListener");var r=function(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];return t.onChainChanged(e,r[0])};e.on("chainChanged",r),this.addProviderListener(e,"chainChanged",r)},e.prototype.onChainChanged=function(e,t){return i(this,void 0,void 0,(function(){var r;return o(this,(function(n){if(u.logger.info("onChainChanged",t),r=(0,p.parseChainId)(t),this.isProviderMismatch(e)&&this.handleProviderMismatch(e),!this.currentAddress)return u.logger.info("OnChainChanged: No current address, user appears disconnected"),[2,Promise.resolve()];this._provider||(this._provider=e),this.currentChainId=r;try{return[2,this.chain({chainId:this.currentChainId,address:this.currentAddress})]}catch(e){u.logger.error("OnChainChanged: Failed to emit chain event:",e)}return[2]}))}))},e.prototype.registerConnectListener=function(e){var t=this;u.logger.info("registerConnectListener");var r=function(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];var i=r[0];t.onConnected(e,i)};e.on("connect",r),this.addProviderListener(e,"connect",r)},e.prototype.registerDisconnectListener=function(e){var t=this;u.logger.info("registerDisconnectListener");var r=function(r){return i(t,void 0,void 0,(function(){var t;return o(this,(function(r){switch(r.label){case 0:if(this._provider!==e)return[2];u.logger.info("OnDisconnect: Wallet disconnect event received, current state:",{currentAddress:this.currentAddress,currentChainId:this.currentChainId}),r.label=1;case 1:return r.trys.push([1,3,,4]),[4,this.disconnect({chainId:this.currentChainId,address:this.currentAddress})];case 2:return r.sent(),[3,4];case 3:return t=r.sent(),u.logger.error("Error during disconnect in disconnect listener",t),[3,4];case 4:return[2]}}))}))};e.on("disconnect",r),this.addProviderListener(e,"disconnect",r)},e.prototype.onConnected=function(e,t){return i(this,void 0,void 0,(function(){var r,n,i,a,s,c,d;return o(this,(function(o){switch(o.label){case 0:u.logger.info("onConnected",t),o.label=1;case 1:return o.trys.push([1,3,,4]),(null==t?void 0:t.chainId)&&"string"==typeof t.chainId?(r=(0,p.parseChainId)(t.chainId),[4,this.getAddress(e)]):[2];case 2:return n=o.sent(),r&&n&&(i=!this.currentAddress,this._provider||(this._provider=e),(a=this._provider===e)&&(this.currentChainId=r,this.currentAddress=this.validateAndChecksumAddress(n)||void 0),a&&this.currentAddress?(c=this.getProviderInfo(e),u.logger.info("OnConnected: Detected wallet connection, emitting connect event",{chainId:r,wasDisconnected:i,providerName:c.name,rdns:c.rdns,hasChainId:!!r,isActiveProvider:a}),0===(s=r||0)&&u.logger.info("OnConnected: Using fallback chainId 0 for connect event"),this.connect({chainId:s,address:n},{providerName:c.name,rdns:c.rdns}).catch((function(e){u.logger.error("Failed to track connect event during provider connection:",e)}))):n&&!a&&(c=this.getProviderInfo(e),u.logger.debug("OnConnected: Skipping connect event for non-active provider",{chainId:r,providerName:c.name,rdns:c.rdns,isActiveProvider:a,activeProviderInfo:this._provider?this.getProviderInfo(this._provider):null}))),[3,4];case 3:return d=o.sent(),u.logger.error("Error handling connect event",d),[3,4];case 4:return[2]}}))}))},e.prototype.registerRequestListeners=function(e){var t=this;if(u.logger.info("registerRequestListeners"),e){var r=e.request;if(this.isProviderAlreadyWrapped(e,r))u.logger.info("Provider already wrapped with our SDK; skipping request wrapping.");else{var a=e.request.bind(e),s=function(r){return i(t,[r],void 0,(function(t){var r,s,c,l,f,h,p,v=this,g=t.method,y=t.params;return o(this,(function(t){switch(t.label){case 0:return Array.isArray(y)&&["eth_signTypedData_v4","personal_sign"].includes(g)?(s=this.currentChainId)?[3,2]:[4,this.getCurrentChainId(e)]:[3,6];case 1:s=t.sent(),t.label=2;case 2:r=s,i(v,void 0,void 0,(function(){return o(this,(function(e){try{this.signature(n({status:d.SignatureStatus.REQUESTED},this.buildSignatureEventPayload(g,y,void 0,r)))}catch(e){u.logger.error("Formo: Failed to track signature request",e)}return[2]}))})),t.label=3;case 3:return t.trys.push([3,5,,6]),[4,a({method:g,params:y})];case 4:return(c=t.sent())&&i(v,void 0,void 0,(function(){return o(this,(function(e){try{this.signature(n({status:d.SignatureStatus.CONFIRMED},this.buildSignatureEventPayload(g,y,c,r)))}catch(e){u.logger.error("Formo: Failed to track signature confirmation",e)}return[2]}))})),[2,c];case 5:throw l=t.sent(),4001===(null==(p=l)?void 0:p.code)&&i(v,void 0,void 0,(function(){return o(this,(function(e){try{this.signature(n({status:d.SignatureStatus.REJECTED},this.buildSignatureEventPayload(g,y,void 0,r)))}catch(e){u.logger.error("Formo: Failed to track signature rejection",e)}return[2]}))})),l;case 6:if(!Array.isArray(y)||"eth_sendTransaction"!==g||!y[0])return[3,10];i(v,void 0,void 0,(function(){var t,r;return o(this,(function(i){switch(i.label){case 0:return i.trys.push([0,2,,3]),[4,this.buildTransactionEventPayload(y,e)];case 1:return t=i.sent(),this.transaction(n({status:d.TransactionStatus.STARTED},t)),[3,3];case 2:return r=i.sent(),u.logger.error("Formo: Failed to track transaction start",r),[3,3];case 3:return[2]}}))})),t.label=7;case 7:return t.trys.push([7,9,,10]),[4,a({method:g,params:y})];case 8:return f=t.sent(),i(v,void 0,void 0,(function(){var t,r;return o(this,(function(i){switch(i.label){case 0:return i.trys.push([0,2,,3]),[4,this.buildTransactionEventPayload(y,e)];case 1:return t=i.sent(),this.transaction(n(n({status:d.TransactionStatus.BROADCASTED},t),{transactionHash:f})),this.pollTransactionReceipt(e,f,t),[3,3];case 2:return r=i.sent(),u.logger.error("Formo: Failed to track transaction broadcast",r),[3,3];case 3:return[2]}}))})),[2,f];case 9:throw h=t.sent(),4001===(null==(p=h)?void 0:p.code)&&i(v,void 0,void 0,(function(){var t,r;return o(this,(function(i){switch(i.label){case 0:return i.trys.push([0,2,,3]),[4,this.buildTransactionEventPayload(y,e)];case 1:return t=i.sent(),this.transaction(n({status:d.TransactionStatus.REJECTED},t)),[3,3];case 2:return r=i.sent(),u.logger.error("Formo: Failed to track transaction rejection",r),[3,3];case 3:return[2]}}))})),h;case 10:return[2,a({method:g,params:y})]}}))}))};s[d.WRAPPED_REQUEST_SYMBOL]=!0,e[d.WRAPPED_REQUEST_REF_SYMBOL]=s;try{e.request=s}catch(e){u.logger.warn("Failed to wrap provider.request; skipping",e)}}}else u.logger.error("Provider not found for request (signature, transaction) tracking")},e.prototype.onLocationChange=function(){return i(this,void 0,void 0,(function(){return o(this,(function(e){return(0,u.cookie)().get(c.SESSION_CURRENT_URL_KEY)!==window.location.href&&((0,u.cookie)().set(c.SESSION_CURRENT_URL_KEY,window.location.href),this.trackPageHit()),[2]}))}))},e.prototype.trackPageHits=function(){return i(this,void 0,void 0,(function(){var e,t,r=this;return o(this,(function(n){return e=history.pushState,history.pushState=function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];var n=e.apply(this,t);return window.dispatchEvent(new window.Event("locationchange")),n},t=history.replaceState,history.replaceState=function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];var n=t.apply(this,e);return window.dispatchEvent(new window.Event("locationchange")),n},window.addEventListener("popstate",(function(){return r.onLocationChange()})),window.addEventListener("locationchange",(function(){return r.onLocationChange()})),[2]}))}))},e.prototype.trackPageHit=function(e,t,r,n,a){return i(this,void 0,void 0,(function(){var s=this;return o(this,(function(d){return this.shouldTrack()?(setTimeout((function(){i(s,void 0,void 0,(function(){var i;return o(this,(function(o){switch(o.label){case 0:return o.trys.push([0,2,,3]),[4,this.trackEvent(c.EventType.PAGE,{category:e,name:t},r,n,a)];case 1:return o.sent(),[3,3];case 2:return i=o.sent(),u.logger.error("Formo: Failed to track page hit",i),[3,3];case 3:return[2]}}))}))}),300),[2]):(u.logger.info("Track page hit: Skipping event due to tracking configuration"),[2])}))}))},e.prototype.trackEvent=function(e,t,r,a,s){return i(this,void 0,void 0,(function(){return o(this,(function(i){try{if(!this.shouldTrack())return u.logger.info("Skipping ".concat(e," event due to tracking configuration")),[2];this.eventManager.addEvent(n(n({type:e},t),{properties:r,context:a,callback:s}),this.currentAddress,this.currentUserId)}catch(e){u.logger.error("Error tracking event:",e)}return[2]}))}))},e.prototype.shouldTrack=function(){if("boolean"==typeof this.options.tracking)return this.options.tracking;if(null!==this.options.tracking&&"object"==typeof this.options.tracking&&!Array.isArray(this.options.tracking)){var e=this.options.tracking,t=e.excludeHosts,r=void 0===t?[]:t,n=e.excludePaths,i=void 0===n?[]:n,o=e.excludeChains,a=void 0===o?[]:o;if(r.length>0&&"undefined"!=typeof window){var s=window.location.hostname;if(r.includes(s))return!1}if(i.length>0&&"undefined"!=typeof window){var c=window.location.pathname;if(i.includes(c))return!1}return!(a.length>0&&this.currentChainId&&a.includes(this.currentChainId))}return!(0,h.isLocalhost)()},e.prototype.getProviderInfo=function(e){var t=this._providers.find((function(t){return t.provider===e}));if(t)return{name:t.info.name,rdns:t.info.rdns};var r=this.detectInjectedProviderInfo(e);return{name:r.name,rdns:r.rdns}},e.prototype.detectInjectedProviderInfo=function(e){var t="Injected Provider",r="io.injected.provider",n=e;return n.isMetaMask?(t="MetaMask",r="io.metamask"):n.isCoinbaseWallet?(t="Coinbase Wallet",r="com.coinbase.wallet"):n.isWalletConnect?(t="WalletConnect",r="com.walletconnect"):n.isTrust?(t="Trust Wallet",r="com.trustwallet"):n.isBraveWallet?(t="Brave Wallet",r="com.brave.wallet"):n.isPhantom&&(t="Phantom",r="app.phantom"),{name:t,rdns:r,uuid:"injected-".concat(r.replace(/[^a-zA-Z0-9]/g,"-")),icon:c.DEFAULT_PROVIDER_ICON}},e.prototype.getProviders=function(){return i(this,void 0,void 0,(function(){var e,t,r,n,c,d,l,f,h,p=this;return o(this,(function(v){if(e=(0,s.createStore)(),t=e.getProviders(),e.subscribe((function(e){t=e;for(var r=e.filter((function(e){var t=null==e?void 0:e.provider;return t&&!p._seenProviders.has(t)})),n=0,a=r;n<a.length;n++){var s=a[n];p.safeAddProviderDetail(s)}var c=e.filter((function(e){var t=null==e?void 0:e.provider;return!!t&&!p._trackedProviders.has(t)}));c.length>0&&(p.trackProviders(c),i(p,void 0,void 0,(function(){var e;return o(this,(function(t){switch(t.label){case 0:return t.trys.push([0,2,,3]),[4,this.detectWallets(c)];case 1:return t.sent(),[3,3];case 2:return e=t.sent(),u.logger.error("Formo: Failed to detect wallets",e),[3,3];case 3:return[2]}}))}))),p.cleanupUnavailableProviders()})),0===t.length){if(r="undefined"!=typeof window?window.ethereum:void 0){if(this._injectedProviderDetail&&this._injectedProviderDetail.provider===r)return this._trackedProviders.has(r)||this.trackProvider(r),this._providers.some((function(e){return e.provider===r}))||(this._providers=a(a([],this._providers,!0),[this._injectedProviderDetail],!1)),[2,this._providers];this._trackedProviders.has(r)||this.trackProvider(r),n=this.detectInjectedProviderInfo(r),c={provider:r,info:n},this._injectedProviderDetail=c,this.safeAddProviderDetail(c)}return[2,this._providers]}for(d=t.filter((function(e){var t=null==e?void 0:e.provider;return t&&!p._seenProviders.has(t)})),l=0,f=d;l<f.length;l++)h=f[l],this.safeAddProviderDetail(h);return[2,this._providers]}))}))},Object.defineProperty(e.prototype,"providers",{get:function(){return this._providers},enumerable:!1,configurable:!0}),e.prototype.detectWallets=function(e){return i(this,void 0,void 0,(function(){var t,r,n,i;return o(this,(function(o){switch(o.label){case 0:o.trys.push([0,5,,6]),t=0,r=e,o.label=1;case 1:return t<r.length?(n=r[t],[4,this.detect({providerName:null==n?void 0:n.info.name,rdns:null==n?void 0:n.info.rdns})]):[3,4];case 2:o.sent(),o.label=3;case 3:return t++,[3,1];case 4:return[3,6];case 5:return i=o.sent(),u.logger.error("Error detect all wallets:",i),[3,6];case 6:return[2]}}))}))},Object.defineProperty(e.prototype,"provider",{get:function(){return this._provider},enumerable:!1,configurable:!0}),e.prototype.getAddress=function(e){return i(this,void 0,void 0,(function(){var t,r,n;return o(this,(function(i){switch(i.label){case 0:if(this.currentAddress)return[2,this.currentAddress];if(!(t=e||this.provider))return u.logger.info("The provider is not set"),[2,null];i.label=1;case 1:return i.trys.push([1,3,,4]),[4,this.getAccounts(t)];case 2:return(r=i.sent())&&r.length>0?[2,this.validateAndChecksumAddress(r[0])||null]:[3,4];case 3:return 4001!==(null==(n=i.sent())?void 0:n.code)&&u.logger.error("FormoAnalytics::getAccounts: eth_accounts threw an error",n),[2,null];case 4:return[2,null]}}))}))},e.prototype.getAccounts=function(e){return i(this,void 0,void 0,(function(){var t,r,n,i=this;return o(this,(function(o){switch(o.label){case 0:t=e||this.provider,o.label=1;case 1:return o.trys.push([1,3,,4]),[4,null==t?void 0:t.request({method:"eth_accounts"})];case 2:return(r=o.sent())&&0!==r.length?[2,r.map((function(e){return i.validateAndChecksumAddress(e)})).filter((function(e){return void 0!==e}))]:[2,null];case 3:return 4001!==(null==(n=o.sent())?void 0:n.code)&&u.logger.error("FormoAnalytics::getAccounts: eth_accounts threw an error",n),[2,null];case 4:return[2]}}))}))},e.prototype.getCurrentChainId=function(e){return i(this,void 0,void 0,(function(){var t,r,n;return o(this,(function(i){switch(i.label){case 0:if(!(t=e||this.provider))return u.logger.error("Provider not set for chain ID"),[2,0];i.label=1;case 1:return i.trys.push([1,3,,4]),[4,t.request({method:"eth_chainId"})];case 2:return(r=i.sent())?[2,(0,p.parseChainId)(r)]:(u.logger.info("Chain id not found"),[2,0]);case 3:return n=i.sent(),u.logger.error("eth_chainId threw an error:",n),[2,0];case 4:return[2]}}))}))},e.prototype.buildSignatureEventPayload=function(e,t,r,i){var o,a="personal_sign"===e?t[1]:t[0],s=this.validateAndChecksumAddress(a);if(!s)throw new Error("Invalid address in signature payload: ".concat(a));var c={chainId:null!==(o=null!=i?i:this.currentChainId)&&void 0!==o?o:void 0,address:s};if("personal_sign"===e){var u=Buffer.from(t[0].slice(2),"hex").toString("utf8");return n(n(n({},c),{message:u}),r?{signatureHash:r}:{})}return n(n(n({},c),{message:t[1]}),r?{signatureHash:r}:{})},e.prototype.buildTransactionEventPayload=function(e,t){return i(this,void 0,void 0,(function(){var r,n,i,a,s,c,u,d;return o(this,(function(o){switch(o.label){case 0:if(r=e[0],n=r.data,i=r.from,a=r.to,s=r.value,!(c=this.validateAndChecksumAddress(i)))throw new Error("Invalid address in transaction payload: ".concat(i));return d={},(u=this.currentChainId)?[3,2]:[4,this.getCurrentChainId(t)];case 1:u=o.sent(),o.label=2;case 2:return[2,(d.chainId=u,d.data=n,d.address=c,d.to=a,d.value=s,d)]}}))}))},e.prototype.pollTransactionReceipt=function(e,t,r){return i(this,arguments,void 0,(function(e,t,r,a,s){var c,l,f=this;return void 0===a&&(a=10),void 0===s&&(s=3e3),o(this,(function(h){return c=0,e?(l=function(){return i(f,void 0,void 0,(function(){var i,f;return o(this,(function(o){switch(o.label){case 0:return o.trys.push([0,2,,3]),[4,e.request({method:"eth_getTransactionReceipt",params:[t]})];case 1:if(i=o.sent()){if("0x1"===i.status||1===i.status)return this.transaction(n(n({status:d.TransactionStatus.CONFIRMED},r),{transactionHash:t})),[2];if("0x0"===i.status||0===i.status)return this.transaction(n(n({status:d.TransactionStatus.REVERTED},r),{transactionHash:t})),[2]}return[3,3];case 2:return f=o.sent(),u.logger.error("Error polling transaction receipt",f),[3,3];case 3:return++c<a&&setTimeout(l,s),[2]}}))}))},l(),[2]):[2]}))}))},e.prototype.removeProviderListeners=function(e){var t=this._providerListenersMap.get(e);if(t){for(var r=0,n=Object.entries(t);r<n.length;r++){var i=n[r],o=i[0],a=i[1];try{e.removeListener(o,a)}catch(e){u.logger.warn("Failed to remove listener for ".concat(String(o)),e)}}this._providerListenersMap.delete(e)}},e.prototype.untrackProvider=function(e){try{this.removeProviderListeners(e),this._trackedProviders.delete(e),this._provider===e&&(this._provider=void 0)}catch(e){u.logger.warn("Failed to untrack provider",e)}},e.prototype.getTrackedProvidersCount=function(){return this._trackedProviders.size},e.prototype.getProviderState=function(){return{totalProviders:this._providers.length,trackedProviders:this._trackedProviders.size,seenProviders:this._seenProviders.size,activeProvider:!!this._provider}},e.prototype.cleanupUnavailableProviders=function(){for(var e=new Set(this._providers.map((function(e){return e.provider}))),t=0,r=Array.from(this._trackedProviders);t<r.length;t++){var n=r[t];e.has(n)||(u.logger.info("Cleaning up unavailable provider: ".concat(n.constructor.name)),this.untrackProvider(n))}},e.prototype.isProviderAlreadyWrapped=function(e,t){return!(!t||"function"!=typeof t||!t[d.WRAPPED_REQUEST_SYMBOL]||e[d.WRAPPED_REQUEST_REF_SYMBOL]!==t)},e.prototype.handleProviderMismatch=function(e){this._provider&&(this.currentChainId=void 0,this.currentAddress=void 0),this._provider=e},e.prototype.validateAndChecksumAddress=function(e){var t=(0,f.getValidAddress)(e);return t?(0,l.toChecksumAddress)(t):void 0},e.prototype.safeAddProviderDetail=function(e){var t=null==e?void 0:e.provider;return!!t&&(this._providers.some((function(e){return e.provider===t}))?(this._seenProviders.add(t),!1):(this._providers=a(a([],this._providers,!0),[e],!1),this._seenProviders.add(t),!0))},e}();t.FormoAnalytics=v;var g=function(){function e(){}return e.prototype.isWalletDetected=function(e){var t;return((null===(t=(0,u.cookie)().get(c.SESSION_WALLET_DETECTED_KEY))||void 0===t?void 0:t.split(","))||[]).includes(e)},e.prototype.markWalletDetected=function(e){var t,r=(null===(t=(0,u.cookie)().get(c.SESSION_WALLET_DETECTED_KEY))||void 0===t?void 0:t.split(","))||[];r.push(e),(0,u.cookie)().set(c.SESSION_WALLET_DETECTED_KEY,r.join(","),{expires:new Date(Date.now()+864e5).toUTCString(),path:"/"})},e}()},922:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.toChecksumAddress=t.getValidAddress=t.isValidAddress=void 0;var n=r(2019),i=r(2672),o=r(9754),a=r(4811),s=function(e){return"string"==typeof e&&""!==e.trim()&&(0,o.isAddress)(e.trim())?e.trim():null};t.isValidAddress=function(e){return null!==s(e)},t.getValidAddress=function(e){return s(e)},t.toChecksumAddress=function(e){if(!(0,o.isAddress)(e,!1))throw new Error("Invalid address "+e);var t=e.toLowerCase().replace(/^0x/i,""),r=(0,o.uint8ArrayToHexString)((0,n.keccak256)((0,o.ensureIfUint8Array)((0,i.utf8ToBytes)(t))));if((0,a.isNullish)(r)||"0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470"===r)return"";for(var s="0x",c=r.replace(/^0x/i,""),u=0;u<t.length;u+=1)parseInt(c[u],16)>7?s+=t[u].toUpperCase():s+=t[u];return s}},1020:(e,t,r)=>{"use strict";var n=r(6540),i=Symbol.for("react.element"),o=Symbol.for("react.fragment"),a=Object.prototype.hasOwnProperty,s=n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,c={key:!0,ref:!0,__self:!0,__source:!0};function u(e,t,r){var n,o={},u=null,d=null;for(n in void 0!==r&&(u=""+r),void 0!==t.key&&(u=""+t.key),void 0!==t.ref&&(d=t.ref),t)a.call(t,n)&&!c.hasOwnProperty(n)&&(o[n]=t[n]);if(e&&e.defaultProps)for(n in t=e.defaultProps)void 0===o[n]&&(o[n]=t[n]);return{$$typeof:i,type:e,key:u,ref:d,props:o,_owner:s.current}}t.Fragment=o,t.jsx=u,t.jsxs=u},1371:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},1388:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.StorageManager=void 0;var i=r(8177),o=n(r(8341)),a=n(r(1968)),s=n(r(6073)),c=["cookieStorage","localStorage","sessionStorage","memoryStorage"],u=function(){function e(e){this.writeKey=e,this.storages=new Map}return e.prototype.getStorage=function(e){if(!this.storages.has(e)){for(var t=this.createStorage(e);!t.isAvailable();){var r=c.indexOf(e);i.logger.warn("Storage ".concat(e," is not available, trying ").concat(c[r+1])),t=this.createStorage(c[r+1])}this.storages.set(e,t)}return this.storages.get(e)},e.prototype.createStorage=function(e){switch(e){case"cookieStorage":return new o.default(this.writeKey);case"localStorage":return new s.default(this.writeKey,localStorage);case"sessionStorage":return new s.default(this.writeKey,sessionStorage);default:return new a.default(this.writeKey)}},e}();t.StorageManager=u},1466:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var i=n(r(654)),o=n(r(9615)),a=(0,i.default)((function(e,t){return(0,o.default)((function(e,t,r){return r}),e,t)}));t.default=a},1484:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.notImplemented=t.bitMask=void 0,t.isBytes=i,t.abytes=o,t.abool=function(e,t){if("boolean"!=typeof t)throw new Error(e+" boolean expected, got "+t)},t.numberToHexUnpadded=a,t.hexToNumber=s,t.bytesToHex=d,t.hexToBytes=h,t.bytesToNumberBE=function(e){return s(d(e))},t.bytesToNumberLE=function(e){return o(e),s(d(Uint8Array.from(e).reverse()))},t.numberToBytesBE=p,t.numberToBytesLE=function(e,t){return p(e,t).reverse()},t.numberToVarBytesBE=function(e){return h(a(e))},t.ensureBytes=function(e,t,r){let n;if("string"==typeof t)try{n=h(t)}catch(t){throw new Error(e+" must be hex string or Uint8Array, cause: "+t)}else{if(!i(t))throw new Error(e+" must be hex string or Uint8Array");n=Uint8Array.from(t)}const o=n.length;if("number"==typeof r&&o!==r)throw new Error(e+" of length "+r+" expected, got "+o);return n},t.concatBytes=v,t.equalBytes=function(e,t){if(e.length!==t.length)return!1;let r=0;for(let n=0;n<e.length;n++)r|=e[n]^t[n];return 0===r},t.utf8ToBytes=function(e){if("string"!=typeof e)throw new Error("string expected");return new Uint8Array((new TextEncoder).encode(e))},t.inRange=y,t.aInRange=function(e,t,r,n){if(!y(t,r,n))throw new Error("expected valid "+e+": "+r+" <= n < "+n+", got "+t)},t.bitLen=function(e){let t;for(t=0;e>r;e>>=n,t+=1);return t},t.bitGet=function(e,t){return e>>BigInt(t)&n},t.bitSet=function(e,t,i){return e|(i?n:r)<<BigInt(t)},t.createHmacDrbg=function(e,t,r){if("number"!=typeof e||e<2)throw new Error("hashLen must be a number");if("number"!=typeof t||t<2)throw new Error("qByteLen must be a number");if("function"!=typeof r)throw new Error("hmacFn must be a function");let n=A(e),i=A(e),o=0;const a=()=>{n.fill(1),i.fill(0),o=0},s=(...e)=>r(i,n,...e),c=(e=A(0))=>{i=s(m([0]),e),n=s(),0!==e.length&&(i=s(m([1]),e),n=s())},u=()=>{if(o++>=1e3)throw new Error("drbg: tried 1000 values");let e=0;const r=[];for(;e<t;){n=s();const t=n.slice();r.push(t),e+=n.length}return v(...r)};return(e,t)=>{let r;for(a(),c(e);!(r=t(u()));)c();return a(),r}},t.validateObject=function(e,t,r={}){const n=(t,r,n)=>{const i=_[r];if("function"!=typeof i)throw new Error("invalid validator function");const o=e[t];if(!(n&&void 0===o||i(o,e)))throw new Error("param "+String(t)+" is invalid. Expected "+r+", got "+o)};for(const[e,r]of Object.entries(t))n(e,r,!1);for(const[e,t]of Object.entries(r))n(e,t,!0);return e},t.memoized=function(e){const t=new WeakMap;return(r,...n)=>{const i=t.get(r);if(void 0!==i)return i;const o=e(r,...n);return t.set(r,o),o}};const r=BigInt(0),n=BigInt(1);function i(e){return e instanceof Uint8Array||ArrayBuffer.isView(e)&&"Uint8Array"===e.constructor.name}function o(e){if(!i(e))throw new Error("Uint8Array expected")}function a(e){const t=e.toString(16);return 1&t.length?"0"+t:t}function s(e){if("string"!=typeof e)throw new Error("hex string expected, got "+typeof e);return""===e?r:BigInt("0x"+e)}const c="function"==typeof Uint8Array.from([]).toHex&&"function"==typeof Uint8Array.fromHex,u=Array.from({length:256},((e,t)=>t.toString(16).padStart(2,"0")));function d(e){if(o(e),c)return e.toHex();let t="";for(let r=0;r<e.length;r++)t+=u[e[r]];return t}const l={_0:48,_9:57,A:65,F:70,a:97,f:102};function f(e){return e>=l._0&&e<=l._9?e-l._0:e>=l.A&&e<=l.F?e-(l.A-10):e>=l.a&&e<=l.f?e-(l.a-10):void 0}function h(e){if("string"!=typeof e)throw new Error("hex string expected, got "+typeof e);if(c)return Uint8Array.fromHex(e);const t=e.length,r=t/2;if(t%2)throw new Error("hex string expected, got unpadded hex of length "+t);const n=new Uint8Array(r);for(let t=0,i=0;t<r;t++,i+=2){const r=f(e.charCodeAt(i)),o=f(e.charCodeAt(i+1));if(void 0===r||void 0===o){const t=e[i]+e[i+1];throw new Error('hex string expected, got non-hex character "'+t+'" at index '+i)}n[t]=16*r+o}return n}function p(e,t){return h(e.toString(16).padStart(2*t,"0"))}function v(...e){let t=0;for(let r=0;r<e.length;r++){const n=e[r];o(n),t+=n.length}const r=new Uint8Array(t);for(let t=0,n=0;t<e.length;t++){const i=e[t];r.set(i,n),n+=i.length}return r}const g=e=>"bigint"==typeof e&&r<=e;function y(e,t,r){return g(e)&&g(t)&&g(r)&&t<=e&&e<r}t.bitMask=e=>(n<<BigInt(e))-n;const A=e=>new Uint8Array(e),m=e=>Uint8Array.from(e),_={bigint:e=>"bigint"==typeof e,function:e=>"function"==typeof e,boolean:e=>"boolean"==typeof e,string:e=>"string"==typeof e,stringOrUint8Array:e=>"string"==typeof e||i(e),isSafeInteger:e=>Number.isSafeInteger(e),array:e=>Array.isArray(e),field:(e,t)=>t.Fp.isValid(e),hash:e=>"function"==typeof e&&Number.isSafeInteger(e.outputLen)};t.notImplemented=()=>{throw new Error("not implemented")}},1565:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},1934:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},1968:function(e,t,r){"use strict";var n,i=this&&this.__extends||(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},n(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var a=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.memoryStorage={},t}return i(t,e),t.prototype.isAvailable=function(){return!0},t.prototype.set=function(e,t){this.memoryStorage[this.getKey(e)]=t},t.prototype.get=function(e){return this.memoryStorage[this.getKey(e)]||null},t.prototype.remove=function(e){delete this.memoryStorage[this.getKey(e)]},t}(o(r(2200)).default);t.default=a},2019:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.keccak512=t.keccak384=t.keccak256=t.keccak224=void 0;const n=r(2955),i=r(2672);t.keccak224=(0,i.wrapHash)(n.keccak_224),t.keccak256=(()=>{const e=(0,i.wrapHash)(n.keccak_256);return e.create=n.keccak_256.create,e})(),t.keccak384=(0,i.wrapHash)(n.keccak_384),t.keccak512=(0,i.wrapHash)(n.keccak_512)},2066:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return"[object Object]"===Object.prototype.toString.call(e)}},2200:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7532),i=function(){function e(e){this.writeKey=e}return e.prototype.getKey=function(e){return"".concat(n.KEY_PREFIX,"_").concat(this.writeKey,".").concat(e)},e}();t.default=i},2309:(e,t)=>{"use strict";var r,n;Object.defineProperty(t,"__esModule",{value:!0}),t.EventChannel=t.EventType=void 0,function(e){e.PAGE="page",e.IDENTIFY="identify",e.DETECT="detect",e.CONNECT="connect",e.DISCONNECT="disconnect",e.CHAIN="chain",e.SIGNATURE="signature",e.TRANSACTION="transaction",e.TRACK="track"}(r||(t.EventType=r={})),function(e){e.WEB="web",e.MOBILE="mobile",e.SERVER="server",e.SOURCE="source"}(n||(t.EventChannel=n={}))},2317:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.requestProviders=t.announceProvider=void 0,t.announceProvider=function(e){const t=new CustomEvent("eip6963:announceProvider",{detail:Object.freeze(e)});window.dispatchEvent(t);const r=()=>window.dispatchEvent(t);return window.addEventListener("eip6963:requestProvider",r),()=>window.removeEventListener("eip6963:requestProvider",r)},t.requestProviders=function(e){if("undefined"==typeof window)return;const t=t=>e(t.detail);return window.addEventListener("eip6963:announceProvider",t),window.dispatchEvent(new CustomEvent("eip6963:requestProvider")),()=>window.removeEventListener("eip6963:announceProvider",t)}},2318:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.toBig=t.shrSL=t.shrSH=t.rotrSL=t.rotrSH=t.rotrBL=t.rotrBH=t.rotr32L=t.rotr32H=t.rotlSL=t.rotlSH=t.rotlBL=t.rotlBH=t.add5L=t.add5H=t.add4L=t.add4H=t.add3L=t.add3H=void 0,t.add=m,t.fromBig=i,t.split=o;const r=BigInt(2**32-1),n=BigInt(32);function i(e,t=!1){return t?{h:Number(e&r),l:Number(e>>n&r)}:{h:0|Number(e>>n&r),l:0|Number(e&r)}}function o(e,t=!1){const r=e.length;let n=new Uint32Array(r),o=new Uint32Array(r);for(let a=0;a<r;a++){const{h:r,l:s}=i(e[a],t);[n[a],o[a]]=[r,s]}return[n,o]}const a=(e,t)=>BigInt(e>>>0)<<n|BigInt(t>>>0);t.toBig=a;const s=(e,t,r)=>e>>>r;t.shrSH=s;const c=(e,t,r)=>e<<32-r|t>>>r;t.shrSL=c;const u=(e,t,r)=>e>>>r|t<<32-r;t.rotrSH=u;const d=(e,t,r)=>e<<32-r|t>>>r;t.rotrSL=d;const l=(e,t,r)=>e<<64-r|t>>>r-32;t.rotrBH=l;const f=(e,t,r)=>e>>>r-32|t<<64-r;t.rotrBL=f;const h=(e,t)=>t;t.rotr32H=h;const p=(e,t)=>e;t.rotr32L=p;const v=(e,t,r)=>e<<r|t>>>32-r;t.rotlSH=v;const g=(e,t,r)=>t<<r|e>>>32-r;t.rotlSL=g;const y=(e,t,r)=>t<<r-32|e>>>64-r;t.rotlBH=y;const A=(e,t,r)=>e<<r-32|t>>>64-r;function m(e,t,r,n){const i=(t>>>0)+(n>>>0);return{h:e+r+(i/2**32|0)|0,l:0|i}}t.rotlBL=A;const _=(e,t,r)=>(e>>>0)+(t>>>0)+(r>>>0);t.add3L=_;const b=(e,t,r,n)=>t+r+n+(e/2**32|0)|0;t.add3H=b;const E=(e,t,r,n)=>(e>>>0)+(t>>>0)+(r>>>0)+(n>>>0);t.add4L=E;const w=(e,t,r,n,i)=>t+r+n+i+(e/2**32|0)|0;t.add4H=w;const S=(e,t,r,n,i)=>(e>>>0)+(t>>>0)+(r>>>0)+(n>>>0)+(i>>>0);t.add5L=S;const P=(e,t,r,n,i,o)=>t+r+n+i+o+(e/2**32|0)|0;t.add5H=P;const C={fromBig:i,split:o,toBig:a,shrSH:s,shrSL:c,rotrSH:u,rotrSL:d,rotrBH:l,rotrBL:f,rotr32H:h,rotr32L:p,rotlSH:v,rotlSL:g,rotlBH:y,rotlBL:A,add:m,add3L:_,add3H:b,add4L:E,add4H:w,add5H:P,add5L:S};t.default=C},2672:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.assertBytes=t.assertBool=t.utf8ToBytes=t.toHex=t.createView=t.concatBytes=t.bytesToHex=void 0,t.bytesToUtf8=function(e){if(!(e instanceof Uint8Array))throw new TypeError("bytesToUtf8 expected Uint8Array, got "+typeof e);return(new TextDecoder).decode(e)},t.hexToBytes=function(e){const t=e.startsWith("0x")?e.substring(2):e;return(0,o.hexToBytes)(t)},t.equalsBytes=function(e,t){if(e.length!==t.length)return!1;for(let r=0;r<e.length;r++)if(e[r]!==t[r])return!1;return!0},t.wrapHash=function(e){return t=>((0,i.abytes)(t),e(t))};const n=r(1484);Object.defineProperty(t,"assertBool",{enumerable:!0,get:function(){return n.abool}});const i=r(7557);Object.defineProperty(t,"assertBytes",{enumerable:!0,get:function(){return i.abytes}});const o=r(9175);var a=r(9175);Object.defineProperty(t,"bytesToHex",{enumerable:!0,get:function(){return a.bytesToHex}}),Object.defineProperty(t,"concatBytes",{enumerable:!0,get:function(){return a.concatBytes}}),Object.defineProperty(t,"createView",{enumerable:!0,get:function(){return a.createView}}),Object.defineProperty(t,"toHex",{enumerable:!0,get:function(){return a.bytesToHex}}),Object.defineProperty(t,"utf8ToBytes",{enumerable:!0,get:function(){return a.utf8ToBytes}})},2865:function(e,t){"use strict";var r=this&&this.__spreadArray||function(e,t,r){if(r||2===arguments.length)for(var n,i=0,o=t.length;i<o;i++)!n&&i in t||(n||(n=Array.prototype.slice.call(t,0,i)),n[i]=t[i]);return e.concat(n||Array.prototype.slice.call(t))};Object.defineProperty(t,"__esModule",{value:!0}),t.logger=t.Logger=void 0;var n=function(){function e(e,t){void 0===e&&(e=!1),void 0===t&&(t=[]),this.enabled=e,this.enabledLevels=new Set(t)}return e.init=function(t){var r=e.getInstance();void 0!==t.enabled&&r.setEnabled(t.enabled),void 0!==t.enabledLevels&&r.setEnabledLevels(t.enabledLevels)},e.getInstance=function(t){var r,n;return e.instance||(e.instance=new e(null!==(r=null==t?void 0:t.enabled)&&void 0!==r&&r,null!==(n=null==t?void 0:t.enabledLevels)&&void 0!==n?n:[])),e.instance},e.prototype.setEnabled=function(e){this.enabled=e},e.prototype.isLoggingEnabled=function(){return this.enabled},e.prototype.setEnabledLevels=function(e){this.enabledLevels=new Set(e)},e.prototype.getEnabledLevels=function(){return Array.from(this.enabledLevels)},e.prototype.shouldLog=function(e){return!!this.enabled&&this.enabledLevels.has(e)},e.prototype.formatMessage=function(e){var t=(new Date).toLocaleString("en-US",{year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",hour12:!1});return"[Formo SDK][".concat(t,"] ").concat(e)},e.prototype.debug=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];this.shouldLog("debug")&&console.debug.apply(console,r([this.formatMessage(e)],t,!1))},e.prototype.info=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];this.shouldLog("info")&&console.info.apply(console,r([this.formatMessage(e)],t,!1))},e.prototype.warn=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];this.shouldLog("warn")&&console.warn.apply(console,r([this.formatMessage(e)],t,!1))},e.prototype.error=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];this.shouldLog("error")&&console.error.apply(console,r([this.formatMessage(e)],t,!1))},e.prototype.trace=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];this.shouldLog("trace")&&console.trace.apply(console,r([this.formatMessage(e)],t,!1))},e.prototype.log=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];this.info.apply(this,r([e],t,!1))},e}();t.Logger=n,t.logger=n.getInstance()},2955:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.shake256=t.shake128=t.keccak_512=t.keccak_384=t.keccak_256=t.keccak_224=t.sha3_512=t.sha3_384=t.sha3_256=t.sha3_224=t.Keccak=void 0,t.keccakP=m;const n=r(2318),i=r(9175),o=BigInt(0),a=BigInt(1),s=BigInt(2),c=BigInt(7),u=BigInt(256),d=BigInt(113),l=[],f=[],h=[];for(let e=0,t=a,r=1,n=0;e<24;e++){[r,n]=[n,(2*r+3*n)%5],l.push(2*(5*n+r)),f.push((e+1)*(e+2)/2%64);let i=o;for(let e=0;e<7;e++)t=(t<<a^(t>>c)*d)%u,t&s&&(i^=a<<(a<<BigInt(e))-a);h.push(i)}const p=(0,n.split)(h,!0),v=p[0],g=p[1],y=(e,t,r)=>r>32?(0,n.rotlBH)(e,t,r):(0,n.rotlSH)(e,t,r),A=(e,t,r)=>r>32?(0,n.rotlBL)(e,t,r):(0,n.rotlSL)(e,t,r);function m(e,t=24){const r=new Uint32Array(10);for(let n=24-t;n<24;n++){for(let t=0;t<10;t++)r[t]=e[t]^e[t+10]^e[t+20]^e[t+30]^e[t+40];for(let t=0;t<10;t+=2){const n=(t+8)%10,i=(t+2)%10,o=r[i],a=r[i+1],s=y(o,a,1)^r[n],c=A(o,a,1)^r[n+1];for(let r=0;r<50;r+=10)e[t+r]^=s,e[t+r+1]^=c}let t=e[2],i=e[3];for(let r=0;r<24;r++){const n=f[r],o=y(t,i,n),a=A(t,i,n),s=l[r];t=e[s],i=e[s+1],e[s]=o,e[s+1]=a}for(let t=0;t<50;t+=10){for(let n=0;n<10;n++)r[n]=e[t+n];for(let n=0;n<10;n++)e[t+n]^=~r[(n+2)%10]&r[(n+4)%10]}e[0]^=v[n],e[1]^=g[n]}(0,i.clean)(r)}class _ extends i.Hash{constructor(e,t,r,n=!1,o=24){if(super(),this.pos=0,this.posOut=0,this.finished=!1,this.destroyed=!1,this.enableXOF=!1,this.blockLen=e,this.suffix=t,this.outputLen=r,this.enableXOF=n,this.rounds=o,(0,i.anumber)(r),!(0<e&&e<200))throw new Error("only keccak-f1600 function is supported");this.state=new Uint8Array(200),this.state32=(0,i.u32)(this.state)}clone(){return this._cloneInto()}keccak(){(0,i.swap32IfBE)(this.state32),m(this.state32,this.rounds),(0,i.swap32IfBE)(this.state32),this.posOut=0,this.pos=0}update(e){(0,i.aexists)(this),e=(0,i.toBytes)(e),(0,i.abytes)(e);const{blockLen:t,state:r}=this,n=e.length;for(let i=0;i<n;){const o=Math.min(t-this.pos,n-i);for(let t=0;t<o;t++)r[this.pos++]^=e[i++];this.pos===t&&this.keccak()}return this}finish(){if(this.finished)return;this.finished=!0;const{state:e,suffix:t,pos:r,blockLen:n}=this;e[r]^=t,128&t&&r===n-1&&this.keccak(),e[n-1]^=128,this.keccak()}writeInto(e){(0,i.aexists)(this,!1),(0,i.abytes)(e),this.finish();const t=this.state,{blockLen:r}=this;for(let n=0,i=e.length;n<i;){this.posOut>=r&&this.keccak();const o=Math.min(r-this.posOut,i-n);e.set(t.subarray(this.posOut,this.posOut+o),n),this.posOut+=o,n+=o}return e}xofInto(e){if(!this.enableXOF)throw new Error("XOF is not possible for this instance");return this.writeInto(e)}xof(e){return(0,i.anumber)(e),this.xofInto(new Uint8Array(e))}digestInto(e){if((0,i.aoutput)(e,this),this.finished)throw new Error("digest() was already called");return this.writeInto(e),this.destroy(),e}digest(){return this.digestInto(new Uint8Array(this.outputLen))}destroy(){this.destroyed=!0,(0,i.clean)(this.state)}_cloneInto(e){const{blockLen:t,suffix:r,outputLen:n,rounds:i,enableXOF:o}=this;return e||(e=new _(t,r,n,o,i)),e.state32.set(this.state32),e.pos=this.pos,e.posOut=this.posOut,e.finished=this.finished,e.rounds=i,e.suffix=r,e.outputLen=n,e.enableXOF=o,e.destroyed=this.destroyed,e}}t.Keccak=_;const b=(e,t,r)=>(0,i.createHasher)((()=>new _(t,e,r)));t.sha3_224=b(6,144,28),t.sha3_256=b(6,136,32),t.sha3_384=b(6,104,48),t.sha3_512=b(6,72,64),t.keccak_224=b(1,144,28),t.keccak_256=b(1,136,32),t.keccak_384=b(1,104,48),t.keccak_512=b(1,72,64);const E=(e,t,r)=>(0,i.createXOFer)(((n={})=>new _(t,e,void 0===n.dkLen?r:n.dkLen,!0)));t.shake128=E(31,168,16),t.shake256=E(31,136,32)},2970:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.formofy=function(e,t){e&&"undefined"!=typeof window?n.FormoAnalytics.init(e,t).then((function(e){if(window.formo=e,null==t?void 0:t.ready)try{t.ready(e)}catch(e){console.error("Error in FormoAnalytics ready callback:",e)}})).catch((function(e){return console.error("Error initializing FormoAnalytics:",e)})):console.warn("FormoAnalytics not found")};var n=r(879)},3113:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isUint8Array=function(e){var t,r;return e instanceof Uint8Array||"Uint8Array"===(null===(t=null==e?void 0:e.constructor)||void 0===t?void 0:t.name)||"Buffer"===(null===(r=null==e?void 0:e.constructor)||void 0===r?void 0:r.name)},t.uint8ArrayToHexString=function(e){for(var t="0x",r=0,n=e;r<n.length;r++){var i=n[r].toString(16);t+=1===i.length?"0".concat(i):i}return t}},3318:function(e){e.exports=function(){"use strict";function e(e){return Number.isInteger(e)&&e>=0}function t(e){this.name="ArgumentError",this.message=e}return function(r,n){if(n=n||{},"function"!=typeof r)throw new t("fetch must be a function");if("object"!=typeof n)throw new t("defaults must be an object");if(void 0!==n.retries&&!e(n.retries))throw new t("retries must be a positive integer");if(void 0!==n.retryDelay&&!e(n.retryDelay)&&"function"!=typeof n.retryDelay)throw new t("retryDelay must be a positive integer or a function returning a positive integer");if(void 0!==n.retryOn&&!Array.isArray(n.retryOn)&&"function"!=typeof n.retryOn)throw new t("retryOn property expects an array or function");return n=Object.assign({retries:3,retryDelay:1e3,retryOn:[]},n),function(i,o){var a=n.retries,s=n.retryDelay,c=n.retryOn;if(o&&void 0!==o.retries){if(!e(o.retries))throw new t("retries must be a positive integer");a=o.retries}if(o&&void 0!==o.retryDelay){if(!e(o.retryDelay)&&"function"!=typeof o.retryDelay)throw new t("retryDelay must be a positive integer or a function returning a positive integer");s=o.retryDelay}if(o&&o.retryOn){if(!Array.isArray(o.retryOn)&&"function"!=typeof o.retryOn)throw new t("retryOn property expects an array or function");c=o.retryOn}return new Promise((function(e,t){var n=function(n){var s="undefined"!=typeof Request&&i instanceof Request?i.clone():i;r(s,o).then((function(r){if(Array.isArray(c)&&-1===c.indexOf(r.status))e(r);else if("function"==typeof c)try{return Promise.resolve(c(n,null,r)).then((function(t){t?u(n,null,r):e(r)})).catch(t)}catch(e){t(e)}else n<a?u(n,null,r):e(r)})).catch((function(e){if("function"==typeof c)try{Promise.resolve(c(n,e,null)).then((function(r){r?u(n,e,null):t(e)})).catch((function(e){t(e)}))}catch(e){t(e)}else n<a?u(n,e,null):t(e)}))};function u(e,t,r){var i="function"==typeof s?s(e,t,r):s;setTimeout((function(){n(++e)}),i)}n(0)}))}}}()},3358:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.COUNTRY_LIST=t.EVENTS_API_REQUEST_HEADER=t.USER_API_URL=t.EVENTS_API_URL=t.EVENTS_API_HOST=void 0,t.EVENTS_API_HOST="https://events.formo.so",t.EVENTS_API_URL="".concat(t.EVENTS_API_HOST,"/v0/raw_events"),t.USER_API_URL="".concat(t.EVENTS_API_HOST,"/user"),t.EVENTS_API_REQUEST_HEADER=function(e){return{"Content-Type":"application/json",Authorization:"Basic ".concat(e)}},t.COUNTRY_LIST={"Africa/Abidjan":"CI","Africa/Accra":"GH","Africa/Addis_Ababa":"ET","Africa/Algiers":"DZ","Africa/Asmara":"ER","Africa/Asmera":"ER","Africa/Bamako":"ML","Africa/Bangui":"CF","Africa/Banjul":"GM","Africa/Bissau":"GW","Africa/Blantyre":"MW","Africa/Brazzaville":"CG","Africa/Bujumbura":"BI","Africa/Cairo":"EG","Africa/Casablanca":"MA","Africa/Ceuta":"ES","Africa/Conakry":"GN","Africa/Dakar":"SN","Africa/Dar_es_Salaam":"TZ","Africa/Djibouti":"DJ","Africa/Douala":"CM","Africa/El_Aaiun":"EH","Africa/Freetown":"SL","Africa/Gaborone":"BW","Africa/Harare":"ZW","Africa/Johannesburg":"ZA","Africa/Juba":"SS","Africa/Kampala":"UG","Africa/Khartoum":"SD","Africa/Kigali":"RW","Africa/Kinshasa":"CD","Africa/Lagos":"NG","Africa/Libreville":"GA","Africa/Lome":"TG","Africa/Luanda":"AO","Africa/Lubumbashi":"CD","Africa/Lusaka":"ZM","Africa/Malabo":"GQ","Africa/Maputo":"MZ","Africa/Maseru":"LS","Africa/Mbabane":"SZ","Africa/Mogadishu":"SO","Africa/Monrovia":"LR","Africa/Nairobi":"KE","Africa/Ndjamena":"TD","Africa/Niamey":"NE","Africa/Nouakchott":"MR","Africa/Ouagadougou":"BF","Africa/Porto-Novo":"BJ","Africa/Sao_Tome":"ST","Africa/Timbuktu":"ML","Africa/Tripoli":"LY","Africa/Tunis":"TN","Africa/Windhoek":"NA","America/Adak":"US","America/Anchorage":"US","America/Anguilla":"AI","America/Antigua":"AG","America/Araguaina":"BR","America/Argentina/Buenos_Aires":"AR","America/Argentina/Catamarca":"AR","America/Argentina/ComodRivadavia":"AR","America/Argentina/Cordoba":"AR","America/Argentina/Jujuy":"AR","America/Argentina/La_Rioja":"AR","America/Argentina/Mendoza":"AR","America/Argentina/Rio_Gallegos":"AR","America/Argentina/Salta":"AR","America/Argentina/San_Juan":"AR","America/Argentina/San_Luis":"AR","America/Argentina/Tucuman":"AR","America/Argentina/Ushuaia":"AR","America/Aruba":"AW","America/Asuncion":"PY","America/Atikokan":"CA","America/Atka":"US","America/Bahia":"BR","America/Bahia_Banderas":"MX","America/Barbados":"BB","America/Belem":"BR","America/Belize":"BZ","America/Blanc-Sablon":"CA","America/Boa_Vista":"BR","America/Bogota":"CO","America/Boise":"US","America/Buenos_Aires":"AR","America/Cambridge_Bay":"CA","America/Campo_Grande":"BR","America/Cancun":"MX","America/Caracas":"VE","America/Catamarca":"AR","America/Cayenne":"GF","America/Cayman":"KY","America/Chicago":"US","America/Chihuahua":"MX","America/Ciudad_Juarez":"MX","America/Coral_Harbour":"CA","America/Cordoba":"AR","America/Costa_Rica":"CR","America/Creston":"CA","America/Cuiaba":"BR","America/Curacao":"CW","America/Danmarkshavn":"GL","America/Dawson":"CA","America/Dawson_Creek":"CA","America/Denver":"US","America/Detroit":"US","America/Dominica":"DM","America/Edmonton":"CA","America/Eirunepe":"BR","America/El_Salvador":"SV","America/Ensenada":"MX","America/Fort_Nelson":"CA","America/Fort_Wayne":"US","America/Fortaleza":"BR","America/Glace_Bay":"CA","America/Godthab":"GL","America/Goose_Bay":"CA","America/Grand_Turk":"TC","America/Grenada":"GD","America/Guadeloupe":"GP","America/Guatemala":"GT","America/Guayaquil":"EC","America/Guyana":"GY","America/Halifax":"CA","America/Havana":"CU","America/Hermosillo":"MX","America/Indiana/Indianapoli":"US","America/Indiana/Knox":"US","America/Indiana/Marengo":"US","America/Indiana/Petersburg":"US","America/Indiana/Tell_City":"US","America/Indiana/Vevay":"US","America/Indiana/Vincennes":"US","America/Indiana/Winamac":"US","America/Indianapoli":"US","America/Inuvik":"CA","America/Iqaluit":"CA","America/Jamaica":"JM","America/Jujuy":"AR","America/Juneau":"US","America/Kentucky/Louisville":"US","America/Kentucky/Monticello":"US","America/Knox_IN":"US","America/Kralendijk":"BQ","America/La_Paz":"BO","America/Lima":"PE","America/Los_Angeles":"US","America/Louisville":"US","America/Lower_Princes":"SX","America/Maceio":"BR","America/Managua":"NI","America/Manaus":"BR","America/Marigot":"MF","America/Martinique":"MQ","America/Matamoros":"MX","America/Mazatlan":"MX","America/Mendoza":"AR","America/Menominee":"US","America/Merida":"MX","America/Metlakatla":"US","America/Mexico_City":"MX","America/Miquelon":"PM","America/Moncton":"CA","America/Monterrey":"MX","America/Montevideo":"UY","America/Montreal":"CA","America/Montserrat":"MS","America/Nassau":"BS","America/New_York":"US","America/Nipigon":"CA","America/Nome":"US","America/Noronha":"BR","America/North_Dakota/Beulah":"US","America/North_Dakota/Center":"US","America/North_Dakota/New_Salem":"US","America/Nuuk":"GL","America/Ojinaga":"MX","America/Panama":"PA","America/Pangnirtung":"CA","America/Paramaribo":"SR","America/Phoenix":"US,CA","America/Port-au-Prince":"HT","America/Port_of_Spain":"TT","America/Porto_Acre":"BR","America/Porto_Velho":"BR","America/Puerto_Rico":"PR","America/Punta_Arenas":"CL","America/Rainy_River":"CA","America/Rankin_Inlet":"CA","America/Recife":"BR","America/Regina":"CA","America/Resolute":"CA","America/Rio_Branco":"BR","America/Rosario":"AR","America/Santa_Isabel":"MX","America/Santarem":"BR","America/Santiago":"CL","America/Santo_Domingo":"DO","America/Sao_Paulo":"BR","America/Scoresbysund":"GL","America/Shiprock":"US","America/Sitka":"US","America/St_Barthelemy":"BL","America/St_Johns":"CA","America/St_Kitts":"KN","America/St_Lucia":"LC","America/St_Thomas":"VI","America/St_Vincent":"VC","America/Swift_Current":"CA","America/Tegucigalpa":"HN","America/Thule":"GL","America/Thunder_Bay":"CA","America/Tijuana":"MX","America/Toronto":"CA","America/Tortola":"VG","America/Vancouver":"CA","America/Virgin":"VI","America/Whitehorse":"CA","America/Winnipeg":"CA","America/Yakutat":"US","America/Yellowknife":"CA","Antarctica/Casey":"AQ","Antarctica/Davis":"AQ","Antarctica/DumontDUrville":"AQ","Antarctica/Macquarie":"AU","Antarctica/Mawson":"AQ","Antarctica/McMurdo":"AQ","Antarctica/Palmer":"AQ","Antarctica/Rothera":"AQ","Antarctica/South_Pole":"AQ","Antarctica/Syowa":"AQ","Antarctica/Troll":"AQ","Antarctica/Vostok":"AQ","Arctic/Longyearbyen":"SJ","Asia/Aden":"YE","Asia/Almaty":"KZ","Asia/Amman":"JO","Asia/Anadyr":"RU","Asia/Aqtau":"KZ","Asia/Aqtobe":"KZ","Asia/Ashgabat":"TM","Asia/Ashkhabad":"TM","Asia/Atyrau":"KZ","Asia/Baghdad":"IQ","Asia/Bahrain":"BH","Asia/Baku":"AZ","Asia/Bangkok":"TH","Asia/Barnaul":"RU","Asia/Beirut":"LB","Asia/Bishkek":"KG","Asia/Brunei":"BN","Asia/Calcutta":"IN","Asia/Chita":"RU","Asia/Choibalsan":"MN","Asia/Chongqing":"CN","Asia/Chungking":"CN","Asia/Colombo":"LK","Asia/Dacca":"BD","Asia/Damascus":"SY","Asia/Dhaka":"BD","Asia/Dili":"TL","Asia/Dubai":"AE","Asia/Dushanbe":"TJ","Asia/Famagusta":"CY","Asia/Gaza":"PS","Asia/Harbin":"CN","Asia/Hebron":"PS","Asia/Ho_Chi_Minh":"VN","Asia/Hong_Kong":"HK","Asia/Hovd":"MN","Asia/Irkutsk":"RU","Asia/Istanbul":"TR","Asia/Jakarta":"ID","Asia/Jayapura":"ID","Asia/Jerusalem":"IL","Asia/Kabul":"AF","Asia/Kamchatka":"RU","Asia/Karachi":"PK","Asia/Kashgar":"CN","Asia/Kathmandu":"NP","Asia/Katmandu":"NP","Asia/Khandyga":"RU","Asia/Kolkata":"IN","Asia/Krasnoyarsk":"RU","Asia/Kuala_Lumpur":"MY","Asia/Kuching":"MY","Asia/Kuwait":"KW","Asia/Macao":"MO","Asia/Macau":"MO","Asia/Magadan":"RU","Asia/Makassar":"ID","Asia/Manila":"PH","Asia/Muscat":"OM","Asia/Nicosia":"CY","Asia/Novokuznetsk":"RU","Asia/Novosibirsk":"RU","Asia/Omsk":"RU","Asia/Oral":"KZ","Asia/Phnom_Penh":"KH","Asia/Pontianak":"ID","Asia/Pyongyang":"KP","Asia/Qatar":"QA","Asia/Qostanay":"KZ","Asia/Qyzylorda":"KZ","Asia/Rangoon":"MM","Asia/Riyadh":"SA","Asia/Saigon":"VN","Asia/Sakhalin":"RU","Asia/Samarkand":"UZ","Asia/Seoul":"KR","Asia/Shanghai":"CN","Asia/Singapore":"SG","Asia/Srednekolymsk":"RU","Asia/Taipei":"TW","Asia/Tashkent":"UZ","Asia/Tbilisi":"GE","Asia/Tehran":"IR","Asia/Tel_Aviv":"IL","Asia/Thimbu":"BT","Asia/Thimphu":"BT","Asia/Tokyo":"JP","Asia/Tomsk":"RU","Asia/Ujung_Pandang":"ID","Asia/Ulaanbaatar":"MN","Asia/Ulan_Bator":"MN","Asia/Urumqi":"CN","Asia/Ust-Nera":"RU","Asia/Vientiane":"LA","Asia/Vladivostok":"RU","Asia/Yakutsk":"RU","Asia/Yangon":"MM","Asia/Yekaterinburg":"RU","Asia/Yerevan":"AM","Atlantic/Azores":"PT","Atlantic/Bermuda":"BM","Atlantic/Canary":"ES","Atlantic/Cape_Verde":"CV","Atlantic/Faeroe":"FO","Atlantic/Faroe":"FO","Atlantic/Jan_Mayen":"SJ","Atlantic/Madeira":"PT","Atlantic/Reykjavik":"IS","Atlantic/South_Georgia":"GS","Atlantic/St_Helena":"SH","Atlantic/Stanley":"FK","Australia/ACT":"AU","Australia/Adelaide":"AU","Australia/Brisbane":"AU","Australia/Broken_Hill":"AU","Australia/Canberra":"AU","Australia/Currie":"AU","Australia/Darwin":"AU","Australia/Eucla":"AU","Australia/Hobart":"AU","Australia/LHI":"AU","Australia/Lindeman":"AU","Australia/Lord_Howe":"AU","Australia/Melbourne":"AU","Australia/North":"AU","Australia/NSW":"AU","Australia/Perth":"AU","Australia/Queensland":"AU","Australia/South":"AU","Australia/Sydney":"AU","Australia/Tasmania":"AU","Australia/Victoria":"AU","Australia/West":"AU","Australia/Yancowinna":"AU","Brazil/Acre":"BR","Brazil/DeNoronha":"BR","Brazil/East":"BR","Brazil/West":"BR","Canada/Atlantic":"CA","Canada/Central":"CA","Canada/Eastern":"CA","Canada/Mountain":"CA","Canada/Newfoundland":"CA","Canada/Pacific":"CA","Canada/Saskatchewan":"CA","Canada/Yukon":"CA",CET:"CET","Chile/Continental":"CL","Chile/EasterIsland":"CL",CST6CDT:"CST6CDT",Cuba:"CU",EET:"EET",Egypt:"EG",Eire:"IE",EST:"EST",EST5EDT:"EST5EDT","Etc/GMT":"Etc/GMT","Etc/GMT+0":"Etc/GMT+0","Etc/GMT+1":"Etc/GMT+1","Etc/GMT+10":"Etc/GMT+10","Etc/GMT+11":"Etc/GMT+11","Etc/GMT+12":"Etc/GMT+12","Etc/GMT+2":"Etc/GMT+2","Etc/GMT+3":"Etc/GMT+3","Etc/GMT+4":"Etc/GMT+4","Etc/GMT+5":"Etc/GMT+5","Etc/GMT+6":"Etc/GMT+6","Etc/GMT+7":"Etc/GMT+7","Etc/GMT+8":"Etc/GMT+8","Etc/GMT+9":"Etc/GMT+9","Etc/GMT-0":"Etc/GMT-0","Etc/GMT-1":"Etc/GMT-1","Etc/GMT-10":"Etc/GMT-10","Etc/GMT-11":"Etc/GMT-11","Etc/GMT-12":"Etc/GMT-12","Etc/GMT-13":"Etc/GMT-13","Etc/GMT-14":"Etc/GMT-14","Etc/GMT-2":"Etc/GMT-2","Etc/GMT-3":"Etc/GMT-3","Etc/GMT-4":"Etc/GMT-4","Etc/GMT-5":"Etc/GMT-5","Etc/GMT-6":"Etc/GMT-6","Etc/GMT-7":"Etc/GMT-7","Etc/GMT-8":"Etc/GMT-8","Etc/GMT-9":"Etc/GMT-9","Etc/GMT0":"Etc/GMT0","Etc/Greenwich":"Etc/Greenwich","Etc/UCT":"Etc/UCT","Etc/UTC":"Etc/UTC","Etc/Universal":"Etc/Universal","Etc/Zulu":"Etc/Zulu","Europe/Amsterdam":"NL","Europe/Andorra":"AD","Europe/Astrakhan":"RU","Europe/Athens":"GR","Europe/Belfast":"GB","Europe/Belgrade":"RS","Europe/Berlin":"DE","Europe/Bratislava":"SK","Europe/Brussels":"BE","Europe/Bucharest":"RO","Europe/Budapest":"HU","Europe/Busingen":"DE","Europe/Chisinau":"MD","Europe/Copenhagen":"DK","Europe/Dublin":"IE","Europe/Gibraltar":"GI","Europe/Guernsey":"GG","Europe/Helsinki":"FI","Europe/Isle_of_Man":"IM","Europe/Istanbul":"TR","Europe/Jersey":"JE","Europe/Kaliningrad":"RU","Europe/Kiev":"UA","Europe/Kirov":"RU","Europe/Kyiv":"UA","Europe/Lisbon":"PT","Europe/Ljubljana":"SI","Europe/London":"GB","Europe/Luxembourg":"LU","Europe/Madrid":"ES","Europe/Malta":"MT","Europe/Mariehamn":"AX","Europe/Minsk":"BY","Europe/Monaco":"MC","Europe/Moscow":"RU","Europe/Nicosia":"CY","Europe/Oslo":"NO","Europe/Paris":"FR","Europe/Podgorica":"ME","Europe/Prague":"CZ","Europe/Riga":"LV","Europe/Rome":"IT","Europe/Samara":"RU","Europe/San_Marino":"SM","Europe/Sarajevo":"BA","Europe/Saratov":"RU","Europe/Simferopol":"RU","Europe/Skopje":"MK","Europe/Sofia":"BG","Europe/Stockholm":"SE","Europe/Tallinn":"EE","Europe/Tirane":"AL","Europe/Tiraspol":"MD","Europe/Ulyanovsk":"RU","Europe/Uzhgorod":"UA","Europe/Vaduz":"LI","Europe/Vatican":"VA","Europe/Vienna":"AT","Europe/Vilnius":"LT","Europe/Volgograd":"RU","Europe/Warsaw":"PL","Europe/Zagreb":"HR","Europe/Zaporozhye":"UA","Europe/Zurich":"CH",Factory:"Factory",GB:"GB","GB-Eire":"GB",GMT:"GMT","GMT+0":"GMT+0","GMT-0":"GMT-0",GMT0:"GMT0",Greenwich:"Greenwich",Hongkong:"HK",HST:"HST",Iceland:"IS","Indian/Antananarivo":"MG","Indian/Chagos":"IO","Indian/Christmas":"CX","Indian/Cocos":"CC","Indian/Comoro":"KM","Indian/Kerguelen":"TF","Indian/Mahe":"SC","Indian/Maldives":"MV","Indian/Mauritius":"MU","Indian/Mayotte":"YT","Indian/Reunion":"RE",Iran:"IR",Israel:"IL",Jamaica:"JM",Japan:"JP",Kwajalein:"MH",Libya:"LY",MET:"MET","Mexico/BajaNorte":"MX","Mexico/BajaSur":"MX","Mexico/General":"MX",MST:"MST",MST7MDT:"MST7MDT",Navajo:"US",NZ:"NZ","NZ-CHAT":"NZ","Pacific/Apia":"WS","Pacific/Auckland":"NZ","Pacific/Bougainville":"PG","Pacific/Chatham":"NZ","Pacific/Chuuk":"FM","Pacific/Easter":"CL","Pacific/Efate":"VU","Pacific/Enderbury":"KI","Pacific/Fakaofo":"TK","Pacific/Fiji":"FJ","Pacific/Funafuti":"TV","Pacific/Galapagos":"EC","Pacific/Gambier":"PF","Pacific/Guadalcanal":"SB","Pacific/Guam":"GU,MP","Pacific/Honolulu":"US","Pacific/Johnston":"UM","Pacific/Kanton":"KI","Pacific/Kiritimati":"KI","Pacific/Kosrae":"FM","Pacific/Kwajalein":"MH","Pacific/Majuro":"MH","Pacific/Marquesas":"PF","Pacific/Midway":"UM","Pacific/Nauru":"NR","Pacific/Niue":"NU","Pacific/Norfolk":"NF","Pacific/Noumea":"NC","Pacific/Pago_Pago":"AS","Pacific/Palau":"PW","Pacific/Pitcairn":"PN","Pacific/Pohnpei":"FM","Pacific/Ponape":"FM","Pacific/Port_Moresby":"PG","Pacific/Rarotonga":"CK","Pacific/Saipan":"MP","Pacific/Samoa":"AS","Pacific/Tahiti":"PF","Pacific/Tarawa":"KI","Pacific/Tongatapu":"TO","Pacific/Truk":"FM","Pacific/Wake":"UM","Pacific/Wallis":"WF","Pacific/Yap":"FM",Poland:"PL",Portugal:"PT",PRC:"CN",PST8PDT:"PST8PDT",ROC:"TW",ROK:"KR",Singapore:"SG",Turkey:"TR",UCT:"UCT",Universal:"Universal","US/Alaska":"US","US/Aleutian":"US","US/Arizona":"US","US/Central":"US","US/East-Indiana":"US","US/Eastern":"US","US/Hawaii":"US","US/Indiana-Starke":"US","US/Michigan":"US","US/Mountain":"US","US/Pacific":"US","US/Samoa":"AS",UTC:"UTC","W-SU":"RU",WET:"WET",Zulu:"Zulu"}},3500:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),i(r(689),t),i(r(1934),t)},3574:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),i(r(7989),t),i(r(4465),t),i(r(7521),t)},3961:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var i=n(r(4229)),o=n(r(661)),a=(0,i.default)((function(e,t,r){var n,i={};for(n in r=r||{},t=t||{})(0,o.default)(n,t)&&(i[n]=(0,o.default)(n,r)?e(n,t[n],r[n]):t[n]);for(n in r)(0,o.default)(n,r)&&!(0,o.default)(n,i)&&(i[n]=r[n]);return i}));t.default=a},4228:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.requestProviders=t.announceProvider=t.createStore=void 0;var n=r(6349);Object.defineProperty(t,"createStore",{enumerable:!0,get:function(){return n.createStore}});var i=r(2317);Object.defineProperty(t,"announceProvider",{enumerable:!0,get:function(){return i.announceProvider}}),Object.defineProperty(t,"requestProviders",{enumerable:!0,get:function(){return i.requestProviders}})},4229:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return function t(r,n,s){switch(arguments.length){case 0:return t;case 1:return(0,a.default)(r)?t:(0,o.default)((function(t,n){return e(r,t,n)}));case 2:return(0,a.default)(r)&&(0,a.default)(n)?t:(0,a.default)(r)?(0,o.default)((function(t,r){return e(t,n,r)})):(0,a.default)(n)?(0,o.default)((function(t,n){return e(r,t,n)})):(0,i.default)((function(t){return e(r,n,t)}));default:return(0,a.default)(r)&&(0,a.default)(n)&&(0,a.default)(s)?t:(0,a.default)(r)&&(0,a.default)(n)?(0,o.default)((function(t,r){return e(t,r,s)})):(0,a.default)(r)&&(0,a.default)(s)?(0,o.default)((function(t,r){return e(t,n,r)})):(0,a.default)(n)&&(0,a.default)(s)?(0,o.default)((function(t,n){return e(r,t,n)})):(0,a.default)(r)?(0,i.default)((function(t){return e(t,n,s)})):(0,a.default)(n)?(0,i.default)((function(t){return e(r,t,s)})):(0,a.default)(s)?(0,i.default)((function(t){return e(r,n,t)})):e(r,n,s)}}};var i=n(r(4323)),o=n(r(654)),a=n(r(80))},4262:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.clampNumber=t.toDateHourMinute=t.millisecondsToSecond=void 0,t.toSnakeCase=function(e,t){void 0===t&&(t=[]);var n=function(e){return Array.isArray(e)?e.map(n):null!==e&&"object"==typeof e?Object.keys(e).reduce((function(i,o){return i[t.includes(o)?o:r(o)]=t.includes(o)?e[o]:n(e[o]),i}),{}):e};return n(e)};var r=function(e){return e.replace(/([a-z])([A-Z])/g,"$1_$2").replace(/[\s-]+/g,"_").toLowerCase()};t.millisecondsToSecond=function(e){return Math.ceil(e/1e3)},t.toDateHourMinute=function(e){return e.getUTCFullYear()+"-"+("0"+(e.getUTCMonth()+1)).slice(-2)+"-"+("0"+e.getUTCDate()).slice(-2)+" "+("0"+e.getUTCHours()).slice(-2)+":"+("0"+e.getUTCMinutes()).slice(-2)},t.clampNumber=function(e,t,r){return Math.min(Math.max(e,r),t)}},4323:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return function t(r){return 0===arguments.length||(0,i.default)(r)?t:e.apply(this,arguments)}};var i=n(r(80))},4364:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var i=n(r(3318));t.default=(0,i.default)(r.g.fetch)},4465:(e,t)=>{"use strict";var r,n;Object.defineProperty(t,"__esModule",{value:!0}),t.TransactionStatus=t.SignatureStatus=void 0,function(e){e.REQUESTED="requested",e.REJECTED="rejected",e.CONFIRMED="confirmed"}(r||(t.SignatureStatus=r={})),function(e){e.STARTED="started",e.REJECTED="rejected",e.BROADCASTED="broadcasted",e.CONFIRMED="confirmed",e.REVERTED="reverted"}(n||(t.TransactionStatus=n={}))},4476:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="1.19.7"},4811:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isNullish=void 0,t.isNullish=function(e){return null==e}},4848:(e,t,r)=>{"use strict";e.exports=r(1020)},5145:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.crypto=void 0,t.crypto="object"==typeof globalThis&&"crypto"in globalThis?globalThis.crypto:void 0},5190:function(e,t,r){"use strict";var n=this&&this.__assign||function(){return n=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},n.apply(this,arguments)},i=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{c(n.next(e))}catch(e){o(e)}}function s(e){try{c(n.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}c((n=n.apply(e,t||[])).next())}))},o=this&&this.__generator||function(e,t){var r,n,i,o={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return a.next=s(0),a.throw=s(1),a.return=s(2),"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function s(s){return function(c){return function(s){if(r)throw new TypeError("Generator is already executing.");for(;a&&(a=0,s[0]&&(o=0)),o;)try{if(r=1,n&&(i=2&s[0]?n.return:s[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,s[1])).done)return i;switch(n=0,i&&(s=[2&s[0],i.value]),s[0]){case 0:case 1:i=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,n=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((i=(i=o.trys).length>0&&i[i.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!i||s[1]>i[0]&&s[1]<i[3])){o.label=s[1];break}if(6===s[0]&&o.label<i[1]){o.label=i[1],i=s;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(s);break}i[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],n=0}finally{r=i=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,c])}}};Object.defineProperty(t,"__esModule",{value:!0}),t.useFormo=t.FormoAnalyticsProvider=t.FormoAnalyticsContext=void 0;var a=r(4848),s=r(6540),c=r(879),u=r(8568),d={chain:function(){return Promise.resolve()},page:function(){return Promise.resolve()},reset:function(){return Promise.resolve()},detect:function(){return Promise.resolve()},connect:function(){return Promise.resolve()},disconnect:function(){return Promise.resolve()},signature:function(){return Promise.resolve()},transaction:function(){return Promise.resolve()},identify:function(){return Promise.resolve()},track:function(){return Promise.resolve()}};t.FormoAnalyticsContext=(0,s.createContext)(d),t.FormoAnalyticsProvider=function(e){var t=e.writeKey,r=e.disabled,i=void 0!==r&&r,o=e.children;return t?i?(u.logger.warn("FormoAnalytics is disabled"),(0,a.jsx)(a.Fragment,{children:o})):(0,a.jsx)(l,n({},e)):(u.logger.error("FormoAnalyticsProvider: No Write Key provided"),(0,a.jsx)(a.Fragment,{children:o}))};var l=function(e){var r=e.writeKey,n=e.options,l=e.children,f=(0,s.useState)(d),h=f[0],p=f[1],v=(0,s.useRef)(!1);return(0,u.initStorageManager)(r),(0,s.useEffect)((function(){i(void 0,void 0,void 0,(function(){var e,t;return o(this,(function(i){switch(i.label){case 0:if(v.current)return[2];v.current=!0,i.label=1;case 1:return i.trys.push([1,3,,4]),[4,c.FormoAnalytics.init(r,n)];case 2:return e=i.sent(),p(e),u.logger.log("Successfully initialized"),[3,4];case 3:return t=i.sent(),u.logger.error("Failed to initialize",t),[3,4];case 4:return[2]}}))}))}),[r,n]),(0,a.jsx)(t.FormoAnalyticsContext.Provider,{value:h,children:l})};t.useFormo=function(){var e=(0,s.useContext)(t.FormoAnalyticsContext);return e||u.logger.warn("useFormo called without a valid context"),e}},5287:(e,t)=>{"use strict";var r=Symbol.for("react.element"),n=Symbol.for("react.portal"),i=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),c=Symbol.for("react.context"),u=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),l=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),h=Symbol.iterator,p={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},v=Object.assign,g={};function y(e,t,r){this.props=e,this.context=t,this.refs=g,this.updater=r||p}function A(){}function m(e,t,r){this.props=e,this.context=t,this.refs=g,this.updater=r||p}y.prototype.isReactComponent={},y.prototype.setState=function(e,t){if("object"!=typeof e&&"function"!=typeof e&&null!=e)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")},y.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},A.prototype=y.prototype;var _=m.prototype=new A;_.constructor=m,v(_,y.prototype),_.isPureReactComponent=!0;var b=Array.isArray,E=Object.prototype.hasOwnProperty,w={current:null},S={key:!0,ref:!0,__self:!0,__source:!0};function P(e,t,n){var i,o={},a=null,s=null;if(null!=t)for(i in void 0!==t.ref&&(s=t.ref),void 0!==t.key&&(a=""+t.key),t)E.call(t,i)&&!S.hasOwnProperty(i)&&(o[i]=t[i]);var c=arguments.length-2;if(1===c)o.children=n;else if(1<c){for(var u=Array(c),d=0;d<c;d++)u[d]=arguments[d+2];o.children=u}if(e&&e.defaultProps)for(i in c=e.defaultProps)void 0===o[i]&&(o[i]=c[i]);return{$$typeof:r,type:e,key:a,ref:s,props:o,_owner:w.current}}function C(e){return"object"==typeof e&&null!==e&&e.$$typeof===r}var T=/\/+/g;function O(e,t){return"object"==typeof e&&null!==e&&null!=e.key?function(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,(function(e){return t[e]}))}(""+e.key):t.toString(36)}function M(e,t,i,o,a){var s=typeof e;"undefined"!==s&&"boolean"!==s||(e=null);var c=!1;if(null===e)c=!0;else switch(s){case"string":case"number":c=!0;break;case"object":switch(e.$$typeof){case r:case n:c=!0}}if(c)return a=a(c=e),e=""===o?"."+O(c,0):o,b(a)?(i="",null!=e&&(i=e.replace(T,"$&/")+"/"),M(a,t,i,"",(function(e){return e}))):null!=a&&(C(a)&&(a=function(e,t){return{$$typeof:r,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}(a,i+(!a.key||c&&c.key===a.key?"":(""+a.key).replace(T,"$&/")+"/")+e)),t.push(a)),1;if(c=0,o=""===o?".":o+":",b(e))for(var u=0;u<e.length;u++){var d=o+O(s=e[u],u);c+=M(s,t,i,d,a)}else if(d=function(e){return null===e||"object"!=typeof e?null:"function"==typeof(e=h&&e[h]||e["@@iterator"])?e:null}(e),"function"==typeof d)for(e=d.call(e),u=0;!(s=e.next()).done;)c+=M(s=s.value,t,i,d=o+O(s,u++),a);else if("object"===s)throw t=String(e),Error("Objects are not valid as a React child (found: "+("[object Object]"===t?"object with keys {"+Object.keys(e).join(", ")+"}":t)+"). If you meant to render a collection of children, use an array instead.");return c}function I(e,t,r){if(null==e)return e;var n=[],i=0;return M(e,n,"","",(function(e){return t.call(r,e,i++)})),n}function k(e){if(-1===e._status){var t=e._result;(t=t()).then((function(t){0!==e._status&&-1!==e._status||(e._status=1,e._result=t)}),(function(t){0!==e._status&&-1!==e._status||(e._status=2,e._result=t)})),-1===e._status&&(e._status=0,e._result=t)}if(1===e._status)return e._result.default;throw e._result}var U={current:null},R={transition:null},L={ReactCurrentDispatcher:U,ReactCurrentBatchConfig:R,ReactCurrentOwner:w};function j(){throw Error("act(...) is not supported in production builds of React.")}t.Children={map:I,forEach:function(e,t,r){I(e,(function(){t.apply(this,arguments)}),r)},count:function(e){var t=0;return I(e,(function(){t++})),t},toArray:function(e){return I(e,(function(e){return e}))||[]},only:function(e){if(!C(e))throw Error("React.Children.only expected to receive a single React element child.");return e}},t.Component=y,t.Fragment=i,t.Profiler=a,t.PureComponent=m,t.StrictMode=o,t.Suspense=d,t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=L,t.act=j,t.cloneElement=function(e,t,n){if(null==e)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+e+".");var i=v({},e.props),o=e.key,a=e.ref,s=e._owner;if(null!=t){if(void 0!==t.ref&&(a=t.ref,s=w.current),void 0!==t.key&&(o=""+t.key),e.type&&e.type.defaultProps)var c=e.type.defaultProps;for(u in t)E.call(t,u)&&!S.hasOwnProperty(u)&&(i[u]=void 0===t[u]&&void 0!==c?c[u]:t[u])}var u=arguments.length-2;if(1===u)i.children=n;else if(1<u){c=Array(u);for(var d=0;d<u;d++)c[d]=arguments[d+2];i.children=c}return{$$typeof:r,type:e.type,key:o,ref:a,props:i,_owner:s}},t.createContext=function(e){return(e={$$typeof:c,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null}).Provider={$$typeof:s,_context:e},e.Consumer=e},t.createElement=P,t.createFactory=function(e){var t=P.bind(null,e);return t.type=e,t},t.createRef=function(){return{current:null}},t.forwardRef=function(e){return{$$typeof:u,render:e}},t.isValidElement=C,t.lazy=function(e){return{$$typeof:f,_payload:{_status:-1,_result:e},_init:k}},t.memo=function(e,t){return{$$typeof:l,type:e,compare:void 0===t?null:t}},t.startTransition=function(e){var t=R.transition;R.transition={};try{e()}finally{R.transition=t}},t.unstable_act=j,t.useCallback=function(e,t){return U.current.useCallback(e,t)},t.useContext=function(e){return U.current.useContext(e)},t.useDebugValue=function(){},t.useDeferredValue=function(e){return U.current.useDeferredValue(e)},t.useEffect=function(e,t){return U.current.useEffect(e,t)},t.useId=function(){return U.current.useId()},t.useImperativeHandle=function(e,t,r){return U.current.useImperativeHandle(e,t,r)},t.useInsertionEffect=function(e,t){return U.current.useInsertionEffect(e,t)},t.useLayoutEffect=function(e,t){return U.current.useLayoutEffect(e,t)},t.useMemo=function(e,t){return U.current.useMemo(e,t)},t.useReducer=function(e,t,r){return U.current.useReducer(e,t,r)},t.useRef=function(e){return U.current.useRef(e)},t.useState=function(e){return U.current.useState(e)},t.useSyncExternalStore=function(e,t,r){return U.current.useSyncExternalStore(e,t,r)},t.useTransition=function(){return U.current.useTransition()},t.version="18.3.1"},5467:function(e,t){"use strict";var r=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{c(n.next(e))}catch(e){o(e)}}function s(e){try{c(n.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}c((n=n.apply(e,t||[])).next())}))},n=this&&this.__generator||function(e,t){var r,n,i,o={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return a.next=s(0),a.throw=s(1),a.return=s(2),"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function s(s){return function(c){return function(s){if(r)throw new TypeError("Generator is already executing.");for(;a&&(a=0,s[0]&&(o=0)),o;)try{if(r=1,n&&(i=2&s[0]?n.return:s[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,s[1])).done)return i;switch(n=0,i&&(s=[2&s[0],i.value]),s[0]){case 0:case 1:i=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,n=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((i=(i=o.trys).length>0&&i[i.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!i||s[1]>i[0]&&s[1]<i[3])){o.label=s[1];break}if(6===s[0]&&o.label<i[1]){o.label=i[1],i=s;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(s);break}i[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],n=0}finally{r=i=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,c])}}};Object.defineProperty(t,"__esModule",{value:!0}),t.hash=function(e){return r(this,void 0,void 0,(function(){var t,r;return n(this,(function(n){switch(n.label){case 0:return[4,crypto.subtle.digest("SHA-256",(new TextEncoder).encode(e))];case 1:return t=n.sent(),r=new Uint8Array(t),[2,Array.from(r).map((function(e){return e.toString(16).padStart(2,"0")})).join("")]}}))}))},t.generateNativeUUID=function(){return crypto.randomUUID()}},5686:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.generateAnonymousId=void 0,t.getCookieDomain=o;var n=r(9266),i=r(6898);function o(e){if(void 0===e&&(e=window.location.hostname),e.includes("localhost")||/^\d{1,3}(\.\d{1,3}){3}$/.test(e))return"";var t=e.split(".");return t.includes("www")&&t.splice(t.indexOf("www"),1),".".concat(t.join("."))}t.generateAnonymousId=function(e){var t=(0,i.cookie)().get(e);if(t&&"string"==typeof t)return t;var r=(0,n.generateNativeUUID)();return(0,i.cookie)().set(e,r,{maxAge:Date.now()+31536e6,domain:o(),path:"/"}),r}},5925:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.objectToString=t.isPrimitive=t.isError=t.isDate=t.isRegExp=t.isObjectAndNotNull=t.isObject=t.isNumber=t.isBoolean=t.isArray=t.isBigInt=t.isDefinedNotNullAndNotEmptyString=t.isDefinedAndNotNull=t.isDefined=t.isTypeOfError=t.isNullOrUndefined=t.isUndefined=t.isNull=t.isString=t.isFunction=void 0,t.isFunction=function(e){return"function"==typeof e&&Boolean(e.constructor&&e.call&&e.apply)},t.isString=function(e){return"string"==typeof e};var r=function(e){return null===e};t.isNull=r;var n=function(e){return void 0===e};t.isUndefined=n;var i=function(e){return r(e)||n(e)};t.isNullOrUndefined=i,t.isBigInt=function(e){return"bigint"==typeof e},t.isDefined=function(e){return!n(e)};var o=function(e){return!i(e)};t.isDefinedAndNotNull=o,t.isDefinedNotNullAndNotEmptyString=function(e){return o(e)&&""!==e},t.isTypeOfError=function(e){switch(Object.prototype.toString.call(e)){case"[object Error]":case"[object Exception]":case"[object DOMException]":return!0;default:return e instanceof Error}};var a=function(e){return Array.isArray(e)};t.isArray=a,t.isBoolean=function(e){return"boolean"==typeof e},t.isNumber=function(e){return"number"==typeof e};var s=function(e){return"object"==typeof e};t.isObject=s,t.isObjectAndNotNull=function(e){return!r(e)&&s(e)&&!a(e)},t.isRegExp=function(e){return s(e)&&"[object RegExp]"===c(e)},t.isDate=function(e){return s(e)&&"[object Date]"===c(e)},t.isError=function(e){return s(e)&&("[object Error]"===c(e)||e instanceof Error)},t.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e};var c=function(e){return Object.prototype.toString.call(e)};t.objectToString=c},5938:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.checkAddressChecksum=t.isAddress=void 0,t.ensureIfUint8Array=s;var n=r(3113),i=r(2019),o=r(2672),a=r(5953);function s(e){var t;return e instanceof Uint8Array||"Uint8Array"!==(null===(t=null==e?void 0:e.constructor)||void 0===t?void 0:t.name)?e:Uint8Array.from(e)}t.isAddress=function(e,r){return void 0===r&&(r=!0),!("string"!=typeof e&&!(0,n.isUint8Array)(e))&&(i=(0,n.isUint8Array)(e)?(0,n.uint8ArrayToHexString)(e):"string"!=typeof e||(0,a.isHexStrict)(e)||e.toLowerCase().startsWith("0x")?e:"0x".concat(e),!!/^(0x)?[0-9a-f]{40}$/i.test(i)&&(!(!/^(0x|0X)?[0-9a-f]{40}$/.test(i)&&!/^(0x|0X)?[0-9A-F]{40}$/.test(i))||!r||(0,t.checkAddressChecksum)(i)));var i},t.checkAddressChecksum=function(e){if(!/^(0x)?[0-9a-f]{40}$/i.test(e))return!1;for(var t=e.slice(2),r=(0,o.utf8ToBytes)(t.toLowerCase()),a=(0,n.uint8ArrayToHexString)((0,i.keccak256)(s(r))).slice(2),c=0;c<40;c+=1)if(parseInt(a[c],16)>7&&t[c].toUpperCase()!==t[c]||parseInt(a[c],16)<=7&&t[c].toLowerCase()!==t[c])return!1;return!0}},5953:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isHexStrict=void 0,t.isHexStrict=function(e){return"string"==typeof e&&/^((-)?0x[0-9a-f]+|(0x))$/i.test(e)}},6073:function(e,t,r){"use strict";var n,i=this&&this.__extends||(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},n(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var a=r(8177),s=r(7532),c=function(e){function t(t,r){var n=e.call(this,t)||this;return n.backend=r,n}return i(t,e),t.prototype.isAvailable=function(){try{var e="__storage_test__";return this.backend.setItem(e,"1"),this.backend.removeItem(e),!0}catch(e){return!1}},t.prototype.set=function(e,t){"boolean"==typeof t&&(t=!0===t?"true":"false"),"object"==typeof t&&(t=s.JSON_PREFIX+JSON.stringify(t)),this.backend.setItem(this.getKey(e),t)},t.prototype.get=function(e){var t=this.backend.getItem(this.getKey(e));if(!t||"string"!=typeof t)return null;if(["null","undefined"].some((function(e){return e==t})))return null;if(t.startsWith(s.JSON_PREFIX))try{return JSON.parse(t.slice(s.JSON_PREFIX.length))}catch(e){return a.logger.error("[FORMO_ERROR] ".concat(this.backend.constructor.name," failed to parse JSON"),e),null}return["true","false"].some((function(e){return e==t}))?JSON.parse(t):t},t.prototype.remove=function(e){this.backend.removeItem(this.getKey(e))},t}(o(r(2200)).default);t.default=c},6138:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getFormattedTimestamp=t.getCurrentTimeFormatted=void 0;var r=function(e){return e.toISOString()};t.getFormattedTimestamp=r,t.getCurrentTimeFormatted=function(){return r(new Date)}},6185:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getActionDescriptor=void 0,t.getActionDescriptor=function(e,t){var r=e;return(null==t?void 0:t.status)&&(r+=" ".concat(t.status)),"connect"!==e&&"disconnect"!==e||!(null==t?void 0:t.rdns)||(r+=" (".concat(t.rdns,")")),r}},6349:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createStore=void 0;const n=r(2317);t.createStore=function(){const e=new Set;let t=[];const r=()=>(0,n.requestProviders)((r=>{t.some((({info:e})=>e.uuid===r.info.uuid))||(t=[...t,r],e.forEach((e=>e(t,{added:[r]}))))}));let i=r();return{_listeners:()=>e,clear(){e.forEach((e=>e([],{removed:[...t]}))),t=[]},destroy(){this.clear(),e.clear(),i?.()},findProvider:({rdns:e})=>t.find((t=>t.info.rdns===e)),getProviders:()=>t,reset(){this.clear(),i?.(),i=r()},subscribe:(r,{emitImmediately:n}={})=>(e.add(r),n&&r(t,{added:t}),()=>e.delete(r))}}},6450:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),i(r(6921),t),i(r(3358),t),i(r(2309),t)},6452:function(e,t,r){"use strict";var n=this&&this.__rest||function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(n=Object.getOwnPropertySymbols(e);i<n.length;i++)t.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(e,n[i])&&(r[n[i]]=e[n[i]])}return r};Object.defineProperty(t,"__esModule",{value:!0}),t.EventManager=void 0;var i=r(8177),o=r(8337),a=function(){function e(e){this.eventQueue=e,this.eventFactory=new o.EventFactory}return e.prototype.addEvent=function(e,t,r){var o=e.callback,a=n(e,["callback"]),s=this.eventFactory.create(a,t,r);this.eventQueue.enqueue(s,(function(e,t,r){e?i.logger.error("Error sending events:",e):i.logger.info("Events sent successfully: ".concat(r.length," events")),null==o||o(e,t,r)}))},e}();t.EventManager=a},6503:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isLocalhost=void 0,t.isLocalhost=function(){return/^localhost$|^127(?:\.[0-9]+){0,2}\.[0-9]+$|^(?:0*:)*?:?0*1$/.test(window.location.hostname)||"file:"===window.location.protocol}},6540:(e,t,r)=>{"use strict";e.exports=r(5287)},6898:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),t.memory=t.session=t.local=t.cookie=void 0,t.initStorageManager=function(e){a||(a=new o.StorageManager(e))};var o=r(1388);i(r(7892),t);var a=null;function s(e){if(!a)throw new Error("StorageManager not initialized. Call initStorageManager(writeKey) first.");return a.getStorage(e)}t.cookie=function(){return s("cookieStorage")},t.local=function(){return s("localStorage")},t.session=function(){return s("sessionStorage")},t.memory=function(){return s("memoryStorage")}},6921:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DEFAULT_PROVIDER_ICON=t.LOCAL_ANONYMOUS_ID_KEY=t.SESSION_USER_ID_KEY=t.SESSION_CURRENT_URL_KEY=t.SESSION_WALLET_DETECTED_KEY=t.SESSION_TRAFFIC_SOURCE_KEY=void 0,t.SESSION_TRAFFIC_SOURCE_KEY="traffic-source",t.SESSION_WALLET_DETECTED_KEY="wallet-detected",t.SESSION_CURRENT_URL_KEY="analytics-current-url",t.SESSION_USER_ID_KEY="user-id",t.LOCAL_ANONYMOUS_ID_KEY="anonymous-id",t.DEFAULT_PROVIDER_ICON="data:image/svg+xml;base64,"},7034:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.VERSION=t.CHANNEL=void 0,t.CHANNEL="web",t.VERSION="0"},7521:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WRAPPED_REQUEST_REF_SYMBOL=t.WRAPPED_REQUEST_SYMBOL=void 0,t.WRAPPED_REQUEST_SYMBOL=Symbol("formoWrappedRequest"),t.WRAPPED_REQUEST_REF_SYMBOL=Symbol("formoWrappedRequestRef")},7532:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.KEY_PREFIX=t.JSON_PREFIX=void 0,t.JSON_PREFIX="__json=",t.KEY_PREFIX="formo"},7557:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.aoutput=t.anumber=t.aexists=t.abytes=void 0;const n=r(9175);t.abytes=n.abytes,t.aexists=n.aexists,t.anumber=n.anumber,t.aoutput=n.aoutput},7892:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},7967:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),i(r(8337),t),i(r(6452),t),i(r(1371),t)},7989:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},8156:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0});var o=r(2970);i(r(5190),t),i(r(879),t),i(r(3574),t),"undefined"!=typeof window&&(window.formofy=o.formofy)},8177:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),i(r(2865),t),i(r(1565),t)},8337:function(e,t,r){"use strict";var n=this&&this.__assign||function(){return n=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},n.apply(this,arguments)},i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.EventFactory=void 0;var o=r(6450),a=r(9266),s=r(922),c=r(6138),u=r(9754),d=r(8177),l=i(r(1466)),f=r(6898),h=r(4476),p=r(7034),v=r(5686),g=function(){function e(){var e=this;this.extractUTMParameters=function(e){var t={utm_campaign:"",utm_content:"",utm_medium:"",utm_source:"",utm_term:""};try{new URL(e).searchParams.forEach((function(e,r){r.startsWith("utm_")&&(t[r]=e.trim())}))}catch(e){}return t},this.extractReferralParameter=function(e){for(var t,r=0,n=["ref","referral","refcode"];r<n.length;r++){var i=n[r],o=null===(t=e.searchParams.get(i))||void 0===t?void 0:t.trim();if(o)return o}return""},this.getTrafficSources=function(t){var r=new URL(t),i=n(n({},e.extractUTMParameters(t)),{ref:e.extractReferralParameter(r),referrer:document.referrer}),a=(0,f.session)().get(o.SESSION_TRAFFIC_SOURCE_KEY)||{},s={ref:i.ref||(null==a?void 0:a.ref)||"",referrer:i.referrer||(null==a?void 0:a.referrer)||"",utm_campaign:i.utm_campaign||(null==a?void 0:a.utm_campaign)||"",utm_content:i.utm_content||(null==a?void 0:a.utm_content)||"",utm_medium:i.utm_medium||(null==a?void 0:a.utm_medium)||"",utm_source:i.utm_source||(null==a?void 0:a.utm_source)||"",utm_term:i.utm_term||(null==a?void 0:a.utm_term)||""},c=Object.keys(s).reduce((function(e,t){var r=s[t];return(0,u.isUndefined)(r)||""===r||(e[t]=r),e}),{});return Object.keys(c).length&&(0,f.session)().set(o.SESSION_TRAFFIC_SOURCE_KEY,c),s},this.getPageProperties=function(e){var t=e;return(0,u.isUndefined)(t.url)&&(t.url=new URL(globalThis.location.href).href),(0,u.isUndefined)(t.path)&&(t.path=globalThis.location.pathname),(0,u.isUndefined)(t.hash)&&(t.hash=globalThis.location.hash),t},this.getEnrichedEvent=function(t,r){var n={context:e.generateContext(r),original_timestamp:(0,c.getCurrentTimeFormatted)(),user_id:t.user_id,type:t.type,channel:p.CHANNEL,version:p.VERSION};n.anonymous_id=(0,v.generateAnonymousId)(o.LOCAL_ANONYMOUS_ID_KEY);var i=(0,s.getValidAddress)(t.address);n.address=i?(0,a.toChecksumAddress)(i):null;var u=(0,l.default)(t,n);return void 0===u.event&&(u.event=null),void 0===u.properties&&(u.properties=null),(0,a.toSnakeCase)(u)}}return e.prototype.getTimezone=function(){try{return Intl.DateTimeFormat().resolvedOptions().timeZone}catch(e){return d.logger.error("Error resolving timezone:",e),""}},e.prototype.getLocation=function(){try{var e=this.getTimezone();return e in o.COUNTRY_LIST?o.COUNTRY_LIST[e]:e}catch(e){return d.logger.error("Error resolving location:",e),""}},e.prototype.getLanguage=function(){try{return(navigator.languages&&navigator.languages.length?navigator.languages[0]:navigator.language)||"en"}catch(e){return d.logger.error("Error resolving language:",e),"en"}},e.prototype.getLibraryVersion=function(){return h.version},e.prototype.generateContext=function(e){var t=globalThis.location.pathname,r=this.getLanguage(),i=this.getTimezone(),o=this.getLocation(),a=this.getLibraryVersion(),s=n(n({user_agent:globalThis.navigator.userAgent,locale:r,timezone:i,location:o},this.getTrafficSources(globalThis.location.href)),{page_path:t,page_title:document.title,page_url:globalThis.location.href,library_name:"Formo Web SDK",library_version:a});return(0,l.default)(s,e||{})},e.prototype.generatePageEvent=function(e,t,r,n){var i=null!=r?r:{};i.category=e,i.name=t;var o={properties:i=this.getPageProperties(i),type:"page"};return this.getEnrichedEvent(o,n)},e.prototype.generateDetectWalletEvent=function(e,t,r,i){var o={properties:n({providerName:e,rdns:t},r),type:"detect"};return this.getEnrichedEvent(o,i)},e.prototype.generateIdentifyEvent=function(e,t,r,i,o,a){var s={properties:n({providerName:e,rdns:t},o),user_id:i,address:r,type:"identify"};return this.getEnrichedEvent(s,a)},e.prototype.generateConnectEvent=function(e,t,r,i){var o={properties:n({chainId:e},r),address:t,type:"connect"};return this.getEnrichedEvent(o,i)},e.prototype.generateDisconnectEvent=function(e,t,r,i){var o={properties:n({chainId:e},r),address:t,type:"disconnect"};return this.getEnrichedEvent(o,i)},e.prototype.generateChainChangedEvent=function(e,t,r,i){var o={properties:n({chainId:e},r),address:t,type:"chain"};return this.getEnrichedEvent(o,i)},e.prototype.generateSignatureEvent=function(e,t,r,i,o,a,s){var c={properties:n(n({status:e,chainId:t,message:i},o&&{signatureHash:o}),a),address:r,type:"signature"};return this.getEnrichedEvent(c,s)},e.prototype.generateTransactionEvent=function(e,t,r,i,o,a,s,c,u){var d={properties:n(n({status:e,chainId:t,data:i,to:o,value:a},s&&{transactionHash:s}),c),address:r,type:"transaction"};return this.getEnrichedEvent(d,u)},e.prototype.generateTrackEvent=function(e,t,r){var i={properties:n(n(n(n({},t),void 0!==(null==t?void 0:t.revenue)&&{revenue:Number(t.revenue),currency:("string"==typeof(null==t?void 0:t.currency)?t.currency:"USD").toLowerCase()}),void 0!==(null==t?void 0:t.points)&&{points:Number(t.points)}),void 0!==(null==t?void 0:t.volume)&&{volume:Number(t.volume)}),event:e,type:"track"};return this.getEnrichedEvent(i,r)},e.prototype.create=function(e,t,r){var n={};switch(e.type){case"page":n=this.generatePageEvent(e.category,e.name,e.properties,e.context);break;case"detect":n=this.generateDetectWalletEvent(e.providerName,e.rdns,e.properties,e.context);break;case"identify":n=this.generateIdentifyEvent(e.providerName,e.rdns,e.address,e.userId,e.properties,e.context);break;case"chain":n=this.generateChainChangedEvent(e.chainId,e.address,e.properties,e.context);break;case"connect":n=this.generateConnectEvent(e.chainId,e.address,e.properties,e.context);break;case"disconnect":n=this.generateDisconnectEvent(e.chainId,e.address,e.properties,e.context);break;case"signature":n=this.generateSignatureEvent(e.status,e.chainId,e.address,e.message,e.signatureHash,e.properties,e.context);break;case"transaction":n=this.generateTransactionEvent(e.status,e.chainId,e.address,e.data,e.to,e.value,e.transactionHash,e.properties,e.context);break;default:n=this.generateTrackEvent(e.event,e.properties,e.context)}if(void 0===n.address||null===n.address){var i=(0,s.getValidAddress)(t);n.address=i?(0,a.toChecksumAddress)(i):null}return n.user_id=r||null,n},e}();t.EventFactory=g},8341:function(e,t,r){"use strict";var n,i=this&&this.__extends||(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},n(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var a=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t.prototype.isAvailable=function(){return"undefined"!=typeof document&&"string"==typeof document.cookie},t.prototype.set=function(e,t,r){var n=null==r?void 0:r.expires,i=null==r?void 0:r.maxAge,o=(null==r?void 0:r.path)||"/",a=null==r?void 0:r.domain,s=null==r?void 0:r.sameSite,c=(null==r?void 0:r.secure)||!1,u="".concat(encodeURIComponent(this.getKey(e)),"=").concat(encodeURIComponent(t));i?u+="; max-age="+i:n&&(u+="; expires="+n),o&&(u+="; path="+o),a&&(u+="; domain="+a),s&&(u+="; samesite="+s),c&&(u+="; secure"),document.cookie=u},t.prototype.get=function(e){var t=document.cookie.match(new RegExp("(?:^|; )".concat(encodeURIComponent(this.getKey(e)),"=([^;]*)")));return t?decodeURIComponent(t[1]):null},t.prototype.remove=function(e){document.cookie="".concat(encodeURIComponent(this.getKey(e)),"=; path=/; expires=Thu, 01 Jan 1970 00:00:00 GMT")},t}(o(r(2200)).default);t.default=a},8568:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)},o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.fetch=void 0,i(r(7967),t),i(r(8177),t),i(r(3500),t),i(r(6898),t);var a=r(4364);Object.defineProperty(t,"fetch",{enumerable:!0,get:function(){return o(a).default}})},9175:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.wrapXOFConstructorWithOpts=t.wrapConstructorWithOpts=t.wrapConstructor=t.Hash=t.nextTick=t.swap32IfBE=t.byteSwapIfBE=t.swap8IfBE=t.isLE=void 0,t.isBytes=i,t.anumber=o,t.abytes=a,t.ahash=function(e){if("function"!=typeof e||"function"!=typeof e.create)throw new Error("Hash should be wrapped by utils.createHasher");o(e.outputLen),o(e.blockLen)},t.aexists=function(e,t=!0){if(e.destroyed)throw new Error("Hash instance has been destroyed");if(t&&e.finished)throw new Error("Hash#digest() has already been called")},t.aoutput=function(e,t){a(e);const r=t.outputLen;if(e.length<r)throw new Error("digestInto() expects output buffer of length at least "+r)},t.u8=function(e){return new Uint8Array(e.buffer,e.byteOffset,e.byteLength)},t.u32=function(e){return new Uint32Array(e.buffer,e.byteOffset,Math.floor(e.byteLength/4))},t.clean=function(...e){for(let t=0;t<e.length;t++)e[t].fill(0)},t.createView=function(e){return new DataView(e.buffer,e.byteOffset,e.byteLength)},t.rotr=function(e,t){return e<<32-t|e>>>t},t.rotl=function(e,t){return e<<t|e>>>32-t>>>0},t.byteSwap=s,t.byteSwap32=c,t.bytesToHex=function(e){if(a(e),u)return e.toHex();let t="";for(let r=0;r<e.length;r++)t+=d[e[r]];return t},t.hexToBytes=function(e){if("string"!=typeof e)throw new Error("hex string expected, got "+typeof e);if(u)return Uint8Array.fromHex(e);const t=e.length,r=t/2;if(t%2)throw new Error("hex string expected, got unpadded hex of length "+t);const n=new Uint8Array(r);for(let t=0,i=0;t<r;t++,i+=2){const r=f(e.charCodeAt(i)),o=f(e.charCodeAt(i+1));if(void 0===r||void 0===o){const t=e[i]+e[i+1];throw new Error('hex string expected, got non-hex character "'+t+'" at index '+i)}n[t]=16*r+o}return n},t.asyncLoop=async function(e,r,n){let i=Date.now();for(let o=0;o<e;o++){n(o);const e=Date.now()-i;e>=0&&e<r||(await(0,t.nextTick)(),i+=e)}},t.utf8ToBytes=h,t.bytesToUtf8=function(e){return(new TextDecoder).decode(e)},t.toBytes=p,t.kdfInputToBytes=function(e){return"string"==typeof e&&(e=h(e)),a(e),e},t.concatBytes=function(...e){let t=0;for(let r=0;r<e.length;r++){const n=e[r];a(n),t+=n.length}const r=new Uint8Array(t);for(let t=0,n=0;t<e.length;t++){const i=e[t];r.set(i,n),n+=i.length}return r},t.checkOpts=function(e,t){if(void 0!==t&&"[object Object]"!=={}.toString.call(t))throw new Error("options should be object or undefined");return Object.assign(e,t)},t.createHasher=v,t.createOptHasher=g,t.createXOFer=y,t.randomBytes=function(e=32){if(n.crypto&&"function"==typeof n.crypto.getRandomValues)return n.crypto.getRandomValues(new Uint8Array(e));if(n.crypto&&"function"==typeof n.crypto.randomBytes)return Uint8Array.from(n.crypto.randomBytes(e));throw new Error("crypto.getRandomValues must be defined")};const n=r(5145);function i(e){return e instanceof Uint8Array||ArrayBuffer.isView(e)&&"Uint8Array"===e.constructor.name}function o(e){if(!Number.isSafeInteger(e)||e<0)throw new Error("positive integer expected, got "+e)}function a(e,...t){if(!i(e))throw new Error("Uint8Array expected");if(t.length>0&&!t.includes(e.length))throw new Error("Uint8Array expected of length "+t+", got length="+e.length)}function s(e){return e<<24&4278190080|e<<8&16711680|e>>>8&65280|e>>>24&255}function c(e){for(let t=0;t<e.length;t++)e[t]=s(e[t]);return e}t.isLE=68===new Uint8Array(new Uint32Array([287454020]).buffer)[0],t.swap8IfBE=t.isLE?e=>e:e=>s(e),t.byteSwapIfBE=t.swap8IfBE,t.swap32IfBE=t.isLE?e=>e:c;const u=(()=>"function"==typeof Uint8Array.from([]).toHex&&"function"==typeof Uint8Array.fromHex)(),d=Array.from({length:256},((e,t)=>t.toString(16).padStart(2,"0"))),l={_0:48,_9:57,A:65,F:70,a:97,f:102};function f(e){return e>=l._0&&e<=l._9?e-l._0:e>=l.A&&e<=l.F?e-(l.A-10):e>=l.a&&e<=l.f?e-(l.a-10):void 0}function h(e){if("string"!=typeof e)throw new Error("string expected");return new Uint8Array((new TextEncoder).encode(e))}function p(e){return"string"==typeof e&&(e=h(e)),a(e),e}function v(e){const t=t=>e().update(p(t)).digest(),r=e();return t.outputLen=r.outputLen,t.blockLen=r.blockLen,t.create=()=>e(),t}function g(e){const t=(t,r)=>e(r).update(p(t)).digest(),r=e({});return t.outputLen=r.outputLen,t.blockLen=r.blockLen,t.create=t=>e(t),t}function y(e){const t=(t,r)=>e(r).update(p(t)).digest(),r=e({});return t.outputLen=r.outputLen,t.blockLen=r.blockLen,t.create=t=>e(t),t}t.nextTick=async()=>{},t.Hash=class{},t.wrapConstructor=v,t.wrapConstructorWithOpts=g,t.wrapXOFConstructorWithOpts=y},9266:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),i(r(922),t),i(r(6185),t),i(r(4262),t),i(r(5467),t)},9615:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var i=n(r(4229)),o=n(r(2066)),a=n(r(3961)),s=(0,i.default)((function e(t,r,n){return(0,a.default)((function(r,n,i){return(0,o.default)(n)&&(0,o.default)(i)?e(t,n,i):t(r,n,i)}),r,n)}));t.default=s},9754:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),i(r(5938),t),i(r(6503),t),i(r(5925),t),i(r(724),t),i(r(4811),t),i(r(5953),t),i(r(3113),t)}},t={};function r(n){var i=t[n];if(void 0!==i)return i.exports;var o=t[n]={exports:{}};return e[n].call(o.exports,o,o.exports,r),o.exports}r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}();var n=r(8156);return n.FormoAnalytics})()));
|
|
2
|
+
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define("FormoAnalytics",[],t):"object"==typeof exports?exports.FormoAnalytics=t():e.FormoAnalytics=t()}(self,(()=>(()=>{var e={15:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.parseChainId=function(e){return"string"!=typeof e?0:e.startsWith("0x")||e.startsWith("0X")?parseInt(e,16):parseInt(e,10)}},80:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return null!=e&&"object"==typeof e&&!0===e["@@functional/placeholder"]}},654:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return function t(r,n){switch(arguments.length){case 0:return t;case 1:return(0,o.default)(r)?t:(0,i.default)((function(t){return e(r,t)}));default:return(0,o.default)(r)&&(0,o.default)(n)?t:(0,o.default)(r)?(0,i.default)((function(t){return e(t,n)})):(0,o.default)(n)?(0,i.default)((function(t){return e(r,t)})):e(r,n)}}};var i=n(r(4323)),o=n(r(80))},661:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){return Object.prototype.hasOwnProperty.call(t,e)}},689:function(e,t,r){"use strict";var n=this&&this.__assign||function(){return n=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},n.apply(this,arguments)},i=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{c(n.next(e))}catch(e){o(e)}}function s(e){try{c(n.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}c((n=n.apply(e,t||[])).next())}))},o=this&&this.__generator||function(e,t){var r,n,i,o={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return a.next=s(0),a.throw=s(1),a.return=s(2),"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function s(s){return function(c){return function(s){if(r)throw new TypeError("Generator is already executing.");for(;a&&(a=0,s[0]&&(o=0)),o;)try{if(r=1,n&&(i=2&s[0]?n.return:s[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,s[1])).done)return i;switch(n=0,i&&(s=[2&s[0],i.value]),s[0]){case 0:case 1:i=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,n=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((i=(i=o.trys).length>0&&i[i.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!i||s[1]>i[0]&&s[1]<i[3])){o.label=s[1];break}if(6===s[0]&&o.label<i[1]){o.label=i[1],i=s;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(s);break}i[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],n=0}finally{r=i=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,c])}}},a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.EventQueue=void 0;var s=r(9754),c=r(9266),u=r(8177),d=r(6450),l=a(r(4364)),f=function(){},h=function(){function e(e,t){var r=this;this.queue=[],this.payloadHashes=new Set,this.onPageLeave=function(e){var t=!1,r=!1;function n(){t||(t=!0,e(r),setTimeout((function(){t=!1}),0))}globalThis.addEventListener("beforeunload",(function(){r=!1,n()})),globalThis.addEventListener("blur",(function(){r=!0,n()})),globalThis.addEventListener("focus",(function(){t=!1})),document.addEventListener("pagehide",(function(){r="hidden"===document.visibilityState,n()})),document.addEventListener("visibilitychange",(function(){r=!0,"hidden"===document.visibilityState?n():t=!1}))},t=t||{},this.queue=[],this.writeKey=e,this.url=t.url,this.retryCount=(0,c.clampNumber)(t.retryCount||3,5,1),this.flushAt=(0,c.clampNumber)(t.flushAt||20,20,1),this.maxQueueSize=(0,c.clampNumber)(t.maxQueueSize||512e3,512e3,200),this.flushIntervalMs=(0,c.clampNumber)(t.flushInterval||3e4,3e5,1e4),this.flushed=!0,this.errorHandler=t.errorHandler,this.pendingFlush=null,this.timer=null,this.onPageLeave((function(e){return i(r,void 0,void 0,(function(){return o(this,(function(t){switch(t.label){case 0:return!1!==e?[3,2]:[4,this.flush()];case 1:t.sent(),t.label=2;case 2:return[2]}}))}))}))}return e.prototype.generateMessageId=function(e){return i(this,void 0,void 0,(function(){var t,r,i;return o(this,(function(o){return t=(0,c.toDateHourMinute)(new Date(e.original_timestamp)),r=n(n({},e),{original_timestamp:t}),i=JSON.stringify(r),[2,(0,c.hash)(i)]}))}))},e.prototype.enqueue=function(e,t){return i(this,void 0,void 0,(function(){var r,i,a;return o(this,(function(o){switch(o.label){case 0:return t=t||f,[4,this.generateMessageId(e)];case 1:return r=o.sent(),[4,this.isDuplicate(r)];case 2:return o.sent()?(u.logger.warn("Event already enqueued, try again after ".concat((0,c.millisecondsToSecond)(this.flushIntervalMs)," seconds.")),[2]):(this.queue.push({message:n(n({},e),{message_id:r}),callback:t}),u.logger.log("Event enqueued: ".concat((0,c.getActionDescriptor)(e.type,e.properties))),this.flushed?(i=this.queue.length>=this.flushAt,a=this.queue.reduce((function(e,t){return e+JSON.stringify(t).length}),0)>=this.maxQueueSize,i||a?(this.flush(),[2]):(this.flushIntervalMs&&!this.timer&&(this.timer=setTimeout(this.flush.bind(this),this.flushIntervalMs)),[2])):(this.flushed=!0,this.flush(),[2]))}}))}))},e.prototype.flush=function(e){return i(this,void 0,void 0,(function(){var t,r,i,a,s,c=this;return o(this,(function(o){switch(o.label){case 0:if(e=e||f,this.timer&&(clearTimeout(this.timer),this.timer=null),!this.queue.length)return e(),[2,Promise.resolve()];o.label=1;case 1:return o.trys.push([1,4,,5]),this.pendingFlush?[4,this.pendingFlush]:[3,3];case 2:o.sent(),o.label=3;case 3:return[3,5];case 4:throw t=o.sent(),this.pendingFlush=null,t;case 5:return r=this.queue.splice(0,this.flushAt),this.payloadHashes.clear(),i=(new Date).toISOString(),a=r.map((function(e){return n(n({},e.message),{sent_at:i})})),s=function(t){r.forEach((function(e){var r=e.message;return(0,e.callback)(t,r,a)})),e(t,a)},[2,this.pendingFlush=(0,l.default)("".concat(this.url),{headers:(0,d.EVENTS_API_REQUEST_HEADER)(this.writeKey),method:"POST",body:JSON.stringify(a),keepalive:!0,retries:this.retryCount,retryDelay:function(e){return 1e3*Math.pow(2,e)},retryOn:function(e,t){return c.isErrorRetryable(t)}}).then((function(){return s(),Promise.resolve(a)})).catch((function(e){if("function"==typeof c.errorHandler)return s(e),c.errorHandler(e);if(e.response){var t=new Error(e.response.statusText);throw s(t),t}throw s(e),e}))]}}))}))},e.prototype.isErrorRetryable=function(e){var t,r,n;return!!(0,s.isNetworkError)(e)||!!(null==e?void 0:e.response)&&((null===(t=null==e?void 0:e.response)||void 0===t?void 0:t.status)>=500&&(null===(r=null==e?void 0:e.response)||void 0===r?void 0:r.status)<=599||429===(null===(n=null==e?void 0:e.response)||void 0===n?void 0:n.status))},e.prototype.isDuplicate=function(e){return i(this,void 0,void 0,(function(){return o(this,(function(t){return this.payloadHashes.has(e)?[2,!0]:(this.payloadHashes.add(e),[2,!1])}))}))},e}();t.EventQueue=h},724:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isNetworkError=function(e){return!(!e||!n(e)||"TypeError"!==e.name||"string"!=typeof e.message)&&("Load failed"===e.message?void 0===e.stack:i.has(e.message))};var r=Object.prototype.toString,n=function(e){return"[object Error]"===r.call(e)},i=new Set(["network error","Failed to fetch","NetworkError when attempting to fetch resource.","The Internet connection appears to be offline.","Load failed","Network request failed","fetch failed","terminated"])},879:function(e,t,r){"use strict";var n=this&&this.__assign||function(){return n=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},n.apply(this,arguments)},i=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{c(n.next(e))}catch(e){o(e)}}function s(e){try{c(n.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}c((n=n.apply(e,t||[])).next())}))},o=this&&this.__generator||function(e,t){var r,n,i,o={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return a.next=s(0),a.throw=s(1),a.return=s(2),"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function s(s){return function(c){return function(s){if(r)throw new TypeError("Generator is already executing.");for(;a&&(a=0,s[0]&&(o=0)),o;)try{if(r=1,n&&(i=2&s[0]?n.return:s[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,s[1])).done)return i;switch(n=0,i&&(s=[2&s[0],i.value]),s[0]){case 0:case 1:i=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,n=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((i=(i=o.trys).length>0&&i[i.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!i||s[1]>i[0]&&s[1]<i[3])){o.label=s[1];break}if(6===s[0]&&o.label<i[1]){o.label=i[1],i=s;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(s);break}i[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],n=0}finally{r=i=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,c])}}},a=this&&this.__spreadArray||function(e,t,r){if(r||2===arguments.length)for(var n,i=0,o=t.length;i<o;i++)!n&&i in t||(n||(n=Array.prototype.slice.call(t,0,i)),n[i]=t[i]);return e.concat(n||Array.prototype.slice.call(t))};Object.defineProperty(t,"__esModule",{value:!0}),t.FormoAnalytics=void 0;var s=r(4228),c=r(6450),u=r(8568),d=r(3574),l=r(9266),f=r(922),h=r(9754),p=r(15),v=function(){function e(e,t){var r,n;void 0===t&&(t={}),this.writeKey=e,this.options=t,this._providerListenersMap=new Map,this._providers=[],this._trackedProviders=new Set,this._processingAccountsChanged=!1,this._seenProviders=new Set,this.currentUserId="",this.config={writeKey:e},this.options=t,this.session=new g,this.currentUserId=(0,u.cookie)().get(c.SESSION_USER_ID_KEY)||void 0,this.identify=this.identify.bind(this),this.connect=this.connect.bind(this),this.disconnect=this.disconnect.bind(this),this.chain=this.chain.bind(this),this.signature=this.signature.bind(this),this.transaction=this.transaction.bind(this),this.detect=this.detect.bind(this),this.track=this.track.bind(this),u.Logger.init({enabled:(null===(r=t.logger)||void 0===r?void 0:r.enabled)||!1,enabledLevels:(null===(n=t.logger)||void 0===n?void 0:n.levels)||[]}),this.eventManager=new u.EventManager(new u.EventQueue(this.config.writeKey,{url:c.EVENTS_API_URL,flushAt:t.flushAt,retryCount:t.retryCount,maxQueueSize:t.maxQueueSize,flushInterval:t.flushInterval}));var i=void 0,o=t.provider;o?i=o:"undefined"!=typeof window&&window.ethereum&&(i=window.ethereum),i&&this.trackProvider(i),this.trackPageHit(),this.trackPageHits()}return e.prototype.isProviderMismatch=function(e){return null!=this._provider&&this._provider!==e},e.prototype.isProviderInValidState=function(e){return e&&"function"==typeof e.request&&"function"==typeof e.on&&"function"==typeof e.removeListener},e.init=function(t,r){return i(this,void 0,void 0,(function(){var n,i;return o(this,(function(o){switch(o.label){case 0:return(0,u.initStorageManager)(t),n=new e(t,r),i=n,[4,n.getProviders()];case 1:return i._providers=o.sent(),[4,n.detectWallets(n._providers)];case 2:return o.sent(),n.trackProviders(n._providers),[2,n]}}))}))},e.prototype.page=function(e,t,r,n,a){return i(this,void 0,void 0,(function(){return o(this,(function(i){switch(i.label){case 0:return[4,this.trackPageHit(e,t,r,n,a)];case 1:return i.sent(),[2]}}))}))},e.prototype.reset=function(){this.currentUserId=void 0,(0,u.cookie)().remove(c.LOCAL_ANONYMOUS_ID_KEY),(0,u.cookie)().remove(c.SESSION_USER_ID_KEY),(0,u.cookie)().remove(c.SESSION_WALLET_DETECTED_KEY),(0,u.cookie)().remove(c.SESSION_WALLET_IDENTIFIED_KEY)},e.prototype.connect=function(e,t,r,n){return i(this,arguments,void 0,(function(e,t,r,n){var i,a=e.chainId,s=e.address;return o(this,(function(e){switch(e.label){case 0:return null==a?(u.logger.warn("Connect: Chain ID cannot be null or undefined"),[2]):s?(this.currentChainId=a,(i=this.validateAndChecksumAddress(s))?(this.currentAddress=i,[4,this.trackEvent(c.EventType.CONNECT,{chainId:a,address:this.currentAddress},t,r,n)]):(u.logger.warn('Connect: Invalid address provided ("'.concat(s,'"). Please provide a valid Ethereum address in checksum format.')),[2])):(u.logger.warn("Connect: Address cannot be empty"),[2]);case 1:return e.sent(),[2]}}))}))},e.prototype.disconnect=function(e,t,r,a){return i(this,void 0,void 0,(function(){var i,s,d,l;return o(this,(function(o){switch(o.label){case 0:return i=(null==e?void 0:e.chainId)||this.currentChainId,s=(null==e?void 0:e.address)||this.currentAddress,d=this._provider?this.getProviderInfo(this._provider):null,u.logger.info("Disconnect: Emitting disconnect event with:",{chainId:i,address:s,providerName:null==d?void 0:d.name,rdns:null==d?void 0:d.rdns}),l=n(n({},d&&{providerName:d.name,rdns:d.rdns}),t),[4,this.trackEvent(c.EventType.DISCONNECT,n(n({},i&&{chainId:i}),s&&{address:s}),l,r,a)];case 1:return o.sent(),this.currentAddress=void 0,this.currentChainId=void 0,this.clearActiveProvider(),u.logger.info("Wallet disconnected: Cleared currentAddress, currentChainId, and provider"),[2]}}))}))},e.prototype.chain=function(e,t,r,n){return i(this,arguments,void 0,(function(e,t,r,n){var i=e.chainId,a=e.address;return o(this,(function(e){switch(e.label){case 0:return i&&0!==Number(i)?isNaN(Number(i))?(u.logger.warn("FormoAnalytics::chain: chainId must be a valid decimal number"),[2]):a||this.currentAddress?(this.currentChainId=i,[4,this.trackEvent(c.EventType.CHAIN,{chainId:i,address:a||this.currentAddress},t,r,n)]):(u.logger.warn("FormoAnalytics::chain: address was empty and no previous address has been recorded"),[2]):(u.logger.warn("FormoAnalytics::chain: chainId cannot be empty or 0"),[2]);case 1:return e.sent(),[2]}}))}))},e.prototype.signature=function(e,t,r,a){return i(this,arguments,void 0,(function(e,t,r,i){var a=e.status,s=e.chainId,u=e.address,d=e.message,l=e.signatureHash;return o(this,(function(e){switch(e.label){case 0:return[4,this.trackEvent(c.EventType.SIGNATURE,n({status:a,chainId:s,address:u,message:d},l&&{signatureHash:l}),t,r,i)];case 1:return e.sent(),[2]}}))}))},e.prototype.transaction=function(e,t,r,a){return i(this,arguments,void 0,(function(e,t,r,i){var a=e.status,s=e.chainId,u=e.address,d=e.data,l=e.to,f=e.value,h=e.transactionHash;return o(this,(function(e){switch(e.label){case 0:return[4,this.trackEvent(c.EventType.TRANSACTION,n({status:a,chainId:s,address:u,data:d,to:l,value:f},h&&{transactionHash:h}),t,r,i)];case 1:return e.sent(),[2]}}))}))},e.prototype.identify=function(e,t,r,n){return i(this,void 0,void 0,(function(){var i,a,s,d,l,f,h,p,v,g,y,A,m,_;return o(this,(function(o){switch(o.label){case 0:if(o.trys.push([0,12,,13]),e)return[3,10];u.logger.info("Auto-identifying with providers:",this._providers.map((function(e){return e.info.name}))),i=0,a=this._providers,o.label=1;case 1:if(!(i<a.length))return[3,9];if(s=a[i],!(d=s.provider))return[3,8];o.label=2;case 2:return o.trys.push([2,7,,8]),[4,this.getAddress(d)];case 3:return(l=o.sent())?!(f=this.validateAndChecksumAddress(l))||this.session.isWalletIdentified(f,s.info.rdns)?[3,5]:(u.logger.info("Auto-identifying",f,s.info.name,s.info.rdns),[4,this.identify({address:f,providerName:s.info.name,rdns:s.info.rdns},t,r,n)]):[3,6];case 4:return o.sent(),[3,6];case 5:f&&u.logger.info("Auto-identify: Skipping already identified wallet",f,s.info.name,s.info.rdns),o.label=6;case 6:return[3,8];case 7:return h=o.sent(),u.logger.error("Failed to identify provider ".concat(s.info.name,":"),h),[3,8];case 8:return i++,[3,1];case 9:return[2];case 10:return p=e.userId,v=e.address,g=e.providerName,y=e.rdns,u.logger.info("Identify",v,p,g,y),A=void 0,v?(A=this.validateAndChecksumAddress(v),this.currentAddress=A||void 0,A||null===(_=u.logger.warn)||void 0===_||_.call(u.logger,"Invalid address provided to identify:",v)):this.currentAddress=void 0,p&&(this.currentUserId=p,(0,u.cookie)().set(c.SESSION_USER_ID_KEY,p)),A&&y&&this.session.isWalletIdentified(A,y)?(u.logger.warn("Identify: Wallet ".concat(g||"Unknown"," with address ").concat(A," already identified in this session")),[2]):(A&&y&&this.session.markWalletIdentified(A,y),[4,this.trackEvent(c.EventType.IDENTIFY,{address:A,providerName:g,userId:p,rdns:y},t,r,n)]);case 11:return o.sent(),[3,13];case 12:return m=o.sent(),u.logger.log("identify error",m),[3,13];case 13:return[2]}}))}))},e.prototype.detect=function(e,t,r,n){return i(this,arguments,void 0,(function(e,t,r,n){var i=e.providerName,a=e.rdns;return o(this,(function(e){switch(e.label){case 0:return this.session.isWalletDetected(a)?[2,u.logger.warn("Detect: Wallet ".concat(i," already detected in this session"))]:(this.session.markWalletDetected(a),[4,this.trackEvent(c.EventType.DETECT,{providerName:i,rdns:a},t,r,n)]);case 1:return e.sent(),[2]}}))}))},e.prototype.track=function(e,t,r,n){return i(this,void 0,void 0,(function(){return o(this,(function(i){switch(i.label){case 0:return[4,this.trackEvent(c.EventType.TRACK,{event:e},t,r,n)];case 1:return i.sent(),[2]}}))}))},e.prototype.trackProvider=function(e){u.logger.info("trackProvider",e);try{if(!e)return;if(this._trackedProviders.has(e))return void u.logger.warn("TrackProvider: Provider already tracked.");this.registerAccountsChangedListener(e),this.registerChainChangedListener(e),this.registerConnectListener(e),this.registerRequestListeners(e),this.registerDisconnectListener(e),this._trackedProviders.add(e)}catch(e){u.logger.error("Error tracking provider:",e)}},e.prototype.trackProviders=function(e){try{for(var t=0,r=e;t<r.length;t++){var n=r[t],i=null==n?void 0:n.provider;i&&!this._trackedProviders.has(i)&&this.trackProvider(i)}}catch(e){u.logger.error("Failed to track EIP-6963 providers during initialization:",e)}},e.prototype.addProviderListener=function(e,t,r){var n=this._providerListenersMap.get(e)||{};n[t]=r,this._providerListenersMap.set(e,n)},e.prototype.registerAccountsChangedListener=function(e){var t=this;u.logger.info("registerAccountsChangedListener");var r=function(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];return t.onAccountsChanged(e,r[0])};e.on("accountsChanged",r),this.addProviderListener(e,"accountsChanged",r)},e.prototype.onAccountsChanged=function(e,t){return i(this,void 0,void 0,(function(){return o(this,(function(r){switch(r.label){case 0:if(u.logger.info("onAccountsChanged",t),this._processingAccountsChanged)return u.logger.debug("OnAccountsChanged: Already processing accountsChanged, skipping",{provider:this.getProviderInfo(e).name}),[2];this._processingAccountsChanged=!0,r.label=1;case 1:return r.trys.push([1,,3,4]),[4,this._handleAccountsChanged(e,t)];case 2:return r.sent(),[3,4];case 3:return this._processingAccountsChanged=!1,[7];case 4:return[2]}}))}))},e.prototype._handleAccountsChanged=function(e,t){return i(this,void 0,void 0,(function(){var r,n,i,a,s,c,d,l,f,h;return o(this,(function(o){switch(o.label){case 0:if(0!==t.length)return[3,7];if(this._provider!==e)return[3,5];u.logger.info("OnAccountsChanged: Detecting disconnect, current state:",{currentAddress:this.currentAddress,currentChainId:this.currentChainId,providerMatch:this._provider===e}),o.label=1;case 1:return o.trys.push([1,3,,4]),[4,this.disconnect({chainId:this.currentChainId,address:this.currentAddress})];case 2:return o.sent(),[3,4];case 3:return r=o.sent(),u.logger.error("Failed to disconnect provider on accountsChanged",r),[3,4];case 4:return[3,6];case 5:u.logger.info("OnAccountsChanged: Ignoring disconnect for non-active provider"),o.label=6;case 6:return[2];case 7:if(!(n=this.validateAndChecksumAddress(t[0])))return u.logger.warn("onAccountsChanged: Invalid address received",t[0]),[2];if(!this._provider||this._provider===e)return[3,18];i=this.currentAddress,a=this.validateAndChecksumAddress(n),u.logger.info("OnAccountsChanged: Different provider attempting to connect",{activeProvider:this.getProviderInfo(this._provider).name,eventProvider:this.getProviderInfo(e).name,currentStoredAddress:i,newProviderAddress:a}),o.label=8;case 8:return o.trys.push([8,16,,18]),[4,this.getAccounts(this._provider)];case 9:return s=o.sent(),u.logger.info("OnAccountsChanged: Checking current provider accounts",{activeProvider:this.getProviderInfo(this._provider).name,accountsLength:s?s.length:0,accounts:s}),s&&s.length>0?a&&i&&a!==i?(u.logger.info("OnAccountsChanged: Different address detected, switching providers despite current provider having accounts",{activeProvider:this.getProviderInfo(this._provider).name,eventProvider:this.getProviderInfo(e).name,currentAddress:i,newAddress:a,reason:"Address mismatch indicates wallet switch"}),[4,this.disconnect({chainId:this.currentChainId,address:this.currentAddress})]):[3,11]:[3,13];case 10:return o.sent(),this.clearActiveProvider(),[3,12];case 11:return u.logger.info("OnAccountsChanged: Current provider still has accounts and same address, ignoring new provider",{activeProvider:this.getProviderInfo(this._provider).name,eventProvider:this.getProviderInfo(e).name,activeProviderAccountsCount:s.length,currentAddress:i,newAddress:a}),[2];case 12:return[3,15];case 13:return u.logger.info("OnAccountsChanged: Current provider has no accounts, switching to new provider",{oldProvider:this.getProviderInfo(this._provider).name,newProvider:this.getProviderInfo(e).name,reason:"Current provider has no accounts"}),[4,this.disconnect({chainId:this.currentChainId,address:this.currentAddress})];case 14:o.sent(),this.clearActiveProvider(),o.label=15;case 15:return[3,18];case 16:return c=o.sent(),u.logger.warn("OnAccountsChanged: Could not check current provider accounts, switching to new provider",{error:c instanceof Error?c.message:String(c),errorType:c instanceof Error?c.constructor.name:typeof c,oldProvider:this._provider?this.getProviderInfo(this._provider).name:"unknown",newProvider:this.getProviderInfo(e).name,reason:"Could not check current provider accounts"}),[4,this.disconnect({chainId:this.currentChainId,address:this.currentAddress})];case 17:return o.sent(),this.clearActiveProvider(),[3,18];case 18:return this._provider||(this._provider=e),this._provider===e&&n===this.currentAddress?[2]:[4,this.getCurrentChainId(e)];case 19:return d=o.sent(),l=!this.currentAddress,this.currentAddress=n,this.currentChainId=d,f=this.getProviderInfo(e),u.logger.info("OnAccountsChanged: Detected wallet connection, emitting connect event",{chainId:d,address:n,wasDisconnected:l,providerName:f.name,rdns:f.rdns,hasChainId:!!d}),0===(h=d||0)&&u.logger.info("OnAccountsChanged: Using fallback chainId 0 for connect event"),this.connect({chainId:h,address:n},{providerName:f.name,rdns:f.rdns}).catch((function(e){u.logger.error("Failed to track connect event during account change:",e)})),[2]}}))}))},e.prototype.registerChainChangedListener=function(e){var t=this;u.logger.info("registerChainChangedListener");var r=function(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];return t.onChainChanged(e,r[0])};e.on("chainChanged",r),this.addProviderListener(e,"chainChanged",r)},e.prototype.onChainChanged=function(e,t){return i(this,void 0,void 0,(function(){var r;return o(this,(function(n){if(u.logger.info("onChainChanged",t),r=(0,p.parseChainId)(t),this.isProviderMismatch(e)&&this.handleProviderMismatch(e),!this.currentAddress)return u.logger.info("OnChainChanged: No current address, user appears disconnected"),[2,Promise.resolve()];this._provider||(this._provider=e),this.currentChainId=r;try{return[2,this.chain({chainId:this.currentChainId,address:this.currentAddress})]}catch(e){u.logger.error("OnChainChanged: Failed to emit chain event:",e)}return[2]}))}))},e.prototype.registerConnectListener=function(e){var t=this;u.logger.info("registerConnectListener");var r=function(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];var i=r[0];t.onConnected(e,i)};e.on("connect",r),this.addProviderListener(e,"connect",r)},e.prototype.registerDisconnectListener=function(e){var t=this;u.logger.info("registerDisconnectListener");var r=function(r){return i(t,void 0,void 0,(function(){var t;return o(this,(function(r){switch(r.label){case 0:if(this._provider!==e)return[2];u.logger.info("OnDisconnect: Wallet disconnect event received, current state:",{currentAddress:this.currentAddress,currentChainId:this.currentChainId}),r.label=1;case 1:return r.trys.push([1,3,,4]),[4,this.disconnect({chainId:this.currentChainId,address:this.currentAddress})];case 2:return r.sent(),[3,4];case 3:return t=r.sent(),u.logger.error("Error during disconnect in disconnect listener",t),[3,4];case 4:return[2]}}))}))};e.on("disconnect",r),this.addProviderListener(e,"disconnect",r)},e.prototype.onConnected=function(e,t){return i(this,void 0,void 0,(function(){var r,n,i,a,s,c,d;return o(this,(function(o){switch(o.label){case 0:u.logger.info("onConnected",t),o.label=1;case 1:return o.trys.push([1,3,,4]),(null==t?void 0:t.chainId)&&"string"==typeof t.chainId?(r=(0,p.parseChainId)(t.chainId),[4,this.getAddress(e)]):[2];case 2:return n=o.sent(),r&&n&&(i=!this.currentAddress,this._provider||(this._provider=e),(a=this._provider===e)&&(this.currentChainId=r,this.currentAddress=this.validateAndChecksumAddress(n)||void 0),a&&this.currentAddress?(c=this.getProviderInfo(e),u.logger.info("OnConnected: Detected wallet connection, emitting connect event",{chainId:r,wasDisconnected:i,providerName:c.name,rdns:c.rdns,hasChainId:!!r,isActiveProvider:a}),0===(s=r||0)&&u.logger.info("OnConnected: Using fallback chainId 0 for connect event"),this.connect({chainId:s,address:n},{providerName:c.name,rdns:c.rdns}).catch((function(e){u.logger.error("Failed to track connect event during provider connection:",e)}))):n&&!a&&(c=this.getProviderInfo(e),u.logger.debug("OnConnected: Skipping connect event for non-active provider",{chainId:r,providerName:c.name,rdns:c.rdns,isActiveProvider:a,activeProviderInfo:this._provider?this.getProviderInfo(this._provider):null}))),[3,4];case 3:return d=o.sent(),u.logger.error("Error handling connect event",d),[3,4];case 4:return[2]}}))}))},e.prototype.registerRequestListeners=function(e){var t=this;if(u.logger.info("registerRequestListeners"),e){var r=e.request;if(this.isProviderAlreadyWrapped(e,r))u.logger.info("Provider already wrapped with our SDK; skipping request wrapping.");else{var a=e.request.bind(e),s=function(r){return i(t,[r],void 0,(function(t){var r,s,c,l,f,h,p,v=this,g=t.method,y=t.params;return o(this,(function(t){switch(t.label){case 0:return Array.isArray(y)&&["eth_signTypedData_v4","personal_sign"].includes(g)?(s=this.currentChainId)?[3,2]:[4,this.getCurrentChainId(e)]:[3,6];case 1:s=t.sent(),t.label=2;case 2:r=s,i(v,void 0,void 0,(function(){return o(this,(function(e){try{this.signature(n({status:d.SignatureStatus.REQUESTED},this.buildSignatureEventPayload(g,y,void 0,r)))}catch(e){u.logger.error("Formo: Failed to track signature request",e)}return[2]}))})),t.label=3;case 3:return t.trys.push([3,5,,6]),[4,a({method:g,params:y})];case 4:return(c=t.sent())&&i(v,void 0,void 0,(function(){return o(this,(function(e){try{this.signature(n({status:d.SignatureStatus.CONFIRMED},this.buildSignatureEventPayload(g,y,c,r)))}catch(e){u.logger.error("Formo: Failed to track signature confirmation",e)}return[2]}))})),[2,c];case 5:throw l=t.sent(),4001===(null==(p=l)?void 0:p.code)&&i(v,void 0,void 0,(function(){return o(this,(function(e){try{this.signature(n({status:d.SignatureStatus.REJECTED},this.buildSignatureEventPayload(g,y,void 0,r)))}catch(e){u.logger.error("Formo: Failed to track signature rejection",e)}return[2]}))})),l;case 6:if(!Array.isArray(y)||"eth_sendTransaction"!==g||!y[0])return[3,10];i(v,void 0,void 0,(function(){var t,r;return o(this,(function(i){switch(i.label){case 0:return i.trys.push([0,2,,3]),[4,this.buildTransactionEventPayload(y,e)];case 1:return t=i.sent(),this.transaction(n({status:d.TransactionStatus.STARTED},t)),[3,3];case 2:return r=i.sent(),u.logger.error("Formo: Failed to track transaction start",r),[3,3];case 3:return[2]}}))})),t.label=7;case 7:return t.trys.push([7,9,,10]),[4,a({method:g,params:y})];case 8:return f=t.sent(),i(v,void 0,void 0,(function(){var t,r;return o(this,(function(i){switch(i.label){case 0:return i.trys.push([0,2,,3]),[4,this.buildTransactionEventPayload(y,e)];case 1:return t=i.sent(),this.transaction(n(n({status:d.TransactionStatus.BROADCASTED},t),{transactionHash:f})),this.pollTransactionReceipt(e,f,t),[3,3];case 2:return r=i.sent(),u.logger.error("Formo: Failed to track transaction broadcast",r),[3,3];case 3:return[2]}}))})),[2,f];case 9:throw h=t.sent(),4001===(null==(p=h)?void 0:p.code)&&i(v,void 0,void 0,(function(){var t,r;return o(this,(function(i){switch(i.label){case 0:return i.trys.push([0,2,,3]),[4,this.buildTransactionEventPayload(y,e)];case 1:return t=i.sent(),this.transaction(n({status:d.TransactionStatus.REJECTED},t)),[3,3];case 2:return r=i.sent(),u.logger.error("Formo: Failed to track transaction rejection",r),[3,3];case 3:return[2]}}))})),h;case 10:return[2,a({method:g,params:y})]}}))}))};s[d.WRAPPED_REQUEST_SYMBOL]=!0,e[d.WRAPPED_REQUEST_REF_SYMBOL]=s;try{e.request=s}catch(e){u.logger.warn("Failed to wrap provider.request; skipping",e)}}}else u.logger.error("Provider not found for request (signature, transaction) tracking")},e.prototype.onLocationChange=function(){return i(this,void 0,void 0,(function(){return o(this,(function(e){return(0,u.cookie)().get(c.SESSION_CURRENT_URL_KEY)!==window.location.href&&((0,u.cookie)().set(c.SESSION_CURRENT_URL_KEY,window.location.href),this.trackPageHit()),[2]}))}))},e.prototype.trackPageHits=function(){return i(this,void 0,void 0,(function(){var e,t,r=this;return o(this,(function(n){return e=history.pushState,history.pushState=function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];var n=e.apply(this,t);return window.dispatchEvent(new window.Event("locationchange")),n},t=history.replaceState,history.replaceState=function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];var n=t.apply(this,e);return window.dispatchEvent(new window.Event("locationchange")),n},window.addEventListener("popstate",(function(){return r.onLocationChange()})),window.addEventListener("locationchange",(function(){return r.onLocationChange()})),[2]}))}))},e.prototype.trackPageHit=function(e,t,r,n,a){return i(this,void 0,void 0,(function(){var s=this;return o(this,(function(d){return this.shouldTrack()?(setTimeout((function(){i(s,void 0,void 0,(function(){var i;return o(this,(function(o){switch(o.label){case 0:return o.trys.push([0,2,,3]),[4,this.trackEvent(c.EventType.PAGE,{category:e,name:t},r,n,a)];case 1:return o.sent(),[3,3];case 2:return i=o.sent(),u.logger.error("Formo: Failed to track page hit",i),[3,3];case 3:return[2]}}))}))}),300),[2]):(u.logger.info("Track page hit: Skipping event due to tracking configuration"),[2])}))}))},e.prototype.trackEvent=function(e,t,r,a,s){return i(this,void 0,void 0,(function(){return o(this,(function(i){try{if(!this.shouldTrack())return u.logger.info("Skipping ".concat(e," event due to tracking configuration")),[2];this.eventManager.addEvent(n(n({type:e},t),{properties:r,context:a,callback:s}),this.currentAddress,this.currentUserId)}catch(e){u.logger.error("Error tracking event:",e)}return[2]}))}))},e.prototype.shouldTrack=function(){if("boolean"==typeof this.options.tracking)return this.options.tracking;if(null!==this.options.tracking&&"object"==typeof this.options.tracking&&!Array.isArray(this.options.tracking)){var e=this.options.tracking,t=e.excludeHosts,r=void 0===t?[]:t,n=e.excludePaths,i=void 0===n?[]:n,o=e.excludeChains,a=void 0===o?[]:o;if(r.length>0&&"undefined"!=typeof window){var s=window.location.hostname;if(r.includes(s))return!1}if(i.length>0&&"undefined"!=typeof window){var c=window.location.pathname;if(i.includes(c))return!1}return!(a.length>0&&this.currentChainId&&a.includes(this.currentChainId))}return!(0,h.isLocalhost)()},e.prototype.getProviderInfo=function(e){var t=this._providers.find((function(t){return t.provider===e}));if(t)return{name:t.info.name,rdns:t.info.rdns};var r=this.detectInjectedProviderInfo(e);return{name:r.name,rdns:r.rdns}},e.prototype.detectInjectedProviderInfo=function(e){var t="Injected Provider",r="io.injected.provider",n=e;return n.isMetaMask?(t="MetaMask",r="io.metamask"):n.isCoinbaseWallet?(t="Coinbase Wallet",r="com.coinbase.wallet"):n.isWalletConnect?(t="WalletConnect",r="com.walletconnect"):n.isTrust?(t="Trust Wallet",r="com.trustwallet"):n.isBraveWallet?(t="Brave Wallet",r="com.brave.wallet"):n.isPhantom&&(t="Phantom",r="app.phantom"),{name:t,rdns:r,uuid:"injected-".concat(r.replace(/[^a-zA-Z0-9]/g,"-")),icon:c.DEFAULT_PROVIDER_ICON}},e.prototype.getProviders=function(){return i(this,void 0,void 0,(function(){var e,t,r,n,c,d,l,f,h,p=this;return o(this,(function(v){if(e=(0,s.createStore)(),t=e.getProviders(),e.subscribe((function(e){t=e;for(var r=e.filter((function(e){var t=null==e?void 0:e.provider;return t&&!p._seenProviders.has(t)})),n=0,a=r;n<a.length;n++){var s=a[n];p.safeAddProviderDetail(s)}var c=e.filter((function(e){var t=null==e?void 0:e.provider;return!!t&&!p._trackedProviders.has(t)}));c.length>0&&(p.trackProviders(c),i(p,void 0,void 0,(function(){var e;return o(this,(function(t){switch(t.label){case 0:return t.trys.push([0,2,,3]),[4,this.detectWallets(c)];case 1:return t.sent(),[3,3];case 2:return e=t.sent(),u.logger.error("Formo: Failed to detect wallets",e),[3,3];case 3:return[2]}}))}))),p.cleanupUnavailableProviders()})),0===t.length){if(r="undefined"!=typeof window?window.ethereum:void 0){if(this._injectedProviderDetail&&this._injectedProviderDetail.provider===r)return this._trackedProviders.has(r)||this.trackProvider(r),this._providers.some((function(e){return e.provider===r}))||(this._providers=a(a([],this._providers,!0),[this._injectedProviderDetail],!1)),[2,this._providers];this._trackedProviders.has(r)||this.trackProvider(r),n=this.detectInjectedProviderInfo(r),c={provider:r,info:n},this._injectedProviderDetail=c,this.safeAddProviderDetail(c)}return[2,this._providers]}for(d=t.filter((function(e){var t=null==e?void 0:e.provider;return t&&!p._seenProviders.has(t)})),l=0,f=d;l<f.length;l++)h=f[l],this.safeAddProviderDetail(h);return[2,this._providers]}))}))},Object.defineProperty(e.prototype,"providers",{get:function(){return this._providers},enumerable:!1,configurable:!0}),e.prototype.detectWallets=function(e){return i(this,void 0,void 0,(function(){var t,r,n,i;return o(this,(function(o){switch(o.label){case 0:o.trys.push([0,5,,6]),t=0,r=e,o.label=1;case 1:return t<r.length?(n=r[t],[4,this.detect({providerName:null==n?void 0:n.info.name,rdns:null==n?void 0:n.info.rdns})]):[3,4];case 2:o.sent(),o.label=3;case 3:return t++,[3,1];case 4:return[3,6];case 5:return i=o.sent(),u.logger.error("Error detect all wallets:",i),[3,6];case 6:return[2]}}))}))},Object.defineProperty(e.prototype,"provider",{get:function(){return this._provider},enumerable:!1,configurable:!0}),e.prototype.getAddress=function(e){return i(this,void 0,void 0,(function(){var t,r,n;return o(this,(function(i){switch(i.label){case 0:if(this.currentAddress)return[2,this.currentAddress];if(!(t=e||this.provider))return u.logger.info("The provider is not set"),[2,null];i.label=1;case 1:return i.trys.push([1,3,,4]),[4,this.getAccounts(t)];case 2:return(r=i.sent())&&r.length>0?[2,this.validateAndChecksumAddress(r[0])||null]:[3,4];case 3:return 4001!==(null==(n=i.sent())?void 0:n.code)&&u.logger.error("FormoAnalytics::getAccounts: eth_accounts threw an error",n),[2,null];case 4:return[2,null]}}))}))},e.prototype.getAccounts=function(e){return i(this,void 0,void 0,(function(){var t,r,n,i=this;return o(this,(function(o){switch(o.label){case 0:t=e||this.provider,o.label=1;case 1:return o.trys.push([1,3,,4]),[4,null==t?void 0:t.request({method:"eth_accounts"})];case 2:return(r=o.sent())&&0!==r.length?[2,r.map((function(e){return i.validateAndChecksumAddress(e)})).filter((function(e){return void 0!==e}))]:[2,null];case 3:return 4001!==(null==(n=o.sent())?void 0:n.code)&&u.logger.error("FormoAnalytics::getAccounts: eth_accounts threw an error",n),[2,null];case 4:return[2]}}))}))},e.prototype.getCurrentChainId=function(e){return i(this,void 0,void 0,(function(){var t,r,n;return o(this,(function(i){switch(i.label){case 0:if(!(t=e||this.provider))return u.logger.error("Provider not set for chain ID"),[2,0];i.label=1;case 1:return i.trys.push([1,3,,4]),[4,t.request({method:"eth_chainId"})];case 2:return(r=i.sent())?[2,(0,p.parseChainId)(r)]:(u.logger.info("Chain id not found"),[2,0]);case 3:return n=i.sent(),u.logger.error("eth_chainId threw an error:",n),[2,0];case 4:return[2]}}))}))},e.prototype.buildSignatureEventPayload=function(e,t,r,i){var o,a="personal_sign"===e?t[1]:t[0],s=this.validateAndChecksumAddress(a);if(!s)throw new Error("Invalid address in signature payload: ".concat(a));var c={chainId:null!==(o=null!=i?i:this.currentChainId)&&void 0!==o?o:void 0,address:s};if("personal_sign"===e){var u=Buffer.from(t[0].slice(2),"hex").toString("utf8");return n(n(n({},c),{message:u}),r?{signatureHash:r}:{})}return n(n(n({},c),{message:t[1]}),r?{signatureHash:r}:{})},e.prototype.buildTransactionEventPayload=function(e,t){return i(this,void 0,void 0,(function(){var r,n,i,a,s,c,u,d;return o(this,(function(o){switch(o.label){case 0:if(r=e[0],n=r.data,i=r.from,a=r.to,s=r.value,!(c=this.validateAndChecksumAddress(i)))throw new Error("Invalid address in transaction payload: ".concat(i));return d={},(u=this.currentChainId)?[3,2]:[4,this.getCurrentChainId(t)];case 1:u=o.sent(),o.label=2;case 2:return[2,(d.chainId=u,d.data=n,d.address=c,d.to=a,d.value=s,d)]}}))}))},e.prototype.pollTransactionReceipt=function(e,t,r){return i(this,arguments,void 0,(function(e,t,r,a,s){var c,l,f=this;return void 0===a&&(a=10),void 0===s&&(s=3e3),o(this,(function(h){return c=0,e?(l=function(){return i(f,void 0,void 0,(function(){var i,f;return o(this,(function(o){switch(o.label){case 0:return o.trys.push([0,2,,3]),[4,e.request({method:"eth_getTransactionReceipt",params:[t]})];case 1:if(i=o.sent()){if("0x1"===i.status||1===i.status)return this.transaction(n(n({status:d.TransactionStatus.CONFIRMED},r),{transactionHash:t})),[2];if("0x0"===i.status||0===i.status)return this.transaction(n(n({status:d.TransactionStatus.REVERTED},r),{transactionHash:t})),[2]}return[3,3];case 2:return f=o.sent(),u.logger.error("Error polling transaction receipt",f),[3,3];case 3:return++c<a&&setTimeout(l,s),[2]}}))}))},l(),[2]):[2]}))}))},e.prototype.removeProviderListeners=function(e){var t=this._providerListenersMap.get(e);if(t){for(var r=0,n=Object.entries(t);r<n.length;r++){var i=n[r],o=i[0],a=i[1];try{e.removeListener(o,a)}catch(e){u.logger.warn("Failed to remove listener for ".concat(String(o)),e)}}this._providerListenersMap.delete(e)}},e.prototype.untrackProvider=function(e){try{this.removeProviderListeners(e),this._trackedProviders.delete(e),this._provider===e&&this.clearActiveProvider()}catch(e){u.logger.warn("Failed to untrack provider",e)}},e.prototype.getTrackedProvidersCount=function(){return this._trackedProviders.size},e.prototype.getProviderState=function(){return{totalProviders:this._providers.length,trackedProviders:this._trackedProviders.size,seenProviders:this._seenProviders.size,activeProvider:!!this._provider}},e.prototype.cleanupUnavailableProviders=function(){for(var e=new Set(this._providers.map((function(e){return e.provider}))),t=0,r=Array.from(this._trackedProviders);t<r.length;t++){var n=r[t];e.has(n)||(u.logger.info("Cleaning up unavailable provider: ".concat(n.constructor.name)),this.untrackProvider(n))}},e.prototype.isProviderAlreadyWrapped=function(e,t){return!(!t||"function"!=typeof t||!t[d.WRAPPED_REQUEST_SYMBOL]||e[d.WRAPPED_REQUEST_REF_SYMBOL]!==t)},e.prototype.handleProviderMismatch=function(e){this._provider&&(this.currentChainId=void 0,this.currentAddress=void 0),this._provider=e},e.prototype.validateAndChecksumAddress=function(e){var t=(0,f.getValidAddress)(e);return t?(0,l.toChecksumAddress)(t):void 0},e.prototype.clearActiveProvider=function(){this._provider=void 0},e.prototype.safeAddProviderDetail=function(e){var t=null==e?void 0:e.provider;return!!t&&(this._providers.some((function(e){return e.provider===t}))?(this._seenProviders.add(t),!1):(this._providers=a(a([],this._providers,!0),[e],!1),this._seenProviders.add(t),!0))},e}();t.FormoAnalytics=v;var g=function(){function e(){}return e.prototype.isWalletDetected=function(e){var t;return((null===(t=(0,u.cookie)().get(c.SESSION_WALLET_DETECTED_KEY))||void 0===t?void 0:t.split(","))||[]).includes(e)},e.prototype.markWalletDetected=function(e){var t,r=(null===(t=(0,u.cookie)().get(c.SESSION_WALLET_DETECTED_KEY))||void 0===t?void 0:t.split(","))||[];r.includes(e)||(r.push(e),(0,u.cookie)().set(c.SESSION_WALLET_DETECTED_KEY,r.join(","),{expires:new Date(Date.now()+864e5).toUTCString(),path:"/"}))},e.prototype.isWalletIdentified=function(e,t){var r,n="".concat(e,":").concat(t);return((null===(r=(0,u.cookie)().get(c.SESSION_WALLET_IDENTIFIED_KEY))||void 0===r?void 0:r.split(","))||[]).includes(n)},e.prototype.markWalletIdentified=function(e,t){var r,n="".concat(e,":").concat(t),i=(null===(r=(0,u.cookie)().get(c.SESSION_WALLET_IDENTIFIED_KEY))||void 0===r?void 0:r.split(","))||[];i.includes(n)||(i.push(n),(0,u.cookie)().set(c.SESSION_WALLET_IDENTIFIED_KEY,i.join(","),{expires:new Date(Date.now()+864e5).toUTCString(),path:"/"}))},e}()},922:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.toChecksumAddress=t.getValidAddress=t.isValidAddress=void 0;var n=r(2019),i=r(2672),o=r(9754),a=r(4811),s=function(e){return"string"==typeof e&&""!==e.trim()&&(0,o.isAddress)(e.trim())?e.trim():null};t.isValidAddress=function(e){return null!==s(e)},t.getValidAddress=function(e){return s(e)},t.toChecksumAddress=function(e){if(!(0,o.isAddress)(e,!1))throw new Error("Invalid address "+e);var t=e.toLowerCase().replace(/^0x/i,""),r=(0,o.uint8ArrayToHexString)((0,n.keccak256)((0,o.ensureIfUint8Array)((0,i.utf8ToBytes)(t))));if((0,a.isNullish)(r)||"0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470"===r)return"";for(var s="0x",c=r.replace(/^0x/i,""),u=0;u<t.length;u+=1)parseInt(c[u],16)>7?s+=t[u].toUpperCase():s+=t[u];return s}},1020:(e,t,r)=>{"use strict";var n=r(6540),i=Symbol.for("react.element"),o=Symbol.for("react.fragment"),a=Object.prototype.hasOwnProperty,s=n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,c={key:!0,ref:!0,__self:!0,__source:!0};function u(e,t,r){var n,o={},u=null,d=null;for(n in void 0!==r&&(u=""+r),void 0!==t.key&&(u=""+t.key),void 0!==t.ref&&(d=t.ref),t)a.call(t,n)&&!c.hasOwnProperty(n)&&(o[n]=t[n]);if(e&&e.defaultProps)for(n in t=e.defaultProps)void 0===o[n]&&(o[n]=t[n]);return{$$typeof:i,type:e,key:u,ref:d,props:o,_owner:s.current}}t.Fragment=o,t.jsx=u,t.jsxs=u},1371:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},1388:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.StorageManager=void 0;var i=r(8177),o=n(r(8341)),a=n(r(1968)),s=n(r(6073)),c=["cookieStorage","localStorage","sessionStorage","memoryStorage"],u=function(){function e(e){this.writeKey=e,this.storages=new Map}return e.prototype.getStorage=function(e){if(!this.storages.has(e)){for(var t=this.createStorage(e);!t.isAvailable();){var r=c.indexOf(e);i.logger.warn("Storage ".concat(e," is not available, trying ").concat(c[r+1])),t=this.createStorage(c[r+1])}this.storages.set(e,t)}return this.storages.get(e)},e.prototype.createStorage=function(e){switch(e){case"cookieStorage":return new o.default(this.writeKey);case"localStorage":return new s.default(this.writeKey,localStorage);case"sessionStorage":return new s.default(this.writeKey,sessionStorage);default:return new a.default(this.writeKey)}},e}();t.StorageManager=u},1466:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var i=n(r(654)),o=n(r(9615)),a=(0,i.default)((function(e,t){return(0,o.default)((function(e,t,r){return r}),e,t)}));t.default=a},1484:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.notImplemented=t.bitMask=void 0,t.isBytes=i,t.abytes=o,t.abool=function(e,t){if("boolean"!=typeof t)throw new Error(e+" boolean expected, got "+t)},t.numberToHexUnpadded=a,t.hexToNumber=s,t.bytesToHex=d,t.hexToBytes=h,t.bytesToNumberBE=function(e){return s(d(e))},t.bytesToNumberLE=function(e){return o(e),s(d(Uint8Array.from(e).reverse()))},t.numberToBytesBE=p,t.numberToBytesLE=function(e,t){return p(e,t).reverse()},t.numberToVarBytesBE=function(e){return h(a(e))},t.ensureBytes=function(e,t,r){let n;if("string"==typeof t)try{n=h(t)}catch(t){throw new Error(e+" must be hex string or Uint8Array, cause: "+t)}else{if(!i(t))throw new Error(e+" must be hex string or Uint8Array");n=Uint8Array.from(t)}const o=n.length;if("number"==typeof r&&o!==r)throw new Error(e+" of length "+r+" expected, got "+o);return n},t.concatBytes=v,t.equalBytes=function(e,t){if(e.length!==t.length)return!1;let r=0;for(let n=0;n<e.length;n++)r|=e[n]^t[n];return 0===r},t.utf8ToBytes=function(e){if("string"!=typeof e)throw new Error("string expected");return new Uint8Array((new TextEncoder).encode(e))},t.inRange=y,t.aInRange=function(e,t,r,n){if(!y(t,r,n))throw new Error("expected valid "+e+": "+r+" <= n < "+n+", got "+t)},t.bitLen=function(e){let t;for(t=0;e>r;e>>=n,t+=1);return t},t.bitGet=function(e,t){return e>>BigInt(t)&n},t.bitSet=function(e,t,i){return e|(i?n:r)<<BigInt(t)},t.createHmacDrbg=function(e,t,r){if("number"!=typeof e||e<2)throw new Error("hashLen must be a number");if("number"!=typeof t||t<2)throw new Error("qByteLen must be a number");if("function"!=typeof r)throw new Error("hmacFn must be a function");let n=A(e),i=A(e),o=0;const a=()=>{n.fill(1),i.fill(0),o=0},s=(...e)=>r(i,n,...e),c=(e=A(0))=>{i=s(m([0]),e),n=s(),0!==e.length&&(i=s(m([1]),e),n=s())},u=()=>{if(o++>=1e3)throw new Error("drbg: tried 1000 values");let e=0;const r=[];for(;e<t;){n=s();const t=n.slice();r.push(t),e+=n.length}return v(...r)};return(e,t)=>{let r;for(a(),c(e);!(r=t(u()));)c();return a(),r}},t.validateObject=function(e,t,r={}){const n=(t,r,n)=>{const i=_[r];if("function"!=typeof i)throw new Error("invalid validator function");const o=e[t];if(!(n&&void 0===o||i(o,e)))throw new Error("param "+String(t)+" is invalid. Expected "+r+", got "+o)};for(const[e,r]of Object.entries(t))n(e,r,!1);for(const[e,t]of Object.entries(r))n(e,t,!0);return e},t.memoized=function(e){const t=new WeakMap;return(r,...n)=>{const i=t.get(r);if(void 0!==i)return i;const o=e(r,...n);return t.set(r,o),o}};const r=BigInt(0),n=BigInt(1);function i(e){return e instanceof Uint8Array||ArrayBuffer.isView(e)&&"Uint8Array"===e.constructor.name}function o(e){if(!i(e))throw new Error("Uint8Array expected")}function a(e){const t=e.toString(16);return 1&t.length?"0"+t:t}function s(e){if("string"!=typeof e)throw new Error("hex string expected, got "+typeof e);return""===e?r:BigInt("0x"+e)}const c="function"==typeof Uint8Array.from([]).toHex&&"function"==typeof Uint8Array.fromHex,u=Array.from({length:256},((e,t)=>t.toString(16).padStart(2,"0")));function d(e){if(o(e),c)return e.toHex();let t="";for(let r=0;r<e.length;r++)t+=u[e[r]];return t}const l={_0:48,_9:57,A:65,F:70,a:97,f:102};function f(e){return e>=l._0&&e<=l._9?e-l._0:e>=l.A&&e<=l.F?e-(l.A-10):e>=l.a&&e<=l.f?e-(l.a-10):void 0}function h(e){if("string"!=typeof e)throw new Error("hex string expected, got "+typeof e);if(c)return Uint8Array.fromHex(e);const t=e.length,r=t/2;if(t%2)throw new Error("hex string expected, got unpadded hex of length "+t);const n=new Uint8Array(r);for(let t=0,i=0;t<r;t++,i+=2){const r=f(e.charCodeAt(i)),o=f(e.charCodeAt(i+1));if(void 0===r||void 0===o){const t=e[i]+e[i+1];throw new Error('hex string expected, got non-hex character "'+t+'" at index '+i)}n[t]=16*r+o}return n}function p(e,t){return h(e.toString(16).padStart(2*t,"0"))}function v(...e){let t=0;for(let r=0;r<e.length;r++){const n=e[r];o(n),t+=n.length}const r=new Uint8Array(t);for(let t=0,n=0;t<e.length;t++){const i=e[t];r.set(i,n),n+=i.length}return r}const g=e=>"bigint"==typeof e&&r<=e;function y(e,t,r){return g(e)&&g(t)&&g(r)&&t<=e&&e<r}t.bitMask=e=>(n<<BigInt(e))-n;const A=e=>new Uint8Array(e),m=e=>Uint8Array.from(e),_={bigint:e=>"bigint"==typeof e,function:e=>"function"==typeof e,boolean:e=>"boolean"==typeof e,string:e=>"string"==typeof e,stringOrUint8Array:e=>"string"==typeof e||i(e),isSafeInteger:e=>Number.isSafeInteger(e),array:e=>Array.isArray(e),field:(e,t)=>t.Fp.isValid(e),hash:e=>"function"==typeof e&&Number.isSafeInteger(e.outputLen)};t.notImplemented=()=>{throw new Error("not implemented")}},1565:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},1934:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},1968:function(e,t,r){"use strict";var n,i=this&&this.__extends||(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},n(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var a=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.memoryStorage={},t}return i(t,e),t.prototype.isAvailable=function(){return!0},t.prototype.set=function(e,t){this.memoryStorage[this.getKey(e)]=t},t.prototype.get=function(e){return this.memoryStorage[this.getKey(e)]||null},t.prototype.remove=function(e){delete this.memoryStorage[this.getKey(e)]},t}(o(r(2200)).default);t.default=a},2019:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.keccak512=t.keccak384=t.keccak256=t.keccak224=void 0;const n=r(2955),i=r(2672);t.keccak224=(0,i.wrapHash)(n.keccak_224),t.keccak256=(()=>{const e=(0,i.wrapHash)(n.keccak_256);return e.create=n.keccak_256.create,e})(),t.keccak384=(0,i.wrapHash)(n.keccak_384),t.keccak512=(0,i.wrapHash)(n.keccak_512)},2066:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return"[object Object]"===Object.prototype.toString.call(e)}},2200:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(7532),i=function(){function e(e){this.writeKey=e}return e.prototype.getKey=function(e){return"".concat(n.KEY_PREFIX,"_").concat(this.writeKey,".").concat(e)},e}();t.default=i},2309:(e,t)=>{"use strict";var r,n;Object.defineProperty(t,"__esModule",{value:!0}),t.EventChannel=t.EventType=void 0,function(e){e.PAGE="page",e.IDENTIFY="identify",e.DETECT="detect",e.CONNECT="connect",e.DISCONNECT="disconnect",e.CHAIN="chain",e.SIGNATURE="signature",e.TRANSACTION="transaction",e.TRACK="track"}(r||(t.EventType=r={})),function(e){e.WEB="web",e.MOBILE="mobile",e.SERVER="server",e.SOURCE="source"}(n||(t.EventChannel=n={}))},2317:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.requestProviders=t.announceProvider=void 0,t.announceProvider=function(e){const t=new CustomEvent("eip6963:announceProvider",{detail:Object.freeze(e)});window.dispatchEvent(t);const r=()=>window.dispatchEvent(t);return window.addEventListener("eip6963:requestProvider",r),()=>window.removeEventListener("eip6963:requestProvider",r)},t.requestProviders=function(e){if("undefined"==typeof window)return;const t=t=>e(t.detail);return window.addEventListener("eip6963:announceProvider",t),window.dispatchEvent(new CustomEvent("eip6963:requestProvider")),()=>window.removeEventListener("eip6963:announceProvider",t)}},2318:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.toBig=t.shrSL=t.shrSH=t.rotrSL=t.rotrSH=t.rotrBL=t.rotrBH=t.rotr32L=t.rotr32H=t.rotlSL=t.rotlSH=t.rotlBL=t.rotlBH=t.add5L=t.add5H=t.add4L=t.add4H=t.add3L=t.add3H=void 0,t.add=m,t.fromBig=i,t.split=o;const r=BigInt(2**32-1),n=BigInt(32);function i(e,t=!1){return t?{h:Number(e&r),l:Number(e>>n&r)}:{h:0|Number(e>>n&r),l:0|Number(e&r)}}function o(e,t=!1){const r=e.length;let n=new Uint32Array(r),o=new Uint32Array(r);for(let a=0;a<r;a++){const{h:r,l:s}=i(e[a],t);[n[a],o[a]]=[r,s]}return[n,o]}const a=(e,t)=>BigInt(e>>>0)<<n|BigInt(t>>>0);t.toBig=a;const s=(e,t,r)=>e>>>r;t.shrSH=s;const c=(e,t,r)=>e<<32-r|t>>>r;t.shrSL=c;const u=(e,t,r)=>e>>>r|t<<32-r;t.rotrSH=u;const d=(e,t,r)=>e<<32-r|t>>>r;t.rotrSL=d;const l=(e,t,r)=>e<<64-r|t>>>r-32;t.rotrBH=l;const f=(e,t,r)=>e>>>r-32|t<<64-r;t.rotrBL=f;const h=(e,t)=>t;t.rotr32H=h;const p=(e,t)=>e;t.rotr32L=p;const v=(e,t,r)=>e<<r|t>>>32-r;t.rotlSH=v;const g=(e,t,r)=>t<<r|e>>>32-r;t.rotlSL=g;const y=(e,t,r)=>t<<r-32|e>>>64-r;t.rotlBH=y;const A=(e,t,r)=>e<<r-32|t>>>64-r;function m(e,t,r,n){const i=(t>>>0)+(n>>>0);return{h:e+r+(i/2**32|0)|0,l:0|i}}t.rotlBL=A;const _=(e,t,r)=>(e>>>0)+(t>>>0)+(r>>>0);t.add3L=_;const b=(e,t,r,n)=>t+r+n+(e/2**32|0)|0;t.add3H=b;const E=(e,t,r,n)=>(e>>>0)+(t>>>0)+(r>>>0)+(n>>>0);t.add4L=E;const S=(e,t,r,n,i)=>t+r+n+i+(e/2**32|0)|0;t.add4H=S;const w=(e,t,r,n,i)=>(e>>>0)+(t>>>0)+(r>>>0)+(n>>>0)+(i>>>0);t.add5L=w;const P=(e,t,r,n,i,o)=>t+r+n+i+o+(e/2**32|0)|0;t.add5H=P;const C={fromBig:i,split:o,toBig:a,shrSH:s,shrSL:c,rotrSH:u,rotrSL:d,rotrBH:l,rotrBL:f,rotr32H:h,rotr32L:p,rotlSH:v,rotlSL:g,rotlBH:y,rotlBL:A,add:m,add3L:_,add3H:b,add4L:E,add4H:S,add5H:P,add5L:w};t.default=C},2672:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.assertBytes=t.assertBool=t.utf8ToBytes=t.toHex=t.createView=t.concatBytes=t.bytesToHex=void 0,t.bytesToUtf8=function(e){if(!(e instanceof Uint8Array))throw new TypeError("bytesToUtf8 expected Uint8Array, got "+typeof e);return(new TextDecoder).decode(e)},t.hexToBytes=function(e){const t=e.startsWith("0x")?e.substring(2):e;return(0,o.hexToBytes)(t)},t.equalsBytes=function(e,t){if(e.length!==t.length)return!1;for(let r=0;r<e.length;r++)if(e[r]!==t[r])return!1;return!0},t.wrapHash=function(e){return t=>((0,i.abytes)(t),e(t))};const n=r(1484);Object.defineProperty(t,"assertBool",{enumerable:!0,get:function(){return n.abool}});const i=r(7557);Object.defineProperty(t,"assertBytes",{enumerable:!0,get:function(){return i.abytes}});const o=r(9175);var a=r(9175);Object.defineProperty(t,"bytesToHex",{enumerable:!0,get:function(){return a.bytesToHex}}),Object.defineProperty(t,"concatBytes",{enumerable:!0,get:function(){return a.concatBytes}}),Object.defineProperty(t,"createView",{enumerable:!0,get:function(){return a.createView}}),Object.defineProperty(t,"toHex",{enumerable:!0,get:function(){return a.bytesToHex}}),Object.defineProperty(t,"utf8ToBytes",{enumerable:!0,get:function(){return a.utf8ToBytes}})},2865:function(e,t){"use strict";var r=this&&this.__spreadArray||function(e,t,r){if(r||2===arguments.length)for(var n,i=0,o=t.length;i<o;i++)!n&&i in t||(n||(n=Array.prototype.slice.call(t,0,i)),n[i]=t[i]);return e.concat(n||Array.prototype.slice.call(t))};Object.defineProperty(t,"__esModule",{value:!0}),t.logger=t.Logger=void 0;var n=function(){function e(e,t){void 0===e&&(e=!1),void 0===t&&(t=[]),this.enabled=e,this.enabledLevels=new Set(t)}return e.init=function(t){var r=e.getInstance();void 0!==t.enabled&&r.setEnabled(t.enabled),void 0!==t.enabledLevels&&r.setEnabledLevels(t.enabledLevels)},e.getInstance=function(t){var r,n;return e.instance||(e.instance=new e(null!==(r=null==t?void 0:t.enabled)&&void 0!==r&&r,null!==(n=null==t?void 0:t.enabledLevels)&&void 0!==n?n:[])),e.instance},e.prototype.setEnabled=function(e){this.enabled=e},e.prototype.isLoggingEnabled=function(){return this.enabled},e.prototype.setEnabledLevels=function(e){this.enabledLevels=new Set(e)},e.prototype.getEnabledLevels=function(){return Array.from(this.enabledLevels)},e.prototype.shouldLog=function(e){return!!this.enabled&&this.enabledLevels.has(e)},e.prototype.formatMessage=function(e){var t=(new Date).toLocaleString("en-US",{year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",hour12:!1});return"[Formo SDK][".concat(t,"] ").concat(e)},e.prototype.debug=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];this.shouldLog("debug")&&console.debug.apply(console,r([this.formatMessage(e)],t,!1))},e.prototype.info=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];this.shouldLog("info")&&console.info.apply(console,r([this.formatMessage(e)],t,!1))},e.prototype.warn=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];this.shouldLog("warn")&&console.warn.apply(console,r([this.formatMessage(e)],t,!1))},e.prototype.error=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];this.shouldLog("error")&&console.error.apply(console,r([this.formatMessage(e)],t,!1))},e.prototype.trace=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];this.shouldLog("trace")&&console.trace.apply(console,r([this.formatMessage(e)],t,!1))},e.prototype.log=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];this.info.apply(this,r([e],t,!1))},e}();t.Logger=n,t.logger=n.getInstance()},2955:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.shake256=t.shake128=t.keccak_512=t.keccak_384=t.keccak_256=t.keccak_224=t.sha3_512=t.sha3_384=t.sha3_256=t.sha3_224=t.Keccak=void 0,t.keccakP=m;const n=r(2318),i=r(9175),o=BigInt(0),a=BigInt(1),s=BigInt(2),c=BigInt(7),u=BigInt(256),d=BigInt(113),l=[],f=[],h=[];for(let e=0,t=a,r=1,n=0;e<24;e++){[r,n]=[n,(2*r+3*n)%5],l.push(2*(5*n+r)),f.push((e+1)*(e+2)/2%64);let i=o;for(let e=0;e<7;e++)t=(t<<a^(t>>c)*d)%u,t&s&&(i^=a<<(a<<BigInt(e))-a);h.push(i)}const p=(0,n.split)(h,!0),v=p[0],g=p[1],y=(e,t,r)=>r>32?(0,n.rotlBH)(e,t,r):(0,n.rotlSH)(e,t,r),A=(e,t,r)=>r>32?(0,n.rotlBL)(e,t,r):(0,n.rotlSL)(e,t,r);function m(e,t=24){const r=new Uint32Array(10);for(let n=24-t;n<24;n++){for(let t=0;t<10;t++)r[t]=e[t]^e[t+10]^e[t+20]^e[t+30]^e[t+40];for(let t=0;t<10;t+=2){const n=(t+8)%10,i=(t+2)%10,o=r[i],a=r[i+1],s=y(o,a,1)^r[n],c=A(o,a,1)^r[n+1];for(let r=0;r<50;r+=10)e[t+r]^=s,e[t+r+1]^=c}let t=e[2],i=e[3];for(let r=0;r<24;r++){const n=f[r],o=y(t,i,n),a=A(t,i,n),s=l[r];t=e[s],i=e[s+1],e[s]=o,e[s+1]=a}for(let t=0;t<50;t+=10){for(let n=0;n<10;n++)r[n]=e[t+n];for(let n=0;n<10;n++)e[t+n]^=~r[(n+2)%10]&r[(n+4)%10]}e[0]^=v[n],e[1]^=g[n]}(0,i.clean)(r)}class _ extends i.Hash{constructor(e,t,r,n=!1,o=24){if(super(),this.pos=0,this.posOut=0,this.finished=!1,this.destroyed=!1,this.enableXOF=!1,this.blockLen=e,this.suffix=t,this.outputLen=r,this.enableXOF=n,this.rounds=o,(0,i.anumber)(r),!(0<e&&e<200))throw new Error("only keccak-f1600 function is supported");this.state=new Uint8Array(200),this.state32=(0,i.u32)(this.state)}clone(){return this._cloneInto()}keccak(){(0,i.swap32IfBE)(this.state32),m(this.state32,this.rounds),(0,i.swap32IfBE)(this.state32),this.posOut=0,this.pos=0}update(e){(0,i.aexists)(this),e=(0,i.toBytes)(e),(0,i.abytes)(e);const{blockLen:t,state:r}=this,n=e.length;for(let i=0;i<n;){const o=Math.min(t-this.pos,n-i);for(let t=0;t<o;t++)r[this.pos++]^=e[i++];this.pos===t&&this.keccak()}return this}finish(){if(this.finished)return;this.finished=!0;const{state:e,suffix:t,pos:r,blockLen:n}=this;e[r]^=t,128&t&&r===n-1&&this.keccak(),e[n-1]^=128,this.keccak()}writeInto(e){(0,i.aexists)(this,!1),(0,i.abytes)(e),this.finish();const t=this.state,{blockLen:r}=this;for(let n=0,i=e.length;n<i;){this.posOut>=r&&this.keccak();const o=Math.min(r-this.posOut,i-n);e.set(t.subarray(this.posOut,this.posOut+o),n),this.posOut+=o,n+=o}return e}xofInto(e){if(!this.enableXOF)throw new Error("XOF is not possible for this instance");return this.writeInto(e)}xof(e){return(0,i.anumber)(e),this.xofInto(new Uint8Array(e))}digestInto(e){if((0,i.aoutput)(e,this),this.finished)throw new Error("digest() was already called");return this.writeInto(e),this.destroy(),e}digest(){return this.digestInto(new Uint8Array(this.outputLen))}destroy(){this.destroyed=!0,(0,i.clean)(this.state)}_cloneInto(e){const{blockLen:t,suffix:r,outputLen:n,rounds:i,enableXOF:o}=this;return e||(e=new _(t,r,n,o,i)),e.state32.set(this.state32),e.pos=this.pos,e.posOut=this.posOut,e.finished=this.finished,e.rounds=i,e.suffix=r,e.outputLen=n,e.enableXOF=o,e.destroyed=this.destroyed,e}}t.Keccak=_;const b=(e,t,r)=>(0,i.createHasher)((()=>new _(t,e,r)));t.sha3_224=b(6,144,28),t.sha3_256=b(6,136,32),t.sha3_384=b(6,104,48),t.sha3_512=b(6,72,64),t.keccak_224=b(1,144,28),t.keccak_256=b(1,136,32),t.keccak_384=b(1,104,48),t.keccak_512=b(1,72,64);const E=(e,t,r)=>(0,i.createXOFer)(((n={})=>new _(t,e,void 0===n.dkLen?r:n.dkLen,!0)));t.shake128=E(31,168,16),t.shake256=E(31,136,32)},2970:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.formofy=function(e,t){e&&"undefined"!=typeof window?n.FormoAnalytics.init(e,t).then((function(e){if(window.formo=e,null==t?void 0:t.ready)try{t.ready(e)}catch(e){console.error("Error in FormoAnalytics ready callback:",e)}})).catch((function(e){return console.error("Error initializing FormoAnalytics:",e)})):console.warn("FormoAnalytics not found")};var n=r(879)},3113:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isUint8Array=function(e){var t,r;return e instanceof Uint8Array||"Uint8Array"===(null===(t=null==e?void 0:e.constructor)||void 0===t?void 0:t.name)||"Buffer"===(null===(r=null==e?void 0:e.constructor)||void 0===r?void 0:r.name)},t.uint8ArrayToHexString=function(e){for(var t="0x",r=0,n=e;r<n.length;r++){var i=n[r].toString(16);t+=1===i.length?"0".concat(i):i}return t}},3318:function(e){e.exports=function(){"use strict";function e(e){return Number.isInteger(e)&&e>=0}function t(e){this.name="ArgumentError",this.message=e}return function(r,n){if(n=n||{},"function"!=typeof r)throw new t("fetch must be a function");if("object"!=typeof n)throw new t("defaults must be an object");if(void 0!==n.retries&&!e(n.retries))throw new t("retries must be a positive integer");if(void 0!==n.retryDelay&&!e(n.retryDelay)&&"function"!=typeof n.retryDelay)throw new t("retryDelay must be a positive integer or a function returning a positive integer");if(void 0!==n.retryOn&&!Array.isArray(n.retryOn)&&"function"!=typeof n.retryOn)throw new t("retryOn property expects an array or function");return n=Object.assign({retries:3,retryDelay:1e3,retryOn:[]},n),function(i,o){var a=n.retries,s=n.retryDelay,c=n.retryOn;if(o&&void 0!==o.retries){if(!e(o.retries))throw new t("retries must be a positive integer");a=o.retries}if(o&&void 0!==o.retryDelay){if(!e(o.retryDelay)&&"function"!=typeof o.retryDelay)throw new t("retryDelay must be a positive integer or a function returning a positive integer");s=o.retryDelay}if(o&&o.retryOn){if(!Array.isArray(o.retryOn)&&"function"!=typeof o.retryOn)throw new t("retryOn property expects an array or function");c=o.retryOn}return new Promise((function(e,t){var n=function(n){var s="undefined"!=typeof Request&&i instanceof Request?i.clone():i;r(s,o).then((function(r){if(Array.isArray(c)&&-1===c.indexOf(r.status))e(r);else if("function"==typeof c)try{return Promise.resolve(c(n,null,r)).then((function(t){t?u(n,null,r):e(r)})).catch(t)}catch(e){t(e)}else n<a?u(n,null,r):e(r)})).catch((function(e){if("function"==typeof c)try{Promise.resolve(c(n,e,null)).then((function(r){r?u(n,e,null):t(e)})).catch((function(e){t(e)}))}catch(e){t(e)}else n<a?u(n,e,null):t(e)}))};function u(e,t,r){var i="function"==typeof s?s(e,t,r):s;setTimeout((function(){n(++e)}),i)}n(0)}))}}}()},3358:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.COUNTRY_LIST=t.EVENTS_API_REQUEST_HEADER=t.USER_API_URL=t.EVENTS_API_URL=t.EVENTS_API_HOST=void 0,t.EVENTS_API_HOST="https://events.formo.so",t.EVENTS_API_URL="".concat(t.EVENTS_API_HOST,"/v0/raw_events"),t.USER_API_URL="".concat(t.EVENTS_API_HOST,"/user"),t.EVENTS_API_REQUEST_HEADER=function(e){return{"Content-Type":"application/json",Authorization:"Basic ".concat(e)}},t.COUNTRY_LIST={"Africa/Abidjan":"CI","Africa/Accra":"GH","Africa/Addis_Ababa":"ET","Africa/Algiers":"DZ","Africa/Asmara":"ER","Africa/Asmera":"ER","Africa/Bamako":"ML","Africa/Bangui":"CF","Africa/Banjul":"GM","Africa/Bissau":"GW","Africa/Blantyre":"MW","Africa/Brazzaville":"CG","Africa/Bujumbura":"BI","Africa/Cairo":"EG","Africa/Casablanca":"MA","Africa/Ceuta":"ES","Africa/Conakry":"GN","Africa/Dakar":"SN","Africa/Dar_es_Salaam":"TZ","Africa/Djibouti":"DJ","Africa/Douala":"CM","Africa/El_Aaiun":"EH","Africa/Freetown":"SL","Africa/Gaborone":"BW","Africa/Harare":"ZW","Africa/Johannesburg":"ZA","Africa/Juba":"SS","Africa/Kampala":"UG","Africa/Khartoum":"SD","Africa/Kigali":"RW","Africa/Kinshasa":"CD","Africa/Lagos":"NG","Africa/Libreville":"GA","Africa/Lome":"TG","Africa/Luanda":"AO","Africa/Lubumbashi":"CD","Africa/Lusaka":"ZM","Africa/Malabo":"GQ","Africa/Maputo":"MZ","Africa/Maseru":"LS","Africa/Mbabane":"SZ","Africa/Mogadishu":"SO","Africa/Monrovia":"LR","Africa/Nairobi":"KE","Africa/Ndjamena":"TD","Africa/Niamey":"NE","Africa/Nouakchott":"MR","Africa/Ouagadougou":"BF","Africa/Porto-Novo":"BJ","Africa/Sao_Tome":"ST","Africa/Timbuktu":"ML","Africa/Tripoli":"LY","Africa/Tunis":"TN","Africa/Windhoek":"NA","America/Adak":"US","America/Anchorage":"US","America/Anguilla":"AI","America/Antigua":"AG","America/Araguaina":"BR","America/Argentina/Buenos_Aires":"AR","America/Argentina/Catamarca":"AR","America/Argentina/ComodRivadavia":"AR","America/Argentina/Cordoba":"AR","America/Argentina/Jujuy":"AR","America/Argentina/La_Rioja":"AR","America/Argentina/Mendoza":"AR","America/Argentina/Rio_Gallegos":"AR","America/Argentina/Salta":"AR","America/Argentina/San_Juan":"AR","America/Argentina/San_Luis":"AR","America/Argentina/Tucuman":"AR","America/Argentina/Ushuaia":"AR","America/Aruba":"AW","America/Asuncion":"PY","America/Atikokan":"CA","America/Atka":"US","America/Bahia":"BR","America/Bahia_Banderas":"MX","America/Barbados":"BB","America/Belem":"BR","America/Belize":"BZ","America/Blanc-Sablon":"CA","America/Boa_Vista":"BR","America/Bogota":"CO","America/Boise":"US","America/Buenos_Aires":"AR","America/Cambridge_Bay":"CA","America/Campo_Grande":"BR","America/Cancun":"MX","America/Caracas":"VE","America/Catamarca":"AR","America/Cayenne":"GF","America/Cayman":"KY","America/Chicago":"US","America/Chihuahua":"MX","America/Ciudad_Juarez":"MX","America/Coral_Harbour":"CA","America/Cordoba":"AR","America/Costa_Rica":"CR","America/Creston":"CA","America/Cuiaba":"BR","America/Curacao":"CW","America/Danmarkshavn":"GL","America/Dawson":"CA","America/Dawson_Creek":"CA","America/Denver":"US","America/Detroit":"US","America/Dominica":"DM","America/Edmonton":"CA","America/Eirunepe":"BR","America/El_Salvador":"SV","America/Ensenada":"MX","America/Fort_Nelson":"CA","America/Fort_Wayne":"US","America/Fortaleza":"BR","America/Glace_Bay":"CA","America/Godthab":"GL","America/Goose_Bay":"CA","America/Grand_Turk":"TC","America/Grenada":"GD","America/Guadeloupe":"GP","America/Guatemala":"GT","America/Guayaquil":"EC","America/Guyana":"GY","America/Halifax":"CA","America/Havana":"CU","America/Hermosillo":"MX","America/Indiana/Indianapoli":"US","America/Indiana/Knox":"US","America/Indiana/Marengo":"US","America/Indiana/Petersburg":"US","America/Indiana/Tell_City":"US","America/Indiana/Vevay":"US","America/Indiana/Vincennes":"US","America/Indiana/Winamac":"US","America/Indianapoli":"US","America/Inuvik":"CA","America/Iqaluit":"CA","America/Jamaica":"JM","America/Jujuy":"AR","America/Juneau":"US","America/Kentucky/Louisville":"US","America/Kentucky/Monticello":"US","America/Knox_IN":"US","America/Kralendijk":"BQ","America/La_Paz":"BO","America/Lima":"PE","America/Los_Angeles":"US","America/Louisville":"US","America/Lower_Princes":"SX","America/Maceio":"BR","America/Managua":"NI","America/Manaus":"BR","America/Marigot":"MF","America/Martinique":"MQ","America/Matamoros":"MX","America/Mazatlan":"MX","America/Mendoza":"AR","America/Menominee":"US","America/Merida":"MX","America/Metlakatla":"US","America/Mexico_City":"MX","America/Miquelon":"PM","America/Moncton":"CA","America/Monterrey":"MX","America/Montevideo":"UY","America/Montreal":"CA","America/Montserrat":"MS","America/Nassau":"BS","America/New_York":"US","America/Nipigon":"CA","America/Nome":"US","America/Noronha":"BR","America/North_Dakota/Beulah":"US","America/North_Dakota/Center":"US","America/North_Dakota/New_Salem":"US","America/Nuuk":"GL","America/Ojinaga":"MX","America/Panama":"PA","America/Pangnirtung":"CA","America/Paramaribo":"SR","America/Phoenix":"US,CA","America/Port-au-Prince":"HT","America/Port_of_Spain":"TT","America/Porto_Acre":"BR","America/Porto_Velho":"BR","America/Puerto_Rico":"PR","America/Punta_Arenas":"CL","America/Rainy_River":"CA","America/Rankin_Inlet":"CA","America/Recife":"BR","America/Regina":"CA","America/Resolute":"CA","America/Rio_Branco":"BR","America/Rosario":"AR","America/Santa_Isabel":"MX","America/Santarem":"BR","America/Santiago":"CL","America/Santo_Domingo":"DO","America/Sao_Paulo":"BR","America/Scoresbysund":"GL","America/Shiprock":"US","America/Sitka":"US","America/St_Barthelemy":"BL","America/St_Johns":"CA","America/St_Kitts":"KN","America/St_Lucia":"LC","America/St_Thomas":"VI","America/St_Vincent":"VC","America/Swift_Current":"CA","America/Tegucigalpa":"HN","America/Thule":"GL","America/Thunder_Bay":"CA","America/Tijuana":"MX","America/Toronto":"CA","America/Tortola":"VG","America/Vancouver":"CA","America/Virgin":"VI","America/Whitehorse":"CA","America/Winnipeg":"CA","America/Yakutat":"US","America/Yellowknife":"CA","Antarctica/Casey":"AQ","Antarctica/Davis":"AQ","Antarctica/DumontDUrville":"AQ","Antarctica/Macquarie":"AU","Antarctica/Mawson":"AQ","Antarctica/McMurdo":"AQ","Antarctica/Palmer":"AQ","Antarctica/Rothera":"AQ","Antarctica/South_Pole":"AQ","Antarctica/Syowa":"AQ","Antarctica/Troll":"AQ","Antarctica/Vostok":"AQ","Arctic/Longyearbyen":"SJ","Asia/Aden":"YE","Asia/Almaty":"KZ","Asia/Amman":"JO","Asia/Anadyr":"RU","Asia/Aqtau":"KZ","Asia/Aqtobe":"KZ","Asia/Ashgabat":"TM","Asia/Ashkhabad":"TM","Asia/Atyrau":"KZ","Asia/Baghdad":"IQ","Asia/Bahrain":"BH","Asia/Baku":"AZ","Asia/Bangkok":"TH","Asia/Barnaul":"RU","Asia/Beirut":"LB","Asia/Bishkek":"KG","Asia/Brunei":"BN","Asia/Calcutta":"IN","Asia/Chita":"RU","Asia/Choibalsan":"MN","Asia/Chongqing":"CN","Asia/Chungking":"CN","Asia/Colombo":"LK","Asia/Dacca":"BD","Asia/Damascus":"SY","Asia/Dhaka":"BD","Asia/Dili":"TL","Asia/Dubai":"AE","Asia/Dushanbe":"TJ","Asia/Famagusta":"CY","Asia/Gaza":"PS","Asia/Harbin":"CN","Asia/Hebron":"PS","Asia/Ho_Chi_Minh":"VN","Asia/Hong_Kong":"HK","Asia/Hovd":"MN","Asia/Irkutsk":"RU","Asia/Istanbul":"TR","Asia/Jakarta":"ID","Asia/Jayapura":"ID","Asia/Jerusalem":"IL","Asia/Kabul":"AF","Asia/Kamchatka":"RU","Asia/Karachi":"PK","Asia/Kashgar":"CN","Asia/Kathmandu":"NP","Asia/Katmandu":"NP","Asia/Khandyga":"RU","Asia/Kolkata":"IN","Asia/Krasnoyarsk":"RU","Asia/Kuala_Lumpur":"MY","Asia/Kuching":"MY","Asia/Kuwait":"KW","Asia/Macao":"MO","Asia/Macau":"MO","Asia/Magadan":"RU","Asia/Makassar":"ID","Asia/Manila":"PH","Asia/Muscat":"OM","Asia/Nicosia":"CY","Asia/Novokuznetsk":"RU","Asia/Novosibirsk":"RU","Asia/Omsk":"RU","Asia/Oral":"KZ","Asia/Phnom_Penh":"KH","Asia/Pontianak":"ID","Asia/Pyongyang":"KP","Asia/Qatar":"QA","Asia/Qostanay":"KZ","Asia/Qyzylorda":"KZ","Asia/Rangoon":"MM","Asia/Riyadh":"SA","Asia/Saigon":"VN","Asia/Sakhalin":"RU","Asia/Samarkand":"UZ","Asia/Seoul":"KR","Asia/Shanghai":"CN","Asia/Singapore":"SG","Asia/Srednekolymsk":"RU","Asia/Taipei":"TW","Asia/Tashkent":"UZ","Asia/Tbilisi":"GE","Asia/Tehran":"IR","Asia/Tel_Aviv":"IL","Asia/Thimbu":"BT","Asia/Thimphu":"BT","Asia/Tokyo":"JP","Asia/Tomsk":"RU","Asia/Ujung_Pandang":"ID","Asia/Ulaanbaatar":"MN","Asia/Ulan_Bator":"MN","Asia/Urumqi":"CN","Asia/Ust-Nera":"RU","Asia/Vientiane":"LA","Asia/Vladivostok":"RU","Asia/Yakutsk":"RU","Asia/Yangon":"MM","Asia/Yekaterinburg":"RU","Asia/Yerevan":"AM","Atlantic/Azores":"PT","Atlantic/Bermuda":"BM","Atlantic/Canary":"ES","Atlantic/Cape_Verde":"CV","Atlantic/Faeroe":"FO","Atlantic/Faroe":"FO","Atlantic/Jan_Mayen":"SJ","Atlantic/Madeira":"PT","Atlantic/Reykjavik":"IS","Atlantic/South_Georgia":"GS","Atlantic/St_Helena":"SH","Atlantic/Stanley":"FK","Australia/ACT":"AU","Australia/Adelaide":"AU","Australia/Brisbane":"AU","Australia/Broken_Hill":"AU","Australia/Canberra":"AU","Australia/Currie":"AU","Australia/Darwin":"AU","Australia/Eucla":"AU","Australia/Hobart":"AU","Australia/LHI":"AU","Australia/Lindeman":"AU","Australia/Lord_Howe":"AU","Australia/Melbourne":"AU","Australia/North":"AU","Australia/NSW":"AU","Australia/Perth":"AU","Australia/Queensland":"AU","Australia/South":"AU","Australia/Sydney":"AU","Australia/Tasmania":"AU","Australia/Victoria":"AU","Australia/West":"AU","Australia/Yancowinna":"AU","Brazil/Acre":"BR","Brazil/DeNoronha":"BR","Brazil/East":"BR","Brazil/West":"BR","Canada/Atlantic":"CA","Canada/Central":"CA","Canada/Eastern":"CA","Canada/Mountain":"CA","Canada/Newfoundland":"CA","Canada/Pacific":"CA","Canada/Saskatchewan":"CA","Canada/Yukon":"CA",CET:"CET","Chile/Continental":"CL","Chile/EasterIsland":"CL",CST6CDT:"CST6CDT",Cuba:"CU",EET:"EET",Egypt:"EG",Eire:"IE",EST:"EST",EST5EDT:"EST5EDT","Etc/GMT":"Etc/GMT","Etc/GMT+0":"Etc/GMT+0","Etc/GMT+1":"Etc/GMT+1","Etc/GMT+10":"Etc/GMT+10","Etc/GMT+11":"Etc/GMT+11","Etc/GMT+12":"Etc/GMT+12","Etc/GMT+2":"Etc/GMT+2","Etc/GMT+3":"Etc/GMT+3","Etc/GMT+4":"Etc/GMT+4","Etc/GMT+5":"Etc/GMT+5","Etc/GMT+6":"Etc/GMT+6","Etc/GMT+7":"Etc/GMT+7","Etc/GMT+8":"Etc/GMT+8","Etc/GMT+9":"Etc/GMT+9","Etc/GMT-0":"Etc/GMT-0","Etc/GMT-1":"Etc/GMT-1","Etc/GMT-10":"Etc/GMT-10","Etc/GMT-11":"Etc/GMT-11","Etc/GMT-12":"Etc/GMT-12","Etc/GMT-13":"Etc/GMT-13","Etc/GMT-14":"Etc/GMT-14","Etc/GMT-2":"Etc/GMT-2","Etc/GMT-3":"Etc/GMT-3","Etc/GMT-4":"Etc/GMT-4","Etc/GMT-5":"Etc/GMT-5","Etc/GMT-6":"Etc/GMT-6","Etc/GMT-7":"Etc/GMT-7","Etc/GMT-8":"Etc/GMT-8","Etc/GMT-9":"Etc/GMT-9","Etc/GMT0":"Etc/GMT0","Etc/Greenwich":"Etc/Greenwich","Etc/UCT":"Etc/UCT","Etc/UTC":"Etc/UTC","Etc/Universal":"Etc/Universal","Etc/Zulu":"Etc/Zulu","Europe/Amsterdam":"NL","Europe/Andorra":"AD","Europe/Astrakhan":"RU","Europe/Athens":"GR","Europe/Belfast":"GB","Europe/Belgrade":"RS","Europe/Berlin":"DE","Europe/Bratislava":"SK","Europe/Brussels":"BE","Europe/Bucharest":"RO","Europe/Budapest":"HU","Europe/Busingen":"DE","Europe/Chisinau":"MD","Europe/Copenhagen":"DK","Europe/Dublin":"IE","Europe/Gibraltar":"GI","Europe/Guernsey":"GG","Europe/Helsinki":"FI","Europe/Isle_of_Man":"IM","Europe/Istanbul":"TR","Europe/Jersey":"JE","Europe/Kaliningrad":"RU","Europe/Kiev":"UA","Europe/Kirov":"RU","Europe/Kyiv":"UA","Europe/Lisbon":"PT","Europe/Ljubljana":"SI","Europe/London":"GB","Europe/Luxembourg":"LU","Europe/Madrid":"ES","Europe/Malta":"MT","Europe/Mariehamn":"AX","Europe/Minsk":"BY","Europe/Monaco":"MC","Europe/Moscow":"RU","Europe/Nicosia":"CY","Europe/Oslo":"NO","Europe/Paris":"FR","Europe/Podgorica":"ME","Europe/Prague":"CZ","Europe/Riga":"LV","Europe/Rome":"IT","Europe/Samara":"RU","Europe/San_Marino":"SM","Europe/Sarajevo":"BA","Europe/Saratov":"RU","Europe/Simferopol":"RU","Europe/Skopje":"MK","Europe/Sofia":"BG","Europe/Stockholm":"SE","Europe/Tallinn":"EE","Europe/Tirane":"AL","Europe/Tiraspol":"MD","Europe/Ulyanovsk":"RU","Europe/Uzhgorod":"UA","Europe/Vaduz":"LI","Europe/Vatican":"VA","Europe/Vienna":"AT","Europe/Vilnius":"LT","Europe/Volgograd":"RU","Europe/Warsaw":"PL","Europe/Zagreb":"HR","Europe/Zaporozhye":"UA","Europe/Zurich":"CH",Factory:"Factory",GB:"GB","GB-Eire":"GB",GMT:"GMT","GMT+0":"GMT+0","GMT-0":"GMT-0",GMT0:"GMT0",Greenwich:"Greenwich",Hongkong:"HK",HST:"HST",Iceland:"IS","Indian/Antananarivo":"MG","Indian/Chagos":"IO","Indian/Christmas":"CX","Indian/Cocos":"CC","Indian/Comoro":"KM","Indian/Kerguelen":"TF","Indian/Mahe":"SC","Indian/Maldives":"MV","Indian/Mauritius":"MU","Indian/Mayotte":"YT","Indian/Reunion":"RE",Iran:"IR",Israel:"IL",Jamaica:"JM",Japan:"JP",Kwajalein:"MH",Libya:"LY",MET:"MET","Mexico/BajaNorte":"MX","Mexico/BajaSur":"MX","Mexico/General":"MX",MST:"MST",MST7MDT:"MST7MDT",Navajo:"US",NZ:"NZ","NZ-CHAT":"NZ","Pacific/Apia":"WS","Pacific/Auckland":"NZ","Pacific/Bougainville":"PG","Pacific/Chatham":"NZ","Pacific/Chuuk":"FM","Pacific/Easter":"CL","Pacific/Efate":"VU","Pacific/Enderbury":"KI","Pacific/Fakaofo":"TK","Pacific/Fiji":"FJ","Pacific/Funafuti":"TV","Pacific/Galapagos":"EC","Pacific/Gambier":"PF","Pacific/Guadalcanal":"SB","Pacific/Guam":"GU,MP","Pacific/Honolulu":"US","Pacific/Johnston":"UM","Pacific/Kanton":"KI","Pacific/Kiritimati":"KI","Pacific/Kosrae":"FM","Pacific/Kwajalein":"MH","Pacific/Majuro":"MH","Pacific/Marquesas":"PF","Pacific/Midway":"UM","Pacific/Nauru":"NR","Pacific/Niue":"NU","Pacific/Norfolk":"NF","Pacific/Noumea":"NC","Pacific/Pago_Pago":"AS","Pacific/Palau":"PW","Pacific/Pitcairn":"PN","Pacific/Pohnpei":"FM","Pacific/Ponape":"FM","Pacific/Port_Moresby":"PG","Pacific/Rarotonga":"CK","Pacific/Saipan":"MP","Pacific/Samoa":"AS","Pacific/Tahiti":"PF","Pacific/Tarawa":"KI","Pacific/Tongatapu":"TO","Pacific/Truk":"FM","Pacific/Wake":"UM","Pacific/Wallis":"WF","Pacific/Yap":"FM",Poland:"PL",Portugal:"PT",PRC:"CN",PST8PDT:"PST8PDT",ROC:"TW",ROK:"KR",Singapore:"SG",Turkey:"TR",UCT:"UCT",Universal:"Universal","US/Alaska":"US","US/Aleutian":"US","US/Arizona":"US","US/Central":"US","US/East-Indiana":"US","US/Eastern":"US","US/Hawaii":"US","US/Indiana-Starke":"US","US/Michigan":"US","US/Mountain":"US","US/Pacific":"US","US/Samoa":"AS",UTC:"UTC","W-SU":"RU",WET:"WET",Zulu:"Zulu"}},3500:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),i(r(689),t),i(r(1934),t)},3574:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),i(r(7989),t),i(r(4465),t),i(r(7521),t)},3961:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var i=n(r(4229)),o=n(r(661)),a=(0,i.default)((function(e,t,r){var n,i={};for(n in r=r||{},t=t||{})(0,o.default)(n,t)&&(i[n]=(0,o.default)(n,r)?e(n,t[n],r[n]):t[n]);for(n in r)(0,o.default)(n,r)&&!(0,o.default)(n,i)&&(i[n]=r[n]);return i}));t.default=a},4228:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.requestProviders=t.announceProvider=t.createStore=void 0;var n=r(6349);Object.defineProperty(t,"createStore",{enumerable:!0,get:function(){return n.createStore}});var i=r(2317);Object.defineProperty(t,"announceProvider",{enumerable:!0,get:function(){return i.announceProvider}}),Object.defineProperty(t,"requestProviders",{enumerable:!0,get:function(){return i.requestProviders}})},4229:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return function t(r,n,s){switch(arguments.length){case 0:return t;case 1:return(0,a.default)(r)?t:(0,o.default)((function(t,n){return e(r,t,n)}));case 2:return(0,a.default)(r)&&(0,a.default)(n)?t:(0,a.default)(r)?(0,o.default)((function(t,r){return e(t,n,r)})):(0,a.default)(n)?(0,o.default)((function(t,n){return e(r,t,n)})):(0,i.default)((function(t){return e(r,n,t)}));default:return(0,a.default)(r)&&(0,a.default)(n)&&(0,a.default)(s)?t:(0,a.default)(r)&&(0,a.default)(n)?(0,o.default)((function(t,r){return e(t,r,s)})):(0,a.default)(r)&&(0,a.default)(s)?(0,o.default)((function(t,r){return e(t,n,r)})):(0,a.default)(n)&&(0,a.default)(s)?(0,o.default)((function(t,n){return e(r,t,n)})):(0,a.default)(r)?(0,i.default)((function(t){return e(t,n,s)})):(0,a.default)(n)?(0,i.default)((function(t){return e(r,t,s)})):(0,a.default)(s)?(0,i.default)((function(t){return e(r,n,t)})):e(r,n,s)}}};var i=n(r(4323)),o=n(r(654)),a=n(r(80))},4262:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.clampNumber=t.toDateHourMinute=t.millisecondsToSecond=void 0,t.toSnakeCase=function(e,t){void 0===t&&(t=[]);var n=function(e){return Array.isArray(e)?e.map(n):null!==e&&"object"==typeof e?Object.keys(e).reduce((function(i,o){return i[t.includes(o)?o:r(o)]=t.includes(o)?e[o]:n(e[o]),i}),{}):e};return n(e)};var r=function(e){return e.replace(/([a-z])([A-Z])/g,"$1_$2").replace(/[\s-]+/g,"_").toLowerCase()};t.millisecondsToSecond=function(e){return Math.ceil(e/1e3)},t.toDateHourMinute=function(e){return e.getUTCFullYear()+"-"+("0"+(e.getUTCMonth()+1)).slice(-2)+"-"+("0"+e.getUTCDate()).slice(-2)+" "+("0"+e.getUTCHours()).slice(-2)+":"+("0"+e.getUTCMinutes()).slice(-2)},t.clampNumber=function(e,t,r){return Math.min(Math.max(e,r),t)}},4323:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return function t(r){return 0===arguments.length||(0,i.default)(r)?t:e.apply(this,arguments)}};var i=n(r(80))},4364:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var i=n(r(3318));t.default=(0,i.default)(r.g.fetch)},4465:(e,t)=>{"use strict";var r,n;Object.defineProperty(t,"__esModule",{value:!0}),t.TransactionStatus=t.SignatureStatus=void 0,function(e){e.REQUESTED="requested",e.REJECTED="rejected",e.CONFIRMED="confirmed"}(r||(t.SignatureStatus=r={})),function(e){e.STARTED="started",e.REJECTED="rejected",e.BROADCASTED="broadcasted",e.CONFIRMED="confirmed",e.REVERTED="reverted"}(n||(t.TransactionStatus=n={}))},4476:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="1.19.7"},4811:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isNullish=void 0,t.isNullish=function(e){return null==e}},4848:(e,t,r)=>{"use strict";e.exports=r(1020)},5145:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.crypto=void 0,t.crypto="object"==typeof globalThis&&"crypto"in globalThis?globalThis.crypto:void 0},5190:function(e,t,r){"use strict";var n=this&&this.__assign||function(){return n=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},n.apply(this,arguments)},i=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{c(n.next(e))}catch(e){o(e)}}function s(e){try{c(n.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}c((n=n.apply(e,t||[])).next())}))},o=this&&this.__generator||function(e,t){var r,n,i,o={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return a.next=s(0),a.throw=s(1),a.return=s(2),"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function s(s){return function(c){return function(s){if(r)throw new TypeError("Generator is already executing.");for(;a&&(a=0,s[0]&&(o=0)),o;)try{if(r=1,n&&(i=2&s[0]?n.return:s[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,s[1])).done)return i;switch(n=0,i&&(s=[2&s[0],i.value]),s[0]){case 0:case 1:i=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,n=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((i=(i=o.trys).length>0&&i[i.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!i||s[1]>i[0]&&s[1]<i[3])){o.label=s[1];break}if(6===s[0]&&o.label<i[1]){o.label=i[1],i=s;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(s);break}i[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],n=0}finally{r=i=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,c])}}};Object.defineProperty(t,"__esModule",{value:!0}),t.useFormo=t.FormoAnalyticsProvider=t.FormoAnalyticsContext=void 0;var a=r(4848),s=r(6540),c=r(879),u=r(8568),d={chain:function(){return Promise.resolve()},page:function(){return Promise.resolve()},reset:function(){return Promise.resolve()},detect:function(){return Promise.resolve()},connect:function(){return Promise.resolve()},disconnect:function(){return Promise.resolve()},signature:function(){return Promise.resolve()},transaction:function(){return Promise.resolve()},identify:function(){return Promise.resolve()},track:function(){return Promise.resolve()}};t.FormoAnalyticsContext=(0,s.createContext)(d),t.FormoAnalyticsProvider=function(e){var t=e.writeKey,r=e.disabled,i=void 0!==r&&r,o=e.children;return t?i?(u.logger.warn("FormoAnalytics is disabled"),(0,a.jsx)(a.Fragment,{children:o})):(0,a.jsx)(l,n({},e)):(u.logger.error("FormoAnalyticsProvider: No Write Key provided"),(0,a.jsx)(a.Fragment,{children:o}))};var l=function(e){var r=e.writeKey,n=e.options,l=e.children,f=(0,s.useState)(d),h=f[0],p=f[1],v=(0,s.useRef)(!1);return(0,u.initStorageManager)(r),(0,s.useEffect)((function(){i(void 0,void 0,void 0,(function(){var e,t;return o(this,(function(i){switch(i.label){case 0:if(v.current)return[2];v.current=!0,i.label=1;case 1:return i.trys.push([1,3,,4]),[4,c.FormoAnalytics.init(r,n)];case 2:return e=i.sent(),p(e),u.logger.log("Successfully initialized"),[3,4];case 3:return t=i.sent(),u.logger.error("Failed to initialize",t),[3,4];case 4:return[2]}}))}))}),[r,n]),(0,a.jsx)(t.FormoAnalyticsContext.Provider,{value:h,children:l})};t.useFormo=function(){var e=(0,s.useContext)(t.FormoAnalyticsContext);return e||u.logger.warn("useFormo called without a valid context"),e}},5287:(e,t)=>{"use strict";var r=Symbol.for("react.element"),n=Symbol.for("react.portal"),i=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),c=Symbol.for("react.context"),u=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),l=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),h=Symbol.iterator,p={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},v=Object.assign,g={};function y(e,t,r){this.props=e,this.context=t,this.refs=g,this.updater=r||p}function A(){}function m(e,t,r){this.props=e,this.context=t,this.refs=g,this.updater=r||p}y.prototype.isReactComponent={},y.prototype.setState=function(e,t){if("object"!=typeof e&&"function"!=typeof e&&null!=e)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")},y.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},A.prototype=y.prototype;var _=m.prototype=new A;_.constructor=m,v(_,y.prototype),_.isPureReactComponent=!0;var b=Array.isArray,E=Object.prototype.hasOwnProperty,S={current:null},w={key:!0,ref:!0,__self:!0,__source:!0};function P(e,t,n){var i,o={},a=null,s=null;if(null!=t)for(i in void 0!==t.ref&&(s=t.ref),void 0!==t.key&&(a=""+t.key),t)E.call(t,i)&&!w.hasOwnProperty(i)&&(o[i]=t[i]);var c=arguments.length-2;if(1===c)o.children=n;else if(1<c){for(var u=Array(c),d=0;d<c;d++)u[d]=arguments[d+2];o.children=u}if(e&&e.defaultProps)for(i in c=e.defaultProps)void 0===o[i]&&(o[i]=c[i]);return{$$typeof:r,type:e,key:a,ref:s,props:o,_owner:S.current}}function C(e){return"object"==typeof e&&null!==e&&e.$$typeof===r}var T=/\/+/g;function I(e,t){return"object"==typeof e&&null!==e&&null!=e.key?function(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,(function(e){return t[e]}))}(""+e.key):t.toString(36)}function O(e,t,i,o,a){var s=typeof e;"undefined"!==s&&"boolean"!==s||(e=null);var c=!1;if(null===e)c=!0;else switch(s){case"string":case"number":c=!0;break;case"object":switch(e.$$typeof){case r:case n:c=!0}}if(c)return a=a(c=e),e=""===o?"."+I(c,0):o,b(a)?(i="",null!=e&&(i=e.replace(T,"$&/")+"/"),O(a,t,i,"",(function(e){return e}))):null!=a&&(C(a)&&(a=function(e,t){return{$$typeof:r,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}(a,i+(!a.key||c&&c.key===a.key?"":(""+a.key).replace(T,"$&/")+"/")+e)),t.push(a)),1;if(c=0,o=""===o?".":o+":",b(e))for(var u=0;u<e.length;u++){var d=o+I(s=e[u],u);c+=O(s,t,i,d,a)}else if(d=function(e){return null===e||"object"!=typeof e?null:"function"==typeof(e=h&&e[h]||e["@@iterator"])?e:null}(e),"function"==typeof d)for(e=d.call(e),u=0;!(s=e.next()).done;)c+=O(s=s.value,t,i,d=o+I(s,u++),a);else if("object"===s)throw t=String(e),Error("Objects are not valid as a React child (found: "+("[object Object]"===t?"object with keys {"+Object.keys(e).join(", ")+"}":t)+"). If you meant to render a collection of children, use an array instead.");return c}function M(e,t,r){if(null==e)return e;var n=[],i=0;return O(e,n,"","",(function(e){return t.call(r,e,i++)})),n}function k(e){if(-1===e._status){var t=e._result;(t=t()).then((function(t){0!==e._status&&-1!==e._status||(e._status=1,e._result=t)}),(function(t){0!==e._status&&-1!==e._status||(e._status=2,e._result=t)})),-1===e._status&&(e._status=0,e._result=t)}if(1===e._status)return e._result.default;throw e._result}var U={current:null},L={transition:null},R={ReactCurrentDispatcher:U,ReactCurrentBatchConfig:L,ReactCurrentOwner:S};function j(){throw Error("act(...) is not supported in production builds of React.")}t.Children={map:M,forEach:function(e,t,r){M(e,(function(){t.apply(this,arguments)}),r)},count:function(e){var t=0;return M(e,(function(){t++})),t},toArray:function(e){return M(e,(function(e){return e}))||[]},only:function(e){if(!C(e))throw Error("React.Children.only expected to receive a single React element child.");return e}},t.Component=y,t.Fragment=i,t.Profiler=a,t.PureComponent=m,t.StrictMode=o,t.Suspense=d,t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=R,t.act=j,t.cloneElement=function(e,t,n){if(null==e)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+e+".");var i=v({},e.props),o=e.key,a=e.ref,s=e._owner;if(null!=t){if(void 0!==t.ref&&(a=t.ref,s=S.current),void 0!==t.key&&(o=""+t.key),e.type&&e.type.defaultProps)var c=e.type.defaultProps;for(u in t)E.call(t,u)&&!w.hasOwnProperty(u)&&(i[u]=void 0===t[u]&&void 0!==c?c[u]:t[u])}var u=arguments.length-2;if(1===u)i.children=n;else if(1<u){c=Array(u);for(var d=0;d<u;d++)c[d]=arguments[d+2];i.children=c}return{$$typeof:r,type:e.type,key:o,ref:a,props:i,_owner:s}},t.createContext=function(e){return(e={$$typeof:c,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null}).Provider={$$typeof:s,_context:e},e.Consumer=e},t.createElement=P,t.createFactory=function(e){var t=P.bind(null,e);return t.type=e,t},t.createRef=function(){return{current:null}},t.forwardRef=function(e){return{$$typeof:u,render:e}},t.isValidElement=C,t.lazy=function(e){return{$$typeof:f,_payload:{_status:-1,_result:e},_init:k}},t.memo=function(e,t){return{$$typeof:l,type:e,compare:void 0===t?null:t}},t.startTransition=function(e){var t=L.transition;L.transition={};try{e()}finally{L.transition=t}},t.unstable_act=j,t.useCallback=function(e,t){return U.current.useCallback(e,t)},t.useContext=function(e){return U.current.useContext(e)},t.useDebugValue=function(){},t.useDeferredValue=function(e){return U.current.useDeferredValue(e)},t.useEffect=function(e,t){return U.current.useEffect(e,t)},t.useId=function(){return U.current.useId()},t.useImperativeHandle=function(e,t,r){return U.current.useImperativeHandle(e,t,r)},t.useInsertionEffect=function(e,t){return U.current.useInsertionEffect(e,t)},t.useLayoutEffect=function(e,t){return U.current.useLayoutEffect(e,t)},t.useMemo=function(e,t){return U.current.useMemo(e,t)},t.useReducer=function(e,t,r){return U.current.useReducer(e,t,r)},t.useRef=function(e){return U.current.useRef(e)},t.useState=function(e){return U.current.useState(e)},t.useSyncExternalStore=function(e,t,r){return U.current.useSyncExternalStore(e,t,r)},t.useTransition=function(){return U.current.useTransition()},t.version="18.3.1"},5467:function(e,t){"use strict";var r=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{c(n.next(e))}catch(e){o(e)}}function s(e){try{c(n.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}c((n=n.apply(e,t||[])).next())}))},n=this&&this.__generator||function(e,t){var r,n,i,o={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return a.next=s(0),a.throw=s(1),a.return=s(2),"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function s(s){return function(c){return function(s){if(r)throw new TypeError("Generator is already executing.");for(;a&&(a=0,s[0]&&(o=0)),o;)try{if(r=1,n&&(i=2&s[0]?n.return:s[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,s[1])).done)return i;switch(n=0,i&&(s=[2&s[0],i.value]),s[0]){case 0:case 1:i=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,n=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((i=(i=o.trys).length>0&&i[i.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!i||s[1]>i[0]&&s[1]<i[3])){o.label=s[1];break}if(6===s[0]&&o.label<i[1]){o.label=i[1],i=s;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(s);break}i[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],n=0}finally{r=i=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,c])}}};Object.defineProperty(t,"__esModule",{value:!0}),t.hash=function(e){return r(this,void 0,void 0,(function(){var t,r;return n(this,(function(n){switch(n.label){case 0:return[4,crypto.subtle.digest("SHA-256",(new TextEncoder).encode(e))];case 1:return t=n.sent(),r=new Uint8Array(t),[2,Array.from(r).map((function(e){return e.toString(16).padStart(2,"0")})).join("")]}}))}))},t.generateNativeUUID=function(){return crypto.randomUUID()}},5686:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.generateAnonymousId=void 0,t.getCookieDomain=o;var n=r(9266),i=r(6898);function o(e){if(void 0===e&&(e=window.location.hostname),e.includes("localhost")||/^\d{1,3}(\.\d{1,3}){3}$/.test(e))return"";var t=e.split(".");return t.includes("www")&&t.splice(t.indexOf("www"),1),".".concat(t.join("."))}t.generateAnonymousId=function(e){var t=(0,i.cookie)().get(e);if(t&&"string"==typeof t)return t;var r=(0,n.generateNativeUUID)();return(0,i.cookie)().set(e,r,{maxAge:Date.now()+31536e6,domain:o(),path:"/"}),r}},5925:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.objectToString=t.isPrimitive=t.isError=t.isDate=t.isRegExp=t.isObjectAndNotNull=t.isObject=t.isNumber=t.isBoolean=t.isArray=t.isBigInt=t.isDefinedNotNullAndNotEmptyString=t.isDefinedAndNotNull=t.isDefined=t.isTypeOfError=t.isNullOrUndefined=t.isUndefined=t.isNull=t.isString=t.isFunction=void 0,t.isFunction=function(e){return"function"==typeof e&&Boolean(e.constructor&&e.call&&e.apply)},t.isString=function(e){return"string"==typeof e};var r=function(e){return null===e};t.isNull=r;var n=function(e){return void 0===e};t.isUndefined=n;var i=function(e){return r(e)||n(e)};t.isNullOrUndefined=i,t.isBigInt=function(e){return"bigint"==typeof e},t.isDefined=function(e){return!n(e)};var o=function(e){return!i(e)};t.isDefinedAndNotNull=o,t.isDefinedNotNullAndNotEmptyString=function(e){return o(e)&&""!==e},t.isTypeOfError=function(e){switch(Object.prototype.toString.call(e)){case"[object Error]":case"[object Exception]":case"[object DOMException]":return!0;default:return e instanceof Error}};var a=function(e){return Array.isArray(e)};t.isArray=a,t.isBoolean=function(e){return"boolean"==typeof e},t.isNumber=function(e){return"number"==typeof e};var s=function(e){return"object"==typeof e};t.isObject=s,t.isObjectAndNotNull=function(e){return!r(e)&&s(e)&&!a(e)},t.isRegExp=function(e){return s(e)&&"[object RegExp]"===c(e)},t.isDate=function(e){return s(e)&&"[object Date]"===c(e)},t.isError=function(e){return s(e)&&("[object Error]"===c(e)||e instanceof Error)},t.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e};var c=function(e){return Object.prototype.toString.call(e)};t.objectToString=c},5938:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.checkAddressChecksum=t.isAddress=void 0,t.ensureIfUint8Array=s;var n=r(3113),i=r(2019),o=r(2672),a=r(5953);function s(e){var t;return e instanceof Uint8Array||"Uint8Array"!==(null===(t=null==e?void 0:e.constructor)||void 0===t?void 0:t.name)?e:Uint8Array.from(e)}t.isAddress=function(e,r){return void 0===r&&(r=!0),!("string"!=typeof e&&!(0,n.isUint8Array)(e))&&(i=(0,n.isUint8Array)(e)?(0,n.uint8ArrayToHexString)(e):"string"!=typeof e||(0,a.isHexStrict)(e)||e.toLowerCase().startsWith("0x")?e:"0x".concat(e),!!/^(0x)?[0-9a-f]{40}$/i.test(i)&&(!(!/^(0x|0X)?[0-9a-f]{40}$/.test(i)&&!/^(0x|0X)?[0-9A-F]{40}$/.test(i))||!r||(0,t.checkAddressChecksum)(i)));var i},t.checkAddressChecksum=function(e){if(!/^(0x)?[0-9a-f]{40}$/i.test(e))return!1;for(var t=e.slice(2),r=(0,o.utf8ToBytes)(t.toLowerCase()),a=(0,n.uint8ArrayToHexString)((0,i.keccak256)(s(r))).slice(2),c=0;c<40;c+=1)if(parseInt(a[c],16)>7&&t[c].toUpperCase()!==t[c]||parseInt(a[c],16)<=7&&t[c].toLowerCase()!==t[c])return!1;return!0}},5953:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isHexStrict=void 0,t.isHexStrict=function(e){return"string"==typeof e&&/^((-)?0x[0-9a-f]+|(0x))$/i.test(e)}},6073:function(e,t,r){"use strict";var n,i=this&&this.__extends||(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},n(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var a=r(8177),s=r(7532),c=function(e){function t(t,r){var n=e.call(this,t)||this;return n.backend=r,n}return i(t,e),t.prototype.isAvailable=function(){try{var e="__storage_test__";return this.backend.setItem(e,"1"),this.backend.removeItem(e),!0}catch(e){return!1}},t.prototype.set=function(e,t){"boolean"==typeof t&&(t=!0===t?"true":"false"),"object"==typeof t&&(t=s.JSON_PREFIX+JSON.stringify(t)),this.backend.setItem(this.getKey(e),t)},t.prototype.get=function(e){var t=this.backend.getItem(this.getKey(e));if(!t||"string"!=typeof t)return null;if(["null","undefined"].some((function(e){return e==t})))return null;if(t.startsWith(s.JSON_PREFIX))try{return JSON.parse(t.slice(s.JSON_PREFIX.length))}catch(e){return a.logger.error("[FORMO_ERROR] ".concat(this.backend.constructor.name," failed to parse JSON"),e),null}return["true","false"].some((function(e){return e==t}))?JSON.parse(t):t},t.prototype.remove=function(e){this.backend.removeItem(this.getKey(e))},t}(o(r(2200)).default);t.default=c},6138:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getFormattedTimestamp=t.getCurrentTimeFormatted=void 0;var r=function(e){return e.toISOString()};t.getFormattedTimestamp=r,t.getCurrentTimeFormatted=function(){return r(new Date)}},6185:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getActionDescriptor=void 0,t.getActionDescriptor=function(e,t){var r=e;return(null==t?void 0:t.status)&&(r+=" ".concat(t.status)),"connect"!==e&&"disconnect"!==e||!(null==t?void 0:t.rdns)||(r+=" (".concat(t.rdns,")")),r}},6349:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createStore=void 0;const n=r(2317);t.createStore=function(){const e=new Set;let t=[];const r=()=>(0,n.requestProviders)((r=>{t.some((({info:e})=>e.uuid===r.info.uuid))||(t=[...t,r],e.forEach((e=>e(t,{added:[r]}))))}));let i=r();return{_listeners:()=>e,clear(){e.forEach((e=>e([],{removed:[...t]}))),t=[]},destroy(){this.clear(),e.clear(),i?.()},findProvider:({rdns:e})=>t.find((t=>t.info.rdns===e)),getProviders:()=>t,reset(){this.clear(),i?.(),i=r()},subscribe:(r,{emitImmediately:n}={})=>(e.add(r),n&&r(t,{added:t}),()=>e.delete(r))}}},6450:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),i(r(6921),t),i(r(3358),t),i(r(2309),t)},6452:function(e,t,r){"use strict";var n=this&&this.__rest||function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(n=Object.getOwnPropertySymbols(e);i<n.length;i++)t.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(e,n[i])&&(r[n[i]]=e[n[i]])}return r};Object.defineProperty(t,"__esModule",{value:!0}),t.EventManager=void 0;var i=r(8177),o=r(8337),a=function(){function e(e){this.eventQueue=e,this.eventFactory=new o.EventFactory}return e.prototype.addEvent=function(e,t,r){var o=e.callback,a=n(e,["callback"]),s=this.eventFactory.create(a,t,r);this.eventQueue.enqueue(s,(function(e,t,r){e?i.logger.error("Error sending events:",e):i.logger.info("Events sent successfully: ".concat(r.length," events")),null==o||o(e,t,r)}))},e}();t.EventManager=a},6503:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isLocalhost=void 0,t.isLocalhost=function(){return/^localhost$|^127(?:\.[0-9]+){0,2}\.[0-9]+$|^(?:0*:)*?:?0*1$/.test(window.location.hostname)||"file:"===window.location.protocol}},6540:(e,t,r)=>{"use strict";e.exports=r(5287)},6898:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),t.memory=t.session=t.local=t.cookie=void 0,t.initStorageManager=function(e){a||(a=new o.StorageManager(e))};var o=r(1388);i(r(7892),t);var a=null;function s(e){if(!a)throw new Error("StorageManager not initialized. Call initStorageManager(writeKey) first.");return a.getStorage(e)}t.cookie=function(){return s("cookieStorage")},t.local=function(){return s("localStorage")},t.session=function(){return s("sessionStorage")},t.memory=function(){return s("memoryStorage")}},6921:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DEFAULT_PROVIDER_ICON=t.LOCAL_ANONYMOUS_ID_KEY=t.SESSION_USER_ID_KEY=t.SESSION_CURRENT_URL_KEY=t.SESSION_WALLET_IDENTIFIED_KEY=t.SESSION_WALLET_DETECTED_KEY=t.SESSION_TRAFFIC_SOURCE_KEY=void 0,t.SESSION_TRAFFIC_SOURCE_KEY="traffic-source",t.SESSION_WALLET_DETECTED_KEY="wallet-detected",t.SESSION_WALLET_IDENTIFIED_KEY="wallet-identified",t.SESSION_CURRENT_URL_KEY="analytics-current-url",t.SESSION_USER_ID_KEY="user-id",t.LOCAL_ANONYMOUS_ID_KEY="anonymous-id",t.DEFAULT_PROVIDER_ICON="data:image/svg+xml;base64,"},7034:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.VERSION=t.CHANNEL=void 0,t.CHANNEL="web",t.VERSION="0"},7521:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WRAPPED_REQUEST_REF_SYMBOL=t.WRAPPED_REQUEST_SYMBOL=void 0,t.WRAPPED_REQUEST_SYMBOL=Symbol("formoWrappedRequest"),t.WRAPPED_REQUEST_REF_SYMBOL=Symbol("formoWrappedRequestRef")},7532:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.KEY_PREFIX=t.JSON_PREFIX=void 0,t.JSON_PREFIX="__json=",t.KEY_PREFIX="formo"},7557:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.aoutput=t.anumber=t.aexists=t.abytes=void 0;const n=r(9175);t.abytes=n.abytes,t.aexists=n.aexists,t.anumber=n.anumber,t.aoutput=n.aoutput},7892:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},7967:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),i(r(8337),t),i(r(6452),t),i(r(1371),t)},7989:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},8156:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0});var o=r(2970);i(r(5190),t),i(r(879),t),i(r(3574),t),"undefined"!=typeof window&&(window.formofy=o.formofy)},8177:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),i(r(2865),t),i(r(1565),t)},8337:function(e,t,r){"use strict";var n=this&&this.__assign||function(){return n=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},n.apply(this,arguments)},i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.EventFactory=void 0;var o=r(6450),a=r(9266),s=r(922),c=r(6138),u=r(9754),d=r(8177),l=i(r(1466)),f=r(6898),h=r(4476),p=r(7034),v=r(5686),g=function(){function e(){var e=this;this.extractUTMParameters=function(e){var t={utm_campaign:"",utm_content:"",utm_medium:"",utm_source:"",utm_term:""};try{new URL(e).searchParams.forEach((function(e,r){r.startsWith("utm_")&&(t[r]=e.trim())}))}catch(e){}return t},this.extractReferralParameter=function(e){for(var t,r=0,n=["ref","referral","refcode"];r<n.length;r++){var i=n[r],o=null===(t=e.searchParams.get(i))||void 0===t?void 0:t.trim();if(o)return o}return""},this.getTrafficSources=function(t){var r=new URL(t),i=n(n({},e.extractUTMParameters(t)),{ref:e.extractReferralParameter(r),referrer:document.referrer}),a=(0,f.session)().get(o.SESSION_TRAFFIC_SOURCE_KEY)||{},s={ref:i.ref||(null==a?void 0:a.ref)||"",referrer:i.referrer||(null==a?void 0:a.referrer)||"",utm_campaign:i.utm_campaign||(null==a?void 0:a.utm_campaign)||"",utm_content:i.utm_content||(null==a?void 0:a.utm_content)||"",utm_medium:i.utm_medium||(null==a?void 0:a.utm_medium)||"",utm_source:i.utm_source||(null==a?void 0:a.utm_source)||"",utm_term:i.utm_term||(null==a?void 0:a.utm_term)||""},c=Object.keys(s).reduce((function(e,t){var r=s[t];return(0,u.isUndefined)(r)||""===r||(e[t]=r),e}),{});return Object.keys(c).length&&(0,f.session)().set(o.SESSION_TRAFFIC_SOURCE_KEY,c),s},this.getPageProperties=function(e){var t=e;return(0,u.isUndefined)(t.url)&&(t.url=new URL(globalThis.location.href).href),(0,u.isUndefined)(t.path)&&(t.path=globalThis.location.pathname),(0,u.isUndefined)(t.hash)&&(t.hash=globalThis.location.hash),t},this.getEnrichedEvent=function(t,r){var n={context:e.generateContext(r),original_timestamp:(0,c.getCurrentTimeFormatted)(),user_id:t.user_id,type:t.type,channel:p.CHANNEL,version:p.VERSION};n.anonymous_id=(0,v.generateAnonymousId)(o.LOCAL_ANONYMOUS_ID_KEY);var i=(0,s.getValidAddress)(t.address);n.address=i?(0,a.toChecksumAddress)(i):null;var u=(0,l.default)(t,n);return void 0===u.event&&(u.event=null),void 0===u.properties&&(u.properties=null),(0,a.toSnakeCase)(u)}}return e.prototype.getTimezone=function(){try{return Intl.DateTimeFormat().resolvedOptions().timeZone}catch(e){return d.logger.error("Error resolving timezone:",e),""}},e.prototype.getLocation=function(){try{var e=this.getTimezone();return e in o.COUNTRY_LIST?o.COUNTRY_LIST[e]:e}catch(e){return d.logger.error("Error resolving location:",e),""}},e.prototype.getLanguage=function(){try{return(navigator.languages&&navigator.languages.length?navigator.languages[0]:navigator.language)||"en"}catch(e){return d.logger.error("Error resolving language:",e),"en"}},e.prototype.getLibraryVersion=function(){return h.version},e.prototype.generateContext=function(e){var t=globalThis.location.pathname,r=this.getLanguage(),i=this.getTimezone(),o=this.getLocation(),a=this.getLibraryVersion(),s=n(n({user_agent:globalThis.navigator.userAgent,locale:r,timezone:i,location:o},this.getTrafficSources(globalThis.location.href)),{page_path:t,page_title:document.title,page_url:globalThis.location.href,library_name:"Formo Web SDK",library_version:a});return(0,l.default)(s,e||{})},e.prototype.generatePageEvent=function(e,t,r,n){var i=null!=r?r:{};i.category=e,i.name=t;var o={properties:i=this.getPageProperties(i),type:"page"};return this.getEnrichedEvent(o,n)},e.prototype.generateDetectWalletEvent=function(e,t,r,i){var o={properties:n({providerName:e,rdns:t},r),type:"detect"};return this.getEnrichedEvent(o,i)},e.prototype.generateIdentifyEvent=function(e,t,r,i,o,a){var s={properties:n({providerName:e,rdns:t},o),user_id:i,address:r,type:"identify"};return this.getEnrichedEvent(s,a)},e.prototype.generateConnectEvent=function(e,t,r,i){var o={properties:n({chainId:e},r),address:t,type:"connect"};return this.getEnrichedEvent(o,i)},e.prototype.generateDisconnectEvent=function(e,t,r,i){var o={properties:n({chainId:e},r),address:t,type:"disconnect"};return this.getEnrichedEvent(o,i)},e.prototype.generateChainChangedEvent=function(e,t,r,i){var o={properties:n({chainId:e},r),address:t,type:"chain"};return this.getEnrichedEvent(o,i)},e.prototype.generateSignatureEvent=function(e,t,r,i,o,a,s){var c={properties:n(n({status:e,chainId:t,message:i},o&&{signatureHash:o}),a),address:r,type:"signature"};return this.getEnrichedEvent(c,s)},e.prototype.generateTransactionEvent=function(e,t,r,i,o,a,s,c,u){var d={properties:n(n({status:e,chainId:t,data:i,to:o,value:a},s&&{transactionHash:s}),c),address:r,type:"transaction"};return this.getEnrichedEvent(d,u)},e.prototype.generateTrackEvent=function(e,t,r){var i={properties:n(n(n(n({},t),void 0!==(null==t?void 0:t.revenue)&&{revenue:Number(t.revenue),currency:("string"==typeof(null==t?void 0:t.currency)?t.currency:"USD").toLowerCase()}),void 0!==(null==t?void 0:t.points)&&{points:Number(t.points)}),void 0!==(null==t?void 0:t.volume)&&{volume:Number(t.volume)}),event:e,type:"track"};return this.getEnrichedEvent(i,r)},e.prototype.create=function(e,t,r){var n={};switch(e.type){case"page":n=this.generatePageEvent(e.category,e.name,e.properties,e.context);break;case"detect":n=this.generateDetectWalletEvent(e.providerName,e.rdns,e.properties,e.context);break;case"identify":n=this.generateIdentifyEvent(e.providerName,e.rdns,e.address,e.userId,e.properties,e.context);break;case"chain":n=this.generateChainChangedEvent(e.chainId,e.address,e.properties,e.context);break;case"connect":n=this.generateConnectEvent(e.chainId,e.address,e.properties,e.context);break;case"disconnect":n=this.generateDisconnectEvent(e.chainId,e.address,e.properties,e.context);break;case"signature":n=this.generateSignatureEvent(e.status,e.chainId,e.address,e.message,e.signatureHash,e.properties,e.context);break;case"transaction":n=this.generateTransactionEvent(e.status,e.chainId,e.address,e.data,e.to,e.value,e.transactionHash,e.properties,e.context);break;default:n=this.generateTrackEvent(e.event,e.properties,e.context)}if(void 0===n.address||null===n.address){var i=(0,s.getValidAddress)(t);n.address=i?(0,a.toChecksumAddress)(i):null}return n.user_id=r||null,n},e}();t.EventFactory=g},8341:function(e,t,r){"use strict";var n,i=this&&this.__extends||(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},n(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var a=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t.prototype.isAvailable=function(){return"undefined"!=typeof document&&"string"==typeof document.cookie},t.prototype.set=function(e,t,r){var n=null==r?void 0:r.expires,i=null==r?void 0:r.maxAge,o=(null==r?void 0:r.path)||"/",a=null==r?void 0:r.domain,s=null==r?void 0:r.sameSite,c=(null==r?void 0:r.secure)||!1,u="".concat(encodeURIComponent(this.getKey(e)),"=").concat(encodeURIComponent(t));i?u+="; max-age="+i:n&&(u+="; expires="+n),o&&(u+="; path="+o),a&&(u+="; domain="+a),s&&(u+="; samesite="+s),c&&(u+="; secure"),document.cookie=u},t.prototype.get=function(e){var t=document.cookie.match(new RegExp("(?:^|; )".concat(encodeURIComponent(this.getKey(e)),"=([^;]*)")));return t?decodeURIComponent(t[1]):null},t.prototype.remove=function(e){document.cookie="".concat(encodeURIComponent(this.getKey(e)),"=; path=/; expires=Thu, 01 Jan 1970 00:00:00 GMT")},t}(o(r(2200)).default);t.default=a},8568:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)},o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.fetch=void 0,i(r(7967),t),i(r(8177),t),i(r(3500),t),i(r(6898),t);var a=r(4364);Object.defineProperty(t,"fetch",{enumerable:!0,get:function(){return o(a).default}})},9175:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.wrapXOFConstructorWithOpts=t.wrapConstructorWithOpts=t.wrapConstructor=t.Hash=t.nextTick=t.swap32IfBE=t.byteSwapIfBE=t.swap8IfBE=t.isLE=void 0,t.isBytes=i,t.anumber=o,t.abytes=a,t.ahash=function(e){if("function"!=typeof e||"function"!=typeof e.create)throw new Error("Hash should be wrapped by utils.createHasher");o(e.outputLen),o(e.blockLen)},t.aexists=function(e,t=!0){if(e.destroyed)throw new Error("Hash instance has been destroyed");if(t&&e.finished)throw new Error("Hash#digest() has already been called")},t.aoutput=function(e,t){a(e);const r=t.outputLen;if(e.length<r)throw new Error("digestInto() expects output buffer of length at least "+r)},t.u8=function(e){return new Uint8Array(e.buffer,e.byteOffset,e.byteLength)},t.u32=function(e){return new Uint32Array(e.buffer,e.byteOffset,Math.floor(e.byteLength/4))},t.clean=function(...e){for(let t=0;t<e.length;t++)e[t].fill(0)},t.createView=function(e){return new DataView(e.buffer,e.byteOffset,e.byteLength)},t.rotr=function(e,t){return e<<32-t|e>>>t},t.rotl=function(e,t){return e<<t|e>>>32-t>>>0},t.byteSwap=s,t.byteSwap32=c,t.bytesToHex=function(e){if(a(e),u)return e.toHex();let t="";for(let r=0;r<e.length;r++)t+=d[e[r]];return t},t.hexToBytes=function(e){if("string"!=typeof e)throw new Error("hex string expected, got "+typeof e);if(u)return Uint8Array.fromHex(e);const t=e.length,r=t/2;if(t%2)throw new Error("hex string expected, got unpadded hex of length "+t);const n=new Uint8Array(r);for(let t=0,i=0;t<r;t++,i+=2){const r=f(e.charCodeAt(i)),o=f(e.charCodeAt(i+1));if(void 0===r||void 0===o){const t=e[i]+e[i+1];throw new Error('hex string expected, got non-hex character "'+t+'" at index '+i)}n[t]=16*r+o}return n},t.asyncLoop=async function(e,r,n){let i=Date.now();for(let o=0;o<e;o++){n(o);const e=Date.now()-i;e>=0&&e<r||(await(0,t.nextTick)(),i+=e)}},t.utf8ToBytes=h,t.bytesToUtf8=function(e){return(new TextDecoder).decode(e)},t.toBytes=p,t.kdfInputToBytes=function(e){return"string"==typeof e&&(e=h(e)),a(e),e},t.concatBytes=function(...e){let t=0;for(let r=0;r<e.length;r++){const n=e[r];a(n),t+=n.length}const r=new Uint8Array(t);for(let t=0,n=0;t<e.length;t++){const i=e[t];r.set(i,n),n+=i.length}return r},t.checkOpts=function(e,t){if(void 0!==t&&"[object Object]"!=={}.toString.call(t))throw new Error("options should be object or undefined");return Object.assign(e,t)},t.createHasher=v,t.createOptHasher=g,t.createXOFer=y,t.randomBytes=function(e=32){if(n.crypto&&"function"==typeof n.crypto.getRandomValues)return n.crypto.getRandomValues(new Uint8Array(e));if(n.crypto&&"function"==typeof n.crypto.randomBytes)return Uint8Array.from(n.crypto.randomBytes(e));throw new Error("crypto.getRandomValues must be defined")};const n=r(5145);function i(e){return e instanceof Uint8Array||ArrayBuffer.isView(e)&&"Uint8Array"===e.constructor.name}function o(e){if(!Number.isSafeInteger(e)||e<0)throw new Error("positive integer expected, got "+e)}function a(e,...t){if(!i(e))throw new Error("Uint8Array expected");if(t.length>0&&!t.includes(e.length))throw new Error("Uint8Array expected of length "+t+", got length="+e.length)}function s(e){return e<<24&4278190080|e<<8&16711680|e>>>8&65280|e>>>24&255}function c(e){for(let t=0;t<e.length;t++)e[t]=s(e[t]);return e}t.isLE=68===new Uint8Array(new Uint32Array([287454020]).buffer)[0],t.swap8IfBE=t.isLE?e=>e:e=>s(e),t.byteSwapIfBE=t.swap8IfBE,t.swap32IfBE=t.isLE?e=>e:c;const u=(()=>"function"==typeof Uint8Array.from([]).toHex&&"function"==typeof Uint8Array.fromHex)(),d=Array.from({length:256},((e,t)=>t.toString(16).padStart(2,"0"))),l={_0:48,_9:57,A:65,F:70,a:97,f:102};function f(e){return e>=l._0&&e<=l._9?e-l._0:e>=l.A&&e<=l.F?e-(l.A-10):e>=l.a&&e<=l.f?e-(l.a-10):void 0}function h(e){if("string"!=typeof e)throw new Error("string expected");return new Uint8Array((new TextEncoder).encode(e))}function p(e){return"string"==typeof e&&(e=h(e)),a(e),e}function v(e){const t=t=>e().update(p(t)).digest(),r=e();return t.outputLen=r.outputLen,t.blockLen=r.blockLen,t.create=()=>e(),t}function g(e){const t=(t,r)=>e(r).update(p(t)).digest(),r=e({});return t.outputLen=r.outputLen,t.blockLen=r.blockLen,t.create=t=>e(t),t}function y(e){const t=(t,r)=>e(r).update(p(t)).digest(),r=e({});return t.outputLen=r.outputLen,t.blockLen=r.blockLen,t.create=t=>e(t),t}t.nextTick=async()=>{},t.Hash=class{},t.wrapConstructor=v,t.wrapConstructorWithOpts=g,t.wrapXOFConstructorWithOpts=y},9266:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),i(r(922),t),i(r(6185),t),i(r(4262),t),i(r(5467),t)},9615:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var i=n(r(4229)),o=n(r(2066)),a=n(r(3961)),s=(0,i.default)((function e(t,r,n){return(0,a.default)((function(r,n,i){return(0,o.default)(n)&&(0,o.default)(i)?e(t,n,i):t(r,n,i)}),r,n)}));t.default=s},9754:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),i=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),i(r(5938),t),i(r(6503),t),i(r(5925),t),i(r(724),t),i(r(4811),t),i(r(5953),t),i(r(3113),t)}},t={};function r(n){var i=t[n];if(void 0!==i)return i.exports;var o=t[n]={exports:{}};return e[n].call(o.exports,o,o.exports,r),o.exports}r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}();var n=r(8156);return n.FormoAnalytics})()));
|
|
3
3
|
//# sourceMappingURL=index.umd.min.js.map
|