From e5150af03977833483fb8967cc2f3c8fe22d2f2e Mon Sep 17 00:00:00 2001 From: NotEternal Date: Tue, 21 Jun 2022 09:52:09 +0200 Subject: [PATCH] Version update --- asset-manifest.json | 91 +-- index.html | 2 +- locales/de.json | 12 +- locales/en.json | 12 +- locales/es.json | 12 +- locales/it.json | 12 +- locales/iw.json | 12 +- locales/ru.json | 12 +- locales/tr.json | 618 +++++++++--------- locales/zh.json | 12 +- ...nifest.8208b73a7a1eec7983c4ff3046696139.js | 168 ++--- service-worker.js | 2 +- static/css/3.a1ab5bd7.chunk.css | 2 +- ...2218.chunk.css => main.c9ee16f2.chunk.css} | 0 static/js/0.010e1646.chunk.js | 1 + static/js/0.0c8959de.chunk.js | 1 - static/js/3.9d3b560a.chunk.js | 2 - static/js/3.cc9b9445.chunk.js | 2 + ...SE.txt => 3.cc9b9445.chunk.js.LICENSE.txt} | 24 +- static/js/4.4a54806d.chunk.js | 1 - static/js/4.8903312b.chunk.js | 1 + static/js/5.0e309873.chunk.js | 2 + static/js/5.0e309873.chunk.js.LICENSE.txt | 23 + static/js/5.2c3c3ed9.chunk.js | 2 - static/js/5.2c3c3ed9.chunk.js.LICENSE.txt | 8 - ....01f07149.chunk.js => 6.73b67430.chunk.js} | 2 +- static/js/7.f9293408.chunk.js | 1 + static/js/main.8d7ad959.chunk.js | 1 - static/js/main.aeb7ae13.chunk.js | 1 + static/js/runtime-main.e923fa6f.js | 1 + static/js/runtime-main.f0688bb1.js | 1 - ...fab91.svg => arrow-down-blue.cd061363.svg} | 0 ...a6a99.svg => arrow-down-grey.c0dedd2f.svg} | 0 ....e96d8158.svg => arrow-right.d285b6cf.svg} | 0 ...urora.d13b261c.svg => aurora.e7a52317.svg} | 0 ....e62a99c3.svg => blue-loader.904b44c2.svg} | 0 ....5dd950ec.svg => circle-grey.ed2a1dad.svg} | 0 ...ircle.716403ba.svg => circle.2d975615.svg} | 0 ...76.svg => coinbaseWalletIcon.62578f59.svg} | 0 .../{cro.73b9bf96.svg => cro.f578d9cd.svg} | 0 .../{de.4b9a7c89.svg => de.78feb91b.svg} | 0 ...0a3ae25.svg => dropdown-blue.b20914ec.svg} | 0 ...own.50dbd07d.svg => dropdown.7d32d2fa.svg} | 0 ....345dad74.svg => dropup-blue.b96d70e1.svg} | 0 .../{en.42219103.svg => en.8886b28b.svg} | 0 .../{es.6273c78a.svg => es.426a1551.svg} | 0 .../{fuse.306cb394.svg => fuse.65ec5752.svg} | 0 .../{it.7e79b672.svg => it.1d72a5de.svg} | 0 .../{iw.01c3fe8a.svg => iw.51984728.svg} | 0 ...c682.svg => magnifying-glass.67440097.svg} | 0 .../{menu.981ecca4.svg => menu.4f2c4440.svg} | 0 ...d245621.svg => optimisticEth.7b05fcf4.svg} | 0 ...ue.899a4aa9.svg => plus-blue.e8021e51.svg} | 0 ...ey.62281ca8.svg => plus-grey.d8e0be7d.svg} | 0 ...761ff9c.svg => question-mark.1ae4d9f4.svg} | 0 ...ion.63be1e24.svg => question.a46e8bc1.svg} | 0 .../{ru.5d71cdb2.svg => ru.ab61f31e.svg} | 0 ...nner.a9842492.svg => spinner.be00fc4a.svg} | 0 .../{tomo.7cbcd424.svg => tomo.db76ba27.svg} | 0 ...ac2.svg => walletConnectIcon.8215855c.svg} | 0 .../{zh.1a6fff51.svg => zh.5c573ebe.svg} | 0 61 files changed, 552 insertions(+), 489 deletions(-) rename precache-manifest.457ae0c736914514271fc5c1b70b5e31.js => precache-manifest.8208b73a7a1eec7983c4ff3046696139.js (63%) rename static/css/{main.904b2218.chunk.css => main.c9ee16f2.chunk.css} (100%) create mode 100644 static/js/0.010e1646.chunk.js delete mode 100644 static/js/0.0c8959de.chunk.js delete mode 100644 static/js/3.9d3b560a.chunk.js create mode 100644 static/js/3.cc9b9445.chunk.js rename static/js/{3.9d3b560a.chunk.js.LICENSE.txt => 3.cc9b9445.chunk.js.LICENSE.txt} (69%) delete mode 100644 static/js/4.4a54806d.chunk.js create mode 100644 static/js/4.8903312b.chunk.js create mode 100644 static/js/5.0e309873.chunk.js create mode 100644 static/js/5.0e309873.chunk.js.LICENSE.txt delete mode 100644 static/js/5.2c3c3ed9.chunk.js delete mode 100644 static/js/5.2c3c3ed9.chunk.js.LICENSE.txt rename static/js/{6.01f07149.chunk.js => 6.73b67430.chunk.js} (65%) create mode 100644 static/js/7.f9293408.chunk.js delete mode 100644 static/js/main.8d7ad959.chunk.js create mode 100644 static/js/main.aeb7ae13.chunk.js create mode 100644 static/js/runtime-main.e923fa6f.js delete mode 100644 static/js/runtime-main.f0688bb1.js rename static/media/{arrow-down-blue.114fab91.svg => arrow-down-blue.cd061363.svg} (100%) rename static/media/{arrow-down-grey.4d4a6a99.svg => arrow-down-grey.c0dedd2f.svg} (100%) rename static/media/{arrow-right.e96d8158.svg => arrow-right.d285b6cf.svg} (100%) rename static/media/{aurora.d13b261c.svg => aurora.e7a52317.svg} (100%) rename static/media/{blue-loader.e62a99c3.svg => blue-loader.904b44c2.svg} (100%) rename static/media/{circle-grey.5dd950ec.svg => circle-grey.ed2a1dad.svg} (100%) rename static/media/{circle.716403ba.svg => circle.2d975615.svg} (100%) rename static/media/{coinbaseWalletIcon.aa4c7a76.svg => coinbaseWalletIcon.62578f59.svg} (100%) rename static/media/{cro.73b9bf96.svg => cro.f578d9cd.svg} (100%) rename static/media/{de.4b9a7c89.svg => de.78feb91b.svg} (100%) rename static/media/{dropdown-blue.80a3ae25.svg => dropdown-blue.b20914ec.svg} (100%) rename static/media/{dropdown.50dbd07d.svg => dropdown.7d32d2fa.svg} (100%) rename static/media/{dropup-blue.345dad74.svg => dropup-blue.b96d70e1.svg} (100%) rename static/media/{en.42219103.svg => en.8886b28b.svg} (100%) rename static/media/{es.6273c78a.svg => es.426a1551.svg} (100%) rename static/media/{fuse.306cb394.svg => fuse.65ec5752.svg} (100%) rename static/media/{it.7e79b672.svg => it.1d72a5de.svg} (100%) rename static/media/{iw.01c3fe8a.svg => iw.51984728.svg} (100%) rename static/media/{magnifying-glass.52eac682.svg => magnifying-glass.67440097.svg} (100%) rename static/media/{menu.981ecca4.svg => menu.4f2c4440.svg} (100%) rename static/media/{optimisticEth.0d245621.svg => optimisticEth.7b05fcf4.svg} (100%) rename static/media/{plus-blue.899a4aa9.svg => plus-blue.e8021e51.svg} (100%) rename static/media/{plus-grey.62281ca8.svg => plus-grey.d8e0be7d.svg} (100%) rename static/media/{question-mark.1761ff9c.svg => question-mark.1ae4d9f4.svg} (100%) rename static/media/{question.63be1e24.svg => question.a46e8bc1.svg} (100%) rename static/media/{ru.5d71cdb2.svg => ru.ab61f31e.svg} (100%) rename static/media/{spinner.a9842492.svg => spinner.be00fc4a.svg} (100%) rename static/media/{tomo.7cbcd424.svg => tomo.db76ba27.svg} (100%) rename static/media/{walletConnectIcon.5e81cac2.svg => walletConnectIcon.8215855c.svg} (100%) rename static/media/{zh.1a6fff51.svg => zh.5c573ebe.svg} (100%) diff --git a/asset-manifest.json b/asset-manifest.json index e456525..66593eb 100644 --- a/asset-manifest.json +++ b/asset-manifest.json @@ -1,74 +1,75 @@ { "files": { - "static/js/0.0c8959de.chunk.js": "./static/js/0.0c8959de.chunk.js", - "main.css": "./static/css/main.904b2218.chunk.css", - "main.js": "./static/js/main.8d7ad959.chunk.js", - "runtime-main.js": "./static/js/runtime-main.f0688bb1.js", + "static/js/0.010e1646.chunk.js": "./static/js/0.010e1646.chunk.js", + "main.css": "./static/css/main.c9ee16f2.chunk.css", + "main.js": "./static/js/main.aeb7ae13.chunk.js", + "runtime-main.js": "./static/js/runtime-main.e923fa6f.js", "static/css/3.a1ab5bd7.chunk.css": "./static/css/3.a1ab5bd7.chunk.css", - "static/js/3.9d3b560a.chunk.js": "./static/js/3.9d3b560a.chunk.js", - "static/js/4.4a54806d.chunk.js": "./static/js/4.4a54806d.chunk.js", - "static/js/5.2c3c3ed9.chunk.js": "./static/js/5.2c3c3ed9.chunk.js", - "static/js/6.01f07149.chunk.js": "./static/js/6.01f07149.chunk.js", + "static/js/3.cc9b9445.chunk.js": "./static/js/3.cc9b9445.chunk.js", + "static/js/4.8903312b.chunk.js": "./static/js/4.8903312b.chunk.js", + "static/js/5.0e309873.chunk.js": "./static/js/5.0e309873.chunk.js", + "static/js/6.73b67430.chunk.js": "./static/js/6.73b67430.chunk.js", + "static/js/7.f9293408.chunk.js": "./static/js/7.f9293408.chunk.js", "index.html": "./index.html", - "precache-manifest.457ae0c736914514271fc5c1b70b5e31.js": "./precache-manifest.457ae0c736914514271fc5c1b70b5e31.js", + "precache-manifest.8208b73a7a1eec7983c4ff3046696139.js": "./precache-manifest.8208b73a7a1eec7983c4ff3046696139.js", "service-worker.js": "./service-worker.js", - "static/js/3.9d3b560a.chunk.js.LICENSE.txt": "./static/js/3.9d3b560a.chunk.js.LICENSE.txt", - "static/js/5.2c3c3ed9.chunk.js.LICENSE.txt": "./static/js/5.2c3c3ed9.chunk.js.LICENSE.txt", + "static/js/3.cc9b9445.chunk.js.LICENSE.txt": "./static/js/3.cc9b9445.chunk.js.LICENSE.txt", + "static/js/5.0e309873.chunk.js.LICENSE.txt": "./static/js/5.0e309873.chunk.js.LICENSE.txt", "static/media/inter.css": "./static/media/Inter.var.8dd26c3d.woff2", "static/media/arbitrum.png": "./static/media/arbitrum.fa428345.png", - "static/media/arrow-down-blue.svg": "./static/media/arrow-down-blue.114fab91.svg", - "static/media/arrow-down-grey.svg": "./static/media/arrow-down-grey.4d4a6a99.svg", + "static/media/arrow-down-blue.svg": "./static/media/arrow-down-blue.cd061363.svg", + "static/media/arrow-down-grey.svg": "./static/media/arrow-down-grey.c0dedd2f.svg", "static/media/arrow-right-white.png": "./static/media/arrow-right-white.337ad716.png", - "static/media/arrow-right.svg": "./static/media/arrow-right.e96d8158.svg", - "static/media/aurora.svg": "./static/media/aurora.d13b261c.svg", + "static/media/arrow-right.svg": "./static/media/arrow-right.d285b6cf.svg", + "static/media/aurora.svg": "./static/media/aurora.e7a52317.svg", "static/media/avax.png": "./static/media/avax.2565884a.png", - "static/media/blue-loader.svg": "./static/media/blue-loader.e62a99c3.svg", + "static/media/blue-loader.svg": "./static/media/blue-loader.904b44c2.svg", "static/media/bnb.png": "./static/media/bnb.162aaf57.png", - "static/media/circle-grey.svg": "./static/media/circle-grey.5dd950ec.svg", - "static/media/circle.svg": "./static/media/circle.716403ba.svg", - "static/media/coinbaseWalletIcon.svg": "./static/media/coinbaseWalletIcon.aa4c7a76.svg", - "static/media/cro.svg": "./static/media/cro.73b9bf96.svg", - "static/media/de.svg": "./static/media/de.4b9a7c89.svg", - "static/media/dropdown-blue.svg": "./static/media/dropdown-blue.80a3ae25.svg", - "static/media/dropdown.svg": "./static/media/dropdown.50dbd07d.svg", - "static/media/dropup-blue.svg": "./static/media/dropup-blue.345dad74.svg", - "static/media/en.svg": "./static/media/en.42219103.svg", - "static/media/es.svg": "./static/media/es.6273c78a.svg", + "static/media/circle-grey.svg": "./static/media/circle-grey.ed2a1dad.svg", + "static/media/circle.svg": "./static/media/circle.2d975615.svg", + "static/media/coinbaseWalletIcon.svg": "./static/media/coinbaseWalletIcon.62578f59.svg", + "static/media/cro.svg": "./static/media/cro.f578d9cd.svg", + "static/media/de.svg": "./static/media/de.78feb91b.svg", + "static/media/dropdown-blue.svg": "./static/media/dropdown-blue.b20914ec.svg", + "static/media/dropdown.svg": "./static/media/dropdown.7d32d2fa.svg", + "static/media/dropup-blue.svg": "./static/media/dropup-blue.b96d70e1.svg", + "static/media/en.svg": "./static/media/en.8886b28b.svg", + "static/media/es.svg": "./static/media/es.426a1551.svg", "static/media/eth.png": "./static/media/eth.86b356aa.png", "static/media/ftm.svg": "./static/media/ftm.3af63018.svg", - "static/media/fuse.svg": "./static/media/fuse.306cb394.svg", + "static/media/fuse.svg": "./static/media/fuse.65ec5752.svg", "static/media/glmr.png": "./static/media/glmr.cb9b3252.png", "static/media/ht.svg": "./static/media/ht.0d242628.svg", - "static/media/it.svg": "./static/media/it.7e79b672.svg", - "static/media/iw.svg": "./static/media/iw.01c3fe8a.svg", + "static/media/it.svg": "./static/media/it.1d72a5de.svg", + "static/media/iw.svg": "./static/media/iw.51984728.svg", "static/media/link.svg": "./static/media/link.50c67f3c.svg", - "static/media/magnifying-glass.svg": "./static/media/magnifying-glass.52eac682.svg", + "static/media/magnifying-glass.svg": "./static/media/magnifying-glass.67440097.svg", "static/media/matic.png": "./static/media/matic.1ee4a1ab.png", - "static/media/menu.svg": "./static/media/menu.981ecca4.svg", + "static/media/menu.svg": "./static/media/menu.4f2c4440.svg", "static/media/metamask.png": "./static/media/metamask.023762b6.png", "static/media/movr.svg": "./static/media/movr.ccc42292.svg", "static/media/one.svg": "./static/media/one.e781dbdc.svg", - "static/media/optimisticEth.svg": "./static/media/optimisticEth.0d245621.svg", - "static/media/plus-blue.svg": "./static/media/plus-blue.899a4aa9.svg", - "static/media/plus-grey.svg": "./static/media/plus-grey.62281ca8.svg", + "static/media/optimisticEth.svg": "./static/media/optimisticEth.7b05fcf4.svg", + "static/media/plus-blue.svg": "./static/media/plus-blue.e8021e51.svg", + "static/media/plus-grey.svg": "./static/media/plus-grey.d8e0be7d.svg", "static/media/portisIcon.png": "./static/media/portisIcon.b234b2bf.png", - "static/media/question-mark.svg": "./static/media/question-mark.1761ff9c.svg", - "static/media/question.svg": "./static/media/question.63be1e24.svg", + "static/media/question-mark.svg": "./static/media/question-mark.1ae4d9f4.svg", + "static/media/question.svg": "./static/media/question.a46e8bc1.svg", "static/media/rbtc.png": "./static/media/rbtc.3f61edb2.png", - "static/media/ru.svg": "./static/media/ru.5d71cdb2.svg", - "static/media/spinner.svg": "./static/media/spinner.a9842492.svg", - "static/media/tomo.svg": "./static/media/tomo.7cbcd424.svg", + "static/media/ru.svg": "./static/media/ru.ab61f31e.svg", + "static/media/spinner.svg": "./static/media/spinner.be00fc4a.svg", + "static/media/tomo.svg": "./static/media/tomo.db76ba27.svg", "static/media/trustWallet.png": "./static/media/trustWallet.edcc1ab5.png", - "static/media/walletConnectIcon.svg": "./static/media/walletConnectIcon.5e81cac2.svg", + "static/media/walletConnectIcon.svg": "./static/media/walletConnectIcon.8215855c.svg", "static/media/x.svg": "./static/media/x.5b8e2186.svg", "static/media/xdai.png": "./static/media/xdai.573f0f5f.png", - "static/media/zh.svg": "./static/media/zh.1a6fff51.svg" + "static/media/zh.svg": "./static/media/zh.5c573ebe.svg" }, "entrypoints": [ - "static/js/runtime-main.f0688bb1.js", + "static/js/runtime-main.e923fa6f.js", "static/css/3.a1ab5bd7.chunk.css", - "static/js/3.9d3b560a.chunk.js", - "static/css/main.904b2218.chunk.css", - "static/js/main.8d7ad959.chunk.js" + "static/js/3.cc9b9445.chunk.js", + "static/css/main.c9ee16f2.chunk.css", + "static/js/main.aeb7ae13.chunk.js" ] } \ No newline at end of file diff --git a/index.html b/index.html index f072e9b..9c2d1d4 100644 --- a/index.html +++ b/index.html @@ -1 +1 @@ -Exchange
\ No newline at end of file +Exchange
\ No newline at end of file diff --git a/locales/de.json b/locales/de.json index 89833e6..783a814 100644 --- a/locales/de.json +++ b/locales/de.json @@ -265,7 +265,7 @@ "storageContract": "Lagervertrag", "chooseNetwork": "Netzwerk auswählen", "chooseWallet": "Wallet auswählen", - "appIsNotReadyYet": "App ist nicht fertig", + "appIsNotReadyYet": "Swap-Verträge sind noch nicht fertig. Der Administrator muss neue Verträge bereitstellen, um dieses Netzwerk nutzen zu können", "selectTokenToFindYourLiquidity": "Wählen Sie einen Token aus, um Ihre Liquidität zu finden", "importPool": "Pool importieren", "findManually": "Manuell suchen", @@ -294,6 +294,9 @@ "migration": "Migration", "oldDomain": "Alte Domain", "newDomain": "Neue Domain", + "waitUntilYourAddressWillBeSaved": "Warten Sie, bis Ihre Adresse gespeichert wird", + "setNewDomainAdmin": "Legen Sie einen neuen Domänenadministrator fest", + "saveThisAddressAsDomainOwner": "Speichern Sie diese Adresse als Domaininhaber", "afterMigrationYourDataWillBeDeleted": "Nach der Migration werden die Daten für diese Domain gelöscht. Sie können nur von einer neuen Domain darauf zugreifen", "migrateToNewDomain": "Zu einer neuen Domain migrieren", "instructionToSaveContractsFromDifferentNetwork": "Wenn Sie Verträge aus einem anderen Netzwerk als dem Speichernetzwerk bereitstellen, müssen Sie sie manuell speichern. Wechseln Sie zum Speichernetzwerk, füllen Sie diese Eingaben aus und speichern Sie sie. Sie können auch bestehende Verträge verwenden, jedoch nur, wenn sie sich auf Folgendes beziehen Definance", @@ -302,5 +305,10 @@ "youAlreadyHaveSwapContractsWarning": "Sie haben bereits Swap-Verträge bereitgestellt. Wenn Sie es erneut tun, werden die alten Vertragsadressen überschrieben. Neue Verträge werden ohne Liquiditäts- und Gebühreneinstellungen sein", "youAlreadyHaveStorageContractWarning": "Sie haben den Speichervertrag bereits bereitgestellt. Wenn Sie es erneut tun, wird die alte Speicheradresse überschrieben. Sie verlieren die Schnittstelleneinstellungen", "noPointToChangeAdminFeeWithoutFeeRecipient": "Es hat keinen Sinn, diese Provision zu ändern, bis Sie die Adresse des Gebührenempfängers festgelegt haben", - "forSuccessfulExchangeRecommendedToIncreaseSlippageTo": "Für einen erfolgreichen Austausch empfiehlt es sich, die Slippage Tolerance auf zu erhöhen" + "forSuccessfulExchangeRecommendedToIncreaseSlippageTo": "Für einen erfolgreichen Austausch empfiehlt es sich, die Slippage Tolerance auf zu erhöhen", + "HelloLetsConnectThisDomain": "Hallo! Verbinden wir diese Domain mit Ihrer Wallet-Adresse", + "IfYouWantToChangeTheAddressSwitchToAnotherAddress": "Wenn Sie die Adresse ändern möchten, wechseln Sie zu einer anderen Adresse. Wenn Sie nicht wechseln können, trennen Sie einfach Ihre Brieftasche und verbinden Sie sie mit der neuen Adresse.", + "setTheOwner": "Legen Sie den Eigentümer fest", + "setAddressAsTheOwnerOfDomain": "Legen Sie Ihre Adresse als Eigentümer dieser Domain fest", + "onlyThisAddressCanAccessAppSettings": "Nur diese Adresse kann auf App-Einstellungen zugreifen und diese ändern" } diff --git a/locales/en.json b/locales/en.json index 7e2ab78..1b94a2e 100644 --- a/locales/en.json +++ b/locales/en.json @@ -264,7 +264,7 @@ "storageContract": "Storage contract", "chooseNetwork": "Choose network", "chooseWallet": "Choose wallet", - "appIsNotReadyYet": "The app is not ready yet", + "appIsNotReadyYet": "Swap contracts are not ready yet. The admin must deploy new contracts to start using this network", "importPool": "Import pool", "selectTokenToFindYourLiquidity": "Select a token to find your liquidity", "findManually": "Find manually", @@ -293,6 +293,9 @@ "migration": "Migration", "oldDomain": "Old domain", "newDomain": "New domain", + "waitUntilYourAddressWillBeSaved": "Wait until your address will be saved", + "setNewDomainAdmin": "Set a new domain admin", + "saveThisAddressAsDomainOwner": "Save this address as a domain owner", "afterMigrationYourDataWillBeDeleted": "After migration data for this domain will be deleted. You can access it only from a new domain", "migrateToNewDomain": "Migrate to a new domain", "instructionToSaveContractsFromDifferentNetwork": "If you deploy contracts from a network other than the Storage network, you need to save them manually. Switch to the Storage network, fill these inputs and save it. You can also use existing contracts, but only if they are related to Definance", @@ -301,5 +304,10 @@ "youAlreadyHaveSwapContractsWarning": "You have already deployed swap contracts. If you do it again, the old contract addresses will be overwritten. New contracts will be without liquidity and fee settings", "youAlreadyHaveStorageContractWarning": "You have already deployed storage contract. If you do it again, the old storage address will be overwritten. You will lose the interface settings", "noPointToChangeAdminFeeWithoutFeeRecipient": "There is no point to change this commission until you set the fee recipient address", - "forSuccessfulExchangeRecommendedToIncreaseSlippageTo": "For a successful exchange it is recommended to increase Slippage Tolerance to" + "forSuccessfulExchangeRecommendedToIncreaseSlippageTo": "For a successful exchange it is recommended to increase Slippage Tolerance to", + "HelloLetsConnectThisDomain": "Hello! Let's connect this domain to your wallet address", + "IfYouWantToChangeTheAddressSwitchToAnotherAddress": "If you want to change the address, switch to another address. If you can't switch, just disconnect your wallet and connect it to the new address.", + "setTheOwner": "Set the owner", + "setAddressAsTheOwnerOfDomain": "Set your address as the owner of this domain", + "onlyThisAddressCanAccessAppSettings": "Only this address can access and change app settings" } diff --git a/locales/es.json b/locales/es.json index ef6c2cb..33505e6 100644 --- a/locales/es.json +++ b/locales/es.json @@ -253,7 +253,7 @@ "storageContract": "Contrato de almacenamiento", "chooseNetwork": "Elija la red", "chooseWallet": "Elegir cartera", - "appIsNotReadyYet": "La aplicación no está lista", + "appIsNotReadyYet": "Los contratos de swap aún no están listos. El administrador debe implementar nuevos contratos para comenzar a usar esta red", "selectTokenToFindYourLiquidity": "Seleccione un token para encontrar su liquidez", "importPool": "Importar grupo", "findManually": "Buscar manualmente", @@ -282,6 +282,9 @@ "migration": "Migración", "oldDomain": "Dominio antiguo", "newDomain": "Nuevo dominio", + "waitUntilYourAddressWillBeSaved": "Espere hasta que se guarde su dirección", + "setNewDomainAdmin": "Establecer un nuevo administrador de dominio", + "saveThisAddressAsDomainOwner": "Guardar esta dirección como propietario de un dominio", "afterMigrationYourDataWillBeDeleted": "Después de la migración, se eliminarán los datos de este dominio. Solo se puede acceder desde un nuevo dominio", "migrateToNewDomain": "Migrar a un nuevo dominio", "instructionToSaveContractsFromDifferentNetwork": "Si implementa contratos desde una red que no sea la red de almacenamiento, debe guardarlos manualmente. Cambie a la red de almacenamiento, complete estas entradas y guárdelas. También puede usar contratos existentes, pero solo si están relacionados con Definance", @@ -290,5 +293,10 @@ "youAlreadyHaveSwapContractsWarning": "Ya ha implementado contratos de intercambio. Si lo hace de nuevo, las direcciones de contrato antiguas se sobrescribirán. Los nuevos contratos no tendrán liquidez ni ajustes de comisiones", "youAlreadyHaveStorageContractWarning": "Ya ha implementado un contrato de almacenamiento. Si lo hace de nuevo, la dirección de almacenamiento antigua se sobrescribirá. Perderá la configuración de la interfaz", "noPointToChangeAdminFeeWithoutFeeRecipient": "No tiene sentido cambiar esta comisión hasta que establezca la dirección del destinatario de la tarifa", - "forSuccessfulExchangeRecommendedToIncreaseSlippageTo": "Para un intercambio exitoso, se recomienda aumentar la tolerancia al deslizamiento a" + "forSuccessfulExchangeRecommendedToIncreaseSlippageTo": "Para un intercambio exitoso, se recomienda aumentar la tolerancia al deslizamiento a", + "HelloLetsConnectThisDomain": "¡Hola! Conectemos este dominio a la dirección de su billetera", + "IfYouWantToChangeTheAddressSwitchToAnotherAddress": "Si desea cambiar la dirección, cambie a otra dirección. Si no puede cambiar, simplemente desconecte su billetera y conéctela a la nueva dirección.", + "setTheOwner": "Establecer el propietario", + "setAddressAsTheOwnerOfDomain": "Establece tu dirección como el propietario de este dominio", + "onlyThisAddressCanAccessAppSettings": "Solo esta dirección puede acceder y cambiar la configuración de la aplicación" } diff --git a/locales/it.json b/locales/it.json index 1bf8cff..c1f51ba 100644 --- a/locales/it.json +++ b/locales/it.json @@ -264,7 +264,7 @@ "storageContract": "Contratto di ammasso", "chooseNetwork": "Scegli rete", "chooseWallet": "Scegli portafoglio", - "appIsNotReadyYet": "App non è pronto", + "appIsNotReadyYet": "I contratti di swap non sono ancora pronti. L'amministratore deve distribuire nuovi contratti per iniziare a utilizzare questa rete", "selectTokenToFindYourLiquidity": "Seleziona un token per trovare la tua liquidità", "importPool": "Importa pool", "findManually": "Trova manualmente", @@ -293,6 +293,9 @@ "migration": "Migrazione", "oldDomain": "Vecchio dominio", "newDomain": "Nuovo dominio", + "waitUntilYourAddressWillBeSaved": "Attendi fino a quando il tuo indirizzo verrà salvato", + "setNewDomainAdmin": "Imposta un nuovo amministratore di dominio", + "saveThisAddressAsDomainOwner": "Salva questo indirizzo come proprietario del dominio", "afterMigrationYourDataWillBeDeleted": "Dopo la migrazione i dati per questo dominio verranno eliminati. È possibile accedervi solo da un nuovo dominio", "migrateToNewDomain": "Migrazione a un nuovo dominio", "instructionToSaveContractsFromDifferentNetwork": "Se si distribuiscono contratti da una rete diversa dalla rete di archiviazione, è necessario salvarli manualmente. Passare alla rete di archiviazione, riempire questi ingressi e salvarlo. È inoltre possibile utilizzare i contratti esistenti, ma solo se sono correlati a Definance", @@ -301,5 +304,10 @@ "youAlreadyHaveSwapContractsWarning": "Hai già distribuito contratti di swap. Se lo fai di nuovo, i vecchi indirizzi del contratto verranno sovrascritti. I nuovi contratti saranno senza impostazioni di liquidità e commissioni", "youAlreadyHaveStorageContractWarning": "Hai già distribuito il contratto di archiviazione. Se lo fai di nuovo, il vecchio indirizzo di archiviazione verrà sovrascritto. Si perderanno le impostazioni dell'interfaccia", "noPointToChangeAdminFeeWithoutFeeRecipient": "Non ha senso modificare questa commissione finché non si imposta l'indirizzo del destinatario della commissione", - "forSuccessfulExchangeRecommendedToIncreaseSlippageTo": "Per uno scambio di successo si consiglia di aumentare la tolleranza di slittamento a" + "forSuccessfulExchangeRecommendedToIncreaseSlippageTo": "Per uno scambio di successo si consiglia di aumentare la tolleranza di slittamento a", + "HelloLetsConnectThisDomain": "Buongiorno! Colleghiamo questo dominio al tuo indirizzo wallet", + "IfYouWantToChangeTheAddressSwitchToAnotherAddress": "Se si desidera modificare l'indirizzo, passare a un altro indirizzo. Se non puoi cambiare, scollega il tuo portafoglio e collegalo al nuovo indirizzo.", + "setTheOwner": "Imposta il proprietario", + "setAddressAsTheOwnerOfDomain": "Imposta il tuo indirizzo come proprietario di questo dominio", + "onlyThisAddressCanAccessAppSettings": "Solo questo indirizzo può accedere e modificare le impostazioni dell'app" } diff --git a/locales/iw.json b/locales/iw.json index dc808ef..8f3f274 100644 --- a/locales/iw.json +++ b/locales/iw.json @@ -253,7 +253,7 @@ "storageContract": "חוזה אחסון", "chooseNetwork": "בחר רשת", "chooseWallet": "בחר ארנק", - "appIsNotReadyYet": "האפליקציה אינה מוכנה", + "appIsNotReadyYet": "חוזי החלפה עדיין לא מוכנים. מנהל המערכת חייב לפרוס חוזים חדשים כדי להתחיל להשתמש ברשת זו", "selectTokenToFindYourLiquidity": "בחר אסימון כדי למצוא את הנזילות שלך", "importPool": "ייבוא מאגר", "findManually": "מצא באופן ידני", @@ -282,6 +282,9 @@ "migration": "הגירה", "oldDomain": "דומיין ישן", "newDomain": "דומיין חדש", + "waitUntilYourAddressWillBeSaved": "המתן עד שהכתובת שלך תישמר", + "setNewDomainAdmin": "הגדר מנהל תחום חדש", + "saveThisAddressAsDomainOwner": "שמור כתובת זו כבעלים של דומיין", "afterMigrationYourDataWillBeDeleted": "לאחר העברת נתונים עבור תחום זה יימחקו. אתה יכול לגשת אליו רק מדומיין חדש", "migrateToNewDomain": "העבר לדומיין חדש", "instructionToSaveContractsFromDifferentNetwork": "אם אתה פורס חוזים מרשת שאינה רשת האחסון, עליך לשמור אותם באופן ידני. עבור לרשת האחסון, מלא תשומות אלה ושמור אותה. ניתן גם להשתמש בחוזים קיימים, אך רק אם הם קשורים להגדרה", @@ -290,5 +293,10 @@ "youAlreadyHaveSwapContractsWarning": "כבר פרסתם חוזי החלפה. אם תעשה זאת שוב, כתובות החוזה הישנות יוחלפו. חוזים חדשים יהיו ללא נזילות והגדרות תשלום", "youAlreadyHaveStorageContractWarning": "כבר פרסתם חוזה אחסון. אם תעשה זאת שוב, כתובת האחסון הישנה תוחלף. אתה תאבד את הגדרות הממשק", "noPointToChangeAdminFeeWithoutFeeRecipient": "זה לא הגיוני לשנות עמלה זו עד שתגדיר את הכתובת של הנמען של הוועדה", - "forSuccessfulExchangeRecommendedToIncreaseSlippageTo": "להחלפה מוצלחת מומלץ להגביר את סובלנות החלקה ל" + "forSuccessfulExchangeRecommendedToIncreaseSlippageTo": "להחלפה מוצלחת מומלץ להגביר את סובלנות החלקה ל", + "HelloLetsConnectThisDomain": "שלום! בואו נחבר דומיין זה לכתובת הארנק שלכם", + "IfYouWantToChangeTheAddressSwitchToAnotherAddress": "אם ברצונך לשנות את הכתובת, עבור לכתובת אחרת. אם אינך יכול להחליף, פשוט נתק את הארנק וחבר אותו לכתובת החדשה.", + "setTheOwner": "הגדר את הבעלים", + "setAddressAsTheOwnerOfDomain": "הגדר את הכתובת שלך כבעלים של דומיין זה", + "onlyThisAddressCanAccessAppSettings": "רק כתובת זו יכולה לגשת ולשנות את הגדרות האפליקציה" } diff --git a/locales/ru.json b/locales/ru.json index b2e9717..52198dc 100644 --- a/locales/ru.json +++ b/locales/ru.json @@ -251,7 +251,7 @@ "storageContract": "Контракт хранилища", "chooseNetwork": "Выберите сеть", "chooseWallet": "Выберите кошелек", - "appIsNotReadyYet": "Приложение еще не готово", + "appIsNotReadyYet": "Контракты для обмена еще не готовы. Администратор должен развернуть новые контракты, чтобы начать использовать эту сеть", "selectTokenToFindYourLiquidity": "Выберите токен, чтобы найти свою ликвидность", "importPool": "Импортировать пул", "findManually": "Поиск вручную", @@ -280,6 +280,9 @@ "migration": "Миграция", "oldDomain": "Старый домен", "newDomain": "Новый домен", + "waitUntilYourAddressWillBeSaved": "Подождите, пока ваш адрес не будет сохранен", + "setNewDomainAdmin": "Установить нового администратора домена", + "saveThisAddressAsDomainOwner": "Сохранить этот адрес в качестве владельца", "afterMigrationYourDataWillBeDeleted": "После миграции данные для этого домена будут удалены. Вы можете получить к ним доступ только с нового домена", "migrateToNewDomain": "Переход на новый домен", "instructionToSaveContractsFromDifferentNetwork": "Если вы развертываете контракты из сети, отличной от сети хранения, вам необходимо сохранить их вручную. Переключитесь на сеть хранения данных, заполните эти входные данные и сохраните их. Вы также можете использовать существующие контракты, но только в том случае, если они связаны с Definance", @@ -288,5 +291,10 @@ "youAlreadyHaveSwapContractsWarning": "Вы уже развернули контракты для обмена. Если вы сделаете это снова, старые адреса контрактов будут перезаписаны. Новые контракты будут без ликвидности и установленной комиссии", "youAlreadyHaveStorageContractWarning": "Вы уже развернули контракт хранилища. Если вы сделаете это снова, старый адрес хранилища будет перезаписан. Вы потеряете настройки интерфейса", "noPointToChangeAdminFeeWithoutFeeRecipient": "Нет смысла менять эту комиссию до тех пор, пока вы не установите адрес получателя комиссии", - "forSuccessfulExchangeRecommendedToIncreaseSlippageTo": "Для успешного обмена рекомендуется увеличить процент проскальзывания до" + "forSuccessfulExchangeRecommendedToIncreaseSlippageTo": "Для успешного обмена рекомендуется увеличить процент проскальзывания до", + "HelloLetsConnectThisDomain": "Привет! Давайте подключим этот домен к адресу вашего кошелька", + "IfYouWantToChangeTheAddressSwitchToAnotherAddress": "Если вы хотите изменить адрес, переключитесь на другой адрес. Если вы не можете переключиться, просто отключите свой кошелек и подключите его к новому адресу.", + "setTheOwner": "Установить владельца", + "setAddressAsTheOwnerOfDomain": "Указать ваш адрес в качестве владельца этого домена", + "onlyThisAddressCanAccessAppSettings": "Только этот адрес может получить доступ к настройкам приложения и изменить их" } diff --git a/locales/tr.json b/locales/tr.json index b4437e3..4fb2762 100644 --- a/locales/tr.json +++ b/locales/tr.json @@ -1,305 +1,313 @@ -{ - "token": "token", - "business": "işletme", - "taxi": "Taksi", - "coffee": "Coffee", - "delivery": "Teslimat", - "earn": "Kazan", - "businessCard": "Kartvizit", - "company": "şirket", - "rider": "Rider", - "driver": "Driver", - "createPair": "Çift oluştur", - "connectWallet": "Cüzdanı Bağla", - "noWallet": "Ethereum cüzdanı bulunamadı", - "wrongNetwork": "Yanlış ağdasın", - "switchNetwork": "Please switch to {{ correctNetwork }}", - "installWeb3MobileBrowser": "Lütfen bizi Trust Wallet veya Coinbase Wallet gibi web3 özellikli bir mobil tarayıcıdan ziyaret edin.", - "installMetamask": "Lütfen Metamask'ı Chrome veya Brave'e yükledikten sonra bizi ziyaret edin.", - "disconnected": "Bağlantı kesildi", - "swap": "Takas", - "send": "gönder", - "sendAnyway": "Ne olursa olsun gönder", - "pool": "havuz", - "betaWarning": "Bu proje beta aşamasındadır. Kendi sorumluluğunuzda kullanın.", - "input": "giriş", - "output": "Çıktı", - "estimated": "Tahmini", - "balance": "Bakiye: {{ balanceInput }}", - "unlock": "Kilidini aç", - "pending": "Bekliyor", - "selectToken": "Token seçin", - "searchOrPaste": "Token ara, sembol, yada Adres", - "searchOrPasteMobile": "İsim, sembol, yada Adres", - "noExchange": "No Exchange Found", - "noToken": "Token Bulunamadı", - "exchangeRate": "kur farkı", - "unknownError": "Bilinmeyen bir hata oluştu. Lütfen sayfayı yenileyin veya başka bir tarayıcı veya cihazdan ziyaret edin.", - "enterValueCont": "Enter a {{ missingCurrencyValue }} value to continue.", - "selectTokenCont": "Devam etmek için bir token seçin.", - "noLiquidity": "likidite yok.", - "insufficientLiquidity": "Yetersiz likidite.", - "unlockTokenCont": "Devam etmek için lütfen token nun kilidini açın.", - "transactionDetails": "Gelişmiş Ayrıntılar", - "hideDetails": "Ayrıntıları Gizle", - "slippageWarning": "Kayma uyarısı", - "highSlippageWarning": "Yüksek Kayma Uyarısı", - "youAreSelling": "Satıyorsun", - "orTransFail": "veya işlem başarısız olur.", - "youWillReceive": "En azından alacaksın", - "youAreBuying": "satın alıyorsun", - "itWillCost": "En fazlaya mal olacak", - "forAtMost": "en fazla", - "insufficientBalance": "Yetersiz bakiye", - "inputNotValid": "Geçerli bir giriş değeri değil", - "differentToken": "Farklı token olmalı.", - "noRecipient": "Göndermek için bir cüzdan adresi girin.", - "invalidRecipient": "Lütfen geçerli bir cüzdan adresi alıcısı girin.", - "recipientAddress": "Alıcı adresi", - "youAreSending": "gönderiyorsun", - "willReceive": "en azından alacaksın", - "to": "to", - "addLiquidity": "Likidite Ekle", - "deposit": "Depozito", - "currentPoolSize": "Mevcut Havuz Boyutu", - "yourPoolShare": "Havuz Paylaşımınız", - "noZero": "Tutar sıfır olamaz.", - "mustBeETH": "Girişlerden biri ETH olmalıdır.", - "enterCurrencyOrLabelCont": "Enter a {{ inputCurrency }} or {{ label }} value to continue.", - "youAreAdding": "ekliyorsun", - "and": "ve", - "intoPool": "likidite havuzuna girdi..", - "outPool": "likidite havuzundan.", - "youWillMint": "Mint yapacaksın", - "liquidityTokens": "likidite tokenları.", - "totalSupplyIs": "Mevcut toplam likidite tokenların arzı", - "youAreSettingExRate": "Başlangıç kurunu şu şekilde ayarlıyorsunuz:", - "totalSupplyIs0": "Mevcut toplam likidite belirteçleri arzı 0.", - "tokenWorth": "Mevcut döviz kurunda, her bir havuz tokenın değeri", - "firstLiquidity": "Likidite ekleyen ilk kişi sizsiniz!", - "initialExchangeRate": "The initial exchange rate will be set based on your deposits. Please make sure that your ETH and {{ label }} deposits have the same fiat value.", - "ratioOfPoolTokens": "Eklediğiniz tokenların oranı bu havuzun fiyatını belirleyecektir.", - "happyWithRate": "Orandan memnun kaldığınızda, incelemek için arza tıklayın.", - "whenYouAddLiquidityTip": "Likidite eklediğinizde, pozisyonunuzu temsil eden havuz tokenları alacaksınız. Bu tokenlar, havuzdaki payınızla orantılı olarak otomatik olarak ücret alır ve herhangi bir zamanda kullanılabilir.", - "approving": "", - "approve": "Onayla", - "approved": "Onaylandı", - "slippageTolerance": "Kayma Toleransı", - "price": "Fiyat", - "removeSend": "Göndermeyi kaldır", - "addSend": "Gönderme ekle (isteğe bağlı)", - "receive": "Teslım Al", - "removingPoolTokensTip": "Havuz tokenlarını kaldırmak, konumunuzu havuzdaki payınızla orantılı olarak mevcut oranda temel tokenlara dönüştürür. Tahakkuk eden ücretler, aldığınız tutarlara dahildir.", - "amount": "Miktar", - "removeLiquidity": "Likiditeyi Kaldır", - "poolTokens": "Havuz Tokenları", - "enterLabelCont": "Enter a {{ label }} value to continue.", - "youAreRemoving": "Arasındakılerı kaldırıyorsun", - "youWillRemove": "Silmek üzeresin", - "createExchange": "Kambiyo Oluştur", - "invalidTokenAddress": "Geçerli bir token adresi değil", - "exchangeExists": "{{ label }} Exchange zaten var!!", - "invalidSymbol": "Geçersiz sembol", - "invalidDecimals": "Geçersiz ondalık sayılar", - "tokenAddress": "Token adresi", - "label": "Etiket", - "name": "İsim", - "symbol": "sembol", - "decimals": "Ondalık sayılar", - "enterTokenCont": "Devam etmek için bir token adresi girin", - "priceChange": "Beklenen fiyat kayması", - "forAtLeast": "en azından ", - "toleranceExplanation": "Bu sınırı düşürmek, önden koşma riskinizi azaltır. Ancak bu, normal fiyat hareketleri nedeniyle işleminizin başarısız olma olasılığını artırır..", - "tokenSearchPlaceholder": "isim arayın veya adresi yapıştırın", - "areYouSure": "Emin misin?", - "expertModeDescription": "Uzman modu, işlem onaylama istemini kapatır ve genellikle düşük oranlara ve para kaybına neden olan yüksek kaymalı işlemlere izin verir.", - "expertModeWarning": "BU MODU SADECE NE YAPTIĞINIZI BİLİYORSANIZ KULLANIN.", - "turnOnExpertMode": "Turn On Expert Mode", - "transactionSettings": "Uzman Modunu Aç", - "interfaceSettings": "Arayüz Ayarları", - "toggleExpertMode": "Uzman Modunu Aç/Kapat", - "disableMultihops": "Çoklu Atlamayı Devre Dışı Bırak", - "transactionDeadline": "İşlem son tarihi", - "minutes": "dakikalar", - "newToEthereum": "Ethereum'da yeni misiniz?", - "learnWallets": "Cüzdanlar hakkında daha fazla bilgi edinin", - "yourLiquidity": "Likiditeniz", - "loading": "Yükleniyor", - "connectToWalletForLiquidity": "Likiditenizi görüntülemek için bir cüzdana bağlanın", - "noLiquidityFound": "Likidite bulunamadı", - "noTokenResultsFound": "Aktif listelerde sonuç bulunamadı", - "manage": "idare et", - "commonBases": "Ortak bazlar", - "enterValidTokenAddress": "Geçerli token adresini girin", - "clearAll": "Hepsini temizle", - "tipAboutCustomTokens": "İpucu: Özel tokenlar tarayıcınızda yerel olarak depolanır", - "account": "Hesap", - "disconnect": "Bağlantıyı kes", - "change": "Değiştir", - "copyAddress": "Adresi kopyala", - "viewIn": "Görüntüle", - "recentTransactions": "Son İşlemler", - "yourTransactionsAppearHere": "İşlemleriniz burada görünecek", - "connectedWith": "Connected with", - "pooled": "havuzlanmış", - "add": "Ekle", - "remove": "Kaldır", - "manageLiquidityInPool": "Ödül havuzundaki likiditeyi yönetin", - "poolTokensInRewardsPool": "havuzdaki tokenlar ödüllü havuzda", - "yourTotalPoolTokens": "Toplam havuz tokenlarınız", - "yourPosition": "Pozisyonun", - "lightTheme": "Açık renk tema", - "darkTheme": "Koyu renk tema", - "language": "Dil", - "settings": "Ayarlar", - "lists": "Listeler", - "tokens": "Tokenlar", - "invalidPair": "Geçersiz çift", - "noPoolFound": "Havuz bulunamadı", - "createPool": "Havuz oluştur", - "youDoNotHaveLiquidity": "Bu havuzda henüz likiditeniz yok", - "managePool": "Bu havuzu yönet", - "poolFound": "Havuz bulundu", - "useThisToolToFindPairs": "Arayüzde otomatik olarak görünmeyen çiftleri bulmak için bu aracı kullanın", - "requiredField": "Gerekli alan", - "deployment": "Dağıtım", - "swapContracts": "Takas sözleşmeleri", - "interfaceOptions": "Arayüz seçenekleri", - "deploySwapContracts": "Takas sözleşmeleri dağıtın", - "wrappedTokenDescription": "Sarılmış token - yerel bir EVM ağ para birimini temsil eden ERC20 tokenı(ETH, BNB, MATIC, gibi.). Yerel para biriminin diğer ERC20 jetonlarıyla değiştirilebilmesi için paketlenmesi gerekir. Yerel para birimini sarmak değerini etkilemez. Örneğin 1 ETH = 1 WETH", - "wrappedToken": "Sarılmıştoken", - "admin": "Yönetici", - "domain": "Domain", - "deployStorageContract": "Depolama sözleşmesi dağıtın", - "deployStorage": "Depolamayı dağıtın", - "deploymentInformation": "Dağıtım bilgileri", - "deploymentInformationDescription": "Dağıtılan sözleşmelerle ilgili en son bilgileri aşağıda görebilirsiniz. Kaydetmeyi unutmayın", - "factory": "Fabrika", - "router": "Router", - "storage": "Depo", - "save": "Kayıt et", - "factoryAddress": "Fabrika adresi", - "newAdmin": "Yeni yönetici", - "feeRecipient": "Ücret alıcısı", - "allFeesToAdmin": "Tüm ücretler yöneticiye (likidite sağlayıcıları için ücret yok)", - "feeIsChargedWhen": "Bu adresin ayarlanması ve sıfır adres olmaması durumunda komisyon tahsil edilir.", - "youCanUseTheSameAddressForBoothInputs": "Her iki giriş için de aynı adresi kullanabilirsiniz.", - "listName": "Liste adı", - "logo": "Logo", - "noTokens": "Tokenlar yok", - "saveTokenList": "Token listesini kaydet", - "updateTokenList": "Token listesini güncelle", - "noTokenLists": "Token listesi yok", - "fetchOptions": "Getirme seçenekleri", - "saveAllSettings": "Tüm ayarları kaydet", - "tokenLists": "Token listeleri", - "createNewTokenList": "Yeni bir token listesi oluşturun", - "youCanNotUseThisNetwork": "Üzgünüz, bu ağı kullanamazsınız", - "pleaseSelectTheFollowingNetwork": "Lütfen aşağıdaki ağı seçin", - "availableNetworks": "Kullanılabilir ağlar", - "toGetStartedConnectWallet": "Başlamak için cüzdanınızı bağlayın", - "pleaseChangeWrongNetwork": "Lütfen ağınızı değiştirin veya uygun ağa bağlanın", - "noInfo": "No information", - "saveSettings": "Ayarları kaydet", - "deployAfterSwapContracts": "Takas sözleşmelerinden sonra dağıtın", - "resetDomainData": "Reset domain data", - "projectName": "Proje Adı", - "logoUrl": "Logo url", - "socialLinks": "Social links", - "resetDomainDescription": "Bu alan adına ait tüm veriler silinecek(admin, contract addresses and settings)", - "youAreDeployingSwapContracts": "Takas sözleşmeleri dağıtacaksınız", - "youAreDeployingStorage": "Depolama sözleşmesi dağıtmak üzeresiniz", - "confirmDeployment": "Dağıtımı onaylayın", - "confirmTransactionInWallet": "Bu işlemi cüzdanınızda onaylayın", - "waitingForConfirmation": "Onay bekleniyor", - "transactionSubmitted": "İşlem gönderildi", - "accept": "Kabul et", - "outputEstimatedYouReceiveAtLeast": "Çıktı tahmini. En azından alacaksın", - "orTransactionWillRevert": "veya işlem geri dönecek", - "inputEstimatedYouSellAtMost": "Giriş tahminidir. En fazla satarsın", - "outputWillSentTo": "çıktı gönderilecek", - "minimumReceived": "Minimum alınan", - "maximumSold": "Maksimum satılan", - "priceImpact": "Fiyat etkisi", - "liquidityProviderFee": "Likidite sağlayıcı ücreti", - "minimumReceivedDescription": "Onaylanmadan önce büyük, olumsuz bir fiyat hareketi olursa işleminiz geri dönecektir (iptal edilecek).", - "priceImpactDescription": "Ticaret büyüklüğü nedeniyle piyasa fiyatı ile tahmini fiyat arasındaki fark", - "liquidityProviderFeeDescription": "Her ticaretin bir kısmı protokol teşviki olarak likidite sağlayıcılarına gider", - "route": "Route", - "routeDescription": "Bu tokenlar aracılığıyla yönlendirme, işleminiz için en iyi fiyatla sonuçlandı", - "primaryColor": "Primary color", - "menuLinks": "Menu links", - "navigationLinks": "Navigation links", - "swapAnyway": "Yine de değiş tokuş yap", - "confirmSwap": "Takas işlemini onaylayın", - "transactionTimeoutDescription": "İşleminiz bu süreden daha uzun süre beklemedeyse işleminiz geri alınacaktır.", - "enterValidSlippage": "Geçerli bir kayma yüzdesi girin", - "yourTransactionMayFail": "İşleminiz başarısız olabilir", - "yourTransactionMayBeFrontrun": "İşleminiz ön çalışmalı olabilir", - "noConnectionMethodsAvailable": "Kullanılabilir bağlantı yöntemi yok", - "deploymentSectionDescription": "seçenekler sözleşme dağıtımıyla ilgilidir", - "interface": "Arayüz", - "instructions": "Talimatlar", - "addressesOfTokenLists": "Token listelerinin adresleri", - "beCareful": "Dikkat olun", - "adminFee": "yönetici ücreti", - "feeSettings": "Ücret ayarları", - "feesDescription": "Toplam ücret, her takasta alınır ve likidite havuzu tokanındaki ek bir miktarlar likidite havuzunda birikir. Likiditenin kaldırılmasından sonra birikmiş ücretleri alabilirsiniz", - "caseWhenNoFeesCharged": "Toplam ücret %0 ise, yönetici dahil hiçbir ücret alınmaz.", - "adminFeeIsPercentOfTotalFee": "Yönetici ücreti, toplam ücretin bir yüzdesidir", - "totalFee": "Toplam ücret", - "liquidityProviders": "Likidite sağlayıcıları", - "adminAndProvidersFeesDoNotWork": "Yönetici ve sağlayıcı ücretleri çalışmıyor", - "tradeAtYourOwnRisk": "Kendi sorumluluğunuzda alım satım yapın!", - "fakeTokenCreationWarning": "Projeleri temsil ettiğini iddia eden mevcut belirteçlerin sahte sürümlerini oluşturmak da dahil olmak üzere herkes bir belirteç oluşturabilir", - "fakeTokenPurchaseWarning": "Bu tokenu satın alırsanız, onu geri satamayabilirsiniz.", - "iUnderstand": "Anladım", - "address": "Adres", - "your": "sizin", - "deploy": "Dağıt", - "youHaveToConfirmTheseTxs": "Bu işlemleri onaylamanız gerekiyor", - "deployFactoryContract": "Fabrika sözleşmesini dağıtın", - "deployRouterContract": "Yönlendirici sözleşmesini dağıt", - "saveInfoToDomainRegistry": "Save information to the domain registry contract", - "storageContract": "Depolama sözleşmesi", - "chooseNetwork": "Ağ seçin", - "chooseWallet": "Cüzdanı seçin", - "appIsNotReadyYet": "Uygulama henüz hazır değil", - "importPool": "havuzu içe aktar", - "selectTokenToFindYourLiquidity": "Likiditenizi bulmak için bir jeton seçin", - "findManually": "Kendiniz bulun", - "backgroundColor": "Arka plan rengi", - "textColor": "Metin rengi", - "light": "Işık", - "dark": "Karanlık", - "swapFormDefaultCurrency": "Varsayılan para birimini değiştir", - "itWillNotWorkIfYouPasteWrongAddress": "Adres yanlışsa veya belirteç listesi bu adresi içermiyorsa çalışmaz.", - "inputToken": "Giriş belirteci", - "outputToken": "Çıkış jetonu", - "disableSourceCopyright": "Kaynak telif hakkını devre dışı bırak", - "backgroundUrl": "Arka plan URL'si", - "storageNetwork": "Depolama ağı", - "contractsNetwork": "Sözleşmeler ağı", - "saveSwapContracts": "Takas sözleşmelerini kaydet", - "switchToNetwork": "Değiştirmek {{network}}", - "colors": "Renk", - "listNetworkId": "Ağ kimliğini listele", - "listNetworkIdDescription": "Liste belirteçlerinin bulunduğu ağın kimliği", - "listId": "Liste Kimliği", - "listIdDescription": "Ağ kimliği değeri için benzersiz", - "tokenLogo": "Jeton logosu", - "fillTokenListChainId": "Simge listesi zincir kimliğini doldur", - "youHaveSuchList": "Böyle bir listen var.", - "migration": "Göç", - "oldDomain": "Eski alan adı", - "newDomain": "Yeni alan adı", - "afterMigrationYourDataWillBeDeleted": "Geçişten sonra bu etki alanı verileri silinir. Yalnızca yeni bir etki alanından erişebilirsiniz", - "migrateToNewDomain": "Yeni bir etki alanına geçirme", - "instructionToSaveContractsFromDifferentNetwork": "Sözleşmeleri Depolama ağı dışındaki bir ağdan dağıtırsanız, bunları el ile kaydetmeniz gerekir. Depolama ağına geçin, bu girişleri doldurun ve kaydedin. Mevcut sözleşmeleri de kullanabilirsiniz, ancak yalnızca bunlarla ilgiliyse Definance", - "youHaveToDeploySwapContractsFirst": "İlk önce takas sözleşmelerini dağıtmanız gerekir", - "pleaseSelectOneOfTheFollowingNetworks": "Lütfen aşağıdaki ağlardan birini seçin", - "youAlreadyHaveSwapContractsWarning": "Zaten takas sözleşmeleri dağıttınız. Tekrar yaparsanız eski sözleşme adreslerinin üzerine yazılacaktır. Yeni sözleşmeler likidite ve ücret ayarları olmadan olacak", - "youAlreadyHaveStorageContractWarning": "Depolama sözleşmesini zaten dağıttınız. Tekrar yaparsanız eski depolama adresinin üzerine yazılacaktır. Arayüz ayarlarını kaybedeceksiniz", - "noPointToChangeAdminFeeWithoutFeeRecipient": "Ücret alıcı adresini belirleyene kadar bu komisyonu değiştirmenin bir anlamı yok.", - "forSuccessfulExchangeRecommendedToIncreaseSlippageTo": "Başarılı bir değişim için Kayma Toleransının artırılması önerilir." -} +{ + "token": "token", + "business": "işletme", + "taxi": "Taksi", + "coffee": "Coffee", + "delivery": "Teslimat", + "earn": "Kazan", + "businessCard": "Kartvizit", + "company": "şirket", + "rider": "Rider", + "driver": "Driver", + "createPair": "Çift oluştur", + "connectWallet": "Cüzdanı Bağla", + "noWallet": "Ethereum cüzdanı bulunamadı", + "wrongNetwork": "Yanlış ağdasın", + "switchNetwork": "Please switch to {{ correctNetwork }}", + "installWeb3MobileBrowser": "Lütfen bizi Trust Wallet veya Coinbase Wallet gibi web3 özellikli bir mobil tarayıcıdan ziyaret edin.", + "installMetamask": "Lütfen Metamask'ı Chrome veya Brave'e yükledikten sonra bizi ziyaret edin.", + "disconnected": "Bağlantı kesildi", + "swap": "Takas", + "send": "gönder", + "sendAnyway": "Ne olursa olsun gönder", + "pool": "havuz", + "betaWarning": "Bu proje beta aşamasındadır. Kendi sorumluluğunuzda kullanın.", + "input": "giriş", + "output": "Çıktı", + "estimated": "Tahmini", + "balance": "Bakiye: {{ balanceInput }}", + "unlock": "Kilidini aç", + "pending": "Bekliyor", + "selectToken": "Token seçin", + "searchOrPaste": "Token ara, sembol, yada Adres", + "searchOrPasteMobile": "İsim, sembol, yada Adres", + "noExchange": "No Exchange Found", + "noToken": "Token Bulunamadı", + "exchangeRate": "kur farkı", + "unknownError": "Bilinmeyen bir hata oluştu. Lütfen sayfayı yenileyin veya başka bir tarayıcı veya cihazdan ziyaret edin.", + "enterValueCont": "Enter a {{ missingCurrencyValue }} value to continue.", + "selectTokenCont": "Devam etmek için bir token seçin.", + "noLiquidity": "likidite yok.", + "insufficientLiquidity": "Yetersiz likidite.", + "unlockTokenCont": "Devam etmek için lütfen token nun kilidini açın.", + "transactionDetails": "Gelişmiş Ayrıntılar", + "hideDetails": "Ayrıntıları Gizle", + "slippageWarning": "Kayma uyarısı", + "highSlippageWarning": "Yüksek Kayma Uyarısı", + "youAreSelling": "Satıyorsun", + "orTransFail": "veya işlem başarısız olur.", + "youWillReceive": "En azından alacaksın", + "youAreBuying": "satın alıyorsun", + "itWillCost": "En fazlaya mal olacak", + "forAtMost": "en fazla", + "insufficientBalance": "Yetersiz bakiye", + "inputNotValid": "Geçerli bir giriş değeri değil", + "differentToken": "Farklı token olmalı.", + "noRecipient": "Göndermek için bir cüzdan adresi girin.", + "invalidRecipient": "Lütfen geçerli bir cüzdan adresi alıcısı girin.", + "recipientAddress": "Alıcı adresi", + "youAreSending": "gönderiyorsun", + "willReceive": "en azından alacaksın", + "to": "to", + "addLiquidity": "Likidite Ekle", + "deposit": "Depozito", + "currentPoolSize": "Mevcut Havuz Boyutu", + "yourPoolShare": "Havuz Paylaşımınız", + "noZero": "Tutar sıfır olamaz.", + "mustBeETH": "Girişlerden biri ETH olmalıdır.", + "enterCurrencyOrLabelCont": "Enter a {{ inputCurrency }} or {{ label }} value to continue.", + "youAreAdding": "ekliyorsun", + "and": "ve", + "intoPool": "likidite havuzuna girdi..", + "outPool": "likidite havuzundan.", + "youWillMint": "Mint yapacaksın", + "liquidityTokens": "likidite tokenları.", + "totalSupplyIs": "Mevcut toplam likidite tokenların arzı", + "youAreSettingExRate": "Başlangıç kurunu şu şekilde ayarlıyorsunuz:", + "totalSupplyIs0": "Mevcut toplam likidite belirteçleri arzı 0.", + "tokenWorth": "Mevcut döviz kurunda, her bir havuz tokenın değeri", + "firstLiquidity": "Likidite ekleyen ilk kişi sizsiniz!", + "initialExchangeRate": "The initial exchange rate will be set based on your deposits. Please make sure that your ETH and {{ label }} deposits have the same fiat value.", + "ratioOfPoolTokens": "Eklediğiniz tokenların oranı bu havuzun fiyatını belirleyecektir.", + "happyWithRate": "Orandan memnun kaldığınızda, incelemek için arza tıklayın.", + "whenYouAddLiquidityTip": "Likidite eklediğinizde, pozisyonunuzu temsil eden havuz tokenları alacaksınız. Bu tokenlar, havuzdaki payınızla orantılı olarak otomatik olarak ücret alır ve herhangi bir zamanda kullanılabilir.", + "approving": "", + "approve": "Onayla", + "approved": "Onaylandı", + "slippageTolerance": "Kayma Toleransı", + "price": "Fiyat", + "removeSend": "Göndermeyi kaldır", + "addSend": "Gönderme ekle (isteğe bağlı)", + "receive": "Teslım Al", + "removingPoolTokensTip": "Havuz tokenlarını kaldırmak, konumunuzu havuzdaki payınızla orantılı olarak mevcut oranda temel tokenlara dönüştürür. Tahakkuk eden ücretler, aldığınız tutarlara dahildir.", + "amount": "Miktar", + "removeLiquidity": "Likiditeyi Kaldır", + "poolTokens": "Havuz Tokenları", + "enterLabelCont": "Enter a {{ label }} value to continue.", + "youAreRemoving": "Arasındakılerı kaldırıyorsun", + "youWillRemove": "Silmek üzeresin", + "createExchange": "Kambiyo Oluştur", + "invalidTokenAddress": "Geçerli bir token adresi değil", + "exchangeExists": "{{ label }} Exchange zaten var!!", + "invalidSymbol": "Geçersiz sembol", + "invalidDecimals": "Geçersiz ondalık sayılar", + "tokenAddress": "Token adresi", + "label": "Etiket", + "name": "İsim", + "symbol": "sembol", + "decimals": "Ondalık sayılar", + "enterTokenCont": "Devam etmek için bir token adresi girin", + "priceChange": "Beklenen fiyat kayması", + "forAtLeast": "en azından ", + "toleranceExplanation": "Bu sınırı düşürmek, önden koşma riskinizi azaltır. Ancak bu, normal fiyat hareketleri nedeniyle işleminizin başarısız olma olasılığını artırır..", + "tokenSearchPlaceholder": "isim arayın veya adresi yapıştırın", + "areYouSure": "Emin misin?", + "expertModeDescription": "Uzman modu, işlem onaylama istemini kapatır ve genellikle düşük oranlara ve para kaybına neden olan yüksek kaymalı işlemlere izin verir.", + "expertModeWarning": "BU MODU SADECE NE YAPTIĞINIZI BİLİYORSANIZ KULLANIN.", + "turnOnExpertMode": "Turn On Expert Mode", + "transactionSettings": "Uzman Modunu Aç", + "interfaceSettings": "Arayüz Ayarları", + "toggleExpertMode": "Uzman Modunu Aç/Kapat", + "disableMultihops": "Çoklu Atlamayı Devre Dışı Bırak", + "transactionDeadline": "İşlem son tarihi", + "minutes": "dakikalar", + "newToEthereum": "Ethereum'da yeni misiniz?", + "learnWallets": "Cüzdanlar hakkında daha fazla bilgi edinin", + "yourLiquidity": "Likiditeniz", + "loading": "Yükleniyor", + "connectToWalletForLiquidity": "Likiditenizi görüntülemek için bir cüzdana bağlanın", + "noLiquidityFound": "Likidite bulunamadı", + "noTokenResultsFound": "Aktif listelerde sonuç bulunamadı", + "manage": "idare et", + "commonBases": "Ortak bazlar", + "enterValidTokenAddress": "Geçerli token adresini girin", + "clearAll": "Hepsini temizle", + "tipAboutCustomTokens": "İpucu: Özel tokenlar tarayıcınızda yerel olarak depolanır", + "account": "Hesap", + "disconnect": "Bağlantıyı kes", + "change": "Değiştir", + "copyAddress": "Adresi kopyala", + "viewIn": "Görüntüle", + "recentTransactions": "Son İşlemler", + "yourTransactionsAppearHere": "İşlemleriniz burada görünecek", + "connectedWith": "Connected with", + "pooled": "havuzlanmış", + "add": "Ekle", + "remove": "Kaldır", + "manageLiquidityInPool": "Ödül havuzundaki likiditeyi yönetin", + "poolTokensInRewardsPool": "havuzdaki tokenlar ödüllü havuzda", + "yourTotalPoolTokens": "Toplam havuz tokenlarınız", + "yourPosition": "Pozisyonun", + "lightTheme": "Açık renk tema", + "darkTheme": "Koyu renk tema", + "language": "Dil", + "settings": "Ayarlar", + "lists": "Listeler", + "tokens": "Tokenlar", + "invalidPair": "Geçersiz çift", + "noPoolFound": "Havuz bulunamadı", + "createPool": "Havuz oluştur", + "youDoNotHaveLiquidity": "Bu havuzda henüz likiditeniz yok", + "managePool": "Bu havuzu yönet", + "poolFound": "Havuz bulundu", + "useThisToolToFindPairs": "Arayüzde otomatik olarak görünmeyen çiftleri bulmak için bu aracı kullanın", + "requiredField": "Gerekli alan", + "deployment": "Dağıtım", + "swapContracts": "Takas sözleşmeleri", + "interfaceOptions": "Arayüz seçenekleri", + "deploySwapContracts": "Takas sözleşmeleri dağıtın", + "wrappedTokenDescription": "Sarılmış token - yerel bir EVM ağ para birimini temsil eden ERC20 tokenı(ETH, BNB, MATIC, gibi.). Yerel para biriminin diğer ERC20 jetonlarıyla değiştirilebilmesi için paketlenmesi gerekir. Yerel para birimini sarmak değerini etkilemez. Örneğin 1 ETH = 1 WETH", + "wrappedToken": "Sarılmıştoken", + "admin": "Yönetici", + "domain": "Domain", + "deployStorageContract": "Depolama sözleşmesi dağıtın", + "deployStorage": "Depolamayı dağıtın", + "deploymentInformation": "Dağıtım bilgileri", + "deploymentInformationDescription": "Dağıtılan sözleşmelerle ilgili en son bilgileri aşağıda görebilirsiniz. Kaydetmeyi unutmayın", + "factory": "Fabrika", + "router": "Router", + "storage": "Depo", + "save": "Kayıt et", + "factoryAddress": "Fabrika adresi", + "newAdmin": "Yeni yönetici", + "feeRecipient": "Ücret alıcısı", + "allFeesToAdmin": "Tüm ücretler yöneticiye (likidite sağlayıcıları için ücret yok)", + "feeIsChargedWhen": "Bu adresin ayarlanması ve sıfır adres olmaması durumunda komisyon tahsil edilir.", + "youCanUseTheSameAddressForBoothInputs": "Her iki giriş için de aynı adresi kullanabilirsiniz.", + "listName": "Liste adı", + "logo": "Logo", + "noTokens": "Tokenlar yok", + "saveTokenList": "Token listesini kaydet", + "updateTokenList": "Token listesini güncelle", + "noTokenLists": "Token listesi yok", + "fetchOptions": "Getirme seçenekleri", + "saveAllSettings": "Tüm ayarları kaydet", + "tokenLists": "Token listeleri", + "createNewTokenList": "Yeni bir token listesi oluşturun", + "youCanNotUseThisNetwork": "Üzgünüz, bu ağı kullanamazsınız", + "pleaseSelectTheFollowingNetwork": "Lütfen aşağıdaki ağı seçin", + "availableNetworks": "Kullanılabilir ağlar", + "toGetStartedConnectWallet": "Başlamak için cüzdanınızı bağlayın", + "pleaseChangeWrongNetwork": "Lütfen ağınızı değiştirin veya uygun ağa bağlanın", + "noInfo": "No information", + "saveSettings": "Ayarları kaydet", + "deployAfterSwapContracts": "Takas sözleşmelerinden sonra dağıtın", + "resetDomainData": "Reset domain data", + "projectName": "Proje Adı", + "logoUrl": "Logo url", + "socialLinks": "Social links", + "resetDomainDescription": "Bu alan adına ait tüm veriler silinecek(admin, contract addresses and settings)", + "youAreDeployingSwapContracts": "Takas sözleşmeleri dağıtacaksınız", + "youAreDeployingStorage": "Depolama sözleşmesi dağıtmak üzeresiniz", + "confirmDeployment": "Dağıtımı onaylayın", + "confirmTransactionInWallet": "Bu işlemi cüzdanınızda onaylayın", + "waitingForConfirmation": "Onay bekleniyor", + "transactionSubmitted": "İşlem gönderildi", + "accept": "Kabul et", + "outputEstimatedYouReceiveAtLeast": "Çıktı tahmini. En azından alacaksın", + "orTransactionWillRevert": "veya işlem geri dönecek", + "inputEstimatedYouSellAtMost": "Giriş tahminidir. En fazla satarsın", + "outputWillSentTo": "çıktı gönderilecek", + "minimumReceived": "Minimum alınan", + "maximumSold": "Maksimum satılan", + "priceImpact": "Fiyat etkisi", + "liquidityProviderFee": "Likidite sağlayıcı ücreti", + "minimumReceivedDescription": "Onaylanmadan önce büyük, olumsuz bir fiyat hareketi olursa işleminiz geri dönecektir (iptal edilecek).", + "priceImpactDescription": "Ticaret büyüklüğü nedeniyle piyasa fiyatı ile tahmini fiyat arasındaki fark", + "liquidityProviderFeeDescription": "Her ticaretin bir kısmı protokol teşviki olarak likidite sağlayıcılarına gider", + "route": "Route", + "routeDescription": "Bu tokenlar aracılığıyla yönlendirme, işleminiz için en iyi fiyatla sonuçlandı", + "primaryColor": "Primary color", + "menuLinks": "Menu links", + "navigationLinks": "Navigation links", + "swapAnyway": "Yine de değiş tokuş yap", + "confirmSwap": "Takas işlemini onaylayın", + "transactionTimeoutDescription": "İşleminiz bu süreden daha uzun süre beklemedeyse işleminiz geri alınacaktır.", + "enterValidSlippage": "Geçerli bir kayma yüzdesi girin", + "yourTransactionMayFail": "İşleminiz başarısız olabilir", + "yourTransactionMayBeFrontrun": "İşleminiz ön çalışmalı olabilir", + "noConnectionMethodsAvailable": "Kullanılabilir bağlantı yöntemi yok", + "deploymentSectionDescription": "seçenekler sözleşme dağıtımıyla ilgilidir", + "interface": "Arayüz", + "instructions": "Talimatlar", + "addressesOfTokenLists": "Token listelerinin adresleri", + "beCareful": "Dikkat olun", + "adminFee": "yönetici ücreti", + "feeSettings": "Ücret ayarları", + "feesDescription": "Toplam ücret, her takasta alınır ve likidite havuzu tokanındaki ek bir miktarlar likidite havuzunda birikir. Likiditenin kaldırılmasından sonra birikmiş ücretleri alabilirsiniz", + "caseWhenNoFeesCharged": "Toplam ücret %0 ise, yönetici dahil hiçbir ücret alınmaz.", + "adminFeeIsPercentOfTotalFee": "Yönetici ücreti, toplam ücretin bir yüzdesidir", + "totalFee": "Toplam ücret", + "liquidityProviders": "Likidite sağlayıcıları", + "adminAndProvidersFeesDoNotWork": "Yönetici ve sağlayıcı ücretleri çalışmıyor", + "tradeAtYourOwnRisk": "Kendi sorumluluğunuzda alım satım yapın!", + "fakeTokenCreationWarning": "Projeleri temsil ettiğini iddia eden mevcut belirteçlerin sahte sürümlerini oluşturmak da dahil olmak üzere herkes bir belirteç oluşturabilir", + "fakeTokenPurchaseWarning": "Bu tokenu satın alırsanız, onu geri satamayabilirsiniz.", + "iUnderstand": "Anladım", + "address": "Adres", + "your": "sizin", + "deploy": "Dağıt", + "youHaveToConfirmTheseTxs": "Bu işlemleri onaylamanız gerekiyor", + "deployFactoryContract": "Fabrika sözleşmesini dağıtın", + "deployRouterContract": "Yönlendirici sözleşmesini dağıt", + "saveInfoToDomainRegistry": "Save information to the domain registry contract", + "storageContract": "Depolama sözleşmesi", + "chooseNetwork": "Ağ seçin", + "chooseWallet": "Cüzdanı seçin", + "appIsNotReadyYet": "Takas sözleşmeleri henüz hazır değil. Yönetici bu ağı kullanmaya başlamak için yeni sözleşmeler dağıtmalıdır", + "importPool": "havuzu içe aktar", + "selectTokenToFindYourLiquidity": "Likiditenizi bulmak için bir jeton seçin", + "findManually": "Kendiniz bulun", + "backgroundColor": "Arka plan rengi", + "textColor": "Metin rengi", + "light": "Işık", + "dark": "Karanlık", + "swapFormDefaultCurrency": "Varsayılan para birimini değiştir", + "itWillNotWorkIfYouPasteWrongAddress": "Adres yanlışsa veya belirteç listesi bu adresi içermiyorsa çalışmaz.", + "inputToken": "Giriş belirteci", + "outputToken": "Çıkış jetonu", + "disableSourceCopyright": "Kaynak telif hakkını devre dışı bırak", + "backgroundUrl": "Arka plan URL'si", + "storageNetwork": "Depolama ağı", + "contractsNetwork": "Sözleşmeler ağı", + "saveSwapContracts": "Takas sözleşmelerini kaydet", + "switchToNetwork": "Değiştirmek {{network}}", + "colors": "Renk", + "listNetworkId": "Ağ kimliğini listele", + "listNetworkIdDescription": "Liste belirteçlerinin bulunduğu ağın kimliği", + "listId": "Liste Kimliği", + "listIdDescription": "Ağ kimliği değeri için benzersiz", + "tokenLogo": "Jeton logosu", + "fillTokenListChainId": "Simge listesi zincir kimliğini doldur", + "youHaveSuchList": "Böyle bir listen var.", + "migration": "Göç", + "oldDomain": "Eski alan adı", + "newDomain": "Yeni alan adı", + "waitUntilYourAddressWillBeSaved": "Adresiniz kaydedilene kadar bekleyin", + "setNewDomainAdmin": "Yeni bir etki alanı yöneticisi ayarlama", + "saveThisAddressAsDomainOwner": "Bu adresi etki alanı sahibi olarak kaydetme", + "afterMigrationYourDataWillBeDeleted": "Geçişten sonra bu etki alanı verileri silinir. Yalnızca yeni bir etki alanından erişebilirsiniz", + "migrateToNewDomain": "Yeni bir etki alanına geçirme", + "instructionToSaveContractsFromDifferentNetwork": "Sözleşmeleri Depolama ağı dışındaki bir ağdan dağıtırsanız, bunları el ile kaydetmeniz gerekir. Depolama ağına geçin, bu girişleri doldurun ve kaydedin. Mevcut sözleşmeleri de kullanabilirsiniz, ancak yalnızca bunlarla ilgiliyse Definance", + "youHaveToDeploySwapContractsFirst": "İlk önce takas sözleşmelerini dağıtmanız gerekir", + "pleaseSelectOneOfTheFollowingNetworks": "Lütfen aşağıdaki ağlardan birini seçin", + "youAlreadyHaveSwapContractsWarning": "Zaten takas sözleşmeleri dağıttınız. Tekrar yaparsanız eski sözleşme adreslerinin üzerine yazılacaktır. Yeni sözleşmeler likidite ve ücret ayarları olmadan olacak", + "youAlreadyHaveStorageContractWarning": "Depolama sözleşmesini zaten dağıttınız. Tekrar yaparsanız eski depolama adresinin üzerine yazılacaktır. Arayüz ayarlarını kaybedeceksiniz", + "noPointToChangeAdminFeeWithoutFeeRecipient": "Ücret alıcı adresini belirleyene kadar bu komisyonu değiştirmenin bir anlamı yok.", + "forSuccessfulExchangeRecommendedToIncreaseSlippageTo": "Başarılı bir değişim için Kayma Toleransının artırılması önerilir.", + "HelloLetsConnectThisDomain": "Merhaba! Bu alanı cüzdan adresinize bağlayalım", + "IfYouWantToChangeTheAddressSwitchToAnotherAddress": "Adresi değiştirmek istiyorsanız, başka bir adrese geçin. Geçiş yapamıyorsanız, cüzdanınızın bağlantısını kesin ve yeni adrese bağlayın.", + "setTheOwner": "Sahibini ayarla", + "setAddressAsThewnerOfDomain": "Adresinizi bu etki alanının sahibi olarak ayarlayın", + "onlyThisAddressCanAccessAppSettings": "Uygulama ayarlarına yalnızca bu adres erişebilir ve bunları değiştirebilir" +} diff --git a/locales/zh.json b/locales/zh.json index 6c1de81..a45a3f8 100644 --- a/locales/zh.json +++ b/locales/zh.json @@ -253,7 +253,7 @@ "storageContract": "储存合约", "chooseNetwork": "选择网络", "chooseWallet": "选择钱包", - "appIsNotReadyYet": "应用程序还没有准备好", + "appIsNotReadyYet": "掉期合约还没有准备好。 管理员必须部署新合同才能开始使用此网络", "selectTokenToFindYourLiquidity": "选择一个令牌来查找您的流动性", "importPool": "进口池", "findManually": "手动查找", @@ -282,6 +282,9 @@ "migration": "移民问题", "oldDomain": "旧域名", "newDomain": "新域名", + "waitUntilYourAddressWillBeSaved": "等待,直到您的地址将被保存", + "setNewDomainAdmin": "设置新域管理员", + "saveThisAddressAsDomainOwner": "将此地址保存为域所有者", "afterMigrationYourDataWillBeDeleted": "迁移后,此域的数据将被删除。 您只能从新域访问它", "migrateToNewDomain": "迁移到新域", "instructionToSaveContractsFromDifferentNetwork": "如果从存储网络以外的网络部署合同,则需要手动保存它们。 切换到存储网络,填充这些输入并保存。 您也可以使用现有合同,但前提是它们与 Definance", @@ -290,5 +293,10 @@ "youAlreadyHaveSwapContractsWarning": "您已经部署了掉期合约。 如果你再这样做,旧的合同地址将被复盖。 新合约将没有流动性和费用设置", "youAlreadyHaveStorageContractWarning": "您已经部署了存储合同。 如果再这样做,旧的存储地址将被复盖。 您将丢失界面设置", "noPointToChangeAdminFeeWithoutFeeRecipient": "在您设置佣金收件人的地址之前,更改此佣金是没有意义的", - "forSuccessfulExchangeRecommendedToIncreaseSlippageTo": "為了成功交換,建議將滑點容差增加到" + "forSuccessfulExchangeRecommendedToIncreaseSlippageTo": "為了成功交換,建議將滑點容差增加到", + "HelloLetsConnectThisDomain": "你好! 让我们把这个域名连接到你的钱包地址", + "IfYouWantToChangeTheAddressSwitchToAnotherAddress": "如果要更改地址,請切換到另一個地址。如果您無法切換,只需斷開您的錢包並將其連接到新地址即可。", + "setTheOwner": "设置所有者", + "setAddressAsTheOwnerOfDomain": "将您的地址设置为该域的所有者", + "onlyThisAddressCanAccessAppSettings": "只有这个地址才能访问和更改应用程序设置" } diff --git a/precache-manifest.457ae0c736914514271fc5c1b70b5e31.js b/precache-manifest.8208b73a7a1eec7983c4ff3046696139.js similarity index 63% rename from precache-manifest.457ae0c736914514271fc5c1b70b5e31.js rename to precache-manifest.8208b73a7a1eec7983c4ff3046696139.js index 9776dd9..e31a930 100644 --- a/precache-manifest.457ae0c736914514271fc5c1b70b5e31.js +++ b/precache-manifest.8208b73a7a1eec7983c4ff3046696139.js @@ -1,51 +1,55 @@ self.__precacheManifest = (self.__precacheManifest || []).concat([ { - "revision": "33e7665b422f2eff23553c1964b6d075", + "revision": "304e84db9180ef2cfbe01d29634e8a8d", "url": "./index.html" }, { - "revision": "39e0d7b5333a536ff892", + "revision": "2b689c5235645cb0a891", "url": "./static/css/3.a1ab5bd7.chunk.css" }, { - "revision": "50e1a326d18d259698c3", - "url": "./static/css/main.904b2218.chunk.css" + "revision": "2e5f2385c83bd03767a7", + "url": "./static/css/main.c9ee16f2.chunk.css" }, { - "revision": "1833dfd1648032ff305e", - "url": "./static/js/0.0c8959de.chunk.js" + "revision": "62666f6686c872b5811a", + "url": "./static/js/0.010e1646.chunk.js" }, { - "revision": "39e0d7b5333a536ff892", - "url": "./static/js/3.9d3b560a.chunk.js" + "revision": "2b689c5235645cb0a891", + "url": "./static/js/3.cc9b9445.chunk.js" }, { - "revision": "13ce7befccc4b77eba90d752761debed", - "url": "./static/js/3.9d3b560a.chunk.js.LICENSE.txt" + "revision": "4b6e726746b39eb986a5dc83e4bac5b2", + "url": "./static/js/3.cc9b9445.chunk.js.LICENSE.txt" }, { - "revision": "ed6baad018eb0c841fe3", - "url": "./static/js/4.4a54806d.chunk.js" + "revision": "5639dec7b6103d6c17e5", + "url": "./static/js/4.8903312b.chunk.js" }, { - "revision": "15963004aabb0d5bb5f5", - "url": "./static/js/5.2c3c3ed9.chunk.js" + "revision": "e5bc29afd33143170fd0", + "url": "./static/js/5.0e309873.chunk.js" }, { - "revision": "e15e83db23e794a86a210f6e7497ab09", - "url": "./static/js/5.2c3c3ed9.chunk.js.LICENSE.txt" + "revision": "086ac0f260c0d88cf399717695349565", + "url": "./static/js/5.0e309873.chunk.js.LICENSE.txt" }, { - "revision": "1fe11ddf5ac0f8e1a8c2", - "url": "./static/js/6.01f07149.chunk.js" + "revision": "1ea5a96d167590fe5a66", + "url": "./static/js/6.73b67430.chunk.js" }, { - "revision": "50e1a326d18d259698c3", - "url": "./static/js/main.8d7ad959.chunk.js" + "revision": "9de7a885285b119adf74", + "url": "./static/js/7.f9293408.chunk.js" }, { - "revision": "c63c0cd53bc0a03d87c9", - "url": "./static/js/runtime-main.f0688bb1.js" + "revision": "2e5f2385c83bd03767a7", + "url": "./static/js/main.aeb7ae13.chunk.js" + }, + { + "revision": "f38b7eabac5eac3b4074", + "url": "./static/js/runtime-main.e923fa6f.js" }, { "revision": "661569afe57a38e1529a775a465da20b", @@ -208,76 +212,76 @@ self.__precacheManifest = (self.__precacheManifest || []).concat([ "url": "./static/media/arbitrum.fa428345.png" }, { - "revision": "114fab910be089671a355764e2326334", - "url": "./static/media/arrow-down-blue.114fab91.svg" + "revision": "cd061363bbf9cd7a26cb09b642dcaf63", + "url": "./static/media/arrow-down-blue.cd061363.svg" }, { - "revision": "4d4a6a99f8bc24af0fcf805146d38a46", - "url": "./static/media/arrow-down-grey.4d4a6a99.svg" + "revision": "c0dedd2f2ed0c4d07d7ca75af3f0a65f", + "url": "./static/media/arrow-down-grey.c0dedd2f.svg" }, { "revision": "337ad716bd89163e2a9c3495b7e0f029", "url": "./static/media/arrow-right-white.337ad716.png" }, { - "revision": "e96d8158ff6d3087ab15e43e64fbb47e", - "url": "./static/media/arrow-right.e96d8158.svg" + "revision": "d285b6cf22b4f1552bb4009333462632", + "url": "./static/media/arrow-right.d285b6cf.svg" }, { - "revision": "d13b261cdb325ca4e59485cc1a2a2c25", - "url": "./static/media/aurora.d13b261c.svg" + "revision": "e7a52317c05b6ec3392085d52123968f", + "url": "./static/media/aurora.e7a52317.svg" }, { "revision": "2565884a03843bf5f37bf4a806402acf", "url": "./static/media/avax.2565884a.png" }, { - "revision": "e62a99c33b7eafddf701893750cedeb9", - "url": "./static/media/blue-loader.e62a99c3.svg" + "revision": "904b44c2b22eb2d49f618396e6f2db1a", + "url": "./static/media/blue-loader.904b44c2.svg" }, { "revision": "162aaf57c64bd732a87c2d553a12f165", "url": "./static/media/bnb.162aaf57.png" }, { - "revision": "5dd950ec66be581e8da4376f49a19d77", - "url": "./static/media/circle-grey.5dd950ec.svg" + "revision": "ed2a1dad16cb9a4b9afd788ddaae7290", + "url": "./static/media/circle-grey.ed2a1dad.svg" }, { - "revision": "716403ba670c3577abbea8e66f428721", - "url": "./static/media/circle.716403ba.svg" + "revision": "2d975615c4c409c3b6b00e8ae7c5767a", + "url": "./static/media/circle.2d975615.svg" }, { - "revision": "aa4c7a7647abc7ede02e017c1a0141b6", - "url": "./static/media/coinbaseWalletIcon.aa4c7a76.svg" + "revision": "62578f5994645a1825d4829e2c4394b0", + "url": "./static/media/coinbaseWalletIcon.62578f59.svg" }, { - "revision": "73b9bf96a6d40089600021dc81e28d85", - "url": "./static/media/cro.73b9bf96.svg" + "revision": "f578d9cdc830bae843b72c87b78b4b1c", + "url": "./static/media/cro.f578d9cd.svg" }, { - "revision": "4b9a7c8903a172402c43e975cd628062", - "url": "./static/media/de.4b9a7c89.svg" + "revision": "78feb91bfda2ddce6bcfdcbab050995b", + "url": "./static/media/de.78feb91b.svg" }, { - "revision": "80a3ae258c229f3c874a8acdf65adeea", - "url": "./static/media/dropdown-blue.80a3ae25.svg" + "revision": "b20914ec5482543a0b1b2c6d5509ab96", + "url": "./static/media/dropdown-blue.b20914ec.svg" }, { - "revision": "50dbd07d8e7428d04464644f7cf819cf", - "url": "./static/media/dropdown.50dbd07d.svg" + "revision": "7d32d2fa19d17d6ab9f0e0067bebaf96", + "url": "./static/media/dropdown.7d32d2fa.svg" }, { - "revision": "345dad7494f835eb9ae6c21c2d3a25f4", - "url": "./static/media/dropup-blue.345dad74.svg" + "revision": "b96d70e10dd30a64a0d122603577c8ae", + "url": "./static/media/dropup-blue.b96d70e1.svg" }, { - "revision": "42219103602e6dd2f02fb005bce546b7", - "url": "./static/media/en.42219103.svg" + "revision": "8886b28b10e3ec0756a9935a216d5bba", + "url": "./static/media/en.8886b28b.svg" }, { - "revision": "6273c78a6e1df30a937e77571d8a83cd", - "url": "./static/media/es.6273c78a.svg" + "revision": "426a1551c98dbbe2a847dd8fd0e2eb5b", + "url": "./static/media/es.426a1551.svg" }, { "revision": "86b356aa4636232f3e200c65d2a8b6b4", @@ -288,8 +292,8 @@ self.__precacheManifest = (self.__precacheManifest || []).concat([ "url": "./static/media/ftm.3af63018.svg" }, { - "revision": "306cb394d8f9dcbd17bef4de084406f8", - "url": "./static/media/fuse.306cb394.svg" + "revision": "65ec57528b9f6dbfbcf5f7cdde0603da", + "url": "./static/media/fuse.65ec5752.svg" }, { "revision": "cb9b3252a26b080c4964baeb2b7ff53c", @@ -300,28 +304,28 @@ self.__precacheManifest = (self.__precacheManifest || []).concat([ "url": "./static/media/ht.0d242628.svg" }, { - "revision": "7e79b672265708ee53cf41c32a124bdc", - "url": "./static/media/it.7e79b672.svg" + "revision": "1d72a5dec3acd073763570e3e5fdf784", + "url": "./static/media/it.1d72a5de.svg" }, { - "revision": "01c3fe8adf16309a7847b129f3393f9b", - "url": "./static/media/iw.01c3fe8a.svg" + "revision": "519847287bb66fbec84a8233cf5597d5", + "url": "./static/media/iw.51984728.svg" }, { "revision": "50c67f3cdd04281013ef95e92fc7244e", "url": "./static/media/link.50c67f3c.svg" }, { - "revision": "52eac682e8d399b4a8d1d48e38a60535", - "url": "./static/media/magnifying-glass.52eac682.svg" + "revision": "674400972753804891ec372652944539", + "url": "./static/media/magnifying-glass.67440097.svg" }, { "revision": "1ee4a1ab4dd95100e8d21e67acf53849", "url": "./static/media/matic.1ee4a1ab.png" }, { - "revision": "981ecca4e2e244ff635162cbb11b69ac", - "url": "./static/media/menu.981ecca4.svg" + "revision": "4f2c4440e19ed9428d0caae5d9840df6", + "url": "./static/media/menu.4f2c4440.svg" }, { "revision": "023762b6aec2a2249b8fdfb638f00ef3", @@ -336,52 +340,52 @@ self.__precacheManifest = (self.__precacheManifest || []).concat([ "url": "./static/media/one.e781dbdc.svg" }, { - "revision": "0d245621115b2c0453939f631d70aa58", - "url": "./static/media/optimisticEth.0d245621.svg" + "revision": "7b05fcf4c86e0e00c1053d6facbac3c8", + "url": "./static/media/optimisticEth.7b05fcf4.svg" }, { - "revision": "899a4aa9bf85aba699112cc7cab6578e", - "url": "./static/media/plus-blue.899a4aa9.svg" + "revision": "e8021e51723d455b2f9fa2446808d2a3", + "url": "./static/media/plus-blue.e8021e51.svg" }, { - "revision": "62281ca8cea976c7f20862db5d12728e", - "url": "./static/media/plus-grey.62281ca8.svg" + "revision": "d8e0be7d6efb0b53c37eb75e44b35bda", + "url": "./static/media/plus-grey.d8e0be7d.svg" }, { "revision": "b234b2bfa0417c7e8711c3a8d17afeec", "url": "./static/media/portisIcon.b234b2bf.png" }, { - "revision": "1761ff9cb139a2ba2a3a485172eb094c", - "url": "./static/media/question-mark.1761ff9c.svg" + "revision": "1ae4d9f4653371789d98b85139933d27", + "url": "./static/media/question-mark.1ae4d9f4.svg" }, { - "revision": "63be1e247274b62bc269445bf114d497", - "url": "./static/media/question.63be1e24.svg" + "revision": "a46e8bc1a36444be83a85007353d692f", + "url": "./static/media/question.a46e8bc1.svg" }, { "revision": "3f61edb2c675ef535b0847ef14556579", "url": "./static/media/rbtc.3f61edb2.png" }, { - "revision": "5d71cdb2ccd36f145a371fab0548e2d8", - "url": "./static/media/ru.5d71cdb2.svg" + "revision": "ab61f31edf4ad95b5ae00aff3be99197", + "url": "./static/media/ru.ab61f31e.svg" }, { - "revision": "a98424922149274b8a364358d02da9fe", - "url": "./static/media/spinner.a9842492.svg" + "revision": "be00fc4a29d03016e78b28c9943e3f51", + "url": "./static/media/spinner.be00fc4a.svg" }, { - "revision": "7cbcd424ca554dd563744b7ddfe7ac92", - "url": "./static/media/tomo.7cbcd424.svg" + "revision": "db76ba27ecaa7ced92a58b1ae94d09f4", + "url": "./static/media/tomo.db76ba27.svg" }, { "revision": "edcc1ab5dde5cb3d5cf134c4aade641b", "url": "./static/media/trustWallet.edcc1ab5.png" }, { - "revision": "5e81cac236fd057cb686399a8fa2ea57", - "url": "./static/media/walletConnectIcon.5e81cac2.svg" + "revision": "8215855c185176eb79446ce8cc1f3998", + "url": "./static/media/walletConnectIcon.8215855c.svg" }, { "revision": "5b8e218668bfea1d44b887bd042f6a52", @@ -392,7 +396,7 @@ self.__precacheManifest = (self.__precacheManifest || []).concat([ "url": "./static/media/xdai.573f0f5f.png" }, { - "revision": "1a6fff51c30dea059be5aa4177bde506", - "url": "./static/media/zh.1a6fff51.svg" + "revision": "5c573ebe5273a73856cae1ef8b8dd88c", + "url": "./static/media/zh.5c573ebe.svg" } ]); \ No newline at end of file diff --git a/service-worker.js b/service-worker.js index 52ea20b..4168c62 100644 --- a/service-worker.js +++ b/service-worker.js @@ -14,7 +14,7 @@ importScripts("https://storage.googleapis.com/workbox-cdn/releases/4.3.1/workbox-sw.js"); importScripts( - "./precache-manifest.457ae0c736914514271fc5c1b70b5e31.js" + "./precache-manifest.8208b73a7a1eec7983c4ff3046696139.js" ); self.addEventListener('message', (event) => { diff --git a/static/css/3.a1ab5bd7.chunk.css b/static/css/3.a1ab5bd7.chunk.css index 639981a..c68a2fa 100644 --- a/static/css/3.a1ab5bd7.chunk.css +++ b/static/css/3.a1ab5bd7.chunk.css @@ -1 +1 @@ -@font-face{font-family:"Inter";font-style:normal;font-weight:100;font-display:swap;src:url(../../static/media/Inter-Thin.d52e5e38.woff2) format("woff2"),url(../../static/media/Inter-Thin.b068b718.woff) format("woff")}@font-face{font-family:"Inter";font-style:italic;font-weight:100;font-display:swap;src:url(../../static/media/Inter-ThinItalic.a9780071.woff2) format("woff2"),url(../../static/media/Inter-ThinItalic.97bec988.woff) format("woff")}@font-face{font-family:"Inter";font-style:normal;font-weight:200;font-display:swap;src:url(../../static/media/Inter-ExtraLight.b3b2ed6a.woff2) format("woff2"),url(../../static/media/Inter-ExtraLight.dd19efda.woff) format("woff")}@font-face{font-family:"Inter";font-style:italic;font-weight:200;font-display:swap;src:url(../../static/media/Inter-ExtraLightItalic.079cd1e7.woff2) format("woff2"),url(../../static/media/Inter-ExtraLightItalic.a6566ae6.woff) format("woff")}@font-face{font-family:"Inter";font-style:normal;font-weight:300;font-display:swap;src:url(../../static/media/Inter-Light.780dd2ad.woff2) format("woff2"),url(../../static/media/Inter-Light.5d3776eb.woff) format("woff")}@font-face{font-family:"Inter";font-style:italic;font-weight:300;font-display:swap;src:url(../../static/media/Inter-LightItalic.df29c534.woff2) format("woff2"),url(../../static/media/Inter-LightItalic.d0fa7cbc.woff) format("woff")}@font-face{font-family:"Inter";font-style:normal;font-weight:400;font-display:swap;src:url(../../static/media/Inter-Regular.dc131113.woff2) format("woff2"),url(../../static/media/Inter-Regular.3ac83020.woff) format("woff")}@font-face{font-family:"Inter";font-style:italic;font-weight:400;font-display:swap;src:url(../../static/media/Inter-Italic.fd26ff23.woff2) format("woff2"),url(../../static/media/Inter-Italic.f137a90d.woff) format("woff")}@font-face{font-family:"Inter";font-style:normal;font-weight:500;font-display:swap;src:url(../../static/media/Inter-Medium.75db5319.woff2) format("woff2"),url(../../static/media/Inter-Medium.c0638bea.woff) format("woff")}@font-face{font-family:"Inter";font-style:italic;font-weight:500;font-display:swap;src:url(../../static/media/Inter-MediumItalic.f1e11535.woff2) format("woff2"),url(../../static/media/Inter-MediumItalic.a1b58862.woff) format("woff")}@font-face{font-family:"Inter";font-style:normal;font-weight:600;font-display:swap;src:url(../../static/media/Inter-SemiBold.007ad31a.woff2) format("woff2"),url(../../static/media/Inter-SemiBold.66a68ffa.woff) format("woff")}@font-face{font-family:"Inter";font-style:italic;font-weight:600;font-display:swap;src:url(../../static/media/Inter-SemiBoldItalic.3031b683.woff2) format("woff2"),url(../../static/media/Inter-SemiBoldItalic.6cd13dbd.woff) format("woff")}@font-face{font-family:"Inter";font-style:normal;font-weight:700;font-display:swap;src:url(../../static/media/Inter-Bold.444a7284.woff2) format("woff2"),url(../../static/media/Inter-Bold.99a0d9a7.woff) format("woff")}@font-face{font-family:"Inter";font-style:italic;font-weight:700;font-display:swap;src:url(../../static/media/Inter-BoldItalic.96284e2a.woff2) format("woff2"),url(../../static/media/Inter-BoldItalic.3aa31f73.woff) format("woff")}@font-face{font-family:"Inter";font-style:normal;font-weight:800;font-display:swap;src:url(../../static/media/Inter-ExtraBold.37da9eec.woff2) format("woff2"),url(../../static/media/Inter-ExtraBold.ab70688a.woff) format("woff")}@font-face{font-family:"Inter";font-style:italic;font-weight:800;font-display:swap;src:url(../../static/media/Inter-ExtraBoldItalic.fcc7d60e.woff2) format("woff2"),url(../../static/media/Inter-ExtraBoldItalic.728a4c7d.woff) format("woff")}@font-face{font-family:"Inter";font-style:normal;font-weight:900;font-display:swap;src:url(../../static/media/Inter-Black.661569af.woff2) format("woff2"),url(../../static/media/Inter-Black.d0b121f3.woff) format("woff")}@font-face{font-family:"Inter";font-style:italic;font-weight:900;font-display:swap;src:url(../../static/media/Inter-BlackItalic.a3cc36c8.woff2) format("woff2"),url(../../static/media/Inter-BlackItalic.e3329b2b.woff) format("woff")}@font-face{font-family:"Inter var";font-weight:100 900;font-style:normal;font-named-instance:"Regular";src:url(../../static/media/Inter-roman.var.66c6e408.woff2) format("woff2 supports variations(gvar)"),url(../../static/media/Inter-roman.var.66c6e408.woff2) format("woff2-variations"),url(../../static/media/Inter-roman.var.66c6e408.woff2) format("woff2")}@font-face{font-family:"Inter var";font-weight:100 900;font-style:italic;font-named-instance:"Italic";src:url(../../static/media/Inter-italic.var.1f7ca638.woff2) format("woff2 supports variations(gvar)"),url(../../static/media/Inter-italic.var.1f7ca638.woff2) format("woff2-variations"),url(../../static/media/Inter-italic.var.1f7ca638.woff2) format("woff2")}@font-face{font-family:"Inter var experimental";font-weight:100 900;font-style:oblique 0deg 10deg;src:url(../../static/media/Inter.var.8dd26c3d.woff2) format("woff2-variations"),url(../../static/media/Inter.var.8dd26c3d.woff2) format("woff2")}:root{--reach-dialog:1}[data-reach-dialog-overlay]{background:rgba(0,0,0,.33);position:fixed;top:0;right:0;bottom:0;left:0;overflow:auto}[data-reach-dialog-content]{width:50vw;margin:10vh auto;background:#fff;padding:2rem;outline:none}.rc-slider{position:relative;height:14px;padding:5px 0;width:100%;border-radius:6px;touch-action:none}.rc-slider,.rc-slider *{box-sizing:border-box;-webkit-tap-highlight-color:rgba(0,0,0,0)}.rc-slider-rail{width:100%;background-color:#e9e9e9}.rc-slider-rail,.rc-slider-track{position:absolute;height:4px;border-radius:6px}.rc-slider-track{left:0;background-color:#abe2fb}.rc-slider-handle{position:absolute;width:14px;height:14px;cursor:pointer;cursor:-webkit-grab;margin-top:-5px;cursor:grab;border-radius:50%;border:2px solid #96dbfa;background-color:#fff;touch-action:pan-x}.rc-slider-handle-dragging.rc-slider-handle-dragging.rc-slider-handle-dragging{border-color:#57c5f7;box-shadow:0 0 0 5px #96dbfa}.rc-slider-handle:focus{outline:none}.rc-slider-handle-click-focused:focus{border-color:#96dbfa;box-shadow:unset}.rc-slider-handle:hover{border-color:#57c5f7}.rc-slider-handle:active{border-color:#57c5f7;box-shadow:0 0 5px #57c5f7;cursor:grabbing}.rc-slider-mark{position:absolute;top:18px;left:0;width:100%;font-size:12px}.rc-slider-mark-text{position:absolute;display:inline-block;vertical-align:middle;text-align:center;cursor:pointer;color:#999}.rc-slider-mark-text-active{color:#666}.rc-slider-step{position:absolute;width:100%;height:4px;background:transparent}.rc-slider-dot{position:absolute;bottom:-2px;margin-left:-4px;width:8px;height:8px;border:2px solid #e9e9e9;background-color:#fff;cursor:pointer;border-radius:50%;vertical-align:middle}.rc-slider-dot-active{border-color:#96dbfa}.rc-slider-dot-reverse{margin-right:-4px}.rc-slider-disabled{background-color:#e9e9e9}.rc-slider-disabled .rc-slider-track{background-color:#ccc}.rc-slider-disabled .rc-slider-dot,.rc-slider-disabled .rc-slider-handle{border-color:#ccc;box-shadow:none;background-color:#fff;cursor:not-allowed}.rc-slider-disabled .rc-slider-dot,.rc-slider-disabled .rc-slider-mark-text{cursor:not-allowed!important}.rc-slider-vertical{width:14px;height:100%;padding:0 5px}.rc-slider-vertical .rc-slider-rail{height:100%;width:4px}.rc-slider-vertical .rc-slider-track{left:5px;bottom:0;width:4px}.rc-slider-vertical .rc-slider-handle{margin-left:-5px;touch-action:pan-y}.rc-slider-vertical .rc-slider-mark{top:0;left:18px;height:100%}.rc-slider-vertical .rc-slider-step{height:100%;width:4px}.rc-slider-vertical .rc-slider-dot{left:2px;margin-bottom:-4px}.rc-slider-vertical .rc-slider-dot:first-child{margin-bottom:-4px}.rc-slider-vertical .rc-slider-dot:last-child{margin-bottom:-4px}.rc-slider-tooltip-zoom-down-appear,.rc-slider-tooltip-zoom-down-enter,.rc-slider-tooltip-zoom-down-leave{-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-fill-mode:both;animation-fill-mode:both;display:block!important;-webkit-animation-play-state:paused;animation-play-state:paused}.rc-slider-tooltip-zoom-down-appear.rc-slider-tooltip-zoom-down-appear-active,.rc-slider-tooltip-zoom-down-enter.rc-slider-tooltip-zoom-down-enter-active{-webkit-animation-name:rcSliderTooltipZoomDownIn;animation-name:rcSliderTooltipZoomDownIn;-webkit-animation-play-state:running;animation-play-state:running}.rc-slider-tooltip-zoom-down-leave.rc-slider-tooltip-zoom-down-leave-active{-webkit-animation-name:rcSliderTooltipZoomDownOut;animation-name:rcSliderTooltipZoomDownOut;-webkit-animation-play-state:running;animation-play-state:running}.rc-slider-tooltip-zoom-down-appear,.rc-slider-tooltip-zoom-down-enter{-webkit-transform:scale(0);transform:scale(0);-webkit-animation-timing-function:cubic-bezier(.23,1,.32,1);animation-timing-function:cubic-bezier(.23,1,.32,1)}.rc-slider-tooltip-zoom-down-leave{-webkit-animation-timing-function:cubic-bezier(.755,.05,.855,.06);animation-timing-function:cubic-bezier(.755,.05,.855,.06)}@-webkit-keyframes rcSliderTooltipZoomDownIn{0%{opacity:0;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scale(0);transform:scale(0)}to{-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scale(1);transform:scale(1)}}@keyframes rcSliderTooltipZoomDownIn{0%{opacity:0;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scale(0);transform:scale(0)}to{-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scale(1);transform:scale(1)}}@-webkit-keyframes rcSliderTooltipZoomDownOut{0%{-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scale(1);transform:scale(1)}to{opacity:0;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scale(0);transform:scale(0)}}@keyframes rcSliderTooltipZoomDownOut{0%{-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scale(1);transform:scale(1)}to{opacity:0;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scale(0);transform:scale(0)}}.rc-slider-tooltip{position:absolute;left:-9999px;top:-9999px;visibility:visible}.rc-slider-tooltip,.rc-slider-tooltip *{box-sizing:border-box;-webkit-tap-highlight-color:rgba(0,0,0,0)}.rc-slider-tooltip-hidden{display:none}.rc-slider-tooltip-placement-top{padding:4px 0 8px}.rc-slider-tooltip-inner{padding:6px 2px;min-width:24px;height:24px;font-size:12px;line-height:1;color:#fff;text-align:center;text-decoration:none;background-color:#6c6c6c;border-radius:6px;box-shadow:0 0 4px #d9d9d9}.rc-slider-tooltip-arrow{position:absolute;width:0;height:0;border-color:transparent;border-style:solid}.rc-slider-tooltip-placement-top .rc-slider-tooltip-arrow{bottom:4px;left:50%;margin-left:-4px;border-width:4px 4px 0;border-top-color:#6c6c6c} \ No newline at end of file +@font-face{font-family:"Inter";font-style:normal;font-weight:100;font-display:swap;src:url(../../static/media/Inter-Thin.d52e5e38.woff2) format("woff2"),url(../../static/media/Inter-Thin.b068b718.woff) format("woff")}@font-face{font-family:"Inter";font-style:italic;font-weight:100;font-display:swap;src:url(../../static/media/Inter-ThinItalic.a9780071.woff2) format("woff2"),url(../../static/media/Inter-ThinItalic.97bec988.woff) format("woff")}@font-face{font-family:"Inter";font-style:normal;font-weight:200;font-display:swap;src:url(../../static/media/Inter-ExtraLight.b3b2ed6a.woff2) format("woff2"),url(../../static/media/Inter-ExtraLight.dd19efda.woff) format("woff")}@font-face{font-family:"Inter";font-style:italic;font-weight:200;font-display:swap;src:url(../../static/media/Inter-ExtraLightItalic.079cd1e7.woff2) format("woff2"),url(../../static/media/Inter-ExtraLightItalic.a6566ae6.woff) format("woff")}@font-face{font-family:"Inter";font-style:normal;font-weight:300;font-display:swap;src:url(../../static/media/Inter-Light.780dd2ad.woff2) format("woff2"),url(../../static/media/Inter-Light.5d3776eb.woff) format("woff")}@font-face{font-family:"Inter";font-style:italic;font-weight:300;font-display:swap;src:url(../../static/media/Inter-LightItalic.df29c534.woff2) format("woff2"),url(../../static/media/Inter-LightItalic.d0fa7cbc.woff) format("woff")}@font-face{font-family:"Inter";font-style:normal;font-weight:400;font-display:swap;src:url(../../static/media/Inter-Regular.dc131113.woff2) format("woff2"),url(../../static/media/Inter-Regular.3ac83020.woff) format("woff")}@font-face{font-family:"Inter";font-style:italic;font-weight:400;font-display:swap;src:url(../../static/media/Inter-Italic.fd26ff23.woff2) format("woff2"),url(../../static/media/Inter-Italic.f137a90d.woff) format("woff")}@font-face{font-family:"Inter";font-style:normal;font-weight:500;font-display:swap;src:url(../../static/media/Inter-Medium.75db5319.woff2) format("woff2"),url(../../static/media/Inter-Medium.c0638bea.woff) format("woff")}@font-face{font-family:"Inter";font-style:italic;font-weight:500;font-display:swap;src:url(../../static/media/Inter-MediumItalic.f1e11535.woff2) format("woff2"),url(../../static/media/Inter-MediumItalic.a1b58862.woff) format("woff")}@font-face{font-family:"Inter";font-style:normal;font-weight:600;font-display:swap;src:url(../../static/media/Inter-SemiBold.007ad31a.woff2) format("woff2"),url(../../static/media/Inter-SemiBold.66a68ffa.woff) format("woff")}@font-face{font-family:"Inter";font-style:italic;font-weight:600;font-display:swap;src:url(../../static/media/Inter-SemiBoldItalic.3031b683.woff2) format("woff2"),url(../../static/media/Inter-SemiBoldItalic.6cd13dbd.woff) format("woff")}@font-face{font-family:"Inter";font-style:normal;font-weight:700;font-display:swap;src:url(../../static/media/Inter-Bold.444a7284.woff2) format("woff2"),url(../../static/media/Inter-Bold.99a0d9a7.woff) format("woff")}@font-face{font-family:"Inter";font-style:italic;font-weight:700;font-display:swap;src:url(../../static/media/Inter-BoldItalic.96284e2a.woff2) format("woff2"),url(../../static/media/Inter-BoldItalic.3aa31f73.woff) format("woff")}@font-face{font-family:"Inter";font-style:normal;font-weight:800;font-display:swap;src:url(../../static/media/Inter-ExtraBold.37da9eec.woff2) format("woff2"),url(../../static/media/Inter-ExtraBold.ab70688a.woff) format("woff")}@font-face{font-family:"Inter";font-style:italic;font-weight:800;font-display:swap;src:url(../../static/media/Inter-ExtraBoldItalic.fcc7d60e.woff2) format("woff2"),url(../../static/media/Inter-ExtraBoldItalic.728a4c7d.woff) format("woff")}@font-face{font-family:"Inter";font-style:normal;font-weight:900;font-display:swap;src:url(../../static/media/Inter-Black.661569af.woff2) format("woff2"),url(../../static/media/Inter-Black.d0b121f3.woff) format("woff")}@font-face{font-family:"Inter";font-style:italic;font-weight:900;font-display:swap;src:url(../../static/media/Inter-BlackItalic.a3cc36c8.woff2) format("woff2"),url(../../static/media/Inter-BlackItalic.e3329b2b.woff) format("woff")}@font-face{font-family:"Inter var";font-weight:100 900;font-style:normal;font-named-instance:"Regular";src:url(../../static/media/Inter-roman.var.66c6e408.woff2) format("woff2 supports variations(gvar)"),url(../../static/media/Inter-roman.var.66c6e408.woff2) format("woff2-variations"),url(../../static/media/Inter-roman.var.66c6e408.woff2) format("woff2")}@font-face{font-family:"Inter var";font-weight:100 900;font-style:italic;font-named-instance:"Italic";src:url(../../static/media/Inter-italic.var.1f7ca638.woff2) format("woff2 supports variations(gvar)"),url(../../static/media/Inter-italic.var.1f7ca638.woff2) format("woff2-variations"),url(../../static/media/Inter-italic.var.1f7ca638.woff2) format("woff2")}@font-face{font-family:"Inter var experimental";font-weight:100 900;font-style:oblique 0deg 10deg;src:url(../../static/media/Inter.var.8dd26c3d.woff2) format("woff2-variations"),url(../../static/media/Inter.var.8dd26c3d.woff2) format("woff2")}:root{--reach-dialog:1}[data-reach-dialog-overlay]{background:rgba(0,0,0,.33);position:fixed;top:0;right:0;bottom:0;left:0;overflow:auto}[data-reach-dialog-content]{width:50vw;margin:10vh auto;background:#fff;padding:2rem;outline:none}.rc-slider{position:relative;height:14px;padding:5px 0;width:100%;border-radius:6px;touch-action:none}.rc-slider,.rc-slider *{box-sizing:border-box;-webkit-tap-highlight-color:rgba(0,0,0,0)}.rc-slider-rail{width:100%;background-color:#e9e9e9}.rc-slider-rail,.rc-slider-track{position:absolute;height:4px;border-radius:6px}.rc-slider-track{left:0;background-color:#abe2fb}.rc-slider-handle{position:absolute;width:14px;height:14px;cursor:pointer;cursor:-webkit-grab;margin-top:-5px;cursor:grab;border-radius:50%;border:2px solid #96dbfa;background-color:#fff;touch-action:pan-x}.rc-slider-handle-dragging.rc-slider-handle-dragging.rc-slider-handle-dragging{border-color:#57c5f7;box-shadow:0 0 0 5px #96dbfa}.rc-slider-handle:focus{outline:none}.rc-slider-handle-click-focused:focus{border-color:#96dbfa;box-shadow:unset}.rc-slider-handle:hover{border-color:#57c5f7}.rc-slider-handle:active{border-color:#57c5f7;box-shadow:0 0 5px #57c5f7;cursor:grabbing}.rc-slider-mark{position:absolute;top:18px;left:0;width:100%;font-size:12px}.rc-slider-mark-text{position:absolute;display:inline-block;vertical-align:middle;text-align:center;cursor:pointer;color:#999}.rc-slider-mark-text-active{color:#666}.rc-slider-step{position:absolute;width:100%;height:4px;background:transparent}.rc-slider-dot{position:absolute;bottom:-2px;margin-left:-4px;width:8px;height:8px;border:2px solid #e9e9e9;background-color:#fff;cursor:pointer;border-radius:50%;vertical-align:middle}.rc-slider-dot-active{border-color:#96dbfa}.rc-slider-dot-reverse{margin-right:-4px}.rc-slider-disabled{background-color:#e9e9e9}.rc-slider-disabled .rc-slider-track{background-color:#ccc}.rc-slider-disabled .rc-slider-dot,.rc-slider-disabled .rc-slider-handle{border-color:#ccc;box-shadow:none;background-color:#fff;cursor:not-allowed}.rc-slider-disabled .rc-slider-dot,.rc-slider-disabled .rc-slider-mark-text{cursor:not-allowed!important}.rc-slider-vertical{width:14px;height:100%;padding:0 5px}.rc-slider-vertical .rc-slider-rail{height:100%;width:4px}.rc-slider-vertical .rc-slider-track{left:5px;bottom:0;width:4px}.rc-slider-vertical .rc-slider-handle{margin-left:-5px;touch-action:pan-y}.rc-slider-vertical .rc-slider-mark{top:0;left:18px;height:100%}.rc-slider-vertical .rc-slider-step{height:100%;width:4px}.rc-slider-vertical .rc-slider-dot{left:2px;margin-bottom:-4px}.rc-slider-vertical .rc-slider-dot:first-child,.rc-slider-vertical .rc-slider-dot:last-child{margin-bottom:-4px}.rc-slider-tooltip-zoom-down-appear,.rc-slider-tooltip-zoom-down-enter,.rc-slider-tooltip-zoom-down-leave{-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-fill-mode:both;animation-fill-mode:both;display:block!important;-webkit-animation-play-state:paused;animation-play-state:paused}.rc-slider-tooltip-zoom-down-appear.rc-slider-tooltip-zoom-down-appear-active,.rc-slider-tooltip-zoom-down-enter.rc-slider-tooltip-zoom-down-enter-active{-webkit-animation-name:rcSliderTooltipZoomDownIn;animation-name:rcSliderTooltipZoomDownIn;-webkit-animation-play-state:running;animation-play-state:running}.rc-slider-tooltip-zoom-down-leave.rc-slider-tooltip-zoom-down-leave-active{-webkit-animation-name:rcSliderTooltipZoomDownOut;animation-name:rcSliderTooltipZoomDownOut;-webkit-animation-play-state:running;animation-play-state:running}.rc-slider-tooltip-zoom-down-appear,.rc-slider-tooltip-zoom-down-enter{-webkit-transform:scale(0);transform:scale(0);-webkit-animation-timing-function:cubic-bezier(.23,1,.32,1);animation-timing-function:cubic-bezier(.23,1,.32,1)}.rc-slider-tooltip-zoom-down-leave{-webkit-animation-timing-function:cubic-bezier(.755,.05,.855,.06);animation-timing-function:cubic-bezier(.755,.05,.855,.06)}@-webkit-keyframes rcSliderTooltipZoomDownIn{0%{opacity:0;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scale(0);transform:scale(0)}to{-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scale(1);transform:scale(1)}}@keyframes rcSliderTooltipZoomDownIn{0%{opacity:0;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scale(0);transform:scale(0)}to{-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scale(1);transform:scale(1)}}@-webkit-keyframes rcSliderTooltipZoomDownOut{0%{-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scale(1);transform:scale(1)}to{opacity:0;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scale(0);transform:scale(0)}}@keyframes rcSliderTooltipZoomDownOut{0%{-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scale(1);transform:scale(1)}to{opacity:0;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scale(0);transform:scale(0)}}.rc-slider-tooltip{position:absolute;left:-9999px;top:-9999px;visibility:visible}.rc-slider-tooltip,.rc-slider-tooltip *{box-sizing:border-box;-webkit-tap-highlight-color:rgba(0,0,0,0)}.rc-slider-tooltip-hidden{display:none}.rc-slider-tooltip-placement-top{padding:4px 0 8px}.rc-slider-tooltip-inner{padding:6px 2px;min-width:24px;height:24px;font-size:12px;line-height:1;color:#fff;text-align:center;text-decoration:none;background-color:#6c6c6c;border-radius:6px;box-shadow:0 0 4px #d9d9d9}.rc-slider-tooltip-arrow{position:absolute;width:0;height:0;border-color:transparent;border-style:solid}.rc-slider-tooltip-placement-top .rc-slider-tooltip-arrow{bottom:4px;left:50%;margin-left:-4px;border-width:4px 4px 0;border-top-color:#6c6c6c} \ No newline at end of file diff --git a/static/css/main.904b2218.chunk.css b/static/css/main.c9ee16f2.chunk.css similarity index 100% rename from static/css/main.904b2218.chunk.css rename to static/css/main.c9ee16f2.chunk.css diff --git a/static/js/0.010e1646.chunk.js b/static/js/0.010e1646.chunk.js new file mode 100644 index 0000000..13a5abc --- /dev/null +++ b/static/js/0.010e1646.chunk.js @@ -0,0 +1 @@ +(this.webpackJsonpunifactory=this.webpackJsonpunifactory||[]).push([[0],{1219:function(e,r){function t(e){return e.sort((function(e,r){return"latest"===e||"earliest"===r?1:"latest"===r||"earliest"===e?-1:n(e)-n(r)}))}function n(e){return void 0===e||null===e?e:Number.parseInt(e,16)}function o(e){if(void 0===e||null===e)return e;var r=e.toString(16);return r.length%2&&(r="0"+r),"0x"+r}function i(){return Math.floor(16*Math.random()).toString(16)}e.exports={minBlockRef:function(){for(var e=arguments.length,r=new Array(e),n=0;n1?n-1:0),i=1;i0&&(u=o[0]),u instanceof Error)throw u;var c=new Error("Unhandled error.".concat(u?" (".concat(u.message,")"):""));throw c.context=u,c}var l=t[e];if(void 0===l)return!1;if("function"===typeof l)a(l,this,o);else for(var p=l.length,f=s(l),d=0;d=1e3&&e<=4999}(e))throw new Error('"code" must be an integer such that: 1000 <= code <= 4999');return r.call(this,e,o,i)}return o(t)}(c);function p(e,r){if("[Circular]"!==r)return r}r.EthereumProviderError=l},1264:function(e,r,t){"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.errorValues=r.errorCodes=void 0,r.errorCodes={rpc:{invalidInput:-32e3,resourceNotFound:-32001,resourceUnavailable:-32002,transactionRejected:-32003,methodNotSupported:-32004,limitExceeded:-32005,parse:-32700,invalidRequest:-32600,methodNotFound:-32601,invalidParams:-32602,internal:-32603},provider:{userRejectedRequest:4001,unauthorized:4100,unsupportedMethod:4200,disconnected:4900,chainDisconnected:4901}},r.errorValues={"-32700":{standard:"JSON RPC 2.0",message:"Invalid JSON was received by the server. An error occurred on the server while parsing the JSON text."},"-32600":{standard:"JSON RPC 2.0",message:"The JSON sent is not a valid Request object."},"-32601":{standard:"JSON RPC 2.0",message:"The method does not exist / is not available."},"-32602":{standard:"JSON RPC 2.0",message:"Invalid method parameter(s)."},"-32603":{standard:"JSON RPC 2.0",message:"Internal JSON-RPC error."},"-32000":{standard:"EIP-1474",message:"Invalid input."},"-32001":{standard:"EIP-1474",message:"Resource not found."},"-32002":{standard:"EIP-1474",message:"Resource unavailable."},"-32003":{standard:"EIP-1474",message:"Transaction rejected."},"-32004":{standard:"EIP-1474",message:"Method not supported."},"-32005":{standard:"EIP-1474",message:"Request limit exceeded."},4001:{standard:"EIP-1193",message:"User rejected the request."},4100:{standard:"EIP-1193",message:"The requested account and/or method has not been authorized by the user."},4200:{standard:"EIP-1193",message:"The requested method is not supported by this Ethereum provider."},4900:{standard:"EIP-1193",message:"The provider is disconnected from all chains."},4901:{standard:"EIP-1193",message:"The provider is disconnected from the specified chain."}}},1265:function(e,r,t){var n=t(2),o=t(234),i=t(86),u=t(87),a=t(290),s=t(291),c=function(e){"use strict";a(t,e);var r=s(t);function t(){var e;return i(this,t),(e=r.call(this)).updates=[],e}return u(t,[{key:"initialize",value:function(){var e=o(n.mark((function e(){return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}()},{key:"update",value:function(){var e=o(n.mark((function e(){return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:throw new Error("BaseFilter - no update method specified");case 1:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}()},{key:"addResults",value:function(e){var r=this;this.updates=this.updates.concat(e),e.forEach((function(e){return r.emit("update",e)}))}},{key:"addInitialResults",value:function(e){}},{key:"getChangesAndClear",value:function(){var e=this.updates;return this.updates=[],e}}]),t}(t(1236).default);e.exports=c},1266:function(e,r,t){var n=t(2),o=t(234);function i(){return(i=o(n.mark((function e(r){var t,o,i,c,l,p,f;return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=r.provider,o=r.fromBlock,i=r.toBlock,o||(o=i),c=u(o),l=u(i),p=Array(l-c+1).fill().map((function(e,r){return c+r})).map(a),e.next=8,Promise.all(p.map((function(e){return s(t,"eth_getBlockByNumber",[e,!1])})));case 8:return f=e.sent,e.abrupt("return",f);case 10:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function u(e){return void 0===e||null===e?e:Number.parseInt(e,16)}function a(e){return void 0===e||null===e?e:"0x"+e.toString(16)}function s(e,r,t){return new Promise((function(n,o){e.sendAsync({id:1,jsonrpc:"2.0",method:r,params:t},(function(e,r){if(e)return o(e);n(r.result)}))}))}e.exports=function(e){return i.apply(this,arguments)}},1321:function(e,r,t){var n=t(2),o=t(234),i=t(86),u=t(87),a=t(290),s=t(291),c=t(1322),l=t(1396),p=function(e){"use strict";a(t,e);var r=s(t);function t(){var e,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(i(this,t),!n.provider)throw new Error("PollingBlockTracker - no provider specified.");var o=n.pollingInterval||2e4,u=n.retryTimeout||o/10,a=void 0===n.keepEventLoopActive||n.keepEventLoopActive,s=n.setSkipCacheFlag||!1;return(e=r.call(this,Object.assign({blockResetDuration:o},n)))._provider=n.provider,e._pollingInterval=o,e._retryTimeout=u,e._keepEventLoopActive=a,e._setSkipCacheFlag=s,e}return u(t,[{key:"checkForLatestBlock",value:function(){var e=o(n.mark((function e(){return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._updateLatestBlock();case 2:return e.next=4,this.getLatestBlock();case 4:return e.abrupt("return",e.sent);case 5:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"_start",value:function(){var e=this;this._performSync().catch((function(r){return e.emit("error",r)}))}},{key:"_performSync",value:function(){var e=o(n.mark((function e(){var r;return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!this._isRunning){e.next=16;break}return e.prev=1,e.next=4,this._updateLatestBlock();case 4:return e.next=6,f(this._pollingInterval,!this._keepEventLoopActive);case 6:e.next=14;break;case 8:e.prev=8,e.t0=e.catch(1),r=new Error("PollingBlockTracker - encountered an error while attempting to update latest block:\n".concat(e.t0.stack));try{this.emit("error",r)}catch(t){console.error(r)}return e.next=14,f(this._retryTimeout,!this._keepEventLoopActive);case 14:e.next=0;break;case 16:case"end":return e.stop()}}),e,this,[[1,8]])})));return function(){return e.apply(this,arguments)}}()},{key:"_updateLatestBlock",value:function(){var e=o(n.mark((function e(){var r;return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._fetchLatestBlock();case 2:r=e.sent,this._newPotentialLatest(r);case 4:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"_fetchLatestBlock",value:function(){var e=o(n.mark((function e(){var r,t,o=this;return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r={jsonrpc:"2.0",id:1,method:"eth_blockNumber",params:[]},this._setSkipCacheFlag&&(r.skipCache=!0),e.next=4,c((function(e){return o._provider.sendAsync(r,e)}))();case 4:if(!(t=e.sent).error){e.next=7;break}throw new Error("PollingBlockTracker - encountered error fetching block:\n".concat(t.error));case 7:return e.abrupt("return",t.result);case 8:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()}]),t}(l);function f(e,r){return new Promise((function(t){var n=setTimeout(t,e);n.unref&&r&&n.unref()}))}e.exports=p},1322:function(e,r,t){"use strict";var n=function(e,r){return function(){for(var t=this,n=r.promiseModule,o=new Array(arguments.length),i=0;i0?r.on("sync",b):t>0&&0===n&&r.removeListener("sync",b)}}},1332:function(e,r,t){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,r,t,n){void 0===n&&(n=t),Object.defineProperty(e,n,{enumerable:!0,get:function(){return r[t]}})}:function(e,r,t,n){void 0===n&&(n=t),e[n]=r[t]}),o=this&&this.__exportStar||function(e,r){for(var t in e)"default"===t||Object.prototype.hasOwnProperty.call(r,t)||n(r,e,t)};Object.defineProperty(r,"__esModule",{value:!0}),o(t(1423),r),o(t(1424),r),o(t(1425),r),o(t(1333),r),o(t(1334),r),o(t(1429),r)},1333:function(e,r,t){"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getUniqueId=void 0;var n=Math.floor(4294967295*Math.random());r.getUniqueId=function(){return n=(n+1)%4294967295}},1334:function(e,r,t){"use strict";var n=t(100),o=t(2),i=t(116),u=t(234),a=t(86),s=t(87),c=t(290),l=t(291),p=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(r,"__esModule",{value:!0}),r.JsonRpcEngine=void 0;var f=p(t(1236)),d=t(1426),h=function(e){c(t,e);var r=l(t);function t(){var e;return a(this,t),(e=r.call(this))._middleware=[],e}return s(t,[{key:"push",value:function(e){this._middleware.push(e)}},{key:"handle",value:function(e,r){if(r&&"function"!==typeof r)throw new Error('"callback" must be a function if provided.');return Array.isArray(e)?r?this._handleBatch(e,r):this._handleBatch(e):r?this._handle(e,r):this._promiseHandle(e)}},{key:"asMiddleware",value:function(){var e=this;return function(){var r=u(o.mark((function r(n,a,s,c){var l,p,f,d,h;return o.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.prev=0,r.next=3,t._runAllMiddleware(n,a,e._middleware);case 3:if(l=r.sent,p=i(l,3),f=p[0],d=p[1],h=p[2],!d){r.next=12;break}return r.next=11,t._runReturnHandlers(h);case 11:return r.abrupt("return",c(f));case 12:return r.abrupt("return",s(function(){var e=u(o.mark((function e(r){return o.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,t._runReturnHandlers(h);case 3:e.next=8;break;case 5:return e.prev=5,e.t0=e.catch(0),e.abrupt("return",r(e.t0));case 8:return e.abrupt("return",r());case 9:case"end":return e.stop()}}),e,null,[[0,5]])})));return function(r){return e.apply(this,arguments)}}()));case 15:return r.prev=15,r.t0=r.catch(0),r.abrupt("return",c(r.t0));case 18:case"end":return r.stop()}}),r,null,[[0,15]])})));return function(e,t,n,o){return r.apply(this,arguments)}}()}},{key:"_handleBatch",value:function(){var e=u(o.mark((function e(r,t){var n;return o.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,Promise.all(r.map(this._promiseHandle.bind(this)));case 3:if(n=e.sent,!t){e.next=6;break}return e.abrupt("return",t(null,n));case 6:return e.abrupt("return",n);case 9:if(e.prev=9,e.t0=e.catch(0),!t){e.next=13;break}return e.abrupt("return",t(e.t0));case 13:throw e.t0;case 14:case"end":return e.stop()}}),e,this,[[0,9]])})));return function(r,t){return e.apply(this,arguments)}}()},{key:"_promiseHandle",value:function(e){var r=this;return new Promise((function(t){r._handle(e,(function(e,r){t(r)}))}))}},{key:"_handle",value:function(){var e=u(o.mark((function e(r,t){var n,i,u,a,s;return o.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(r&&!Array.isArray(r)&&"object"===typeof r){e.next=3;break}return n=new d.EthereumRpcError(d.errorCodes.rpc.invalidRequest,"Requests must be plain objects. Received: ".concat(typeof r),{request:r}),e.abrupt("return",t(n,{id:void 0,jsonrpc:"2.0",error:n}));case 3:if("string"===typeof r.method){e.next=6;break}return i=new d.EthereumRpcError(d.errorCodes.rpc.invalidRequest,"Must specify a string method. Received: ".concat(typeof r.method),{request:r}),e.abrupt("return",t(i,{id:r.id,jsonrpc:"2.0",error:i}));case 6:return u=Object.assign({},r),a={id:u.id,jsonrpc:u.jsonrpc},s=null,e.prev=9,e.next=12,this._processRequest(u,a);case 12:e.next=17;break;case 14:e.prev=14,e.t0=e.catch(9),s=e.t0;case 17:return s&&(delete a.result,a.error||(a.error=d.serializeError(s))),e.abrupt("return",t(s,a));case 19:case"end":return e.stop()}}),e,this,[[9,14]])})));return function(r,t){return e.apply(this,arguments)}}()},{key:"_processRequest",value:function(){var e=u(o.mark((function e(r,n){var u,a,s,c,l;return o.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t._runAllMiddleware(r,n,this._middleware);case 2:return u=e.sent,a=i(u,3),s=a[0],c=a[1],l=a[2],t._checkForCompletion(r,n,c),e.next=10,t._runReturnHandlers(l);case 10:if(!s){e.next=12;break}throw s;case 12:case"end":return e.stop()}}),e,this)})));return function(r,t){return e.apply(this,arguments)}}()}],[{key:"_runAllMiddleware",value:function(){var e=u(o.mark((function e(r,u,a){var s,c,l,p,f,d,h,v;return o.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:s=[],c=null,l=!1,p=n(a),e.prev=4,p.s();case 6:if((f=p.n()).done){e.next=18;break}return d=f.value,e.next=10,t._runMiddleware(r,u,d,s);case 10:if(h=e.sent,v=i(h,2),c=v[0],!(l=v[1])){e.next=16;break}return e.abrupt("break",18);case 16:e.next=6;break;case 18:e.next=23;break;case 20:e.prev=20,e.t0=e.catch(4),p.e(e.t0);case 23:return e.prev=23,p.f(),e.finish(23);case 26:return e.abrupt("return",[c,l,s.reverse()]);case 27:case"end":return e.stop()}}),e,null,[[4,20,23,26]])})));return function(r,t,n){return e.apply(this,arguments)}}()},{key:"_runMiddleware",value:function(e,r,t,n){return new Promise((function(o){var i=function(e){var t=e||r.error;t&&(r.error=d.serializeError(t)),o([t,!0])};try{t(e,r,(function(t){r.error?i(r.error):(t&&("function"!==typeof t&&i(new d.EthereumRpcError(d.errorCodes.rpc.internal,'JsonRpcEngine: "next" return handlers must be functions. '+'Received "'.concat(typeof t,'" for request:\n').concat(v(e)),{request:e})),n.push(t)),o([null,!1]))}),i)}catch(u){i(u)}}))}},{key:"_runReturnHandlers",value:function(){var e=u(o.mark((function e(r){var t,i,u;return o.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:t=n(r),e.prev=1,u=o.mark((function e(){var r;return o.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=i.value,e.next=3,new Promise((function(e,t){r((function(r){return r?t(r):e()}))}));case 3:case"end":return e.stop()}}),e)})),t.s();case 4:if((i=t.n()).done){e.next=8;break}return e.delegateYield(u(),"t0",6);case 6:e.next=4;break;case 8:e.next=13;break;case 10:e.prev=10,e.t1=e.catch(1),t.e(e.t1);case 13:return e.prev=13,t.f(),e.finish(13);case 16:case"end":return e.stop()}}),e,null,[[1,10,13,16]])})));return function(r){return e.apply(this,arguments)}}()},{key:"_checkForCompletion",value:function(e,r,t){if(!("result"in r)&&!("error"in r))throw new d.EthereumRpcError(d.errorCodes.rpc.internal,"JsonRpcEngine: Response has no error or result for request:\n".concat(v(e)),{request:e});if(!t)throw new d.EthereumRpcError(d.errorCodes.rpc.internal,"JsonRpcEngine: Nothing ended request:\n".concat(v(e)),{request:e})}}]),t}(f.default);function v(e){return JSON.stringify(e,null,2)}r.JsonRpcEngine=h},1335:function(e,r,t){var n=t(575),o=t(385),i=t(1427),u=t(581);function a(r){var t="function"===typeof Map?new Map:void 0;return e.exports=a=function(e){if(null===e||!i(e))return e;if("function"!==typeof e)throw new TypeError("Super expression must either be null or a function");if("undefined"!==typeof t){if(t.has(e))return t.get(e);t.set(e,r)}function r(){return u(e,arguments,n(this).constructor)}return r.prototype=Object.create(e.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}),o(r,e)},a(r)}e.exports=a},1336:function(e,r){e.exports=i,i.default=i,i.stable=s,i.stableStringify=s;var t=[],n=[];function o(){return{depthLimit:Number.MAX_SAFE_INTEGER,edgesLimit:Number.MAX_SAFE_INTEGER}}function i(e,r,i,a){var s;"undefined"===typeof a&&(a=o()),function e(r,t,n,o,i,a,s){var c;if(a+=1,"object"===typeof r&&null!==r){for(c=0;cs.depthLimit)return void u("[...]",r,t,i);if("undefined"!==typeof s.edgesLimit&&n+1>s.edgesLimit)return void u("[...]",r,t,i);if(o.push(r),Array.isArray(r))for(c=0;cr?1:0}function s(e,r,i,s){"undefined"===typeof s&&(s=o());var l,p=function e(r,n,o,i,s,c,l){var p;if(c+=1,"object"===typeof r&&null!==r){for(p=0;pl.depthLimit)return void u("[...]",r,n,s);if("undefined"!==typeof l.edgesLimit&&o+1>l.edgesLimit)return void u("[...]",r,n,s);if(i.push(r),Array.isArray(r))for(p=0;p0)for(var o=0;o1&&void 0!==arguments[1]?arguments[1]:u;if(Number.isInteger(e)){var o=e.toString();if(f(n.errorValues,o))return n.errorValues[o].message;if(l(e))return r.JSON_RPC_SERVER_ERROR_MESSAGE}return t}function c(e){if(!Number.isInteger(e))return!1;var r=e.toString();return!!n.errorValues[r]||!!l(e)}function l(e){return e>=-32099&&e<=-32e3}function p(e){return e&&"object"===typeof e&&!Array.isArray(e)?Object.assign({},e):e}function f(e,r){return Object.prototype.hasOwnProperty.call(e,r)}r.JSON_RPC_SERVER_ERROR_MESSAGE="Unspecified server error.",r.getMessageFromCode=s,r.isValidCode=c,r.serializeError=function(e){var r,t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=n.fallbackError,u=void 0===i?a:i,l=n.shouldIncludeStack,d=void 0!==l&&l;if(!u||!Number.isInteger(u.code)||"string"!==typeof u.message)throw new Error("Must provide fallback error with integer number code and string message.");if(e instanceof o.EthereumRpcError)return e.serialize();var h={};if(e&&"object"===typeof e&&!Array.isArray(e)&&f(e,"code")&&c(e.code)){var v=e;h.code=v.code,v.message&&"string"===typeof v.message?(h.message=v.message,f(v,"data")&&(h.data=v.data)):(h.message=s(h.code),h.data={originalError:p(e)})}else{h.code=u.code;var y=null===(r=e)||void 0===r?void 0:r.message;h.message=y&&"string"===typeof y?y:u.message,h.data={originalError:p(e)}}var m=null===(t=e)||void 0===t?void 0:t.stack;return d&&e&&m&&"string"===typeof m&&(h.stack=m),h}},1338:function(e,r,t){e.exports=t(1430)},1339:function(e,r,t){var n=t(2),o=t(234),i=t(1236).default,u=t(1338),a=t(1332).createAsyncMiddleware,s=t(1331),c=t(1219),l=c.unsafeRandomBytes,p=c.incrementHexInt,f=t(1266);function d(e){return{hash:e.hash,parentHash:e.parentHash,sha3Uncles:e.sha3Uncles,miner:e.miner,stateRoot:e.stateRoot,transactionsRoot:e.transactionsRoot,receiptsRoot:e.receiptsRoot,logsBloom:e.logsBloom,difficulty:e.difficulty,number:e.number,gasLimit:e.gasLimit,gasUsed:e.gasUsed,nonce:e.nonce,mixHash:e.mixHash,timestamp:e.timestamp,extraData:e.extraData}}e.exports=function(e){var r=e.blockTracker,t=e.provider,c={},h=s({blockTracker:r,provider:t}),v=!1,y=new i,m=u({eth_subscribe:a((function(e,r){return g.apply(this,arguments)})),eth_unsubscribe:a((function(e,r){return k.apply(this,arguments)}))});return m.destroy=function(){for(var e in y.removeAllListeners(),c)c[e].destroy(),delete c[e];v=!0},{events:y,middleware:m};function g(){return(g=o(n.mark((function e(i,u){var a,s,y,m,g,k,w;return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(w=function(e){var r=e.subId,t=e.filter;return t.on("update",(function(e){return b(r,e)})),{type:a,destroy:function(){var e=o(n.mark((function e(){return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,h.uninstallFilter(t.idHex);case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}()}},k=function(e){var i=e.subId,u={type:a,destroy:function(){var e=o(n.mark((function e(){return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:r.removeListener("sync",u.update);case 1:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),update:function(){var e=o(n.mark((function e(r){var o,u,a,s,c;return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return o=r.oldBlock,u=r.newBlock,a=u,s=p(o),e.next=5,f({provider:t,fromBlock:s,toBlock:a});case 5:c=e.sent,c.map(d).forEach((function(e){b(i,e)}));case 8:case"end":return e.stop()}}),e)})));return function(r){return e.apply(this,arguments)}}()};return r.on("sync",u.update),u},!v){e.next=4;break}throw new Error("SubscriptionManager - attempting to use after destroying");case 4:a=i.params[0],s=l(16),e.t0=a,e.next="newHeads"===e.t0?9:"logs"===e.t0?11:17;break;case 9:return y=k({subId:s}),e.abrupt("break",18);case 11:return m=i.params[1],e.next=14,h.newLogFilter(m);case 14:return g=e.sent,y=w({subId:s,filter:g}),e.abrupt("break",18);case 17:throw new Error('SubscriptionManager - unsupported subscription type "'.concat(a,'"'));case 18:return c[s]=y,u.result=s,e.abrupt("return");case 21:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function k(){return(k=o(n.mark((function e(r,t){var o,i;return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!v){e.next=2;break}throw new Error("SubscriptionManager - attempting to use after destroying");case 2:if(o=r.params[0],i=c[o]){e.next=7;break}return t.result=!1,e.abrupt("return");case 7:return delete c[o],e.next=10,i.destroy();case 10:t.result=!0;case 11:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function b(e,r){y.emit("notification",{jsonrpc:"2.0",method:"eth_subscription",params:{subscription:e,result:r}})}}},1396:function(e,r,t){var n=t(2),o=t(234),i=t(86),u=t(87),a=t(383),s=t(1323),c=t(575),l=t(290),p=t(291),f=(t(1324),t(1322),t(1399)),d=function(e,r){return e+r},h=["sync","latest"],v=function(e){"use strict";l(t,e);var r=p(t);function t(){var e,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return i(this,t),(e=r.call(this))._blockResetDuration=n.blockResetDuration||2e4,e._blockResetTimeout,e._currentBlock=null,e._isRunning=!1,e._onNewListener=e._onNewListener.bind(a(e)),e._onRemoveListener=e._onRemoveListener.bind(a(e)),e._resetCurrentBlock=e._resetCurrentBlock.bind(a(e)),e._setupInternalEvents(),e}return u(t,[{key:"isRunning",value:function(){return this._isRunning}},{key:"getCurrentBlock",value:function(){return this._currentBlock}},{key:"getLatestBlock",value:function(){var e=o(n.mark((function e(){var r,t=this;return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!this._currentBlock){e.next=2;break}return e.abrupt("return",this._currentBlock);case 2:return e.next=4,new Promise((function(e){return t.once("latest",e)}));case 4:return r=e.sent,e.abrupt("return",r);case 6:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"removeAllListeners",value:function(e){e?s(c(t.prototype),"removeAllListeners",this).call(this,e):s(c(t.prototype),"removeAllListeners",this).call(this),this._setupInternalEvents(),this._onRemoveListener()}},{key:"_start",value:function(){}},{key:"_end",value:function(){}},{key:"_setupInternalEvents",value:function(){this.removeListener("newListener",this._onNewListener),this.removeListener("removeListener",this._onRemoveListener),this.on("newListener",this._onNewListener),this.on("removeListener",this._onRemoveListener)}},{key:"_onNewListener",value:function(e,r){h.includes(e)&&this._maybeStart()}},{key:"_onRemoveListener",value:function(e,r){this._getBlockTrackerEventCount()>0||this._maybeEnd()}},{key:"_maybeStart",value:function(){this._isRunning||(this._isRunning=!0,this._cancelBlockResetTimeout(),this._start())}},{key:"_maybeEnd",value:function(){this._isRunning&&(this._isRunning=!1,this._setupBlockResetTimeout(),this._end())}},{key:"_getBlockTrackerEventCount",value:function(){var e=this;return h.map((function(r){return e.listenerCount(r)})).reduce(d)}},{key:"_newPotentialLatest",value:function(e){var r=this._currentBlock;r&&y(e)<=y(r)||this._setCurrentBlock(e)}},{key:"_setCurrentBlock",value:function(e){var r=this._currentBlock;this._currentBlock=e,this.emit("latest",e),this.emit("sync",{oldBlock:r,newBlock:e})}},{key:"_setupBlockResetTimeout",value:function(){this._cancelBlockResetTimeout(),this._blockResetTimeout=setTimeout(this._resetCurrentBlock,this._blockResetDuration),this._blockResetTimeout.unref&&this._blockResetTimeout.unref()}},{key:"_cancelBlockResetTimeout",value:function(){clearTimeout(this._blockResetTimeout)}},{key:"_resetCurrentBlock",value:function(){this._currentBlock=null}}]),t}(f);function y(e){return Number.parseInt(e,16)}e.exports=v},1397:function(e,r,t){var n=t(575);e.exports=function(e,r){for(;!Object.prototype.hasOwnProperty.call(e,r)&&null!==(e=n(e)););return e}},1398:function(e,r){e.exports=function(e){var r=(e=e||{}).max||Number.MAX_SAFE_INTEGER,t="undefined"!==typeof e.start?e.start:Math.floor(Math.random()*r);return function(){return t%=r,t++}}},1399:function(e,r,t){var n=t(380),o=t(90),i="object"===typeof Reflect?Reflect:null,u=i&&"function"===typeof i.apply?i.apply:function(e,r,t){return Function.prototype.apply.call(e,r,t)};function a(){o.call(this)}function s(e,r,t){try{u(e,r,t)}catch(n){setTimeout((function(){throw n}))}}function c(e,r){for(var t=new Array(r),n=0;n0&&(i=r[0]),i instanceof Error)throw i;var u=new Error("Unhandled error."+(i?" ("+i.message+")":""));throw u.context=i,u}var a=o[e];if(void 0===a)return!1;if("function"===typeof a)s(a,this,r);else{var l=a.length,p=c(a,l);for(t=0;t-32005||r<-32099)throw new Error('"code" must be an integer such that: -32099 <= code <= -32005');return a(r,e)},invalidInput:function(e){return a(u.errorCodes.rpc.invalidInput,e)},resourceNotFound:function(e){return a(u.errorCodes.rpc.resourceNotFound,e)},resourceUnavailable:function(e){return a(u.errorCodes.rpc.resourceUnavailable,e)},transactionRejected:function(e){return a(u.errorCodes.rpc.transactionRejected,e)},methodNotSupported:function(e){return a(u.errorCodes.rpc.methodNotSupported,e)},limitExceeded:function(e){return a(u.errorCodes.rpc.limitExceeded,e)}},provider:{userRejectedRequest:function(e){return s(u.errorCodes.provider.userRejectedRequest,e)},unauthorized:function(e){return s(u.errorCodes.provider.unauthorized,e)},unsupportedMethod:function(e){return s(u.errorCodes.provider.unsupportedMethod,e)},disconnected:function(e){return s(u.errorCodes.provider.disconnected,e)},chainDisconnected:function(e){return s(u.errorCodes.provider.chainDisconnected,e)},custom:function(e){if(!e||"object"!==typeof e||Array.isArray(e))throw new Error("Ethereum Provider custom errors must provide single object argument.");var r=e.code,t=e.message,n=e.data;if(!t||"string"!==typeof t)throw new Error('"message" must be a nonempty string');return new o.EthereumProviderError(r,t,n)}}}},1429:function(e,r,t){"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.mergeMiddleware=void 0;var n=t(1334);r.mergeMiddleware=function(e){var r=new n.JsonRpcEngine;return e.forEach((function(e){return r.push(e)})),r.asMiddleware()}},1430:function(e,r){e.exports=function(e){return function(r,t,n,o){var i=e[r.method];return void 0===i?n():"function"===typeof i?i(r,t,n,o):(t.result=i,o())}}},1431:function(e,r,t){var n=t(2),o=t(234),i=t(86),u=t(87),a=t(290),s=t(291),c=t(1324),l=t(1432),p=t(1433),f=t(1219),d=(f.bnToHex,f.hexToInt),h=f.incrementHexInt,v=f.minBlockRef,y=f.blockRefIsNumber,m=function(e){"use strict";a(t,e);var r=s(t);function t(e){var n,o=e.provider,u=e.params;return i(this,t),(n=r.call(this)).type="log",n.ethQuery=new c(o),n.params=Object.assign({fromBlock:"latest",toBlock:"latest",address:void 0,topics:[]},u),n.params.address&&(Array.isArray(n.params.address)||(n.params.address=[n.params.address]),n.params.address=n.params.address.map((function(e){return e.toLowerCase()}))),n}return u(t,[{key:"initialize",value:function(){var e=o(n.mark((function e(r){var t,o,i,u,a;return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=r.currentBlock,o=this.params.fromBlock,["latest","pending"].includes(o)&&(o=t),"earliest"===o&&(o="0x0"),this.params.fromBlock=o,i=v(this.params.toBlock,t),u=Object.assign({},this.params,{toBlock:i}),e.next=9,this._fetchLogs(u);case 9:a=e.sent,this.addInitialResults(a);case 11:case"end":return e.stop()}}),e,this)})));return function(r){return e.apply(this,arguments)}}()},{key:"update",value:function(){var e=o(n.mark((function e(r){var t,o,i,u,a,s,c,l=this;return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=r.oldBlock,o=r.newBlock,i=o,u=t?h(t):o,a=Object.assign({},this.params,{fromBlock:u,toBlock:i}),e.next=6,this._fetchLogs(a);case 6:s=e.sent,c=s.filter((function(e){return l.matchLog(e)})),this.addResults(c);case 9:case"end":return e.stop()}}),e,this)})));return function(r){return e.apply(this,arguments)}}()},{key:"_fetchLogs",value:function(){var e=o(n.mark((function e(r){var t,o=this;return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,l((function(e){return o.ethQuery.getLogs(r,e)}))();case 2:return t=e.sent,e.abrupt("return",t);case 4:case"end":return e.stop()}}),e)})));return function(r){return e.apply(this,arguments)}}()},{key:"matchLog",value:function(e){if(d(this.params.fromBlock)>=d(e.blockNumber))return!1;if(y(this.params.toBlock)&&d(this.params.toBlock)<=d(e.blockNumber))return!1;var r=e.address&&e.address.toLowerCase();return!(this.params.address&&r&&!this.params.address.includes(r))&&this.params.topics.every((function(r,t){var n=e.topics[t];if(!n)return!1;n=n.toLowerCase();var o=Array.isArray(r)?r:[r];return!!o.includes(null)||(o=o.map((function(e){return e.toLowerCase()}))).includes(n)}))}}]),t}(p);e.exports=m},1432:function(e,r,t){"use strict";var n=t(130),o=function(e,r,t,n){return function(){for(var o=this,i=arguments.length,u=new Array(i),a=0;a0&&o[o.length-1])&&(6===i[0]||2===i[0])){u=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]1)throw new Error("this method is unavailabel on semaphores with concurrency > 1; use the scoped release returned by acquire instead");if(this._currentReleaser){var e=this._currentReleaser;this._currentReleaser=void 0,e()}},e.prototype._dispatch=function(){var e=this,r=this._queue.shift();if(r){var t=!1;this._currentReleaser=function(){t||(t=!0,e._value++,e._dispatch())},r([this._value--,this._currentReleaser])}},e}(),u=function(){function e(){this._semaphore=new i(1)}return e.prototype.acquire=function(){return n(this,void 0,void 0,(function(){var e;return o(this,(function(r){switch(r.label){case 0:return[4,this._semaphore.acquire()];case 1:return e=r.sent(),[2,e[1]]}}))}))},e.prototype.runExclusive=function(e){return this._semaphore.runExclusive((function(){return e()}))},e.prototype.isLocked=function(){return this._semaphore.isLocked()},e.prototype.release=function(){this._semaphore.release()},e}();function a(e,r,t){var i=this;return void 0===t&&(t=new Error("timeout")),{acquire:function(){return new Promise((function(u,a){return n(i,void 0,void 0,(function(){var n,i;return o(this,(function(o){switch(o.label){case 0:return n=!1,setTimeout((function(){n=!0,a(t)}),r),[4,e.acquire()];case 1:return i=o.sent(),n?(Array.isArray(i)?i[1]:i)():u(i),[2]}}))}))}))},runExclusive:function(e){return n(this,void 0,void 0,(function(){var r,t;return o(this,(function(n){switch(n.label){case 0:r=function(){},n.label=1;case 1:return n.trys.push([1,,7,8]),[4,this.acquire()];case 2:return t=n.sent(),Array.isArray(t)?(r=t[1],[4,e(t[0])]):[3,4];case 3:return[2,n.sent()];case 4:return r=t,[4,e()];case 5:return[2,n.sent()];case 6:return[3,8];case 7:return r(),[7];case 8:return[2]}}))}))},release:function(){e.release()},isLocked:function(){return e.isLocked()}}}}}]); \ No newline at end of file diff --git a/static/js/0.0c8959de.chunk.js b/static/js/0.0c8959de.chunk.js deleted file mode 100644 index bd9f457..0000000 --- a/static/js/0.0c8959de.chunk.js +++ /dev/null @@ -1 +0,0 @@ -(this.webpackJsonpunifactory=this.webpackJsonpunifactory||[]).push([[0],{1229:function(e,r){function t(e){return e.sort((function(e,r){return"latest"===e||"earliest"===r?1:"latest"===r||"earliest"===e?-1:n(e)-n(r)}))}function n(e){return void 0===e||null===e?e:Number.parseInt(e,16)}function o(e){if(void 0===e||null===e)return e;var r=e.toString(16);return r.length%2&&(r="0"+r),"0x"+r}function i(){return Math.floor(16*Math.random()).toString(16)}e.exports={minBlockRef:function(){for(var e=arguments.length,r=new Array(e),n=0;n1?n-1:0),i=1;i0&&(a=o[0]),a instanceof Error)throw a;var c=new Error("Unhandled error.".concat(a?" (".concat(a.message,")"):""));throw c.context=a,c}var p=t[e];if(void 0===p)return!1;if("function"===typeof p)u(p,this,o);else for(var l=p.length,f=s(p),d=0;d=1e3&&e<=4999}(e))throw new Error('"code" must be an integer such that: 1000 <= code <= 4999');return r.call(this,e,o,i)}return o(t)}(c);function l(e,r){if("[Circular]"!==r)return r}r.EthereumProviderError=p},1277:function(e,r,t){"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.errorValues=r.errorCodes=void 0,r.errorCodes={rpc:{invalidInput:-32e3,resourceNotFound:-32001,resourceUnavailable:-32002,transactionRejected:-32003,methodNotSupported:-32004,limitExceeded:-32005,parse:-32700,invalidRequest:-32600,methodNotFound:-32601,invalidParams:-32602,internal:-32603},provider:{userRejectedRequest:4001,unauthorized:4100,unsupportedMethod:4200,disconnected:4900,chainDisconnected:4901}},r.errorValues={"-32700":{standard:"JSON RPC 2.0",message:"Invalid JSON was received by the server. An error occurred on the server while parsing the JSON text."},"-32600":{standard:"JSON RPC 2.0",message:"The JSON sent is not a valid Request object."},"-32601":{standard:"JSON RPC 2.0",message:"The method does not exist / is not available."},"-32602":{standard:"JSON RPC 2.0",message:"Invalid method parameter(s)."},"-32603":{standard:"JSON RPC 2.0",message:"Internal JSON-RPC error."},"-32000":{standard:"EIP-1474",message:"Invalid input."},"-32001":{standard:"EIP-1474",message:"Resource not found."},"-32002":{standard:"EIP-1474",message:"Resource unavailable."},"-32003":{standard:"EIP-1474",message:"Transaction rejected."},"-32004":{standard:"EIP-1474",message:"Method not supported."},"-32005":{standard:"EIP-1474",message:"Request limit exceeded."},4001:{standard:"EIP-1193",message:"User rejected the request."},4100:{standard:"EIP-1193",message:"The requested account and/or method has not been authorized by the user."},4200:{standard:"EIP-1193",message:"The requested method is not supported by this Ethereum provider."},4900:{standard:"EIP-1193",message:"The provider is disconnected from all chains."},4901:{standard:"EIP-1193",message:"The provider is disconnected from the specified chain."}}},1278:function(e,r,t){var n=t(2),o=t(235),i=t(87),a=t(88),u=t(292),s=t(293),c=function(e){"use strict";u(t,e);var r=s(t);function t(){var e;return i(this,t),(e=r.call(this)).updates=[],e}return a(t,[{key:"initialize",value:function(){var e=o(n.mark((function e(){return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}()},{key:"update",value:function(){var e=o(n.mark((function e(){return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:throw new Error("BaseFilter - no update method specified");case 1:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}()},{key:"addResults",value:function(e){var r=this;this.updates=this.updates.concat(e),e.forEach((function(e){return r.emit("update",e)}))}},{key:"addInitialResults",value:function(e){}},{key:"getChangesAndClear",value:function(){var e=this.updates;return this.updates=[],e}}]),t}(t(1246).default);e.exports=c},1279:function(e,r,t){var n=t(2),o=t(235);function i(){return(i=o(n.mark((function e(r){var t,o,i,c,p,l,f;return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=r.provider,o=r.fromBlock,i=r.toBlock,o||(o=i),c=a(o),p=a(i),l=Array(p-c+1).fill().map((function(e,r){return c+r})).map(u),e.next=8,Promise.all(l.map((function(e){return s(t,"eth_getBlockByNumber",[e,!1])})));case 8:return f=e.sent,e.abrupt("return",f);case 10:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function a(e){return void 0===e||null===e?e:Number.parseInt(e,16)}function u(e){return void 0===e||null===e?e:"0x"+e.toString(16)}function s(e,r,t){return new Promise((function(n,o){e.sendAsync({id:1,jsonrpc:"2.0",method:r,params:t},(function(e,r){if(e)return o(e);n(r.result)}))}))}e.exports=function(e){return i.apply(this,arguments)}},1334:function(e,r,t){var n=t(382),o=t(91),i="object"===typeof Reflect?Reflect:null,a=i&&"function"===typeof i.apply?i.apply:function(e,r,t){return Function.prototype.apply.call(e,r,t)};function u(){o.call(this)}function s(e,r,t){try{a(e,r,t)}catch(n){setTimeout((function(){throw n}))}}function c(e,r){for(var t=new Array(r),n=0;n0&&(i=r[0]),i instanceof Error)throw i;var a=new Error("Unhandled error."+(i?" ("+i.message+")":""));throw a.context=i,a}var u=o[e];if(void 0===u)return!1;if("function"===typeof u)s(u,this,r);else{var p=u.length,l=c(u,p);for(t=0;t0?r.on("sync",b):t>0&&0===n&&r.removeListener("sync",b)}}},1342:function(e,r,t){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,r,t,n){void 0===n&&(n=t),Object.defineProperty(e,n,{enumerable:!0,get:function(){return r[t]}})}:function(e,r,t,n){void 0===n&&(n=t),e[n]=r[t]}),o=this&&this.__exportStar||function(e,r){for(var t in e)"default"===t||Object.prototype.hasOwnProperty.call(r,t)||n(r,e,t)};Object.defineProperty(r,"__esModule",{value:!0}),o(t(1431),r),o(t(1432),r),o(t(1433),r),o(t(1343),r),o(t(1344),r),o(t(1437),r)},1343:function(e,r,t){"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getUniqueId=void 0;var n=Math.floor(4294967295*Math.random());r.getUniqueId=function(){return n=(n+1)%4294967295}},1344:function(e,r,t){"use strict";var n=t(101),o=t(2),i=t(117),a=t(235),u=t(87),s=t(88),c=t(292),p=t(293),l=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(r,"__esModule",{value:!0}),r.JsonRpcEngine=void 0;var f=l(t(1246)),d=t(1434),h=function(e){c(t,e);var r=p(t);function t(){var e;return u(this,t),(e=r.call(this))._middleware=[],e}return s(t,[{key:"push",value:function(e){this._middleware.push(e)}},{key:"handle",value:function(e,r){if(r&&"function"!==typeof r)throw new Error('"callback" must be a function if provided.');return Array.isArray(e)?r?this._handleBatch(e,r):this._handleBatch(e):r?this._handle(e,r):this._promiseHandle(e)}},{key:"asMiddleware",value:function(){var e=this;return function(){var r=a(o.mark((function r(n,u,s,c){var p,l,f,d,h;return o.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.prev=0,r.next=3,t._runAllMiddleware(n,u,e._middleware);case 3:if(p=r.sent,l=i(p,3),f=l[0],d=l[1],h=l[2],!d){r.next=12;break}return r.next=11,t._runReturnHandlers(h);case 11:return r.abrupt("return",c(f));case 12:return r.abrupt("return",s(function(){var e=a(o.mark((function e(r){return o.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,t._runReturnHandlers(h);case 3:e.next=8;break;case 5:return e.prev=5,e.t0=e.catch(0),e.abrupt("return",r(e.t0));case 8:return e.abrupt("return",r());case 9:case"end":return e.stop()}}),e,null,[[0,5]])})));return function(r){return e.apply(this,arguments)}}()));case 15:return r.prev=15,r.t0=r.catch(0),r.abrupt("return",c(r.t0));case 18:case"end":return r.stop()}}),r,null,[[0,15]])})));return function(e,t,n,o){return r.apply(this,arguments)}}()}},{key:"_handleBatch",value:function(){var e=a(o.mark((function e(r,t){var n;return o.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,Promise.all(r.map(this._promiseHandle.bind(this)));case 3:if(n=e.sent,!t){e.next=6;break}return e.abrupt("return",t(null,n));case 6:return e.abrupt("return",n);case 9:if(e.prev=9,e.t0=e.catch(0),!t){e.next=13;break}return e.abrupt("return",t(e.t0));case 13:throw e.t0;case 14:case"end":return e.stop()}}),e,this,[[0,9]])})));return function(r,t){return e.apply(this,arguments)}}()},{key:"_promiseHandle",value:function(e){var r=this;return new Promise((function(t){r._handle(e,(function(e,r){t(r)}))}))}},{key:"_handle",value:function(){var e=a(o.mark((function e(r,t){var n,i,a,u,s;return o.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(r&&!Array.isArray(r)&&"object"===typeof r){e.next=3;break}return n=new d.EthereumRpcError(d.errorCodes.rpc.invalidRequest,"Requests must be plain objects. Received: ".concat(typeof r),{request:r}),e.abrupt("return",t(n,{id:void 0,jsonrpc:"2.0",error:n}));case 3:if("string"===typeof r.method){e.next=6;break}return i=new d.EthereumRpcError(d.errorCodes.rpc.invalidRequest,"Must specify a string method. Received: ".concat(typeof r.method),{request:r}),e.abrupt("return",t(i,{id:r.id,jsonrpc:"2.0",error:i}));case 6:return a=Object.assign({},r),u={id:a.id,jsonrpc:a.jsonrpc},s=null,e.prev=9,e.next=12,this._processRequest(a,u);case 12:e.next=17;break;case 14:e.prev=14,e.t0=e.catch(9),s=e.t0;case 17:return s&&(delete u.result,u.error||(u.error=d.serializeError(s))),e.abrupt("return",t(s,u));case 19:case"end":return e.stop()}}),e,this,[[9,14]])})));return function(r,t){return e.apply(this,arguments)}}()},{key:"_processRequest",value:function(){var e=a(o.mark((function e(r,n){var a,u,s,c,p;return o.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t._runAllMiddleware(r,n,this._middleware);case 2:return a=e.sent,u=i(a,3),s=u[0],c=u[1],p=u[2],t._checkForCompletion(r,n,c),e.next=10,t._runReturnHandlers(p);case 10:if(!s){e.next=12;break}throw s;case 12:case"end":return e.stop()}}),e,this)})));return function(r,t){return e.apply(this,arguments)}}()}],[{key:"_runAllMiddleware",value:function(){var e=a(o.mark((function e(r,a,u){var s,c,p,l,f,d,h,v;return o.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:s=[],c=null,p=!1,l=n(u),e.prev=4,l.s();case 6:if((f=l.n()).done){e.next=18;break}return d=f.value,e.next=10,t._runMiddleware(r,a,d,s);case 10:if(h=e.sent,v=i(h,2),c=v[0],!(p=v[1])){e.next=16;break}return e.abrupt("break",18);case 16:e.next=6;break;case 18:e.next=23;break;case 20:e.prev=20,e.t0=e.catch(4),l.e(e.t0);case 23:return e.prev=23,l.f(),e.finish(23);case 26:return e.abrupt("return",[c,p,s.reverse()]);case 27:case"end":return e.stop()}}),e,null,[[4,20,23,26]])})));return function(r,t,n){return e.apply(this,arguments)}}()},{key:"_runMiddleware",value:function(e,r,t,n){return new Promise((function(o){var i=function(e){var t=e||r.error;t&&(r.error=d.serializeError(t)),o([t,!0])};try{t(e,r,(function(t){r.error?i(r.error):(t&&("function"!==typeof t&&i(new d.EthereumRpcError(d.errorCodes.rpc.internal,'JsonRpcEngine: "next" return handlers must be functions. '+'Received "'.concat(typeof t,'" for request:\n').concat(v(e)),{request:e})),n.push(t)),o([null,!1]))}),i)}catch(a){i(a)}}))}},{key:"_runReturnHandlers",value:function(){var e=a(o.mark((function e(r){var t,i,a;return o.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:t=n(r),e.prev=1,a=o.mark((function e(){var r;return o.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=i.value,e.next=3,new Promise((function(e,t){r((function(r){return r?t(r):e()}))}));case 3:case"end":return e.stop()}}),e)})),t.s();case 4:if((i=t.n()).done){e.next=8;break}return e.delegateYield(a(),"t0",6);case 6:e.next=4;break;case 8:e.next=13;break;case 10:e.prev=10,e.t1=e.catch(1),t.e(e.t1);case 13:return e.prev=13,t.f(),e.finish(13);case 16:case"end":return e.stop()}}),e,null,[[1,10,13,16]])})));return function(r){return e.apply(this,arguments)}}()},{key:"_checkForCompletion",value:function(e,r,t){if(!("result"in r)&&!("error"in r))throw new d.EthereumRpcError(d.errorCodes.rpc.internal,"JsonRpcEngine: Response has no error or result for request:\n".concat(v(e)),{request:e});if(!t)throw new d.EthereumRpcError(d.errorCodes.rpc.internal,"JsonRpcEngine: Nothing ended request:\n".concat(v(e)),{request:e})}}]),t}(f.default);function v(e){return JSON.stringify(e,null,2)}r.JsonRpcEngine=h},1345:function(e,r,t){var n=t(578),o=t(387),i=t(1435),a=t(584);function u(r){var t="function"===typeof Map?new Map:void 0;return e.exports=u=function(e){if(null===e||!i(e))return e;if("function"!==typeof e)throw new TypeError("Super expression must either be null or a function");if("undefined"!==typeof t){if(t.has(e))return t.get(e);t.set(e,r)}function r(){return a(e,arguments,n(this).constructor)}return r.prototype=Object.create(e.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}),o(r,e)},u(r)}e.exports=u},1346:function(e,r){e.exports=i,i.default=i,i.stable=s,i.stableStringify=s;var t=[],n=[];function o(){return{depthLimit:Number.MAX_SAFE_INTEGER,edgesLimit:Number.MAX_SAFE_INTEGER}}function i(e,r,i,u){var s;"undefined"===typeof u&&(u=o()),function e(r,t,n,o,i,u,s){var c;if(u+=1,"object"===typeof r&&null!==r){for(c=0;cs.depthLimit)return void a("[...]",r,t,i);if("undefined"!==typeof s.edgesLimit&&n+1>s.edgesLimit)return void a("[...]",r,t,i);if(o.push(r),Array.isArray(r))for(c=0;cr?1:0}function s(e,r,i,s){"undefined"===typeof s&&(s=o());var p,l=function e(r,n,o,i,s,c,p){var l;if(c+=1,"object"===typeof r&&null!==r){for(l=0;lp.depthLimit)return void a("[...]",r,n,s);if("undefined"!==typeof p.edgesLimit&&o+1>p.edgesLimit)return void a("[...]",r,n,s);if(i.push(r),Array.isArray(r))for(l=0;l0)for(var o=0;o1&&void 0!==arguments[1]?arguments[1]:a;if(Number.isInteger(e)){var o=e.toString();if(f(n.errorValues,o))return n.errorValues[o].message;if(p(e))return r.JSON_RPC_SERVER_ERROR_MESSAGE}return t}function c(e){if(!Number.isInteger(e))return!1;var r=e.toString();return!!n.errorValues[r]||!!p(e)}function p(e){return e>=-32099&&e<=-32e3}function l(e){return e&&"object"===typeof e&&!Array.isArray(e)?Object.assign({},e):e}function f(e,r){return Object.prototype.hasOwnProperty.call(e,r)}r.JSON_RPC_SERVER_ERROR_MESSAGE="Unspecified server error.",r.getMessageFromCode=s,r.isValidCode=c,r.serializeError=function(e){var r,t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=n.fallbackError,a=void 0===i?u:i,p=n.shouldIncludeStack,d=void 0!==p&&p;if(!a||!Number.isInteger(a.code)||"string"!==typeof a.message)throw new Error("Must provide fallback error with integer number code and string message.");if(e instanceof o.EthereumRpcError)return e.serialize();var h={};if(e&&"object"===typeof e&&!Array.isArray(e)&&f(e,"code")&&c(e.code)){var v=e;h.code=v.code,v.message&&"string"===typeof v.message?(h.message=v.message,f(v,"data")&&(h.data=v.data)):(h.message=s(h.code),h.data={originalError:l(e)})}else{h.code=a.code;var y=null===(r=e)||void 0===r?void 0:r.message;h.message=y&&"string"===typeof y?y:a.message,h.data={originalError:l(e)}}var m=null===(t=e)||void 0===t?void 0:t.stack;return d&&e&&m&&"string"===typeof m&&(h.stack=m),h}},1348:function(e,r,t){e.exports=t(1438)},1349:function(e,r,t){var n=t(2),o=t(235),i=t(1246).default,a=t(1348),u=t(1342).createAsyncMiddleware,s=t(1341),c=t(1229),p=c.unsafeRandomBytes,l=c.incrementHexInt,f=t(1279);function d(e){return{hash:e.hash,parentHash:e.parentHash,sha3Uncles:e.sha3Uncles,miner:e.miner,stateRoot:e.stateRoot,transactionsRoot:e.transactionsRoot,receiptsRoot:e.receiptsRoot,logsBloom:e.logsBloom,difficulty:e.difficulty,number:e.number,gasLimit:e.gasLimit,gasUsed:e.gasUsed,nonce:e.nonce,mixHash:e.mixHash,timestamp:e.timestamp,extraData:e.extraData}}e.exports=function(e){var r=e.blockTracker,t=e.provider,c={},h=s({blockTracker:r,provider:t}),v=!1,y=new i,m=a({eth_subscribe:u((function(e,r){return g.apply(this,arguments)})),eth_unsubscribe:u((function(e,r){return w.apply(this,arguments)}))});return m.destroy=function(){for(var e in y.removeAllListeners(),c)c[e].destroy(),delete c[e];v=!0},{events:y,middleware:m};function g(){return(g=o(n.mark((function e(i,a){var u,s,y,m,g,w,k;return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(k=function(e){var r=e.subId,t=e.filter;return t.on("update",(function(e){return b(r,e)})),{type:u,destroy:function(){var e=o(n.mark((function e(){return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,h.uninstallFilter(t.idHex);case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}()}},w=function(e){var i=e.subId,a={type:u,destroy:function(){var e=o(n.mark((function e(){return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:r.removeListener("sync",a.update);case 1:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),update:function(){var e=o(n.mark((function e(r){var o,a,u,s,c;return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return o=r.oldBlock,a=r.newBlock,u=a,s=l(o),e.next=5,f({provider:t,fromBlock:s,toBlock:u});case 5:c=e.sent,c.map(d).forEach((function(e){b(i,e)}));case 8:case"end":return e.stop()}}),e)})));return function(r){return e.apply(this,arguments)}}()};return r.on("sync",a.update),a},!v){e.next=4;break}throw new Error("SubscriptionManager - attempting to use after destroying");case 4:u=i.params[0],s=p(16),e.t0=u,e.next="newHeads"===e.t0?9:"logs"===e.t0?11:17;break;case 9:return y=w({subId:s}),e.abrupt("break",18);case 11:return m=i.params[1],e.next=14,h.newLogFilter(m);case 14:return g=e.sent,y=k({subId:s,filter:g}),e.abrupt("break",18);case 17:throw new Error('SubscriptionManager - unsupported subscription type "'.concat(u,'"'));case 18:return c[s]=y,a.result=s,e.abrupt("return");case 21:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function w(){return(w=o(n.mark((function e(r,t){var o,i;return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!v){e.next=2;break}throw new Error("SubscriptionManager - attempting to use after destroying");case 2:if(o=r.params[0],i=c[o]){e.next=7;break}return t.result=!1,e.abrupt("return");case 7:return delete c[o],e.next=10,i.destroy();case 10:t.result=!0;case 11:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function b(e,r){y.emit("notification",{jsonrpc:"2.0",method:"eth_subscription",params:{subscription:e,result:r}})}}},1406:function(e,r,t){var n=t(578);e.exports=function(e,r){for(;!Object.prototype.hasOwnProperty.call(e,r)&&null!==(e=n(e)););return e}},1407:function(e,r){e.exports=function(e){var r=(e=e||{}).max||Number.MAX_SAFE_INTEGER,t="undefined"!==typeof e.start?e.start:Math.floor(Math.random()*r);return function(){return t%=r,t++}}},1431:function(e,r,t){"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.createIdRemapMiddleware=void 0;var n=t(1343);r.createIdRemapMiddleware=function(){return function(e,r,t,o){var i=e.id,a=n.getUniqueId();e.id=a,r.id=a,t((function(t){e.id=i,r.id=i,t()}))}}},1432:function(e,r,t){"use strict";var n=t(2),o=t(235);Object.defineProperty(r,"__esModule",{value:!0}),r.createAsyncMiddleware=void 0,r.createAsyncMiddleware=function(e){return function(){var r=o(n.mark((function r(t,i,a,u){var s,c,p,l,f;return n.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return c=new Promise((function(e){s=e})),p=null,l=!1,f=function(){var e=o(n.mark((function e(){return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return l=!0,a((function(e){p=e,s()})),e.next=4,c;case 4:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),r.prev=4,r.next=7,e(t,i,f);case 7:if(!l){r.next=13;break}return r.next=10,c;case 10:p(null),r.next=14;break;case 13:u(null);case 14:r.next=19;break;case 16:r.prev=16,r.t0=r.catch(4),p?p(r.t0):u(r.t0);case 19:case"end":return r.stop()}}),r,null,[[4,16]])})));return function(e,t,n,o){return r.apply(this,arguments)}}()}},1433:function(e,r,t){"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.createScaffoldMiddleware=void 0,r.createScaffoldMiddleware=function(e){return function(r,t,n,o){var i=e[r.method];return void 0===i?n():"function"===typeof i?i(r,t,n,o):(t.result=i,o())}}},1434:function(e,r,t){"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getMessageFromCode=r.serializeError=r.EthereumProviderError=r.EthereumRpcError=r.ethErrors=r.errorCodes=void 0;var n=t(1276);Object.defineProperty(r,"EthereumRpcError",{enumerable:!0,get:function(){return n.EthereumRpcError}}),Object.defineProperty(r,"EthereumProviderError",{enumerable:!0,get:function(){return n.EthereumProviderError}});var o=t(1347);Object.defineProperty(r,"serializeError",{enumerable:!0,get:function(){return o.serializeError}}),Object.defineProperty(r,"getMessageFromCode",{enumerable:!0,get:function(){return o.getMessageFromCode}});var i=t(1436);Object.defineProperty(r,"ethErrors",{enumerable:!0,get:function(){return i.ethErrors}});var a=t(1277);Object.defineProperty(r,"errorCodes",{enumerable:!0,get:function(){return a.errorCodes}})},1435:function(e,r){e.exports=function(e){return-1!==Function.toString.call(e).indexOf("[native code]")}},1436:function(e,r,t){"use strict";var n=t(117);Object.defineProperty(r,"__esModule",{value:!0}),r.ethErrors=void 0;var o=t(1276),i=t(1347),a=t(1277);function u(e,r){var t=c(r),a=n(t,2),u=a[0],s=a[1];return new o.EthereumRpcError(e,u||i.getMessageFromCode(e),s)}function s(e,r){var t=c(r),a=n(t,2),u=a[0],s=a[1];return new o.EthereumProviderError(e,u||i.getMessageFromCode(e),s)}function c(e){if(e){if("string"===typeof e)return[e];if("object"===typeof e&&!Array.isArray(e)){var r=e.message,t=e.data;if(r&&"string"!==typeof r)throw new Error("Must specify string message.");return[r||void 0,t]}}return[]}r.ethErrors={rpc:{parse:function(e){return u(a.errorCodes.rpc.parse,e)},invalidRequest:function(e){return u(a.errorCodes.rpc.invalidRequest,e)},invalidParams:function(e){return u(a.errorCodes.rpc.invalidParams,e)},methodNotFound:function(e){return u(a.errorCodes.rpc.methodNotFound,e)},internal:function(e){return u(a.errorCodes.rpc.internal,e)},server:function(e){if(!e||"object"!==typeof e||Array.isArray(e))throw new Error("Ethereum RPC Server errors must provide single object argument.");var r=e.code;if(!Number.isInteger(r)||r>-32005||r<-32099)throw new Error('"code" must be an integer such that: -32099 <= code <= -32005');return u(r,e)},invalidInput:function(e){return u(a.errorCodes.rpc.invalidInput,e)},resourceNotFound:function(e){return u(a.errorCodes.rpc.resourceNotFound,e)},resourceUnavailable:function(e){return u(a.errorCodes.rpc.resourceUnavailable,e)},transactionRejected:function(e){return u(a.errorCodes.rpc.transactionRejected,e)},methodNotSupported:function(e){return u(a.errorCodes.rpc.methodNotSupported,e)},limitExceeded:function(e){return u(a.errorCodes.rpc.limitExceeded,e)}},provider:{userRejectedRequest:function(e){return s(a.errorCodes.provider.userRejectedRequest,e)},unauthorized:function(e){return s(a.errorCodes.provider.unauthorized,e)},unsupportedMethod:function(e){return s(a.errorCodes.provider.unsupportedMethod,e)},disconnected:function(e){return s(a.errorCodes.provider.disconnected,e)},chainDisconnected:function(e){return s(a.errorCodes.provider.chainDisconnected,e)},custom:function(e){if(!e||"object"!==typeof e||Array.isArray(e))throw new Error("Ethereum Provider custom errors must provide single object argument.");var r=e.code,t=e.message,n=e.data;if(!t||"string"!==typeof t)throw new Error('"message" must be a nonempty string');return new o.EthereumProviderError(r,t,n)}}}},1437:function(e,r,t){"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.mergeMiddleware=void 0;var n=t(1344);r.mergeMiddleware=function(e){var r=new n.JsonRpcEngine;return e.forEach((function(e){return r.push(e)})),r.asMiddleware()}},1438:function(e,r){e.exports=function(e){return function(r,t,n,o){var i=e[r.method];return void 0===i?n():"function"===typeof i?i(r,t,n,o):(t.result=i,o())}}},1439:function(e,r,t){var n=t(2),o=t(235),i=t(87),a=t(88),u=t(292),s=t(293),c=t(1271),p=t(1440),l=t(1441),f=t(1229),d=(f.bnToHex,f.hexToInt),h=f.incrementHexInt,v=f.minBlockRef,y=f.blockRefIsNumber,m=function(e){"use strict";u(t,e);var r=s(t);function t(e){var n,o=e.provider,a=e.params;return i(this,t),(n=r.call(this)).type="log",n.ethQuery=new c(o),n.params=Object.assign({fromBlock:"latest",toBlock:"latest",address:void 0,topics:[]},a),n.params.address&&(Array.isArray(n.params.address)||(n.params.address=[n.params.address]),n.params.address=n.params.address.map((function(e){return e.toLowerCase()}))),n}return a(t,[{key:"initialize",value:function(){var e=o(n.mark((function e(r){var t,o,i,a,u;return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=r.currentBlock,o=this.params.fromBlock,["latest","pending"].includes(o)&&(o=t),"earliest"===o&&(o="0x0"),this.params.fromBlock=o,i=v(this.params.toBlock,t),a=Object.assign({},this.params,{toBlock:i}),e.next=9,this._fetchLogs(a);case 9:u=e.sent,this.addInitialResults(u);case 11:case"end":return e.stop()}}),e,this)})));return function(r){return e.apply(this,arguments)}}()},{key:"update",value:function(){var e=o(n.mark((function e(r){var t,o,i,a,u,s,c,p=this;return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=r.oldBlock,o=r.newBlock,i=o,a=t?h(t):o,u=Object.assign({},this.params,{fromBlock:a,toBlock:i}),e.next=6,this._fetchLogs(u);case 6:s=e.sent,c=s.filter((function(e){return p.matchLog(e)})),this.addResults(c);case 9:case"end":return e.stop()}}),e,this)})));return function(r){return e.apply(this,arguments)}}()},{key:"_fetchLogs",value:function(){var e=o(n.mark((function e(r){var t,o=this;return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,p((function(e){return o.ethQuery.getLogs(r,e)}))();case 2:return t=e.sent,e.abrupt("return",t);case 4:case"end":return e.stop()}}),e)})));return function(r){return e.apply(this,arguments)}}()},{key:"matchLog",value:function(e){if(d(this.params.fromBlock)>=d(e.blockNumber))return!1;if(y(this.params.toBlock)&&d(this.params.toBlock)<=d(e.blockNumber))return!1;var r=e.address&&e.address.toLowerCase();return!(this.params.address&&r&&!this.params.address.includes(r))&&this.params.topics.every((function(r,t){var n=e.topics[t];if(!n)return!1;n=n.toLowerCase();var o=Array.isArray(r)?r:[r];return!!o.includes(null)||(o=o.map((function(e){return e.toLowerCase()}))).includes(n)}))}}]),t}(l);e.exports=m},1440:function(e,r,t){"use strict";var n=t(130),o=function(e,r,t,n){return function(){for(var o=this,i=arguments.length,a=new Array(i),u=0;u0&&o[o.length-1])&&(6===i[0]||2===i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]1)throw new Error("this method is unavailabel on semaphores with concurrency > 1; use the scoped release returned by acquire instead");if(this._currentReleaser){var e=this._currentReleaser;this._currentReleaser=void 0,e()}},e.prototype._dispatch=function(){var e=this,r=this._queue.shift();if(r){var t=!1;this._currentReleaser=function(){t||(t=!0,e._value++,e._dispatch())},r([this._value--,this._currentReleaser])}},e}(),a=function(){function e(){this._semaphore=new i(1)}return e.prototype.acquire=function(){return n(this,void 0,void 0,(function(){var e;return o(this,(function(r){switch(r.label){case 0:return[4,this._semaphore.acquire()];case 1:return e=r.sent(),[2,e[1]]}}))}))},e.prototype.runExclusive=function(e){return this._semaphore.runExclusive((function(){return e()}))},e.prototype.isLocked=function(){return this._semaphore.isLocked()},e.prototype.release=function(){this._semaphore.release()},e}();function u(e,r,t){var i=this;return void 0===t&&(t=new Error("timeout")),{acquire:function(){return new Promise((function(a,u){return n(i,void 0,void 0,(function(){var n,i;return o(this,(function(o){switch(o.label){case 0:return n=!1,setTimeout((function(){n=!0,u(t)}),r),[4,e.acquire()];case 1:return i=o.sent(),n?(Array.isArray(i)?i[1]:i)():a(i),[2]}}))}))}))},runExclusive:function(e){return n(this,void 0,void 0,(function(){var r,t;return o(this,(function(n){switch(n.label){case 0:r=function(){},n.label=1;case 1:return n.trys.push([1,,7,8]),[4,this.acquire()];case 2:return t=n.sent(),Array.isArray(t)?(r=t[1],[4,e(t[0])]):[3,4];case 3:return[2,n.sent()];case 4:return r=t,[4,e()];case 5:return[2,n.sent()];case 6:return[3,8];case 7:return r(),[7];case 8:return[2]}}))}))},release:function(){e.release()},isLocked:function(){return e.isLocked()}}}}}]); \ No newline at end of file diff --git a/static/js/3.9d3b560a.chunk.js b/static/js/3.9d3b560a.chunk.js deleted file mode 100644 index 3bfe14e..0000000 --- a/static/js/3.9d3b560a.chunk.js +++ /dev/null @@ -1,2 +0,0 @@ -/*! For license information please see 3.9d3b560a.chunk.js.LICENSE.txt */ -(this.webpackJsonpunifactory=this.webpackJsonpunifactory||[]).push([[3],[function(e,t,r){"use strict";r.d(t,"a",(function(){return f}));var n=r(1),a=r.n(n),i={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},o=a.a.createContext&&a.a.createContext(i),c=function(){return(c=Object.assign||function(e){for(var t,r=1,n=arguments.length;r1?t-1:0),n=1;n0?" Args: "+r.join(", "):""))}var O=function(){function e(e){this.groupSizes=new Uint32Array(512),this.length=512,this.tag=e}var t=e.prototype;return t.indexOfGroup=function(e){for(var t=0,r=0;r=this.groupSizes.length){for(var r=this.groupSizes,n=r.length,a=n;e>=a;)(a<<=1)<0&&E(16,""+e);this.groupSizes=new Uint32Array(a),this.groupSizes.set(r),this.length=a;for(var i=n;i=this.length||0===this.groupSizes[e])return t;for(var r=this.groupSizes[e],n=this.indexOfGroup(e),a=n+r,i=n;i=0;r--){var n=t[r];if(n&&1===n.nodeType&&n.hasAttribute(w))return n}}(r),i=void 0!==a?a.nextSibling:null;n.setAttribute(w,"active"),n.setAttribute("data-styled-version","5.3.0");var o=F();return o&&n.setAttribute("nonce",o),r.insertBefore(n,i),n},U=function(){function e(e){var t=this.element=D(e);t.appendChild(document.createTextNode("")),this.sheet=function(e){if(e.sheet)return e.sheet;for(var t=document.styleSheets,r=0,n=t.length;r=0){var r=document.createTextNode(t),n=this.nodes[e];return this.element.insertBefore(r,n||null),this.length++,!0}return!1},t.deleteRule=function(e){this.element.removeChild(this.nodes[e]),this.length--},t.getRule=function(e){return e0&&(f+=e+",")})),n+=""+c+s+'{content:"'+f+'"}/*!sc*/\n'}}}return n}(this)},e}(),G=/(a)(d)/gi,X=function(e){return String.fromCharCode(e+(e>25?39:97))};function K(e){var t,r="";for(t=Math.abs(e);t>52;t=t/52|0)r=X(t%52)+r;return(X(t%52)+r).replace(G,"$1-$2")}var W=function(e,t){for(var r=t.length;r;)e=33*e^t.charCodeAt(--r);return e},Z=function(e){return W(5381,e)};function $(e){for(var t=0;t>>0);if(!t.hasNameForId(n,o)){var c=r(i,"."+o,void 0,n);t.insertRules(n,o,c)}a.push(o),this.staticRulesId=o}else{for(var s=this.rules.length,f=W(this.baseHash,r.hash),d="",u=0;u>>0);if(!t.hasNameForId(n,p)){var m=r(d,"."+p,void 0,n);t.insertRules(n,p,m)}a.push(p)}}return a.join(" ")},e}(),ee=/^\s*\/\/.*$/gm,te=[":","[",".","#"];function re(e){var t,r,n,a,i=void 0===e?v:e,o=i.options,c=void 0===o?v:o,f=i.plugins,d=void 0===f?m:f,u=new s.a(c),l=[],b=function(e){function t(t){if(t)try{e(t+"}")}catch(e){}}return function(r,n,a,i,o,c,s,f,d,u){switch(r){case 1:if(0===d&&64===n.charCodeAt(0))return e(n+";"),"";break;case 2:if(0===f)return n+"/*|*/";break;case 3:switch(f){case 102:case 112:return e(a[0]+n),"";default:return n+(0===u?"/*|*/":"")}case-2:n.split("/*|*/}").forEach(t)}}}((function(e){l.push(e)})),h=function(e,n,i){return 0===n&&-1!==te.indexOf(i[r.length])||i.match(a)?e:"."+t};function p(e,i,o,c){void 0===c&&(c="&");var s=e.replace(ee,""),f=i&&o?o+" "+i+" { "+s+" }":s;return t=c,r=i,n=new RegExp("\\"+r+"\\b","g"),a=new RegExp("(\\"+r+"\\b){2,}"),u(o||!i?"":i,f)}return u.use([].concat(d,[function(e,t,a){2===e&&a.length&&a[0].lastIndexOf(r)>0&&(a[0]=a[0].replace(n,h))},b,function(e){if(-2===e){var t=l;return l=[],t}}])),p.hash=d.length?d.reduce((function(e,t){return t.name||E(15),W(e,t.name)}),5381).toString():"",p}var ne=i.a.createContext(),ae=ne.Consumer,ie=i.a.createContext(),oe=(ie.Consumer,new V),ce=re();function se(){return Object(a.useContext)(ne)||oe}function fe(){return Object(a.useContext)(ie)||ce}function de(e){var t=Object(a.useState)(e.stylisPlugins),r=t[0],n=t[1],o=se(),s=Object(a.useMemo)((function(){var t=o;return e.sheet?t=e.sheet:e.target&&(t=t.reconstructWithOptions({target:e.target},!1)),e.disableCSSOMInjection&&(t=t.reconstructWithOptions({useCSSOMInjection:!1})),t}),[e.disableCSSOMInjection,e.sheet,e.target]),f=Object(a.useMemo)((function(){return re({options:{prefix:!e.disableVendorPrefixes},plugins:r})}),[e.disableVendorPrefixes,r]);return Object(a.useEffect)((function(){c()(r,e.stylisPlugins)||n(e.stylisPlugins)}),[e.stylisPlugins]),i.a.createElement(ne.Provider,{value:s},i.a.createElement(ie.Provider,{value:f},e.children))}var ue=function(){function e(e,t){var r=this;this.inject=function(e,t){void 0===t&&(t=ce);var n=r.name+t.hash;e.hasNameForId(r.id,n)||e.insertRules(r.id,n,t(r.rules,n,"@keyframes"))},this.toString=function(){return E(12,String(r.name))},this.name=e,this.id="sc-keyframes-"+e,this.rules=t}return e.prototype.getName=function(e){return void 0===e&&(e=ce),this.name+e.hash},e}(),le=/([A-Z])/,be=/([A-Z])/g,he=/^ms-/,pe=function(e){return"-"+e.toLowerCase()};function me(e){return le.test(e)?e.replace(be,pe).replace(he,"-ms-"):e}var ve=function(e){return null==e||!1===e||""===e};function ge(e,t,r,n){if(Array.isArray(e)){for(var a,i=[],o=0,c=e.length;o1?t-1:0),n=1;n?@[\\\]^`{|}~-]+/g,ke=/(^-|-$)/g;function _e(e){return e.replace(we,"-").replace(ke,"")}var Me=function(e){return K(Z(e)>>>0)};function Se(e){return"string"==typeof e&&!0}var Ee=function(e){return"function"==typeof e||"object"==typeof e&&null!==e&&!Array.isArray(e)},Oe=function(e){return"__proto__"!==e&&"constructor"!==e&&"prototype"!==e};function Ae(e,t,r){var n=e[r];Ee(t)&&Ee(n)?Te(n,t):e[r]=t}function Te(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n=0||(a[r]=e[r]);return a}(t,["componentId"]),i=n&&n+"-"+(Se(e)?e:_e(x(e)));return Ne(e,b({},a,{attrs:k,componentId:i}),r)},Object.defineProperty(M,"defaultProps",{get:function(){return this._foldedDefaultProps},set:function(t){this._foldedDefaultProps=n?Te({},e.defaultProps,t):t}}),M.toString=function(){return"."+M.styledComponentId},o&&l()(M,e,{attrs:!0,componentStyle:!0,displayName:!0,foldedComponentIds:!0,shouldForwardProp:!0,styledComponentId:!0,target:!0,withComponent:!0}),M}var Be=function(e){return function e(t,r,a){if(void 0===a&&(a=v),!Object(n.isValidElementType)(r))return E(1,String(r));var i=function(){return t(r,a,xe.apply(void 0,arguments))};return i.withConfig=function(n){return e(t,r,b({},a,{},n))},i.attrs=function(n){return e(t,r,b({},a,{attrs:Array.prototype.concat(a.attrs,n).filter(Boolean)}))},i}(Ne,e)};["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","marquee","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","marker","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","textPath","tspan"].forEach((function(e){Be[e]=Be(e)}));var Le=function(){function e(e,t){this.rules=e,this.componentId=t,this.isStatic=$(e),V.registerId(this.componentId+1)}var t=e.prototype;return t.createStyles=function(e,t,r,n){var a=n(ge(this.rules,t,r,n).join(""),""),i=this.componentId+e;r.insertRules(i,i,a)},t.removeStyles=function(e,t){t.clearRules(this.componentId+e)},t.renderStyles=function(e,t,r,n){e>2&&V.registerId(this.componentId+e),this.removeStyles(e,r),this.createStyles(e,t,r,n)},e}();function Ie(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n1?t-1:0),n=1;n"+t+""},this.getStyleTags=function(){return e.sealed?E(2):e._emitSheetCSS()},this.getStyleElement=function(){var t;if(e.sealed)return E(2);var r=((t={})[w]="",t["data-styled-version"]="5.3.0",t.dangerouslySetInnerHTML={__html:e.instance.toString()},t),n=F();return n&&(r.nonce=n),[i.a.createElement("style",b({},r,{key:"sc-0-0"}))]},this.seal=function(){e.sealed=!0},this.instance=new V({isServer:!0}),this.sealed=!1}var t=e.prototype;return t.collectStyles=function(e){return this.sealed?E(2):i.a.createElement(de,{sheet:this.instance},e)},t.interleaveWithNodeStream=function(e){return E(3)},e}(),Ue=function(e){var t=i.a.forwardRef((function(t,r){var n=Object(a.useContext)(je),o=e.defaultProps,c=ye(t,n,o);return i.a.createElement(e,b({},t,{theme:c,ref:r}))}));return l()(t,e),t.displayName="WithTheme("+x(e)+")",t},ze=function(){return Object(a.useContext)(je)},He={StyleSheet:V,masterSheet:oe};t.default=Be}.call(this,r(48))},function(e,t,r){"use strict";r.d(t,"j",(function(){return o})),r.d(t,"i",(function(){return s})),r.d(t,"a",(function(){return f})),r.d(t,"b",(function(){return d})),r.d(t,"n",(function(){return u})),r.d(t,"o",(function(){return l})),r.d(t,"k",(function(){return b})),r.d(t,"h",(function(){return h})),r.d(t,"d",(function(){return p})),r.d(t,"e",(function(){return m})),r.d(t,"c",(function(){return v})),r.d(t,"f",(function(){return g})),r.d(t,"g",(function(){return x})),r.d(t,"m",(function(){return y})),r.d(t,"l",(function(){return w}));var n=new(r(11).a)("bytes/5.5.0");function a(e){return!!e.toHexString}function i(e){return e.slice||(e.slice=function(){var t=Array.prototype.slice.call(arguments);return i(new Uint8Array(Array.prototype.slice.apply(e,t)))}),e}function o(e){return b(e)&&!(e.length%2)||s(e)}function c(e){return"number"===typeof e&&e==e&&e%1===0}function s(e){if(null==e)return!1;if(e.constructor===Uint8Array)return!0;if("string"===typeof e)return!1;if(!c(e.length)||e.length<0)return!1;for(var t=0;t=256)return!1}return!0}function f(e,t){if(t||(t={}),"number"===typeof e){n.checkSafeUint53(e,"invalid arrayify value");for(var r=[];e;)r.unshift(255&e),e=parseInt(String(e/256));return 0===r.length&&r.push(0),i(new Uint8Array(r))}if(t.allowMissingPrefix&&"string"===typeof e&&"0x"!==e.substring(0,2)&&(e="0x"+e),a(e)&&(e=e.toHexString()),b(e)){var o=e.substring(2);o.length%2&&("left"===t.hexPad?o="0x0"+o.substring(2):"right"===t.hexPad?o+="0":n.throwArgumentError("hex data is odd-length","value",e));for(var c=[],f=0;ft&&n.throwArgumentError("value out of range","value",arguments[0]);var r=new Uint8Array(t);return r.set(e,t-e.length),i(r)}function b(e,t){return!("string"!==typeof e||!e.match(/^0x[0-9A-Fa-f]*$/))&&(!t||e.length===2+2*t)}function h(e,t){if(t||(t={}),"number"===typeof e){n.checkSafeUint53(e,"invalid hexlify value");for(var r="";e;)r="0123456789abcdef"[15&e]+r,e=Math.floor(e/16);return r.length?(r.length%2&&(r="0"+r),"0x"+r):"0x00"}if("bigint"===typeof e)return(e=e.toString(16)).length%2?"0x0"+e:"0x"+e;if(t.allowMissingPrefix&&"string"===typeof e&&"0x"!==e.substring(0,2)&&(e="0x"+e),a(e))return e.toHexString();if(b(e))return e.length%2&&("left"===t.hexPad?e="0x0"+e.substring(2):"right"===t.hexPad?e+="0":n.throwArgumentError("hex data is odd-length","value",e)),e.toLowerCase();if(s(e)){for(var i="0x",o=0;o>4]+"0123456789abcdef"[15&c]}return i}return n.throwArgumentError("invalid hexlify value","value",e)}function p(e){if("string"!==typeof e)e=h(e);else if(!b(e)||e.length%2)return null;return(e.length-2)/2}function m(e,t,r){return"string"!==typeof e?e=h(e):(!b(e)||e.length%2)&&n.throwArgumentError("invalid hexData","value",e),t=2+2*t,null!=r?"0x"+e.substring(t,2+2*r):"0x"+e.substring(t)}function v(e){var t="0x";return e.forEach((function(e){t+=h(e).substring(2)})),t}function g(e){var t=function(e){"string"!==typeof e&&(e=h(e));b(e)||n.throwArgumentError("invalid hex string","value",e);e=e.substring(2);var t=0;for(;t2*t+2&&n.throwArgumentError("value out of range","value",arguments[1]);e.length<2*t+2;)e="0x0"+e.substring(2);return e}function y(e){var t={r:"0x",s:"0x",_vs:"0x",recoveryParam:0,v:0};if(o(e)){var r=f(e);65!==r.length&&n.throwArgumentError("invalid signature string; must be 65 bytes","signature",e),t.r=h(r.slice(0,32)),t.s=h(r.slice(32,64)),t.v=r[64],t.v<27&&(0===t.v||1===t.v?t.v+=27:n.throwArgumentError("signature invalid v byte","signature",e)),t.recoveryParam=1-t.v%2,t.recoveryParam&&(r[32]|=128),t._vs=h(r.slice(32,64))}else{if(t.r=e.r,t.s=e.s,t.v=e.v,t.recoveryParam=e.recoveryParam,t._vs=e._vs,null!=t._vs){var a=l(f(t._vs),32);t._vs=h(a);var i=a[0]>=128?1:0;null==t.recoveryParam?t.recoveryParam=i:t.recoveryParam!==i&&n.throwArgumentError("signature recoveryParam mismatch _vs","signature",e),a[0]&=127;var c=h(a);null==t.s?t.s=c:t.s!==c&&n.throwArgumentError("signature v mismatch _vs","signature",e)}if(null==t.recoveryParam)null==t.v?n.throwArgumentError("signature missing v and recoveryParam","signature",e):0===t.v||1===t.v?t.recoveryParam=t.v:t.recoveryParam=1-t.v%2;else if(null==t.v)t.v=27+t.recoveryParam;else{var s=0===t.v||1===t.v?t.v:1-t.v%2;t.recoveryParam!==s&&n.throwArgumentError("signature recoveryParam mismatch v","signature",e)}null!=t.r&&b(t.r)?t.r=x(t.r,32):n.throwArgumentError("signature missing or invalid r","signature",e),null!=t.s&&b(t.s)?t.s=x(t.s,32):n.throwArgumentError("signature missing or invalid s","signature",e);var d=f(t.s);d[0]>=128&&n.throwArgumentError("signature s out of range","signature",e),t.recoveryParam&&(d[0]|=128);var u=h(d);t._vs&&(b(t._vs)||n.throwArgumentError("signature invalid _vs","signature",e),t._vs=x(t._vs,32)),null==t._vs?t._vs=u:t._vs!==u&&n.throwArgumentError("signature _vs mismatch v and s","signature",e)}return t}function w(e){return h(d([(e=y(e)).r,e.s,e.recoveryParam?"0x1c":"0x1b"]))}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}r.d(t,"a",(function(){return n}))},function(e,t,r){"use strict";function n(e,t){for(var r=0;r=256||r%1)return!1}return!0}function s(e,t){if(t||(t={}),"number"===typeof e){n.checkSafeUint53(e,"invalid arrayify value");for(var r=[];e;)r.unshift(255&e),e=parseInt(String(e/256));return 0===r.length&&r.push(0),i(new Uint8Array(r))}if(t.allowMissingPrefix&&"string"===typeof e&&"0x"!==e.substring(0,2)&&(e="0x"+e),a(e)&&(e=e.toHexString()),l(e)){var o=e.substring(2);o.length%2&&("left"===t.hexPad?o="0x0"+o.substring(2):"right"===t.hexPad?o+="0":n.throwArgumentError("hex data is odd-length","value",e));for(var s=[],f=0;ft&&n.throwArgumentError("value out of range","value",arguments[0]);var r=new Uint8Array(t);return r.set(e,t-e.length),i(r)}function l(e,t){return!("string"!==typeof e||!e.match(/^0x[0-9A-Fa-f]*$/))&&(!t||e.length===2+2*t)}function b(e,t){if(t||(t={}),"number"===typeof e){n.checkSafeUint53(e,"invalid hexlify value");for(var r="";e;)r="0123456789abcdef"[15&e]+r,e=Math.floor(e/16);return r.length?(r.length%2&&(r="0"+r),"0x"+r):"0x00"}if("bigint"===typeof e)return(e=e.toString(16)).length%2?"0x0"+e:"0x"+e;if(t.allowMissingPrefix&&"string"===typeof e&&"0x"!==e.substring(0,2)&&(e="0x"+e),a(e))return e.toHexString();if(l(e))return e.length%2&&("left"===t.hexPad?e="0x0"+e.substring(2):"right"===t.hexPad?e+="0":n.throwArgumentError("hex data is odd-length","value",e)),e.toLowerCase();if(c(e)){for(var i="0x",o=0;o>4]+"0123456789abcdef"[15&s]}return i}return n.throwArgumentError("invalid hexlify value","value",e)}function h(e){if("string"!==typeof e)e=b(e);else if(!l(e)||e.length%2)return null;return(e.length-2)/2}function p(e,t,r){return"string"!==typeof e?e=b(e):(!l(e)||e.length%2)&&n.throwArgumentError("invalid hexData","value",e),t=2+2*t,null!=r?"0x"+e.substring(t,2+2*r):"0x"+e.substring(t)}function m(e){var t="0x";return e.forEach((function(e){t+=b(e).substring(2)})),t}function v(e){var t=g(b(e,{hexPad:"left"}));return"0x"===t?"0x0":t}function g(e){"string"!==typeof e&&(e=b(e)),l(e)||n.throwArgumentError("invalid hex string","value",e),e=e.substring(2);for(var t=0;t2*t+2&&n.throwArgumentError("value out of range","value",arguments[1]);e.length<2*t+2;)e="0x0"+e.substring(2);return e}function y(e){var t={r:"0x",s:"0x",_vs:"0x",recoveryParam:0,v:0};if(o(e)){var r=s(e);65!==r.length&&n.throwArgumentError("invalid signature string; must be 65 bytes","signature",e),t.r=b(r.slice(0,32)),t.s=b(r.slice(32,64)),t.v=r[64],t.v<27&&(0===t.v||1===t.v?t.v+=27:n.throwArgumentError("signature invalid v byte","signature",e)),t.recoveryParam=1-t.v%2,t.recoveryParam&&(r[32]|=128),t._vs=b(r.slice(32,64))}else{if(t.r=e.r,t.s=e.s,t.v=e.v,t.recoveryParam=e.recoveryParam,t._vs=e._vs,null!=t._vs){var a=u(s(t._vs),32);t._vs=b(a);var i=a[0]>=128?1:0;null==t.recoveryParam?t.recoveryParam=i:t.recoveryParam!==i&&n.throwArgumentError("signature recoveryParam mismatch _vs","signature",e),a[0]&=127;var c=b(a);null==t.s?t.s=c:t.s!==c&&n.throwArgumentError("signature v mismatch _vs","signature",e)}null==t.recoveryParam?null==t.v?n.throwArgumentError("signature missing v and recoveryParam","signature",e):0===t.v||1===t.v?t.recoveryParam=t.v:t.recoveryParam=1-t.v%2:null==t.v?t.v=27+t.recoveryParam:t.recoveryParam!==1-t.v%2&&n.throwArgumentError("signature recoveryParam mismatch v","signature",e),null!=t.r&&l(t.r)?t.r=x(t.r,32):n.throwArgumentError("signature missing or invalid r","signature",e),null!=t.s&&l(t.s)?t.s=x(t.s,32):n.throwArgumentError("signature missing or invalid s","signature",e);var f=s(t.s);f[0]>=128&&n.throwArgumentError("signature s out of range","signature",e),t.recoveryParam&&(f[0]|=128);var d=b(f);t._vs&&(l(t._vs)||n.throwArgumentError("signature invalid _vs","signature",e),t._vs=x(t._vs,32)),null==t._vs?t._vs=d:t._vs!==d&&n.throwArgumentError("signature _vs mismatch v and s","signature",e)}return t}function w(e){return b(f([(e=y(e)).r,e.s,e.recoveryParam?"0x1c":"0x1b"]))}},function(e,t,r){"use strict";r.d(t,"a",(function(){return h}));var n=r(6),a=r(7),i=!1,o=!1,c={debug:1,default:2,info:2,warning:3,error:4,off:5},s=c.default,f=null;var d,u,l=function(){try{var e=[];if(["NFD","NFC","NFKD","NFKC"].forEach((function(t){try{if("test"!=="test".normalize(t))throw new Error("bad normalize")}catch(r){e.push(t)}})),e.length)throw new Error("missing "+e.join(", "));if(String.fromCharCode(233).normalize("NFD")!==String.fromCharCode(101,769))throw new Error("broken implementation")}catch(t){return t.message}return null}();!function(e){e.DEBUG="DEBUG",e.INFO="INFO",e.WARNING="WARNING",e.ERROR="ERROR",e.OFF="OFF"}(d||(d={})),function(e){e.UNKNOWN_ERROR="UNKNOWN_ERROR",e.NOT_IMPLEMENTED="NOT_IMPLEMENTED",e.UNSUPPORTED_OPERATION="UNSUPPORTED_OPERATION",e.NETWORK_ERROR="NETWORK_ERROR",e.SERVER_ERROR="SERVER_ERROR",e.TIMEOUT="TIMEOUT",e.BUFFER_OVERRUN="BUFFER_OVERRUN",e.NUMERIC_FAULT="NUMERIC_FAULT",e.MISSING_NEW="MISSING_NEW",e.INVALID_ARGUMENT="INVALID_ARGUMENT",e.MISSING_ARGUMENT="MISSING_ARGUMENT",e.UNEXPECTED_ARGUMENT="UNEXPECTED_ARGUMENT",e.CALL_EXCEPTION="CALL_EXCEPTION",e.INSUFFICIENT_FUNDS="INSUFFICIENT_FUNDS",e.NONCE_EXPIRED="NONCE_EXPIRED",e.REPLACEMENT_UNDERPRICED="REPLACEMENT_UNDERPRICED",e.UNPREDICTABLE_GAS_LIMIT="UNPREDICTABLE_GAS_LIMIT",e.TRANSACTION_REPLACED="TRANSACTION_REPLACED"}(u||(u={}));var b="0123456789abcdef",h=function(){function e(t){Object(n.a)(this,e),Object.defineProperty(this,"version",{enumerable:!0,value:t,writable:!1})}return Object(a.a)(e,[{key:"_log",value:function(e,t){var r=e.toLowerCase();null==c[r]&&this.throwArgumentError("invalid log level name","logLevel",e),s>c[r]||console.log.apply(console,t)}},{key:"debug",value:function(){for(var t=arguments.length,r=new Array(t),n=0;n>4],r+=b[15&t[i]];a.push(e+"=Uint8Array(0x"+r+")")}else a.push(e+"="+JSON.stringify(t))}catch(c){a.push(e+"="+JSON.stringify(n[e].toString()))}})),a.push("code=".concat(r)),a.push("version=".concat(this.version));var i=t;a.length&&(t+=" ("+a.join(", ")+")");var c=new Error(t);return c.reason=i,c.code=r,Object.keys(n).forEach((function(e){c[e]=n[e]})),c}},{key:"throwError",value:function(e,t,r){throw this.makeError(e,t,r)}},{key:"throwArgumentError",value:function(t,r,n){return this.throwError(t,e.errors.INVALID_ARGUMENT,{argument:r,value:n})}},{key:"assert",value:function(e,t,r,n){e||this.throwError(t,r,n)}},{key:"assertArgument",value:function(e,t,r,n){e||this.throwArgumentError(t,r,n)}},{key:"checkNormalize",value:function(t){null==t&&(t="platform missing String.prototype.normalize"),l&&this.throwError("platform missing String.prototype.normalize",e.errors.UNSUPPORTED_OPERATION,{operation:"String.prototype.normalize",form:l})}},{key:"checkSafeUint53",value:function(t,r){"number"===typeof t&&(null==r&&(r="value not safe"),(t<0||t>=9007199254740991)&&this.throwError(r,e.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"out-of-safe-range",value:t}),t%1&&this.throwError(r,e.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"non-integer",value:t}))}},{key:"checkArgumentCount",value:function(t,r,n){n=n?": "+n:"",tr&&this.throwError("too many arguments"+n,e.errors.UNEXPECTED_ARGUMENT,{count:t,expectedCount:r})}},{key:"checkNew",value:function(t,r){t!==Object&&null!=t||this.throwError("missing new",e.errors.MISSING_NEW,{name:r.name})}},{key:"checkAbstract",value:function(t,r){t===r?this.throwError("cannot instantiate abstract class "+JSON.stringify(r.name)+" directly; use a sub-class",e.errors.UNSUPPORTED_OPERATION,{name:t.name,operation:"new"}):t!==Object&&null!=t||this.throwError("missing new",e.errors.MISSING_NEW,{name:r.name})}}],[{key:"globalLogger",value:function(){return f||(f=new e("logger/5.5.0")),f}},{key:"setCensorship",value:function(t,r){if(!t&&r&&this.globalLogger().throwError("cannot permanently disable censorship",e.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"}),i){if(!t)return;this.globalLogger().throwError("error censorship permanent",e.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"})}o=!!t,i=!!r}},{key:"setLogLevel",value:function(t){var r=c[t.toLowerCase()];null!=r?s=r:e.globalLogger().warn("invalid log level - "+t)}},{key:"from",value:function(t){return new e(t)}}]),e}();h.errors=u,h.levels=d},function(e,t,r){e.exports=r(601)()},function(e,t,r){"use strict";r.d(t,"a",(function(){return a}));var n=r(183);function a(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Object(n.a)(e,t)}},function(e,t,r){"use strict";r.d(t,"a",(function(){return s}));var n=r(32),a=r(264);function i(e){return(i="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var o=r(20);function c(e,t){return!t||"object"!==i(t)&&"function"!==typeof t?Object(o.a)(e):t}function s(e){return function(){var t,r=Object(n.a)(e);if(Object(a.a)()){var i=Object(n.a)(this).constructor;t=Reflect.construct(r,arguments,i)}else t=r.apply(this,arguments);return c(this,t)}}},function(e,t,r){"use strict";r.r(t),r.d(t,"defineReadOnly",(function(){return d})),r.d(t,"getStatic",(function(){return u})),r.d(t,"resolveProperties",(function(){return l})),r.d(t,"checkProperties",(function(){return b})),r.d(t,"shallowCopy",(function(){return h})),r.d(t,"deepCopy",(function(){return v})),r.d(t,"Description",(function(){return g}));var n=r(7),a=r(6),i=r(2),o=r.n(i),c=r(16),s=function(e,t,r,n){return new(r||(r=Promise))((function(a,i){function o(e){try{s(n.next(e))}catch(t){i(t)}}function c(e){try{s(n.throw(e))}catch(t){i(t)}}function s(e){var t;e.done?a(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(o,c)}s((n=n.apply(e,t||[])).next())}))},f=new c.Logger("properties/5.3.0");function d(e,t,r){Object.defineProperty(e,t,{enumerable:!0,value:r,writable:!1})}function u(e,t){for(var r=0;r<32;r++){if(e[t])return e[t];if(!e.prototype||"object"!==typeof e.prototype)break;e=Object.getPrototypeOf(e.prototype).constructor}return null}function l(e){return s(this,void 0,void 0,o.a.mark((function t(){var r,n;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=Object.keys(e).map((function(t){var r=e[t];return Promise.resolve(r).then((function(e){return{key:t,value:e}}))})),t.next=3,Promise.all(r);case 3:return n=t.sent,t.abrupt("return",n.reduce((function(e,t){return e[t.key]=t.value,e}),{}));case 5:case"end":return t.stop()}}),t)})))}function b(e,t){e&&"object"===typeof e||f.throwArgumentError("invalid object","object",e),Object.keys(e).forEach((function(r){t[r]||f.throwArgumentError("invalid object key - "+r,"transaction:"+r,e)}))}function h(e){var t={};for(var r in e)t[r]=e[r];return t}var p={bigint:!0,boolean:!0,function:!0,number:!0,string:!0};function m(e){if(function e(t){if(void 0===t||null===t||p[typeof t])return!0;if(Array.isArray(t)||"object"===typeof t){if(!Object.isFrozen(t))return!1;for(var r=Object.keys(t),n=0;nc[r]||console.log.apply(console,t)}},{key:"debug",value:function(){for(var t=arguments.length,r=new Array(t),n=0;n=9007199254740991)&&this.throwError(r,e.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"out-of-safe-range",value:t}),t%1&&this.throwError(r,e.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"non-integer",value:t}))}},{key:"checkArgumentCount",value:function(t,r,n){n=n?": "+n:"",tr&&this.throwError("too many arguments"+n,e.errors.UNEXPECTED_ARGUMENT,{count:t,expectedCount:r})}},{key:"checkNew",value:function(t,r){t!==Object&&null!=t||this.throwError("missing new",e.errors.MISSING_NEW,{name:r.name})}},{key:"checkAbstract",value:function(t,r){t===r?this.throwError("cannot instantiate abstract class "+JSON.stringify(r.name)+" directly; use a sub-class",e.errors.UNSUPPORTED_OPERATION,{name:t.name,operation:"new"}):t!==Object&&null!=t||this.throwError("missing new",e.errors.MISSING_NEW,{name:r.name})}}],[{key:"globalLogger",value:function(){return f||(f=new e("logger/5.3.0")),f}},{key:"setCensorship",value:function(t,r){if(!t&&r&&this.globalLogger().throwError("cannot permanently disable censorship",e.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"}),i){if(!t)return;this.globalLogger().throwError("error censorship permanent",e.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"})}o=!!t,i=!!r}},{key:"setLogLevel",value:function(t){var r=c[t.toLowerCase()];null!=r?s=r:e.globalLogger().warn("invalid log level - "+t)}},{key:"from",value:function(t){return new e(t)}}]),e}();b.errors=u,b.levels=d},function(e,t,r){"use strict";r.d(t,"c",(function(){return c}));var n=r(1),a=r.n(n),i=r(60);function o(){return(o=Object.assign||function(e){for(var t=1;te.length)&&(t=e.length);for(var r=0,n=Array(t);r=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:a}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,o=!0,c=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return o=e.done,e},e:function(e){c=!0,i=e},f:function(){try{o||null==r.return||r.return()}finally{if(c)throw i}}}}var m=function(e){var t=Math.abs,n=Math.max,o=Math.floor;function c(e,t){var r;if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,c),(r=s.call(this,e)).sign=t,Object.setPrototypeOf(u(r),c.prototype),e>c.__kMaxLength)throw new RangeError("Maximum BigInt size exceeded");return r}i(c,e);var s=b(c);return a(c,[{key:"toDebugString",value:function(){var e,t=["BigInt["],r=p(this);try{for(r.s();!(e=r.n()).done;){var n=e.value;t.push((n?(n>>>0).toString(16):n)+", ")}}catch(e){r.e(e)}finally{r.f()}return t.push("]"),t.join("")}},{key:"toString",value:function(){var e=0e||36this.length&&(r=this.length);for(var n=32767&e,a=e>>>15,i=0,o=t,s=0;s>>15,l=c.__imul(d,n),b=c.__imul(d,a),h=c.__imul(u,n),p=o+l+i;i=p>>>30,p&=1073741823,i+=(p+=((32767&b)<<15)+((32767&h)<<15))>>>30,o=c.__imul(u,a)+(b>>>15)+(h>>>15),this.__setDigit(s,1073741823&p)}if(0!==i||0!==o)throw new Error("implementation bug")}},{key:"__inplaceAdd",value:function(e,t,r){for(var n,a=0,i=0;i>>15,this.__setHalfDigit(t+i,32767&n);return a}},{key:"__inplaceSub",value:function(e,t,r){var n=0;if(1&t){t>>=1;for(var a=this.__digit(t),i=32767&a,o=0;o>>1;o++){var c=e.__digit(o),s=(a>>>15)-(32767&c)-n;n=1&s>>>15,this.__setDigit(t+o,(32767&s)<<15|32767&i),n=1&(i=(32767&(a=this.__digit(t+o+1)))-(c>>>15)-n)>>>15}var f=e.__digit(o),d=(a>>>15)-(32767&f)-n;if(n=1&d>>>15,this.__setDigit(t+o,(32767&d)<<15|32767&i),t+o+1>=this.length)throw new RangeError("out of bounds");0==(1&r)&&(n=1&(i=(32767&(a=this.__digit(t+o+1)))-(f>>>15)-n)>>>15,this.__setDigit(t+e.length,1073709056&a|32767&i))}else{t>>=1;for(var u=0;u>>15)-(b>>>15)-(n=1&h>>>15);n=1&p>>>15,this.__setDigit(t+u,(32767&p)<<15|32767&h)}var m=this.__digit(t+u),v=e.__digit(u),g=(32767&m)-(32767&v)-n;n=1&g>>>15;var x=0;0==(1&r)&&(n=1&(x=(m>>>15)-(v>>>15)-n)>>>15),this.__setDigit(t+u,(32767&x)<<15|32767&g)}return n}},{key:"__inplaceRightShift",value:function(e){if(0!==e){for(var t,r=this.__digit(0)>>>e,n=this.length-1,a=0;a>>e;this.__setDigit(n,r)}}},{key:"__digit",value:function(e){return this[e]}},{key:"__unsignedDigit",value:function(e){return this[e]>>>0}},{key:"__setDigit",value:function(e,t){this[e]=0|t}},{key:"__setDigitGrow",value:function(e,t){this[e]=0|t}},{key:"__halfDigitLength",value:function(){var e=this.length;return 32767>=this.__unsignedDigit(e-1)?2*e-1:2*e}},{key:"__halfDigit",value:function(e){return 32767&this[e>>>1]>>>15*(1&e)}},{key:"__setHalfDigit",value:function(e,t){var r=e>>>1,n=this.__digit(r),a=1&e?32767&n|t<<15:1073709056&n|32767&t;this.__setDigit(r,a)}}],[{key:"BigInt",value:function(e){var t=Number.isFinite;if("number"==typeof e){if(0===e)return c.__zero();if(c.__isOneDigitInt(e))return 0>e?c.__oneDigit(-e,!0):c.__oneDigit(e,!1);if(!t(e)||o(e)!==e)throw new RangeError("The number "+e+" cannot be converted to BigInt because it is not an integer");return c.__fromDouble(e)}if("string"==typeof e){var n=c.__fromString(e);if(null===n)throw new SyntaxError("Cannot convert "+e+" to a BigInt");return n}if("boolean"==typeof e)return!0===e?c.__oneDigit(1,!1):c.__zero();if("object"===r(e)){if(e.constructor===c)return e;var a=c.__toPrimitive(e);return c.BigInt(a)}throw new TypeError("Cannot convert "+e+" to a BigInt")}},{key:"toNumber",value:function(e){var t=e.length;if(0===t)return 0;if(1===t){var r=e.__unsignedDigit(0);return e.sign?-r:r}var n=e.__digit(t-1),a=c.__clz30(n),i=30*t-a;if(1024>>=12;var l=d-12,b=12<=d?0:s<<20+d,h=20+d;for(0>>30-l,b=s<>>30-h,h-=30;var p=c.__decideRounding(e,h,f,s);if((1===p||0===p&&1==(1&b))&&0===(b=b+1>>>0)&&0!=++u>>>20&&(u=0,1023<++o))return e.sign?-1/0:1/0;var m=e.sign?-2147483648:0;return o=o+1023<<20,c.__kBitConversionInts[1]=m|o|u,c.__kBitConversionInts[0]=b,c.__kBitConversionDouble[0]}},{key:"unaryMinus",value:function(e){if(0===e.length)return e;var t=e.__copy();return t.sign=!e.sign,t}},{key:"bitwiseNot",value:function(e){return e.sign?c.__absoluteSubOne(e).__trim():c.__absoluteAddOne(e,!0)}},{key:"exponentiate",value:function(e,t){if(t.sign)throw new RangeError("Exponent must be positive");if(0===t.length)return c.__oneDigit(1,!1);if(0===e.length)return e;if(1===e.length&&1===e.__digit(0))return e.sign&&0==(1&t.__digit(0))?c.unaryMinus(e):e;if(1=c.__kMaxLengthBits)throw new RangeError("BigInt too big");if(1===e.length&&2===e.__digit(0)){var n=1+(0|r/30),a=new c(n,e.sign&&0!=(1&r));a.__initializeDigits();var i=1<>=1;0!==r;r>>=1)s=c.multiply(s,s),0!=(1&r)&&(o=null===o?s:c.multiply(o,s));return o}},{key:"multiply",value:function(e,t){if(0===e.length)return e;if(0===t.length)return t;var r=e.length+t.length;30<=e.__clzmsd()+t.__clzmsd()&&r--;var n=new c(r,e.sign!==t.sign);n.__initializeDigits();for(var a=0;ac.__absoluteCompare(e,t))return c.__zero();var r,n=e.sign!==t.sign,a=t.__unsignedDigit(0);if(1===t.length&&32767>=a){if(1===a)return n===e.sign?e:c.unaryMinus(e);r=c.__absoluteDivSmall(e,a,null)}else r=c.__absoluteDivLarge(e,t,!0,!1);return r.sign=n,r.__trim()}},{key:"remainder",value:function(e,t){if(0===t.length)throw new RangeError("Division by zero");if(0>c.__absoluteCompare(e,t))return e;var r=t.__unsignedDigit(0);if(1===t.length&&32767>=r){if(1===r)return c.__zero();var n=c.__absoluteModSmall(e,r);return 0===n?c.__zero():c.__oneDigit(n,e.sign)}var a=c.__absoluteDivLarge(e,t,!1,!0);return a.sign=e.sign,a.__trim()}},{key:"add",value:function(e,t){var r=e.sign;return r===t.sign?c.__absoluteAdd(e,t,r):0<=c.__absoluteCompare(e,t)?c.__absoluteSub(e,t,r):c.__absoluteSub(t,e,!r)}},{key:"subtract",value:function(e,t){var r=e.sign;return r===t.sign?0<=c.__absoluteCompare(e,t)?c.__absoluteSub(e,t,r):c.__absoluteSub(t,e,!r):c.__absoluteAdd(e,t,r)}},{key:"leftShift",value:function(e,t){return 0===t.length||0===e.length?e:t.sign?c.__rightShiftByAbsolute(e,t):c.__leftShiftByAbsolute(e,t)}},{key:"signedRightShift",value:function(e,t){return 0===t.length||0===e.length?e:t.sign?c.__leftShiftByAbsolute(e,t):c.__rightShiftByAbsolute(e,t)}},{key:"unsignedRightShift",value:function(){throw new TypeError("BigInts have no unsigned right shift; use >> instead")}},{key:"lessThan",value:function(e,t){return 0>c.__compareToBigInt(e,t)}},{key:"lessThanOrEqual",value:function(e,t){return 0>=c.__compareToBigInt(e,t)}},{key:"greaterThan",value:function(e,t){return 0(e=o(e)))throw new RangeError("Invalid value: not (convertible to) a safe integer");if(0===e)return c.__zero();if(e>=c.__kMaxLengthBits)return t;var r=0|(e+29)/30;if(t.length(e=o(e)))throw new RangeError("Invalid value: not (convertible to) a safe integer");if(0===e)return c.__zero();if(t.sign){if(e>c.__kMaxLengthBits)throw new RangeError("BigInt too big");return c.__truncateAndSubFromPowerOfTwo(e,t,!1)}if(e>=c.__kMaxLengthBits)return t;var r=0|(e+29)/30;if(t.length>>n)return t}return c.__truncateToNBits(e,t)}},{key:"ADD",value:function(e,t){if(e=c.__toPrimitive(e),t=c.__toPrimitive(t),"string"==typeof e)return"string"!=typeof t&&(t=t.toString()),e+t;if("string"==typeof t)return e.toString()+t;if(e=c.__toNumeric(e),t=c.__toNumeric(t),c.__isBigInt(e)&&c.__isBigInt(t))return c.add(e,t);if("number"==typeof e&&"number"==typeof t)return e+t;throw new TypeError("Cannot mix BigInt and other types, use explicit conversions")}},{key:"LT",value:function(e,t){return c.__compare(e,t,0)}},{key:"LE",value:function(e,t){return c.__compare(e,t,1)}},{key:"GT",value:function(e,t){return c.__compare(e,t,2)}},{key:"GE",value:function(e,t){return c.__compare(e,t,3)}},{key:"EQ",value:function(e,t){for(;;){if(c.__isBigInt(e))return c.__isBigInt(t)?c.equal(e,t):c.EQ(t,e);if("number"==typeof e){if(c.__isBigInt(t))return c.__equalToNumber(t,e);if("object"!==r(t))return e==t;t=c.__toPrimitive(t)}else if("string"==typeof e){if(c.__isBigInt(t))return null!==(e=c.__fromString(e))&&c.equal(e,t);if("object"!==r(t))return e==t;t=c.__toPrimitive(t)}else if("boolean"==typeof e){if(c.__isBigInt(t))return c.__equalToNumber(t,+e);if("object"!==r(t))return e==t;t=c.__toPrimitive(t)}else if("symbol"===r(e)){if(c.__isBigInt(t))return!1;if("object"!==r(t))return e==t;t=c.__toPrimitive(t)}else{if("object"!==r(e))return e==t;if("object"===r(t)&&t.constructor!==c)return e==t;e=c.__toPrimitive(e)}}}},{key:"NE",value:function(e,t){return!c.EQ(e,t)}},{key:"__zero",value:function(){return new c(0,!1)}},{key:"__oneDigit",value:function(e,t){var r=new c(1,t);return r.__setDigit(0,e),r}},{key:"__decideRounding",value:function(e,t,r,n){if(0t)a=-t-1;else{if(0===r)return-1;r--,n=e.__digit(r),a=29}var i=1<>>20)-1023,n=1+(0|r/30),a=new c(n,0>e),i=1048575&c.__kBitConversionInts[1]|1048576,o=c.__kBitConversionInts[0],s=r%30,f=0;if(s<20){var d=20-s;f=d+32,t=i>>>d,i=i<<32-d|o>>>d,o<<=32-d}else if(20===s)f=32,t=i,i=o,o=0;else{var u=s-20;f=32-u,t=i<>>32-u,i=o<>>2,i=i<<30|o>>>2,o<<=30):t=0,a.__setDigit(l,t);return a.__trim()}},{key:"__isWhitespace",value:function(e){return!!(13>=e&&9<=e)||(159>=e?32==e:131071>=e?160==e||5760==e:196607>=e?10>=(e&=131071)||40==e||41==e||47==e||95==e||4096==e:65279==e)}},{key:"__fromString",value:function(e){var t=11073741824/s)return null;var d=s*o+f>>>c.__kBitsPerCharTableShift,u=new c(0|(d+29)/30,!1),l=10>t?t:10,b=10>=c.__kBitsPerCharTableShift;var h=[],p=[],m=!1;do{for(var v,g=0,x=0;;){if(v=void 0,i-48>>>0>>0>>0>>0>>c.__kBitsPerCharTableShift)/30;u.__inplaceMultiplyAdd(M,_,E)}while(!y)}if(a!==n){if(!c.__isWhitespace(i))return null;for(a++;a>>s-(i-=30))}if(0!==a){if(n>=e.length)throw new Error("implementation bug");e.__setDigit(n++,a)}for(;n>>1)+(85&n))>>>2)+(51&n))>>>4)+(15&n),i=t-1,o=e.__digit(r-1),s=0|(30*r-c.__clz30(o)+a-1)/a;if(e.sign&&s++,268435456>>m,l=30-m;l>=a;)f[d--]=c.__kConversionChars[u&i],u>>>=a,l-=a}var v=(u|o<>>a-l;0!==u;)f[d--]=c.__kConversionChars[u&i],u>>>=a;if(e.sign&&(f[d--]="-"),-1!==d)throw new Error("implementation bug");return f.join("")}},{key:"__toStringGeneric",value:function(e,t,r){var n=e.length;if(0===n)return"";if(1===n){var a=e.__unsignedDigit(0).toString(t);return!1===r&&e.sign&&(a="-"+a),a}var i,o,s=30*n-c.__clz30(e.__digit(n-1)),f=c.__kMaxBitsPerChar[t]-1,d=s*c.__kBitsPerCharTableMultiplier,u=1+(d=0|(d+=f-1)/f)>>1,l=c.exponentiate(c.__oneDigit(t,!1),c.__oneDigit(u,!1)),b=l.__unsignedDigit(0);if(1===l.length&&32767>=b){(i=new c(e.length,!1)).__initializeDigits();for(var h,p=0,m=2*e.length-1;0<=m;m--)h=p<<15|e.__halfDigit(m),i.__setHalfDigit(m,0|h/b),p=0|h%b;o=p.toString(t)}else{var v=c.__absoluteDivLarge(e,l,!0,!0);i=v.quotient;var g=v.remainder.__trim();o=c.__toStringGeneric(g,t,!0)}i.__trim();for(var x=c.__toStringGeneric(i,t,!0);o.lengthn?c.__absoluteLess(r):0}},{key:"__compareToNumber",value:function(e,r){if(c.__isOneDigitInt(r)){var n=e.sign,a=0>r;if(n!==a)return c.__unequalSign(n);if(0===e.length){if(a)throw new Error("implementation bug");return 0===r?0:-1}if(1i?c.__absoluteGreater(n):ot)return c.__unequalSign(r);if(0===t)throw new Error("implementation bug: should be handled elsewhere");if(0===e.length)return-1;c.__kBitConversionDouble[0]=t;var n=2047&c.__kBitConversionInts[1]>>>20;if(2047==n)throw new Error("implementation bug: handled elsewhere");var a=n-1023;if(0>a)return c.__absoluteGreater(r);var i=e.length,o=e.__digit(i-1),s=c.__clz30(o),f=30*i-s,d=a+1;if(fd)return c.__absoluteGreater(r);var u=1048576|1048575&c.__kBitConversionInts[1],l=c.__kBitConversionInts[0],b=29-s;if(b!==(0|(f-1)%30))throw new Error("implementation bug");var h,p=0;if(b<20){var m=20-b;p=m+32,h=u>>>m,u=u<<32-m|l>>>m,l<<=32-m}else if(20===b)p=32,h=u,u=l,l=0;else{var v=b-20;p=32-v,h=u<>>32-v,u=l<>>=0)>(h>>>=0))return c.__absoluteGreater(r);if(o>>2,u=u<<30|l>>>2,l<<=30):h=0;var x=e.__unsignedDigit(g);if(x>h)return c.__absoluteGreater(r);if(xr&&e.__unsignedDigit(0)===t(r):0===c.__compareToDouble(e,r)}},{key:"__comparisonResultToBool",value:function(e,t){return 0===t?0>e:1===t?0>=e:2===t?0t;case 3:return e>=t}if(c.__isBigInt(e)&&"string"==typeof t)return null!==(t=c.__fromString(t))&&c.__comparisonResultToBool(c.__compareToBigInt(e,t),r);if("string"==typeof e&&c.__isBigInt(t))return null!==(e=c.__fromString(e))&&c.__comparisonResultToBool(c.__compareToBigInt(e,t),r);if(e=c.__toNumeric(e),t=c.__toNumeric(t),c.__isBigInt(e)){if(c.__isBigInt(t))return c.__comparisonResultToBool(c.__compareToBigInt(e,t),r);if("number"!=typeof t)throw new Error("implementation bug");return c.__comparisonResultToBool(c.__compareToNumber(e,t),r)}if("number"!=typeof e)throw new Error("implementation bug");if(c.__isBigInt(t))return c.__comparisonResultToBool(c.__compareToNumber(t,e),2^r);if("number"!=typeof t)throw new Error("implementation bug");return 0===r?et:3===r?e>=t:void 0}},{key:"__absoluteAdd",value:function(e,t,r){if(e.length>>30,i.__setDigit(s,1073741823&a);for(;s>>30,i.__setDigit(s,1073741823&f)}return s>>30,a.__setDigit(o,1073741823&n);for(;o>>30,a.__setDigit(o,1073741823&s)}return a.__trim()}},{key:"__absoluteAddOne",value:function(e,t){var r=2>>30,r.__setDigit(o,1073741823&a);return 0!==i&&r.__setDigitGrow(n,1),r}},{key:"__absoluteSubOne",value:function(e,t){for(var r,n=e.length,a=new c(t=t||n,!1),i=1,o=0;o>>30,a.__setDigit(o,1073741823&r);if(0!==i)throw new Error("implementation bug");for(var s=n;sn?0:e.__unsignedDigit(n)>t.__unsignedDigit(n)?1:-1}},{key:"__multiplyAccumulate",value:function(e,t,r,n){if(0!==t){for(var a=32767&t,i=t>>>15,o=0,s=0,f=0;f>>15,h=c.__imul(l,a),p=c.__imul(l,i),m=c.__imul(b,a);o=(d+=s+h+o)>>>30,d&=1073741823,o+=(d+=((32767&p)<<15)+((32767&m)<<15))>>>30,s=c.__imul(b,i)+(p>>>15)+(m>>>15),r.__setDigit(n,1073741823&d)}for(;0!==o||0!==s;n++){var v=r.__digit(n);v+=o+s,s=0,o=v>>>30,r.__setDigit(n,1073741823&v)}}}},{key:"__internalMultiplyAdd",value:function(e,t,r,n,a){for(var i=r,o=0,s=0;s>>15,t),l=d+((32767&u)<<15)+o+i;i=l>>>30,o=u>>>15,a.__setDigit(s,1073741823&l)}if(a.length>n)for(a.__setDigit(n++,i+o);n>>0,o=0|i/t,s=0|(i=((n=0|i%t)<<15|e.__halfDigit(a-1))>>>0)/t;n=0|i%t,r.__setDigit(a>>>1,o<<15|s)}return r}},{key:"__absoluteModSmall",value:function(e,t){for(var r=0,n=2*e.length-1;0<=n;n--)r=0|((r<<15|e.__halfDigit(n))>>>0)%t;return r}},{key:"__absoluteDivLarge",value:function(e,t,r,n){var a=t.__halfDigitLength(),i=t.length,o=e.__halfDigitLength()-a,s=null;r&&(s=new c(o+2>>>1,!1)).__initializeDigits();var f=new c(a+2>>>1,!1);f.__initializeDigits();var d=c.__clz15(t.__halfDigit(a-1));0>>0;p=0|v/l;for(var g=0|v%l,x=t.__halfDigit(a-2),y=u.__halfDigit(h+a-2);c.__imul(p,x)>>>0>(g<<16|y)>>>0&&(p--,!(32767<(g+=l))););}c.__internalMultiplyAdd(t,p,0,i,f);var w=u.__inplaceSub(f,h,a+1);0!==w&&(w=u.__inplaceAdd(t,h,a),u.__setHalfDigit(h+a,32767&u.__halfDigit(h+a)+w),p--),r&&(1&h?b=p<<15:s.__setDigit(h>>>1,b|p))}if(n)return u.__inplaceRightShift(d),r?{quotient:s,remainder:u}:u;if(r)return s;throw new Error("unreachable")}},{key:"__clz15",value:function(e){return c.__clz30(e)-15}},{key:"__specialLeftShift",value:function(e,t,r){var n=e.length,a=new c(n+r,!1);if(0===t){for(var i=0;i>>30-t;return 0r)throw new RangeError("BigInt too big");var n=0|r/30,a=r%30,i=e.length,o=0!==a&&0!=e.__digit(i-1)>>>30-a,s=i+n+(o?1:0),f=new c(s,e.sign);if(0===a){for(var d=0;d>>30-a;if(o)f.__setDigit(i+n,u);else if(0!==u)throw new Error("implementation bug")}return f.__trim()}},{key:"__rightShiftByAbsolute",value:function(e,t){var r=e.length,n=e.sign,a=c.__toShiftAmount(t);if(0>a)return c.__rightShiftByMaximum(n);var i=0|a/30,o=a%30,s=r-i;if(0>=s)return c.__rightShiftByMaximum(n);var f=!1;if(n)if(0!=(e.__digit(i)&(1<>>o,p=r-i-1,m=0;m>>o;u.__setDigit(p,h)}return f&&(u=c.__absoluteAddOne(u,!0,u)),u.__trim()}},{key:"__rightShiftByMaximum",value:function(e){return e?c.__oneDigit(1,!0):c.__zero()}},{key:"__toShiftAmount",value:function(e){if(1c.__kMaxLengthBits?-1:t}},{key:"__toPrimitive",value:function(e){var t=1>>s}return n.__setDigit(a,o),n.__trim()}},{key:"__truncateAndSubFromPowerOfTwo",value:function(e,t,r){for(var n,a=Math.min,i=0|(e+29)/30,o=new c(i,r),s=0,f=i-1,d=0,u=a(f,t.length);s>>30,o.__setDigit(s,1073741823&n);for(;s>>p)-d,l&=m-1}return o.__setDigit(f,l),o.__trim()}},{key:"__digitPow",value:function(e,t){for(var r=1;0>>=1,e*=e;return r}},{key:"__isOneDigitInt",value:function(e){return(1073741823&e)===e}}]),c}(d(Array));return m.__kMaxLength=33554432,m.__kMaxLengthBits=m.__kMaxLength<<5,m.__kMaxBitsPerChar=[0,0,32,51,64,75,83,90,96,102,107,111,115,119,122,126,128,131,134,136,139,141,143,145,147,149,151,153,154,156,158,159,160,162,163,165,166],m.__kBitsPerCharTableShift=5,m.__kBitsPerCharTableMultiplier=1<>>0)/t)},m.__imul=e||function(e,t){return 0|e*t},m}()},function(e,t,r){"use strict";function n(){return(n=Object.assign||function(e){for(var t=1;t1?t-1:0),o=1;o0&&void 0!==arguments[0]?arguments[0]:{};p=l({},p,{},e)}(e.options.react),function(e){b=e}(e)}};function k(){if(console&&console.warn){for(var e,t=arguments.length,r=new Array(t),n=0;n1&&void 0!==arguments[1]?arguments[1]:{},r=t.i18n,n=Object(i.useContext)(m),a=v()&&n||{},o=a.i18n,c=a.defaultNS,s=r||o||y();if(s&&!s.reportNamespaces&&(s.reportNamespaces=new x),!s){M("You will need pass in an i18next instance by using initReactI18next");var f=[function(e){return e},{},!1];return f.t=function(e){return e},f.i18n={},f.ready=!1,f}var d=j({},g(),{},s.options.react),u=t.useSuspense,l=void 0===u?d.useSuspense:u,b=e||c||s.options&&s.options.defaultNS;b="string"===typeof b?[b]:b||["translation"],s.reportNamespaces.addUsedNamespaces&&s.reportNamespaces.addUsedNamespaces(b);var h=(s.isInitialized||s.initializedStoreOnce)&&b.every((function(e){return E(e,s)}));function p(){return{t:s.getFixedT(null,"fallback"===d.nsMode?b:b[0])}}var w=Object(i.useState)(p()),k=A()(w,2),_=k[0],O=k[1];Object(i.useEffect)((function(){var e=!0,t=d.bindI18n,r=d.bindI18nStore;function n(){e&&O(p())}return h||l||S(s,b,(function(){e&&O(p())})),t&&s&&s.on(t,n),r&&s&&s.store.on(r,n),function(){e=!1,t&&s&&t.split(" ").forEach((function(e){return s.off(e,n)})),r&&s&&r.split(" ").forEach((function(e){return s.store.off(e,n)}))}}),[b.join()]);var T=[_.t,s,h];if(T.t=_.t,T.i18n=s,T.ready=h,h)return T;if(!h&&!l)return T;throw new Promise((function(e){S(s,b,(function(){O(p()),e()}))}))}r(544)},function(e,t,r){"use strict";function n(e,t,r,n,a,i,o){try{var c=e[i](o),s=c.value}catch(f){return void r(f)}c.done?t(s):Promise.resolve(s).then(n,a)}function a(e){return function(){var t=this,r=arguments;return new Promise((function(a,i){var o=e.apply(t,r);function c(e){n(o,a,i,c,s,"next",e)}function s(e){n(o,a,i,c,s,"throw",e)}c(void 0)}))}}r.d(t,"a",(function(){return a}))},function(e,t,r){"use strict";function n(e){for(var t=arguments.length,r=Array(t>1?t-1:0),n=1;n3?t.i-4:t.i:Array.isArray(e)?1:l(e)?2:b(e)?3:0}function s(e,t){return 2===c(e)?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function f(e,t){return 2===c(e)?e.get(t):e[t]}function d(e,t,r){var n=c(e);2===n?e.set(t,r):3===n?(e.delete(t),e.add(r)):e[t]=r}function u(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}function l(e){return H&&e instanceof Map}function b(e){return q&&e instanceof Set}function h(e){return e.o||e.t}function p(e){if(Array.isArray(e))return Array.prototype.slice.call(e);var t=Z(e);delete t[X];for(var r=W(t),n=0;n1&&(e.set=e.add=e.clear=e.delete=v),Object.freeze(e),t&&o(e,(function(e,t){return m(t,!0)}),!0)),e}function v(){n(2)}function g(e){return null==e||"object"!=typeof e||Object.isFrozen(e)}function x(e){var t=$[e];return t||n(18,e),t}function y(e,t){$[e]||($[e]=t)}function w(){return U}function k(e,t){t&&(x("Patches"),e.u=[],e.s=[],e.v=t)}function _(e){M(e),e.p.forEach(E),e.p=null}function M(e){e===U&&(U=e.l)}function S(e){return U={p:[],l:U,h:e,m:!0,_:0}}function E(e){var t=e[X];0===t.i||1===t.i?t.j():t.O=!0}function O(e,t){t._=t.p.length;var r=t.p[0],a=void 0!==e&&e!==r;return t.h.g||x("ES5").S(t,e,a),a?(r[X].P&&(_(t),n(4)),i(e)&&(e=A(t,e),t.l||j(t,e)),t.u&&x("Patches").M(r[X].t,e,t.u,t.s)):e=A(t,r,[]),_(t),t.u&&t.v(t.u,t.s),e!==V?e:void 0}function A(e,t,r){if(g(t))return t;var n=t[X];if(!n)return o(t,(function(a,i){return T(e,n,t,a,i,r)}),!0),t;if(n.A!==e)return t;if(!n.P)return j(e,n.t,!0),n.t;if(!n.I){n.I=!0,n.A._--;var a=4===n.i||5===n.i?n.o=p(n.k):n.o;o(3===n.i?new Set(a):a,(function(t,i){return T(e,n,a,t,i,r)})),j(e,a,!1),r&&e.u&&x("Patches").R(n,r,e.u,e.s)}return n.o}function T(e,t,r,n,o,c){if(a(o)){var f=A(e,o,c&&t&&3!==t.i&&!s(t.D,n)?c.concat(n):void 0);if(d(r,n,f),!a(f))return;e.m=!1}if(i(o)&&!g(o)){if(!e.h.F&&e._<1)return;A(e,o),t&&t.A.l||j(e,o)}}function j(e,t,r){void 0===r&&(r=!1),e.h.F&&e.m&&m(t,r)}function P(e,t){var r=e[X];return(r?h(r):e)[t]}function C(e,t){if(t in e)for(var r=Object.getPrototypeOf(e);r;){var n=Object.getOwnPropertyDescriptor(r,t);if(n)return n;r=Object.getPrototypeOf(r)}}function R(e){e.P||(e.P=!0,e.l&&R(e.l))}function N(e){e.o||(e.o=p(e.t))}function B(e,t,r){var n=l(t)?x("MapSet").N(t,r):b(t)?x("MapSet").T(t,r):e.g?function(e,t){var r=Array.isArray(e),n={i:r?1:0,A:t?t.A:w(),P:!1,I:!1,D:{},l:t,t:e,k:null,o:null,j:null,C:!1},a=n,i=Q;r&&(a=[n],i=Y);var o=Proxy.revocable(a,i),c=o.revoke,s=o.proxy;return n.k=s,n.j=c,s}(t,r):x("ES5").J(t,r);return(r?r.A:w()).p.push(n),n}function L(e){return a(e)||n(22,e),function e(t){if(!i(t))return t;var r,n=t[X],a=c(t);if(n){if(!n.P&&(n.i<4||!x("ES5").K(n)))return n.t;n.I=!0,r=I(t,a),n.I=!1}else r=I(t,a);return o(r,(function(t,a){n&&f(n.t,t)===a||d(r,t,e(a))})),3===a?new Set(r):r}(e)}function I(e,t){switch(t){case 2:return new Map(e);case 3:return Array.from(e)}return p(e)}function F(){function e(e,t){var r=i[e];return r?r.enumerable=t:i[e]=r={configurable:!0,enumerable:t,get:function(){var t=this[X];return Q.get(t,e)},set:function(t){var r=this[X];Q.set(r,e,t)}},r}function t(e){for(var t=e.length-1;t>=0;t--){var a=e[t][X];if(!a.P)switch(a.i){case 5:n(a)&&R(a);break;case 4:r(a)&&R(a)}}}function r(e){for(var t=e.t,r=e.k,n=W(r),a=n.length-1;a>=0;a--){var i=n[a];if(i!==X){var o=t[i];if(void 0===o&&!s(t,i))return!0;var c=r[i],f=c&&c[X];if(f?f.t!==o:!u(c,o))return!0}}var d=!!t[X];return n.length!==W(t).length+(d?0:1)}function n(e){var t=e.k;if(t.length!==e.t.length)return!0;var r=Object.getOwnPropertyDescriptor(t,t.length-1);if(r&&!r.get)return!0;for(var n=0;n1?n-1:0),i=1;i1?n-1:0),i=1;i=0;r--){var n=t[r];if(0===n.path.length&&"replace"===n.op){e=n.value;break}}r>-1&&(t=t.slice(r+1));var i=x("Patches").$;return a(e)?i(e,t):this.produce(e,(function(e){return i(e,t)}))},e}()),te=ee.produce,re=(ee.produceWithPatches.bind(ee),ee.setAutoFreeze.bind(ee),ee.setUseProxies.bind(ee),ee.applyPatches.bind(ee),ee.createDraft.bind(ee),ee.finishDraft.bind(ee),te);var ne=r(26);function ae(e){return"Minified Redux error #"+e+"; visit https://redux.js.org/Errors?code="+e+" for the full message or use the non-minified dev environment for full errors. "}var ie="function"===typeof Symbol&&Symbol.observable||"@@observable",oe=function(){return Math.random().toString(36).substring(7).split("").join(".")},ce={INIT:"@@redux/INIT"+oe(),REPLACE:"@@redux/REPLACE"+oe(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+oe()}};function se(e){if("object"!==typeof e||null===e)return!1;for(var t=e;null!==Object.getPrototypeOf(t);)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t}function fe(e,t,r){var n;if("function"===typeof t&&"function"===typeof r||"function"===typeof r&&"function"===typeof arguments[3])throw new Error(ae(0));if("function"===typeof t&&"undefined"===typeof r&&(r=t,t=void 0),"undefined"!==typeof r){if("function"!==typeof r)throw new Error(ae(1));return r(fe)(e,t)}if("function"!==typeof e)throw new Error(ae(2));var a=e,i=t,o=[],c=o,s=!1;function f(){c===o&&(c=o.slice())}function d(){if(s)throw new Error(ae(3));return i}function u(e){if("function"!==typeof e)throw new Error(ae(4));if(s)throw new Error(ae(5));var t=!0;return f(),c.push(e),function(){if(t){if(s)throw new Error(ae(6));t=!1,f();var r=c.indexOf(e);c.splice(r,1),o=null}}}function l(e){if(!se(e))throw new Error(ae(7));if("undefined"===typeof e.type)throw new Error(ae(8));if(s)throw new Error(ae(9));try{s=!0,i=a(i,e)}finally{s=!1}for(var t=o=c,r=0;r=o())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+o().toString(16)+" bytes");return 0|e}function h(e,t){if(s.isBuffer(e))return e.length;if("undefined"!==typeof ArrayBuffer&&"function"===typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!==typeof e&&(e=""+e);var r=e.length;if(0===r)return 0;for(var n=!1;;)switch(t){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":case void 0:return U(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return z(e).length;default:if(n)return U(e).length;t=(""+t).toLowerCase(),n=!0}}function p(e,t,r){var n=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return T(this,t,r);case"utf8":case"utf-8":return E(this,t,r);case"ascii":return O(this,t,r);case"latin1":case"binary":return A(this,t,r);case"base64":return S(this,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return j(this,t,r);default:if(n)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),n=!0}}function m(e,t,r){var n=e[t];e[t]=e[r],e[r]=n}function v(e,t,r,n,a){if(0===e.length)return-1;if("string"===typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,isNaN(r)&&(r=a?0:e.length-1),r<0&&(r=e.length+r),r>=e.length){if(a)return-1;r=e.length-1}else if(r<0){if(!a)return-1;r=0}if("string"===typeof t&&(t=s.from(t,n)),s.isBuffer(t))return 0===t.length?-1:g(e,t,r,n,a);if("number"===typeof t)return t&=255,s.TYPED_ARRAY_SUPPORT&&"function"===typeof Uint8Array.prototype.indexOf?a?Uint8Array.prototype.indexOf.call(e,t,r):Uint8Array.prototype.lastIndexOf.call(e,t,r):g(e,[t],r,n,a);throw new TypeError("val must be string, number or Buffer")}function g(e,t,r,n,a){var i,o=1,c=e.length,s=t.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(e.length<2||t.length<2)return-1;o=2,c/=2,s/=2,r/=2}function f(e,t){return 1===o?e[t]:e.readUInt16BE(t*o)}if(a){var d=-1;for(i=r;ic&&(r=c-s),i=r;i>=0;i--){for(var u=!0,l=0;la&&(n=a):n=a;var i=t.length;if(i%2!==0)throw new TypeError("Invalid hex string");n>i/2&&(n=i/2);for(var o=0;o>8,a=r%256,i.push(a),i.push(n);return i}(t,e.length-r),e,r,n)}function S(e,t,r){return 0===t&&r===e.length?n.fromByteArray(e):n.fromByteArray(e.slice(t,r))}function E(e,t,r){r=Math.min(e.length,r);for(var n=[],a=t;a239?4:f>223?3:f>191?2:1;if(a+u<=r)switch(u){case 1:f<128&&(d=f);break;case 2:128===(192&(i=e[a+1]))&&(s=(31&f)<<6|63&i)>127&&(d=s);break;case 3:i=e[a+1],o=e[a+2],128===(192&i)&&128===(192&o)&&(s=(15&f)<<12|(63&i)<<6|63&o)>2047&&(s<55296||s>57343)&&(d=s);break;case 4:i=e[a+1],o=e[a+2],c=e[a+3],128===(192&i)&&128===(192&o)&&128===(192&c)&&(s=(15&f)<<18|(63&i)<<12|(63&o)<<6|63&c)>65535&&s<1114112&&(d=s)}null===d?(d=65533,u=1):d>65535&&(d-=65536,n.push(d>>>10&1023|55296),d=56320|1023&d),n.push(d),a+=u}return function(e){var t=e.length;if(t<=4096)return String.fromCharCode.apply(String,e);var r="",n=0;for(;n0&&(e=this.toString("hex",0,r).match(/.{2}/g).join(" "),this.length>r&&(e+=" ... ")),""},s.prototype.compare=function(e,t,r,n,a){if(!s.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===r&&(r=e?e.length:0),void 0===n&&(n=0),void 0===a&&(a=this.length),t<0||r>e.length||n<0||a>this.length)throw new RangeError("out of range index");if(n>=a&&t>=r)return 0;if(n>=a)return-1;if(t>=r)return 1;if(this===e)return 0;for(var i=(a>>>=0)-(n>>>=0),o=(r>>>=0)-(t>>>=0),c=Math.min(i,o),f=this.slice(n,a),d=e.slice(t,r),u=0;ua)&&(r=a),e.length>0&&(r<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");for(var i=!1;;)switch(n){case"hex":return x(this,e,t,r);case"utf8":case"utf-8":return y(this,e,t,r);case"ascii":return w(this,e,t,r);case"latin1":case"binary":return k(this,e,t,r);case"base64":return _(this,e,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return M(this,e,t,r);default:if(i)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),i=!0}},s.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function O(e,t,r){var n="";r=Math.min(e.length,r);for(var a=t;an)&&(r=n);for(var a="",i=t;ir)throw new RangeError("Trying to access beyond buffer length")}function C(e,t,r,n,a,i){if(!s.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>a||te.length)throw new RangeError("Index out of range")}function R(e,t,r,n){t<0&&(t=65535+t+1);for(var a=0,i=Math.min(e.length-r,2);a>>8*(n?a:1-a)}function N(e,t,r,n){t<0&&(t=4294967295+t+1);for(var a=0,i=Math.min(e.length-r,4);a>>8*(n?a:3-a)&255}function B(e,t,r,n,a,i){if(r+n>e.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function L(e,t,r,n,i){return i||B(e,0,r,4),a.write(e,t,r,n,23,4),r+4}function I(e,t,r,n,i){return i||B(e,0,r,8),a.write(e,t,r,n,52,8),r+8}s.prototype.slice=function(e,t){var r,n=this.length;if((e=~~e)<0?(e+=n)<0&&(e=0):e>n&&(e=n),(t=void 0===t?n:~~t)<0?(t+=n)<0&&(t=0):t>n&&(t=n),t0&&(a*=256);)n+=this[e+--t]*a;return n},s.prototype.readUInt8=function(e,t){return t||P(e,1,this.length),this[e]},s.prototype.readUInt16LE=function(e,t){return t||P(e,2,this.length),this[e]|this[e+1]<<8},s.prototype.readUInt16BE=function(e,t){return t||P(e,2,this.length),this[e]<<8|this[e+1]},s.prototype.readUInt32LE=function(e,t){return t||P(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},s.prototype.readUInt32BE=function(e,t){return t||P(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},s.prototype.readIntLE=function(e,t,r){e|=0,t|=0,r||P(e,t,this.length);for(var n=this[e],a=1,i=0;++i=(a*=128)&&(n-=Math.pow(2,8*t)),n},s.prototype.readIntBE=function(e,t,r){e|=0,t|=0,r||P(e,t,this.length);for(var n=t,a=1,i=this[e+--n];n>0&&(a*=256);)i+=this[e+--n]*a;return i>=(a*=128)&&(i-=Math.pow(2,8*t)),i},s.prototype.readInt8=function(e,t){return t||P(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},s.prototype.readInt16LE=function(e,t){t||P(e,2,this.length);var r=this[e]|this[e+1]<<8;return 32768&r?4294901760|r:r},s.prototype.readInt16BE=function(e,t){t||P(e,2,this.length);var r=this[e+1]|this[e]<<8;return 32768&r?4294901760|r:r},s.prototype.readInt32LE=function(e,t){return t||P(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},s.prototype.readInt32BE=function(e,t){return t||P(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},s.prototype.readFloatLE=function(e,t){return t||P(e,4,this.length),a.read(this,e,!0,23,4)},s.prototype.readFloatBE=function(e,t){return t||P(e,4,this.length),a.read(this,e,!1,23,4)},s.prototype.readDoubleLE=function(e,t){return t||P(e,8,this.length),a.read(this,e,!0,52,8)},s.prototype.readDoubleBE=function(e,t){return t||P(e,8,this.length),a.read(this,e,!1,52,8)},s.prototype.writeUIntLE=function(e,t,r,n){(e=+e,t|=0,r|=0,n)||C(this,e,t,r,Math.pow(2,8*r)-1,0);var a=1,i=0;for(this[t]=255&e;++i=0&&(i*=256);)this[t+a]=e/i&255;return t+r},s.prototype.writeUInt8=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,1,255,0),s.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},s.prototype.writeUInt16LE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,2,65535,0),s.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):R(this,e,t,!0),t+2},s.prototype.writeUInt16BE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,2,65535,0),s.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):R(this,e,t,!1),t+2},s.prototype.writeUInt32LE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,4,4294967295,0),s.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):N(this,e,t,!0),t+4},s.prototype.writeUInt32BE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,4,4294967295,0),s.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):N(this,e,t,!1),t+4},s.prototype.writeIntLE=function(e,t,r,n){if(e=+e,t|=0,!n){var a=Math.pow(2,8*r-1);C(this,e,t,r,a-1,-a)}var i=0,o=1,c=0;for(this[t]=255&e;++i>0)-c&255;return t+r},s.prototype.writeIntBE=function(e,t,r,n){if(e=+e,t|=0,!n){var a=Math.pow(2,8*r-1);C(this,e,t,r,a-1,-a)}var i=r-1,o=1,c=0;for(this[t+i]=255&e;--i>=0&&(o*=256);)e<0&&0===c&&0!==this[t+i+1]&&(c=1),this[t+i]=(e/o>>0)-c&255;return t+r},s.prototype.writeInt8=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,1,127,-128),s.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},s.prototype.writeInt16LE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,2,32767,-32768),s.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):R(this,e,t,!0),t+2},s.prototype.writeInt16BE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,2,32767,-32768),s.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):R(this,e,t,!1),t+2},s.prototype.writeInt32LE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,4,2147483647,-2147483648),s.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):N(this,e,t,!0),t+4},s.prototype.writeInt32BE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),s.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):N(this,e,t,!1),t+4},s.prototype.writeFloatLE=function(e,t,r){return L(this,e,t,!0,r)},s.prototype.writeFloatBE=function(e,t,r){return L(this,e,t,!1,r)},s.prototype.writeDoubleLE=function(e,t,r){return I(this,e,t,!0,r)},s.prototype.writeDoubleBE=function(e,t,r){return I(this,e,t,!1,r)},s.prototype.copy=function(e,t,r,n){if(r||(r=0),n||0===n||(n=this.length),t>=e.length&&(t=e.length),t||(t=0),n>0&&n=this.length)throw new RangeError("sourceStart out of bounds");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),e.length-t=0;--a)e[a+t]=this[a+r];else if(i<1e3||!s.TYPED_ARRAY_SUPPORT)for(a=0;a>>=0,r=void 0===r?this.length:r>>>0,e||(e=0),"number"===typeof e)for(i=t;i55295&&r<57344){if(!a){if(r>56319){(t-=3)>-1&&i.push(239,191,189);continue}if(o+1===n){(t-=3)>-1&&i.push(239,191,189);continue}a=r;continue}if(r<56320){(t-=3)>-1&&i.push(239,191,189),a=r;continue}r=65536+(a-55296<<10|r-56320)}else a&&(t-=3)>-1&&i.push(239,191,189);if(a=null,r<128){if((t-=1)<0)break;i.push(r)}else if(r<2048){if((t-=2)<0)break;i.push(r>>6|192,63&r|128)}else if(r<65536){if((t-=3)<0)break;i.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;i.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return i}function z(e){return n.toByteArray(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(F,"")).length<2)return"";for(;e.length%4!==0;)e+="=";return e}(e))}function H(e,t,r,n){for(var a=0;a=t.length||a>=e.length);++a)t[a+r]=e[a];return a}}).call(this,r(44))},function(e,t,r){"use strict";function n(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}r.d(t,"a",(function(){return n}))},function(e,t,r){"use strict";function n(e){return(n=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}r.d(t,"a",(function(){return n}))},function(e,t){"function"===typeof Object.create?e.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}}},function(e,t,r){"use strict";function n(){return(n=Object.assign||function(e){for(var t=1;t=0&&a<1?(c=i,s=o):a>=1&&a<2?(c=o,s=i):a>=2&&a<3?(s=i,f=o):a>=3&&a<4?(s=o,f=i):a>=4&&a<5?(c=o,f=i):a>=5&&a<6&&(c=i,f=o);var d=r-i/2;return n(c+d,s+d,f+d)}var b={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"00ffff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"0000ff",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"ff00ff",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"639",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"};var h=/^#[a-fA-F0-9]{6}$/,p=/^#[a-fA-F0-9]{8}$/,m=/^#[a-fA-F0-9]{3}$/,v=/^#[a-fA-F0-9]{4}$/,g=/^rgb\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*\)$/i,x=/^rgba\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*([-+]?[0-9]*[.]?[0-9]+)\s*\)$/i,y=/^hsl\(\s*(\d{0,3}[.]?[0-9]+)\s*,\s*(\d{1,3}[.]?[0-9]?)%\s*,\s*(\d{1,3}[.]?[0-9]?)%\s*\)$/i,w=/^hsla\(\s*(\d{0,3}[.]?[0-9]+)\s*,\s*(\d{1,3}[.]?[0-9]?)%\s*,\s*(\d{1,3}[.]?[0-9]?)%\s*,\s*([-+]?[0-9]*[.]?[0-9]+)\s*\)$/i;function k(e){if("string"!==typeof e)throw new f(3);var t=function(e){if("string"!==typeof e)return e;var t=e.toLowerCase();return b[t]?"#"+b[t]:e}(e);if(t.match(h))return{red:parseInt(""+t[1]+t[2],16),green:parseInt(""+t[3]+t[4],16),blue:parseInt(""+t[5]+t[6],16)};if(t.match(p)){var r=parseFloat((parseInt(""+t[7]+t[8],16)/255).toFixed(2));return{red:parseInt(""+t[1]+t[2],16),green:parseInt(""+t[3]+t[4],16),blue:parseInt(""+t[5]+t[6],16),alpha:r}}if(t.match(m))return{red:parseInt(""+t[1]+t[1],16),green:parseInt(""+t[2]+t[2],16),blue:parseInt(""+t[3]+t[3],16)};if(t.match(v)){var n=parseFloat((parseInt(""+t[4]+t[4],16)/255).toFixed(2));return{red:parseInt(""+t[1]+t[1],16),green:parseInt(""+t[2]+t[2],16),blue:parseInt(""+t[3]+t[3],16),alpha:n}}var a=g.exec(t);if(a)return{red:parseInt(""+a[1],10),green:parseInt(""+a[2],10),blue:parseInt(""+a[3],10)};var i=x.exec(t.substring(0,50));if(i)return{red:parseInt(""+i[1],10),green:parseInt(""+i[2],10),blue:parseInt(""+i[3],10),alpha:parseFloat(""+i[4])};var o=y.exec(t);if(o){var c="rgb("+l(parseInt(""+o[1],10),parseInt(""+o[2],10)/100,parseInt(""+o[3],10)/100)+")",s=g.exec(c);if(!s)throw new f(4,t,c);return{red:parseInt(""+s[1],10),green:parseInt(""+s[2],10),blue:parseInt(""+s[3],10)}}var d=w.exec(t.substring(0,50));if(d){var u="rgb("+l(parseInt(""+d[1],10),parseInt(""+d[2],10)/100,parseInt(""+d[3],10)/100)+")",k=g.exec(u);if(!k)throw new f(4,t,u);return{red:parseInt(""+k[1],10),green:parseInt(""+k[2],10),blue:parseInt(""+k[3],10),alpha:parseFloat(""+d[4])}}throw new f(5)}function _(e){return function(e){var t,r=e.red/255,n=e.green/255,a=e.blue/255,i=Math.max(r,n,a),o=Math.min(r,n,a),c=(i+o)/2;if(i===o)return void 0!==e.alpha?{hue:0,saturation:0,lightness:c,alpha:e.alpha}:{hue:0,saturation:0,lightness:c};var s=i-o,f=c>.5?s/(2-i-o):s/(i+o);switch(i){case r:t=(n-a)/s+(n=1?A(e,t,r):"rgba("+l(e,t,r)+","+n+")";if("object"===typeof e&&void 0===t&&void 0===r&&void 0===n)return e.alpha>=1?A(e.hue,e.saturation,e.lightness):"rgba("+l(e.hue,e.saturation,e.lightness)+","+e.alpha+")";throw new f(2)}function P(e,t,r){if("number"===typeof e&&"number"===typeof t&&"number"===typeof r)return M("#"+S(e)+S(t)+S(r));if("object"===typeof e&&void 0===t&&void 0===r)return M("#"+S(e.red)+S(e.green)+S(e.blue));throw new f(6)}function C(e,t,r,n){if("string"===typeof e&&"number"===typeof t){var a=k(e);return"rgba("+a.red+","+a.green+","+a.blue+","+t+")"}if("number"===typeof e&&"number"===typeof t&&"number"===typeof r&&"number"===typeof n)return n>=1?P(e,t,r):"rgba("+e+","+t+","+r+","+n+")";if("object"===typeof e&&void 0===t&&void 0===r&&void 0===n)return e.alpha>=1?P(e.red,e.green,e.blue):"rgba("+e.red+","+e.green+","+e.blue+","+e.alpha+")";throw new f(7)}function R(e){if("object"!==typeof e)throw new f(8);if(function(e){return"number"===typeof e.red&&"number"===typeof e.green&&"number"===typeof e.blue&&"number"===typeof e.alpha}(e))return C(e);if(function(e){return"number"===typeof e.red&&"number"===typeof e.green&&"number"===typeof e.blue&&("number"!==typeof e.alpha||"undefined"===typeof e.alpha)}(e))return P(e);if(function(e){return"number"===typeof e.hue&&"number"===typeof e.saturation&&"number"===typeof e.lightness&&"number"===typeof e.alpha}(e))return j(e);if(function(e){return"number"===typeof e.hue&&"number"===typeof e.saturation&&"number"===typeof e.lightness&&("number"!==typeof e.alpha||"undefined"===typeof e.alpha)}(e))return T(e);throw new f(8)}function N(e){return function e(t,r,n){return function(){var a=n.concat(Array.prototype.slice.call(arguments));return a.length>=r?t.apply(this,a):e(t,r,a)}}(e,e.length,[])}function B(e,t,r){return Math.max(e,Math.min(t,r))}function L(e,t){if("transparent"===t)return t;var r=_(t);return R(n({},r,{lightness:B(0,1,r.lightness-parseFloat(e))}))}var I=N(L);function F(e,t){if("transparent"===t)return t;var r=_(t);return R(n({},r,{lightness:B(0,1,r.lightness+parseFloat(e))}))}var D=N(F);function U(e,t,r){if("transparent"===t)return r;if("transparent"===r)return t;if(0===e)return r;var a=k(t),i=n({},a,{alpha:"number"===typeof a.alpha?a.alpha:1}),o=k(r),c=n({},o,{alpha:"number"===typeof o.alpha?o.alpha:1}),s=i.alpha-c.alpha,f=2*parseFloat(e)-1,d=((f*s===-1?f:f+s)/(1+f*s)+1)/2,u=1-d;return C({red:Math.floor(i.red*d+c.red*u),green:Math.floor(i.green*d+c.green*u),blue:Math.floor(i.blue*d+c.blue*u),alpha:i.alpha*parseFloat(e)+c.alpha*(1-parseFloat(e))})}var z=N(U);function H(e,t){return"transparent"===t?t:z(parseFloat(e),"rgb(0, 0, 0)",t)}var q=N(H);function J(e,t){if("transparent"===t)return t;var r=k(t);return C(n({},r,{alpha:B(0,1,+(100*("number"===typeof r.alpha?r.alpha:1)-100*parseFloat(e)).toFixed(2)/100)}))}var V=N(J)},function(e,t,r){"use strict";r.d(t,"a",(function(){return i}));var n=r(216);var a=r(184);function i(e){return function(e){if(Array.isArray(e))return Object(n.a)(e)}(e)||function(e){if("undefined"!==typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||Object(a.a)(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}},function(e,t,r){"use strict";r.d(t,"a",(function(){return a}));var n=r(32);function a(e,t,r){return(a="undefined"!==typeof Reflect&&Reflect.get?Reflect.get:function(e,t,r){var a=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Object(n.a)(e)););return e}(e,t);if(a){var i=Object.getOwnPropertyDescriptor(a,t);return i.get?i.get.call(r):i.value}})(e,t,r||e)}},,function(e,t,r){"use strict";r.d(t,"a",(function(){return p})),r.d(t,"b",(function(){return m})),r.d(t,"c",(function(){return v}));var n=r(5),a=r(46),i=r(40),o=r(104),c=new(r(11).a)("address/5.5.0");function s(e){Object(n.k)(e,20)||c.throwArgumentError("invalid address","address",e);for(var t=(e=e.toLowerCase()).substring(2).split(""),r=new Uint8Array(40),a=0;a<40;a++)r[a]=t[a].charCodeAt(0);for(var o=Object(n.a)(Object(i.a)(r)),s=0;s<40;s+=2)o[s>>1]>>4>=8&&(t[s]=t[s].toUpperCase()),(15&o[s>>1])>=8&&(t[s+1]=t[s+1].toUpperCase());return"0x"+t.join("")}for(var f={},d=0;d<10;d++)f[String(d)]=String(d);for(var u=0;u<26;u++)f[String.fromCharCode(65+u)]=String(10+u);var l,b=Math.floor((l=9007199254740991,Math.log10?Math.log10(l):Math.log(l)/Math.LN10));function h(e){for(var t=(e=(e=e.toUpperCase()).substring(4)+e.substring(0,2)+"00").split("").map((function(e){return f[e]})).join("");t.length>=b;){var r=t.substring(0,b);t=parseInt(r,10)%97+t.substring(r.length)}for(var n=String(98-parseInt(t,10)%97);n.length<2;)n="0"+n;return n}function p(e){var t=null;if("string"!==typeof e&&c.throwArgumentError("invalid address","address",e),e.match(/^(0x)?[0-9a-fA-F]{40}$/))"0x"!==e.substring(0,2)&&(e="0x"+e),t=s(e),e.match(/([A-F].*[a-f])|([a-f].*[A-F])/)&&t!==e&&c.throwArgumentError("bad address checksum","address",e);else if(e.match(/^XE[0-9]{2}[0-9A-Za-z]{30,31}$/)){for(e.substring(2,4)!==h(e)&&c.throwArgumentError("bad icap checksum","address",e),t=Object(a.c)(e.substring(4));t.length<40;)t="0"+t;t=s("0x"+t)}else c.throwArgumentError("invalid address","address",e);return t}function m(e){var t=null;try{t=p(e.from)}catch(s){c.throwArgumentError("missing from address","transaction",e)}var r=Object(n.n)(Object(n.a)(a.a.from(e.nonce).toHexString()));return p(Object(n.e)(Object(i.a)(Object(o.b)([t,r])),12))}function v(e,t,r){return 32!==Object(n.d)(t)&&c.throwArgumentError("salt must be 32 bytes","salt",t),32!==Object(n.d)(r)&&c.throwArgumentError("initCodeHash must be 32 bytes","initCodeHash",r),p(Object(n.e)(Object(i.a)(Object(n.b)(["0xff",p(e),t,r])),12))}},function(e,t,r){(function(e){!function(e,t){"use strict";function n(e,t){if(!e)throw new Error(t||"Assertion failed")}function a(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function i(e,t,r){if(i.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var o;"object"===typeof e?e.exports=i:t.BN=i,i.BN=i,i.wordSize=26;try{o="undefined"!==typeof window&&"undefined"!==typeof window.Buffer?window.Buffer:r(909).Buffer}catch(S){}function c(e,t){var r=e.charCodeAt(t);return r>=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function s(e,t,r){var n=c(e,r);return r-1>=t&&(n|=c(e,r-1)<<4),n}function f(e,t,r,n){for(var a=0,i=Math.min(e.length,r),o=t;o=49?c-49+10:c>=17?c-17+10:c}return a}i.isBN=function(e){return e instanceof i||null!==e&&"object"===typeof e&&e.constructor.wordSize===i.wordSize&&Array.isArray(e.words)},i.max=function(e,t){return e.cmp(t)>0?e:t},i.min=function(e,t){return e.cmp(t)<0?e:t},i.prototype._init=function(e,t,r){if("number"===typeof e)return this._initNumber(e,t,r);if("object"===typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var a=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(a++,this.negative=1),a=0;a-=3)o=e[a]|e[a-1]<<8|e[a-2]<<16,this.words[i]|=o<>>26-c&67108863,(c+=24)>=26&&(c-=26,i++);else if("le"===r)for(a=0,i=0;a>>26-c&67108863,(c+=24)>=26&&(c-=26,i++);return this.strip()},i.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)a=s(e,t,n)<=18?(i-=18,o+=1,this.words[o]|=a>>>26):i+=8;else for(n=(e.length-t)%2===0?t+1:t;n=18?(i-=18,o+=1,this.words[o]|=a>>>26):i+=8;this.strip()},i.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,a=1;a<=67108863;a*=t)n++;n--,a=a/t|0;for(var i=e.length-r,o=i%n,c=Math.min(i,i-o)+r,s=0,d=r;d1&&0===this.words[this.length-1];)this.length--;return this._normSign()},i.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},i.prototype.inspect=function(){return(this.red?""};var d=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],u=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],l=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];function b(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var a=0|e.words[0],i=0|t.words[0],o=a*i,c=67108863&o,s=o/67108864|0;r.words[0]=c;for(var f=1;f>>26,u=67108863&s,l=Math.min(f,t.length-1),b=Math.max(0,f-e.length+1);b<=l;b++){var h=f-b|0;d+=(o=(a=0|e.words[h])*(i=0|t.words[b])+u)/67108864|0,u=67108863&o}r.words[f]=0|u,s=0|d}return 0!==s?r.words[f]=0|s:r.length--,r.strip()}i.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var a=0,i=0,o=0;o>>24-a&16777215)||o!==this.length-1?d[6-s.length]+s+r:s+r,(a+=2)>=26&&(a-=26,o--)}for(0!==i&&(r=i.toString(16)+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var f=u[e],b=l[e];r="";var h=this.clone();for(h.negative=0;!h.isZero();){var p=h.modn(b).toString(e);r=(h=h.idivn(b)).isZero()?p+r:d[f-p.length]+p+r}for(this.isZero()&&(r="0"+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},i.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},i.prototype.toJSON=function(){return this.toString(16)},i.prototype.toBuffer=function(e,t){return n("undefined"!==typeof o),this.toArrayLike(o,e,t)},i.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},i.prototype.toArrayLike=function(e,t,r){var a=this.byteLength(),i=r||Math.max(1,a);n(a<=i,"byte array longer than desired length"),n(i>0,"Requested array length <= 0"),this.strip();var o,c,s="le"===t,f=new e(i),d=this.clone();if(s){for(c=0;!d.isZero();c++)o=d.andln(255),d.iushrn(8),f[c]=o;for(;c=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},i.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0===(8191&t)&&(r+=13,t>>>=13),0===(127&t)&&(r+=7,t>>>=7),0===(15&t)&&(r+=4,t>>>=4),0===(3&t)&&(r+=2,t>>>=2),0===(1&t)&&r++,r},i.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},i.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},i.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},i.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},i.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},i.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},i.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},i.prototype.inotn=function(e){n("number"===typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var a=0;a0&&(this.words[a]=~this.words[a]&67108863>>26-r),this.strip()},i.prototype.notn=function(e){return this.clone().inotn(e)},i.prototype.setn=function(e,t){n("number"===typeof e&&e>=0);var r=e/26|0,a=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var a=0,i=0;i>>26;for(;0!==a&&i>>26;if(this.length=r.length,0!==a)this.words[this.length]=a,this.length++;else if(r!==this)for(;ie.length?this.clone().iadd(e):e.clone().iadd(this)},i.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,a=this.cmp(e);if(0===a)return this.negative=0,this.length=1,this.words[0]=0,this;a>0?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>26,this.words[o]=67108863&t;for(;0!==i&&o>26,this.words[o]=67108863&t;if(0===i&&o>>13,b=0|o[1],h=8191&b,p=b>>>13,m=0|o[2],v=8191&m,g=m>>>13,x=0|o[3],y=8191&x,w=x>>>13,k=0|o[4],_=8191&k,M=k>>>13,S=0|o[5],E=8191&S,O=S>>>13,A=0|o[6],T=8191&A,j=A>>>13,P=0|o[7],C=8191&P,R=P>>>13,N=0|o[8],B=8191&N,L=N>>>13,I=0|o[9],F=8191&I,D=I>>>13,U=0|c[0],z=8191&U,H=U>>>13,q=0|c[1],J=8191&q,V=q>>>13,G=0|c[2],X=8191&G,K=G>>>13,W=0|c[3],Z=8191&W,$=W>>>13,Q=0|c[4],Y=8191&Q,ee=Q>>>13,te=0|c[5],re=8191&te,ne=te>>>13,ae=0|c[6],ie=8191&ae,oe=ae>>>13,ce=0|c[7],se=8191&ce,fe=ce>>>13,de=0|c[8],ue=8191&de,le=de>>>13,be=0|c[9],he=8191&be,pe=be>>>13;r.negative=e.negative^t.negative,r.length=19;var me=(f+(n=Math.imul(u,z))|0)+((8191&(a=(a=Math.imul(u,H))+Math.imul(l,z)|0))<<13)|0;f=((i=Math.imul(l,H))+(a>>>13)|0)+(me>>>26)|0,me&=67108863,n=Math.imul(h,z),a=(a=Math.imul(h,H))+Math.imul(p,z)|0,i=Math.imul(p,H);var ve=(f+(n=n+Math.imul(u,J)|0)|0)+((8191&(a=(a=a+Math.imul(u,V)|0)+Math.imul(l,J)|0))<<13)|0;f=((i=i+Math.imul(l,V)|0)+(a>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(v,z),a=(a=Math.imul(v,H))+Math.imul(g,z)|0,i=Math.imul(g,H),n=n+Math.imul(h,J)|0,a=(a=a+Math.imul(h,V)|0)+Math.imul(p,J)|0,i=i+Math.imul(p,V)|0;var ge=(f+(n=n+Math.imul(u,X)|0)|0)+((8191&(a=(a=a+Math.imul(u,K)|0)+Math.imul(l,X)|0))<<13)|0;f=((i=i+Math.imul(l,K)|0)+(a>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(y,z),a=(a=Math.imul(y,H))+Math.imul(w,z)|0,i=Math.imul(w,H),n=n+Math.imul(v,J)|0,a=(a=a+Math.imul(v,V)|0)+Math.imul(g,J)|0,i=i+Math.imul(g,V)|0,n=n+Math.imul(h,X)|0,a=(a=a+Math.imul(h,K)|0)+Math.imul(p,X)|0,i=i+Math.imul(p,K)|0;var xe=(f+(n=n+Math.imul(u,Z)|0)|0)+((8191&(a=(a=a+Math.imul(u,$)|0)+Math.imul(l,Z)|0))<<13)|0;f=((i=i+Math.imul(l,$)|0)+(a>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(_,z),a=(a=Math.imul(_,H))+Math.imul(M,z)|0,i=Math.imul(M,H),n=n+Math.imul(y,J)|0,a=(a=a+Math.imul(y,V)|0)+Math.imul(w,J)|0,i=i+Math.imul(w,V)|0,n=n+Math.imul(v,X)|0,a=(a=a+Math.imul(v,K)|0)+Math.imul(g,X)|0,i=i+Math.imul(g,K)|0,n=n+Math.imul(h,Z)|0,a=(a=a+Math.imul(h,$)|0)+Math.imul(p,Z)|0,i=i+Math.imul(p,$)|0;var ye=(f+(n=n+Math.imul(u,Y)|0)|0)+((8191&(a=(a=a+Math.imul(u,ee)|0)+Math.imul(l,Y)|0))<<13)|0;f=((i=i+Math.imul(l,ee)|0)+(a>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(E,z),a=(a=Math.imul(E,H))+Math.imul(O,z)|0,i=Math.imul(O,H),n=n+Math.imul(_,J)|0,a=(a=a+Math.imul(_,V)|0)+Math.imul(M,J)|0,i=i+Math.imul(M,V)|0,n=n+Math.imul(y,X)|0,a=(a=a+Math.imul(y,K)|0)+Math.imul(w,X)|0,i=i+Math.imul(w,K)|0,n=n+Math.imul(v,Z)|0,a=(a=a+Math.imul(v,$)|0)+Math.imul(g,Z)|0,i=i+Math.imul(g,$)|0,n=n+Math.imul(h,Y)|0,a=(a=a+Math.imul(h,ee)|0)+Math.imul(p,Y)|0,i=i+Math.imul(p,ee)|0;var we=(f+(n=n+Math.imul(u,re)|0)|0)+((8191&(a=(a=a+Math.imul(u,ne)|0)+Math.imul(l,re)|0))<<13)|0;f=((i=i+Math.imul(l,ne)|0)+(a>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(T,z),a=(a=Math.imul(T,H))+Math.imul(j,z)|0,i=Math.imul(j,H),n=n+Math.imul(E,J)|0,a=(a=a+Math.imul(E,V)|0)+Math.imul(O,J)|0,i=i+Math.imul(O,V)|0,n=n+Math.imul(_,X)|0,a=(a=a+Math.imul(_,K)|0)+Math.imul(M,X)|0,i=i+Math.imul(M,K)|0,n=n+Math.imul(y,Z)|0,a=(a=a+Math.imul(y,$)|0)+Math.imul(w,Z)|0,i=i+Math.imul(w,$)|0,n=n+Math.imul(v,Y)|0,a=(a=a+Math.imul(v,ee)|0)+Math.imul(g,Y)|0,i=i+Math.imul(g,ee)|0,n=n+Math.imul(h,re)|0,a=(a=a+Math.imul(h,ne)|0)+Math.imul(p,re)|0,i=i+Math.imul(p,ne)|0;var ke=(f+(n=n+Math.imul(u,ie)|0)|0)+((8191&(a=(a=a+Math.imul(u,oe)|0)+Math.imul(l,ie)|0))<<13)|0;f=((i=i+Math.imul(l,oe)|0)+(a>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(C,z),a=(a=Math.imul(C,H))+Math.imul(R,z)|0,i=Math.imul(R,H),n=n+Math.imul(T,J)|0,a=(a=a+Math.imul(T,V)|0)+Math.imul(j,J)|0,i=i+Math.imul(j,V)|0,n=n+Math.imul(E,X)|0,a=(a=a+Math.imul(E,K)|0)+Math.imul(O,X)|0,i=i+Math.imul(O,K)|0,n=n+Math.imul(_,Z)|0,a=(a=a+Math.imul(_,$)|0)+Math.imul(M,Z)|0,i=i+Math.imul(M,$)|0,n=n+Math.imul(y,Y)|0,a=(a=a+Math.imul(y,ee)|0)+Math.imul(w,Y)|0,i=i+Math.imul(w,ee)|0,n=n+Math.imul(v,re)|0,a=(a=a+Math.imul(v,ne)|0)+Math.imul(g,re)|0,i=i+Math.imul(g,ne)|0,n=n+Math.imul(h,ie)|0,a=(a=a+Math.imul(h,oe)|0)+Math.imul(p,ie)|0,i=i+Math.imul(p,oe)|0;var _e=(f+(n=n+Math.imul(u,se)|0)|0)+((8191&(a=(a=a+Math.imul(u,fe)|0)+Math.imul(l,se)|0))<<13)|0;f=((i=i+Math.imul(l,fe)|0)+(a>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(B,z),a=(a=Math.imul(B,H))+Math.imul(L,z)|0,i=Math.imul(L,H),n=n+Math.imul(C,J)|0,a=(a=a+Math.imul(C,V)|0)+Math.imul(R,J)|0,i=i+Math.imul(R,V)|0,n=n+Math.imul(T,X)|0,a=(a=a+Math.imul(T,K)|0)+Math.imul(j,X)|0,i=i+Math.imul(j,K)|0,n=n+Math.imul(E,Z)|0,a=(a=a+Math.imul(E,$)|0)+Math.imul(O,Z)|0,i=i+Math.imul(O,$)|0,n=n+Math.imul(_,Y)|0,a=(a=a+Math.imul(_,ee)|0)+Math.imul(M,Y)|0,i=i+Math.imul(M,ee)|0,n=n+Math.imul(y,re)|0,a=(a=a+Math.imul(y,ne)|0)+Math.imul(w,re)|0,i=i+Math.imul(w,ne)|0,n=n+Math.imul(v,ie)|0,a=(a=a+Math.imul(v,oe)|0)+Math.imul(g,ie)|0,i=i+Math.imul(g,oe)|0,n=n+Math.imul(h,se)|0,a=(a=a+Math.imul(h,fe)|0)+Math.imul(p,se)|0,i=i+Math.imul(p,fe)|0;var Me=(f+(n=n+Math.imul(u,ue)|0)|0)+((8191&(a=(a=a+Math.imul(u,le)|0)+Math.imul(l,ue)|0))<<13)|0;f=((i=i+Math.imul(l,le)|0)+(a>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,z),a=(a=Math.imul(F,H))+Math.imul(D,z)|0,i=Math.imul(D,H),n=n+Math.imul(B,J)|0,a=(a=a+Math.imul(B,V)|0)+Math.imul(L,J)|0,i=i+Math.imul(L,V)|0,n=n+Math.imul(C,X)|0,a=(a=a+Math.imul(C,K)|0)+Math.imul(R,X)|0,i=i+Math.imul(R,K)|0,n=n+Math.imul(T,Z)|0,a=(a=a+Math.imul(T,$)|0)+Math.imul(j,Z)|0,i=i+Math.imul(j,$)|0,n=n+Math.imul(E,Y)|0,a=(a=a+Math.imul(E,ee)|0)+Math.imul(O,Y)|0,i=i+Math.imul(O,ee)|0,n=n+Math.imul(_,re)|0,a=(a=a+Math.imul(_,ne)|0)+Math.imul(M,re)|0,i=i+Math.imul(M,ne)|0,n=n+Math.imul(y,ie)|0,a=(a=a+Math.imul(y,oe)|0)+Math.imul(w,ie)|0,i=i+Math.imul(w,oe)|0,n=n+Math.imul(v,se)|0,a=(a=a+Math.imul(v,fe)|0)+Math.imul(g,se)|0,i=i+Math.imul(g,fe)|0,n=n+Math.imul(h,ue)|0,a=(a=a+Math.imul(h,le)|0)+Math.imul(p,ue)|0,i=i+Math.imul(p,le)|0;var Se=(f+(n=n+Math.imul(u,he)|0)|0)+((8191&(a=(a=a+Math.imul(u,pe)|0)+Math.imul(l,he)|0))<<13)|0;f=((i=i+Math.imul(l,pe)|0)+(a>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(F,J),a=(a=Math.imul(F,V))+Math.imul(D,J)|0,i=Math.imul(D,V),n=n+Math.imul(B,X)|0,a=(a=a+Math.imul(B,K)|0)+Math.imul(L,X)|0,i=i+Math.imul(L,K)|0,n=n+Math.imul(C,Z)|0,a=(a=a+Math.imul(C,$)|0)+Math.imul(R,Z)|0,i=i+Math.imul(R,$)|0,n=n+Math.imul(T,Y)|0,a=(a=a+Math.imul(T,ee)|0)+Math.imul(j,Y)|0,i=i+Math.imul(j,ee)|0,n=n+Math.imul(E,re)|0,a=(a=a+Math.imul(E,ne)|0)+Math.imul(O,re)|0,i=i+Math.imul(O,ne)|0,n=n+Math.imul(_,ie)|0,a=(a=a+Math.imul(_,oe)|0)+Math.imul(M,ie)|0,i=i+Math.imul(M,oe)|0,n=n+Math.imul(y,se)|0,a=(a=a+Math.imul(y,fe)|0)+Math.imul(w,se)|0,i=i+Math.imul(w,fe)|0,n=n+Math.imul(v,ue)|0,a=(a=a+Math.imul(v,le)|0)+Math.imul(g,ue)|0,i=i+Math.imul(g,le)|0;var Ee=(f+(n=n+Math.imul(h,he)|0)|0)+((8191&(a=(a=a+Math.imul(h,pe)|0)+Math.imul(p,he)|0))<<13)|0;f=((i=i+Math.imul(p,pe)|0)+(a>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,X),a=(a=Math.imul(F,K))+Math.imul(D,X)|0,i=Math.imul(D,K),n=n+Math.imul(B,Z)|0,a=(a=a+Math.imul(B,$)|0)+Math.imul(L,Z)|0,i=i+Math.imul(L,$)|0,n=n+Math.imul(C,Y)|0,a=(a=a+Math.imul(C,ee)|0)+Math.imul(R,Y)|0,i=i+Math.imul(R,ee)|0,n=n+Math.imul(T,re)|0,a=(a=a+Math.imul(T,ne)|0)+Math.imul(j,re)|0,i=i+Math.imul(j,ne)|0,n=n+Math.imul(E,ie)|0,a=(a=a+Math.imul(E,oe)|0)+Math.imul(O,ie)|0,i=i+Math.imul(O,oe)|0,n=n+Math.imul(_,se)|0,a=(a=a+Math.imul(_,fe)|0)+Math.imul(M,se)|0,i=i+Math.imul(M,fe)|0,n=n+Math.imul(y,ue)|0,a=(a=a+Math.imul(y,le)|0)+Math.imul(w,ue)|0,i=i+Math.imul(w,le)|0;var Oe=(f+(n=n+Math.imul(v,he)|0)|0)+((8191&(a=(a=a+Math.imul(v,pe)|0)+Math.imul(g,he)|0))<<13)|0;f=((i=i+Math.imul(g,pe)|0)+(a>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,Z),a=(a=Math.imul(F,$))+Math.imul(D,Z)|0,i=Math.imul(D,$),n=n+Math.imul(B,Y)|0,a=(a=a+Math.imul(B,ee)|0)+Math.imul(L,Y)|0,i=i+Math.imul(L,ee)|0,n=n+Math.imul(C,re)|0,a=(a=a+Math.imul(C,ne)|0)+Math.imul(R,re)|0,i=i+Math.imul(R,ne)|0,n=n+Math.imul(T,ie)|0,a=(a=a+Math.imul(T,oe)|0)+Math.imul(j,ie)|0,i=i+Math.imul(j,oe)|0,n=n+Math.imul(E,se)|0,a=(a=a+Math.imul(E,fe)|0)+Math.imul(O,se)|0,i=i+Math.imul(O,fe)|0,n=n+Math.imul(_,ue)|0,a=(a=a+Math.imul(_,le)|0)+Math.imul(M,ue)|0,i=i+Math.imul(M,le)|0;var Ae=(f+(n=n+Math.imul(y,he)|0)|0)+((8191&(a=(a=a+Math.imul(y,pe)|0)+Math.imul(w,he)|0))<<13)|0;f=((i=i+Math.imul(w,pe)|0)+(a>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(F,Y),a=(a=Math.imul(F,ee))+Math.imul(D,Y)|0,i=Math.imul(D,ee),n=n+Math.imul(B,re)|0,a=(a=a+Math.imul(B,ne)|0)+Math.imul(L,re)|0,i=i+Math.imul(L,ne)|0,n=n+Math.imul(C,ie)|0,a=(a=a+Math.imul(C,oe)|0)+Math.imul(R,ie)|0,i=i+Math.imul(R,oe)|0,n=n+Math.imul(T,se)|0,a=(a=a+Math.imul(T,fe)|0)+Math.imul(j,se)|0,i=i+Math.imul(j,fe)|0,n=n+Math.imul(E,ue)|0,a=(a=a+Math.imul(E,le)|0)+Math.imul(O,ue)|0,i=i+Math.imul(O,le)|0;var Te=(f+(n=n+Math.imul(_,he)|0)|0)+((8191&(a=(a=a+Math.imul(_,pe)|0)+Math.imul(M,he)|0))<<13)|0;f=((i=i+Math.imul(M,pe)|0)+(a>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,re),a=(a=Math.imul(F,ne))+Math.imul(D,re)|0,i=Math.imul(D,ne),n=n+Math.imul(B,ie)|0,a=(a=a+Math.imul(B,oe)|0)+Math.imul(L,ie)|0,i=i+Math.imul(L,oe)|0,n=n+Math.imul(C,se)|0,a=(a=a+Math.imul(C,fe)|0)+Math.imul(R,se)|0,i=i+Math.imul(R,fe)|0,n=n+Math.imul(T,ue)|0,a=(a=a+Math.imul(T,le)|0)+Math.imul(j,ue)|0,i=i+Math.imul(j,le)|0;var je=(f+(n=n+Math.imul(E,he)|0)|0)+((8191&(a=(a=a+Math.imul(E,pe)|0)+Math.imul(O,he)|0))<<13)|0;f=((i=i+Math.imul(O,pe)|0)+(a>>>13)|0)+(je>>>26)|0,je&=67108863,n=Math.imul(F,ie),a=(a=Math.imul(F,oe))+Math.imul(D,ie)|0,i=Math.imul(D,oe),n=n+Math.imul(B,se)|0,a=(a=a+Math.imul(B,fe)|0)+Math.imul(L,se)|0,i=i+Math.imul(L,fe)|0,n=n+Math.imul(C,ue)|0,a=(a=a+Math.imul(C,le)|0)+Math.imul(R,ue)|0,i=i+Math.imul(R,le)|0;var Pe=(f+(n=n+Math.imul(T,he)|0)|0)+((8191&(a=(a=a+Math.imul(T,pe)|0)+Math.imul(j,he)|0))<<13)|0;f=((i=i+Math.imul(j,pe)|0)+(a>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,se),a=(a=Math.imul(F,fe))+Math.imul(D,se)|0,i=Math.imul(D,fe),n=n+Math.imul(B,ue)|0,a=(a=a+Math.imul(B,le)|0)+Math.imul(L,ue)|0,i=i+Math.imul(L,le)|0;var Ce=(f+(n=n+Math.imul(C,he)|0)|0)+((8191&(a=(a=a+Math.imul(C,pe)|0)+Math.imul(R,he)|0))<<13)|0;f=((i=i+Math.imul(R,pe)|0)+(a>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,n=Math.imul(F,ue),a=(a=Math.imul(F,le))+Math.imul(D,ue)|0,i=Math.imul(D,le);var Re=(f+(n=n+Math.imul(B,he)|0)|0)+((8191&(a=(a=a+Math.imul(B,pe)|0)+Math.imul(L,he)|0))<<13)|0;f=((i=i+Math.imul(L,pe)|0)+(a>>>13)|0)+(Re>>>26)|0,Re&=67108863;var Ne=(f+(n=Math.imul(F,he))|0)+((8191&(a=(a=Math.imul(F,pe))+Math.imul(D,he)|0))<<13)|0;return f=((i=Math.imul(D,pe))+(a>>>13)|0)+(Ne>>>26)|0,Ne&=67108863,s[0]=me,s[1]=ve,s[2]=ge,s[3]=xe,s[4]=ye,s[5]=we,s[6]=ke,s[7]=_e,s[8]=Me,s[9]=Se,s[10]=Ee,s[11]=Oe,s[12]=Ae,s[13]=Te,s[14]=je,s[15]=Pe,s[16]=Ce,s[17]=Re,s[18]=Ne,0!==f&&(s[19]=f,r.length++),r};function p(e,t,r){return(new m).mulp(e,t,r)}function m(e,t){this.x=e,this.y=t}Math.imul||(h=b),i.prototype.mulTo=function(e,t){var r=this.length+e.length;return 10===this.length&&10===e.length?h(this,e,t):r<63?b(this,e,t):r<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,a=0,i=0;i>>26)|0)>>>26,o&=67108863}r.words[i]=c,n=o,o=a}return 0!==n?r.words[i]=n:r.length--,r.strip()}(this,e,t):p(this,e,t)},m.prototype.makeRBT=function(e){for(var t=new Array(e),r=i.prototype._countBits(e)-1,n=0;n>=1;return n},m.prototype.permute=function(e,t,r,n,a,i){for(var o=0;o>>=1)a++;return 1<>>=13,r[2*o+1]=8191&i,i>>>=13;for(o=2*t;o>=26,t+=a/67108864|0,t+=i>>>26,this.words[r]=67108863&i}return 0!==t&&(this.words[r]=t,this.length++),this},i.prototype.muln=function(e){return this.clone().imuln(e)},i.prototype.sqr=function(){return this.mul(this)},i.prototype.isqr=function(){return this.imul(this.clone())},i.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>a}return t}(e);if(0===t.length)return new i(1);for(var r=this,n=0;n=0);var t,r=e%26,a=(e-r)/26,i=67108863>>>26-r<<26-r;if(0!==r){var o=0;for(t=0;t>>26-r}o&&(this.words[t]=o,this.length++)}if(0!==a){for(t=this.length-1;t>=0;t--)this.words[t+a]=this.words[t];for(t=0;t=0),a=t?(t-t%26)/26:0;var i=e%26,o=Math.min((e-i)/26,this.length),c=67108863^67108863>>>i<o)for(this.length-=o,f=0;f=0&&(0!==d||f>=a);f--){var u=0|this.words[f];this.words[f]=d<<26-i|u>>>i,d=u&c}return s&&0!==d&&(s.words[s.length++]=d),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},i.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},i.prototype.shln=function(e){return this.clone().ishln(e)},i.prototype.ushln=function(e){return this.clone().iushln(e)},i.prototype.shrn=function(e){return this.clone().ishrn(e)},i.prototype.ushrn=function(e){return this.clone().iushrn(e)},i.prototype.testn=function(e){n("number"===typeof e&&e>=0);var t=e%26,r=(e-t)/26,a=1<=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var a=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},i.prototype.isubn=function(e){if(n("number"===typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(s/67108864|0),this.words[a+r]=67108863&i}for(;a>26,this.words[a+r]=67108863&i;if(0===c)return this.strip();for(n(-1===c),c=0,a=0;a>26,this.words[a]=67108863&i;return this.negative=1,this.strip()},i.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),a=e,o=0|a.words[a.length-1];0!==(r=26-this._countBits(o))&&(a=a.ushln(r),n.iushln(r),o=0|a.words[a.length-1]);var c,s=n.length-a.length;if("mod"!==t){(c=new i(null)).length=s+1,c.words=new Array(c.length);for(var f=0;f=0;u--){var l=67108864*(0|n.words[a.length+u])+(0|n.words[a.length+u-1]);for(l=Math.min(l/o|0,67108863),n._ishlnsubmul(a,l,u);0!==n.negative;)l--,n.negative=0,n._ishlnsubmul(a,1,u),n.isZero()||(n.negative^=1);c&&(c.words[u]=l)}return c&&c.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:c||null,mod:n}},i.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new i(0),mod:new i(0)}:0!==this.negative&&0===e.negative?(c=this.neg().divmod(e,t),"mod"!==t&&(a=c.div.neg()),"div"!==t&&(o=c.mod.neg(),r&&0!==o.negative&&o.iadd(e)),{div:a,mod:o}):0===this.negative&&0!==e.negative?(c=this.divmod(e.neg(),t),"mod"!==t&&(a=c.div.neg()),{div:a,mod:c.mod}):0!==(this.negative&e.negative)?(c=this.neg().divmod(e.neg(),t),"div"!==t&&(o=c.mod.neg(),r&&0!==o.negative&&o.isub(e)),{div:c.div,mod:o}):e.length>this.length||this.cmp(e)<0?{div:new i(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new i(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new i(this.modn(e.words[0]))}:this._wordDiv(e,t);var a,o,c},i.prototype.div=function(e){return this.divmod(e,"div",!1).div},i.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},i.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},i.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),a=e.andln(1),i=r.cmp(n);return i<0||1===a&&0===i?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},i.prototype.modn=function(e){n(e<=67108863);for(var t=(1<<26)%e,r=0,a=this.length-1;a>=0;a--)r=(t*r+(0|this.words[a]))%e;return r},i.prototype.idivn=function(e){n(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var a=(0|this.words[r])+67108864*t;this.words[r]=a/e|0,t=a%e}return this.strip()},i.prototype.divn=function(e){return this.clone().idivn(e)},i.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var a=new i(1),o=new i(0),c=new i(0),s=new i(1),f=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++f;for(var d=r.clone(),u=t.clone();!t.isZero();){for(var l=0,b=1;0===(t.words[0]&b)&&l<26;++l,b<<=1);if(l>0)for(t.iushrn(l);l-- >0;)(a.isOdd()||o.isOdd())&&(a.iadd(d),o.isub(u)),a.iushrn(1),o.iushrn(1);for(var h=0,p=1;0===(r.words[0]&p)&&h<26;++h,p<<=1);if(h>0)for(r.iushrn(h);h-- >0;)(c.isOdd()||s.isOdd())&&(c.iadd(d),s.isub(u)),c.iushrn(1),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(c),o.isub(s)):(r.isub(t),c.isub(a),s.isub(o))}return{a:c,b:s,gcd:r.iushln(f)}},i.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var a,o=new i(1),c=new i(0),s=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var f=0,d=1;0===(t.words[0]&d)&&f<26;++f,d<<=1);if(f>0)for(t.iushrn(f);f-- >0;)o.isOdd()&&o.iadd(s),o.iushrn(1);for(var u=0,l=1;0===(r.words[0]&l)&&u<26;++u,l<<=1);if(u>0)for(r.iushrn(u);u-- >0;)c.isOdd()&&c.iadd(s),c.iushrn(1);t.cmp(r)>=0?(t.isub(r),o.isub(c)):(r.isub(t),c.isub(o))}return(a=0===t.cmpn(1)?o:c).cmpn(0)<0&&a.iadd(e),a},i.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var a=t.cmp(r);if(a<0){var i=t;t=r,r=i}else if(0===a||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},i.prototype.invm=function(e){return this.egcd(e).a.umod(e)},i.prototype.isEven=function(){return 0===(1&this.words[0])},i.prototype.isOdd=function(){return 1===(1&this.words[0])},i.prototype.andln=function(e){return this.words[0]&e},i.prototype.bincn=function(e){n("number"===typeof e);var t=e%26,r=(e-t)/26,a=1<>>26,c&=67108863,this.words[o]=c}return 0!==i&&(this.words[o]=i,this.length++),this},i.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},i.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var a=0|this.words[0];t=a===e?0:ae.length)return 1;if(this.length=0;r--){var n=0|this.words[r],a=0|e.words[r];if(n!==a){na&&(t=1);break}}return t},i.prototype.gtn=function(e){return 1===this.cmpn(e)},i.prototype.gt=function(e){return 1===this.cmp(e)},i.prototype.gten=function(e){return this.cmpn(e)>=0},i.prototype.gte=function(e){return this.cmp(e)>=0},i.prototype.ltn=function(e){return-1===this.cmpn(e)},i.prototype.lt=function(e){return-1===this.cmp(e)},i.prototype.lten=function(e){return this.cmpn(e)<=0},i.prototype.lte=function(e){return this.cmp(e)<=0},i.prototype.eqn=function(e){return 0===this.cmpn(e)},i.prototype.eq=function(e){return 0===this.cmp(e)},i.red=function(e){return new _(e)},i.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},i.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},i.prototype._forceRed=function(e){return this.red=e,this},i.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},i.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},i.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},i.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},i.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},i.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},i.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},i.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},i.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},i.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},i.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},i.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},i.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},i.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var v={k256:null,p224:null,p192:null,p25519:null};function g(e,t){this.name=e,this.p=new i(t,16),this.n=this.p.bitLength(),this.k=new i(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function x(){g.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function y(){g.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function w(){g.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function k(){g.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function _(e){if("string"===typeof e){var t=i._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function M(e){_.call(this,e),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new i(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}g.prototype._tmp=function(){var e=new i(null);return e.words=new Array(Math.ceil(this.n/13)),e},g.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},g.prototype.split=function(e,t){e.iushrn(this.n,0,t)},g.prototype.imulK=function(e){return e.imul(this.k)},a(x,g),x.prototype.split=function(e,t){for(var r=Math.min(e.length,9),n=0;n>>22,a=i}a>>>=22,e.words[n-10]=a,0===a&&e.length>10?e.length-=10:e.length-=9},x.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=a,t=n}return 0!==t&&(e.words[e.length++]=t),e},i._prime=function(e){if(v[e])return v[e];var t;if("k256"===e)t=new x;else if("p224"===e)t=new y;else if("p192"===e)t=new w;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new k}return v[e]=t,t},_.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},_.prototype._verify2=function(e,t){n(0===(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},_.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},_.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},_.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},_.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},_.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},_.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},_.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},_.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},_.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},_.prototype.isqr=function(e){return this.imul(e,e.clone())},_.prototype.sqr=function(e){return this.mul(e,e)},_.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2===1),3===t){var r=this.m.add(new i(1)).iushrn(2);return this.pow(e,r)}for(var a=this.m.subn(1),o=0;!a.isZero()&&0===a.andln(1);)o++,a.iushrn(1);n(!a.isZero());var c=new i(1).toRed(this),s=c.redNeg(),f=this.m.subn(1).iushrn(1),d=this.m.bitLength();for(d=new i(2*d*d).toRed(this);0!==this.pow(d,f).cmp(s);)d.redIAdd(s);for(var u=this.pow(d,a),l=this.pow(e,a.addn(1).iushrn(1)),b=this.pow(e,a),h=o;0!==b.cmp(c);){for(var p=b,m=0;0!==p.cmp(c);m++)p=p.redSqr();n(m=0;n--){for(var f=t.words[n],d=s-1;d>=0;d--){var u=f>>d&1;a!==r[0]&&(a=this.sqr(a)),0!==u||0!==o?(o<<=1,o|=u,(4===++c||0===n&&0===d)&&(a=this.mul(a,r[o]),c=0,o=0)):c=0}s=26}return a},_.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},_.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},i.mont=function(e){return new M(e)},a(M,_),M.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},M.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},M.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),a=r.isub(n).iushrn(this.shift),i=a;return a.cmp(this.m)>=0?i=a.isub(this.m):a.cmpn(0)<0&&(i=a.iadd(this.m)),i._forceRed(this)},M.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new i(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),a=r.isub(n).iushrn(this.shift),o=a;return a.cmp(this.m)>=0?o=a.isub(this.m):a.cmpn(0)<0&&(o=a.iadd(this.m)),o._forceRed(this)},M.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e,this)}).call(this,r(74)(e))},function(e,t,r){"use strict";r.d(t,"a",(function(){return o}));var n=r(297),a=r.n(n),i=r(5);function o(e){return"0x"+a.a.keccak_256(Object(i.a)(e))}},function(e,t,r){(function(e){!function(e,t){"use strict";function n(e,t){if(!e)throw new Error(t||"Assertion failed")}function a(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function i(e,t,r){if(i.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var o;"object"===typeof e?e.exports=i:t.BN=i,i.BN=i,i.wordSize=26;try{o="undefined"!==typeof window&&"undefined"!==typeof window.Buffer?window.Buffer:r(613).Buffer}catch(S){}function c(e,t){var r=e.charCodeAt(t);return r>=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function s(e,t,r){var n=c(e,r);return r-1>=t&&(n|=c(e,r-1)<<4),n}function f(e,t,r,n){for(var a=0,i=Math.min(e.length,r),o=t;o=49?c-49+10:c>=17?c-17+10:c}return a}i.isBN=function(e){return e instanceof i||null!==e&&"object"===typeof e&&e.constructor.wordSize===i.wordSize&&Array.isArray(e.words)},i.max=function(e,t){return e.cmp(t)>0?e:t},i.min=function(e,t){return e.cmp(t)<0?e:t},i.prototype._init=function(e,t,r){if("number"===typeof e)return this._initNumber(e,t,r);if("object"===typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var a=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(a++,this.negative=1),a=0;a-=3)o=e[a]|e[a-1]<<8|e[a-2]<<16,this.words[i]|=o<>>26-c&67108863,(c+=24)>=26&&(c-=26,i++);else if("le"===r)for(a=0,i=0;a>>26-c&67108863,(c+=24)>=26&&(c-=26,i++);return this.strip()},i.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)a=s(e,t,n)<=18?(i-=18,o+=1,this.words[o]|=a>>>26):i+=8;else for(n=(e.length-t)%2===0?t+1:t;n=18?(i-=18,o+=1,this.words[o]|=a>>>26):i+=8;this.strip()},i.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,a=1;a<=67108863;a*=t)n++;n--,a=a/t|0;for(var i=e.length-r,o=i%n,c=Math.min(i,i-o)+r,s=0,d=r;d1&&0===this.words[this.length-1];)this.length--;return this._normSign()},i.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},i.prototype.inspect=function(){return(this.red?""};var d=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],u=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],l=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];function b(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var a=0|e.words[0],i=0|t.words[0],o=a*i,c=67108863&o,s=o/67108864|0;r.words[0]=c;for(var f=1;f>>26,u=67108863&s,l=Math.min(f,t.length-1),b=Math.max(0,f-e.length+1);b<=l;b++){var h=f-b|0;d+=(o=(a=0|e.words[h])*(i=0|t.words[b])+u)/67108864|0,u=67108863&o}r.words[f]=0|u,s=0|d}return 0!==s?r.words[f]=0|s:r.length--,r.strip()}i.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var a=0,i=0,o=0;o>>24-a&16777215)||o!==this.length-1?d[6-s.length]+s+r:s+r,(a+=2)>=26&&(a-=26,o--)}for(0!==i&&(r=i.toString(16)+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var f=u[e],b=l[e];r="";var h=this.clone();for(h.negative=0;!h.isZero();){var p=h.modn(b).toString(e);r=(h=h.idivn(b)).isZero()?p+r:d[f-p.length]+p+r}for(this.isZero()&&(r="0"+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},i.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},i.prototype.toJSON=function(){return this.toString(16)},i.prototype.toBuffer=function(e,t){return n("undefined"!==typeof o),this.toArrayLike(o,e,t)},i.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},i.prototype.toArrayLike=function(e,t,r){var a=this.byteLength(),i=r||Math.max(1,a);n(a<=i,"byte array longer than desired length"),n(i>0,"Requested array length <= 0"),this.strip();var o,c,s="le"===t,f=new e(i),d=this.clone();if(s){for(c=0;!d.isZero();c++)o=d.andln(255),d.iushrn(8),f[c]=o;for(;c=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},i.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0===(8191&t)&&(r+=13,t>>>=13),0===(127&t)&&(r+=7,t>>>=7),0===(15&t)&&(r+=4,t>>>=4),0===(3&t)&&(r+=2,t>>>=2),0===(1&t)&&r++,r},i.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},i.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},i.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},i.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},i.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},i.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},i.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},i.prototype.inotn=function(e){n("number"===typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var a=0;a0&&(this.words[a]=~this.words[a]&67108863>>26-r),this.strip()},i.prototype.notn=function(e){return this.clone().inotn(e)},i.prototype.setn=function(e,t){n("number"===typeof e&&e>=0);var r=e/26|0,a=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var a=0,i=0;i>>26;for(;0!==a&&i>>26;if(this.length=r.length,0!==a)this.words[this.length]=a,this.length++;else if(r!==this)for(;ie.length?this.clone().iadd(e):e.clone().iadd(this)},i.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,a=this.cmp(e);if(0===a)return this.negative=0,this.length=1,this.words[0]=0,this;a>0?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>26,this.words[o]=67108863&t;for(;0!==i&&o>26,this.words[o]=67108863&t;if(0===i&&o>>13,b=0|o[1],h=8191&b,p=b>>>13,m=0|o[2],v=8191&m,g=m>>>13,x=0|o[3],y=8191&x,w=x>>>13,k=0|o[4],_=8191&k,M=k>>>13,S=0|o[5],E=8191&S,O=S>>>13,A=0|o[6],T=8191&A,j=A>>>13,P=0|o[7],C=8191&P,R=P>>>13,N=0|o[8],B=8191&N,L=N>>>13,I=0|o[9],F=8191&I,D=I>>>13,U=0|c[0],z=8191&U,H=U>>>13,q=0|c[1],J=8191&q,V=q>>>13,G=0|c[2],X=8191&G,K=G>>>13,W=0|c[3],Z=8191&W,$=W>>>13,Q=0|c[4],Y=8191&Q,ee=Q>>>13,te=0|c[5],re=8191&te,ne=te>>>13,ae=0|c[6],ie=8191&ae,oe=ae>>>13,ce=0|c[7],se=8191&ce,fe=ce>>>13,de=0|c[8],ue=8191&de,le=de>>>13,be=0|c[9],he=8191&be,pe=be>>>13;r.negative=e.negative^t.negative,r.length=19;var me=(f+(n=Math.imul(u,z))|0)+((8191&(a=(a=Math.imul(u,H))+Math.imul(l,z)|0))<<13)|0;f=((i=Math.imul(l,H))+(a>>>13)|0)+(me>>>26)|0,me&=67108863,n=Math.imul(h,z),a=(a=Math.imul(h,H))+Math.imul(p,z)|0,i=Math.imul(p,H);var ve=(f+(n=n+Math.imul(u,J)|0)|0)+((8191&(a=(a=a+Math.imul(u,V)|0)+Math.imul(l,J)|0))<<13)|0;f=((i=i+Math.imul(l,V)|0)+(a>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(v,z),a=(a=Math.imul(v,H))+Math.imul(g,z)|0,i=Math.imul(g,H),n=n+Math.imul(h,J)|0,a=(a=a+Math.imul(h,V)|0)+Math.imul(p,J)|0,i=i+Math.imul(p,V)|0;var ge=(f+(n=n+Math.imul(u,X)|0)|0)+((8191&(a=(a=a+Math.imul(u,K)|0)+Math.imul(l,X)|0))<<13)|0;f=((i=i+Math.imul(l,K)|0)+(a>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(y,z),a=(a=Math.imul(y,H))+Math.imul(w,z)|0,i=Math.imul(w,H),n=n+Math.imul(v,J)|0,a=(a=a+Math.imul(v,V)|0)+Math.imul(g,J)|0,i=i+Math.imul(g,V)|0,n=n+Math.imul(h,X)|0,a=(a=a+Math.imul(h,K)|0)+Math.imul(p,X)|0,i=i+Math.imul(p,K)|0;var xe=(f+(n=n+Math.imul(u,Z)|0)|0)+((8191&(a=(a=a+Math.imul(u,$)|0)+Math.imul(l,Z)|0))<<13)|0;f=((i=i+Math.imul(l,$)|0)+(a>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(_,z),a=(a=Math.imul(_,H))+Math.imul(M,z)|0,i=Math.imul(M,H),n=n+Math.imul(y,J)|0,a=(a=a+Math.imul(y,V)|0)+Math.imul(w,J)|0,i=i+Math.imul(w,V)|0,n=n+Math.imul(v,X)|0,a=(a=a+Math.imul(v,K)|0)+Math.imul(g,X)|0,i=i+Math.imul(g,K)|0,n=n+Math.imul(h,Z)|0,a=(a=a+Math.imul(h,$)|0)+Math.imul(p,Z)|0,i=i+Math.imul(p,$)|0;var ye=(f+(n=n+Math.imul(u,Y)|0)|0)+((8191&(a=(a=a+Math.imul(u,ee)|0)+Math.imul(l,Y)|0))<<13)|0;f=((i=i+Math.imul(l,ee)|0)+(a>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(E,z),a=(a=Math.imul(E,H))+Math.imul(O,z)|0,i=Math.imul(O,H),n=n+Math.imul(_,J)|0,a=(a=a+Math.imul(_,V)|0)+Math.imul(M,J)|0,i=i+Math.imul(M,V)|0,n=n+Math.imul(y,X)|0,a=(a=a+Math.imul(y,K)|0)+Math.imul(w,X)|0,i=i+Math.imul(w,K)|0,n=n+Math.imul(v,Z)|0,a=(a=a+Math.imul(v,$)|0)+Math.imul(g,Z)|0,i=i+Math.imul(g,$)|0,n=n+Math.imul(h,Y)|0,a=(a=a+Math.imul(h,ee)|0)+Math.imul(p,Y)|0,i=i+Math.imul(p,ee)|0;var we=(f+(n=n+Math.imul(u,re)|0)|0)+((8191&(a=(a=a+Math.imul(u,ne)|0)+Math.imul(l,re)|0))<<13)|0;f=((i=i+Math.imul(l,ne)|0)+(a>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(T,z),a=(a=Math.imul(T,H))+Math.imul(j,z)|0,i=Math.imul(j,H),n=n+Math.imul(E,J)|0,a=(a=a+Math.imul(E,V)|0)+Math.imul(O,J)|0,i=i+Math.imul(O,V)|0,n=n+Math.imul(_,X)|0,a=(a=a+Math.imul(_,K)|0)+Math.imul(M,X)|0,i=i+Math.imul(M,K)|0,n=n+Math.imul(y,Z)|0,a=(a=a+Math.imul(y,$)|0)+Math.imul(w,Z)|0,i=i+Math.imul(w,$)|0,n=n+Math.imul(v,Y)|0,a=(a=a+Math.imul(v,ee)|0)+Math.imul(g,Y)|0,i=i+Math.imul(g,ee)|0,n=n+Math.imul(h,re)|0,a=(a=a+Math.imul(h,ne)|0)+Math.imul(p,re)|0,i=i+Math.imul(p,ne)|0;var ke=(f+(n=n+Math.imul(u,ie)|0)|0)+((8191&(a=(a=a+Math.imul(u,oe)|0)+Math.imul(l,ie)|0))<<13)|0;f=((i=i+Math.imul(l,oe)|0)+(a>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(C,z),a=(a=Math.imul(C,H))+Math.imul(R,z)|0,i=Math.imul(R,H),n=n+Math.imul(T,J)|0,a=(a=a+Math.imul(T,V)|0)+Math.imul(j,J)|0,i=i+Math.imul(j,V)|0,n=n+Math.imul(E,X)|0,a=(a=a+Math.imul(E,K)|0)+Math.imul(O,X)|0,i=i+Math.imul(O,K)|0,n=n+Math.imul(_,Z)|0,a=(a=a+Math.imul(_,$)|0)+Math.imul(M,Z)|0,i=i+Math.imul(M,$)|0,n=n+Math.imul(y,Y)|0,a=(a=a+Math.imul(y,ee)|0)+Math.imul(w,Y)|0,i=i+Math.imul(w,ee)|0,n=n+Math.imul(v,re)|0,a=(a=a+Math.imul(v,ne)|0)+Math.imul(g,re)|0,i=i+Math.imul(g,ne)|0,n=n+Math.imul(h,ie)|0,a=(a=a+Math.imul(h,oe)|0)+Math.imul(p,ie)|0,i=i+Math.imul(p,oe)|0;var _e=(f+(n=n+Math.imul(u,se)|0)|0)+((8191&(a=(a=a+Math.imul(u,fe)|0)+Math.imul(l,se)|0))<<13)|0;f=((i=i+Math.imul(l,fe)|0)+(a>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(B,z),a=(a=Math.imul(B,H))+Math.imul(L,z)|0,i=Math.imul(L,H),n=n+Math.imul(C,J)|0,a=(a=a+Math.imul(C,V)|0)+Math.imul(R,J)|0,i=i+Math.imul(R,V)|0,n=n+Math.imul(T,X)|0,a=(a=a+Math.imul(T,K)|0)+Math.imul(j,X)|0,i=i+Math.imul(j,K)|0,n=n+Math.imul(E,Z)|0,a=(a=a+Math.imul(E,$)|0)+Math.imul(O,Z)|0,i=i+Math.imul(O,$)|0,n=n+Math.imul(_,Y)|0,a=(a=a+Math.imul(_,ee)|0)+Math.imul(M,Y)|0,i=i+Math.imul(M,ee)|0,n=n+Math.imul(y,re)|0,a=(a=a+Math.imul(y,ne)|0)+Math.imul(w,re)|0,i=i+Math.imul(w,ne)|0,n=n+Math.imul(v,ie)|0,a=(a=a+Math.imul(v,oe)|0)+Math.imul(g,ie)|0,i=i+Math.imul(g,oe)|0,n=n+Math.imul(h,se)|0,a=(a=a+Math.imul(h,fe)|0)+Math.imul(p,se)|0,i=i+Math.imul(p,fe)|0;var Me=(f+(n=n+Math.imul(u,ue)|0)|0)+((8191&(a=(a=a+Math.imul(u,le)|0)+Math.imul(l,ue)|0))<<13)|0;f=((i=i+Math.imul(l,le)|0)+(a>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,z),a=(a=Math.imul(F,H))+Math.imul(D,z)|0,i=Math.imul(D,H),n=n+Math.imul(B,J)|0,a=(a=a+Math.imul(B,V)|0)+Math.imul(L,J)|0,i=i+Math.imul(L,V)|0,n=n+Math.imul(C,X)|0,a=(a=a+Math.imul(C,K)|0)+Math.imul(R,X)|0,i=i+Math.imul(R,K)|0,n=n+Math.imul(T,Z)|0,a=(a=a+Math.imul(T,$)|0)+Math.imul(j,Z)|0,i=i+Math.imul(j,$)|0,n=n+Math.imul(E,Y)|0,a=(a=a+Math.imul(E,ee)|0)+Math.imul(O,Y)|0,i=i+Math.imul(O,ee)|0,n=n+Math.imul(_,re)|0,a=(a=a+Math.imul(_,ne)|0)+Math.imul(M,re)|0,i=i+Math.imul(M,ne)|0,n=n+Math.imul(y,ie)|0,a=(a=a+Math.imul(y,oe)|0)+Math.imul(w,ie)|0,i=i+Math.imul(w,oe)|0,n=n+Math.imul(v,se)|0,a=(a=a+Math.imul(v,fe)|0)+Math.imul(g,se)|0,i=i+Math.imul(g,fe)|0,n=n+Math.imul(h,ue)|0,a=(a=a+Math.imul(h,le)|0)+Math.imul(p,ue)|0,i=i+Math.imul(p,le)|0;var Se=(f+(n=n+Math.imul(u,he)|0)|0)+((8191&(a=(a=a+Math.imul(u,pe)|0)+Math.imul(l,he)|0))<<13)|0;f=((i=i+Math.imul(l,pe)|0)+(a>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(F,J),a=(a=Math.imul(F,V))+Math.imul(D,J)|0,i=Math.imul(D,V),n=n+Math.imul(B,X)|0,a=(a=a+Math.imul(B,K)|0)+Math.imul(L,X)|0,i=i+Math.imul(L,K)|0,n=n+Math.imul(C,Z)|0,a=(a=a+Math.imul(C,$)|0)+Math.imul(R,Z)|0,i=i+Math.imul(R,$)|0,n=n+Math.imul(T,Y)|0,a=(a=a+Math.imul(T,ee)|0)+Math.imul(j,Y)|0,i=i+Math.imul(j,ee)|0,n=n+Math.imul(E,re)|0,a=(a=a+Math.imul(E,ne)|0)+Math.imul(O,re)|0,i=i+Math.imul(O,ne)|0,n=n+Math.imul(_,ie)|0,a=(a=a+Math.imul(_,oe)|0)+Math.imul(M,ie)|0,i=i+Math.imul(M,oe)|0,n=n+Math.imul(y,se)|0,a=(a=a+Math.imul(y,fe)|0)+Math.imul(w,se)|0,i=i+Math.imul(w,fe)|0,n=n+Math.imul(v,ue)|0,a=(a=a+Math.imul(v,le)|0)+Math.imul(g,ue)|0,i=i+Math.imul(g,le)|0;var Ee=(f+(n=n+Math.imul(h,he)|0)|0)+((8191&(a=(a=a+Math.imul(h,pe)|0)+Math.imul(p,he)|0))<<13)|0;f=((i=i+Math.imul(p,pe)|0)+(a>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,X),a=(a=Math.imul(F,K))+Math.imul(D,X)|0,i=Math.imul(D,K),n=n+Math.imul(B,Z)|0,a=(a=a+Math.imul(B,$)|0)+Math.imul(L,Z)|0,i=i+Math.imul(L,$)|0,n=n+Math.imul(C,Y)|0,a=(a=a+Math.imul(C,ee)|0)+Math.imul(R,Y)|0,i=i+Math.imul(R,ee)|0,n=n+Math.imul(T,re)|0,a=(a=a+Math.imul(T,ne)|0)+Math.imul(j,re)|0,i=i+Math.imul(j,ne)|0,n=n+Math.imul(E,ie)|0,a=(a=a+Math.imul(E,oe)|0)+Math.imul(O,ie)|0,i=i+Math.imul(O,oe)|0,n=n+Math.imul(_,se)|0,a=(a=a+Math.imul(_,fe)|0)+Math.imul(M,se)|0,i=i+Math.imul(M,fe)|0,n=n+Math.imul(y,ue)|0,a=(a=a+Math.imul(y,le)|0)+Math.imul(w,ue)|0,i=i+Math.imul(w,le)|0;var Oe=(f+(n=n+Math.imul(v,he)|0)|0)+((8191&(a=(a=a+Math.imul(v,pe)|0)+Math.imul(g,he)|0))<<13)|0;f=((i=i+Math.imul(g,pe)|0)+(a>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,Z),a=(a=Math.imul(F,$))+Math.imul(D,Z)|0,i=Math.imul(D,$),n=n+Math.imul(B,Y)|0,a=(a=a+Math.imul(B,ee)|0)+Math.imul(L,Y)|0,i=i+Math.imul(L,ee)|0,n=n+Math.imul(C,re)|0,a=(a=a+Math.imul(C,ne)|0)+Math.imul(R,re)|0,i=i+Math.imul(R,ne)|0,n=n+Math.imul(T,ie)|0,a=(a=a+Math.imul(T,oe)|0)+Math.imul(j,ie)|0,i=i+Math.imul(j,oe)|0,n=n+Math.imul(E,se)|0,a=(a=a+Math.imul(E,fe)|0)+Math.imul(O,se)|0,i=i+Math.imul(O,fe)|0,n=n+Math.imul(_,ue)|0,a=(a=a+Math.imul(_,le)|0)+Math.imul(M,ue)|0,i=i+Math.imul(M,le)|0;var Ae=(f+(n=n+Math.imul(y,he)|0)|0)+((8191&(a=(a=a+Math.imul(y,pe)|0)+Math.imul(w,he)|0))<<13)|0;f=((i=i+Math.imul(w,pe)|0)+(a>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(F,Y),a=(a=Math.imul(F,ee))+Math.imul(D,Y)|0,i=Math.imul(D,ee),n=n+Math.imul(B,re)|0,a=(a=a+Math.imul(B,ne)|0)+Math.imul(L,re)|0,i=i+Math.imul(L,ne)|0,n=n+Math.imul(C,ie)|0,a=(a=a+Math.imul(C,oe)|0)+Math.imul(R,ie)|0,i=i+Math.imul(R,oe)|0,n=n+Math.imul(T,se)|0,a=(a=a+Math.imul(T,fe)|0)+Math.imul(j,se)|0,i=i+Math.imul(j,fe)|0,n=n+Math.imul(E,ue)|0,a=(a=a+Math.imul(E,le)|0)+Math.imul(O,ue)|0,i=i+Math.imul(O,le)|0;var Te=(f+(n=n+Math.imul(_,he)|0)|0)+((8191&(a=(a=a+Math.imul(_,pe)|0)+Math.imul(M,he)|0))<<13)|0;f=((i=i+Math.imul(M,pe)|0)+(a>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,re),a=(a=Math.imul(F,ne))+Math.imul(D,re)|0,i=Math.imul(D,ne),n=n+Math.imul(B,ie)|0,a=(a=a+Math.imul(B,oe)|0)+Math.imul(L,ie)|0,i=i+Math.imul(L,oe)|0,n=n+Math.imul(C,se)|0,a=(a=a+Math.imul(C,fe)|0)+Math.imul(R,se)|0,i=i+Math.imul(R,fe)|0,n=n+Math.imul(T,ue)|0,a=(a=a+Math.imul(T,le)|0)+Math.imul(j,ue)|0,i=i+Math.imul(j,le)|0;var je=(f+(n=n+Math.imul(E,he)|0)|0)+((8191&(a=(a=a+Math.imul(E,pe)|0)+Math.imul(O,he)|0))<<13)|0;f=((i=i+Math.imul(O,pe)|0)+(a>>>13)|0)+(je>>>26)|0,je&=67108863,n=Math.imul(F,ie),a=(a=Math.imul(F,oe))+Math.imul(D,ie)|0,i=Math.imul(D,oe),n=n+Math.imul(B,se)|0,a=(a=a+Math.imul(B,fe)|0)+Math.imul(L,se)|0,i=i+Math.imul(L,fe)|0,n=n+Math.imul(C,ue)|0,a=(a=a+Math.imul(C,le)|0)+Math.imul(R,ue)|0,i=i+Math.imul(R,le)|0;var Pe=(f+(n=n+Math.imul(T,he)|0)|0)+((8191&(a=(a=a+Math.imul(T,pe)|0)+Math.imul(j,he)|0))<<13)|0;f=((i=i+Math.imul(j,pe)|0)+(a>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,se),a=(a=Math.imul(F,fe))+Math.imul(D,se)|0,i=Math.imul(D,fe),n=n+Math.imul(B,ue)|0,a=(a=a+Math.imul(B,le)|0)+Math.imul(L,ue)|0,i=i+Math.imul(L,le)|0;var Ce=(f+(n=n+Math.imul(C,he)|0)|0)+((8191&(a=(a=a+Math.imul(C,pe)|0)+Math.imul(R,he)|0))<<13)|0;f=((i=i+Math.imul(R,pe)|0)+(a>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,n=Math.imul(F,ue),a=(a=Math.imul(F,le))+Math.imul(D,ue)|0,i=Math.imul(D,le);var Re=(f+(n=n+Math.imul(B,he)|0)|0)+((8191&(a=(a=a+Math.imul(B,pe)|0)+Math.imul(L,he)|0))<<13)|0;f=((i=i+Math.imul(L,pe)|0)+(a>>>13)|0)+(Re>>>26)|0,Re&=67108863;var Ne=(f+(n=Math.imul(F,he))|0)+((8191&(a=(a=Math.imul(F,pe))+Math.imul(D,he)|0))<<13)|0;return f=((i=Math.imul(D,pe))+(a>>>13)|0)+(Ne>>>26)|0,Ne&=67108863,s[0]=me,s[1]=ve,s[2]=ge,s[3]=xe,s[4]=ye,s[5]=we,s[6]=ke,s[7]=_e,s[8]=Me,s[9]=Se,s[10]=Ee,s[11]=Oe,s[12]=Ae,s[13]=Te,s[14]=je,s[15]=Pe,s[16]=Ce,s[17]=Re,s[18]=Ne,0!==f&&(s[19]=f,r.length++),r};function p(e,t,r){return(new m).mulp(e,t,r)}function m(e,t){this.x=e,this.y=t}Math.imul||(h=b),i.prototype.mulTo=function(e,t){var r=this.length+e.length;return 10===this.length&&10===e.length?h(this,e,t):r<63?b(this,e,t):r<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,a=0,i=0;i>>26)|0)>>>26,o&=67108863}r.words[i]=c,n=o,o=a}return 0!==n?r.words[i]=n:r.length--,r.strip()}(this,e,t):p(this,e,t)},m.prototype.makeRBT=function(e){for(var t=new Array(e),r=i.prototype._countBits(e)-1,n=0;n>=1;return n},m.prototype.permute=function(e,t,r,n,a,i){for(var o=0;o>>=1)a++;return 1<>>=13,r[2*o+1]=8191&i,i>>>=13;for(o=2*t;o>=26,t+=a/67108864|0,t+=i>>>26,this.words[r]=67108863&i}return 0!==t&&(this.words[r]=t,this.length++),this},i.prototype.muln=function(e){return this.clone().imuln(e)},i.prototype.sqr=function(){return this.mul(this)},i.prototype.isqr=function(){return this.imul(this.clone())},i.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>a}return t}(e);if(0===t.length)return new i(1);for(var r=this,n=0;n=0);var t,r=e%26,a=(e-r)/26,i=67108863>>>26-r<<26-r;if(0!==r){var o=0;for(t=0;t>>26-r}o&&(this.words[t]=o,this.length++)}if(0!==a){for(t=this.length-1;t>=0;t--)this.words[t+a]=this.words[t];for(t=0;t=0),a=t?(t-t%26)/26:0;var i=e%26,o=Math.min((e-i)/26,this.length),c=67108863^67108863>>>i<o)for(this.length-=o,f=0;f=0&&(0!==d||f>=a);f--){var u=0|this.words[f];this.words[f]=d<<26-i|u>>>i,d=u&c}return s&&0!==d&&(s.words[s.length++]=d),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},i.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},i.prototype.shln=function(e){return this.clone().ishln(e)},i.prototype.ushln=function(e){return this.clone().iushln(e)},i.prototype.shrn=function(e){return this.clone().ishrn(e)},i.prototype.ushrn=function(e){return this.clone().iushrn(e)},i.prototype.testn=function(e){n("number"===typeof e&&e>=0);var t=e%26,r=(e-t)/26,a=1<=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var a=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},i.prototype.isubn=function(e){if(n("number"===typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(s/67108864|0),this.words[a+r]=67108863&i}for(;a>26,this.words[a+r]=67108863&i;if(0===c)return this.strip();for(n(-1===c),c=0,a=0;a>26,this.words[a]=67108863&i;return this.negative=1,this.strip()},i.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),a=e,o=0|a.words[a.length-1];0!==(r=26-this._countBits(o))&&(a=a.ushln(r),n.iushln(r),o=0|a.words[a.length-1]);var c,s=n.length-a.length;if("mod"!==t){(c=new i(null)).length=s+1,c.words=new Array(c.length);for(var f=0;f=0;u--){var l=67108864*(0|n.words[a.length+u])+(0|n.words[a.length+u-1]);for(l=Math.min(l/o|0,67108863),n._ishlnsubmul(a,l,u);0!==n.negative;)l--,n.negative=0,n._ishlnsubmul(a,1,u),n.isZero()||(n.negative^=1);c&&(c.words[u]=l)}return c&&c.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:c||null,mod:n}},i.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new i(0),mod:new i(0)}:0!==this.negative&&0===e.negative?(c=this.neg().divmod(e,t),"mod"!==t&&(a=c.div.neg()),"div"!==t&&(o=c.mod.neg(),r&&0!==o.negative&&o.iadd(e)),{div:a,mod:o}):0===this.negative&&0!==e.negative?(c=this.divmod(e.neg(),t),"mod"!==t&&(a=c.div.neg()),{div:a,mod:c.mod}):0!==(this.negative&e.negative)?(c=this.neg().divmod(e.neg(),t),"div"!==t&&(o=c.mod.neg(),r&&0!==o.negative&&o.isub(e)),{div:c.div,mod:o}):e.length>this.length||this.cmp(e)<0?{div:new i(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new i(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new i(this.modn(e.words[0]))}:this._wordDiv(e,t);var a,o,c},i.prototype.div=function(e){return this.divmod(e,"div",!1).div},i.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},i.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},i.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),a=e.andln(1),i=r.cmp(n);return i<0||1===a&&0===i?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},i.prototype.modn=function(e){n(e<=67108863);for(var t=(1<<26)%e,r=0,a=this.length-1;a>=0;a--)r=(t*r+(0|this.words[a]))%e;return r},i.prototype.idivn=function(e){n(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var a=(0|this.words[r])+67108864*t;this.words[r]=a/e|0,t=a%e}return this.strip()},i.prototype.divn=function(e){return this.clone().idivn(e)},i.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var a=new i(1),o=new i(0),c=new i(0),s=new i(1),f=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++f;for(var d=r.clone(),u=t.clone();!t.isZero();){for(var l=0,b=1;0===(t.words[0]&b)&&l<26;++l,b<<=1);if(l>0)for(t.iushrn(l);l-- >0;)(a.isOdd()||o.isOdd())&&(a.iadd(d),o.isub(u)),a.iushrn(1),o.iushrn(1);for(var h=0,p=1;0===(r.words[0]&p)&&h<26;++h,p<<=1);if(h>0)for(r.iushrn(h);h-- >0;)(c.isOdd()||s.isOdd())&&(c.iadd(d),s.isub(u)),c.iushrn(1),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(c),o.isub(s)):(r.isub(t),c.isub(a),s.isub(o))}return{a:c,b:s,gcd:r.iushln(f)}},i.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var a,o=new i(1),c=new i(0),s=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var f=0,d=1;0===(t.words[0]&d)&&f<26;++f,d<<=1);if(f>0)for(t.iushrn(f);f-- >0;)o.isOdd()&&o.iadd(s),o.iushrn(1);for(var u=0,l=1;0===(r.words[0]&l)&&u<26;++u,l<<=1);if(u>0)for(r.iushrn(u);u-- >0;)c.isOdd()&&c.iadd(s),c.iushrn(1);t.cmp(r)>=0?(t.isub(r),o.isub(c)):(r.isub(t),c.isub(o))}return(a=0===t.cmpn(1)?o:c).cmpn(0)<0&&a.iadd(e),a},i.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var a=t.cmp(r);if(a<0){var i=t;t=r,r=i}else if(0===a||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},i.prototype.invm=function(e){return this.egcd(e).a.umod(e)},i.prototype.isEven=function(){return 0===(1&this.words[0])},i.prototype.isOdd=function(){return 1===(1&this.words[0])},i.prototype.andln=function(e){return this.words[0]&e},i.prototype.bincn=function(e){n("number"===typeof e);var t=e%26,r=(e-t)/26,a=1<>>26,c&=67108863,this.words[o]=c}return 0!==i&&(this.words[o]=i,this.length++),this},i.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},i.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var a=0|this.words[0];t=a===e?0:ae.length)return 1;if(this.length=0;r--){var n=0|this.words[r],a=0|e.words[r];if(n!==a){na&&(t=1);break}}return t},i.prototype.gtn=function(e){return 1===this.cmpn(e)},i.prototype.gt=function(e){return 1===this.cmp(e)},i.prototype.gten=function(e){return this.cmpn(e)>=0},i.prototype.gte=function(e){return this.cmp(e)>=0},i.prototype.ltn=function(e){return-1===this.cmpn(e)},i.prototype.lt=function(e){return-1===this.cmp(e)},i.prototype.lten=function(e){return this.cmpn(e)<=0},i.prototype.lte=function(e){return this.cmp(e)<=0},i.prototype.eqn=function(e){return 0===this.cmpn(e)},i.prototype.eq=function(e){return 0===this.cmp(e)},i.red=function(e){return new _(e)},i.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},i.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},i.prototype._forceRed=function(e){return this.red=e,this},i.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},i.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},i.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},i.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},i.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},i.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},i.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},i.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},i.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},i.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},i.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},i.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},i.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},i.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var v={k256:null,p224:null,p192:null,p25519:null};function g(e,t){this.name=e,this.p=new i(t,16),this.n=this.p.bitLength(),this.k=new i(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function x(){g.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function y(){g.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function w(){g.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function k(){g.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function _(e){if("string"===typeof e){var t=i._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function M(e){_.call(this,e),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new i(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}g.prototype._tmp=function(){var e=new i(null);return e.words=new Array(Math.ceil(this.n/13)),e},g.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},g.prototype.split=function(e,t){e.iushrn(this.n,0,t)},g.prototype.imulK=function(e){return e.imul(this.k)},a(x,g),x.prototype.split=function(e,t){for(var r=Math.min(e.length,9),n=0;n>>22,a=i}a>>>=22,e.words[n-10]=a,0===a&&e.length>10?e.length-=10:e.length-=9},x.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=a,t=n}return 0!==t&&(e.words[e.length++]=t),e},i._prime=function(e){if(v[e])return v[e];var t;if("k256"===e)t=new x;else if("p224"===e)t=new y;else if("p192"===e)t=new w;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new k}return v[e]=t,t},_.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},_.prototype._verify2=function(e,t){n(0===(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},_.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},_.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},_.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},_.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},_.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},_.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},_.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},_.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},_.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},_.prototype.isqr=function(e){return this.imul(e,e.clone())},_.prototype.sqr=function(e){return this.mul(e,e)},_.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2===1),3===t){var r=this.m.add(new i(1)).iushrn(2);return this.pow(e,r)}for(var a=this.m.subn(1),o=0;!a.isZero()&&0===a.andln(1);)o++,a.iushrn(1);n(!a.isZero());var c=new i(1).toRed(this),s=c.redNeg(),f=this.m.subn(1).iushrn(1),d=this.m.bitLength();for(d=new i(2*d*d).toRed(this);0!==this.pow(d,f).cmp(s);)d.redIAdd(s);for(var u=this.pow(d,a),l=this.pow(e,a.addn(1).iushrn(1)),b=this.pow(e,a),h=o;0!==b.cmp(c);){for(var p=b,m=0;0!==p.cmp(c);m++)p=p.redSqr();n(m=0;n--){for(var f=t.words[n],d=s-1;d>=0;d--){var u=f>>d&1;a!==r[0]&&(a=this.sqr(a)),0!==u||0!==o?(o<<=1,o|=u,(4===++c||0===n&&0===d)&&(a=this.mul(a,r[o]),c=0,o=0)):c=0}s=26}return a},_.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},_.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},i.mont=function(e){return new M(e)},a(M,_),M.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},M.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},M.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),a=r.isub(n).iushrn(this.shift),i=a;return a.cmp(this.m)>=0?i=a.isub(this.m):a.cmpn(0)<0&&(i=a.iadd(this.m)),i._forceRed(this)},M.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new i(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),a=r.isub(n).iushrn(this.shift),o=a;return a.cmp(this.m)>=0?o=a.isub(this.m):a.cmpn(0)<0&&(o=a.iadd(this.m)),o._forceRed(this)},M.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e,this)}).call(this,r(74)(e))},function(e,t,r){var n=r(30),a=n.Buffer;function i(e,t){for(var r in e)t[r]=e[r]}function o(e,t,r){return a(e,t,r)}a.from&&a.alloc&&a.allocUnsafe&&a.allocUnsafeSlow?e.exports=n:(i(n,t),t.Buffer=o),o.prototype=Object.create(a.prototype),i(a,o),o.from=function(e,t,r){if("number"===typeof e)throw new TypeError("Argument must not be a number");return a(e,t,r)},o.alloc=function(e,t,r){if("number"!==typeof e)throw new TypeError("Argument must be a number");var n=a(e);return void 0!==t?"string"===typeof r?n.fill(t,r):n.fill(t):n.fill(0),n},o.allocUnsafe=function(e){if("number"!==typeof e)throw new TypeError("Argument must be a number");return a(e)},o.allocUnsafeSlow=function(e){if("number"!==typeof e)throw new TypeError("Argument must be a number");return n.SlowBuffer(e)}},function(e,t,r){"use strict";r.d(t,"b",(function(){return i})),r.d(t,"e",(function(){return o})),r.d(t,"a",(function(){return c})),r.d(t,"c",(function(){return s})),r.d(t,"d",(function(){return f}));var n=r(5),a=r(86);function i(e){return"string"===typeof e&&"0x"!==e.substring(0,2)&&(e="0x"+e),Object(n.a)(e)}function o(e,t){for(e=String(e);e.length0&&(10===arguments[0]?h||(h=!0,u.warn("BigNumber.toString does not accept any parameters; base-10 is assumed")):16===arguments[0]?u.throwError("BigNumber.toString does not accept any parameters; use bigNumber.toHexString()",s.a.errors.UNEXPECTED_ARGUMENT,{}):u.throwError("BigNumber.toString does not accept parameters",s.a.errors.UNEXPECTED_ARGUMENT,{})),g(this).toString(10)}},{key:"toHexString",value:function(){return this._hex}},{key:"toJSON",value:function(e){return{type:"BigNumber",hex:this.toHexString()}}}],[{key:"from",value:function(t){if(t instanceof e)return t;if("string"===typeof t)return t.match(/^-?0x[0-9a-f]+$/i)?new e(l,m(t)):t.match(/^-?[0-9]+$/)?new e(l,m(new d(t))):u.throwArgumentError("invalid BigNumber string","value",t);if("number"===typeof t)return t%1&&x("underflow","BigNumber.from",t),(t>=9007199254740991||t<=-9007199254740991)&&x("overflow","BigNumber.from",t),e.from(String(t));var r=t;if("bigint"===typeof r)return e.from(r.toString());if(Object(c.i)(r))return e.from(Object(c.h)(r));if(r)if(r.toHexString){var n=r.toHexString();if("string"===typeof n)return e.from(n)}else{var a=r._hex;if(null==a&&"BigNumber"===r.type&&(a=r.hex),"string"===typeof a&&(Object(c.k)(a)||"-"===a[0]&&Object(c.k)(a.substring(1))))return e.from(a)}return u.throwArgumentError("invalid BigNumber value","value",t)}},{key:"isBigNumber",value:function(e){return!(!e||!e._isBigNumber)}}]),e}();function m(e){if("string"!==typeof e)return m(e.toString(16));if("-"===e[0])return"-"===(e=e.substring(1))[0]&&u.throwArgumentError("invalid hex","value",e),"0x00"===(e=m(e))?e:"-"+e;if("0x"!==e.substring(0,2)&&(e="0x"+e),"0x"===e)return"0x00";for(e.length%2&&(e="0x0"+e.substring(2));e.length>4&&"0x00"===e.substring(0,4);)e="0x"+e.substring(4);return e}function v(e){return p.from(m(e))}function g(e){var t=p.from(e).toHexString();return"-"===t[0]?new d("-"+t.substring(3),16):new d(t.substring(2),16)}function x(e,t,r){var n={fault:e,operation:t};return null!=r&&(n.value=r),u.throwError(e,s.a.errors.NUMERIC_FAULT,n)}function y(e){return new d(e,36).toString(16)}function w(e){return new d(e,16).toString(36)}},function(e,t,r){var n=t;n.utils=r(106),n.common=r(198),n.sha=r(607),n.ripemd=r(611),n.hmac=r(612),n.sha1=n.sha.sha1,n.sha256=n.sha.sha256,n.sha224=n.sha.sha224,n.sha384=n.sha.sha384,n.sha512=n.sha.sha512,n.ripemd160=n.ripemd.ripemd160},function(e,t){var r,n,a=e.exports={};function i(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function c(e){if(r===setTimeout)return setTimeout(e,0);if((r===i||!r)&&setTimeout)return r=setTimeout,setTimeout(e,0);try{return r(e,0)}catch(t){try{return r.call(null,e,0)}catch(t){return r.call(this,e,0)}}}!function(){try{r="function"===typeof setTimeout?setTimeout:i}catch(e){r=i}try{n="function"===typeof clearTimeout?clearTimeout:o}catch(e){n=o}}();var s,f=[],d=!1,u=-1;function l(){d&&s&&(d=!1,s.length?f=s.concat(f):u=-1,f.length&&b())}function b(){if(!d){var e=c(l);d=!0;for(var t=f.length;t;){for(s=f,f=[];++u1)for(var r=1;r=0||(a[r]=e[r]);return a}r.d(t,"a",(function(){return n}))},function(e,t,r){"use strict";r.d(t,"d",(function(){return b})),r.d(t,"a",(function(){return p})),r.d(t,"c",(function(){return y})),r.d(t,"b",(function(){return w}));var n=r(6),a=r(7),i=r(39),o=r.n(i),c=r(10),s=r(16),f=r(275),d=o.a.BN,u=new s.Logger(f.a),l={};function b(e){return null!=e&&(p.isBigNumber(e)||"number"===typeof e&&e%1===0||"string"===typeof e&&!!e.match(/^-?[0-9]+$/)||Object(c.isHexString)(e)||"bigint"===typeof e||Object(c.isBytes)(e))}var h=!1,p=function(){function e(t,r){Object(n.a)(this,e),u.checkNew(this instanceof e?this.constructor:void 0,e),t!==l&&u.throwError("cannot call constructor directly; use BigNumber.from",s.Logger.errors.UNSUPPORTED_OPERATION,{operation:"new (BigNumber)"}),this._hex=r,this._isBigNumber=!0,Object.freeze(this)}return Object(a.a)(e,[{key:"fromTwos",value:function(e){return v(g(this).fromTwos(e))}},{key:"toTwos",value:function(e){return v(g(this).toTwos(e))}},{key:"abs",value:function(){return"-"===this._hex[0]?e.from(this._hex.substring(1)):this}},{key:"add",value:function(e){return v(g(this).add(g(e)))}},{key:"sub",value:function(e){return v(g(this).sub(g(e)))}},{key:"div",value:function(t){return e.from(t).isZero()&&x("division by zero","div"),v(g(this).div(g(t)))}},{key:"mul",value:function(e){return v(g(this).mul(g(e)))}},{key:"mod",value:function(e){var t=g(e);return t.isNeg()&&x("cannot modulo negative values","mod"),v(g(this).umod(t))}},{key:"pow",value:function(e){var t=g(e);return t.isNeg()&&x("cannot raise to negative values","pow"),v(g(this).pow(t))}},{key:"and",value:function(e){var t=g(e);return(this.isNegative()||t.isNeg())&&x("cannot 'and' negative values","and"),v(g(this).and(t))}},{key:"or",value:function(e){var t=g(e);return(this.isNegative()||t.isNeg())&&x("cannot 'or' negative values","or"),v(g(this).or(t))}},{key:"xor",value:function(e){var t=g(e);return(this.isNegative()||t.isNeg())&&x("cannot 'xor' negative values","xor"),v(g(this).xor(t))}},{key:"mask",value:function(e){return(this.isNegative()||e<0)&&x("cannot mask negative values","mask"),v(g(this).maskn(e))}},{key:"shl",value:function(e){return(this.isNegative()||e<0)&&x("cannot shift negative values","shl"),v(g(this).shln(e))}},{key:"shr",value:function(e){return(this.isNegative()||e<0)&&x("cannot shift negative values","shr"),v(g(this).shrn(e))}},{key:"eq",value:function(e){return g(this).eq(g(e))}},{key:"lt",value:function(e){return g(this).lt(g(e))}},{key:"lte",value:function(e){return g(this).lte(g(e))}},{key:"gt",value:function(e){return g(this).gt(g(e))}},{key:"gte",value:function(e){return g(this).gte(g(e))}},{key:"isNegative",value:function(){return"-"===this._hex[0]}},{key:"isZero",value:function(){return g(this).isZero()}},{key:"toNumber",value:function(){try{return g(this).toNumber()}catch(e){x("overflow","toNumber",this.toString())}return null}},{key:"toBigInt",value:function(){try{return BigInt(this.toString())}catch(e){}return u.throwError("this platform does not support BigInt",s.Logger.errors.UNSUPPORTED_OPERATION,{value:this.toString()})}},{key:"toString",value:function(){return arguments.length>0&&(10===arguments[0]?h||(h=!0,u.warn("BigNumber.toString does not accept any parameters; base-10 is assumed")):16===arguments[0]?u.throwError("BigNumber.toString does not accept any parameters; use bigNumber.toHexString()",s.Logger.errors.UNEXPECTED_ARGUMENT,{}):u.throwError("BigNumber.toString does not accept parameters",s.Logger.errors.UNEXPECTED_ARGUMENT,{})),g(this).toString(10)}},{key:"toHexString",value:function(){return this._hex}},{key:"toJSON",value:function(e){return{type:"BigNumber",hex:this.toHexString()}}}],[{key:"from",value:function(t){if(t instanceof e)return t;if("string"===typeof t)return t.match(/^-?0x[0-9a-f]+$/i)?new e(l,m(t)):t.match(/^-?[0-9]+$/)?new e(l,m(new d(t))):u.throwArgumentError("invalid BigNumber string","value",t);if("number"===typeof t)return t%1&&x("underflow","BigNumber.from",t),(t>=9007199254740991||t<=-9007199254740991)&&x("overflow","BigNumber.from",t),e.from(String(t));var r=t;if("bigint"===typeof r)return e.from(r.toString());if(Object(c.isBytes)(r))return e.from(Object(c.hexlify)(r));if(r)if(r.toHexString){var n=r.toHexString();if("string"===typeof n)return e.from(n)}else{var a=r._hex;if(null==a&&"BigNumber"===r.type&&(a=r.hex),"string"===typeof a&&(Object(c.isHexString)(a)||"-"===a[0]&&Object(c.isHexString)(a.substring(1))))return e.from(a)}return u.throwArgumentError("invalid BigNumber value","value",t)}},{key:"isBigNumber",value:function(e){return!(!e||!e._isBigNumber)}}]),e}();function m(e){if("string"!==typeof e)return m(e.toString(16));if("-"===e[0])return"-"===(e=e.substring(1))[0]&&u.throwArgumentError("invalid hex","value",e),"0x00"===(e=m(e))?e:"-"+e;if("0x"!==e.substring(0,2)&&(e="0x"+e),"0x"===e)return"0x00";for(e.length%2&&(e="0x0"+e.substring(2));e.length>4&&"0x00"===e.substring(0,4);)e="0x"+e.substring(4);return e}function v(e){return p.from(m(e))}function g(e){var t=p.from(e).toHexString();return"-"===t[0]?new d("-"+t.substring(3),16):new d(t.substring(2),16)}function x(e,t,r){var n={fault:e,operation:t};return null!=r&&(n.value=r),u.throwError(e,s.Logger.errors.NUMERIC_FAULT,n)}function y(e){return new d(e,36).toString(16)}function w(e){return new d(e,16).toString(36)}},function(e,t,r){"use strict";r.d(t,"a",(function(){return n}));var n="providers/5.5.3"},function(e,t,r){"use strict";r.r(t),r.d(t,"getAddress",(function(){return p})),r.d(t,"isAddress",(function(){return m})),r.d(t,"getIcapAddress",(function(){return v})),r.d(t,"getContractAddress",(function(){return g})),r.d(t,"getCreate2Address",(function(){return x}));var n=r(10),a=r(51),i=r(49),o=r(98),c=new(r(16).Logger)("address/5.3.0");function s(e){Object(n.isHexString)(e,20)||c.throwArgumentError("invalid address","address",e);for(var t=(e=e.toLowerCase()).substring(2).split(""),r=new Uint8Array(40),a=0;a<40;a++)r[a]=t[a].charCodeAt(0);for(var o=Object(n.arrayify)(Object(i.keccak256)(r)),s=0;s<40;s+=2)o[s>>1]>>4>=8&&(t[s]=t[s].toUpperCase()),(15&o[s>>1])>=8&&(t[s+1]=t[s+1].toUpperCase());return"0x"+t.join("")}for(var f={},d=0;d<10;d++)f[String(d)]=String(d);for(var u=0;u<26;u++)f[String.fromCharCode(65+u)]=String(10+u);var l,b=Math.floor((l=9007199254740991,Math.log10?Math.log10(l):Math.log(l)/Math.LN10));function h(e){for(var t=(e=(e=e.toUpperCase()).substring(4)+e.substring(0,2)+"00").split("").map((function(e){return f[e]})).join("");t.length>=b;){var r=t.substring(0,b);t=parseInt(r,10)%97+t.substring(r.length)}for(var n=String(98-parseInt(t,10)%97);n.length<2;)n="0"+n;return n}function p(e){var t=null;if("string"!==typeof e&&c.throwArgumentError("invalid address","address",e),e.match(/^(0x)?[0-9a-fA-F]{40}$/))"0x"!==e.substring(0,2)&&(e="0x"+e),t=s(e),e.match(/([A-F].*[a-f])|([a-f].*[A-F])/)&&t!==e&&c.throwArgumentError("bad address checksum","address",e);else if(e.match(/^XE[0-9]{2}[0-9A-Za-z]{30,31}$/)){for(e.substring(2,4)!==h(e)&&c.throwArgumentError("bad icap checksum","address",e),t=Object(a.c)(e.substring(4));t.length<40;)t="0"+t;t=s("0x"+t)}else c.throwArgumentError("invalid address","address",e);return t}function m(e){try{return p(e),!0}catch(t){}return!1}function v(e){for(var t=Object(a.b)(p(e).substring(2)).toUpperCase();t.length<30;)t="0"+t;return"XE"+h("XE00"+t)+t}function g(e){var t=null;try{t=p(e.from)}catch(s){c.throwArgumentError("missing from address","transaction",e)}var r=Object(n.stripZeros)(Object(n.arrayify)(a.a.from(e.nonce).toHexString()));return p(Object(n.hexDataSlice)(Object(i.keccak256)(Object(o.encode)([t,r])),12))}function x(e,t,r){return 32!==Object(n.hexDataLength)(t)&&c.throwArgumentError("salt must be 32 bytes","salt",t),32!==Object(n.hexDataLength)(r)&&c.throwArgumentError("initCodeHash must be 32 bytes","initCodeHash",r),p(Object(n.hexDataSlice)(Object(i.keccak256)(Object(n.concat)(["0xff",p(e),t,r])),12))}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}r.d(t,"a",(function(){return n}))},function(e,t,r){"use strict";function n(e,t){for(var r=0;r=0||(a[r]=e[r]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(n=0;n=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}r.d(t,"a",(function(){return n}))},,function(e,t,r){"use strict";r.d(t,"d",(function(){return u})),r.d(t,"a",(function(){return l})),r.d(t,"c",(function(){return b})),r.d(t,"b",(function(){return h}));var n=r(6),a=r(7),i=r(10),o=r(51),c=r(15),s=r(16),f=r(110),d=new s.Logger(f.a);function u(e){var t=[];return function e(r,n){if(Array.isArray(n))for(var a in n){var i=r.slice();i.push(a);try{e(i,n[a])}catch(o){t.push({path:i,error:o})}}}([],e),t}var l=function(){function e(t,r,a,i){Object(n.a)(this,e),this.name=t,this.type=r,this.localName=a,this.dynamic=i}return Object(a.a)(e,[{key:"_throwError",value:function(e,t){d.throwArgumentError(e,this.localName,t)}}]),e}(),b=function(){function e(t){Object(n.a)(this,e),Object(c.defineReadOnly)(this,"wordSize",t||32),this._data=[],this._dataLength=0,this._padding=new Uint8Array(t)}return Object(a.a)(e,[{key:"data",get:function(){return Object(i.hexConcat)(this._data)}},{key:"length",get:function(){return this._dataLength}},{key:"_writeData",value:function(e){return this._data.push(e),this._dataLength+=e.length,e.length}},{key:"appendWriter",value:function(e){return this._writeData(Object(i.concat)(e._data))}},{key:"writeBytes",value:function(e){var t=Object(i.arrayify)(e),r=t.length%this.wordSize;return r&&(t=Object(i.concat)([t,this._padding.slice(r)])),this._writeData(t)}},{key:"_getValue",value:function(e){var t=Object(i.arrayify)(o.a.from(e));return t.length>this.wordSize&&d.throwError("value out-of-bounds",s.Logger.errors.BUFFER_OVERRUN,{length:this.wordSize,offset:t.length}),t.length%this.wordSize&&(t=Object(i.concat)([this._padding.slice(t.length%this.wordSize),t])),t}},{key:"writeValue",value:function(e){return this._writeData(this._getValue(e))}},{key:"writeUpdatableValue",value:function(){var e=this,t=this._data.length;return this._data.push(this._padding),this._dataLength+=this.wordSize,function(r){e._data[t]=e._getValue(r)}}}]),e}(),h=function(){function e(t,r,a,o){Object(n.a)(this,e),Object(c.defineReadOnly)(this,"_data",Object(i.arrayify)(t)),Object(c.defineReadOnly)(this,"wordSize",r||32),Object(c.defineReadOnly)(this,"_coerceFunc",a),Object(c.defineReadOnly)(this,"allowLoose",o),this._offset=0}return Object(a.a)(e,[{key:"data",get:function(){return Object(i.hexlify)(this._data)}},{key:"consumed",get:function(){return this._offset}},{key:"coerce",value:function(t,r){return this._coerceFunc?this._coerceFunc(t,r):e.coerce(t,r)}},{key:"_peekBytes",value:function(e,t,r){var n=Math.ceil(t/this.wordSize)*this.wordSize;return this._offset+n>this._data.length&&(this.allowLoose&&r&&this._offset+t<=this._data.length?n=t:d.throwError("data out-of-bounds",s.Logger.errors.BUFFER_OVERRUN,{length:this._data.length,offset:this._offset+n})),this._data.slice(this._offset,this._offset+n)}},{key:"subReader",value:function(t){return new e(this._data.slice(this._offset+t),this.wordSize,this._coerceFunc,this.allowLoose)}},{key:"readBytes",value:function(e,t){var r=this._peekBytes(0,e,!!t);return this._offset+=r.length,r.slice(0,e)}},{key:"readValue",value:function(){return o.a.from(this.readBytes(this.wordSize))}}],[{key:"coerce",value:function(e,t){var r=e.match("^u?int([0-9]+)$");return r&&parseInt(r[1])<=48&&(t=t.toNumber()),t}}]),e}()},function(e,t,r){"use strict";r.d(t,"a",(function(){return k})),r.d(t,"b",(function(){return E})),r.d(t,"c",(function(){return S})),r.d(t,"d",(function(){return O}));var n=r(1),a=r.n(n),i=r(23),o=r(103),c=r(5),s=r(40);function f(){return(f=Object.assign||function(e){for(var t=1;t>1]>>4>=8&&(r[f]=r[f].toUpperCase()),(15&o[f>>1])>=8&&(r[f+1]=r[f+1].toUpperCase());var d="0x"+r.join("");return t.match(/([A-F].*[a-f])|([a-f].*[A-F])/)&&t!==d&&Object(i.a)(!1),d}var x,y=function(e,t){try{var r=function(r){return Promise.resolve(Promise.all([void 0===t.chainId?e.getChainId():t.chainId,void 0===t.account?e.getAccount():t.account])).then((function(t){var n=t[0],a=t[1],i=v(n);if(e.supportedChainIds&&!e.supportedChainIds.includes(i))throw new k(i,e.supportedChainIds);var o=null===a?a:g(a);return{provider:r,chainId:i,account:o}}))},n=void 0===t.provider;return Promise.resolve(n?Promise.resolve(e.getProvider()).then(r):r(t.provider))}catch(a){return Promise.reject(a)}},w=function(e){function t(){var t;return(t=e.call(this)||this).name=t.constructor.name,t}return d(t,e),t}(p(Error)),k=function(e){function t(t,r){var n;return(n=e.call(this)||this).name=n.constructor.name,n.message="Unsupported chain id: "+t+". Supported chain ids are: "+r+".",n}return d(t,e),t}(p(Error));function _(e,t){var r=t.type,n=t.payload;switch(r){case x.ACTIVATE_CONNECTOR:return{connector:n.connector,provider:n.provider,chainId:n.chainId,account:n.account,onError:n.onError};case x.UPDATE:var a=n.provider,i=n.chainId,o=n.account;return f({},e,void 0===a?{}:{provider:a},void 0===i?{}:{chainId:i},void 0===o?{}:{account:o});case x.UPDATE_FROM_ERROR:var c=n.provider,s=n.chainId,d=n.account;return f({},e,void 0===c?{}:{provider:c},void 0===s?{}:{chainId:s},void 0===d?{}:{account:d},{error:void 0});case x.ERROR:var u=n.error;return{connector:e.connector,error:u,onError:e.onError};case x.ERROR_FROM_ACTIVATION:return{connector:n.connector,error:n.error};case x.DEACTIVATE_CONNECTOR:return{}}}!function(e){e[e.ACTIVATE_CONNECTOR=0]="ACTIVATE_CONNECTOR",e[e.UPDATE=1]="UPDATE",e[e.UPDATE_FROM_ERROR=2]="UPDATE_FROM_ERROR",e[e.ERROR=3]="ERROR",e[e.ERROR_FROM_ACTIVATION=4]="ERROR_FROM_ACTIVATION",e[e.DEACTIVATE_CONNECTOR=5]="DEACTIVATE_CONNECTOR"}(x||(x={}));var M={};function S(e){M[e]&&Object(i.a)(!1),M[e]=Object(n.createContext)({activate:function(){try{return Object(i.a)(!1),Promise.resolve()}catch(e){return Promise.reject(e)}},setError:function(){Object(i.a)(!1)},deactivate:function(){Object(i.a)(!1)},active:!1}),M[e].displayName="Web3ReactContext - "+e;var t=M[e].Provider;return function(e){var r=e.getLibrary,i=e.children,c=function(){var e=Object(n.useReducer)(_,{}),t=e[0],r=e[1],a=t.connector,i=t.provider,c=t.chainId,s=t.account,d=t.onError,u=t.error,l=Object(n.useRef)(-1);l.current+=1;var b=Object(n.useCallback)((function(e,t,n){void 0===n&&(n=!1);try{var a=l.current,i=!1;return Promise.resolve(m((function(){return Promise.resolve(e.activate().then((function(e){return i=!0,e}))).then((function(n){return Promise.resolve(y(e,n)).then((function(n){if(l.current>a)throw new w;r({type:x.ACTIVATE_CONNECTOR,payload:f({connector:e},n,{onError:t})})}))}))}),(function(a){if(a instanceof w)i&&e.deactivate();else{if(n)throw i&&e.deactivate(),a;t?(i&&e.deactivate(),t(a)):r({type:x.ERROR_FROM_ACTIVATION,payload:{connector:e,error:a}})}})))}catch(o){return Promise.reject(o)}}),[]),h=Object(n.useCallback)((function(e){r({type:x.ERROR,payload:{error:e}})}),[]),p=Object(n.useCallback)((function(){r({type:x.DEACTIVATE_CONNECTOR})}),[]),M=Object(n.useCallback)((function(e){try{if(!a)throw Error("This should never happen, it's just so Typescript stops complaining");var t=l.current;return Promise.resolve(function(){if(u)return m((function(){return Promise.resolve(y(a,e)).then((function(e){if(l.current>t)throw new w;r({type:x.UPDATE_FROM_ERROR,payload:e})}))}),(function(e){e instanceof w||(d?d(e):r({type:x.ERROR,payload:{error:e}}))}));var n=void 0===e.chainId?void 0:v(e.chainId);if(void 0!==n&&a.supportedChainIds&&!a.supportedChainIds.includes(n)){var i=new k(n,a.supportedChainIds);d?d(i):r({type:x.ERROR,payload:{error:i}})}else{var o="string"===typeof e.account?g(e.account):e.account;r({type:x.UPDATE,payload:{provider:e.provider,chainId:n,account:o}})}}())}catch(n){return Promise.reject(n)}}),[a,u,d]),S=Object(n.useCallback)((function(e){d?d(e):r({type:x.ERROR,payload:{error:e}})}),[d]),E=Object(n.useCallback)((function(){r({type:x.DEACTIVATE_CONNECTOR})}),[]);return Object(n.useEffect)((function(){return function(){a&&a.deactivate()}}),[a]),Object(n.useEffect)((function(){return a&&a.on(o.a.Update,M).on(o.a.Error,S).on(o.a.Deactivate,E),function(){a&&a.off(o.a.Update,M).off(o.a.Error,S).off(o.a.Deactivate,E)}}),[a,M,S,E]),{connector:a,provider:i,chainId:c,account:s,activate:b,setError:h,deactivate:p,error:u}}(),s=c.connector,d=c.provider,u=c.chainId,l=c.account,b=c.activate,h=c.setError,p=c.deactivate,M=c.error,S=void 0!==s&&void 0!==u&&void 0!==l&&!M,E=Object(n.useMemo)((function(){return S&&void 0!==u&&Number.isInteger(u)&&s?r(d,s):void 0}),[S,r,d,s,u]),O={connector:s,library:E,chainId:u,account:l,activate:b,setError:h,deactivate:p,active:S,error:M};return a.a.createElement(t,{value:O},i)}}var E=S("primary");function O(e){return Object(n.useContext)(function(e){return void 0===e&&(e="primary"),Object.keys(M).includes(e)||Object(i.a)(!1),M[e]}(e))}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Flex=t.Box=void 0;s(r(1));var n=s(r(1161)),a=r(82),i=function(e){if(e&&e.__esModule)return e;var t=c();if(t&&t.has(e))return t.get(e);var r={};if(null!=e){var n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if(Object.prototype.hasOwnProperty.call(e,a)){var i=n?Object.getOwnPropertyDescriptor(e,a):null;i&&(i.get||i.set)?Object.defineProperty(r,a,i):r[a]=e[a]}}r.default=e,t&&t.set(e,r);return r}(r(262)),o=s(r(263));function c(){if("function"!==typeof WeakMap)return null;var e=new WeakMap;return c=function(){return e},e}function s(e){return e&&e.__esModule?e:{default:e}}var f=(0,n.default)("div",{shouldForwardProp:o.default})({boxSizing:"border-box",margin:0,minWidth:0},(function(e){return(0,i.default)(e.__css)(e.theme)}),(function(e){var t=e.theme,r=e.variant,n=e.tx,a=void 0===n?"variants":n;return(0,i.default)((0,i.get)(t,a+"."+r,(0,i.get)(t,r)))(t)}),(function(e){return(0,i.default)(e.sx)(e.theme)}),(function(e){return e.css}),(0,a.compose)(a.space,a.layout,a.typography,a.color,a.flexbox));t.Box=f;var d=(0,n.default)(f)({display:"flex"});t.Flex=d},,function(e,t,r){"use strict";r.d(t,"a",(function(){return O})),r.d(t,"b",(function(){return R})),r.d(t,"c",(function(){return L}));var n=r(69),a=r(72),i=r(1),o=r.n(i),c=r(22),s=r(282),f=(r(283),r(23));function d(e){return"/"===e.charAt(0)?e:"/"+e}function u(e){return"/"===e.charAt(0)?e.substr(1):e}function l(e,t){return function(e,t){return 0===e.toLowerCase().indexOf(t.toLowerCase())&&-1!=="/?#".indexOf(e.charAt(t.length))}(e,t)?e.substr(t.length):e}function b(e){return"/"===e.charAt(e.length-1)?e.slice(0,-1):e}function h(e){var t=e.pathname,r=e.search,n=e.hash,a=t||"/";return r&&"?"!==r&&(a+="?"===r.charAt(0)?r:"?"+r),n&&"#"!==n&&(a+="#"===n.charAt(0)?n:"#"+n),a}function p(e,t,r,n){var a;"string"===typeof e?(a=function(e){var t=e||"/",r="",n="",a=t.indexOf("#");-1!==a&&(n=t.substr(a),t=t.substr(0,a));var i=t.indexOf("?");return-1!==i&&(r=t.substr(i),t=t.substr(0,i)),{pathname:t,search:"?"===r?"":r,hash:"#"===n?"":n}}(e)).state=t:(void 0===(a=Object(c.a)({},e)).pathname&&(a.pathname=""),a.search?"?"!==a.search.charAt(0)&&(a.search="?"+a.search):a.search="",a.hash?"#"!==a.hash.charAt(0)&&(a.hash="#"+a.hash):a.hash="",void 0!==t&&void 0===a.state&&(a.state=t));try{a.pathname=decodeURI(a.pathname)}catch(i){throw i instanceof URIError?new URIError('Pathname "'+a.pathname+'" could not be decoded. This is likely caused by an invalid percent-encoding.'):i}return r&&(a.key=r),n?a.pathname?"/"!==a.pathname.charAt(0)&&(a.pathname=Object(s.a)(a.pathname,n.pathname)):a.pathname=n.pathname:a.pathname||(a.pathname="/"),a}function m(){var e=null;var t=[];return{setPrompt:function(t){return e=t,function(){e===t&&(e=null)}},confirmTransitionTo:function(t,r,n,a){if(null!=e){var i="function"===typeof e?e(t,r):e;"string"===typeof i?"function"===typeof n?n(i,a):a(!0):a(!1!==i)}else a(!0)},appendListener:function(e){var r=!0;function n(){r&&e.apply(void 0,arguments)}return t.push(n),function(){r=!1,t=t.filter((function(e){return e!==n}))}},notifyListeners:function(){for(var e=arguments.length,r=new Array(e),n=0;n=256)throw new Error("Depth too large!");return w(Object(o.b)([null!=this.privateKey?"0x0488ADE4":"0x0488B21E",Object(o.h)(this.depth),this.parentFingerprint,Object(o.g)(Object(o.h)(this.index),4),this.chainCode,null!=this.privateKey?Object(o.b)(["0x00",this.privateKey]):this.publicKey]))}},{key:"neuter",value:function(){return new e(_,null,this.publicKey,this.parentFingerprint,this.chainCode,this.index,this.depth,this.path)}},{key:"_derive",value:function(t){if(t>4294967295)throw new Error("invalid index - "+String(t));var r=this.path;r&&(r+="/"+(2147483647&t));var n=new Uint8Array(37);if(2147483648&t){if(!this.privateKey)throw new Error("cannot derive child of neutered node");n.set(Object(o.a)(this.privateKey),1),r&&(r+="'")}else n.set(Object(o.a)(this.publicKey));for(var a=24;a>=0;a-=8)n[33+(a>>3)]=t>>24-a&255;var i=Object(o.a)(Object(l.a)(b.a.sha512,this.chainCode,n)),s=i.slice(0,32),f=i.slice(32),d=null,h=null;this.privateKey?d=y(c.a.from(s).add(this.privateKey).mod(v)):h=new u.a(Object(o.h)(s))._addPoint(this.publicKey);var p=r,m=this.mnemonic;return m&&(p=Object.freeze({phrase:m.phrase,path:r,locale:m.locale||"en"})),new e(_,d,h,this.fingerprint,y(f),t,this.depth+1,p)}},{key:"derivePath",value:function(e){var t=e.split("/");if(0===t.length||"m"===t[0]&&0!==this.depth)throw new Error("invalid path - "+e);"m"===t[0]&&t.shift();for(var r=this,n=0;n=2147483648)throw new Error("invalid path index - "+a);r=r._derive(2147483648+i)}else{if(!a.match(/^[0-9]+$/))throw new Error("invalid path component - "+a);var o=parseInt(a);if(o>=2147483648)throw new Error("invalid path index - "+a);r=r._derive(o)}}return r}}],[{key:"_fromSeed",value:function(t,r){var n=Object(o.a)(t);if(n.length<16||n.length>64)throw new Error("invalid seed");var a=Object(o.a)(Object(l.a)(b.a.sha512,g,n));return new e(_,y(a.slice(0,32)),null,"0x00000000",y(a.slice(32)),0,0,r)}},{key:"fromMnemonic",value:function(t,r,n){return t=A(O(t,n=k(n)),n),e._fromSeed(E(t,r),{phrase:t,path:"m",locale:n.locale})}},{key:"fromSeed",value:function(t){return e._fromSeed(t,null)}},{key:"fromExtendedKey",value:function(t){var r=i.a.decode(t);82===r.length&&w(r.slice(0,78))===t||m.throwArgumentError("invalid extended key","extendedKey","[REDACTED]");var n=r[4],a=Object(o.h)(r.slice(5,9)),c=parseInt(Object(o.h)(r.slice(9,13)).substring(2),16),s=Object(o.h)(r.slice(13,45)),f=r.slice(45,78);switch(Object(o.h)(r.slice(0,4))){case"0x0488b21e":case"0x043587cf":return new e(_,null,Object(o.h)(f),a,s,c,n,null);case"0x0488ade4":case"0x04358394 ":if(0!==f[0])break;return new e(_,Object(o.h)(f.slice(1)),null,a,s,c,n,null)}return m.throwArgumentError("invalid extended key","extendedKey","[REDACTED]")}}]),e}();function E(e,t){t||(t="");var r=Object(s.c)("mnemonic"+t,s.a.NFKD);return Object(f.a)(Object(s.c)(e,s.a.NFKD),r,2048,64,"sha512")}function O(e,t){t=k(t),m.checkNormalize();var r=t.split(e);if(r.length%3!==0)throw new Error("invalid mnemonic");for(var n=Object(o.a)(new Uint8Array(Math.ceil(11*r.length/8))),a=0,i=0;i>3]|=1<<7-a%8),a++}var f=32*r.length/3,d=x(r.length/3);if((Object(o.a)(Object(l.c)(n.slice(0,f/8)))[0]&d)!==(n[n.length-1]&d))throw new Error("invalid checksum");return Object(o.h)(n.slice(0,f/8))}function A(e,t){if(t=k(t),(e=Object(o.a)(e)).length%4!==0||e.length<16||e.length>32)throw new Error("invalid entropy");for(var r=[0],n=11,a=0;a8?(r[r.length-1]<<=8,r[r.length-1]|=e[a],n-=8):(r[r.length-1]<<=n,r[r.length-1]|=e[a]>>8-n,r.push(e[a]&(1<<8-n)-1),n+=3);var i=e.length/4,c=Object(o.a)(Object(l.c)(e))[0]&x(i);return r[r.length-1]<<=i,r[r.length-1]|=c>>8-i,t.join(r.map((function(e){return t.getWord(e)})))}function T(e,t){try{return O(e,t),!0}catch(r){}return!1}function j(e){return("number"!==typeof e||e<0||e>=2147483648||e%1)&&m.throwArgumentError("invalid account index","index",e),"m/44'/60'/".concat(e,"'/0/0")}},function(e,t,r){"use strict";r.d(t,"a",(function(){return n})),r.d(t,"c",(function(){return a})),r.d(t,"b",(function(){return s})),r.d(t,"f",(function(){return d})),r.d(t,"d",(function(){return l})),r.d(t,"e",(function(){return b})),r.d(t,"h",(function(){return h})),r.d(t,"g",(function(){return p}));var n,a,i=r(10),o=new(r(16).Logger)("strings/5.3.0");function c(e,t,r,n,i){if(e===a.BAD_PREFIX||e===a.UNEXPECTED_CONTINUE){for(var o=0,c=t+1;c>6===2;c++)o++;return o}return e===a.OVERRUN?r.length-t-1:0}!function(e){e.current="",e.NFC="NFC",e.NFD="NFD",e.NFKC="NFKC",e.NFKD="NFKD"}(n||(n={})),function(e){e.UNEXPECTED_CONTINUE="unexpected continuation byte",e.BAD_PREFIX="bad codepoint prefix",e.OVERRUN="string overrun",e.MISSING_CONTINUE="missing continuation byte",e.OUT_OF_RANGE="out of UTF-8 range",e.UTF16_SURROGATE="UTF-16 surrogate",e.OVERLONG="overlong representation"}(a||(a={}));var s=Object.freeze({error:function(e,t,r,n,a){return o.throwArgumentError("invalid codepoint at offset ".concat(t,"; ").concat(e),"bytes",r)},ignore:c,replace:function(e,t,r,n,i){return e===a.OVERLONG?(n.push(i),0):(n.push(65533),c(e,t,r))}});function f(e,t){null==t&&(t=s.error),e=Object(i.arrayify)(e);for(var r=[],n=0;n>7!==0){var c=null,f=null;if(192===(224&o))c=1,f=127;else if(224===(240&o))c=2,f=2047;else{if(240!==(248&o)){n+=t(128===(192&o)?a.UNEXPECTED_CONTINUE:a.BAD_PREFIX,n-1,e,r);continue}c=3,f=65535}if(n-1+c>=e.length)n+=t(a.OVERRUN,n-1,e,r);else{for(var d=o&(1<<8-c-1)-1,u=0;u1114111?n+=t(a.OUT_OF_RANGE,n-1-c,e,r,d):d>=55296&&d<=57343?n+=t(a.UTF16_SURROGATE,n-1-c,e,r,d):d<=f?n+=t(a.OVERLONG,n-1-c,e,r,d):r.push(d))}}else r.push(o)}return r}function d(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:n.current;t!=n.current&&(o.checkNormalize(),e=e.normalize(t));for(var r=[],a=0;a>6|192),r.push(63&c|128);else if(55296==(64512&c)){a++;var s=e.charCodeAt(a);if(a>=e.length||56320!==(64512&s))throw new Error("invalid utf-8 string");var f=65536+((1023&c)<<10)+(1023&s);r.push(f>>18|240),r.push(f>>12&63|128),r.push(f>>6&63|128),r.push(63&f|128)}else r.push(c>>12|224),r.push(c>>6&63|128),r.push(63&c|128)}return Object(i.arrayify)(r)}function u(e){var t="0000"+e.toString(16);return"\\u"+t.substring(t.length-4)}function l(e,t){return'"'+f(e,t).map((function(e){if(e<256){switch(e){case 8:return"\\b";case 9:return"\\t";case 10:return"\\n";case 13:return"\\r";case 34:return'\\"';case 92:return"\\\\"}if(e>=32&&e<127)return String.fromCharCode(e)}return e<=65535?u(e):u(55296+((e-=65536)>>10&1023))+u(56320+(1023&e))})).join("")+'"'}function b(e){return e.map((function(e){return e<=65535?String.fromCharCode(e):(e-=65536,String.fromCharCode(55296+(e>>10&1023),56320+(1023&e)))})).join("")}function h(e,t){return b(f(e,t))}function p(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:n.current;return f(d(e,t))}},function(e,t,r){"use strict";function n(e){return(n="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}r.d(t,"a",(function(){return n}))},function(e,t,r){"use strict";r.r(t),r.d(t,"TransactionTypes",(function(){return n})),r.d(t,"computeAddress",(function(){return g})),r.d(t,"recoverAddress",(function(){return x})),r.d(t,"accessListify",(function(){return k})),r.d(t,"serialize",(function(){return E})),r.d(t,"parse",(function(){return A}));var n,a=r(38),i=r(46),o=r(5),c=r(1174),s=r(40),f=r(9),d=r(104),u=r(113),l=r(11),b=new l.a("transactions/5.5.0");function h(e){return"0x"===e?null:Object(a.a)(e)}function p(e){return"0x"===e?c.d:i.a.from(e)}!function(e){e[e.legacy=0]="legacy",e[e.eip2930=1]="eip2930",e[e.eip1559=2]="eip1559"}(n||(n={}));var m=[{name:"nonce",maxLength:32,numeric:!0},{name:"gasPrice",maxLength:32,numeric:!0},{name:"gasLimit",maxLength:32,numeric:!0},{name:"to",length:20},{name:"value",maxLength:32,numeric:!0},{name:"data"}],v={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,type:!0,value:!0};function g(e){var t=Object(u.b)(e);return Object(a.a)(Object(o.e)(Object(s.a)(Object(o.e)(t,1)),12))}function x(e,t){return g(Object(u.c)(Object(o.a)(e),t))}function y(e,t){var r=Object(o.n)(i.a.from(e).toHexString());return r.length>32&&b.throwArgumentError("invalid length for "+t,"transaction:"+t,e),r}function w(e,t){return{address:Object(a.a)(e),storageKeys:(t||[]).map((function(t,r){return 32!==Object(o.d)(t)&&b.throwArgumentError("invalid access list storageKey","accessList[".concat(e,":").concat(r,"]"),t),t.toLowerCase()}))}}function k(e){if(Array.isArray(e))return e.map((function(e,t){return Array.isArray(e)?(e.length>2&&b.throwArgumentError("access list expected to be [ address, storageKeys[] ]","value[".concat(t,"]"),e),w(e[0],e[1])):w(e.address,e.storageKeys)}));var t=Object.keys(e).map((function(t){var r=e[t].reduce((function(e,t){return e[t]=!0,e}),{});return w(t,Object.keys(r).sort())}));return t.sort((function(e,t){return e.address.localeCompare(t.address)})),t}function _(e){return k(e).map((function(e){return[e.address,e.storageKeys]}))}function M(e,t){if(null!=e.gasPrice){var r=i.a.from(e.gasPrice),n=i.a.from(e.maxFeePerGas||0);r.eq(n)||b.throwArgumentError("mismatch EIP-1559 gasPrice != maxFeePerGas","tx",{gasPrice:r,maxFeePerGas:n})}var c=[y(e.chainId||0,"chainId"),y(e.nonce||0,"nonce"),y(e.maxPriorityFeePerGas||0,"maxPriorityFeePerGas"),y(e.maxFeePerGas||0,"maxFeePerGas"),y(e.gasLimit||0,"gasLimit"),null!=e.to?Object(a.a)(e.to):"0x",y(e.value||0,"value"),e.data||"0x",_(e.accessList||[])];if(t){var s=Object(o.m)(t);c.push(y(s.recoveryParam,"recoveryParam")),c.push(Object(o.n)(s.r)),c.push(Object(o.n)(s.s))}return Object(o.c)(["0x02",d.b(c)])}function S(e,t){var r=[y(e.chainId||0,"chainId"),y(e.nonce||0,"nonce"),y(e.gasPrice||0,"gasPrice"),y(e.gasLimit||0,"gasLimit"),null!=e.to?Object(a.a)(e.to):"0x",y(e.value||0,"value"),e.data||"0x",_(e.accessList||[])];if(t){var n=Object(o.m)(t);r.push(y(n.recoveryParam,"recoveryParam")),r.push(Object(o.n)(n.r)),r.push(Object(o.n)(n.s))}return Object(o.c)(["0x01",d.b(r)])}function E(e,t){if(null==e.type||0===e.type)return null!=e.accessList&&b.throwArgumentError("untyped transactions do not support accessList; include type: 1","transaction",e),function(e,t){Object(f.b)(e,v);var r=[];m.forEach((function(t){var n=e[t.name]||[],a={};t.numeric&&(a.hexPad="left"),n=Object(o.a)(Object(o.h)(n,a)),t.length&&n.length!==t.length&&n.length>0&&b.throwArgumentError("invalid length for "+t.name,"transaction:"+t.name,n),t.maxLength&&(n=Object(o.n)(n)).length>t.maxLength&&b.throwArgumentError("invalid length for "+t.name,"transaction:"+t.name,n),r.push(Object(o.h)(n))}));var n=0;if(null!=e.chainId?"number"!==typeof(n=e.chainId)&&b.throwArgumentError("invalid transaction.chainId","transaction",e):t&&!Object(o.j)(t)&&t.v>28&&(n=Math.floor((t.v-35)/2)),0!==n&&(r.push(Object(o.h)(n)),r.push("0x"),r.push("0x")),!t)return d.b(r);var a=Object(o.m)(t),i=27+a.recoveryParam;return 0!==n?(r.pop(),r.pop(),r.pop(),i+=2*n+8,a.v>28&&a.v!==i&&b.throwArgumentError("transaction.chainId/signature.v mismatch","signature",t)):a.v!==i&&b.throwArgumentError("transaction.chainId/signature.v mismatch","signature",t),r.push(Object(o.h)(i)),r.push(Object(o.n)(Object(o.a)(a.r))),r.push(Object(o.n)(Object(o.a)(a.s))),d.b(r)}(e,t);switch(e.type){case 1:return S(e,t);case 2:return M(e,t)}return b.throwError("unsupported transaction type: ".concat(e.type),l.a.errors.UNSUPPORTED_OPERATION,{operation:"serializeTransaction",transactionType:e.type})}function O(e,t,r){try{var n=p(t[0]).toNumber();if(0!==n&&1!==n)throw new Error("bad recid");e.v=n}catch(i){b.throwArgumentError("invalid v for transaction type: 1","v",t[0])}e.r=Object(o.g)(t[1],32),e.s=Object(o.g)(t[2],32);try{var a=Object(s.a)(r(e));e.from=x(a,{r:e.r,s:e.s,recoveryParam:e.v})}catch(i){console.log(i)}}function A(e){var t=Object(o.a)(e);if(t[0]>127)return function(e){var t=d.a(e);9!==t.length&&6!==t.length&&b.throwArgumentError("invalid raw transaction","rawTransaction",e);var r={nonce:p(t[0]).toNumber(),gasPrice:p(t[1]),gasLimit:p(t[2]),to:h(t[3]),value:p(t[4]),data:t[5],chainId:0};if(6===t.length)return r;try{r.v=i.a.from(t[6]).toNumber()}catch(f){return console.log(f),r}if(r.r=Object(o.g)(t[7],32),r.s=Object(o.g)(t[8],32),i.a.from(r.r).isZero()&&i.a.from(r.s).isZero())r.chainId=r.v,r.v=0;else{r.chainId=Math.floor((r.v-35)/2),r.chainId<0&&(r.chainId=0);var n=r.v-27,a=t.slice(0,6);0!==r.chainId&&(a.push(Object(o.h)(r.chainId)),a.push("0x"),a.push("0x"),n-=2*r.chainId+8);var c=Object(s.a)(d.b(a));try{r.from=x(c,{r:Object(o.h)(r.r),s:Object(o.h)(r.s),recoveryParam:n})}catch(f){console.log(f)}r.hash=Object(s.a)(e)}return r.type=null,r}(t);switch(t[0]){case 1:return function(e){var t=d.a(e.slice(1));8!==t.length&&11!==t.length&&b.throwArgumentError("invalid component count for transaction type: 1","payload",Object(o.h)(e));var r={type:1,chainId:p(t[0]).toNumber(),nonce:p(t[1]).toNumber(),gasPrice:p(t[2]),gasLimit:p(t[3]),to:h(t[4]),value:p(t[5]),data:t[6],accessList:k(t[7])};return 8===t.length||(r.hash=Object(s.a)(e),O(r,t.slice(8),S)),r}(t);case 2:return function(e){var t=d.a(e.slice(1));9!==t.length&&12!==t.length&&b.throwArgumentError("invalid component count for transaction type: 2","payload",Object(o.h)(e));var r=p(t[2]),n=p(t[3]),a={type:2,chainId:p(t[0]).toNumber(),nonce:p(t[1]).toNumber(),maxPriorityFeePerGas:r,maxFeePerGas:n,gasPrice:null,gasLimit:p(t[4]),to:h(t[5]),value:p(t[6]),data:t[7],accessList:k(t[8])};return 9===t.length||(a.hash=Object(s.a)(e),O(a,t.slice(9),M)),a}(t)}return b.throwError("unsupported transaction type: ".concat(t[0]),l.a.errors.UNSUPPORTED_OPERATION,{operation:"parseTransaction",transactionType:t[0]})}},function(e,t,r){"use strict";var n=r(284),a="object"==typeof self&&self&&self.Object===Object&&self,i=n.a||a||Function("return this")();t.a=i},function(e,t,r){"use strict";r.d(t,"d",(function(){return v})),r.d(t,"g",(function(){return x})),r.d(t,"e",(function(){return w})),r.d(t,"c",(function(){return k})),r.d(t,"a",(function(){return E})),r.d(t,"f",(function(){return O})),r.d(t,"b",(function(){return T}));var n=r(13),a=r(14),i=r(6),o=r(7),c=r(51),s=r(15),f=r(16),d=r(110),u=new f.Logger(d.a),l={},b={calldata:!0,memory:!0,storage:!0},h={calldata:!0,memory:!0};function p(e,t){if("bytes"===e||"string"===e){if(b[t])return!0}else if("address"===e){if("payable"===t)return!0}else if((e.indexOf("[")>=0||"tuple"===e)&&h[t])return!0;return(b[t]||"payable"===t)&&u.throwArgumentError("invalid modifier","name",t),!1}function m(e,t){for(var r in t)Object(s.defineReadOnly)(e,r,t[r])}var v=Object.freeze({sighash:"sighash",minimal:"minimal",full:"full",json:"json"}),g=new RegExp(/^(.*)\[([0-9]*)\]$/),x=function(){function e(t,r){Object(i.a)(this,e),t!==l&&u.throwError("use fromString",f.Logger.errors.UNSUPPORTED_OPERATION,{operation:"new ParamType()"}),m(this,r);var n=this.type.match(g);m(this,n?{arrayLength:parseInt(n[2]||"-1"),arrayChildren:e.fromObject({type:n[1],components:this.components}),baseType:"array"}:{arrayLength:null,arrayChildren:null,baseType:null!=this.components?"tuple":this.type}),this._isParamType=!0,Object.freeze(this)}return Object(o.a)(e,[{key:"format",value:function(e){if(e||(e=v.sighash),v[e]||u.throwArgumentError("invalid format type","format",e),e===v.json){var t={type:"tuple"===this.baseType?"tuple":this.type,name:this.name||void 0};return"boolean"===typeof this.indexed&&(t.indexed=this.indexed),this.components&&(t.components=this.components.map((function(t){return JSON.parse(t.format(e))}))),JSON.stringify(t)}var r="";return"array"===this.baseType?(r+=this.arrayChildren.format(e),r+="["+(this.arrayLength<0?"":String(this.arrayLength))+"]"):"tuple"===this.baseType?(e!==v.sighash&&(r+=this.type),r+="("+this.components.map((function(t){return t.format(e)})).join(e===v.full?", ":",")+")"):r+=this.type,e!==v.sighash&&(!0===this.indexed&&(r+=" indexed"),e===v.full&&this.name&&(r+=" "+this.name)),r}}],[{key:"from",value:function(t,r){return"string"===typeof t?e.fromString(t,r):e.fromObject(t)}},{key:"fromObject",value:function(t){return e.isParamType(t)?t:new e(l,{name:t.name||null,type:j(t.type),indexed:null==t.indexed?null:!!t.indexed,components:t.components?t.components.map(e.fromObject):null})}},{key:"fromString",value:function(t,r){return function(t){return e.fromObject({name:t.name,type:t.type,indexed:t.indexed,components:t.components})}(function(e,t){var r=e;function n(t){u.throwArgumentError("unexpected character at position ".concat(t),"param",e)}function a(e){var r={type:"",name:"",parent:e,state:{allowType:!0}};return t&&(r.indexed=!1),r}e=e.replace(/\s/g," ");for(var i={type:"",name:"",state:{allowType:!0}},o=i,c=0;c2&&u.throwArgumentError("invalid human-readable ABI signature","value",e),r[1].match(/^[0-9]+$/)||u.throwArgumentError("invalid human-readable ABI signature gas","value",e),t.gas=c.a.from(r[1]),r[0]):e}function M(e,t){t.constant=!1,t.payable=!1,t.stateMutability="nonpayable",e.split(" ").forEach((function(e){switch(e.trim()){case"constant":t.constant=!0;break;case"payable":t.payable=!0,t.stateMutability="payable";break;case"nonpayable":t.payable=!1,t.stateMutability="nonpayable";break;case"pure":t.constant=!0,t.stateMutability="pure";break;case"view":t.constant=!0,t.stateMutability="view";break;case"external":case"public":case"":break;default:console.log("unknown modifier: "+e)}}))}function S(e){var t={constant:!1,payable:!0,stateMutability:"payable"};return null!=e.stateMutability?(t.stateMutability=e.stateMutability,t.constant="view"===t.stateMutability||"pure"===t.stateMutability,null!=e.constant&&!!e.constant!==t.constant&&u.throwArgumentError("cannot have constant function with mutability "+t.stateMutability,"value",e),t.payable="payable"===t.stateMutability,null!=e.payable&&!!e.payable!==t.payable&&u.throwArgumentError("cannot have payable function with mutability "+t.stateMutability,"value",e)):null!=e.payable?(t.payable=!!e.payable,null!=e.constant||t.payable||"constructor"===e.type||u.throwArgumentError("unable to determine stateMutability","value",e),t.constant=!!e.constant,t.constant?t.stateMutability="view":t.stateMutability=t.payable?"payable":"nonpayable",t.payable&&t.constant&&u.throwArgumentError("cannot have constant payable function","value",e)):null!=e.constant?(t.constant=!!e.constant,t.payable=!t.constant,t.stateMutability=t.constant?"view":"payable"):"constructor"!==e.type&&u.throwArgumentError("unable to determine stateMutability","value",e),t}var E=function(e){Object(n.a)(r,e);var t=Object(a.a)(r);function r(){return Object(i.a)(this,r),t.apply(this,arguments)}return Object(o.a)(r,[{key:"format",value:function(e){if(e||(e=v.sighash),v[e]||u.throwArgumentError("invalid format type","format",e),e===v.json)return JSON.stringify({type:"constructor",stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map((function(t){return JSON.parse(t.format(e))}))});e===v.sighash&&u.throwError("cannot format a constructor for sighash",f.Logger.errors.UNSUPPORTED_OPERATION,{operation:"format(sighash)"});var t="constructor("+this.inputs.map((function(t){return t.format(e)})).join(e===v.full?", ":",")+") ";return this.stateMutability&&"nonpayable"!==this.stateMutability&&(t+=this.stateMutability+" "),t.trim()}}],[{key:"from",value:function(e){return"string"===typeof e?r.fromString(e):r.fromObject(e)}},{key:"fromObject",value:function(e){if(r.isConstructorFragment(e))return e;"constructor"!==e.type&&u.throwArgumentError("invalid constructor object","value",e);var t=S(e);t.constant&&u.throwArgumentError("constructor cannot be constant","value",e);var n={name:null,type:e.type,inputs:e.inputs?e.inputs.map(x.fromObject):[],payable:t.payable,stateMutability:t.stateMutability,gas:e.gas?c.a.from(e.gas):null};return new r(l,n)}},{key:"fromString",value:function(e){var t={type:"constructor"},n=(e=_(e,t)).match(R);return n&&"constructor"===n[1].trim()||u.throwArgumentError("invalid constructor string","value",e),t.inputs=y(n[2].trim(),!1),M(n[3].trim(),t),r.fromObject(t)}},{key:"isConstructorFragment",value:function(e){return e&&e._isFragment&&"constructor"===e.type}}]),r}(w),O=function(e){Object(n.a)(r,e);var t=Object(a.a)(r);function r(){return Object(i.a)(this,r),t.apply(this,arguments)}return Object(o.a)(r,[{key:"format",value:function(e){if(e||(e=v.sighash),v[e]||u.throwArgumentError("invalid format type","format",e),e===v.json)return JSON.stringify({type:"function",name:this.name,constant:this.constant,stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map((function(t){return JSON.parse(t.format(e))})),outputs:this.outputs.map((function(t){return JSON.parse(t.format(e))}))});var t="";return e!==v.sighash&&(t+="function "),t+=this.name+"("+this.inputs.map((function(t){return t.format(e)})).join(e===v.full?", ":",")+") ",e!==v.sighash&&(this.stateMutability?"nonpayable"!==this.stateMutability&&(t+=this.stateMutability+" "):this.constant&&(t+="view "),this.outputs&&this.outputs.length&&(t+="returns ("+this.outputs.map((function(t){return t.format(e)})).join(", ")+") "),null!=this.gas&&(t+="@"+this.gas.toString()+" ")),t.trim()}}],[{key:"from",value:function(e){return"string"===typeof e?r.fromString(e):r.fromObject(e)}},{key:"fromObject",value:function(e){if(r.isFunctionFragment(e))return e;"function"!==e.type&&u.throwArgumentError("invalid function object","value",e);var t=S(e),n={type:e.type,name:C(e.name),constant:t.constant,inputs:e.inputs?e.inputs.map(x.fromObject):[],outputs:e.outputs?e.outputs.map(x.fromObject):[],payable:t.payable,stateMutability:t.stateMutability,gas:e.gas?c.a.from(e.gas):null};return new r(l,n)}},{key:"fromString",value:function(e){var t={type:"function"},n=(e=_(e,t)).split(" returns ");n.length>2&&u.throwArgumentError("invalid function string","value",e);var a=n[0].match(R);if(a||u.throwArgumentError("invalid function signature","value",e),t.name=a[1].trim(),t.name&&C(t.name),t.inputs=y(a[2],!1),M(a[3].trim(),t),n.length>1){var i=n[1].match(R);""==i[1].trim()&&""==i[3].trim()||u.throwArgumentError("unexpected tokens","value",e),t.outputs=y(i[2],!1)}else t.outputs=[];return r.fromObject(t)}},{key:"isFunctionFragment",value:function(e){return e&&e._isFragment&&"function"===e.type}}]),r}(E);function A(e){var t=e.format();return"Error(string)"!==t&&"Panic(uint256)"!==t||u.throwArgumentError("cannot specify user defined ".concat(t," error"),"fragment",e),e}var T=function(e){Object(n.a)(r,e);var t=Object(a.a)(r);function r(){return Object(i.a)(this,r),t.apply(this,arguments)}return Object(o.a)(r,[{key:"format",value:function(e){if(e||(e=v.sighash),v[e]||u.throwArgumentError("invalid format type","format",e),e===v.json)return JSON.stringify({type:"error",name:this.name,inputs:this.inputs.map((function(t){return JSON.parse(t.format(e))}))});var t="";return e!==v.sighash&&(t+="error "),(t+=this.name+"("+this.inputs.map((function(t){return t.format(e)})).join(e===v.full?", ":",")+") ").trim()}}],[{key:"from",value:function(e){return"string"===typeof e?r.fromString(e):r.fromObject(e)}},{key:"fromObject",value:function(e){if(r.isErrorFragment(e))return e;"error"!==e.type&&u.throwArgumentError("invalid error object","value",e);var t={type:e.type,name:C(e.name),inputs:e.inputs?e.inputs.map(x.fromObject):[]};return A(new r(l,t))}},{key:"fromString",value:function(e){var t={type:"error"},n=e.match(R);return n||u.throwArgumentError("invalid error signature","value",e),t.name=n[1].trim(),t.name&&C(t.name),t.inputs=y(n[2],!1),A(r.fromObject(t))}},{key:"isErrorFragment",value:function(e){return e&&e._isFragment&&"error"===e.type}}]),r}(w);function j(e){return e.match(/^uint($|[^1-9])/)?e="uint256"+e.substring(4):e.match(/^int($|[^1-9])/)&&(e="int256"+e.substring(3)),e}var P=new RegExp("^[A-Za-z_][A-Za-z0-9_]*$");function C(e){return e&&e.match(P)||u.throwArgumentError('invalid identifier "'.concat(e,'"'),"value",e),e}var R=new RegExp("^([^)(]*)\\((.*)\\)([^)(]*)$")},function(e,t,r){"use strict";r.d(t,"a",(function(){return E})),r.d(t,"b",(function(){return j})),r.d(t,"c",(function(){return w})),r.d(t,"d",(function(){return L})),r.d(t,"e",(function(){return y})),r.d(t,"f",(function(){return T})),r.d(t,"g",(function(){return F}));var n=r(72),a=r(1),i=r.n(a),o=(r(12),r(22)),c=r(282),s=r(283),f=r(23);function d(e){var t=e.pathname,r=e.search,n=e.hash,a=t||"/";return r&&"?"!==r&&(a+="?"===r.charAt(0)?r:"?"+r),n&&"#"!==n&&(a+="#"===n.charAt(0)?n:"#"+n),a}function u(e,t,r,n){var a;"string"===typeof e?(a=function(e){var t=e||"/",r="",n="",a=t.indexOf("#");-1!==a&&(n=t.substr(a),t=t.substr(0,a));var i=t.indexOf("?");return-1!==i&&(r=t.substr(i),t=t.substr(0,i)),{pathname:t,search:"?"===r?"":r,hash:"#"===n?"":n}}(e)).state=t:(void 0===(a=Object(o.a)({},e)).pathname&&(a.pathname=""),a.search?"?"!==a.search.charAt(0)&&(a.search="?"+a.search):a.search="",a.hash?"#"!==a.hash.charAt(0)&&(a.hash="#"+a.hash):a.hash="",void 0!==t&&void 0===a.state&&(a.state=t));try{a.pathname=decodeURI(a.pathname)}catch(i){throw i instanceof URIError?new URIError('Pathname "'+a.pathname+'" could not be decoded. This is likely caused by an invalid percent-encoding.'):i}return r&&(a.key=r),n?a.pathname?"/"!==a.pathname.charAt(0)&&(a.pathname=Object(c.a)(a.pathname,n.pathname)):a.pathname=n.pathname:a.pathname||(a.pathname="/"),a}function l(){var e=null;var t=[];return{setPrompt:function(t){return e=t,function(){e===t&&(e=null)}},confirmTransitionTo:function(t,r,n,a){if(null!=e){var i="function"===typeof e?e(t,r):e;"string"===typeof i?"function"===typeof n?n(i,a):a(!0):a(!1!==i)}else a(!0)},appendListener:function(e){var r=!0;function n(){r&&e.apply(void 0,arguments)}return t.push(n),function(){r=!1,t=t.filter((function(e){return e!==n}))}},notifyListeners:function(){for(var e=arguments.length,r=new Array(e),n=0;nt?r.splice(t,r.length-t,n):r.push(n),p({action:"PUSH",location:n,index:t,entries:r})}}))},replace:function(e,t){var n=u(e,t,m(),w.location);h.confirmTransitionTo(n,"REPLACE",r,(function(e){e&&(w.entries[w.index]=n,p({action:"REPLACE",location:n}))}))},go:y,goBack:function(){y(-1)},goForward:function(){y(1)},canGo:function(e){var t=w.index+e;return t>=0&&t0&&n%1===0,"invalid connection throttle limit","connection.throttleLimit",n);var o="object"===typeof e?e.throttleCallback:null,c="object"===typeof e&&"number"===typeof e.throttleSlotInterval?e.throttleSlotInterval:100;b.assertArgument(c>0&&c%1===0,"invalid connection throttle slot interval","connection.throttleSlotInterval",c);var d={},m=null,v={method:"GET"},g=!1,x=12e4;if("string"===typeof e)m=e;else if("object"===typeof e){if(null!=e&&null!=e.url||b.throwArgumentError("missing URL","connection.url",e),m=e.url,"number"===typeof e.timeout&&e.timeout>0&&(x=e.timeout),e.headers)for(var y in e.headers)d[y.toLowerCase()]={key:y,value:String(e.headers[y])},["if-none-match","if-modified-since"].indexOf(y.toLowerCase())>=0&&(g=!0);if(v.allowGzip=!!e.allowGzip,null!=e.user&&null!=e.password){"https:"!==m.substring(0,6)&&!0!==e.allowInsecureAuthentication&&b.throwError("basic authentication requires a secure https url",f.Logger.errors.INVALID_ARGUMENT,{argument:"url",url:m,user:e.user,password:"[REDACTED]"});var w=e.user+":"+e.password;d.authorization={key:"Authorization",value:"Basic "+Object(i.b)(Object(s.f)(w))}}}t&&(v.method="POST",v.body=t,null==d["content-type"]&&(d["content-type"]={key:"Content-Type",value:"application/octet-stream"}),null==d["content-length"]&&(d["content-length"]={key:"Content-Length",value:String(t.length)}));var k={};Object.keys(d).forEach((function(e){var t=d[e];k[t.key]=t.value})),v.headers=k;var _=function(){var e=null;return{promise:new Promise((function(t,r){x&&(e=setTimeout((function(){null!=e&&(e=null,r(b.makeError("timeout",f.Logger.errors.TIMEOUT,{requestBody:p(v.body,k["content-type"]),requestMethod:v.method,timeout:x,url:m})))}),x))})),cancel:function(){null!=e&&(clearTimeout(e),e=null)}}}(),M=function(){return l(this,void 0,void 0,a.a.mark((function e(){var t,i,s,d,l,x,y,w,M;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:t=0;case 1:if(!(t=300)&&(_.cancel(),b.throwError("bad response",f.Logger.errors.SERVER_ERROR,{status:i.statusCode,headers:i.headers,body:p(x,i.headers?i.headers["content-type"]:null),requestBody:p(v.body,k["content-type"]),requestMethod:v.method,url:m})),!r){e.next=52;break}return e.prev=29,e.next=32,r(x,i);case 32:return y=e.sent,_.cancel(),e.abrupt("return",y);case 37:if(e.prev=37,e.t1=e.catch(29),!(e.t1.throttleRetry&&tc)return void(o()&&n(new Error("retry limit reached")));var f=t.interval*parseInt(String(Math.random()*Math.pow(2,s)));ft.ceiling&&(f=t.ceiling),setTimeout(a,f)}return null}),(function(e){o()&&n(e)}))}()}))}},function(e,t,r){"use strict";var n=r(703),a=r(704);e.exports={errors:n,formatters:a}},,function(e,t,r){var n=r(625),a=r(398),i=r(700),o=r(131),c=r(298),s=function e(t,r){var n=[];return r.forEach((function(r){if("object"===typeof r.components){if("tuple"!==r.type.substring(0,5))throw new Error("components found but type is not tuple; report on GitHub");var a="",i=r.type.indexOf("[");i>=0&&(a=r.type.substring(i));var o=e(t,r.components);Array.isArray(o)&&t?n.push("tuple("+o.join(",")+")"+a):t?n.push("("+o+")"):n.push("("+o.join(",")+")"+a)}else n.push(r.type)})),n},f=function(e){if(!a.isHexStrict(e))throw new Error("The parameter must be a valid HEX string.");var t="",r=0,n=e.length;for("0x"===e.substring(0,2)&&(r=2);r7?r+=e[n].toUpperCase():r+=e[n];return r},toHex:a.toHex,toBN:a.toBN,bytesToHex:a.bytesToHex,hexToBytes:a.hexToBytes,hexToNumberString:a.hexToNumberString,hexToNumber:a.hexToNumber,toDecimal:a.hexToNumber,numberToHex:a.numberToHex,fromDecimal:a.numberToHex,hexToUtf8:a.hexToUtf8,hexToString:a.hexToUtf8,toUtf8:a.hexToUtf8,stripHexPrefix:a.stripHexPrefix,utf8ToHex:a.utf8ToHex,stringToHex:a.utf8ToHex,fromUtf8:a.utf8ToHex,hexToAscii:f,toAscii:f,asciiToHex:d,fromAscii:d,unitMap:n.unitMap,toWei:function(e,t){if(t=u(t),!a.isBN(e)&&"string"!==typeof e)throw new Error("Please pass numbers as strings or BN objects to avoid precision errors.");return a.isBN(e)?n.toWei(e,t):n.toWei(e,t).toString(10)},fromWei:function(e,t){if(t=u(t),!a.isBN(e)&&"string"!==typeof e)throw new Error("Please pass numbers as strings or BN objects to avoid precision errors.");return a.isBN(e)?n.fromWei(e,t):n.fromWei(e,t).toString(10)},padLeft:a.leftPad,leftPad:a.leftPad,padRight:a.rightPad,rightPad:a.rightPad,toTwosComplement:a.toTwosComplement,isBloom:a.isBloom,isUserEthereumAddressInBloom:a.isUserEthereumAddressInBloom,isContractAddressInBloom:a.isContractAddressInBloom,isTopic:a.isTopic,isTopicInBloom:a.isTopicInBloom,isInBloom:a.isInBloom,compareBlockNumbers:function(e,t){if(e==t)return 0;if("genesis"!=e&&"earliest"!=e&&0!=e||"genesis"!=t&&"earliest"!=t&&0!=t){if("genesis"==e||"earliest"==e)return-1;if("genesis"==t||"earliest"==t)return 1;if("latest"==e)return"pending"==t?-1:1;if("latest"===t)return"pending"==e?1:-1;if("pending"==e)return 1;if("pending"==t)return-1;var r=new c(e),n=new c(t);return r.lt(n)?-1:r.eq(n)?0:1}return 0},toNumber:a.toNumber}},function(e,t,r){"use strict";r.d(t,"a",(function(){return h})),r.d(t,"b",(function(){return p})),r.d(t,"c",(function(){return v}));var n=r(6),a=r(7),i=r(38),o=r(46),c=r(5),s=r(1162),f=r(9),d=r(66),u=r(11),l=r(52),b=new u.a(l.a),h=function(){function e(){Object(n.a)(this,e),b.checkNew(this instanceof e?this.constructor:void 0,e),this.formats=this.getDefaultFormats()}return Object(a.a)(e,[{key:"getDefaultFormats",value:function(){var t=this,r={},n=this.address.bind(this),a=this.bigNumber.bind(this),i=this.blockTag.bind(this),o=this.data.bind(this),c=this.hash.bind(this),s=this.hex.bind(this),d=this.number.bind(this),u=this.type.bind(this);return r.transaction={hash:c,type:u,accessList:e.allowNull(this.accessList.bind(this),null),blockHash:e.allowNull(c,null),blockNumber:e.allowNull(d,null),transactionIndex:e.allowNull(d,null),confirmations:e.allowNull(d,null),from:n,gasPrice:e.allowNull(a),maxPriorityFeePerGas:e.allowNull(a),maxFeePerGas:e.allowNull(a),gasLimit:a,to:e.allowNull(n,null),value:a,nonce:d,data:o,r:e.allowNull(this.uint256),s:e.allowNull(this.uint256),v:e.allowNull(d),creates:e.allowNull(n,null),raw:e.allowNull(o)},r.transactionRequest={from:e.allowNull(n),nonce:e.allowNull(d),gasLimit:e.allowNull(a),gasPrice:e.allowNull(a),maxPriorityFeePerGas:e.allowNull(a),maxFeePerGas:e.allowNull(a),to:e.allowNull(n),value:e.allowNull(a),data:e.allowNull((function(e){return t.data(e,!0)})),type:e.allowNull(d),accessList:e.allowNull(this.accessList.bind(this),null)},r.receiptLog={transactionIndex:d,blockNumber:d,transactionHash:c,address:n,topics:e.arrayOf(c),data:o,logIndex:d,blockHash:c},r.receipt={to:e.allowNull(this.address,null),from:e.allowNull(this.address,null),contractAddress:e.allowNull(n,null),transactionIndex:d,root:e.allowNull(s),gasUsed:a,logsBloom:e.allowNull(o),blockHash:c,transactionHash:c,logs:e.arrayOf(this.receiptLog.bind(this)),blockNumber:d,confirmations:e.allowNull(d,null),cumulativeGasUsed:a,effectiveGasPrice:e.allowNull(a),status:e.allowNull(d),type:u},r.block={hash:c,parentHash:c,number:d,timestamp:d,nonce:e.allowNull(s),difficulty:this.difficulty.bind(this),gasLimit:a,gasUsed:a,miner:n,extraData:o,transactions:e.allowNull(e.arrayOf(c)),baseFeePerGas:e.allowNull(a)},r.blockWithTransactions=Object(f.g)(r.block),r.blockWithTransactions.transactions=e.allowNull(e.arrayOf(this.transactionResponse.bind(this))),r.filter={fromBlock:e.allowNull(i,void 0),toBlock:e.allowNull(i,void 0),blockHash:e.allowNull(c,void 0),address:e.allowNull(n,void 0),topics:e.allowNull(this.topics.bind(this),void 0)},r.filterLog={blockNumber:e.allowNull(d),blockHash:e.allowNull(c),transactionIndex:d,removed:e.allowNull(this.boolean.bind(this)),address:n,data:e.allowFalsish(o,"0x"),topics:e.arrayOf(c),transactionHash:c,logIndex:d},r}},{key:"accessList",value:function(e){return Object(d.accessListify)(e||[])}},{key:"number",value:function(e){return"0x"===e?0:o.a.from(e).toNumber()}},{key:"type",value:function(e){return"0x"===e||null==e?0:o.a.from(e).toNumber()}},{key:"bigNumber",value:function(e){return o.a.from(e)}},{key:"boolean",value:function(e){if("boolean"===typeof e)return e;if("string"===typeof e){if("true"===(e=e.toLowerCase()))return!0;if("false"===e)return!1}throw new Error("invalid boolean - "+e)}},{key:"hex",value:function(e,t){return"string"===typeof e&&(t||"0x"===e.substring(0,2)||(e="0x"+e),Object(c.k)(e))?e.toLowerCase():b.throwArgumentError("invalid hash","value",e)}},{key:"data",value:function(e,t){var r=this.hex(e,t);if(r.length%2!==0)throw new Error("invalid data; odd-length - "+e);return r}},{key:"address",value:function(e){return Object(i.a)(e)}},{key:"callAddress",value:function(e){if(!Object(c.k)(e,32))return null;var t=Object(i.a)(Object(c.e)(e,12));return t===s.a?null:t}},{key:"contractAddress",value:function(e){return Object(i.b)(e)}},{key:"blockTag",value:function(e){if(null==e)return"latest";if("earliest"===e)return"0x0";if("latest"===e||"pending"===e)return e;if("number"===typeof e||Object(c.k)(e))return Object(c.f)(e);throw new Error("invalid blockTag")}},{key:"hash",value:function(e,t){var r=this.hex(e,t);return 32!==Object(c.d)(r)?b.throwArgumentError("invalid hash","value",e):r}},{key:"difficulty",value:function(e){if(null==e)return null;var t=o.a.from(e);try{return t.toNumber()}catch(r){}return null}},{key:"uint256",value:function(e){if(!Object(c.k)(e))throw new Error("invalid uint256");return Object(c.g)(e,32)}},{key:"_block",value:function(t,r){null!=t.author&&null==t.miner&&(t.miner=t.author);var n=null!=t._difficulty?t._difficulty:t.difficulty,a=e.check(r,t);return a._difficulty=null==n?null:o.a.from(n),a}},{key:"block",value:function(e){return this._block(e,this.formats.block)}},{key:"blockWithTransactions",value:function(e){return this._block(e,this.formats.blockWithTransactions)}},{key:"transactionRequest",value:function(t){return e.check(this.formats.transactionRequest,t)}},{key:"transactionResponse",value:function(t){null!=t.gas&&null==t.gasLimit&&(t.gasLimit=t.gas),t.to&&o.a.from(t.to).isZero()&&(t.to="0x0000000000000000000000000000000000000000"),null!=t.input&&null==t.data&&(t.data=t.input),null==t.to&&null==t.creates&&(t.creates=this.contractAddress(t)),1!==t.type&&2!==t.type||null!=t.accessList||(t.accessList=[]);var r=e.check(this.formats.transaction,t);if(null!=t.chainId){var n=t.chainId;Object(c.k)(n)&&(n=o.a.from(n).toNumber()),r.chainId=n}else{var a=t.networkId;null==a&&null==r.v&&(a=t.chainId),Object(c.k)(a)&&(a=o.a.from(a).toNumber()),"number"!==typeof a&&null!=r.v&&((a=(r.v-35)/2)<0&&(a=0),a=parseInt(a)),"number"!==typeof a&&(a=0),r.chainId=a}return r.blockHash&&"x"===r.blockHash.replace(/0/g,"")&&(r.blockHash=null),r}},{key:"transaction",value:function(e){return Object(d.parse)(e)}},{key:"receiptLog",value:function(t){return e.check(this.formats.receiptLog,t)}},{key:"receipt",value:function(t){var r=e.check(this.formats.receipt,t);if(null!=r.root)if(r.root.length<=4){var n=o.a.from(r.root).toNumber();0===n||1===n?(null!=r.status&&r.status!==n&&b.throwArgumentError("alt-root-status/status mismatch","value",{root:r.root,status:r.status}),r.status=n,delete r.root):b.throwArgumentError("invalid alt-root-status","value.root",r.root)}else 66!==r.root.length&&b.throwArgumentError("invalid root hash","value.root",r.root);return null!=r.status&&(r.byzantium=!0),r}},{key:"topics",value:function(e){var t=this;return Array.isArray(e)?e.map((function(e){return t.topics(e)})):null!=e?this.hash(e,!0):null}},{key:"filter",value:function(t){return e.check(this.formats.filter,t)}},{key:"filterLog",value:function(t){return e.check(this.formats.filterLog,t)}}],[{key:"check",value:function(e,t){var r={};for(var n in e)try{var a=e[n](t[n]);void 0!==a&&(r[n]=a)}catch(i){throw i.checkKey=n,i.checkValue=t[n],i}return r}},{key:"allowNull",value:function(e,t){return function(r){return null==r?t:e(r)}}},{key:"allowFalsish",value:function(e,t){return function(r){return r?e(r):t}}},{key:"arrayOf",value:function(e){return function(t){if(!Array.isArray(t))throw new Error("not an array");var r=[];return t.forEach((function(t){r.push(e(t))})),r}}}]),e}();function p(e){return function(e){return e&&"function"===typeof e.isCommunityResource}(e)&&e.isCommunityResource()}var m=!1;function v(){m||(m=!0,console.log("========= NOTICE ========="),console.log("Request-Rate Exceeded (this message will not be repeated)"),console.log(""),console.log("The default API keys for each service are provided as a highly-throttled,"),console.log("community resource for low-traffic projects and early prototyping."),console.log(""),console.log("While your application will continue to function, we highly recommended"),console.log("signing up for your own API keys to improve performance, increase your"),console.log("request rate/limit and enable other perks, such as metrics and advanced APIs."),console.log(""),console.log("For more details: https://docs.ethers.io/api-keys/"),console.log("=========================="))}},function(e,t,r){"use strict";!function e(){if("undefined"!==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"===typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE){0;try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}}(),e.exports=r(598)},function(e,t,r){"use strict";var n=Object.getOwnPropertySymbols,a=Object.prototype.hasOwnProperty,i=Object.prototype.propertyIsEnumerable;function o(e){if(null===e||void 0===e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},r=0;r<10;r++)t["_"+String.fromCharCode(r)]=r;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var n={};return"abcdefghijklmnopqrst".split("").forEach((function(e){n[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},n)).join("")}catch(a){return!1}}()?Object.assign:function(e,t){for(var r,c,s=o(e),f=1;f1&&s.forEach((function(r){var a;n[r]=e(((a={})[r]=t[r],a))})),n},u=function(e,t,r,n,i){var o={};return n.slice(0,e.length).forEach((function(n,c){var s,f=e[c],d=t(n,r,i);f?a()(o,((s={})[f]=a()({},o[f],d),s)):a()(o,d)})),o},l=function(e,t,r,n,i){var o={};for(var s in n){var f=e[s],d=t(n[s],r,i);if(f){var u,l=c(f);a()(o,((u={})[l]=a()({},o[l],d),u))}else a()(o,d)}return o},b=function(e){var t=e.properties,r=e.property,n=e.scale,a=e.transform,i=void 0===a?s:a,o=e.defaultScale;t=t||[r];var c=function(e,r,n){var a={},o=i(e,r,n);if(null!==o)return t.forEach((function(e){a[e]=o})),a};return c.scale=n,c.defaults=o,c},h=function(e){void 0===e&&(e={});var t={};return Object.keys(e).forEach((function(r){var n=e[r];t[r]=!0!==n?"function"!==typeof n?b(n):n:b({property:r,scale:r})})),d(t)},p=function(){for(var e={},t=arguments.length,r=new Array(t),n=0;n1?e:100*e+"%")}},height:{property:"height",scale:"sizes"},minWidth:{property:"minWidth",scale:"sizes"},minHeight:{property:"minHeight",scale:"sizes"},maxWidth:{property:"maxWidth",scale:"sizes"},maxHeight:{property:"maxHeight",scale:"sizes"},size:{properties:["width","height"],scale:"sizes"},overflow:!0,overflowX:!0,overflowY:!0,display:!0,verticalAlign:!0}),v=m,g={color:{property:"color",scale:"colors"},backgroundColor:{property:"backgroundColor",scale:"colors"},opacity:!0};g.bg=g.backgroundColor;var x=h(g),y=x,w=h({fontFamily:{property:"fontFamily",scale:"fonts"},fontSize:{property:"fontSize",scale:"fontSizes",defaultScale:[12,14,16,20,24,32,48,64,72]},fontWeight:{property:"fontWeight",scale:"fontWeights"},lineHeight:{property:"lineHeight",scale:"lineHeights"},letterSpacing:{property:"letterSpacing",scale:"letterSpacings"},textAlign:!0,fontStyle:!0}),k=w,_=h({alignItems:!0,alignContent:!0,justifyItems:!0,justifyContent:!0,flexWrap:!0,flexDirection:!0,flex:!0,flexGrow:!0,flexShrink:!0,flexBasis:!0,justifySelf:!0,alignSelf:!0,order:!0}),M=_,S={space:[0,4,8,16,32,64,128,256,512]},E=h({gridGap:{property:"gridGap",scale:"space",defaultScale:S.space},gridColumnGap:{property:"gridColumnGap",scale:"space",defaultScale:S.space},gridRowGap:{property:"gridRowGap",scale:"space",defaultScale:S.space},gridColumn:!0,gridRow:!0,gridAutoFlow:!0,gridAutoColumns:!0,gridAutoRows:!0,gridTemplateColumns:!0,gridTemplateRows:!0,gridTemplateAreas:!0,gridArea:!0}),O=E,A={border:{property:"border",scale:"borders"},borderWidth:{property:"borderWidth",scale:"borderWidths"},borderStyle:{property:"borderStyle",scale:"borderStyles"},borderColor:{property:"borderColor",scale:"colors"},borderRadius:{property:"borderRadius",scale:"radii"},borderTop:{property:"borderTop",scale:"borders"},borderTopLeftRadius:{property:"borderTopLeftRadius",scale:"radii"},borderTopRightRadius:{property:"borderTopRightRadius",scale:"radii"},borderRight:{property:"borderRight",scale:"borders"},borderBottom:{property:"borderBottom",scale:"borders"},borderBottomLeftRadius:{property:"borderBottomLeftRadius",scale:"radii"},borderBottomRightRadius:{property:"borderBottomRightRadius",scale:"radii"},borderLeft:{property:"borderLeft",scale:"borders"},borderX:{properties:["borderLeft","borderRight"],scale:"borders"},borderY:{properties:["borderTop","borderBottom"],scale:"borders"},borderTopWidth:{property:"borderTopWidth",scale:"borderWidths"},borderTopColor:{property:"borderTopColor",scale:"colors"},borderTopStyle:{property:"borderTopStyle",scale:"borderStyles"}};A.borderTopLeftRadius={property:"borderTopLeftRadius",scale:"radii"},A.borderTopRightRadius={property:"borderTopRightRadius",scale:"radii"},A.borderBottomWidth={property:"borderBottomWidth",scale:"borderWidths"},A.borderBottomColor={property:"borderBottomColor",scale:"colors"},A.borderBottomStyle={property:"borderBottomStyle",scale:"borderStyles"},A.borderBottomLeftRadius={property:"borderBottomLeftRadius",scale:"radii"},A.borderBottomRightRadius={property:"borderBottomRightRadius",scale:"radii"},A.borderLeftWidth={property:"borderLeftWidth",scale:"borderWidths"},A.borderLeftColor={property:"borderLeftColor",scale:"colors"},A.borderLeftStyle={property:"borderLeftStyle",scale:"borderStyles"},A.borderRightWidth={property:"borderRightWidth",scale:"borderWidths"},A.borderRightColor={property:"borderRightColor",scale:"colors"},A.borderRightStyle={property:"borderRightStyle",scale:"borderStyles"};var T=h(A),j=T,P={background:!0,backgroundImage:!0,backgroundSize:!0,backgroundPosition:!0,backgroundRepeat:!0};P.bgImage=P.backgroundImage,P.bgSize=P.backgroundSize,P.bgPosition=P.backgroundPosition,P.bgRepeat=P.backgroundRepeat;var C=h(P),R=C,N={space:[0,4,8,16,32,64,128,256,512]},B=h({position:!0,zIndex:{property:"zIndex",scale:"zIndices"},top:{property:"top",scale:"space",defaultScale:N.space},right:{property:"right",scale:"space",defaultScale:N.space},bottom:{property:"bottom",scale:"space",defaultScale:N.space},left:{property:"left",scale:"space",defaultScale:N.space}}),L=B,I={space:[0,4,8,16,32,64,128,256,512]},F=function(e){return"number"===typeof e&&!isNaN(e)},D=function(e,t){if(!F(e))return f(t,e,e);var r=e<0,n=Math.abs(e),a=f(t,n,n);return F(a)?a*(r?-1:1):r?"-"+a:a},U={};U.margin={margin:{property:"margin",scale:"space",transform:D,defaultScale:I.space},marginTop:{property:"marginTop",scale:"space",transform:D,defaultScale:I.space},marginRight:{property:"marginRight",scale:"space",transform:D,defaultScale:I.space},marginBottom:{property:"marginBottom",scale:"space",transform:D,defaultScale:I.space},marginLeft:{property:"marginLeft",scale:"space",transform:D,defaultScale:I.space},marginX:{properties:["marginLeft","marginRight"],scale:"space",transform:D,defaultScale:I.space},marginY:{properties:["marginTop","marginBottom"],scale:"space",transform:D,defaultScale:I.space}},U.margin.m=U.margin.margin,U.margin.mt=U.margin.marginTop,U.margin.mr=U.margin.marginRight,U.margin.mb=U.margin.marginBottom,U.margin.ml=U.margin.marginLeft,U.margin.mx=U.margin.marginX,U.margin.my=U.margin.marginY,U.padding={padding:{property:"padding",scale:"space",defaultScale:I.space},paddingTop:{property:"paddingTop",scale:"space",defaultScale:I.space},paddingRight:{property:"paddingRight",scale:"space",defaultScale:I.space},paddingBottom:{property:"paddingBottom",scale:"space",defaultScale:I.space},paddingLeft:{property:"paddingLeft",scale:"space",defaultScale:I.space},paddingX:{properties:["paddingLeft","paddingRight"],scale:"space",defaultScale:I.space},paddingY:{properties:["paddingTop","paddingBottom"],scale:"space",defaultScale:I.space}},U.padding.p=U.padding.padding,U.padding.pt=U.padding.paddingTop,U.padding.pr=U.padding.paddingRight,U.padding.pb=U.padding.paddingBottom,U.padding.pl=U.padding.paddingLeft,U.padding.px=U.padding.paddingX,U.padding.py=U.padding.paddingY;var z=h(U.margin),H=h(U.padding),q=p(z,H),J=h({boxShadow:{property:"boxShadow",scale:"shadows"},textShadow:{property:"textShadow",scale:"shadows"}}),V=J,G=r(262),X=function(e){var t,r,n=e.scale,a=e.prop,i=void 0===a?"variant":a,o=e.variants,c=void 0===o?{}:o,s=e.key;(r=Object.keys(c).length?function(e,t,r){return Object(G.default)(f(t,e,null))(r.theme)}:function(e,t){return f(t,e,null)}).scale=n||s,r.defaults=c;var u=((t={})[i]=r,t);return d(u)},K=X({key:"buttons"}),W=X({key:"textStyles",prop:"textStyle"}),Z=X({key:"colorStyles",prop:"colors"}),$=v.width,Q=v.height,Y=v.minWidth,ee=v.minHeight,te=v.maxWidth,re=v.maxHeight,ne=v.size,ae=v.verticalAlign,ie=v.display,oe=v.overflow,ce=v.overflowX,se=v.overflowY,fe=y.opacity,de=k.fontSize,ue=k.fontFamily,le=k.fontWeight,be=k.lineHeight,he=k.textAlign,pe=k.fontStyle,me=k.letterSpacing,ve=M.alignItems,ge=M.alignContent,xe=M.justifyItems,ye=M.justifyContent,we=M.flexWrap,ke=M.flexDirection,_e=M.flex,Me=M.flexGrow,Se=M.flexShrink,Ee=M.flexBasis,Oe=M.justifySelf,Ae=M.alignSelf,Te=M.order,je=O.gridGap,Pe=O.gridColumnGap,Ce=O.gridRowGap,Re=O.gridColumn,Ne=O.gridRow,Be=O.gridAutoFlow,Le=O.gridAutoColumns,Ie=O.gridAutoRows,Fe=O.gridTemplateColumns,De=O.gridTemplateRows,Ue=O.gridTemplateAreas,ze=O.gridArea,He=j.borderWidth,qe=j.borderStyle,Je=j.borderColor,Ve=j.borderTop,Ge=j.borderRight,Xe=j.borderBottom,Ke=j.borderLeft,We=j.borderRadius,Ze=R.backgroundImage,$e=R.backgroundSize,Qe=R.backgroundPosition,Ye=R.backgroundRepeat,et=L.zIndex,tt=L.top,rt=L.right,nt=L.bottom,at=L.left,it=function(e){var t=e.prop,r=e.cssProperty,n=e.alias,a=e.key,i=e.transformValue,o=e.scale,c=e.properties,s={};return s[t]=b({properties:c,property:r||t,scale:a,defaultScale:o,transform:i}),n&&(s[n]=s[t]),d(s)}},function(e,t,r){"use strict";r.r(t),r.d(t,"computeAddress",(function(){return v})),r.d(t,"recoverAddress",(function(){return g})),r.d(t,"accessListify",(function(){return w})),r.d(t,"serialize",(function(){return _})),r.d(t,"parse",(function(){return M}));var n=r(53),a=r(51),i=r(10),o=r(120),c=r(49),s=r(15),f=r(98),d=r(135),u=r(16),l=new u.Logger("transactions/5.3.0");function b(e){return"0x"===e?null:Object(n.getAddress)(e)}function h(e){return"0x"===e?o.h:a.a.from(e)}var p=[{name:"nonce",maxLength:32,numeric:!0},{name:"gasPrice",maxLength:32,numeric:!0},{name:"gasLimit",maxLength:32,numeric:!0},{name:"to",length:20},{name:"value",maxLength:32,numeric:!0},{name:"data"}],m={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,value:!0};function v(e){var t=Object(d.computePublicKey)(e);return Object(n.getAddress)(Object(i.hexDataSlice)(Object(c.keccak256)(Object(i.hexDataSlice)(t,1)),12))}function g(e,t){return v(Object(d.recoverPublicKey)(Object(i.arrayify)(e),t))}function x(e,t){var r=Object(i.stripZeros)(a.a.from(e).toHexString());return r.length>32&&l.throwArgumentError("invalid length for "+t,"transaction:"+t,e),r}function y(e,t){return{address:Object(n.getAddress)(e),storageKeys:(t||[]).map((function(t,r){return 32!==Object(i.hexDataLength)(t)&&l.throwArgumentError("invalid access list storageKey","accessList[".concat(e,":").concat(r,"]"),t),t.toLowerCase()}))}}function w(e){if(Array.isArray(e))return e.map((function(e,t){return Array.isArray(e)?(e.length>2&&l.throwArgumentError("access list expected to be [ address, storageKeys[] ]","value[".concat(t,"]"),e),y(e[0],e[1])):y(e.address,e.storageKeys)}));var t=Object.keys(e).map((function(t){var r=e[t].reduce((function(e,t){return e[t]=!0,e}),{});return y(t,Object.keys(r).sort())}));return t.sort((function(e,t){return e.address.localeCompare(t.address)})),t}function k(e,t){var r,a=[x(e.chainId||0,"chainId"),x(e.nonce||0,"nonce"),x(e.gasPrice||0,"gasPrice"),x(e.gasLimit||0,"gasLimit"),null!=e.to?Object(n.getAddress)(e.to):"0x",x(e.value||0,"value"),e.data||"0x",(r=e.accessList||[],w(r).map((function(e){return[e.address,e.storageKeys]})))];if(t){var o=Object(i.splitSignature)(t);a.push(x(o.recoveryParam,"recoveryParam")),a.push(Object(i.stripZeros)(o.r)),a.push(Object(i.stripZeros)(o.s))}return Object(i.hexConcat)(["0x01",f.encode(a)])}function _(e,t){if(null==e.type)return null!=e.accessList&&l.throwArgumentError("untyped transactions do not support accessList; include type: 1","transaction",e),function(e,t){Object(s.checkProperties)(e,m);var r=[];p.forEach((function(t){var n=e[t.name]||[],a={};t.numeric&&(a.hexPad="left"),n=Object(i.arrayify)(Object(i.hexlify)(n,a)),t.length&&n.length!==t.length&&n.length>0&&l.throwArgumentError("invalid length for "+t.name,"transaction:"+t.name,n),t.maxLength&&(n=Object(i.stripZeros)(n)).length>t.maxLength&&l.throwArgumentError("invalid length for "+t.name,"transaction:"+t.name,n),r.push(Object(i.hexlify)(n))}));var n=0;if(null!=e.chainId?"number"!==typeof(n=e.chainId)&&l.throwArgumentError("invalid transaction.chainId","transaction",e):t&&!Object(i.isBytesLike)(t)&&t.v>28&&(n=Math.floor((t.v-35)/2)),0!==n&&(r.push(Object(i.hexlify)(n)),r.push("0x"),r.push("0x")),!t)return f.encode(r);var a=Object(i.splitSignature)(t),o=27+a.recoveryParam;return 0!==n?(r.pop(),r.pop(),r.pop(),o+=2*n+8,a.v>28&&a.v!==o&&l.throwArgumentError("transaction.chainId/signature.v mismatch","signature",t)):a.v!==o&&l.throwArgumentError("transaction.chainId/signature.v mismatch","signature",t),r.push(Object(i.hexlify)(o)),r.push(Object(i.stripZeros)(Object(i.arrayify)(a.r))),r.push(Object(i.stripZeros)(Object(i.arrayify)(a.s))),f.encode(r)}(e,t);switch(e.type){case 1:return k(e,t)}return l.throwError("unsupported transaction type: ".concat(e.type),u.Logger.errors.UNSUPPORTED_OPERATION,{operation:"serializeTransaction",transactionType:e.type})}function M(e){var t=Object(i.arrayify)(e);if(t[0]>127)return function(e){var t=f.decode(e);9!==t.length&&6!==t.length&&l.throwArgumentError("invalid raw transaction","rawTransaction",e);var r={nonce:h(t[0]).toNumber(),gasPrice:h(t[1]),gasLimit:h(t[2]),to:b(t[3]),value:h(t[4]),data:t[5],chainId:0};if(6===t.length)return r;try{r.v=a.a.from(t[6]).toNumber()}catch(d){return console.log(d),r}if(r.r=Object(i.hexZeroPad)(t[7],32),r.s=Object(i.hexZeroPad)(t[8],32),a.a.from(r.r).isZero()&&a.a.from(r.s).isZero())r.chainId=r.v,r.v=0;else{r.chainId=Math.floor((r.v-35)/2),r.chainId<0&&(r.chainId=0);var n=r.v-27,o=t.slice(0,6);0!==r.chainId&&(o.push(Object(i.hexlify)(r.chainId)),o.push("0x"),o.push("0x"),n-=2*r.chainId+8);var s=Object(c.keccak256)(f.encode(o));try{r.from=g(s,{r:Object(i.hexlify)(r.r),s:Object(i.hexlify)(r.s),recoveryParam:n})}catch(d){console.log(d)}r.hash=Object(c.keccak256)(e)}return r.type=null,r}(t);switch(t[0]){case 1:return function(e){var t=f.decode(e.slice(1));8!==t.length&&11!==t.length&&l.throwArgumentError("invalid component count for transaction type: 1","payload",Object(i.hexlify)(e));var r={type:1,chainId:h(t[0]).toNumber(),nonce:h(t[1]).toNumber(),gasPrice:h(t[2]),gasLimit:h(t[3]),to:b(t[4]),value:h(t[5]),data:t[6],accessList:w(t[7])};if(8===t.length)return r;try{var n=h(t[8]).toNumber();if(0!==n&&1!==n)throw new Error("bad recid");r.v=n}catch(o){l.throwArgumentError("invalid v for transaction type: 1","v",t[8])}r.r=Object(i.hexZeroPad)(t[9],32),r.s=Object(i.hexZeroPad)(t[10],32);try{var a=Object(c.keccak256)(k(r));r.from=g(a,{r:r.r,s:r.s,recoveryParam:r.v})}catch(o){console.log(o)}return r.hash=Object(c.keccak256)(e),r}(t)}return l.throwError("unsupported transaction type: ".concat(t[0]),u.Logger.errors.UNSUPPORTED_OPERATION,{operation:"parseTransaction",transactionType:t[0]})}},,function(e,t,r){"use strict";function n(e){return(n=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}r.d(t,"a",(function(){return n}))},function(e,t,r){"use strict";r.d(t,"a",(function(){return n})),r.d(t,"c",(function(){return d})),r.d(t,"b",(function(){return u})),r.d(t,"e",(function(){return l})),r.d(t,"d",(function(){return b}));var n,a,i=r(5),o=new(r(11).a)("strings/5.5.0");function c(e,t,r,n,i){if(e===a.BAD_PREFIX||e===a.UNEXPECTED_CONTINUE){for(var o=0,c=t+1;c>6===2;c++)o++;return o}return e===a.OVERRUN?r.length-t-1:0}!function(e){e.current="",e.NFC="NFC",e.NFD="NFD",e.NFKC="NFKC",e.NFKD="NFKD"}(n||(n={})),function(e){e.UNEXPECTED_CONTINUE="unexpected continuation byte",e.BAD_PREFIX="bad codepoint prefix",e.OVERRUN="string overrun",e.MISSING_CONTINUE="missing continuation byte",e.OUT_OF_RANGE="out of UTF-8 range",e.UTF16_SURROGATE="UTF-16 surrogate",e.OVERLONG="overlong representation"}(a||(a={}));var s=Object.freeze({error:function(e,t,r,n,a){return o.throwArgumentError("invalid codepoint at offset ".concat(t,"; ").concat(e),"bytes",r)},ignore:c,replace:function(e,t,r,n,i){return e===a.OVERLONG?(n.push(i),0):(n.push(65533),c(e,t,r))}});function f(e,t){null==t&&(t=s.error),e=Object(i.a)(e);for(var r=[],n=0;n>7!==0){var c=null,f=null;if(192===(224&o))c=1,f=127;else if(224===(240&o))c=2,f=2047;else{if(240!==(248&o)){n+=t(128===(192&o)?a.UNEXPECTED_CONTINUE:a.BAD_PREFIX,n-1,e,r);continue}c=3,f=65535}if(n-1+c>=e.length)n+=t(a.OVERRUN,n-1,e,r);else{for(var d=o&(1<<8-c-1)-1,u=0;u1114111?n+=t(a.OUT_OF_RANGE,n-1-c,e,r,d):d>=55296&&d<=57343?n+=t(a.UTF16_SURROGATE,n-1-c,e,r,d):d<=f?n+=t(a.OVERLONG,n-1-c,e,r,d):r.push(d))}}else r.push(o)}return r}function d(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:n.current;t!=n.current&&(o.checkNormalize(),e=e.normalize(t));for(var r=[],a=0;a>6|192),r.push(63&c|128);else if(55296==(64512&c)){a++;var s=e.charCodeAt(a);if(a>=e.length||56320!==(64512&s))throw new Error("invalid utf-8 string");var f=65536+((1023&c)<<10)+(1023&s);r.push(f>>18|240),r.push(f>>12&63|128),r.push(f>>6&63|128),r.push(63&f|128)}else r.push(c>>12|224),r.push(c>>6&63|128),r.push(63&c|128)}return Object(i.a)(r)}function u(e){return e.map((function(e){return e<=65535?String.fromCharCode(e):(e-=65536,String.fromCharCode(55296+(e>>10&1023),56320+(1023&e)))})).join("")}function l(e,t){return u(f(e,t))}function b(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:n.current;return f(d(e,t))}},function(e,t){e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}},function(e,t){function r(e,t){for(var r=0;r0&&n%1===0,"invalid connection throttle limit","connection.throttleLimit",n);var i="object"===typeof e?e.throttleCallback:null,c="object"===typeof e&&"number"===typeof e.throttleSlotInterval?e.throttleSlotInterval:100;b.assertArgument(c>0&&c%1===0,"invalid connection throttle slot interval","connection.throttleSlotInterval",c);var d={},m=null,v={method:"GET"},g=!1,x=12e4;if("string"===typeof e)m=e;else if("object"===typeof e){if(null!=e&&null!=e.url||b.throwArgumentError("missing URL","connection.url",e),m=e.url,"number"===typeof e.timeout&&e.timeout>0&&(x=e.timeout),e.headers)for(var y in e.headers)d[y.toLowerCase()]={key:y,value:String(e.headers[y])},["if-none-match","if-modified-since"].indexOf(y.toLowerCase())>=0&&(g=!0);if(v.allowGzip=!!e.allowGzip,null!=e.user&&null!=e.password){"https:"!==m.substring(0,6)&&!0!==e.allowInsecureAuthentication&&b.throwError("basic authentication requires a secure https url",f.a.errors.INVALID_ARGUMENT,{argument:"url",url:m,user:e.user,password:"[REDACTED]"});var w=e.user+":"+e.password;d.authorization={key:"Authorization",value:"Basic "+o(Object(s.c)(w))}}}t&&(v.method="POST",v.body=t,null==d["content-type"]&&(d["content-type"]={key:"Content-Type",value:"application/octet-stream"}),null==d["content-length"]&&(d["content-length"]={key:"Content-Length",value:String(t.length)}));var k={};Object.keys(d).forEach((function(e){var t=d[e];k[t.key]=t.value})),v.headers=k;var _=function(){var e=null;return{promise:new Promise((function(t,r){x&&(e=setTimeout((function(){null!=e&&(e=null,r(b.makeError("timeout",f.a.errors.TIMEOUT,{requestBody:p(v.body,k["content-type"]),requestMethod:v.method,timeout:x,url:m})))}),x))})),cancel:function(){null!=e&&(clearTimeout(e),e=null)}}}(),M=function(){return l(this,void 0,void 0,a.a.mark((function e(){var t,o,s,d,l,x,y,w,M;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:t=0;case 1:if(!(t=300)&&(_.cancel(),b.throwError("bad response",f.a.errors.SERVER_ERROR,{status:o.statusCode,headers:o.headers,body:p(x,o.headers?o.headers["content-type"]:null),requestBody:p(v.body,k["content-type"]),requestMethod:v.method,url:m})),!r){e.next=52;break}return e.prev=29,e.next=32,r(x,o);case 32:return y=e.sent,_.cancel(),e.abrupt("return",y);case 37:if(e.prev=37,e.t1=e.catch(29),!(e.t1.throttleRetry&&tc)return void(o()&&n(new Error("retry limit reached")));var f=t.interval*parseInt(String(Math.random()*Math.pow(2,s)));ft.ceiling&&(f=t.ceiling),setTimeout(a,f)}return null}),(function(e){o()&&n(e)}))}()}))}},function(e,t,r){"use strict";r.d(t,"b",(function(){return a})),r.d(t,"a",(function(){return i})),r.d(t,"c",(function(){return o}));var 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)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)};function a(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}var i=function(){return(i=Object.assign||function(e){for(var t,r=1,n=arguments.length;r0&&o.length>a&&!o.warned){o.warned=!0;var s=new Error("Possible EventEmitter memory leak detected. "+o.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");s.name="MaxListenersExceededWarning",s.emitter=e,s.type=t,s.count=o.length,c=s,console&&console.warn&&console.warn(c)}return e}function l(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function b(e,t,r){var n={fired:!1,wrapFn:void 0,target:e,type:t,listener:r},a=l.bind(n);return a.listener=r,n.wrapFn=a,a}function h(e,t,r){var n=e._events;if(void 0===n)return[];var a=n[t];return void 0===a?[]:"function"===typeof a?r?[a.listener||a]:[a]:r?function(e){for(var t=new Array(e.length),r=0;r0&&(o=t[0]),o instanceof Error)throw o;var c=new Error("Unhandled error."+(o?" ("+o.message+")":""));throw c.context=o,c}var s=a[e];if(void 0===s)return!1;if("function"===typeof s)i(s,this,t);else{var f=s.length,d=m(s,f);for(r=0;r=0;i--)if(r[i]===t||r[i].listener===t){o=r[i].listener,a=i;break}if(a<0)return this;0===a?r.shift():function(e,t){for(;t+1=0;n--)this.removeListener(e,t[n]);return this},c.prototype.listeners=function(e){return h(this,e,!0)},c.prototype.rawListeners=function(e){return h(this,e,!1)},c.listenerCount=function(e,t){return"function"===typeof e.listenerCount?e.listenerCount(t):p.call(e,t)},c.prototype.listenerCount=p,c.prototype.eventNames=function(){return this._eventsCount>0?n(this._events):[]}},function(e,t){var r=Array.isArray;e.exports=r},function(e,t){function r(e,t){if(!e)throw new Error(t||"Assertion failed")}e.exports=r,r.equal=function(e,t,r){if(e!=t)throw new Error(r||"Assertion failed: "+e+" != "+t)}},function(e,t,r){"use strict";var n=t,a=r(118),i=r(93),o=r(403);n.assert=i,n.toArray=o.toArray,n.zero2=o.zero2,n.toHex=o.toHex,n.encode=o.encode,n.getNAF=function(e,t,r){var n=new Array(Math.max(e.bitLength(),r)+1);n.fill(0);for(var a=1<(a>>1)-1?(a>>1)-s:s,i.isubn(c)):c=0,n[o]=c,i.iushrn(1)}return n},n.getJSF=function(e,t){var r=[[],[]];e=e.clone(),t=t.clone();for(var n,a=0,i=0;e.cmpn(-a)>0||t.cmpn(-i)>0;){var o,c,s=e.andln(3)+a&3,f=t.andln(3)+i&3;3===s&&(s=-1),3===f&&(f=-1),o=0===(1&s)?0:3!==(n=e.andln(7)+a&7)&&5!==n||2!==f?s:-s,r[0].push(o),c=0===(1&f)?0:3!==(n=t.andln(7)+i&7)&&5!==n||2!==s?f:-f,r[1].push(c),2*a===o+1&&(a=1-a),2*i===c+1&&(i=1-i),e.iushrn(1),t.iushrn(1)}return r},n.cachedProperty=function(e,t,r){var n="_"+t;e.prototype[t]=function(){return void 0!==this[n]?this[n]:this[n]=r.call(this)}},n.parseBytes=function(e){return"string"===typeof e?n.toArray(e,"hex"):e},n.intFromLE=function(e){return new a(e,"hex","le")}},function(e,t,r){"use strict";r.r(t);var n=r(327);r.d(t,"formatBytes32String",(function(){return n.a})),r.d(t,"parseBytes32String",(function(){return n.b}));var a=r(276);r.d(t,"nameprep",(function(){return a.a}));var i=r(64);r.d(t,"_toEscapedUtf8String",(function(){return i.d})),r.d(t,"toUtf8Bytes",(function(){return i.f})),r.d(t,"toUtf8CodePoints",(function(){return i.g})),r.d(t,"toUtf8String",(function(){return i.h})),r.d(t,"Utf8ErrorFuncs",(function(){return i.b})),r.d(t,"Utf8ErrorReason",(function(){return i.c})),r.d(t,"UnicodeNormalizationForm",(function(){return i.a}))},function(e,t,r){"use strict";r.d(t,"a",(function(){return a})),r.d(t,"b",(function(){return i})),r.d(t,"c",(function(){return o}));var n=r(0);function a(e){return Object(n.a)({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"g",attr:{},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"}},{tag:"path",attr:{d:"M16.004 9.414l-8.607 8.607-1.414-1.414L14.589 8H7.004V6h11v11h-2V9.414z"}}]}]})(e)}function i(e){return Object(n.a)({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"g",attr:{},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"}},{tag:"path",attr:{d:"M12 10.586l4.95-4.95 1.414 1.414-4.95 4.95 4.95 4.95-1.414 1.414-4.95-4.95-4.95 4.95-1.414-1.414 4.95-4.95-4.95-4.95L7.05 5.636z"}}]}]})(e)}function o(e){return Object(n.a)({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"g",attr:{},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"}},{tag:"path",attr:{d:"M12 22C6.477 22 2 17.523 2 12S6.477 2 12 2s10 4.477 10 10-4.477 10-10 10zm0-2a8 8 0 1 0 0-16 8 8 0 0 0 0 16zm-1-5h2v2h-2v-2zm0-8h2v6h-2V7z"}}]}]})(e)}},function(e,t,r){"use strict";r.d(t,"a",(function(){return h})),r.d(t,"b",(function(){return p}));var n=r(2),a=r.n(n),i=r(6),o=r(7),c=r(13),s=r(14),f=r(46),d=(r(5),r(9)),u=r(11),l=function(e,t,r,n){return new(r||(r=Promise))((function(a,i){function o(e){try{s(n.next(e))}catch(t){i(t)}}function c(e){try{s(n.throw(e))}catch(t){i(t)}}function s(e){var t;e.done?a(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(o,c)}s((n=n.apply(e,t||[])).next())}))},b=new u.a("abstract-provider/5.5.1"),h=function(e){Object(c.a)(r,e);var t=Object(s.a)(r);function r(){return Object(i.a)(this,r),t.apply(this,arguments)}return Object(o.a)(r,null,[{key:"isForkEvent",value:function(e){return!(!e||!e._isForkEvent)}}]),r}(d.a),p=function(){function e(){Object(i.a)(this,e),b.checkAbstract(this instanceof e?this.constructor:void 0,e),Object(d.d)(this,"_isProvider",!0)}return Object(o.a)(e,[{key:"getFeeData",value:function(){return l(this,void 0,void 0,a.a.mark((function e(){var t,r,n,i,o;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(d.f)({block:this.getBlock("latest"),gasPrice:this.getGasPrice().catch((function(e){return null}))});case 2:return t=e.sent,r=t.block,n=t.gasPrice,i=null,o=null,r&&r.baseFeePerGas&&(o=f.a.from("2500000000"),i=r.baseFeePerGas.mul(2).add(o)),e.abrupt("return",{maxFeePerGas:i,maxPriorityFeePerGas:o,gasPrice:n});case 8:case"end":return e.stop()}}),e,this)})))}},{key:"addListener",value:function(e,t){return this.on(e,t)}},{key:"removeListener",value:function(e,t){return this.off(e,t)}}],[{key:"isProvider",value:function(e){return!(!e||!e._isProvider)}}]),e}()},function(e,t,r){"use strict";r.r(t),r.d(t,"encode",(function(){return s})),r.d(t,"decode",(function(){return u}));var n=r(10),a=r(16),i=new a.Logger("rlp/5.3.0");function o(e){for(var t=[];e;)t.unshift(255&e),e>>=8;return t}function c(e,t,r){for(var n=0,a=0;at+1+n&&i.throwError("child data too short",a.Logger.errors.BUFFER_OVERRUN,{})}return{consumed:1+n,result:o}}function d(e,t){if(0===e.length&&i.throwError("data too short",a.Logger.errors.BUFFER_OVERRUN,{}),e[t]>=248){var r=e[t]-247;t+1+r>e.length&&i.throwError("data short segment too short",a.Logger.errors.BUFFER_OVERRUN,{});var o=c(e,t+1,r);return t+1+r+o>e.length&&i.throwError("data long segment too short",a.Logger.errors.BUFFER_OVERRUN,{}),f(e,t,t+1+r,r+o)}if(e[t]>=192){var s=e[t]-192;return t+1+s>e.length&&i.throwError("data array too short",a.Logger.errors.BUFFER_OVERRUN,{}),f(e,t,t+1,s)}if(e[t]>=184){var d=e[t]-183;t+1+d>e.length&&i.throwError("data array too short",a.Logger.errors.BUFFER_OVERRUN,{});var u=c(e,t+1,d);return t+1+d+u>e.length&&i.throwError("data array too short",a.Logger.errors.BUFFER_OVERRUN,{}),{consumed:1+d+u,result:Object(n.hexlify)(e.slice(t+1+d,t+1+d+u))}}if(e[t]>=128){var l=e[t]-128;return t+1+l>e.length&&i.throwError("data too short",a.Logger.errors.BUFFER_OVERRUN,{}),{consumed:1+l,result:Object(n.hexlify)(e.slice(t+1,t+1+l))}}return{consumed:1,result:Object(n.hexlify)(e[t])}}function u(e){var t=Object(n.arrayify)(e),r=d(t,0);return r.consumed!==t.length&&i.throwArgumentError("invalid rlp data","data",e),r.result}},function(e,t,r){"use strict";r.d(t,"a",(function(){return n})),r.d(t,"b",(function(){return i})),r.d(t,"c",(function(){return a})),r.d(t,"d",(function(){return o}));var n;function a(e,t){return t.major>e.major?n.MAJOR:t.majore.minor?n.MINOR:t.minore.patch?n.PATCH:n.NONE}function i(e,t){var r=e.reduce((function(e,t){return e[t.chainId]||(e[t.chainId]={}),e[t.chainId][t.address]=t,e}),{}),n=t.reduce((function(e,t){var n,a,i=null==(n=r[t.chainId])?void 0:n[t.address];if(i){var o=Object.keys(t).filter((function(e){return"address"!==e&&"chainId"!==e})).filter((function(e){return r=t[e],n=i[e],!(r===n||typeof r===typeof n&&Array.isArray(r)&&Array.isArray(n)&&r.every((function(e,t){return n[t]===e})));var r,n}));o.length>0&&(e.changed[t.chainId]||(e.changed[t.chainId]={}),e.changed[t.chainId][t.address]=o)}else e.added.push(t);e.index[t.chainId]?e.index[t.chainId][t.address]=!0:e.index[t.chainId]=((a={})[t.address]=!0,a);return e}),{added:[],changed:{},index:{}}),a=e.reduce((function(e,t){return n.index[t.chainId]&&n.index[t.chainId][t.address]||e.push(t),e}),[]);return{added:n.added,changed:n.changed,removed:a}}function o(e,t){var r=i(e,t);return r.removed.length>0?n.MAJOR:r.added.length>0?n.MINOR:Object.keys(r.changed).length>0?n.PATCH:n.NONE}!function(e){e[e.NONE=0]="NONE",e[e.PATCH=1]="PATCH",e[e.MINOR=2]="MINOR",e[e.MAJOR=3]="MAJOR"}(n||(n={}))},function(e,t,r){"use strict";!function(t){function r(e){return parseInt(e)===e}function n(e){if(!r(e.length))return!1;for(var t=0;t255)return!1;return!0}function a(e,t){if(e.buffer&&ArrayBuffer.isView(e)&&"Uint8Array"===e.name)return t&&(e=e.slice?e.slice():Array.prototype.slice.call(e)),e;if(Array.isArray(e)){if(!n(e))throw new Error("Array contains invalid value: "+e);return new Uint8Array(e)}if(r(e.length)&&n(e))return new Uint8Array(e);throw new Error("unsupported array-like object")}function i(e){return new Uint8Array(e)}function o(e,t,r,n,a){null==n&&null==a||(e=e.slice?e.slice(n,a):Array.prototype.slice.call(e,n,a)),t.set(e,r)}var c={toBytes:function(e){var t=[],r=0;for(e=encodeURI(e);r191&&n<224?(t.push(String.fromCharCode((31&n)<<6|63&e[r+1])),r+=2):(t.push(String.fromCharCode((15&n)<<12|(63&e[r+1])<<6|63&e[r+2])),r+=3)}return t.join("")}},s=function(){var e="0123456789abcdef";return{toBytes:function(e){for(var t=[],r=0;r>4]+e[15&a])}return r.join("")}}}(),f={16:10,24:12,32:14},d=[1,2,4,8,16,32,64,128,27,54,108,216,171,77,154,47,94,188,99,198,151,53,106,212,179,125,250,239,197,145],u=[99,124,119,123,242,107,111,197,48,1,103,43,254,215,171,118,202,130,201,125,250,89,71,240,173,212,162,175,156,164,114,192,183,253,147,38,54,63,247,204,52,165,229,241,113,216,49,21,4,199,35,195,24,150,5,154,7,18,128,226,235,39,178,117,9,131,44,26,27,110,90,160,82,59,214,179,41,227,47,132,83,209,0,237,32,252,177,91,106,203,190,57,74,76,88,207,208,239,170,251,67,77,51,133,69,249,2,127,80,60,159,168,81,163,64,143,146,157,56,245,188,182,218,33,16,255,243,210,205,12,19,236,95,151,68,23,196,167,126,61,100,93,25,115,96,129,79,220,34,42,144,136,70,238,184,20,222,94,11,219,224,50,58,10,73,6,36,92,194,211,172,98,145,149,228,121,231,200,55,109,141,213,78,169,108,86,244,234,101,122,174,8,186,120,37,46,28,166,180,198,232,221,116,31,75,189,139,138,112,62,181,102,72,3,246,14,97,53,87,185,134,193,29,158,225,248,152,17,105,217,142,148,155,30,135,233,206,85,40,223,140,161,137,13,191,230,66,104,65,153,45,15,176,84,187,22],l=[82,9,106,213,48,54,165,56,191,64,163,158,129,243,215,251,124,227,57,130,155,47,255,135,52,142,67,68,196,222,233,203,84,123,148,50,166,194,35,61,238,76,149,11,66,250,195,78,8,46,161,102,40,217,36,178,118,91,162,73,109,139,209,37,114,248,246,100,134,104,152,22,212,164,92,204,93,101,182,146,108,112,72,80,253,237,185,218,94,21,70,87,167,141,157,132,144,216,171,0,140,188,211,10,247,228,88,5,184,179,69,6,208,44,30,143,202,63,15,2,193,175,189,3,1,19,138,107,58,145,17,65,79,103,220,234,151,242,207,206,240,180,230,115,150,172,116,34,231,173,53,133,226,249,55,232,28,117,223,110,71,241,26,113,29,41,197,137,111,183,98,14,170,24,190,27,252,86,62,75,198,210,121,32,154,219,192,254,120,205,90,244,31,221,168,51,136,7,199,49,177,18,16,89,39,128,236,95,96,81,127,169,25,181,74,13,45,229,122,159,147,201,156,239,160,224,59,77,174,42,245,176,200,235,187,60,131,83,153,97,23,43,4,126,186,119,214,38,225,105,20,99,85,33,12,125],b=[3328402341,4168907908,4000806809,4135287693,4294111757,3597364157,3731845041,2445657428,1613770832,33620227,3462883241,1445669757,3892248089,3050821474,1303096294,3967186586,2412431941,528646813,2311702848,4202528135,4026202645,2992200171,2387036105,4226871307,1101901292,3017069671,1604494077,1169141738,597466303,1403299063,3832705686,2613100635,1974974402,3791519004,1033081774,1277568618,1815492186,2118074177,4126668546,2211236943,1748251740,1369810420,3521504564,4193382664,3799085459,2883115123,1647391059,706024767,134480908,2512897874,1176707941,2646852446,806885416,932615841,168101135,798661301,235341577,605164086,461406363,3756188221,3454790438,1311188841,2142417613,3933566367,302582043,495158174,1479289972,874125870,907746093,3698224818,3025820398,1537253627,2756858614,1983593293,3084310113,2108928974,1378429307,3722699582,1580150641,327451799,2790478837,3117535592,0,3253595436,1075847264,3825007647,2041688520,3059440621,3563743934,2378943302,1740553945,1916352843,2487896798,2555137236,2958579944,2244988746,3151024235,3320835882,1336584933,3992714006,2252555205,2588757463,1714631509,293963156,2319795663,3925473552,67240454,4269768577,2689618160,2017213508,631218106,1269344483,2723238387,1571005438,2151694528,93294474,1066570413,563977660,1882732616,4059428100,1673313503,2008463041,2950355573,1109467491,537923632,3858759450,4260623118,3218264685,2177748300,403442708,638784309,3287084079,3193921505,899127202,2286175436,773265209,2479146071,1437050866,4236148354,2050833735,3362022572,3126681063,840505643,3866325909,3227541664,427917720,2655997905,2749160575,1143087718,1412049534,999329963,193497219,2353415882,3354324521,1807268051,672404540,2816401017,3160301282,369822493,2916866934,3688947771,1681011286,1949973070,336202270,2454276571,201721354,1210328172,3093060836,2680341085,3184776046,1135389935,3294782118,965841320,831886756,3554993207,4068047243,3588745010,2345191491,1849112409,3664604599,26054028,2983581028,2622377682,1235855840,3630984372,2891339514,4092916743,3488279077,3395642799,4101667470,1202630377,268961816,1874508501,4034427016,1243948399,1546530418,941366308,1470539505,1941222599,2546386513,3421038627,2715671932,3899946140,1042226977,2521517021,1639824860,227249030,260737669,3765465232,2084453954,1907733956,3429263018,2420656344,100860677,4160157185,470683154,3261161891,1781871967,2924959737,1773779408,394692241,2579611992,974986535,664706745,3655459128,3958962195,731420851,571543859,3530123707,2849626480,126783113,865375399,765172662,1008606754,361203602,3387549984,2278477385,2857719295,1344809080,2782912378,59542671,1503764984,160008576,437062935,1707065306,3622233649,2218934982,3496503480,2185314755,697932208,1512910199,504303377,2075177163,2824099068,1841019862,739644986],h=[2781242211,2230877308,2582542199,2381740923,234877682,3184946027,2984144751,1418839493,1348481072,50462977,2848876391,2102799147,434634494,1656084439,3863849899,2599188086,1167051466,2636087938,1082771913,2281340285,368048890,3954334041,3381544775,201060592,3963727277,1739838676,4250903202,3930435503,3206782108,4149453988,2531553906,1536934080,3262494647,484572669,2923271059,1783375398,1517041206,1098792767,49674231,1334037708,1550332980,4098991525,886171109,150598129,2481090929,1940642008,1398944049,1059722517,201851908,1385547719,1699095331,1587397571,674240536,2704774806,252314885,3039795866,151914247,908333586,2602270848,1038082786,651029483,1766729511,3447698098,2682942837,454166793,2652734339,1951935532,775166490,758520603,3000790638,4004797018,4217086112,4137964114,1299594043,1639438038,3464344499,2068982057,1054729187,1901997871,2534638724,4121318227,1757008337,0,750906861,1614815264,535035132,3363418545,3988151131,3201591914,1183697867,3647454910,1265776953,3734260298,3566750796,3903871064,1250283471,1807470800,717615087,3847203498,384695291,3313910595,3617213773,1432761139,2484176261,3481945413,283769337,100925954,2180939647,4037038160,1148730428,3123027871,3813386408,4087501137,4267549603,3229630528,2315620239,2906624658,3156319645,1215313976,82966005,3747855548,3245848246,1974459098,1665278241,807407632,451280895,251524083,1841287890,1283575245,337120268,891687699,801369324,3787349855,2721421207,3431482436,959321879,1469301956,4065699751,2197585534,1199193405,2898814052,3887750493,724703513,2514908019,2696962144,2551808385,3516813135,2141445340,1715741218,2119445034,2872807568,2198571144,3398190662,700968686,3547052216,1009259540,2041044702,3803995742,487983883,1991105499,1004265696,1449407026,1316239930,504629770,3683797321,168560134,1816667172,3837287516,1570751170,1857934291,4014189740,2797888098,2822345105,2754712981,936633572,2347923833,852879335,1133234376,1500395319,3084545389,2348912013,1689376213,3533459022,3762923945,3034082412,4205598294,133428468,634383082,2949277029,2398386810,3913789102,403703816,3580869306,2297460856,1867130149,1918643758,607656988,4049053350,3346248884,1368901318,600565992,2090982877,2632479860,557719327,3717614411,3697393085,2249034635,2232388234,2430627952,1115438654,3295786421,2865522278,3633334344,84280067,33027830,303828494,2747425121,1600795957,4188952407,3496589753,2434238086,1486471617,658119965,3106381470,953803233,334231800,3005978776,857870609,3151128937,1890179545,2298973838,2805175444,3056442267,574365214,2450884487,550103529,1233637070,4289353045,2018519080,2057691103,2399374476,4166623649,2148108681,387583245,3664101311,836232934,3330556482,3100665960,3280093505,2955516313,2002398509,287182607,3413881008,4238890068,3597515707,975967766],p=[1671808611,2089089148,2006576759,2072901243,4061003762,1807603307,1873927791,3310653893,810573872,16974337,1739181671,729634347,4263110654,3613570519,2883997099,1989864566,3393556426,2191335298,3376449993,2106063485,4195741690,1508618841,1204391495,4027317232,2917941677,3563566036,2734514082,2951366063,2629772188,2767672228,1922491506,3227229120,3082974647,4246528509,2477669779,644500518,911895606,1061256767,4144166391,3427763148,878471220,2784252325,3845444069,4043897329,1905517169,3631459288,827548209,356461077,67897348,3344078279,593839651,3277757891,405286936,2527147926,84871685,2595565466,118033927,305538066,2157648768,3795705826,3945188843,661212711,2999812018,1973414517,152769033,2208177539,745822252,439235610,455947803,1857215598,1525593178,2700827552,1391895634,994932283,3596728278,3016654259,695947817,3812548067,795958831,2224493444,1408607827,3513301457,0,3979133421,543178784,4229948412,2982705585,1542305371,1790891114,3410398667,3201918910,961245753,1256100938,1289001036,1491644504,3477767631,3496721360,4012557807,2867154858,4212583931,1137018435,1305975373,861234739,2241073541,1171229253,4178635257,33948674,2139225727,1357946960,1011120188,2679776671,2833468328,1374921297,2751356323,1086357568,2408187279,2460827538,2646352285,944271416,4110742005,3168756668,3066132406,3665145818,560153121,271589392,4279952895,4077846003,3530407890,3444343245,202643468,322250259,3962553324,1608629855,2543990167,1154254916,389623319,3294073796,2817676711,2122513534,1028094525,1689045092,1575467613,422261273,1939203699,1621147744,2174228865,1339137615,3699352540,577127458,712922154,2427141008,2290289544,1187679302,3995715566,3100863416,339486740,3732514782,1591917662,186455563,3681988059,3762019296,844522546,978220090,169743370,1239126601,101321734,611076132,1558493276,3260915650,3547250131,2901361580,1655096418,2443721105,2510565781,3828863972,2039214713,3878868455,3359869896,928607799,1840765549,2374762893,3580146133,1322425422,2850048425,1823791212,1459268694,4094161908,3928346602,1706019429,2056189050,2934523822,135794696,3134549946,2022240376,628050469,779246638,472135708,2800834470,3032970164,3327236038,3894660072,3715932637,1956440180,522272287,1272813131,3185336765,2340818315,2323976074,1888542832,1044544574,3049550261,1722469478,1222152264,50660867,4127324150,236067854,1638122081,895445557,1475980887,3117443513,2257655686,3243809217,489110045,2662934430,3778599393,4162055160,2561878936,288563729,1773916777,3648039385,2391345038,2493985684,2612407707,505560094,2274497927,3911240169,3460925390,1442818645,678973480,3749357023,2358182796,2717407649,2306869641,219617805,3218761151,3862026214,1120306242,1756942440,1103331905,2578459033,762796589,252780047,2966125488,1425844308,3151392187,372911126],m=[1667474886,2088535288,2004326894,2071694838,4075949567,1802223062,1869591006,3318043793,808472672,16843522,1734846926,724270422,4278065639,3621216949,2880169549,1987484396,3402253711,2189597983,3385409673,2105378810,4210693615,1499065266,1195886990,4042263547,2913856577,3570689971,2728590687,2947541573,2627518243,2762274643,1920112356,3233831835,3082273397,4261223649,2475929149,640051788,909531756,1061110142,4160160501,3435941763,875846760,2779116625,3857003729,4059105529,1903268834,3638064043,825316194,353713962,67374088,3351728789,589522246,3284360861,404236336,2526454071,84217610,2593830191,117901582,303183396,2155911963,3806477791,3958056653,656894286,2998062463,1970642922,151591698,2206440989,741110872,437923380,454765878,1852748508,1515908788,2694904667,1381168804,993742198,3604373943,3014905469,690584402,3823320797,791638366,2223281939,1398011302,3520161977,0,3991743681,538992704,4244381667,2981218425,1532751286,1785380564,3419096717,3200178535,960056178,1246420628,1280103576,1482221744,3486468741,3503319995,4025428677,2863326543,4227536621,1128514950,1296947098,859002214,2240123921,1162203018,4193849577,33687044,2139062782,1347481760,1010582648,2678045221,2829640523,1364325282,2745433693,1077985408,2408548869,2459086143,2644360225,943212656,4126475505,3166494563,3065430391,3671750063,555836226,269496352,4294908645,4092792573,3537006015,3452783745,202118168,320025894,3974901699,1600119230,2543297077,1145359496,387397934,3301201811,2812801621,2122220284,1027426170,1684319432,1566435258,421079858,1936954854,1616945344,2172753945,1330631070,3705438115,572679748,707427924,2425400123,2290647819,1179044492,4008585671,3099120491,336870440,3739122087,1583276732,185277718,3688593069,3772791771,842159716,976899700,168435220,1229577106,101059084,606366792,1549591736,3267517855,3553849021,2897014595,1650632388,2442242105,2509612081,3840161747,2038008818,3890688725,3368567691,926374254,1835907034,2374863873,3587531953,1313788572,2846482505,1819063512,1448540844,4109633523,3941213647,1701162954,2054852340,2930698567,134748176,3132806511,2021165296,623210314,774795868,471606328,2795958615,3031746419,3334885783,3907527627,3722280097,1953799400,522133822,1263263126,3183336545,2341176845,2324333839,1886425312,1044267644,3048588401,1718004428,1212733584,50529542,4143317495,235803164,1633788866,892690282,1465383342,3115962473,2256965911,3250673817,488449850,2661202215,3789633753,4177007595,2560144171,286339874,1768537042,3654906025,2391705863,2492770099,2610673197,505291324,2273808917,3924369609,3469625735,1431699370,673740880,3755965093,2358021891,2711746649,2307489801,218961690,3217021541,3873845719,1111672452,1751693520,1094828930,2576986153,757954394,252645662,2964376443,1414855848,3149649517,370555436],v=[1374988112,2118214995,437757123,975658646,1001089995,530400753,2902087851,1273168787,540080725,2910219766,2295101073,4110568485,1340463100,3307916247,641025152,3043140495,3736164937,632953703,1172967064,1576976609,3274667266,2169303058,2370213795,1809054150,59727847,361929877,3211623147,2505202138,3569255213,1484005843,1239443753,2395588676,1975683434,4102977912,2572697195,666464733,3202437046,4035489047,3374361702,2110667444,1675577880,3843699074,2538681184,1649639237,2976151520,3144396420,4269907996,4178062228,1883793496,2403728665,2497604743,1383856311,2876494627,1917518562,3810496343,1716890410,3001755655,800440835,2261089178,3543599269,807962610,599762354,33778362,3977675356,2328828971,2809771154,4077384432,1315562145,1708848333,101039829,3509871135,3299278474,875451293,2733856160,92987698,2767645557,193195065,1080094634,1584504582,3178106961,1042385657,2531067453,3711829422,1306967366,2438237621,1908694277,67556463,1615861247,429456164,3602770327,2302690252,1742315127,2968011453,126454664,3877198648,2043211483,2709260871,2084704233,4169408201,0,159417987,841739592,504459436,1817866830,4245618683,260388950,1034867998,908933415,168810852,1750902305,2606453969,607530554,202008497,2472011535,3035535058,463180190,2160117071,1641816226,1517767529,470948374,3801332234,3231722213,1008918595,303765277,235474187,4069246893,766945465,337553864,1475418501,2943682380,4003061179,2743034109,4144047775,1551037884,1147550661,1543208500,2336434550,3408119516,3069049960,3102011747,3610369226,1113818384,328671808,2227573024,2236228733,3535486456,2935566865,3341394285,496906059,3702665459,226906860,2009195472,733156972,2842737049,294930682,1206477858,2835123396,2700099354,1451044056,573804783,2269728455,3644379585,2362090238,2564033334,2801107407,2776292904,3669462566,1068351396,742039012,1350078989,1784663195,1417561698,4136440770,2430122216,775550814,2193862645,2673705150,1775276924,1876241833,3475313331,3366754619,270040487,3902563182,3678124923,3441850377,1851332852,3969562369,2203032232,3868552805,2868897406,566021896,4011190502,3135740889,1248802510,3936291284,699432150,832877231,708780849,3332740144,899835584,1951317047,4236429990,3767586992,866637845,4043610186,1106041591,2144161806,395441711,1984812685,1139781709,3433712980,3835036895,2664543715,1282050075,3240894392,1181045119,2640243204,25965917,4203181171,4211818798,3009879386,2463879762,3910161971,1842759443,2597806476,933301370,1509430414,3943906441,3467192302,3076639029,3776767469,2051518780,2631065433,1441952575,404016761,1942435775,1408749034,1610459739,3745345300,2017778566,3400528769,3110650942,941896748,3265478751,371049330,3168937228,675039627,4279080257,967311729,135050206,3635733660,1683407248,2076935265,3576870512,1215061108,3501741890],g=[1347548327,1400783205,3273267108,2520393566,3409685355,4045380933,2880240216,2471224067,1428173050,4138563181,2441661558,636813900,4233094615,3620022987,2149987652,2411029155,1239331162,1730525723,2554718734,3781033664,46346101,310463728,2743944855,3328955385,3875770207,2501218972,3955191162,3667219033,768917123,3545789473,692707433,1150208456,1786102409,2029293177,1805211710,3710368113,3065962831,401639597,1724457132,3028143674,409198410,2196052529,1620529459,1164071807,3769721975,2226875310,486441376,2499348523,1483753576,428819965,2274680428,3075636216,598438867,3799141122,1474502543,711349675,129166120,53458370,2592523643,2782082824,4063242375,2988687269,3120694122,1559041666,730517276,2460449204,4042459122,2706270690,3446004468,3573941694,533804130,2328143614,2637442643,2695033685,839224033,1973745387,957055980,2856345839,106852767,1371368976,4181598602,1033297158,2933734917,1179510461,3046200461,91341917,1862534868,4284502037,605657339,2547432937,3431546947,2003294622,3182487618,2282195339,954669403,3682191598,1201765386,3917234703,3388507166,0,2198438022,1211247597,2887651696,1315723890,4227665663,1443857720,507358933,657861945,1678381017,560487590,3516619604,975451694,2970356327,261314535,3535072918,2652609425,1333838021,2724322336,1767536459,370938394,182621114,3854606378,1128014560,487725847,185469197,2918353863,3106780840,3356761769,2237133081,1286567175,3152976349,4255350624,2683765030,3160175349,3309594171,878443390,1988838185,3704300486,1756818940,1673061617,3403100636,272786309,1075025698,545572369,2105887268,4174560061,296679730,1841768865,1260232239,4091327024,3960309330,3497509347,1814803222,2578018489,4195456072,575138148,3299409036,446754879,3629546796,4011996048,3347532110,3252238545,4270639778,915985419,3483825537,681933534,651868046,2755636671,3828103837,223377554,2607439820,1649704518,3270937875,3901806776,1580087799,4118987695,3198115200,2087309459,2842678573,3016697106,1003007129,2802849917,1860738147,2077965243,164439672,4100872472,32283319,2827177882,1709610350,2125135846,136428751,3874428392,3652904859,3460984630,3572145929,3593056380,2939266226,824852259,818324884,3224740454,930369212,2801566410,2967507152,355706840,1257309336,4148292826,243256656,790073846,2373340630,1296297904,1422699085,3756299780,3818836405,457992840,3099667487,2135319889,77422314,1560382517,1945798516,788204353,1521706781,1385356242,870912086,325965383,2358957921,2050466060,2388260884,2313884476,4006521127,901210569,3990953189,1014646705,1503449823,1062597235,2031621326,3212035895,3931371469,1533017514,350174575,2256028891,2177544179,1052338372,741876788,1606591296,1914052035,213705253,2334669897,1107234197,1899603969,3725069491,2631447780,2422494913,1635502980,1893020342,1950903388,1120974935],x=[2807058932,1699970625,2764249623,1586903591,1808481195,1173430173,1487645946,59984867,4199882800,1844882806,1989249228,1277555970,3623636965,3419915562,1149249077,2744104290,1514790577,459744698,244860394,3235995134,1963115311,4027744588,2544078150,4190530515,1608975247,2627016082,2062270317,1507497298,2200818878,567498868,1764313568,3359936201,2305455554,2037970062,1047239e3,1910319033,1337376481,2904027272,2892417312,984907214,1243112415,830661914,861968209,2135253587,2011214180,2927934315,2686254721,731183368,1750626376,4246310725,1820824798,4172763771,3542330227,48394827,2404901663,2871682645,671593195,3254988725,2073724613,145085239,2280796200,2779915199,1790575107,2187128086,472615631,3029510009,4075877127,3802222185,4107101658,3201631749,1646252340,4270507174,1402811438,1436590835,3778151818,3950355702,3963161475,4020912224,2667994737,273792366,2331590177,104699613,95345982,3175501286,2377486676,1560637892,3564045318,369057872,4213447064,3919042237,1137477952,2658625497,1119727848,2340947849,1530455833,4007360968,172466556,266959938,516552836,0,2256734592,3980931627,1890328081,1917742170,4294704398,945164165,3575528878,958871085,3647212047,2787207260,1423022939,775562294,1739656202,3876557655,2530391278,2443058075,3310321856,547512796,1265195639,437656594,3121275539,719700128,3762502690,387781147,218828297,3350065803,2830708150,2848461854,428169201,122466165,3720081049,1627235199,648017665,4122762354,1002783846,2117360635,695634755,3336358691,4234721005,4049844452,3704280881,2232435299,574624663,287343814,612205898,1039717051,840019705,2708326185,793451934,821288114,1391201670,3822090177,376187827,3113855344,1224348052,1679968233,2361698556,1058709744,752375421,2431590963,1321699145,3519142200,2734591178,188127444,2177869557,3727205754,2384911031,3215212461,2648976442,2450346104,3432737375,1180849278,331544205,3102249176,4150144569,2952102595,2159976285,2474404304,766078933,313773861,2570832044,2108100632,1668212892,3145456443,2013908262,418672217,3070356634,2594734927,1852171925,3867060991,3473416636,3907448597,2614737639,919489135,164948639,2094410160,2997825956,590424639,2486224549,1723872674,3157750862,3399941250,3501252752,3625268135,2555048196,3673637356,1343127501,4130281361,3599595085,2957853679,1297403050,81781910,3051593425,2283490410,532201772,1367295589,3926170974,895287692,1953757831,1093597963,492483431,3528626907,1446242576,1192455638,1636604631,209336225,344873464,1015671571,669961897,3375740769,3857572124,2973530695,3747192018,1933530610,3464042516,935293895,3454686199,2858115069,1863638845,3683022916,4085369519,3292445032,875313188,1080017571,3279033885,621591778,1233856572,2504130317,24197544,3017672716,3835484340,3247465558,2220981195,3060847922,1551124588,1463996600],y=[4104605777,1097159550,396673818,660510266,2875968315,2638606623,4200115116,3808662347,821712160,1986918061,3430322568,38544885,3856137295,718002117,893681702,1654886325,2975484382,3122358053,3926825029,4274053469,796197571,1290801793,1184342925,3556361835,2405426947,2459735317,1836772287,1381620373,3196267988,1948373848,3764988233,3385345166,3263785589,2390325492,1480485785,3111247143,3780097726,2293045232,548169417,3459953789,3746175075,439452389,1362321559,1400849762,1685577905,1806599355,2174754046,137073913,1214797936,1174215055,3731654548,2079897426,1943217067,1258480242,529487843,1437280870,3945269170,3049390895,3313212038,923313619,679998e3,3215307299,57326082,377642221,3474729866,2041877159,133361907,1776460110,3673476453,96392454,878845905,2801699524,777231668,4082475170,2330014213,4142626212,2213296395,1626319424,1906247262,1846563261,562755902,3708173718,1040559837,3871163981,1418573201,3294430577,114585348,1343618912,2566595609,3186202582,1078185097,3651041127,3896688048,2307622919,425408743,3371096953,2081048481,1108339068,2216610296,0,2156299017,736970802,292596766,1517440620,251657213,2235061775,2933202493,758720310,265905162,1554391400,1532285339,908999204,174567692,1474760595,4002861748,2610011675,3234156416,3693126241,2001430874,303699484,2478443234,2687165888,585122620,454499602,151849742,2345119218,3064510765,514443284,4044981591,1963412655,2581445614,2137062819,19308535,1928707164,1715193156,4219352155,1126790795,600235211,3992742070,3841024952,836553431,1669664834,2535604243,3323011204,1243905413,3141400786,4180808110,698445255,2653899549,2989552604,2253581325,3252932727,3004591147,1891211689,2487810577,3915653703,4237083816,4030667424,2100090966,865136418,1229899655,953270745,3399679628,3557504664,4118925222,2061379749,3079546586,2915017791,983426092,2022837584,1607244650,2118541908,2366882550,3635996816,972512814,3283088770,1568718495,3499326569,3576539503,621982671,2895723464,410887952,2623762152,1002142683,645401037,1494807662,2595684844,1335535747,2507040230,4293295786,3167684641,367585007,3885750714,1865862730,2668221674,2960971305,2763173681,1059270954,2777952454,2724642869,1320957812,2194319100,2429595872,2815956275,77089521,3973773121,3444575871,2448830231,1305906550,4021308739,2857194700,2516901860,3518358430,1787304780,740276417,1699839814,1592394909,2352307457,2272556026,188821243,1729977011,3687994002,274084841,3594982253,3613494426,2701949495,4162096729,322734571,2837966542,1640576439,484830689,1202797690,3537852828,4067639125,349075736,3342319475,4157467219,4255800159,1030690015,1155237496,2951971274,1757691577,607398968,2738905026,499347990,3794078908,1011452712,227885567,2818666809,213114376,3034881240,1455525988,3414450555,850817237,1817998408,3092726480],w=[0,235474187,470948374,303765277,941896748,908933415,607530554,708780849,1883793496,2118214995,1817866830,1649639237,1215061108,1181045119,1417561698,1517767529,3767586992,4003061179,4236429990,4069246893,3635733660,3602770327,3299278474,3400528769,2430122216,2664543715,2362090238,2193862645,2835123396,2801107407,3035535058,3135740889,3678124923,3576870512,3341394285,3374361702,3810496343,3977675356,4279080257,4043610186,2876494627,2776292904,3076639029,3110650942,2472011535,2640243204,2403728665,2169303058,1001089995,899835584,666464733,699432150,59727847,226906860,530400753,294930682,1273168787,1172967064,1475418501,1509430414,1942435775,2110667444,1876241833,1641816226,2910219766,2743034109,2976151520,3211623147,2505202138,2606453969,2302690252,2269728455,3711829422,3543599269,3240894392,3475313331,3843699074,3943906441,4178062228,4144047775,1306967366,1139781709,1374988112,1610459739,1975683434,2076935265,1775276924,1742315127,1034867998,866637845,566021896,800440835,92987698,193195065,429456164,395441711,1984812685,2017778566,1784663195,1683407248,1315562145,1080094634,1383856311,1551037884,101039829,135050206,437757123,337553864,1042385657,807962610,573804783,742039012,2531067453,2564033334,2328828971,2227573024,2935566865,2700099354,3001755655,3168937228,3868552805,3902563182,4203181171,4102977912,3736164937,3501741890,3265478751,3433712980,1106041591,1340463100,1576976609,1408749034,2043211483,2009195472,1708848333,1809054150,832877231,1068351396,766945465,599762354,159417987,126454664,361929877,463180190,2709260871,2943682380,3178106961,3009879386,2572697195,2538681184,2236228733,2336434550,3509871135,3745345300,3441850377,3274667266,3910161971,3877198648,4110568485,4211818798,2597806476,2497604743,2261089178,2295101073,2733856160,2902087851,3202437046,2968011453,3936291284,3835036895,4136440770,4169408201,3535486456,3702665459,3467192302,3231722213,2051518780,1951317047,1716890410,1750902305,1113818384,1282050075,1584504582,1350078989,168810852,67556463,371049330,404016761,841739592,1008918595,775550814,540080725,3969562369,3801332234,4035489047,4269907996,3569255213,3669462566,3366754619,3332740144,2631065433,2463879762,2160117071,2395588676,2767645557,2868897406,3102011747,3069049960,202008497,33778362,270040487,504459436,875451293,975658646,675039627,641025152,2084704233,1917518562,1615861247,1851332852,1147550661,1248802510,1484005843,1451044056,933301370,967311729,733156972,632953703,260388950,25965917,328671808,496906059,1206477858,1239443753,1543208500,1441952575,2144161806,1908694277,1675577880,1842759443,3610369226,3644379585,3408119516,3307916247,4011190502,3776767469,4077384432,4245618683,2809771154,2842737049,3144396420,3043140495,2673705150,2438237621,2203032232,2370213795],k=[0,185469197,370938394,487725847,741876788,657861945,975451694,824852259,1483753576,1400783205,1315723890,1164071807,1950903388,2135319889,1649704518,1767536459,2967507152,3152976349,2801566410,2918353863,2631447780,2547432937,2328143614,2177544179,3901806776,3818836405,4270639778,4118987695,3299409036,3483825537,3535072918,3652904859,2077965243,1893020342,1841768865,1724457132,1474502543,1559041666,1107234197,1257309336,598438867,681933534,901210569,1052338372,261314535,77422314,428819965,310463728,3409685355,3224740454,3710368113,3593056380,3875770207,3960309330,4045380933,4195456072,2471224067,2554718734,2237133081,2388260884,3212035895,3028143674,2842678573,2724322336,4138563181,4255350624,3769721975,3955191162,3667219033,3516619604,3431546947,3347532110,2933734917,2782082824,3099667487,3016697106,2196052529,2313884476,2499348523,2683765030,1179510461,1296297904,1347548327,1533017514,1786102409,1635502980,2087309459,2003294622,507358933,355706840,136428751,53458370,839224033,957055980,605657339,790073846,2373340630,2256028891,2607439820,2422494913,2706270690,2856345839,3075636216,3160175349,3573941694,3725069491,3273267108,3356761769,4181598602,4063242375,4011996048,3828103837,1033297158,915985419,730517276,545572369,296679730,446754879,129166120,213705253,1709610350,1860738147,1945798516,2029293177,1239331162,1120974935,1606591296,1422699085,4148292826,4233094615,3781033664,3931371469,3682191598,3497509347,3446004468,3328955385,2939266226,2755636671,3106780840,2988687269,2198438022,2282195339,2501218972,2652609425,1201765386,1286567175,1371368976,1521706781,1805211710,1620529459,2105887268,1988838185,533804130,350174575,164439672,46346101,870912086,954669403,636813900,788204353,2358957921,2274680428,2592523643,2441661558,2695033685,2880240216,3065962831,3182487618,3572145929,3756299780,3270937875,3388507166,4174560061,4091327024,4006521127,3854606378,1014646705,930369212,711349675,560487590,272786309,457992840,106852767,223377554,1678381017,1862534868,1914052035,2031621326,1211247597,1128014560,1580087799,1428173050,32283319,182621114,401639597,486441376,768917123,651868046,1003007129,818324884,1503449823,1385356242,1333838021,1150208456,1973745387,2125135846,1673061617,1756818940,2970356327,3120694122,2802849917,2887651696,2637442643,2520393566,2334669897,2149987652,3917234703,3799141122,4284502037,4100872472,3309594171,3460984630,3545789473,3629546796,2050466060,1899603969,1814803222,1730525723,1443857720,1560382517,1075025698,1260232239,575138148,692707433,878443390,1062597235,243256656,91341917,409198410,325965383,3403100636,3252238545,3704300486,3620022987,3874428392,3990953189,4042459122,4227665663,2460449204,2578018489,2226875310,2411029155,3198115200,3046200461,2827177882,2743944855],_=[0,218828297,437656594,387781147,875313188,958871085,775562294,590424639,1750626376,1699970625,1917742170,2135253587,1551124588,1367295589,1180849278,1265195639,3501252752,3720081049,3399941250,3350065803,3835484340,3919042237,4270507174,4085369519,3102249176,3051593425,2734591178,2952102595,2361698556,2177869557,2530391278,2614737639,3145456443,3060847922,2708326185,2892417312,2404901663,2187128086,2504130317,2555048196,3542330227,3727205754,3375740769,3292445032,3876557655,3926170974,4246310725,4027744588,1808481195,1723872674,1910319033,2094410160,1608975247,1391201670,1173430173,1224348052,59984867,244860394,428169201,344873464,935293895,984907214,766078933,547512796,1844882806,1627235199,2011214180,2062270317,1507497298,1423022939,1137477952,1321699145,95345982,145085239,532201772,313773861,830661914,1015671571,731183368,648017665,3175501286,2957853679,2807058932,2858115069,2305455554,2220981195,2474404304,2658625497,3575528878,3625268135,3473416636,3254988725,3778151818,3963161475,4213447064,4130281361,3599595085,3683022916,3432737375,3247465558,3802222185,4020912224,4172763771,4122762354,3201631749,3017672716,2764249623,2848461854,2331590177,2280796200,2431590963,2648976442,104699613,188127444,472615631,287343814,840019705,1058709744,671593195,621591778,1852171925,1668212892,1953757831,2037970062,1514790577,1463996600,1080017571,1297403050,3673637356,3623636965,3235995134,3454686199,4007360968,3822090177,4107101658,4190530515,2997825956,3215212461,2830708150,2779915199,2256734592,2340947849,2627016082,2443058075,172466556,122466165,273792366,492483431,1047239e3,861968209,612205898,695634755,1646252340,1863638845,2013908262,1963115311,1446242576,1530455833,1277555970,1093597963,1636604631,1820824798,2073724613,1989249228,1436590835,1487645946,1337376481,1119727848,164948639,81781910,331544205,516552836,1039717051,821288114,669961897,719700128,2973530695,3157750862,2871682645,2787207260,2232435299,2283490410,2667994737,2450346104,3647212047,3564045318,3279033885,3464042516,3980931627,3762502690,4150144569,4199882800,3070356634,3121275539,2904027272,2686254721,2200818878,2384911031,2570832044,2486224549,3747192018,3528626907,3310321856,3359936201,3950355702,3867060991,4049844452,4234721005,1739656202,1790575107,2108100632,1890328081,1402811438,1586903591,1233856572,1149249077,266959938,48394827,369057872,418672217,1002783846,919489135,567498868,752375421,209336225,24197544,376187827,459744698,945164165,895287692,574624663,793451934,1679968233,1764313568,2117360635,1933530610,1343127501,1560637892,1243112415,1192455638,3704280881,3519142200,3336358691,3419915562,3907448597,3857572124,4075877127,4294704398,3029510009,3113855344,2927934315,2744104290,2159976285,2377486676,2594734927,2544078150],M=[0,151849742,303699484,454499602,607398968,758720310,908999204,1059270954,1214797936,1097159550,1517440620,1400849762,1817998408,1699839814,2118541908,2001430874,2429595872,2581445614,2194319100,2345119218,3034881240,3186202582,2801699524,2951971274,3635996816,3518358430,3399679628,3283088770,4237083816,4118925222,4002861748,3885750714,1002142683,850817237,698445255,548169417,529487843,377642221,227885567,77089521,1943217067,2061379749,1640576439,1757691577,1474760595,1592394909,1174215055,1290801793,2875968315,2724642869,3111247143,2960971305,2405426947,2253581325,2638606623,2487810577,3808662347,3926825029,4044981591,4162096729,3342319475,3459953789,3576539503,3693126241,1986918061,2137062819,1685577905,1836772287,1381620373,1532285339,1078185097,1229899655,1040559837,923313619,740276417,621982671,439452389,322734571,137073913,19308535,3871163981,4021308739,4104605777,4255800159,3263785589,3414450555,3499326569,3651041127,2933202493,2815956275,3167684641,3049390895,2330014213,2213296395,2566595609,2448830231,1305906550,1155237496,1607244650,1455525988,1776460110,1626319424,2079897426,1928707164,96392454,213114376,396673818,514443284,562755902,679998e3,865136418,983426092,3708173718,3557504664,3474729866,3323011204,4180808110,4030667424,3945269170,3794078908,2507040230,2623762152,2272556026,2390325492,2975484382,3092726480,2738905026,2857194700,3973773121,3856137295,4274053469,4157467219,3371096953,3252932727,3673476453,3556361835,2763173681,2915017791,3064510765,3215307299,2156299017,2307622919,2459735317,2610011675,2081048481,1963412655,1846563261,1729977011,1480485785,1362321559,1243905413,1126790795,878845905,1030690015,645401037,796197571,274084841,425408743,38544885,188821243,3613494426,3731654548,3313212038,3430322568,4082475170,4200115116,3780097726,3896688048,2668221674,2516901860,2366882550,2216610296,3141400786,2989552604,2837966542,2687165888,1202797690,1320957812,1437280870,1554391400,1669664834,1787304780,1906247262,2022837584,265905162,114585348,499347990,349075736,736970802,585122620,972512814,821712160,2595684844,2478443234,2293045232,2174754046,3196267988,3079546586,2895723464,2777952454,3537852828,3687994002,3234156416,3385345166,4142626212,4293295786,3841024952,3992742070,174567692,57326082,410887952,292596766,777231668,660510266,1011452712,893681702,1108339068,1258480242,1343618912,1494807662,1715193156,1865862730,1948373848,2100090966,2701949495,2818666809,3004591147,3122358053,2235061775,2352307457,2535604243,2653899549,3915653703,3764988233,4219352155,4067639125,3444575871,3294430577,3746175075,3594982253,836553431,953270745,600235211,718002117,367585007,484830689,133361907,251657213,2041877159,1891211689,1806599355,1654886325,1568718495,1418573201,1335535747,1184342925];function S(e){for(var t=[],r=0;r>2,this._Ke[r][t%4]=i[t],this._Kd[e-r][t%4]=i[t];for(var o,c=0,s=a;s>16&255]<<24^u[o>>8&255]<<16^u[255&o]<<8^u[o>>24&255]^d[c]<<24,c+=1,8!=a)for(t=1;t>8&255]<<8^u[o>>16&255]<<16^u[o>>24&255]<<24;for(t=a/2+1;t>2,b=s%4,this._Ke[l][b]=i[t],this._Kd[e-l][b]=i[t++],s++}for(var l=1;l>24&255]^k[o>>16&255]^_[o>>8&255]^M[255&o]},E.prototype.encrypt=function(e){if(16!=e.length)throw new Error("invalid plaintext size (must be 16 bytes)");for(var t=this._Ke.length-1,r=[0,0,0,0],n=S(e),a=0;a<4;a++)n[a]^=this._Ke[0][a];for(var o=1;o>24&255]^h[n[(a+1)%4]>>16&255]^p[n[(a+2)%4]>>8&255]^m[255&n[(a+3)%4]]^this._Ke[o][a];n=r.slice()}var c,s=i(16);for(a=0;a<4;a++)c=this._Ke[t][a],s[4*a]=255&(u[n[a]>>24&255]^c>>24),s[4*a+1]=255&(u[n[(a+1)%4]>>16&255]^c>>16),s[4*a+2]=255&(u[n[(a+2)%4]>>8&255]^c>>8),s[4*a+3]=255&(u[255&n[(a+3)%4]]^c);return s},E.prototype.decrypt=function(e){if(16!=e.length)throw new Error("invalid ciphertext size (must be 16 bytes)");for(var t=this._Kd.length-1,r=[0,0,0,0],n=S(e),a=0;a<4;a++)n[a]^=this._Kd[0][a];for(var o=1;o>24&255]^g[n[(a+3)%4]>>16&255]^x[n[(a+2)%4]>>8&255]^y[255&n[(a+1)%4]]^this._Kd[o][a];n=r.slice()}var c,s=i(16);for(a=0;a<4;a++)c=this._Kd[t][a],s[4*a]=255&(l[n[a]>>24&255]^c>>24),s[4*a+1]=255&(l[n[(a+3)%4]>>16&255]^c>>16),s[4*a+2]=255&(l[n[(a+2)%4]>>8&255]^c>>8),s[4*a+3]=255&(l[255&n[(a+1)%4]]^c);return s};var O=function e(t){if(!(this instanceof e))throw Error("AES must be instanitated with `new`");this.description="Electronic Code Block",this.name="ecb",this._aes=new E(t)};O.prototype.encrypt=function(e){if((e=a(e)).length%16!==0)throw new Error("invalid plaintext size (must be multiple of 16 bytes)");for(var t=i(e.length),r=i(16),n=0;n=0;--t)this._counter[t]=e%256,e>>=8},P.prototype.setBytes=function(e){if(16!=(e=a(e,!0)).length)throw new Error("invalid counter bytes size (must be 16 bytes)");this._counter=e},P.prototype.increment=function(){for(var e=15;e>=0;e--){if(255!==this._counter[e]){this._counter[e]++;break}this._counter[e]=0}};var C=function e(t,r){if(!(this instanceof e))throw Error("AES must be instanitated with `new`");this.description="Counter",this.name="ctr",r instanceof P||(r=new P(r)),this._counter=r,this._remainingCounter=null,this._remainingCounterIndex=16,this._aes=new E(t)};C.prototype.encrypt=function(e){for(var t=a(e,!0),r=0;r16)throw new Error("PKCS#7 padding byte out of range");for(var r=e.length-t,n=0;n=e.length?{done:!0}:{done:!1,value:e[t++]}},e:function(e){throw e},f:r}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,i,o=!0,c=!1;return{s:function(){a=e[Symbol.iterator]()},n:function(){var e=a.next();return o=e.done,e},e:function(e){c=!0,i=e},f:function(){try{o||null==a.return||a.return()}finally{if(c)throw i}}}}},function(e,t,r){"use strict";r.d(t,"a",(function(){return N}));var n=r(36),a=r(32),i=r(2),o=r.n(i),c=r(6),s=r(7),f=r(20),d=r(13),u=r(14),l=r(145),b=r(46),h=r(5),p=r(575),m=r(9),v=r(86),g=r(66),x=r(89),y=r(11),w=r(52),k=r(125),_=function(e,t,r,n){return new(r||(r=Promise))((function(a,i){function o(e){try{s(n.next(e))}catch(t){i(t)}}function c(e){try{s(n.throw(e))}catch(t){i(t)}}function s(e){var t;e.done?a(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(o,c)}s((n=n.apply(e,t||[])).next())}))},M=new y.a(w.a),S=["call","estimateGas"];function E(e,t,r){if("call"===e&&t.code===y.a.errors.SERVER_ERROR){var n=t.error;if(n&&n.message.match("reverted")&&Object(h.k)(n.data))return n.data;M.throwError("missing revert data in call exception",y.a.errors.CALL_EXCEPTION,{error:t,data:"0x"})}var a=t.message;t.code===y.a.errors.SERVER_ERROR&&t.error&&"string"===typeof t.error.message?a=t.error.message:"string"===typeof t.body?a=t.body:"string"===typeof t.responseText&&(a=t.responseText),a=(a||"").toLowerCase();var i=r.transaction||r.signedTransaction;throw a.match(/insufficient funds|base fee exceeds gas limit/)&&M.throwError("insufficient funds for intrinsic transaction cost",y.a.errors.INSUFFICIENT_FUNDS,{error:t,method:e,transaction:i}),a.match(/nonce too low/)&&M.throwError("nonce has already been used",y.a.errors.NONCE_EXPIRED,{error:t,method:e,transaction:i}),a.match(/replacement transaction underpriced/)&&M.throwError("replacement fee too low",y.a.errors.REPLACEMENT_UNDERPRICED,{error:t,method:e,transaction:i}),a.match(/only replay-protected/)&&M.throwError("legacy pre-eip-155 transactions not supported",y.a.errors.UNSUPPORTED_OPERATION,{error:t,method:e,transaction:i}),S.indexOf(e)>=0&&a.match(/gas required exceeds allowance|always failing transaction|execution reverted/)&&M.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",y.a.errors.UNPREDICTABLE_GAS_LIMIT,{error:t,method:e,transaction:i}),t}function O(e){return new Promise((function(t){setTimeout(t,e)}))}function A(e){if(e.error){var t=new Error(e.error.message);throw t.code=e.error.code,t.data=e.error.data,t}return e.result}function T(e){return e?e.toLowerCase():e}var j={},P=function(e){Object(d.a)(r,e);var t=Object(u.a)(r);function r(e,n,a){var i;if(Object(c.a)(this,r),M.checkNew(this instanceof r?this.constructor:void 0,r),i=t.call(this),e!==j)throw new Error("do not call the JsonRpcSigner constructor directly; use provider.getSigner");return Object(m.d)(Object(f.a)(i),"provider",n),null==a&&(a=0),"string"===typeof a?(Object(m.d)(Object(f.a)(i),"_address",i.provider.formatter.address(a)),Object(m.d)(Object(f.a)(i),"_index",null)):"number"===typeof a?(Object(m.d)(Object(f.a)(i),"_index",a),Object(m.d)(Object(f.a)(i),"_address",null)):M.throwArgumentError("invalid address or index","addressOrIndex",a),i}return Object(s.a)(r,[{key:"connect",value:function(e){return M.throwError("cannot alter JSON-RPC Signer connection",y.a.errors.UNSUPPORTED_OPERATION,{operation:"connect"})}},{key:"connectUnchecked",value:function(){return new C(j,this.provider,this._address||this._index)}},{key:"getAddress",value:function(){var e=this;return this._address?Promise.resolve(this._address):this.provider.send("eth_accounts",[]).then((function(t){return t.length<=e._index&&M.throwError("unknown account #"+e._index,y.a.errors.UNSUPPORTED_OPERATION,{operation:"getAddress"}),e.provider.formatter.address(t[e._index])}))}},{key:"sendUncheckedTransaction",value:function(e){var t=this;e=Object(m.g)(e);var r=this.getAddress().then((function(e){return e&&(e=e.toLowerCase()),e}));if(null==e.gasLimit){var n=Object(m.g)(e);n.from=r,e.gasLimit=this.provider.estimateGas(n)}return null!=e.to&&(e.to=Promise.resolve(e.to).then((function(e){return _(t,void 0,void 0,o.a.mark((function t(){var r;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(null!=e){t.next=2;break}return t.abrupt("return",null);case 2:return t.next=4,this.provider.resolveName(e);case 4:return null==(r=t.sent)&&M.throwArgumentError("provided ENS name resolves to null","tx.to",e),t.abrupt("return",r);case 7:case"end":return t.stop()}}),t,this)})))}))),Object(m.f)({tx:Object(m.f)(e),sender:r}).then((function(r){var n=r.tx,a=r.sender;null!=n.from?n.from.toLowerCase()!==a&&M.throwArgumentError("from address mismatch","transaction",e):n.from=a;var i=t.provider.constructor.hexlifyTransaction(n,{from:!0});return t.provider.send("eth_sendTransaction",[i]).then((function(e){return e}),(function(e){return E("sendTransaction",e,i)}))}))}},{key:"signTransaction",value:function(e){return M.throwError("signing transactions is unsupported",y.a.errors.UNSUPPORTED_OPERATION,{operation:"signTransaction"})}},{key:"sendTransaction",value:function(e){return _(this,void 0,void 0,o.a.mark((function t(){var r,n,a=this;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.provider._getInternalBlockNumber(100+2*this.provider.pollingInterval);case 2:return r=t.sent,t.next=5,this.sendUncheckedTransaction(e);case 5:return n=t.sent,t.prev=6,t.next=9,Object(x.b)((function(){return _(a,void 0,void 0,o.a.mark((function e(){var t;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.provider.getTransaction(n);case 2:if(null!==(t=e.sent)){e.next=5;break}return e.abrupt("return",void 0);case 5:return e.abrupt("return",this.provider._wrapTransaction(t,n,r));case 6:case"end":return e.stop()}}),e,this)})))}),{oncePoll:this.provider});case 9:return t.abrupt("return",t.sent);case 12:throw t.prev=12,t.t0=t.catch(6),t.t0.transactionHash=n,t.t0;case 16:case"end":return t.stop()}}),t,this,[[6,12]])})))}},{key:"signMessage",value:function(e){return _(this,void 0,void 0,o.a.mark((function t(){var r,n;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r="string"===typeof e?Object(v.c)(e):e,t.next=3,this.getAddress();case 3:return n=t.sent,t.next=6,this.provider.send("personal_sign",[Object(h.h)(r),n.toLowerCase()]);case 6:return t.abrupt("return",t.sent);case 7:case"end":return t.stop()}}),t,this)})))}},{key:"_legacySignMessage",value:function(e){return _(this,void 0,void 0,o.a.mark((function t(){var r,n;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r="string"===typeof e?Object(v.c)(e):e,t.next=3,this.getAddress();case 3:return n=t.sent,t.next=6,this.provider.send("eth_sign",[n.toLowerCase(),Object(h.h)(r)]);case 6:return t.abrupt("return",t.sent);case 7:case"end":return t.stop()}}),t,this)})))}},{key:"_signTypedData",value:function(e,t,r){return _(this,void 0,void 0,o.a.mark((function n(){var a,i,c=this;return o.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,p.a.resolveNames(e,t,r,(function(e){return c.provider.resolveName(e)}));case 2:return a=n.sent,n.next=5,this.getAddress();case 5:return i=n.sent,n.next=8,this.provider.send("eth_signTypedData_v4",[i.toLowerCase(),JSON.stringify(p.a.getPayload(a.domain,t,a.value))]);case 8:return n.abrupt("return",n.sent);case 9:case"end":return n.stop()}}),n,this)})))}},{key:"unlock",value:function(e){return _(this,void 0,void 0,o.a.mark((function t(){var r,n;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=this.provider,t.next=3,this.getAddress();case 3:return n=t.sent,t.abrupt("return",r.send("personal_unlockAccount",[n.toLowerCase(),e,null]));case 5:case"end":return t.stop()}}),t,this)})))}}]),r}(l.a),C=function(e){Object(d.a)(r,e);var t=Object(u.a)(r);function r(){return Object(c.a)(this,r),t.apply(this,arguments)}return Object(s.a)(r,[{key:"sendTransaction",value:function(e){var t=this;return this.sendUncheckedTransaction(e).then((function(e){return{hash:e,nonce:null,gasLimit:null,gasPrice:null,data:null,value:null,chainId:null,confirmations:0,from:null,wait:function(r){return t.provider.waitForTransaction(e,r)}}}))}}]),r}(P),R={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,value:!0,type:!0,accessList:!0,maxFeePerGas:!0,maxPriorityFeePerGas:!0},N=function(e){Object(d.a)(r,e);var t=Object(u.a)(r);function r(e,n){var a;Object(c.a)(this,r),M.checkNew(this instanceof r?this.constructor:void 0,r);var i=n;return null==i&&(i=new Promise((function(e,t){setTimeout((function(){a.detectNetwork().then((function(t){e(t)}),(function(e){t(e)}))}),0)}))),a=t.call(this,i),e||(e=Object(m.e)(a.constructor,"defaultUrl")()),"string"===typeof e?Object(m.d)(Object(f.a)(a),"connection",Object.freeze({url:e})):Object(m.d)(Object(f.a)(a),"connection",Object.freeze(Object(m.g)(e))),a._nextId=42,a}return Object(s.a)(r,[{key:"_cache",get:function(){return null==this._eventLoopCache&&(this._eventLoopCache={}),this._eventLoopCache}},{key:"detectNetwork",value:function(){var e=this;return this._cache.detectNetwork||(this._cache.detectNetwork=this._uncachedDetectNetwork(),setTimeout((function(){e._cache.detectNetwork=null}),0)),this._cache.detectNetwork}},{key:"_uncachedDetectNetwork",value:function(){return _(this,void 0,void 0,o.a.mark((function e(){var t,r;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,O(0);case 2:return t=null,e.prev=3,e.next=6,this.send("eth_chainId",[]);case 6:t=e.sent,e.next=19;break;case 9:return e.prev=9,e.t0=e.catch(3),e.prev=11,e.next=14,this.send("net_version",[]);case 14:t=e.sent,e.next=19;break;case 17:e.prev=17,e.t1=e.catch(11);case 19:if(null==t){e.next=28;break}return r=Object(m.e)(this.constructor,"getNetwork"),e.prev=21,e.abrupt("return",r(b.a.from(t).toNumber()));case 25:return e.prev=25,e.t2=e.catch(21),e.abrupt("return",M.throwError("could not detect network",y.a.errors.NETWORK_ERROR,{chainId:t,event:"invalidNetwork",serverError:e.t2}));case 28:return e.abrupt("return",M.throwError("could not detect network",y.a.errors.NETWORK_ERROR,{event:"noNetwork"}));case 29:case"end":return e.stop()}}),e,this,[[3,9],[11,17],[21,25]])})))}},{key:"getSigner",value:function(e){return new P(j,this,e)}},{key:"getUncheckedSigner",value:function(e){return this.getSigner(e).connectUnchecked()}},{key:"listAccounts",value:function(){var e=this;return this.send("eth_accounts",[]).then((function(t){return t.map((function(t){return e.formatter.address(t)}))}))}},{key:"send",value:function(e,t){var r=this,n={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};this.emit("debug",{action:"request",request:Object(m.c)(n),provider:this});var a=["eth_chainId","eth_blockNumber"].indexOf(e)>=0;if(a&&this._cache[e])return this._cache[e];var i=Object(x.a)(this.connection,JSON.stringify(n),A).then((function(e){return r.emit("debug",{action:"response",request:n,response:e,provider:r}),e}),(function(e){throw r.emit("debug",{action:"response",error:e,request:n,provider:r}),e}));return a&&(this._cache[e]=i,setTimeout((function(){r._cache[e]=null}),0)),i}},{key:"prepareRequest",value:function(e,t){switch(e){case"getBlockNumber":return["eth_blockNumber",[]];case"getGasPrice":return["eth_gasPrice",[]];case"getBalance":return["eth_getBalance",[T(t.address),t.blockTag]];case"getTransactionCount":return["eth_getTransactionCount",[T(t.address),t.blockTag]];case"getCode":return["eth_getCode",[T(t.address),t.blockTag]];case"getStorageAt":return["eth_getStorageAt",[T(t.address),t.position,t.blockTag]];case"sendTransaction":return["eth_sendRawTransaction",[t.signedTransaction]];case"getBlock":return t.blockTag?["eth_getBlockByNumber",[t.blockTag,!!t.includeTransactions]]:t.blockHash?["eth_getBlockByHash",[t.blockHash,!!t.includeTransactions]]:null;case"getTransaction":return["eth_getTransactionByHash",[t.transactionHash]];case"getTransactionReceipt":return["eth_getTransactionReceipt",[t.transactionHash]];case"call":return["eth_call",[Object(m.e)(this.constructor,"hexlifyTransaction")(t.transaction,{from:!0}),t.blockTag]];case"estimateGas":return["eth_estimateGas",[Object(m.e)(this.constructor,"hexlifyTransaction")(t.transaction,{from:!0})]];case"getLogs":return t.filter&&null!=t.filter.address&&(t.filter.address=T(t.filter.address)),["eth_getLogs",[t.filter]]}return null}},{key:"perform",value:function(e,t){return _(this,void 0,void 0,o.a.mark((function r(){var n,a,i;return o.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if("call"!==e&&"estimateGas"!==e){r.next=8;break}if(!(n=t.transaction)||null==n.type||!b.a.from(n.type).isZero()){r.next=8;break}if(null!=n.maxFeePerGas||null!=n.maxPriorityFeePerGas){r.next=8;break}return r.next=6,this.getFeeData();case 6:null==(a=r.sent).maxFeePerGas&&null==a.maxPriorityFeePerGas&&((t=Object(m.g)(t)).transaction=Object(m.g)(n),delete t.transaction.type);case 8:return null==(i=this.prepareRequest(e,t))&&M.throwError(e+" not implemented",y.a.errors.NOT_IMPLEMENTED,{operation:e}),r.prev=10,r.next=13,this.send(i[0],i[1]);case 13:return r.abrupt("return",r.sent);case 16:return r.prev=16,r.t0=r.catch(10),r.abrupt("return",E(e,r.t0,t));case 19:case"end":return r.stop()}}),r,this,[[10,16]])})))}},{key:"_startEvent",value:function(e){"pending"===e.tag&&this._startPending(),Object(n.a)(Object(a.a)(r.prototype),"_startEvent",this).call(this,e)}},{key:"_startPending",value:function(){if(null==this._pendingFilter){var e=this,t=this.send("eth_newPendingTransactionFilter",[]);this._pendingFilter=t,t.then((function(r){return function n(){e.send("eth_getFilterChanges",[r]).then((function(r){if(e._pendingFilter!=t)return null;var n=Promise.resolve();return r.forEach((function(t){e._emitted["t:"+t.toLowerCase()]="pending",n=n.then((function(){return e.getTransaction(t).then((function(t){return e.emit("pending",t),null}))}))})),n.then((function(){return O(1e3)}))})).then((function(){if(e._pendingFilter==t)return setTimeout((function(){n()}),0),null;e.send("eth_uninstallFilter",[r])})).catch((function(e){}))}(),r})).catch((function(e){}))}}},{key:"_stopEvent",value:function(e){"pending"===e.tag&&0===this.listenerCount("pending")&&(this._pendingFilter=null),Object(n.a)(Object(a.a)(r.prototype),"_stopEvent",this).call(this,e)}}],[{key:"defaultUrl",value:function(){return"http://localhost:8545"}},{key:"hexlifyTransaction",value:function(e,t){var r=Object(m.g)(R);if(t)for(var n in t)t[n]&&(r[n]=!0);Object(m.b)(e,r);var a={};return["gasLimit","gasPrice","type","maxFeePerGas","maxPriorityFeePerGas","nonce","value"].forEach((function(t){if(null!=e[t]){var r=Object(h.f)(e[t]);"gasLimit"===t&&(t="gas"),a[t]=r}})),["from","to","data"].forEach((function(t){null!=e[t]&&(a[t]=Object(h.h)(e[t]))})),e.accessList&&(a.accessList=Object(g.accessListify)(e.accessList)),a}}]),r}(k.a)},function(e,t,r){"use strict";var n;r.d(t,"a",(function(){return n})),function(e){e.Update="Web3ReactUpdate",e.Error="Web3ReactError",e.Deactivate="Web3ReactDeactivate"}(n||(n={}))},function(e,t,r){"use strict";r.d(t,"b",(function(){return s})),r.d(t,"a",(function(){return u}));var n=r(5),a=r(11),i=new a.a("rlp/5.5.0");function o(e){for(var t=[];e;)t.unshift(255&e),e>>=8;return t}function c(e,t,r){for(var n=0,a=0;at+1+n&&i.throwError("child data too short",a.a.errors.BUFFER_OVERRUN,{})}return{consumed:1+n,result:o}}function d(e,t){if(0===e.length&&i.throwError("data too short",a.a.errors.BUFFER_OVERRUN,{}),e[t]>=248){var r=e[t]-247;t+1+r>e.length&&i.throwError("data short segment too short",a.a.errors.BUFFER_OVERRUN,{});var o=c(e,t+1,r);return t+1+r+o>e.length&&i.throwError("data long segment too short",a.a.errors.BUFFER_OVERRUN,{}),f(e,t,t+1+r,r+o)}if(e[t]>=192){var s=e[t]-192;return t+1+s>e.length&&i.throwError("data array too short",a.a.errors.BUFFER_OVERRUN,{}),f(e,t,t+1,s)}if(e[t]>=184){var d=e[t]-183;t+1+d>e.length&&i.throwError("data array too short",a.a.errors.BUFFER_OVERRUN,{});var u=c(e,t+1,d);return t+1+d+u>e.length&&i.throwError("data array too short",a.a.errors.BUFFER_OVERRUN,{}),{consumed:1+d+u,result:Object(n.h)(e.slice(t+1+d,t+1+d+u))}}if(e[t]>=128){var l=e[t]-128;return t+1+l>e.length&&i.throwError("data too short",a.a.errors.BUFFER_OVERRUN,{}),{consumed:1+l,result:Object(n.h)(e.slice(t+1,t+1+l))}}return{consumed:1,result:Object(n.h)(e[t])}}function u(e){var t=Object(n.a)(e),r=d(t,0);return r.consumed!==t.length&&i.throwArgumentError("invalid rlp data","data",e),r.result}},function(e,t,r){(function(e){!function(e,t){"use strict";function n(e,t){if(!e)throw new Error(t||"Assertion failed")}function a(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function i(e,t,r){if(i.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var o;"object"===typeof e?e.exports=i:t.BN=i,i.BN=i,i.wordSize=26;try{o=r(806).Buffer}catch(M){}function c(e,t,r){for(var n=0,a=Math.min(e.length,r),i=t;i=49&&o<=54?o-49+10:o>=17&&o<=22?o-17+10:15&o}return n}function s(e,t,r,n){for(var a=0,i=Math.min(e.length,r),o=t;o=49?c-49+10:c>=17?c-17+10:c}return a}i.isBN=function(e){return e instanceof i||null!==e&&"object"===typeof e&&e.constructor.wordSize===i.wordSize&&Array.isArray(e.words)},i.max=function(e,t){return e.cmp(t)>0?e:t},i.min=function(e,t){return e.cmp(t)<0?e:t},i.prototype._init=function(e,t,r){if("number"===typeof e)return this._initNumber(e,t,r);if("object"===typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var a=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&a++,16===t?this._parseHex(e,a):this._parseBase(e,t,a),"-"===e[0]&&(this.negative=1),this.strip(),"le"===r&&this._initArray(this.toArray(),t,r)},i.prototype._initNumber=function(e,t,r){e<0&&(this.negative=1,e=-e),e<67108864?(this.words=[67108863&e],this.length=1):e<4503599627370496?(this.words=[67108863&e,e/67108864&67108863],this.length=2):(n(e<9007199254740992),this.words=[67108863&e,e/67108864&67108863,1],this.length=3),"le"===r&&this._initArray(this.toArray(),t,r)},i.prototype._initArray=function(e,t,r){if(n("number"===typeof e.length),e.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(e.length/3),this.words=new Array(this.length);for(var a=0;a=0;a-=3)o=e[a]|e[a-1]<<8|e[a-2]<<16,this.words[i]|=o<>>26-c&67108863,(c+=24)>=26&&(c-=26,i++);else if("le"===r)for(a=0,i=0;a>>26-c&67108863,(c+=24)>=26&&(c-=26,i++);return this.strip()},i.prototype._parseHex=function(e,t){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var r=0;r=t;r-=6)a=c(e,r,r+6),this.words[n]|=a<>>26-i&4194303,(i+=24)>=26&&(i-=26,n++);r+6!==t&&(a=c(e,t,r+6),this.words[n]|=a<>>26-i&4194303),this.strip()},i.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,a=1;a<=67108863;a*=t)n++;n--,a=a/t|0;for(var i=e.length-r,o=i%n,c=Math.min(i,i-o)+r,f=0,d=r;d1&&0===this.words[this.length-1];)this.length--;return this._normSign()},i.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},i.prototype.inspect=function(){return(this.red?""};var f=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],d=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],u=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];function l(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var a=0|e.words[0],i=0|t.words[0],o=a*i,c=67108863&o,s=o/67108864|0;r.words[0]=c;for(var f=1;f>>26,u=67108863&s,l=Math.min(f,t.length-1),b=Math.max(0,f-e.length+1);b<=l;b++){var h=f-b|0;d+=(o=(a=0|e.words[h])*(i=0|t.words[b])+u)/67108864|0,u=67108863&o}r.words[f]=0|u,s=0|d}return 0!==s?r.words[f]=0|s:r.length--,r.strip()}i.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var a=0,i=0,o=0;o>>24-a&16777215)||o!==this.length-1?f[6-s.length]+s+r:s+r,(a+=2)>=26&&(a-=26,o--)}for(0!==i&&(r=i.toString(16)+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var l=d[e],b=u[e];r="";var h=this.clone();for(h.negative=0;!h.isZero();){var p=h.modn(b).toString(e);r=(h=h.idivn(b)).isZero()?p+r:f[l-p.length]+p+r}for(this.isZero()&&(r="0"+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},i.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},i.prototype.toJSON=function(){return this.toString(16)},i.prototype.toBuffer=function(e,t){return n("undefined"!==typeof o),this.toArrayLike(o,e,t)},i.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},i.prototype.toArrayLike=function(e,t,r){var a=this.byteLength(),i=r||Math.max(1,a);n(a<=i,"byte array longer than desired length"),n(i>0,"Requested array length <= 0"),this.strip();var o,c,s="le"===t,f=new e(i),d=this.clone();if(s){for(c=0;!d.isZero();c++)o=d.andln(255),d.iushrn(8),f[c]=o;for(;c=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},i.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0===(8191&t)&&(r+=13,t>>>=13),0===(127&t)&&(r+=7,t>>>=7),0===(15&t)&&(r+=4,t>>>=4),0===(3&t)&&(r+=2,t>>>=2),0===(1&t)&&r++,r},i.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},i.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},i.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},i.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},i.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},i.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},i.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},i.prototype.inotn=function(e){n("number"===typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var a=0;a0&&(this.words[a]=~this.words[a]&67108863>>26-r),this.strip()},i.prototype.notn=function(e){return this.clone().inotn(e)},i.prototype.setn=function(e,t){n("number"===typeof e&&e>=0);var r=e/26|0,a=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var a=0,i=0;i>>26;for(;0!==a&&i>>26;if(this.length=r.length,0!==a)this.words[this.length]=a,this.length++;else if(r!==this)for(;ie.length?this.clone().iadd(e):e.clone().iadd(this)},i.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,a=this.cmp(e);if(0===a)return this.negative=0,this.length=1,this.words[0]=0,this;a>0?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>26,this.words[o]=67108863&t;for(;0!==i&&o>26,this.words[o]=67108863&t;if(0===i&&o>>13,b=0|o[1],h=8191&b,p=b>>>13,m=0|o[2],v=8191&m,g=m>>>13,x=0|o[3],y=8191&x,w=x>>>13,k=0|o[4],_=8191&k,M=k>>>13,S=0|o[5],E=8191&S,O=S>>>13,A=0|o[6],T=8191&A,j=A>>>13,P=0|o[7],C=8191&P,R=P>>>13,N=0|o[8],B=8191&N,L=N>>>13,I=0|o[9],F=8191&I,D=I>>>13,U=0|c[0],z=8191&U,H=U>>>13,q=0|c[1],J=8191&q,V=q>>>13,G=0|c[2],X=8191&G,K=G>>>13,W=0|c[3],Z=8191&W,$=W>>>13,Q=0|c[4],Y=8191&Q,ee=Q>>>13,te=0|c[5],re=8191&te,ne=te>>>13,ae=0|c[6],ie=8191&ae,oe=ae>>>13,ce=0|c[7],se=8191&ce,fe=ce>>>13,de=0|c[8],ue=8191&de,le=de>>>13,be=0|c[9],he=8191&be,pe=be>>>13;r.negative=e.negative^t.negative,r.length=19;var me=(f+(n=Math.imul(u,z))|0)+((8191&(a=(a=Math.imul(u,H))+Math.imul(l,z)|0))<<13)|0;f=((i=Math.imul(l,H))+(a>>>13)|0)+(me>>>26)|0,me&=67108863,n=Math.imul(h,z),a=(a=Math.imul(h,H))+Math.imul(p,z)|0,i=Math.imul(p,H);var ve=(f+(n=n+Math.imul(u,J)|0)|0)+((8191&(a=(a=a+Math.imul(u,V)|0)+Math.imul(l,J)|0))<<13)|0;f=((i=i+Math.imul(l,V)|0)+(a>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(v,z),a=(a=Math.imul(v,H))+Math.imul(g,z)|0,i=Math.imul(g,H),n=n+Math.imul(h,J)|0,a=(a=a+Math.imul(h,V)|0)+Math.imul(p,J)|0,i=i+Math.imul(p,V)|0;var ge=(f+(n=n+Math.imul(u,X)|0)|0)+((8191&(a=(a=a+Math.imul(u,K)|0)+Math.imul(l,X)|0))<<13)|0;f=((i=i+Math.imul(l,K)|0)+(a>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(y,z),a=(a=Math.imul(y,H))+Math.imul(w,z)|0,i=Math.imul(w,H),n=n+Math.imul(v,J)|0,a=(a=a+Math.imul(v,V)|0)+Math.imul(g,J)|0,i=i+Math.imul(g,V)|0,n=n+Math.imul(h,X)|0,a=(a=a+Math.imul(h,K)|0)+Math.imul(p,X)|0,i=i+Math.imul(p,K)|0;var xe=(f+(n=n+Math.imul(u,Z)|0)|0)+((8191&(a=(a=a+Math.imul(u,$)|0)+Math.imul(l,Z)|0))<<13)|0;f=((i=i+Math.imul(l,$)|0)+(a>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(_,z),a=(a=Math.imul(_,H))+Math.imul(M,z)|0,i=Math.imul(M,H),n=n+Math.imul(y,J)|0,a=(a=a+Math.imul(y,V)|0)+Math.imul(w,J)|0,i=i+Math.imul(w,V)|0,n=n+Math.imul(v,X)|0,a=(a=a+Math.imul(v,K)|0)+Math.imul(g,X)|0,i=i+Math.imul(g,K)|0,n=n+Math.imul(h,Z)|0,a=(a=a+Math.imul(h,$)|0)+Math.imul(p,Z)|0,i=i+Math.imul(p,$)|0;var ye=(f+(n=n+Math.imul(u,Y)|0)|0)+((8191&(a=(a=a+Math.imul(u,ee)|0)+Math.imul(l,Y)|0))<<13)|0;f=((i=i+Math.imul(l,ee)|0)+(a>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(E,z),a=(a=Math.imul(E,H))+Math.imul(O,z)|0,i=Math.imul(O,H),n=n+Math.imul(_,J)|0,a=(a=a+Math.imul(_,V)|0)+Math.imul(M,J)|0,i=i+Math.imul(M,V)|0,n=n+Math.imul(y,X)|0,a=(a=a+Math.imul(y,K)|0)+Math.imul(w,X)|0,i=i+Math.imul(w,K)|0,n=n+Math.imul(v,Z)|0,a=(a=a+Math.imul(v,$)|0)+Math.imul(g,Z)|0,i=i+Math.imul(g,$)|0,n=n+Math.imul(h,Y)|0,a=(a=a+Math.imul(h,ee)|0)+Math.imul(p,Y)|0,i=i+Math.imul(p,ee)|0;var we=(f+(n=n+Math.imul(u,re)|0)|0)+((8191&(a=(a=a+Math.imul(u,ne)|0)+Math.imul(l,re)|0))<<13)|0;f=((i=i+Math.imul(l,ne)|0)+(a>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(T,z),a=(a=Math.imul(T,H))+Math.imul(j,z)|0,i=Math.imul(j,H),n=n+Math.imul(E,J)|0,a=(a=a+Math.imul(E,V)|0)+Math.imul(O,J)|0,i=i+Math.imul(O,V)|0,n=n+Math.imul(_,X)|0,a=(a=a+Math.imul(_,K)|0)+Math.imul(M,X)|0,i=i+Math.imul(M,K)|0,n=n+Math.imul(y,Z)|0,a=(a=a+Math.imul(y,$)|0)+Math.imul(w,Z)|0,i=i+Math.imul(w,$)|0,n=n+Math.imul(v,Y)|0,a=(a=a+Math.imul(v,ee)|0)+Math.imul(g,Y)|0,i=i+Math.imul(g,ee)|0,n=n+Math.imul(h,re)|0,a=(a=a+Math.imul(h,ne)|0)+Math.imul(p,re)|0,i=i+Math.imul(p,ne)|0;var ke=(f+(n=n+Math.imul(u,ie)|0)|0)+((8191&(a=(a=a+Math.imul(u,oe)|0)+Math.imul(l,ie)|0))<<13)|0;f=((i=i+Math.imul(l,oe)|0)+(a>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(C,z),a=(a=Math.imul(C,H))+Math.imul(R,z)|0,i=Math.imul(R,H),n=n+Math.imul(T,J)|0,a=(a=a+Math.imul(T,V)|0)+Math.imul(j,J)|0,i=i+Math.imul(j,V)|0,n=n+Math.imul(E,X)|0,a=(a=a+Math.imul(E,K)|0)+Math.imul(O,X)|0,i=i+Math.imul(O,K)|0,n=n+Math.imul(_,Z)|0,a=(a=a+Math.imul(_,$)|0)+Math.imul(M,Z)|0,i=i+Math.imul(M,$)|0,n=n+Math.imul(y,Y)|0,a=(a=a+Math.imul(y,ee)|0)+Math.imul(w,Y)|0,i=i+Math.imul(w,ee)|0,n=n+Math.imul(v,re)|0,a=(a=a+Math.imul(v,ne)|0)+Math.imul(g,re)|0,i=i+Math.imul(g,ne)|0,n=n+Math.imul(h,ie)|0,a=(a=a+Math.imul(h,oe)|0)+Math.imul(p,ie)|0,i=i+Math.imul(p,oe)|0;var _e=(f+(n=n+Math.imul(u,se)|0)|0)+((8191&(a=(a=a+Math.imul(u,fe)|0)+Math.imul(l,se)|0))<<13)|0;f=((i=i+Math.imul(l,fe)|0)+(a>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(B,z),a=(a=Math.imul(B,H))+Math.imul(L,z)|0,i=Math.imul(L,H),n=n+Math.imul(C,J)|0,a=(a=a+Math.imul(C,V)|0)+Math.imul(R,J)|0,i=i+Math.imul(R,V)|0,n=n+Math.imul(T,X)|0,a=(a=a+Math.imul(T,K)|0)+Math.imul(j,X)|0,i=i+Math.imul(j,K)|0,n=n+Math.imul(E,Z)|0,a=(a=a+Math.imul(E,$)|0)+Math.imul(O,Z)|0,i=i+Math.imul(O,$)|0,n=n+Math.imul(_,Y)|0,a=(a=a+Math.imul(_,ee)|0)+Math.imul(M,Y)|0,i=i+Math.imul(M,ee)|0,n=n+Math.imul(y,re)|0,a=(a=a+Math.imul(y,ne)|0)+Math.imul(w,re)|0,i=i+Math.imul(w,ne)|0,n=n+Math.imul(v,ie)|0,a=(a=a+Math.imul(v,oe)|0)+Math.imul(g,ie)|0,i=i+Math.imul(g,oe)|0,n=n+Math.imul(h,se)|0,a=(a=a+Math.imul(h,fe)|0)+Math.imul(p,se)|0,i=i+Math.imul(p,fe)|0;var Me=(f+(n=n+Math.imul(u,ue)|0)|0)+((8191&(a=(a=a+Math.imul(u,le)|0)+Math.imul(l,ue)|0))<<13)|0;f=((i=i+Math.imul(l,le)|0)+(a>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,z),a=(a=Math.imul(F,H))+Math.imul(D,z)|0,i=Math.imul(D,H),n=n+Math.imul(B,J)|0,a=(a=a+Math.imul(B,V)|0)+Math.imul(L,J)|0,i=i+Math.imul(L,V)|0,n=n+Math.imul(C,X)|0,a=(a=a+Math.imul(C,K)|0)+Math.imul(R,X)|0,i=i+Math.imul(R,K)|0,n=n+Math.imul(T,Z)|0,a=(a=a+Math.imul(T,$)|0)+Math.imul(j,Z)|0,i=i+Math.imul(j,$)|0,n=n+Math.imul(E,Y)|0,a=(a=a+Math.imul(E,ee)|0)+Math.imul(O,Y)|0,i=i+Math.imul(O,ee)|0,n=n+Math.imul(_,re)|0,a=(a=a+Math.imul(_,ne)|0)+Math.imul(M,re)|0,i=i+Math.imul(M,ne)|0,n=n+Math.imul(y,ie)|0,a=(a=a+Math.imul(y,oe)|0)+Math.imul(w,ie)|0,i=i+Math.imul(w,oe)|0,n=n+Math.imul(v,se)|0,a=(a=a+Math.imul(v,fe)|0)+Math.imul(g,se)|0,i=i+Math.imul(g,fe)|0,n=n+Math.imul(h,ue)|0,a=(a=a+Math.imul(h,le)|0)+Math.imul(p,ue)|0,i=i+Math.imul(p,le)|0;var Se=(f+(n=n+Math.imul(u,he)|0)|0)+((8191&(a=(a=a+Math.imul(u,pe)|0)+Math.imul(l,he)|0))<<13)|0;f=((i=i+Math.imul(l,pe)|0)+(a>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(F,J),a=(a=Math.imul(F,V))+Math.imul(D,J)|0,i=Math.imul(D,V),n=n+Math.imul(B,X)|0,a=(a=a+Math.imul(B,K)|0)+Math.imul(L,X)|0,i=i+Math.imul(L,K)|0,n=n+Math.imul(C,Z)|0,a=(a=a+Math.imul(C,$)|0)+Math.imul(R,Z)|0,i=i+Math.imul(R,$)|0,n=n+Math.imul(T,Y)|0,a=(a=a+Math.imul(T,ee)|0)+Math.imul(j,Y)|0,i=i+Math.imul(j,ee)|0,n=n+Math.imul(E,re)|0,a=(a=a+Math.imul(E,ne)|0)+Math.imul(O,re)|0,i=i+Math.imul(O,ne)|0,n=n+Math.imul(_,ie)|0,a=(a=a+Math.imul(_,oe)|0)+Math.imul(M,ie)|0,i=i+Math.imul(M,oe)|0,n=n+Math.imul(y,se)|0,a=(a=a+Math.imul(y,fe)|0)+Math.imul(w,se)|0,i=i+Math.imul(w,fe)|0,n=n+Math.imul(v,ue)|0,a=(a=a+Math.imul(v,le)|0)+Math.imul(g,ue)|0,i=i+Math.imul(g,le)|0;var Ee=(f+(n=n+Math.imul(h,he)|0)|0)+((8191&(a=(a=a+Math.imul(h,pe)|0)+Math.imul(p,he)|0))<<13)|0;f=((i=i+Math.imul(p,pe)|0)+(a>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,X),a=(a=Math.imul(F,K))+Math.imul(D,X)|0,i=Math.imul(D,K),n=n+Math.imul(B,Z)|0,a=(a=a+Math.imul(B,$)|0)+Math.imul(L,Z)|0,i=i+Math.imul(L,$)|0,n=n+Math.imul(C,Y)|0,a=(a=a+Math.imul(C,ee)|0)+Math.imul(R,Y)|0,i=i+Math.imul(R,ee)|0,n=n+Math.imul(T,re)|0,a=(a=a+Math.imul(T,ne)|0)+Math.imul(j,re)|0,i=i+Math.imul(j,ne)|0,n=n+Math.imul(E,ie)|0,a=(a=a+Math.imul(E,oe)|0)+Math.imul(O,ie)|0,i=i+Math.imul(O,oe)|0,n=n+Math.imul(_,se)|0,a=(a=a+Math.imul(_,fe)|0)+Math.imul(M,se)|0,i=i+Math.imul(M,fe)|0,n=n+Math.imul(y,ue)|0,a=(a=a+Math.imul(y,le)|0)+Math.imul(w,ue)|0,i=i+Math.imul(w,le)|0;var Oe=(f+(n=n+Math.imul(v,he)|0)|0)+((8191&(a=(a=a+Math.imul(v,pe)|0)+Math.imul(g,he)|0))<<13)|0;f=((i=i+Math.imul(g,pe)|0)+(a>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,Z),a=(a=Math.imul(F,$))+Math.imul(D,Z)|0,i=Math.imul(D,$),n=n+Math.imul(B,Y)|0,a=(a=a+Math.imul(B,ee)|0)+Math.imul(L,Y)|0,i=i+Math.imul(L,ee)|0,n=n+Math.imul(C,re)|0,a=(a=a+Math.imul(C,ne)|0)+Math.imul(R,re)|0,i=i+Math.imul(R,ne)|0,n=n+Math.imul(T,ie)|0,a=(a=a+Math.imul(T,oe)|0)+Math.imul(j,ie)|0,i=i+Math.imul(j,oe)|0,n=n+Math.imul(E,se)|0,a=(a=a+Math.imul(E,fe)|0)+Math.imul(O,se)|0,i=i+Math.imul(O,fe)|0,n=n+Math.imul(_,ue)|0,a=(a=a+Math.imul(_,le)|0)+Math.imul(M,ue)|0,i=i+Math.imul(M,le)|0;var Ae=(f+(n=n+Math.imul(y,he)|0)|0)+((8191&(a=(a=a+Math.imul(y,pe)|0)+Math.imul(w,he)|0))<<13)|0;f=((i=i+Math.imul(w,pe)|0)+(a>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(F,Y),a=(a=Math.imul(F,ee))+Math.imul(D,Y)|0,i=Math.imul(D,ee),n=n+Math.imul(B,re)|0,a=(a=a+Math.imul(B,ne)|0)+Math.imul(L,re)|0,i=i+Math.imul(L,ne)|0,n=n+Math.imul(C,ie)|0,a=(a=a+Math.imul(C,oe)|0)+Math.imul(R,ie)|0,i=i+Math.imul(R,oe)|0,n=n+Math.imul(T,se)|0,a=(a=a+Math.imul(T,fe)|0)+Math.imul(j,se)|0,i=i+Math.imul(j,fe)|0,n=n+Math.imul(E,ue)|0,a=(a=a+Math.imul(E,le)|0)+Math.imul(O,ue)|0,i=i+Math.imul(O,le)|0;var Te=(f+(n=n+Math.imul(_,he)|0)|0)+((8191&(a=(a=a+Math.imul(_,pe)|0)+Math.imul(M,he)|0))<<13)|0;f=((i=i+Math.imul(M,pe)|0)+(a>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,re),a=(a=Math.imul(F,ne))+Math.imul(D,re)|0,i=Math.imul(D,ne),n=n+Math.imul(B,ie)|0,a=(a=a+Math.imul(B,oe)|0)+Math.imul(L,ie)|0,i=i+Math.imul(L,oe)|0,n=n+Math.imul(C,se)|0,a=(a=a+Math.imul(C,fe)|0)+Math.imul(R,se)|0,i=i+Math.imul(R,fe)|0,n=n+Math.imul(T,ue)|0,a=(a=a+Math.imul(T,le)|0)+Math.imul(j,ue)|0,i=i+Math.imul(j,le)|0;var je=(f+(n=n+Math.imul(E,he)|0)|0)+((8191&(a=(a=a+Math.imul(E,pe)|0)+Math.imul(O,he)|0))<<13)|0;f=((i=i+Math.imul(O,pe)|0)+(a>>>13)|0)+(je>>>26)|0,je&=67108863,n=Math.imul(F,ie),a=(a=Math.imul(F,oe))+Math.imul(D,ie)|0,i=Math.imul(D,oe),n=n+Math.imul(B,se)|0,a=(a=a+Math.imul(B,fe)|0)+Math.imul(L,se)|0,i=i+Math.imul(L,fe)|0,n=n+Math.imul(C,ue)|0,a=(a=a+Math.imul(C,le)|0)+Math.imul(R,ue)|0,i=i+Math.imul(R,le)|0;var Pe=(f+(n=n+Math.imul(T,he)|0)|0)+((8191&(a=(a=a+Math.imul(T,pe)|0)+Math.imul(j,he)|0))<<13)|0;f=((i=i+Math.imul(j,pe)|0)+(a>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,se),a=(a=Math.imul(F,fe))+Math.imul(D,se)|0,i=Math.imul(D,fe),n=n+Math.imul(B,ue)|0,a=(a=a+Math.imul(B,le)|0)+Math.imul(L,ue)|0,i=i+Math.imul(L,le)|0;var Ce=(f+(n=n+Math.imul(C,he)|0)|0)+((8191&(a=(a=a+Math.imul(C,pe)|0)+Math.imul(R,he)|0))<<13)|0;f=((i=i+Math.imul(R,pe)|0)+(a>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,n=Math.imul(F,ue),a=(a=Math.imul(F,le))+Math.imul(D,ue)|0,i=Math.imul(D,le);var Re=(f+(n=n+Math.imul(B,he)|0)|0)+((8191&(a=(a=a+Math.imul(B,pe)|0)+Math.imul(L,he)|0))<<13)|0;f=((i=i+Math.imul(L,pe)|0)+(a>>>13)|0)+(Re>>>26)|0,Re&=67108863;var Ne=(f+(n=Math.imul(F,he))|0)+((8191&(a=(a=Math.imul(F,pe))+Math.imul(D,he)|0))<<13)|0;return f=((i=Math.imul(D,pe))+(a>>>13)|0)+(Ne>>>26)|0,Ne&=67108863,s[0]=me,s[1]=ve,s[2]=ge,s[3]=xe,s[4]=ye,s[5]=we,s[6]=ke,s[7]=_e,s[8]=Me,s[9]=Se,s[10]=Ee,s[11]=Oe,s[12]=Ae,s[13]=Te,s[14]=je,s[15]=Pe,s[16]=Ce,s[17]=Re,s[18]=Ne,0!==f&&(s[19]=f,r.length++),r};function h(e,t,r){return(new p).mulp(e,t,r)}function p(e,t){this.x=e,this.y=t}Math.imul||(b=l),i.prototype.mulTo=function(e,t){var r=this.length+e.length;return 10===this.length&&10===e.length?b(this,e,t):r<63?l(this,e,t):r<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,a=0,i=0;i>>26)|0)>>>26,o&=67108863}r.words[i]=c,n=o,o=a}return 0!==n?r.words[i]=n:r.length--,r.strip()}(this,e,t):h(this,e,t)},p.prototype.makeRBT=function(e){for(var t=new Array(e),r=i.prototype._countBits(e)-1,n=0;n>=1;return n},p.prototype.permute=function(e,t,r,n,a,i){for(var o=0;o>>=1)a++;return 1<>>=13,r[2*o+1]=8191&i,i>>>=13;for(o=2*t;o>=26,t+=a/67108864|0,t+=i>>>26,this.words[r]=67108863&i}return 0!==t&&(this.words[r]=t,this.length++),this},i.prototype.muln=function(e){return this.clone().imuln(e)},i.prototype.sqr=function(){return this.mul(this)},i.prototype.isqr=function(){return this.imul(this.clone())},i.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>a}return t}(e);if(0===t.length)return new i(1);for(var r=this,n=0;n=0);var t,r=e%26,a=(e-r)/26,i=67108863>>>26-r<<26-r;if(0!==r){var o=0;for(t=0;t>>26-r}o&&(this.words[t]=o,this.length++)}if(0!==a){for(t=this.length-1;t>=0;t--)this.words[t+a]=this.words[t];for(t=0;t=0),a=t?(t-t%26)/26:0;var i=e%26,o=Math.min((e-i)/26,this.length),c=67108863^67108863>>>i<o)for(this.length-=o,f=0;f=0&&(0!==d||f>=a);f--){var u=0|this.words[f];this.words[f]=d<<26-i|u>>>i,d=u&c}return s&&0!==d&&(s.words[s.length++]=d),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},i.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},i.prototype.shln=function(e){return this.clone().ishln(e)},i.prototype.ushln=function(e){return this.clone().iushln(e)},i.prototype.shrn=function(e){return this.clone().ishrn(e)},i.prototype.ushrn=function(e){return this.clone().iushrn(e)},i.prototype.testn=function(e){n("number"===typeof e&&e>=0);var t=e%26,r=(e-t)/26,a=1<=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var a=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},i.prototype.isubn=function(e){if(n("number"===typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(s/67108864|0),this.words[a+r]=67108863&i}for(;a>26,this.words[a+r]=67108863&i;if(0===c)return this.strip();for(n(-1===c),c=0,a=0;a>26,this.words[a]=67108863&i;return this.negative=1,this.strip()},i.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),a=e,o=0|a.words[a.length-1];0!==(r=26-this._countBits(o))&&(a=a.ushln(r),n.iushln(r),o=0|a.words[a.length-1]);var c,s=n.length-a.length;if("mod"!==t){(c=new i(null)).length=s+1,c.words=new Array(c.length);for(var f=0;f=0;u--){var l=67108864*(0|n.words[a.length+u])+(0|n.words[a.length+u-1]);for(l=Math.min(l/o|0,67108863),n._ishlnsubmul(a,l,u);0!==n.negative;)l--,n.negative=0,n._ishlnsubmul(a,1,u),n.isZero()||(n.negative^=1);c&&(c.words[u]=l)}return c&&c.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:c||null,mod:n}},i.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new i(0),mod:new i(0)}:0!==this.negative&&0===e.negative?(c=this.neg().divmod(e,t),"mod"!==t&&(a=c.div.neg()),"div"!==t&&(o=c.mod.neg(),r&&0!==o.negative&&o.iadd(e)),{div:a,mod:o}):0===this.negative&&0!==e.negative?(c=this.divmod(e.neg(),t),"mod"!==t&&(a=c.div.neg()),{div:a,mod:c.mod}):0!==(this.negative&e.negative)?(c=this.neg().divmod(e.neg(),t),"div"!==t&&(o=c.mod.neg(),r&&0!==o.negative&&o.isub(e)),{div:c.div,mod:o}):e.length>this.length||this.cmp(e)<0?{div:new i(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new i(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new i(this.modn(e.words[0]))}:this._wordDiv(e,t);var a,o,c},i.prototype.div=function(e){return this.divmod(e,"div",!1).div},i.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},i.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},i.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),a=e.andln(1),i=r.cmp(n);return i<0||1===a&&0===i?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},i.prototype.modn=function(e){n(e<=67108863);for(var t=(1<<26)%e,r=0,a=this.length-1;a>=0;a--)r=(t*r+(0|this.words[a]))%e;return r},i.prototype.idivn=function(e){n(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var a=(0|this.words[r])+67108864*t;this.words[r]=a/e|0,t=a%e}return this.strip()},i.prototype.divn=function(e){return this.clone().idivn(e)},i.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var a=new i(1),o=new i(0),c=new i(0),s=new i(1),f=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++f;for(var d=r.clone(),u=t.clone();!t.isZero();){for(var l=0,b=1;0===(t.words[0]&b)&&l<26;++l,b<<=1);if(l>0)for(t.iushrn(l);l-- >0;)(a.isOdd()||o.isOdd())&&(a.iadd(d),o.isub(u)),a.iushrn(1),o.iushrn(1);for(var h=0,p=1;0===(r.words[0]&p)&&h<26;++h,p<<=1);if(h>0)for(r.iushrn(h);h-- >0;)(c.isOdd()||s.isOdd())&&(c.iadd(d),s.isub(u)),c.iushrn(1),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(c),o.isub(s)):(r.isub(t),c.isub(a),s.isub(o))}return{a:c,b:s,gcd:r.iushln(f)}},i.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var a,o=new i(1),c=new i(0),s=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var f=0,d=1;0===(t.words[0]&d)&&f<26;++f,d<<=1);if(f>0)for(t.iushrn(f);f-- >0;)o.isOdd()&&o.iadd(s),o.iushrn(1);for(var u=0,l=1;0===(r.words[0]&l)&&u<26;++u,l<<=1);if(u>0)for(r.iushrn(u);u-- >0;)c.isOdd()&&c.iadd(s),c.iushrn(1);t.cmp(r)>=0?(t.isub(r),o.isub(c)):(r.isub(t),c.isub(o))}return(a=0===t.cmpn(1)?o:c).cmpn(0)<0&&a.iadd(e),a},i.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var a=t.cmp(r);if(a<0){var i=t;t=r,r=i}else if(0===a||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},i.prototype.invm=function(e){return this.egcd(e).a.umod(e)},i.prototype.isEven=function(){return 0===(1&this.words[0])},i.prototype.isOdd=function(){return 1===(1&this.words[0])},i.prototype.andln=function(e){return this.words[0]&e},i.prototype.bincn=function(e){n("number"===typeof e);var t=e%26,r=(e-t)/26,a=1<>>26,c&=67108863,this.words[o]=c}return 0!==i&&(this.words[o]=i,this.length++),this},i.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},i.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var a=0|this.words[0];t=a===e?0:ae.length)return 1;if(this.length=0;r--){var n=0|this.words[r],a=0|e.words[r];if(n!==a){na&&(t=1);break}}return t},i.prototype.gtn=function(e){return 1===this.cmpn(e)},i.prototype.gt=function(e){return 1===this.cmp(e)},i.prototype.gten=function(e){return this.cmpn(e)>=0},i.prototype.gte=function(e){return this.cmp(e)>=0},i.prototype.ltn=function(e){return-1===this.cmpn(e)},i.prototype.lt=function(e){return-1===this.cmp(e)},i.prototype.lten=function(e){return this.cmpn(e)<=0},i.prototype.lte=function(e){return this.cmp(e)<=0},i.prototype.eqn=function(e){return 0===this.cmpn(e)},i.prototype.eq=function(e){return 0===this.cmp(e)},i.red=function(e){return new k(e)},i.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},i.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},i.prototype._forceRed=function(e){return this.red=e,this},i.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},i.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},i.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},i.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},i.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},i.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},i.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},i.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},i.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},i.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},i.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},i.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},i.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},i.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var m={k256:null,p224:null,p192:null,p25519:null};function v(e,t){this.name=e,this.p=new i(t,16),this.n=this.p.bitLength(),this.k=new i(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function g(){v.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function x(){v.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function y(){v.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function w(){v.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function k(e){if("string"===typeof e){var t=i._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function _(e){k.call(this,e),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new i(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}v.prototype._tmp=function(){var e=new i(null);return e.words=new Array(Math.ceil(this.n/13)),e},v.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):r.strip(),r},v.prototype.split=function(e,t){e.iushrn(this.n,0,t)},v.prototype.imulK=function(e){return e.imul(this.k)},a(g,v),g.prototype.split=function(e,t){for(var r=Math.min(e.length,9),n=0;n>>22,a=i}a>>>=22,e.words[n-10]=a,0===a&&e.length>10?e.length-=10:e.length-=9},g.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=a,t=n}return 0!==t&&(e.words[e.length++]=t),e},i._prime=function(e){if(m[e])return m[e];var t;if("k256"===e)t=new g;else if("p224"===e)t=new x;else if("p192"===e)t=new y;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new w}return m[e]=t,t},k.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},k.prototype._verify2=function(e,t){n(0===(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},k.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},k.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},k.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},k.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},k.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},k.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},k.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},k.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},k.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},k.prototype.isqr=function(e){return this.imul(e,e.clone())},k.prototype.sqr=function(e){return this.mul(e,e)},k.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2===1),3===t){var r=this.m.add(new i(1)).iushrn(2);return this.pow(e,r)}for(var a=this.m.subn(1),o=0;!a.isZero()&&0===a.andln(1);)o++,a.iushrn(1);n(!a.isZero());var c=new i(1).toRed(this),s=c.redNeg(),f=this.m.subn(1).iushrn(1),d=this.m.bitLength();for(d=new i(2*d*d).toRed(this);0!==this.pow(d,f).cmp(s);)d.redIAdd(s);for(var u=this.pow(d,a),l=this.pow(e,a.addn(1).iushrn(1)),b=this.pow(e,a),h=o;0!==b.cmp(c);){for(var p=b,m=0;0!==p.cmp(c);m++)p=p.redSqr();n(m=0;n--){for(var f=t.words[n],d=s-1;d>=0;d--){var u=f>>d&1;a!==r[0]&&(a=this.sqr(a)),0!==u||0!==o?(o<<=1,o|=u,(4===++c||0===n&&0===d)&&(a=this.mul(a,r[o]),c=0,o=0)):c=0}s=26}return a},k.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},k.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},i.mont=function(e){return new _(e)},a(_,k),_.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},_.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},_.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),a=r.isub(n).iushrn(this.shift),i=a;return a.cmp(this.m)>=0?i=a.isub(this.m):a.cmpn(0)<0&&(i=a.iadd(this.m)),i._forceRed(this)},_.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new i(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),a=r.isub(n).iushrn(this.shift),o=a;return a.cmp(this.m)>=0?o=a.isub(this.m):a.cmpn(0)<0&&(o=a.iadd(this.m)),o._forceRed(this)},_.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e,this)}).call(this,r(74)(e))},function(e,t,r){"use strict";var n=r(93),a=r(33);function i(e,t){return 55296===(64512&e.charCodeAt(t))&&(!(t<0||t+1>=e.length)&&56320===(64512&e.charCodeAt(t+1)))}function o(e){return(e>>>24|e>>>8&65280|e<<8&16711680|(255&e)<<24)>>>0}function c(e){return 1===e.length?"0"+e:e}function s(e){return 7===e.length?"0"+e:6===e.length?"00"+e:5===e.length?"000"+e:4===e.length?"0000"+e:3===e.length?"00000"+e:2===e.length?"000000"+e:1===e.length?"0000000"+e:e}t.inherits=a,t.toArray=function(e,t){if(Array.isArray(e))return e.slice();if(!e)return[];var r=[];if("string"===typeof e)if(t){if("hex"===t)for((e=e.replace(/[^a-z0-9]+/gi,"")).length%2!==0&&(e="0"+e),a=0;a>6|192,r[n++]=63&o|128):i(e,a)?(o=65536+((1023&o)<<10)+(1023&e.charCodeAt(++a)),r[n++]=o>>18|240,r[n++]=o>>12&63|128,r[n++]=o>>6&63|128,r[n++]=63&o|128):(r[n++]=o>>12|224,r[n++]=o>>6&63|128,r[n++]=63&o|128)}else for(a=0;a>>0}return o},t.split32=function(e,t){for(var r=new Array(4*e.length),n=0,a=0;n>>24,r[a+1]=i>>>16&255,r[a+2]=i>>>8&255,r[a+3]=255&i):(r[a+3]=i>>>24,r[a+2]=i>>>16&255,r[a+1]=i>>>8&255,r[a]=255&i)}return r},t.rotr32=function(e,t){return e>>>t|e<<32-t},t.rotl32=function(e,t){return e<>>32-t},t.sum32=function(e,t){return e+t>>>0},t.sum32_3=function(e,t,r){return e+t+r>>>0},t.sum32_4=function(e,t,r,n){return e+t+r+n>>>0},t.sum32_5=function(e,t,r,n,a){return e+t+r+n+a>>>0},t.sum64=function(e,t,r,n){var a=e[t],i=n+e[t+1]>>>0,o=(i>>0,e[t+1]=i},t.sum64_hi=function(e,t,r,n){return(t+n>>>0>>0},t.sum64_lo=function(e,t,r,n){return t+n>>>0},t.sum64_4_hi=function(e,t,r,n,a,i,o,c){var s=0,f=t;return s+=(f=f+n>>>0)>>0)>>0)>>0},t.sum64_4_lo=function(e,t,r,n,a,i,o,c){return t+n+i+c>>>0},t.sum64_5_hi=function(e,t,r,n,a,i,o,c,s,f){var d=0,u=t;return d+=(u=u+n>>>0)>>0)>>0)>>0)>>0},t.sum64_5_lo=function(e,t,r,n,a,i,o,c,s,f){return t+n+i+c+f>>>0},t.rotr64_hi=function(e,t,r){return(t<<32-r|e>>>r)>>>0},t.rotr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0},t.shr64_hi=function(e,t,r){return e>>>r},t.shr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0}},function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r),Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[r]}})}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),a=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.isHexString=t.getKeys=t.fromAscii=t.fromUtf8=t.toAscii=t.arrayContainsArray=t.getBinarySize=t.padToEven=t.stripHexPrefix=t.isHexPrefixed=void 0,a(r(399),t),a(r(400),t),a(r(694),t),a(r(302),t),a(r(695),t),a(r(151),t),a(r(696),t),a(r(697),t),a(r(310),t);var i=r(167);Object.defineProperty(t,"isHexPrefixed",{enumerable:!0,get:function(){return i.isHexPrefixed}}),Object.defineProperty(t,"stripHexPrefix",{enumerable:!0,get:function(){return i.stripHexPrefix}}),Object.defineProperty(t,"padToEven",{enumerable:!0,get:function(){return i.padToEven}}),Object.defineProperty(t,"getBinarySize",{enumerable:!0,get:function(){return i.getBinarySize}}),Object.defineProperty(t,"arrayContainsArray",{enumerable:!0,get:function(){return i.arrayContainsArray}}),Object.defineProperty(t,"toAscii",{enumerable:!0,get:function(){return i.toAscii}}),Object.defineProperty(t,"fromUtf8",{enumerable:!0,get:function(){return i.fromUtf8}}),Object.defineProperty(t,"fromAscii",{enumerable:!0,get:function(){return i.fromAscii}}),Object.defineProperty(t,"getKeys",{enumerable:!0,get:function(){return i.getKeys}}),Object.defineProperty(t,"isHexString",{enumerable:!0,get:function(){return i.isHexString}})},function(e,t,r){var n=r(500),a="object"==typeof self&&self&&self.Object===Object&&self,i=n||a||Function("return this")();e.exports=i},function(e,t){e.exports=function(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,r){"use strict";r.d(t,"a",(function(){return n}));var n="abi/5.3.0"},function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r),Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[r]}})}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),a=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&n(t,e,r);return a(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.parseBytes32String=t.formatBytes32String=t.Utf8ErrorFuncs=t.toUtf8String=t.toUtf8CodePoints=t.toUtf8Bytes=t._toEscapedUtf8String=t.nameprep=t.hexDataSlice=t.hexDataLength=t.hexZeroPad=t.hexValue=t.hexStripZeros=t.hexConcat=t.isHexString=t.hexlify=t.base64=t.base58=t.TransactionDescription=t.LogDescription=t.Interface=t.SigningKey=t.HDNode=t.defaultPath=t.isBytesLike=t.isBytes=t.zeroPad=t.stripZeros=t.concat=t.arrayify=t.shallowCopy=t.resolveProperties=t.getStatic=t.defineReadOnly=t.deepCopy=t.checkProperties=t.poll=t.fetchJson=t._fetchData=t.RLP=t.Logger=t.checkResultErrors=t.FormatTypes=t.ParamType=t.FunctionFragment=t.EventFragment=t.ErrorFragment=t.Fragment=t.defaultAbiCoder=t.AbiCoder=void 0,t.Indexed=t.Utf8ErrorReason=t.UnicodeNormalizationForm=t.SupportedAlgorithm=t.mnemonicToSeed=t.isValidMnemonic=t.entropyToMnemonic=t.mnemonicToEntropy=t.getAccountPath=t.verifyTypedData=t.verifyMessage=t.recoverPublicKey=t.computePublicKey=t.recoverAddress=t.computeAddress=t.getJsonWalletAddress=t.serializeTransaction=t.parseTransaction=t.accessListify=t.joinSignature=t.splitSignature=t.soliditySha256=t.solidityKeccak256=t.solidityPack=t.shuffled=t.randomBytes=t.sha512=t.sha256=t.ripemd160=t.keccak256=t.computeHmac=t.commify=t.parseUnits=t.formatUnits=t.parseEther=t.formatEther=t.isAddress=t.getCreate2Address=t.getContractAddress=t.getIcapAddress=t.getAddress=t._TypedDataEncoder=t.id=t.isValidName=t.namehash=t.hashMessage=void 0;var o=r(352);Object.defineProperty(t,"AbiCoder",{enumerable:!0,get:function(){return o.AbiCoder}}),Object.defineProperty(t,"checkResultErrors",{enumerable:!0,get:function(){return o.checkResultErrors}}),Object.defineProperty(t,"defaultAbiCoder",{enumerable:!0,get:function(){return o.defaultAbiCoder}}),Object.defineProperty(t,"ErrorFragment",{enumerable:!0,get:function(){return o.ErrorFragment}}),Object.defineProperty(t,"EventFragment",{enumerable:!0,get:function(){return o.EventFragment}}),Object.defineProperty(t,"FormatTypes",{enumerable:!0,get:function(){return o.FormatTypes}}),Object.defineProperty(t,"Fragment",{enumerable:!0,get:function(){return o.Fragment}}),Object.defineProperty(t,"FunctionFragment",{enumerable:!0,get:function(){return o.FunctionFragment}}),Object.defineProperty(t,"Indexed",{enumerable:!0,get:function(){return o.Indexed}}),Object.defineProperty(t,"Interface",{enumerable:!0,get:function(){return o.Interface}}),Object.defineProperty(t,"LogDescription",{enumerable:!0,get:function(){return o.LogDescription}}),Object.defineProperty(t,"ParamType",{enumerable:!0,get:function(){return o.ParamType}}),Object.defineProperty(t,"TransactionDescription",{enumerable:!0,get:function(){return o.TransactionDescription}});var c=r(53);Object.defineProperty(t,"getAddress",{enumerable:!0,get:function(){return c.getAddress}}),Object.defineProperty(t,"getCreate2Address",{enumerable:!0,get:function(){return c.getCreate2Address}}),Object.defineProperty(t,"getContractAddress",{enumerable:!0,get:function(){return c.getContractAddress}}),Object.defineProperty(t,"getIcapAddress",{enumerable:!0,get:function(){return c.getIcapAddress}}),Object.defineProperty(t,"isAddress",{enumerable:!0,get:function(){return c.isAddress}});var s=i(r(249));t.base64=s;var f=r(182);Object.defineProperty(t,"base58",{enumerable:!0,get:function(){return f.Base58}});var d=r(10);Object.defineProperty(t,"arrayify",{enumerable:!0,get:function(){return d.arrayify}}),Object.defineProperty(t,"concat",{enumerable:!0,get:function(){return d.concat}}),Object.defineProperty(t,"hexConcat",{enumerable:!0,get:function(){return d.hexConcat}}),Object.defineProperty(t,"hexDataSlice",{enumerable:!0,get:function(){return d.hexDataSlice}}),Object.defineProperty(t,"hexDataLength",{enumerable:!0,get:function(){return d.hexDataLength}}),Object.defineProperty(t,"hexlify",{enumerable:!0,get:function(){return d.hexlify}}),Object.defineProperty(t,"hexStripZeros",{enumerable:!0,get:function(){return d.hexStripZeros}}),Object.defineProperty(t,"hexValue",{enumerable:!0,get:function(){return d.hexValue}}),Object.defineProperty(t,"hexZeroPad",{enumerable:!0,get:function(){return d.hexZeroPad}}),Object.defineProperty(t,"isBytes",{enumerable:!0,get:function(){return d.isBytes}}),Object.defineProperty(t,"isBytesLike",{enumerable:!0,get:function(){return d.isBytesLike}}),Object.defineProperty(t,"isHexString",{enumerable:!0,get:function(){return d.isHexString}}),Object.defineProperty(t,"joinSignature",{enumerable:!0,get:function(){return d.joinSignature}}),Object.defineProperty(t,"zeroPad",{enumerable:!0,get:function(){return d.zeroPad}}),Object.defineProperty(t,"splitSignature",{enumerable:!0,get:function(){return d.splitSignature}}),Object.defineProperty(t,"stripZeros",{enumerable:!0,get:function(){return d.stripZeros}});var u=r(209);Object.defineProperty(t,"_TypedDataEncoder",{enumerable:!0,get:function(){return u._TypedDataEncoder}}),Object.defineProperty(t,"hashMessage",{enumerable:!0,get:function(){return u.hashMessage}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return u.id}}),Object.defineProperty(t,"isValidName",{enumerable:!0,get:function(){return u.isValidName}}),Object.defineProperty(t,"namehash",{enumerable:!0,get:function(){return u.namehash}});var l=r(63);Object.defineProperty(t,"defaultPath",{enumerable:!0,get:function(){return l.defaultPath}}),Object.defineProperty(t,"entropyToMnemonic",{enumerable:!0,get:function(){return l.entropyToMnemonic}}),Object.defineProperty(t,"getAccountPath",{enumerable:!0,get:function(){return l.getAccountPath}}),Object.defineProperty(t,"HDNode",{enumerable:!0,get:function(){return l.HDNode}}),Object.defineProperty(t,"isValidMnemonic",{enumerable:!0,get:function(){return l.isValidMnemonic}}),Object.defineProperty(t,"mnemonicToEntropy",{enumerable:!0,get:function(){return l.mnemonicToEntropy}}),Object.defineProperty(t,"mnemonicToSeed",{enumerable:!0,get:function(){return l.mnemonicToSeed}});var b=r(215);Object.defineProperty(t,"getJsonWalletAddress",{enumerable:!0,get:function(){return b.getJsonWalletAddress}});var h=r(49);Object.defineProperty(t,"keccak256",{enumerable:!0,get:function(){return h.keccak256}});var p=r(16);Object.defineProperty(t,"Logger",{enumerable:!0,get:function(){return p.Logger}});var m=r(178);Object.defineProperty(t,"computeHmac",{enumerable:!0,get:function(){return m.computeHmac}}),Object.defineProperty(t,"ripemd160",{enumerable:!0,get:function(){return m.ripemd160}}),Object.defineProperty(t,"sha256",{enumerable:!0,get:function(){return m.sha256}}),Object.defineProperty(t,"sha512",{enumerable:!0,get:function(){return m.sha512}});var v=r(205);Object.defineProperty(t,"solidityKeccak256",{enumerable:!0,get:function(){return v.keccak256}}),Object.defineProperty(t,"solidityPack",{enumerable:!0,get:function(){return v.pack}}),Object.defineProperty(t,"soliditySha256",{enumerable:!0,get:function(){return v.sha256}});var g=r(353);Object.defineProperty(t,"randomBytes",{enumerable:!0,get:function(){return g.randomBytes}}),Object.defineProperty(t,"shuffled",{enumerable:!0,get:function(){return g.shuffled}});var x=r(15);Object.defineProperty(t,"checkProperties",{enumerable:!0,get:function(){return x.checkProperties}}),Object.defineProperty(t,"deepCopy",{enumerable:!0,get:function(){return x.deepCopy}}),Object.defineProperty(t,"defineReadOnly",{enumerable:!0,get:function(){return x.defineReadOnly}}),Object.defineProperty(t,"getStatic",{enumerable:!0,get:function(){return x.getStatic}}),Object.defineProperty(t,"resolveProperties",{enumerable:!0,get:function(){return x.resolveProperties}}),Object.defineProperty(t,"shallowCopy",{enumerable:!0,get:function(){return x.shallowCopy}});var y=i(r(98));t.RLP=y;var w=r(135);Object.defineProperty(t,"computePublicKey",{enumerable:!0,get:function(){return w.computePublicKey}}),Object.defineProperty(t,"recoverPublicKey",{enumerable:!0,get:function(){return w.recoverPublicKey}}),Object.defineProperty(t,"SigningKey",{enumerable:!0,get:function(){return w.SigningKey}});var k=r(95);Object.defineProperty(t,"formatBytes32String",{enumerable:!0,get:function(){return k.formatBytes32String}}),Object.defineProperty(t,"nameprep",{enumerable:!0,get:function(){return k.nameprep}}),Object.defineProperty(t,"parseBytes32String",{enumerable:!0,get:function(){return k.parseBytes32String}}),Object.defineProperty(t,"_toEscapedUtf8String",{enumerable:!0,get:function(){return k._toEscapedUtf8String}}),Object.defineProperty(t,"toUtf8Bytes",{enumerable:!0,get:function(){return k.toUtf8Bytes}}),Object.defineProperty(t,"toUtf8CodePoints",{enumerable:!0,get:function(){return k.toUtf8CodePoints}}),Object.defineProperty(t,"toUtf8String",{enumerable:!0,get:function(){return k.toUtf8String}}),Object.defineProperty(t,"Utf8ErrorFuncs",{enumerable:!0,get:function(){return k.Utf8ErrorFuncs}});var _=r(83);Object.defineProperty(t,"accessListify",{enumerable:!0,get:function(){return _.accessListify}}),Object.defineProperty(t,"computeAddress",{enumerable:!0,get:function(){return _.computeAddress}}),Object.defineProperty(t,"parseTransaction",{enumerable:!0,get:function(){return _.parse}}),Object.defineProperty(t,"recoverAddress",{enumerable:!0,get:function(){return _.recoverAddress}}),Object.defineProperty(t,"serializeTransaction",{enumerable:!0,get:function(){return _.serialize}});var M=r(124);Object.defineProperty(t,"commify",{enumerable:!0,get:function(){return M.commify}}),Object.defineProperty(t,"formatEther",{enumerable:!0,get:function(){return M.formatEther}}),Object.defineProperty(t,"parseEther",{enumerable:!0,get:function(){return M.parseEther}}),Object.defineProperty(t,"formatUnits",{enumerable:!0,get:function(){return M.formatUnits}}),Object.defineProperty(t,"parseUnits",{enumerable:!0,get:function(){return M.parseUnits}});var S=r(179);Object.defineProperty(t,"verifyMessage",{enumerable:!0,get:function(){return S.verifyMessage}}),Object.defineProperty(t,"verifyTypedData",{enumerable:!0,get:function(){return S.verifyTypedData}});var E=r(75);Object.defineProperty(t,"_fetchData",{enumerable:!0,get:function(){return E._fetchData}}),Object.defineProperty(t,"fetchJson",{enumerable:!0,get:function(){return E.fetchJson}}),Object.defineProperty(t,"poll",{enumerable:!0,get:function(){return E.poll}});var O=r(178);Object.defineProperty(t,"SupportedAlgorithm",{enumerable:!0,get:function(){return O.SupportedAlgorithm}});var A=r(95);Object.defineProperty(t,"UnicodeNormalizationForm",{enumerable:!0,get:function(){return A.UnicodeNormalizationForm}}),Object.defineProperty(t,"Utf8ErrorReason",{enumerable:!0,get:function(){return A.Utf8ErrorReason}})},function(e,t,r){"use strict";r.d(t,"a",(function(){return Ie}));var n=r(35),a=r(20),i=r(36),o=r(32),c=r(13),s=r(14),f=r(6),d=r(7),u=r(2),l=r.n(u),b=r(5),h=r(46),p=r(9),m=r(11),v=new m.a("abi/5.5.0");var g=function(){function e(t,r,n,a){Object(f.a)(this,e),this.name=t,this.type=r,this.localName=n,this.dynamic=a}return Object(d.a)(e,[{key:"_throwError",value:function(e,t){v.throwArgumentError(e,this.localName,t)}}]),e}(),x=function(){function e(t){Object(f.a)(this,e),Object(p.d)(this,"wordSize",t||32),this._data=[],this._dataLength=0,this._padding=new Uint8Array(t)}return Object(d.a)(e,[{key:"data",get:function(){return Object(b.c)(this._data)}},{key:"length",get:function(){return this._dataLength}},{key:"_writeData",value:function(e){return this._data.push(e),this._dataLength+=e.length,e.length}},{key:"appendWriter",value:function(e){return this._writeData(Object(b.b)(e._data))}},{key:"writeBytes",value:function(e){var t=Object(b.a)(e),r=t.length%this.wordSize;return r&&(t=Object(b.b)([t,this._padding.slice(r)])),this._writeData(t)}},{key:"_getValue",value:function(e){var t=Object(b.a)(h.a.from(e));return t.length>this.wordSize&&v.throwError("value out-of-bounds",m.a.errors.BUFFER_OVERRUN,{length:this.wordSize,offset:t.length}),t.length%this.wordSize&&(t=Object(b.b)([this._padding.slice(t.length%this.wordSize),t])),t}},{key:"writeValue",value:function(e){return this._writeData(this._getValue(e))}},{key:"writeUpdatableValue",value:function(){var e=this,t=this._data.length;return this._data.push(this._padding),this._dataLength+=this.wordSize,function(r){e._data[t]=e._getValue(r)}}}]),e}(),y=function(){function e(t,r,n,a){Object(f.a)(this,e),Object(p.d)(this,"_data",Object(b.a)(t)),Object(p.d)(this,"wordSize",r||32),Object(p.d)(this,"_coerceFunc",n),Object(p.d)(this,"allowLoose",a),this._offset=0}return Object(d.a)(e,[{key:"data",get:function(){return Object(b.h)(this._data)}},{key:"consumed",get:function(){return this._offset}},{key:"coerce",value:function(t,r){return this._coerceFunc?this._coerceFunc(t,r):e.coerce(t,r)}},{key:"_peekBytes",value:function(e,t,r){var n=Math.ceil(t/this.wordSize)*this.wordSize;return this._offset+n>this._data.length&&(this.allowLoose&&r&&this._offset+t<=this._data.length?n=t:v.throwError("data out-of-bounds",m.a.errors.BUFFER_OVERRUN,{length:this._data.length,offset:this._offset+n})),this._data.slice(this._offset,this._offset+n)}},{key:"subReader",value:function(t){return new e(this._data.slice(this._offset+t),this.wordSize,this._coerceFunc,this.allowLoose)}},{key:"readBytes",value:function(e,t){var r=this._peekBytes(0,e,!!t);return this._offset+=r.length,r.slice(0,e)}},{key:"readValue",value:function(){return h.a.from(this.readBytes(this.wordSize))}}],[{key:"coerce",value:function(e,t){var r=e.match("^u?int([0-9]+)$");return r&&parseInt(r[1])<=48&&(t=t.toNumber()),t}}]),e}(),w=r(38),k=r(366),_=r(40),M=function(e){Object(c.a)(r,e);var t=Object(s.a)(r);function r(e){return Object(f.a)(this,r),t.call(this,"address","address",e,!1)}return Object(d.a)(r,[{key:"defaultValue",value:function(){return"0x0000000000000000000000000000000000000000"}},{key:"encode",value:function(e,t){try{t=Object(w.a)(t)}catch(r){this._throwError(r.message,t)}return e.writeValue(t)}},{key:"decode",value:function(e){return Object(w.a)(Object(b.g)(e.readValue().toHexString(),20))}}]),r}(g),S=function(e){Object(c.a)(r,e);var t=Object(s.a)(r);function r(e){var n;return Object(f.a)(this,r),(n=t.call(this,e.name,e.type,void 0,e.dynamic)).coder=e,n}return Object(d.a)(r,[{key:"defaultValue",value:function(){return this.coder.defaultValue()}},{key:"encode",value:function(e,t){return this.coder.encode(e,t)}},{key:"decode",value:function(e){return this.coder.decode(e)}}]),r}(g),E=new m.a("abi/5.5.0");function O(e,t,r){var n=null;if(Array.isArray(r))n=r;else if(r&&"object"===typeof r){var a={};n=t.map((function(e){var t=e.localName;return t||E.throwError("cannot encode object for signature with missing names",m.a.errors.INVALID_ARGUMENT,{argument:"values",coder:e,value:r}),a[t]&&E.throwError("cannot encode object for signature with duplicate names",m.a.errors.INVALID_ARGUMENT,{argument:"values",coder:e,value:r}),a[t]=!0,r[t]}))}else E.throwArgumentError("invalid tuple value","tuple",r);t.length!==n.length&&E.throwArgumentError("types/value length mismatch","tuple",r);var i=new x(e.wordSize),o=new x(e.wordSize),c=[];t.forEach((function(e,t){var r=n[t];if(e.dynamic){var a=o.length;e.encode(o,r);var s=i.writeUpdatableValue();c.push((function(e){s(e+a)}))}else e.encode(i,r)})),c.forEach((function(e){e(i.length)}));var s=e.appendWriter(i);return s+=e.appendWriter(o)}function A(e,t){var r=[],n=e.subReader(0);t.forEach((function(t){var a=null;if(t.dynamic){var i=e.readValue(),o=n.subReader(i.toNumber());try{a=t.decode(o)}catch(c){if(c.code===m.a.errors.BUFFER_OVERRUN)throw c;(a=c).baseType=t.name,a.name=t.localName,a.type=t.type}}else try{a=t.decode(e)}catch(c){if(c.code===m.a.errors.BUFFER_OVERRUN)throw c;(a=c).baseType=t.name,a.name=t.localName,a.type=t.type}void 0!=a&&r.push(a)}));var a=t.reduce((function(e,t){var r=t.localName;return r&&(e[r]||(e[r]=0),e[r]++),e}),{});t.forEach((function(e,t){var n=e.localName;if(n&&1===a[n]&&("length"===n&&(n="_length"),null==r[n])){var i=r[t];i instanceof Error?Object.defineProperty(r,n,{enumerable:!0,get:function(){throw i}}):r[n]=i}}));for(var i=function(e){var t=r[e];t instanceof Error&&Object.defineProperty(r,e,{enumerable:!0,get:function(){throw t}})},o=0;o=0?n:"")+"]",c=-1===n||e.dynamic;return(i=t.call(this,"array",o,a,c)).coder=e,i.length=n,i}return Object(d.a)(r,[{key:"defaultValue",value:function(){for(var e=this.coder.defaultValue(),t=[],r=0;re._data.length&&E.throwError("insufficient data length",m.a.errors.BUFFER_OVERRUN,{length:e._data.length,count:t});for(var r=[],n=0;n=0||"tuple"===e)&&q[t])return!0;return(H[t]||"payable"===t)&&U.throwArgumentError("invalid modifier","name",t),!1}function V(e,t){for(var r in t)Object(p.d)(e,r,t[r])}var G=Object.freeze({sighash:"sighash",minimal:"minimal",full:"full",json:"json"}),X=new RegExp(/^(.*)\[([0-9]*)\]$/),K=function(){function e(t,r){Object(f.a)(this,e),t!==z&&U.throwError("use fromString",m.a.errors.UNSUPPORTED_OPERATION,{operation:"new ParamType()"}),V(this,r);var n=this.type.match(X);V(this,n?{arrayLength:parseInt(n[2]||"-1"),arrayChildren:e.fromObject({type:n[1],components:this.components}),baseType:"array"}:{arrayLength:null,arrayChildren:null,baseType:null!=this.components?"tuple":this.type}),this._isParamType=!0,Object.freeze(this)}return Object(d.a)(e,[{key:"format",value:function(e){if(e||(e=G.sighash),G[e]||U.throwArgumentError("invalid format type","format",e),e===G.json){var t={type:"tuple"===this.baseType?"tuple":this.type,name:this.name||void 0};return"boolean"===typeof this.indexed&&(t.indexed=this.indexed),this.components&&(t.components=this.components.map((function(t){return JSON.parse(t.format(e))}))),JSON.stringify(t)}var r="";return"array"===this.baseType?(r+=this.arrayChildren.format(e),r+="["+(this.arrayLength<0?"":String(this.arrayLength))+"]"):"tuple"===this.baseType?(e!==G.sighash&&(r+=this.type),r+="("+this.components.map((function(t){return t.format(e)})).join(e===G.full?", ":",")+")"):r+=this.type,e!==G.sighash&&(!0===this.indexed&&(r+=" indexed"),e===G.full&&this.name&&(r+=" "+this.name)),r}}],[{key:"from",value:function(t,r){return"string"===typeof t?e.fromString(t,r):e.fromObject(t)}},{key:"fromObject",value:function(t){return e.isParamType(t)?t:new e(z,{name:t.name||null,type:ie(t.type),indexed:null==t.indexed?null:!!t.indexed,components:t.components?t.components.map(e.fromObject):null})}},{key:"fromString",value:function(t,r){return function(t){return e.fromObject({name:t.name,type:t.type,indexed:t.indexed,components:t.components})}(function(e,t){var r=e;function n(t){U.throwArgumentError("unexpected character at position ".concat(t),"param",e)}function a(e){var r={type:"",name:"",parent:e,state:{allowType:!0}};return t&&(r.indexed=!1),r}e=e.replace(/\s/g," ");for(var i={type:"",name:"",state:{allowType:!0}},o=i,c=0;c2&&U.throwArgumentError("invalid human-readable ABI signature","value",e),r[1].match(/^[0-9]+$/)||U.throwArgumentError("invalid human-readable ABI signature gas","value",e),t.gas=h.a.from(r[1]),r[0]):e}function Y(e,t){t.constant=!1,t.payable=!1,t.stateMutability="nonpayable",e.split(" ").forEach((function(e){switch(e.trim()){case"constant":t.constant=!0;break;case"payable":t.payable=!0,t.stateMutability="payable";break;case"nonpayable":t.payable=!1,t.stateMutability="nonpayable";break;case"pure":t.constant=!0,t.stateMutability="pure";break;case"view":t.constant=!0,t.stateMutability="view";break;case"external":case"public":case"":break;default:console.log("unknown modifier: "+e)}}))}function ee(e){var t={constant:!1,payable:!0,stateMutability:"payable"};return null!=e.stateMutability?(t.stateMutability=e.stateMutability,t.constant="view"===t.stateMutability||"pure"===t.stateMutability,null!=e.constant&&!!e.constant!==t.constant&&U.throwArgumentError("cannot have constant function with mutability "+t.stateMutability,"value",e),t.payable="payable"===t.stateMutability,null!=e.payable&&!!e.payable!==t.payable&&U.throwArgumentError("cannot have payable function with mutability "+t.stateMutability,"value",e)):null!=e.payable?(t.payable=!!e.payable,null!=e.constant||t.payable||"constructor"===e.type||U.throwArgumentError("unable to determine stateMutability","value",e),t.constant=!!e.constant,t.constant?t.stateMutability="view":t.stateMutability=t.payable?"payable":"nonpayable",t.payable&&t.constant&&U.throwArgumentError("cannot have constant payable function","value",e)):null!=e.constant?(t.constant=!!e.constant,t.payable=!t.constant,t.stateMutability=t.constant?"view":"payable"):"constructor"!==e.type&&U.throwArgumentError("unable to determine stateMutability","value",e),t}var te=function(e){Object(c.a)(r,e);var t=Object(s.a)(r);function r(){return Object(f.a)(this,r),t.apply(this,arguments)}return Object(d.a)(r,[{key:"format",value:function(e){if(e||(e=G.sighash),G[e]||U.throwArgumentError("invalid format type","format",e),e===G.json)return JSON.stringify({type:"constructor",stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map((function(t){return JSON.parse(t.format(e))}))});e===G.sighash&&U.throwError("cannot format a constructor for sighash",m.a.errors.UNSUPPORTED_OPERATION,{operation:"format(sighash)"});var t="constructor("+this.inputs.map((function(t){return t.format(e)})).join(e===G.full?", ":",")+") ";return this.stateMutability&&"nonpayable"!==this.stateMutability&&(t+=this.stateMutability+" "),t.trim()}}],[{key:"from",value:function(e){return"string"===typeof e?r.fromString(e):r.fromObject(e)}},{key:"fromObject",value:function(e){if(r.isConstructorFragment(e))return e;"constructor"!==e.type&&U.throwArgumentError("invalid constructor object","value",e);var t=ee(e);t.constant&&U.throwArgumentError("constructor cannot be constant","value",e);var n={name:null,type:e.type,inputs:e.inputs?e.inputs.map(K.fromObject):[],payable:t.payable,stateMutability:t.stateMutability,gas:e.gas?h.a.from(e.gas):null};return new r(z,n)}},{key:"fromString",value:function(e){var t={type:"constructor"},n=(e=Q(e,t)).match(se);return n&&"constructor"===n[1].trim()||U.throwArgumentError("invalid constructor string","value",e),t.inputs=W(n[2].trim(),!1),Y(n[3].trim(),t),r.fromObject(t)}},{key:"isConstructorFragment",value:function(e){return e&&e._isFragment&&"constructor"===e.type}}]),r}(Z),re=function(e){Object(c.a)(r,e);var t=Object(s.a)(r);function r(){return Object(f.a)(this,r),t.apply(this,arguments)}return Object(d.a)(r,[{key:"format",value:function(e){if(e||(e=G.sighash),G[e]||U.throwArgumentError("invalid format type","format",e),e===G.json)return JSON.stringify({type:"function",name:this.name,constant:this.constant,stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map((function(t){return JSON.parse(t.format(e))})),outputs:this.outputs.map((function(t){return JSON.parse(t.format(e))}))});var t="";return e!==G.sighash&&(t+="function "),t+=this.name+"("+this.inputs.map((function(t){return t.format(e)})).join(e===G.full?", ":",")+") ",e!==G.sighash&&(this.stateMutability?"nonpayable"!==this.stateMutability&&(t+=this.stateMutability+" "):this.constant&&(t+="view "),this.outputs&&this.outputs.length&&(t+="returns ("+this.outputs.map((function(t){return t.format(e)})).join(", ")+") "),null!=this.gas&&(t+="@"+this.gas.toString()+" ")),t.trim()}}],[{key:"from",value:function(e){return"string"===typeof e?r.fromString(e):r.fromObject(e)}},{key:"fromObject",value:function(e){if(r.isFunctionFragment(e))return e;"function"!==e.type&&U.throwArgumentError("invalid function object","value",e);var t=ee(e),n={type:e.type,name:ce(e.name),constant:t.constant,inputs:e.inputs?e.inputs.map(K.fromObject):[],outputs:e.outputs?e.outputs.map(K.fromObject):[],payable:t.payable,stateMutability:t.stateMutability,gas:e.gas?h.a.from(e.gas):null};return new r(z,n)}},{key:"fromString",value:function(e){var t={type:"function"},n=(e=Q(e,t)).split(" returns ");n.length>2&&U.throwArgumentError("invalid function string","value",e);var a=n[0].match(se);if(a||U.throwArgumentError("invalid function signature","value",e),t.name=a[1].trim(),t.name&&ce(t.name),t.inputs=W(a[2],!1),Y(a[3].trim(),t),n.length>1){var i=n[1].match(se);""==i[1].trim()&&""==i[3].trim()||U.throwArgumentError("unexpected tokens","value",e),t.outputs=W(i[2],!1)}else t.outputs=[];return r.fromObject(t)}},{key:"isFunctionFragment",value:function(e){return e&&e._isFragment&&"function"===e.type}}]),r}(te);function ne(e){var t=e.format();return"Error(string)"!==t&&"Panic(uint256)"!==t||U.throwArgumentError("cannot specify user defined ".concat(t," error"),"fragment",e),e}var ae=function(e){Object(c.a)(r,e);var t=Object(s.a)(r);function r(){return Object(f.a)(this,r),t.apply(this,arguments)}return Object(d.a)(r,[{key:"format",value:function(e){if(e||(e=G.sighash),G[e]||U.throwArgumentError("invalid format type","format",e),e===G.json)return JSON.stringify({type:"error",name:this.name,inputs:this.inputs.map((function(t){return JSON.parse(t.format(e))}))});var t="";return e!==G.sighash&&(t+="error "),(t+=this.name+"("+this.inputs.map((function(t){return t.format(e)})).join(e===G.full?", ":",")+") ").trim()}}],[{key:"from",value:function(e){return"string"===typeof e?r.fromString(e):r.fromObject(e)}},{key:"fromObject",value:function(e){if(r.isErrorFragment(e))return e;"error"!==e.type&&U.throwArgumentError("invalid error object","value",e);var t={type:e.type,name:ce(e.name),inputs:e.inputs?e.inputs.map(K.fromObject):[]};return ne(new r(z,t))}},{key:"fromString",value:function(e){var t={type:"error"},n=e.match(se);return n||U.throwArgumentError("invalid error signature","value",e),t.name=n[1].trim(),t.name&&ce(t.name),t.inputs=W(n[2],!1),ne(r.fromObject(t))}},{key:"isErrorFragment",value:function(e){return e&&e._isFragment&&"error"===e.type}}]),r}(Z);function ie(e){return e.match(/^uint($|[^1-9])/)?e="uint256"+e.substring(4):e.match(/^int($|[^1-9])/)&&(e="int256"+e.substring(3)),e}var oe=new RegExp("^[a-zA-Z$_][a-zA-Z0-9$_]*$");function ce(e){return e&&e.match(oe)||U.throwArgumentError('invalid identifier "'.concat(e,'"'),"value",e),e}var se=new RegExp("^([^)(]*)\\((.*)\\)([^)(]*)$");var fe=new m.a("abi/5.5.0"),de=new RegExp(/^bytes([0-9]*)$/),ue=new RegExp(/^(u?int)([0-9]*)$/),le=new(function(){function e(t){Object(f.a)(this,e),fe.checkNew(this instanceof e?this.constructor:void 0,e),Object(p.d)(this,"coerceFunc",t||null)}return Object(d.a)(e,[{key:"_getCoder",value:function(e){var t=this;switch(e.baseType){case"address":return new M(e.name);case"bool":return new j(e.name);case"string":return new F(e.name);case"bytes":return new C(e.name);case"array":return new T(this._getCoder(e.arrayChildren),e.arrayLength,e.name);case"tuple":return new D((e.components||[]).map((function(e){return t._getCoder(e)})),e.name);case"":return new N(e.name)}var r=e.type.match(ue);if(r){var n=parseInt(r[2]||"256");return(0===n||n>256||n%8!==0)&&fe.throwArgumentError("invalid "+r[1]+" bit length","param",e),new L(n/8,"int"===r[1],e.name)}if(r=e.type.match(de)){var a=parseInt(r[1]);return(0===a||a>32)&&fe.throwArgumentError("invalid bytes length","param",e),new R(a,e.name)}return fe.throwArgumentError("invalid type","type",e.type)}},{key:"_getWordSize",value:function(){return 32}},{key:"_getReader",value:function(e,t){return new y(e,this._getWordSize(),this.coerceFunc,t)}},{key:"_getWriter",value:function(){return new x(this._getWordSize())}},{key:"getDefaultValue",value:function(e){var t=this,r=e.map((function(e){return t._getCoder(K.from(e))}));return new D(r,"_").defaultValue()}},{key:"encode",value:function(e,t){var r=this;e.length!==t.length&&fe.throwError("types/values length mismatch",m.a.errors.INVALID_ARGUMENT,{count:{types:e.length,values:t.length},value:{types:e,values:t}});var n=e.map((function(e){return r._getCoder(K.from(e))})),a=new D(n,"_"),i=this._getWriter();return a.encode(i,t),i.data}},{key:"decode",value:function(e,t,r){var n=this,a=e.map((function(e){return n._getCoder(K.from(e))}));return new D(a,"_").decode(this._getReader(Object(b.a)(t),r))}}]),e}()),be=new m.a("abi/5.5.0"),he=function(e){Object(c.a)(r,e);var t=Object(s.a)(r);function r(){return Object(f.a)(this,r),t.apply(this,arguments)}return Object(d.a)(r)}(p.a),pe=function(e){Object(c.a)(r,e);var t=Object(s.a)(r);function r(){return Object(f.a)(this,r),t.apply(this,arguments)}return Object(d.a)(r)}(p.a),me=function(e){Object(c.a)(r,e);var t=Object(s.a)(r);function r(){return Object(f.a)(this,r),t.apply(this,arguments)}return Object(d.a)(r)}(p.a),ve=function(e){Object(c.a)(r,e);var t=Object(s.a)(r);function r(){return Object(f.a)(this,r),t.apply(this,arguments)}return Object(d.a)(r,null,[{key:"isIndexed",value:function(e){return!(!e||!e._isIndexed)}}]),r}(p.a),ge={"0x08c379a0":{signature:"Error(string)",name:"Error",inputs:["string"],reason:!0},"0x4e487b71":{signature:"Panic(uint256)",name:"Panic",inputs:["uint256"]}};function xe(e,t){var r=new Error("deferred error during ABI decoding triggered accessing ".concat(e));return r.error=t,r}var ye=function(){function e(t){var r=this;Object(f.a)(this,e),be.checkNew(this instanceof e?this.constructor:void 0,e);var n=[];n="string"===typeof t?JSON.parse(t):t,Object(p.d)(this,"fragments",n.map((function(e){return Z.from(e)})).filter((function(e){return null!=e}))),Object(p.d)(this,"_abiCoder",Object(p.e)(this instanceof e?this.constructor:void 0,"getAbiCoder")()),Object(p.d)(this,"functions",{}),Object(p.d)(this,"errors",{}),Object(p.d)(this,"events",{}),Object(p.d)(this,"structs",{}),this.fragments.forEach((function(e){var t=null;switch(e.type){case"constructor":return r.deploy?void be.warn("duplicate definition - constructor"):void Object(p.d)(r,"deploy",e);case"function":t=r.functions;break;case"event":t=r.events;break;case"error":t=r.errors;break;default:return}var n=e.format();t[n]?be.warn("duplicate definition - "+n):t[n]=e})),this.deploy||Object(p.d)(this,"deploy",te.from({payable:!1,type:"constructor"})),Object(p.d)(this,"_isInterface",!0)}return Object(d.a)(e,[{key:"format",value:function(e){e||(e=G.full),e===G.sighash&&be.throwArgumentError("interface does not support formatting sighash","format",e);var t=this.fragments.map((function(t){return t.format(e)}));return e===G.json?JSON.stringify(t.map((function(e){return JSON.parse(e)}))):t}},{key:"getFunction",value:function(e){if(Object(b.k)(e)){for(var t in this.functions)if(e===this.getSighash(t))return this.functions[t];be.throwArgumentError("no matching function","sighash",e)}if(-1===e.indexOf("(")){var r=e.trim(),n=Object.keys(this.functions).filter((function(e){return e.split("(")[0]===r}));return 0===n.length?be.throwArgumentError("no matching function","name",r):n.length>1&&be.throwArgumentError("multiple matching functions","name",r),this.functions[n[0]]}var a=this.functions[re.fromString(e).format()];return a||be.throwArgumentError("no matching function","signature",e),a}},{key:"getEvent",value:function(e){if(Object(b.k)(e)){var t=e.toLowerCase();for(var r in this.events)if(t===this.getEventTopic(r))return this.events[r];be.throwArgumentError("no matching event","topichash",t)}if(-1===e.indexOf("(")){var n=e.trim(),a=Object.keys(this.events).filter((function(e){return e.split("(")[0]===n}));return 0===a.length?be.throwArgumentError("no matching event","name",n):a.length>1&&be.throwArgumentError("multiple matching events","name",n),this.events[a[0]]}var i=this.events[$.fromString(e).format()];return i||be.throwArgumentError("no matching event","signature",e),i}},{key:"getError",value:function(e){if(Object(b.k)(e)){var t=Object(p.e)(this.constructor,"getSighash");for(var r in this.errors){if(e===t(this.errors[r]))return this.errors[r]}be.throwArgumentError("no matching error","sighash",e)}if(-1===e.indexOf("(")){var n=e.trim(),a=Object.keys(this.errors).filter((function(e){return e.split("(")[0]===n}));return 0===a.length?be.throwArgumentError("no matching error","name",n):a.length>1&&be.throwArgumentError("multiple matching errors","name",n),this.errors[a[0]]}var i=this.errors[re.fromString(e).format()];return i||be.throwArgumentError("no matching error","signature",e),i}},{key:"getSighash",value:function(e){if("string"===typeof e)try{e=this.getFunction(e)}catch(t){try{e=this.getError(e)}catch(r){throw t}}return Object(p.e)(this.constructor,"getSighash")(e)}},{key:"getEventTopic",value:function(e){return"string"===typeof e&&(e=this.getEvent(e)),Object(p.e)(this.constructor,"getEventTopic")(e)}},{key:"_decodeParams",value:function(e,t){return this._abiCoder.decode(e,t)}},{key:"_encodeParams",value:function(e,t){return this._abiCoder.encode(e,t)}},{key:"encodeDeploy",value:function(e){return this._encodeParams(this.deploy.inputs,e||[])}},{key:"decodeErrorResult",value:function(e,t){"string"===typeof e&&(e=this.getError(e));var r=Object(b.a)(t);return Object(b.h)(r.slice(0,4))!==this.getSighash(e)&&be.throwArgumentError("data signature does not match error ".concat(e.name,"."),"data",Object(b.h)(r)),this._decodeParams(e.inputs,r.slice(4))}},{key:"encodeErrorResult",value:function(e,t){return"string"===typeof e&&(e=this.getError(e)),Object(b.h)(Object(b.b)([this.getSighash(e),this._encodeParams(e.inputs,t||[])]))}},{key:"decodeFunctionData",value:function(e,t){"string"===typeof e&&(e=this.getFunction(e));var r=Object(b.a)(t);return Object(b.h)(r.slice(0,4))!==this.getSighash(e)&&be.throwArgumentError("data signature does not match function ".concat(e.name,"."),"data",Object(b.h)(r)),this._decodeParams(e.inputs,r.slice(4))}},{key:"encodeFunctionData",value:function(e,t){return"string"===typeof e&&(e=this.getFunction(e)),Object(b.h)(Object(b.b)([this.getSighash(e),this._encodeParams(e.inputs,t||[])]))}},{key:"decodeFunctionResult",value:function(e,t){"string"===typeof e&&(e=this.getFunction(e));var r=Object(b.a)(t),n=null,a=null,i=null,o=null;switch(r.length%this._abiCoder._getWordSize()){case 0:try{return this._abiCoder.decode(e.outputs,r)}catch(f){}break;case 4:var c=Object(b.h)(r.slice(0,4)),s=ge[c];if(s)a=this._abiCoder.decode(s.inputs,r.slice(4)),i=s.name,o=s.signature,s.reason&&(n=a[0]);else try{var f=this.getError(c);a=this._abiCoder.decode(f.inputs,r.slice(4)),i=f.name,o=f.format()}catch(f){console.log(f)}}return be.throwError("call revert exception",m.a.errors.CALL_EXCEPTION,{method:e.format(),errorArgs:a,errorName:i,errorSignature:o,reason:n})}},{key:"encodeFunctionResult",value:function(e,t){return"string"===typeof e&&(e=this.getFunction(e)),Object(b.h)(this._abiCoder.encode(e.outputs,t||[]))}},{key:"encodeFilterTopics",value:function(e,t){var r=this;"string"===typeof e&&(e=this.getEvent(e)),t.length>e.inputs.length&&be.throwError("too many arguments for "+e.format(),m.a.errors.UNEXPECTED_ARGUMENT,{argument:"values",value:t});var n=[];e.anonymous||n.push(this.getEventTopic(e));var a=function(e,t){return"string"===e.type?Object(k.a)(t):"bytes"===e.type?Object(_.a)(Object(b.h)(t)):("address"===e.type&&r._abiCoder.encode(["address"],[t]),Object(b.g)(Object(b.h)(t),32))};for(t.forEach((function(t,r){var i=e.inputs[r];i.indexed?null==t?n.push(null):"array"===i.baseType||"tuple"===i.baseType?be.throwArgumentError("filtering with tuples or arrays not supported","contract."+i.name,t):Array.isArray(t)?n.push(t.map((function(e){return a(i,e)}))):n.push(a(i,t)):null!=t&&be.throwArgumentError("cannot filter non-indexed parameters; must be null","contract."+i.name,t)}));n.length&&null===n[n.length-1];)n.pop();return n}},{key:"encodeEventLog",value:function(e,t){var r=this;"string"===typeof e&&(e=this.getEvent(e));var n=[],a=[],i=[];return e.anonymous||n.push(this.getEventTopic(e)),t.length!==e.inputs.length&&be.throwArgumentError("event arguments/values mismatch","values",t),e.inputs.forEach((function(e,o){var c=t[o];if(e.indexed)if("string"===e.type)n.push(Object(k.a)(c));else if("bytes"===e.type)n.push(Object(_.a)(c));else{if("tuple"===e.baseType||"array"===e.baseType)throw new Error("not implemented");n.push(r._abiCoder.encode([e.type],[c]))}else a.push(e),i.push(c)})),{data:this._abiCoder.encode(a,i),topics:n}}},{key:"decodeEventLog",value:function(e,t,r){if("string"===typeof e&&(e=this.getEvent(e)),null!=r&&!e.anonymous){var n=this.getEventTopic(e);Object(b.k)(r[0],32)&&r[0].toLowerCase()===n||be.throwError("fragment/topic mismatch",m.a.errors.INVALID_ARGUMENT,{argument:"topics[0]",expected:n,value:r[0]}),r=r.slice(1)}var a=[],i=[],o=[];e.inputs.forEach((function(e,t){e.indexed?"string"===e.type||"bytes"===e.type||"tuple"===e.baseType||"array"===e.baseType?(a.push(K.fromObject({type:"bytes32",name:e.name})),o.push(!0)):(a.push(e),o.push(!1)):(i.push(e),o.push(!1))}));var c=null!=r?this._abiCoder.decode(a,Object(b.b)(r)):null,s=this._abiCoder.decode(i,t,!0),f=[],d=0,u=0;e.inputs.forEach((function(e,t){if(e.indexed)if(null==c)f[t]=new ve({_isIndexed:!0,hash:null});else if(o[t])f[t]=new ve({_isIndexed:!0,hash:c[u++]});else try{f[t]=c[u++]}catch(n){f[t]=n}else try{f[t]=s[d++]}catch(n){f[t]=n}if(e.name&&null==f[e.name]){var r=f[t];r instanceof Error?Object.defineProperty(f,e.name,{enumerable:!0,get:function(){throw xe("property ".concat(JSON.stringify(e.name)),r)}}):f[e.name]=r}}));for(var l=function(e){var t=f[e];t instanceof Error&&Object.defineProperty(f,e,{enumerable:!0,get:function(){throw xe("index ".concat(e),t)}})},h=0;h1)){e=e.substring(1);var r=t[0];try{null==a[e]&&Object(p.d)(a,e,a[r])}catch(n){}null==a.functions[e]&&Object(p.d)(a.functions,e,a.functions[r]),null==a.callStatic[e]&&Object(p.d)(a.callStatic,e,a.callStatic[r]),null==a.populateTransaction[e]&&Object(p.d)(a.populateTransaction,e,a.populateTransaction[r]),null==a.estimateGas[e]&&Object(p.d)(a.estimateGas,e,a.estimateGas[r])}}))}return Object(d.a)(e,[{key:"deployed",value:function(){return this._deployed()}},{key:"_deployed",value:function(e){var t=this;return this._deployedPromise||(this.deployTransaction?this._deployedPromise=this.deployTransaction.wait().then((function(){return t})):this._deployedPromise=this.provider.getCode(this.address,e).then((function(e){return"0x"===e&&Se.throwError("contract not deployed",m.a.errors.UNSUPPORTED_OPERATION,{contractAddress:t.address,operation:"getDeployed"}),t}))),this._deployedPromise}},{key:"fallback",value:function(e){var t=this;this.signer||Se.throwError("sending a transactions require a signer",m.a.errors.UNSUPPORTED_OPERATION,{operation:"sendTransaction(fallback)"});var r=Object(p.g)(e||{});return["from","to"].forEach((function(e){null!=r[e]&&Se.throwError("cannot override "+e,m.a.errors.UNSUPPORTED_OPERATION,{operation:e})})),r.to=this.resolvedAddress,this.deployed().then((function(){return t.signer.sendTransaction(r)}))}},{key:"connect",value:function(e){"string"===typeof e&&(e=new ke.b(e,this.provider));var t=new this.constructor(this.address,this.interface,e);return this.deployTransaction&&Object(p.d)(t,"deployTransaction",this.deployTransaction),t}},{key:"attach",value:function(e){return new this.constructor(e,this.interface,this.signer||this.provider)}},{key:"_normalizeRunningEvent",value:function(e){return this._runningEvents[e.tag]?this._runningEvents[e.tag]:e}},{key:"_getRunningEvent",value:function(e){if("string"===typeof e){if("error"===e)return this._normalizeRunningEvent(new Ne);if("event"===e)return this._normalizeRunningEvent(new Re("event",null));if("*"===e)return this._normalizeRunningEvent(new Le(this.address,this.interface));var t=this.interface.getEvent(e);return this._normalizeRunningEvent(new Be(this.address,this.interface,t))}if(e.topics&&e.topics.length>0){try{var r=e.topics[0];if("string"!==typeof r)throw new Error("invalid topic");var n=this.interface.getEvent(r);return this._normalizeRunningEvent(new Be(this.address,this.interface,n,e.topics))}catch(i){}var a={address:this.address,topics:e.topics};return this._normalizeRunningEvent(new Re(Ce(a),a))}return this._normalizeRunningEvent(new Le(this.address,this.interface))}},{key:"_checkRunningEvents",value:function(e){if(0===e.listenerCount()){delete this._runningEvents[e.tag];var t=this._wrappedEmits[e.tag];t&&e.filter&&(this.provider.off(e.filter,t),delete this._wrappedEmits[e.tag])}}},{key:"_wrapEvent",value:function(e,t,r){var n=this,a=Object(p.c)(t);return a.removeListener=function(){r&&(e.removeListener(r),n._checkRunningEvents(e))},a.getBlock=function(){return n.provider.getBlock(t.blockHash)},a.getTransaction=function(){return n.provider.getTransaction(t.transactionHash)},a.getTransactionReceipt=function(){return n.provider.getTransactionReceipt(t.transactionHash)},e.prepareEvent(a),a}},{key:"_addEventListener",value:function(e,t,r){var a=this;if(this.provider||Se.throwError("events require a provider or a signer with a provider",m.a.errors.UNSUPPORTED_OPERATION,{operation:"once"}),e.addListener(t,r),this._runningEvents[e.tag]=e,!this._wrappedEmits[e.tag]){var i=function(r){var i=a._wrapEvent(e,r,t);if(null==i.decodeError)try{var o=e.getEmit(i);a.emit.apply(a,[e.filter].concat(Object(n.a)(o)))}catch(c){i.decodeError=c.error}null!=e.filter&&a.emit("event",i),null!=i.decodeError&&a.emit("error",i.decodeError,i)};this._wrappedEmits[e.tag]=i,null!=e.filter&&this.provider.on(e.filter,i)}}},{key:"queryFilter",value:function(e,t,r){var n=this,a=this._getRunningEvent(e),i=Object(p.g)(a.filter);return"string"===typeof t&&Object(b.k)(t,32)?(null!=r&&Se.throwArgumentError("cannot specify toBlock with blockhash","toBlock",r),i.blockHash=t):(i.fromBlock=null!=t?t:0,i.toBlock=null!=r?r:"latest"),this.provider.getLogs(i).then((function(e){return e.map((function(e){return n._wrapEvent(a,e,null)}))}))}},{key:"on",value:function(e,t){return this._addEventListener(this._getRunningEvent(e),t,!1),this}},{key:"once",value:function(e,t){return this._addEventListener(this._getRunningEvent(e),t,!0),this}},{key:"emit",value:function(e){if(!this.provider)return!1;for(var t=this._getRunningEvent(e),r=arguments.length,n=new Array(r>1?r-1:0),a=1;a0;return this._checkRunningEvents(t),i}},{key:"listenerCount",value:function(e){var t=this;return this.provider?null==e?Object.keys(this._runningEvents).reduce((function(e,r){return e+t._runningEvents[r].listenerCount()}),0):this._getRunningEvent(e).listenerCount():0}},{key:"listeners",value:function(e){var t=this;if(!this.provider)return[];if(null==e){var r=function(){var e=[];for(var r in t._runningEvents)t._runningEvents[r].listeners().forEach((function(t){e.push(t)}));return{v:e}}();if("object"===typeof r)return r.v}return this._getRunningEvent(e).listeners()}},{key:"removeAllListeners",value:function(e){if(!this.provider)return this;if(null==e){for(var t in this._runningEvents){var r=this._runningEvents[t];r.removeAllListeners(),this._checkRunningEvents(r)}return this}var n=this._getRunningEvent(e);return n.removeAllListeners(),this._checkRunningEvents(n),this}},{key:"off",value:function(e,t){if(!this.provider)return this;var r=this._getRunningEvent(e);return r.removeListener(t),this._checkRunningEvents(r),this}},{key:"removeListener",value:function(e,t){return this.off(e,t)}}],[{key:"getContractAddress",value:function(e){return Object(w.b)(e)}},{key:"getInterface",value:function(e){return ye.isInterface(e)?e:new ye(e)}},{key:"isIndexed",value:function(e){return ve.isIndexed(e)}}]),e}())},function(e,t,r){"use strict";r.d(t,"a",(function(){return u})),r.d(t,"c",(function(){return l})),r.d(t,"b",(function(){return b}));var n=r(6),a=r(7),i=r(538),o=r(5),c=r(9),s=new(r(11).a)("signing-key/5.5.0"),f=null;function d(){return f||(f=new i.a("secp256k1")),f}var u=function(){function e(t){Object(n.a)(this,e),Object(c.d)(this,"curve","secp256k1"),Object(c.d)(this,"privateKey",Object(o.h)(t));var r=d().keyFromPrivate(Object(o.a)(this.privateKey));Object(c.d)(this,"publicKey","0x"+r.getPublic(!1,"hex")),Object(c.d)(this,"compressedPublicKey","0x"+r.getPublic(!0,"hex")),Object(c.d)(this,"_isSigningKey",!0)}return Object(a.a)(e,[{key:"_addPoint",value:function(e){var t=d().keyFromPublic(Object(o.a)(this.publicKey)),r=d().keyFromPublic(Object(o.a)(e));return"0x"+t.pub.add(r.pub).encodeCompressed("hex")}},{key:"signDigest",value:function(e){var t=d().keyFromPrivate(Object(o.a)(this.privateKey)),r=Object(o.a)(e);32!==r.length&&s.throwArgumentError("bad digest length","digest",e);var n=t.sign(r,{canonical:!0});return Object(o.m)({recoveryParam:n.recoveryParam,r:Object(o.g)("0x"+n.r.toString(16),32),s:Object(o.g)("0x"+n.s.toString(16),32)})}},{key:"computeSharedSecret",value:function(e){var t=d().keyFromPrivate(Object(o.a)(this.privateKey)),r=d().keyFromPublic(Object(o.a)(b(e)));return Object(o.g)("0x"+t.derive(r.getPublic()).toString(16),32)}}],[{key:"isSigningKey",value:function(e){return!(!e||!e._isSigningKey)}}]),e}();function l(e,t){var r=Object(o.m)(t),n={r:Object(o.a)(r.r),s:Object(o.a)(r.s)};return"0x"+d().recoverPubKey(Object(o.a)(e),n,r.recoveryParam).encode("hex",!1)}function b(e,t){var r=Object(o.a)(e);if(32===r.length){var n=new u(r);return t?"0x"+d().keyFromPrivate(r).getPublic(!0,"hex"):n.publicKey}return 33===r.length?t?Object(o.h)(r):"0x"+d().keyFromPublic(r).getPublic(!1,"hex"):65===r.length?t?"0x"+d().keyFromPublic(r).getPublic(!0,"hex"):Object(o.h)(r):s.throwArgumentError("invalid public or private key","key","[REDACTED]")}},function(e,t,r){var n;!function(a){"use strict";var i,o=/^-?(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?$/i,c=Math.ceil,s=Math.floor,f="[BigNumber Error] ",d=f+"Number primitive has more than 15 significant digits: ",u=1e14,l=[1,10,100,1e3,1e4,1e5,1e6,1e7,1e8,1e9,1e10,1e11,1e12,1e13],b=1e9;function h(e){var t=0|e;return e>0||e===t?t:t-1}function p(e){for(var t,r,n=1,a=e.length,i=e[0]+"";nf^r?1:-1;for(c=(s=a.length)<(f=i.length)?s:f,o=0;oi[o]^r?1:-1;return s==f?0:s>f^r?1:-1}function v(e,t,r,n){if(er||e!==s(e))throw Error(f+(n||"Argument")+("number"==typeof e?er?" out of range: ":" not an integer: ":" not a primitive number: ")+String(e))}function g(e){var t=e.c.length-1;return h(e.e/14)==t&&e.c[t]%2!=0}function x(e,t){return(e.length>1?e.charAt(0)+"."+e.slice(1):e)+(t<0?"e":"e+")+t}function y(e,t,r){var n,a;if(t<0){for(a=r+".";++t;a+=r);e=a+e}else if(++t>(n=e.length)){for(a=r,t-=n;--t;a+=r);e+=a}else tO?p.c=p.e=null:e.e=10;u/=10,f++);return void(f>O?p.c=p.e=null:(p.e=f,p.c=[e]))}h=String(e)}else{if(!o.test(h=String(e)))return a(p,h,l);p.s=45==h.charCodeAt(0)?(h=h.slice(1),-1):1}(f=h.indexOf("."))>-1&&(h=h.replace(".","")),(u=h.search(/e/i))>0?(f<0&&(f=u),f+=+h.slice(u+1),h=h.substring(0,u)):f<0&&(f=h.length)}else{if(v(t,2,C.length,"Base"),10==t&&R)return F(p=new N(e),k+p.e+1,_);if(h=String(e),l="number"==typeof e){if(0*e!=0)return a(p,h,l,t);if(p.s=1/e<0?(h=h.slice(1),-1):1,N.DEBUG&&h.replace(/^0\.0*|\./,"").length>15)throw Error(d+e)}else p.s=45===h.charCodeAt(0)?(h=h.slice(1),-1):1;for(r=C.slice(0,t),f=u=0,b=h.length;uf){f=b;continue}}else if(!c&&(h==h.toUpperCase()&&(h=h.toLowerCase())||h==h.toLowerCase()&&(h=h.toUpperCase()))){c=!0,u=-1,f=0;continue}return a(p,String(e),l,t)}l=!1,(f=(h=n(h,t,10,p.s)).indexOf("."))>-1?h=h.replace(".",""):f=h.length}for(u=0;48===h.charCodeAt(u);u++);for(b=h.length;48===h.charCodeAt(--b););if(h=h.slice(u,++b)){if(b-=u,l&&N.DEBUG&&b>15&&(e>9007199254740991||e!==s(e)))throw Error(d+p.s*e);if((f=f-u-1)>O)p.c=p.e=null;else if(f=S)?x(s,o):y(s,o,"0");else if(i=(e=F(new N(e),t,r)).e,c=(s=p(e.c)).length,1==n||2==n&&(t<=i||i<=M)){for(;cc){if(--t>0)for(s+=".";t--;s+="0");}else if((t+=i-c)>0)for(i+1==c&&(s+=".");t--;s+="0");return e.s<0&&a?"-"+s:s}function L(e,t){for(var r,n=1,a=new N(e[0]);n=10;a/=10,n++);return(r=n+14*r-1)>O?e.c=e.e=null:r=10;f/=10,a++);if((i=t-a)<0)i+=14,o=t,h=(d=p[b=0])/m[a-o-1]%10|0;else if((b=c((i+1)/14))>=p.length){if(!n)break e;for(;p.length<=b;p.push(0));d=h=0,a=1,o=(i%=14)-14+1}else{for(d=f=p[b],a=1;f>=10;f/=10,a++);h=(o=(i%=14)-14+a)<0?0:d/m[a-o-1]%10|0}if(n=n||t<0||null!=p[b+1]||(o<0?d:d%m[a-o-1]),n=r<4?(h||n)&&(0==r||r==(e.s<0?3:2)):h>5||5==h&&(4==r||n||6==r&&(i>0?o>0?d/m[a-o]:0:p[b-1])%10&1||r==(e.s<0?8:7)),t<1||!p[0])return p.length=0,n?(t-=e.e+1,p[0]=m[(14-t%14)%14],e.e=-t||0):p[0]=e.e=0,e;if(0==i?(p.length=b,f=1,b--):(p.length=b+1,f=m[14-i],p[b]=o>0?s(d/m[a-o]%m[o])*f:0),n)for(;;){if(0==b){for(i=1,o=p[0];o>=10;o/=10,i++);for(o=p[0]+=f,f=1;o>=10;o/=10,f++);i!=f&&(e.e++,p[0]==u&&(p[0]=1));break}if(p[b]+=f,p[b]!=u)break;p[b--]=0,f=1}for(i=p.length;0===p[--i];p.pop());}e.e>O?e.c=e.e=null:e.e=S?x(t,r):y(t,r,"0"),e.s<0?"-"+t:t)}return N.clone=e,N.ROUND_UP=0,N.ROUND_DOWN=1,N.ROUND_CEIL=2,N.ROUND_FLOOR=3,N.ROUND_HALF_UP=4,N.ROUND_HALF_DOWN=5,N.ROUND_HALF_EVEN=6,N.ROUND_HALF_CEIL=7,N.ROUND_HALF_FLOOR=8,N.EUCLID=9,N.config=N.set=function(e){var t,r;if(null!=e){if("object"!=typeof e)throw Error(f+"Object expected: "+e);if(e.hasOwnProperty(t="DECIMAL_PLACES")&&(v(r=e[t],0,b,t),k=r),e.hasOwnProperty(t="ROUNDING_MODE")&&(v(r=e[t],0,8,t),_=r),e.hasOwnProperty(t="EXPONENTIAL_AT")&&((r=e[t])&&r.pop?(v(r[0],-b,0,t),v(r[1],0,b,t),M=r[0],S=r[1]):(v(r,-b,b,t),M=-(S=r<0?-r:r))),e.hasOwnProperty(t="RANGE"))if((r=e[t])&&r.pop)v(r[0],-b,-1,t),v(r[1],1,b,t),E=r[0],O=r[1];else{if(v(r,-b,b,t),!r)throw Error(f+t+" cannot be zero: "+r);E=-(O=r<0?-r:r)}if(e.hasOwnProperty(t="CRYPTO")){if((r=e[t])!==!!r)throw Error(f+t+" not true or false: "+r);if(r){if("undefined"==typeof crypto||!crypto||!crypto.getRandomValues&&!crypto.randomBytes)throw A=!r,Error(f+"crypto unavailable");A=r}else A=r}if(e.hasOwnProperty(t="MODULO_MODE")&&(v(r=e[t],0,9,t),T=r),e.hasOwnProperty(t="POW_PRECISION")&&(v(r=e[t],0,b,t),j=r),e.hasOwnProperty(t="FORMAT")){if("object"!=typeof(r=e[t]))throw Error(f+t+" not an object: "+r);P=r}if(e.hasOwnProperty(t="ALPHABET")){if("string"!=typeof(r=e[t])||/^.?$|[+\-.\s]|(.).*\1/.test(r))throw Error(f+t+" invalid: "+r);R="0123456789"==r.slice(0,10),C=r}}return{DECIMAL_PLACES:k,ROUNDING_MODE:_,EXPONENTIAL_AT:[M,S],RANGE:[E,O],CRYPTO:A,MODULO_MODE:T,POW_PRECISION:j,FORMAT:P,ALPHABET:C}},N.isBigNumber=function(e){if(!e||!0!==e._isBigNumber)return!1;if(!N.DEBUG)return!0;var t,r,n=e.c,a=e.e,i=e.s;e:if("[object Array]"=={}.toString.call(n)){if((1===i||-1===i)&&a>=-b&&a<=b&&a===s(a)){if(0===n[0]){if(0===a&&1===n.length)return!0;break e}if((t=(a+1)%14)<1&&(t+=14),String(n[0]).length==t){for(t=0;t=u||r!==s(r))break e;if(0!==r)return!0}}}else if(null===n&&null===a&&(null===i||1===i||-1===i))return!0;throw Error(f+"Invalid BigNumber: "+e)},N.maximum=N.max=function(){return L(arguments,i.lt)},N.minimum=N.min=function(){return L(arguments,i.gt)},N.random=function(){var e=9007199254740992*Math.random()&2097151?function(){return s(9007199254740992*Math.random())}:function(){return 8388608*(1073741824*Math.random()|0)+(8388608*Math.random()|0)};return function(t){var r,n,a,i,o,d=0,u=[],h=new N(w);if(null==t?t=k:v(t,0,b),i=c(t/14),A)if(crypto.getRandomValues){for(r=crypto.getRandomValues(new Uint32Array(i*=2));d>>11))>=9e15?(n=crypto.getRandomValues(new Uint32Array(2)),r[d]=n[0],r[d+1]=n[1]):(u.push(o%1e14),d+=2);d=i/2}else{if(!crypto.randomBytes)throw A=!1,Error(f+"crypto unavailable");for(r=crypto.randomBytes(i*=7);d=9e15?crypto.randomBytes(7).copy(r,d):(u.push(o%1e14),d+=7);d=i/7}if(!A)for(;d=10;o/=10,d++);d<14&&(a-=14-d)}return h.e=a,h.c=u,h}}(),N.sum=function(){for(var e=1,t=arguments,r=new N(t[0]);er-1&&(null==o[a+1]&&(o[a+1]=0),o[a+1]+=o[a]/r|0,o[a]%=r)}return o.reverse()}return function(t,n,a,i,o){var c,s,f,d,u,l,b,h,m=t.indexOf("."),v=k,g=_;for(m>=0&&(d=j,j=0,t=t.replace(".",""),l=(h=new N(n)).pow(t.length-m),j=d,h.c=e(y(p(l.c),l.e,"0"),10,a,"0123456789"),h.e=h.c.length),f=d=(b=e(t,n,a,o?(c=C,"0123456789"):(c="0123456789",C))).length;0==b[--d];b.pop());if(!b[0])return c.charAt(0);if(m<0?--f:(l.c=b,l.e=f,l.s=i,b=(l=r(l,h,v,g,a)).c,u=l.r,f=l.e),m=b[s=f+v+1],d=a/2,u=u||s<0||null!=b[s+1],u=g<4?(null!=m||u)&&(0==g||g==(l.s<0?3:2)):m>d||m==d&&(4==g||u||6==g&&1&b[s-1]||g==(l.s<0?8:7)),s<1||!b[0])t=u?y(c.charAt(1),-v,c.charAt(0)):c.charAt(0);else{if(b.length=s,u)for(--a;++b[--s]>a;)b[s]=0,s||(++f,b=[1].concat(b));for(d=b.length;!b[--d];);for(m=0,t="";m<=d;t+=c.charAt(b[m++]));t=y(t,f,c.charAt(0))}return t}}(),r=function(){function e(e,t,r){var n,a,i,o,c=0,s=e.length,f=t%1e7,d=t/1e7|0;for(e=e.slice();s--;)c=((a=f*(i=e[s]%1e7)+(n=d*i+(o=e[s]/1e7|0)*f)%1e7*1e7+c)/r|0)+(n/1e7|0)+d*o,e[s]=a%r;return c&&(e=[c].concat(e)),e}function t(e,t,r,n){var a,i;if(r!=n)i=r>n?1:-1;else for(a=i=0;at[a]?1:-1;break}return i}function r(e,t,r,n){for(var a=0;r--;)e[r]-=a,a=e[r]1;e.splice(0,1));}return function(n,a,i,o,c){var f,d,l,b,p,m,v,g,x,y,w,k,_,M,S,E,O,A=n.s==a.s?1:-1,T=n.c,j=a.c;if(!T||!T[0]||!j||!j[0])return new N(n.s&&a.s&&(T?!j||T[0]!=j[0]:j)?T&&0==T[0]||!j?0*A:A/0:NaN);for(x=(g=new N(A)).c=[],A=i+(d=n.e-a.e)+1,c||(c=u,d=h(n.e/14)-h(a.e/14),A=A/14|0),l=0;j[l]==(T[l]||0);l++);if(j[l]>(T[l]||0)&&d--,A<0)x.push(1),b=!0;else{for(M=T.length,E=j.length,l=0,A+=2,(p=s(c/(j[0]+1)))>1&&(j=e(j,p,c),T=e(T,p,c),E=j.length,M=T.length),_=E,w=(y=T.slice(0,E)).length;w=c/2&&S++;do{if(p=0,(f=t(j,y,E,w))<0){if(k=y[0],E!=w&&(k=k*c+(y[1]||0)),(p=s(k/S))>1)for(p>=c&&(p=c-1),v=(m=e(j,p,c)).length,w=y.length;1==t(m,y,v,w);)p--,r(m,E=10;A/=10,l++);F(g,i+(g.e=l+14*d-1)+1,o,b)}else g.e=d,g.r=+b;return g}}(),a=function(){var e=/^(-?)0([xbo])(?=\w[\w.]*$)/i,t=/^([^.]+)\.$/,r=/^\.([^.]+)$/,n=/^-?(Infinity|NaN)$/,a=/^\s*\+(?=[\w.])|^\s+|\s+$/g;return function(i,o,c,s){var d,u=c?o:o.replace(a,"");if(n.test(u))i.s=isNaN(u)?null:u<0?-1:1;else{if(!c&&(u=u.replace(e,(function(e,t,r){return d="x"==(r=r.toLowerCase())?16:"b"==r?2:8,s&&s!=d?e:t})),s&&(d=s,u=u.replace(t,"$1").replace(r,"0.$1")),o!=u))return new N(u,d);if(N.DEBUG)throw Error(f+"Not a"+(s?" base "+s:"")+" number: "+o);i.s=null}i.c=i.e=null}}(),i.absoluteValue=i.abs=function(){var e=new N(this);return e.s<0&&(e.s=1),e},i.comparedTo=function(e,t){return m(this,new N(e,t))},i.decimalPlaces=i.dp=function(e,t){var r,n,a,i=this;if(null!=e)return v(e,0,b),null==t?t=_:v(t,0,8),F(new N(i),e+i.e+1,t);if(!(r=i.c))return null;if(n=14*((a=r.length-1)-h(this.e/14)),a=r[a])for(;a%10==0;a/=10,n--);return n<0&&(n=0),n},i.dividedBy=i.div=function(e,t){return r(this,new N(e,t),k,_)},i.dividedToIntegerBy=i.idiv=function(e,t){return r(this,new N(e,t),0,1)},i.exponentiatedBy=i.pow=function(e,t){var r,n,a,i,o,d,u,l,b=this;if((e=new N(e)).c&&!e.isInteger())throw Error(f+"Exponent not an integer: "+D(e));if(null!=t&&(t=new N(t)),o=e.e>14,!b.c||!b.c[0]||1==b.c[0]&&!b.e&&1==b.c.length||!e.c||!e.c[0])return l=new N(Math.pow(+D(b),o?2-g(e):+D(e))),t?l.mod(t):l;if(d=e.s<0,t){if(t.c?!t.c[0]:!t.s)return new N(NaN);(n=!d&&b.isInteger()&&t.isInteger())&&(b=b.mod(t))}else{if(e.e>9&&(b.e>0||b.e<-1||(0==b.e?b.c[0]>1||o&&b.c[1]>=24e7:b.c[0]<8e13||o&&b.c[0]<=9999975e7)))return i=b.s<0&&g(e)?-0:0,b.e>-1&&(i=1/i),new N(d?1/i:i);j&&(i=c(j/14+2))}for(o?(r=new N(.5),d&&(e.s=1),u=g(e)):u=(a=Math.abs(+D(e)))%2,l=new N(w);;){if(u){if(!(l=l.times(b)).c)break;i?l.c.length>i&&(l.c.length=i):n&&(l=l.mod(t))}if(a){if(0===(a=s(a/2)))break;u=a%2}else if(F(e=e.times(r),e.e+1,1),e.e>14)u=g(e);else{if(0===(a=+D(e)))break;u=a%2}b=b.times(b),i?b.c&&b.c.length>i&&(b.c.length=i):n&&(b=b.mod(t))}return n?l:(d&&(l=w.div(l)),t?l.mod(t):i?F(l,j,_,void 0):l)},i.integerValue=function(e){var t=new N(this);return null==e?e=_:v(e,0,8),F(t,t.e+1,e)},i.isEqualTo=i.eq=function(e,t){return 0===m(this,new N(e,t))},i.isFinite=function(){return!!this.c},i.isGreaterThan=i.gt=function(e,t){return m(this,new N(e,t))>0},i.isGreaterThanOrEqualTo=i.gte=function(e,t){return 1===(t=m(this,new N(e,t)))||0===t},i.isInteger=function(){return!!this.c&&h(this.e/14)>this.c.length-2},i.isLessThan=i.lt=function(e,t){return m(this,new N(e,t))<0},i.isLessThanOrEqualTo=i.lte=function(e,t){return-1===(t=m(this,new N(e,t)))||0===t},i.isNaN=function(){return!this.s},i.isNegative=function(){return this.s<0},i.isPositive=function(){return this.s>0},i.isZero=function(){return!!this.c&&0==this.c[0]},i.minus=function(e,t){var r,n,a,i,o=this,c=o.s;if(t=(e=new N(e,t)).s,!c||!t)return new N(NaN);if(c!=t)return e.s=-t,o.plus(e);var s=o.e/14,f=e.e/14,d=o.c,l=e.c;if(!s||!f){if(!d||!l)return d?(e.s=-t,e):new N(l?o:NaN);if(!d[0]||!l[0])return l[0]?(e.s=-t,e):new N(d[0]?o:3==_?-0:0)}if(s=h(s),f=h(f),d=d.slice(),c=s-f){for((i=c<0)?(c=-c,a=d):(f=s,a=l),a.reverse(),t=c;t--;a.push(0));a.reverse()}else for(n=(i=(c=d.length)<(t=l.length))?c:t,c=t=0;t0)for(;t--;d[r++]=0);for(t=u-1;n>c;){if(d[--n]=0;){for(r=0,b=y[a]%1e7,p=y[a]/1e7|0,i=a+(o=s);i>a;)r=((f=b*(f=x[--o]%1e7)+(c=p*f+(d=x[o]/1e7|0)*b)%1e7*1e7+m[i]+r)/v|0)+(c/1e7|0)+p*d,m[i--]=f%v;m[i]=r}return r?++n:m.splice(0,1),I(e,m,n)},i.negated=function(){var e=new N(this);return e.s=-e.s||null,e},i.plus=function(e,t){var r,n=this,a=n.s;if(t=(e=new N(e,t)).s,!a||!t)return new N(NaN);if(a!=t)return e.s=-t,n.minus(e);var i=n.e/14,o=e.e/14,c=n.c,s=e.c;if(!i||!o){if(!c||!s)return new N(a/0);if(!c[0]||!s[0])return s[0]?e:new N(c[0]?n:0*a)}if(i=h(i),o=h(o),c=c.slice(),a=i-o){for(a>0?(o=i,r=s):(a=-a,r=c),r.reverse();a--;r.push(0));r.reverse()}for((a=c.length)-(t=s.length)<0&&(r=s,s=c,c=r,t=a),a=0;t;)a=(c[--t]=c[t]+s[t]+a)/u|0,c[t]=u===c[t]?0:c[t]%u;return a&&(c=[a].concat(c),++o),I(e,c,o)},i.precision=i.sd=function(e,t){var r,n,a,i=this;if(null!=e&&e!==!!e)return v(e,1,b),null==t?t=_:v(t,0,8),F(new N(i),e,t);if(!(r=i.c))return null;if(n=14*(a=r.length-1)+1,a=r[a]){for(;a%10==0;a/=10,n--);for(a=r[0];a>=10;a/=10,n++);}return e&&i.e+1>n&&(n=i.e+1),n},i.shiftedBy=function(e){return v(e,-9007199254740991,9007199254740991),this.times("1e"+e)},i.squareRoot=i.sqrt=function(){var e,t,n,a,i,o=this,c=o.c,s=o.s,f=o.e,d=k+4,u=new N("0.5");if(1!==s||!c||!c[0])return new N(!s||s<0&&(!c||c[0])?NaN:c?o:1/0);if(0==(s=Math.sqrt(+D(o)))||s==1/0?(((t=p(c)).length+f)%2==0&&(t+="0"),s=Math.sqrt(+t),f=h((f+1)/2)-(f<0||f%2),n=new N(t=s==1/0?"5e"+f:(t=s.toExponential()).slice(0,t.indexOf("e")+1)+f)):n=new N(s+""),n.c[0])for((s=(f=n.e)+d)<3&&(s=0);;)if(i=n,n=u.times(i.plus(r(o,i,d,1))),p(i.c).slice(0,s)===(t=p(n.c)).slice(0,s)){if(n.e0&&p>0){for(i=p%c||c,u=h.substr(0,i);i0&&(u+=d+h.slice(i)),b&&(u="-"+u)}n=l?u+(r.decimalSeparator||"")+((s=+r.fractionGroupSize)?l.replace(new RegExp("\\d{"+s+"}\\B","g"),"$&"+(r.fractionGroupSeparator||"")):l):u}return(r.prefix||"")+n+(r.suffix||"")},i.toFraction=function(e){var t,n,a,i,o,c,s,d,u,b,h,m,v=this,g=v.c;if(null!=e&&(!(s=new N(e)).isInteger()&&(s.c||1!==s.s)||s.lt(w)))throw Error(f+"Argument "+(s.isInteger()?"out of range: ":"not an integer: ")+D(s));if(!g)return new N(v);for(t=new N(w),u=n=new N(w),a=d=new N(w),m=p(g),o=t.e=m.length-v.e-1,t.c[0]=l[(c=o%14)<0?14+c:c],e=!e||s.comparedTo(t)>0?o>0?t:u:s,c=O,O=1/0,s=new N(m),d.c[0]=0;b=r(s,t,0,1),1!=(i=n.plus(b.times(a))).comparedTo(e);)n=a,a=i,u=d.plus(b.times(i=u)),d=i,t=s.minus(b.times(i=t)),s=i;return i=r(e.minus(n),a,0,1),d=d.plus(i.times(u)),n=n.plus(i.times(a)),d.s=u.s=v.s,h=r(u,a,o*=2,_).minus(v).abs().comparedTo(r(d,n,o,_).minus(v).abs())<1?[u,a]:[d,n],O=c,h},i.toNumber=function(){return+D(this)},i.toPrecision=function(e,t){return null!=e&&v(e,1,b),B(this,e,t,2)},i.toString=function(e){var t,r=this,a=r.s,i=r.e;return null===i?a?(t="Infinity",a<0&&(t="-"+t)):t="NaN":(null==e?t=i<=M||i>=S?x(p(r.c),i):y(p(r.c),i,"0"):10===e&&R?t=y(p((r=F(new N(r),k+i+1,_)).c),r.e,"0"):(v(e,2,C.length,"Base"),t=n(y(p(r.c),i,"0"),10,e,a,!0)),a<0&&r.c[0]&&(t="-"+t)),t},i.valueOf=i.toJSON=function(){return D(this)},i._isBigNumber=!0,null!=t&&N.set(t),N}()).default=i.BigNumber=i,void 0===(n=function(){return i}.call(t,r,t,e))||(e.exports=n)}()},function(e,t,r){(function(e){!function(e){"use strict";e.exports.is_uri=r,e.exports.is_http_uri=n,e.exports.is_https_uri=a,e.exports.is_web_uri=i,e.exports.isUri=r,e.exports.isHttpUri=n,e.exports.isHttpsUri=a,e.exports.isWebUri=i;var t=function(e){return e.match(/(?:([^:\/?#]+):)?(?:\/\/([^\/?#]*))?([^?#]*)(?:\?([^#]*))?(?:#(.*))?/)};function r(e){if(e&&!/[^a-z0-9\:\/\?\#\[\]\@\!\$\&\'\(\)\*\+\,\;\=\.\-\_\~\%]/i.test(e)&&!/%[^0-9a-f]/i.test(e)&&!/%[0-9a-f](:?[^0-9a-f]|$)/i.test(e)){var r,n,a,i,o,c="",s="";if(c=(r=t(e))[1],n=r[2],a=r[3],i=r[4],o=r[5],c&&c.length&&a.length>=0){if(n&&n.length){if(0!==a.length&&!/^\//.test(a))return}else if(/^\/\//.test(a))return;if(/^[a-z][a-z0-9\+\-\.]*$/.test(c.toLowerCase()))return s+=c+":",n&&n.length&&(s+="//"+n),s+=a,i&&i.length&&(s+="?"+i),o&&o.length&&(s+="#"+o),s}}}function n(e,n){if(r(e)){var a,i,o,c,s="",f="",d="",u="";if(s=(a=t(e))[1],f=a[2],i=a[3],o=a[4],c=a[5],s){if(n){if("https"!=s.toLowerCase())return}else if("http"!=s.toLowerCase())return;if(f)return/:(\d+)$/.test(f)&&(d=f.match(/:(\d+)$/)[0],f=f.replace(/:\d+$/,"")),u+=s+":",u+="//"+f,d&&(u+=d),u+=i,o&&o.length&&(u+="?"+o),c&&c.length&&(u+="#"+c),u}}}function a(e){return n(e,!0)}function i(e){return n(e)||a(e)}}(e)}).call(this,r(74)(e))},function(e,t,r){"use strict";r.d(t,"a",(function(){return a})),r.d(t,"b",(function(){return i})),r.d(t,"c",(function(){return o})),r.d(t,"d",(function(){return c})),r.d(t,"e",(function(){return s})),r.d(t,"f",(function(){return f})),r.d(t,"g",(function(){return d})),r.d(t,"h",(function(){return u}));var n=r(0);function a(e){return Object(n.a)({tag:"svg",attr:{fill:"currentColor",viewBox:"0 0 16 16"},child:[{tag:"path",attr:{d:"M6.552 6.712c-.456 0-.816.4-.816.888s.368.888.816.888c.456 0 .816-.4.816-.888.008-.488-.36-.888-.816-.888zm2.92 0c-.456 0-.816.4-.816.888s.368.888.816.888c.456 0 .816-.4.816-.888s-.36-.888-.816-.888z"}},{tag:"path",attr:{d:"M13.36 0H2.64C1.736 0 1 .736 1 1.648v10.816c0 .912.736 1.648 1.64 1.648h9.072l-.424-1.48 1.024.952.968.896L15 16V1.648C15 .736 14.264 0 13.36 0zm-3.088 10.448s-.288-.344-.528-.648c1.048-.296 1.448-.952 1.448-.952-.328.216-.64.368-.92.472-.4.168-.784.28-1.16.344a5.604 5.604 0 0 1-2.072-.008 6.716 6.716 0 0 1-1.176-.344 4.688 4.688 0 0 1-.584-.272c-.024-.016-.048-.024-.072-.04-.016-.008-.024-.016-.032-.024-.144-.08-.224-.136-.224-.136s.384.64 1.4.944c-.24.304-.536.664-.536.664-1.768-.056-2.44-1.216-2.44-1.216 0-2.576 1.152-4.664 1.152-4.664 1.152-.864 2.248-.84 2.248-.84l.08.096c-1.44.416-2.104 1.048-2.104 1.048s.176-.096.472-.232c.856-.376 1.536-.48 1.816-.504.048-.008.088-.016.136-.016a6.521 6.521 0 0 1 4.024.752s-.632-.6-1.992-1.016l.112-.128s1.096-.024 2.248.84c0 0 1.152 2.088 1.152 4.664 0 0-.68 1.16-2.448 1.216z"}}]})(e)}function i(e){return Object(n.a)({tag:"svg",attr:{fill:"currentColor",viewBox:"0 0 16 16"},child:[{tag:"path",attr:{d:"M16 8.049c0-4.446-3.582-8.05-8-8.05C3.58 0-.002 3.603-.002 8.05c0 4.017 2.926 7.347 6.75 7.951v-5.625h-2.03V8.05H6.75V6.275c0-2.017 1.195-3.131 3.022-3.131.876 0 1.791.157 1.791.157v1.98h-1.009c-.993 0-1.303.621-1.303 1.258v1.51h2.218l-.354 2.326H9.25V16c3.824-.604 6.75-3.934 6.75-7.951z"}}]})(e)}function o(e){return Object(n.a)({tag:"svg",attr:{fill:"currentColor",viewBox:"0 0 16 16"},child:[{tag:"path",attr:{d:"M8 0C3.58 0 0 3.58 0 8c0 3.54 2.29 6.53 5.47 7.59.4.07.55-.17.55-.38 0-.19-.01-.82-.01-1.49-2.01.37-2.53-.49-2.69-.94-.09-.23-.48-.94-.82-1.13-.28-.15-.68-.52-.01-.53.63-.01 1.08.58 1.23.82.72 1.21 1.87.87 2.33.66.07-.52.28-.87.51-1.07-1.78-.2-3.64-.89-3.64-3.95 0-.87.31-1.59.82-2.15-.08-.2-.36-1.02.08-2.12 0 0 .67-.21 2.2.82.64-.18 1.32-.27 2-.27.68 0 1.36.09 2 .27 1.53-1.04 2.2-.82 2.2-.82.44 1.1.16 1.92.08 2.12.51.56.82 1.27.82 2.15 0 3.07-1.87 3.75-3.65 3.95.29.25.54.73.54 1.48 0 1.07-.01 1.93-.01 2.2 0 .21.15.46.55.38A8.012 8.012 0 0 0 16 8c0-4.42-3.58-8-8-8z"}}]})(e)}function c(e){return Object(n.a)({tag:"svg",attr:{fill:"currentColor",viewBox:"0 0 16 16"},child:[{tag:"path",attr:{d:"M11.251.068a.5.5 0 0 1 .227.58L9.677 6.5H13a.5.5 0 0 1 .364.843l-8 8.5a.5.5 0 0 1-.842-.49L6.323 9.5H3a.5.5 0 0 1-.364-.843l8-8.5a.5.5 0 0 1 .615-.09z"}}]})(e)}function s(e){return Object(n.a)({tag:"svg",attr:{fill:"currentColor",viewBox:"0 0 16 16"},child:[{tag:"path",attr:{d:"M0 1.146C0 .513.526 0 1.175 0h13.65C15.474 0 16 .513 16 1.146v13.708c0 .633-.526 1.146-1.175 1.146H1.175C.526 16 0 15.487 0 14.854V1.146zm4.943 12.248V6.169H2.542v7.225h2.401zm-1.2-8.212c.837 0 1.358-.554 1.358-1.248-.015-.709-.52-1.248-1.342-1.248-.822 0-1.359.54-1.359 1.248 0 .694.521 1.248 1.327 1.248h.016zm4.908 8.212V9.359c0-.216.016-.432.08-.586.173-.431.568-.878 1.232-.878.869 0 1.216.662 1.216 1.634v3.865h2.401V9.25c0-2.22-1.184-3.252-2.764-3.252-1.274 0-1.845.7-2.165 1.193v.025h-.016a5.54 5.54 0 0 1 .016-.025V6.169h-2.4c.03.678 0 7.225 0 7.225h2.4z"}}]})(e)}function f(e){return Object(n.a)({tag:"svg",attr:{fill:"currentColor",viewBox:"0 0 16 16"},child:[{tag:"path",attr:{d:"M9.025 8c0 2.485-2.02 4.5-4.513 4.5A4.506 4.506 0 0 1 0 8c0-2.486 2.02-4.5 4.512-4.5A4.506 4.506 0 0 1 9.025 8zm4.95 0c0 2.34-1.01 4.236-2.256 4.236-1.246 0-2.256-1.897-2.256-4.236 0-2.34 1.01-4.236 2.256-4.236 1.246 0 2.256 1.897 2.256 4.236zM16 8c0 2.096-.355 3.795-.794 3.795-.438 0-.793-1.7-.793-3.795 0-2.096.355-3.795.794-3.795.438 0 .793 1.699.793 3.795z"}}]})(e)}function d(e){return Object(n.a)({tag:"svg",attr:{fill:"currentColor",viewBox:"0 0 16 16"},child:[{tag:"path",attr:{d:"M8 15A7 7 0 1 1 8 1a7 7 0 0 1 0 14zm0 1A8 8 0 1 0 8 0a8 8 0 0 0 0 16z"}},{tag:"path",attr:{d:"M5.255 5.786a.237.237 0 0 0 .241.247h.825c.138 0 .248-.113.266-.25.09-.656.54-1.134 1.342-1.134.686 0 1.314.343 1.314 1.168 0 .635-.374.927-.965 1.371-.673.489-1.206 1.06-1.168 1.987l.003.217a.25.25 0 0 0 .25.246h.811a.25.25 0 0 0 .25-.25v-.105c0-.718.273-.927 1.01-1.486.609-.463 1.244-.977 1.244-2.056 0-1.511-1.276-2.241-2.673-2.241-1.267 0-2.655.59-2.75 2.286zm1.557 5.763c0 .533.425.927 1.01.927.609 0 1.028-.394 1.028-.927 0-.552-.42-.94-1.029-.94-.584 0-1.009.388-1.009.94z"}}]})(e)}function u(e){return Object(n.a)({tag:"svg",attr:{fill:"currentColor",viewBox:"0 0 16 16"},child:[{tag:"path",attr:{d:"M6.167 8a.831.831 0 0 0-.83.83c0 .459.372.84.83.831a.831.831 0 0 0 0-1.661zm1.843 3.647c.315 0 1.403-.038 1.976-.611a.232.232 0 0 0 0-.306.213.213 0 0 0-.306 0c-.353.363-1.126.487-1.67.487-.545 0-1.308-.124-1.671-.487a.213.213 0 0 0-.306 0 .213.213 0 0 0 0 .306c.564.563 1.652.61 1.977.61zm.992-2.807c0 .458.373.83.831.83.458 0 .83-.381.83-.83a.831.831 0 0 0-1.66 0z"}},{tag:"path",attr:{d:"M16 8A8 8 0 1 1 0 8a8 8 0 0 1 16 0zm-3.828-1.165c-.315 0-.602.124-.812.325-.801-.573-1.9-.945-3.121-.993l.534-2.501 1.738.372a.83.83 0 1 0 .83-.869.83.83 0 0 0-.744.468l-1.938-.41a.203.203 0 0 0-.153.028.186.186 0 0 0-.086.134l-.592 2.788c-1.24.038-2.358.41-3.17.992-.21-.2-.496-.324-.81-.324a1.163 1.163 0 0 0-.478 2.224c-.02.115-.029.23-.029.353 0 1.795 2.091 3.256 4.669 3.256 2.577 0 4.668-1.451 4.668-3.256 0-.114-.01-.238-.029-.353.401-.181.688-.592.688-1.069 0-.65-.525-1.165-1.165-1.165z"}}]})(e)}},function(e,t,r){var n=r(733),a=r(734),i=r(299),o=r(735);e.exports=function(e,t){return n(e)||a(e,t)||i(e,t)||o()}},function(e,t,r){(function(e){!function(e,t){"use strict";function n(e,t){if(!e)throw new Error(t||"Assertion failed")}function a(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function i(e,t,r){if(i.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var o;"object"===typeof e?e.exports=i:t.BN=i,i.BN=i,i.wordSize=26;try{o="undefined"!==typeof window&&"undefined"!==typeof window.Buffer?window.Buffer:r(641).Buffer}catch(S){}function c(e,t){var r=e.charCodeAt(t);return r>=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function s(e,t,r){var n=c(e,r);return r-1>=t&&(n|=c(e,r-1)<<4),n}function f(e,t,r,n){for(var a=0,i=Math.min(e.length,r),o=t;o=49?c-49+10:c>=17?c-17+10:c}return a}i.isBN=function(e){return e instanceof i||null!==e&&"object"===typeof e&&e.constructor.wordSize===i.wordSize&&Array.isArray(e.words)},i.max=function(e,t){return e.cmp(t)>0?e:t},i.min=function(e,t){return e.cmp(t)<0?e:t},i.prototype._init=function(e,t,r){if("number"===typeof e)return this._initNumber(e,t,r);if("object"===typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var a=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(a++,this.negative=1),a=0;a-=3)o=e[a]|e[a-1]<<8|e[a-2]<<16,this.words[i]|=o<>>26-c&67108863,(c+=24)>=26&&(c-=26,i++);else if("le"===r)for(a=0,i=0;a>>26-c&67108863,(c+=24)>=26&&(c-=26,i++);return this.strip()},i.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)a=s(e,t,n)<=18?(i-=18,o+=1,this.words[o]|=a>>>26):i+=8;else for(n=(e.length-t)%2===0?t+1:t;n=18?(i-=18,o+=1,this.words[o]|=a>>>26):i+=8;this.strip()},i.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,a=1;a<=67108863;a*=t)n++;n--,a=a/t|0;for(var i=e.length-r,o=i%n,c=Math.min(i,i-o)+r,s=0,d=r;d1&&0===this.words[this.length-1];)this.length--;return this._normSign()},i.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},i.prototype.inspect=function(){return(this.red?""};var d=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],u=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],l=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];function b(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var a=0|e.words[0],i=0|t.words[0],o=a*i,c=67108863&o,s=o/67108864|0;r.words[0]=c;for(var f=1;f>>26,u=67108863&s,l=Math.min(f,t.length-1),b=Math.max(0,f-e.length+1);b<=l;b++){var h=f-b|0;d+=(o=(a=0|e.words[h])*(i=0|t.words[b])+u)/67108864|0,u=67108863&o}r.words[f]=0|u,s=0|d}return 0!==s?r.words[f]=0|s:r.length--,r.strip()}i.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var a=0,i=0,o=0;o>>24-a&16777215)||o!==this.length-1?d[6-s.length]+s+r:s+r,(a+=2)>=26&&(a-=26,o--)}for(0!==i&&(r=i.toString(16)+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var f=u[e],b=l[e];r="";var h=this.clone();for(h.negative=0;!h.isZero();){var p=h.modn(b).toString(e);r=(h=h.idivn(b)).isZero()?p+r:d[f-p.length]+p+r}for(this.isZero()&&(r="0"+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},i.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},i.prototype.toJSON=function(){return this.toString(16)},i.prototype.toBuffer=function(e,t){return n("undefined"!==typeof o),this.toArrayLike(o,e,t)},i.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},i.prototype.toArrayLike=function(e,t,r){var a=this.byteLength(),i=r||Math.max(1,a);n(a<=i,"byte array longer than desired length"),n(i>0,"Requested array length <= 0"),this.strip();var o,c,s="le"===t,f=new e(i),d=this.clone();if(s){for(c=0;!d.isZero();c++)o=d.andln(255),d.iushrn(8),f[c]=o;for(;c=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},i.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0===(8191&t)&&(r+=13,t>>>=13),0===(127&t)&&(r+=7,t>>>=7),0===(15&t)&&(r+=4,t>>>=4),0===(3&t)&&(r+=2,t>>>=2),0===(1&t)&&r++,r},i.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},i.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},i.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},i.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},i.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},i.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},i.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},i.prototype.inotn=function(e){n("number"===typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var a=0;a0&&(this.words[a]=~this.words[a]&67108863>>26-r),this.strip()},i.prototype.notn=function(e){return this.clone().inotn(e)},i.prototype.setn=function(e,t){n("number"===typeof e&&e>=0);var r=e/26|0,a=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var a=0,i=0;i>>26;for(;0!==a&&i>>26;if(this.length=r.length,0!==a)this.words[this.length]=a,this.length++;else if(r!==this)for(;ie.length?this.clone().iadd(e):e.clone().iadd(this)},i.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,a=this.cmp(e);if(0===a)return this.negative=0,this.length=1,this.words[0]=0,this;a>0?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>26,this.words[o]=67108863&t;for(;0!==i&&o>26,this.words[o]=67108863&t;if(0===i&&o>>13,b=0|o[1],h=8191&b,p=b>>>13,m=0|o[2],v=8191&m,g=m>>>13,x=0|o[3],y=8191&x,w=x>>>13,k=0|o[4],_=8191&k,M=k>>>13,S=0|o[5],E=8191&S,O=S>>>13,A=0|o[6],T=8191&A,j=A>>>13,P=0|o[7],C=8191&P,R=P>>>13,N=0|o[8],B=8191&N,L=N>>>13,I=0|o[9],F=8191&I,D=I>>>13,U=0|c[0],z=8191&U,H=U>>>13,q=0|c[1],J=8191&q,V=q>>>13,G=0|c[2],X=8191&G,K=G>>>13,W=0|c[3],Z=8191&W,$=W>>>13,Q=0|c[4],Y=8191&Q,ee=Q>>>13,te=0|c[5],re=8191&te,ne=te>>>13,ae=0|c[6],ie=8191&ae,oe=ae>>>13,ce=0|c[7],se=8191&ce,fe=ce>>>13,de=0|c[8],ue=8191&de,le=de>>>13,be=0|c[9],he=8191&be,pe=be>>>13;r.negative=e.negative^t.negative,r.length=19;var me=(f+(n=Math.imul(u,z))|0)+((8191&(a=(a=Math.imul(u,H))+Math.imul(l,z)|0))<<13)|0;f=((i=Math.imul(l,H))+(a>>>13)|0)+(me>>>26)|0,me&=67108863,n=Math.imul(h,z),a=(a=Math.imul(h,H))+Math.imul(p,z)|0,i=Math.imul(p,H);var ve=(f+(n=n+Math.imul(u,J)|0)|0)+((8191&(a=(a=a+Math.imul(u,V)|0)+Math.imul(l,J)|0))<<13)|0;f=((i=i+Math.imul(l,V)|0)+(a>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(v,z),a=(a=Math.imul(v,H))+Math.imul(g,z)|0,i=Math.imul(g,H),n=n+Math.imul(h,J)|0,a=(a=a+Math.imul(h,V)|0)+Math.imul(p,J)|0,i=i+Math.imul(p,V)|0;var ge=(f+(n=n+Math.imul(u,X)|0)|0)+((8191&(a=(a=a+Math.imul(u,K)|0)+Math.imul(l,X)|0))<<13)|0;f=((i=i+Math.imul(l,K)|0)+(a>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(y,z),a=(a=Math.imul(y,H))+Math.imul(w,z)|0,i=Math.imul(w,H),n=n+Math.imul(v,J)|0,a=(a=a+Math.imul(v,V)|0)+Math.imul(g,J)|0,i=i+Math.imul(g,V)|0,n=n+Math.imul(h,X)|0,a=(a=a+Math.imul(h,K)|0)+Math.imul(p,X)|0,i=i+Math.imul(p,K)|0;var xe=(f+(n=n+Math.imul(u,Z)|0)|0)+((8191&(a=(a=a+Math.imul(u,$)|0)+Math.imul(l,Z)|0))<<13)|0;f=((i=i+Math.imul(l,$)|0)+(a>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(_,z),a=(a=Math.imul(_,H))+Math.imul(M,z)|0,i=Math.imul(M,H),n=n+Math.imul(y,J)|0,a=(a=a+Math.imul(y,V)|0)+Math.imul(w,J)|0,i=i+Math.imul(w,V)|0,n=n+Math.imul(v,X)|0,a=(a=a+Math.imul(v,K)|0)+Math.imul(g,X)|0,i=i+Math.imul(g,K)|0,n=n+Math.imul(h,Z)|0,a=(a=a+Math.imul(h,$)|0)+Math.imul(p,Z)|0,i=i+Math.imul(p,$)|0;var ye=(f+(n=n+Math.imul(u,Y)|0)|0)+((8191&(a=(a=a+Math.imul(u,ee)|0)+Math.imul(l,Y)|0))<<13)|0;f=((i=i+Math.imul(l,ee)|0)+(a>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(E,z),a=(a=Math.imul(E,H))+Math.imul(O,z)|0,i=Math.imul(O,H),n=n+Math.imul(_,J)|0,a=(a=a+Math.imul(_,V)|0)+Math.imul(M,J)|0,i=i+Math.imul(M,V)|0,n=n+Math.imul(y,X)|0,a=(a=a+Math.imul(y,K)|0)+Math.imul(w,X)|0,i=i+Math.imul(w,K)|0,n=n+Math.imul(v,Z)|0,a=(a=a+Math.imul(v,$)|0)+Math.imul(g,Z)|0,i=i+Math.imul(g,$)|0,n=n+Math.imul(h,Y)|0,a=(a=a+Math.imul(h,ee)|0)+Math.imul(p,Y)|0,i=i+Math.imul(p,ee)|0;var we=(f+(n=n+Math.imul(u,re)|0)|0)+((8191&(a=(a=a+Math.imul(u,ne)|0)+Math.imul(l,re)|0))<<13)|0;f=((i=i+Math.imul(l,ne)|0)+(a>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(T,z),a=(a=Math.imul(T,H))+Math.imul(j,z)|0,i=Math.imul(j,H),n=n+Math.imul(E,J)|0,a=(a=a+Math.imul(E,V)|0)+Math.imul(O,J)|0,i=i+Math.imul(O,V)|0,n=n+Math.imul(_,X)|0,a=(a=a+Math.imul(_,K)|0)+Math.imul(M,X)|0,i=i+Math.imul(M,K)|0,n=n+Math.imul(y,Z)|0,a=(a=a+Math.imul(y,$)|0)+Math.imul(w,Z)|0,i=i+Math.imul(w,$)|0,n=n+Math.imul(v,Y)|0,a=(a=a+Math.imul(v,ee)|0)+Math.imul(g,Y)|0,i=i+Math.imul(g,ee)|0,n=n+Math.imul(h,re)|0,a=(a=a+Math.imul(h,ne)|0)+Math.imul(p,re)|0,i=i+Math.imul(p,ne)|0;var ke=(f+(n=n+Math.imul(u,ie)|0)|0)+((8191&(a=(a=a+Math.imul(u,oe)|0)+Math.imul(l,ie)|0))<<13)|0;f=((i=i+Math.imul(l,oe)|0)+(a>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(C,z),a=(a=Math.imul(C,H))+Math.imul(R,z)|0,i=Math.imul(R,H),n=n+Math.imul(T,J)|0,a=(a=a+Math.imul(T,V)|0)+Math.imul(j,J)|0,i=i+Math.imul(j,V)|0,n=n+Math.imul(E,X)|0,a=(a=a+Math.imul(E,K)|0)+Math.imul(O,X)|0,i=i+Math.imul(O,K)|0,n=n+Math.imul(_,Z)|0,a=(a=a+Math.imul(_,$)|0)+Math.imul(M,Z)|0,i=i+Math.imul(M,$)|0,n=n+Math.imul(y,Y)|0,a=(a=a+Math.imul(y,ee)|0)+Math.imul(w,Y)|0,i=i+Math.imul(w,ee)|0,n=n+Math.imul(v,re)|0,a=(a=a+Math.imul(v,ne)|0)+Math.imul(g,re)|0,i=i+Math.imul(g,ne)|0,n=n+Math.imul(h,ie)|0,a=(a=a+Math.imul(h,oe)|0)+Math.imul(p,ie)|0,i=i+Math.imul(p,oe)|0;var _e=(f+(n=n+Math.imul(u,se)|0)|0)+((8191&(a=(a=a+Math.imul(u,fe)|0)+Math.imul(l,se)|0))<<13)|0;f=((i=i+Math.imul(l,fe)|0)+(a>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(B,z),a=(a=Math.imul(B,H))+Math.imul(L,z)|0,i=Math.imul(L,H),n=n+Math.imul(C,J)|0,a=(a=a+Math.imul(C,V)|0)+Math.imul(R,J)|0,i=i+Math.imul(R,V)|0,n=n+Math.imul(T,X)|0,a=(a=a+Math.imul(T,K)|0)+Math.imul(j,X)|0,i=i+Math.imul(j,K)|0,n=n+Math.imul(E,Z)|0,a=(a=a+Math.imul(E,$)|0)+Math.imul(O,Z)|0,i=i+Math.imul(O,$)|0,n=n+Math.imul(_,Y)|0,a=(a=a+Math.imul(_,ee)|0)+Math.imul(M,Y)|0,i=i+Math.imul(M,ee)|0,n=n+Math.imul(y,re)|0,a=(a=a+Math.imul(y,ne)|0)+Math.imul(w,re)|0,i=i+Math.imul(w,ne)|0,n=n+Math.imul(v,ie)|0,a=(a=a+Math.imul(v,oe)|0)+Math.imul(g,ie)|0,i=i+Math.imul(g,oe)|0,n=n+Math.imul(h,se)|0,a=(a=a+Math.imul(h,fe)|0)+Math.imul(p,se)|0,i=i+Math.imul(p,fe)|0;var Me=(f+(n=n+Math.imul(u,ue)|0)|0)+((8191&(a=(a=a+Math.imul(u,le)|0)+Math.imul(l,ue)|0))<<13)|0;f=((i=i+Math.imul(l,le)|0)+(a>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,z),a=(a=Math.imul(F,H))+Math.imul(D,z)|0,i=Math.imul(D,H),n=n+Math.imul(B,J)|0,a=(a=a+Math.imul(B,V)|0)+Math.imul(L,J)|0,i=i+Math.imul(L,V)|0,n=n+Math.imul(C,X)|0,a=(a=a+Math.imul(C,K)|0)+Math.imul(R,X)|0,i=i+Math.imul(R,K)|0,n=n+Math.imul(T,Z)|0,a=(a=a+Math.imul(T,$)|0)+Math.imul(j,Z)|0,i=i+Math.imul(j,$)|0,n=n+Math.imul(E,Y)|0,a=(a=a+Math.imul(E,ee)|0)+Math.imul(O,Y)|0,i=i+Math.imul(O,ee)|0,n=n+Math.imul(_,re)|0,a=(a=a+Math.imul(_,ne)|0)+Math.imul(M,re)|0,i=i+Math.imul(M,ne)|0,n=n+Math.imul(y,ie)|0,a=(a=a+Math.imul(y,oe)|0)+Math.imul(w,ie)|0,i=i+Math.imul(w,oe)|0,n=n+Math.imul(v,se)|0,a=(a=a+Math.imul(v,fe)|0)+Math.imul(g,se)|0,i=i+Math.imul(g,fe)|0,n=n+Math.imul(h,ue)|0,a=(a=a+Math.imul(h,le)|0)+Math.imul(p,ue)|0,i=i+Math.imul(p,le)|0;var Se=(f+(n=n+Math.imul(u,he)|0)|0)+((8191&(a=(a=a+Math.imul(u,pe)|0)+Math.imul(l,he)|0))<<13)|0;f=((i=i+Math.imul(l,pe)|0)+(a>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(F,J),a=(a=Math.imul(F,V))+Math.imul(D,J)|0,i=Math.imul(D,V),n=n+Math.imul(B,X)|0,a=(a=a+Math.imul(B,K)|0)+Math.imul(L,X)|0,i=i+Math.imul(L,K)|0,n=n+Math.imul(C,Z)|0,a=(a=a+Math.imul(C,$)|0)+Math.imul(R,Z)|0,i=i+Math.imul(R,$)|0,n=n+Math.imul(T,Y)|0,a=(a=a+Math.imul(T,ee)|0)+Math.imul(j,Y)|0,i=i+Math.imul(j,ee)|0,n=n+Math.imul(E,re)|0,a=(a=a+Math.imul(E,ne)|0)+Math.imul(O,re)|0,i=i+Math.imul(O,ne)|0,n=n+Math.imul(_,ie)|0,a=(a=a+Math.imul(_,oe)|0)+Math.imul(M,ie)|0,i=i+Math.imul(M,oe)|0,n=n+Math.imul(y,se)|0,a=(a=a+Math.imul(y,fe)|0)+Math.imul(w,se)|0,i=i+Math.imul(w,fe)|0,n=n+Math.imul(v,ue)|0,a=(a=a+Math.imul(v,le)|0)+Math.imul(g,ue)|0,i=i+Math.imul(g,le)|0;var Ee=(f+(n=n+Math.imul(h,he)|0)|0)+((8191&(a=(a=a+Math.imul(h,pe)|0)+Math.imul(p,he)|0))<<13)|0;f=((i=i+Math.imul(p,pe)|0)+(a>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,X),a=(a=Math.imul(F,K))+Math.imul(D,X)|0,i=Math.imul(D,K),n=n+Math.imul(B,Z)|0,a=(a=a+Math.imul(B,$)|0)+Math.imul(L,Z)|0,i=i+Math.imul(L,$)|0,n=n+Math.imul(C,Y)|0,a=(a=a+Math.imul(C,ee)|0)+Math.imul(R,Y)|0,i=i+Math.imul(R,ee)|0,n=n+Math.imul(T,re)|0,a=(a=a+Math.imul(T,ne)|0)+Math.imul(j,re)|0,i=i+Math.imul(j,ne)|0,n=n+Math.imul(E,ie)|0,a=(a=a+Math.imul(E,oe)|0)+Math.imul(O,ie)|0,i=i+Math.imul(O,oe)|0,n=n+Math.imul(_,se)|0,a=(a=a+Math.imul(_,fe)|0)+Math.imul(M,se)|0,i=i+Math.imul(M,fe)|0,n=n+Math.imul(y,ue)|0,a=(a=a+Math.imul(y,le)|0)+Math.imul(w,ue)|0,i=i+Math.imul(w,le)|0;var Oe=(f+(n=n+Math.imul(v,he)|0)|0)+((8191&(a=(a=a+Math.imul(v,pe)|0)+Math.imul(g,he)|0))<<13)|0;f=((i=i+Math.imul(g,pe)|0)+(a>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,Z),a=(a=Math.imul(F,$))+Math.imul(D,Z)|0,i=Math.imul(D,$),n=n+Math.imul(B,Y)|0,a=(a=a+Math.imul(B,ee)|0)+Math.imul(L,Y)|0,i=i+Math.imul(L,ee)|0,n=n+Math.imul(C,re)|0,a=(a=a+Math.imul(C,ne)|0)+Math.imul(R,re)|0,i=i+Math.imul(R,ne)|0,n=n+Math.imul(T,ie)|0,a=(a=a+Math.imul(T,oe)|0)+Math.imul(j,ie)|0,i=i+Math.imul(j,oe)|0,n=n+Math.imul(E,se)|0,a=(a=a+Math.imul(E,fe)|0)+Math.imul(O,se)|0,i=i+Math.imul(O,fe)|0,n=n+Math.imul(_,ue)|0,a=(a=a+Math.imul(_,le)|0)+Math.imul(M,ue)|0,i=i+Math.imul(M,le)|0;var Ae=(f+(n=n+Math.imul(y,he)|0)|0)+((8191&(a=(a=a+Math.imul(y,pe)|0)+Math.imul(w,he)|0))<<13)|0;f=((i=i+Math.imul(w,pe)|0)+(a>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(F,Y),a=(a=Math.imul(F,ee))+Math.imul(D,Y)|0,i=Math.imul(D,ee),n=n+Math.imul(B,re)|0,a=(a=a+Math.imul(B,ne)|0)+Math.imul(L,re)|0,i=i+Math.imul(L,ne)|0,n=n+Math.imul(C,ie)|0,a=(a=a+Math.imul(C,oe)|0)+Math.imul(R,ie)|0,i=i+Math.imul(R,oe)|0,n=n+Math.imul(T,se)|0,a=(a=a+Math.imul(T,fe)|0)+Math.imul(j,se)|0,i=i+Math.imul(j,fe)|0,n=n+Math.imul(E,ue)|0,a=(a=a+Math.imul(E,le)|0)+Math.imul(O,ue)|0,i=i+Math.imul(O,le)|0;var Te=(f+(n=n+Math.imul(_,he)|0)|0)+((8191&(a=(a=a+Math.imul(_,pe)|0)+Math.imul(M,he)|0))<<13)|0;f=((i=i+Math.imul(M,pe)|0)+(a>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,re),a=(a=Math.imul(F,ne))+Math.imul(D,re)|0,i=Math.imul(D,ne),n=n+Math.imul(B,ie)|0,a=(a=a+Math.imul(B,oe)|0)+Math.imul(L,ie)|0,i=i+Math.imul(L,oe)|0,n=n+Math.imul(C,se)|0,a=(a=a+Math.imul(C,fe)|0)+Math.imul(R,se)|0,i=i+Math.imul(R,fe)|0,n=n+Math.imul(T,ue)|0,a=(a=a+Math.imul(T,le)|0)+Math.imul(j,ue)|0,i=i+Math.imul(j,le)|0;var je=(f+(n=n+Math.imul(E,he)|0)|0)+((8191&(a=(a=a+Math.imul(E,pe)|0)+Math.imul(O,he)|0))<<13)|0;f=((i=i+Math.imul(O,pe)|0)+(a>>>13)|0)+(je>>>26)|0,je&=67108863,n=Math.imul(F,ie),a=(a=Math.imul(F,oe))+Math.imul(D,ie)|0,i=Math.imul(D,oe),n=n+Math.imul(B,se)|0,a=(a=a+Math.imul(B,fe)|0)+Math.imul(L,se)|0,i=i+Math.imul(L,fe)|0,n=n+Math.imul(C,ue)|0,a=(a=a+Math.imul(C,le)|0)+Math.imul(R,ue)|0,i=i+Math.imul(R,le)|0;var Pe=(f+(n=n+Math.imul(T,he)|0)|0)+((8191&(a=(a=a+Math.imul(T,pe)|0)+Math.imul(j,he)|0))<<13)|0;f=((i=i+Math.imul(j,pe)|0)+(a>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,se),a=(a=Math.imul(F,fe))+Math.imul(D,se)|0,i=Math.imul(D,fe),n=n+Math.imul(B,ue)|0,a=(a=a+Math.imul(B,le)|0)+Math.imul(L,ue)|0,i=i+Math.imul(L,le)|0;var Ce=(f+(n=n+Math.imul(C,he)|0)|0)+((8191&(a=(a=a+Math.imul(C,pe)|0)+Math.imul(R,he)|0))<<13)|0;f=((i=i+Math.imul(R,pe)|0)+(a>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,n=Math.imul(F,ue),a=(a=Math.imul(F,le))+Math.imul(D,ue)|0,i=Math.imul(D,le);var Re=(f+(n=n+Math.imul(B,he)|0)|0)+((8191&(a=(a=a+Math.imul(B,pe)|0)+Math.imul(L,he)|0))<<13)|0;f=((i=i+Math.imul(L,pe)|0)+(a>>>13)|0)+(Re>>>26)|0,Re&=67108863;var Ne=(f+(n=Math.imul(F,he))|0)+((8191&(a=(a=Math.imul(F,pe))+Math.imul(D,he)|0))<<13)|0;return f=((i=Math.imul(D,pe))+(a>>>13)|0)+(Ne>>>26)|0,Ne&=67108863,s[0]=me,s[1]=ve,s[2]=ge,s[3]=xe,s[4]=ye,s[5]=we,s[6]=ke,s[7]=_e,s[8]=Me,s[9]=Se,s[10]=Ee,s[11]=Oe,s[12]=Ae,s[13]=Te,s[14]=je,s[15]=Pe,s[16]=Ce,s[17]=Re,s[18]=Ne,0!==f&&(s[19]=f,r.length++),r};function p(e,t,r){return(new m).mulp(e,t,r)}function m(e,t){this.x=e,this.y=t}Math.imul||(h=b),i.prototype.mulTo=function(e,t){var r=this.length+e.length;return 10===this.length&&10===e.length?h(this,e,t):r<63?b(this,e,t):r<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,a=0,i=0;i>>26)|0)>>>26,o&=67108863}r.words[i]=c,n=o,o=a}return 0!==n?r.words[i]=n:r.length--,r.strip()}(this,e,t):p(this,e,t)},m.prototype.makeRBT=function(e){for(var t=new Array(e),r=i.prototype._countBits(e)-1,n=0;n>=1;return n},m.prototype.permute=function(e,t,r,n,a,i){for(var o=0;o>>=1)a++;return 1<>>=13,r[2*o+1]=8191&i,i>>>=13;for(o=2*t;o>=26,t+=a/67108864|0,t+=i>>>26,this.words[r]=67108863&i}return 0!==t&&(this.words[r]=t,this.length++),this},i.prototype.muln=function(e){return this.clone().imuln(e)},i.prototype.sqr=function(){return this.mul(this)},i.prototype.isqr=function(){return this.imul(this.clone())},i.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>a}return t}(e);if(0===t.length)return new i(1);for(var r=this,n=0;n=0);var t,r=e%26,a=(e-r)/26,i=67108863>>>26-r<<26-r;if(0!==r){var o=0;for(t=0;t>>26-r}o&&(this.words[t]=o,this.length++)}if(0!==a){for(t=this.length-1;t>=0;t--)this.words[t+a]=this.words[t];for(t=0;t=0),a=t?(t-t%26)/26:0;var i=e%26,o=Math.min((e-i)/26,this.length),c=67108863^67108863>>>i<o)for(this.length-=o,f=0;f=0&&(0!==d||f>=a);f--){var u=0|this.words[f];this.words[f]=d<<26-i|u>>>i,d=u&c}return s&&0!==d&&(s.words[s.length++]=d),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},i.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},i.prototype.shln=function(e){return this.clone().ishln(e)},i.prototype.ushln=function(e){return this.clone().iushln(e)},i.prototype.shrn=function(e){return this.clone().ishrn(e)},i.prototype.ushrn=function(e){return this.clone().iushrn(e)},i.prototype.testn=function(e){n("number"===typeof e&&e>=0);var t=e%26,r=(e-t)/26,a=1<=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var a=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},i.prototype.isubn=function(e){if(n("number"===typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(s/67108864|0),this.words[a+r]=67108863&i}for(;a>26,this.words[a+r]=67108863&i;if(0===c)return this.strip();for(n(-1===c),c=0,a=0;a>26,this.words[a]=67108863&i;return this.negative=1,this.strip()},i.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),a=e,o=0|a.words[a.length-1];0!==(r=26-this._countBits(o))&&(a=a.ushln(r),n.iushln(r),o=0|a.words[a.length-1]);var c,s=n.length-a.length;if("mod"!==t){(c=new i(null)).length=s+1,c.words=new Array(c.length);for(var f=0;f=0;u--){var l=67108864*(0|n.words[a.length+u])+(0|n.words[a.length+u-1]);for(l=Math.min(l/o|0,67108863),n._ishlnsubmul(a,l,u);0!==n.negative;)l--,n.negative=0,n._ishlnsubmul(a,1,u),n.isZero()||(n.negative^=1);c&&(c.words[u]=l)}return c&&c.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:c||null,mod:n}},i.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new i(0),mod:new i(0)}:0!==this.negative&&0===e.negative?(c=this.neg().divmod(e,t),"mod"!==t&&(a=c.div.neg()),"div"!==t&&(o=c.mod.neg(),r&&0!==o.negative&&o.iadd(e)),{div:a,mod:o}):0===this.negative&&0!==e.negative?(c=this.divmod(e.neg(),t),"mod"!==t&&(a=c.div.neg()),{div:a,mod:c.mod}):0!==(this.negative&e.negative)?(c=this.neg().divmod(e.neg(),t),"div"!==t&&(o=c.mod.neg(),r&&0!==o.negative&&o.isub(e)),{div:c.div,mod:o}):e.length>this.length||this.cmp(e)<0?{div:new i(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new i(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new i(this.modn(e.words[0]))}:this._wordDiv(e,t);var a,o,c},i.prototype.div=function(e){return this.divmod(e,"div",!1).div},i.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},i.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},i.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),a=e.andln(1),i=r.cmp(n);return i<0||1===a&&0===i?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},i.prototype.modn=function(e){n(e<=67108863);for(var t=(1<<26)%e,r=0,a=this.length-1;a>=0;a--)r=(t*r+(0|this.words[a]))%e;return r},i.prototype.idivn=function(e){n(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var a=(0|this.words[r])+67108864*t;this.words[r]=a/e|0,t=a%e}return this.strip()},i.prototype.divn=function(e){return this.clone().idivn(e)},i.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var a=new i(1),o=new i(0),c=new i(0),s=new i(1),f=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++f;for(var d=r.clone(),u=t.clone();!t.isZero();){for(var l=0,b=1;0===(t.words[0]&b)&&l<26;++l,b<<=1);if(l>0)for(t.iushrn(l);l-- >0;)(a.isOdd()||o.isOdd())&&(a.iadd(d),o.isub(u)),a.iushrn(1),o.iushrn(1);for(var h=0,p=1;0===(r.words[0]&p)&&h<26;++h,p<<=1);if(h>0)for(r.iushrn(h);h-- >0;)(c.isOdd()||s.isOdd())&&(c.iadd(d),s.isub(u)),c.iushrn(1),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(c),o.isub(s)):(r.isub(t),c.isub(a),s.isub(o))}return{a:c,b:s,gcd:r.iushln(f)}},i.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var a,o=new i(1),c=new i(0),s=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var f=0,d=1;0===(t.words[0]&d)&&f<26;++f,d<<=1);if(f>0)for(t.iushrn(f);f-- >0;)o.isOdd()&&o.iadd(s),o.iushrn(1);for(var u=0,l=1;0===(r.words[0]&l)&&u<26;++u,l<<=1);if(u>0)for(r.iushrn(u);u-- >0;)c.isOdd()&&c.iadd(s),c.iushrn(1);t.cmp(r)>=0?(t.isub(r),o.isub(c)):(r.isub(t),c.isub(o))}return(a=0===t.cmpn(1)?o:c).cmpn(0)<0&&a.iadd(e),a},i.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var a=t.cmp(r);if(a<0){var i=t;t=r,r=i}else if(0===a||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},i.prototype.invm=function(e){return this.egcd(e).a.umod(e)},i.prototype.isEven=function(){return 0===(1&this.words[0])},i.prototype.isOdd=function(){return 1===(1&this.words[0])},i.prototype.andln=function(e){return this.words[0]&e},i.prototype.bincn=function(e){n("number"===typeof e);var t=e%26,r=(e-t)/26,a=1<>>26,c&=67108863,this.words[o]=c}return 0!==i&&(this.words[o]=i,this.length++),this},i.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},i.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var a=0|this.words[0];t=a===e?0:ae.length)return 1;if(this.length=0;r--){var n=0|this.words[r],a=0|e.words[r];if(n!==a){na&&(t=1);break}}return t},i.prototype.gtn=function(e){return 1===this.cmpn(e)},i.prototype.gt=function(e){return 1===this.cmp(e)},i.prototype.gten=function(e){return this.cmpn(e)>=0},i.prototype.gte=function(e){return this.cmp(e)>=0},i.prototype.ltn=function(e){return-1===this.cmpn(e)},i.prototype.lt=function(e){return-1===this.cmp(e)},i.prototype.lten=function(e){return this.cmpn(e)<=0},i.prototype.lte=function(e){return this.cmp(e)<=0},i.prototype.eqn=function(e){return 0===this.cmpn(e)},i.prototype.eq=function(e){return 0===this.cmp(e)},i.red=function(e){return new _(e)},i.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},i.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},i.prototype._forceRed=function(e){return this.red=e,this},i.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},i.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},i.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},i.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},i.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},i.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},i.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},i.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},i.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},i.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},i.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},i.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},i.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},i.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var v={k256:null,p224:null,p192:null,p25519:null};function g(e,t){this.name=e,this.p=new i(t,16),this.n=this.p.bitLength(),this.k=new i(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function x(){g.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function y(){g.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function w(){g.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function k(){g.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function _(e){if("string"===typeof e){var t=i._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function M(e){_.call(this,e),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new i(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}g.prototype._tmp=function(){var e=new i(null);return e.words=new Array(Math.ceil(this.n/13)),e},g.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},g.prototype.split=function(e,t){e.iushrn(this.n,0,t)},g.prototype.imulK=function(e){return e.imul(this.k)},a(x,g),x.prototype.split=function(e,t){for(var r=Math.min(e.length,9),n=0;n>>22,a=i}a>>>=22,e.words[n-10]=a,0===a&&e.length>10?e.length-=10:e.length-=9},x.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=a,t=n}return 0!==t&&(e.words[e.length++]=t),e},i._prime=function(e){if(v[e])return v[e];var t;if("k256"===e)t=new x;else if("p224"===e)t=new y;else if("p192"===e)t=new w;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new k}return v[e]=t,t},_.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},_.prototype._verify2=function(e,t){n(0===(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},_.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},_.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},_.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},_.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},_.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},_.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},_.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},_.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},_.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},_.prototype.isqr=function(e){return this.imul(e,e.clone())},_.prototype.sqr=function(e){return this.mul(e,e)},_.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2===1),3===t){var r=this.m.add(new i(1)).iushrn(2);return this.pow(e,r)}for(var a=this.m.subn(1),o=0;!a.isZero()&&0===a.andln(1);)o++,a.iushrn(1);n(!a.isZero());var c=new i(1).toRed(this),s=c.redNeg(),f=this.m.subn(1).iushrn(1),d=this.m.bitLength();for(d=new i(2*d*d).toRed(this);0!==this.pow(d,f).cmp(s);)d.redIAdd(s);for(var u=this.pow(d,a),l=this.pow(e,a.addn(1).iushrn(1)),b=this.pow(e,a),h=o;0!==b.cmp(c);){for(var p=b,m=0;0!==p.cmp(c);m++)p=p.redSqr();n(m=0;n--){for(var f=t.words[n],d=s-1;d>=0;d--){var u=f>>d&1;a!==r[0]&&(a=this.sqr(a)),0!==u||0!==o?(o<<=1,o|=u,(4===++c||0===n&&0===d)&&(a=this.mul(a,r[o]),c=0,o=0)):c=0}s=26}return a},_.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},_.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},i.mont=function(e){return new M(e)},a(M,_),M.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},M.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},M.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),a=r.isub(n).iushrn(this.shift),i=a;return a.cmp(this.m)>=0?i=a.isub(this.m):a.cmpn(0)<0&&(i=a.iadd(this.m)),i._forceRed(this)},M.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new i(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),a=r.isub(n).iushrn(this.shift),o=a;return a.cmp(this.m)>=0?o=a.isub(this.m):a.cmpn(0)<0&&(o=a.iadd(this.m)),o._forceRed(this)},M.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e,this)}).call(this,r(74)(e))},function(e,t,r){"use strict";var n=r(663).Buffer,a=n.isEncoding||function(e){switch((e=""+e)&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function i(e){var t;switch(this.encoding=function(e){var t=function(e){if(!e)return"utf8";for(var t;;)switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}(e);if("string"!==typeof t&&(n.isEncoding===a||!a(e)))throw new Error("Unknown encoding: "+e);return t||e}(e),this.encoding){case"utf16le":this.text=s,this.end=f,t=4;break;case"utf8":this.fillLast=c,t=4;break;case"base64":this.text=d,this.end=u,t=3;break;default:return this.write=l,void(this.end=b)}this.lastNeed=0,this.lastTotal=0,this.lastChar=n.allocUnsafe(t)}function o(e){return e<=127?0:e>>5===6?2:e>>4===14?3:e>>3===30?4:e>>6===2?-1:-2}function c(e){var t=this.lastTotal-this.lastNeed,r=function(e,t,r){if(128!==(192&t[0]))return e.lastNeed=0,"\ufffd";if(e.lastNeed>1&&t.length>1){if(128!==(192&t[1]))return e.lastNeed=1,"\ufffd";if(e.lastNeed>2&&t.length>2&&128!==(192&t[2]))return e.lastNeed=2,"\ufffd"}}(this,e);return void 0!==r?r:this.lastNeed<=e.length?(e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(e.copy(this.lastChar,t,0,e.length),void(this.lastNeed-=e.length))}function s(e,t){if((e.length-t)%2===0){var r=e.toString("utf16le",t);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function f(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}function d(e,t){var r=(e.length-t)%3;return 0===r?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,1===r?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}function u(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function l(e){return e.toString(this.encoding)}function b(e){return e&&e.length?this.write(e):""}t.StringDecoder=i,i.prototype.write=function(e){if(0===e.length)return"";var t,r;if(this.lastNeed){if(void 0===(t=this.fillLast(e)))return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r=0)return a>0&&(e.lastNeed=a-1),a;if(--n=0)return a>0&&(e.lastNeed=a-2),a;if(--n=0)return a>0&&(2===a?a=0:e.lastNeed=a-3),a;return 0}(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var n=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,n),e.toString("utf8",t,n)},i.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length}},function(e,t,r){"use strict";r.d(t,"d",(function(){return a})),r.d(t,"h",(function(){return i})),r.d(t,"e",(function(){return o})),r.d(t,"f",(function(){return c})),r.d(t,"g",(function(){return s})),r.d(t,"b",(function(){return f})),r.d(t,"c",(function(){return d})),r.d(t,"a",(function(){return u}));var n=r(51),a=n.a.from(-1),i=n.a.from(0),o=n.a.from(1),c=n.a.from(2),s=n.a.from("1000000000000000000"),f=n.a.from("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"),d=n.a.from("-0x8000000000000000000000000000000000000000000000000000000000000000"),u=n.a.from("0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff")},function(e,t,r){"use strict";var n=r(295),a=r(130),i=r(87),o=r(88);Object.defineProperty(t,"__esModule",{value:!0});var c=r(950),s=r(134),f=function(){function e(t,r,n){i(this,e),this.name=t,this.prefix=r,this.baseEncode=n}return o(e,[{key:"encode",value:function(e){if(e instanceof Uint8Array)return"".concat(this.prefix).concat(this.baseEncode(e));throw Error("Unknown type, must be binary type")}}]),e}(),d=function(){function e(t,r,n){i(this,e),this.name=t,this.prefix=r,this.baseDecode=n}return o(e,[{key:"decode",value:function(e){if("string"!==typeof e)throw Error("Can only multibase decode strings");switch(e[0]){case this.prefix:return this.baseDecode(e.slice(1));default:throw Error("Unable to decode multibase string ".concat(JSON.stringify(e),", ").concat(this.name," decoder only supports inputs prefixed with ").concat(this.prefix))}}},{key:"or",value:function(e){return l(this,e)}}]),e}(),u=function(){function e(t){i(this,e),this.decoders=t}return o(e,[{key:"or",value:function(e){return l(this,e)}},{key:"decode",value:function(e){var t=e[0],r=this.decoders[t];if(r)return r.decode(e);throw RangeError("Unable to decode multibase string ".concat(JSON.stringify(e),", only inputs prefixed with ").concat(Object.keys(this.decoders)," are supported"))}}]),e}(),l=function(e,t){return new u(a(a({},e.decoders||n({},e.prefix,e)),t.decoders||n({},t.prefix,t)))},b=function(){function e(t,r,n,a){i(this,e),this.name=t,this.prefix=r,this.baseEncode=n,this.baseDecode=a,this.encoder=new f(t,r,n),this.decoder=new d(t,r,a)}return o(e,[{key:"encode",value:function(e){return this.encoder.encode(e)}},{key:"decode",value:function(e){return this.decoder.decode(e)}}]),e}(),h=function(e){var t=e.name,r=e.prefix,n=e.encode,a=e.decode;return new b(t,r,n,a)};t.Codec=b,t.baseX=function(e){var t=e.prefix,r=e.name,n=e.alphabet,a=c(n,r),i=a.encode,o=a.decode;return h({prefix:t,name:r,encode:i,decode:function(e){return s.coerce(o(e))}})},t.from=h,t.or=l,t.rfc4648=function(e){var t=e.name,r=e.prefix,n=e.bitsPerChar,a=e.alphabet;return h({prefix:r,name:t,encode:function(e){return function(e,t,r){for(var n="="===t[t.length-1],a=(1<r;)i+=t[a&c>>(o-=r)];if(o&&(i+=t[a&c<=8&&(s-=8,c[d++]=255&f>>s)}if(s>=r||255&f<<8-s)throw new SyntaxError("Unexpected end of data");return c}(e,a,n,t)}})}},function(e,t){e.exports=function(e){return null!=e&&"object"==typeof e}},function(e,t,r){"use strict";t.a=function(e,t){}},function(e,t,r){"use strict";r.r(t),r.d(t,"commify",(function(){return M})),r.d(t,"formatUnits",(function(){return S})),r.d(t,"parseUnits",(function(){return E})),r.d(t,"formatEther",(function(){return O})),r.d(t,"parseEther",(function(){return A}));var n=r(6),a=r(7),i=r(5),o=r(11),c=r(265),s=r(46),f=new o.a(c.a),d={},u=s.a.from(0),l=s.a.from(-1);function b(e,t,r,n){var a={fault:t,operation:r};return void 0!==n&&(a.value=n),f.throwError(e,o.a.errors.NUMERIC_FAULT,a)}for(var h="0";h.length<256;)h+=h;function p(e){if("number"!==typeof e)try{e=s.a.from(e).toNumber()}catch(t){}return"number"===typeof e&&e>=0&&e<=256&&!(e%1)?"1"+h.substring(0,e):f.throwArgumentError("invalid decimal size","decimals",e)}function m(e,t){null==t&&(t=0);var r=p(t),n=(e=s.a.from(e)).lt(u);n&&(e=e.mul(l));for(var a=e.mod(r).toString();a.length2&&f.throwArgumentError("too many decimal points","value",e);var i=a[0],o=a[1];for(i||(i="0"),o||(o="0");"0"===o[o.length-1];)o=o.substring(0,o.length-1);for(o.length>r.length-1&&b("fractional component exceeds decimals","underflow","parseFixed"),""===o&&(o="0");o.length80&&f.throwArgumentError("invalid fixed format (decimals too large)","format.decimals",a),new e(d,r,n,a)}}]),e}(),x=function(){function e(t,r,a,i){Object(n.a)(this,e),f.checkNew(this instanceof e?this.constructor:void 0,e),t!==d&&f.throwError("cannot use FixedNumber constructor; use FixedNumber.from",o.a.errors.UNSUPPORTED_OPERATION,{operation:"new FixedFormat"}),this.format=i,this._hex=r,this._value=a,this._isFixedNumber=!0,Object.freeze(this)}return Object(a.a)(e,[{key:"_checkFormat",value:function(e){this.format.name!==e.format.name&&f.throwArgumentError("incompatible format; use fixedNumber.toFormat","other",e)}},{key:"addUnsafe",value:function(t){this._checkFormat(t);var r=v(this._value,this.format.decimals),n=v(t._value,t.format.decimals);return e.fromValue(r.add(n),this.format.decimals,this.format)}},{key:"subUnsafe",value:function(t){this._checkFormat(t);var r=v(this._value,this.format.decimals),n=v(t._value,t.format.decimals);return e.fromValue(r.sub(n),this.format.decimals,this.format)}},{key:"mulUnsafe",value:function(t){this._checkFormat(t);var r=v(this._value,this.format.decimals),n=v(t._value,t.format.decimals);return e.fromValue(r.mul(n).div(this.format._multiplier),this.format.decimals,this.format)}},{key:"divUnsafe",value:function(t){this._checkFormat(t);var r=v(this._value,this.format.decimals),n=v(t._value,t.format.decimals);return e.fromValue(r.mul(this.format._multiplier).div(n),this.format.decimals,this.format)}},{key:"floor",value:function(){var t=this.toString().split(".");1===t.length&&t.push("0");var r=e.from(t[0],this.format),n=!t[1].match(/^(0*)$/);return this.isNegative()&&n&&(r=r.subUnsafe(y.toFormat(r.format))),r}},{key:"ceiling",value:function(){var t=this.toString().split(".");1===t.length&&t.push("0");var r=e.from(t[0],this.format),n=!t[1].match(/^(0*)$/);return!this.isNegative()&&n&&(r=r.addUnsafe(y.toFormat(r.format))),r}},{key:"round",value:function(t){null==t&&(t=0);var r=this.toString().split(".");if(1===r.length&&r.push("0"),(t<0||t>80||t%1)&&f.throwArgumentError("invalid decimal count","decimals",t),r[1].length<=t)return this;var n=e.from("1"+h.substring(0,t),this.format),a=w.toFormat(this.format);return this.mulUnsafe(n).addUnsafe(a).floor().divUnsafe(n)}},{key:"isZero",value:function(){return"0.0"===this._value||"0"===this._value}},{key:"isNegative",value:function(){return"-"===this._value[0]}},{key:"toString",value:function(){return this._value}},{key:"toHexString",value:function(e){if(null==e)return this._hex;e%8&&f.throwArgumentError("invalid byte width","width",e);var t=s.a.from(this._hex).fromTwos(this.format.width).toTwos(e).toHexString();return Object(i.g)(t,e/8)}},{key:"toUnsafeFloat",value:function(){return parseFloat(this.toString())}},{key:"toFormat",value:function(t){return e.fromString(this._value,t)}}],[{key:"fromValue",value:function(t,r,n){return null!=n||null==r||Object(s.d)(r)||(n=r,r=null),null==r&&(r=0),null==n&&(n="fixed"),e.fromString(m(t,r),g.from(n))}},{key:"fromString",value:function(t,r){null==r&&(r="fixed");var n=g.from(r),a=v(t,n.decimals);!n.signed&&a.lt(u)&&b("unsigned value cannot be negative","overflow","value",t);var o=null;n.signed?o=a.toTwos(n.width).toHexString():(o=a.toHexString(),o=Object(i.g)(o,n.width/8));var c=m(a,n.decimals);return new e(d,o,c,n)}},{key:"fromBytes",value:function(t,r){null==r&&(r="fixed");var n=g.from(r);if(Object(i.a)(t).length>n.width/8)throw new Error("overflow");var a=s.a.from(t);n.signed&&(a=a.fromTwos(n.width));var o=a.toTwos((n.signed?0:1)+n.width).toHexString(),c=m(a,n.decimals);return new e(d,o,c,n)}},{key:"from",value:function(t,r){if("string"===typeof t)return e.fromString(t,r);if(Object(i.i)(t))return e.fromBytes(t,r);try{return e.fromValue(t,0,r)}catch(n){if(n.code!==o.a.errors.INVALID_ARGUMENT)throw n}return f.throwArgumentError("invalid FixedNumber value","value",t)}},{key:"isFixedNumber",value:function(e){return!(!e||!e._isFixedNumber)}}]),e}(),y=x.from(1),w=x.from("0.5"),k=new o.a("units/5.3.0"),_=["wei","kwei","mwei","gwei","szabo","finney","ether"];function M(e){var t=String(e).split(".");(t.length>2||!t[0].match(/^-?[0-9]*$/)||t[1]&&!t[1].match(/^[0-9]*$/)||"."===e||"-."===e)&&k.throwArgumentError("invalid value","value",e);var r=t[0],n="";for("-"===r.substring(0,1)&&(n="-",r=r.substring(1));"0"===r.substring(0,1);)r=r.substring(1);""===r&&(r="0");var a="";for(2===t.length&&(a="."+(t[1]||"0"));a.length>2&&"0"===a[a.length-1];)a=a.substring(0,a.length-1);for(var i=[];r.length;){if(r.length<=3){i.unshift(r);break}var o=r.length-3;i.unshift(r.substring(o)),r=r.substring(0,o)}return n+i.join(",")+a}function S(e,t){if("string"===typeof t){var r=_.indexOf(t);-1!==r&&(t=3*r)}return m(e,null!=t?t:18)}function E(e,t){if("string"!==typeof e&&k.throwArgumentError("value must be a string","value",e),"string"===typeof t){var r=_.indexOf(t);-1!==r&&(t=3*r)}return v(e,null!=t?t:18)}function O(e){return S(e,18)}function A(e){return E(e,18)}},function(e,t,r){"use strict";r.d(t,"a",(function(){return se}));var n=r(20),a=r(13),i=r(14),o=r(2),c=r.n(o),s=r(6),f=r(7),d=r(97),u=r(193),l=r(46),b=r(5),h=r(1163),p=r(86);function m(e,t){t||(t=function(e){return[parseInt(e,16)]});var r=0,n={};return e.split(",").forEach((function(e){var a=e.split(":");r+=parseInt(a[0],16),n[r]=t(a[1])})),n}function v(e){var t=0;return e.split(",").map((function(e){var r=e.split("-");return 1===r.length?r[1]="0":""===r[1]&&(r[1]="1"),{l:t+parseInt(r[0],16),h:t=parseInt(r[1],16)}}))}function g(e,t){for(var r=0,n=0;n=(r+=a.l)&&e<=r+a.h&&(e-r)%(a.d||1)===0){if(a.e&&-1!==a.e.indexOf(e-r))continue;return a}}return null}var x=v("221,13-1b,5f-,40-10,51-f,11-3,3-3,2-2,2-4,8,2,15,2d,28-8,88,48,27-,3-5,11-20,27-,8,28,3-5,12,18,b-a,1c-4,6-16,2-d,2-2,2,1b-4,17-9,8f-,10,f,1f-2,1c-34,33-14e,4,36-,13-,6-2,1a-f,4,9-,3-,17,8,2-2,5-,2,8-,3-,4-8,2-3,3,6-,16-6,2-,7-3,3-,17,8,3,3,3-,2,6-3,3-,4-a,5,2-6,10-b,4,8,2,4,17,8,3,6-,b,4,4-,2-e,2-4,b-10,4,9-,3-,17,8,3-,5-,9-2,3-,4-7,3-3,3,4-3,c-10,3,7-2,4,5-2,3,2,3-2,3-2,4-2,9,4-3,6-2,4,5-8,2-e,d-d,4,9,4,18,b,6-3,8,4,5-6,3-8,3-3,b-11,3,9,4,18,b,6-3,8,4,5-6,3-6,2,3-3,b-11,3,9,4,18,11-3,7-,4,5-8,2-7,3-3,b-11,3,13-2,19,a,2-,8-2,2-3,7,2,9-11,4-b,3b-3,1e-24,3,2-,3,2-,2-5,5,8,4,2,2-,3,e,4-,6,2,7-,b-,3-21,49,23-5,1c-3,9,25,10-,2-2f,23,6,3,8-2,5-5,1b-45,27-9,2a-,2-3,5b-4,45-4,53-5,8,40,2,5-,8,2,5-,28,2,5-,20,2,5-,8,2,5-,8,8,18,20,2,5-,8,28,14-5,1d-22,56-b,277-8,1e-2,52-e,e,8-a,18-8,15-b,e,4,3-b,5e-2,b-15,10,b-5,59-7,2b-555,9d-3,5b-5,17-,7-,27-,7-,9,2,2,2,20-,36,10,f-,7,14-,4,a,54-3,2-6,6-5,9-,1c-10,13-1d,1c-14,3c-,10-6,32-b,240-30,28-18,c-14,a0,115-,3,66-,b-76,5,5-,1d,24,2,5-2,2,8-,35-2,19,f-10,1d-3,311-37f,1b,5a-b,d7-19,d-3,41,57-,68-4,29-3,5f,29-37,2e-2,25-c,2c-2,4e-3,30,78-3,64-,20,19b7-49,51a7-59,48e-2,38-738,2ba5-5b,222f-,3c-94,8-b,6-4,1b,6,2,3,3,6d-20,16e-f,41-,37-7,2e-2,11-f,5-b,18-,b,14,5-3,6,88-,2,bf-2,7-,7-,7-,4-2,8,8-9,8-2ff,20,5-b,1c-b4,27-,27-cbb1,f7-9,28-2,b5-221,56,48,3-,2-,3-,5,d,2,5,3,42,5-,9,8,1d,5,6,2-2,8,153-3,123-3,33-27fd,a6da-5128,21f-5df,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3,2-1d,61-ff7d"),y="ad,34f,1806,180b,180c,180d,200b,200c,200d,2060,feff".split(",").map((function(e){return parseInt(e,16)})),w=[{h:25,s:32,l:65},{h:30,s:32,e:[23],l:127},{h:54,s:1,e:[48],l:64,d:2},{h:14,s:1,l:57,d:2},{h:44,s:1,l:17,d:2},{h:10,s:1,e:[2,6,8],l:61,d:2},{h:16,s:1,l:68,d:2},{h:84,s:1,e:[18,24,66],l:19,d:2},{h:26,s:32,e:[17],l:435},{h:22,s:1,l:71,d:2},{h:15,s:80,l:40},{h:31,s:32,l:16},{h:32,s:1,l:80,d:2},{h:52,s:1,l:42,d:2},{h:12,s:1,l:55,d:2},{h:40,s:1,e:[38],l:15,d:2},{h:14,s:1,l:48,d:2},{h:37,s:48,l:49},{h:148,s:1,l:6351,d:2},{h:88,s:1,l:160,d:2},{h:15,s:16,l:704},{h:25,s:26,l:854},{h:25,s:32,l:55915},{h:37,s:40,l:1247},{h:25,s:-119711,l:53248},{h:25,s:-119763,l:52},{h:25,s:-119815,l:52},{h:25,s:-119867,e:[1,4,5,7,8,11,12,17],l:52},{h:25,s:-119919,l:52},{h:24,s:-119971,e:[2,7,8,17],l:52},{h:24,s:-120023,e:[2,7,13,15,16,17],l:52},{h:25,s:-120075,l:52},{h:25,s:-120127,l:52},{h:25,s:-120179,l:52},{h:25,s:-120231,l:52},{h:25,s:-120283,l:52},{h:25,s:-120335,l:52},{h:24,s:-119543,e:[17],l:56},{h:24,s:-119601,e:[17],l:58},{h:24,s:-119659,e:[17],l:58},{h:24,s:-119717,e:[17],l:58},{h:24,s:-119775,e:[17],l:58}],k=m("b5:3bc,c3:ff,7:73,2:253,5:254,3:256,1:257,5:259,1:25b,3:260,1:263,2:269,1:268,5:26f,1:272,2:275,7:280,3:283,5:288,3:28a,1:28b,5:292,3f:195,1:1bf,29:19e,125:3b9,8b:3b2,1:3b8,1:3c5,3:3c6,1:3c0,1a:3ba,1:3c1,1:3c3,2:3b8,1:3b5,1bc9:3b9,1c:1f76,1:1f77,f:1f7a,1:1f7b,d:1f78,1:1f79,1:1f7c,1:1f7d,107:63,5:25b,4:68,1:68,1:68,3:69,1:69,1:6c,3:6e,4:70,1:71,1:72,1:72,1:72,7:7a,2:3c9,2:7a,2:6b,1:e5,1:62,1:63,3:65,1:66,2:6d,b:3b3,1:3c0,6:64,1b574:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3"),_=m("179:1,2:1,2:1,5:1,2:1,a:4f,a:1,8:1,2:1,2:1,3:1,5:1,3:1,4:1,2:1,3:1,4:1,8:2,1:1,2:2,1:1,2:2,27:2,195:26,2:25,1:25,1:25,2:40,2:3f,1:3f,33:1,11:-6,1:-9,1ac7:-3a,6d:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,b:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,c:-8,2:-8,2:-8,2:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,49:-8,1:-8,1:-4a,1:-4a,d:-56,1:-56,1:-56,1:-56,d:-8,1:-8,f:-8,1:-8,3:-7"),M=m("df:00730073,51:00690307,19:02BC006E,a7:006A030C,18a:002003B9,16:03B903080301,20:03C503080301,1d7:05650582,190f:00680331,1:00740308,1:0077030A,1:0079030A,1:006102BE,b6:03C50313,2:03C503130300,2:03C503130301,2:03C503130342,2a:1F0003B9,1:1F0103B9,1:1F0203B9,1:1F0303B9,1:1F0403B9,1:1F0503B9,1:1F0603B9,1:1F0703B9,1:1F0003B9,1:1F0103B9,1:1F0203B9,1:1F0303B9,1:1F0403B9,1:1F0503B9,1:1F0603B9,1:1F0703B9,1:1F2003B9,1:1F2103B9,1:1F2203B9,1:1F2303B9,1:1F2403B9,1:1F2503B9,1:1F2603B9,1:1F2703B9,1:1F2003B9,1:1F2103B9,1:1F2203B9,1:1F2303B9,1:1F2403B9,1:1F2503B9,1:1F2603B9,1:1F2703B9,1:1F6003B9,1:1F6103B9,1:1F6203B9,1:1F6303B9,1:1F6403B9,1:1F6503B9,1:1F6603B9,1:1F6703B9,1:1F6003B9,1:1F6103B9,1:1F6203B9,1:1F6303B9,1:1F6403B9,1:1F6503B9,1:1F6603B9,1:1F6703B9,3:1F7003B9,1:03B103B9,1:03AC03B9,2:03B10342,1:03B1034203B9,5:03B103B9,6:1F7403B9,1:03B703B9,1:03AE03B9,2:03B70342,1:03B7034203B9,5:03B703B9,6:03B903080300,1:03B903080301,3:03B90342,1:03B903080342,b:03C503080300,1:03C503080301,1:03C10313,2:03C50342,1:03C503080342,b:1F7C03B9,1:03C903B9,1:03CE03B9,2:03C90342,1:03C9034203B9,5:03C903B9,ac:00720073,5b:00B00063,6:00B00066,d:006E006F,a:0073006D,1:00740065006C,1:0074006D,124f:006800700061,2:00610075,2:006F0076,b:00700061,1:006E0061,1:03BC0061,1:006D0061,1:006B0061,1:006B0062,1:006D0062,1:00670062,3:00700066,1:006E0066,1:03BC0066,4:0068007A,1:006B0068007A,1:006D0068007A,1:00670068007A,1:00740068007A,15:00700061,1:006B00700061,1:006D00700061,1:006700700061,8:00700076,1:006E0076,1:03BC0076,1:006D0076,1:006B0076,1:006D0076,1:00700077,1:006E0077,1:03BC0077,1:006D0077,1:006B0077,1:006D0077,1:006B03C9,1:006D03C9,2:00620071,3:00632215006B0067,1:0063006F002E,1:00640062,1:00670079,2:00680070,2:006B006B,1:006B006D,9:00700068,2:00700070006D,1:00700072,2:00730076,1:00770062,c723:00660066,1:00660069,1:0066006C,1:006600660069,1:00660066006C,1:00730074,1:00730074,d:05740576,1:05740565,1:0574056B,1:057E0576,1:0574056D",(function(e){if(e.length%4!==0)throw new Error("bad data");for(var t=[],r=0;r=0)return[];if(e>=65024&&e<=65039)return[];var t=function(e){var t=g(e,w);if(t)return[e+t.s];var r=k[e];if(r)return r;var n=_[e];if(n)return[e+n[0]];var a=M[e];return a||null}(e);return t||[e]})),r=t.reduce((function(e,t){return t.forEach((function(t){e.push(t)})),e}),[]),(r=Object(p.d)(Object(p.b)(r),p.a.NFKC)).forEach((function(e){if(g(e,S))throw new Error("STRINGPREP_CONTAINS_PROHIBITED")})),r.forEach((function(e){if(g(e,x))throw new Error("STRINGPREP_CONTAINS_UNASSIGNED")}));var n=Object(p.b)(r);if("-"===n.substring(0,1)||"--"===n.substring(2,4)||"-"===n.substring(n.length-1))throw new Error("invalid hyphen");if(n.length>63)throw new Error("too long");return n}var O=r(40),A=r(11),T=r(267),j=new A.a(T.a),P=new Uint8Array(32);P.fill(0);var C=new RegExp("^((.*)\\.)?([^.]+)$");function R(e){"string"!==typeof e&&j.throwArgumentError("invalid ENS name; not a string","name",e);for(var t=e,r=P;t.length;){var n=t.match(C);null!=n&&""!==n[2]||j.throwArgumentError("invalid ENS address; missing component","name",e);var a=Object(p.c)(E(n[3]));r=Object(O.a)(Object(b.b)([r,Object(O.a)(a)])),t=n[2]||""}return Object(b.h)(r)}var N=r(140),B=r(9),L=r(576),I=r(89),F=r(192),D=r.n(F),U=r(52),z=r(79),H=function(e,t,r,n){return new(r||(r=Promise))((function(a,i){function o(e){try{s(n.next(e))}catch(t){i(t)}}function c(e){try{s(n.throw(e))}catch(t){i(t)}}function s(e){var t;e.done?a(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(o,c)}s((n=n.apply(e,t||[])).next())}))},q=new A.a(U.a);function J(e){return null==e?"null":(32!==Object(b.d)(e)&&q.throwArgumentError("invalid topic","topic",e),e.toLowerCase())}function V(e){for(e=e.slice();e.length>0&&null==e[e.length-1];)e.pop();return e.map((function(e){if(Array.isArray(e)){var t={};e.forEach((function(e){t[J(e)]=!0}));var r=Object.keys(t);return r.sort(),r.join("|")}return J(e)})).join("&")}function G(e){if("string"===typeof e){if(e=e.toLowerCase(),32===Object(b.d)(e))return"tx:"+e;if(-1===e.indexOf(":"))return e}else{if(Array.isArray(e))return"filter:*:"+V(e);if(d.a.isForkEvent(e))throw q.warn("not implemented"),new Error("not implemented");if(e&&"object"===typeof e)return"filter:"+(e.address||"*")+":"+V(e.topics||[])}throw new Error("invalid event - "+e)}function X(){return(new Date).getTime()}function K(e){return new Promise((function(t){setTimeout(t,e)}))}var W=["block","network","pending","poll"],Z=function(){function e(t,r,n){Object(s.a)(this,e),Object(B.d)(this,"tag",t),Object(B.d)(this,"listener",r),Object(B.d)(this,"once",n)}return Object(f.a)(e,[{key:"event",get:function(){switch(this.type){case"tx":return this.hash;case"filter":return this.filter}return this.tag}},{key:"type",get:function(){return this.tag.split(":")[0]}},{key:"hash",get:function(){var e=this.tag.split(":");return"tx"!==e[0]?null:e[1]}},{key:"filter",get:function(){var e=this.tag.split(":");if("filter"!==e[0])return null;var t,r=e[1],n=""===(t=e[2])?[]:t.split(/&/g).map((function(e){if(""===e)return[];var t=e.split("|").map((function(e){return"null"===e?null:e}));return 1===t.length?t[0]:t})),a={};return n.length>0&&(a.topics=n),r&&"*"!==r&&(a.address=r),a}},{key:"pollable",value:function(){return this.tag.indexOf(":")>=0||W.indexOf(this.tag)>=0}}]),e}(),$={0:{symbol:"btc",p2pkh:0,p2sh:5,prefix:"bc"},2:{symbol:"ltc",p2pkh:48,p2sh:50,prefix:"ltc"},3:{symbol:"doge",p2pkh:30,p2sh:22},60:{symbol:"eth",ilk:"eth"},61:{symbol:"etc",ilk:"eth"},700:{symbol:"xdai",ilk:"eth"}};function Q(e){return Object(b.g)(l.a.from(e).toHexString(),32)}function Y(e){return u.a.encode(Object(b.b)([e,Object(b.e)(Object(L.c)(Object(L.c)(e)),0,4)]))}var ee=new RegExp("^(ipfs)://(.*)$","i"),te=[new RegExp("^(https)://(.*)$","i"),new RegExp("^(data):(.*)$","i"),ee,new RegExp("^eip155:[0-9]+/(erc[0-9]+):(.*)$","i")];function re(e){try{return Object(p.e)(ne(e))}catch(t){}return null}function ne(e){if("0x"===e)return null;var t=l.a.from(Object(b.e)(e,0,32)).toNumber(),r=l.a.from(Object(b.e)(e,t,t+32)).toNumber();return Object(b.e)(e,t+32,t+32+r)}function ae(e){return e.match(/^ipfs:\/\/ipfs\//i)?e=e.substring(12):e.match(/^ipfs:\/\//i)?e=e.substring(7):q.throwArgumentError("unsupported IPFS format","link",e),"https://gateway.ipfs.io/ipfs/".concat(e)}var ie=function(){function e(t,r,n,a){Object(s.a)(this,e),Object(B.d)(this,"provider",t),Object(B.d)(this,"name",n),Object(B.d)(this,"address",t.formatter.address(r)),Object(B.d)(this,"_resolvedAddress",a)}return Object(f.a)(e,[{key:"_fetchBytes",value:function(e,t){return H(this,void 0,void 0,c.a.mark((function r(){var n;return c.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return n={to:this.address,data:Object(b.c)([e,R(this.name),t||"0x"])},r.prev=1,r.t0=ne,r.next=5,this.provider.call(n);case 5:return r.t1=r.sent,r.abrupt("return",(0,r.t0)(r.t1));case 9:if(r.prev=9,r.t2=r.catch(1),r.t2.code!==A.a.errors.CALL_EXCEPTION){r.next=13;break}return r.abrupt("return",null);case 13:return r.abrupt("return",null);case 14:case"end":return r.stop()}}),r,this,[[1,9]])})))}},{key:"_getAddress",value:function(e,t){var r=$[String(e)];if(null==r&&q.throwError("unsupported coin type: ".concat(e),A.a.errors.UNSUPPORTED_OPERATION,{operation:"getAddress(".concat(e,")")}),"eth"===r.ilk)return this.provider.formatter.address(t);var n=Object(b.a)(t);if(null!=r.p2pkh){var a=t.match(/^0x76a9([0-9a-f][0-9a-f])([0-9a-f]*)88ac$/);if(a){var i=parseInt(a[1],16);if(a[2].length===2*i&&i>=1&&i<=75)return Y(Object(b.b)([[r.p2pkh],"0x"+a[2]]))}}if(null!=r.p2sh){var o=t.match(/^0xa9([0-9a-f][0-9a-f])([0-9a-f]*)87$/);if(o){var c=parseInt(o[1],16);if(o[2].length===2*c&&c>=1&&c<=75)return Y(Object(b.b)([[r.p2sh],"0x"+o[2]]))}}if(null!=r.prefix){var s=n[1],f=n[0];if(0===f?20!==s&&32!==s&&(f=-1):f=-1,f>=0&&n.length===2+s&&s>=1&&s<=75){var d=D.a.toWords(n.slice(2));return d.unshift(f),D.a.encode(r.prefix,d)}}return null}},{key:"getAddress",value:function(e){return H(this,void 0,void 0,c.a.mark((function t(){var r,n,a,i;return c.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(null==e&&(e=60),60!==e){t.next=17;break}return t.prev=2,r={to:this.address,data:"0x3b3b57de"+R(this.name).substring(2)},t.next=6,this.provider.call(r);case 6:if("0x"!==(n=t.sent)&&n!==h.a){t.next=9;break}return t.abrupt("return",null);case 9:return t.abrupt("return",this.provider.formatter.callAddress(n));case 12:if(t.prev=12,t.t0=t.catch(2),t.t0.code!==A.a.errors.CALL_EXCEPTION){t.next=16;break}return t.abrupt("return",null);case 16:throw t.t0;case 17:return t.next=19,this._fetchBytes("0xf1cb7e06",Q(e));case 19:if(null!=(a=t.sent)&&"0x"!==a){t.next=22;break}return t.abrupt("return",null);case 22:return null==(i=this._getAddress(e,a))&&q.throwError("invalid or unsupported coin data",A.a.errors.UNSUPPORTED_OPERATION,{operation:"getAddress(".concat(e,")"),coinType:e,data:a}),t.abrupt("return",i);case 25:case"end":return t.stop()}}),t,this,[[2,12]])})))}},{key:"getAvatar",value:function(){return H(this,void 0,void 0,c.a.mark((function e(){var t,r,n,a,i,o,s,f,d,u,h,p,m,v,g,x;return c.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=[{type:"name",content:this.name}],e.prev=1,e.next=4,this.getText("avatar");case 4:if(null!=(r=e.sent)){e.next=7;break}return e.abrupt("return",null);case 7:n=0;case 8:if(!(n0)){t.next=20;break}case 3:if(!this._internalBlockNumber){t.next=20;break}return r=this._internalBlockNumber,t.prev=5,t.next=8,r;case 8:if(n=t.sent,!(X()-n.respTime<=e)){t.next=11;break}return t.abrupt("return",n.blockNumber);case 11:return t.abrupt("break",20);case 14:if(t.prev=14,t.t0=t.catch(5),this._internalBlockNumber!==r){t.next=18;break}return t.abrupt("break",20);case 18:t.next=3;break;case 20:return a=X(),i=Object(B.f)({blockNumber:this.perform("getBlockNumber",{}),networkError:this.getNetwork().then((function(e){return null}),(function(e){return e}))}).then((function(e){var t=e.blockNumber,r=e.networkError;if(r)throw o._internalBlockNumber===i&&(o._internalBlockNumber=null),r;var n=X();return(t=l.a.from(t).toNumber())1e3)q.warn("network block skew detected; skipping block events (emitted=".concat(this._emitted.block," blockNumber").concat(n,")")),this.emit("error",q.makeError("network block skew detected",A.a.errors.NETWORK_ERROR,{blockNumber:n,event:"blockSkew",previousBlockNumber:this._emitted.block})),this.emit("block",n);else for(a=this._emitted.block+1;a<=n;a++)this.emit("block",a);return this._emitted.block!==n&&(this._emitted.block=n,Object.keys(this._emitted).forEach((function(e){if("block"!==e){var t=i._emitted[e];"pending"!==t&&n-t>12&&delete i._emitted[e]}}))),-2===this._lastBlockNumber&&(this._lastBlockNumber=n-1),this._events.forEach((function(e){switch(e.type){case"tx":var t=e.hash,a=i.getTransactionReceipt(t).then((function(e){return e&&null!=e.blockNumber?(i._emitted["t:"+t]=e.blockNumber,i.emit(t,e),null):null})).catch((function(e){i.emit("error",e)}));r.push(a);break;case"filter":var o=e.filter;o.fromBlock=i._lastBlockNumber+1,o.toBlock=n;var c=i.getLogs(o).then((function(e){0!==e.length&&e.forEach((function(e){i._emitted["b:"+e.blockHash]=e.blockNumber,i._emitted["t:"+e.transactionHash]=e.blockNumber,i.emit(o,e)}))})).catch((function(e){i.emit("error",e)}));r.push(c)}})),this._lastBlockNumber=n,Promise.all(r).then((function(){i.emit("didPoll",t)})).catch((function(e){i.emit("error",e)})),e.abrupt("return");case 26:case"end":return e.stop()}}),e,this,[[3,9]])})))}},{key:"resetEventsBlock",value:function(e){this._lastBlockNumber=e-1,this.polling&&this.poll()}},{key:"network",get:function(){return this._network}},{key:"detectNetwork",value:function(){return H(this,void 0,void 0,c.a.mark((function e(){return c.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",q.throwError("provider does not support network detection",A.a.errors.UNSUPPORTED_OPERATION,{operation:"provider.detectNetwork"}));case 1:case"end":return e.stop()}}),e)})))}},{key:"getNetwork",value:function(){return H(this,void 0,void 0,c.a.mark((function e(){var t,r,n;return c.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._ready();case 2:return t=e.sent,e.next=5,this.detectNetwork();case 5:if(r=e.sent,t.chainId===r.chainId){e.next=23;break}if(!this.anyNetwork){e.next=20;break}return this._network=r,this._lastBlockNumber=-2,this._fastBlockNumber=null,this._fastBlockNumberPromise=null,this._fastQueryDate=0,this._emitted.block=-2,this._maxInternalBlockNumber=-1024,this._internalBlockNumber=null,this.emit("network",r,t),e.next=19,K(0);case 19:return e.abrupt("return",this._network);case 20:throw n=q.makeError("underlying network changed",A.a.errors.NETWORK_ERROR,{event:"changed",network:t,detectedNetwork:r}),this.emit("error",n),n;case 23:return e.abrupt("return",t);case 24:case"end":return e.stop()}}),e,this)})))}},{key:"blockNumber",get:function(){var e=this;return this._getInternalBlockNumber(100+this.pollingInterval/2).then((function(t){e._setFastBlockNumber(t)}),(function(e){})),null!=this._fastBlockNumber?this._fastBlockNumber:-1}},{key:"polling",get:function(){return null!=this._poller},set:function(e){var t=this;e&&!this._poller?(this._poller=setInterval((function(){t.poll()}),this.pollingInterval),this._bootstrapPoll||(this._bootstrapPoll=setTimeout((function(){t.poll(),t._bootstrapPoll=setTimeout((function(){t._poller||t.poll(),t._bootstrapPoll=null}),t.pollingInterval)}),0))):!e&&this._poller&&(clearInterval(this._poller),this._poller=null)}},{key:"pollingInterval",get:function(){return this._pollingInterval},set:function(e){var t=this;if("number"!==typeof e||e<=0||parseInt(String(e))!=e)throw new Error("invalid polling interval");this._pollingInterval=e,this._poller&&(clearInterval(this._poller),this._poller=setInterval((function(){t.poll()}),this._pollingInterval))}},{key:"_getFastBlockNumber",value:function(){var e=this,t=X();return t-this._fastQueryDate>2*this._pollingInterval&&(this._fastQueryDate=t,this._fastBlockNumberPromise=this.getBlockNumber().then((function(t){return(null==e._fastBlockNumber||t>e._fastBlockNumber)&&(e._fastBlockNumber=t),e._fastBlockNumber}))),this._fastBlockNumberPromise}},{key:"_setFastBlockNumber",value:function(e){null!=this._fastBlockNumber&&ethis._fastBlockNumber)&&(this._fastBlockNumber=e,this._fastBlockNumberPromise=Promise.resolve(e)))}},{key:"waitForTransaction",value:function(e,t,r){return H(this,void 0,void 0,c.a.mark((function n(){return c.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.abrupt("return",this._waitForTransaction(e,null==t?1:t,r||0,null));case 1:case"end":return n.stop()}}),n,this)})))}},{key:"_waitForTransaction",value:function(e,t,r,n){return H(this,void 0,void 0,c.a.mark((function a(){var i,o=this;return c.a.wrap((function(a){for(;;)switch(a.prev=a.next){case 0:return a.next=2,this.getTransactionReceipt(e);case 2:if(!(((i=a.sent)?i.confirmations:0)>=t)){a.next=5;break}return a.abrupt("return",i);case 5:return a.abrupt("return",new Promise((function(a,i){var s=[],f=!1,d=function(){return!!f||(f=!0,s.forEach((function(e){e()})),!1)},u=function(e){e.confirmations0){var p=setTimeout((function(){d()||i(q.makeError("timeout exceeded",A.a.errors.TIMEOUT,{timeout:r}))}),r);p.unref&&p.unref(),s.push((function(){clearTimeout(p)}))}})));case 6:case"end":return a.stop()}}),a,this)})))}},{key:"getBlockNumber",value:function(){return H(this,void 0,void 0,c.a.mark((function e(){return c.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",this._getInternalBlockNumber(0));case 1:case"end":return e.stop()}}),e,this)})))}},{key:"getGasPrice",value:function(){return H(this,void 0,void 0,c.a.mark((function e(){var t;return c.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.getNetwork();case 2:return e.next=4,this.perform("getGasPrice",{});case 4:return t=e.sent,e.prev=5,e.abrupt("return",l.a.from(t));case 9:return e.prev=9,e.t0=e.catch(5),e.abrupt("return",q.throwError("bad result from backend",A.a.errors.SERVER_ERROR,{method:"getGasPrice",result:t,error:e.t0}));case 12:case"end":return e.stop()}}),e,this,[[5,9]])})))}},{key:"getBalance",value:function(e,t){return H(this,void 0,void 0,c.a.mark((function r(){var n,a;return c.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,this.getNetwork();case 2:return r.next=4,Object(B.f)({address:this._getAddress(e),blockTag:this._getBlockTag(t)});case 4:return n=r.sent,r.next=7,this.perform("getBalance",n);case 7:return a=r.sent,r.prev=8,r.abrupt("return",l.a.from(a));case 12:return r.prev=12,r.t0=r.catch(8),r.abrupt("return",q.throwError("bad result from backend",A.a.errors.SERVER_ERROR,{method:"getBalance",params:n,result:a,error:r.t0}));case 15:case"end":return r.stop()}}),r,this,[[8,12]])})))}},{key:"getTransactionCount",value:function(e,t){return H(this,void 0,void 0,c.a.mark((function r(){var n,a;return c.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,this.getNetwork();case 2:return r.next=4,Object(B.f)({address:this._getAddress(e),blockTag:this._getBlockTag(t)});case 4:return n=r.sent,r.next=7,this.perform("getTransactionCount",n);case 7:return a=r.sent,r.prev=8,r.abrupt("return",l.a.from(a).toNumber());case 12:return r.prev=12,r.t0=r.catch(8),r.abrupt("return",q.throwError("bad result from backend",A.a.errors.SERVER_ERROR,{method:"getTransactionCount",params:n,result:a,error:r.t0}));case 15:case"end":return r.stop()}}),r,this,[[8,12]])})))}},{key:"getCode",value:function(e,t){return H(this,void 0,void 0,c.a.mark((function r(){var n,a;return c.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,this.getNetwork();case 2:return r.next=4,Object(B.f)({address:this._getAddress(e),blockTag:this._getBlockTag(t)});case 4:return n=r.sent,r.next=7,this.perform("getCode",n);case 7:return a=r.sent,r.prev=8,r.abrupt("return",Object(b.h)(a));case 12:return r.prev=12,r.t0=r.catch(8),r.abrupt("return",q.throwError("bad result from backend",A.a.errors.SERVER_ERROR,{method:"getCode",params:n,result:a,error:r.t0}));case 15:case"end":return r.stop()}}),r,this,[[8,12]])})))}},{key:"getStorageAt",value:function(e,t,r){return H(this,void 0,void 0,c.a.mark((function n(){var a,i;return c.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,this.getNetwork();case 2:return n.next=4,Object(B.f)({address:this._getAddress(e),blockTag:this._getBlockTag(r),position:Promise.resolve(t).then((function(e){return Object(b.f)(e)}))});case 4:return a=n.sent,n.next=7,this.perform("getStorageAt",a);case 7:return i=n.sent,n.prev=8,n.abrupt("return",Object(b.h)(i));case 12:return n.prev=12,n.t0=n.catch(8),n.abrupt("return",q.throwError("bad result from backend",A.a.errors.SERVER_ERROR,{method:"getStorageAt",params:a,result:i,error:n.t0}));case 15:case"end":return n.stop()}}),n,this,[[8,12]])})))}},{key:"_wrapTransaction",value:function(e,t,r){var n=this;if(null!=t&&32!==Object(b.d)(t))throw new Error("invalid response - sendTransaction");var a=e;return null!=t&&e.hash!==t&&q.throwError("Transaction hash mismatch from Provider.sendTransaction.",A.a.errors.UNKNOWN_ERROR,{expectedHash:e.hash,returnedHash:t}),a.wait=function(t,a){return H(n,void 0,void 0,c.a.mark((function n(){var i,o;return c.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return null==t&&(t=1),null==a&&(a=0),i=void 0,0!==t&&null!=r&&(i={data:e.data,from:e.from,nonce:e.nonce,to:e.to,value:e.value,startBlock:r}),n.next=6,this._waitForTransaction(e.hash,t,a,i);case 6:if(null!=(o=n.sent)||0!==t){n.next=9;break}return n.abrupt("return",null);case 9:return this._emitted["t:"+e.hash]=o.blockNumber,0===o.status&&q.throwError("transaction failed",A.a.errors.CALL_EXCEPTION,{transactionHash:e.hash,transaction:e,receipt:o}),n.abrupt("return",o);case 12:case"end":return n.stop()}}),n,this)})))},a}},{key:"sendTransaction",value:function(e){return H(this,void 0,void 0,c.a.mark((function t(){var r,n,a,i;return c.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.getNetwork();case 2:return t.next=4,Promise.resolve(e).then((function(e){return Object(b.h)(e)}));case 4:return r=t.sent,null==(n=this.formatter.transaction(e)).confirmations&&(n.confirmations=0),t.next=9,this._getInternalBlockNumber(100+2*this.pollingInterval);case 9:return a=t.sent,t.prev=10,t.next=13,this.perform("sendTransaction",{signedTransaction:r});case 13:return i=t.sent,t.abrupt("return",this._wrapTransaction(n,i,a));case 17:throw t.prev=17,t.t0=t.catch(10),t.t0.transaction=n,t.t0.transactionHash=n.hash,t.t0;case 22:case"end":return t.stop()}}),t,this,[[10,17]])})))}},{key:"_getTransactionRequest",value:function(e){return H(this,void 0,void 0,c.a.mark((function t(){var r,n,a=this;return c.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,e;case 2:return r=t.sent,n={},["from","to"].forEach((function(e){null!=r[e]&&(n[e]=Promise.resolve(r[e]).then((function(e){return e?a._getAddress(e):null})))})),["gasLimit","gasPrice","maxFeePerGas","maxPriorityFeePerGas","value"].forEach((function(e){null!=r[e]&&(n[e]=Promise.resolve(r[e]).then((function(e){return e?l.a.from(e):null})))})),["type"].forEach((function(e){null!=r[e]&&(n[e]=Promise.resolve(r[e]).then((function(e){return null!=e?e:null})))})),r.accessList&&(n.accessList=this.formatter.accessList(r.accessList)),["data"].forEach((function(e){null!=r[e]&&(n[e]=Promise.resolve(r[e]).then((function(e){return e?Object(b.h)(e):null})))})),t.t0=this.formatter,t.next=12,Object(B.f)(n);case 12:return t.t1=t.sent,t.abrupt("return",t.t0.transactionRequest.call(t.t0,t.t1));case 14:case"end":return t.stop()}}),t,this)})))}},{key:"_getFilter",value:function(e){return H(this,void 0,void 0,c.a.mark((function t(){var r,n=this;return c.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,e;case 2:return e=t.sent,r={},null!=e.address&&(r.address=this._getAddress(e.address)),["blockHash","topics"].forEach((function(t){null!=e[t]&&(r[t]=e[t])})),["fromBlock","toBlock"].forEach((function(t){null!=e[t]&&(r[t]=n._getBlockTag(e[t]))})),t.t0=this.formatter,t.next=10,Object(B.f)(r);case 10:return t.t1=t.sent,t.abrupt("return",t.t0.filter.call(t.t0,t.t1));case 12:case"end":return t.stop()}}),t,this)})))}},{key:"call",value:function(e,t){return H(this,void 0,void 0,c.a.mark((function r(){var n,a;return c.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,this.getNetwork();case 2:return r.next=4,Object(B.f)({transaction:this._getTransactionRequest(e),blockTag:this._getBlockTag(t)});case 4:return n=r.sent,r.next=7,this.perform("call",n);case 7:return a=r.sent,r.prev=8,r.abrupt("return",Object(b.h)(a));case 12:return r.prev=12,r.t0=r.catch(8),r.abrupt("return",q.throwError("bad result from backend",A.a.errors.SERVER_ERROR,{method:"call",params:n,result:a,error:r.t0}));case 15:case"end":return r.stop()}}),r,this,[[8,12]])})))}},{key:"estimateGas",value:function(e){return H(this,void 0,void 0,c.a.mark((function t(){var r,n;return c.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.getNetwork();case 2:return t.next=4,Object(B.f)({transaction:this._getTransactionRequest(e)});case 4:return r=t.sent,t.next=7,this.perform("estimateGas",r);case 7:return n=t.sent,t.prev=8,t.abrupt("return",l.a.from(n));case 12:return t.prev=12,t.t0=t.catch(8),t.abrupt("return",q.throwError("bad result from backend",A.a.errors.SERVER_ERROR,{method:"estimateGas",params:r,result:n,error:t.t0}));case 15:case"end":return t.stop()}}),t,this,[[8,12]])})))}},{key:"_getAddress",value:function(e){return H(this,void 0,void 0,c.a.mark((function t(){var r;return c.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,e;case 2:return"string"!==typeof(e=t.sent)&&q.throwArgumentError("invalid address or ENS name","name",e),t.next=6,this.resolveName(e);case 6:return null==(r=t.sent)&&q.throwError("ENS name not configured",A.a.errors.UNSUPPORTED_OPERATION,{operation:"resolveName(".concat(JSON.stringify(e),")")}),t.abrupt("return",r);case 9:case"end":return t.stop()}}),t,this)})))}},{key:"_getBlock",value:function(e,t){return H(this,void 0,void 0,c.a.mark((function r(){var n,a,i=this;return c.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,this.getNetwork();case 2:return r.next=4,e;case 4:if(e=r.sent,n=-128,a={includeTransactions:!!t},!Object(b.k)(e,32)){r.next=11;break}a.blockHash=e,r.next=21;break;case 11:return r.prev=11,r.next=14,this._getBlockTag(e);case 14:a.blockTag=r.sent,Object(b.k)(a.blockTag)&&(n=parseInt(a.blockTag.substring(2),16)),r.next=21;break;case 18:r.prev=18,r.t0=r.catch(11),q.throwArgumentError("invalid block hash or block tag","blockHashOrBlockTag",e);case 21:return r.abrupt("return",Object(I.b)((function(){return H(i,void 0,void 0,c.a.mark((function e(){var r,i,o,s,f,d,u=this;return c.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.perform("getBlock",a);case 2:if(null!=(r=e.sent)){e.next=11;break}if(null==a.blockHash){e.next=7;break}if(null!=this._emitted["b:"+a.blockHash]){e.next=7;break}return e.abrupt("return",null);case 7:if(null==a.blockTag){e.next=10;break}if(!(n>this._emitted.block)){e.next=10;break}return e.abrupt("return",null);case 10:return e.abrupt("return",void 0);case 11:if(!t){e.next=34;break}i=null,o=0;case 14:if(!(oa.length)){t.next=24;break}return t.abrupt("return",null);case 24:return o=Object(p.e)(a.slice(0,i)),t.next=27,this.resolveName(o);case 27:if(t.sent==e){t.next=30;break}return t.abrupt("return",null);case 30:return t.abrupt("return",o);case 31:case"end":return t.stop()}}),t,this)})))}},{key:"getAvatar",value:function(e){return H(this,void 0,void 0,c.a.mark((function t(){var r,n,a,i,o;return c.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(r=null,!Object(b.k)(e)){t.next=12;break}return n=this.formatter.address(e),a=n.substring(2).toLowerCase()+".addr.reverse",t.next=6,this._getResolver(a);case 6:if(i=t.sent){t.next=9;break}return t.abrupt("return",null);case 9:r=new ie(this,i,"_",n),t.next=17;break;case 12:return t.next=14,this.getResolver(e);case 14:if(r=t.sent){t.next=17;break}return t.abrupt("return",null);case 17:return t.next=19,r.getAvatar();case 19:if(null!=(o=t.sent)){t.next=22;break}return t.abrupt("return",null);case 22:return t.abrupt("return",o.url);case 23:case"end":return t.stop()}}),t,this)})))}},{key:"perform",value:function(e,t){return q.throwError(e+" not implemented",A.a.errors.NOT_IMPLEMENTED,{operation:e})}},{key:"_startEvent",value:function(e){this.polling=this._events.filter((function(e){return e.pollable()})).length>0}},{key:"_stopEvent",value:function(e){this.polling=this._events.filter((function(e){return e.pollable()})).length>0}},{key:"_addEventListener",value:function(e,t,r){var n=new Z(G(e),t,r);return this._events.push(n),this._startEvent(n),this}},{key:"on",value:function(e,t){return this._addEventListener(e,t,!1)}},{key:"once",value:function(e,t){return this._addEventListener(e,t,!0)}},{key:"emit",value:function(e){for(var t=this,r=arguments.length,n=new Array(r>1?r-1:0),a=1;a=e.length?{done:!0}:{done:!1,value:e[t++]}},e:function(e){throw e},f:r}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,i,o=!0,c=!1;return{s:function(){a=e[Symbol.iterator]()},n:function(){var e=a.next();return o=e.done,e},e:function(e){c=!0,i=e},f:function(){try{o||null==a.return||a.return()}finally{if(c)throw i}}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n,a=r(1),i=(n=a)&&"object"===typeof n&&"default"in n?n.default:n,o=new(r(624)),c=o.getBrowser(),s=(o.getCPU(),o.getDevice()),f=o.getEngine(),d=o.getOS(),u=o.getUA(),l=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"none";return e||t},b=function(){return!("undefined"===typeof window||!window.navigator&&!navigator)&&(window.navigator||navigator)},h=function(e){var t=b();return t&&t.platform&&(-1!==t.platform.indexOf(e)||"MacIntel"===t.platform&&t.maxTouchPoints>1&&!window.MSStream)};function p(e){return(p="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function m(e,t){for(var r=0;r=0||(a[r]=e[r]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(n=0;n=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}function _(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var M="mobile",S="tablet",E="smarttv",O="console",A="wearable",T=void 0,j={Chrome:"Chrome",Firefox:"Firefox",Opera:"Opera",Yandex:"Yandex",Safari:"Safari",InternetExplorer:"Internet Explorer",Edge:"Edge",Chromium:"Chromium",Ie:"IE",MobileSafari:"Mobile Safari",EdgeChromium:"Edge Chromium",MIUI:"MIUI Browser",SamsungBrowser:"Samsung Browser"},P={IOS:"iOS",Android:"Android",WindowsPhone:"Windows Phone",Windows:"Windows",MAC_OS:"Mac OS"},C={isMobile:!1,isTablet:!1,isBrowser:!1,isSmartTV:!1,isConsole:!1,isWearable:!1},R=function(e,t,r,n){return function(e){for(var t=1;t1)&&!window.MSStream}(),ve=F(),ge=h("iPhone"),xe=h("iPod"),ye=function(){var e=b(),t=e&&e.userAgent&&e.userAgent.toLowerCase();return"string"===typeof t&&/electron/.test(t)}(),we=B(),ke=I()&&!B(),_e=d.name===P.Windows,Me=d.name===P.MAC_OS,Se=c.name===j.MIUI,Ee=c.name===j.SamsungBrowser;t.AndroidView=function(e){var t=e.renderWithFragment,r=e.children,n=e.viewClassName,o=e.style,c=k(e,["renderWithFragment","children","viewClassName","style"]);return W?t?i.createElement(a.Fragment,null,r):i.createElement("div",g({className:n,style:o},c),r):null},t.BrowserTypes=j,t.BrowserView=function(e){var t=e.renderWithFragment,r=e.children,n=e.viewClassName,o=e.style,c=k(e,["renderWithFragment","children","viewClassName","style"]);return X?t?i.createElement(a.Fragment,null,r):i.createElement("div",g({className:n,style:o},c),r):null},t.ConsoleView=function(e){var t=e.renderWithFragment,r=e.children,n=e.viewClassName,o=e.style,c=k(e,["renderWithFragment","children","viewClassName","style"]);return U?t?i.createElement(a.Fragment,null,r):i.createElement("div",g({className:n,style:o},c),r):null},t.CustomView=function(e){var t=e.renderWithFragment,r=e.children,n=e.viewClassName,o=e.style,c=e.condition,s=k(e,["renderWithFragment","children","viewClassName","style","condition"]);return c?t?i.createElement(a.Fragment,null,r):i.createElement("div",g({className:n,style:o},s),r):null},t.IEView=function(e){var t=e.renderWithFragment,r=e.children,n=e.viewClassName,o=e.style,c=k(e,["renderWithFragment","children","viewClassName","style"]);return re?t?i.createElement(a.Fragment,null,r):i.createElement("div",g({className:n,style:o},c),r):null},t.IOSView=function(e){var t=e.renderWithFragment,r=e.children,n=e.viewClassName,o=e.style,c=k(e,["renderWithFragment","children","viewClassName","style"]);return $?t?i.createElement(a.Fragment,null,r):i.createElement("div",g({className:n,style:o},c),r):null},t.MobileOnlyView=function(e){var t=e.renderWithFragment,r=e.children,n=e.viewClassName,o=e.style,c=k(e,["renderWithFragment","children","viewClassName","style"]);return V?t?i.createElement(a.Fragment,null,r):i.createElement("div",g({className:n,style:o},c),r):null},t.MobileView=function(e){var t=e.renderWithFragment,r=e.children,n=e.viewClassName,o=e.style,c=k(e,["renderWithFragment","children","viewClassName","style"]);return J?t?i.createElement(a.Fragment,null,r):i.createElement("div",g({className:n,style:o},c),r):null},t.OsTypes=P,t.SmartTVView=function(e){var t=e.renderWithFragment,r=e.children,n=e.viewClassName,o=e.style,c=k(e,["renderWithFragment","children","viewClassName","style"]);return D?t?i.createElement(a.Fragment,null,r):i.createElement("div",g({className:n,style:o},c),r):null},t.TabletView=function(e){var t=e.renderWithFragment,r=e.children,n=e.viewClassName,o=e.style,c=k(e,["renderWithFragment","children","viewClassName","style"]);return G?t?i.createElement(a.Fragment,null,r):i.createElement("div",g({className:n,style:o},c),r):null},t.WearableView=function(e){var t=e.renderWithFragment,r=e.children,n=e.viewClassName,o=e.style,c=k(e,["renderWithFragment","children","viewClassName","style"]);return z?t?i.createElement(a.Fragment,null,r):i.createElement("div",g({className:n,style:o},c),r):null},t.WinPhoneView=function(e){var t=e.renderWithFragment,r=e.children,n=e.viewClassName,o=e.style,c=k(e,["renderWithFragment","children","viewClassName","style"]);return Z?t?i.createElement(a.Fragment,null,r):i.createElement("div",g({className:n,style:o},c),r):null},t.browserName=ce,t.browserVersion=oe,t.deviceDetect=function(){var e=N.isBrowser,t=N.isMobile,r=N.isTablet,n=N.isSmartTV,a=N.isConsole,i=N.isWearable;return e?function(e,t,r,n,a){return{isBrowser:e,browserMajorVersion:l(t.major),browserFullVersion:l(t.version),browserName:l(t.name),engineName:l(r.name),engineVersion:l(r.version),osName:l(n.name),osVersion:l(n.version),userAgent:l(a)}}(e,c,f,d,u):n?function(e,t,r,n){return{isSmartTV:e,engineName:l(t.name),engineVersion:l(t.version),osName:l(r.name),osVersion:l(r.version),userAgent:l(n)}}(n,f,d,u):a?function(e,t,r,n){return{isConsole:e,engineName:l(t.name),engineVersion:l(t.version),osName:l(r.name),osVersion:l(r.version),userAgent:l(n)}}(a,f,d,u):t||r?R(N,s,d,u):i?function(e,t,r,n){return{isWearable:e,engineName:l(t.name),engineVersion:l(t.version),osName:l(r.name),osVersion:l(r.version),userAgent:l(n)}}(i,f,d,u):void 0},t.deviceType=pe,t.engineName=de,t.engineVersion=ue,t.fullBrowserVersion=ie,t.getUA=le,t.isAndroid=W,t.isBrowser=X,t.isChrome=Q,t.isChromium=q,t.isConsole=U,t.isDesktop=K,t.isEdge=be,t.isEdgeChromium=we,t.isElectron=ye,t.isFirefox=Y,t.isIE=re,t.isIOS=$,t.isIOS13=me,t.isIPad13=ve,t.isIPhone13=ge,t.isIPod13=xe,t.isLegacyEdge=ke,t.isMIUI=Se,t.isMacOs=Me,t.isMobile=J,t.isMobileOnly=V,t.isMobileSafari=H,t.isOpera=te,t.isSafari=ee,t.isSamsungBrowser=Ee,t.isSmartTV=D,t.isTablet=G,t.isWearable=z,t.isWinPhone=Z,t.isWindows=_e,t.isYandex=he,t.mobileModel=fe,t.mobileVendor=se,t.osName=ae,t.osVersion=ne,t.withOrientationChange=function(e){return function(t){function r(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r),(t=function(e,t){return!t||"object"!==typeof t&&"function"!==typeof t?_(e):t}(this,y(r).call(this,e))).isEventListenerAdded=!1,t.handleOrientationChange=t.handleOrientationChange.bind(_(t)),t.onOrientationChange=t.onOrientationChange.bind(_(t)),t.onPageLoad=t.onPageLoad.bind(_(t)),t.state={isLandscape:!1,isPortrait:!1},t}var n,a,o;return function(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&w(e,t)}(r,t),n=r,(a=[{key:"handleOrientationChange",value:function(){this.isEventListenerAdded||(this.isEventListenerAdded=!0);var e=window.innerWidth>window.innerHeight?90:0;this.setState({isPortrait:0===e,isLandscape:90===e})}},{key:"onOrientationChange",value:function(){this.handleOrientationChange()}},{key:"onPageLoad",value:function(){this.handleOrientationChange()}},{key:"componentDidMount",value:function(){void 0!==("undefined"===typeof window?"undefined":p(window))&&J&&(this.isEventListenerAdded?window.removeEventListener("load",this.onPageLoad,!1):(this.handleOrientationChange(),window.addEventListener("load",this.onPageLoad,!1)),window.addEventListener("resize",this.onOrientationChange,!1))}},{key:"componentWillUnmount",value:function(){window.removeEventListener("resize",this.onOrientationChange,!1)}},{key:"render",value:function(){return i.createElement(e,g({},this.props,{isLandscape:this.state.isLandscape,isPortrait:this.state.isPortrait}))}}])&&m(n.prototype,a),o&&m(n,o),r}(i.Component)}},function(e,t,r){"use strict";r.d(t,"a",(function(){return i}));var n=r(49),a=r(64);function i(e){return Object(n.keccak256)(Object(a.f)(e))}},function(e,t,r){"use strict";r.d(t,"a",(function(){return Ae})),r.d(t,"b",(function(){return K})),r.d(t,"c",(function(){return Q}));var n=r(35),a=r(126),i=r(20),o=r(13),c=r(14),s=r(6),f=r(7),d=r(19),u=r(22),l=r(50),b=r(1),h=r.n(b),p={arr:Array.isArray,obj:function(e){return"[object Object]"===Object.prototype.toString.call(e)},fun:function(e){return"function"===typeof e},str:function(e){return"string"===typeof e},num:function(e){return"number"===typeof e},und:function(e){return void 0===e},nul:function(e){return null===e},set:function(e){return e instanceof Set},map:function(e){return e instanceof Map},equ:function(e,t){if(typeof e!==typeof t)return!1;if(p.str(e)||p.num(e))return e===t;if(p.obj(e)&&p.obj(t)&&Object.keys(e).length+Object.keys(t).length===0)return!0;var r;for(r in e)if(!(r in t))return!1;for(r in t)if(e[r]!==t[r])return!1;return!p.und(r)||e===t}};function m(){var e=Object(b.useState)(!1)[1];return Object(b.useCallback)((function(){return e((function(e){return!e}))}),[])}function v(e,t){return p.und(e)||p.nul(e)?t:e}function g(e){return p.und(e)?[]:p.arr(e)?e:[e]}function x(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n=l.startTime+s.duration;else if(s.decay)p=b+v/(1-.998)*(1-Math.exp(-(1-.998)*(r-l.startTime))),(f=Math.abs(l.lastPosition-p)<.1)&&(h=p);else{d=void 0!==l.lastTime?l.lastTime:r,v=void 0!==l.lastVelocity?l.lastVelocity:s.initialVelocity,r>d+64&&(d=r);for(var g=Math.floor(r-d),x=0;xh:p=e);++r);return r-1}(e,i);return function(e,t,r,n,a,i,o,c,s){var f=s?s(e):e;if(fr){if("identity"===c)return f;"clamp"===c&&(f=r)}if(n===a)return n;if(t===r)return e<=t?n:a;t===-1/0?f=-f:r===1/0?f-=t:f=(f-t)/(r-t);f=i(f),n===-1/0?f=-f:a===1/0?f+=n:f=f*(a-n)+n;return f}(e,i[t],i[t+1],a[t],a[t+1],s,o,c,n.map)}}var H=function(e){Object(o.a)(r,e);var t=Object(c.a)(r);function r(e,n,a,i){var o;return Object(s.a)(this,r),(o=t.call(this)).calc=void 0,o.payload=e instanceof M&&!(e instanceof r)?e.getPayload():Array.isArray(e)?e:[e],o.calc=z(n,a,i),o}return Object(f.a)(r,[{key:"getValue",value:function(){return this.calc.apply(this,Object(n.a)(this.payload.map((function(e){return e.getValue()}))))}},{key:"updateConfig",value:function(e,t,r){this.calc=z(e,t,r)}},{key:"interpolate",value:function(e,t,n){return new r(this,e,t,n)}}]),r}(M);var q=function(e){Object(o.a)(r,e);var t=Object(c.a)(r);function r(e){var n,a;return Object(s.a)(this,r),n=t.call(this),a=Object(i.a)(n),n.animatedStyles=new Set,n.value=void 0,n.startPosition=void 0,n.lastPosition=void 0,n.lastVelocity=void 0,n.startTime=void 0,n.lastTime=void 0,n.done=!1,n.setValue=function(e,t){void 0===t&&(t=!0),a.value=e,t&&a.flush()},n.value=e,n.startPosition=e,n.lastPosition=e,n}return Object(f.a)(r,[{key:"flush",value:function(){0===this.animatedStyles.size&&function e(t,r){"update"in t?r.add(t):t.getChildren().forEach((function(t){return e(t,r)}))}(this,this.animatedStyles),this.animatedStyles.forEach((function(e){return e.update()}))}},{key:"clearStyles",value:function(){this.animatedStyles.clear()}},{key:"getValue",value:function(){return this.value}},{key:"interpolate",value:function(e,t,r){return new H(this,e,t,r)}}]),r}(_),J=function(e){Object(o.a)(r,e);var t=Object(c.a)(r);function r(e){var n;return Object(s.a)(this,r),(n=t.call(this)).payload=e.map((function(e){return new q(e)})),n}return Object(f.a)(r,[{key:"setValue",value:function(e,t){var r=this;void 0===t&&(t=!0),Array.isArray(e)?e.length===this.payload.length&&e.forEach((function(e,n){return r.payload[n].setValue(e,t)})):this.payload.forEach((function(r){return r.setValue(e,t)}))}},{key:"getValue",value:function(){return this.payload.map((function(e){return e.getValue()}))}},{key:"interpolate",value:function(e,t){return new H(this,e,t)}}]),r}(M),V=0,G=function(){function e(){var t=this;Object(s.a)(this,e),this.id=void 0,this.idle=!0,this.hasChanged=!1,this.guid=0,this.local=0,this.props={},this.merged={},this.animations={},this.interpolations={},this.values={},this.configs=[],this.listeners=[],this.queue=[],this.localQueue=void 0,this.getValues=function(){return t.interpolations},this.id=V++}return Object(f.a)(e,[{key:"update",value:function(e){if(!e)return this;var t=y(e),r=t.delay,n=void 0===r?0:r,a=t.to,i=Object(l.a)(t,["delay","to"]);if(p.arr(a)||p.fun(a))this.queue.push(Object(u.a)({},i,{delay:n,to:a}));else if(a){var o={};Object.entries(a).forEach((function(e){var t=e[0],r=e[1],a=Object(u.a)({to:Object(d.a)({},t,r),delay:x(n,t)},i),c=o[a.delay]&&o[a.delay].to;o[a.delay]=Object(u.a)({},o[a.delay],a,{to:Object(u.a)({},c,a.to)})})),this.queue=Object.values(o)}return this.queue=this.queue.sort((function(e,t){return e.delay-t.delay})),this.diff(i),this}},{key:"start",value:function(e){var t,r=this;if(this.queue.length){this.idle=!1,this.localQueue&&this.localQueue.forEach((function(e){var t=e.from,n=void 0===t?{}:t,a=e.to,i=void 0===a?{}:a;p.obj(n)&&(r.merged=Object(u.a)({},n,r.merged)),p.obj(i)&&(r.merged=Object(u.a)({},r.merged,i))}));var n=this.local=++this.guid,a=this.localQueue=this.queue;this.queue=[],a.forEach((function(t,i){var o=t.delay,c=Object(l.a)(t,["delay"]),s=function(t){i===a.length-1&&n===r.guid&&t&&(r.idle=!0,r.props.onRest&&r.props.onRest(r.merged)),e&&e()},f=p.arr(c.to)||p.fun(c.to);o?setTimeout((function(){n===r.guid&&(f?r.runAsync(c,s):r.diff(c).start(s))}),o):f?r.runAsync(c,s):r.diff(c).start(s)}))}else p.fun(e)&&this.listeners.push(e),this.props.onStart&&this.props.onStart(),t=this,D.has(t)||D.add(t),F||(F=!0,T(N||U));return this}},{key:"stop",value:function(e){return this.listeners.forEach((function(t){return t(e)})),this.listeners=[],this}},{key:"pause",value:function(e){var t;return this.stop(!0),e&&(t=this,D.has(t)&&D.delete(t)),this}},{key:"runAsync",value:function(e,t){var r=this,n=this,a=(e.delay,Object(l.a)(e,["delay"])),i=this.local,o=Promise.resolve(void 0);if(p.arr(a.to))for(var c=function(e){var t=e,n=Object(u.a)({},a,y(a.to[t]));p.arr(n.config)&&(n.config=n.config[t]),o=o.then((function(){if(i===r.guid)return new Promise((function(e){return r.diff(n).start(e)}))}))},s=0;s0&&Y(_),p&&p(s,t,r))},onStart:v&&function(){return v(s,t)},onFrame:h&&function(e){return h(s,t,e)},delay:i,reset:f&&"enter"===t});l.update(b),_.current.paused||l.start()})),Object(b.useEffect)((function(){return _.current.mounted=k.current=!0,function(){_.current.mounted=k.current=!1,Array.from(_.current.instances).map((function(e){return e[1].destroy()})),_.current.instances.clear()}}),[]),_.current.transitions.map((function(e){var t=e.item,r=e.slot,n=e.key;return{item:t,key:n,state:r,props:_.current.instances.get(n).getValues()}}))}function Y(e,t){var r,n=e.current.deleted,i=Object(a.a)(n);try{var o=function(){var n=r.value.key,a=function(e){return e.key!==n};(p.und(t)||t===n)&&(e.current.instances.delete(n),e.current.transitions=e.current.transitions.filter(a),e.current.deleted=e.current.deleted.filter(a))};for(i.s();!(r=i.n()).done;)o()}catch(c){i.e(c)}finally{i.f()}e.current.forceUpdate()}var ee=function(e){Object(o.a)(r,e);var t=Object(c.a)(r);function r(e){var n;return Object(s.a)(this,r),void 0===e&&(e={}),n=t.call(this),!e.transform||e.transform instanceof _||(e=w.transform(e)),n.payload=e,n}return Object(f.a)(r)}(S),te={transparent:0,aliceblue:4042850303,antiquewhite:4209760255,aqua:16777215,aquamarine:2147472639,azure:4043309055,beige:4126530815,bisque:4293182719,black:255,blanchedalmond:4293643775,blue:65535,blueviolet:2318131967,brown:2771004159,burlywood:3736635391,burntsienna:3934150143,cadetblue:1604231423,chartreuse:2147418367,chocolate:3530104575,coral:4286533887,cornflowerblue:1687547391,cornsilk:4294499583,crimson:3692313855,cyan:16777215,darkblue:35839,darkcyan:9145343,darkgoldenrod:3095792639,darkgray:2846468607,darkgreen:6553855,darkgrey:2846468607,darkkhaki:3182914559,darkmagenta:2332068863,darkolivegreen:1433087999,darkorange:4287365375,darkorchid:2570243327,darkred:2332033279,darksalmon:3918953215,darkseagreen:2411499519,darkslateblue:1211993087,darkslategray:793726975,darkslategrey:793726975,darkturquoise:13554175,darkviolet:2483082239,deeppink:4279538687,deepskyblue:12582911,dimgray:1768516095,dimgrey:1768516095,dodgerblue:512819199,firebrick:2988581631,floralwhite:4294635775,forestgreen:579543807,fuchsia:4278255615,gainsboro:3705462015,ghostwhite:4177068031,gold:4292280575,goldenrod:3668254975,gray:2155905279,green:8388863,greenyellow:2919182335,grey:2155905279,honeydew:4043305215,hotpink:4285117695,indianred:3445382399,indigo:1258324735,ivory:4294963455,khaki:4041641215,lavender:3873897215,lavenderblush:4293981695,lawngreen:2096890111,lemonchiffon:4294626815,lightblue:2916673279,lightcoral:4034953471,lightcyan:3774873599,lightgoldenrodyellow:4210742015,lightgray:3553874943,lightgreen:2431553791,lightgrey:3553874943,lightpink:4290167295,lightsalmon:4288707327,lightseagreen:548580095,lightskyblue:2278488831,lightslategray:2005441023,lightslategrey:2005441023,lightsteelblue:2965692159,lightyellow:4294959359,lime:16711935,limegreen:852308735,linen:4210091775,magenta:4278255615,maroon:2147483903,mediumaquamarine:1724754687,mediumblue:52735,mediumorchid:3126187007,mediumpurple:2473647103,mediumseagreen:1018393087,mediumslateblue:2070474495,mediumspringgreen:16423679,mediumturquoise:1221709055,mediumvioletred:3340076543,midnightblue:421097727,mintcream:4127193855,mistyrose:4293190143,moccasin:4293178879,navajowhite:4292783615,navy:33023,oldlace:4260751103,olive:2155872511,olivedrab:1804477439,orange:4289003775,orangered:4282712319,orchid:3664828159,palegoldenrod:4008225535,palegreen:2566625535,paleturquoise:2951671551,palevioletred:3681588223,papayawhip:4293907967,peachpuff:4292524543,peru:3448061951,pink:4290825215,plum:3718307327,powderblue:2967529215,purple:2147516671,rebeccapurple:1714657791,red:4278190335,rosybrown:3163525119,royalblue:1097458175,saddlebrown:2336560127,salmon:4202722047,sandybrown:4104413439,seagreen:780883967,seashell:4294307583,sienna:2689740287,silver:3233857791,skyblue:2278484991,slateblue:1784335871,slategray:1887473919,slategrey:1887473919,snow:4294638335,springgreen:16744447,steelblue:1182971135,tan:3535047935,teal:8421631,thistle:3636451583,tomato:4284696575,turquoise:1088475391,violet:4001558271,wheat:4125012991,white:4294967295,whitesmoke:4126537215,yellow:4294902015,yellowgreen:2597139199},re="[-+]?\\d*\\.?\\d+";function ne(){for(var e=arguments.length,t=new Array(e),r=0;r1&&(r-=1),r<1/6?e+6*(t-e)*r:r<.5?t:r<2/3?e+(t-e)*(2/3-r)*6:e}function be(e,t,r){var n=r<.5?r*(1+t):r+t-r*t,a=2*r-n,i=le(a,n,e+1/3),o=le(a,n,e),c=le(a,n,e-1/3);return Math.round(255*i)<<24|Math.round(255*o)<<16|Math.round(255*c)<<8}function he(e){var t=parseInt(e,10);return t<0?0:t>255?255:t}function pe(e){return(parseFloat(e)%360+360)%360/360}function me(e){var t=parseFloat(e);return t<0?0:t>1?255:Math.round(255*t)}function ve(e){var t=parseFloat(e);return t<0?0:t>100?1:t/100}function ge(e){var t=function(e){var t;return"number"===typeof e?e>>>0===e&&e>=0&&e<=4294967295?e:null:(t=de.exec(e))?parseInt(t[1]+"ff",16)>>>0:te.hasOwnProperty(e)?te[e]:(t=ae.exec(e))?(he(t[1])<<24|he(t[2])<<16|he(t[3])<<8|255)>>>0:(t=ie.exec(e))?(he(t[1])<<24|he(t[2])<<16|he(t[3])<<8|me(t[4]))>>>0:(t=se.exec(e))?parseInt(t[1]+t[1]+t[2]+t[2]+t[3]+t[3]+"ff",16)>>>0:(t=ue.exec(e))?parseInt(t[1],16)>>>0:(t=fe.exec(e))?parseInt(t[1]+t[1]+t[2]+t[2]+t[3]+t[3]+t[4]+t[4],16)>>>0:(t=oe.exec(e))?(255|be(pe(t[1]),ve(t[2]),ve(t[3])))>>>0:(t=ce.exec(e))?(be(pe(t[1]),ve(t[2]),ve(t[3]))|me(t[4]))>>>0:null}(e);if(null===t)return e;var r=(16711680&(t=t||0))>>>16,n=(65280&t)>>>8,a=(255&t)/255;return"rgba(".concat((4278190080&t)>>>24,", ").concat(r,", ").concat(n,", ").concat(a,")")}var xe=/[+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,ye=/(#(?:[0-9a-f]{2}){2,4}|(#[0-9a-f]{3})|(rgb|hsl)a?\((-?\d+%?[,\s]+){2,3}\s*[\d\.]+%?\))/gi,we=new RegExp("(".concat(Object.keys(te).join("|"),")"),"g"),ke={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},_e=["Webkit","Ms","Moz","O"];function Me(e,t,r){return null==t||"boolean"===typeof t||""===t?"":r||"number"!==typeof t||0===t||ke.hasOwnProperty(e)&&ke[e]?(""+t).trim():t+"px"}ke=Object.keys(ke).reduce((function(e,t){return _e.forEach((function(r){return e[function(e,t){return e+t.charAt(0).toUpperCase()+t.substring(1)}(r,t)]=e[t]})),e}),ke);var Se={};L((function(e){return new ee(e)})),C("div"),j((function(e){var t=e.output.map((function(e){return e.replace(ye,ge)})).map((function(e){return e.replace(we,ge)})),r=t[0].match(xe).map((function(){return[]}));t.forEach((function(e){e.match(xe).forEach((function(e,t){return r[t].push(+e)}))}));var n=t[0].match(xe).map((function(t,n){return z(Object(u.a)({},e,{output:r[n]}))}));return function(e){var r=0;return t[0].replace(xe,(function(){return n[r++](e)})).replace(/rgba\(([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+)\)/gi,(function(e,t,r,n,a){return"rgba(".concat(Math.round(t),", ").concat(Math.round(r),", ").concat(Math.round(n),", ").concat(a,")")}))}})),O(te),E((function(e,t){if(!e.nodeType||void 0===e.setAttribute)return!1;var r=t.style,n=t.children,a=t.scrollTop,i=t.scrollLeft,o=Object(l.a)(t,["style","children","scrollTop","scrollLeft"]),c="filter"===e.nodeName||e.parentNode&&"filter"===e.parentNode.nodeName;for(var s in void 0!==a&&(e.scrollTop=a),void 0!==i&&(e.scrollLeft=i),void 0!==n&&(e.textContent=n),r)if(r.hasOwnProperty(s)){var f=0===s.indexOf("--"),d=Me(s,r[s],f);"float"===s&&(s="cssFloat"),f?e.style.setProperty(s,d):e.style[s]=d}for(var u in o){var b=c?u:Se[u]||(Se[u]=u.replace(/([A-Z])/g,(function(e){return"-"+e.toLowerCase()})));"undefined"!==typeof e.getAttribute(b)&&e.setAttribute(b,o[u])}}),(function(e){return e}));var Ee,Oe,Ae=(Ee=function(e){return Object(b.forwardRef)((function(t,r){var n=m(),a=Object(b.useRef)(!0),i=Object(b.useRef)(null),o=Object(b.useRef)(null),c=Object(b.useCallback)((function(e){var t=i.current;i.current=new I(e,(function(){var e=!1;o.current&&(e=w.fn(o.current,i.current.getAnimatedValue())),o.current&&!1!==e||n()})),t&&t.detach()}),[]);Object(b.useEffect)((function(){return function(){a.current=!1,i.current&&i.current.detach()}}),[]),Object(b.useImperativeHandle)(r,(function(){return B(o,a,n)})),c(t);var s,f=i.current.getValue(),d=(f.scrollTop,f.scrollLeft,Object(l.a)(f,["scrollTop","scrollLeft"])),v=(s=e,!p.fun(s)||s.prototype instanceof h.a.Component?function(e){return o.current=function(e,t){return t&&(p.fun(t)?t(e):p.obj(t)&&(t.current=e)),e}(e,r)}:void 0);return h.a.createElement(e,Object(u.a)({},d,{ref:v}))}))},void 0===(Oe=!1)&&(Oe=!0),function(e){return(p.arr(e)?e:Object.keys(e)).reduce((function(e,t){var r=Oe?t[0].toLowerCase()+t.substring(1):t;return e[r]=Ee(r),e}),Ee)})(["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"])},function(e,t,r){var n=r(295);function a(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}e.exports=function(e){for(var t=1;t4294967295)throw new RangeError("requested too many random bytes");var r=a.allocUnsafe(e);if(e>0)if(e>65536)for(var o=0;o=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,r){"use strict";r.d(t,"b",(function(){return a})),r.d(t,"c",(function(){return i})),r.d(t,"a",(function(){return o}));var n=r(38);function a(e){var t=null;try{t=JSON.parse(e)}catch(r){return!1}return t.encseed&&t.ethaddr}function i(e){var t=null;try{t=JSON.parse(e)}catch(r){return!1}return!(!t.version||parseInt(t.version)!==t.version||3!==parseInt(t.version))}function o(e){if(a(e))try{return Object(n.a)(JSON.parse(e).ethaddr)}catch(t){return null}if(i(e))try{return Object(n.a)(JSON.parse(e).address)}catch(t){return null}return null}},function(e,t,r){"use strict";r.d(t,"a",(function(){return d}));var n=new(r(11).a)("networks/5.5.2");function a(e){var t=function(t,r){null==r&&(r={});var n=[];if(t.InfuraProvider)try{n.push(new t.InfuraProvider(e,r.infura))}catch(o){}if(t.EtherscanProvider)try{n.push(new t.EtherscanProvider(e,r.etherscan))}catch(o){}if(t.AlchemyProvider)try{n.push(new t.AlchemyProvider(e,r.alchemy))}catch(o){}if(t.PocketProvider){try{var a=new t.PocketProvider(e);a.network&&-1===["goerli","ropsten","rinkeby"].indexOf(a.network.name)&&n.push(a)}catch(o){}}if(t.CloudflareProvider)try{n.push(new t.CloudflareProvider(e))}catch(o){}if(0===n.length)return null;if(t.FallbackProvider){var i=1;return null!=r.quorum?i=r.quorum:"homestead"===e&&(i=2),new t.FallbackProvider(n,i)}return n[0]};return t.renetwork=function(e){return a(e)},t}function i(e,t){var r=function(r,n){return r.JsonRpcProvider?new r.JsonRpcProvider(e,t):null};return r.renetwork=function(t){return i(e,t)},r}var o={chainId:1,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"homestead",_defaultProvider:a("homestead")},c={chainId:3,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"ropsten",_defaultProvider:a("ropsten")},s={chainId:63,name:"classicMordor",_defaultProvider:i("https://www.ethercluster.com/mordor","classicMordor")},f={unspecified:{chainId:0,name:"unspecified"},homestead:o,mainnet:o,morden:{chainId:2,name:"morden"},ropsten:c,testnet:c,rinkeby:{chainId:4,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"rinkeby",_defaultProvider:a("rinkeby")},kovan:{chainId:42,name:"kovan",_defaultProvider:a("kovan")},goerli:{chainId:5,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"goerli",_defaultProvider:a("goerli")},kintsugi:{chainId:1337702,name:"kintsugi"},classic:{chainId:61,name:"classic",_defaultProvider:i("https://www.ethercluster.com/etc","classic")},classicMorden:{chainId:62,name:"classicMorden"},classicMordor:s,classicTestnet:s,classicKotti:{chainId:6,name:"classicKotti",_defaultProvider:i("https://www.ethercluster.com/kotti","classicKotti")},xdai:{chainId:100,name:"xdai"},matic:{chainId:137,name:"matic"},maticmum:{chainId:80001,name:"maticmum"},optimism:{chainId:10,name:"optimism"},"optimism-kovan":{chainId:69,name:"optimism-kovan"},"optimism-goerli":{chainId:420,name:"optimism-goerli"},arbitrum:{chainId:42161,name:"arbitrum"},"arbitrum-rinkeby":{chainId:421611,name:"arbitrum-rinkeby"},bnb:{chainId:56,name:"bnb"},bnbt:{chainId:97,name:"bnbt"}};function d(e){if(null==e)return null;if("number"===typeof e){for(var t in f){var r=f[t];if(r.chainId===e)return{name:r.name,chainId:r.chainId,ensAddress:r.ensAddress||null,_defaultProvider:r._defaultProvider||null}}return{chainId:e,name:"unknown"}}if("string"===typeof e){var a=f[e];return null==a?null:{name:a.name,chainId:a.chainId,ensAddress:a.ensAddress,_defaultProvider:a._defaultProvider||null}}var i=f[e.name];if(!i)return"number"!==typeof e.chainId&&n.throwArgumentError("invalid network chainId","network",e),e;0!==e.chainId&&e.chainId!==i.chainId&&n.throwArgumentError("network chainId mismatch","network",e);var o,c=e._defaultProvider||null;return null==c&&i._defaultProvider&&(c=(o=i._defaultProvider)&&"function"===typeof o.renetwork?i._defaultProvider.renetwork(e):i._defaultProvider),{name:e.name,chainId:i.chainId,ensAddress:e.ensAddress||i.ensAddress||null,_defaultProvider:c}}},function(e,t,r){"use strict";var n=r(603),a={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},i={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},o={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},c={};function s(e){return n.isMemo(e)?o:c[e.$$typeof]||a}c[n.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},c[n.Memo]=o;var f=Object.defineProperty,d=Object.getOwnPropertyNames,u=Object.getOwnPropertySymbols,l=Object.getOwnPropertyDescriptor,b=Object.getPrototypeOf,h=Object.prototype;e.exports=function e(t,r,n){if("string"!==typeof r){if(h){var a=b(r);a&&a!==h&&e(t,a,n)}var o=d(r);u&&(o=o.concat(u(r)));for(var c=s(t),p=s(r),m=0;m=0)throw e;return b.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",u.a.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,tx:r})}))),null==r.chainId?r.chainId=this.getChainId():r.chainId=Promise.all([Promise.resolve(r.chainId),this.getChainId()]).then((function(t){return 0!==t[1]&&t[0]!==t[1]&&b.throwArgumentError("chainId address mismatch","transaction",e),t[0]})),t.next=23,Object(d.f)(r);case 23:return t.abrupt("return",t.sent);case 24:case"end":return t.stop()}}),t,this)})))}},{key:"_checkProvider",value:function(e){this.provider||b.throwError("missing provider",u.a.errors.UNSUPPORTED_OPERATION,{operation:e||"_checkProvider"})}}],[{key:"isSigner",value:function(e){return!(!e||!e._isSigner)}}]),e}(),v=function(e){Object(a.a)(r,e);var t=Object(i.a)(r);function r(e,a){var i;return Object(s.a)(this,r),b.checkNew(this instanceof r?this.constructor:void 0,r),i=t.call(this),Object(d.d)(Object(n.a)(i),"address",e),Object(d.d)(Object(n.a)(i),"provider",a||null),i}return Object(f.a)(r,[{key:"getAddress",value:function(){return Promise.resolve(this.address)}},{key:"_fail",value:function(e,t){return Promise.resolve().then((function(){b.throwError(e,u.a.errors.UNSUPPORTED_OPERATION,{operation:t})}))}},{key:"signMessage",value:function(e){return this._fail("VoidSigner cannot sign messages","signMessage")}},{key:"signTransaction",value:function(e){return this._fail("VoidSigner cannot sign transactions","signTransaction")}},{key:"_signTypedData",value:function(e,t,r){return this._fail("VoidSigner cannot sign typed data","signTypedData")}},{key:"connect",value:function(e){return new r(this.address,e)}}]),r}(m)},function(e,t,r){"use strict";r.d(t,"a",(function(){return o}));var n=r(164),a=r.n(n),i=r(73);function o(e,t){if(t&&("object"===a()(t)||"function"===typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return Object(i.a)(e)}},,function(e,t){e.exports=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}},,function(e,t,r){(function(e){!function(e,t){"use strict";function n(e,t){if(!e)throw new Error(t||"Assertion failed")}function a(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function i(e,t,r){if(i.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var o;"object"===typeof e?e.exports=i:t.BN=i,i.BN=i,i.wordSize=26;try{o="undefined"!==typeof window&&"undefined"!==typeof window.Buffer?window.Buffer:r(633).Buffer}catch(A){}function c(e,t){var r=e.charCodeAt(t);return r>=48&&r<=57?r-48:r>=65&&r<=70?r-55:r>=97&&r<=102?r-87:void n(!1,"Invalid character in "+e)}function s(e,t,r){var n=c(e,r);return r-1>=t&&(n|=c(e,r-1)<<4),n}function f(e,t,r,a){for(var i=0,o=0,c=Math.min(e.length,r),s=t;s=49?f-49+10:f>=17?f-17+10:f,n(f>=0&&o0?e:t},i.min=function(e,t){return e.cmp(t)<0?e:t},i.prototype._init=function(e,t,r){if("number"===typeof e)return this._initNumber(e,t,r);if("object"===typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var a=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(a++,this.negative=1),a=0;a-=3)o=e[a]|e[a-1]<<8|e[a-2]<<16,this.words[i]|=o<>>26-c&67108863,(c+=24)>=26&&(c-=26,i++);else if("le"===r)for(a=0,i=0;a>>26-c&67108863,(c+=24)>=26&&(c-=26,i++);return this._strip()},i.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)a=s(e,t,n)<=18?(i-=18,o+=1,this.words[o]|=a>>>26):i+=8;else for(n=(e.length-t)%2===0?t+1:t;n=18?(i-=18,o+=1,this.words[o]|=a>>>26):i+=8;this._strip()},i.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,a=1;a<=67108863;a*=t)n++;n--,a=a/t|0;for(var i=e.length-r,o=i%n,c=Math.min(i,i-o)+r,s=0,d=r;d1&&0===this.words[this.length-1];)this.length--;return this._normSign()},i.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},"undefined"!==typeof Symbol&&"function"===typeof Symbol.for)try{i.prototype[Symbol.for("nodejs.util.inspect.custom")]=u}catch(A){i.prototype.inspect=u}else i.prototype.inspect=u;function u(){return(this.red?""}var l=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],b=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],h=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];i.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var a=0,i=0,o=0;o>>24-a&16777215)||o!==this.length-1?l[6-s.length]+s+r:s+r,(a+=2)>=26&&(a-=26,o--)}for(0!==i&&(r=i.toString(16)+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var f=b[e],d=h[e];r="";var u=this.clone();for(u.negative=0;!u.isZero();){var p=u.modrn(d).toString(e);r=(u=u.idivn(d)).isZero()?p+r:l[f-p.length]+p+r}for(this.isZero()&&(r="0"+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},i.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},i.prototype.toJSON=function(){return this.toString(16,2)},o&&(i.prototype.toBuffer=function(e,t){return this.toArrayLike(o,e,t)}),i.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)};function p(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var a=0|e.words[0],i=0|t.words[0],o=a*i,c=67108863&o,s=o/67108864|0;r.words[0]=c;for(var f=1;f>>26,u=67108863&s,l=Math.min(f,t.length-1),b=Math.max(0,f-e.length+1);b<=l;b++){var h=f-b|0;d+=(o=(a=0|e.words[h])*(i=0|t.words[b])+u)/67108864|0,u=67108863&o}r.words[f]=0|u,s=0|d}return 0!==s?r.words[f]=0|s:r.length--,r._strip()}i.prototype.toArrayLike=function(e,t,r){this._strip();var a=this.byteLength(),i=r||Math.max(1,a);n(a<=i,"byte array longer than desired length"),n(i>0,"Requested array length <= 0");var o=function(e,t){return e.allocUnsafe?e.allocUnsafe(t):new e(t)}(e,i);return this["_toArrayLike"+("le"===t?"LE":"BE")](o,a),o},i.prototype._toArrayLikeLE=function(e,t){for(var r=0,n=0,a=0,i=0;a>8&255),r>16&255),6===i?(r>24&255),n=0,i=0):(n=o>>>24,i+=2)}if(r=0&&(e[r--]=o>>8&255),r>=0&&(e[r--]=o>>16&255),6===i?(r>=0&&(e[r--]=o>>24&255),n=0,i=0):(n=o>>>24,i+=2)}if(r>=0)for(e[r--]=n;r>=0;)e[r--]=0},Math.clz32?i.prototype._countBits=function(e){return 32-Math.clz32(e)}:i.prototype._countBits=function(e){var t=e,r=0;return t>=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},i.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0===(8191&t)&&(r+=13,t>>>=13),0===(127&t)&&(r+=7,t>>>=7),0===(15&t)&&(r+=4,t>>>=4),0===(3&t)&&(r+=2,t>>>=2),0===(1&t)&&r++,r},i.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},i.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},i.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},i.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},i.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},i.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},i.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},i.prototype.inotn=function(e){n("number"===typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var a=0;a0&&(this.words[a]=~this.words[a]&67108863>>26-r),this._strip()},i.prototype.notn=function(e){return this.clone().inotn(e)},i.prototype.setn=function(e,t){n("number"===typeof e&&e>=0);var r=e/26|0,a=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var a=0,i=0;i>>26;for(;0!==a&&i>>26;if(this.length=r.length,0!==a)this.words[this.length]=a,this.length++;else if(r!==this)for(;ie.length?this.clone().iadd(e):e.clone().iadd(this)},i.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,a=this.cmp(e);if(0===a)return this.negative=0,this.length=1,this.words[0]=0,this;a>0?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>26,this.words[o]=67108863&t;for(;0!==i&&o>26,this.words[o]=67108863&t;if(0===i&&o>>13,b=0|o[1],h=8191&b,p=b>>>13,m=0|o[2],v=8191&m,g=m>>>13,x=0|o[3],y=8191&x,w=x>>>13,k=0|o[4],_=8191&k,M=k>>>13,S=0|o[5],E=8191&S,O=S>>>13,A=0|o[6],T=8191&A,j=A>>>13,P=0|o[7],C=8191&P,R=P>>>13,N=0|o[8],B=8191&N,L=N>>>13,I=0|o[9],F=8191&I,D=I>>>13,U=0|c[0],z=8191&U,H=U>>>13,q=0|c[1],J=8191&q,V=q>>>13,G=0|c[2],X=8191&G,K=G>>>13,W=0|c[3],Z=8191&W,$=W>>>13,Q=0|c[4],Y=8191&Q,ee=Q>>>13,te=0|c[5],re=8191&te,ne=te>>>13,ae=0|c[6],ie=8191&ae,oe=ae>>>13,ce=0|c[7],se=8191&ce,fe=ce>>>13,de=0|c[8],ue=8191&de,le=de>>>13,be=0|c[9],he=8191&be,pe=be>>>13;r.negative=e.negative^t.negative,r.length=19;var me=(f+(n=Math.imul(u,z))|0)+((8191&(a=(a=Math.imul(u,H))+Math.imul(l,z)|0))<<13)|0;f=((i=Math.imul(l,H))+(a>>>13)|0)+(me>>>26)|0,me&=67108863,n=Math.imul(h,z),a=(a=Math.imul(h,H))+Math.imul(p,z)|0,i=Math.imul(p,H);var ve=(f+(n=n+Math.imul(u,J)|0)|0)+((8191&(a=(a=a+Math.imul(u,V)|0)+Math.imul(l,J)|0))<<13)|0;f=((i=i+Math.imul(l,V)|0)+(a>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(v,z),a=(a=Math.imul(v,H))+Math.imul(g,z)|0,i=Math.imul(g,H),n=n+Math.imul(h,J)|0,a=(a=a+Math.imul(h,V)|0)+Math.imul(p,J)|0,i=i+Math.imul(p,V)|0;var ge=(f+(n=n+Math.imul(u,X)|0)|0)+((8191&(a=(a=a+Math.imul(u,K)|0)+Math.imul(l,X)|0))<<13)|0;f=((i=i+Math.imul(l,K)|0)+(a>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(y,z),a=(a=Math.imul(y,H))+Math.imul(w,z)|0,i=Math.imul(w,H),n=n+Math.imul(v,J)|0,a=(a=a+Math.imul(v,V)|0)+Math.imul(g,J)|0,i=i+Math.imul(g,V)|0,n=n+Math.imul(h,X)|0,a=(a=a+Math.imul(h,K)|0)+Math.imul(p,X)|0,i=i+Math.imul(p,K)|0;var xe=(f+(n=n+Math.imul(u,Z)|0)|0)+((8191&(a=(a=a+Math.imul(u,$)|0)+Math.imul(l,Z)|0))<<13)|0;f=((i=i+Math.imul(l,$)|0)+(a>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(_,z),a=(a=Math.imul(_,H))+Math.imul(M,z)|0,i=Math.imul(M,H),n=n+Math.imul(y,J)|0,a=(a=a+Math.imul(y,V)|0)+Math.imul(w,J)|0,i=i+Math.imul(w,V)|0,n=n+Math.imul(v,X)|0,a=(a=a+Math.imul(v,K)|0)+Math.imul(g,X)|0,i=i+Math.imul(g,K)|0,n=n+Math.imul(h,Z)|0,a=(a=a+Math.imul(h,$)|0)+Math.imul(p,Z)|0,i=i+Math.imul(p,$)|0;var ye=(f+(n=n+Math.imul(u,Y)|0)|0)+((8191&(a=(a=a+Math.imul(u,ee)|0)+Math.imul(l,Y)|0))<<13)|0;f=((i=i+Math.imul(l,ee)|0)+(a>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(E,z),a=(a=Math.imul(E,H))+Math.imul(O,z)|0,i=Math.imul(O,H),n=n+Math.imul(_,J)|0,a=(a=a+Math.imul(_,V)|0)+Math.imul(M,J)|0,i=i+Math.imul(M,V)|0,n=n+Math.imul(y,X)|0,a=(a=a+Math.imul(y,K)|0)+Math.imul(w,X)|0,i=i+Math.imul(w,K)|0,n=n+Math.imul(v,Z)|0,a=(a=a+Math.imul(v,$)|0)+Math.imul(g,Z)|0,i=i+Math.imul(g,$)|0,n=n+Math.imul(h,Y)|0,a=(a=a+Math.imul(h,ee)|0)+Math.imul(p,Y)|0,i=i+Math.imul(p,ee)|0;var we=(f+(n=n+Math.imul(u,re)|0)|0)+((8191&(a=(a=a+Math.imul(u,ne)|0)+Math.imul(l,re)|0))<<13)|0;f=((i=i+Math.imul(l,ne)|0)+(a>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(T,z),a=(a=Math.imul(T,H))+Math.imul(j,z)|0,i=Math.imul(j,H),n=n+Math.imul(E,J)|0,a=(a=a+Math.imul(E,V)|0)+Math.imul(O,J)|0,i=i+Math.imul(O,V)|0,n=n+Math.imul(_,X)|0,a=(a=a+Math.imul(_,K)|0)+Math.imul(M,X)|0,i=i+Math.imul(M,K)|0,n=n+Math.imul(y,Z)|0,a=(a=a+Math.imul(y,$)|0)+Math.imul(w,Z)|0,i=i+Math.imul(w,$)|0,n=n+Math.imul(v,Y)|0,a=(a=a+Math.imul(v,ee)|0)+Math.imul(g,Y)|0,i=i+Math.imul(g,ee)|0,n=n+Math.imul(h,re)|0,a=(a=a+Math.imul(h,ne)|0)+Math.imul(p,re)|0,i=i+Math.imul(p,ne)|0;var ke=(f+(n=n+Math.imul(u,ie)|0)|0)+((8191&(a=(a=a+Math.imul(u,oe)|0)+Math.imul(l,ie)|0))<<13)|0;f=((i=i+Math.imul(l,oe)|0)+(a>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(C,z),a=(a=Math.imul(C,H))+Math.imul(R,z)|0,i=Math.imul(R,H),n=n+Math.imul(T,J)|0,a=(a=a+Math.imul(T,V)|0)+Math.imul(j,J)|0,i=i+Math.imul(j,V)|0,n=n+Math.imul(E,X)|0,a=(a=a+Math.imul(E,K)|0)+Math.imul(O,X)|0,i=i+Math.imul(O,K)|0,n=n+Math.imul(_,Z)|0,a=(a=a+Math.imul(_,$)|0)+Math.imul(M,Z)|0,i=i+Math.imul(M,$)|0,n=n+Math.imul(y,Y)|0,a=(a=a+Math.imul(y,ee)|0)+Math.imul(w,Y)|0,i=i+Math.imul(w,ee)|0,n=n+Math.imul(v,re)|0,a=(a=a+Math.imul(v,ne)|0)+Math.imul(g,re)|0,i=i+Math.imul(g,ne)|0,n=n+Math.imul(h,ie)|0,a=(a=a+Math.imul(h,oe)|0)+Math.imul(p,ie)|0,i=i+Math.imul(p,oe)|0;var _e=(f+(n=n+Math.imul(u,se)|0)|0)+((8191&(a=(a=a+Math.imul(u,fe)|0)+Math.imul(l,se)|0))<<13)|0;f=((i=i+Math.imul(l,fe)|0)+(a>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(B,z),a=(a=Math.imul(B,H))+Math.imul(L,z)|0,i=Math.imul(L,H),n=n+Math.imul(C,J)|0,a=(a=a+Math.imul(C,V)|0)+Math.imul(R,J)|0,i=i+Math.imul(R,V)|0,n=n+Math.imul(T,X)|0,a=(a=a+Math.imul(T,K)|0)+Math.imul(j,X)|0,i=i+Math.imul(j,K)|0,n=n+Math.imul(E,Z)|0,a=(a=a+Math.imul(E,$)|0)+Math.imul(O,Z)|0,i=i+Math.imul(O,$)|0,n=n+Math.imul(_,Y)|0,a=(a=a+Math.imul(_,ee)|0)+Math.imul(M,Y)|0,i=i+Math.imul(M,ee)|0,n=n+Math.imul(y,re)|0,a=(a=a+Math.imul(y,ne)|0)+Math.imul(w,re)|0,i=i+Math.imul(w,ne)|0,n=n+Math.imul(v,ie)|0,a=(a=a+Math.imul(v,oe)|0)+Math.imul(g,ie)|0,i=i+Math.imul(g,oe)|0,n=n+Math.imul(h,se)|0,a=(a=a+Math.imul(h,fe)|0)+Math.imul(p,se)|0,i=i+Math.imul(p,fe)|0;var Me=(f+(n=n+Math.imul(u,ue)|0)|0)+((8191&(a=(a=a+Math.imul(u,le)|0)+Math.imul(l,ue)|0))<<13)|0;f=((i=i+Math.imul(l,le)|0)+(a>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,z),a=(a=Math.imul(F,H))+Math.imul(D,z)|0,i=Math.imul(D,H),n=n+Math.imul(B,J)|0,a=(a=a+Math.imul(B,V)|0)+Math.imul(L,J)|0,i=i+Math.imul(L,V)|0,n=n+Math.imul(C,X)|0,a=(a=a+Math.imul(C,K)|0)+Math.imul(R,X)|0,i=i+Math.imul(R,K)|0,n=n+Math.imul(T,Z)|0,a=(a=a+Math.imul(T,$)|0)+Math.imul(j,Z)|0,i=i+Math.imul(j,$)|0,n=n+Math.imul(E,Y)|0,a=(a=a+Math.imul(E,ee)|0)+Math.imul(O,Y)|0,i=i+Math.imul(O,ee)|0,n=n+Math.imul(_,re)|0,a=(a=a+Math.imul(_,ne)|0)+Math.imul(M,re)|0,i=i+Math.imul(M,ne)|0,n=n+Math.imul(y,ie)|0,a=(a=a+Math.imul(y,oe)|0)+Math.imul(w,ie)|0,i=i+Math.imul(w,oe)|0,n=n+Math.imul(v,se)|0,a=(a=a+Math.imul(v,fe)|0)+Math.imul(g,se)|0,i=i+Math.imul(g,fe)|0,n=n+Math.imul(h,ue)|0,a=(a=a+Math.imul(h,le)|0)+Math.imul(p,ue)|0,i=i+Math.imul(p,le)|0;var Se=(f+(n=n+Math.imul(u,he)|0)|0)+((8191&(a=(a=a+Math.imul(u,pe)|0)+Math.imul(l,he)|0))<<13)|0;f=((i=i+Math.imul(l,pe)|0)+(a>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(F,J),a=(a=Math.imul(F,V))+Math.imul(D,J)|0,i=Math.imul(D,V),n=n+Math.imul(B,X)|0,a=(a=a+Math.imul(B,K)|0)+Math.imul(L,X)|0,i=i+Math.imul(L,K)|0,n=n+Math.imul(C,Z)|0,a=(a=a+Math.imul(C,$)|0)+Math.imul(R,Z)|0,i=i+Math.imul(R,$)|0,n=n+Math.imul(T,Y)|0,a=(a=a+Math.imul(T,ee)|0)+Math.imul(j,Y)|0,i=i+Math.imul(j,ee)|0,n=n+Math.imul(E,re)|0,a=(a=a+Math.imul(E,ne)|0)+Math.imul(O,re)|0,i=i+Math.imul(O,ne)|0,n=n+Math.imul(_,ie)|0,a=(a=a+Math.imul(_,oe)|0)+Math.imul(M,ie)|0,i=i+Math.imul(M,oe)|0,n=n+Math.imul(y,se)|0,a=(a=a+Math.imul(y,fe)|0)+Math.imul(w,se)|0,i=i+Math.imul(w,fe)|0,n=n+Math.imul(v,ue)|0,a=(a=a+Math.imul(v,le)|0)+Math.imul(g,ue)|0,i=i+Math.imul(g,le)|0;var Ee=(f+(n=n+Math.imul(h,he)|0)|0)+((8191&(a=(a=a+Math.imul(h,pe)|0)+Math.imul(p,he)|0))<<13)|0;f=((i=i+Math.imul(p,pe)|0)+(a>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,X),a=(a=Math.imul(F,K))+Math.imul(D,X)|0,i=Math.imul(D,K),n=n+Math.imul(B,Z)|0,a=(a=a+Math.imul(B,$)|0)+Math.imul(L,Z)|0,i=i+Math.imul(L,$)|0,n=n+Math.imul(C,Y)|0,a=(a=a+Math.imul(C,ee)|0)+Math.imul(R,Y)|0,i=i+Math.imul(R,ee)|0,n=n+Math.imul(T,re)|0,a=(a=a+Math.imul(T,ne)|0)+Math.imul(j,re)|0,i=i+Math.imul(j,ne)|0,n=n+Math.imul(E,ie)|0,a=(a=a+Math.imul(E,oe)|0)+Math.imul(O,ie)|0,i=i+Math.imul(O,oe)|0,n=n+Math.imul(_,se)|0,a=(a=a+Math.imul(_,fe)|0)+Math.imul(M,se)|0,i=i+Math.imul(M,fe)|0,n=n+Math.imul(y,ue)|0,a=(a=a+Math.imul(y,le)|0)+Math.imul(w,ue)|0,i=i+Math.imul(w,le)|0;var Oe=(f+(n=n+Math.imul(v,he)|0)|0)+((8191&(a=(a=a+Math.imul(v,pe)|0)+Math.imul(g,he)|0))<<13)|0;f=((i=i+Math.imul(g,pe)|0)+(a>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,Z),a=(a=Math.imul(F,$))+Math.imul(D,Z)|0,i=Math.imul(D,$),n=n+Math.imul(B,Y)|0,a=(a=a+Math.imul(B,ee)|0)+Math.imul(L,Y)|0,i=i+Math.imul(L,ee)|0,n=n+Math.imul(C,re)|0,a=(a=a+Math.imul(C,ne)|0)+Math.imul(R,re)|0,i=i+Math.imul(R,ne)|0,n=n+Math.imul(T,ie)|0,a=(a=a+Math.imul(T,oe)|0)+Math.imul(j,ie)|0,i=i+Math.imul(j,oe)|0,n=n+Math.imul(E,se)|0,a=(a=a+Math.imul(E,fe)|0)+Math.imul(O,se)|0,i=i+Math.imul(O,fe)|0,n=n+Math.imul(_,ue)|0,a=(a=a+Math.imul(_,le)|0)+Math.imul(M,ue)|0,i=i+Math.imul(M,le)|0;var Ae=(f+(n=n+Math.imul(y,he)|0)|0)+((8191&(a=(a=a+Math.imul(y,pe)|0)+Math.imul(w,he)|0))<<13)|0;f=((i=i+Math.imul(w,pe)|0)+(a>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(F,Y),a=(a=Math.imul(F,ee))+Math.imul(D,Y)|0,i=Math.imul(D,ee),n=n+Math.imul(B,re)|0,a=(a=a+Math.imul(B,ne)|0)+Math.imul(L,re)|0,i=i+Math.imul(L,ne)|0,n=n+Math.imul(C,ie)|0,a=(a=a+Math.imul(C,oe)|0)+Math.imul(R,ie)|0,i=i+Math.imul(R,oe)|0,n=n+Math.imul(T,se)|0,a=(a=a+Math.imul(T,fe)|0)+Math.imul(j,se)|0,i=i+Math.imul(j,fe)|0,n=n+Math.imul(E,ue)|0,a=(a=a+Math.imul(E,le)|0)+Math.imul(O,ue)|0,i=i+Math.imul(O,le)|0;var Te=(f+(n=n+Math.imul(_,he)|0)|0)+((8191&(a=(a=a+Math.imul(_,pe)|0)+Math.imul(M,he)|0))<<13)|0;f=((i=i+Math.imul(M,pe)|0)+(a>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,re),a=(a=Math.imul(F,ne))+Math.imul(D,re)|0,i=Math.imul(D,ne),n=n+Math.imul(B,ie)|0,a=(a=a+Math.imul(B,oe)|0)+Math.imul(L,ie)|0,i=i+Math.imul(L,oe)|0,n=n+Math.imul(C,se)|0,a=(a=a+Math.imul(C,fe)|0)+Math.imul(R,se)|0,i=i+Math.imul(R,fe)|0,n=n+Math.imul(T,ue)|0,a=(a=a+Math.imul(T,le)|0)+Math.imul(j,ue)|0,i=i+Math.imul(j,le)|0;var je=(f+(n=n+Math.imul(E,he)|0)|0)+((8191&(a=(a=a+Math.imul(E,pe)|0)+Math.imul(O,he)|0))<<13)|0;f=((i=i+Math.imul(O,pe)|0)+(a>>>13)|0)+(je>>>26)|0,je&=67108863,n=Math.imul(F,ie),a=(a=Math.imul(F,oe))+Math.imul(D,ie)|0,i=Math.imul(D,oe),n=n+Math.imul(B,se)|0,a=(a=a+Math.imul(B,fe)|0)+Math.imul(L,se)|0,i=i+Math.imul(L,fe)|0,n=n+Math.imul(C,ue)|0,a=(a=a+Math.imul(C,le)|0)+Math.imul(R,ue)|0,i=i+Math.imul(R,le)|0;var Pe=(f+(n=n+Math.imul(T,he)|0)|0)+((8191&(a=(a=a+Math.imul(T,pe)|0)+Math.imul(j,he)|0))<<13)|0;f=((i=i+Math.imul(j,pe)|0)+(a>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,se),a=(a=Math.imul(F,fe))+Math.imul(D,se)|0,i=Math.imul(D,fe),n=n+Math.imul(B,ue)|0,a=(a=a+Math.imul(B,le)|0)+Math.imul(L,ue)|0,i=i+Math.imul(L,le)|0;var Ce=(f+(n=n+Math.imul(C,he)|0)|0)+((8191&(a=(a=a+Math.imul(C,pe)|0)+Math.imul(R,he)|0))<<13)|0;f=((i=i+Math.imul(R,pe)|0)+(a>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,n=Math.imul(F,ue),a=(a=Math.imul(F,le))+Math.imul(D,ue)|0,i=Math.imul(D,le);var Re=(f+(n=n+Math.imul(B,he)|0)|0)+((8191&(a=(a=a+Math.imul(B,pe)|0)+Math.imul(L,he)|0))<<13)|0;f=((i=i+Math.imul(L,pe)|0)+(a>>>13)|0)+(Re>>>26)|0,Re&=67108863;var Ne=(f+(n=Math.imul(F,he))|0)+((8191&(a=(a=Math.imul(F,pe))+Math.imul(D,he)|0))<<13)|0;return f=((i=Math.imul(D,pe))+(a>>>13)|0)+(Ne>>>26)|0,Ne&=67108863,s[0]=me,s[1]=ve,s[2]=ge,s[3]=xe,s[4]=ye,s[5]=we,s[6]=ke,s[7]=_e,s[8]=Me,s[9]=Se,s[10]=Ee,s[11]=Oe,s[12]=Ae,s[13]=Te,s[14]=je,s[15]=Pe,s[16]=Ce,s[17]=Re,s[18]=Ne,0!==f&&(s[19]=f,r.length++),r};function v(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,a=0,i=0;i>>26)|0)>>>26,o&=67108863}r.words[i]=c,n=o,o=a}return 0!==n?r.words[i]=n:r.length--,r._strip()}function g(e,t,r){return v(e,t,r)}function x(e,t){this.x=e,this.y=t}Math.imul||(m=p),i.prototype.mulTo=function(e,t){var r=this.length+e.length;return 10===this.length&&10===e.length?m(this,e,t):r<63?p(this,e,t):r<1024?v(this,e,t):g(this,e,t)},x.prototype.makeRBT=function(e){for(var t=new Array(e),r=i.prototype._countBits(e)-1,n=0;n>=1;return n},x.prototype.permute=function(e,t,r,n,a,i){for(var o=0;o>>=1)a++;return 1<>>=13,r[2*o+1]=8191&i,i>>>=13;for(o=2*t;o>=26,r+=i/67108864|0,r+=o>>>26,this.words[a]=67108863&o}return 0!==r&&(this.words[a]=r,this.length++),t?this.ineg():this},i.prototype.muln=function(e){return this.clone().imuln(e)},i.prototype.sqr=function(){return this.mul(this)},i.prototype.isqr=function(){return this.imul(this.clone())},i.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>a&1}return t}(e);if(0===t.length)return new i(1);for(var r=this,n=0;n=0);var t,r=e%26,a=(e-r)/26,i=67108863>>>26-r<<26-r;if(0!==r){var o=0;for(t=0;t>>26-r}o&&(this.words[t]=o,this.length++)}if(0!==a){for(t=this.length-1;t>=0;t--)this.words[t+a]=this.words[t];for(t=0;t=0),a=t?(t-t%26)/26:0;var i=e%26,o=Math.min((e-i)/26,this.length),c=67108863^67108863>>>i<o)for(this.length-=o,f=0;f=0&&(0!==d||f>=a);f--){var u=0|this.words[f];this.words[f]=d<<26-i|u>>>i,d=u&c}return s&&0!==d&&(s.words[s.length++]=d),0===this.length&&(this.words[0]=0,this.length=1),this._strip()},i.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},i.prototype.shln=function(e){return this.clone().ishln(e)},i.prototype.ushln=function(e){return this.clone().iushln(e)},i.prototype.shrn=function(e){return this.clone().ishrn(e)},i.prototype.ushrn=function(e){return this.clone().iushrn(e)},i.prototype.testn=function(e){n("number"===typeof e&&e>=0);var t=e%26,r=(e-t)/26,a=1<=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var a=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},i.prototype.isubn=function(e){if(n("number"===typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(s/67108864|0),this.words[a+r]=67108863&i}for(;a>26,this.words[a+r]=67108863&i;if(0===c)return this._strip();for(n(-1===c),c=0,a=0;a>26,this.words[a]=67108863&i;return this.negative=1,this._strip()},i.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),a=e,o=0|a.words[a.length-1];0!==(r=26-this._countBits(o))&&(a=a.ushln(r),n.iushln(r),o=0|a.words[a.length-1]);var c,s=n.length-a.length;if("mod"!==t){(c=new i(null)).length=s+1,c.words=new Array(c.length);for(var f=0;f=0;u--){var l=67108864*(0|n.words[a.length+u])+(0|n.words[a.length+u-1]);for(l=Math.min(l/o|0,67108863),n._ishlnsubmul(a,l,u);0!==n.negative;)l--,n.negative=0,n._ishlnsubmul(a,1,u),n.isZero()||(n.negative^=1);c&&(c.words[u]=l)}return c&&c._strip(),n._strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:c||null,mod:n}},i.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new i(0),mod:new i(0)}:0!==this.negative&&0===e.negative?(c=this.neg().divmod(e,t),"mod"!==t&&(a=c.div.neg()),"div"!==t&&(o=c.mod.neg(),r&&0!==o.negative&&o.iadd(e)),{div:a,mod:o}):0===this.negative&&0!==e.negative?(c=this.divmod(e.neg(),t),"mod"!==t&&(a=c.div.neg()),{div:a,mod:c.mod}):0!==(this.negative&e.negative)?(c=this.neg().divmod(e.neg(),t),"div"!==t&&(o=c.mod.neg(),r&&0!==o.negative&&o.isub(e)),{div:c.div,mod:o}):e.length>this.length||this.cmp(e)<0?{div:new i(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new i(this.modrn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new i(this.modrn(e.words[0]))}:this._wordDiv(e,t);var a,o,c},i.prototype.div=function(e){return this.divmod(e,"div",!1).div},i.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},i.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},i.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),a=e.andln(1),i=r.cmp(n);return i<0||1===a&&0===i?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},i.prototype.modrn=function(e){var t=e<0;t&&(e=-e),n(e<=67108863);for(var r=(1<<26)%e,a=0,i=this.length-1;i>=0;i--)a=(r*a+(0|this.words[i]))%e;return t?-a:a},i.prototype.modn=function(e){return this.modrn(e)},i.prototype.idivn=function(e){var t=e<0;t&&(e=-e),n(e<=67108863);for(var r=0,a=this.length-1;a>=0;a--){var i=(0|this.words[a])+67108864*r;this.words[a]=i/e|0,r=i%e}return this._strip(),t?this.ineg():this},i.prototype.divn=function(e){return this.clone().idivn(e)},i.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var a=new i(1),o=new i(0),c=new i(0),s=new i(1),f=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++f;for(var d=r.clone(),u=t.clone();!t.isZero();){for(var l=0,b=1;0===(t.words[0]&b)&&l<26;++l,b<<=1);if(l>0)for(t.iushrn(l);l-- >0;)(a.isOdd()||o.isOdd())&&(a.iadd(d),o.isub(u)),a.iushrn(1),o.iushrn(1);for(var h=0,p=1;0===(r.words[0]&p)&&h<26;++h,p<<=1);if(h>0)for(r.iushrn(h);h-- >0;)(c.isOdd()||s.isOdd())&&(c.iadd(d),s.isub(u)),c.iushrn(1),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(c),o.isub(s)):(r.isub(t),c.isub(a),s.isub(o))}return{a:c,b:s,gcd:r.iushln(f)}},i.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var a,o=new i(1),c=new i(0),s=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var f=0,d=1;0===(t.words[0]&d)&&f<26;++f,d<<=1);if(f>0)for(t.iushrn(f);f-- >0;)o.isOdd()&&o.iadd(s),o.iushrn(1);for(var u=0,l=1;0===(r.words[0]&l)&&u<26;++u,l<<=1);if(u>0)for(r.iushrn(u);u-- >0;)c.isOdd()&&c.iadd(s),c.iushrn(1);t.cmp(r)>=0?(t.isub(r),o.isub(c)):(r.isub(t),c.isub(o))}return(a=0===t.cmpn(1)?o:c).cmpn(0)<0&&a.iadd(e),a},i.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var a=t.cmp(r);if(a<0){var i=t;t=r,r=i}else if(0===a||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},i.prototype.invm=function(e){return this.egcd(e).a.umod(e)},i.prototype.isEven=function(){return 0===(1&this.words[0])},i.prototype.isOdd=function(){return 1===(1&this.words[0])},i.prototype.andln=function(e){return this.words[0]&e},i.prototype.bincn=function(e){n("number"===typeof e);var t=e%26,r=(e-t)/26,a=1<>>26,c&=67108863,this.words[o]=c}return 0!==i&&(this.words[o]=i,this.length++),this},i.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},i.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this._strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var a=0|this.words[0];t=a===e?0:ae.length)return 1;if(this.length=0;r--){var n=0|this.words[r],a=0|e.words[r];if(n!==a){na&&(t=1);break}}return t},i.prototype.gtn=function(e){return 1===this.cmpn(e)},i.prototype.gt=function(e){return 1===this.cmp(e)},i.prototype.gten=function(e){return this.cmpn(e)>=0},i.prototype.gte=function(e){return this.cmp(e)>=0},i.prototype.ltn=function(e){return-1===this.cmpn(e)},i.prototype.lt=function(e){return-1===this.cmp(e)},i.prototype.lten=function(e){return this.cmpn(e)<=0},i.prototype.lte=function(e){return this.cmp(e)<=0},i.prototype.eqn=function(e){return 0===this.cmpn(e)},i.prototype.eq=function(e){return 0===this.cmp(e)},i.red=function(e){return new E(e)},i.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},i.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},i.prototype._forceRed=function(e){return this.red=e,this},i.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},i.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},i.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},i.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},i.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},i.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},i.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},i.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},i.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},i.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},i.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},i.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},i.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},i.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var y={k256:null,p224:null,p192:null,p25519:null};function w(e,t){this.name=e,this.p=new i(t,16),this.n=this.p.bitLength(),this.k=new i(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function k(){w.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function _(){w.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function M(){w.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function S(){w.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function E(e){if("string"===typeof e){var t=i._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function O(e){E.call(this,e),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new i(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}w.prototype._tmp=function(){var e=new i(null);return e.words=new Array(Math.ceil(this.n/13)),e},w.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},w.prototype.split=function(e,t){e.iushrn(this.n,0,t)},w.prototype.imulK=function(e){return e.imul(this.k)},a(k,w),k.prototype.split=function(e,t){for(var r=Math.min(e.length,9),n=0;n>>22,a=i}a>>>=22,e.words[n-10]=a,0===a&&e.length>10?e.length-=10:e.length-=9},k.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=a,t=n}return 0!==t&&(e.words[e.length++]=t),e},i._prime=function(e){if(y[e])return y[e];var t;if("k256"===e)t=new k;else if("p224"===e)t=new _;else if("p192"===e)t=new M;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new S}return y[e]=t,t},E.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},E.prototype._verify2=function(e,t){n(0===(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},E.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):(d(e,e.umod(this.m)._forceRed(this)),e)},E.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},E.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},E.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},E.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},E.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},E.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},E.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},E.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},E.prototype.isqr=function(e){return this.imul(e,e.clone())},E.prototype.sqr=function(e){return this.mul(e,e)},E.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2===1),3===t){var r=this.m.add(new i(1)).iushrn(2);return this.pow(e,r)}for(var a=this.m.subn(1),o=0;!a.isZero()&&0===a.andln(1);)o++,a.iushrn(1);n(!a.isZero());var c=new i(1).toRed(this),s=c.redNeg(),f=this.m.subn(1).iushrn(1),d=this.m.bitLength();for(d=new i(2*d*d).toRed(this);0!==this.pow(d,f).cmp(s);)d.redIAdd(s);for(var u=this.pow(d,a),l=this.pow(e,a.addn(1).iushrn(1)),b=this.pow(e,a),h=o;0!==b.cmp(c);){for(var p=b,m=0;0!==p.cmp(c);m++)p=p.redSqr();n(m=0;n--){for(var f=t.words[n],d=s-1;d>=0;d--){var u=f>>d&1;a!==r[0]&&(a=this.sqr(a)),0!==u||0!==o?(o<<=1,o|=u,(4===++c||0===n&&0===d)&&(a=this.mul(a,r[o]),c=0,o=0)):c=0}s=26}return a},E.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},E.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},i.mont=function(e){return new O(e)},a(O,E),O.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},O.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},O.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),a=r.isub(n).iushrn(this.shift),i=a;return a.cmp(this.m)>=0?i=a.isub(this.m):a.cmpn(0)<0&&(i=a.iadd(this.m)),i._forceRed(this)},O.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new i(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),a=r.isub(n).iushrn(this.shift),o=a;return a.cmp(this.m)>=0?o=a.isub(this.m):a.cmpn(0)<0&&(o=a.iadd(this.m)),o._forceRed(this)},O.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e,this)}).call(this,r(74)(e))},function(e,t,r){"use strict";(function(e){var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.baToJSON=t.toUtf8=t.addHexPrefix=t.toUnsigned=t.fromSigned=t.bufferToHex=t.bufferToInt=t.toBuffer=t.unpadHexString=t.unpadArray=t.unpadBuffer=t.setLengthRight=t.setLengthLeft=t.zeros=t.intToBuffer=t.intToHex=void 0;var a=n(r(150)),i=r(167),o=r(238);t.intToHex=function(e){if(!Number.isSafeInteger(e)||e<0)throw new Error("Received an invalid integer type: "+e);return"0x"+e.toString(16)};t.intToBuffer=function(r){var n=(0,t.intToHex)(r);return e.from((0,i.padToEven)(n.slice(2)),"hex")};t.zeros=function(t){return e.allocUnsafe(t).fill(0)};var c=function(e,r,n){var a=(0,t.zeros)(r);return n?e.length0&&"0"===t.toString();)t=(e=e.slice(1))[0];return e};t.unpadBuffer=function(e){return(0,o.assertIsBuffer)(e),s(e)};t.unpadArray=function(e){return(0,o.assertIsArray)(e),s(e)};t.unpadHexString=function(e){return(0,o.assertIsHexString)(e),e=(0,i.stripHexPrefix)(e),s(e)};t.toBuffer=function(r){if(null===r||void 0===r)return e.allocUnsafe(0);if(e.isBuffer(r))return e.from(r);if(Array.isArray(r)||r instanceof Uint8Array)return e.from(r);if("string"===typeof r){if(!(0,i.isHexString)(r))throw new Error("Cannot convert string to buffer. toBuffer only supports 0x-prefixed hex strings and this string was given: "+r);return e.from((0,i.padToEven)((0,i.stripHexPrefix)(r)),"hex")}if("number"===typeof r)return(0,t.intToBuffer)(r);if(a.default.isBN(r))return r.toArrayLike(e);if(r.toArray)return e.from(r.toArray());if(r.toBuffer)return e.from(r.toBuffer());throw new Error("invalid type")};t.bufferToInt=function(e){return new a.default((0,t.toBuffer)(e)).toNumber()};t.bufferToHex=function(e){return"0x"+(e=(0,t.toBuffer)(e)).toString("hex")};t.fromSigned=function(e){return new a.default(e).fromTwos(256)};t.toUnsigned=function(t){return e.from(t.toTwos(256).toArray())};t.addHexPrefix=function(e){return"string"!==typeof e||(0,i.isHexPrefixed)(e)?e:"0x"+e};t.toUtf8=function(t){if((t=(0,i.stripHexPrefix)(t)).length%2!==0)throw new Error("Invalid non-even hex string input for toUtf8() provided");return e.from(t.replace(/^(00)+|(00)+$/g,""),"hex").toString("utf8")};t.baToJSON=function(r){if(e.isBuffer(r))return"0x"+r.toString("hex");if(r instanceof Array){for(var n=[],a=0;a1?(e[r[0]]=e[r[0]]||{},e[r[0]][r[1]]=t):e[r[0]]=t},b.prototype.getCall=function(e){return"function"===typeof this.call?this.call(e):this.call},b.prototype.extractCallback=function(e){if("function"===typeof e[e.length-1])return e.pop()},b.prototype.validateArgs=function(e){if(e.length!==this.params)throw c.InvalidNumberOfParams(e.length,this.params,this.name)},b.prototype.formatInput=function(e){var t=this;return this.inputFormatter?this.inputFormatter.map((function(r,n){return r?r.call(t,e[n]):e[n]})):e},b.prototype.formatOutput=function(e){var t=this;return Array.isArray(e)?e.map((function(e){return t.outputFormatter&&e?t.outputFormatter(e):e})):this.outputFormatter&&e?this.outputFormatter(e):e},b.prototype.toPayload=function(e){var t=this.getCall(e),r=this.extractCallback(e),n=this.formatInput(e);this.validateArgs(n);var a={method:t,params:n,callback:r};return this.transformPayload&&(a=this.transformPayload(a)),a},b.prototype._confirmTransaction=function(e,t,r){var n=this,a=!1,h=!0,p=0,m=0,v=null,g=null,x=null,y=r.params[0]&&"object"===typeof r.params[0]&&r.params[0].gas?r.params[0].gas:null,w=!!r.params[0]&&"object"===typeof r.params[0]&&r.params[0].data&&r.params[0].from&&!r.params[0].to,k=w&&r.params[0].data.length>2,_=[new b({name:"getBlockByNumber",call:"eth_getBlockByNumber",params:2,inputFormatter:[s.inputBlockNumberFormatter,function(e){return!!e}],outputFormatter:s.outputBlockFormatter}),new b({name:"getTransactionReceipt",call:"eth_getTransactionReceipt",params:1,inputFormatter:[null],outputFormatter:s.outputTransactionReceiptFormatter}),new b({name:"getCode",call:"eth_getCode",params:2,inputFormatter:[s.inputAddressFormatter,s.inputDefaultBlockNumberFormatter]}),new b({name:"getTransactionByHash",call:"eth_getTransactionByHash",params:1,inputFormatter:[null],outputFormatter:s.outputTransactionFormatter}),new u({name:"subscribe",type:"eth",subscriptions:{newBlockHeaders:{subscriptionName:"newHeads",params:0,outputFormatter:s.outputBlockFormatter}}})],M={};_.forEach((function(e){e.attachToObject(M),e.requestManager=n.requestManager}));var S=function(u,b,_,S,E){if(!_)return E||(E={unsubscribe:function(){clearInterval(v),clearTimeout(g)}}),(u?d.resolve(u):M.getTransactionReceipt(t)).catch((function(t){E.unsubscribe(),a=!0,f._fireError({message:"Failed to check for transaction receipt:",data:t},e.eventEmitter,e.reject)})).then(function(){var t=o(i.mark((function t(r){var a,o,c;return i.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(r&&r.blockHash){t.next=2;break}throw new Error("Receipt missing or blockHash null");case 2:if(n.extraFormatters&&n.extraFormatters.receiptFormatter&&(r=n.extraFormatters.receiptFormatter(r)),!(e.eventEmitter.listeners("confirmation").length>0)){t.next=28;break}if(void 0!==u&&0===m){t.next=25;break}return t.next=7,M.getBlockByNumber("latest");case 7:if(o=t.sent,c=o?o.hash:null,!b){t.next=24;break}if(!x){t.next=17;break}return t.next=13,M.getBlockByNumber(x.number+1);case 13:(a=t.sent)&&(x=a,e.eventEmitter.emit("confirmation",m,r,c)),t.next=22;break;case 17:return t.next=19,M.getBlockByNumber(r.blockNumber);case 19:a=t.sent,x=a,e.eventEmitter.emit("confirmation",m,r,c);case 22:t.next=25;break;case 24:e.eventEmitter.emit("confirmation",m,r,c);case 25:(b&&a||!b)&&m++,h=!1,m===n.transactionConfirmationBlocks+1&&(E.unsubscribe(),e.eventEmitter.removeAllListeners());case 28:return t.abrupt("return",r);case 29:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}()).then(function(){var t=o(i.mark((function t(r){var o;return i.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!w||a){t.next=19;break}if(r.contractAddress){t.next=5;break}return h&&(E.unsubscribe(),a=!0),f._fireError(c.NoContractAddressFoundError(r),e.eventEmitter,e.reject,null,r),t.abrupt("return");case 5:return t.prev=5,t.next=8,M.getCode(r.contractAddress);case 8:o=t.sent,t.next=13;break;case 11:t.prev=11,t.t0=t.catch(5);case 13:if(o){t.next=15;break}return t.abrupt("return");case 15:!0===r.status&&k||o.length>2?(e.eventEmitter.emit("receipt",r),n.extraFormatters&&n.extraFormatters.contractDeployFormatter?e.resolve(n.extraFormatters.contractDeployFormatter(r)):e.resolve(r),h&&e.eventEmitter.removeAllListeners()):f._fireError(c.ContractCodeNotStoredError(r),e.eventEmitter,e.reject,null,r),h&&E.unsubscribe(),a=!0;case 19:return t.abrupt("return",r);case 20:case"end":return t.stop()}}),t,null,[[5,11]])})));return function(e){return t.apply(this,arguments)}}()).then(function(){var t=o(i.mark((function t(o){var d,u,b,p;return i.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(w||a){t.next=35;break}if(o.outOfGas||y&&y===o.gasUsed||!0!==o.status&&"0x1"!==o.status&&"undefined"!==typeof o.status){t.next=7;break}e.eventEmitter.emit("receipt",o),e.resolve(o),h&&e.eventEmitter.removeAllListeners(),t.next=33;break;case 7:if(JSON.stringify(o,null,2),!1!==o.status&&"0x0"!==o.status){t.next=32;break}if(t.prev=9,d=null,!n.handleRevert||"eth_sendTransaction"!==n.call&&"eth_sendRawTransaction"!==n.call){t.next=24;break}return u=r.params[0],"eth_sendRawTransaction"===n.call&&(b=r.params[0],p=l.parse(b),u=s.inputTransactionFormatter({data:p.data,to:p.to,from:p.from,gas:p.gasLimit.toHexString(),gasPrice:p.gasPrice.toHexString(),value:p.value.toHexString()})),t.next=16,n.getRevertReason(u,o.blockNumber);case 16:if(!(d=t.sent)){t.next=21;break}f._fireError(c.TransactionRevertInstructionError(d.reason,d.signature,o),e.eventEmitter,e.reject,null,o),t.next=22;break;case 21:throw!1;case 22:t.next=25;break;case 24:throw!1;case 25:t.next=30;break;case 27:t.prev=27,t.t0=t.catch(9),f._fireError(c.TransactionRevertedWithoutReasonError(o),e.eventEmitter,e.reject,null,o);case 30:t.next=33;break;case 32:f._fireError(c.TransactionOutOfGasError(o),e.eventEmitter,e.reject,null,o);case 33:h&&E.unsubscribe(),a=!0;case 35:case"end":return t.stop()}}),t,null,[[9,27]])})));return function(e){return t.apply(this,arguments)}}()).catch((function(){p++,b?p-1>=n.transactionPollingTimeout&&(E.unsubscribe(),a=!0,f._fireError(c.TransactionError("Transaction was not mined within "+n.transactionPollingTimeout+" seconds, please make sure your transaction was properly sent. Be aware that it might still be mined!"),e.eventEmitter,e.reject)):p-1>=n.transactionBlockTimeout&&(E.unsubscribe(),a=!0,f._fireError(c.TransactionError("Transaction was not mined within "+n.transactionBlockTimeout+" blocks, please make sure your transaction was properly sent. Be aware that it might still be mined!"),e.eventEmitter,e.reject))}));E.unsubscribe(),a=!0,f._fireError({message:"Failed to subscribe to new newBlockHeaders to confirm the transaction receipts.",data:_},e.eventEmitter,e.reject)},E=function(e){var t=!1,r=function(){v=setInterval(S.bind(null,e,!0),1e3)};if(!this.requestManager.provider.on)return r();M.subscribe("newBlockHeaders",(function(n,a,i){if(t=!0,n||!a)return r();S(e,!1,n,0,i)})),g=setTimeout((function(){t||r()}),1e3*this.blockHeaderTimeout)}.bind(this);M.getTransactionReceipt(t).then((function(t){t&&t.blockHash?(e.eventEmitter.listeners("confirmation").length>0&&E(t),S(t,!1)):a||E()})).catch((function(){a||E()}))};var h=function(e,t){return"number"===typeof e?t.wallet[e]:e&&"object"===typeof e&&e.address&&e.privateKey?e:t.wallet[e.toLowerCase()]};function p(e,t){return new Promise((function(r,a){try{var i=new b({name:"getBlockByNumber",call:"eth_getBlockByNumber",params:2,inputFormatter:[function(e){return e?f.toHex(e):"latest"},function(){return!1}]}).createFunction(e.requestManager),o=new b({name:"getGasPrice",call:"eth_gasPrice",params:0}).createFunction(e.requestManager);Promise.all([i(),o()]).then((function(e){var a=n(e,2),i=a[0],o=a[1];if(("0x2"===t.type||void 0===t.type)&&i&&i.baseFeePerGas){var c,s;t.gasPrice?(c=t.gasPrice,s=t.gasPrice,delete t.gasPrice):(c=t.maxPriorityFeePerGas||"0x9502F900",s=t.maxFeePerGas||f.toHex(f.toBN(i.baseFeePerGas).mul(f.toBN(2)).add(f.toBN(c)))),r({maxFeePerGas:s,maxPriorityFeePerGas:c})}else{if(t.maxPriorityFeePerGas||t.maxFeePerGas)throw Error("Network doesn't support eip-1559");r({gasPrice:o})}}))}catch(c){a(c)}}))}b.prototype.buildCall=function(){var e=this,t="eth_sendTransaction"===e.call||"eth_sendRawTransaction"===e.call,r="eth_call"===e.call,n=function(){var n=d(!t),i=e.toPayload(Array.prototype.slice.call(arguments)),o=function(a,o){var s;if(e.handleRevert&&r&&e.abiCoder&&(!a&&e.isRevertReasonString(o)?s=o.substring(10):a&&a.data&&(s=a.data.substring(10)),s)){var d=e.abiCoder.decodeParameter("string","0x"+s);return void f._fireError(c.RevertInstructionError(d,"Error(String)"),n.eventEmitter,n.reject,i.callback,{reason:d,signature:"Error(String)"})}try{o=e.formatOutput(o)}catch(u){a=u}if(o instanceof Error&&(a=o),a)return a.error&&(a=a.error),f._fireError(a,n.eventEmitter,n.reject,i.callback);i.callback&&i.callback(null,o),t?(n.eventEmitter.emit("transactionHash",o),e._confirmTransaction(n,o,i)):a||n.resolve(o)},s=function(t){var r=a(a({},i),{},{method:"eth_sendRawTransaction",params:[t.rawTransaction]});e.requestManager.send(r,o)},u=function(e,t){var r;if(t&&t.accounts&&t.accounts.wallet&&t.accounts.wallet.length)if("eth_sendTransaction"===e.method){var a=e.params[0];if((r=h(a&&"object"===typeof a?a.from:null,t.accounts))&&r.privateKey)return delete(a=JSON.parse(JSON.stringify(a))).from,t.defaultChain&&!a.chain&&(a.chain=t.defaultChain),t.defaultHardfork&&!a.hardfork&&(a.hardfork=t.defaultHardfork),t.defaultCommon&&!a.common&&(a.common=t.defaultCommon),void t.accounts.signTransaction(a,r.privateKey).then(s).catch((function(e){if("function"===typeof n.eventEmitter.listeners&&n.eventEmitter.listeners("error").length){try{n.eventEmitter.emit("error",e)}catch(e){}n.eventEmitter.removeAllListeners(),n.eventEmitter.catch((function(){}))}n.reject(e)}))}else if("eth_sign"===e.method){var i=e.params[1];if((r=h(e.params[0],t.accounts))&&r.privateKey){var c=t.accounts.sign(i,r.privateKey);return e.callback&&e.callback(null,c.signature),void n.resolve(c.signature)}}return t.requestManager.send(e,o)};return t&&i.params[0]&&"object"===typeof i.params[0]&&"undefined"===typeof i.params[0].gasPrice&&("undefined"===typeof i.params[0].maxPriorityFeePerGas||"undefined"===typeof i.params[0].maxFeePerGas)?p(e,i.params[0]).then((function(r){void 0!==r.gasPrice?i.params[0].gasPrice=r.gasPrice:void 0!==r.maxPriorityFeePerGas&&void 0!==r.maxFeePerGas&&(i.params[0].maxPriorityFeePerGas=r.maxPriorityFeePerGas,i.params[0].maxFeePerGas=r.maxFeePerGas),t&&setTimeout((function(){n.eventEmitter.emit("sending",i)}),0),u(i,e)})):(t&&setTimeout((function(){n.eventEmitter.emit("sending",i)}),0),u(i,e)),t&&setTimeout((function(){n.eventEmitter.emit("sent",i)}),0),n.eventEmitter};return n.method=e,n.request=this.request.bind(this),n},b.prototype.getRevertReason=function(e,t){var r=this;return new Promise((function(n,a){new b({name:"call",call:"eth_call",params:2,abiCoder:r.abiCoder,handleRevert:!0}).createFunction(r.requestManager)(e,f.numberToHex(t)).then((function(){n(!1)})).catch((function(e){e.reason?n({reason:e.reason,signature:e.signature}):a(e)}))}))},b.prototype.isRevertReasonString=function(e){return"string"===typeof e&&(e.length-2)/2%32===4&&"0x08c379a0"===e.substring(0,10)},b.prototype.request=function(){var e=this.toPayload(Array.prototype.slice.call(arguments));return e.format=this.formatOutput.bind(this),e},e.exports=b},function(e,t,r){var n=r(984),a=r(989);e.exports=function(e,t){var r=a(e,t);return n(r)?r:void 0}},function(e,t,r){var n=r(208),a=r(985),i=r(986),o=n?n.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":o&&o in Object(e)?a(e):i(e)}},function(e,t,r){"use strict";r.r(t),r.d(t,"AddressZero",(function(){return n.a})),r.d(t,"NegativeOne",(function(){return a.d})),r.d(t,"Zero",(function(){return a.h})),r.d(t,"One",(function(){return a.e})),r.d(t,"Two",(function(){return a.f})),r.d(t,"WeiPerEther",(function(){return a.g})),r.d(t,"MaxUint256",(function(){return a.b})),r.d(t,"MinInt256",(function(){return a.c})),r.d(t,"MaxInt256",(function(){return a.a})),r.d(t,"HashZero",(function(){return i.a})),r.d(t,"EtherSymbol",(function(){return o}));var n=r(481),a=r(120),i=r(361),o="\u039e"},function(e,t,r){"use strict";r.r(t),r.d(t,"ConstructorFragment",(function(){return S})),r.d(t,"EventFragment",(function(){return w})),r.d(t,"Fragment",(function(){return y})),r.d(t,"FunctionFragment",(function(){return E})),r.d(t,"ParamType",(function(){return g})),r.d(t,"FormatTypes",(function(){return m})),r.d(t,"AbiCoder",(function(){return ie})),r.d(t,"defaultAbiCoder",(function(){return oe})),r.d(t,"Interface",(function(){return he})),r.d(t,"Indexed",(function(){return le})),r.d(t,"checkResultErrors",(function(){return R})),r.d(t,"LogDescription",(function(){return de})),r.d(t,"TransactionDescription",(function(){return ue}));var n=r(13),a=r(14),i=r(6),o=r(7),c=r(46),s=r(9),f=r(11),d=new f.a("abi/5.0.7"),u={},l={calldata:!0,memory:!0,storage:!0},b={calldata:!0,memory:!0};function h(e,t){if("bytes"===e||"string"===e){if(l[t])return!0}else if("address"===e){if("payable"===t)return!0}else if((e.indexOf("[")>=0||"tuple"===e)&&b[t])return!0;return(l[t]||"payable"===t)&&d.throwArgumentError("invalid modifier","name",t),!1}function p(e,t){for(var r in t)Object(s.d)(e,r,t[r])}var m=Object.freeze({sighash:"sighash",minimal:"minimal",full:"full",json:"json"}),v=new RegExp(/^(.*)\[([0-9]*)\]$/),g=function(){function e(t,r){Object(i.a)(this,e),t!==u&&d.throwError("use fromString",f.a.errors.UNSUPPORTED_OPERATION,{operation:"new ParamType()"}),p(this,r);var n=this.type.match(v);p(this,n?{arrayLength:parseInt(n[2]||"-1"),arrayChildren:e.fromObject({type:n[1],components:this.components}),baseType:"array"}:{arrayLength:null,arrayChildren:null,baseType:null!=this.components?"tuple":this.type}),this._isParamType=!0,Object.freeze(this)}return Object(o.a)(e,[{key:"format",value:function(e){if(e||(e=m.sighash),m[e]||d.throwArgumentError("invalid format type","format",e),e===m.json){var t={type:"tuple"===this.baseType?"tuple":this.type,name:this.name||void 0};return"boolean"===typeof this.indexed&&(t.indexed=this.indexed),this.components&&(t.components=this.components.map((function(t){return JSON.parse(t.format(e))}))),JSON.stringify(t)}var r="";return"array"===this.baseType?(r+=this.arrayChildren.format(e),r+="["+(this.arrayLength<0?"":String(this.arrayLength))+"]"):"tuple"===this.baseType?(e!==m.sighash&&(r+=this.type),r+="("+this.components.map((function(t){return t.format(e)})).join(e===m.full?", ":",")+")"):r+=this.type,e!==m.sighash&&(!0===this.indexed&&(r+=" indexed"),e===m.full&&this.name&&(r+=" "+this.name)),r}}],[{key:"from",value:function(t,r){return"string"===typeof t?e.fromString(t,r):e.fromObject(t)}},{key:"fromObject",value:function(t){return e.isParamType(t)?t:new e(u,{name:t.name||null,type:O(t.type),indexed:null==t.indexed?null:!!t.indexed,components:t.components?t.components.map(e.fromObject):null})}},{key:"fromString",value:function(t,r){return function(t){return e.fromObject({name:t.name,type:t.type,indexed:t.indexed,components:t.components})}(function(e,t){var r=e;function n(t){d.throwArgumentError("unexpected character at position ".concat(t),"param",e)}function a(e){var r={type:"",name:"",parent:e,state:{allowType:!0}};return t&&(r.indexed=!1),r}e=e.replace(/\s/g," ");for(var i={type:"",name:"",state:{allowType:!0}},o=i,c=0;c2&&d.throwArgumentError("invalid human-readable ABI signature","value",e),r[1].match(/^[0-9]+$/)||d.throwArgumentError("invalid human-readable ABI signature gas","value",e),t.gas=c.a.from(r[1]),r[0]):e}function _(e,t){t.constant=!1,t.payable=!1,t.stateMutability="nonpayable",e.split(" ").forEach((function(e){switch(e.trim()){case"constant":t.constant=!0;break;case"payable":t.payable=!0,t.stateMutability="payable";break;case"nonpayable":t.payable=!1,t.stateMutability="nonpayable";break;case"pure":t.constant=!0,t.stateMutability="pure";break;case"view":t.constant=!0,t.stateMutability="view";break;case"external":case"public":case"":break;default:console.log("unknown modifier: "+e)}}))}function M(e){var t={constant:!1,payable:!0,stateMutability:"payable"};return null!=e.stateMutability?(t.stateMutability=e.stateMutability,t.constant="view"===t.stateMutability||"pure"===t.stateMutability,null!=e.constant&&!!e.constant!==t.constant&&d.throwArgumentError("cannot have constant function with mutability "+t.stateMutability,"value",e),t.payable="payable"===t.stateMutability,null!=e.payable&&!!e.payable!==t.payable&&d.throwArgumentError("cannot have payable function with mutability "+t.stateMutability,"value",e)):null!=e.payable?(t.payable=!!e.payable,null!=e.constant||t.payable||"constructor"===e.type||d.throwArgumentError("unable to determine stateMutability","value",e),t.constant=!!e.constant,t.constant?t.stateMutability="view":t.stateMutability=t.payable?"payable":"nonpayable",t.payable&&t.constant&&d.throwArgumentError("cannot have constant payable function","value",e)):null!=e.constant?(t.constant=!!e.constant,t.payable=!t.constant,t.stateMutability=t.constant?"view":"payable"):"constructor"!==e.type&&d.throwArgumentError("unable to determine stateMutability","value",e),t}var S=function(e){Object(n.a)(r,e);var t=Object(a.a)(r);function r(){return Object(i.a)(this,r),t.apply(this,arguments)}return Object(o.a)(r,[{key:"format",value:function(e){if(e||(e=m.sighash),m[e]||d.throwArgumentError("invalid format type","format",e),e===m.json)return JSON.stringify({type:"constructor",stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payble:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map((function(t){return JSON.parse(t.format(e))}))});e===m.sighash&&d.throwError("cannot format a constructor for sighash",f.a.errors.UNSUPPORTED_OPERATION,{operation:"format(sighash)"});var t="constructor("+this.inputs.map((function(t){return t.format(e)})).join(e===m.full?", ":",")+") ";return this.stateMutability&&"nonpayable"!==this.stateMutability&&(t+=this.stateMutability+" "),t.trim()}}],[{key:"from",value:function(e){return"string"===typeof e?r.fromString(e):r.fromObject(e)}},{key:"fromObject",value:function(e){if(r.isConstructorFragment(e))return e;"constructor"!==e.type&&d.throwArgumentError("invalid constructor object","value",e);var t=M(e);t.constant&&d.throwArgumentError("constructor cannot be constant","value",e);var n={name:null,type:e.type,inputs:e.inputs?e.inputs.map(g.fromObject):[],payable:t.payable,stateMutability:t.stateMutability,gas:e.gas?c.a.from(e.gas):null};return new r(u,n)}},{key:"fromString",value:function(e){var t={type:"constructor"},n=(e=k(e,t)).match(j);return n&&"constructor"===n[1].trim()||d.throwArgumentError("invalid constructor string","value",e),t.inputs=x(n[2].trim(),!1),_(n[3].trim(),t),r.fromObject(t)}},{key:"isConstructorFragment",value:function(e){return e&&e._isFragment&&"constructor"===e.type}}]),r}(y),E=function(e){Object(n.a)(r,e);var t=Object(a.a)(r);function r(){return Object(i.a)(this,r),t.apply(this,arguments)}return Object(o.a)(r,[{key:"format",value:function(e){if(e||(e=m.sighash),m[e]||d.throwArgumentError("invalid format type","format",e),e===m.json)return JSON.stringify({type:"function",name:this.name,constant:this.constant,stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payble:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map((function(t){return JSON.parse(t.format(e))})),ouputs:this.outputs.map((function(t){return JSON.parse(t.format(e))}))});var t="";return e!==m.sighash&&(t+="function "),t+=this.name+"("+this.inputs.map((function(t){return t.format(e)})).join(e===m.full?", ":",")+") ",e!==m.sighash&&(this.stateMutability?"nonpayable"!==this.stateMutability&&(t+=this.stateMutability+" "):this.constant&&(t+="view "),this.outputs&&this.outputs.length&&(t+="returns ("+this.outputs.map((function(t){return t.format(e)})).join(", ")+") "),null!=this.gas&&(t+="@"+this.gas.toString()+" ")),t.trim()}}],[{key:"from",value:function(e){return"string"===typeof e?r.fromString(e):r.fromObject(e)}},{key:"fromObject",value:function(e){if(r.isFunctionFragment(e))return e;"function"!==e.type&&d.throwArgumentError("invalid function object","value",e);var t=M(e),n={type:e.type,name:T(e.name),constant:t.constant,inputs:e.inputs?e.inputs.map(g.fromObject):[],outputs:e.outputs?e.outputs.map(g.fromObject):[],payable:t.payable,stateMutability:t.stateMutability,gas:e.gas?c.a.from(e.gas):null};return new r(u,n)}},{key:"fromString",value:function(e){var t={type:"function"},n=(e=k(e,t)).split(" returns ");n.length>2&&d.throwArgumentError("invalid function string","value",e);var a=n[0].match(j);if(a||d.throwArgumentError("invalid function signature","value",e),t.name=a[1].trim(),t.name&&T(t.name),t.inputs=x(a[2],!1),_(a[3].trim(),t),n.length>1){var i=n[1].match(j);""==i[1].trim()&&""==i[3].trim()||d.throwArgumentError("unexpected tokens","value",e),t.outputs=x(i[2],!1)}else t.outputs=[];return r.fromObject(t)}},{key:"isFunctionFragment",value:function(e){return e&&e._isFragment&&"function"===e.type}}]),r}(S);function O(e){return e.match(/^uint($|[^1-9])/)?e="uint256"+e.substring(4):e.match(/^int($|[^1-9])/)&&(e="int256"+e.substring(3)),e}var A=new RegExp("^[A-Za-z_][A-Za-z0-9_]*$");function T(e){return e&&e.match(A)||d.throwArgumentError('invalid identifier "'.concat(e,'"'),"value",e),e}var j=new RegExp("^([^)(]*)\\((.*)\\)([^)(]*)$");var P=r(5),C=new f.a("abi/5.0.7");function R(e){var t=[];return function e(r,n){if(Array.isArray(n))for(var a in n){var i=r.slice();i.push(a);try{e(i,n[a])}catch(o){t.push({path:i,error:o})}}}([],e),t}var N=function(){function e(t,r,n,a){Object(i.a)(this,e),this.name=t,this.type=r,this.localName=n,this.dynamic=a}return Object(o.a)(e,[{key:"_throwError",value:function(e,t){C.throwArgumentError(e,this.localName,t)}}]),e}(),B=function(){function e(t){Object(i.a)(this,e),Object(s.d)(this,"wordSize",t||32),this._data=[],this._dataLength=0,this._padding=new Uint8Array(t)}return Object(o.a)(e,[{key:"data",get:function(){return Object(P.c)(this._data)}},{key:"length",get:function(){return this._dataLength}},{key:"_writeData",value:function(e){return this._data.push(e),this._dataLength+=e.length,e.length}},{key:"appendWriter",value:function(e){return this._writeData(Object(P.b)(e._data))}},{key:"writeBytes",value:function(e){var t=Object(P.a)(e),r=t.length%this.wordSize;return r&&(t=Object(P.b)([t,this._padding.slice(r)])),this._writeData(t)}},{key:"_getValue",value:function(e){var t=Object(P.a)(c.a.from(e));return t.length>this.wordSize&&C.throwError("value out-of-bounds",f.a.errors.BUFFER_OVERRUN,{length:this.wordSize,offset:t.length}),t.length%this.wordSize&&(t=Object(P.b)([this._padding.slice(t.length%this.wordSize),t])),t}},{key:"writeValue",value:function(e){return this._writeData(this._getValue(e))}},{key:"writeUpdatableValue",value:function(){var e=this,t=this._data.length;return this._data.push(this._padding),this._dataLength+=this.wordSize,function(r){e._data[t]=e._getValue(r)}}}]),e}(),L=function(){function e(t,r,n,a){Object(i.a)(this,e),Object(s.d)(this,"_data",Object(P.a)(t)),Object(s.d)(this,"wordSize",r||32),Object(s.d)(this,"_coerceFunc",n),Object(s.d)(this,"allowLoose",a),this._offset=0}return Object(o.a)(e,[{key:"data",get:function(){return Object(P.h)(this._data)}},{key:"consumed",get:function(){return this._offset}},{key:"coerce",value:function(t,r){return this._coerceFunc?this._coerceFunc(t,r):e.coerce(t,r)}},{key:"_peekBytes",value:function(e,t,r){var n=Math.ceil(t/this.wordSize)*this.wordSize;return this._offset+n>this._data.length&&(this.allowLoose&&r&&this._offset+t<=this._data.length?n=t:C.throwError("data out-of-bounds",f.a.errors.BUFFER_OVERRUN,{length:this._data.length,offset:this._offset+n})),this._data.slice(this._offset,this._offset+n)}},{key:"subReader",value:function(t){return new e(this._data.slice(this._offset+t),this.wordSize,this._coerceFunc,this.allowLoose)}},{key:"readBytes",value:function(e,t){var r=this._peekBytes(0,e,!!t);return this._offset+=r.length,r.slice(0,e)}},{key:"readValue",value:function(){return c.a.from(this.readBytes(this.wordSize))}}],[{key:"coerce",value:function(e,t){var r=e.match("^u?int([0-9]+)$");return r&&parseInt(r[1])<=48&&(t=t.toNumber()),t}}]),e}(),I=r(38),F=function(e){Object(n.a)(r,e);var t=Object(a.a)(r);function r(e){return Object(i.a)(this,r),t.call(this,"address","address",e,!1)}return Object(o.a)(r,[{key:"encode",value:function(e,t){try{Object(I.a)(t)}catch(r){this._throwError(r.message,t)}return e.writeValue(t)}},{key:"decode",value:function(e){return Object(I.a)(Object(P.g)(e.readValue().toHexString(),20))}}]),r}(N),D=function(e){Object(n.a)(r,e);var t=Object(a.a)(r);function r(e){var n;return Object(i.a)(this,r),(n=t.call(this,e.name,e.type,void 0,e.dynamic)).coder=e,n}return Object(o.a)(r,[{key:"encode",value:function(e,t){return this.coder.encode(e,t)}},{key:"decode",value:function(e){return this.coder.decode(e)}}]),r}(N),U=new f.a("abi/5.0.7");function z(e,t,r){var n=null;if(Array.isArray(r))n=r;else if(r&&"object"===typeof r){var a={};n=t.map((function(e){var t=e.localName;return t||U.throwError("cannot encode object for signature with missing names",f.a.errors.INVALID_ARGUMENT,{argument:"values",coder:e,value:r}),a[t]&&U.throwError("cannot encode object for signature with duplicate names",f.a.errors.INVALID_ARGUMENT,{argument:"values",coder:e,value:r}),a[t]=!0,r[t]}))}else U.throwArgumentError("invalid tuple value","tuple",r);t.length!==n.length&&U.throwArgumentError("types/value length mismatch","tuple",r);var i=new B(e.wordSize),o=new B(e.wordSize),c=[];t.forEach((function(e,t){var r=n[t];if(e.dynamic){var a=o.length;e.encode(o,r);var s=i.writeUpdatableValue();c.push((function(e){s(e+a)}))}else e.encode(i,r)})),c.forEach((function(e){e(i.length)}));var s=e.appendWriter(i);return s+=e.appendWriter(o)}function H(e,t){var r=[],n=e.subReader(0);t.forEach((function(t){var a=null;if(t.dynamic){var i=e.readValue(),o=n.subReader(i.toNumber());try{a=t.decode(o)}catch(c){if(c.code===f.a.errors.BUFFER_OVERRUN)throw c;(a=c).baseType=t.name,a.name=t.localName,a.type=t.type}}else try{a=t.decode(e)}catch(c){if(c.code===f.a.errors.BUFFER_OVERRUN)throw c;(a=c).baseType=t.name,a.name=t.localName,a.type=t.type}void 0!=a&&r.push(a)}));var a=t.reduce((function(e,t){var r=t.localName;return r&&(e[r]||(e[r]=0),e[r]++),e}),{});t.forEach((function(e,t){var n=e.localName;if(n&&1===a[n]&&("length"===n&&(n="_length"),null==r[n])){var i=r[t];i instanceof Error?Object.defineProperty(r,n,{get:function(){throw i}}):r[n]=i}}));for(var i=function(e){var t=r[e];t instanceof Error&&Object.defineProperty(r,e,{get:function(){throw t}})},o=0;o=0?n:"")+"]",s=-1===n||e.dynamic;return(o=t.call(this,"array",c,a,s)).coder=e,o.length=n,o}return Object(o.a)(r,[{key:"encode",value:function(e,t){Array.isArray(t)||this._throwError("expected array value",t);var r=this.length;-1===r&&(r=t.length,e.writeValue(t.length)),U.checkArgumentCount(t.length,r,"coder array"+(this.localName?" "+this.localName:""));for(var n=[],a=0;a256||n%8!==0)&&re.throwArgumentError("invalid "+r[1]+" bit length","param",e),new Q(n/8,"int"===r[1],e.name)}if(r=e.type.match(ne)){var a=parseInt(r[1]);return(0===a||a>32)&&re.throwArgumentError("invalid bytes length","param",e),new W(a,e.name)}return re.throwArgumentError("invalid type","type",e.type)}},{key:"_getWordSize",value:function(){return 32}},{key:"_getReader",value:function(e,t){return new L(e,this._getWordSize(),this.coerceFunc,t)}},{key:"_getWriter",value:function(){return new B(this._getWordSize())}},{key:"encode",value:function(e,t){var r=this;e.length!==t.length&&re.throwError("types/values length mismatch",f.a.errors.INVALID_ARGUMENT,{count:{types:e.length,values:t.length},value:{types:e,values:t}});var n=e.map((function(e){return r._getCoder(g.from(e))})),a=new te(n,"_"),i=this._getWriter();return a.encode(i,t),i.data}},{key:"decode",value:function(e,t,r){var n=this,a=e.map((function(e){return n._getCoder(g.from(e))}));return new te(a,"_").decode(this._getReader(Object(P.a)(t),r))}}]),e}(),oe=new ie,ce=r(366),se=r(40),fe=new f.a("abi/5.0.7"),de=function(e){Object(n.a)(r,e);var t=Object(a.a)(r);function r(){return Object(i.a)(this,r),t.apply(this,arguments)}return Object(o.a)(r)}(s.a),ue=function(e){Object(n.a)(r,e);var t=Object(a.a)(r);function r(){return Object(i.a)(this,r),t.apply(this,arguments)}return Object(o.a)(r)}(s.a),le=function(e){Object(n.a)(r,e);var t=Object(a.a)(r);function r(){return Object(i.a)(this,r),t.apply(this,arguments)}return Object(o.a)(r,null,[{key:"isIndexed",value:function(e){return!(!e||!e._isIndexed)}}]),r}(s.a);function be(e,t){var r=new Error("deferred error during ABI decoding triggered accessing ".concat(e));return r.error=t,r}var he=function(){function e(t){var r=this;Object(i.a)(this,e),fe.checkNew(this instanceof e?this.constructor:void 0,e);var n=[];n="string"===typeof t?JSON.parse(t):t,Object(s.d)(this,"fragments",n.map((function(e){return y.from(e)})).filter((function(e){return null!=e}))),Object(s.d)(this,"_abiCoder",Object(s.e)(this instanceof e?this.constructor:void 0,"getAbiCoder")()),Object(s.d)(this,"functions",{}),Object(s.d)(this,"errors",{}),Object(s.d)(this,"events",{}),Object(s.d)(this,"structs",{}),this.fragments.forEach((function(e){var t=null;switch(e.type){case"constructor":return r.deploy?void fe.warn("duplicate definition - constructor"):void Object(s.d)(r,"deploy",e);case"function":t=r.functions;break;case"event":t=r.events;break;default:return}var n=e.format();t[n]?fe.warn("duplicate definition - "+n):t[n]=e})),this.deploy||Object(s.d)(this,"deploy",S.from({payable:!1,type:"constructor"})),Object(s.d)(this,"_isInterface",!0)}return Object(o.a)(e,[{key:"format",value:function(e){e||(e=m.full),e===m.sighash&&fe.throwArgumentError("interface does not support formatting sighash","format",e);var t=this.fragments.map((function(t){return t.format(e)}));return e===m.json?JSON.stringify(t.map((function(e){return JSON.parse(e)}))):t}},{key:"getFunction",value:function(e){if(Object(P.k)(e)){for(var t in this.functions)if(e===this.getSighash(t))return this.functions[t];fe.throwArgumentError("no matching function","sighash",e)}if(-1===e.indexOf("(")){var r=e.trim(),n=Object.keys(this.functions).filter((function(e){return e.split("(")[0]===r}));return 0===n.length?fe.throwArgumentError("no matching function","name",r):n.length>1&&fe.throwArgumentError("multiple matching functions","name",r),this.functions[n[0]]}var a=this.functions[E.fromString(e).format()];return a||fe.throwArgumentError("no matching function","signature",e),a}},{key:"getEvent",value:function(e){if(Object(P.k)(e)){var t=e.toLowerCase();for(var r in this.events)if(t===this.getEventTopic(r))return this.events[r];fe.throwArgumentError("no matching event","topichash",t)}if(-1===e.indexOf("(")){var n=e.trim(),a=Object.keys(this.events).filter((function(e){return e.split("(")[0]===n}));return 0===a.length?fe.throwArgumentError("no matching event","name",n):a.length>1&&fe.throwArgumentError("multiple matching events","name",n),this.events[a[0]]}var i=this.events[w.fromString(e).format()];return i||fe.throwArgumentError("no matching event","signature",e),i}},{key:"getSighash",value:function(e){return"string"===typeof e&&(e=this.getFunction(e)),Object(s.e)(this.constructor,"getSighash")(e)}},{key:"getEventTopic",value:function(e){return"string"===typeof e&&(e=this.getEvent(e)),Object(s.e)(this.constructor,"getEventTopic")(e)}},{key:"_decodeParams",value:function(e,t){return this._abiCoder.decode(e,t)}},{key:"_encodeParams",value:function(e,t){return this._abiCoder.encode(e,t)}},{key:"encodeDeploy",value:function(e){return this._encodeParams(this.deploy.inputs,e||[])}},{key:"decodeFunctionData",value:function(e,t){"string"===typeof e&&(e=this.getFunction(e));var r=Object(P.a)(t);return Object(P.h)(r.slice(0,4))!==this.getSighash(e)&&fe.throwArgumentError("data signature does not match function ".concat(e.name,"."),"data",Object(P.h)(r)),this._decodeParams(e.inputs,r.slice(4))}},{key:"encodeFunctionData",value:function(e,t){return"string"===typeof e&&(e=this.getFunction(e)),Object(P.h)(Object(P.b)([this.getSighash(e),this._encodeParams(e.inputs,t||[])]))}},{key:"decodeFunctionResult",value:function(e,t){"string"===typeof e&&(e=this.getFunction(e));var r=Object(P.a)(t),n=null,a=null;switch(r.length%this._abiCoder._getWordSize()){case 0:try{return this._abiCoder.decode(e.outputs,r)}catch(i){}break;case 4:"0x08c379a0"===Object(P.h)(r.slice(0,4))&&(a="Error(string)",n=this._abiCoder.decode(["string"],r.slice(4))[0])}return fe.throwError("call revert exception",f.a.errors.CALL_EXCEPTION,{method:e.format(),errorSignature:a,errorArgs:[n],reason:n})}},{key:"encodeFunctionResult",value:function(e,t){return"string"===typeof e&&(e=this.getFunction(e)),Object(P.h)(this._abiCoder.encode(e.outputs,t||[]))}},{key:"encodeFilterTopics",value:function(e,t){var r=this;"string"===typeof e&&(e=this.getEvent(e)),t.length>e.inputs.length&&fe.throwError("too many arguments for "+e.format(),f.a.errors.UNEXPECTED_ARGUMENT,{argument:"values",value:t});var n=[];e.anonymous||n.push(this.getEventTopic(e));var a=function(e,t){return"string"===e.type?Object(ce.a)(t):"bytes"===e.type?Object(se.a)(Object(P.h)(t)):("address"===e.type&&r._abiCoder.encode(["address"],[t]),Object(P.g)(Object(P.h)(t),32))};for(t.forEach((function(t,r){var i=e.inputs[r];i.indexed?null==t?n.push(null):"array"===i.baseType||"tuple"===i.baseType?fe.throwArgumentError("filtering with tuples or arrays not supported","contract."+i.name,t):Array.isArray(t)?n.push(t.map((function(e){return a(i,e)}))):n.push(a(i,t)):null!=t&&fe.throwArgumentError("cannot filter non-indexed parameters; must be null","contract."+i.name,t)}));n.length&&null===n[n.length-1];)n.pop();return n}},{key:"encodeEventLog",value:function(e,t){var r=this;"string"===typeof e&&(e=this.getEvent(e));var n=[],a=[],i=[];return e.anonymous||n.push(this.getEventTopic(e)),t.length!==e.inputs.length&&fe.throwArgumentError("event arguments/values mismatch","values",t),e.inputs.forEach((function(e,o){var c=t[o];if(e.indexed)if("string"===e.type)n.push(Object(ce.a)(c));else if("bytes"===e.type)n.push(Object(se.a)(c));else{if("tuple"===e.baseType||"array"===e.baseType)throw new Error("not implemented");n.push(r._abiCoder.encode([e.type],[c]))}else a.push(e),i.push(c)})),{data:this._abiCoder.encode(a,i),topics:n}}},{key:"decodeEventLog",value:function(e,t,r){if("string"===typeof e&&(e=this.getEvent(e)),null!=r&&!e.anonymous){var n=this.getEventTopic(e);Object(P.k)(r[0],32)&&r[0].toLowerCase()===n||fe.throwError("fragment/topic mismatch",f.a.errors.INVALID_ARGUMENT,{argument:"topics[0]",expected:n,value:r[0]}),r=r.slice(1)}var a=[],i=[],o=[];e.inputs.forEach((function(e,t){e.indexed?"string"===e.type||"bytes"===e.type||"tuple"===e.baseType||"array"===e.baseType?(a.push(g.fromObject({type:"bytes32",name:e.name})),o.push(!0)):(a.push(e),o.push(!1)):(i.push(e),o.push(!1))}));var c=null!=r?this._abiCoder.decode(a,Object(P.b)(r)):null,s=this._abiCoder.decode(i,t,!0),d=[],u=0,l=0;e.inputs.forEach((function(e,t){if(e.indexed)if(null==c)d[t]=new le({_isIndexed:!0,hash:null});else if(o[t])d[t]=new le({_isIndexed:!0,hash:c[l++]});else try{d[t]=c[l++]}catch(n){d[t]=n}else try{d[t]=s[u++]}catch(n){d[t]=n}if(e.name&&null==d[e.name]){var r=d[t];r instanceof Error?Object.defineProperty(d,e.name,{get:function(){throw be("property ".concat(JSON.stringify(e.name)),r)}}):d[e.name]=r}}));for(var b=function(e){var t=d[e];t instanceof Error&&Object.defineProperty(d,e,{get:function(){throw be("index ".concat(e),t)}})},h=0;h=0||(a[r]=e[r]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(n=0;n=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}var f,d=[].concat(function(e){if(Array.isArray(e)){for(var t=0,r=new Array(e.length);t1&&void 0!==arguments[1]?arguments[1]:{};Object(o.a)(this,e),this.init(t,r)}return Object(c.a)(e,[{key:"init",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.prefix=t.prefix||"i18next:",this.logger=e||l,this.options=t,this.debug=t.debug}},{key:"setDebug",value:function(e){this.debug=e}},{key:"log",value:function(){for(var e=arguments.length,t=new Array(e),r=0;r1?t-1:0),n=1;n-1?e.replace(/###/g,"."):e}function a(){return!e||"string"===typeof e}for(var i="string"!==typeof t?[].concat(t):t.split(".");i.length>1;){if(a())return{};var o=n(i.shift());!e[o]&&r&&(e[o]=new r),e=Object.prototype.hasOwnProperty.call(e,o)?e[o]:{}}return a()?{}:{obj:e,k:n(i.shift())}}function x(e,t,r){var n=g(e,t,Object);n.obj[n.k]=r}function y(e,t){var r=g(e,t),n=r.obj,a=r.k;if(n)return n[a]}function w(e,t,r){var n=y(e,r);return void 0!==n?n:y(t,r)}function k(e,t,r){for(var n in t)"__proto__"!==n&&"constructor"!==n&&(n in e?"string"===typeof e[n]||e[n]instanceof String||"string"===typeof t[n]||t[n]instanceof String?r&&(e[n]=t[n]):k(e[n],t[n],r):e[n]=t[n]);return e}function _(e){return e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}var M={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"};function S(e){return"string"===typeof e?e.replace(/[&<>"'\/]/g,(function(e){return M[e]})):e}var E="undefined"!==typeof window&&window.navigator&&window.navigator.userAgent&&window.navigator.userAgent.indexOf("MSIE")>-1;function O(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:".";if(e){if(e[t])return e[t];for(var n=t.split(r),a=e,i=0;ii+o;)o++,s=a[c=n.slice(i,i+o).join(r)];if(void 0===s)return;if("string"===typeof s)return s;if(c&&"string"===typeof s[c])return s[c];var f=n.slice(i+o).join(r);return f?O(s,f,r):void 0}a=a[n[i]]}return a}}var A=function(e){function t(e){var r,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{ns:["translation"],defaultNS:"translation"};return Object(o.a)(this,t),r=Object(s.a)(this,Object(f.a)(t).call(this)),E&&h.call(Object(d.a)(r)),r.data=e||{},r.options=n,void 0===r.options.keySeparator&&(r.options.keySeparator="."),void 0===r.options.ignoreJSONStructure&&(r.options.ignoreJSONStructure=!0),r}return Object(u.a)(t,e),Object(c.a)(t,[{key:"addNamespaces",value:function(e){this.options.ns.indexOf(e)<0&&this.options.ns.push(e)}},{key:"removeNamespaces",value:function(e){var t=this.options.ns.indexOf(e);t>-1&&this.options.ns.splice(t,1)}},{key:"getResource",value:function(e,t,r){var n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},a=void 0!==n.keySeparator?n.keySeparator:this.options.keySeparator,i=void 0!==n.ignoreJSONStructure?n.ignoreJSONStructure:this.options.ignoreJSONStructure,o=[e,t];r&&"string"!==typeof r&&(o=o.concat(r)),r&&"string"===typeof r&&(o=o.concat(a?r.split(a):r)),e.indexOf(".")>-1&&(o=e.split("."));var c=y(this.data,o);return c||!i||"string"!==typeof r?c:O(this.data&&this.data[e]&&this.data[e][t],r,a)}},{key:"addResource",value:function(e,t,r,n){var a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{silent:!1},i=this.options.keySeparator;void 0===i&&(i=".");var o=[e,t];r&&(o=o.concat(i?r.split(i):r)),e.indexOf(".")>-1&&(n=t,t=(o=e.split("."))[1]),this.addNamespaces(t),x(this.data,o,n),a.silent||this.emit("added",e,t,r,n)}},{key:"addResources",value:function(e,t,r){var n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{silent:!1};for(var a in r)"string"!==typeof r[a]&&"[object Array]"!==Object.prototype.toString.apply(r[a])||this.addResource(e,t,a,r[a],{silent:!0});n.silent||this.emit("added",e,t,r)}},{key:"addResourceBundle",value:function(e,t,r,n,a){var o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{silent:!1},c=[e,t];e.indexOf(".")>-1&&(n=r,r=t,t=(c=e.split("."))[1]),this.addNamespaces(t);var s=y(this.data,c)||{};n?k(s,r,a):s=i({},s,r),x(this.data,c,s),o.silent||this.emit("added",e,t,r)}},{key:"removeResourceBundle",value:function(e,t){this.hasResourceBundle(e,t)&&delete this.data[e][t],this.removeNamespaces(t),this.emit("removed",e,t)}},{key:"hasResourceBundle",value:function(e,t){return void 0!==this.getResource(e,t)}},{key:"getResourceBundle",value:function(e,t){return t||(t=this.options.defaultNS),"v1"===this.options.compatibilityAPI?i({},{},this.getResource(e,t)):this.getResource(e,t)}},{key:"getDataByLanguage",value:function(e){return this.data[e]}},{key:"toJSON",value:function(){return this.data}}]),t}(h),T={processors:{},addPostProcessor:function(e){this.processors[e.name]=e},handle:function(e,t,r,n,a){var i=this;return e.forEach((function(e){i.processors[e]&&(t=i.processors[e].process(t,r,n,a))})),t}},j={},P=function(e){function t(e){var r,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return Object(o.a)(this,t),r=Object(s.a)(this,Object(f.a)(t).call(this)),E&&h.call(Object(d.a)(r)),v(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],e,Object(d.a)(r)),r.options=n,void 0===r.options.keySeparator&&(r.options.keySeparator="."),r.logger=b.create("translator"),r}return Object(u.a)(t,e),Object(c.a)(t,[{key:"changeLanguage",value:function(e){e&&(this.language=e)}},{key:"exists",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{interpolation:{}},r=this.resolve(e,t);return r&&void 0!==r.res}},{key:"extractFromKey",value:function(e,t){var r=void 0!==t.nsSeparator?t.nsSeparator:this.options.nsSeparator;void 0===r&&(r=":");var n=void 0!==t.keySeparator?t.keySeparator:this.options.keySeparator,a=t.ns||this.options.defaultNS;if(r&&e.indexOf(r)>-1){var i=e.match(this.interpolator.nestingRegexp);if(i&&i.length>0)return{key:e,namespaces:a};var o=e.split(r);(r!==n||r===n&&this.options.ns.indexOf(o[0])>-1)&&(a=o.shift()),e=o.join(n)}return"string"===typeof a&&(a=[a]),{key:e,namespaces:a}}},{key:"translate",value:function(e,r,a){var o=this;if("object"!==Object(n.a)(r)&&this.options.overloadTranslationOptionHandler&&(r=this.options.overloadTranslationOptionHandler(arguments)),r||(r={}),void 0===e||null===e)return"";Array.isArray(e)||(e=[String(e)]);var c=void 0!==r.keySeparator?r.keySeparator:this.options.keySeparator,s=this.extractFromKey(e[e.length-1],r),f=s.key,d=s.namespaces,u=d[d.length-1],l=r.lng||this.language,b=r.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if(l&&"cimode"===l.toLowerCase()){if(b){var h=r.nsSeparator||this.options.nsSeparator;return u+h+f}return f}var p=this.resolve(e,r),m=p&&p.res,v=p&&p.usedKey||f,g=p&&p.exactUsedKey||f,x=Object.prototype.toString.apply(m),y=["[object Number]","[object Function]","[object RegExp]"],w=void 0!==r.joinArrays?r.joinArrays:this.options.joinArrays,k=!this.i18nFormat||this.i18nFormat.handleAsObject,_="string"!==typeof m&&"boolean"!==typeof m&&"number"!==typeof m;if(k&&m&&_&&y.indexOf(x)<0&&("string"!==typeof w||"[object Array]"!==x)){if(!r.returnObjects&&!this.options.returnObjects)return this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!"),this.options.returnedObjectHandler?this.options.returnedObjectHandler(v,m,i({},r,{ns:d})):"key '".concat(f," (").concat(this.language,")' returned an object instead of string.");if(c){var M="[object Array]"===x,S=M?[]:{},E=M?g:v;for(var O in m)if(Object.prototype.hasOwnProperty.call(m,O)){var A="".concat(E).concat(c).concat(O);S[O]=this.translate(A,i({},r,{joinArrays:!1,ns:d})),S[O]===A&&(S[O]=m[O])}m=S}}else if(k&&"string"===typeof w&&"[object Array]"===x)(m=m.join(w))&&(m=this.extendTranslation(m,e,r,a));else{var T=!1,j=!1,P=void 0!==r.count&&"string"!==typeof r.count,C=t.hasDefaultValue(r),R=P?this.pluralResolver.getSuffix(l,r.count):"",N=r["defaultValue".concat(R)]||r.defaultValue;!this.isValidLookup(m)&&C&&(T=!0,m=N),this.isValidLookup(m)||(j=!0,m=f);var B=C&&N!==m&&this.options.updateMissing;if(j||T||B){if(this.logger.log(B?"updateKey":"missingKey",l,u,f,B?N:m),c){var L=this.resolve(f,i({},r,{keySeparator:!1}));L&&L.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}var I=[],F=this.languageUtils.getFallbackCodes(this.options.fallbackLng,r.lng||this.language);if("fallback"===this.options.saveMissingTo&&F&&F[0])for(var D=0;D1&&void 0!==arguments[1]?arguments[1]:{};return"string"===typeof e&&(e=[e]),e.forEach((function(e){if(!o.isValidLookup(t)){var s=o.extractFromKey(e,c),f=s.key;r=f;var d=s.namespaces;o.options.fallbackNS&&(d=d.concat(o.options.fallbackNS));var u=void 0!==c.count&&"string"!==typeof c.count,l=void 0!==c.context&&"string"===typeof c.context&&""!==c.context,b=c.lngs?c.lngs:o.languageUtils.toResolveHierarchy(c.lng||o.language,c.fallbackLng);d.forEach((function(e){o.isValidLookup(t)||(i=e,!j["".concat(b[0],"-").concat(e)]&&o.utils&&o.utils.hasLoadedNamespace&&!o.utils.hasLoadedNamespace(i)&&(j["".concat(b[0],"-").concat(e)]=!0,o.logger.warn('key "'.concat(r,'" for languages "').concat(b.join(", "),'" won\'t get resolved as namespace "').concat(i,'" was not yet loaded'),"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),b.forEach((function(r){if(!o.isValidLookup(t)){a=r;var i,s,d=f,b=[d];if(o.i18nFormat&&o.i18nFormat.addLookupKeys)o.i18nFormat.addLookupKeys(b,f,r,e,c);else u&&(i=o.pluralResolver.getSuffix(r,c.count)),u&&l&&b.push(d+i),l&&b.push(d+="".concat(o.options.contextSeparator).concat(c.context)),u&&b.push(d+=i);for(;s=b.pop();)o.isValidLookup(t)||(n=s,t=o.getResource(r,e,s,c))}})))}))}})),{res:t,usedKey:r,exactUsedKey:n,usedLng:a,usedNS:i}}},{key:"isValidLookup",value:function(e){return void 0!==e&&!(!this.options.returnNull&&null===e)&&!(!this.options.returnEmptyString&&""===e)}},{key:"getResource",value:function(e,t,r){var n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return this.i18nFormat&&this.i18nFormat.getResource?this.i18nFormat.getResource(e,t,r,n):this.resourceStore.getResource(e,t,r,n)}}],[{key:"hasDefaultValue",value:function(e){for(var t in e)if(Object.prototype.hasOwnProperty.call(e,t)&&"defaultValue"===t.substring(0,"defaultValue".length)&&void 0!==e[t])return!0;return!1}}]),t}(h);function C(e){return e.charAt(0).toUpperCase()+e.slice(1)}var R=function(){function e(t){Object(o.a)(this,e),this.options=t,this.whitelist=this.options.supportedLngs||!1,this.supportedLngs=this.options.supportedLngs||!1,this.logger=b.create("languageUtils")}return Object(c.a)(e,[{key:"getScriptPartFromCode",value:function(e){if(!e||e.indexOf("-")<0)return null;var t=e.split("-");return 2===t.length?null:(t.pop(),"x"===t[t.length-1].toLowerCase()?null:this.formatLanguageCode(t.join("-")))}},{key:"getLanguagePartFromCode",value:function(e){if(!e||e.indexOf("-")<0)return e;var t=e.split("-");return this.formatLanguageCode(t[0])}},{key:"formatLanguageCode",value:function(e){if("string"===typeof e&&e.indexOf("-")>-1){var t=["hans","hant","latn","cyrl","cans","mong","arab"],r=e.split("-");return this.options.lowerCaseLng?r=r.map((function(e){return e.toLowerCase()})):2===r.length?(r[0]=r[0].toLowerCase(),r[1]=r[1].toUpperCase(),t.indexOf(r[1].toLowerCase())>-1&&(r[1]=C(r[1].toLowerCase()))):3===r.length&&(r[0]=r[0].toLowerCase(),2===r[1].length&&(r[1]=r[1].toUpperCase()),"sgn"!==r[0]&&2===r[2].length&&(r[2]=r[2].toUpperCase()),t.indexOf(r[1].toLowerCase())>-1&&(r[1]=C(r[1].toLowerCase())),t.indexOf(r[2].toLowerCase())>-1&&(r[2]=C(r[2].toLowerCase()))),r.join("-")}return this.options.cleanCode||this.options.lowerCaseLng?e.toLowerCase():e}},{key:"isWhitelisted",value:function(e){return this.logger.deprecate("languageUtils.isWhitelisted",'function "isWhitelisted" will be renamed to "isSupportedCode" in the next major - please make sure to rename it\'s usage asap.'),this.isSupportedCode(e)}},{key:"isSupportedCode",value:function(e){return("languageOnly"===this.options.load||this.options.nonExplicitSupportedLngs)&&(e=this.getLanguagePartFromCode(e)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(e)>-1}},{key:"getBestMatchFromCodes",value:function(e){var t,r=this;return e?(e.forEach((function(e){if(!t){var n=r.formatLanguageCode(e);r.options.supportedLngs&&!r.isSupportedCode(n)||(t=n)}})),!t&&this.options.supportedLngs&&e.forEach((function(e){if(!t){var n=r.getLanguagePartFromCode(e);if(r.isSupportedCode(n))return t=n;t=r.options.supportedLngs.find((function(e){if(0===e.indexOf(n))return e}))}})),t||(t=this.getFallbackCodes(this.options.fallbackLng)[0]),t):null}},{key:"getFallbackCodes",value:function(e,t){if(!e)return[];if("function"===typeof e&&(e=e(t)),"string"===typeof e&&(e=[e]),"[object Array]"===Object.prototype.toString.apply(e))return e;if(!t)return e.default||[];var r=e[t];return r||(r=e[this.getScriptPartFromCode(t)]),r||(r=e[this.formatLanguageCode(t)]),r||(r=e[this.getLanguagePartFromCode(t)]),r||(r=e.default),r||[]}},{key:"toResolveHierarchy",value:function(e,t){var r=this,n=this.getFallbackCodes(t||this.options.fallbackLng||[],e),a=[],i=function(e){e&&(r.isSupportedCode(e)?a.push(e):r.logger.warn("rejecting language code not found in supportedLngs: ".concat(e)))};return"string"===typeof e&&e.indexOf("-")>-1?("languageOnly"!==this.options.load&&i(this.formatLanguageCode(e)),"languageOnly"!==this.options.load&&"currentOnly"!==this.options.load&&i(this.getScriptPartFromCode(e)),"currentOnly"!==this.options.load&&i(this.getLanguagePartFromCode(e))):"string"===typeof e&&i(this.formatLanguageCode(e)),n.forEach((function(e){a.indexOf(e)<0&&i(r.formatLanguageCode(e))})),a}}]),e}(),N=[{lngs:["ach","ak","am","arn","br","fil","gun","ln","mfe","mg","mi","oc","pt","pt-BR","tg","tl","ti","tr","uz","wa"],nr:[1,2],fc:1},{lngs:["af","an","ast","az","bg","bn","ca","da","de","dev","el","en","eo","es","et","eu","fi","fo","fur","fy","gl","gu","ha","hi","hu","hy","ia","it","kk","kn","ku","lb","mai","ml","mn","mr","nah","nap","nb","ne","nl","nn","no","nso","pa","pap","pms","ps","pt-PT","rm","sco","se","si","so","son","sq","sv","sw","ta","te","tk","ur","yo"],nr:[1,2],fc:2},{lngs:["ay","bo","cgg","fa","ht","id","ja","jbo","ka","km","ko","ky","lo","ms","sah","su","th","tt","ug","vi","wo","zh"],nr:[1],fc:3},{lngs:["be","bs","cnr","dz","hr","ru","sr","uk"],nr:[1,2,5],fc:4},{lngs:["ar"],nr:[0,1,2,3,11,100],fc:5},{lngs:["cs","sk"],nr:[1,2,5],fc:6},{lngs:["csb","pl"],nr:[1,2,5],fc:7},{lngs:["cy"],nr:[1,2,3,8],fc:8},{lngs:["fr"],nr:[1,2],fc:9},{lngs:["ga"],nr:[1,2,3,7,11],fc:10},{lngs:["gd"],nr:[1,2,3,20],fc:11},{lngs:["is"],nr:[1,2],fc:12},{lngs:["jv"],nr:[0,1],fc:13},{lngs:["kw"],nr:[1,2,3,4],fc:14},{lngs:["lt"],nr:[1,2,10],fc:15},{lngs:["lv"],nr:[1,2,0],fc:16},{lngs:["mk"],nr:[1,2],fc:17},{lngs:["mnk"],nr:[0,1,2],fc:18},{lngs:["mt"],nr:[1,2,11,20],fc:19},{lngs:["or"],nr:[2,1],fc:2},{lngs:["ro"],nr:[1,2,20],fc:20},{lngs:["sl"],nr:[5,1,2,3],fc:21},{lngs:["he","iw"],nr:[1,2,20,21],fc:22}],B={1:function(e){return Number(e>1)},2:function(e){return Number(1!=e)},3:function(e){return 0},4:function(e){return Number(e%10==1&&e%100!=11?0:e%10>=2&&e%10<=4&&(e%100<10||e%100>=20)?1:2)},5:function(e){return Number(0==e?0:1==e?1:2==e?2:e%100>=3&&e%100<=10?3:e%100>=11?4:5)},6:function(e){return Number(1==e?0:e>=2&&e<=4?1:2)},7:function(e){return Number(1==e?0:e%10>=2&&e%10<=4&&(e%100<10||e%100>=20)?1:2)},8:function(e){return Number(1==e?0:2==e?1:8!=e&&11!=e?2:3)},9:function(e){return Number(e>=2)},10:function(e){return Number(1==e?0:2==e?1:e<7?2:e<11?3:4)},11:function(e){return Number(1==e||11==e?0:2==e||12==e?1:e>2&&e<20?2:3)},12:function(e){return Number(e%10!=1||e%100==11)},13:function(e){return Number(0!==e)},14:function(e){return Number(1==e?0:2==e?1:3==e?2:3)},15:function(e){return Number(e%10==1&&e%100!=11?0:e%10>=2&&(e%100<10||e%100>=20)?1:2)},16:function(e){return Number(e%10==1&&e%100!=11?0:0!==e?1:2)},17:function(e){return Number(1==e||e%10==1&&e%100!=11?0:1)},18:function(e){return Number(0==e?0:1==e?1:2)},19:function(e){return Number(1==e?0:0==e||e%100>1&&e%100<11?1:e%100>10&&e%100<20?2:3)},20:function(e){return Number(1==e?0:0==e||e%100>0&&e%100<20?1:2)},21:function(e){return Number(e%100==1?1:e%100==2?2:e%100==3||e%100==4?3:0)},22:function(e){return Number(1==e?0:2==e?1:(e<0||e>10)&&e%10==0?2:3)}};function L(){var e={};return N.forEach((function(t){t.lngs.forEach((function(r){e[r]={numbers:t.nr,plurals:B[t.fc]}}))})),e}var I=function(){function e(t){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Object(o.a)(this,e),this.languageUtils=t,this.options=r,this.logger=b.create("pluralResolver"),this.rules=L()}return Object(c.a)(e,[{key:"addRule",value:function(e,t){this.rules[e]=t}},{key:"getRule",value:function(e){return this.rules[e]||this.rules[this.languageUtils.getLanguagePartFromCode(e)]}},{key:"needsPlural",value:function(e){var t=this.getRule(e);return t&&t.numbers.length>1}},{key:"getPluralFormsOfKey",value:function(e,t){return this.getSuffixes(e).map((function(e){return t+e}))}},{key:"getSuffixes",value:function(e){var t=this,r=this.getRule(e);return r?r.numbers.map((function(r){return t.getSuffix(e,r)})):[]}},{key:"getSuffix",value:function(e,t){var r=this,n=this.getRule(e);if(n){var a=n.noAbs?n.plurals(t):n.plurals(Math.abs(t)),i=n.numbers[a];this.options.simplifyPluralSuffix&&2===n.numbers.length&&1===n.numbers[0]&&(2===i?i="plural":1===i&&(i=""));var o=function(){return r.options.prepend&&i.toString()?r.options.prepend+i.toString():i.toString()};return"v1"===this.options.compatibilityJSON?1===i?"":"number"===typeof i?"_plural_".concat(i.toString()):o():"v2"===this.options.compatibilityJSON||this.options.simplifyPluralSuffix&&2===n.numbers.length&&1===n.numbers[0]?o():this.options.prepend&&a.toString()?this.options.prepend+a.toString():a.toString()}return this.logger.warn("no plural rule found for: ".concat(e)),""}}]),e}(),F=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};Object(o.a)(this,e),this.logger=b.create("interpolator"),this.options=t,this.format=t.interpolation&&t.interpolation.format||function(e){return e},this.init(t)}return Object(c.a)(e,[{key:"init",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};e.interpolation||(e.interpolation={escapeValue:!0});var t=e.interpolation;this.escape=void 0!==t.escape?t.escape:S,this.escapeValue=void 0===t.escapeValue||t.escapeValue,this.useRawValueToEscape=void 0!==t.useRawValueToEscape&&t.useRawValueToEscape,this.prefix=t.prefix?_(t.prefix):t.prefixEscaped||"{{",this.suffix=t.suffix?_(t.suffix):t.suffixEscaped||"}}",this.formatSeparator=t.formatSeparator?t.formatSeparator:t.formatSeparator||",",this.unescapePrefix=t.unescapeSuffix?"":t.unescapePrefix||"-",this.unescapeSuffix=this.unescapePrefix?"":t.unescapeSuffix||"",this.nestingPrefix=t.nestingPrefix?_(t.nestingPrefix):t.nestingPrefixEscaped||_("$t("),this.nestingSuffix=t.nestingSuffix?_(t.nestingSuffix):t.nestingSuffixEscaped||_(")"),this.nestingOptionsSeparator=t.nestingOptionsSeparator?t.nestingOptionsSeparator:t.nestingOptionsSeparator||",",this.maxReplaces=t.maxReplaces?t.maxReplaces:1e3,this.alwaysFormat=void 0!==t.alwaysFormat&&t.alwaysFormat,this.resetRegExp()}},{key:"reset",value:function(){this.options&&this.init(this.options)}},{key:"resetRegExp",value:function(){var e="".concat(this.prefix,"(.+?)").concat(this.suffix);this.regexp=new RegExp(e,"g");var t="".concat(this.prefix).concat(this.unescapePrefix,"(.+?)").concat(this.unescapeSuffix).concat(this.suffix);this.regexpUnescape=new RegExp(t,"g");var r="".concat(this.nestingPrefix,"(.+?)").concat(this.nestingSuffix);this.nestingRegexp=new RegExp(r,"g")}},{key:"interpolate",value:function(e,t,r,n){var a,o,c,s=this,f=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{};function d(e){return e.replace(/\$/g,"$$$$")}var u=function(e){if(e.indexOf(s.formatSeparator)<0){var a=w(t,f,e);return s.alwaysFormat?s.format(a,void 0,r,i({},n,t,{interpolationkey:e})):a}var o=e.split(s.formatSeparator),c=o.shift().trim(),d=o.join(s.formatSeparator).trim();return s.format(w(t,f,c),d,r,i({},n,t,{interpolationkey:c}))};this.resetRegExp();var l=n&&n.missingInterpolationHandler||this.options.missingInterpolationHandler,b=n&&n.interpolation&&n.interpolation.skipOnVariables||this.options.interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:function(e){return d(e)}},{regex:this.regexp,safeValue:function(e){return s.escapeValue?d(s.escape(e)):d(e)}}].forEach((function(t){for(c=0;a=t.regex.exec(e);){if(void 0===(o=u(a[1].trim())))if("function"===typeof l){var r=l(e,a,n);o="string"===typeof r?r:""}else{if(b){o=a[0];continue}s.logger.warn("missed to pass in variable ".concat(a[1]," for interpolating ").concat(e)),o=""}else"string"===typeof o||s.useRawValueToEscape||(o=m(o));var i=t.safeValue(o);if(e=e.replace(a[0],i),b?(t.regex.lastIndex+=i.length,t.regex.lastIndex-=a[0].length):t.regex.lastIndex=0,++c>=s.maxReplaces)break}})),e}},{key:"nest",value:function(e,t){var r,n,a=this,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},c=i({},o);function s(e,t){var r=this.nestingOptionsSeparator;if(e.indexOf(r)<0)return e;var n=e.split(new RegExp("".concat(r,"[ ]*{"))),a="{".concat(n[1]);e=n[0],a=(a=this.interpolate(a,c)).replace(/'/g,'"');try{c=JSON.parse(a),t&&(c=i({},t,c))}catch(o){return this.logger.warn("failed parsing options string in nesting for key ".concat(e),o),"".concat(e).concat(r).concat(a)}return delete c.defaultValue,e}for(c.applyPostProcessor=!1,delete c.defaultValue;r=this.nestingRegexp.exec(e);){var f=[],d=!1;if(-1!==r[0].indexOf(this.formatSeparator)&&!/{.*}/.test(r[1])){var u=r[1].split(this.formatSeparator).map((function(e){return e.trim()}));r[1]=u.shift(),f=u,d=!0}if((n=t(s.call(this,r[1].trim(),c),c))&&r[0]===e&&"string"!==typeof n)return n;"string"!==typeof n&&(n=m(n)),n||(this.logger.warn("missed to resolve ".concat(r[1]," for nesting ").concat(e)),n=""),d&&(n=f.reduce((function(e,t){return a.format(e,t,o.lng,i({},o,{interpolationkey:r[1].trim()}))}),n.trim())),e=e.replace(r[0],n),this.regexp.lastIndex=0}return e}}]),e}();var D=function(e){function t(e,r,n){var a,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return Object(o.a)(this,t),a=Object(s.a)(this,Object(f.a)(t).call(this)),E&&h.call(Object(d.a)(a)),a.backend=e,a.store=r,a.services=n,a.languageUtils=n.languageUtils,a.options=i,a.logger=b.create("backendConnector"),a.state={},a.queue=[],a.backend&&a.backend.init&&a.backend.init(n,i.backend,i),a}return Object(u.a)(t,e),Object(c.a)(t,[{key:"queueLoad",value:function(e,t,r,n){var a=this,i=[],o=[],c=[],s=[];return e.forEach((function(e){var n=!0;t.forEach((function(t){var c="".concat(e,"|").concat(t);!r.reload&&a.store.hasResourceBundle(e,t)?a.state[c]=2:a.state[c]<0||(1===a.state[c]?o.indexOf(c)<0&&o.push(c):(a.state[c]=1,n=!1,o.indexOf(c)<0&&o.push(c),i.indexOf(c)<0&&i.push(c),s.indexOf(t)<0&&s.push(t)))})),n||c.push(e)})),(i.length||o.length)&&this.queue.push({pending:o,loaded:{},errors:[],callback:n}),{toLoad:i,pending:o,toLoadLanguages:c,toLoadNamespaces:s}}},{key:"loaded",value:function(e,t,r){var n=e.split("|"),a=n[0],i=n[1];t&&this.emit("failedLoading",a,i,t),r&&this.store.addResourceBundle(a,i,r),this.state[e]=t?-1:2;var o={};this.queue.forEach((function(r){!function(e,t,r,n){var a=g(e,t,Object),i=a.obj,o=a.k;i[o]=i[o]||[],n&&(i[o]=i[o].concat(r)),n||i[o].push(r)}(r.loaded,[a],i),function(e,t){for(var r=e.indexOf(t);-1!==r;)e.splice(r,1),r=e.indexOf(t)}(r.pending,e),t&&r.errors.push(t),0!==r.pending.length||r.done||(Object.keys(r.loaded).forEach((function(e){o[e]||(o[e]=[]),r.loaded[e].length&&r.loaded[e].forEach((function(t){o[e].indexOf(t)<0&&o[e].push(t)}))})),r.done=!0,r.errors.length?r.callback(r.errors):r.callback())})),this.emit("loaded",o),this.queue=this.queue.filter((function(e){return!e.done}))}},{key:"read",value:function(e,t,r){var n=this,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:350,o=arguments.length>5?arguments[5]:void 0;return e.length?this.backend[r](e,t,(function(c,s){c&&s&&a<5?setTimeout((function(){n.read.call(n,e,t,r,a+1,2*i,o)}),i):o(c,s)})):o(null,{})}},{key:"prepareLoading",value:function(e,t){var r=this,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},a=arguments.length>3?arguments[3]:void 0;if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),a&&a();"string"===typeof e&&(e=this.languageUtils.toResolveHierarchy(e)),"string"===typeof t&&(t=[t]);var i=this.queueLoad(e,t,n,a);if(!i.toLoad.length)return i.pending.length||a(),null;i.toLoad.forEach((function(e){r.loadOne(e)}))}},{key:"load",value:function(e,t,r){this.prepareLoading(e,t,{},r)}},{key:"reload",value:function(e,t,r){this.prepareLoading(e,t,{reload:!0},r)}},{key:"loadOne",value:function(e){var t=this,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=e.split("|"),a=n[0],i=n[1];this.read(a,i,"read",void 0,void 0,(function(n,o){n&&t.logger.warn("".concat(r,"loading namespace ").concat(i," for language ").concat(a," failed"),n),!n&&o&&t.logger.log("".concat(r,"loaded namespace ").concat(i," for language ").concat(a),o),t.loaded(e,n,o)}))}},{key:"saveMissing",value:function(e,t,r,n,a){var o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{};this.services.utils&&this.services.utils.hasLoadedNamespace&&!this.services.utils.hasLoadedNamespace(t)?this.logger.warn('did not save key "'.concat(r,'" as the namespace "').concat(t,'" was not yet loaded'),"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!"):void 0!==r&&null!==r&&""!==r&&(this.backend&&this.backend.create&&this.backend.create(e,t,r,n,null,i({},o,{isUpdate:a})),e&&e[0]&&this.store.addResource(e[0],t,r,n))}}]),t}(h);function U(){return{debug:!1,initImmediate:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,whitelist:!1,nonExplicitWhitelist:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!0,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:function(e){var t={};if("object"===Object(n.a)(e[1])&&(t=e[1]),"string"===typeof e[1]&&(t.defaultValue=e[1]),"string"===typeof e[2]&&(t.tDescription=e[2]),"object"===Object(n.a)(e[2])||"object"===Object(n.a)(e[3])){var r=e[3]||e[2];Object.keys(r).forEach((function(e){t[e]=r[e]}))}return t},interpolation:{escapeValue:!0,format:function(e,t,r,n){return e},prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!1}}}function z(e){return"string"===typeof e.ns&&(e.ns=[e.ns]),"string"===typeof e.fallbackLng&&(e.fallbackLng=[e.fallbackLng]),"string"===typeof e.fallbackNS&&(e.fallbackNS=[e.fallbackNS]),e.whitelist&&(e.whitelist&&e.whitelist.indexOf("cimode")<0&&(e.whitelist=e.whitelist.concat(["cimode"])),e.supportedLngs=e.whitelist),e.nonExplicitWhitelist&&(e.nonExplicitSupportedLngs=e.nonExplicitWhitelist),e.supportedLngs&&e.supportedLngs.indexOf("cimode")<0&&(e.supportedLngs=e.supportedLngs.concat(["cimode"])),e}function H(){}var q=new(function(e){function t(){var e,r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1?arguments[1]:void 0;if(Object(o.a)(this,t),e=Object(s.a)(this,Object(f.a)(t).call(this)),E&&h.call(Object(d.a)(e)),e.options=z(r),e.services={},e.logger=b,e.modules={external:[]},n&&!e.isInitialized&&!r.isClone){if(!e.options.initImmediate)return e.init(r,n),Object(s.a)(e,Object(d.a)(e));setTimeout((function(){e.init(r,n)}),0)}return e}return Object(u.a)(t,e),Object(c.a)(t,[{key:"init",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},r=arguments.length>1?arguments[1]:void 0;function n(e){return e?"function"===typeof e?new e:e:null}if("function"===typeof t&&(r=t,t={}),t.whitelist&&!t.supportedLngs&&this.logger.deprecate("whitelist",'option "whitelist" will be renamed to "supportedLngs" in the next major - please make sure to rename this option asap.'),t.nonExplicitWhitelist&&!t.nonExplicitSupportedLngs&&this.logger.deprecate("whitelist",'options "nonExplicitWhitelist" will be renamed to "nonExplicitSupportedLngs" in the next major - please make sure to rename this option asap.'),this.options=i({},U(),this.options,z(t)),this.format=this.options.interpolation.format,r||(r=H),!this.options.isClone){this.modules.logger?b.init(n(this.modules.logger),this.options):b.init(null,this.options);var a=new R(this.options);this.store=new A(this.options.resources,this.options);var o=this.services;o.logger=b,o.resourceStore=this.store,o.languageUtils=a,o.pluralResolver=new I(a,{prepend:this.options.pluralSeparator,compatibilityJSON:this.options.compatibilityJSON,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),o.interpolator=new F(this.options),o.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},o.backendConnector=new D(n(this.modules.backend),o.resourceStore,o,this.options),o.backendConnector.on("*",(function(t){for(var r=arguments.length,n=new Array(r>1?r-1:0),a=1;a1?r-1:0),a=1;a0&&"dev"!==c[0]&&(this.options.lng=c[0])}this.services.languageDetector||this.options.lng||this.logger.warn("init: no languageDetector is used and no lng is defined");var s=["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"];s.forEach((function(t){e[t]=function(){var r;return(r=e.store)[t].apply(r,arguments)}}));var f=["addResource","addResources","addResourceBundle","removeResourceBundle"];f.forEach((function(t){e[t]=function(){var r;return(r=e.store)[t].apply(r,arguments),e}}));var d=p(),u=function(){var t=function(t,n){e.isInitialized&&e.logger.warn("init: i18next is already initialized. You should call init just once!"),e.isInitialized=!0,e.options.isClone||e.logger.log("initialized",e.options),e.emit("initialized",e.options),d.resolve(n),r(t,n)};if(e.languages&&"v1"!==e.options.compatibilityAPI&&!e.isInitialized)return t(null,e.t.bind(e));e.changeLanguage(e.options.lng,t)};return this.options.resources||!this.options.initImmediate?u():setTimeout(u,0),d}},{key:"loadResources",value:function(e){var t=this,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:H,n=r,a="string"===typeof e?e:this.language;if("function"===typeof e&&(n=e),!this.options.resources||this.options.partialBundledLanguages){if(a&&"cimode"===a.toLowerCase())return n();var i=[],o=function(e){e&&t.services.languageUtils.toResolveHierarchy(e).forEach((function(e){i.indexOf(e)<0&&i.push(e)}))};if(a)o(a);else{var c=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);c.forEach((function(e){return o(e)}))}this.options.preload&&this.options.preload.forEach((function(e){return o(e)})),this.services.backendConnector.load(i,this.options.ns,n)}else n(null)}},{key:"reloadResources",value:function(e,t,r){var n=p();return e||(e=this.languages),t||(t=this.options.ns),r||(r=H),this.services.backendConnector.reload(e,t,(function(e){n.resolve(),r(e)})),n}},{key:"use",value:function(e){if(!e)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!e.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return"backend"===e.type&&(this.modules.backend=e),("logger"===e.type||e.log&&e.warn&&e.error)&&(this.modules.logger=e),"languageDetector"===e.type&&(this.modules.languageDetector=e),"i18nFormat"===e.type&&(this.modules.i18nFormat=e),"postProcessor"===e.type&&T.addPostProcessor(e),"3rdParty"===e.type&&this.modules.external.push(e),this}},{key:"changeLanguage",value:function(e,t){var r=this;this.isLanguageChangingTo=e;var n=p();this.emit("languageChanging",e);var a=function(a){e||a||!r.services.languageDetector||(a=[]);var i="string"===typeof a?a:r.services.languageUtils.getBestMatchFromCodes(a);i&&(r.language||(r.language=i,r.languages=r.services.languageUtils.toResolveHierarchy(i)),r.translator.language||r.translator.changeLanguage(i),r.services.languageDetector&&r.services.languageDetector.cacheUserLanguage(i)),r.loadResources(i,(function(e){!function(e,a){a?(r.language=a,r.languages=r.services.languageUtils.toResolveHierarchy(a),r.translator.changeLanguage(a),r.isLanguageChangingTo=void 0,r.emit("languageChanged",a),r.logger.log("languageChanged",a)):r.isLanguageChangingTo=void 0,n.resolve((function(){return r.t.apply(r,arguments)})),t&&t(e,(function(){return r.t.apply(r,arguments)}))}(e,i)}))};return e||!this.services.languageDetector||this.services.languageDetector.async?!e&&this.services.languageDetector&&this.services.languageDetector.async?this.services.languageDetector.detect(a):a(e):a(this.services.languageDetector.detect()),n}},{key:"getFixedT",value:function(e,t){var r=this,a=function e(t,a){var o;if("object"!==Object(n.a)(a)){for(var c=arguments.length,s=new Array(c>2?c-2:0),f=2;f1&&void 0!==arguments[1]?arguments[1]:{};if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;var n=this.languages[0],a=!!this.options&&this.options.fallbackLng,i=this.languages[this.languages.length-1];if("cimode"===n.toLowerCase())return!0;var o=function(e,r){var n=t.services.backendConnector.state["".concat(e,"|").concat(r)];return-1===n||2===n};if(r.precheck){var c=r.precheck(this,o);if(void 0!==c)return c}return!!this.hasResourceBundle(n,e)||(!this.services.backendConnector.backend||!(!o(n,e)||a&&!o(i,e)))}},{key:"loadNamespaces",value:function(e,t){var r=this,n=p();return this.options.ns?("string"===typeof e&&(e=[e]),e.forEach((function(e){r.options.ns.indexOf(e)<0&&r.options.ns.push(e)})),this.loadResources((function(e){n.resolve(),t&&t(e)})),n):(t&&t(),Promise.resolve())}},{key:"loadLanguages",value:function(e,t){var r=p();"string"===typeof e&&(e=[e]);var n=this.options.preload||[],a=e.filter((function(e){return n.indexOf(e)<0}));return a.length?(this.options.preload=n.concat(a),this.loadResources((function(e){r.resolve(),t&&t(e)})),r):(t&&t(),Promise.resolve())}},{key:"dir",value:function(e){if(e||(e=this.languages&&this.languages.length>0?this.languages[0]:this.language),!e)return"rtl";return["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam"].indexOf(this.services.languageUtils.getLanguagePartFromCode(e))>=0?"rtl":"ltr"}},{key:"createInstance",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},r=arguments.length>1?arguments[1]:void 0;return new t(e,r)}},{key:"cloneInstance",value:function(){var e=this,r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:H,a=i({},this.options,r,{isClone:!0}),o=new t(a),c=["store","services","language"];return c.forEach((function(t){o[t]=e[t]})),o.services=i({},this.services),o.services.utils={hasLoadedNamespace:o.hasLoadedNamespace.bind(o)},o.translator=new P(o.services,o.options),o.translator.on("*",(function(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n=0}))},t.toAscii=function(e){var t="",r=0,n=e.length;for("0x"===e.substring(0,2)&&(r=2);r2?"one of ".concat(t," ").concat(e.slice(0,r-1).join(", "),", or ")+e[r-1]:2===r?"one of ".concat(t," ").concat(e[0]," or ").concat(e[1]):"of ".concat(t," ").concat(e[0])}return"of ".concat(t," ").concat(String(e))}a("ERR_INVALID_OPT_VALUE",(function(e,t){return'The value "'+t+'" is invalid for option "'+e+'"'}),TypeError),a("ERR_INVALID_ARG_TYPE",(function(e,t,r){var n,a,o,c;if("string"===typeof t&&(a="not ",t.substr(!o||o<0?0:+o,a.length)===a)?(n="must not be",t=t.replace(/^not /,"")):n="must be",function(e,t,r){return(void 0===r||r>e.length)&&(r=e.length),e.substring(r-t.length,r)===t}(e," argument"))c="The ".concat(e," ").concat(n," ").concat(i(t,"type"));else{var s=function(e,t,r){return"number"!==typeof r&&(r=0),!(r+t.length>e.length)&&-1!==e.indexOf(t,r)}(e,".")?"property":"argument";c='The "'.concat(e,'" ').concat(s," ").concat(n," ").concat(i(t,"type"))}return c+=". Received type ".concat(typeof r)}),TypeError),a("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),a("ERR_METHOD_NOT_IMPLEMENTED",(function(e){return"The "+e+" method is not implemented"})),a("ERR_STREAM_PREMATURE_CLOSE","Premature close"),a("ERR_STREAM_DESTROYED",(function(e){return"Cannot call "+e+" after a stream was destroyed"})),a("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),a("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),a("ERR_STREAM_WRITE_AFTER_END","write after end"),a("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),a("ERR_UNKNOWN_ENCODING",(function(e){return"Unknown encoding: "+e}),TypeError),a("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),e.exports.codes=n},function(e,t,r){"use strict";(function(t){var n=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};e.exports=f;var a=r(407),i=r(411);r(33)(f,a);for(var o=n(i.prototype),c=0;c2?"one of ".concat(t," ").concat(e.slice(0,r-1).join(", "),", or ")+e[r-1]:2===r?"one of ".concat(t," ").concat(e[0]," or ").concat(e[1]):"of ".concat(t," ").concat(e[0])}return"of ".concat(t," ").concat(String(e))}a("ERR_INVALID_OPT_VALUE",(function(e,t){return'The value "'+t+'" is invalid for option "'+e+'"'}),TypeError),a("ERR_INVALID_ARG_TYPE",(function(e,t,r){var n,a,o,c;if("string"===typeof t&&(a="not ",t.substr(!o||o<0?0:+o,a.length)===a)?(n="must not be",t=t.replace(/^not /,"")):n="must be",function(e,t,r){return(void 0===r||r>e.length)&&(r=e.length),e.substring(r-t.length,r)===t}(e," argument"))c="The ".concat(e," ").concat(n," ").concat(i(t,"type"));else{var s=function(e,t,r){return"number"!==typeof r&&(r=0),!(r+t.length>e.length)&&-1!==e.indexOf(t,r)}(e,".")?"property":"argument";c='The "'.concat(e,'" ').concat(s," ").concat(n," ").concat(i(t,"type"))}return c+=". Received type ".concat(typeof r)}),TypeError),a("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),a("ERR_METHOD_NOT_IMPLEMENTED",(function(e){return"The "+e+" method is not implemented"})),a("ERR_STREAM_PREMATURE_CLOSE","Premature close"),a("ERR_STREAM_DESTROYED",(function(e){return"Cannot call "+e+" after a stream was destroyed"})),a("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),a("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),a("ERR_STREAM_WRITE_AFTER_END","write after end"),a("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),a("ERR_UNKNOWN_ENCODING",(function(e){return"Unknown encoding: "+e}),TypeError),a("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),e.exports.codes=n},function(e,t,r){"use strict";(function(t){var n=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};e.exports=f;var a=r(414),i=r(418);r(33)(f,a);for(var o=n(i.prototype),c=0;c=this._finalSize&&(this._update(this._block),this._block.fill(0));var r=8*this._len;if(r<=4294967295)this._block.writeUInt32BE(r,this._blockSize-4);else{var n=(4294967295&r)>>>0,a=(r-n)/4294967296;this._block.writeUInt32BE(a,this._blockSize-8),this._block.writeUInt32BE(n,this._blockSize-4)}this._update(this._block);var i=this._hash();return e?i.toString(e):i},a.prototype._update=function(){throw new Error("_update must be implemented by subclass")},e.exports=a},function(e,t,r){"use strict";var n=r(428),a=r(712);function i(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}t.parse=x,t.resolve=function(e,t){return x(e,!1,!0).resolve(t)},t.resolveObject=function(e,t){return e?x(e,!1,!0).resolveObject(t):t},t.format=function(e){a.isString(e)&&(e=x(e));return e instanceof i?e.format():i.prototype.format.call(e)},t.Url=i;var o=/^([a-z0-9.+-]+:)/i,c=/:[0-9]*$/,s=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,f=["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r","\n","\t"]),d=["'"].concat(f),u=["%","/","?",";","#"].concat(d),l=["/","?","#"],b=/^[+a-z0-9A-Z_-]{0,63}$/,h=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,p={javascript:!0,"javascript:":!0},m={javascript:!0,"javascript:":!0},v={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},g=r(713);function x(e,t,r){if(e&&a.isObject(e)&&e instanceof i)return e;var n=new i;return n.parse(e,t,r),n}i.prototype.parse=function(e,t,r){if(!a.isString(e))throw new TypeError("Parameter 'url' must be a string, not "+typeof e);var i=e.indexOf("?"),c=-1!==i&&i127?R+="x":R+=C[N];if(!R.match(b)){var L=j.slice(0,O),I=j.slice(O+1),F=C.match(h);F&&(L.push(F[1]),I.unshift(F[2])),I.length&&(x="/"+I.join(".")+x),this.hostname=L.join(".");break}}}this.hostname.length>255?this.hostname="":this.hostname=this.hostname.toLowerCase(),T||(this.hostname=n.toASCII(this.hostname));var D=this.port?":"+this.port:"",U=this.hostname||"";this.host=U+D,this.href+=this.host,T&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),"/"!==x[0]&&(x="/"+x))}if(!p[k])for(O=0,P=d.length;O0)&&r.host.split("@"))&&(r.auth=T.shift(),r.host=r.hostname=T.shift());return r.search=e.search,r.query=e.query,a.isNull(r.pathname)&&a.isNull(r.search)||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.href=r.format(),r}if(!_.length)return r.pathname=null,r.search?r.path="/"+r.search:r.path=null,r.href=r.format(),r;for(var S=_.slice(-1)[0],E=(r.host||e.host||_.length>1)&&("."===S||".."===S)||""===S,O=0,A=_.length;A>=0;A--)"."===(S=_[A])?_.splice(A,1):".."===S?(_.splice(A,1),O++):O&&(_.splice(A,1),O--);if(!w&&!k)for(;O--;O)_.unshift("..");!w||""===_[0]||_[0]&&"/"===_[0].charAt(0)||_.unshift(""),E&&"/"!==_.join("/").substr(-1)&&_.push("");var T,j=""===_[0]||_[0]&&"/"===_[0].charAt(0);M&&(r.hostname=r.host=j?"":_.length?_.shift():"",(T=!!(r.host&&r.host.indexOf("@")>0)&&r.host.split("@"))&&(r.auth=T.shift(),r.host=r.hostname=T.shift()));return(w=w||r.host&&_.length)&&!j&&_.unshift(""),_.length?r.pathname=_.join("/"):(r.pathname=null,r.path=null),a.isNull(r.pathname)&&a.isNull(r.search)||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.auth=e.auth||r.auth,r.slashes=r.slashes||e.slashes,r.href=r.format(),r},i.prototype.parseHost=function(){var e=this.host,t=c.exec(e);t&&(":"!==(t=t[0])&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)}},function(e,t,r){"use strict";var n={};function a(e,t,r){r||(r=Error);var a=function(e){var r,n;function a(r,n,a){return e.call(this,function(e,r,n){return"string"===typeof t?t:t(e,r,n)}(r,n,a))||this}return n=e,(r=a).prototype=Object.create(n.prototype),r.prototype.constructor=r,r.__proto__=n,a}(r);a.prototype.name=r.name,a.prototype.code=e,n[e]=a}function i(e,t){if(Array.isArray(e)){var r=e.length;return e=e.map((function(e){return String(e)})),r>2?"one of ".concat(t," ").concat(e.slice(0,r-1).join(", "),", or ")+e[r-1]:2===r?"one of ".concat(t," ").concat(e[0]," or ").concat(e[1]):"of ".concat(t," ").concat(e[0])}return"of ".concat(t," ").concat(String(e))}a("ERR_INVALID_OPT_VALUE",(function(e,t){return'The value "'+t+'" is invalid for option "'+e+'"'}),TypeError),a("ERR_INVALID_ARG_TYPE",(function(e,t,r){var n,a,o,c;if("string"===typeof t&&(a="not ",t.substr(!o||o<0?0:+o,a.length)===a)?(n="must not be",t=t.replace(/^not /,"")):n="must be",function(e,t,r){return(void 0===r||r>e.length)&&(r=e.length),e.substring(r-t.length,r)===t}(e," argument"))c="The ".concat(e," ").concat(n," ").concat(i(t,"type"));else{var s=function(e,t,r){return"number"!==typeof r&&(r=0),!(r+t.length>e.length)&&-1!==e.indexOf(t,r)}(e,".")?"property":"argument";c='The "'.concat(e,'" ').concat(s," ").concat(n," ").concat(i(t,"type"))}return c+=". Received type ".concat(typeof r)}),TypeError),a("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),a("ERR_METHOD_NOT_IMPLEMENTED",(function(e){return"The "+e+" method is not implemented"})),a("ERR_STREAM_PREMATURE_CLOSE","Premature close"),a("ERR_STREAM_DESTROYED",(function(e){return"Cannot call "+e+" after a stream was destroyed"})),a("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),a("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),a("ERR_STREAM_WRITE_AFTER_END","write after end"),a("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),a("ERR_UNKNOWN_ENCODING",(function(e){return"Unknown encoding: "+e}),TypeError),a("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),e.exports.codes=n},function(e,t,r){"use strict";(function(t){var n=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};e.exports=f;var a=r(459),i=r(463);r(33)(f,a);for(var o=n(i.prototype),c=0;c=t)throw new Error("Cannot access property/index "+n+" levels up, current level is "+t);return r[t-n]}if(n>t)throw new Error("Cannot access data "+n+" levels up, current level is "+t);if(i="data"+(t-n||""),!a)return i}for(var c=i,f=a.split("/"),d=0;d0;)r.push(a%this.base),a=a/this.base|0}for(var c="",s=0;0===t[s]&&s=0;--f)c+=this.alphabet[r[f]];return c}},{key:"decode",value:function(e){if("string"!==typeof e)throw new TypeError("Expected String");var t=[];if(0===e.length)return new Uint8Array(t);t.push(0);for(var r=0;r>=8;for(;a>0;)t.push(255&a),a>>=8}for(var c=0;e[c]===this._leader&&c0})))}),(function(){return!1}))):Promise.resolve(!1)}catch(e){return Promise.reject(e)}},t}(n.a)},function(e,t,r){var n=r(619),a=r(620),i=r(621),o=r(623);e.exports=function(e,t){return n(e)||a(e,t)||i(e,t)||o()},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,r){"use strict";var n=r(701).version,a=r(153),i=r(739),o=r(243),c=r(440),s=r(890),f=r(891),d=r(78),u=function(){var e=this;a.packageInit(this,arguments),this.version=n,this.utils=d,this.eth=new i(this),this.shh=new s(this),this.bzz=new f(this);var t=this.setProvider;this.setProvider=function(r,n){return t.apply(e,arguments),e.eth.setRequestManager(e._requestManager),e.shh.setRequestManager(e._requestManager),e.bzz.setProvider(r),!0}};u.version=n,u.utils=d,u.modules={Eth:i,Net:o,Personal:c,Shh:s,Bzz:f},a.addProviders(u),e.exports=u},function(e,t,r){"use strict";var n=r(492),a=r(133),i=r(947).names,o=r(333),c=r(497),s=r(335),f={};for(var d in i){var u=d;f[i[u]]=u}function l(e){if(!(e instanceof Uint8Array))throw new Error("multihash must be a Uint8Array");if(e.length<2)throw new Error("multihash too short. must be > 2 bytes.");var t=a.decode(e);if(!p(t))throw new Error("multihash unknown function code: 0x".concat(t.toString(16)));e=e.slice(a.decode.bytes);var r=a.decode(e);if(r<0)throw new Error("multihash invalid length: ".concat(r));if((e=e.slice(a.decode.bytes)).length!==r)throw new Error("multihash length inconsistent: 0x".concat(o(e,"base16")));return{code:t,name:f[t],length:r,digest:e}}function b(e){var t=e;if("string"===typeof e){if(void 0===i[e])throw new Error("Unrecognized hash function named: ".concat(e));t=i[e]}if("number"!==typeof t)throw new Error("Hash function code should be a number. Got: ".concat(t));if(void 0===f[t]&&!h(t))throw new Error("Unrecognized function code: ".concat(t));return t}function h(e){return e>0&&e<16}function p(e){return!!h(e)||!!f[e]}function m(e){l(e)}Object.freeze(f),e.exports={names:i,codes:f,toHexString:function(e){if(!(e instanceof Uint8Array))throw new Error("must be passed a Uint8Array");return o(e,"base16")},fromHexString:function(e){return c(e,"base16")},toB58String:function(e){if(!(e instanceof Uint8Array))throw new Error("must be passed a Uint8Array");return o(n.encode("base58btc",e)).slice(1)},fromB58String:function(e){var t=e instanceof Uint8Array?o(e):e;return n.decode("z"+t)},decode:l,encode:function(e,t,r){if(!e||void 0===t)throw new Error("multihash encode requires at least two args: digest, code");var n=b(t);if(!(e instanceof Uint8Array))throw new Error("digest should be a Uint8Array");if(null==r&&(r=e.length),r&&e.length!==r)throw new Error("digest length should be equal to specified length.");var i=a.encode(n),o=a.encode(r);return s([i,o,e],i.length+o.length+e.length)},coerceCode:b,isAppCode:h,validate:m,prefix:function(e){return m(e),e.subarray(0,2)},isValidCode:p}},function(e,t,r){"use strict";t.a=function(e){var t={};return function(r){return void 0===t[r]&&(t[r]=e(r)),t[r]}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"Box",{enumerable:!0,get:function(){return a.Box}}),Object.defineProperty(t,"Flex",{enumerable:!0,get:function(){return a.Flex}}),t.Card=t.Image=t.Button=t.Link=t.Heading=t.Text=void 0;var n=function(e){if(e&&e.__esModule)return e;var t=i();if(t&&t.has(e))return t.get(e);var r={};if(null!=e){var n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if(Object.prototype.hasOwnProperty.call(e,a)){var o=n?Object.getOwnPropertyDescriptor(e,a):null;o&&(o.get||o.set)?Object.defineProperty(r,a,o):r[a]=e[a]}}r.default=e,t&&t.set(e,r);return r}(r(1)),a=r(970);function i(){if("function"!==typeof WeakMap)return null;var e=new WeakMap;return i=function(){return e},e}function o(){return(o=Object.assign||function(e){for(var t=1;t>25;return(33554431&e)<<5^996825010&-(t>>0&1)^642813549&-(t>>1&1)^513874426&-(t>>2&1)^1027748829&-(t>>3&1)^705979059&-(t>>4&1)}function s(e){for(var t=1,r=0;r126)return"Invalid prefix ("+e+")";t=c(t)^n>>5}for(t=c(t),r=0;rt)return"Exceeds length limit";var r=e.toLowerCase(),n=e.toUpperCase();if(e!==r&&e!==n)return"Mixed-case string "+e;var i=(e=r).lastIndexOf("1");if(-1===i)return"No separator character for "+e;if(0===i)return"Missing prefix for "+e;var o=e.slice(0,i),f=e.slice(i+1);if(f.length<6)return"Data too short";var d=s(o);if("string"===typeof d)return d;for(var u=[],l=0;l=f.length||u.push(h)}return 1!==d?"Invalid checksum for "+e:{prefix:o,words:u}}function d(e,t,r,n){for(var a=0,i=0,o=(1<=r;)i-=r,c.push(a>>i&o);if(n)i>0&&c.push(a<=t)return"Excess padding";if(a<r)throw new TypeError("Exceeds length limit");var a=s(e=e.toLowerCase());if("string"===typeof a)throw new Error(a);for(var i=e+"1",o=0;o>5!==0)throw new Error("Non 5-bit word");a=c(a)^f,i+=n.charAt(f)}for(o=0;o<6;++o)a=c(a);for(a^=1,o=0;o<6;++o){i+=n.charAt(a>>5*(5-o)&31)}return i},toWordsUnsafe:function(e){var t=d(e,8,5,!0);if(Array.isArray(t))return t},toWords:function(e){var t=d(e,8,5,!0);if(Array.isArray(t))return t;throw new Error(t)},fromWordsUnsafe:function(e){var t=d(e,5,8,!1);if(Array.isArray(t))return t},fromWords:function(e){var t=d(e,5,8,!1);if(Array.isArray(t))return t;throw new Error(t)}}},function(e,t,r){"use strict";r.d(t,"a",(function(){return s}));var n=r(6),a=r(7),i=r(5),o=r(9),c=function(){function e(t){Object(n.a)(this,e),Object(o.d)(this,"alphabet",t),Object(o.d)(this,"base",t.length),Object(o.d)(this,"_alphabetMap",{}),Object(o.d)(this,"_leader",t.charAt(0));for(var r=0;r0;)r.push(a%this.base),a=a/this.base|0}for(var c="",s=0;0===t[s]&&s=0;--f)c+=this.alphabet[r[f]];return c}},{key:"decode",value:function(e){if("string"!==typeof e)throw new TypeError("Expected String");var t=[];if(0===e.length)return new Uint8Array(t);t.push(0);for(var r=0;r>=8;for(;a>0;)t.push(255&a),a>>=8}for(var c=0;e[c]===this._leader&&c=this._delta8){var r=(e=this.pending).length%this._delta8;this.pending=e.slice(e.length-r,e.length),0===this.pending.length&&(this.pending=null),e=n.join32(e,0,e.length-r,this.endian);for(var a=0;a>>24&255,n[a++]=e>>>16&255,n[a++]=e>>>8&255,n[a++]=255&e}else for(n[a++]=255&e,n[a++]=e>>>8&255,n[a++]=e>>>16&255,n[a++]=e>>>24&255,n[a++]=0,n[a++]=0,n[a++]=0,n[a++]=0,i=8;i1&&v.throwArgumentError("multiple matching functions","name",r),this.functions[n[0]]}var a=this.functions[h.f.fromString(e).format()];return a||v.throwArgumentError("no matching function","signature",e),a}},{key:"getEvent",value:function(e){if(Object(f.isHexString)(e)){var t=e.toLowerCase();for(var r in this.events)if(t===this.getEventTopic(r))return this.events[r];v.throwArgumentError("no matching event","topichash",t)}if(-1===e.indexOf("(")){var n=e.trim(),a=Object.keys(this.events).filter((function(e){return e.split("(")[0]===n}));return 0===a.length?v.throwArgumentError("no matching event","name",n):a.length>1&&v.throwArgumentError("multiple matching events","name",n),this.events[a[0]]}var i=this.events[h.c.fromString(e).format()];return i||v.throwArgumentError("no matching event","signature",e),i}},{key:"getError",value:function(e){if(Object(f.isHexString)(e)){var t=Object(l.getStatic)(this.constructor,"getSighash");for(var r in this.errors){if(e===t(this.errors[r]))return this.errors[r]}v.throwArgumentError("no matching error","sighash",e)}if(-1===e.indexOf("(")){var n=e.trim(),a=Object.keys(this.errors).filter((function(e){return e.split("(")[0]===n}));return 0===a.length?v.throwArgumentError("no matching error","name",n):a.length>1&&v.throwArgumentError("multiple matching errors","name",n),this.errors[a[0]]}var i=this.errors[h.f.fromString(e).format()];return i||v.throwArgumentError("no matching error","signature",e),i}},{key:"getSighash",value:function(e){return"string"===typeof e&&(e=this.getFunction(e)),Object(l.getStatic)(this.constructor,"getSighash")(e)}},{key:"getEventTopic",value:function(e){return"string"===typeof e&&(e=this.getEvent(e)),Object(l.getStatic)(this.constructor,"getEventTopic")(e)}},{key:"_decodeParams",value:function(e,t){return this._abiCoder.decode(e,t)}},{key:"_encodeParams",value:function(e,t){return this._abiCoder.encode(e,t)}},{key:"encodeDeploy",value:function(e){return this._encodeParams(this.deploy.inputs,e||[])}},{key:"decodeFunctionData",value:function(e,t){"string"===typeof e&&(e=this.getFunction(e));var r=Object(f.arrayify)(t);return Object(f.hexlify)(r.slice(0,4))!==this.getSighash(e)&&v.throwArgumentError("data signature does not match function ".concat(e.name,"."),"data",Object(f.hexlify)(r)),this._decodeParams(e.inputs,r.slice(4))}},{key:"encodeFunctionData",value:function(e,t){return"string"===typeof e&&(e=this.getFunction(e)),Object(f.hexlify)(Object(f.concat)([this.getSighash(e),this._encodeParams(e.inputs,t||[])]))}},{key:"decodeFunctionResult",value:function(e,t){"string"===typeof e&&(e=this.getFunction(e));var r=Object(f.arrayify)(t),n=null,a=null,i=null,o=null;switch(r.length%this._abiCoder._getWordSize()){case 0:try{return this._abiCoder.decode(e.outputs,r)}catch(d){}break;case 4:var c=Object(f.hexlify)(r.slice(0,4)),s=w[c];if(s)a=this._abiCoder.decode(s.inputs,r.slice(4)),i=s.name,o=s.signature,s.reason&&(n=a[0]);else try{var d=this.getError(c);a=this._abiCoder.decode(d.inputs,r.slice(4)),i=d.name,o=d.format()}catch(d){console.log(d)}}return v.throwError("call revert exception",p.Logger.errors.CALL_EXCEPTION,{method:e.format(),errorArgs:a,errorName:i,errorSignature:o,reason:n})}},{key:"encodeFunctionResult",value:function(e,t){return"string"===typeof e&&(e=this.getFunction(e)),Object(f.hexlify)(this._abiCoder.encode(e.outputs,t||[]))}},{key:"encodeFilterTopics",value:function(e,t){var r=this;"string"===typeof e&&(e=this.getEvent(e)),t.length>e.inputs.length&&v.throwError("too many arguments for "+e.format(),p.Logger.errors.UNEXPECTED_ARGUMENT,{argument:"values",value:t});var n=[];e.anonymous||n.push(this.getEventTopic(e));var a=function(e,t){return"string"===e.type?Object(d.a)(t):"bytes"===e.type?Object(u.keccak256)(Object(f.hexlify)(t)):("address"===e.type&&r._abiCoder.encode(["address"],[t]),Object(f.hexZeroPad)(Object(f.hexlify)(t),32))};for(t.forEach((function(t,r){var i=e.inputs[r];i.indexed?null==t?n.push(null):"array"===i.baseType||"tuple"===i.baseType?v.throwArgumentError("filtering with tuples or arrays not supported","contract."+i.name,t):Array.isArray(t)?n.push(t.map((function(e){return a(i,e)}))):n.push(a(i,t)):null!=t&&v.throwArgumentError("cannot filter non-indexed parameters; must be null","contract."+i.name,t)}));n.length&&null===n[n.length-1];)n.pop();return n}},{key:"encodeEventLog",value:function(e,t){var r=this;"string"===typeof e&&(e=this.getEvent(e));var n=[],a=[],i=[];return e.anonymous||n.push(this.getEventTopic(e)),t.length!==e.inputs.length&&v.throwArgumentError("event arguments/values mismatch","values",t),e.inputs.forEach((function(e,o){var c=t[o];if(e.indexed)if("string"===e.type)n.push(Object(d.a)(c));else if("bytes"===e.type)n.push(Object(u.keccak256)(c));else{if("tuple"===e.baseType||"array"===e.baseType)throw new Error("not implemented");n.push(r._abiCoder.encode([e.type],[c]))}else a.push(e),i.push(c)})),{data:this._abiCoder.encode(a,i),topics:n}}},{key:"decodeEventLog",value:function(e,t,r){if("string"===typeof e&&(e=this.getEvent(e)),null!=r&&!e.anonymous){var n=this.getEventTopic(e);Object(f.isHexString)(r[0],32)&&r[0].toLowerCase()===n||v.throwError("fragment/topic mismatch",p.Logger.errors.INVALID_ARGUMENT,{argument:"topics[0]",expected:n,value:r[0]}),r=r.slice(1)}var a=[],i=[],o=[];e.inputs.forEach((function(e,t){e.indexed?"string"===e.type||"bytes"===e.type||"tuple"===e.baseType||"array"===e.baseType?(a.push(h.g.fromObject({type:"bytes32",name:e.name})),o.push(!0)):(a.push(e),o.push(!1)):(i.push(e),o.push(!1))}));var c=null!=r?this._abiCoder.decode(a,Object(f.concat)(r)):null,s=this._abiCoder.decode(i,t,!0),d=[],u=0,l=0;e.inputs.forEach((function(e,t){if(e.indexed)if(null==c)d[t]=new y({_isIndexed:!0,hash:null});else if(o[t])d[t]=new y({_isIndexed:!0,hash:c[l++]});else try{d[t]=c[l++]}catch(n){d[t]=n}else try{d[t]=s[u++]}catch(n){d[t]=n}if(e.name&&null==d[e.name]){var r=d[t];r instanceof Error?Object.defineProperty(d,e.name,{get:function(){throw k("property ".concat(JSON.stringify(e.name)),r)}}):d[e.name]=r}}));for(var b=function(e){var t=d[e];t instanceof Error&&Object.defineProperty(d,e,{get:function(){throw k("index ".concat(e),t)}})},m=0;m256)throw new Error("invalid number type - "+t);return i&&(u=256),r=n.a.from(r).toTwos(u),Object(a.zeroPad)(r,u/8)}if(o=t.match(s)){var l=parseInt(o[1]);if(String(l)!==o[1]||0===l||l>32)throw new Error("invalid bytes type - "+t);if(Object(a.arrayify)(r).byteLength!==l)throw new Error("invalid value for "+t);return i?Object(a.arrayify)((r+"0000000000000000000000000000000000000000000000000000000000000000").substring(0,66)):r}if((o=t.match(d))&&Array.isArray(r)){var b=o[1];if(parseInt(o[2]||String(r.length))!=r.length)throw new Error("invalid value for "+t);var h=[];return r.forEach((function(t){h.push(e(b,t,!0))})),Object(a.concat)(h)}throw new Error("invalid type - "+t)}(e,t[i]))})),Object(a.hexlify)(Object(a.concat)(r))}function l(e,t){return Object(i.keccak256)(u(e,t))}function b(e,t){return Object(o.c)(u(e,t))}},function(e,t,r){"use strict";var n=r(88),a=r(87),i=r(117);Object.defineProperty(t,"__esModule",{value:!0});var o=r(134),c=r(250),s=n((function e(t,r,n,i){a(this,e),this.code=t,this.size=r,this.digest=n,this.bytes=i}));t.Digest=s,t.create=function(e,t){var r=t.byteLength,n=c.encodingLength(e),a=n+c.encodingLength(r),i=new Uint8Array(a+r);return c.encodeTo(e,i,0),c.encodeTo(r,i,n),i.set(t,a),new s(e,r,t,i)},t.decode=function(e){var t=o.coerce(e),r=c.decode(t),n=i(r,2),a=n[0],f=n[1],d=c.decode(t.subarray(f)),u=i(d,2),l=u[0],b=u[1],h=t.subarray(f+b);if(h.byteLength!==l)throw new Error("Incorrect length");return new s(a,l,h,t)},t.equals=function(e,t){return e===t||e.code===t.code&&e.size===t.size&&o.equals(e.bytes,t.bytes)}},function(e,t){e.exports=function(e,t){return e===t||e!==e&&t!==t}},function(e,t,r){var n=r(108).Symbol;e.exports=n},function(e,t,r){"use strict";r.r(t);var n=r(128);r.d(t,"id",(function(){return n.a}));var a=r(326);r.d(t,"namehash",(function(){return a.b})),r.d(t,"isValidName",(function(){return a.a}));var i=r(328);r.d(t,"messagePrefix",(function(){return i.b})),r.d(t,"hashMessage",(function(){return i.a}));var o=r(480);r.d(t,"_TypedDataEncoder",(function(){return o.a}))},function(e,t,r){"use strict";r.d(t,"a",(function(){return L})),r.d(t,"b",(function(){return I}));var n=r(6),a=r(7),i=r(10),o=r(15),c=r(16),s=r(110),f=r(58),d=r(13),u=r(14),l=r(53),b=function(e){Object(d.a)(r,e);var t=Object(u.a)(r);function r(e){return Object(n.a)(this,r),t.call(this,"address","address",e,!1)}return Object(a.a)(r,[{key:"defaultValue",value:function(){return"0x0000000000000000000000000000000000000000"}},{key:"encode",value:function(e,t){try{Object(l.getAddress)(t)}catch(r){this._throwError(r.message,t)}return e.writeValue(t)}},{key:"decode",value:function(e){return Object(l.getAddress)(Object(i.hexZeroPad)(e.readValue().toHexString(),20))}}]),r}(f.a),h=function(e){Object(d.a)(r,e);var t=Object(u.a)(r);function r(e){var a;return Object(n.a)(this,r),(a=t.call(this,e.name,e.type,void 0,e.dynamic)).coder=e,a}return Object(a.a)(r,[{key:"defaultValue",value:function(){return this.coder.defaultValue()}},{key:"encode",value:function(e,t){return this.coder.encode(e,t)}},{key:"decode",value:function(e){return this.coder.decode(e)}}]),r}(f.a),p=new c.Logger(s.a);function m(e,t,r){var n=null;if(Array.isArray(r))n=r;else if(r&&"object"===typeof r){var a={};n=t.map((function(e){var t=e.localName;return t||p.throwError("cannot encode object for signature with missing names",c.Logger.errors.INVALID_ARGUMENT,{argument:"values",coder:e,value:r}),a[t]&&p.throwError("cannot encode object for signature with duplicate names",c.Logger.errors.INVALID_ARGUMENT,{argument:"values",coder:e,value:r}),a[t]=!0,r[t]}))}else p.throwArgumentError("invalid tuple value","tuple",r);t.length!==n.length&&p.throwArgumentError("types/value length mismatch","tuple",r);var i=new f.c(e.wordSize),o=new f.c(e.wordSize),s=[];t.forEach((function(e,t){var r=n[t];if(e.dynamic){var a=o.length;e.encode(o,r);var c=i.writeUpdatableValue();s.push((function(e){c(e+a)}))}else e.encode(i,r)})),s.forEach((function(e){e(i.length)}));var d=e.appendWriter(i);return d+=e.appendWriter(o)}function v(e,t){var r=[],n=e.subReader(0);t.forEach((function(t){var a=null;if(t.dynamic){var i=e.readValue(),o=n.subReader(i.toNumber());try{a=t.decode(o)}catch(s){if(s.code===c.Logger.errors.BUFFER_OVERRUN)throw s;(a=s).baseType=t.name,a.name=t.localName,a.type=t.type}}else try{a=t.decode(e)}catch(s){if(s.code===c.Logger.errors.BUFFER_OVERRUN)throw s;(a=s).baseType=t.name,a.name=t.localName,a.type=t.type}void 0!=a&&r.push(a)}));var a=t.reduce((function(e,t){var r=t.localName;return r&&(e[r]||(e[r]=0),e[r]++),e}),{});t.forEach((function(e,t){var n=e.localName;if(n&&1===a[n]&&("length"===n&&(n="_length"),null==r[n])){var i=r[t];i instanceof Error?Object.defineProperty(r,n,{get:function(){throw i}}):r[n]=i}}));for(var i=function(e){var t=r[e];t instanceof Error&&Object.defineProperty(r,e,{get:function(){throw t}})},o=0;o=0?a:"")+"]",s=-1===a||e.dynamic;return(o=t.call(this,"array",c,i,s)).coder=e,o.length=a,o}return Object(a.a)(r,[{key:"defaultValue",value:function(){for(var e=this.coder.defaultValue(),t=[],r=0;re._data.length&&p.throwError("insufficient data length",c.Logger.errors.BUFFER_OVERRUN,{length:e._data.length,count:t});for(var r=[],n=0;n256||n%8!==0)&&R.throwArgumentError("invalid "+r[1]+" bit length","param",e),new A(n/8,"int"===r[1],e.name)}if(r=e.type.match(N)){var a=parseInt(r[1]);return(0===a||a>32)&&R.throwArgumentError("invalid bytes length","param",e),new M(a,e.name)}return R.throwArgumentError("invalid type","type",e.type)}},{key:"_getWordSize",value:function(){return 32}},{key:"_getReader",value:function(e,t){return new f.b(e,this._getWordSize(),this.coerceFunc,t)}},{key:"_getWriter",value:function(){return new f.c(this._getWordSize())}},{key:"getDefaultValue",value:function(e){var t=this,r=e.map((function(e){return t._getCoder(C.g.from(e))}));return new P(r,"_").defaultValue()}},{key:"encode",value:function(e,t){var r=this;e.length!==t.length&&R.throwError("types/values length mismatch",c.Logger.errors.INVALID_ARGUMENT,{count:{types:e.length,values:t.length},value:{types:e,values:t}});var n=e.map((function(e){return r._getCoder(C.g.from(e))})),a=new P(n,"_"),i=this._getWriter();return a.encode(i,t),i.data}},{key:"decode",value:function(e,t,r){var n=this,a=e.map((function(e){return n._getCoder(C.g.from(e))}));return new P(a,"_").decode(this._getReader(Object(i.arrayify)(t),r))}}]),e}(),I=new L},,,,function(e,t,r){"use strict";r.d(t,"a",(function(){return we}));var n=r(140),a=r(6),i=r(7),o=r(20),c=r(13),s=r(14),f=r(9),d=r(79),u=r(2),l=r.n(u),b=r(36),h=r(32),p=r(46),m=r(102),v=r(11),g=r(52),x=null;try{if(null==(x=WebSocket))throw new Error("inject please")}catch(ke){var y=new v.a(g.a);x=function(){y.throwError("WebSockets not supported in this environment",v.a.errors.UNSUPPORTED_OPERATION,{operation:"new WebSocket()"})}}var w=function(e,t,r,n){return new(r||(r=Promise))((function(a,i){function o(e){try{s(n.next(e))}catch(t){i(t)}}function c(e){try{s(n.throw(e))}catch(t){i(t)}}function s(e){var t;e.done?a(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(o,c)}s((n=n.apply(e,t||[])).next())}))},k=new v.a(g.a),_=1,M=function(e){Object(c.a)(r,e);var t=Object(s.a)(r);function r(e,n){var i,c;Object(a.a)(this,r),"any"===n&&k.throwError("WebSocketProvider does not support 'any' network yet",v.a.errors.UNSUPPORTED_OPERATION,{operation:"network:any"}),(c=t.call(this,e,n))._pollingInterval=-1,c._wsReady=!1,Object(f.d)(Object(o.a)(c),"_websocket",new x(c.connection.url)),Object(f.d)(Object(o.a)(c),"_requests",{}),Object(f.d)(Object(o.a)(c),"_subs",{}),Object(f.d)(Object(o.a)(c),"_subIds",{}),Object(f.d)(Object(o.a)(c),"_detectNetwork",Object(b.a)((i=Object(o.a)(c),Object(h.a)(r.prototype)),"detectNetwork",i).call(i)),c._websocket.onopen=function(){c._wsReady=!0,Object.keys(c._requests).forEach((function(e){c._websocket.send(c._requests[e].payload)}))},c._websocket.onmessage=function(e){var t=e.data,r=JSON.parse(t);if(null!=r.id){var n=String(r.id),a=c._requests[n];if(delete c._requests[n],void 0!==r.result)a.callback(null,r.result),c.emit("debug",{action:"response",request:JSON.parse(a.payload),response:r.result,provider:Object(o.a)(c)});else{var i=null;r.error?(i=new Error(r.error.message||"unknown error"),Object(f.d)(i,"code",r.error.code||null),Object(f.d)(i,"response",t)):i=new Error("unknown error"),a.callback(i,void 0),c.emit("debug",{action:"response",error:i,request:JSON.parse(a.payload),provider:Object(o.a)(c)})}}else if("eth_subscription"===r.method){var s=c._subs[r.params.subscription];s&&s.processFunc(r.params.result)}else console.warn("this should not happen")};var s=setInterval((function(){c.emit("poll")}),1e3);return s.unref&&s.unref(),c}return Object(i.a)(r,[{key:"detectNetwork",value:function(){return this._detectNetwork}},{key:"pollingInterval",get:function(){return 0},set:function(e){k.throwError("cannot set polling interval on WebSocketProvider",v.a.errors.UNSUPPORTED_OPERATION,{operation:"setPollingInterval"})}},{key:"resetEventsBlock",value:function(e){k.throwError("cannot reset events block on WebSocketProvider",v.a.errors.UNSUPPORTED_OPERATION,{operation:"resetEventBlock"})}},{key:"poll",value:function(){return w(this,void 0,void 0,l.a.mark((function e(){return l.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",null);case 1:case"end":return e.stop()}}),e)})))}},{key:"polling",set:function(e){e&&k.throwError("cannot set polling on WebSocketProvider",v.a.errors.UNSUPPORTED_OPERATION,{operation:"setPolling"})}},{key:"send",value:function(e,t){var r=this,n=_++;return new Promise((function(a,i){var o=JSON.stringify({method:e,params:t,id:n,jsonrpc:"2.0"});r.emit("debug",{action:"request",request:JSON.parse(o),provider:r}),r._requests[String(n)]={callback:function(e,t){return e?i(e):a(t)},payload:o},r._wsReady&&r._websocket.send(o)}))}},{key:"_subscribe",value:function(e,t,r){return w(this,void 0,void 0,l.a.mark((function n(){var a,i,o=this;return l.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return null==(a=this._subIds[e])&&(a=Promise.all(t).then((function(e){return o.send("eth_subscribe",e)})),this._subIds[e]=a),n.next=4,a;case 4:i=n.sent,this._subs[i]={tag:e,processFunc:r};case 6:case"end":return n.stop()}}),n,this)})))}},{key:"_startEvent",value:function(e){var t=this;switch(e.type){case"block":this._subscribe("block",["newHeads"],(function(e){var r=p.a.from(e.number).toNumber();t._emitted.block=r,t.emit("block",r)}));break;case"pending":this._subscribe("pending",["newPendingTransactions"],(function(e){t.emit("pending",e)}));break;case"filter":this._subscribe(e.tag,["logs",this._getFilter(e.filter)],(function(r){null==r.removed&&(r.removed=!1),t.emit(e.filter,t.formatter.filterLog(r))}));break;case"tx":var r=function(e){var r=e.hash;t.getTransactionReceipt(r).then((function(e){e&&t.emit(r,e)}))};r(e),this._subscribe("tx",["newHeads"],(function(e){t._events.filter((function(e){return"tx"===e.type})).forEach(r)}));break;case"debug":case"poll":case"willPoll":case"didPoll":case"error":break;default:console.log("unhandled:",e)}}},{key:"_stopEvent",value:function(e){var t=this,r=e.tag;if("tx"===e.type){if(this._events.filter((function(e){return"tx"===e.type})).length)return;r="tx"}else if(this.listenerCount(e.event))return;var n=this._subIds[r];n&&(delete this._subIds[r],n.then((function(e){t._subs[e]&&(delete t._subs[e],t.send("eth_unsubscribe",[e]))})))}},{key:"destroy",value:function(){return w(this,void 0,void 0,l.a.mark((function e(){var t=this;return l.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(this._websocket.readyState!==x.CONNECTING){e.next=3;break}return e.next=3,new Promise((function(e){t._websocket.onopen=function(){e(!0)},t._websocket.onerror=function(){e(!1)}}));case 3:this._websocket.close(1e3);case 4:case"end":return e.stop()}}),e,this)})))}}],[{key:"defaultUrl",value:function(){return"ws://localhost:8546"}}]),r}(m.a),S=function(e,t,r,n){return new(r||(r=Promise))((function(a,i){function o(e){try{s(n.next(e))}catch(t){i(t)}}function c(e){try{s(n.throw(e))}catch(t){i(t)}}function s(e){var t;e.done?a(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(o,c)}s((n=n.apply(e,t||[])).next())}))},E=new v.a(g.a),O=function(e){Object(c.a)(r,e);var t=Object(s.a)(r);function r(e,n){var i;Object(a.a)(this,r),E.checkAbstract(this instanceof r?this.constructor:void 0,r),e=Object(f.e)(this instanceof r?this.constructor:void 0,"getNetwork")(e),n=Object(f.e)(this instanceof r?this.constructor:void 0,"getApiKey")(n);var c=Object(f.e)(this instanceof r?this.constructor:void 0,"getUrl")(e,n);return i=t.call(this,c,e),"string"===typeof n?Object(f.d)(Object(o.a)(i),"apiKey",n):null!=n&&Object.keys(n).forEach((function(e){Object(f.d)(Object(o.a)(i),e,n[e])})),i}return Object(i.a)(r,[{key:"_startPending",value:function(){E.warn("WARNING: API provider does not support pending filters")}},{key:"isCommunityResource",value:function(){return!1}},{key:"getSigner",value:function(e){return E.throwError("API provider does not support signing",v.a.errors.UNSUPPORTED_OPERATION,{operation:"getSigner"})}},{key:"listAccounts",value:function(){return Promise.resolve([])}}],[{key:"getApiKey",value:function(e){return e}},{key:"getUrl",value:function(e,t){return E.throwError("not implemented; sub-classes must override getUrl",v.a.errors.NOT_IMPLEMENTED,{operation:"getUrl"})}}]),r}(function(e){Object(c.a)(r,e);var t=Object(s.a)(r);function r(){return Object(a.a)(this,r),t.apply(this,arguments)}return Object(i.a)(r,[{key:"detectNetwork",value:function(){var e=this,t=Object.create(null,{detectNetwork:{get:function(){return Object(b.a)(Object(h.a)(r.prototype),"detectNetwork",e)}}});return S(this,void 0,void 0,l.a.mark((function e(){var r;return l.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(null!=(r=this.network)){e.next=7;break}return e.next=4,t.detectNetwork.call(this);case 4:(r=e.sent)||E.throwError("no network detected",v.a.errors.UNKNOWN_ERROR,{}),null==this._network&&(Object(f.d)(this,"_network",r),this.emit("network",r,null));case 7:return e.abrupt("return",r);case 8:case"end":return e.stop()}}),e,this)})))}}]),r}(m.a)),A=new v.a(g.a),T="_gg7wSSi0KMBsdKnGVfHDueq6xMB9EkC",j=function(e){Object(c.a)(r,e);var t=Object(s.a)(r);function r(e,n){var i;Object(a.a)(this,r);var c=new P(e,n),s=c.connection.url.replace(/^http/i,"ws").replace(".alchemyapi.",".ws.alchemyapi.");return i=t.call(this,s,c.network),Object(f.d)(Object(o.a)(i),"apiKey",c.apiKey),i}return Object(i.a)(r,[{key:"isCommunityResource",value:function(){return this.apiKey===T}}]),r}(M),P=function(e){Object(c.a)(r,e);var t=Object(s.a)(r);function r(){return Object(a.a)(this,r),t.apply(this,arguments)}return Object(i.a)(r,[{key:"isCommunityResource",value:function(){return this.apiKey===T}}],[{key:"getWebSocketProvider",value:function(e,t){return new j(e,t)}},{key:"getApiKey",value:function(e){return null==e?T:(e&&"string"!==typeof e&&A.throwArgumentError("invalid apiKey","apiKey",e),e)}},{key:"getUrl",value:function(e,t){var r=null;switch(e.name){case"homestead":r="eth-mainnet.alchemyapi.io/v2/";break;case"ropsten":r="eth-ropsten.alchemyapi.io/v2/";break;case"rinkeby":r="eth-rinkeby.alchemyapi.io/v2/";break;case"goerli":r="eth-goerli.alchemyapi.io/v2/";break;case"kovan":r="eth-kovan.alchemyapi.io/v2/";break;case"matic":r="polygon-mainnet.g.alchemy.com/v2/";break;case"maticmum":r="polygon-mumbai.g.alchemy.com/v2/";break;case"arbitrum":r="arb-mainnet.g.alchemy.com/v2/";break;case"arbitrum-rinkeby":r="arb-rinkeby.g.alchemy.com/v2/";break;case"optimism":r="opt-mainnet.g.alchemy.com/v2/";break;case"optimism-kovan":r="opt-kovan.g.alchemy.com/v2/";break;default:A.throwArgumentError("unsupported network","network",arguments[0])}return{allowGzip:!0,url:"https://"+r+t,throttleCallback:function(e,r){return t===T&&Object(d.c)(),Promise.resolve(!0)}}}}]),r}(O),C=function(e,t,r,n){return new(r||(r=Promise))((function(a,i){function o(e){try{s(n.next(e))}catch(t){i(t)}}function c(e){try{s(n.throw(e))}catch(t){i(t)}}function s(e){var t;e.done?a(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(o,c)}s((n=n.apply(e,t||[])).next())}))},R=new v.a(g.a),N=function(e){Object(c.a)(r,e);var t=Object(s.a)(r);function r(){return Object(a.a)(this,r),t.apply(this,arguments)}return Object(i.a)(r,[{key:"perform",value:function(e,t){var n=this,a=Object.create(null,{perform:{get:function(){return Object(b.a)(Object(h.a)(r.prototype),"perform",n)}}});return C(this,void 0,void 0,l.a.mark((function r(){var n;return l.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if("getBlockNumber"!==e){r.next=5;break}return r.next=3,a.perform.call(this,"getBlock",{blockTag:"latest"});case 3:return n=r.sent,r.abrupt("return",n.number);case 5:return r.abrupt("return",a.perform.call(this,e,t));case 6:case"end":return r.stop()}}),r,this)})))}}],[{key:"getApiKey",value:function(e){return null!=e&&R.throwArgumentError("apiKey not supported for cloudflare","apiKey",e),null}},{key:"getUrl",value:function(e,t){var r=null;switch(e.name){case"homestead":r="https://cloudflare-eth.com/";break;default:R.throwArgumentError("unsupported network","network",arguments[0])}return r}}]),r}(O),B=r(5),L=r(66),I=r(89),F=r(125),D=function(e,t,r,n){return new(r||(r=Promise))((function(a,i){function o(e){try{s(n.next(e))}catch(t){i(t)}}function c(e){try{s(n.throw(e))}catch(t){i(t)}}function s(e){var t;e.done?a(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(o,c)}s((n=n.apply(e,t||[])).next())}))},U=new v.a(g.a);function z(e){var t={};for(var r in e)if(null!=e[r]){var n=e[r];"type"===r&&0===n||(n={type:!0,gasLimit:!0,gasPrice:!0,maxFeePerGs:!0,maxPriorityFeePerGas:!0,nonce:!0,value:!0}[r]?Object(B.f)(Object(B.h)(n)):"accessList"===r?"["+Object(L.accessListify)(n).map((function(e){return'{address:"'.concat(e.address,'",storageKeys:["').concat(e.storageKeys.join('","'),'"]}')})).join(",")+"]":Object(B.h)(n),t[r]=n)}return t}function H(e){if(0==e.status&&("No records found"===e.message||"No transactions found"===e.message))return e.result;if(1!=e.status||"OK"!=e.message){var t=new Error("invalid response");throw t.result=JSON.stringify(e),(e.result||"").toLowerCase().indexOf("rate limit")>=0&&(t.throttleRetry=!0),t}return e.result}function q(e){if(e&&0==e.status&&"NOTOK"==e.message&&(e.result||"").toLowerCase().indexOf("rate limit")>=0){var t=new Error("throttled response");throw t.result=JSON.stringify(e),t.throttleRetry=!0,t}if("2.0"!=e.jsonrpc){var r=new Error("invalid response");throw r.result=JSON.stringify(e),r}if(e.error){var n=new Error(e.error.message||"unknown error");throw e.error.code&&(n.code=e.error.code),e.error.data&&(n.data=e.error.data),n}return e.result}function J(e){if("pending"===e)throw new Error("pending not supported");return"latest"===e?e:parseInt(e.substring(2),16)}function V(e,t,r){if("call"===e&&t.code===v.a.errors.SERVER_ERROR){var n=t.error;if(n&&(n.message.match(/reverted/i)||n.message.match(/VM execution error/i))){var a=n.data;if(a&&(a="0x"+a.replace(/^.*0x/i,"")),Object(B.k)(a))return a;U.throwError("missing revert data in call exception",v.a.errors.CALL_EXCEPTION,{error:t,data:"0x"})}}var i=t.message;throw t.code===v.a.errors.SERVER_ERROR&&(t.error&&"string"===typeof t.error.message?i=t.error.message:"string"===typeof t.body?i=t.body:"string"===typeof t.responseText&&(i=t.responseText)),(i=(i||"").toLowerCase()).match(/insufficient funds/)&&U.throwError("insufficient funds for intrinsic transaction cost",v.a.errors.INSUFFICIENT_FUNDS,{error:t,method:e,transaction:r}),i.match(/same hash was already imported|transaction nonce is too low|nonce too low/)&&U.throwError("nonce has already been used",v.a.errors.NONCE_EXPIRED,{error:t,method:e,transaction:r}),i.match(/another transaction with same nonce/)&&U.throwError("replacement fee too low",v.a.errors.REPLACEMENT_UNDERPRICED,{error:t,method:e,transaction:r}),i.match(/execution failed due to an exception|execution reverted/)&&U.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",v.a.errors.UNPREDICTABLE_GAS_LIMIT,{error:t,method:e,transaction:r}),t}var G=function(e){Object(c.a)(r,e);var t=Object(s.a)(r);function r(e,n){var i;return Object(a.a)(this,r),U.checkNew(this instanceof r?this.constructor:void 0,r),i=t.call(this,e),Object(f.d)(Object(o.a)(i),"baseUrl",i.getBaseUrl()),Object(f.d)(Object(o.a)(i),"apiKey",n||"9D13ZE7XSBTJ94N9BNJ2MA33VMAY2YPIRB"),i}return Object(i.a)(r,[{key:"getBaseUrl",value:function(){switch(this.network?this.network.name:"invalid"){case"homestead":return"https://api.etherscan.io";case"ropsten":return"https://api-ropsten.etherscan.io";case"rinkeby":return"https://api-rinkeby.etherscan.io";case"kovan":return"https://api-kovan.etherscan.io";case"goerli":return"https://api-goerli.etherscan.io"}return U.throwArgumentError("unsupported network","network",name)}},{key:"getUrl",value:function(e,t){var r=Object.keys(t).reduce((function(e,r){var n=t[r];return null!=n&&(e+="&".concat(r,"=").concat(n)),e}),""),n=this.apiKey?"&apikey=".concat(this.apiKey):"";return"".concat(this.baseUrl,"/api?module=").concat(e).concat(r).concat(n)}},{key:"getPostUrl",value:function(){return"".concat(this.baseUrl,"/api")}},{key:"getPostData",value:function(e,t){return t.module=e,t.apikey=this.apiKey,t}},{key:"fetch",value:function(e,t,r){return D(this,void 0,void 0,l.a.mark((function n(){var a,i,o,c,s,u,b=this;return l.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return a=r?this.getPostUrl():this.getUrl(e,t),i=r?this.getPostData(e,t):null,o="proxy"===e?q:H,this.emit("debug",{action:"request",request:a,provider:this}),c={url:a,throttleSlotInterval:1e3,throttleCallback:function(e,t){return b.isCommunityResource()&&Object(d.c)(),Promise.resolve(!0)}},s=null,i&&(c.headers={"content-type":"application/x-www-form-urlencoded; charset=UTF-8"},s=Object.keys(i).map((function(e){return"".concat(e,"=").concat(i[e])})).join("&")),n.next=9,Object(I.a)(c,s,o||q);case 9:return u=n.sent,this.emit("debug",{action:"response",request:a,response:Object(f.c)(u),provider:this}),n.abrupt("return",u);case 12:case"end":return n.stop()}}),n,this)})))}},{key:"detectNetwork",value:function(){return D(this,void 0,void 0,l.a.mark((function e(){return l.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",this.network);case 1:case"end":return e.stop()}}),e,this)})))}},{key:"perform",value:function(e,t){var n=this,a=Object.create(null,{perform:{get:function(){return Object(b.a)(Object(h.a)(r.prototype),"perform",n)}}});return D(this,void 0,void 0,l.a.mark((function r(){var n,i,o,c,s,f,d,u,b;return l.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:r.t0=e,r.next="getBlockNumber"===r.t0?3:"getGasPrice"===r.t0?4:"getBalance"===r.t0?5:"getTransactionCount"===r.t0?6:"getCode"===r.t0?7:"getStorageAt"===r.t0?8:"sendTransaction"===r.t0?9:"getBlock"===r.t0?10:"getTransaction"===r.t0?13:"getTransactionReceipt"===r.t0?14:"call"===r.t0?15:"estimateGas"===r.t0?29:"getLogs"===r.t0?41:"getEtherPrice"===r.t0?65:72;break;case 3:return r.abrupt("return",this.fetch("proxy",{action:"eth_blockNumber"}));case 4:return r.abrupt("return",this.fetch("proxy",{action:"eth_gasPrice"}));case 5:return r.abrupt("return",this.fetch("account",{action:"balance",address:t.address,tag:t.blockTag}));case 6:return r.abrupt("return",this.fetch("proxy",{action:"eth_getTransactionCount",address:t.address,tag:t.blockTag}));case 7:return r.abrupt("return",this.fetch("proxy",{action:"eth_getCode",address:t.address,tag:t.blockTag}));case 8:return r.abrupt("return",this.fetch("proxy",{action:"eth_getStorageAt",address:t.address,position:t.position,tag:t.blockTag}));case 9:return r.abrupt("return",this.fetch("proxy",{action:"eth_sendRawTransaction",hex:t.signedTransaction},!0).catch((function(e){return V("sendTransaction",e,t.signedTransaction)})));case 10:if(!t.blockTag){r.next=12;break}return r.abrupt("return",this.fetch("proxy",{action:"eth_getBlockByNumber",tag:t.blockTag,boolean:t.includeTransactions?"true":"false"}));case 12:throw new Error("getBlock by blockHash not implemented");case 13:return r.abrupt("return",this.fetch("proxy",{action:"eth_getTransactionByHash",txhash:t.transactionHash}));case 14:return r.abrupt("return",this.fetch("proxy",{action:"eth_getTransactionReceipt",txhash:t.transactionHash}));case 15:if("latest"===t.blockTag){r.next=17;break}throw new Error("EtherscanProvider does not support blockTag for call");case 17:return(n=z(t.transaction)).module="proxy",n.action="eth_call",r.prev=20,r.next=23,this.fetch("proxy",n,!0);case 23:return r.abrupt("return",r.sent);case 26:return r.prev=26,r.t1=r.catch(20),r.abrupt("return",V("call",r.t1,t.transaction));case 29:return(i=z(t.transaction)).module="proxy",i.action="eth_estimateGas",r.prev=32,r.next=35,this.fetch("proxy",i,!0);case 35:return r.abrupt("return",r.sent);case 38:return r.prev=38,r.t2=r.catch(32),r.abrupt("return",V("estimateGas",r.t2,t.transaction));case 41:return o={action:"getLogs"},t.filter.fromBlock&&(o.fromBlock=J(t.filter.fromBlock)),t.filter.toBlock&&(o.toBlock=J(t.filter.toBlock)),t.filter.address&&(o.address=t.filter.address),t.filter.topics&&t.filter.topics.length>0&&(t.filter.topics.length>1&&U.throwError("unsupported topic count",v.a.errors.UNSUPPORTED_OPERATION,{topics:t.filter.topics}),1===t.filter.topics.length&&("string"===typeof(c=t.filter.topics[0])&&66===c.length||U.throwError("unsupported topic format",v.a.errors.UNSUPPORTED_OPERATION,{topic0:c}),o.topic0=c)),r.next=48,this.fetch("logs",o);case 48:s=r.sent,f={},d=0;case 51:if(!(d0;t--){var r=Math.floor(Math.random()*(t+1)),n=e[t];e[t]=e[r],e[r]=n}return e}var W=function(e,t,r,n){return new(r||(r=Promise))((function(a,i){function o(e){try{s(n.next(e))}catch(t){i(t)}}function c(e){try{s(n.throw(e))}catch(t){i(t)}}function s(e){var t;e.done?a(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(o,c)}s((n=n.apply(e,t||[])).next())}))},Z=new v.a(g.a);function $(){return(new Date).getTime()}function Q(e){for(var t=null,r=0;rt?null:(n+a)/2}function ee(e){if(null===e)return"null";if("number"===typeof e||"boolean"===typeof e)return JSON.stringify(e);if("string"===typeof e)return e;if(p.a.isBigNumber(e))return e.toString();if(Array.isArray(e))return JSON.stringify(e.map((function(e){return ee(e)})));if("object"===typeof e){var t=Object.keys(e);return t.sort(),"{"+t.map((function(t){var r=e[t];return r="function"===typeof r?"[function]":ee(r),JSON.stringify(t)+":"+r})).join(",")+"}"}throw new Error("unknown value type: "+typeof e)}var te=1;function re(e){var t=null,r=null,n=new Promise((function(n){t=function(){r&&(clearTimeout(r),r=null),n()},r=setTimeout(t,e)}));return{cancel:t,getPromise:function(){return n},wait:function(e){return n=n.then(e)}}}var ne=[v.a.errors.CALL_EXCEPTION,v.a.errors.INSUFFICIENT_FUNDS,v.a.errors.NONCE_EXPIRED,v.a.errors.REPLACEMENT_UNDERPRICED,v.a.errors.UNPREDICTABLE_GAS_LIMIT],ae=["address","args","errorArgs","errorSignature","method","transaction"];function ie(e,t){var r={weight:e.weight};return Object.defineProperty(r,"provider",{get:function(){return e.provider}}),e.start&&(r.start=e.start),t&&(r.duration=t-e.start),e.done&&(e.error?r.error=e.error:r.result=e.result||null),r}function oe(e,t,r){var n=ee;switch(t){case"getBlockNumber":return function(t){var r=t.map((function(e){return e.result})),n=Y(t.map((function(e){return e.result})),2);if(null!=n)return n=Math.ceil(n),r.indexOf(n+1)>=0&&n++,n>=e._highestBlockNumber&&(e._highestBlockNumber=n),e._highestBlockNumber};case"getGasPrice":return function(e){var t=e.map((function(e){return e.result}));return t.sort(),t[Math.floor(t.length/2)]};case"getEtherPrice":return function(e){return Y(e.map((function(e){return e.result})))};case"getBalance":case"getTransactionCount":case"getCode":case"getStorageAt":case"call":case"estimateGas":case"getLogs":break;case"getTransaction":case"getTransactionReceipt":n=function(e){return null==e?null:((e=Object(f.g)(e)).confirmations=-1,ee(e))};break;case"getBlock":n=r.includeTransactions?function(e){return null==e?null:((e=Object(f.g)(e)).transactions=e.transactions.map((function(e){return(e=Object(f.g)(e)).confirmations=-1,e})),ee(e))}:function(e){return null==e?null:ee(e)};break;default:throw new Error("unknown method: "+t)}return function(e,t){return function(r){var n={};r.forEach((function(t){var r=e(t.result);n[r]||(n[r]={count:0,result:t.result}),n[r].count++}));for(var a=Object.keys(n),i=0;i=t)return o.result}}}(n,e.quorum)}function ce(e,t){return W(this,void 0,void 0,l.a.mark((function r(){var n;return l.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if(!(null!=(n=e.provider).blockNumber&&n.blockNumber>=t||-1===t)){r.next=3;break}return r.abrupt("return",n);case 3:return r.abrupt("return",Object(I.b)((function(){return new Promise((function(r,a){setTimeout((function(){return n.blockNumber>=t?r(n):e.cancelled?r(null):r(void 0)}),0)}))}),{oncePoll:n}));case 4:case"end":return r.stop()}}),r)})))}function se(e,t,r,n){return W(this,void 0,void 0,l.a.mark((function a(){var i,o;return l.a.wrap((function(a){for(;;)switch(a.prev=a.next){case 0:i=e.provider,a.t0=r,a.next="getBlockNumber"===a.t0||"getGasPrice"===a.t0?4:"getEtherPrice"===a.t0?5:"getBalance"===a.t0||"getTransactionCount"===a.t0||"getCode"===a.t0?8:"getStorageAt"===a.t0?13:"getBlock"===a.t0?18:"call"===a.t0||"estimateGas"===a.t0?23:"getTransaction"===a.t0||"getTransactionReceipt"===a.t0?28:"getLogs"===a.t0?29:35;break;case 4:return a.abrupt("return",i[r]());case 5:if(!i.getEtherPrice){a.next=7;break}return a.abrupt("return",i.getEtherPrice());case 7:return a.abrupt("break",35);case 8:if(!n.blockTag||!Object(B.k)(n.blockTag)){a.next=12;break}return a.next=11,ce(e,t);case 11:i=a.sent;case 12:return a.abrupt("return",i[r](n.address,n.blockTag||"latest"));case 13:if(!n.blockTag||!Object(B.k)(n.blockTag)){a.next=17;break}return a.next=16,ce(e,t);case 16:i=a.sent;case 17:return a.abrupt("return",i.getStorageAt(n.address,n.position,n.blockTag||"latest"));case 18:if(!n.blockTag||!Object(B.k)(n.blockTag)){a.next=22;break}return a.next=21,ce(e,t);case 21:i=a.sent;case 22:return a.abrupt("return",i[n.includeTransactions?"getBlockWithTransactions":"getBlock"](n.blockTag||n.blockHash));case 23:if(!n.blockTag||!Object(B.k)(n.blockTag)){a.next=27;break}return a.next=26,ce(e,t);case 26:i=a.sent;case 27:return a.abrupt("return",i[r](n.transaction));case 28:return a.abrupt("return",i[r](n.transactionHash));case 29:if(!((o=n.filter).fromBlock&&Object(B.k)(o.fromBlock)||o.toBlock&&Object(B.k)(o.toBlock))){a.next=34;break}return a.next=33,ce(e,t);case 33:i=a.sent;case 34:return a.abrupt("return",i.getLogs(o));case 35:return a.abrupt("return",Z.throwError("unknown method error",v.a.errors.UNKNOWN_ERROR,{method:r,params:n}));case 36:case"end":return a.stop()}}),a)})))}var fe=function(e){Object(c.a)(r,e);var t=Object(s.a)(r);function r(e,n){var i;Object(a.a)(this,r),Z.checkNew(this instanceof r?this.constructor:void 0,r),0===e.length&&Z.throwArgumentError("missing providers","providers",e);var c=e.map((function(e,t){if(X.b.isProvider(e)){var r=Object(d.b)(e)?2e3:750;return Object.freeze({provider:e,weight:1,stallTimeout:r,priority:1})}var n=Object(f.g)(e);null==n.priority&&(n.priority=1),null==n.stallTimeout&&(n.stallTimeout=Object(d.b)(e)?2e3:750),null==n.weight&&(n.weight=1);var a=n.weight;return(a%1||a>512||a<1)&&Z.throwArgumentError("invalid weight; must be integer in [1, 512]","providers[".concat(t,"].weight"),a),Object.freeze(n)})),s=c.reduce((function(e,t){return e+t.weight}),0);null==n?n=s/2:n>s&&Z.throwArgumentError("quorum will always fail; larger than total weight","quorum",n);var u=Q(c.map((function(e){return e.provider.network})));return null==u&&(u=new Promise((function(e,t){setTimeout((function(){i.detectNetwork().then(e,t)}),0)}))),i=t.call(this,u),Object(f.d)(Object(o.a)(i),"providerConfigs",Object.freeze(c)),Object(f.d)(Object(o.a)(i),"quorum",n),i._highestBlockNumber=-1,i}return Object(i.a)(r,[{key:"detectNetwork",value:function(){return W(this,void 0,void 0,l.a.mark((function e(){var t;return l.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Promise.all(this.providerConfigs.map((function(e){return e.provider.getNetwork()})));case 2:return t=e.sent,e.abrupt("return",Q(t));case 4:case"end":return e.stop()}}),e,this)})))}},{key:"perform",value:function(e,t){return W(this,void 0,void 0,l.a.mark((function r(){var n,a,i,o,c,s,d,u,b,h,p=this;return l.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if("sendTransaction"!==e){r.next=13;break}return r.next=3,Promise.all(this.providerConfigs.map((function(e){return e.provider.sendTransaction(t.signedTransaction).then((function(e){return e.hash}),(function(e){return e}))})));case 3:n=r.sent,a=0;case 5:if(!(a=p.quorum)){r.next=19;break}if(void 0===(m=o(h))){r.next=15;break}return c.forEach((function(e){e.staller&&e.staller.cancel(),e.cancelled=!0})),r.abrupt("return",{v:m});case 15:if(u){r.next=18;break}return r.next=18,re(100).getPromise();case 18:u=!1;case 19:if(v=c.reduce((function(e,t){if(!t.done||null==t.error)return e;var r=t.error.code;return ne.indexOf(r)>=0&&(e[r]||(e[r]={error:t.error,weight:0}),e[r].weight+=t.weight),e}),{}),Object.keys(v).forEach((function(e){var t=v[e];if(!(t.weighte.length)&&(t=e.length);for(var r=0,n=new Array(t);r0&&s>0)){for(o=s%a||a,d=f.substr(0,o);o0&&(d+=b+f.slice(o)),this.s<0&&(d="-"+d)}return u?((m=r.fractionGroupSeparator)==c&&(m=g.fractionGroupSeparator)==c&&(m=x.fractionGroupSeparator),m&&((v=r.fractionGroupSize)==c&&(v=g.fractionGroupSize)==c&&(v=x.fractionGroupSize)==c&&(v=0),(v=+v)&&(u=u.replace(new RegExp("\\d{"+v+"}\\B","g"),"$&"+m))),d+l+u):d},e.format={decimalSeparator:".",groupSeparator:",",groupSize:3,secondaryGroupSize:0,fractionGroupSeparator:"",fractionGroupSize:0},e})},function(e,t,r){"use strict";(function(t){!function(r){function n(e){var t=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),r=1779033703,n=3144134277,a=1013904242,i=2773480762,o=1359893119,c=2600822924,s=528734635,f=1541459225,d=new Uint32Array(64);function u(e){for(var u=0,l=e.length;l>=64;){var b=r,h=n,p=a,m=i,v=o,g=c,x=s,y=f,w=void 0,k=void 0,_=void 0,M=void 0,S=void 0;for(k=0;k<16;k++)_=u+4*k,d[k]=(255&e[_])<<24|(255&e[_+1])<<16|(255&e[_+2])<<8|255&e[_+3];for(k=16;k<64;k++)M=((w=d[k-2])>>>17|w<<15)^(w>>>19|w<<13)^w>>>10,S=((w=d[k-15])>>>7|w<<25)^(w>>>18|w<<14)^w>>>3,d[k]=(M+d[k-7]|0)+(S+d[k-16]|0)|0;for(k=0;k<64;k++)M=(((v>>>6|v<<26)^(v>>>11|v<<21)^(v>>>25|v<<7))+(v&g^~v&x)|0)+(y+(t[k]+d[k]|0)|0)|0,S=((b>>>2|b<<30)^(b>>>13|b<<19)^(b>>>22|b<<10))+(b&h^b&p^h&p)|0,y=x,x=g,g=v,v=m+M|0,m=p,p=h,h=b,b=M+S|0;r=r+b|0,n=n+h|0,a=a+p|0,i=i+m|0,o=o+v|0,c=c+g|0,s=s+x|0,f=f+y|0,u+=64,l-=64}}u(e);var l,b=e.length%64,h=e.length/536870912|0,p=e.length<<3,m=b<56?56:120,v=e.slice(e.length-b,e.length);for(v.push(128),l=b+1;l>>24&255),v.push(h>>>16&255),v.push(h>>>8&255),v.push(h>>>0&255),v.push(p>>>24&255),v.push(p>>>16&255),v.push(p>>>8&255),v.push(p>>>0&255),u(v),[r>>>24&255,r>>>16&255,r>>>8&255,r>>>0&255,n>>>24&255,n>>>16&255,n>>>8&255,n>>>0&255,a>>>24&255,a>>>16&255,a>>>8&255,a>>>0&255,i>>>24&255,i>>>16&255,i>>>8&255,i>>>0&255,o>>>24&255,o>>>16&255,o>>>8&255,o>>>0&255,c>>>24&255,c>>>16&255,c>>>8&255,c>>>0&255,s>>>24&255,s>>>16&255,s>>>8&255,s>>>0&255,f>>>24&255,f>>>16&255,f>>>8&255,f>>>0&255]}function a(e,t,r){e=e.length<=64?e:n(e);var a,i=64+t.length+4,o=new Array(i),c=new Array(64),s=[];for(a=0;a<64;a++)o[a]=54;for(a=0;a=i-4;e--){if(o[e]++,o[e]<=255)return;o[e]=0}}for(;r>=32;)f(),s=s.concat(n(c.concat(n(o)))),r-=32;return r>0&&(f(),s=s.concat(n(c.concat(n(o))).slice(0,r))),s}function i(e,t,r,n,a){var i;for(f(e,16*(2*r-1),a,0,16),i=0;i<2*r;i++)s(e,16*i,a,16),c(a,n),f(a,0,e,t+16*i,16);for(i=0;i>>32-t}function c(e,t){f(e,0,t,0,16);for(var r=8;r>0;r-=2)t[4]^=o(t[0]+t[12],7),t[8]^=o(t[4]+t[0],9),t[12]^=o(t[8]+t[4],13),t[0]^=o(t[12]+t[8],18),t[9]^=o(t[5]+t[1],7),t[13]^=o(t[9]+t[5],9),t[1]^=o(t[13]+t[9],13),t[5]^=o(t[1]+t[13],18),t[14]^=o(t[10]+t[6],7),t[2]^=o(t[14]+t[10],9),t[6]^=o(t[2]+t[14],13),t[10]^=o(t[6]+t[2],18),t[3]^=o(t[15]+t[11],7),t[7]^=o(t[3]+t[15],9),t[11]^=o(t[7]+t[3],13),t[15]^=o(t[11]+t[7],18),t[1]^=o(t[0]+t[3],7),t[2]^=o(t[1]+t[0],9),t[3]^=o(t[2]+t[1],13),t[0]^=o(t[3]+t[2],18),t[6]^=o(t[5]+t[4],7),t[7]^=o(t[6]+t[5],9),t[4]^=o(t[7]+t[6],13),t[5]^=o(t[4]+t[7],18),t[11]^=o(t[10]+t[9],7),t[8]^=o(t[11]+t[10],9),t[9]^=o(t[8]+t[11],13),t[10]^=o(t[9]+t[8],18),t[12]^=o(t[15]+t[14],7),t[13]^=o(t[12]+t[15],9),t[14]^=o(t[13]+t[12],13),t[15]^=o(t[14]+t[13],18);for(var n=0;n<16;++n)e[n]+=t[n]}function s(e,t,r,n){for(var a=0;a=256)return!1}return!0}function u(e,t){if("number"!==typeof e||e%1)throw new Error("invalid "+t);return e}function l(e,r,n,o,c,l,b){if(n=u(n,"N"),o=u(o,"r"),c=u(c,"p"),l=u(l,"dkLen"),0===n||0!==(n&n-1))throw new Error("N must be power of 2");if(n>2147483647/128/o)throw new Error("N too large");if(o>2147483647/128/c)throw new Error("r too large");if(!d(e))throw new Error("password must be an array or buffer");if(e=Array.prototype.slice.call(e),!d(r))throw new Error("salt must be an array or buffer");r=Array.prototype.slice.call(r);for(var h=a(e,r,128*c*o),p=new Uint32Array(32*c*o),m=0;mP&&(r=P);for(var d=0;dP&&(r=P);for(var m=0;m>0&255),h.push(p[N]>>8&255),h.push(p[N]>>16&255),h.push(p[N]>>24&255);var B=a(e,h,l);return b&&b(null,1,B),B}b&&C(t)};if(!b)for(;;){var N=R();if(void 0!=N)return N}R()}var b={scrypt:function(e,t,r,n,a,i,o){return new Promise((function(c,s){var f=0;o&&o(0),l(e,t,r,n,a,i,(function(e,t,r){if(e)s(e);else if(r)o&&1!==f&&o(1),c(new Uint8Array(r));else if(o&&t!==f)return f=t,o(t)}))}))},syncScrypt:function(e,t,r,n,a,i){return new Uint8Array(l(e,t,r,n,a,i))}};e.exports=b}()}).call(this,r(388).setImmediate)},function(e,t,r){"use strict";var n=r(130),a=r(133),i=r(335),o=r(498),c=r(963),s=c.nameToVarint,f=c.constantToCode,d=c.nameToCode,u=c.codeToName;function l(e){var t=a.decode(e),r=u[t];if(void 0===r)throw new Error('Code "'.concat(t,'" not found'));return r}function b(e){return u[e]}function h(e){var t=d[e];if(void 0===t)throw new Error('Codec "'.concat(e,'" not found'));return t}function p(e){return a.decode(e)}function m(e){var t=s[e];if(void 0===t)throw new Error('Codec "'.concat(e,'" not found'));return t}function v(e){return o.varintEncode(e)}e.exports=n(n({addPrefix:function(e,t){var r;if(e instanceof Uint8Array)r=o.varintUint8ArrayEncode(e);else{if(!s[e])throw new Error("multicodec not recognized");r=s[e]}return i([r,t],r.length+t.length)},rmPrefix:function(e){return a.decode(e),e.slice(a.decode.bytes)},getNameFromData:l,getNameFromCode:b,getCodeFromName:h,getCodeFromData:p,getVarintFromName:m,getVarintFromCode:v,getCodec:function(e){return l(e)},getName:function(e){return b(e)},getNumber:function(e){return h(e)},getCode:function(e){return p(e)},getCodeVarint:function(e){return m(e)},getVarint:function(e){return Array.from(v(e))}},f),{},{nameToVarint:s,nameToCode:d,codeToName:u})},,,,,,,,,,,,,,,function(e,t,r){var n;!function(a){var i=/^\s+/,o=/\s+$/,c=0,s=a.round,f=a.min,d=a.max,u=a.random;function l(e,t){if(t=t||{},(e=e||"")instanceof l)return e;if(!(this instanceof l))return new l(e,t);var r=function(e){var t={r:0,g:0,b:0},r=1,n=null,c=null,s=null,u=!1,l=!1;"string"==typeof e&&(e=function(e){e=e.replace(i,"").replace(o,"").toLowerCase();var t,r=!1;if(j[e])e=j[e],r=!0;else if("transparent"==e)return{r:0,g:0,b:0,a:0,format:"name"};if(t=U.rgb.exec(e))return{r:t[1],g:t[2],b:t[3]};if(t=U.rgba.exec(e))return{r:t[1],g:t[2],b:t[3],a:t[4]};if(t=U.hsl.exec(e))return{h:t[1],s:t[2],l:t[3]};if(t=U.hsla.exec(e))return{h:t[1],s:t[2],l:t[3],a:t[4]};if(t=U.hsv.exec(e))return{h:t[1],s:t[2],v:t[3]};if(t=U.hsva.exec(e))return{h:t[1],s:t[2],v:t[3],a:t[4]};if(t=U.hex8.exec(e))return{r:B(t[1]),g:B(t[2]),b:B(t[3]),a:D(t[4]),format:r?"name":"hex8"};if(t=U.hex6.exec(e))return{r:B(t[1]),g:B(t[2]),b:B(t[3]),format:r?"name":"hex"};if(t=U.hex4.exec(e))return{r:B(t[1]+""+t[1]),g:B(t[2]+""+t[2]),b:B(t[3]+""+t[3]),a:D(t[4]+""+t[4]),format:r?"name":"hex8"};if(t=U.hex3.exec(e))return{r:B(t[1]+""+t[1]),g:B(t[2]+""+t[2]),b:B(t[3]+""+t[3]),format:r?"name":"hex"};return!1}(e));"object"==typeof e&&(z(e.r)&&z(e.g)&&z(e.b)?(b=e.r,h=e.g,p=e.b,t={r:255*R(b,255),g:255*R(h,255),b:255*R(p,255)},u=!0,l="%"===String(e.r).substr(-1)?"prgb":"rgb"):z(e.h)&&z(e.s)&&z(e.v)?(n=I(e.s),c=I(e.v),t=function(e,t,r){e=6*R(e,360),t=R(t,100),r=R(r,100);var n=a.floor(e),i=e-n,o=r*(1-t),c=r*(1-i*t),s=r*(1-(1-i)*t),f=n%6;return{r:255*[r,c,o,o,s,r][f],g:255*[s,r,r,c,o,o][f],b:255*[o,o,s,r,r,c][f]}}(e.h,n,c),u=!0,l="hsv"):z(e.h)&&z(e.s)&&z(e.l)&&(n=I(e.s),s=I(e.l),t=function(e,t,r){var n,a,i;function o(e,t,r){return r<0&&(r+=1),r>1&&(r-=1),r<1/6?e+6*(t-e)*r:r<.5?t:r<2/3?e+(t-e)*(2/3-r)*6:e}if(e=R(e,360),t=R(t,100),r=R(r,100),0===t)n=a=i=r;else{var c=r<.5?r*(1+t):r+t-r*t,s=2*r-c;n=o(s,c,e+1/3),a=o(s,c,e),i=o(s,c,e-1/3)}return{r:255*n,g:255*a,b:255*i}}(e.h,n,s),u=!0,l="hsl"),e.hasOwnProperty("a")&&(r=e.a));var b,h,p;return r=C(r),{ok:u,format:e.format||l,r:f(255,d(t.r,0)),g:f(255,d(t.g,0)),b:f(255,d(t.b,0)),a:r}}(e);this._originalInput=e,this._r=r.r,this._g=r.g,this._b=r.b,this._a=r.a,this._roundA=s(100*this._a)/100,this._format=t.format||r.format,this._gradientType=t.gradientType,this._r<1&&(this._r=s(this._r)),this._g<1&&(this._g=s(this._g)),this._b<1&&(this._b=s(this._b)),this._ok=r.ok,this._tc_id=c++}function b(e,t,r){e=R(e,255),t=R(t,255),r=R(r,255);var n,a,i=d(e,t,r),o=f(e,t,r),c=(i+o)/2;if(i==o)n=a=0;else{var s=i-o;switch(a=c>.5?s/(2-i-o):s/(i+o),i){case e:n=(t-r)/s+(t>1)+720)%360;--t;)n.h=(n.h+a)%360,i.push(l(n));return i}function T(e,t){t=t||6;for(var r=l(e).toHsv(),n=r.h,a=r.s,i=r.v,o=[],c=1/t;t--;)o.push(l({h:n,s:a,v:i})),i=(i+c)%1;return o}l.prototype={isDark:function(){return this.getBrightness()<128},isLight:function(){return!this.isDark()},isValid:function(){return this._ok},getOriginalInput:function(){return this._originalInput},getFormat:function(){return this._format},getAlpha:function(){return this._a},getBrightness:function(){var e=this.toRgb();return(299*e.r+587*e.g+114*e.b)/1e3},getLuminance:function(){var e,t,r,n=this.toRgb();return e=n.r/255,t=n.g/255,r=n.b/255,.2126*(e<=.03928?e/12.92:a.pow((e+.055)/1.055,2.4))+.7152*(t<=.03928?t/12.92:a.pow((t+.055)/1.055,2.4))+.0722*(r<=.03928?r/12.92:a.pow((r+.055)/1.055,2.4))},setAlpha:function(e){return this._a=C(e),this._roundA=s(100*this._a)/100,this},toHsv:function(){var e=h(this._r,this._g,this._b);return{h:360*e.h,s:e.s,v:e.v,a:this._a}},toHsvString:function(){var e=h(this._r,this._g,this._b),t=s(360*e.h),r=s(100*e.s),n=s(100*e.v);return 1==this._a?"hsv("+t+", "+r+"%, "+n+"%)":"hsva("+t+", "+r+"%, "+n+"%, "+this._roundA+")"},toHsl:function(){var e=b(this._r,this._g,this._b);return{h:360*e.h,s:e.s,l:e.l,a:this._a}},toHslString:function(){var e=b(this._r,this._g,this._b),t=s(360*e.h),r=s(100*e.s),n=s(100*e.l);return 1==this._a?"hsl("+t+", "+r+"%, "+n+"%)":"hsla("+t+", "+r+"%, "+n+"%, "+this._roundA+")"},toHex:function(e){return p(this._r,this._g,this._b,e)},toHexString:function(e){return"#"+this.toHex(e)},toHex8:function(e){return function(e,t,r,n,a){var i=[L(s(e).toString(16)),L(s(t).toString(16)),L(s(r).toString(16)),L(F(n))];if(a&&i[0].charAt(0)==i[0].charAt(1)&&i[1].charAt(0)==i[1].charAt(1)&&i[2].charAt(0)==i[2].charAt(1)&&i[3].charAt(0)==i[3].charAt(1))return i[0].charAt(0)+i[1].charAt(0)+i[2].charAt(0)+i[3].charAt(0);return i.join("")}(this._r,this._g,this._b,this._a,e)},toHex8String:function(e){return"#"+this.toHex8(e)},toRgb:function(){return{r:s(this._r),g:s(this._g),b:s(this._b),a:this._a}},toRgbString:function(){return 1==this._a?"rgb("+s(this._r)+", "+s(this._g)+", "+s(this._b)+")":"rgba("+s(this._r)+", "+s(this._g)+", "+s(this._b)+", "+this._roundA+")"},toPercentageRgb:function(){return{r:s(100*R(this._r,255))+"%",g:s(100*R(this._g,255))+"%",b:s(100*R(this._b,255))+"%",a:this._a}},toPercentageRgbString:function(){return 1==this._a?"rgb("+s(100*R(this._r,255))+"%, "+s(100*R(this._g,255))+"%, "+s(100*R(this._b,255))+"%)":"rgba("+s(100*R(this._r,255))+"%, "+s(100*R(this._g,255))+"%, "+s(100*R(this._b,255))+"%, "+this._roundA+")"},toName:function(){return 0===this._a?"transparent":!(this._a<1)&&(P[p(this._r,this._g,this._b,!0)]||!1)},toFilter:function(e){var t="#"+m(this._r,this._g,this._b,this._a),r=t,n=this._gradientType?"GradientType = 1, ":"";if(e){var a=l(e);r="#"+m(a._r,a._g,a._b,a._a)}return"progid:DXImageTransform.Microsoft.gradient("+n+"startColorstr="+t+",endColorstr="+r+")"},toString:function(e){var t=!!e;e=e||this._format;var r=!1,n=this._a<1&&this._a>=0;return t||!n||"hex"!==e&&"hex6"!==e&&"hex3"!==e&&"hex4"!==e&&"hex8"!==e&&"name"!==e?("rgb"===e&&(r=this.toRgbString()),"prgb"===e&&(r=this.toPercentageRgbString()),"hex"!==e&&"hex6"!==e||(r=this.toHexString()),"hex3"===e&&(r=this.toHexString(!0)),"hex4"===e&&(r=this.toHex8String(!0)),"hex8"===e&&(r=this.toHex8String()),"name"===e&&(r=this.toName()),"hsl"===e&&(r=this.toHslString()),"hsv"===e&&(r=this.toHsvString()),r||this.toHexString()):"name"===e&&0===this._a?this.toName():this.toRgbString()},clone:function(){return l(this.toString())},_applyModification:function(e,t){var r=e.apply(null,[this].concat([].slice.call(t)));return this._r=r._r,this._g=r._g,this._b=r._b,this.setAlpha(r._a),this},lighten:function(){return this._applyModification(y,arguments)},brighten:function(){return this._applyModification(w,arguments)},darken:function(){return this._applyModification(k,arguments)},desaturate:function(){return this._applyModification(v,arguments)},saturate:function(){return this._applyModification(g,arguments)},greyscale:function(){return this._applyModification(x,arguments)},spin:function(){return this._applyModification(_,arguments)},_applyCombination:function(e,t){return e.apply(null,[this].concat([].slice.call(t)))},analogous:function(){return this._applyCombination(A,arguments)},complement:function(){return this._applyCombination(M,arguments)},monochromatic:function(){return this._applyCombination(T,arguments)},splitcomplement:function(){return this._applyCombination(O,arguments)},triad:function(){return this._applyCombination(S,arguments)},tetrad:function(){return this._applyCombination(E,arguments)}},l.fromRatio=function(e,t){if("object"==typeof e){var r={};for(var n in e)e.hasOwnProperty(n)&&(r[n]="a"===n?e[n]:I(e[n]));e=r}return l(e,t)},l.equals=function(e,t){return!(!e||!t)&&l(e).toRgbString()==l(t).toRgbString()},l.random=function(){return l.fromRatio({r:u(),g:u(),b:u()})},l.mix=function(e,t,r){r=0===r?0:r||50;var n=l(e).toRgb(),a=l(t).toRgb(),i=r/100;return l({r:(a.r-n.r)*i+n.r,g:(a.g-n.g)*i+n.g,b:(a.b-n.b)*i+n.b,a:(a.a-n.a)*i+n.a})},l.readability=function(e,t){var r=l(e),n=l(t);return(a.max(r.getLuminance(),n.getLuminance())+.05)/(a.min(r.getLuminance(),n.getLuminance())+.05)},l.isReadable=function(e,t,r){var n,a,i=l.readability(e,t);switch(a=!1,(n=function(e){var t,r;t=((e=e||{level:"AA",size:"small"}).level||"AA").toUpperCase(),r=(e.size||"small").toLowerCase(),"AA"!==t&&"AAA"!==t&&(t="AA");"small"!==r&&"large"!==r&&(r="small");return{level:t,size:r}}(r)).level+n.size){case"AAsmall":case"AAAlarge":a=i>=4.5;break;case"AAlarge":a=i>=3;break;case"AAAsmall":a=i>=7}return a},l.mostReadable=function(e,t,r){var n,a,i,o,c=null,s=0;a=(r=r||{}).includeFallbackColors,i=r.level,o=r.size;for(var f=0;fs&&(s=n,c=l(t[f]));return l.isReadable(e,c,{level:i,size:o})||!a?c:(r.includeFallbackColors=!1,l.mostReadable(e,["#fff","#000"],r))};var j=l.names={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"},P=l.hexNames=function(e){var t={};for(var r in e)e.hasOwnProperty(r)&&(t[e[r]]=r);return t}(j);function C(e){return e=parseFloat(e),(isNaN(e)||e<0||e>1)&&(e=1),e}function R(e,t){(function(e){return"string"==typeof e&&-1!=e.indexOf(".")&&1===parseFloat(e)})(e)&&(e="100%");var r=function(e){return"string"===typeof e&&-1!=e.indexOf("%")}(e);return e=f(t,d(0,parseFloat(e))),r&&(e=parseInt(e*t,10)/100),a.abs(e-t)<1e-6?1:e%t/parseFloat(t)}function N(e){return f(1,d(0,e))}function B(e){return parseInt(e,16)}function L(e){return 1==e.length?"0"+e:""+e}function I(e){return e<=1&&(e=100*e+"%"),e}function F(e){return a.round(255*parseFloat(e)).toString(16)}function D(e){return B(e)/255}var U=function(){var e="(?:[-\\+]?\\d*\\.\\d+%?)|(?:[-\\+]?\\d+%?)",t="[\\s|\\(]+("+e+")[,|\\s]+("+e+")[,|\\s]+("+e+")\\s*\\)?",r="[\\s|\\(]+("+e+")[,|\\s]+("+e+")[,|\\s]+("+e+")[,|\\s]+("+e+")\\s*\\)?";return{CSS_UNIT:new RegExp(e),rgb:new RegExp("rgb"+t),rgba:new RegExp("rgba"+r),hsl:new RegExp("hsl"+t),hsla:new RegExp("hsla"+r),hsv:new RegExp("hsv"+t),hsva:new RegExp("hsva"+r),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/}}();function z(e){return!!U.CSS_UNIT.exec(e)}e.exports?e.exports=l:void 0===(n=function(){return l}.call(t,r,t,e))||(e.exports=n)}(Math)},function(e,t){function r(e,t,r,n,a,i,o){try{var c=e[i](o),s=c.value}catch(f){return void r(f)}c.done?t(s):Promise.resolve(s).then(n,a)}e.exports=function(e){return function(){var t=this,n=arguments;return new Promise((function(a,i){var o=e.apply(t,n);function c(e){r(o,a,i,c,s,"next",e)}function s(e){r(o,a,i,c,s,"throw",e)}c(void 0)}))}}},function(e,t,r){"use strict";(function(e){var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.getLength=t.decode=t.encode=void 0;var a=n(r(636));function i(e,t){if("0"===e[0]&&"0"===e[1])throw new Error("invalid RLP: extra zeros");return parseInt(e,t)}function o(t,r){if(t<56)return e.from([t+r]);var n=s(t),a=s(r+55+n.length/2);return e.from(a+n,"hex")}function c(e){return"0x"===e.slice(0,2)}function s(e){if(e<0)throw new Error("Invalid integer as argument, must be unsigned!");var t=e.toString(16);return t.length%2?"0"+t:t}function f(t){if(!e.isBuffer(t)){if("string"===typeof t)return c(t)?e.from((r="string"!==typeof(n=t)?n:c(n)?n.slice(2):n).length%2?"0"+r:r,"hex"):e.from(t);if("number"===typeof t||"bigint"===typeof t)return t?function(t){var r=s(t);return e.from(r,"hex")}(t):e.from([]);if(null===t||void 0===t)return e.from([]);if(t instanceof Uint8Array)return e.from(t);if(a.default.isBN(t))return e.from(t.toArray());throw new Error("invalid type")}var r,n;return t}t.encode=function t(r){if(Array.isArray(r)){for(var n=[],a=0;ar.length)throw new Error("invalid rlp: total length is larger than the data");if(0===(c=r.slice(a,u)).length)throw new Error("invalid rlp, List has a invalid length");for(;c.length;)s=t(c),f.push(s.data),c=s.remainder;return{data:f,remainder:r.slice(u)}}(f(t));if(r)return n;if(0!==n.remainder.length)throw new Error("invalid remainder");return n.data},t.getLength=function(t){if(!t||0===t.length)return e.from([]);var r=f(t),n=r[0];if(n<=127)return r.length;if(n<=183)return n-127;if(n<=191)return n-182;if(n<=247)return n-191;var a=n-246;return a+i(r.slice(1,a).toString("hex"),16)}}).call(this,r(30).Buffer)},function(e,t,r){"use strict";var n=r(118),a=r(94),i=a.getNAF,o=a.getJSF,c=a.assert;function s(e,t){this.type=e,this.p=new n(t.p,16),this.red=t.prime?n.red(t.prime):n.mont(this.p),this.zero=new n(0).toRed(this.red),this.one=new n(1).toRed(this.red),this.two=new n(2).toRed(this.red),this.n=t.n&&new n(t.n,16),this.g=t.g&&this.pointFromJSON(t.g,t.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var r=this.n&&this.p.div(this.n);!r||r.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}function f(e,t){this.curve=e,this.type=t,this.precomputed=null}e.exports=s,s.prototype.point=function(){throw new Error("Not implemented")},s.prototype.validate=function(){throw new Error("Not implemented")},s.prototype._fixedNafMul=function(e,t){c(e.precomputed);var r=e._getDoubles(),n=i(t,1,this._bitLength),a=(1<=o;d--)s=(s<<1)+n[d];f.push(s)}for(var u=this.jpoint(null,null,null),l=this.jpoint(null,null,null),b=a;b>0;b--){for(o=0;o=0;f--){for(var d=0;f>=0&&0===o[f];f--)d++;if(f>=0&&d++,s=s.dblp(d),f<0)break;var u=o[f];c(0!==u),s="affine"===e.type?u>0?s.mixedAdd(a[u-1>>1]):s.mixedAdd(a[-u-1>>1].neg()):u>0?s.add(a[u-1>>1]):s.add(a[-u-1>>1].neg())}return"affine"===e.type?s.toP():s},s.prototype._wnafMulAdd=function(e,t,r,n,a){var c,s,f,d=this._wnafT1,u=this._wnafT2,l=this._wnafT3,b=0;for(c=0;c=1;c-=2){var p=c-1,m=c;if(1===d[p]&&1===d[m]){var v=[t[p],null,null,t[m]];0===t[p].y.cmp(t[m].y)?(v[1]=t[p].add(t[m]),v[2]=t[p].toJ().mixedAdd(t[m].neg())):0===t[p].y.cmp(t[m].y.redNeg())?(v[1]=t[p].toJ().mixedAdd(t[m]),v[2]=t[p].add(t[m].neg())):(v[1]=t[p].toJ().mixedAdd(t[m]),v[2]=t[p].toJ().mixedAdd(t[m].neg()));var g=[-3,-1,-5,-7,0,7,5,1,3],x=o(r[p],r[m]);for(b=Math.max(x[0].length,b),l[p]=new Array(b),l[m]=new Array(b),s=0;s=0;c--){for(var M=0;c>=0;){var S=!0;for(s=0;s=0&&M++,k=k.dblp(M),c<0)break;for(s=0;s0?f=u[s][E-1>>1]:E<0&&(f=u[s][-E-1>>1].neg()),k="affine"===f.type?k.mixedAdd(f):k.add(f))}}for(c=0;c=Math.ceil((e.bitLength()+1)/t.step)},f.prototype._getDoubles=function(e,t){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var r=[this],n=this,a=0;a1?(e[r[0]]=e[r[0]]||{},e[r[0]][r[1]]=t):e[r[0]]=t},a.prototype.buildCall=function(){var e=this;return function(){e.subscriptions[arguments[0]]||console.warn("Subscription "+JSON.stringify(arguments[0])+" doesn't exist. Subscribing anyway.");var t=new n({subscription:e.subscriptions[arguments[0]]||{},requestManager:e.requestManager,type:e.type});return t.subscribe.apply(t,arguments)}},e.exports={subscriptions:a,subscription:n}},function(e,t,r){"use strict";var n=r(153),a=r(154),i=r(78),o=function(){var e=this;n.packageInit(this,arguments),[new a({name:"getId",call:"net_version",params:0,outputFormatter:parseInt}),new a({name:"isListening",call:"net_listening",params:0}),new a({name:"getPeerCount",call:"net_peerCount",params:0,outputFormatter:i.hexToNumber})].forEach((function(t){t.attachToObject(e),t.setRequestManager(e._requestManager)}))};n.addProviders(o),e.exports=o},function(e){e.exports=JSON.parse('{"identity":0,"ip4":4,"tcp":6,"sha1":17,"sha2-256":18,"sha2-512":19,"sha3-512":20,"sha3-384":21,"sha3-256":22,"sha3-224":23,"shake-128":24,"shake-256":25,"keccak-224":26,"keccak-256":27,"keccak-384":28,"keccak-512":29,"dccp":33,"murmur3-128":34,"murmur3-32":35,"ip6":41,"ip6zone":42,"path":47,"multicodec":48,"multihash":49,"multiaddr":50,"multibase":51,"dns":53,"dns4":54,"dns6":55,"dnsaddr":56,"protobuf":80,"cbor":81,"raw":85,"dbl-sha2-256":86,"rlp":96,"bencode":99,"dag-pb":112,"dag-cbor":113,"libp2p-key":114,"git-raw":120,"torrent-info":123,"torrent-file":124,"leofcoin-block":129,"leofcoin-tx":130,"leofcoin-pr":131,"sctp":132,"eth-block":144,"eth-block-list":145,"eth-tx-trie":146,"eth-tx":147,"eth-tx-receipt-trie":148,"eth-tx-receipt":149,"eth-state-trie":150,"eth-account-snapshot":151,"eth-storage-trie":152,"bitcoin-block":176,"bitcoin-tx":177,"zcash-block":192,"zcash-tx":193,"stellar-block":208,"stellar-tx":209,"md4":212,"md5":213,"bmt":214,"decred-block":224,"decred-tx":225,"ipld-ns":226,"ipfs-ns":227,"swarm-ns":228,"ipns-ns":229,"zeronet":230,"ed25519-pub":237,"dash-block":240,"dash-tx":241,"swarm-manifest":250,"swarm-feed":251,"udp":273,"p2p-webrtc-star":275,"p2p-webrtc-direct":276,"p2p-stardust":277,"p2p-circuit":290,"dag-json":297,"udt":301,"utp":302,"unix":400,"p2p":421,"ipfs":421,"https":443,"onion":444,"onion3":445,"garlic64":446,"garlic32":447,"tls":448,"quic":460,"ws":477,"wss":478,"p2p-websocket-star":479,"http":480,"json":512,"messagepack":513,"x11":4352,"blake2b-8":45569,"blake2b-16":45570,"blake2b-24":45571,"blake2b-32":45572,"blake2b-40":45573,"blake2b-48":45574,"blake2b-56":45575,"blake2b-64":45576,"blake2b-72":45577,"blake2b-80":45578,"blake2b-88":45579,"blake2b-96":45580,"blake2b-104":45581,"blake2b-112":45582,"blake2b-120":45583,"blake2b-128":45584,"blake2b-136":45585,"blake2b-144":45586,"blake2b-152":45587,"blake2b-160":45588,"blake2b-168":45589,"blake2b-176":45590,"blake2b-184":45591,"blake2b-192":45592,"blake2b-200":45593,"blake2b-208":45594,"blake2b-216":45595,"blake2b-224":45596,"blake2b-232":45597,"blake2b-240":45598,"blake2b-248":45599,"blake2b-256":45600,"blake2b-264":45601,"blake2b-272":45602,"blake2b-280":45603,"blake2b-288":45604,"blake2b-296":45605,"blake2b-304":45606,"blake2b-312":45607,"blake2b-320":45608,"blake2b-328":45609,"blake2b-336":45610,"blake2b-344":45611,"blake2b-352":45612,"blake2b-360":45613,"blake2b-368":45614,"blake2b-376":45615,"blake2b-384":45616,"blake2b-392":45617,"blake2b-400":45618,"blake2b-408":45619,"blake2b-416":45620,"blake2b-424":45621,"blake2b-432":45622,"blake2b-440":45623,"blake2b-448":45624,"blake2b-456":45625,"blake2b-464":45626,"blake2b-472":45627,"blake2b-480":45628,"blake2b-488":45629,"blake2b-496":45630,"blake2b-504":45631,"blake2b-512":45632,"blake2s-8":45633,"blake2s-16":45634,"blake2s-24":45635,"blake2s-32":45636,"blake2s-40":45637,"blake2s-48":45638,"blake2s-56":45639,"blake2s-64":45640,"blake2s-72":45641,"blake2s-80":45642,"blake2s-88":45643,"blake2s-96":45644,"blake2s-104":45645,"blake2s-112":45646,"blake2s-120":45647,"blake2s-128":45648,"blake2s-136":45649,"blake2s-144":45650,"blake2s-152":45651,"blake2s-160":45652,"blake2s-168":45653,"blake2s-176":45654,"blake2s-184":45655,"blake2s-192":45656,"blake2s-200":45657,"blake2s-208":45658,"blake2s-216":45659,"blake2s-224":45660,"blake2s-232":45661,"blake2s-240":45662,"blake2s-248":45663,"blake2s-256":45664,"skein256-8":45825,"skein256-16":45826,"skein256-24":45827,"skein256-32":45828,"skein256-40":45829,"skein256-48":45830,"skein256-56":45831,"skein256-64":45832,"skein256-72":45833,"skein256-80":45834,"skein256-88":45835,"skein256-96":45836,"skein256-104":45837,"skein256-112":45838,"skein256-120":45839,"skein256-128":45840,"skein256-136":45841,"skein256-144":45842,"skein256-152":45843,"skein256-160":45844,"skein256-168":45845,"skein256-176":45846,"skein256-184":45847,"skein256-192":45848,"skein256-200":45849,"skein256-208":45850,"skein256-216":45851,"skein256-224":45852,"skein256-232":45853,"skein256-240":45854,"skein256-248":45855,"skein256-256":45856,"skein512-8":45857,"skein512-16":45858,"skein512-24":45859,"skein512-32":45860,"skein512-40":45861,"skein512-48":45862,"skein512-56":45863,"skein512-64":45864,"skein512-72":45865,"skein512-80":45866,"skein512-88":45867,"skein512-96":45868,"skein512-104":45869,"skein512-112":45870,"skein512-120":45871,"skein512-128":45872,"skein512-136":45873,"skein512-144":45874,"skein512-152":45875,"skein512-160":45876,"skein512-168":45877,"skein512-176":45878,"skein512-184":45879,"skein512-192":45880,"skein512-200":45881,"skein512-208":45882,"skein512-216":45883,"skein512-224":45884,"skein512-232":45885,"skein512-240":45886,"skein512-248":45887,"skein512-256":45888,"skein512-264":45889,"skein512-272":45890,"skein512-280":45891,"skein512-288":45892,"skein512-296":45893,"skein512-304":45894,"skein512-312":45895,"skein512-320":45896,"skein512-328":45897,"skein512-336":45898,"skein512-344":45899,"skein512-352":45900,"skein512-360":45901,"skein512-368":45902,"skein512-376":45903,"skein512-384":45904,"skein512-392":45905,"skein512-400":45906,"skein512-408":45907,"skein512-416":45908,"skein512-424":45909,"skein512-432":45910,"skein512-440":45911,"skein512-448":45912,"skein512-456":45913,"skein512-464":45914,"skein512-472":45915,"skein512-480":45916,"skein512-488":45917,"skein512-496":45918,"skein512-504":45919,"skein512-512":45920,"skein1024-8":45921,"skein1024-16":45922,"skein1024-24":45923,"skein1024-32":45924,"skein1024-40":45925,"skein1024-48":45926,"skein1024-56":45927,"skein1024-64":45928,"skein1024-72":45929,"skein1024-80":45930,"skein1024-88":45931,"skein1024-96":45932,"skein1024-104":45933,"skein1024-112":45934,"skein1024-120":45935,"skein1024-128":45936,"skein1024-136":45937,"skein1024-144":45938,"skein1024-152":45939,"skein1024-160":45940,"skein1024-168":45941,"skein1024-176":45942,"skein1024-184":45943,"skein1024-192":45944,"skein1024-200":45945,"skein1024-208":45946,"skein1024-216":45947,"skein1024-224":45948,"skein1024-232":45949,"skein1024-240":45950,"skein1024-248":45951,"skein1024-256":45952,"skein1024-264":45953,"skein1024-272":45954,"skein1024-280":45955,"skein1024-288":45956,"skein1024-296":45957,"skein1024-304":45958,"skein1024-312":45959,"skein1024-320":45960,"skein1024-328":45961,"skein1024-336":45962,"skein1024-344":45963,"skein1024-352":45964,"skein1024-360":45965,"skein1024-368":45966,"skein1024-376":45967,"skein1024-384":45968,"skein1024-392":45969,"skein1024-400":45970,"skein1024-408":45971,"skein1024-416":45972,"skein1024-424":45973,"skein1024-432":45974,"skein1024-440":45975,"skein1024-448":45976,"skein1024-456":45977,"skein1024-464":45978,"skein1024-472":45979,"skein1024-480":45980,"skein1024-488":45981,"skein1024-496":45982,"skein1024-504":45983,"skein1024-512":45984,"skein1024-520":45985,"skein1024-528":45986,"skein1024-536":45987,"skein1024-544":45988,"skein1024-552":45989,"skein1024-560":45990,"skein1024-568":45991,"skein1024-576":45992,"skein1024-584":45993,"skein1024-592":45994,"skein1024-600":45995,"skein1024-608":45996,"skein1024-616":45997,"skein1024-624":45998,"skein1024-632":45999,"skein1024-640":46000,"skein1024-648":46001,"skein1024-656":46002,"skein1024-664":46003,"skein1024-672":46004,"skein1024-680":46005,"skein1024-688":46006,"skein1024-696":46007,"skein1024-704":46008,"skein1024-712":46009,"skein1024-720":46010,"skein1024-728":46011,"skein1024-736":46012,"skein1024-744":46013,"skein1024-752":46014,"skein1024-760":46015,"skein1024-768":46016,"skein1024-776":46017,"skein1024-784":46018,"skein1024-792":46019,"skein1024-800":46020,"skein1024-808":46021,"skein1024-816":46022,"skein1024-824":46023,"skein1024-832":46024,"skein1024-840":46025,"skein1024-848":46026,"skein1024-856":46027,"skein1024-864":46028,"skein1024-872":46029,"skein1024-880":46030,"skein1024-888":46031,"skein1024-896":46032,"skein1024-904":46033,"skein1024-912":46034,"skein1024-920":46035,"skein1024-928":46036,"skein1024-936":46037,"skein1024-944":46038,"skein1024-952":46039,"skein1024-960":46040,"skein1024-968":46041,"skein1024-976":46042,"skein1024-984":46043,"skein1024-992":46044,"skein1024-1000":46045,"skein1024-1008":46046,"skein1024-1016":46047,"skein1024-1024":46048,"holochain-adr-v0":8417572,"holochain-adr-v1":8483108,"holochain-key-v0":9728292,"holochain-key-v1":9793828,"holochain-sig-v0":10645796,"holochain-sig-v1":10711332}')},function(e,t,r){"use strict";t.randomBytes=t.rng=t.pseudoRandomBytes=t.prng=r(131),t.createHash=t.Hash=r(166),t.createHmac=t.Hmac=r(442);var n=r(788),a=Object.keys(n),i=["sha1","sha224","sha256","sha384","sha512","md5","rmd160"].concat(a);t.getHashes=function(){return i};var o=r(445);t.pbkdf2=o.pbkdf2,t.pbkdf2Sync=o.pbkdf2Sync;var c=r(790);t.Cipher=c.Cipher,t.createCipher=c.createCipher,t.Cipheriv=c.Cipheriv,t.createCipheriv=c.createCipheriv,t.Decipher=c.Decipher,t.createDecipher=c.createDecipher,t.Decipheriv=c.Decipheriv,t.createDecipheriv=c.createDecipheriv,t.getCiphers=c.getCiphers,t.listCiphers=c.listCiphers;var s=r(805);t.DiffieHellmanGroup=s.DiffieHellmanGroup,t.createDiffieHellmanGroup=s.createDiffieHellmanGroup,t.getDiffieHellman=s.getDiffieHellman,t.createDiffieHellman=s.createDiffieHellman,t.DiffieHellman=s.DiffieHellman;var f=r(809);t.createSign=f.createSign,t.Sign=f.Sign,t.createVerify=f.createVerify,t.Verify=f.Verify,t.createECDH=r(832);var d=r(833);t.publicEncrypt=d.publicEncrypt,t.privateEncrypt=d.privateEncrypt,t.publicDecrypt=d.publicDecrypt,t.privateDecrypt=d.privateDecrypt;var u=r(836);t.randomFill=u.randomFill,t.randomFillSync=u.randomFillSync,t.createCredentials=function(){throw new Error(["sorry, createCredentials is not implemented yet","we accept pull requests","https://github.com/crypto-browserify/crypto-browserify"].join("\n"))},t.constants={DH_CHECK_P_NOT_SAFE_PRIME:2,DH_CHECK_P_NOT_PRIME:1,DH_UNABLE_TO_CHECK_GENERATOR:4,DH_NOT_SUITABLE_GENERATOR:8,NPN_ENABLED:1,ALPN_ENABLED:1,RSA_PKCS1_PADDING:1,RSA_SSLV23_PADDING:2,RSA_NO_PADDING:3,RSA_PKCS1_OAEP_PADDING:4,RSA_X931_PADDING:5,RSA_PKCS1_PSS_PADDING:6,POINT_CONVERSION_COMPRESSED:2,POINT_CONVERSION_UNCOMPRESSED:4,POINT_CONVERSION_HYBRID:6}},function(e,t,r){var n=r(42).Buffer;function a(e){n.isBuffer(e)||(e=n.from(e));for(var t=e.length/4|0,r=new Array(t),a=0;a>>24]^d[h>>>16&255]^u[p>>>8&255]^l[255&m]^t[v++],o=f[h>>>24]^d[p>>>16&255]^u[m>>>8&255]^l[255&b]^t[v++],c=f[p>>>24]^d[m>>>16&255]^u[b>>>8&255]^l[255&h]^t[v++],s=f[m>>>24]^d[b>>>16&255]^u[h>>>8&255]^l[255&p]^t[v++],b=i,h=o,p=c,m=s;return i=(n[b>>>24]<<24|n[h>>>16&255]<<16|n[p>>>8&255]<<8|n[255&m])^t[v++],o=(n[h>>>24]<<24|n[p>>>16&255]<<16|n[m>>>8&255]<<8|n[255&b])^t[v++],c=(n[p>>>24]<<24|n[m>>>16&255]<<16|n[b>>>8&255]<<8|n[255&h])^t[v++],s=(n[m>>>24]<<24|n[b>>>16&255]<<16|n[h>>>8&255]<<8|n[255&p])^t[v++],[i>>>=0,o>>>=0,c>>>=0,s>>>=0]}var c=[0,1,2,4,8,16,32,64,128,27,54],s=function(){for(var e=new Array(256),t=0;t<256;t++)e[t]=t<128?t<<1:t<<1^283;for(var r=[],n=[],a=[[],[],[],[]],i=[[],[],[],[]],o=0,c=0,s=0;s<256;++s){var f=c^c<<1^c<<2^c<<3^c<<4;f=f>>>8^255&f^99,r[o]=f,n[f]=o;var d=e[o],u=e[d],l=e[u],b=257*e[f]^16843008*f;a[0][o]=b<<24|b>>>8,a[1][o]=b<<16|b>>>16,a[2][o]=b<<8|b>>>24,a[3][o]=b,b=16843009*l^65537*u^257*d^16843008*o,i[0][f]=b<<24|b>>>8,i[1][f]=b<<16|b>>>16,i[2][f]=b<<8|b>>>24,i[3][f]=b,0===o?o=c=1:(o=d^e[e[e[l^d]]],c^=e[e[c]])}return{SBOX:r,INV_SBOX:n,SUB_MIX:a,INV_SUB_MIX:i}}();function f(e){this._key=a(e),this._reset()}f.blockSize=16,f.keySize=32,f.prototype.blockSize=f.blockSize,f.prototype.keySize=f.keySize,f.prototype._reset=function(){for(var e=this._key,t=e.length,r=t+6,n=4*(r+1),a=[],i=0;i>>24,o=s.SBOX[o>>>24]<<24|s.SBOX[o>>>16&255]<<16|s.SBOX[o>>>8&255]<<8|s.SBOX[255&o],o^=c[i/t|0]<<24):t>6&&i%t===4&&(o=s.SBOX[o>>>24]<<24|s.SBOX[o>>>16&255]<<16|s.SBOX[o>>>8&255]<<8|s.SBOX[255&o]),a[i]=a[i-t]^o}for(var f=[],d=0;d>>24]]^s.INV_SUB_MIX[1][s.SBOX[l>>>16&255]]^s.INV_SUB_MIX[2][s.SBOX[l>>>8&255]]^s.INV_SUB_MIX[3][s.SBOX[255&l]]}this._nRounds=r,this._keySchedule=a,this._invKeySchedule=f},f.prototype.encryptBlockRaw=function(e){return o(e=a(e),this._keySchedule,s.SUB_MIX,s.SBOX,this._nRounds)},f.prototype.encryptBlock=function(e){var t=this.encryptBlockRaw(e),r=n.allocUnsafe(16);return r.writeUInt32BE(t[0],0),r.writeUInt32BE(t[1],4),r.writeUInt32BE(t[2],8),r.writeUInt32BE(t[3],12),r},f.prototype.decryptBlock=function(e){var t=(e=a(e))[1];e[1]=e[3],e[3]=t;var r=o(e,this._invKeySchedule,s.INV_SUB_MIX,s.INV_SBOX,this._nRounds),i=n.allocUnsafe(16);return i.writeUInt32BE(r[0],0),i.writeUInt32BE(r[3],4),i.writeUInt32BE(r[2],8),i.writeUInt32BE(r[1],12),i},f.prototype.scrub=function(){i(this._keySchedule),i(this._invKeySchedule),i(this._key)},e.exports.AES=f},function(e,t,r){var n=r(42).Buffer,a=r(304);e.exports=function(e,t,r,i){if(n.isBuffer(e)||(e=n.from(e,"binary")),t&&(n.isBuffer(t)||(t=n.from(t,"binary")),8!==t.length))throw new RangeError("salt should be Buffer with 8 byte length");for(var o=r/8,c=n.alloc(o),s=n.alloc(i||0),f=n.alloc(0);o>0||i>0;){var d=new a;d.update(f),d.update(e),t&&d.update(t),f=d.digest();var u=0;if(o>0){var l=c.length-o;u=Math.min(o,f.length),f.copy(c,l,0,u),o-=u}if(u0){var b=s.length-i,h=Math.min(i,f.length-u);f.copy(s,b,u,u+h),i-=h}}return f.fill(0),{key:c,iv:s}}},function(e,t,r){var n=r(822),a=r(829),i=r(830),o=r(315),c=r(445),s=r(42).Buffer;function f(e){var t;"object"!==typeof e||s.isBuffer(e)||(t=e.passphrase,e=e.key),"string"===typeof e&&(e=s.from(e));var r,f,d=i(e,t),u=d.tag,l=d.data;switch(u){case"CERTIFICATE":f=n.certificate.decode(l,"der").tbsCertificate.subjectPublicKeyInfo;case"PUBLIC KEY":switch(f||(f=n.PublicKey.decode(l,"der")),r=f.algorithm.algorithm.join(".")){case"1.2.840.113549.1.1.1":return n.RSAPublicKey.decode(f.subjectPublicKey.data,"der");case"1.2.840.10045.2.1":return f.subjectPrivateKey=f.subjectPublicKey,{type:"ec",data:f};case"1.2.840.10040.4.1":return f.algorithm.params.pub_key=n.DSAparam.decode(f.subjectPublicKey.data,"der"),{type:"dsa",data:f.algorithm.params};default:throw new Error("unknown key id "+r)}case"ENCRYPTED PRIVATE KEY":l=function(e,t){var r=e.algorithm.decrypt.kde.kdeparams.salt,n=parseInt(e.algorithm.decrypt.kde.kdeparams.iters.toString(),10),i=a[e.algorithm.decrypt.cipher.algo.join(".")],f=e.algorithm.decrypt.cipher.iv,d=e.subjectPrivateKey,u=parseInt(i.split("-")[1],10)/8,l=c.pbkdf2Sync(t,r,n,u,"sha1"),b=o.createDecipheriv(i,l,f),h=[];return h.push(b.update(d)),h.push(b.final()),s.concat(h)}(l=n.EncryptedPrivateKey.decode(l,"der"),t);case"PRIVATE KEY":switch(r=(f=n.PrivateKey.decode(l,"der")).algorithm.algorithm.join(".")){case"1.2.840.113549.1.1.1":return n.RSAPrivateKey.decode(f.subjectPrivateKey,"der");case"1.2.840.10045.2.1":return{curve:f.algorithm.curve,privateKey:n.ECPrivateKey.decode(f.subjectPrivateKey,"der").privateKey};case"1.2.840.10040.4.1":return f.algorithm.params.priv_key=n.DSAparam.decode(f.subjectPrivateKey,"der"),{type:"dsa",params:f.algorithm.params};default:throw new Error("unknown key id "+r)}case"RSA PUBLIC KEY":return n.RSAPublicKey.decode(l,"der");case"RSA PRIVATE KEY":return n.RSAPrivateKey.decode(l,"der");case"DSA PRIVATE KEY":return{type:"dsa",params:n.DSAPrivateKey.decode(l,"der")};case"EC PRIVATE KEY":return{curve:(l=n.ECPrivateKey.decode(l,"der")).parameters.value,privateKey:l.privateKey};default:throw new Error("unknown key type "+u)}}e.exports=f,f.signature=n.signature},function(e,t,r){"use strict";r.r(t);var n=r(325);r.d(t,"decode",(function(){return n.a})),r.d(t,"encode",(function(){return n.b}))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(958);t.decode=function(e){return[n.decode(e),n.decode.bytes]},t.encodeTo=function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;return n.encode(e,t,r),t},t.encodingLength=function(e){return n.encodingLength(e)}},function(e,t,r){var n=r(974),a=r(975),i=r(976),o=r(977),c=r(978);function s(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t.04045?Math.pow((e+.005)/1.055,2.4):e/12.92,t=t>.04045?Math.pow((t+.005)/1.055,2.4):t/12.92,r=r>.04045?Math.pow((r+.005)/1.055,2.4):r/12.92,[.4124*(e*=100)+.3576*(t*=100)+.1805*(r*=100),.2126*e+.7152*t+.0722*r,.0193*e+.1192*t+.9505*r]}function i(e,t,r){return t/=100,r/=108.883,e=(e/=95.047)>.008856?Math.pow(e,1/3):7.787*e+16/116,[116*(t=t>.008856?Math.pow(t,1/3):7.787*t+16/116)-16,500*(e-t),200*(t-(r=r>.008856?Math.pow(r,1/3):7.787*r+16/116))]}function o(e,t,r){var n=a(e,t,r);return i(n[0],n[1],n[2])}function c(e,t){var r=e[0],n=e[1],a=e[2],i=t[0],o=t[1],c=t[2],s=r-i,f=n-o,d=a-c,u=Math.sqrt(n*n+a*a),l=i-r,b=Math.sqrt(o*o+c*c)-u,h=Math.sqrt(s*s+f*f+d*d),p=Math.sqrt(h)>Math.sqrt(Math.abs(l))+Math.sqrt(Math.abs(b))?Math.sqrt(h*h-l*l-b*b):0;return l/=1,b/=1*(1+.045*u),p/=1*(1+.015*u),Math.sqrt(l*l+b*b+p*p)}function s(e,t){return c(o.apply(void 0,e),o.apply(void 0,t))}Object.defineProperty(t,"__esModule",{value:!0}),t.getColorIndex=t.getColorDiffStatus=t.hexDiff=t.rgbDiff=t.deltaE94=t.rgbToCIELab=t.xyzToCIELab=t.rgbToXyz=t.hslToRgb=t.rgbToHsl=t.rgbToHex=t.hexToRgb=t.defer=t.RSHIFT=t.SIGBITS=t.DELTAE94_DIFF_STATUS=void 0,t.DELTAE94_DIFF_STATUS={NA:0,PERFECT:1,CLOSE:2,GOOD:10,SIMILAR:50},t.SIGBITS=5,t.RSHIFT=8-t.SIGBITS,t.defer=function(){var e,t,r=new Promise((function(r,n){e=r,t=n}));return{resolve:e,reject:t,promise:r}},t.hexToRgb=n,t.rgbToHex=function(e,t,r){return"#"+((1<<24)+(e<<16)+(t<<8)+r).toString(16).slice(1,7)},t.rgbToHsl=function(e,t,r){e/=255,t/=255,r/=255;var n,a,i=Math.max(e,t,r),o=Math.min(e,t,r),c=(i+o)/2;if(i===o)n=a=0;else{var s=i-o;switch(a=c>.5?s/(2-i-o):s/(i+o),i){case e:n=(t-r)/s+(t1&&(r-=1),r<1/6?e+6*(t-e)*r:r<.5?t:r<2/3?e+(t-e)*(2/3-r)*6:e}if(0===t)n=a=i=r;else{var c=r<.5?r*(1+t):r+t-r*t,s=2*r-c;n=o(s,c,e+1/3),a=o(s,c,e),i=o(s,c,e-1/3)}return[255*n,255*a,255*i]},t.rgbToXyz=a,t.xyzToCIELab=i,t.rgbToCIELab=o,t.deltaE94=c,t.rgbDiff=s,t.hexDiff=function(e,t){return s(n(e),n(t))},t.getColorDiffStatus=function(e){return e=0)return a(e,t,t);var r=Math.abs(t),n=a(e,r,r);return"string"===typeof n?"-"+n:-1*n},u=["margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","top","bottom","left","right"].reduce((function(e,t){var r;return n({},e,((r={})[t]=d,r))}),{}),l=function(e){return function(t){var r={},n=a(t,"breakpoints",i),o=[null].concat(n.map((function(e){return"@media screen and (min-width: "+e+")"})));for(var c in e){var s="function"===typeof e[c]?e[c](t):e[c];if(null!=s)if(Array.isArray(s))for(var f=0;f=5||2===r&&(a[0]>5||5===a[0]&&(n||void 0!==a[1]))),a.length=1,n?(e.e=e.e-t+1,a[0]=1):a[0]=e.e=0;else if(t=5||2===r&&(a[t]>5||5===a[t]&&(n||void 0!==a[t+1]||1&a[t-1]))||3===r&&(n||!!a[0]),a.length=t--,n)for(;++a[t]>9;)a[t]=0,t--||(++e.e,a.unshift(1));for(t=a.length;!a[--t];)a.pop()}return e}function l(e,t,r){var n=e.e,a=e.c.join(""),i=a.length;if(t)a=a.charAt(0)+(i>1?"."+a.slice(1):"")+(n<0?"e":"e+")+n;else if(n<0){for(;++n;)a="0"+a;a="0."+a}else if(n>0)if(++n>i)for(n-=i;n--;)a+="0";else n1&&(a=a.charAt(0)+"."+a.slice(1));return e.s<0&&r?"-"+a:a}f.abs=function(){var e=new this.constructor(this);return e.s=1,e},f.cmp=function(e){var t,r=this,n=r.c,a=(e=new r.constructor(e)).c,i=r.s,o=e.s,c=r.e,s=e.e;if(!n[0]||!a[0])return n[0]?i:a[0]?-o:0;if(i!=o)return i;if(t=i<0,c!=s)return c>s^t?1:-1;for(o=(c=n.length)<(s=a.length)?c:s,i=-1;++ia[i]^t?1:-1;return c==s?0:c>s^t?1:-1},f.div=function(e){var t=this,r=t.constructor,n=t.c,a=(e=new r(e)).c,i=t.s==e.s?1:-1,o=r.DP;if(o!==~~o||o<0||o>1e6)throw Error(s);if(!a[0])throw Error("[big.js] Division by zero");if(!n[0])return e.s=i,e.c=[e.e=0],e;var c,f,d,l,b,h=a.slice(),p=c=a.length,m=n.length,v=n.slice(0,c),g=v.length,x=e,y=x.c=[],w=0,k=o+(x.e=t.e-e.e)+1;for(x.s=i,i=k<0?0:k,h.unshift(0);g++g?1:-1;else for(b=-1,l=0;++bv[b]?1:-1;break}if(!(l<0))break;for(f=g==c?a:h;g;){if(v[--g]k&&u(x,k,r.RM,void 0!==v[0]),x},f.eq=function(e){return 0===this.cmp(e)},f.gt=function(e){return this.cmp(e)>0},f.gte=function(e){return this.cmp(e)>-1},f.lt=function(e){return this.cmp(e)<0},f.lte=function(e){return this.cmp(e)<1},f.minus=f.sub=function(e){var t,r,n,a,i=this,o=i.constructor,c=i.s,s=(e=new o(e)).s;if(c!=s)return e.s=-s,i.plus(e);var f=i.c.slice(),d=i.e,u=e.c,l=e.e;if(!f[0]||!u[0])return u[0]?e.s=-s:f[0]?e=new o(i):e.s=1,e;if(c=d-l){for((a=c<0)?(c=-c,n=f):(l=d,n=u),n.reverse(),s=c;s--;)n.push(0);n.reverse()}else for(r=((a=f.length0)for(;s--;)f[t++]=0;for(s=t;r>c;){if(f[--r]0?(s=o,n=f):(t=-t,n=c),n.reverse();t--;)n.push(0);n.reverse()}for(c.length-f.length<0&&(n=f,f=c,c=n),t=f.length,r=0;t;c[t]%=10)r=(c[--t]=c[t]+f[t]+r)/10|0;for(r&&(c.unshift(r),++s),t=c.length;0===c[--t];)c.pop();return e.c=c,e.e=s,e},f.pow=function(e){var t=this,r=new t.constructor("1"),n=r,a=e<0;if(e!==~~e||e<-1e6||e>1e6)throw Error(c+"exponent");for(a&&(e=-e);1&e&&(n=n.times(t)),e>>=1;)t=t.times(t);return a?r.div(n):n},f.prec=function(e,t){if(e!==~~e||e<1||e>1e6)throw Error(c+"precision");return u(new this.constructor(this),e,t)},f.round=function(e,t){if(void 0===e)e=0;else if(e!==~~e||e<-1e6||e>1e6)throw Error(s);return u(new this.constructor(this),e+this.e+1,t)},f.sqrt=function(){var e,t,r,n=this,a=n.constructor,i=n.s,c=n.e,s=new a("0.5");if(!n.c[0])return new a(n);if(i<0)throw Error(o+"No square root");0===(i=Math.sqrt(n+""))||i===1/0?((t=n.c.join("")).length+c&1||(t+="0"),c=((c+1)/2|0)-(c<0||1&c),e=new a(((i=Math.sqrt(t))==1/0?"5e":(i=i.toExponential()).slice(0,i.indexOf("e")+1))+c)):e=new a(i+""),c=e.e+(a.DP+=4);do{r=e,e=s.times(r.plus(n.div(r)))}while(r.c.slice(0,c).join("")!==e.c.slice(0,c).join(""));return u(e,(a.DP-=4)+e.e+1,a.RM)},f.times=f.mul=function(e){var t,r=this,n=r.constructor,a=r.c,i=(e=new n(e)).c,o=a.length,c=i.length,s=r.e,f=e.e;if(e.s=r.s==e.s?1:-1,!a[0]||!i[0])return e.c=[e.e=0],e;for(e.e=s+f,os;)c=t[f]+i[s]*a[f-s-1]+c,t[f--]=c%10,c=c/10|0;t[f]=c}for(c?++e.e:t.shift(),s=t.length;!t[--s];)t.pop();return e.c=t,e},f.toExponential=function(e,t){var r=this,n=r.c[0];if(void 0!==e){if(e!==~~e||e<0||e>1e6)throw Error(s);for(r=u(new r.constructor(r),++e,t);r.c.length1e6)throw Error(s);for(e=e+(r=u(new r.constructor(r),e+r.e+1,t)).e+1;r.c.length=t.PE,!!e.c[0])},f.toNumber=function(){var e=Number(l(this,!0,!0));if(!0===this.constructor.strict&&!this.eq(e.toString()))throw Error(o+"Imprecise conversion");return e},f.toPrecision=function(e,t){var r=this,n=r.constructor,a=r.c[0];if(void 0!==e){if(e!==~~e||e<1||e>1e6)throw Error(c+"precision");for(r=u(new n(r),e,t);r.c.length=n.PE,!!a)},f.valueOf=function(){var e=this,t=e.constructor;if(!0===t.strict)throw Error(o+"valueOf disallowed");return l(e,e.e<=t.NE||e.e>=t.PE,!0)},(i=function e(){function t(r){var n=this;if(!(n instanceof t))return void 0===r?e():new t(r);if(r instanceof t)n.s=r.s,n.e=r.e,n.c=r.c.slice();else{if("string"!==typeof r){if(!0===t.strict)throw TypeError(c+"number");r=0===r&&1/r<0?"-0":String(r)}!function(e,t){var r,n,a;if(!d.test(t))throw Error(c+"number");e.s="-"==t.charAt(0)?(t=t.slice(1),-1):1,(r=t.indexOf("."))>-1&&(t=t.replace(".",""));(n=t.search(/e/i))>0?(r<0&&(r=n),r+=+t.slice(n+1),t=t.substring(0,n)):r<0&&(r=t.length);for(a=t.length,n=0;n0&&"0"==t.charAt(--a););for(e.e=r-n-1,e.c=[],r=0;n<=a;)e.c[r++]=+t.charAt(n++)}}(n,r)}n.constructor=t}return t.prototype=f,t.DP=20,t.RM=1,t.NE=-7,t.PE=21,t.strict=!1,t.roundDown=0,t.roundHalfUp=1,t.roundHalfEven=2,t.roundUp=3,t}()).default=i.Big=i,void 0===(n=function(){return i}.call(t,r,t,e))||(e.exports=n)}()},function(e,t,r){"use strict";r.d(t,"a",(function(){return n}));var n="hash/5.5.0"},function(e,t,r){"use strict";r.d(t,"a",(function(){return b}));var n=r(137),a=r(23);function i(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}function o(e){return(o=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function c(e,t){return(c=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function s(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}function f(e,t,r){return(f=s()?Reflect.construct:function(e,t,r){var n=[null];n.push.apply(n,t);var a=new(Function.bind.apply(e,n));return r&&c(a,r.prototype),a}).apply(null,arguments)}function d(e){var t="function"===typeof Map?new Map:void 0;return(d=function(e){if(null===e||(r=e,-1===Function.toString.call(r).indexOf("[native code]")))return e;var r;if("function"!==typeof e)throw new TypeError("Super expression must either be null or a function");if("undefined"!==typeof t){if(t.has(e))return t.get(e);t.set(e,n)}function n(){return f(e,arguments,o(this).constructor)}return n.prototype=Object.create(e.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),c(n,e)})(e)}function u(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var l=function(e){function t(){var t;return(t=e.call(this)||this).name=t.constructor.name,t.message="The user rejected the request.",t}return i(t,e),t}(d(Error)),b=function(e){function t(t){var r,n=t.rpc,i=t.bridge,o=t.qrcode,c=t.pollingInterval;return 1!==Object.keys(n).length&&Object(a.a)(!1),(r=e.call(this,{supportedChainIds:Object.keys(n).map((function(e){return Number(e)}))})||this).rpc=n,r.bridge=i,r.qrcode=o,r.pollingInterval=c,r.handleChainChanged=r.handleChainChanged.bind(u(r)),r.handleAccountsChanged=r.handleAccountsChanged.bind(u(r)),r.handleDisconnect=r.handleDisconnect.bind(u(r)),r}i(t,e);var n=t.prototype;return n.handleChainChanged=function(e){this.emitUpdate({chainId:e})},n.handleAccountsChanged=function(e){this.emitUpdate({account:e[0]})},n.handleDisconnect=function(){this.emitDeactivate(),this.walletConnectProvider&&(this.walletConnectProvider.stop(),this.walletConnectProvider.removeListener("chainChanged",this.handleChainChanged),this.walletConnectProvider.removeListener("accountsChanged",this.handleAccountsChanged),this.walletConnectProvider=void 0),this.emitDeactivate()},n.activate=function(){try{var e=function(){function e(){return Promise.resolve(t.walletConnectProvider.enable().then((function(e){return e[0]})).catch((function(e){if("User closed modal"===e.message)throw new l;throw e}))).then((function(e){return t.walletConnectProvider.on("disconnect",t.handleDisconnect),t.walletConnectProvider.on("chainChanged",t.handleChainChanged),t.walletConnectProvider.on("accountsChanged",t.handleAccountsChanged),{provider:t.walletConnectProvider,account:e}}))}var r=function(){if(!t.walletConnectProvider.wc.connected)return Promise.resolve(t.walletConnectProvider.wc.createSession({chainId:Number(Object.keys(t.rpc)[0])})).then((function(){t.emit("URI_AVAILABLE",t.walletConnectProvider.wc.uri)}))}();return r&&r.then?r.then(e):e()},t=this,n=function(){if(!t.walletConnectProvider)return Promise.resolve(Promise.all([r.e(0),r.e(4)]).then(r.bind(null,1166))).then((function(e){var r=e.default;t.walletConnectProvider=new r({bridge:t.bridge,rpc:t.rpc,qrcode:t.qrcode,pollingInterval:t.pollingInterval})}))}();return Promise.resolve(n&&n.then?n.then(e):e())}catch(a){return Promise.reject(a)}},n.getProvider=function(){try{return Promise.resolve(this.walletConnectProvider)}catch(e){return Promise.reject(e)}},n.getChainId=function(){try{return Promise.resolve(this.walletConnectProvider.send("eth_chainId"))}catch(e){return Promise.reject(e)}},n.getAccount=function(){try{return Promise.resolve(this.walletConnectProvider.send("eth_accounts").then((function(e){return e[0]})))}catch(e){return Promise.reject(e)}},n.deactivate=function(){this.walletConnectProvider&&(this.walletConnectProvider.stop(),this.walletConnectProvider.removeListener("disconnect",this.handleDisconnect),this.walletConnectProvider.removeListener("chainChanged",this.handleChainChanged),this.walletConnectProvider.removeListener("accountsChanged",this.handleAccountsChanged))},n.close=function(){try{var e;return Promise.resolve(null==(e=this.walletConnectProvider)?void 0:e.close()).then((function(){}))}catch(t){return Promise.reject(t)}},t}(n.a)},function(e,t,r){"use strict";function n(e,t){return(n=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}r.d(t,"a",(function(){return n}))},function(e,t){var r="undefined"!==typeof Element,n="function"===typeof Map,a="function"===typeof Set,i="function"===typeof ArrayBuffer&&!!ArrayBuffer.isView;e.exports=function(e,t){try{return function e(t,o){if(t===o)return!0;if(t&&o&&"object"==typeof t&&"object"==typeof o){if(t.constructor!==o.constructor)return!1;var c,s,f,d;if(Array.isArray(t)){if((c=t.length)!=o.length)return!1;for(s=c;0!==s--;)if(!e(t[s],o[s]))return!1;return!0}if(n&&t instanceof Map&&o instanceof Map){if(t.size!==o.size)return!1;for(d=t.entries();!(s=d.next()).done;)if(!o.has(s.value[0]))return!1;for(d=t.entries();!(s=d.next()).done;)if(!e(s.value[1],o.get(s.value[0])))return!1;return!0}if(a&&t instanceof Set&&o instanceof Set){if(t.size!==o.size)return!1;for(d=t.entries();!(s=d.next()).done;)if(!o.has(s.value[0]))return!1;return!0}if(i&&ArrayBuffer.isView(t)&&ArrayBuffer.isView(o)){if((c=t.length)!=o.length)return!1;for(s=c;0!==s--;)if(t[s]!==o[s])return!1;return!0}if(t.constructor===RegExp)return t.source===o.source&&t.flags===o.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===o.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===o.toString();if((c=(f=Object.keys(t)).length)!==Object.keys(o).length)return!1;for(s=c;0!==s--;)if(!Object.prototype.hasOwnProperty.call(o,f[s]))return!1;if(r&&t instanceof Element)return!1;for(s=c;0!==s--;)if(("_owner"!==f[s]&&"__v"!==f[s]&&"__o"!==f[s]||!t.$$typeof)&&!e(t[f[s]],o[f[s]]))return!1;return!0}return t!==t&&o!==o}(e,t)}catch(o){if((o.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),!1;throw o}}},function(e,t){e.exports=function(e,t,r,n){var a=r?r.call(n,e,t):void 0;if(void 0!==a)return!!a;if(e===t)return!0;if("object"!==typeof e||!e||"object"!==typeof t||!t)return!1;var i=Object.keys(e),o=Object.keys(t);if(i.length!==o.length)return!1;for(var c=Object.prototype.hasOwnProperty.bind(t),s=0;s=(r+=a.l)&&e<=r+a.h&&(e-r)%(a.d||1)===0){if(a.e&&-1!==a.e.indexOf(e-r))continue;return a}}return null}var c=i("221,13-1b,5f-,40-10,51-f,11-3,3-3,2-2,2-4,8,2,15,2d,28-8,88,48,27-,3-5,11-20,27-,8,28,3-5,12,18,b-a,1c-4,6-16,2-d,2-2,2,1b-4,17-9,8f-,10,f,1f-2,1c-34,33-14e,4,36-,13-,6-2,1a-f,4,9-,3-,17,8,2-2,5-,2,8-,3-,4-8,2-3,3,6-,16-6,2-,7-3,3-,17,8,3,3,3-,2,6-3,3-,4-a,5,2-6,10-b,4,8,2,4,17,8,3,6-,b,4,4-,2-e,2-4,b-10,4,9-,3-,17,8,3-,5-,9-2,3-,4-7,3-3,3,4-3,c-10,3,7-2,4,5-2,3,2,3-2,3-2,4-2,9,4-3,6-2,4,5-8,2-e,d-d,4,9,4,18,b,6-3,8,4,5-6,3-8,3-3,b-11,3,9,4,18,b,6-3,8,4,5-6,3-6,2,3-3,b-11,3,9,4,18,11-3,7-,4,5-8,2-7,3-3,b-11,3,13-2,19,a,2-,8-2,2-3,7,2,9-11,4-b,3b-3,1e-24,3,2-,3,2-,2-5,5,8,4,2,2-,3,e,4-,6,2,7-,b-,3-21,49,23-5,1c-3,9,25,10-,2-2f,23,6,3,8-2,5-5,1b-45,27-9,2a-,2-3,5b-4,45-4,53-5,8,40,2,5-,8,2,5-,28,2,5-,20,2,5-,8,2,5-,8,8,18,20,2,5-,8,28,14-5,1d-22,56-b,277-8,1e-2,52-e,e,8-a,18-8,15-b,e,4,3-b,5e-2,b-15,10,b-5,59-7,2b-555,9d-3,5b-5,17-,7-,27-,7-,9,2,2,2,20-,36,10,f-,7,14-,4,a,54-3,2-6,6-5,9-,1c-10,13-1d,1c-14,3c-,10-6,32-b,240-30,28-18,c-14,a0,115-,3,66-,b-76,5,5-,1d,24,2,5-2,2,8-,35-2,19,f-10,1d-3,311-37f,1b,5a-b,d7-19,d-3,41,57-,68-4,29-3,5f,29-37,2e-2,25-c,2c-2,4e-3,30,78-3,64-,20,19b7-49,51a7-59,48e-2,38-738,2ba5-5b,222f-,3c-94,8-b,6-4,1b,6,2,3,3,6d-20,16e-f,41-,37-7,2e-2,11-f,5-b,18-,b,14,5-3,6,88-,2,bf-2,7-,7-,7-,4-2,8,8-9,8-2ff,20,5-b,1c-b4,27-,27-cbb1,f7-9,28-2,b5-221,56,48,3-,2-,3-,5,d,2,5,3,42,5-,9,8,1d,5,6,2-2,8,153-3,123-3,33-27fd,a6da-5128,21f-5df,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3-fffd,3,2-1d,61-ff7d"),s="ad,34f,1806,180b,180c,180d,200b,200c,200d,2060,feff".split(",").map((function(e){return parseInt(e,16)})),f=[{h:25,s:32,l:65},{h:30,s:32,e:[23],l:127},{h:54,s:1,e:[48],l:64,d:2},{h:14,s:1,l:57,d:2},{h:44,s:1,l:17,d:2},{h:10,s:1,e:[2,6,8],l:61,d:2},{h:16,s:1,l:68,d:2},{h:84,s:1,e:[18,24,66],l:19,d:2},{h:26,s:32,e:[17],l:435},{h:22,s:1,l:71,d:2},{h:15,s:80,l:40},{h:31,s:32,l:16},{h:32,s:1,l:80,d:2},{h:52,s:1,l:42,d:2},{h:12,s:1,l:55,d:2},{h:40,s:1,e:[38],l:15,d:2},{h:14,s:1,l:48,d:2},{h:37,s:48,l:49},{h:148,s:1,l:6351,d:2},{h:88,s:1,l:160,d:2},{h:15,s:16,l:704},{h:25,s:26,l:854},{h:25,s:32,l:55915},{h:37,s:40,l:1247},{h:25,s:-119711,l:53248},{h:25,s:-119763,l:52},{h:25,s:-119815,l:52},{h:25,s:-119867,e:[1,4,5,7,8,11,12,17],l:52},{h:25,s:-119919,l:52},{h:24,s:-119971,e:[2,7,8,17],l:52},{h:24,s:-120023,e:[2,7,13,15,16,17],l:52},{h:25,s:-120075,l:52},{h:25,s:-120127,l:52},{h:25,s:-120179,l:52},{h:25,s:-120231,l:52},{h:25,s:-120283,l:52},{h:25,s:-120335,l:52},{h:24,s:-119543,e:[17],l:56},{h:24,s:-119601,e:[17],l:58},{h:24,s:-119659,e:[17],l:58},{h:24,s:-119717,e:[17],l:58},{h:24,s:-119775,e:[17],l:58}],d=a("b5:3bc,c3:ff,7:73,2:253,5:254,3:256,1:257,5:259,1:25b,3:260,1:263,2:269,1:268,5:26f,1:272,2:275,7:280,3:283,5:288,3:28a,1:28b,5:292,3f:195,1:1bf,29:19e,125:3b9,8b:3b2,1:3b8,1:3c5,3:3c6,1:3c0,1a:3ba,1:3c1,1:3c3,2:3b8,1:3b5,1bc9:3b9,1c:1f76,1:1f77,f:1f7a,1:1f7b,d:1f78,1:1f79,1:1f7c,1:1f7d,107:63,5:25b,4:68,1:68,1:68,3:69,1:69,1:6c,3:6e,4:70,1:71,1:72,1:72,1:72,7:7a,2:3c9,2:7a,2:6b,1:e5,1:62,1:63,3:65,1:66,2:6d,b:3b3,1:3c0,6:64,1b574:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3,20:3b8,1a:3c3"),u=a("179:1,2:1,2:1,5:1,2:1,a:4f,a:1,8:1,2:1,2:1,3:1,5:1,3:1,4:1,2:1,3:1,4:1,8:2,1:1,2:2,1:1,2:2,27:2,195:26,2:25,1:25,1:25,2:40,2:3f,1:3f,33:1,11:-6,1:-9,1ac7:-3a,6d:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,b:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,c:-8,2:-8,2:-8,2:-8,9:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,1:-8,49:-8,1:-8,1:-4a,1:-4a,d:-56,1:-56,1:-56,1:-56,d:-8,1:-8,f:-8,1:-8,3:-7"),l=a("df:00730073,51:00690307,19:02BC006E,a7:006A030C,18a:002003B9,16:03B903080301,20:03C503080301,1d7:05650582,190f:00680331,1:00740308,1:0077030A,1:0079030A,1:006102BE,b6:03C50313,2:03C503130300,2:03C503130301,2:03C503130342,2a:1F0003B9,1:1F0103B9,1:1F0203B9,1:1F0303B9,1:1F0403B9,1:1F0503B9,1:1F0603B9,1:1F0703B9,1:1F0003B9,1:1F0103B9,1:1F0203B9,1:1F0303B9,1:1F0403B9,1:1F0503B9,1:1F0603B9,1:1F0703B9,1:1F2003B9,1:1F2103B9,1:1F2203B9,1:1F2303B9,1:1F2403B9,1:1F2503B9,1:1F2603B9,1:1F2703B9,1:1F2003B9,1:1F2103B9,1:1F2203B9,1:1F2303B9,1:1F2403B9,1:1F2503B9,1:1F2603B9,1:1F2703B9,1:1F6003B9,1:1F6103B9,1:1F6203B9,1:1F6303B9,1:1F6403B9,1:1F6503B9,1:1F6603B9,1:1F6703B9,1:1F6003B9,1:1F6103B9,1:1F6203B9,1:1F6303B9,1:1F6403B9,1:1F6503B9,1:1F6603B9,1:1F6703B9,3:1F7003B9,1:03B103B9,1:03AC03B9,2:03B10342,1:03B1034203B9,5:03B103B9,6:1F7403B9,1:03B703B9,1:03AE03B9,2:03B70342,1:03B7034203B9,5:03B703B9,6:03B903080300,1:03B903080301,3:03B90342,1:03B903080342,b:03C503080300,1:03C503080301,1:03C10313,2:03C50342,1:03C503080342,b:1F7C03B9,1:03C903B9,1:03CE03B9,2:03C90342,1:03C9034203B9,5:03C903B9,ac:00720073,5b:00B00063,6:00B00066,d:006E006F,a:0073006D,1:00740065006C,1:0074006D,124f:006800700061,2:00610075,2:006F0076,b:00700061,1:006E0061,1:03BC0061,1:006D0061,1:006B0061,1:006B0062,1:006D0062,1:00670062,3:00700066,1:006E0066,1:03BC0066,4:0068007A,1:006B0068007A,1:006D0068007A,1:00670068007A,1:00740068007A,15:00700061,1:006B00700061,1:006D00700061,1:006700700061,8:00700076,1:006E0076,1:03BC0076,1:006D0076,1:006B0076,1:006D0076,1:00700077,1:006E0077,1:03BC0077,1:006D0077,1:006B0077,1:006D0077,1:006B03C9,1:006D03C9,2:00620071,3:00632215006B0067,1:0063006F002E,1:00640062,1:00670079,2:00680070,2:006B006B,1:006B006D,9:00700068,2:00700070006D,1:00700072,2:00730076,1:00770062,c723:00660066,1:00660069,1:0066006C,1:006600660069,1:00660066006C,1:00730074,1:00730074,d:05740576,1:05740565,1:0574056B,1:057E0576,1:0574056D",(function(e){if(e.length%4!==0)throw new Error("bad data");for(var t=[],r=0;r=0)return[];if(e>=65024&&e<=65039)return[];var t=function(e){var t=o(e,f);if(t)return[e+t.s];var r=d[e];if(r)return r;var n=u[e];if(n)return[e+n[0]];var a=l[e];return a||null}(e);return t||[e]})),r=t.reduce((function(e,t){return t.forEach((function(t){e.push(t)})),e}),[]),(r=Object(n.g)(Object(n.e)(r),n.a.NFKC)).forEach((function(e){if(o(e,b))throw new Error("STRINGPREP_CONTAINS_PROHIBITED")})),r.forEach((function(e){if(o(e,c))throw new Error("STRINGPREP_CONTAINS_UNASSIGNED")}));var a=Object(n.e)(r);if("-"===a.substring(0,1)||"--"===a.substring(2,4)||"-"===a.substring(a.length-1))throw new Error("invalid hyphen");if(a.length>63)throw new Error("too long");return a}},,function(e,t,r){"use strict";t.a=function(e){function t(e,t,n){var a=t.trim().split(h);t=a;var i=a.length,o=e.length;switch(o){case 0:case 1:var c=0;for(e=0===o?"":e[0]+" ";cn&&(n=(t=t.trim()).charCodeAt(0)),n){case 38:return t.replace(p,"$1"+e.trim());case 58:return e.trim()+t.replace(p,"$1"+e.trim());default:if(0<1*r&&0s.charCodeAt(8))break;case 115:o=o.replace(s,"-webkit-"+s)+";"+o;break;case 207:case 102:o=o.replace(s,"-webkit-"+(102c.charCodeAt(0)&&(c=c.trim()),c=[c],0b)&&(D=(H=H.replace(" ",":")).length),0-1},ce.prototype.set=function(e,t){var r=this.__data__,n=le(r,e);return n<0?r.push([e,t]):r[n][1]=t,this},se.prototype.clear=function(){this.__data__={hash:new oe,map:new(X||ce),string:new oe}},se.prototype.delete=function(e){return Ee(this,e).delete(e)},se.prototype.get=function(e){return Ee(this,e).get(e)},se.prototype.has=function(e){return Ee(this,e).has(e)},se.prototype.set=function(e,t){return Ee(this,e).set(e,t),this},fe.prototype.add=fe.prototype.push=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this},fe.prototype.has=function(e){return this.__data__.has(e)},de.prototype.clear=function(){this.__data__=new ce},de.prototype.delete=function(e){return this.__data__.delete(e)},de.prototype.get=function(e){return this.__data__.get(e)},de.prototype.has=function(e){return this.__data__.has(e)},de.prototype.set=function(e,t){var r=this.__data__;if(r instanceof ce){var n=r.__data__;if(!X||n.length<199)return n.push([e,t]),this;r=this.__data__=new se(n)}return r.set(e,t),this};var be,he,pe=(be=function(e,t){return e&&me(e,t,Ke)},function(e,t){if(null==e)return e;if(!ze(e))return be(e,t);for(var r=e.length,n=he?r:-1,a=Object(e);(he?n--:++nc))return!1;var f=i.get(e);if(f&&i.get(t))return f==t;var d=-1,u=!0,l=1&a?new fe:void 0;for(i.set(e,t),i.set(t,e);++d-1&&e%1==0&&e-1&&e%1==0&&e<=9007199254740991}function Je(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function Ve(e){return!!e&&"object"==typeof e}function Ge(e){return"symbol"==typeof e||Ve(e)&&"[object Symbol]"==F.call(e)}var Xe=k?function(e){return function(t){return e(t)}}(k):function(e){return Ve(e)&&qe(e.length)&&!!h[F.call(e)]};function Ke(e){return ze(e)?ue(e):ke(e)}function We(e){return e}r.exports=function(e,t){return function e(t,r,n,a,i){var o=-1,c=t.length;for(n||(n=Te),i||(i=[]);++o0&&n(s)?r>1?e(s,r-1,n,a,i):M(i,s):a||(i[i.length]=s)}return i}(function(e,t){return(Ue(e)?_:_e)(e,we(t))}(e,t),1)}}).call(this,r(44),r(74)(e))},function(e,t,r){"use strict";function n(e){return"/"===e.charAt(0)}function a(e,t){for(var r=t,n=r+1,a=e.length;n=0;l--){var b=o[l];"."===b?a(o,l):".."===b?(a(o,l),u++):u&&(a(o,l),u--)}if(!f)for(;u--;u)o.unshift("..");!f||""===o[0]||o[0]&&n(o[0])||o.unshift("");var h=o.join("/");return r&&"/"!==h.substr(-1)&&(h+="/"),h}},function(e,t,r){"use strict";function n(e){return e.valueOf?e.valueOf():Object.prototype.valueOf.call(e)}t.a=function e(t,r){if(t===r)return!0;if(null==t||null==r)return!1;if(Array.isArray(t))return Array.isArray(r)&&t.length===r.length&&t.every((function(t,n){return e(t,r[n])}));if("object"===typeof t||"object"===typeof r){var a=n(t),i=n(r);return a!==t||i!==r?e(a,i):Object.keys(Object.assign({},t,r)).every((function(n){return e(t[n],r[n])}))}return!1}},function(e,t,r){"use strict";(function(e){var r="object"==typeof e&&e&&e.Object===Object&&e;t.a=r}).call(this,r(44))},,,function(e,t,r){"use strict";r.d(t,"a",(function(){return a})),r.d(t,"b",(function(){return i}));var n=r(0);function a(e){return Object(n.a)({tag:"svg",attr:{viewBox:"0 0 448 512"},child:[{tag:"path",attr:{d:"M446.7 98.6l-67.6 318.8c-5.1 22.5-18.4 28.1-37.3 17.5l-103-75.9-49.7 47.8c-5.5 5.5-10.1 10.1-20.7 10.1l7.4-104.9 190.9-172.5c8.3-7.4-1.8-11.5-12.9-4.1L117.8 284 16.2 252.2c-22.1-6.9-22.5-22.1 4.6-32.7L418.2 66.4c18.4-6.9 34.5 4.1 28.5 32.2z"}}]})(e)}function i(e){return Object(n.a)({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M461.2 128H80c-8.84 0-16-7.16-16-16s7.16-16 16-16h384c8.84 0 16-7.16 16-16 0-26.51-21.49-48-48-48H64C28.65 32 0 60.65 0 96v320c0 35.35 28.65 64 64 64h397.2c28.02 0 50.8-21.53 50.8-48V176c0-26.47-22.78-48-50.8-48zM416 336c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32z"}}]})(e)}},function(e,t,r){"use strict";var n=r(1148),a=r(1158),i=r(359);e.exports={formats:i,parse:a,stringify:n}},function(e,t,r){"use strict";r.d(t,"a",(function(){return c}));var n=r(1),a=r(280),i=Object(a.a)()?n.useLayoutEffect:n.useEffect;var o=r(80),c=function(e){var t=e.children,r=e.type,a=void 0===r?"reach-portal":r,c=Object(n.useRef)(null),s=Object(n.useRef)(null),f=function(){var e=Object(n.useState)(Object.create(null))[1];return Object(n.useCallback)((function(){e(Object.create(null))}),[])}();return i((function(){if(c.current){var e=c.current.ownerDocument;return s.current=null==e?void 0:e.createElement(a),e.body.appendChild(s.current),f(),function(){s.current&&s.current.ownerDocument&&s.current.ownerDocument.body.removeChild(s.current)}}}),[a,f]),s.current?Object(o.createPortal)(t,s.current):Object(n.createElement)("span",{ref:c})};t.b=c},function(e,t,r){"use strict";r.d(t,"a",(function(){return Mr}));var n=r(26),a=r(54),i=r(55),o=r(71),c=r(85);var s=r(146);function f(e){var t=function(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var r,n=Object(c.a)(e);if(t){var a=Object(c.a)(this).constructor;r=Reflect.construct(n,arguments,a)}else r=n.apply(this,arguments);return Object(s.a)(this,r)}}var d=r(1),u=r.n(d),l={};function b(e,t){0}function h(e,t,r){t||l[r]||(e(!1,r),l[r]=!0)}var p=function(e,t){h(b,e,t)},m=r(31),v=function(e){var t,r,a=e.className,i=e.included,o=e.vertical,c=e.style,s=e.length,f=e.offset,d=e.reverse;s<0&&(d=!d,s=Math.abs(s),f=100-f);var l=o?(t={},Object(m.a)(t,d?"top":"bottom","".concat(f,"%")),Object(m.a)(t,d?"bottom":"top","auto"),Object(m.a)(t,"height","".concat(s,"%")),t):(r={},Object(m.a)(r,d?"right":"left","".concat(f,"%")),Object(m.a)(r,d?"left":"right","auto"),Object(m.a)(r,"width","".concat(s,"%")),r),b=Object(n.a)(Object(n.a)({},c),l);return i?u.a.createElement("div",{className:a,style:b}):null},g=r(22),x=r(50);function y(e,t){if(null==e)return{};var r,n,a=Object(x.a)(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(n=0;n=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}function w(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r0,"`Slider[step]` should be a positive number in order to make Slider[dots] work.");var o=Object.keys(t).map(parseFloat).sort((function(e,t){return e-t}));if(r&&n)for(var c=a;c<=i;c+=n)-1===o.indexOf(c)&&o.push(c);return o}(0,i,o,c,b,l).map((function(e){var i,o="".concat(Math.abs(e-b)/g*100,"%"),c=!s&&e===d||s&&e<=d&&e>=f,l=r?Object(n.a)(Object(n.a)({},h),{},Object(m.a)({},a?"top":"bottom",o)):Object(n.a)(Object(n.a)({},h),{},Object(m.a)({},a?"right":"left",o));c&&(l=Object(n.a)(Object(n.a)({},l),v));var p=j()((i={},Object(m.a)(i,"".concat(t,"-dot"),!0),Object(m.a)(i,"".concat(t,"-dot-active"),c),Object(m.a)(i,"".concat(t,"-dot-reverse"),a),i));return u.a.createElement("span",{className:p,style:l,key:e})}));return u.a.createElement("div",{className:"".concat(t,"-step")},x)},C=r(65),R=function(e){var t=e.className,r=e.vertical,a=e.reverse,i=e.marks,o=e.included,c=e.upperBound,s=e.lowerBound,f=e.max,d=e.min,l=e.onClickLabel,b=Object.keys(i),h=f-d,p=b.map(parseFloat).sort((function(e,t){return e-t})).map((function(e){var f,b=i[e],p="object"===Object(C.a)(b)&&!u.a.isValidElement(b),v=p?b.label:b;if(!v&&0!==v)return null;var g=!o&&e===c||o&&e<=c&&e>=s,x=j()((f={},Object(m.a)(f,"".concat(t,"-text"),!0),Object(m.a)(f,"".concat(t,"-text-active"),g),f)),y=Object(m.a)({marginBottom:"-50%"},a?"top":"bottom","".concat((e-d)/h*100,"%")),w=Object(m.a)({transform:"translateX(".concat(a?"50%":"-50%",")"),msTransform:"translateX(".concat(a?"50%":"-50%",")")},a?"right":"left","".concat((e-d)/h*100,"%")),k=r?y:w,_=p?Object(n.a)(Object(n.a)({},k),b.style):k;return u.a.createElement("span",{className:x,style:_,key:e,onMouseDown:function(t){return l(t,e)},onTouchStart:function(t){return l(t,e)}},v)}));return u.a.createElement("div",{className:t},p)},N=function(e){Object(o.a)(r,e);var t=f(r);function r(){var e;return Object(a.a)(this,r),(e=t.apply(this,arguments)).state={clickFocused:!1},e.setHandleRef=function(t){e.handle=t},e.handleMouseUp=function(){document.activeElement===e.handle&&e.setClickFocus(!0)},e.handleMouseDown=function(t){t.preventDefault(),e.focus()},e.handleBlur=function(){e.setClickFocus(!1)},e.handleKeyDown=function(){e.setClickFocus(!1)},e}return Object(i.a)(r,[{key:"componentDidMount",value:function(){this.onMouseUpListener=A(document,"mouseup",this.handleMouseUp)}},{key:"componentWillUnmount",value:function(){this.onMouseUpListener&&this.onMouseUpListener.remove()}},{key:"setClickFocus",value:function(e){this.setState({clickFocused:e})}},{key:"clickFocus",value:function(){this.setClickFocus(!0),this.focus()}},{key:"focus",value:function(){this.handle.focus()}},{key:"blur",value:function(){this.handle.blur()}},{key:"render",value:function(){var e,t,r,a=this.props,i=a.prefixCls,o=a.vertical,c=a.reverse,s=a.offset,f=a.style,d=a.disabled,l=a.min,b=a.max,h=a.value,p=a.tabIndex,v=a.ariaLabel,x=a.ariaLabelledBy,w=a.ariaValueTextFormatter,k=y(a,["prefixCls","vertical","reverse","offset","style","disabled","min","max","value","tabIndex","ariaLabel","ariaLabelledBy","ariaValueTextFormatter"]),_=j()(this.props.className,Object(m.a)({},"".concat(i,"-handle-click-focused"),this.state.clickFocused)),M=o?(e={},Object(m.a)(e,c?"top":"bottom","".concat(s,"%")),Object(m.a)(e,c?"bottom":"top","auto"),Object(m.a)(e,"transform",c?null:"translateY(+50%)"),e):(t={},Object(m.a)(t,c?"right":"left","".concat(s,"%")),Object(m.a)(t,c?"left":"right","auto"),Object(m.a)(t,"transform","translateX(".concat(c?"+":"-","50%)")),t),S=Object(n.a)(Object(n.a)({},f),M),E=p||0;return(d||null===p)&&(E=null),w&&(r=w(h)),u.a.createElement("div",Object(g.a)({ref:this.setHandleRef,tabIndex:E},k,{className:_,style:S,onBlur:this.handleBlur,onKeyDown:this.handleKeyDown,onMouseDown:this.handleMouseDown,role:"slider","aria-valuemin":l,"aria-valuemax":b,"aria-valuenow":h,"aria-disabled":!!d,"aria-label":v,"aria-labelledby":x,"aria-valuetext":r}))}}]),r}(u.a.Component),B={MAC_ENTER:3,BACKSPACE:8,TAB:9,NUM_CENTER:12,ENTER:13,SHIFT:16,CTRL:17,ALT:18,PAUSE:19,CAPS_LOCK:20,ESC:27,SPACE:32,PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,PRINT_SCREEN:44,INSERT:45,DELETE:46,ZERO:48,ONE:49,TWO:50,THREE:51,FOUR:52,FIVE:53,SIX:54,SEVEN:55,EIGHT:56,NINE:57,QUESTION_MARK:63,A:65,B:66,C:67,D:68,E:69,F:70,G:71,H:72,I:73,J:74,K:75,L:76,M:77,N:78,O:79,P:80,Q:81,R:82,S:83,T:84,U:85,V:86,W:87,X:88,Y:89,Z:90,META:91,WIN_KEY_RIGHT:92,CONTEXT_MENU:93,NUM_ZERO:96,NUM_ONE:97,NUM_TWO:98,NUM_THREE:99,NUM_FOUR:100,NUM_FIVE:101,NUM_SIX:102,NUM_SEVEN:103,NUM_EIGHT:104,NUM_NINE:105,NUM_MULTIPLY:106,NUM_PLUS:107,NUM_MINUS:109,NUM_PERIOD:110,NUM_DIVISION:111,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,NUMLOCK:144,SEMICOLON:186,DASH:189,EQUALS:187,COMMA:188,PERIOD:190,SLASH:191,APOSTROPHE:192,SINGLE_QUOTE:222,OPEN_SQUARE_BRACKET:219,BACKSLASH:220,CLOSE_SQUARE_BRACKET:221,WIN_KEY:224,MAC_FF_META:224,WIN_IME:229,isTextModifyingKeyEvent:function(e){var t=e.keyCode;if(e.altKey&&!e.ctrlKey||e.metaKey||t>=B.F1&&t<=B.F12)return!1;switch(t){case B.ALT:case B.CAPS_LOCK:case B.CONTEXT_MENU:case B.CTRL:case B.DOWN:case B.END:case B.ESC:case B.HOME:case B.INSERT:case B.LEFT:case B.MAC_FF_META:case B.META:case B.NUMLOCK:case B.NUM_CENTER:case B.PAGE_DOWN:case B.PAGE_UP:case B.PAUSE:case B.PRINT_SCREEN:case B.RIGHT:case B.SHIFT:case B.UP:case B.WIN_KEY:case B.WIN_KEY_RIGHT:return!1;default:return!0}},isCharacterKey:function(e){if(e>=B.ZERO&&e<=B.NINE)return!0;if(e>=B.NUM_ZERO&&e<=B.NUM_MULTIPLY)return!0;if(e>=B.A&&e<=B.Z)return!0;if(-1!==window.navigator.userAgent.indexOf("WebKit")&&0===e)return!0;switch(e){case B.SPACE:case B.QUESTION_MARK:case B.NUM_PLUS:case B.NUM_MINUS:case B.NUM_PERIOD:case B.NUM_DIVISION:case B.SEMICOLON:case B.DASH:case B.EQUALS:case B.COMMA:case B.PERIOD:case B.SLASH:case B.APOSTROPHE:case B.SINGLE_QUOTE:case B.OPEN_SQUARE_BRACKET:case B.BACKSLASH:case B.CLOSE_SQUARE_BRACKET:return!0;default:return!1}}},L=B;function I(e,t){try{return Object.keys(t).some((function(r){return e.target===Object(E.findDOMNode)(t[r])}))}catch(r){return!1}}function F(e,t){var r=t.min,n=t.max;return en}function D(e){return e.touches.length>1||"touchend"===e.type.toLowerCase()&&e.touches.length>0}function U(e,t){var r=t.marks,n=t.step,a=t.min,i=t.max,o=Object.keys(r).map(parseFloat);if(null!==n){var c=Math.pow(10,z(n)),s=Math.floor((i*c-a*c)/(n*c)),f=Math.min((e-a)/n,s),d=Math.round(f)*n+a;o.push(d)}var u=o.map((function(t){return Math.abs(e-t)}));return o[u.indexOf(Math.min.apply(Math,_(u)))]}function z(e){var t=e.toString(),r=0;return t.indexOf(".")>=0&&(r=t.length-t.indexOf(".")-1),r}function H(e,t){return e?t.clientY:t.pageX}function q(e,t){return e?t.touches[0].clientY:t.touches[0].pageX}function J(e,t){var r=t.getBoundingClientRect();return e?r.top+.5*r.height:window.pageXOffset+r.left+.5*r.width}function V(e,t){var r=t.max,n=t.min;return e<=n?n:e>=r?r:e}function G(e,t){var r=t.step,n=isFinite(U(e,t))?U(e,t):0;return null===r?n:parseFloat(n.toFixed(z(r)))}function X(e){e.stopPropagation(),e.preventDefault()}function K(e,t,r){var n="increase";switch(e.keyCode){case L.UP:n=t&&r?"decrease":"increase";break;case L.RIGHT:n=!t&&r?"decrease":"increase";break;case L.DOWN:n=t&&r?"increase":"decrease";break;case L.LEFT:n=!t&&r?"increase":"decrease";break;case L.END:return function(e,t){return t.max};case L.HOME:return function(e,t){return t.min};case L.PAGE_UP:return function(e,t){return e+2*t.step};case L.PAGE_DOWN:return function(e,t){return e-2*t.step};default:return}return function(e,t){return function(e,t,r){var n={increase:function(e,t){return e+t},decrease:function(e,t){return e-t}},a=n[e](Object.keys(r.marks).indexOf(JSON.stringify(t)),1),i=Object.keys(r.marks)[a];return r.step?n[e](t,r.step):Object.keys(r.marks).length&&r.marks[i]?r.marks[i]:t}(n,e,t)}}function W(){}function Z(e){var t;return(t=function(e){Object(o.a)(r,e);var t=f(r);function r(e){var n;Object(a.a)(this,r),(n=t.call(this,e)).onDown=function(e,t){var r=t,a=n.props,i=a.draggableTrack,o=a.vertical,c=n.state.bounds,s=i&&n.positionGetValue&&n.positionGetValue(r)||[],f=I(e,n.handlesRefs);if(n.dragTrack=i&&c.length>=2&&!f&&!s.map((function(e,t){var r=!!t||e>=c[t];return t===s.length-1?e<=c[t]:r})).some((function(e){return!e})),n.dragTrack)n.dragOffset=r,n.startBounds=_(c);else{if(f){var d=J(o,e.target);n.dragOffset=r-d,r=d}else n.dragOffset=0;n.onStart(r)}},n.onMouseDown=function(e){if(0===e.button){n.removeDocumentEvents();var t=H(n.props.vertical,e);n.onDown(e,t),n.addDocumentMouseEvents()}},n.onTouchStart=function(e){if(!D(e)){var t=q(n.props.vertical,e);n.onDown(e,t),n.addDocumentTouchEvents(),X(e)}},n.onFocus=function(e){var t=n.props,r=t.onFocus,a=t.vertical;if(I(e,n.handlesRefs)&&!n.dragTrack){var i=J(a,e.target);n.dragOffset=0,n.onStart(i),X(e),r&&r(e)}},n.onBlur=function(e){var t=n.props.onBlur;n.dragTrack||n.onEnd(),t&&t(e)},n.onMouseUp=function(){n.handlesRefs[n.prevMovedHandleIndex]&&n.handlesRefs[n.prevMovedHandleIndex].clickFocus()},n.onMouseMove=function(e){if(n.sliderRef){var t=H(n.props.vertical,e);n.onMove(e,t-n.dragOffset,n.dragTrack,n.startBounds)}else n.onEnd()},n.onTouchMove=function(e){if(!D(e)&&n.sliderRef){var t=q(n.props.vertical,e);n.onMove(e,t-n.dragOffset,n.dragTrack,n.startBounds)}else n.onEnd()},n.onKeyDown=function(e){n.sliderRef&&I(e,n.handlesRefs)&&n.onKeyboard(e)},n.onClickMarkLabel=function(e,t){e.stopPropagation(),n.onChange({value:t}),n.setState({value:t},(function(){return n.onEnd(!0)}))},n.saveSlider=function(e){n.sliderRef=e};var i=e.step,o=e.max,c=e.min,s=!isFinite(o-c)||(o-c)%i===0;return p(!i||Math.floor(i)!==i||s,"Slider[max] - Slider[min] (".concat(o-c,") should be a multiple of Slider[step] (").concat(i,")")),n.handlesRefs={},n}return Object(i.a)(r,[{key:"componentDidMount",value:function(){this.document=this.sliderRef&&this.sliderRef.ownerDocument;var e=this.props,t=e.autoFocus,r=e.disabled;t&&!r&&this.focus()}},{key:"componentWillUnmount",value:function(){S(Object(c.a)(r.prototype),"componentWillUnmount",this)&&S(Object(c.a)(r.prototype),"componentWillUnmount",this).call(this),this.removeDocumentEvents()}},{key:"getSliderStart",value:function(){var e=this.sliderRef,t=this.props,r=t.vertical,n=t.reverse,a=e.getBoundingClientRect();return r?n?a.bottom:a.top:window.pageXOffset+(n?a.right:a.left)}},{key:"getSliderLength",value:function(){var e=this.sliderRef;if(!e)return 0;var t=e.getBoundingClientRect();return this.props.vertical?t.height:t.width}},{key:"addDocumentTouchEvents",value:function(){this.onTouchMoveListener=A(this.document,"touchmove",this.onTouchMove),this.onTouchUpListener=A(this.document,"touchend",this.onEnd)}},{key:"addDocumentMouseEvents",value:function(){this.onMouseMoveListener=A(this.document,"mousemove",this.onMouseMove),this.onMouseUpListener=A(this.document,"mouseup",this.onEnd)}},{key:"removeDocumentEvents",value:function(){this.onTouchMoveListener&&this.onTouchMoveListener.remove(),this.onTouchUpListener&&this.onTouchUpListener.remove(),this.onMouseMoveListener&&this.onMouseMoveListener.remove(),this.onMouseUpListener&&this.onMouseUpListener.remove()}},{key:"focus",value:function(){var e;this.props.disabled||null===(e=this.handlesRefs[0])||void 0===e||e.focus()}},{key:"blur",value:function(){var e=this;this.props.disabled||Object.keys(this.handlesRefs).forEach((function(t){var r,n;null===(r=e.handlesRefs[t])||void 0===r||null===(n=r.blur)||void 0===n||n.call(r)}))}},{key:"calcValue",value:function(e){var t=this.props,r=t.vertical,n=t.min,a=t.max,i=Math.abs(Math.max(e,0)/this.getSliderLength());return r?(1-i)*(a-n)+n:i*(a-n)+n}},{key:"calcValueByPos",value:function(e){var t=(this.props.reverse?-1:1)*(e-this.getSliderStart());return this.trimAlignValue(this.calcValue(t))}},{key:"calcOffset",value:function(e){var t=this.props,r=t.min,n=(e-r)/(t.max-r);return Math.max(0,100*n)}},{key:"saveHandle",value:function(e,t){this.handlesRefs[e]=t}},{key:"render",value:function(){var e,t=this.props,a=t.prefixCls,i=t.className,o=t.marks,s=t.dots,f=t.step,d=t.included,l=t.disabled,b=t.vertical,h=t.reverse,p=t.min,v=t.max,g=t.children,x=t.maximumTrackStyle,y=t.style,w=t.railStyle,k=t.dotStyle,_=t.activeDotStyle,M=S(Object(c.a)(r.prototype),"render",this).call(this),E=M.tracks,O=M.handles,A=j()(a,(e={},Object(m.a)(e,"".concat(a,"-with-marks"),Object.keys(o).length),Object(m.a)(e,"".concat(a,"-disabled"),l),Object(m.a)(e,"".concat(a,"-vertical"),b),Object(m.a)(e,i,i),e));return u.a.createElement("div",{ref:this.saveSlider,className:A,onTouchStart:l?W:this.onTouchStart,onMouseDown:l?W:this.onMouseDown,onMouseUp:l?W:this.onMouseUp,onKeyDown:l?W:this.onKeyDown,onFocus:l?W:this.onFocus,onBlur:l?W:this.onBlur,style:y},u.a.createElement("div",{className:"".concat(a,"-rail"),style:Object(n.a)(Object(n.a)({},x),w)}),E,u.a.createElement(P,{prefixCls:a,vertical:b,reverse:h,marks:o,dots:s,step:f,included:d,lowerBound:this.getLowerBound(),upperBound:this.getUpperBound(),max:v,min:p,dotStyle:k,activeDotStyle:_}),O,u.a.createElement(R,{className:"".concat(a,"-mark"),onClickLabel:l?W:this.onClickMarkLabel,vertical:b,marks:o,included:d,lowerBound:this.getLowerBound(),upperBound:this.getUpperBound(),max:v,min:p,reverse:h}),g)}}]),r}(e)).displayName="ComponentEnhancer(".concat(e.displayName,")"),t.defaultProps=Object(n.a)(Object(n.a)({},e.defaultProps),{},{prefixCls:"rc-slider",className:"",min:0,max:100,step:1,marks:{},handle:function(e){var t=e.index,r=y(e,["index"]);return delete r.dragging,null===r.value?null:u.a.createElement(N,Object(g.a)({},r,{key:t}))},onBeforeChange:W,onChange:W,onAfterChange:W,included:!0,disabled:!1,dots:!1,vertical:!1,reverse:!1,trackStyle:[{}],handleStyle:[{}],railStyle:{},dotStyle:{},activeDotStyle:{}}),t}var $=Z(function(e){Object(o.a)(r,e);var t=f(r);function r(e){var n;Object(a.a)(this,r),(n=t.call(this,e)).positionGetValue=function(e){return[]},n.onEnd=function(e){var t=n.state.dragging;n.removeDocumentEvents(),(t||e)&&n.props.onAfterChange(n.getValue()),n.setState({dragging:!1})};var i=void 0!==e.defaultValue?e.defaultValue:e.min,o=void 0!==e.value?e.value:i;return n.state={value:n.trimAlignValue(o),dragging:!1},p(!("minimumTrackStyle"in e),"minimumTrackStyle will be deprecated, please use trackStyle instead."),p(!("maximumTrackStyle"in e),"maximumTrackStyle will be deprecated, please use railStyle instead."),n}return Object(i.a)(r,[{key:"calcValueByPos",value:function(e){return 0}},{key:"calcOffset",value:function(e){return 0}},{key:"saveHandle",value:function(e,t){}},{key:"removeDocumentEvents",value:function(){}},{key:"componentDidUpdate",value:function(e,t){var r=this.props,n=r.min,a=r.max,i=r.value,o=r.onChange;if("min"in this.props||"max"in this.props){var c=void 0!==i?i:t.value,s=this.trimAlignValue(c,this.props);s!==t.value&&(this.setState({value:s}),n===e.min&&a===e.max||!F(c,this.props)||o(s))}}},{key:"onChange",value:function(e){var t=this.props,r=!("value"in t),a=e.value>this.props.max?Object(n.a)(Object(n.a)({},e),{},{value:this.props.max}):e;r&&this.setState(a);var i=a.value;t.onChange(i)}},{key:"onStart",value:function(e){this.setState({dragging:!0});var t=this.props,r=this.getValue();t.onBeforeChange(r);var n=this.calcValueByPos(e);this.startValue=n,this.startPosition=e,n!==r&&(this.prevMovedHandleIndex=0,this.onChange({value:n}))}},{key:"onMove",value:function(e,t){X(e);var r=this.state.value,n=this.calcValueByPos(t);n!==r&&this.onChange({value:n})}},{key:"onKeyboard",value:function(e){var t=this.props,r=t.reverse,n=K(e,t.vertical,r);if(n){X(e);var a=this.state.value,i=n(a,this.props),o=this.trimAlignValue(i);if(o===a)return;this.onChange({value:o}),this.props.onAfterChange(o),this.onEnd()}}},{key:"getValue",value:function(){return this.state.value}},{key:"getLowerBound",value:function(){var e=this.props.startPoint||this.props.min;return this.state.value>e?e:this.state.value}},{key:"getUpperBound",value:function(){return this.state.value1&&void 0!==arguments[1]?arguments[1]:{};if(null===e)return null;var r=Object(n.a)(Object(n.a)({},this.props),t),a=V(e,r);return G(a,r)}},{key:"render",value:function(){var e=this,t=this.props,r=t.prefixCls,a=t.vertical,i=t.included,o=t.disabled,c=t.minimumTrackStyle,s=t.trackStyle,f=t.handleStyle,d=t.tabIndex,l=t.ariaLabelForHandle,b=t.ariaLabelledByForHandle,h=t.ariaValueTextFormatterForHandle,p=t.min,m=t.max,g=t.startPoint,x=t.reverse,y=t.handle,w=this.state,k=w.value,_=w.dragging,M=this.calcOffset(k),S=y({className:"".concat(r,"-handle"),prefixCls:r,vertical:a,offset:M,value:k,dragging:_,disabled:o,min:p,max:m,reverse:x,index:0,tabIndex:d,ariaLabel:l,ariaLabelledBy:b,ariaValueTextFormatter:h,style:f[0]||f,ref:function(t){return e.saveHandle(0,t)}}),E=void 0!==g?this.calcOffset(g):0,O=s[0]||s;return{tracks:u.a.createElement(v,{className:"".concat(r,"-track"),vertical:a,included:i,offset:E,reverse:x,length:M-E,style:Object(n.a)(Object(n.a)({},c),O)}),handles:S}}}]),r}(u.a.Component)),Q=function(e){var t=e.value,r=e.handle,n=e.bounds,a=e.props,i=a.allowCross,o=a.pushable,c=Number(o),s=V(t,a),f=s;return i||null==r||void 0===n||(r>0&&s<=n[r-1]+c&&(f=n[r-1]+c),r=n[r+1]-c&&(f=n[r+1]-c)),G(f,a)},Y=function(e){Object(o.a)(r,e);var t=f(r);function r(e){var n;Object(a.a)(this,r),(n=t.call(this,e)).positionGetValue=function(e){var t=n.getValue(),r=n.calcValueByPos(e),a=n.getClosestBound(r),i=n.getBoundNeedMoving(r,a);if(r===t[i])return null;var o=_(t);return o[i]=r,o},n.onEnd=function(e){var t=n.state.handle;n.removeDocumentEvents(),t||(n.dragTrack=!1),(null!==t||e)&&n.props.onAfterChange(n.getValue()),n.setState({handle:null})};var i=e.count,o=e.min,c=e.max,s=Array.apply(void 0,_(Array(i+1))).map((function(){return o})),f="defaultValue"in e?e.defaultValue:s,d=(void 0!==e.value?e.value:f).map((function(t,r){return Q({value:t,handle:r,props:e})})),u=d[0]===c?0:d.length-1;return n.state={handle:null,recent:u,bounds:d},n}return Object(i.a)(r,[{key:"calcValueByPos",value:function(e){return 0}},{key:"getSliderLength",value:function(){return 0}},{key:"calcOffset",value:function(e){return 0}},{key:"saveHandle",value:function(e,t){}},{key:"removeDocumentEvents",value:function(){}},{key:"componentDidUpdate",value:function(e,t){var r=this,n=this.props,a=n.onChange,i=n.value,o=n.min,c=n.max;if(("min"in this.props||"max"in this.props)&&(o!==e.min||c!==e.max)){var s=i||t.bounds;if(s.some((function(e){return F(e,r.props)})))a(s.map((function(e){return V(e,r.props)})))}}},{key:"onChange",value:function(e){var t=this.props;if(!("value"in t))this.setState(e);else{var r={};["handle","recent"].forEach((function(t){void 0!==e[t]&&(r[t]=e[t])})),Object.keys(r).length&&this.setState(r)}var a=Object(n.a)(Object(n.a)({},this.state),e).bounds;t.onChange(a)}},{key:"onStart",value:function(e){var t=this.props,r=this.state,n=this.getValue();t.onBeforeChange(n);var a=this.calcValueByPos(e);this.startValue=a,this.startPosition=e;var i=this.getClosestBound(a);if(this.prevMovedHandleIndex=this.getBoundNeedMoving(a,i),this.setState({handle:this.prevMovedHandleIndex,recent:this.prevMovedHandleIndex}),a!==n[this.prevMovedHandleIndex]){var o=_(r.bounds);o[this.prevMovedHandleIndex]=a,this.onChange({bounds:o})}}},{key:"onMove",value:function(e,t,r,n){X(e);var a=this.state,i=this.props,o=i.max||100,c=i.min||0;if(r){var s=i.vertical?-t:t;s=i.reverse?-s:s;var f=o-Math.max.apply(Math,_(n)),d=c-Math.min.apply(Math,_(n)),u=Math.min(Math.max(s/(this.getSliderLength()/(o-c)),d),f),l=n.map((function(e){return Math.floor(Math.max(Math.min(e+u,o),c))}));a.bounds.map((function(e,t){return e===l[t]})).some((function(e){return!e}))&&this.onChange({bounds:l})}else{var b=this.calcValueByPos(t);b!==a.bounds[a.handle]&&this.moveTo(b)}}},{key:"onKeyboard",value:function(e){var t=this.props,r=t.reverse,n=K(e,t.vertical,r);if(n){X(e);var a=this.state,i=this.props,o=a.bounds,c=a.handle,s=o[null===c?a.recent:c],f=n(s,i),d=Q({value:f,handle:c,bounds:a.bounds,props:i});if(d===s)return;this.moveTo(d,!0)}}},{key:"getValue",value:function(){return this.state.bounds}},{key:"getClosestBound",value:function(e){for(var t=this.state.bounds,r=0,n=1;n=t[n]&&(r=n);return Math.abs(t[r+1]-e)=n.length||a<0)return!1;var i=t+r,o=n[a],c=this.props.pushable,s=Number(c),f=r*(e[i]-o);return!!this.pushHandle(e,i,r,s-f)&&(e[t]=o,!0)}},{key:"trimAlignValue",value:function(e){var t=this.state,r=t.handle,n=t.bounds;return Q({value:e,handle:r,bounds:n,props:this.props})}},{key:"render",value:function(){var e=this,t=this.state,r=t.handle,n=t.bounds,a=this.props,i=a.prefixCls,o=a.vertical,c=a.included,s=a.disabled,f=a.min,d=a.max,l=a.reverse,b=a.handle,h=a.trackStyle,p=a.handleStyle,g=a.tabIndex,x=a.ariaLabelGroupForHandles,y=a.ariaLabelledByGroupForHandles,w=a.ariaValueTextFormatterGroupForHandles,k=n.map((function(t){return e.calcOffset(t)})),_="".concat(i,"-handle"),M=n.map((function(t,n){var a,c=g[n]||0;(s||null===g[n])&&(c=null);var u=r===n;return b({className:j()((a={},Object(m.a)(a,_,!0),Object(m.a)(a,"".concat(_,"-").concat(n+1),!0),Object(m.a)(a,"".concat(_,"-dragging"),u),a)),prefixCls:i,vertical:o,dragging:u,offset:k[n],value:t,index:n,tabIndex:c,min:f,max:d,reverse:l,disabled:s,style:p[n],ref:function(t){return e.saveHandle(n,t)},ariaLabel:x[n],ariaLabelledBy:y[n],ariaValueTextFormatter:w[n]})}));return{tracks:n.slice(0,-1).map((function(e,t){var r,n=t+1,a=j()((r={},Object(m.a)(r,"".concat(i,"-track"),!0),Object(m.a)(r,"".concat(i,"-track-").concat(n),!0),r));return u.a.createElement(v,{className:a,vertical:o,reverse:l,included:c,offset:k[n-1],length:k[n]-k[n-1],style:h[t],key:n})})),handles:M}}}],[{key:"getDerivedStateFromProps",value:function(e,t){if(!("value"in e||"min"in e||"max"in e))return null;var r=e.value||t.bounds,a=r.map((function(r,n){return Q({value:r,handle:n,bounds:t.bounds,props:e})}));if(t.bounds.length===a.length){if(a.every((function(e,r){return e===t.bounds[r]})))return null}else a=r.map((function(t,r){return Q({value:t,handle:r,props:e})}));return Object(n.a)(Object(n.a)({},t),{},{bounds:a})}}]),r}(u.a.Component);Y.displayName="Range",Y.defaultProps={count:1,allowCross:!0,pushable:!1,draggableTrack:!1,tabIndex:[],ariaLabelGroupForHandles:[],ariaLabelledByGroupForHandles:[],ariaValueTextFormatterGroupForHandles:[]};var ee=Z(Y),te=r(73),re=function(e){return+setTimeout(e,16)},ne=function(e){return clearTimeout(e)};"undefined"!==typeof window&&"requestAnimationFrame"in window&&(re=function(e){return window.requestAnimationFrame(e)},ne=function(e){return window.cancelAnimationFrame(e)});var ae=0,ie=new Map;function oe(e){ie.delete(e)}function ce(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,r=ae+=1;function n(t){if(0===t)oe(r),e();else{var a=re((function(){n(t-1)}));ie.set(r,a)}}return n(t),r}function se(e,t){return!!e&&e.contains(t)}function fe(e){return e instanceof HTMLElement?e:O.a.findDOMNode(e)}ce.cancel=function(e){var t=ie.get(e);return oe(t),ne(t)};var de=r(558);function ue(e,t){"function"===typeof e?e(t):"object"===Object(C.a)(e)&&e&&"current"in e&&(e.current=t)}function le(){for(var e=arguments.length,t=new Array(e),r=0;r1&&void 0!==arguments[1]?arguments[1]:2;t();var i=ce((function(){a<=1?n({isCanceled:function(){return i!==e.current}}):r(n,a-1)}));e.current=i},t]}(),2),o=i[0],c=i[1];return je((function(){if("none"!==n&&"end"!==n){var e=Pe.indexOf(n),r=Pe[e+1],i=t(n);!1===i?a(r):o((function(e){function t(){e.isCanceled()||a(r)}!0===i?t():Promise.resolve(i).then(t)}))}}),[e,n]),d.useEffect((function(){return function(){c()}}),[]),[function(){a("prepare")},n]};function Ne(e,t,r,a){var i=a.motionEnter,o=void 0===i||i,c=a.motionAppear,s=void 0===c||c,f=a.motionLeave,u=void 0===f||f,l=a.motionDeadline,b=a.motionLeaveImmediately,h=a.onAppearPrepare,p=a.onEnterPrepare,v=a.onLeavePrepare,g=a.onAppearStart,x=a.onEnterStart,y=a.onLeaveStart,w=a.onAppearActive,k=a.onEnterActive,_=a.onLeaveActive,M=a.onAppearEnd,S=a.onEnterEnd,E=a.onLeaveEnd,O=a.onVisibleChanged,A=me(Te(),2),T=A[0],j=A[1],P=me(Te("none"),2),C=P[0],R=P[1],N=me(Te(null),2),B=N[0],L=N[1],I=Object(d.useRef)(!1),F=Object(d.useRef)(null),D=Object(d.useRef)(!1),U=Object(d.useRef)(null);function z(){return r()||U.current}var H=Object(d.useRef)(!1);function q(e){var t,r=z();e&&!e.deadline&&e.target!==r||("appear"===C&&H.current?t=null===M||void 0===M?void 0:M(r,e):"enter"===C&&H.current?t=null===S||void 0===S?void 0:S(r,e):"leave"===C&&H.current&&(t=null===E||void 0===E?void 0:E(r,e)),!1===t||D.current||(R("none"),L(null)))}var J=me(function(e){var t=Object(d.useRef)(),r=Object(d.useRef)(e);r.current=e;var n=d.useCallback((function(e){r.current(e)}),[]);function a(e){e&&(e.removeEventListener(Oe,n),e.removeEventListener(Ee,n))}return d.useEffect((function(){return function(){a(t.current)}}),[]),[function(e){t.current&&t.current!==e&&a(t.current),e&&e!==t.current&&(e.addEventListener(Oe,n),e.addEventListener(Ee,n),t.current=e)},a]}(q),1)[0],V=d.useMemo((function(){var e,t,r;switch(C){case"appear":return e={},Object(m.a)(e,"prepare",h),Object(m.a)(e,"start",g),Object(m.a)(e,"active",w),e;case"enter":return t={},Object(m.a)(t,"prepare",p),Object(m.a)(t,"start",x),Object(m.a)(t,"active",k),t;case"leave":return r={},Object(m.a)(r,"prepare",v),Object(m.a)(r,"start",y),Object(m.a)(r,"active",_),r;default:return{}}}),[C]),G=me(Re(C,(function(e){if("prepare"===e){var t=V.prepare;return!!t&&t(z())}var r;K in V&&L((null===(r=V[K])||void 0===r?void 0:r.call(V,z(),null))||null);return"active"===K&&(J(z()),l>0&&(clearTimeout(F.current),F.current=setTimeout((function(){q({deadline:!0})}),l))),!0})),2),X=G[0],K=G[1],W=Ce(K);H.current=W,je((function(){j(t);var r,n=I.current;(I.current=!0,e)&&(!n&&t&&s&&(r="appear"),n&&t&&o&&(r="enter"),(n&&!t&&u||!n&&b&&!t&&u)&&(r="leave"),r&&(R(r),X()))}),[t]),Object(d.useEffect)((function(){("appear"===C&&!s||"enter"===C&&!o||"leave"===C&&!u)&&R("none")}),[s,o,u]),Object(d.useEffect)((function(){return function(){clearTimeout(F.current),D.current=!0}}),[]),Object(d.useEffect)((function(){void 0!==T&&"none"===C&&(null===O||void 0===O||O(T))}),[T,C]);var Z=B;return V.prepare&&"start"===K&&(Z=Object(n.a)({transition:"none"},Z)),[C,K,Z,null!==T&&void 0!==T?T:t]}var Be=function(e){Object(o.a)(r,e);var t=f(r);function r(){return Object(a.a)(this,r),t.apply(this,arguments)}return Object(i.a)(r,[{key:"render",value:function(){return this.props.children}}]),r}(d.Component);var Le=function(e){var t=e;function r(e){return!(!e.motionName||!t)}"object"===Object(C.a)(e)&&(t=e.transitionSupport);var a=d.forwardRef((function(e,t){var a=e.visible,i=void 0===a||a,o=e.removeOnLeave,c=void 0===o||o,s=e.forceRender,f=e.children,u=e.motionName,l=e.leavedClassName,b=e.eventProps,h=r(e),p=Object(d.useRef)(),v=Object(d.useRef)();var g=me(Ne(h,i,(function(){try{return fe(p.current||v.current)}catch(e){return null}}),e),4),x=g[0],y=g[1],w=g[2],k=g[3],_=d.useRef(k);k&&(_.current=!0);var M=Object(d.useRef)(t);M.current=t;var S,E=d.useCallback((function(e){p.current=e,ue(M.current,e)}),[]),O=Object(n.a)(Object(n.a)({},b),{},{visible:i});if(f)if("none"!==x&&r(e)){var A,T;"prepare"===y?T="prepare":Ce(y)?T="active":"start"===y&&(T="start"),S=f(Object(n.a)(Object(n.a)({},O),{},{className:j()(Ae(u,x),(A={},Object(m.a)(A,Ae(u,"".concat(x,"-").concat(T)),T),Object(m.a)(A,u,"string"===typeof u),A)),style:w}),E)}else S=k?f(Object(n.a)({},O),E):!c&&_.current?f(Object(n.a)(Object(n.a)({},O),{},{className:l}),E):s?f(Object(n.a)(Object(n.a)({},O),{},{style:{display:"none"}}),E):null;else S=null;return d.createElement(Be,{ref:v},S)}));return a.displayName="CSSMotion",a}(Se);function Ie(e){var t;return t=e&&"object"===Object(C.a)(e)&&"key"in e?e:{key:e},Object(n.a)(Object(n.a)({},t),{},{key:String(t.key)})}function Fe(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return e.map(Ie)}function De(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],r=[],a=0,i=t.length,o=Fe(e),c=Fe(t);o.forEach((function(e){for(var t=!1,o=a;o1}));return f.forEach((function(e){(r=r.filter((function(t){var r=t.key,n=t.status;return r!==e||"remove"!==n}))).forEach((function(t){t.key===e&&(t.status="keep")}))})),r}var Ue=["eventProps","visible","children","motionName","motionAppear","motionEnter","motionLeave","motionLeaveImmediately","motionDeadline","removeOnLeave","leavedClassName","onAppearStart","onAppearActive","onAppearEnd","onEnterStart","onEnterActive","onEnterEnd","onLeaveStart","onLeaveActive","onLeaveEnd"];!function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Le,r=function(e){Object(o.a)(c,e);var r=f(c);function c(){var e;return Object(a.a)(this,c),(e=r.apply(this,arguments)).state={keyEntities:[]},e.removeKey=function(t){e.setState((function(e){return{keyEntities:e.keyEntities.map((function(e){return e.key!==t?e:Object(n.a)(Object(n.a)({},e),{},{status:"removed"})}))}}))},e}return Object(i.a)(c,[{key:"render",value:function(){var e=this,r=this.state.keyEntities,n=this.props,a=n.component,i=n.children,o=n.onVisibleChanged,c=y(n,["component","children","onVisibleChanged"]),s=a||d.Fragment,f={};return Ue.forEach((function(e){f[e]=c[e],delete c[e]})),delete c.keys,d.createElement(s,c,r.map((function(r){var n=r.status,a=y(r,["status"]),c="add"===n||"keep"===n;return d.createElement(t,Object(g.a)({},f,{key:a.key,visible:c,eventProps:a,onVisibleChanged:function(t){null===o||void 0===o||o(t,{key:a.key}),t||e.removeKey(a.key)}}),i)})))}}],[{key:"getDerivedStateFromProps",value:function(e,t){var r=e.keys,n=t.keyEntities,a=Fe(r);return{keyEntities:De(n,a).filter((function(e){var t=n.find((function(t){var r=t.key;return e.key===r}));return!t||"removed"!==t.status||"remove"!==e.status}))}}}]),c}(d.Component);r.defaultProps={component:"div"}}(Se);var ze=Le;function He(e){var t=e.prefixCls,r=e.motion,n=e.animation,a=e.transitionName;return r||(n?{motionName:"".concat(t,"-").concat(n)}:a?{motionName:a}:null)}function qe(e){var t=e.prefixCls,r=e.visible,a=e.zIndex,i=e.mask,o=e.maskMotion,c=e.maskAnimation,s=e.maskTransitionName;if(!i)return null;var f={};return(o||s||c)&&(f=Object(n.a)({motionAppear:!0},He({motion:o,prefixCls:t,transitionName:s,animation:c}))),d.createElement(ze,Object(g.a)({},f,{visible:r,removeOnLeave:!0}),(function(e){var r=e.className;return d.createElement("div",{style:{zIndex:a},className:j()("".concat(t,"-mask"),r)})}))}var Je;function Ve(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Ge(e){for(var t=1;t=0&&r.left>=0&&r.bottom>r.top&&r.right>r.left?r:null}function Nt(e){var t,r,n;if(Tt.isWindow(e)||9===e.nodeType){var a=Tt.getWindow(e);t={left:Tt.getWindowScrollLeft(a),top:Tt.getWindowScrollTop(a)},r=Tt.viewportWidth(a),n=Tt.viewportHeight(a)}else t=Tt.offset(e),r=Tt.outerWidth(e),n=Tt.outerHeight(e);return t.width=r,t.height=n,t}function Bt(e,t){var r=t.charAt(0),n=t.charAt(1),a=e.width,i=e.height,o=e.left,c=e.top;return"c"===r?c+=i/2:"b"===r&&(c+=i),"c"===n?o+=a/2:"r"===n&&(o+=a),{left:o,top:c}}function Lt(e,t,r,n,a){var i=Bt(t,r[1]),o=Bt(e,r[0]),c=[o.left-i.left,o.top-i.top];return{left:Math.round(e.left-c[0]+n[0]-a[0]),top:Math.round(e.top-c[1]+n[1]-a[1])}}function It(e,t,r){return e.leftr.right}function Ft(e,t,r){return e.topr.bottom}function Dt(e,t,r){var n=[];return Tt.each(e,(function(e){n.push(e.replace(t,(function(e){return r[e]})))})),n}function Ut(e,t){return e[t]=-e[t],e}function zt(e,t){return(/%$/.test(e)?parseInt(e.substring(0,e.length-1),10)/100*t:parseInt(e,10))||0}function Ht(e,t){e[0]=zt(e[0],t.width),e[1]=zt(e[1],t.height)}function qt(e,t,r,n){var a=r.points,i=r.offset||[0,0],o=r.targetOffset||[0,0],c=r.overflow,s=r.source||e;i=[].concat(i),o=[].concat(o);var f={},d=0,u=Rt(s,!(!(c=c||{})||!c.alwaysByViewport)),l=Nt(s);Ht(i,l),Ht(o,t);var b=Lt(l,t,a,i,o),h=Tt.merge(l,b);if(u&&(c.adjustX||c.adjustY)&&n){if(c.adjustX&&It(b,l,u)){var p=Dt(a,/[lr]/gi,{l:"r",r:"l"}),m=Ut(i,0),v=Ut(o,0);(function(e,t,r){return e.left>r.right||e.left+t.widthr.bottom||e.top+t.height=r.left&&a.left+i.width>r.right&&(i.width-=a.left+i.width-r.right),n.adjustX&&a.left+i.width>r.right&&(a.left=Math.max(r.right-i.width,r.left)),n.adjustY&&a.top=r.top&&a.top+i.height>r.bottom&&(i.height-=a.top+i.height-r.bottom),n.adjustY&&a.top+i.height>r.bottom&&(a.top=Math.max(r.bottom-i.height,r.top)),Tt.mix(a,i)}(b,l,u,f))}return h.width!==l.width&&Tt.css(s,"width",Tt.width(s)+h.width-l.width),h.height!==l.height&&Tt.css(s,"height",Tt.height(s)+h.height-l.height),Tt.offset(s,{left:h.left,top:h.top},{useCssRight:r.useCssRight,useCssBottom:r.useCssBottom,useCssTransform:r.useCssTransform,ignoreShake:r.ignoreShake}),{points:a,offset:i,targetOffset:o,overflow:f}}function Jt(e,t,r){var n=r.target||t;return qt(e,Nt(n),r,!function(e,t){var r=Rt(e,t),n=Nt(e);return!r||n.left+n.width<=r.left||n.top+n.height<=r.top||n.left>=r.right||n.top>=r.bottom}(n,r.overflow&&r.overflow.alwaysByViewport))}Jt.__getOffsetParent=Pt,Jt.__getVisibleRectForElement=Rt;var Vt=r(559),Gt=r.n(Vt),Xt=r(560);function Kt(e,t){var r=null,n=null;var a=new Xt.a((function(e){var a=me(e,1)[0].target;if(document.documentElement.contains(a)){var i=a.getBoundingClientRect(),o=i.width,c=i.height,s=Math.floor(o),f=Math.floor(c);r===s&&n===f||Promise.resolve().then((function(){t({width:s,height:f})})),r=s,n=f}}));return e&&a.observe(e),function(){a.disconnect()}}function Wt(e){return"function"!==typeof e?null:e()}function Zt(e){return"object"===Object(C.a)(e)&&e?e:null}var $t=function(e,t){var r=e.children,n=e.disabled,a=e.target,i=e.align,o=e.onAlign,c=e.monitorWindowResize,s=e.monitorBufferTime,f=void 0===s?0:s,d=u.a.useRef({}),l=u.a.useRef(),b=u.a.Children.only(r),h=u.a.useRef({});h.current.disabled=n,h.current.target=a,h.current.align=i,h.current.onAlign=o;var p=me(function(e,t){var r=u.a.useRef(!1),n=u.a.useRef(null);function a(){window.clearTimeout(n.current)}return[function i(o){if(r.current&&!0!==o)a(),n.current=window.setTimeout((function(){r.current=!1,i()}),t);else{if(!1===e())return;r.current=!0,a(),n.current=window.setTimeout((function(){r.current=!1}),t)}},function(){r.current=!1,a()}]}((function(){var e=h.current,t=e.disabled,r=e.target,n=e.align,a=e.onAlign;if(!t&&r){var i,o=l.current,c=Wt(r),s=Zt(r);d.current.element=c,d.current.point=s,d.current.align=n;var f=document.activeElement;return c&&function(e){if(!e)return!1;if(e.offsetParent)return!0;if(e.getBBox){var t=e.getBBox();if(t.width||t.height)return!0}if(e.getBoundingClientRect){var r=e.getBoundingClientRect();if(r.width||r.height)return!0}return!1}(c)?i=Jt(o,c,n):s&&(i=function(e,t,r){var n,a,i=Tt.getDocument(e),o=i.defaultView||i.parentWindow,c=Tt.getWindowScrollLeft(o),s=Tt.getWindowScrollTop(o),f=Tt.viewportWidth(o),d=Tt.viewportHeight(o),u={left:n="pageX"in t?t.pageX:c+t.clientX,top:a="pageY"in t?t.pageY:s+t.clientY,width:0,height:0},l=n>=0&&n<=c+f&&a>=0&&a<=s+d,b=[r.points[0],"cc"];return qt(e,u,Ge(Ge({},r),{},{points:b}),l)}(o,s,n)),function(e,t){e!==document.activeElement&&se(t,e)&&"function"===typeof e.focus&&e.focus()}(f,o),a&&i&&a(o,i),!0}return!1}),f),2),m=p[0],v=p[1],g=u.a.useRef({cancel:function(){}}),x=u.a.useRef({cancel:function(){}});u.a.useEffect((function(){var e,t,r=Wt(a),n=Zt(a);l.current!==x.current.element&&(x.current.cancel(),x.current.element=l.current,x.current.cancel=Kt(l.current,m)),d.current.element===r&&((e=d.current.point)===(t=n)||e&&t&&("pageX"in t&&"pageY"in t?e.pageX===t.pageX&&e.pageY===t.pageY:"clientX"in t&&"clientY"in t&&e.clientX===t.clientX&&e.clientY===t.clientY))&&Gt()(d.current.align,i)||(m(),g.current.element!==r&&(g.current.cancel(),g.current.element=r,g.current.cancel=Kt(r,m)))})),u.a.useEffect((function(){n?v():m()}),[n]);var y=u.a.useRef(null);return u.a.useEffect((function(){c?y.current||(y.current=A(window,"resize",m)):y.current&&(y.current.remove(),y.current=null)}),[c]),u.a.useEffect((function(){return function(){g.current.cancel(),x.current.cancel(),y.current&&y.current.remove(),v()}}),[]),u.a.useImperativeHandle(t,(function(){return{forceAlign:function(){return m(!0)}}})),u.a.isValidElement(b)&&(b=u.a.cloneElement(b,{ref:le(b.ref,l)})),b},Qt=u.a.forwardRef($t);Qt.displayName="Align";var Yt=Qt,er=r(372),tr=r.n(er);function rr(e,t,r,n,a,i,o){try{var c=e[i](o),s=c.value}catch(f){return void r(f)}c.done?t(s):Promise.resolve(s).then(n,a)}function nr(e){return function(){var t=this,r=arguments;return new Promise((function(n,a){var i=e.apply(t,r);function o(e){rr(i,n,a,o,c,"next",e)}function c(e){rr(i,n,a,o,c,"throw",e)}o(void 0)}))}}var ar=["measure","align",null,"motion"],ir=d.forwardRef((function(e,t){var r=e.visible,a=e.prefixCls,i=e.className,o=e.style,c=e.children,s=e.zIndex,f=e.stretch,u=e.destroyPopupOnHide,l=e.forceRender,b=e.align,h=e.point,p=e.getRootDomNode,m=e.getClassNameFromAlign,v=e.onAlign,x=e.onMouseEnter,y=e.onMouseLeave,w=e.onMouseDown,k=e.onTouchStart,_=Object(d.useRef)(),M=Object(d.useRef)(),S=me(Object(d.useState)(),2),E=S[0],O=S[1],A=function(e){var t=me(d.useState({width:0,height:0}),2),r=t[0],n=t[1];return[d.useMemo((function(){var t={};if(e){var n=r.width,a=r.height;-1!==e.indexOf("height")&&a?t.height=a:-1!==e.indexOf("minHeight")&&a&&(t.minHeight=a),-1!==e.indexOf("width")&&n?t.width=n:-1!==e.indexOf("minWidth")&&n&&(t.minWidth=n)}return t}),[e,r]),function(e){n({width:e.offsetWidth,height:e.offsetHeight})}]}(f),T=me(A,2),P=T[0],C=T[1];var R=function(e,t){var r=me(Object(d.useState)(null),2),n=r[0],a=r[1],i=Object(d.useRef)(),o=Object(d.useRef)(!1);function c(e){o.current||a(e)}function s(){ce.cancel(i.current)}return Object(d.useEffect)((function(){c("measure")}),[e]),Object(d.useEffect)((function(){switch(n){case"measure":t()}n&&(i.current=ce(nr(tr.a.mark((function e(){var t,r;return tr.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:t=ar.indexOf(n),(r=ar[t+1])&&-1!==t&&c(r);case 3:case"end":return e.stop()}}),e)})))))}),[n]),Object(d.useEffect)((function(){return function(){o.current=!0,s()}}),[]),[n,function(e){s(),i.current=ce((function(){c((function(e){switch(n){case"align":return"motion";case"motion":return"stable"}return e})),null===e||void 0===e||e()}))}]}(r,(function(){f&&C(p())})),N=me(R,2),B=N[0],L=N[1],I=Object(d.useRef)();function F(){var e;null===(e=_.current)||void 0===e||e.forceAlign()}function D(e,t){var r=m(t);E!==r&&O(r),"align"===B&&(E!==r?Promise.resolve().then((function(){F()})):L((function(){var e;null===(e=I.current)||void 0===e||e.call(I)})),null===v||void 0===v||v(e,t))}var U=Object(n.a)({},He(e));function z(){return new Promise((function(e){I.current=e}))}["onAppearEnd","onEnterEnd","onLeaveEnd"].forEach((function(e){var t=U[e];U[e]=function(e,r){return L(),null===t||void 0===t?void 0:t(e,r)}})),d.useEffect((function(){U.motionName||"motion"!==B||L()}),[U.motionName,B]),d.useImperativeHandle(t,(function(){return{forceAlign:F,getElement:function(){return M.current}}}));var H=Object(n.a)(Object(n.a)({},P),{},{zIndex:s,opacity:"motion"!==B&&"stable"!==B&&r?0:void 0,pointerEvents:"stable"===B?void 0:"none"},o),q=!0;!(null===b||void 0===b?void 0:b.points)||"align"!==B&&"stable"!==B||(q=!1);var J=c;return d.Children.count(c)>1&&(J=d.createElement("div",{className:"".concat(a,"-content")},c)),d.createElement(ze,Object(g.a)({visible:r,ref:M,leavedClassName:"".concat(a,"-hidden")},U,{onAppearPrepare:z,onEnterPrepare:z,removeOnLeave:u,forceRender:l}),(function(e,t){var r=e.className,o=e.style,c=j()(a,i,E,r);return d.createElement(Yt,{target:h||p,key:"popup",ref:_,monitorWindowResize:!0,disabled:q,align:b,onAlign:D},d.createElement("div",{ref:t,className:c,onMouseEnter:x,onMouseLeave:y,onMouseDownCapture:w,onTouchStartCapture:k,style:Object(n.a)(Object(n.a)({},o),H)},J))}))}));ir.displayName="PopupInner";var or=ir,cr=d.forwardRef((function(e,t){var r=e.prefixCls,a=e.visible,i=e.zIndex,o=e.children,c=e.mobile,s=(c=void 0===c?{}:c).popupClassName,f=c.popupStyle,u=c.popupMotion,l=void 0===u?{}:u,b=c.popupRender,h=d.useRef();d.useImperativeHandle(t,(function(){return{forceAlign:function(){},getElement:function(){return h.current}}}));var p=Object(n.a)({zIndex:i},f),m=o;return d.Children.count(o)>1&&(m=d.createElement("div",{className:"".concat(r,"-content")},o)),b&&(m=b(m)),d.createElement(ze,Object(g.a)({visible:a,ref:h,removeOnLeave:!0},l),(function(e,t){var a=e.className,i=e.style,o=j()(r,s,a);return d.createElement("div",{ref:t,className:o,style:Object(n.a)(Object(n.a)({},i),p)},m)}))}));cr.displayName="MobilePopupInner";var sr=cr,fr=["visible","mobile"],dr=d.forwardRef((function(e,t){var r=e.visible,a=e.mobile,i=y(e,fr),o=me(Object(d.useState)(r),2),c=o[0],s=o[1],f=me(Object(d.useState)(!1),2),u=f[0],l=f[1],b=Object(n.a)(Object(n.a)({},i),{},{visible:c});Object(d.useEffect)((function(){s(r),r&&a&&l(function(){if("undefined"===typeof navigator||"undefined"===typeof window)return!1;var e=navigator.userAgent||navigator.vendor||window.opera;return!(!/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino|android|ipad|playbook|silk/i.test(e)&&!/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw-(n|u)|c55\/|capi|ccwa|cdm-|cell|chtm|cldc|cmd-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc-s|devi|dica|dmob|do(c|p)o|ds(12|-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(-|_)|g1 u|g560|gene|gf-5|g-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd-(m|p|t)|hei-|hi(pt|ta)|hp( i|ip)|hs-c|ht(c(-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i-(20|go|ma)|i230|iac( |-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|-[a-w])|libw|lynx|m1-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|-([1-8]|c))|phil|pire|pl(ay|uc)|pn-2|po(ck|rt|se)|prox|psio|pt-g|qa-a|qc(07|12|21|32|60|-[2-7]|i-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h-|oo|p-)|sdk\/|se(c(-|0|1)|47|mc|nd|ri)|sgh-|shar|sie(-|m)|sk-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h-|v-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl-|tdg-|tel(i|m)|tim-|t-mo|to(pl|sh)|ts(70|m-|m3|m5)|tx-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas-|your|zeto|zte-/i.test(null===e||void 0===e?void 0:e.substr(0,4)))}())}),[r,a]);var h=u?d.createElement(sr,Object(g.a)({},b,{mobile:a,ref:t})):d.createElement(or,Object(g.a)({},b,{ref:t}));return d.createElement("div",null,d.createElement(qe,b),h)}));dr.displayName="Popup";var ur=dr,lr=d.createContext(null);function br(){}function hr(){return""}function pr(e){return e?e.ownerDocument:window.document}var mr=["onClick","onMouseDown","onTouchStart","onMouseEnter","onMouseLeave","onFocus","onBlur","onContextMenu"];var vr=function(e){var t=function(t){Object(o.a)(c,t);var r=f(c);function c(e){var t,n;return Object(a.a)(this,c),(t=r.call(this,e)).popupRef=d.createRef(),t.triggerRef=d.createRef(),t.attachId=void 0,t.clickOutsideHandler=void 0,t.touchOutsideHandler=void 0,t.contextMenuOutsideHandler1=void 0,t.contextMenuOutsideHandler2=void 0,t.mouseDownTimeout=void 0,t.focusTime=void 0,t.preClickTime=void 0,t.preTouchTime=void 0,t.delayTimer=void 0,t.hasPopupMouseDown=void 0,t.onMouseEnter=function(e){var r=t.props.mouseEnterDelay;t.fireEvents("onMouseEnter",e),t.delaySetPopupVisible(!0,r,r?null:e)},t.onMouseMove=function(e){t.fireEvents("onMouseMove",e),t.setPoint(e)},t.onMouseLeave=function(e){t.fireEvents("onMouseLeave",e),t.delaySetPopupVisible(!1,t.props.mouseLeaveDelay)},t.onPopupMouseEnter=function(){t.clearDelayTimer()},t.onPopupMouseLeave=function(e){var r;e.relatedTarget&&!e.relatedTarget.setTimeout&&se(null===(r=t.popupRef.current)||void 0===r?void 0:r.getElement(),e.relatedTarget)||t.delaySetPopupVisible(!1,t.props.mouseLeaveDelay)},t.onFocus=function(e){t.fireEvents("onFocus",e),t.clearDelayTimer(),t.isFocusToShow()&&(t.focusTime=Date.now(),t.delaySetPopupVisible(!0,t.props.focusDelay))},t.onMouseDown=function(e){t.fireEvents("onMouseDown",e),t.preClickTime=Date.now()},t.onTouchStart=function(e){t.fireEvents("onTouchStart",e),t.preTouchTime=Date.now()},t.onBlur=function(e){t.fireEvents("onBlur",e),t.clearDelayTimer(),t.isBlurToHide()&&t.delaySetPopupVisible(!1,t.props.blurDelay)},t.onContextMenu=function(e){e.preventDefault(),t.fireEvents("onContextMenu",e),t.setPopupVisible(!0,e)},t.onContextMenuClose=function(){t.isContextMenuToShow()&&t.close()},t.onClick=function(e){if(t.fireEvents("onClick",e),t.focusTime){var r;if(t.preClickTime&&t.preTouchTime?r=Math.min(t.preClickTime,t.preTouchTime):t.preClickTime?r=t.preClickTime:t.preTouchTime&&(r=t.preTouchTime),Math.abs(r-t.focusTime)<20)return;t.focusTime=0}t.preClickTime=0,t.preTouchTime=0,t.isClickToShow()&&(t.isClickToHide()||t.isBlurToHide())&&e&&e.preventDefault&&e.preventDefault();var n=!t.state.popupVisible;(t.isClickToHide()&&!n||n&&t.isClickToShow())&&t.setPopupVisible(!t.state.popupVisible,e)},t.onPopupMouseDown=function(){var e;(t.hasPopupMouseDown=!0,clearTimeout(t.mouseDownTimeout),t.mouseDownTimeout=window.setTimeout((function(){t.hasPopupMouseDown=!1}),0),t.context)&&(e=t.context).onPopupMouseDown.apply(e,arguments)},t.onDocumentClick=function(e){if(!t.props.mask||t.props.maskClosable){var r=e.target,n=t.getRootDomNode(),a=t.getPopupDomNode();se(n,r)&&!t.isContextMenuOnly()||se(a,r)||t.hasPopupMouseDown||t.close()}},t.getRootDomNode=function(){var e=t.props.getTriggerDOMNode;if(e)return e(t.triggerRef.current);try{var r=fe(t.triggerRef.current);if(r)return r}catch(n){}return O.a.findDOMNode(Object(te.a)(t))},t.getPopupClassNameFromAlign=function(e){var r=[],n=t.props,a=n.popupPlacement,i=n.builtinPlacements,o=n.prefixCls,c=n.alignPoint,s=n.getPopupClassNameFromAlign;return a&&i&&r.push(function(e,t,r,n){for(var a=r.points,i=Object.keys(e),o=0;o1024||e%1||e!=e)&&o.throwArgumentError("invalid length","length",e);var t=new Uint8Array(e);return s.getRandomValues(t),Object(n.a)(t)}s&&s.getRandomValues||(o.warn("WARNING: Missing strong random number source"),s={getRandomValues:function(e){return o.throwError("no secure random source avaialble",a.a.errors.UNSUPPORTED_OPERATION,{operation:"crypto.getRandomValues"})}})}).call(this,r(44))},function(e,t,r){var n=r(387);e.exports=function(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&n(e,t)}},function(e,t,r){var n=r(578),a=r(405),i=r(658);e.exports=function(e){return function(){var t,r=n(e);if(a()){var o=n(this).constructor;t=Reflect.construct(r,arguments,o)}else t=r.apply(this,arguments);return i(this,t)}}},function(e,t,r){"use strict";(function(t){var n=r(81);function a(e,t){if(e===t)return 0;for(var r=e.length,n=t.length,a=0,i=Math.min(r,n);a=0;f--)if(d[f]!==u[f])return!1;for(f=d.length-1;f>=0;f--)if(c=d[f],!x(e[c],t[c],r,n))return!1;return!0}(e,t,r,n))}return r?e===t:e==t}function y(e){return"[object Arguments]"==Object.prototype.toString.call(e)}function w(e,t){if(!e||!t)return!1;if("[object RegExp]"==Object.prototype.toString.call(t))return t.test(e);try{if(e instanceof t)return!0}catch(r){}return!Error.isPrototypeOf(t)&&!0===t.call({},e)}function k(e,t,r,n){var a;if("function"!==typeof t)throw new TypeError('"block" argument must be a function');"string"===typeof r&&(n=r,r=null),a=function(e){var t;try{e()}catch(r){t=r}return t}(t),n=(r&&r.name?" ("+r.name+").":".")+(n?" "+n:"."),e&&!a&&v(a,r,"Missing expected exception"+n);var i="string"===typeof n,c=!e&&a&&!r;if((!e&&o.isError(a)&&i&&w(a,r)||c)&&v(a,r,"Got unwanted exception"+n),e&&a&&r&&!w(a,r)||!e&&a)throw a}l.AssertionError=function(e){this.name="AssertionError",this.actual=e.actual,this.expected=e.expected,this.operator=e.operator,e.message?(this.message=e.message,this.generatedMessage=!1):(this.message=function(e){return p(m(e.actual),128)+" "+e.operator+" "+p(m(e.expected),128)}(this),this.generatedMessage=!0);var t=e.stackStartFunction||v;if(Error.captureStackTrace)Error.captureStackTrace(this,t);else{var r=new Error;if(r.stack){var n=r.stack,a=h(t),i=n.indexOf("\n"+a);if(i>=0){var o=n.indexOf("\n",i+1);n=n.substring(o+1)}this.stack=n}}},o.inherits(l.AssertionError,Error),l.fail=v,l.ok=g,l.equal=function(e,t,r){e!=t&&v(e,t,r,"==",l.equal)},l.notEqual=function(e,t,r){e==t&&v(e,t,r,"!=",l.notEqual)},l.deepEqual=function(e,t,r){x(e,t,!1)||v(e,t,r,"deepEqual",l.deepEqual)},l.deepStrictEqual=function(e,t,r){x(e,t,!0)||v(e,t,r,"deepStrictEqual",l.deepStrictEqual)},l.notDeepEqual=function(e,t,r){x(e,t,!1)&&v(e,t,r,"notDeepEqual",l.notDeepEqual)},l.notDeepStrictEqual=function e(t,r,n){x(t,r,!0)&&v(t,r,n,"notDeepStrictEqual",e)},l.strictEqual=function(e,t,r){e!==t&&v(e,t,r,"===",l.strictEqual)},l.notStrictEqual=function(e,t,r){e===t&&v(e,t,r,"!==",l.notStrictEqual)},l.throws=function(e,t,r){k(!0,e,t,r)},l.doesNotThrow=function(e,t,r){k(!1,e,t,r)},l.ifError=function(e){if(e)throw e},l.strict=n((function e(t,r){t||v(t,!0,r,"==",e)}),l,{equal:l.strictEqual,deepEqual:l.deepStrictEqual,notEqual:l.notStrictEqual,notDeepEqual:l.notDeepStrictEqual}),l.strict.strict=l.strict;var _=Object.keys||function(e){var t=[];for(var r in e)c.call(e,r)&&t.push(r);return t}}).call(this,r(44))},function(e,t){e.exports=function(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}},,function(e,t,r){(function(n,a){var i;!function(){"use strict";var o="input is invalid type",c="object"===typeof window,s=c?window:{};s.JS_SHA3_NO_WINDOW&&(c=!1);var f=!c&&"object"===typeof self;!s.JS_SHA3_NO_NODE_JS&&"object"===typeof n&&n.versions&&n.versions.node?s=a:f&&(s=self);var d=!s.JS_SHA3_NO_COMMON_JS&&"object"===typeof e&&e.exports,u=r(386),l=!s.JS_SHA3_NO_ARRAY_BUFFER&&"undefined"!==typeof ArrayBuffer,b="0123456789abcdef".split(""),h=[4,1024,262144,67108864],p=[0,8,16,24],m=[1,0,32898,0,32906,2147483648,2147516416,2147483648,32907,0,2147483649,0,2147516545,2147483648,32777,2147483648,138,0,136,0,2147516425,0,2147483658,0,2147516555,0,139,2147483648,32905,2147483648,32771,2147483648,32770,2147483648,128,2147483648,32778,0,2147483658,2147483648,2147516545,2147483648,32896,2147483648,2147483649,0,2147516424,2147483648],v=[224,256,384,512],g=[128,256],x=["hex","buffer","arrayBuffer","array","digest"],y={128:168,256:136};!s.JS_SHA3_NO_NODE_JS&&Array.isArray||(Array.isArray=function(e){return"[object Array]"===Object.prototype.toString.call(e)}),!l||!s.JS_SHA3_NO_ARRAY_BUFFER_IS_VIEW&&ArrayBuffer.isView||(ArrayBuffer.isView=function(e){return"object"===typeof e&&e.buffer&&e.buffer.constructor===ArrayBuffer});for(var w=function(e,t,r){return function(n){return new L(e,t,e).update(n)[r]()}},k=function(e,t,r){return function(n,a){return new L(e,t,a).update(n)[r]()}},_=function(e,t,r){return function(t,n,a,i){return A["cshake"+e].update(t,n,a,i)[r]()}},M=function(e,t,r){return function(t,n,a,i){return A["kmac"+e].update(t,n,a,i)[r]()}},S=function(e,t,r,n){for(var a=0;a>5,this.byteCount=this.blockCount<<2,this.outputBlocks=r>>5,this.extraBytes=(31&r)>>3;for(var n=0;n<50;++n)this.s[n]=0}function I(e,t,r){L.call(this,e,t,r)}L.prototype.update=function(e){if(this.finalized)throw new Error("finalize already called");var t,r=typeof e;if("string"!==r){if("object"!==r)throw new Error(o);if(null===e)throw new Error(o);if(l&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!Array.isArray(e)&&(!l||!ArrayBuffer.isView(e)))throw new Error(o);t=!0}for(var n,a,i=this.blocks,c=this.byteCount,s=e.length,f=this.blockCount,d=0,u=this.s;d>2]|=e[d]<>2]|=a<>2]|=(192|a>>6)<>2]|=(128|63&a)<=57344?(i[n>>2]|=(224|a>>12)<>2]|=(128|a>>6&63)<>2]|=(128|63&a)<>2]|=(240|a>>18)<>2]|=(128|a>>12&63)<>2]|=(128|a>>6&63)<>2]|=(128|63&a)<=c){for(this.start=n-c,this.block=i[f],n=0;n>=8);r>0;)a.unshift(r),r=255&(e>>=8),++n;return t?a.push(n):a.unshift(n),this.update(a),a.length},L.prototype.encodeString=function(e){var t,r=typeof e;if("string"!==r){if("object"!==r)throw new Error(o);if(null===e)throw new Error(o);if(l&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!Array.isArray(e)&&(!l||!ArrayBuffer.isView(e)))throw new Error(o);t=!0}var n=0,a=e.length;if(t)n=a;else for(var i=0;i=57344?n+=3:(c=65536+((1023&c)<<10|1023&e.charCodeAt(++i)),n+=4)}return n+=this.encode(8*n),this.update(e),n},L.prototype.bytepad=function(e,t){for(var r=this.encode(t),n=0;n>2]|=this.padding[3&t],this.lastByteIndex===this.byteCount)for(e[0]=e[r],t=1;t>4&15]+b[15&e]+b[e>>12&15]+b[e>>8&15]+b[e>>20&15]+b[e>>16&15]+b[e>>28&15]+b[e>>24&15];o%t===0&&(F(r),i=0)}return a&&(e=r[i],c+=b[e>>4&15]+b[15&e],a>1&&(c+=b[e>>12&15]+b[e>>8&15]),a>2&&(c+=b[e>>20&15]+b[e>>16&15])),c},L.prototype.arrayBuffer=function(){this.finalize();var e,t=this.blockCount,r=this.s,n=this.outputBlocks,a=this.extraBytes,i=0,o=0,c=this.outputBits>>3;e=a?new ArrayBuffer(n+1<<2):new ArrayBuffer(c);for(var s=new Uint32Array(e);o>8&255,s[e+2]=t>>16&255,s[e+3]=t>>24&255;c%r===0&&F(n)}return i&&(e=c<<2,t=n[o],s[e]=255&t,i>1&&(s[e+1]=t>>8&255),i>2&&(s[e+2]=t>>16&255)),s},I.prototype=new L,I.prototype.finalize=function(){return this.encode(this.outputBits,!0),L.prototype.finalize.call(this)};var F=function(e){var t,r,n,a,i,o,c,s,f,d,u,l,b,h,p,v,g,x,y,w,k,_,M,S,E,O,A,T,j,P,C,R,N,B,L,I,F,D,U,z,H,q,J,V,G,X,K,W,Z,$,Q,Y,ee,te,re,ne,ae,ie,oe,ce,se,fe,de;for(n=0;n<48;n+=2)a=e[0]^e[10]^e[20]^e[30]^e[40],i=e[1]^e[11]^e[21]^e[31]^e[41],o=e[2]^e[12]^e[22]^e[32]^e[42],c=e[3]^e[13]^e[23]^e[33]^e[43],s=e[4]^e[14]^e[24]^e[34]^e[44],f=e[5]^e[15]^e[25]^e[35]^e[45],d=e[6]^e[16]^e[26]^e[36]^e[46],u=e[7]^e[17]^e[27]^e[37]^e[47],t=(l=e[8]^e[18]^e[28]^e[38]^e[48])^(o<<1|c>>>31),r=(b=e[9]^e[19]^e[29]^e[39]^e[49])^(c<<1|o>>>31),e[0]^=t,e[1]^=r,e[10]^=t,e[11]^=r,e[20]^=t,e[21]^=r,e[30]^=t,e[31]^=r,e[40]^=t,e[41]^=r,t=a^(s<<1|f>>>31),r=i^(f<<1|s>>>31),e[2]^=t,e[3]^=r,e[12]^=t,e[13]^=r,e[22]^=t,e[23]^=r,e[32]^=t,e[33]^=r,e[42]^=t,e[43]^=r,t=o^(d<<1|u>>>31),r=c^(u<<1|d>>>31),e[4]^=t,e[5]^=r,e[14]^=t,e[15]^=r,e[24]^=t,e[25]^=r,e[34]^=t,e[35]^=r,e[44]^=t,e[45]^=r,t=s^(l<<1|b>>>31),r=f^(b<<1|l>>>31),e[6]^=t,e[7]^=r,e[16]^=t,e[17]^=r,e[26]^=t,e[27]^=r,e[36]^=t,e[37]^=r,e[46]^=t,e[47]^=r,t=d^(a<<1|i>>>31),r=u^(i<<1|a>>>31),e[8]^=t,e[9]^=r,e[18]^=t,e[19]^=r,e[28]^=t,e[29]^=r,e[38]^=t,e[39]^=r,e[48]^=t,e[49]^=r,h=e[0],p=e[1],X=e[11]<<4|e[10]>>>28,K=e[10]<<4|e[11]>>>28,T=e[20]<<3|e[21]>>>29,j=e[21]<<3|e[20]>>>29,ce=e[31]<<9|e[30]>>>23,se=e[30]<<9|e[31]>>>23,q=e[40]<<18|e[41]>>>14,J=e[41]<<18|e[40]>>>14,B=e[2]<<1|e[3]>>>31,L=e[3]<<1|e[2]>>>31,v=e[13]<<12|e[12]>>>20,g=e[12]<<12|e[13]>>>20,W=e[22]<<10|e[23]>>>22,Z=e[23]<<10|e[22]>>>22,P=e[33]<<13|e[32]>>>19,C=e[32]<<13|e[33]>>>19,fe=e[42]<<2|e[43]>>>30,de=e[43]<<2|e[42]>>>30,te=e[5]<<30|e[4]>>>2,re=e[4]<<30|e[5]>>>2,I=e[14]<<6|e[15]>>>26,F=e[15]<<6|e[14]>>>26,x=e[25]<<11|e[24]>>>21,y=e[24]<<11|e[25]>>>21,$=e[34]<<15|e[35]>>>17,Q=e[35]<<15|e[34]>>>17,R=e[45]<<29|e[44]>>>3,N=e[44]<<29|e[45]>>>3,S=e[6]<<28|e[7]>>>4,E=e[7]<<28|e[6]>>>4,ne=e[17]<<23|e[16]>>>9,ae=e[16]<<23|e[17]>>>9,D=e[26]<<25|e[27]>>>7,U=e[27]<<25|e[26]>>>7,w=e[36]<<21|e[37]>>>11,k=e[37]<<21|e[36]>>>11,Y=e[47]<<24|e[46]>>>8,ee=e[46]<<24|e[47]>>>8,V=e[8]<<27|e[9]>>>5,G=e[9]<<27|e[8]>>>5,O=e[18]<<20|e[19]>>>12,A=e[19]<<20|e[18]>>>12,ie=e[29]<<7|e[28]>>>25,oe=e[28]<<7|e[29]>>>25,z=e[38]<<8|e[39]>>>24,H=e[39]<<8|e[38]>>>24,_=e[48]<<14|e[49]>>>18,M=e[49]<<14|e[48]>>>18,e[0]=h^~v&x,e[1]=p^~g&y,e[10]=S^~O&T,e[11]=E^~A&j,e[20]=B^~I&D,e[21]=L^~F&U,e[30]=V^~X&W,e[31]=G^~K&Z,e[40]=te^~ne&ie,e[41]=re^~ae&oe,e[2]=v^~x&w,e[3]=g^~y&k,e[12]=O^~T&P,e[13]=A^~j&C,e[22]=I^~D&z,e[23]=F^~U&H,e[32]=X^~W&$,e[33]=K^~Z&Q,e[42]=ne^~ie&ce,e[43]=ae^~oe&se,e[4]=x^~w&_,e[5]=y^~k&M,e[14]=T^~P&R,e[15]=j^~C&N,e[24]=D^~z&q,e[25]=U^~H&J,e[34]=W^~$&Y,e[35]=Z^~Q&ee,e[44]=ie^~ce&fe,e[45]=oe^~se&de,e[6]=w^~_&h,e[7]=k^~M&p,e[16]=P^~R&S,e[17]=C^~N&E,e[26]=z^~q&B,e[27]=H^~J&L,e[36]=$^~Y&V,e[37]=Q^~ee&G,e[46]=ce^~fe&te,e[47]=se^~de&re,e[8]=_^~h&v,e[9]=M^~p&g,e[18]=R^~S&O,e[19]=N^~E&A,e[28]=q^~B&I,e[29]=J^~L&F,e[38]=Y^~V&X,e[39]=ee^~G&K,e[48]=fe^~te&ne,e[49]=de^~re&ae,e[0]^=m[n],e[1]^=m[n+1]};if(d)e.exports=A;else{for(j=0;j=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function s(e,t,r){var n=c(e,r);return r-1>=t&&(n|=c(e,r-1)<<4),n}function f(e,t,r,n){for(var a=0,i=Math.min(e.length,r),o=t;o=49?c-49+10:c>=17?c-17+10:c}return a}i.isBN=function(e){return e instanceof i||null!==e&&"object"===typeof e&&e.constructor.wordSize===i.wordSize&&Array.isArray(e.words)},i.max=function(e,t){return e.cmp(t)>0?e:t},i.min=function(e,t){return e.cmp(t)<0?e:t},i.prototype._init=function(e,t,r){if("number"===typeof e)return this._initNumber(e,t,r);if("object"===typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var a=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(a++,this.negative=1),a=0;a-=3)o=e[a]|e[a-1]<<8|e[a-2]<<16,this.words[i]|=o<>>26-c&67108863,(c+=24)>=26&&(c-=26,i++);else if("le"===r)for(a=0,i=0;a>>26-c&67108863,(c+=24)>=26&&(c-=26,i++);return this.strip()},i.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)a=s(e,t,n)<=18?(i-=18,o+=1,this.words[o]|=a>>>26):i+=8;else for(n=(e.length-t)%2===0?t+1:t;n=18?(i-=18,o+=1,this.words[o]|=a>>>26):i+=8;this.strip()},i.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,a=1;a<=67108863;a*=t)n++;n--,a=a/t|0;for(var i=e.length-r,o=i%n,c=Math.min(i,i-o)+r,s=0,d=r;d1&&0===this.words[this.length-1];)this.length--;return this._normSign()},i.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},i.prototype.inspect=function(){return(this.red?""};var d=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],u=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],l=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];function b(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var a=0|e.words[0],i=0|t.words[0],o=a*i,c=67108863&o,s=o/67108864|0;r.words[0]=c;for(var f=1;f>>26,u=67108863&s,l=Math.min(f,t.length-1),b=Math.max(0,f-e.length+1);b<=l;b++){var h=f-b|0;d+=(o=(a=0|e.words[h])*(i=0|t.words[b])+u)/67108864|0,u=67108863&o}r.words[f]=0|u,s=0|d}return 0!==s?r.words[f]=0|s:r.length--,r.strip()}i.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var a=0,i=0,o=0;o>>24-a&16777215)||o!==this.length-1?d[6-s.length]+s+r:s+r,(a+=2)>=26&&(a-=26,o--)}for(0!==i&&(r=i.toString(16)+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var f=u[e],b=l[e];r="";var h=this.clone();for(h.negative=0;!h.isZero();){var p=h.modn(b).toString(e);r=(h=h.idivn(b)).isZero()?p+r:d[f-p.length]+p+r}for(this.isZero()&&(r="0"+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},i.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},i.prototype.toJSON=function(){return this.toString(16)},i.prototype.toBuffer=function(e,t){return n("undefined"!==typeof o),this.toArrayLike(o,e,t)},i.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},i.prototype.toArrayLike=function(e,t,r){var a=this.byteLength(),i=r||Math.max(1,a);n(a<=i,"byte array longer than desired length"),n(i>0,"Requested array length <= 0"),this.strip();var o,c,s="le"===t,f=new e(i),d=this.clone();if(s){for(c=0;!d.isZero();c++)o=d.andln(255),d.iushrn(8),f[c]=o;for(;c=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},i.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0===(8191&t)&&(r+=13,t>>>=13),0===(127&t)&&(r+=7,t>>>=7),0===(15&t)&&(r+=4,t>>>=4),0===(3&t)&&(r+=2,t>>>=2),0===(1&t)&&r++,r},i.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},i.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},i.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},i.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},i.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},i.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},i.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},i.prototype.inotn=function(e){n("number"===typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var a=0;a0&&(this.words[a]=~this.words[a]&67108863>>26-r),this.strip()},i.prototype.notn=function(e){return this.clone().inotn(e)},i.prototype.setn=function(e,t){n("number"===typeof e&&e>=0);var r=e/26|0,a=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var a=0,i=0;i>>26;for(;0!==a&&i>>26;if(this.length=r.length,0!==a)this.words[this.length]=a,this.length++;else if(r!==this)for(;ie.length?this.clone().iadd(e):e.clone().iadd(this)},i.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,a=this.cmp(e);if(0===a)return this.negative=0,this.length=1,this.words[0]=0,this;a>0?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>26,this.words[o]=67108863&t;for(;0!==i&&o>26,this.words[o]=67108863&t;if(0===i&&o>>13,b=0|o[1],h=8191&b,p=b>>>13,m=0|o[2],v=8191&m,g=m>>>13,x=0|o[3],y=8191&x,w=x>>>13,k=0|o[4],_=8191&k,M=k>>>13,S=0|o[5],E=8191&S,O=S>>>13,A=0|o[6],T=8191&A,j=A>>>13,P=0|o[7],C=8191&P,R=P>>>13,N=0|o[8],B=8191&N,L=N>>>13,I=0|o[9],F=8191&I,D=I>>>13,U=0|c[0],z=8191&U,H=U>>>13,q=0|c[1],J=8191&q,V=q>>>13,G=0|c[2],X=8191&G,K=G>>>13,W=0|c[3],Z=8191&W,$=W>>>13,Q=0|c[4],Y=8191&Q,ee=Q>>>13,te=0|c[5],re=8191&te,ne=te>>>13,ae=0|c[6],ie=8191&ae,oe=ae>>>13,ce=0|c[7],se=8191&ce,fe=ce>>>13,de=0|c[8],ue=8191&de,le=de>>>13,be=0|c[9],he=8191&be,pe=be>>>13;r.negative=e.negative^t.negative,r.length=19;var me=(f+(n=Math.imul(u,z))|0)+((8191&(a=(a=Math.imul(u,H))+Math.imul(l,z)|0))<<13)|0;f=((i=Math.imul(l,H))+(a>>>13)|0)+(me>>>26)|0,me&=67108863,n=Math.imul(h,z),a=(a=Math.imul(h,H))+Math.imul(p,z)|0,i=Math.imul(p,H);var ve=(f+(n=n+Math.imul(u,J)|0)|0)+((8191&(a=(a=a+Math.imul(u,V)|0)+Math.imul(l,J)|0))<<13)|0;f=((i=i+Math.imul(l,V)|0)+(a>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(v,z),a=(a=Math.imul(v,H))+Math.imul(g,z)|0,i=Math.imul(g,H),n=n+Math.imul(h,J)|0,a=(a=a+Math.imul(h,V)|0)+Math.imul(p,J)|0,i=i+Math.imul(p,V)|0;var ge=(f+(n=n+Math.imul(u,X)|0)|0)+((8191&(a=(a=a+Math.imul(u,K)|0)+Math.imul(l,X)|0))<<13)|0;f=((i=i+Math.imul(l,K)|0)+(a>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(y,z),a=(a=Math.imul(y,H))+Math.imul(w,z)|0,i=Math.imul(w,H),n=n+Math.imul(v,J)|0,a=(a=a+Math.imul(v,V)|0)+Math.imul(g,J)|0,i=i+Math.imul(g,V)|0,n=n+Math.imul(h,X)|0,a=(a=a+Math.imul(h,K)|0)+Math.imul(p,X)|0,i=i+Math.imul(p,K)|0;var xe=(f+(n=n+Math.imul(u,Z)|0)|0)+((8191&(a=(a=a+Math.imul(u,$)|0)+Math.imul(l,Z)|0))<<13)|0;f=((i=i+Math.imul(l,$)|0)+(a>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(_,z),a=(a=Math.imul(_,H))+Math.imul(M,z)|0,i=Math.imul(M,H),n=n+Math.imul(y,J)|0,a=(a=a+Math.imul(y,V)|0)+Math.imul(w,J)|0,i=i+Math.imul(w,V)|0,n=n+Math.imul(v,X)|0,a=(a=a+Math.imul(v,K)|0)+Math.imul(g,X)|0,i=i+Math.imul(g,K)|0,n=n+Math.imul(h,Z)|0,a=(a=a+Math.imul(h,$)|0)+Math.imul(p,Z)|0,i=i+Math.imul(p,$)|0;var ye=(f+(n=n+Math.imul(u,Y)|0)|0)+((8191&(a=(a=a+Math.imul(u,ee)|0)+Math.imul(l,Y)|0))<<13)|0;f=((i=i+Math.imul(l,ee)|0)+(a>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(E,z),a=(a=Math.imul(E,H))+Math.imul(O,z)|0,i=Math.imul(O,H),n=n+Math.imul(_,J)|0,a=(a=a+Math.imul(_,V)|0)+Math.imul(M,J)|0,i=i+Math.imul(M,V)|0,n=n+Math.imul(y,X)|0,a=(a=a+Math.imul(y,K)|0)+Math.imul(w,X)|0,i=i+Math.imul(w,K)|0,n=n+Math.imul(v,Z)|0,a=(a=a+Math.imul(v,$)|0)+Math.imul(g,Z)|0,i=i+Math.imul(g,$)|0,n=n+Math.imul(h,Y)|0,a=(a=a+Math.imul(h,ee)|0)+Math.imul(p,Y)|0,i=i+Math.imul(p,ee)|0;var we=(f+(n=n+Math.imul(u,re)|0)|0)+((8191&(a=(a=a+Math.imul(u,ne)|0)+Math.imul(l,re)|0))<<13)|0;f=((i=i+Math.imul(l,ne)|0)+(a>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(T,z),a=(a=Math.imul(T,H))+Math.imul(j,z)|0,i=Math.imul(j,H),n=n+Math.imul(E,J)|0,a=(a=a+Math.imul(E,V)|0)+Math.imul(O,J)|0,i=i+Math.imul(O,V)|0,n=n+Math.imul(_,X)|0,a=(a=a+Math.imul(_,K)|0)+Math.imul(M,X)|0,i=i+Math.imul(M,K)|0,n=n+Math.imul(y,Z)|0,a=(a=a+Math.imul(y,$)|0)+Math.imul(w,Z)|0,i=i+Math.imul(w,$)|0,n=n+Math.imul(v,Y)|0,a=(a=a+Math.imul(v,ee)|0)+Math.imul(g,Y)|0,i=i+Math.imul(g,ee)|0,n=n+Math.imul(h,re)|0,a=(a=a+Math.imul(h,ne)|0)+Math.imul(p,re)|0,i=i+Math.imul(p,ne)|0;var ke=(f+(n=n+Math.imul(u,ie)|0)|0)+((8191&(a=(a=a+Math.imul(u,oe)|0)+Math.imul(l,ie)|0))<<13)|0;f=((i=i+Math.imul(l,oe)|0)+(a>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(C,z),a=(a=Math.imul(C,H))+Math.imul(R,z)|0,i=Math.imul(R,H),n=n+Math.imul(T,J)|0,a=(a=a+Math.imul(T,V)|0)+Math.imul(j,J)|0,i=i+Math.imul(j,V)|0,n=n+Math.imul(E,X)|0,a=(a=a+Math.imul(E,K)|0)+Math.imul(O,X)|0,i=i+Math.imul(O,K)|0,n=n+Math.imul(_,Z)|0,a=(a=a+Math.imul(_,$)|0)+Math.imul(M,Z)|0,i=i+Math.imul(M,$)|0,n=n+Math.imul(y,Y)|0,a=(a=a+Math.imul(y,ee)|0)+Math.imul(w,Y)|0,i=i+Math.imul(w,ee)|0,n=n+Math.imul(v,re)|0,a=(a=a+Math.imul(v,ne)|0)+Math.imul(g,re)|0,i=i+Math.imul(g,ne)|0,n=n+Math.imul(h,ie)|0,a=(a=a+Math.imul(h,oe)|0)+Math.imul(p,ie)|0,i=i+Math.imul(p,oe)|0;var _e=(f+(n=n+Math.imul(u,se)|0)|0)+((8191&(a=(a=a+Math.imul(u,fe)|0)+Math.imul(l,se)|0))<<13)|0;f=((i=i+Math.imul(l,fe)|0)+(a>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(B,z),a=(a=Math.imul(B,H))+Math.imul(L,z)|0,i=Math.imul(L,H),n=n+Math.imul(C,J)|0,a=(a=a+Math.imul(C,V)|0)+Math.imul(R,J)|0,i=i+Math.imul(R,V)|0,n=n+Math.imul(T,X)|0,a=(a=a+Math.imul(T,K)|0)+Math.imul(j,X)|0,i=i+Math.imul(j,K)|0,n=n+Math.imul(E,Z)|0,a=(a=a+Math.imul(E,$)|0)+Math.imul(O,Z)|0,i=i+Math.imul(O,$)|0,n=n+Math.imul(_,Y)|0,a=(a=a+Math.imul(_,ee)|0)+Math.imul(M,Y)|0,i=i+Math.imul(M,ee)|0,n=n+Math.imul(y,re)|0,a=(a=a+Math.imul(y,ne)|0)+Math.imul(w,re)|0,i=i+Math.imul(w,ne)|0,n=n+Math.imul(v,ie)|0,a=(a=a+Math.imul(v,oe)|0)+Math.imul(g,ie)|0,i=i+Math.imul(g,oe)|0,n=n+Math.imul(h,se)|0,a=(a=a+Math.imul(h,fe)|0)+Math.imul(p,se)|0,i=i+Math.imul(p,fe)|0;var Me=(f+(n=n+Math.imul(u,ue)|0)|0)+((8191&(a=(a=a+Math.imul(u,le)|0)+Math.imul(l,ue)|0))<<13)|0;f=((i=i+Math.imul(l,le)|0)+(a>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,z),a=(a=Math.imul(F,H))+Math.imul(D,z)|0,i=Math.imul(D,H),n=n+Math.imul(B,J)|0,a=(a=a+Math.imul(B,V)|0)+Math.imul(L,J)|0,i=i+Math.imul(L,V)|0,n=n+Math.imul(C,X)|0,a=(a=a+Math.imul(C,K)|0)+Math.imul(R,X)|0,i=i+Math.imul(R,K)|0,n=n+Math.imul(T,Z)|0,a=(a=a+Math.imul(T,$)|0)+Math.imul(j,Z)|0,i=i+Math.imul(j,$)|0,n=n+Math.imul(E,Y)|0,a=(a=a+Math.imul(E,ee)|0)+Math.imul(O,Y)|0,i=i+Math.imul(O,ee)|0,n=n+Math.imul(_,re)|0,a=(a=a+Math.imul(_,ne)|0)+Math.imul(M,re)|0,i=i+Math.imul(M,ne)|0,n=n+Math.imul(y,ie)|0,a=(a=a+Math.imul(y,oe)|0)+Math.imul(w,ie)|0,i=i+Math.imul(w,oe)|0,n=n+Math.imul(v,se)|0,a=(a=a+Math.imul(v,fe)|0)+Math.imul(g,se)|0,i=i+Math.imul(g,fe)|0,n=n+Math.imul(h,ue)|0,a=(a=a+Math.imul(h,le)|0)+Math.imul(p,ue)|0,i=i+Math.imul(p,le)|0;var Se=(f+(n=n+Math.imul(u,he)|0)|0)+((8191&(a=(a=a+Math.imul(u,pe)|0)+Math.imul(l,he)|0))<<13)|0;f=((i=i+Math.imul(l,pe)|0)+(a>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(F,J),a=(a=Math.imul(F,V))+Math.imul(D,J)|0,i=Math.imul(D,V),n=n+Math.imul(B,X)|0,a=(a=a+Math.imul(B,K)|0)+Math.imul(L,X)|0,i=i+Math.imul(L,K)|0,n=n+Math.imul(C,Z)|0,a=(a=a+Math.imul(C,$)|0)+Math.imul(R,Z)|0,i=i+Math.imul(R,$)|0,n=n+Math.imul(T,Y)|0,a=(a=a+Math.imul(T,ee)|0)+Math.imul(j,Y)|0,i=i+Math.imul(j,ee)|0,n=n+Math.imul(E,re)|0,a=(a=a+Math.imul(E,ne)|0)+Math.imul(O,re)|0,i=i+Math.imul(O,ne)|0,n=n+Math.imul(_,ie)|0,a=(a=a+Math.imul(_,oe)|0)+Math.imul(M,ie)|0,i=i+Math.imul(M,oe)|0,n=n+Math.imul(y,se)|0,a=(a=a+Math.imul(y,fe)|0)+Math.imul(w,se)|0,i=i+Math.imul(w,fe)|0,n=n+Math.imul(v,ue)|0,a=(a=a+Math.imul(v,le)|0)+Math.imul(g,ue)|0,i=i+Math.imul(g,le)|0;var Ee=(f+(n=n+Math.imul(h,he)|0)|0)+((8191&(a=(a=a+Math.imul(h,pe)|0)+Math.imul(p,he)|0))<<13)|0;f=((i=i+Math.imul(p,pe)|0)+(a>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,X),a=(a=Math.imul(F,K))+Math.imul(D,X)|0,i=Math.imul(D,K),n=n+Math.imul(B,Z)|0,a=(a=a+Math.imul(B,$)|0)+Math.imul(L,Z)|0,i=i+Math.imul(L,$)|0,n=n+Math.imul(C,Y)|0,a=(a=a+Math.imul(C,ee)|0)+Math.imul(R,Y)|0,i=i+Math.imul(R,ee)|0,n=n+Math.imul(T,re)|0,a=(a=a+Math.imul(T,ne)|0)+Math.imul(j,re)|0,i=i+Math.imul(j,ne)|0,n=n+Math.imul(E,ie)|0,a=(a=a+Math.imul(E,oe)|0)+Math.imul(O,ie)|0,i=i+Math.imul(O,oe)|0,n=n+Math.imul(_,se)|0,a=(a=a+Math.imul(_,fe)|0)+Math.imul(M,se)|0,i=i+Math.imul(M,fe)|0,n=n+Math.imul(y,ue)|0,a=(a=a+Math.imul(y,le)|0)+Math.imul(w,ue)|0,i=i+Math.imul(w,le)|0;var Oe=(f+(n=n+Math.imul(v,he)|0)|0)+((8191&(a=(a=a+Math.imul(v,pe)|0)+Math.imul(g,he)|0))<<13)|0;f=((i=i+Math.imul(g,pe)|0)+(a>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,Z),a=(a=Math.imul(F,$))+Math.imul(D,Z)|0,i=Math.imul(D,$),n=n+Math.imul(B,Y)|0,a=(a=a+Math.imul(B,ee)|0)+Math.imul(L,Y)|0,i=i+Math.imul(L,ee)|0,n=n+Math.imul(C,re)|0,a=(a=a+Math.imul(C,ne)|0)+Math.imul(R,re)|0,i=i+Math.imul(R,ne)|0,n=n+Math.imul(T,ie)|0,a=(a=a+Math.imul(T,oe)|0)+Math.imul(j,ie)|0,i=i+Math.imul(j,oe)|0,n=n+Math.imul(E,se)|0,a=(a=a+Math.imul(E,fe)|0)+Math.imul(O,se)|0,i=i+Math.imul(O,fe)|0,n=n+Math.imul(_,ue)|0,a=(a=a+Math.imul(_,le)|0)+Math.imul(M,ue)|0,i=i+Math.imul(M,le)|0;var Ae=(f+(n=n+Math.imul(y,he)|0)|0)+((8191&(a=(a=a+Math.imul(y,pe)|0)+Math.imul(w,he)|0))<<13)|0;f=((i=i+Math.imul(w,pe)|0)+(a>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(F,Y),a=(a=Math.imul(F,ee))+Math.imul(D,Y)|0,i=Math.imul(D,ee),n=n+Math.imul(B,re)|0,a=(a=a+Math.imul(B,ne)|0)+Math.imul(L,re)|0,i=i+Math.imul(L,ne)|0,n=n+Math.imul(C,ie)|0,a=(a=a+Math.imul(C,oe)|0)+Math.imul(R,ie)|0,i=i+Math.imul(R,oe)|0,n=n+Math.imul(T,se)|0,a=(a=a+Math.imul(T,fe)|0)+Math.imul(j,se)|0,i=i+Math.imul(j,fe)|0,n=n+Math.imul(E,ue)|0,a=(a=a+Math.imul(E,le)|0)+Math.imul(O,ue)|0,i=i+Math.imul(O,le)|0;var Te=(f+(n=n+Math.imul(_,he)|0)|0)+((8191&(a=(a=a+Math.imul(_,pe)|0)+Math.imul(M,he)|0))<<13)|0;f=((i=i+Math.imul(M,pe)|0)+(a>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,re),a=(a=Math.imul(F,ne))+Math.imul(D,re)|0,i=Math.imul(D,ne),n=n+Math.imul(B,ie)|0,a=(a=a+Math.imul(B,oe)|0)+Math.imul(L,ie)|0,i=i+Math.imul(L,oe)|0,n=n+Math.imul(C,se)|0,a=(a=a+Math.imul(C,fe)|0)+Math.imul(R,se)|0,i=i+Math.imul(R,fe)|0,n=n+Math.imul(T,ue)|0,a=(a=a+Math.imul(T,le)|0)+Math.imul(j,ue)|0,i=i+Math.imul(j,le)|0;var je=(f+(n=n+Math.imul(E,he)|0)|0)+((8191&(a=(a=a+Math.imul(E,pe)|0)+Math.imul(O,he)|0))<<13)|0;f=((i=i+Math.imul(O,pe)|0)+(a>>>13)|0)+(je>>>26)|0,je&=67108863,n=Math.imul(F,ie),a=(a=Math.imul(F,oe))+Math.imul(D,ie)|0,i=Math.imul(D,oe),n=n+Math.imul(B,se)|0,a=(a=a+Math.imul(B,fe)|0)+Math.imul(L,se)|0,i=i+Math.imul(L,fe)|0,n=n+Math.imul(C,ue)|0,a=(a=a+Math.imul(C,le)|0)+Math.imul(R,ue)|0,i=i+Math.imul(R,le)|0;var Pe=(f+(n=n+Math.imul(T,he)|0)|0)+((8191&(a=(a=a+Math.imul(T,pe)|0)+Math.imul(j,he)|0))<<13)|0;f=((i=i+Math.imul(j,pe)|0)+(a>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,se),a=(a=Math.imul(F,fe))+Math.imul(D,se)|0,i=Math.imul(D,fe),n=n+Math.imul(B,ue)|0,a=(a=a+Math.imul(B,le)|0)+Math.imul(L,ue)|0,i=i+Math.imul(L,le)|0;var Ce=(f+(n=n+Math.imul(C,he)|0)|0)+((8191&(a=(a=a+Math.imul(C,pe)|0)+Math.imul(R,he)|0))<<13)|0;f=((i=i+Math.imul(R,pe)|0)+(a>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,n=Math.imul(F,ue),a=(a=Math.imul(F,le))+Math.imul(D,ue)|0,i=Math.imul(D,le);var Re=(f+(n=n+Math.imul(B,he)|0)|0)+((8191&(a=(a=a+Math.imul(B,pe)|0)+Math.imul(L,he)|0))<<13)|0;f=((i=i+Math.imul(L,pe)|0)+(a>>>13)|0)+(Re>>>26)|0,Re&=67108863;var Ne=(f+(n=Math.imul(F,he))|0)+((8191&(a=(a=Math.imul(F,pe))+Math.imul(D,he)|0))<<13)|0;return f=((i=Math.imul(D,pe))+(a>>>13)|0)+(Ne>>>26)|0,Ne&=67108863,s[0]=me,s[1]=ve,s[2]=ge,s[3]=xe,s[4]=ye,s[5]=we,s[6]=ke,s[7]=_e,s[8]=Me,s[9]=Se,s[10]=Ee,s[11]=Oe,s[12]=Ae,s[13]=Te,s[14]=je,s[15]=Pe,s[16]=Ce,s[17]=Re,s[18]=Ne,0!==f&&(s[19]=f,r.length++),r};function p(e,t,r){return(new m).mulp(e,t,r)}function m(e,t){this.x=e,this.y=t}Math.imul||(h=b),i.prototype.mulTo=function(e,t){var r=this.length+e.length;return 10===this.length&&10===e.length?h(this,e,t):r<63?b(this,e,t):r<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,a=0,i=0;i>>26)|0)>>>26,o&=67108863}r.words[i]=c,n=o,o=a}return 0!==n?r.words[i]=n:r.length--,r.strip()}(this,e,t):p(this,e,t)},m.prototype.makeRBT=function(e){for(var t=new Array(e),r=i.prototype._countBits(e)-1,n=0;n>=1;return n},m.prototype.permute=function(e,t,r,n,a,i){for(var o=0;o>>=1)a++;return 1<>>=13,r[2*o+1]=8191&i,i>>>=13;for(o=2*t;o>=26,t+=a/67108864|0,t+=i>>>26,this.words[r]=67108863&i}return 0!==t&&(this.words[r]=t,this.length++),this},i.prototype.muln=function(e){return this.clone().imuln(e)},i.prototype.sqr=function(){return this.mul(this)},i.prototype.isqr=function(){return this.imul(this.clone())},i.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>a}return t}(e);if(0===t.length)return new i(1);for(var r=this,n=0;n=0);var t,r=e%26,a=(e-r)/26,i=67108863>>>26-r<<26-r;if(0!==r){var o=0;for(t=0;t>>26-r}o&&(this.words[t]=o,this.length++)}if(0!==a){for(t=this.length-1;t>=0;t--)this.words[t+a]=this.words[t];for(t=0;t=0),a=t?(t-t%26)/26:0;var i=e%26,o=Math.min((e-i)/26,this.length),c=67108863^67108863>>>i<o)for(this.length-=o,f=0;f=0&&(0!==d||f>=a);f--){var u=0|this.words[f];this.words[f]=d<<26-i|u>>>i,d=u&c}return s&&0!==d&&(s.words[s.length++]=d),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},i.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},i.prototype.shln=function(e){return this.clone().ishln(e)},i.prototype.ushln=function(e){return this.clone().iushln(e)},i.prototype.shrn=function(e){return this.clone().ishrn(e)},i.prototype.ushrn=function(e){return this.clone().iushrn(e)},i.prototype.testn=function(e){n("number"===typeof e&&e>=0);var t=e%26,r=(e-t)/26,a=1<=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var a=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},i.prototype.isubn=function(e){if(n("number"===typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(s/67108864|0),this.words[a+r]=67108863&i}for(;a>26,this.words[a+r]=67108863&i;if(0===c)return this.strip();for(n(-1===c),c=0,a=0;a>26,this.words[a]=67108863&i;return this.negative=1,this.strip()},i.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),a=e,o=0|a.words[a.length-1];0!==(r=26-this._countBits(o))&&(a=a.ushln(r),n.iushln(r),o=0|a.words[a.length-1]);var c,s=n.length-a.length;if("mod"!==t){(c=new i(null)).length=s+1,c.words=new Array(c.length);for(var f=0;f=0;u--){var l=67108864*(0|n.words[a.length+u])+(0|n.words[a.length+u-1]);for(l=Math.min(l/o|0,67108863),n._ishlnsubmul(a,l,u);0!==n.negative;)l--,n.negative=0,n._ishlnsubmul(a,1,u),n.isZero()||(n.negative^=1);c&&(c.words[u]=l)}return c&&c.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:c||null,mod:n}},i.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new i(0),mod:new i(0)}:0!==this.negative&&0===e.negative?(c=this.neg().divmod(e,t),"mod"!==t&&(a=c.div.neg()),"div"!==t&&(o=c.mod.neg(),r&&0!==o.negative&&o.iadd(e)),{div:a,mod:o}):0===this.negative&&0!==e.negative?(c=this.divmod(e.neg(),t),"mod"!==t&&(a=c.div.neg()),{div:a,mod:c.mod}):0!==(this.negative&e.negative)?(c=this.neg().divmod(e.neg(),t),"div"!==t&&(o=c.mod.neg(),r&&0!==o.negative&&o.isub(e)),{div:c.div,mod:o}):e.length>this.length||this.cmp(e)<0?{div:new i(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new i(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new i(this.modn(e.words[0]))}:this._wordDiv(e,t);var a,o,c},i.prototype.div=function(e){return this.divmod(e,"div",!1).div},i.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},i.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},i.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),a=e.andln(1),i=r.cmp(n);return i<0||1===a&&0===i?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},i.prototype.modn=function(e){n(e<=67108863);for(var t=(1<<26)%e,r=0,a=this.length-1;a>=0;a--)r=(t*r+(0|this.words[a]))%e;return r},i.prototype.idivn=function(e){n(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var a=(0|this.words[r])+67108864*t;this.words[r]=a/e|0,t=a%e}return this.strip()},i.prototype.divn=function(e){return this.clone().idivn(e)},i.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var a=new i(1),o=new i(0),c=new i(0),s=new i(1),f=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++f;for(var d=r.clone(),u=t.clone();!t.isZero();){for(var l=0,b=1;0===(t.words[0]&b)&&l<26;++l,b<<=1);if(l>0)for(t.iushrn(l);l-- >0;)(a.isOdd()||o.isOdd())&&(a.iadd(d),o.isub(u)),a.iushrn(1),o.iushrn(1);for(var h=0,p=1;0===(r.words[0]&p)&&h<26;++h,p<<=1);if(h>0)for(r.iushrn(h);h-- >0;)(c.isOdd()||s.isOdd())&&(c.iadd(d),s.isub(u)),c.iushrn(1),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(c),o.isub(s)):(r.isub(t),c.isub(a),s.isub(o))}return{a:c,b:s,gcd:r.iushln(f)}},i.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var a,o=new i(1),c=new i(0),s=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var f=0,d=1;0===(t.words[0]&d)&&f<26;++f,d<<=1);if(f>0)for(t.iushrn(f);f-- >0;)o.isOdd()&&o.iadd(s),o.iushrn(1);for(var u=0,l=1;0===(r.words[0]&l)&&u<26;++u,l<<=1);if(u>0)for(r.iushrn(u);u-- >0;)c.isOdd()&&c.iadd(s),c.iushrn(1);t.cmp(r)>=0?(t.isub(r),o.isub(c)):(r.isub(t),c.isub(o))}return(a=0===t.cmpn(1)?o:c).cmpn(0)<0&&a.iadd(e),a},i.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var a=t.cmp(r);if(a<0){var i=t;t=r,r=i}else if(0===a||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},i.prototype.invm=function(e){return this.egcd(e).a.umod(e)},i.prototype.isEven=function(){return 0===(1&this.words[0])},i.prototype.isOdd=function(){return 1===(1&this.words[0])},i.prototype.andln=function(e){return this.words[0]&e},i.prototype.bincn=function(e){n("number"===typeof e);var t=e%26,r=(e-t)/26,a=1<>>26,c&=67108863,this.words[o]=c}return 0!==i&&(this.words[o]=i,this.length++),this},i.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},i.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var a=0|this.words[0];t=a===e?0:ae.length)return 1;if(this.length=0;r--){var n=0|this.words[r],a=0|e.words[r];if(n!==a){na&&(t=1);break}}return t},i.prototype.gtn=function(e){return 1===this.cmpn(e)},i.prototype.gt=function(e){return 1===this.cmp(e)},i.prototype.gten=function(e){return this.cmpn(e)>=0},i.prototype.gte=function(e){return this.cmp(e)>=0},i.prototype.ltn=function(e){return-1===this.cmpn(e)},i.prototype.lt=function(e){return-1===this.cmp(e)},i.prototype.lten=function(e){return this.cmpn(e)<=0},i.prototype.lte=function(e){return this.cmp(e)<=0},i.prototype.eqn=function(e){return 0===this.cmpn(e)},i.prototype.eq=function(e){return 0===this.cmp(e)},i.red=function(e){return new _(e)},i.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},i.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},i.prototype._forceRed=function(e){return this.red=e,this},i.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},i.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},i.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},i.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},i.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},i.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},i.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},i.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},i.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},i.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},i.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},i.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},i.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},i.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var v={k256:null,p224:null,p192:null,p25519:null};function g(e,t){this.name=e,this.p=new i(t,16),this.n=this.p.bitLength(),this.k=new i(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function x(){g.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function y(){g.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function w(){g.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function k(){g.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function _(e){if("string"===typeof e){var t=i._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function M(e){_.call(this,e),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new i(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}g.prototype._tmp=function(){var e=new i(null);return e.words=new Array(Math.ceil(this.n/13)),e},g.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},g.prototype.split=function(e,t){e.iushrn(this.n,0,t)},g.prototype.imulK=function(e){return e.imul(this.k)},a(x,g),x.prototype.split=function(e,t){for(var r=Math.min(e.length,9),n=0;n>>22,a=i}a>>>=22,e.words[n-10]=a,0===a&&e.length>10?e.length-=10:e.length-=9},x.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=a,t=n}return 0!==t&&(e.words[e.length++]=t),e},i._prime=function(e){if(v[e])return v[e];var t;if("k256"===e)t=new x;else if("p224"===e)t=new y;else if("p192"===e)t=new w;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new k}return v[e]=t,t},_.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},_.prototype._verify2=function(e,t){n(0===(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},_.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},_.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},_.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},_.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},_.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},_.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},_.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},_.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},_.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},_.prototype.isqr=function(e){return this.imul(e,e.clone())},_.prototype.sqr=function(e){return this.mul(e,e)},_.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2===1),3===t){var r=this.m.add(new i(1)).iushrn(2);return this.pow(e,r)}for(var a=this.m.subn(1),o=0;!a.isZero()&&0===a.andln(1);)o++,a.iushrn(1);n(!a.isZero());var c=new i(1).toRed(this),s=c.redNeg(),f=this.m.subn(1).iushrn(1),d=this.m.bitLength();for(d=new i(2*d*d).toRed(this);0!==this.pow(d,f).cmp(s);)d.redIAdd(s);for(var u=this.pow(d,a),l=this.pow(e,a.addn(1).iushrn(1)),b=this.pow(e,a),h=o;0!==b.cmp(c);){for(var p=b,m=0;0!==p.cmp(c);m++)p=p.redSqr();n(m=0;n--){for(var f=t.words[n],d=s-1;d>=0;d--){var u=f>>d&1;a!==r[0]&&(a=this.sqr(a)),0!==u||0!==o?(o<<=1,o|=u,(4===++c||0===n&&0===d)&&(a=this.mul(a,r[o]),c=0,o=0)):c=0}s=26}return a},_.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},_.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},i.mont=function(e){return new M(e)},a(M,_),M.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},M.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},M.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),a=r.isub(n).iushrn(this.shift),i=a;return a.cmp(this.m)>=0?i=a.isub(this.m):a.cmpn(0)<0&&(i=a.iadd(this.m)),i._forceRed(this)},M.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new i(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),a=r.isub(n).iushrn(this.shift),o=a;return a.cmp(this.m)>=0?o=a.isub(this.m):a.cmpn(0)<0&&(o=a.iadd(this.m)),o._forceRed(this)},M.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e,this)}).call(this,r(74)(e))},function(e,t,r){var n=r(402);e.exports=function(e,t){if(e){if("string"===typeof e)return n(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(r):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?n(e,t):void 0}}},function(e,t,r){var n;function a(e){this.rand=e}if(e.exports=function(e){return n||(n=new a(null)),n.generate(e)},e.exports.Rand=a,a.prototype.generate=function(e){return this._rand(e)},a.prototype._rand=function(e){if(this.rand.getBytes)return this.rand.getBytes(e);for(var t=new Uint8Array(e),r=0;r>>32-t}function f(e,t,r,n,a,i,o){return s(e+(t&r|~t&n)+a+i|0,o)+t|0}function d(e,t,r,n,a,i,o){return s(e+(t&n|r&~n)+a+i|0,o)+t|0}function u(e,t,r,n,a,i,o){return s(e+(t^r^n)+a+i|0,o)+t|0}function l(e,t,r,n,a,i,o){return s(e+(r^(t|~n))+a+i|0,o)+t|0}n(c,a),c.prototype._update=function(){for(var e=o,t=0;t<16;++t)e[t]=this._block.readInt32LE(4*t);var r=this._a,n=this._b,a=this._c,i=this._d;r=f(r,n,a,i,e[0],3614090360,7),i=f(i,r,n,a,e[1],3905402710,12),a=f(a,i,r,n,e[2],606105819,17),n=f(n,a,i,r,e[3],3250441966,22),r=f(r,n,a,i,e[4],4118548399,7),i=f(i,r,n,a,e[5],1200080426,12),a=f(a,i,r,n,e[6],2821735955,17),n=f(n,a,i,r,e[7],4249261313,22),r=f(r,n,a,i,e[8],1770035416,7),i=f(i,r,n,a,e[9],2336552879,12),a=f(a,i,r,n,e[10],4294925233,17),n=f(n,a,i,r,e[11],2304563134,22),r=f(r,n,a,i,e[12],1804603682,7),i=f(i,r,n,a,e[13],4254626195,12),a=f(a,i,r,n,e[14],2792965006,17),r=d(r,n=f(n,a,i,r,e[15],1236535329,22),a,i,e[1],4129170786,5),i=d(i,r,n,a,e[6],3225465664,9),a=d(a,i,r,n,e[11],643717713,14),n=d(n,a,i,r,e[0],3921069994,20),r=d(r,n,a,i,e[5],3593408605,5),i=d(i,r,n,a,e[10],38016083,9),a=d(a,i,r,n,e[15],3634488961,14),n=d(n,a,i,r,e[4],3889429448,20),r=d(r,n,a,i,e[9],568446438,5),i=d(i,r,n,a,e[14],3275163606,9),a=d(a,i,r,n,e[3],4107603335,14),n=d(n,a,i,r,e[8],1163531501,20),r=d(r,n,a,i,e[13],2850285829,5),i=d(i,r,n,a,e[2],4243563512,9),a=d(a,i,r,n,e[7],1735328473,14),r=u(r,n=d(n,a,i,r,e[12],2368359562,20),a,i,e[5],4294588738,4),i=u(i,r,n,a,e[8],2272392833,11),a=u(a,i,r,n,e[11],1839030562,16),n=u(n,a,i,r,e[14],4259657740,23),r=u(r,n,a,i,e[1],2763975236,4),i=u(i,r,n,a,e[4],1272893353,11),a=u(a,i,r,n,e[7],4139469664,16),n=u(n,a,i,r,e[10],3200236656,23),r=u(r,n,a,i,e[13],681279174,4),i=u(i,r,n,a,e[0],3936430074,11),a=u(a,i,r,n,e[3],3572445317,16),n=u(n,a,i,r,e[6],76029189,23),r=u(r,n,a,i,e[9],3654602809,4),i=u(i,r,n,a,e[12],3873151461,11),a=u(a,i,r,n,e[15],530742520,16),r=l(r,n=u(n,a,i,r,e[2],3299628645,23),a,i,e[0],4096336452,6),i=l(i,r,n,a,e[7],1126891415,10),a=l(a,i,r,n,e[14],2878612391,15),n=l(n,a,i,r,e[5],4237533241,21),r=l(r,n,a,i,e[12],1700485571,6),i=l(i,r,n,a,e[3],2399980690,10),a=l(a,i,r,n,e[10],4293915773,15),n=l(n,a,i,r,e[1],2240044497,21),r=l(r,n,a,i,e[8],1873313359,6),i=l(i,r,n,a,e[15],4264355552,10),a=l(a,i,r,n,e[6],2734768916,15),n=l(n,a,i,r,e[13],1309151649,21),r=l(r,n,a,i,e[4],4149444226,6),i=l(i,r,n,a,e[11],3174756917,10),a=l(a,i,r,n,e[2],718787259,15),n=l(n,a,i,r,e[9],3951481745,21),this._a=this._a+r|0,this._b=this._b+n|0,this._c=this._c+a|0,this._d=this._d+i|0},c.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var e=i.allocUnsafe(16);return e.writeInt32LE(this._a,0),e.writeInt32LE(this._b,4),e.writeInt32LE(this._c,8),e.writeInt32LE(this._d,12),e},e.exports=c},function(e,t,r){"use strict";var n=r(170).codes.ERR_STREAM_PREMATURE_CLOSE;function a(){}e.exports=function e(t,r,i){if("function"===typeof r)return e(t,null,r);r||(r={}),i=function(e){var t=!1;return function(){if(!t){t=!0;for(var r=arguments.length,n=new Array(r),a=0;a>>32-t}function p(e,t,r,n,a,i,o,c){return h(e+(t^r^n)+i+o|0,c)+a|0}function m(e,t,r,n,a,i,o,c){return h(e+(t&r|~t&n)+i+o|0,c)+a|0}function v(e,t,r,n,a,i,o,c){return h(e+((t|~r)^n)+i+o|0,c)+a|0}function g(e,t,r,n,a,i,o,c){return h(e+(t&n|r&~n)+i+o|0,c)+a|0}function x(e,t,r,n,a,i,o,c){return h(e+(t^(r|~n))+i+o|0,c)+a|0}a(b,i),b.prototype._update=function(){for(var e=o,t=0;t<16;++t)e[t]=this._block.readInt32LE(4*t);for(var r=0|this._a,n=0|this._b,a=0|this._c,i=0|this._d,b=0|this._e,y=0|this._a,w=0|this._b,k=0|this._c,_=0|this._d,M=0|this._e,S=0;S<80;S+=1){var E,O;S<16?(E=p(r,n,a,i,b,e[c[S]],u[0],f[S]),O=x(y,w,k,_,M,e[s[S]],l[0],d[S])):S<32?(E=m(r,n,a,i,b,e[c[S]],u[1],f[S]),O=g(y,w,k,_,M,e[s[S]],l[1],d[S])):S<48?(E=v(r,n,a,i,b,e[c[S]],u[2],f[S]),O=v(y,w,k,_,M,e[s[S]],l[2],d[S])):S<64?(E=g(r,n,a,i,b,e[c[S]],u[3],f[S]),O=m(y,w,k,_,M,e[s[S]],l[3],d[S])):(E=x(r,n,a,i,b,e[c[S]],u[4],f[S]),O=p(y,w,k,_,M,e[s[S]],l[4],d[S])),r=b,b=i,i=h(a,10),a=n,n=E,y=M,M=_,_=h(k,10),k=w,w=O}var A=this._b+a+_|0;this._b=this._c+i+M|0,this._c=this._d+b+y|0,this._d=this._e+r+w|0,this._e=this._a+n+k|0,this._a=A},b.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var e=n.alloc?n.alloc(20):new n(20);return e.writeInt32LE(this._a,0),e.writeInt32LE(this._b,4),e.writeInt32LE(this._c,8),e.writeInt32LE(this._d,12),e.writeInt32LE(this._e,16),e},e.exports=b},function(e,t,r){(t=e.exports=function(e){e=e.toLowerCase();var r=t[e];if(!r)throw new Error(e+" is not supported (we accept pull requests)");return new r}).sha=r(679),t.sha1=r(680),t.sha224=r(681),t.sha256=r(420),t.sha384=r(682),t.sha512=r(421)},function(e,t,r){var n=r(30),a=n.Buffer;function i(e,t){for(var r in e)t[r]=e[r]}function o(e,t,r){return a(e,t,r)}a.from&&a.alloc&&a.allocUnsafe&&a.allocUnsafeSlow?e.exports=n:(i(n,t),t.Buffer=o),i(a,o),o.from=function(e,t,r){if("number"===typeof e)throw new TypeError("Argument must not be a number");return a(e,t,r)},o.alloc=function(e,t,r){if("number"!==typeof e)throw new TypeError("Argument must be a number");var n=a(e);return void 0!==t?"string"===typeof r?n.fill(t,r):n.fill(t):n.fill(0),n},o.allocUnsafe=function(e){if("number"!==typeof e)throw new TypeError("Argument must be a number");return a(e)},o.allocUnsafeSlow=function(e){if("number"!==typeof e)throw new TypeError("Argument must be a number");return n.SlowBuffer(e)}},function(e,t,r){"use strict";(function(t,n,a){var i=r(240);function o(e){var t=this;this.next=null,this.entry=null,this.finish=function(){!function(e,t,r){var n=e.entry;e.entry=null;for(;n;){var a=n.callback;t.pendingcb--,a(r),n=n.next}t.corkedRequestsFree?t.corkedRequestsFree.next=e:t.corkedRequestsFree=e}(t,e)}}e.exports=g;var c,s=!t.browser&&["v0.10","v0.9."].indexOf(t.version.slice(0,5))>-1?n:i.nextTick;g.WritableState=v;var f=Object.create(r(200));f.inherits=r(33);var d={deprecate:r(239)},u=r(423),l=r(308).Buffer,b=a.Uint8Array||function(){};var h,p=r(424);function m(){}function v(e,t){c=c||r(152),e=e||{};var n=t instanceof c;this.objectMode=!!e.objectMode,n&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var a=e.highWaterMark,f=e.writableHighWaterMark,d=this.objectMode?16:16384;this.highWaterMark=a||0===a?a:n&&(f||0===f)?f:d,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var u=!1===e.decodeStrings;this.decodeStrings=!u,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){!function(e,t){var r=e._writableState,n=r.sync,a=r.writecb;if(function(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}(r),t)!function(e,t,r,n,a){--t.pendingcb,r?(i.nextTick(a,n),i.nextTick(M,e,t),e._writableState.errorEmitted=!0,e.emit("error",n)):(a(n),e._writableState.errorEmitted=!0,e.emit("error",n),M(e,t))}(e,r,n,t,a);else{var o=k(r);o||r.corked||r.bufferProcessing||!r.bufferedRequest||w(e,r),n?s(y,e,r,o,a):y(e,r,o,a)}}(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new o(this)}function g(e){if(c=c||r(152),!h.call(g,this)&&!(this instanceof c))return new g(e);this._writableState=new v(e,this),this.writable=!0,e&&("function"===typeof e.write&&(this._write=e.write),"function"===typeof e.writev&&(this._writev=e.writev),"function"===typeof e.destroy&&(this._destroy=e.destroy),"function"===typeof e.final&&(this._final=e.final)),u.call(this)}function x(e,t,r,n,a,i,o){t.writelen=n,t.writecb=o,t.writing=!0,t.sync=!0,r?e._writev(a,t.onwrite):e._write(a,i,t.onwrite),t.sync=!1}function y(e,t,r,n){r||function(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}(e,t),t.pendingcb--,n(),M(e,t)}function w(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var n=t.bufferedRequestCount,a=new Array(n),i=t.corkedRequestsFree;i.entry=r;for(var c=0,s=!0;r;)a[c]=r,r.isBuf||(s=!1),r=r.next,c+=1;a.allBuffers=s,x(e,t,!0,t.length,a,"",i.finish),t.pendingcb++,t.lastBufferedRequest=null,i.next?(t.corkedRequestsFree=i.next,i.next=null):t.corkedRequestsFree=new o(t),t.bufferedRequestCount=0}else{for(;r;){var f=r.chunk,d=r.encoding,u=r.callback;if(x(e,t,!1,t.objectMode?1:f.length,f,d,u),r=r.next,t.bufferedRequestCount--,t.writing)break}null===r&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}function k(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function _(e,t){e._final((function(r){t.pendingcb--,r&&e.emit("error",r),t.prefinished=!0,e.emit("prefinish"),M(e,t)}))}function M(e,t){var r=k(t);return r&&(!function(e,t){t.prefinished||t.finalCalled||("function"===typeof e._final?(t.pendingcb++,t.finalCalled=!0,i.nextTick(_,e,t)):(t.prefinished=!0,e.emit("prefinish")))}(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"))),r}f.inherits(g,u),v.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t},function(){try{Object.defineProperty(v.prototype,"buffer",{get:d.deprecate((function(){return this.getBuffer()}),"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"===typeof Symbol&&Symbol.hasInstance&&"function"===typeof Function.prototype[Symbol.hasInstance]?(h=Function.prototype[Symbol.hasInstance],Object.defineProperty(g,Symbol.hasInstance,{value:function(e){return!!h.call(this,e)||this===g&&(e&&e._writableState instanceof v)}})):h=function(e){return e instanceof this},g.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},g.prototype.write=function(e,t,r){var n,a=this._writableState,o=!1,c=!a.objectMode&&(n=e,l.isBuffer(n)||n instanceof b);return c&&!l.isBuffer(e)&&(e=function(e){return l.from(e)}(e)),"function"===typeof t&&(r=t,t=null),c?t="buffer":t||(t=a.defaultEncoding),"function"!==typeof r&&(r=m),a.ended?function(e,t){var r=new Error("write after end");e.emit("error",r),i.nextTick(t,r)}(this,r):(c||function(e,t,r,n){var a=!0,o=!1;return null===r?o=new TypeError("May not write null values to stream"):"string"===typeof r||void 0===r||t.objectMode||(o=new TypeError("Invalid non-string/buffer chunk")),o&&(e.emit("error",o),i.nextTick(n,o),a=!1),a}(this,a,e,r))&&(a.pendingcb++,o=function(e,t,r,n,a,i){if(!r){var o=function(e,t,r){e.objectMode||!1===e.decodeStrings||"string"!==typeof t||(t=l.from(t,r));return t}(t,n,a);n!==o&&(r=!0,a="buffer",n=o)}var c=t.objectMode?1:n.length;t.length+=c;var s=t.length-1))throw new TypeError("Unknown encoding: "+e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(g.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),g.prototype._write=function(e,t,r){r(new Error("_write() is not implemented"))},g.prototype._writev=null,g.prototype.end=function(e,t,r){var n=this._writableState;"function"===typeof e?(r=e,e=null,t=null):"function"===typeof t&&(r=t,t=null),null!==e&&void 0!==e&&this.write(e,t),n.corked&&(n.corked=1,this.uncork()),n.ending||n.finished||function(e,t,r){t.ending=!0,M(e,t),r&&(t.finished?i.nextTick(r):e.once("finish",r));t.ended=!0,e.writable=!1}(this,n,r)},Object.defineProperty(g.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),g.prototype.destroy=p.destroy,g.prototype._undestroy=p.undestroy,g.prototype._destroy=function(e,t){this.end(),t(e)}}).call(this,r(48),r(388).setImmediate,r(44))},function(e,t,r){"use strict";(function(e){var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.toType=t.TypeOutput=t.bnToRlp=t.bnToUnpaddedBuffer=t.bnToHex=void 0;var a,i=n(r(150)),o=r(167),c=r(151);function s(t){return(0,c.unpadBuffer)(t.toArrayLike(e))}t.bnToHex=function(e){return"0x"+e.toString(16)},t.bnToUnpaddedBuffer=s,t.bnToRlp=function(e){return s(e)},function(e){e[e.Number=0]="Number",e[e.BN=1]="BN",e[e.Buffer=2]="Buffer",e[e.PrefixedHexString=3]="PrefixedHexString"}(a=t.TypeOutput||(t.TypeOutput={})),t.toType=function(e,t){if(null===e)return null;if(void 0!==e){if("string"===typeof e&&!(0,o.isHexString)(e))throw new Error("A string must be provided with a 0x-prefix, given: "+e);if("number"===typeof e&&!Number.isSafeInteger(e))throw new Error("The provided number is greater than MAX_SAFE_INTEGER (please use an alternative input type)");var r=(0,c.toBuffer)(e);if(t===a.Buffer)return r;if(t===a.BN)return new i.default(r);if(t===a.Number){var n=new i.default(r),s=new i.default(Number.MAX_SAFE_INTEGER.toString());if(n.gt(s))throw new Error("The provided number is greater than MAX_SAFE_INTEGER (please use an alternative output type)");return n.toNumber()}return"0x"+r.toString("hex")}}}).call(this,r(30).Buffer)},function(e,t,r){(function(e){var n=r(722),a=r(430),i=r(385),o=r(724),c=r(173),s=t;s.request=function(t,r){t="string"===typeof t?c.parse(t):i(t);var a=-1===e.location.protocol.search(/^https?:$/)?"http:":"",o=t.protocol||a,s=t.hostname||t.host,f=t.port,d=t.path||"/";s&&-1!==s.indexOf(":")&&(s="["+s+"]"),t.url=(s?o+"//"+s:"")+(f?":"+f:"")+d,t.method=(t.method||"GET").toUpperCase(),t.headers=t.headers||{};var u=new n(t);return r&&u.on("response",r),u},s.get=function(e,t){var r=s.request(e,t);return r.end(),r},s.ClientRequest=n,s.IncomingMessage=a.IncomingMessage,s.Agent=function(){},s.Agent.defaultMaxSockets=4,s.globalAgent=new s.Agent,s.STATUS_CODES=o,s.METHODS=["CHECKOUT","CONNECT","COPY","DELETE","GET","HEAD","LOCK","M-SEARCH","MERGE","MKACTIVITY","MKCOL","MOVE","NOTIFY","OPTIONS","PATCH","POST","PROPFIND","PROPPATCH","PURGE","PUT","REPORT","SEARCH","SUBSCRIBE","TRACE","UNLOCK","UNSUBSCRIBE"]}).call(this,r(44))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(){function e(){this.listeners={}}return e.prototype.addEventListener=function(e,t){e=e.toLowerCase(),this.listeners[e]=this.listeners[e]||[],this.listeners[e].push(t.handleEvent||t)},e.prototype.removeEventListener=function(e,t){if(e=e.toLowerCase(),this.listeners[e]){var r=this.listeners[e].indexOf(t.handleEvent||t);r<0||this.listeners[e].splice(r,1)}},e.prototype.dispatchEvent=function(e){var t=e.type.toLowerCase();if(e.target=this,this.listeners[t])for(var r=0,n=this.listeners[t];r 2 bytes.");var r=i.decode(e);if(!t.isValidCode(r))throw new Error("multihash unknown function code: 0x".concat(r.toString(16)));e=e.slice(i.decode.bytes);var a=i.decode(e);if(a<0)throw new Error("multihash invalid length: ".concat(a));if((e=e.slice(i.decode.bytes)).length!==a)throw new Error("multihash length inconsistent: 0x".concat(e.toString("hex")));return{code:r,name:o.codes[r],length:a,digest:e}},t.encode=function(e,r,a){if(!e||void 0===r)throw new Error("multihash encode requires at least two args: digest, code");var o=t.coerceCode(r);if(!n.isBuffer(e))throw new Error("digest should be a Buffer");if(null==a&&(a=e.length),a&&e.length!==a)throw new Error("digest length should be equal to specified length.");return n.concat([n.from(i.encode(o)),n.from(i.encode(a)),e])},t.coerceCode=function(e){var r=e;if("string"===typeof e){if(void 0===o.names[e])throw new Error("Unrecognized hash function named: ".concat(e));r=o.names[e]}if("number"!==typeof r)throw new Error("Hash function code should be a number. Got: ".concat(r));if(void 0===o.codes[r]&&!t.isAppCode(r))throw new Error("Unrecognized function code: ".concat(r));return r},t.isAppCode=function(e){return e>0&&e<16},t.isValidCode=function(e){return!!t.isAppCode(e)||!!o.codes[e]},t.validate=c,t.prefix=function(e){return c(e),e.slice(0,2)}},function(e,t,r){"use strict";var n=r(93);function a(e){this.options=e,this.type=this.options.type,this.blockSize=8,this._init(),this.buffer=new Array(this.blockSize),this.bufferOff=0}e.exports=a,a.prototype._init=function(){},a.prototype.update=function(e){return 0===e.length?[]:"decrypt"===this.type?this._updateDecrypt(e):this._updateEncrypt(e)},a.prototype._buffer=function(e,t){for(var r=Math.min(this.buffer.length-this.bufferOff,e.length-t),n=0;n0;n--)t+=this._buffer(e,t),r+=this._flushBuffer(a,r);return t+=this._buffer(e,t),a},a.prototype.final=function(e){var t,r;return e&&(t=this.update(e)),r="encrypt"===this.type?this._finalEncrypt():this._finalDecrypt(),t?t.concat(r):r},a.prototype._pad=function(e,t){if(0===t)return!1;for(;t=0||!t.umod(e.prime1)||!t.umod(e.prime2));return t}function o(e,r){var a=function(e){var t=i(e);return{blinder:t.toRed(n.mont(e.modulus)).redPow(new n(e.publicExponent)).fromRed(),unblinder:t.invm(e.modulus)}}(r),o=r.modulus.byteLength(),c=new n(e).mul(a.blinder).umod(r.modulus),s=c.toRed(n.mont(r.prime1)),f=c.toRed(n.mont(r.prime2)),d=r.coefficient,u=r.prime1,l=r.prime2,b=s.redPow(r.exponent1).fromRed(),h=f.redPow(r.exponent2).fromRed(),p=b.isub(h).imul(d).umod(u).imul(l);return h.iadd(p).imul(a.unblinder).umod(r.modulus).toArrayLike(t,"be",o)}o.getr=i,e.exports=o}).call(this,r(30).Buffer)},function(e,t,r){"use strict";(function(t){var n,a=r(30),i=a.Buffer,o={};for(n in a)a.hasOwnProperty(n)&&"SlowBuffer"!==n&&"Buffer"!==n&&(o[n]=a[n]);var c=o.Buffer={};for(n in i)i.hasOwnProperty(n)&&"allocUnsafe"!==n&&"allocUnsafeSlow"!==n&&(c[n]=i[n]);if(o.Buffer.prototype=i.prototype,c.from&&c.from!==Uint8Array.from||(c.from=function(e,t,r){if("number"===typeof e)throw new TypeError('The "value" argument must not be of type number. Received type '+typeof e);if(e&&"undefined"===typeof e.length)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);return i(e,t,r)}),c.alloc||(c.alloc=function(e,t,r){if("number"!==typeof e)throw new TypeError('The "size" argument must be of type number. Received type '+typeof e);if(e<0||e>=2*(1<<30))throw new RangeError('The value "'+e+'" is invalid for option "size"');var n=i(e);return t&&0!==t.length?"string"===typeof r?n.fill(t,r):n.fill(t):n.fill(0),n}),!o.kStringMaxLength)try{o.kStringMaxLength=t.binding("buffer").kStringMaxLength}catch(s){}o.constants||(o.constants={MAX_LENGTH:o.kMaxLength},o.kStringMaxLength&&(o.constants.MAX_STRING_LENGTH=o.kStringMaxLength)),e.exports=o}).call(this,r(48))},function(e,t,r){"use strict";var n=r(321).Reporter,a=r(203).EncoderBuffer,i=r(203).DecoderBuffer,o=r(93),c=["seq","seqof","set","setof","objid","bool","gentime","utctime","null_","enum","int","objDesc","bitstr","bmpstr","charstr","genstr","graphstr","ia5str","iso646str","numstr","octstr","printstr","t61str","unistr","utf8str","videostr"],s=["key","obj","use","optional","explicit","implicit","def","choice","any","contains"].concat(c);function f(e,t,r){var n={};this._baseState=n,n.name=r,n.enc=e,n.parent=t||null,n.children=null,n.tag=null,n.args=null,n.reverseArgs=null,n.choice=null,n.optional=!1,n.any=!1,n.obj=!1,n.use=null,n.useDecoder=null,n.key=null,n.default=null,n.explicit=null,n.implicit=null,n.contains=null,n.parent||(n.children=[],this._wrap())}e.exports=f;var d=["enc","parent","children","tag","args","reverseArgs","choice","optional","any","obj","use","alteredUse","key","default","explicit","implicit","contains"];f.prototype.clone=function(){var e=this._baseState,t={};d.forEach((function(r){t[r]=e[r]}));var r=new this.constructor(t.parent);return r._baseState=t,r},f.prototype._wrap=function(){var e=this._baseState;s.forEach((function(t){this[t]=function(){var r=new this.constructor(this);return e.children.push(r),r[t].apply(r,arguments)}}),this)},f.prototype._init=function(e){var t=this._baseState;o(null===t.parent),e.call(this),t.children=t.children.filter((function(e){return e._baseState.parent===this}),this),o.equal(t.children.length,1,"Root node can have only one child")},f.prototype._useArgs=function(e){var t=this._baseState,r=e.filter((function(e){return e instanceof this.constructor}),this);e=e.filter((function(e){return!(e instanceof this.constructor)}),this),0!==r.length&&(o(null===t.children),t.children=r,r.forEach((function(e){e._baseState.parent=this}),this)),0!==e.length&&(o(null===t.args),t.args=e,t.reverseArgs=e.map((function(e){if("object"!==typeof e||e.constructor!==Object)return e;var t={};return Object.keys(e).forEach((function(r){r==(0|r)&&(r|=0);var n=e[r];t[n]=r})),t})))},["_peekTag","_decodeTag","_use","_decodeStr","_decodeObjid","_decodeTime","_decodeNull","_decodeInt","_decodeBool","_decodeList","_encodeComposite","_encodeStr","_encodeObjid","_encodeTime","_encodeNull","_encodeInt","_encodeBool"].forEach((function(e){f.prototype[e]=function(){var t=this._baseState;throw new Error(e+" not implemented for encoding: "+t.enc)}})),c.forEach((function(e){f.prototype[e]=function(){var t=this._baseState,r=Array.prototype.slice.call(arguments);return o(null===t.tag),t.tag=e,this._useArgs(r),this}})),f.prototype.use=function(e){o(e);var t=this._baseState;return o(null===t.use),t.use=e,this},f.prototype.optional=function(){return this._baseState.optional=!0,this},f.prototype.def=function(e){var t=this._baseState;return o(null===t.default),t.default=e,t.optional=!0,this},f.prototype.explicit=function(e){var t=this._baseState;return o(null===t.explicit&&null===t.implicit),t.explicit=e,this},f.prototype.implicit=function(e){var t=this._baseState;return o(null===t.explicit&&null===t.implicit),t.implicit=e,this},f.prototype.obj=function(){var e=this._baseState,t=Array.prototype.slice.call(arguments);return e.obj=!0,0!==t.length&&this._useArgs(t),this},f.prototype.key=function(e){var t=this._baseState;return o(null===t.key),t.key=e,this},f.prototype.any=function(){return this._baseState.any=!0,this},f.prototype.choice=function(e){var t=this._baseState;return o(null===t.choice),t.choice=e,this._useArgs(Object.keys(e).map((function(t){return e[t]}))),this},f.prototype.contains=function(e){var t=this._baseState;return o(null===t.use),t.contains=e,this},f.prototype._decode=function(e,t){var r=this._baseState;if(null===r.parent)return e.wrapResult(r.children[0]._decode(e,t));var n,a=r.default,o=!0,c=null;if(null!==r.key&&(c=e.enterKey(r.key)),r.optional){var s=null;if(null!==r.explicit?s=r.explicit:null!==r.implicit?s=r.implicit:null!==r.tag&&(s=r.tag),null!==s||r.any){if(o=this._peekTag(e,s,r.any),e.isError(o))return o}else{var f=e.save();try{null===r.choice?this._decodeGeneric(r.tag,e,t):this._decodeChoice(e,t),o=!0}catch(p){o=!1}e.restore(f)}}if(r.obj&&o&&(n=e.enterObject()),o){if(null!==r.explicit){var d=this._decodeTag(e,r.explicit);if(e.isError(d))return d;e=d}var u=e.offset;if(null===r.use&&null===r.choice){var l;r.any&&(l=e.save());var b=this._decodeTag(e,null!==r.implicit?r.implicit:r.tag,r.any);if(e.isError(b))return b;r.any?a=e.raw(l):e=b}if(t&&t.track&&null!==r.tag&&t.track(e.path(),u,e.length,"tagged"),t&&t.track&&null!==r.tag&&t.track(e.path(),e.offset,e.length,"content"),r.any||(a=null===r.choice?this._decodeGeneric(r.tag,e,t):this._decodeChoice(e,t)),e.isError(a))return a;if(r.any||null!==r.choice||null===r.children||r.children.forEach((function(r){r._decode(e,t)})),r.contains&&("octstr"===r.tag||"bitstr"===r.tag)){var h=new i(a);a=this._getUse(r.contains,e._reporterState.obj)._decode(h,t)}}return r.obj&&o&&(a=e.leaveObject(n)),null===r.key||null===a&&!0!==o?null!==c&&e.exitKey(c):e.leaveKey(c,r.key,a),a},f.prototype._decodeGeneric=function(e,t,r){var n=this._baseState;return"seq"===e||"set"===e?null:"seqof"===e||"setof"===e?this._decodeList(t,e,n.args[0],r):/str$/.test(e)?this._decodeStr(t,e,r):"objid"===e&&n.args?this._decodeObjid(t,n.args[0],n.args[1],r):"objid"===e?this._decodeObjid(t,null,null,r):"gentime"===e||"utctime"===e?this._decodeTime(t,e,r):"null_"===e?this._decodeNull(t,r):"bool"===e?this._decodeBool(t,r):"objDesc"===e?this._decodeStr(t,e,r):"int"===e||"enum"===e?this._decodeInt(t,n.args&&n.args[0],r):null!==n.use?this._getUse(n.use,t._reporterState.obj)._decode(t,r):t.error("unknown tag: "+e)},f.prototype._getUse=function(e,t){var r=this._baseState;return r.useDecoder=this._use(e,t),o(null===r.useDecoder._baseState.parent),r.useDecoder=r.useDecoder._baseState.children[0],r.implicit!==r.useDecoder._baseState.implicit&&(r.useDecoder=r.useDecoder.clone(),r.useDecoder._baseState.implicit=r.implicit),r.useDecoder},f.prototype._decodeChoice=function(e,t){var r=this._baseState,n=null,a=!1;return Object.keys(r.choice).some((function(i){var o=e.save(),c=r.choice[i];try{var s=c._decode(e,t);if(e.isError(s))return!1;n={type:i,value:s},a=!0}catch(f){return e.restore(o),!1}return!0}),this),a?n:e.error("Choice not matched")},f.prototype._createEncoderBuffer=function(e){return new a(e,this.reporter)},f.prototype._encode=function(e,t,r){var n=this._baseState;if(null===n.default||n.default!==e){var a=this._encodeValue(e,t,r);if(void 0!==a&&!this._skipDefault(a,t,r))return a}},f.prototype._encodeValue=function(e,t,r){var a=this._baseState;if(null===a.parent)return a.children[0]._encode(e,t||new n);var i=null;if(this.reporter=t,a.optional&&void 0===e){if(null===a.default)return;e=a.default}var o=null,c=!1;if(a.any)i=this._createEncoderBuffer(e);else if(a.choice)i=this._encodeChoice(e,t);else if(a.contains)o=this._getUse(a.contains,r)._encode(e,t),c=!0;else if(a.children)o=a.children.map((function(r){if("null_"===r._baseState.tag)return r._encode(null,t,e);if(null===r._baseState.key)return t.error("Child should have a key");var n=t.enterKey(r._baseState.key);if("object"!==typeof e)return t.error("Child expected, but input is not object");var a=r._encode(e[r._baseState.key],t,e);return t.leaveKey(n),a}),this).filter((function(e){return e})),o=this._createEncoderBuffer(o);else if("seqof"===a.tag||"setof"===a.tag){if(!a.args||1!==a.args.length)return t.error("Too many args for : "+a.tag);if(!Array.isArray(e))return t.error("seqof/setof, but data is not Array");var s=this.clone();s._baseState.implicit=null,o=this._createEncoderBuffer(e.map((function(r){var n=this._baseState;return this._getUse(n.args[0],e)._encode(r,t)}),s))}else null!==a.use?i=this._getUse(a.use,r)._encode(e,t):(o=this._encodePrimitive(a.tag,e),c=!0);if(!a.any&&null===a.choice){var f=null!==a.implicit?a.implicit:a.tag,d=null===a.implicit?"universal":"context";null===f?null===a.use&&t.error("Tag could be omitted only for .use()"):null===a.use&&(i=this._encodeComposite(f,c,d,o))}return null!==a.explicit&&(i=this._encodeComposite(a.explicit,!1,"context",i)),i},f.prototype._encodeChoice=function(e,t){var r=this._baseState,n=r.choice[e.type];return n||o(!1,e.type+" not found in "+JSON.stringify(Object.keys(r.choice))),n._encode(e.value,t)},f.prototype._encodePrimitive=function(e,t){var r=this._baseState;if(/str$/.test(e))return this._encodeStr(t,e);if("objid"===e&&r.args)return this._encodeObjid(t,r.reverseArgs[0],r.args[1]);if("objid"===e)return this._encodeObjid(t,null,null);if("gentime"===e||"utctime"===e)return this._encodeTime(t,e);if("null_"===e)return this._encodeNull();if("int"===e||"enum"===e)return this._encodeInt(t,r.args&&r.reverseArgs[0]);if("bool"===e)return this._encodeBool(t);if("objDesc"===e)return this._encodeStr(t,e);throw new Error("Unsupported tag: "+e)},f.prototype._isNumstr=function(e){return/^[0-9 ]*$/.test(e)},f.prototype._isPrintstr=function(e){return/^[A-Za-z0-9 '()+,-./:=?]*$/.test(e)}},function(e,t,r){"use strict";var n=r(33);function a(e){this._reporterState={obj:null,path:[],options:e||{},errors:[]}}function i(e,t){this.path=e,this.rethrow(t)}t.Reporter=a,a.prototype.isError=function(e){return e instanceof i},a.prototype.save=function(){var e=this._reporterState;return{obj:e.obj,pathLen:e.path.length}},a.prototype.restore=function(e){var t=this._reporterState;t.obj=e.obj,t.path=t.path.slice(0,e.pathLen)},a.prototype.enterKey=function(e){return this._reporterState.path.push(e)},a.prototype.exitKey=function(e){var t=this._reporterState;t.path=t.path.slice(0,e-1)},a.prototype.leaveKey=function(e,t,r){var n=this._reporterState;this.exitKey(e),null!==n.obj&&(n.obj[t]=r)},a.prototype.path=function(){return this._reporterState.path.join("/")},a.prototype.enterObject=function(){var e=this._reporterState,t=e.obj;return e.obj={},t},a.prototype.leaveObject=function(e){var t=this._reporterState,r=t.obj;return t.obj=e,r},a.prototype.error=function(e){var t,r=this._reporterState,n=e instanceof i;if(t=n?e:new i(r.path.map((function(e){return"["+JSON.stringify(e)+"]"})).join(""),e.message||e,e.stack),!r.options.partial)throw t;return n||r.errors.push(t),t},a.prototype.wrapResult=function(e){var t=this._reporterState;return t.options.partial?{result:this.isError(e)?null:e,errors:t.errors}:e},n(i,Error),i.prototype.rethrow=function(e){if(this.message=e+" at: "+(this.path||"(shallow)"),Error.captureStackTrace&&Error.captureStackTrace(this,i),!this.stack)try{throw new Error(this.message)}catch(t){this.stack=t.stack}return this}},function(e,t,r){"use strict";function n(e){var t={};return Object.keys(e).forEach((function(r){(0|r)==r&&(r|=0);var n=e[r];t[n]=r})),t}t.tagClass={0:"universal",1:"application",2:"context",3:"private"},t.tagClassByName=n(t.tagClass),t.tag={0:"end",1:"bool",2:"int",3:"bitstr",4:"octstr",5:"null_",6:"objid",7:"objDesc",8:"external",9:"real",10:"enum",11:"embed",12:"utf8str",13:"relativeOid",16:"seq",17:"set",18:"numstr",19:"printstr",20:"t61str",21:"videostr",22:"ia5str",23:"utctime",24:"gentime",25:"graphstr",26:"iso646str",27:"genstr",28:"unistr",29:"charstr",30:"bmpstr"},t.tagByName=n(t.tag)},function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r),Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[r]}})}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),a=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&n(t,e,r);return a(t,e),t},o=this&&this.__values||function(e){var t="function"===typeof Symbol&&Symbol.iterator,r=t&&e[t],n=0;if(r)return r.call(e);if(e&&"number"===typeof e.length)return{next:function(){return e&&n>=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")},c=this&&this.__read||function(e,t){var r="function"===typeof Symbol&&e[Symbol.iterator];if(!r)return e;var n,a,i=r.call(e),o=[];try{for(;(void 0===t||t-- >0)&&!(n=i.next()).done;)o.push(n.value)}catch(c){a={error:c}}finally{try{n&&!n.done&&(r=i.return)&&r.call(i)}finally{if(a)throw a.error}}return o};Object.defineProperty(t,"__esModule",{value:!0}),t.BaseTransaction=void 0;var s=i(r(324)),f=r(107),d=r(176),u=function(){function e(e){this.cache={hash:void 0,dataFee:void 0},this.activeCapabilities=[],this.DEFAULT_CHAIN=s.Chain.Mainnet,this.DEFAULT_HARDFORK=s.Hardfork.Istanbul;var t=e.nonce,r=e.gasLimit,n=e.to,a=e.value,i=e.data,o=e.v,c=e.r,d=e.s,u=e.type;this._type=new f.BN((0,f.toBuffer)(u)).toNumber();var l=(0,f.toBuffer)(""===n?"0x":n),b=(0,f.toBuffer)(""===o?"0x":o),h=(0,f.toBuffer)(""===c?"0x":c),p=(0,f.toBuffer)(""===d?"0x":d);this.nonce=new f.BN((0,f.toBuffer)(""===t?"0x":t)),this.gasLimit=new f.BN((0,f.toBuffer)(""===r?"0x":r)),this.to=l.length>0?new f.Address(l):void 0,this.value=new f.BN((0,f.toBuffer)(""===a?"0x":a)),this.data=(0,f.toBuffer)(""===i?"0x":i),this.v=b.length>0?new f.BN(b):void 0,this.r=h.length>0?new f.BN(h):void 0,this.s=p.length>0?new f.BN(p):void 0,this._validateCannotExceedMaxInteger({nonce:this.nonce,gasLimit:this.gasLimit,value:this.value,r:this.r,s:this.s})}return Object.defineProperty(e.prototype,"transactionType",{get:function(){return this.type},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"type",{get:function(){return this._type},enumerable:!1,configurable:!0}),e.prototype.supports=function(e){return this.activeCapabilities.includes(e)},e.prototype.validate=function(e){void 0===e&&(e=!1);var t=[];return this.getBaseFee().gt(this.gasLimit)&&t.push("gasLimit is too low. given "+this.gasLimit+", need at least "+this.getBaseFee()),this.isSigned()&&!this.verifySignature()&&t.push("Invalid Signature"),e?t:0===t.length},e.prototype.getBaseFee=function(){var e=this.getDataFee().addn(this.common.param("gasPrices","tx"));return this.common.gteHardfork("homestead")&&this.toCreationAddress()&&e.iaddn(this.common.param("gasPrices","txCreation")),e},e.prototype.getDataFee=function(){for(var e=this.common.param("gasPrices","txDataZero"),t=this.common.param("gasPrices","txDataNonZero"),r=0,n=0;n-1&&this.activeCapabilities.splice(u,1)}return s},e.prototype._getCommon=function(e,t){var r;if(t){var n=new f.BN((0,f.toBuffer)(t));if(e){if(!e.chainIdBN().eq(n)){var a=this._errorMsg("The chain ID does not match the chain ID of Common");throw new Error(a)}return e.copy()}return s.default.isSupportedChainId(n)?new s.default({chain:n,hardfork:this.DEFAULT_HARDFORK}):s.default.forCustomChain(this.DEFAULT_CHAIN,{name:"custom-chain",networkId:n,chainId:n},this.DEFAULT_HARDFORK)}return null!==(r=null===e||void 0===e?void 0:e.copy())&&void 0!==r?r:new s.default({chain:this.DEFAULT_CHAIN,hardfork:this.DEFAULT_HARDFORK})},e.prototype._validateCannotExceedMaxInteger=function(e,t){var r,n;void 0===t&&(t=53);try{for(var a=o(Object.entries(e)),i=a.next();!i.done;i=a.next()){var s=c(i.value,2),d=s[0],u=s[1];if(53===t){if(null===u||void 0===u?void 0:u.gt(f.MAX_INTEGER)){var l=this._errorMsg(d+" cannot exceed MAX_INTEGER, given "+u);throw new Error(l)}}else{if(256!==t){l=this._errorMsg("unimplemented bits value");throw new Error(l)}if(null===u||void 0===u?void 0:u.gte(f.TWO_POW256)){var l=this._errorMsg(d+" must be less than 2^256, given "+u);throw new Error(l)}}}}catch(b){r={error:b}}finally{try{i&&!i.done&&(n=a.return)&&n.call(a)}finally{if(r)throw r.error}}},e.prototype._getSharedErrorPostfix=function(){var e="";try{e=this.isSigned()?(0,f.bufferToHex)(this.hash()):"not available (unsigned)"}catch(a){e="error"}var t="";try{t=this.isSigned().toString()}catch(a){e="error"}var r="";try{r=this.common.hardfork()}catch(a){r="error"}var n="tx type="+this.type+" hash="+e+" nonce="+this.nonce+" value="+this.value+" ";return n+="signed="+t+" hf="+r},e}();t.BaseTransaction=u},function(e,t,r){"use strict";(function(e){var n=this&&this.__extends||function(){var e=function(t,r){return(e=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])})(t,r)};return function(t,r){if("function"!==typeof r&&null!==r)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");function n(){this.constructor=t}e(t,r),t.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}(),a=this&&this.__assign||function(){return(a=Object.assign||function(e){for(var t,r=1,n=arguments.length;r=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};Object.defineProperty(t,"__esModule",{value:!0}),t.ConsensusAlgorithm=t.ConsensusType=t.Hardfork=t.Chain=t.CustomChain=void 0;var o,c,s=r(91),f=r(844),d=r(107),u=r(845),l=r(851),b=r(867);!function(e){e.PolygonMainnet="polygon-mainnet",e.PolygonMumbai="polygon-mumbai",e.ArbitrumRinkebyTestnet="arbitrum-rinkeby-testnet",e.xDaiChain="x-dai-chain",e.OptimisticKovan="optimistic-kovan",e.OptimisticEthereum="optimistic-ethereum"}(o=t.CustomChain||(t.CustomChain={})),function(e){e[e.Mainnet=1]="Mainnet",e[e.Ropsten=3]="Ropsten",e[e.Rinkeby=4]="Rinkeby",e[e.Kovan=42]="Kovan",e[e.Goerli=5]="Goerli"}(t.Chain||(t.Chain={})),function(e){e.Chainstart="chainstart",e.Homestead="homestead",e.Dao="dao",e.TangerineWhistle="tangerineWhistle",e.SpuriousDragon="spuriousDragon",e.Byzantium="byzantium",e.Constantinople="constantinople",e.Petersburg="petersburg",e.Istanbul="istanbul",e.MuirGlacier="muirGlacier",e.Berlin="berlin",e.London="london",e.ArrowGlacier="arrowGlacier",e.Shanghai="shanghai",e.Merge="merge"}(c=t.Hardfork||(t.Hardfork={})),function(e){e.ProofOfStake="pos",e.ProofOfWork="pow",e.ProofOfAuthority="poa"}(t.ConsensusType||(t.ConsensusType={})),function(e){e.Ethash="ethash",e.Clique="clique",e.Casper="casper"}(t.ConsensusAlgorithm||(t.ConsensusAlgorithm={}));var h=function(t){function s(e){var r,n,a,o,s=t.call(this)||this;s._supportedHardforks=[],s._eips=[],s._customChains=null!==(a=e.customChains)&&void 0!==a?a:[],s._chainParams=s.setChain(e.chain),s.DEFAULT_HARDFORK=null!==(o=s._chainParams.defaultHardfork)&&void 0!==o?o:c.Istanbul;try{for(var f=i(s._chainParams.hardforks),d=f.next();!d.done;d=f.next()){var u=d.value;u.forkHash||(u.forkHash=s._calcForkHash(u.name))}}catch(l){r={error:l}}finally{try{d&&!d.done&&(n=f.return)&&n.call(f)}finally{if(r)throw r.error}}return s._hardfork=s.DEFAULT_HARDFORK,e.supportedHardforks&&(s._supportedHardforks=e.supportedHardforks),e.hardfork&&s.setHardfork(e.hardfork),e.eips&&s.setEIPs(e.eips),s}return n(s,t),s.custom=function(e,t){var r;void 0===t&&(t={});var n=null!==(r=t.baseChain)&&void 0!==r?r:"mainnet",i=a({},s._getChainParams(n));if(i.name="custom-chain","string"!==typeof e)return new s(a({chain:a(a({},i),e)},t));if(e===o.PolygonMainnet)return s.custom({name:o.PolygonMainnet,chainId:137,networkId:137});if(e===o.PolygonMumbai)return s.custom({name:o.PolygonMumbai,chainId:80001,networkId:80001});if(e===o.ArbitrumRinkebyTestnet)return s.custom({name:o.ArbitrumRinkebyTestnet,chainId:421611,networkId:421611});if(e===o.xDaiChain)return s.custom({name:o.xDaiChain,chainId:100,networkId:100});if(e===o.OptimisticKovan)return s.custom({name:o.OptimisticKovan,chainId:69,networkId:69},{hardfork:c.Berlin});if(e===o.OptimisticEthereum)return s.custom({name:o.OptimisticEthereum,chainId:10,networkId:10},{hardfork:c.Berlin});throw new Error("Custom chain "+e+" not supported")},s.forCustomChain=function(e,t,r,n){var i=s._getChainParams(e);return new s({chain:a(a({},i),t),hardfork:r,supportedHardforks:n})},s.isSupportedChainId=function(e){var t=(0,u._getInitializedChains)();return Boolean(t.names[e.toString()])},s._getChainParams=function(e,t){var r=(0,u._getInitializedChains)(t);if("number"===typeof e||d.BN.isBN(e)){if(e=e.toString(),r.names[e])return r[r.names[e]];throw new Error("Chain with ID "+e+" not supported")}if(r[e])return r[e];throw new Error("Chain with name "+e+" not supported")},s.prototype.setChain=function(e){var t,r;if("number"===typeof e||"string"===typeof e||d.BN.isBN(e)){var n=void 0;n=this._customChains&&this._customChains.length>0&&Array.isArray(this._customChains[0])?this._customChains.map((function(e){return e[0]})):this._customChains,this._chainParams=s._getChainParams(e,n)}else{if("object"!==typeof e)throw new Error("Wrong input format");if(this._customChains.length>0)throw new Error("Chain must be a string, number, or BN when initialized with customChains passed in");try{for(var a=i(["networkId","genesis","hardforks","bootstrapNodes"]),o=a.next();!o.done;o=a.next()){var c=o.value;if(void 0===e[c])throw new Error("Missing required chain parameter: "+c)}}catch(f){t={error:f}}finally{try{o&&!o.done&&(r=a.return)&&r.call(a)}finally{if(t)throw t.error}}this._chainParams=e}return this._chainParams},s.prototype.setHardfork=function(e){var t,r;if(!this._isSupportedHardfork(e))throw new Error("Hardfork "+e+" not set as supported in supportedHardforks");var n=!1;try{for(var a=i(l.hardforks),o=a.next();!o.done;o=a.next()){o.value[0]===e&&(this._hardfork!==e&&(this._hardfork=e,this.emit("hardforkChanged",e)),n=!0)}}catch(c){t={error:c}}finally{try{o&&!o.done&&(r=a.return)&&r.call(a)}finally{if(t)throw t.error}}if(!n)throw new Error("Hardfork with name "+e+" not supported")},s.prototype.getHardforkByBlockNumber=function(e,t){var r,n;e=(0,d.toType)(e,d.TypeOutput.BN),t=(0,d.toType)(t,d.TypeOutput.BN);var a,o,s,f=c.Chainstart;try{for(var u=i(this.hardforks()),l=u.next();!l.done;l=u.next()){var b=l.value;if(null!==b.block)e.gte(new d.BN(b.block))&&(f=b.name),t&&b.td&&(t.gte(new d.BN(b.td))?a=b.name:o=s),s=b.name;else if(void 0!==t&&null!==t&&void 0!==b.td&&null!==b.td&&t.gte(new d.BN(b.td)))return b.name}}catch(m){r={error:m}}finally{try{l&&!l.done&&(n=u.return)&&n.call(u)}finally{if(r)throw r.error}}if(t){var h="block number: "+e+" (-> "+f+"), ";if(a&&!this.hardforkGteHardfork(f,a)){var p="HF determined by block number is lower than the minimum total difficulty HF";throw h+="total difficulty: "+t+" (-> "+a+")",new Error(p+": "+h)}if(o&&!this.hardforkGteHardfork(o,f)){p="Maximum HF determined by total difficulty is lower than the block number HF";throw h+="total difficulty: "+t+" (-> "+o+")",new Error(p+": "+h)}}return f},s.prototype.setHardforkByBlockNumber=function(e,t){var r=this.getHardforkByBlockNumber(e,t);return this.setHardfork(r),r},s.prototype._chooseHardfork=function(e,t){if(void 0===t&&(t=!0),e){if(t&&!this._isSupportedHardfork(e))throw new Error("Hardfork "+e+" not set as supported in supportedHardforks")}else e=this._hardfork;return e},s.prototype._getHardfork=function(e){var t,r,n=this.hardforks();try{for(var a=i(n),o=a.next();!o.done;o=a.next()){var c=o.value;if(c.name===e)return c}}catch(s){t={error:s}}finally{try{o&&!o.done&&(r=a.return)&&r.call(a)}finally{if(t)throw t.error}}throw new Error("Hardfork "+e+" not defined for chain "+this.chainName())},s.prototype._isSupportedHardfork=function(e){var t,r;if(!(this._supportedHardforks.length>0))return!0;try{for(var n=i(this._supportedHardforks),a=n.next();!a.done;a=n.next()){if(e===a.value)return!0}}catch(o){t={error:o}}finally{try{a&&!a.done&&(r=n.return)&&r.call(n)}finally{if(t)throw t.error}}return!1},s.prototype.setEIPs=function(e){var t,r,n=this;void 0===e&&(e=[]);var a=function(t){if(!(t in b.EIPs))throw new Error(t+" not supported");var r=o.gteHardfork(b.EIPs[t].minimumHardfork);if(!r)throw new Error(t+" cannot be activated on hardfork "+o.hardfork()+", minimumHardfork: "+r);b.EIPs[t].requiredEIPs&&b.EIPs[t].requiredEIPs.forEach((function(r){if(!e.includes(r)&&!n.isActivatedEIP(r))throw new Error(t+" requires EIP "+r+", but is not included in the EIP list")}))},o=this;try{for(var c=i(e),s=c.next();!s.done;s=c.next()){a(s.value)}}catch(f){t={error:f}}finally{try{s&&!s.done&&(r=c.return)&&r.call(c)}finally{if(t)throw t.error}}this._eips=e},s.prototype.param=function(e,t){var r,n,a=null;try{for(var o=i(this._eips),c=o.next();!c.done;c=o.next()){var s=c.value;if(null!==(a=this.paramByEIP(e,t,s)))return a}}catch(f){r={error:f}}finally{try{c&&!c.done&&(n=o.return)&&n.call(o)}finally{if(r)throw r.error}}return this.paramByHardfork(e,t,this._hardfork)},s.prototype.paramByHardfork=function(e,t,r){var n,a,o,c;r=this._chooseHardfork(r);var s=null;try{for(var f=i(l.hardforks),d=f.next();!d.done;d=f.next()){var u=d.value;if("eips"in u[1]){var b=u[1].eips;try{for(var h=(o=void 0,i(b)),p=h.next();!p.done;p=h.next()){var m=p.value,v=this.paramByEIP(e,t,m);s=null!==v?v:s}}catch(g){o={error:g}}finally{try{p&&!p.done&&(c=h.return)&&c.call(h)}finally{if(o)throw o.error}}}else{if(!u[1][e])throw new Error("Topic "+e+" not defined");void 0!==u[1][e][t]&&(s=u[1][e][t].v)}if(u[0]===r)break}}catch(x){n={error:x}}finally{try{d&&!d.done&&(a=f.return)&&a.call(f)}finally{if(n)throw n.error}}return s},s.prototype.paramByEIP=function(e,t,r){if(!(r in b.EIPs))throw new Error(r+" not supported");var n=b.EIPs[r];if(!(e in n))throw new Error("Topic "+e+" not defined");return void 0===n[e][t]?null:n[e][t].v},s.prototype.paramByBlock=function(e,t,r){var n=this.activeHardforks(r),a=n[n.length-1].name;return this.paramByHardfork(e,t,a)},s.prototype.isActivatedEIP=function(e){var t,r;if(this.eips().includes(e))return!0;try{for(var n=i(l.hardforks),a=n.next();!a.done;a=n.next()){var o=a.value[1];if(this.gteHardfork(o.name)&&"eips"in o&&o.eips.includes(e))return!0}}catch(c){t={error:c}}finally{try{a&&!a.done&&(r=n.return)&&r.call(n)}finally{if(t)throw t.error}}return!1},s.prototype.hardforkIsActiveOnBlock=function(e,t,r){var n;void 0===r&&(r={}),t=(0,d.toType)(t,d.TypeOutput.BN);var a=null!==(n=r.onlySupported)&&void 0!==n&&n;e=this._chooseHardfork(e,a);var i=this.hardforkBlockBN(e);return!(!i||!t.gte(i))},s.prototype.activeOnBlock=function(e,t){return this.hardforkIsActiveOnBlock(null,e,t)},s.prototype.hardforkGteHardfork=function(e,t,r){var n,a;void 0===r&&(r={});var o,c=void 0!==r.onlyActive&&r.onlyActive;e=this._chooseHardfork(e,r.onlySupported),o=c?this.activeHardforks(null,r):this.hardforks();var s=-1,f=-1,d=0;try{for(var u=i(o),l=u.next();!l.done;l=u.next()){var b=l.value;b.name===e&&(s=d),b.name===t&&(f=d),d+=1}}catch(h){n={error:h}}finally{try{l&&!l.done&&(a=u.return)&&a.call(u)}finally{if(n)throw n.error}}return s>=f&&-1!==f},s.prototype.gteHardfork=function(e,t){return this.hardforkGteHardfork(null,e,t)},s.prototype.hardforkIsActiveOnChain=function(e,t){var r,n,a;void 0===t&&(t={});var o=null!==(a=t.onlySupported)&&void 0!==a&&a;e=this._chooseHardfork(e,o);try{for(var c=i(this.hardforks()),s=c.next();!s.done;s=c.next()){var f=s.value;if(f.name===e&&null!==f.block)return!0}}catch(d){r={error:d}}finally{try{s&&!s.done&&(n=c.return)&&n.call(c)}finally{if(r)throw r.error}}return!1},s.prototype.activeHardforks=function(e,t){var r,n;void 0===t&&(t={});var a=[],o=this.hardforks();try{for(var c=i(o),s=c.next();!s.done;s=c.next()){var f=s.value;if(null!==f.block){if(void 0!==e&&null!==e&&e0)return r[r.length-1].name;throw new Error("No (supported) active hardfork found")},s.prototype.hardforkBlock=function(e){var t=this.hardforkBlockBN(e);return(0,d.toType)(t,d.TypeOutput.Number)},s.prototype.hardforkBlockBN=function(e){e=this._chooseHardfork(e,!1);var t=this._getHardfork(e).block;return void 0===t||null===t?null:new d.BN(t)},s.prototype.hardforkTD=function(e){e=this._chooseHardfork(e,!1);var t=this._getHardfork(e).td;return void 0===t||null===t?null:new d.BN(t)},s.prototype.isHardforkBlock=function(e,t){e=(0,d.toType)(e,d.TypeOutput.BN),t=this._chooseHardfork(t,!1);var r=this.hardforkBlockBN(t);return!!r&&r.eq(e)},s.prototype.nextHardforkBlock=function(e){var t=this.nextHardforkBlockBN(e);return(0,d.toType)(t,d.TypeOutput.Number)},s.prototype.nextHardforkBlockBN=function(e){e=this._chooseHardfork(e,!1);var t=this.hardforkBlockBN(e);return null===t?null:this.hardforks().reduce((function(e,r){var n=new d.BN(r.block);return n.gt(t)&&null===e?n:e}),null)},s.prototype.isNextHardforkBlock=function(e,t){e=(0,d.toType)(e,d.TypeOutput.BN),t=this._chooseHardfork(t,!1);var r=this.nextHardforkBlockBN(t);return null!==r&&r.eq(e)},s.prototype._calcForkHash=function(t){var r,n,a=e.from(this.genesis().hash.substr(2),"hex"),o=e.alloc(0),c=0;try{for(var s=i(this.hardforks()),u=s.next();!u.done;u=s.next()){var l=u.value,b=l.block;if(0!==b&&null!==b&&b!==c){var h=e.from(b.toString(16).padStart(16,"0"),"hex");o=e.concat([o,h])}if(l.name===t)break;null!==b&&(c=b)}}catch(m){r={error:m}}finally{try{u&&!u.done&&(n=s.return)&&n.call(s)}finally{if(r)throw r.error}}var p=e.concat([a,o]);return"0x"+(0,d.intToBuffer)((0,f.buf)(p)>>>0).toString("hex")},s.prototype.forkHash=function(e){e=this._chooseHardfork(e,!1);var t=this._getHardfork(e);if(null===t.block&&void 0===t.td){throw new Error("No fork hash calculation possible for future hardfork")}return void 0!==t.forkHash?t.forkHash:this._calcForkHash(e)},s.prototype.hardforkForForkHash=function(e){var t=this.hardforks().filter((function(t){return t.forkHash===e}));return t.length>=1?t[t.length-1]:null},s.prototype.genesis=function(){return this._chainParams.genesis},s.prototype.genesisState=function(){var e,t;switch(this.chainName()){case"mainnet":return r(881);case"ropsten":return r(882);case"rinkeby":return r(883);case"kovan":return r(884);case"goerli":return r(885)}if(this._customChains&&this._customChains.length>0&&Array.isArray(this._customChains[0]))try{for(var n=i(this._customChains),a=n.next();!a.done;a=n.next()){var o=a.value;if(o[0].name===this.chainName())return o[1]}}catch(c){e={error:c}}finally{try{a&&!a.done&&(t=n.return)&&t.call(n)}finally{if(e)throw e.error}}return{}},s.prototype.hardforks=function(){return this._chainParams.hardforks},s.prototype.bootstrapNodes=function(){return this._chainParams.bootstrapNodes},s.prototype.dnsNetworks=function(){return this._chainParams.dnsNetworks},s.prototype.hardfork=function(){return this._hardfork},s.prototype.chainId=function(){return(0,d.toType)(this.chainIdBN(),d.TypeOutput.Number)},s.prototype.chainIdBN=function(){return new d.BN(this._chainParams.chainId)},s.prototype.chainName=function(){return this._chainParams.name},s.prototype.networkId=function(){return(0,d.toType)(this.networkIdBN(),d.TypeOutput.Number)},s.prototype.networkIdBN=function(){return new d.BN(this._chainParams.networkId)},s.prototype.eips=function(){return this._eips},s.prototype.consensusType=function(){var e,t,r,n=this.hardfork();try{for(var a=i(l.hardforks),o=a.next();!o.done;o=a.next()){var c=o.value;if("consensus"in c[1]&&(r=c[1].consensus.type),c[0]===n)break}}catch(s){e={error:s}}finally{try{o&&!o.done&&(t=a.return)&&t.call(a)}finally{if(e)throw e.error}}return r||this._chainParams.consensus.type},s.prototype.consensusAlgorithm=function(){var e,t,r,n=this.hardfork();try{for(var a=i(l.hardforks),o=a.next();!o.done;o=a.next()){var c=o.value;if("consensus"in c[1]&&(r=c[1].consensus.algorithm),c[0]===n)break}}catch(s){e={error:s}}finally{try{o&&!o.done&&(t=a.return)&&t.call(a)}finally{if(e)throw e.error}}return r||this._chainParams.consensus.algorithm},s.prototype.consensusConfig=function(){var e,t,r,n=this.hardfork();try{for(var a=i(l.hardforks),o=a.next();!o.done;o=a.next()){var c=o.value;if("consensus"in c[1]&&(r=c[1].consensus[c[1].consensus.algorithm]),c[0]===n)break}}catch(f){e={error:f}}finally{try{o&&!o.done&&(t=a.return)&&t.call(a)}finally{if(e)throw e.error}}if(r)return r;var s=this.consensusAlgorithm();return this._chainParams.consensus[s]},s.prototype.copy=function(){return Object.assign(Object.create(Object.getPrototypeOf(this)),this)},s}(s.EventEmitter);t.default=h}).call(this,r(30).Buffer)},function(e,t,r){"use strict";r.d(t,"a",(function(){return a})),r.d(t,"b",(function(){return i}));var n=r(10);function a(e){e=atob(e);for(var t=[],r=0;r31)throw new Error("bytes32 string must be less than 32 bytes");return Object(a.hexlify)(Object(a.concat)([t,n.a]).slice(0,32))}function c(e){var t=Object(a.arrayify)(e);if(32!==t.length)throw new Error("invalid bytes32 - not 32 bytes long");if(0!==t[31])throw new Error("invalid bytes32 string - no null terminator");for(var r=31;0===t[r-1];)r--;return Object(i.h)(t.slice(0,r))}},function(e,t,r){"use strict";r.d(t,"b",(function(){return o})),r.d(t,"a",(function(){return c}));var n=r(10),a=r(49),i=r(64),o="\x19Ethereum Signed Message:\n";function c(e){return"string"===typeof e&&(e=Object(i.f)(e)),Object(a.keccak256)(Object(n.concat)([Object(i.f)(o),Object(i.f)(String(e.length)),e]))}},function(e,t,r){"use strict";var n=r(911),a=r(330),i=r(177),o=r(484),c=r(913);function s(e,t,r){var n=this._refs[r];if("string"==typeof n){if(!this._refs[n])return s.call(this,e,t,n);n=this._refs[n]}if((n=n||this._schemas[r])instanceof o)return h(n.schema,this._opts.inlineRefs)?n.schema:n.validate||this._compile(n);var a,i,c,d=f.call(this,t,r);return d&&(a=d.schema,t=d.root,c=d.baseId),a instanceof o?i=a.validate||e.call(this,a.schema,t,void 0,c):void 0!==a&&(i=h(a,this._opts.inlineRefs)?a:e.call(this,a,t,void 0,c)),i}function f(e,t){var r=n.parse(t),a=m(r),i=p(this._getId(e.schema));if(0===Object.keys(e.schema).length||a!==i){var c=g(a),s=this._refs[c];if("string"==typeof s)return d.call(this,e,s,r);if(s instanceof o)s.validate||this._compile(s),e=s;else{if(!((s=this._schemas[c])instanceof o))return;if(s.validate||this._compile(s),c==g(t))return{schema:s,root:e,baseId:i};e=s}if(!e.schema)return;i=p(this._getId(e.schema))}return l.call(this,r,i,e.schema,e)}function d(e,t,r){var n=f.call(this,e,t);if(n){var a=n.schema,i=n.baseId;e=n.root;var o=this._getId(a);return o&&(i=x(i,o)),l.call(this,r,i,a,e)}}e.exports=s,s.normalizeId=g,s.fullPath=p,s.url=x,s.ids=function(e){var t=g(this._getId(e)),r={"":t},o={"":p(t,!1)},s={},f=this;return c(e,{allKeys:!0},(function(e,t,c,d,u,l,b){if(""!==t){var h=f._getId(e),p=r[d],m=o[d]+"/"+u;if(void 0!==b&&(m+="/"+("number"==typeof b?b:i.escapeFragment(b))),"string"==typeof h){h=p=g(p?n.resolve(p,h):h);var v=f._refs[h];if("string"==typeof v&&(v=f._refs[v]),v&&v.schema){if(!a(e,v.schema))throw new Error('id "'+h+'" resolves to more than one schema')}else if(h!=g(m))if("#"==h[0]){if(s[h]&&!a(e,s[h]))throw new Error('id "'+h+'" resolves to more than one schema');s[h]=e}else f._refs[h]=m}r[t]=p,o[t]=m}})),s},s.inlineRef=h,s.schema=f;var u=i.toHash(["properties","patternProperties","enum","dependencies","definitions"]);function l(e,t,r,n){if(e.fragment=e.fragment||"","/"==e.fragment.slice(0,1)){for(var a=e.fragment.split("/"),o=1;o1&&void 0!==arguments[1]?arguments[1]:"utf8",r=n[t];if(!r)throw new Error('Unsupported encoding "'.concat(t,'"'));return r.encoder.encode(e).substring(1)}},function(e,t,r){"use strict";var n=r(87),a=r(88);Object.defineProperty(t,"__esModule",{value:!0});var i=r(206),o=function(){function e(t,r,a){n(this,e),this.name=t,this.code=r,this.encode=a}return a(e,[{key:"digest",value:function(e){var t=this;if(e instanceof Uint8Array){var r=this.encode(e);return r instanceof Uint8Array?i.create(this.code,r):r.then((function(e){return i.create(t.code,e)}))}throw Error("Unknown type, must be binary type")}}]),e}();t.Hasher=o,t.from=function(e){var t=e.name,r=e.code,n=e.encode;return new o(t,r,n)}},function(e,t,r){"use strict";var n=r(101);e.exports=function(e,t){t||(t=e.reduce((function(e,t){return e+t.length}),0));var r,a=new Uint8Array(t),i=0,o=n(e);try{for(o.s();!(r=o.n()).done;){var c=r.value;a.set(c,i),i+=c.length}}catch(s){o.e(s)}finally{o.f()}return a}},function(e,t,r){var n=r(973),a=r(122);e.exports=function e(t,r,i,o,c){return t===r||(null==t||null==r||!a(t)&&!a(r)?t!==t&&r!==r:n(t,r,i,o,e,c))}},function(e,t,r){var n=r(251),a=r(979),i=r(980),o=r(981),c=r(982),s=r(983);function f(e){var t=this.__data__=new n(e);this.size=t.size}f.prototype.clear=a,f.prototype.delete=i,f.prototype.get=o,f.prototype.has=c,f.prototype.set=s,e.exports=f},function(e,t,r){var n=r(155)(r(108),"Map");e.exports=n},function(e,t,r){var n=r(990),a=r(997),i=r(999),o=r(1e3),c=r(1001);function s(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t-1&&e%1==0&&e-1&&e%1==0&&e<=9007199254740991}},function(e,t){e.exports=function(e){return function(t){return e(t)}}},function(e,t,r){(function(e){var n=r(500),a=t&&!t.nodeType&&t,i=a&&"object"==typeof e&&e&&!e.nodeType&&e,o=i&&i.exports===a&&n.process,c=function(){try{var e=i&&i.require&&i.require("util").types;return e||o&&o.binding&&o.binding("util")}catch(t){}}();e.exports=c}).call(this,r(74)(e))},function(e,t){var r=Object.prototype;e.exports=function(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||r)}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Swatch=void 0;var n=r(256),a=r(1029),i=function(){function e(e,t){this._rgb=e,this._population=t}return e.applyFilter=function(e,t){return"function"===typeof t?a(e,(function(e){var r=e.r,n=e.g,a=e.b;return t(r,n,a,255)})):e},Object.defineProperty(e.prototype,"r",{get:function(){return this._rgb[0]},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"g",{get:function(){return this._rgb[1]},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"b",{get:function(){return this._rgb[2]},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"rgb",{get:function(){return this._rgb},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"hsl",{get:function(){if(!this._hsl){var e=this._rgb,t=e[0],r=e[1],a=e[2];this._hsl=n.rgbToHsl(t,r,a)}return this._hsl},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"hex",{get:function(){if(!this._hex){var e=this._rgb,t=e[0],r=e[1],a=e[2];this._hex=n.rgbToHex(t,r,a)}return this._hex},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"population",{get:function(){return this._population},enumerable:!1,configurable:!0}),e.prototype.toJSON=function(){return{rgb:this.rgb,population:this.population}},e.prototype.getRgb=function(){return this._rgb},e.prototype.getHsl=function(){return this.hsl},e.prototype.getPopulation=function(){return this._population},e.prototype.getHex=function(){return this.hex},e.prototype.getYiq=function(){if(!this._yiq){var e=this._rgb;this._yiq=(299*e[0]+587*e[1]+114*e[2])/1e3}return this._yiq},Object.defineProperty(e.prototype,"titleTextColor",{get:function(){return this._titleTextColor||(this._titleTextColor=this.getYiq()<200?"#fff":"#000"),this._titleTextColor},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"bodyTextColor",{get:function(){return this._bodyTextColor||(this._bodyTextColor=this.getYiq()<150?"#fff":"#000"),this._bodyTextColor},enumerable:!1,configurable:!0}),e.prototype.getTitleTextColor=function(){return this.titleTextColor},e.prototype.getBodyTextColor=function(){return this.bodyTextColor},e}();t.Swatch=i},function(e,t,r){var n=r(92),a=r(349),i=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,o=/^\w*$/;e.exports=function(e,t){if(n(e))return!1;var r=typeof e;return!("number"!=r&&"symbol"!=r&&"boolean"!=r&&null!=e&&!a(e))||(o.test(e)||!i.test(e)||null!=t&&e in Object(t))}},function(e,t,r){var n=r(156),a=r(122);e.exports=function(e){return"symbol"==typeof e||a(e)&&"[object Symbol]"==n(e)}},function(e,t,r){var n=r(512)(Object.getPrototypeOf,Object);e.exports=n},function(e,t,r){var n=r(503);e.exports=function(e){var t=new e.constructor(e.byteLength);return new n(t).set(new n(e)),t}},function(e,t,r){"use strict";r.r(t);var n=r(68);r.d(t,"ConstructorFragment",(function(){return n.a})),r.d(t,"ErrorFragment",(function(){return n.b})),r.d(t,"EventFragment",(function(){return n.c})),r.d(t,"Fragment",(function(){return n.e})),r.d(t,"FunctionFragment",(function(){return n.f})),r.d(t,"ParamType",(function(){return n.g})),r.d(t,"FormatTypes",(function(){return n.d}));var a=r(210);r.d(t,"AbiCoder",(function(){return a.a})),r.d(t,"defaultAbiCoder",(function(){return a.b}));var i=r(204);r.d(t,"Interface",(function(){return i.b})),r.d(t,"Indexed",(function(){return i.a}));var o=r(58);r.d(t,"checkResultErrors",(function(){return o.d})),r.d(t,"LogDescription",(function(){return i.c})),r.d(t,"TransactionDescription",(function(){return i.d}))},function(e,t,r){"use strict";r.r(t);var n=r(483);r.d(t,"randomBytes",(function(){return n.a}));var a=r(482);r.d(t,"shuffled",(function(){return a.a}))},function(e,t,r){var n=r(516),a=r(1097);e.exports=function(e,t){return e&&n(e,a(t))}},function(e,t){e.exports=function(e){if(!e.webpackPolyfill){var t=Object.create(e);t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),Object.defineProperty(t,"exports",{enumerable:!0}),t.webpackPolyfill=1}return t}},,function(e,t,r){"use strict";var n=SyntaxError,a=Function,i=TypeError,o=function(e){try{return a('"use strict"; return ('+e+").constructor;")()}catch(t){}},c=Object.getOwnPropertyDescriptor;if(c)try{c({},"")}catch(E){c=null}var s=function(){throw new i},f=c?function(){try{return s}catch(e){try{return c(arguments,"callee").get}catch(t){return s}}}():s,d=r(1150)(),u=Object.getPrototypeOf||function(e){return e.__proto__},l={},b="undefined"===typeof Uint8Array?void 0:u(Uint8Array),h={"%AggregateError%":"undefined"===typeof AggregateError?void 0:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"===typeof ArrayBuffer?void 0:ArrayBuffer,"%ArrayIteratorPrototype%":d?u([][Symbol.iterator]()):void 0,"%AsyncFromSyncIteratorPrototype%":void 0,"%AsyncFunction%":l,"%AsyncGenerator%":l,"%AsyncGeneratorFunction%":l,"%AsyncIteratorPrototype%":l,"%Atomics%":"undefined"===typeof Atomics?void 0:Atomics,"%BigInt%":"undefined"===typeof BigInt?void 0:BigInt,"%Boolean%":Boolean,"%DataView%":"undefined"===typeof DataView?void 0:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":"undefined"===typeof Float32Array?void 0:Float32Array,"%Float64Array%":"undefined"===typeof Float64Array?void 0:Float64Array,"%FinalizationRegistry%":"undefined"===typeof FinalizationRegistry?void 0:FinalizationRegistry,"%Function%":a,"%GeneratorFunction%":l,"%Int8Array%":"undefined"===typeof Int8Array?void 0:Int8Array,"%Int16Array%":"undefined"===typeof Int16Array?void 0:Int16Array,"%Int32Array%":"undefined"===typeof Int32Array?void 0:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":d?u(u([][Symbol.iterator]())):void 0,"%JSON%":"object"===typeof JSON?JSON:void 0,"%Map%":"undefined"===typeof Map?void 0:Map,"%MapIteratorPrototype%":"undefined"!==typeof Map&&d?u((new Map)[Symbol.iterator]()):void 0,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"===typeof Promise?void 0:Promise,"%Proxy%":"undefined"===typeof Proxy?void 0:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":"undefined"===typeof Reflect?void 0:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"===typeof Set?void 0:Set,"%SetIteratorPrototype%":"undefined"!==typeof Set&&d?u((new Set)[Symbol.iterator]()):void 0,"%SharedArrayBuffer%":"undefined"===typeof SharedArrayBuffer?void 0:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":d?u(""[Symbol.iterator]()):void 0,"%Symbol%":d?Symbol:void 0,"%SyntaxError%":n,"%ThrowTypeError%":f,"%TypedArray%":b,"%TypeError%":i,"%Uint8Array%":"undefined"===typeof Uint8Array?void 0:Uint8Array,"%Uint8ClampedArray%":"undefined"===typeof Uint8ClampedArray?void 0:Uint8ClampedArray,"%Uint16Array%":"undefined"===typeof Uint16Array?void 0:Uint16Array,"%Uint32Array%":"undefined"===typeof Uint32Array?void 0:Uint32Array,"%URIError%":URIError,"%WeakMap%":"undefined"===typeof WeakMap?void 0:WeakMap,"%WeakRef%":"undefined"===typeof WeakRef?void 0:WeakRef,"%WeakSet%":"undefined"===typeof WeakSet?void 0:WeakSet},p={"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},m=r(358),v=r(1153),g=m.call(Function.call,Array.prototype.concat),x=m.call(Function.apply,Array.prototype.splice),y=m.call(Function.call,String.prototype.replace),w=m.call(Function.call,String.prototype.slice),k=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,_=/\\(\\)?/g,M=function(e){var t=w(e,0,1),r=w(e,-1);if("%"===t&&"%"!==r)throw new n("invalid intrinsic syntax, expected closing `%`");if("%"===r&&"%"!==t)throw new n("invalid intrinsic syntax, expected opening `%`");var a=[];return y(e,k,(function(e,t,r,n){a[a.length]=r?y(n,_,"$1"):t||e})),a},S=function(e,t){var r,a=e;if(v(p,a)&&(a="%"+(r=p[a])[0]+"%"),v(h,a)){var c=h[a];if(c===l&&(c=function e(t){var r;if("%AsyncFunction%"===t)r=o("async function () {}");else if("%GeneratorFunction%"===t)r=o("function* () {}");else if("%AsyncGeneratorFunction%"===t)r=o("async function* () {}");else if("%AsyncGenerator%"===t){var n=e("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if("%AsyncIteratorPrototype%"===t){var a=e("%AsyncGenerator%");a&&(r=u(a.prototype))}return h[t]=r,r}(a)),"undefined"===typeof c&&!t)throw new i("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:r,name:a,value:c}}throw new n("intrinsic "+e+" does not exist!")};e.exports=function(e,t){if("string"!==typeof e||0===e.length)throw new i("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!==typeof t)throw new i('"allowMissing" argument must be a boolean');var r=M(e),a=r.length>0?r[0]:"",o=S("%"+a+"%",t),s=o.name,f=o.value,d=!1,u=o.alias;u&&(a=u[0],x(r,g([0,1],u)));for(var l=1,b=!0;l=r.length){var k=c(f,p);f=(b=!!k)&&"get"in k&&!("originalValue"in k.get)?k.get:f[p]}else b=v(f,p),f=f[p];b&&!d&&(h[s]=f)}}return f}},function(e,t,r){"use strict";var n=r(1152);e.exports=Function.prototype.bind||n},function(e,t,r){"use strict";var n=String.prototype.replace,a=/%20/g,i="RFC1738",o="RFC3986";e.exports={default:o,formatters:{RFC1738:function(e){return n.call(e,a,"+")},RFC3986:function(e){return String(e)}},RFC1738:i,RFC3986:o}},function(e,t,r){"use strict";r.d(t,"a",(function(){return p}));var n=r(6),a=r(7),i=r(20),o=r(13),c=r(14),s=r(9),f=r(11),d=r(52),u=r(102),l=new f.a(d.a),b=1;function h(e,t){var r="Web3LegacyFetcher";return function(e,n){var a=this,i={method:e,params:n,id:b++,jsonrpc:"2.0"};return new Promise((function(e,n){a.emit("debug",{action:"request",fetcher:r,request:Object(s.c)(i),provider:a}),t(i,(function(t,o){if(t)return a.emit("debug",{action:"response",fetcher:r,error:t,request:i,provider:a}),n(t);if(a.emit("debug",{action:"response",fetcher:r,request:i,response:o,provider:a}),o.error){var c=new Error(o.error.message);return c.code=o.error.code,c.data=o.error.data,n(c)}e(o.result)}))}))}}var p=function(e){Object(o.a)(r,e);var t=Object(c.a)(r);function r(e,a){var o;Object(n.a)(this,r),l.checkNew(this instanceof r?this.constructor:void 0,r),null==e&&l.throwArgumentError("missing provider","provider",e);var c=null,f=null,d=null;return"function"===typeof e?(c="unknown:",f=e):(!(c=e.host||e.path||"")&&e.isMetaMask&&(c="metamask"),d=e,e.request?(""===c&&(c="eip-1193:"),f=function(e){return function(t,r){var n=this;null==r&&(r=[]);var a={method:t,params:r};return this.emit("debug",{action:"request",fetcher:"Eip1193Fetcher",request:Object(s.c)(a),provider:this}),e.request(a).then((function(e){return n.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:a,response:e,provider:n}),e}),(function(e){throw n.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:a,error:e,provider:n}),e}))}}(e)):e.sendAsync?f=h(0,e.sendAsync.bind(e)):e.send?f=h(0,e.send.bind(e)):l.throwArgumentError("unsupported provider","provider",e),c||(c="unknown:")),o=t.call(this,c,a),Object(s.d)(Object(i.a)(o),"jsonRpcFetchFunc",f),Object(s.d)(Object(i.a)(o),"provider",d),o}return Object(a.a)(r,[{key:"send",value:function(e,t){return this.jsonRpcFetchFunc(e,t)}}]),r}(u.a)},function(e,t,r){"use strict";r.d(t,"a",(function(){return n}));var n="0x0000000000000000000000000000000000000000000000000000000000000000"},,,,,function(e,t,r){"use strict";r.d(t,"a",(function(){return i}));var n=r(40),a=r(86);function i(e){return Object(n.a)(Object(a.c)(e))}},function(e,t,r){"use strict";r.d(t,"a",(function(){return Y})),r.d(t,"b",(function(){return V}));var n=r(1),a=r.n(n),i=r(12),o=r.n(i),c=r(270),s=r.n(c),f=r(368),d=r.n(f),u=r(271),l=r.n(u);function b(){return(b=Object.assign||function(e){for(var t=1;t=0||(a[r]=e[r]);return a}var m={BASE:"base",BODY:"body",HEAD:"head",HTML:"html",LINK:"link",META:"meta",NOSCRIPT:"noscript",SCRIPT:"script",STYLE:"style",TITLE:"title",FRAGMENT:"Symbol(react.fragment)"},v={rel:["amphtml","canonical","alternate"]},g={type:["application/ld+json"]},x={charset:"",name:["robots","description"],property:["og:type","og:title","og:url","og:image","og:image:alt","og:description","twitter:url","twitter:title","twitter:description","twitter:image","twitter:image:alt","twitter:card","twitter:site"]},y=Object.keys(m).map((function(e){return m[e]})),w={accesskey:"accessKey",charset:"charSet",class:"className",contenteditable:"contentEditable",contextmenu:"contextMenu","http-equiv":"httpEquiv",itemprop:"itemProp",tabindex:"tabIndex"},k=Object.keys(w).reduce((function(e,t){return e[w[t]]=t,e}),{}),_=function(e,t){for(var r=e.length-1;r>=0;r-=1){var n=e[r];if(Object.prototype.hasOwnProperty.call(n,t))return n[t]}return null},M=function(e){var t=_(e,m.TITLE),r=_(e,"titleTemplate");if(Array.isArray(t)&&(t=t.join("")),r&&t)return r.replace(/%s/g,(function(){return t}));var n=_(e,"defaultTitle");return t||n||void 0},S=function(e){return _(e,"onChangeClientState")||function(){}},E=function(e,t){return t.filter((function(t){return void 0!==t[e]})).map((function(t){return t[e]})).reduce((function(e,t){return b({},e,t)}),{})},O=function(e,t){return t.filter((function(e){return void 0!==e[m.BASE]})).map((function(e){return e[m.BASE]})).reverse().reduce((function(t,r){if(!t.length)for(var n=Object.keys(r),a=0;a/g,">").replace(/"/g,""").replace(/'/g,"'")},B=function(e){return Object.keys(e).reduce((function(t,r){var n=void 0!==e[r]?r+'="'+e[r]+'"':""+r;return t?t+" "+n:n}),"")},L=function(e,t){return void 0===t&&(t={}),Object.keys(e).reduce((function(t,r){return t[w[r]||r]=e[r],t}),t)},I=function(e,t){return t.map((function(t,r){var n,i=((n={key:r})["data-rh"]=!0,n);return Object.keys(t).forEach((function(e){var r=w[e]||e;"innerHTML"===r||"cssText"===r?i.dangerouslySetInnerHTML={__html:t.innerHTML||t.cssText}:i[r]=t[e]})),a.a.createElement(e,i)}))},F=function(e,t,r){switch(e){case m.TITLE:return{toComponent:function(){return r=t.titleAttributes,(n={key:e=t.title})["data-rh"]=!0,i=L(r,n),[a.a.createElement(m.TITLE,i,e)];var e,r,n,i},toString:function(){return function(e,t,r,n){var a=B(r),i=j(t);return a?"<"+e+' data-rh="true" '+a+">"+N(i,n)+"":"<"+e+' data-rh="true">'+N(i,n)+""}(e,t.title,t.titleAttributes,r)}};case"bodyAttributes":case"htmlAttributes":return{toComponent:function(){return L(t)},toString:function(){return B(t)}};default:return{toComponent:function(){return I(e,t)},toString:function(){return function(e,t,r){return t.reduce((function(t,n){var a=Object.keys(n).filter((function(e){return!("innerHTML"===e||"cssText"===e)})).reduce((function(e,t){var a=void 0===n[t]?t:t+'="'+N(n[t],r)+'"';return e?e+" "+a:a}),""),i=n.innerHTML||n.cssText||"",o=-1===R.indexOf(e);return t+"<"+e+' data-rh="true" '+a+(o?"/>":">"+i+"")}),"")}(e,t,r)}}}},D=function(e){var t=e.baseTag,r=e.bodyAttributes,n=e.encode,a=e.htmlAttributes,i=e.noscriptTags,o=e.styleTags,c=e.title,s=void 0===c?"":c,f=e.titleAttributes,d=e.linkTags,u=e.metaTags,l=e.scriptTags,b={toComponent:function(){},toString:function(){return""}};if(e.prioritizeSeoTags){var h=function(e){var t=e.linkTags,r=e.scriptTags,n=e.encode,a=P(e.metaTags,x),i=P(t,v),o=P(r,g);return{priorityMethods:{toComponent:function(){return[].concat(I(m.META,a.priority),I(m.LINK,i.priority),I(m.SCRIPT,o.priority))},toString:function(){return F(m.META,a.priority,n)+" "+F(m.LINK,i.priority,n)+" "+F(m.SCRIPT,o.priority,n)}},metaTags:a.default,linkTags:i.default,scriptTags:o.default}}(e);b=h.priorityMethods,d=h.linkTags,u=h.metaTags,l=h.scriptTags}return{priority:b,base:F(m.BASE,t,n),bodyAttributes:F("bodyAttributes",r,n),htmlAttributes:F("htmlAttributes",a,n),link:F(m.LINK,d,n),meta:F(m.META,u,n),noscript:F(m.NOSCRIPT,i,n),script:F(m.SCRIPT,l,n),style:F(m.STYLE,o,n),title:F(m.TITLE,{title:s,titleAttributes:f},n)}},U=[],z=function(e,t){var r=this;void 0===t&&(t="undefined"!=typeof document),this.instances=[],this.value={setHelmet:function(e){r.context.helmet=e},helmetInstances:{get:function(){return r.canUseDOM?U:r.instances},add:function(e){(r.canUseDOM?U:r.instances).push(e)},remove:function(e){var t=(r.canUseDOM?U:r.instances).indexOf(e);(r.canUseDOM?U:r.instances).splice(t,1)}}},this.context=e,this.canUseDOM=t,t||(e.helmet=D({baseTag:[],bodyAttributes:{},encodeSpecialCharacters:!0,htmlAttributes:{},linkTags:[],metaTags:[],noscriptTags:[],scriptTags:[],styleTags:[],title:"",titleAttributes:{}}))},H=a.a.createContext({}),q=o.a.shape({setHelmet:o.a.func,helmetInstances:o.a.shape({get:o.a.func,add:o.a.func,remove:o.a.func})}),J="undefined"!=typeof document,V=function(e){function t(r){var n;return(n=e.call(this,r)||this).helmetData=new z(n.props.context,t.canUseDOM),n}return h(t,e),t.prototype.render=function(){return a.a.createElement(H.Provider,{value:this.helmetData.value},this.props.children)},t}(n.Component);V.canUseDOM=J,V.propTypes={context:o.a.shape({helmet:o.a.shape()}),children:o.a.node.isRequired},V.defaultProps={context:{}},V.displayName="HelmetProvider";var G=function(e,t){var r,n=document.head||document.querySelector(m.HEAD),a=n.querySelectorAll(e+"[data-rh]"),i=[].slice.call(a),o=[];return t&&t.length&&t.forEach((function(t){var n=document.createElement(e);for(var a in t)Object.prototype.hasOwnProperty.call(t,a)&&("innerHTML"===a?n.innerHTML=t.innerHTML:"cssText"===a?n.styleSheet?n.styleSheet.cssText=t.cssText:n.appendChild(document.createTextNode(t.cssText)):n.setAttribute(a,void 0===t[a]?"":t[a]));n.setAttribute("data-rh","true"),i.some((function(e,t){return r=t,n.isEqualNode(e)}))?i.splice(r,1):o.push(n)})),i.forEach((function(e){return e.parentNode.removeChild(e)})),o.forEach((function(e){return n.appendChild(e)})),{oldTags:i,newTags:o}},X=function(e,t){var r=document.getElementsByTagName(e)[0];if(r){for(var n=r.getAttribute("data-rh"),a=n?n.split(","):[],i=[].concat(a),o=Object.keys(t),c=0;c=0;u-=1)r.removeAttribute(i[u]);a.length===i.length?r.removeAttribute("data-rh"):r.getAttribute("data-rh")!==o.join(",")&&r.setAttribute("data-rh",o.join(","))}},K=function(e,t){var r=e.baseTag,n=e.htmlAttributes,a=e.linkTags,i=e.metaTags,o=e.noscriptTags,c=e.onChangeClientState,s=e.scriptTags,f=e.styleTags,d=e.title,u=e.titleAttributes;X(m.BODY,e.bodyAttributes),X(m.HTML,n),function(e,t){void 0!==e&&document.title!==e&&(document.title=j(e)),X(m.TITLE,t)}(d,u);var l={baseTag:G(m.BASE,r),linkTags:G(m.LINK,a),metaTags:G(m.META,i),noscriptTags:G(m.NOSCRIPT,o),scriptTags:G(m.SCRIPT,s),styleTags:G(m.STYLE,f)},b={},h={};Object.keys(l).forEach((function(e){var t=l[e],r=t.newTags,n=t.oldTags;r.length&&(b[e]=r),n.length&&(h[e]=l[e].oldTags)})),t&&t(),c(e,b,h)},W=null,Z=function(e){function t(){for(var t,r=arguments.length,n=new Array(r),a=0;a elements are self-closing and can not contain children. Refer to our API for more information.")}},r.flattenArrayTypeChildren=function(e){var t,r=e.child,n=e.arrayTypeChildren;return b({},n,((t={})[r.type]=[].concat(n[r.type]||[],[b({},e.newChildProps,this.mapNestedChildrenToProps(r,e.nestedChildren))]),t))},r.mapObjectTypeChildren=function(e){var t,r,n=e.child,a=e.newProps,i=e.newChildProps,o=e.nestedChildren;switch(n.type){case m.TITLE:return b({},a,((t={})[n.type]=o,t.titleAttributes=b({},i),t));case m.BODY:return b({},a,{bodyAttributes:b({},i)});case m.HTML:return b({},a,{htmlAttributes:b({},i)});default:return b({},a,((r={})[n.type]=b({},i),r))}},r.mapArrayTypeChildrenToProps=function(e,t){var r=b({},t);return Object.keys(e).forEach((function(t){var n;r=b({},r,((n={})[t]=e[t],n))})),r},r.warnOnInvalidChildren=function(e,t){return d()(y.some((function(t){return e.type===t})),"function"==typeof e.type?"You may be attempting to nest components within each other, which is not allowed. Refer to our API for more information.":"Only elements types "+y.join(", ")+" are allowed. Helmet does not support rendering <"+e.type+"> elements. Refer to our API for more information."),d()(!t||"string"==typeof t||Array.isArray(t)&&!t.some((function(e){return"string"!=typeof e})),"Helmet expects a string as a child of <"+e.type+">. Did you forget to wrap your children in braces? ( <"+e.type+">{``} ) Refer to our API for more information."),!0},r.mapChildrenToProps=function(e,t){var r=this,n={};return a.a.Children.forEach(e,(function(e){if(e&&e.props){var a=e.props,i=a.children,o=p(a,$),c=Object.keys(o).reduce((function(e,t){return e[k[t]||t]=o[t],e}),{}),s=e.type;switch("symbol"==typeof s?s=s.toString():r.warnOnInvalidChildren(e,i),s){case m.FRAGMENT:t=r.mapChildrenToProps(i,t);break;case m.LINK:case m.META:case m.NOSCRIPT:case m.SCRIPT:case m.STYLE:n=r.flattenArrayTypeChildren({child:e,arrayTypeChildren:n,newChildProps:c,nestedChildren:i});break;default:t=r.mapObjectTypeChildren({child:e,newProps:t,newChildProps:c,nestedChildren:i})}}})),this.mapArrayTypeChildrenToProps(n,t)},r.render=function(){var e=this.props,t=e.children,r=p(e,Q),n=b({},r),i=r.helmetData;return t&&(n=this.mapChildrenToProps(t,n)),!i||i instanceof z||(i=new z(i.context,i.instances)),i?a.a.createElement(Z,b({},n,{context:i.value,helmetData:void 0})):a.a.createElement(H.Consumer,null,(function(e){return a.a.createElement(Z,b({},n,{context:e}))}))},t}(n.Component);Y.propTypes={base:o.a.object,bodyAttributes:o.a.object,children:o.a.oneOfType([o.a.arrayOf(o.a.node),o.a.node]),defaultTitle:o.a.string,defer:o.a.bool,encodeSpecialCharacters:o.a.bool,htmlAttributes:o.a.object,link:o.a.arrayOf(o.a.object),meta:o.a.arrayOf(o.a.object),noscript:o.a.arrayOf(o.a.object),onChangeClientState:o.a.func,script:o.a.arrayOf(o.a.object),style:o.a.arrayOf(o.a.object),title:o.a.string,titleAttributes:o.a.object,titleTemplate:o.a.string,prioritizeSeoTags:o.a.bool,helmetData:o.a.object},Y.defaultProps={defer:!0,encodeSpecialCharacters:!0,prioritizeSeoTags:!1},Y.displayName="Helmet"},function(e,t,r){"use strict";e.exports=function(e,t,r,n,a,i,o,c){if(!e){var s;if(void 0===t)s=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var f=[r,n,a,i,o,c],d=0;(s=new Error(t.replace(/%s/g,(function(){return f[d++]})))).name="Invariant Violation"}throw s.framesToPop=1,s}}},,function(e,t,r){"use strict";var n=r(87),a=r(88),i=r(189),o=r(492),c=r(219),s=r(965),f=r(335),d=r(333),u=r(966),l=c.nameToCode,b=Object.keys(l).reduce((function(e,t){return e[l[t]]=t,e}),{}),h=Symbol.for("@ipld/js-cid/CID"),p=function(e){function t(e,r,a,s){if(n(this,t),this.version,this.codec,this.multihash,Object.defineProperty(this,h,{value:!0}),t.isCID(e)){var f=e;return this.version=f.version,this.codec=f.codec,this.multihash=f.multihash,void(this.multibaseName=f.multibaseName||(0===f.version?"base58btc":"base32"))}if("string"===typeof e){var d=o.isEncoded(e);if(d){var u=o.decode(e);this.version=parseInt(u[0].toString(),16),this.codec=c.getCodec(u.slice(1)),this.multihash=c.rmPrefix(u.slice(1)),this.multibaseName=d}else this.version=0,this.codec="dag-pb",this.multihash=i.fromB58String(e),this.multibaseName="base58btc";return t.validateCID(this),void Object.defineProperty(this,"string",{value:e})}if(e instanceof Uint8Array){var l=parseInt(e[0].toString(),16);if(1===l){var p=e;this.version=l,this.codec=c.getCodec(p.slice(1)),this.multihash=c.rmPrefix(p.slice(1)),this.multibaseName="base32"}else this.version=0,this.codec="dag-pb",this.multihash=e,this.multibaseName="base58btc";t.validateCID(this)}else this.version=e,"number"===typeof r&&(r=b[r]),this.codec=r,this.multihash=a,this.multibaseName=s||(0===e?"base58btc":"base32"),t.validateCID(this)}return a(t,[{key:"bytes",get:function(){var e=this._bytes;if(!e){if(0===this.version)e=this.multihash;else{if(1!==this.version)throw new Error("unsupported version");var t=c.getCodeVarint(this.codec);e=f([[1],t,this.multihash],1+t.byteLength+this.multihash.byteLength)}Object.defineProperty(this,"_bytes",{value:e})}return e}},{key:"prefix",get:function(){var e=c.getCodeVarint(this.codec),t=i.prefix(this.multihash);return f([[this.version],e,t],1+e.byteLength+t.byteLength)}},{key:"code",get:function(){return l[this.codec]}},{key:"toV0",value:function(){if("dag-pb"!==this.codec)throw new Error("Cannot convert a non dag-pb CID to CIDv0");var e=i.decode(this.multihash),r=e.name,n=e.length;if("sha2-256"!==r)throw new Error("Cannot convert non sha2-256 multihash CID to CIDv0");if(32!==n)throw new Error("Cannot convert non 32 byte multihash CID to CIDv0");return new t(0,this.codec,this.multihash)}},{key:"toV1",value:function(){return new t(1,this.codec,this.multihash,this.multibaseName)}},{key:"toBaseEncodedString",value:function(){var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.multibaseName;if(this.string&&0!==this.string.length&&t===this.multibaseName)return this.string;if(0===this.version){if("base58btc"!==t)throw new Error("not supported with CIDv0, to support different bases, please migrate the instance do CIDv1, you can do that through cid.toV1()");e=i.toB58String(this.multihash)}else{if(1!==this.version)throw new Error("unsupported version");e=d(o.encode(t,this.bytes))}return t===this.multibaseName&&Object.defineProperty(this,"string",{value:e}),e}},{key:e,value:function(){return"CID("+this.toString()+")"}},{key:"toString",value:function(e){return this.toBaseEncodedString(e)}},{key:"toJSON",value:function(){return{codec:this.codec,version:this.version,hash:this.multihash}}},{key:"equals",value:function(e){return this.codec===e.codec&&this.version===e.version&&u(this.multihash,e.multihash)}}],[{key:"validateCID",value:function(e){var t=s.checkCIDComponents(e);if(t)throw new Error(t)}},{key:"isCID",value:function(e){return e instanceof t||Boolean(e&&e[h])}}]),t}(Symbol.for("nodejs.util.inspect.custom"));p.codecs=l,e.exports=p},function(e,t,r){"use strict";e.exports=r(967)},function(e,t,r){e.exports=r(396)},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}},a=n(r(514)),i=n(r(1090));a.default.DefaultOpts.ImageClass=i.default,e.exports=a.default},function(e,t,r){"use strict";r.d(t,"a",(function(){return s}));var n=1/12.92;function a(e){return Math.pow((e+.055)/1.055,2.4)}function i(e){var t=e[0]/255,r=e[1]/255,i=e[2]/255;return.2126*(t<=.03928?t*n:a(t))+.7152*(r<=.03928?r*n:a(r))+.0722*(i<=.03928?i*n:a(i))}function o(e){var t=255;8===(e=e.replace(/^#/,"")).length&&(t=parseInt(e.slice(6,8),16),e=e.substring(0,6)),4===e.length&&(t=parseInt(e.slice(3,4).repeat(2),16),e=e.substring(0,3)),3===e.length&&(e=e[0]+e[0]+e[1]+e[1]+e[2]+e[2]);var r=parseInt(e,16);return[r>>16,r>>8&255,255&r,t]}function c(e,t){return function(e,t){return(Math.max(e,t)+.05)/(Math.min(e,t)+.05)}(i(e),i(t))}function s(e,t){return c(o(e),o(t))}},function(e,t,r){"use strict";(function(e){var n=r(1),a=r.n(n),i=r(72),o=r(12),c=r.n(o),s="undefined"!==typeof globalThis?globalThis:"undefined"!==typeof window?window:"undefined"!==typeof e?e:{};function f(e){var t=[];return{on:function(e){t.push(e)},off:function(e){t=t.filter((function(t){return t!==e}))},get:function(){return e},set:function(r,n){e=r,t.forEach((function(t){return t(e,n)}))}}}var d=a.a.createContext||function(e,t){var r,a,o="__create-react-context-"+function(){var e="__global_unique_id__";return s[e]=(s[e]||0)+1}()+"__",d=function(e){function r(){var t;return(t=e.apply(this,arguments)||this).emitter=f(t.props.value),t}Object(i.a)(r,e);var n=r.prototype;return n.getChildContext=function(){var e;return(e={})[o]=this.emitter,e},n.componentWillReceiveProps=function(e){if(this.props.value!==e.value){var r,n=this.props.value,a=e.value;((i=n)===(o=a)?0!==i||1/i===1/o:i!==i&&o!==o)?r=0:(r="function"===typeof t?t(n,a):1073741823,0!==(r|=0)&&this.emitter.set(e.value,r))}var i,o},n.render=function(){return this.props.children},r}(n.Component);d.childContextTypes=((r={})[o]=c.a.object.isRequired,r);var u=function(t){function r(){var e;return(e=t.apply(this,arguments)||this).state={value:e.getValue()},e.onUpdate=function(t,r){0!==((0|e.observedBits)&r)&&e.setState({value:e.getValue()})},e}Object(i.a)(r,t);var n=r.prototype;return n.componentWillReceiveProps=function(e){var t=e.observedBits;this.observedBits=void 0===t||null===t?1073741823:t},n.componentDidMount=function(){this.context[o]&&this.context[o].on(this.onUpdate);var e=this.props.observedBits;this.observedBits=void 0===e||null===e?1073741823:e},n.componentWillUnmount=function(){this.context[o]&&this.context[o].off(this.onUpdate)},n.getValue=function(){return this.context[o]?this.context[o].get():e},n.render=function(){return(e=this.props.children,Array.isArray(e)?e[0]:e)(this.state.value);var e},r}(n.Component);return u.contextTypes=((a={})[o]=c.a.object,a),{Provider:d,Consumer:u}};t.a=d}).call(this,r(44))},function(e,t,r){var n=r(1092);e.exports=b,e.exports.parse=i,e.exports.compile=function(e,t){return c(i(e,t),t)},e.exports.tokensToFunction=c,e.exports.tokensToRegExp=l;var a=new RegExp(["(\\\\.)","([\\/.])?(?:(?:\\:(\\w+)(?:\\(((?:\\\\.|[^\\\\()])+)\\))?|\\(((?:\\\\.|[^\\\\()])+)\\))([+*?])?|(\\*))"].join("|"),"g");function i(e,t){for(var r,n=[],i=0,o=0,c="",d=t&&t.delimiter||"/";null!=(r=a.exec(e));){var u=r[0],l=r[1],b=r.index;if(c+=e.slice(o,b),o=b+u.length,l)c+=l[1];else{var h=e[o],p=r[2],m=r[3],v=r[4],g=r[5],x=r[6],y=r[7];c&&(n.push(c),c="");var w=null!=p&&null!=h&&h!==p,k="+"===x||"*"===x,_="?"===x||"*"===x,M=r[2]||d,S=v||g;n.push({name:m||i++,prefix:p||"",delimiter:M,optional:_,repeat:k,partial:w,asterisk:!!y,pattern:S?f(S):y?".*":"[^"+s(M)+"]+?"})}}return oe.length)&&(t=e.length);for(var r=0,n=Array(t);re.length)&&(t=e.length);for(var r=0,n=new Array(t);r=e.length?{done:!0}:{done:!1,value:e[n++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}return(r=e[Symbol.iterator]()).next.bind(r)}function u(e,t){if(null!=e)if(function(e){return!(!e||"[object Function]"!={}.toString.call(e))}(e))e(t);else try{e.current=t}catch(r){throw new Error('Cannot assign value "'+t+'" to ref "'+e+'"')}}function l(e,t){return function(r){if(e&&e(r),!r.defaultPrevented)return t(r)}}var b=r(50),h=r(22),p=r(12),m=r.n(p);function v(e,t){return function(e,t){var r=Object(n.useState)((function(){return{value:e,callback:t,facade:{get current(){return r.value},set current(e){var t=r.value;t!==e&&(r.value=e,r.callback(e,t))}}}}))[0];return r.callback=t,r.facade}(t,(function(t){return e.forEach((function(e){return function(e,t){return"function"===typeof e?e(t):e&&(e.current=t),e}(e,t)}))}))}var g={width:"1px",height:"0px",padding:0,overflow:"hidden",position:"fixed",top:"1px",left:"1px"},x=function(e){var t=e.children;return n.createElement(n.Fragment,null,n.createElement("div",{key:"guard-first","data-focus-guard":!0,"data-focus-auto-guard":!0,style:g}),t,t&&n.createElement("div",{key:"guard-last","data-focus-guard":!0,"data-focus-auto-guard":!0,style:g}))};x.propTypes={},x.defaultProps={children:null};var y=r(90);function w(e){return e}function k(e,t){void 0===t&&(t=w);var r=[],n=!1;return{read:function(){if(n)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return r.length?r[r.length-1]:e},useMedium:function(e){var a=t(e,n);return r.push(a),function(){r=r.filter((function(e){return e!==a}))}},assignSyncMedium:function(e){for(n=!0;r.length;){var t=r;r=[],t.forEach(e)}r={push:function(t){return e(t)},filter:function(){return r}}},assignMedium:function(e){n=!0;var t=[];if(r.length){var a=r;r=[],a.forEach(e),t=r}var i=function(){var r=t;t=[],r.forEach(e)},o=function(){return Promise.resolve().then(i)};o(),r={push:function(e){t.push(e),o()},filter:function(e){return t=t.filter(e),r}}}}}function _(e,t){return void 0===t&&(t=w),k(e,t)}function M(e){void 0===e&&(e={});var t=k(null);return t.options=y.a({async:!0,ssr:!1},e),t}var S=_({},(function(e){return{target:e.target,currentTarget:e.currentTarget}})),E=_(),O=_(),A=M({async:!0}),T=[],j=n.forwardRef((function(e,t){var r,a=n.useState(),i=a[0],o=a[1],c=n.useRef(),s=n.useRef(!1),f=n.useRef(null),d=e.children,u=e.disabled,l=e.noFocusGuards,b=e.persistentFocus,p=e.crossFrame,m=e.autoFocus,x=(e.allowTextSelection,e.group),y=e.className,w=e.whiteList,k=e.shards,_=void 0===k?T:k,M=e.as,O=void 0===M?"div":M,j=e.lockProps,P=void 0===j?{}:j,C=e.sideCar,R=e.returnFocus,N=e.focusOptions,B=e.onActivation,L=e.onDeactivation,I=n.useState({})[0],F=n.useCallback((function(){f.current=f.current||document&&document.activeElement,c.current&&B&&B(c.current),s.current=!0}),[B]),D=n.useCallback((function(){s.current=!1,L&&L(c.current)}),[L]);Object(n.useEffect)((function(){u||(f.current=null)}),[]);var U=n.useCallback((function(e){var t=f.current;if(t&&t.focus){var r="function"===typeof R?R(t):R;if(Boolean(r)){var n="object"===typeof r?r:void 0;f.current=null,e?Promise.resolve().then((function(){return t.focus(n)})):t.focus(n)}}}),[R]),z=n.useCallback((function(e){s.current&&S.useMedium(e)}),[]),H=E.useMedium,q=n.useCallback((function(e){c.current!==e&&(c.current=e,o(e))}),[]);var J=Object(h.a)(((r={})["data-focus-lock-disabled"]=u&&"disabled",r["data-focus-lock"]=x,r),P),V=!0!==l,G=V&&"tail"!==l,X=v([t,q]);return n.createElement(n.Fragment,null,V&&[n.createElement("div",{key:"guard-first","data-focus-guard":!0,tabIndex:u?-1:0,style:g}),n.createElement("div",{key:"guard-nearest","data-focus-guard":!0,tabIndex:u?-1:1,style:g})],!u&&n.createElement(C,{id:I,sideCar:A,observed:i,disabled:u,persistentFocus:b,crossFrame:p,autoFocus:m,whiteList:w,shards:_,onActivation:F,onDeactivation:D,returnFocus:U,focusOptions:N}),n.createElement(O,Object(h.a)({ref:X},J,{className:y,onBlur:H,onFocus:z}),d),G&&n.createElement("div",{"data-focus-guard":!0,tabIndex:u?-1:0,style:g}))}));j.propTypes={},j.defaultProps={children:void 0,disabled:!1,returnFocus:!1,focusOptions:void 0,noFocusGuards:!1,autoFocus:!0,persistentFocus:!1,crossFrame:!0,allowTextSelection:void 0,group:void 0,className:void 0,whiteList:void 0,shards:void 0,as:"div",lockProps:{},onActivation:void 0,onDeactivation:void 0};var P=j,C=r(72),R=r(31);var N=function(e,t){return function(r){var i,o=[];function c(){i=e(o.map((function(e){return e.props}))),t(i)}var s=function(e){function t(){return e.apply(this,arguments)||this}Object(C.a)(t,e),t.peek=function(){return i};var n=t.prototype;return n.componentDidMount=function(){o.push(this),c()},n.componentDidUpdate=function(){c()},n.componentWillUnmount=function(){var e=o.indexOf(this);o.splice(e,1),c()},n.render=function(){return a.a.createElement(r,this.props)},t}(n.PureComponent);return Object(R.a)(s,"displayName","SideEffect("+function(e){return e.displayName||e.name||"Component"}(r)+")"),s}},B=function(e){for(var t=Array(e.length),r=0;r0&&t.add(a),(i&Node.DOCUMENT_POSITION_CONTAINS)>0&&t.add(n)}return e.filter((function(e,r){return!t.has(r)}))}(B(function e(t){return t.parentNode?e(t.parentNode):t}(t).querySelectorAll('[data-focus-lock="'+r+'"]:not([data-focus-lock-disabled="disabled"])'))):[t]),e}),[])},F=function(e){return Boolean(B(e.querySelectorAll("iframe")).some((function(e){return e===document.activeElement})))},D=function(e){var t=document&&document.activeElement;return!(!t||t.dataset&&t.dataset.focusGuard)&&I(e).reduce((function(e,r){return e||r.contains(t)||F(r)}),!1)},U=function(e){return"INPUT"===e.tagName&&"radio"===e.type},z=function(e,t){return U(e)&&e.name?function(e,t){return t.filter(U).filter((function(t){return t.name===e.name})).filter((function(e){return e.checked}))[0]||e}(e,t):e},H=function(e){return e[0]&&e.length>1?z(e[0],e):e[0]},q=function(e,t){return e.length>1?e.indexOf(z(e[t],e)):t},J=function(e,t){return!e||e===document||e&&e.nodeType===Node.DOCUMENT_NODE||!function(e){if(e.nodeType!==Node.ELEMENT_NODE)return!1;var t=window.getComputedStyle(e,null);return!(!t||!t.getPropertyValue)&&("none"===t.getPropertyValue("display")||"hidden"===t.getPropertyValue("visibility"))}(e)&&t(e.parentNode&&e.parentNode.nodeType===Node.DOCUMENT_FRAGMENT_NODE?e.parentNode.host:e.parentNode)},V=function(e){return Boolean(e&&e.dataset&&e.dataset.focusGuard)},G=function(e){return!V(e)},X=function(e){return Boolean(e)},K=function(e,t,r,n){var a=e.length,i=e[0],o=e[a-1],c=V(r);if(!(e.indexOf(r)>=0)){var s=t.indexOf(r),f=n?t.indexOf(n):s,d=n?e.indexOf(n):-1,u=s-f,l=t.indexOf(i),b=t.indexOf(o),h=function(e){var t=new Set;return e.forEach((function(r){return t.add(z(r,e))})),e.filter((function(e){return t.has(e)}))}(t),p=h.indexOf(r)-(n?h.indexOf(n):s),m=q(e,0),v=q(e,a-1);return-1===s||-1===d?"NEW_FOCUS":!u&&d>=0?d:s<=l&&c&&Math.abs(u)>1?v:s>=b&&c&&Math.abs(u)>1?m:u&&Math.abs(p)>1?d:s<=l?v:s>b?m:u?Math.abs(u)>1?d:(a+d+u)%a:void 0}},W=function(e,t){var r=e.tabIndex-t.tabIndex,n=e.index-t.index;if(r){if(!e.tabIndex)return 1;if(!t.tabIndex)return-1}return r||n},Z=function(e,t,r){return B(e).map((function(e,t){return{node:e,index:t,tabIndex:r&&-1===e.tabIndex?(e.dataset||{}).focusGuard?0:-1:e.tabIndex}})).filter((function(e){return!t||e.tabIndex>=0})).sort(W)},$=["button:enabled","select:enabled","textarea:enabled","input:enabled","a[href]","area[href]","summary","iframe","object","embed","audio[controls]","video[controls]","[tabindex]","[contenteditable]","[autofocus]"].join(","),Q=$+", [data-focus-guard]",Y=function(e,t){return e.reduce((function(e,r){return e.concat(B(r.querySelectorAll(t?Q:$)),r.parentNode?B(r.parentNode.querySelectorAll($)).filter((function(e){return e===r})):[])}),[])},ee=function(e,t){return B(e).filter((function(e){return function e(t,r){var n=t.get(r);if(void 0!==n)return n;var a=J(r,e.bind(void 0,t));return t.set(r,a),a}(t,e)})).filter((function(e){return function(e){return!(("INPUT"===e.tagName||"BUTTON"===e.tagName)&&("hidden"===e.type||e.disabled))}(e)}))},te=function(e,t,r){return Z(ee(Y(e,r),t),!0,r)},re=function(e,t){return Z(ee(Y(e),t),!1)},ne=function(e,t){return ee(function(e){var t=e.querySelectorAll("[data-autofocus-inside]");return B(t).map((function(e){return Y([e])})).reduce((function(e,t){return e.concat(t)}),[])}(e),t)},ae=function e(t,r){return void 0===r&&(r=[]),r.push(t),t.parentNode&&e(t.parentNode,r),r},ie=function(e,t){for(var r=ae(e),n=ae(t),a=0;a=0)return i}return!1},oe=function(e,t,r){var n=L(e),a=L(t),i=n[0],o=!1;return a.filter(Boolean).forEach((function(e){o=ie(o||e,e)||o,r.filter(Boolean).forEach((function(e){var t=ie(i,e);t&&(o=!o||t.contains(o)?t:ie(t,o))}))})),o},ce=function(e,t){var r=document&&document.activeElement,n=I(e).filter(G),a=oe(r||e,e,n),i=new Map,o=re(n,i),c=te(n,i).filter((function(e){var t=e.node;return G(t)}));if(c[0]||(c=o)[0]){var s,f=re([a],i).map((function(e){return e.node})),d=function(e,t){var r=new Map;return t.forEach((function(e){return r.set(e.node,e)})),e.map((function(e){return r.get(e)})).filter(X)}(f,c),u=d.map((function(e){return e.node})),l=K(u,f,r,t);if("NEW_FOCUS"===l){var b=o.map((function(e){return e.node})).filter((s=function(e,t){return e.reduce((function(e,r){return e.concat(ne(r,t))}),[])}(n,i),function(e){return e.autofocus||e.dataset&&!!e.dataset.autofocus||s.indexOf(e)>=0}));return{node:b&&b.length?H(b):H(u)}}return void 0===l?l:d[l]}},se=0,fe=!1,de=function(e,t,r){void 0===r&&(r={});var n,a,i=ce(e,t);if(!fe&&i){if(se>2)return console.error("FocusLock: focus-fighting detected. Only one focus management system could be active. See https://github.com/theKashey/focus-lock/#focus-fighting"),fe=!0,void setTimeout((function(){fe=!1}),1);se++,n=i.node,a=r.focusOptions,n.focus(a),"contentWindow"in n&&n.contentWindow&&n.contentWindow.focus(),se--}};function ue(e){var t=window.setImmediate;"undefined"!==typeof t?t(e):setTimeout(e,1)}var le=function(){return document&&document.activeElement===document.body||document&&B(document.querySelectorAll("[data-no-focus-lock]")).some((function(e){return e.contains(document.activeElement)}))},be=null,he=null,pe=null,me=!1,ve=function(){return!0};function ge(e,t,r,n){var a=null,i=e;do{var o=n[i];if(o.guard)o.node.dataset.focusAutoGuard&&(a=o);else{if(!o.lockItem)break;if(i!==e)return;a=null}}while((i+=r)!==t);a&&(a.node.tabIndex=0)}var xe=function(e){return e&&"current"in e?e.current:e},ye=function(){var e,t=!1;if(be){var r=be,n=r.observed,a=r.persistentFocus,i=r.autoFocus,o=r.shards,c=r.crossFrame,s=r.focusOptions,f=n||pe&&pe.portaledElement,d=document&&document.activeElement;if(f){var u=[f].concat(o.map(xe).filter(Boolean));if(d&&!function(e){return(be.whiteList||ve)(e)}(d)||(a||(c?Boolean(me):"meanwhile"===me)||!le()||!he&&i)&&(!f||D(u)||(e=d,pe&&pe.portaledElement===e)||(document&&!he&&d&&!i?(d.blur&&d.blur(),document.body.focus()):(t=de(u,he,{focusOptions:s}),pe={})),me=!1,he=document&&document.activeElement),document){var l=document&&document.activeElement,b=function(e){var t=I(e).filter(G),r=oe(e,e,t),n=new Map,a=te([r],n,!0),i=te(t,n).filter((function(e){var t=e.node;return G(t)})).map((function(e){return e.node}));return a.map((function(e){var t=e.node;return{node:t,index:e.index,lockItem:i.indexOf(t)>=0,guard:V(t)}}))}(u),h=b.map((function(e){return e.node})).indexOf(l);h>-1&&(b.filter((function(e){var t=e.guard,r=e.node;return t&&r.dataset.focusAutoGuard})).forEach((function(e){return e.node.removeAttribute("tabIndex")})),ge(h,b.length,1,b),ge(h,-1,-1,b))}}}return t},we=function(e){ye()&&e&&(e.stopPropagation(),e.preventDefault())},ke=function(){return ue(ye)},_e=function(e){var t=e.target,r=e.currentTarget;r.contains(t)||(pe={observerNode:r,portaledElement:t})},Me=function(){me="just",setTimeout((function(){me="meanwhile"}),0)};S.assignSyncMedium(_e),E.assignMedium(ke),O.assignMedium((function(e){return e({moveFocusInside:de,focusInside:D})}));var Se=N((function(e){return e.filter((function(e){return!e.disabled}))}),(function(e){var t=e.slice(-1)[0];t&&!be&&(document.addEventListener("focusin",we),document.addEventListener("focusout",ke),window.addEventListener("blur",Me));var r=be,n=r&&t&&t.id===r.id;be=t,r&&!n&&(r.onDeactivation(),e.filter((function(e){return e.id===r.id})).length||r.returnFocus(!t)),t?(he=null,n&&r.observed===t.observed||t.onActivation(),ye(),ue(ye)):(document.removeEventListener("focusin",we),document.removeEventListener("focusout",ke),window.removeEventListener("blur",Me),he=null)}))((function(){return null})),Ee=n.forwardRef((function(e,t){return n.createElement(P,Object(h.a)({sideCar:Se,ref:t},e))})),Oe=P.propTypes||{};Oe.sideCar,Object(b.a)(Oe,["sideCar"]);Ee.propTypes={};var Ae=Ee,Te=M(),je=function(){},Pe=n.forwardRef((function(e,t){var r=n.useRef(null),a=n.useState({onScrollCapture:je,onWheelCapture:je,onTouchMoveCapture:je}),i=a[0],o=a[1],c=e.forwardProps,s=e.children,f=e.className,d=e.removeScrollBar,u=e.enabled,l=e.shards,b=e.sideCar,h=e.noIsolation,p=e.inert,m=e.allowPinchZoom,g=e.as,x=void 0===g?"div":g,w=y.c(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as"]),k=b,_=v([r,t]),M=y.a({},w,i);return n.createElement(n.Fragment,null,u&&n.createElement(k,{sideCar:Te,removeScrollBar:d,shards:l,noIsolation:h,inert:p,setCallbacks:o,allowPinchZoom:!!m,lockRef:r}),c?n.cloneElement(n.Children.only(s),y.a({},M,{ref:_})):n.createElement(x,y.a({},M,{className:f,ref:_}),s))}));Pe.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},Pe.classNames={fullWidth:"width-before-scroll-bar",zeroRight:"right-scroll-bar-position"};var Ce,Re=function(e){var t=e.sideCar,r=y.c(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var a=t.read();if(!a)throw new Error("Sidecar medium not found");return n.createElement(a,y.a({},r))};Re.isSideCarExport=!0;function Ne(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=Ce||r.nc;return t&&e.setAttribute("nonce",t),e}var Be=function(){var e=0,t=null;return{add:function(r){var n,a;0==e&&(t=Ne())&&(a=r,(n=t).styleSheet?n.styleSheet.cssText=a:n.appendChild(document.createTextNode(a)),function(e){(document.head||document.getElementsByTagName("head")[0]).appendChild(e)}(t)),e++},remove:function(){!--e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},Le=function(){var e=function(){var e=Be();return function(t){n.useEffect((function(){return e.add(t),function(){e.remove()}}),[])}}();return function(t){var r=t.styles;return e(r),null}},Ie={left:0,top:0,right:0,gap:0},Fe=function(e){return parseInt(e||"",10)||0},De=function(e){if(void 0===e&&(e="margin"),"undefined"===typeof window)return Ie;var t=function(e){var t=window.getComputedStyle(document.body),r=t["padding"===e?"paddingLeft":"marginLeft"],n=t["padding"===e?"paddingTop":"marginTop"],a=t["padding"===e?"paddingRight":"marginRight"];return[Fe(r),Fe(n),Fe(a)]}(e),r=document.documentElement.clientWidth,n=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,n-r+t[2]-t[0])}},Ue=Le(),ze=function(e,t,r,n){var a=e.left,i=e.top,o=e.right,c=e.gap;return void 0===r&&(r="margin"),"\n .with-scroll-bars-hidden {\n overflow: hidden "+n+";\n padding-right: "+c+"px "+n+";\n }\n body {\n overflow: hidden "+n+";\n "+[t&&"position: relative "+n+";","margin"===r&&"\n padding-left: "+a+"px;\n padding-top: "+i+"px;\n padding-right: "+o+"px;\n margin-left:0;\n margin-top:0;\n margin-right: "+c+"px "+n+";\n ","padding"===r&&"padding-right: "+c+"px "+n+";"].filter(Boolean).join("")+"\n }\n \n .right-scroll-bar-position {\n right: "+c+"px "+n+";\n }\n \n .width-before-scroll-bar {\n margin-right: "+c+"px "+n+";\n }\n \n .right-scroll-bar-position .right-scroll-bar-position {\n right: 0 "+n+";\n }\n \n .width-before-scroll-bar .width-before-scroll-bar {\n margin-right: 0 "+n+";\n }\n \n body {\n --removed-body-scroll-bar-size: "+c+"px;\n }\n"},He=function(e){var t=n.useState(De(e.gapMode)),r=t[0],a=t[1];n.useEffect((function(){a(De(e.gapMode))}),[e.gapMode]);var i=e.noRelative,o=e.noImportant,c=e.gapMode,s=void 0===c?"margin":c;return n.createElement(Ue,{styles:ze(r,!i,s,o?"":"!important")})},qe=function(e,t){var r=t;do{if("undefined"!==typeof ShadowRoot&&r instanceof ShadowRoot&&(r=r.host),Je(e,r)){var n=Ve(e,r);if(n[1]>n[2])return!0}r=r.parentNode}while(r&&r!==document.body);return!1},Je=function(e,t){return"v"===e?function(e){var t=window.getComputedStyle(e);return"hidden"!==t.overflowY&&!(t.overflowY===t.overflowX&&"visible"===t.overflowY)}(t):function(e){var t=window.getComputedStyle(e);return"range"===e.type||"hidden"!==t.overflowX&&!(t.overflowY===t.overflowX&&"visible"===t.overflowX)}(t)},Ve=function(e,t){return"v"===e?[(r=t).scrollTop,r.scrollHeight,r.clientHeight]:function(e){return[e.scrollLeft,e.scrollWidth,e.clientWidth]}(t);var r},Ge=!1;if("undefined"!==typeof window)try{var Xe=Object.defineProperty({},"passive",{get:function(){return Ge=!0,!0}});window.addEventListener("test",Xe,Xe),window.removeEventListener("test",Xe,Xe)}catch(dt){Ge=!1}var Ke=!!Ge&&{passive:!1},We=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},Ze=function(e){return[e.deltaX,e.deltaY]},$e=function(e){return e&&"current"in e?e.current:e},Qe=function(e){return"\n .block-interactivity-"+e+" {pointer-events: none;}\n .allow-interactivity-"+e+" {pointer-events: all;}\n"},Ye=0,et=[];var tt,rt=(tt=function(e){var t=n.useRef([]),r=n.useRef([0,0]),a=n.useRef(),i=n.useState(Ye++)[0],o=n.useState((function(){return Le()}))[0],c=n.useRef(e);n.useEffect((function(){c.current=e}),[e]),n.useEffect((function(){if(e.inert){document.body.classList.add("block-interactivity-"+i);var t=[e.lockRef.current].concat((e.shards||[]).map($e)).filter(Boolean);return t.forEach((function(e){return e.classList.add("allow-interactivity-"+i)})),function(){document.body.classList.remove("block-interactivity-"+i),t.forEach((function(e){return e.classList.remove("allow-interactivity-"+i)}))}}}),[e.inert,e.lockRef.current,e.shards]);var s=n.useCallback((function(e,t){if("touches"in e&&2===e.touches.length)return!c.current.allowPinchZoom;var n,i=We(e),o=r.current,s="deltaX"in e?e.deltaX:o[0]-i[0],f="deltaY"in e?e.deltaY:o[1]-i[1],d=e.target,u=Math.abs(s)>Math.abs(f)?"h":"v",l=qe(u,d);if(!l)return!0;if(l?n=u:(n="v"===u?"h":"v",l=qe(u,d)),!l)return!1;if(!a.current&&"changedTouches"in e&&(s||f)&&(a.current=n),!n)return!0;var b=a.current||n;return function(e,t,r,n,a){var i=n,o=r.target,c=t.contains(o),s=!1,f=i>0,d=0,u=0;do{var l=Ve(e,o),b=l[0],h=l[1]-l[2]-b;(b||h)&&Je(e,o)&&(d+=h,u+=b),o=o.parentNode}while(!c&&o!==document.body||c&&(t.contains(o)||t===o));return(f&&(a&&0===d||!a&&i>d)||!f&&(a&&0===u||!a&&-i>u))&&(s=!0),s}(b,t,e,"h"===b?s:f,!0)}),[]),f=n.useCallback((function(e){var r=e;if(et.length&&et[et.length-1]===o){var n="deltaY"in r?Ze(r):We(r),a=t.current.filter((function(e){return e.name===r.type&&e.target===r.target&&(t=e.delta,a=n,t[0]===a[0]&&t[1]===a[1]);var t,a}))[0];if(a&&a.should)r.preventDefault();else if(!a){var i=(c.current.shards||[]).map($e).filter(Boolean).filter((function(e){return e.contains(r.target)}));(i.length>0?s(r,i[0]):!c.current.noIsolation)&&r.preventDefault()}}}),[]),d=n.useCallback((function(e,r,n,a){var i={name:e,delta:r,target:n,should:a};t.current.push(i),setTimeout((function(){t.current=t.current.filter((function(e){return e!==i}))}),1)}),[]),u=n.useCallback((function(e){r.current=We(e),a.current=void 0}),[]),l=n.useCallback((function(t){d(t.type,Ze(t),t.target,s(t,e.lockRef.current))}),[]),b=n.useCallback((function(t){d(t.type,We(t),t.target,s(t,e.lockRef.current))}),[]);n.useEffect((function(){return et.push(o),e.setCallbacks({onScrollCapture:l,onWheelCapture:l,onTouchMoveCapture:b}),document.addEventListener("wheel",f,Ke),document.addEventListener("touchmove",f,Ke),document.addEventListener("touchstart",u,Ke),function(){et=et.filter((function(e){return e!==o})),document.removeEventListener("wheel",f,Ke),document.removeEventListener("touchmove",f,Ke),document.removeEventListener("touchstart",u,Ke)}}),[]);var h=e.removeScrollBar,p=e.inert;return n.createElement(n.Fragment,null,p?n.createElement(o,{styles:Qe(i)}):null,h?n.createElement(He,{gapMode:"margin"}):null)},Te.useMedium(tt),Re),nt=n.forwardRef((function(e,t){return n.createElement(Pe,y.a({},e,{ref:t,sideCar:rt}))}));nt.classNames=Pe.classNames;var at=nt;function it(){return(it=Object.assign||function(e){for(var t=1;t=0||(a[r]=e[r]);return a}m.a.bool,m.a.bool,m.a.bool,m.a.func;var ct=Object(n.forwardRef)((function(e,t){var r=e.as,a=void 0===r?"div":r,o=e.isOpen,c=void 0===o||o,s=ot(e,["as","isOpen"]);return Object(n.useEffect)((function(){c?window.__REACH_DISABLE_TOOLTIPS=!0:window.requestAnimationFrame((function(){window.__REACH_DISABLE_TOOLTIPS=!1}))}),[c]),c?Object(n.createElement)(i.a,{"data-reach-dialog-wrapper":""},Object(n.createElement)(st,it({ref:t,as:a},s))):null}));var st=Object(n.forwardRef)((function(e,t){var r=e.allowPinchZoom,a=e.as,i=void 0===a?"div":a,o=e.dangerouslyBypassFocusLock,f=void 0!==o&&o,b=e.dangerouslyBypassScrollLock,h=void 0!==b&&b,p=e.initialFocusRef,m=e.onClick,v=e.onDismiss,g=void 0===v?s:v,x=e.onKeyDown,y=e.onMouseDown,w=e.unstable_lockFocusAcrossFrames,k=void 0===w||w,_=ot(e,["allowPinchZoom","as","dangerouslyBypassFocusLock","dangerouslyBypassScrollLock","initialFocusRef","onClick","onDismiss","onKeyDown","onMouseDown","unstable_lockFocusAcrossFrames"]),M=Object(n.useRef)(null),S=Object(n.useRef)(null),E=function(){for(var e=arguments.length,t=new Array(e),r=0;r *"),(function(n){var a,i;if(n!==(null==(a=e.parentNode)||null==(i=a.parentNode)?void 0:i.parentNode)){var o=n.getAttribute("aria-hidden");null!==o&&"false"!==o||(t.push(o),r.push(n),n.setAttribute("aria-hidden","true"))}})),function(){r.forEach((function(e,r){var n=t[r];null===n?e.removeAttribute("aria-hidden"):e.setAttribute("aria-hidden",n)}))}}(S.current):void 0}),[]),Object(n.createElement)(Ae,{autoFocus:!0,returnFocus:!0,onActivation:O,disabled:f,crossFrame:k},Object(n.createElement)(at,{allowPinchZoom:r,enabled:!h},Object(n.createElement)(i,it({},_,{ref:E,"data-reach-dialog-overlay":"",onClick:l(m,(function(e){M.current===e.target&&(e.stopPropagation(),g(e))})),onKeyDown:l(x,(function(e){"Escape"===e.key&&(e.stopPropagation(),g(e))})),onMouseDown:l(y,(function(e){M.current=e.target}))}))))}));var ft=Object(n.forwardRef)((function(e,t){var r=e.as,a=void 0===r?"div":r,i=e.onClick;e.onKeyDown;var o=ot(e,["as","onClick","onKeyDown"]);return Object(n.createElement)(a,it({"aria-modal":"true",role:"dialog",tabIndex:-1},o,{ref:t,"data-reach-dialog-content":"",onClick:l(i,(function(e){e.stopPropagation()}))}))}))},function(e,t,r){"use strict";r.d(t,"b",(function(){return l})),r.d(t,"a",(function(){return b}));var n=r(46),a=r(5),i=r(40),o=(r(576),r(86)),c=r(11),s=new RegExp("^bytes([0-9]+)$"),f=new RegExp("^(u?int)([0-9]*)$"),d=new RegExp("^(.*)\\[([0-9]*)\\]$"),u=new c.a("solidity/5.5.0");function l(e,t){e.length!=t.length&&u.throwArgumentError("wrong number of values; expected ${ types.length }","values",t);var r=[];return e.forEach((function(e,i){r.push(function e(t,r,i){switch(t){case"address":return i?Object(a.o)(r,32):Object(a.a)(r);case"string":return Object(o.c)(r);case"bytes":return Object(a.a)(r);case"bool":return r=r?"0x01":"0x00",i?Object(a.o)(r,32):Object(a.a)(r)}var c=t.match(f);if(c){var l=parseInt(c[2]||"256");return(c[2]&&String(l)!==c[2]||l%8!==0||0===l||l>256)&&u.throwArgumentError("invalid number type","type",t),i&&(l=256),r=n.a.from(r).toTwos(l),Object(a.o)(r,l/8)}if(c=t.match(s)){var b=parseInt(c[1]);return(String(b)!==c[1]||0===b||b>32)&&u.throwArgumentError("invalid bytes type","type",t),Object(a.a)(r).byteLength!==b&&u.throwArgumentError("invalid value for ".concat(t),"value",r),i?Object(a.a)((r+"0000000000000000000000000000000000000000000000000000000000000000").substring(0,66)):r}if((c=t.match(d))&&Array.isArray(r)){var h=c[1];parseInt(c[2]||String(r.length))!=r.length&&u.throwArgumentError("invalid array length for ".concat(t),"value",r);var p=[];return r.forEach((function(t){p.push(e(h,t,!0))})),Object(a.b)(p)}return u.throwArgumentError("invalid type","type",t)}(e,t[i]))})),Object(a.h)(Object(a.b)(r))}function b(e,t){return Object(i.a)(l(e,t))}},function(e,t,r){(function(e){var n=Object.getOwnPropertyDescriptors||function(e){for(var t=Object.keys(e),r={},n=0;n=i)return e;switch(e){case"%s":return String(n[r++]);case"%d":return Number(n[r++]);case"%j":try{return JSON.stringify(n[r++])}catch(t){return"[Circular]"}default:return e}})),s=n[r];r=3&&(n.depth=arguments[2]),arguments.length>=4&&(n.colors=arguments[3]),h(r)?n.showHidden=r:r&&t._extend(n,r),g(n.showHidden)&&(n.showHidden=!1),g(n.depth)&&(n.depth=2),g(n.colors)&&(n.colors=!1),g(n.customInspect)&&(n.customInspect=!0),n.colors&&(n.stylize=s),d(n,e,n.depth)}function s(e,t){var r=c.styles[t];return r?"\x1b["+c.colors[r][0]+"m"+e+"\x1b["+c.colors[r][1]+"m":e}function f(e,t){return e}function d(e,r,n){if(e.customInspect&&r&&_(r.inspect)&&r.inspect!==t.inspect&&(!r.constructor||r.constructor.prototype!==r)){var a=r.inspect(n,e);return v(a)||(a=d(e,a,n)),a}var i=function(e,t){if(g(t))return e.stylize("undefined","undefined");if(v(t)){var r="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(r,"string")}if(m(t))return e.stylize(""+t,"number");if(h(t))return e.stylize(""+t,"boolean");if(p(t))return e.stylize("null","null")}(e,r);if(i)return i;var o=Object.keys(r),c=function(e){var t={};return e.forEach((function(e,r){t[e]=!0})),t}(o);if(e.showHidden&&(o=Object.getOwnPropertyNames(r)),k(r)&&(o.indexOf("message")>=0||o.indexOf("description")>=0))return u(r);if(0===o.length){if(_(r)){var s=r.name?": "+r.name:"";return e.stylize("[Function"+s+"]","special")}if(x(r))return e.stylize(RegExp.prototype.toString.call(r),"regexp");if(w(r))return e.stylize(Date.prototype.toString.call(r),"date");if(k(r))return u(r)}var f,y="",M=!1,S=["{","}"];(b(r)&&(M=!0,S=["[","]"]),_(r))&&(y=" [Function"+(r.name?": "+r.name:"")+"]");return x(r)&&(y=" "+RegExp.prototype.toString.call(r)),w(r)&&(y=" "+Date.prototype.toUTCString.call(r)),k(r)&&(y=" "+u(r)),0!==o.length||M&&0!=r.length?n<0?x(r)?e.stylize(RegExp.prototype.toString.call(r),"regexp"):e.stylize("[Object]","special"):(e.seen.push(r),f=M?function(e,t,r,n,a){for(var i=[],o=0,c=t.length;o=0&&0,e+t.replace(/\u001b\[\d\d?m/g,"").length+1}),0)>60)return r[0]+(""===t?"":t+"\n ")+" "+e.join(",\n ")+" "+r[1];return r[0]+t+" "+e.join(", ")+" "+r[1]}(f,y,S)):S[0]+y+S[1]}function u(e){return"["+Error.prototype.toString.call(e)+"]"}function l(e,t,r,n,a,i){var o,c,s;if((s=Object.getOwnPropertyDescriptor(t,a)||{value:t[a]}).get?c=s.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):s.set&&(c=e.stylize("[Setter]","special")),A(n,a)||(o="["+a+"]"),c||(e.seen.indexOf(s.value)<0?(c=p(r)?d(e,s.value,null):d(e,s.value,r-1)).indexOf("\n")>-1&&(c=i?c.split("\n").map((function(e){return" "+e})).join("\n").substr(2):"\n"+c.split("\n").map((function(e){return" "+e})).join("\n")):c=e.stylize("[Circular]","special")),g(o)){if(i&&a.match(/^\d+$/))return c;(o=JSON.stringify(""+a)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(o=o.substr(1,o.length-2),o=e.stylize(o,"name")):(o=o.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),o=e.stylize(o,"string"))}return o+": "+c}function b(e){return Array.isArray(e)}function h(e){return"boolean"===typeof e}function p(e){return null===e}function m(e){return"number"===typeof e}function v(e){return"string"===typeof e}function g(e){return void 0===e}function x(e){return y(e)&&"[object RegExp]"===M(e)}function y(e){return"object"===typeof e&&null!==e}function w(e){return y(e)&&"[object Date]"===M(e)}function k(e){return y(e)&&("[object Error]"===M(e)||e instanceof Error)}function _(e){return"function"===typeof e}function M(e){return Object.prototype.toString.call(e)}function S(e){return e<10?"0"+e.toString(10):e.toString(10)}t.debuglog=function(r){if(g(i)&&(i=Object({NODE_ENV:"production",PUBLIC_URL:".",WDS_SOCKET_HOST:void 0,WDS_SOCKET_PATH:void 0,WDS_SOCKET_PORT:void 0}).NODE_DEBUG||""),r=r.toUpperCase(),!o[r])if(new RegExp("\\b"+r+"\\b","i").test(i)){var n=e.pid;o[r]=function(){var e=t.format.apply(t,arguments);console.error("%s %d: %s",r,n,e)}}else o[r]=function(){};return o[r]},t.inspect=c,c.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},c.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},t.isArray=b,t.isBoolean=h,t.isNull=p,t.isNullOrUndefined=function(e){return null==e},t.isNumber=m,t.isString=v,t.isSymbol=function(e){return"symbol"===typeof e},t.isUndefined=g,t.isRegExp=x,t.isObject=y,t.isDate=w,t.isError=k,t.isFunction=_,t.isPrimitive=function(e){return null===e||"boolean"===typeof e||"number"===typeof e||"string"===typeof e||"symbol"===typeof e||"undefined"===typeof e},t.isBuffer=r(634);var E=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function O(){var e=new Date,t=[S(e.getHours()),S(e.getMinutes()),S(e.getSeconds())].join(":");return[e.getDate(),E[e.getMonth()],t].join(" ")}function A(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.log=function(){console.log("%s - %s",O(),t.format.apply(t,arguments))},t.inherits=r(635),t._extend=function(e,t){if(!t||!y(t))return e;for(var r=Object.keys(t),n=r.length;n--;)e[r[n]]=t[r[n]];return e};var T="undefined"!==typeof Symbol?Symbol("util.promisify.custom"):void 0;function j(e,t){if(!e){var r=new Error("Promise was rejected with a falsy value");r.reason=e,e=r}return t(e)}t.promisify=function(e){if("function"!==typeof e)throw new TypeError('The "original" argument must be of type Function');if(T&&e[T]){var t;if("function"!==typeof(t=e[T]))throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(t,T,{value:t,enumerable:!1,writable:!1,configurable:!0}),t}function t(){for(var t,r,n=new Promise((function(e,n){t=e,r=n})),a=[],i=0;i0&&a[a.length-1])&&(6===i[0]||2===i[0])){o=0;continue}if(3===i[0]&&(!a||i[1]>a[0]&&i[1]=0&&(e._idleTimeoutId=setTimeout((function(){e._onTimeout&&e._onTimeout()}),t))},r(688),t.setImmediate="undefined"!==typeof self&&self.setImmediate||"undefined"!==typeof e&&e.setImmediate||this&&this.setImmediate,t.clearImmediate="undefined"!==typeof self&&self.clearImmediate||"undefined"!==typeof e&&e.clearImmediate||this&&this.clearImmediate}).call(this,r(44))},,,,,function(e,t,r){"use strict";var n=r(106).rotr32;function a(e,t,r){return e&t^~e&r}function i(e,t,r){return e&t^e&r^t&r}function o(e,t,r){return e^t^r}t.ft_1=function(e,t,r,n){return 0===e?a(t,r,n):1===e||3===e?o(t,r,n):2===e?i(t,r,n):void 0},t.ch32=a,t.maj32=i,t.p32=o,t.s0_256=function(e){return n(e,2)^n(e,13)^n(e,22)},t.s1_256=function(e){return n(e,6)^n(e,11)^n(e,25)},t.g0_256=function(e){return n(e,7)^n(e,18)^e>>>3},t.g1_256=function(e){return n(e,17)^n(e,19)^e>>>10}},function(e,t,r){"use strict";var n=r(106),a=r(198),i=r(393),o=r(93),c=n.sum32,s=n.sum32_4,f=n.sum32_5,d=i.ch32,u=i.maj32,l=i.s0_256,b=i.s1_256,h=i.g0_256,p=i.g1_256,m=a.BlockHash,v=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298];function g(){if(!(this instanceof g))return new g;m.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=v,this.W=new Array(64)}n.inherits(g,m),e.exports=g,g.blockSize=512,g.outSize=256,g.hmacStrength=192,g.padLength=64,g.prototype._update=function(e,t){for(var r=this.W,n=0;n<16;n++)r[n]=e[t+n];for(;n=0;--a){var i=this.tryEntries[a],o=i.completion;if("root"===i.tryLoc)return n("end");if(i.tryLoc<=this.prev){var c=r.call(i,"catchLoc"),s=r.call(i,"finallyLoc");if(c&&s){if(this.prev=0;--n){var a=this.tryEntries[n];if(a.tryLoc<=this.prev&&r.call(a,"finallyLoc")&&this.prev=0;--t){var r=this.tryEntries[t];if(r.finallyLoc===e)return this.complete(r.completion,r.afterLoc),k(r),d}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.tryLoc===e){var n=r.completion;if("throw"===n.type){var a=n.arg;k(r)}return a}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,r){return this.delegate={iterator:M(e),resultName:t,nextLoc:r},"next"===this.method&&(this.arg=void 0),d}},e}(e.exports);try{regeneratorRuntime=n}catch(a){"object"===typeof globalThis?globalThis.regeneratorRuntime=n:Function("r","regeneratorRuntime = r")(n)}},function(e,t,r){var n=r(630),a=r(580);e.exports=function(e){if("string"===typeof e||"number"===typeof e){var t=new n(1),r=String(e).toLowerCase().trim(),i="0x"===r.substr(0,2)||"-0x"===r.substr(0,3),o=a(r);if("-"===o.substr(0,1)&&(o=a(o.slice(1)),t=new n(-1,10)),!(o=""===o?"0":o).match(/^-?[0-9]+$/)&&o.match(/^[0-9A-Fa-f]+$/)||o.match(/^[a-fA-F]+$/)||!0===i&&o.match(/^[0-9A-Fa-f]+$/))return new n(o,16).mul(t);if((o.match(/^-?[0-9]+$/)||""===o)&&!1===i)return new n(o,10).mul(t)}else if("object"===typeof e&&e.toString&&!e.pop&&!e.push&&e.toString(10).match(/^-?[0-9]+$/)&&(e.mul||e.dividedToIntegerBy))return new n(e.toString(10),10);throw new Error("[number-to-bn] while converting number "+JSON.stringify(e)+" to BN.js instance, error: invalid number value. Value must be an integer, hex string, BN or BigNumber instance. Note, decimals are not supported.")}},function(e,t,r){(function(t){var n=r(298),a=r(397),i=r(632),o=r(107),c=r(698),s=function(e){return n.isBN(e)},f=function(e){return e&&e.constructor&&"BigNumber"===e.constructor.name},d=function(e){try{return a.apply(null,arguments)}catch(t){throw new Error(t+' Given value: "'+e+'"')}},u=function(e){return!!/^(0x)?[0-9a-f]{40}$/i.test(e)&&(!(!/^(0x|0X)?[0-9a-f]{40}$/.test(e)&&!/^(0x|0X)?[0-9A-F]{40}$/.test(e))||l(e))},l=function(e){e=e.replace(/^0x/i,"");for(var t=y(e.toLowerCase()).replace(/^0x/i,""),r=0;r<40;r++)if(parseInt(t[r],16)>7&&e[r].toUpperCase()!==e[r]||parseInt(t[r],16)<=7&&e[r].toLowerCase()!==e[r])return!1;return!0},b=function(e){var t="";e=(e=(e=(e=(e=i.encode(e)).replace(/^(?:\u0000)*/,"")).split("").reverse().join("")).replace(/^(?:\u0000)*/,"")).split("").reverse().join("");for(var r=0;r>>4).toString(16)),t.push((15&e[r]).toString(16));return"0x"+t.join("")},isHex:g,isHexStrict:v,stripHexPrefix:function(e){return 0!==e&&g(e)?e.replace(/^(-)?0x/i,"$1"):e},leftPad:function(e,t,r){var n=/^0x/i.test(e)||"number"===typeof e,a=t-(e=e.toString(16).replace(/^0x/i,"")).length+1>=0?t-e.length+1:0;return(n?"0x":"")+new Array(a).join(r||"0")+e},rightPad:function(e,t,r){var n=/^0x/i.test(e)||"number"===typeof e,a=t-(e=e.toString(16).replace(/^0x/i,"")).length+1>=0?t-e.length+1:0;return(n?"0x":"")+e+new Array(a).join(r||"0")},toTwosComplement:function(e){return"0x"+d(e).toTwos(256).toString(16,64)},sha3:y,sha3Raw:function(e){return null===(e=y(e))?x:e},toNumber:function(e){return"number"===typeof e?e:h(m(e))}}}).call(this,r(30).Buffer)},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.KECCAK256_RLP=t.KECCAK256_RLP_S=t.KECCAK256_RLP_ARRAY=t.KECCAK256_RLP_ARRAY_S=t.KECCAK256_NULL=t.KECCAK256_NULL_S=t.TWO_POW256=t.MAX_INTEGER=void 0;var a=r(30).Buffer,i=n(r(150));t.MAX_INTEGER=new i.default("ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff",16),t.TWO_POW256=new i.default("10000000000000000000000000000000000000000000000000000000000000000",16),t.KECCAK256_NULL_S="c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470",t.KECCAK256_NULL=a.from(t.KECCAK256_NULL_S,"hex"),t.KECCAK256_RLP_ARRAY_S="1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",t.KECCAK256_RLP_ARRAY=a.from(t.KECCAK256_RLP_ARRAY_S,"hex"),t.KECCAK256_RLP_S="56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421",t.KECCAK256_RLP=a.from(t.KECCAK256_RLP_S,"hex")},function(e,t,r){"use strict";(function(e){var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r),Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[r]}})}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),a=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&n(t,e,r);return a(t,e),t},o=this&&this.__read||function(e,t){var r="function"===typeof Symbol&&e[Symbol.iterator];if(!r)return e;var n,a,i=r.call(e),o=[];try{for(;(void 0===t||t-- >0)&&!(n=i.next()).done;)o.push(n.value)}catch(c){a={error:c}}finally{try{n&&!n.done&&(r=i.return)&&r.call(i)}finally{if(a)throw a.error}}return o},c=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.isZeroAddress=t.zeroAddress=t.importPublic=t.privateToAddress=t.privateToPublic=t.publicToAddress=t.pubToAddress=t.isValidPublic=t.isValidPrivate=t.generateAddress2=t.generateAddress=t.isValidChecksumAddress=t.toChecksumAddress=t.isValidAddress=t.Account=void 0;var s=c(r(294)),f=c(r(150)),d=i(r(236)),u=r(383),l=r(167),b=r(399),h=r(151),p=r(302),m=r(238),v=r(310),g=function(){function e(e,t,r,n){void 0===e&&(e=new f.default(0)),void 0===t&&(t=new f.default(0)),void 0===r&&(r=b.KECCAK256_RLP),void 0===n&&(n=b.KECCAK256_NULL),this.nonce=e,this.balance=t,this.stateRoot=r,this.codeHash=n,this._validate()}return e.fromAccountData=function(t){var r=t.nonce,n=t.balance,a=t.stateRoot,i=t.codeHash;return new e(r?new f.default((0,h.toBuffer)(r)):void 0,n?new f.default((0,h.toBuffer)(n)):void 0,a?(0,h.toBuffer)(a):void 0,i?(0,h.toBuffer)(i):void 0)},e.fromRlpSerializedAccount=function(e){var t=d.decode(e);if(!Array.isArray(t))throw new Error("Invalid serialized account input. Must be array");return this.fromValuesArray(t)},e.fromValuesArray=function(t){var r=o(t,4),n=r[0],a=r[1],i=r[2],c=r[3];return new e(new f.default(n),new f.default(a),i,c)},e.prototype._validate=function(){if(this.nonce.lt(new f.default(0)))throw new Error("nonce must be greater than zero");if(this.balance.lt(new f.default(0)))throw new Error("balance must be greater than zero");if(32!==this.stateRoot.length)throw new Error("stateRoot must have a length of 32");if(32!==this.codeHash.length)throw new Error("codeHash must have a length of 32")},e.prototype.raw=function(){return[(0,v.bnToUnpaddedBuffer)(this.nonce),(0,v.bnToUnpaddedBuffer)(this.balance),this.stateRoot,this.codeHash]},e.prototype.serialize=function(){return d.encode(this.raw())},e.prototype.isContract=function(){return!this.codeHash.equals(b.KECCAK256_NULL)},e.prototype.isEmpty=function(){return this.balance.isZero()&&this.nonce.isZero()&&this.codeHash.equals(b.KECCAK256_NULL)},e}();t.Account=g;t.isValidAddress=function(e){try{(0,m.assertIsString)(e)}catch(t){return!1}return/^0x[0-9a-fA-F]{40}$/.test(e)};t.toChecksumAddress=function(e,t){(0,m.assertIsHexString)(e);var r=(0,l.stripHexPrefix)(e).toLowerCase(),n="";t&&(n=(0,v.toType)(t,v.TypeOutput.BN).toString()+"0x");for(var a=(0,p.keccakFromString)(n+r).toString("hex"),i="0x",o=0;o=8?i+=r[o].toUpperCase():i+=r[o];return i};t.isValidChecksumAddress=function(e,r){return(0,t.isValidAddress)(e)&&(0,t.toChecksumAddress)(e,r)===e};t.generateAddress=function(t,r){(0,m.assertIsBuffer)(t),(0,m.assertIsBuffer)(r);var n=new f.default(r);return n.isZero()?(0,p.rlphash)([t,null]).slice(-20):(0,p.rlphash)([t,e.from(n.toArray())]).slice(-20)};t.generateAddress2=function(t,r,n){return(0,m.assertIsBuffer)(t),(0,m.assertIsBuffer)(r),(0,m.assertIsBuffer)(n),(0,s.default)(20===t.length),(0,s.default)(32===r.length),(0,p.keccak256)(e.concat([e.from("ff","hex"),t,r,(0,p.keccak256)(n)])).slice(-20)};t.isValidPrivate=function(e){return(0,u.privateKeyVerify)(e)};t.isValidPublic=function(t,r){return void 0===r&&(r=!1),(0,m.assertIsBuffer)(t),64===t.length?(0,u.publicKeyVerify)(e.concat([e.from([4]),t])):!!r&&(0,u.publicKeyVerify)(t)};t.pubToAddress=function(t,r){return void 0===r&&(r=!1),(0,m.assertIsBuffer)(t),r&&64!==t.length&&(t=e.from((0,u.publicKeyConvert)(t,!1).slice(1))),(0,s.default)(64===t.length),(0,p.keccak)(t).slice(-20)},t.publicToAddress=t.pubToAddress;t.privateToPublic=function(t){return(0,m.assertIsBuffer)(t),e.from((0,u.publicKeyCreate)(t,!1)).slice(1)};t.privateToAddress=function(e){return(0,t.publicToAddress)((0,t.privateToPublic)(e))};t.importPublic=function(t){return(0,m.assertIsBuffer)(t),64!==t.length&&(t=e.from((0,u.publicKeyConvert)(t,!1).slice(1))),t};t.zeroAddress=function(){var e=(0,h.zeros)(20);return(0,h.bufferToHex)(e)};t.isZeroAddress=function(e){try{(0,m.assertIsString)(e)}catch(r){return!1}return(0,t.zeroAddress)()===e}}).call(this,r(30).Buffer)},function(e,t,r){e.exports=r(638)(r(639))},function(e,t){e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r>8,o=255&a;i?r.push(i,o):r.push(o)}return r},n.zero2=a,n.toHex=i,n.encode=function(e,t){return"hex"===t?i(e):e}},function(e,t,r){"use strict";var n=t;n.base=r(237),n.short=r(643),n.mont=r(644),n.edwards=r(645)},function(e,t){e.exports=function(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}},function(e,t,r){(t=e.exports=r(407)).Stream=t,t.Readable=t,t.Writable=r(411),t.Duplex=r(169),t.Transform=r(412),t.PassThrough=r(666),t.finished=r(303),t.pipeline=r(667)},function(e,t,r){"use strict";(function(t,n){var a;e.exports=S,S.ReadableState=M;r(91).EventEmitter;var i=function(e,t){return e.listeners(t).length},o=r(408),c=r(30).Buffer,s=t.Uint8Array||function(){};var f,d=r(660);f=d&&d.debuglog?d.debuglog("stream"):function(){};var u,l,b,h=r(661),p=r(409),m=r(410).getHighWaterMark,v=r(168).codes,g=v.ERR_INVALID_ARG_TYPE,x=v.ERR_STREAM_PUSH_AFTER_EOF,y=v.ERR_METHOD_NOT_IMPLEMENTED,w=v.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;r(33)(S,o);var k=p.errorOrDestroy,_=["error","close","destroy","pause","resume"];function M(e,t,n){a=a||r(169),e=e||{},"boolean"!==typeof n&&(n=t instanceof a),this.objectMode=!!e.objectMode,n&&(this.objectMode=this.objectMode||!!e.readableObjectMode),this.highWaterMark=m(this,e,"readableHighWaterMark",n),this.buffer=new h,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(u||(u=r(119).StringDecoder),this.decoder=new u(e.encoding),this.encoding=e.encoding)}function S(e){if(a=a||r(169),!(this instanceof S))return new S(e);var t=this instanceof a;this._readableState=new M(e,this,t),this.readable=!0,e&&("function"===typeof e.read&&(this._read=e.read),"function"===typeof e.destroy&&(this._destroy=e.destroy)),o.call(this)}function E(e,t,r,n,a){f("readableAddChunk",t);var i,o=e._readableState;if(null===t)o.reading=!1,function(e,t){if(f("onEofChunk"),t.ended)return;if(t.decoder){var r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,t.sync?T(e):(t.needReadable=!1,t.emittedReadable||(t.emittedReadable=!0,j(e)))}(e,o);else if(a||(i=function(e,t){var r;n=t,c.isBuffer(n)||n instanceof s||"string"===typeof t||void 0===t||e.objectMode||(r=new g("chunk",["string","Buffer","Uint8Array"],t));var n;return r}(o,t)),i)k(e,i);else if(o.objectMode||t&&t.length>0)if("string"===typeof t||o.objectMode||Object.getPrototypeOf(t)===c.prototype||(t=function(e){return c.from(e)}(t)),n)o.endEmitted?k(e,new w):O(e,o,t,!0);else if(o.ended)k(e,new x);else{if(o.destroyed)return!1;o.reading=!1,o.decoder&&!r?(t=o.decoder.write(t),o.objectMode||0!==t.length?O(e,o,t,!1):P(e,o)):O(e,o,t,!1)}else n||(o.reading=!1,P(e,o));return!o.ended&&(o.lengtht.highWaterMark&&(t.highWaterMark=function(e){return e>=1073741824?e=1073741824:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function T(e){var t=e._readableState;f("emitReadable",t.needReadable,t.emittedReadable),t.needReadable=!1,t.emittedReadable||(f("emitReadable",t.flowing),t.emittedReadable=!0,n.nextTick(j,e))}function j(e){var t=e._readableState;f("emitReadable_",t.destroyed,t.length,t.ended),t.destroyed||!t.length&&!t.ended||(e.emit("readable"),t.emittedReadable=!1),t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark,L(e)}function P(e,t){t.readingMore||(t.readingMore=!0,n.nextTick(C,e,t))}function C(e,t){for(;!t.reading&&!t.ended&&(t.length0,t.resumeScheduled&&!t.paused?t.flowing=!0:e.listenerCount("data")>0&&e.resume()}function N(e){f("readable nexttick read 0"),e.read(0)}function B(e,t){f("resume",t.reading),t.reading||e.read(0),t.resumeScheduled=!1,e.emit("resume"),L(e),t.flowing&&!t.reading&&e.read(0)}function L(e){var t=e._readableState;for(f("flow",t.flowing);t.flowing&&null!==e.read(););}function I(e,t){return 0===t.length?null:(t.objectMode?r=t.buffer.shift():!e||e>=t.length?(r=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.first():t.buffer.concat(t.length),t.buffer.clear()):r=t.buffer.consume(e,t.decoder),r);var r}function F(e){var t=e._readableState;f("endReadable",t.endEmitted),t.endEmitted||(t.ended=!0,n.nextTick(D,t,e))}function D(e,t){if(f("endReadableNT",e.endEmitted,e.length),!e.endEmitted&&0===e.length&&(e.endEmitted=!0,t.readable=!1,t.emit("end"),e.autoDestroy)){var r=t._writableState;(!r||r.autoDestroy&&r.finished)&&t.destroy()}}function U(e,t){for(var r=0,n=e.length;r=t.highWaterMark:t.length>0)||t.ended))return f("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?F(this):T(this),null;if(0===(e=A(e,t))&&t.ended)return 0===t.length&&F(this),null;var n,a=t.needReadable;return f("need readable",a),(0===t.length||t.length-e0?I(e,t):null)?(t.needReadable=t.length<=t.highWaterMark,e=0):(t.length-=e,t.awaitDrain=0),0===t.length&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&F(this)),null!==n&&this.emit("data",n),n},S.prototype._read=function(e){k(this,new y("_read()"))},S.prototype.pipe=function(e,t){var r=this,a=this._readableState;switch(a.pipesCount){case 0:a.pipes=e;break;case 1:a.pipes=[a.pipes,e];break;default:a.pipes.push(e)}a.pipesCount+=1,f("pipe count=%d opts=%j",a.pipesCount,t);var o=(!t||!1!==t.end)&&e!==n.stdout&&e!==n.stderr?s:m;function c(t,n){f("onunpipe"),t===r&&n&&!1===n.hasUnpiped&&(n.hasUnpiped=!0,f("cleanup"),e.removeListener("close",h),e.removeListener("finish",p),e.removeListener("drain",d),e.removeListener("error",b),e.removeListener("unpipe",c),r.removeListener("end",s),r.removeListener("end",m),r.removeListener("data",l),u=!0,!a.awaitDrain||e._writableState&&!e._writableState.needDrain||d())}function s(){f("onend"),e.end()}a.endEmitted?n.nextTick(o):r.once("end",o),e.on("unpipe",c);var d=function(e){return function(){var t=e._readableState;f("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&i(e,"data")&&(t.flowing=!0,L(e))}}(r);e.on("drain",d);var u=!1;function l(t){f("ondata");var n=e.write(t);f("dest.write",n),!1===n&&((1===a.pipesCount&&a.pipes===e||a.pipesCount>1&&-1!==U(a.pipes,e))&&!u&&(f("false write response, pause",a.awaitDrain),a.awaitDrain++),r.pause())}function b(t){f("onerror",t),m(),e.removeListener("error",b),0===i(e,"error")&&k(e,t)}function h(){e.removeListener("finish",p),m()}function p(){f("onfinish"),e.removeListener("close",h),m()}function m(){f("unpipe"),r.unpipe(e)}return r.on("data",l),function(e,t,r){if("function"===typeof e.prependListener)return e.prependListener(t,r);e._events&&e._events[t]?Array.isArray(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]:e.on(t,r)}(e,"error",b),e.once("close",h),e.once("finish",p),e.emit("pipe",r),a.flowing||(f("pipe resume"),r.resume()),e},S.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes||(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r)),this;if(!e){var n=t.pipes,a=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var i=0;i0,!1!==a.flowing&&this.resume()):"readable"===e&&(a.endEmitted||a.readableListening||(a.readableListening=a.needReadable=!0,a.flowing=!1,a.emittedReadable=!1,f("on readable",a.length,a.reading),a.length?T(this):a.reading||n.nextTick(N,this))),r},S.prototype.addListener=S.prototype.on,S.prototype.removeListener=function(e,t){var r=o.prototype.removeListener.call(this,e,t);return"readable"===e&&n.nextTick(R,this),r},S.prototype.removeAllListeners=function(e){var t=o.prototype.removeAllListeners.apply(this,arguments);return"readable"!==e&&void 0!==e||n.nextTick(R,this),t},S.prototype.resume=function(){var e=this._readableState;return e.flowing||(f("resume"),e.flowing=!e.readableListening,function(e,t){t.resumeScheduled||(t.resumeScheduled=!0,n.nextTick(B,e,t))}(this,e)),e.paused=!1,this},S.prototype.pause=function(){return f("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(f("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},S.prototype.wrap=function(e){var t=this,r=this._readableState,n=!1;for(var a in e.on("end",(function(){if(f("wrapped end"),r.decoder&&!r.ended){var e=r.decoder.end();e&&e.length&&t.push(e)}t.push(null)})),e.on("data",(function(a){(f("wrapped data"),r.decoder&&(a=r.decoder.write(a)),!r.objectMode||null!==a&&void 0!==a)&&((r.objectMode||a&&a.length)&&(t.push(a)||(n=!0,e.pause())))})),e)void 0===this[a]&&"function"===typeof e[a]&&(this[a]=function(t){return function(){return e[t].apply(e,arguments)}}(a));for(var i=0;i<_.length;i++)e.on(_[i],this.emit.bind(this,_[i]));return this._read=function(t){f("wrapped _read",t),n&&(n=!1,e.resume())},this},"function"===typeof Symbol&&(S.prototype[Symbol.asyncIterator]=function(){return void 0===l&&(l=r(664)),l(this)}),Object.defineProperty(S.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),Object.defineProperty(S.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}}),Object.defineProperty(S.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(e){this._readableState&&(this._readableState.flowing=e)}}),S._fromList=I,Object.defineProperty(S.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}}),"function"===typeof Symbol&&(S.from=function(e,t){return void 0===b&&(b=r(665)),b(S,e,t)})}).call(this,r(44),r(48))},function(e,t,r){e.exports=r(91).EventEmitter},function(e,t,r){"use strict";(function(t){function r(e,t){a(e,t),n(e)}function n(e){e._writableState&&!e._writableState.emitClose||e._readableState&&!e._readableState.emitClose||e.emit("close")}function a(e,t){e.emit("error",t)}e.exports={destroy:function(e,i){var o=this,c=this._readableState&&this._readableState.destroyed,s=this._writableState&&this._writableState.destroyed;return c||s?(i?i(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,t.nextTick(a,this,e)):t.nextTick(a,this,e)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,(function(e){!i&&e?o._writableState?o._writableState.errorEmitted?t.nextTick(n,o):(o._writableState.errorEmitted=!0,t.nextTick(r,o,e)):t.nextTick(r,o,e):i?(t.nextTick(n,o),i(e)):t.nextTick(n,o)})),this)},undestroy:function(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)},errorOrDestroy:function(e,t){var r=e._readableState,n=e._writableState;r&&r.autoDestroy||n&&n.autoDestroy?e.destroy(t):e.emit("error",t)}}}).call(this,r(48))},function(e,t,r){"use strict";var n=r(168).codes.ERR_INVALID_OPT_VALUE;e.exports={getHighWaterMark:function(e,t,r,a){var i=function(e,t,r){return null!=e.highWaterMark?e.highWaterMark:t?e[r]:null}(t,a,r);if(null!=i){if(!isFinite(i)||Math.floor(i)!==i||i<0)throw new n(a?r:"highWaterMark",i);return Math.floor(i)}return e.objectMode?16:16384}}},function(e,t,r){"use strict";(function(t,n){function a(e){var t=this;this.next=null,this.entry=null,this.finish=function(){!function(e,t,r){var n=e.entry;e.entry=null;for(;n;){var a=n.callback;t.pendingcb--,a(r),n=n.next}t.corkedRequestsFree.next=e}(t,e)}}var i;e.exports=S,S.WritableState=M;var o={deprecate:r(239)},c=r(408),s=r(30).Buffer,f=t.Uint8Array||function(){};var d,u=r(409),l=r(410).getHighWaterMark,b=r(168).codes,h=b.ERR_INVALID_ARG_TYPE,p=b.ERR_METHOD_NOT_IMPLEMENTED,m=b.ERR_MULTIPLE_CALLBACK,v=b.ERR_STREAM_CANNOT_PIPE,g=b.ERR_STREAM_DESTROYED,x=b.ERR_STREAM_NULL_VALUES,y=b.ERR_STREAM_WRITE_AFTER_END,w=b.ERR_UNKNOWN_ENCODING,k=u.errorOrDestroy;function _(){}function M(e,t,o){i=i||r(169),e=e||{},"boolean"!==typeof o&&(o=t instanceof i),this.objectMode=!!e.objectMode,o&&(this.objectMode=this.objectMode||!!e.writableObjectMode),this.highWaterMark=l(this,e,"writableHighWaterMark",o),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var c=!1===e.decodeStrings;this.decodeStrings=!c,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){!function(e,t){var r=e._writableState,a=r.sync,i=r.writecb;if("function"!==typeof i)throw new m;if(function(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}(r),t)!function(e,t,r,a,i){--t.pendingcb,r?(n.nextTick(i,a),n.nextTick(P,e,t),e._writableState.errorEmitted=!0,k(e,a)):(i(a),e._writableState.errorEmitted=!0,k(e,a),P(e,t))}(e,r,a,t,i);else{var o=T(r)||e.destroyed;o||r.corked||r.bufferProcessing||!r.bufferedRequest||A(e,r),a?n.nextTick(O,e,r,o,i):O(e,r,o,i)}}(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new a(this)}function S(e){var t=this instanceof(i=i||r(169));if(!t&&!d.call(S,this))return new S(e);this._writableState=new M(e,this,t),this.writable=!0,e&&("function"===typeof e.write&&(this._write=e.write),"function"===typeof e.writev&&(this._writev=e.writev),"function"===typeof e.destroy&&(this._destroy=e.destroy),"function"===typeof e.final&&(this._final=e.final)),c.call(this)}function E(e,t,r,n,a,i,o){t.writelen=n,t.writecb=o,t.writing=!0,t.sync=!0,t.destroyed?t.onwrite(new g("write")):r?e._writev(a,t.onwrite):e._write(a,i,t.onwrite),t.sync=!1}function O(e,t,r,n){r||function(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}(e,t),t.pendingcb--,n(),P(e,t)}function A(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var n=t.bufferedRequestCount,i=new Array(n),o=t.corkedRequestsFree;o.entry=r;for(var c=0,s=!0;r;)i[c]=r,r.isBuf||(s=!1),r=r.next,c+=1;i.allBuffers=s,E(e,t,!0,t.length,i,"",o.finish),t.pendingcb++,t.lastBufferedRequest=null,o.next?(t.corkedRequestsFree=o.next,o.next=null):t.corkedRequestsFree=new a(t),t.bufferedRequestCount=0}else{for(;r;){var f=r.chunk,d=r.encoding,u=r.callback;if(E(e,t,!1,t.objectMode?1:f.length,f,d,u),r=r.next,t.bufferedRequestCount--,t.writing)break}null===r&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}function T(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function j(e,t){e._final((function(r){t.pendingcb--,r&&k(e,r),t.prefinished=!0,e.emit("prefinish"),P(e,t)}))}function P(e,t){var r=T(t);if(r&&(function(e,t){t.prefinished||t.finalCalled||("function"!==typeof e._final||t.destroyed?(t.prefinished=!0,e.emit("prefinish")):(t.pendingcb++,t.finalCalled=!0,n.nextTick(j,e,t)))}(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"),t.autoDestroy))){var a=e._readableState;(!a||a.autoDestroy&&a.endEmitted)&&e.destroy()}return r}r(33)(S,c),M.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t},function(){try{Object.defineProperty(M.prototype,"buffer",{get:o.deprecate((function(){return this.getBuffer()}),"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"===typeof Symbol&&Symbol.hasInstance&&"function"===typeof Function.prototype[Symbol.hasInstance]?(d=Function.prototype[Symbol.hasInstance],Object.defineProperty(S,Symbol.hasInstance,{value:function(e){return!!d.call(this,e)||this===S&&(e&&e._writableState instanceof M)}})):d=function(e){return e instanceof this},S.prototype.pipe=function(){k(this,new v)},S.prototype.write=function(e,t,r){var a,i=this._writableState,o=!1,c=!i.objectMode&&(a=e,s.isBuffer(a)||a instanceof f);return c&&!s.isBuffer(e)&&(e=function(e){return s.from(e)}(e)),"function"===typeof t&&(r=t,t=null),c?t="buffer":t||(t=i.defaultEncoding),"function"!==typeof r&&(r=_),i.ending?function(e,t){var r=new y;k(e,r),n.nextTick(t,r)}(this,r):(c||function(e,t,r,a){var i;return null===r?i=new x:"string"===typeof r||t.objectMode||(i=new h("chunk",["string","Buffer"],r)),!i||(k(e,i),n.nextTick(a,i),!1)}(this,i,e,r))&&(i.pendingcb++,o=function(e,t,r,n,a,i){if(!r){var o=function(e,t,r){e.objectMode||!1===e.decodeStrings||"string"!==typeof t||(t=s.from(t,r));return t}(t,n,a);n!==o&&(r=!0,a="buffer",n=o)}var c=t.objectMode?1:n.length;t.length+=c;var f=t.length-1))throw new w(e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(S.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(S.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),S.prototype._write=function(e,t,r){r(new p("_write()"))},S.prototype._writev=null,S.prototype.end=function(e,t,r){var a=this._writableState;return"function"===typeof e?(r=e,e=null,t=null):"function"===typeof t&&(r=t,t=null),null!==e&&void 0!==e&&this.write(e,t),a.corked&&(a.corked=1,this.uncork()),a.ending||function(e,t,r){t.ending=!0,P(e,t),r&&(t.finished?n.nextTick(r):e.once("finish",r));t.ended=!0,e.writable=!1}(this,a,r),this},Object.defineProperty(S.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(S.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),S.prototype.destroy=u.destroy,S.prototype._undestroy=u.undestroy,S.prototype._destroy=function(e,t){t(e)}}).call(this,r(44),r(48))},function(e,t,r){"use strict";e.exports=d;var n=r(168).codes,a=n.ERR_METHOD_NOT_IMPLEMENTED,i=n.ERR_MULTIPLE_CALLBACK,o=n.ERR_TRANSFORM_ALREADY_TRANSFORMING,c=n.ERR_TRANSFORM_WITH_LENGTH_0,s=r(169);function f(e,t){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(null===n)return this.emit("error",new i);r.writechunk=null,r.writecb=null,null!=t&&this.push(t),n(e);var a=this._readableState;a.reading=!1,(a.needReadable||a.length=this._blockSize;){for(var i=this._blockOffset;i0;++o)this._length[o]+=c,(c=this._length[o]/4294967296|0)>0&&(this._length[o]-=4294967296*c);return this},i.prototype._update=function(){throw new Error("_update is not implemented")},i.prototype.digest=function(e){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var t=this._digest();void 0!==e&&(t=t.toString(e)),this._block.fill(0),this._blockOffset=0;for(var r=0;r<4;++r)this._length[r]=0;return t},i.prototype._digest=function(){throw new Error("_digest is not implemented")},e.exports=i},function(e,t,r){"use strict";(function(t,n){var a;e.exports=S,S.ReadableState=M;r(91).EventEmitter;var i=function(e,t){return e.listeners(t).length},o=r(415),c=r(30).Buffer,s=t.Uint8Array||function(){};var f,d=r(672);f=d&&d.debuglog?d.debuglog("stream"):function(){};var u,l,b,h=r(673),p=r(416),m=r(417).getHighWaterMark,v=r(170).codes,g=v.ERR_INVALID_ARG_TYPE,x=v.ERR_STREAM_PUSH_AFTER_EOF,y=v.ERR_METHOD_NOT_IMPLEMENTED,w=v.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;r(33)(S,o);var k=p.errorOrDestroy,_=["error","close","destroy","pause","resume"];function M(e,t,n){a=a||r(171),e=e||{},"boolean"!==typeof n&&(n=t instanceof a),this.objectMode=!!e.objectMode,n&&(this.objectMode=this.objectMode||!!e.readableObjectMode),this.highWaterMark=m(this,e,"readableHighWaterMark",n),this.buffer=new h,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(u||(u=r(119).StringDecoder),this.decoder=new u(e.encoding),this.encoding=e.encoding)}function S(e){if(a=a||r(171),!(this instanceof S))return new S(e);var t=this instanceof a;this._readableState=new M(e,this,t),this.readable=!0,e&&("function"===typeof e.read&&(this._read=e.read),"function"===typeof e.destroy&&(this._destroy=e.destroy)),o.call(this)}function E(e,t,r,n,a){f("readableAddChunk",t);var i,o=e._readableState;if(null===t)o.reading=!1,function(e,t){if(f("onEofChunk"),t.ended)return;if(t.decoder){var r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,t.sync?T(e):(t.needReadable=!1,t.emittedReadable||(t.emittedReadable=!0,j(e)))}(e,o);else if(a||(i=function(e,t){var r;n=t,c.isBuffer(n)||n instanceof s||"string"===typeof t||void 0===t||e.objectMode||(r=new g("chunk",["string","Buffer","Uint8Array"],t));var n;return r}(o,t)),i)k(e,i);else if(o.objectMode||t&&t.length>0)if("string"===typeof t||o.objectMode||Object.getPrototypeOf(t)===c.prototype||(t=function(e){return c.from(e)}(t)),n)o.endEmitted?k(e,new w):O(e,o,t,!0);else if(o.ended)k(e,new x);else{if(o.destroyed)return!1;o.reading=!1,o.decoder&&!r?(t=o.decoder.write(t),o.objectMode||0!==t.length?O(e,o,t,!1):P(e,o)):O(e,o,t,!1)}else n||(o.reading=!1,P(e,o));return!o.ended&&(o.lengtht.highWaterMark&&(t.highWaterMark=function(e){return e>=1073741824?e=1073741824:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function T(e){var t=e._readableState;f("emitReadable",t.needReadable,t.emittedReadable),t.needReadable=!1,t.emittedReadable||(f("emitReadable",t.flowing),t.emittedReadable=!0,n.nextTick(j,e))}function j(e){var t=e._readableState;f("emitReadable_",t.destroyed,t.length,t.ended),t.destroyed||!t.length&&!t.ended||(e.emit("readable"),t.emittedReadable=!1),t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark,L(e)}function P(e,t){t.readingMore||(t.readingMore=!0,n.nextTick(C,e,t))}function C(e,t){for(;!t.reading&&!t.ended&&(t.length0,t.resumeScheduled&&!t.paused?t.flowing=!0:e.listenerCount("data")>0&&e.resume()}function N(e){f("readable nexttick read 0"),e.read(0)}function B(e,t){f("resume",t.reading),t.reading||e.read(0),t.resumeScheduled=!1,e.emit("resume"),L(e),t.flowing&&!t.reading&&e.read(0)}function L(e){var t=e._readableState;for(f("flow",t.flowing);t.flowing&&null!==e.read(););}function I(e,t){return 0===t.length?null:(t.objectMode?r=t.buffer.shift():!e||e>=t.length?(r=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.first():t.buffer.concat(t.length),t.buffer.clear()):r=t.buffer.consume(e,t.decoder),r);var r}function F(e){var t=e._readableState;f("endReadable",t.endEmitted),t.endEmitted||(t.ended=!0,n.nextTick(D,t,e))}function D(e,t){if(f("endReadableNT",e.endEmitted,e.length),!e.endEmitted&&0===e.length&&(e.endEmitted=!0,t.readable=!1,t.emit("end"),e.autoDestroy)){var r=t._writableState;(!r||r.autoDestroy&&r.finished)&&t.destroy()}}function U(e,t){for(var r=0,n=e.length;r=t.highWaterMark:t.length>0)||t.ended))return f("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?F(this):T(this),null;if(0===(e=A(e,t))&&t.ended)return 0===t.length&&F(this),null;var n,a=t.needReadable;return f("need readable",a),(0===t.length||t.length-e0?I(e,t):null)?(t.needReadable=t.length<=t.highWaterMark,e=0):(t.length-=e,t.awaitDrain=0),0===t.length&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&F(this)),null!==n&&this.emit("data",n),n},S.prototype._read=function(e){k(this,new y("_read()"))},S.prototype.pipe=function(e,t){var r=this,a=this._readableState;switch(a.pipesCount){case 0:a.pipes=e;break;case 1:a.pipes=[a.pipes,e];break;default:a.pipes.push(e)}a.pipesCount+=1,f("pipe count=%d opts=%j",a.pipesCount,t);var o=(!t||!1!==t.end)&&e!==n.stdout&&e!==n.stderr?s:m;function c(t,n){f("onunpipe"),t===r&&n&&!1===n.hasUnpiped&&(n.hasUnpiped=!0,f("cleanup"),e.removeListener("close",h),e.removeListener("finish",p),e.removeListener("drain",d),e.removeListener("error",b),e.removeListener("unpipe",c),r.removeListener("end",s),r.removeListener("end",m),r.removeListener("data",l),u=!0,!a.awaitDrain||e._writableState&&!e._writableState.needDrain||d())}function s(){f("onend"),e.end()}a.endEmitted?n.nextTick(o):r.once("end",o),e.on("unpipe",c);var d=function(e){return function(){var t=e._readableState;f("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&i(e,"data")&&(t.flowing=!0,L(e))}}(r);e.on("drain",d);var u=!1;function l(t){f("ondata");var n=e.write(t);f("dest.write",n),!1===n&&((1===a.pipesCount&&a.pipes===e||a.pipesCount>1&&-1!==U(a.pipes,e))&&!u&&(f("false write response, pause",a.awaitDrain),a.awaitDrain++),r.pause())}function b(t){f("onerror",t),m(),e.removeListener("error",b),0===i(e,"error")&&k(e,t)}function h(){e.removeListener("finish",p),m()}function p(){f("onfinish"),e.removeListener("close",h),m()}function m(){f("unpipe"),r.unpipe(e)}return r.on("data",l),function(e,t,r){if("function"===typeof e.prependListener)return e.prependListener(t,r);e._events&&e._events[t]?Array.isArray(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]:e.on(t,r)}(e,"error",b),e.once("close",h),e.once("finish",p),e.emit("pipe",r),a.flowing||(f("pipe resume"),r.resume()),e},S.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes||(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r)),this;if(!e){var n=t.pipes,a=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var i=0;i0,!1!==a.flowing&&this.resume()):"readable"===e&&(a.endEmitted||a.readableListening||(a.readableListening=a.needReadable=!0,a.flowing=!1,a.emittedReadable=!1,f("on readable",a.length,a.reading),a.length?T(this):a.reading||n.nextTick(N,this))),r},S.prototype.addListener=S.prototype.on,S.prototype.removeListener=function(e,t){var r=o.prototype.removeListener.call(this,e,t);return"readable"===e&&n.nextTick(R,this),r},S.prototype.removeAllListeners=function(e){var t=o.prototype.removeAllListeners.apply(this,arguments);return"readable"!==e&&void 0!==e||n.nextTick(R,this),t},S.prototype.resume=function(){var e=this._readableState;return e.flowing||(f("resume"),e.flowing=!e.readableListening,function(e,t){t.resumeScheduled||(t.resumeScheduled=!0,n.nextTick(B,e,t))}(this,e)),e.paused=!1,this},S.prototype.pause=function(){return f("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(f("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},S.prototype.wrap=function(e){var t=this,r=this._readableState,n=!1;for(var a in e.on("end",(function(){if(f("wrapped end"),r.decoder&&!r.ended){var e=r.decoder.end();e&&e.length&&t.push(e)}t.push(null)})),e.on("data",(function(a){(f("wrapped data"),r.decoder&&(a=r.decoder.write(a)),!r.objectMode||null!==a&&void 0!==a)&&((r.objectMode||a&&a.length)&&(t.push(a)||(n=!0,e.pause())))})),e)void 0===this[a]&&"function"===typeof e[a]&&(this[a]=function(t){return function(){return e[t].apply(e,arguments)}}(a));for(var i=0;i<_.length;i++)e.on(_[i],this.emit.bind(this,_[i]));return this._read=function(t){f("wrapped _read",t),n&&(n=!1,e.resume())},this},"function"===typeof Symbol&&(S.prototype[Symbol.asyncIterator]=function(){return void 0===l&&(l=r(675)),l(this)}),Object.defineProperty(S.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),Object.defineProperty(S.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}}),Object.defineProperty(S.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(e){this._readableState&&(this._readableState.flowing=e)}}),S._fromList=I,Object.defineProperty(S.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}}),"function"===typeof Symbol&&(S.from=function(e,t){return void 0===b&&(b=r(676)),b(S,e,t)})}).call(this,r(44),r(48))},function(e,t,r){e.exports=r(91).EventEmitter},function(e,t,r){"use strict";(function(t){function r(e,t){a(e,t),n(e)}function n(e){e._writableState&&!e._writableState.emitClose||e._readableState&&!e._readableState.emitClose||e.emit("close")}function a(e,t){e.emit("error",t)}e.exports={destroy:function(e,i){var o=this,c=this._readableState&&this._readableState.destroyed,s=this._writableState&&this._writableState.destroyed;return c||s?(i?i(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,t.nextTick(a,this,e)):t.nextTick(a,this,e)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,(function(e){!i&&e?o._writableState?o._writableState.errorEmitted?t.nextTick(n,o):(o._writableState.errorEmitted=!0,t.nextTick(r,o,e)):t.nextTick(r,o,e):i?(t.nextTick(n,o),i(e)):t.nextTick(n,o)})),this)},undestroy:function(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)},errorOrDestroy:function(e,t){var r=e._readableState,n=e._writableState;r&&r.autoDestroy||n&&n.autoDestroy?e.destroy(t):e.emit("error",t)}}}).call(this,r(48))},function(e,t,r){"use strict";var n=r(170).codes.ERR_INVALID_OPT_VALUE;e.exports={getHighWaterMark:function(e,t,r,a){var i=function(e,t,r){return null!=e.highWaterMark?e.highWaterMark:t?e[r]:null}(t,a,r);if(null!=i){if(!isFinite(i)||Math.floor(i)!==i||i<0)throw new n(a?r:"highWaterMark",i);return Math.floor(i)}return e.objectMode?16:16384}}},function(e,t,r){"use strict";(function(t,n){function a(e){var t=this;this.next=null,this.entry=null,this.finish=function(){!function(e,t,r){var n=e.entry;e.entry=null;for(;n;){var a=n.callback;t.pendingcb--,a(r),n=n.next}t.corkedRequestsFree.next=e}(t,e)}}var i;e.exports=S,S.WritableState=M;var o={deprecate:r(239)},c=r(415),s=r(30).Buffer,f=t.Uint8Array||function(){};var d,u=r(416),l=r(417).getHighWaterMark,b=r(170).codes,h=b.ERR_INVALID_ARG_TYPE,p=b.ERR_METHOD_NOT_IMPLEMENTED,m=b.ERR_MULTIPLE_CALLBACK,v=b.ERR_STREAM_CANNOT_PIPE,g=b.ERR_STREAM_DESTROYED,x=b.ERR_STREAM_NULL_VALUES,y=b.ERR_STREAM_WRITE_AFTER_END,w=b.ERR_UNKNOWN_ENCODING,k=u.errorOrDestroy;function _(){}function M(e,t,o){i=i||r(171),e=e||{},"boolean"!==typeof o&&(o=t instanceof i),this.objectMode=!!e.objectMode,o&&(this.objectMode=this.objectMode||!!e.writableObjectMode),this.highWaterMark=l(this,e,"writableHighWaterMark",o),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var c=!1===e.decodeStrings;this.decodeStrings=!c,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){!function(e,t){var r=e._writableState,a=r.sync,i=r.writecb;if("function"!==typeof i)throw new m;if(function(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}(r),t)!function(e,t,r,a,i){--t.pendingcb,r?(n.nextTick(i,a),n.nextTick(P,e,t),e._writableState.errorEmitted=!0,k(e,a)):(i(a),e._writableState.errorEmitted=!0,k(e,a),P(e,t))}(e,r,a,t,i);else{var o=T(r)||e.destroyed;o||r.corked||r.bufferProcessing||!r.bufferedRequest||A(e,r),a?n.nextTick(O,e,r,o,i):O(e,r,o,i)}}(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new a(this)}function S(e){var t=this instanceof(i=i||r(171));if(!t&&!d.call(S,this))return new S(e);this._writableState=new M(e,this,t),this.writable=!0,e&&("function"===typeof e.write&&(this._write=e.write),"function"===typeof e.writev&&(this._writev=e.writev),"function"===typeof e.destroy&&(this._destroy=e.destroy),"function"===typeof e.final&&(this._final=e.final)),c.call(this)}function E(e,t,r,n,a,i,o){t.writelen=n,t.writecb=o,t.writing=!0,t.sync=!0,t.destroyed?t.onwrite(new g("write")):r?e._writev(a,t.onwrite):e._write(a,i,t.onwrite),t.sync=!1}function O(e,t,r,n){r||function(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}(e,t),t.pendingcb--,n(),P(e,t)}function A(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var n=t.bufferedRequestCount,i=new Array(n),o=t.corkedRequestsFree;o.entry=r;for(var c=0,s=!0;r;)i[c]=r,r.isBuf||(s=!1),r=r.next,c+=1;i.allBuffers=s,E(e,t,!0,t.length,i,"",o.finish),t.pendingcb++,t.lastBufferedRequest=null,o.next?(t.corkedRequestsFree=o.next,o.next=null):t.corkedRequestsFree=new a(t),t.bufferedRequestCount=0}else{for(;r;){var f=r.chunk,d=r.encoding,u=r.callback;if(E(e,t,!1,t.objectMode?1:f.length,f,d,u),r=r.next,t.bufferedRequestCount--,t.writing)break}null===r&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}function T(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function j(e,t){e._final((function(r){t.pendingcb--,r&&k(e,r),t.prefinished=!0,e.emit("prefinish"),P(e,t)}))}function P(e,t){var r=T(t);if(r&&(function(e,t){t.prefinished||t.finalCalled||("function"!==typeof e._final||t.destroyed?(t.prefinished=!0,e.emit("prefinish")):(t.pendingcb++,t.finalCalled=!0,n.nextTick(j,e,t)))}(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"),t.autoDestroy))){var a=e._readableState;(!a||a.autoDestroy&&a.endEmitted)&&e.destroy()}return r}r(33)(S,c),M.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t},function(){try{Object.defineProperty(M.prototype,"buffer",{get:o.deprecate((function(){return this.getBuffer()}),"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"===typeof Symbol&&Symbol.hasInstance&&"function"===typeof Function.prototype[Symbol.hasInstance]?(d=Function.prototype[Symbol.hasInstance],Object.defineProperty(S,Symbol.hasInstance,{value:function(e){return!!d.call(this,e)||this===S&&(e&&e._writableState instanceof M)}})):d=function(e){return e instanceof this},S.prototype.pipe=function(){k(this,new v)},S.prototype.write=function(e,t,r){var a,i=this._writableState,o=!1,c=!i.objectMode&&(a=e,s.isBuffer(a)||a instanceof f);return c&&!s.isBuffer(e)&&(e=function(e){return s.from(e)}(e)),"function"===typeof t&&(r=t,t=null),c?t="buffer":t||(t=i.defaultEncoding),"function"!==typeof r&&(r=_),i.ending?function(e,t){var r=new y;k(e,r),n.nextTick(t,r)}(this,r):(c||function(e,t,r,a){var i;return null===r?i=new x:"string"===typeof r||t.objectMode||(i=new h("chunk",["string","Buffer"],r)),!i||(k(e,i),n.nextTick(a,i),!1)}(this,i,e,r))&&(i.pendingcb++,o=function(e,t,r,n,a,i){if(!r){var o=function(e,t,r){e.objectMode||!1===e.decodeStrings||"string"!==typeof t||(t=s.from(t,r));return t}(t,n,a);n!==o&&(r=!0,a="buffer",n=o)}var c=t.objectMode?1:n.length;t.length+=c;var f=t.length-1))throw new w(e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(S.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(S.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),S.prototype._write=function(e,t,r){r(new p("_write()"))},S.prototype._writev=null,S.prototype.end=function(e,t,r){var a=this._writableState;return"function"===typeof e?(r=e,e=null,t=null):"function"===typeof t&&(r=t,t=null),null!==e&&void 0!==e&&this.write(e,t),a.corked&&(a.corked=1,this.uncork()),a.ending||function(e,t,r){t.ending=!0,P(e,t),r&&(t.finished?n.nextTick(r):e.once("finish",r));t.ended=!0,e.writable=!1}(this,a,r),this},Object.defineProperty(S.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(S.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),S.prototype.destroy=u.destroy,S.prototype._undestroy=u.undestroy,S.prototype._destroy=function(e,t){t(e)}}).call(this,r(44),r(48))},function(e,t,r){"use strict";e.exports=d;var n=r(170).codes,a=n.ERR_METHOD_NOT_IMPLEMENTED,i=n.ERR_MULTIPLE_CALLBACK,o=n.ERR_TRANSFORM_ALREADY_TRANSFORMING,c=n.ERR_TRANSFORM_WITH_LENGTH_0,s=r(171);function f(e,t){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(null===n)return this.emit("error",new i);r.writechunk=null,r.writecb=null,null!=t&&this.push(t),n(e);var a=this._readableState;a.reading=!1,(a.needReadable||a.length>>2|e<<30)^(e>>>13|e<<19)^(e>>>22|e<<10)}function l(e){return(e>>>6|e<<26)^(e>>>11|e<<21)^(e>>>25|e<<7)}function b(e){return(e>>>7|e<<25)^(e>>>18|e<<14)^e>>>3}n(s,a),s.prototype.init=function(){return this._a=1779033703,this._b=3144134277,this._c=1013904242,this._d=2773480762,this._e=1359893119,this._f=2600822924,this._g=528734635,this._h=1541459225,this},s.prototype._update=function(e){for(var t,r=this._w,n=0|this._a,a=0|this._b,i=0|this._c,c=0|this._d,s=0|this._e,h=0|this._f,p=0|this._g,m=0|this._h,v=0;v<16;++v)r[v]=e.readInt32BE(4*v);for(;v<64;++v)r[v]=0|(((t=r[v-2])>>>17|t<<15)^(t>>>19|t<<13)^t>>>10)+r[v-7]+b(r[v-15])+r[v-16];for(var g=0;g<64;++g){var x=m+l(s)+f(s,h,p)+o[g]+r[g]|0,y=u(n)+d(n,a,i)|0;m=p,p=h,h=s,s=c+x|0,c=i,i=a,a=n,n=x+y|0}this._a=n+this._a|0,this._b=a+this._b|0,this._c=i+this._c|0,this._d=c+this._d|0,this._e=s+this._e|0,this._f=h+this._f|0,this._g=p+this._g|0,this._h=m+this._h|0},s.prototype._hash=function(){var e=i.allocUnsafe(32);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e.writeInt32BE(this._h,28),e},e.exports=s},function(e,t,r){var n=r(33),a=r(172),i=r(42).Buffer,o=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],c=new Array(160);function s(){this.init(),this._w=c,a.call(this,128,112)}function f(e,t,r){return r^e&(t^r)}function d(e,t,r){return e&t|r&(e|t)}function u(e,t){return(e>>>28|t<<4)^(t>>>2|e<<30)^(t>>>7|e<<25)}function l(e,t){return(e>>>14|t<<18)^(e>>>18|t<<14)^(t>>>9|e<<23)}function b(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^e>>>7}function h(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^(e>>>7|t<<25)}function p(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^e>>>6}function m(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^(e>>>6|t<<26)}function v(e,t){return e>>>0>>0?1:0}n(s,a),s.prototype.init=function(){return this._ah=1779033703,this._bh=3144134277,this._ch=1013904242,this._dh=2773480762,this._eh=1359893119,this._fh=2600822924,this._gh=528734635,this._hh=1541459225,this._al=4089235720,this._bl=2227873595,this._cl=4271175723,this._dl=1595750129,this._el=2917565137,this._fl=725511199,this._gl=4215389547,this._hl=327033209,this},s.prototype._update=function(e){for(var t=this._w,r=0|this._ah,n=0|this._bh,a=0|this._ch,i=0|this._dh,c=0|this._eh,s=0|this._fh,g=0|this._gh,x=0|this._hh,y=0|this._al,w=0|this._bl,k=0|this._cl,_=0|this._dl,M=0|this._el,S=0|this._fl,E=0|this._gl,O=0|this._hl,A=0;A<32;A+=2)t[A]=e.readInt32BE(4*A),t[A+1]=e.readInt32BE(4*A+4);for(;A<160;A+=2){var T=t[A-30],j=t[A-30+1],P=b(T,j),C=h(j,T),R=p(T=t[A-4],j=t[A-4+1]),N=m(j,T),B=t[A-14],L=t[A-14+1],I=t[A-32],F=t[A-32+1],D=C+L|0,U=P+B+v(D,C)|0;U=(U=U+R+v(D=D+N|0,N)|0)+I+v(D=D+F|0,F)|0,t[A]=U,t[A+1]=D}for(var z=0;z<160;z+=2){U=t[z],D=t[z+1];var H=d(r,n,a),q=d(y,w,k),J=u(r,y),V=u(y,r),G=l(c,M),X=l(M,c),K=o[z],W=o[z+1],Z=f(c,s,g),$=f(M,S,E),Q=O+X|0,Y=x+G+v(Q,O)|0;Y=(Y=(Y=Y+Z+v(Q=Q+$|0,$)|0)+K+v(Q=Q+W|0,W)|0)+U+v(Q=Q+D|0,D)|0;var ee=V+q|0,te=J+H+v(ee,V)|0;x=g,O=E,g=s,E=S,s=c,S=M,c=i+Y+v(M=_+Q|0,_)|0,i=a,_=k,a=n,k=w,n=r,w=y,r=Y+te+v(y=Q+ee|0,Q)|0}this._al=this._al+y|0,this._bl=this._bl+w|0,this._cl=this._cl+k|0,this._dl=this._dl+_|0,this._el=this._el+M|0,this._fl=this._fl+S|0,this._gl=this._gl+E|0,this._hl=this._hl+O|0,this._ah=this._ah+r+v(this._al,y)|0,this._bh=this._bh+n+v(this._bl,w)|0,this._ch=this._ch+a+v(this._cl,k)|0,this._dh=this._dh+i+v(this._dl,_)|0,this._eh=this._eh+c+v(this._el,M)|0,this._fh=this._fh+s+v(this._fl,S)|0,this._gh=this._gh+g+v(this._gl,E)|0,this._hh=this._hh+x+v(this._hl,O)|0},s.prototype._hash=function(){var e=i.allocUnsafe(64);function t(t,r,n){e.writeInt32BE(t,n),e.writeInt32BE(r,n+4)}return t(this._ah,this._al,0),t(this._bh,this._bl,8),t(this._ch,this._cl,16),t(this._dh,this._dl,24),t(this._eh,this._el,32),t(this._fh,this._fl,40),t(this._gh,this._gl,48),t(this._hh,this._hl,56),e},e.exports=s},function(e,t,r){"use strict";(function(t,n){var a=r(240);e.exports=x;var i,o=r(684);x.ReadableState=g;r(91).EventEmitter;var c=function(e,t){return e.listeners(t).length},s=r(423),f=r(308).Buffer,d=t.Uint8Array||function(){};var u=Object.create(r(200));u.inherits=r(33);var l=r(685),b=void 0;b=l&&l.debuglog?l.debuglog("stream"):function(){};var h,p=r(686),m=r(424);u.inherits(x,s);var v=["error","close","destroy","pause","resume"];function g(e,t){e=e||{};var n=t instanceof(i=i||r(152));this.objectMode=!!e.objectMode,n&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var a=e.highWaterMark,o=e.readableHighWaterMark,c=this.objectMode?16:16384;this.highWaterMark=a||0===a?a:n&&(o||0===o)?o:c,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new p,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(h||(h=r(119).StringDecoder),this.decoder=new h(e.encoding),this.encoding=e.encoding)}function x(e){if(i=i||r(152),!(this instanceof x))return new x(e);this._readableState=new g(e,this),this.readable=!0,e&&("function"===typeof e.read&&(this._read=e.read),"function"===typeof e.destroy&&(this._destroy=e.destroy)),s.call(this)}function y(e,t,r,n,a){var i,o=e._readableState;null===t?(o.reading=!1,function(e,t){if(t.ended)return;if(t.decoder){var r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,_(e)}(e,o)):(a||(i=function(e,t){var r;n=t,f.isBuffer(n)||n instanceof d||"string"===typeof t||void 0===t||e.objectMode||(r=new TypeError("Invalid non-string/buffer chunk"));var n;return r}(o,t)),i?e.emit("error",i):o.objectMode||t&&t.length>0?("string"===typeof t||o.objectMode||Object.getPrototypeOf(t)===f.prototype||(t=function(e){return f.from(e)}(t)),n?o.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):w(e,o,t,!0):o.ended?e.emit("error",new Error("stream.push() after EOF")):(o.reading=!1,o.decoder&&!r?(t=o.decoder.write(t),o.objectMode||0!==t.length?w(e,o,t,!1):S(e,o)):w(e,o,t,!1))):n||(o.reading=!1));return function(e){return!e.ended&&(e.needReadable||e.lengtht.highWaterMark&&(t.highWaterMark=function(e){return e>=8388608?e=8388608:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function _(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(b("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?a.nextTick(M,e):M(e))}function M(e){b("emit readable"),e.emit("readable"),T(e)}function S(e,t){t.readingMore||(t.readingMore=!0,a.nextTick(E,e,t))}function E(e,t){for(var r=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length=t.length?(r=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):r=function(e,t,r){var n;ei.length?i.length:e;if(o===i.length?a+=i:a+=i.slice(0,e),0===(e-=o)){o===i.length?(++n,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=i.slice(o));break}++n}return t.length-=n,a}(e,t):function(e,t){var r=f.allocUnsafe(e),n=t.head,a=1;n.data.copy(r),e-=n.data.length;for(;n=n.next;){var i=n.data,o=e>i.length?i.length:e;if(i.copy(r,r.length-e,0,o),0===(e-=o)){o===i.length?(++a,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=i.slice(o));break}++a}return t.length-=a,r}(e,t);return n}(e,t.buffer,t.decoder),r);var r}function P(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,a.nextTick(C,t,e))}function C(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function R(e,t){for(var r=0,n=e.length;r=t.highWaterMark||t.ended))return b("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?P(this):_(this),null;if(0===(e=k(e,t))&&t.ended)return 0===t.length&&P(this),null;var n,a=t.needReadable;return b("need readable",a),(0===t.length||t.length-e0?j(e,t):null)?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&P(this)),null!==n&&this.emit("data",n),n},x.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},x.prototype.pipe=function(e,t){var r=this,i=this._readableState;switch(i.pipesCount){case 0:i.pipes=e;break;case 1:i.pipes=[i.pipes,e];break;default:i.pipes.push(e)}i.pipesCount+=1,b("pipe count=%d opts=%j",i.pipesCount,t);var s=(!t||!1!==t.end)&&e!==n.stdout&&e!==n.stderr?d:x;function f(t,n){b("onunpipe"),t===r&&n&&!1===n.hasUnpiped&&(n.hasUnpiped=!0,b("cleanup"),e.removeListener("close",v),e.removeListener("finish",g),e.removeListener("drain",u),e.removeListener("error",m),e.removeListener("unpipe",f),r.removeListener("end",d),r.removeListener("end",x),r.removeListener("data",p),l=!0,!i.awaitDrain||e._writableState&&!e._writableState.needDrain||u())}function d(){b("onend"),e.end()}i.endEmitted?a.nextTick(s):r.once("end",s),e.on("unpipe",f);var u=function(e){return function(){var t=e._readableState;b("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&c(e,"data")&&(t.flowing=!0,T(e))}}(r);e.on("drain",u);var l=!1;var h=!1;function p(t){b("ondata"),h=!1,!1!==e.write(t)||h||((1===i.pipesCount&&i.pipes===e||i.pipesCount>1&&-1!==R(i.pipes,e))&&!l&&(b("false write response, pause",r._readableState.awaitDrain),r._readableState.awaitDrain++,h=!0),r.pause())}function m(t){b("onerror",t),x(),e.removeListener("error",m),0===c(e,"error")&&e.emit("error",t)}function v(){e.removeListener("finish",g),x()}function g(){b("onfinish"),e.removeListener("close",v),x()}function x(){b("unpipe"),r.unpipe(e)}return r.on("data",p),function(e,t,r){if("function"===typeof e.prependListener)return e.prependListener(t,r);e._events&&e._events[t]?o(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]:e.on(t,r)}(e,"error",m),e.once("close",v),e.once("finish",g),e.emit("pipe",r),i.flowing||(b("pipe resume"),r.resume()),e},x.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes||(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r)),this;if(!e){var n=t.pipes,a=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var i=0;i=t&&n<=r?n-t+10:e})).join("")},s=function(e){for(var t,r=e;r.length>2;)t=r.slice(0,9),r=parseInt(t,10)%97+r.slice(t.length);return parseInt(r,10)%97},f=function(){function e(t){n(this,e),this._iban=t}return a(e,[{key:"isValid",value:function(){return/^XE[0-9]{2}(ETH[0-9A-Z]{13}|[0-9A-Z]{30,31})$/.test(this._iban)&&1===s(c(this._iban))}},{key:"isDirect",value:function(){return 34===this._iban.length||35===this._iban.length}},{key:"isIndirect",value:function(){return 20===this._iban.length}},{key:"checksum",value:function(){return this._iban.substr(2,2)}},{key:"institution",value:function(){return this.isIndirect()?this._iban.substr(7,4):""}},{key:"client",value:function(){return this.isIndirect()?this._iban.substr(11):""}},{key:"toAddress",value:function(){if(this.isDirect()){var e=this._iban.substr(4),t=new o(e,36);return i.toChecksumAddress(t.toString(16,20))}return""}},{key:"toString",value:function(){return this._iban}}],[{key:"toAddress",value:function(t){if(!(t=new e(t)).isDirect())throw new Error("IBAN is indirect and can't be converted");return t.toAddress()}},{key:"toIban",value:function(t){return e.fromAddress(t).toString()}},{key:"fromAddress",value:function(t){if(!i.isAddress(t))throw new Error("Provided address is not a valid address: "+t);t=t.replace("0x","").replace("0X","");var r=function(e,t){for(var r=e;r.length<2*t;)r="0"+r;return r}(new o(t,16).toString(36),15);return e.fromBban(r.toUpperCase())}},{key:"fromBban",value:function(t){return new e("XE"+("0"+(98-s(c("XE00"+t)))).slice(-2)+t)}},{key:"createIndirect",value:function(t){return e.fromBban("ETH"+t.institution+t.identifier)}},{key:"isValid",value:function(t){return new e(t).isValid()}}]),e}();e.exports=f},function(e,t,r){"use strict";var n={messageId:0,toPayload:function(e,t){if(!e)throw new Error('JSONRPC method should be specified for params: "'+JSON.stringify(t)+'"!');return n.messageId++,{jsonrpc:"2.0",id:n.messageId,method:e,params:t||[]}},isValidResponse:function(e){return Array.isArray(e)?e.every(t):t(e);function t(e){return!!e&&!e.error&&"2.0"===e.jsonrpc&&("number"===typeof e.id||"string"===typeof e.id)&&void 0!==e.result}},toBatchPayload:function(e){return e.map((function(e){return n.toPayload(e.method,e.params)}))}};e.exports=n},function(e,t,r){(function(e,n){var a;!function(i){t&&t.nodeType,e&&e.nodeType;var o="object"==typeof n&&n;o.global!==o&&o.window!==o&&o.self;var c,s=2147483647,f=/^xn--/,d=/[^\x20-\x7E]/,u=/[\x2E\u3002\uFF0E\uFF61]/g,l={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},b=Math.floor,h=String.fromCharCode;function p(e){throw new RangeError(l[e])}function m(e,t){for(var r=e.length,n=[];r--;)n[r]=t(e[r]);return n}function v(e,t){var r=e.split("@"),n="";return r.length>1&&(n=r[0]+"@",e=r[1]),n+m((e=e.replace(u,".")).split("."),t).join(".")}function g(e){for(var t,r,n=[],a=0,i=e.length;a=55296&&t<=56319&&a65535&&(t+=h((e-=65536)>>>10&1023|55296),e=56320|1023&e),t+=h(e)})).join("")}function y(e,t){return e+22+75*(e<26)-((0!=t)<<5)}function w(e,t,r){var n=0;for(e=r?b(e/700):e>>1,e+=b(e/t);e>455;n+=36)e=b(e/35);return b(n+36*e/(e+38))}function k(e){var t,r,n,a,i,o,c,f,d,u,l,h=[],m=e.length,v=0,g=128,y=72;for((r=e.lastIndexOf("-"))<0&&(r=0),n=0;n=128&&p("not-basic"),h.push(e.charCodeAt(n));for(a=r>0?r+1:0;a=m&&p("invalid-input"),((f=(l=e.charCodeAt(a++))-48<10?l-22:l-65<26?l-65:l-97<26?l-97:36)>=36||f>b((s-v)/o))&&p("overflow"),v+=f*o,!(f<(d=c<=y?1:c>=y+26?26:c-y));c+=36)o>b(s/(u=36-d))&&p("overflow"),o*=u;y=w(v-i,t=h.length+1,0==i),b(v/t)>s-g&&p("overflow"),g+=b(v/t),v%=t,h.splice(v++,0,g)}return x(h)}function _(e){var t,r,n,a,i,o,c,f,d,u,l,m,v,x,k,_=[];for(m=(e=g(e)).length,t=128,r=0,i=72,o=0;o=t&&lb((s-r)/(v=n+1))&&p("overflow"),r+=(c-t)*v,t=c,o=0;os&&p("overflow"),l==t){for(f=r,d=36;!(f<(u=d<=i?1:d>=i+26?26:d-i));d+=36)k=f-u,x=36-u,_.push(h(y(u+k%x,0))),f=b(k/x);_.push(h(y(f,0))),i=w(r,v,n==a),r=0,++n}++r,++t}return _.join("")}c={version:"1.4.1",ucs2:{decode:g,encode:x},decode:k,encode:_,toASCII:function(e){return v(e,(function(e){return d.test(e)?"xn--"+_(e):e}))},toUnicode:function(e){return v(e,(function(e){return f.test(e)?k(e.slice(4).toLowerCase()):e}))}},void 0===(a=function(){return c}.call(t,r,t,e))||(e.exports=a)}()}).call(this,r(74)(e),r(44))},function(e,t,r){(function(e){t.fetch=c(e.fetch)&&c(e.ReadableStream),t.writableStream=c(e.WritableStream),t.abortController=c(e.AbortController),t.blobConstructor=!1;try{new Blob([new ArrayBuffer(1)]),t.blobConstructor=!0}catch(s){}var r;function n(){if(void 0!==r)return r;if(e.XMLHttpRequest){r=new e.XMLHttpRequest;try{r.open("GET",e.XDomainRequest?"/":"https://example.com")}catch(s){r=null}}else r=null;return r}function a(e){var t=n();if(!t)return!1;try{return t.responseType=e,t.responseType===e}catch(s){}return!1}var i="undefined"!==typeof e.ArrayBuffer,o=i&&c(e.ArrayBuffer.prototype.slice);function c(e){return"function"===typeof e}t.arraybuffer=t.fetch||i&&a("arraybuffer"),t.msstream=!t.fetch&&o&&a("ms-stream"),t.mozchunkedarraybuffer=!t.fetch&&i&&a("moz-chunked-arraybuffer"),t.overrideMimeType=t.fetch||!!n()&&c(n().overrideMimeType),t.vbArray=c(e.VBArray),r=null}).call(this,r(44))},function(e,t,r){(function(e,n,a){var i=r(429),o=r(33),c=r(199),s=t.readyStates={UNSENT:0,OPENED:1,HEADERS_RECEIVED:2,LOADING:3,DONE:4},f=t.IncomingMessage=function(t,r,o,s){var f=this;if(c.Readable.call(f),f._mode=o,f.headers={},f.rawHeaders=[],f.trailers={},f.rawTrailers=[],f.on("end",(function(){e.nextTick((function(){f.emit("close")}))})),"fetch"===o){if(f._fetchResponse=r,f.url=r.url,f.statusCode=r.status,f.statusMessage=r.statusText,r.headers.forEach((function(e,t){f.headers[t.toLowerCase()]=e,f.rawHeaders.push(t,e)})),i.writableStream){var d=new WritableStream({write:function(e){return new Promise((function(t,r){f._destroyed?r():f.push(new a(e))?t():f._resumeFetch=t}))},close:function(){n.clearTimeout(s),f._destroyed||f.push(null)},abort:function(e){f._destroyed||f.emit("error",e)}});try{return void r.body.pipeTo(d).catch((function(e){n.clearTimeout(s),f._destroyed||f.emit("error",e)}))}catch(h){}}var u=r.body.getReader();!function e(){u.read().then((function(t){if(!f._destroyed){if(t.done)return n.clearTimeout(s),void f.push(null);f.push(new a(t.value)),e()}})).catch((function(e){n.clearTimeout(s),f._destroyed||f.emit("error",e)}))}()}else{if(f._xhr=t,f._pos=0,f.url=t.responseURL,f.statusCode=t.status,f.statusMessage=t.statusText,t.getAllResponseHeaders().split(/\r?\n/).forEach((function(e){var t=e.match(/^([^:]+):\s*(.*)/);if(t){var r=t[1].toLowerCase();"set-cookie"===r?(void 0===f.headers[r]&&(f.headers[r]=[]),f.headers[r].push(t[2])):void 0!==f.headers[r]?f.headers[r]+=", "+t[2]:f.headers[r]=t[2],f.rawHeaders.push(t[1],t[2])}})),f._charset="x-user-defined",!i.overrideMimeType){var l=f.rawHeaders["mime-type"];if(l){var b=l.match(/;\s*charset=([^;])(;|$)/);b&&(f._charset=b[1].toLowerCase())}f._charset||(f._charset="utf-8")}}};o(f,c.Readable),f.prototype._read=function(){var e=this._resumeFetch;e&&(this._resumeFetch=null,e())},f.prototype._onXHRProgress=function(){var e=this,t=e._xhr,r=null;switch(e._mode){case"text:vbarray":if(t.readyState!==s.DONE)break;try{r=new n.VBArray(t.responseBody).toArray()}catch(d){}if(null!==r){e.push(new a(r));break}case"text":try{r=t.responseText}catch(d){e._mode="text:vbarray";break}if(r.length>e._pos){var i=r.substr(e._pos);if("x-user-defined"===e._charset){for(var o=new a(i.length),c=0;ce._pos&&(e.push(new a(new Uint8Array(f.result.slice(e._pos)))),e._pos=f.result.byteLength)},f.onload=function(){e.push(null)},f.readAsArrayBuffer(r)}e._xhr.readyState===s.DONE&&"ms-stream"!==e._mode&&e.push(null)}}).call(this,r(48),r(44),r(30).Buffer)},function(e,t,r){var n=r(311),a=r(173),i=e.exports;for(var o in n)n.hasOwnProperty(o)&&(i[o]=n[o]);function c(e){if("string"===typeof e&&(e=a.parse(e)),e.protocol||(e.protocol="https:"),"https:"!==e.protocol)throw new Error('Protocol "'+e.protocol+'" not supported. Expected "https:"');return e}i.request=function(e,t){return e=c(e),n.request.call(this,e,t)},i.get=function(e,t){return e=c(e),n.get.call(this,e,t)}},function(e,t,r){"use strict";e.exports={addresses:{main:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",ropsten:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",rinkeby:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",goerli:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e"},interfaceIds:{addr:"0x3b3b57de",setAddr:"0x3b3b57de",pubkey:"0xc8690233",setPubkey:"0xc8690233",contenthash:"0xbc1c58d1",setContenthash:"0xbc1c58d1",content:"0xd8389dc5",setContent:"0xd8389dc5"}}},function(e,t,r){"use strict";var n=r(130),a=r(153),i=r(154),o=r(78),c=r(242).subscription,s=r(76).formatters,f=r(76).errors,d=r(241),u=r(434),l=function e(t,r,i){var c=this,d=Array.prototype.slice.call(arguments);if(!(this instanceof e))throw new Error('Please use the "new" keyword to instantiate a web3.eth.Contract() object!');if(this.setProvider=function(){a.packageInit(c,arguments),c.clearSubscriptions=c._requestManager.clearSubscriptions},a.packageInit(this,[this.constructor]),this.clearSubscriptions=this._requestManager.clearSubscriptions,!t||!Array.isArray(t))throw f.ContractMissingABIError();this.options={};var l=d[d.length-1];l&&"object"===typeof l&&!Array.isArray(l)&&(i=l,this.options=n(n({},this.options),this._getOrSetDefaultOptions(i)),r&&"object"===typeof r&&(r=null)),Object.defineProperty(this.options,"address",{set:function(e){e&&(c._address=o.toChecksumAddress(s.inputAddressFormatter(e)))},get:function(){return c._address},enumerable:!0}),Object.defineProperty(this.options,"jsonInterface",{set:function(e){return c.methods={},c.events={},c._jsonInterface=e.map((function(e){var t,r;if(e.constant="view"===e.stateMutability||"pure"===e.stateMutability||e.constant,e.payable="payable"===e.stateMutability||e.payable,e.name&&(r=o._jsonInterfaceMethodToString(e)),"function"===e.type){if(e.signature=u.encodeFunctionSignature(r),t=c._createTxObject.bind({method:e,parent:c}),c.methods[e.name]){var n=c._createTxObject.bind({method:e,parent:c,nextMethod:c.methods[e.name]});c.methods[e.name]=n}else c.methods[e.name]=t;c.methods[e.signature]=t,c.methods[r]=t}else if("event"===e.type){e.signature=u.encodeEventSignature(r);var a=c._on.bind(c,e.signature);c.events[e.name]&&"bound "!==c.events[e.name].name||(c.events[e.name]=a),c.events[e.signature]=a,c.events[r]=a}return e})),c.events.allEvents=c._on.bind(c,"allevents"),c._jsonInterface},get:function(){return c._jsonInterface},enumerable:!0});var b=this.constructor.defaultAccount,h=this.constructor.defaultBlock||"latest";Object.defineProperty(this,"handleRevert",{get:function(){return!1===c.options.handleRevert||!0===c.options.handleRevert?c.options.handleRevert:this.constructor.handleRevert},set:function(e){c.options.handleRevert=e},enumerable:!0}),Object.defineProperty(this,"defaultCommon",{get:function(){return c.options.common||this.constructor.defaultCommon},set:function(e){c.options.common=e},enumerable:!0}),Object.defineProperty(this,"defaultHardfork",{get:function(){return c.options.hardfork||this.constructor.defaultHardfork},set:function(e){c.options.hardfork=e},enumerable:!0}),Object.defineProperty(this,"defaultChain",{get:function(){return c.options.chain||this.constructor.defaultChain},set:function(e){c.options.chain=e},enumerable:!0}),Object.defineProperty(this,"transactionPollingTimeout",{get:function(){return 0===c.options.transactionPollingTimeout?c.options.transactionPollingTimeout:c.options.transactionPollingTimeout||this.constructor.transactionPollingTimeout},set:function(e){c.options.transactionPollingTimeout=e},enumerable:!0}),Object.defineProperty(this,"transactionConfirmationBlocks",{get:function(){return 0===c.options.transactionConfirmationBlocks?c.options.transactionConfirmationBlocks:c.options.transactionConfirmationBlocks||this.constructor.transactionConfirmationBlocks},set:function(e){c.options.transactionConfirmationBlocks=e},enumerable:!0}),Object.defineProperty(this,"transactionBlockTimeout",{get:function(){return 0===c.options.transactionBlockTimeout?c.options.transactionBlockTimeout:c.options.transactionBlockTimeout||this.constructor.transactionBlockTimeout},set:function(e){c.options.transactionBlockTimeout=e},enumerable:!0}),Object.defineProperty(this,"blockHeaderTimeout",{get:function(){return 0===c.options.blockHeaderTimeout?c.options.blockHeaderTimeout:c.options.blockHeaderTimeout||this.constructor.blockHeaderTimeout},set:function(e){c.options.blockHeaderTimeout=e},enumerable:!0}),Object.defineProperty(this,"defaultAccount",{get:function(){return b},set:function(e){return e&&(b=o.toChecksumAddress(s.inputAddressFormatter(e))),e},enumerable:!0}),Object.defineProperty(this,"defaultBlock",{get:function(){return h},set:function(e){return h=e,e},enumerable:!0}),this.methods={},this.events={},this._address=null,this._jsonInterface=[],this.options.address=r,this.options.jsonInterface=t};l.setProvider=function(e,t){a.packageInit(this,[e]),this._ethAccounts=t},l.prototype._getCallback=function(e){if(e&&e[e.length-1]&&"function"===typeof e[e.length-1])return e.pop()},l.prototype._checkListener=function(e,t){if(t===e)throw f.ContractReservedEventError(e)},l.prototype._getOrSetDefaultOptions=function(e){var t=e.gasPrice?String(e.gasPrice):null,r=e.from?o.toChecksumAddress(s.inputAddressFormatter(e.from)):null;return e.data=e.data||this.options.data,e.from=r||this.options.from,e.gasPrice=t||this.options.gasPrice,e.gas=e.gas||e.gasLimit||this.options.gas,delete e.gasLimit,e},l.prototype._encodeEventABI=function(e,t){var r=(t=t||{}).filter||{},n={};if(["fromBlock","toBlock"].filter((function(e){return void 0!==t[e]})).forEach((function(e){n[e]=s.inputBlockNumberFormatter(t[e])})),Array.isArray(t.topics))n.topics=t.topics;else{if(n.topics=[],e&&!e.anonymous&&"ALLEVENTS"!==e.name&&n.topics.push(e.signature),"ALLEVENTS"!==e.name){var a=e.inputs.filter((function(e){return!0===e.indexed})).map((function(e){var t=r[e.name];return t?Array.isArray(t)?t.map((function(t){return u.encodeParameter(e.type,t)})):u.encodeParameter(e.type,t):null}));n.topics=n.topics.concat(a)}n.topics.length||delete n.topics}return this.options.address&&(n.address=this.options.address.toLowerCase()),n},l.prototype._decodeEventABI=function(e){var t=this;e.data=e.data||"",e.topics=e.topics||[];var r=s.outputLogFormatter(e);if("ALLEVENTS"===t.name&&(t=t.jsonInterface.find((function(t){return t.signature===e.topics[0]}))||{anonymous:!0}),t.inputs=t.inputs||[],!t.anonymous){var n=0;t.inputs.forEach((function(e){return e.indexed?n++:null})),n>0&&e.topics.length!==n+1&&(t={anonymous:!0,inputs:[]})}var a=t.anonymous?e.topics:e.topics.slice(1);return r.returnValues=u.decodeLog(t.inputs,e.data,a),delete r.returnValues.__length__,r.event=t.name,r.signature=t.anonymous||!e.topics[0]?null:e.topics[0],r.raw={data:r.data,topics:r.topics},delete r.data,delete r.topics,r},l.prototype._encodeMethodABI=function(){var e=this._method.signature,t=this.arguments||[],r=!1,n=this._parent.options.jsonInterface.filter((function(t){return"constructor"===e&&t.type===e||(t.signature===e||t.signature===e.replace("0x","")||t.name===e)&&"function"===t.type})).map((function(e){var n=Array.isArray(e.inputs)?e.inputs.length:0;if(n!==t.length)throw new Error("The number of arguments is not matching the methods required number. You need to pass "+n+" arguments.");return"function"===e.type&&(r=e.signature),Array.isArray(e.inputs)?e.inputs:[]})).map((function(e){return u.encodeParameters(e,t).replace("0x","")}))[0]||"";if("constructor"===e){if(!this._deployData)throw new Error("The contract has no contract data option set. This is necessary to append the constructor parameters.");return this._deployData.startsWith("0x")||(this._deployData="0x"+this._deployData),this._deployData+n}var a=r?r+n:n;if(!a)throw new Error("Couldn't find a matching contract method named \""+this._method.name+'".');return a},l.prototype._decodeMethodReturn=function(e,t){if(!t)return null;t=t.length>=2?t.slice(2):t;var r=u.decodeParameters(e,t);return 1===r.__length__?r[0]:(delete r.__length__,r)},l.prototype.deploy=function(e,t){if((e=e||{}).arguments=e.arguments||[],!(e=this._getOrSetDefaultOptions(e)).data){if("function"===typeof t)return t(f.ContractMissingDeployDataError());throw f.ContractMissingDeployDataError()}var r=this.options.jsonInterface.find((function(e){return"constructor"===e.type}))||{};return r.signature="constructor",this._createTxObject.apply({method:r,parent:this,deployData:e.data,_ethAccounts:this.constructor._ethAccounts},e.arguments)},l.prototype._generateEventOptions=function(){var e=Array.prototype.slice.call(arguments),t=this._getCallback(e),r="object"===(!!e[e.length-1]&&typeof e[e.length-1])?e.pop():{},n="string"===typeof e[0]?e[0]:"allevents",a="allevents"===n.toLowerCase()?{name:"ALLEVENTS",jsonInterface:this.options.jsonInterface}:this.options.jsonInterface.find((function(e){return"event"===e.type&&(e.name===n||e.signature==="0x"+n.replace("0x",""))}));if(!a)throw f.ContractEventDoesNotExistError(n);if(!o.isAddress(this.options.address))throw f.ContractNoAddressDefinedError();return{params:this._encodeEventABI(a,r),event:a,callback:t}},l.prototype.clone=function(){return new this.constructor(this.options.jsonInterface,this.options.address,this.options)},l.prototype.once=function(e,t,r){var n=Array.prototype.slice.call(arguments);if(!(r=this._getCallback(n)))throw f.ContractOnceRequiresCallbackError();t&&delete t.fromBlock,this._on(e,t,(function(e,t,n){n.unsubscribe(),"function"===typeof r&&r(e,t,n)}))},l.prototype._on=function(){var e=this._generateEventOptions.apply(this,arguments);e.params&&e.params.toBlock&&(delete e.params.toBlock,console.warn("Invalid option: toBlock. Use getPastEvents for specific range.")),this._checkListener("newListener",e.event.name),this._checkListener("removeListener",e.event.name);var t=new c({subscription:{params:1,inputFormatter:[s.inputLogFormatter],outputFormatter:this._decodeEventABI.bind(e.event),subscriptionHandler:function(e){e.removed?this.emit("changed",e):this.emit("data",e),"function"===typeof this.callback&&this.callback(null,e,this)}},type:"eth",requestManager:this._requestManager});return t.subscribe("logs",e.params,e.callback||function(){}),t},l.prototype.getPastEvents=function(){var e=this._generateEventOptions.apply(this,arguments),t=new i({name:"getPastLogs",call:"eth_getLogs",params:1,inputFormatter:[s.inputLogFormatter],outputFormatter:this._decodeEventABI.bind(e.event)});t.setRequestManager(this._requestManager);var r=t.buildCall();return t=null,r(e.params,e.callback)},l.prototype._createTxObject=function(){var e=Array.prototype.slice.call(arguments),t={};if("function"===this.method.type&&(t.call=this.parent._executeMethod.bind(t,"call"),t.call.request=this.parent._executeMethod.bind(t,"call",!0)),t.send=this.parent._executeMethod.bind(t,"send"),t.send.request=this.parent._executeMethod.bind(t,"send",!0),t.encodeABI=this.parent._encodeMethodABI.bind(t),t.estimateGas=this.parent._executeMethod.bind(t,"estimate"),t.createAccessList=this.parent._executeMethod.bind(t,"createAccessList"),e&&this.method.inputs&&e.length!==this.method.inputs.length){if(this.nextMethod)return this.nextMethod.apply(null,e);throw f.InvalidNumberOfParams(e.length,this.method.inputs.length,this.method.name)}return t.arguments=e||[],t._method=this.method,t._parent=this.parent,t._ethAccounts=this.parent.constructor._ethAccounts||this._ethAccounts,this.deployData&&(t._deployData=this.deployData),t},l.prototype._processExecuteArguments=function(e,t){var r={};if(r.type=e.shift(),r.callback=this._parent._getCallback(e),"call"!==r.type||!0===e[e.length-1]||"string"!==typeof e[e.length-1]&&!isFinite(e[e.length-1])||(r.defaultBlock=e.pop()),r.options="object"===(!!e[e.length-1]&&typeof e[e.length-1])?e.pop():{},r.generateRequest=!0===e[e.length-1]&&e.pop(),r.options=this._parent._getOrSetDefaultOptions(r.options),r.options.data=this.encodeABI(),!this._deployData&&!o.isAddress(this._parent.options.address))throw f.ContractNoAddressDefinedError();return this._deployData||(r.options.to=this._parent.options.address),r.options.data?r:o._fireError(new Error("Couldn't find a matching contract method, or the number of parameters is wrong."),t.eventEmitter,t.reject,r.callback)},l.prototype._executeMethod=function(){var e=this,t=this._parent._processExecuteArguments.call(this,Array.prototype.slice.call(arguments),r),r=d("send"!==t.type),n=e.constructor._ethAccounts||e._ethAccounts;if(t.generateRequest){var a={params:[s.inputCallFormatter.call(this._parent,t.options)],callback:t.callback};return"call"===t.type?(a.params.push(s.inputDefaultBlockNumberFormatter.call(this._parent,t.defaultBlock)),a.method="eth_call",a.format=this._parent._decodeMethodReturn.bind(null,this._method.outputs)):a.method="eth_sendTransaction",a}switch(t.type){case"createAccessList":if(!o.isAddress(t.options.from))return o._fireError(f.ContractNoFromAddressDefinedError(),r.eventEmitter,r.reject,t.callback);var c=new i({name:"createAccessList",call:"eth_createAccessList",params:2,inputFormatter:[s.inputTransactionFormatter,s.inputDefaultBlockNumberFormatter],requestManager:e._parent._requestManager,accounts:n,defaultAccount:e._parent.defaultAccount,defaultBlock:e._parent.defaultBlock}).createFunction();return c(t.options,t.callback);case"estimate":var l=new i({name:"estimateGas",call:"eth_estimateGas",params:1,inputFormatter:[s.inputCallFormatter],outputFormatter:o.hexToNumber,requestManager:e._parent._requestManager,accounts:n,defaultAccount:e._parent.defaultAccount,defaultBlock:e._parent.defaultBlock}).createFunction();return l(t.options,t.callback);case"call":var b=new i({name:"call",call:"eth_call",params:2,inputFormatter:[s.inputCallFormatter,s.inputDefaultBlockNumberFormatter],outputFormatter:function(t){return e._parent._decodeMethodReturn(e._method.outputs,t)},requestManager:e._parent._requestManager,accounts:n,defaultAccount:e._parent.defaultAccount,defaultBlock:e._parent.defaultBlock,handleRevert:e._parent.handleRevert,abiCoder:u}).createFunction();return b(t.options,t.defaultBlock,t.callback);case"send":if(!o.isAddress(t.options.from))return o._fireError(f.ContractNoFromAddressDefinedError(),r.eventEmitter,r.reject,t.callback);if("boolean"===typeof this._method.payable&&!this._method.payable&&t.options.value&&t.options.value>0)return o._fireError(new Error("Can not send value to non-payable contract method or constructor"),r.eventEmitter,r.reject,t.callback);var h={receiptFormatter:function(t){if(Array.isArray(t.logs)){var r=t.logs.map((function(t){return e._parent._decodeEventABI.call({name:"ALLEVENTS",jsonInterface:e._parent.options.jsonInterface},t)}));t.events={};var n=0;r.forEach((function(e){e.event?t.events[e.event]?Array.isArray(t.events[e.event])?t.events[e.event].push(e):t.events[e.event]=[t.events[e.event],e]:t.events[e.event]=e:(t.events[n]=e,n++)})),delete t.logs}return t},contractDeployFormatter:function(t){var r=e._parent.clone();return r.options.address=t.contractAddress,r}},p=new i({name:"sendTransaction",call:"eth_sendTransaction",params:1,inputFormatter:[s.inputTransactionFormatter],requestManager:e._parent._requestManager,accounts:e.constructor._ethAccounts||e._ethAccounts,defaultAccount:e._parent.defaultAccount,defaultBlock:e._parent.defaultBlock,transactionBlockTimeout:e._parent.transactionBlockTimeout,transactionConfirmationBlocks:e._parent.transactionConfirmationBlocks,transactionPollingTimeout:e._parent.transactionPollingTimeout,defaultCommon:e._parent.defaultCommon,defaultChain:e._parent.defaultChain,defaultHardfork:e._parent.defaultHardfork,handleRevert:e._parent.handleRevert,extraFormatters:h,abiCoder:u}).createFunction();return p(t.options,t.callback);default:throw new Error('Method "'+t.type+'" not implemented.')}},e.exports=l},function(e,t,r){var n=r(30).Buffer,a=r(78),i=r(158).AbiCoder,o=r(158).ParamType,c=new i((function(e,t){return!e.match(/^u?int/)||Array.isArray(t)||t&&"object"===typeof t&&"BN"===t.constructor.name?t:t.toString()}));function s(){}var f=function(){};f.prototype.encodeFunctionSignature=function(e){return("function"===typeof e||"object"===typeof e&&e)&&(e=a._jsonInterfaceMethodToString(e)),a.sha3(e).slice(0,10)},f.prototype.encodeEventSignature=function(e){return("function"===typeof e||"object"===typeof e&&e)&&(e=a._jsonInterfaceMethodToString(e)),a.sha3(e)},f.prototype.encodeParameter=function(e,t){return this.encodeParameters([e],[t])},f.prototype.encodeParameters=function(e,t){var r=this;return e=r.mapTypes(e),t=t.map((function(t,n){var a=e[n];if("object"===typeof a&&a.type&&(a=a.type),t=r.formatParam(a,t),"string"===typeof a&&a.includes("tuple")){!function e(t,n){if("array"===t.name)return n.map((function(r){return e(c._getCoder(o.from(t.type.replace("[]",""))),r)}));t.coders.forEach((function(t,a){"tuple"===t.name?e(t,n[a]):n[a]=r.formatParam(t.name,n[a])}))}(c._getCoder(o.from(a)),t)}return t})),c.encode(e,t)},f.prototype.mapTypes=function(e){var t=this,r=[];return e.forEach((function(e){if("object"===typeof e&&"function"===e.type&&(e=Object.assign({},e,{type:"bytes24"})),t.isSimplifiedStructFormat(e)){var n=Object.keys(e)[0];r.push(Object.assign(t.mapStructNameAndType(n),{components:t.mapStructToCoderFormat(e[n])}))}else r.push(e)})),r},f.prototype.isSimplifiedStructFormat=function(e){return"object"===typeof e&&"undefined"===typeof e.components&&"undefined"===typeof e.name},f.prototype.mapStructNameAndType=function(e){var t="tuple";return e.indexOf("[]")>-1&&(t="tuple[]",e=e.slice(0,-2)),{type:t,name:e}},f.prototype.mapStructToCoderFormat=function(e){var t=this,r=[];return Object.keys(e).forEach((function(n){"object"!==typeof e[n]?r.push({name:n,type:e[n]}):r.push(Object.assign(t.mapStructNameAndType(n),{components:t.mapStructToCoderFormat(e[n])}))})),r},f.prototype.formatParam=function(e,t){var r=this,i=new RegExp(/^bytes([0-9]*)$/),o=new RegExp(/^bytes([0-9]*)\[\]$/),c=new RegExp(/^(u?int)([0-9]*)$/),s=new RegExp(/^(u?int)([0-9]*)\[\]$/);if(a.isBN(t)||a.isBigNumber(t))return t.toString(10);if(e.match(o)||e.match(s))return t.map((function(t){return r.formatParam(e.replace("[]",""),t)}));var f=e.match(c);if(f){var d=parseInt(f[2]||"256");d/80&&(!t||"0x"===t||"0X"===t))throw new Error("Returned values aren't valid, did it run Out of Gas? You might also see this error if you are not using the correct ABI for the contract you are retrieving data from, requesting data from a block number that does not exist, or querying a node which is not fully synced.");var n=c.decode(this.mapTypes(e),"0x"+t.replace(/0x/i,""),r),a=new s;return a.__length__=0,e.forEach((function(e,t){var r=n[a.__length__];r="0x"===r?null:r,a[t]=r,("function"===typeof e||e&&"object"===typeof e)&&e.name&&(a[e.name]=r),a.__length__++})),a},f.prototype.decodeLog=function(e,t,r){var n=this;r=Array.isArray(r)?r:[r],t=t||"";var a=[],i=[],o=0;e.forEach((function(e,t){e.indexed?(i[t]=["bool","int","uint","address","fixed","ufixed"].find((function(t){return-1!==e.type.indexOf(t)}))?n.decodeParameter(e.type,r[o]):r[o],o++):a[t]=e}));var c=t,f=c?this.decodeParametersWith(a,c,!0):[],d=new s;return d.__length__=0,e.forEach((function(e,t){d[t]="string"===e.type?"":null,"undefined"!==typeof f[t]&&(d[t]=f[t]),"undefined"!==typeof i[t]&&(d[t]=i[t]),e.name&&(d[e.name]=d[t]),d.__length__++})),d};var d=new f;e.exports=d},function(e,t,r){(function(e){var n=r(743).keccak_256,a=r(744);function i(e){return e?a.toUnicode(e,{useStd3ASCII:!0,transitional:!1}):e}t.hash=function(t){for(var r="",a=0;a<32;a++)r+="00";if(name=i(t),name){var o=name.split(".");for(a=o.length-1;a>=0;a--){var c=n(o[a]);r=n(new e(r+c,"hex"))}}return"0x"+r},t.normalize=i}).call(this,r(30).Buffer)},function(e,t,r){"use strict";(function(t){var n=r(133);function a(e){return parseInt(e.toString("hex"),16)}function i(e){var r=e.toString(16);return r.length%2===1&&(r="0"+r),t.from(r,"hex")}e.exports={numberToBuffer:i,bufferToNumber:a,varintBufferEncode:function(e){return t.from(n.encode(a(e)))},varintBufferDecode:function(e){return i(n.decode(e))},varintEncode:function(e){return t.from(n.encode(e))}}}).call(this,r(30).Buffer)},function(e,t,r){"use strict";var n=r(87),a=r(88),i=r(30).Buffer,o=r(313),c=r(767),s=r(773),f=r(201),d=r(778),u=r(779)(function(e){function t(e,r,a,f){if(n(this,t),u.isCID(e)){var d=e;return this.version=d.version,this.codec=d.codec,this.multihash=i.from(d.multihash),void(this.multibaseName=d.multibaseName||(0===d.version?"base58btc":"base32"))}if("string"===typeof e){var l=c.isEncoded(e);if(l){var b=c.decode(e);this.version=parseInt(b.slice(0,1).toString("hex"),16),this.codec=s.getCodec(b.slice(1)),this.multihash=s.rmPrefix(b.slice(1)),this.multibaseName=l}else this.version=0,this.codec="dag-pb",this.multihash=o.fromB58String(e),this.multibaseName="base58btc";return t.validateCID(this),void Object.defineProperty(this,"string",{value:e})}if(i.isBuffer(e)){var h=e.slice(0,1),p=parseInt(h.toString("hex"),16);if(1===p){var m=e;this.version=p,this.codec=s.getCodec(m.slice(1)),this.multihash=s.rmPrefix(m.slice(1)),this.multibaseName="base32"}else this.version=0,this.codec="dag-pb",this.multihash=e,this.multibaseName="base58btc";t.validateCID(this)}else this.version=e,this.codec=r,this.multihash=a,this.multibaseName=f||(0===e?"base58btc":"base32"),t.validateCID(this)}return a(t,[{key:"buffer",get:function(){var e=this._buffer;if(!e){if(0===this.version)e=this.multihash;else{if(1!==this.version)throw new Error("unsupported version");e=i.concat([i.from("01","hex"),s.getCodeVarint(this.codec),this.multihash])}Object.defineProperty(this,"_buffer",{value:e})}return e}},{key:"prefix",get:function(){return i.concat([i.from("0".concat(this.version),"hex"),s.getCodeVarint(this.codec),o.prefix(this.multihash)])}},{key:"toV0",value:function(){if("dag-pb"!==this.codec)throw new Error("Cannot convert a non dag-pb CID to CIDv0");var e=o.decode(this.multihash),t=e.name,r=e.length;if("sha2-256"!==t)throw new Error("Cannot convert non sha2-256 multihash CID to CIDv0");if(32!==r)throw new Error("Cannot convert non 32 byte multihash CID to CIDv0");return new u(0,this.codec,this.multihash)}},{key:"toV1",value:function(){return new u(1,this.codec,this.multihash)}},{key:"toBaseEncodedString",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.multibaseName;if(this.string&&e===this.multibaseName)return this.string;var t=null;if(0===this.version){if("base58btc"!==e)throw new Error("not supported with CIDv0, to support different bases, please migrate the instance do CIDv1, you can do that through cid.toV1()");t=o.toB58String(this.multihash)}else{if(1!==this.version)throw new Error("unsupported version");t=c.encode(e,this.buffer).toString()}return e===this.multibaseName&&Object.defineProperty(this,"string",{value:t}),t}},{key:e,value:function(){return"CID("+this.toString()+")"}},{key:"toString",value:function(e){return this.toBaseEncodedString(e)}},{key:"toJSON",value:function(){return{codec:this.codec,version:this.version,hash:this.multihash}}},{key:"equals",value:function(e){return this.codec===e.codec&&this.version===e.version&&this.multihash.equals(e.multihash)}}],[{key:"validateCID",value:function(e){var t=d.checkCIDComponents(e);if(t)throw new Error(t)}}]),t}(Symbol.for("nodejs.util.inspect.custom")),{className:"CID",symbolName:"@ipld/js-cid/CID"});u.codecs=f,e.exports=u},function(e,t,r){"use strict";var n=r(42).Buffer;e.exports=function(e){if(e.length>=255)throw new TypeError("Alphabet too long");for(var t=new Uint8Array(256),r=0;r>>0,d=new Uint8Array(o);e[r];){var u=t[e.charCodeAt(r)];if(255===u)return;for(var l=0,b=o-1;(0!==u||l>>0,d[b]=u%256>>>0,u=u/256>>>0;if(0!==u)throw new Error("Non-zero carry");i=l,r++}for(var h=o-i;h!==o&&0===d[h];)h++;var p=n.allocUnsafe(a+(o-h));p.fill(0,0,a);for(var m=a;h!==o;)p[m++]=d[h++];return p}return{encode:function(t){if((Array.isArray(t)||t instanceof Uint8Array)&&(t=n.from(t)),!n.isBuffer(t))throw new TypeError("Expected Buffer");if(0===t.length)return"";for(var r=0,a=0,i=0,o=t.length;i!==o&&0===t[i];)i++,r++;for(var f=(o-i)*d+1>>>0,u=new Uint8Array(f);i!==o;){for(var l=t[i],b=0,h=f-1;(0!==l||b>>0,u[h]=l%c>>>0,l=l/c>>>0;if(0!==l)throw new Error("Non-zero carry");a=b,i++}for(var p=f-a;p!==f&&0===u[p];)p++;for(var m=s.repeat(r);p>6|192);else{if(a>55295&&a<56320){if(++n==e.length)return null;var i=e.charCodeAt(n);if(i<56320||i>57343)return null;r+=t((a=65536+((1023&a)<<10)+(1023&i))>>18|240),r+=t(a>>12&63|128)}else r+=t(a>>12|224);r+=t(a>>6&63|128)}r+=t(63&a|128)}}return r},toString:function(e){for(var t="",r=0,i=a(e);r127){if(o>191&&o<224){if(r>=i)return null;o=(31&o)<<6|63&n(e,r)}else if(o>223&&o<240){if(r+1>=i)return null;o=(15&o)<<12|(63&n(e,r))<<6|63&n(e,++r)}else{if(!(o>239&&o<248))return null;if(r+2>=i)return null;o=(7&o)<<18|(63&n(e,r))<<12|(63&n(e,++r))<<6|63&n(e,++r)}++r}if(o<=65535)t+=String.fromCharCode(o);else{if(!(o<=1114111))return null;o-=65536,t+=String.fromCharCode(o>>10|55296),t+=String.fromCharCode(1023&o|56320)}}return t},fromNumber:function(e){var t=e.toString(16);return t.length%2===0?"0x"+t:"0x0"+t},toNumber:function(e){return parseInt(e.slice(2),16)},fromNat:function(e){return"0x0"===e?"0x":e.length%2===0?e:"0x0"+e.slice(2)},toNat:function(e){return"0"===e[2]?"0x"+e.slice(3):e},fromArray:o,toArray:i,fromUint8Array:function(e){return o([].slice.call(e,0))},toUint8Array:function(e){return new Uint8Array(i(e))}}},function(e,t,r){"use strict";var n=r(33),a=r(787),i=r(132),o=r(42).Buffer,c=r(443),s=r(306),f=r(307),d=o.alloc(128);function u(e,t){i.call(this,"digest"),"string"===typeof t&&(t=o.from(t));var r="sha512"===e||"sha384"===e?128:64;(this._alg=e,this._key=t,t.length>r)?t=("rmd160"===e?new s:f(e)).update(t).digest():t.lengthr||t!==t)throw new TypeError("Bad key length")}},function(e,t,r){(function(t,r){var n;if(t.process&&t.process.browser)n="utf-8";else if(t.process&&t.process.version){n=parseInt(r.version.split(".")[0].slice(1),10)>=6?"utf-8":"binary"}else n="utf-8";e.exports=n}).call(this,r(44),r(48))},function(e,t,r){var n=r(443),a=r(306),i=r(307),o=r(42).Buffer,c=r(446),s=r(447),f=r(449),d=o.alloc(128),u={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,rmd160:20,ripemd160:20};function l(e,t,r){var c=function(e){function t(t){return i(e).update(t).digest()}return"rmd160"===e||"ripemd160"===e?function(e){return(new a).update(e).digest()}:"md5"===e?n:t}(e),s="sha512"===e||"sha384"===e?128:64;t.length>s?t=c(t):t.length>>0},t.writeUInt32BE=function(e,t,r){e[0+r]=t>>>24,e[1+r]=t>>>16&255,e[2+r]=t>>>8&255,e[3+r]=255&t},t.ip=function(e,t,r,n){for(var a=0,i=0,o=6;o>=0;o-=2){for(var c=0;c<=24;c+=8)a<<=1,a|=t>>>c+o&1;for(c=0;c<=24;c+=8)a<<=1,a|=e>>>c+o&1}for(o=6;o>=0;o-=2){for(c=1;c<=25;c+=8)i<<=1,i|=t>>>c+o&1;for(c=1;c<=25;c+=8)i<<=1,i|=e>>>c+o&1}r[n+0]=a>>>0,r[n+1]=i>>>0},t.rip=function(e,t,r,n){for(var a=0,i=0,o=0;o<4;o++)for(var c=24;c>=0;c-=8)a<<=1,a|=t>>>c+o&1,a<<=1,a|=e>>>c+o&1;for(o=4;o<8;o++)for(c=24;c>=0;c-=8)i<<=1,i|=t>>>c+o&1,i<<=1,i|=e>>>c+o&1;r[n+0]=a>>>0,r[n+1]=i>>>0},t.pc1=function(e,t,r,n){for(var a=0,i=0,o=7;o>=5;o--){for(var c=0;c<=24;c+=8)a<<=1,a|=t>>c+o&1;for(c=0;c<=24;c+=8)a<<=1,a|=e>>c+o&1}for(c=0;c<=24;c+=8)a<<=1,a|=t>>c+o&1;for(o=1;o<=3;o++){for(c=0;c<=24;c+=8)i<<=1,i|=t>>c+o&1;for(c=0;c<=24;c+=8)i<<=1,i|=e>>c+o&1}for(c=0;c<=24;c+=8)i<<=1,i|=e>>c+o&1;r[n+0]=a>>>0,r[n+1]=i>>>0},t.r28shl=function(e,t){return e<>>28-t};var n=[14,11,17,4,27,23,25,0,13,22,7,18,5,9,16,24,2,20,12,21,1,8,15,26,15,4,25,19,9,1,26,16,5,11,23,8,12,7,17,0,22,3,10,14,6,20,27,24];t.pc2=function(e,t,r,a){for(var i=0,o=0,c=n.length>>>1,s=0;s>>n[s]&1;for(s=c;s>>n[s]&1;r[a+0]=i>>>0,r[a+1]=o>>>0},t.expand=function(e,t,r){var n=0,a=0;n=(1&e)<<5|e>>>27;for(var i=23;i>=15;i-=4)n<<=6,n|=e>>>i&63;for(i=11;i>=3;i-=4)a|=e>>>i&63,a<<=6;a|=(31&e)<<1|e>>>31,t[r+0]=n>>>0,t[r+1]=a>>>0};var a=[14,0,4,15,13,7,1,4,2,14,15,2,11,13,8,1,3,10,10,6,6,12,12,11,5,9,9,5,0,3,7,8,4,15,1,12,14,8,8,2,13,4,6,9,2,1,11,7,15,5,12,11,9,3,7,14,3,10,10,0,5,6,0,13,15,3,1,13,8,4,14,7,6,15,11,2,3,8,4,14,9,12,7,0,2,1,13,10,12,6,0,9,5,11,10,5,0,13,14,8,7,10,11,1,10,3,4,15,13,4,1,2,5,11,8,6,12,7,6,12,9,0,3,5,2,14,15,9,10,13,0,7,9,0,14,9,6,3,3,4,15,6,5,10,1,2,13,8,12,5,7,14,11,12,4,11,2,15,8,1,13,1,6,10,4,13,9,0,8,6,15,9,3,8,0,7,11,4,1,15,2,14,12,3,5,11,10,5,14,2,7,12,7,13,13,8,14,11,3,5,0,6,6,15,9,0,10,3,1,4,2,7,8,2,5,12,11,1,12,10,4,14,15,9,10,3,6,15,9,0,0,6,12,10,11,1,7,13,13,8,15,9,1,4,3,5,14,11,5,12,2,7,8,2,4,14,2,14,12,11,4,2,1,12,7,4,10,7,11,13,6,1,8,5,5,0,3,15,15,10,13,3,0,9,14,8,9,6,4,11,2,8,1,12,11,7,10,1,13,14,7,2,8,13,15,6,9,15,12,0,5,9,6,10,3,4,0,5,14,3,12,10,1,15,10,4,15,2,9,7,2,12,6,9,8,5,0,6,13,1,3,13,4,14,14,0,7,11,5,3,11,8,9,4,14,3,15,2,5,12,2,9,8,5,12,15,3,10,7,11,0,14,4,1,10,7,1,6,13,0,11,8,6,13,4,13,11,0,2,11,14,7,15,4,0,9,8,1,13,10,3,14,12,3,9,5,7,12,5,2,10,15,6,8,1,6,1,6,4,11,11,13,13,8,12,1,3,4,7,10,14,7,10,9,15,5,6,0,8,15,0,14,5,2,9,3,2,12,13,1,2,15,8,13,4,8,6,10,15,3,11,7,1,4,10,12,9,5,3,6,14,11,5,0,0,14,12,9,7,2,7,2,11,1,4,14,1,7,9,4,12,10,14,8,2,13,0,15,6,12,10,9,13,0,15,3,3,5,5,6,8,11];t.substitute=function(e,t){for(var r=0,n=0;n<4;n++){r<<=4,r|=a[64*n+(e>>>18-6*n&63)]}for(n=0;n<4;n++){r<<=4,r|=a[256+64*n+(t>>>18-6*n&63)]}return r>>>0};var i=[16,25,12,11,3,20,4,15,31,17,9,6,27,14,1,22,30,24,8,18,0,5,29,23,13,19,2,26,10,21,28,7];t.permute=function(e){for(var t=0,r=0;r>>i[r]&1;return t>>>0},t.padSplit=function(e,t,r){for(var n=e.toString(2);n.length>>1];r=i.r28shl(r,c),a=i.r28shl(a,c),i.pc2(r,a,e.keys,o)}},s.prototype._update=function(e,t,r,n){var a=this._desState,o=i.readUInt32BE(e,t),c=i.readUInt32BE(e,t+4);i.ip(o,c,a.tmp,0),o=a.tmp[0],c=a.tmp[1],"encrypt"===this.type?this._encrypt(a,o,c,a.tmp,0):this._decrypt(a,o,c,a.tmp,0),o=a.tmp[0],c=a.tmp[1],i.writeUInt32BE(r,o,n),i.writeUInt32BE(r,c,n+4)},s.prototype._pad=function(e,t){for(var r=e.length-t,n=t;n>>0,o=l}i.rip(c,o,n,a)},s.prototype._decrypt=function(e,t,r,n,a){for(var o=r,c=t,s=e.keys.length-2;s>=0;s-=2){var f=e.keys[s],d=e.keys[s+1];i.expand(o,e.tmp,0),f^=e.tmp[0],d^=e.tmp[1];var u=i.substitute(f,d),l=o;o=(c^i.permute(u))>>>0,c=l}i.rip(o,c,n,a)}},function(e,t,r){var n=r(202),a=r(42).Buffer,i=r(453);function o(e){var t=e._cipher.encryptBlockRaw(e._prev);return i(e._prev),t}t.encrypt=function(e,t){var r=Math.ceil(t.length/16),i=e._cache.length;e._cache=a.concat([e._cache,a.allocUnsafe(16*r)]);for(var c=0;ce;)r.ishrn(1);if(r.isEven()&&r.iadd(c),r.testn(1)||r.iadd(s),t.cmp(s)){if(!t.cmp(f))for(;r.mod(d).cmp(u);)r.iadd(b)}else for(;r.mod(i).cmp(l);)r.iadd(b);if(m(h=r.shrn(1))&&m(r)&&v(h)&&v(r)&&o.test(h)&&o.test(r))return r}}},function(e,t,r){var n=r(105),a=r(300);function i(e){this.rand=e||new a.Rand}e.exports=i,i.create=function(e){return new i(e)},i.prototype._randbelow=function(e){var t=e.bitLength(),r=Math.ceil(t/8);do{var a=new n(this.rand.generate(r))}while(a.cmp(e)>=0);return a},i.prototype._randrange=function(e,t){var r=t.sub(e);return e.add(this._randbelow(r))},i.prototype.test=function(e,t,r){var a=e.bitLength(),i=n.mont(e),o=new n(1).toRed(i);t||(t=Math.max(1,a/48|0));for(var c=e.subn(1),s=0;!c.testn(s);s++);for(var f=e.shrn(s),d=c.toRed(i);t>0;t--){var u=this._randrange(new n(2),c);r&&r(u);var l=u.toRed(i).redPow(f);if(0!==l.cmp(o)&&0!==l.cmp(d)){for(var b=1;b0;t--){var d=this._randrange(new n(2),o),u=e.gcd(d);if(0!==u.cmpn(1))return u;var l=d.toRed(a).redPow(s);if(0!==l.cmp(i)&&0!==l.cmp(f)){for(var b=1;b0)if("string"===typeof t||o.objectMode||Object.getPrototypeOf(t)===c.prototype||(t=function(e){return c.from(e)}(t)),n)o.endEmitted?k(e,new w):O(e,o,t,!0);else if(o.ended)k(e,new x);else{if(o.destroyed)return!1;o.reading=!1,o.decoder&&!r?(t=o.decoder.write(t),o.objectMode||0!==t.length?O(e,o,t,!1):P(e,o)):O(e,o,t,!1)}else n||(o.reading=!1,P(e,o));return!o.ended&&(o.lengtht.highWaterMark&&(t.highWaterMark=function(e){return e>=1073741824?e=1073741824:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function T(e){var t=e._readableState;f("emitReadable",t.needReadable,t.emittedReadable),t.needReadable=!1,t.emittedReadable||(f("emitReadable",t.flowing),t.emittedReadable=!0,n.nextTick(j,e))}function j(e){var t=e._readableState;f("emitReadable_",t.destroyed,t.length,t.ended),t.destroyed||!t.length&&!t.ended||(e.emit("readable"),t.emittedReadable=!1),t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark,L(e)}function P(e,t){t.readingMore||(t.readingMore=!0,n.nextTick(C,e,t))}function C(e,t){for(;!t.reading&&!t.ended&&(t.length0,t.resumeScheduled&&!t.paused?t.flowing=!0:e.listenerCount("data")>0&&e.resume()}function N(e){f("readable nexttick read 0"),e.read(0)}function B(e,t){f("resume",t.reading),t.reading||e.read(0),t.resumeScheduled=!1,e.emit("resume"),L(e),t.flowing&&!t.reading&&e.read(0)}function L(e){var t=e._readableState;for(f("flow",t.flowing);t.flowing&&null!==e.read(););}function I(e,t){return 0===t.length?null:(t.objectMode?r=t.buffer.shift():!e||e>=t.length?(r=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.first():t.buffer.concat(t.length),t.buffer.clear()):r=t.buffer.consume(e,t.decoder),r);var r}function F(e){var t=e._readableState;f("endReadable",t.endEmitted),t.endEmitted||(t.ended=!0,n.nextTick(D,t,e))}function D(e,t){if(f("endReadableNT",e.endEmitted,e.length),!e.endEmitted&&0===e.length&&(e.endEmitted=!0,t.readable=!1,t.emit("end"),e.autoDestroy)){var r=t._writableState;(!r||r.autoDestroy&&r.finished)&&t.destroy()}}function U(e,t){for(var r=0,n=e.length;r=t.highWaterMark:t.length>0)||t.ended))return f("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?F(this):T(this),null;if(0===(e=A(e,t))&&t.ended)return 0===t.length&&F(this),null;var n,a=t.needReadable;return f("need readable",a),(0===t.length||t.length-e0?I(e,t):null)?(t.needReadable=t.length<=t.highWaterMark,e=0):(t.length-=e,t.awaitDrain=0),0===t.length&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&F(this)),null!==n&&this.emit("data",n),n},S.prototype._read=function(e){k(this,new y("_read()"))},S.prototype.pipe=function(e,t){var r=this,a=this._readableState;switch(a.pipesCount){case 0:a.pipes=e;break;case 1:a.pipes=[a.pipes,e];break;default:a.pipes.push(e)}a.pipesCount+=1,f("pipe count=%d opts=%j",a.pipesCount,t);var o=(!t||!1!==t.end)&&e!==n.stdout&&e!==n.stderr?s:m;function c(t,n){f("onunpipe"),t===r&&n&&!1===n.hasUnpiped&&(n.hasUnpiped=!0,f("cleanup"),e.removeListener("close",h),e.removeListener("finish",p),e.removeListener("drain",d),e.removeListener("error",b),e.removeListener("unpipe",c),r.removeListener("end",s),r.removeListener("end",m),r.removeListener("data",l),u=!0,!a.awaitDrain||e._writableState&&!e._writableState.needDrain||d())}function s(){f("onend"),e.end()}a.endEmitted?n.nextTick(o):r.once("end",o),e.on("unpipe",c);var d=function(e){return function(){var t=e._readableState;f("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&i(e,"data")&&(t.flowing=!0,L(e))}}(r);e.on("drain",d);var u=!1;function l(t){f("ondata");var n=e.write(t);f("dest.write",n),!1===n&&((1===a.pipesCount&&a.pipes===e||a.pipesCount>1&&-1!==U(a.pipes,e))&&!u&&(f("false write response, pause",a.awaitDrain),a.awaitDrain++),r.pause())}function b(t){f("onerror",t),m(),e.removeListener("error",b),0===i(e,"error")&&k(e,t)}function h(){e.removeListener("finish",p),m()}function p(){f("onfinish"),e.removeListener("close",h),m()}function m(){f("unpipe"),r.unpipe(e)}return r.on("data",l),function(e,t,r){if("function"===typeof e.prependListener)return e.prependListener(t,r);e._events&&e._events[t]?Array.isArray(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]:e.on(t,r)}(e,"error",b),e.once("close",h),e.once("finish",p),e.emit("pipe",r),a.flowing||(f("pipe resume"),r.resume()),e},S.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes||(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r)),this;if(!e){var n=t.pipes,a=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var i=0;i0,!1!==a.flowing&&this.resume()):"readable"===e&&(a.endEmitted||a.readableListening||(a.readableListening=a.needReadable=!0,a.flowing=!1,a.emittedReadable=!1,f("on readable",a.length,a.reading),a.length?T(this):a.reading||n.nextTick(N,this))),r},S.prototype.addListener=S.prototype.on,S.prototype.removeListener=function(e,t){var r=o.prototype.removeListener.call(this,e,t);return"readable"===e&&n.nextTick(R,this),r},S.prototype.removeAllListeners=function(e){var t=o.prototype.removeAllListeners.apply(this,arguments);return"readable"!==e&&void 0!==e||n.nextTick(R,this),t},S.prototype.resume=function(){var e=this._readableState;return e.flowing||(f("resume"),e.flowing=!e.readableListening,function(e,t){t.resumeScheduled||(t.resumeScheduled=!0,n.nextTick(B,e,t))}(this,e)),e.paused=!1,this},S.prototype.pause=function(){return f("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(f("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},S.prototype.wrap=function(e){var t=this,r=this._readableState,n=!1;for(var a in e.on("end",(function(){if(f("wrapped end"),r.decoder&&!r.ended){var e=r.decoder.end();e&&e.length&&t.push(e)}t.push(null)})),e.on("data",(function(a){(f("wrapped data"),r.decoder&&(a=r.decoder.write(a)),!r.objectMode||null!==a&&void 0!==a)&&((r.objectMode||a&&a.length)&&(t.push(a)||(n=!0,e.pause())))})),e)void 0===this[a]&&"function"===typeof e[a]&&(this[a]=function(t){return function(){return e[t].apply(e,arguments)}}(a));for(var i=0;i<_.length;i++)e.on(_[i],this.emit.bind(this,_[i]));return this._read=function(t){f("wrapped _read",t),n&&(n=!1,e.resume())},this},"function"===typeof Symbol&&(S.prototype[Symbol.asyncIterator]=function(){return void 0===l&&(l=r(814)),l(this)}),Object.defineProperty(S.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),Object.defineProperty(S.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}}),Object.defineProperty(S.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(e){this._readableState&&(this._readableState.flowing=e)}}),S._fromList=I,Object.defineProperty(S.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}}),"function"===typeof Symbol&&(S.from=function(e,t){return void 0===b&&(b=r(815)),b(S,e,t)})}).call(this,r(44),r(48))},function(e,t,r){e.exports=r(91).EventEmitter},function(e,t,r){"use strict";(function(t){function r(e,t){a(e,t),n(e)}function n(e){e._writableState&&!e._writableState.emitClose||e._readableState&&!e._readableState.emitClose||e.emit("close")}function a(e,t){e.emit("error",t)}e.exports={destroy:function(e,i){var o=this,c=this._readableState&&this._readableState.destroyed,s=this._writableState&&this._writableState.destroyed;return c||s?(i?i(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,t.nextTick(a,this,e)):t.nextTick(a,this,e)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,(function(e){!i&&e?o._writableState?o._writableState.errorEmitted?t.nextTick(n,o):(o._writableState.errorEmitted=!0,t.nextTick(r,o,e)):t.nextTick(r,o,e):i?(t.nextTick(n,o),i(e)):t.nextTick(n,o)})),this)},undestroy:function(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)},errorOrDestroy:function(e,t){var r=e._readableState,n=e._writableState;r&&r.autoDestroy||n&&n.autoDestroy?e.destroy(t):e.emit("error",t)}}}).call(this,r(48))},function(e,t,r){"use strict";var n=r(174).codes.ERR_INVALID_OPT_VALUE;e.exports={getHighWaterMark:function(e,t,r,a){var i=function(e,t,r){return null!=e.highWaterMark?e.highWaterMark:t?e[r]:null}(t,a,r);if(null!=i){if(!isFinite(i)||Math.floor(i)!==i||i<0)throw new n(a?r:"highWaterMark",i);return Math.floor(i)}return e.objectMode?16:16384}}},function(e,t,r){"use strict";(function(t,n){function a(e){var t=this;this.next=null,this.entry=null,this.finish=function(){!function(e,t,r){var n=e.entry;e.entry=null;for(;n;){var a=n.callback;t.pendingcb--,a(r),n=n.next}t.corkedRequestsFree.next=e}(t,e)}}var i;e.exports=S,S.WritableState=M;var o={deprecate:r(239)},c=r(460),s=r(30).Buffer,f=t.Uint8Array||function(){};var d,u=r(461),l=r(462).getHighWaterMark,b=r(174).codes,h=b.ERR_INVALID_ARG_TYPE,p=b.ERR_METHOD_NOT_IMPLEMENTED,m=b.ERR_MULTIPLE_CALLBACK,v=b.ERR_STREAM_CANNOT_PIPE,g=b.ERR_STREAM_DESTROYED,x=b.ERR_STREAM_NULL_VALUES,y=b.ERR_STREAM_WRITE_AFTER_END,w=b.ERR_UNKNOWN_ENCODING,k=u.errorOrDestroy;function _(){}function M(e,t,o){i=i||r(175),e=e||{},"boolean"!==typeof o&&(o=t instanceof i),this.objectMode=!!e.objectMode,o&&(this.objectMode=this.objectMode||!!e.writableObjectMode),this.highWaterMark=l(this,e,"writableHighWaterMark",o),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var c=!1===e.decodeStrings;this.decodeStrings=!c,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){!function(e,t){var r=e._writableState,a=r.sync,i=r.writecb;if("function"!==typeof i)throw new m;if(function(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}(r),t)!function(e,t,r,a,i){--t.pendingcb,r?(n.nextTick(i,a),n.nextTick(P,e,t),e._writableState.errorEmitted=!0,k(e,a)):(i(a),e._writableState.errorEmitted=!0,k(e,a),P(e,t))}(e,r,a,t,i);else{var o=T(r)||e.destroyed;o||r.corked||r.bufferProcessing||!r.bufferedRequest||A(e,r),a?n.nextTick(O,e,r,o,i):O(e,r,o,i)}}(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new a(this)}function S(e){var t=this instanceof(i=i||r(175));if(!t&&!d.call(S,this))return new S(e);this._writableState=new M(e,this,t),this.writable=!0,e&&("function"===typeof e.write&&(this._write=e.write),"function"===typeof e.writev&&(this._writev=e.writev),"function"===typeof e.destroy&&(this._destroy=e.destroy),"function"===typeof e.final&&(this._final=e.final)),c.call(this)}function E(e,t,r,n,a,i,o){t.writelen=n,t.writecb=o,t.writing=!0,t.sync=!0,t.destroyed?t.onwrite(new g("write")):r?e._writev(a,t.onwrite):e._write(a,i,t.onwrite),t.sync=!1}function O(e,t,r,n){r||function(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}(e,t),t.pendingcb--,n(),P(e,t)}function A(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var n=t.bufferedRequestCount,i=new Array(n),o=t.corkedRequestsFree;o.entry=r;for(var c=0,s=!0;r;)i[c]=r,r.isBuf||(s=!1),r=r.next,c+=1;i.allBuffers=s,E(e,t,!0,t.length,i,"",o.finish),t.pendingcb++,t.lastBufferedRequest=null,o.next?(t.corkedRequestsFree=o.next,o.next=null):t.corkedRequestsFree=new a(t),t.bufferedRequestCount=0}else{for(;r;){var f=r.chunk,d=r.encoding,u=r.callback;if(E(e,t,!1,t.objectMode?1:f.length,f,d,u),r=r.next,t.bufferedRequestCount--,t.writing)break}null===r&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}function T(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function j(e,t){e._final((function(r){t.pendingcb--,r&&k(e,r),t.prefinished=!0,e.emit("prefinish"),P(e,t)}))}function P(e,t){var r=T(t);if(r&&(function(e,t){t.prefinished||t.finalCalled||("function"!==typeof e._final||t.destroyed?(t.prefinished=!0,e.emit("prefinish")):(t.pendingcb++,t.finalCalled=!0,n.nextTick(j,e,t)))}(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"),t.autoDestroy))){var a=e._readableState;(!a||a.autoDestroy&&a.endEmitted)&&e.destroy()}return r}r(33)(S,c),M.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t},function(){try{Object.defineProperty(M.prototype,"buffer",{get:o.deprecate((function(){return this.getBuffer()}),"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"===typeof Symbol&&Symbol.hasInstance&&"function"===typeof Function.prototype[Symbol.hasInstance]?(d=Function.prototype[Symbol.hasInstance],Object.defineProperty(S,Symbol.hasInstance,{value:function(e){return!!d.call(this,e)||this===S&&(e&&e._writableState instanceof M)}})):d=function(e){return e instanceof this},S.prototype.pipe=function(){k(this,new v)},S.prototype.write=function(e,t,r){var a,i=this._writableState,o=!1,c=!i.objectMode&&(a=e,s.isBuffer(a)||a instanceof f);return c&&!s.isBuffer(e)&&(e=function(e){return s.from(e)}(e)),"function"===typeof t&&(r=t,t=null),c?t="buffer":t||(t=i.defaultEncoding),"function"!==typeof r&&(r=_),i.ending?function(e,t){var r=new y;k(e,r),n.nextTick(t,r)}(this,r):(c||function(e,t,r,a){var i;return null===r?i=new x:"string"===typeof r||t.objectMode||(i=new h("chunk",["string","Buffer"],r)),!i||(k(e,i),n.nextTick(a,i),!1)}(this,i,e,r))&&(i.pendingcb++,o=function(e,t,r,n,a,i){if(!r){var o=function(e,t,r){e.objectMode||!1===e.decodeStrings||"string"!==typeof t||(t=s.from(t,r));return t}(t,n,a);n!==o&&(r=!0,a="buffer",n=o)}var c=t.objectMode?1:n.length;t.length+=c;var f=t.length-1))throw new w(e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(S.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(S.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),S.prototype._write=function(e,t,r){r(new p("_write()"))},S.prototype._writev=null,S.prototype.end=function(e,t,r){var a=this._writableState;return"function"===typeof e?(r=e,e=null,t=null):"function"===typeof t&&(r=t,t=null),null!==e&&void 0!==e&&this.write(e,t),a.corked&&(a.corked=1,this.uncork()),a.ending||function(e,t,r){t.ending=!0,P(e,t),r&&(t.finished?n.nextTick(r):e.once("finish",r));t.ended=!0,e.writable=!1}(this,a,r),this},Object.defineProperty(S.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(S.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),S.prototype.destroy=u.destroy,S.prototype._undestroy=u.undestroy,S.prototype._destroy=function(e,t){t(e)}}).call(this,r(44),r(48))},function(e,t,r){"use strict";e.exports=d;var n=r(174).codes,a=n.ERR_METHOD_NOT_IMPLEMENTED,i=n.ERR_MULTIPLE_CALLBACK,o=n.ERR_TRANSFORM_ALREADY_TRANSFORMING,c=n.ERR_TRANSFORM_WITH_LENGTH_0,s=r(175);function f(e,t){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(null===n)return this.emit("error",new i);r.writechunk=null,r.writecb=null,null!=t&&this.push(t),n(e);var a=this._readableState;a.reading=!1,(a.needReadable||a.length=48&&r<=57?r-48:r>=65&&r<=70?r-55:r>=97&&r<=102?r-87:void n(!1,"Invalid character in "+e)}function s(e,t,r){var n=c(e,r);return r-1>=t&&(n|=c(e,r-1)<<4),n}function f(e,t,r,a){for(var i=0,o=0,c=Math.min(e.length,r),s=t;s=49?f-49+10:f>=17?f-17+10:f,n(f>=0&&o0?e:t},i.min=function(e,t){return e.cmp(t)<0?e:t},i.prototype._init=function(e,t,r){if("number"===typeof e)return this._initNumber(e,t,r);if("object"===typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var a=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(a++,this.negative=1),a=0;a-=3)o=e[a]|e[a-1]<<8|e[a-2]<<16,this.words[i]|=o<>>26-c&67108863,(c+=24)>=26&&(c-=26,i++);else if("le"===r)for(a=0,i=0;a>>26-c&67108863,(c+=24)>=26&&(c-=26,i++);return this._strip()},i.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)a=s(e,t,n)<=18?(i-=18,o+=1,this.words[o]|=a>>>26):i+=8;else for(n=(e.length-t)%2===0?t+1:t;n=18?(i-=18,o+=1,this.words[o]|=a>>>26):i+=8;this._strip()},i.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,a=1;a<=67108863;a*=t)n++;n--,a=a/t|0;for(var i=e.length-r,o=i%n,c=Math.min(i,i-o)+r,s=0,d=r;d1&&0===this.words[this.length-1];)this.length--;return this._normSign()},i.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},"undefined"!==typeof Symbol&&"function"===typeof Symbol.for)try{i.prototype[Symbol.for("nodejs.util.inspect.custom")]=u}catch(A){i.prototype.inspect=u}else i.prototype.inspect=u;function u(){return(this.red?""}var l=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],b=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],h=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];i.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var a=0,i=0,o=0;o>>24-a&16777215)||o!==this.length-1?l[6-s.length]+s+r:s+r,(a+=2)>=26&&(a-=26,o--)}for(0!==i&&(r=i.toString(16)+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var f=b[e],d=h[e];r="";var u=this.clone();for(u.negative=0;!u.isZero();){var p=u.modrn(d).toString(e);r=(u=u.idivn(d)).isZero()?p+r:l[f-p.length]+p+r}for(this.isZero()&&(r="0"+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},i.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},i.prototype.toJSON=function(){return this.toString(16,2)},o&&(i.prototype.toBuffer=function(e,t){return this.toArrayLike(o,e,t)}),i.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)};function p(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var a=0|e.words[0],i=0|t.words[0],o=a*i,c=67108863&o,s=o/67108864|0;r.words[0]=c;for(var f=1;f>>26,u=67108863&s,l=Math.min(f,t.length-1),b=Math.max(0,f-e.length+1);b<=l;b++){var h=f-b|0;d+=(o=(a=0|e.words[h])*(i=0|t.words[b])+u)/67108864|0,u=67108863&o}r.words[f]=0|u,s=0|d}return 0!==s?r.words[f]=0|s:r.length--,r._strip()}i.prototype.toArrayLike=function(e,t,r){this._strip();var a=this.byteLength(),i=r||Math.max(1,a);n(a<=i,"byte array longer than desired length"),n(i>0,"Requested array length <= 0");var o=function(e,t){return e.allocUnsafe?e.allocUnsafe(t):new e(t)}(e,i);return this["_toArrayLike"+("le"===t?"LE":"BE")](o,a),o},i.prototype._toArrayLikeLE=function(e,t){for(var r=0,n=0,a=0,i=0;a>8&255),r>16&255),6===i?(r>24&255),n=0,i=0):(n=o>>>24,i+=2)}if(r=0&&(e[r--]=o>>8&255),r>=0&&(e[r--]=o>>16&255),6===i?(r>=0&&(e[r--]=o>>24&255),n=0,i=0):(n=o>>>24,i+=2)}if(r>=0)for(e[r--]=n;r>=0;)e[r--]=0},Math.clz32?i.prototype._countBits=function(e){return 32-Math.clz32(e)}:i.prototype._countBits=function(e){var t=e,r=0;return t>=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},i.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0===(8191&t)&&(r+=13,t>>>=13),0===(127&t)&&(r+=7,t>>>=7),0===(15&t)&&(r+=4,t>>>=4),0===(3&t)&&(r+=2,t>>>=2),0===(1&t)&&r++,r},i.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},i.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},i.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},i.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},i.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},i.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},i.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},i.prototype.inotn=function(e){n("number"===typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var a=0;a0&&(this.words[a]=~this.words[a]&67108863>>26-r),this._strip()},i.prototype.notn=function(e){return this.clone().inotn(e)},i.prototype.setn=function(e,t){n("number"===typeof e&&e>=0);var r=e/26|0,a=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var a=0,i=0;i>>26;for(;0!==a&&i>>26;if(this.length=r.length,0!==a)this.words[this.length]=a,this.length++;else if(r!==this)for(;ie.length?this.clone().iadd(e):e.clone().iadd(this)},i.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,a=this.cmp(e);if(0===a)return this.negative=0,this.length=1,this.words[0]=0,this;a>0?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>26,this.words[o]=67108863&t;for(;0!==i&&o>26,this.words[o]=67108863&t;if(0===i&&o>>13,b=0|o[1],h=8191&b,p=b>>>13,m=0|o[2],v=8191&m,g=m>>>13,x=0|o[3],y=8191&x,w=x>>>13,k=0|o[4],_=8191&k,M=k>>>13,S=0|o[5],E=8191&S,O=S>>>13,A=0|o[6],T=8191&A,j=A>>>13,P=0|o[7],C=8191&P,R=P>>>13,N=0|o[8],B=8191&N,L=N>>>13,I=0|o[9],F=8191&I,D=I>>>13,U=0|c[0],z=8191&U,H=U>>>13,q=0|c[1],J=8191&q,V=q>>>13,G=0|c[2],X=8191&G,K=G>>>13,W=0|c[3],Z=8191&W,$=W>>>13,Q=0|c[4],Y=8191&Q,ee=Q>>>13,te=0|c[5],re=8191&te,ne=te>>>13,ae=0|c[6],ie=8191&ae,oe=ae>>>13,ce=0|c[7],se=8191&ce,fe=ce>>>13,de=0|c[8],ue=8191&de,le=de>>>13,be=0|c[9],he=8191&be,pe=be>>>13;r.negative=e.negative^t.negative,r.length=19;var me=(f+(n=Math.imul(u,z))|0)+((8191&(a=(a=Math.imul(u,H))+Math.imul(l,z)|0))<<13)|0;f=((i=Math.imul(l,H))+(a>>>13)|0)+(me>>>26)|0,me&=67108863,n=Math.imul(h,z),a=(a=Math.imul(h,H))+Math.imul(p,z)|0,i=Math.imul(p,H);var ve=(f+(n=n+Math.imul(u,J)|0)|0)+((8191&(a=(a=a+Math.imul(u,V)|0)+Math.imul(l,J)|0))<<13)|0;f=((i=i+Math.imul(l,V)|0)+(a>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(v,z),a=(a=Math.imul(v,H))+Math.imul(g,z)|0,i=Math.imul(g,H),n=n+Math.imul(h,J)|0,a=(a=a+Math.imul(h,V)|0)+Math.imul(p,J)|0,i=i+Math.imul(p,V)|0;var ge=(f+(n=n+Math.imul(u,X)|0)|0)+((8191&(a=(a=a+Math.imul(u,K)|0)+Math.imul(l,X)|0))<<13)|0;f=((i=i+Math.imul(l,K)|0)+(a>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(y,z),a=(a=Math.imul(y,H))+Math.imul(w,z)|0,i=Math.imul(w,H),n=n+Math.imul(v,J)|0,a=(a=a+Math.imul(v,V)|0)+Math.imul(g,J)|0,i=i+Math.imul(g,V)|0,n=n+Math.imul(h,X)|0,a=(a=a+Math.imul(h,K)|0)+Math.imul(p,X)|0,i=i+Math.imul(p,K)|0;var xe=(f+(n=n+Math.imul(u,Z)|0)|0)+((8191&(a=(a=a+Math.imul(u,$)|0)+Math.imul(l,Z)|0))<<13)|0;f=((i=i+Math.imul(l,$)|0)+(a>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(_,z),a=(a=Math.imul(_,H))+Math.imul(M,z)|0,i=Math.imul(M,H),n=n+Math.imul(y,J)|0,a=(a=a+Math.imul(y,V)|0)+Math.imul(w,J)|0,i=i+Math.imul(w,V)|0,n=n+Math.imul(v,X)|0,a=(a=a+Math.imul(v,K)|0)+Math.imul(g,X)|0,i=i+Math.imul(g,K)|0,n=n+Math.imul(h,Z)|0,a=(a=a+Math.imul(h,$)|0)+Math.imul(p,Z)|0,i=i+Math.imul(p,$)|0;var ye=(f+(n=n+Math.imul(u,Y)|0)|0)+((8191&(a=(a=a+Math.imul(u,ee)|0)+Math.imul(l,Y)|0))<<13)|0;f=((i=i+Math.imul(l,ee)|0)+(a>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(E,z),a=(a=Math.imul(E,H))+Math.imul(O,z)|0,i=Math.imul(O,H),n=n+Math.imul(_,J)|0,a=(a=a+Math.imul(_,V)|0)+Math.imul(M,J)|0,i=i+Math.imul(M,V)|0,n=n+Math.imul(y,X)|0,a=(a=a+Math.imul(y,K)|0)+Math.imul(w,X)|0,i=i+Math.imul(w,K)|0,n=n+Math.imul(v,Z)|0,a=(a=a+Math.imul(v,$)|0)+Math.imul(g,Z)|0,i=i+Math.imul(g,$)|0,n=n+Math.imul(h,Y)|0,a=(a=a+Math.imul(h,ee)|0)+Math.imul(p,Y)|0,i=i+Math.imul(p,ee)|0;var we=(f+(n=n+Math.imul(u,re)|0)|0)+((8191&(a=(a=a+Math.imul(u,ne)|0)+Math.imul(l,re)|0))<<13)|0;f=((i=i+Math.imul(l,ne)|0)+(a>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(T,z),a=(a=Math.imul(T,H))+Math.imul(j,z)|0,i=Math.imul(j,H),n=n+Math.imul(E,J)|0,a=(a=a+Math.imul(E,V)|0)+Math.imul(O,J)|0,i=i+Math.imul(O,V)|0,n=n+Math.imul(_,X)|0,a=(a=a+Math.imul(_,K)|0)+Math.imul(M,X)|0,i=i+Math.imul(M,K)|0,n=n+Math.imul(y,Z)|0,a=(a=a+Math.imul(y,$)|0)+Math.imul(w,Z)|0,i=i+Math.imul(w,$)|0,n=n+Math.imul(v,Y)|0,a=(a=a+Math.imul(v,ee)|0)+Math.imul(g,Y)|0,i=i+Math.imul(g,ee)|0,n=n+Math.imul(h,re)|0,a=(a=a+Math.imul(h,ne)|0)+Math.imul(p,re)|0,i=i+Math.imul(p,ne)|0;var ke=(f+(n=n+Math.imul(u,ie)|0)|0)+((8191&(a=(a=a+Math.imul(u,oe)|0)+Math.imul(l,ie)|0))<<13)|0;f=((i=i+Math.imul(l,oe)|0)+(a>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(C,z),a=(a=Math.imul(C,H))+Math.imul(R,z)|0,i=Math.imul(R,H),n=n+Math.imul(T,J)|0,a=(a=a+Math.imul(T,V)|0)+Math.imul(j,J)|0,i=i+Math.imul(j,V)|0,n=n+Math.imul(E,X)|0,a=(a=a+Math.imul(E,K)|0)+Math.imul(O,X)|0,i=i+Math.imul(O,K)|0,n=n+Math.imul(_,Z)|0,a=(a=a+Math.imul(_,$)|0)+Math.imul(M,Z)|0,i=i+Math.imul(M,$)|0,n=n+Math.imul(y,Y)|0,a=(a=a+Math.imul(y,ee)|0)+Math.imul(w,Y)|0,i=i+Math.imul(w,ee)|0,n=n+Math.imul(v,re)|0,a=(a=a+Math.imul(v,ne)|0)+Math.imul(g,re)|0,i=i+Math.imul(g,ne)|0,n=n+Math.imul(h,ie)|0,a=(a=a+Math.imul(h,oe)|0)+Math.imul(p,ie)|0,i=i+Math.imul(p,oe)|0;var _e=(f+(n=n+Math.imul(u,se)|0)|0)+((8191&(a=(a=a+Math.imul(u,fe)|0)+Math.imul(l,se)|0))<<13)|0;f=((i=i+Math.imul(l,fe)|0)+(a>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(B,z),a=(a=Math.imul(B,H))+Math.imul(L,z)|0,i=Math.imul(L,H),n=n+Math.imul(C,J)|0,a=(a=a+Math.imul(C,V)|0)+Math.imul(R,J)|0,i=i+Math.imul(R,V)|0,n=n+Math.imul(T,X)|0,a=(a=a+Math.imul(T,K)|0)+Math.imul(j,X)|0,i=i+Math.imul(j,K)|0,n=n+Math.imul(E,Z)|0,a=(a=a+Math.imul(E,$)|0)+Math.imul(O,Z)|0,i=i+Math.imul(O,$)|0,n=n+Math.imul(_,Y)|0,a=(a=a+Math.imul(_,ee)|0)+Math.imul(M,Y)|0,i=i+Math.imul(M,ee)|0,n=n+Math.imul(y,re)|0,a=(a=a+Math.imul(y,ne)|0)+Math.imul(w,re)|0,i=i+Math.imul(w,ne)|0,n=n+Math.imul(v,ie)|0,a=(a=a+Math.imul(v,oe)|0)+Math.imul(g,ie)|0,i=i+Math.imul(g,oe)|0,n=n+Math.imul(h,se)|0,a=(a=a+Math.imul(h,fe)|0)+Math.imul(p,se)|0,i=i+Math.imul(p,fe)|0;var Me=(f+(n=n+Math.imul(u,ue)|0)|0)+((8191&(a=(a=a+Math.imul(u,le)|0)+Math.imul(l,ue)|0))<<13)|0;f=((i=i+Math.imul(l,le)|0)+(a>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,z),a=(a=Math.imul(F,H))+Math.imul(D,z)|0,i=Math.imul(D,H),n=n+Math.imul(B,J)|0,a=(a=a+Math.imul(B,V)|0)+Math.imul(L,J)|0,i=i+Math.imul(L,V)|0,n=n+Math.imul(C,X)|0,a=(a=a+Math.imul(C,K)|0)+Math.imul(R,X)|0,i=i+Math.imul(R,K)|0,n=n+Math.imul(T,Z)|0,a=(a=a+Math.imul(T,$)|0)+Math.imul(j,Z)|0,i=i+Math.imul(j,$)|0,n=n+Math.imul(E,Y)|0,a=(a=a+Math.imul(E,ee)|0)+Math.imul(O,Y)|0,i=i+Math.imul(O,ee)|0,n=n+Math.imul(_,re)|0,a=(a=a+Math.imul(_,ne)|0)+Math.imul(M,re)|0,i=i+Math.imul(M,ne)|0,n=n+Math.imul(y,ie)|0,a=(a=a+Math.imul(y,oe)|0)+Math.imul(w,ie)|0,i=i+Math.imul(w,oe)|0,n=n+Math.imul(v,se)|0,a=(a=a+Math.imul(v,fe)|0)+Math.imul(g,se)|0,i=i+Math.imul(g,fe)|0,n=n+Math.imul(h,ue)|0,a=(a=a+Math.imul(h,le)|0)+Math.imul(p,ue)|0,i=i+Math.imul(p,le)|0;var Se=(f+(n=n+Math.imul(u,he)|0)|0)+((8191&(a=(a=a+Math.imul(u,pe)|0)+Math.imul(l,he)|0))<<13)|0;f=((i=i+Math.imul(l,pe)|0)+(a>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(F,J),a=(a=Math.imul(F,V))+Math.imul(D,J)|0,i=Math.imul(D,V),n=n+Math.imul(B,X)|0,a=(a=a+Math.imul(B,K)|0)+Math.imul(L,X)|0,i=i+Math.imul(L,K)|0,n=n+Math.imul(C,Z)|0,a=(a=a+Math.imul(C,$)|0)+Math.imul(R,Z)|0,i=i+Math.imul(R,$)|0,n=n+Math.imul(T,Y)|0,a=(a=a+Math.imul(T,ee)|0)+Math.imul(j,Y)|0,i=i+Math.imul(j,ee)|0,n=n+Math.imul(E,re)|0,a=(a=a+Math.imul(E,ne)|0)+Math.imul(O,re)|0,i=i+Math.imul(O,ne)|0,n=n+Math.imul(_,ie)|0,a=(a=a+Math.imul(_,oe)|0)+Math.imul(M,ie)|0,i=i+Math.imul(M,oe)|0,n=n+Math.imul(y,se)|0,a=(a=a+Math.imul(y,fe)|0)+Math.imul(w,se)|0,i=i+Math.imul(w,fe)|0,n=n+Math.imul(v,ue)|0,a=(a=a+Math.imul(v,le)|0)+Math.imul(g,ue)|0,i=i+Math.imul(g,le)|0;var Ee=(f+(n=n+Math.imul(h,he)|0)|0)+((8191&(a=(a=a+Math.imul(h,pe)|0)+Math.imul(p,he)|0))<<13)|0;f=((i=i+Math.imul(p,pe)|0)+(a>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,X),a=(a=Math.imul(F,K))+Math.imul(D,X)|0,i=Math.imul(D,K),n=n+Math.imul(B,Z)|0,a=(a=a+Math.imul(B,$)|0)+Math.imul(L,Z)|0,i=i+Math.imul(L,$)|0,n=n+Math.imul(C,Y)|0,a=(a=a+Math.imul(C,ee)|0)+Math.imul(R,Y)|0,i=i+Math.imul(R,ee)|0,n=n+Math.imul(T,re)|0,a=(a=a+Math.imul(T,ne)|0)+Math.imul(j,re)|0,i=i+Math.imul(j,ne)|0,n=n+Math.imul(E,ie)|0,a=(a=a+Math.imul(E,oe)|0)+Math.imul(O,ie)|0,i=i+Math.imul(O,oe)|0,n=n+Math.imul(_,se)|0,a=(a=a+Math.imul(_,fe)|0)+Math.imul(M,se)|0,i=i+Math.imul(M,fe)|0,n=n+Math.imul(y,ue)|0,a=(a=a+Math.imul(y,le)|0)+Math.imul(w,ue)|0,i=i+Math.imul(w,le)|0;var Oe=(f+(n=n+Math.imul(v,he)|0)|0)+((8191&(a=(a=a+Math.imul(v,pe)|0)+Math.imul(g,he)|0))<<13)|0;f=((i=i+Math.imul(g,pe)|0)+(a>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,Z),a=(a=Math.imul(F,$))+Math.imul(D,Z)|0,i=Math.imul(D,$),n=n+Math.imul(B,Y)|0,a=(a=a+Math.imul(B,ee)|0)+Math.imul(L,Y)|0,i=i+Math.imul(L,ee)|0,n=n+Math.imul(C,re)|0,a=(a=a+Math.imul(C,ne)|0)+Math.imul(R,re)|0,i=i+Math.imul(R,ne)|0,n=n+Math.imul(T,ie)|0,a=(a=a+Math.imul(T,oe)|0)+Math.imul(j,ie)|0,i=i+Math.imul(j,oe)|0,n=n+Math.imul(E,se)|0,a=(a=a+Math.imul(E,fe)|0)+Math.imul(O,se)|0,i=i+Math.imul(O,fe)|0,n=n+Math.imul(_,ue)|0,a=(a=a+Math.imul(_,le)|0)+Math.imul(M,ue)|0,i=i+Math.imul(M,le)|0;var Ae=(f+(n=n+Math.imul(y,he)|0)|0)+((8191&(a=(a=a+Math.imul(y,pe)|0)+Math.imul(w,he)|0))<<13)|0;f=((i=i+Math.imul(w,pe)|0)+(a>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(F,Y),a=(a=Math.imul(F,ee))+Math.imul(D,Y)|0,i=Math.imul(D,ee),n=n+Math.imul(B,re)|0,a=(a=a+Math.imul(B,ne)|0)+Math.imul(L,re)|0,i=i+Math.imul(L,ne)|0,n=n+Math.imul(C,ie)|0,a=(a=a+Math.imul(C,oe)|0)+Math.imul(R,ie)|0,i=i+Math.imul(R,oe)|0,n=n+Math.imul(T,se)|0,a=(a=a+Math.imul(T,fe)|0)+Math.imul(j,se)|0,i=i+Math.imul(j,fe)|0,n=n+Math.imul(E,ue)|0,a=(a=a+Math.imul(E,le)|0)+Math.imul(O,ue)|0,i=i+Math.imul(O,le)|0;var Te=(f+(n=n+Math.imul(_,he)|0)|0)+((8191&(a=(a=a+Math.imul(_,pe)|0)+Math.imul(M,he)|0))<<13)|0;f=((i=i+Math.imul(M,pe)|0)+(a>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,re),a=(a=Math.imul(F,ne))+Math.imul(D,re)|0,i=Math.imul(D,ne),n=n+Math.imul(B,ie)|0,a=(a=a+Math.imul(B,oe)|0)+Math.imul(L,ie)|0,i=i+Math.imul(L,oe)|0,n=n+Math.imul(C,se)|0,a=(a=a+Math.imul(C,fe)|0)+Math.imul(R,se)|0,i=i+Math.imul(R,fe)|0,n=n+Math.imul(T,ue)|0,a=(a=a+Math.imul(T,le)|0)+Math.imul(j,ue)|0,i=i+Math.imul(j,le)|0;var je=(f+(n=n+Math.imul(E,he)|0)|0)+((8191&(a=(a=a+Math.imul(E,pe)|0)+Math.imul(O,he)|0))<<13)|0;f=((i=i+Math.imul(O,pe)|0)+(a>>>13)|0)+(je>>>26)|0,je&=67108863,n=Math.imul(F,ie),a=(a=Math.imul(F,oe))+Math.imul(D,ie)|0,i=Math.imul(D,oe),n=n+Math.imul(B,se)|0,a=(a=a+Math.imul(B,fe)|0)+Math.imul(L,se)|0,i=i+Math.imul(L,fe)|0,n=n+Math.imul(C,ue)|0,a=(a=a+Math.imul(C,le)|0)+Math.imul(R,ue)|0,i=i+Math.imul(R,le)|0;var Pe=(f+(n=n+Math.imul(T,he)|0)|0)+((8191&(a=(a=a+Math.imul(T,pe)|0)+Math.imul(j,he)|0))<<13)|0;f=((i=i+Math.imul(j,pe)|0)+(a>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,se),a=(a=Math.imul(F,fe))+Math.imul(D,se)|0,i=Math.imul(D,fe),n=n+Math.imul(B,ue)|0,a=(a=a+Math.imul(B,le)|0)+Math.imul(L,ue)|0,i=i+Math.imul(L,le)|0;var Ce=(f+(n=n+Math.imul(C,he)|0)|0)+((8191&(a=(a=a+Math.imul(C,pe)|0)+Math.imul(R,he)|0))<<13)|0;f=((i=i+Math.imul(R,pe)|0)+(a>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,n=Math.imul(F,ue),a=(a=Math.imul(F,le))+Math.imul(D,ue)|0,i=Math.imul(D,le);var Re=(f+(n=n+Math.imul(B,he)|0)|0)+((8191&(a=(a=a+Math.imul(B,pe)|0)+Math.imul(L,he)|0))<<13)|0;f=((i=i+Math.imul(L,pe)|0)+(a>>>13)|0)+(Re>>>26)|0,Re&=67108863;var Ne=(f+(n=Math.imul(F,he))|0)+((8191&(a=(a=Math.imul(F,pe))+Math.imul(D,he)|0))<<13)|0;return f=((i=Math.imul(D,pe))+(a>>>13)|0)+(Ne>>>26)|0,Ne&=67108863,s[0]=me,s[1]=ve,s[2]=ge,s[3]=xe,s[4]=ye,s[5]=we,s[6]=ke,s[7]=_e,s[8]=Me,s[9]=Se,s[10]=Ee,s[11]=Oe,s[12]=Ae,s[13]=Te,s[14]=je,s[15]=Pe,s[16]=Ce,s[17]=Re,s[18]=Ne,0!==f&&(s[19]=f,r.length++),r};function v(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,a=0,i=0;i>>26)|0)>>>26,o&=67108863}r.words[i]=c,n=o,o=a}return 0!==n?r.words[i]=n:r.length--,r._strip()}function g(e,t,r){return v(e,t,r)}function x(e,t){this.x=e,this.y=t}Math.imul||(m=p),i.prototype.mulTo=function(e,t){var r=this.length+e.length;return 10===this.length&&10===e.length?m(this,e,t):r<63?p(this,e,t):r<1024?v(this,e,t):g(this,e,t)},x.prototype.makeRBT=function(e){for(var t=new Array(e),r=i.prototype._countBits(e)-1,n=0;n>=1;return n},x.prototype.permute=function(e,t,r,n,a,i){for(var o=0;o>>=1)a++;return 1<>>=13,r[2*o+1]=8191&i,i>>>=13;for(o=2*t;o>=26,r+=i/67108864|0,r+=o>>>26,this.words[a]=67108863&o}return 0!==r&&(this.words[a]=r,this.length++),t?this.ineg():this},i.prototype.muln=function(e){return this.clone().imuln(e)},i.prototype.sqr=function(){return this.mul(this)},i.prototype.isqr=function(){return this.imul(this.clone())},i.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>a&1}return t}(e);if(0===t.length)return new i(1);for(var r=this,n=0;n=0);var t,r=e%26,a=(e-r)/26,i=67108863>>>26-r<<26-r;if(0!==r){var o=0;for(t=0;t>>26-r}o&&(this.words[t]=o,this.length++)}if(0!==a){for(t=this.length-1;t>=0;t--)this.words[t+a]=this.words[t];for(t=0;t=0),a=t?(t-t%26)/26:0;var i=e%26,o=Math.min((e-i)/26,this.length),c=67108863^67108863>>>i<o)for(this.length-=o,f=0;f=0&&(0!==d||f>=a);f--){var u=0|this.words[f];this.words[f]=d<<26-i|u>>>i,d=u&c}return s&&0!==d&&(s.words[s.length++]=d),0===this.length&&(this.words[0]=0,this.length=1),this._strip()},i.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},i.prototype.shln=function(e){return this.clone().ishln(e)},i.prototype.ushln=function(e){return this.clone().iushln(e)},i.prototype.shrn=function(e){return this.clone().ishrn(e)},i.prototype.ushrn=function(e){return this.clone().iushrn(e)},i.prototype.testn=function(e){n("number"===typeof e&&e>=0);var t=e%26,r=(e-t)/26,a=1<=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var a=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},i.prototype.isubn=function(e){if(n("number"===typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(s/67108864|0),this.words[a+r]=67108863&i}for(;a>26,this.words[a+r]=67108863&i;if(0===c)return this._strip();for(n(-1===c),c=0,a=0;a>26,this.words[a]=67108863&i;return this.negative=1,this._strip()},i.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),a=e,o=0|a.words[a.length-1];0!==(r=26-this._countBits(o))&&(a=a.ushln(r),n.iushln(r),o=0|a.words[a.length-1]);var c,s=n.length-a.length;if("mod"!==t){(c=new i(null)).length=s+1,c.words=new Array(c.length);for(var f=0;f=0;u--){var l=67108864*(0|n.words[a.length+u])+(0|n.words[a.length+u-1]);for(l=Math.min(l/o|0,67108863),n._ishlnsubmul(a,l,u);0!==n.negative;)l--,n.negative=0,n._ishlnsubmul(a,1,u),n.isZero()||(n.negative^=1);c&&(c.words[u]=l)}return c&&c._strip(),n._strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:c||null,mod:n}},i.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new i(0),mod:new i(0)}:0!==this.negative&&0===e.negative?(c=this.neg().divmod(e,t),"mod"!==t&&(a=c.div.neg()),"div"!==t&&(o=c.mod.neg(),r&&0!==o.negative&&o.iadd(e)),{div:a,mod:o}):0===this.negative&&0!==e.negative?(c=this.divmod(e.neg(),t),"mod"!==t&&(a=c.div.neg()),{div:a,mod:c.mod}):0!==(this.negative&e.negative)?(c=this.neg().divmod(e.neg(),t),"div"!==t&&(o=c.mod.neg(),r&&0!==o.negative&&o.isub(e)),{div:c.div,mod:o}):e.length>this.length||this.cmp(e)<0?{div:new i(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new i(this.modrn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new i(this.modrn(e.words[0]))}:this._wordDiv(e,t);var a,o,c},i.prototype.div=function(e){return this.divmod(e,"div",!1).div},i.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},i.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},i.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),a=e.andln(1),i=r.cmp(n);return i<0||1===a&&0===i?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},i.prototype.modrn=function(e){var t=e<0;t&&(e=-e),n(e<=67108863);for(var r=(1<<26)%e,a=0,i=this.length-1;i>=0;i--)a=(r*a+(0|this.words[i]))%e;return t?-a:a},i.prototype.modn=function(e){return this.modrn(e)},i.prototype.idivn=function(e){var t=e<0;t&&(e=-e),n(e<=67108863);for(var r=0,a=this.length-1;a>=0;a--){var i=(0|this.words[a])+67108864*r;this.words[a]=i/e|0,r=i%e}return this._strip(),t?this.ineg():this},i.prototype.divn=function(e){return this.clone().idivn(e)},i.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var a=new i(1),o=new i(0),c=new i(0),s=new i(1),f=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++f;for(var d=r.clone(),u=t.clone();!t.isZero();){for(var l=0,b=1;0===(t.words[0]&b)&&l<26;++l,b<<=1);if(l>0)for(t.iushrn(l);l-- >0;)(a.isOdd()||o.isOdd())&&(a.iadd(d),o.isub(u)),a.iushrn(1),o.iushrn(1);for(var h=0,p=1;0===(r.words[0]&p)&&h<26;++h,p<<=1);if(h>0)for(r.iushrn(h);h-- >0;)(c.isOdd()||s.isOdd())&&(c.iadd(d),s.isub(u)),c.iushrn(1),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(c),o.isub(s)):(r.isub(t),c.isub(a),s.isub(o))}return{a:c,b:s,gcd:r.iushln(f)}},i.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var a,o=new i(1),c=new i(0),s=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var f=0,d=1;0===(t.words[0]&d)&&f<26;++f,d<<=1);if(f>0)for(t.iushrn(f);f-- >0;)o.isOdd()&&o.iadd(s),o.iushrn(1);for(var u=0,l=1;0===(r.words[0]&l)&&u<26;++u,l<<=1);if(u>0)for(r.iushrn(u);u-- >0;)c.isOdd()&&c.iadd(s),c.iushrn(1);t.cmp(r)>=0?(t.isub(r),o.isub(c)):(r.isub(t),c.isub(o))}return(a=0===t.cmpn(1)?o:c).cmpn(0)<0&&a.iadd(e),a},i.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var a=t.cmp(r);if(a<0){var i=t;t=r,r=i}else if(0===a||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},i.prototype.invm=function(e){return this.egcd(e).a.umod(e)},i.prototype.isEven=function(){return 0===(1&this.words[0])},i.prototype.isOdd=function(){return 1===(1&this.words[0])},i.prototype.andln=function(e){return this.words[0]&e},i.prototype.bincn=function(e){n("number"===typeof e);var t=e%26,r=(e-t)/26,a=1<>>26,c&=67108863,this.words[o]=c}return 0!==i&&(this.words[o]=i,this.length++),this},i.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},i.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this._strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var a=0|this.words[0];t=a===e?0:ae.length)return 1;if(this.length=0;r--){var n=0|this.words[r],a=0|e.words[r];if(n!==a){na&&(t=1);break}}return t},i.prototype.gtn=function(e){return 1===this.cmpn(e)},i.prototype.gt=function(e){return 1===this.cmp(e)},i.prototype.gten=function(e){return this.cmpn(e)>=0},i.prototype.gte=function(e){return this.cmp(e)>=0},i.prototype.ltn=function(e){return-1===this.cmpn(e)},i.prototype.lt=function(e){return-1===this.cmp(e)},i.prototype.lten=function(e){return this.cmpn(e)<=0},i.prototype.lte=function(e){return this.cmp(e)<=0},i.prototype.eqn=function(e){return 0===this.cmpn(e)},i.prototype.eq=function(e){return 0===this.cmp(e)},i.red=function(e){return new E(e)},i.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},i.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},i.prototype._forceRed=function(e){return this.red=e,this},i.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},i.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},i.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},i.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},i.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},i.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},i.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},i.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},i.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},i.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},i.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},i.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},i.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},i.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var y={k256:null,p224:null,p192:null,p25519:null};function w(e,t){this.name=e,this.p=new i(t,16),this.n=this.p.bitLength(),this.k=new i(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function k(){w.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function _(){w.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function M(){w.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function S(){w.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function E(e){if("string"===typeof e){var t=i._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function O(e){E.call(this,e),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new i(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}w.prototype._tmp=function(){var e=new i(null);return e.words=new Array(Math.ceil(this.n/13)),e},w.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},w.prototype.split=function(e,t){e.iushrn(this.n,0,t)},w.prototype.imulK=function(e){return e.imul(this.k)},a(k,w),k.prototype.split=function(e,t){for(var r=Math.min(e.length,9),n=0;n>>22,a=i}a>>>=22,e.words[n-10]=a,0===a&&e.length>10?e.length-=10:e.length-=9},k.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=a,t=n}return 0!==t&&(e.words[e.length++]=t),e},i._prime=function(e){if(y[e])return y[e];var t;if("k256"===e)t=new k;else if("p224"===e)t=new _;else if("p192"===e)t=new M;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new S}return y[e]=t,t},E.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},E.prototype._verify2=function(e,t){n(0===(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},E.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):(d(e,e.umod(this.m)._forceRed(this)),e)},E.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},E.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},E.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},E.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},E.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},E.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},E.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},E.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},E.prototype.isqr=function(e){return this.imul(e,e.clone())},E.prototype.sqr=function(e){return this.mul(e,e)},E.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2===1),3===t){var r=this.m.add(new i(1)).iushrn(2);return this.pow(e,r)}for(var a=this.m.subn(1),o=0;!a.isZero()&&0===a.andln(1);)o++,a.iushrn(1);n(!a.isZero());var c=new i(1).toRed(this),s=c.redNeg(),f=this.m.subn(1).iushrn(1),d=this.m.bitLength();for(d=new i(2*d*d).toRed(this);0!==this.pow(d,f).cmp(s);)d.redIAdd(s);for(var u=this.pow(d,a),l=this.pow(e,a.addn(1).iushrn(1)),b=this.pow(e,a),h=o;0!==b.cmp(c);){for(var p=b,m=0;0!==p.cmp(c);m++)p=p.redSqr();n(m=0;n--){for(var f=t.words[n],d=s-1;d>=0;d--){var u=f>>d&1;a!==r[0]&&(a=this.sqr(a)),0!==u||0!==o?(o<<=1,o|=u,(4===++c||0===n&&0===d)&&(a=this.mul(a,r[o]),c=0,o=0)):c=0}s=26}return a},E.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},E.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},i.mont=function(e){return new O(e)},a(O,E),O.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},O.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},O.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),a=r.isub(n).iushrn(this.shift),i=a;return a.cmp(this.m)>=0?i=a.isub(this.m):a.cmpn(0)<0&&(i=a.iadd(this.m)),i._forceRed(this)},O.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new i(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),a=r.isub(n).iushrn(this.shift),o=a;return a.cmp(this.m)>=0?o=a.isub(this.m):a.cmpn(0)<0&&(o=a.iadd(this.m)),o._forceRed(this)},O.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e,this)}).call(this,r(74)(e))},function(e,t,r){"use strict";var n=t;n.bignum=r(105),n.define=r(823).define,n.base=r(826),n.constants=r(827),n.decoders=r(469),n.encoders=r(467)},function(e,t,r){"use strict";var n=t;n.der=r(468),n.pem=r(824)},function(e,t,r){"use strict";var n=r(33),a=r(319).Buffer,i=r(320),o=r(322);function c(e){this.enc="der",this.name=e.name,this.entity=e,this.tree=new s,this.tree._init(e.body)}function s(e){i.call(this,"der",e)}function f(e){return e<10?"0"+e:e}e.exports=c,c.prototype.encode=function(e,t){return this.tree._encode(e,t).join()},n(s,i),s.prototype._encodeComposite=function(e,t,r,n){var i=function(e,t,r,n){var a;"seqof"===e?e="seq":"setof"===e&&(e="set");if(o.tagByName.hasOwnProperty(e))a=o.tagByName[e];else{if("number"!==typeof e||(0|e)!==e)return n.error("Unknown tag: "+e);a=e}if(a>=31)return n.error("Multi-octet tag encoding unsupported");t||(a|=32);return a|=o.tagClassByName[r||"universal"]<<6}(e,t,r,this.reporter);if(n.length<128){var c=a.alloc(2);return c[0]=i,c[1]=n.length,this._createEncoderBuffer([c,n])}for(var s=1,f=n.length;f>=256;f>>=8)s++;var d=a.alloc(2+s);d[0]=i,d[1]=128|s;for(var u=1+s,l=n.length;l>0;u--,l>>=8)d[u]=255&l;return this._createEncoderBuffer([d,n])},s.prototype._encodeStr=function(e,t){if("bitstr"===t)return this._createEncoderBuffer([0|e.unused,e.data]);if("bmpstr"===t){for(var r=a.alloc(2*e.length),n=0;n=40)return this.reporter.error("Second objid identifier OOB");e.splice(0,2,40*e[0]+e[1])}for(var o=0,c=0;c=128;s>>=7)o++}for(var f=a.alloc(o),d=f.length-1,u=e.length-1;u>=0;u--){var l=e[u];for(f[d--]=127&l;(l>>=7)>0;)f[d--]=128|127&l}return this._createEncoderBuffer(f)},s.prototype._encodeTime=function(e,t){var r,n=new Date(e);return"gentime"===t?r=[f(n.getUTCFullYear()),f(n.getUTCMonth()+1),f(n.getUTCDate()),f(n.getUTCHours()),f(n.getUTCMinutes()),f(n.getUTCSeconds()),"Z"].join(""):"utctime"===t?r=[f(n.getUTCFullYear()%100),f(n.getUTCMonth()+1),f(n.getUTCDate()),f(n.getUTCHours()),f(n.getUTCMinutes()),f(n.getUTCSeconds()),"Z"].join(""):this.reporter.error("Encoding "+t+" time is not supported yet"),this._encodeStr(r,"octstr")},s.prototype._encodeNull=function(){return this._createEncoderBuffer("")},s.prototype._encodeInt=function(e,t){if("string"===typeof e){if(!t)return this.reporter.error("String int or enum given, but no values map");if(!t.hasOwnProperty(e))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(e));e=t[e]}if("number"!==typeof e&&!a.isBuffer(e)){var r=e.toArray();!e.sign&&128&r[0]&&r.unshift(0),e=a.from(r)}if(a.isBuffer(e)){var n=e.length;0===e.length&&n++;var i=a.alloc(n);return e.copy(i),0===e.length&&(i[0]=0),this._createEncoderBuffer(i)}if(e<128)return this._createEncoderBuffer(e);if(e<256)return this._createEncoderBuffer([0,e]);for(var o=1,c=e;c>=256;c>>=8)o++;for(var s=new Array(o),f=s.length-1;f>=0;f--)s[f]=255&e,e>>=8;return 128&s[0]&&s.unshift(0),this._createEncoderBuffer(a.from(s))},s.prototype._encodeBool=function(e){return this._createEncoderBuffer(e?255:0)},s.prototype._use=function(e,t){return"function"===typeof e&&(e=e(t)),e._getEncoder("der").tree},s.prototype._skipDefault=function(e,t,r){var n,a=this._baseState;if(null===a.default)return!1;var i=e.join();if(void 0===a.defaultBuffer&&(a.defaultBuffer=this._encodeValue(a.default,t,r).join()),i.length!==a.defaultBuffer.length)return!1;for(n=0;n>6],a=0===(32&r);if(31===(31&r)){var i=r;for(r=0;128===(128&i);){if(i=e.readUInt8(t),e.isError(i))return i;r<<=7,r|=127&i}}else r&=31;return{cls:n,primitive:a,tag:r,tagStr:c.tag[r]}}function u(e,t,r){var n=e.readUInt8(r);if(e.isError(n))return n;if(!t&&128===n)return null;if(0===(128&n))return n;var a=127&n;if(a>4)return e.error("length octect is too long");n=0;for(var i=0;i>>((3&t)<<3)&255;return a}}},function(e,t){for(var r=[],n=0;n<256;++n)r[n]=(n+256).toString(16).substr(1);e.exports=function(e,t){var n=t||0,a=r;return[a[e[n++]],a[e[n++]],a[e[n++]],a[e[n++]],"-",a[e[n++]],a[e[n++]],"-",a[e[n++]],a[e[n++]],"-",a[e[n++]],a[e[n++]],"-",a[e[n++]],a[e[n++]],a[e[n++]],a[e[n++]],a[e[n++]],a[e[n++]]].join("")}},function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r),Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[r]}})}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),a=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)},i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.FeeMarketEIP1559Transaction=t.TransactionFactory=t.AccessListEIP2930Transaction=t.Transaction=void 0;var o=r(843);Object.defineProperty(t,"Transaction",{enumerable:!0,get:function(){return i(o).default}});var c=r(886);Object.defineProperty(t,"AccessListEIP2930Transaction",{enumerable:!0,get:function(){return i(c).default}});var s=r(887);Object.defineProperty(t,"TransactionFactory",{enumerable:!0,get:function(){return i(s).default}});var f=r(888);Object.defineProperty(t,"FeeMarketEIP1559Transaction",{enumerable:!0,get:function(){return i(f).default}}),a(r(176),t)},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AccessLists=void 0;var n=r(107),a=r(176),i=function(){function e(){}return e.getAccessListData=function(e){var t,r;if(e&&(0,a.isAccessList)(e)){t=e;for(var i=[],o=0;o>6|192);else{if(a>55295&&a<56320){if(++n==e.length)return null;var i=e.charCodeAt(n);if(i<56320||i>57343)return null;r+=t((a=65536+((1023&a)<<10)+(1023&i))>>18|240),r+=t(a>>12&63|128)}else r+=t(a>>12|224);r+=t(a>>6&63|128)}r+=t(63&a|128)}}return r},toString:function(e){for(var t="",r=0,i=a(e);r127){if(o>191&&o<224){if(r>=i)return null;o=(31&o)<<6|63&n(e,r)}else if(o>223&&o<240){if(r+1>=i)return null;o=(15&o)<<12|(63&n(e,r))<<6|63&n(e,++r)}else{if(!(o>239&&o<248))return null;if(r+2>=i)return null;o=(7&o)<<18|(63&n(e,r))<<12|(63&n(e,++r))<<6|63&n(e,++r)}++r}if(o<=65535)t+=String.fromCharCode(o);else{if(!(o<=1114111))return null;o-=65536,t+=String.fromCharCode(o>>10|55296),t+=String.fromCharCode(1023&o|56320)}}return t},fromNumber:function(e){var t=e.toString(16);return t.length%2===0?"0x"+t:"0x0"+t},toNumber:function(e){return parseInt(e.slice(2),16)},fromNat:function(e){return"0x0"===e?"0x":e.length%2===0?e:"0x0"+e.slice(2)},toNat:function(e){return"0"===e[2]?"0x"+e.slice(3):e},fromArray:o,toArray:i,fromUint8Array:function(e){return o([].slice.call(e,0))},toUint8Array:function(e){return new Uint8Array(i(e))}}},function(e,t,r){"use strict";r.d(t,"a",(function(){return j}));var n=r(2),a=r.n(n),i=r(6),o=r(7),c=r(53),s=r(51),f=r(10),d=r(49),u=r(15),l=r(16),b=r(274),h=r(128),p=function(e,t,r,n){return new(r||(r=Promise))((function(a,i){function o(e){try{s(n.next(e))}catch(t){i(t)}}function c(e){try{s(n.throw(e))}catch(t){i(t)}}function s(e){var t;e.done?a(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(o,c)}s((n=n.apply(e,t||[])).next())}))},m=new l.Logger(b.a),v=new Uint8Array(32);v.fill(0);var g=s.a.from(-1),x=s.a.from(0),y=s.a.from(1),w=s.a.from("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");var k=Object(f.hexZeroPad)(y.toHexString(),32),_=Object(f.hexZeroPad)(x.toHexString(),32),M={name:"string",version:"string",chainId:"uint256",verifyingContract:"address",salt:"bytes32"},S=["name","version","chainId","verifyingContract","salt"];function E(e){return function(t){return"string"!==typeof t&&m.throwArgumentError("invalid domain value for ".concat(JSON.stringify(e)),"domain.".concat(e),t),t}}var O={name:E("name"),version:E("version"),chainId:function(e){try{return s.a.from(e).toString()}catch(t){}return m.throwArgumentError('invalid domain value for "chainId"',"domain.chainId",e)},verifyingContract:function(e){try{return Object(c.getAddress)(e).toLowerCase()}catch(t){}return m.throwArgumentError('invalid domain value "verifyingContract"',"domain.verifyingContract",e)},salt:function(e){try{var t=Object(f.arrayify)(e);if(32!==t.length)throw new Error("bad length");return Object(f.hexlify)(t)}catch(r){}return m.throwArgumentError('invalid domain value "salt"',"domain.salt",e)}};function A(e){var t=e.match(/^(u?)int(\d*)$/);if(t){var r=""===t[1],n=parseInt(t[2]||"256");(n%8!==0||n>256||t[2]&&t[2]!==String(n))&&m.throwArgumentError("invalid numeric width","type",e);var a=w.mask(r?n-1:n),i=r?a.add(y).mul(g):x;return function(t){var r=s.a.from(t);return(r.lt(i)||r.gt(a))&&m.throwArgumentError("value out-of-bounds for ".concat(e),"value",t),Object(f.hexZeroPad)(r.toTwos(256).toHexString(),32)}}var o=e.match(/^bytes(\d+)$/);if(o){var u=parseInt(o[1]);return(0===u||u>32||o[1]!==String(u))&&m.throwArgumentError("invalid bytes width","type",e),function(t){return Object(f.arrayify)(t).length!==u&&m.throwArgumentError("invalid length for ".concat(e),"value",t),function(e){var t=Object(f.arrayify)(e),r=t.length%32;return r?Object(f.hexConcat)([t,v.slice(r)]):Object(f.hexlify)(t)}(t)}}switch(e){case"address":return function(e){return Object(f.hexZeroPad)(Object(c.getAddress)(e),32)};case"bool":return function(e){return e?k:_};case"bytes":return function(e){return Object(d.keccak256)(e)};case"string":return function(e){return Object(h.a)(e)}}return null}function T(e,t){return"".concat(e,"(").concat(t.map((function(e){var t=e.name;return e.type+" "+t})).join(","),")")}var j=function(){function e(t){Object(i.a)(this,e),Object(u.defineReadOnly)(this,"types",Object.freeze(Object(u.deepCopy)(t))),Object(u.defineReadOnly)(this,"_encoderCache",{}),Object(u.defineReadOnly)(this,"_types",{});var r={},n={},a={};Object.keys(t).forEach((function(e){r[e]={},n[e]=[],a[e]={}}));var o=function(e){var a={};t[e].forEach((function(i){a[i.name]&&m.throwArgumentError("duplicate variable name ".concat(JSON.stringify(i.name)," in ").concat(JSON.stringify(e)),"types",t),a[i.name]=!0;var o=i.type.match(/^([^\x5b]*)(\x5b|$)/)[1];o===e&&m.throwArgumentError("circular type reference to ".concat(JSON.stringify(o)),"types",t),A(o)||(n[o]||m.throwArgumentError("unknown type ".concat(JSON.stringify(o)),"types",t),n[o].push(e),r[e][o]=!0)}))};for(var c in t)o(c);var s=Object.keys(n).filter((function(e){return 0===n[e].length}));for(var f in 0===s.length?m.throwArgumentError("missing primary type","types",t):s.length>1&&m.throwArgumentError("ambiguous primary types or unused types: ".concat(s.map((function(e){return JSON.stringify(e)})).join(", ")),"types",t),Object(u.defineReadOnly)(this,"primaryType",s[0]),function e(i,o){o[i]&&m.throwArgumentError("circular type reference to ".concat(JSON.stringify(i)),"types",t),o[i]=!0,Object.keys(r[i]).forEach((function(t){n[t]&&(e(t,o),Object.keys(o).forEach((function(e){a[e][t]=!0})))})),delete o[i]}(this.primaryType,{}),a){var d=Object.keys(a[f]);d.sort(),this._types[f]=T(f,t[f])+d.map((function(e){return T(e,t[e])})).join("")}}return Object(o.a)(e,[{key:"getEncoder",value:function(e){var t=this._encoderCache[e];return t||(t=this._encoderCache[e]=this._getEncoder(e)),t}},{key:"_getEncoder",value:function(e){var t=this,r=A(e);if(r)return r;var n=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(n){var a=n[1],i=this.getEncoder(a),o=parseInt(n[3]);return function(e){o>=0&&e.length!==o&&m.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",e);var r=e.map(i);return t._types[a]&&(r=r.map(d.keccak256)),Object(d.keccak256)(Object(f.hexConcat)(r))}}var c=this.types[e];if(c){var s=Object(h.a)(this._types[e]);return function(e){var r=c.map((function(r){var n=r.name,a=r.type,i=t.getEncoder(a)(e[n]);return t._types[a]?Object(d.keccak256)(i):i}));return r.unshift(s),Object(f.hexConcat)(r)}}return m.throwArgumentError("unknown type: ".concat(e),"type",e)}},{key:"encodeType",value:function(e){var t=this._types[e];return t||m.throwArgumentError("unknown type: ".concat(JSON.stringify(e)),"name",e),t}},{key:"encodeData",value:function(e,t){return this.getEncoder(e)(t)}},{key:"hashStruct",value:function(e,t){return Object(d.keccak256)(this.encodeData(e,t))}},{key:"encode",value:function(e){return this.encodeData(this.primaryType,e)}},{key:"hash",value:function(e){return this.hashStruct(this.primaryType,e)}},{key:"_visit",value:function(e,t,r){var n=this;if(A(e))return r(e,t);var a=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(a){var i=a[1],o=parseInt(a[3]);return o>=0&&t.length!==o&&m.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",t),t.map((function(e){return n._visit(i,e,r)}))}var c=this.types[e];return c?c.reduce((function(e,a){var i=a.name,o=a.type;return e[i]=n._visit(o,t[i],r),e}),{}):m.throwArgumentError("unknown type: ".concat(e),"type",e)}},{key:"visit",value:function(e,t){return this._visit(this.primaryType,e,t)}}],[{key:"from",value:function(t){return new e(t)}},{key:"getPrimaryType",value:function(t){return e.from(t).primaryType}},{key:"hashStruct",value:function(t,r,n){return e.from(r).hashStruct(t,n)}},{key:"hashDomain",value:function(t){var r=[];for(var n in t){var a=M[n];a||m.throwArgumentError("invalid typed-data domain key: ".concat(JSON.stringify(n)),"domain",t),r.push({name:n,type:a})}return r.sort((function(e,t){return S.indexOf(e.name)-S.indexOf(t.name)})),e.hashStruct("EIP712Domain",{EIP712Domain:r},t)}},{key:"encode",value:function(t,r,n){return Object(f.hexConcat)(["0x1901",e.hashDomain(t),e.from(r).hash(n)])}},{key:"hash",value:function(t,r,n){return Object(d.keccak256)(e.encode(t,r,n))}},{key:"resolveNames",value:function(t,r,n,i){return p(this,void 0,void 0,a.a.mark((function o(){var c,s,d;return a.a.wrap((function(o){for(;;)switch(o.prev=o.next){case 0:t=Object(u.shallowCopy)(t),c={},t.verifyingContract&&!Object(f.isHexString)(t.verifyingContract,20)&&(c[t.verifyingContract]="0x"),(s=e.from(r)).visit(n,(function(e,t){return"address"!==e||Object(f.isHexString)(t,20)||(c[t]="0x"),t})),o.t0=a.a.keys(c);case 6:if((o.t1=o.t0()).done){o.next=13;break}return d=o.t1.value,o.next=10,i(d);case 10:c[d]=o.sent,o.next=6;break;case 13:return t.verifyingContract&&c[t.verifyingContract]&&(t.verifyingContract=c[t.verifyingContract]),n=s.visit(n,(function(e,t){return"address"===e&&c[t]?c[t]:t})),o.abrupt("return",{domain:t,value:n});case 16:case"end":return o.stop()}}),o)})))}},{key:"getPayload",value:function(t,r,n){e.hashDomain(t);var a={},i=[];S.forEach((function(e){var r=t[e];null!=r&&(a[e]=O[e](r),i.push({name:e,type:M[e]}))}));var o=e.from(r),c=Object(u.shallowCopy)(r);return c.EIP712Domain?m.throwArgumentError("types must not contain EIP712Domain type","types.EIP712Domain",r):c.EIP712Domain=i,o.encode(n),{types:c,domain:a,primaryType:o.primaryType,message:o.visit(n,(function(e,t){if(e.match(/^bytes(\d*)/))return Object(f.hexlify)(Object(f.arrayify)(t));if(e.match(/^u?int/))return s.a.from(t).toString();switch(e){case"address":return t.toLowerCase();case"bool":return!!t;case"string":return"string"!==typeof t&&m.throwArgumentError("invalid string","value",t),t}return m.throwArgumentError("unsupported type","type",e)}))}}}]),e}()},function(e,t,r){"use strict";r.d(t,"a",(function(){return n}));var n="0x0000000000000000000000000000000000000000"},function(e,t,r){"use strict";function n(e){for(var t=(e=e.slice()).length-1;t>0;t--){var r=Math.floor(Math.random()*(t+1)),n=e[t];e[t]=e[r],e[r]=n}return e}r.d(t,"a",(function(){return n}))},function(e,t,r){"use strict";(function(e){r.d(t,"a",(function(){return f}));var n=r(10),a=r(16),i=r(550),o=new a.Logger(i.a),c=null;try{if(null==(c=window))throw new Error("try next")}catch(d){try{if(null==(c=e))throw new Error("try next")}catch(d){c={}}}var s=c.crypto||c.msCrypto;function f(e){(e<=0||e>1024||e%1)&&o.throwArgumentError("invalid length","length",e);var t=new Uint8Array(e);return s.getRandomValues(t),Object(n.arrayify)(t)}s&&s.getRandomValues||(o.warn("WARNING: Missing strong random number source"),s={getRandomValues:function(e){return o.throwError("no secure random source avaialble",a.Logger.errors.UNSUPPORTED_OPERATION,{operation:"crypto.getRandomValues"})}})}).call(this,r(44))},function(e,t,r){"use strict";var n=r(177);e.exports=function(e){n.copy(e,this)}},function(e,t,r){"use strict";e.exports=function(e,t){t||(t={}),"function"===typeof t&&(t={cmp:t});var r,n="boolean"===typeof t.cycles&&t.cycles,a=t.cmp&&(r=t.cmp,function(e){return function(t,n){var a={key:t,value:e[t]},i={key:n,value:e[n]};return r(a,i)}}),i=[];return function e(t){if(t&&t.toJSON&&"function"===typeof t.toJSON&&(t=t.toJSON()),void 0!==t){if("number"==typeof t)return isFinite(t)?""+t:"null";if("object"!==typeof t)return JSON.stringify(t);var r,o;if(Array.isArray(t)){for(o="[",r=0;r",g=b?">":"<",x=void 0;if(!l&&"number"!=typeof c&&void 0!==c)throw new Error(t+" must be number");if(!m&&void 0!==p&&"number"!=typeof p&&"boolean"!=typeof p)throw new Error(h+" must be number or boolean");if(m){var y=e.util.getData(p.$data,o,e.dataPathArr),w="exclusive"+i,k="exclType"+i,_="exclIsNumber"+i,M="' + "+(O="op"+i)+" + '";a+=" var schemaExcl"+i+" = "+y+"; ",a+=" var "+w+"; var "+k+" = typeof "+(y="schemaExcl"+i)+"; if ("+k+" != 'boolean' && "+k+" != 'undefined' && "+k+" != 'number') { ";var S;x=h;(S=S||[]).push(a),a="",!1!==e.createErrors?(a+=" { keyword: '"+(x||"_exclusiveLimit")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(f)+" , params: {} ",!1!==e.opts.messages&&(a+=" , message: '"+h+" should be boolean' "),e.opts.verbose&&(a+=" , schema: validate.schema"+s+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+u+" "),a+=" } "):a+=" {} ";var E=a;a=S.pop(),!e.compositeRule&&d?e.async?a+=" throw new ValidationError(["+E+"]); ":a+=" validate.errors = ["+E+"]; return false; ":a+=" var err = "+E+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",a+=" } else if ( ",l&&(a+=" ("+n+" !== undefined && typeof "+n+" != 'number') || "),a+=" "+k+" == 'number' ? ( ("+w+" = "+n+" === undefined || "+y+" "+v+"= "+n+") ? "+u+" "+g+"= "+y+" : "+u+" "+g+" "+n+" ) : ( ("+w+" = "+y+" === true) ? "+u+" "+g+"= "+n+" : "+u+" "+g+" "+n+" ) || "+u+" !== "+u+") { var op"+i+" = "+w+" ? '"+v+"' : '"+v+"='; ",void 0===c&&(x=h,f=e.errSchemaPath+"/"+h,n=y,l=m)}else{M=v;if((_="number"==typeof p)&&l){var O="'"+M+"'";a+=" if ( ",l&&(a+=" ("+n+" !== undefined && typeof "+n+" != 'number') || "),a+=" ( "+n+" === undefined || "+p+" "+v+"= "+n+" ? "+u+" "+g+"= "+p+" : "+u+" "+g+" "+n+" ) || "+u+" !== "+u+") { "}else{_&&void 0===c?(w=!0,x=h,f=e.errSchemaPath+"/"+h,n=p,g+="="):(_&&(n=Math[b?"min":"max"](p,c)),p===(!_||n)?(w=!0,x=h,f=e.errSchemaPath+"/"+h,g+="="):(w=!1,M+="="));O="'"+M+"'";a+=" if ( ",l&&(a+=" ("+n+" !== undefined && typeof "+n+" != 'number') || "),a+=" "+u+" "+g+" "+n+" || "+u+" !== "+u+") { "}}x=x||t,(S=S||[]).push(a),a="",!1!==e.createErrors?(a+=" { keyword: '"+(x||"_limit")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(f)+" , params: { comparison: "+O+", limit: "+n+", exclusive: "+w+" } ",!1!==e.opts.messages&&(a+=" , message: 'should be "+M+" ",a+=l?"' + "+n:n+"'"),e.opts.verbose&&(a+=" , schema: ",a+=l?"validate.schema"+s:""+c,a+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+u+" "),a+=" } "):a+=" {} ";E=a;return a=S.pop(),!e.compositeRule&&d?e.async?a+=" throw new ValidationError(["+E+"]); ":a+=" validate.errors = ["+E+"]; return false; ":a+=" var err = "+E+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",a+=" } ",d&&(a+=" else { "),a}},function(e,t,r){"use strict";e.exports=function(e,t,r){var n,a=" ",i=e.level,o=e.dataLevel,c=e.schema[t],s=e.schemaPath+e.util.getProperty(t),f=e.errSchemaPath+"/"+t,d=!e.opts.allErrors,u="data"+(o||""),l=e.opts.$data&&c&&c.$data;if(l?(a+=" var schema"+i+" = "+e.util.getData(c.$data,o,e.dataPathArr)+"; ",n="schema"+i):n=c,!l&&"number"!=typeof c)throw new Error(t+" must be number");a+="if ( ",l&&(a+=" ("+n+" !== undefined && typeof "+n+" != 'number') || "),a+=" "+u+".length "+("maxItems"==t?">":"<")+" "+n+") { ";var b=t,h=h||[];h.push(a),a="",!1!==e.createErrors?(a+=" { keyword: '"+(b||"_limitItems")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(f)+" , params: { limit: "+n+" } ",!1!==e.opts.messages&&(a+=" , message: 'should NOT have ",a+="maxItems"==t?"more":"fewer",a+=" than ",a+=l?"' + "+n+" + '":""+c,a+=" items' "),e.opts.verbose&&(a+=" , schema: ",a+=l?"validate.schema"+s:""+c,a+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+u+" "),a+=" } "):a+=" {} ";var p=a;return a=h.pop(),!e.compositeRule&&d?e.async?a+=" throw new ValidationError(["+p+"]); ":a+=" validate.errors = ["+p+"]; return false; ":a+=" var err = "+p+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",a+="} ",d&&(a+=" else { "),a}},function(e,t,r){"use strict";e.exports=function(e,t,r){var n,a=" ",i=e.level,o=e.dataLevel,c=e.schema[t],s=e.schemaPath+e.util.getProperty(t),f=e.errSchemaPath+"/"+t,d=!e.opts.allErrors,u="data"+(o||""),l=e.opts.$data&&c&&c.$data;if(l?(a+=" var schema"+i+" = "+e.util.getData(c.$data,o,e.dataPathArr)+"; ",n="schema"+i):n=c,!l&&"number"!=typeof c)throw new Error(t+" must be number");var b="maxLength"==t?">":"<";a+="if ( ",l&&(a+=" ("+n+" !== undefined && typeof "+n+" != 'number') || "),!1===e.opts.unicode?a+=" "+u+".length ":a+=" ucs2length("+u+") ",a+=" "+b+" "+n+") { ";var h=t,p=p||[];p.push(a),a="",!1!==e.createErrors?(a+=" { keyword: '"+(h||"_limitLength")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(f)+" , params: { limit: "+n+" } ",!1!==e.opts.messages&&(a+=" , message: 'should NOT be ",a+="maxLength"==t?"longer":"shorter",a+=" than ",a+=l?"' + "+n+" + '":""+c,a+=" characters' "),e.opts.verbose&&(a+=" , schema: ",a+=l?"validate.schema"+s:""+c,a+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+u+" "),a+=" } "):a+=" {} ";var m=a;return a=p.pop(),!e.compositeRule&&d?e.async?a+=" throw new ValidationError(["+m+"]); ":a+=" validate.errors = ["+m+"]; return false; ":a+=" var err = "+m+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",a+="} ",d&&(a+=" else { "),a}},function(e,t,r){"use strict";e.exports=function(e,t,r){var n,a=" ",i=e.level,o=e.dataLevel,c=e.schema[t],s=e.schemaPath+e.util.getProperty(t),f=e.errSchemaPath+"/"+t,d=!e.opts.allErrors,u="data"+(o||""),l=e.opts.$data&&c&&c.$data;if(l?(a+=" var schema"+i+" = "+e.util.getData(c.$data,o,e.dataPathArr)+"; ",n="schema"+i):n=c,!l&&"number"!=typeof c)throw new Error(t+" must be number");a+="if ( ",l&&(a+=" ("+n+" !== undefined && typeof "+n+" != 'number') || "),a+=" Object.keys("+u+").length "+("maxProperties"==t?">":"<")+" "+n+") { ";var b=t,h=h||[];h.push(a),a="",!1!==e.createErrors?(a+=" { keyword: '"+(b||"_limitProperties")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(f)+" , params: { limit: "+n+" } ",!1!==e.opts.messages&&(a+=" , message: 'should NOT have ",a+="maxProperties"==t?"more":"fewer",a+=" than ",a+=l?"' + "+n+" + '":""+c,a+=" properties' "),e.opts.verbose&&(a+=" , schema: ",a+=l?"validate.schema"+s:""+c,a+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+u+" "),a+=" } "):a+=" {} ";var p=a;return a=h.pop(),!e.compositeRule&&d?e.async?a+=" throw new ValidationError(["+p+"]); ":a+=" validate.errors = ["+p+"]; return false; ":a+=" var err = "+p+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",a+="} ",d&&(a+=" else { "),a}},function(e){e.exports=JSON.parse('{"$schema":"http://json-schema.org/draft-07/schema#","$id":"http://json-schema.org/draft-07/schema#","title":"Core schema meta-schema","definitions":{"schemaArray":{"type":"array","minItems":1,"items":{"$ref":"#"}},"nonNegativeInteger":{"type":"integer","minimum":0},"nonNegativeIntegerDefault0":{"allOf":[{"$ref":"#/definitions/nonNegativeInteger"},{"default":0}]},"simpleTypes":{"enum":["array","boolean","integer","null","number","object","string"]},"stringArray":{"type":"array","items":{"type":"string"},"uniqueItems":true,"default":[]}},"type":["object","boolean"],"properties":{"$id":{"type":"string","format":"uri-reference"},"$schema":{"type":"string","format":"uri"},"$ref":{"type":"string","format":"uri-reference"},"$comment":{"type":"string"},"title":{"type":"string"},"description":{"type":"string"},"default":true,"readOnly":{"type":"boolean","default":false},"examples":{"type":"array","items":true},"multipleOf":{"type":"number","exclusiveMinimum":0},"maximum":{"type":"number"},"exclusiveMaximum":{"type":"number"},"minimum":{"type":"number"},"exclusiveMinimum":{"type":"number"},"maxLength":{"$ref":"#/definitions/nonNegativeInteger"},"minLength":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"pattern":{"type":"string","format":"regex"},"additionalItems":{"$ref":"#"},"items":{"anyOf":[{"$ref":"#"},{"$ref":"#/definitions/schemaArray"}],"default":true},"maxItems":{"$ref":"#/definitions/nonNegativeInteger"},"minItems":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"uniqueItems":{"type":"boolean","default":false},"contains":{"$ref":"#"},"maxProperties":{"$ref":"#/definitions/nonNegativeInteger"},"minProperties":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"required":{"$ref":"#/definitions/stringArray"},"additionalProperties":{"$ref":"#"},"definitions":{"type":"object","additionalProperties":{"$ref":"#"},"default":{}},"properties":{"type":"object","additionalProperties":{"$ref":"#"},"default":{}},"patternProperties":{"type":"object","additionalProperties":{"$ref":"#"},"propertyNames":{"format":"regex"},"default":{}},"dependencies":{"type":"object","additionalProperties":{"anyOf":[{"$ref":"#"},{"$ref":"#/definitions/stringArray"}]}},"propertyNames":{"$ref":"#"},"const":true,"enum":{"type":"array","items":true,"minItems":1,"uniqueItems":true},"type":{"anyOf":[{"$ref":"#/definitions/simpleTypes"},{"type":"array","items":{"$ref":"#/definitions/simpleTypes"},"minItems":1,"uniqueItems":true}]},"format":{"type":"string"},"contentMediaType":{"type":"string"},"contentEncoding":{"type":"string"},"if":{"$ref":"#"},"then":{"$ref":"#"},"else":{"$ref":"#"},"allOf":{"$ref":"#/definitions/schemaArray"},"anyOf":{"$ref":"#/definitions/schemaArray"},"oneOf":{"$ref":"#/definitions/schemaArray"},"not":{"$ref":"#"}},"default":true}')},function(e,t,r){"use strict";var n=r(943),a=r(332),i=a.encodeText,o=a.decodeText,c=a.concat;function s(e){if(Object.prototype.hasOwnProperty.call(n.names,e))return n.names[e];if(Object.prototype.hasOwnProperty.call(n.codes,e))return n.codes[e];throw new Error("Unsupported encoding: ".concat(e))}(t=e.exports=function(e,t){if(!t)throw new Error("requires an encoded Uint8Array");var r=s(e),n=r.name,a=r.codeBuf;return function(e,t){s(e).decode(o(t))}(n,t),c([a,t],a.length+t.length)}).encode=function(e,t){var r=s(e),n=i(r.encode(t));return c([r.codeBuf,n],r.codeBuf.length+n.length)},t.decode=function(e){e instanceof Uint8Array&&(e=o(e));var t=e[0];return["f","F","v","V","t","T","b","B","c","C","h","k","K"].includes(t)&&(e=e.toLowerCase()),s(e[0]).decode(e.substring(1))},t.isEncoded=function(e){if(e instanceof Uint8Array&&(e=o(e)),"[object String]"!==Object.prototype.toString.call(e))return!1;try{return s(e[0]).name}catch(t){return!1}},t.encoding=s,t.encodingFromData=function(e){return e instanceof Uint8Array&&(e=o(e)),s(e[0])};var f=Object.freeze(n.names),d=Object.freeze(n.codes);t.names=f,t.codes=d},function(e,t,r){"use strict";var n=r(130),a=r(948).bases;function i(e,t,r,n){return{name:e,prefix:t,encoder:{name:e,prefix:t,encode:r},decoder:{decode:n}}}var o=i("utf8","u",(function(e){return"u"+new TextDecoder("utf8").decode(e)}),(function(e){return(new TextEncoder).encode(e.substring(1))})),c=i("ascii","a",(function(e){for(var t="a",r=0;r1&&void 0!==arguments[1]?arguments[1]:"utf8",r=n[t];if(!r)throw new Error('Unsupported encoding "'.concat(t,'"'));return r.decoder.decode("".concat(r.prefix).concat(e))}},function(e,t,r){"use strict";var n=r(133),a=r(333),i=r(497);function o(e){return parseInt(a(e,"base16"),16)}e.exports={numberToUint8Array:function(e){var t=e.toString(16);t.length%2===1&&(t="0"+t);return i(t,"base16")},uint8ArrayToNumber:o,varintUint8ArrayEncode:function(e){return Uint8Array.from(n.encode(o(e)))},varintEncode:function(e){return Uint8Array.from(n.encode(e))}}},function(e,t,r){var n=r(156),a=r(148);e.exports=function(e){if(!a(e))return!1;var t=n(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t}},function(e,t,r){(function(t){var r="object"==typeof t&&t&&t.Object===Object&&t;e.exports=r}).call(this,r(44))},function(e,t){var r=Function.prototype.toString;e.exports=function(e){if(null!=e){try{return r.call(e)}catch(t){}try{return e+""}catch(t){}}return""}},function(e,t,r){var n=r(1002),a=r(1005),i=r(1006);e.exports=function(e,t,r,o,c,s){var f=1&r,d=e.length,u=t.length;if(d!=u&&!(f&&u>d))return!1;var l=s.get(e),b=s.get(t);if(l&&b)return l==t&&b==e;var h=-1,p=!0,m=2&r?new n:void 0;for(s.set(e,t),s.set(t,e);++h1&&(a-=1)),[360*a,100*i,100*f]},o.rgb.hwb=function(e){var t=e[0],r=e[1],n=e[2];return[o.rgb.hsl(e)[0],100*(1/255*Math.min(t,Math.min(r,n))),100*(n=1-1/255*Math.max(t,Math.max(r,n)))]},o.rgb.cmyk=function(e){var t,r=e[0]/255,n=e[1]/255,a=e[2]/255;return[100*((1-r-(t=Math.min(1-r,1-n,1-a)))/(1-t)||0),100*((1-n-t)/(1-t)||0),100*((1-a-t)/(1-t)||0),100*t]},o.rgb.keyword=function(e){var t=a[e];if(t)return t;var r,i,o,c=1/0;for(var s in n)if(n.hasOwnProperty(s)){var f=n[s],d=(i=e,o=f,Math.pow(i[0]-o[0],2)+Math.pow(i[1]-o[1],2)+Math.pow(i[2]-o[2],2));d.04045?Math.pow((t+.055)/1.055,2.4):t/12.92)+.3576*(r=r>.04045?Math.pow((r+.055)/1.055,2.4):r/12.92)+.1805*(n=n>.04045?Math.pow((n+.055)/1.055,2.4):n/12.92)),100*(.2126*t+.7152*r+.0722*n),100*(.0193*t+.1192*r+.9505*n)]},o.rgb.lab=function(e){var t=o.rgb.xyz(e),r=t[0],n=t[1],a=t[2];return n/=100,a/=108.883,r=(r/=95.047)>.008856?Math.pow(r,1/3):7.787*r+16/116,[116*(n=n>.008856?Math.pow(n,1/3):7.787*n+16/116)-16,500*(r-n),200*(n-(a=a>.008856?Math.pow(a,1/3):7.787*a+16/116))]},o.hsl.rgb=function(e){var t,r,n,a,i,o=e[0]/360,c=e[1]/100,s=e[2]/100;if(0===c)return[i=255*s,i,i];t=2*s-(r=s<.5?s*(1+c):s+c-s*c),a=[0,0,0];for(var f=0;f<3;f++)(n=o+1/3*-(f-1))<0&&n++,n>1&&n--,i=6*n<1?t+6*(r-t)*n:2*n<1?r:3*n<2?t+(r-t)*(2/3-n)*6:t,a[f]=255*i;return a},o.hsl.hsv=function(e){var t=e[0],r=e[1]/100,n=e[2]/100,a=r,i=Math.max(n,.01);return r*=(n*=2)<=1?n:2-n,a*=i<=1?i:2-i,[t,100*(0===n?2*a/(i+a):2*r/(n+r)),100*((n+r)/2)]},o.hsv.rgb=function(e){var t=e[0]/60,r=e[1]/100,n=e[2]/100,a=Math.floor(t)%6,i=t-Math.floor(t),o=255*n*(1-r),c=255*n*(1-r*i),s=255*n*(1-r*(1-i));switch(n*=255,a){case 0:return[n,s,o];case 1:return[c,n,o];case 2:return[o,n,s];case 3:return[o,c,n];case 4:return[s,o,n];case 5:return[n,o,c]}},o.hsv.hsl=function(e){var t,r,n,a=e[0],i=e[1]/100,o=e[2]/100,c=Math.max(o,.01);return n=(2-i)*o,r=i*c,[a,100*(r=(r/=(t=(2-i)*c)<=1?t:2-t)||0),100*(n/=2)]},o.hwb.rgb=function(e){var t,r,n,a,i,o,c,s=e[0]/360,f=e[1]/100,d=e[2]/100,u=f+d;switch(u>1&&(f/=u,d/=u),n=6*s-(t=Math.floor(6*s)),0!==(1&t)&&(n=1-n),a=f+n*((r=1-d)-f),t){default:case 6:case 0:i=r,o=a,c=f;break;case 1:i=a,o=r,c=f;break;case 2:i=f,o=r,c=a;break;case 3:i=f,o=a,c=r;break;case 4:i=a,o=f,c=r;break;case 5:i=r,o=f,c=a}return[255*i,255*o,255*c]},o.cmyk.rgb=function(e){var t=e[0]/100,r=e[1]/100,n=e[2]/100,a=e[3]/100;return[255*(1-Math.min(1,t*(1-a)+a)),255*(1-Math.min(1,r*(1-a)+a)),255*(1-Math.min(1,n*(1-a)+a))]},o.xyz.rgb=function(e){var t,r,n,a=e[0]/100,i=e[1]/100,o=e[2]/100;return r=-.9689*a+1.8758*i+.0415*o,n=.0557*a+-.204*i+1.057*o,t=(t=3.2406*a+-1.5372*i+-.4986*o)>.0031308?1.055*Math.pow(t,1/2.4)-.055:12.92*t,r=r>.0031308?1.055*Math.pow(r,1/2.4)-.055:12.92*r,n=n>.0031308?1.055*Math.pow(n,1/2.4)-.055:12.92*n,[255*(t=Math.min(Math.max(0,t),1)),255*(r=Math.min(Math.max(0,r),1)),255*(n=Math.min(Math.max(0,n),1))]},o.xyz.lab=function(e){var t=e[0],r=e[1],n=e[2];return r/=100,n/=108.883,t=(t/=95.047)>.008856?Math.pow(t,1/3):7.787*t+16/116,[116*(r=r>.008856?Math.pow(r,1/3):7.787*r+16/116)-16,500*(t-r),200*(r-(n=n>.008856?Math.pow(n,1/3):7.787*n+16/116))]},o.lab.xyz=function(e){var t,r,n,a=e[0];t=e[1]/500+(r=(a+16)/116),n=r-e[2]/200;var i=Math.pow(r,3),o=Math.pow(t,3),c=Math.pow(n,3);return r=i>.008856?i:(r-16/116)/7.787,t=o>.008856?o:(t-16/116)/7.787,n=c>.008856?c:(n-16/116)/7.787,[t*=95.047,r*=100,n*=108.883]},o.lab.lch=function(e){var t,r=e[0],n=e[1],a=e[2];return(t=360*Math.atan2(a,n)/2/Math.PI)<0&&(t+=360),[r,Math.sqrt(n*n+a*a),t]},o.lch.lab=function(e){var t,r=e[0],n=e[1];return t=e[2]/360*2*Math.PI,[r,n*Math.cos(t),n*Math.sin(t)]},o.rgb.ansi16=function(e){var t=e[0],r=e[1],n=e[2],a=1 in arguments?arguments[1]:o.rgb.hsv(e)[2];if(0===(a=Math.round(a/50)))return 30;var i=30+(Math.round(n/255)<<2|Math.round(r/255)<<1|Math.round(t/255));return 2===a&&(i+=60),i},o.hsv.ansi16=function(e){return o.rgb.ansi16(o.hsv.rgb(e),e[2])},o.rgb.ansi256=function(e){var t=e[0],r=e[1],n=e[2];return t===r&&r===n?t<8?16:t>248?231:Math.round((t-8)/247*24)+232:16+36*Math.round(t/255*5)+6*Math.round(r/255*5)+Math.round(n/255*5)},o.ansi16.rgb=function(e){var t=e%10;if(0===t||7===t)return e>50&&(t+=3.5),[t=t/10.5*255,t,t];var r=.5*(1+~~(e>50));return[(1&t)*r*255,(t>>1&1)*r*255,(t>>2&1)*r*255]},o.ansi256.rgb=function(e){if(e>=232){var t=10*(e-232)+8;return[t,t,t]}var r;return e-=16,[Math.floor(e/36)/5*255,Math.floor((r=e%36)/6)/5*255,r%6/5*255]},o.rgb.hex=function(e){var t=(((255&Math.round(e[0]))<<16)+((255&Math.round(e[1]))<<8)+(255&Math.round(e[2]))).toString(16).toUpperCase();return"000000".substring(t.length)+t},o.hex.rgb=function(e){var t=e.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!t)return[0,0,0];var r=t[0];3===t[0].length&&(r=r.split("").map((function(e){return e+e})).join(""));var n=parseInt(r,16);return[n>>16&255,n>>8&255,255&n]},o.rgb.hcg=function(e){var t,r=e[0]/255,n=e[1]/255,a=e[2]/255,i=Math.max(Math.max(r,n),a),o=Math.min(Math.min(r,n),a),c=i-o;return t=c<=0?0:i===r?(n-a)/c%6:i===n?2+(a-r)/c:4+(r-n)/c+4,t/=6,[360*(t%=1),100*c,100*(c<1?o/(1-c):0)]},o.hsl.hcg=function(e){var t=e[1]/100,r=e[2]/100,n=1,a=0;return(n=r<.5?2*t*r:2*t*(1-r))<1&&(a=(r-.5*n)/(1-n)),[e[0],100*n,100*a]},o.hsv.hcg=function(e){var t=e[1]/100,r=e[2]/100,n=t*r,a=0;return n<1&&(a=(r-n)/(1-n)),[e[0],100*n,100*a]},o.hcg.rgb=function(e){var t=e[0]/360,r=e[1]/100,n=e[2]/100;if(0===r)return[255*n,255*n,255*n];var a,i=[0,0,0],o=t%1*6,c=o%1,s=1-c;switch(Math.floor(o)){case 0:i[0]=1,i[1]=c,i[2]=0;break;case 1:i[0]=s,i[1]=1,i[2]=0;break;case 2:i[0]=0,i[1]=1,i[2]=c;break;case 3:i[0]=0,i[1]=s,i[2]=1;break;case 4:i[0]=c,i[1]=0,i[2]=1;break;default:i[0]=1,i[1]=0,i[2]=s}return a=(1-r)*n,[255*(r*i[0]+a),255*(r*i[1]+a),255*(r*i[2]+a)]},o.hcg.hsv=function(e){var t=e[1]/100,r=t+e[2]/100*(1-t),n=0;return r>0&&(n=t/r),[e[0],100*n,100*r]},o.hcg.hsl=function(e){var t=e[1]/100,r=e[2]/100*(1-t)+.5*t,n=0;return r>0&&r<.5?n=t/(2*r):r>=.5&&r<1&&(n=t/(2*(1-r))),[e[0],100*n,100*r]},o.hcg.hwb=function(e){var t=e[1]/100,r=t+e[2]/100*(1-t);return[e[0],100*(r-t),100*(1-r)]},o.hwb.hcg=function(e){var t=e[1]/100,r=1-e[2]/100,n=r-t,a=0;return n<1&&(a=(r-n)/(1-n)),[e[0],100*n,100*a]},o.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]},o.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]},o.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]},o.gray.hsl=o.gray.hsv=function(e){return[0,0,e[0]]},o.gray.hwb=function(e){return[0,100,e[0]]},o.gray.cmyk=function(e){return[0,0,0,e[0]]},o.gray.lab=function(e){return[e[0],0,0]},o.gray.hex=function(e){var t=255&Math.round(e[0]/100*255),r=((t<<16)+(t<<8)+t).toString(16).toUpperCase();return"000000".substring(r.length)+r},o.rgb.gray=function(e){return[(e[0]+e[1]+e[2])/3/255*100]}},function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r),Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[r]}})}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),a=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.hasOwnProperty.call(e,r)&&n(t,e,r);return a(t,e),t},o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var c=r(347),s=o(r(1050)),f=i(r(256)),d=i(r(1074)),u=i(r(1078)),l=i(r(1088)),b=r(528),h=function(){function e(t,r){this._src=t,this.opts=b({},r,e.DefaultOpts),this.opts.combinedFilter=l.combineFilters(this.opts.filters)}return e.from=function(e){return new s.default(e)},e.prototype._process=function(e,t){var r=t.quantizer,n=t.generator;return e.scaleDown(t),e.applyFilter(t.combinedFilter).then((function(e){return r(e.data,t)})).then((function(e){return c.Swatch.applyFilter(e,t.combinedFilter)})).then((function(e){return Promise.resolve(n(e))}))},e.prototype.palette=function(){return this.swatches()},e.prototype.swatches=function(){return this._palette},e.prototype.getPalette=function(e){var t=this,r=new this.opts.ImageClass,n=r.load(this._src).then((function(e){return t._process(e,t.opts)})).then((function(e){return t._palette=e,r.remove(),e}),(function(e){throw r.remove(),e}));return e&&n.then((function(t){return e(null,t)}),(function(t){return e(t)})),n},e.Builder=s.default,e.Quantizer=d,e.Generator=u,e.Filter=l,e.Util=f,e.Swatch=c.Swatch,e.DefaultOpts={colorCount:64,quality:5,generator:u.Default,ImageClass:null,quantizer:d.MMCQ,filters:[l.Default]},e}();t.default=h},function(e,t,r){var n=r(516),a=r(1033)(n);e.exports=a},function(e,t,r){var n=r(1031),a=r(196);e.exports=function(e,t){return e&&n(e,t,a)}},function(e,t,r){var n=r(1034),a=r(1037),i=r(258),o=r(92),c=r(1047);e.exports=function(e){return"function"==typeof e?e:null==e?i:"object"==typeof e?o(e)?a(e[0],e[1]):n(e):c(e)}},function(e,t,r){var n=r(148);e.exports=function(e){return e===e&&!n(e)}},function(e,t){e.exports=function(e,t){return function(r){return null!=r&&(r[e]===t&&(void 0!==t||e in Object(r)))}}},function(e,t,r){var n=r(521),a=r(257);e.exports=function(e,t){for(var r=0,i=(t=n(t,e)).length;null!=e&&r2?t[2]:void 0;for(f&&i(t[0],t[1],f)&&(n=1);++r1&&(a-=1)),[360*a,100*i,100*f]},o.rgb.hwb=function(e){var t=e[0],r=e[1],n=e[2];return[o.rgb.hsl(e)[0],100*(1/255*Math.min(t,Math.min(r,n))),100*(n=1-1/255*Math.max(t,Math.max(r,n)))]},o.rgb.cmyk=function(e){var t,r=e[0]/255,n=e[1]/255,a=e[2]/255;return[100*((1-r-(t=Math.min(1-r,1-n,1-a)))/(1-t)||0),100*((1-n-t)/(1-t)||0),100*((1-a-t)/(1-t)||0),100*t]},o.rgb.keyword=function(e){var t=a[e];if(t)return t;var r,i,o,c=1/0;for(var s in n)if(n.hasOwnProperty(s)){var f=n[s],d=(i=e,o=f,Math.pow(i[0]-o[0],2)+Math.pow(i[1]-o[1],2)+Math.pow(i[2]-o[2],2));d.04045?Math.pow((t+.055)/1.055,2.4):t/12.92)+.3576*(r=r>.04045?Math.pow((r+.055)/1.055,2.4):r/12.92)+.1805*(n=n>.04045?Math.pow((n+.055)/1.055,2.4):n/12.92)),100*(.2126*t+.7152*r+.0722*n),100*(.0193*t+.1192*r+.9505*n)]},o.rgb.lab=function(e){var t=o.rgb.xyz(e),r=t[0],n=t[1],a=t[2];return n/=100,a/=108.883,r=(r/=95.047)>.008856?Math.pow(r,1/3):7.787*r+16/116,[116*(n=n>.008856?Math.pow(n,1/3):7.787*n+16/116)-16,500*(r-n),200*(n-(a=a>.008856?Math.pow(a,1/3):7.787*a+16/116))]},o.hsl.rgb=function(e){var t,r,n,a,i,o=e[0]/360,c=e[1]/100,s=e[2]/100;if(0===c)return[i=255*s,i,i];t=2*s-(r=s<.5?s*(1+c):s+c-s*c),a=[0,0,0];for(var f=0;f<3;f++)(n=o+1/3*-(f-1))<0&&n++,n>1&&n--,i=6*n<1?t+6*(r-t)*n:2*n<1?r:3*n<2?t+(r-t)*(2/3-n)*6:t,a[f]=255*i;return a},o.hsl.hsv=function(e){var t=e[0],r=e[1]/100,n=e[2]/100,a=r,i=Math.max(n,.01);return r*=(n*=2)<=1?n:2-n,a*=i<=1?i:2-i,[t,100*(0===n?2*a/(i+a):2*r/(n+r)),100*((n+r)/2)]},o.hsv.rgb=function(e){var t=e[0]/60,r=e[1]/100,n=e[2]/100,a=Math.floor(t)%6,i=t-Math.floor(t),o=255*n*(1-r),c=255*n*(1-r*i),s=255*n*(1-r*(1-i));switch(n*=255,a){case 0:return[n,s,o];case 1:return[c,n,o];case 2:return[o,n,s];case 3:return[o,c,n];case 4:return[s,o,n];case 5:return[n,o,c]}},o.hsv.hsl=function(e){var t,r,n,a=e[0],i=e[1]/100,o=e[2]/100,c=Math.max(o,.01);return n=(2-i)*o,r=i*c,[a,100*(r=(r/=(t=(2-i)*c)<=1?t:2-t)||0),100*(n/=2)]},o.hwb.rgb=function(e){var t,r,n,a,i,o,c,s=e[0]/360,f=e[1]/100,d=e[2]/100,u=f+d;switch(u>1&&(f/=u,d/=u),n=6*s-(t=Math.floor(6*s)),0!==(1&t)&&(n=1-n),a=f+n*((r=1-d)-f),t){default:case 6:case 0:i=r,o=a,c=f;break;case 1:i=a,o=r,c=f;break;case 2:i=f,o=r,c=a;break;case 3:i=f,o=a,c=r;break;case 4:i=a,o=f,c=r;break;case 5:i=r,o=f,c=a}return[255*i,255*o,255*c]},o.cmyk.rgb=function(e){var t=e[0]/100,r=e[1]/100,n=e[2]/100,a=e[3]/100;return[255*(1-Math.min(1,t*(1-a)+a)),255*(1-Math.min(1,r*(1-a)+a)),255*(1-Math.min(1,n*(1-a)+a))]},o.xyz.rgb=function(e){var t,r,n,a=e[0]/100,i=e[1]/100,o=e[2]/100;return r=-.9689*a+1.8758*i+.0415*o,n=.0557*a+-.204*i+1.057*o,t=(t=3.2406*a+-1.5372*i+-.4986*o)>.0031308?1.055*Math.pow(t,1/2.4)-.055:12.92*t,r=r>.0031308?1.055*Math.pow(r,1/2.4)-.055:12.92*r,n=n>.0031308?1.055*Math.pow(n,1/2.4)-.055:12.92*n,[255*(t=Math.min(Math.max(0,t),1)),255*(r=Math.min(Math.max(0,r),1)),255*(n=Math.min(Math.max(0,n),1))]},o.xyz.lab=function(e){var t=e[0],r=e[1],n=e[2];return r/=100,n/=108.883,t=(t/=95.047)>.008856?Math.pow(t,1/3):7.787*t+16/116,[116*(r=r>.008856?Math.pow(r,1/3):7.787*r+16/116)-16,500*(t-r),200*(r-(n=n>.008856?Math.pow(n,1/3):7.787*n+16/116))]},o.lab.xyz=function(e){var t,r,n,a=e[0];t=e[1]/500+(r=(a+16)/116),n=r-e[2]/200;var i=Math.pow(r,3),o=Math.pow(t,3),c=Math.pow(n,3);return r=i>.008856?i:(r-16/116)/7.787,t=o>.008856?o:(t-16/116)/7.787,n=c>.008856?c:(n-16/116)/7.787,[t*=95.047,r*=100,n*=108.883]},o.lab.lch=function(e){var t,r=e[0],n=e[1],a=e[2];return(t=360*Math.atan2(a,n)/2/Math.PI)<0&&(t+=360),[r,Math.sqrt(n*n+a*a),t]},o.lch.lab=function(e){var t,r=e[0],n=e[1];return t=e[2]/360*2*Math.PI,[r,n*Math.cos(t),n*Math.sin(t)]},o.rgb.ansi16=function(e){var t=e[0],r=e[1],n=e[2],a=1 in arguments?arguments[1]:o.rgb.hsv(e)[2];if(0===(a=Math.round(a/50)))return 30;var i=30+(Math.round(n/255)<<2|Math.round(r/255)<<1|Math.round(t/255));return 2===a&&(i+=60),i},o.hsv.ansi16=function(e){return o.rgb.ansi16(o.hsv.rgb(e),e[2])},o.rgb.ansi256=function(e){var t=e[0],r=e[1],n=e[2];return t===r&&r===n?t<8?16:t>248?231:Math.round((t-8)/247*24)+232:16+36*Math.round(t/255*5)+6*Math.round(r/255*5)+Math.round(n/255*5)},o.ansi16.rgb=function(e){var t=e%10;if(0===t||7===t)return e>50&&(t+=3.5),[t=t/10.5*255,t,t];var r=.5*(1+~~(e>50));return[(1&t)*r*255,(t>>1&1)*r*255,(t>>2&1)*r*255]},o.ansi256.rgb=function(e){if(e>=232){var t=10*(e-232)+8;return[t,t,t]}var r;return e-=16,[Math.floor(e/36)/5*255,Math.floor((r=e%36)/6)/5*255,r%6/5*255]},o.rgb.hex=function(e){var t=(((255&Math.round(e[0]))<<16)+((255&Math.round(e[1]))<<8)+(255&Math.round(e[2]))).toString(16).toUpperCase();return"000000".substring(t.length)+t},o.hex.rgb=function(e){var t=e.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!t)return[0,0,0];var r=t[0];3===t[0].length&&(r=r.split("").map((function(e){return e+e})).join(""));var n=parseInt(r,16);return[n>>16&255,n>>8&255,255&n]},o.rgb.hcg=function(e){var t,r=e[0]/255,n=e[1]/255,a=e[2]/255,i=Math.max(Math.max(r,n),a),o=Math.min(Math.min(r,n),a),c=i-o;return t=c<=0?0:i===r?(n-a)/c%6:i===n?2+(a-r)/c:4+(r-n)/c+4,t/=6,[360*(t%=1),100*c,100*(c<1?o/(1-c):0)]},o.hsl.hcg=function(e){var t=e[1]/100,r=e[2]/100,n=1,a=0;return(n=r<.5?2*t*r:2*t*(1-r))<1&&(a=(r-.5*n)/(1-n)),[e[0],100*n,100*a]},o.hsv.hcg=function(e){var t=e[1]/100,r=e[2]/100,n=t*r,a=0;return n<1&&(a=(r-n)/(1-n)),[e[0],100*n,100*a]},o.hcg.rgb=function(e){var t=e[0]/360,r=e[1]/100,n=e[2]/100;if(0===r)return[255*n,255*n,255*n];var a,i=[0,0,0],o=t%1*6,c=o%1,s=1-c;switch(Math.floor(o)){case 0:i[0]=1,i[1]=c,i[2]=0;break;case 1:i[0]=s,i[1]=1,i[2]=0;break;case 2:i[0]=0,i[1]=1,i[2]=c;break;case 3:i[0]=0,i[1]=s,i[2]=1;break;case 4:i[0]=c,i[1]=0,i[2]=1;break;default:i[0]=1,i[1]=0,i[2]=s}return a=(1-r)*n,[255*(r*i[0]+a),255*(r*i[1]+a),255*(r*i[2]+a)]},o.hcg.hsv=function(e){var t=e[1]/100,r=t+e[2]/100*(1-t),n=0;return r>0&&(n=t/r),[e[0],100*n,100*r]},o.hcg.hsl=function(e){var t=e[1]/100,r=e[2]/100*(1-t)+.5*t,n=0;return r>0&&r<.5?n=t/(2*r):r>=.5&&r<1&&(n=t/(2*(1-r))),[e[0],100*n,100*r]},o.hcg.hwb=function(e){var t=e[1]/100,r=t+e[2]/100*(1-t);return[e[0],100*(r-t),100*(1-r)]},o.hwb.hcg=function(e){var t=e[1]/100,r=1-e[2]/100,n=r-t,a=0;return n<1&&(a=(r-n)/(1-n)),[e[0],100*n,100*a]},o.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]},o.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]},o.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]},o.gray.hsl=o.gray.hsv=function(e){return[0,0,e[0]]},o.gray.hwb=function(e){return[0,100,e[0]]},o.gray.cmyk=function(e){return[0,0,0,e[0]]},o.gray.lab=function(e){return[e[0],0,0]},o.gray.hex=function(e){var t=255&Math.round(e[0]/100*255),r=((t<<16)+(t<<8)+t).toString(16).toUpperCase();return"000000".substring(r.length)+r},o.rgb.gray=function(e){return[(e[0]+e[1]+e[2])/3/255*100]}},function(e,t,r){"use strict";e.exports={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}},function(e,t,r){"use strict";var n=r(1116),a={"text/plain":"Text","text/html":"Url",default:"Text"};e.exports=function(e,t){var r,i,o,c,s,f,d=!1;t||(t={}),r=t.debug||!1;try{if(o=n(),c=document.createRange(),s=document.getSelection(),(f=document.createElement("span")).textContent=e,f.style.all="unset",f.style.position="fixed",f.style.top=0,f.style.clip="rect(0, 0, 0, 0)",f.style.whiteSpace="pre",f.style.webkitUserSelect="text",f.style.MozUserSelect="text",f.style.msUserSelect="text",f.style.userSelect="text",f.addEventListener("copy",(function(n){if(n.stopPropagation(),t.format)if(n.preventDefault(),"undefined"===typeof n.clipboardData){r&&console.warn("unable to use e.clipboardData"),r&&console.warn("trying IE specific stuff"),window.clipboardData.clearData();var i=a[t.format]||a.default;window.clipboardData.setData(i,e)}else n.clipboardData.clearData(),n.clipboardData.setData(t.format,e);t.onCopy&&(n.preventDefault(),t.onCopy(n.clipboardData))})),document.body.appendChild(f),c.selectNodeContents(f),s.addRange(c),!document.execCommand("copy"))throw new Error("copy command was unsuccessful");d=!0}catch(u){r&&console.error("unable to copy using execCommand: ",u),r&&console.warn("trying IE specific stuff");try{window.clipboardData.setData(t.format||"text",e),t.onCopy&&t.onCopy(window.clipboardData),d=!0}catch(u){r&&console.error("unable to copy using clipboardData: ",u),r&&console.error("falling back to prompt"),i=function(e){var t=(/mac os x/i.test(navigator.userAgent)?"\u2318":"Ctrl")+"+C";return e.replace(/#{\s*key\s*}/g,t)}("message"in t?t.message:"Copy to clipboard: #{key}, Enter"),window.prompt(i,e)}}finally{s&&("function"==typeof s.removeRange?s.removeRange(c):s.removeAllRanges()),f&&document.body.removeChild(f),o()}return d}},function(e,t,r){"use strict";var n=r(359),a=Object.prototype.hasOwnProperty,i=Array.isArray,o=function(){for(var e=[],t=0;t<256;++t)e.push("%"+((t<16?"0":"")+t.toString(16)).toUpperCase());return e}(),c=function(e,t){for(var r=t&&t.plainObjects?Object.create(null):{},n=0;n1;){var t=e.pop(),r=t.obj[t.prop];if(i(r)){for(var n=[],a=0;a=48&&d<=57||d>=65&&d<=90||d>=97&&d<=122||i===n.RFC1738&&(40===d||41===d)?s+=c.charAt(f):d<128?s+=o[d]:d<2048?s+=o[192|d>>6]+o[128|63&d]:d<55296||d>=57344?s+=o[224|d>>12]+o[128|d>>6&63]+o[128|63&d]:(f+=1,d=65536+((1023&d)<<10|1023&c.charCodeAt(f)),s+=o[240|d>>18]+o[128|d>>12&63]+o[128|d>>6&63]+o[128|63&d])}return s},isBuffer:function(e){return!(!e||"object"!==typeof e)&&!!(e.constructor&&e.constructor.isBuffer&&e.constructor.isBuffer(e))},isRegExp:function(e){return"[object RegExp]"===Object.prototype.toString.call(e)},maybeMap:function(e,t){if(i(e)){for(var r=[],n=0;n=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function s(e,t,r){var n=c(e,r);return r-1>=t&&(n|=c(e,r-1)<<4),n}function f(e,t,r,n){for(var a=0,i=Math.min(e.length,r),o=t;o=49?c-49+10:c>=17?c-17+10:c}return a}i.isBN=function(e){return e instanceof i||null!==e&&"object"===typeof e&&e.constructor.wordSize===i.wordSize&&Array.isArray(e.words)},i.max=function(e,t){return e.cmp(t)>0?e:t},i.min=function(e,t){return e.cmp(t)<0?e:t},i.prototype._init=function(e,t,r){if("number"===typeof e)return this._initNumber(e,t,r);if("object"===typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var a=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(a++,this.negative=1),a=0;a-=3)o=e[a]|e[a-1]<<8|e[a-2]<<16,this.words[i]|=o<>>26-c&67108863,(c+=24)>=26&&(c-=26,i++);else if("le"===r)for(a=0,i=0;a>>26-c&67108863,(c+=24)>=26&&(c-=26,i++);return this.strip()},i.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n=t;n-=2)a=s(e,t,n)<=18?(i-=18,o+=1,this.words[o]|=a>>>26):i+=8;else for(n=(e.length-t)%2===0?t+1:t;n=18?(i-=18,o+=1,this.words[o]|=a>>>26):i+=8;this.strip()},i.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,a=1;a<=67108863;a*=t)n++;n--,a=a/t|0;for(var i=e.length-r,o=i%n,c=Math.min(i,i-o)+r,s=0,d=r;d1&&0===this.words[this.length-1];)this.length--;return this._normSign()},i.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},i.prototype.inspect=function(){return(this.red?""};var d=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],u=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],l=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];function b(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var a=0|e.words[0],i=0|t.words[0],o=a*i,c=67108863&o,s=o/67108864|0;r.words[0]=c;for(var f=1;f>>26,u=67108863&s,l=Math.min(f,t.length-1),b=Math.max(0,f-e.length+1);b<=l;b++){var h=f-b|0;d+=(o=(a=0|e.words[h])*(i=0|t.words[b])+u)/67108864|0,u=67108863&o}r.words[f]=0|u,s=0|d}return 0!==s?r.words[f]=0|s:r.length--,r.strip()}i.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var a=0,i=0,o=0;o>>24-a&16777215)||o!==this.length-1?d[6-s.length]+s+r:s+r,(a+=2)>=26&&(a-=26,o--)}for(0!==i&&(r=i.toString(16)+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var f=u[e],b=l[e];r="";var h=this.clone();for(h.negative=0;!h.isZero();){var p=h.modn(b).toString(e);r=(h=h.idivn(b)).isZero()?p+r:d[f-p.length]+p+r}for(this.isZero()&&(r="0"+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},i.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},i.prototype.toJSON=function(){return this.toString(16)},i.prototype.toBuffer=function(e,t){return n("undefined"!==typeof o),this.toArrayLike(o,e,t)},i.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},i.prototype.toArrayLike=function(e,t,r){var a=this.byteLength(),i=r||Math.max(1,a);n(a<=i,"byte array longer than desired length"),n(i>0,"Requested array length <= 0"),this.strip();var o,c,s="le"===t,f=new e(i),d=this.clone();if(s){for(c=0;!d.isZero();c++)o=d.andln(255),d.iushrn(8),f[c]=o;for(;c=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},i.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0===(8191&t)&&(r+=13,t>>>=13),0===(127&t)&&(r+=7,t>>>=7),0===(15&t)&&(r+=4,t>>>=4),0===(3&t)&&(r+=2,t>>>=2),0===(1&t)&&r++,r},i.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},i.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},i.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},i.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},i.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},i.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},i.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},i.prototype.inotn=function(e){n("number"===typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var a=0;a0&&(this.words[a]=~this.words[a]&67108863>>26-r),this.strip()},i.prototype.notn=function(e){return this.clone().inotn(e)},i.prototype.setn=function(e,t){n("number"===typeof e&&e>=0);var r=e/26|0,a=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var a=0,i=0;i>>26;for(;0!==a&&i>>26;if(this.length=r.length,0!==a)this.words[this.length]=a,this.length++;else if(r!==this)for(;ie.length?this.clone().iadd(e):e.clone().iadd(this)},i.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,a=this.cmp(e);if(0===a)return this.negative=0,this.length=1,this.words[0]=0,this;a>0?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>26,this.words[o]=67108863&t;for(;0!==i&&o>26,this.words[o]=67108863&t;if(0===i&&o>>13,b=0|o[1],h=8191&b,p=b>>>13,m=0|o[2],v=8191&m,g=m>>>13,x=0|o[3],y=8191&x,w=x>>>13,k=0|o[4],_=8191&k,M=k>>>13,S=0|o[5],E=8191&S,O=S>>>13,A=0|o[6],T=8191&A,j=A>>>13,P=0|o[7],C=8191&P,R=P>>>13,N=0|o[8],B=8191&N,L=N>>>13,I=0|o[9],F=8191&I,D=I>>>13,U=0|c[0],z=8191&U,H=U>>>13,q=0|c[1],J=8191&q,V=q>>>13,G=0|c[2],X=8191&G,K=G>>>13,W=0|c[3],Z=8191&W,$=W>>>13,Q=0|c[4],Y=8191&Q,ee=Q>>>13,te=0|c[5],re=8191&te,ne=te>>>13,ae=0|c[6],ie=8191&ae,oe=ae>>>13,ce=0|c[7],se=8191&ce,fe=ce>>>13,de=0|c[8],ue=8191&de,le=de>>>13,be=0|c[9],he=8191&be,pe=be>>>13;r.negative=e.negative^t.negative,r.length=19;var me=(f+(n=Math.imul(u,z))|0)+((8191&(a=(a=Math.imul(u,H))+Math.imul(l,z)|0))<<13)|0;f=((i=Math.imul(l,H))+(a>>>13)|0)+(me>>>26)|0,me&=67108863,n=Math.imul(h,z),a=(a=Math.imul(h,H))+Math.imul(p,z)|0,i=Math.imul(p,H);var ve=(f+(n=n+Math.imul(u,J)|0)|0)+((8191&(a=(a=a+Math.imul(u,V)|0)+Math.imul(l,J)|0))<<13)|0;f=((i=i+Math.imul(l,V)|0)+(a>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(v,z),a=(a=Math.imul(v,H))+Math.imul(g,z)|0,i=Math.imul(g,H),n=n+Math.imul(h,J)|0,a=(a=a+Math.imul(h,V)|0)+Math.imul(p,J)|0,i=i+Math.imul(p,V)|0;var ge=(f+(n=n+Math.imul(u,X)|0)|0)+((8191&(a=(a=a+Math.imul(u,K)|0)+Math.imul(l,X)|0))<<13)|0;f=((i=i+Math.imul(l,K)|0)+(a>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(y,z),a=(a=Math.imul(y,H))+Math.imul(w,z)|0,i=Math.imul(w,H),n=n+Math.imul(v,J)|0,a=(a=a+Math.imul(v,V)|0)+Math.imul(g,J)|0,i=i+Math.imul(g,V)|0,n=n+Math.imul(h,X)|0,a=(a=a+Math.imul(h,K)|0)+Math.imul(p,X)|0,i=i+Math.imul(p,K)|0;var xe=(f+(n=n+Math.imul(u,Z)|0)|0)+((8191&(a=(a=a+Math.imul(u,$)|0)+Math.imul(l,Z)|0))<<13)|0;f=((i=i+Math.imul(l,$)|0)+(a>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(_,z),a=(a=Math.imul(_,H))+Math.imul(M,z)|0,i=Math.imul(M,H),n=n+Math.imul(y,J)|0,a=(a=a+Math.imul(y,V)|0)+Math.imul(w,J)|0,i=i+Math.imul(w,V)|0,n=n+Math.imul(v,X)|0,a=(a=a+Math.imul(v,K)|0)+Math.imul(g,X)|0,i=i+Math.imul(g,K)|0,n=n+Math.imul(h,Z)|0,a=(a=a+Math.imul(h,$)|0)+Math.imul(p,Z)|0,i=i+Math.imul(p,$)|0;var ye=(f+(n=n+Math.imul(u,Y)|0)|0)+((8191&(a=(a=a+Math.imul(u,ee)|0)+Math.imul(l,Y)|0))<<13)|0;f=((i=i+Math.imul(l,ee)|0)+(a>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(E,z),a=(a=Math.imul(E,H))+Math.imul(O,z)|0,i=Math.imul(O,H),n=n+Math.imul(_,J)|0,a=(a=a+Math.imul(_,V)|0)+Math.imul(M,J)|0,i=i+Math.imul(M,V)|0,n=n+Math.imul(y,X)|0,a=(a=a+Math.imul(y,K)|0)+Math.imul(w,X)|0,i=i+Math.imul(w,K)|0,n=n+Math.imul(v,Z)|0,a=(a=a+Math.imul(v,$)|0)+Math.imul(g,Z)|0,i=i+Math.imul(g,$)|0,n=n+Math.imul(h,Y)|0,a=(a=a+Math.imul(h,ee)|0)+Math.imul(p,Y)|0,i=i+Math.imul(p,ee)|0;var we=(f+(n=n+Math.imul(u,re)|0)|0)+((8191&(a=(a=a+Math.imul(u,ne)|0)+Math.imul(l,re)|0))<<13)|0;f=((i=i+Math.imul(l,ne)|0)+(a>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(T,z),a=(a=Math.imul(T,H))+Math.imul(j,z)|0,i=Math.imul(j,H),n=n+Math.imul(E,J)|0,a=(a=a+Math.imul(E,V)|0)+Math.imul(O,J)|0,i=i+Math.imul(O,V)|0,n=n+Math.imul(_,X)|0,a=(a=a+Math.imul(_,K)|0)+Math.imul(M,X)|0,i=i+Math.imul(M,K)|0,n=n+Math.imul(y,Z)|0,a=(a=a+Math.imul(y,$)|0)+Math.imul(w,Z)|0,i=i+Math.imul(w,$)|0,n=n+Math.imul(v,Y)|0,a=(a=a+Math.imul(v,ee)|0)+Math.imul(g,Y)|0,i=i+Math.imul(g,ee)|0,n=n+Math.imul(h,re)|0,a=(a=a+Math.imul(h,ne)|0)+Math.imul(p,re)|0,i=i+Math.imul(p,ne)|0;var ke=(f+(n=n+Math.imul(u,ie)|0)|0)+((8191&(a=(a=a+Math.imul(u,oe)|0)+Math.imul(l,ie)|0))<<13)|0;f=((i=i+Math.imul(l,oe)|0)+(a>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(C,z),a=(a=Math.imul(C,H))+Math.imul(R,z)|0,i=Math.imul(R,H),n=n+Math.imul(T,J)|0,a=(a=a+Math.imul(T,V)|0)+Math.imul(j,J)|0,i=i+Math.imul(j,V)|0,n=n+Math.imul(E,X)|0,a=(a=a+Math.imul(E,K)|0)+Math.imul(O,X)|0,i=i+Math.imul(O,K)|0,n=n+Math.imul(_,Z)|0,a=(a=a+Math.imul(_,$)|0)+Math.imul(M,Z)|0,i=i+Math.imul(M,$)|0,n=n+Math.imul(y,Y)|0,a=(a=a+Math.imul(y,ee)|0)+Math.imul(w,Y)|0,i=i+Math.imul(w,ee)|0,n=n+Math.imul(v,re)|0,a=(a=a+Math.imul(v,ne)|0)+Math.imul(g,re)|0,i=i+Math.imul(g,ne)|0,n=n+Math.imul(h,ie)|0,a=(a=a+Math.imul(h,oe)|0)+Math.imul(p,ie)|0,i=i+Math.imul(p,oe)|0;var _e=(f+(n=n+Math.imul(u,se)|0)|0)+((8191&(a=(a=a+Math.imul(u,fe)|0)+Math.imul(l,se)|0))<<13)|0;f=((i=i+Math.imul(l,fe)|0)+(a>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(B,z),a=(a=Math.imul(B,H))+Math.imul(L,z)|0,i=Math.imul(L,H),n=n+Math.imul(C,J)|0,a=(a=a+Math.imul(C,V)|0)+Math.imul(R,J)|0,i=i+Math.imul(R,V)|0,n=n+Math.imul(T,X)|0,a=(a=a+Math.imul(T,K)|0)+Math.imul(j,X)|0,i=i+Math.imul(j,K)|0,n=n+Math.imul(E,Z)|0,a=(a=a+Math.imul(E,$)|0)+Math.imul(O,Z)|0,i=i+Math.imul(O,$)|0,n=n+Math.imul(_,Y)|0,a=(a=a+Math.imul(_,ee)|0)+Math.imul(M,Y)|0,i=i+Math.imul(M,ee)|0,n=n+Math.imul(y,re)|0,a=(a=a+Math.imul(y,ne)|0)+Math.imul(w,re)|0,i=i+Math.imul(w,ne)|0,n=n+Math.imul(v,ie)|0,a=(a=a+Math.imul(v,oe)|0)+Math.imul(g,ie)|0,i=i+Math.imul(g,oe)|0,n=n+Math.imul(h,se)|0,a=(a=a+Math.imul(h,fe)|0)+Math.imul(p,se)|0,i=i+Math.imul(p,fe)|0;var Me=(f+(n=n+Math.imul(u,ue)|0)|0)+((8191&(a=(a=a+Math.imul(u,le)|0)+Math.imul(l,ue)|0))<<13)|0;f=((i=i+Math.imul(l,le)|0)+(a>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(F,z),a=(a=Math.imul(F,H))+Math.imul(D,z)|0,i=Math.imul(D,H),n=n+Math.imul(B,J)|0,a=(a=a+Math.imul(B,V)|0)+Math.imul(L,J)|0,i=i+Math.imul(L,V)|0,n=n+Math.imul(C,X)|0,a=(a=a+Math.imul(C,K)|0)+Math.imul(R,X)|0,i=i+Math.imul(R,K)|0,n=n+Math.imul(T,Z)|0,a=(a=a+Math.imul(T,$)|0)+Math.imul(j,Z)|0,i=i+Math.imul(j,$)|0,n=n+Math.imul(E,Y)|0,a=(a=a+Math.imul(E,ee)|0)+Math.imul(O,Y)|0,i=i+Math.imul(O,ee)|0,n=n+Math.imul(_,re)|0,a=(a=a+Math.imul(_,ne)|0)+Math.imul(M,re)|0,i=i+Math.imul(M,ne)|0,n=n+Math.imul(y,ie)|0,a=(a=a+Math.imul(y,oe)|0)+Math.imul(w,ie)|0,i=i+Math.imul(w,oe)|0,n=n+Math.imul(v,se)|0,a=(a=a+Math.imul(v,fe)|0)+Math.imul(g,se)|0,i=i+Math.imul(g,fe)|0,n=n+Math.imul(h,ue)|0,a=(a=a+Math.imul(h,le)|0)+Math.imul(p,ue)|0,i=i+Math.imul(p,le)|0;var Se=(f+(n=n+Math.imul(u,he)|0)|0)+((8191&(a=(a=a+Math.imul(u,pe)|0)+Math.imul(l,he)|0))<<13)|0;f=((i=i+Math.imul(l,pe)|0)+(a>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(F,J),a=(a=Math.imul(F,V))+Math.imul(D,J)|0,i=Math.imul(D,V),n=n+Math.imul(B,X)|0,a=(a=a+Math.imul(B,K)|0)+Math.imul(L,X)|0,i=i+Math.imul(L,K)|0,n=n+Math.imul(C,Z)|0,a=(a=a+Math.imul(C,$)|0)+Math.imul(R,Z)|0,i=i+Math.imul(R,$)|0,n=n+Math.imul(T,Y)|0,a=(a=a+Math.imul(T,ee)|0)+Math.imul(j,Y)|0,i=i+Math.imul(j,ee)|0,n=n+Math.imul(E,re)|0,a=(a=a+Math.imul(E,ne)|0)+Math.imul(O,re)|0,i=i+Math.imul(O,ne)|0,n=n+Math.imul(_,ie)|0,a=(a=a+Math.imul(_,oe)|0)+Math.imul(M,ie)|0,i=i+Math.imul(M,oe)|0,n=n+Math.imul(y,se)|0,a=(a=a+Math.imul(y,fe)|0)+Math.imul(w,se)|0,i=i+Math.imul(w,fe)|0,n=n+Math.imul(v,ue)|0,a=(a=a+Math.imul(v,le)|0)+Math.imul(g,ue)|0,i=i+Math.imul(g,le)|0;var Ee=(f+(n=n+Math.imul(h,he)|0)|0)+((8191&(a=(a=a+Math.imul(h,pe)|0)+Math.imul(p,he)|0))<<13)|0;f=((i=i+Math.imul(p,pe)|0)+(a>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,X),a=(a=Math.imul(F,K))+Math.imul(D,X)|0,i=Math.imul(D,K),n=n+Math.imul(B,Z)|0,a=(a=a+Math.imul(B,$)|0)+Math.imul(L,Z)|0,i=i+Math.imul(L,$)|0,n=n+Math.imul(C,Y)|0,a=(a=a+Math.imul(C,ee)|0)+Math.imul(R,Y)|0,i=i+Math.imul(R,ee)|0,n=n+Math.imul(T,re)|0,a=(a=a+Math.imul(T,ne)|0)+Math.imul(j,re)|0,i=i+Math.imul(j,ne)|0,n=n+Math.imul(E,ie)|0,a=(a=a+Math.imul(E,oe)|0)+Math.imul(O,ie)|0,i=i+Math.imul(O,oe)|0,n=n+Math.imul(_,se)|0,a=(a=a+Math.imul(_,fe)|0)+Math.imul(M,se)|0,i=i+Math.imul(M,fe)|0,n=n+Math.imul(y,ue)|0,a=(a=a+Math.imul(y,le)|0)+Math.imul(w,ue)|0,i=i+Math.imul(w,le)|0;var Oe=(f+(n=n+Math.imul(v,he)|0)|0)+((8191&(a=(a=a+Math.imul(v,pe)|0)+Math.imul(g,he)|0))<<13)|0;f=((i=i+Math.imul(g,pe)|0)+(a>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,Z),a=(a=Math.imul(F,$))+Math.imul(D,Z)|0,i=Math.imul(D,$),n=n+Math.imul(B,Y)|0,a=(a=a+Math.imul(B,ee)|0)+Math.imul(L,Y)|0,i=i+Math.imul(L,ee)|0,n=n+Math.imul(C,re)|0,a=(a=a+Math.imul(C,ne)|0)+Math.imul(R,re)|0,i=i+Math.imul(R,ne)|0,n=n+Math.imul(T,ie)|0,a=(a=a+Math.imul(T,oe)|0)+Math.imul(j,ie)|0,i=i+Math.imul(j,oe)|0,n=n+Math.imul(E,se)|0,a=(a=a+Math.imul(E,fe)|0)+Math.imul(O,se)|0,i=i+Math.imul(O,fe)|0,n=n+Math.imul(_,ue)|0,a=(a=a+Math.imul(_,le)|0)+Math.imul(M,ue)|0,i=i+Math.imul(M,le)|0;var Ae=(f+(n=n+Math.imul(y,he)|0)|0)+((8191&(a=(a=a+Math.imul(y,pe)|0)+Math.imul(w,he)|0))<<13)|0;f=((i=i+Math.imul(w,pe)|0)+(a>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(F,Y),a=(a=Math.imul(F,ee))+Math.imul(D,Y)|0,i=Math.imul(D,ee),n=n+Math.imul(B,re)|0,a=(a=a+Math.imul(B,ne)|0)+Math.imul(L,re)|0,i=i+Math.imul(L,ne)|0,n=n+Math.imul(C,ie)|0,a=(a=a+Math.imul(C,oe)|0)+Math.imul(R,ie)|0,i=i+Math.imul(R,oe)|0,n=n+Math.imul(T,se)|0,a=(a=a+Math.imul(T,fe)|0)+Math.imul(j,se)|0,i=i+Math.imul(j,fe)|0,n=n+Math.imul(E,ue)|0,a=(a=a+Math.imul(E,le)|0)+Math.imul(O,ue)|0,i=i+Math.imul(O,le)|0;var Te=(f+(n=n+Math.imul(_,he)|0)|0)+((8191&(a=(a=a+Math.imul(_,pe)|0)+Math.imul(M,he)|0))<<13)|0;f=((i=i+Math.imul(M,pe)|0)+(a>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,re),a=(a=Math.imul(F,ne))+Math.imul(D,re)|0,i=Math.imul(D,ne),n=n+Math.imul(B,ie)|0,a=(a=a+Math.imul(B,oe)|0)+Math.imul(L,ie)|0,i=i+Math.imul(L,oe)|0,n=n+Math.imul(C,se)|0,a=(a=a+Math.imul(C,fe)|0)+Math.imul(R,se)|0,i=i+Math.imul(R,fe)|0,n=n+Math.imul(T,ue)|0,a=(a=a+Math.imul(T,le)|0)+Math.imul(j,ue)|0,i=i+Math.imul(j,le)|0;var je=(f+(n=n+Math.imul(E,he)|0)|0)+((8191&(a=(a=a+Math.imul(E,pe)|0)+Math.imul(O,he)|0))<<13)|0;f=((i=i+Math.imul(O,pe)|0)+(a>>>13)|0)+(je>>>26)|0,je&=67108863,n=Math.imul(F,ie),a=(a=Math.imul(F,oe))+Math.imul(D,ie)|0,i=Math.imul(D,oe),n=n+Math.imul(B,se)|0,a=(a=a+Math.imul(B,fe)|0)+Math.imul(L,se)|0,i=i+Math.imul(L,fe)|0,n=n+Math.imul(C,ue)|0,a=(a=a+Math.imul(C,le)|0)+Math.imul(R,ue)|0,i=i+Math.imul(R,le)|0;var Pe=(f+(n=n+Math.imul(T,he)|0)|0)+((8191&(a=(a=a+Math.imul(T,pe)|0)+Math.imul(j,he)|0))<<13)|0;f=((i=i+Math.imul(j,pe)|0)+(a>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,se),a=(a=Math.imul(F,fe))+Math.imul(D,se)|0,i=Math.imul(D,fe),n=n+Math.imul(B,ue)|0,a=(a=a+Math.imul(B,le)|0)+Math.imul(L,ue)|0,i=i+Math.imul(L,le)|0;var Ce=(f+(n=n+Math.imul(C,he)|0)|0)+((8191&(a=(a=a+Math.imul(C,pe)|0)+Math.imul(R,he)|0))<<13)|0;f=((i=i+Math.imul(R,pe)|0)+(a>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,n=Math.imul(F,ue),a=(a=Math.imul(F,le))+Math.imul(D,ue)|0,i=Math.imul(D,le);var Re=(f+(n=n+Math.imul(B,he)|0)|0)+((8191&(a=(a=a+Math.imul(B,pe)|0)+Math.imul(L,he)|0))<<13)|0;f=((i=i+Math.imul(L,pe)|0)+(a>>>13)|0)+(Re>>>26)|0,Re&=67108863;var Ne=(f+(n=Math.imul(F,he))|0)+((8191&(a=(a=Math.imul(F,pe))+Math.imul(D,he)|0))<<13)|0;return f=((i=Math.imul(D,pe))+(a>>>13)|0)+(Ne>>>26)|0,Ne&=67108863,s[0]=me,s[1]=ve,s[2]=ge,s[3]=xe,s[4]=ye,s[5]=we,s[6]=ke,s[7]=_e,s[8]=Me,s[9]=Se,s[10]=Ee,s[11]=Oe,s[12]=Ae,s[13]=Te,s[14]=je,s[15]=Pe,s[16]=Ce,s[17]=Re,s[18]=Ne,0!==f&&(s[19]=f,r.length++),r};function p(e,t,r){return(new m).mulp(e,t,r)}function m(e,t){this.x=e,this.y=t}Math.imul||(h=b),i.prototype.mulTo=function(e,t){var r=this.length+e.length;return 10===this.length&&10===e.length?h(this,e,t):r<63?b(this,e,t):r<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,a=0,i=0;i>>26)|0)>>>26,o&=67108863}r.words[i]=c,n=o,o=a}return 0!==n?r.words[i]=n:r.length--,r.strip()}(this,e,t):p(this,e,t)},m.prototype.makeRBT=function(e){for(var t=new Array(e),r=i.prototype._countBits(e)-1,n=0;n>=1;return n},m.prototype.permute=function(e,t,r,n,a,i){for(var o=0;o>>=1)a++;return 1<>>=13,r[2*o+1]=8191&i,i>>>=13;for(o=2*t;o>=26,t+=a/67108864|0,t+=i>>>26,this.words[r]=67108863&i}return 0!==t&&(this.words[r]=t,this.length++),this},i.prototype.muln=function(e){return this.clone().imuln(e)},i.prototype.sqr=function(){return this.mul(this)},i.prototype.isqr=function(){return this.imul(this.clone())},i.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>a}return t}(e);if(0===t.length)return new i(1);for(var r=this,n=0;n=0);var t,r=e%26,a=(e-r)/26,i=67108863>>>26-r<<26-r;if(0!==r){var o=0;for(t=0;t>>26-r}o&&(this.words[t]=o,this.length++)}if(0!==a){for(t=this.length-1;t>=0;t--)this.words[t+a]=this.words[t];for(t=0;t=0),a=t?(t-t%26)/26:0;var i=e%26,o=Math.min((e-i)/26,this.length),c=67108863^67108863>>>i<o)for(this.length-=o,f=0;f=0&&(0!==d||f>=a);f--){var u=0|this.words[f];this.words[f]=d<<26-i|u>>>i,d=u&c}return s&&0!==d&&(s.words[s.length++]=d),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},i.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},i.prototype.shln=function(e){return this.clone().ishln(e)},i.prototype.ushln=function(e){return this.clone().iushln(e)},i.prototype.shrn=function(e){return this.clone().ishrn(e)},i.prototype.ushrn=function(e){return this.clone().iushrn(e)},i.prototype.testn=function(e){n("number"===typeof e&&e>=0);var t=e%26,r=(e-t)/26,a=1<=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var a=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},i.prototype.isubn=function(e){if(n("number"===typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(s/67108864|0),this.words[a+r]=67108863&i}for(;a>26,this.words[a+r]=67108863&i;if(0===c)return this.strip();for(n(-1===c),c=0,a=0;a>26,this.words[a]=67108863&i;return this.negative=1,this.strip()},i.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),a=e,o=0|a.words[a.length-1];0!==(r=26-this._countBits(o))&&(a=a.ushln(r),n.iushln(r),o=0|a.words[a.length-1]);var c,s=n.length-a.length;if("mod"!==t){(c=new i(null)).length=s+1,c.words=new Array(c.length);for(var f=0;f=0;u--){var l=67108864*(0|n.words[a.length+u])+(0|n.words[a.length+u-1]);for(l=Math.min(l/o|0,67108863),n._ishlnsubmul(a,l,u);0!==n.negative;)l--,n.negative=0,n._ishlnsubmul(a,1,u),n.isZero()||(n.negative^=1);c&&(c.words[u]=l)}return c&&c.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:c||null,mod:n}},i.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new i(0),mod:new i(0)}:0!==this.negative&&0===e.negative?(c=this.neg().divmod(e,t),"mod"!==t&&(a=c.div.neg()),"div"!==t&&(o=c.mod.neg(),r&&0!==o.negative&&o.iadd(e)),{div:a,mod:o}):0===this.negative&&0!==e.negative?(c=this.divmod(e.neg(),t),"mod"!==t&&(a=c.div.neg()),{div:a,mod:c.mod}):0!==(this.negative&e.negative)?(c=this.neg().divmod(e.neg(),t),"div"!==t&&(o=c.mod.neg(),r&&0!==o.negative&&o.isub(e)),{div:c.div,mod:o}):e.length>this.length||this.cmp(e)<0?{div:new i(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new i(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new i(this.modn(e.words[0]))}:this._wordDiv(e,t);var a,o,c},i.prototype.div=function(e){return this.divmod(e,"div",!1).div},i.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},i.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},i.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),a=e.andln(1),i=r.cmp(n);return i<0||1===a&&0===i?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},i.prototype.modn=function(e){n(e<=67108863);for(var t=(1<<26)%e,r=0,a=this.length-1;a>=0;a--)r=(t*r+(0|this.words[a]))%e;return r},i.prototype.idivn=function(e){n(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var a=(0|this.words[r])+67108864*t;this.words[r]=a/e|0,t=a%e}return this.strip()},i.prototype.divn=function(e){return this.clone().idivn(e)},i.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var a=new i(1),o=new i(0),c=new i(0),s=new i(1),f=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++f;for(var d=r.clone(),u=t.clone();!t.isZero();){for(var l=0,b=1;0===(t.words[0]&b)&&l<26;++l,b<<=1);if(l>0)for(t.iushrn(l);l-- >0;)(a.isOdd()||o.isOdd())&&(a.iadd(d),o.isub(u)),a.iushrn(1),o.iushrn(1);for(var h=0,p=1;0===(r.words[0]&p)&&h<26;++h,p<<=1);if(h>0)for(r.iushrn(h);h-- >0;)(c.isOdd()||s.isOdd())&&(c.iadd(d),s.isub(u)),c.iushrn(1),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(c),o.isub(s)):(r.isub(t),c.isub(a),s.isub(o))}return{a:c,b:s,gcd:r.iushln(f)}},i.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var a,o=new i(1),c=new i(0),s=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var f=0,d=1;0===(t.words[0]&d)&&f<26;++f,d<<=1);if(f>0)for(t.iushrn(f);f-- >0;)o.isOdd()&&o.iadd(s),o.iushrn(1);for(var u=0,l=1;0===(r.words[0]&l)&&u<26;++u,l<<=1);if(u>0)for(r.iushrn(u);u-- >0;)c.isOdd()&&c.iadd(s),c.iushrn(1);t.cmp(r)>=0?(t.isub(r),o.isub(c)):(r.isub(t),c.isub(o))}return(a=0===t.cmpn(1)?o:c).cmpn(0)<0&&a.iadd(e),a},i.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var a=t.cmp(r);if(a<0){var i=t;t=r,r=i}else if(0===a||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},i.prototype.invm=function(e){return this.egcd(e).a.umod(e)},i.prototype.isEven=function(){return 0===(1&this.words[0])},i.prototype.isOdd=function(){return 1===(1&this.words[0])},i.prototype.andln=function(e){return this.words[0]&e},i.prototype.bincn=function(e){n("number"===typeof e);var t=e%26,r=(e-t)/26,a=1<>>26,c&=67108863,this.words[o]=c}return 0!==i&&(this.words[o]=i,this.length++),this},i.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},i.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var a=0|this.words[0];t=a===e?0:ae.length)return 1;if(this.length=0;r--){var n=0|this.words[r],a=0|e.words[r];if(n!==a){na&&(t=1);break}}return t},i.prototype.gtn=function(e){return 1===this.cmpn(e)},i.prototype.gt=function(e){return 1===this.cmp(e)},i.prototype.gten=function(e){return this.cmpn(e)>=0},i.prototype.gte=function(e){return this.cmp(e)>=0},i.prototype.ltn=function(e){return-1===this.cmpn(e)},i.prototype.lt=function(e){return-1===this.cmp(e)},i.prototype.lten=function(e){return this.cmpn(e)<=0},i.prototype.lte=function(e){return this.cmp(e)<=0},i.prototype.eqn=function(e){return 0===this.cmpn(e)},i.prototype.eq=function(e){return 0===this.cmp(e)},i.red=function(e){return new _(e)},i.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},i.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},i.prototype._forceRed=function(e){return this.red=e,this},i.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},i.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},i.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},i.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},i.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},i.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},i.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},i.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},i.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},i.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},i.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},i.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},i.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},i.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var v={k256:null,p224:null,p192:null,p25519:null};function g(e,t){this.name=e,this.p=new i(t,16),this.n=this.p.bitLength(),this.k=new i(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function x(){g.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function y(){g.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function w(){g.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function k(){g.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function _(e){if("string"===typeof e){var t=i._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function M(e){_.call(this,e),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new i(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}g.prototype._tmp=function(){var e=new i(null);return e.words=new Array(Math.ceil(this.n/13)),e},g.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},g.prototype.split=function(e,t){e.iushrn(this.n,0,t)},g.prototype.imulK=function(e){return e.imul(this.k)},a(x,g),x.prototype.split=function(e,t){for(var r=Math.min(e.length,9),n=0;n>>22,a=i}a>>>=22,e.words[n-10]=a,0===a&&e.length>10?e.length-=10:e.length-=9},x.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=a,t=n}return 0!==t&&(e.words[e.length++]=t),e},i._prime=function(e){if(v[e])return v[e];var t;if("k256"===e)t=new x;else if("p224"===e)t=new y;else if("p192"===e)t=new w;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new k}return v[e]=t,t},_.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},_.prototype._verify2=function(e,t){n(0===(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},_.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},_.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},_.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},_.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},_.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},_.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},_.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},_.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},_.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},_.prototype.isqr=function(e){return this.imul(e,e.clone())},_.prototype.sqr=function(e){return this.mul(e,e)},_.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2===1),3===t){var r=this.m.add(new i(1)).iushrn(2);return this.pow(e,r)}for(var a=this.m.subn(1),o=0;!a.isZero()&&0===a.andln(1);)o++,a.iushrn(1);n(!a.isZero());var c=new i(1).toRed(this),s=c.redNeg(),f=this.m.subn(1).iushrn(1),d=this.m.bitLength();for(d=new i(2*d*d).toRed(this);0!==this.pow(d,f).cmp(s);)d.redIAdd(s);for(var u=this.pow(d,a),l=this.pow(e,a.addn(1).iushrn(1)),b=this.pow(e,a),h=o;0!==b.cmp(c);){for(var p=b,m=0;0!==p.cmp(c);m++)p=p.redSqr();n(m=0;n--){for(var f=t.words[n],d=s-1;d>=0;d--){var u=f>>d&1;a!==r[0]&&(a=this.sqr(a)),0!==u||0!==o?(o<<=1,o|=u,(4===++c||0===n&&0===d)&&(a=this.mul(a,r[o]),c=0,o=0)):c=0}s=26}return a},_.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},_.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},i.mont=function(e){return new M(e)},a(M,_),M.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},M.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},M.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),a=r.isub(n).iushrn(this.shift),i=a;return a.cmp(this.m)>=0?i=a.isub(this.m):a.cmpn(0)<0&&(i=a.iadd(this.m)),i._forceRed(this)},M.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new i(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),a=r.isub(n).iushrn(this.shift),o=a;return a.cmp(this.m)>=0?o=a.isub(this.m):a.cmpn(0)<0&&(o=a.iadd(this.m)),o._forceRed(this)},M.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e,this)}).call(this,r(74)(e))},function(e,t,r){var n;!function(a){"use strict";var i,o={precision:20,rounding:4,toExpNeg:-7,toExpPos:21,LN10:"2.302585092994045684017991454684364207601101488628772976033327900967572609677352480235997205089598298341967784042286"},c=!0,s="[DecimalError] ",f=s+"Invalid argument: ",d=s+"Exponent out of range: ",u=Math.floor,l=Math.pow,b=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,h=1e7,p=u(1286742750677284.5),m={};function v(e,t){var r,n,a,i,o,s,f,d,u=e.constructor,l=u.precision;if(!e.s||!t.s)return t.s||(t=new u(e)),c?O(t,l):t;if(f=e.d,d=t.d,o=e.e,a=t.e,f=f.slice(),i=o-a){for(i<0?(n=f,i=-i,s=d.length):(n=d,a=o,s=f.length),i>(s=(o=Math.ceil(l/7))>s?o+1:s+1)&&(i=s,n.length=1),n.reverse();i--;)n.push(0);n.reverse()}for((s=f.length)-(i=d.length)<0&&(i=s,n=d,d=f,f=n),r=0;i;)r=(f[--i]=f[i]+d[i]+r)/h|0,f[i]%=h;for(r&&(f.unshift(r),++a),s=f.length;0==f[--s];)f.pop();return t.d=f,t.e=a,c?O(t,l):t}function g(e,t,r){if(e!==~~e||er)throw Error(f+e)}function x(e){var t,r,n,a=e.length-1,i="",o=e[0];if(a>0){for(i+=o,t=1;te.e^i.s<0?1:-1;for(t=0,r=(n=i.d.length)<(a=e.d.length)?n:a;te.d[t]^i.s<0?1:-1;return n===a?0:n>a^i.s<0?1:-1},m.decimalPlaces=m.dp=function(){var e=this,t=e.d.length-1,r=7*(t-e.e);if(t=e.d[t])for(;t%10==0;t/=10)r--;return r<0?0:r},m.dividedBy=m.div=function(e){return y(this,new this.constructor(e))},m.dividedToIntegerBy=m.idiv=function(e){var t=this.constructor;return O(y(this,new t(e),0,1),t.precision)},m.equals=m.eq=function(e){return!this.cmp(e)},m.exponent=function(){return k(this)},m.greaterThan=m.gt=function(e){return this.cmp(e)>0},m.greaterThanOrEqualTo=m.gte=function(e){return this.cmp(e)>=0},m.isInteger=m.isint=function(){return this.e>this.d.length-2},m.isNegative=m.isneg=function(){return this.s<0},m.isPositive=m.ispos=function(){return this.s>0},m.isZero=function(){return 0===this.s},m.lessThan=m.lt=function(e){return this.cmp(e)<0},m.lessThanOrEqualTo=m.lte=function(e){return this.cmp(e)<1},m.logarithm=m.log=function(e){var t,r=this,n=r.constructor,a=n.precision,o=a+5;if(void 0===e)e=new n(10);else if((e=new n(e)).s<1||e.eq(i))throw Error(s+"NaN");if(r.s<1)throw Error(s+(r.s?"NaN":"-Infinity"));return r.eq(i)?new n(0):(c=!1,t=y(S(r,o),S(e,o),o),c=!0,O(t,a))},m.minus=m.sub=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?A(t,e):v(t,(e.s=-e.s,e))},m.modulo=m.mod=function(e){var t,r=this,n=r.constructor,a=n.precision;if(!(e=new n(e)).s)throw Error(s+"NaN");return r.s?(c=!1,t=y(r,e,0,1).times(e),c=!0,r.minus(t)):O(new n(r),a)},m.naturalExponential=m.exp=function(){return w(this)},m.naturalLogarithm=m.ln=function(){return S(this)},m.negated=m.neg=function(){var e=new this.constructor(this);return e.s=-e.s||0,e},m.plus=m.add=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?v(t,e):A(t,(e.s=-e.s,e))},m.precision=m.sd=function(e){var t,r,n,a=this;if(void 0!==e&&e!==!!e&&1!==e&&0!==e)throw Error(f+e);if(t=k(a)+1,r=7*(n=a.d.length-1)+1,n=a.d[n]){for(;n%10==0;n/=10)r--;for(n=a.d[0];n>=10;n/=10)r++}return e&&t>r?t:r},m.squareRoot=m.sqrt=function(){var e,t,r,n,a,i,o,f=this,d=f.constructor;if(f.s<1){if(!f.s)return new d(0);throw Error(s+"NaN")}for(e=k(f),c=!1,0==(a=Math.sqrt(+f))||a==1/0?(((t=x(f.d)).length+e)%2==0&&(t+="0"),a=Math.sqrt(t),e=u((e+1)/2)-(e<0||e%2),n=new d(t=a==1/0?"5e"+e:(t=a.toExponential()).slice(0,t.indexOf("e")+1)+e)):n=new d(a.toString()),a=o=(r=d.precision)+3;;)if(n=(i=n).plus(y(f,i,o+2)).times(.5),x(i.d).slice(0,o)===(t=x(n.d)).slice(0,o)){if(t=t.slice(o-3,o+1),a==o&&"4999"==t){if(O(i,r+1,0),i.times(i).eq(f)){n=i;break}}else if("9999"!=t)break;o+=4}return c=!0,O(n,r)},m.times=m.mul=function(e){var t,r,n,a,i,o,s,f,d,u=this,l=u.constructor,b=u.d,p=(e=new l(e)).d;if(!u.s||!e.s)return new l(0);for(e.s*=u.s,r=u.e+e.e,(f=b.length)<(d=p.length)&&(i=b,b=p,p=i,o=f,f=d,d=o),i=[],n=o=f+d;n--;)i.push(0);for(n=d;--n>=0;){for(t=0,a=f+n;a>n;)s=i[a]+p[n]*b[a-n-1]+t,i[a--]=s%h|0,t=s/h|0;i[a]=(i[a]+t)%h|0}for(;!i[--o];)i.pop();return t?++r:i.shift(),e.d=i,e.e=r,c?O(e,l.precision):e},m.toDecimalPlaces=m.todp=function(e,t){var r=this,n=r.constructor;return r=new n(r),void 0===e?r:(g(e,0,1e9),void 0===t?t=n.rounding:g(t,0,8),O(r,e+k(r)+1,t))},m.toExponential=function(e,t){var r,n=this,a=n.constructor;return void 0===e?r=T(n,!0):(g(e,0,1e9),void 0===t?t=a.rounding:g(t,0,8),r=T(n=O(new a(n),e+1,t),!0,e+1)),r},m.toFixed=function(e,t){var r,n,a=this,i=a.constructor;return void 0===e?T(a):(g(e,0,1e9),void 0===t?t=i.rounding:g(t,0,8),r=T((n=O(new i(a),e+k(a)+1,t)).abs(),!1,e+k(n)+1),a.isneg()&&!a.isZero()?"-"+r:r)},m.toInteger=m.toint=function(){var e=this,t=e.constructor;return O(new t(e),k(e)+1,t.rounding)},m.toNumber=function(){return+this},m.toPower=m.pow=function(e){var t,r,n,a,o,f,d=this,l=d.constructor,b=+(e=new l(e));if(!e.s)return new l(i);if(!(d=new l(d)).s){if(e.s<1)throw Error(s+"Infinity");return d}if(d.eq(i))return d;if(n=l.precision,e.eq(i))return O(d,n);if(f=(t=e.e)>=(r=e.d.length-1),o=d.s,f){if((r=b<0?-b:b)<=9007199254740991){for(a=new l(i),t=Math.ceil(n/7+4),c=!1;r%2&&j((a=a.times(d)).d,t),0!==(r=u(r/2));)j((d=d.times(d)).d,t);return c=!0,e.s<0?new l(i).div(a):O(a,n)}}else if(o<0)throw Error(s+"NaN");return o=o<0&&1&e.d[Math.max(t,r)]?-1:1,d.s=1,c=!1,a=e.times(S(d,n+12)),c=!0,(a=w(a)).s=o,a},m.toPrecision=function(e,t){var r,n,a=this,i=a.constructor;return void 0===e?n=T(a,(r=k(a))<=i.toExpNeg||r>=i.toExpPos):(g(e,1,1e9),void 0===t?t=i.rounding:g(t,0,8),n=T(a=O(new i(a),e,t),e<=(r=k(a))||r<=i.toExpNeg,e)),n},m.toSignificantDigits=m.tosd=function(e,t){var r=this.constructor;return void 0===e?(e=r.precision,t=r.rounding):(g(e,1,1e9),void 0===t?t=r.rounding:g(t,0,8)),O(new r(this),e,t)},m.toString=m.valueOf=m.val=m.toJSON=function(){var e=this,t=k(e),r=e.constructor;return T(e,t<=r.toExpNeg||t>=r.toExpPos)};var y=function(){function e(e,t){var r,n=0,a=e.length;for(e=e.slice();a--;)r=e[a]*t+n,e[a]=r%h|0,n=r/h|0;return n&&e.unshift(n),e}function t(e,t,r,n){var a,i;if(r!=n)i=r>n?1:-1;else for(a=i=0;at[a]?1:-1;break}return i}function r(e,t,r){for(var n=0;r--;)e[r]-=n,n=e[r]1;)e.shift()}return function(n,a,i,o){var c,f,d,u,l,b,p,m,v,g,x,y,w,_,M,S,E,A,T=n.constructor,j=n.s==a.s?1:-1,P=n.d,C=a.d;if(!n.s)return new T(n);if(!a.s)throw Error(s+"Division by zero");for(f=n.e-a.e,E=C.length,M=P.length,m=(p=new T(j)).d=[],d=0;C[d]==(P[d]||0);)++d;if(C[d]>(P[d]||0)&&--f,(y=null==i?i=T.precision:o?i+(k(n)-k(a))+1:i)<0)return new T(0);if(y=y/7+2|0,d=0,1==E)for(u=0,C=C[0],y++;(d1&&(C=e(C,u),P=e(P,u),E=C.length,M=P.length),_=E,g=(v=P.slice(0,E)).length;g=h/2&&++S;do{u=0,(c=t(C,v,E,g))<0?(x=v[0],E!=g&&(x=x*h+(v[1]||0)),(u=x/S|0)>1?(u>=h&&(u=h-1),1==(c=t(l=e(C,u),v,b=l.length,g=v.length))&&(u--,r(l,E16)throw Error(d+k(e));if(!e.s)return new b(i);for(null==t?(c=!1,s=h):s=t,o=new b(.03125);e.abs().gte(.1);)e=e.times(o),u+=5;for(s+=Math.log(l(2,u))/Math.LN10*2+5|0,r=n=a=new b(i),b.precision=s;;){if(n=O(n.times(e),s),r=r.times(++f),x((o=a.plus(y(n,r,s))).d).slice(0,s)===x(a.d).slice(0,s)){for(;u--;)a=O(a.times(a),s);return b.precision=h,null==t?(c=!0,O(a,h)):a}a=o}}function k(e){for(var t=7*e.e,r=e.d[0];r>=10;r/=10)t++;return t}function _(e,t,r){if(t>e.LN10.sd())throw c=!0,r&&(e.precision=r),Error(s+"LN10 precision limit exceeded");return O(new e(e.LN10),t)}function M(e){for(var t="";e--;)t+="0";return t}function S(e,t){var r,n,a,o,f,d,u,l,b,h=1,p=e,m=p.d,v=p.constructor,g=v.precision;if(p.s<1)throw Error(s+(p.s?"NaN":"-Infinity"));if(p.eq(i))return new v(0);if(null==t?(c=!1,l=g):l=t,p.eq(10))return null==t&&(c=!0),_(v,l);if(l+=10,v.precision=l,n=(r=x(m)).charAt(0),o=k(p),!(Math.abs(o)<15e14))return u=_(v,l+2,g).times(o+""),p=S(new v(n+"."+r.slice(1)),l-10).plus(u),v.precision=g,null==t?(c=!0,O(p,g)):p;for(;n<7&&1!=n||1==n&&r.charAt(1)>3;)n=(r=x((p=p.times(e)).d)).charAt(0),h++;for(o=k(p),n>1?(p=new v("0."+r),o++):p=new v(n+"."+r.slice(1)),d=f=p=y(p.minus(i),p.plus(i),l),b=O(p.times(p),l),a=3;;){if(f=O(f.times(b),l),x((u=d.plus(y(f,new v(a),l))).d).slice(0,l)===x(d.d).slice(0,l))return d=d.times(2),0!==o&&(d=d.plus(_(v,l+2,g).times(o+""))),d=y(d,new v(h),l),v.precision=g,null==t?(c=!0,O(d,g)):d;d=u,a+=2}}function E(e,t){var r,n,a;for((r=t.indexOf("."))>-1&&(t=t.replace(".","")),(n=t.search(/e/i))>0?(r<0&&(r=n),r+=+t.slice(n+1),t=t.substring(0,n)):r<0&&(r=t.length),n=0;48===t.charCodeAt(n);)++n;for(a=t.length;48===t.charCodeAt(a-1);)--a;if(t=t.slice(n,a)){if(a-=n,r=r-n-1,e.e=u(r/7),e.d=[],n=(r+1)%7,r<0&&(n+=7),np||e.e<-p))throw Error(d+r)}else e.s=0,e.e=0,e.d=[0];return e}function O(e,t,r){var n,a,i,o,s,f,b,m,v=e.d;for(o=1,i=v[0];i>=10;i/=10)o++;if((n=t-o)<0)n+=7,a=t,b=v[m=0];else{if((m=Math.ceil((n+1)/7))>=(i=v.length))return e;for(b=i=v[m],o=1;i>=10;i/=10)o++;a=(n%=7)-7+o}if(void 0!==r&&(s=b/(i=l(10,o-a-1))%10|0,f=t<0||void 0!==v[m+1]||b%i,f=r<4?(s||f)&&(0==r||r==(e.s<0?3:2)):s>5||5==s&&(4==r||f||6==r&&(n>0?a>0?b/l(10,o-a):0:v[m-1])%10&1||r==(e.s<0?8:7))),t<1||!v[0])return f?(i=k(e),v.length=1,t=t-i-1,v[0]=l(10,(7-t%7)%7),e.e=u(-t/7)||0):(v.length=1,v[0]=e.e=e.s=0),e;if(0==n?(v.length=m,i=1,m--):(v.length=m+1,i=l(10,7-n),v[m]=a>0?(b/l(10,o-a)%l(10,a)|0)*i:0),f)for(;;){if(0==m){(v[0]+=i)==h&&(v[0]=1,++e.e);break}if(v[m]+=i,v[m]!=h)break;v[m--]=0,i=1}for(n=v.length;0===v[--n];)v.pop();if(c&&(e.e>p||e.e<-p))throw Error(d+k(e));return e}function A(e,t){var r,n,a,i,o,s,f,d,u,l,b=e.constructor,p=b.precision;if(!e.s||!t.s)return t.s?t.s=-t.s:t=new b(e),c?O(t,p):t;if(f=e.d,l=t.d,n=t.e,d=e.e,f=f.slice(),o=d-n){for((u=o<0)?(r=f,o=-o,s=l.length):(r=l,n=d,s=f.length),o>(a=Math.max(Math.ceil(p/7),s)+2)&&(o=a,r.length=1),r.reverse(),a=o;a--;)r.push(0);r.reverse()}else{for((u=(a=f.length)<(s=l.length))&&(s=a),a=0;a0;--a)f[s++]=0;for(a=l.length;a>o;){if(f[--a]0?i=i.charAt(0)+"."+i.slice(1)+M(n):o>1&&(i=i.charAt(0)+"."+i.slice(1)),i=i+(a<0?"e":"e+")+a):a<0?(i="0."+M(-a-1)+i,r&&(n=r-o)>0&&(i+=M(n))):a>=o?(i+=M(a+1-o),r&&(n=r-a-1)>0&&(i=i+"."+M(n))):((n=a+1)0&&(a+1===o&&(i+="."),i+=M(n))),e.s<0?"-"+i:i}function j(e,t){if(e.length>t)return e.length=t,!0}function P(e){if(!e||"object"!==typeof e)throw Error(s+"Object expected");var t,r,n,a=["precision",1,1e9,"rounding",0,8,"toExpNeg",-1/0,0,"toExpPos",0,1/0];for(t=0;t=a[t+1]&&n<=a[t+2]))throw Error(f+r+": "+n);this[r]=n}if(void 0!==(n=e[r="LN10"])){if(n!=Math.LN10)throw Error(f+r+": "+n);this[r]=new this(n)}return this}(o=function e(t){var r,n,a;function i(e){var t=this;if(!(t instanceof i))return new i(e);if(t.constructor=i,e instanceof i)return t.s=e.s,t.e=e.e,void(t.d=(e=e.d)?e.slice():e);if("number"===typeof e){if(0*e!==0)throw Error(f+e);if(e>0)t.s=1;else{if(!(e<0))return t.s=0,t.e=0,void(t.d=[0]);e=-e,t.s=-1}return e===~~e&&e<1e7?(t.e=0,void(t.d=[e])):E(t,e.toString())}if("string"!==typeof e)throw Error(f+e);if(45===e.charCodeAt(0)?(e=e.slice(1),t.s=-1):t.s=1,!b.test(e))throw Error(f+e);E(t,e)}if(i.prototype=m,i.ROUND_UP=0,i.ROUND_DOWN=1,i.ROUND_CEIL=2,i.ROUND_FLOOR=3,i.ROUND_HALF_UP=4,i.ROUND_HALF_DOWN=5,i.ROUND_HALF_EVEN=6,i.ROUND_HALF_CEIL=7,i.ROUND_HALF_FLOOR=8,i.clone=e,i.config=i.set=P,void 0===t&&(t={}),t)for(a=["precision","rounding","toExpNeg","toExpPos","LN10"],r=0;r>8,o=255&a;i?r.push(i,o):r.push(o)}return r},r.zero2=n,r.toHex=a,r.encode=function(e,t){return"hex"===t?a(e):e}})),u=c((function(e,t){var r=t;r.assert=s,r.toArray=d.toArray,r.zero2=d.zero2,r.toHex=d.toHex,r.encode=d.encode,r.getNAF=function(e,t,r){var n=new Array(Math.max(e.bitLength(),r)+1);n.fill(0);for(var a=1<(a>>1)-1?(a>>1)-s:s,i.isubn(c)):c=0,n[o]=c,i.iushrn(1)}return n},r.getJSF=function(e,t){var r=[[],[]];e=e.clone(),t=t.clone();for(var n,a=0,i=0;e.cmpn(-a)>0||t.cmpn(-i)>0;){var o,c,s=e.andln(3)+a&3,f=t.andln(3)+i&3;3===s&&(s=-1),3===f&&(f=-1),o=0===(1&s)?0:3!==(n=e.andln(7)+a&7)&&5!==n||2!==f?s:-s,r[0].push(o),c=0===(1&f)?0:3!==(n=t.andln(7)+i&7)&&5!==n||2!==s?f:-f,r[1].push(c),2*a===o+1&&(a=1-a),2*i===c+1&&(i=1-i),e.iushrn(1),t.iushrn(1)}return r},r.cachedProperty=function(e,t,r){var n="_"+t;e.prototype[t]=function(){return void 0!==this[n]?this[n]:this[n]=r.call(this)}},r.parseBytes=function(e){return"string"===typeof e?r.toArray(e,"hex"):e},r.intFromLE=function(e){return new a.a(e,"hex","le")}})),l=u.getNAF,b=u.getJSF,h=u.assert;function p(e,t){this.type=e,this.p=new a.a(t.p,16),this.red=t.prime?a.a.red(t.prime):a.a.mont(this.p),this.zero=new a.a(0).toRed(this.red),this.one=new a.a(1).toRed(this.red),this.two=new a.a(2).toRed(this.red),this.n=t.n&&new a.a(t.n,16),this.g=t.g&&this.pointFromJSON(t.g,t.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var r=this.n&&this.p.div(this.n);!r||r.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}var m=p;function v(e,t){this.curve=e,this.type=t,this.precomputed=null}p.prototype.point=function(){throw new Error("Not implemented")},p.prototype.validate=function(){throw new Error("Not implemented")},p.prototype._fixedNafMul=function(e,t){h(e.precomputed);var r=e._getDoubles(),n=l(t,1,this._bitLength),a=(1<=i;s--)o=(o<<1)+n[s];c.push(o)}for(var f=this.jpoint(null,null,null),d=this.jpoint(null,null,null),u=a;u>0;u--){for(i=0;i=0;c--){for(var s=0;c>=0&&0===i[c];c--)s++;if(c>=0&&s++,o=o.dblp(s),c<0)break;var f=i[c];h(0!==f),o="affine"===e.type?f>0?o.mixedAdd(a[f-1>>1]):o.mixedAdd(a[-f-1>>1].neg()):f>0?o.add(a[f-1>>1]):o.add(a[-f-1>>1].neg())}return"affine"===e.type?o.toP():o},p.prototype._wnafMulAdd=function(e,t,r,n,a){var i,o,c,s=this._wnafT1,f=this._wnafT2,d=this._wnafT3,u=0;for(i=0;i=1;i-=2){var p=i-1,m=i;if(1===s[p]&&1===s[m]){var v=[t[p],null,null,t[m]];0===t[p].y.cmp(t[m].y)?(v[1]=t[p].add(t[m]),v[2]=t[p].toJ().mixedAdd(t[m].neg())):0===t[p].y.cmp(t[m].y.redNeg())?(v[1]=t[p].toJ().mixedAdd(t[m]),v[2]=t[p].add(t[m].neg())):(v[1]=t[p].toJ().mixedAdd(t[m]),v[2]=t[p].toJ().mixedAdd(t[m].neg()));var g=[-3,-1,-5,-7,0,7,5,1,3],x=b(r[p],r[m]);for(u=Math.max(x[0].length,u),d[p]=new Array(u),d[m]=new Array(u),o=0;o=0;i--){for(var M=0;i>=0;){var S=!0;for(o=0;o=0&&M++,k=k.dblp(M),i<0)break;for(o=0;o0?c=f[o][E-1>>1]:E<0&&(c=f[o][-E-1>>1].neg()),k="affine"===c.type?k.mixedAdd(c):k.add(c))}}for(i=0;i=Math.ceil((e.bitLength()+1)/t.step)},v.prototype._getDoubles=function(e,t){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var r=[this],n=this,a=0;a=0&&(o=t,c=r),n.negative&&(n=n.neg(),i=i.neg()),o.negative&&(o=o.neg(),c=c.neg()),[{a:n,b:i},{a:o,b:c}]},y.prototype._endoSplit=function(e){var t=this.endo.basis,r=t[0],n=t[1],a=n.b.mul(e).divRound(this.n),i=r.b.neg().mul(e).divRound(this.n),o=a.mul(r.a),c=i.mul(n.a),s=a.mul(r.b),f=i.mul(n.b);return{k1:e.sub(o).sub(c),k2:s.add(f).neg()}},y.prototype.pointFromX=function(e,t){(e=new a.a(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr().redMul(e).redIAdd(e.redMul(this.a)).redIAdd(this.b),n=r.redSqrt();if(0!==n.redSqr().redSub(r).cmp(this.zero))throw new Error("invalid point");var i=n.fromRed().isOdd();return(t&&!i||!t&&i)&&(n=n.redNeg()),this.point(e,n)},y.prototype.validate=function(e){if(e.inf)return!0;var t=e.x,r=e.y,n=this.a.redMul(t),a=t.redSqr().redMul(t).redIAdd(n).redIAdd(this.b);return 0===r.redSqr().redISub(a).cmpn(0)},y.prototype._endoWnafMulAdd=function(e,t,r){for(var n=this._endoWnafT1,a=this._endoWnafT2,i=0;i":""},k.prototype.isInfinity=function(){return this.inf},k.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;if(this.eq(e))return this.dbl();if(this.neg().eq(e))return this.curve.point(null,null);if(0===this.x.cmp(e.x))return this.curve.point(null,null);var t=this.y.redSub(e.y);0!==t.cmpn(0)&&(t=t.redMul(this.x.redSub(e.x).redInvm()));var r=t.redSqr().redISub(this.x).redISub(e.x),n=t.redMul(this.x.redSub(r)).redISub(this.y);return this.curve.point(r,n)},k.prototype.dbl=function(){if(this.inf)return this;var e=this.y.redAdd(this.y);if(0===e.cmpn(0))return this.curve.point(null,null);var t=this.curve.a,r=this.x.redSqr(),n=e.redInvm(),a=r.redAdd(r).redIAdd(r).redIAdd(t).redMul(n),i=a.redSqr().redISub(this.x.redAdd(this.x)),o=a.redMul(this.x.redSub(i)).redISub(this.y);return this.curve.point(i,o)},k.prototype.getX=function(){return this.x.fromRed()},k.prototype.getY=function(){return this.y.fromRed()},k.prototype.mul=function(e){return e=new a.a(e,16),this.isInfinity()?this:this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve.endo?this.curve._endoWnafMulAdd([this],[e]):this.curve._wnafMul(this,e)},k.prototype.mulAdd=function(e,t,r){var n=[this,t],a=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,a):this.curve._wnafMulAdd(1,n,a,2)},k.prototype.jmulAdd=function(e,t,r){var n=[this,t],a=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,a,!0):this.curve._wnafMulAdd(1,n,a,2,!0)},k.prototype.eq=function(e){return this===e||this.inf===e.inf&&(this.inf||0===this.x.cmp(e.x)&&0===this.y.cmp(e.y))},k.prototype.neg=function(e){if(this.inf)return this;var t=this.curve.point(this.x,this.y.redNeg());if(e&&this.precomputed){var r=this.precomputed,n=function(e){return e.neg()};t.precomputed={naf:r.naf&&{wnd:r.naf.wnd,points:r.naf.points.map(n)},doubles:r.doubles&&{step:r.doubles.step,points:r.doubles.points.map(n)}}}return t},k.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},g(_,m.BasePoint),y.prototype.jpoint=function(e,t,r){return new _(this,e,t,r)},_.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var e=this.z.redInvm(),t=e.redSqr(),r=this.x.redMul(t),n=this.y.redMul(t).redMul(e);return this.curve.point(r,n)},_.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},_.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var t=e.z.redSqr(),r=this.z.redSqr(),n=this.x.redMul(t),a=e.x.redMul(r),i=this.y.redMul(t.redMul(e.z)),o=e.y.redMul(r.redMul(this.z)),c=n.redSub(a),s=i.redSub(o);if(0===c.cmpn(0))return 0!==s.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var f=c.redSqr(),d=f.redMul(c),u=n.redMul(f),l=s.redSqr().redIAdd(d).redISub(u).redISub(u),b=s.redMul(u.redISub(l)).redISub(i.redMul(d)),h=this.z.redMul(e.z).redMul(c);return this.curve.jpoint(l,b,h)},_.prototype.mixedAdd=function(e){if(this.isInfinity())return e.toJ();if(e.isInfinity())return this;var t=this.z.redSqr(),r=this.x,n=e.x.redMul(t),a=this.y,i=e.y.redMul(t).redMul(this.z),o=r.redSub(n),c=a.redSub(i);if(0===o.cmpn(0))return 0!==c.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var s=o.redSqr(),f=s.redMul(o),d=r.redMul(s),u=c.redSqr().redIAdd(f).redISub(d).redISub(d),l=c.redMul(d.redISub(u)).redISub(a.redMul(f)),b=this.z.redMul(o);return this.curve.jpoint(u,l,b)},_.prototype.dblp=function(e){if(0===e)return this;if(this.isInfinity())return this;if(!e)return this.dbl();var t;if(this.curve.zeroA||this.curve.threeA){var r=this;for(t=0;t=0)return!1;if(r.redIAdd(a),0===this.x.cmp(r))return!0}},_.prototype.inspect=function(){return this.isInfinity()?"":""},_.prototype.isInfinity=function(){return 0===this.z.cmpn(0)};var M=c((function(e,t){var r=t;r.base=m,r.short=w,r.mont=null,r.edwards=null})),S=c((function(e,t){var r,n=t,a=u.assert;function i(e){"short"===e.type?this.curve=new M.short(e):"edwards"===e.type?this.curve=new M.edwards(e):this.curve=new M.mont(e),this.g=this.curve.g,this.n=this.curve.n,this.hash=e.hash,a(this.g.validate(),"Invalid curve"),a(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function c(e,t){Object.defineProperty(n,e,{configurable:!0,enumerable:!0,get:function(){var r=new i(t);return Object.defineProperty(n,e,{configurable:!0,enumerable:!0,value:r}),r}})}n.PresetCurve=i,c("p192",{type:"short",prime:"p192",p:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff",a:"ffffffff ffffffff ffffffff fffffffe ffffffff fffffffc",b:"64210519 e59c80e7 0fa7e9ab 72243049 feb8deec c146b9b1",n:"ffffffff ffffffff ffffffff 99def836 146bc9b1 b4d22831",hash:o.a.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),c("p224",{type:"short",prime:"p224",p:"ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001",a:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff fffffffe",b:"b4050a85 0c04b3ab f5413256 5044b0b7 d7bfd8ba 270b3943 2355ffb4",n:"ffffffff ffffffff ffffffff ffff16a2 e0b8f03e 13dd2945 5c5c2a3d",hash:o.a.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),c("p256",{type:"short",prime:null,p:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff ffffffff",a:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff fffffffc",b:"5ac635d8 aa3a93e7 b3ebbd55 769886bc 651d06b0 cc53b0f6 3bce3c3e 27d2604b",n:"ffffffff 00000000 ffffffff ffffffff bce6faad a7179e84 f3b9cac2 fc632551",hash:o.a.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),c("p384",{type:"short",prime:null,p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 ffffffff",a:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 fffffffc",b:"b3312fa7 e23ee7e4 988e056b e3f82d19 181d9c6e fe814112 0314088f 5013875a c656398d 8a2ed19d 2a85c8ed d3ec2aef",n:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff c7634d81 f4372ddf 581a0db2 48b0a77a ecec196a ccc52973",hash:o.a.sha384,gRed:!1,g:["aa87ca22 be8b0537 8eb1c71e f320ad74 6e1d3b62 8ba79b98 59f741e0 82542a38 5502f25d bf55296c 3a545e38 72760ab7","3617de4a 96262c6f 5d9e98bf 9292dc29 f8f41dbd 289a147c e9da3113 b5f0b8c0 0a60b1ce 1d7e819d 7a431d7c 90ea0e5f"]}),c("p521",{type:"short",prime:null,p:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff",a:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffc",b:"00000051 953eb961 8e1c9a1f 929a21a0 b68540ee a2da725b 99b315f3 b8b48991 8ef109e1 56193951 ec7e937b 1652c0bd 3bb1bf07 3573df88 3d2c34f1 ef451fd4 6b503f00",n:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffa 51868783 bf2f966b 7fcc0148 f709a5d0 3bb5c9b8 899c47ae bb6fb71e 91386409",hash:o.a.sha512,gRed:!1,g:["000000c6 858e06b7 0404e9cd 9e3ecb66 2395b442 9c648139 053fb521 f828af60 6b4d3dba a14b5e77 efe75928 fe1dc127 a2ffa8de 3348b3c1 856a429b f97e7e31 c2e5bd66","00000118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd9 98f54449 579b4468 17afbd17 273e662c 97ee7299 5ef42640 c550b901 3fad0761 353c7086 a272c240 88be9476 9fd16650"]}),c("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:o.a.sha256,gRed:!1,g:["9"]}),c("ed25519",{type:"edwards",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"-1",c:"1",d:"52036cee2b6ffe73 8cc740797779e898 00700a4d4141d8ab 75eb4dca135978a3",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:o.a.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});try{r=null.crash()}catch(s){r=void 0}c("secp256k1",{type:"short",prime:"k256",p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f",a:"0",b:"7",n:"ffffffff ffffffff ffffffff fffffffe baaedce6 af48a03b bfd25e8c d0364141",h:"1",hash:o.a.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",r]})}));function E(e){if(!(this instanceof E))return new E(e);this.hash=e.hash,this.predResist=!!e.predResist,this.outLen=this.hash.outSize,this.minEntropy=e.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var t=d.toArray(e.entropy,e.entropyEnc||"hex"),r=d.toArray(e.nonce,e.nonceEnc||"hex"),n=d.toArray(e.pers,e.persEnc||"hex");s(t.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(t,r,n)}var O=E;E.prototype._init=function(e,t,r){var n=e.concat(t).concat(r);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var a=0;a=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(e.concat(r||[])),this._reseed=1},E.prototype.generate=function(e,t,r,n){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");"string"!==typeof t&&(n=r,r=t,t=null),r&&(r=d.toArray(r,n||"hex"),this._update(r));for(var a=[];a.length"};var P=u.assert;function C(e,t){if(e instanceof C)return e;this._importDER(e,t)||(P(e.r&&e.s,"Signature without r or s"),this.r=new a.a(e.r,16),this.s=new a.a(e.s,16),void 0===e.recoveryParam?this.recoveryParam=null:this.recoveryParam=e.recoveryParam)}var R=C;function N(){this.place=0}function B(e,t){var r=e[t.place++];if(!(128&r))return r;var n=15&r;if(0===n||n>4)return!1;for(var a=0,i=0,o=t.place;i>>=0;return!(a<=127)&&(t.place=o,a)}function L(e){for(var t=0,r=e.length-1;!e[t]&&!(128&e[t+1])&&t>>3);for(e.push(128|r);--r;)e.push(t>>>(r<<3)&255);e.push(t)}}C.prototype._importDER=function(e,t){e=u.toArray(e,t);var r=new N;if(48!==e[r.place++])return!1;var n=B(e,r);if(!1===n)return!1;if(n+r.place!==e.length)return!1;if(2!==e[r.place++])return!1;var i=B(e,r);if(!1===i)return!1;var o=e.slice(r.place,i+r.place);if(r.place+=i,2!==e[r.place++])return!1;var c=B(e,r);if(!1===c)return!1;if(e.length!==c+r.place)return!1;var s=e.slice(r.place,c+r.place);if(0===o[0]){if(!(128&o[1]))return!1;o=o.slice(1)}if(0===s[0]){if(!(128&s[1]))return!1;s=s.slice(1)}return this.r=new a.a(o),this.s=new a.a(s),this.recoveryParam=null,!0},C.prototype.toDER=function(e){var t=this.r.toArray(),r=this.s.toArray();for(128&t[0]&&(t=[0].concat(t)),128&r[0]&&(r=[0].concat(r)),t=L(t),r=L(r);!r[0]&&!(128&r[1]);)r=r.slice(1);var n=[2];I(n,t.length),(n=n.concat(t)).push(2),I(n,r.length);var a=n.concat(r),i=[48];return I(i,a.length),i=i.concat(a),u.encode(i,e)};var F=function(){throw new Error("unsupported")},D=u.assert;function U(e){if(!(this instanceof U))return new U(e);"string"===typeof e&&(D(Object.prototype.hasOwnProperty.call(S,e),"Unknown curve "+e),e=S[e]),e instanceof S.PresetCurve&&(e={curve:e}),this.curve=e.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=e.curve.g,this.g.precompute(e.curve.n.bitLength()+1),this.hash=e.hash||e.curve.hash}var z=U;U.prototype.keyPair=function(e){return new j(this,e)},U.prototype.keyFromPrivate=function(e,t){return j.fromPrivate(this,e,t)},U.prototype.keyFromPublic=function(e,t){return j.fromPublic(this,e,t)},U.prototype.genKeyPair=function(e){e||(e={});for(var t=new O({hash:this.hash,pers:e.pers,persEnc:e.persEnc||"utf8",entropy:e.entropy||F(this.hash.hmacStrength),entropyEnc:e.entropy&&e.entropyEnc||"utf8",nonce:this.n.toArray()}),r=this.n.byteLength(),n=this.n.sub(new a.a(2));;){var i=new a.a(t.generate(r));if(!(i.cmp(n)>0))return i.iaddn(1),this.keyFromPrivate(i)}},U.prototype._truncateToN=function(e,t){var r=8*e.byteLength()-this.n.bitLength();return r>0&&(e=e.ushrn(r)),!t&&e.cmp(this.n)>=0?e.sub(this.n):e},U.prototype.sign=function(e,t,r,n){"object"===typeof r&&(n=r,r=null),n||(n={}),t=this.keyFromPrivate(t,r),e=this._truncateToN(new a.a(e,16));for(var i=this.n.byteLength(),o=t.getPrivate().toArray("be",i),c=e.toArray("be",i),s=new O({hash:this.hash,entropy:o,nonce:c,pers:n.pers,persEnc:n.persEnc||"utf8"}),f=this.n.sub(new a.a(1)),d=0;;d++){var u=n.k?n.k(d):new a.a(s.generate(this.n.byteLength()));if(!((u=this._truncateToN(u,!0)).cmpn(1)<=0||u.cmp(f)>=0)){var l=this.g.mul(u);if(!l.isInfinity()){var b=l.getX(),h=b.umod(this.n);if(0!==h.cmpn(0)){var p=u.invm(this.n).mul(h.mul(t.getPrivate()).iadd(e));if(0!==(p=p.umod(this.n)).cmpn(0)){var m=(l.getY().isOdd()?1:0)|(0!==b.cmp(h)?2:0);return n.canonical&&p.cmp(this.nh)>0&&(p=this.n.sub(p),m^=1),new R({r:h,s:p,recoveryParam:m})}}}}}},U.prototype.verify=function(e,t,r,n){e=this._truncateToN(new a.a(e,16)),r=this.keyFromPublic(r,n);var i=(t=new R(t,"hex")).r,o=t.s;if(i.cmpn(1)<0||i.cmp(this.n)>=0)return!1;if(o.cmpn(1)<0||o.cmp(this.n)>=0)return!1;var c,s=o.invm(this.n),f=s.mul(e).umod(this.n),d=s.mul(i).umod(this.n);return this.curve._maxwellTrick?!(c=this.g.jmulAdd(f,r.getPublic(),d)).isInfinity()&&c.eqXToP(i):!(c=this.g.mulAdd(f,r.getPublic(),d)).isInfinity()&&0===c.getX().umod(this.n).cmp(i)},U.prototype.recoverPubKey=function(e,t,r,n){D((3&r)===r,"The recovery param is more than two bits"),t=new R(t,n);var i=this.n,o=new a.a(e),c=t.r,s=t.s,f=1&r,d=r>>1;if(c.cmp(this.curve.p.umod(this.curve.n))>=0&&d)throw new Error("Unable to find sencond key candinate");c=d?this.curve.pointFromX(c.add(this.curve.n),f):this.curve.pointFromX(c,f);var u=t.r.invm(i),l=i.sub(o).mul(u).umod(i),b=s.mul(u).umod(i);return this.g.mulAdd(l,c,b)},U.prototype.getKeyRecoveryParam=function(e,t,r,n){if(null!==(t=new R(t,n)).recoveryParam)return t.recoveryParam;for(var a=0;a<4;a++){var i;try{i=this.recoverPubKey(e,t,a)}catch(e){continue}if(i.eq(r))return a}throw new Error("Unable to find valid recovery factor")};var H=c((function(e,t){var r=t;r.version="6.5.4",r.utils=u,r.rand=function(){throw new Error("unsupported")},r.curve=M,r.curves=S,r.ec=z,r.eddsa=null})).ec}).call(this,r(44))},,function(e,t,r){"use strict";r.d(t,"a",(function(){return o}));var n=r(137);function a(){return(a=Object.assign||function(e){for(var t=1;t3&&r&&r(i.responseText,i)},i.send(n)}catch(f){console&&console.log(f)}}function b(){return{loadPath:"/locales/{{lng}}/{{ns}}.json",addPath:"/locales/add/{{lng}}/{{ns}}",allowMultiLoading:!1,parse:JSON.parse,parsePayload:function(e,t,r){return Object(i.a)({},t,r||"")},crossDomain:!1,ajax:l}}var h=function(){function e(t){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Object(n.a)(this,e),this.init(t,r),this.type="backend"}return Object(a.a)(e,[{key:"init",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.services=e,this.options=d(t,this.options||{},b())}},{key:"readMulti",value:function(e,t,r){var n=this.options.loadPath;"function"===typeof this.options.loadPath&&(n=this.options.loadPath(e,t));var a=this.services.interpolator.interpolate(n,{lng:e.join("+"),ns:t.join("+")});this.loadUrl(a,r)}},{key:"read",value:function(e,t,r){var n=this.options.loadPath;"function"===typeof this.options.loadPath&&(n=this.options.loadPath([e],[t]));var a=this.services.interpolator.interpolate(n,{lng:e,ns:t});this.loadUrl(a,r)}},{key:"loadUrl",value:function(e,t){var r=this;this.options.ajax(e,this.options,(function(n,a){if(a.status>=500&&a.status<600)return t("failed loading "+e,!0);if(a.status>=400&&a.status<500)return t("failed loading "+e,!1);var i,o;try{i=r.options.parse(n,e)}catch(c){o="failed parsing "+e+" to json"}if(o)return t(o,!1);t(null,i)}))}},{key:"create",value:function(e,t,r,n){var a=this;"string"===typeof e&&(e=[e]);var i=this.options.parsePayload(t,r,n);e.forEach((function(e){var r=a.services.interpolator.interpolate(a.options.addPath,{lng:e,ns:t});a.options.ajax(r,a.options,(function(e,t){}),i)}))}}]),e}();h.type="backend",t.a=h},function(e,t,r){"use strict";var n=r(54),a=r(55),i=[],o=i.forEach,c=i.slice;function s(e){return o.call(c.call(arguments,1),(function(t){if(t)for(var r in t)void 0===e[r]&&(e[r]=t[r])})),e}var f=/^[\u0009\u0020-\u007e\u0080-\u00ff]+$/,d=function(e,t,r){var n=r||{};n.path=n.path||"/";var a=e+"="+encodeURIComponent(t);if(n.maxAge>0){var i=n.maxAge-0;if(isNaN(i))throw new Error("maxAge should be a Number");a+="; Max-Age="+Math.floor(i)}if(n.domain){if(!f.test(n.domain))throw new TypeError("option domain is invalid");a+="; Domain="+n.domain}if(n.path){if(!f.test(n.path))throw new TypeError("option path is invalid");a+="; Path="+n.path}if(n.expires){if("function"!==typeof n.expires.toUTCString)throw new TypeError("option expires is invalid");a+="; Expires="+n.expires.toUTCString()}if(n.httpOnly&&(a+="; HttpOnly"),n.secure&&(a+="; Secure"),n.sameSite)switch("string"===typeof n.sameSite?n.sameSite.toLowerCase():n.sameSite){case!0:a+="; SameSite=Strict";break;case"lax":a+="; SameSite=Lax";break;case"strict":a+="; SameSite=Strict";break;case"none":a+="; SameSite=None";break;default:throw new TypeError("option sameSite is invalid")}return a},u=function(e,t,r,n){var a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{path:"/",sameSite:"strict"};r&&(a.expires=new Date,a.expires.setTime(a.expires.getTime()+60*r*1e3)),n&&(a.domain=n),document.cookie=d(e,encodeURIComponent(t),a)},l=function(e){for(var t=e+"=",r=document.cookie.split(";"),n=0;n0)r[n].substring(0,a)===e.lookupQuerystring&&(t=r[n].substring(a+1))}return t}},p=null,m=function(){if(null!==p)return p;try{p="undefined"!==window&&null!==window.localStorage;window.localStorage.setItem("i18next.translate.boo","foo"),window.localStorage.removeItem("i18next.translate.boo")}catch(e){p=!1}return p},v={name:"localStorage",lookup:function(e){var t;if(e.lookupLocalStorage&&m()){var r=window.localStorage.getItem(e.lookupLocalStorage);r&&(t=r)}return t},cacheUserLanguage:function(e,t){t.lookupLocalStorage&&m()&&window.localStorage.setItem(t.lookupLocalStorage,e)}},g=null,x=function(){if(null!==g)return g;try{g="undefined"!==window&&null!==window.sessionStorage;window.sessionStorage.setItem("i18next.translate.boo","foo"),window.sessionStorage.removeItem("i18next.translate.boo")}catch(e){g=!1}return g},y={name:"sessionStorage",lookup:function(e){var t;if(e.lookupSessionStorage&&x()){var r=window.sessionStorage.getItem(e.lookupSessionStorage);r&&(t=r)}return t},cacheUserLanguage:function(e,t){t.lookupSessionStorage&&x()&&window.sessionStorage.setItem(t.lookupSessionStorage,e)}},w={name:"navigator",lookup:function(e){var t=[];if("undefined"!==typeof navigator){if(navigator.languages)for(var r=0;r0?t:void 0}},k={name:"htmlTag",lookup:function(e){var t,r=e.htmlTag||("undefined"!==typeof document?document.documentElement:null);return r&&"function"===typeof r.getAttribute&&(t=r.getAttribute("lang")),t}},_={name:"path",lookup:function(e){var t;if("undefined"!==typeof window){var r=window.location.pathname.match(/\/([a-zA-Z-]*)/g);if(r instanceof Array)if("number"===typeof e.lookupFromPathIndex){if("string"!==typeof r[e.lookupFromPathIndex])return;t=r[e.lookupFromPathIndex].replace("/","")}else t=r[0].replace("/","")}return t}},M={name:"subdomain",lookup:function(e){var t;if("undefined"!==typeof window){var r=window.location.href.match(/(?:http[s]*\:\/\/)*(.*?)\.(?=[^\/]*\..{2,5})/gi);r instanceof Array&&(t="number"===typeof e.lookupFromSubdomainIndex?r[e.lookupFromSubdomainIndex].replace("http://","").replace("https://","").replace(".",""):r[0].replace("http://","").replace("https://","").replace(".",""))}return t}};var S=function(){function e(t){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Object(n.a)(this,e),this.type="languageDetector",this.detectors={},this.init(t,r)}return Object(a.a)(e,[{key:"init",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};this.services=e,this.options=s(t,this.options||{},{order:["querystring","cookie","localStorage","sessionStorage","navigator","htmlTag"],lookupQuerystring:"lng",lookupCookie:"i18next",lookupLocalStorage:"i18nextLng",lookupSessionStorage:"i18nextLng",caches:["localStorage"],excludeCacheFor:["cimode"]}),this.options.lookupFromUrlIndex&&(this.options.lookupFromPathIndex=this.options.lookupFromUrlIndex),this.i18nOptions=r,this.addDetector(b),this.addDetector(h),this.addDetector(v),this.addDetector(y),this.addDetector(w),this.addDetector(k),this.addDetector(_),this.addDetector(M)}},{key:"addDetector",value:function(e){this.detectors[e.name]=e}},{key:"detect",value:function(e){var t=this;e||(e=this.options.order);var r=[];return e.forEach((function(e){if(t.detectors[e]){var n=t.detectors[e].lookup(t.options);n&&"string"===typeof n&&(n=[n]),n&&(r=r.concat(n))}})),this.services.languageUtils.getBestMatchFromCodes?r:r.length>0?r[0]:null}},{key:"cacheUserLanguage",value:function(e,t){var r=this;t||(t=this.options.caches),t&&(this.options.excludeCacheFor&&this.options.excludeCacheFor.indexOf(e)>-1||t.forEach((function(t){r.detectors[t]&&r.detectors[t].cacheUserLanguage(e,r.options)})))}}]),e}();S.type="languageDetector",t.a=S},function(e,t,r){"use strict";r.d(t,"a",(function(){return n}));var n="random/5.5.1"},function(e,t,r){(function(t,r){!function(){"use strict";var n="object"===typeof window?window:{};!n.JS_SHA3_NO_NODE_JS&&"object"===typeof t&&t.versions&&t.versions.node&&(n=r);for(var a=!n.JS_SHA3_NO_COMMON_JS&&"object"===typeof e&&e.exports,i="0123456789abcdef".split(""),o=[0,8,16,24],c=[1,0,32898,0,32906,2147483648,2147516416,2147483648,32907,0,2147483649,0,2147516545,2147483648,32777,2147483648,138,0,136,0,2147516425,0,2147483658,0,2147516555,0,139,2147483648,32905,2147483648,32771,2147483648,32770,2147483648,128,2147483648,32778,0,2147483658,2147483648,2147516545,2147483648,32896,2147483648,2147483649,0,2147516424,2147483648],s=[224,256,384,512],f=["hex","buffer","arrayBuffer","array"],d=function(e,t,r){return function(n){return new w(e,t,e).update(n)[r]()}},u=function(e,t,r){return function(n,a){return new w(e,t,a).update(n)[r]()}},l=function(e,t){var r=d(e,t,"hex");r.create=function(){return new w(e,t,e)},r.update=function(e){return r.create().update(e)};for(var n=0;n>5,this.byteCount=this.blockCount<<2,this.outputBlocks=r>>5,this.extraBytes=(31&r)>>3;for(var n=0;n<50;++n)this.s[n]=0}w.prototype.update=function(e){var t="string"!==typeof e;t&&e.constructor===ArrayBuffer&&(e=new Uint8Array(e));for(var r,n,a=e.length,i=this.blocks,c=this.byteCount,s=this.blockCount,f=0,d=this.s;f>2]|=e[f]<>2]|=n<>2]|=(192|n>>6)<>2]|=(128|63&n)<=57344?(i[r>>2]|=(224|n>>12)<>2]|=(128|n>>6&63)<>2]|=(128|63&n)<>2]|=(240|n>>18)<>2]|=(128|n>>12&63)<>2]|=(128|n>>6&63)<>2]|=(128|63&n)<=c){for(this.start=r-c,this.block=i[s],r=0;r>2]|=this.padding[3&t],this.lastByteIndex===this.byteCount)for(e[0]=e[r],t=1;t>4&15]+i[15&e]+i[e>>12&15]+i[e>>8&15]+i[e>>20&15]+i[e>>16&15]+i[e>>28&15]+i[e>>24&15];c%t===0&&(k(r),o=0)}return a&&(e=r[o],a>0&&(s+=i[e>>4&15]+i[15&e]),a>1&&(s+=i[e>>12&15]+i[e>>8&15]),a>2&&(s+=i[e>>20&15]+i[e>>16&15])),s},w.prototype.arrayBuffer=function(){this.finalize();var e,t=this.blockCount,r=this.s,n=this.outputBlocks,a=this.extraBytes,i=0,o=0,c=this.outputBits>>3;e=a?new ArrayBuffer(n+1<<2):new ArrayBuffer(c);for(var s=new Uint32Array(e);o>8&255,s[e+2]=t>>16&255,s[e+3]=t>>24&255;c%r===0&&k(n)}return i&&(e=c<<2,t=n[o],i>0&&(s[e]=255&t),i>1&&(s[e+1]=t>>8&255),i>2&&(s[e+2]=t>>16&255)),s};var k=function(e){var t,r,n,a,i,o,s,f,d,u,l,b,h,p,m,v,g,x,y,w,k,_,M,S,E,O,A,T,j,P,C,R,N,B,L,I,F,D,U,z,H,q,J,V,G,X,K,W,Z,$,Q,Y,ee,te,re,ne,ae,ie,oe,ce,se,fe,de;for(n=0;n<48;n+=2)a=e[0]^e[10]^e[20]^e[30]^e[40],i=e[1]^e[11]^e[21]^e[31]^e[41],o=e[2]^e[12]^e[22]^e[32]^e[42],s=e[3]^e[13]^e[23]^e[33]^e[43],f=e[4]^e[14]^e[24]^e[34]^e[44],d=e[5]^e[15]^e[25]^e[35]^e[45],u=e[6]^e[16]^e[26]^e[36]^e[46],l=e[7]^e[17]^e[27]^e[37]^e[47],t=(b=e[8]^e[18]^e[28]^e[38]^e[48])^(o<<1|s>>>31),r=(h=e[9]^e[19]^e[29]^e[39]^e[49])^(s<<1|o>>>31),e[0]^=t,e[1]^=r,e[10]^=t,e[11]^=r,e[20]^=t,e[21]^=r,e[30]^=t,e[31]^=r,e[40]^=t,e[41]^=r,t=a^(f<<1|d>>>31),r=i^(d<<1|f>>>31),e[2]^=t,e[3]^=r,e[12]^=t,e[13]^=r,e[22]^=t,e[23]^=r,e[32]^=t,e[33]^=r,e[42]^=t,e[43]^=r,t=o^(u<<1|l>>>31),r=s^(l<<1|u>>>31),e[4]^=t,e[5]^=r,e[14]^=t,e[15]^=r,e[24]^=t,e[25]^=r,e[34]^=t,e[35]^=r,e[44]^=t,e[45]^=r,t=f^(b<<1|h>>>31),r=d^(h<<1|b>>>31),e[6]^=t,e[7]^=r,e[16]^=t,e[17]^=r,e[26]^=t,e[27]^=r,e[36]^=t,e[37]^=r,e[46]^=t,e[47]^=r,t=u^(a<<1|i>>>31),r=l^(i<<1|a>>>31),e[8]^=t,e[9]^=r,e[18]^=t,e[19]^=r,e[28]^=t,e[29]^=r,e[38]^=t,e[39]^=r,e[48]^=t,e[49]^=r,p=e[0],m=e[1],X=e[11]<<4|e[10]>>>28,K=e[10]<<4|e[11]>>>28,T=e[20]<<3|e[21]>>>29,j=e[21]<<3|e[20]>>>29,ce=e[31]<<9|e[30]>>>23,se=e[30]<<9|e[31]>>>23,q=e[40]<<18|e[41]>>>14,J=e[41]<<18|e[40]>>>14,B=e[2]<<1|e[3]>>>31,L=e[3]<<1|e[2]>>>31,v=e[13]<<12|e[12]>>>20,g=e[12]<<12|e[13]>>>20,W=e[22]<<10|e[23]>>>22,Z=e[23]<<10|e[22]>>>22,P=e[33]<<13|e[32]>>>19,C=e[32]<<13|e[33]>>>19,fe=e[42]<<2|e[43]>>>30,de=e[43]<<2|e[42]>>>30,te=e[5]<<30|e[4]>>>2,re=e[4]<<30|e[5]>>>2,I=e[14]<<6|e[15]>>>26,F=e[15]<<6|e[14]>>>26,x=e[25]<<11|e[24]>>>21,y=e[24]<<11|e[25]>>>21,$=e[34]<<15|e[35]>>>17,Q=e[35]<<15|e[34]>>>17,R=e[45]<<29|e[44]>>>3,N=e[44]<<29|e[45]>>>3,S=e[6]<<28|e[7]>>>4,E=e[7]<<28|e[6]>>>4,ne=e[17]<<23|e[16]>>>9,ae=e[16]<<23|e[17]>>>9,D=e[26]<<25|e[27]>>>7,U=e[27]<<25|e[26]>>>7,w=e[36]<<21|e[37]>>>11,k=e[37]<<21|e[36]>>>11,Y=e[47]<<24|e[46]>>>8,ee=e[46]<<24|e[47]>>>8,V=e[8]<<27|e[9]>>>5,G=e[9]<<27|e[8]>>>5,O=e[18]<<20|e[19]>>>12,A=e[19]<<20|e[18]>>>12,ie=e[29]<<7|e[28]>>>25,oe=e[28]<<7|e[29]>>>25,z=e[38]<<8|e[39]>>>24,H=e[39]<<8|e[38]>>>24,_=e[48]<<14|e[49]>>>18,M=e[49]<<14|e[48]>>>18,e[0]=p^~v&x,e[1]=m^~g&y,e[10]=S^~O&T,e[11]=E^~A&j,e[20]=B^~I&D,e[21]=L^~F&U,e[30]=V^~X&W,e[31]=G^~K&Z,e[40]=te^~ne&ie,e[41]=re^~ae&oe,e[2]=v^~x&w,e[3]=g^~y&k,e[12]=O^~T&P,e[13]=A^~j&C,e[22]=I^~D&z,e[23]=F^~U&H,e[32]=X^~W&$,e[33]=K^~Z&Q,e[42]=ne^~ie&ce,e[43]=ae^~oe&se,e[4]=x^~w&_,e[5]=y^~k&M,e[14]=T^~P&R,e[15]=j^~C&N,e[24]=D^~z&q,e[25]=U^~H&J,e[34]=W^~$&Y,e[35]=Z^~Q&ee,e[44]=ie^~ce&fe,e[45]=oe^~se&de,e[6]=w^~_&p,e[7]=k^~M&m,e[16]=P^~R&S,e[17]=C^~N&E,e[26]=z^~q&B,e[27]=H^~J&L,e[36]=$^~Y&V,e[37]=Q^~ee&G,e[46]=ce^~fe&te,e[47]=se^~de&re,e[8]=_^~p&v,e[9]=M^~m&g,e[18]=R^~S&O,e[19]=N^~E&A,e[28]=q^~B&I,e[29]=J^~L&F,e[38]=Y^~V&X,e[39]=ee^~G&K,e[48]=fe^~te&ne,e[49]=de^~re&ae,e[0]^=c[n],e[1]^=c[n+1]};if(a)e.exports=h;else for(m=0;m>8,o=255&a;i?r.push(i,o):r.push(o)}return r},r.zero2=n,r.toHex=a,r.encode=function(e,t){return"hex"===t?a(e):e}})),u=c((function(e,t){var r=t;r.assert=s,r.toArray=d.toArray,r.zero2=d.zero2,r.toHex=d.toHex,r.encode=d.encode,r.getNAF=function(e,t,r){var n=new Array(Math.max(e.bitLength(),r)+1);n.fill(0);for(var a=1<(a>>1)-1?(a>>1)-s:s,i.isubn(c)):c=0,n[o]=c,i.iushrn(1)}return n},r.getJSF=function(e,t){var r=[[],[]];e=e.clone(),t=t.clone();for(var n,a=0,i=0;e.cmpn(-a)>0||t.cmpn(-i)>0;){var o,c,s=e.andln(3)+a&3,f=t.andln(3)+i&3;3===s&&(s=-1),3===f&&(f=-1),o=0===(1&s)?0:3!==(n=e.andln(7)+a&7)&&5!==n||2!==f?s:-s,r[0].push(o),c=0===(1&f)?0:3!==(n=t.andln(7)+i&7)&&5!==n||2!==s?f:-f,r[1].push(c),2*a===o+1&&(a=1-a),2*i===c+1&&(i=1-i),e.iushrn(1),t.iushrn(1)}return r},r.cachedProperty=function(e,t,r){var n="_"+t;e.prototype[t]=function(){return void 0!==this[n]?this[n]:this[n]=r.call(this)}},r.parseBytes=function(e){return"string"===typeof e?r.toArray(e,"hex"):e},r.intFromLE=function(e){return new a.a(e,"hex","le")}})),l=u.getNAF,b=u.getJSF,h=u.assert;function p(e,t){this.type=e,this.p=new a.a(t.p,16),this.red=t.prime?a.a.red(t.prime):a.a.mont(this.p),this.zero=new a.a(0).toRed(this.red),this.one=new a.a(1).toRed(this.red),this.two=new a.a(2).toRed(this.red),this.n=t.n&&new a.a(t.n,16),this.g=t.g&&this.pointFromJSON(t.g,t.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var r=this.n&&this.p.div(this.n);!r||r.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}var m=p;function v(e,t){this.curve=e,this.type=t,this.precomputed=null}p.prototype.point=function(){throw new Error("Not implemented")},p.prototype.validate=function(){throw new Error("Not implemented")},p.prototype._fixedNafMul=function(e,t){h(e.precomputed);var r=e._getDoubles(),n=l(t,1,this._bitLength),a=(1<=i;s--)o=(o<<1)+n[s];c.push(o)}for(var f=this.jpoint(null,null,null),d=this.jpoint(null,null,null),u=a;u>0;u--){for(i=0;i=0;c--){for(var s=0;c>=0&&0===i[c];c--)s++;if(c>=0&&s++,o=o.dblp(s),c<0)break;var f=i[c];h(0!==f),o="affine"===e.type?f>0?o.mixedAdd(a[f-1>>1]):o.mixedAdd(a[-f-1>>1].neg()):f>0?o.add(a[f-1>>1]):o.add(a[-f-1>>1].neg())}return"affine"===e.type?o.toP():o},p.prototype._wnafMulAdd=function(e,t,r,n,a){var i,o,c,s=this._wnafT1,f=this._wnafT2,d=this._wnafT3,u=0;for(i=0;i=1;i-=2){var p=i-1,m=i;if(1===s[p]&&1===s[m]){var v=[t[p],null,null,t[m]];0===t[p].y.cmp(t[m].y)?(v[1]=t[p].add(t[m]),v[2]=t[p].toJ().mixedAdd(t[m].neg())):0===t[p].y.cmp(t[m].y.redNeg())?(v[1]=t[p].toJ().mixedAdd(t[m]),v[2]=t[p].add(t[m].neg())):(v[1]=t[p].toJ().mixedAdd(t[m]),v[2]=t[p].toJ().mixedAdd(t[m].neg()));var g=[-3,-1,-5,-7,0,7,5,1,3],x=b(r[p],r[m]);for(u=Math.max(x[0].length,u),d[p]=new Array(u),d[m]=new Array(u),o=0;o=0;i--){for(var M=0;i>=0;){var S=!0;for(o=0;o=0&&M++,k=k.dblp(M),i<0)break;for(o=0;o0?c=f[o][E-1>>1]:E<0&&(c=f[o][-E-1>>1].neg()),k="affine"===c.type?k.mixedAdd(c):k.add(c))}}for(i=0;i=Math.ceil((e.bitLength()+1)/t.step)},v.prototype._getDoubles=function(e,t){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var r=[this],n=this,a=0;a=0&&(o=t,c=r),n.negative&&(n=n.neg(),i=i.neg()),o.negative&&(o=o.neg(),c=c.neg()),[{a:n,b:i},{a:o,b:c}]},y.prototype._endoSplit=function(e){var t=this.endo.basis,r=t[0],n=t[1],a=n.b.mul(e).divRound(this.n),i=r.b.neg().mul(e).divRound(this.n),o=a.mul(r.a),c=i.mul(n.a),s=a.mul(r.b),f=i.mul(n.b);return{k1:e.sub(o).sub(c),k2:s.add(f).neg()}},y.prototype.pointFromX=function(e,t){(e=new a.a(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr().redMul(e).redIAdd(e.redMul(this.a)).redIAdd(this.b),n=r.redSqrt();if(0!==n.redSqr().redSub(r).cmp(this.zero))throw new Error("invalid point");var i=n.fromRed().isOdd();return(t&&!i||!t&&i)&&(n=n.redNeg()),this.point(e,n)},y.prototype.validate=function(e){if(e.inf)return!0;var t=e.x,r=e.y,n=this.a.redMul(t),a=t.redSqr().redMul(t).redIAdd(n).redIAdd(this.b);return 0===r.redSqr().redISub(a).cmpn(0)},y.prototype._endoWnafMulAdd=function(e,t,r){for(var n=this._endoWnafT1,a=this._endoWnafT2,i=0;i":""},k.prototype.isInfinity=function(){return this.inf},k.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;if(this.eq(e))return this.dbl();if(this.neg().eq(e))return this.curve.point(null,null);if(0===this.x.cmp(e.x))return this.curve.point(null,null);var t=this.y.redSub(e.y);0!==t.cmpn(0)&&(t=t.redMul(this.x.redSub(e.x).redInvm()));var r=t.redSqr().redISub(this.x).redISub(e.x),n=t.redMul(this.x.redSub(r)).redISub(this.y);return this.curve.point(r,n)},k.prototype.dbl=function(){if(this.inf)return this;var e=this.y.redAdd(this.y);if(0===e.cmpn(0))return this.curve.point(null,null);var t=this.curve.a,r=this.x.redSqr(),n=e.redInvm(),a=r.redAdd(r).redIAdd(r).redIAdd(t).redMul(n),i=a.redSqr().redISub(this.x.redAdd(this.x)),o=a.redMul(this.x.redSub(i)).redISub(this.y);return this.curve.point(i,o)},k.prototype.getX=function(){return this.x.fromRed()},k.prototype.getY=function(){return this.y.fromRed()},k.prototype.mul=function(e){return e=new a.a(e,16),this.isInfinity()?this:this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve.endo?this.curve._endoWnafMulAdd([this],[e]):this.curve._wnafMul(this,e)},k.prototype.mulAdd=function(e,t,r){var n=[this,t],a=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,a):this.curve._wnafMulAdd(1,n,a,2)},k.prototype.jmulAdd=function(e,t,r){var n=[this,t],a=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,a,!0):this.curve._wnafMulAdd(1,n,a,2,!0)},k.prototype.eq=function(e){return this===e||this.inf===e.inf&&(this.inf||0===this.x.cmp(e.x)&&0===this.y.cmp(e.y))},k.prototype.neg=function(e){if(this.inf)return this;var t=this.curve.point(this.x,this.y.redNeg());if(e&&this.precomputed){var r=this.precomputed,n=function(e){return e.neg()};t.precomputed={naf:r.naf&&{wnd:r.naf.wnd,points:r.naf.points.map(n)},doubles:r.doubles&&{step:r.doubles.step,points:r.doubles.points.map(n)}}}return t},k.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},g(_,m.BasePoint),y.prototype.jpoint=function(e,t,r){return new _(this,e,t,r)},_.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var e=this.z.redInvm(),t=e.redSqr(),r=this.x.redMul(t),n=this.y.redMul(t).redMul(e);return this.curve.point(r,n)},_.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},_.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var t=e.z.redSqr(),r=this.z.redSqr(),n=this.x.redMul(t),a=e.x.redMul(r),i=this.y.redMul(t.redMul(e.z)),o=e.y.redMul(r.redMul(this.z)),c=n.redSub(a),s=i.redSub(o);if(0===c.cmpn(0))return 0!==s.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var f=c.redSqr(),d=f.redMul(c),u=n.redMul(f),l=s.redSqr().redIAdd(d).redISub(u).redISub(u),b=s.redMul(u.redISub(l)).redISub(i.redMul(d)),h=this.z.redMul(e.z).redMul(c);return this.curve.jpoint(l,b,h)},_.prototype.mixedAdd=function(e){if(this.isInfinity())return e.toJ();if(e.isInfinity())return this;var t=this.z.redSqr(),r=this.x,n=e.x.redMul(t),a=this.y,i=e.y.redMul(t).redMul(this.z),o=r.redSub(n),c=a.redSub(i);if(0===o.cmpn(0))return 0!==c.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var s=o.redSqr(),f=s.redMul(o),d=r.redMul(s),u=c.redSqr().redIAdd(f).redISub(d).redISub(d),l=c.redMul(d.redISub(u)).redISub(a.redMul(f)),b=this.z.redMul(o);return this.curve.jpoint(u,l,b)},_.prototype.dblp=function(e){if(0===e)return this;if(this.isInfinity())return this;if(!e)return this.dbl();var t;if(this.curve.zeroA||this.curve.threeA){var r=this;for(t=0;t=0)return!1;if(r.redIAdd(a),0===this.x.cmp(r))return!0}},_.prototype.inspect=function(){return this.isInfinity()?"":""},_.prototype.isInfinity=function(){return 0===this.z.cmpn(0)};var M=c((function(e,t){var r=t;r.base=m,r.short=w,r.mont=null,r.edwards=null})),S=c((function(e,t){var r,n=t,a=u.assert;function i(e){"short"===e.type?this.curve=new M.short(e):"edwards"===e.type?this.curve=new M.edwards(e):this.curve=new M.mont(e),this.g=this.curve.g,this.n=this.curve.n,this.hash=e.hash,a(this.g.validate(),"Invalid curve"),a(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function c(e,t){Object.defineProperty(n,e,{configurable:!0,enumerable:!0,get:function(){var r=new i(t);return Object.defineProperty(n,e,{configurable:!0,enumerable:!0,value:r}),r}})}n.PresetCurve=i,c("p192",{type:"short",prime:"p192",p:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff",a:"ffffffff ffffffff ffffffff fffffffe ffffffff fffffffc",b:"64210519 e59c80e7 0fa7e9ab 72243049 feb8deec c146b9b1",n:"ffffffff ffffffff ffffffff 99def836 146bc9b1 b4d22831",hash:o.a.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),c("p224",{type:"short",prime:"p224",p:"ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001",a:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff fffffffe",b:"b4050a85 0c04b3ab f5413256 5044b0b7 d7bfd8ba 270b3943 2355ffb4",n:"ffffffff ffffffff ffffffff ffff16a2 e0b8f03e 13dd2945 5c5c2a3d",hash:o.a.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),c("p256",{type:"short",prime:null,p:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff ffffffff",a:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff fffffffc",b:"5ac635d8 aa3a93e7 b3ebbd55 769886bc 651d06b0 cc53b0f6 3bce3c3e 27d2604b",n:"ffffffff 00000000 ffffffff ffffffff bce6faad a7179e84 f3b9cac2 fc632551",hash:o.a.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),c("p384",{type:"short",prime:null,p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 ffffffff",a:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 fffffffc",b:"b3312fa7 e23ee7e4 988e056b e3f82d19 181d9c6e fe814112 0314088f 5013875a c656398d 8a2ed19d 2a85c8ed d3ec2aef",n:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff c7634d81 f4372ddf 581a0db2 48b0a77a ecec196a ccc52973",hash:o.a.sha384,gRed:!1,g:["aa87ca22 be8b0537 8eb1c71e f320ad74 6e1d3b62 8ba79b98 59f741e0 82542a38 5502f25d bf55296c 3a545e38 72760ab7","3617de4a 96262c6f 5d9e98bf 9292dc29 f8f41dbd 289a147c e9da3113 b5f0b8c0 0a60b1ce 1d7e819d 7a431d7c 90ea0e5f"]}),c("p521",{type:"short",prime:null,p:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff",a:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffc",b:"00000051 953eb961 8e1c9a1f 929a21a0 b68540ee a2da725b 99b315f3 b8b48991 8ef109e1 56193951 ec7e937b 1652c0bd 3bb1bf07 3573df88 3d2c34f1 ef451fd4 6b503f00",n:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffa 51868783 bf2f966b 7fcc0148 f709a5d0 3bb5c9b8 899c47ae bb6fb71e 91386409",hash:o.a.sha512,gRed:!1,g:["000000c6 858e06b7 0404e9cd 9e3ecb66 2395b442 9c648139 053fb521 f828af60 6b4d3dba a14b5e77 efe75928 fe1dc127 a2ffa8de 3348b3c1 856a429b f97e7e31 c2e5bd66","00000118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd9 98f54449 579b4468 17afbd17 273e662c 97ee7299 5ef42640 c550b901 3fad0761 353c7086 a272c240 88be9476 9fd16650"]}),c("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:o.a.sha256,gRed:!1,g:["9"]}),c("ed25519",{type:"edwards",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"-1",c:"1",d:"52036cee2b6ffe73 8cc740797779e898 00700a4d4141d8ab 75eb4dca135978a3",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:o.a.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});try{r=null.crash()}catch(s){r=void 0}c("secp256k1",{type:"short",prime:"k256",p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f",a:"0",b:"7",n:"ffffffff ffffffff ffffffff fffffffe baaedce6 af48a03b bfd25e8c d0364141",h:"1",hash:o.a.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",r]})}));function E(e){if(!(this instanceof E))return new E(e);this.hash=e.hash,this.predResist=!!e.predResist,this.outLen=this.hash.outSize,this.minEntropy=e.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var t=d.toArray(e.entropy,e.entropyEnc||"hex"),r=d.toArray(e.nonce,e.nonceEnc||"hex"),n=d.toArray(e.pers,e.persEnc||"hex");s(t.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(t,r,n)}var O=E;E.prototype._init=function(e,t,r){var n=e.concat(t).concat(r);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var a=0;a=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(e.concat(r||[])),this._reseed=1},E.prototype.generate=function(e,t,r,n){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");"string"!==typeof t&&(n=r,r=t,t=null),r&&(r=d.toArray(r,n||"hex"),this._update(r));for(var a=[];a.length"};var P=u.assert;function C(e,t){if(e instanceof C)return e;this._importDER(e,t)||(P(e.r&&e.s,"Signature without r or s"),this.r=new a.a(e.r,16),this.s=new a.a(e.s,16),void 0===e.recoveryParam?this.recoveryParam=null:this.recoveryParam=e.recoveryParam)}var R=C;function N(){this.place=0}function B(e,t){var r=e[t.place++];if(!(128&r))return r;var n=15&r;if(0===n||n>4)return!1;for(var a=0,i=0,o=t.place;i>>=0;return!(a<=127)&&(t.place=o,a)}function L(e){for(var t=0,r=e.length-1;!e[t]&&!(128&e[t+1])&&t>>3);for(e.push(128|r);--r;)e.push(t>>>(r<<3)&255);e.push(t)}}C.prototype._importDER=function(e,t){e=u.toArray(e,t);var r=new N;if(48!==e[r.place++])return!1;var n=B(e,r);if(!1===n)return!1;if(n+r.place!==e.length)return!1;if(2!==e[r.place++])return!1;var i=B(e,r);if(!1===i)return!1;var o=e.slice(r.place,i+r.place);if(r.place+=i,2!==e[r.place++])return!1;var c=B(e,r);if(!1===c)return!1;if(e.length!==c+r.place)return!1;var s=e.slice(r.place,c+r.place);if(0===o[0]){if(!(128&o[1]))return!1;o=o.slice(1)}if(0===s[0]){if(!(128&s[1]))return!1;s=s.slice(1)}return this.r=new a.a(o),this.s=new a.a(s),this.recoveryParam=null,!0},C.prototype.toDER=function(e){var t=this.r.toArray(),r=this.s.toArray();for(128&t[0]&&(t=[0].concat(t)),128&r[0]&&(r=[0].concat(r)),t=L(t),r=L(r);!r[0]&&!(128&r[1]);)r=r.slice(1);var n=[2];I(n,t.length),(n=n.concat(t)).push(2),I(n,r.length);var a=n.concat(r),i=[48];return I(i,a.length),i=i.concat(a),u.encode(i,e)};var F=function(){throw new Error("unsupported")},D=u.assert;function U(e){if(!(this instanceof U))return new U(e);"string"===typeof e&&(D(Object.prototype.hasOwnProperty.call(S,e),"Unknown curve "+e),e=S[e]),e instanceof S.PresetCurve&&(e={curve:e}),this.curve=e.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=e.curve.g,this.g.precompute(e.curve.n.bitLength()+1),this.hash=e.hash||e.curve.hash}var z=U;U.prototype.keyPair=function(e){return new j(this,e)},U.prototype.keyFromPrivate=function(e,t){return j.fromPrivate(this,e,t)},U.prototype.keyFromPublic=function(e,t){return j.fromPublic(this,e,t)},U.prototype.genKeyPair=function(e){e||(e={});for(var t=new O({hash:this.hash,pers:e.pers,persEnc:e.persEnc||"utf8",entropy:e.entropy||F(this.hash.hmacStrength),entropyEnc:e.entropy&&e.entropyEnc||"utf8",nonce:this.n.toArray()}),r=this.n.byteLength(),n=this.n.sub(new a.a(2));;){var i=new a.a(t.generate(r));if(!(i.cmp(n)>0))return i.iaddn(1),this.keyFromPrivate(i)}},U.prototype._truncateToN=function(e,t){var r=8*e.byteLength()-this.n.bitLength();return r>0&&(e=e.ushrn(r)),!t&&e.cmp(this.n)>=0?e.sub(this.n):e},U.prototype.sign=function(e,t,r,n){"object"===typeof r&&(n=r,r=null),n||(n={}),t=this.keyFromPrivate(t,r),e=this._truncateToN(new a.a(e,16));for(var i=this.n.byteLength(),o=t.getPrivate().toArray("be",i),c=e.toArray("be",i),s=new O({hash:this.hash,entropy:o,nonce:c,pers:n.pers,persEnc:n.persEnc||"utf8"}),f=this.n.sub(new a.a(1)),d=0;;d++){var u=n.k?n.k(d):new a.a(s.generate(this.n.byteLength()));if(!((u=this._truncateToN(u,!0)).cmpn(1)<=0||u.cmp(f)>=0)){var l=this.g.mul(u);if(!l.isInfinity()){var b=l.getX(),h=b.umod(this.n);if(0!==h.cmpn(0)){var p=u.invm(this.n).mul(h.mul(t.getPrivate()).iadd(e));if(0!==(p=p.umod(this.n)).cmpn(0)){var m=(l.getY().isOdd()?1:0)|(0!==b.cmp(h)?2:0);return n.canonical&&p.cmp(this.nh)>0&&(p=this.n.sub(p),m^=1),new R({r:h,s:p,recoveryParam:m})}}}}}},U.prototype.verify=function(e,t,r,n){e=this._truncateToN(new a.a(e,16)),r=this.keyFromPublic(r,n);var i=(t=new R(t,"hex")).r,o=t.s;if(i.cmpn(1)<0||i.cmp(this.n)>=0)return!1;if(o.cmpn(1)<0||o.cmp(this.n)>=0)return!1;var c,s=o.invm(this.n),f=s.mul(e).umod(this.n),d=s.mul(i).umod(this.n);return this.curve._maxwellTrick?!(c=this.g.jmulAdd(f,r.getPublic(),d)).isInfinity()&&c.eqXToP(i):!(c=this.g.mulAdd(f,r.getPublic(),d)).isInfinity()&&0===c.getX().umod(this.n).cmp(i)},U.prototype.recoverPubKey=function(e,t,r,n){D((3&r)===r,"The recovery param is more than two bits"),t=new R(t,n);var i=this.n,o=new a.a(e),c=t.r,s=t.s,f=1&r,d=r>>1;if(c.cmp(this.curve.p.umod(this.curve.n))>=0&&d)throw new Error("Unable to find sencond key candinate");c=d?this.curve.pointFromX(c.add(this.curve.n),f):this.curve.pointFromX(c,f);var u=t.r.invm(i),l=i.sub(o).mul(u).umod(i),b=s.mul(u).umod(i);return this.g.mulAdd(l,c,b)},U.prototype.getKeyRecoveryParam=function(e,t,r,n){if(null!==(t=new R(t,n)).recoveryParam)return t.recoveryParam;for(var a=0;a<4;a++){var i;try{i=this.recoverPubKey(e,t,a)}catch(e){continue}if(i.eq(r))return a}throw new Error("Unable to find valid recovery factor")};var H=c((function(e,t){var r=t;r.version="6.5.4",r.utils=u,r.rand=function(){throw new Error("unsupported")},r.curve=M,r.curves=S,r.ec=z,r.eddsa=null})).ec}).call(this,r(44))},function(e,t,r){"use strict";r.d(t,"a",(function(){return n}));var n="random/5.3.0"},function(e){e.exports=JSON.parse('{"$schema":"http://json-schema.org/draft-07/schema#","$id":"https://uniswap.org/tokenlist.schema.json","title":"Uniswap Token List","description":"Schema for lists of tokens compatible with the Uniswap Interface","definitions":{"Version":{"type":"object","description":"The version of the list, used in change detection","examples":[{"major":1,"minor":0,"patch":0}],"additionalProperties":false,"properties":{"major":{"type":"integer","description":"The major version of the list. Must be incremented when tokens are removed from the list or token addresses are changed.","minimum":0,"examples":[1,2]},"minor":{"type":"integer","description":"The minor version of the list. Must be incremented when tokens are added to the list.","minimum":0,"examples":[0,1]},"patch":{"type":"integer","description":"The patch version of the list. Must be incremented for any changes to the list.","minimum":0,"examples":[0,1]}},"required":["major","minor","patch"]},"TagIdentifier":{"type":"string","description":"The unique identifier of a tag","minLength":1,"maxLength":10,"pattern":"^[\\\\w]+$","examples":["compound","stablecoin"]},"ExtensionIdentifier":{"type":"string","description":"The name of a token extension property","minLength":1,"maxLength":30,"pattern":"^[\\\\w]+$","examples":["color","is_fee_on_transfer","aliases"]},"ExtensionValue":{"anyOf":[{"type":"string","minLength":1,"maxLength":30,"examples":["#00000"]},{"type":"boolean","examples":[true]},{"type":"number","examples":[15]},{"type":"null"}]},"TagDefinition":{"type":"object","description":"Definition of a tag that can be associated with a token via its identifier","additionalProperties":false,"properties":{"name":{"type":"string","description":"The name of the tag","pattern":"^[ \\\\w]+$","minLength":1,"maxLength":20},"description":{"type":"string","description":"A user-friendly description of the tag","pattern":"^[ \\\\w\\\\.,]+$","minLength":1,"maxLength":200}},"required":["name","description"],"examples":[{"name":"Stablecoin","description":"A token with value pegged to another asset"}]},"TokenInfo":{"type":"object","description":"Metadata for a single token in a token list","additionalProperties":false,"properties":{"chainId":{"type":"integer","description":"The chain ID of the Ethereum network where this token is deployed","minimum":1,"examples":[1,42]},"address":{"type":"string","description":"The checksummed address of the token on the specified chain ID","pattern":"^0x[a-fA-F0-9]{40}$","examples":["0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48"]},"decimals":{"type":"integer","description":"The number of decimals for the token balance","minimum":0,"maximum":255,"examples":[18]},"name":{"type":"string","description":"The name of the token","minLength":1,"maxLength":40,"pattern":"^[ \\\\w.\'+\\\\-%/\xc0-\xd6\xd8-\xf6\xf8-\xff\\\\:]+$","examples":["USD Coin"]},"symbol":{"type":"string","description":"The symbol for the token; must be alphanumeric","pattern":"^[a-zA-Z0-9+\\\\-%/\\\\$]+$","minLength":1,"maxLength":20,"examples":["USDC"]},"logoURI":{"type":"string","description":"A URI to the token logo asset; if not set, interface will attempt to find a logo based on the token address; suggest SVG or PNG of size 64x64","format":"uri","examples":["ipfs://QmXfzKRvjZz3u5JRgC4v5mGVbm9ahrUiB4DgzHBsnWbTMM"]},"tags":{"type":"array","description":"An array of tag identifiers associated with the token; tags are defined at the list level","items":{"$ref":"#/definitions/TagIdentifier"},"maxLength":10,"examples":["stablecoin","compound"]},"extensions":{"type":"object","description":"An object containing any arbitrary or vendor-specific token metadata","propertyNames":{"$ref":"#/definitions/ExtensionIdentifier"},"additionalProperties":{"$ref":"#/definitions/ExtensionValue"},"maxProperties":10,"examples":[{"color":"#000000","is_verified_by_me":true}]}},"required":["chainId","address","decimals","name","symbol"]}},"type":"object","additionalProperties":false,"properties":{"name":{"type":"string","description":"The name of the token list","minLength":1,"maxLength":20,"pattern":"^[\\\\w ]+$","examples":["My Token List"]},"timestamp":{"type":"string","format":"date-time","description":"The timestamp of this list version; i.e. when this immutable version of the list was created"},"version":{"$ref":"#/definitions/Version"},"tokens":{"type":"array","description":"The list of tokens included in the list","items":{"$ref":"#/definitions/TokenInfo"},"minItems":1,"maxItems":10000},"keywords":{"type":"array","description":"Keywords associated with the contents of the list; may be used in list discoverability","items":{"type":"string","description":"A keyword to describe the contents of the list","minLength":1,"maxLength":20,"pattern":"^[\\\\w ]+$","examples":["compound","lending","personal tokens"]},"maxItems":20,"uniqueItems":true},"tags":{"type":"object","description":"A mapping of tag identifiers to their name and description","propertyNames":{"$ref":"#/definitions/TagIdentifier"},"additionalProperties":{"$ref":"#/definitions/TagDefinition"},"maxProperties":20,"examples":[{"stablecoin":{"name":"Stablecoin","description":"A token with value pegged to another asset"}}]},"logoURI":{"type":"string","description":"A URI for the logo of the token list; prefer SVG or PNG of size 256x256","format":"uri","examples":["ipfs://QmXfzKRvjZz3u5JRgC4v5mGVbm9ahrUiB4DgzHBsnWbTMM"]}},"required":["name","timestamp","version","tokens"]}')},function(e,t,r){"use strict";var n=r(910),a=r(329),i=r(914),o=r(484),c=r(485),s=r(915),f=r(916),d=r(937),u=r(177);e.exports=v,v.prototype.validate=function(e,t){var r;if("string"==typeof e){if(!(r=this.getSchema(e)))throw new Error('no schema with key or ref "'+e+'"')}else{var n=this._addSchema(e);r=n.validate||this._compile(n)}var a=r(t);!0!==r.$async&&(this.errors=r.errors);return a},v.prototype.compile=function(e,t){var r=this._addSchema(e,void 0,t);return r.validate||this._compile(r)},v.prototype.addSchema=function(e,t,r,n){if(Array.isArray(e)){for(var i=0;i0)-Number(e<0)||+e}function u(e,t,r){return 0===t||Math.abs(t)===1/0?function(e,t){return Math.pow(e,5*t)}(e,r):e*t*r/(t+r*e)}function l(e,t,r,n){return void 0===n&&(n=.15),0===n?function(e,t,r){return Math.max(t,Math.min(e,r))}(e,t,r):er?+u(e-r,r-t,n)+r:e}function b(e,t){for(var r=0;r=0||(a[r]=e[r]);return a}function v(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function g(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r=e.length?{done:!0}:{done:!1,value:e[n++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}return(r=e[Symbol.iterator]()).next.bind(r)}function y(){}function w(){for(var e=arguments.length,t=new Array(e),r=0;r1?t-1:0),n=1;n2?a-2:0),o=2;o0||a>0,o=h({},r.controller.state.shared,r.state,r.mapStateValues(r.state),{locked:!!document.pointerLockElement,touches:a,down:i}),c=r.handler(o);return r.state.memo=void 0!==c?c:r.state.memo,o},this.controller=e,this.args=t}var t,r,n,a=e.prototype;return a.updateSharedState=function(e){Object.assign(this.controller.state.shared,e)},a.updateGestureState=function(e){Object.assign(this.state,e)},a.checkIntentionality=function(e,t){return{_intentional:e,_blocked:!1}},a.getMovement=function(e){var t=this.config.rubberband,r=this.state,n=r._bounds,a=r._initial,c=r._active,s=r._intentional,f=r.lastOffset,d=r.movement,u=r._threshold,l=this.getInternalMovement(e,this.state),b=!1===s[0]?$(l[0],u[0]):s[0],p=!1===s[1]?$(l[1],u[1]):s[1],m=this.checkIntentionality([b,p],l);if(m._blocked)return h({},m,{_movement:l,delta:[0,0]});var v=m._intentional,g=l,x=[!1!==v[0]?l[0]-v[0]:0,!1!==v[1]?l[1]-v[1]:0],y=i(x,f),w=c?t:[0,0];return x=Q(n,i(x,a),w),h({},m,{intentional:!1!==v[0]||!1!==v[1],_initial:a,_movement:g,movement:x,values:e,offset:Q(n,y,w),delta:o(x,d)})},a.clean=function(){this.clearTimeout()},t=e,(r=[{key:"config",get:function(){return this.controller.config[this.stateKey]}},{key:"enabled",get:function(){return this.controller.config.enabled&&this.config.enabled}},{key:"state",get:function(){return this.controller.state[this.stateKey]}},{key:"handler",get:function(){return this.controller.handlers[this.stateKey]}},{key:"transform",get:function(){return this.config.transform||this.controller.config.transform||W}}])&&b(t.prototype,r),n&&b(t,n),e}();function $(e,t){return Math.abs(e)>=t&&d(e)*t}function Q(e,t,r){var n=t[0],a=t[1],i=r[0],o=r[1],c=e[0],s=c[0],f=c[1],d=e[1],u=d[0],b=d[1];return[l(n,s,f,i),l(a,u,b,o)]}function Y(e,t,r){var n=e.state,a=t.timeStamp,i=t.type,o=n.values;return{_lastEventType:i,event:t,timeStamp:a,elapsedTime:r?0:a-n.startTime,previous:o}}function ee(e,t,r,n){var a=e.state,i=e.config,c=e.stateKey,s=e.args,f=e.transform,d=a.offset,u=r.timeStamp,l=i.initial,b=i.bounds,p=o(f(i.threshold),f([0,0])).map(Math.abs),m=h({},X()[c],{_active:!0,args:s,values:t,initial:null!=n?n:t,_threshold:p,offset:d,lastOffset:d,startTime:u});return h({},m,{_initial:M(l,m),_bounds:M(b,m)})}var te=function(e){var t=this;this.classes=e,this.pointerIds=new Set,this.touchIds=new Set,this.supportsTouchEvents=E(),this.supportsGestureEvents=function(){try{return"constructor"in GestureEvent}catch(e){return!1}}(),this.bind=function(){for(var e=arguments.length,r=new Array(e),n=0;na?"x":n0?t.setUpDelayedDragTrigger(e):t.startDrag(e,!0))},t.onDragChange=function(e){if(!t.state.canceled&&t.state._active&&t.isValidEvent(e)&&(t.state._lastEventType!==e.type||e.timeStamp!==t.state.timeStamp)){var r;if(document.pointerLockElement){var n=e.movementX,a=e.movementY;r=i(t.transform([n,a]),t.state.values)}else r=P(e,t.transform);var o=t.getKinematics(r,e);if(!t.state._dragStarted){if(t.state._dragDelayed)return void t.startDrag(e);if(!t.shouldPreventWindowScrollY)return;if(t.state._dragPreventScroll||!o.axis)return;if("x"!==o.axis)return void(t.state._active=!1);t.startDrag(e)}var s=T(e);t.updateSharedState(s);var f=Y(v(t),e),d=c(o._movement),u=t.state._dragIsTap;u&&d>=3&&(u=!1),t.updateGestureState(h({},f,o,{_dragIsTap:u})),t.fireGestureHandler()}},t.onDragEnd=function(e){if(ne(t.controller,e),t.isValidEvent(e)&&(t.clean(),t.state._active)){t.state._active=!1;var r=t.state._dragIsTap,n=t.state.velocities,a=n[0],i=n[1],o=t.state.movement,c=o[0],s=o[1],f=t.state._intentional,u=f[0],l=f[1],b=t.config.swipeVelocity,p=b[0],m=b[1],g=t.config.swipeDistance,x=g[0],y=g[1],w=t.config.swipeDuration,k=h({},Y(v(t),e),t.getMovement(t.state.values)),_=[0,0];k.elapsedTimep&&Math.abs(c)>x&&(_[0]=d(a)),!1!==l&&Math.abs(i)>m&&Math.abs(s)>y&&(_[1]=d(i))),t.updateSharedState({buttons:0}),t.updateGestureState(h({},k,{tap:r,swipe:_})),t.fireGestureHandler(t.config.filterTaps&&!0===r)}},t.clean=function(){e.prototype.clean.call(v(t)),t.state._dragStarted=!1,t.releasePointerCapture(),ae(t.controller,t.stateKey)},t.onCancel=function(){t.state.canceled||(t.updateGestureState({canceled:!0,_active:!1}),t.updateSharedState({buttons:0}),setTimeout((function(){return t.fireGestureHandler()}),0))},t.onClick=function(e){t.state._dragIsTap||e.stopPropagation()},t}p(t,e);var r=t.prototype;return r.startDrag=function(e,t){void 0===t&&(t=!1),this.state._active&&!this.state._dragStarted&&(t||this.setStartState(e),this.updateGestureState({_dragStarted:!0,_dragPreventScroll:!0,cancel:this.onCancel}),this.clearTimeout(),this.fireGestureHandler())},r.addBindings=function(e){(this.config.useTouch?(de(e,"onTouchStart",this.onDragStart),de(e,"onTouchMove",this.onDragChange),de(e,"onTouchEnd",this.onDragEnd),de(e,"onTouchCancel",this.onDragEnd)):(de(e,"onPointerDown",this.onDragStart),de(e,"onPointerMove",this.onDragChange),de(e,"onPointerUp",this.onDragEnd),de(e,"onPointerCancel",this.onDragEnd)),this.config.filterTaps)&&de(e,this.controller.config.eventOptions.capture?"onClick":"onClickCapture",this.onClick)},t}(pe);var ge=function(e){function t(){var t;return(t=e.apply(this,arguments)||this).ingKey="pinching",t.stateKey="pinch",t.onPinchStart=function(e){re(t.controller,e);var r=t.controller.touchIds;if(t.enabled&&(!t.state._active||!t.state._pointerIds.every((function(e){return r.has(e)})))&&!(r.size<2)){var n=Array.from(r).slice(0,2),a=C(e,n,t.transform),i=a.values,o=a.origin;t.updateSharedState(T(e)),t.updateGestureState(h({},ee(v(t),i,e),Y(v(t),e,!0),{_pointerIds:n,cancel:t.onCancel,origin:o})),t.updateGestureState(t.getMovement(i)),t.fireGestureHandler()}},t.onPinchChange=function(e){var r=t.state,n=r.canceled,a=r._active;if(!n&&a&&e.timeStamp!==t.state.timeStamp){var i=T(e);t.updateSharedState(i);try{var o=C(e,t.state._pointerIds,t.transform),c=o.values,s=o.origin,f=t.getKinematics(c,e);t.updateGestureState(h({},Y(v(t),e),f,{origin:s})),t.fireGestureHandler()}catch(d){t.onPinchEnd(e)}}},t.onPinchEnd=function(e){ne(t.controller,e);var r=A(e);t.state._pointerIds.every((function(e){return!r.includes(e)}))||(t.clean(),t.state._active&&(t.updateGestureState(h({},Y(v(t),e),t.getMovement(t.state.values),{_active:!1})),t.fireGestureHandler()))},t.onCancel=function(){t.state.canceled||(t.updateGestureState({_active:!1,canceled:!0}),setTimeout((function(){return t.fireGestureHandler()}),0))},t.onGestureStart=function(e){if(t.enabled){e.preventDefault();var r=B(e,t.transform);t.updateSharedState(T(e)),t.updateGestureState(h({},ee(v(t),r,e),Y(v(t),e,!0),{origin:[e.clientX,e.clientY],cancel:t.onCancel})),t.updateGestureState(t.getMovement(r)),t.fireGestureHandler()}},t.onGestureChange=function(e){var r=t.state,n=r.canceled,a=r._active;if(!n&&a){e.preventDefault();var i=T(e);t.updateSharedState(i);var o=B(e,t.transform);o[0]=260*(o[0]-t.state.event.scale)+t.state.values[0];var c=t.getKinematics(o,e);t.updateGestureState(h({},Y(v(t),e),c,{origin:[e.clientX,e.clientY]})),t.fireGestureHandler()}},t.onGestureEnd=function(e){t.clean(),t.state._active&&(t.updateGestureState(h({},Y(v(t),e),t.getMovement(t.state.values),{_active:!1,origin:[e.clientX,e.clientY]})),t.fireGestureHandler())},t.wheelShouldRun=function(e){return t.enabled&&e.ctrlKey},t.getWheelValuesFromEvent=function(e){var r=N(e,t.transform)[1],n=t.state.values,a=n[0],i=n[1],o=7*-r,c=void 0!==i?i:0;return{values:[a+o,c],origin:[e.clientX,e.clientY],delta:[o,c]}},t.onWheel=function(e){t.wheelShouldRun(e)&&(t.setTimeout(t.onWheelEnd),t.state._active?t.onWheelChange(e):t.onWheelStart(e))},t.onWheelStart=function(e){var r=t.getWheelValuesFromEvent(e),n=r.values,a=r.delta,i=r.origin;e.cancelable&&e.preventDefault(),t.updateSharedState(T(e)),t.updateGestureState(h({},ee(v(t),n,e,t.state.values),Y(v(t),e,!0),{offset:n,delta:a,origin:i})),t.updateGestureState(t.getMovement(n)),t.fireGestureHandler()},t.onWheelChange=function(e){e.cancelable&&e.preventDefault(),t.updateSharedState(T(e));var r=t.getWheelValuesFromEvent(e),n=r.values,a=r.origin,i=r.delta;t.updateGestureState(h({},Y(v(t),e),t.getKinematics(n,e),{origin:a,delta:i})),t.fireGestureHandler()},t.onWheelEnd=function(){t.clean(),t.state._active&&(t.state._active=!1,t.updateGestureState(t.getMovement(t.state.values)),t.fireGestureHandler())},t}return p(t,e),t.prototype.addBindings=function(e){this.controller.config.domTarget&&!this.controller.supportsTouchEvents&&this.controller.supportsGestureEvents?(de(e,"onGestureStart",this.onGestureStart),de(e,"onGestureChange",this.onGestureChange),de(e,"onGestureEnd",this.onGestureEnd)):(de(e,"onTouchStart",this.onPinchStart),de(e,"onTouchMove",this.onPinchChange),de(e,"onTouchEnd",this.onPinchEnd),de(e,"onTouchCancel",this.onPinchEnd),de(e,"onWheel",this.onWheel))},t}(function(e){function t(){return e.apply(this,arguments)||this}p(t,e);var r=t.prototype;return r.getInternalMovement=function(e,t){var r=t.values[1],n=e[0],a=e[1],i=void 0===a?r:a,c=i-r,s=t.turns;return Math.abs(c)>270&&(s+=d(c)),o([n,i-360*s],t.initial)},r.getKinematics=function(e,t){var r=this.getMovement(e),n=(e[1]-r._movement[1]-this.state.initial[1])/360,a=t.timeStamp-this.state.timeStamp;return h({turns:n},r,m(f(r.movement,r.delta,a),["distance","velocity"]))},r.mapStateValues=function(e){return{da:e.values,vdva:e.velocities}},t}(Z));var xe=function(e){function t(){var t;return(t=e.apply(this,arguments)||this).ingKey="wheeling",t.stateKey="wheel",t.debounced=!0,t.handleEvent=function(e){if((!e.ctrlKey||!("pinch"in t.controller.handlers))&&t.enabled){t.setTimeout(t.onEnd),t.updateSharedState(T(e));var r=i(N(e,t.transform),t.state.values);if(t.state._active)t.updateGestureState(h({},Y(v(t),e),t.getKinematics(r,e)));else{t.updateGestureState(h({},ee(v(t),r,e,t.state.values),Y(v(t),e,!0)));var n=t.getMovement(r),a=s(n.delta);t.updateGestureState(n),t.updateGestureState(a)}t.fireGestureHandler()}},t.onEnd=function(){if(t.clean(),t.state._active){var e=t.getMovement(t.state.values);t.updateGestureState(e),t.updateGestureState({_active:!1,velocities:[0,0],velocity:0}),t.fireGestureHandler()}},t}return p(t,e),t.prototype.addBindings=function(e){de(e,"onWheel",this.handleEvent)},t}(pe);var ye=function(e){function t(){var t;return(t=e.apply(this,arguments)||this).ingKey="moving",t.stateKey="move",t.debounced=!0,t.onMove=function(e){t.enabled&&(t.setTimeout(t.onMoveEnd),t.state._active?t.onMoveChange(e):t.onMoveStart(e))},t.onMoveStart=function(e){t.updateSharedState(T(e));var r=P(e,t.transform);t.updateGestureState(h({},ee(v(t),r,e),Y(v(t),e,!0))),t.updateGestureState(t.getMovement(r)),t.fireGestureHandler()},t.onMoveChange=function(e){t.updateSharedState(T(e));var r=P(e,t.transform);t.updateGestureState(h({},Y(v(t),e),t.getKinematics(r,e))),t.fireGestureHandler()},t.onMoveEnd=function(){if(t.clean(),t.state._active){var e=t.state.values;t.updateGestureState(t.getMovement(e)),t.updateGestureState({velocities:[0,0],velocity:0,_active:!1}),t.fireGestureHandler()}},t.hoverTransform=function(){return t.controller.config.hover.transform||t.controller.config.transform},t.onPointerEnter=function(e){if(t.controller.state.shared.hovering=!0,t.controller.config.enabled){if(t.controller.config.hover.enabled){var r=P(e,t.hoverTransform()),n=h({},t.controller.state.shared,t.state,Y(v(t),e,!0),{args:t.args,values:r,active:!0,hovering:!0});t.controller.handlers.hover(h({},n,t.mapStateValues(n)))}"move"in t.controller.handlers&&t.onMoveStart(e)}},t.onPointerLeave=function(e){if(t.controller.state.shared.hovering=!1,"move"in t.controller.handlers&&t.onMoveEnd(),t.controller.config.hover.enabled){var r=P(e,t.hoverTransform()),n=h({},t.controller.state.shared,t.state,Y(v(t),e),{args:t.args,values:r,active:!1});t.controller.handlers.hover(h({},n,t.mapStateValues(n)))}},t}return p(t,e),t.prototype.addBindings=function(e){"move"in this.controller.handlers&&de(e,"onPointerMove",this.onMove),"hover"in this.controller.handlers&&(de(e,"onPointerEnter",this.onPointerEnter),de(e,"onPointerLeave",this.onPointerLeave))},t}(pe);var we=function(e){function t(){var t;return(t=e.apply(this,arguments)||this).ingKey="scrolling",t.stateKey="scroll",t.debounced=!0,t.handleEvent=function(e){if(t.enabled){t.clearTimeout(),t.setTimeout(t.onEnd);var r=R(e,t.transform);if(t.updateSharedState(T(e)),t.state._active)t.updateGestureState(h({},Y(v(t),e),t.getKinematics(r,e)));else{t.updateGestureState(h({},ee(v(t),r,e,t.state.values),Y(v(t),e,!0)));var n=t.getMovement(r),a=s(n.delta);t.updateGestureState(n),t.updateGestureState(a)}t.fireGestureHandler()}},t.onEnd=function(){t.clean(),t.state._active&&(t.updateGestureState(h({},t.getMovement(t.state.values),{_active:!1,velocities:[0,0],velocity:0})),t.fireGestureHandler())},t}return p(t,e),t.prototype.addBindings=function(e){de(e,"onScroll",this.handleEvent)},t}(pe);var ke=/^on(Drag|Wheel|Scroll|Move|Pinch|Hover)/;function _e(e,t){void 0===t&&(t={});var r=function(e){var t={},r={},n=new Set;for(var a in e)ke.test(a)?(n.add(RegExp.lastMatch),r[a]=e[a]):t[a]=e[a];return[r,t,n]}(e),n=r[0],a=r[1],i=r[2];K.set("drag",ve),K.set("hover",ye),K.set("move",ye),K.set("pinch",ge),K.set("scroll",we),K.set("wheel",xe);var o=function(e,t){void 0===e&&(e={}),void 0===t&&(t=new Set);var r=e,n=r.drag,a=r.wheel,i=r.move,o=r.scroll,c=r.pinch,s=r.hover,f=r.eventOptions,d=r.window,u=r.transform,l=H({domTarget:r.domTarget,eventOptions:f,transform:u,window:d,enabled:r.enabled});return t.has("onDrag")&&(l.drag=V(n)),t.has("onWheel")&&(l.wheel=q(a)),t.has("onScroll")&&(l.scroll=q(o)),t.has("onMove")&&(l.move=q(i)),t.has("onPinch")&&(l.pinch=J(c)),t.has("onHover")&&(l.hover=h({enabled:!0},s)),l}(t,i),c={};return i.has("onDrag")&&(c.drag=Me(n,"onDrag")),i.has("onWheel")&&(c.wheel=Me(n,"onWheel")),i.has("onScroll")&&(c.scroll=Me(n,"onScroll")),i.has("onMove")&&(c.move=Me(n,"onMove")),i.has("onPinch")&&(c.pinch=Me(n,"onPinch")),i.has("onHover")&&(c.hover=n.onHover),be(c,o,a)}function Me(e,t){var r=t+"Start",n=t+"End";return function(a){var i=void 0;return a.first&&r in e&&e[r](a),t in e&&(i=e[t](a)),a.last&&n in e&&e[n](a),i}}},function(e,t,r){"use strict";e.exports=r(972)},function(e,t,r){var n=r(336);e.exports=function(e,t){return n(e,t)}},function(e,t,r){"use strict";(function(e){var r=function(){if("undefined"!==typeof Map)return Map;function e(e,t){var r=-1;return e.some((function(e,n){return e[0]===t&&(r=n,!0)})),r}return function(){function t(){this.__entries__=[]}return Object.defineProperty(t.prototype,"size",{get:function(){return this.__entries__.length},enumerable:!0,configurable:!0}),t.prototype.get=function(t){var r=e(this.__entries__,t),n=this.__entries__[r];return n&&n[1]},t.prototype.set=function(t,r){var n=e(this.__entries__,t);~n?this.__entries__[n][1]=r:this.__entries__.push([t,r])},t.prototype.delete=function(t){var r=this.__entries__,n=e(r,t);~n&&r.splice(n,1)},t.prototype.has=function(t){return!!~e(this.__entries__,t)},t.prototype.clear=function(){this.__entries__.splice(0)},t.prototype.forEach=function(e,t){void 0===t&&(t=null);for(var r=0,n=this.__entries__;r0},e.prototype.connect_=function(){n&&!this.connected_&&(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),c?(this.mutationsObserver_=new MutationObserver(this.refresh),this.mutationsObserver_.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0})):(document.addEventListener("DOMSubtreeModified",this.refresh),this.mutationEventsAdded_=!0),this.connected_=!0)},e.prototype.disconnect_=function(){n&&this.connected_&&(document.removeEventListener("transitionend",this.onTransitionEnd_),window.removeEventListener("resize",this.refresh),this.mutationsObserver_&&this.mutationsObserver_.disconnect(),this.mutationEventsAdded_&&document.removeEventListener("DOMSubtreeModified",this.refresh),this.mutationsObserver_=null,this.mutationEventsAdded_=!1,this.connected_=!1)},e.prototype.onTransitionEnd_=function(e){var t=e.propertyName,r=void 0===t?"":t;o.some((function(e){return!!~r.indexOf(e)}))&&this.refresh()},e.getInstance=function(){return this.instance_||(this.instance_=new e),this.instance_},e.instance_=null,e}(),f=function(e,t){for(var r=0,n=Object.keys(t);r0},e}(),w="undefined"!==typeof WeakMap?new WeakMap:new r,k=function e(t){if(!(this instanceof e))throw new TypeError("Cannot call a class as a function.");if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");var r=s.getInstance(),n=new y(t,r,this);w.set(this,n)};["observe","unobserve","disconnect"].forEach((function(e){k.prototype[e]=function(){var t;return(t=w.get(this))[e].apply(t,arguments)}}));var _="undefined"!==typeof a.ResizeObserver?a.ResizeObserver:k;t.a=_}).call(this,r(44))},function(e,t,r){"use strict";var n=r(1022),a=r(1026),i=[].slice,o=["keyword","gray","hex"],c={};Object.keys(a).forEach((function(e){c[i.call(a[e].labels).sort().join("")]=e}));var s={};function f(e,t){if(!(this instanceof f))return new f(e,t);if(t&&t in o&&(t=null),t&&!(t in a))throw new Error("Unknown model: "+t);var r,d;if(null==e)this.model="rgb",this.color=[0,0,0],this.valpha=1;else if(e instanceof f)this.model=e.model,this.color=e.color.slice(),this.valpha=e.valpha;else if("string"===typeof e){var u=n.get(e);if(null===u)throw new Error("Unable to parse color from string: "+e);this.model=u.model,d=a[this.model].channels,this.color=u.value.slice(0,d),this.valpha="number"===typeof u.value[d]?u.value[d]:1}else if(e.length){this.model=t||"rgb",d=a[this.model].channels;var l=i.call(e,0,d);this.color=b(l,d),this.valpha="number"===typeof e[d]?e[d]:1}else if("number"===typeof e)e&=16777215,this.model="rgb",this.color=[e>>16&255,e>>8&255,255&e],this.valpha=1;else{this.valpha=1;var h=Object.keys(e);"alpha"in e&&(h.splice(h.indexOf("alpha"),1),this.valpha="number"===typeof e.alpha?e.alpha:0);var p=h.sort().join("");if(!(p in c))throw new Error("Unable to parse color from object: "+JSON.stringify(e));this.model=c[p];var m=a[this.model].labels,v=[];for(r=0;rr?(t+.05)/(r+.05):(r+.05)/(t+.05)},level:function(e){var t=this.contrast(e);return t>=7.1?"AAA":t>=4.5?"AA":""},isDark:function(){var e=this.rgb().color;return(299*e[0]+587*e[1]+114*e[2])/1e3<128},isLight:function(){return!this.isDark()},negate:function(){for(var e=this.rgb(),t=0;t<3;t++)e.color[t]=255-e.color[t];return e},lighten:function(e){var t=this.hsl();return t.color[2]+=t.color[2]*e,t},darken:function(e){var t=this.hsl();return t.color[2]-=t.color[2]*e,t},saturate:function(e){var t=this.hsl();return t.color[1]+=t.color[1]*e,t},desaturate:function(e){var t=this.hsl();return t.color[1]-=t.color[1]*e,t},whiten:function(e){var t=this.hwb();return t.color[1]+=t.color[1]*e,t},blacken:function(e){var t=this.hwb();return t.color[2]+=t.color[2]*e,t},grayscale:function(){var e=this.rgb().color,t=.3*e[0]+.59*e[1]+.11*e[2];return f.rgb(t,t,t)},fade:function(e){return this.alpha(this.valpha-this.valpha*e)},opaquer:function(e){return this.alpha(this.valpha+this.valpha*e)},rotate:function(e){var t=this.hsl(),r=t.color[0];return r=(r=(r+e)%360)<0?360+r:r,t.color[0]=r,t},mix:function(e,t){if(!e||!e.rgb)throw new Error('Argument to "mix" was not a Color instance, but rather an instance of '+typeof e);var r=e.rgb(),n=this.rgb(),a=void 0===t?.5:t,i=2*a-1,o=r.alpha()-n.alpha(),c=((i*o===-1?i:(i+o)/(1+i*o))+1)/2,s=1-c;return f.rgb(c*r.red()+s*n.red(),c*r.green()+s*n.green(),c*r.blue()+s*n.blue(),r.alpha()*a+n.alpha()*(1-a))}},Object.keys(a).forEach((function(e){if(-1===o.indexOf(e)){var t=a[e].channels;f.prototype[e]=function(){if(this.model===e)return new f(this);if(arguments.length)return new f(arguments,e);var r="number"===typeof arguments[t]?t:this.valpha;return new f(l(a[this.model][e].raw(this.color)).concat(r),e)},f[e]=function(r){return"number"===typeof r&&(r=b(i.call(arguments),t)),new f(r,e)}}})),e.exports=f},function(e,t,r){"use strict";t.a=function(){return!1}},function(e,t,r){"use strict";(function(e){var n=r(67),a="object"==typeof exports&&exports&&!exports.nodeType&&exports,i=a&&"object"==typeof e&&e&&!e.nodeType&&e,o=i&&i.exports===a?n.a.Buffer:void 0,c=o?o.allocUnsafe:void 0;t.a=function(e,t){if(t)return e.slice();var r=e.length,n=c?c(r):new e.constructor(r);return e.copy(n),n}}).call(this,r(355)(e))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n,a=Object.assign||function(e){for(var t=1;t=0||Object.prototype.hasOwnProperty.call(e,n)&&(r[n]=e[n]);return r}(e,["fill","width","height","style"]);return o.default.createElement("svg",a({viewBox:"0 0 24 24",style:a({fill:r,width:i,height:s},d)},u),o.default.createElement("path",{d:"M12,18.17L8.83,15L7.42,16.41L12,21L16.59,16.41L15.17,15M12,5.83L15.17,9L16.58,7.59L12,3L7.41,7.59L8.83,9L12,5.83Z"}))}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n,a=Object.assign||function(e){for(var t=1;t=0||Object.prototype.hasOwnProperty.call(e,n)&&(r[n]=e[n]);return r}(e,["fill","width","height","style"]);return o.default.createElement("svg",a({viewBox:"0 0 24 24",style:a({fill:r,width:i,height:s},d)},u),o.default.createElement("path",{d:"M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"}))}},function(e,t,r){var n,a=r(1107),i=r(1108),o=r(1110),c=r(1115);function s(e,t,r,a,i){var o=e.rect(0,0,r,r);o.rotate(360*n.random());var c=r/i*n.random()+a*r/i;o.translate(c),o.rotate(180*n.random()),o.attr("fill",f(t)),o.attr("stroke","none")}function f(e){n.random();var t=Math.floor(e.length*n.random());return e.splice(t,1)[0]}e.exports=function(e,t){n=new a(t);var r=i(e),d=r.paper,u=r.container,l=function(e,t){var r=30*t.random()-15;return e.map((function(e){var t=o(e);return t.rotate(r),t.hexString()}))}(c.slice(),n),b=d.rect(0,0,e,e);b.attr("fill",f(l)),b.attr("stroke","none");for(var h=0;h<3;h++)s(d,l,e,h,3);return u}},function(e,t,r){"use strict";r.d(t,"a",(function(){return a}));var n=r(0);function a(e){return Object(n.a)({tag:"svg",attr:{viewBox:"0 0 16 16",fill:"currentColor"},child:[{tag:"path",attr:{fillRule:"evenodd",clipRule:"evenodd",d:"M8.6 1c1.6.1 3.1.9 4.2 2 1.3 1.4 2 3.1 2 5.1 0 1.6-.6 3.1-1.6 4.4-1 1.2-2.4 2.1-4 2.4-1.6.3-3.2.1-4.6-.7-1.4-.8-2.5-2-3.1-3.5C.9 9.2.8 7.5 1.3 6c.5-1.6 1.4-2.9 2.8-3.8C5.4 1.3 7 .9 8.6 1zm.5 12.9c1.3-.3 2.5-1 3.4-2.1.8-1.1 1.3-2.4 1.2-3.8 0-1.6-.6-3.2-1.7-4.3-1-1-2.2-1.6-3.6-1.7-1.3-.1-2.7.2-3.8 1-1.1.8-1.9 1.9-2.3 3.3-.4 1.3-.4 2.7.2 4 .6 1.3 1.5 2.3 2.7 3 1.2.7 2.6.9 3.9.6zM7.9 7.5L10.3 5l.7.7-2.4 2.5 2.4 2.5-.7.7-2.4-2.5-2.4 2.5-.7-.7 2.4-2.5-2.4-2.5.7-.7 2.4 2.5z"}}]})(e)}},function(e,t,r){"use strict";(function(e){var n=r(1),a=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},i=function(){function e(e,t){for(var r=0;r div, .contract-trigger:before { content: " "; display: block; position: absolute; top: 0; left: 0; height: 100%; width: 100%; overflow: hidden; z-index: -1; } .resize-triggers > div { background: #eee; overflow: auto; } .contract-trigger:before { width: 200%; height: 200%; }',i=r.head||r.getElementsByTagName("head")[0],o=r.createElement("style");o.id="detectElementResize",o.type="text/css",null!=e&&o.setAttribute("nonce",e),o.styleSheet?o.styleSheet.cssText=n:o.appendChild(r.createTextNode(n)),i.appendChild(o)}}(u),i.__resizeLast__={},i.__resizeListeners__=[],(i.__resizeTriggers__=u.createElement("div")).className="resize-triggers";var b=u.createElement("div");b.className="expand-trigger",b.appendChild(u.createElement("div"));var h=u.createElement("div");h.className="contract-trigger",i.__resizeTriggers__.appendChild(b),i.__resizeTriggers__.appendChild(h),i.appendChild(i.__resizeTriggers__),o(i),i.addEventListener("scroll",c,!0),n&&(i.__resizeTriggers__.__animationListener__=function(e){e.animationName===r&&o(i)},i.__resizeTriggers__.addEventListener(n,i.__resizeTriggers__.__animationListener__))}i.__resizeListeners__.push(d)}},removeResizeListener:function(e,t){if(s)e.detachEvent("onresize",t);else if(e.__resizeListeners__.splice(e.__resizeListeners__.indexOf(t),1),!e.__resizeListeners__.length){e.removeEventListener("scroll",c,!0),e.__resizeTriggers__.__animationListener__&&(e.__resizeTriggers__.removeEventListener(n,e.__resizeTriggers__.__animationListener__),e.__resizeTriggers__.__animationListener__=null);try{e.__resizeTriggers__=!e.removeChild(e.__resizeTriggers__)}catch(r){}}}}}null==h||null==p?(d=l,u=function(e){return b(e,20)}):(d=function(e){var t=s(e,2),r=t[0],n=t[1];h(r),l(n)},u=function(e){var t=p((function(){l(r),e()})),r=b((function(){h(t),e()}),20);return[t,r]});var v=function(e){function t(){var e,r,n;a(this,t);for(var i=arguments.length,o=Array(i),s=0;so?1:Math.round(100*d/o)/100,t.a!==u)return{h:t.h,s:t.s,l:t.l,a:u,source:"rgb"}}else{var l=void 0;if(n!==(l=f<0?0:f>i?1:Math.round(100*f/i)/100))return{h:t.h,s:t.s,l:t.l,a:l,source:"rgb"}}return null},s={},f=function(e,t,r,n){var a=e+"-"+t+"-"+r+(n?"-server":"");if(s[a])return s[a];var i=function(e,t,r,n){if("undefined"===typeof document&&!n)return null;var a=n?new n:document.createElement("canvas");a.width=2*r,a.height=2*r;var i=a.getContext("2d");return i?(i.fillStyle=e,i.fillRect(0,0,a.width,a.height),i.fillStyle=t,i.fillRect(0,0,r,r),i.translate(r,r),i.fillRect(0,0,r,r),a.toDataURL()):null}(e,t,r,n);return s[a]=i,i},d=Object.assign||function(e){for(var t=1;t-1)){var a=r.getArrowOffset(),i=38===e.keyCode?n+a:n-a;r.setUpdatedValue(i,e)}},r.handleDrag=function(e){if(r.props.dragLabel){var t=Math.round(r.props.value+e.movementX);t>=0&&t<=r.props.dragMax&&r.props.onChange&&r.props.onChange(r.getValueObjectWithLabel(t),e)}},r.handleMouseDown=function(e){r.props.dragLabel&&(e.preventDefault(),r.handleDrag(e),window.addEventListener("mousemove",r.handleDrag),window.addEventListener("mouseup",r.handleMouseUp))},r.handleMouseUp=function(){r.unbindEventListeners()},r.unbindEventListeners=function(){window.removeEventListener("mousemove",r.handleDrag),window.removeEventListener("mouseup",r.handleMouseUp)},r.state={value:String(e.value).toUpperCase(),blurValue:String(e.value).toUpperCase()},r.inputId="rc-editable-input-"+y++,r}return function(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),g(t,[{key:"componentDidUpdate",value:function(e,t){this.props.value===this.state.value||e.value===this.props.value&&t.value===this.state.value||(this.input===document.activeElement?this.setState({blurValue:String(this.props.value).toUpperCase()}):this.setState({value:String(this.props.value).toUpperCase(),blurValue:!this.state.blurValue&&String(this.props.value).toUpperCase()}))}},{key:"componentWillUnmount",value:function(){this.unbindEventListeners()}},{key:"getValueObjectWithLabel",value:function(e){return function(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}({},this.props.label,e)}},{key:"getArrowOffset",value:function(){return this.props.arrowOffset||1}},{key:"setUpdatedValue",value:function(e,t){var r=this.props.label?this.getValueObjectWithLabel(e):e;this.props.onChange&&this.props.onChange(r,t),this.setState({value:e})}},{key:"render",value:function(){var e=this,t=o()({default:{wrap:{position:"relative"}},"user-override":{wrap:this.props.style&&this.props.style.wrap?this.props.style.wrap:{},input:this.props.style&&this.props.style.input?this.props.style.input:{},label:this.props.style&&this.props.style.label?this.props.style.label:{}},"dragLabel-true":{label:{cursor:"ew-resize"}}},{"user-override":!0},this.props);return a.a.createElement("div",{style:t.wrap},a.a.createElement("input",{id:this.inputId,style:t.input,ref:function(t){return e.input=t},value:this.state.value,onKeyDown:this.handleKeyDown,onChange:this.handleChange,onBlur:this.handleBlur,placeholder:this.props.placeholder,spellCheck:"false"}),this.props.label&&!this.props.hideLabel?a.a.createElement("label",{htmlFor:this.inputId,style:t.label,onMouseDown:this.handleMouseDown},this.props.label):null)}}]),t}(n.PureComponent||n.Component),k=function(e,t,r,n){var a=n.clientWidth,i=n.clientHeight,o="number"===typeof e.pageX?e.pageX:e.touches[0].pageX,c="number"===typeof e.pageY?e.pageY:e.touches[0].pageY,s=o-(n.getBoundingClientRect().left+window.pageXOffset),f=c-(n.getBoundingClientRect().top+window.pageYOffset);if("vertical"===t){var d=void 0;if(f<0)d=359;else if(f>i)d=0;else{d=360*(-100*f/i+100)/100}if(r.h!==d)return{h:d,s:r.s,l:r.l,a:r.a,source:"hsl"}}else{var u=void 0;if(s<0)u=0;else if(s>a)u=359;else{u=360*(100*s/a)/100}if(r.h!==u)return{h:u,s:r.s,l:r.l,a:r.a,source:"hsl"}}return null},_=function(){function e(e,t){for(var r=0;r-1};var L=function(e,t){var r=this.__data__,n=P(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this};function I(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t-1&&e%1==0&&e<=9007199254740991};var ft=function(e){return null!=e&&st(e.length)&&!te(e)};var dt=function(e){return tt(e)&&ft(e)},ut=r(162),lt=Function.prototype,bt=Object.prototype,ht=lt.toString,pt=bt.hasOwnProperty,mt=ht.call(Object);var vt=function(e){if(!tt(e)||"[object Object]"!=Y(e))return!1;var t=$e(e);if(null===t)return!0;var r=pt.call(t,"constructor")&&t.constructor;return"function"==typeof r&&r instanceof r&&ht.call(r)==mt},gt={};gt["[object Float32Array]"]=gt["[object Float64Array]"]=gt["[object Int8Array]"]=gt["[object Int16Array]"]=gt["[object Int32Array]"]=gt["[object Uint8Array]"]=gt["[object Uint8ClampedArray]"]=gt["[object Uint16Array]"]=gt["[object Uint32Array]"]=!0,gt["[object Arguments]"]=gt["[object Array]"]=gt["[object ArrayBuffer]"]=gt["[object Boolean]"]=gt["[object DataView]"]=gt["[object Date]"]=gt["[object Error]"]=gt["[object Function]"]=gt["[object Map]"]=gt["[object Number]"]=gt["[object Object]"]=gt["[object RegExp]"]=gt["[object Set]"]=gt["[object String]"]=gt["[object WeakMap]"]=!1;var xt=function(e){return tt(e)&&st(e.length)&&!!gt[Y(e)]};var yt=function(e){return function(t){return e(t)}},wt=r(377),kt=wt.a&&wt.a.isTypedArray,_t=kt?yt(kt):xt;var Mt=function(e,t){if(("constructor"!==t||"function"!==typeof e[t])&&"__proto__"!=t)return e[t]},St=Object.prototype.hasOwnProperty;var Et=function(e,t,r){var n=e[t];St.call(e,t)&&j(n,r)&&(void 0!==r||t in e)||Ue(e,t,r)};var Ot=function(e,t,r,n){var a=!r;r||(r={});for(var i=-1,o=t.length;++i-1&&e%1==0&&e0){if(++t>=800)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}(Vt);var Kt=function(e,t){return Xt(qt(e,t,Ut),e+"")};var Wt=function(e,t,r){if(!ee(r))return!1;var n=typeof t;return!!("number"==n?ft(r)&&jt(t,r.length):"string"==n&&t in r)&&j(r[t],e)};var Zt=function(e){return Kt((function(t,r){var n=-1,a=r.length,i=a>1?r[a-1]:void 0,o=a>2?r[2]:void 0;for(i=e.length>3&&"function"==typeof i?(a--,i):void 0,o&&Wt(r[0],r[1],o)&&(i=a<3?void 0:i,a=1),t=Object(t);++n=t||r<0||u&&e-f>=i}function m(){var e=Yt();if(p(e))return v(e);c=setTimeout(m,function(e){var r=t-(e-s);return u?ur(r,i-(e-f)):r}(e))}function v(e){return c=void 0,l&&n?b(e):(n=a=void 0,o)}function g(){var e=Yt(),r=p(e);if(n=arguments,a=this,s=e,r){if(void 0===c)return h(s);if(u)return clearTimeout(c),c=setTimeout(m,t),b(s)}return void 0===c&&(c=setTimeout(m,t)),o}return t=fr(t)||0,ee(r)&&(d=!!r.leading,i=(u="maxWait"in r)?dr(fr(r.maxWait)||0,t):i,l="trailing"in r?!!r.trailing:l),g.cancel=function(){void 0!==c&&clearTimeout(c),f=0,n=s=a=c=void 0},g.flush=function(){return void 0===c?o:v(Yt())},g};var br=function(e,t,r){var n=!0,a=!0;if("function"!=typeof e)throw new TypeError("Expected a function");return ee(r)&&(n="leading"in r?!!r.leading:n,a="trailing"in r?!!r.trailing:a),lr(e,t,{leading:n,maxWait:t,trailing:a})},hr=function(){function e(e,t){for(var r=0;ra&&(s=a),f<0?f=0:f>i&&(f=i);var d=s/a,u=1-f/i;return{h:t.h,s:d,v:u,a:t.a,source:"hsv"}}(e,r.props.hsl,r.container),e)},r.handleMouseDown=function(e){r.handleChange(e);var t=r.getContainerRenderWindow();t.addEventListener("mousemove",r.handleChange),t.addEventListener("mouseup",r.handleMouseUp)},r.handleMouseUp=function(){r.unbindEventListeners()},r.throttle=br((function(e,t,r){e(t,r)}),50),r}return function(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),hr(t,[{key:"componentWillUnmount",value:function(){this.throttle.cancel(),this.unbindEventListeners()}},{key:"getContainerRenderWindow",value:function(){for(var e=this.container,t=window;!t.document.contains(e)&&t.parent!==t;)t=t.parent;return t}},{key:"unbindEventListeners",value:function(){var e=this.getContainerRenderWindow();e.removeEventListener("mousemove",this.handleChange),e.removeEventListener("mouseup",this.handleMouseUp)}},{key:"render",value:function(){var e=this,t=this.props.style||{},r=t.color,n=t.white,i=t.black,c=t.pointer,s=t.circle,f=o()({default:{color:{absolute:"0px 0px 0px 0px",background:"hsl("+this.props.hsl.h+",100%, 50%)",borderRadius:this.props.radius},white:{absolute:"0px 0px 0px 0px",borderRadius:this.props.radius},black:{absolute:"0px 0px 0px 0px",boxShadow:this.props.shadow,borderRadius:this.props.radius},pointer:{position:"absolute",top:-100*this.props.hsv.v+100+"%",left:100*this.props.hsv.s+"%",cursor:"default"},circle:{width:"4px",height:"4px",boxShadow:"0 0 0 1.5px #fff, inset 0 0 1px 1px rgba(0,0,0,.3),\n 0 0 1px 2px rgba(0,0,0,.4)",borderRadius:"50%",cursor:"hand",transform:"translate(-2px, -2px)"}},custom:{color:r,white:n,black:i,pointer:c,circle:s}},{custom:!!this.props.style});return a.a.createElement("div",{style:f.color,ref:function(t){return e.container=t},onMouseDown:this.handleMouseDown,onTouchMove:this.handleChange,onTouchStart:this.handleChange},a.a.createElement("style",null,"\n .saturation-white {\n background: -webkit-linear-gradient(to right, #fff, rgba(255,255,255,0));\n background: linear-gradient(to right, #fff, rgba(255,255,255,0));\n }\n .saturation-black {\n background: -webkit-linear-gradient(to top, #000, rgba(0,0,0,0));\n background: linear-gradient(to top, #000, rgba(0,0,0,0));\n }\n "),a.a.createElement("div",{style:f.white,className:"saturation-white"},a.a.createElement("div",{style:f.black,className:"saturation-black"}),a.a.createElement("div",{style:f.pointer},this.props.pointer?a.a.createElement(this.props.pointer,this.props):a.a.createElement("div",{style:f.circle}))))}}]),t}(n.PureComponent||n.Component);var mr=function(e,t){for(var r=-1,n=null==e?0:e.length;++r=128?"#000":"#fff"},jr=function(e,t){var r=e.replace("\xb0","");return Sr()(t+" ("+r+")")._ok},Pr=Object.assign||function(e){for(var t=1;t1&&void 0!==arguments[1]?arguments[1]:"span";return function(r){function n(){var e,t,r;Lr(this,n);for(var a=arguments.length,i=Array(a),o=0;oc))return!1;var f=i.get(e),d=i.get(t);if(f&&d)return f==t&&d==e;var u=-1,l=!0,b=2&r?new Kr:void 0;for(i.set(e,t),i.set(t,e);++u1&&(e.a=1),r.props.onChange({h:r.props.hsl.h,s:r.props.hsl.s,l:r.props.hsl.l,a:Math.round(100*e.a)/100,source:"rgb"},t)):(e.h||e.s||e.l)&&("string"===typeof e.s&&e.s.includes("%")&&(e.s=e.s.replace("%","")),"string"===typeof e.l&&e.l.includes("%")&&(e.l=e.l.replace("%","")),1==e.s?e.s=.01:1==e.l&&(e.l=.01),r.props.onChange({h:e.h||r.props.hsl.h,s:Number(Aa(e.s)?r.props.hsl.s:e.s),l:Number(Aa(e.l)?r.props.hsl.l:e.l),source:"hsl"},t))},r.showHighlight=function(e){e.currentTarget.style.background="#eee"},r.hideHighlight=function(e){e.currentTarget.style.background="transparent"},1!==e.hsl.a&&"hex"===e.view?r.state={view:"rgb"}:r.state={view:e.view},r}return function(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),Pa(t,[{key:"render",value:function(){var e=this,t=o()({default:{wrap:{paddingTop:"16px",display:"flex"},fields:{flex:"1",display:"flex",marginLeft:"-6px"},field:{paddingLeft:"6px",width:"100%"},alpha:{paddingLeft:"6px",width:"100%"},toggle:{width:"32px",textAlign:"right",position:"relative"},icon:{marginRight:"-4px",marginTop:"12px",cursor:"pointer",position:"relative"},iconHighlight:{position:"absolute",width:"24px",height:"28px",background:"#eee",borderRadius:"4px",top:"10px",left:"12px",display:"none"},input:{fontSize:"11px",color:"#333",width:"100%",borderRadius:"2px",border:"none",boxShadow:"inset 0 0 0 1px #dadada",height:"21px",textAlign:"center"},label:{textTransform:"uppercase",fontSize:"11px",lineHeight:"11px",color:"#969696",textAlign:"center",display:"block",marginTop:"12px"},svg:{fill:"#333",width:"24px",height:"24px",border:"1px transparent solid",borderRadius:"5px"}},disableAlpha:{alpha:{display:"none"}}},this.props,this.state),r=void 0;return"hex"===this.state.view?r=a.a.createElement("div",{style:t.fields,className:"flexbox-fix"},a.a.createElement("div",{style:t.field},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"hex",value:this.props.hex,onChange:this.handleChange}))):"rgb"===this.state.view?r=a.a.createElement("div",{style:t.fields,className:"flexbox-fix"},a.a.createElement("div",{style:t.field},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"r",value:this.props.rgb.r,onChange:this.handleChange})),a.a.createElement("div",{style:t.field},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"g",value:this.props.rgb.g,onChange:this.handleChange})),a.a.createElement("div",{style:t.field},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"b",value:this.props.rgb.b,onChange:this.handleChange})),a.a.createElement("div",{style:t.alpha},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"a",value:this.props.rgb.a,arrowOffset:.01,onChange:this.handleChange}))):"hsl"===this.state.view&&(r=a.a.createElement("div",{style:t.fields,className:"flexbox-fix"},a.a.createElement("div",{style:t.field},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"h",value:Math.round(this.props.hsl.h),onChange:this.handleChange})),a.a.createElement("div",{style:t.field},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"s",value:Math.round(100*this.props.hsl.s)+"%",onChange:this.handleChange})),a.a.createElement("div",{style:t.field},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"l",value:Math.round(100*this.props.hsl.l)+"%",onChange:this.handleChange})),a.a.createElement("div",{style:t.alpha},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"a",value:this.props.hsl.a,arrowOffset:.01,onChange:this.handleChange})))),a.a.createElement("div",{style:t.wrap,className:"flexbox-fix"},r,a.a.createElement("div",{style:t.toggle},a.a.createElement("div",{style:t.icon,onClick:this.toggleViews,ref:function(t){return e.icon=t}},a.a.createElement(ja.a,{style:t.svg,onMouseOver:this.showHighlight,onMouseEnter:this.showHighlight,onMouseOut:this.hideHighlight}))))}}],[{key:"getDerivedStateFromProps",value:function(e,t){return 1!==e.hsl.a&&"hex"===t.view?{view:"rgb"}:null}}]),t}(a.a.Component);Ca.defaultProps={view:"hex"};var Ra=Ca,Na=function(){var e=o()({default:{picker:{width:"12px",height:"12px",borderRadius:"6px",transform:"translate(-6px, -1px)",backgroundColor:"rgb(248, 248, 248)",boxShadow:"0 1px 4px 0 rgba(0, 0, 0, 0.37)"}}});return a.a.createElement("div",{style:e.picker})},Ba=function(){var e=o()({default:{picker:{width:"12px",height:"12px",borderRadius:"6px",boxShadow:"inset 0 0 0 1px #fff",transform:"translate(-6px, -6px)"}}});return a.a.createElement("div",{style:e.picker})},La=function(e){var t=e.width,r=e.onChange,n=e.disableAlpha,i=e.rgb,c=e.hsl,s=e.hsv,f=e.hex,d=e.renderers,u=e.styles,b=void 0===u?{}:u,h=e.className,p=void 0===h?"":h,m=e.defaultView,g=o()(Zt({default:{picker:{width:t,background:"#fff",borderRadius:"2px",boxShadow:"0 0 2px rgba(0,0,0,.3), 0 4px 8px rgba(0,0,0,.3)",boxSizing:"initial",fontFamily:"Menlo"},saturation:{width:"100%",paddingBottom:"55%",position:"relative",borderRadius:"2px 2px 0 0",overflow:"hidden"},Saturation:{radius:"2px 2px 0 0"},body:{padding:"16px 16px 12px"},controls:{display:"flex"},color:{width:"32px"},swatch:{marginTop:"6px",width:"16px",height:"16px",borderRadius:"8px",position:"relative",overflow:"hidden"},active:{absolute:"0px 0px 0px 0px",borderRadius:"8px",boxShadow:"inset 0 0 0 1px rgba(0,0,0,.1)",background:"rgba("+i.r+", "+i.g+", "+i.b+", "+i.a+")",zIndex:"2"},toggles:{flex:"1"},hue:{height:"10px",position:"relative",marginBottom:"8px"},Hue:{radius:"2px"},alpha:{height:"10px",position:"relative"},Alpha:{radius:"2px"}},disableAlpha:{color:{width:"22px"},alpha:{display:"none"},hue:{marginBottom:"0px"},swatch:{width:"10px",height:"10px",marginTop:"0px"}}},b),{disableAlpha:n});return a.a.createElement("div",{style:g.picker,className:"chrome-picker "+p},a.a.createElement("div",{style:g.saturation},a.a.createElement(pr,{style:g.Saturation,hsl:c,hsv:s,pointer:Ba,onChange:r})),a.a.createElement("div",{style:g.body},a.a.createElement("div",{style:g.controls,className:"flexbox-fix"},a.a.createElement("div",{style:g.color},a.a.createElement("div",{style:g.swatch},a.a.createElement("div",{style:g.active}),a.a.createElement(l,{renderers:d}))),a.a.createElement("div",{style:g.toggles},a.a.createElement("div",{style:g.hue},a.a.createElement(E,{style:g.Hue,hsl:c,pointer:Na,onChange:r})),a.a.createElement("div",{style:g.alpha},a.a.createElement(v,{style:g.Alpha,rgb:i,hsl:c,pointer:Na,renderers:d,onChange:r})))),a.a.createElement(Ra,{rgb:i,hsl:c,hex:f,view:m,onChange:r,disableAlpha:n})))};La.propTypes={width:A.a.oneOfType([A.a.string,A.a.number]),disableAlpha:A.a.bool,styles:A.a.object,defaultView:A.a.oneOf(["hex","rgb","hsl"])},La.defaultProps={width:225,disableAlpha:!1,styles:{}};Rr(La);var Ia=function(e){var t=e.color,r=e.onClick,n=void 0===r?function(){}:r,i=e.onSwatchHover,c=e.active,s=o()({default:{color:{background:t,width:"15px",height:"15px",float:"left",marginRight:"5px",marginBottom:"5px",position:"relative",cursor:"pointer"},dot:{absolute:"5px 5px 5px 5px",background:Tr(t),borderRadius:"50%",opacity:"0"}},active:{dot:{opacity:"1"}},"color-#FFFFFF":{color:{boxShadow:"inset 0 0 0 1px #ddd"},dot:{background:"#000"}},transparent:{dot:{background:"#000"}}},{active:c,"color-#FFFFFF":"#FFFFFF"===t,transparent:"transparent"===t});return a.a.createElement(Ur,{style:s.color,color:t,onClick:n,onHover:i,focusStyle:{boxShadow:"0 0 4px "+t}},a.a.createElement("div",{style:s.dot}))},Fa=function(e){var t=e.hex,r=e.rgb,n=e.onChange,i=o()({default:{fields:{display:"flex",paddingBottom:"6px",paddingRight:"5px",position:"relative"},active:{position:"absolute",top:"6px",left:"5px",height:"9px",width:"9px",background:t},HEXwrap:{flex:"6",position:"relative"},HEXinput:{width:"80%",padding:"0px",paddingLeft:"20%",border:"none",outline:"none",background:"none",fontSize:"12px",color:"#333",height:"16px"},HEXlabel:{display:"none"},RGBwrap:{flex:"3",position:"relative"},RGBinput:{width:"70%",padding:"0px",paddingLeft:"30%",border:"none",outline:"none",background:"none",fontSize:"12px",color:"#333",height:"16px"},RGBlabel:{position:"absolute",top:"3px",left:"0px",lineHeight:"16px",textTransform:"uppercase",fontSize:"12px",color:"#999"}}}),c=function(e,t){e.r||e.g||e.b?n({r:e.r||r.r,g:e.g||r.g,b:e.b||r.b,source:"rgb"},t):n({hex:e.hex,source:"hex"},t)};return a.a.createElement("div",{style:i.fields,className:"flexbox-fix"},a.a.createElement("div",{style:i.active}),a.a.createElement(w,{style:{wrap:i.HEXwrap,input:i.HEXinput,label:i.HEXlabel},label:"hex",value:t,onChange:c}),a.a.createElement(w,{style:{wrap:i.RGBwrap,input:i.RGBinput,label:i.RGBlabel},label:"r",value:r.r,onChange:c}),a.a.createElement(w,{style:{wrap:i.RGBwrap,input:i.RGBinput,label:i.RGBlabel},label:"g",value:r.g,onChange:c}),a.a.createElement(w,{style:{wrap:i.RGBwrap,input:i.RGBinput,label:i.RGBlabel},label:"b",value:r.b,onChange:c}))},Da=function(e){var t=e.onChange,r=e.onSwatchHover,n=e.colors,i=e.hex,c=e.rgb,s=e.styles,f=void 0===s?{}:s,d=e.className,u=void 0===d?"":d,l=o()(Zt({default:{Compact:{background:"#f6f6f6",radius:"4px"},compact:{paddingTop:"5px",paddingLeft:"5px",boxSizing:"initial",width:"240px"},clear:{clear:"both"}}},f)),b=function(e,r){e.hex?Ar(e.hex)&&t({hex:e.hex,source:"hex"},r):t(e,r)};return a.a.createElement(Qt,{style:l.Compact,styles:f},a.a.createElement("div",{style:l.compact,className:"compact-picker "+u},a.a.createElement("div",null,aa(n,(function(e){return a.a.createElement(Ia,{key:e,color:e,active:e.toLowerCase()===i,onClick:b,onSwatchHover:r})})),a.a.createElement("div",{style:l.clear})),a.a.createElement(Fa,{hex:i,rgb:c,onChange:b})))};Da.propTypes={colors:A.a.arrayOf(A.a.string),styles:A.a.object},Da.defaultProps={colors:["#4D4D4D","#999999","#FFFFFF","#F44E3B","#FE9200","#FCDC00","#DBDF00","#A4DD00","#68CCCA","#73D8FF","#AEA1FF","#FDA1FF","#333333","#808080","#cccccc","#D33115","#E27300","#FCC400","#B0BC00","#68BC00","#16A5A5","#009CE0","#7B64FF","#FA28FF","#000000","#666666","#B3B3B3","#9F0500","#C45100","#FB9E00","#808900","#194D33","#0C797D","#0062B1","#653294","#AB149E"],styles:{}};Rr(Da);var Ua=Object(i.handleHover)((function(e){var t=e.hover,r=e.color,n=e.onClick,i=e.onSwatchHover,c={position:"relative",zIndex:"2",outline:"2px solid #fff",boxShadow:"0 0 5px 2px rgba(0,0,0,0.25)"},s=o()({default:{swatch:{width:"25px",height:"25px",fontSize:"0"}},hover:{swatch:c}},{hover:t});return a.a.createElement("div",{style:s.swatch},a.a.createElement(Ur,{color:r,onClick:n,onHover:i,focusStyle:c}))})),za=function(e){var t=e.width,r=e.colors,n=e.onChange,i=e.onSwatchHover,c=e.triangle,s=e.styles,f=void 0===s?{}:s,d=e.className,u=void 0===d?"":d,l=o()(Zt({default:{card:{width:t,background:"#fff",border:"1px solid rgba(0,0,0,0.2)",boxShadow:"0 3px 12px rgba(0,0,0,0.15)",borderRadius:"4px",position:"relative",padding:"5px",display:"flex",flexWrap:"wrap"},triangle:{position:"absolute",border:"7px solid transparent",borderBottomColor:"#fff"},triangleShadow:{position:"absolute",border:"8px solid transparent",borderBottomColor:"rgba(0,0,0,0.15)"}},"hide-triangle":{triangle:{display:"none"},triangleShadow:{display:"none"}},"top-left-triangle":{triangle:{top:"-14px",left:"10px"},triangleShadow:{top:"-16px",left:"9px"}},"top-right-triangle":{triangle:{top:"-14px",right:"10px"},triangleShadow:{top:"-16px",right:"9px"}},"bottom-left-triangle":{triangle:{top:"35px",left:"10px",transform:"rotate(180deg)"},triangleShadow:{top:"37px",left:"9px",transform:"rotate(180deg)"}},"bottom-right-triangle":{triangle:{top:"35px",right:"10px",transform:"rotate(180deg)"},triangleShadow:{top:"37px",right:"9px",transform:"rotate(180deg)"}}},f),{"hide-triangle":"hide"===c,"top-left-triangle":"top-left"===c,"top-right-triangle":"top-right"===c,"bottom-left-triangle":"bottom-left"===c,"bottom-right-triangle":"bottom-right"===c}),b=function(e,t){return n({hex:e,source:"hex"},t)};return a.a.createElement("div",{style:l.card,className:"github-picker "+u},a.a.createElement("div",{style:l.triangleShadow}),a.a.createElement("div",{style:l.triangle}),aa(r,(function(e){return a.a.createElement(Ua,{color:e,key:e,onClick:b,onSwatchHover:i})})))};za.propTypes={width:A.a.oneOfType([A.a.string,A.a.number]),colors:A.a.arrayOf(A.a.string),triangle:A.a.oneOf(["hide","top-left","top-right","bottom-left","bottom-right"]),styles:A.a.object},za.defaultProps={width:200,colors:["#B80000","#DB3E00","#FCCB00","#008B02","#006B76","#1273DE","#004DCF","#5300EB","#EB9694","#FAD0C3","#FEF3BD","#C1E1C5","#BEDADC","#C4DEF6","#BED3F3","#D4C4FB"],triangle:"top-left",styles:{}};Rr(za);var Ha=function(e){var t=e.direction,r=o()({default:{picker:{width:"18px",height:"18px",borderRadius:"50%",transform:"translate(-9px, -1px)",backgroundColor:"rgb(248, 248, 248)",boxShadow:"0 1px 4px 0 rgba(0, 0, 0, 0.37)"}},vertical:{picker:{transform:"translate(-3px, -9px)"}}},{vertical:"vertical"===t});return a.a.createElement("div",{style:r.picker})},qa=Object.assign||function(e){for(var t=1;t.5});return a.a.createElement("div",{style:r.picker})},Ka=function(){var e=o()({default:{triangle:{width:0,height:0,borderStyle:"solid",borderWidth:"4px 0 4px 6px",borderColor:"transparent transparent transparent #fff",position:"absolute",top:"1px",left:"1px"},triangleBorder:{width:0,height:0,borderStyle:"solid",borderWidth:"5px 0 5px 8px",borderColor:"transparent transparent transparent #555"},left:{Extend:"triangleBorder",transform:"translate(-13px, -4px)"},leftInside:{Extend:"triangle",transform:"translate(-8px, -5px)"},right:{Extend:"triangleBorder",transform:"translate(20px, -14px) rotate(180deg)"},rightInside:{Extend:"triangle",transform:"translate(-8px, -5px)"}}});return a.a.createElement("div",{style:e.pointer},a.a.createElement("div",{style:e.left},a.a.createElement("div",{style:e.leftInside})),a.a.createElement("div",{style:e.right},a.a.createElement("div",{style:e.rightInside})))},Wa=function(e){var t=e.onClick,r=e.label,n=e.children,i=e.active,c=o()({default:{button:{backgroundImage:"linear-gradient(-180deg, #FFFFFF 0%, #E6E6E6 100%)",border:"1px solid #878787",borderRadius:"2px",height:"20px",boxShadow:"0 1px 0 0 #EAEAEA",fontSize:"14px",color:"#000",lineHeight:"20px",textAlign:"center",marginBottom:"10px",cursor:"pointer"}},active:{button:{boxShadow:"0 0 0 1px #878787"}}},{active:i});return a.a.createElement("div",{style:c.button,onClick:t},r||n)},Za=function(e){var t=e.rgb,r=e.currentColor,n=o()({default:{swatches:{border:"1px solid #B3B3B3",borderBottom:"1px solid #F0F0F0",marginBottom:"2px",marginTop:"1px"},new:{height:"34px",background:"rgb("+t.r+","+t.g+", "+t.b+")",boxShadow:"inset 1px 0 0 #000, inset -1px 0 0 #000, inset 0 1px 0 #000"},current:{height:"34px",background:r,boxShadow:"inset 1px 0 0 #000, inset -1px 0 0 #000, inset 0 -1px 0 #000"},label:{fontSize:"14px",color:"#000",textAlign:"center"}}});return a.a.createElement("div",null,a.a.createElement("div",{style:n.label},"new"),a.a.createElement("div",{style:n.swatches},a.a.createElement("div",{style:n.new}),a.a.createElement("div",{style:n.current})),a.a.createElement("div",{style:n.label},"current"))},$a=function(){function e(e,t){for(var r=0;r100&&(e.a=100),e.a/=100,t({h:n.h,s:n.s,l:n.l,a:e.a,source:"rgb"},a))};return a.a.createElement("div",{style:s.fields,className:"flexbox-fix"},a.a.createElement("div",{style:s.double},a.a.createElement(w,{style:{input:s.input,label:s.label},label:"hex",value:i.replace("#",""),onChange:f})),a.a.createElement("div",{style:s.single},a.a.createElement(w,{style:{input:s.input,label:s.label},label:"r",value:r.r,onChange:f,dragLabel:"true",dragMax:"255"})),a.a.createElement("div",{style:s.single},a.a.createElement(w,{style:{input:s.input,label:s.label},label:"g",value:r.g,onChange:f,dragLabel:"true",dragMax:"255"})),a.a.createElement("div",{style:s.single},a.a.createElement(w,{style:{input:s.input,label:s.label},label:"b",value:r.b,onChange:f,dragLabel:"true",dragMax:"255"})),a.a.createElement("div",{style:s.alpha},a.a.createElement(w,{style:{input:s.input,label:s.label},label:"a",value:Math.round(100*r.a),onChange:f,dragLabel:"true",dragMax:"100"})))},ei=Object.assign||function(e){for(var t=1;t=0)throw e;return S.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",y.Logger.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,tx:r})}))),null==r.chainId?r.chainId=this.getChainId():r.chainId=Promise.all([Promise.resolve(r.chainId),this.getChainId()]).then((function(t){return 0!==t[1]&&t[0]!==t[1]&&S.throwArgumentError("chainId address mismatch","transaction",e),t[0]})),t.next=10,Object(x.resolveProperties)(r);case 10:return t.abrupt("return",t.sent);case 11:case"end":return t.stop()}}),t,this)})))}},{key:"_checkProvider",value:function(e){this.provider||S.throwError("missing provider",y.Logger.errors.UNSUPPORTED_OPERATION,{operation:e||"_checkProvider"})}}],[{key:"isSigner",value:function(e){return!(!e||!e._isSigner)}}]),e}(),T=function(e){Object(d.a)(r,e);var t=Object(u.a)(r);function r(e,n){var a;return Object(l.a)(this,r),S.checkNew(this instanceof r?this.constructor:void 0,r),a=t.call(this),Object(x.defineReadOnly)(Object(c.a)(a),"address",e),Object(x.defineReadOnly)(Object(c.a)(a),"provider",n||null),a}return Object(b.a)(r,[{key:"getAddress",value:function(){return Promise.resolve(this.address)}},{key:"_fail",value:function(e,t){return Promise.resolve().then((function(){S.throwError(e,y.Logger.errors.UNSUPPORTED_OPERATION,{operation:t})}))}},{key:"signMessage",value:function(e){return this._fail("VoidSigner cannot sign messages","signMessage")}},{key:"signTransaction",value:function(e){return this._fail("VoidSigner cannot sign transactions","signTransaction")}},{key:"_signTypedData",value:function(e,t,r){return this._fail("VoidSigner cannot sign typed data","signTypedData")}},{key:"connect",value:function(e){return new r(this.address,e)}}]),r}(A),j=r(53),P=r(51),C=r(83),R=function(e,t,r,n){return new(r||(r=Promise))((function(a,i){function o(e){try{s(n.next(e))}catch(t){i(t)}}function c(e){try{s(n.throw(e))}catch(t){i(t)}}function s(e){var t;e.done?a(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(o,c)}s((n=n.apply(e,t||[])).next())}))},N=new y.Logger("contracts/5.3.0"),B={chainId:!0,data:!0,from:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,value:!0,type:!0,accessList:!0};function L(e,t){return R(this,void 0,void 0,p.a.mark((function r(){var n,a;return p.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,t;case 2:return n=r.sent,r.prev=3,r.abrupt("return",Object(j.getAddress)(n));case 7:r.prev=7,r.t0=r.catch(3);case 9:return e||N.throwError("a provider or signer is needed to resolve ENS names",y.Logger.errors.UNSUPPORTED_OPERATION,{operation:"resolveName"}),r.next=12,e.resolveName(n);case 12:return null==(a=r.sent)&&N.throwArgumentError("resolver or addr is not configured for ENS name","name",n),r.abrupt("return",a);case 15:case"end":return r.stop()}}),r,null,[[3,7]])})))}function I(e,t,r){return R(this,void 0,void 0,p.a.mark((function n(){return p.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:if(!Array.isArray(r)){n.next=4;break}return n.next=3,Promise.all(r.map((function(r,n){return I(e,Array.isArray(t)?t[n]:t[r.name],r)})));case 3:return n.abrupt("return",n.sent);case 4:if("address"!==r.type){n.next=8;break}return n.next=7,L(e,t);case 7:return n.abrupt("return",n.sent);case 8:if("tuple"!==r.type){n.next=12;break}return n.next=11,I(e,t,r.components);case 11:return n.abrupt("return",n.sent);case 12:if("array"!==r.baseType){n.next=18;break}if(Array.isArray(t)){n.next=15;break}return n.abrupt("return",Promise.reject(new Error("invalid value for array")));case 15:return n.next=17,Promise.all(t.map((function(t){return I(e,t,r.arrayChildren)})));case 17:return n.abrupt("return",n.sent);case 18:return n.abrupt("return",t);case 19:case"end":return n.stop()}}),n)})))}function F(e,t,r){return R(this,void 0,void 0,p.a.mark((function n(){var a,i,o,c,s,f,d,u,l,b,h=this;return p.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return a={},r.length===t.inputs.length+1&&"object"===typeof r[r.length-1]&&(a=Object(x.shallowCopy)(r.pop())),N.checkArgumentCount(r.length,t.inputs.length,"passed to contract"),e.signer?a.from?a.from=Object(x.resolveProperties)({override:L(e.signer,a.from),signer:e.signer.getAddress()}).then((function(e){return R(h,void 0,void 0,p.a.mark((function t(){return p.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return Object(j.getAddress)(e.signer)!==e.override&&N.throwError("Contract with a Signer cannot override from",y.Logger.errors.UNSUPPORTED_OPERATION,{operation:"overrides.from"}),t.abrupt("return",e.override);case 2:case"end":return t.stop()}}),t)})))})):a.from=e.signer.getAddress():a.from&&(a.from=L(e.provider,a.from)),n.next=6,Object(x.resolveProperties)({args:I(e.signer||e.provider,r,t.inputs),address:e.resolvedAddress,overrides:Object(x.resolveProperties)(a)||{}});case 6:if(i=n.sent,o=e.interface.encodeFunctionData(t,i.args),c={data:o,to:i.address},null!=(s=i.overrides).nonce&&(c.nonce=P.a.from(s.nonce).toNumber()),null!=s.gasLimit&&(c.gasLimit=P.a.from(s.gasLimit)),null!=s.gasPrice&&(c.gasPrice=P.a.from(s.gasPrice)),null!=s.from&&(c.from=s.from),null!=s.type&&(c.type=s.type),null!=s.accessList&&(c.accessList=Object(C.accessListify)(s.accessList)),null==c.gasLimit&&null!=t.gas){for(f=21e3,d=Object(g.arrayify)(o),u=0;u1)){var r=t[0];try{null==a[e]&&Object(x.defineReadOnly)(a,e,a[r])}catch(n){}null==a.functions[e]&&Object(x.defineReadOnly)(a.functions,e,a.functions[r]),null==a.callStatic[e]&&Object(x.defineReadOnly)(a.callStatic,e,a.callStatic[r]),null==a.populateTransaction[e]&&Object(x.defineReadOnly)(a.populateTransaction,e,a.populateTransaction[r]),null==a.estimateGas[e]&&Object(x.defineReadOnly)(a.estimateGas,e,a.estimateGas[r])}}))}return Object(b.a)(e,[{key:"deployed",value:function(){return this._deployed()}},{key:"_deployed",value:function(e){var t=this;return this._deployedPromise||(this.deployTransaction?this._deployedPromise=this.deployTransaction.wait().then((function(){return t})):this._deployedPromise=this.provider.getCode(this.address,e).then((function(e){return"0x"===e&&N.throwError("contract not deployed",y.Logger.errors.UNSUPPORTED_OPERATION,{contractAddress:t.address,operation:"getDeployed"}),t}))),this._deployedPromise}},{key:"fallback",value:function(e){var t=this;this.signer||N.throwError("sending a transactions require a signer",y.Logger.errors.UNSUPPORTED_OPERATION,{operation:"sendTransaction(fallback)"});var r=Object(x.shallowCopy)(e||{});return["from","to"].forEach((function(e){null!=r[e]&&N.throwError("cannot override "+e,y.Logger.errors.UNSUPPORTED_OPERATION,{operation:e})})),r.to=this.resolvedAddress,this.deployed().then((function(){return t.signer.sendTransaction(r)}))}},{key:"connect",value:function(e){"string"===typeof e&&(e=new T(e,this.provider));var t=new this.constructor(this.address,this.interface,e);return this.deployTransaction&&Object(x.defineReadOnly)(t,"deployTransaction",this.deployTransaction),t}},{key:"attach",value:function(e){return new this.constructor(e,this.interface,this.signer||this.provider)}},{key:"_normalizeRunningEvent",value:function(e){return this._runningEvents[e.tag]?this._runningEvents[e.tag]:e}},{key:"_getRunningEvent",value:function(e){if("string"===typeof e){if("error"===e)return this._normalizeRunningEvent(new q);if("event"===e)return this._normalizeRunningEvent(new H("event",null));if("*"===e)return this._normalizeRunningEvent(new V(this.address,this.interface));var t=this.interface.getEvent(e);return this._normalizeRunningEvent(new J(this.address,this.interface,t))}if(e.topics&&e.topics.length>0){try{var r=e.topics[0];if("string"!==typeof r)throw new Error("invalid topic");var n=this.interface.getEvent(r);return this._normalizeRunningEvent(new J(this.address,this.interface,n,e.topics))}catch(i){}var a={address:this.address,topics:e.topics};return this._normalizeRunningEvent(new H(z(a),a))}return this._normalizeRunningEvent(new V(this.address,this.interface))}},{key:"_checkRunningEvents",value:function(e){if(0===e.listenerCount()){delete this._runningEvents[e.tag];var t=this._wrappedEmits[e.tag];t&&e.filter&&(this.provider.off(e.filter,t),delete this._wrappedEmits[e.tag])}}},{key:"_wrapEvent",value:function(e,t,r){var n=this,a=Object(x.deepCopy)(t);return a.removeListener=function(){r&&(e.removeListener(r),n._checkRunningEvents(e))},a.getBlock=function(){return n.provider.getBlock(t.blockHash)},a.getTransaction=function(){return n.provider.getTransaction(t.transactionHash)},a.getTransactionReceipt=function(){return n.provider.getTransactionReceipt(t.transactionHash)},e.prepareEvent(a),a}},{key:"_addEventListener",value:function(e,t,r){var n=this;if(this.provider||N.throwError("events require a provider or a signer with a provider",y.Logger.errors.UNSUPPORTED_OPERATION,{operation:"once"}),e.addListener(t,r),this._runningEvents[e.tag]=e,!this._wrappedEmits[e.tag]){var a=function(r){var a=n._wrapEvent(e,r,t);if(null==a.decodeError)try{var i=e.getEmit(a);n.emit.apply(n,[e.filter].concat(Object(o.a)(i)))}catch(c){a.decodeError=c.error}null!=e.filter&&n.emit("event",a),null!=a.decodeError&&n.emit("error",a.decodeError,a)};this._wrappedEmits[e.tag]=a,null!=e.filter&&this.provider.on(e.filter,a)}}},{key:"queryFilter",value:function(e,t,r){var n=this,a=this._getRunningEvent(e),i=Object(x.shallowCopy)(a.filter);return"string"===typeof t&&Object(g.isHexString)(t,32)?(null!=r&&N.throwArgumentError("cannot specify toBlock with blockhash","toBlock",r),i.blockHash=t):(i.fromBlock=null!=t?t:0,i.toBlock=null!=r?r:"latest"),this.provider.getLogs(i).then((function(e){return e.map((function(e){return n._wrapEvent(a,e,null)}))}))}},{key:"on",value:function(e,t){return this._addEventListener(this._getRunningEvent(e),t,!1),this}},{key:"once",value:function(e,t){return this._addEventListener(this._getRunningEvent(e),t,!0),this}},{key:"emit",value:function(e){if(!this.provider)return!1;for(var t=this._getRunningEvent(e),r=arguments.length,n=new Array(r>1?r-1:0),a=1;a0;return this._checkRunningEvents(t),i}},{key:"listenerCount",value:function(e){var t=this;return this.provider?null==e?Object.keys(this._runningEvents).reduce((function(e,r){return e+t._runningEvents[r].listenerCount()}),0):this._getRunningEvent(e).listenerCount():0}},{key:"listeners",value:function(e){var t=this;if(!this.provider)return[];if(null==e){var r=function(){var e=[];for(var r in t._runningEvents)t._runningEvents[r].listeners().forEach((function(t){e.push(t)}));return{v:e}}();if("object"===typeof r)return r.v}return this._getRunningEvent(e).listeners()}},{key:"removeAllListeners",value:function(e){if(!this.provider)return this;if(null==e){for(var t in this._runningEvents){var r=this._runningEvents[t];r.removeAllListeners(),this._checkRunningEvents(r)}return this}var n=this._getRunningEvent(e);return n.removeAllListeners(),this._checkRunningEvents(n),this}},{key:"off",value:function(e,t){if(!this.provider)return this;var r=this._getRunningEvent(e);return r.removeListener(t),this._checkRunningEvents(r),this}},{key:"removeListener",value:function(e,t){return this.off(e,t)}}],[{key:"getContractAddress",value:function(e){return Object(j.getContractAddress)(e)}},{key:"getInterface",value:function(e){return v.b.isInterface(e)?e:new v.b(e)}},{key:"isIndexed",value:function(e){return v.a.isIndexed(e)}}]),e}(),X=function(e){Object(d.a)(r,e);var t=Object(u.a)(r);function r(){return Object(l.a)(this,r),t.apply(this,arguments)}return Object(b.a)(r)}(G),K=function(){function e(t,r,n){Object(l.a)(this,e);var a=null;"0x"!==(a="string"===typeof r?r:Object(g.isBytes)(r)?Object(g.hexlify)(r):r&&"string"===typeof r.object?r.object:"!").substring(0,2)&&(a="0x"+a),(!Object(g.isHexString)(a)||a.length%2)&&N.throwArgumentError("invalid bytecode","bytecode",r),n&&!A.isSigner(n)&&N.throwArgumentError("invalid signer","signer",n),Object(x.defineReadOnly)(this,"bytecode",a),Object(x.defineReadOnly)(this,"interface",Object(x.getStatic)(this instanceof e?this.constructor:void 0,"getInterface")(t)),Object(x.defineReadOnly)(this,"signer",n||null)}return Object(b.a)(e,[{key:"getDeployTransaction",value:function(){for(var e={},t=arguments.length,r=new Array(t),n=0;n=0&&e<=256&&!(e%1)?"1"+te.substring(0,e):Z.throwArgumentError("invalid decimal size","decimals",e)}function ne(e,t){null==t&&(t=0);var r=re(t),n=(e=P.a.from(e)).lt(Q);n&&(e=e.mul(Y));for(var a=e.mod(r).toString();a.length2&&Z.throwArgumentError("too many decimal points","value",e);var i=a[0],o=a[1];for(i||(i="0"),o||(o="0"),o.replace(/^([0-9]*?)(0*)$/,(function(e,t,r){return t})).length>r.length-1&&ee("fractional component exceeds decimals","underflow","parseFixed");o.length80&&Z.throwArgumentError("invalid fixed format (decimals too large)","format.decimals",a),new e($,r,n,a)}}]),e}(),oe=function(){function e(t,r,n,a){Object(l.a)(this,e),Z.checkNew(this instanceof e?this.constructor:void 0,e),t!==$&&Z.throwError("cannot use FixedNumber constructor; use FixedNumber.from",y.Logger.errors.UNSUPPORTED_OPERATION,{operation:"new FixedFormat"}),this.format=a,this._hex=r,this._value=n,this._isFixedNumber=!0,Object.freeze(this)}return Object(b.a)(e,[{key:"_checkFormat",value:function(e){this.format.name!==e.format.name&&Z.throwArgumentError("incompatible format; use fixedNumber.toFormat","other",e)}},{key:"addUnsafe",value:function(t){this._checkFormat(t);var r=ae(this._value,this.format.decimals),n=ae(t._value,t.format.decimals);return e.fromValue(r.add(n),this.format.decimals,this.format)}},{key:"subUnsafe",value:function(t){this._checkFormat(t);var r=ae(this._value,this.format.decimals),n=ae(t._value,t.format.decimals);return e.fromValue(r.sub(n),this.format.decimals,this.format)}},{key:"mulUnsafe",value:function(t){this._checkFormat(t);var r=ae(this._value,this.format.decimals),n=ae(t._value,t.format.decimals);return e.fromValue(r.mul(n).div(this.format._multiplier),this.format.decimals,this.format)}},{key:"divUnsafe",value:function(t){this._checkFormat(t);var r=ae(this._value,this.format.decimals),n=ae(t._value,t.format.decimals);return e.fromValue(r.mul(this.format._multiplier).div(n),this.format.decimals,this.format)}},{key:"floor",value:function(){var t=this.toString().split(".");1===t.length&&t.push("0");var r=e.from(t[0],this.format),n=!t[1].match(/^(0*)$/);return this.isNegative()&&n&&(r=r.subUnsafe(ce)),r}},{key:"ceiling",value:function(){var t=this.toString().split(".");1===t.length&&t.push("0");var r=e.from(t[0],this.format),n=!t[1].match(/^(0*)$/);return!this.isNegative()&&n&&(r=r.addUnsafe(ce)),r}},{key:"round",value:function(t){null==t&&(t=0);var r=this.toString().split(".");if(1===r.length&&r.push("0"),(t<0||t>80||t%1)&&Z.throwArgumentError("invalid decimal count","decimals",t),r[1].length<=t)return this;var n=e.from("1"+te.substring(0,t),this.format),a=se.toFormat(this.format);return this.mulUnsafe(n).addUnsafe(a).floor().divUnsafe(n)}},{key:"isZero",value:function(){return"0.0"===this._value||"0"===this._value}},{key:"isNegative",value:function(){return"-"===this._value[0]}},{key:"toString",value:function(){return this._value}},{key:"toHexString",value:function(e){if(null==e)return this._hex;e%8&&Z.throwArgumentError("invalid byte width","width",e);var t=P.a.from(this._hex).fromTwos(this.format.width).toTwos(e).toHexString();return Object(g.hexZeroPad)(t,e/8)}},{key:"toUnsafeFloat",value:function(){return parseFloat(this.toString())}},{key:"toFormat",value:function(t){return e.fromString(this._value,t)}}],[{key:"fromValue",value:function(t,r,n){return null!=n||null==r||Object(P.d)(r)||(n=r,r=null),null==r&&(r=0),null==n&&(n="fixed"),e.fromString(ne(t,r),ie.from(n))}},{key:"fromString",value:function(t,r){null==r&&(r="fixed");var n=ie.from(r),a=ae(t,n.decimals);!n.signed&&a.lt(Q)&&ee("unsigned value cannot be negative","overflow","value",t);var i=null;n.signed?i=a.toTwos(n.width).toHexString():(i=a.toHexString(),i=Object(g.hexZeroPad)(i,n.width/8));var o=ne(a,n.decimals);return new e($,i,o,n)}},{key:"fromBytes",value:function(t,r){null==r&&(r="fixed");var n=ie.from(r);if(Object(g.arrayify)(t).length>n.width/8)throw new Error("overflow");var a=P.a.from(t);n.signed&&(a=a.fromTwos(n.width));var i=a.toTwos((n.signed?0:1)+n.width).toHexString(),o=ne(a,n.decimals);return new e($,i,o,n)}},{key:"from",value:function(t,r){if("string"===typeof t)return e.fromString(t,r);if(Object(g.isBytes)(t))return e.fromBytes(t,r);try{return e.fromValue(t,0,r)}catch(n){if(n.code!==y.Logger.errors.INVALID_ARGUMENT)throw n}return Z.throwArgumentError("invalid FixedNumber value","value",t)}},{key:"isFixedNumber",value:function(e){return!(!e||!e._isFixedNumber)}}]),e}(),ce=oe.from(1),se=oe.from("0.5"),fe=r(179),de=r(157),ue=new y.Logger("networks/5.3.0");function le(e){var t=function(t,r){null==r&&(r={});var n=[];if(t.InfuraProvider)try{n.push(new t.InfuraProvider(e,r.infura))}catch(i){}if(t.EtherscanProvider)try{n.push(new t.EtherscanProvider(e,r.etherscan))}catch(i){}if(t.AlchemyProvider)try{n.push(new t.AlchemyProvider(e,r.alchemy))}catch(i){}if(t.CloudflareProvider)try{n.push(new t.CloudflareProvider(e))}catch(i){}if(0===n.length)return null;if(t.FallbackProvider){var a=1;return null!=r.quorum?a=r.quorum:"homestead"===e&&(a=2),new t.FallbackProvider(n,a)}return n[0]};return t.renetwork=function(e){return le(e)},t}function be(e,t){var r=function(r,n){return r.JsonRpcProvider?new r.JsonRpcProvider(e,t):null};return r.renetwork=function(t){return be(e,t)},r}var he={chainId:1,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"homestead",_defaultProvider:le("homestead")},pe={chainId:3,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"ropsten",_defaultProvider:le("ropsten")},me={chainId:63,name:"classicMordor",_defaultProvider:be("https://www.ethercluster.com/mordor","classicMordor")},ve={unspecified:{chainId:0,name:"unspecified"},homestead:he,mainnet:he,morden:{chainId:2,name:"morden"},ropsten:pe,testnet:pe,rinkeby:{chainId:4,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"rinkeby",_defaultProvider:le("rinkeby")},kovan:{chainId:42,name:"kovan",_defaultProvider:le("kovan")},goerli:{chainId:5,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"goerli",_defaultProvider:le("goerli")},classic:{chainId:61,name:"classic",_defaultProvider:be("https://www.ethercluster.com/etc","classic")},classicMorden:{chainId:62,name:"classicMorden"},classicMordor:me,classicTestnet:me,classicKotti:{chainId:6,name:"classicKotti",_defaultProvider:be("https://www.ethercluster.com/kotti","classicKotti")},xdai:{chainId:100,name:"xdai"},matic:{chainId:137,name:"matic"},bnb:{chainId:56,name:"bnb"},bnbt:{chainId:97,name:"bnbt"}};function ge(e){if(null==e)return null;if("number"===typeof e){for(var t in ve){var r=ve[t];if(r.chainId===e)return{name:r.name,chainId:r.chainId,ensAddress:r.ensAddress||null,_defaultProvider:r._defaultProvider||null}}return{chainId:e,name:"unknown"}}if("string"===typeof e){var n=ve[e];return null==n?null:{name:n.name,chainId:n.chainId,ensAddress:n.ensAddress,_defaultProvider:n._defaultProvider||null}}var a=ve[e.name];if(!a)return"number"!==typeof e.chainId&&ue.throwArgumentError("invalid network chainId","network",e),e;0!==e.chainId&&e.chainId!==a.chainId&&ue.throwArgumentError("network chainId mismatch","network",e);var i,o=e._defaultProvider||null;return null==o&&a._defaultProvider&&(o=(i=a._defaultProvider)&&"function"===typeof i.renetwork?a._defaultProvider.renetwork(e):a._defaultProvider),{name:e.name,chainId:a.chainId,ensAddress:e.ensAddress||a.ensAddress||null,_defaultProvider:o}}var xe=r(182),ye=r(361),we=r(326),ke=r(180),_e=r(64),Me=r(75),Se=r(192),Ee=r.n(Se),Oe=r(481),Ae=new y.Logger("providers/5.3.0"),Te=function(){function e(){Object(l.a)(this,e),Ae.checkNew(this instanceof e?this.constructor:void 0,e),this.formats=this.getDefaultFormats()}return Object(b.a)(e,[{key:"getDefaultFormats",value:function(){var t=this,r={},n=this.address.bind(this),a=this.bigNumber.bind(this),i=this.blockTag.bind(this),o=this.data.bind(this),c=this.hash.bind(this),s=this.hex.bind(this),f=this.number.bind(this);return r.transaction={hash:c,type:e.allowNull(f,null),accessList:e.allowNull(this.accessList.bind(this),null),blockHash:e.allowNull(c,null),blockNumber:e.allowNull(f,null),transactionIndex:e.allowNull(f,null),confirmations:e.allowNull(f,null),from:n,gasPrice:a,gasLimit:a,to:e.allowNull(n,null),value:a,nonce:f,data:o,r:e.allowNull(this.uint256),s:e.allowNull(this.uint256),v:e.allowNull(f),creates:e.allowNull(n,null),raw:e.allowNull(o)},r.transactionRequest={from:e.allowNull(n),nonce:e.allowNull(f),gasLimit:e.allowNull(a),gasPrice:e.allowNull(a),to:e.allowNull(n),value:e.allowNull(a),data:e.allowNull((function(e){return t.data(e,!0)})),type:e.allowNull(f),accessList:e.allowNull(this.accessList.bind(this),null)},r.receiptLog={transactionIndex:f,blockNumber:f,transactionHash:c,address:n,topics:e.arrayOf(c),data:o,logIndex:f,blockHash:c},r.receipt={to:e.allowNull(this.address,null),from:e.allowNull(this.address,null),contractAddress:e.allowNull(n,null),transactionIndex:f,root:e.allowNull(s),gasUsed:a,logsBloom:e.allowNull(o),blockHash:c,transactionHash:c,logs:e.arrayOf(this.receiptLog.bind(this)),blockNumber:f,confirmations:e.allowNull(f,null),cumulativeGasUsed:a,status:e.allowNull(f)},r.block={hash:c,parentHash:c,number:f,timestamp:f,nonce:e.allowNull(s),difficulty:this.difficulty.bind(this),gasLimit:a,gasUsed:a,miner:n,extraData:o,transactions:e.allowNull(e.arrayOf(c))},r.blockWithTransactions=Object(x.shallowCopy)(r.block),r.blockWithTransactions.transactions=e.allowNull(e.arrayOf(this.transactionResponse.bind(this))),r.filter={fromBlock:e.allowNull(i,void 0),toBlock:e.allowNull(i,void 0),blockHash:e.allowNull(c,void 0),address:e.allowNull(n,void 0),topics:e.allowNull(this.topics.bind(this),void 0)},r.filterLog={blockNumber:e.allowNull(f),blockHash:e.allowNull(c),transactionIndex:f,removed:e.allowNull(this.boolean.bind(this)),address:n,data:e.allowFalsish(o,"0x"),topics:e.arrayOf(c),transactionHash:c,logIndex:f},r}},{key:"accessList",value:function(e){return Object(C.accessListify)(e||[])}},{key:"number",value:function(e){return"0x"===e?0:P.a.from(e).toNumber()}},{key:"bigNumber",value:function(e){return P.a.from(e)}},{key:"boolean",value:function(e){if("boolean"===typeof e)return e;if("string"===typeof e){if("true"===(e=e.toLowerCase()))return!0;if("false"===e)return!1}throw new Error("invalid boolean - "+e)}},{key:"hex",value:function(e,t){return"string"===typeof e&&(t||"0x"===e.substring(0,2)||(e="0x"+e),Object(g.isHexString)(e))?e.toLowerCase():Ae.throwArgumentError("invalid hash","value",e)}},{key:"data",value:function(e,t){var r=this.hex(e,t);if(r.length%2!==0)throw new Error("invalid data; odd-length - "+e);return r}},{key:"address",value:function(e){return Object(j.getAddress)(e)}},{key:"callAddress",value:function(e){if(!Object(g.isHexString)(e,32))return null;var t=Object(j.getAddress)(Object(g.hexDataSlice)(e,12));return t===Oe.a?null:t}},{key:"contractAddress",value:function(e){return Object(j.getContractAddress)(e)}},{key:"blockTag",value:function(e){if(null==e)return"latest";if("earliest"===e)return"0x0";if("latest"===e||"pending"===e)return e;if("number"===typeof e||Object(g.isHexString)(e))return Object(g.hexValue)(e);throw new Error("invalid blockTag")}},{key:"hash",value:function(e,t){var r=this.hex(e,t);return 32!==Object(g.hexDataLength)(r)?Ae.throwArgumentError("invalid hash","value",e):r}},{key:"difficulty",value:function(e){if(null==e)return null;var t=P.a.from(e);try{return t.toNumber()}catch(r){}return null}},{key:"uint256",value:function(e){if(!Object(g.isHexString)(e))throw new Error("invalid uint256");return Object(g.hexZeroPad)(e,32)}},{key:"_block",value:function(t,r){return null!=t.author&&null==t.miner&&(t.miner=t.author),e.check(r,t)}},{key:"block",value:function(e){return this._block(e,this.formats.block)}},{key:"blockWithTransactions",value:function(e){return this._block(e,this.formats.blockWithTransactions)}},{key:"transactionRequest",value:function(t){return e.check(this.formats.transactionRequest,t)}},{key:"transactionResponse",value:function(t){null!=t.gas&&null==t.gasLimit&&(t.gasLimit=t.gas),t.to&&P.a.from(t.to).isZero()&&(t.to="0x0000000000000000000000000000000000000000"),null!=t.input&&null==t.data&&(t.data=t.input),null==t.to&&null==t.creates&&(t.creates=this.contractAddress(t)),1===t.type&&null==t.accessList&&(t.accessList=[]);var r=e.check(this.formats.transaction,t);if(null!=t.chainId){var n=t.chainId;Object(g.isHexString)(n)&&(n=P.a.from(n).toNumber()),r.chainId=n}else{var a=t.networkId;null==a&&null==r.v&&(a=t.chainId),Object(g.isHexString)(a)&&(a=P.a.from(a).toNumber()),"number"!==typeof a&&null!=r.v&&((a=(r.v-35)/2)<0&&(a=0),a=parseInt(a)),"number"!==typeof a&&(a=0),r.chainId=a}return r.blockHash&&"x"===r.blockHash.replace(/0/g,"")&&(r.blockHash=null),r}},{key:"transaction",value:function(e){return Object(C.parse)(e)}},{key:"receiptLog",value:function(t){return e.check(this.formats.receiptLog,t)}},{key:"receipt",value:function(t){var r=e.check(this.formats.receipt,t);if(null!=r.root)if(r.root.length<=4){var n=P.a.from(r.root).toNumber();0===n||1===n?(null!=r.status&&r.status!==n&&Ae.throwArgumentError("alt-root-status/status mismatch","value",{root:r.root,status:r.status}),r.status=n,delete r.root):Ae.throwArgumentError("invalid alt-root-status","value.root",r.root)}else 66!==r.root.length&&Ae.throwArgumentError("invalid root hash","value.root",r.root);return null!=r.status&&(r.byzantium=!0),r}},{key:"topics",value:function(e){var t=this;return Array.isArray(e)?e.map((function(e){return t.topics(e)})):null!=e?this.hash(e,!0):null}},{key:"filter",value:function(t){return e.check(this.formats.filter,t)}},{key:"filterLog",value:function(t){return e.check(this.formats.filterLog,t)}}],[{key:"check",value:function(e,t){var r={};for(var n in e)try{var a=e[n](t[n]);void 0!==a&&(r[n]=a)}catch(i){throw i.checkKey=n,i.checkValue=t[n],i}return r}},{key:"allowNull",value:function(e,t){return function(r){return null==r?t:e(r)}}},{key:"allowFalsish",value:function(e,t){return function(r){return r?e(r):t}}},{key:"arrayOf",value:function(e){return function(t){if(!Array.isArray(t))throw new Error("not an array");var r=[];return t.forEach((function(t){r.push(e(t))})),r}}}]),e}();function je(e){return e&&"function"===typeof e.isCommunityResource}function Pe(e){return je(e)&&e.isCommunityResource()}var Ce=!1;function Re(){Ce||(Ce=!0,console.log("========= NOTICE ========="),console.log("Request-Rate Exceeded (this message will not be repeated)"),console.log(""),console.log("The default API keys for each service are provided as a highly-throttled,"),console.log("community resource for low-traffic projects and early prototyping."),console.log(""),console.log("While your application will continue to function, we highly recommended"),console.log("signing up for your own API keys to improve performance, increase your"),console.log("request rate/limit and enable other perks, such as metrics and advanced APIs."),console.log(""),console.log("For more details: https://docs.ethers.io/api-keys/"),console.log("=========================="))}var Ne=function(e,t,r,n){return new(r||(r=Promise))((function(a,i){function o(e){try{s(n.next(e))}catch(t){i(t)}}function c(e){try{s(n.throw(e))}catch(t){i(t)}}function s(e){var t;e.done?a(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(o,c)}s((n=n.apply(e,t||[])).next())}))},Be=new y.Logger("providers/5.3.0");function Le(e){return null==e?"null":(32!==Object(g.hexDataLength)(e)&&Be.throwArgumentError("invalid topic","topic",e),e.toLowerCase())}function Ie(e){for(e=e.slice();e.length>0&&null==e[e.length-1];)e.pop();return e.map((function(e){if(Array.isArray(e)){var t={};e.forEach((function(e){t[Le(e)]=!0}));var r=Object.keys(t);return r.sort(),r.join("|")}return Le(e)})).join("&")}function Fe(e){if("string"===typeof e){if(e=e.toLowerCase(),32===Object(g.hexDataLength)(e))return"tx:"+e;if(-1===e.indexOf(":"))return e}else{if(Array.isArray(e))return"filter:*:"+Ie(e);if(k.isForkEvent(e))throw Be.warn("not implemented"),new Error("not implemented");if(e&&"object"===typeof e)return"filter:"+(e.address||"*")+":"+Ie(e.topics||[])}throw new Error("invalid event - "+e)}function De(){return(new Date).getTime()}function Ue(e){return new Promise((function(t){setTimeout(t,e)}))}var ze=["block","network","pending","poll"],He=function(){function e(t,r,n){Object(l.a)(this,e),Object(x.defineReadOnly)(this,"tag",t),Object(x.defineReadOnly)(this,"listener",r),Object(x.defineReadOnly)(this,"once",n)}return Object(b.a)(e,[{key:"event",get:function(){switch(this.type){case"tx":return this.hash;case"filter":return this.filter}return this.tag}},{key:"type",get:function(){return this.tag.split(":")[0]}},{key:"hash",get:function(){var e=this.tag.split(":");return"tx"!==e[0]?null:e[1]}},{key:"filter",get:function(){var e=this.tag.split(":");if("filter"!==e[0])return null;var t,r=e[1],n=""===(t=e[2])?[]:t.split(/&/g).map((function(e){if(""===e)return[];var t=e.split("|").map((function(e){return"null"===e?null:e}));return 1===t.length?t[0]:t})),a={};return n.length>0&&(a.topics=n),r&&"*"!==r&&(a.address=r),a}},{key:"pollable",value:function(){return this.tag.indexOf(":")>=0||ze.indexOf(this.tag)>=0}}]),e}(),qe={0:{symbol:"btc",p2pkh:0,p2sh:5,prefix:"bc"},2:{symbol:"ltc",p2pkh:48,p2sh:50,prefix:"ltc"},3:{symbol:"doge",p2pkh:30,p2sh:22},60:{symbol:"eth",ilk:"eth"},61:{symbol:"etc",ilk:"eth"},700:{symbol:"xdai",ilk:"eth"}};function Je(e){return Object(g.hexZeroPad)(P.a.from(e).toHexString(),32)}function Ve(e){return xe.Base58.encode(Object(g.concat)([e,Object(g.hexDataSlice)(Object(ke.c)(Object(ke.c)(e)),0,4)]))}var Ge=function(){function e(t,r,n){Object(l.a)(this,e),Object(x.defineReadOnly)(this,"provider",t),Object(x.defineReadOnly)(this,"name",n),Object(x.defineReadOnly)(this,"address",t.formatter.address(r))}return Object(b.a)(e,[{key:"_fetchBytes",value:function(e,t){return Ne(this,void 0,void 0,p.a.mark((function r(){var n,a,i,o;return p.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return n={to:this.address,data:Object(g.hexConcat)([e,Object(we.b)(this.name),t||"0x"])},r.next=3,this.provider.call(n);case 3:if("0x"!==(a=r.sent)){r.next=6;break}return r.abrupt("return",null);case 6:return i=P.a.from(Object(g.hexDataSlice)(a,0,32)).toNumber(),o=P.a.from(Object(g.hexDataSlice)(a,i,i+32)).toNumber(),r.abrupt("return",Object(g.hexDataSlice)(a,i+32,i+32+o));case 9:case"end":return r.stop()}}),r,this)})))}},{key:"_getAddress",value:function(e,t){var r=qe[String(e)];if(null==r&&Be.throwError("unsupported coin type: ".concat(e),y.Logger.errors.UNSUPPORTED_OPERATION,{operation:"getAddress(".concat(e,")")}),"eth"===r.ilk)return this.provider.formatter.address(t);var n=Object(g.arrayify)(t);if(null!=r.p2pkh){var a=t.match(/^0x76a9([0-9a-f][0-9a-f])([0-9a-f]*)88ac$/);if(a){var i=parseInt(a[1],16);if(a[2].length===2*i&&i>=1&&i<=75)return Ve(Object(g.concat)([[r.p2pkh],"0x"+a[2]]))}}if(null!=r.p2sh){var o=t.match(/^0xa9([0-9a-f][0-9a-f])([0-9a-f]*)87$/);if(o){var c=parseInt(o[1],16);if(o[2].length===2*c&&c>=1&&c<=75)return Ve(Object(g.concat)([[r.p2sh],"0x"+o[2]]))}}if(null!=r.prefix){var s=n[1],f=n[0];if(0===f?20!==s&&32!==s&&(f=-1):f=-1,f>=0&&n.length===2+s&&s>=1&&s<=75){var d=Ee.a.toWords(n.slice(2));return d.unshift(f),Ee.a.encode(r.prefix,d)}}return null}},{key:"getAddress",value:function(e){return Ne(this,void 0,void 0,p.a.mark((function t(){var r,n,a,i;return p.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(null==e&&(e=60),60!==e){t.next=9;break}return r={to:this.address,data:"0x3b3b57de"+Object(we.b)(this.name).substring(2)},t.next=5,this.provider.call(r);case 5:if("0x"!==(n=t.sent)&&n!==ye.a){t.next=8;break}return t.abrupt("return",null);case 8:return t.abrupt("return",this.provider.formatter.callAddress(n));case 9:return t.next=11,this._fetchBytes("0xf1cb7e06",Je(e));case 11:if(null!=(a=t.sent)&&"0x"!==a){t.next=14;break}return t.abrupt("return",null);case 14:return null==(i=this._getAddress(e,a))&&Be.throwError("invalid or unsupported coin data",y.Logger.errors.UNSUPPORTED_OPERATION,{operation:"getAddress(".concat(e,")"),coinType:e,data:a}),t.abrupt("return",i);case 17:case"end":return t.stop()}}),t,this)})))}},{key:"getContentHash",value:function(){return Ne(this,void 0,void 0,p.a.mark((function e(){var t,r,n,a;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._fetchBytes("0xbc1c58d1");case 2:if(null!=(t=e.sent)&&"0x"!==t){e.next=5;break}return e.abrupt("return",null);case 5:if(!(r=t.match(/^0xe3010170(([0-9a-f][0-9a-f])([0-9a-f][0-9a-f])([0-9a-f]*))$/))){e.next=10;break}if(n=parseInt(r[3],16),r[4].length!==2*n){e.next=10;break}return e.abrupt("return","ipfs://"+xe.Base58.encode("0x"+r[1]));case 10:if(!(a=t.match(/^0xe40101fa011b20([0-9a-f]*)$/))){e.next=14;break}if(64!==a[1].length){e.next=14;break}return e.abrupt("return","bzz://"+a[1]);case 14:return e.abrupt("return",Be.throwError("invalid or unsupported content hash data",y.Logger.errors.UNSUPPORTED_OPERATION,{operation:"getContentHash()",data:t}));case 15:case"end":return e.stop()}}),e,this)})))}},{key:"getText",value:function(e){return Ne(this,void 0,void 0,p.a.mark((function t(){var r,n;return p.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=Object(_e.f)(e),(r=Object(g.concat)([Je(64),Je(r.length),r])).length%32!==0&&(r=Object(g.concat)([r,Object(g.hexZeroPad)("0x",32-e.length%32)])),t.next=5,this._fetchBytes("0x59d1d43c",Object(g.hexlify)(r));case 5:if(null!=(n=t.sent)&&"0x"!==n){t.next=8;break}return t.abrupt("return",null);case 8:return t.abrupt("return",Object(_e.h)(n));case 9:case"end":return t.stop()}}),t,this)})))}}]),e}(),Xe=null,Ke=1,We=function(e){Object(d.a)(r,e);var t=Object(u.a)(r);function r(e){var n;if(Object(l.a)(this,r),Be.checkNew(this instanceof r?this.constructor:void 0,_),(n=t.call(this))._events=[],n._emitted={block:-2},n.formatter=(this instanceof r?this.constructor:void 0).getFormatter(),Object(x.defineReadOnly)(Object(c.a)(n),"anyNetwork","any"===e),n.anyNetwork&&(e=n.detectNetwork()),e instanceof Promise)n._networkPromise=e,e.catch((function(e){})),n._ready().catch((function(e){}));else{var a=Object(x.getStatic)(this instanceof r?this.constructor:void 0,"getNetwork")(e);a?(Object(x.defineReadOnly)(Object(c.a)(n),"_network",a),n.emit("network",a,null)):Be.throwArgumentError("invalid network","network",e)}return n._maxInternalBlockNumber=-1024,n._lastBlockNumber=-2,n._pollingInterval=4e3,n._fastQueryDate=0,n}return Object(b.a)(r,[{key:"_ready",value:function(){return Ne(this,void 0,void 0,p.a.mark((function e(){var t;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(null!=this._network){e.next=17;break}if(t=null,!this._networkPromise){e.next=11;break}return e.prev=3,e.next=6,this._networkPromise;case 6:t=e.sent,e.next=11;break;case 9:e.prev=9,e.t0=e.catch(3);case 11:if(null!=t){e.next=15;break}return e.next=14,this.detectNetwork();case 14:t=e.sent;case 15:t||Be.throwError("no network detected",y.Logger.errors.UNKNOWN_ERROR,{}),null==this._network&&(this.anyNetwork?this._network=t:Object(x.defineReadOnly)(this,"_network",t),this.emit("network",t,null));case 17:return e.abrupt("return",this._network);case 18:case"end":return e.stop()}}),e,this,[[3,9]])})))}},{key:"ready",get:function(){var e=this;return Object(Me.poll)((function(){return e._ready().then((function(e){return e}),(function(e){if(e.code!==y.Logger.errors.NETWORK_ERROR||"noNetwork"!==e.event)throw e}))}))}},{key:"_getInternalBlockNumber",value:function(e){return Ne(this,void 0,void 0,p.a.mark((function t(){var r,n,a,i,o=this;return p.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this._ready();case 2:if(!(e>0)){t.next=20;break}case 3:if(!this._internalBlockNumber){t.next=20;break}return r=this._internalBlockNumber,t.prev=5,t.next=8,r;case 8:if(n=t.sent,!(De()-n.respTime<=e)){t.next=11;break}return t.abrupt("return",n.blockNumber);case 11:return t.abrupt("break",20);case 14:if(t.prev=14,t.t0=t.catch(5),this._internalBlockNumber!==r){t.next=18;break}return t.abrupt("break",20);case 18:t.next=3;break;case 20:return a=De(),i=Object(x.resolveProperties)({blockNumber:this.perform("getBlockNumber",{}),networkError:this.getNetwork().then((function(e){return null}),(function(e){return e}))}).then((function(e){var t=e.blockNumber,r=e.networkError;if(r)throw o._internalBlockNumber===i&&(o._internalBlockNumber=null),r;var n=De();return(t=P.a.from(t).toNumber())1e3)Be.warn("network block skew detected; skipping block events (emitted=".concat(this._emitted.block," blockNumber").concat(n,")")),this.emit("error",Be.makeError("network block skew detected",y.Logger.errors.NETWORK_ERROR,{blockNumber:n,event:"blockSkew",previousBlockNumber:this._emitted.block})),this.emit("block",n);else for(a=this._emitted.block+1;a<=n;a++)this.emit("block",a);return this._emitted.block!==n&&(this._emitted.block=n,Object.keys(this._emitted).forEach((function(e){if("block"!==e){var t=i._emitted[e];"pending"!==t&&n-t>12&&delete i._emitted[e]}}))),-2===this._lastBlockNumber&&(this._lastBlockNumber=n-1),this._events.forEach((function(e){switch(e.type){case"tx":var t=e.hash,a=i.getTransactionReceipt(t).then((function(e){return e&&null!=e.blockNumber?(i._emitted["t:"+t]=e.blockNumber,i.emit(t,e),null):null})).catch((function(e){i.emit("error",e)}));r.push(a);break;case"filter":var o=e.filter;o.fromBlock=i._lastBlockNumber+1,o.toBlock=n;var c=i.getLogs(o).then((function(e){0!==e.length&&e.forEach((function(e){i._emitted["b:"+e.blockHash]=e.blockNumber,i._emitted["t:"+e.transactionHash]=e.blockNumber,i.emit(o,e)}))})).catch((function(e){i.emit("error",e)}));r.push(c)}})),this._lastBlockNumber=n,Promise.all(r).then((function(){i.emit("didPoll",t)})).catch((function(e){i.emit("error",e)})),e.abrupt("return");case 26:case"end":return e.stop()}}),e,this,[[3,9]])})))}},{key:"resetEventsBlock",value:function(e){this._lastBlockNumber=e-1,this.polling&&this.poll()}},{key:"network",get:function(){return this._network}},{key:"detectNetwork",value:function(){return Ne(this,void 0,void 0,p.a.mark((function e(){return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",Be.throwError("provider does not support network detection",y.Logger.errors.UNSUPPORTED_OPERATION,{operation:"provider.detectNetwork"}));case 1:case"end":return e.stop()}}),e)})))}},{key:"getNetwork",value:function(){return Ne(this,void 0,void 0,p.a.mark((function e(){var t,r,n;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._ready();case 2:return t=e.sent,e.next=5,this.detectNetwork();case 5:if(r=e.sent,t.chainId===r.chainId){e.next=23;break}if(!this.anyNetwork){e.next=20;break}return this._network=r,this._lastBlockNumber=-2,this._fastBlockNumber=null,this._fastBlockNumberPromise=null,this._fastQueryDate=0,this._emitted.block=-2,this._maxInternalBlockNumber=-1024,this._internalBlockNumber=null,this.emit("network",r,t),e.next=19,Ue(0);case 19:return e.abrupt("return",this._network);case 20:throw n=Be.makeError("underlying network changed",y.Logger.errors.NETWORK_ERROR,{event:"changed",network:t,detectedNetwork:r}),this.emit("error",n),n;case 23:return e.abrupt("return",t);case 24:case"end":return e.stop()}}),e,this)})))}},{key:"blockNumber",get:function(){var e=this;return this._getInternalBlockNumber(100+this.pollingInterval/2).then((function(t){e._setFastBlockNumber(t)}),(function(e){})),null!=this._fastBlockNumber?this._fastBlockNumber:-1}},{key:"polling",get:function(){return null!=this._poller},set:function(e){var t=this;e&&!this._poller?(this._poller=setInterval((function(){t.poll()}),this.pollingInterval),this._bootstrapPoll||(this._bootstrapPoll=setTimeout((function(){t.poll(),t._bootstrapPoll=setTimeout((function(){t._poller||t.poll(),t._bootstrapPoll=null}),t.pollingInterval)}),0))):!e&&this._poller&&(clearInterval(this._poller),this._poller=null)}},{key:"pollingInterval",get:function(){return this._pollingInterval},set:function(e){var t=this;if("number"!==typeof e||e<=0||parseInt(String(e))!=e)throw new Error("invalid polling interval");this._pollingInterval=e,this._poller&&(clearInterval(this._poller),this._poller=setInterval((function(){t.poll()}),this._pollingInterval))}},{key:"_getFastBlockNumber",value:function(){var e=this,t=De();return t-this._fastQueryDate>2*this._pollingInterval&&(this._fastQueryDate=t,this._fastBlockNumberPromise=this.getBlockNumber().then((function(t){return(null==e._fastBlockNumber||t>e._fastBlockNumber)&&(e._fastBlockNumber=t),e._fastBlockNumber}))),this._fastBlockNumberPromise}},{key:"_setFastBlockNumber",value:function(e){null!=this._fastBlockNumber&&ethis._fastBlockNumber)&&(this._fastBlockNumber=e,this._fastBlockNumberPromise=Promise.resolve(e)))}},{key:"waitForTransaction",value:function(e,t,r){return Ne(this,void 0,void 0,p.a.mark((function n(){return p.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.abrupt("return",this._waitForTransaction(e,null==t?1:t,r||0,null));case 1:case"end":return n.stop()}}),n,this)})))}},{key:"_waitForTransaction",value:function(e,t,r,n){return Ne(this,void 0,void 0,p.a.mark((function a(){var i,o=this;return p.a.wrap((function(a){for(;;)switch(a.prev=a.next){case 0:return a.next=2,this.getTransactionReceipt(e);case 2:if(!(((i=a.sent)?i.confirmations:0)>=t)){a.next=5;break}return a.abrupt("return",i);case 5:return a.abrupt("return",new Promise((function(a,i){var c=[],s=!1,f=function(){return!!s||(s=!0,c.forEach((function(e){e()})),!1)},d=function(e){e.confirmations0){var h=setTimeout((function(){f()||i(Be.makeError("timeout exceeded",y.Logger.errors.TIMEOUT,{timeout:r}))}),r);h.unref&&h.unref(),c.push((function(){clearTimeout(h)}))}})));case 6:case"end":return a.stop()}}),a,this)})))}},{key:"getBlockNumber",value:function(){return Ne(this,void 0,void 0,p.a.mark((function e(){return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",this._getInternalBlockNumber(0));case 1:case"end":return e.stop()}}),e,this)})))}},{key:"getGasPrice",value:function(){return Ne(this,void 0,void 0,p.a.mark((function e(){var t;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.getNetwork();case 2:return e.next=4,this.perform("getGasPrice",{});case 4:return t=e.sent,e.prev=5,e.abrupt("return",P.a.from(t));case 9:return e.prev=9,e.t0=e.catch(5),e.abrupt("return",Be.throwError("bad result from backend",y.Logger.errors.SERVER_ERROR,{method:"getGasPrice",result:t,error:e.t0}));case 12:case"end":return e.stop()}}),e,this,[[5,9]])})))}},{key:"getBalance",value:function(e,t){return Ne(this,void 0,void 0,p.a.mark((function r(){var n,a;return p.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,this.getNetwork();case 2:return r.next=4,Object(x.resolveProperties)({address:this._getAddress(e),blockTag:this._getBlockTag(t)});case 4:return n=r.sent,r.next=7,this.perform("getBalance",n);case 7:return a=r.sent,r.prev=8,r.abrupt("return",P.a.from(a));case 12:return r.prev=12,r.t0=r.catch(8),r.abrupt("return",Be.throwError("bad result from backend",y.Logger.errors.SERVER_ERROR,{method:"getBalance",params:n,result:a,error:r.t0}));case 15:case"end":return r.stop()}}),r,this,[[8,12]])})))}},{key:"getTransactionCount",value:function(e,t){return Ne(this,void 0,void 0,p.a.mark((function r(){var n,a;return p.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,this.getNetwork();case 2:return r.next=4,Object(x.resolveProperties)({address:this._getAddress(e),blockTag:this._getBlockTag(t)});case 4:return n=r.sent,r.next=7,this.perform("getTransactionCount",n);case 7:return a=r.sent,r.prev=8,r.abrupt("return",P.a.from(a).toNumber());case 12:return r.prev=12,r.t0=r.catch(8),r.abrupt("return",Be.throwError("bad result from backend",y.Logger.errors.SERVER_ERROR,{method:"getTransactionCount",params:n,result:a,error:r.t0}));case 15:case"end":return r.stop()}}),r,this,[[8,12]])})))}},{key:"getCode",value:function(e,t){return Ne(this,void 0,void 0,p.a.mark((function r(){var n,a;return p.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,this.getNetwork();case 2:return r.next=4,Object(x.resolveProperties)({address:this._getAddress(e),blockTag:this._getBlockTag(t)});case 4:return n=r.sent,r.next=7,this.perform("getCode",n);case 7:return a=r.sent,r.prev=8,r.abrupt("return",Object(g.hexlify)(a));case 12:return r.prev=12,r.t0=r.catch(8),r.abrupt("return",Be.throwError("bad result from backend",y.Logger.errors.SERVER_ERROR,{method:"getCode",params:n,result:a,error:r.t0}));case 15:case"end":return r.stop()}}),r,this,[[8,12]])})))}},{key:"getStorageAt",value:function(e,t,r){return Ne(this,void 0,void 0,p.a.mark((function n(){var a,i;return p.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,this.getNetwork();case 2:return n.next=4,Object(x.resolveProperties)({address:this._getAddress(e),blockTag:this._getBlockTag(r),position:Promise.resolve(t).then((function(e){return Object(g.hexValue)(e)}))});case 4:return a=n.sent,n.next=7,this.perform("getStorageAt",a);case 7:return i=n.sent,n.prev=8,n.abrupt("return",Object(g.hexlify)(i));case 12:return n.prev=12,n.t0=n.catch(8),n.abrupt("return",Be.throwError("bad result from backend",y.Logger.errors.SERVER_ERROR,{method:"getStorageAt",params:a,result:i,error:n.t0}));case 15:case"end":return n.stop()}}),n,this,[[8,12]])})))}},{key:"_wrapTransaction",value:function(e,t,r){var n=this;if(null!=t&&32!==Object(g.hexDataLength)(t))throw new Error("invalid response - sendTransaction");var a=e;return null!=t&&e.hash!==t&&Be.throwError("Transaction hash mismatch from Provider.sendTransaction.",y.Logger.errors.UNKNOWN_ERROR,{expectedHash:e.hash,returnedHash:t}),a.wait=function(t,a){return Ne(n,void 0,void 0,p.a.mark((function n(){var i,o;return p.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return null==t&&(t=1),null==a&&(a=0),i=void 0,0!==t&&null!=r&&(i={data:e.data,from:e.from,nonce:e.nonce,to:e.to,value:e.value,startBlock:r}),n.next=6,this._waitForTransaction(e.hash,t,a,i);case 6:if(null!=(o=n.sent)||0!==t){n.next=9;break}return n.abrupt("return",null);case 9:return this._emitted["t:"+e.hash]=o.blockNumber,0===o.status&&Be.throwError("transaction failed",y.Logger.errors.CALL_EXCEPTION,{transactionHash:e.hash,transaction:e,receipt:o}),n.abrupt("return",o);case 12:case"end":return n.stop()}}),n,this)})))},a}},{key:"sendTransaction",value:function(e){return Ne(this,void 0,void 0,p.a.mark((function t(){var r,n,a,i;return p.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.getNetwork();case 2:return t.next=4,Promise.resolve(e).then((function(e){return Object(g.hexlify)(e)}));case 4:return r=t.sent,n=this.formatter.transaction(e),t.next=8,this._getInternalBlockNumber(100+2*this.pollingInterval);case 8:return a=t.sent,t.prev=9,t.next=12,this.perform("sendTransaction",{signedTransaction:r});case 12:return i=t.sent,t.abrupt("return",this._wrapTransaction(n,i,a));case 16:throw t.prev=16,t.t0=t.catch(9),t.t0.transaction=n,t.t0.transactionHash=n.hash,t.t0;case 21:case"end":return t.stop()}}),t,this,[[9,16]])})))}},{key:"_getTransactionRequest",value:function(e){return Ne(this,void 0,void 0,p.a.mark((function t(){var r,n,a=this;return p.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,e;case 2:return r=t.sent,n={},["from","to"].forEach((function(e){null!=r[e]&&(n[e]=Promise.resolve(r[e]).then((function(e){return e?a._getAddress(e):null})))})),["gasLimit","gasPrice","value"].forEach((function(e){null!=r[e]&&(n[e]=Promise.resolve(r[e]).then((function(e){return e?P.a.from(e):null})))})),["type"].forEach((function(e){null!=r[e]&&(n[e]=Promise.resolve(r[e]).then((function(e){return null!=e?e:null})))})),r.accessList&&(n.accessList=this.formatter.accessList(r.accessList)),["data"].forEach((function(e){null!=r[e]&&(n[e]=Promise.resolve(r[e]).then((function(e){return e?Object(g.hexlify)(e):null})))})),t.t0=this.formatter,t.next=12,Object(x.resolveProperties)(n);case 12:return t.t1=t.sent,t.abrupt("return",t.t0.transactionRequest.call(t.t0,t.t1));case 14:case"end":return t.stop()}}),t,this)})))}},{key:"_getFilter",value:function(e){return Ne(this,void 0,void 0,p.a.mark((function t(){var r,n=this;return p.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,e;case 2:return e=t.sent,r={},null!=e.address&&(r.address=this._getAddress(e.address)),["blockHash","topics"].forEach((function(t){null!=e[t]&&(r[t]=e[t])})),["fromBlock","toBlock"].forEach((function(t){null!=e[t]&&(r[t]=n._getBlockTag(e[t]))})),t.t0=this.formatter,t.next=10,Object(x.resolveProperties)(r);case 10:return t.t1=t.sent,t.abrupt("return",t.t0.filter.call(t.t0,t.t1));case 12:case"end":return t.stop()}}),t,this)})))}},{key:"call",value:function(e,t){return Ne(this,void 0,void 0,p.a.mark((function r(){var n,a;return p.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,this.getNetwork();case 2:return r.next=4,Object(x.resolveProperties)({transaction:this._getTransactionRequest(e),blockTag:this._getBlockTag(t)});case 4:return n=r.sent,r.next=7,this.perform("call",n);case 7:return a=r.sent,r.prev=8,r.abrupt("return",Object(g.hexlify)(a));case 12:return r.prev=12,r.t0=r.catch(8),r.abrupt("return",Be.throwError("bad result from backend",y.Logger.errors.SERVER_ERROR,{method:"call",params:n,result:a,error:r.t0}));case 15:case"end":return r.stop()}}),r,this,[[8,12]])})))}},{key:"estimateGas",value:function(e){return Ne(this,void 0,void 0,p.a.mark((function t(){var r,n;return p.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.getNetwork();case 2:return t.next=4,Object(x.resolveProperties)({transaction:this._getTransactionRequest(e)});case 4:return r=t.sent,t.next=7,this.perform("estimateGas",r);case 7:return n=t.sent,t.prev=8,t.abrupt("return",P.a.from(n));case 12:return t.prev=12,t.t0=t.catch(8),t.abrupt("return",Be.throwError("bad result from backend",y.Logger.errors.SERVER_ERROR,{method:"estimateGas",params:r,result:n,error:t.t0}));case 15:case"end":return t.stop()}}),t,this,[[8,12]])})))}},{key:"_getAddress",value:function(e){return Ne(this,void 0,void 0,p.a.mark((function t(){var r;return p.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.resolveName(e);case 2:return null==(r=t.sent)&&Be.throwError("ENS name not configured",y.Logger.errors.UNSUPPORTED_OPERATION,{operation:"resolveName(".concat(JSON.stringify(e),")")}),t.abrupt("return",r);case 5:case"end":return t.stop()}}),t,this)})))}},{key:"_getBlock",value:function(e,t){return Ne(this,void 0,void 0,p.a.mark((function r(){var n,a,i=this;return p.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,this.getNetwork();case 2:return r.next=4,e;case 4:if(e=r.sent,n=-128,a={includeTransactions:!!t},!Object(g.isHexString)(e,32)){r.next=11;break}a.blockHash=e,r.next=23;break;case 11:return r.prev=11,r.t0=this.formatter,r.next=15,this._getBlockTag(e);case 15:r.t1=r.sent,a.blockTag=r.t0.blockTag.call(r.t0,r.t1),Object(g.isHexString)(a.blockTag)&&(n=parseInt(a.blockTag.substring(2),16)),r.next=23;break;case 20:r.prev=20,r.t2=r.catch(11),Be.throwArgumentError("invalid block hash or block tag","blockHashOrBlockTag",e);case 23:return r.abrupt("return",Object(Me.poll)((function(){return Ne(i,void 0,void 0,p.a.mark((function e(){var r,i,o,c,s;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.perform("getBlock",a);case 2:if(null!=(r=e.sent)){e.next=11;break}if(null==a.blockHash){e.next=7;break}if(null!=this._emitted["b:"+a.blockHash]){e.next=7;break}return e.abrupt("return",null);case 7:if(null==a.blockTag){e.next=10;break}if(!(n>this._emitted.block)){e.next=10;break}return e.abrupt("return",null);case 10:return e.abrupt("return",void 0);case 11:if(!t){e.next=32;break}i=null,o=0;case 14:if(!(oa.length)){t.next=24;break}return t.abrupt("return",null);case 24:return o=Object(_e.h)(a.slice(0,i)),t.next=27,this.resolveName(o);case 27:if(t.sent==e){t.next=30;break}return t.abrupt("return",null);case 30:return t.abrupt("return",o);case 31:case"end":return t.stop()}}),t,this)})))}},{key:"perform",value:function(e,t){return Be.throwError(e+" not implemented",y.Logger.errors.NOT_IMPLEMENTED,{operation:e})}},{key:"_startEvent",value:function(e){this.polling=this._events.filter((function(e){return e.pollable()})).length>0}},{key:"_stopEvent",value:function(e){this.polling=this._events.filter((function(e){return e.pollable()})).length>0}},{key:"_addEventListener",value:function(e,t,r){var n=new He(Fe(e),t,r);return this._events.push(n),this._startEvent(n),this}},{key:"on",value:function(e,t){return this._addEventListener(e,t,!1)}},{key:"once",value:function(e,t){return this._addEventListener(e,t,!0)}},{key:"emit",value:function(e){for(var t=this,r=arguments.length,n=new Array(r>1?r-1:0),a=1;a=0&&a.match(/gas required exceeds allowance|always failing transaction|execution reverted/)&&Qe.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",y.Logger.errors.UNPREDICTABLE_GAS_LIMIT,{error:t,method:e,transaction:i}),t}function tt(e){return new Promise((function(t){setTimeout(t,e)}))}function rt(e){if(e.error){var t=new Error(e.error.message);throw t.code=e.error.code,t.data=e.error.data,t}return e.result}function nt(e){return e?e.toLowerCase():e}var at={},it=function(e){Object(d.a)(r,e);var t=Object(u.a)(r);function r(e,n,a){var i;if(Object(l.a)(this,r),Qe.checkNew(this instanceof r?this.constructor:void 0,r),i=t.call(this),e!==at)throw new Error("do not call the JsonRpcSigner constructor directly; use provider.getSigner");return Object(x.defineReadOnly)(Object(c.a)(i),"provider",n),null==a&&(a=0),"string"===typeof a?(Object(x.defineReadOnly)(Object(c.a)(i),"_address",i.provider.formatter.address(a)),Object(x.defineReadOnly)(Object(c.a)(i),"_index",null)):"number"===typeof a?(Object(x.defineReadOnly)(Object(c.a)(i),"_index",a),Object(x.defineReadOnly)(Object(c.a)(i),"_address",null)):Qe.throwArgumentError("invalid address or index","addressOrIndex",a),i}return Object(b.a)(r,[{key:"connect",value:function(e){return Qe.throwError("cannot alter JSON-RPC Signer connection",y.Logger.errors.UNSUPPORTED_OPERATION,{operation:"connect"})}},{key:"connectUnchecked",value:function(){return new ot(at,this.provider,this._address||this._index)}},{key:"getAddress",value:function(){var e=this;return this._address?Promise.resolve(this._address):this.provider.send("eth_accounts",[]).then((function(t){return t.length<=e._index&&Qe.throwError("unknown account #"+e._index,y.Logger.errors.UNSUPPORTED_OPERATION,{operation:"getAddress"}),e.provider.formatter.address(t[e._index])}))}},{key:"sendUncheckedTransaction",value:function(e){var t=this;e=Object(x.shallowCopy)(e);var r=this.getAddress().then((function(e){return e&&(e=e.toLowerCase()),e}));if(null==e.gasLimit){var n=Object(x.shallowCopy)(e);n.from=r,e.gasLimit=this.provider.estimateGas(n)}return Object(x.resolveProperties)({tx:Object(x.resolveProperties)(e),sender:r}).then((function(r){var n=r.tx,a=r.sender;null!=n.from?n.from.toLowerCase()!==a&&Qe.throwArgumentError("from address mismatch","transaction",e):n.from=a;var i=t.provider.constructor.hexlifyTransaction(n,{from:!0});return t.provider.send("eth_sendTransaction",[i]).then((function(e){return e}),(function(e){return et("sendTransaction",e,i)}))}))}},{key:"signTransaction",value:function(e){return Qe.throwError("signing transactions is unsupported",y.Logger.errors.UNSUPPORTED_OPERATION,{operation:"signTransaction"})}},{key:"sendTransaction",value:function(e){var t=this;return this.sendUncheckedTransaction(e).then((function(e){return Object(Me.poll)((function(){return t.provider.getTransaction(e).then((function(r){if(null!==r)return t.provider._wrapTransaction(r,e)}))}),{oncePoll:t.provider}).catch((function(t){throw t.transactionHash=e,t}))}))}},{key:"signMessage",value:function(e){return $e(this,void 0,void 0,p.a.mark((function t(){var r,n;return p.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r="string"===typeof e?Object(_e.f)(e):e,t.next=3,this.getAddress();case 3:return n=t.sent,t.next=6,this.provider.send("eth_sign",[n.toLowerCase(),Object(g.hexlify)(r)]);case 6:return t.abrupt("return",t.sent);case 7:case"end":return t.stop()}}),t,this)})))}},{key:"_signTypedData",value:function(e,t,r){return $e(this,void 0,void 0,p.a.mark((function n(){var a,i,o=this;return p.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,Ze.a.resolveNames(e,t,r,(function(e){return o.provider.resolveName(e)}));case 2:return a=n.sent,n.next=5,this.getAddress();case 5:return i=n.sent,n.next=8,this.provider.send("eth_signTypedData_v4",[i.toLowerCase(),JSON.stringify(Ze.a.getPayload(a.domain,t,a.value))]);case 8:return n.abrupt("return",n.sent);case 9:case"end":return n.stop()}}),n,this)})))}},{key:"unlock",value:function(e){return $e(this,void 0,void 0,p.a.mark((function t(){var r,n;return p.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=this.provider,t.next=3,this.getAddress();case 3:return n=t.sent,t.abrupt("return",r.send("personal_unlockAccount",[n.toLowerCase(),e,null]));case 5:case"end":return t.stop()}}),t,this)})))}}]),r}(A),ot=function(e){Object(d.a)(r,e);var t=Object(u.a)(r);function r(){return Object(l.a)(this,r),t.apply(this,arguments)}return Object(b.a)(r,[{key:"sendTransaction",value:function(e){var t=this;return this.sendUncheckedTransaction(e).then((function(e){return{hash:e,nonce:null,gasLimit:null,gasPrice:null,data:null,value:null,chainId:null,confirmations:0,from:null,wait:function(r){return t.provider.waitForTransaction(e,r)}}}))}}]),r}(it),ct={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,value:!0,type:!0,accessList:!0},st=function(e){Object(d.a)(r,e);var t=Object(u.a)(r);function r(e,n){var a;Object(l.a)(this,r),Qe.checkNew(this instanceof r?this.constructor:void 0,r);var i=n;return null==i&&(i=new Promise((function(e,t){setTimeout((function(){a.detectNetwork().then((function(t){e(t)}),(function(e){t(e)}))}),0)}))),a=t.call(this,i),e||(e=Object(x.getStatic)(a.constructor,"defaultUrl")()),"string"===typeof e?Object(x.defineReadOnly)(Object(c.a)(a),"connection",Object.freeze({url:e})):Object(x.defineReadOnly)(Object(c.a)(a),"connection",Object.freeze(Object(x.shallowCopy)(e))),a._nextId=42,a}return Object(b.a)(r,[{key:"_cache",get:function(){return null==this._eventLoopCache&&(this._eventLoopCache={}),this._eventLoopCache}},{key:"detectNetwork",value:function(){var e=this;return this._cache.detectNetwork||(this._cache.detectNetwork=this._uncachedDetectNetwork(),setTimeout((function(){e._cache.detectNetwork=null}),0)),this._cache.detectNetwork}},{key:"_uncachedDetectNetwork",value:function(){return $e(this,void 0,void 0,p.a.mark((function e(){var t,r;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,tt(0);case 2:return t=null,e.prev=3,e.next=6,this.send("eth_chainId",[]);case 6:t=e.sent,e.next=19;break;case 9:return e.prev=9,e.t0=e.catch(3),e.prev=11,e.next=14,this.send("net_version",[]);case 14:t=e.sent,e.next=19;break;case 17:e.prev=17,e.t1=e.catch(11);case 19:if(null==t){e.next=28;break}return r=Object(x.getStatic)(this.constructor,"getNetwork"),e.prev=21,e.abrupt("return",r(P.a.from(t).toNumber()));case 25:return e.prev=25,e.t2=e.catch(21),e.abrupt("return",Qe.throwError("could not detect network",y.Logger.errors.NETWORK_ERROR,{chainId:t,event:"invalidNetwork",serverError:e.t2}));case 28:return e.abrupt("return",Qe.throwError("could not detect network",y.Logger.errors.NETWORK_ERROR,{event:"noNetwork"}));case 29:case"end":return e.stop()}}),e,this,[[3,9],[11,17],[21,25]])})))}},{key:"getSigner",value:function(e){return new it(at,this,e)}},{key:"getUncheckedSigner",value:function(e){return this.getSigner(e).connectUnchecked()}},{key:"listAccounts",value:function(){var e=this;return this.send("eth_accounts",[]).then((function(t){return t.map((function(t){return e.formatter.address(t)}))}))}},{key:"send",value:function(e,t){var r=this,n={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};this.emit("debug",{action:"request",request:Object(x.deepCopy)(n),provider:this});var a=["eth_chainId","eth_blockNumber"].indexOf(e)>=0;if(a&&this._cache[e])return this._cache[e];var i=Object(Me.fetchJson)(this.connection,JSON.stringify(n),rt).then((function(e){return r.emit("debug",{action:"response",request:n,response:e,provider:r}),e}),(function(e){throw r.emit("debug",{action:"response",error:e,request:n,provider:r}),e}));return a&&(this._cache[e]=i,setTimeout((function(){r._cache[e]=null}),0)),i}},{key:"prepareRequest",value:function(e,t){switch(e){case"getBlockNumber":return["eth_blockNumber",[]];case"getGasPrice":return["eth_gasPrice",[]];case"getBalance":return["eth_getBalance",[nt(t.address),t.blockTag]];case"getTransactionCount":return["eth_getTransactionCount",[nt(t.address),t.blockTag]];case"getCode":return["eth_getCode",[nt(t.address),t.blockTag]];case"getStorageAt":return["eth_getStorageAt",[nt(t.address),t.position,t.blockTag]];case"sendTransaction":return["eth_sendRawTransaction",[t.signedTransaction]];case"getBlock":return t.blockTag?["eth_getBlockByNumber",[t.blockTag,!!t.includeTransactions]]:t.blockHash?["eth_getBlockByHash",[t.blockHash,!!t.includeTransactions]]:null;case"getTransaction":return["eth_getTransactionByHash",[t.transactionHash]];case"getTransactionReceipt":return["eth_getTransactionReceipt",[t.transactionHash]];case"call":return["eth_call",[Object(x.getStatic)(this.constructor,"hexlifyTransaction")(t.transaction,{from:!0}),t.blockTag]];case"estimateGas":return["eth_estimateGas",[Object(x.getStatic)(this.constructor,"hexlifyTransaction")(t.transaction,{from:!0})]];case"getLogs":return t.filter&&null!=t.filter.address&&(t.filter.address=nt(t.filter.address)),["eth_getLogs",[t.filter]]}return null}},{key:"perform",value:function(e,t){return $e(this,void 0,void 0,p.a.mark((function r(){var n;return p.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return null==(n=this.prepareRequest(e,t))&&Qe.throwError(e+" not implemented",y.Logger.errors.NOT_IMPLEMENTED,{operation:e}),r.prev=2,r.next=5,this.send(n[0],n[1]);case 5:return r.abrupt("return",r.sent);case 8:return r.prev=8,r.t0=r.catch(2),r.abrupt("return",et(e,r.t0,t));case 11:case"end":return r.stop()}}),r,this,[[2,8]])})))}},{key:"_startEvent",value:function(e){"pending"===e.tag&&this._startPending(),Object(s.a)(Object(f.a)(r.prototype),"_startEvent",this).call(this,e)}},{key:"_startPending",value:function(){if(null==this._pendingFilter){var e=this,t=this.send("eth_newPendingTransactionFilter",[]);this._pendingFilter=t,t.then((function(r){return function n(){e.send("eth_getFilterChanges",[r]).then((function(r){if(e._pendingFilter!=t)return null;var n=Promise.resolve();return r.forEach((function(t){e._emitted["t:"+t.toLowerCase()]="pending",n=n.then((function(){return e.getTransaction(t).then((function(t){return e.emit("pending",t),null}))}))})),n.then((function(){return tt(1e3)}))})).then((function(){if(e._pendingFilter==t)return setTimeout((function(){n()}),0),null;e.send("eth_uninstallFilter",[r])})).catch((function(e){}))}(),r})).catch((function(e){}))}}},{key:"_stopEvent",value:function(e){"pending"===e.tag&&0===this.listenerCount("pending")&&(this._pendingFilter=null),Object(s.a)(Object(f.a)(r.prototype),"_stopEvent",this).call(this,e)}}],[{key:"defaultUrl",value:function(){return"http://localhost:8545"}},{key:"hexlifyTransaction",value:function(e,t){var r=Object(x.shallowCopy)(ct);if(t)for(var n in t)t[n]&&(r[n]=!0);Object(x.checkProperties)(e,r);var a={};return["gasLimit","gasPrice","type","nonce","value"].forEach((function(t){if(null!=e[t]){var r=Object(g.hexValue)(e[t]);"gasLimit"===t&&(t="gas"),a[t]=r}})),["from","to","data"].forEach((function(t){null!=e[t]&&(a[t]=Object(g.hexlify)(e[t]))})),e.accessList&&(a.accessList=Object(C.accessListify)(e.accessList)),a}}]),r}(We),ft=null;try{if(null==(ft=WebSocket))throw new Error("inject please")}catch(Nr){var dt=new y.Logger("providers/5.3.0");ft=function(){dt.throwError("WebSockets not supported in this environment",y.Logger.errors.UNSUPPORTED_OPERATION,{operation:"new WebSocket()"})}}var ut=function(e,t,r,n){return new(r||(r=Promise))((function(a,i){function o(e){try{s(n.next(e))}catch(t){i(t)}}function c(e){try{s(n.throw(e))}catch(t){i(t)}}function s(e){var t;e.done?a(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(o,c)}s((n=n.apply(e,t||[])).next())}))},lt=new y.Logger("providers/5.3.0"),bt=1,ht=function(e){Object(d.a)(r,e);var t=Object(u.a)(r);function r(e,n){var a,i;Object(l.a)(this,r),"any"===n&<.throwError("WebSocketProvider does not support 'any' network yet",y.Logger.errors.UNSUPPORTED_OPERATION,{operation:"network:any"}),(i=t.call(this,e,n))._pollingInterval=-1,i._wsReady=!1,Object(x.defineReadOnly)(Object(c.a)(i),"_websocket",new ft(i.connection.url)),Object(x.defineReadOnly)(Object(c.a)(i),"_requests",{}),Object(x.defineReadOnly)(Object(c.a)(i),"_subs",{}),Object(x.defineReadOnly)(Object(c.a)(i),"_subIds",{}),Object(x.defineReadOnly)(Object(c.a)(i),"_detectNetwork",Object(s.a)((a=Object(c.a)(i),Object(f.a)(r.prototype)),"detectNetwork",a).call(a)),i._websocket.onopen=function(){i._wsReady=!0,Object.keys(i._requests).forEach((function(e){i._websocket.send(i._requests[e].payload)}))},i._websocket.onmessage=function(e){var t=e.data,r=JSON.parse(t);if(null!=r.id){var n=String(r.id),a=i._requests[n];if(delete i._requests[n],void 0!==r.result)a.callback(null,r.result),i.emit("debug",{action:"response",request:JSON.parse(a.payload),response:r.result,provider:Object(c.a)(i)});else{var o=null;r.error?(o=new Error(r.error.message||"unknown error"),Object(x.defineReadOnly)(o,"code",r.error.code||null),Object(x.defineReadOnly)(o,"response",t)):o=new Error("unknown error"),a.callback(o,void 0),i.emit("debug",{action:"response",error:o,request:JSON.parse(a.payload),provider:Object(c.a)(i)})}}else if("eth_subscription"===r.method){var s=i._subs[r.params.subscription];s&&s.processFunc(r.params.result)}else console.warn("this should not happen")};var o=setInterval((function(){i.emit("poll")}),1e3);return o.unref&&o.unref(),i}return Object(b.a)(r,[{key:"detectNetwork",value:function(){return this._detectNetwork}},{key:"pollingInterval",get:function(){return 0},set:function(e){lt.throwError("cannot set polling interval on WebSocketProvider",y.Logger.errors.UNSUPPORTED_OPERATION,{operation:"setPollingInterval"})}},{key:"resetEventsBlock",value:function(e){lt.throwError("cannot reset events block on WebSocketProvider",y.Logger.errors.UNSUPPORTED_OPERATION,{operation:"resetEventBlock"})}},{key:"poll",value:function(){return ut(this,void 0,void 0,p.a.mark((function e(){return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",null);case 1:case"end":return e.stop()}}),e)})))}},{key:"polling",set:function(e){e&<.throwError("cannot set polling on WebSocketProvider",y.Logger.errors.UNSUPPORTED_OPERATION,{operation:"setPolling"})}},{key:"send",value:function(e,t){var r=this,n=bt++;return new Promise((function(a,i){var o=JSON.stringify({method:e,params:t,id:n,jsonrpc:"2.0"});r.emit("debug",{action:"request",request:JSON.parse(o),provider:r}),r._requests[String(n)]={callback:function(e,t){return e?i(e):a(t)},payload:o},r._wsReady&&r._websocket.send(o)}))}},{key:"_subscribe",value:function(e,t,r){return ut(this,void 0,void 0,p.a.mark((function n(){var a,i,o=this;return p.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return null==(a=this._subIds[e])&&(a=Promise.all(t).then((function(e){return o.send("eth_subscribe",e)})),this._subIds[e]=a),n.next=4,a;case 4:i=n.sent,this._subs[i]={tag:e,processFunc:r};case 6:case"end":return n.stop()}}),n,this)})))}},{key:"_startEvent",value:function(e){var t=this;switch(e.type){case"block":this._subscribe("block",["newHeads"],(function(e){var r=P.a.from(e.number).toNumber();t._emitted.block=r,t.emit("block",r)}));break;case"pending":this._subscribe("pending",["newPendingTransactions"],(function(e){t.emit("pending",e)}));break;case"filter":this._subscribe(e.tag,["logs",this._getFilter(e.filter)],(function(r){null==r.removed&&(r.removed=!1),t.emit(e.filter,t.formatter.filterLog(r))}));break;case"tx":var r=function(e){var r=e.hash;t.getTransactionReceipt(r).then((function(e){e&&t.emit(r,e)}))};r(e),this._subscribe("tx",["newHeads"],(function(e){t._events.filter((function(e){return"tx"===e.type})).forEach(r)}));break;case"debug":case"poll":case"willPoll":case"didPoll":case"error":break;default:console.log("unhandled:",e)}}},{key:"_stopEvent",value:function(e){var t=this,r=e.tag;if("tx"===e.type){if(this._events.filter((function(e){return"tx"===e.type})).length)return;r="tx"}else if(this.listenerCount(e.event))return;var n=this._subIds[r];n&&(delete this._subIds[r],n.then((function(e){t._subs[e]&&(delete t._subs[e],t.send("eth_unsubscribe",[e]))})))}},{key:"destroy",value:function(){return ut(this,void 0,void 0,p.a.mark((function e(){var t=this;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(this._websocket.readyState!==ft.CONNECTING){e.next=3;break}return e.next=3,new Promise((function(e){t._websocket.onopen=function(){e(!0)},t._websocket.onerror=function(){e(!1)}}));case 3:this._websocket.close(1e3);case 4:case"end":return e.stop()}}),e,this)})))}}],[{key:"defaultUrl",value:function(){return"ws://localhost:8546"}}]),r}(st),pt=function(e,t,r,n){return new(r||(r=Promise))((function(a,i){function o(e){try{s(n.next(e))}catch(t){i(t)}}function c(e){try{s(n.throw(e))}catch(t){i(t)}}function s(e){var t;e.done?a(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(o,c)}s((n=n.apply(e,t||[])).next())}))},mt=new y.Logger("providers/5.3.0"),vt=function(e){Object(d.a)(r,e);var t=Object(u.a)(r);function r(){return Object(l.a)(this,r),t.apply(this,arguments)}return Object(b.a)(r,[{key:"detectNetwork",value:function(){var e=this,t=Object.create(null,{detectNetwork:{get:function(){return Object(s.a)(Object(f.a)(r.prototype),"detectNetwork",e)}}});return pt(this,void 0,void 0,p.a.mark((function e(){var r;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(null!=(r=this.network)){e.next=7;break}return e.next=4,t.detectNetwork.call(this);case 4:(r=e.sent)||mt.throwError("no network detected",y.Logger.errors.UNKNOWN_ERROR,{}),null==this._network&&(Object(x.defineReadOnly)(this,"_network",r),this.emit("network",r,null));case 7:return e.abrupt("return",r);case 8:case"end":return e.stop()}}),e,this)})))}}]),r}(st),gt=function(e){Object(d.a)(r,e);var t=Object(u.a)(r);function r(e,n){var a;Object(l.a)(this,r),mt.checkAbstract(this instanceof r?this.constructor:void 0,r),e=Object(x.getStatic)(this instanceof r?this.constructor:void 0,"getNetwork")(e),n=Object(x.getStatic)(this instanceof r?this.constructor:void 0,"getApiKey")(n);var i=Object(x.getStatic)(this instanceof r?this.constructor:void 0,"getUrl")(e,n);return a=t.call(this,i,e),"string"===typeof n?Object(x.defineReadOnly)(Object(c.a)(a),"apiKey",n):null!=n&&Object.keys(n).forEach((function(e){Object(x.defineReadOnly)(Object(c.a)(a),e,n[e])})),a}return Object(b.a)(r,[{key:"_startPending",value:function(){mt.warn("WARNING: API provider does not support pending filters")}},{key:"isCommunityResource",value:function(){return!1}},{key:"getSigner",value:function(e){return mt.throwError("API provider does not support signing",y.Logger.errors.UNSUPPORTED_OPERATION,{operation:"getSigner"})}},{key:"listAccounts",value:function(){return Promise.resolve([])}}],[{key:"getApiKey",value:function(e){return e}},{key:"getUrl",value:function(e,t){return mt.throwError("not implemented; sub-classes must override getUrl",y.Logger.errors.NOT_IMPLEMENTED,{operation:"getUrl"})}}]),r}(vt),xt=new y.Logger("providers/5.3.0"),yt="_gg7wSSi0KMBsdKnGVfHDueq6xMB9EkC",wt=function(e){Object(d.a)(r,e);var t=Object(u.a)(r);function r(e,n){var a;Object(l.a)(this,r);var i=new kt(e,n),o=i.connection.url.replace(/^http/i,"ws").replace(".alchemyapi.",".ws.alchemyapi.");return a=t.call(this,o,i.network),Object(x.defineReadOnly)(Object(c.a)(a),"apiKey",i.apiKey),a}return Object(b.a)(r,[{key:"isCommunityResource",value:function(){return this.apiKey===yt}}]),r}(ht),kt=function(e){Object(d.a)(r,e);var t=Object(u.a)(r);function r(){return Object(l.a)(this,r),t.apply(this,arguments)}return Object(b.a)(r,[{key:"isCommunityResource",value:function(){return this.apiKey===yt}}],[{key:"getWebSocketProvider",value:function(e,t){return new wt(e,t)}},{key:"getApiKey",value:function(e){return null==e?yt:(e&&"string"!==typeof e&&xt.throwArgumentError("invalid apiKey","apiKey",e),e)}},{key:"getUrl",value:function(e,t){var r=null;switch(e.name){case"homestead":r="eth-mainnet.alchemyapi.io/v2/";break;case"ropsten":r="eth-ropsten.alchemyapi.io/v2/";break;case"rinkeby":r="eth-rinkeby.alchemyapi.io/v2/";break;case"goerli":r="eth-goerli.alchemyapi.io/v2/";break;case"kovan":r="eth-kovan.alchemyapi.io/v2/";break;default:xt.throwArgumentError("unsupported network","network",arguments[0])}return{allowGzip:!0,url:"https://"+r+t,throttleCallback:function(e,r){return t===yt&&Re(),Promise.resolve(!0)}}}}]),r}(gt),_t=function(e,t,r,n){return new(r||(r=Promise))((function(a,i){function o(e){try{s(n.next(e))}catch(t){i(t)}}function c(e){try{s(n.throw(e))}catch(t){i(t)}}function s(e){var t;e.done?a(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(o,c)}s((n=n.apply(e,t||[])).next())}))},Mt=new y.Logger("providers/5.3.0"),St=function(e){Object(d.a)(r,e);var t=Object(u.a)(r);function r(){return Object(l.a)(this,r),t.apply(this,arguments)}return Object(b.a)(r,[{key:"perform",value:function(e,t){var n=this,a=Object.create(null,{perform:{get:function(){return Object(s.a)(Object(f.a)(r.prototype),"perform",n)}}});return _t(this,void 0,void 0,p.a.mark((function r(){var n;return p.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if("getBlockNumber"!==e){r.next=5;break}return r.next=3,a.perform.call(this,"getBlock",{blockTag:"latest"});case 3:return n=r.sent,r.abrupt("return",n.number);case 5:return r.abrupt("return",a.perform.call(this,e,t));case 6:case"end":return r.stop()}}),r,this)})))}}],[{key:"getApiKey",value:function(e){return null!=e&&Mt.throwArgumentError("apiKey not supported for cloudflare","apiKey",e),null}},{key:"getUrl",value:function(e,t){var r=null;switch(e.name){case"homestead":r="https://cloudflare-eth.com/";break;default:Mt.throwArgumentError("unsupported network","network",arguments[0])}return r}}]),r}(gt),Et=function(e,t,r,n){return new(r||(r=Promise))((function(a,i){function o(e){try{s(n.next(e))}catch(t){i(t)}}function c(e){try{s(n.throw(e))}catch(t){i(t)}}function s(e){var t;e.done?a(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(o,c)}s((n=n.apply(e,t||[])).next())}))},Ot=new y.Logger("providers/5.3.0");function At(e){var t={};for(var r in e)if(null!=e[r]){var n=e[r];n={type:!0,gasLimit:!0,gasPrice:!0,nonce:!0,value:!0}[r]?Object(g.hexValue)(Object(g.hexlify)(n)):"accessList"===r?"["+Object(C.accessListify)(n).map((function(e){return'{address:"'.concat(e.address,'",storageKeys:["').concat(e.storageKeys.join('","'),'"]}')})).join(",")+"]":Object(g.hexlify)(n),t[r]=n}return t}function Tt(e){if(0==e.status&&("No records found"===e.message||"No transactions found"===e.message))return e.result;if(1!=e.status||"OK"!=e.message){var t=new Error("invalid response");throw t.result=JSON.stringify(e),(e.result||"").toLowerCase().indexOf("rate limit")>=0&&(t.throttleRetry=!0),t}return e.result}function jt(e){if(e&&0==e.status&&"NOTOK"==e.message&&(e.result||"").toLowerCase().indexOf("rate limit")>=0){var t=new Error("throttled response");throw t.result=JSON.stringify(e),t.throttleRetry=!0,t}if("2.0"!=e.jsonrpc){var r=new Error("invalid response");throw r.result=JSON.stringify(e),r}if(e.error){var n=new Error(e.error.message||"unknown error");throw e.error.code&&(n.code=e.error.code),e.error.data&&(n.data=e.error.data),n}return e.result}function Pt(e){if("pending"===e)throw new Error("pending not supported");return"latest"===e?e:parseInt(e.substring(2),16)}function Ct(e,t,r){if("call"===e&&t.code===y.Logger.errors.SERVER_ERROR){var n=t.error;if(n&&n.message.match("reverted")&&Object(g.isHexString)(n.data))return n.data}var a=t.message;throw t.code===y.Logger.errors.SERVER_ERROR&&(t.error&&"string"===typeof t.error.message?a=t.error.message:"string"===typeof t.body?a=t.body:"string"===typeof t.responseText&&(a=t.responseText)),(a=(a||"").toLowerCase()).match(/insufficient funds/)&&Ot.throwError("insufficient funds for intrinsic transaction cost",y.Logger.errors.INSUFFICIENT_FUNDS,{error:t,method:e,transaction:r}),a.match(/same hash was already imported|transaction nonce is too low/)&&Ot.throwError("nonce has already been used",y.Logger.errors.NONCE_EXPIRED,{error:t,method:e,transaction:r}),a.match(/another transaction with same nonce/)&&Ot.throwError("replacement fee too low",y.Logger.errors.REPLACEMENT_UNDERPRICED,{error:t,method:e,transaction:r}),a.match(/execution failed due to an exception/)&&Ot.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",y.Logger.errors.UNPREDICTABLE_GAS_LIMIT,{error:t,method:e,transaction:r}),t}var Rt=function(e){Object(d.a)(r,e);var t=Object(u.a)(r);function r(e,n){var a;return Object(l.a)(this,r),Ot.checkNew(this instanceof r?this.constructor:void 0,r),a=t.call(this,e),Object(x.defineReadOnly)(Object(c.a)(a),"baseUrl",a.getBaseUrl()),Object(x.defineReadOnly)(Object(c.a)(a),"apiKey",n||"9D13ZE7XSBTJ94N9BNJ2MA33VMAY2YPIRB"),a}return Object(b.a)(r,[{key:"getBaseUrl",value:function(){switch(this.network?this.network.name:"invalid"){case"homestead":return"https://api.etherscan.io";case"ropsten":return"https://api-ropsten.etherscan.io";case"rinkeby":return"https://api-rinkeby.etherscan.io";case"kovan":return"https://api-kovan.etherscan.io";case"goerli":return"https://api-goerli.etherscan.io"}return Ot.throwArgumentError("unsupported network","network",name)}},{key:"getUrl",value:function(e,t){var r=Object.keys(t).reduce((function(e,r){var n=t[r];return null!=n&&(e+="&".concat(r,"=").concat(n)),e}),""),n=this.apiKey?"&apikey=".concat(this.apiKey):"";return"".concat(this.baseUrl,"/api?module=").concat(e).concat(r).concat(n)}},{key:"getPostUrl",value:function(){return"".concat(this.baseUrl,"/api")}},{key:"getPostData",value:function(e,t){return t.module=e,t.apikey=this.apiKey,t}},{key:"fetch",value:function(e,t,r){return Et(this,void 0,void 0,p.a.mark((function n(){var a,i,o,c,s,f,d=this;return p.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return a=r?this.getPostUrl():this.getUrl(e,t),i=r?this.getPostData(e,t):null,o="proxy"===e?jt:Tt,this.emit("debug",{action:"request",request:a,provider:this}),c={url:a,throttleSlotInterval:1e3,throttleCallback:function(e,t){return d.isCommunityResource()&&Re(),Promise.resolve(!0)}},s=null,i&&(c.headers={"content-type":"application/x-www-form-urlencoded; charset=UTF-8"},s=Object.keys(i).map((function(e){return"".concat(e,"=").concat(i[e])})).join("&")),n.next=9,Object(Me.fetchJson)(c,s,o||jt);case 9:return f=n.sent,this.emit("debug",{action:"response",request:a,response:Object(x.deepCopy)(f),provider:this}),n.abrupt("return",f);case 12:case"end":return n.stop()}}),n,this)})))}},{key:"detectNetwork",value:function(){return Et(this,void 0,void 0,p.a.mark((function e(){return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",this.network);case 1:case"end":return e.stop()}}),e,this)})))}},{key:"perform",value:function(e,t){var n=this,a=Object.create(null,{perform:{get:function(){return Object(s.a)(Object(f.a)(r.prototype),"perform",n)}}});return Et(this,void 0,void 0,p.a.mark((function r(){var n,i,o,c,s,f,d,u,l;return p.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:r.t0=e,r.next="getBlockNumber"===r.t0?3:"getGasPrice"===r.t0?4:"getBalance"===r.t0?5:"getTransactionCount"===r.t0?6:"getCode"===r.t0?7:"getStorageAt"===r.t0?8:"sendTransaction"===r.t0?9:"getBlock"===r.t0?10:"getTransaction"===r.t0?13:"getTransactionReceipt"===r.t0?14:"call"===r.t0?15:"estimateGas"===r.t0?29:"getLogs"===r.t0?41:"getEtherPrice"===r.t0?65:72;break;case 3:return r.abrupt("return",this.fetch("proxy",{action:"eth_blockNumber"}));case 4:return r.abrupt("return",this.fetch("proxy",{action:"eth_gasPrice"}));case 5:return r.abrupt("return",this.fetch("account",{action:"balance",address:t.address,tag:t.blockTag}));case 6:return r.abrupt("return",this.fetch("proxy",{action:"eth_getTransactionCount",address:t.address,tag:t.blockTag}));case 7:return r.abrupt("return",this.fetch("proxy",{action:"eth_getCode",address:t.address,tag:t.blockTag}));case 8:return r.abrupt("return",this.fetch("proxy",{action:"eth_getStorageAt",address:t.address,position:t.position,tag:t.blockTag}));case 9:return r.abrupt("return",this.fetch("proxy",{action:"eth_sendRawTransaction",hex:t.signedTransaction},!0).catch((function(e){return Ct("sendTransaction",e,t.signedTransaction)})));case 10:if(!t.blockTag){r.next=12;break}return r.abrupt("return",this.fetch("proxy",{action:"eth_getBlockByNumber",tag:t.blockTag,boolean:t.includeTransactions?"true":"false"}));case 12:throw new Error("getBlock by blockHash not implemented");case 13:return r.abrupt("return",this.fetch("proxy",{action:"eth_getTransactionByHash",txhash:t.transactionHash}));case 14:return r.abrupt("return",this.fetch("proxy",{action:"eth_getTransactionReceipt",txhash:t.transactionHash}));case 15:if("latest"===t.blockTag){r.next=17;break}throw new Error("EtherscanProvider does not support blockTag for call");case 17:return(n=At(t.transaction)).module="proxy",n.action="eth_call",r.prev=20,r.next=23,this.fetch("proxy",n,!0);case 23:return r.abrupt("return",r.sent);case 26:return r.prev=26,r.t1=r.catch(20),r.abrupt("return",Ct("call",r.t1,t.transaction));case 29:return(i=At(t.transaction)).module="proxy",i.action="eth_estimateGas",r.prev=32,r.next=35,this.fetch("proxy",i,!0);case 35:return r.abrupt("return",r.sent);case 38:return r.prev=38,r.t2=r.catch(32),r.abrupt("return",Ct("estimateGas",r.t2,t.transaction));case 41:return o={action:"getLogs"},t.filter.fromBlock&&(o.fromBlock=Pt(t.filter.fromBlock)),t.filter.toBlock&&(o.toBlock=Pt(t.filter.toBlock)),t.filter.address&&(o.address=t.filter.address),t.filter.topics&&t.filter.topics.length>0&&(t.filter.topics.length>1&&Ot.throwError("unsupported topic count",y.Logger.errors.UNSUPPORTED_OPERATION,{topics:t.filter.topics}),1===t.filter.topics.length&&("string"===typeof(c=t.filter.topics[0])&&66===c.length||Ot.throwError("unsupported topic format",y.Logger.errors.UNSUPPORTED_OPERATION,{topic0:c}),o.topic0=c)),r.next=48,this.fetch("logs",o);case 48:s=r.sent,f={},d=0;case 51:if(!(dt?null:(n+a)/2}function Ut(e){if(null===e)return"null";if("number"===typeof e||"boolean"===typeof e)return JSON.stringify(e);if("string"===typeof e)return e;if(P.a.isBigNumber(e))return e.toString();if(Array.isArray(e))return JSON.stringify(e.map((function(e){return Ut(e)})));if("object"===typeof e){var t=Object.keys(e);return t.sort(),"{"+t.map((function(t){var r=e[t];return r="function"===typeof r?"[function]":Ut(r),JSON.stringify(t)+":"+r})).join(",")+"}"}throw new Error("unknown value type: "+typeof e)}var zt=1;function Ht(e){var t=null,r=null,n=new Promise((function(n){t=function(){r&&(clearTimeout(r),r=null),n()},r=setTimeout(t,e)}));return{cancel:t,getPromise:function(){return n},wait:function(e){return n=n.then(e)}}}var qt=[y.Logger.errors.CALL_EXCEPTION,y.Logger.errors.INSUFFICIENT_FUNDS,y.Logger.errors.NONCE_EXPIRED,y.Logger.errors.REPLACEMENT_UNDERPRICED,y.Logger.errors.UNPREDICTABLE_GAS_LIMIT],Jt=["address","args","errorArgs","errorSignature","method","transaction"];function Vt(e,t){var r={weight:e.weight};return Object.defineProperty(r,"provider",{get:function(){return e.provider}}),e.start&&(r.start=e.start),t&&(r.duration=t-e.start),e.done&&(e.error?r.error=e.error:r.result=e.result||null),r}function Gt(e,t,r){var n=Ut;switch(t){case"getBlockNumber":return function(t){var r=t.map((function(e){return e.result})),n=Dt(t.map((function(e){return e.result})),2);if(null!=n)return n=Math.ceil(n),r.indexOf(n+1)>=0&&n++,n>=e._highestBlockNumber&&(e._highestBlockNumber=n),e._highestBlockNumber};case"getGasPrice":return function(e){var t=e.map((function(e){return e.result}));return t.sort(),t[Math.floor(t.length/2)]};case"getEtherPrice":return function(e){return Dt(e.map((function(e){return e.result})))};case"getBalance":case"getTransactionCount":case"getCode":case"getStorageAt":case"call":case"estimateGas":case"getLogs":break;case"getTransaction":case"getTransactionReceipt":n=function(e){return null==e?null:((e=Object(x.shallowCopy)(e)).confirmations=-1,Ut(e))};break;case"getBlock":n=r.includeTransactions?function(e){return null==e?null:((e=Object(x.shallowCopy)(e)).transactions=e.transactions.map((function(e){return(e=Object(x.shallowCopy)(e)).confirmations=-1,e})),Ut(e))}:function(e){return null==e?null:Ut(e)};break;default:throw new Error("unknown method: "+t)}return function(e,t){return function(r){var n={};r.forEach((function(t){var r=e(t.result);n[r]||(n[r]={count:0,result:t.result}),n[r].count++}));for(var a=Object.keys(n),i=0;i=t)return o.result}}}(n,e.quorum)}function Xt(e,t){return Bt(this,void 0,void 0,p.a.mark((function r(){var n;return p.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if(!(null!=(n=e.provider).blockNumber&&n.blockNumber>=t||-1===t)){r.next=3;break}return r.abrupt("return",n);case 3:return r.abrupt("return",Object(Me.poll)((function(){return new Promise((function(r,a){setTimeout((function(){return n.blockNumber>=t?r(n):e.cancelled?r(null):r(void 0)}),0)}))}),{oncePoll:n}));case 4:case"end":return r.stop()}}),r)})))}function Kt(e,t,r,n){return Bt(this,void 0,void 0,p.a.mark((function a(){var i,o;return p.a.wrap((function(a){for(;;)switch(a.prev=a.next){case 0:i=e.provider,a.t0=r,a.next="getBlockNumber"===a.t0||"getGasPrice"===a.t0?4:"getEtherPrice"===a.t0?5:"getBalance"===a.t0||"getTransactionCount"===a.t0||"getCode"===a.t0?8:"getStorageAt"===a.t0?13:"getBlock"===a.t0?18:"call"===a.t0||"estimateGas"===a.t0?23:"getTransaction"===a.t0||"getTransactionReceipt"===a.t0?28:"getLogs"===a.t0?29:35;break;case 4:return a.abrupt("return",i[r]());case 5:if(!i.getEtherPrice){a.next=7;break}return a.abrupt("return",i.getEtherPrice());case 7:return a.abrupt("break",35);case 8:if(!n.blockTag||!Object(g.isHexString)(n.blockTag)){a.next=12;break}return a.next=11,Xt(e,t);case 11:i=a.sent;case 12:return a.abrupt("return",i[r](n.address,n.blockTag||"latest"));case 13:if(!n.blockTag||!Object(g.isHexString)(n.blockTag)){a.next=17;break}return a.next=16,Xt(e,t);case 16:i=a.sent;case 17:return a.abrupt("return",i.getStorageAt(n.address,n.position,n.blockTag||"latest"));case 18:if(!n.blockTag||!Object(g.isHexString)(n.blockTag)){a.next=22;break}return a.next=21,Xt(e,t);case 21:i=a.sent;case 22:return a.abrupt("return",i[n.includeTransactions?"getBlockWithTransactions":"getBlock"](n.blockTag||n.blockHash));case 23:if(!n.blockTag||!Object(g.isHexString)(n.blockTag)){a.next=27;break}return a.next=26,Xt(e,t);case 26:i=a.sent;case 27:return a.abrupt("return",i[r](n.transaction));case 28:return a.abrupt("return",i[r](n.transactionHash));case 29:if(!((o=n.filter).fromBlock&&Object(g.isHexString)(o.fromBlock)||o.toBlock&&Object(g.isHexString)(o.toBlock))){a.next=34;break}return a.next=33,Xt(e,t);case 33:i=a.sent;case 34:return a.abrupt("return",i.getLogs(o));case 35:return a.abrupt("return",Lt.throwError("unknown method error",y.Logger.errors.UNKNOWN_ERROR,{method:r,params:n}));case 36:case"end":return a.stop()}}),a)})))}var Wt=function(e){Object(d.a)(r,e);var t=Object(u.a)(r);function r(e,n){var a;Object(l.a)(this,r),Lt.checkNew(this instanceof r?this.constructor:void 0,r),0===e.length&&Lt.throwArgumentError("missing providers","providers",e);var i=e.map((function(e,t){if(_.isProvider(e)){var r=Pe(e)?2e3:750;return Object.freeze({provider:e,weight:1,stallTimeout:r,priority:1})}var n=Object(x.shallowCopy)(e);null==n.priority&&(n.priority=1),null==n.stallTimeout&&(n.stallTimeout=Pe(e)?2e3:750),null==n.weight&&(n.weight=1);var a=n.weight;return(a%1||a>512||a<1)&&Lt.throwArgumentError("invalid weight; must be integer in [1, 512]","providers[".concat(t,"].weight"),a),Object.freeze(n)})),o=i.reduce((function(e,t){return e+t.weight}),0);null==n?n=o/2:n>o&&Lt.throwArgumentError("quorum will always fail; larger than total weight","quorum",n);var s=Ft(i.map((function(e){return e.provider.network})));return null==s&&(s=new Promise((function(e,t){setTimeout((function(){a.detectNetwork().then(e,t)}),0)}))),a=t.call(this,s),Object(x.defineReadOnly)(Object(c.a)(a),"providerConfigs",Object.freeze(i)),Object(x.defineReadOnly)(Object(c.a)(a),"quorum",n),a._highestBlockNumber=-1,a}return Object(b.a)(r,[{key:"detectNetwork",value:function(){return Bt(this,void 0,void 0,p.a.mark((function e(){var t;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Promise.all(this.providerConfigs.map((function(e){return e.provider.getNetwork()})));case 2:return t=e.sent,e.abrupt("return",Ft(t));case 4:case"end":return e.stop()}}),e,this)})))}},{key:"perform",value:function(e,t){return Bt(this,void 0,void 0,p.a.mark((function r(){var n,a,i,o,c,s,f,d,u,l,b=this;return p.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if("sendTransaction"!==e){r.next=13;break}return r.next=3,Promise.all(this.providerConfigs.map((function(e){return e.provider.sendTransaction(t.signedTransaction).then((function(e){return e.hash}),(function(e){return e}))})));case 3:n=r.sent,a=0;case 5:if(!(a=b.quorum)){r.next=19;break}if(void 0===(h=o(l))){r.next=15;break}return c.forEach((function(e){e.staller&&e.staller.cancel(),e.cancelled=!0})),r.abrupt("return",{v:h});case 15:if(d){r.next=18;break}return r.next=18,Ht(100).getPromise();case 18:d=!1;case 19:if(m=c.reduce((function(e,t){if(!t.done||null==t.error)return e;var r=t.error.code;return qt.indexOf(r)>=0&&(e[r]||(e[r]={error:t.error,weight:0}),e[r].weight+=t.weight),e}),{}),Object.keys(m).forEach((function(e){var t=m[e];if(!(t.weight=t?e.call(null):n.id=requestAnimationFrame(a)}))};return n}var b=null;function h(e){if(void 0===e&&(e=!1),null===b||e){var t=document.createElement("div"),r=t.style;r.width="50px",r.height="50px",r.overflow="scroll",r.direction="rtl";var n=document.createElement("div"),a=n.style;return a.width="100px",a.height="100px",t.appendChild(n),document.body.appendChild(t),t.scrollLeft>0?b="positive-descending":(t.scrollLeft=1,b=0===t.scrollLeft?"negative":"positive-ascending"),document.body.removeChild(t),b}return b}var p=function(e,t){return e};function m(e){var t,r,o=e.getItemOffset,c=e.getEstimatedTotalSize,d=e.getItemSize,b=e.getOffsetForIndexAndAlignment,m=e.getStartIndexForOffset,g=e.getStopIndexForStartIndex,x=e.initInstanceProps,y=e.shouldResetStyleCacheOnItemSizeChange,w=e.validateProps;return r=t=function(e){function t(t){var r;return(r=e.call(this,t)||this)._instanceProps=x(r.props,Object(i.a)(Object(i.a)(r))),r._outerRef=void 0,r._resetIsScrollingTimeoutId=null,r.state={instance:Object(i.a)(Object(i.a)(r)),isScrolling:!1,scrollDirection:"forward",scrollOffset:"number"===typeof r.props.initialScrollOffset?r.props.initialScrollOffset:0,scrollUpdateWasRequested:!1},r._callOnItemsRendered=void 0,r._callOnItemsRendered=s((function(e,t,n,a){return r.props.onItemsRendered({overscanStartIndex:e,overscanStopIndex:t,visibleStartIndex:n,visibleStopIndex:a})})),r._callOnScroll=void 0,r._callOnScroll=s((function(e,t,n){return r.props.onScroll({scrollDirection:e,scrollOffset:t,scrollUpdateWasRequested:n})})),r._getItemStyle=void 0,r._getItemStyle=function(e){var t,n=r.props,a=n.direction,i=n.itemSize,c=n.layout,s=r._getItemStyleCache(y&&i,y&&c,y&&a);if(s.hasOwnProperty(e))t=s[e];else{var f=o(r.props,e,r._instanceProps),u=d(r.props,e,r._instanceProps),l="horizontal"===a||"horizontal"===c,b="rtl"===a,h=l?f:0;s[e]=t={position:"absolute",left:b?void 0:h,right:b?h:void 0,top:l?0:f,height:l?"100%":u,width:l?u:"100%"}}return t},r._getItemStyleCache=void 0,r._getItemStyleCache=s((function(e,t,r){return{}})),r._onScrollHorizontal=function(e){var t=e.currentTarget,n=t.clientWidth,a=t.scrollLeft,i=t.scrollWidth;r.setState((function(e){if(e.scrollOffset===a)return null;var t=r.props.direction,o=a;if("rtl"===t)switch(h()){case"negative":o=-a;break;case"positive-descending":o=i-n-a}return o=Math.max(0,Math.min(o,i-n)),{isScrolling:!0,scrollDirection:e.scrollOffset0)for(var T=E;T<=O;T++)A.push(Object(f.createElement)(t,{data:l,key:h(T,l),index:T,isScrolling:y?k:void 0,style:this._getItemStyle(T)}));var j=c(this.props,this._instanceProps);return Object(f.createElement)(v||g||"div",{className:r,onScroll:M,ref:this._outerRefSetter,style:Object(n.a)({position:"relative",height:i,width:w,overflow:"auto",WebkitOverflowScrolling:"touch",willChange:"transform",direction:a},x)},Object(f.createElement)(s||d||"div",{children:A,ref:o,style:{height:_?"100%":j,pointerEvents:k?"none":void 0,width:_?j:"100%"}}))},r._callPropsCallbacks=function(){if("function"===typeof this.props.onItemsRendered&&this.props.itemCount>0){var e=this._getRangeToRender(),t=e[0],r=e[1],n=e[2],a=e[3];this._callOnItemsRendered(t,r,n,a)}if("function"===typeof this.props.onScroll){var i=this.state,o=i.scrollDirection,c=i.scrollOffset,s=i.scrollUpdateWasRequested;this._callOnScroll(o,c,s)}},r._getRangeToRender=function(){var e=this.props,t=e.itemCount,r=e.overscanCount,n=this.state,a=n.isScrolling,i=n.scrollDirection,o=n.scrollOffset;if(0===t)return[0,0,0,0];var c=m(this.props,o,this._instanceProps),s=g(this.props,c,o,this._instanceProps),f=a&&"backward"!==i?1:Math.max(1,r),d=a&&"forward"!==i?1:Math.max(1,r);return[Math.max(0,c-f),Math.max(0,Math.min(t-1,s+d)),c,s]},t}(f.PureComponent),t.defaultProps={direction:"ltr",itemData:void 0,layout:"vertical",overscanCount:2,useIsScrolling:!1},r}var v=function(e,t){e.children,e.direction,e.height,e.layout,e.innerTagName,e.outerTagName,e.width,t.instance},g=m({getItemOffset:function(e,t){return t*e.itemSize},getItemSize:function(e,t){return e.itemSize},getEstimatedTotalSize:function(e){var t=e.itemCount;return e.itemSize*t},getOffsetForIndexAndAlignment:function(e,t,r,n){var a=e.direction,i=e.height,o=e.itemCount,c=e.itemSize,s=e.layout,f=e.width,d="horizontal"===a||"horizontal"===s?f:i,u=Math.max(0,o*c-d),l=Math.min(u,t*c),b=Math.max(0,t*c-d+c);switch("smart"===r&&(r=n>=b-d&&n<=l+d?"auto":"center"),r){case"start":return l;case"end":return b;case"center":var h=Math.round(b+(l-b)/2);return hu+Math.floor(d/2)?u:h;case"auto":default:return n>=b&&n<=l?n:n256||t[2]&&t[2]!==String(n))&&m.throwArgumentError("invalid numeric width","type",e);var a=w.mask(r?n-1:n),i=r?a.add(y).mul(g):x;return function(t){var r=s.a.from(t);return(r.lt(i)||r.gt(a))&&m.throwArgumentError("value out-of-bounds for ".concat(e),"value",t),Object(f.g)(r.toTwos(256).toHexString(),32)}}var o=e.match(/^bytes(\d+)$/);if(o){var u=parseInt(o[1]);return(0===u||u>32||o[1]!==String(u))&&m.throwArgumentError("invalid bytes width","type",e),function(t){return Object(f.a)(t).length!==u&&m.throwArgumentError("invalid length for ".concat(e),"value",t),function(e){var t=Object(f.a)(e),r=t.length%32;return r?Object(f.c)([t,v.slice(r)]):Object(f.h)(t)}(t)}}switch(e){case"address":return function(e){return Object(f.g)(Object(c.a)(e),32)};case"bool":return function(e){return e?k:_};case"bytes":return function(e){return Object(d.a)(e)};case"string":return function(e){return Object(h.a)(e)}}return null}function T(e,t){return"".concat(e,"(").concat(t.map((function(e){var t=e.name;return e.type+" "+t})).join(","),")")}var j=function(){function e(t){Object(i.a)(this,e),Object(u.d)(this,"types",Object.freeze(Object(u.c)(t))),Object(u.d)(this,"_encoderCache",{}),Object(u.d)(this,"_types",{});var r={},n={},a={};Object.keys(t).forEach((function(e){r[e]={},n[e]=[],a[e]={}}));var o=function(e){var a={};t[e].forEach((function(i){a[i.name]&&m.throwArgumentError("duplicate variable name ".concat(JSON.stringify(i.name)," in ").concat(JSON.stringify(e)),"types",t),a[i.name]=!0;var o=i.type.match(/^([^\x5b]*)(\x5b|$)/)[1];o===e&&m.throwArgumentError("circular type reference to ".concat(JSON.stringify(o)),"types",t),A(o)||(n[o]||m.throwArgumentError("unknown type ".concat(JSON.stringify(o)),"types",t),n[o].push(e),r[e][o]=!0)}))};for(var c in t)o(c);var s=Object.keys(n).filter((function(e){return 0===n[e].length}));for(var f in 0===s.length?m.throwArgumentError("missing primary type","types",t):s.length>1&&m.throwArgumentError("ambiguous primary types or unused types: ".concat(s.map((function(e){return JSON.stringify(e)})).join(", ")),"types",t),Object(u.d)(this,"primaryType",s[0]),function e(i,o){o[i]&&m.throwArgumentError("circular type reference to ".concat(JSON.stringify(i)),"types",t),o[i]=!0,Object.keys(r[i]).forEach((function(t){n[t]&&(e(t,o),Object.keys(o).forEach((function(e){a[e][t]=!0})))})),delete o[i]}(this.primaryType,{}),a){var d=Object.keys(a[f]);d.sort(),this._types[f]=T(f,t[f])+d.map((function(e){return T(e,t[e])})).join("")}}return Object(o.a)(e,[{key:"getEncoder",value:function(e){var t=this._encoderCache[e];return t||(t=this._encoderCache[e]=this._getEncoder(e)),t}},{key:"_getEncoder",value:function(e){var t=this,r=A(e);if(r)return r;var n=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(n){var a=n[1],i=this.getEncoder(a),o=parseInt(n[3]);return function(e){o>=0&&e.length!==o&&m.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",e);var r=e.map(i);return t._types[a]&&(r=r.map(d.a)),Object(d.a)(Object(f.c)(r))}}var c=this.types[e];if(c){var s=Object(h.a)(this._types[e]);return function(e){var r=c.map((function(r){var n=r.name,a=r.type,i=t.getEncoder(a)(e[n]);return t._types[a]?Object(d.a)(i):i}));return r.unshift(s),Object(f.c)(r)}}return m.throwArgumentError("unknown type: ".concat(e),"type",e)}},{key:"encodeType",value:function(e){var t=this._types[e];return t||m.throwArgumentError("unknown type: ".concat(JSON.stringify(e)),"name",e),t}},{key:"encodeData",value:function(e,t){return this.getEncoder(e)(t)}},{key:"hashStruct",value:function(e,t){return Object(d.a)(this.encodeData(e,t))}},{key:"encode",value:function(e){return this.encodeData(this.primaryType,e)}},{key:"hash",value:function(e){return this.hashStruct(this.primaryType,e)}},{key:"_visit",value:function(e,t,r){var n=this;if(A(e))return r(e,t);var a=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(a){var i=a[1],o=parseInt(a[3]);return o>=0&&t.length!==o&&m.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",t),t.map((function(e){return n._visit(i,e,r)}))}var c=this.types[e];return c?c.reduce((function(e,a){var i=a.name,o=a.type;return e[i]=n._visit(o,t[i],r),e}),{}):m.throwArgumentError("unknown type: ".concat(e),"type",e)}},{key:"visit",value:function(e,t){return this._visit(this.primaryType,e,t)}}],[{key:"from",value:function(t){return new e(t)}},{key:"getPrimaryType",value:function(t){return e.from(t).primaryType}},{key:"hashStruct",value:function(t,r,n){return e.from(r).hashStruct(t,n)}},{key:"hashDomain",value:function(t){var r=[];for(var n in t){var a=M[n];a||m.throwArgumentError("invalid typed-data domain key: ".concat(JSON.stringify(n)),"domain",t),r.push({name:n,type:a})}return r.sort((function(e,t){return S.indexOf(e.name)-S.indexOf(t.name)})),e.hashStruct("EIP712Domain",{EIP712Domain:r},t)}},{key:"encode",value:function(t,r,n){return Object(f.c)(["0x1901",e.hashDomain(t),e.from(r).hash(n)])}},{key:"hash",value:function(t,r,n){return Object(d.a)(e.encode(t,r,n))}},{key:"resolveNames",value:function(t,r,n,i){return p(this,void 0,void 0,a.a.mark((function o(){var c,s,d;return a.a.wrap((function(o){for(;;)switch(o.prev=o.next){case 0:t=Object(u.g)(t),c={},t.verifyingContract&&!Object(f.k)(t.verifyingContract,20)&&(c[t.verifyingContract]="0x"),(s=e.from(r)).visit(n,(function(e,t){return"address"!==e||Object(f.k)(t,20)||(c[t]="0x"),t})),o.t0=a.a.keys(c);case 6:if((o.t1=o.t0()).done){o.next=13;break}return d=o.t1.value,o.next=10,i(d);case 10:c[d]=o.sent,o.next=6;break;case 13:return t.verifyingContract&&c[t.verifyingContract]&&(t.verifyingContract=c[t.verifyingContract]),n=s.visit(n,(function(e,t){return"address"===e&&c[t]?c[t]:t})),o.abrupt("return",{domain:t,value:n});case 16:case"end":return o.stop()}}),o)})))}},{key:"getPayload",value:function(t,r,n){e.hashDomain(t);var a={},i=[];S.forEach((function(e){var r=t[e];null!=r&&(a[e]=O[e](r),i.push({name:e,type:M[e]}))}));var o=e.from(r),c=Object(u.g)(r);return c.EIP712Domain?m.throwArgumentError("types must not contain EIP712Domain type","types.EIP712Domain",r):c.EIP712Domain=i,o.encode(n),{types:c,domain:a,primaryType:o.primaryType,message:o.visit(n,(function(e,t){if(e.match(/^bytes(\d*)/))return Object(f.h)(Object(f.a)(t));if(e.match(/^u?int/))return s.a.from(t).toString();switch(e){case"address":return t.toLowerCase();case"bool":return!!t;case"string":return"string"!==typeof t&&m.throwArgumentError("invalid string","value",t),t}return m.throwArgumentError("unsupported type","type",e)}))}}}]),e}()},function(e,t,r){"use strict";r.d(t,"b",(function(){return f})),r.d(t,"c",(function(){return d})),r.d(t,"a",(function(){return u}));var n=r(47),a=r.n(n),i=r(5),o=r(536),c=r(11),s=new c.a("sha2/5.5.0");function f(e){return"0x"+a.a.ripemd160().update(Object(i.a)(e)).digest("hex")}function d(e){return"0x"+a.a.sha256().update(Object(i.a)(e)).digest("hex")}function u(e,t,r){return o.a[e]||s.throwError("unsupported algorithm "+e,c.a.errors.UNSUPPORTED_OPERATION,{operation:"hmac",algorithm:e}),"0x"+a.a.hmac(a.a[e],Object(i.a)(t)).update(Object(i.a)(r)).digest("hex")}},function(e,t,r){var n=r(782),a=r(783),i=r(299),o=r(784);e.exports=function(e){return n(e)||a(e)||i(e)||o()}},function(e,t){function r(t){return e.exports=r=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},r(t)}e.exports=r},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(655),a=r(582);t.keccak224=n.createHashFunction((function(){return a("keccak224")})),t.keccak256=n.createHashFunction((function(){return a("keccak256")})),t.keccak384=n.createHashFunction((function(){return a("keccak384")})),t.keccak512=n.createHashFunction((function(){return a("keccak512")}))},function(e,t,r){var n=r(581);e.exports=function(e){return"string"!==typeof e?e:n(e)?e.slice(2):e}},function(e,t){e.exports=function(e){if("string"!==typeof e)throw new Error("[is-hex-prefixed] value must be type 'string', is currently type "+typeof e+", while checking isHexPrefixed.");return"0x"===e.slice(0,2)}},function(e,t,r){e.exports=r(656)(r(669))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(721));var n=r(312);t.XMLHttpRequestEventTarget=n.XMLHttpRequestEventTarget},function(e,t,r){var n=r(387),a=r(405);function i(t,r,o){return a()?e.exports=i=Reflect.construct:e.exports=i=function(e,t,r){var a=[null];a.push.apply(a,t);var i=new(Function.bind.apply(e,a));return r&&n(i,r.prototype),i},i.apply(null,arguments)}e.exports=i},function(e,t,r){"use strict";var n=new RegExp("%[a-f0-9]{2}","gi"),a=new RegExp("(%[a-f0-9]{2})+","gi");function i(e,t){try{return decodeURIComponent(e.join(""))}catch(a){}if(1===e.length)return e;t=t||1;var r=e.slice(0,t),n=e.slice(t);return Array.prototype.concat.call([],i(r),i(n))}function o(e){try{return decodeURIComponent(e)}catch(a){for(var t=e.match(n),r=1;r