@pufferfinance/puffer-sdk 1.17.1 → 1.17.3
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/api/puffer-client-helpers.cjs +1 -1
- package/dist/api/puffer-client-helpers.js +3 -3
- package/dist/api/puffer-client.cjs +1 -1
- package/dist/api/puffer-client.js +2 -2
- package/dist/{ccip-DxZd6avE.js → ccip-BJ1xqhtz.js} +3 -3
- package/dist/{ccip-DxZd6avE.js.map → ccip-BJ1xqhtz.js.map} +1 -1
- package/dist/{ccip-KTVYuImW.cjs → ccip-BxmhlmqV.cjs} +2 -2
- package/dist/{ccip-KTVYuImW.cjs.map → ccip-BxmhlmqV.cjs.map} +1 -1
- package/dist/chains/constants.cjs +1 -1
- package/dist/chains/constants.d.ts +2 -1
- package/dist/chains/constants.js +1 -1
- package/dist/{constants-Bsa7cnXP.cjs → constants-B96CDi8I.cjs} +9 -9
- package/dist/constants-B96CDi8I.cjs.map +1 -0
- package/dist/{constants-DtzphQjb.js → constants-Bw9JXSap.js} +478 -432
- package/dist/constants-Bw9JXSap.js.map +1 -0
- package/dist/contracts/addresses.cjs +1 -1
- package/dist/contracts/addresses.js +1 -1
- package/dist/contracts/handlers/carrot-staking-handler.cjs +1 -1
- package/dist/contracts/handlers/carrot-staking-handler.d.ts +2 -2
- package/dist/contracts/handlers/carrot-staking-handler.js +2 -2
- package/dist/contracts/handlers/concrete-vault-handler.cjs +1 -1
- package/dist/contracts/handlers/concrete-vault-handler.d.ts +2 -2
- package/dist/contracts/handlers/concrete-vault-handler.js +2 -2
- package/dist/contracts/handlers/distributor-handler.cjs +1 -1
- package/dist/contracts/handlers/distributor-handler.d.ts +2 -2
- package/dist/contracts/handlers/distributor-handler.js +2 -2
- package/dist/contracts/handlers/erc20-permit-handler.cjs +1 -1
- package/dist/contracts/handlers/erc20-permit-handler.d.ts +2 -2
- package/dist/contracts/handlers/erc20-permit-handler.js +3 -3
- package/dist/contracts/handlers/l1-reward-manager-handler.cjs +1 -1
- package/dist/contracts/handlers/l1-reward-manager-handler.d.ts +2 -2
- package/dist/contracts/handlers/l1-reward-manager-handler.js +2 -2
- package/dist/contracts/handlers/l2-reward-manager-handler.cjs +1 -1
- package/dist/contracts/handlers/l2-reward-manager-handler.d.ts +2 -2
- package/dist/contracts/handlers/l2-reward-manager-handler.js +2 -2
- package/dist/contracts/handlers/mtw-carrot-handler.cjs +1 -1
- package/dist/contracts/handlers/mtw-carrot-handler.d.ts +2 -2
- package/dist/contracts/handlers/mtw-carrot-handler.js +2 -2
- package/dist/contracts/handlers/nucleus-accountant-handler.cjs +1 -1
- package/dist/contracts/handlers/nucleus-accountant-handler.d.ts +2 -2
- package/dist/contracts/handlers/nucleus-accountant-handler.js +1 -1
- package/dist/contracts/handlers/nucleus-atomic-queue-handler.cjs +1 -1
- package/dist/contracts/handlers/nucleus-atomic-queue-handler.d.ts +2 -2
- package/dist/contracts/handlers/nucleus-atomic-queue-handler.js +2 -2
- package/dist/contracts/handlers/nucleus-boring-vault-handler.cjs +1 -1
- package/dist/contracts/handlers/nucleus-boring-vault-handler.d.ts +2 -2
- package/dist/contracts/handlers/nucleus-boring-vault-handler.js +2 -2
- package/dist/contracts/handlers/nucleus-teller-handler.cjs +1 -1
- package/dist/contracts/handlers/nucleus-teller-handler.d.ts +2 -2
- package/dist/contracts/handlers/nucleus-teller-handler.js +2 -2
- package/dist/contracts/handlers/puf-locker-handler.cjs +1 -1
- package/dist/contracts/handlers/puf-locker-handler.d.ts +2 -2
- package/dist/contracts/handlers/puf-locker-handler.js +2 -2
- package/dist/contracts/handlers/puffer-depositor-handler.cjs +1 -1
- package/dist/contracts/handlers/puffer-depositor-handler.d.ts +2 -2
- package/dist/contracts/handlers/puffer-depositor-handler.js +2 -2
- package/dist/contracts/handlers/puffer-l2-depositor-handler.cjs +1 -1
- package/dist/contracts/handlers/puffer-l2-depositor-handler.d.ts +2 -2
- package/dist/contracts/handlers/puffer-l2-depositor-handler.js +2 -2
- package/dist/contracts/handlers/puffer-vault-handler.cjs +1 -1
- package/dist/contracts/handlers/puffer-vault-handler.d.ts +2 -2
- package/dist/contracts/handlers/puffer-vault-handler.js +2 -2
- package/dist/contracts/handlers/puffer-withdrawal-manager-handler.cjs +1 -1
- package/dist/contracts/handlers/puffer-withdrawal-manager-handler.d.ts +2 -2
- package/dist/contracts/handlers/puffer-withdrawal-manager-handler.js +2 -2
- package/dist/contracts/tokens.cjs +1 -1
- package/dist/contracts/tokens.cjs.map +1 -1
- package/dist/contracts/tokens.js +6 -4
- package/dist/contracts/tokens.js.map +1 -1
- package/dist/contracts/vaults-addresses.cjs +1 -1
- package/dist/contracts/vaults-addresses.js +1 -1
- package/dist/{createWalletClient-DveM0zMc.js → createWalletClient-CsOHhabf.js} +4 -4
- package/dist/{createWalletClient-DveM0zMc.js.map → createWalletClient-CsOHhabf.js.map} +1 -1
- package/dist/{createWalletClient-Cxvyuh55.cjs → createWalletClient-usZXff24.cjs} +2 -2
- package/dist/{createWalletClient-Cxvyuh55.cjs.map → createWalletClient-usZXff24.cjs.map} +1 -1
- package/dist/{getContract-Ck0plC0s.js → getContract-8WqQMpYW.js} +2 -2
- package/dist/{getContract-Ck0plC0s.js.map → getContract-8WqQMpYW.js.map} +1 -1
- package/dist/{getContract-Z5RjOH18.cjs → getContract-Bzdkp3oE.cjs} +2 -2
- package/dist/{getContract-Z5RjOH18.cjs.map → getContract-Bzdkp3oE.cjs.map} +1 -1
- package/dist/main.cjs +1 -1
- package/dist/main.d.ts +1 -0
- package/dist/main.js +30 -28
- package/dist/main.js.map +1 -1
- package/dist/{secp256k1-BWuyf2aG.cjs → secp256k1-BCRN0kWE.cjs} +2 -2
- package/dist/{secp256k1-BWuyf2aG.cjs.map → secp256k1-BCRN0kWE.cjs.map} +1 -1
- package/dist/{secp256k1-48Xl94oi.js → secp256k1-YxK0LcBT.js} +2 -2
- package/dist/{secp256k1-48Xl94oi.js.map → secp256k1-YxK0LcBT.js.map} +1 -1
- package/dist/utils/version.cjs +1 -1
- package/dist/utils/version.js +1 -1
- package/dist/{writeContract-CynQLeZV.js → writeContract-CYCoIOLc.js} +4 -4
- package/dist/{writeContract-CynQLeZV.js.map → writeContract-CYCoIOLc.js.map} +1 -1
- package/dist/{writeContract-D5BxbWBy.cjs → writeContract-D_ETLOw6.cjs} +3 -3
- package/dist/{writeContract-D5BxbWBy.cjs.map → writeContract-D_ETLOw6.cjs.map} +1 -1
- package/package.json +1 -1
- package/dist/constants-Bsa7cnXP.cjs.map +0 -1
- package/dist/constants-DtzphQjb.js.map +0 -1
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../constants-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../constants-B96CDi8I.cjs"),a={[e.Chain.Mainnet]:{PufferVault:"0xD9A442856C234a39a81a089C06451EBAa4306a72",PufferDepositor:"0x4aa799c5dfc01ee7d790e3bf1a7c2257ce1dceff",PufferL2Depositor:"0x3436E0B85cd929929F5802e792CFE282166E0259",PufLocker:"0x48e8dE138C246c14248C94d2D616a2F9eb4590D2",L1RewardManager:"0x157788cc028Ac6405bD406f2D1e0A8A22b3cf17b",L2RewardManager:"0x0000000000000000000000000000000000000000",PufferWithdrawalManager:"0xDdA0483184E75a5579ef9635ED14BacCf9d50283",NucleusAtomicQueue:"0x228c44bb4885c6633f4b6c83f14622f37d5112e5",CarrotStaker:"0x99c599227c65132822f0290d9e5b4b0430d6c0d6",Distributor:"0x3Ef3D8bA38EBe18DB133cEc108f4D14CE00Dd9Ae"},[e.Chain.Holesky]:{PufferVault:"0x9196830bB4c05504E0A8475A0aD566AceEB6BeC9",PufferDepositor:"0x824AC05aeb86A0aD770b8acDe0906d2d4a6c4A8c",PufferL2Depositor:"0x0af6998e4828ad8ef8f79a9288d0a861890f791d",PufLocker:"0xa58983ad0899a452b7420bc57228e329d7ba92b6",L1RewardManager:"0x10f970bcb84B82B82a65eBCbF45F26dD26D69F12",L2RewardManager:"0x58C046794f69A8830b0BE737022a45b4acd01dE5",PufferWithdrawalManager:"0x5A3E1069B66800c0ecbc91bd81b1AE4D1804DBc4"},[e.Chain.Base]:{L2RewardManager:"0xF9Dd335bF363b2E4ecFe3c94A86EBD7Dd3Dcf0e7"}};exports.CONTRACT_ADDRESSES=a;
|
|
2
2
|
//# sourceMappingURL=addresses.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";var s=Object.defineProperty;var c=(a,t,e)=>t in a?s(a,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):a[t]=e;var r=(a,t,e)=>c(a,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("../../constants-
|
|
1
|
+
"use strict";var s=Object.defineProperty;var c=(a,t,e)=>t in a?s(a,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):a[t]=e;var r=(a,t,e)=>c(a,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("../../constants-B96CDi8I.cjs"),i=require("../tokens.cjs"),l=require("../abis/mainnet/CarrotStaker.cjs"),h=require("../../getContract-Bzdkp3oE.cjs");class C{constructor(t,e,n){r(this,"viemChain");this.chain=t,this.walletClient=e,this.publicClient=n,this.viemChain=o.VIEM_CHAINS[t]}getContract(){const t=i.TOKENS_ADDRESSES[i.Token.sCARROT][this.chain],e=l.CarrotStaker,n={public:this.publicClient,wallet:this.walletClient};return h.getContract({address:t,abi:e,client:n})}allowance(t,e){return this.getContract().read.allowance([t,e])}balanceOf(t){return this.getContract().read.balanceOf([t])}decimals(){return this.getContract().read.decimals()}isUnstakingAllowed(){return this.getContract().read.isUnstakingAllowed()}totalSupply(){return this.getContract().read.totalSupply()}stake(t,e){return this.getContract().write.stake([e],{account:t,chain:this.viemChain})}unstake(t,e,n){return this.getContract().write.unstake([e,n],{account:t,chain:this.viemChain})}}exports.CarrotStakingHandler=C;
|
|
2
2
|
//# sourceMappingURL=carrot-staking-handler.cjs.map
|
|
@@ -14430,8 +14430,8 @@ export declare class CarrotStakingHandler {
|
|
|
14430
14430
|
[x: `bytes[${string}]`]: undefined;
|
|
14431
14431
|
[x: `bytes1[${string}]`]: undefined;
|
|
14432
14432
|
[x: `bytes18[${string}]`]: undefined;
|
|
14433
|
-
[x: `bytes2[${string}]`]: undefined;
|
|
14434
14433
|
[x: `bytes3[${string}]`]: undefined;
|
|
14434
|
+
[x: `bytes2[${string}]`]: undefined;
|
|
14435
14435
|
[x: `bytes12[${string}]`]: undefined;
|
|
14436
14436
|
[x: `bytes23[${string}]`]: undefined;
|
|
14437
14437
|
[x: `bytes4[${string}]`]: undefined;
|
|
@@ -14532,8 +14532,8 @@ export declare class CarrotStakingHandler {
|
|
|
14532
14532
|
bytes?: undefined;
|
|
14533
14533
|
bytes1?: undefined;
|
|
14534
14534
|
bytes18?: undefined;
|
|
14535
|
-
bytes2?: undefined;
|
|
14536
14535
|
bytes3?: undefined;
|
|
14536
|
+
bytes2?: undefined;
|
|
14537
14537
|
bytes12?: undefined;
|
|
14538
14538
|
bytes23?: undefined;
|
|
14539
14539
|
bytes4?: undefined;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
var n = Object.defineProperty;
|
|
2
2
|
var s = (a, t, e) => t in a ? n(a, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : a[t] = e;
|
|
3
3
|
var i = (a, t, e) => s(a, typeof t != "symbol" ? t + "" : t, e);
|
|
4
|
-
import { V as l } from "../../constants-
|
|
4
|
+
import { V as l } from "../../constants-Bw9JXSap.js";
|
|
5
5
|
import { TOKENS_ADDRESSES as o, Token as c } from "../tokens.js";
|
|
6
6
|
import { CarrotStaker as h } from "../abis/mainnet/CarrotStaker.js";
|
|
7
|
-
import { g as C } from "../../getContract-
|
|
7
|
+
import { g as C } from "../../getContract-8WqQMpYW.js";
|
|
8
8
|
class k {
|
|
9
9
|
/**
|
|
10
10
|
* Create the handler for the `CarrotStaker` contract exposing
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";var a=Object.defineProperty;var c=(i,t,e)=>t in i?a(i,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):i[t]=e;var r=(i,t,e)=>c(i,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("../../constants-
|
|
1
|
+
"use strict";var a=Object.defineProperty;var c=(i,t,e)=>t in i?a(i,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):i[t]=e;var r=(i,t,e)=>c(i,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("../../constants-B96CDi8I.cjs"),s=require("../abis/mainnet/ConcreteMultiStrategyVault.cjs"),l=require("../tokens.cjs"),h=require("../vaults-addresses.cjs"),u=require("../../getContract-Bzdkp3oE.cjs");class C{constructor(t,e,n){r(this,"viemChain");r(this,"token");this.chain=t,this.walletClient=e,this.publicClient=n,this.viemChain=o.VIEM_CHAINS[t],this.token=l.Token.pufETH}withToken(t){return this.token=t,this}getContract(){const t=h.VAULTS_ADDRESSES[this.token][this.chain].ConcreteMultiStrategyVault,e=s.ConcreteMultiStrategyVault,n={public:this.publicClient,wallet:this.walletClient};return u.getContract({address:t,abi:e,client:n})}approve(t,e){return this.getContract().write.approve([t,e],{account:this.walletClient.account,chain:this.viemChain})}getAllowance(t,e){return this.getContract().read.allowance([t,e])}getBalance(t){return this.getContract().read.balanceOf([t])}getTotalSupply(){return this.getContract().read.totalSupply()}deposit(t){return this.getContract().write.deposit([t],{account:this.walletClient.account,chain:this.viemChain})}withdraw(t){return this.getContract().write.withdraw([t],{account:this.walletClient.account,chain:this.viemChain})}previewDeposit(t){return this.getContract().read.previewDeposit([t])}previewWithdraw(t){return this.getContract().read.previewWithdraw([t])}}exports.ConcreteVaultHandler=C;
|
|
2
2
|
//# sourceMappingURL=concrete-vault-handler.cjs.map
|
|
@@ -14624,8 +14624,8 @@ export declare class ConcreteVaultHandler {
|
|
|
14624
14624
|
[x: `bytes[${string}]`]: undefined;
|
|
14625
14625
|
[x: `bytes1[${string}]`]: undefined;
|
|
14626
14626
|
[x: `bytes18[${string}]`]: undefined;
|
|
14627
|
-
[x: `bytes2[${string}]`]: undefined;
|
|
14628
14627
|
[x: `bytes3[${string}]`]: undefined;
|
|
14628
|
+
[x: `bytes2[${string}]`]: undefined;
|
|
14629
14629
|
[x: `bytes12[${string}]`]: undefined;
|
|
14630
14630
|
[x: `bytes23[${string}]`]: undefined;
|
|
14631
14631
|
[x: `bytes4[${string}]`]: undefined;
|
|
@@ -14726,8 +14726,8 @@ export declare class ConcreteVaultHandler {
|
|
|
14726
14726
|
bytes?: undefined;
|
|
14727
14727
|
bytes1?: undefined;
|
|
14728
14728
|
bytes18?: undefined;
|
|
14729
|
-
bytes2?: undefined;
|
|
14730
14729
|
bytes3?: undefined;
|
|
14730
|
+
bytes2?: undefined;
|
|
14731
14731
|
bytes12?: undefined;
|
|
14732
14732
|
bytes23?: undefined;
|
|
14733
14733
|
bytes4?: undefined;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
var n = Object.defineProperty;
|
|
2
2
|
var o = (i, t, e) => t in i ? n(i, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : i[t] = e;
|
|
3
3
|
var a = (i, t, e) => o(i, typeof t != "symbol" ? t + "" : t, e);
|
|
4
|
-
import { V as c } from "../../constants-
|
|
4
|
+
import { V as c } from "../../constants-Bw9JXSap.js";
|
|
5
5
|
import { ConcreteMultiStrategyVault as l } from "../abis/mainnet/ConcreteMultiStrategyVault.js";
|
|
6
6
|
import { Token as h } from "../tokens.js";
|
|
7
7
|
import { VAULTS_ADDRESSES as s } from "../vaults-addresses.js";
|
|
8
|
-
import { g as u } from "../../getContract-
|
|
8
|
+
import { g as u } from "../../getContract-8WqQMpYW.js";
|
|
9
9
|
class v {
|
|
10
10
|
/**
|
|
11
11
|
* Create the handler for processing UniFi tokens.
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";var o=Object.defineProperty;var c=(i,t,e)=>t in i?o(i,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):i[t]=e;var s=(i,t,e)=>c(i,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const u=require("../../constants-
|
|
1
|
+
"use strict";var o=Object.defineProperty;var c=(i,t,e)=>t in i?o(i,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):i[t]=e;var s=(i,t,e)=>c(i,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const u=require("../../constants-B96CDi8I.cjs"),l=require("../addresses.cjs"),h=require("../abis/mainnet/Distributor.cjs"),C=require("../../getContract-Bzdkp3oE.cjs");class d{constructor(t,e,r){s(this,"viemChain");this.chain=t,this.walletClient=e,this.publicClient=r,this.viemChain=u.VIEM_CHAINS[t]}getContract(){const t=l.CONTRACT_ADDRESSES[this.chain].Distributor,e=h.Distributor,r={public:this.publicClient,wallet:this.walletClient};return C.getContract({address:t,abi:e,client:r})}claim(t,{users:e,tokens:r,amounts:n,proofs:a}){return this.getContract().write.claim([e,r,n,a],{account:t,chain:this.viemChain})}async claimed(t,e){const[r,n,a]=await this.getContract().read.claimed([t,e]);return{amount:r,timestamp:BigInt(n),merkleRoot:a}}core(){return this.getContract().read.core()}disputeAmount(){return this.getContract().read.disputeAmount()}disputePeriod(){return this.getContract().read.disputePeriod()}disputeToken(){return this.getContract().read.disputeToken()}disputeTree(t,e){return this.getContract().write.disputeTree([e],{account:t,chain:this.viemChain})}disputer(){return this.getContract().read.disputer()}endOfDisputePeriod(){return this.getContract().read.endOfDisputePeriod()}getMerkleRoot(){return this.getContract().read.getMerkleRoot()}async lastTree(){const[t,e]=await this.getContract().read.lastTree();return{merkleRoot:t,ipfsHash:e}}onlyOperatorCanClaim(t){return this.getContract().read.onlyOperatorCanClaim([t])}toggleOnlyOperatorCanClaim(t,e){return this.getContract().write.toggleOnlyOperatorCanClaim([e],{account:t,chain:this.viemChain})}toggleOperator(t,e,r){return this.getContract().write.toggleOperator([e,r],{account:t,chain:this.viemChain})}toggleTrusted(t,e){return this.getContract().write.toggleTrusted([e],{account:t,chain:this.viemChain})}async tree(){const[t,e]=await this.getContract().read.tree();return{merkleRoot:t,ipfsHash:e}}}exports.DistributorHandler=d;
|
|
2
2
|
//# sourceMappingURL=distributor-handler.cjs.map
|
|
@@ -14560,8 +14560,8 @@ export declare class DistributorHandler {
|
|
|
14560
14560
|
[x: `bytes[${string}]`]: undefined;
|
|
14561
14561
|
[x: `bytes1[${string}]`]: undefined;
|
|
14562
14562
|
[x: `bytes18[${string}]`]: undefined;
|
|
14563
|
-
[x: `bytes2[${string}]`]: undefined;
|
|
14564
14563
|
[x: `bytes3[${string}]`]: undefined;
|
|
14564
|
+
[x: `bytes2[${string}]`]: undefined;
|
|
14565
14565
|
[x: `bytes12[${string}]`]: undefined;
|
|
14566
14566
|
[x: `bytes23[${string}]`]: undefined;
|
|
14567
14567
|
[x: `bytes4[${string}]`]: undefined;
|
|
@@ -14662,8 +14662,8 @@ export declare class DistributorHandler {
|
|
|
14662
14662
|
bytes?: undefined;
|
|
14663
14663
|
bytes1?: undefined;
|
|
14664
14664
|
bytes18?: undefined;
|
|
14665
|
-
bytes2?: undefined;
|
|
14666
14665
|
bytes3?: undefined;
|
|
14666
|
+
bytes2?: undefined;
|
|
14667
14667
|
bytes12?: undefined;
|
|
14668
14668
|
bytes23?: undefined;
|
|
14669
14669
|
bytes4?: undefined;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
var s = Object.defineProperty;
|
|
2
2
|
var c = (i, t, e) => t in i ? s(i, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : i[t] = e;
|
|
3
3
|
var o = (i, t, e) => c(i, typeof t != "symbol" ? t + "" : t, e);
|
|
4
|
-
import { V as h } from "../../constants-
|
|
4
|
+
import { V as h } from "../../constants-Bw9JXSap.js";
|
|
5
5
|
import { CONTRACT_ADDRESSES as l } from "../addresses.js";
|
|
6
6
|
import { Distributor as u } from "../abis/mainnet/Distributor.js";
|
|
7
|
-
import { g as C } from "../../getContract-
|
|
7
|
+
import { g as C } from "../../getContract-8WqQMpYW.js";
|
|
8
8
|
class O {
|
|
9
9
|
/**
|
|
10
10
|
* Create the handler for the Distributor contract exposing
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";var p=Object.defineProperty;var d=(i,t,e)=>t in i?p(i,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):i[t]=e;var c=(i,t,e)=>d(i,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("../../constants-
|
|
1
|
+
"use strict";var p=Object.defineProperty;var d=(i,t,e)=>t in i?p(i,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):i[t]=e;var c=(i,t,e)=>d(i,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("../../constants-B96CDi8I.cjs"),s=require("../tokens.cjs"),g=require("../../utils/time.cjs"),S=require("../abis/mainnet/ERC20Permit.cjs"),y=require("../../getContract-Bzdkp3oE.cjs"),C=require("../../secp256k1-BCRN0kWE.cjs");function E(i){const{r:t,s:e}=C.secp256k1.Signature.fromCompact(i.slice(2,130)),n=+`0x${i.slice(130)}`,[r,o]=(()=>{if(n===0||n===1)return[void 0,n];if(n===27)return[BigInt(n),0];if(n===28)return[BigInt(n),1];throw new Error("Invalid yParityOrV value")})();return typeof r<"u"?{r:a.numberToHex(t,{size:32}),s:a.numberToHex(e,{size:32}),v:r,yParity:o}:{r:a.numberToHex(t,{size:32}),s:a.numberToHex(e,{size:32}),yParity:o}}class T{constructor(t,e,n){c(this,"viemChain");c(this,"token");this.chain=t,this.walletClient=e,this.publicClient=n,this.viemChain=a.VIEM_CHAINS[t],this.token=s.Token.WETH}withToken(t){return this.token=t,this}getContract(){const t=s.TOKENS_ADDRESSES[this.token][this.chain],e=S.ERC20Permit,n={public:this.publicClient,wallet:this.walletClient};return y.getContract({address:t,abi:e,client:n})}async getPermitSignature(t,e,n){const r=this.getContract(),o=await r.read.nonces([t]),m={name:await r.read.name(),version:this.getPermitVersion(this.token),chainId:this.chain,verifyingContract:s.TOKENS_ADDRESSES[this.token][this.chain],salt:this.getPermitSalt(this.token)},h={Permit:[{name:"owner",type:"address"},{name:"spender",type:"address"},{name:"value",type:"uint256"},{name:"nonce",type:"uint256"},{name:"deadline",type:"uint256"}]},u=BigInt(g.getTimestampInSeconds()+60*60*2),l=await this.walletClient.signTypedData({account:t,domain:m,types:h,primaryType:"Permit",message:{owner:t,spender:e,value:n,nonce:o,deadline:u}});return{...E(l),deadline:u}}approve(t,e,n){return this.getContract().write.approve([e,n],{account:t,chain:this.viemChain})}getPermitVersion(t){return s.TOKENS_PERMIT_VERSION[t]}getPermitSalt(t){var e,n;return(n=(e=s.TOKENS_SALT)==null?void 0:e[t])==null?void 0:n[this.chain]}}exports.ERC20PermitHandler=T;
|
|
2
2
|
//# sourceMappingURL=erc20-permit-handler.cjs.map
|
|
@@ -14747,8 +14747,8 @@ export declare class ERC20PermitHandler {
|
|
|
14747
14747
|
[x: `bytes[${string}]`]: undefined;
|
|
14748
14748
|
[x: `bytes1[${string}]`]: undefined;
|
|
14749
14749
|
[x: `bytes18[${string}]`]: undefined;
|
|
14750
|
-
[x: `bytes2[${string}]`]: undefined;
|
|
14751
14750
|
[x: `bytes3[${string}]`]: undefined;
|
|
14751
|
+
[x: `bytes2[${string}]`]: undefined;
|
|
14752
14752
|
[x: `bytes12[${string}]`]: undefined;
|
|
14753
14753
|
[x: `bytes23[${string}]`]: undefined;
|
|
14754
14754
|
[x: `bytes4[${string}]`]: undefined;
|
|
@@ -14849,8 +14849,8 @@ export declare class ERC20PermitHandler {
|
|
|
14849
14849
|
bytes?: undefined;
|
|
14850
14850
|
bytes1?: undefined;
|
|
14851
14851
|
bytes18?: undefined;
|
|
14852
|
-
bytes2?: undefined;
|
|
14853
14852
|
bytes3?: undefined;
|
|
14853
|
+
bytes2?: undefined;
|
|
14854
14854
|
bytes12?: undefined;
|
|
14855
14855
|
bytes23?: undefined;
|
|
14856
14856
|
bytes4?: undefined;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
var l = Object.defineProperty;
|
|
2
2
|
var d = (i, t, e) => t in i ? l(i, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : i[t] = e;
|
|
3
3
|
var o = (i, t, e) => d(i, typeof t != "symbol" ? t + "" : t, e);
|
|
4
|
-
import { n as s, V as g } from "../../constants-
|
|
4
|
+
import { n as s, V as g } from "../../constants-Bw9JXSap.js";
|
|
5
5
|
import { Token as y, TOKENS_ADDRESSES as m, TOKENS_PERMIT_VERSION as C, TOKENS_SALT as f } from "../tokens.js";
|
|
6
6
|
import { getTimestampInSeconds as S } from "../../utils/time.js";
|
|
7
7
|
import { ERC20Permit as P } from "../abis/mainnet/ERC20Permit.js";
|
|
8
|
-
import { g as E } from "../../getContract-
|
|
9
|
-
import { secp256k1 as T } from "../../secp256k1-
|
|
8
|
+
import { g as E } from "../../getContract-8WqQMpYW.js";
|
|
9
|
+
import { secp256k1 as T } from "../../secp256k1-YxK0LcBT.js";
|
|
10
10
|
function v(i) {
|
|
11
11
|
const { r: t, s: e } = T.Signature.fromCompact(i.slice(2, 130)), n = +`0x${i.slice(130)}`, [r, a] = (() => {
|
|
12
12
|
if (n === 0 || n === 1)
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";var i=Object.defineProperty;var s=(a,t,e)=>t in a?i(a,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):a[t]=e;var n=(a,t,e)=>s(a,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("../../constants-
|
|
1
|
+
"use strict";var i=Object.defineProperty;var s=(a,t,e)=>t in a?i(a,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):a[t]=e;var n=(a,t,e)=>s(a,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("../../constants-B96CDi8I.cjs"),o=require("../addresses.cjs"),l=require("../abis/mainnet/L1RewardManager.cjs"),C=require("../../getContract-Bzdkp3oE.cjs");class d{constructor(t,e,r){n(this,"viemChain");this.chain=t,this.walletClient=e,this.publicClient=r,this.viemChain=c.VIEM_CHAINS[t]}getContract(){const t=o.CONTRACT_ADDRESSES[this.chain].L1RewardManager,e=l.L1RewardManager,r={public:this.publicClient,wallet:this.walletClient};return C.getContract({address:t,abi:e,client:r})}getBridge(t){return this.getContract().read.getBridge([t])}setL2RewardClaimer(t,e,r){return{transact:()=>this.getContract().write.setL2RewardClaimer([e,r],{chain:this.viemChain,account:t}),estimate:()=>this.getContract().estimateGas.setL2RewardClaimer([e,r],{account:t})}}}exports.L1RewardManagerHandler=d;
|
|
2
2
|
//# sourceMappingURL=l1-reward-manager-handler.cjs.map
|
|
@@ -14377,8 +14377,8 @@ export declare class L1RewardManagerHandler {
|
|
|
14377
14377
|
[x: `bytes[${string}]`]: undefined;
|
|
14378
14378
|
[x: `bytes1[${string}]`]: undefined;
|
|
14379
14379
|
[x: `bytes18[${string}]`]: undefined;
|
|
14380
|
-
[x: `bytes2[${string}]`]: undefined;
|
|
14381
14380
|
[x: `bytes3[${string}]`]: undefined;
|
|
14381
|
+
[x: `bytes2[${string}]`]: undefined;
|
|
14382
14382
|
[x: `bytes12[${string}]`]: undefined;
|
|
14383
14383
|
[x: `bytes23[${string}]`]: undefined;
|
|
14384
14384
|
[x: `bytes4[${string}]`]: undefined;
|
|
@@ -14479,8 +14479,8 @@ export declare class L1RewardManagerHandler {
|
|
|
14479
14479
|
bytes?: undefined;
|
|
14480
14480
|
bytes1?: undefined;
|
|
14481
14481
|
bytes18?: undefined;
|
|
14482
|
-
bytes2?: undefined;
|
|
14483
14482
|
bytes3?: undefined;
|
|
14483
|
+
bytes2?: undefined;
|
|
14484
14484
|
bytes12?: undefined;
|
|
14485
14485
|
bytes23?: undefined;
|
|
14486
14486
|
bytes4?: undefined;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
var s = Object.defineProperty;
|
|
2
2
|
var n = (a, t, e) => t in a ? s(a, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : a[t] = e;
|
|
3
3
|
var i = (a, t, e) => n(a, typeof t != "symbol" ? t + "" : t, e);
|
|
4
|
-
import { V as o } from "../../constants-
|
|
4
|
+
import { V as o } from "../../constants-Bw9JXSap.js";
|
|
5
5
|
import { CONTRACT_ADDRESSES as c } from "../addresses.js";
|
|
6
6
|
import { L1RewardManager as l } from "../abis/mainnet/L1RewardManager.js";
|
|
7
|
-
import { g as C } from "../../getContract-
|
|
7
|
+
import { g as C } from "../../getContract-8WqQMpYW.js";
|
|
8
8
|
class u {
|
|
9
9
|
/**
|
|
10
10
|
* Create the handler for the `L1RewardManager` contract exposing
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";var n=Object.defineProperty;var s=(r,t,e)=>t in r?n(r,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):r[t]=e;var i=(r,t,e)=>s(r,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("../../constants-
|
|
1
|
+
"use strict";var n=Object.defineProperty;var s=(r,t,e)=>t in r?n(r,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):r[t]=e;var i=(r,t,e)=>s(r,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("../../constants-B96CDi8I.cjs"),o=require("../addresses.cjs"),l=require("../../errors/validation-errors.cjs"),d=require("../abis/mainnet/L2RewardManager.cjs"),g=require("../../getContract-Bzdkp3oE.cjs");class C{constructor(t,e,a){i(this,"viemChain");this.chain=t,this.walletClient=e,this.publicClient=a,this.viemChain=c.VIEM_CHAINS[t]}getContract(){const t=o.CONTRACT_ADDRESSES[this.chain].L2RewardManager,e=d.L2RewardManager,a={public:this.publicClient,wallet:this.walletClient};return g.getContract({address:t,abi:e,client:a})}authority(){return this.getContract().read.authority()}getClaimingDelay(){return this.getContract().read.getClaimingDelay()}getEpochRecord(t){return this.getContract().read.getEpochRecord([t])}getIntervalId(t,e){return this.getContract().read.getIntervalId([t,e])}getRewardsClaimer(t){return this.getContract().read.getRewardsClaimer([t])}isClaimed(t,e){return this.getContract().read.isClaimed([e,t])}isClaimingLocked(t){return this.getContract().read.isClaimingLocked([t])}claimRewards(t,e){if(e.length===0)throw new l.InvalidInputError("`claimOrders` cannot be empty and must be specified",{fixMessage:"Specify at least one or more claim orders to claim rewards"});return{transact:()=>this.getContract().write.claimRewards([e],{chain:this.viemChain,account:t}),estimate:()=>this.getContract().estimateGas.claimRewards([e],{account:t})}}}exports.L2RewardManagerHandler=C;
|
|
2
2
|
//# sourceMappingURL=l2-reward-manager-handler.cjs.map
|
|
@@ -14509,8 +14509,8 @@ export declare class L2RewardManagerHandler {
|
|
|
14509
14509
|
[x: `bytes[${string}]`]: undefined;
|
|
14510
14510
|
[x: `bytes1[${string}]`]: undefined;
|
|
14511
14511
|
[x: `bytes18[${string}]`]: undefined;
|
|
14512
|
-
[x: `bytes2[${string}]`]: undefined;
|
|
14513
14512
|
[x: `bytes3[${string}]`]: undefined;
|
|
14513
|
+
[x: `bytes2[${string}]`]: undefined;
|
|
14514
14514
|
[x: `bytes12[${string}]`]: undefined;
|
|
14515
14515
|
[x: `bytes23[${string}]`]: undefined;
|
|
14516
14516
|
[x: `bytes4[${string}]`]: undefined;
|
|
@@ -14611,8 +14611,8 @@ export declare class L2RewardManagerHandler {
|
|
|
14611
14611
|
bytes?: undefined;
|
|
14612
14612
|
bytes1?: undefined;
|
|
14613
14613
|
bytes18?: undefined;
|
|
14614
|
-
bytes2?: undefined;
|
|
14615
14614
|
bytes3?: undefined;
|
|
14615
|
+
bytes2?: undefined;
|
|
14616
14616
|
bytes12?: undefined;
|
|
14617
14617
|
bytes23?: undefined;
|
|
14618
14618
|
bytes4?: undefined;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
var n = Object.defineProperty;
|
|
2
2
|
var s = (r, t, e) => t in r ? n(r, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : r[t] = e;
|
|
3
3
|
var i = (r, t, e) => s(r, typeof t != "symbol" ? t + "" : t, e);
|
|
4
|
-
import { V as o } from "../../constants-
|
|
4
|
+
import { V as o } from "../../constants-Bw9JXSap.js";
|
|
5
5
|
import { CONTRACT_ADDRESSES as c } from "../addresses.js";
|
|
6
6
|
import { InvalidInputError as l } from "../../errors/validation-errors.js";
|
|
7
7
|
import { L2RewardManager as m } from "../abis/mainnet/L2RewardManager.js";
|
|
8
|
-
import { g as d } from "../../getContract-
|
|
8
|
+
import { g as d } from "../../getContract-8WqQMpYW.js";
|
|
9
9
|
class f {
|
|
10
10
|
/**
|
|
11
11
|
* Create the handler for the `L2RewardManager` contract exposing
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";var s=Object.defineProperty;var o=(n,t,e)=>t in n?s(n,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):n[t]=e;var i=(n,t,e)=>o(n,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const h=require("../../constants-
|
|
1
|
+
"use strict";var s=Object.defineProperty;var o=(n,t,e)=>t in n?s(n,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):n[t]=e;var i=(n,t,e)=>o(n,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const h=require("../../constants-B96CDi8I.cjs"),a=require("../tokens.cjs"),l=require("../abis/mainnet/mtwCARROT.cjs"),C=require("../../getContract-Bzdkp3oE.cjs");class u{constructor(t,e,r){i(this,"viemChain");this.chain=t,this.walletClient=e,this.publicClient=r,this.viemChain=h.VIEM_CHAINS[t]}getContract(){const t=a.TOKENS_ADDRESSES[a.Token.mtwCARROT][this.chain],e=l.mtwCARROT,r={public:this.publicClient,wallet:this.walletClient};return C.getContract({address:t,abi:e,client:r})}balanceOf(t){return this.getContract().read.balanceOf([t])}allowance(t,e){return this.getContract().read.allowance([t,e])}claimable(t,e){return e!==void 0?this.getContract().read.claimable([t,e]):this.getContract().read.claimable([t])}cliffDuration(){return this.getContract().read.cliffDuration()}async getUserVestings(t){const[e,r]=await this.getContract().read.getUserVestings([t]);return{allVestings:e,nextClaimIndex:r}}isTokenWrapper(){return this.getContract().read.isTokenWrapper()}symbol(){return this.getContract().read.symbol()}token(){return this.getContract().read.token()}underlying(){return this.getContract().read.underlying()}vestingData(t){return this.getContract().read.vestingData([t])}approve(t,e,r){return this.getContract().write.approve([e,r],{account:t,chain:this.viemChain})}claim(t,e,r){return r!==void 0?this.getContract().write.claim([e,r],{account:t,chain:this.viemChain}):this.getContract().write.claim([e],{account:t,chain:this.viemChain})}decreaseAllowance(t,e,r){return this.getContract().write.decreaseAllowance([e,r],{account:t,chain:this.viemChain})}increaseAllowance(t,e,r){return this.getContract().write.increaseAllowance([e,r],{account:t,chain:this.viemChain})}recoverERC20(t,e,r,c){return this.getContract().write.recoverERC20([e,r,c],{account:t,chain:this.viemChain})}transfer(t,e,r){return this.getContract().write.transfer([e,r],{account:t,chain:this.viemChain})}}exports.MtwCarrotHandler=u;
|
|
2
2
|
//# sourceMappingURL=mtw-carrot-handler.cjs.map
|
|
@@ -14621,8 +14621,8 @@ export declare class MtwCarrotHandler {
|
|
|
14621
14621
|
[x: `bytes[${string}]`]: undefined;
|
|
14622
14622
|
[x: `bytes1[${string}]`]: undefined;
|
|
14623
14623
|
[x: `bytes18[${string}]`]: undefined;
|
|
14624
|
-
[x: `bytes2[${string}]`]: undefined;
|
|
14625
14624
|
[x: `bytes3[${string}]`]: undefined;
|
|
14625
|
+
[x: `bytes2[${string}]`]: undefined;
|
|
14626
14626
|
[x: `bytes12[${string}]`]: undefined;
|
|
14627
14627
|
[x: `bytes23[${string}]`]: undefined;
|
|
14628
14628
|
[x: `bytes4[${string}]`]: undefined;
|
|
@@ -14723,8 +14723,8 @@ export declare class MtwCarrotHandler {
|
|
|
14723
14723
|
bytes?: undefined;
|
|
14724
14724
|
bytes1?: undefined;
|
|
14725
14725
|
bytes18?: undefined;
|
|
14726
|
-
bytes2?: undefined;
|
|
14727
14726
|
bytes3?: undefined;
|
|
14727
|
+
bytes2?: undefined;
|
|
14728
14728
|
bytes12?: undefined;
|
|
14729
14729
|
bytes23?: undefined;
|
|
14730
14730
|
bytes4?: undefined;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
var c = Object.defineProperty;
|
|
2
2
|
var s = (i, t, e) => t in i ? c(i, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : i[t] = e;
|
|
3
3
|
var a = (i, t, e) => s(i, typeof t != "symbol" ? t + "" : t, e);
|
|
4
|
-
import { V as o } from "../../constants-
|
|
4
|
+
import { V as o } from "../../constants-Bw9JXSap.js";
|
|
5
5
|
import { TOKENS_ADDRESSES as h, Token as l } from "../tokens.js";
|
|
6
6
|
import { mtwCARROT as C } from "../abis/mainnet/mtwCARROT.js";
|
|
7
|
-
import { g } from "../../getContract-
|
|
7
|
+
import { g } from "../../getContract-8WqQMpYW.js";
|
|
8
8
|
class p {
|
|
9
9
|
/**
|
|
10
10
|
* Create the handler for the `mtwCARROT` token contract exposing
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";var c=Object.defineProperty;var i=(n,t,e)=>t in n?c(n,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):n[t]=e;var r=(n,t,e)=>i(n,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("../vaults-addresses.cjs"),s=require("../tokens.cjs"),u=require("../abis/mainnet/Accountant.cjs"),l=require("../../getContract-
|
|
1
|
+
"use strict";var c=Object.defineProperty;var i=(n,t,e)=>t in n?c(n,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):n[t]=e;var r=(n,t,e)=>i(n,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("../vaults-addresses.cjs"),s=require("../tokens.cjs"),u=require("../abis/mainnet/Accountant.cjs"),l=require("../../getContract-Bzdkp3oE.cjs");class g{constructor(t,e,a){r(this,"token");this.chain=t,this.walletClient=e,this.publicClient=a,this.token=s.UnifiToken.unifiETH}withToken(t){return this.token=t,this}getContract(){const t=o.VAULTS_ADDRESSES[this.token][this.chain].NucleusAccountant,e=u.Accountant,a={public:this.publicClient,wallet:this.walletClient};return l.getContract({address:t,abi:e,client:a})}async rateProviderData(t){const[e,a]=await this.getContract().read.rateProviderData([t]);return{isPeggedToBase:e,rateProvider:a}}vault(){return this.getContract().read.vault()}getRate(){return this.getContract().read.getRate()}getRateSafe(){return this.getContract().read.getRateSafe()}getRateInQuote(t){return this.getContract().read.getRateInQuote([t])}getRateInQuoteSafe(t){return this.getContract().read.getRateInQuoteSafe([t])}}exports.NucleusAccountantHandler=g;
|
|
2
2
|
//# sourceMappingURL=nucleus-accountant-handler.cjs.map
|
|
@@ -14428,8 +14428,8 @@ export declare class NucleusAccountantHandler {
|
|
|
14428
14428
|
[x: `bytes[${string}]`]: undefined;
|
|
14429
14429
|
[x: `bytes1[${string}]`]: undefined;
|
|
14430
14430
|
[x: `bytes18[${string}]`]: undefined;
|
|
14431
|
-
[x: `bytes2[${string}]`]: undefined;
|
|
14432
14431
|
[x: `bytes3[${string}]`]: undefined;
|
|
14432
|
+
[x: `bytes2[${string}]`]: undefined;
|
|
14433
14433
|
[x: `bytes12[${string}]`]: undefined;
|
|
14434
14434
|
[x: `bytes23[${string}]`]: undefined;
|
|
14435
14435
|
[x: `bytes4[${string}]`]: undefined;
|
|
@@ -14530,8 +14530,8 @@ export declare class NucleusAccountantHandler {
|
|
|
14530
14530
|
bytes?: undefined;
|
|
14531
14531
|
bytes1?: undefined;
|
|
14532
14532
|
bytes18?: undefined;
|
|
14533
|
-
bytes2?: undefined;
|
|
14534
14533
|
bytes3?: undefined;
|
|
14534
|
+
bytes2?: undefined;
|
|
14535
14535
|
bytes12?: undefined;
|
|
14536
14536
|
bytes23?: undefined;
|
|
14537
14537
|
bytes4?: undefined;
|
|
@@ -4,7 +4,7 @@ var n = (a, t, e) => o(a, typeof t != "symbol" ? t + "" : t, e);
|
|
|
4
4
|
import { VAULTS_ADDRESSES as s } from "../vaults-addresses.js";
|
|
5
5
|
import { UnifiToken as c } from "../tokens.js";
|
|
6
6
|
import { Accountant as u } from "../abis/mainnet/Accountant.js";
|
|
7
|
-
import { g as l } from "../../getContract-
|
|
7
|
+
import { g as l } from "../../getContract-8WqQMpYW.js";
|
|
8
8
|
class R {
|
|
9
9
|
/**
|
|
10
10
|
* Create the handler for processing tokens.
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";var u=Object.defineProperty;var a=(s,t,e)=>t in s?u(s,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):s[t]=e;var n=(s,t,e)=>a(s,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("../../constants-
|
|
1
|
+
"use strict";var u=Object.defineProperty;var a=(s,t,e)=>t in s?u(s,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):s[t]=e;var n=(s,t,e)=>a(s,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("../../constants-B96CDi8I.cjs"),l=require("../addresses.cjs"),h=require("../abis/mainnet/AtomicQueue.cjs"),C=require("../../getContract-Bzdkp3oE.cjs");class m{constructor(t,e,i){n(this,"viemChain");this.chain=t,this.walletClient=e,this.publicClient=i,this.viemChain=o.VIEM_CHAINS[t]}getContract(){const t=l.CONTRACT_ADDRESSES[this.chain].NucleusAtomicQueue,e=h.AtomicQueue,i={public:this.publicClient,wallet:this.walletClient};return C.getContract({address:t,abi:e,client:i})}getUserAtomicRequest(t,e,i){return this.getContract().read.getUserAtomicRequest([t,e,i])}isAtomicRequestValid(t,e,i){return this.getContract().read.isAtomicRequestValid([t,e,i])}solve(t,e,i,c,r){return this.getContract().write.solve([t,e,i,c,r],{account:this.walletClient.account,chain:this.viemChain})}updateAtomicRequest(t,e,i,c){return this.getContract().write.updateAtomicRequest([t,e,i],{account:c,chain:this.viemChain})}userAtomicRequest(t,e,i){return this.getContract().read.userAtomicRequest([t,e,i])}}exports.NucleusAtomicQueueHandler=m;
|
|
2
2
|
//# sourceMappingURL=nucleus-atomic-queue-handler.cjs.map
|
|
@@ -14667,8 +14667,8 @@ export declare class NucleusAtomicQueueHandler {
|
|
|
14667
14667
|
[x: `bytes[${string}]`]: undefined;
|
|
14668
14668
|
[x: `bytes1[${string}]`]: undefined;
|
|
14669
14669
|
[x: `bytes18[${string}]`]: undefined;
|
|
14670
|
-
[x: `bytes2[${string}]`]: undefined;
|
|
14671
14670
|
[x: `bytes3[${string}]`]: undefined;
|
|
14671
|
+
[x: `bytes2[${string}]`]: undefined;
|
|
14672
14672
|
[x: `bytes12[${string}]`]: undefined;
|
|
14673
14673
|
[x: `bytes23[${string}]`]: undefined;
|
|
14674
14674
|
[x: `bytes4[${string}]`]: undefined;
|
|
@@ -14769,8 +14769,8 @@ export declare class NucleusAtomicQueueHandler {
|
|
|
14769
14769
|
bytes?: undefined;
|
|
14770
14770
|
bytes1?: undefined;
|
|
14771
14771
|
bytes18?: undefined;
|
|
14772
|
-
bytes2?: undefined;
|
|
14773
14772
|
bytes3?: undefined;
|
|
14773
|
+
bytes2?: undefined;
|
|
14774
14774
|
bytes12?: undefined;
|
|
14775
14775
|
bytes23?: undefined;
|
|
14776
14776
|
bytes4?: undefined;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
var u = Object.defineProperty;
|
|
2
2
|
var a = (s, t, e) => t in s ? u(s, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : s[t] = e;
|
|
3
3
|
var c = (s, t, e) => a(s, typeof t != "symbol" ? t + "" : t, e);
|
|
4
|
-
import { V as n } from "../../constants-
|
|
4
|
+
import { V as n } from "../../constants-Bw9JXSap.js";
|
|
5
5
|
import { CONTRACT_ADDRESSES as l } from "../addresses.js";
|
|
6
6
|
import { AtomicQueue as m } from "../abis/mainnet/AtomicQueue.js";
|
|
7
|
-
import { g as h } from "../../getContract-
|
|
7
|
+
import { g as h } from "../../getContract-8WqQMpYW.js";
|
|
8
8
|
class R {
|
|
9
9
|
constructor(t, e, i) {
|
|
10
10
|
c(this, "viemChain");
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";var l=Object.defineProperty;var C=(a,t,e)=>t in a?l(a,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):a[t]=e;var c=(a,t,e)=>C(a,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const m=require("../../constants-
|
|
1
|
+
"use strict";var l=Object.defineProperty;var C=(a,t,e)=>t in a?l(a,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):a[t]=e;var c=(a,t,e)=>C(a,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const m=require("../../constants-B96CDi8I.cjs"),g=require("../vaults-addresses.cjs"),p=require("../tokens.cjs"),f=require("../abis/mainnet/BoringVault.cjs"),v=require("../../getContract-Bzdkp3oE.cjs");class b{constructor(t,e,n){c(this,"viemChain");c(this,"token");this.chain=t,this.walletClient=e,this.publicClient=n,this.viemChain=m.VIEM_CHAINS[t],this.token=p.UnifiToken.unifiETH}withToken(t){return this.token=t,this}getContract(){const t=g.VAULTS_ADDRESSES[this.token][this.chain].NucleusBoringVault,e=f.BoringVault,n={public:this.publicClient,wallet:this.walletClient};return v.getContract({address:t,abi:e,client:n})}getAllowance(t,e){return this.getContract().read.allowance([t,e])}balanceOf(t){return this.getContract().read.balanceOf([t])}totalSupply(){return this.getContract().read.totalSupply()}approve(t,e,n){return this.getContract().write.approve([e,n],{account:t,chain:this.viemChain})}transfer(t,e,n){return{transact:()=>this.getContract().write.transfer([e,n],{account:t,chain:this.viemChain}),estimate:()=>this.getContract().estimateGas.transfer([e,n],{account:t})}}transferFrom(t,e,n,i){return{transact:()=>this.getContract().write.transferFrom([e,n,i],{account:t,chain:this.viemChain}),estimate:()=>this.getContract().estimateGas.transferFrom([e,n,i],{account:t})}}permit(t){const{account:e,owner:n,spender:i,value:r,deadline:s,v:o,r:u,s:h}=t;return{transact:()=>this.getContract().write.permit([n,i,r,s,o,u,h],{account:e,chain:this.viemChain}),estimate:()=>this.getContract().estimateGas.permit([n,i,r,s,o,u,h],{account:e})}}}exports.NucleusBoringVaultHandler=b;
|
|
2
2
|
//# sourceMappingURL=nucleus-boring-vault-handler.cjs.map
|
|
@@ -14498,8 +14498,8 @@ export declare class NucleusBoringVaultHandler {
|
|
|
14498
14498
|
[x: `bytes[${string}]`]: undefined;
|
|
14499
14499
|
[x: `bytes1[${string}]`]: undefined;
|
|
14500
14500
|
[x: `bytes18[${string}]`]: undefined;
|
|
14501
|
-
[x: `bytes2[${string}]`]: undefined;
|
|
14502
14501
|
[x: `bytes3[${string}]`]: undefined;
|
|
14502
|
+
[x: `bytes2[${string}]`]: undefined;
|
|
14503
14503
|
[x: `bytes12[${string}]`]: undefined;
|
|
14504
14504
|
[x: `bytes23[${string}]`]: undefined;
|
|
14505
14505
|
[x: `bytes4[${string}]`]: undefined;
|
|
@@ -14600,8 +14600,8 @@ export declare class NucleusBoringVaultHandler {
|
|
|
14600
14600
|
bytes?: undefined;
|
|
14601
14601
|
bytes1?: undefined;
|
|
14602
14602
|
bytes18?: undefined;
|
|
14603
|
-
bytes2?: undefined;
|
|
14604
14603
|
bytes3?: undefined;
|
|
14604
|
+
bytes2?: undefined;
|
|
14605
14605
|
bytes12?: undefined;
|
|
14606
14606
|
bytes23?: undefined;
|
|
14607
14607
|
bytes4?: undefined;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
var u = Object.defineProperty;
|
|
2
2
|
var l = (a, t, n) => t in a ? u(a, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : a[t] = n;
|
|
3
3
|
var c = (a, t, n) => l(a, typeof t != "symbol" ? t + "" : t, n);
|
|
4
|
-
import { V as C } from "../../constants-
|
|
4
|
+
import { V as C } from "../../constants-Bw9JXSap.js";
|
|
5
5
|
import { VAULTS_ADDRESSES as p } from "../vaults-addresses.js";
|
|
6
6
|
import { UnifiToken as g } from "../tokens.js";
|
|
7
7
|
import { BoringVault as f } from "../abis/mainnet/BoringVault.js";
|
|
8
|
-
import { g as w } from "../../getContract-
|
|
8
|
+
import { g as w } from "../../getContract-8WqQMpYW.js";
|
|
9
9
|
class F {
|
|
10
10
|
/**
|
|
11
11
|
* Create the handler for processing UniFi tokens.
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";var P=Object.defineProperty;var p=(r,t,e)=>t in r?P(r,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):r[t]=e;var u=(r,t,e)=>p(r,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const S=require("../../constants-
|
|
1
|
+
"use strict";var P=Object.defineProperty;var p=(r,t,e)=>t in r?P(r,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):r[t]=e;var u=(r,t,e)=>p(r,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const S=require("../../constants-B96CDi8I.cjs"),T=require("../vaults-addresses.cjs"),l=require("../tokens.cjs"),k=require("./erc20-permit-handler.cjs"),v=require("../abis/mainnet/Teller.cjs"),_=require("../../getContract-Bzdkp3oE.cjs");class E{constructor(t,e,i){u(this,"viemChain");u(this,"erc20PermitHandler");u(this,"token");this.chain=t,this.walletClient=e,this.publicClient=i,this.viemChain=S.VIEM_CHAINS[t],this.erc20PermitHandler=new k.ERC20PermitHandler(t,e,i),this.token=l.UnifiToken.unifiETH}withToken(t){return this.token=t,this}getContract(){const t=T.VAULTS_ADDRESSES[this.token][this.chain].NucleusTeller,e=v.Teller,i={public:this.publicClient,wallet:this.walletClient};return _.getContract({address:t,abi:e,client:i})}accountant(){return this.getContract().read.accountant()}vault(){return this.getContract().read.vault()}shareLockPeriod(){return this.getContract().read.shareLockPeriod()}shareUnlockTime(t){return this.getContract().read.shareUnlockTime([t])}isPaused(){return this.getContract().read.isPaused()}async deposit(t){const{token:e,unifiToken:i,account:s,amount:n,minimumMint:a,isPreapproved:o=!1}=t,c=l.TOKENS_ADDRESSES[e][this.chain];if(o)return{transact:()=>this.getContract().write.deposit([c,n,a],{account:s,chain:this.viemChain}),estimate:()=>this.getContract().estimateGas.deposit([c,n,a],{account:s})};const{r:h,s:d,v:m,deadline:g}=await this.erc20PermitHandler.withToken(e).getPermitSignature(s,l.TOKENS_ADDRESSES[i][this.chain],n),C=[c,n,a,g,Number(m),h,d];return{transact:()=>this.getContract().write.depositWithPermit(C,{account:s,chain:this.viemChain}),estimate:()=>this.getContract().estimateGas.depositWithPermit(C,{account:s})}}depositWithPermit(t){const{account:e,depositAsset:i,depositAmount:s,minimumMint:n,deadline:a,v:o,r:c,s:h}=t;return{transact:()=>this.getContract().write.depositWithPermit([i,s,n,a,o,c,h],{account:e,chain:this.viemChain}),estimate:()=>this.getContract().estimateGas.depositWithPermit([i,s,n,a,o,c,h],{account:e})}}}exports.NucleusTellerHandler=E;
|
|
2
2
|
//# sourceMappingURL=nucleus-teller-handler.cjs.map
|
|
@@ -14486,8 +14486,8 @@ export declare class NucleusTellerHandler {
|
|
|
14486
14486
|
[x: `bytes[${string}]`]: undefined;
|
|
14487
14487
|
[x: `bytes1[${string}]`]: undefined;
|
|
14488
14488
|
[x: `bytes18[${string}]`]: undefined;
|
|
14489
|
-
[x: `bytes2[${string}]`]: undefined;
|
|
14490
14489
|
[x: `bytes3[${string}]`]: undefined;
|
|
14490
|
+
[x: `bytes2[${string}]`]: undefined;
|
|
14491
14491
|
[x: `bytes12[${string}]`]: undefined;
|
|
14492
14492
|
[x: `bytes23[${string}]`]: undefined;
|
|
14493
14493
|
[x: `bytes4[${string}]`]: undefined;
|
|
@@ -14588,8 +14588,8 @@ export declare class NucleusTellerHandler {
|
|
|
14588
14588
|
bytes?: undefined;
|
|
14589
14589
|
bytes1?: undefined;
|
|
14590
14590
|
bytes18?: undefined;
|
|
14591
|
-
bytes2?: undefined;
|
|
14592
14591
|
bytes3?: undefined;
|
|
14592
|
+
bytes2?: undefined;
|
|
14593
14593
|
bytes12?: undefined;
|
|
14594
14594
|
bytes23?: undefined;
|
|
14595
14595
|
bytes4?: undefined;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
var g = Object.defineProperty;
|
|
2
2
|
var P = (n, t, e) => t in n ? g(n, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[t] = e;
|
|
3
3
|
var m = (n, t, e) => P(n, typeof t != "symbol" ? t + "" : t, e);
|
|
4
|
-
import { V as k } from "../../constants-
|
|
4
|
+
import { V as k } from "../../constants-Bw9JXSap.js";
|
|
5
5
|
import { VAULTS_ADDRESSES as T } from "../vaults-addresses.js";
|
|
6
6
|
import { UnifiToken as f, TOKENS_ADDRESSES as p } from "../tokens.js";
|
|
7
7
|
import { ERC20PermitHandler as v } from "./erc20-permit-handler.js";
|
|
8
8
|
import { Teller as S } from "../abis/mainnet/Teller.js";
|
|
9
|
-
import { g as w } from "../../getContract-
|
|
9
|
+
import { g as w } from "../../getContract-8WqQMpYW.js";
|
|
10
10
|
class L {
|
|
11
11
|
/**
|
|
12
12
|
* Create the handler for processing tokens.
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";var p=Object.defineProperty;var D=(r,t,e)=>t in r?p(r,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):r[t]=e;var c=(r,t,e)=>D(r,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("../../constants-
|
|
1
|
+
"use strict";var p=Object.defineProperty;var D=(r,t,e)=>t in r?p(r,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):r[t]=e;var c=(r,t,e)=>D(r,typeof t!="symbol"?t+"":t,e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("../../constants-B96CDi8I.cjs"),S=require("../addresses.cjs"),n=require("../tokens.cjs"),_=require("./erc20-permit-handler.cjs"),w=require("../abis/mainnet/PufLocker.cjs"),k=require("../../getContract-Bzdkp3oE.cjs");class A{constructor(t,e,i){c(this,"viemChain");c(this,"erc20PermitHandler");this.chain=t,this.walletClient=e,this.publicClient=i,this.viemChain=o.VIEM_CHAINS[t],this.erc20PermitHandler=new _.ERC20PermitHandler(t,e,i)}getContract(){const t=S.CONTRACT_ADDRESSES[this.chain].PufLocker,e=w.PufLocker,i={public:this.publicClient,wallet:this.walletClient};return k.getContract({address:t,abi:e,client:i})}getAllDeposits(t,e){return this.getContract().read.getAllDeposits([n.TOKENS_ADDRESSES[t][this.chain],e])}getDeposits(t,e,i,a){return this.getContract().read.getDeposits([e,n.TOKENS_ADDRESSES[t][this.chain],i,a])}getLockPeriods(){return this.getContract().read.getLockPeriods()}async deposit(t){const{token:e,account:i,recipient:a,value:s,lockPeriod:h,isPreapproved:d=!1}=t;let u={r:o.padHex("0x",{size:32}),s:o.padHex("0x",{size:32}),v:0,deadline:0n,amount:s};if(!d){const{r:g,s:m,v:C,yParity:E,deadline:P}=await this.erc20PermitHandler.withToken(e).getPermitSignature(i,S.CONTRACT_ADDRESSES[this.chain].PufLocker,s);u={r:g,s:m,v:Number(C??E),deadline:P,amount:s}}const l=[n.TOKENS_ADDRESSES[e][this.chain],a,h,u];return{transact:()=>this.getContract().write.deposit(l,{account:i,chain:this.viemChain}),estimate:()=>this.getContract().estimateGas.deposit(l,{account:i})}}withdraw(t,e,i,a){const s=[n.TOKENS_ADDRESSES[t][this.chain],a,i];return{transact:()=>this.getContract().write.withdraw(s,{account:e,chain:this.viemChain}),estimate:()=>this.getContract().estimateGas.withdraw(s,{account:e})}}}exports.PufLockerHandler=A;
|
|
2
2
|
//# sourceMappingURL=puf-locker-handler.cjs.map
|
|
@@ -14492,8 +14492,8 @@ export declare class PufLockerHandler {
|
|
|
14492
14492
|
[x: `bytes[${string}]`]: undefined;
|
|
14493
14493
|
[x: `bytes1[${string}]`]: undefined;
|
|
14494
14494
|
[x: `bytes18[${string}]`]: undefined;
|
|
14495
|
-
[x: `bytes2[${string}]`]: undefined;
|
|
14496
14495
|
[x: `bytes3[${string}]`]: undefined;
|
|
14496
|
+
[x: `bytes2[${string}]`]: undefined;
|
|
14497
14497
|
[x: `bytes12[${string}]`]: undefined;
|
|
14498
14498
|
[x: `bytes23[${string}]`]: undefined;
|
|
14499
14499
|
[x: `bytes4[${string}]`]: undefined;
|
|
@@ -14594,8 +14594,8 @@ export declare class PufLockerHandler {
|
|
|
14594
14594
|
bytes?: undefined;
|
|
14595
14595
|
bytes1?: undefined;
|
|
14596
14596
|
bytes18?: undefined;
|
|
14597
|
-
bytes2?: undefined;
|
|
14598
14597
|
bytes3?: undefined;
|
|
14598
|
+
bytes2?: undefined;
|
|
14599
14599
|
bytes12?: undefined;
|
|
14600
14600
|
bytes23?: undefined;
|
|
14601
14601
|
bytes4?: undefined;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
var f = Object.defineProperty;
|
|
2
2
|
var k = (r, t, e) => t in r ? f(r, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : r[t] = e;
|
|
3
3
|
var o = (r, t, e) => k(r, typeof t != "symbol" ? t + "" : t, e);
|
|
4
|
-
import { V as v, p as l } from "../../constants-
|
|
4
|
+
import { V as v, p as l } from "../../constants-Bw9JXSap.js";
|
|
5
5
|
import { CONTRACT_ADDRESSES as p } from "../addresses.js";
|
|
6
6
|
import { TOKENS_ADDRESSES as n } from "../tokens.js";
|
|
7
7
|
import { ERC20PermitHandler as D } from "./erc20-permit-handler.js";
|
|
8
8
|
import { PufLocker as S } from "../abis/mainnet/PufLocker.js";
|
|
9
|
-
import { g as A } from "../../getContract-
|
|
9
|
+
import { g as A } from "../../getContract-8WqQMpYW.js";
|
|
10
10
|
class _ {
|
|
11
11
|
/**
|
|
12
12
|
* Create the handler for the `PufLocker` contract exposing methods to
|