From 4c1b8311ef3b5d3a75be24af581de4287f492f33 Mon Sep 17 00:00:00 2001 From: Julien Genestoux Date: Tue, 16 Apr 2024 15:13:53 -0400 Subject: [PATCH] Production Deploy (#13636) Manual deploy as of commit:7028c0149d7621a0f9455029f25615cf563e361d --- README.md | 1 + docker/development/eth-node/yarn.lock | 12 +- docs/package.json | 7 +- docs/src/.eslintrc.js | 3 + docs/src/theme/SearchBar/index.js | 24 + governance/README.md | 46 + governance/hardhat.config.js | 1 + governance/helpers/bridge/abis/IConnext.js | 51 + governance/helpers/bridge/abis/IXCalled.js | 124 + .../_lib.js => helpers/bridge/delayMod.js} | 275 +- governance/helpers/bridge/index.js | 11 + governance/helpers/bridge/xCall.js | 153 + governance/helpers/multisig.js | 47 +- governance/package.json | 5 + .../proposals/006-cross-bridge-proposal.js | 64 +- governance/proposals/009-protocol-upgrade.js | 118 +- .../proposals/010-arbitrum-l1-l2-messaging.js | 215 ++ governance/proposals/010-test-multicall.js | 40 + governance/scripts/bridge/execTx.js | 167 +- .../scripts/bridge/{bump.js => payFee.js} | 4 +- governance/scripts/bridge/status.js | 15 +- .../scripts/deployments/OPBridgedERC20.js | 95 + governance/scripts/deployments/swapBurner.js | 2 +- governance/scripts/gov/execute.js | 2 +- governance/scripts/gov/index.js | 4 +- governance/scripts/gov/queue.js | 3 +- governance/scripts/gov/submit.js | 2 +- governance/scripts/lock/purchase.js | 62 +- governance/scripts/multisig/submitTx.js | 25 +- .../udt/bridge/abi/l1standardbridge.json | 521 +++ governance/scripts/udt/bridge/arb.js | 133 + governance/scripts/udt/bridge/base.js | 124 + governance/scripts/udt/bridge/op.js | 110 + governance/scripts/uniswap/oracle.js | 73 + governance/tasks/gov.js | 3 +- governance/tasks/uniswap.js | 14 + locksmith/.op.env.production | 2 + locksmith/.op.env.staging | 4 +- locksmith/__tests__/utils/gasPrice.test.ts | 21 +- locksmith/__tests__/worker/renewKey.test.ts | 21 +- ...gitcoin-passport-score-to-lock-settings.js | 19 + locksmith/package.json | 4 +- locksmith/src/config/config.ts | 9 + .../src/controllers/v2/eventsController.ts | 4 +- .../src/controllers/v2/hooksController.ts | 149 + .../controllers/v2/lockSettingController.ts | 10 + .../src/controllers/v2/rsvpController.ts | 4 +- locksmith/src/fulfillment/dispatcher.ts | 16 +- locksmith/src/models/lockSetting.ts | 6 + locksmith/src/operations/eventOperations.ts | 29 +- .../src/operations/gitcoinVerification.ts | 163 + .../src/operations/lockSettingOperations.ts | 18 +- .../src/operations/metadataOperations.ts | 26 +- locksmith/src/operations/pricingOperations.ts | 1 - .../src/operations/wedlocksOperations.ts | 4 +- locksmith/src/routes/v2/hooks.ts | 4 +- locksmith/src/routes/v2/images.ts | 1 - locksmith/src/utils/ethPrice.ts | 25 - locksmith/src/utils/gasPrice.ts | 15 +- locksmith/src/utils/keyPricer.ts | 31 +- locksmith/src/utils/priceConversion.ts | 46 - locksmith/src/worker/helpers/renewKey.ts | 24 +- packages/contracts/CHANGELOG.md | 6 +- packages/contracts/package.json | 2 +- .../src/abis/utils/UnlockSwapBurner.json | 10 +- .../src/contracts/utils/UnlockSwapBurner.sol | 300 +- packages/core/src/schema.ts | 2 + packages/crypto-icon/.storybook/main.ts | 13 +- packages/crypto-icon/package.json | 3 +- .../email-templates/src/templates/custom.ts | 2 +- packages/hardhat-helpers/src/fork.js | 8 +- packages/networks/bin/check-tokens.ts | 15 +- packages/networks/bin/doc.js | 6 +- packages/networks/src/networks/arbitrum.ts | 9 + .../networks/src/networks/base-sepolia.ts | 14 +- packages/networks/src/networks/base.ts | 8 + packages/networks/src/networks/bsc.ts | 5 + packages/networks/src/networks/gnosis.ts | 5 + packages/networks/src/networks/linea.ts | 2 +- packages/networks/src/networks/optimism.ts | 9 + packages/networks/src/networks/sepolia.ts | 3 +- packages/networks/src/networks/zkevm.ts | 1 + packages/networks/src/networks/zksync.ts | 3 +- packages/paywall/package.json | 2 +- packages/types/src/types/unlockTypes.ts | 2 +- packages/ui/.storybook/main.ts | 13 +- .../lib/components/Form/Checkbox.stories.tsx | 25 + packages/ui/lib/components/Form/Checkbox.tsx | 43 + packages/ui/lib/components/Form/index.tsx | 1 + .../PriceFormatter/PriceFormatter.stories.tsx | 74 + .../PriceFormatter/PriceFormatter.tsx | 57 + .../components/PriceFormatter/formatPrice.ts | 59 + .../ui/lib/components/Tooltip/Tooltip.tsx | 33 +- packages/ui/lib/index.tsx | 9 +- packages/ui/package.json | 3 +- packages/unlock-js/openapi.yml | 38 + packages/unlock-js/src/web3Service.ts | 1 + paywall-app/package.json | 4 +- .../contracts/interfaces/IUniversalRouter.sol | 37 + .../contracts/utils/UnlockSwapBurner.sol | 61 +- smart-contracts/scripts/hooks/GitcoinHook.js | 32 +- smart-contracts/scripts/hooks/GuildHook.js | 7 +- .../UnlockSwapBurner/swapAndBurn.mainnet.js | 25 +- unlock-app/.gitignore | 2 + .../frames/event/Components/Description.tsx | 11 +- unlock-app/package.json | 5 +- .../components/content/KeychainContent.tsx | 30 +- .../components/content/event/CastItButton.tsx | 4 +- .../content/event/CoverImageDrawer.tsx | 2 +- .../components/content/event/EventDetails.tsx | 88 +- .../src/components/content/event/Form.tsx | 33 + .../src/components/content/event/Hosts.tsx | 77 + .../event/Settings/Components/CustomEmail.tsx | 229 ++ .../Settings/Components/SenderSettings.tsx | 84 + .../content/event/Settings/Emails.tsx | 41 + .../content/event/Settings/EventSettings.tsx | 7 + .../Receipts/elements/ReceiptBox.tsx | 14 +- .../interface/checkout/ViewContract.tsx | 26 - .../checkout/main/Confirm/ConfirmCard.tsx | 6 +- .../checkout/main/Confirm/ConfirmClaim.tsx | 6 +- .../Confirm/ConfirmCrossChainPurchase.tsx | 6 +- .../main/Confirm/ConfirmCrossmint.tsx | 9 +- .../checkout/main/Confirm/ConfirmCrypto.tsx | 6 +- .../main/Confirm/ConfirmSwapAndPurchase.tsx | 6 +- .../interface/checkout/main/Gitcoin.tsx | 314 ++ .../interface/checkout/main/Quantity.tsx | 5 - .../interface/checkout/main/Select.tsx | 5 - .../checkout/main/checkoutMachine.ts | 51 +- .../checkout/main/checkoutMachine.typegen.ts | 2 + .../interface/checkout/main/index.tsx | 11 +- .../checkout/main/useCheckoutHook.ts | 1 + .../checkout/main/useStepperItems.ts | 6 + .../keychain/CancelAndRefundModal.tsx | 9 +- .../components/interface/keychain/Extend.tsx | 4 +- .../src/components/interface/keychain/Key.tsx | 261 +- .../interface/keychain/KeyDetails.tsx | 65 +- .../interface/keychain/KeyInfoDrawer.tsx | 14 +- .../interface/keychain/OwnerSocials.tsx | 66 + .../CheckoutUrl/elements/BasicConfigForm.tsx | 42 +- .../locks/CheckoutUrl/elements/LocksForm.tsx | 6 +- .../locks/Create/elements/NetworkWarning.tsx | 2 - .../locks/List/elements/LockCard.tsx | 10 +- .../locks/Manage/elements/LockDetailCard.tsx | 9 +- .../locks/Manage/elements/MetadataCard.tsx | 75 +- .../locks/Manage/elements/TotalBar.tsx | 11 +- .../locks/Settings/forms/UpdateHooksForm.tsx | 12 +- .../locks/Settings/forms/UpdatePriceForm.tsx | 2 +- .../hooksComponents/GitcoinContractHook.tsx | 84 + .../hooksComponents/PasswordContractHook.tsx | 121 - .../src/hooks/useDataForGitcoinPassport.ts | 83 + unlock-app/src/hooks/useEventOrganizers.ts | 66 + unlock-app/src/hooks/useKeys.ts | 1 + unlock-app/src/hooks/useLockData.ts | 8 +- unlock-app/src/hooks/useLockSettings.ts | 1 + unlock-app/src/hooks/useSocials.ts | 88 + unlock-app/src/pages/_app.tsx | 5 +- unlock-app/src/utils/checkoutLockUtils.ts | 5 +- unlock-app/src/utils/truncateString.ts | 14 + yarn.lock | 2865 +++++++++-------- 159 files changed, 6253 insertions(+), 2927 deletions(-) create mode 100644 docs/src/.eslintrc.js create mode 100644 docs/src/theme/SearchBar/index.js create mode 100644 governance/helpers/bridge/abis/IConnext.js create mode 100644 governance/helpers/bridge/abis/IXCalled.js rename governance/{scripts/bridge/_lib.js => helpers/bridge/delayMod.js} (63%) create mode 100644 governance/helpers/bridge/index.js create mode 100644 governance/helpers/bridge/xCall.js create mode 100644 governance/proposals/010-arbitrum-l1-l2-messaging.js create mode 100644 governance/proposals/010-test-multicall.js rename governance/scripts/bridge/{bump.js => payFee.js} (96%) create mode 100644 governance/scripts/deployments/OPBridgedERC20.js create mode 100644 governance/scripts/udt/bridge/abi/l1standardbridge.json create mode 100644 governance/scripts/udt/bridge/arb.js create mode 100644 governance/scripts/udt/bridge/base.js create mode 100644 governance/scripts/udt/bridge/op.js create mode 100644 governance/scripts/uniswap/oracle.js create mode 100644 governance/tasks/uniswap.js create mode 100644 locksmith/migrations/20240404214415-add-required-gitcoin-passport-score-to-lock-settings.js create mode 100644 locksmith/src/operations/gitcoinVerification.ts delete mode 100644 locksmith/src/utils/ethPrice.ts delete mode 100644 locksmith/src/utils/priceConversion.ts create mode 100644 packages/ui/lib/components/Form/Checkbox.stories.tsx create mode 100644 packages/ui/lib/components/Form/Checkbox.tsx create mode 100644 packages/ui/lib/components/PriceFormatter/PriceFormatter.stories.tsx create mode 100644 packages/ui/lib/components/PriceFormatter/PriceFormatter.tsx create mode 100644 packages/ui/lib/components/PriceFormatter/formatPrice.ts create mode 100644 smart-contracts/contracts/interfaces/IUniversalRouter.sol create mode 100644 unlock-app/src/components/content/event/Hosts.tsx create mode 100644 unlock-app/src/components/content/event/Settings/Components/CustomEmail.tsx create mode 100644 unlock-app/src/components/content/event/Settings/Components/SenderSettings.tsx create mode 100644 unlock-app/src/components/content/event/Settings/Emails.tsx delete mode 100644 unlock-app/src/components/interface/checkout/ViewContract.tsx create mode 100644 unlock-app/src/components/interface/checkout/main/Gitcoin.tsx create mode 100644 unlock-app/src/components/interface/keychain/OwnerSocials.tsx create mode 100644 unlock-app/src/components/interface/locks/Settings/forms/hooksComponents/GitcoinContractHook.tsx delete mode 100644 unlock-app/src/components/interface/locks/Settings/forms/hooksComponents/PasswordContractHook.tsx create mode 100644 unlock-app/src/hooks/useDataForGitcoinPassport.ts create mode 100644 unlock-app/src/hooks/useEventOrganizers.ts create mode 100644 unlock-app/src/hooks/useSocials.ts create mode 100644 unlock-app/src/utils/truncateString.ts diff --git a/README.md b/README.md index 417fe2cfa4c..c5e4feb1dac 100644 --- a/README.md +++ b/README.md @@ -30,6 +30,7 @@ Please read more about contributing in our [contributor guide](https://github.co Unlock uses a monorepo which includes all the services and applications we develop. ``` + # get the code git clone https://github.com/unlock-protocol/unlock cd unlock diff --git a/docker/development/eth-node/yarn.lock b/docker/development/eth-node/yarn.lock index cf574eee095..5bb713a6c2b 100644 --- a/docker/development/eth-node/yarn.lock +++ b/docker/development/eth-node/yarn.lock @@ -1094,11 +1094,11 @@ __metadata: linkType: hard "@types/node@npm:*": - version: 20.12.2 - resolution: "@types/node@npm:20.12.2" + version: 20.12.4 + resolution: "@types/node@npm:20.12.4" dependencies: undici-types: "npm:~5.26.4" - checksum: 10/f1f0ebfe475aefa183763b856e0023b81b76554196e8676a45b9fcfd1012cdd20d32adefb3c0330001c0011e074676603c34c24821a4924228250ea13a75da43 + checksum: 10/eab4ed07774b96ea77fc23eb27508dbfe094b52c8326764f5044c609c036a1570fd8708ba770e13db7ad7b69d8a834bf3a4e59fc2f1ade31d6501db76cf5a39b languageName: node linkType: hard @@ -4188,11 +4188,11 @@ __metadata: linkType: hard "undici@npm:^5.14.0": - version: 5.28.3 - resolution: "undici@npm:5.28.3" + version: 5.28.4 + resolution: "undici@npm:5.28.4" dependencies: "@fastify/busboy": "npm:^2.0.0" - checksum: 10/779856ce14ba6907c0759df8e4babd61608b1f502569d44de7dd1d014afb7c67a0a2997b4f706e0daff8a55d87ee2f25b830b195fc0202cb6fbd25abe2d941eb + checksum: 10/a666a9f5ac4270c659fafc33d78b6b5039a0adbae3e28f934774c85dcc66ea91da907896f12b414bd6f578508b44d5dc206fa636afa0e49a4e1c9e99831ff065 languageName: node linkType: hard diff --git a/docs/package.json b/docs/package.json index 8fc5d3f6821..e94b087c915 100644 --- a/docs/package.json +++ b/docs/package.json @@ -4,9 +4,10 @@ "private": true, "dependencies": { "@babel/helper-get-function-arity": "7.16.7", - "@docusaurus/core": "3.1.1", - "@docusaurus/plugin-client-redirects": "3.1.1", - "@docusaurus/plugin-content-docs": "3.1.1", + "@cookbookdev/docsbot": "4.5.0", + "@docusaurus/core": "3.2.1", + "@docusaurus/plugin-client-redirects": "3.2.1", + "@docusaurus/plugin-content-docs": "3.2.1", "@flockler/react-flockler-embed": "1.0.4", "@mdx-js/react": "3.0.1", "@unlock-protocol/networks": "workspace:./packages/networks", diff --git a/docs/src/.eslintrc.js b/docs/src/.eslintrc.js new file mode 100644 index 00000000000..83fbbaa5cd6 --- /dev/null +++ b/docs/src/.eslintrc.js @@ -0,0 +1,3 @@ +module.exports = { + extends: ['@unlock-protocol/eslint-config'], +} diff --git a/docs/src/theme/SearchBar/index.js b/docs/src/theme/SearchBar/index.js new file mode 100644 index 00000000000..050584ef62c --- /dev/null +++ b/docs/src/theme/SearchBar/index.js @@ -0,0 +1,24 @@ +import React from 'react' +import SearchBar from '@theme-original/SearchBar' +import BrowserOnly from '@docusaurus/BrowserOnly' + +export default function SearchBarWrapper(props) { + return ( + <> + + + {() => { + const AskCookbook = require('@cookbookdev/docsbot/react-fixed') + return ( + + ) + }} + + + ) +} + +// Ask Cookbook API key obtainable at https://cms.cookbook.dev with an invite from an admin of the project. diff --git a/governance/README.md b/governance/README.md index aa8f451c74c..86c99c4a4ff 100644 --- a/governance/README.md +++ b/governance/README.md @@ -234,3 +234,49 @@ Edit directly the amounts and prices in the script ``` yarn run scripts/uniswap/addLiquidity.js ``` + +## Cross-Chain DAO Proposals + +To maintain the integrity of the protocol accross various chains, we use a pattern of DAO proposals that allows execution on multiple chains. Messaging is sent accross the [Connext bridge](https://connext.network) to all supported chains. + +### Prepare a cross-chain proposal + +#### Write a cross-chain DAO proposal + +Read the explanations and follow the template in [`./proposals/006-cross-bridge-proposal.js`](./proposals/006-cross-bridge-proposal.js) to submit a cross-chain proposal to the DAO. + +#### Test a cross-chain DAO proposal + +To make sure all calls can be executed properly, you can use Tenderly forks to test execution of calls on each destination chains. + +### After proposal execution + +#### Pay bridge fees + +Each transaction contained in the proposal is sent separately to the bridge. For each tx, the bridge fee needs to be paid on origin chain (mainnet) for the txs to proceed. To pay all fees for the bridge, use the following script: + +``` +# update the txId accordingly +yarn hardhat run scripts/bridge/payFee.js --network mainnet +``` + +#### Check status of the calls + +You can check the status of all calls on various chains manually with the [Connext explorer](https://connextscan.io/) or directly parse calls from the execution tx using the following script: + +``` +# update the txId accordingly +yarn hardhat run scripts/bridge/status.js --network mainnet +``` + +NB: This will create a temporary JSON file named `xcalled.json.tmp` with the info and statuses of all tx. + +### Execute all tx on destination chains + +Once all calls have crossed the bridges they stay in cooldown in multisigs. Once cooldown ends, they can be executed. To execute the calls, use the following command _for each network_: + +``` +yarn hardhat run scripts/bridge/execTx.js --network optimism +``` + +NB: The tmp file with all txs statuses is required, so you need to first run the "Check status" step above diff --git a/governance/hardhat.config.js b/governance/hardhat.config.js index abdd43c63ad..41b9e5deec0 100644 --- a/governance/hardhat.config.js +++ b/governance/hardhat.config.js @@ -58,6 +58,7 @@ require('./tasks/deploy') require('./tasks/set') require('./tasks/unlock') require('./tasks/lock') +require('./tasks/uniswap') /** * @type import('hardhat/config').HardhatUserConfig diff --git a/governance/helpers/bridge/abis/IConnext.js b/governance/helpers/bridge/abis/IConnext.js new file mode 100644 index 00000000000..0d8d00bde42 --- /dev/null +++ b/governance/helpers/bridge/abis/IConnext.js @@ -0,0 +1,51 @@ +module.exports = [ + { + inputs: [ + { + internalType: 'uint32', + name: '_destination', + type: 'uint32', + }, + { + internalType: 'address', + name: '_to', + type: 'address', + }, + { + internalType: 'address', + name: '_asset', + type: 'address', + }, + { + internalType: 'address', + name: '_delegate', + type: 'address', + }, + { + internalType: 'uint256', + name: '_amount', + type: 'uint256', + }, + { + internalType: 'uint256', + name: '_slippage', + type: 'uint256', + }, + { + internalType: 'bytes', + name: '_callData', + type: 'bytes', + }, + ], + name: 'xcall', + outputs: [ + { + internalType: 'bytes32', + name: '', + type: 'bytes32', + }, + ], + stateMutability: 'payable', + type: 'function', + }, +] diff --git a/governance/helpers/bridge/abis/IXCalled.js b/governance/helpers/bridge/abis/IXCalled.js new file mode 100644 index 00000000000..5b6810f93a7 --- /dev/null +++ b/governance/helpers/bridge/abis/IXCalled.js @@ -0,0 +1,124 @@ +module.exports = [ + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: 'bytes32', + name: 'transferId', + type: 'bytes32', + }, + { + indexed: true, + internalType: 'uint256', + name: 'nonce', + type: 'uint256', + }, + { + indexed: true, + internalType: 'bytes32', + name: 'messageHash', + type: 'bytes32', + }, + { + components: [ + { + internalType: 'uint32', + name: 'originDomain', + type: 'uint32', + }, + { + internalType: 'uint32', + name: 'destinationDomain', + type: 'uint32', + }, + { + internalType: 'uint32', + name: 'canonicalDomain', + type: 'uint32', + }, + { + internalType: 'address', + name: 'to', + type: 'address', + }, + { + internalType: 'address', + name: 'delegate', + type: 'address', + }, + { + internalType: 'bool', + name: 'receiveLocal', + type: 'bool', + }, + { + internalType: 'bytes', + name: 'callData', + type: 'bytes', + }, + { + internalType: 'uint256', + name: 'slippage', + type: 'uint256', + }, + { + internalType: 'address', + name: 'originSender', + type: 'address', + }, + { + internalType: 'uint256', + name: 'bridgedAmt', + type: 'uint256', + }, + { + internalType: 'uint256', + name: 'normalizedIn', + type: 'uint256', + }, + { + internalType: 'uint256', + name: 'nonce', + type: 'uint256', + }, + { + internalType: 'bytes32', + name: 'canonicalId', + type: 'bytes32', + }, + ], + indexed: false, + internalType: 'struct TransferInfo', + name: 'params', + type: 'tuple', + }, + { + indexed: false, + internalType: 'address', + name: 'asset', + type: 'address', + }, + { + indexed: false, + internalType: 'uint256', + name: 'amount', + type: 'uint256', + }, + { + indexed: false, + internalType: 'address', + name: 'local', + type: 'address', + }, + { + indexed: false, + internalType: 'bytes', + name: 'messageBody', + type: 'bytes', + }, + ], + name: 'XCalled', + type: 'event', + }, +] diff --git a/governance/scripts/bridge/_lib.js b/governance/helpers/bridge/delayMod.js similarity index 63% rename from governance/scripts/bridge/_lib.js rename to governance/helpers/bridge/delayMod.js index f6653e05d42..62b0c9442ca 100644 --- a/governance/scripts/bridge/_lib.js +++ b/governance/helpers/bridge/delayMod.js @@ -1,266 +1,7 @@ const { ethers } = require('hardhat') -const { ADDRESS_ZERO, getNetwork } = require('@unlock-protocol/hardhat-helpers') +const { getNetwork } = require('@unlock-protocol/hardhat-helpers') const { networks } = require('@unlock-protocol/networks') -/*** - * CONNEXT logic - */ -const xCalledABI = [ - { - anonymous: false, - inputs: [ - { - indexed: true, - internalType: 'bytes32', - name: 'transferId', - type: 'bytes32', - }, - { - indexed: true, - internalType: 'uint256', - name: 'nonce', - type: 'uint256', - }, - { - indexed: true, - internalType: 'bytes32', - name: 'messageHash', - type: 'bytes32', - }, - { - components: [ - { - internalType: 'uint32', - name: 'originDomain', - type: 'uint32', - }, - { - internalType: 'uint32', - name: 'destinationDomain', - type: 'uint32', - }, - { - internalType: 'uint32', - name: 'canonicalDomain', - type: 'uint32', - }, - { - internalType: 'address', - name: 'to', - type: 'address', - }, - { - internalType: 'address', - name: 'delegate', - type: 'address', - }, - { - internalType: 'bool', - name: 'receiveLocal', - type: 'bool', - }, - { - internalType: 'bytes', - name: 'callData', - type: 'bytes', - }, - { - internalType: 'uint256', - name: 'slippage', - type: 'uint256', - }, - { - internalType: 'address', - name: 'originSender', - type: 'address', - }, - { - internalType: 'uint256', - name: 'bridgedAmt', - type: 'uint256', - }, - { - internalType: 'uint256', - name: 'normalizedIn', - type: 'uint256', - }, - { - internalType: 'uint256', - name: 'nonce', - type: 'uint256', - }, - { - internalType: 'bytes32', - name: 'canonicalId', - type: 'bytes32', - }, - ], - indexed: false, - internalType: 'struct TransferInfo', - name: 'params', - type: 'tuple', - }, - { - indexed: false, - internalType: 'address', - name: 'asset', - type: 'address', - }, - { - indexed: false, - internalType: 'uint256', - name: 'amount', - type: 'uint256', - }, - { - indexed: false, - internalType: 'address', - name: 'local', - type: 'address', - }, - { - indexed: false, - internalType: 'bytes', - name: 'messageBody', - type: 'bytes', - }, - ], - name: 'XCalled', - type: 'event', - }, -] - -const getXCalledEvents = async (hash) => { - const { interface } = await ethers.getContractAt(xCalledABI, ADDRESS_ZERO) - const { logs } = await ethers.provider.getTransactionReceipt(hash) - const parsedLogs = logs.map((log) => { - try { - return interface.parseLog(log) - } catch (error) { - return {} - } - }) - - const xCalled = parsedLogs - .filter((e) => e !== null) - .filter(({ name }) => name === 'XCalled') - .map(({ args }) => args) - - return xCalled -} - -const fetchOriginXCall = async ({ transferIds = [], chainId = 1 }) => { - const query = ` - { - originTransfers(where:{ - transferId_in: ${JSON.stringify(transferIds)} - }) { - chainId - nonce - transferId - to - delegate - receiveLocal - callData - slippage - originSender - originDomain - destinationDomain - transactionHash - bridgedAmt - status - } - } - ` - const { originTransfers } = await fetchXCall({ query, chainId }) - return originTransfers -} - -const fetchDestinationXCall = async ({ transferIds, chainId }) => { - const query = ` - { - destinationTransfers(where:{ - transferId_in: ${JSON.stringify(transferIds)} - }) { - chainId - nonce - transferId - to - delegate - receiveLocal - callData - originDomain - destinationDomain - delegate - status - executedTransactionHash - reconciledTransactionHash - } - } - ` - const { destinationTransfers } = await fetchXCall({ query, chainId }) - return destinationTransfers -} - -// supported chains by domain id -const getSupportedChainsByDomainId = async () => { - return Object.keys(networks) - .map((id) => networks[id]) - .filter( - ({ governanceBridge, isTestNetwork, id }) => - !isTestNetwork && !!governanceBridge && id != 1 - ) - .reduce( - (prev, curr) => ({ - ...prev, - [curr.governanceBridge.domainId]: curr, - }), - {} - ) -} - -const connextSubgraphIds = { - 1: `FfTxiY98LJG6zoiAjCXdT34pAmCKDEP8vZRVuC8D5Gf`, - 137: `7mDXK2K6UfkVXiJMhXU8VEFuh7qi2TwdYxeyaRjkmexo`, //plygon - 10: `3115xfkzXPrYzbqDHTiWGtzRDYNXBxs8dyitva6J18jf`, //optimims - 42161: `F325dMRiLVCJpX8EUFHg3SX8LE3kXBUmrsLRASisPEQ3`, // arb - 100: `6oJrPk9YJEU9rWU4DAizjZdALSccxe5ZahBsTtFaGksU`, //gnosis -} - -const connextSubgraphURL = (chainId) => { - // bnb is hosted version - if (chainId == 56) { - return 'https://api.thegraph.com/subgraphs/name/connext/amarok-runtime-v0-bnb' - } - const { SUBGRAPH_QUERY_API_KEY } = process.env - if (!SUBGRAPH_QUERY_API_KEY) { - throw new Error(`Missing SUBGRAPH_QUERY_API_KEY env`) - } - const subgraphId = connextSubgraphIds[chainId] - if (!subgraphId) { - throw new Error(`Unknown chain id ${chainId}`) - } - return `https://gateway-arbitrum.network.thegraph.com/api/${SUBGRAPH_QUERY_API_KEY}/subgraphs/id/${subgraphId}` -} - -const fetchXCall = async ({ query, chainId }) => { - const endpoint = connextSubgraphURL(chainId) - const q = await fetch(endpoint, { - method: 'POST', - headers: { 'Content-Type': 'application/json' }, - body: JSON.stringify({ - query, - }), - }) - - const { data, errors } = await q.json() - if (errors) { - console.log('LOCK > Error while fetching the graph', errors) - return [] - } - return data -} - /*** * Delay Mod Logic */ @@ -699,13 +440,11 @@ const getDelayModule = async (delayModuleAddress) => { } const logStatus = (transferId, status) => { - const { origin, dest } = status + const { dest } = status const { explorer, name, id } = networks[dest.chainId] - console.log(`To ${name} (${id}) - ${transferId} - - origin (${origin.status}) - tx : ${explorer.urls.transaction( - origin.transactionHash - )} - - dest (${dest.status}) + console.log(`To ${name} (${id}) https://connextscan.io/tx/${transferId} (${ + dest.status + }) - executedTransactionHash: ${explorer.urls.transaction( dest.executedTransactionHash )} @@ -716,10 +455,6 @@ const logStatus = (transferId, status) => { module.exports = { delayABI, - getXCalledEvents, - fetchOriginXCall, - fetchDestinationXCall, - getSupportedChainsByDomainId, getDelayModule, logStatus, } diff --git a/governance/helpers/bridge/index.js b/governance/helpers/bridge/index.js new file mode 100644 index 00000000000..8b261c03aca --- /dev/null +++ b/governance/helpers/bridge/index.js @@ -0,0 +1,11 @@ +const delayMod = require('./delayMod') +const xCall = require('./xCall') +const IConnext = require('./abis/IConnext') +const IXCalled = require('./abis/IXCalled') + +module.exports = { + ...delayMod, + ...xCall, + IConnext, + IXCalled, +} diff --git a/governance/helpers/bridge/xCall.js b/governance/helpers/bridge/xCall.js new file mode 100644 index 00000000000..de193379a05 --- /dev/null +++ b/governance/helpers/bridge/xCall.js @@ -0,0 +1,153 @@ +const { ethers } = require('hardhat') +const { ADDRESS_ZERO } = require('@unlock-protocol/hardhat-helpers') +const { networks } = require('@unlock-protocol/networks') +const IXCalled = require('./abis/IXCalled') + +const targetChains = Object.keys(networks) + .map((id) => networks[id]) + .filter( + ({ governanceBridge, isTestNetwork, id }) => + !isTestNetwork && !!governanceBridge && id != 1 + ) + +/*** + * CONNEXT logic + */ +const getXCalledEvents = async (hash) => { + const { interface } = await ethers.getContractAt(IXCalled, ADDRESS_ZERO) + const { logs } = await ethers.provider.getTransactionReceipt(hash) + const parsedLogs = logs.map((log) => { + try { + return interface.parseLog(log) + } catch (error) { + return {} + } + }) + + const xCalled = parsedLogs + .filter((e) => e !== null) + .filter(({ name }) => name === 'XCalled') + .map(({ args }) => args) + + return xCalled +} + +const fetchOriginXCall = async ({ transferIds = [], chainId = 1 }) => { + const query = ` + { + originTransfers(where:{ + transferId_in: ${JSON.stringify(transferIds)} + }) { + chainId + nonce + transferId + to + delegate + receiveLocal + callData + slippage + originSender + originDomain + destinationDomain + transactionHash + bridgedAmt + status + } + } + ` + const { originTransfers } = await fetchXCall({ query, chainId }) + return originTransfers +} + +const fetchDestinationXCall = async ({ transferIds, chainId }) => { + const query = ` + { + destinationTransfers(where:{ + transferId_in: ${JSON.stringify(transferIds)} + }) { + chainId + nonce + transferId + to + delegate + receiveLocal + callData + originDomain + destinationDomain + delegate + status + executedTransactionHash + reconciledTransactionHash + } + } + ` + const { destinationTransfers } = await fetchXCall({ query, chainId }) + return destinationTransfers +} + +// supported chains by domain id +const getSupportedChainsByDomainId = async () => { + return Object.keys(networks) + .map((id) => networks[id]) + .filter( + ({ governanceBridge, isTestNetwork, id }) => + !isTestNetwork && !!governanceBridge && id != 1 + ) + .reduce( + (prev, curr) => ({ + ...prev, + [curr.governanceBridge.domainId]: curr, + }), + {} + ) +} + +const connextSubgraphIds = { + 1: `FfTxiY98LJG6zoiAjCXdT34pAmCKDEP8vZRVuC8D5Gf`, + 137: `7mDXK2K6UfkVXiJMhXU8VEFuh7qi2TwdYxeyaRjkmexo`, //polygon + 10: `3115xfkzXPrYzbqDHTiWGtzRDYNXBxs8dyitva6J18jf`, //optimims + 42161: `F325dMRiLVCJpX8EUFHg3SX8LE3kXBUmrsLRASisPEQ3`, // arb + 100: `6oJrPk9YJEU9rWU4DAizjZdALSccxe5ZahBsTtFaGksU`, //gnosis +} + +const connextSubgraphURL = (chainId) => { + // bnb is hosted version + if (chainId == 56) { + return 'https://api.thegraph.com/subgraphs/name/connext/amarok-runtime-v0-bnb' + } + const { SUBGRAPH_QUERY_API_KEY } = process.env + if (!SUBGRAPH_QUERY_API_KEY) { + throw new Error(`Missing SUBGRAPH_QUERY_API_KEY env`) + } + const subgraphId = connextSubgraphIds[chainId] + if (!subgraphId) { + throw new Error(`Unknown chain id ${chainId}`) + } + return `https://gateway-arbitrum.network.thegraph.com/api/${SUBGRAPH_QUERY_API_KEY}/subgraphs/id/${subgraphId}` +} + +const fetchXCall = async ({ query, chainId }) => { + const endpoint = connextSubgraphURL(chainId) + const q = await fetch(endpoint, { + method: 'POST', + headers: { 'Content-Type': 'application/json' }, + body: JSON.stringify({ + query, + }), + }) + + const { data, errors } = await q.json() + if (errors) { + console.log('LOCK > Error while fetching the graph', errors) + return [] + } + return data +} + +module.exports = { + targetChains, + getXCalledEvents, + fetchOriginXCall, + fetchDestinationXCall, + getSupportedChainsByDomainId, +} diff --git a/governance/helpers/multisig.js b/governance/helpers/multisig.js index 439b91c7901..b758f63dde1 100644 --- a/governance/helpers/multisig.js +++ b/governance/helpers/multisig.js @@ -1,9 +1,14 @@ const { ethers } = require('hardhat') const { networks } = require('@unlock-protocol/networks') -const { getNetwork } = require('@unlock-protocol/hardhat-helpers') +const { getNetwork, ADDRESS_ZERO } = require('@unlock-protocol/hardhat-helpers') const multisigABI = require('@unlock-protocol/hardhat-helpers/dist/ABIs/multisig2.json') const multisigOldABI = require('@unlock-protocol/hardhat-helpers/dist/ABIs/multisig.json') const SafeApiKit = require('@safe-global/api-kit').default +const { + EthersAdapter, + encodeMultiSendData, +} = require('@safe-global/protocol-kit') +const Safe = require('@safe-global/protocol-kit').default // custom services URL for network not supported by Safe const safeServiceURLs = { @@ -104,7 +109,7 @@ const getMultiSigInfo = async (chainId, multisig) => { const getProvider = async (chainId) => { let provider if (chainId) { - const { publicProvider } = networks[chainId] + const { provider: publicProvider } = networks[chainId] provider = new ethers.JsonRpcProvider(publicProvider) } else { ;({ provider } = ethers) @@ -190,6 +195,43 @@ const submitTxOldMultisig = async ({ safeAddress, tx, signer }) => { return nonce } +// pack multiple calls in a single multicall +const parseSafeMulticall = async ({ calls, chainId, options }) => { + const transactions = calls.map( + ({ contractAddress, calldata = '0x', value = 0, operation = null }) => ({ + to: contractAddress, + value, + data: calldata, + operation, + }) + ) + + // init safe lib with correct provider + const { provider } = await getProvider(chainId) + const { multisig } = await getNetwork(chainId) + const ethAdapter = new EthersAdapter({ ethers, signerOrProvider: provider }) + const safe = await Safe.create({ + ethAdapter, + safeAddress: multisig, + }) + + // get multicall data from lib + const totalValue = calls.reduce( + (total, { value }) => (value || 0n) + total, + 0n + ) + const { data } = await safe.createTransaction({ + transactions, + options, + callsOnly: totalValue === 0, + }) + + // parse calls correcly for our multisig/dao helpers + data.calldata = data.data + data.contractAddress = data.to + return data +} + module.exports = { getProvider, getSafeAddress, @@ -202,4 +244,5 @@ module.exports = { getExpectedSigners, logError, getSafeService, + parseSafeMulticall, } diff --git a/governance/package.json b/governance/package.json index 994913acd9f..5ab9226df31 100644 --- a/governance/package.json +++ b/governance/package.json @@ -3,6 +3,9 @@ "description": "Scripts for the management of the Unlock Protocol", "private": true, "dependencies": { + "@arbitrum/nitro-contracts": "1.0.2", + "@arbitrum/sdk": "3.3.3", + "@eth-optimism/sdk": "3.3.0", "@matterlabs/hardhat-zksync-deploy": "1.1.2", "@matterlabs/hardhat-zksync-solc": "1.1.0", "@matterlabs/hardhat-zksync-upgradable": "1.2.4", @@ -21,8 +24,10 @@ "@unlock-protocol/hardhat-helpers": "workspace:^", "@unlock-protocol/hardhat-plugin": "workspace:^", "@unlock-protocol/networks": "workspace:./packages/networks", + "arb-shared-dependencies": "1.0.0", "eslint": "8.54.0", "ethers": "6.10.0", + "ethers5": "npm:ethers@5", "fs-extra": "11.2.0", "hardhat": "2.20.1", "solhint": "4.5.2", diff --git a/governance/proposals/006-cross-bridge-proposal.js b/governance/proposals/006-cross-bridge-proposal.js index 20761a42cf8..e60971e6ee1 100644 --- a/governance/proposals/006-cross-bridge-proposal.js +++ b/governance/proposals/006-cross-bridge-proposal.js @@ -2,69 +2,11 @@ * Example of a bridged proposal that will be sent across Connext to multisigs * on the other side of the network. */ -const { ADDRESS_ZERO } = require('../test/helpers') +const { ADDRESS_ZERO } = require('@unlock-protocol/hardhat-helpers') +const { IConnext, targetChains } = require('../helpers/bridge') const { ethers } = require('hardhat') const { networks } = require('@unlock-protocol/networks') -const abiIConnext = [ - { - inputs: [ - { - internalType: 'uint32', - name: '_destination', - type: 'uint32', - }, - { - internalType: 'address', - name: '_to', - type: 'address', - }, - { - internalType: 'address', - name: '_asset', - type: 'address', - }, - { - internalType: 'address', - name: '_delegate', - type: 'address', - }, - { - internalType: 'uint256', - name: '_amount', - type: 'uint256', - }, - { - internalType: 'uint256', - name: '_slippage', - type: 'uint256', - }, - { - internalType: 'bytes', - name: '_callData', - type: 'bytes', - }, - ], - name: 'xcall', - outputs: [ - { - internalType: 'bytes32', - name: '', - type: 'bytes32', - }, - ], - stateMutability: 'payable', - type: 'function', - }, -] - -const targetChains = Object.keys(networks) - .map((id) => networks[id]) - .filter( - ({ governanceBridge, isTestNetwork, id }) => - !isTestNetwork && !!governanceBridge && id != 1 - ) - module.exports = async () => { // parse call data for function call const { interface: unlockInterface } = await ethers.getContractAt( @@ -138,7 +80,7 @@ module.exports = async () => { // proposed changes return { contractAddress: bridgeAddress, - contractNameOrAbi: abiIConnext, + contractNameOrAbi: IConnext, functionName: 'xcall', functionArgs: [ destDomainId, diff --git a/governance/proposals/009-protocol-upgrade.js b/governance/proposals/009-protocol-upgrade.js index 7a4265bf41b..f9e1df55f46 100644 --- a/governance/proposals/009-protocol-upgrade.js +++ b/governance/proposals/009-protocol-upgrade.js @@ -5,6 +5,7 @@ const { ethers } = require('hardhat') const { UnlockV13 } = require('@unlock-protocol/contracts') const { networks } = require('@unlock-protocol/networks') +const { IConnext, targetChains } = require('../helpers/bridge') const { getProxyAdminAddress, @@ -15,58 +16,7 @@ const { abi: proxyAdminABI, } = require('@unlock-protocol/hardhat-helpers/dist/ABIs/ProxyAdmin.json') -// TODO: move to hardhat-helpers -const abiIConnext = [ - { - inputs: [ - { - internalType: 'uint32', - name: '_destination', - type: 'uint32', - }, - { - internalType: 'address', - name: '_to', - type: 'address', - }, - { - internalType: 'address', - name: '_asset', - type: 'address', - }, - { - internalType: 'address', - name: '_delegate', - type: 'address', - }, - { - internalType: 'uint256', - name: '_amount', - type: 'uint256', - }, - { - internalType: 'uint256', - name: '_slippage', - type: 'uint256', - }, - { - internalType: 'bytes', - name: '_callData', - type: 'bytes', - }, - ], - name: 'xcall', - outputs: [ - { - internalType: 'bytes32', - name: '', - type: 'bytes32', - }, - ], - stateMutability: 'payable', - type: 'function', - }, -] +const { parseSafeMulticall } = require('../helpers/multisig') // addresses const deployedContracts = { @@ -110,8 +60,6 @@ const parseCalls = async ({ unlockAddress, name, id }) => { throw Error(`missing contract on chain ${name}(${id})`) } - console.log(`Parsing calls for ${name}(${id}) - Unlock: ${unlockAddress}`) - // submit template to Unlock const { interface: unlockInterface } = await ethers.getContractAt( UnlockV13.abi, @@ -167,17 +115,8 @@ const parseCalls = async ({ unlockAddress, name, id }) => { } module.exports = async () => { - const targetChains = Object.keys(networks) - .filter((id) => Object.keys(deployedContracts).includes(id.toString())) - .filter((id) => id != 1) - .map((id) => networks[id]) - // src info const { id: chainId } = await getNetwork() - console.log( - `from ${chainId} to chains ${targetChains.map(({ id }) => id).join(' - ')}` - ) - const { governanceBridge: { connext: bridgeAddress }, } = networks[chainId] @@ -217,43 +156,28 @@ module.exports = async () => { // store explainers explainers[destChainId] = destCalls - const abiCoder = ethers.AbiCoder.defaultAbiCoder() - await Promise.all( - destCalls.map(async ({ contractAddress, calldata, explainer }) => { - // encode instructions to be executed by the SAFE - const moduleData = await abiCoder.encode( - ['address', 'uint256', 'bytes', 'bool'], - [ - contractAddress, // to - 0, // value - calldata, // data - 0, // operation: 0 for CALL, 1 for DELEGATECALL - // 0, - ] - ) - - // add to the list of calls to be passed to the bridge - bridgeCalls.push({ - contractAddress: bridgeAddress, - contractNameOrAbi: abiIConnext, - functionName: 'xcall', - functionArgs: [ - destDomainId, - destAddress, // destMultisigAddress, - ADDRESS_ZERO, // asset - ADDRESS_ZERO, // delegate - 0, // amount - 30, // slippage - moduleData, // calldata - ], - }) - }) - ) + // parse calls for Safe + const moduleData = await parseSafeMulticall(destCalls) + + // add to the list of calls to be passed to the bridge + bridgeCalls.push({ + contractAddress: bridgeAddress, + contractNameOrAbi: IConnext, + functionName: 'xcall', + functionArgs: [ + destDomainId, + destAddress, // destMultisigAddress, + ADDRESS_ZERO, // asset + ADDRESS_ZERO, // delegate + 0, // amount + 30, // slippage + moduleData, // calldata + ], + }) }) ) const calls = [...mainnetCalls, ...bridgeCalls] - console.log(calls) // set proposal name and text const proposalName = `Upgrade protocol: switch to Unlock v13 and PublicLock v14 @@ -296,9 +220,9 @@ Onwards ! The Unlock Protocol Team ` - console.log(proposalName) return { proposalName, calls, + explainers, } } diff --git a/governance/proposals/010-arbitrum-l1-l2-messaging.js b/governance/proposals/010-arbitrum-l1-l2-messaging.js new file mode 100644 index 00000000000..0c8da68e7ed --- /dev/null +++ b/governance/proposals/010-arbitrum-l1-l2-messaging.js @@ -0,0 +1,215 @@ +const ethers = require('ethers5') +const { + L1ToL2MessageGasEstimator, +} = require('@arbitrum/sdk/dist/lib/message/L1ToL2MessageGasEstimator') +const { EthBridger, getL2Network } = require('@arbitrum/sdk') +const { getBaseFee } = require('@arbitrum/sdk/dist/lib/utils/lib') +const { mainnet, arbitrum } = require('@unlock-protocol/networks') + +const GRANTS_CONTRACT_ADDRESS = '0x00D5E0d31d37cc13C645D86410aB4cB7Cb428ccA' // Grants contract on Arbitrum +const TIMELOCK_L2_ALIAS = '0x28ffDfB0A6e6E06E95B3A1f928Dc4024240bD87c' // Timelock Alias Address on L2 +const L1_TIMELOCK_CONTRACT = '0x17EEDFb0a6E6e06E95B3A1F928dc4024240BC76B' // Timelock Address mainnet + +// ARB TOKEN ADDRESS ON ARBITRUM ONE +const { address: ARB_TOKEN_ADRESS_ON_L2 } = arbitrum.tokens.find( + ({ symbol }) => symbol === 'ARB' +) +const ERC20_ABI = require('@unlock-protocol/hardhat-helpers/dist/ABIs/erc20.json') +const INBOX_ABI = [ + { + inputs: [ + { + internalType: 'address', + name: 'to', + type: 'address', + }, + { + internalType: 'uint256', + name: 'l2CallValue', + type: 'uint256', + }, + { + internalType: 'uint256', + name: 'maxSubmissionCost', + type: 'uint256', + }, + { + internalType: 'address', + name: 'excessFeeRefundAddress', + type: 'address', + }, + { + internalType: 'address', + name: 'callValueRefundAddress', + type: 'address', + }, + { + internalType: 'uint256', + name: 'gasLimit', + type: 'uint256', + }, + { + internalType: 'uint256', + name: 'maxFeePerGas', + type: 'uint256', + }, + { + internalType: 'bytes', + name: 'data', + type: 'bytes', + }, + ], + name: 'createRetryableTicket', + outputs: [ + { + internalType: 'uint256', + name: '', + type: 'uint256', + }, + ], + stateMutability: 'payable', + type: 'function', + }, +] + +/** + * Set up: instantiate L1 / L2 wallets connected to providers + */ + +const l1Provider = new ethers.providers.StaticJsonRpcProvider(mainnet.provider) +const l2Provider = new ethers.providers.StaticJsonRpcProvider(arbitrum.provider) + +module.exports = async ({ + tokenAddressL2 = ARB_TOKEN_ADRESS_ON_L2, + fromL1 = L1_TIMELOCK_CONTRACT, + toL2 = GRANTS_CONTRACT_ADDRESS, + fromL2 = TIMELOCK_L2_ALIAS, +}) => { + console.log( + 'Proposal For Executing L1 to L2 Messaging Using Arbitrum Delayed Inbox (Retryable Tickets)' + ) + + const l2Network = await getL2Network(l2Provider) + const ethBridger = new EthBridger(l2Network) + const inboxAddress = ethBridger.l2Network.ethBridge.inbox + + // token on L2 + const L2TokenContract = new ethers.Contract( + tokenAddressL2, + ERC20_ABI, + l2Provider + ) + const decimals = await L2TokenContract.decimals() + + // check balance of sender on L2 + const balanceOf = await L2TokenContract.balanceOf(fromL2) + const tokenAmount = ethers.utils.parseUnits('8200', decimals) + + // Create an instance of the Interface from the ABIs + const erc20ContractInterface = new ethers.utils.Interface(ERC20_ABI) + const inboxContractInterface = new ethers.utils.Interface(INBOX_ABI) + + // Encode the ERC20 Token transfer calldata + const transferCalldata = erc20ContractInterface.encodeFunctionData( + 'transfer', + [toL2, tokenAmount] + ) + + /** + * Now we can query the required gas params using the estimateAll method in Arbitrum SDK + */ + const l1ToL2MessageGasEstimate = new L1ToL2MessageGasEstimator(l2Provider) + + const estimateAllParams = { + from: fromL1, + to: tokenAddressL2, + l2CallValue: 0, + excessFeeRefundAddress: fromL1, + callValueRefundAddress: fromL1, + data: transferCalldata, + } + + /** + * The estimateAll method gives us the following values for sending an L1->L2 message + * (1) maxSubmissionCost: The maximum cost to be paid for submitting the transaction + * (2) gasLimit: The L2 gas limit + * (3) deposit: The total amount to deposit on L1 to cover L2 gas and L2 call value + */ + const L1ToL2MessageGasParams = await l1ToL2MessageGasEstimate.estimateAll( + estimateAllParams, + await getBaseFee(l1Provider), + l1Provider + ) + const gasPriceBid = await l2Provider.getGasPrice() + const ETHDeposit = L1ToL2MessageGasParams.deposit.toNumber() * 10 // I Multiply by 10 to add extra in case gas changes due to proposal delay + + const params = [ + estimateAllParams.to, + estimateAllParams.l2CallValue, + L1ToL2MessageGasParams.maxSubmissionCost.toString(), // maxSubmissionCost + estimateAllParams.excessFeeRefundAddress, + estimateAllParams.callValueRefundAddress, + L1ToL2MessageGasParams.gasLimit.toString(), // gasLimit + gasPriceBid.toString(), // maxFeePerGas + estimateAllParams.data, + ] + + const inboxCalldata = inboxContractInterface.encodeFunctionData( + 'createRetryableTicket', + params + ) + + const proposalName = ` + # Transfer 8200 ARB To Fund Unlock Protocol’s Ecosystem via Grants Stack + + ### Goal of the proposal + This proposal requests to use 8200 ARB from the tokens given to Unlock Protocol DAO by ArbitrumDAO to fund the retroQF round on Grants Stack for projects building on Unlock Protocol. + + #### Current situation of DAO's ARB Tokens + - total: ${ethers.utils.formatUnits(balanceOf, decimals).toString()} ARB. + - DAO ALIAS Address (On Arbitrum): [${fromL2}](https://arbiscan.io/address/${fromL2}) + + For Reference + [Snapshot temperature check for Retro QF Grants Round](https://snapshot.org/#/unlock-protocol.eth/proposal/0xaa142e599d981f0b58c3ac1a51af9f9a52fb5307f27d791ecc18c4da69eeacc3) + + In addition to the 7k ARB tokens requested for funding Unlock Ecosystem projects, an extra 1200 ARB is requested for compensation for the round management according to the following breakdown: + + 7000 ARB - Matching fund + 700 ARB (10%) of matching fund to the round manager - lanadingwall.eth + 500 ARB for research and technical assistance - dannithomx.eth + Total: 8200 ARB + + [Snapshot temperature check for 8200 ARBs](https://snapshot.org/#/unlock-protocol.eth/proposal/0x4fa320e553e6992506cd31d7c0b2013e1548c646baba02d657f3a7b198140c25) + + #### About the proposal + The proposal contains a single call to the Arbitrum Delayed Inbox Contract's \`createRetryableTicket\` function on mainnet to create a \`Retryable Ticket\` that will attempt to execute an L2 request to the ARB token contract to transfer ${ethers.utils + .formatUnits(tokenAmount, decimals) + .toString()} of token from the Timelock L2 Alias address \`${fromL2}\` to the [grants contract](https://arbiscan.io/address/0x00d5e0d31d37cc13c645d86410ab4cb7cb428cca) - \`transfer(${toL2},${ethers.utils + .formatUnits(tokenAmount, decimals) + .toString()})\`. + + Once approved and executed, the request will be sent to the Delayed Inbox contract and a ticket is created. + + Note that, this function forces the sender to provide a reasonable amount of funds (at least enough to submitting, and attempting to executing the ticket), but that doesn't guarantee a successful auto-redemption. [Checkout arbitrum docs for more info.](https://docs.arbitrum.io/arbos/l1-to-l2-messaging). + + Thank you! + ` + // Proposal ARGS i.e Call Governor.propose() directly with these values + const targets = [inboxAddress] + const values = [ETHDeposit] + const calldatas = [inboxCalldata] + const description = proposalName + + const calls = [ + { + contractAddress: inboxAddress, + calldata: inboxCalldata, + value: ETHDeposit.toString(), + }, + ] + + return { + proposalName, + calls, + } +} diff --git a/governance/proposals/010-test-multicall.js b/governance/proposals/010-test-multicall.js new file mode 100644 index 00000000000..4b465f1448e --- /dev/null +++ b/governance/proposals/010-test-multicall.js @@ -0,0 +1,40 @@ +const { ethers, ZeroAddress } = require('ethers') +const { parseSafeMulticall } = require('../helpers/multisig') +const { UnlockV12 } = require('@unlock-protocol/contracts') +const { + getNetwork, + getERC20Contract, +} = require('@unlock-protocol/hardhat-helpers') + +module.exports = async () => { + const { unlockAddress, tokens, id: chainId } = await getNetwork() + const { address: USDC } = tokens.find(({ symbol }) => symbol === 'USDC') + const { interface } = await getERC20Contract(USDC) + + const calls = [ + { + contractAddress: ZeroAddress, + value: ethers.parseEther('0.0001'), + }, + { + contractAddress: USDC, + calldata: interface.encodeFunctionData('transfer', [ + ZeroAddress, + ethers.parseUnits('0.1', 8), + ]), + }, + { + contractNameOrAbi: UnlockV12.abi, + contractAddress: unlockAddress, + functionName: 'setProtocolFee', + functionArgs: '0.0001', + }, + ] + + // parse calls for Safe + const packedCalls = await parseSafeMulticall({ chainId, calls }) + return { + proposalName: 'Test a multicall', + calls: [packedCalls], + } +} diff --git a/governance/scripts/bridge/execTx.js b/governance/scripts/bridge/execTx.js index a0123721287..e8b5dce5fc8 100644 --- a/governance/scripts/bridge/execTx.js +++ b/governance/scripts/bridge/execTx.js @@ -7,51 +7,47 @@ * */ -const { getDelayModule, logStatus, delayABI } = require('./_lib') -const { fetchDataFromTx } = require('../../helpers/tx') +const { + getDelayModule, + fetchDataFromTx, + logStatus, +} = require('../../helpers/bridge') const fs = require('fs-extra') +const { resolve } = require('path') +const { ethers } = require('hardhat') + const { getNetwork } = require('@unlock-protocol/hardhat-helpers') +const { loadProposal } = require('../../helpers/gov') + // use cache file to gather tx hashes from calls const filepath = './xcalled.json.tmp' const bigIntToDate = (num) => new Date(parseInt((num * 1000n).toString())) -const getTxStatus = async ({ delayMod, txHash, nextNonce } = {}) => { - const currentNonce = nextNonce - 1n - const { to, value, data, operation } = await fetchDataFromTx({ - txHash, - abi: delayABI, - }) - - // make sure tx is scheduled correctly - const txHashExec = await delayMod.getTransactionHash( - to, - value, - data, - operation - ) - - // verify tx hash from nonce - const txHashFromNonce = await delayMod.getTxHash(currentNonce) - if (txHashFromNonce !== txHashExec) { - console.error(`tx mismatch`) - console.error({ txHashFromNonce, txHashExec }) - } - - const createdAt = await delayMod.txCreatedAt(currentNonce) +const getTxStatus = async (delayMod, nonce) => { + const hash = await delayMod.getTxHash(nonce) + const createdAt = await delayMod.txCreatedAt(nonce) const cooldown = await delayMod.txCooldown() const expiration = await delayMod.txExpiration() - return { - execArgs: [to, value, data, operation], + nonce, + hash, createdAt, cooldown: createdAt + cooldown, expiration: createdAt + expiration, - nonce: currentNonce, } } +const explain = (explainers, args) => { + const exp = explainers.find( + ({ contractAddress, calldata }) => + contractAddress === args[0] && calldata === args[2] + ) + return `to: \`${exp.contractAddress}\` +func: \`${exp.explainer}\`` +} + async function main({ delayModuleAddress, bridgeTxHash, @@ -62,45 +58,108 @@ async function main({ bridgeTxHash = [bridgeTxHash] } + console.log(`\n-------\n`) + if (await fs.exists(filepath)) { // parse statuses from cache file const statuses = await fs.readJSON(filepath) - const { id } = await getNetwork() + const { + id, + name, + governanceBridge: { domainId }, + } = await getNetwork() + + // get original proposal to organize calls in correct order + const proposalPath = resolve('./proposals/009-protocol-upgrade') + const { calls, explainers: allExplainers } = await loadProposal( + proposalPath + ) + const explainers = allExplainers[id] - // prune calls only for the current chain + // unpack calls from proposal + const proposalCalls = calls.filter( + ({ calldata, functionArgs }) => !calldata && functionArgs[0] === domainId + ) + + // compute expected tx hashes from proposal data + const abiCoder = ethers.AbiCoder.defaultAbiCoder() + const computedFromProposal = await Promise.all( + proposalCalls + .map((call) => + // decode args from proposal + abiCoder.decode( + ['address', 'uint256', 'bytes', 'bool'], + call.functionArgs[6] + ) + ) + .map(async (a) => { + // compute expected hash from proposal args + let args = a.toArray() + // parse bool as uint + args[3] = args[3] ? 1n : 0n + const hash = await delayMod.getTransactionHash(...args) + return { hash, args } + }) + ) + + console.log( + `${ + proposalCalls.length + } bridge calls sent to ${name} in the original proposal +${computedFromProposal + .map( + ({ hash, args }, i) => + `[${i}]: +expected hash: \`${hash}\` +${explain(explainers, args)}\n` + ) + .join('\n')}` + ) + console.log(`\n-------\n`) + + // pick bridged calls statuses only for the current chain const transfers = Object.keys(statuses) + .reverse() .map((transferId) => ({ transferId, ...statuses[transferId], })) .filter(({ dest }) => dest.chainId == id) - console.log(`${transfers.length} calls`) - - // get info on calls from multisig - let nonce = currentNonce - const txs = await Promise.all( - transfers.map(async ({ dest: { executedTransactionHash } }) => { - nonce++ // increment nonce - return await getTxStatus({ - delayMod, - txHash: executedTransactionHash, - nextNonce: nonce, - }) - }) - ) - transfers.forEach((transfer, i) => { - console.log('----------------------\n') - logStatus(transfer.transferId, transfer) - const { createdAt, cooldown, expiration } = txs[i] - console.log( - `Status on the multisig delay mod - - createdAt: ${bigIntToDate(createdAt)} - - cooldown: ${bigIntToDate(cooldown)} - - expiration: ${bigIntToDate(expiration)} - ` + const dataFromChain = await Promise.all( + transfers.map(({ dest: { executedTransactionHash } }) => + fetchDataFromTx({ txHash: executedTransactionHash }) ) + ) + console.log(`${transfers.length} txs bridged to ${name} (${id}) \n`) + transfers.map(({ transferId, ...status }, i) => { + console.log(`#### [Connext bridged call ${i}]`) + + logStatus(transferId, status) + const [nonce, hash, ...args] = dataFromChain[i] + console.log(`Containing a \`TransactionAdded\` call to multisig (nonce: ${nonce}) +hash: \`${hash}\` +${explain(explainers, args)}\n`) }) + console.log(`\n-------\n`) + + // get tx hash from nonce + const txHashesFromNonce = await Promise.all( + transfers.map((_, i) => getTxStatus(delayMod, currentNonce + BigInt(i))) + ) + + console.log( + `Txs present in the Delay module at ${await delayMod.getAddress()}:\n`, + txHashesFromNonce + .map( + ({ hash, createdAt, cooldown, expiration, nonce }) => ` + ${hash} (nonce: ${nonce}) + - createdAt: ${bigIntToDate(createdAt)} (${createdAt}) + - cooldown: ${bigIntToDate(cooldown)} + - expiration: ${bigIntToDate(expiration)}` + ) + .join(`\n`) + ) // execute all if (execute) { diff --git a/governance/scripts/bridge/bump.js b/governance/scripts/bridge/payFee.js similarity index 96% rename from governance/scripts/bridge/bump.js rename to governance/scripts/bridge/payFee.js index b21218c1bf8..0da71ef4e10 100644 --- a/governance/scripts/bridge/bump.js +++ b/governance/scripts/bridge/payFee.js @@ -5,13 +5,13 @@ * yarn hardhat run scripts/bridge/bump.js --network mainnet * * TODO: - * - make cli task to pass args + * - make cli task to pass txIx as args * */ const { ethers } = require('hardhat') const { getNetwork } = require('@unlock-protocol/hardhat-helpers') const submitTx = require('../multisig/submitTx') -const { getXCalledEvents } = require('./_lib') +const { getXCalledEvents } = require('../../helpers/bridge') const fetchRelayerFee = async ({ originDomain, destinationDomain }) => { const res = await fetch( diff --git a/governance/scripts/bridge/status.js b/governance/scripts/bridge/status.js index e39bccfb389..9208e423821 100644 --- a/governance/scripts/bridge/status.js +++ b/governance/scripts/bridge/status.js @@ -1,10 +1,19 @@ +/** + * Script to check the status of all bridge calls contained in a specific + * tx + * + * Usage: + * 1. update the `txId` with the DAO proposal execution tx has + * 2. run the script with : + * `yarn hardhat run scripts/bridge/status.js --network mainnet` + */ const { getXCalledEvents, fetchOriginXCall, fetchDestinationXCall, getSupportedChainsByDomainId, logStatus, -} = require('./_lib') +} = require('../../helpers/bridge') const fs = require('fs-extra') @@ -15,12 +24,8 @@ async function main({ // TODO: pass this hash via cli txId = '0x12d380bb7f995930872122033988524727a9f847687eede0b4e1fb2dcb8fce68', } = {}) { - console.log(`hello world ${txId}`) - const xCalls = await getXCalledEvents(txId) - console.log() - // sort by domain id const sorted = xCalls.reduce((prev, curr) => { const { destinationDomain } = curr.params diff --git a/governance/scripts/deployments/OPBridgedERC20.js b/governance/scripts/deployments/OPBridgedERC20.js new file mode 100644 index 00000000000..ae1199fb818 --- /dev/null +++ b/governance/scripts/deployments/OPBridgedERC20.js @@ -0,0 +1,95 @@ +/** + * Deploy a bridged ERC20 UDT token contract on Optimism networks + * + * Please edit the chain ids constant below to use + */ +const { getNetwork, getEvent } = require('@unlock-protocol/hardhat-helpers') +const { getProvider } = require('../../helpers/multisig') + +const { ethers } = require('hardhat') +const fs = require('fs-extra') + +// base factory address from https://docs.base.org/base-contracts/ +const OptimismMintableERC20Factory = { + base: '0xf23d369d7471bD9f6487E198723eEa023389f1d4', + optimism: '0x4200000000000000000000000000000000000012', + baseSepolia: '0x4200000000000000000000000000000000000012', +} + +// OP factory address +// const OP_OptimismMintableERC20Factory = + +// edit default values +const L1_CHAIN_ID = 11155111 // default to (Sepolia 11155111) +const l2_CHAIN_ID = 84532 // default to (Base Sepolia 84532) + +async function main({ + tokenSymbol = 'UDT', + tokenName = 'UnlockDiscountToken', + factoryAddress = OptimismMintableERC20Factory.baseSepolia, // bridged erc20 factory address + l1ChainId = L1_CHAIN_ID, + l2ChainId = l2_CHAIN_ID, +} = {}) { + const { DEPLOYER_PRIVATE_KEY } = process.env + const { + name: l1Name, + unlockDaoToken: { address: l1TokenAddress }, + } = await getNetwork(l1ChainId) + + if (!l1TokenAddress) { + throw new Error(`Missing UDT on L1 ${l1Name}`) + } + // get l2 network info + const l2 = await getNetwork(l2ChainId) + console.log( + `Deploying bridged token from L1 (${l1Name}) ${l1TokenAddress} to L2 ${l2.name} (${l2.id})... + - token: ${l1TokenAddress} ` + ) + + // Create the RPC providers and wallets + const { provider: l2Provider } = await getProvider(l2ChainId) + const l2Wallet = new ethers.Wallet(DEPLOYER_PRIVATE_KEY, l2Provider) + + // read ABI from node_modules + const { abi: factoryAbi } = JSON.parse( + fs + .readFileSync( + '../node_modules/@eth-optimism/contracts-bedrock/deployments/mainnet/OptimismMintableERC20Factory.json' + ) + .toString() + .replace(/\n/g, '') + ) + + // get factory contract instance + const factory = await ethers.getContractAt( + factoryAbi, + factoryAddress, + l2Wallet + ) + + // create bridged token + const tx = await factory.createOptimismMintableERC20( + l1TokenAddress, + tokenName, + tokenSymbol + ) + + // fetch info from tx + const receipt = await tx.wait() + const { + args: { localToken }, + hash, + } = await getEvent(receipt, 'OptimismMintableERC20Created') + + console.log(`Bridged token deployed at: ${localToken} (${hash})`) +} + +// execute as standalone +if (require.main === module) { + main() + .then(() => process.exit(0)) + .catch((error) => { + console.error(error) + process.exit(1) + }) +} diff --git a/governance/scripts/deployments/swapBurner.js b/governance/scripts/deployments/swapBurner.js index 05bc18a5cb3..87716015821 100644 --- a/governance/scripts/deployments/swapBurner.js +++ b/governance/scripts/deployments/swapBurner.js @@ -14,7 +14,7 @@ async function main() { uniswapV3: { universalRouterAddress: routerAddress }, } = await getNetwork() - console.log(`Deploying SwapAndBurn to ${chainId} + console.log(`Deploying UnlockSwapBurner to ${chainId} - unlockAddress: ${unlockAddress} - PERMIT2_ADDRESS : ${PERMIT2_ADDRESS} - routerAddress: ${routerAddress}`) diff --git a/governance/scripts/gov/execute.js b/governance/scripts/gov/execute.js index 8cfa391a965..2bba93030b0 100644 --- a/governance/scripts/gov/execute.js +++ b/governance/scripts/gov/execute.js @@ -18,7 +18,7 @@ async function main({ proposal, proposalId, txId, govAddress }) { if (!proposal && !proposalId) { throw new Error('GOV EXEC > Missing proposal or proposalId.') } - if (proposalId && !txId) { + if (!proposal && proposalId && !txId) { throw new Error( 'GOV EXEC > The tx id of the proposal creation is required to execute the proposal.' ) diff --git a/governance/scripts/gov/index.js b/governance/scripts/gov/index.js index be0e6106d3b..8bbf8d95d6b 100644 --- a/governance/scripts/gov/index.js +++ b/governance/scripts/gov/index.js @@ -54,7 +54,7 @@ async function main({ proposal, proposalId, govAddress, txId }) { // Submit the proposal if necessary if (!proposalId) { - proposalId = await submit({ proposal, govAddress }) + ;({ proposalId } = await submit({ proposal, govAddress })) } // votes @@ -74,7 +74,7 @@ async function main({ proposal, proposalId, govAddress, txId }) { ) // Run the gov workflow - await queue({ proposalId, govAddress, txId }) + await queue({ proposalId, proposal, govAddress, txId }) const { logs } = await execute({ proposalId, txId, proposal, govAddress }) // log all events diff --git a/governance/scripts/gov/queue.js b/governance/scripts/gov/queue.js index 79f545ddceb..a32c06a0771 100644 --- a/governance/scripts/gov/queue.js +++ b/governance/scripts/gov/queue.js @@ -1,6 +1,5 @@ const { ethers } = require('hardhat') const { mineUpTo } = require('@nomicfoundation/hardhat-network-helpers') -const { getProposalArgsFromTx } = require('../../helpers/gov') const { queueProposal, @@ -17,7 +16,7 @@ async function main({ proposalId, txId, proposal, govAddress }) { if (!proposal && !proposalId) { throw new Error('GOV QUEUE > Missing proposal or proposalId.') } - if (proposalId && !txId) { + if (!proposal && proposalId && !txId) { throw new Error( 'GOV QUEUE > The tx id of the proposal creation is required to execute the proposal.' ) diff --git a/governance/scripts/gov/submit.js b/governance/scripts/gov/submit.js index 822b815d0f9..17ae2119d7d 100644 --- a/governance/scripts/gov/submit.js +++ b/governance/scripts/gov/submit.js @@ -34,7 +34,7 @@ async function main({ proposal, govAddress }) { `GOV SUBMIT > proposal submitted: ${await proposalId.toString()} (txid: ${hash}, block: ${currentBlock})` ) - return proposalId, hash + return { proposalId, hash } } // execute as standalone diff --git a/governance/scripts/lock/purchase.js b/governance/scripts/lock/purchase.js index 634b8c1e1d2..9e96d966cbf 100644 --- a/governance/scripts/lock/purchase.js +++ b/governance/scripts/lock/purchase.js @@ -1,51 +1,49 @@ const { ethers } = require('hardhat') -const { AddressZero } = ethers.constants +const { ADDRESS_ZERO, getEvent } = require('@unlock-protocol/hardhat-helpers') const contracts = require('@unlock-protocol/contracts') -async function main({ lockAddress, to: _recipient, lockVersion }) { +async function main({ + lockAddress, + to: _recipient, + lockVersion, + referrer = ADDRESS_ZERO, + keyManager = ADDRESS_ZERO, +}) { const [signer] = await ethers.getSigners() const recipient = _recipient || signer.address // get lock contract - let Lock - if (lockVersion) { - Lock = await ethers.getContractFactory('PublicLock') - } else { - const { abi, bytecode } = contracts[`PublicLockV${lockVersion}`] - Lock = await ethers.getContractFactory(abi, bytecode) - } - const lock = Lock.attach(lockAddress) + const { abi } = + contracts[lockVersion ? `PublicLockV${lockVersion}` : `PublicLock`] + const lock = await ethers.getContractAt(abi, lockAddress) // purchase a bunch of keys console.log('LOCK PURCHASE > Buying a key...') const keyPrice = (await lock.keyPrice()).toString() - const isErc20 = (await lock.tokenAddress()) !== AddressZero + const isErc20 = (await lock.tokenAddress()) !== ADDRESS_ZERO - // multiple purchases was introduced in v11 - let tx - if (lockVersion >= 10) { - tx = await lock.purchase( - isErc20 ? [keyPrice] : [], - [recipient], - [AddressZero], - [AddressZero], - [[]], - { - value: isErc20 ? 0 : keyPrice, - } - ) - } else { - tx = lock.purchase(keyPrice, recipient, AddressZero, AddressZero, [], { - value: keyPrice, - }) - } + const args = [ + isErc20 ? [keyPrice] : [], + [recipient], + [referrer], + [keyManager], + ['0x'], + ] + // multiple purchases was introduced in v11 + const tx = await lock.purchase(...args, { + value: isErc20 ? 0 : keyPrice, + }) // get token ids - const { events } = await tx.wait() + const receipt = await tx.wait() const { args: { to, tokenId }, - } = events.find(({ event }) => event === 'Transfer') - console.log(`LOCK PURCHASE > key (${tokenId}) purchased by ${to}`) + hash, + } = await getEvent(receipt, 'Transfer') + + console.log( + `LOCK PURCHASE > key (${tokenId}) purchased by ${to} (tx: ${hash})` + ) } // execute as standalone diff --git a/governance/scripts/multisig/submitTx.js b/governance/scripts/multisig/submitTx.js index 9f805eed19d..2f4728faba5 100644 --- a/governance/scripts/multisig/submitTx.js +++ b/governance/scripts/multisig/submitTx.js @@ -46,14 +46,19 @@ async function main({ safeAddress, tx, signer }) { const safeSdk = await Safe.create({ ethAdapter, safeAddress }) const txs = !Array.isArray(tx) ? [tx] : tx - const explainer = txs - .map(({ functionName, functionArgs, explainer }) => - explainer - ? explainer - : `'${functionName}(${Object.values(functionArgs).toString()})'` - ) - .join(', ') - console.log(`Submitting txs: ${explainer}`) + let explainer = '' + try { + explainer = txs + .map(({ functionName, functionArgs, explainer }) => + explainer + ? explainer + : `'${functionName}(${Object.values(functionArgs).toString()})'` + ) + .join(', ') + console.log(`Submitting txs: ${explainer}`) + } catch (error) { + console.log(`Missing explainers...`) + } // parse transactions const transactions = await Promise.all( @@ -108,13 +113,13 @@ async function main({ safeAddress, tx, signer }) { // now send tx via Safe Global web service const safeTxHash = await safeSdk.getTransactionHash(safeTransaction) - const senderSignature = await safeSdk.signTransactionHash(safeTxHash) + const senderSignature = await safeSdk.signHash(safeTxHash) await safeService.proposeTransaction({ safeAddress, safeTransactionData: safeTransaction.data, safeTxHash, - senderAddress: signer.address, + senderAddress: await signer.getAddress(), senderSignature: senderSignature.data, }) diff --git a/governance/scripts/udt/bridge/abi/l1standardbridge.json b/governance/scripts/udt/bridge/abi/l1standardbridge.json new file mode 100644 index 00000000000..d7fcc0d0226 --- /dev/null +++ b/governance/scripts/udt/bridge/abi/l1standardbridge.json @@ -0,0 +1,521 @@ +[ + { + "inputs": [ + { + "internalType": "address payable", + "name": "_messenger", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "localToken", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "remoteToken", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "bytes", + "name": "extraData", + "type": "bytes" + } + ], + "name": "ERC20BridgeFinalized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "localToken", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "remoteToken", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "bytes", + "name": "extraData", + "type": "bytes" + } + ], + "name": "ERC20BridgeInitiated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "l1Token", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "l2Token", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "bytes", + "name": "extraData", + "type": "bytes" + } + ], + "name": "ERC20DepositInitiated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "l1Token", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "l2Token", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "bytes", + "name": "extraData", + "type": "bytes" + } + ], + "name": "ERC20WithdrawalFinalized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "bytes", + "name": "extraData", + "type": "bytes" + } + ], + "name": "ETHBridgeFinalized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "bytes", + "name": "extraData", + "type": "bytes" + } + ], + "name": "ETHBridgeInitiated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "bytes", + "name": "extraData", + "type": "bytes" + } + ], + "name": "ETHDepositInitiated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "bytes", + "name": "extraData", + "type": "bytes" + } + ], + "name": "ETHWithdrawalFinalized", + "type": "event" + }, + { + "inputs": [], + "name": "MESSENGER", + "outputs": [ + { + "internalType": "contract CrossDomainMessenger", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "OTHER_BRIDGE", + "outputs": [ + { + "internalType": "contract StandardBridge", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_localToken", "type": "address" }, + { "internalType": "address", "name": "_remoteToken", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" }, + { "internalType": "uint32", "name": "_minGasLimit", "type": "uint32" }, + { "internalType": "bytes", "name": "_extraData", "type": "bytes" } + ], + "name": "bridgeERC20", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_localToken", "type": "address" }, + { "internalType": "address", "name": "_remoteToken", "type": "address" }, + { "internalType": "address", "name": "_to", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" }, + { "internalType": "uint32", "name": "_minGasLimit", "type": "uint32" }, + { "internalType": "bytes", "name": "_extraData", "type": "bytes" } + ], + "name": "bridgeERC20To", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint32", "name": "_minGasLimit", "type": "uint32" }, + { "internalType": "bytes", "name": "_extraData", "type": "bytes" } + ], + "name": "bridgeETH", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_to", "type": "address" }, + { "internalType": "uint32", "name": "_minGasLimit", "type": "uint32" }, + { "internalType": "bytes", "name": "_extraData", "type": "bytes" } + ], + "name": "bridgeETHTo", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_l1Token", "type": "address" }, + { "internalType": "address", "name": "_l2Token", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" }, + { "internalType": "uint32", "name": "_minGasLimit", "type": "uint32" }, + { "internalType": "bytes", "name": "_extraData", "type": "bytes" } + ], + "name": "depositERC20", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_l1Token", "type": "address" }, + { "internalType": "address", "name": "_l2Token", "type": "address" }, + { "internalType": "address", "name": "_to", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" }, + { "internalType": "uint32", "name": "_minGasLimit", "type": "uint32" }, + { "internalType": "bytes", "name": "_extraData", "type": "bytes" } + ], + "name": "depositERC20To", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint32", "name": "_minGasLimit", "type": "uint32" }, + { "internalType": "bytes", "name": "_extraData", "type": "bytes" } + ], + "name": "depositETH", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_to", "type": "address" }, + { "internalType": "uint32", "name": "_minGasLimit", "type": "uint32" }, + { "internalType": "bytes", "name": "_extraData", "type": "bytes" } + ], + "name": "depositETHTo", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "", "type": "address" }, + { "internalType": "address", "name": "", "type": "address" } + ], + "name": "deposits", + "outputs": [{ "internalType": "uint256", "name": "", "type": "uint256" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_localToken", "type": "address" }, + { "internalType": "address", "name": "_remoteToken", "type": "address" }, + { "internalType": "address", "name": "_from", "type": "address" }, + { "internalType": "address", "name": "_to", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" }, + { "internalType": "bytes", "name": "_extraData", "type": "bytes" } + ], + "name": "finalizeBridgeERC20", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_from", "type": "address" }, + { "internalType": "address", "name": "_to", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" }, + { "internalType": "bytes", "name": "_extraData", "type": "bytes" } + ], + "name": "finalizeBridgeETH", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_l1Token", "type": "address" }, + { "internalType": "address", "name": "_l2Token", "type": "address" }, + { "internalType": "address", "name": "_from", "type": "address" }, + { "internalType": "address", "name": "_to", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" }, + { "internalType": "bytes", "name": "_extraData", "type": "bytes" } + ], + "name": "finalizeERC20Withdrawal", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { "internalType": "address", "name": "_from", "type": "address" }, + { "internalType": "address", "name": "_to", "type": "address" }, + { "internalType": "uint256", "name": "_amount", "type": "uint256" }, + { "internalType": "bytes", "name": "_extraData", "type": "bytes" } + ], + "name": "finalizeETHWithdrawal", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [], + "name": "l2TokenBridge", + "outputs": [{ "internalType": "address", "name": "", "type": "address" }], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "messenger", + "outputs": [ + { + "internalType": "contract CrossDomainMessenger", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "version", + "outputs": [{ "internalType": "string", "name": "", "type": "string" }], + "stateMutability": "view", + "type": "function" + }, + { "stateMutability": "payable", "type": "receive" } +] diff --git a/governance/scripts/udt/bridge/arb.js b/governance/scripts/udt/bridge/arb.js new file mode 100644 index 00000000000..e7e71244c94 --- /dev/null +++ b/governance/scripts/udt/bridge/arb.js @@ -0,0 +1,133 @@ +/** + * Bridge UDT token to the Arbitrum network + * NB: if the contract for the bridge token is not deployed, + * this will deploy it. + * + */ +const { getNetwork } = require('@unlock-protocol/hardhat-helpers') + +const { + getL2Network, + Erc20Bridger, + L1ToL2MessageStatus, +} = require('@arbitrum/sdk') +const ethers = require('ethers5') +const abiERC20 = require('@unlock-protocol/hardhat-helpers/dist/ABIs/erc20.json') + +const L1_CHAIN_ID = 1 // mainnet (Sepolia 11155111) +const l2_CHAIN_ID = 42161 // ARB (ARB Sepolia 421614) + +async function main({ + l1ChainId = L1_CHAIN_ID, + l2ChainId = l2_CHAIN_ID, + amount = 100000000000000000n, // default to 0.1 +} = {}) { + const { DEPLOYER_PRIVATE_KEY } = process.env + + // unlock networks info + const [l1, l2] = await Promise.all([ + await getNetwork(l1ChainId), + await getNetwork(l2ChainId), + ]) + + const l1TokenAddress = l1.unlockDaoToken.address + + console.log( + `Bridging tokens from L1 ${l1.name} (${l1.id}) to L2 ${l2.name} (${l2.id})... + - UDT L1: ${l1TokenAddress}` + ) + + // get wallets and providers + const l1Provider = new ethers.providers.StaticJsonRpcProvider(l1.provider) + const l1Wallet = new ethers.Wallet(DEPLOYER_PRIVATE_KEY, l1Provider) + // const l2Provider = await getProvider(l2ChainId) + const l2Provider = new ethers.providers.StaticJsonRpcProvider(l2.provider) + + // token contract instance + const l1Token = new ethers.Contract(abiERC20, l1TokenAddress, l1Wallet) + + // use arb sdk + const l2Network = await getL2Network(l2Provider) + const erc20Bridger = new Erc20Bridger(l2Network) + const l2TokenAddress = await erc20Bridger.getL2ERC20Address( + l1TokenAddress, + l1Provider + ) + console.log(`L2 ERC20 bridged token contract at ${l2TokenAddress}`) + + // get arb gateway address + const expectedL1GatewayAddress = await erc20Bridger.getL1GatewayAddress( + l1TokenAddress, + l1Provider + ) + console.log(`Using ARB Gateway at: ${expectedL1GatewayAddress}`) + const balance = await l1Token.balanceOf(l1Wallet.address) + console.log(`Balances: + - L1 Wallet: ${balance.toString()} + - L1 Gateway / L2 totalSupply: ${await l1Token.balanceOf( + expectedL1GatewayAddress + )}`) + + if (balance.lt(amount)) { + throw new Error('Insufficient UDT balance on L1. Can not bridge') + } + + console.log('Approving the Bridge to spend token...') + const approveTx = await erc20Bridger.approveToken({ + l1Signer: l1Wallet, + erc20L1Address: l1TokenAddress, + }) + const approveRec = await approveTx.wait() + console.log( + `You successfully allowed the Arbitrum Bridge to spend UDT ${approveRec.transactionHash}` + ) + + console.log(`Depositing ${amount} to L2 via the Gateway bridge contract...`) + const depositTx = await erc20Bridger.deposit({ + amount, + erc20L1Address: l1TokenAddress, + l1Signer: l1Wallet, + l2Provider: l2Provider, + }) + + // Now we wait for L1 and L2 side of transactions to be confirmed + console.log( + `Deposit initiated: waiting for L2 retryable (takes 10-15 minutes; current time: ${new Date().toTimeString()}) ` + ) + const depositRec = await depositTx.wait() + const l2Result = await depositRec.waitForL2(l2Provider) + l2Result.complete + ? console.log( + `L2 message successful: status: ${L1ToL2MessageStatus[l2Result.status]}` + ) + : console.log( + `L2 message failed: status ${L1ToL2MessageStatus[l2Result.status]}` + ) + + // now fetch the token address created on l2 + if (!l2TokenAddress) { + console.log('Get address on L2...') + const l2TokenAddress = await erc20Bridger.getL2ERC20Address( + l1TokenAddress, + l1Provider + ) + console.log(`L2 token contract created at ${l2TokenAddress}`) + } + const l2Token = erc20Bridger.getL2TokenContract(l2Provider, l2TokenAddress) + + console.log( + `Balances: + - l1: ${(await l1Token.balanceOf(l1Wallet.address)).toString()} + - l2: ${(await l2Token.balanceOf(l1Wallet.address)).toString()}` + ) +} + +// execute as standalone +if (require.main === module) { + main() + .then(() => process.exit(0)) + .catch((error) => { + console.error(error) + process.exit(1) + }) +} diff --git a/governance/scripts/udt/bridge/base.js b/governance/scripts/udt/bridge/base.js new file mode 100644 index 00000000000..14b80300adf --- /dev/null +++ b/governance/scripts/udt/bridge/base.js @@ -0,0 +1,124 @@ +/** + * Deploy a bridged ERC20 UDT token contract on Arbitrum network + * + */ +const { getNetwork } = require('@unlock-protocol/hardhat-helpers') +const l1BridgeAbi = require('./abi/l1standardbridge.json') +const ethers = require('ethers5') +const abiERC20 = require('@unlock-protocol/hardhat-helpers/dist/ABIs/erc20.json') + +// tweak these params +const USE_TESTNET = false +const SIMULATION = true +const gasLimit = 1000000 +const defaultGasAmount = '200000' + +// parse network details +const L1_CHAIN_ID = USE_TESTNET ? 11155111 : 1 // mainnet (Sepolia 11155111) +const l2_CHAIN_ID = USE_TESTNET ? 84532 : 8453 // BASE (BASE Sepolia 84532) +const standardBridges = { + 1: '0x3154Cf16ccdb4C6d922629664174b904d80F2C35', + 11155111: '0xfd0Bf71F60660E2f608ed56e1659C450eB113120', +} +const L1_STANDARD_BRIDGE = standardBridges[L1_CHAIN_ID] + +async function main({ + l1ChainId = L1_CHAIN_ID, + l2ChainId = l2_CHAIN_ID, + l1StandardBridge = L1_STANDARD_BRIDGE, + amount = `100000000000000000`, // default to 0.1 +} = {}) { + const { DEPLOYER_PRIVATE_KEY } = process.env + + const [l1, l2] = await Promise.all([ + await getNetwork(l1ChainId), + await getNetwork(l2ChainId), + ]) + + const l1TokenAddress = l1.unlockDaoToken.address + const l2TokenAddress = l2.unlockDaoToken.address + + console.log( + `Bridging tokens from L1 ${l1.name} (${l1.id}) to L2 ${l2.name} (${l2.id})... + - L1: ${l1TokenAddress} + - L2: ${l2TokenAddress}` + ) + + // Create the RPC providers and wallets + const l1Provider = new ethers.providers.StaticJsonRpcProvider(l1.provider) + const l1Wallet = new ethers.Wallet(DEPLOYER_PRIVATE_KEY, l1Provider) + + const bridgeContract = new ethers.Contract( + l1StandardBridge, + l1BridgeAbi, + l1Wallet + ) + + const sender = await bridgeContract.l2TokenBridge() + console.log('sender', sender) + + const l1Token = new ethers.Contract(l1TokenAddress, abiERC20, l1Wallet) + + // check balance + const balance = await l1Token.balanceOf(l1Wallet.address) + if (balance.lt(amount)) { + throw new Error(`Balance too low`) + } + + // approval + const allowance = await l1Token.allowance(l1Wallet.address, l1StandardBridge) + if (allowance.lt(amount)) { + console.log('approve bridge to access token...') + const { hash } = await l1Token.approve(l1StandardBridge, amount) + console.log(`approved (tx: ${hash})`) + } else { + console.log('token approval ok for deposit') + } + + const bridgeArgs = { + l1TokenAddress, + l2TokenAddress, + amount, + defaultGasAmount, + emptyData: '0x', + } + + // show gas estimate + const gasEstimate = await bridgeContract.estimateGas.bridgeERC20( + ...Object.values(bridgeArgs), + { + gasLimit, + } + ) + const { baseFeePerGas } = await l1Provider.getBlock('latest') + const gasCostEstimate = baseFeePerGas.mul(gasEstimate) + console.log( + `Gas cost estimate: ${ethers.utils.formatEther(gasCostEstimate)} ETH` + ) + // deposit to bridge + if (!SIMULATION) { + try { + const bridgeResult = await bridgeContract.bridgeERC20( + ...Object.values(bridgeArgs), + { + gasLimit, + } + ) + console.log('bridge deposit done', bridgeResult) + const { transactionHash } = await bridgeResult.wait() + console.log(`(tx: ${transactionHash})`) + } catch (e) { + console.log('bridge token result error', e) + } + } +} + +// execute as standalone +if (require.main === module) { + main() + .then(() => process.exit(0)) + .catch((error) => { + console.error(error) + process.exit(1) + }) +} diff --git a/governance/scripts/udt/bridge/op.js b/governance/scripts/udt/bridge/op.js new file mode 100644 index 00000000000..020212a70c7 --- /dev/null +++ b/governance/scripts/udt/bridge/op.js @@ -0,0 +1,110 @@ +/** + * Bridge tokens to Optimism networks + * + */ + +const { getNetwork } = require('@unlock-protocol/hardhat-helpers') +const ethers = require('ethers5') +const optimism = require('@eth-optimism/sdk') + +// edit default values +const L1_CHAIN_ID = 1 // Sepolia 11155111 +const l2_CHAIN_ID = 10 // Base Sepolia 84532 + +async function main({ + l1ChainId = L1_CHAIN_ID, + l2ChainId = l2_CHAIN_ID, + amount = 100000000000000000n, // default to 0.1 +} = {}) { + const { DEPLOYER_PRIVATE_KEY } = process.env + + const [l1, l2] = await Promise.all([ + await getNetwork(l1ChainId), + await getNetwork(l2ChainId), + ]) + + const l1TokenAddress = l1.unlockDaoToken.address + const l2TokenAddress = l2.unlockDaoToken.address + + console.log( + `Bridging tokens from L1 ${l1.name} (${l1.id}) to L2 ${l2.name} (${l2.id})... + - L1: ${l1TokenAddress} + - L2: ${l2TokenAddress}` + ) + + // Create the RPC providers and wallets + const l1Provider = new ethers.providers.StaticJsonRpcProvider(l1.provider) + const l2Provider = new ethers.providers.StaticJsonRpcProvider(l2.provider) + const l1Wallet = new ethers.Wallet(DEPLOYER_PRIVATE_KEY, l1Provider) + const l2Wallet = new ethers.Wallet(DEPLOYER_PRIVATE_KEY, l2Provider) + + // tokens + const l1Token = await ethers.getContractAt( + 'IMintableERC20', + l1TokenAddress, + l1Wallet + ) + const l2Token = await ethers.getContractAt( + 'IMintableERC20', + l2TokenAddress, + l2Wallet + ) + + console.log( + `Amount: ${ethers.utils.formatUnits( + amount + )} ${await l1Token.symbol()} to ${await l2Token.symbol()} on L2...` + ) + + const showBalances = async (text = 'Balance') => { + console.log( + `${text} + - l1: ${(await l1Token.balanceOf(l1Wallet.address)).toString()} + - l2: ${(await l2Token.balanceOf(l2Wallet.address)).toString()}` + ) + } + + // log balances + await showBalances('Balance before') + + // sdk init + const messenger = new optimism.CrossChainMessenger({ + l1ChainId, + l2ChainId, + l1SignerOrProvider: l1Wallet, + l2SignerOrProvider: l2Wallet, + }) + + console.log(`Approving tokens...`) + const txApprove = await messenger.approveERC20( + l1TokenAddress, + l2TokenAddress, + amount + ) + await txApprove.wait() + + console.log(`Deposit tokens...`) + const txDeposit = await messenger.depositERC20(l1Token, l2Token, amount) + await txDeposit.wait() + + // wait for deposit to be ready + console.log(`Wait for the deposit to be ready...`) + await messenger.waitForMessageStatus( + txDeposit.hash, + optimism.MessageStatus.RELAYED + ) + + // check balances after operations + console.log(`Deposit done.`) + await showBalances('Balance after') +} + +// execute as standalone +if (require.main === module) { + main() + .then(() => process.exit(0)) + .catch((error) => { + console.error(error) + process.exit(1) + }) +} diff --git a/governance/scripts/uniswap/oracle.js b/governance/scripts/uniswap/oracle.js new file mode 100644 index 00000000000..a85a99f24ff --- /dev/null +++ b/governance/scripts/uniswap/oracle.js @@ -0,0 +1,73 @@ +const { ethers } = require('hardhat') +const { + getNetwork, + getERC20Contract, +} = require('@unlock-protocol/hardhat-helpers') +const { UniswapOracleV3 } = require('@unlock-protocol/contracts') + +async function main({ tokenIn = 'POINTS', tokenOut, amount = '1' } = {}) { + const { + nativeCurrency: { wrapped: wrappedNativeAddress }, + uniswapV3: { oracle: oracleAddress }, + tokens, + } = await getNetwork() + + if (!oracleAddress) { + throw new Error( + 'No address for oracle in the networks package, please add one.' + ) + } + + // check wrapped + let tokenTo + if (!tokenOut) { + const wrapped = await getERC20Contract(wrappedNativeAddress) + const wrappedSymbol = await wrapped.symbol() + tokenTo = { address: wrappedNativeAddress, symbol: wrappedSymbol } + } else { + tokenTo = tokens.find((token) => token.symbol === tokenOut) + if (!tokenTo) { + throw new Error( + `Token ${tokenOut} is not defined in the networks package.` + ) + } + } + + const tokenFrom = tokens.find((token) => token.symbol === tokenIn) + if (!tokenFrom) { + throw new Error(`Token ${tokenIn} is not defined in the networks package.`) + } + + // check if token can be retrieved through Uniswap V3 oracle + const oracle = await ethers.getContractAt(UniswapOracleV3.abi, oracleAddress) + console.log( + `Checking oracle for ${tokenFrom.symbol}/${tokenTo.symbol} (${amount})` + ) + const rate = await oracle.consult( + tokenFrom.address, + ethers.parseUnits(amount, tokenFrom.decimals), + tokenTo.address + ) + if (rate === 0n) { + console.log(`Uniswap V3 pool not found`) + } else { + console.log( + `Current rate (~last hour) : ${ethers.formatUnits( + rate, + tokenTo.decimals + )} ${tokenTo.symbol} for ${amount} ${tokenIn.symbol}` + ) + } +} + +// execute as standalone +if (require.main === module) { + main() + .then(() => process.exit(0)) + .catch((error) => { + console.error(error) + process.exit(1) + }) +} + +module.exports = main diff --git a/governance/tasks/gov.js b/governance/tasks/gov.js index 7f37242e123..fe34939e62f 100644 --- a/governance/tasks/gov.js +++ b/governance/tasks/gov.js @@ -265,6 +265,7 @@ task('gov:show', 'Show content of proposal') console.log('load from tx') proposal = await parseProposal({ txId, govAddress }) } - console.log(proposal) + const { explainers } = proposal + console.log(explainers) } ) diff --git a/governance/tasks/uniswap.js b/governance/tasks/uniswap.js new file mode 100644 index 00000000000..397f2041672 --- /dev/null +++ b/governance/tasks/uniswap.js @@ -0,0 +1,14 @@ +const { task } = require('hardhat/config') + +task('oracle:check', 'Show the rate for a token from Unlock oracle') + .addParam('token', 'The symbol of the token to check') + .addOptionalParam('amount', 'Amount of tokens to check (ex. 1 ETH)') + .addOptionalParam( + 'tokenOut', + 'The symbol of the token pair (default to Wrapped Native)' + ) + .setAction(async ({ token, amount, tokenOut }) => { + // eslint-disable-next-line global-require + const oracleCheck = require('../scripts/uniswap/oracle') + await oracleCheck({ tokenIn: token, tokenOut, amount }) + }) diff --git a/locksmith/.op.env.production b/locksmith/.op.env.production index 40ec3743c9c..679731c91c8 100644 --- a/locksmith/.op.env.production +++ b/locksmith/.op.env.production @@ -10,6 +10,8 @@ LOGTAIL=op://secrets/logtail/logtail-prod WEDLOCKS=op://secrets/wedlocks/private-key PURCHASER_CREDENTIALS=op://secrets/purchaser/credentials-prod ON_HEROKU=true +GITCOIN_API_KEY=op://secrets/gitcoin/api-key +GITCOIN_SCORER_ID=op://secrets/gitcoin/scorer-id DEFENDER_RELAY_KEY_1=op://secrets/open-zeppelin-relay/ethereum-key DEFENDER_RELAY_SECRET_1=op://secrets/open-zeppelin-relay/ethereum-secret diff --git a/locksmith/.op.env.staging b/locksmith/.op.env.staging index f0fff048061..5e971c6ad3c 100644 --- a/locksmith/.op.env.staging +++ b/locksmith/.op.env.staging @@ -10,4 +10,6 @@ STORAGE_PUBLIC_HOST=op://secrets/cloudflare/storage-public-host-staging LOGTAIL=op://secrets/logtail/logtail-staging WEDLOCKS=op://secrets/wedlocks/private-key PURCHASER_CREDENTIALS=op://secrets/purchaser/credentials-staging -ON_HEROKU=true \ No newline at end of file +ON_HEROKU=true +GITCOIN_API_KEY=op://secrets/gitcoin/api-key +GITCOIN_SCORER_ID=op://secrets/gitcoin/scorer-id diff --git a/locksmith/__tests__/utils/gasPrice.test.ts b/locksmith/__tests__/utils/gasPrice.test.ts index ace41f7ed34..97b6ee7d9a3 100644 --- a/locksmith/__tests__/utils/gasPrice.test.ts +++ b/locksmith/__tests__/utils/gasPrice.test.ts @@ -1,23 +1,14 @@ import { BigNumber } from 'ethers' import GasPrice from '../../src/utils/gasPrice' import { vi } from 'vitest' -// mock coinbase API -vi.mock('isomorphic-fetch', () => { - return { - default: async () => ({ - json: async () => ({ - data: { base: 'ETH', currency: 'USD', amount: '420000' }, - }), - ok: true, - }), - } -}) -vi.mock('@unlock-protocol/networks', () => { +vi.mock('../../src/operations/pricingOperations', () => { return { - default: { - 1: {}, - 31137: {}, + getDefiLammaPrice: ({ network, erc20Address, amount = 1 }) => { + return Promise.resolve({ + priceInAmount: amount * 420000, // Keeping tests simple + decimals: 5, + }) }, } }) diff --git a/locksmith/__tests__/worker/renewKey.test.ts b/locksmith/__tests__/worker/renewKey.test.ts index dc7ef3ed479..5c6b0ba529b 100644 --- a/locksmith/__tests__/worker/renewKey.test.ts +++ b/locksmith/__tests__/worker/renewKey.test.ts @@ -109,13 +109,9 @@ vi.mock('@unlock-protocol/unlock-js', () => ({ }, })) -vi.mock('../../src/utils/keyPricer', () => { +vi.mock('../../src/operations/pricingOperations', () => { return { - default: vi.fn(() => { - return { - GAS_COST: 1000, - } - }), + getDefiLammaPrice: () => Promise.resolve({ priceInAmount: 1 }), } }) @@ -130,19 +126,6 @@ vi.mock('../../src/utils/gasPrice', () => { } }) -vi.mock('isomorphic-fetch', () => { - return { - default: vi.fn().mockImplementation(() => { - return { - json: async () => ({ - data: { base: 'USDT', currency: 'USD', amount: 1 }, - }), - ok: true, - } - }), - } -}) - describe('isWorthRenewing', () => { it('should return true when gas refund is enough', async () => { expect.assertions(2) diff --git a/locksmith/migrations/20240404214415-add-required-gitcoin-passport-score-to-lock-settings.js b/locksmith/migrations/20240404214415-add-required-gitcoin-passport-score-to-lock-settings.js new file mode 100644 index 00000000000..7ed59cab194 --- /dev/null +++ b/locksmith/migrations/20240404214415-add-required-gitcoin-passport-score-to-lock-settings.js @@ -0,0 +1,19 @@ +'use strict' + +const table = 'LockSettings' + +/** @type {import('sequelize-cli').Migration} */ + +module.exports = { + async up(queryInterface, Sequelize) { + await queryInterface.addColumn(table, 'requiredGitcoinPassportScore', { + type: Sequelize.INTEGER, + allowNull: true, + defaultValue: null, + }) + }, + + async down(queryInterface, Sequelize) { + await queryInterface.removeColumn(table, 'requiredGitcoinPassportScore') + }, +} diff --git a/locksmith/package.json b/locksmith/package.json index 8bcd85daba6..a50cbba326c 100644 --- a/locksmith/package.json +++ b/locksmith/package.json @@ -35,8 +35,8 @@ "license": "ISC", "dependencies": { "@aws-sdk/client-s3": "3.525.0", - "@logtail/node": "0.4.19", - "@logtail/winston": "0.4.12", + "@logtail/node": "0.4.21", + "@logtail/winston": "0.4.21", "@nuintun/qrcode": "4.1.2", "@openzeppelin/defender-relay-client": "1.54.1", "@resvg/resvg-js": "2.4.1", diff --git a/locksmith/src/config/config.ts b/locksmith/src/config/config.ts index ff74a73eb52..43e856ff985 100644 --- a/locksmith/src/config/config.ts +++ b/locksmith/src/config/config.ts @@ -77,6 +77,15 @@ const config = { exportsBucket: 'uploads', }, recaptchaSecret: process.env.RECAPTCHA_SECRET, + /* To utilize the Gitcoin Passport API, you need the GITCOIN_API_KEY and GITCOIN_SCORER_ID, essential for authentication and scoring customization. + + While setting these up in the Gitcoin passport dashboard, select the "Bot Prevention" use case for creating a scorer. + + This setup ensures secure, application-specific API access. For comprehensive setup instructions, see the Gitcoin Passport API documentation: + https://docs.passport.gitcoin.co/building-with-passport/passport-api/getting-access + */ + gitcoinApiKey: process.env.GITCOIN_API_KEY, + gitcoinScorerId: process.env.GITCOIN_SCORER_ID, logtailSourceToken: process.env.LOGTAIL, sessionDuration: Number(process.env.SESSION_DURATION || 86400 * 60), // 60 days requestTimeout: '25s', diff --git a/locksmith/src/controllers/v2/eventsController.ts b/locksmith/src/controllers/v2/eventsController.ts index 637e2e7799f..0d7c305adea 100644 --- a/locksmith/src/controllers/v2/eventsController.ts +++ b/locksmith/src/controllers/v2/eventsController.ts @@ -1,7 +1,7 @@ import { RequestHandler } from 'express' import { getEventBySlug, - getEventDataForLock, + getEventMetadataForLock, saveEvent, } from '../../operations/eventOperations' import normalizer from '../../utils/normalizer' @@ -19,7 +19,7 @@ export const getEventDetailsByLock: RequestHandler = async ( ) => { const network = Number(request.params.network) const lockAddress = normalizer.ethereumAddress(request.params.lockAddress) - const eventDetails = await getEventDataForLock(lockAddress, network) + const eventDetails = await getEventMetadataForLock(lockAddress, network) return response.status(200).send(eventDetails) } diff --git a/locksmith/src/controllers/v2/hooksController.ts b/locksmith/src/controllers/v2/hooksController.ts index 613aa9b2c17..d965ca93749 100644 --- a/locksmith/src/controllers/v2/hooksController.ts +++ b/locksmith/src/controllers/v2/hooksController.ts @@ -5,6 +5,11 @@ import normalizer from '../../utils/normalizer' import { getSettings } from '../../operations/lockSettingOperations' import { ethers } from 'ethers' import { getSignerFromOnKeyPurchaserHookOnLock } from '../../fulfillment/dispatcher' +import { + checkMultipleScores, + submitAddressForScoring, +} from '../../operations/gitcoinVerification' +import logger from '../../logger' const guildHookQuery = z.object({ network: z.preprocess((a) => parseInt(z.string().parse(a), 10), z.number()), @@ -60,3 +65,147 @@ export const guildHook: RequestHandler = async (request, response) => { result: accesses, }) } + +// schema for validating and parsing incoming request queries using Zod +const gitcoinHookQuery = z.object({ + network: z.preprocess((a) => parseInt(z.string().parse(a), 10), z.number()), + lockAddress: z.string(), + recipients: z + .preprocess((a) => { + // preprocess to ensure recipients is always an array of strings + if (typeof a === 'string') return [a] + return a + }, z.array(z.string())) + // transform each recipient address using a normalization function + .transform((items) => + items.map((item) => normalizer.ethereumAddress(item)) + ), +}) + +/** + * The `gitcoinHook` function is designed to handle the scoring and verification process for recipients (typically wallet addresses) + * submitted through a request. This process involves several key steps: + * 1. Parsing and validating the input parameters from the request, including network details, recipient addresses, and lock address. + * 2. Submitting each recipient's address for scoring, initiating an asynchronous process that calculates their respective scores + * based on predefined criteria (via `submitAddressForScoring`). + * 3. Retrieving a wallet that is capable of signing messages, which is necessary for generating cryptographic signatures as a form of + * verification for recipients with scores above a certain threshold. + * 4. Fetching the scores for all submitted recipients, utilizing a batch or collective approach for efficiency. + * 5. Evaluating each recipient's score to determine if it exceeds the defined threshold (in this case, a score greater than 20). + * Recipients with qualifying scores are then provided with a signature generated using the retrieved wallet, serving as a form + * of validation or access granting. Recipients not meeting the score requirement receive an empty string, indicating a lack of + * qualification. + * 6. Compiling and responding with the results, which include either signatures for qualified recipients or empty strings for + * those who did not qualify, effectively communicating the outcome of the verification process. + * + + */ + +// polling mechanism parameters +const pollingConfig = { + // maximum number of attempts before "giving up" + maxAttempts: 5, + // initial delay in milliseconds before the first retry is attempted + initialDelay: 3500, + // factor by which to multiply the delay between retries + backoffFactor: 2, +} + +export const gitcoinHook: RequestHandler = async (request, response) => { + const { network, recipients, lockAddress } = + await gitcoinHookQuery.parseAsync(request.query) + + // retrieve the required Gitcoin Passport score for the lock + const settings = await getSettings({ + lockAddress, + network, + }) + + // ensure that requiredGitcoinPassportScore is defined + if ( + !settings?.requiredGitcoinPassportScore || + settings?.requiredGitcoinPassportScore === null + ) { + // if the check fails, respond with an appropriate error message + return response.status(400).json({ + error: 'The required Gitcoin Passport score is not defined or invalid.', + }) + } + + const requiredScore = settings.requiredGitcoinPassportScore + + try { + // submit each recipient for scoring + await Promise.all( + recipients.map((recipient) => submitAddressForScoring(recipient)) + ) + + // retrieve the wallet for signing, ensuring it's available before generating signatures + const wallet = await getSignerFromOnKeyPurchaserHookOnLock({ + lockAddress, + network, + }) + + if (!wallet) { + return response.status(422).json({ + error: 'This lock has a misconfigured Gitcoin Passport hook.', + }) + } + + let attempts = 0 + let scoresReady = false + let delay = pollingConfig.initialDelay + let scoresResponse + + while (attempts < pollingConfig.maxAttempts && !scoresReady) { + try { + scoresResponse = await checkMultipleScores(recipients) + scoresReady = true + } catch (error) { + logger.error(error) + attempts++ + await new Promise((resolve) => setTimeout(resolve, delay)) + // Apply backoff factor to delay between retries + delay *= pollingConfig.backoffFactor + } + } + + if (!scoresReady) { + return response.status(504).json({ + error: 'Timeout: Unable to verify scores within expected time frame.', + }) + } + + // generate signatures for recipients with valid scores + const generatedSignatures = scoresResponse.map(async (recipient: any) => { + // only sign recipients who have a score that meets the specified threshold in the lock settings + if (recipient && recipient.score >= requiredScore) { + const message = recipient.address.toLowerCase() + const messageHash = ethers.utils.solidityKeccak256( + ['string'], + [message] + ) + const signature = await wallet.signMessage( + ethers.utils.arrayify(messageHash) + ) + return signature + } else { + return '' + } + }) + + // wait for all signatures to be generated + const signatures = await Promise.all(generatedSignatures) + + // send the signatures + return response.status(200).send({ + result: signatures, + }) + } catch (error) { + // log and send errors if encountered + logger.error('Error in Gitcoin score verification:', error) + return response + .status(500) + .json({ error: 'Error verifying Gitcoin scores.' }) + } +} diff --git a/locksmith/src/controllers/v2/lockSettingController.ts b/locksmith/src/controllers/v2/lockSettingController.ts index 4dc1fc44923..7f75ec02d36 100644 --- a/locksmith/src/controllers/v2/lockSettingController.ts +++ b/locksmith/src/controllers/v2/lockSettingController.ts @@ -64,6 +64,15 @@ const LockSettingSchema = z.object({ }) .optional(), promoCodes: z.array(z.string()).optional().optional(), + + requiredGitcoinPassportScore: z + .preprocess( + (a) => parseInt(z.string().parse(a), 10), + z.number({ + description: 'Required Gitcoin Passport score for the Gitcoin Hook.', + }) + ) + .nullish(), passwords: z.array(z.string()).optional().optional(), }) @@ -81,6 +90,7 @@ export const DEFAULT_LOCK_SETTINGS: LockSettingProps = { creditCardCurrency: 'usd', crossmintClientId: undefined, promoCodes: [], + requiredGitcoinPassportScore: undefined, passwords: [], } diff --git a/locksmith/src/controllers/v2/rsvpController.ts b/locksmith/src/controllers/v2/rsvpController.ts index f3a7ed2cdad..fb814c8dcd7 100644 --- a/locksmith/src/controllers/v2/rsvpController.ts +++ b/locksmith/src/controllers/v2/rsvpController.ts @@ -6,7 +6,7 @@ import { KeyManager } from '@unlock-protocol/unlock-js' import { UserMetadata } from './metadataController' import { Rsvp } from '../../models' import { sendEmail } from '../../operations/wedlocksOperations' -import { getEventDataForLock } from '../../operations/eventOperations' +import { getEventMetadataForLock } from '../../operations/eventOperations' const RsvpBody = z.object({ data: z.record(z.string(), z.string()), @@ -76,7 +76,7 @@ export const rsvp = async (request: Request, response: Response) => { }) // Then, send email - const eventDetail = await getEventDataForLock(lockAddress, network) + const eventDetail = await getEventMetadataForLock(lockAddress, network) sendEmail({ network, template: 'eventRsvpSubmitted', diff --git a/locksmith/src/fulfillment/dispatcher.ts b/locksmith/src/fulfillment/dispatcher.ts index ece765b34c1..415042ce973 100644 --- a/locksmith/src/fulfillment/dispatcher.ts +++ b/locksmith/src/fulfillment/dispatcher.ts @@ -148,17 +148,21 @@ export const getSignerFromOnKeyPurchaserHookOnLock = async function ({ // Ok let's now select a purchaser that is set as signer, or throw an Error! // Can we do Promise.all to reduce latency? for (let i = 0; i < purchasers.length; i++) { - const isSigner = await hook - .signers(await purchasers[i].getAddress()) - .catch((e: any) => { - logger.error(e) - return false - }) + const purchaserAddress = await purchasers[i].getAddress() + const isSigner = await hook.signers(purchaserAddress).catch((e: any) => { + logger.error(e) + return false + }) if (isSigner) { wallet = purchasers[i] break } } + if (!wallet) { + logger.error( + `None of the locksmiths purchasers are signers on the hook at ${hookAddress} on ${network}` + ) + } return wallet } diff --git a/locksmith/src/models/lockSetting.ts b/locksmith/src/models/lockSetting.ts index 8bb26407402..035ec6562ed 100644 --- a/locksmith/src/models/lockSetting.ts +++ b/locksmith/src/models/lockSetting.ts @@ -18,6 +18,7 @@ export class LockSetting extends Model< declare crossmintClientId?: string | null declare hookGuildId?: number | null declare unlockFeeChargedToUser?: boolean + declare requiredGitcoinPassportScore?: number | null declare createdAt: CreationOptional declare updatedAt: CreationOptional declare promoCodes?: string[] | null @@ -89,6 +90,11 @@ LockSetting.init( allowNull: true, defaultValue: [], }, + requiredGitcoinPassportScore: { + type: DataTypes.INTEGER, + allowNull: true, + defaultValue: null, + }, passwords: { type: DataTypes.ARRAY(DataTypes.STRING), allowNull: true, diff --git a/locksmith/src/operations/eventOperations.ts b/locksmith/src/operations/eventOperations.ts index 0a66061027f..830b993d8ae 100644 --- a/locksmith/src/operations/eventOperations.ts +++ b/locksmith/src/operations/eventOperations.ts @@ -2,9 +2,10 @@ import dayjs from '../config/dayjs' import { kebabCase } from 'lodash' import * as metadataOperations from './metadataOperations' import { PaywallConfig, getLockTypeByMetadata } from '@unlock-protocol/core' -import { EventData } from '../models' +import { CheckoutConfig, EventData } from '../models' import { saveCheckoutConfig } from './checkoutConfigOperations' import { EventBodyType } from '../controllers/v2/eventsController' +import { Op } from 'sequelize' interface AttributeProps { value: string @@ -36,7 +37,31 @@ const getEventDate = ( return null } -export const getEventDataForLock = async ( +export const getEventForLock = async ( + lockAddress: string, + network?: number +) => { + const checkoutConfigs = await CheckoutConfig.findAll({ + where: { + [Op.or]: [ + { [`config.locks.${lockAddress}.network`]: network }, + { [`config.locks.${lockAddress.toLowerCase()}.network`]: network }, + ], + }, + order: [['updatedAt', 'DESC']], + }) + + // If there are checkout configs, let's see if an even exists with them! + // Let's now find any event that uses this checkout config! + const event = await EventData.findOne({ + where: { + checkoutConfigId: checkoutConfigs.map((record) => record.id), + }, + }) + return event +} + +export const getEventMetadataForLock = async ( lockAddress: string, network?: number ): Promise => { diff --git a/locksmith/src/operations/gitcoinVerification.ts b/locksmith/src/operations/gitcoinVerification.ts new file mode 100644 index 00000000000..9b8a2b3bd13 --- /dev/null +++ b/locksmith/src/operations/gitcoinVerification.ts @@ -0,0 +1,163 @@ +import fetch from 'isomorphic-fetch' +// Configuration module for accessing project settings +import config from '../config/config' + +// Retrieve Gitcoin API key and Scorer ID from the configuration +const gitcoinApiKey = config.gitcoinApiKey +const gitcoinScorerId = config.gitcoinScorerId + +// Interface describing the structure of a score response from Gitcoin API +interface ScoreResponse { + address: string + score: number + status: string +} + +// Custom error class for handling score submission errors +class ScoreSubmissionError extends Error { + constructor(message: string) { + super(message) + this.name = 'ScoreSubmissionError' + } +} + +// Custom error class for handling score retrieval errors +class ScoreRetrievalError extends Error { + constructor(message: string) { + super(message) + this.name = 'ScoreRetrievalError' + } +} + +/** + * Submits an Ethereum address for scoring to the Gitcoin Passport API. + * @param {string} address - The Ethereum address to submit for scoring. + * @throws {Error} Throws an error if the Gitcoin API key is not defined. + * @throws {ScoreSubmissionError} Throws a ScoreSubmissionError if the submission fails. + */ +export async function submitAddressForScoring(address: string): Promise { + if (!gitcoinApiKey) { + throw new Error('Gitcoin API key is not defined.') + } + + const headers = { + 'Content-Type': 'application/json', + 'X-API-KEY': gitcoinApiKey, + } + + const body = JSON.stringify({ + address, + scorer_id: gitcoinScorerId, + }) + + // Perform the POST request to submit the address for scoring + const response = await fetch( + 'https://api.scorer.gitcoin.co/registry/submit-passport', + { + method: 'POST', + headers, + body, + } + ) + + // Await and log the raw response for debugging purposes + const rawResponse = await response.json() + + // Handle non-200 response statuses by throwing a ScoreSubmissionError + if (!response.ok) { + throw new ScoreSubmissionError( + `Failed to submit address for scoring: ${response.statusText} and ${gitcoinScorerId}` + ) + } + + return rawResponse +} + +/** + * Retrieves scores for submitted addresses from the Gitcoin Passport API and filters them to include only the scores for the specified recipients. + * @param {string[]} recipients An array of recipient addresses to filter the scores for. + * @throws {Error} Throws an error if the Gitcoin API key is not defined. + * @throws {ScoreRetrievalError} Throws a ScoreRetrievalError if fetching scores fails. + * @returns {Promise} A promise that resolves to the scores of recipients. + */ +export async function checkMultipleScores(recipients: string[]): Promise { + if (!gitcoinApiKey) { + throw new Error('Gitcoin API key is not defined.') + } + + const headers = { + 'Content-Type': 'application/json', + 'X-API-KEY': gitcoinApiKey, + } + + // Perform the GET request to retrieve scores + const response = await fetch( + `https://api.scorer.gitcoin.co/registry/score/${gitcoinScorerId}`, + { + method: 'GET', + headers, + } + ) + + // Handle non-200 response statuses by throwing a ScoreRetrievalError + if (!response.ok) { + throw new ScoreRetrievalError( + `Failed to get scores: ${response.statusText}` + ) + } + + // Parse the JSON response and simplify it to include only relevant information + const jsonResponse = await response.json() + + const recipientScores = jsonResponse.items + .filter((item: any) => + recipients.some( + (recipient) => recipient.toLowerCase() === item.address.toLowerCase() + ) + ) + .map((item: any) => ({ + address: item.address, + score: parseFloat(item.score), // Ensure score is treated as a number + status: item.status, + })) + + // Return the simplified scores object + return recipientScores +} + +/** + * Retrieves the score for a single Ethereum address from the Gitcoin Passport API. + * @param {string} address - The Ethereum address whose score is to be retrieved. + * @throws {Error} Throws an error if the Gitcoin API key is not defined. + * @throws {ScoreRetrievalError} Throws a ScoreRetrievalError if fetching the score fails. + * @returns {Promise} A promise that resolves to the score response. + */ +export async function checkSingleScore( + address: string +): Promise { + if (!gitcoinApiKey) { + throw new Error('Gitcoin API key is not defined.') + } + + const headers = { + 'Content-Type': 'application/json', + 'X-API-KEY': gitcoinApiKey, + } + + // Perform the GET request to retrieve the score for a single address + const response = await fetch( + `https://api.scorer.gitcoin.co/registry/score/${gitcoinScorerId}/${address}`, + { + method: 'GET', + headers, + } + ) + + // Handle non-200 response statuses by throwing a ScoreRetrievalError + if (!response.ok) { + throw new ScoreRetrievalError(`Failed to get score: ${response.statusText}`) + } + + // Return the parsed JSON response as a ScoreResponse object + return response.json() as Promise +} diff --git a/locksmith/src/operations/lockSettingOperations.ts b/locksmith/src/operations/lockSettingOperations.ts index 2dab8c9c90e..8bebe7631ad 100644 --- a/locksmith/src/operations/lockSettingOperations.ts +++ b/locksmith/src/operations/lockSettingOperations.ts @@ -4,6 +4,7 @@ import { } from '../controllers/v2/lockSettingController' import { LockSetting } from '../models/lockSetting' import * as Normalizer from '../utils/normalizer' +import { getEventForLock } from './eventOperations' interface SendEmailProps { lockAddress: string @@ -52,13 +53,24 @@ export async function getSettings({ }, }) - const res = settings || DEFAULT_LOCK_SETTINGS + const lockSettings = settings || DEFAULT_LOCK_SETTINGS + + const eventDetails = await getEventForLock(lockAddress, network) + if (eventDetails?.data) { + if (eventDetails?.data.replyTo) { + lockSettings.replyTo = eventDetails.data.replyTo + } + if (eventDetails?.data.emailSender) { + lockSettings.emailSender = eventDetails.data.emailSender + } + } + attributesExcludes.forEach((attr) => { // @ts-expect-error Element implicitly has an 'any' type because expression of type 'string' can't be used to index type - delete res[attr] + delete lockSettings[attr] }) - return res + return lockSettings } export async function getLockSettingsBySlug( diff --git a/locksmith/src/operations/metadataOperations.ts b/locksmith/src/operations/metadataOperations.ts index e12b3fd1a96..4a1ce557eb9 100644 --- a/locksmith/src/operations/metadataOperations.ts +++ b/locksmith/src/operations/metadataOperations.ts @@ -10,9 +10,8 @@ import * as lockOperations from './lockOperations' import { Attribute } from '../types' import metadata from '../config/metadata' import { getDefaultLockData } from '../utils/metadata' -import { CheckoutConfig, EventData } from '../models' import { getEventUrl } from '../utils/eventHelpers' -import { Op } from 'sequelize' +import { getEventForLock } from './eventOperations' interface IsKeyOrLockOwnerOptions { userAddress?: string @@ -290,27 +289,8 @@ export const getLockMetadata = async ({ } } - // Now let's see if there is an event data that needs to be attached - // find checkout URLs that include this lock - // We look for both cases... because I am not sure how to look for - // keys in an insensitive way! - const checkoutConfigs = await CheckoutConfig.findAll({ - where: { - [Op.or]: [ - { [`config.locks.${lockAddress}.network`]: network }, - { [`config.locks.${lockAddress.toLowerCase()}.network`]: network }, - ], - }, - order: [['updatedAt', 'DESC']], - }) - - // If there are checkout configs, let's see if an even exists with them! - // Let's now find any event that uses this checkout config! - const event = await EventData.findOne({ - where: { - checkoutConfigId: checkoutConfigs.map((record) => record.id), - }, - }) + // Now let's see if there is an event data that needs to be attached to this lock! + const event = await getEventForLock(lockAddress, network) // Add the event data! if (event) { diff --git a/locksmith/src/operations/pricingOperations.ts b/locksmith/src/operations/pricingOperations.ts index 0eb88493d32..5597f8ca282 100644 --- a/locksmith/src/operations/pricingOperations.ts +++ b/locksmith/src/operations/pricingOperations.ts @@ -30,7 +30,6 @@ interface Price { price: number timestamp: number confidence: number - creditCardEnabled: boolean } export interface Options { diff --git a/locksmith/src/operations/wedlocksOperations.ts b/locksmith/src/operations/wedlocksOperations.ts index 50133d9fc8b..0bd53d2a2ed 100644 --- a/locksmith/src/operations/wedlocksOperations.ts +++ b/locksmith/src/operations/wedlocksOperations.ts @@ -11,7 +11,7 @@ import * as emailOperations from './emailOperations' import * as lockSettingOperations from './lockSettingOperations' import * as userMetadataOperations from './userMetadataOperations' import { createEventIcs } from '../utils/calendar' -import { EventProps, getEventDataForLock } from './eventOperations' +import { EventProps, getEventMetadataForLock } from './eventOperations' import { LockSetting } from '../models/lockSetting' import { DEFAULT_LOCK_SETTINGS, @@ -412,7 +412,7 @@ export const notifyNewKeyToWedlocks = async (key: Key, network: number) => { // get event details only when lock is event if (isEvent) { - eventDetail = await getEventDataForLock(lockAddress, network) + eventDetail = await getEventMetadataForLock(lockAddress, network) } if (isCertification && tokenId) { diff --git a/locksmith/src/routes/v2/hooks.ts b/locksmith/src/routes/v2/hooks.ts index b981750a9e4..542f4329677 100644 --- a/locksmith/src/routes/v2/hooks.ts +++ b/locksmith/src/routes/v2/hooks.ts @@ -1,8 +1,10 @@ import express from 'express' -import { guildHook } from '../../controllers/v2/hooksController' +import { gitcoinHook, guildHook } from '../../controllers/v2/hooksController' const router = express.Router({ mergeParams: true }) router.get('/guild', guildHook) +router.get('/gitcoin', gitcoinHook) + export default router diff --git a/locksmith/src/routes/v2/images.ts b/locksmith/src/routes/v2/images.ts index 5f2314d11f5..34ee33483d6 100644 --- a/locksmith/src/routes/v2/images.ts +++ b/locksmith/src/routes/v2/images.ts @@ -31,7 +31,6 @@ export const upload = multer({ } }, storage: multerS3({ - // @ts-expect-error Type 'import("/Users/julien/repos/unlock/node_modules/@aws-sdk/client-s3/dist-types/S3Client").S3Client' is not assignable to type 'import("/Users/julien/repos/unlock/node_modules/@types/multer-s3/node_modules/@aws-sdk/client-s3/dist-types/S3Client").S3Client'. Types of property 'config' are incompatible. s3: storageClient, // Cloudflare R2 does not support other ACLs schemes. See: https://developers.cloudflare.com/r2/data-access/s3-api/api/ // That said, we only require public-read. diff --git a/locksmith/src/utils/ethPrice.ts b/locksmith/src/utils/ethPrice.ts deleted file mode 100644 index dee6eac4661..00000000000 --- a/locksmith/src/utils/ethPrice.ts +++ /dev/null @@ -1,25 +0,0 @@ -const https = require('https') - -// DEPRECATED! -export const getPrice = async (): Promise => { - return new Promise((resolve, reject) => { - https - .get('https://api.coinbase.com/v2/prices/ETH-USD/buy', (resp: any) => { - let data = '' - - // A chunk of data has been recieved. - resp.on('data', (chunk: string) => { - data += chunk - }) - - // The whole response has been received. Print out the result. - resp.on('end', () => { - const body = JSON.parse(data) - resolve(parseFloat(body.data.amount)) - }) - }) - .on('error', (err: any) => { - reject(err) - }) - }) -} diff --git a/locksmith/src/utils/gasPrice.ts b/locksmith/src/utils/gasPrice.ts index 03704aee915..3428b9fec39 100644 --- a/locksmith/src/utils/gasPrice.ts +++ b/locksmith/src/utils/gasPrice.ts @@ -1,7 +1,6 @@ import { ethers, utils, BigNumber } from 'ethers' import networks from '@unlock-protocol/networks' - -import PriceConversion from './priceConversion' +import { getDefiLammaPrice } from '../operations/pricingOperations' export default class GasPrice { // gasCost is expressed in gas, returns cost in base currency (ether on mainnet...) @@ -24,9 +23,13 @@ export default class GasPrice { } const gasPrice = await this.gasPriceETH(network, gasCost) - const symbol = networks[network].nativeCurrency?.symbol || 'ETH' // default to ether - const priceConversion = new PriceConversion() - const usdPrice = await priceConversion.convertToUSD(symbol, gasPrice) - return usdPrice + const price = await getDefiLammaPrice({ + network, + amount: gasPrice, + }) + if (!price.priceInAmount) { + throw new Error(`Price not available`) + } + return Math.ceil(price.priceInAmount * 100) } } diff --git a/locksmith/src/utils/keyPricer.ts b/locksmith/src/utils/keyPricer.ts index 009247e4287..a76ee78dc81 100644 --- a/locksmith/src/utils/keyPricer.ts +++ b/locksmith/src/utils/keyPricer.ts @@ -1,9 +1,8 @@ -import { ethers } from 'ethers' import { Web3Service } from '@unlock-protocol/unlock-js' import networks from '@unlock-protocol/networks' -import PriceConversion from './priceConversion' import { GAS_COST_TO_GRANT } from './constants' import { getProviderForNetwork, getPurchaser } from '../fulfillment/dispatcher' +import GasPrice from './gasPrice' // @deprecated - Remove once no longer used anywhere. Use functions in pricing.ts instead. export default class KeyPricer { @@ -22,28 +21,22 @@ export default class KeyPricer { if (networks[network].fullySubsidizedGas) { return { canAfford: true } } - const [provider, wallet] = await Promise.all([ - getProviderForNetwork(network), - getPurchaser({ network }), + const [gasCost, balance] = await Promise.all([ + new GasPrice().gasPriceUSD(network, GAS_COST_TO_GRANT), + (await getProviderForNetwork(network)).getBalance( + await (await getPurchaser({ network })).getAddress() + ), ]) - const [gasPrice, balance] = await Promise.all([ - provider.getGasPrice(), - provider.getBalance(await wallet.getAddress()), - ]) - const gasCost = gasPrice.mul(GAS_COST_TO_GRANT) // Balance is too low to afford the gas cost if (balance.lt(gasCost)) { return { canAfford: false, reason: 'Insufficient purchaser balance' } } - // And now check the value in USD - const symbol = networks[network].nativeCurrency.symbol - const priceConversion = new PriceConversion() - const usdPrice = await priceConversion.convertToUSD( - symbol, - parseFloat(ethers.utils.formatEther(gasCost).toString()) - ) - if (usdPrice > networks[network].maxFreeClaimCost!) { - return { canAfford: false, reason: `Gas costs too high: $${usdPrice}` } + + if (gasCost > networks[network].maxFreeClaimCost!) { + return { + canAfford: false, + reason: `Gas costs too high: $${gasCost / 100}`, + } } return { canAfford: true } } diff --git a/locksmith/src/utils/priceConversion.ts b/locksmith/src/utils/priceConversion.ts deleted file mode 100644 index 4f44494485e..00000000000 --- a/locksmith/src/utils/priceConversion.ts +++ /dev/null @@ -1,46 +0,0 @@ -import fetch from 'isomorphic-fetch' - -interface PricesCache { - [currency: string]: [timestamp: number, price: number] -} - -const cache: PricesCache = {} - -export default class PriceConversion { - client: any - - /** - * Returns the USD cents price of a currency amount - * @param currency - * @param lockPriceAmount in cents - * @returns - */ - async convertToUSD(currency: string, lockPriceAmount: number) { - const cached = cache[currency] - let rate - // Cache is valid for 5 minutes! - if (cached && cached[0] > new Date().getTime() - 1000 * 60 * 5) { - return parseInt((cached[1] * lockPriceAmount * 100).toFixed(0)) - } else { - const response = await fetch( - `https://api.coinbase.com/v2/prices/${currency}-USD/buy` - ) - - if (!response.ok) { - throw new Error(`USD price not available on coinbase`) - } - - const { data } = await response.json() - const amount = data?.amount - - if (!amount) { - throw new Error('Amount is invalid') - } - - cache[currency] = [new Date().getTime(), parseFloat(amount)] - rate = parseFloat(amount) - } - - return parseInt((rate * lockPriceAmount * 100).toFixed(0)) - } -} diff --git a/locksmith/src/worker/helpers/renewKey.ts b/locksmith/src/worker/helpers/renewKey.ts index 3f6726ba3c2..3d15324de23 100644 --- a/locksmith/src/worker/helpers/renewKey.ts +++ b/locksmith/src/worker/helpers/renewKey.ts @@ -4,9 +4,9 @@ import networks from '@unlock-protocol/networks' import { KeyRenewal } from '../../models' import GasPrice from '../../utils/gasPrice' -import PriceConversion from '../../utils/priceConversion' import Dispatcher from '../../fulfillment/dispatcher' import logger from '../../logger' +import { getDefiLammaPrice } from '../../operations/pricingOperations' // multiply factor to increase precision for gas calculations const BASE_POINT_ACCURACY = 1000 @@ -42,10 +42,13 @@ const getGasFee = async (network: number, gasCost: number) => { } // calculate price of any ERC20 to USD cents -const getERC20AmountInUSD = async (symbol: string, amount: string) => { - const conversion = new PriceConversion() - const priceUSD = await conversion.convertToUSD(symbol, parseFloat(amount)) - return priceUSD * BASE_POINT_ACCURACY +export const getRefundAmountInUSD = async (network: number, amount: string) => { + const { priceInAmount: priceUSD } = await getDefiLammaPrice({ + network, + amount: parseFloat(amount) * BASE_POINT_ACCURACY, + }) + + return priceUSD || 0 } export const isWorthRenewing = async ( @@ -91,8 +94,10 @@ export const isWorthRenewing = async ( const gasRefund = await lock.gasRefundValue() // get ERC20 info - const { currencySymbol, currencyContractAddress } = - await web3Service.getLock(lockAddress, network) + const { currencyContractAddress } = await web3Service.getLock( + lockAddress, + network + ) const abi = ['function decimals() public view returns (uint decimals)'] const tokenContract = new Contract(currencyContractAddress, abi, provider) const decimals = await tokenContract.decimals() @@ -117,8 +122,9 @@ export const isWorthRenewing = async ( // find costs in USD cents const costToRenew = await getGasFee(network, gasLimit.toNumber()) - const costRefunded = await getERC20AmountInUSD( - currencySymbol, + + const costRefunded = await getRefundAmountInUSD( + network, ethers.utils.formatUnits(gasRefund, decimals) ) diff --git a/packages/contracts/CHANGELOG.md b/packages/contracts/CHANGELOG.md index eab934f2a32..abd49df663c 100644 --- a/packages/contracts/CHANGELOG.md +++ b/packages/contracts/CHANGELOG.md @@ -1,6 +1,10 @@ # CHANGELOG -## 0.0.22 +## 0.0.25 + +- update `UnlockSwapBurner` to latest version using Uniswap `UniversalRouter` + +## 0.0.22-0.0.24 - add `contracts` alias for all versions - add `PublicLock` and `Unlock` alias for all versions diff --git a/packages/contracts/package.json b/packages/contracts/package.json index 3aac5ca197e..39af53c1b2f 100644 --- a/packages/contracts/package.json +++ b/packages/contracts/package.json @@ -1,6 +1,6 @@ { "name": "@unlock-protocol/contracts", - "version": "0.0.24", + "version": "0.0.25", "main": "dist/index.js", "scripts": { "clean": "rm -rf dist docs src/index.ts", diff --git a/packages/contracts/src/abis/utils/UnlockSwapBurner.json b/packages/contracts/src/abis/utils/UnlockSwapBurner.json index 19012ae38ce..40353a85dec 100644 --- a/packages/contracts/src/abis/utils/UnlockSwapBurner.json +++ b/packages/contracts/src/abis/utils/UnlockSwapBurner.json @@ -17,7 +17,7 @@ }, { "internalType": "address", - "name": "_uniswapRouter", + "name": "_uniswapUniversalRouter", "type": "address" } ], @@ -28,7 +28,7 @@ "inputs": [ { "internalType": "address", - "name": "uniswapRouter", + "name": "uniswapUniversalRouter", "type": "address" }, { @@ -132,7 +132,7 @@ }, { "inputs": [], - "name": "uniswapRouter", + "name": "uniswapUniversalRouter", "outputs": [ { "internalType": "address", @@ -161,8 +161,8 @@ "type": "receive" } ], - "bytecode": "0x608060405234801561000f575f80fd5b50604051610aeb380380610aeb83398101604081905261002e9161008a565b5f80546001600160a01b039485166001600160a01b0319918216179091556001805493851693821693909317909255600280549190931691161790556100ca565b80516001600160a01b0381168114610085575f80fd5b919050565b5f805f6060848603121561009c575f80fd5b6100a58461006f565b92506100b36020850161006f565b91506100c16040850161006f565b90509250925092565b610a14806100d75f395ff3fe60806040526004361061004c575f3560e01c806312261ee7146100575780632ef8e1671461009357806370d5ae05146100b4578063735de9f7146100c9578063b30929cd146100e8575f80fd5b3661005357005b5f80fd5b348015610062575f80fd5b50600154610076906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6100a66100a13660046107f8565b610106565b60405190815260200161008a565b3480156100bf575f80fd5b5061007661dead81565b3480156100d4575f80fd5b50600254610076906001600160a01b031681565b3480156100f3575f80fd5b505f54610076906001600160a01b031681565b5f80546040805163262d0a8560e01b8152905183926001600160a01b03169163262d0a859160048083019260209291908290030181865afa15801561014d573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906101719190610836565b90505f805f9054906101000a90046001600160a01b03166001600160a01b0316633fc8cef36040518163ffffffff1660e01b8152600401602060405180830381865afa1580156101c3573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906101e79190610836565b90505f6101f38661062d565b9050826001600160a01b0316866001600160a01b0316036102275760405163aa3cc2ad60e01b815260040160405180910390fd5b6001600160a01b03861661029457816001600160a01b031663d0e30db0826040518263ffffffff1660e01b81526004015f604051808303818588803b15801561026e575f80fd5b505af1158015610280573d5f803e3d5ffd5b50505050508195506102918661062d565b90505b6001600160a01b03861615610331576002546102bb9087906001600160a01b0316836106af565b60015460405163095ea7b360e01b81526001600160a01b038881169263095ea7b3926102ef92909116908590600401610858565b6020604051808303815f875af115801561030b573d5f803e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061032f9190610871565b505b6001546002546001600160a01b03918216916387517c4591899116610355856107b4565b61036042603c610890565b6040516001600160e01b031960e087901b1681526001600160a01b03948516600482015292841660248401529216604482015265ffffffffffff90911660648201526084015f604051808303815f87803b1580156103bc575f80fd5b505af11580156103ce573d5f803e3d5ffd5b5050604080516001600160601b0319606087811b8216602084015261017760eb1b603484015288901b1660378201528151808203602b01815260eb82019092529092505f9150604b01806001600160a01b038a81169087161461045457898985604051602001610440939291906108d1565b604051602081830303815290604052610456565b835b815230602082015260400161046c42603c610890565b8152602081018590525f6040918201819052600254915163c04b8d5960e01b8152929350916001600160a01b039091169063c04b8d59906104b190859060040161091a565b6020604051808303815f875af11580156104cd573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906104f19190610988565b9050805f0361052d5760025460405163fa0392e960e01b8152610524916001600160a01b0316908b90879060040161099f565b60405180910390fd5b60405163a9059cbb60e01b81525f906001600160a01b0388169063a9059cbb9061055f9061dead908690600401610858565b6020604051808303815f875af115801561057b573d5f803e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061059f9190610871565b90508015155f036105d45760025460405163fa0392e960e01b8152610524916001600160a01b0316908c90889060040161099f565b604080516001600160a01b038c168152602081018790529081018390527fffc421788049cd9552ceb1be68395519e4a86c07e24ff133db48d1b16a2f9df09060600160405180910390a150955050505050505b92915050565b5f6001600160a01b038216156106a8576040516370a0823160e01b81523060048201526001600160a01b038316906370a0823190602401602060405180830381865afa15801561067f573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906106a39190610988565b610627565b4792915050565b5f80846001600160a01b031663095ea7b360e01b85856040516024016106d6929190610858565b60408051601f198184030181529181526020820180516001600160e01b03166001600160e01b031990941693909317909252905161071491906109c3565b5f604051808303815f865af19150503d805f811461074d576040519150601f19603f3d011682016040523d82523d5f602084013e610752565b606091505b509150915081801561077c57508051158061077c57508080602001905181019061077c9190610871565b6107ad5760405162461bcd60e51b8152602060048201526002602482015261534160f01b6044820152606401610524565b5050505050565b5f6001600160a01b038211156107dd5760405163c4bd89a960e01b815260040160405180910390fd5b5090565b6001600160a01b03811681146107f5575f80fd5b50565b5f8060408385031215610809575f80fd5b8235610814816107e1565b9150602083013562ffffff8116811461082b575f80fd5b809150509250929050565b5f60208284031215610846575f80fd5b8151610851816107e1565b9392505050565b6001600160a01b03929092168252602082015260400190565b5f60208284031215610881575f80fd5b81518015158114610851575f80fd5b8082018082111561062757634e487b7160e01b5f52601160045260245ffd5b5f5b838110156108c95781810151838201526020016108b1565b50505f910152565b606084901b6001600160601b031916815260e883901b6001600160e81b031916601482015281515f9061090b8160178501602087016108af565b91909101601701949350505050565b602081525f825160a0602084015280518060c08501526109418160e08601602085016108af565b60018060a01b0360208601511660408501526040850151606085015260608501516080850152608085015160a085015260e0601f19601f8301168501019250505092915050565b5f60208284031215610998575f80fd5b5051919050565b6001600160a01b039384168152919092166020820152604081019190915260600190565b5f82516109d48184602087016108af565b919091019291505056fea26469706673582212204450d7ac974593aa653a36fc69e17836dd25ae648864c9ba4ac4d3e2ca5b101064736f6c63430008150033", - "deployedBytecode": "0x60806040526004361061004c575f3560e01c806312261ee7146100575780632ef8e1671461009357806370d5ae05146100b4578063735de9f7146100c9578063b30929cd146100e8575f80fd5b3661005357005b5f80fd5b348015610062575f80fd5b50600154610076906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6100a66100a13660046107f8565b610106565b60405190815260200161008a565b3480156100bf575f80fd5b5061007661dead81565b3480156100d4575f80fd5b50600254610076906001600160a01b031681565b3480156100f3575f80fd5b505f54610076906001600160a01b031681565b5f80546040805163262d0a8560e01b8152905183926001600160a01b03169163262d0a859160048083019260209291908290030181865afa15801561014d573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906101719190610836565b90505f805f9054906101000a90046001600160a01b03166001600160a01b0316633fc8cef36040518163ffffffff1660e01b8152600401602060405180830381865afa1580156101c3573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906101e79190610836565b90505f6101f38661062d565b9050826001600160a01b0316866001600160a01b0316036102275760405163aa3cc2ad60e01b815260040160405180910390fd5b6001600160a01b03861661029457816001600160a01b031663d0e30db0826040518263ffffffff1660e01b81526004015f604051808303818588803b15801561026e575f80fd5b505af1158015610280573d5f803e3d5ffd5b50505050508195506102918661062d565b90505b6001600160a01b03861615610331576002546102bb9087906001600160a01b0316836106af565b60015460405163095ea7b360e01b81526001600160a01b038881169263095ea7b3926102ef92909116908590600401610858565b6020604051808303815f875af115801561030b573d5f803e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061032f9190610871565b505b6001546002546001600160a01b03918216916387517c4591899116610355856107b4565b61036042603c610890565b6040516001600160e01b031960e087901b1681526001600160a01b03948516600482015292841660248401529216604482015265ffffffffffff90911660648201526084015f604051808303815f87803b1580156103bc575f80fd5b505af11580156103ce573d5f803e3d5ffd5b5050604080516001600160601b0319606087811b8216602084015261017760eb1b603484015288901b1660378201528151808203602b01815260eb82019092529092505f9150604b01806001600160a01b038a81169087161461045457898985604051602001610440939291906108d1565b604051602081830303815290604052610456565b835b815230602082015260400161046c42603c610890565b8152602081018590525f6040918201819052600254915163c04b8d5960e01b8152929350916001600160a01b039091169063c04b8d59906104b190859060040161091a565b6020604051808303815f875af11580156104cd573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906104f19190610988565b9050805f0361052d5760025460405163fa0392e960e01b8152610524916001600160a01b0316908b90879060040161099f565b60405180910390fd5b60405163a9059cbb60e01b81525f906001600160a01b0388169063a9059cbb9061055f9061dead908690600401610858565b6020604051808303815f875af115801561057b573d5f803e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061059f9190610871565b90508015155f036105d45760025460405163fa0392e960e01b8152610524916001600160a01b0316908c90889060040161099f565b604080516001600160a01b038c168152602081018790529081018390527fffc421788049cd9552ceb1be68395519e4a86c07e24ff133db48d1b16a2f9df09060600160405180910390a150955050505050505b92915050565b5f6001600160a01b038216156106a8576040516370a0823160e01b81523060048201526001600160a01b038316906370a0823190602401602060405180830381865afa15801561067f573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906106a39190610988565b610627565b4792915050565b5f80846001600160a01b031663095ea7b360e01b85856040516024016106d6929190610858565b60408051601f198184030181529181526020820180516001600160e01b03166001600160e01b031990941693909317909252905161071491906109c3565b5f604051808303815f865af19150503d805f811461074d576040519150601f19603f3d011682016040523d82523d5f602084013e610752565b606091505b509150915081801561077c57508051158061077c57508080602001905181019061077c9190610871565b6107ad5760405162461bcd60e51b8152602060048201526002602482015261534160f01b6044820152606401610524565b5050505050565b5f6001600160a01b038211156107dd5760405163c4bd89a960e01b815260040160405180910390fd5b5090565b6001600160a01b03811681146107f5575f80fd5b50565b5f8060408385031215610809575f80fd5b8235610814816107e1565b9150602083013562ffffff8116811461082b575f80fd5b809150509250929050565b5f60208284031215610846575f80fd5b8151610851816107e1565b9392505050565b6001600160a01b03929092168252602082015260400190565b5f60208284031215610881575f80fd5b81518015158114610851575f80fd5b8082018082111561062757634e487b7160e01b5f52601160045260245ffd5b5f5b838110156108c95781810151838201526020016108b1565b50505f910152565b606084901b6001600160601b031916815260e883901b6001600160e81b031916601482015281515f9061090b8160178501602087016108af565b91909101601701949350505050565b602081525f825160a0602084015280518060c08501526109418160e08601602085016108af565b60018060a01b0360208601511660408501526040850151606085015260608501516080850152608085015160a085015260e0601f19601f8301168501019250505092915050565b5f60208284031215610998575f80fd5b5051919050565b6001600160a01b039384168152919092166020820152604081019190915260600190565b5f82516109d48184602087016108af565b919091019291505056fea26469706673582212204450d7ac974593aa653a36fc69e17836dd25ae648864c9ba4ac4d3e2ca5b101064736f6c63430008150033", + "bytecode": "0x608060405234801561000f575f80fd5b50604051610c08380380610c0883398101604081905261002e9161008a565b5f80546001600160a01b039485166001600160a01b0319918216179091556001805493851693821693909317909255600280549190931691161790556100ca565b80516001600160a01b0381168114610085575f80fd5b919050565b5f805f6060848603121561009c575f80fd5b6100a58461006f565b92506100b36020850161006f565b91506100c16040850161006f565b90509250925092565b610b31806100d75f395ff3fe60806040526004361061004c575f3560e01c806312261ee7146100575780632ef8e1671461009357806370d5ae05146100b4578063a5c414a6146100c9578063b30929cd146100e8575f80fd5b3661005357005b5f80fd5b348015610062575f80fd5b50600154610076906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6100a66100a136600461086d565b610106565b60405190815260200161008a565b3480156100bf575f80fd5b5061007661dead81565b3480156100d4575f80fd5b50600254610076906001600160a01b031681565b3480156100f3575f80fd5b505f54610076906001600160a01b031681565b5f80546040805163262d0a8560e01b8152905183926001600160a01b03169163262d0a859160048083019260209291908290030181865afa15801561014d573d5f803e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061017191906108ab565b90505f805f9054906101000a90046001600160a01b03166001600160a01b0316633fc8cef36040518163ffffffff1660e01b8152600401602060405180830381865afa1580156101c3573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906101e791906108ab565b90505f6101f3866106a2565b90505f6101ff846106a2565b9050836001600160a01b0316876001600160a01b0316036102335760405163aa3cc2ad60e01b815260040160405180910390fd5b6001600160a01b0387166102a057826001600160a01b031663d0e30db0836040518263ffffffff1660e01b81526004015f604051808303818588803b15801561027a575f80fd5b505af115801561028c573d5f803e3d5ffd5b505050505082965061029d876106a2565b91505b6001600160a01b0387161561033d576002546102c79088906001600160a01b031684610724565b60015460405163095ea7b360e01b81526001600160a01b038981169263095ea7b3926102fb929091169086906004016108cd565b6020604051808303815f875af1158015610317573d5f803e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061033b91906108e6565b505b6001546002546001600160a01b03918216916387517c45918a911661036186610829565b61036c42603c610919565b6040516001600160e01b031960e087901b1681526001600160a01b03948516600482015292841660248401529216604482015265ffffffffffff90911660648201526084015f604051808303815f87803b1580156103c8575f80fd5b505af11580156103da573d5f803e3d5ffd5b5050604080516001600160601b0319606088811b8216602084015261017760eb1b603484015289901b1660378201528151808203602b018152604b820183525f606b83018190528351808403604c0181526001606c850181815260ac860190965292965094509291608c015b606081526020019060019003908161044657905050905030855f886001600160a01b03168d6001600160a01b0316146104a2578c8c8760405160200161048e9392919061094e565b6040516020818303038152906040526104a4565b855b60016040516020016104ba9594939291906109c2565b604051602081830303815290604052815f815181106104db576104db610a05565b60209081029190910101526002546001600160a01b0316633593564c838361050442603c610919565b6040518463ffffffff1660e01b815260040161052293929190610a19565b5f604051808303815f87803b158015610539575f80fd5b505af115801561054b573d5f803e3d5ffd5b505050505f8461055a896106a2565b6105649190610a92565b9050805f036105a05760025460405163fa0392e960e01b8152610597916001600160a01b0316908d908990600401610aa5565b60405180910390fd5b60405163a9059cbb60e01b81525f906001600160a01b038a169063a9059cbb906105d29061dead9086906004016108cd565b6020604051808303815f875af11580156105ee573d5f803e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061061291906108e6565b90508015155f036106475760025460405163fa0392e960e01b8152610597916001600160a01b0316908e908a90600401610aa5565b604080516001600160a01b038e168152602081018990529081018390527fffc421788049cd9552ceb1be68395519e4a86c07e24ff133db48d1b16a2f9df09060600160405180910390a1509750505050505050505b92915050565b5f6001600160a01b0382161561071d576040516370a0823160e01b81523060048201526001600160a01b038316906370a0823190602401602060405180830381865afa1580156106f4573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906107189190610ac9565b61069c565b4792915050565b5f80846001600160a01b031663095ea7b360e01b858560405160240161074b9291906108cd565b60408051601f198184030181529181526020820180516001600160e01b03166001600160e01b03199094169390931790925290516107899190610ae0565b5f604051808303815f865af19150503d805f81146107c2576040519150601f19603f3d011682016040523d82523d5f602084013e6107c7565b606091505b50915091508180156107f15750805115806107f15750808060200190518101906107f191906108e6565b6108225760405162461bcd60e51b8152602060048201526002602482015261534160f01b6044820152606401610597565b5050505050565b5f6001600160a01b038211156108525760405163c4bd89a960e01b815260040160405180910390fd5b5090565b6001600160a01b038116811461086a575f80fd5b50565b5f806040838503121561087e575f80fd5b823561088981610856565b9150602083013562ffffff811681146108a0575f80fd5b809150509250929050565b5f602082840312156108bb575f80fd5b81516108c681610856565b9392505050565b6001600160a01b03929092168252602082015260400190565b5f602082840312156108f6575f80fd5b815180151581146108c6575f80fd5b634e487b7160e01b5f52601160045260245ffd5b8082018082111561069c5761069c610905565b5f5b8381101561094657818101518382015260200161092e565b50505f910152565b606084901b6001600160601b031916815260e883901b6001600160e81b031916601482015281515f9061098881601785016020870161092c565b91909101601701949350505050565b5f81518084526109ae81602086016020860161092c565b601f01601f19169290920160200192915050565b60018060a01b038616815284602082015260ff8416604082015260a060608201525f6109f160a0830185610997565b905082151560808301529695505050505050565b634e487b7160e01b5f52603260045260245ffd5b606081525f610a2b6060830186610997565b6020838203818501528186518084528284019150828160051b8501018389015f5b83811015610a7a57601f19878403018552610a68838351610997565b94860194925090850190600101610a4c565b50508095505050505050826040830152949350505050565b8181038181111561069c5761069c610905565b6001600160a01b039384168152919092166020820152604081019190915260600190565b5f60208284031215610ad9575f80fd5b5051919050565b5f8251610af181846020870161092c565b919091019291505056fea2646970667358221220b554c63c34198c2f944b927623b53e2e5591a1346669c64f98194f9a024665cd64736f6c63430008150033", + "deployedBytecode": "0x60806040526004361061004c575f3560e01c806312261ee7146100575780632ef8e1671461009357806370d5ae05146100b4578063a5c414a6146100c9578063b30929cd146100e8575f80fd5b3661005357005b5f80fd5b348015610062575f80fd5b50600154610076906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6100a66100a136600461086d565b610106565b60405190815260200161008a565b3480156100bf575f80fd5b5061007661dead81565b3480156100d4575f80fd5b50600254610076906001600160a01b031681565b3480156100f3575f80fd5b505f54610076906001600160a01b031681565b5f80546040805163262d0a8560e01b8152905183926001600160a01b03169163262d0a859160048083019260209291908290030181865afa15801561014d573d5f803e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061017191906108ab565b90505f805f9054906101000a90046001600160a01b03166001600160a01b0316633fc8cef36040518163ffffffff1660e01b8152600401602060405180830381865afa1580156101c3573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906101e791906108ab565b90505f6101f3866106a2565b90505f6101ff846106a2565b9050836001600160a01b0316876001600160a01b0316036102335760405163aa3cc2ad60e01b815260040160405180910390fd5b6001600160a01b0387166102a057826001600160a01b031663d0e30db0836040518263ffffffff1660e01b81526004015f604051808303818588803b15801561027a575f80fd5b505af115801561028c573d5f803e3d5ffd5b505050505082965061029d876106a2565b91505b6001600160a01b0387161561033d576002546102c79088906001600160a01b031684610724565b60015460405163095ea7b360e01b81526001600160a01b038981169263095ea7b3926102fb929091169086906004016108cd565b6020604051808303815f875af1158015610317573d5f803e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061033b91906108e6565b505b6001546002546001600160a01b03918216916387517c45918a911661036186610829565b61036c42603c610919565b6040516001600160e01b031960e087901b1681526001600160a01b03948516600482015292841660248401529216604482015265ffffffffffff90911660648201526084015f604051808303815f87803b1580156103c8575f80fd5b505af11580156103da573d5f803e3d5ffd5b5050604080516001600160601b0319606088811b8216602084015261017760eb1b603484015289901b1660378201528151808203602b018152604b820183525f606b83018190528351808403604c0181526001606c850181815260ac860190965292965094509291608c015b606081526020019060019003908161044657905050905030855f886001600160a01b03168d6001600160a01b0316146104a2578c8c8760405160200161048e9392919061094e565b6040516020818303038152906040526104a4565b855b60016040516020016104ba9594939291906109c2565b604051602081830303815290604052815f815181106104db576104db610a05565b60209081029190910101526002546001600160a01b0316633593564c838361050442603c610919565b6040518463ffffffff1660e01b815260040161052293929190610a19565b5f604051808303815f87803b158015610539575f80fd5b505af115801561054b573d5f803e3d5ffd5b505050505f8461055a896106a2565b6105649190610a92565b9050805f036105a05760025460405163fa0392e960e01b8152610597916001600160a01b0316908d908990600401610aa5565b60405180910390fd5b60405163a9059cbb60e01b81525f906001600160a01b038a169063a9059cbb906105d29061dead9086906004016108cd565b6020604051808303815f875af11580156105ee573d5f803e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061061291906108e6565b90508015155f036106475760025460405163fa0392e960e01b8152610597916001600160a01b0316908e908a90600401610aa5565b604080516001600160a01b038e168152602081018990529081018390527fffc421788049cd9552ceb1be68395519e4a86c07e24ff133db48d1b16a2f9df09060600160405180910390a1509750505050505050505b92915050565b5f6001600160a01b0382161561071d576040516370a0823160e01b81523060048201526001600160a01b038316906370a0823190602401602060405180830381865afa1580156106f4573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906107189190610ac9565b61069c565b4792915050565b5f80846001600160a01b031663095ea7b360e01b858560405160240161074b9291906108cd565b60408051601f198184030181529181526020820180516001600160e01b03166001600160e01b03199094169390931790925290516107899190610ae0565b5f604051808303815f865af19150503d805f81146107c2576040519150601f19603f3d011682016040523d82523d5f602084013e6107c7565b606091505b50915091508180156107f15750805115806107f15750808060200190518101906107f191906108e6565b6108225760405162461bcd60e51b8152602060048201526002602482015261534160f01b6044820152606401610597565b5050505050565b5f6001600160a01b038211156108525760405163c4bd89a960e01b815260040160405180910390fd5b5090565b6001600160a01b038116811461086a575f80fd5b50565b5f806040838503121561087e575f80fd5b823561088981610856565b9150602083013562ffffff811681146108a0575f80fd5b809150509250929050565b5f602082840312156108bb575f80fd5b81516108c681610856565b9392505050565b6001600160a01b03929092168252602082015260400190565b5f602082840312156108f6575f80fd5b815180151581146108c6575f80fd5b634e487b7160e01b5f52601160045260245ffd5b8082018082111561069c5761069c610905565b5f5b8381101561094657818101518382015260200161092e565b50505f910152565b606084901b6001600160601b031916815260e883901b6001600160e81b031916601482015281515f9061098881601785016020870161092c565b91909101601701949350505050565b5f81518084526109ae81602086016020860161092c565b601f01601f19169290920160200192915050565b60018060a01b038616815284602082015260ff8416604082015260a060608201525f6109f160a0830185610997565b905082151560808301529695505050505050565b634e487b7160e01b5f52603260045260245ffd5b606081525f610a2b6060830186610997565b6020838203818501528186518084528284019150828160051b8501018389015f5b83811015610a7a57601f19878403018552610a68838351610997565b94860194925090850190600101610a4c565b50508095505050505050826040830152949350505050565b8181038181111561069c5761069c610905565b6001600160a01b039384168152919092166020820152604081019190915260600190565b5f60208284031215610ad9575f80fd5b5051919050565b5f8251610af181846020870161092c565b919091019291505056fea2646970667358221220b554c63c34198c2f944b927623b53e2e5591a1346669c64f98194f9a024665cd64736f6c63430008150033", "linkReferences": {}, "deployedLinkReferences": {} } diff --git a/packages/contracts/src/contracts/utils/UnlockSwapBurner.sol b/packages/contracts/src/contracts/utils/UnlockSwapBurner.sol index e4cf582dbcb..f3e4ad260e3 100644 --- a/packages/contracts/src/contracts/utils/UnlockSwapBurner.sol +++ b/packages/contracts/src/contracts/utils/UnlockSwapBurner.sol @@ -1,108 +1,92 @@ -// Sources flattened with hardhat v2.18.3 https://hardhat.org +// Sources flattened with hardhat v2.20.1 https://hardhat.org -// SPDX-License-Identifier: GPL-2.0-or-later AND MIT +// SPDX-License-Identifier: GPL-2.0-or-later AND GPL-3.0-or-later AND MIT -pragma abicoder v2; +// File @openzeppelin/contracts/utils/introspection/IERC165.sol@v4.9.5 -// File @uniswap/v3-core/contracts/interfaces/callback/IUniswapV3SwapCallback.sol@v1.0.1 +// Original license: SPDX_License_Identifier: MIT +// OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol) -// Original license: SPDX_License_Identifier: GPL-2.0-or-later -pragma solidity >=0.5.0; - -/// @title Callback for IUniswapV3PoolActions#swap -/// @notice Any contract that calls IUniswapV3PoolActions#swap must implement this interface -interface IUniswapV3SwapCallback { - /// @notice Called to `msg.sender` after executing a swap via IUniswapV3Pool#swap. - /// @dev In the implementation you must pay the pool tokens owed for the swap. - /// The caller of this method must be checked to be a UniswapV3Pool deployed by the canonical UniswapV3Factory. - /// amount0Delta and amount1Delta can both be 0 if no tokens were swapped. - /// @param amount0Delta The amount of token0 that was sent (negative) or must be received (positive) by the pool by - /// the end of the swap. If positive, the callback must send that amount of token0 to the pool. - /// @param amount1Delta The amount of token1 that was sent (negative) or must be received (positive) by the pool by - /// the end of the swap. If positive, the callback must send that amount of token1 to the pool. - /// @param data Any data passed through by the caller via the IUniswapV3PoolActions#swap call - function uniswapV3SwapCallback( - int256 amount0Delta, - int256 amount1Delta, - bytes calldata data - ) external; -} +pragma solidity ^0.8.0; -// File @uniswap/v3-periphery/contracts/interfaces/ISwapRouter.sol@v1.4.4 +/** + * @dev Interface of the ERC165 standard, as defined in the + * https://eips.ethereum.org/EIPS/eip-165[EIP]. + * + * Implementers can declare support of contract interfaces, which can then be + * queried by others ({ERC165Checker}). + * + * For an implementation, see {ERC165}. + */ +interface IERC165 { + /** + * @dev Returns true if this contract implements the interface defined by + * `interfaceId`. See the corresponding + * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] + * to learn more about how these ids are created. + * + * This function call must use less than 30 000 gas. + */ + function supportsInterface(bytes4 interfaceId) external view returns (bool); +} -// Original license: SPDX_License_Identifier: GPL-2.0-or-later -pragma solidity >=0.7.5; - -// Original pragma directive: pragma abicoder v2 - -/// @title Router token swapping functionality -/// @notice Functions for swapping tokens via Uniswap V3 -interface ISwapRouter is IUniswapV3SwapCallback { - struct ExactInputSingleParams { - address tokenIn; - address tokenOut; - uint24 fee; - address recipient; - uint256 deadline; - uint256 amountIn; - uint256 amountOutMinimum; - uint160 sqrtPriceLimitX96; - } +// File @openzeppelin/contracts/token/ERC1155/IERC1155Receiver.sol@v4.9.5 - /// @notice Swaps `amountIn` of one token for as much as possible of another token - /// @param params The parameters necessary for the swap, encoded as `ExactInputSingleParams` in calldata - /// @return amountOut The amount of the received token - function exactInputSingle( - ExactInputSingleParams calldata params - ) external payable returns (uint256 amountOut); - - struct ExactInputParams { - bytes path; - address recipient; - uint256 deadline; - uint256 amountIn; - uint256 amountOutMinimum; - } +// Original license: SPDX_License_Identifier: MIT +// OpenZeppelin Contracts (last updated v4.5.0) (token/ERC1155/IERC1155Receiver.sol) - /// @notice Swaps `amountIn` of one token for as much as possible of another along the specified path - /// @param params The parameters necessary for the multi-hop swap, encoded as `ExactInputParams` in calldata - /// @return amountOut The amount of the received token - function exactInput( - ExactInputParams calldata params - ) external payable returns (uint256 amountOut); - - struct ExactOutputSingleParams { - address tokenIn; - address tokenOut; - uint24 fee; - address recipient; - uint256 deadline; - uint256 amountOut; - uint256 amountInMaximum; - uint160 sqrtPriceLimitX96; - } +pragma solidity ^0.8.0; - /// @notice Swaps as little as possible of one token for `amountOut` of another token - /// @param params The parameters necessary for the swap, encoded as `ExactOutputSingleParams` in calldata - /// @return amountIn The amount of the input token - function exactOutputSingle( - ExactOutputSingleParams calldata params - ) external payable returns (uint256 amountIn); - - struct ExactOutputParams { - bytes path; - address recipient; - uint256 deadline; - uint256 amountOut; - uint256 amountInMaximum; - } +/** + * @dev _Available since v3.1._ + */ +interface IERC1155Receiver is IERC165 { + /** + * @dev Handles the receipt of a single ERC1155 token type. This function is + * called at the end of a `safeTransferFrom` after the balance has been updated. + * + * NOTE: To accept the transfer, this must return + * `bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)"))` + * (i.e. 0xf23a6e61, or its own function selector). + * + * @param operator The address which initiated the transfer (i.e. msg.sender) + * @param from The address which previously owned the token + * @param id The ID of the token being transferred + * @param value The amount of tokens being transferred + * @param data Additional data with no specified format + * @return `bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)"))` if transfer is allowed + */ + function onERC1155Received( + address operator, + address from, + uint256 id, + uint256 value, + bytes calldata data + ) external returns (bytes4); - /// @notice Swaps as little as possible of one token for `amountOut` of another along the specified path (reversed) - /// @param params The parameters necessary for the multi-hop swap, encoded as `ExactOutputParams` in calldata - /// @return amountIn The amount of the input token - function exactOutput( - ExactOutputParams calldata params - ) external payable returns (uint256 amountIn); + /** + * @dev Handles the receipt of a multiple ERC1155 token types. This function + * is called at the end of a `safeBatchTransferFrom` after the balances have + * been updated. + * + * NOTE: To accept the transfer(s), this must return + * `bytes4(keccak256("onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)"))` + * (i.e. 0xbc197c81, or its own function selector). + * + * @param operator The address which initiated the batch transfer (i.e. msg.sender) + * @param from The address which previously owned the token + * @param ids An array containing ids of each token being transferred (order and length must match values array) + * @param values An array containing amounts of each token being transferred (order and length must match ids array) + * @param data Additional data with no specified format + * @return `bytes4(keccak256("onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)"))` if transfer is allowed + */ + function onERC1155BatchReceived( + address operator, + address from, + uint256[] calldata ids, + uint256[] calldata values, + bytes calldata data + ) external returns (bytes4); } // File @openzeppelin/contracts/token/ERC20/IERC20.sol@v4.9.5 @@ -251,6 +235,73 @@ library TransferHelper { } } +// File @openzeppelin/contracts/token/ERC721/IERC721Receiver.sol@v4.9.5 + +// Original license: SPDX_License_Identifier: MIT +// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/IERC721Receiver.sol) + +pragma solidity ^0.8.0; + +/** + * @title ERC721 token receiver interface + * @dev Interface for any contract that wants to support safeTransfers + * from ERC721 asset contracts. + */ +interface IERC721Receiver { + /** + * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom} + * by `operator` from `from`, this function is called. + * + * It must return its Solidity selector to confirm the token transfer. + * If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted. + * + * The selector can be obtained in Solidity with `IERC721Receiver.onERC721Received.selector`. + */ + function onERC721Received( + address operator, + address from, + uint256 tokenId, + bytes calldata data + ) external returns (bytes4); +} + +// File contracts/interfaces/IUniversalRouter.sol + +// Original license: SPDX_License_Identifier: GPL-3.0-or-later +pragma solidity ^0.8.17; + +interface IUniversalRouter is IERC721Receiver, IERC1155Receiver { + /// @notice Thrown when a required command has failed + error ExecutionFailed(uint256 commandIndex, bytes message); + + /// @notice Thrown when attempting to send ETH directly to the contract + error ETHNotAccepted(); + + /// @notice Thrown when executing commands with an expired deadline + error TransactionDeadlinePassed(); + + /// @notice Thrown when attempting to execute commands and an incorrect number of inputs are provided + error LengthMismatch(); + + /// @notice Executes encoded commands along with provided inputs. + /// @param commands A set of concatenated commands, each 1 byte in length + /// @param inputs An array of byte strings containing abi encoded inputs for each command + function execute( + bytes calldata commands, + bytes[] calldata inputs + ) external payable; + + /// @notice Executes encoded commands along with provided inputs. Reverts if deadline has expired. + /// @param commands A set of concatenated commands, each 1 byte in length + /// @param inputs An array of byte strings containing abi encoded inputs for each command + /// @param deadline The deadline by which the transaction must be executed + function execute( + bytes calldata commands, + bytes[] calldata inputs, + uint256 deadline + ) external payable; +} + // File contracts/interfaces/IMintableERC20.sol // Original license: SPDX_License_Identifier: MIT @@ -673,17 +724,24 @@ contract UnlockSwapBurner { // required by Uniswap Universal Router address public permit2; - address public uniswapRouter; + address public uniswapUniversalRouter; // dead address to burn address public constant burnAddress = 0x000000000000000000000000000000000000dEaD; + // specified in https://docs.uniswap.org/contracts/universal-router/technical-reference#v3_swap_exact_in + uint256 constant V3_SWAP_EXACT_IN = 0x00; + // events event SwapBurn(address tokenAddress, uint amountSpent, uint amountBurnt); // errors - error UDTSwapFailed(address uniswapRouter, address tokenIn, uint amount); + error UDTSwapFailed( + address uniswapUniversalRouter, + address tokenIn, + uint amount + ); error UnauthorizedSwap(); /** @@ -694,11 +752,11 @@ contract UnlockSwapBurner { constructor( address _unlockAddress, address _permit2Address, - address _uniswapRouter + address _uniswapUniversalRouter ) { unlockAddress = _unlockAddress; permit2 = _permit2Address; - uniswapRouter = _uniswapRouter; + uniswapUniversalRouter = _uniswapUniversalRouter; } /** @@ -725,6 +783,7 @@ contract UnlockSwapBurner { // get total balance of token to swap uint tokenAmount = getBalance(tokenAddress); + uint udtBefore = getBalance(udtAddress); if (tokenAddress == udtAddress) { revert UnauthorizedSwap(); @@ -740,7 +799,11 @@ contract UnlockSwapBurner { // approve ERC20 spending if (tokenAddress != address(0)) { // Approve the router to spend src ERC20 - TransferHelper.safeApprove(tokenAddress, uniswapRouter, tokenAmount); + TransferHelper.safeApprove( + tokenAddress, + uniswapUniversalRouter, + tokenAmount + ); // approve PERMIT2 to manipulate the token IERC20(tokenAddress).approve(permit2, tokenAmount); @@ -749,7 +812,7 @@ contract UnlockSwapBurner { // issue PERMIT2 Allowance IPermit2(permit2).approve( tokenAddress, - uniswapRouter, + uniswapUniversalRouter, tokenAmount.toUint160(), uint48(block.timestamp + 60) // expires after 1min ); @@ -760,27 +823,36 @@ contract UnlockSwapBurner { udtAddress ); - // executes the swap token > WETH > UDT - ISwapRouter.ExactInputParams memory params = ISwapRouter.ExactInputParams({ - path: tokenAddress == wrappedAddress + // encode parameters for the swap om UniversalRouter + bytes memory commands = abi.encodePacked(bytes1(uint8(V3_SWAP_EXACT_IN))); + bytes[] memory inputs = new bytes[](1); + inputs[0] = abi.encode( + address(this), // recipient + tokenAmount, // amountIn + 0, // amountOutMinimum + tokenAddress == wrappedAddress ? defaultPath - : abi.encodePacked(tokenAddress, poolFee, defaultPath), - recipient: address(this), - deadline: block.timestamp + 60, // expires after 1min - amountIn: tokenAmount, - amountOutMinimum: 0 - }); + : abi.encodePacked(tokenAddress, poolFee, defaultPath), // path + true // funds are coming from PERMIT2 + ); // Executes the swap. - uint amountUDTOut = ISwapRouter(uniswapRouter).exactInput(params); + IUniversalRouter(uniswapUniversalRouter).execute( + commands, + inputs, + block.timestamp + 60 // expires after 1min + ); + + // calculate how much UDT has been received + uint amountUDTOut = getBalance(udtAddress) - udtBefore; if (amountUDTOut == 0) { - revert UDTSwapFailed(uniswapRouter, tokenAddress, tokenAmount); + revert UDTSwapFailed(uniswapUniversalRouter, tokenAddress, tokenAmount); } - // burn the UDT + // burn the newly recevied UDT bool success = IERC20(udtAddress).transfer(burnAddress, amountUDTOut); if (success == false) { - revert UDTSwapFailed(uniswapRouter, tokenAddress, tokenAmount); + revert UDTSwapFailed(uniswapUniversalRouter, tokenAddress, tokenAmount); } else { emit SwapBurn(tokenAddress, tokenAmount, amountUDTOut); } diff --git a/packages/core/src/schema.ts b/packages/core/src/schema.ts index db92efc377f..770b041a77f 100644 --- a/packages/core/src/schema.ts +++ b/packages/core/src/schema.ts @@ -326,6 +326,8 @@ export const EventObject = z.object({ image: z.string().url(), description: z.string(), requiresApproval: z.boolean(), + emailSender: z.string(), + replyTo: z.string(), ticket: z.object({ event_cover_image: z.string(), event_start_date: z.string(), diff --git a/packages/crypto-icon/.storybook/main.ts b/packages/crypto-icon/.storybook/main.ts index d5ba3391e9b..2754028cd1f 100644 --- a/packages/crypto-icon/.storybook/main.ts +++ b/packages/crypto-icon/.storybook/main.ts @@ -3,18 +3,7 @@ import tsconfigPaths from 'vite-tsconfig-paths' import svgr from 'vite-plugin-svgr' export default { stories: ['../lib/**/*.stories.mdx', '../lib/**/*.stories.@(js|jsx|ts|tsx)'], - addons: [ - '@storybook/addon-links', - '@storybook/addon-essentials', - { - name: '@storybook/addon-postcss', - options: { - postcssLoaderOptions: { - implementation: require('postcss'), - }, - }, - }, - ], + addons: ['@storybook/addon-links', '@storybook/addon-essentials'], framework: '@storybook/react-vite', async viteFinal(config) { // Merge custom configuration into the default config diff --git a/packages/crypto-icon/package.json b/packages/crypto-icon/package.json index 4e09c3cfbcc..3cd233e5e0e 100644 --- a/packages/crypto-icon/package.json +++ b/packages/crypto-icon/package.json @@ -34,8 +34,7 @@ "@storybook/addon-docs": "7.0.18", "@storybook/addon-essentials": "7.0.18", "@storybook/addon-links": "7.0.18", - "@storybook/addon-postcss": "3.0.0-alpha.1", - "@storybook/react": "7.0.18", + "@storybook/react": "7.6.3", "@storybook/react-vite": "7.0.18", "@types/react": "18.2.46", "@types/react-dom": "18.2.18", diff --git a/packages/email-templates/src/templates/custom.ts b/packages/email-templates/src/templates/custom.ts index 26865ebcc24..664651e5a1b 100644 --- a/packages/email-templates/src/templates/custom.ts +++ b/packages/email-templates/src/templates/custom.ts @@ -4,7 +4,7 @@ import { formattedCustomContent } from './helpers/customContent' Handlebars.registerHelper('formattedCustomContent', formattedCustomContent) export default { - subject: `{{subject}}"`, + subject: `{{subject}}`, html: ` {{formattedCustomContent "Contract Manager" content}}

If you do not want to receive emails for this person, you can unsubscribe.

diff --git a/packages/hardhat-helpers/src/fork.js b/packages/hardhat-helpers/src/fork.js index f1cf16759fe..d28a857e463 100644 --- a/packages/hardhat-helpers/src/fork.js +++ b/packages/hardhat-helpers/src/fork.js @@ -26,7 +26,7 @@ async function getWhales(chainId = 1) { switch (chainId) { case 1: return { - [tokens.DAI]: '0x075e72a5eDf65F0A5f44699c7654C1a76941Ddc8', // PulseX + [tokens.DAI]: '0x4DEDf26112B3Ec8eC46e7E31EA5e123490B05B8B', // PulseX [tokens.USDC]: '0x8EB8a3b98659Cce290402893d0123abb75E3ab28', [tokens.WBTC]: '0x845cbCb8230197F733b59cFE1795F282786f212C', [tokens.UDT]: '0xF5C28ce24Acf47849988f147d5C75787c0103534', // unlock-protocol.eth @@ -219,12 +219,14 @@ const getDelegates = async () => { return await Promise.all(delegates.map((delegate) => impersonate(delegate))) } -const getERC20Contract = async (tokenAddress) => { +const getERC20Contract = async (tokenAddress, signer) => { const { ethers } = require('hardhat') const { nativeCurrency: { wrapped }, } = await getNetwork() - const [signer] = await ethers.getSigners() + if (!signer) { + ;[signer] = await ethers.getSigners() + } return tokenAddress === wrapped ? await ethers.getContractAt(WETH_ABI, wrapped, signer) : await ethers.getContractAt(ERC20_ABI, tokenAddress, signer) diff --git a/packages/networks/bin/check-tokens.ts b/packages/networks/bin/check-tokens.ts index 313e8dee02b..7250c12b8c6 100644 --- a/packages/networks/bin/check-tokens.ts +++ b/packages/networks/bin/check-tokens.ts @@ -6,6 +6,12 @@ const run = async () => { for (const networkId in networks) { const network = networks[networkId] const provider = new ethers.JsonRpcProvider(network.provider) + const unlock = new ethers.Contract( + network.unlockAddress, + ['function uniswapOracles(address) view returns (address)'], + provider + ) + if (network.tokens) { for (const token of network.tokens) { const contract = new ethers.Contract(token.address, ERC20, provider) @@ -13,7 +19,6 @@ const run = async () => { const symbol = await contract.symbol() const name = await contract.name() const decimals = parseInt(await contract.decimals()) - if (decimals !== token.decimals) { console.error( `❌ Decimals mismatch for ${token.address} on ${networkId}. It needs to be "${decimals}"` @@ -29,6 +34,14 @@ const run = async () => { `❌ Symbol mismatch for ${token.address} on ${networkId}. It needs to be "${symbol}"` ) } + + // check if oracle is set in Unlock + const isSetInUnlock = await unlock.uniswapOracles(token.address) + if (isSetInUnlock === ethers.ZeroAddress) { + console.error( + `❌ Oracle for token ${name} (${symbol}) at ${token.address} on ${network.name} (${networkId}) is not set correctly` + ) + } } catch (error) { console.error( `❌ We could not verify ${token.address} on ${networkId}. ${error}` diff --git a/packages/networks/bin/doc.js b/packages/networks/bin/doc.js index 2c6a7016ad5..26688b396ba 100644 --- a/packages/networks/bin/doc.js +++ b/packages/networks/bin/doc.js @@ -10,11 +10,7 @@ const parseNetwork = ({ maxFreeClaimCost, }) => ` -### ${name} ${ - maxFreeClaimCost > 1 - ? "" - : '' - } +### ${name} ${description || ''} diff --git a/packages/networks/src/networks/arbitrum.ts b/packages/networks/src/networks/arbitrum.ts index 5882d275ca8..05f21982ea8 100644 --- a/packages/networks/src/networks/arbitrum.ts +++ b/packages/networks/src/networks/arbitrum.ts @@ -53,6 +53,11 @@ export const arbitrum: NetworkConfig = { id: HookType.PASSWORD_CAPPED, name: 'Passwords with caps. Multiple passwords can be used per contract', }, + { + address: '0x8e1158A7f9d0905602f90191AC4DFb30DD4Ee04C', + id: HookType.GITCOIN, + name: 'Gitcoin', + }, ], }, id: 42161, @@ -143,6 +148,10 @@ export const arbitrum: NetworkConfig = { universalRouterAddress: '0x4C60051384bd2d3C01bfc845Cf5F4b44bcbE9de5', }, unlockAddress: '0x1FF7e338d5E582138C46044dc238543Ce555C963', + unlockDaoToken: { + address: '0xd5d3aA404D7562d09a848F96a8a8d5D65977bF90', + mainnetBridge: '0xa3A7B6F88361F48403514059F1F16C8E78d60EeC', + }, url: 'https://arbitrum.io/', } diff --git a/packages/networks/src/networks/base-sepolia.ts b/packages/networks/src/networks/base-sepolia.ts index d2d6318ce6c..7c59d595fee 100644 --- a/packages/networks/src/networks/base-sepolia.ts +++ b/packages/networks/src/networks/base-sepolia.ts @@ -1,4 +1,4 @@ -import { NetworkConfig } from '@unlock-protocol/types' +import { HookType, NetworkConfig } from '@unlock-protocol/types' export const baseSepolia: NetworkConfig = { blockScan: { @@ -19,7 +19,15 @@ export const baseSepolia: NetworkConfig = { }, featured: false, fullySubsidizedGas: true, - hooks: {}, + hooks: { + onKeyPurchaseHook: [ + { + address: '0x8c5D54B2CAA4C2D08B0DDF82a1e6D2641779B8EC', + id: HookType.GITCOIN, + name: 'Gitcoin', + }, + ], + }, id: 84532, isTestNetwork: true, keyManagerAddress: '', @@ -68,7 +76,7 @@ export const baseSepolia: NetworkConfig = { ], unlockAddress: '0x259813B665C8f6074391028ef782e27B65840d89', unlockDaoToken: { - address: '', + address: '0x68a8011d72E6D41bf7CE9dC49De0aeaEBAAC9b39', }, } diff --git a/packages/networks/src/networks/base.ts b/packages/networks/src/networks/base.ts index 0ea82385c8a..f722b03efa8 100644 --- a/packages/networks/src/networks/base.ts +++ b/packages/networks/src/networks/base.ts @@ -46,6 +46,11 @@ export const base: NetworkConfig = { id: HookType.PASSWORD_CAPPED, name: 'Passwords with caps. Multiple passwords can be used per contract', }, + { + address: '0xbBBdD46ef548712c203d306F6587336EC15E0d7f', + id: HookType.GITCOIN, + name: 'Gitcoin', + }, ], }, id: 8453, @@ -125,6 +130,9 @@ export const base: NetworkConfig = { universalRouterAddress: '0x198EF79F1F515F02dFE9e3115eD9fC07183f02fC', }, unlockAddress: '0xd0b14797b9D08493392865647384974470202A78', + unlockDaoToken: { + address: '0xD7eA82D19f1f59FF1aE95F1945Ee6E6d86A25B96', + }, url: 'https://base.org/', } diff --git a/packages/networks/src/networks/bsc.ts b/packages/networks/src/networks/bsc.ts index e24abc06ddf..2282e6b56dd 100644 --- a/packages/networks/src/networks/bsc.ts +++ b/packages/networks/src/networks/bsc.ts @@ -53,6 +53,11 @@ export const bsc: NetworkConfig = { id: HookType.PASSWORD_CAPPED, name: 'Passwords with caps. Multiple passwords can be used per contract', }, + { + address: '0x5B6C5a766edBc6c7988108A689C96AfCEa95a2f1', + id: HookType.GITCOIN, + name: 'Gitcoin', + }, ], }, id: 56, diff --git a/packages/networks/src/networks/gnosis.ts b/packages/networks/src/networks/gnosis.ts index a3907cde3ad..8f859472bbc 100644 --- a/packages/networks/src/networks/gnosis.ts +++ b/packages/networks/src/networks/gnosis.ts @@ -55,6 +55,11 @@ export const gnosis: NetworkConfig = { id: HookType.PASSWORD_CAPPED, name: 'Passwords with caps. Multiple passwords can be used per contract', }, + { + address: '0xd6129cAC45a16187F4D09Dd69C512F68F0f2B371', + id: HookType.GITCOIN, + name: 'Gitcoin', + }, ], }, id: 100, diff --git a/packages/networks/src/networks/linea.ts b/packages/networks/src/networks/linea.ts index 3fe37a24fe4..46adf771bd7 100644 --- a/packages/networks/src/networks/linea.ts +++ b/packages/networks/src/networks/linea.ts @@ -66,7 +66,7 @@ export const linea: NetworkConfig = { name: 'Linea', nativeCurrency: { - coingecko: 'linea-eth', + coingecko: 'ethereum', decimals: 18, name: 'Linea Ether', symbol: 'ETH', diff --git a/packages/networks/src/networks/optimism.ts b/packages/networks/src/networks/optimism.ts index d818a26f854..30d8155d1fc 100644 --- a/packages/networks/src/networks/optimism.ts +++ b/packages/networks/src/networks/optimism.ts @@ -59,6 +59,11 @@ export const optimism: NetworkConfig = { id: HookType.PASSWORD_CAPPED, name: 'Passwords with caps. Multiple passwords can be used per contract', }, + { + address: '0x6a0971717ABFfCfE08f67b53DeAC5D234A6676Ed', + id: HookType.GITCOIN, + name: 'Gitcoin', + }, ], }, id: 10, @@ -152,6 +157,10 @@ export const optimism: NetworkConfig = { universalRouterAddress: '0xb555edF5dcF85f42cEeF1f3630a52A108E55A654', }, unlockAddress: '0x99b1348a9129ac49c6de7F11245773dE2f51fB0c', + unlockDaoToken: { + address: '0xc709c9116dBf29Da9c25041b13a07A0e68aC5d2D', + mainnetBridge: '0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1', + }, url: 'https://www.optimism.io/', } diff --git a/packages/networks/src/networks/sepolia.ts b/packages/networks/src/networks/sepolia.ts index 022c79f0fca..01285e9f729 100644 --- a/packages/networks/src/networks/sepolia.ts +++ b/packages/networks/src/networks/sepolia.ts @@ -113,7 +113,8 @@ export const sepolia: NetworkConfig = { }, ], uniswapV3: { - factoryAddress: '0xB7f907f7A9eBC822a80BD25E224be42Ce0A698A0', + factoryAddress: '0x0227628f3F023bb0B980b67D528571c95c6DaC1c', + oracle: '0x3A691355348DDC549515A7b538f3e85bCCdFe0B5', positionManager: '0x1238536071E1c677A632429e3655c799b22cDA52', universalRouterAddress: '0x3fC91A3afd70395Cd496C647d5a6CC9D4B2b7FAD', }, diff --git a/packages/networks/src/networks/zkevm.ts b/packages/networks/src/networks/zkevm.ts index 3de36118754..3c89ca031b1 100644 --- a/packages/networks/src/networks/zkevm.ts +++ b/packages/networks/src/networks/zkevm.ts @@ -24,6 +24,7 @@ export const zkevm: NetworkConfig = { multisig: '0xD62EF39c54d9100B17c8fA3C2D15e0262338AED0', name: 'zkEVM (Polygon)', nativeCurrency: { + coingecko: 'ethereum', decimals: 18, name: 'ETH', symbol: 'ETH', diff --git a/packages/networks/src/networks/zksync.ts b/packages/networks/src/networks/zksync.ts index ee3c3ec7827..c43a6652f4f 100644 --- a/packages/networks/src/networks/zksync.ts +++ b/packages/networks/src/networks/zksync.ts @@ -28,7 +28,7 @@ export const zksync: NetworkConfig = { multisig: '0xFa5592CE9C52FA5214ccEa10cB72Faa88eC80a3c', name: 'zkSync Era', nativeCurrency: { - coingecko: 'zksync-eth', + coingecko: 'ethereum', decimals: 18, name: 'zkSync Ether', symbol: 'ETH', @@ -42,6 +42,7 @@ export const zksync: NetworkConfig = { endpoint: 'https://api.studio.thegraph.com/query/65299/unlock-protocol-zksync/version/latest', networkName: 'zksync-era', + studioName: 'unlock-protocol-zksync', }, tokens: [ { diff --git a/packages/paywall/package.json b/packages/paywall/package.json index aede359283d..247b5ca2cf4 100644 --- a/packages/paywall/package.json +++ b/packages/paywall/package.json @@ -36,7 +36,7 @@ "eslint": "8.46.0", "tsup": "8.0.2", "typescript": "5.3.3", - "vite": "5.0.12", + "vite": "5.0.13", "vite-plugin-css-injected-by-js": "3.2.1", "vite-plugin-node-polyfills": "0.21.0", "vitest": "0.33.0", diff --git a/packages/types/src/types/unlockTypes.ts b/packages/types/src/types/unlockTypes.ts index 4a32b182cb0..5e6e3831773 100644 --- a/packages/types/src/types/unlockTypes.ts +++ b/packages/types/src/types/unlockTypes.ts @@ -141,7 +141,7 @@ export interface NetworkConfig { symbol: string address: string } | null - maxFreeClaimCost?: number + maxFreeClaimCost?: number // in cents! nativeCurrency: Omit startBlock?: number previousDeploys?: NetworkDeploy[] diff --git a/packages/ui/.storybook/main.ts b/packages/ui/.storybook/main.ts index 881dc121a85..dec1c2ddf4a 100644 --- a/packages/ui/.storybook/main.ts +++ b/packages/ui/.storybook/main.ts @@ -3,18 +3,7 @@ import tsconfigPaths from 'vite-tsconfig-paths' import svgr from 'vite-plugin-svgr' export default { stories: ['../lib/**/*.stories.mdx', '../lib/**/*.stories.@(js|jsx|ts|tsx)'], - addons: [ - '@storybook/addon-links', - '@storybook/addon-essentials', - { - name: '@storybook/addon-postcss', - options: { - postcssLoaderOptions: { - implementation: require('postcss'), - }, - }, - }, - ], + addons: ['@storybook/addon-links', '@storybook/addon-essentials'], staticDirs: ['../public'], framework: '@storybook/react-vite', async viteFinal(config) { diff --git a/packages/ui/lib/components/Form/Checkbox.stories.tsx b/packages/ui/lib/components/Form/Checkbox.stories.tsx new file mode 100644 index 00000000000..002014fdf3d --- /dev/null +++ b/packages/ui/lib/components/Form/Checkbox.stories.tsx @@ -0,0 +1,25 @@ +import { Checkbox } from './Checkbox' +import { Meta, StoryObj } from '@storybook/react' + +const meta = { + component: Checkbox, + title: 'Checkbox', +} satisfies Meta + +export default meta +type Story = StoryObj + +export const Normal = { + args: { + label: 'Is this a checkbox?', + description: 'Please check this box if you want to proceed with the action', + }, +} satisfies Story + +export const Error = { + args: { + label: 'Is this a checkbox?', + fieldSize: 'large', + error: 'Yes it is!', + }, +} satisfies Story diff --git a/packages/ui/lib/components/Form/Checkbox.tsx b/packages/ui/lib/components/Form/Checkbox.tsx new file mode 100644 index 00000000000..408a3d0f1af --- /dev/null +++ b/packages/ui/lib/components/Form/Checkbox.tsx @@ -0,0 +1,43 @@ +import { InputHTMLAttributes, forwardRef } from 'react' +import { FieldLayout } from './FieldLayout' +import { Size, SizeStyleProp } from '~/types' +import { twMerge } from 'tailwind-merge' + +interface CheckboxProps extends InputHTMLAttributes { + label: string + error?: string + description?: string + fieldSize?: Size +} + +export const SIZE_STYLES: SizeStyleProp = { + small: 'w-4 h-4 text-base md:text-sm', + medium: 'w-5 h-5 text-base', + large: 'w-6 h-6 text-base', +} + +export const Checkbox = forwardRef( + ({ label, error, description, fieldSize = 'medium', ...rest }, ref) => { + const inputSizeStyle = SIZE_STYLES[fieldSize] + + const inputClass = twMerge( + 'box-border rounded-md transition-all shadow-sm border border-gray-400 hover:border-gray-500 focus:ring-gray-500 focus:border-gray-500 focus:outline-none disabled:bg-gray-100 cursor-pointer focus:outline-0 hover:outline-0 outline-0 focus:ring-transparent', + inputSizeStyle + ) + + return ( + +
+ + +
+
+ ) + } +) + +Checkbox.displayName = 'Checkbox' + +export default Checkbox diff --git a/packages/ui/lib/components/Form/index.tsx b/packages/ui/lib/components/Form/index.tsx index a1c8d2b462e..db994f3e116 100644 --- a/packages/ui/lib/components/Form/index.tsx +++ b/packages/ui/lib/components/Form/index.tsx @@ -2,3 +2,4 @@ export { FieldLayout } from './FieldLayout' export { Input } from './Input' export { TextBox } from './TextBox' export { AddressInput } from './AddressInput' +export { Checkbox } from './Checkbox' diff --git a/packages/ui/lib/components/PriceFormatter/PriceFormatter.stories.tsx b/packages/ui/lib/components/PriceFormatter/PriceFormatter.stories.tsx new file mode 100644 index 00000000000..fa9fc317e96 --- /dev/null +++ b/packages/ui/lib/components/PriceFormatter/PriceFormatter.stories.tsx @@ -0,0 +1,74 @@ +import { Meta, StoryObj } from '@storybook/react' +import { PriceFormatter } from './PriceFormatter' + +const meta = { + component: PriceFormatter, + title: 'PriceFormatter', +} satisfies Meta + +export default meta +type Story = StoryObj + +export const DefaultPrice = { + args: { + price: '1.0', + }, +} satisfies Story + +export const ZeroPrice = { + args: { + price: '0.0', + }, +} satisfies Story + +export const SmallPrice1 = { + args: { + price: '0.000005', + }, +} satisfies Story + +export const SmallPrice2 = { + args: { + price: '1.000005', + precision: 3, + }, +} satisfies Story + +export const BigPrice1 = { + args: { + price: '100500', + }, +} satisfies Story + +export const BigPrice2 = { + args: { + price: '23476573', + precision: 3, + }, +} satisfies Story + +export const BigPricePrecision = { + args: { + price: '100500.1346', + }, +} satisfies Story + +export const BigPricePrecision2 = { + args: { + price: '23476573.00006', + precision: 3, + }, +} satisfies Story + +export const BigPricePrecision3 = { + args: { + price: '23476573.2534700006', + precision: 3, + }, +} satisfies Story + +export const BigPricePrecision4 = { + args: { + price: '23476573.200006', + }, +} satisfies Story diff --git a/packages/ui/lib/components/PriceFormatter/PriceFormatter.tsx b/packages/ui/lib/components/PriceFormatter/PriceFormatter.tsx new file mode 100644 index 00000000000..314382515fb --- /dev/null +++ b/packages/ui/lib/components/PriceFormatter/PriceFormatter.tsx @@ -0,0 +1,57 @@ +import React from 'react' + +export interface PriceFormatterProps { + price: string + precision?: number +} + +export function PriceFormatter({ price, precision = 4 }: PriceFormatterProps) { + if (!price) return '' + + const decimalIndex = price.indexOf('.') + + const removeTrailingZeroes = (number: string): string => { + for (let i = number.length - 1; i >= 0; i--) { + if (number.charAt(i) === '.') { + return number.substring(0, i) + } else if (number.charAt(i) !== '0') { + return number.substring(0, i + 1) + } + } + + return number + } + + // If not decimal - return + if (decimalIndex === -1 || decimalIndex === price.length - 1) { + return price + } + + const fractionalPart = price.substring(decimalIndex + 1) + + // Numbers of zeroes + let numZeroes = 0 + for (let i = 0; i < fractionalPart.length; i++) { + if (fractionalPart.charAt(i) === '0') { + numZeroes++ + } else { + break + } + } + + if (numZeroes > 3) { + return ( + <> + {`${price.substring(0, decimalIndex)}.0`} + {numZeroes - 1} + {removeTrailingZeroes( + price.substring(decimalIndex + 1 + numZeroes).substring(0, 4) + )} + + ) + } else { + return removeTrailingZeroes( + price.substring(0, decimalIndex + 1 + numZeroes + precision) + ) + } +} diff --git a/packages/ui/lib/components/PriceFormatter/formatPrice.ts b/packages/ui/lib/components/PriceFormatter/formatPrice.ts new file mode 100644 index 00000000000..f448f6e3029 --- /dev/null +++ b/packages/ui/lib/components/PriceFormatter/formatPrice.ts @@ -0,0 +1,59 @@ +import React from 'react' + +interface PriceFormatterProps { + price: string + precision?: number +} + +function PriceFormatter({ price, precision = 4 }: PriceFormatterProps) { + if (!price) return '' + + const decimalIndex = price.indexOf('.') + + const removeTrailingZeroes = (number: string): string => { + for (let i = number.length - 1; i >= 0; i--) { + if (number.charAt(i) === '.') { + return number.substring(0, i) + } else if (number.charAt(i) !== '0') { + return number.substring(0, i + 1) + } + } + + return number + } + + // If not decimal - return + if (decimalIndex === -1 || decimalIndex === price.length - 1) { + return price + } + + const fractionalPart = price.substring(decimalIndex + 1) + + // Numbers of zeroes + let numZeroes = 0 + for (let i = 0; i < fractionalPart.length; i++) { + if (fractionalPart.charAt(i) === '0') { + numZeroes++ + } else { + break + } + } + + if (numZeroes > 3) { + return ( + <> + {`${price.substring(0, decimalIndex)}.0`} + {numZeroes - 1} + {removeTrailingZeroes( + price.substring(decimalIndex + 1 + numZeroes).substring(0, 4) + )} + + ) + } else { + return removeTrailingZeroes( + price.substring(0, decimalIndex + 1 + numZeroes + precision) + ) + } +} + +export default PriceFormatter \ No newline at end of file diff --git a/packages/ui/lib/components/Tooltip/Tooltip.tsx b/packages/ui/lib/components/Tooltip/Tooltip.tsx index cd9236bb96f..93effb9943f 100644 --- a/packages/ui/lib/components/Tooltip/Tooltip.tsx +++ b/packages/ui/lib/components/Tooltip/Tooltip.tsx @@ -5,6 +5,7 @@ import { Portal, TooltipContentProps, Root, + Provider, } from '@radix-ui/react-tooltip' import { ReactNode } from 'react' @@ -29,20 +30,22 @@ export function Tooltip({ theme === 'clear' ? 'text-brand-dark bg-white' : 'text-white bg-brand-dark' const arrowColor = theme === 'clear' ? 'fill-white' : 'fill-brand-dark' return ( - - - {children} - - - - - {tip} - - - + + + + {children} + + + + + {tip} + + + + ) } diff --git a/packages/ui/lib/index.tsx b/packages/ui/lib/index.tsx index a57acbb9142..143c5568fc1 100644 --- a/packages/ui/lib/index.tsx +++ b/packages/ui/lib/index.tsx @@ -2,7 +2,13 @@ import './index.css' export { Button } from './components/Button/Button' export { Alert } from './components/Alert/Alert' export { Drawer } from './components/Drawer/Drawer' -export { Input, FieldLayout, TextBox, AddressInput } from './components/Form' +export { + Input, + FieldLayout, + TextBox, + AddressInput, + Checkbox, +} from './components/Form' export { IconButton } from './components/IconButton/IconButton' export { CodeBox } from './components/CodeBox/CodeBox' export { TabbedCodeBox } from './components/CodeBox/TabbedCodeBox' @@ -36,3 +42,4 @@ export { Images } from '~/components/Images/Images' export { GuidesHeader, GuidesFooter } from '~/configs/guides' export { ShowcaseHeader, ShowcaseFooter } from '~/configs/showcase' +export { PriceFormatter } from '~/components/PriceFormatter/PriceFormatter' diff --git a/packages/ui/package.json b/packages/ui/package.json index de094776727..d56a9b86c26 100644 --- a/packages/ui/package.json +++ b/packages/ui/package.json @@ -66,7 +66,6 @@ "@storybook/addon-docs": "7.6.3", "@storybook/addon-essentials": "7.6.3", "@storybook/addon-links": "7.6.3", - "@storybook/addon-postcss": "3.0.0-alpha.1", "@storybook/react": "7.6.3", "@storybook/react-vite": "7.6.3", "@types/react": "18.2.46", @@ -83,7 +82,7 @@ "tsx": "4.7.1", "typescript": "5.3.3", "url-loader": "4.1.1", - "vite": "5.0.12", + "vite": "5.0.13", "vite-plugin-node-polyfills": "0.19.0", "vite-plugin-svgr": "4.2.0", "vite-tsconfig-paths": "4.3.2" diff --git a/packages/unlock-js/openapi.yml b/packages/unlock-js/openapi.yml index eae20b0e8fa..1f49ab29798 100644 --- a/packages/unlock-js/openapi.yml +++ b/packages/unlock-js/openapi.yml @@ -450,6 +450,9 @@ components: type: array items: type: string + requiredGitcoinPassportScore: + type: number + nullable: true EventDetails: type: object @@ -3116,7 +3119,42 @@ paths: type: array items: type: string + /v2/hooks/gitcoin: + get: + operationId: getDataForRecipientsAndGitcoinPassport + description: Get the data for recipients and gitcoin passport. This is to be used in conjunction with the Gitcoin passport scorer. + parameters: + - in: query + name: network + required: true + description: The network the lock is on + schema: + type: number + - in: query + name: lockAddress + description: The address of the lock + schema: + type: string + - in: query + name: recipients + description: The list of recipients for the purchase + schema: + type: array + items: + type: string + responses: + 200: + description: the list of data inputs to use for the transaction + content: + application/json: + schema: + type: object + properties: + result: + type: array + items: + type: string /purchase/capture: post: operationId: capturePurchase diff --git a/packages/unlock-js/src/web3Service.ts b/packages/unlock-js/src/web3Service.ts index 53bd666510e..dd51aa15078 100644 --- a/packages/unlock-js/src/web3Service.ts +++ b/packages/unlock-js/src/web3Service.ts @@ -146,6 +146,7 @@ export default class Web3Service extends UnlockService { ) // Add the lock address lock.address = address + lock.network = network // Add the unlock address lock.unlockContractAddress = ethers.utils.getAddress( diff --git a/paywall-app/package.json b/paywall-app/package.json index 74af4a3a0fb..07742b7010b 100644 --- a/paywall-app/package.json +++ b/paywall-app/package.json @@ -17,7 +17,7 @@ "dependencies": { "@types/next": "9.0.0", "@unlock-protocol/paywall": "workspace:./packages/paywall", - "next": "14.0.4", + "next": "14.1.4", "vite-plugin-node-polyfills": "0.21.0" }, "license": "MIT", @@ -27,7 +27,7 @@ "eslint": "8.54.0", "prettier": "3.1.0", "typescript": "5.3.3", - "vite": "5.0.12" + "vite": "5.0.13" }, "browserslist": [ "defaults", diff --git a/smart-contracts/contracts/interfaces/IUniversalRouter.sol b/smart-contracts/contracts/interfaces/IUniversalRouter.sol new file mode 100644 index 00000000000..cb6c3e91bda --- /dev/null +++ b/smart-contracts/contracts/interfaces/IUniversalRouter.sol @@ -0,0 +1,37 @@ +// SPDX-License-Identifier: GPL-3.0-or-later +pragma solidity ^0.8.17; + +import {IERC721Receiver} from "@openzeppelin/contracts/token/ERC721/IERC721Receiver.sol"; +import {IERC1155Receiver} from "@openzeppelin/contracts/token/ERC1155/IERC1155Receiver.sol"; + +interface IUniversalRouter is IERC721Receiver, IERC1155Receiver { + /// @notice Thrown when a required command has failed + error ExecutionFailed(uint256 commandIndex, bytes message); + + /// @notice Thrown when attempting to send ETH directly to the contract + error ETHNotAccepted(); + + /// @notice Thrown when executing commands with an expired deadline + error TransactionDeadlinePassed(); + + /// @notice Thrown when attempting to execute commands and an incorrect number of inputs are provided + error LengthMismatch(); + + /// @notice Executes encoded commands along with provided inputs. + /// @param commands A set of concatenated commands, each 1 byte in length + /// @param inputs An array of byte strings containing abi encoded inputs for each command + function execute( + bytes calldata commands, + bytes[] calldata inputs + ) external payable; + + /// @notice Executes encoded commands along with provided inputs. Reverts if deadline has expired. + /// @param commands A set of concatenated commands, each 1 byte in length + /// @param inputs An array of byte strings containing abi encoded inputs for each command + /// @param deadline The deadline by which the transaction must be executed + function execute( + bytes calldata commands, + bytes[] calldata inputs, + uint256 deadline + ) external payable; +} diff --git a/smart-contracts/contracts/utils/UnlockSwapBurner.sol b/smart-contracts/contracts/utils/UnlockSwapBurner.sol index 8d59d219c67..b4d0f9e16bd 100644 --- a/smart-contracts/contracts/utils/UnlockSwapBurner.sol +++ b/smart-contracts/contracts/utils/UnlockSwapBurner.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "@uniswap/v3-periphery/contracts/interfaces/ISwapRouter.sol"; +import "../interfaces/IUniversalRouter.sol"; import "@uniswap/v3-periphery/contracts/libraries/TransferHelper.sol"; import "../interfaces/IMintableERC20.sol"; import "../interfaces/IPermit2.sol"; @@ -28,17 +28,24 @@ contract UnlockSwapBurner { // required by Uniswap Universal Router address public permit2; - address public uniswapRouter; + address public uniswapUniversalRouter; // dead address to burn address public constant burnAddress = 0x000000000000000000000000000000000000dEaD; + // specified in https://docs.uniswap.org/contracts/universal-router/technical-reference#v3_swap_exact_in + uint256 constant V3_SWAP_EXACT_IN = 0x00; + // events event SwapBurn(address tokenAddress, uint amountSpent, uint amountBurnt); // errors - error UDTSwapFailed(address uniswapRouter, address tokenIn, uint amount); + error UDTSwapFailed( + address uniswapUniversalRouter, + address tokenIn, + uint amount + ); error UnauthorizedSwap(); /** @@ -49,11 +56,11 @@ contract UnlockSwapBurner { constructor( address _unlockAddress, address _permit2Address, - address _uniswapRouter + address _uniswapUniversalRouter ) { unlockAddress = _unlockAddress; permit2 = _permit2Address; - uniswapRouter = _uniswapRouter; + uniswapUniversalRouter = _uniswapUniversalRouter; } /** @@ -80,6 +87,7 @@ contract UnlockSwapBurner { // get total balance of token to swap uint tokenAmount = getBalance(tokenAddress); + uint udtBefore = getBalance(udtAddress); if (tokenAddress == udtAddress) { revert UnauthorizedSwap(); @@ -95,7 +103,11 @@ contract UnlockSwapBurner { // approve ERC20 spending if (tokenAddress != address(0)) { // Approve the router to spend src ERC20 - TransferHelper.safeApprove(tokenAddress, uniswapRouter, tokenAmount); + TransferHelper.safeApprove( + tokenAddress, + uniswapUniversalRouter, + tokenAmount + ); // approve PERMIT2 to manipulate the token IERC20(tokenAddress).approve(permit2, tokenAmount); @@ -104,7 +116,7 @@ contract UnlockSwapBurner { // issue PERMIT2 Allowance IPermit2(permit2).approve( tokenAddress, - uniswapRouter, + uniswapUniversalRouter, tokenAmount.toUint160(), uint48(block.timestamp + 60) // expires after 1min ); @@ -115,27 +127,36 @@ contract UnlockSwapBurner { udtAddress ); - // executes the swap token > WETH > UDT - ISwapRouter.ExactInputParams memory params = ISwapRouter.ExactInputParams({ - path: tokenAddress == wrappedAddress + // encode parameters for the swap om UniversalRouter + bytes memory commands = abi.encodePacked(bytes1(uint8(V3_SWAP_EXACT_IN))); + bytes[] memory inputs = new bytes[](1); + inputs[0] = abi.encode( + address(this), // recipient + tokenAmount, // amountIn + 0, // amountOutMinimum + tokenAddress == wrappedAddress ? defaultPath - : abi.encodePacked(tokenAddress, poolFee, defaultPath), - recipient: address(this), - deadline: block.timestamp + 60, // expires after 1min - amountIn: tokenAmount, - amountOutMinimum: 0 - }); + : abi.encodePacked(tokenAddress, poolFee, defaultPath), // path + true // funds are not coming from PERMIT2 + ); // Executes the swap. - uint amountUDTOut = ISwapRouter(uniswapRouter).exactInput(params); + IUniversalRouter(uniswapUniversalRouter).execute( + commands, + inputs, + block.timestamp + 60 // expires after 1min + ); + + // calculate how much UDT has been received + uint amountUDTOut = getBalance(udtAddress) - udtBefore; if (amountUDTOut == 0) { - revert UDTSwapFailed(uniswapRouter, tokenAddress, tokenAmount); + revert UDTSwapFailed(uniswapUniversalRouter, tokenAddress, tokenAmount); } - // burn the UDT + // burn the newly received UDT bool success = IERC20(udtAddress).transfer(burnAddress, amountUDTOut); if (success == false) { - revert UDTSwapFailed(uniswapRouter, tokenAddress, tokenAmount); + revert UDTSwapFailed(uniswapUniversalRouter, tokenAddress, tokenAmount); } else { emit SwapBurn(tokenAddress, tokenAmount, amountUDTOut); } diff --git a/smart-contracts/scripts/hooks/GitcoinHook.js b/smart-contracts/scripts/hooks/GitcoinHook.js index bb6371ce73d..cb710d40dc4 100644 --- a/smart-contracts/scripts/hooks/GitcoinHook.js +++ b/smart-contracts/scripts/hooks/GitcoinHook.js @@ -1,7 +1,11 @@ -const { ethers } = require('hardhat') +const { networks } = require('@unlock-protocol/networks') +const { ethers, run } = require('hardhat') async function main() { const [user] = await ethers.getSigners() + const { chainId } = await user.provider.getNetwork() + + const unlockNetwork = networks[chainId] console.log('Deploying from :', user.address) @@ -11,11 +15,27 @@ async function main() { await hook.deployed() - console.log( - 'Gitcoin hook deployed to:', - hook.address, - '. You can add signers now and transfer ownership of this hook to the multisig!' - ) + const signers = [ + '0x22c095c69c38b66afAad4eFd4280D94Ec9D12f4C', // prod purchaser + '0x903073735Bb6FDB802bd3CDD3b3a2b00C36Bc2A9', // staging purchaser + '0xd851fe9ba8EfA66e65d7865690bD2B9522C6E99f', // OpenZeppelin purchaser + ] + + console.log('Gitcoin hook deployed to:', hook.address) + for (let i = 0; i < signers.length; i++) { + console.log('Adding signer:', signers[i]) + await hook.addSigner(signers[i]) + } + if (unlockNetwork?.multisig) { + console.log( + 'Transfering ownership to multisig signer:', + unlockNetwork.multisig + ) + await hook.transferOwnership(unlockNetwork.multisig) + } + await run('verify:verify', { + address: hook.address, + }) } main() diff --git a/smart-contracts/scripts/hooks/GuildHook.js b/smart-contracts/scripts/hooks/GuildHook.js index 34c0357373a..0f217e19e68 100644 --- a/smart-contracts/scripts/hooks/GuildHook.js +++ b/smart-contracts/scripts/hooks/GuildHook.js @@ -13,11 +13,10 @@ async function main() { console.log('Deploying from', user.address) - // We get the contract to deploy const signers = [ - '0x22c095c69c38b66afAad4eFd4280D94Ec9D12f4C', - '0x903073735Bb6FDB802bd3CDD3b3a2b00C36Bc2A9', - '0xd851fe9ba8EfA66e65d7865690bD2B9522C6E99f', + '0x22c095c69c38b66afAad4eFd4280D94Ec9D12f4C', // prod purchaser + '0x903073735Bb6FDB802bd3CDD3b3a2b00C36Bc2A9', // staging purchaser + '0xd851fe9ba8EfA66e65d7865690bD2B9522C6E99f', // OpenZeppelin purchaser ] const PurchaseHook = await ethers.getContractFactory('GuildHook') diff --git a/smart-contracts/test/UnlockSwapBurner/swapAndBurn.mainnet.js b/smart-contracts/test/UnlockSwapBurner/swapAndBurn.mainnet.js index 1d33f117460..9b72eee740c 100644 --- a/smart-contracts/test/UnlockSwapBurner/swapAndBurn.mainnet.js +++ b/smart-contracts/test/UnlockSwapBurner/swapAndBurn.mainnet.js @@ -17,16 +17,15 @@ const { compareBigNumbers } = require('../helpers') let scenarios -const routerAddress = '0xE592427A0AEce92De3Edee1F18E0157C05861564' -// const routerAddress = '0x68b3465833fb72A70ecDF485E0e4C7bD8665Fc45' // swaRouter02 - describe(`swapAndBurn`, function () { - let swapBurner, + let chainId, + swapBurner, unlockAddress, tokenAddress, udtAddress, wrappedAddress, unlock, + universalRouterAddress, burnAddress before(async function () { @@ -38,17 +37,17 @@ describe(`swapAndBurn`, function () { // mainnet fork: need to fund hardhat default signer const [signer] = await ethers.getSigners() await addSomeETH(signer.address) + // get mainnet values + ;({ + id: chainId, + unlockAddress, + uniswapV3: { universalRouterAddress }, + } = await getNetwork()) // get uniswap-formatted tokens - const { chainId } = await ethers.provider.getNetwork() const { native, usdc, dai, weth } = await getUniswapTokens(chainId) scenarios = [native, usdc, dai, weth] - // get mainnet values - ;({ - // uniswapV3: { universalRouterAddress: routerAddress }, - unlockAddress, - } = await getNetwork()) unlock = await getUnlock(unlockAddress) udtAddress = await unlock.udt() wrappedAddress = await unlock.weth() @@ -60,7 +59,7 @@ describe(`swapAndBurn`, function () { swapBurner = await UnlockSwapBurner.deploy( unlockAddress, PERMIT2_ADDRESS, - routerAddress + universalRouterAddress ) burnAddress = await swapBurner.burnAddress() @@ -71,7 +70,9 @@ describe(`swapAndBurn`, function () { expect(await swapBurner.unlockAddress()).to.equal(unlockAddress) }) it('uniswap routers are set properly', async () => { - expect(await swapBurner.uniswapRouter()).to.equal(routerAddress) + expect(await swapBurner.uniswapUniversalRouter()).to.equal( + universalRouterAddress + ) }) it('permit2 is set properly', async () => { expect(await swapBurner.permit2()).to.equal(PERMIT2_ADDRESS) diff --git a/unlock-app/.gitignore b/unlock-app/.gitignore index 67c955d7fa8..6c982c6c6d9 100644 --- a/unlock-app/.gitignore +++ b/unlock-app/.gitignore @@ -32,3 +32,5 @@ scripts/index.html # Sentry .sentryclirc .vercel + +certificates \ No newline at end of file diff --git a/unlock-app/app/frames/event/Components/Description.tsx b/unlock-app/app/frames/event/Components/Description.tsx index 0bf52c9b8d1..d794ddcdd9a 100644 --- a/unlock-app/app/frames/event/Components/Description.tsx +++ b/unlock-app/app/frames/event/Components/Description.tsx @@ -2,6 +2,8 @@ import React from 'react' import Container from './Container' import { FrameButton, FrameImage } from 'frames.js/next/server' import { config } from '../../../../src/config/app' +import removeMd from 'remove-markdown' +import { truncateString } from '~/utils/truncateString' export const Description = ({ event, @@ -15,7 +17,14 @@ export const Description = ({ return ( -

{event.data.description}

+
+

+ {truncateString( + removeMd(event.data.description, { useImgAltText: false }), + 650 + )} +

+
{ const { account } = useAuth() + const { query } = useRouter() + const [owner, setOwner] = React.useState(null) + + useEffect(() => { + if (query.owner) { + setOwner(query.owner as string) + } else if (account) { + setOwner(account) + } + }, [account, query]) const networkConfig = networks[1] return ( -

Member Keychain

- {networkConfig && account && ( +
+ {owner && } + {networkConfig && owner && (
{networkConfig.blockScan && networkConfig.blockScan.url && ( { label="View Opensea Profile" > { )}
} - description="A Key is a membership NFT created on Unlock Protocol" > {pageTitle('Member Keychain')} - + + {owner && } ) } diff --git a/unlock-app/src/components/content/event/CastItButton.tsx b/unlock-app/src/components/content/event/CastItButton.tsx index 0ca3894c911..3737714d8a1 100644 --- a/unlock-app/src/components/content/event/CastItButton.tsx +++ b/unlock-app/src/components/content/event/CastItButton.tsx @@ -41,8 +41,8 @@ export const CastItButton = ({ event, eventUrl }: CastItButtonProps) => { className="w-12 h-12 flex justify-center items-center p-2" > +
{isOrganizer && ( -
- - - {/* -
- -
-
- {Object.keys(checkoutConfig.config.locks).map( - (lockAddress: string) => { - const network = - checkoutConfig.config.locks[lockAddress].network - let label = 'Manage attendees' - if (Object.keys(checkoutConfig.config.locks).length > 1) { - label = `Manage attendees for ${minifyAddress( - lockAddress - )}` - } - return ( - - ) - } - )} -
-
*/} - { }, image: '', requiresApproval: false, + emailSender: '', }, }, }) @@ -459,6 +460,38 @@ export const Form = ({ onSubmit }: FormProps) => {
+ +
+ + +
+
+

diff --git a/unlock-app/src/components/content/event/Hosts.tsx b/unlock-app/src/components/content/event/Hosts.tsx new file mode 100644 index 00000000000..ff1eedf9453 --- /dev/null +++ b/unlock-app/src/components/content/event/Hosts.tsx @@ -0,0 +1,77 @@ +import { Placeholder } from '@unlock-protocol/ui' +import Image from 'next/image' +import Link from 'next/link' +import { useSocials } from '~/hooks/useSocials' +import { FaUser } from 'react-icons/fa' + +interface HostsProps { + organizers?: string[] +} + +export const Hosts = ({ organizers }: HostsProps) => { + const { socials, loading, error } = useSocials(organizers || []) + + if (error) { + console.error(error) + return null + } + if (loading || !socials) { + return ( + + + + ) + } + + if (Object.values(socials).length > 0) { + return ( +

+ Hosted by: +
    + {Object.values(socials).map((social) => { + if (social.profileUrl) { + return ( +
  • + + {social.profileImage && ( + {social.profileName} + )} + {!social.profileImage && } + {social.profileDisplayName} + +
  • + ) + } + return ( +
  • + {social.profileImage && ( + {social.profileName} + )} + {social.profileDisplayName} +
  • + ) + })} +
+
+ ) + } + return null +} + +export default Hosts diff --git a/unlock-app/src/components/content/event/Settings/Components/CustomEmail.tsx b/unlock-app/src/components/content/event/Settings/Components/CustomEmail.tsx new file mode 100644 index 00000000000..54af7b42ab7 --- /dev/null +++ b/unlock-app/src/components/content/event/Settings/Components/CustomEmail.tsx @@ -0,0 +1,229 @@ +import { + Button, + Input, + Modal, + Placeholder, + TextBox, + Checkbox, +} from '@unlock-protocol/ui' +import { Event, PaywallConfigType } from '@unlock-protocol/core' +import { useMultipleLockData } from '~/hooks/useLockData' +import { useState } from 'react' +import { useCustomEmailSend } from '~/hooks/useCustomEmail' +import { useForm } from 'react-hook-form' +import { ToastHelper } from '~/components/helpers/toast.helper' + +interface EmailsProps { + event: Event + checkoutConfig: { + id?: string + config: PaywallConfigType + } +} + +interface SendCustomEmailData { + subject: string + content: string + [lockAddress: string]: boolean | string +} + +interface ConfirmModalProps { + isOpen: boolean + setIsOpen: (isOpen: boolean) => void + onSuccess: () => void + formData: SendCustomEmailData + checkoutConfig: { + id?: string + config: PaywallConfigType + } +} + +export const ConfirmModal = ({ + isOpen, + setIsOpen, + onSuccess, + formData, + checkoutConfig, +}: ConfirmModalProps) => { + const { mutateAsync: sendCustomEmail, isLoading: isSendingCustomEmail } = + useCustomEmailSend() + + const { handleSubmit } = useForm() + + const onSubmit = async () => { + const { subject, content, ...locks } = formData + + await ToastHelper.promise( + Promise.all( + Object.keys(locks).map(async (address) => { + if (locks[address]) { + await sendCustomEmail({ + network: + checkoutConfig.config.locks[address].network || + checkoutConfig.config.network!, + lockAddress: address, + content, + subject, + }) + } + }) + ), + { + success: 'Emails sent!', + error: 'There was an error while sending the emails.', + loading: 'Sending the emails... please stand-by!', + } + ) + onSuccess() + setIsOpen(false) + return false + } + + return ( + +
+
+
+

Confirm Email

+

+ Are you sure you want to send this email to all the confirmed + attendees? +

+
+
+ + +
+
+
+
+ ) +} + +export const SendCustomEmail = ({ checkoutConfig }: EmailsProps) => { + const [confirm, setIsConfirm] = useState(false) + const [formData, setFormData] = useState() + + const { + register, + setError, + clearErrors, + handleSubmit, + reset, + formState: { errors, isValid }, + } = useForm({ + defaultValues: { + subject: '', + content: '', + ...Object.keys(checkoutConfig.config.locks).reduce( + (acc, address) => ({ ...acc, [address]: true }), + {} + ), + }, + }) + + const loadingLocks = useMultipleLockData(checkoutConfig.config.locks) + + const onSubmit = (data: SendCustomEmailData) => { + setFormData(data) + setIsConfirm(true) + return false + } + + return ( +
+ {formData && ( + reset()} + checkoutConfig={checkoutConfig} + formData={formData} + isOpen={confirm} + setIsOpen={setIsConfirm} + /> + )} + +
+ {loadingLocks.map(({ lock, isLockLoading }, index) => { + if (isLockLoading || !lock) { + return ( + + + + ) + } else { + return ( +
+ { + if (!Object.values(locksToSend).some((value) => value)) { + setError('root', { + type: 'custom', + message: 'At least one lock must be selected', + }) + } else { + clearErrors('root') + } + return true + }, + })} + label={lock.name} + /> +
+ ) + } + })} + {errors.root && ( +

{errors.root.message}

+ )} + + + + The content of the email.{' '} +
+ Markdown is supported. + + + } + placeholder="New information on the event..." + {...register('content', { + required: 'This field is required', + })} + /> +
+ +
+
+
+ ) +} + +export default SendCustomEmail diff --git a/unlock-app/src/components/content/event/Settings/Components/SenderSettings.tsx b/unlock-app/src/components/content/event/Settings/Components/SenderSettings.tsx new file mode 100644 index 00000000000..23a41eea1de --- /dev/null +++ b/unlock-app/src/components/content/event/Settings/Components/SenderSettings.tsx @@ -0,0 +1,84 @@ +import { storage } from '~/config/storage' +import { ToastHelper } from '~/components/helpers/toast.helper' +import { Button, Input } from '@unlock-protocol/ui' +import { formDataToMetadata } from '@unlock-protocol/core' + +import { useForm } from 'react-hook-form' +import { EmailsProps } from '../Emails' + +export const SenderSettings = ({ checkoutConfig, event }: EmailsProps) => { + const { + register, + handleSubmit, + formState: { errors, isSubmitting }, + } = useForm({ + mode: 'onSubmit', + reValidateMode: 'onSubmit', + defaultValues: { + replyTo: event.replyTo, + emailSender: event.emailSender, + }, + }) + const save = async (values: { replyTo: string; emailSender: string }) => { + await ToastHelper.promise( + storage.saveEventData({ + data: { + ...formDataToMetadata({ + ...event, + }), + ...values, + }, + // @ts-expect-error + checkoutConfig, + }), + { + success: 'Settings saved!', + error: + 'We could not save. Please try again and report if the issue persists.', + loading: `Updating your event's properties.`, + } + ) + } + + return ( +
+
+ + +
+
+ +
+
+ ) +} diff --git a/unlock-app/src/components/content/event/Settings/Emails.tsx b/unlock-app/src/components/content/event/Settings/Emails.tsx new file mode 100644 index 00000000000..a0009254811 --- /dev/null +++ b/unlock-app/src/components/content/event/Settings/Emails.tsx @@ -0,0 +1,41 @@ +import { Event, PaywallConfigType } from '@unlock-protocol/core' + +import { SettingCard } from '~/components/interface/locks/Settings/elements/SettingCard' +import SendCustomEmail from './Components/CustomEmail' +import { SenderSettings } from './Components/SenderSettings' + +export interface EmailsProps { + event: Event + checkoutConfig: { + id?: string + config: PaywallConfigType + } +} + +export const Emails = ({ event, checkoutConfig }: EmailsProps) => { + return ( +
+ + + + + {/* + Here, we show an input form where a lock manager can enter email + addresses. We should keep track of invites sent! + */} + + + + +
+ ) +} diff --git a/unlock-app/src/components/content/event/Settings/EventSettings.tsx b/unlock-app/src/components/content/event/Settings/EventSettings.tsx index e2dcb2980f3..a03aecbc813 100644 --- a/unlock-app/src/components/content/event/Settings/EventSettings.tsx +++ b/unlock-app/src/components/content/event/Settings/EventSettings.tsx @@ -9,6 +9,7 @@ import { SettingTab } from '~/pages/locks/settings' import { PaywallConfigType, Event } from '@unlock-protocol/core' import { General } from './General' import { Referrals } from './Referrals' +import { Emails } from './Emails' import Link from 'next/link' interface EventSettingsProps { @@ -43,6 +44,12 @@ export const EventSettings = ({ description: `Create referral links to share with your community and reward them.`, children: , }, + { + id: 'emails', + label: 'Emails', + description: `Configure and send emails to the attendees of your event.`, + children: , + }, // { // id: 'checkout', // label: 'Checkout', diff --git a/unlock-app/src/components/interface/Receipts/elements/ReceiptBox.tsx b/unlock-app/src/components/interface/Receipts/elements/ReceiptBox.tsx index b352e028f27..64e243f9deb 100644 --- a/unlock-app/src/components/interface/Receipts/elements/ReceiptBox.tsx +++ b/unlock-app/src/components/interface/Receipts/elements/ReceiptBox.tsx @@ -1,4 +1,10 @@ -import { Button, Disclosure, Placeholder, Detail } from '@unlock-protocol/ui' +import { + Button, + Disclosure, + Placeholder, + Detail, + PriceFormatter, +} from '@unlock-protocol/ui' import ReactToPrint from 'react-to-print' import { useRef, useState } from 'react' import { PoweredByUnlock } from '../../checkout/PoweredByUnlock' @@ -175,7 +181,11 @@ export const ReceiptBox = ({ lockAddress, hash, network }: ReceiptBoxProps) => { )} - {(multiplier * parseFloat(receiptPrice?.total)).toFixed(2)}{' '} + {' '} {symbol}
diff --git a/unlock-app/src/components/interface/checkout/ViewContract.tsx b/unlock-app/src/components/interface/checkout/ViewContract.tsx deleted file mode 100644 index 8bcc677dea8..00000000000 --- a/unlock-app/src/components/interface/checkout/ViewContract.tsx +++ /dev/null @@ -1,26 +0,0 @@ -import { RiExternalLinkLine as ExternalLinkIcon } from 'react-icons/ri' -import { useConfig } from '~/utils/withConfig' -import { Icon } from '@unlock-protocol/ui' - -interface ViewContractProps { - lockAddress: string - network: number -} - -export const ViewContract = ({ lockAddress, network }: ViewContractProps) => { - const config = useConfig() - const networkConfig = config.networks[network] - return ( - - View contract ({networkConfig.name}){' '} - - - - - ) -} diff --git a/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmCard.tsx b/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmCard.tsx index 5c91b8b07c0..f2c81e15c01 100644 --- a/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmCard.tsx +++ b/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmCard.tsx @@ -11,7 +11,6 @@ import { Pricing } from '../../Lock' import { getReferrer, lockTickerSymbol } from '~/utils/checkoutLockUtils' import { Lock } from '~/unlockTypes' import { RiErrorWarningFill as ErrorIcon } from 'react-icons/ri' -import { ViewContract } from '../../ViewContract' import { usePurchase } from '~/hooks/usePurchase' import { useUpdateUsersMetadata } from '~/hooks/useUserMetadata' import { usePricing } from '~/hooks/usePricing' @@ -294,10 +293,7 @@ export function ConfirmCard({
-
-

{lock!.name}

- -
+

{lock!.name}

{isError && ( // TODO: use actual error from simulation diff --git a/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmClaim.tsx b/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmClaim.tsx index 61e114d9872..d228fd9c934 100644 --- a/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmClaim.tsx +++ b/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmClaim.tsx @@ -9,7 +9,6 @@ import { Pricing } from '../../Lock' import { lockTickerSymbol } from '~/utils/checkoutLockUtils' import { Lock } from '~/unlockTypes' import { RiErrorWarningFill as ErrorIcon } from 'react-icons/ri' -import { ViewContract } from '../../ViewContract' import { useClaim } from '~/hooks/useClaim' import { useUpdateUsersMetadata } from '~/hooks/useUserMetadata' import { usePricing } from '~/hooks/usePricing' @@ -108,10 +107,7 @@ export function ConfirmClaim({
-
-

{lock!.name}

- -
+

{lock!.name}

{isPricingDataError && ( // TODO: use actual error from simulation
diff --git a/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmCrossChainPurchase.tsx b/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmCrossChainPurchase.tsx index b4007330c56..0e60f84d882 100644 --- a/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmCrossChainPurchase.tsx +++ b/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmCrossChainPurchase.tsx @@ -12,7 +12,6 @@ import { lockTickerSymbol } from '~/utils/checkoutLockUtils' import { Lock } from '~/unlockTypes' import ReCaptcha from 'react-google-recaptcha' import { RiErrorWarningFill as ErrorIcon } from 'react-icons/ri' -import { ViewContract } from '../../ViewContract' import { useUpdateUsersMetadata } from '~/hooks/useUserMetadata' import { usePricing } from '~/hooks/usePricing' import { usePurchaseData } from '~/hooks/usePurchaseData' @@ -125,10 +124,7 @@ export function ConfirmCrossChainPurchase({
-
-

{lock!.name}

- -
+

{lock!.name}

{isPricingDataError && ( // TODO: use actual error from simulation
diff --git a/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmCrossmint.tsx b/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmCrossmint.tsx index 830be97e3ed..ce88c1e87fb 100644 --- a/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmCrossmint.tsx +++ b/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmCrossmint.tsx @@ -11,7 +11,6 @@ import { Pricing } from '../../Lock' import { getReferrer, lockTickerSymbol } from '~/utils/checkoutLockUtils' import { Lock } from '~/unlockTypes' import { RiErrorWarningFill as ErrorIcon } from 'react-icons/ri' -import { ViewContract } from '../../ViewContract' import { usePricing } from '~/hooks/usePricing' import { usePurchaseData } from '~/hooks/usePurchaseData' import { useAuth } from '~/contexts/AuthenticationContext' @@ -200,13 +199,7 @@ export function ConfirmCrossmint({ {!isConfirming && ( <>
-
-

{lock!.name}

- -
+

{lock!.name}

{isPricingDataError && ( // TODO: use actual error from simulation diff --git a/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmCrypto.tsx b/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmCrypto.tsx index 6056c6af4d8..3922a1343b6 100644 --- a/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmCrypto.tsx +++ b/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmCrypto.tsx @@ -15,7 +15,6 @@ import { getReferrer, lockTickerSymbol } from '~/utils/checkoutLockUtils' import { Lock } from '~/unlockTypes' import ReCaptcha from 'react-google-recaptcha' import { RiErrorWarningFill as ErrorIcon } from 'react-icons/ri' -import { ViewContract } from '../../ViewContract' import { useUpdateUsersMetadata } from '~/hooks/useUserMetadata' import { usePricing } from '~/hooks/usePricing' import { usePurchaseData } from '~/hooks/usePurchaseData' @@ -248,10 +247,7 @@ export function ConfirmCrypto({ />
-
-

{lock!.name}

- -
+

{lock!.name}

{isPricingDataError && ( // TODO: use actual error from simulation
diff --git a/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmSwapAndPurchase.tsx b/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmSwapAndPurchase.tsx index 8633b26ed65..55077e8a496 100644 --- a/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmSwapAndPurchase.tsx +++ b/unlock-app/src/components/interface/checkout/main/Confirm/ConfirmSwapAndPurchase.tsx @@ -13,7 +13,6 @@ import { getReferrer, lockTickerSymbol } from '~/utils/checkoutLockUtils' import { Lock } from '~/unlockTypes' import ReCaptcha from 'react-google-recaptcha' import { RiErrorWarningFill as ErrorIcon } from 'react-icons/ri' -import { ViewContract } from '../../ViewContract' import { useUpdateUsersMetadata } from '~/hooks/useUserMetadata' import { usePricing } from '~/hooks/usePricing' import { usePurchaseData } from '~/hooks/usePurchaseData' @@ -218,10 +217,7 @@ export function ConfirmSwapAndPurchase({
-
-

{lock!.name}

- -
+

{lock!.name}

{isPricingDataError && ( // TODO: use actual error from simulation
diff --git a/unlock-app/src/components/interface/checkout/main/Gitcoin.tsx b/unlock-app/src/components/interface/checkout/main/Gitcoin.tsx new file mode 100644 index 00000000000..45e03820eb4 --- /dev/null +++ b/unlock-app/src/components/interface/checkout/main/Gitcoin.tsx @@ -0,0 +1,314 @@ +import { Fragment } from 'react' +import { useActor } from '@xstate/react' +import { Button, minifyAddress } from '@unlock-protocol/ui' +import { useAuth } from '~/contexts/AuthenticationContext' +import { CheckoutService } from './checkoutMachine' +import { + FaCheckCircle as CheckIcon, + FaExclamationCircle as FailIcon, +} from 'react-icons/fa' +import { Connected } from '../Connected' +import { PoweredByUnlock } from '../PoweredByUnlock' +import { Stepper } from '../Stepper' +import LoadingIcon from '../../Loading' +import { useDataForGitcoinPassport } from '~/hooks/useDataForGitcoinPassport' + +interface Props { + injectedProvider: unknown + checkoutService: CheckoutService +} + +interface CustomErrorType { + isMisconfigurationError?: boolean + isInvalidScoreError?: boolean + isTimeoutError?: boolean +} + +export function Gitcoin({ injectedProvider, checkoutService }: Props) { + const [state, send] = useActor(checkoutService) + const { account } = useAuth() + const { recipients, lock } = state.context + + const users = recipients.length > 0 ? recipients : [account!] + + const { + data, + isLoading: isLoadingGitcoinPassportData, + isFetching: isFetchingGitcoinPassportData, + refetch, + isError, + isSuccess, + error, + } = useDataForGitcoinPassport({ + lockAddress: lock!.address, + network: lock!.network, + recipients: users, + }) + + // evaluate if all recipients, or one recipient have valid Gitcoin Passports + const allValidPassports = !data || data.every((d) => d !== '') + // evaluate if at least one recipient has an invalid Gitcoin Passport + const disabled = !allValidPassports + + // type assertion + const typedError = error as CustomErrorType + + const onContinue = async () => { + if (data) { + send({ + type: 'SUBMIT_DATA', + data, + }) + } + } + + return ( + + +
+
+ {/* Verification Info */} + {!isFetchingGitcoinPassportData && !isError && !isSuccess && ( + <> +

+ Verify Your Gitcoin Passport +

+

+ Recipients need to have a valid Gitcoin Passport before you can + proceed. Verify their passports to continue with the checkout + process. +

+ + )} + + {/* Verification loading, error, and success states */} + {/* verification in progress state */} + {isFetchingGitcoinPassportData && ( +
+ +

Verifying Gitcoin passports...

+ +
+ {users.map((user, index) => { + if (isLoadingGitcoinPassportData) { + return ( +
  • + + {minifyAddress(user)} +
  • + ) + } + if (data && data[index]) { + return ( +
  • + ✅ {minifyAddress(user)} +
  • + ) + } + return ( +
  • + ❌ {minifyAddress(user)} +
  • + ) + })} +
    +
    + )} + + {/* Invalid Gitcoin Passport states */} + {/* Render when at least one of multiple recipients has an invalid Gitcoin passport */} + {disabled && users.length > 1 && ( +
    + +

    + Some of the selected recipients possess an invalid Gitcoin + passport{' '} +

    +
    + {users.map((user, index) => { + if (data && data[index]) { + return ( +
  • + ✅ {minifyAddress(user)} +
  • + ) + } + return ( + <> +
  • + ❌ {minifyAddress(user)} +
  • + + ) + })} +
    +
    + )} + + {/* render when it's a single recipient, and they possess an invalid Gitcoin passport */} + {disabled && users.length === 1 && ( +
    + +

    + The recipient you have selected possesses an invalid Gitcoin + passport +

    +
    + )} + {/* Invalid Gitcoin Passport states */} + + {/* Verification success states */} + {/* when it's one recipient */} + {isSuccess && allValidPassports && users.length === 1 && ( +
    + +

    + Gitcoin Passport successfully verified! +

    +
    + )} + + {/* for multiple recipients */} + {isSuccess && allValidPassports && users.length > 1 && ( +
    + +

    + All Gitcoin Passports successfully verified! +

    + +
    + {users.map((user, index) => { + if (data && data[index]) { + return ( +
  • + ✅ {minifyAddress(user)} +
  • + ) + } + })} +
    +
    + )} + {/* Verification success states */} + + {/* Verification error states */} + {isError && ( +
    + + + {/* Dynamically display error messages */} +
    + {typedError.isMisconfigurationError && + 'Verification failed due to a misconfiguration in your lock.'} + {typedError.isInvalidScoreError && + 'The required Gitcoin Passport score is not defined or invalid.'} + {typedError.isTimeoutError && + 'Timeout: Unable to verify scores within expected time frame.'} + {!typedError.isMisconfigurationError && + !typedError.isInvalidScoreError && + !typedError.isTimeoutError && + 'Verification failed. An unexpected error occurred.'} +
    +
    + )} + {/* Verification error states */} + {/* Verification loading, error, and success states */} +
    +
    + +
    + + {/* Show the "Verify" button only initially, before any attempt at verification has been made */} + {!isFetchingGitcoinPassportData && !isError && !isSuccess && ( + + )} + + {/* Verification in progress button */} + {isFetchingGitcoinPassportData && ( + + )} + + {/* Button to continue to next step upon successful verification */} + {isSuccess && !isFetchingGitcoinPassportData && allValidPassports && ( + + )} + + {/* Verification failed disabled button */} + {disabled && ( + + )} + + {/* Retry verification button */} + {isError && ( + + )} + + +
    +
    + ) +} diff --git a/unlock-app/src/components/interface/checkout/main/Quantity.tsx b/unlock-app/src/components/interface/checkout/main/Quantity.tsx index 57463c8df70..fd0bf37d864 100644 --- a/unlock-app/src/components/interface/checkout/main/Quantity.tsx +++ b/unlock-app/src/components/interface/checkout/main/Quantity.tsx @@ -13,7 +13,6 @@ import { PoweredByUnlock } from '../PoweredByUnlock' import { Stepper } from '../Stepper' import { LabeledItem } from '../LabeledItem' import { Pricing } from '../Lock' -import { ViewContract } from '../ViewContract' import { useCreditCardEnabled } from '~/hooks/useCreditCardEnabled' import { useGetLockProps } from '~/hooks/useGetLockProps' @@ -91,10 +90,6 @@ export function Quantity({ injectedProvider, checkoutService }: Props) { } />
    -
    { > {lock.name} -
    { fiatPricing: FiatPricing @@ -221,6 +227,7 @@ export const checkoutMachine = createMachine( PASSWORD: 'PASSWORD', PROMO: 'PROMO', GUILD: 'GUILD', + GITCOIN: 'GITCOIN', CARD: 'CARD', UPDATE_PAYWALL_CONFIG: { target: 'SELECT', @@ -293,6 +300,13 @@ export const checkoutMachine = createMachine( return event.hook === 'captcha' }, }, + { + actions: ['selectLock'], + target: 'GITCOIN', + cond: (_, event) => { + return event.hook === 'gitcoin' + }, + }, { actions: ['selectLock'], target: 'PAYMENT', @@ -339,6 +353,11 @@ export const checkoutMachine = createMachine( actions: ['selectRecipients'], cond: 'requireGuild', }, + { + target: 'GITCOIN', + actions: ['selectRecipients'], + cond: 'requireGitcoin', + }, { actions: ['selectRecipients'], target: 'PAYMENT', @@ -381,6 +400,11 @@ export const checkoutMachine = createMachine( cond: 'requireCaptcha', target: 'CAPTCHA', }, + { + actions: ['signMessage'], + cond: 'requireGitcoin', + target: 'GITCOIN', + }, { actions: ['signMessage'], target: 'PAYMENT', @@ -470,6 +494,26 @@ export const checkoutMachine = createMachine( DISCONNECT, }, }, + GITCOIN: { + on: { + SUBMIT_DATA: [ + { + target: 'PAYMENT', + actions: ['submitData'], + }, + ], + BACK: [ + { + target: 'MESSAGE_TO_SIGN', + cond: 'requireMessageToSign', + }, + { + target: 'METADATA', + }, + ], + DISCONNECT, + }, + }, PAYMENT: { on: { SELECT_PAYMENT_METHOD: [ @@ -502,6 +546,10 @@ export const checkoutMachine = createMachine( cond: 'requireCaptcha', target: 'CAPTCHA', }, + { + cond: 'requireGitcoin', + target: 'GITCOIN', + }, { cond: 'requireMessageToSign', target: 'MESSAGE_TO_SIGN', @@ -668,6 +716,7 @@ export const checkoutMachine = createMachine( requirePassword: (context) => context && context?.hook === 'password', requirePromo: (context) => context && context?.hook === 'promocode', requireGuild: (context) => context && context?.hook === 'guild', + requireGitcoin: (context) => context && context?.hook === 'gitcoin', isCardPayment: (context) => ['card'].includes(context.payment.method), }, } diff --git a/unlock-app/src/components/interface/checkout/main/checkoutMachine.typegen.ts b/unlock-app/src/components/interface/checkout/main/checkoutMachine.typegen.ts index 209945f3f63..198be49c091 100644 --- a/unlock-app/src/components/interface/checkout/main/checkoutMachine.typegen.ts +++ b/unlock-app/src/components/interface/checkout/main/checkoutMachine.typegen.ts @@ -27,6 +27,7 @@ export interface Typegen0 { eventsCausingGuards: { isCardPayment: 'BACK' requireCaptcha: 'BACK' | 'SELECT_RECIPIENTS' | 'SIGN_MESSAGE' + requireGitcoin: 'BACK' | 'SELECT_RECIPIENTS' | 'SIGN_MESSAGE' requireGuild: 'BACK' | 'SELECT_RECIPIENTS' | 'SIGN_MESSAGE' requireMessageToSign: 'BACK' | 'SELECT_LOCK' | 'SELECT_RECIPIENTS' requirePassword: 'BACK' | 'SELECT_RECIPIENTS' | 'SIGN_MESSAGE' @@ -39,6 +40,7 @@ export interface Typegen0 { | 'CAPTCHA' | 'CARD' | 'CONFIRM' + | 'GITCOIN' | 'GUILD' | 'MESSAGE_TO_SIGN' | 'METADATA' diff --git a/unlock-app/src/components/interface/checkout/main/index.tsx b/unlock-app/src/components/interface/checkout/main/index.tsx index 8084f05babc..aff5355f2eb 100644 --- a/unlock-app/src/components/interface/checkout/main/index.tsx +++ b/unlock-app/src/components/interface/checkout/main/index.tsx @@ -20,6 +20,7 @@ import { isEqual } from 'lodash' import { CheckoutHead, TopNavigation } from '../Shell' import { PaywallConfigType } from '@unlock-protocol/core' import { Guild } from './Guild' +import { Gitcoin } from './Gitcoin' interface Props { injectedProvider: any paywallConfig: PaywallConfigType @@ -233,7 +234,14 @@ export function Checkout({ /> ) } - + case 'GITCOIN': { + return ( + + ) + } case 'RETURNING': { return ( ) } - default: { return null } diff --git a/unlock-app/src/components/interface/checkout/main/useCheckoutHook.ts b/unlock-app/src/components/interface/checkout/main/useCheckoutHook.ts index eb9c51ca76c..c0cc4aa9677 100644 --- a/unlock-app/src/components/interface/checkout/main/useCheckoutHook.ts +++ b/unlock-app/src/components/interface/checkout/main/useCheckoutHook.ts @@ -10,6 +10,7 @@ const HookIdMapping: Partial> = { PASSWORD: 'password', GUILD: 'guild', CAPTCHA: 'captcha', + GITCOIN: 'gitcoin', PROMOCODE: 'promocode', PROMO_CODE_CAPPED: 'promocode', PASSWORD_CAPPED: 'password', diff --git a/unlock-app/src/components/interface/checkout/main/useStepperItems.ts b/unlock-app/src/components/interface/checkout/main/useStepperItems.ts index a57b33094f9..622bc78bd6e 100644 --- a/unlock-app/src/components/interface/checkout/main/useStepperItems.ts +++ b/unlock-app/src/components/interface/checkout/main/useStepperItems.ts @@ -68,6 +68,7 @@ export function useStepperItems( const isCaptcha = hook === 'captcha' || hookType === 'captcha' const isPromo = hook === 'promocode' || hookType === 'promocode' const isGuild = hook === 'guild' || hookType === 'guild' + const isGitcoin = hook === 'gitcoin' || hookType === 'gitcoin' const isMember = existingMember || isExistingMember const checkoutItems: StepItem[] = [ { @@ -107,6 +108,11 @@ export function useStepperItems( name: 'Guild', to: 'GUILD', } + : isGitcoin + ? { + name: 'Gitcoin Passport Verification', + to: 'GITCOIN', + } : { name: 'Solve captcha', to: 'CAPTCHA', diff --git a/unlock-app/src/components/interface/keychain/CancelAndRefundModal.tsx b/unlock-app/src/components/interface/keychain/CancelAndRefundModal.tsx index dab8b512a25..867e38eab12 100644 --- a/unlock-app/src/components/interface/keychain/CancelAndRefundModal.tsx +++ b/unlock-app/src/components/interface/keychain/CancelAndRefundModal.tsx @@ -1,4 +1,4 @@ -import { Button, Modal, Placeholder } from '@unlock-protocol/ui' +import { Button, Modal, Placeholder, PriceFormatter } from '@unlock-protocol/ui' import React from 'react' import { useMutation, useQuery } from '@tanstack/react-query' import { ToastHelper } from '../../helpers/toast.helper' @@ -9,7 +9,7 @@ export interface CancelAndRefundProps { isOpen: boolean lock: any setIsOpen: (open: boolean) => void - account: string + owner: string currency: string tokenId: string network: number @@ -22,7 +22,7 @@ export const CancelAndRefundModal = ({ isOpen, lock, setIsOpen, - account: owner, + owner, currency, tokenId, network, @@ -117,7 +117,8 @@ export const CancelAndRefundModal = ({ ) : isRefundable ? ( <> - {currency} {parseFloat(`${refundAmount}`!).toFixed(3)} + {currency}{' '} + {' '} {` will be refunded, Do you want to proceed?`} diff --git a/unlock-app/src/components/interface/keychain/Extend.tsx b/unlock-app/src/components/interface/keychain/Extend.tsx index fe75ea0e20d..2418516a8a5 100644 --- a/unlock-app/src/components/interface/keychain/Extend.tsx +++ b/unlock-app/src/components/interface/keychain/Extend.tsx @@ -40,7 +40,7 @@ export interface Props { isOpen: boolean lock: any setIsOpen: (open: boolean) => void - account: string + owner: string currency: string tokenId: string network: number @@ -51,7 +51,7 @@ export const ExtendMembershipModal = ({ isOpen, lock, setIsOpen, - account: owner, + owner, network, ownedKey, }: Props) => { diff --git a/unlock-app/src/components/interface/keychain/Key.tsx b/unlock-app/src/components/interface/keychain/Key.tsx index 245a04728ca..60dfc06d7b9 100644 --- a/unlock-app/src/components/interface/keychain/Key.tsx +++ b/unlock-app/src/components/interface/keychain/Key.tsx @@ -37,10 +37,7 @@ import { RiNavigationFill as ExploreIcon, RiQrCodeLine as QrCodeIcon, } from 'react-icons/ri' -import { - RiFileCopyLine as CopyLineIcon, - RiExternalLinkFill as ExternalIcon, -} from 'react-icons/ri' +import { RiFileCopyLine as CopyLineIcon } from 'react-icons/ri' import { ExtendMembershipModal } from './Extend' import { Key } from '~/hooks/useKeys' import { TbReceipt as ReceiptIcon } from 'react-icons/tb' @@ -63,14 +60,14 @@ export const MenuButton = tw.button( export interface Props { ownedKey: Key - account: string + owner: string network: number } -function Key({ ownedKey, account, network }: Props) { +function Key({ ownedKey, owner, network }: Props) { const { lock, expiration, tokenId, isExpired, isExtendable, isRenewable } = ownedKey - const { getWalletService, isUnlockAccount, watchAsset } = useAuth() + const { getWalletService, isUnlockAccount, watchAsset, account } = useAuth() const wedlockService = useContext(WedlockServiceContext) const web3Service = useWeb3Service() const config = useConfig() @@ -195,7 +192,7 @@ function Key({ ownedKey, account, network }: Props) { setExpireAndRefunded(true)} @@ -225,7 +222,7 @@ function Key({ ownedKey, account, network }: Props) { setIsOpen={setShowExtendMembership} lock={lock} tokenId={tokenId} - account={account} + owner={owner} currency={symbol} network={network} ownedKey={ownedKey} @@ -256,14 +253,16 @@ function Key({ ownedKey, account, network }: Props) { )}
    - + {owner == account && ( + + )} )} - {!isUnlockAccount && ( + {owner == account && !isUnlockAccount && ( {({ active, disabled }) => ( )} - {tokenId && isEthPassSupported(network) && ( - <> - - {({ active, disabled }) => ( - { - window.location.assign(url) - }} - > - Google Wallet - Add to my Google Wallet - - )} - - - {({ active, disabled }) => ( - { - if (isIOS) { - // Download + {owner == account && + tokenId && + isEthPassSupported(network) && ( + <> + + {({ active, disabled }) => ( + { window.location.assign(url) - } else if (setPassUrl) { - // Show the modal - setPassUrl(url) - setShowApplePassModal(true) - } - }} - > - Apple Wallet - Add to my Apple Wallet - - )} - - - )} + }} + > + Google Wallet + Add to my Google Wallet + + )} + + + {({ active, disabled }) => ( + { + if (isIOS) { + // Download + window.location.assign(url) + } else if (setPassUrl) { + // Show the modal + setPassUrl(url) + setShowApplePassModal(true) + } + }} + > + Apple Wallet + Add to my Apple Wallet + + )} + + + )} {({ active, disabled }) => ( )} - {receiptsPageUrl?.length && ( + {owner == account && receiptsPageUrl?.length && ( {({ active, disabled }) => ( )} - - {({ active, disabled }) => ( - { - event.preventDefault() - setShowExtendMembership(true) - }} - > - - {isRenewable && !isKeyExpired - ? 'Renew membership' - : 'Extend membership'} - - )} - -
    -
    - - {({ active, disabled }) => ( - { - event.preventDefault() - setShowCancelModal(!showCancelModal) - }} - > - - Cancel and refund - - )} - + {/* This should go in the details modal! */} + {owner == account && ( + + {({ active, disabled }) => ( + { + event.preventDefault() + setShowExtendMembership(true) + }} + > + + {isRenewable && !isKeyExpired + ? 'Renew membership' + : 'Extend membership'} + + )} + + )}
    + {owner == account && !isUnlockAccount && ( +
    + + {({ active, disabled }) => ( + { + event.preventDefault() + setShowCancelModal(!showCancelModal) + }} + > + + Cancel and refund + + )} + +
    + )} @@ -475,7 +481,12 @@ function Key({ ownedKey, account, network }: Props) { {lock?.name?.slice(0, 2)} -
    +
    + {networkName && ( +
    + {networkName} +
    + )}
    {minifyAddress(lock.address)} -
    - - View - +
    {' '}

    {lock.name}

    - {networkName && ( -
    - Network - {networkName} -
    - )}
    ) diff --git a/unlock-app/src/components/interface/keychain/KeyDetails.tsx b/unlock-app/src/components/interface/keychain/KeyDetails.tsx index 602b5ab7afe..cd62b3b52e8 100644 --- a/unlock-app/src/components/interface/keychain/KeyDetails.tsx +++ b/unlock-app/src/components/interface/keychain/KeyDetails.tsx @@ -1,49 +1,58 @@ import React, { useContext } from 'react' -import { AuthenticationContext } from '../../../contexts/AuthenticationContext' import Key from './Key' import { ImageBar } from '../locks/Manage/elements/ImageBar' import { useKeys } from '~/hooks/useKeys' -import { Placeholder } from '@unlock-protocol/ui' +import { minifyAddress, Placeholder } from '@unlock-protocol/ui' +import AuthenticationContext from '~/contexts/AuthenticationContext' +import networks from '@unlock-protocol/networks' +import { NetworkConfig } from '@unlock-protocol/types' -export const KeyDetails = () => { +export const KeyDetails = ({ owner }: { owner: string }) => { const { account } = useContext(AuthenticationContext) const { keys, isKeysLoading } = useKeys({ - owner: account, + owner, + networks: Object.values(networks) + .filter((item: NetworkConfig) => !item.isTestNetwork || owner === account) + .map((item: NetworkConfig) => item.id), }) if (!keys?.length && !isKeysLoading) { return ( ) } return ( -
    - {isKeysLoading && - Array.from({ length: 10 }).map((_, index) => ( - - - - - - - - ))} - {!isKeysLoading && - keys?.map((item) => ( - - ))} +
    +
    + {isKeysLoading && + Array.from({ length: 10 }).map((_, index) => ( + + + + + + + + ))} + {!isKeysLoading && + keys?.map((item: any) => ( + + ))} +
    ) } diff --git a/unlock-app/src/components/interface/keychain/KeyInfoDrawer.tsx b/unlock-app/src/components/interface/keychain/KeyInfoDrawer.tsx index bf23d74a149..54218cad7d9 100644 --- a/unlock-app/src/components/interface/keychain/KeyInfoDrawer.tsx +++ b/unlock-app/src/components/interface/keychain/KeyInfoDrawer.tsx @@ -88,7 +88,7 @@ interface KeyInfoProps { tokenId: string network: number lock: any - account: string + owner: string expiration: string imageURL?: string } @@ -97,7 +97,7 @@ export const KeyInfo = ({ tokenId, lock, network, - account, + owner, expiration, imageURL, }: KeyInfoProps) => { @@ -164,7 +164,7 @@ export const KeyInfo = ({ }, { retry: 0, - enabled: !!(lock?.address && account), + enabled: !!(lock?.address && owner), onError(error) { console.error(error) }, @@ -233,7 +233,7 @@ export const KeyInfo = ({ {`${keyPrice.amount} ${keyPrice.symbol}`} )} - {subscription && ( + {expiration !== MAX_UINT && subscription && ( { return ( { + const { socials, loading } = useSocials([owner]) + const size = 90 + if (loading) { + return ( + + + + + + ) + } + const social = socials[owner] + if (!social) { + return ( +
    +

    + Member Keychain +

    +
    + A Key is a membership or ticket NFT created on Unlock Protocol +
    +
    + ) + } + return ( +
    + {social.profileImage && ( + {social.profileName} + )} +
    +

    + Member Keychain +

    +

    + All Unlock powered memberships, tickets and certifications owned by{' '} + {social.profileUrl ? ( + + {social.profileDisplayName} + + ) : ( + social.profileDisplayName + )} + . +

    +
    +
    + ) +} + +export default OwnerSocials diff --git a/unlock-app/src/components/interface/locks/CheckoutUrl/elements/BasicConfigForm.tsx b/unlock-app/src/components/interface/locks/CheckoutUrl/elements/BasicConfigForm.tsx index 3fde850abf7..9fe6f727b37 100644 --- a/unlock-app/src/components/interface/locks/CheckoutUrl/elements/BasicConfigForm.tsx +++ b/unlock-app/src/components/interface/locks/CheckoutUrl/elements/BasicConfigForm.tsx @@ -2,44 +2,16 @@ import { BasicPaywallConfigSchema } from '~/unlockTypes' import { useForm } from 'react-hook-form' import { Input, - FieldLayout, + Checkbox, TextBox, Button, ImageUpload, Modal, } from '@unlock-protocol/ui' import { z } from 'zod' -import { InputHTMLAttributes, forwardRef, useState } from 'react' +import { useState } from 'react' import { useImageUpload } from '~/hooks/useImageUpload' -interface CheckBoxInputProps extends InputHTMLAttributes { - label: string - error?: string - description?: string -} - -export const CheckBoxInput = forwardRef( - ({ label, error, description, ...rest }, ref) => { - return ( - -
    - - -
    -
    - ) - } -) - -CheckBoxInput.displayName = 'CheckBoxInput' - interface Props { onChange: (values: z.infer) => void defaultValues?: z.infer @@ -149,7 +121,7 @@ export const BasicConfigForm = ({ onChange, defaultValues }: Props) => { })} error={errors.messageToSign?.message} /> - { error={errors.persistentCheckout?.message} {...register('persistentCheckout')} /> - - - - = ({ description={PaywallLockConfig.shape.dataBuilder?.description} {...register('dataBuilder')} /> - - { const config = useConfig() if (!network) return null - console.log(network) if (!NETWORK_MAPPING_MAPPING[network!]) return const { date } = NETWORK_MAPPING_MAPPING[network!] - console.log(date) const networkName = config.networks[network!].name return ( diff --git a/unlock-app/src/components/interface/locks/List/elements/LockCard.tsx b/unlock-app/src/components/interface/locks/List/elements/LockCard.tsx index 2c8a358c792..5a32c53cd3f 100644 --- a/unlock-app/src/components/interface/locks/List/elements/LockCard.tsx +++ b/unlock-app/src/components/interface/locks/List/elements/LockCard.tsx @@ -14,6 +14,8 @@ import { ethers } from 'ethers' import { AddressLink } from '~/components/interface/AddressLink' import { Card, Detail, Icon } from '@unlock-protocol/ui' import { CryptoIcon } from '@unlock-protocol/crypto-icon' +import { PriceFormatter } from '@unlock-protocol/ui' + interface LockCardProps { lock: any network: number @@ -136,7 +138,9 @@ export const LockCard = ({ lock, network }: LockCardProps) => { >
    - {keyPrice} + + +
    @@ -154,7 +158,9 @@ export const LockCard = ({ lock, network }: LockCardProps) => { >
    - {balance} + + +
    >( @@ -244,7 +245,9 @@ export const LockDetailCard = ({
    - {priceLabel} + + +
    diff --git a/unlock-app/src/components/interface/locks/Manage/elements/MetadataCard.tsx b/unlock-app/src/components/interface/locks/Manage/elements/MetadataCard.tsx index 304aa83538b..0945a351d2e 100644 --- a/unlock-app/src/components/interface/locks/Manage/elements/MetadataCard.tsx +++ b/unlock-app/src/components/interface/locks/Manage/elements/MetadataCard.tsx @@ -69,7 +69,7 @@ const MembershipRenewal = ({ if (possible.lte(0)) { return ( - + User balance of {balance.amount} {balance.symbol} is too low to renew ) @@ -230,7 +230,7 @@ const ChangeManagerModal = ({
    -
    +
    @@ -575,7 +564,7 @@ export const MetadataCard = ({ network={network} manager={manager} tokenId={tokenId} - label="Set key manager" + label="Set manager" onChange={(keyManager) => { setData({ ...data, @@ -647,33 +636,37 @@ export const MetadataCard = ({ />
    )} - {!isSubscriptionLoading && subscription && ( - <> - - {subscription.balance?.amount} {subscription.balance?.symbol} - - - {expirationDuration && expirationDuration !== MAX_UINT && ( + {!isSubscriptionLoading && + subscription && + expirationDuration && + expirationDuration !== MAX_UINT && ( + <> - {durationAsText(expirationDuration)} + {subscription.balance?.amount}{' '} + {subscription.balance?.symbol} - )} - - )} + + { + + {durationAsText(expirationDuration)} + + } + + )}
    diff --git a/unlock-app/src/components/interface/locks/Manage/elements/TotalBar.tsx b/unlock-app/src/components/interface/locks/Manage/elements/TotalBar.tsx index 91e7fbd36b6..55bc2cd2a8b 100644 --- a/unlock-app/src/components/interface/locks/Manage/elements/TotalBar.tsx +++ b/unlock-app/src/components/interface/locks/Manage/elements/TotalBar.tsx @@ -1,4 +1,4 @@ -import { Button, Detail, Card } from '@unlock-protocol/ui' +import { Button, Detail, Card, PriceFormatter } from '@unlock-protocol/ui' import React, { useState } from 'react' import { useQueries } from '@tanstack/react-query' import { useConfig } from '~/utils/withConfig' @@ -65,7 +65,6 @@ export const TotalBar = ({ lockAddress, network }: TotalsProps) => { const withdrawDisabled = false // parseFloat(`${balance}`) === 0) || loading - const formattedBalance = parseFloat(`${balance || 0}`)?.toFixed(2) const symbol = lock?.currencySymbol || baseCurrencySymbol const wrapperClass = @@ -95,9 +94,11 @@ export const TotalBar = ({ lockAddress, network }: TotalsProps) => { valueSize="large" loading={loading} > -
    +
    - {formattedBalance} + + + {isManager && (
    {stripeConnected ? ( -

    +

    Check{' '} = { options: [ { label: 'Password', - value: HookType.PASSWORD, - component: (args) => , - }, - { - label: 'Password with caps', value: HookType.PASSWORD_CAPPED, component: (args) => , }, @@ -98,6 +93,11 @@ export const HookMapping: Record = { value: HookType.PROMO_CODE_CAPPED, component: (args) => , }, + { + label: 'Gitcoin Passport verification', + value: HookType.GITCOIN, + component: (args) => , + }, ], }, keyCancel: { diff --git a/unlock-app/src/components/interface/locks/Settings/forms/UpdatePriceForm.tsx b/unlock-app/src/components/interface/locks/Settings/forms/UpdatePriceForm.tsx index 2baa986fb80..1b250b28c27 100644 --- a/unlock-app/src/components/interface/locks/Settings/forms/UpdatePriceForm.tsx +++ b/unlock-app/src/components/interface/locks/Settings/forms/UpdatePriceForm.tsx @@ -55,7 +55,7 @@ export const UpdatePriceForm = ({ mode: 'onChange', defaultValues: { currencyContractAddress: undefined, - keyPrice: keyPrice?.toFixed(3), + keyPrice: keyPrice?.toString(), symbol: '', isFree, }, diff --git a/unlock-app/src/components/interface/locks/Settings/forms/hooksComponents/GitcoinContractHook.tsx b/unlock-app/src/components/interface/locks/Settings/forms/hooksComponents/GitcoinContractHook.tsx new file mode 100644 index 00000000000..e687aae3082 --- /dev/null +++ b/unlock-app/src/components/interface/locks/Settings/forms/hooksComponents/GitcoinContractHook.tsx @@ -0,0 +1,84 @@ +import { CustomComponentProps } from '../UpdateHooksForm' +import { Button, Input } from '@unlock-protocol/ui' +import { useEffect } from 'react' +import { useFormContext } from 'react-hook-form' +import { + useGetLockSettings, + useSaveLockSettings, +} from '~/hooks/useLockSettings' + +export const GitcoinContractHook = ({ + lockAddress, + network, + setEventsHooksMutation, +}: CustomComponentProps) => { + const { data: settings } = useGetLockSettings({ + lockAddress, + network, + }) + + const { mutateAsync: saveSettingsMutation } = useSaveLockSettings() + + const { handleSubmit, register, getValues, setValue } = useFormContext() + + // initialize the form field with the fetched setting + useEffect(() => { + if (settings?.requiredGitcoinPassportScore !== undefined) { + setValue( + 'hook.requiredGitcoinPassportScore', + settings.requiredGitcoinPassportScore + ) + } + }, [settings, setValue]) + + const onSubmit = async (values: any) => { + const requiredGitcoinPassportScore = getValues( + 'hook.requiredGitcoinPassportScore' + ).toString() + + await saveSettingsMutation({ + lockAddress, + network, + requiredGitcoinPassportScore: requiredGitcoinPassportScore, + }) + + await setEventsHooksMutation.mutateAsync(values) + } + + return ( +

    +

    + With this hook, you can control membership purchases exclusively for + members with a required Gitcoin passport score. +

    + + + +
    + +
    +
    + ) +} diff --git a/unlock-app/src/components/interface/locks/Settings/forms/hooksComponents/PasswordContractHook.tsx b/unlock-app/src/components/interface/locks/Settings/forms/hooksComponents/PasswordContractHook.tsx deleted file mode 100644 index 91edda7562e..00000000000 --- a/unlock-app/src/components/interface/locks/Settings/forms/hooksComponents/PasswordContractHook.tsx +++ /dev/null @@ -1,121 +0,0 @@ -import { Button, Input, Placeholder } from '@unlock-protocol/ui' -import { DEFAULT_USER_ACCOUNT_ADDRESS } from '~/constants' -import { CustomComponentProps } from '../UpdateHooksForm' -import { useAuth } from '~/contexts/AuthenticationContext' -import { useMutation, useQuery } from '@tanstack/react-query' -import { ToastHelper } from '~/components/helpers/toast.helper' -import { useWeb3Service } from '~/utils/withWeb3Service' -import { getEthersWalletFromPassword } from '~/utils/strings' -import { useFormContext } from 'react-hook-form' - -export const PasswordContractHook = ({ - disabled, - lockAddress, - network, - hookAddress, - setEventsHooksMutation, -}: CustomComponentProps) => { - const { getWalletService } = useAuth() - const web3Service = useWeb3Service() - - const onSavePassword = async (password: string) => { - const { address: signerAddress } = - getEthersWalletFromPassword(password) ?? {} - const walletService = await getWalletService(network) - const tx = await walletService.setPasswordHookSigner( - { - lockAddress, - contractAddress: hookAddress, - signerAddress, - network, - }, - walletService.signer - ) - return tx.wait() - } - - const { data: signers = DEFAULT_USER_ACCOUNT_ADDRESS, isLoading } = useQuery( - ['getSigners', lockAddress, network], - async () => { - return web3Service.getPasswordHookSigners({ - lockAddress, - contractAddress: hookAddress, - network, - }) - } - ) - - const hasSigner = - signers?.toLowerCase() !== DEFAULT_USER_ACCOUNT_ADDRESS?.toLowerCase() - - const savePasswordMutation = useMutation(onSavePassword) - - const onSubmit = async ({ hook, ...rest }: any) => { - await setEventsHooksMutation.mutateAsync(rest) - const promise = savePasswordMutation.mutateAsync(hook.password) - await ToastHelper.promise(promise, { - loading: 'Updating password...', - success: 'Password is set for the lock.', - error: 'There is an issue with password update.', - }) - } - - const disabledInput = disabled || savePasswordMutation.isLoading - - const { - handleSubmit, - register, - formState: { errors }, - } = useFormContext() - - if (isLoading) { - return ( - - -
    - -
    -
    - ) - } - - return ( -
    - - There is already a password set, enter and save a new one to - update it.{' '} - - ) - } - disabled={disabledInput} - /> -
    - -
    -
    - ) -} diff --git a/unlock-app/src/hooks/useDataForGitcoinPassport.ts b/unlock-app/src/hooks/useDataForGitcoinPassport.ts new file mode 100644 index 00000000000..c22467c5503 --- /dev/null +++ b/unlock-app/src/hooks/useDataForGitcoinPassport.ts @@ -0,0 +1,83 @@ +import { useQuery } from '@tanstack/react-query' +import { storage } from '~/config/storage' +import { ToastHelper } from '~/components/helpers/toast.helper' + +const getDataForGitcoinPassport = async ( + network: number, + lockAddress: string, + recipients: string[] +) => { + try { + const response = await storage.getDataForRecipientsAndGitcoinPassport( + network, + lockAddress, + recipients + ) + + return response.data.result + } catch (error: any) { + if (error.response) { + // Propagate the error as is to be caught by the calling function + throw error + } + // Fallback for other types of errors + throw new Error('An unexpected error occurred') + } +} + +interface UseDataForGitcoinPassportProps { + lockAddress: string + network: number + recipients: string[] +} + +export function useDataForGitcoinPassport({ + lockAddress, + network, + recipients, +}: UseDataForGitcoinPassportProps) { + return useQuery( + ['getDataForGitcoinPassport', lockAddress, network, recipients], + async () => { + try { + return await getDataForGitcoinPassport(network, lockAddress, recipients) + } catch (error: any) { + if (error.response) { + // Handle specific error statuses + const status = error.response.status + switch (status) { + case 400: + ToastHelper.error( + 'The required Gitcoin Passport score is not defined or invalid.' + ) + error.isInvalidScoreError = true + break + case 504: + ToastHelper.error( + 'Timeout: Unable to verify scores within expected time frame.' + ) + error.isTimeoutError = true + break + case 422: + ToastHelper.error(error.response.data.error) + error.isMisconfigurationError = true + break + default: + ToastHelper.error(error.message || 'An unexpected error occurred') + } + // Propagate error + throw error + } else { + // Generic error message for other types of errors + ToastHelper.error(error.message || 'An unexpected error occurred') + } + // Return empty values to maintain consistency + return recipients.map(() => '') + } + }, + { + enabled: false, // Manually trigger the query + retry: false, // Do not retry after a failure + } + ) +} diff --git a/unlock-app/src/hooks/useEventOrganizers.ts b/unlock-app/src/hooks/useEventOrganizers.ts new file mode 100644 index 00000000000..747c8ce13f0 --- /dev/null +++ b/unlock-app/src/hooks/useEventOrganizers.ts @@ -0,0 +1,66 @@ +import { useQuery } from '@tanstack/react-query' +import { PaywallConfigType } from '@unlock-protocol/core' +import { SubgraphService } from '@unlock-protocol/unlock-js' + +interface useEventOrganizersProps { + checkoutConfig: { + id?: string + config: PaywallConfigType + } +} +/** + * Check if currently authenticated user is manager for one of the event's locks. + * + */ +export const useEventOrganizers = ({ + checkoutConfig, +}: useEventOrganizersProps) => { + return useQuery( + ['eventOrganizers', checkoutConfig], + async (): Promise => { + const service = new SubgraphService() + // Group locks by network + const locksByNetwork: { [key: string]: string[] } = {} + const defaultNetwork = checkoutConfig.config.network + if (defaultNetwork) { + locksByNetwork[defaultNetwork] = [] + } + Object.keys(checkoutConfig.config.locks).forEach((lockAddress) => { + const lock = checkoutConfig.config.locks[lockAddress] + if (!lock.network && defaultNetwork) { + locksByNetwork[defaultNetwork].push(lockAddress) + } else { + if (!locksByNetwork[lock.network!]) { + locksByNetwork[lock.network!] = [] + } + locksByNetwork[lock.network!].push(lockAddress) + } + }) + const eventOrganizers: string[] = [] + await Promise.all( + Object.keys(locksByNetwork).map(async (network: string) => { + const locks = locksByNetwork[network] + const locksWithManagers = await service.locks( + { + first: locks.length, + where: { + address_in: locks, + }, + }, + { + networks: [network], + } + ) + locksWithManagers.forEach((lock) => { + lock.lockManagers.forEach((manager: string) => { + if (eventOrganizers.indexOf(manager) == -1) { + eventOrganizers.push(manager) + } + }) + }) + }) + ) + return eventOrganizers + } + ) +} diff --git a/unlock-app/src/hooks/useKeys.ts b/unlock-app/src/hooks/useKeys.ts index 6814aee55be..4cfe23a30d7 100644 --- a/unlock-app/src/hooks/useKeys.ts +++ b/unlock-app/src/hooks/useKeys.ts @@ -12,6 +12,7 @@ interface Options { lockAddress?: string owner?: string networks?: number[] + showTestNets?: boolean } export type Key = NonNullable['keys']>[0] diff --git a/unlock-app/src/hooks/useLockData.ts b/unlock-app/src/hooks/useLockData.ts index c968fb7d0d0..135fc45ab82 100644 --- a/unlock-app/src/hooks/useLockData.ts +++ b/unlock-app/src/hooks/useLockData.ts @@ -32,17 +32,13 @@ export const useLockData = ({ lockAddress, network }: Options) => { export const useMultipleLockData = (locks: PaywallLocksConfigType) => { const web3Service = new Web3Service(networks) - const results = useQueries({ + const results = useQueries({ queries: Object.keys(locks).map((lockAddress: string) => { const network = locks[lockAddress].network return { queryKey: ['lock', lockAddress, network], queryFn: async () => { - const result = await web3Service.getLock(lockAddress, network!) - return { - ...result, - network, - } + return web3Service.getLock(lockAddress, network!) as Promise }, } }), diff --git a/unlock-app/src/hooks/useLockSettings.ts b/unlock-app/src/hooks/useLockSettings.ts index 783fd034460..c200b094472 100644 --- a/unlock-app/src/hooks/useLockSettings.ts +++ b/unlock-app/src/hooks/useLockSettings.ts @@ -87,6 +87,7 @@ interface SaveLockProps { creditCardCurrency?: string promoCodes?: string[] crossmintClientId?: string + requiredGitcoinPassportScore?: number | null passwords?: string[] } diff --git a/unlock-app/src/hooks/useSocials.ts b/unlock-app/src/hooks/useSocials.ts new file mode 100644 index 00000000000..8026b5db885 --- /dev/null +++ b/unlock-app/src/hooks/useSocials.ts @@ -0,0 +1,88 @@ +import { useQuery } from '@airstack/airstack-react' + +interface Social { + id: string + profileName: string + profileImage: string + profileDisplayName: string + profileUrl: string +} +interface Socials { + [address: string]: Social +} + +const query = `query DomainsAndSocials($wallets: [Address!]) { + Domains( + input: { + filter: { + isPrimary: { + _eq: true + }, + resolvedAddress: { + _in: $wallets + } + }, + blockchain: ethereum + }) { + Domain { + resolvedAddress + name + } + } + Socials( + input: { + filter: { + userAssociatedAddresses: { + _in: $wallets + } + }, + blockchain: ethereum + }) { + Social { + dappName + profileName + profileUrl + userAssociatedAddresses + id + profileDisplayName + profileHandle + profileImage + userAssociatedAddresses + } + } +}` + +export const useSocials = (addresses: string[]) => { + const socials: Socials = {} as Socials + + const { data, loading, error } = useQuery(query, { + wallets: ['0xF41a98D4F2E52aa1ccB48F0b6539e955707b8F7a', ...addresses], + }) + + if (data) { + data.Socials?.Social?.forEach((social: any) => { + social.userAssociatedAddresses.forEach((address: string) => { + if (addresses.indexOf(address) > -1) { + const existing = socials[address] || {} + let profileUrl = social.profileUrl + if (social.dappName === 'farcaster') { + profileUrl = `https://warpcast.com/${social.profileHandle}` + } else if (social.dappName === 'lens') { + profileUrl = `https://hey.xyz/u/${social.profileHandle}` + } + socials[address] = { + id: existing.id || social.id, + profileName: existing.profileName || social.profileName, + profileImage: existing.profileImage || social.profileImage, + profileDisplayName: + existing.profileDisplayName || + social.profileDisplayName || + social.profileName, + profileUrl: existing.profileUrl || profileUrl, + } + } + }) + }) + } + return { socials, loading, error } +} diff --git a/unlock-app/src/pages/_app.tsx b/unlock-app/src/pages/_app.tsx index 65bcdf2f30a..9c7800097df 100644 --- a/unlock-app/src/pages/_app.tsx +++ b/unlock-app/src/pages/_app.tsx @@ -1,3 +1,4 @@ +import { AirstackProvider } from '@airstack/airstack-react' import { SpeedInsights } from '@vercel/speed-insights/next' import React, { useEffect } from 'react' import type { AppProps } from 'next/app' @@ -38,7 +39,9 @@ const UnlockApp = ({ Component, pageProps }: AppProps) => { }> - + + + diff --git a/unlock-app/src/utils/checkoutLockUtils.ts b/unlock-app/src/utils/checkoutLockUtils.ts index 891961ee9d9..2e17f121c54 100644 --- a/unlock-app/src/utils/checkoutLockUtils.ts +++ b/unlock-app/src/utils/checkoutLockUtils.ts @@ -125,9 +125,8 @@ export const formattedKeyPrice = ( return 'FREE' } const price = keyPrice ? parseFloat(keyPrice) * numberOfRecipients : null - return `${price - ?.toLocaleString() // language-sensitive representation of the price - ?.toString()} ${lockTickerSymbol(lock, baseCurrencySymbol)}` + + return `${price?.toString()} ${lockTickerSymbol(lock, baseCurrencySymbol)}` } /** diff --git a/unlock-app/src/utils/truncateString.ts b/unlock-app/src/utils/truncateString.ts new file mode 100644 index 00000000000..0675fbcbc7c --- /dev/null +++ b/unlock-app/src/utils/truncateString.ts @@ -0,0 +1,14 @@ +export function truncateString(text: string, maxLength: number): string { + if (text.length <= maxLength) { + return text + } + + const shortenedString = text.substring(0, maxLength) + const lastSpaceIndex = shortenedString.lastIndexOf(' ') + + if (lastSpaceIndex !== -1) { + return shortenedString.substring(0, lastSpaceIndex) + '...' + } else { + return shortenedString + '...' + } +} diff --git a/yarn.lock b/yarn.lock index 8584e1471a4..f1f4e8f6b20 100644 --- a/yarn.lock +++ b/yarn.lock @@ -26,6 +26,25 @@ __metadata: languageName: node linkType: hard +"@aduh95/viz.js@npm:^3.7.0": + version: 3.7.0 + resolution: "@aduh95/viz.js@npm:3.7.0" + checksum: 10/4b1aac92e7a6ea783b1ad33220163dd8623dbcd3bf947deb6a8637ee8a3b59137e76d87638a479e96df04c929dcdddc8bb3432b065642b11f75d944b431e2f9c + languageName: node + linkType: hard + +"@airstack/airstack-react@npm:0.6.2": + version: 0.6.2 + resolution: "@airstack/airstack-react@npm:0.6.2" + dependencies: + graphql: "npm:16.6.0" + peerDependencies: + react: ^16.8.0 || ^17.0.0 || ^18.0.0 + react-dom: ^16.8.0 || ^17.0.0 || ^18.0.0 + checksum: 10/2d87b48237157b2b4bd4defde1ad34665f2247b1af9210b142a7df042a18b0e87476996e1e2e5b6b56023d3afee87504856a3ce4ac16402c1865776c9d88fbaf + languageName: node + linkType: hard + "@algolia/autocomplete-core@npm:1.9.3": version: 1.9.3 resolution: "@algolia/autocomplete-core@npm:1.9.3" @@ -276,6 +295,34 @@ __metadata: languageName: node linkType: hard +"@arbitrum/nitro-contracts@npm:1.0.2": + version: 1.0.2 + resolution: "@arbitrum/nitro-contracts@npm:1.0.2" + dependencies: + "@openzeppelin/contracts": "npm:4.5.0" + "@openzeppelin/contracts-upgradeable": "npm:4.5.2" + patch-package: "npm:^6.4.7" + sol2uml: "npm:2.2.0" + dependenciesMeta: + sol2uml: + optional: true + checksum: 10/242119c32a6d58dc394c8f2f407d304643b41e0996fd0650fd34800b170660da3ab5c0e1c1aeede193ff3fda5402a375e21efaefcb48199fc962052de4b3a78e + languageName: node + linkType: hard + +"@arbitrum/sdk@npm:3.3.3": + version: 3.3.3 + resolution: "@arbitrum/sdk@npm:3.3.3" + dependencies: + "@ethersproject/address": "npm:^5.0.8" + "@ethersproject/bignumber": "npm:^5.1.1" + "@ethersproject/bytes": "npm:^5.0.8" + async-mutex: "npm:^0.4.0" + ethers: "npm:^5.1.0" + checksum: 10/cf21a8750191beaa588bbe350853118d6142ac70aebcdb38306ff5144cbbb89a7ac2680b03537f218bdad9eb528cfe85ba97834794bcbe397ce7d817f2a010c8 + languageName: node + linkType: hard + "@ardatan/relay-compiler@npm:12.0.0": version: 12.0.0 resolution: "@ardatan/relay-compiler@npm:12.0.0" @@ -518,15 +565,15 @@ __metadata: linkType: hard "@aws-sdk/client-s3@npm:^3.0.0": - version: 3.540.0 - resolution: "@aws-sdk/client-s3@npm:3.540.0" + version: 3.552.0 + resolution: "@aws-sdk/client-s3@npm:3.552.0" dependencies: "@aws-crypto/sha1-browser": "npm:3.0.0" "@aws-crypto/sha256-browser": "npm:3.0.0" "@aws-crypto/sha256-js": "npm:3.0.0" - "@aws-sdk/client-sts": "npm:3.540.0" - "@aws-sdk/core": "npm:3.535.0" - "@aws-sdk/credential-provider-node": "npm:3.540.0" + "@aws-sdk/client-sts": "npm:3.552.0" + "@aws-sdk/core": "npm:3.552.0" + "@aws-sdk/credential-provider-node": "npm:3.552.0" "@aws-sdk/middleware-bucket-endpoint": "npm:3.535.0" "@aws-sdk/middleware-expect-continue": "npm:3.535.0" "@aws-sdk/middleware-flexible-checksums": "npm:3.535.0" @@ -534,19 +581,19 @@ __metadata: "@aws-sdk/middleware-location-constraint": "npm:3.535.0" "@aws-sdk/middleware-logger": "npm:3.535.0" "@aws-sdk/middleware-recursion-detection": "npm:3.535.0" - "@aws-sdk/middleware-sdk-s3": "npm:3.535.0" - "@aws-sdk/middleware-signing": "npm:3.535.0" + "@aws-sdk/middleware-sdk-s3": "npm:3.552.0" + "@aws-sdk/middleware-signing": "npm:3.552.0" "@aws-sdk/middleware-ssec": "npm:3.537.0" "@aws-sdk/middleware-user-agent": "npm:3.540.0" "@aws-sdk/region-config-resolver": "npm:3.535.0" - "@aws-sdk/signature-v4-multi-region": "npm:3.535.0" + "@aws-sdk/signature-v4-multi-region": "npm:3.552.0" "@aws-sdk/types": "npm:3.535.0" "@aws-sdk/util-endpoints": "npm:3.540.0" "@aws-sdk/util-user-agent-browser": "npm:3.535.0" "@aws-sdk/util-user-agent-node": "npm:3.535.0" "@aws-sdk/xml-builder": "npm:3.535.0" "@smithy/config-resolver": "npm:^2.2.0" - "@smithy/core": "npm:^1.4.0" + "@smithy/core": "npm:^1.4.2" "@smithy/eventstream-serde-browser": "npm:^2.2.0" "@smithy/eventstream-serde-config-resolver": "npm:^2.2.0" "@smithy/eventstream-serde-node": "npm:^2.2.0" @@ -557,28 +604,28 @@ __metadata: "@smithy/invalid-dependency": "npm:^2.2.0" "@smithy/md5-js": "npm:^2.2.0" "@smithy/middleware-content-length": "npm:^2.2.0" - "@smithy/middleware-endpoint": "npm:^2.5.0" - "@smithy/middleware-retry": "npm:^2.2.0" + "@smithy/middleware-endpoint": "npm:^2.5.1" + "@smithy/middleware-retry": "npm:^2.3.1" "@smithy/middleware-serde": "npm:^2.3.0" "@smithy/middleware-stack": "npm:^2.2.0" "@smithy/node-config-provider": "npm:^2.3.0" "@smithy/node-http-handler": "npm:^2.5.0" "@smithy/protocol-http": "npm:^3.3.0" - "@smithy/smithy-client": "npm:^2.5.0" + "@smithy/smithy-client": "npm:^2.5.1" "@smithy/types": "npm:^2.12.0" "@smithy/url-parser": "npm:^2.2.0" "@smithy/util-base64": "npm:^2.3.0" "@smithy/util-body-length-browser": "npm:^2.2.0" "@smithy/util-body-length-node": "npm:^2.3.0" - "@smithy/util-defaults-mode-browser": "npm:^2.2.0" - "@smithy/util-defaults-mode-node": "npm:^2.3.0" + "@smithy/util-defaults-mode-browser": "npm:^2.2.1" + "@smithy/util-defaults-mode-node": "npm:^2.3.1" "@smithy/util-endpoints": "npm:^1.2.0" "@smithy/util-retry": "npm:^2.2.0" "@smithy/util-stream": "npm:^2.2.0" "@smithy/util-utf8": "npm:^2.3.0" "@smithy/util-waiter": "npm:^2.2.0" tslib: "npm:^2.6.2" - checksum: 10/083902842f94614bad792beae8c2596fa36a6f00a1642dd6dfa0f3dc1424f20d14bbb13c9413e7de4ae3bd91107373707eff7b6407ba5da7f89b7ceafa4ccf76 + checksum: 10/74785c5a37076c88d30896ea987cc25c3e3ad83834de9504d60672cd78d5ccf26d136103d6b806fc8e1ab25ce5f31db2fd1bbf3dbb3925f90588fa7494cb2b32 languageName: node linkType: hard @@ -631,14 +678,14 @@ __metadata: languageName: node linkType: hard -"@aws-sdk/client-sso-oidc@npm:3.540.0": - version: 3.540.0 - resolution: "@aws-sdk/client-sso-oidc@npm:3.540.0" +"@aws-sdk/client-sso-oidc@npm:3.552.0": + version: 3.552.0 + resolution: "@aws-sdk/client-sso-oidc@npm:3.552.0" dependencies: "@aws-crypto/sha256-browser": "npm:3.0.0" "@aws-crypto/sha256-js": "npm:3.0.0" - "@aws-sdk/client-sts": "npm:3.540.0" - "@aws-sdk/core": "npm:3.535.0" + "@aws-sdk/client-sts": "npm:3.552.0" + "@aws-sdk/core": "npm:3.552.0" "@aws-sdk/middleware-host-header": "npm:3.535.0" "@aws-sdk/middleware-logger": "npm:3.535.0" "@aws-sdk/middleware-recursion-detection": "npm:3.535.0" @@ -649,34 +696,34 @@ __metadata: "@aws-sdk/util-user-agent-browser": "npm:3.535.0" "@aws-sdk/util-user-agent-node": "npm:3.535.0" "@smithy/config-resolver": "npm:^2.2.0" - "@smithy/core": "npm:^1.4.0" + "@smithy/core": "npm:^1.4.2" "@smithy/fetch-http-handler": "npm:^2.5.0" "@smithy/hash-node": "npm:^2.2.0" "@smithy/invalid-dependency": "npm:^2.2.0" "@smithy/middleware-content-length": "npm:^2.2.0" - "@smithy/middleware-endpoint": "npm:^2.5.0" - "@smithy/middleware-retry": "npm:^2.2.0" + "@smithy/middleware-endpoint": "npm:^2.5.1" + "@smithy/middleware-retry": "npm:^2.3.1" "@smithy/middleware-serde": "npm:^2.3.0" "@smithy/middleware-stack": "npm:^2.2.0" "@smithy/node-config-provider": "npm:^2.3.0" "@smithy/node-http-handler": "npm:^2.5.0" "@smithy/protocol-http": "npm:^3.3.0" - "@smithy/smithy-client": "npm:^2.5.0" + "@smithy/smithy-client": "npm:^2.5.1" "@smithy/types": "npm:^2.12.0" "@smithy/url-parser": "npm:^2.2.0" "@smithy/util-base64": "npm:^2.3.0" "@smithy/util-body-length-browser": "npm:^2.2.0" "@smithy/util-body-length-node": "npm:^2.3.0" - "@smithy/util-defaults-mode-browser": "npm:^2.2.0" - "@smithy/util-defaults-mode-node": "npm:^2.3.0" + "@smithy/util-defaults-mode-browser": "npm:^2.2.1" + "@smithy/util-defaults-mode-node": "npm:^2.3.1" "@smithy/util-endpoints": "npm:^1.2.0" "@smithy/util-middleware": "npm:^2.2.0" "@smithy/util-retry": "npm:^2.2.0" "@smithy/util-utf8": "npm:^2.3.0" tslib: "npm:^2.6.2" peerDependencies: - "@aws-sdk/credential-provider-node": ^3.540.0 - checksum: 10/3d730be4c5031381f3c10b26243e26e5d50178f3aa511a38c0ad28b7f8e68897daead41da65dac98cfe81f6c0e37b074cf02bb63179ff112bdfd2472b70e1160 + "@aws-sdk/credential-provider-node": ^3.552.0 + checksum: 10/8b0bc32385a79507ae42ad5caf1705eeaa5ee285b059832ba835a6b3e1145742e22a59e386e3c86dffc3d0fff9174b23f26b4ab5af3a5a8638b6ea3f491bfddc languageName: node linkType: hard @@ -726,13 +773,13 @@ __metadata: languageName: node linkType: hard -"@aws-sdk/client-sso@npm:3.540.0": - version: 3.540.0 - resolution: "@aws-sdk/client-sso@npm:3.540.0" +"@aws-sdk/client-sso@npm:3.552.0": + version: 3.552.0 + resolution: "@aws-sdk/client-sso@npm:3.552.0" dependencies: "@aws-crypto/sha256-browser": "npm:3.0.0" "@aws-crypto/sha256-js": "npm:3.0.0" - "@aws-sdk/core": "npm:3.535.0" + "@aws-sdk/core": "npm:3.552.0" "@aws-sdk/middleware-host-header": "npm:3.535.0" "@aws-sdk/middleware-logger": "npm:3.535.0" "@aws-sdk/middleware-recursion-detection": "npm:3.535.0" @@ -743,32 +790,32 @@ __metadata: "@aws-sdk/util-user-agent-browser": "npm:3.535.0" "@aws-sdk/util-user-agent-node": "npm:3.535.0" "@smithy/config-resolver": "npm:^2.2.0" - "@smithy/core": "npm:^1.4.0" + "@smithy/core": "npm:^1.4.2" "@smithy/fetch-http-handler": "npm:^2.5.0" "@smithy/hash-node": "npm:^2.2.0" "@smithy/invalid-dependency": "npm:^2.2.0" "@smithy/middleware-content-length": "npm:^2.2.0" - "@smithy/middleware-endpoint": "npm:^2.5.0" - "@smithy/middleware-retry": "npm:^2.2.0" + "@smithy/middleware-endpoint": "npm:^2.5.1" + "@smithy/middleware-retry": "npm:^2.3.1" "@smithy/middleware-serde": "npm:^2.3.0" "@smithy/middleware-stack": "npm:^2.2.0" "@smithy/node-config-provider": "npm:^2.3.0" "@smithy/node-http-handler": "npm:^2.5.0" "@smithy/protocol-http": "npm:^3.3.0" - "@smithy/smithy-client": "npm:^2.5.0" + "@smithy/smithy-client": "npm:^2.5.1" "@smithy/types": "npm:^2.12.0" "@smithy/url-parser": "npm:^2.2.0" "@smithy/util-base64": "npm:^2.3.0" "@smithy/util-body-length-browser": "npm:^2.2.0" "@smithy/util-body-length-node": "npm:^2.3.0" - "@smithy/util-defaults-mode-browser": "npm:^2.2.0" - "@smithy/util-defaults-mode-node": "npm:^2.3.0" + "@smithy/util-defaults-mode-browser": "npm:^2.2.1" + "@smithy/util-defaults-mode-node": "npm:^2.3.1" "@smithy/util-endpoints": "npm:^1.2.0" "@smithy/util-middleware": "npm:^2.2.0" "@smithy/util-retry": "npm:^2.2.0" "@smithy/util-utf8": "npm:^2.3.0" tslib: "npm:^2.6.2" - checksum: 10/8e2a021624c102ab5a35216ecf1e42dc9d0b7bfb1213477783f64bcc227dcc6cc2363359678b702549d44332f3d2d71173374bd7bf56ea0093aa351a9cba2a90 + checksum: 10/211cd5a6e53dcfdaebbe65e934d72c57ed1db2a6bc361f68b98e8ba57803e5a881e36cb1a563dcfcaf61c553aa031309b033105ed8e05bf2a2997e4af002031c languageName: node linkType: hard @@ -821,13 +868,13 @@ __metadata: languageName: node linkType: hard -"@aws-sdk/client-sts@npm:3.540.0": - version: 3.540.0 - resolution: "@aws-sdk/client-sts@npm:3.540.0" +"@aws-sdk/client-sts@npm:3.552.0": + version: 3.552.0 + resolution: "@aws-sdk/client-sts@npm:3.552.0" dependencies: "@aws-crypto/sha256-browser": "npm:3.0.0" "@aws-crypto/sha256-js": "npm:3.0.0" - "@aws-sdk/core": "npm:3.535.0" + "@aws-sdk/core": "npm:3.552.0" "@aws-sdk/middleware-host-header": "npm:3.535.0" "@aws-sdk/middleware-logger": "npm:3.535.0" "@aws-sdk/middleware-recursion-detection": "npm:3.535.0" @@ -838,34 +885,34 @@ __metadata: "@aws-sdk/util-user-agent-browser": "npm:3.535.0" "@aws-sdk/util-user-agent-node": "npm:3.535.0" "@smithy/config-resolver": "npm:^2.2.0" - "@smithy/core": "npm:^1.4.0" + "@smithy/core": "npm:^1.4.2" "@smithy/fetch-http-handler": "npm:^2.5.0" "@smithy/hash-node": "npm:^2.2.0" "@smithy/invalid-dependency": "npm:^2.2.0" "@smithy/middleware-content-length": "npm:^2.2.0" - "@smithy/middleware-endpoint": "npm:^2.5.0" - "@smithy/middleware-retry": "npm:^2.2.0" + "@smithy/middleware-endpoint": "npm:^2.5.1" + "@smithy/middleware-retry": "npm:^2.3.1" "@smithy/middleware-serde": "npm:^2.3.0" "@smithy/middleware-stack": "npm:^2.2.0" "@smithy/node-config-provider": "npm:^2.3.0" "@smithy/node-http-handler": "npm:^2.5.0" "@smithy/protocol-http": "npm:^3.3.0" - "@smithy/smithy-client": "npm:^2.5.0" + "@smithy/smithy-client": "npm:^2.5.1" "@smithy/types": "npm:^2.12.0" "@smithy/url-parser": "npm:^2.2.0" "@smithy/util-base64": "npm:^2.3.0" "@smithy/util-body-length-browser": "npm:^2.2.0" "@smithy/util-body-length-node": "npm:^2.3.0" - "@smithy/util-defaults-mode-browser": "npm:^2.2.0" - "@smithy/util-defaults-mode-node": "npm:^2.3.0" + "@smithy/util-defaults-mode-browser": "npm:^2.2.1" + "@smithy/util-defaults-mode-node": "npm:^2.3.1" "@smithy/util-endpoints": "npm:^1.2.0" "@smithy/util-middleware": "npm:^2.2.0" "@smithy/util-retry": "npm:^2.2.0" "@smithy/util-utf8": "npm:^2.3.0" tslib: "npm:^2.6.2" peerDependencies: - "@aws-sdk/credential-provider-node": ^3.540.0 - checksum: 10/1344fe3d8ecd0e399859b50034d7b3400ab7f67b3734180bd6ecdef464a1069cdd1135dfc39864fd97033be8c3c9551f28b65e07d658307963836d3f548b4e69 + "@aws-sdk/credential-provider-node": ^3.552.0 + checksum: 10/8d73fb359e6ae2b54468a68d4ac76975622065367b7f0eb1a9cd051d8b6ffb9be5699de70861ae8214256fccd20baf7c2e2ec215d2b5e441ff7aeec9d1711436 languageName: node linkType: hard @@ -883,18 +930,18 @@ __metadata: languageName: node linkType: hard -"@aws-sdk/core@npm:3.535.0": - version: 3.535.0 - resolution: "@aws-sdk/core@npm:3.535.0" +"@aws-sdk/core@npm:3.552.0": + version: 3.552.0 + resolution: "@aws-sdk/core@npm:3.552.0" dependencies: - "@smithy/core": "npm:^1.4.0" + "@smithy/core": "npm:^1.4.2" "@smithy/protocol-http": "npm:^3.3.0" - "@smithy/signature-v4": "npm:^2.2.0" - "@smithy/smithy-client": "npm:^2.5.0" + "@smithy/signature-v4": "npm:^2.2.1" + "@smithy/smithy-client": "npm:^2.5.1" "@smithy/types": "npm:^2.12.0" fast-xml-parser: "npm:4.2.5" tslib: "npm:^2.6.2" - checksum: 10/f80dd5f6293dbfa11fdfdaed6dc56142c86eaf074231be990ce127ebd9fd92e2b574d751d5b15c397b885ad60ef0550b5d80bc516979d0b0289605c9eacdfdb0 + checksum: 10/a2514db32a4b70a003c27c30b3679ff3cd5c7edcc877d0a7fc12305c9635a363c2101c098fafd48b0af3dfe86b675d96ecef9e760dd76138604f2db455ba7cbe languageName: node linkType: hard @@ -939,20 +986,20 @@ __metadata: languageName: node linkType: hard -"@aws-sdk/credential-provider-http@npm:3.535.0": - version: 3.535.0 - resolution: "@aws-sdk/credential-provider-http@npm:3.535.0" +"@aws-sdk/credential-provider-http@npm:3.552.0": + version: 3.552.0 + resolution: "@aws-sdk/credential-provider-http@npm:3.552.0" dependencies: "@aws-sdk/types": "npm:3.535.0" "@smithy/fetch-http-handler": "npm:^2.5.0" "@smithy/node-http-handler": "npm:^2.5.0" "@smithy/property-provider": "npm:^2.2.0" "@smithy/protocol-http": "npm:^3.3.0" - "@smithy/smithy-client": "npm:^2.5.0" + "@smithy/smithy-client": "npm:^2.5.1" "@smithy/types": "npm:^2.12.0" "@smithy/util-stream": "npm:^2.2.0" tslib: "npm:^2.6.2" - checksum: 10/989d97be76e7c93801c216e18974741df14d66c5a1069bc01d80b26a73bae714a4070d1469db8a00db51d8914167e2c8d17eee565fb9fba29527895b0b165e85 + checksum: 10/b3d8437ee218fff92817f07205eafd764ed0768799a84bfe826e73966b57f4f90f6459fe3a14e20423c5b83d37f5d5e6c4abac87e8a6558b7042fd504656a931 languageName: node linkType: hard @@ -975,22 +1022,22 @@ __metadata: languageName: node linkType: hard -"@aws-sdk/credential-provider-ini@npm:3.540.0": - version: 3.540.0 - resolution: "@aws-sdk/credential-provider-ini@npm:3.540.0" +"@aws-sdk/credential-provider-ini@npm:3.552.0": + version: 3.552.0 + resolution: "@aws-sdk/credential-provider-ini@npm:3.552.0" dependencies: - "@aws-sdk/client-sts": "npm:3.540.0" + "@aws-sdk/client-sts": "npm:3.552.0" "@aws-sdk/credential-provider-env": "npm:3.535.0" "@aws-sdk/credential-provider-process": "npm:3.535.0" - "@aws-sdk/credential-provider-sso": "npm:3.540.0" - "@aws-sdk/credential-provider-web-identity": "npm:3.540.0" + "@aws-sdk/credential-provider-sso": "npm:3.552.0" + "@aws-sdk/credential-provider-web-identity": "npm:3.552.0" "@aws-sdk/types": "npm:3.535.0" "@smithy/credential-provider-imds": "npm:^2.3.0" "@smithy/property-provider": "npm:^2.2.0" "@smithy/shared-ini-file-loader": "npm:^2.4.0" "@smithy/types": "npm:^2.12.0" tslib: "npm:^2.6.2" - checksum: 10/71d6a3eda7ec07e2c516e149f75f33d35217c8ea54cf705fde06173d35fd118f2c1569e56ddd89f229049ef8edcfec26cbebbd51d84c0781f131df1537bab222 + checksum: 10/f30a64fbef4769e8a988aa22c21bb57ab4da8068dd5dd205222aeab01fb73ab967cd9a47e380e50ea05f9cb6d10298b5fb8ffbf7b99facdf125230cb82e69044 languageName: node linkType: hard @@ -1014,23 +1061,23 @@ __metadata: languageName: node linkType: hard -"@aws-sdk/credential-provider-node@npm:3.540.0": - version: 3.540.0 - resolution: "@aws-sdk/credential-provider-node@npm:3.540.0" +"@aws-sdk/credential-provider-node@npm:3.552.0": + version: 3.552.0 + resolution: "@aws-sdk/credential-provider-node@npm:3.552.0" dependencies: "@aws-sdk/credential-provider-env": "npm:3.535.0" - "@aws-sdk/credential-provider-http": "npm:3.535.0" - "@aws-sdk/credential-provider-ini": "npm:3.540.0" + "@aws-sdk/credential-provider-http": "npm:3.552.0" + "@aws-sdk/credential-provider-ini": "npm:3.552.0" "@aws-sdk/credential-provider-process": "npm:3.535.0" - "@aws-sdk/credential-provider-sso": "npm:3.540.0" - "@aws-sdk/credential-provider-web-identity": "npm:3.540.0" + "@aws-sdk/credential-provider-sso": "npm:3.552.0" + "@aws-sdk/credential-provider-web-identity": "npm:3.552.0" "@aws-sdk/types": "npm:3.535.0" "@smithy/credential-provider-imds": "npm:^2.3.0" "@smithy/property-provider": "npm:^2.2.0" "@smithy/shared-ini-file-loader": "npm:^2.4.0" "@smithy/types": "npm:^2.12.0" tslib: "npm:^2.6.2" - checksum: 10/78fde961d1b0b9b5e19b7a8e3ccae2daf35c3cb1dd4fee58e8960e7f7d97a0f42a470caab5c62aa5568f1b2d39171992164f22eb32e5cc231db34a9be4743bc9 + checksum: 10/b3f8b6d647e2bc8e0ef80283abbda968f28d583412ba78cf8875731aa92da44129459962b2332b9a64cd9d5ddc06218b9aa1f8f474b2cc41cf56b122a6171531 languageName: node linkType: hard @@ -1075,18 +1122,18 @@ __metadata: languageName: node linkType: hard -"@aws-sdk/credential-provider-sso@npm:3.540.0": - version: 3.540.0 - resolution: "@aws-sdk/credential-provider-sso@npm:3.540.0" +"@aws-sdk/credential-provider-sso@npm:3.552.0": + version: 3.552.0 + resolution: "@aws-sdk/credential-provider-sso@npm:3.552.0" dependencies: - "@aws-sdk/client-sso": "npm:3.540.0" - "@aws-sdk/token-providers": "npm:3.540.0" + "@aws-sdk/client-sso": "npm:3.552.0" + "@aws-sdk/token-providers": "npm:3.552.0" "@aws-sdk/types": "npm:3.535.0" "@smithy/property-provider": "npm:^2.2.0" "@smithy/shared-ini-file-loader": "npm:^2.4.0" "@smithy/types": "npm:^2.12.0" tslib: "npm:^2.6.2" - checksum: 10/9aa974a56a2effb2254df63bc5ec08595d6ca9bd5d724d8fc463e798131bfab0c15a47c32f2b359765ef44241dd737ebd09202a09690214f6e52060eba2f0dcd + checksum: 10/ed2a062015e767736b9e11a8156f2a810da65aa33da31e21326c06d0cca052ed618f2fe9fc737b641efe339dd5a89f4ab1b6355831b27f9df83f0184bec48504 languageName: node linkType: hard @@ -1103,33 +1150,33 @@ __metadata: languageName: node linkType: hard -"@aws-sdk/credential-provider-web-identity@npm:3.540.0": - version: 3.540.0 - resolution: "@aws-sdk/credential-provider-web-identity@npm:3.540.0" +"@aws-sdk/credential-provider-web-identity@npm:3.552.0": + version: 3.552.0 + resolution: "@aws-sdk/credential-provider-web-identity@npm:3.552.0" dependencies: - "@aws-sdk/client-sts": "npm:3.540.0" + "@aws-sdk/client-sts": "npm:3.552.0" "@aws-sdk/types": "npm:3.535.0" "@smithy/property-provider": "npm:^2.2.0" "@smithy/types": "npm:^2.12.0" tslib: "npm:^2.6.2" - checksum: 10/889dac368f27fde4a47428dd9ba23ba8352bb01a6c9674b36b3972feef5acc68ff5ba37b8932413bff34c7ed128d1a840369e663ac0291eb8ebd8a6fe48e5ce0 + checksum: 10/333e5f57c4a0b1e42b2e6b85896a75b0475b56350279d13b57c63d7972582349d4005a395efa61525c6d71cfd4c839ce3ff2108565f02b5f8840c04f934cf622 languageName: node linkType: hard "@aws-sdk/lib-storage@npm:^3.46.0": - version: 3.540.0 - resolution: "@aws-sdk/lib-storage@npm:3.540.0" + version: 3.552.0 + resolution: "@aws-sdk/lib-storage@npm:3.552.0" dependencies: "@smithy/abort-controller": "npm:^2.2.0" - "@smithy/middleware-endpoint": "npm:^2.5.0" - "@smithy/smithy-client": "npm:^2.5.0" + "@smithy/middleware-endpoint": "npm:^2.5.1" + "@smithy/smithy-client": "npm:^2.5.1" buffer: "npm:5.6.0" events: "npm:3.3.0" stream-browserify: "npm:3.0.0" tslib: "npm:^2.6.2" peerDependencies: "@aws-sdk/client-s3": ^3.0.0 - checksum: 10/8f1a12c083ac322e76be1c3805e335207cfd85f92bc006c6c620fc66c0df26876cb3ba11284bfe6675439e5093568c38ba186e70e29f83b3036403601a947505 + checksum: 10/cf2e33f2bfd888f04f05259f52daab8c7ce26aac24b8f2d10bd800b71a814a9a8469b56f4bd37e656248f47a215d22ad23970db5ded86a9a6e3195a2e9a07798 languageName: node linkType: hard @@ -1328,20 +1375,20 @@ __metadata: languageName: node linkType: hard -"@aws-sdk/middleware-sdk-s3@npm:3.535.0": - version: 3.535.0 - resolution: "@aws-sdk/middleware-sdk-s3@npm:3.535.0" +"@aws-sdk/middleware-sdk-s3@npm:3.552.0": + version: 3.552.0 + resolution: "@aws-sdk/middleware-sdk-s3@npm:3.552.0" dependencies: "@aws-sdk/types": "npm:3.535.0" "@aws-sdk/util-arn-parser": "npm:3.535.0" "@smithy/node-config-provider": "npm:^2.3.0" "@smithy/protocol-http": "npm:^3.3.0" - "@smithy/signature-v4": "npm:^2.2.0" - "@smithy/smithy-client": "npm:^2.5.0" + "@smithy/signature-v4": "npm:^2.2.1" + "@smithy/smithy-client": "npm:^2.5.1" "@smithy/types": "npm:^2.12.0" "@smithy/util-config-provider": "npm:^2.3.0" tslib: "npm:^2.6.2" - checksum: 10/effcd878a305953128dd5e12babbc94181a4a442845164abfc3b84b2ca986330a76c7641f372bd8f872d6b855616d59a2bbfa4105c87258de4c5a5cf01a7eedc + checksum: 10/32bbb89e76b14ed6a73177ed2e0484c58dee6d2bd6f8085b4b1326a66aabae3c01e69a1c52318745b980e4150c84f0baff8dc64697d419e7179f5e19e5abfba7 languageName: node linkType: hard @@ -1360,18 +1407,18 @@ __metadata: languageName: node linkType: hard -"@aws-sdk/middleware-signing@npm:3.535.0": - version: 3.535.0 - resolution: "@aws-sdk/middleware-signing@npm:3.535.0" +"@aws-sdk/middleware-signing@npm:3.552.0": + version: 3.552.0 + resolution: "@aws-sdk/middleware-signing@npm:3.552.0" dependencies: "@aws-sdk/types": "npm:3.535.0" "@smithy/property-provider": "npm:^2.2.0" "@smithy/protocol-http": "npm:^3.3.0" - "@smithy/signature-v4": "npm:^2.2.0" + "@smithy/signature-v4": "npm:^2.2.1" "@smithy/types": "npm:^2.12.0" "@smithy/util-middleware": "npm:^2.2.0" tslib: "npm:^2.6.2" - checksum: 10/c61a230082f37f444d6041d045913e7b72d676a801b4908493ed0cca4e19bf0cdfd568d71929e49cc6173882f5fcf0a730e20e954435c62f4154af1a7fa4f524 + checksum: 10/406e24c943645641fe7bae469f1df3d96e914a61780162d55a1d7ef1ceed5aa0c5364f7afa7836a64236c7ee859e95290ae1a16b5a5bf949ff5123427d44b41c languageName: node linkType: hard @@ -1465,17 +1512,17 @@ __metadata: languageName: node linkType: hard -"@aws-sdk/signature-v4-multi-region@npm:3.535.0": - version: 3.535.0 - resolution: "@aws-sdk/signature-v4-multi-region@npm:3.535.0" +"@aws-sdk/signature-v4-multi-region@npm:3.552.0": + version: 3.552.0 + resolution: "@aws-sdk/signature-v4-multi-region@npm:3.552.0" dependencies: - "@aws-sdk/middleware-sdk-s3": "npm:3.535.0" + "@aws-sdk/middleware-sdk-s3": "npm:3.552.0" "@aws-sdk/types": "npm:3.535.0" "@smithy/protocol-http": "npm:^3.3.0" - "@smithy/signature-v4": "npm:^2.2.0" + "@smithy/signature-v4": "npm:^2.2.1" "@smithy/types": "npm:^2.12.0" tslib: "npm:^2.6.2" - checksum: 10/b2302cd39e45feecb921bcd7fdda619b3e23fdf0175cfd23d75db6157f524401b210dec719e901332b6846eeb5c26f12d0d4822498b23908b8ee157ee13df6f7 + checksum: 10/0720854f7d1b344b8a8949b8db08cabe101917de31dca629f2fbddc4feb3c895e49db60bbaf6ed902436a3d4d0624269d139cdfadf79fc94b8ca62417e0ebdce languageName: node linkType: hard @@ -1493,17 +1540,17 @@ __metadata: languageName: node linkType: hard -"@aws-sdk/token-providers@npm:3.540.0": - version: 3.540.0 - resolution: "@aws-sdk/token-providers@npm:3.540.0" +"@aws-sdk/token-providers@npm:3.552.0": + version: 3.552.0 + resolution: "@aws-sdk/token-providers@npm:3.552.0" dependencies: - "@aws-sdk/client-sso-oidc": "npm:3.540.0" + "@aws-sdk/client-sso-oidc": "npm:3.552.0" "@aws-sdk/types": "npm:3.535.0" "@smithy/property-provider": "npm:^2.2.0" "@smithy/shared-ini-file-loader": "npm:^2.4.0" "@smithy/types": "npm:^2.12.0" tslib: "npm:^2.6.2" - checksum: 10/137e43d2257ac87302033bf59731a7c5d21f1fab047c673d90f1adb036cde889debe159f2a59aec70c9daefe0d76528eae51d821f178c0de20b1e328efc25c14 + checksum: 10/e64585fad8eab5c25bb29024900ea6040b1a98fddcc2e75d9df62ef8964051ed12e618115ba868bce3d1a186ecfdded9f6ed5c96f4df7234e274ccad7063c741 languageName: node linkType: hard @@ -4193,6 +4240,26 @@ __metadata: languageName: node linkType: hard +"@cookbookdev/docsbot@npm:4.5.0": + version: 4.5.0 + resolution: "@cookbookdev/docsbot@npm:4.5.0" + dependencies: + "@headlessui/react": "npm:^1.7.18" + clsx: "npm:^2.1.0" + idb: "npm:^8.0.0" + nanoid: "npm:^5.0.5" + prop-types: "npm:^15.8.1" + react-markdown: "npm:^9.0.1" + react-syntax-highlighter: "npm:^15.5.0" + remark-gfm: "npm:^4.0.0" + swr: "npm:^2.2.5" + peerDependencies: + react: ^16.8 || ^17.0 || ^18.0 + react-dom: ^16.8 || ^17.0 || ^18.0 + checksum: 10/4064c429aef00972a6522864494414b74ba9b58e66526de97f3ff169c815ff7e2ffb7d1379cb28447f064b28af2c62a6be65cc87968043299ea1d0e18f57cf3f + languageName: node + linkType: hard + "@crossmint/client-sdk-base@npm:1.1.8": version: 1.1.8 resolution: "@crossmint/client-sdk-base@npm:1.1.8" @@ -4302,91 +4369,9 @@ __metadata: languageName: node linkType: hard -"@docusaurus/core@npm:3.1.1": - version: 3.1.1 - resolution: "@docusaurus/core@npm:3.1.1" - dependencies: - "@babel/core": "npm:^7.23.3" - "@babel/generator": "npm:^7.23.3" - "@babel/plugin-syntax-dynamic-import": "npm:^7.8.3" - "@babel/plugin-transform-runtime": "npm:^7.22.9" - "@babel/preset-env": "npm:^7.22.9" - "@babel/preset-react": "npm:^7.22.5" - "@babel/preset-typescript": "npm:^7.22.5" - "@babel/runtime": "npm:^7.22.6" - "@babel/runtime-corejs3": "npm:^7.22.6" - "@babel/traverse": "npm:^7.22.8" - "@docusaurus/cssnano-preset": "npm:3.1.1" - "@docusaurus/logger": "npm:3.1.1" - "@docusaurus/mdx-loader": "npm:3.1.1" - "@docusaurus/react-loadable": "npm:5.5.2" - "@docusaurus/utils": "npm:3.1.1" - "@docusaurus/utils-common": "npm:3.1.1" - "@docusaurus/utils-validation": "npm:3.1.1" - "@slorber/static-site-generator-webpack-plugin": "npm:^4.0.7" - "@svgr/webpack": "npm:^6.5.1" - autoprefixer: "npm:^10.4.14" - babel-loader: "npm:^9.1.3" - babel-plugin-dynamic-import-node: "npm:^2.3.3" - boxen: "npm:^6.2.1" - chalk: "npm:^4.1.2" - chokidar: "npm:^3.5.3" - clean-css: "npm:^5.3.2" - cli-table3: "npm:^0.6.3" - combine-promises: "npm:^1.1.0" - commander: "npm:^5.1.0" - copy-webpack-plugin: "npm:^11.0.0" - core-js: "npm:^3.31.1" - css-loader: "npm:^6.8.1" - css-minimizer-webpack-plugin: "npm:^4.2.2" - cssnano: "npm:^5.1.15" - del: "npm:^6.1.1" - detect-port: "npm:^1.5.1" - escape-html: "npm:^1.0.3" - eta: "npm:^2.2.0" - file-loader: "npm:^6.2.0" - fs-extra: "npm:^11.1.1" - html-minifier-terser: "npm:^7.2.0" - html-tags: "npm:^3.3.1" - html-webpack-plugin: "npm:^5.5.3" - leven: "npm:^3.1.0" - lodash: "npm:^4.17.21" - mini-css-extract-plugin: "npm:^2.7.6" - postcss: "npm:^8.4.26" - postcss-loader: "npm:^7.3.3" - prompts: "npm:^2.4.2" - react-dev-utils: "npm:^12.0.1" - react-helmet-async: "npm:^1.3.0" - react-loadable: "npm:@docusaurus/react-loadable@5.5.2" - react-loadable-ssr-addon-v5-slorber: "npm:^1.0.1" - react-router: "npm:^5.3.4" - react-router-config: "npm:^5.1.1" - react-router-dom: "npm:^5.3.4" - rtl-detect: "npm:^1.0.4" - semver: "npm:^7.5.4" - serve-handler: "npm:^6.1.5" - shelljs: "npm:^0.8.5" - terser-webpack-plugin: "npm:^5.3.9" - tslib: "npm:^2.6.0" - update-notifier: "npm:^6.0.2" - url-loader: "npm:^4.1.1" - webpack: "npm:^5.88.1" - webpack-bundle-analyzer: "npm:^4.9.0" - webpack-dev-server: "npm:^4.15.1" - webpack-merge: "npm:^5.9.0" - webpackbar: "npm:^5.0.2" - peerDependencies: - react: ^18.0.0 - react-dom: ^18.0.0 - bin: - docusaurus: bin/docusaurus.mjs - checksum: 10/ff0a573d70ebafa34433cb358803dc73d70ac01cf9edbab35a81ae15232a229d31b428d1b5a286975d8e8aec04ea5debdb6528a3aa632ac766a75b6ed21ce319 - languageName: node - linkType: hard - -"@docusaurus/core@npm:3.2.0": - version: 3.2.0 - resolution: "@docusaurus/core@npm:3.2.0" +"@docusaurus/core@npm:3.2.1": + version: 3.2.1 + resolution: "@docusaurus/core@npm:3.2.1" dependencies: "@babel/core": "npm:^7.23.3" "@babel/generator": "npm:^7.23.3" @@ -4398,13 +4383,13 @@ __metadata: "@babel/runtime": "npm:^7.22.6" "@babel/runtime-corejs3": "npm:^7.22.6" "@babel/traverse": "npm:^7.22.8" - "@docusaurus/cssnano-preset": "npm:3.2.0" - "@docusaurus/logger": "npm:3.2.0" - "@docusaurus/mdx-loader": "npm:3.2.0" + "@docusaurus/cssnano-preset": "npm:3.2.1" + "@docusaurus/logger": "npm:3.2.1" + "@docusaurus/mdx-loader": "npm:3.2.1" "@docusaurus/react-loadable": "npm:5.5.2" - "@docusaurus/utils": "npm:3.2.0" - "@docusaurus/utils-common": "npm:3.2.0" - "@docusaurus/utils-validation": "npm:3.2.0" + "@docusaurus/utils": "npm:3.2.1" + "@docusaurus/utils-common": "npm:3.2.1" + "@docusaurus/utils-validation": "npm:3.2.1" "@svgr/webpack": "npm:^6.5.1" autoprefixer: "npm:^10.4.14" babel-loader: "npm:^9.1.3" @@ -4463,98 +4448,39 @@ __metadata: react-dom: ^18.0.0 bin: docusaurus: bin/docusaurus.mjs - checksum: 10/e56de94b1af2e3f9cc1344cf51ac85ee31e4fbe1f170ae8b3615b2fcdc37c4a0c8aedee9f8722dedfafc2c6b279e7ae428146a991674a28fb11cecdebc7dc2a4 - languageName: node - linkType: hard - -"@docusaurus/cssnano-preset@npm:3.1.1": - version: 3.1.1 - resolution: "@docusaurus/cssnano-preset@npm:3.1.1" - dependencies: - cssnano-preset-advanced: "npm:^5.3.10" - postcss: "npm:^8.4.26" - postcss-sort-media-queries: "npm:^4.4.1" - tslib: "npm:^2.6.0" - checksum: 10/562d96c2ff60826459c255831cd57b12393e6f41b3827c499d43d00ec1887fbeebfea7c68aa72d9e56a5d64419847d11a5d66021acb4f1e3ce4c87b781f33954 + checksum: 10/94bf57cc35eeefff667d2d2116f3ece9d6869680a204842d9612f76debe7ab349c6ea833338b1003c5ba7b9aad3d577b8e141f3cd4d7a4680614bcc1cdbbca9a languageName: node linkType: hard -"@docusaurus/cssnano-preset@npm:3.2.0": - version: 3.2.0 - resolution: "@docusaurus/cssnano-preset@npm:3.2.0" +"@docusaurus/cssnano-preset@npm:3.2.1": + version: 3.2.1 + resolution: "@docusaurus/cssnano-preset@npm:3.2.1" dependencies: cssnano-preset-advanced: "npm:^5.3.10" postcss: "npm:^8.4.26" postcss-sort-media-queries: "npm:^4.4.1" tslib: "npm:^2.6.0" - checksum: 10/59c7571f6c9d8b2e1c3df85f599da6bfd8f08f6b4fd974da8057cb6a6b38e6df46b1635f54a7566c365f346deff703796a2191df214a6b7025fc264db2cc1a2f - languageName: node - linkType: hard - -"@docusaurus/logger@npm:3.1.1": - version: 3.1.1 - resolution: "@docusaurus/logger@npm:3.1.1" - dependencies: - chalk: "npm:^4.1.2" - tslib: "npm:^2.6.0" - checksum: 10/6fb275e7be4acc1088738a9ea5d554936f7c2b7f99c8c63333b37f7004d640156a86faaeeb72552a1a19f3981fd64fe177f7f46cb3e874146832faa14dd8c095 + checksum: 10/ee23a1229d23732d936fe1d68732d1305abf0132b43a398336fee500504a3e7566d3b0c6222f89f565e24e68e00e353765e0cbbab5611a3b35ecf88305558b6d languageName: node linkType: hard -"@docusaurus/logger@npm:3.2.0": - version: 3.2.0 - resolution: "@docusaurus/logger@npm:3.2.0" +"@docusaurus/logger@npm:3.2.1": + version: 3.2.1 + resolution: "@docusaurus/logger@npm:3.2.1" dependencies: chalk: "npm:^4.1.2" tslib: "npm:^2.6.0" - checksum: 10/0f4e2a203ea29e2dfb85a4d0c1925adec260b0094f2682a1a20b8a6e3143a1a44b478370a9554ed16f9882d0faca44d250c271afdbe4872fd9619e3e00da6d75 + checksum: 10/410dcd3ed9bdad976e2f2b54aa72293e9bf229710efbf14db4db8aa98c58e8062f97398e4a1b94bb2f6edaebf204de13fe6294a3573b14309d88cdb02497f387 languageName: node linkType: hard -"@docusaurus/mdx-loader@npm:3.1.1": - version: 3.1.1 - resolution: "@docusaurus/mdx-loader@npm:3.1.1" - dependencies: - "@babel/parser": "npm:^7.22.7" - "@babel/traverse": "npm:^7.22.8" - "@docusaurus/logger": "npm:3.1.1" - "@docusaurus/utils": "npm:3.1.1" - "@docusaurus/utils-validation": "npm:3.1.1" - "@mdx-js/mdx": "npm:^3.0.0" - "@slorber/remark-comment": "npm:^1.0.0" - escape-html: "npm:^1.0.3" - estree-util-value-to-estree: "npm:^3.0.1" - file-loader: "npm:^6.2.0" - fs-extra: "npm:^11.1.1" - image-size: "npm:^1.0.2" - mdast-util-mdx: "npm:^3.0.0" - mdast-util-to-string: "npm:^4.0.0" - rehype-raw: "npm:^7.0.0" - remark-directive: "npm:^3.0.0" - remark-emoji: "npm:^4.0.0" - remark-frontmatter: "npm:^5.0.0" - remark-gfm: "npm:^4.0.0" - stringify-object: "npm:^3.3.0" - tslib: "npm:^2.6.0" - unified: "npm:^11.0.3" - unist-util-visit: "npm:^5.0.0" - url-loader: "npm:^4.1.1" - vfile: "npm:^6.0.1" - webpack: "npm:^5.88.1" - peerDependencies: - react: ^18.0.0 - react-dom: ^18.0.0 - checksum: 10/78a4591a3851df4ae8606f9a923ff19f6162a391838b362cce217c7c0357fb5dafd274ec442ef4097e5ae06d1814319e575eca8e20b39d44196522edf057d5b5 - languageName: node - linkType: hard - -"@docusaurus/mdx-loader@npm:3.2.0, @docusaurus/mdx-loader@npm:^3.2.0": - version: 3.2.0 - resolution: "@docusaurus/mdx-loader@npm:3.2.0" +"@docusaurus/mdx-loader@npm:3.2.1, @docusaurus/mdx-loader@npm:^3.2.0": + version: 3.2.1 + resolution: "@docusaurus/mdx-loader@npm:3.2.1" dependencies: - "@docusaurus/logger": "npm:3.2.0" - "@docusaurus/utils": "npm:3.2.0" - "@docusaurus/utils-validation": "npm:3.2.0" + "@docusaurus/logger": "npm:3.2.1" + "@docusaurus/utils": "npm:3.2.1" + "@docusaurus/utils-validation": "npm:3.2.1" "@mdx-js/mdx": "npm:^3.0.0" "@slorber/remark-comment": "npm:^1.0.0" escape-html: "npm:^1.0.3" @@ -4579,35 +4505,16 @@ __metadata: peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 10/248094f19f171d607aed373156abae93172ae16e4e460d652f59031c5e12127bb8b8b54a982617dda3cfc75e509355b33d41032549732a9133f58a03368db172 - languageName: node - linkType: hard - -"@docusaurus/module-type-aliases@npm:3.1.1": - version: 3.1.1 - resolution: "@docusaurus/module-type-aliases@npm:3.1.1" - dependencies: - "@docusaurus/react-loadable": "npm:5.5.2" - "@docusaurus/types": "npm:3.1.1" - "@types/history": "npm:^4.7.11" - "@types/react": "npm:*" - "@types/react-router-config": "npm:*" - "@types/react-router-dom": "npm:*" - react-helmet-async: "npm:*" - react-loadable: "npm:@docusaurus/react-loadable@5.5.2" - peerDependencies: - react: "*" - react-dom: "*" - checksum: 10/1a52051d4bd166f5e7a8b7ba02439565fcffacdabd9e42ac268c064c9ac24d1b39dea8028a3e40c61ec0d423cfd69441dc647c434ef1bc932372915ebea45a3c + checksum: 10/53946a4c697f8cac3a975022e90ada3dc50a7b5782fd731f93c3508359ef339c1438b799c5926db8331debd942b7adb85a5303bf0a3d756c772cfa285ffa2154 languageName: node linkType: hard -"@docusaurus/module-type-aliases@npm:3.2.0": - version: 3.2.0 - resolution: "@docusaurus/module-type-aliases@npm:3.2.0" +"@docusaurus/module-type-aliases@npm:3.2.1": + version: 3.2.1 + resolution: "@docusaurus/module-type-aliases@npm:3.2.1" dependencies: "@docusaurus/react-loadable": "npm:5.5.2" - "@docusaurus/types": "npm:3.2.0" + "@docusaurus/types": "npm:3.2.1" "@types/history": "npm:^4.7.11" "@types/react": "npm:*" "@types/react-router-config": "npm:*" @@ -4617,19 +4524,19 @@ __metadata: peerDependencies: react: "*" react-dom: "*" - checksum: 10/e6dbba8cd7c6232c3efa0c838423c5f1ddf46107fac4179984c4ec1e8ac2978d2558fb905b26cc0a854154edaeb9c8dec680a430fdc9987d87b223b442f10cce + checksum: 10/ded330c5ef7ed2a4864fe67bc279920cf28eb236adb95b9f950059e72663d8d3387003c4d80fa4f7374d26a5268aa6e17ca4a0237c6f77c34385238cc4541e25 languageName: node linkType: hard -"@docusaurus/plugin-client-redirects@npm:3.1.1": - version: 3.1.1 - resolution: "@docusaurus/plugin-client-redirects@npm:3.1.1" +"@docusaurus/plugin-client-redirects@npm:3.2.1": + version: 3.2.1 + resolution: "@docusaurus/plugin-client-redirects@npm:3.2.1" dependencies: - "@docusaurus/core": "npm:3.1.1" - "@docusaurus/logger": "npm:3.1.1" - "@docusaurus/utils": "npm:3.1.1" - "@docusaurus/utils-common": "npm:3.1.1" - "@docusaurus/utils-validation": "npm:3.1.1" + "@docusaurus/core": "npm:3.2.1" + "@docusaurus/logger": "npm:3.2.1" + "@docusaurus/utils": "npm:3.2.1" + "@docusaurus/utils-common": "npm:3.2.1" + "@docusaurus/utils-validation": "npm:3.2.1" eta: "npm:^2.2.0" fs-extra: "npm:^11.1.1" lodash: "npm:^4.17.21" @@ -4637,21 +4544,21 @@ __metadata: peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 10/8e489029499f7a6c218fc1a57d670f918eca5c01c5f3735ecc86329a0dd96b8c7c9ace0671fa63ecbb1f706f95e3edbbc3bac87dc8b02af5e6f1784bdc894ebc + checksum: 10/24dac73ee7a9eb783f3954d79fed2bcbb7f50bd22d7e94c0c42aacfd8e3f2a1be1cd116e9661e97113a1f8c1c44fa4945801cf4ffd8b2b3b925723fd1110a26f languageName: node linkType: hard -"@docusaurus/plugin-content-blog@npm:3.2.0": - version: 3.2.0 - resolution: "@docusaurus/plugin-content-blog@npm:3.2.0" - dependencies: - "@docusaurus/core": "npm:3.2.0" - "@docusaurus/logger": "npm:3.2.0" - "@docusaurus/mdx-loader": "npm:3.2.0" - "@docusaurus/types": "npm:3.2.0" - "@docusaurus/utils": "npm:3.2.0" - "@docusaurus/utils-common": "npm:3.2.0" - "@docusaurus/utils-validation": "npm:3.2.0" +"@docusaurus/plugin-content-blog@npm:3.2.1": + version: 3.2.1 + resolution: "@docusaurus/plugin-content-blog@npm:3.2.1" + dependencies: + "@docusaurus/core": "npm:3.2.1" + "@docusaurus/logger": "npm:3.2.1" + "@docusaurus/mdx-loader": "npm:3.2.1" + "@docusaurus/types": "npm:3.2.1" + "@docusaurus/utils": "npm:3.2.1" + "@docusaurus/utils-common": "npm:3.2.1" + "@docusaurus/utils-validation": "npm:3.2.1" cheerio: "npm:^1.0.0-rc.12" feed: "npm:^4.2.2" fs-extra: "npm:^11.1.1" @@ -4665,48 +4572,22 @@ __metadata: peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 10/f23c9075e2ea369824beb6c3779eb862c1e3e77f05e23eb9269f127b9ece01cc278bf450a574095f858a4ef3779f8dd7c0162063827f1c875dc876f5d554a1c3 - languageName: node - linkType: hard - -"@docusaurus/plugin-content-docs@npm:3.1.1": - version: 3.1.1 - resolution: "@docusaurus/plugin-content-docs@npm:3.1.1" - dependencies: - "@docusaurus/core": "npm:3.1.1" - "@docusaurus/logger": "npm:3.1.1" - "@docusaurus/mdx-loader": "npm:3.1.1" - "@docusaurus/module-type-aliases": "npm:3.1.1" - "@docusaurus/types": "npm:3.1.1" - "@docusaurus/utils": "npm:3.1.1" - "@docusaurus/utils-validation": "npm:3.1.1" - "@types/react-router-config": "npm:^5.0.7" - combine-promises: "npm:^1.1.0" - fs-extra: "npm:^11.1.1" - js-yaml: "npm:^4.1.0" - lodash: "npm:^4.17.21" - tslib: "npm:^2.6.0" - utility-types: "npm:^3.10.0" - webpack: "npm:^5.88.1" - peerDependencies: - react: ^18.0.0 - react-dom: ^18.0.0 - checksum: 10/bbe61f78c28da007d60af867893b9330a2ab31c55e864593a2d00861cac7c2a0fa1f81e7a1cfc29ce83148ffba0169d280d5f7f943d6062d1b3f17a803f992f9 + checksum: 10/9790f1bc99f80fd8b14d9d9e5cfd7895cd30ab60631ec66da7ea8bba83ce10d98a1e29cfc438731657d90c3d2bf724bfb1fe72aa09a3c836e867c08c7772205b languageName: node linkType: hard -"@docusaurus/plugin-content-docs@npm:3.2.0, @docusaurus/plugin-content-docs@npm:^3.2.0": - version: 3.2.0 - resolution: "@docusaurus/plugin-content-docs@npm:3.2.0" - dependencies: - "@docusaurus/core": "npm:3.2.0" - "@docusaurus/logger": "npm:3.2.0" - "@docusaurus/mdx-loader": "npm:3.2.0" - "@docusaurus/module-type-aliases": "npm:3.2.0" - "@docusaurus/types": "npm:3.2.0" - "@docusaurus/utils": "npm:3.2.0" - "@docusaurus/utils-common": "npm:3.2.0" - "@docusaurus/utils-validation": "npm:3.2.0" +"@docusaurus/plugin-content-docs@npm:3.2.1, @docusaurus/plugin-content-docs@npm:^3.2.0": + version: 3.2.1 + resolution: "@docusaurus/plugin-content-docs@npm:3.2.1" + dependencies: + "@docusaurus/core": "npm:3.2.1" + "@docusaurus/logger": "npm:3.2.1" + "@docusaurus/mdx-loader": "npm:3.2.1" + "@docusaurus/module-type-aliases": "npm:3.2.1" + "@docusaurus/types": "npm:3.2.1" + "@docusaurus/utils": "npm:3.2.1" + "@docusaurus/utils-common": "npm:3.2.1" + "@docusaurus/utils-validation": "npm:3.2.1" "@types/react-router-config": "npm:^5.0.7" combine-promises: "npm:^1.1.0" fs-extra: "npm:^11.1.1" @@ -4718,133 +4599,133 @@ __metadata: peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 10/406595a147880e01759d175c30895af9c5c7bff50c4a009a3bd848d0b76bfca2e53c3aa9e778245222ba47f516649740b8e8e1b65b1a39d5a2fe7165ab8d34ce + checksum: 10/5e688343ac9a2db607fb1d94c6de048e21ad3bc9af42a86edd63384886784549e9bc78cfef5869f7ef4addedf60e6300bf4c03aa2b0d098553e334cb67a09645 languageName: node linkType: hard -"@docusaurus/plugin-content-pages@npm:3.2.0": - version: 3.2.0 - resolution: "@docusaurus/plugin-content-pages@npm:3.2.0" +"@docusaurus/plugin-content-pages@npm:3.2.1": + version: 3.2.1 + resolution: "@docusaurus/plugin-content-pages@npm:3.2.1" dependencies: - "@docusaurus/core": "npm:3.2.0" - "@docusaurus/mdx-loader": "npm:3.2.0" - "@docusaurus/types": "npm:3.2.0" - "@docusaurus/utils": "npm:3.2.0" - "@docusaurus/utils-validation": "npm:3.2.0" + "@docusaurus/core": "npm:3.2.1" + "@docusaurus/mdx-loader": "npm:3.2.1" + "@docusaurus/types": "npm:3.2.1" + "@docusaurus/utils": "npm:3.2.1" + "@docusaurus/utils-validation": "npm:3.2.1" fs-extra: "npm:^11.1.1" tslib: "npm:^2.6.0" webpack: "npm:^5.88.1" peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 10/de61a25383d3790b516548fe6230ae83eb7d2d4ba3be99e92814760c502b72fd0ffb2a85aa5b6010463423aba56148f5b46cfab93251639c93d04f76b8b73ffe + checksum: 10/568ca1e7707a3d00cef8dc9ba1ba0b0e3697b655bbd208a85473afda2dcb9b9b50714a09f750c90aa695bdf225badc42e233ca0f1eb298ac26d585a7d12edaa4 languageName: node linkType: hard -"@docusaurus/plugin-debug@npm:3.2.0": - version: 3.2.0 - resolution: "@docusaurus/plugin-debug@npm:3.2.0" +"@docusaurus/plugin-debug@npm:3.2.1": + version: 3.2.1 + resolution: "@docusaurus/plugin-debug@npm:3.2.1" dependencies: - "@docusaurus/core": "npm:3.2.0" - "@docusaurus/types": "npm:3.2.0" - "@docusaurus/utils": "npm:3.2.0" + "@docusaurus/core": "npm:3.2.1" + "@docusaurus/types": "npm:3.2.1" + "@docusaurus/utils": "npm:3.2.1" fs-extra: "npm:^11.1.1" react-json-view-lite: "npm:^1.2.0" tslib: "npm:^2.6.0" peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 10/b6d8abed32f414df655d37d2a69c2642bda97138d0bba5189fa9c8166b15d1652b3eb9f4fbb86188ee994547c0c4b277616f2ad55ff3b0f76a61cd44de133412 + checksum: 10/b3fb1c8935463afb97f233042692c247d4147c03e18ef9fb37fbf0c46d4adaefa4af0d5c357025992dadfe7b83a9fd3754946b8947bfb8b9535dca390a3668d0 languageName: node linkType: hard -"@docusaurus/plugin-google-analytics@npm:3.2.0": - version: 3.2.0 - resolution: "@docusaurus/plugin-google-analytics@npm:3.2.0" +"@docusaurus/plugin-google-analytics@npm:3.2.1": + version: 3.2.1 + resolution: "@docusaurus/plugin-google-analytics@npm:3.2.1" dependencies: - "@docusaurus/core": "npm:3.2.0" - "@docusaurus/types": "npm:3.2.0" - "@docusaurus/utils-validation": "npm:3.2.0" + "@docusaurus/core": "npm:3.2.1" + "@docusaurus/types": "npm:3.2.1" + "@docusaurus/utils-validation": "npm:3.2.1" tslib: "npm:^2.6.0" peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 10/ea16d694377d0953660e4f675350a9cf35d73444b49bd02b00dcd34951e7a01ee372d83952780b3b9f5aaa518933080a92647412c054c0c7064a03068442c9a2 + checksum: 10/e1e881fd6adbe408029257d526759b9217f7d70e5e068c7e9241a5f0c3050b0fa46acfeb4f8a23c3f36e1739d0a3d810642d69c6648ff6801ce13b646e44e6c1 languageName: node linkType: hard -"@docusaurus/plugin-google-gtag@npm:3.2.0": - version: 3.2.0 - resolution: "@docusaurus/plugin-google-gtag@npm:3.2.0" +"@docusaurus/plugin-google-gtag@npm:3.2.1": + version: 3.2.1 + resolution: "@docusaurus/plugin-google-gtag@npm:3.2.1" dependencies: - "@docusaurus/core": "npm:3.2.0" - "@docusaurus/types": "npm:3.2.0" - "@docusaurus/utils-validation": "npm:3.2.0" + "@docusaurus/core": "npm:3.2.1" + "@docusaurus/types": "npm:3.2.1" + "@docusaurus/utils-validation": "npm:3.2.1" "@types/gtag.js": "npm:^0.0.12" tslib: "npm:^2.6.0" peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 10/87316ebdebda34f9173d241f5e56062c5bf912cdb94d932d28b9ecc69016e2b115063a9021c028d726df0a95bd8b261779fc631a31d7b0208c920a8ce4415866 + checksum: 10/b7758289d8453e98baf95d41e754c1e4c8fd5b1c000ba444c4bdf13fc97674a3cddf3215b6406266729e23898641b5bae297c5422c5bd079ef04773fa5a15c1b languageName: node linkType: hard -"@docusaurus/plugin-google-tag-manager@npm:3.2.0": - version: 3.2.0 - resolution: "@docusaurus/plugin-google-tag-manager@npm:3.2.0" +"@docusaurus/plugin-google-tag-manager@npm:3.2.1": + version: 3.2.1 + resolution: "@docusaurus/plugin-google-tag-manager@npm:3.2.1" dependencies: - "@docusaurus/core": "npm:3.2.0" - "@docusaurus/types": "npm:3.2.0" - "@docusaurus/utils-validation": "npm:3.2.0" + "@docusaurus/core": "npm:3.2.1" + "@docusaurus/types": "npm:3.2.1" + "@docusaurus/utils-validation": "npm:3.2.1" tslib: "npm:^2.6.0" peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 10/da54a75927cca64c58e2195309bcf347f37f85833b1308f6176faffb6697217f73e5acd54ea1b53bbe5ee018acbcd3b420b2c934aef8fd548f1c035ba241bf08 + checksum: 10/82355aed046b12ce0fead68339e24a3c6f2f517bc2b80c9c26c502cc49d86c1b6d0f797d5269d1d5e73ac78fd748c8a2f4528f7f3feee1137ae8e73876426426 languageName: node linkType: hard -"@docusaurus/plugin-sitemap@npm:3.2.0": - version: 3.2.0 - resolution: "@docusaurus/plugin-sitemap@npm:3.2.0" - dependencies: - "@docusaurus/core": "npm:3.2.0" - "@docusaurus/logger": "npm:3.2.0" - "@docusaurus/types": "npm:3.2.0" - "@docusaurus/utils": "npm:3.2.0" - "@docusaurus/utils-common": "npm:3.2.0" - "@docusaurus/utils-validation": "npm:3.2.0" +"@docusaurus/plugin-sitemap@npm:3.2.1": + version: 3.2.1 + resolution: "@docusaurus/plugin-sitemap@npm:3.2.1" + dependencies: + "@docusaurus/core": "npm:3.2.1" + "@docusaurus/logger": "npm:3.2.1" + "@docusaurus/types": "npm:3.2.1" + "@docusaurus/utils": "npm:3.2.1" + "@docusaurus/utils-common": "npm:3.2.1" + "@docusaurus/utils-validation": "npm:3.2.1" fs-extra: "npm:^11.1.1" sitemap: "npm:^7.1.1" tslib: "npm:^2.6.0" peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 10/be1516e5f8097584f06e05c7a0ec9868dfebca3ef44e42042b149538c1341effb9e1a40b8e2dcefdc6570828a05d7d88946cc3fa0ff5978b5e19c89dfdbfa657 + checksum: 10/c24428ccb62083e66b0b1b722d20aeff207ee8dd25fb1e03529d430064a555f5af65774a44ce344cbffa85937731af022e820c45ce790757a839101faebaf767 languageName: node linkType: hard "@docusaurus/preset-classic@npm:^3.0.0": - version: 3.2.0 - resolution: "@docusaurus/preset-classic@npm:3.2.0" - dependencies: - "@docusaurus/core": "npm:3.2.0" - "@docusaurus/plugin-content-blog": "npm:3.2.0" - "@docusaurus/plugin-content-docs": "npm:3.2.0" - "@docusaurus/plugin-content-pages": "npm:3.2.0" - "@docusaurus/plugin-debug": "npm:3.2.0" - "@docusaurus/plugin-google-analytics": "npm:3.2.0" - "@docusaurus/plugin-google-gtag": "npm:3.2.0" - "@docusaurus/plugin-google-tag-manager": "npm:3.2.0" - "@docusaurus/plugin-sitemap": "npm:3.2.0" - "@docusaurus/theme-classic": "npm:3.2.0" - "@docusaurus/theme-common": "npm:3.2.0" - "@docusaurus/theme-search-algolia": "npm:3.2.0" - "@docusaurus/types": "npm:3.2.0" + version: 3.2.1 + resolution: "@docusaurus/preset-classic@npm:3.2.1" + dependencies: + "@docusaurus/core": "npm:3.2.1" + "@docusaurus/plugin-content-blog": "npm:3.2.1" + "@docusaurus/plugin-content-docs": "npm:3.2.1" + "@docusaurus/plugin-content-pages": "npm:3.2.1" + "@docusaurus/plugin-debug": "npm:3.2.1" + "@docusaurus/plugin-google-analytics": "npm:3.2.1" + "@docusaurus/plugin-google-gtag": "npm:3.2.1" + "@docusaurus/plugin-google-tag-manager": "npm:3.2.1" + "@docusaurus/plugin-sitemap": "npm:3.2.1" + "@docusaurus/theme-classic": "npm:3.2.1" + "@docusaurus/theme-common": "npm:3.2.1" + "@docusaurus/theme-search-algolia": "npm:3.2.1" + "@docusaurus/types": "npm:3.2.1" peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 10/96a5e3f71fd8e9761bfbedb89422a745fe53b20c38c6cbe038227a71109c298b8a14335ca6415158ee4bc2a1c325c31c595b2ae5173ee2200c02e3ef95ad6682 + checksum: 10/343c896f22bffbda9db4af7d652588f353c5f60336e545eb07be0dfe9bc29ca04a3978d88d5a8b3fa7caafc56a48b341349ffd08006885fa0d4de216cfdc5401 languageName: node linkType: hard @@ -4860,22 +4741,22 @@ __metadata: languageName: node linkType: hard -"@docusaurus/theme-classic@npm:3.2.0": - version: 3.2.0 - resolution: "@docusaurus/theme-classic@npm:3.2.0" - dependencies: - "@docusaurus/core": "npm:3.2.0" - "@docusaurus/mdx-loader": "npm:3.2.0" - "@docusaurus/module-type-aliases": "npm:3.2.0" - "@docusaurus/plugin-content-blog": "npm:3.2.0" - "@docusaurus/plugin-content-docs": "npm:3.2.0" - "@docusaurus/plugin-content-pages": "npm:3.2.0" - "@docusaurus/theme-common": "npm:3.2.0" - "@docusaurus/theme-translations": "npm:3.2.0" - "@docusaurus/types": "npm:3.2.0" - "@docusaurus/utils": "npm:3.2.0" - "@docusaurus/utils-common": "npm:3.2.0" - "@docusaurus/utils-validation": "npm:3.2.0" +"@docusaurus/theme-classic@npm:3.2.1": + version: 3.2.1 + resolution: "@docusaurus/theme-classic@npm:3.2.1" + dependencies: + "@docusaurus/core": "npm:3.2.1" + "@docusaurus/mdx-loader": "npm:3.2.1" + "@docusaurus/module-type-aliases": "npm:3.2.1" + "@docusaurus/plugin-content-blog": "npm:3.2.1" + "@docusaurus/plugin-content-docs": "npm:3.2.1" + "@docusaurus/plugin-content-pages": "npm:3.2.1" + "@docusaurus/theme-common": "npm:3.2.1" + "@docusaurus/theme-translations": "npm:3.2.1" + "@docusaurus/types": "npm:3.2.1" + "@docusaurus/utils": "npm:3.2.1" + "@docusaurus/utils-common": "npm:3.2.1" + "@docusaurus/utils-validation": "npm:3.2.1" "@mdx-js/react": "npm:^3.0.0" clsx: "npm:^2.0.0" copy-text-to-clipboard: "npm:^3.2.0" @@ -4892,21 +4773,21 @@ __metadata: peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 10/9905431e11942b80fbb73a5876f6370a17c368f133d8ab990fa8e5aaab415dd1aefb9f2e43e6c3638d2c32122afc2c160c708ce4e9c261827ac7d5b835ac3b05 + checksum: 10/384b7289b86f00bc3dfbe254924a1be0dc1786ddeaffb7f57ff9fff30d7fb64cf07d9860527ee6c0cf026da848056d35e75397607b2cfc89f9835ff674735633 languageName: node linkType: hard -"@docusaurus/theme-common@npm:3.2.0, @docusaurus/theme-common@npm:^3.2.0": - version: 3.2.0 - resolution: "@docusaurus/theme-common@npm:3.2.0" - dependencies: - "@docusaurus/mdx-loader": "npm:3.2.0" - "@docusaurus/module-type-aliases": "npm:3.2.0" - "@docusaurus/plugin-content-blog": "npm:3.2.0" - "@docusaurus/plugin-content-docs": "npm:3.2.0" - "@docusaurus/plugin-content-pages": "npm:3.2.0" - "@docusaurus/utils": "npm:3.2.0" - "@docusaurus/utils-common": "npm:3.2.0" +"@docusaurus/theme-common@npm:3.2.1, @docusaurus/theme-common@npm:^3.2.0": + version: 3.2.1 + resolution: "@docusaurus/theme-common@npm:3.2.1" + dependencies: + "@docusaurus/mdx-loader": "npm:3.2.1" + "@docusaurus/module-type-aliases": "npm:3.2.1" + "@docusaurus/plugin-content-blog": "npm:3.2.1" + "@docusaurus/plugin-content-docs": "npm:3.2.1" + "@docusaurus/plugin-content-pages": "npm:3.2.1" + "@docusaurus/utils": "npm:3.2.1" + "@docusaurus/utils-common": "npm:3.2.1" "@types/history": "npm:^4.7.11" "@types/react": "npm:*" "@types/react-router-config": "npm:*" @@ -4918,22 +4799,22 @@ __metadata: peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 10/403c4e3111e1acc9b1c3e382673c376594cbe62657f1306c9839fee54aa1be6c5be740058a5c47a66bd44e7c18e922202a52c8f573e6564aab0dc21229065cb5 + checksum: 10/bedd469ddb8bf4924783a4b76b847ccb746b154e65d4c73fe3a94af8cc0e69d2d70a0d69e12f94615aa82a4e61dcfe20db7ed216023259cb57076ffca780d387 languageName: node linkType: hard -"@docusaurus/theme-search-algolia@npm:3.2.0": - version: 3.2.0 - resolution: "@docusaurus/theme-search-algolia@npm:3.2.0" +"@docusaurus/theme-search-algolia@npm:3.2.1": + version: 3.2.1 + resolution: "@docusaurus/theme-search-algolia@npm:3.2.1" dependencies: "@docsearch/react": "npm:^3.5.2" - "@docusaurus/core": "npm:3.2.0" - "@docusaurus/logger": "npm:3.2.0" - "@docusaurus/plugin-content-docs": "npm:3.2.0" - "@docusaurus/theme-common": "npm:3.2.0" - "@docusaurus/theme-translations": "npm:3.2.0" - "@docusaurus/utils": "npm:3.2.0" - "@docusaurus/utils-validation": "npm:3.2.0" + "@docusaurus/core": "npm:3.2.1" + "@docusaurus/logger": "npm:3.2.1" + "@docusaurus/plugin-content-docs": "npm:3.2.1" + "@docusaurus/theme-common": "npm:3.2.1" + "@docusaurus/theme-translations": "npm:3.2.1" + "@docusaurus/utils": "npm:3.2.1" + "@docusaurus/utils-validation": "npm:3.2.1" algoliasearch: "npm:^4.18.0" algoliasearch-helper: "npm:^3.13.3" clsx: "npm:^2.0.0" @@ -4945,43 +4826,23 @@ __metadata: peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 10/b81aa2c4be3d1077b8195dbc00d0c0aa0bee113e0c09c1318faff994beaf77bf25588b4dbc81c63630d6c7c56f3c8c01798112e77eae995a1eccb6b7f5b37732 + checksum: 10/3109e9c486532ea5fba74596326c22ea0f206a253b10f05d9391f4b578bbdc76e319f691f5a561691a9bc7e8dd00da6634158ffb14d3499f943d679de8aac0c0 languageName: node linkType: hard -"@docusaurus/theme-translations@npm:3.2.0": - version: 3.2.0 - resolution: "@docusaurus/theme-translations@npm:3.2.0" +"@docusaurus/theme-translations@npm:3.2.1": + version: 3.2.1 + resolution: "@docusaurus/theme-translations@npm:3.2.1" dependencies: fs-extra: "npm:^11.1.1" tslib: "npm:^2.6.0" - checksum: 10/9c6d3f8d04c07cb4954f53ace547f1f39ea5c0c7d45a0995ab50efd30834d32d8cc2bd608d5a2dc497ea70126535b7e583546c063049d5bf62b0f6c93baa56ce + checksum: 10/ab3029e539ba28ccfbd371c862c6fad10d1625e068101fdbfc2a5bd9a72059a868c3db9723761fd7a2d9efcb2d252316666177dda9b9868cbfe6880a4c6a112d languageName: node linkType: hard -"@docusaurus/types@npm:3.1.1": - version: 3.1.1 - resolution: "@docusaurus/types@npm:3.1.1" - dependencies: - "@mdx-js/mdx": "npm:^3.0.0" - "@types/history": "npm:^4.7.11" - "@types/react": "npm:*" - commander: "npm:^5.1.0" - joi: "npm:^17.9.2" - react-helmet-async: "npm:^1.3.0" - utility-types: "npm:^3.10.0" - webpack: "npm:^5.88.1" - webpack-merge: "npm:^5.9.0" - peerDependencies: - react: ^18.0.0 - react-dom: ^18.0.0 - checksum: 10/55e70d4856391a373991ac4da0ecd836b55ebe690198bb2df33617135c8e3fc2acb0946f41c933cc9226e6b0133697fb297871e5f6b1a23d7a5bcd250c2da715 - languageName: node - linkType: hard - -"@docusaurus/types@npm:3.2.0": - version: 3.2.0 - resolution: "@docusaurus/types@npm:3.2.0" +"@docusaurus/types@npm:3.2.1": + version: 3.2.1 + resolution: "@docusaurus/types@npm:3.2.1" dependencies: "@mdx-js/mdx": "npm:^3.0.0" "@types/history": "npm:^4.7.11" @@ -4995,27 +4856,13 @@ __metadata: peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 10/41fb9ea411b03669124643deef65e98d06b31e7b494844d8c419b2170b4c396f76fbcd32b2efb57fd9c06cdfa19fcb6255d6ae1711f4a9ac2d8bde6c518055ad - languageName: node - linkType: hard - -"@docusaurus/utils-common@npm:3.1.1": - version: 3.1.1 - resolution: "@docusaurus/utils-common@npm:3.1.1" - dependencies: - tslib: "npm:^2.6.0" - peerDependencies: - "@docusaurus/types": "*" - peerDependenciesMeta: - "@docusaurus/types": - optional: true - checksum: 10/0370110801034ebd6fe3b50fbbeb3001f73ed78a8a6e3101319b41494b8d6d648902c43f4f1892696deb292f7c17af45d63d2018dca53488a79af448beaf1462 + checksum: 10/0a54e10d9b6d26cc8cab0cbdbd4a5cb213532937dedd8251ad27ebb8016d2d1f5592342cc2f4c31e1e72211f9bad59888c8b20d93a6a9171f01f161fc53bdafc languageName: node linkType: hard -"@docusaurus/utils-common@npm:3.2.0, @docusaurus/utils-common@npm:^3.2.0": - version: 3.2.0 - resolution: "@docusaurus/utils-common@npm:3.2.0" +"@docusaurus/utils-common@npm:3.2.1, @docusaurus/utils-common@npm:^3.2.0": + version: 3.2.1 + resolution: "@docusaurus/utils-common@npm:3.2.1" dependencies: tslib: "npm:^2.6.0" peerDependencies: @@ -5023,73 +4870,30 @@ __metadata: peerDependenciesMeta: "@docusaurus/types": optional: true - checksum: 10/8639ce0aa66dfbfd43222ddcd031e39d7e117f3c5c343fa5fafc898319e7159e756158c840ba70e848a6ea8b3124282753bfafb9a182e2e66a44dea7ab246990 + checksum: 10/bc0b7e74bc29134dbdb7fbc2e8f9f39f0f460923a07d0ccd7f0542088e92c47faf06bdbd253b7ba2b9250b0869118a3b7bf3faa3a075a2a35f5f8545eb3345f2 languageName: node linkType: hard -"@docusaurus/utils-validation@npm:3.1.1": - version: 3.1.1 - resolution: "@docusaurus/utils-validation@npm:3.1.1" - dependencies: - "@docusaurus/logger": "npm:3.1.1" - "@docusaurus/utils": "npm:3.1.1" - joi: "npm:^17.9.2" - js-yaml: "npm:^4.1.0" - tslib: "npm:^2.6.0" - checksum: 10/949adf506a1accc9aefd9559b48e16cdc5faac0d455e22d7c85064fd87710dca1d73c82b4ff7536beaeba3e2893a3d78f92fd4c9d720765fe480f6fd165d54c4 - languageName: node - linkType: hard - -"@docusaurus/utils-validation@npm:3.2.0, @docusaurus/utils-validation@npm:^3.2.0": - version: 3.2.0 - resolution: "@docusaurus/utils-validation@npm:3.2.0" +"@docusaurus/utils-validation@npm:3.2.1, @docusaurus/utils-validation@npm:^3.2.0": + version: 3.2.1 + resolution: "@docusaurus/utils-validation@npm:3.2.1" dependencies: - "@docusaurus/logger": "npm:3.2.0" - "@docusaurus/utils": "npm:3.2.0" - "@docusaurus/utils-common": "npm:3.2.0" + "@docusaurus/logger": "npm:3.2.1" + "@docusaurus/utils": "npm:3.2.1" + "@docusaurus/utils-common": "npm:3.2.1" joi: "npm:^17.9.2" js-yaml: "npm:^4.1.0" tslib: "npm:^2.6.0" - checksum: 10/f5b4cfa8ccb6ff5538a1d08dc03ed3e20910f826a8c664a63e719670c167300c92dcbd823e74ea14d6566e2c9fa80e5df38217310601e573b478e5b428c35cd3 + checksum: 10/24c93442482349346fbe1232dc59053b53b41dda8de58b5a8bae3634c931eb05ecd06e84faf7db3d5baaea185132f02363c082103067e174c6f277c8da37e64f languageName: node linkType: hard -"@docusaurus/utils@npm:3.1.1": - version: 3.1.1 - resolution: "@docusaurus/utils@npm:3.1.1" - dependencies: - "@docusaurus/logger": "npm:3.1.1" - "@svgr/webpack": "npm:^6.5.1" - escape-string-regexp: "npm:^4.0.0" - file-loader: "npm:^6.2.0" - fs-extra: "npm:^11.1.1" - github-slugger: "npm:^1.5.0" - globby: "npm:^11.1.0" - gray-matter: "npm:^4.0.3" - jiti: "npm:^1.20.0" - js-yaml: "npm:^4.1.0" - lodash: "npm:^4.17.21" - micromatch: "npm:^4.0.5" - resolve-pathname: "npm:^3.0.0" - shelljs: "npm:^0.8.5" - tslib: "npm:^2.6.0" - url-loader: "npm:^4.1.1" - webpack: "npm:^5.88.1" - peerDependencies: - "@docusaurus/types": "*" - peerDependenciesMeta: - "@docusaurus/types": - optional: true - checksum: 10/9a557516d0cebc63225ab06f2a0a0042606a10b42e3e3a496d56062fbafa49c88d91a3d27b218ed12392ce258245efc84fbd27ae23d435ccb56696be51a92ef7 - languageName: node - linkType: hard - -"@docusaurus/utils@npm:3.2.0, @docusaurus/utils@npm:^3.2.0": - version: 3.2.0 - resolution: "@docusaurus/utils@npm:3.2.0" +"@docusaurus/utils@npm:3.2.1, @docusaurus/utils@npm:^3.2.0": + version: 3.2.1 + resolution: "@docusaurus/utils@npm:3.2.1" dependencies: - "@docusaurus/logger": "npm:3.2.0" - "@docusaurus/utils-common": "npm:3.2.0" + "@docusaurus/logger": "npm:3.2.1" + "@docusaurus/utils-common": "npm:3.2.1" "@svgr/webpack": "npm:^6.5.1" escape-string-regexp: "npm:^4.0.0" file-loader: "npm:^6.2.0" @@ -5112,7 +4916,7 @@ __metadata: peerDependenciesMeta: "@docusaurus/types": optional: true - checksum: 10/7d899d0745af2c4675047c56943f12b542298c2791e1c2907f6975536ef1771dbf4e9401a6db2585a2967f077f09dc010c3ddce5742598baae34b8ad68c75f53 + checksum: 10/0ed193119bc51bcb22c150fa793672f76c22ddd6a301292615666e61d79cd2d020436340a184cb5c3b2f407272492c17c2d47fe34c9af5f5d84d9f774b5bce97 languageName: node linkType: hard @@ -6025,6 +5829,89 @@ __metadata: languageName: node linkType: hard +"@eth-optimism/contracts-bedrock@npm:0.17.2": + version: 0.17.2 + resolution: "@eth-optimism/contracts-bedrock@npm:0.17.2" + checksum: 10/7c577e1fb111b29b93701f6bd152dd6f6ba45b8bd5f08e60d31a12d78dfb1946c3e590811c5e6282978ed23a31a8839bd3903b918f433d3c328501fc1627d9fb + languageName: node + linkType: hard + +"@eth-optimism/contracts@npm:0.6.0": + version: 0.6.0 + resolution: "@eth-optimism/contracts@npm:0.6.0" + dependencies: + "@eth-optimism/core-utils": "npm:0.12.0" + "@ethersproject/abstract-provider": "npm:^5.7.0" + "@ethersproject/abstract-signer": "npm:^5.7.0" + peerDependencies: + ethers: ^5 + checksum: 10/dd1fa303ca39125d45fa71a2be0fe773971a986d0694ba98075b9b93ee3c0c71764fd061f1094f82c36d5aa167f5340ec92ef1ec45d901cb69ace086327c0cf2 + languageName: node + linkType: hard + +"@eth-optimism/core-utils@npm:0.12.0": + version: 0.12.0 + resolution: "@eth-optimism/core-utils@npm:0.12.0" + dependencies: + "@ethersproject/abi": "npm:^5.7.0" + "@ethersproject/abstract-provider": "npm:^5.7.0" + "@ethersproject/address": "npm:^5.7.0" + "@ethersproject/bignumber": "npm:^5.7.0" + "@ethersproject/bytes": "npm:^5.7.0" + "@ethersproject/constants": "npm:^5.7.0" + "@ethersproject/contracts": "npm:^5.7.0" + "@ethersproject/hash": "npm:^5.7.0" + "@ethersproject/keccak256": "npm:^5.7.0" + "@ethersproject/properties": "npm:^5.7.0" + "@ethersproject/providers": "npm:^5.7.0" + "@ethersproject/rlp": "npm:^5.7.0" + "@ethersproject/transactions": "npm:^5.7.0" + "@ethersproject/web": "npm:^5.7.0" + bufio: "npm:^1.0.7" + chai: "npm:^4.3.4" + checksum: 10/a7ea17a8b529b2c86b00ef19fa562c2b792d7e8a4071defea4d8a8b82a101105a3ab6dc86361118e17bf9b4784b4eca9c1e937c8b1e7294a1a850f97b5a73a10 + languageName: node + linkType: hard + +"@eth-optimism/core-utils@npm:0.13.2": + version: 0.13.2 + resolution: "@eth-optimism/core-utils@npm:0.13.2" + dependencies: + "@ethersproject/abi": "npm:^5.7.0" + "@ethersproject/abstract-provider": "npm:^5.7.0" + "@ethersproject/address": "npm:^5.7.0" + "@ethersproject/bignumber": "npm:^5.7.0" + "@ethersproject/bytes": "npm:^5.7.0" + "@ethersproject/constants": "npm:^5.7.0" + "@ethersproject/contracts": "npm:^5.7.0" + "@ethersproject/keccak256": "npm:^5.7.0" + "@ethersproject/properties": "npm:^5.7.0" + "@ethersproject/rlp": "npm:^5.7.0" + "@ethersproject/web": "npm:^5.7.1" + chai: "npm:^4.3.10" + ethers: "npm:^5.7.2" + node-fetch: "npm:^2.6.7" + checksum: 10/035287fc13fc94090e66a8833e3994fa669d46ac0009102114e3d27634b7303887614dc8a2093378c98bcd8bcd9668a59acd26ecc64d06f0709e0692bc380d35 + languageName: node + linkType: hard + +"@eth-optimism/sdk@npm:3.3.0": + version: 3.3.0 + resolution: "@eth-optimism/sdk@npm:3.3.0" + dependencies: + "@eth-optimism/contracts": "npm:0.6.0" + "@eth-optimism/contracts-bedrock": "npm:0.17.2" + "@eth-optimism/core-utils": "npm:0.13.2" + lodash: "npm:^4.17.21" + merkletreejs: "npm:^0.3.11" + rlp: "npm:^2.2.7" + semver: "npm:^7.6.0" + peerDependencies: + ethers: ^5 + checksum: 10/dce0ed1c2b646237ec4f7ff96dd9c6df02fff8dd2cd9ddb1533bbb0944221a6ddc085f933207030330e3e8b863080cbff740a8989450e7bad30149c7c2158540 + languageName: node + linkType: hard + "@ethereumjs/common@npm:2.6.5, @ethereumjs/common@npm:^2.6.4": version: 2.6.5 resolution: "@ethereumjs/common@npm:2.6.5" @@ -6127,7 +6014,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/address@npm:5.7.0, @ethersproject/address@npm:^5.0.0, @ethersproject/address@npm:^5.0.2, @ethersproject/address@npm:^5.0.4, @ethersproject/address@npm:^5.7.0": +"@ethersproject/address@npm:5.7.0, @ethersproject/address@npm:^5.0.0, @ethersproject/address@npm:^5.0.2, @ethersproject/address@npm:^5.0.4, @ethersproject/address@npm:^5.0.8, @ethersproject/address@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/address@npm:5.7.0" dependencies: @@ -6159,7 +6046,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/bignumber@npm:5.7.0, @ethersproject/bignumber@npm:^5.0.7, @ethersproject/bignumber@npm:^5.7.0": +"@ethersproject/bignumber@npm:5.7.0, @ethersproject/bignumber@npm:^5.0.7, @ethersproject/bignumber@npm:^5.1.1, @ethersproject/bignumber@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/bignumber@npm:5.7.0" dependencies: @@ -6170,7 +6057,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/bytes@npm:5.7.0, @ethersproject/bytes@npm:^5.0.4, @ethersproject/bytes@npm:^5.7.0": +"@ethersproject/bytes@npm:5.7.0, @ethersproject/bytes@npm:^5.0.4, @ethersproject/bytes@npm:^5.0.8, @ethersproject/bytes@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/bytes@npm:5.7.0" dependencies: @@ -6309,7 +6196,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/providers@npm:5.7.2, @ethersproject/providers@npm:^5.7.2": +"@ethersproject/providers@npm:5.7.2, @ethersproject/providers@npm:^5.7.0, @ethersproject/providers@npm:^5.7.2": version: 5.7.2 resolution: "@ethersproject/providers@npm:5.7.2" dependencies: @@ -6458,7 +6345,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/web@npm:5.7.1, @ethersproject/web@npm:^5.7.0": +"@ethersproject/web@npm:5.7.1, @ethersproject/web@npm:^5.7.0, @ethersproject/web@npm:^5.7.1": version: 5.7.1 resolution: "@ethersproject/web@npm:5.7.1" dependencies: @@ -7043,8 +6930,8 @@ __metadata: linkType: hard "@graphql-tools/executor@npm:^1.2.1": - version: 1.2.5 - resolution: "@graphql-tools/executor@npm:1.2.5" + version: 1.2.6 + resolution: "@graphql-tools/executor@npm:1.2.6" dependencies: "@graphql-tools/utils": "npm:^10.1.1" "@graphql-typed-document-node/core": "npm:3.2.0" @@ -7053,7 +6940,7 @@ __metadata: value-or-promise: "npm:^1.0.12" peerDependencies: graphql: ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0 - checksum: 10/520d75360a69fa2a7b7916f0bd21ef8d01790897f35a5e3edb1f64128fbc684781f58bd53970919c56f32f863794016a4e96deb687eb54b8bad26b0ce7ab2b72 + checksum: 10/fa095a89d79530d47774678336f4734e5ebf31a16cb2ad462e78412e679edbff123d1dd80d72a35e1d69d14d8cc39f539d1581617956ab3f43c74b148dfdbf5c languageName: node linkType: hard @@ -7376,7 +7263,7 @@ __metadata: languageName: node linkType: hard -"@headlessui/react@npm:1.7.18": +"@headlessui/react@npm:1.7.18, @headlessui/react@npm:^1.7.18": version: 1.7.18 resolution: "@headlessui/react@npm:1.7.18" dependencies: @@ -7712,7 +7599,7 @@ __metadata: languageName: node linkType: hard -"@logtail/core@npm:^0.4.19, @logtail/core@npm:^0.4.21": +"@logtail/core@npm:^0.4.21": version: 0.4.21 resolution: "@logtail/core@npm:0.4.21" dependencies: @@ -7723,23 +7610,7 @@ __metadata: languageName: node linkType: hard -"@logtail/node@npm:0.4.19": - version: 0.4.19 - resolution: "@logtail/node@npm:0.4.19" - dependencies: - "@logtail/core": "npm:^0.4.19" - "@logtail/types": "npm:^0.4.19" - "@msgpack/msgpack": "npm:^2.5.1" - "@types/stack-trace": "npm:^0.0.29" - cross-fetch: "npm:^3.0.4" - minimatch: "npm:^3.0.4" - serialize-error: "npm:^8.1.0" - stack-trace: "npm:^0.0.10" - checksum: 10/1f768bd0e74b3d71547679aad4185e8184979d8e1cb58a7c62d08909f7cea9573e50f5367e1f41e30d7772eb5c16030ba6de62e210f39665ad46d5d4eebc2b0c - languageName: node - linkType: hard - -"@logtail/node@npm:^0.4.12": +"@logtail/node@npm:0.4.21, @logtail/node@npm:^0.4.21": version: 0.4.21 resolution: "@logtail/node@npm:0.4.21" dependencies: @@ -7764,23 +7635,23 @@ __metadata: languageName: node linkType: hard -"@logtail/types@npm:^0.4.11, @logtail/types@npm:^0.4.19, @logtail/types@npm:^0.4.20": +"@logtail/types@npm:^0.4.20": version: 0.4.20 resolution: "@logtail/types@npm:0.4.20" checksum: 10/9240cbec66249102aaec67c8ac4457b5b15d9ec64136791f0c21acc519e4f5e6a89736ef7cc17950ca11595a19d719a893a61239df050a0d58e347c01c5ac6a9 languageName: node linkType: hard -"@logtail/winston@npm:0.4.12": - version: 0.4.12 - resolution: "@logtail/winston@npm:0.4.12" +"@logtail/winston@npm:0.4.21": + version: 0.4.21 + resolution: "@logtail/winston@npm:0.4.21" dependencies: - "@logtail/node": "npm:^0.4.12" - "@logtail/types": "npm:^0.4.11" + "@logtail/node": "npm:^0.4.21" + "@logtail/types": "npm:^0.4.20" winston-transport: "npm:^4.3.0" peerDependencies: winston: ">=3.2.1" - checksum: 10/c2922042a1603d7608c99bdb84a16a43b93f3c98ef584fadefdfde55de79e5516185ee1bce4c3e9de900af70caa94ff5642f0cc05212ab220eb2169f3241f9a7 + checksum: 10/6995e6d2abc114aa96dd6ad72ff236f961a9b9c95891cdb93029d4ff7881dc174e119b2bd2dd37f055c2fa7ea51269312c2f968ee39856d6609054fea5965186 languageName: node linkType: hard @@ -7833,8 +7704,8 @@ __metadata: linkType: hard "@matterlabs/hardhat-zksync-deploy@npm:^1.1.0": - version: 1.2.1 - resolution: "@matterlabs/hardhat-zksync-deploy@npm:1.2.1" + version: 1.3.0 + resolution: "@matterlabs/hardhat-zksync-deploy@npm:1.3.0" dependencies: "@matterlabs/hardhat-zksync-solc": "npm:^1.0.4" chai: "npm:^4.3.6" @@ -7849,7 +7720,7 @@ __metadata: ethers: ^6.7.1 hardhat: ^2.19.4 zksync-ethers: ^6.0.0 - checksum: 10/9237f56dd31e256b09840d0c8e3cd547c7674cf9434cfe1a7ad697f9ba131871270e16c9a7483e177ade73dd9114a7cbd74190a17d53c91bea565d6651773b16 + checksum: 10/e12c761a879c7861d061891aa2fadbfece8366b12f823421cc56b6137bbaebf7c249e4acbe6089a8babbcc003413e395022719a88df0fd659cbc5e9defd2f268 languageName: node linkType: hard @@ -8709,13 +8580,13 @@ __metadata: linkType: hard "@netlify/functions-utils@npm:^5.2.10": - version: 5.2.53 - resolution: "@netlify/functions-utils@npm:5.2.53" + version: 5.2.54 + resolution: "@netlify/functions-utils@npm:5.2.54" dependencies: - "@netlify/zip-it-and-ship-it": "npm:9.31.1" + "@netlify/zip-it-and-ship-it": "npm:9.31.3" cpy: "npm:^9.0.0" path-exists: "npm:^5.0.0" - checksum: 10/8e1318f86255180de46d2731a71a5e2eb3bc13008062746eb614377442d486129ca271a0d51b798464ceb3ff20b5bea6a23c06440656ea46b0edd3f86592a288 + checksum: 10/abf8d30ed35339a3e0ca022515a2182672f7eca32aee188256c013401106b06234f31eb5e9c3bc61e162ded38f3b20fc3459b89fe5180a244476b5ac47029eb3 languageName: node linkType: hard @@ -8893,9 +8764,9 @@ __metadata: linkType: hard "@netlify/open-api@npm:^2.18.0, @netlify/open-api@npm:^2.28.0": - version: 2.28.0 - resolution: "@netlify/open-api@npm:2.28.0" - checksum: 10/0b52553720dd8f877a35e32742c47aefc49edf406364ef53c3d2141bf172464fd40385cd0902da3235414efebe76d54f2fd015ea48907af26d11125484159049 + version: 2.30.0 + resolution: "@netlify/open-api@npm:2.30.0" + checksum: 10/f392b208937d8ef5d4375749b8a5c8912d974742617f1a565d1f123740494aeefc34c282e5b9ed5bf04421fccfa687b7f737eb804f07648ab9209d2a5bd9cdac languageName: node linkType: hard @@ -8915,24 +8786,24 @@ __metadata: languageName: node linkType: hard -"@netlify/serverless-functions-api@npm:^1.16.0, @netlify/serverless-functions-api@npm:^1.5.0": - version: 1.16.0 - resolution: "@netlify/serverless-functions-api@npm:1.16.0" +"@netlify/serverless-functions-api@npm:^1.16.2, @netlify/serverless-functions-api@npm:^1.5.0": + version: 1.16.2 + resolution: "@netlify/serverless-functions-api@npm:1.16.2" dependencies: "@netlify/node-cookies": "npm:^0.1.0" urlpattern-polyfill: "npm:8.0.2" - checksum: 10/4c74bf96c1a45e8b55bea87501f7b1695a3d2f616dd23cdc5b6d3a4400fa9b0dcc2866e0d5f1fd41f1c87f546aeb647c73580a11eb9546d663de8c3a9bb5abb8 + checksum: 10/758f5e627197e50841362d9f847d7ecab03fce9cd84039325335efb323c1e6a8cbc74b519471bd8527f43071977306a189bb7f6d3c7b830aac9f3c8fcf8ebbe1 languageName: node linkType: hard -"@netlify/zip-it-and-ship-it@npm:9.31.1": - version: 9.31.1 - resolution: "@netlify/zip-it-and-ship-it@npm:9.31.1" +"@netlify/zip-it-and-ship-it@npm:9.31.3": + version: 9.31.3 + resolution: "@netlify/zip-it-and-ship-it@npm:9.31.3" dependencies: "@babel/parser": "npm:^7.22.5" "@babel/types": "npm:7.23.6" "@netlify/binary-info": "npm:^1.0.0" - "@netlify/serverless-functions-api": "npm:^1.16.0" + "@netlify/serverless-functions-api": "npm:^1.16.2" "@vercel/nft": "npm:^0.23.0" archiver: "npm:^6.0.0" common-path-prefix: "npm:^3.0.0" @@ -8964,7 +8835,7 @@ __metadata: yargs: "npm:^17.0.0" bin: zip-it-and-ship-it: dist/bin.js - checksum: 10/06ab1b4fe3fe3f8f256ea8ea0f23e7e370543d8df85a838676a9e7eed9ea466c1b7ad9c03ef09a656cf75b13b43b6cbcf947712704f7f92b1707f491bdc06fa9 + checksum: 10/3a0497bc0965d74bbb12b0e6bfb55acf4fc3d3798f835e56f1f2ea786948421e00902f9bd80455883446a7b78e55277f1b55e5f4e88d8fd1a8adc47e0e6bf991 languageName: node linkType: hard @@ -9009,20 +8880,6 @@ __metadata: languageName: node linkType: hard -"@next/env@npm:13.4.19": - version: 13.4.19 - resolution: "@next/env@npm:13.4.19" - checksum: 10/9454485caf50292d4b1b4ffdd4794d408a07c43ac3e4688bcca023cd10980232a0a283f6fc48129ae4f3c21ad547b8404beeb84b5e1883815f940cb36a18c2fa - languageName: node - linkType: hard - -"@next/env@npm:14.0.4": - version: 14.0.4 - resolution: "@next/env@npm:14.0.4" - checksum: 10/781eede471730264812d8c744d33eb42da997b4403b06a5b0e58597645152af21f3619a6cb8fc0ba1c1b26d89910c0a8ade6d4242ae13d0b7baa70e3a83cac0f - languageName: node - linkType: hard - "@next/env@npm:14.1.4": version: 14.1.4 resolution: "@next/env@npm:14.1.4" @@ -9048,20 +8905,6 @@ __metadata: languageName: node linkType: hard -"@next/swc-darwin-arm64@npm:13.4.19": - version: 13.4.19 - resolution: "@next/swc-darwin-arm64@npm:13.4.19" - conditions: os=darwin & cpu=arm64 - languageName: node - linkType: hard - -"@next/swc-darwin-arm64@npm:14.0.4": - version: 14.0.4 - resolution: "@next/swc-darwin-arm64@npm:14.0.4" - conditions: os=darwin & cpu=arm64 - languageName: node - linkType: hard - "@next/swc-darwin-arm64@npm:14.1.4": version: 14.1.4 resolution: "@next/swc-darwin-arm64@npm:14.1.4" @@ -9069,20 +8912,6 @@ __metadata: languageName: node linkType: hard -"@next/swc-darwin-x64@npm:13.4.19": - version: 13.4.19 - resolution: "@next/swc-darwin-x64@npm:13.4.19" - conditions: os=darwin & cpu=x64 - languageName: node - linkType: hard - -"@next/swc-darwin-x64@npm:14.0.4": - version: 14.0.4 - resolution: "@next/swc-darwin-x64@npm:14.0.4" - conditions: os=darwin & cpu=x64 - languageName: node - linkType: hard - "@next/swc-darwin-x64@npm:14.1.4": version: 14.1.4 resolution: "@next/swc-darwin-x64@npm:14.1.4" @@ -9090,20 +8919,6 @@ __metadata: languageName: node linkType: hard -"@next/swc-linux-arm64-gnu@npm:13.4.19": - version: 13.4.19 - resolution: "@next/swc-linux-arm64-gnu@npm:13.4.19" - conditions: os=linux & cpu=arm64 & libc=glibc - languageName: node - linkType: hard - -"@next/swc-linux-arm64-gnu@npm:14.0.4": - version: 14.0.4 - resolution: "@next/swc-linux-arm64-gnu@npm:14.0.4" - conditions: os=linux & cpu=arm64 & libc=glibc - languageName: node - linkType: hard - "@next/swc-linux-arm64-gnu@npm:14.1.4": version: 14.1.4 resolution: "@next/swc-linux-arm64-gnu@npm:14.1.4" @@ -9111,20 +8926,6 @@ __metadata: languageName: node linkType: hard -"@next/swc-linux-arm64-musl@npm:13.4.19": - version: 13.4.19 - resolution: "@next/swc-linux-arm64-musl@npm:13.4.19" - conditions: os=linux & cpu=arm64 & libc=musl - languageName: node - linkType: hard - -"@next/swc-linux-arm64-musl@npm:14.0.4": - version: 14.0.4 - resolution: "@next/swc-linux-arm64-musl@npm:14.0.4" - conditions: os=linux & cpu=arm64 & libc=musl - languageName: node - linkType: hard - "@next/swc-linux-arm64-musl@npm:14.1.4": version: 14.1.4 resolution: "@next/swc-linux-arm64-musl@npm:14.1.4" @@ -9132,20 +8933,6 @@ __metadata: languageName: node linkType: hard -"@next/swc-linux-x64-gnu@npm:13.4.19": - version: 13.4.19 - resolution: "@next/swc-linux-x64-gnu@npm:13.4.19" - conditions: os=linux & cpu=x64 & libc=glibc - languageName: node - linkType: hard - -"@next/swc-linux-x64-gnu@npm:14.0.4": - version: 14.0.4 - resolution: "@next/swc-linux-x64-gnu@npm:14.0.4" - conditions: os=linux & cpu=x64 & libc=glibc - languageName: node - linkType: hard - "@next/swc-linux-x64-gnu@npm:14.1.4": version: 14.1.4 resolution: "@next/swc-linux-x64-gnu@npm:14.1.4" @@ -9153,20 +8940,6 @@ __metadata: languageName: node linkType: hard -"@next/swc-linux-x64-musl@npm:13.4.19": - version: 13.4.19 - resolution: "@next/swc-linux-x64-musl@npm:13.4.19" - conditions: os=linux & cpu=x64 & libc=musl - languageName: node - linkType: hard - -"@next/swc-linux-x64-musl@npm:14.0.4": - version: 14.0.4 - resolution: "@next/swc-linux-x64-musl@npm:14.0.4" - conditions: os=linux & cpu=x64 & libc=musl - languageName: node - linkType: hard - "@next/swc-linux-x64-musl@npm:14.1.4": version: 14.1.4 resolution: "@next/swc-linux-x64-musl@npm:14.1.4" @@ -9174,20 +8947,6 @@ __metadata: languageName: node linkType: hard -"@next/swc-win32-arm64-msvc@npm:13.4.19": - version: 13.4.19 - resolution: "@next/swc-win32-arm64-msvc@npm:13.4.19" - conditions: os=win32 & cpu=arm64 - languageName: node - linkType: hard - -"@next/swc-win32-arm64-msvc@npm:14.0.4": - version: 14.0.4 - resolution: "@next/swc-win32-arm64-msvc@npm:14.0.4" - conditions: os=win32 & cpu=arm64 - languageName: node - linkType: hard - "@next/swc-win32-arm64-msvc@npm:14.1.4": version: 14.1.4 resolution: "@next/swc-win32-arm64-msvc@npm:14.1.4" @@ -9195,20 +8954,6 @@ __metadata: languageName: node linkType: hard -"@next/swc-win32-ia32-msvc@npm:13.4.19": - version: 13.4.19 - resolution: "@next/swc-win32-ia32-msvc@npm:13.4.19" - conditions: os=win32 & cpu=ia32 - languageName: node - linkType: hard - -"@next/swc-win32-ia32-msvc@npm:14.0.4": - version: 14.0.4 - resolution: "@next/swc-win32-ia32-msvc@npm:14.0.4" - conditions: os=win32 & cpu=ia32 - languageName: node - linkType: hard - "@next/swc-win32-ia32-msvc@npm:14.1.4": version: 14.1.4 resolution: "@next/swc-win32-ia32-msvc@npm:14.1.4" @@ -9216,20 +8961,6 @@ __metadata: languageName: node linkType: hard -"@next/swc-win32-x64-msvc@npm:13.4.19": - version: 13.4.19 - resolution: "@next/swc-win32-x64-msvc@npm:13.4.19" - conditions: os=win32 & cpu=x64 - languageName: node - linkType: hard - -"@next/swc-win32-x64-msvc@npm:14.0.4": - version: 14.0.4 - resolution: "@next/swc-win32-x64-msvc@npm:14.0.4" - conditions: os=win32 & cpu=x64 - languageName: node - linkType: hard - "@next/swc-win32-x64-msvc@npm:14.1.4": version: 14.1.4 resolution: "@next/swc-win32-x64-msvc@npm:14.1.4" @@ -9301,7 +9032,7 @@ __metadata: languageName: node linkType: hard -"@noble/hashes@npm:1.4.0, @noble/hashes@npm:^1.1.2, @noble/hashes@npm:^1.3.0, @noble/hashes@npm:^1.3.1, @noble/hashes@npm:^1.3.3": +"@noble/hashes@npm:1.4.0, @noble/hashes@npm:^1.1.2, @noble/hashes@npm:^1.3.0, @noble/hashes@npm:^1.3.1, @noble/hashes@npm:^1.3.3, @noble/hashes@npm:^1.4.0": version: 1.4.0 resolution: "@noble/hashes@npm:1.4.0" checksum: 10/e156e65794c473794c52fa9d06baf1eb20903d0d96719530f523cc4450f6c721a957c544796e6efd0197b2296e7cd70efeb312f861465e17940a3e3c7e0febc6 @@ -9342,82 +9073,82 @@ __metadata: languageName: node linkType: hard -"@nomicfoundation/edr-darwin-arm64@npm:0.3.3": - version: 0.3.3 - resolution: "@nomicfoundation/edr-darwin-arm64@npm:0.3.3" +"@nomicfoundation/edr-darwin-arm64@npm:0.3.4": + version: 0.3.4 + resolution: "@nomicfoundation/edr-darwin-arm64@npm:0.3.4" conditions: os=darwin & cpu=arm64 languageName: node linkType: hard -"@nomicfoundation/edr-darwin-x64@npm:0.3.3": - version: 0.3.3 - resolution: "@nomicfoundation/edr-darwin-x64@npm:0.3.3" +"@nomicfoundation/edr-darwin-x64@npm:0.3.4": + version: 0.3.4 + resolution: "@nomicfoundation/edr-darwin-x64@npm:0.3.4" conditions: os=darwin & cpu=x64 languageName: node linkType: hard -"@nomicfoundation/edr-linux-arm64-gnu@npm:0.3.3": - version: 0.3.3 - resolution: "@nomicfoundation/edr-linux-arm64-gnu@npm:0.3.3" +"@nomicfoundation/edr-linux-arm64-gnu@npm:0.3.4": + version: 0.3.4 + resolution: "@nomicfoundation/edr-linux-arm64-gnu@npm:0.3.4" conditions: os=linux & cpu=arm64 & libc=glibc languageName: node linkType: hard -"@nomicfoundation/edr-linux-arm64-musl@npm:0.3.3": - version: 0.3.3 - resolution: "@nomicfoundation/edr-linux-arm64-musl@npm:0.3.3" +"@nomicfoundation/edr-linux-arm64-musl@npm:0.3.4": + version: 0.3.4 + resolution: "@nomicfoundation/edr-linux-arm64-musl@npm:0.3.4" conditions: os=linux & cpu=arm64 & libc=musl languageName: node linkType: hard -"@nomicfoundation/edr-linux-x64-gnu@npm:0.3.3": - version: 0.3.3 - resolution: "@nomicfoundation/edr-linux-x64-gnu@npm:0.3.3" +"@nomicfoundation/edr-linux-x64-gnu@npm:0.3.4": + version: 0.3.4 + resolution: "@nomicfoundation/edr-linux-x64-gnu@npm:0.3.4" conditions: os=linux & cpu=x64 & libc=glibc languageName: node linkType: hard -"@nomicfoundation/edr-linux-x64-musl@npm:0.3.3": - version: 0.3.3 - resolution: "@nomicfoundation/edr-linux-x64-musl@npm:0.3.3" +"@nomicfoundation/edr-linux-x64-musl@npm:0.3.4": + version: 0.3.4 + resolution: "@nomicfoundation/edr-linux-x64-musl@npm:0.3.4" conditions: os=linux & cpu=x64 & libc=musl languageName: node linkType: hard -"@nomicfoundation/edr-win32-arm64-msvc@npm:0.3.3": - version: 0.3.3 - resolution: "@nomicfoundation/edr-win32-arm64-msvc@npm:0.3.3" +"@nomicfoundation/edr-win32-arm64-msvc@npm:0.3.4": + version: 0.3.4 + resolution: "@nomicfoundation/edr-win32-arm64-msvc@npm:0.3.4" conditions: os=win32 & cpu=arm64 languageName: node linkType: hard -"@nomicfoundation/edr-win32-ia32-msvc@npm:0.3.3": - version: 0.3.3 - resolution: "@nomicfoundation/edr-win32-ia32-msvc@npm:0.3.3" +"@nomicfoundation/edr-win32-ia32-msvc@npm:0.3.4": + version: 0.3.4 + resolution: "@nomicfoundation/edr-win32-ia32-msvc@npm:0.3.4" conditions: os=win32 & cpu=ia32 languageName: node linkType: hard -"@nomicfoundation/edr-win32-x64-msvc@npm:0.3.3": - version: 0.3.3 - resolution: "@nomicfoundation/edr-win32-x64-msvc@npm:0.3.3" +"@nomicfoundation/edr-win32-x64-msvc@npm:0.3.4": + version: 0.3.4 + resolution: "@nomicfoundation/edr-win32-x64-msvc@npm:0.3.4" conditions: os=win32 & cpu=x64 languageName: node linkType: hard "@nomicfoundation/edr@npm:^0.3.1": - version: 0.3.3 - resolution: "@nomicfoundation/edr@npm:0.3.3" - dependencies: - "@nomicfoundation/edr-darwin-arm64": "npm:0.3.3" - "@nomicfoundation/edr-darwin-x64": "npm:0.3.3" - "@nomicfoundation/edr-linux-arm64-gnu": "npm:0.3.3" - "@nomicfoundation/edr-linux-arm64-musl": "npm:0.3.3" - "@nomicfoundation/edr-linux-x64-gnu": "npm:0.3.3" - "@nomicfoundation/edr-linux-x64-musl": "npm:0.3.3" - "@nomicfoundation/edr-win32-arm64-msvc": "npm:0.3.3" - "@nomicfoundation/edr-win32-ia32-msvc": "npm:0.3.3" - "@nomicfoundation/edr-win32-x64-msvc": "npm:0.3.3" + version: 0.3.4 + resolution: "@nomicfoundation/edr@npm:0.3.4" + dependencies: + "@nomicfoundation/edr-darwin-arm64": "npm:0.3.4" + "@nomicfoundation/edr-darwin-x64": "npm:0.3.4" + "@nomicfoundation/edr-linux-arm64-gnu": "npm:0.3.4" + "@nomicfoundation/edr-linux-arm64-musl": "npm:0.3.4" + "@nomicfoundation/edr-linux-x64-gnu": "npm:0.3.4" + "@nomicfoundation/edr-linux-x64-musl": "npm:0.3.4" + "@nomicfoundation/edr-win32-arm64-msvc": "npm:0.3.4" + "@nomicfoundation/edr-win32-ia32-msvc": "npm:0.3.4" + "@nomicfoundation/edr-win32-x64-msvc": "npm:0.3.4" dependenciesMeta: "@nomicfoundation/edr-darwin-arm64": optional: true @@ -9437,7 +9168,7 @@ __metadata: optional: true "@nomicfoundation/edr-win32-x64-msvc": optional: true - checksum: 10/fd3447d557ca38716f957cdf3b3d5c211acd86d2a3c2a556473d281fb3515d0d04d54106dd249a63c70d68c7e2f2e2e09c3cc7203b0bfa5d758acdccf10c6442 + checksum: 10/672a98e55634017d9b96dc87a072b01151761372212ce2003e2f373419a4f08300373bbe65fa0c11d9cf0fece696cb6a494a2fe1c0d5bd3c78527a74e808007f languageName: node linkType: hard @@ -9978,8 +9709,8 @@ __metadata: linkType: hard "@oclif/core@npm:^2.15.0": - version: 2.15.0 - resolution: "@oclif/core@npm:2.15.0" + version: 2.16.0 + resolution: "@oclif/core@npm:2.16.0" dependencies: "@types/cli-progress": "npm:^3.11.0" ansi-escapes: "npm:^4.3.2" @@ -10009,7 +9740,7 @@ __metadata: widest-line: "npm:^3.1.0" wordwrap: "npm:^1.0.0" wrap-ansi: "npm:^7.0.0" - checksum: 10/610ad7425ac811797ec289be9f2f4763f95abf407d2b7b78a8f2871a2954168ff5c4ec323f831a0df5b5938d3ef826ad3915629c9749f7f615e1d4455f13b100 + checksum: 10/74ea31a5cec9281c1b1fade5930cb7ac0e9330342f58a1fa7403eff0860d5959b9389a9be20e24e54126b111973e0eec42b09cec922f4cc04a2ce83e39b3bfdb languageName: node linkType: hard @@ -10213,6 +9944,13 @@ __metadata: languageName: node linkType: hard +"@openzeppelin/contracts-upgradeable@npm:4.5.2": + version: 4.5.2 + resolution: "@openzeppelin/contracts-upgradeable@npm:4.5.2" + checksum: 10/5e246da7a44bb982a312ebf79978735712140692d46273566e490159b98b9041ca72cc08c3d05172137a389be4caad5afc001480bc5557f3d47162f4626e3723 + languageName: node + linkType: hard + "@openzeppelin/contracts-upgradeable@npm:4.9.5": version: 4.9.5 resolution: "@openzeppelin/contracts-upgradeable@npm:4.9.5" @@ -10234,6 +9972,13 @@ __metadata: languageName: node linkType: hard +"@openzeppelin/contracts@npm:4.5.0": + version: 4.5.0 + resolution: "@openzeppelin/contracts@npm:4.5.0" + checksum: 10/8bfa1733732420331728cedd7f1f5f4e4ae0700b32c9e5def19b2d42dbb0b246709e8e22abd457e8269d743012ff2aed4e3f100a942f45d9507cb78d5dbd435b + languageName: node + linkType: hard + "@openzeppelin/contracts@npm:4.7.0": version: 4.7.0 resolution: "@openzeppelin/contracts@npm:4.7.0" @@ -10302,35 +10047,35 @@ __metadata: languageName: node linkType: hard -"@openzeppelin/defender-sdk-base-client@npm:^1.10.0, @openzeppelin/defender-sdk-base-client@npm:^1.11.0, @openzeppelin/defender-sdk-base-client@npm:^1.8.0": - version: 1.11.0 - resolution: "@openzeppelin/defender-sdk-base-client@npm:1.11.0" +"@openzeppelin/defender-sdk-base-client@npm:^1.10.0, @openzeppelin/defender-sdk-base-client@npm:^1.12.0, @openzeppelin/defender-sdk-base-client@npm:^1.8.0": + version: 1.12.0 + resolution: "@openzeppelin/defender-sdk-base-client@npm:1.12.0" dependencies: amazon-cognito-identity-js: "npm:^6.3.6" async-retry: "npm:^1.3.3" - checksum: 10/c4624d5575bec7860c0a9280fcb2929c4fd1f852cbf969afbd223ed6736d413862e430e250554b0f6794520c7dfa14d7f45716a3f5e9857ec9341c99f81a0ea3 + checksum: 10/1e6171f9d8c321631cc23ecf8018d28109b0510c8a30926d28b3f1476bde88696b92f8fe4669ff75e6b156eb971efa03d2ffc27d202607ed84ce648bb8b971d1 languageName: node linkType: hard "@openzeppelin/defender-sdk-deploy-client@npm:^1.10.0, @openzeppelin/defender-sdk-deploy-client@npm:^1.8.0": - version: 1.11.0 - resolution: "@openzeppelin/defender-sdk-deploy-client@npm:1.11.0" + version: 1.12.0 + resolution: "@openzeppelin/defender-sdk-deploy-client@npm:1.12.0" dependencies: - "@openzeppelin/defender-sdk-base-client": "npm:^1.11.0" + "@openzeppelin/defender-sdk-base-client": "npm:^1.12.0" axios: "npm:^1.6.7" lodash: "npm:^4.17.21" - checksum: 10/f3f32dfe69b3b72b36b1fa6d3bd9544b1b9670a1b4f1e5a03e9994f7db83da6907f390f2c82fb628d83865c41601f403e4175ee9306fcee5df8948a31f3341c3 + checksum: 10/be6eb915ce6338683c38c81f9c1c132448170de2d6fa352a1f582d1152451210d8eb536900e7af1d69fafec330ca066fe3be62369348f40e2b2e4ef2aca4f001 languageName: node linkType: hard "@openzeppelin/defender-sdk-network-client@npm:^1.10.0": - version: 1.11.0 - resolution: "@openzeppelin/defender-sdk-network-client@npm:1.11.0" + version: 1.12.0 + resolution: "@openzeppelin/defender-sdk-network-client@npm:1.12.0" dependencies: - "@openzeppelin/defender-sdk-base-client": "npm:^1.11.0" + "@openzeppelin/defender-sdk-base-client": "npm:^1.12.0" axios: "npm:^1.6.7" lodash: "npm:^4.17.21" - checksum: 10/be89c738797016cb9561d371563af506bcfb3ea283454e796116754e044d583b787feaf62e2b82403c1ee4f0e575f0091a03891b883964a76647a383af2470b2 + checksum: 10/dd6b9f32b66ab51d4b61b7c5bd707b25db8c8f7e5969ad178d3286c8b963292020a5a2e08b7660a7f13893bf216dd7f5c7ccba5d9fa81f2239b312a127cb2e44 languageName: node linkType: hard @@ -11731,107 +11476,107 @@ __metadata: languageName: node linkType: hard -"@rollup/rollup-android-arm-eabi@npm:4.14.0": - version: 4.14.0 - resolution: "@rollup/rollup-android-arm-eabi@npm:4.14.0" +"@rollup/rollup-android-arm-eabi@npm:4.14.1": + version: 4.14.1 + resolution: "@rollup/rollup-android-arm-eabi@npm:4.14.1" conditions: os=android & cpu=arm languageName: node linkType: hard -"@rollup/rollup-android-arm64@npm:4.14.0": - version: 4.14.0 - resolution: "@rollup/rollup-android-arm64@npm:4.14.0" +"@rollup/rollup-android-arm64@npm:4.14.1": + version: 4.14.1 + resolution: "@rollup/rollup-android-arm64@npm:4.14.1" conditions: os=android & cpu=arm64 languageName: node linkType: hard -"@rollup/rollup-darwin-arm64@npm:4.14.0": - version: 4.14.0 - resolution: "@rollup/rollup-darwin-arm64@npm:4.14.0" +"@rollup/rollup-darwin-arm64@npm:4.14.1": + version: 4.14.1 + resolution: "@rollup/rollup-darwin-arm64@npm:4.14.1" conditions: os=darwin & cpu=arm64 languageName: node linkType: hard -"@rollup/rollup-darwin-x64@npm:4.14.0": - version: 4.14.0 - resolution: "@rollup/rollup-darwin-x64@npm:4.14.0" +"@rollup/rollup-darwin-x64@npm:4.14.1": + version: 4.14.1 + resolution: "@rollup/rollup-darwin-x64@npm:4.14.1" conditions: os=darwin & cpu=x64 languageName: node linkType: hard -"@rollup/rollup-linux-arm-gnueabihf@npm:4.14.0": - version: 4.14.0 - resolution: "@rollup/rollup-linux-arm-gnueabihf@npm:4.14.0" +"@rollup/rollup-linux-arm-gnueabihf@npm:4.14.1": + version: 4.14.1 + resolution: "@rollup/rollup-linux-arm-gnueabihf@npm:4.14.1" conditions: os=linux & cpu=arm languageName: node linkType: hard -"@rollup/rollup-linux-arm64-gnu@npm:4.14.0": - version: 4.14.0 - resolution: "@rollup/rollup-linux-arm64-gnu@npm:4.14.0" +"@rollup/rollup-linux-arm64-gnu@npm:4.14.1": + version: 4.14.1 + resolution: "@rollup/rollup-linux-arm64-gnu@npm:4.14.1" conditions: os=linux & cpu=arm64 & libc=glibc languageName: node linkType: hard -"@rollup/rollup-linux-arm64-musl@npm:4.14.0": - version: 4.14.0 - resolution: "@rollup/rollup-linux-arm64-musl@npm:4.14.0" +"@rollup/rollup-linux-arm64-musl@npm:4.14.1": + version: 4.14.1 + resolution: "@rollup/rollup-linux-arm64-musl@npm:4.14.1" conditions: os=linux & cpu=arm64 & libc=musl languageName: node linkType: hard -"@rollup/rollup-linux-powerpc64le-gnu@npm:4.14.0": - version: 4.14.0 - resolution: "@rollup/rollup-linux-powerpc64le-gnu@npm:4.14.0" +"@rollup/rollup-linux-powerpc64le-gnu@npm:4.14.1": + version: 4.14.1 + resolution: "@rollup/rollup-linux-powerpc64le-gnu@npm:4.14.1" conditions: os=linux & cpu=ppc64le & libc=glibc languageName: node linkType: hard -"@rollup/rollup-linux-riscv64-gnu@npm:4.14.0": - version: 4.14.0 - resolution: "@rollup/rollup-linux-riscv64-gnu@npm:4.14.0" +"@rollup/rollup-linux-riscv64-gnu@npm:4.14.1": + version: 4.14.1 + resolution: "@rollup/rollup-linux-riscv64-gnu@npm:4.14.1" conditions: os=linux & cpu=riscv64 & libc=glibc languageName: node linkType: hard -"@rollup/rollup-linux-s390x-gnu@npm:4.14.0": - version: 4.14.0 - resolution: "@rollup/rollup-linux-s390x-gnu@npm:4.14.0" +"@rollup/rollup-linux-s390x-gnu@npm:4.14.1": + version: 4.14.1 + resolution: "@rollup/rollup-linux-s390x-gnu@npm:4.14.1" conditions: os=linux & cpu=s390x & libc=glibc languageName: node linkType: hard -"@rollup/rollup-linux-x64-gnu@npm:4.14.0": - version: 4.14.0 - resolution: "@rollup/rollup-linux-x64-gnu@npm:4.14.0" +"@rollup/rollup-linux-x64-gnu@npm:4.14.1": + version: 4.14.1 + resolution: "@rollup/rollup-linux-x64-gnu@npm:4.14.1" conditions: os=linux & cpu=x64 & libc=glibc languageName: node linkType: hard -"@rollup/rollup-linux-x64-musl@npm:4.14.0": - version: 4.14.0 - resolution: "@rollup/rollup-linux-x64-musl@npm:4.14.0" +"@rollup/rollup-linux-x64-musl@npm:4.14.1": + version: 4.14.1 + resolution: "@rollup/rollup-linux-x64-musl@npm:4.14.1" conditions: os=linux & cpu=x64 & libc=musl languageName: node linkType: hard -"@rollup/rollup-win32-arm64-msvc@npm:4.14.0": - version: 4.14.0 - resolution: "@rollup/rollup-win32-arm64-msvc@npm:4.14.0" +"@rollup/rollup-win32-arm64-msvc@npm:4.14.1": + version: 4.14.1 + resolution: "@rollup/rollup-win32-arm64-msvc@npm:4.14.1" conditions: os=win32 & cpu=arm64 languageName: node linkType: hard -"@rollup/rollup-win32-ia32-msvc@npm:4.14.0": - version: 4.14.0 - resolution: "@rollup/rollup-win32-ia32-msvc@npm:4.14.0" +"@rollup/rollup-win32-ia32-msvc@npm:4.14.1": + version: 4.14.1 + resolution: "@rollup/rollup-win32-ia32-msvc@npm:4.14.1" conditions: os=win32 & cpu=ia32 languageName: node linkType: hard -"@rollup/rollup-win32-x64-msvc@npm:4.14.0": - version: 4.14.0 - resolution: "@rollup/rollup-win32-x64-msvc@npm:4.14.0" +"@rollup/rollup-win32-x64-msvc@npm:4.14.1": + version: 4.14.1 + resolution: "@rollup/rollup-win32-x64-msvc@npm:4.14.1" conditions: os=win32 & cpu=x64 languageName: node linkType: hard @@ -11855,7 +11600,7 @@ __metadata: languageName: node linkType: hard -"@safe-global/protocol-kit@npm:3.0.1, @safe-global/protocol-kit@npm:^3.0.1": +"@safe-global/protocol-kit@npm:3.0.1": version: 3.0.1 resolution: "@safe-global/protocol-kit@npm:3.0.1" dependencies: @@ -11871,6 +11616,22 @@ __metadata: languageName: node linkType: hard +"@safe-global/protocol-kit@npm:^3.0.1": + version: 3.0.2 + resolution: "@safe-global/protocol-kit@npm:3.0.2" + dependencies: + "@noble/hashes": "npm:^1.3.3" + "@safe-global/safe-deployments": "npm:^1.34.0" + ethereumjs-util: "npm:^7.1.5" + ethers: "npm:^6.7.1" + semver: "npm:^7.5.4" + web3: "npm:^1.10.3" + web3-core: "npm:^1.10.3" + web3-utils: "npm:^1.10.3" + checksum: 10/6eda029c510d05c38b07f6889804865c70a65bc2e6a9e411dc0bd1332c496ed37d522820214514d4b3115c02c6eb43b1ad1c3c6df48ad9b3db714f0a84a7a334 + languageName: node + linkType: hard + "@safe-global/safe-core-sdk-types@npm:^1.9.1, @safe-global/safe-core-sdk-types@npm:^1.9.2": version: 1.10.1 resolution: "@safe-global/safe-core-sdk-types@npm:1.10.1" @@ -11885,14 +11646,14 @@ __metadata: linkType: hard "@safe-global/safe-core-sdk-types@npm:^4.0.1": - version: 4.0.1 - resolution: "@safe-global/safe-core-sdk-types@npm:4.0.1" + version: 4.0.2 + resolution: "@safe-global/safe-core-sdk-types@npm:4.0.2" dependencies: - "@safe-global/safe-deployments": "npm:^1.33.0" + "@safe-global/safe-deployments": "npm:^1.34.0" ethers: "npm:^6.7.1" web3-core: "npm:^1.10.3" web3-utils: "npm:^1.10.3" - checksum: 10/fc68538ab0bfa17a00c33fe3eb2ad80d150947edb2f345060c5794f3b753001f368653af87960e707d92addec1a37a30376463481f8d7a8aa23319ae5b3d9484 + checksum: 10/d998ad70802cba6aa9ce1afb17034d054bad2062b7fecea008046652e5a715c3fd99d1586063aa9172c45dca4b8b48d3a89ee29656462bfe99f5b698d1d073f4 languageName: node linkType: hard @@ -11923,7 +11684,7 @@ __metadata: languageName: node linkType: hard -"@safe-global/safe-deployments@npm:^1.20.2, @safe-global/safe-deployments@npm:^1.25.0, @safe-global/safe-deployments@npm:^1.33.0": +"@safe-global/safe-deployments@npm:^1.20.2, @safe-global/safe-deployments@npm:^1.25.0, @safe-global/safe-deployments@npm:^1.33.0, @safe-global/safe-deployments@npm:^1.34.0": version: 1.34.0 resolution: "@safe-global/safe-deployments@npm:1.34.0" dependencies: @@ -12542,17 +12303,6 @@ __metadata: languageName: node linkType: hard -"@slorber/static-site-generator-webpack-plugin@npm:^4.0.7": - version: 4.0.7 - resolution: "@slorber/static-site-generator-webpack-plugin@npm:4.0.7" - dependencies: - eval: "npm:^0.1.8" - p-map: "npm:^4.0.0" - webpack-sources: "npm:^3.2.2" - checksum: 10/c39814907a3e9ac6635c14a2d5647a4399aa436ce1e17795df07871d61f9d4810d810d85268257e6ffa1ceae3ca2a53930e4b5f24b6756f12db6c19c21ca2e28 - languageName: node - linkType: hard - "@smithy/abort-controller@npm:^2.2.0": version: 2.2.0 resolution: "@smithy/abort-controller@npm:2.2.0" @@ -12595,19 +12345,19 @@ __metadata: languageName: node linkType: hard -"@smithy/core@npm:^1.3.5, @smithy/core@npm:^1.4.0": - version: 1.4.1 - resolution: "@smithy/core@npm:1.4.1" +"@smithy/core@npm:^1.3.5, @smithy/core@npm:^1.4.2": + version: 1.4.2 + resolution: "@smithy/core@npm:1.4.2" dependencies: - "@smithy/middleware-endpoint": "npm:^2.5.0" - "@smithy/middleware-retry": "npm:^2.3.0" + "@smithy/middleware-endpoint": "npm:^2.5.1" + "@smithy/middleware-retry": "npm:^2.3.1" "@smithy/middleware-serde": "npm:^2.3.0" "@smithy/protocol-http": "npm:^3.3.0" - "@smithy/smithy-client": "npm:^2.5.0" + "@smithy/smithy-client": "npm:^2.5.1" "@smithy/types": "npm:^2.12.0" "@smithy/util-middleware": "npm:^2.2.0" tslib: "npm:^2.6.2" - checksum: 10/5d2f155e32d8c3d8aca3b207e3c27275b87bfc8f0003d3e98bf4d49ead319f3c5d7aaf5b37f2547771ddb791bd7d35160f773a43c02a5bc340234927ca9f42f3 + checksum: 10/a1aa9d5727edf5d50b9209dc2d05dcc55c2d20eca5201daa7704b4db4c78dc0fd64c97f58ca044280653882c55156bc7e733e8b3ec26606eaff4de473abdd59a languageName: node linkType: hard @@ -12768,9 +12518,9 @@ __metadata: languageName: node linkType: hard -"@smithy/middleware-endpoint@npm:^2.4.4, @smithy/middleware-endpoint@npm:^2.5.0": - version: 2.5.0 - resolution: "@smithy/middleware-endpoint@npm:2.5.0" +"@smithy/middleware-endpoint@npm:^2.4.4, @smithy/middleware-endpoint@npm:^2.5.1": + version: 2.5.1 + resolution: "@smithy/middleware-endpoint@npm:2.5.1" dependencies: "@smithy/middleware-serde": "npm:^2.3.0" "@smithy/node-config-provider": "npm:^2.3.0" @@ -12779,24 +12529,24 @@ __metadata: "@smithy/url-parser": "npm:^2.2.0" "@smithy/util-middleware": "npm:^2.2.0" tslib: "npm:^2.6.2" - checksum: 10/9d4ea6335671d97a58d245b5497bddbee7b44c45de49e930e9ab2685bf0e57029a5d76f61cf4390f1d336231459ef562f90d80e988ce3b272bf33aa394fcf29a + checksum: 10/5814d5cd5c8adb31500d0f6358c99c91e2e124ce1c12412d34ef03eab6c8b0cf5c385b6bf8c6a36c5de1fe363d075b736bae0560ae30460b6d6ae76b3e732d32 languageName: node linkType: hard -"@smithy/middleware-retry@npm:^2.1.4, @smithy/middleware-retry@npm:^2.2.0, @smithy/middleware-retry@npm:^2.3.0": - version: 2.3.0 - resolution: "@smithy/middleware-retry@npm:2.3.0" +"@smithy/middleware-retry@npm:^2.1.4, @smithy/middleware-retry@npm:^2.3.1": + version: 2.3.1 + resolution: "@smithy/middleware-retry@npm:2.3.1" dependencies: "@smithy/node-config-provider": "npm:^2.3.0" "@smithy/protocol-http": "npm:^3.3.0" "@smithy/service-error-classification": "npm:^2.1.5" - "@smithy/smithy-client": "npm:^2.5.0" + "@smithy/smithy-client": "npm:^2.5.1" "@smithy/types": "npm:^2.12.0" "@smithy/util-middleware": "npm:^2.2.0" "@smithy/util-retry": "npm:^2.2.0" tslib: "npm:^2.6.2" uuid: "npm:^9.0.1" - checksum: 10/07db583e98f9cf2c6cae43a00431058d447d2f49529972c2bc02b014fec2e55597f46fa7a699efa0de77467fdaf18c86df39621e03109bb36a02ea8f1a4fe2b2 + checksum: 10/efb8b40a84f03befcc420c39df53669a5447d158fddc04f6f6ba5f9220df89c289830ae17f08613b82701b7201a2016a3fd5a234f1c18a37cb27778f5d12ff6a languageName: node linkType: hard @@ -12905,11 +12655,10 @@ __metadata: languageName: node linkType: hard -"@smithy/signature-v4@npm:^2.1.3, @smithy/signature-v4@npm:^2.2.0": - version: 2.2.0 - resolution: "@smithy/signature-v4@npm:2.2.0" +"@smithy/signature-v4@npm:^2.1.3, @smithy/signature-v4@npm:^2.2.1": + version: 2.2.1 + resolution: "@smithy/signature-v4@npm:2.2.1" dependencies: - "@smithy/eventstream-codec": "npm:^2.2.0" "@smithy/is-array-buffer": "npm:^2.2.0" "@smithy/types": "npm:^2.12.0" "@smithy/util-hex-encoding": "npm:^2.2.0" @@ -12917,21 +12666,21 @@ __metadata: "@smithy/util-uri-escape": "npm:^2.2.0" "@smithy/util-utf8": "npm:^2.3.0" tslib: "npm:^2.6.2" - checksum: 10/c1d356c73d7641a9f5636e0598fcc5a7e4a06d2a464a39f1cb0a9104b8f0166291e37ee1afd158c7815d933a01d6a2ba5b08090f055d177094ac8690a58bbd93 + checksum: 10/ee85a1e0d69b4f125960d499d1aa7ac3c270a070b0a433c3c2b58aae4c6eb5c74f56130fb41f2317583ed9151553d8c704d4d396d9e555558d7e064a5ef1fd3b languageName: node linkType: hard -"@smithy/smithy-client@npm:^2.4.2, @smithy/smithy-client@npm:^2.5.0": - version: 2.5.0 - resolution: "@smithy/smithy-client@npm:2.5.0" +"@smithy/smithy-client@npm:^2.4.2, @smithy/smithy-client@npm:^2.5.1": + version: 2.5.1 + resolution: "@smithy/smithy-client@npm:2.5.1" dependencies: - "@smithy/middleware-endpoint": "npm:^2.5.0" + "@smithy/middleware-endpoint": "npm:^2.5.1" "@smithy/middleware-stack": "npm:^2.2.0" "@smithy/protocol-http": "npm:^3.3.0" "@smithy/types": "npm:^2.12.0" "@smithy/util-stream": "npm:^2.2.0" tslib: "npm:^2.6.2" - checksum: 10/ea12f139b6967d477b42b0af634861f1d4040cdeeef2cfea87c213845e202db63231a2a967048e799c756f5f84bb292cfbe90df2cec338c287d1324cff4e79f9 + checksum: 10/d2a492bb01ce2d6e2f1ae61f287d596541a8c1664333c551481d64b58c61552a531338f0d6a68b481315bc18f323b5b67b884d2e13420411dd3025bdeb550849 languageName: node linkType: hard @@ -13003,31 +12752,31 @@ __metadata: languageName: node linkType: hard -"@smithy/util-defaults-mode-browser@npm:^2.1.4, @smithy/util-defaults-mode-browser@npm:^2.2.0": - version: 2.2.0 - resolution: "@smithy/util-defaults-mode-browser@npm:2.2.0" +"@smithy/util-defaults-mode-browser@npm:^2.1.4, @smithy/util-defaults-mode-browser@npm:^2.2.1": + version: 2.2.1 + resolution: "@smithy/util-defaults-mode-browser@npm:2.2.1" dependencies: "@smithy/property-provider": "npm:^2.2.0" - "@smithy/smithy-client": "npm:^2.5.0" + "@smithy/smithy-client": "npm:^2.5.1" "@smithy/types": "npm:^2.12.0" bowser: "npm:^2.11.0" tslib: "npm:^2.6.2" - checksum: 10/06def0134965de01a35ba1a814d83a464b9d752974109a306588418a643a4205a716635cd4b97a3fc80af4a74c1e82550221f6d1ebea3c8e0d7106d8647e240d + checksum: 10/83b9ece1c7dbd213b67ac4d2221422c2655ca3a339245fc9da9c9648ba42f07a4484f4ec571b4d72ad1aa6f026141cec72fdcafe40337d6ca2e671b726843644 languageName: node linkType: hard -"@smithy/util-defaults-mode-node@npm:^2.2.3, @smithy/util-defaults-mode-node@npm:^2.3.0": - version: 2.3.0 - resolution: "@smithy/util-defaults-mode-node@npm:2.3.0" +"@smithy/util-defaults-mode-node@npm:^2.2.3, @smithy/util-defaults-mode-node@npm:^2.3.1": + version: 2.3.1 + resolution: "@smithy/util-defaults-mode-node@npm:2.3.1" dependencies: "@smithy/config-resolver": "npm:^2.2.0" "@smithy/credential-provider-imds": "npm:^2.3.0" "@smithy/node-config-provider": "npm:^2.3.0" "@smithy/property-provider": "npm:^2.2.0" - "@smithy/smithy-client": "npm:^2.5.0" + "@smithy/smithy-client": "npm:^2.5.1" "@smithy/types": "npm:^2.12.0" tslib: "npm:^2.6.2" - checksum: 10/2dab5c7b346b128d50ef7c4e7d80d4dbe8f7ba1578bf0ae3b78ea0c6dd6c02778e8b8c71d880163f835be6cc9ee435b55d645fd0f5cae3983765990d3115079d + checksum: 10/6fedcb39e722d424c56100e1ff3a789459214c9756611d3ce7b48c3d4ffe18f0caf8cc144c912e0df69bf1d715cefef6af3c0945da1aa173fa89aa3f7dd45db6 languageName: node linkType: hard @@ -13150,7 +12899,7 @@ __metadata: languageName: node linkType: hard -"@solidity-parser/parser@npm:^0.14.0, @solidity-parser/parser@npm:^0.14.1": +"@solidity-parser/parser@npm:^0.14.0, @solidity-parser/parser@npm:^0.14.1, @solidity-parser/parser@npm:^0.14.3": version: 0.14.5 resolution: "@solidity-parser/parser@npm:0.14.5" dependencies: @@ -13719,19 +13468,6 @@ __metadata: languageName: node linkType: hard -"@storybook/addon-postcss@npm:3.0.0-alpha.1": - version: 3.0.0-alpha.1 - resolution: "@storybook/addon-postcss@npm:3.0.0-alpha.1" - dependencies: - "@storybook/node-logger": "npm:^6.1.14" - css-loader: "npm:^3.6.0" - postcss: "npm:^7.0.35" - postcss-loader: "npm:^4.2.0" - style-loader: "npm:^1.3.0" - checksum: 10/745ed2445e154514eca43fc54aecc16d83862a86bcd5492ae13c9e127c9f2037259ef9f4368445762dbc2b4f805ff3db79d565e952e8a1c3ed601476e54c05b6 - languageName: node - linkType: hard - "@storybook/addon-toolbars@npm:7.0.18": version: 7.0.18 resolution: "@storybook/addon-toolbars@npm:7.0.18" @@ -14624,19 +14360,6 @@ __metadata: languageName: node linkType: hard -"@storybook/node-logger@npm:^6.1.14": - version: 6.5.16 - resolution: "@storybook/node-logger@npm:6.5.16" - dependencies: - "@types/npmlog": "npm:^4.1.2" - chalk: "npm:^4.1.0" - core-js: "npm:^3.8.2" - npmlog: "npm:^5.0.1" - pretty-hrtime: "npm:^1.0.3" - checksum: 10/c4b6da5a4e57ce0dcd7fef1e2050a175f8dcd329d9f8c3dc231477a402e05e897d172191ccd9078ba570eca0d73b0378e4a88452c1956fa98cbf147041a4af57 - languageName: node - linkType: hard - "@storybook/postinstall@npm:7.0.18": version: 7.0.18 resolution: "@storybook/postinstall@npm:7.0.18" @@ -15237,15 +14960,6 @@ __metadata: languageName: node linkType: hard -"@swc/helpers@npm:0.5.1": - version: 0.5.1 - resolution: "@swc/helpers@npm:0.5.1" - dependencies: - tslib: "npm:^2.4.0" - checksum: 10/4954c4d2dd97bf965e863a10ffa44c3fdaf7653f2fa9ef1a6cf7ffffd67f3f832216588f9751afd75fdeaea60c4688c75c01e2405119c448f1a109c9a7958c54 - languageName: node - linkType: hard - "@swc/helpers@npm:0.5.2": version: 0.5.2 resolution: "@swc/helpers@npm:0.5.2" @@ -15927,14 +15641,14 @@ __metadata: linkType: hard "@types/express-serve-static-core@npm:*, @types/express-serve-static-core@npm:^4.17.33": - version: 4.17.43 - resolution: "@types/express-serve-static-core@npm:4.17.43" + version: 4.19.0 + resolution: "@types/express-serve-static-core@npm:4.19.0" dependencies: "@types/node": "npm:*" "@types/qs": "npm:*" "@types/range-parser": "npm:*" "@types/send": "npm:*" - checksum: 10/9079e137470e0456bb8e77ae66df9505ee12591e94860bde574cfe52c5c60bbc5bf7dd44f5689c3cbb1baf0aa84442d9a21f53dcd921d18745727293cd5a5fd6 + checksum: 10/3e803822f90106158e2c7598d0a44e078e22fad67806eadb1e9f00261fa2be7ea65725d9d177157225d2b0ab22793a84039a433c2d97910586ae6f79e9d04c2f languageName: node linkType: hard @@ -16353,11 +16067,11 @@ __metadata: linkType: hard "@types/node@npm:*, @types/node@npm:>=13.7.0, @types/node@npm:>=8.1.0": - version: 20.12.3 - resolution: "@types/node@npm:20.12.3" + version: 20.12.7 + resolution: "@types/node@npm:20.12.7" dependencies: undici-types: "npm:~5.26.4" - checksum: 10/3f3c5c6ba118a18aa997c51cdc3c66259d69021f87475a99ed6c913a6956e22de49748e09843bf6447a7a63ae474e61945a6dbcca93e23b2359fc0b6f9914f7a + checksum: 10/b4a28a3b593a9bdca5650880b6a9acef46911d58cf7cfa57268f048e9a7157a7c3196421b96cea576850ddb732e3b54bc982c8eb5e1e5ef0635d4424c2fce801 languageName: node linkType: hard @@ -16408,9 +16122,9 @@ __metadata: linkType: hard "@types/node@npm:^16.0.0": - version: 16.18.94 - resolution: "@types/node@npm:16.18.94" - checksum: 10/a6f32e8386d78ee0a0c8e2a336e887b4367a9a29991be776b40c587a58bddb8faf0e4bf6011e43e9773453d38e047be2467bb1ec10beed72d36cb3d26982cfee + version: 16.18.96 + resolution: "@types/node@npm:16.18.96" + checksum: 10/6b6d1250c777f40bbc665024b13912c8f65ebe64e7dfe8369084aa65a8ebeaec7037f7a87f280b211bdb0b2b8a4173619be89e642962a1f58690d3bac08bfa33 languageName: node linkType: hard @@ -16422,11 +16136,11 @@ __metadata: linkType: hard "@types/node@npm:^18.0.0": - version: 18.19.29 - resolution: "@types/node@npm:18.19.29" + version: 18.19.31 + resolution: "@types/node@npm:18.19.31" dependencies: undici-types: "npm:~5.26.4" - checksum: 10/9a3572b488f875ca1b545cc96980f1cb54dd05da16b2dc0cc3c3cb49ceafc3a5e417f4741c711c7bb81a67a0ddd29f546dcb077e4cb9b98a492fbaf373b1fbdc + checksum: 10/654194d4f3cc5867e5525a39647773a12c0c7175972bc4d288cdc74991fc969be2a9689267a3dc1cc5c5c7617e8f7c4769ac4829525726cd3e2f60eb238c1ff4 languageName: node linkType: hard @@ -16477,13 +16191,13 @@ __metadata: linkType: hard "@types/pg@npm:>=6 <9": - version: 8.11.4 - resolution: "@types/pg@npm:8.11.4" + version: 8.11.5 + resolution: "@types/pg@npm:8.11.5" dependencies: "@types/node": "npm:*" pg-protocol: "npm:*" pg-types: "npm:^4.0.1" - checksum: 10/b2713bc4ec8e7245958d8ced5833e5fbf3b7bdc090c19b1967f49626abf79cfe62a14e36b194c48c9fc9edeeeb3d4308cfa716534e6ca318b0785daaeb32e359 + checksum: 10/bb4c28f721ab0da9df96ecf9e2ebb34c3986b2c785e763612c899292bfd0e4e364f38ae10c0a35144d1e647d51cb9a2a80eb900a4ee1f1fdcc3e8d54d39c5abf languageName: node linkType: hard @@ -16571,11 +16285,11 @@ __metadata: linkType: hard "@types/react-dom@npm:^18.0.0": - version: 18.2.23 - resolution: "@types/react-dom@npm:18.2.23" + version: 18.2.24 + resolution: "@types/react-dom@npm:18.2.24" dependencies: "@types/react": "npm:*" - checksum: 10/8311c67767b0aafb5cd94176a90f801f0f5f6930731d57caaa04bb0d87fdef6bc6f723a116d9777d2082ec022682acaad7a62d04dc27e330e818cf34f2ef2703 + checksum: 10/bbd4005f2f65b7606505e9b8759b6e99e222d503602765594ea327893fb7061de8951279baef47a1932f04d94d1865daea05a32f9fcf6f9f1143dbabce5b33de languageName: node linkType: hard @@ -16640,12 +16354,12 @@ __metadata: linkType: hard "@types/react@npm:*, @types/react@npm:>=16": - version: 18.2.74 - resolution: "@types/react@npm:18.2.74" + version: 18.2.75 + resolution: "@types/react@npm:18.2.75" dependencies: "@types/prop-types": "npm:*" csstype: "npm:^3.0.2" - checksum: 10/4057aa7d082d434f8e580e5aebd4007e5dbe7f8e9ae5e506a34a629e382070694a0401bf3f0d38fe8d64f4b38622e5794341e634b9739784deae19b037ae43fa + checksum: 10/d609cdc52d3c89871e0b1b0a77ed2d4077c1393709d0ac51a03b04c17704eb337484405aa646b193ac0c54f4fb286e311739b243ce50023ef8ba5bed422a0e8b languageName: node linkType: hard @@ -16681,6 +16395,13 @@ __metadata: languageName: node linkType: hard +"@types/remove-markdown@npm:0.3.4": + version: 0.3.4 + resolution: "@types/remove-markdown@npm:0.3.4" + checksum: 10/a748714a63cb02e96828750e27a679866420bde21411008ae266b6f43c819dea562233714dac0072776d5efd7871d54cf73ac54e3615747cbeddd348bde9e840 + languageName: node + linkType: hard + "@types/request-promise-native@npm:1.0.21": version: 1.0.21 resolution: "@types/request-promise-native@npm:1.0.21" @@ -17201,7 +16922,7 @@ __metadata: languageName: node linkType: hard -"@typescript-eslint/typescript-estree@npm:^5.59.5": +"@typescript-eslint/typescript-estree@npm:^5.62.0": version: 5.62.0 resolution: "@typescript-eslint/typescript-estree@npm:5.62.0" dependencies: @@ -17318,9 +17039,9 @@ __metadata: linkType: hard "@uniswap/default-token-list@npm:^11.2.0": - version: 11.16.0 - resolution: "@uniswap/default-token-list@npm:11.16.0" - checksum: 10/3d20f2e2d21406c49ccf15d5925b570b70da60735da09c8bee96dab8250226e6ed73b0c1268e64c34b7e8049ebf62b4492114fc03e702799c83fc928282d7928 + version: 11.17.0 + resolution: "@uniswap/default-token-list@npm:11.17.0" + checksum: 10/63edf84a3ac7f3e1d1937df0f865e1668d13f328a070a2382676d04d7c2b7a808f7e457699bd7c39fa514f5b5dcdcf5b35165cd00b3fbd59acc3065d90b894db languageName: node linkType: hard @@ -17602,8 +17323,7 @@ __metadata: "@storybook/addon-docs": "npm:7.0.18" "@storybook/addon-essentials": "npm:7.0.18" "@storybook/addon-links": "npm:7.0.18" - "@storybook/addon-postcss": "npm:3.0.0-alpha.1" - "@storybook/react": "npm:7.0.18" + "@storybook/react": "npm:7.6.3" "@storybook/react-vite": "npm:7.0.18" "@types/react": "npm:18.2.46" "@types/react-dom": "npm:18.2.18" @@ -17628,9 +17348,10 @@ __metadata: resolution: "@unlock-protocol/docs@workspace:docs" dependencies: "@babel/helper-get-function-arity": "npm:7.16.7" - "@docusaurus/core": "npm:3.1.1" - "@docusaurus/plugin-client-redirects": "npm:3.1.1" - "@docusaurus/plugin-content-docs": "npm:3.1.1" + "@cookbookdev/docsbot": "npm:4.5.0" + "@docusaurus/core": "npm:3.2.1" + "@docusaurus/plugin-client-redirects": "npm:3.2.1" + "@docusaurus/plugin-content-docs": "npm:3.2.1" "@flockler/react-flockler-embed": "npm:1.0.4" "@mdx-js/react": "npm:3.0.1" "@unlock-protocol/networks": "workspace:./packages/networks" @@ -17680,6 +17401,9 @@ __metadata: version: 0.0.0-use.local resolution: "@unlock-protocol/governance@workspace:governance" dependencies: + "@arbitrum/nitro-contracts": "npm:1.0.2" + "@arbitrum/sdk": "npm:3.3.3" + "@eth-optimism/sdk": "npm:3.3.0" "@matterlabs/hardhat-zksync-deploy": "npm:1.1.2" "@matterlabs/hardhat-zksync-solc": "npm:1.1.0" "@matterlabs/hardhat-zksync-upgradable": "npm:1.2.4" @@ -17698,8 +17422,10 @@ __metadata: "@unlock-protocol/hardhat-helpers": "workspace:^" "@unlock-protocol/hardhat-plugin": "workspace:^" "@unlock-protocol/networks": "workspace:./packages/networks" + arb-shared-dependencies: "npm:1.0.0" eslint: "npm:8.54.0" ethers: "npm:6.10.0" + ethers5: "npm:ethers@5" fs-extra: "npm:11.2.0" hardhat: "npm:2.20.1" solhint: "npm:4.5.2" @@ -17769,8 +17495,8 @@ __metadata: resolution: "@unlock-protocol/locksmith@workspace:locksmith" dependencies: "@aws-sdk/client-s3": "npm:3.525.0" - "@logtail/node": "npm:0.4.19" - "@logtail/winston": "npm:0.4.12" + "@logtail/node": "npm:0.4.21" + "@logtail/winston": "npm:0.4.21" "@nuintun/qrcode": "npm:4.1.2" "@openzeppelin/defender-relay-client": "npm:1.54.1" "@resvg/resvg-js": "npm:2.4.1" @@ -17878,10 +17604,10 @@ __metadata: "@unlock-protocol/paywall": "workspace:./packages/paywall" "@unlock-protocol/tsconfig": "workspace:./packages/tsconfig" eslint: "npm:8.54.0" - next: "npm:14.0.4" + next: "npm:14.1.4" prettier: "npm:3.1.0" typescript: "npm:5.3.3" - vite: "npm:5.0.12" + vite: "npm:5.0.13" vite-plugin-node-polyfills: "npm:0.21.0" languageName: unknown linkType: soft @@ -17899,7 +17625,7 @@ __metadata: postmate: "npm:1.5.2" tsup: "npm:8.0.2" typescript: "npm:5.3.3" - vite: "npm:5.0.12" + vite: "npm:5.0.13" vite-plugin-css-injected-by-js: "npm:3.2.1" vite-plugin-node-polyfills: "npm:0.21.0" vitest: "npm:0.33.0" @@ -17998,7 +17724,6 @@ __metadata: "@storybook/addon-docs": "npm:7.6.3" "@storybook/addon-essentials": "npm:7.6.3" "@storybook/addon-links": "npm:7.6.3" - "@storybook/addon-postcss": "npm:3.0.0-alpha.1" "@storybook/react": "npm:7.6.3" "@storybook/react-vite": "npm:7.6.3" "@tailwindcss/aspect-ratio": "npm:0.4.2" @@ -18029,7 +17754,7 @@ __metadata: tsx: "npm:4.7.1" typescript: "npm:5.3.3" url-loader: "npm:4.1.1" - vite: "npm:5.0.12" + vite: "npm:5.0.13" vite-plugin-node-polyfills: "npm:0.19.0" vite-plugin-svgr: "npm:4.2.0" vite-tsconfig-paths: "npm:4.3.2" @@ -18044,6 +17769,7 @@ __metadata: version: 0.0.0-use.local resolution: "@unlock-protocol/unlock-app@workspace:unlock-app" dependencies: + "@airstack/airstack-react": "npm:0.6.2" "@crossmint/client-sdk-react-ui": "npm:1.1.5" "@enzoferey/ethers-error-parser": "npm:0.2.3" "@guildxyz/sdk": "npm:1.1.1" @@ -18065,6 +17791,7 @@ __metadata: "@types/react": "npm:18.2.52" "@types/react-google-recaptcha": "npm:2.1.9" "@types/react-gtm-module": "npm:2.0.3" + "@types/remove-markdown": "npm:0.3.4" "@uniswap/sdk-core": "npm:4.2.0" "@uniswap/smart-order-router": "npm:3.17.4" "@unlock-protocol/core": "workspace:./packages/core" @@ -18098,7 +17825,7 @@ __metadata: graphql: "npm:16.8.1" jsdom: "npm:24.0.0" lottie-react: "npm:2.4.0" - next: "npm:13.4.19" + next: "npm:14.1.4" next-seo: "npm:6.1.0" node-forge: "npm:1.3.1" postcss: "npm:8.4.38" @@ -18124,6 +17851,7 @@ __metadata: react-use-clipboard: "npm:1.0.9" remark-html: "npm:16.0.1" remark-parse: "npm:11.0.0" + remove-markdown: "npm:0.5.0" siwe: "npm:2.1.4" tailwind-merge: "npm:2.2.2" tailwindcss: "npm:3.3.5" @@ -18841,12 +18569,12 @@ __metadata: linkType: hard "@walletconnect/logger@npm:^2.0.1": - version: 2.1.0 - resolution: "@walletconnect/logger@npm:2.1.0" + version: 2.1.2 + resolution: "@walletconnect/logger@npm:2.1.2" dependencies: "@walletconnect/safe-json": "npm:^1.0.2" pino: "npm:7.11.0" - checksum: 10/26ebd689b35359b7510479085fc6f210015f223c04ed7804b8974d41379d5cff72b9bce0876e1cdccfae7eb1a12af7ba0f30a5e80621c84ad3fe95f89f51532f + checksum: 10/2e6d438bd352595fff6691712c83953e3ad6b2b9ab298c5a8b670a024f53a3f744b165e5aa081a79261ee4801b93b6c60698a39947d613d49a8f6e6215ecd4c2 languageName: node linkType: hard @@ -19497,6 +19225,13 @@ __metadata: languageName: node linkType: hard +"@yarnpkg/lockfile@npm:^1.1.0": + version: 1.1.0 + resolution: "@yarnpkg/lockfile@npm:1.1.0" + checksum: 10/cd19e1114aaf10a05126aeea8833ef4ca8af8a46e88e12884f8359d19333fd19711036dbc2698dbe937f81f037070cf9a8da45c2e8c6ca19cafd7d15659094ed + languageName: node + linkType: hard + "@zeit/next-source-maps@npm:0.0.3": version: 0.0.3 resolution: "@zeit/next-source-maps@npm:0.0.3" @@ -19774,6 +19509,20 @@ __metadata: languageName: node linkType: hard +"ajv-formats@npm:^3.0.1": + version: 3.0.1 + resolution: "ajv-formats@npm:3.0.1" + dependencies: + ajv: "npm:^8.0.0" + peerDependencies: + ajv: ^8.0.0 + peerDependenciesMeta: + ajv: + optional: true + checksum: 10/5679b9f9ced9d0213a202a37f3aa91efcffe59a6de1a6e3da5c873344d3c161820a1f11cc29899661fee36271fd2895dd3851b6461c902a752ad661d1c1e8722 + languageName: node + linkType: hard + "ajv-keywords@npm:^3.4.1, ajv-keywords@npm:^3.5.2": version: 3.5.2 resolution: "ajv-keywords@npm:3.5.2" @@ -20227,6 +19976,16 @@ __metadata: languageName: node linkType: hard +"arb-shared-dependencies@npm:1.0.0": + version: 1.0.0 + resolution: "arb-shared-dependencies@npm:1.0.0" + dependencies: + dotenv: "npm:^8.2.0" + eslint-plugin-prettier: "npm:^3.4.0" + checksum: 10/1a658de6423e14ef1020673ad8a07188054dc4bf24a9780b5d46cff12de4c40521c233b2cbc0d09e37d10b96b5ad0b476eebea3fa9f2de0c47dcca84b6f956e1 + languageName: node + linkType: hard + "archiver-utils@npm:^2.1.0": version: 2.1.0 resolution: "archiver-utils@npm:2.1.0" @@ -20799,6 +20558,15 @@ __metadata: languageName: node linkType: hard +"async-mutex@npm:^0.4.0": + version: 0.4.1 + resolution: "async-mutex@npm:0.4.1" + dependencies: + tslib: "npm:^2.4.0" + checksum: 10/7e9f77b112b8545beb6612493fae4a8d9d1d6c3f24fc22f4d6d05ce96d1e8d326ac3e743a804cc6d7bf24e7ef0267afb65bb127f99b2e433609684b38933ff1c + languageName: node + linkType: hard + "async-retry@npm:^1.3.1, async-retry@npm:^1.3.3": version: 1.3.3 resolution: "async-retry@npm:1.3.3" @@ -21597,7 +21365,7 @@ __metadata: languageName: node linkType: hard -"bignumber.js@npm:^9.0.0, bignumber.js@npm:^9.0.2": +"bignumber.js@npm:^9.0.0, bignumber.js@npm:^9.0.1, bignumber.js@npm:^9.0.2": version: 9.1.2 resolution: "bignumber.js@npm:9.1.2" checksum: 10/d89b8800a987225d2c00dcbf8a69dc08e92aa0880157c851c287b307d31ceb2fc2acb0c62c3e3a3d42b6c5fcae9b004035f13eb4386e56d529d7edac18d5c9d8 @@ -22208,6 +21976,13 @@ __metadata: languageName: node linkType: hard +"buffer-reverse@npm:^1.0.1": + version: 1.0.1 + resolution: "buffer-reverse@npm:1.0.1" + checksum: 10/e350872a89b17af0a7e1bd7a73239a535164f3f010b0800add44f2e52bd0511548dc5b96c20309effba969868c385023d2d02a0add6155f6a76da7b3073b77bd + languageName: node + linkType: hard + "buffer-to-arraybuffer@npm:^0.0.5": version: 0.0.5 resolution: "buffer-to-arraybuffer@npm:0.0.5" @@ -22273,6 +22048,13 @@ __metadata: languageName: node linkType: hard +"bufio@npm:^1.0.7": + version: 1.2.1 + resolution: "bufio@npm:1.2.1" + checksum: 10/c8920ee0d765eb97d218643705346c3360ae6227414df7b3f345932531b85d18fe385d0740e1bcda6225fa082a179910679f444a6de5aec7aecd176a01e40573 + languageName: node + linkType: hard + "buildcheck@npm:~0.0.6": version: 0.0.6 resolution: "buildcheck@npm:0.0.6" @@ -22302,11 +22084,11 @@ __metadata: linkType: hard "builtins@npm:^5.0.0": - version: 5.0.1 - resolution: "builtins@npm:5.0.1" + version: 5.1.0 + resolution: "builtins@npm:5.1.0" dependencies: semver: "npm:^7.0.0" - checksum: 10/90136fa0ba98b7a3aea33190b1262a5297164731efb6a323b0231acf60cc2ea0b2b1075dbf107038266b8b77d6045fa9631d1c3f90efc1c594ba61218fbfbb4c + checksum: 10/60aa9969f69656bf6eab82cd74b23ab805f112ae46a54b912bccc1533875760f2d2ce95e0a7d13144e35ada9f0386f17ed4961908bc9434b5a5e21375b1902b2 languageName: node linkType: hard @@ -22613,10 +22395,10 @@ __metadata: languageName: node linkType: hard -"caniuse-lite@npm:^1.0.0, caniuse-lite@npm:^1.0.30001406, caniuse-lite@npm:^1.0.30001579, caniuse-lite@npm:^1.0.30001587, caniuse-lite@npm:^1.0.30001599": - version: 1.0.30001605 - resolution: "caniuse-lite@npm:1.0.30001605" - checksum: 10/c5671465d7301ecea515698e6b680f20933d1c5351c0381b6ef1a14bf911b3f1f8b7633eedc10339268036f0a63d703bc8d36071412f89495b48630f01a21fe5 +"caniuse-lite@npm:^1.0.0, caniuse-lite@npm:^1.0.30001579, caniuse-lite@npm:^1.0.30001587, caniuse-lite@npm:^1.0.30001599": + version: 1.0.30001607 + resolution: "caniuse-lite@npm:1.0.30001607" + checksum: 10/caab9ae1aa343e72da935c071041344c80338d8a12bd12a90b7d46eb8a97c7620dac72e95c994b94ce82d63f2f27151dab49206864620d8bfd7aa99f7fc75c83 languageName: node linkType: hard @@ -22734,7 +22516,7 @@ __metadata: languageName: node linkType: hard -"chai@npm:^4.3.10, chai@npm:^4.3.6, chai@npm:^4.3.7": +"chai@npm:^4.3.10, chai@npm:^4.3.4, chai@npm:^4.3.6, chai@npm:^4.3.7": version: 4.4.1 resolution: "chai@npm:4.4.1" dependencies: @@ -22877,6 +22659,13 @@ __metadata: languageName: node linkType: hard +"character-entities-legacy@npm:^1.0.0": + version: 1.1.4 + resolution: "character-entities-legacy@npm:1.1.4" + checksum: 10/fe03a82c154414da3a0c8ab3188e4237ec68006cbcd681cf23c7cfb9502a0e76cd30ab69a2e50857ca10d984d57de3b307680fff5328ccd427f400e559c3a811 + languageName: node + linkType: hard + "character-entities-legacy@npm:^3.0.0": version: 3.0.0 resolution: "character-entities-legacy@npm:3.0.0" @@ -22884,6 +22673,13 @@ __metadata: languageName: node linkType: hard +"character-entities@npm:^1.0.0": + version: 1.2.4 + resolution: "character-entities@npm:1.2.4" + checksum: 10/7c11641c48d1891aaba7bc800d4500804d91a28f46d64e88c001c38e6ab2e7eae28873a77ae16e6c55d24cac35ddfbb15efe56c3012b86684a3c4e95c70216b7 + languageName: node + linkType: hard + "character-entities@npm:^2.0.0": version: 2.0.2 resolution: "character-entities@npm:2.0.2" @@ -22891,6 +22687,13 @@ __metadata: languageName: node linkType: hard +"character-reference-invalid@npm:^1.0.0": + version: 1.1.4 + resolution: "character-reference-invalid@npm:1.1.4" + checksum: 10/812ebc5e6e8d08fd2fa5245ae78c1e1a4bea4692e93749d256a135c4a442daf931ca18e067cc61ff4a58a419eae52677126a0bc4f05a511290427d60d3057805 + languageName: node + linkType: hard + "character-reference-invalid@npm:^2.0.0": version: 2.0.1 resolution: "character-reference-invalid@npm:2.0.1" @@ -22942,7 +22745,7 @@ __metadata: languageName: node linkType: hard -"cheerio@npm:^1.0.0-rc.12": +"cheerio@npm:^1.0.0-rc.11, cheerio@npm:^1.0.0-rc.12": version: 1.0.0-rc.12 resolution: "cheerio@npm:1.0.0-rc.12" dependencies: @@ -23403,7 +23206,7 @@ __metadata: languageName: node linkType: hard -"clsx@npm:2.1.0, clsx@npm:^2.0.0": +"clsx@npm:2.1.0, clsx@npm:^2.0.0, clsx@npm:^2.1.0": version: 2.1.0 resolution: "clsx@npm:2.1.0" checksum: 10/2e0ce7c3b6803d74fc8147c408f88e79245583202ac14abd9691e2aebb9f312de44270b79154320d10bb7804a9197869635d1291741084826cff20820f31542b @@ -23585,6 +23388,13 @@ __metadata: languageName: node linkType: hard +"comma-separated-tokens@npm:^1.0.0": + version: 1.0.8 + resolution: "comma-separated-tokens@npm:1.0.8" + checksum: 10/0adcb07174fa4d08cf0f5c8e3aec40a36b5ff0c2c720e5e23f50fe02e6789d1d00a67036c80e0c1e1539f41d3e7f0101b074039dd833b4e4a59031b659d6ca0d + languageName: node + linkType: hard + "comma-separated-tokens@npm:^2.0.0": version: 2.0.3 resolution: "comma-separated-tokens@npm:2.0.3" @@ -23686,7 +23496,7 @@ __metadata: languageName: node linkType: hard -"commander@npm:^9.0.0, commander@npm:^9.3.0, commander@npm:^9.4.0": +"commander@npm:^9.0.0, commander@npm:^9.2.0, commander@npm:^9.3.0, commander@npm:^9.4.0": version: 9.5.0 resolution: "commander@npm:9.5.0" checksum: 10/41c49b3d0f94a1fbeb0463c85b13f15aa15a9e0b4d5e10a49c0a1d58d4489b549d62262b052ae0aa6cfda53299bee487bfe337825df15e342114dde543f82906 @@ -24003,6 +23813,36 @@ __metadata: languageName: node linkType: hard +"convert-svg-core@npm:^0.6.4": + version: 0.6.4 + resolution: "convert-svg-core@npm:0.6.4" + dependencies: + chalk: "npm:^4.1.2" + cheerio: "npm:^1.0.0-rc.11" + commander: "npm:^9.2.0" + file-url: "npm:^3.0.0" + get-stdin: "npm:^8.0.0" + glob: "npm:^8.0.1" + lodash.omit: "npm:^4.5.0" + lodash.pick: "npm:^4.4.0" + pollock: "npm:^0.2.0" + puppeteer: "npm:^13.7.0" + tmp: "npm:^0.2.1" + checksum: 10/0d07df05f5f4d0080ce1f35bbec3457a4954ffa4d7dee13c6394cba0b11a20d2855e2e028318845e2004c5e8cafba431ca647a225e63cdaf592ef78f96c4fa5b + languageName: node + linkType: hard + +"convert-svg-to-png@npm:^0.6.4": + version: 0.6.4 + resolution: "convert-svg-to-png@npm:0.6.4" + dependencies: + convert-svg-core: "npm:^0.6.4" + bin: + convert-svg-to-png: bin/convert-svg-to-png + checksum: 10/272712cfb04c7e68470745f6455abc58c11e21d8806d3265ff844da7877387e212ff9d729922692aa108f19c3a4fd32c231ca35f6d22c90463f3e47d9994dc84 + languageName: node + linkType: hard + "cookie-es@npm:^1.0.0": version: 1.1.0 resolution: "cookie-es@npm:1.1.0" @@ -24166,7 +24006,7 @@ __metadata: languageName: node linkType: hard -"core-js@npm:^3.30.2, core-js@npm:^3.31.1, core-js@npm:^3.8.2": +"core-js@npm:^3.30.2, core-js@npm:^3.31.1": version: 3.36.1 resolution: "core-js@npm:3.36.1" checksum: 10/ce1e1bfc1034b6f2ff7c91077319e8abdd650ee606ffe6e80073e64ab9d8aad2d6a6d953461b01f331a6f796ad2fd766a3386b88aa371b45d44fa7c0b9913ce6 @@ -24394,6 +24234,15 @@ __metadata: languageName: node linkType: hard +"cross-fetch@npm:3.1.5": + version: 3.1.5 + resolution: "cross-fetch@npm:3.1.5" + dependencies: + node-fetch: "npm:2.6.7" + checksum: 10/5d101a3b1e6cb172f0e5e8168cbc927eeff2ef915f33ceef50fed85441df870e1fdff195b56eca36fae8b78ddba5d8e913b8927f73d11b19d27e96301438cd30 + languageName: node + linkType: hard + "cross-fetch@npm:^3.0.4, cross-fetch@npm:^3.0.6, cross-fetch@npm:^3.1.4, cross-fetch@npm:^3.1.5": version: 3.1.8 resolution: "cross-fetch@npm:3.1.8" @@ -24432,6 +24281,19 @@ __metadata: languageName: node linkType: hard +"cross-spawn@npm:^6.0.5": + version: 6.0.5 + resolution: "cross-spawn@npm:6.0.5" + dependencies: + nice-try: "npm:^1.0.4" + path-key: "npm:^2.0.1" + semver: "npm:^5.5.0" + shebang-command: "npm:^1.2.0" + which: "npm:^1.2.9" + checksum: 10/f07e643b4875f26adffcd7f13bc68d9dff20cf395f8ed6f43a23f3ee24fc3a80a870a32b246fd074e514c8fd7da5f978ac6a7668346eec57aa87bac89c1ed3a1 + languageName: node + linkType: hard + "crossws@npm:^0.2.0, crossws@npm:^0.2.2": version: 0.2.4 resolution: "crossws@npm:0.2.4" @@ -24470,7 +24332,7 @@ __metadata: languageName: node linkType: hard -"crypto-js@npm:^4.1.1": +"crypto-js@npm:^4.1.1, crypto-js@npm:^4.2.0": version: 4.2.0 resolution: "crypto-js@npm:4.2.0" checksum: 10/c7bcc56a6e01c3c397e95aa4a74e4241321f04677f9a618a8f48a63b5781617248afb9adb0629824792e7ec20ca0d4241a49b6b2938ae6f973ec4efc5c53c924 @@ -24543,29 +24405,6 @@ __metadata: languageName: node linkType: hard -"css-loader@npm:^3.6.0": - version: 3.6.0 - resolution: "css-loader@npm:3.6.0" - dependencies: - camelcase: "npm:^5.3.1" - cssesc: "npm:^3.0.0" - icss-utils: "npm:^4.1.1" - loader-utils: "npm:^1.2.3" - normalize-path: "npm:^3.0.0" - postcss: "npm:^7.0.32" - postcss-modules-extract-imports: "npm:^2.0.0" - postcss-modules-local-by-default: "npm:^3.0.2" - postcss-modules-scope: "npm:^2.2.0" - postcss-modules-values: "npm:^3.0.0" - postcss-value-parser: "npm:^4.1.0" - schema-utils: "npm:^2.7.0" - semver: "npm:^6.3.0" - peerDependencies: - webpack: ^4.0.0 || ^5.0.0 - checksum: 10/7de2ac05bc77ed1486e7113a38e4e61bd2fc0264fdaece0b2235e33488f3f53ecd95fc80b689959ea55dbc6982a38a4b6662a7d718f5127735f2477fa433edad - languageName: node - linkType: hard - "css-loader@npm:^6.8.1": version: 6.11.0 resolution: "css-loader@npm:6.11.0" @@ -25857,14 +25696,14 @@ __metadata: linkType: hard "detective-typescript@npm:^11.1.0": - version: 11.1.0 - resolution: "detective-typescript@npm:11.1.0" + version: 11.2.0 + resolution: "detective-typescript@npm:11.2.0" dependencies: - "@typescript-eslint/typescript-estree": "npm:^5.59.5" + "@typescript-eslint/typescript-estree": "npm:^5.62.0" ast-module-types: "npm:^5.0.0" - node-source-walk: "npm:^6.0.1" - typescript: "npm:^5.0.4" - checksum: 10/b9f481b05a85ee71e5c4f0f1eb6892264d12faf287097f730be161fe1a1bc3a21d97f49e7001580084e32e6c59e6339d28d0c66ce2b4db924651f87c09fa253a + node-source-walk: "npm:^6.0.2" + typescript: "npm:^5.4.4" + checksum: 10/e990cf13e0dc1c992ee80f4dfe961ac1ae1a48d42360d150302453547fa28fc012db7c0e73d20c6eea66bb7b2232e7c1304fc6861820f22e3005f86bcf56f67d languageName: node linkType: hard @@ -25877,6 +25716,13 @@ __metadata: languageName: node linkType: hard +"devtools-protocol@npm:0.0.981744": + version: 0.0.981744 + resolution: "devtools-protocol@npm:0.0.981744" + checksum: 10/ec502af20a8806f46d03f5dffaec126e9487c9100cc3a05dfc3159af476484a8589dcea306e121698338c4991d47738af0d621d694bc0758f5f9ebba7b85e562 + languageName: node + linkType: hard + "dezalgo@npm:^1.0.4": version: 1.0.4 resolution: "dezalgo@npm:1.0.4" @@ -26371,6 +26217,13 @@ __metadata: languageName: node linkType: hard +"dotenv@npm:^8.2.0": + version: 8.6.0 + resolution: "dotenv@npm:8.6.0" + checksum: 10/31d7b5c010cebb80046ba6853d703f9573369b00b15129536494f04b0af4ea0060ce8646e3af58b455af2f6f1237879dd261a5831656410ec92561ae1ea44508 + languageName: node + linkType: hard + "dottie@npm:^2.0.4": version: 2.0.6 resolution: "dottie@npm:2.0.6" @@ -26517,9 +26370,9 @@ __metadata: linkType: hard "electron-to-chromium@npm:^1.4.668": - version: 1.4.724 - resolution: "electron-to-chromium@npm:1.4.724" - checksum: 10/0ed96404b76c0499ede838ebc9a4c302af179ac3e4b2046f5cb0be956ad587fece20a72eb358f8d3827cba8e16269284e1b2abb981b376bc0d9647af5573b30e + version: 1.4.731 + resolution: "electron-to-chromium@npm:1.4.731" + checksum: 10/ec73815fd0dc77e6ba74771c6bb57822d5bdef3267f9cc1c80c378c01682afef346b6f2d423b0277ce4635e709788a950716425866df5e1c30ea756724338f26 languageName: node linkType: hard @@ -26750,11 +26603,11 @@ __metadata: linkType: hard "envinfo@npm:^7.7.3": - version: 7.11.1 - resolution: "envinfo@npm:7.11.1" + version: 7.12.0 + resolution: "envinfo@npm:7.12.0" bin: envinfo: dist/cli.js - checksum: 10/5a18ead05954ac1643350170fefce2436a9cb758dc402e36fe4616553ee46469f766fcb6df72379d1741a2e5b55918949b343ff6174502c31c524a5cf75f05cd + checksum: 10/981fbc80d484e42aa2c86d637ab0db773b67c285116561e50f49b5d2cb95cfd7c381d323196c487a1fa95d461ae787857559f08cf68c01be114449527f757df8 languageName: node linkType: hard @@ -27762,6 +27615,21 @@ __metadata: languageName: node linkType: hard +"eslint-plugin-prettier@npm:^3.4.0": + version: 3.4.1 + resolution: "eslint-plugin-prettier@npm:3.4.1" + dependencies: + prettier-linter-helpers: "npm:^1.0.0" + peerDependencies: + eslint: ">=5.0.0" + prettier: ">=1.13.0" + peerDependenciesMeta: + eslint-config-prettier: + optional: true + checksum: 10/d7ab93df9a93f0afb9fa9c9c3cf30479075e1b56303c82ed6efbfff30c2d3d3741537b490c2b517d501bfa97a3d8d0269a1ab4b6fa741a6e966e5811efbfe8b8 + languageName: node + linkType: hard + "eslint-plugin-react-hooks@npm:^4.5.0 || 5.0.0-canary-7118f5dd7-20230705": version: 5.0.0-canary-7118f5dd7-20230705 resolution: "eslint-plugin-react-hooks@npm:5.0.0-canary-7118f5dd7-20230705" @@ -28215,12 +28083,12 @@ __metadata: linkType: hard "estree-util-value-to-estree@npm:^3.0.1": - version: 3.0.1 - resolution: "estree-util-value-to-estree@npm:3.0.1" + version: 3.1.1 + resolution: "estree-util-value-to-estree@npm:3.1.1" dependencies: "@types/estree": "npm:^1.0.0" is-plain-obj: "npm:^4.0.0" - checksum: 10/f78ea726a3542e50b7d589dca53ed03262c1f9a118bafd7fef168409a396ebe6906993678c3a1c727029bca55b517047db3a1a2819d1ec66f3b190b20ddbaf39 + checksum: 10/31e87547ee99aa9f34ffb373badb74ed7bc8156a10acd0a77f88c27b6706630f73d60a6834365cdc9d22e24280cdb5cba557ff3dbc5118f888f996cfa2dd6f58 languageName: node linkType: hard @@ -28434,11 +28302,11 @@ __metadata: linkType: hard "ethereum-bloom-filters@npm:^1.0.6": - version: 1.0.10 - resolution: "ethereum-bloom-filters@npm:1.0.10" + version: 1.1.0 + resolution: "ethereum-bloom-filters@npm:1.1.0" dependencies: - js-sha3: "npm:^0.8.0" - checksum: 10/dc4191c5d810db864ace106886f340b541bf03f1ad3249459ac630cab9c191f1e45c03e935887cca903cca884326e3ac97acfef0a083c7e1a004108f5991f9ba + "@noble/hashes": "npm:^1.4.0" + checksum: 10/fb50448d024723f5817d7fce7d11ed22921b36f2b14b6102fe553721cf073b07f5f0f32ceef1a2a4520b426e5d9cac217b76f5bc8af4b82b4036c2d14b907836 languageName: node linkType: hard @@ -28552,7 +28420,7 @@ __metadata: languageName: node linkType: hard -"ethers@npm:5.7.2, ethers@npm:^5.3.1, ethers@npm:^5.5.4, ethers@npm:^5.6.1, ethers@npm:^5.7.0, ethers@npm:^5.7.2": +"ethers5@npm:ethers@5, ethers@npm:5.7.2, ethers@npm:^5.1.0, ethers@npm:^5.3.1, ethers@npm:^5.5.4, ethers@npm:^5.6.1, ethers@npm:^5.6.9, ethers@npm:^5.7.0, ethers@npm:^5.7.2": version: 5.7.2 resolution: "ethers@npm:5.7.2" dependencies: @@ -29173,17 +29041,17 @@ __metadata: linkType: hard "fast-json-stringify@npm:^5.7.0": - version: 5.13.0 - resolution: "fast-json-stringify@npm:5.13.0" + version: 5.14.0 + resolution: "fast-json-stringify@npm:5.14.0" dependencies: "@fastify/merge-json-schemas": "npm:^0.1.0" ajv: "npm:^8.10.0" - ajv-formats: "npm:^2.1.1" + ajv-formats: "npm:^3.0.1" fast-deep-equal: "npm:^3.1.3" fast-uri: "npm:^2.1.0" json-schema-ref-resolver: "npm:^1.0.1" rfdc: "npm:^1.2.0" - checksum: 10/84820e26749481b7af929926453c77382fb187623f9f08da84102602f5e41301113501a2f0fc9f561673cc97e58a9247848b6574925644f7f54cf0bb6809a885 + checksum: 10/98b4e77b8de8a5874f25fb5b782959baecb1269d1f962c705df0228263f6b3471e987b940d6e6ae5e8ddd58734b66c9473d9b6a612e0c039f62fb8758a0ad6ce languageName: node linkType: hard @@ -29328,6 +29196,15 @@ __metadata: languageName: node linkType: hard +"fault@npm:^1.0.0": + version: 1.0.4 + resolution: "fault@npm:1.0.4" + dependencies: + format: "npm:^0.2.0" + checksum: 10/5ac610d8b09424e0f2fa8cf913064372f2ee7140a203a79957f73ed557c0e79b1a3d096064d7f40bde8132a69204c1fe25ec23634c05c6da2da2039cff26c4e7 + languageName: node + linkType: hard + "fault@npm:^2.0.0": version: 2.0.1 resolution: "fault@npm:2.0.1" @@ -29567,6 +29444,13 @@ __metadata: languageName: node linkType: hard +"file-url@npm:^3.0.0": + version: 3.0.0 + resolution: "file-url@npm:3.0.0" + checksum: 10/f15c1bdd81df1a09238f3411f877274d7849703df837ec327c4d1df631314f60036cb700a59d826d8c96b79ff66429d3c758480005e1899c00961541b98d5bfe + languageName: node + linkType: hard + "filelist@npm:^1.0.4": version: 1.0.4 resolution: "filelist@npm:1.0.4" @@ -29765,6 +29649,15 @@ __metadata: languageName: node linkType: hard +"find-yarn-workspace-root@npm:^2.0.0": + version: 2.0.0 + resolution: "find-yarn-workspace-root@npm:2.0.0" + dependencies: + micromatch: "npm:^4.0.2" + checksum: 10/7fa7942849eef4d5385ee96a0a9a5a9afe885836fd72ed6a4280312a38690afea275e7d09b343fe97daf0412d833f8ac4b78c17fc756386d9ebebf0759d707a7 + languageName: node + linkType: hard + "flat-cache@npm:^3.0.4": version: 3.2.0 resolution: "flat-cache@npm:3.2.0" @@ -30493,6 +30386,13 @@ __metadata: languageName: node linkType: hard +"get-stdin@npm:^8.0.0": + version: 8.0.0 + resolution: "get-stdin@npm:8.0.0" + checksum: 10/40128b6cd25781ddbd233344f1a1e4006d4284906191ed0a7d55ec2c1a3e44d650f280b2c9eeab79c03ac3037da80257476c0e4e5af38ddfb902d6ff06282d77 + languageName: node + linkType: hard + "get-stream@npm:^5.1.0": version: 5.2.0 resolution: "get-stream@npm:5.2.0" @@ -31782,6 +31682,13 @@ __metadata: languageName: node linkType: hard +"hast-util-parse-selector@npm:^2.0.0": + version: 2.2.5 + resolution: "hast-util-parse-selector@npm:2.2.5" + checksum: 10/22ee4afbd11754562144cb3c4f3ec52524dafba4d90ee52512902d17cf11066d83b38f7bdf6ca571bbc2541f07ba30db0d234657b6ecb8ca4631587466459605 + languageName: node + linkType: hard + "hast-util-parse-selector@npm:^3.0.0": version: 3.1.1 resolution: "hast-util-parse-selector@npm:3.1.1" @@ -31930,6 +31837,19 @@ __metadata: languageName: node linkType: hard +"hastscript@npm:^6.0.0": + version: 6.0.0 + resolution: "hastscript@npm:6.0.0" + dependencies: + "@types/hast": "npm:^2.0.0" + comma-separated-tokens: "npm:^1.0.0" + hast-util-parse-selector: "npm:^2.0.0" + property-information: "npm:^5.0.0" + space-separated-tokens: "npm:^1.0.0" + checksum: 10/78f91b71e50506f7499c8275d67645f9f4f130e6f12b038853261d1fa7393432da4113baf3508c41b79d933f255089d6d593beea9d4cda89dfd34d0a498cf378 + languageName: node + linkType: hard + "hastscript@npm:^7.0.0": version: 7.2.0 resolution: "hastscript@npm:7.2.0" @@ -32003,6 +31923,13 @@ __metadata: languageName: node linkType: hard +"highlight.js@npm:^10.4.1, highlight.js@npm:~10.7.0": + version: 10.7.3 + resolution: "highlight.js@npm:10.7.3" + checksum: 10/db8d10a541936b058e221dbde77869664b2b45bca75d660aa98065be2cd29f3924755fbc7348213f17fd931aefb6e6597448ba6fe82afba6d8313747a91983ee + languageName: node + linkType: hard + "highlight.js@npm:^11.5.0": version: 11.9.0 resolution: "highlight.js@npm:11.9.0" @@ -32201,6 +32128,13 @@ __metadata: languageName: node linkType: hard +"html-url-attributes@npm:^3.0.0": + version: 3.0.0 + resolution: "html-url-attributes@npm:3.0.0" + checksum: 10/80c892b013d253a5638318a481b8a5f4f207117da73901f8c50f49b0a37eaaf71cb9e59c9426820f8b455b2429d9056955e17662ebc9fc77da189c5b80d7ea98 + languageName: node + linkType: hard + "html-void-elements@npm:^3.0.0": version: 3.0.0 resolution: "html-void-elements@npm:3.0.0" @@ -32591,15 +32525,6 @@ __metadata: languageName: node linkType: hard -"icss-utils@npm:^4.0.0, icss-utils@npm:^4.1.1": - version: 4.1.1 - resolution: "icss-utils@npm:4.1.1" - dependencies: - postcss: "npm:^7.0.14" - checksum: 10/a4ca2c6b82cb3eb879d635bd4028d74bca174edc49ee48ef5f01988489747d340a389d5a0ac6f6887a5c24ab8fc4386c781daab32a7ade5344a2edff66207635 - languageName: node - linkType: hard - "icss-utils@npm:^5.0.0, icss-utils@npm:^5.1.0": version: 5.1.0 resolution: "icss-utils@npm:5.1.0" @@ -32616,6 +32541,13 @@ __metadata: languageName: node linkType: hard +"idb@npm:^8.0.0": + version: 8.0.0 + resolution: "idb@npm:8.0.0" + checksum: 10/6ff47b46ead4bf02ac3a9145bb2f48bac707b950cf33282a72eec8efcda610ffb0a09aab6eea58450f6c87373060bf50998d307085830a302e9e231eee6cd37d + languageName: node + linkType: hard + "idna-uts46-hx@npm:^2.3.1": version: 2.3.1 resolution: "idna-uts46-hx@npm:2.3.1" @@ -33174,6 +33106,13 @@ __metadata: languageName: node linkType: hard +"is-alphabetical@npm:^1.0.0": + version: 1.0.4 + resolution: "is-alphabetical@npm:1.0.4" + checksum: 10/6508cce44fd348f06705d377b260974f4ce68c74000e7da4045f0d919e568226dc3ce9685c5a2af272195384df6930f748ce9213fc9f399b5d31b362c66312cb + languageName: node + linkType: hard + "is-alphabetical@npm:^2.0.0": version: 2.0.1 resolution: "is-alphabetical@npm:2.0.1" @@ -33181,6 +33120,16 @@ __metadata: languageName: node linkType: hard +"is-alphanumerical@npm:^1.0.0": + version: 1.0.4 + resolution: "is-alphanumerical@npm:1.0.4" + dependencies: + is-alphabetical: "npm:^1.0.0" + is-decimal: "npm:^1.0.0" + checksum: 10/e2e491acc16fcf5b363f7c726f666a9538dba0a043665740feb45bba1652457a73441e7c5179c6768a638ed396db3437e9905f403644ec7c468fb41f4813d03f + languageName: node + linkType: hard + "is-alphanumerical@npm:^2.0.0": version: 2.0.1 resolution: "is-alphanumerical@npm:2.0.1" @@ -33292,6 +33241,17 @@ __metadata: languageName: node linkType: hard +"is-ci@npm:^2.0.0": + version: 2.0.0 + resolution: "is-ci@npm:2.0.0" + dependencies: + ci-info: "npm:^2.0.0" + bin: + is-ci: bin.js + checksum: 10/77b869057510f3efa439bbb36e9be429d53b3f51abd4776eeea79ab3b221337fe1753d1e50058a9e2c650d38246108beffb15ccfd443929d77748d8c0cc90144 + languageName: node + linkType: hard + "is-ci@npm:^3.0.1": version: 3.0.1 resolution: "is-ci@npm:3.0.1" @@ -33339,6 +33299,13 @@ __metadata: languageName: node linkType: hard +"is-decimal@npm:^1.0.0": + version: 1.0.4 + resolution: "is-decimal@npm:1.0.4" + checksum: 10/ed483a387517856dc395c68403a10201fddcc1b63dc56513fbe2fe86ab38766120090ecdbfed89223d84ca8b1cd28b0641b93cb6597b6e8f4c097a7c24e3fb96 + languageName: node + linkType: hard + "is-decimal@npm:^2.0.0": version: 2.0.1 resolution: "is-decimal@npm:2.0.1" @@ -33506,6 +33473,13 @@ __metadata: languageName: node linkType: hard +"is-hexadecimal@npm:^1.0.0": + version: 1.0.4 + resolution: "is-hexadecimal@npm:1.0.4" + checksum: 10/a452e047587b6069332d83130f54d30da4faf2f2ebaa2ce6d073c27b5703d030d58ed9e0b729c8e4e5b52c6f1dab26781bb77b7bc6c7805f14f320e328ff8cd5 + languageName: node + linkType: hard + "is-hexadecimal@npm:^2.0.0": version: 2.0.1 resolution: "is-hexadecimal@npm:2.0.1" @@ -34447,9 +34421,9 @@ __metadata: linkType: hard "jose@npm:^5.0.0": - version: 5.2.3 - resolution: "jose@npm:5.2.3" - checksum: 10/33056092ed6c1539eee6c0c75bd3664a39c639e02f21ec5cb32ddd231b9345f239e7bffe3f4741c903c711e237ceafb816ed634bd9cd5e4fb61b5a1f067e2c40 + version: 5.2.4 + resolution: "jose@npm:5.2.4" + checksum: 10/0b09df51d70dad34d301f444dfe44681a157c5e166df88e4a05892ddd7181e42e883c83ed7fae8a41960237343dd4c72282c4aeb10ec94801782be47e3f62170 languageName: node linkType: hard @@ -34491,6 +34465,15 @@ __metadata: languageName: node linkType: hard +"js-graph-algorithms@npm:^1.0.18": + version: 1.0.18 + resolution: "js-graph-algorithms@npm:1.0.18" + bin: + js-graphs: ./src/jsgraphs.js + checksum: 10/84914d2dc3caacee043f42cf22e156ea9c4c98ce52588a576e33267433853f744894c4ca4b87085a613d6e197898a4eba6e9de7127e277ca1abeba96cc384b81 + languageName: node + linkType: hard + "js-sdsl@npm:^4.1.4": version: 4.4.2 resolution: "js-sdsl@npm:4.4.2" @@ -34869,7 +34852,7 @@ __metadata: languageName: node linkType: hard -"json5@npm:^1.0.1, json5@npm:^1.0.2": +"json5@npm:^1.0.2": version: 1.0.2 resolution: "json5@npm:1.0.2" dependencies: @@ -35263,6 +35246,15 @@ __metadata: languageName: node linkType: hard +"klaw-sync@npm:^6.0.0": + version: 6.0.0 + resolution: "klaw-sync@npm:6.0.0" + dependencies: + graceful-fs: "npm:^4.1.11" + checksum: 10/0da397f8961313c3ef8f79fb63af9002cde5a8fb2aeb1a37351feff0dd6006129c790400c3f5c3b4e757bedcabb13d21ec0a5eaef5a593d59515d4f2c291e475 + languageName: node + linkType: hard + "klaw@npm:^1.0.0": version: 1.3.1 resolution: "klaw@npm:1.3.1" @@ -35275,6 +35267,13 @@ __metadata: languageName: node linkType: hard +"klaw@npm:^4.0.1": + version: 4.1.0 + resolution: "klaw@npm:4.1.0" + checksum: 10/d3ac625e40a917633d89e8079b16d737dfca670d3ac92631a2d0b9005c02ed77721fa39e589d1572695b86331e516876b72fbe805438664e629177cac6c0790e + languageName: node + linkType: hard + "kleur@npm:^3.0.3": version: 3.0.3 resolution: "kleur@npm:3.0.3" @@ -35289,13 +35288,6 @@ __metadata: languageName: node linkType: hard -"klona@npm:^2.0.4": - version: 2.0.6 - resolution: "klona@npm:2.0.6" - checksum: 10/ed7e2c9af58cb646e758e60b75dec24bf72466066290f78c515a2bae23a06fa280f11ff3210c43b94a18744954aa5358f9d46583d5e4c36da073ecc3606355c4 - languageName: node - linkType: hard - "kuler@npm:^2.0.0": version: 2.0.0 resolution: "kuler@npm:2.0.0" @@ -35633,17 +35625,6 @@ __metadata: languageName: node linkType: hard -"loader-utils@npm:^1.2.3": - version: 1.4.2 - resolution: "loader-utils@npm:1.4.2" - dependencies: - big.js: "npm:^5.2.2" - emojis-list: "npm:^3.0.0" - json5: "npm:^1.0.1" - checksum: 10/2ae94cc88ad9cf2991e322b9ddf547cff80cf6fc0f9c77546b258c5ed9f77b0827f64c2625cb0baa06432f1f441bb4744c9ab1e1412ee6f8e97d31f8e9c730d6 - languageName: node - linkType: hard - "loader-utils@npm:^2.0.0": version: 2.0.4 resolution: "loader-utils@npm:2.0.4" @@ -35879,6 +35860,13 @@ __metadata: languageName: node linkType: hard +"lodash.omit@npm:^4.5.0": + version: 4.5.0 + resolution: "lodash.omit@npm:4.5.0" + checksum: 10/f5c67cd1df11f1275662060febb629a4d4e7b547c4bea66454508b5e6096162c2af882aab1ff8cb5dcf2b328f22252416de6ca9c1334588f6310edfac525e511 + languageName: node + linkType: hard + "lodash.pad@npm:^4.5.1": version: 4.5.1 resolution: "lodash.pad@npm:4.5.1" @@ -35900,6 +35888,13 @@ __metadata: languageName: node linkType: hard +"lodash.pick@npm:^4.4.0": + version: 4.4.0 + resolution: "lodash.pick@npm:4.4.0" + checksum: 10/5a76778aa1c245ce081d19c5a625a44cdf4853f421c8789ec962cb5d73dd21be7cf11ae3bc2123ff5f432326ed0176d674d22ca6e0e8f9eaba5b74b00f632c12 + languageName: node + linkType: hard + "lodash.repeat@npm:4.1.0, lodash.repeat@npm:^4.1.0": version: 4.1.0 resolution: "lodash.repeat@npm:4.1.0" @@ -36200,6 +36195,16 @@ __metadata: languageName: node linkType: hard +"lowlight@npm:^1.17.0": + version: 1.20.0 + resolution: "lowlight@npm:1.20.0" + dependencies: + fault: "npm:^1.0.0" + highlight.js: "npm:~10.7.0" + checksum: 10/3294677be15bbc256556f097d9b675f23f14309aceeada7880473c57bdbdd7761f200d903fe26d8fa5e82259f70a39465d1d40754c4c049ad2bbd33d77e2c06f + languageName: node + linkType: hard + "lru-cache@npm:^10.0.0, lru-cache@npm:^10.0.1, lru-cache@npm:^10.2.0": version: 10.2.0 resolution: "lru-cache@npm:10.2.0" @@ -36283,11 +36288,11 @@ __metadata: linkType: hard "magic-string@npm:^0.30.0, magic-string@npm:^0.30.1, magic-string@npm:^0.30.3": - version: 0.30.8 - resolution: "magic-string@npm:0.30.8" + version: 0.30.9 + resolution: "magic-string@npm:0.30.9" dependencies: "@jridgewell/sourcemap-codec": "npm:^1.4.15" - checksum: 10/72ab63817af600e92c19dc8489c1aa4a9599da00cfd59b2319709bd48fb0cf533fdf354bf140ac86e598dbd63e6b2cc83647fe8448f864a3eb6061c62c94e784 + checksum: 10/a49b7f848e36914c2794e443d4da6579abebb3e57a5e98b1603958f4672d1435dc15261f70c2793e9b6d6c891191c83b9608322b48d0d76a9be32e73e039cc8a languageName: node linkType: hard @@ -36406,11 +36411,11 @@ __metadata: linkType: hard "markdown-to-jsx@npm:^7.1.8": - version: 7.4.5 - resolution: "markdown-to-jsx@npm:7.4.5" + version: 7.4.6 + resolution: "markdown-to-jsx@npm:7.4.6" peerDependencies: react: ">= 0.14.0" - checksum: 10/eda0560c32f89ed86ca0ae8aa03f9f60312001f8126d403388d7e57211d2ff28f679a731802b92837414f50ac29103baab27a1d6c2e920d83a1f81b8181681da + checksum: 10/87f8d52b9fdb73c39cbd2744e3a6c97f17a5ab4580f863bce5027409a73d1bf718d39bbcd279230c473199b6cf102a626716d8f19261ea6319388c62bcd64885 languageName: node linkType: hard @@ -36927,6 +36932,19 @@ __metadata: languageName: node linkType: hard +"merkletreejs@npm:^0.3.11": + version: 0.3.11 + resolution: "merkletreejs@npm:0.3.11" + dependencies: + bignumber.js: "npm:^9.0.1" + buffer-reverse: "npm:^1.0.1" + crypto-js: "npm:^4.2.0" + treeify: "npm:^1.1.0" + web3-utils: "npm:^1.3.4" + checksum: 10/a93520ef768648d1e4ebd175182bd3d304270b8eb0700df5be99395fb3ad8805407bdaf3231d13b1649e87de799aa06d71c616db047ad039025764eb23b02244 + languageName: node + linkType: hard + "meros@npm:^1.2.1": version: 1.3.0 resolution: "meros@npm:1.3.0" @@ -38714,7 +38732,7 @@ __metadata: languageName: node linkType: hard -"nanoid@npm:^3.0.2, nanoid@npm:^3.1.20, nanoid@npm:^3.1.23, nanoid@npm:^3.3.1, nanoid@npm:^3.3.3, nanoid@npm:^3.3.4, nanoid@npm:^3.3.6, nanoid@npm:^3.3.7": +"nanoid@npm:^3.0.2, nanoid@npm:^3.1.20, nanoid@npm:^3.1.23, nanoid@npm:^3.3.1, nanoid@npm:^3.3.3, nanoid@npm:^3.3.6, nanoid@npm:^3.3.7": version: 3.3.7 resolution: "nanoid@npm:3.3.7" bin: @@ -38723,6 +38741,15 @@ __metadata: languageName: node linkType: hard +"nanoid@npm:^5.0.5": + version: 5.0.7 + resolution: "nanoid@npm:5.0.7" + bin: + nanoid: bin/nanoid.js + checksum: 10/25ab0b0cf9082ae6747f0f55cec930e6c1cc5975103aa3a5fda44be5720eff57d9b25a8a9850274bfdde8def964b49bf03def71c6aa7ad1cba32787819b79f60 + languageName: node + linkType: hard + "nanomatch@npm:^1.2.9": version: 1.2.13 resolution: "nanomatch@npm:1.2.13" @@ -39127,115 +39154,10 @@ __metadata: languageName: node linkType: hard -"next@npm:13.4.19": - version: 13.4.19 - resolution: "next@npm:13.4.19" - dependencies: - "@next/env": "npm:13.4.19" - "@next/swc-darwin-arm64": "npm:13.4.19" - "@next/swc-darwin-x64": "npm:13.4.19" - "@next/swc-linux-arm64-gnu": "npm:13.4.19" - "@next/swc-linux-arm64-musl": "npm:13.4.19" - "@next/swc-linux-x64-gnu": "npm:13.4.19" - "@next/swc-linux-x64-musl": "npm:13.4.19" - "@next/swc-win32-arm64-msvc": "npm:13.4.19" - "@next/swc-win32-ia32-msvc": "npm:13.4.19" - "@next/swc-win32-x64-msvc": "npm:13.4.19" - "@swc/helpers": "npm:0.5.1" - busboy: "npm:1.6.0" - caniuse-lite: "npm:^1.0.30001406" - postcss: "npm:8.4.14" - styled-jsx: "npm:5.1.1" - watchpack: "npm:2.4.0" - zod: "npm:3.21.4" - peerDependencies: - "@opentelemetry/api": ^1.1.0 - react: ^18.2.0 - react-dom: ^18.2.0 - sass: ^1.3.0 - dependenciesMeta: - "@next/swc-darwin-arm64": - optional: true - "@next/swc-darwin-x64": - optional: true - "@next/swc-linux-arm64-gnu": - optional: true - "@next/swc-linux-arm64-musl": - optional: true - "@next/swc-linux-x64-gnu": - optional: true - "@next/swc-linux-x64-musl": - optional: true - "@next/swc-win32-arm64-msvc": - optional: true - "@next/swc-win32-ia32-msvc": - optional: true - "@next/swc-win32-x64-msvc": - optional: true - peerDependenciesMeta: - "@opentelemetry/api": - optional: true - sass: - optional: true - bin: - next: dist/bin/next - checksum: 10/e5180f07d5d0fd8603ae6f57966c8051a67c69cc07f1d472f1947c82dd1961ec2d57480012f234101f9a0ac90c85839798972efe9b91512417f34db0d2dcbf29 - languageName: node - linkType: hard - -"next@npm:14.0.4": - version: 14.0.4 - resolution: "next@npm:14.0.4" - dependencies: - "@next/env": "npm:14.0.4" - "@next/swc-darwin-arm64": "npm:14.0.4" - "@next/swc-darwin-x64": "npm:14.0.4" - "@next/swc-linux-arm64-gnu": "npm:14.0.4" - "@next/swc-linux-arm64-musl": "npm:14.0.4" - "@next/swc-linux-x64-gnu": "npm:14.0.4" - "@next/swc-linux-x64-musl": "npm:14.0.4" - "@next/swc-win32-arm64-msvc": "npm:14.0.4" - "@next/swc-win32-ia32-msvc": "npm:14.0.4" - "@next/swc-win32-x64-msvc": "npm:14.0.4" - "@swc/helpers": "npm:0.5.2" - busboy: "npm:1.6.0" - caniuse-lite: "npm:^1.0.30001406" - graceful-fs: "npm:^4.2.11" - postcss: "npm:8.4.31" - styled-jsx: "npm:5.1.1" - watchpack: "npm:2.4.0" - peerDependencies: - "@opentelemetry/api": ^1.1.0 - react: ^18.2.0 - react-dom: ^18.2.0 - sass: ^1.3.0 - dependenciesMeta: - "@next/swc-darwin-arm64": - optional: true - "@next/swc-darwin-x64": - optional: true - "@next/swc-linux-arm64-gnu": - optional: true - "@next/swc-linux-arm64-musl": - optional: true - "@next/swc-linux-x64-gnu": - optional: true - "@next/swc-linux-x64-musl": - optional: true - "@next/swc-win32-arm64-msvc": - optional: true - "@next/swc-win32-ia32-msvc": - optional: true - "@next/swc-win32-x64-msvc": - optional: true - peerDependenciesMeta: - "@opentelemetry/api": - optional: true - sass: - optional: true - bin: - next: dist/bin/next - checksum: 10/f119dfed59ba14972759bbc354fd2e99793c5a31689465a5e7cacd329977ed3d259eb756142bef31e96f28a80a00997e76314425faeda4c6fcf4e4ad6c5fa960 +"nice-try@npm:^1.0.4": + version: 1.0.5 + resolution: "nice-try@npm:1.0.5" + checksum: 10/0b4af3b5bb5d86c289f7a026303d192a7eb4417231fe47245c460baeabae7277bcd8fd9c728fb6bd62c30b3e15cd6620373e2cf33353b095d8b403d3e8a15aff languageName: node linkType: hard @@ -39388,6 +39310,20 @@ __metadata: languageName: node linkType: hard +"node-fetch@npm:2.6.7": + version: 2.6.7 + resolution: "node-fetch@npm:2.6.7" + dependencies: + whatwg-url: "npm:^5.0.0" + peerDependencies: + encoding: ^0.1.0 + peerDependenciesMeta: + encoding: + optional: true + checksum: 10/4bc9245383db92c35601a798c9a992fdf38d99920ceac11e0e6512ef3014d188b3807ccb060bc6c4bdb57a145030c73f5b5fd6730f665979f9264bc43ca3afea + languageName: node + linkType: hard + "node-fetch@npm:^2.0.0, node-fetch@npm:^2.6.0, node-fetch@npm:^2.6.1, node-fetch@npm:^2.6.12, node-fetch@npm:^2.6.6, node-fetch@npm:^2.6.7, node-fetch@npm:^2.6.8, node-fetch@npm:^2.7.0": version: 2.7.0 resolution: "node-fetch@npm:2.7.0" @@ -40150,7 +40086,7 @@ __metadata: languageName: node linkType: hard -"open@npm:^7.0.3": +"open@npm:^7.0.3, open@npm:^7.4.2": version: 7.4.2 resolution: "open@npm:7.4.2" dependencies: @@ -40699,6 +40635,20 @@ __metadata: languageName: node linkType: hard +"parse-entities@npm:^2.0.0": + version: 2.0.0 + resolution: "parse-entities@npm:2.0.0" + dependencies: + character-entities: "npm:^1.0.0" + character-entities-legacy: "npm:^1.0.0" + character-reference-invalid: "npm:^1.0.0" + is-alphanumerical: "npm:^1.0.0" + is-decimal: "npm:^1.0.0" + is-hexadecimal: "npm:^1.0.0" + checksum: 10/feb46b516722474797d72331421f3e62856750cfb4f70ba098b36447bf0b169e819cc4fdee53e022874d5f0c81b605d86e1912b9842a70e59a54de2fee81589d + languageName: node + linkType: hard + "parse-entities@npm:^4.0.0": version: 4.0.1 resolution: "parse-entities@npm:4.0.1" @@ -40862,6 +40812,30 @@ __metadata: languageName: node linkType: hard +"patch-package@npm:^6.4.7": + version: 6.5.1 + resolution: "patch-package@npm:6.5.1" + dependencies: + "@yarnpkg/lockfile": "npm:^1.1.0" + chalk: "npm:^4.1.2" + cross-spawn: "npm:^6.0.5" + find-yarn-workspace-root: "npm:^2.0.0" + fs-extra: "npm:^9.0.0" + is-ci: "npm:^2.0.0" + klaw-sync: "npm:^6.0.0" + minimist: "npm:^1.2.6" + open: "npm:^7.4.2" + rimraf: "npm:^2.6.3" + semver: "npm:^5.6.0" + slash: "npm:^2.0.0" + tmp: "npm:^0.0.33" + yaml: "npm:^1.10.2" + bin: + patch-package: index.js + checksum: 10/e15b3848f008da2cc659abd6d84dfeab6ed25a999ba25692071c13409f198dad28b6e451ecfebc2139a0847ad8e608575d6724bcc887c56169df8a733b849e79 + languageName: node + linkType: hard + "path-browserify@npm:1.0.1, path-browserify@npm:^1.0.1": version: 1.0.1 resolution: "path-browserify@npm:1.0.1" @@ -40921,6 +40895,13 @@ __metadata: languageName: node linkType: hard +"path-key@npm:^2.0.1": + version: 2.0.1 + resolution: "path-key@npm:2.0.1" + checksum: 10/6e654864e34386a2a8e6bf72cf664dcabb76574dd54013add770b374384d438aca95f4357bb26935b514a4e4c2c9b19e191f2200b282422a76ee038b9258c5e7 + languageName: node + linkType: hard + "path-key@npm:^3.0.0, path-key@npm:^3.1.0": version: 3.1.1 resolution: "path-key@npm:3.1.1" @@ -41002,7 +40983,7 @@ __metadata: languageName: node linkType: hard -"path-to-regexp@npm:6.2.1, path-to-regexp@npm:^6.2.0, path-to-regexp@npm:^6.2.1": +"path-to-regexp@npm:6.2.1": version: 6.2.1 resolution: "path-to-regexp@npm:6.2.1" checksum: 10/1e266be712d1a08086ee77beab12a1804842ec635dfed44f9ee1ba960a0e01cec8063fb8c92561115cdc0ce73158cdc7766e353ffa039340b4a85b370084c4d4 @@ -41018,6 +40999,13 @@ __metadata: languageName: node linkType: hard +"path-to-regexp@npm:^6.2.0, path-to-regexp@npm:^6.2.1": + version: 6.2.2 + resolution: "path-to-regexp@npm:6.2.2" + checksum: 10/f7d11c1a9e02576ce0294f4efdc523c11b73894947afdf7b23a0d0f7c6465d7a7772166e770ddf1495a8017cc0ee99e3e8a15ed7302b6b948b89a6dd4eea895e + languageName: node + linkType: hard + "path-type@npm:^4.0.0": version: 4.0.0 resolution: "path-type@npm:4.0.0" @@ -41295,23 +41283,23 @@ __metadata: languageName: node linkType: hard -"pino-abstract-transport@npm:v0.5.0": - version: 0.5.0 - resolution: "pino-abstract-transport@npm:0.5.0" +"pino-abstract-transport@npm:^1.1.0": + version: 1.1.0 + resolution: "pino-abstract-transport@npm:1.1.0" dependencies: - duplexify: "npm:^4.1.2" + readable-stream: "npm:^4.0.0" split2: "npm:^4.0.0" - checksum: 10/d304a104e5cb0c3fef62ea544a4a39bf2472a602cdd7ddb136b0671b9c324ad93fa7888825c4cf33e624802436e897081ba92440f40518b9f2dbdbc0c889e409 + checksum: 10/39b4496c9e4289e8d44a1d01adfa8dfeebb374e14b7a6451a4f3713561aeb9e181c64ff0272921667abcb95aceb312ab2761b82e253db23a456ab3dd35a42675 languageName: node linkType: hard -"pino-abstract-transport@npm:v1.1.0": - version: 1.1.0 - resolution: "pino-abstract-transport@npm:1.1.0" +"pino-abstract-transport@npm:v0.5.0": + version: 0.5.0 + resolution: "pino-abstract-transport@npm:0.5.0" dependencies: - readable-stream: "npm:^4.0.0" + duplexify: "npm:^4.1.2" split2: "npm:^4.0.0" - checksum: 10/39b4496c9e4289e8d44a1d01adfa8dfeebb374e14b7a6451a4f3713561aeb9e181c64ff0272921667abcb95aceb312ab2761b82e253db23a456ab3dd35a42675 + checksum: 10/d304a104e5cb0c3fef62ea544a4a39bf2472a602cdd7ddb136b0671b9c324ad93fa7888825c4cf33e624802436e897081ba92440f40518b9f2dbdbc0c889e409 languageName: node linkType: hard @@ -41351,13 +41339,13 @@ __metadata: linkType: hard "pino@npm:^8.5.0": - version: 8.19.0 - resolution: "pino@npm:8.19.0" + version: 8.20.0 + resolution: "pino@npm:8.20.0" dependencies: atomic-sleep: "npm:^1.0.0" fast-redact: "npm:^3.1.1" on-exit-leak-free: "npm:^2.1.0" - pino-abstract-transport: "npm:v1.1.0" + pino-abstract-transport: "npm:^1.1.0" pino-std-serializers: "npm:^6.0.0" process-warning: "npm:^3.0.0" quick-format-unescaped: "npm:^4.0.3" @@ -41367,7 +41355,7 @@ __metadata: thread-stream: "npm:^2.0.0" bin: pino: bin.js - checksum: 10/c98e8bedb7c9eca5c0e75c2dd910a58b0e470da282c5a4787873a591666cc7cce33561d9ba6d6a20cf6bc4bc8d15b7db84cf6156f262081a5c6b8de134285789 + checksum: 10/c236ad50ea6fa533b25275928ac1c3c96d6c06df08f79a70d91a571fcf1b6fe0570c6f4b00eb5ad201fa9b4a9292d4cfe21fd8af29fa1df44aa1963d35c1bf8b languageName: node linkType: hard @@ -41378,6 +41366,15 @@ __metadata: languageName: node linkType: hard +"pkg-dir@npm:4.2.0, pkg-dir@npm:^4.1.0": + version: 4.2.0 + resolution: "pkg-dir@npm:4.2.0" + dependencies: + find-up: "npm:^4.0.0" + checksum: 10/9863e3f35132bf99ae1636d31ff1e1e3501251d480336edb1c211133c8d58906bed80f154a1d723652df1fda91e01c7442c2eeaf9dc83157c7ae89087e43c8d6 + languageName: node + linkType: hard + "pkg-dir@npm:^3.0.0": version: 3.0.0 resolution: "pkg-dir@npm:3.0.0" @@ -41387,15 +41384,6 @@ __metadata: languageName: node linkType: hard -"pkg-dir@npm:^4.1.0": - version: 4.2.0 - resolution: "pkg-dir@npm:4.2.0" - dependencies: - find-up: "npm:^4.0.0" - checksum: 10/9863e3f35132bf99ae1636d31ff1e1e3501251d480336edb1c211133c8d58906bed80f154a1d723652df1fda91e01c7442c2eeaf9dc83157c7ae89087e43c8d6 - languageName: node - linkType: hard - "pkg-dir@npm:^5.0.0": version: 5.0.0 resolution: "pkg-dir@npm:5.0.0" @@ -41466,6 +41454,13 @@ __metadata: languageName: node linkType: hard +"pollock@npm:^0.2.0": + version: 0.2.1 + resolution: "pollock@npm:0.2.1" + checksum: 10/cd95df0878619c9de87d2f4d9685fa2ee983a38ecd7f8f8dea6163b8b6da4c0ba9c58c40712fd301412ef69d2685cb39f3f4a05114160eea673b4c879922b581 + languageName: node + linkType: hard + "posix-character-classes@npm:^0.1.0": version: 0.1.1 resolution: "posix-character-classes@npm:0.1.1" @@ -41607,22 +41602,6 @@ __metadata: languageName: node linkType: hard -"postcss-loader@npm:^4.2.0": - version: 4.3.0 - resolution: "postcss-loader@npm:4.3.0" - dependencies: - cosmiconfig: "npm:^7.0.0" - klona: "npm:^2.0.4" - loader-utils: "npm:^2.0.0" - schema-utils: "npm:^3.0.0" - semver: "npm:^7.3.4" - peerDependencies: - postcss: ^7.0.0 || ^8.0.1 - webpack: ^4.0.0 || ^5.0.0 - checksum: 10/6b60ef72ac1639d3a2c0322b22e6c22068525473e180a8f56e30918b0c4d11b92a10dc9a8fb5ab4aa0b489e86cfd695f13c97b1735c76b8cd36d5e1d05feebbe - languageName: node - linkType: hard - "postcss-loader@npm:^7.3.3": version: 7.3.4 resolution: "postcss-loader@npm:7.3.4" @@ -41723,15 +41702,6 @@ __metadata: languageName: node linkType: hard -"postcss-modules-extract-imports@npm:^2.0.0": - version: 2.0.0 - resolution: "postcss-modules-extract-imports@npm:2.0.0" - dependencies: - postcss: "npm:^7.0.5" - checksum: 10/154790fe5954aaa12f300aa9aa782fae8b847138459c8f533ea6c8f29439dd66b4d9a49e0bf6f8388fa0df898cc03d61c84678e3b0d4b47cac5a4334a7151a9f - languageName: node - linkType: hard - "postcss-modules-extract-imports@npm:^3.1.0": version: 3.1.0 resolution: "postcss-modules-extract-imports@npm:3.1.0" @@ -41741,18 +41711,6 @@ __metadata: languageName: node linkType: hard -"postcss-modules-local-by-default@npm:^3.0.2": - version: 3.0.3 - resolution: "postcss-modules-local-by-default@npm:3.0.3" - dependencies: - icss-utils: "npm:^4.1.1" - postcss: "npm:^7.0.32" - postcss-selector-parser: "npm:^6.0.2" - postcss-value-parser: "npm:^4.1.0" - checksum: 10/29b8b13b22a8992a5cf26d2de6854de7e60b8bfd4f0245961144005cf8eec2a05b68dfd2d07cc15ca19b18fa9320dd9cd5856b96ca5ccb84a724ff3154147d04 - languageName: node - linkType: hard - "postcss-modules-local-by-default@npm:^4.0.5": version: 4.0.5 resolution: "postcss-modules-local-by-default@npm:4.0.5" @@ -41766,16 +41724,6 @@ __metadata: languageName: node linkType: hard -"postcss-modules-scope@npm:^2.2.0": - version: 2.2.0 - resolution: "postcss-modules-scope@npm:2.2.0" - dependencies: - postcss: "npm:^7.0.6" - postcss-selector-parser: "npm:^6.0.0" - checksum: 10/f6f7365fdd2c87ee108a466692faaee858c7b0213262c12df02e81d4d6a7e76505f0e7b615a0a609baf57d1ebf9870818b497bb23132faf209c441b55af46da0 - languageName: node - linkType: hard - "postcss-modules-scope@npm:^3.2.0": version: 3.2.0 resolution: "postcss-modules-scope@npm:3.2.0" @@ -41787,16 +41735,6 @@ __metadata: languageName: node linkType: hard -"postcss-modules-values@npm:^3.0.0": - version: 3.0.0 - resolution: "postcss-modules-values@npm:3.0.0" - dependencies: - icss-utils: "npm:^4.0.0" - postcss: "npm:^7.0.6" - checksum: 10/39bf5406b0dd1d12d805f303859d9d942743b3aec762f41c6210b1955cb03a605944eb80c6c872f2a18bc3ce5aa97d979230fee2fd8e7ea0fadb305073f610b0 - languageName: node - linkType: hard - "postcss-modules-values@npm:^4.0.0": version: 4.0.0 resolution: "postcss-modules-values@npm:4.0.0" @@ -41974,7 +41912,7 @@ __metadata: languageName: node linkType: hard -"postcss-selector-parser@npm:^6.0.0, postcss-selector-parser@npm:^6.0.11, postcss-selector-parser@npm:^6.0.2, postcss-selector-parser@npm:^6.0.4, postcss-selector-parser@npm:^6.0.5, postcss-selector-parser@npm:^6.0.9": +"postcss-selector-parser@npm:^6.0.11, postcss-selector-parser@npm:^6.0.2, postcss-selector-parser@npm:^6.0.4, postcss-selector-parser@npm:^6.0.5, postcss-selector-parser@npm:^6.0.9": version: 6.0.16 resolution: "postcss-selector-parser@npm:6.0.16" dependencies: @@ -42047,17 +41985,6 @@ __metadata: languageName: node linkType: hard -"postcss@npm:8.4.14": - version: 8.4.14 - resolution: "postcss@npm:8.4.14" - dependencies: - nanoid: "npm:^3.3.4" - picocolors: "npm:^1.0.0" - source-map-js: "npm:^1.0.2" - checksum: 10/1940e8d1da04a2ac3e518735ab3e9563e2255bfab14cecc8c11fee97b2a36ac5fee496bccfc7057aaae7ff3accae463cd800d746238cf691bd65a32dba5cb7be - languageName: node - linkType: hard - "postcss@npm:8.4.31": version: 8.4.31 resolution: "postcss@npm:8.4.31" @@ -42080,7 +42007,7 @@ __metadata: languageName: node linkType: hard -"postcss@npm:^7.0.14, postcss@npm:^7.0.32, postcss@npm:^7.0.35, postcss@npm:^7.0.5, postcss@npm:^7.0.6": +"postcss@npm:^7.0.5": version: 7.0.39 resolution: "postcss@npm:7.0.39" dependencies: @@ -42288,9 +42215,9 @@ __metadata: linkType: hard "preact@npm:^10.5.9": - version: 10.20.1 - resolution: "preact@npm:10.20.1" - checksum: 10/894ac14b3ec6f8ca308b53fb14e12e57678248fd1faa24ae857f5e37d9c11b34833e6dd1ba8210a34de4d6d523462923b1f9c93d35ce433874affd056f2d0998 + version: 10.20.2 + resolution: "preact@npm:10.20.2" + checksum: 10/55b6128906771e33fb789898698e66eb0bdbc8b3303e1bf6c6e8a7d4191d12e476590a8a32e52513a1ac02b94313c3b20e8712bb9bc60fa377f0924cee2da992 languageName: node linkType: hard @@ -42514,13 +42441,20 @@ __metadata: languageName: node linkType: hard -"prismjs@npm:^1.29.0": +"prismjs@npm:^1.27.0, prismjs@npm:^1.29.0": version: 1.29.0 resolution: "prismjs@npm:1.29.0" checksum: 10/2080db382c2dde0cfc7693769e89b501ef1bfc8ff4f8d25c07fd4c37ca31bc443f6133d5b7c145a73309dc396e829ddb7cc18560026d862a887ae08864ef6b07 languageName: node linkType: hard +"prismjs@npm:~1.27.0": + version: 1.27.0 + resolution: "prismjs@npm:1.27.0" + checksum: 10/dc83e2e09170b53526182f5435fae056fc200b109cac39faa88eb48d992311c7f59b94990318962fa93299190a9b33a404920ed150e5b364ce48c897f2ba1e8e + languageName: node + linkType: hard + "private@npm:^0.1.8": version: 0.1.8 resolution: "private@npm:0.1.8" @@ -42570,7 +42504,7 @@ __metadata: languageName: node linkType: hard -"progress@npm:^2.0.1, progress@npm:^2.0.3": +"progress@npm:2.0.3, progress@npm:^2.0.1, progress@npm:^2.0.3": version: 2.0.3 resolution: "progress@npm:2.0.3" checksum: 10/e6f0bcb71f716eee9dfac0fe8a2606e3704d6a64dd93baaf49fbadbc8499989a610fe14cf1bc6f61b6d6653c49408d94f4a94e124538084efd8e4cf525e0293d @@ -42651,6 +42585,15 @@ __metadata: languageName: node linkType: hard +"property-information@npm:^5.0.0": + version: 5.6.0 + resolution: "property-information@npm:5.6.0" + dependencies: + xtend: "npm:^4.0.0" + checksum: 10/e4f45b100fec5968126b08102f9567f1b5fc3442aecbb5b4cdeca401f1f447672e7638a08c81c05dd3979c62d084e0cc6acbe2d8b053c05280ac5abaaf666a68 + languageName: node + linkType: hard + "property-information@npm:^6.0.0": version: 6.5.0 resolution: "property-information@npm:6.5.0" @@ -42741,7 +42684,7 @@ __metadata: languageName: node linkType: hard -"proxy-from-env@npm:^1.0.0, proxy-from-env@npm:^1.1.0": +"proxy-from-env@npm:1.1.0, proxy-from-env@npm:^1.0.0, proxy-from-env@npm:^1.1.0": version: 1.1.0 resolution: "proxy-from-env@npm:1.1.0" checksum: 10/f0bb4a87cfd18f77bc2fba23ae49c3b378fb35143af16cc478171c623eebe181678f09439707ad80081d340d1593cd54a33a0113f3ccb3f4bc9451488780ee23 @@ -42865,6 +42808,26 @@ __metadata: languageName: node linkType: hard +"puppeteer@npm:^13.7.0": + version: 13.7.0 + resolution: "puppeteer@npm:13.7.0" + dependencies: + cross-fetch: "npm:3.1.5" + debug: "npm:4.3.4" + devtools-protocol: "npm:0.0.981744" + extract-zip: "npm:2.0.1" + https-proxy-agent: "npm:5.0.1" + pkg-dir: "npm:4.2.0" + progress: "npm:2.0.3" + proxy-from-env: "npm:1.1.0" + rimraf: "npm:3.0.2" + tar-fs: "npm:2.1.1" + unbzip2-stream: "npm:1.4.3" + ws: "npm:8.5.0" + checksum: 10/ffdcfb2ad118c8e39563701dfe903b925f6c57068c9e55a7d239be6acf8f9d210638dffa1f727e0f200914afacfad9e9e6a311515c6a3e1b9c9291f83118ee1c + languageName: node + linkType: hard + "pvtsutils@npm:^1.3.2, pvtsutils@npm:^1.3.5": version: 1.3.5 resolution: "pvtsutils@npm:1.3.5" @@ -43592,6 +43555,27 @@ __metadata: languageName: node linkType: hard +"react-markdown@npm:^9.0.1": + version: 9.0.1 + resolution: "react-markdown@npm:9.0.1" + dependencies: + "@types/hast": "npm:^3.0.0" + devlop: "npm:^1.0.0" + hast-util-to-jsx-runtime: "npm:^2.0.0" + html-url-attributes: "npm:^3.0.0" + mdast-util-to-hast: "npm:^13.0.0" + remark-parse: "npm:^11.0.0" + remark-rehype: "npm:^11.0.0" + unified: "npm:^11.0.0" + unist-util-visit: "npm:^5.0.0" + vfile: "npm:^6.0.0" + peerDependencies: + "@types/react": ">=18" + react: ">=18" + checksum: 10/71ce31f200982f641d363888a26e8fb52a199a589124f20295e9be870fa3aed26fcfa14d1dc766d83df666a15cb82359291bfda207bd55d5728ff376d217e079 + languageName: node + linkType: hard + "react-native-fetch-api@npm:^3.0.0": version: 3.0.0 resolution: "react-native-fetch-api@npm:3.0.0" @@ -43754,6 +43738,21 @@ __metadata: languageName: node linkType: hard +"react-syntax-highlighter@npm:^15.5.0": + version: 15.5.0 + resolution: "react-syntax-highlighter@npm:15.5.0" + dependencies: + "@babel/runtime": "npm:^7.3.1" + highlight.js: "npm:^10.4.1" + lowlight: "npm:^1.17.0" + prismjs: "npm:^1.27.0" + refractor: "npm:^3.6.0" + peerDependencies: + react: ">= 0.14.0" + checksum: 10/14291a92672a79cf167e6cf2dba2547b920c24573729a95ae24035bece43f7e00e3429477be7b87455e8ce018682c8992545c405a915421eb772c5cd07c00576 + languageName: node + linkType: hard + "react-test-renderer@npm:18.2.0": version: 18.2.0 resolution: "react-test-renderer@npm:18.2.0" @@ -44115,6 +44114,17 @@ __metadata: languageName: node linkType: hard +"refractor@npm:^3.6.0": + version: 3.6.0 + resolution: "refractor@npm:3.6.0" + dependencies: + hastscript: "npm:^6.0.0" + parse-entities: "npm:^2.0.0" + prismjs: "npm:~1.27.0" + checksum: 10/671bbcf5ae1b4e207f98b9a3dc2cbae215be30effe9f3bdcfd10f565f45fecfe97334cf38c8e4f52d6cc012ff2ec7fb627d3d5678efc388751c8b1e1f7ca2a6c + languageName: node + linkType: hard + "refractor@npm:^4.8.1": version: 4.8.1 resolution: "refractor@npm:4.8.1" @@ -44473,6 +44483,13 @@ __metadata: languageName: node linkType: hard +"remove-markdown@npm:0.5.0": + version: 0.5.0 + resolution: "remove-markdown@npm:0.5.0" + checksum: 10/c7ad6f32511afcb90ef205680be08eb8cbd9bb380e934516d35001229bd9b062d8fed72c5456c9455955a08914c4fcbbae9d9841c45cecf75a7f057427b9d5a0 + languageName: node + linkType: hard + "remove-trailing-separator@npm:^1.0.1": version: 1.1.0 resolution: "remove-trailing-separator@npm:1.1.0" @@ -44900,25 +44917,25 @@ __metadata: languageName: node linkType: hard -"rimraf@npm:^2.2.8, rimraf@npm:^2.6.1, rimraf@npm:^2.6.2, rimraf@npm:^2.6.3, rimraf@npm:^2.7.1": - version: 2.7.1 - resolution: "rimraf@npm:2.7.1" +"rimraf@npm:3.0.2, rimraf@npm:^3.0.2": + version: 3.0.2 + resolution: "rimraf@npm:3.0.2" dependencies: glob: "npm:^7.1.3" bin: - rimraf: ./bin.js - checksum: 10/4586c296c736483e297da7cffd19475e4a3e41d07b1ae124aad5d687c79e4ffa716bdac8732ed1db942caf65271cee9dd39f8b639611de161a2753e2112ffe1d + rimraf: bin.js + checksum: 10/063ffaccaaaca2cfd0ef3beafb12d6a03dd7ff1260d752d62a6077b5dfff6ae81bea571f655bb6b589d366930ec1bdd285d40d560c0dae9b12f125e54eb743d5 languageName: node linkType: hard -"rimraf@npm:^3.0.2": - version: 3.0.2 - resolution: "rimraf@npm:3.0.2" +"rimraf@npm:^2.2.8, rimraf@npm:^2.6.1, rimraf@npm:^2.6.2, rimraf@npm:^2.6.3, rimraf@npm:^2.7.1": + version: 2.7.1 + resolution: "rimraf@npm:2.7.1" dependencies: glob: "npm:^7.1.3" bin: - rimraf: bin.js - checksum: 10/063ffaccaaaca2cfd0ef3beafb12d6a03dd7ff1260d752d62a6077b5dfff6ae81bea571f655bb6b589d366930ec1bdd285d40d560c0dae9b12f125e54eb743d5 + rimraf: ./bin.js + checksum: 10/4586c296c736483e297da7cffd19475e4a3e41d07b1ae124aad5d687c79e4ffa716bdac8732ed1db942caf65271cee9dd39f8b639611de161a2753e2112ffe1d languageName: node linkType: hard @@ -44954,7 +44971,7 @@ __metadata: languageName: node linkType: hard -"rlp@npm:^2.0.0, rlp@npm:^2.2.3, rlp@npm:^2.2.4": +"rlp@npm:^2.0.0, rlp@npm:^2.2.3, rlp@npm:^2.2.4, rlp@npm:^2.2.7": version: 2.2.7 resolution: "rlp@npm:2.2.7" dependencies: @@ -45030,24 +45047,24 @@ __metadata: linkType: hard "rollup@npm:^4.0.2, rollup@npm:^4.13.0, rollup@npm:^4.2.0": - version: 4.14.0 - resolution: "rollup@npm:4.14.0" - dependencies: - "@rollup/rollup-android-arm-eabi": "npm:4.14.0" - "@rollup/rollup-android-arm64": "npm:4.14.0" - "@rollup/rollup-darwin-arm64": "npm:4.14.0" - "@rollup/rollup-darwin-x64": "npm:4.14.0" - "@rollup/rollup-linux-arm-gnueabihf": "npm:4.14.0" - "@rollup/rollup-linux-arm64-gnu": "npm:4.14.0" - "@rollup/rollup-linux-arm64-musl": "npm:4.14.0" - "@rollup/rollup-linux-powerpc64le-gnu": "npm:4.14.0" - "@rollup/rollup-linux-riscv64-gnu": "npm:4.14.0" - "@rollup/rollup-linux-s390x-gnu": "npm:4.14.0" - "@rollup/rollup-linux-x64-gnu": "npm:4.14.0" - "@rollup/rollup-linux-x64-musl": "npm:4.14.0" - "@rollup/rollup-win32-arm64-msvc": "npm:4.14.0" - "@rollup/rollup-win32-ia32-msvc": "npm:4.14.0" - "@rollup/rollup-win32-x64-msvc": "npm:4.14.0" + version: 4.14.1 + resolution: "rollup@npm:4.14.1" + dependencies: + "@rollup/rollup-android-arm-eabi": "npm:4.14.1" + "@rollup/rollup-android-arm64": "npm:4.14.1" + "@rollup/rollup-darwin-arm64": "npm:4.14.1" + "@rollup/rollup-darwin-x64": "npm:4.14.1" + "@rollup/rollup-linux-arm-gnueabihf": "npm:4.14.1" + "@rollup/rollup-linux-arm64-gnu": "npm:4.14.1" + "@rollup/rollup-linux-arm64-musl": "npm:4.14.1" + "@rollup/rollup-linux-powerpc64le-gnu": "npm:4.14.1" + "@rollup/rollup-linux-riscv64-gnu": "npm:4.14.1" + "@rollup/rollup-linux-s390x-gnu": "npm:4.14.1" + "@rollup/rollup-linux-x64-gnu": "npm:4.14.1" + "@rollup/rollup-linux-x64-musl": "npm:4.14.1" + "@rollup/rollup-win32-arm64-msvc": "npm:4.14.1" + "@rollup/rollup-win32-ia32-msvc": "npm:4.14.1" + "@rollup/rollup-win32-x64-msvc": "npm:4.14.1" "@types/estree": "npm:1.0.5" fsevents: "npm:~2.3.2" dependenciesMeta: @@ -45085,7 +45102,7 @@ __metadata: optional: true bin: rollup: dist/bin/rollup - checksum: 10/803b45976dfc73843a48083dc345821860e960aede010b0e765201cc2827fe131b6f29296da3186a48813b83f823cd26b77adcafcf32ba859efb1b62adb8f4e0 + checksum: 10/dd7db600611b11a9d6f4bb1221003b1d02149fedad48a8ddde449bddaa72a9b739760b8adae9026091e2c0df85ecdc93985468c9733312d1ae3ea0030e9939e5 languageName: node linkType: hard @@ -45460,17 +45477,6 @@ __metadata: languageName: node linkType: hard -"schema-utils@npm:^2.7.0": - version: 2.7.1 - resolution: "schema-utils@npm:2.7.1" - dependencies: - "@types/json-schema": "npm:^7.0.5" - ajv: "npm:^6.12.4" - ajv-keywords: "npm:^3.5.2" - checksum: 10/86c3038798981dbc702d5f6a86d4e4a308a2ec6e8eb1bf7d1a3ea95cb3f1972491833b76ce1c86a068652417019126d5b68219c33a9ad069358dd10429d4096d - languageName: node - linkType: hard - "schema-utils@npm:^3.0.0, schema-utils@npm:^3.1.1, schema-utils@npm:^3.2.0": version: 3.3.0 resolution: "schema-utils@npm:3.3.0" @@ -45653,7 +45659,7 @@ __metadata: languageName: node linkType: hard -"semver@npm:^7.0.0, semver@npm:^7.3.2, semver@npm:^7.3.4, semver@npm:^7.3.5, semver@npm:^7.3.7, semver@npm:^7.3.8, semver@npm:^7.5.1, semver@npm:^7.5.2, semver@npm:^7.5.3, semver@npm:^7.5.4": +"semver@npm:^7.0.0, semver@npm:^7.3.2, semver@npm:^7.3.4, semver@npm:^7.3.5, semver@npm:^7.3.7, semver@npm:^7.3.8, semver@npm:^7.5.1, semver@npm:^7.5.2, semver@npm:^7.5.3, semver@npm:^7.5.4, semver@npm:^7.6.0": version: 7.6.0 resolution: "semver@npm:7.6.0" dependencies: @@ -46026,6 +46032,15 @@ __metadata: languageName: node linkType: hard +"shebang-command@npm:^1.2.0": + version: 1.2.0 + resolution: "shebang-command@npm:1.2.0" + dependencies: + shebang-regex: "npm:^1.0.0" + checksum: 10/9eed1750301e622961ba5d588af2212505e96770ec376a37ab678f965795e995ade7ed44910f5d3d3cb5e10165a1847f52d3348c64e146b8be922f7707958908 + languageName: node + linkType: hard + "shebang-command@npm:^2.0.0": version: 2.0.0 resolution: "shebang-command@npm:2.0.0" @@ -46035,6 +46050,13 @@ __metadata: languageName: node linkType: hard +"shebang-regex@npm:^1.0.0": + version: 1.0.0 + resolution: "shebang-regex@npm:1.0.0" + checksum: 10/404c5a752cd40f94591dfd9346da40a735a05139dac890ffc229afba610854d8799aaa52f87f7e0c94c5007f2c6af55bdcaeb584b56691926c5eaf41dc8f1372 + languageName: node + linkType: hard + "shebang-regex@npm:^3.0.0": version: 3.0.0 resolution: "shebang-regex@npm:3.0.0" @@ -46423,12 +46445,31 @@ __metadata: linkType: hard "socks@npm:^2.7.1": - version: 2.8.1 - resolution: "socks@npm:2.8.1" + version: 2.8.2 + resolution: "socks@npm:2.8.2" dependencies: ip-address: "npm:^9.0.5" smart-buffer: "npm:^4.2.0" - checksum: 10/a3cc38e0716ab53a2db3fa00c703ca682ad54dbbc9ed4c7461624a999be6fa7cdc79fc904c411618e698d5eff55a55aa6d9329169a7db11636d0200814a2b5aa + checksum: 10/acc6c0ac347fc41e7c555a1ee180220bb79235f490bc7b96d71e4806a7f3955ea2babaa8e0aea528af03e277a5252286088560c7c5717d6b819ce6ac330fef02 + languageName: node + linkType: hard + +"sol2uml@npm:2.2.0": + version: 2.2.0 + resolution: "sol2uml@npm:2.2.0" + dependencies: + "@aduh95/viz.js": "npm:^3.7.0" + "@solidity-parser/parser": "npm:^0.14.3" + axios: "npm:^0.27.2" + commander: "npm:^9.4.0" + convert-svg-to-png: "npm:^0.6.4" + debug: "npm:^4.3.4" + ethers: "npm:^5.6.9" + js-graph-algorithms: "npm:^1.0.18" + klaw: "npm:^4.0.1" + bin: + sol2uml: lib/sol2uml.js + checksum: 10/d6d860e9a9db0e7034a6f1e5b188ef7ddb7b1b4dda2174322e82b4d7bb5c0d6f95de9d26ee056956fab293253ae43bd68759b88e8ef530ac791c8903d16d7d79 languageName: node linkType: hard @@ -46605,11 +46646,11 @@ __metadata: linkType: hard "sonic-boom@npm:^3.7.0": - version: 3.8.0 - resolution: "sonic-boom@npm:3.8.0" + version: 3.8.1 + resolution: "sonic-boom@npm:3.8.1" dependencies: atomic-sleep: "npm:^1.0.0" - checksum: 10/470a82cb1af3ab99fcd3003bbecb2ce79a6b243d0f6012c59e5f567f71cbe039c8cd810752748b5820ee20d72c8da81aa298e510eec9e41a4ca05c7f419825ff + checksum: 10/e03c9611e43fa81132cd2ce0fe4eb7fbcf19db267e9dec20dc6c586f82465c9c906e91a02f72150c740463ad9335536ea2131850307aaa6686d1fb5d4cc4be3e languageName: node linkType: hard @@ -47563,12 +47604,12 @@ __metadata: linkType: hard "stripe@npm:*": - version: 14.23.0 - resolution: "stripe@npm:14.23.0" + version: 14.25.0 + resolution: "stripe@npm:14.25.0" dependencies: "@types/node": "npm:>=8.1.0" qs: "npm:^6.11.0" - checksum: 10/7463ab8adfedabdfc21e07ab6df7a783e454eac74818a0727c9818707a3ba37a2bc3f7a581eb9c292e0a1bc670b62972c310da610cba185e7059081abad2f93f + checksum: 10/0bec50ef59fd2b98d4055e8ef6837a06f62e6d11b2d2fc87796e5d2c8dc1b473d83e6ddd0895f00e12df36ae54c6de1d63d77adb83a35c0c105e69cb2b445c21 languageName: node linkType: hard @@ -47596,18 +47637,6 @@ __metadata: languageName: node linkType: hard -"style-loader@npm:^1.3.0": - version: 1.3.0 - resolution: "style-loader@npm:1.3.0" - dependencies: - loader-utils: "npm:^2.0.0" - schema-utils: "npm:^2.7.0" - peerDependencies: - webpack: ^4.0.0 || ^5.0.0 - checksum: 10/04a2742a9b9608419b16e4e4f002c6859a60601c35d13f28483cb85a8ae10b4622fe255c59cf955aaf9297dc1e19e48bbba8f2ab5b02934ce3e93c0479b49325 - languageName: node - linkType: hard - "style-to-object@npm:^0.4.0": version: 0.4.4 resolution: "style-to-object@npm:0.4.4" @@ -47861,6 +47890,18 @@ __metadata: languageName: node linkType: hard +"swr@npm:^2.2.5": + version: 2.2.5 + resolution: "swr@npm:2.2.5" + dependencies: + client-only: "npm:^0.0.1" + use-sync-external-store: "npm:^1.2.0" + peerDependencies: + react: ^16.11.0 || ^17.0.0 || ^18.0.0 + checksum: 10/f02b3bd5a198a0f62f9a53d7c0528c4a58aa61a43310bea169614b6e873dadb52599e856ef0775405b6aa7409835343da0cf328948aa892aa309bf4b7e7d6902 + languageName: node + linkType: hard + "symbol-observable@npm:^1.1.0, symbol-observable@npm:^1.2.0": version: 1.2.0 resolution: "symbol-observable@npm:1.2.0" @@ -48054,7 +48095,7 @@ __metadata: languageName: node linkType: hard -"tar-fs@npm:^2.1.1": +"tar-fs@npm:2.1.1, tar-fs@npm:^2.1.1": version: 2.1.1 resolution: "tar-fs@npm:2.1.1" dependencies: @@ -48601,7 +48642,7 @@ __metadata: languageName: node linkType: hard -"tmp@npm:^0.2.0": +"tmp@npm:^0.2.0, tmp@npm:^0.2.1": version: 0.2.3 resolution: "tmp@npm:0.2.3" checksum: 10/7b13696787f159c9754793a83aa79a24f1522d47b87462ddb57c18ee93ff26c74cbb2b8d9138f571d2e0e765c728fb2739863a672b280528512c6d83d511c6fa @@ -48814,6 +48855,13 @@ __metadata: languageName: node linkType: hard +"treeify@npm:^1.1.0": + version: 1.1.0 + resolution: "treeify@npm:1.1.0" + checksum: 10/5241976a751168fb9894a12d031299f1f6337b7f2cbd3eff22ee86e6777620352a69a1cab0d4709251317ff307eeda0dc45918850974fc44f4c7fc50e623b990 + languageName: node + linkType: hard + "trim-lines@npm:^3.0.0": version: 3.0.1 resolution: "trim-lines@npm:3.0.1" @@ -49501,7 +49549,7 @@ __metadata: languageName: node linkType: hard -"typescript@npm:5.4.3, typescript@npm:^5.0.0, typescript@npm:^5.0.4, typescript@npm:^5.2.2": +"typescript@npm:5.4.3": version: 5.4.3 resolution: "typescript@npm:5.4.3" bin: @@ -49511,6 +49559,16 @@ __metadata: languageName: node linkType: hard +"typescript@npm:^5.0.0, typescript@npm:^5.2.2, typescript@npm:^5.4.4": + version: 5.4.4 + resolution: "typescript@npm:5.4.4" + bin: + tsc: bin/tsc + tsserver: bin/tsserver + checksum: 10/bade322d88fd93c8179e262aca9ba7f7b4417c09117879819c87946578c782ab123e3acb4733046a6e38714c47ef927360045a1f9292a1bff3a05a6577d27ca2 + languageName: node + linkType: hard + "typescript@patch:typescript@npm%3A5.3.3#optional!builtin": version: 5.3.3 resolution: "typescript@patch:typescript@npm%3A5.3.3#optional!builtin::version=5.3.3&hash=e012d7" @@ -49521,7 +49579,7 @@ __metadata: languageName: node linkType: hard -"typescript@patch:typescript@npm%3A5.4.3#optional!builtin, typescript@patch:typescript@npm%3A^5.0.0#optional!builtin, typescript@patch:typescript@npm%3A^5.0.4#optional!builtin, typescript@patch:typescript@npm%3A^5.2.2#optional!builtin": +"typescript@patch:typescript@npm%3A5.4.3#optional!builtin": version: 5.4.3 resolution: "typescript@patch:typescript@npm%3A5.4.3#optional!builtin::version=5.4.3&hash=5adc0c" bin: @@ -49531,6 +49589,16 @@ __metadata: languageName: node linkType: hard +"typescript@patch:typescript@npm%3A^5.0.0#optional!builtin, typescript@patch:typescript@npm%3A^5.2.2#optional!builtin, typescript@patch:typescript@npm%3A^5.4.4#optional!builtin": + version: 5.4.4 + resolution: "typescript@patch:typescript@npm%3A5.4.4#optional!builtin::version=5.4.4&hash=5adc0c" + bin: + tsc: bin/tsc + tsserver: bin/tsserver + checksum: 10/88aff3244c31d4c6ede05b4fd28732fc8935a7fc638f2a3dcbbb767d1ac98e4b077f21ec74bc97f43c9307bc3f27e2359def1d793f9918c3429a744408fd75b4 + languageName: node + linkType: hard + "typical@npm:^4.0.0": version: 4.0.0 resolution: "typical@npm:4.0.0" @@ -49632,7 +49700,7 @@ __metadata: languageName: node linkType: hard -"unbzip2-stream@npm:^1.4.3": +"unbzip2-stream@npm:1.4.3, unbzip2-stream@npm:^1.4.3": version: 1.4.3 resolution: "unbzip2-stream@npm:1.4.3" dependencies: @@ -49673,9 +49741,9 @@ __metadata: linkType: hard "undici@npm:^6.0.0": - version: 6.11.1 - resolution: "undici@npm:6.11.1" - checksum: 10/129480684630e5723b7f4a946c1d9f8120f9b5697cb2032d791d1e3d2898a90eed0ed63c6ef5641502569dca0112759948564354a932c8172fc96845aaf2dd28 + version: 6.12.0 + resolution: "undici@npm:6.12.0" + checksum: 10/6cdc05c7ed4eef3f998ccd41f355b7f8ffd34ba6962f582b7ee8b3e9488ba95199fb6f23ff92ef87e53762286c45c19fb23aa64f12d33d2c61a45c56c5b85a4b languageName: node linkType: hard @@ -50727,8 +50795,8 @@ __metadata: linkType: hard "viem@npm:^2.7.1": - version: 2.9.8 - resolution: "viem@npm:2.9.8" + version: 2.9.15 + resolution: "viem@npm:2.9.15" dependencies: "@adraffy/ens-normalize": "npm:1.10.0" "@noble/curves": "npm:1.2.0" @@ -50743,7 +50811,7 @@ __metadata: peerDependenciesMeta: typescript: optional: true - checksum: 10/1e464f9e4fec0f56aa88917806a5fc3eb23000688f4a9b45d7789ea7b3d12429de82f095c7c9072a3a80dc8b84412176f37a9f5e018c1e28c78db9ff2b07a822 + checksum: 10/3a8e40bfb7d366e5845cf8d5a307d2890fc0e75398f2b9a88f6b14760f12dbfdb363fc8ba78a19bc0aa891f0661239145d01b6dd51a7a13214f090432470c4dd languageName: node linkType: hard @@ -50857,9 +50925,9 @@ __metadata: languageName: node linkType: hard -"vite@npm:5.0.12": - version: 5.0.12 - resolution: "vite@npm:5.0.12" +"vite@npm:5.0.13": + version: 5.0.13 + resolution: "vite@npm:5.0.13" dependencies: esbuild: "npm:^0.19.3" fsevents: "npm:~2.3.3" @@ -50893,7 +50961,7 @@ __metadata: optional: true bin: vite: bin/vite.js - checksum: 10/ed0bb26a0d0c8e1dae0b70af9e36adffd7e15d80297443fe4da762596dc81570bad7f0291f590a57c1553f5e435338d8c7ffc483bd9431a95c09d9ac90665fad + checksum: 10/e0da15142ecbe3e88dbb2682c86c7e468927ea35a04c6a57dae623c575d632f3150a1098905af2da5a598b604a5762bdf45f904d00a2ecc6e93042d904b01077 languageName: node linkType: hard @@ -51335,16 +51403,6 @@ __metadata: languageName: node linkType: hard -"watchpack@npm:2.4.0": - version: 2.4.0 - resolution: "watchpack@npm:2.4.0" - dependencies: - glob-to-regexp: "npm:^0.4.1" - graceful-fs: "npm:^4.1.2" - checksum: 10/4280b45bc4b5d45d5579113f2a4af93b67ae1b9607cc3d86ae41cdd53ead10db5d9dc3237f24256d05ef88b28c69a02712f78e434cb7ecc8edaca134a56e8cab - languageName: node - linkType: hard - "watchpack@npm:^2.2.0, watchpack@npm:^2.4.1": version: 2.4.1 resolution: "watchpack@npm:2.4.1" @@ -51654,7 +51712,7 @@ __metadata: languageName: node linkType: hard -"web3-utils@npm:1.10.4, web3-utils@npm:^1.10.3, web3-utils@npm:^1.3.6, web3-utils@npm:^1.8.1": +"web3-utils@npm:1.10.4, web3-utils@npm:^1.10.3, web3-utils@npm:^1.3.4, web3-utils@npm:^1.3.6, web3-utils@npm:^1.8.1": version: 1.10.4 resolution: "web3-utils@npm:1.10.4" dependencies: @@ -51843,7 +51901,7 @@ __metadata: languageName: node linkType: hard -"webpack-sources@npm:^2.0.0 || ^3.0.0, webpack-sources@npm:^3.2.2, webpack-sources@npm:^3.2.3": +"webpack-sources@npm:^2.0.0 || ^3.0.0, webpack-sources@npm:^3.2.3": version: 3.2.3 resolution: "webpack-sources@npm:3.2.3" checksum: 10/a661f41795d678b7526ae8a88cd1b3d8ce71a7d19b6503da8149b2e667fc7a12f9b899041c1665d39e38245ed3a59ab68de648ea31040c3829aa695a5a45211d @@ -52073,7 +52131,7 @@ __metadata: languageName: node linkType: hard -"which@npm:1.3.1, which@npm:^1.1.1, which@npm:^1.3.1": +"which@npm:1.3.1, which@npm:^1.1.1, which@npm:^1.2.9, which@npm:^1.3.1": version: 1.3.1 resolution: "which@npm:1.3.1" dependencies: @@ -53030,11 +53088,11 @@ __metadata: linkType: hard "zksync-ethers@npm:^6.0.0": - version: 6.6.0 - resolution: "zksync-ethers@npm:6.6.0" + version: 6.7.0 + resolution: "zksync-ethers@npm:6.7.0" peerDependencies: ethers: ^6.7.1 - checksum: 10/a2b22fb0667d34e92ad8cd4cea844110ac7ca85a184634e4e6561cd1ab74901087870f792fc1d8b2656c0cecb4649057584e4f0a846387c9347de471959c2301 + checksum: 10/c12d2e80324a332a17cb7a77acea8d52c9e234906419067d93f42a46ce48feb8b337bf49cc7e22b226091e61a8e13739da0b1afdf6aaa8f89b643e8a453a982a languageName: node linkType: hard @@ -53056,13 +53114,6 @@ __metadata: languageName: node linkType: hard -"zod@npm:3.21.4": - version: 3.21.4 - resolution: "zod@npm:3.21.4" - checksum: 10/03c79fa4610a35e24119771970be764c6e177a271a225587f86a7fc35d55e94a154d8e1970d23ffe35b567c147262bedbcb53b31aa30eeef2493fbd13e1b4aca - languageName: node - linkType: hard - "zod@npm:3.22.4, zod@npm:^3.20.6, zod@npm:^3.21.4": version: 3.22.4 resolution: "zod@npm:3.22.4"