@boostxyz/sdk 0.0.0-alpha.17 → 0.0.0-alpha.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Actions/Action.cjs +1 -1
- package/dist/Actions/Action.cjs.map +1 -1
- package/dist/Actions/Action.js +13 -13
- package/dist/Actions/ContractAction.d.ts +9 -9
- package/dist/Actions/ContractAction.d.ts.map +1 -1
- package/dist/Actions/ERC721MintAction.d.ts +12 -12
- package/dist/Actions/ERC721MintAction.d.ts.map +1 -1
- package/dist/Actions/EventAction.cjs +1 -1
- package/dist/Actions/EventAction.cjs.map +1 -1
- package/dist/Actions/EventAction.d.ts +32 -49
- package/dist/Actions/EventAction.d.ts.map +1 -1
- package/dist/Actions/EventAction.js +13 -962
- package/dist/Actions/EventAction.js.map +1 -1
- package/dist/AllowLists/AllowList.cjs +1 -1
- package/dist/AllowLists/AllowList.js +3 -3
- package/dist/AllowLists/SimpleAllowList.cjs +1 -1
- package/dist/AllowLists/SimpleAllowList.cjs.map +1 -1
- package/dist/AllowLists/SimpleAllowList.d.ts +5 -5
- package/dist/AllowLists/SimpleAllowList.js +24 -24
- package/dist/AllowLists/SimpleAllowList.js.map +1 -1
- package/dist/AllowLists/SimpleDenyList.cjs +1 -1
- package/dist/AllowLists/SimpleDenyList.d.ts +6 -6
- package/dist/AllowLists/SimpleDenyList.js +3 -3
- package/dist/Auth/PassthroughAuth.cjs +1 -1
- package/dist/Auth/PassthroughAuth.js +1 -1
- package/dist/Boost.cjs.map +1 -1
- package/dist/Boost.d.ts +18 -0
- package/dist/Boost.d.ts.map +1 -1
- package/dist/Boost.js.map +1 -1
- package/dist/BoostCore-BiPwp6SR.cjs +3 -0
- package/dist/BoostCore-BiPwp6SR.cjs.map +1 -0
- package/dist/BoostCore-C00iqvks.js +1477 -0
- package/dist/BoostCore-C00iqvks.js.map +1 -0
- package/dist/BoostCore.cjs +1 -2
- package/dist/BoostCore.cjs.map +1 -1
- package/dist/BoostCore.d.ts +80 -35
- package/dist/BoostCore.d.ts.map +1 -1
- package/dist/BoostCore.js +29 -1273
- package/dist/BoostCore.js.map +1 -1
- package/dist/BoostRegistry.cjs +1 -1
- package/dist/BoostRegistry.cjs.map +1 -1
- package/dist/BoostRegistry.d.ts +18 -18
- package/dist/BoostRegistry.js +28 -28
- package/dist/BoostRegistry.js.map +1 -1
- package/dist/Budgets/Budget.cjs +1 -1
- package/dist/Budgets/Budget.js +2 -2
- package/dist/Budgets/ManagedBudget.cjs +1 -1
- package/dist/Budgets/ManagedBudget.cjs.map +1 -1
- package/dist/Budgets/ManagedBudget.d.ts +18 -18
- package/dist/Budgets/ManagedBudget.js +48 -48
- package/dist/Budgets/ManagedBudget.js.map +1 -1
- package/dist/Budgets/VestingBudget.d.ts +23 -23
- package/dist/Deployable/Contract.cjs +1 -1
- package/dist/Deployable/Contract.cjs.map +1 -1
- package/dist/Deployable/Contract.d.ts +4 -5
- package/dist/Deployable/Contract.d.ts.map +1 -1
- package/dist/Deployable/Contract.js +4 -5
- package/dist/Deployable/Contract.js.map +1 -1
- package/dist/Deployable/Deployable.cjs.map +1 -1
- package/dist/Deployable/Deployable.d.ts +1 -1
- package/dist/Deployable/Deployable.js +1 -1
- package/dist/Deployable/Deployable.js.map +1 -1
- package/dist/Deployable/DeployableTarget.cjs +1 -1
- package/dist/Deployable/DeployableTarget.cjs.map +1 -1
- package/dist/Deployable/DeployableTarget.d.ts +5 -5
- package/dist/Deployable/DeployableTarget.js +10 -10
- package/dist/Deployable/DeployableTarget.js.map +1 -1
- package/dist/Deployable/DeployableTargetWithRBAC.cjs +1 -1
- package/dist/Deployable/DeployableTargetWithRBAC.cjs.map +1 -1
- package/dist/Deployable/DeployableTargetWithRBAC.d.ts +15 -15
- package/dist/Deployable/DeployableTargetWithRBAC.js +32 -32
- package/dist/Deployable/DeployableTargetWithRBAC.js.map +1 -1
- package/dist/EventAction-BO5WI_5s.js +1355 -0
- package/dist/EventAction-BO5WI_5s.js.map +1 -0
- package/dist/EventAction-DBDRaG4A.cjs +2 -0
- package/dist/EventAction-DBDRaG4A.cjs.map +1 -0
- package/dist/{Incentive-DJf-vdyL.js → Incentive-CF7kaz_9.js} +61 -62
- package/dist/Incentive-CF7kaz_9.js.map +1 -0
- package/dist/{Incentive-DNwROd1r.cjs → Incentive-Djnzseoj.cjs} +2 -2
- package/dist/Incentive-Djnzseoj.cjs.map +1 -0
- package/dist/Incentives/AllowListIncentive.cjs +1 -1
- package/dist/Incentives/AllowListIncentive.cjs.map +1 -1
- package/dist/Incentives/AllowListIncentive.d.ts +12 -12
- package/dist/Incentives/AllowListIncentive.js +19 -19
- package/dist/Incentives/AllowListIncentive.js.map +1 -1
- package/dist/Incentives/CGDAIncentive.cjs +1 -1
- package/dist/Incentives/CGDAIncentive.cjs.map +1 -1
- package/dist/Incentives/CGDAIncentive.d.ts +15 -15
- package/dist/Incentives/CGDAIncentive.js +18 -18
- package/dist/Incentives/CGDAIncentive.js.map +1 -1
- package/dist/Incentives/ERC1155Incentive.d.ts +30 -30
- package/dist/Incentives/ERC20Incentive.cjs +1 -1
- package/dist/Incentives/ERC20Incentive.cjs.map +1 -1
- package/dist/Incentives/ERC20Incentive.d.ts +23 -23
- package/dist/Incentives/ERC20Incentive.js +25 -25
- package/dist/Incentives/ERC20Incentive.js.map +1 -1
- package/dist/Incentives/ERC20VariableCriteriaIncentive.d.ts +523 -0
- package/dist/Incentives/ERC20VariableCriteriaIncentive.d.ts.map +1 -0
- package/dist/Incentives/ERC20VariableIncentive.d.ts +19 -19
- package/dist/Incentives/Incentive.cjs +1 -1
- package/dist/Incentives/Incentive.d.ts +3 -3
- package/dist/Incentives/Incentive.d.ts.map +1 -1
- package/dist/Incentives/Incentive.js +3 -3
- package/dist/Incentives/PointsIncentive.cjs +1 -1
- package/dist/Incentives/PointsIncentive.cjs.map +1 -1
- package/dist/Incentives/PointsIncentive.d.ts +14 -14
- package/dist/Incentives/PointsIncentive.js +21 -21
- package/dist/Incentives/PointsIncentive.js.map +1 -1
- package/dist/{SimpleDenyList-DMlUkmAn.cjs → SimpleDenyList-BwfNjRsg.cjs} +2 -2
- package/dist/SimpleDenyList-BwfNjRsg.cjs.map +1 -0
- package/dist/{SimpleDenyList-DvUvmOeE.js → SimpleDenyList-D9i4rw_F.js} +9 -9
- package/dist/SimpleDenyList-D9i4rw_F.js.map +1 -0
- package/dist/Validators/SignerValidator.cjs +1 -1
- package/dist/Validators/SignerValidator.cjs.map +1 -1
- package/dist/Validators/SignerValidator.d.ts +14 -14
- package/dist/Validators/SignerValidator.js +19 -19
- package/dist/Validators/SignerValidator.js.map +1 -1
- package/dist/Validators/Validator.cjs +1 -1
- package/dist/Validators/Validator.cjs.map +1 -1
- package/dist/Validators/Validator.d.ts +1 -1
- package/dist/Validators/Validator.js +6 -6
- package/dist/Validators/Validator.js.map +1 -1
- package/dist/claiming.cjs.map +1 -1
- package/dist/claiming.d.ts +1 -1
- package/dist/claiming.js.map +1 -1
- package/dist/componentInterfaces-D09mhzxO.cjs +2 -0
- package/dist/componentInterfaces-D09mhzxO.cjs.map +1 -0
- package/dist/componentInterfaces-RXBMI5yH.js +14 -0
- package/dist/componentInterfaces-RXBMI5yH.js.map +1 -0
- package/dist/deployments-BM42vImE.js +43 -0
- package/dist/deployments-BM42vImE.js.map +1 -0
- package/dist/deployments-CMdF5uEC.cjs +2 -0
- package/dist/deployments-CMdF5uEC.cjs.map +1 -0
- package/dist/deployments.json +15 -12
- package/dist/errors.cjs +1 -1
- package/dist/errors.cjs.map +1 -1
- package/dist/errors.d.ts +132 -0
- package/dist/errors.d.ts.map +1 -1
- package/dist/errors.js +122 -36
- package/dist/errors.js.map +1 -1
- package/dist/generated-B0tk-c9b.cjs +3 -0
- package/dist/generated-B0tk-c9b.cjs.map +1 -0
- package/dist/{generated-C_7Jx3YG.js → generated-B8VWObPa.js} +631 -343
- package/dist/generated-B8VWObPa.js.map +1 -0
- package/dist/index.cjs +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +133 -125
- package/dist/transfers.cjs.map +1 -1
- package/dist/transfers.d.ts +1 -1
- package/dist/transfers.js.map +1 -1
- package/dist/utils.cjs.map +1 -1
- package/dist/utils.d.ts +1 -1
- package/dist/utils.js.map +1 -1
- package/package.json +5 -5
- package/src/Actions/ContractAction.ts +9 -10
- package/src/Actions/ERC721MintAction.ts +12 -13
- package/src/Actions/EventAction.test.ts +45 -54
- package/src/Actions/EventAction.ts +100 -100
- package/src/AllowLists/SimpleAllowList.ts +5 -5
- package/src/AllowLists/SimpleDenyList.ts +6 -6
- package/src/Boost.ts +19 -0
- package/src/BoostCore.test.ts +117 -1
- package/src/BoostCore.ts +113 -54
- package/src/BoostRegistry.ts +18 -18
- package/src/Budgets/ManagedBudget.ts +18 -18
- package/src/Budgets/VestingBudget.ts +23 -23
- package/src/Deployable/Contract.ts +4 -5
- package/src/Deployable/Deployable.ts +1 -1
- package/src/Deployable/DeployableTarget.ts +5 -5
- package/src/Deployable/DeployableTargetWithRBAC.ts +15 -15
- package/src/Incentives/AllowListIncentive.ts +12 -12
- package/src/Incentives/CGDAIncentive.ts +15 -15
- package/src/Incentives/ERC1155Incentive.ts +26 -26
- package/src/Incentives/ERC20Incentive.ts +23 -23
- package/src/Incentives/ERC20VariableCriteriaIncentive.test.ts +184 -0
- package/src/Incentives/ERC20VariableCriteriaIncentive.ts +309 -0
- package/src/Incentives/ERC20VariableIncentive.ts +19 -19
- package/src/Incentives/Incentive.ts +6 -5
- package/src/Incentives/PointsIncentive.test.ts +21 -21
- package/src/Incentives/PointsIncentive.ts +14 -14
- package/src/Validators/SignerValidator.ts +14 -14
- package/src/Validators/Validator.ts +1 -1
- package/src/claiming.ts +1 -1
- package/src/errors.ts +165 -0
- package/src/index.ts +1 -0
- package/src/transfers.ts +1 -1
- package/src/utils.ts +1 -1
- package/dist/Incentive-DJf-vdyL.js.map +0 -1
- package/dist/Incentive-DNwROd1r.cjs.map +0 -1
- package/dist/SimpleDenyList-DMlUkmAn.cjs.map +0 -1
- package/dist/SimpleDenyList-DvUvmOeE.js.map +0 -1
- package/dist/componentInterfaces-BPVR_Ykd.js +0 -13
- package/dist/componentInterfaces-BPVR_Ykd.js.map +0 -1
- package/dist/componentInterfaces-BfppSIl4.cjs +0 -2
- package/dist/componentInterfaces-BfppSIl4.cjs.map +0 -1
- package/dist/deployments-BvFcK_eR.js +0 -40
- package/dist/deployments-BvFcK_eR.js.map +0 -1
- package/dist/deployments-Ho4PnGCS.cjs +0 -2
- package/dist/deployments-Ho4PnGCS.cjs.map +0 -1
- package/dist/generated-CMQ6ZC2_.cjs +0 -3
- package/dist/generated-CMQ6ZC2_.cjs.map +0 -1
- package/dist/generated-C_7Jx3YG.js.map +0 -1
package/dist/BoostCore.js
CHANGED
|
@@ -1,1276 +1,32 @@
|
|
|
1
|
-
import { b as
|
|
2
|
-
import {
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
import
|
|
13
|
-
import
|
|
14
|
-
import
|
|
15
|
-
import
|
|
16
|
-
import
|
|
17
|
-
import
|
|
18
|
-
import
|
|
19
|
-
import
|
|
20
|
-
import
|
|
21
|
-
import
|
|
22
|
-
import
|
|
23
|
-
import
|
|
24
|
-
import
|
|
25
|
-
import { parseAccount as Hf, getAddress as Jf } from "viem/utils";
|
|
26
|
-
const Qf = "0x60806040526544364c5bb0006004556103e860055f6101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055506103e8600560086101000a81548167ffffffffffffffff021916908367ffffffffffffffff16021790555034801561006e575f80fd5b506040516136713803806136718339818101604052810190610090919061029f565b61009f3361012660201b60201c565b8160015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508060035f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050506102dd565b61013461020260201b60201c565b156101ac577fffffffffffffffffffffffffffffffffffffffffffffffffffffffff7487392780541561016e57630dc149f05f526004601cfd5b8160601b60601c9150811560ff1b82178155815f7f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e05f80a3506101ff565b8060601b60601c9050807fffffffffffffffffffffffffffffffffffffffffffffffffffffffff7487392755805f7f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e05f80a35b50565b5f90565b5f80fd5b5f73ffffffffffffffffffffffffffffffffffffffff82169050919050565b5f6102338261020a565b9050919050565b5f61024482610229565b9050919050565b6102548161023a565b811461025e575f80fd5b50565b5f8151905061026f8161024b565b92915050565b61027e81610229565b8114610288575f80fd5b50565b5f8151905061029981610275565b92915050565b5f80604083850312156102b5576102b4610206565b5b5f6102c285828601610261565b92505060206102d38582860161028b565b9150509250929050565b613387806102ea5f395ff3fe60806040526004361061014a575f3560e01c8063892b97f8116100b5578063d73792a91161006e578063d73792a9146103d0578063e21ff731146103fa578063eccc19a614610436578063f04e283e1461045e578063f2fde38b1461047a578063fee81cf4146104965761014a565b8063892b97f8146102e45780638da5cb5b1461030c5780638fe4f5231461033657806399d32fc414610352578063a92647dc1461037c578063b0e21e8a146103a65761014a565b806354d1f13d1161010757806354d1f13d146102365780635edb9eb014610240578063715018a61461026a578063730f9c57146102745780637b1039991461029057806384ae2bc6146102ba5761014a565b806313c8e2de1461014e578063256929621461018a5780632e75ab501461019457806339a51be5146101bc57806343bc42d3146101e657806346877b1a1461020e575b5f80fd5b348015610159575f80fd5b50610174600480360381019061016f91906123db565b6104d2565b60405161018191906126cc565b60405180910390f35b6101926107ac565b005b34801561019f575f80fd5b506101ba60048036038101906101b591906123db565b6107fd565b005b3480156101c7575f80fd5b506101d061080f565b6040516101dd91906126fb565b60405180910390f35b3480156101f1575f80fd5b5061020c6004803603810190610207919061273e565b610834565b005b348015610219575f80fd5b50610234600480360381019061022f9190612793565b610867565b005b61023e6108b2565b005b34801561024b575f80fd5b506102546108eb565b60405161026191906127cd565b60405180910390f35b6102726108f6565b005b61028e60048036038101906102899190612847565b610909565b005b34801561029b575f80fd5b506102a4610bee565b6040516102b191906128fd565b60405180910390f35b3480156102c5575f80fd5b506102ce610c13565b6040516102db9190612925565b60405180910390f35b3480156102ef575f80fd5b5061030a6004803603810190610305919061273e565b610c2d565b005b348015610317575f80fd5b50610320610c61565b60405161032d91906126fb565b60405180910390f35b610350600480360381019061034b919061293e565b610c89565b005b34801561035d575f80fd5b50610366610c9e565b60405161037391906127cd565b60405180910390f35b348015610387575f80fd5b50610390610ca4565b60405161039d91906129e2565b60405180910390f35b3480156103b1575f80fd5b506103ba610cc9565b6040516103c79190612925565b60405180910390f35b3480156103db575f80fd5b506103e4610ce2565b6040516103f19190612925565b60405180910390f35b348015610405575f80fd5b50610420600480360381019061041b91906129fb565b610ce8565b60405161042d91906126cc565b60405180910390f35b348015610441575f80fd5b5061045c60048036038101906104579190612793565b611758565b005b61047860048036038101906104739190612793565b6117a3565b005b610494600480360381019061048f9190612793565b6117e1565b005b3480156104a1575f80fd5b506104bc60048036038101906104b79190612793565b61180a565b6040516104c991906127cd565b60405180910390f35b6104da61222f565b5f82815481106104ed576104ec612a46565b5b905f5260205f209060080201604051806101200160405290815f82015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001600182015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001600282015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001600382015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001600482018054806020026020016040519081016040528092919081815260200182805480156106da57602002820191905f5260205f20905b815f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019060010190808311610691575b50505050508152602001600582015f9054906101000a900467ffffffffffffffff1667ffffffffffffffff1667ffffffffffffffff1681526020016005820160089054906101000a900467ffffffffffffffff1667ffffffffffffffff1667ffffffffffffffff16815260200160068201548152602001600782015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815250509050919050565b5f6107b5611823565b67ffffffffffffffff164201905063389a75e1600c52335f52806020600c2055337fdbf36a107da19e49527a7176a1babf963b4b0ff8cde35ee35d6cd8f1f9ac7e1d5f80a250565b61080561182d565b8060048190555050565b60035f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b61083c61182d565b8060055f6101000a81548167ffffffffffffffff021916908367ffffffffffffffff16021790555050565b61086f61182d565b8060035f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b63389a75e1600c52335f525f6020600c2055337ffa7b8eab7da67f412cc9575ed43464468f9bfbae89d1675917346ca6d8fe3c925f80a2565b5f8080549050905090565b6108fe61182d565b6109075f611864565b565b3068929eee149b4bd2126854036109275763ab143c065f526004601cfd5b3068929eee149b4bd21268555f80878154811061094757610946612a46565b5b905f5260205f20906008020190506004543410156109a2575f346004546040517f5c54305e00000000000000000000000000000000000000000000000000000000815260040161099993929190612a73565b60405180910390fd5b6109ac818661192a565b806001015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663703b690088888588886040518663ffffffff1660e01b8152600401610a10959493929190612b02565b6020604051808303815f875af1158015610a2c573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610a509190612b83565b610a86576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806004018681548110610a9c57610a9b612a46565b5b905f5260205f20015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663bb1757cf8386866040518463ffffffff1660e01b8152600401610b0093929190612bae565b6020604051808303815f875af1158015610b1c573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610b409190612b83565b610b85578184846040517f4139d81d000000000000000000000000000000000000000000000000000000008152600401610b7c93929190612bae565b60405180910390fd5b8173ffffffffffffffffffffffffffffffffffffffff1686887f0f29bbf4ce25d2346bbeb8a898e24e5d6d7d1d19bb895e71faecac833b259547888888604051610bd193929190612bae565b60405180910390a4503868929eee149b4bd2126855505050505050565b60015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600560089054906101000a900467ffffffffffffffff1681565b610c3561182d565b80600560086101000a81548167ffffffffffffffff021916908367ffffffffffffffff16021790555050565b5f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffff7487392754905090565b610c97858585858533610909565b5050505050565b60045481565b60025f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60055f9054906101000a900467ffffffffffffffff1681565b61271081565b610cf061222f565b335f73ffffffffffffffffffffffffffffffffffffffff1660025f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614158015610de4575060025f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fe9fbb80826040518263ffffffff1660e01b8152600401610da391906126fb565b602060405180830381865afa158015610dbe573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610de29190612b83565b155b15610e1b576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3068929eee149b4bd212685403610e395763ab143c065f526004601cfd5b3068929eee149b4bd21268555f610e9285858080601f0160208091040260200160405190810160405280939291908181526020018383808284375f81840152601f19601f82011690508083019250505050505050611a98565b806020019051810190610ea5919061303e565b9050610eb3815f0151611b31565b5f8060018160018154018082558091505003905f5260205f2090600802019050816101000151816007015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550815f0151816003015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508160a0015160055f9054906101000a900467ffffffffffffffff16610f8491906130b2565b816005015f6101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055508160c00151600560089054906101000a900467ffffffffffffffff16610fd391906130b2565b8160050160086101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055508160e00151816006018190555061103a7fe67157950000000000000000000000000000000000000000000000000000000083602001516001611c0c565b815f015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506110aa7fe2089f790000000000000000000000000000000000000000000000000000000083606001516001611c0c565b816002015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506110fc8260800151835f0151611c2e565b8160040190805190602001906111139291906122f5565b505f73ffffffffffffffffffffffffffffffffffffffff1682604001516020015173ffffffffffffffffffffffffffffffffffffffff16146111845761117f7f5912b89c0000000000000000000000000000000000000000000000000000000083604001516001611c0c565b61126d565b805f015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166301ffc9a77f5912b89c000000000000000000000000000000000000000000000000000000006040518263ffffffff1660e01b81526004016111ff9190613127565b602060405180830381865afa15801561121a573d5f803e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061123e9190612b83565b611248575f61126c565b805f015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff165b5b816001015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505f73ffffffffffffffffffffffffffffffffffffffff16816001015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1603611363577f5912b89c000000000000000000000000000000000000000000000000000000005f6040517fe1c4444800000000000000000000000000000000000000000000000000000000815260040161135a929190613140565b60405180910390fd5b805f015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16816007015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1660015f805490506113e79190613167565b7f116812d3ad4507d72f2c428b63246d594ca055a1dc119394285504c23d1f34cd8460040180549050856001015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16866002015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16876003015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1660405161148c949392919061319a565b60405180910390a480604051806101200160405290815f82015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001600182015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001600282015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001600382015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016004820180548060200260200160405190810160405280929190818152602001828054801561167657602002820191905f5260205f20905b815f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001906001019080831161162d575b50505050508152602001600582015f9054906101000a900467ffffffffffffffff1667ffffffffffffffff1667ffffffffffffffff1681526020016005820160089054906101000a900467ffffffffffffffff1667ffffffffffffffff1667ffffffffffffffff16815260200160068201548152602001600782015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681525050935050503868929eee149b4bd21268555092915050565b61176061182d565b8060025f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b6117ab61182d565b63389a75e1600c52805f526020600c2080544211156117d157636f5e88185f526004601cfd5b5f8155506117de81611864565b50565b6117e961182d565b8060601b6117fe57637448fbae5f526004601cfd5b61180781611864565b50565b5f63389a75e1600c52815f526020600c20549050919050565b5f6202a300905090565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffff74873927543314611862576382b429005f526004601cfd5b565b61186c611ff8565b156118d1577fffffffffffffffffffffffffffffffffffffffffffffffffffffffff748739278160601b60601c91508181547f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e05f80a3811560ff1b8217815550611927565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffff748739278160601b60601c91508181547f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e05f80a3818155505b50565b5f6004540315611a94575f60045490505f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16146119f0575f61271067ffffffffffffffff168460050160089054906101000a900467ffffffffffffffff1667ffffffffffffffff166004546119ab91906131dd565b6119b5919061324b565b905080826119c39190613167565b91506119ee818473ffffffffffffffffffffffffffffffffffffffff16611ffc90919063ffffffff16565b505b611a48600282611a00919061324b565b846007015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16611ffc90919063ffffffff16565b611a924760035f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16611ffc90919063ffffffff16565b505b5050565b6060815115611b2c5760405190506020810160048301805184518501811983525b80861015611b12576001860195508551601f1a80611b02576001870196508651601f1a5f198652607f8111611af057600181013887395b6001607f821601860195505050611b0d565b808553600185019450505b611ab9565b81835260208501840385525f845260208401604052505050505b919050565b611b5b7f579cba440000000000000000000000000000000000000000000000000000000082612019565b8073ffffffffffffffffffffffffffffffffffffffff1663fe9fbb80336040518263ffffffff1660e01b8152600401611b9491906126fb565b602060405180830381865afa158015611baf573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190611bd39190612b83565b611c09576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b50565b5f611c1b848460200151612019565b611c258383612110565b90509392505050565b6060825167ffffffffffffffff811115611c4b57611c4a612be2565b5b604051908082528060200260200182016040528015611c795781602001602082028036833780820191505090505b5090505f5b8351811015611ff157611ccf7f5970a68900000000000000000000000000000000000000000000000000000000858381518110611cbe57611cbd612a46565b5b602002602001015160200151612019565b838181518110611ce257611ce1612a46565b5b60200260200101515f0151611d6e577f5970a68900000000000000000000000000000000000000000000000000000000848281518110611d2557611d24612a46565b5b6020026020010151602001516040517fe1c44448000000000000000000000000000000000000000000000000000000008152600401611d65929190613140565b60405180910390fd5b611db37f5970a68900000000000000000000000000000000000000000000000000000000858381518110611da557611da4612a46565b5b60200260200101515f611c0c565b828281518110611dc657611dc5612a46565b5b602002602001019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff16815250505f828281518110611e1457611e13612a46565b5b602002602001015173ffffffffffffffffffffffffffffffffffffffff16634e7165a2868481518110611e4a57611e49612a46565b5b6020026020010151604001516040518263ffffffff1660e01b8152600401611e7291906132bd565b5f60405180830381865afa158015611e8c573d5f803e3d5ffd5b505050506040513d5f823e3d601f19601f82011682018060405250810190611eb491906132dd565b90505f815114611f45578373ffffffffffffffffffffffffffffffffffffffff1663fa4ca9b1826040518263ffffffff1660e01b8152600401611ef791906132bd565b6020604051808303815f875af1158015611f13573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190611f379190612b83565b611f4457611f43613324565b5b5b828281518110611f5857611f57612a46565b5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1663439fab91868481518110611f8e57611f8d612a46565b5b6020026020010151604001516040518263ffffffff1660e01b8152600401611fb691906132bd565b5f604051808303815f87803b158015611fcd575f80fd5b505af1158015611fdf573d5f803e3d5ffd5b50505050508080600101915050611c7e565b5092915050565b5f90565b5f385f3884865af16120155763b12d13eb5f526004601cfd5b5050565b5f73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614806120c857508073ffffffffffffffffffffffffffffffffffffffff166301ffc9a7836040518263ffffffff1660e01b81526004016120879190613127565b602060405180830381865afa1580156120a2573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906120c69190612b83565b155b1561210c5781816040517fe1c44448000000000000000000000000000000000000000000000000000000008152600401612103929190613140565b60405180910390fd5b5050565b5f825f0151612123578260200151612147565b612146836020015173ffffffffffffffffffffffffffffffffffffffff166121cc565b5b9050825f015180156121565750815b156121c6578073ffffffffffffffffffffffffffffffffffffffff1663439fab9184604001516040518263ffffffff1660e01b815260040161219891906132bd565b5f604051808303815f87803b1580156121af575f80fd5b505af11580156121c1573d5f803e3d5ffd5b505050505b92915050565b5f6121d75f836121de565b9050919050565b5f6c5af43d3d93803e602a57fd5bf36021528160145273602c3d8160093d39f33d3d3d3d363d3d37363d735f526035600c84f09050806122255763301164255f526004601cfd5b5f60215292915050565b6040518061012001604052805f73ffffffffffffffffffffffffffffffffffffffff1681526020015f73ffffffffffffffffffffffffffffffffffffffff1681526020015f73ffffffffffffffffffffffffffffffffffffffff1681526020015f73ffffffffffffffffffffffffffffffffffffffff168152602001606081526020015f67ffffffffffffffff1681526020015f67ffffffffffffffff1681526020015f81526020015f73ffffffffffffffffffffffffffffffffffffffff1681525090565b828054828255905f5260205f2090810192821561236b579160200282015b8281111561236a578251825f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555091602001919060010190612313565b5b509050612378919061237c565b5090565b5b80821115612393575f815f90555060010161237d565b5090565b5f604051905090565b5f80fd5b5f80fd5b5f819050919050565b6123ba816123a8565b81146123c4575f80fd5b50565b5f813590506123d5816123b1565b92915050565b5f602082840312156123f0576123ef6123a0565b5b5f6123fd848285016123c7565b91505092915050565b5f73ffffffffffffffffffffffffffffffffffffffff82169050919050565b5f819050919050565b5f61244861244361243e84612406565b612425565b612406565b9050919050565b5f6124598261242e565b9050919050565b5f61246a8261244f565b9050919050565b61247a81612460565b82525050565b5f61248a8261244f565b9050919050565b61249a81612480565b82525050565b5f6124aa8261244f565b9050919050565b6124ba816124a0565b82525050565b5f6124ca8261242e565b9050919050565b5f6124db826124c0565b9050919050565b6124eb816124d1565b82525050565b5f81519050919050565b5f82825260208201905092915050565b5f819050602082019050919050565b5f6125248261244f565b9050919050565b6125348161251a565b82525050565b5f612545838361252b565b60208301905092915050565b5f602082019050919050565b5f612567826124f1565b61257181856124fb565b935061257c8361250b565b805f5b838110156125ac578151612593888261253a565b975061259e83612551565b92505060018101905061257f565b5085935050505092915050565b5f67ffffffffffffffff82169050919050565b6125d5816125b9565b82525050565b6125e4816123a8565b82525050565b5f6125f482612406565b9050919050565b612604816125ea565b82525050565b5f61012083015f8301516126205f860182612471565b5060208301516126336020860182612491565b50604083015161264660408601826124b1565b50606083015161265960608601826124e2565b5060808301518482036080860152612671828261255d565b91505060a083015161268660a08601826125cc565b5060c083015161269960c08601826125cc565b5060e08301516126ac60e08601826125db565b506101008301516126c16101008601826125fb565b508091505092915050565b5f6020820190508181035f8301526126e4818461260a565b905092915050565b6126f5816125ea565b82525050565b5f60208201905061270e5f8301846126ec565b92915050565b61271d816125b9565b8114612727575f80fd5b50565b5f8135905061273881612714565b92915050565b5f60208284031215612753576127526123a0565b5b5f6127608482850161272a565b91505092915050565b612772816125ea565b811461277c575f80fd5b50565b5f8135905061278d81612769565b92915050565b5f602082840312156127a8576127a76123a0565b5b5f6127b58482850161277f565b91505092915050565b6127c7816123a8565b82525050565b5f6020820190506127e05f8301846127be565b92915050565b5f80fd5b5f80fd5b5f80fd5b5f8083601f840112612807576128066127e6565b5b8235905067ffffffffffffffff811115612824576128236127ea565b5b6020830191508360018202830111156128405761283f6127ee565b5b9250929050565b5f805f805f8060a08789031215612861576128606123a0565b5b5f61286e89828a016123c7565b965050602061287f89828a016123c7565b955050604061289089828a0161277f565b945050606087013567ffffffffffffffff8111156128b1576128b06123a4565b5b6128bd89828a016127f2565b935093505060806128d089828a0161277f565b9150509295509295509295565b5f6128e78261244f565b9050919050565b6128f7816128dd565b82525050565b5f6020820190506129105f8301846128ee565b92915050565b61291f816125b9565b82525050565b5f6020820190506129385f830184612916565b92915050565b5f805f805f60808688031215612957576129566123a0565b5b5f612964888289016123c7565b9550506020612975888289016123c7565b94505060406129868882890161277f565b935050606086013567ffffffffffffffff8111156129a7576129a66123a4565b5b6129b3888289016127f2565b92509250509295509295909350565b5f6129cc8261244f565b9050919050565b6129dc816129c2565b82525050565b5f6020820190506129f55f8301846129d3565b92915050565b5f8060208385031215612a1157612a106123a0565b5b5f83013567ffffffffffffffff811115612a2e57612a2d6123a4565b5b612a3a858286016127f2565b92509250509250929050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52603260045260245ffd5b5f606082019050612a865f8301866126ec565b612a9360208301856127be565b612aa060408301846127be565b949350505050565b5f82825260208201905092915050565b828183375f83830152505050565b5f601f19601f8301169050919050565b5f612ae18385612aa8565b9350612aee838584612ab8565b612af783612ac6565b840190509392505050565b5f608082019050612b155f8301886127be565b612b2260208301876127be565b612b2f60408301866126ec565b8181036060830152612b42818486612ad6565b90509695505050505050565b5f8115159050919050565b612b6281612b4e565b8114612b6c575f80fd5b50565b5f81519050612b7d81612b59565b92915050565b5f60208284031215612b9857612b976123a0565b5b5f612ba584828501612b6f565b91505092915050565b5f604082019050612bc15f8301866126ec565b8181036020830152612bd4818486612ad6565b9050949350505050565b5f80fd5b7f4e487b71000000000000000000000000000000000000000000000000000000005f52604160045260245ffd5b612c1882612ac6565b810181811067ffffffffffffffff82111715612c3757612c36612be2565b5b80604052505050565b5f612c49612397565b9050612c558282612c0f565b919050565b5f80fd5b5f612c6882612406565b9050919050565b5f612c7982612c5e565b9050919050565b612c8981612c6f565b8114612c93575f80fd5b50565b5f81519050612ca481612c80565b92915050565b5f81519050612cb881612769565b92915050565b5f80fd5b5f67ffffffffffffffff821115612cdc57612cdb612be2565b5b612ce582612ac6565b9050602081019050919050565b8281835e5f83830152505050565b5f612d12612d0d84612cc2565b612c40565b905082815260208101848484011115612d2e57612d2d612cbe565b5b612d39848285612cf2565b509392505050565b5f82601f830112612d5557612d546127e6565b5b8151612d65848260208601612d00565b91505092915050565b5f60608284031215612d8357612d82612bde565b5b612d8d6060612c40565b90505f612d9c84828501612b6f565b5f830152506020612daf84828501612caa565b602083015250604082015167ffffffffffffffff811115612dd357612dd2612c5a565b5b612ddf84828501612d41565b60408301525092915050565b5f67ffffffffffffffff821115612e0557612e04612be2565b5b602082029050602081019050919050565b5f612e28612e2384612deb565b612c40565b90508083825260208201905060208402830185811115612e4b57612e4a6127ee565b5b835b81811015612e9257805167ffffffffffffffff811115612e7057612e6f6127e6565b5b808601612e7d8982612d6e565b85526020850194505050602081019050612e4d565b5050509392505050565b5f82601f830112612eb057612eaf6127e6565b5b8151612ec0848260208601612e16565b91505092915050565b5f81519050612ed781612714565b92915050565b5f81519050612eeb816123b1565b92915050565b5f6101208284031215612f0757612f06612bde565b5b612f12610120612c40565b90505f612f2184828501612c96565b5f83015250602082015167ffffffffffffffff811115612f4457612f43612c5a565b5b612f5084828501612d6e565b602083015250604082015167ffffffffffffffff811115612f7457612f73612c5a565b5b612f8084828501612d6e565b604083015250606082015167ffffffffffffffff811115612fa457612fa3612c5a565b5b612fb084828501612d6e565b606083015250608082015167ffffffffffffffff811115612fd457612fd3612c5a565b5b612fe084828501612e9c565b60808301525060a0612ff484828501612ec9565b60a08301525060c061300884828501612ec9565b60c08301525060e061301c84828501612edd565b60e08301525061010061303184828501612caa565b6101008301525092915050565b5f60208284031215613053576130526123a0565b5b5f82015167ffffffffffffffff8111156130705761306f6123a4565b5b61307c84828501612ef1565b91505092915050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601160045260245ffd5b5f6130bc826125b9565b91506130c7836125b9565b9250828201905067ffffffffffffffff8111156130e7576130e6613085565b5b92915050565b5f7fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b613121816130ed565b82525050565b5f60208201905061313a5f830184613118565b92915050565b5f6040820190506131535f830185613118565b61316060208301846126ec565b9392505050565b5f613171826123a8565b915061317c836123a8565b925082820390508181111561319457613193613085565b5b92915050565b5f6080820190506131ad5f8301876127be565b6131ba60208301866126ec565b6131c760408301856126ec565b6131d460608301846126ec565b95945050505050565b5f6131e7826123a8565b91506131f2836123a8565b9250828202613200816123a8565b9150828204841483151761321757613216613085565b5b5092915050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601260045260245ffd5b5f613255826123a8565b9150613260836123a8565b9250826132705761326f61321e565b5b828204905092915050565b5f81519050919050565b5f61328f8261327b565b6132998185612aa8565b93506132a9818560208601612cf2565b6132b281612ac6565b840191505092915050565b5f6020820190508181035f8301526132d58184613285565b905092915050565b5f602082840312156132f2576132f16123a0565b5b5f82015167ffffffffffffffff81111561330f5761330e6123a4565b5b61331b84828501612d41565b91505092915050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52600160045260245ffdfea264697066735822122024def9a895986486dd724b09cc789a35bd4c181a104eebeaabb0ca6aa54fe8cc64736f6c634300081a0033";
|
|
27
|
-
function z(a) {
|
|
28
|
-
const e = a.state.current, f = a.state.connections.get(e), b = f == null ? void 0 : f.accounts, t = b == null ? void 0 : b[0], c = a.chains.find((i) => i.id === (f == null ? void 0 : f.chainId)), n = a.state.status;
|
|
29
|
-
switch (n) {
|
|
30
|
-
case "connected":
|
|
31
|
-
return {
|
|
32
|
-
address: t,
|
|
33
|
-
addresses: b,
|
|
34
|
-
chain: c,
|
|
35
|
-
chainId: f == null ? void 0 : f.chainId,
|
|
36
|
-
connector: f == null ? void 0 : f.connector,
|
|
37
|
-
isConnected: !0,
|
|
38
|
-
isConnecting: !1,
|
|
39
|
-
isDisconnected: !1,
|
|
40
|
-
isReconnecting: !1,
|
|
41
|
-
status: n
|
|
42
|
-
};
|
|
43
|
-
case "reconnecting":
|
|
44
|
-
return {
|
|
45
|
-
address: t,
|
|
46
|
-
addresses: b,
|
|
47
|
-
chain: c,
|
|
48
|
-
chainId: f == null ? void 0 : f.chainId,
|
|
49
|
-
connector: f == null ? void 0 : f.connector,
|
|
50
|
-
isConnected: !!t,
|
|
51
|
-
isConnecting: !1,
|
|
52
|
-
isDisconnected: !1,
|
|
53
|
-
isReconnecting: !0,
|
|
54
|
-
status: n
|
|
55
|
-
};
|
|
56
|
-
case "connecting":
|
|
57
|
-
return {
|
|
58
|
-
address: t,
|
|
59
|
-
addresses: b,
|
|
60
|
-
chain: c,
|
|
61
|
-
chainId: f == null ? void 0 : f.chainId,
|
|
62
|
-
connector: f == null ? void 0 : f.connector,
|
|
63
|
-
isConnected: !1,
|
|
64
|
-
isConnecting: !0,
|
|
65
|
-
isDisconnected: !1,
|
|
66
|
-
isReconnecting: !1,
|
|
67
|
-
status: n
|
|
68
|
-
};
|
|
69
|
-
case "disconnected":
|
|
70
|
-
return {
|
|
71
|
-
address: void 0,
|
|
72
|
-
addresses: void 0,
|
|
73
|
-
chain: void 0,
|
|
74
|
-
chainId: void 0,
|
|
75
|
-
connector: void 0,
|
|
76
|
-
isConnected: !1,
|
|
77
|
-
isConnecting: !1,
|
|
78
|
-
isDisconnected: !0,
|
|
79
|
-
isReconnecting: !1,
|
|
80
|
-
status: n
|
|
81
|
-
};
|
|
82
|
-
}
|
|
83
|
-
}
|
|
84
|
-
function Kf(a) {
|
|
85
|
-
return a.state.chainId;
|
|
86
|
-
}
|
|
87
|
-
function G(a, e, f) {
|
|
88
|
-
const b = a[e.name];
|
|
89
|
-
if (typeof b == "function")
|
|
90
|
-
return b;
|
|
91
|
-
const t = a[f];
|
|
92
|
-
return typeof t == "function" ? t : (c) => e(a, c);
|
|
93
|
-
}
|
|
94
|
-
const Xf = "2.13.8", Yf = () => `@wagmi/core@${Xf}`;
|
|
95
|
-
var U = function(a, e, f, b) {
|
|
96
|
-
if (f === "a" && !b) throw new TypeError("Private accessor was defined without a getter");
|
|
97
|
-
if (typeof e == "function" ? a !== e || !b : !e.has(a)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
98
|
-
return f === "m" ? b : f === "a" ? b.call(a) : b ? b.value : e.get(a);
|
|
99
|
-
}, E, k;
|
|
100
|
-
class C extends Error {
|
|
101
|
-
get docsBaseUrl() {
|
|
102
|
-
return "https://wagmi.sh/core";
|
|
103
|
-
}
|
|
104
|
-
get version() {
|
|
105
|
-
return Yf();
|
|
106
|
-
}
|
|
107
|
-
constructor(e, f = {}) {
|
|
108
|
-
var c;
|
|
109
|
-
super(), E.add(this), Object.defineProperty(this, "details", {
|
|
110
|
-
enumerable: !0,
|
|
111
|
-
configurable: !0,
|
|
112
|
-
writable: !0,
|
|
113
|
-
value: void 0
|
|
114
|
-
}), Object.defineProperty(this, "docsPath", {
|
|
115
|
-
enumerable: !0,
|
|
116
|
-
configurable: !0,
|
|
117
|
-
writable: !0,
|
|
118
|
-
value: void 0
|
|
119
|
-
}), Object.defineProperty(this, "metaMessages", {
|
|
120
|
-
enumerable: !0,
|
|
121
|
-
configurable: !0,
|
|
122
|
-
writable: !0,
|
|
123
|
-
value: void 0
|
|
124
|
-
}), Object.defineProperty(this, "shortMessage", {
|
|
125
|
-
enumerable: !0,
|
|
126
|
-
configurable: !0,
|
|
127
|
-
writable: !0,
|
|
128
|
-
value: void 0
|
|
129
|
-
}), Object.defineProperty(this, "name", {
|
|
130
|
-
enumerable: !0,
|
|
131
|
-
configurable: !0,
|
|
132
|
-
writable: !0,
|
|
133
|
-
value: "WagmiCoreError"
|
|
134
|
-
});
|
|
135
|
-
const b = f.cause instanceof C ? f.cause.details : (c = f.cause) != null && c.message ? f.cause.message : f.details, t = f.cause instanceof C && f.cause.docsPath || f.docsPath;
|
|
136
|
-
this.message = [
|
|
137
|
-
e || "An error occurred.",
|
|
138
|
-
"",
|
|
139
|
-
...f.metaMessages ? [...f.metaMessages, ""] : [],
|
|
140
|
-
...t ? [
|
|
141
|
-
`Docs: ${this.docsBaseUrl}${t}.html${f.docsSlug ? `#${f.docsSlug}` : ""}`
|
|
142
|
-
] : [],
|
|
143
|
-
...b ? [`Details: ${b}`] : [],
|
|
144
|
-
`Version: ${this.version}`
|
|
145
|
-
].join(`
|
|
146
|
-
`), f.cause && (this.cause = f.cause), this.details = b, this.docsPath = t, this.metaMessages = f.metaMessages, this.shortMessage = e;
|
|
147
|
-
}
|
|
148
|
-
walk(e) {
|
|
149
|
-
return U(this, E, "m", k).call(this, this, e);
|
|
150
|
-
}
|
|
151
|
-
}
|
|
152
|
-
E = /* @__PURE__ */ new WeakSet(), k = function a(e, f) {
|
|
153
|
-
return f != null && f(e) ? e : e.cause ? U(this, E, "m", a).call(this, e.cause, f) : e;
|
|
154
|
-
};
|
|
155
|
-
class Zf extends C {
|
|
156
|
-
constructor() {
|
|
157
|
-
super("Connector not connected."), Object.defineProperty(this, "name", {
|
|
158
|
-
enumerable: !0,
|
|
159
|
-
configurable: !0,
|
|
160
|
-
writable: !0,
|
|
161
|
-
value: "ConnectorNotConnectedError"
|
|
162
|
-
});
|
|
163
|
-
}
|
|
164
|
-
}
|
|
165
|
-
class f0 extends C {
|
|
166
|
-
constructor({ address: e, connector: f }) {
|
|
167
|
-
super(`Account "${e}" not found for connector "${f.name}".`), Object.defineProperty(this, "name", {
|
|
168
|
-
enumerable: !0,
|
|
169
|
-
configurable: !0,
|
|
170
|
-
writable: !0,
|
|
171
|
-
value: "ConnectorAccountNotFoundError"
|
|
172
|
-
});
|
|
173
|
-
}
|
|
174
|
-
}
|
|
175
|
-
class e0 extends C {
|
|
176
|
-
constructor({ connectionChainId: e, connectorChainId: f }) {
|
|
177
|
-
super(`The current chain of the connector (id: ${f}) does not match the connection's chain (id: ${e}).`, {
|
|
178
|
-
metaMessages: [
|
|
179
|
-
`Current Chain ID: ${f}`,
|
|
180
|
-
`Expected Chain ID: ${e}`
|
|
181
|
-
]
|
|
182
|
-
}), Object.defineProperty(this, "name", {
|
|
183
|
-
enumerable: !0,
|
|
184
|
-
configurable: !0,
|
|
185
|
-
writable: !0,
|
|
186
|
-
value: "ConnectorChainMismatchError"
|
|
187
|
-
});
|
|
188
|
-
}
|
|
189
|
-
}
|
|
190
|
-
class b0 extends C {
|
|
191
|
-
constructor({ connector: e }) {
|
|
192
|
-
super(`Connector "${e.name}" unavailable while reconnecting.`, {
|
|
193
|
-
details: [
|
|
194
|
-
"During the reconnection step, the only connector methods guaranteed to be available are: `id`, `name`, `type`, `uuid`.",
|
|
195
|
-
"All other methods are not guaranteed to be available until reconnection completes and connectors are fully restored.",
|
|
196
|
-
"This error commonly occurs for connectors that asynchronously inject after reconnection has already started."
|
|
197
|
-
].join(" ")
|
|
198
|
-
}), Object.defineProperty(this, "name", {
|
|
199
|
-
enumerable: !0,
|
|
200
|
-
configurable: !0,
|
|
201
|
-
writable: !0,
|
|
202
|
-
value: "ConnectorUnavailableReconnectingError"
|
|
203
|
-
});
|
|
204
|
-
}
|
|
205
|
-
}
|
|
206
|
-
async function W(a, e = {}) {
|
|
207
|
-
let f;
|
|
208
|
-
if (e.connector) {
|
|
209
|
-
const { connector: s } = e;
|
|
210
|
-
if (a.state.status === "reconnecting" && !s.getAccounts && !s.getChainId)
|
|
211
|
-
throw new b0({ connector: s });
|
|
212
|
-
const [o, h] = await Promise.all([
|
|
213
|
-
s.getAccounts(),
|
|
214
|
-
s.getChainId()
|
|
215
|
-
]);
|
|
216
|
-
f = {
|
|
217
|
-
accounts: o,
|
|
218
|
-
chainId: h,
|
|
219
|
-
connector: s
|
|
220
|
-
};
|
|
221
|
-
} else
|
|
222
|
-
f = a.state.connections.get(a.state.current);
|
|
223
|
-
if (!f)
|
|
224
|
-
throw new Zf();
|
|
225
|
-
const b = e.chainId ?? f.chainId, t = await f.connector.getChainId();
|
|
226
|
-
if (t !== f.chainId)
|
|
227
|
-
throw new e0({
|
|
228
|
-
connectionChainId: f.chainId,
|
|
229
|
-
connectorChainId: t
|
|
230
|
-
});
|
|
231
|
-
const c = f.connector;
|
|
232
|
-
if (c.getClient)
|
|
233
|
-
return c.getClient({ chainId: b });
|
|
234
|
-
const n = Hf(e.account ?? f.accounts[0]);
|
|
235
|
-
if (n.address = Jf(n.address), e.account && !f.accounts.some((s) => s.toLowerCase() === n.address.toLowerCase()))
|
|
236
|
-
throw new f0({
|
|
237
|
-
address: n.address,
|
|
238
|
-
connector: c
|
|
239
|
-
});
|
|
240
|
-
const i = a.chains.find((s) => s.id === b), d = await f.connector.getProvider({ chainId: b });
|
|
241
|
-
return mf({
|
|
242
|
-
account: n,
|
|
243
|
-
chain: i,
|
|
244
|
-
name: "Connector Client",
|
|
245
|
-
transport: (s) => yf(d)({ ...s, retryCount: 0 })
|
|
246
|
-
});
|
|
247
|
-
}
|
|
248
|
-
async function t0(a, e) {
|
|
249
|
-
const { abi: f, chainId: b, connector: t, ...c } = e;
|
|
250
|
-
let n;
|
|
251
|
-
e.account ? n = e.account : n = (await W(a, {
|
|
252
|
-
chainId: b,
|
|
253
|
-
connector: t
|
|
254
|
-
})).account;
|
|
255
|
-
const i = a.getClient({ chainId: b }), d = G(i, kf, "simulateContract"), { result: s, request: o } = await d({ ...c, abi: f, account: n });
|
|
256
|
-
return {
|
|
257
|
-
chainId: i.chain.id,
|
|
258
|
-
result: s,
|
|
259
|
-
request: { __mode: "prepared", ...o, chainId: b }
|
|
260
|
-
};
|
|
261
|
-
}
|
|
262
|
-
async function N(a, e) {
|
|
263
|
-
const { account: f, chainId: b, connector: t, __mode: c, ...n } = e;
|
|
264
|
-
let i;
|
|
265
|
-
typeof f == "object" && f.type === "local" ? i = a.getClient({ chainId: b }) : i = await W(a, { account: f, chainId: b, connector: t });
|
|
266
|
-
const { connector: d } = z(a);
|
|
267
|
-
let s;
|
|
268
|
-
if (c === "prepared" || d != null && d.supportsSimulation)
|
|
269
|
-
s = n;
|
|
270
|
-
else {
|
|
271
|
-
const { request: m } = await t0(a, {
|
|
272
|
-
...n,
|
|
273
|
-
account: f,
|
|
274
|
-
chainId: b
|
|
275
|
-
});
|
|
276
|
-
s = m;
|
|
277
|
-
}
|
|
278
|
-
return await G(i, Wf, "writeContract")({
|
|
279
|
-
...s,
|
|
280
|
-
...f ? { account: f } : {},
|
|
281
|
-
chain: b ? { id: b } : null
|
|
282
|
-
});
|
|
283
|
-
}
|
|
284
|
-
function a0(a) {
|
|
285
|
-
return a.address !== void 0 && typeof a.address == "object" ? (e, f) => {
|
|
286
|
-
var n;
|
|
287
|
-
const b = Kf(e), t = z(e);
|
|
288
|
-
let c;
|
|
289
|
-
return f.chainId ? c = f.chainId : f.account && f.account === t.address || f.account === void 0 ? c = t.chainId : c = b, N(e, {
|
|
290
|
-
...f,
|
|
291
|
-
...a.functionName ? { functionName: a.functionName } : {},
|
|
292
|
-
address: c ? (n = a.address) == null ? void 0 : n[c] : void 0,
|
|
293
|
-
abi: a.abi
|
|
294
|
-
});
|
|
295
|
-
} : (e, f) => N(e, {
|
|
296
|
-
...f,
|
|
297
|
-
...a.address ? { address: a.address } : {},
|
|
298
|
-
...a.functionName ? { functionName: a.functionName } : {},
|
|
299
|
-
abi: a.abi
|
|
300
|
-
});
|
|
301
|
-
}
|
|
302
|
-
const L0 = Cf("0.000075"), S0 = T[11155111], q = {
|
|
303
|
-
...T,
|
|
304
|
-
31337: void 0
|
|
305
|
-
};
|
|
306
|
-
function c0(a) {
|
|
307
|
-
return a.address;
|
|
308
|
-
}
|
|
309
|
-
function n0(a) {
|
|
310
|
-
return a.registryAddress && a.protocolFeeReceiver;
|
|
311
|
-
}
|
|
312
|
-
const S = class S extends Of {
|
|
313
|
-
/**
|
|
314
|
-
* A getter that will return Boost core's static addresses by numerical chain ID
|
|
315
|
-
*
|
|
316
|
-
* @public
|
|
317
|
-
* @readonly
|
|
318
|
-
* @type {Record<number, Address>}
|
|
319
|
-
*/
|
|
320
|
-
get addresses() {
|
|
321
|
-
return this.constructor.addresses;
|
|
322
|
-
}
|
|
323
|
-
/**
|
|
324
|
-
* Creates an instance of BoostCore.
|
|
325
|
-
*
|
|
326
|
-
* @constructor
|
|
327
|
-
* @param {BoostCoreConfig} param0
|
|
328
|
-
* @param {Config} param0.config
|
|
329
|
-
* @param {?Account} [param0.account]
|
|
330
|
-
* @param {({ address?: Address; } | { registryAddress: Address; protocolFeeReceiver: Address; })} param0....options
|
|
331
|
-
*/
|
|
332
|
-
constructor({ config: e, account: f, ...b }) {
|
|
333
|
-
if (c0(b) && b.address)
|
|
334
|
-
super({ account: f, config: e }, b.address);
|
|
335
|
-
else if (n0(b))
|
|
336
|
-
super({ account: f, config: e }, [
|
|
337
|
-
b.registryAddress,
|
|
338
|
-
b.protocolFeeReceiver
|
|
339
|
-
]);
|
|
340
|
-
else {
|
|
341
|
-
const { address: t } = l(
|
|
342
|
-
e,
|
|
343
|
-
q
|
|
344
|
-
);
|
|
345
|
-
super({ account: f, config: e }, t);
|
|
346
|
-
}
|
|
347
|
-
this.abi = R;
|
|
348
|
-
}
|
|
349
|
-
/**
|
|
350
|
-
* Create a new Boost.
|
|
351
|
-
*
|
|
352
|
-
* @public
|
|
353
|
-
* @async
|
|
354
|
-
* @param {CreateBoostPayload} _boostPayload
|
|
355
|
-
* @param {?DeployableOptions} [_options]
|
|
356
|
-
* @returns {Boost}
|
|
357
|
-
*/
|
|
358
|
-
async createBoost(e, f) {
|
|
359
|
-
var j, x;
|
|
360
|
-
const [b, t] = this.validateDeploymentConfig(e, f), c = ((j = f == null ? void 0 : f.chain) == null ? void 0 : j.id) || (f == null ? void 0 : f.chainId), { chainId: n, address: i } = l(
|
|
361
|
-
t.config,
|
|
362
|
-
this.addresses,
|
|
363
|
-
c
|
|
364
|
-
);
|
|
365
|
-
let {
|
|
366
|
-
budget: d,
|
|
367
|
-
action: s,
|
|
368
|
-
validator: o,
|
|
369
|
-
allowList: h,
|
|
370
|
-
incentives: m,
|
|
371
|
-
protocolFee: F = 0n,
|
|
372
|
-
referralFee: p = 0n,
|
|
373
|
-
maxParticipants: D = 0n,
|
|
374
|
-
owner: v
|
|
375
|
-
} = b;
|
|
376
|
-
const H = a0({
|
|
377
|
-
abi: R,
|
|
378
|
-
functionName: "createBoost",
|
|
379
|
-
address: i
|
|
380
|
-
});
|
|
381
|
-
if (!v && (v = ((x = this._account) == null ? void 0 : x.address) || gf(t.config).address || y, v === y))
|
|
382
|
-
throw new Vf();
|
|
383
|
-
let $ = y;
|
|
384
|
-
if (d.address) {
|
|
385
|
-
if ($ = d.address, !await d.isAuthorized(i))
|
|
386
|
-
throw new Tf(i);
|
|
387
|
-
} else
|
|
388
|
-
throw new zf();
|
|
389
|
-
let A = {
|
|
390
|
-
instance: y,
|
|
391
|
-
isBase: !0,
|
|
392
|
-
parameters: u
|
|
393
|
-
};
|
|
394
|
-
if (s.address) {
|
|
395
|
-
const r = s.isBase;
|
|
396
|
-
A = {
|
|
397
|
-
isBase: r,
|
|
398
|
-
instance: s.address,
|
|
399
|
-
parameters: r ? s.buildParameters(void 0, t).args.at(0) || u : u
|
|
400
|
-
};
|
|
401
|
-
} else
|
|
402
|
-
A.parameters = s.buildParameters(void 0, t).args.at(0) || u, A.instance = l(
|
|
403
|
-
t.config,
|
|
404
|
-
s.bases,
|
|
405
|
-
n
|
|
406
|
-
).address;
|
|
407
|
-
let I = {
|
|
408
|
-
instance: y,
|
|
409
|
-
isBase: !0,
|
|
410
|
-
parameters: u
|
|
411
|
-
};
|
|
412
|
-
if (o.address) {
|
|
413
|
-
const r = o.isBase;
|
|
414
|
-
I = {
|
|
415
|
-
isBase: r,
|
|
416
|
-
instance: o.address,
|
|
417
|
-
parameters: r ? o.buildParameters(
|
|
418
|
-
{
|
|
419
|
-
signers: [v],
|
|
420
|
-
validatorCaller: i
|
|
421
|
-
},
|
|
422
|
-
t
|
|
423
|
-
).args.at(0) || u : u
|
|
424
|
-
};
|
|
425
|
-
} else
|
|
426
|
-
I.parameters = o.buildParameters(
|
|
427
|
-
{
|
|
428
|
-
signers: [v],
|
|
429
|
-
validatorCaller: i
|
|
430
|
-
},
|
|
431
|
-
t
|
|
432
|
-
).args.at(0) || u, I.instance = l(
|
|
433
|
-
t.config,
|
|
434
|
-
o.bases,
|
|
435
|
-
n
|
|
436
|
-
).address;
|
|
437
|
-
let _ = {
|
|
438
|
-
instance: y,
|
|
439
|
-
isBase: !0,
|
|
440
|
-
parameters: u
|
|
441
|
-
};
|
|
442
|
-
if (h.address) {
|
|
443
|
-
const r = h.isBase;
|
|
444
|
-
_ = {
|
|
445
|
-
isBase: r,
|
|
446
|
-
instance: h.address,
|
|
447
|
-
parameters: r ? u : u
|
|
448
|
-
};
|
|
449
|
-
} else
|
|
450
|
-
_.parameters = h.buildParameters(void 0, t).args.at(0) || u, _.instance = l(
|
|
451
|
-
t.config,
|
|
452
|
-
h.bases,
|
|
453
|
-
n
|
|
454
|
-
).address;
|
|
455
|
-
const P = m.map(() => ({
|
|
456
|
-
instance: y,
|
|
457
|
-
isBase: !0,
|
|
458
|
-
parameters: u
|
|
459
|
-
}));
|
|
460
|
-
for (let r = 0; r < m.length; r++) {
|
|
461
|
-
const w = m.at(r);
|
|
462
|
-
if (w.address) {
|
|
463
|
-
const L = w.isBase;
|
|
464
|
-
if (!L) throw new Gf(w);
|
|
465
|
-
P[r] = {
|
|
466
|
-
isBase: L,
|
|
467
|
-
instance: w.address,
|
|
468
|
-
parameters: L ? w.buildParameters(void 0, t).args.at(0) || u : u
|
|
469
|
-
};
|
|
470
|
-
} else
|
|
471
|
-
P[r].parameters = w.buildParameters(void 0, t).args.at(0) || u, P[r].instance = l(
|
|
472
|
-
t.config,
|
|
473
|
-
w.bases,
|
|
474
|
-
n
|
|
475
|
-
).address;
|
|
476
|
-
}
|
|
477
|
-
const J = {
|
|
478
|
-
budget: $,
|
|
479
|
-
action: A,
|
|
480
|
-
validator: I,
|
|
481
|
-
allowList: _,
|
|
482
|
-
incentives: P,
|
|
483
|
-
protocolFee: F,
|
|
484
|
-
referralFee: p,
|
|
485
|
-
maxParticipants: D,
|
|
486
|
-
owner: v
|
|
487
|
-
}, Q = await H(t.config, {
|
|
488
|
-
...this.optionallyAttachAccount(t.account),
|
|
489
|
-
// biome-ignore lint/suspicious/noExplicitAny: Accept any shape of valid wagmi/viem parameters, wagmi does the same thing internally
|
|
490
|
-
...f,
|
|
491
|
-
chainId: n,
|
|
492
|
-
args: [Ff(J)]
|
|
493
|
-
}), K = await wf(t.config, {
|
|
494
|
-
hash: Q
|
|
495
|
-
}), B = vf({
|
|
496
|
-
abi: R,
|
|
497
|
-
eventName: "BoostCreated",
|
|
498
|
-
logs: K.logs
|
|
499
|
-
}).at(0);
|
|
500
|
-
let O = 0n;
|
|
501
|
-
if (!B) throw new Uf();
|
|
502
|
-
O = B == null ? void 0 : B.args.boostIndex;
|
|
503
|
-
const g = await this.readBoost(O);
|
|
504
|
-
return new M({
|
|
505
|
-
id: O,
|
|
506
|
-
budget: d.at(g.budget),
|
|
507
|
-
action: s.at(g.action),
|
|
508
|
-
validator: o.at(g.validator),
|
|
509
|
-
allowList: h.at(g.allowList),
|
|
510
|
-
incentives: m.map(
|
|
511
|
-
(r, w) => (
|
|
512
|
-
// biome-ignore lint/style/noNonNullAssertion: this will never be undefined
|
|
513
|
-
r.at(g.incentives.at(w))
|
|
514
|
-
)
|
|
515
|
-
),
|
|
516
|
-
protocolFee: g.protocolFee,
|
|
517
|
-
referralFee: g.referralFee,
|
|
518
|
-
maxParticipants: g.maxParticipants,
|
|
519
|
-
owner: g.owner
|
|
520
|
-
});
|
|
521
|
-
}
|
|
522
|
-
/**
|
|
523
|
-
* Claims one incentive from a given `Boost` by `boostId` and `incentiveId`
|
|
524
|
-
*
|
|
525
|
-
* @public
|
|
526
|
-
* @async
|
|
527
|
-
* @param {bigint} boostId
|
|
528
|
-
* @param {bigint} incentiveId
|
|
529
|
-
* @param {Address} address
|
|
530
|
-
* @param {Hex} data
|
|
531
|
-
* @param {?WriteParams<typeof boostCoreAbi, 'claimIncentive'>} [params]
|
|
532
|
-
* @returns {unknown}
|
|
533
|
-
*/
|
|
534
|
-
async claimIncentive(e, f, b, t, c) {
|
|
535
|
-
return await this.awaitResult(
|
|
536
|
-
this.claimIncentiveRaw(e, f, b, t, c)
|
|
537
|
-
);
|
|
538
|
-
}
|
|
539
|
-
/**
|
|
540
|
-
* Claim an incentive for a Boost
|
|
541
|
-
*
|
|
542
|
-
* @public
|
|
543
|
-
* @async
|
|
544
|
-
* @param {bigint} boostId - The ID of the Boost
|
|
545
|
-
* @param {bigint} incentiveId - The ID of the Incentive
|
|
546
|
-
* @param {Address} referrer - The address of the referrer (if any)
|
|
547
|
-
* @param {Hex} data- The data for the claim
|
|
548
|
-
* @param {?WriteParams<typeof boostCoreAbi, 'claimIncentive'>} [params]
|
|
549
|
-
* @returns {unknown}
|
|
550
|
-
*/
|
|
551
|
-
async claimIncentiveRaw(e, f, b, t, c) {
|
|
552
|
-
var s;
|
|
553
|
-
const { request: n, result: i } = await X(
|
|
554
|
-
this._config,
|
|
555
|
-
{
|
|
556
|
-
...l(
|
|
557
|
-
this._config,
|
|
558
|
-
this.addresses,
|
|
559
|
-
((s = c == null ? void 0 : c.chain) == null ? void 0 : s.id) || (c == null ? void 0 : c.chainId)
|
|
560
|
-
),
|
|
561
|
-
args: [e, f, b, t],
|
|
562
|
-
...this.optionallyAttachAccount(),
|
|
563
|
-
// biome-ignore lint/suspicious/noExplicitAny: Accept any shape of valid wagmi/viem parameters, wagmi does the same thing internally
|
|
564
|
-
...c
|
|
565
|
-
}
|
|
566
|
-
);
|
|
567
|
-
return { hash: await Y(this._config, n), result: i };
|
|
568
|
-
}
|
|
569
|
-
/**
|
|
570
|
-
* Claims one incentive for a given `Boost` on behalf of another user by `boostId` and `incentiveId`
|
|
571
|
-
*
|
|
572
|
-
* @public
|
|
573
|
-
* @async
|
|
574
|
-
* @param {bigint} boostId
|
|
575
|
-
* @param {bigint} incentiveId
|
|
576
|
-
* @param {Address} referrer
|
|
577
|
-
* @param {Hex} data
|
|
578
|
-
* @param {Address} claimant
|
|
579
|
-
* @param {?WriteParams<typeof boostCoreAbi, 'claimIncentiveFor'>} [params]
|
|
580
|
-
* @returns {unknown}
|
|
581
|
-
*/
|
|
582
|
-
async claimIncentiveFor(e, f, b, t, c, n) {
|
|
583
|
-
return await this.awaitResult(
|
|
584
|
-
this.claimIncentiveForRaw(
|
|
585
|
-
e,
|
|
586
|
-
f,
|
|
587
|
-
b,
|
|
588
|
-
t,
|
|
589
|
-
c,
|
|
590
|
-
n
|
|
591
|
-
)
|
|
592
|
-
);
|
|
593
|
-
}
|
|
594
|
-
/**
|
|
595
|
-
* Claim an incentive for a Boost on behalf of another user
|
|
596
|
-
*
|
|
597
|
-
* @public
|
|
598
|
-
* @async
|
|
599
|
-
* @param {bigint} boostId - The ID of the Boost
|
|
600
|
-
* @param {bigint} incentiveId - The ID of the Incentive
|
|
601
|
-
* @param {Address} referrer - The address of the referrer (if any)
|
|
602
|
-
* @param {Hex} data - The data for the claim
|
|
603
|
-
* @param {Address} claimant - The address of the user eligible for the incentive payout
|
|
604
|
-
* @param {?WriteParams<typeof boostCoreAbi, 'claimIncentiveFor'>} [params]
|
|
605
|
-
* @returns {unknown}
|
|
606
|
-
*/
|
|
607
|
-
async claimIncentiveForRaw(e, f, b, t, c, n) {
|
|
608
|
-
var o;
|
|
609
|
-
const { request: i, result: d } = await Z(
|
|
610
|
-
this._config,
|
|
611
|
-
{
|
|
612
|
-
...l(
|
|
613
|
-
this._config,
|
|
614
|
-
this.addresses,
|
|
615
|
-
((o = n == null ? void 0 : n.chain) == null ? void 0 : o.id) || (n == null ? void 0 : n.chainId)
|
|
616
|
-
),
|
|
617
|
-
args: [e, f, b, t, c],
|
|
618
|
-
...this.optionallyAttachAccount(),
|
|
619
|
-
// biome-ignore lint/suspicious/noExplicitAny: Accept any shape of valid wagmi/viem parameters, wagmi does the same thing internally
|
|
620
|
-
...n
|
|
621
|
-
}
|
|
622
|
-
);
|
|
623
|
-
return { hash: await ff(this._config, i), result: d };
|
|
624
|
-
}
|
|
625
|
-
/**
|
|
626
|
-
* Get a Boost by index, will return the raw on chain representation of a Boost.
|
|
627
|
-
*
|
|
628
|
-
* @public
|
|
629
|
-
* @async
|
|
630
|
-
* @param {bigint} id
|
|
631
|
-
* @param {?ReadParams<typeof boostCoreAbi, 'getBoost'>} [params]
|
|
632
|
-
* @returns {unknown}
|
|
633
|
-
*/
|
|
634
|
-
async readBoost(e, f) {
|
|
635
|
-
return await ef(this._config, {
|
|
636
|
-
address: this.assertValidAddress(),
|
|
637
|
-
args: [e],
|
|
638
|
-
...this.optionallyAttachAccount(),
|
|
639
|
-
// biome-ignore lint/suspicious/noExplicitAny: Accept any shape of valid wagmi/viem parameters, wagmi does the same thing internally
|
|
640
|
-
...f
|
|
641
|
-
});
|
|
642
|
-
}
|
|
643
|
-
/**
|
|
644
|
-
* Get a Boost by index, will return a new {@link Boost} with correct target implementations instantiated, ie `(await core.getBoost(0n)).allowList instanceof SimpleAllowList` vs `SimpleDenyList`
|
|
645
|
-
*
|
|
646
|
-
* @public
|
|
647
|
-
* @async
|
|
648
|
-
* @param {(string | bigint)} _id
|
|
649
|
-
* @param {?ReadParams<typeof boostCoreAbi, 'getBoost'>} [params]
|
|
650
|
-
* @returns {unknown}
|
|
651
|
-
*/
|
|
652
|
-
async getBoost(e, f) {
|
|
653
|
-
let b;
|
|
654
|
-
typeof e == "string" ? b = BigInt(e) : b = e;
|
|
655
|
-
const {
|
|
656
|
-
protocolFee: t,
|
|
657
|
-
referralFee: c,
|
|
658
|
-
maxParticipants: n,
|
|
659
|
-
owner: i,
|
|
660
|
-
...d
|
|
661
|
-
} = await this.readBoost(b, f), s = {
|
|
662
|
-
config: this._config,
|
|
663
|
-
account: this._account
|
|
664
|
-
}, [o, h, m, F, p] = await Promise.all([
|
|
665
|
-
Af(s, d.action),
|
|
666
|
-
pf(s, d.budget),
|
|
667
|
-
qf(s, d.validator),
|
|
668
|
-
_f(s, d.allowList),
|
|
669
|
-
Promise.all(
|
|
670
|
-
d.incentives.map(
|
|
671
|
-
(D) => jf(s, D)
|
|
672
|
-
)
|
|
673
|
-
)
|
|
674
|
-
]);
|
|
675
|
-
return new M({
|
|
676
|
-
id: b,
|
|
677
|
-
action: o,
|
|
678
|
-
budget: h,
|
|
679
|
-
validator: m,
|
|
680
|
-
allowList: F,
|
|
681
|
-
incentives: p,
|
|
682
|
-
protocolFee: t,
|
|
683
|
-
referralFee: c,
|
|
684
|
-
maxParticipants: n,
|
|
685
|
-
owner: i
|
|
686
|
-
});
|
|
687
|
-
}
|
|
688
|
-
/**
|
|
689
|
-
* Retrieve the total number of deployed Boosts
|
|
690
|
-
*
|
|
691
|
-
* @public
|
|
692
|
-
* @async
|
|
693
|
-
* @param {?ReadParams<typeof boostCoreAbi, 'getBoostCount'>} [params]
|
|
694
|
-
* @returns {Promise<bigint>}
|
|
695
|
-
*/
|
|
696
|
-
async getBoostCount(e) {
|
|
697
|
-
return await bf(this._config, {
|
|
698
|
-
...l(
|
|
699
|
-
this._config,
|
|
700
|
-
this.addresses,
|
|
701
|
-
e == null ? void 0 : e.chainId
|
|
702
|
-
),
|
|
703
|
-
args: [],
|
|
704
|
-
...this.optionallyAttachAccount(),
|
|
705
|
-
// biome-ignore lint/suspicious/noExplicitAny: Accept any shape of valid wagmi/viem parameters, wagmi does the same thing internally
|
|
706
|
-
...e
|
|
707
|
-
});
|
|
708
|
-
}
|
|
709
|
-
/**
|
|
710
|
-
* Checks if an address is authorized
|
|
711
|
-
*
|
|
712
|
-
* @public
|
|
713
|
-
* @async
|
|
714
|
-
* @param {Address} address
|
|
715
|
-
* @param {?ReadParams<typeof boostCoreAbi, 'createBoostAuth'> &
|
|
716
|
-
* ReadParams<typeof iAuthAbi, 'isAuthorized'>} [params]
|
|
717
|
-
* @returns {Promise<boolean>}
|
|
718
|
-
*/
|
|
719
|
-
async isAuthorized(e, f) {
|
|
720
|
-
const b = await this.createBoostAuth(f);
|
|
721
|
-
return tf(this._config, {
|
|
722
|
-
address: b,
|
|
723
|
-
args: [e],
|
|
724
|
-
...this.optionallyAttachAccount(),
|
|
725
|
-
// biome-ignore lint/suspicious/noExplicitAny: Accept any shape of valid wagmi/viem parameters, wagmi does the same thing internally
|
|
726
|
-
...f
|
|
727
|
-
});
|
|
728
|
-
}
|
|
729
|
-
/**
|
|
730
|
-
* Retrieve the address of the current creation auth provider.
|
|
731
|
-
*
|
|
732
|
-
* @public
|
|
733
|
-
* @async
|
|
734
|
-
* @param {?ReadParams<typeof boostCoreAbi, 'createBoostAuth'>} [params]
|
|
735
|
-
* @returns {unknown}
|
|
736
|
-
*/
|
|
737
|
-
async createBoostAuth(e) {
|
|
738
|
-
return await af(this._config, {
|
|
739
|
-
...l(
|
|
740
|
-
this._config,
|
|
741
|
-
this.addresses,
|
|
742
|
-
e == null ? void 0 : e.chainId
|
|
743
|
-
),
|
|
744
|
-
args: [],
|
|
745
|
-
...this.optionallyAttachAccount(),
|
|
746
|
-
// biome-ignore lint/suspicious/noExplicitAny: Accept any shape of valid wagmi/viem parameters, wagmi does the same thing internally
|
|
747
|
-
...e
|
|
748
|
-
});
|
|
749
|
-
}
|
|
750
|
-
/**
|
|
751
|
-
* Replace the current auth scheme.
|
|
752
|
-
*
|
|
753
|
-
* @public
|
|
754
|
-
* @async
|
|
755
|
-
* @param {Auth} auth
|
|
756
|
-
* @param {?WriteParams<typeof boostCoreAbi, 'setCreateBoostAuth'>} [params]
|
|
757
|
-
* @returns {unknown}
|
|
758
|
-
*/
|
|
759
|
-
async setCreateBoostAuth(e, f) {
|
|
760
|
-
return await this.awaitResult(
|
|
761
|
-
this.setCreateBoostAuthRaw(e.assertValidAddress(), {
|
|
762
|
-
...f
|
|
763
|
-
})
|
|
764
|
-
);
|
|
765
|
-
}
|
|
766
|
-
/**
|
|
767
|
-
* Set the createBoostAuth address
|
|
768
|
-
*
|
|
769
|
-
* @public
|
|
770
|
-
* @async
|
|
771
|
-
* @param {Address} address
|
|
772
|
-
* @param {?WriteParams<typeof boostCoreAbi, 'setCreateBoostAuth'>} [params]
|
|
773
|
-
* @returns {unknown}
|
|
774
|
-
*/
|
|
775
|
-
async setCreateBoostAuthRaw(e, f) {
|
|
776
|
-
const { request: b, result: t } = await cf(
|
|
777
|
-
this._config,
|
|
778
|
-
{
|
|
779
|
-
...l(
|
|
780
|
-
this._config,
|
|
781
|
-
this.addresses,
|
|
782
|
-
f == null ? void 0 : f.chainId
|
|
783
|
-
),
|
|
784
|
-
args: [e],
|
|
785
|
-
...this.optionallyAttachAccount(),
|
|
786
|
-
// biome-ignore lint/suspicious/noExplicitAny: Accept any shape of valid wagmi/viem parameters, wagmi does the same thing internally
|
|
787
|
-
...f
|
|
788
|
-
}
|
|
789
|
-
);
|
|
790
|
-
return { hash: await nf(this._config, b), result: t };
|
|
791
|
-
}
|
|
792
|
-
/**
|
|
793
|
-
* Get the protocol fee.
|
|
794
|
-
*
|
|
795
|
-
* @public
|
|
796
|
-
* @async
|
|
797
|
-
* @param {?ReadParams<typeof boostCoreAbi, 'protocolFee'>} [params]
|
|
798
|
-
* @returns {unknown}
|
|
799
|
-
*/
|
|
800
|
-
async protocolFee(e) {
|
|
801
|
-
return await sf(this._config, {
|
|
802
|
-
...l(
|
|
803
|
-
this._config,
|
|
804
|
-
this.addresses,
|
|
805
|
-
e == null ? void 0 : e.chainId
|
|
806
|
-
),
|
|
807
|
-
args: [],
|
|
808
|
-
...this.optionallyAttachAccount(),
|
|
809
|
-
// biome-ignore lint/suspicious/noExplicitAny: Accept any shape of valid wagmi/viem parameters, wagmi does the same thing internally
|
|
810
|
-
...e
|
|
811
|
-
});
|
|
812
|
-
}
|
|
813
|
-
/**
|
|
814
|
-
* Get the protocol fee receiver.
|
|
815
|
-
*
|
|
816
|
-
* @public
|
|
817
|
-
* @async
|
|
818
|
-
* @param {?ReadParams<typeof boostCoreAbi, 'protocolFeeReceiver'>} [params]
|
|
819
|
-
* @returns {unknown}
|
|
820
|
-
*/
|
|
821
|
-
async protocolFeeReceiver(e) {
|
|
822
|
-
return await df(this._config, {
|
|
823
|
-
...l(
|
|
824
|
-
this._config,
|
|
825
|
-
this.addresses,
|
|
826
|
-
e == null ? void 0 : e.chainId
|
|
827
|
-
),
|
|
828
|
-
args: [],
|
|
829
|
-
...this.optionallyAttachAccount(),
|
|
830
|
-
// biome-ignore lint/suspicious/noExplicitAny: Accept any shape of valid wagmi/viem parameters, wagmi does the same thing internally
|
|
831
|
-
...e
|
|
832
|
-
});
|
|
833
|
-
}
|
|
834
|
-
/**
|
|
835
|
-
* Set the protocol fee receiver address. This function is only callable by the owner.
|
|
836
|
-
*
|
|
837
|
-
* @public
|
|
838
|
-
* @async
|
|
839
|
-
* @param {Address} address
|
|
840
|
-
* @param {?WriteParams<typeof boostCoreAbi, 'setProtocolFeeReceiver'>} [params]
|
|
841
|
-
* @returns {unknown}
|
|
842
|
-
*/
|
|
843
|
-
async setProcolFeeReceiver(e, f) {
|
|
844
|
-
return await this.awaitResult(
|
|
845
|
-
this.setProcolFeeReceiverRaw(e, {
|
|
846
|
-
...f
|
|
847
|
-
})
|
|
848
|
-
);
|
|
849
|
-
}
|
|
850
|
-
/**
|
|
851
|
-
* Set the protocol fee receiver address. This function is only callable by the owner.
|
|
852
|
-
*
|
|
853
|
-
* @public
|
|
854
|
-
* @async
|
|
855
|
-
* @param {Address} address
|
|
856
|
-
* @param {?WriteParams<typeof boostCoreAbi, 'setProtocolFeeReceiver'>} [params]
|
|
857
|
-
* @returns {unknown}
|
|
858
|
-
*/
|
|
859
|
-
async setProcolFeeReceiverRaw(e, f) {
|
|
860
|
-
const { request: b, result: t } = await of(
|
|
861
|
-
this._config,
|
|
862
|
-
{
|
|
863
|
-
...l(
|
|
864
|
-
this._config,
|
|
865
|
-
this.addresses,
|
|
866
|
-
f == null ? void 0 : f.chainId
|
|
867
|
-
),
|
|
868
|
-
args: [e],
|
|
869
|
-
...this.optionallyAttachAccount(),
|
|
870
|
-
// biome-ignore lint/suspicious/noExplicitAny: Accept any shape of valid wagmi/viem parameters, wagmi does the same thing internally
|
|
871
|
-
...f
|
|
872
|
-
}
|
|
873
|
-
);
|
|
874
|
-
return { hash: await rf(
|
|
875
|
-
this._config,
|
|
876
|
-
b
|
|
877
|
-
), result: t };
|
|
878
|
-
}
|
|
879
|
-
/**
|
|
880
|
-
* Get the claim fee.
|
|
881
|
-
*
|
|
882
|
-
* @public
|
|
883
|
-
* @async
|
|
884
|
-
* @param {?ReadParams<typeof boostCoreAbi, 'claimFee'>} [params]
|
|
885
|
-
* @returns {unknown}
|
|
886
|
-
*/
|
|
887
|
-
async claimFee(e) {
|
|
888
|
-
return await uf(this._config, {
|
|
889
|
-
...l(
|
|
890
|
-
this._config,
|
|
891
|
-
this.addresses,
|
|
892
|
-
e == null ? void 0 : e.chainId
|
|
893
|
-
),
|
|
894
|
-
args: [],
|
|
895
|
-
...this.optionallyAttachAccount(),
|
|
896
|
-
// biome-ignore lint/suspicious/noExplicitAny: Accept any shape of valid wagmi/viem parameters, wagmi does the same thing internally
|
|
897
|
-
...e
|
|
898
|
-
});
|
|
899
|
-
}
|
|
900
|
-
/**
|
|
901
|
-
* Sets the claim fee.
|
|
902
|
-
*
|
|
903
|
-
* @public
|
|
904
|
-
* @async
|
|
905
|
-
* @param {bigint} claimFee
|
|
906
|
-
* @param {?WriteParams<typeof boostCoreAbi, 'setClaimFee'>} [params]
|
|
907
|
-
* @returns {unknown}
|
|
908
|
-
*/
|
|
909
|
-
async setClaimFee(e, f) {
|
|
910
|
-
return await this.awaitResult(this.setClaimFeeRaw(e, f));
|
|
911
|
-
}
|
|
912
|
-
/**
|
|
913
|
-
* Sets the claim fee.
|
|
914
|
-
*
|
|
915
|
-
* @public
|
|
916
|
-
* @async
|
|
917
|
-
* @param {bigint} claimFee
|
|
918
|
-
* @param {?WriteParams<typeof boostCoreAbi, 'setClaimFee'>} [params]
|
|
919
|
-
* @returns {unknown}
|
|
920
|
-
*/
|
|
921
|
-
async setClaimFeeRaw(e, f) {
|
|
922
|
-
const { request: b, result: t } = await lf(
|
|
923
|
-
this._config,
|
|
924
|
-
{
|
|
925
|
-
...l(
|
|
926
|
-
this._config,
|
|
927
|
-
this.addresses,
|
|
928
|
-
f == null ? void 0 : f.chainId
|
|
929
|
-
),
|
|
930
|
-
args: [e],
|
|
931
|
-
...this.optionallyAttachAccount(),
|
|
932
|
-
// biome-ignore lint/suspicious/noExplicitAny: Accept any shape of valid wagmi/viem parameters, wagmi does the same thing internally
|
|
933
|
-
...f
|
|
934
|
-
}
|
|
935
|
-
);
|
|
936
|
-
return { hash: await hf(this._config, b), result: t };
|
|
937
|
-
}
|
|
938
|
-
/**
|
|
939
|
-
* Bound {@link PassthroughAuth} constructor that reuses the same configuration as the Boost Core instance.
|
|
940
|
-
*
|
|
941
|
-
* @example
|
|
942
|
-
* ```ts
|
|
943
|
-
* const auth = core.PassthroughAuth('0x') // is roughly equivalent to
|
|
944
|
-
* const auth = new PassthroughAuth({ config: core._config, account: core._account }, '0x')
|
|
945
|
-
* ```
|
|
946
|
-
* @param {Address} address
|
|
947
|
-
* @returns {PassthroughAuth}
|
|
948
|
-
*/
|
|
949
|
-
PassthroughAuth(e) {
|
|
950
|
-
return new Ef(
|
|
951
|
-
{ config: this._config, account: this._account },
|
|
952
|
-
e
|
|
953
|
-
);
|
|
954
|
-
}
|
|
955
|
-
// /**
|
|
956
|
-
// * Bound {@link ContractAction} constructor that reuses the same configuration as the Boost Core instance.
|
|
957
|
-
// *
|
|
958
|
-
// * @example
|
|
959
|
-
// * ```ts
|
|
960
|
-
// * const action = core.ContractAction('0x') // is roughly equivalent to
|
|
961
|
-
// * const action = new ContractAction({ config: core._config, account: core._account }, '0x')
|
|
962
|
-
// * ```
|
|
963
|
-
// * @param {DeployablePayloadOrAddress<ContractActionPayload>} options
|
|
964
|
-
// * @param {?boolean} [isBase]
|
|
965
|
-
// * @returns {ContractAction}
|
|
966
|
-
// */
|
|
967
|
-
// ContractAction(
|
|
968
|
-
// options: DeployablePayloadOrAddress<ContractActionPayload>,
|
|
969
|
-
// isBase?: boolean,
|
|
970
|
-
// ) {
|
|
971
|
-
// return new ContractAction(
|
|
972
|
-
// { config: this._config, account: this._account },
|
|
973
|
-
// options,
|
|
974
|
-
// isBase,
|
|
975
|
-
// );
|
|
976
|
-
// }
|
|
977
|
-
/**
|
|
978
|
-
* Bound {@link EventAction} constructor that reuses the same configuration as the Boost Core instance.
|
|
979
|
-
*
|
|
980
|
-
* @example
|
|
981
|
-
* ```ts
|
|
982
|
-
* const action = core.EventAction('0x') // is roughly equivalent to
|
|
983
|
-
* const action = new EventAction({ config: core._config, account: core._account }, '0x')
|
|
984
|
-
*/
|
|
985
|
-
EventAction(e, f) {
|
|
986
|
-
return new If(
|
|
987
|
-
{ config: this._config, account: this._account },
|
|
988
|
-
e,
|
|
989
|
-
f
|
|
990
|
-
);
|
|
991
|
-
}
|
|
992
|
-
// /**
|
|
993
|
-
// * Bound {@link ERC721MintAction} constructor that reuses the same configuration as the Boost Core instance.
|
|
994
|
-
// *
|
|
995
|
-
// * @example
|
|
996
|
-
// * ```ts
|
|
997
|
-
// * const action = core.ERC721MintAction('0x') // is roughly equivalent to
|
|
998
|
-
// * const action = new ERC721MintAction({ config: core._config, account: core._account }, '0x')
|
|
999
|
-
// * ```
|
|
1000
|
-
// * @param {DeployablePayloadOrAddress<ERC721MintActionPayload>} options
|
|
1001
|
-
// * @param {?boolean} [isBase]
|
|
1002
|
-
// * @returns {ERC721MintAction}
|
|
1003
|
-
// */
|
|
1004
|
-
// ERC721MintAction(
|
|
1005
|
-
// options: DeployablePayloadOrAddress<ERC721MintActionPayload>,
|
|
1006
|
-
// isBase?: boolean,
|
|
1007
|
-
// ) {
|
|
1008
|
-
// return new ERC721MintAction(
|
|
1009
|
-
// { config: this._config, account: this._account },
|
|
1010
|
-
// options,
|
|
1011
|
-
// isBase,
|
|
1012
|
-
// );
|
|
1013
|
-
// }
|
|
1014
|
-
/**
|
|
1015
|
-
* Bound {@link OpenAllowList} constructor that reuses the same configuration as the Boost Core instance.
|
|
1016
|
-
*
|
|
1017
|
-
* @example
|
|
1018
|
-
* ```ts
|
|
1019
|
-
* const list = core.OpenAllowList('0x') // is roughly equivalent to
|
|
1020
|
-
* const list = new OpenAllowList({ config: core._config, account: core._account }, '0x')
|
|
1021
|
-
* ```
|
|
1022
|
-
* @param {?boolean} [isBase]
|
|
1023
|
-
* @returns {OpenAllowList}
|
|
1024
|
-
*/
|
|
1025
|
-
OpenAllowList(e) {
|
|
1026
|
-
return new Pf(
|
|
1027
|
-
{ config: this._config, account: this._account },
|
|
1028
|
-
void 0,
|
|
1029
|
-
e
|
|
1030
|
-
);
|
|
1031
|
-
}
|
|
1032
|
-
/**
|
|
1033
|
-
* Bound {@link SimpleAllowList} constructor that reuses the same configuration as the Boost Core instance.
|
|
1034
|
-
*
|
|
1035
|
-
* @example
|
|
1036
|
-
* ```ts
|
|
1037
|
-
* const list = core.SimpleAllowList('0x') // is roughly equivalent to
|
|
1038
|
-
* const list = new SimpleAllowList({ config: core._config, account: core._account }, '0x')
|
|
1039
|
-
* ```
|
|
1040
|
-
* @param {DeployablePayloadOrAddress<SimpleAllowListPayload>} options
|
|
1041
|
-
* @param {?boolean} [isBase]
|
|
1042
|
-
* @returns {SimpleAllowList}
|
|
1043
|
-
*/
|
|
1044
|
-
SimpleAllowList(e, f) {
|
|
1045
|
-
return new Bf(
|
|
1046
|
-
{ config: this._config, account: this._account },
|
|
1047
|
-
e,
|
|
1048
|
-
f
|
|
1049
|
-
);
|
|
1050
|
-
}
|
|
1051
|
-
/**
|
|
1052
|
-
* Bound {@link SimpleDenyList} constructor that reuses the same configuration as the Boost Core instance.
|
|
1053
|
-
*
|
|
1054
|
-
* @example
|
|
1055
|
-
* ```ts
|
|
1056
|
-
* const list = core.SimpleDenyList('0x') // is roughly equivalent to
|
|
1057
|
-
* const list = new SimpleDenyList({ config: core._config, account: core._account }, '0x')
|
|
1058
|
-
* ```
|
|
1059
|
-
* @param {DeployablePayloadOrAddress<SimpleDenyListPayload>} options
|
|
1060
|
-
* @param {?boolean} [isBase]
|
|
1061
|
-
* @returns {SimpleDenyList}
|
|
1062
|
-
*/
|
|
1063
|
-
SimpleDenyList(e, f) {
|
|
1064
|
-
return new Rf(
|
|
1065
|
-
{ config: this._config, account: this._account },
|
|
1066
|
-
e,
|
|
1067
|
-
f
|
|
1068
|
-
);
|
|
1069
|
-
}
|
|
1070
|
-
// /**
|
|
1071
|
-
// * Bound {@link SimpleBudget} constructor that reuses the same configuration as the Boost Core instance.
|
|
1072
|
-
// *
|
|
1073
|
-
// * @example
|
|
1074
|
-
// * ```ts
|
|
1075
|
-
// * const budget = core.SimpleBudget('0x') // is roughly equivalent to
|
|
1076
|
-
// * const budget = new SimpleBudget({ config: core._config, account: core._account }, '0x')
|
|
1077
|
-
// * ```
|
|
1078
|
-
// * @param {DeployablePayloadOrAddress<SimpleBudgetPayload>} options
|
|
1079
|
-
// * @returns {SimpleBudget}
|
|
1080
|
-
// */
|
|
1081
|
-
// SimpleBudget(options: DeployablePayloadOrAddress<SimpleBudgetPayload>) {
|
|
1082
|
-
// return new SimpleBudget(
|
|
1083
|
-
// { config: this._config, account: this._account },
|
|
1084
|
-
// options,
|
|
1085
|
-
// );
|
|
1086
|
-
// }
|
|
1087
|
-
/**
|
|
1088
|
-
* Bound {@link ManagedBudget} constructor that reuses the same configuration as the Boost Core instance.
|
|
1089
|
-
*
|
|
1090
|
-
* @example
|
|
1091
|
-
* ```ts
|
|
1092
|
-
* const budget = core.ManagedBudget('0x') // is roughly equivalent to
|
|
1093
|
-
* const budget = new ManagedBudget({ config: core._config, account: core._account }, '0x')
|
|
1094
|
-
* ```
|
|
1095
|
-
* @param {DeployablePayloadOrAddress<ManagedBudgetPayload>} options
|
|
1096
|
-
* @returns {ManagedBudget}
|
|
1097
|
-
*/
|
|
1098
|
-
ManagedBudget(e) {
|
|
1099
|
-
return new Df(
|
|
1100
|
-
{ config: this._config, account: this._account },
|
|
1101
|
-
e
|
|
1102
|
-
);
|
|
1103
|
-
}
|
|
1104
|
-
// /**
|
|
1105
|
-
// * Bound {@link VestingBudget} constructor that reuses the same configuration as the Boost Core instance.
|
|
1106
|
-
// *
|
|
1107
|
-
// * @example
|
|
1108
|
-
// * ```ts
|
|
1109
|
-
// * const budget = core.VestingBudget('0x') // is roughly equivalent to
|
|
1110
|
-
// * const budget = new VestingBudget({ config: core._config, account: core._account }, '0x')
|
|
1111
|
-
// * ```
|
|
1112
|
-
// * @param {DeployablePayloadOrAddress<VestingBudgetPayload>} options
|
|
1113
|
-
// * @returns {VestingBudget}
|
|
1114
|
-
// */
|
|
1115
|
-
// VestingBudget(options: DeployablePayloadOrAddress<VestingBudgetPayload>) {
|
|
1116
|
-
// return new VestingBudget(
|
|
1117
|
-
// { config: this._config, account: this._account },
|
|
1118
|
-
// options,
|
|
1119
|
-
// );
|
|
1120
|
-
// }
|
|
1121
|
-
/**
|
|
1122
|
-
* Bound {@link AllowListIncentive} constructor that reuses the same configuration as the Boost Core instance.
|
|
1123
|
-
*
|
|
1124
|
-
* @example
|
|
1125
|
-
* ```ts
|
|
1126
|
-
* const incentive = core.AllowListIncentive({ ... }) // is roughly equivalent to
|
|
1127
|
-
* const incentive = new AllowListIncentive({ config: core._config, account: core._account }, { ... })
|
|
1128
|
-
* ```
|
|
1129
|
-
* @param {DeployablePayloadOrAddress<VestingBudgetPayload>} options
|
|
1130
|
-
* @returns {VestingBudget}
|
|
1131
|
-
*/
|
|
1132
|
-
AllowListIncentive(e) {
|
|
1133
|
-
return new Lf(
|
|
1134
|
-
{ config: this._config, account: this._account },
|
|
1135
|
-
e
|
|
1136
|
-
);
|
|
1137
|
-
}
|
|
1138
|
-
/**
|
|
1139
|
-
* Bound {@link CGDAIncentive} constructor that reuses the same configuration as the Boost Core instance.
|
|
1140
|
-
*
|
|
1141
|
-
* @example
|
|
1142
|
-
* ```ts
|
|
1143
|
-
* const incentive = core.CGDAIncentive({ ... }) // is roughly equivalent to
|
|
1144
|
-
* const incentive = new CGDAIncentive({ config: core._config, account: core._account }, { ... })
|
|
1145
|
-
* ```
|
|
1146
|
-
* @param {CGDAIncentivePayload} options
|
|
1147
|
-
* @returns {CGDAIncentive}
|
|
1148
|
-
*/
|
|
1149
|
-
CGDAIncentive(e) {
|
|
1150
|
-
return new Sf(
|
|
1151
|
-
{ config: this._config, account: this._account },
|
|
1152
|
-
e
|
|
1153
|
-
);
|
|
1154
|
-
}
|
|
1155
|
-
/**
|
|
1156
|
-
* Bound {@link ERC20Incentive} constructor that reuses the same configuration as the Boost Core instance.
|
|
1157
|
-
*
|
|
1158
|
-
* @example
|
|
1159
|
-
* ```ts
|
|
1160
|
-
* const incentive = core.ERC20Incentive({ ... }) // is roughly equivalent to
|
|
1161
|
-
* const incentive = new ERC20Incentive({ config: core._config, account: core._account }, { ... })
|
|
1162
|
-
* ```
|
|
1163
|
-
* @param {ERC20IncentivePayload} options
|
|
1164
|
-
* @returns {ERC20Incentive}
|
|
1165
|
-
*/
|
|
1166
|
-
ERC20Incentive(e) {
|
|
1167
|
-
return new $f(
|
|
1168
|
-
{ config: this._config, account: this._account },
|
|
1169
|
-
e
|
|
1170
|
-
);
|
|
1171
|
-
}
|
|
1172
|
-
// /**
|
|
1173
|
-
// * Temporarily disabled until low level ABI encoding bugs are resolved
|
|
1174
|
-
// * Bound {@link ERC1155Incentive} constructor that reuses the same configuration as the Boost Core instance.
|
|
1175
|
-
// *
|
|
1176
|
-
// * @experimental
|
|
1177
|
-
// * @example
|
|
1178
|
-
// * ```ts
|
|
1179
|
-
// * const incentive = core.ERC1155Incentive({ ... }) // is roughly equivalent to
|
|
1180
|
-
// * const incentive = new ERC1155Incentive({ config: core._config, account: core._account }, { ... })
|
|
1181
|
-
// * ```
|
|
1182
|
-
// * @param {ERC1155IncentivePayload} options
|
|
1183
|
-
// * @returns {ERC1155Incentive}
|
|
1184
|
-
// */
|
|
1185
|
-
// ERC1155Incentive(options: ERC1155IncentivePayload) {
|
|
1186
|
-
// return new ERC1155Incentive(
|
|
1187
|
-
// { config: this._config, account: this._account },
|
|
1188
|
-
// options,
|
|
1189
|
-
// );
|
|
1190
|
-
// }
|
|
1191
|
-
/**
|
|
1192
|
-
* Bound {@link PointsIncentive} constructor that reuses the same configuration as the Boost Core instance.
|
|
1193
|
-
*
|
|
1194
|
-
* @example
|
|
1195
|
-
* ```ts
|
|
1196
|
-
* const incentive = core.PointsIncentive({ ... }) // is roughly equivalent to
|
|
1197
|
-
* const incentive = new PointsIncentive({ config: core._config, account: core._account }, { ... })
|
|
1198
|
-
* ```
|
|
1199
|
-
* @param {PointsIncentivePayload} options
|
|
1200
|
-
* @returns {PointsIncentive}
|
|
1201
|
-
*/
|
|
1202
|
-
PointsIncentive(e) {
|
|
1203
|
-
return new Mf(
|
|
1204
|
-
{ config: this._config, account: this._account },
|
|
1205
|
-
e
|
|
1206
|
-
);
|
|
1207
|
-
}
|
|
1208
|
-
/**
|
|
1209
|
-
* Bound {@link SignerValidator} constructor that reuses the same configuration as the Boost Core instance.
|
|
1210
|
-
*
|
|
1211
|
-
* @example
|
|
1212
|
-
* ```ts
|
|
1213
|
-
* const validator = core.SignerValidator({ ... }) // is roughly equivalent to
|
|
1214
|
-
* const validator = new SignerValidator({ config: core._config, account: core._account }, { ... })
|
|
1215
|
-
* ```
|
|
1216
|
-
* @param {DeployablePayloadOrAddress<SignerValidatorPayload>} options
|
|
1217
|
-
* @param {?boolean} [isBase]
|
|
1218
|
-
* @returns {SignerValidator}
|
|
1219
|
-
*/
|
|
1220
|
-
SignerValidator(e, f) {
|
|
1221
|
-
return new Nf(
|
|
1222
|
-
{ config: this._config, account: this._account },
|
|
1223
|
-
e,
|
|
1224
|
-
f
|
|
1225
|
-
);
|
|
1226
|
-
}
|
|
1227
|
-
/**
|
|
1228
|
-
* Bound {@link ERC20VariableIncentive} constructor that reuses the same configuration as the Boost Core instance.
|
|
1229
|
-
*
|
|
1230
|
-
* @example
|
|
1231
|
-
* ```ts
|
|
1232
|
-
* const validator = core.ERC20VariableIncentive({ ... }) // is roughly equivalent to
|
|
1233
|
-
* const validator = new ERC20VariableIncentive({ config: core._config, account: core._account }, { ... })
|
|
1234
|
-
* ```
|
|
1235
|
-
* @param {DeployablePayloadOrAddress<ERC20VariableIncentivePayload>} options
|
|
1236
|
-
* @param {?boolean} [isBase]
|
|
1237
|
-
* @returns {ERC20VariableIncentive}
|
|
1238
|
-
*/
|
|
1239
|
-
ERC20VariableIncentive(e, f) {
|
|
1240
|
-
return new xf(
|
|
1241
|
-
{ config: this._config, account: this._account },
|
|
1242
|
-
e,
|
|
1243
|
-
f
|
|
1244
|
-
);
|
|
1245
|
-
}
|
|
1246
|
-
/**
|
|
1247
|
-
* @inheritdoc
|
|
1248
|
-
*
|
|
1249
|
-
* @public
|
|
1250
|
-
* @param {?[Address, Address]} [_payload]
|
|
1251
|
-
* @param {?DeployableOptions} [_options]
|
|
1252
|
-
* @returns {GenericDeployableParams}
|
|
1253
|
-
*/
|
|
1254
|
-
buildParameters(e, f) {
|
|
1255
|
-
const [b, t] = this.validateDeploymentConfig(
|
|
1256
|
-
e,
|
|
1257
|
-
f
|
|
1258
|
-
);
|
|
1259
|
-
return {
|
|
1260
|
-
abi: R,
|
|
1261
|
-
bytecode: Qf,
|
|
1262
|
-
args: b,
|
|
1263
|
-
...this.optionallyAttachAccount(t.account)
|
|
1264
|
-
};
|
|
1265
|
-
}
|
|
1266
|
-
};
|
|
1267
|
-
S.addresses = q;
|
|
1268
|
-
let V = S;
|
|
1
|
+
import { b as I } from "./generated-B8VWObPa.js";
|
|
2
|
+
import { a as M, b as d, B as g, c as h } from "./BoostCore-C00iqvks.js";
|
|
3
|
+
import "@wagmi/core";
|
|
4
|
+
import "viem";
|
|
5
|
+
import "./deployments-BM42vImE.js";
|
|
6
|
+
import "./Actions/Action.js";
|
|
7
|
+
import "./EventAction-BO5WI_5s.js";
|
|
8
|
+
import "./AllowLists/AllowList.js";
|
|
9
|
+
import "./AllowLists/SimpleAllowList.js";
|
|
10
|
+
import "./SimpleDenyList-D9i4rw_F.js";
|
|
11
|
+
import "./Auth/PassthroughAuth.js";
|
|
12
|
+
import "./Boost.js";
|
|
13
|
+
import "./Budgets/Budget.js";
|
|
14
|
+
import "./Budgets/ManagedBudget.js";
|
|
15
|
+
import "./Deployable/Deployable.js";
|
|
16
|
+
import "./Incentives/AllowListIncentive.js";
|
|
17
|
+
import "./Incentives/CGDAIncentive.js";
|
|
18
|
+
import "./Incentives/ERC20Incentive.js";
|
|
19
|
+
import "./Incentive-CF7kaz_9.js";
|
|
20
|
+
import "./Incentives/PointsIncentive.js";
|
|
21
|
+
import "./Validators/SignerValidator.js";
|
|
22
|
+
import "./Validators/Validator.js";
|
|
23
|
+
import "./errors.js";
|
|
24
|
+
import "./utils.js";
|
|
1269
25
|
export {
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
1273
|
-
|
|
1274
|
-
|
|
26
|
+
M as BOOST_CORE_ADDRESS,
|
|
27
|
+
d as BOOST_CORE_ADDRESSES,
|
|
28
|
+
g as BOOST_CORE_CLAIM_FEE,
|
|
29
|
+
h as BoostCore,
|
|
30
|
+
I as boostCoreAbi
|
|
1275
31
|
};
|
|
1276
32
|
//# sourceMappingURL=BoostCore.js.map
|