@dhedge/v2-sdk 2.1.2 → 2.1.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.
@@ -4272,6 +4272,34 @@ var abi$2 = [
4272
4272
  ],
4273
4273
  stateMutability: "nonpayable",
4274
4274
  type: "function"
4275
+ },
4276
+ {
4277
+ inputs: [
4278
+ {
4279
+ internalType: "uint256",
4280
+ name: "_maxSupplyCapD18",
4281
+ type: "uint256"
4282
+ }
4283
+ ],
4284
+ name: "setMaxSupplyCap",
4285
+ outputs: [
4286
+ ],
4287
+ stateMutability: "nonpayable",
4288
+ type: "function"
4289
+ },
4290
+ {
4291
+ inputs: [
4292
+ ],
4293
+ name: "maxSupplyCap",
4294
+ outputs: [
4295
+ {
4296
+ internalType: "uint256",
4297
+ name: "",
4298
+ type: "uint256"
4299
+ }
4300
+ ],
4301
+ stateMutability: "view",
4302
+ type: "function"
4275
4303
  }
4276
4304
  ];
4277
4305
  var ManagerLogic = {
@@ -29600,6 +29628,65 @@ var Pool = /*#__PURE__*/function () {
29600
29628
 
29601
29629
  return setPrivate;
29602
29630
  }()
29631
+ /**
29632
+ * Sets max supply cap for a pool
29633
+ * @param {BigNumberish} _maxSupplyCapD18 Max supply cap with 18 decimals
29634
+ * @param {any} options Transaction options
29635
+ * @param {boolean} estimateGas Simulate/estimate gas
29636
+ * @returns {Promise<any>} Transaction
29637
+ */
29638
+ ;
29639
+
29640
+ _proto.setMaxCap =
29641
+ /*#__PURE__*/
29642
+ function () {
29643
+ var _setMaxCap = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee27(_maxSupplyCapD18, options, estimateGas) {
29644
+ var tx;
29645
+ return runtime_1.wrap(function _callee27$(_context27) {
29646
+ while (1) {
29647
+ switch (_context27.prev = _context27.next) {
29648
+ case 0:
29649
+ if (options === void 0) {
29650
+ options = null;
29651
+ }
29652
+
29653
+ if (estimateGas === void 0) {
29654
+ estimateGas = false;
29655
+ }
29656
+
29657
+ if (!estimateGas) {
29658
+ _context27.next = 6;
29659
+ break;
29660
+ }
29661
+
29662
+ _context27.next = 5;
29663
+ return this.managerLogic.estimateGas.setMaxSupplyCap(_maxSupplyCapD18, options);
29664
+
29665
+ case 5:
29666
+ return _context27.abrupt("return", _context27.sent);
29667
+
29668
+ case 6:
29669
+ _context27.next = 8;
29670
+ return this.managerLogic.setMaxSupplyCap(_maxSupplyCapD18, options);
29671
+
29672
+ case 8:
29673
+ tx = _context27.sent;
29674
+ return _context27.abrupt("return", tx);
29675
+
29676
+ case 10:
29677
+ case "end":
29678
+ return _context27.stop();
29679
+ }
29680
+ }
29681
+ }, _callee27, this);
29682
+ }));
29683
+
29684
+ function setMaxCap(_x120, _x121, _x122) {
29685
+ return _setMaxCap.apply(this, arguments);
29686
+ }
29687
+
29688
+ return setMaxCap;
29689
+ }()
29603
29690
  /**
29604
29691
  * Invest into a Balancer pool
29605
29692
  * @param {string} poolId Balancer pool id
@@ -29614,11 +29701,11 @@ var Pool = /*#__PURE__*/function () {
29614
29701
  _proto.joinBalancerPool =
29615
29702
  /*#__PURE__*/
29616
29703
  function () {
29617
- var _joinBalancerPool = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee27(poolId, assets, amountsIn, options, sdkOptions) {
29704
+ var _joinBalancerPool = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee28(poolId, assets, amountsIn, options, sdkOptions) {
29618
29705
  var joinPoolTxData, tx;
29619
- return runtime_1.wrap(function _callee27$(_context27) {
29706
+ return runtime_1.wrap(function _callee28$(_context28) {
29620
29707
  while (1) {
29621
- switch (_context27.prev = _context27.next) {
29708
+ switch (_context28.prev = _context28.next) {
29622
29709
  case 0:
29623
29710
  if (options === void 0) {
29624
29711
  options = null;
@@ -29631,22 +29718,22 @@ var Pool = /*#__PURE__*/function () {
29631
29718
  }
29632
29719
 
29633
29720
  joinPoolTxData = this.utils.getBalancerJoinPoolTx(this, poolId, assets, amountsIn);
29634
- _context27.next = 5;
29721
+ _context28.next = 5;
29635
29722
  return getPoolTxOrGasEstimate(this, [routerAddress[this.network][exports.Dapp.BALANCER], joinPoolTxData, options], sdkOptions);
29636
29723
 
29637
29724
  case 5:
29638
- tx = _context27.sent;
29639
- return _context27.abrupt("return", tx);
29725
+ tx = _context28.sent;
29726
+ return _context28.abrupt("return", tx);
29640
29727
 
29641
29728
  case 7:
29642
29729
  case "end":
29643
- return _context27.stop();
29730
+ return _context28.stop();
29644
29731
  }
29645
29732
  }
29646
- }, _callee27, this);
29733
+ }, _callee28, this);
29647
29734
  }));
29648
29735
 
29649
- function joinBalancerPool(_x120, _x121, _x122, _x123, _x124) {
29736
+ function joinBalancerPool(_x123, _x124, _x125, _x126, _x127) {
29650
29737
  return _joinBalancerPool.apply(this, arguments);
29651
29738
  }
29652
29739
 
@@ -29667,11 +29754,11 @@ var Pool = /*#__PURE__*/function () {
29667
29754
  _proto.exitBalancerPool =
29668
29755
  /*#__PURE__*/
29669
29756
  function () {
29670
- var _exitBalancerPool = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee28(poolId, assets, amount, singleExitAssetIndex, options, sdkOptions) {
29757
+ var _exitBalancerPool = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee29(poolId, assets, amount, singleExitAssetIndex, options, sdkOptions) {
29671
29758
  var exitPoolTxData, tx;
29672
- return runtime_1.wrap(function _callee28$(_context28) {
29759
+ return runtime_1.wrap(function _callee29$(_context29) {
29673
29760
  while (1) {
29674
- switch (_context28.prev = _context28.next) {
29761
+ switch (_context29.prev = _context29.next) {
29675
29762
  case 0:
29676
29763
  if (singleExitAssetIndex === void 0) {
29677
29764
  singleExitAssetIndex = null;
@@ -29688,22 +29775,22 @@ var Pool = /*#__PURE__*/function () {
29688
29775
  }
29689
29776
 
29690
29777
  exitPoolTxData = this.utils.getBalancerExitPoolTx(this, poolId, assets, singleExitAssetIndex, amount);
29691
- _context28.next = 6;
29778
+ _context29.next = 6;
29692
29779
  return getPoolTxOrGasEstimate(this, [routerAddress[this.network][exports.Dapp.BALANCER], exitPoolTxData, options], sdkOptions);
29693
29780
 
29694
29781
  case 6:
29695
- tx = _context28.sent;
29696
- return _context28.abrupt("return", tx);
29782
+ tx = _context29.sent;
29783
+ return _context29.abrupt("return", tx);
29697
29784
 
29698
29785
  case 8:
29699
29786
  case "end":
29700
- return _context28.stop();
29787
+ return _context29.stop();
29701
29788
  }
29702
29789
  }
29703
- }, _callee28, this);
29790
+ }, _callee29, this);
29704
29791
  }));
29705
29792
 
29706
- function exitBalancerPool(_x125, _x126, _x127, _x128, _x129, _x130) {
29793
+ function exitBalancerPool(_x128, _x129, _x130, _x131, _x132, _x133) {
29707
29794
  return _exitBalancerPool.apply(this, arguments);
29708
29795
  }
29709
29796
 
@@ -29721,11 +29808,11 @@ var Pool = /*#__PURE__*/function () {
29721
29808
  _proto.harvestAaveRewards =
29722
29809
  /*#__PURE__*/
29723
29810
  function () {
29724
- var _harvestAaveRewards = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee29(assets, options, sdkOptions) {
29811
+ var _harvestAaveRewards = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee30(assets, options, sdkOptions) {
29725
29812
  var aaveIncentivesAddress, iAaveIncentivesController, aaveIncentivesController, amount, claimTxData, tx;
29726
- return runtime_1.wrap(function _callee29$(_context29) {
29813
+ return runtime_1.wrap(function _callee30$(_context30) {
29727
29814
  while (1) {
29728
- switch (_context29.prev = _context29.next) {
29815
+ switch (_context30.prev = _context30.next) {
29729
29816
  case 0:
29730
29817
  if (options === void 0) {
29731
29818
  options = null;
@@ -29740,28 +29827,28 @@ var Pool = /*#__PURE__*/function () {
29740
29827
  aaveIncentivesAddress = stakingAddress[this.network][exports.Dapp.AAVE];
29741
29828
  iAaveIncentivesController = new ethers.ethers.utils.Interface(IAaveIncentivesController.abi);
29742
29829
  aaveIncentivesController = new ethers.ethers.Contract(aaveIncentivesAddress, iAaveIncentivesController, this.signer);
29743
- _context29.next = 7;
29830
+ _context30.next = 7;
29744
29831
  return aaveIncentivesController.getUserUnclaimedRewards(this.address);
29745
29832
 
29746
29833
  case 7:
29747
- amount = _context29.sent;
29834
+ amount = _context30.sent;
29748
29835
  claimTxData = iAaveIncentivesController.encodeFunctionData(exports.Transaction.CLAIM_REWARDS, [assets, amount, this.address]);
29749
- _context29.next = 11;
29836
+ _context30.next = 11;
29750
29837
  return getPoolTxOrGasEstimate(this, [aaveIncentivesAddress, claimTxData, options], sdkOptions);
29751
29838
 
29752
29839
  case 11:
29753
- tx = _context29.sent;
29754
- return _context29.abrupt("return", tx);
29840
+ tx = _context30.sent;
29841
+ return _context30.abrupt("return", tx);
29755
29842
 
29756
29843
  case 13:
29757
29844
  case "end":
29758
- return _context29.stop();
29845
+ return _context30.stop();
29759
29846
  }
29760
29847
  }
29761
- }, _callee29, this);
29848
+ }, _callee30, this);
29762
29849
  }));
29763
29850
 
29764
- function harvestAaveRewards(_x131, _x132, _x133) {
29851
+ function harvestAaveRewards(_x134, _x135, _x136) {
29765
29852
  return _harvestAaveRewards.apply(this, arguments);
29766
29853
  }
29767
29854
 
@@ -29780,11 +29867,11 @@ var Pool = /*#__PURE__*/function () {
29780
29867
  _proto.harvestAaveV3Rewards =
29781
29868
  /*#__PURE__*/
29782
29869
  function () {
29783
- var _harvestAaveV3Rewards = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee30(assets, rewardAsset, options, sdkOptions) {
29870
+ var _harvestAaveV3Rewards = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee31(assets, rewardAsset, options, sdkOptions) {
29784
29871
  var claimTxData, tx;
29785
- return runtime_1.wrap(function _callee30$(_context30) {
29872
+ return runtime_1.wrap(function _callee31$(_context31) {
29786
29873
  while (1) {
29787
- switch (_context30.prev = _context30.next) {
29874
+ switch (_context31.prev = _context31.next) {
29788
29875
  case 0:
29789
29876
  if (options === void 0) {
29790
29877
  options = null;
@@ -29796,27 +29883,27 @@ var Pool = /*#__PURE__*/function () {
29796
29883
  };
29797
29884
  }
29798
29885
 
29799
- _context30.next = 4;
29886
+ _context31.next = 4;
29800
29887
  return getAaveV3ClaimTxData(this, assets, rewardAsset);
29801
29888
 
29802
29889
  case 4:
29803
- claimTxData = _context30.sent;
29804
- _context30.next = 7;
29890
+ claimTxData = _context31.sent;
29891
+ _context31.next = 7;
29805
29892
  return getPoolTxOrGasEstimate(this, [stakingAddress[this.network][exports.Dapp.AAVEV3], claimTxData, options], sdkOptions);
29806
29893
 
29807
29894
  case 7:
29808
- tx = _context30.sent;
29809
- return _context30.abrupt("return", tx);
29895
+ tx = _context31.sent;
29896
+ return _context31.abrupt("return", tx);
29810
29897
 
29811
29898
  case 9:
29812
29899
  case "end":
29813
- return _context30.stop();
29900
+ return _context31.stop();
29814
29901
  }
29815
29902
  }
29816
- }, _callee30, this);
29903
+ }, _callee31, this);
29817
29904
  }));
29818
29905
 
29819
- function harvestAaveV3Rewards(_x134, _x135, _x136, _x137) {
29906
+ function harvestAaveV3Rewards(_x137, _x138, _x139, _x140) {
29820
29907
  return _harvestAaveV3Rewards.apply(this, arguments);
29821
29908
  }
29822
29909
 
@@ -29834,11 +29921,11 @@ var Pool = /*#__PURE__*/function () {
29834
29921
  _proto.harvestCompoundV3Rewards =
29835
29922
  /*#__PURE__*/
29836
29923
  function () {
29837
- var _harvestCompoundV3Rewards = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee31(asset, options, sdkOptions) {
29924
+ var _harvestCompoundV3Rewards = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee32(asset, options, sdkOptions) {
29838
29925
  var claimTxData, tx;
29839
- return runtime_1.wrap(function _callee31$(_context31) {
29926
+ return runtime_1.wrap(function _callee32$(_context32) {
29840
29927
  while (1) {
29841
- switch (_context31.prev = _context31.next) {
29928
+ switch (_context32.prev = _context32.next) {
29842
29929
  case 0:
29843
29930
  if (options === void 0) {
29844
29931
  options = null;
@@ -29850,27 +29937,27 @@ var Pool = /*#__PURE__*/function () {
29850
29937
  };
29851
29938
  }
29852
29939
 
29853
- _context31.next = 4;
29940
+ _context32.next = 4;
29854
29941
  return getCompoundV3ClaimTxData(this, asset);
29855
29942
 
29856
29943
  case 4:
29857
- claimTxData = _context31.sent;
29858
- _context31.next = 7;
29944
+ claimTxData = _context32.sent;
29945
+ _context32.next = 7;
29859
29946
  return getPoolTxOrGasEstimate(this, [stakingAddress[this.network][exports.Dapp.COMPOUNDV3], claimTxData, options], sdkOptions);
29860
29947
 
29861
29948
  case 7:
29862
- tx = _context31.sent;
29863
- return _context31.abrupt("return", tx);
29949
+ tx = _context32.sent;
29950
+ return _context32.abrupt("return", tx);
29864
29951
 
29865
29952
  case 9:
29866
29953
  case "end":
29867
- return _context31.stop();
29954
+ return _context32.stop();
29868
29955
  }
29869
29956
  }
29870
- }, _callee31, this);
29957
+ }, _callee32, this);
29871
29958
  }));
29872
29959
 
29873
- function harvestCompoundV3Rewards(_x138, _x139, _x140) {
29960
+ function harvestCompoundV3Rewards(_x141, _x142, _x143) {
29874
29961
  return _harvestCompoundV3Rewards.apply(this, arguments);
29875
29962
  }
29876
29963
 
@@ -29897,11 +29984,11 @@ var Pool = /*#__PURE__*/function () {
29897
29984
  _proto.addLiquidityUniswapV3 =
29898
29985
  /*#__PURE__*/
29899
29986
  function () {
29900
- var _addLiquidityUniswapV = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee32(dapp, assetA, assetB, amountA, amountB, minPrice, maxPrice, minTick, maxTick, feeAmountOrTickSpacing, options, sdkOptions) {
29987
+ var _addLiquidityUniswapV = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee33(dapp, assetA, assetB, amountA, amountB, minPrice, maxPrice, minTick, maxTick, feeAmountOrTickSpacing, options, sdkOptions) {
29901
29988
  var mintTxData, tx;
29902
- return runtime_1.wrap(function _callee32$(_context32) {
29989
+ return runtime_1.wrap(function _callee33$(_context33) {
29903
29990
  while (1) {
29904
- switch (_context32.prev = _context32.next) {
29991
+ switch (_context33.prev = _context33.next) {
29905
29992
  case 0:
29906
29993
  if (options === void 0) {
29907
29994
  options = null;
@@ -29914,7 +30001,7 @@ var Pool = /*#__PURE__*/function () {
29914
30001
  }
29915
30002
 
29916
30003
  if (!((minPrice === null || maxPrice === null) && (minTick === null || maxTick === null))) {
29917
- _context32.next = 4;
30004
+ _context33.next = 4;
29918
30005
  break;
29919
30006
  }
29920
30007
 
@@ -29922,34 +30009,34 @@ var Pool = /*#__PURE__*/function () {
29922
30009
 
29923
30010
  case 4:
29924
30011
  if (!((minPrice || maxPrice) && dapp !== exports.Dapp.UNISWAPV3)) {
29925
- _context32.next = 6;
30012
+ _context33.next = 6;
29926
30013
  break;
29927
30014
  }
29928
30015
 
29929
30016
  throw new Error("no price conversion for Aerodrome/Velodrome CL");
29930
30017
 
29931
30018
  case 6:
29932
- _context32.next = 8;
30019
+ _context33.next = 8;
29933
30020
  return getUniswapV3MintTxData(dapp, this, assetA, assetB, amountA, amountB, minPrice, maxPrice, minTick, maxTick, feeAmountOrTickSpacing);
29934
30021
 
29935
30022
  case 8:
29936
- mintTxData = _context32.sent;
29937
- _context32.next = 11;
30023
+ mintTxData = _context33.sent;
30024
+ _context33.next = 11;
29938
30025
  return getPoolTxOrGasEstimate(this, [nonfungiblePositionManagerAddress[this.network][dapp], mintTxData, options], sdkOptions);
29939
30026
 
29940
30027
  case 11:
29941
- tx = _context32.sent;
29942
- return _context32.abrupt("return", tx);
30028
+ tx = _context33.sent;
30029
+ return _context33.abrupt("return", tx);
29943
30030
 
29944
30031
  case 13:
29945
30032
  case "end":
29946
- return _context32.stop();
30033
+ return _context33.stop();
29947
30034
  }
29948
30035
  }
29949
- }, _callee32, this);
30036
+ }, _callee33, this);
29950
30037
  }));
29951
30038
 
29952
- function addLiquidityUniswapV3(_x141, _x142, _x143, _x144, _x145, _x146, _x147, _x148, _x149, _x150, _x151, _x152) {
30039
+ function addLiquidityUniswapV3(_x144, _x145, _x146, _x147, _x148, _x149, _x150, _x151, _x152, _x153, _x154, _x155) {
29953
30040
  return _addLiquidityUniswapV.apply(this, arguments);
29954
30041
  }
29955
30042
 
@@ -29969,11 +30056,11 @@ var Pool = /*#__PURE__*/function () {
29969
30056
  _proto.decreaseLiquidity =
29970
30057
  /*#__PURE__*/
29971
30058
  function () {
29972
- var _decreaseLiquidity = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee33(dapp, tokenId, amount, options, sdkOptions) {
30059
+ var _decreaseLiquidity = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee34(dapp, tokenId, amount, options, sdkOptions) {
29973
30060
  var dappAddress, isStaked, txData, tokenIdOwner, tx;
29974
- return runtime_1.wrap(function _callee33$(_context33) {
30061
+ return runtime_1.wrap(function _callee34$(_context34) {
29975
30062
  while (1) {
29976
- switch (_context33.prev = _context33.next) {
30063
+ switch (_context34.prev = _context34.next) {
29977
30064
  case 0:
29978
30065
  if (amount === void 0) {
29979
30066
  amount = 100;
@@ -29990,20 +30077,20 @@ var Pool = /*#__PURE__*/function () {
29990
30077
  }
29991
30078
 
29992
30079
  isStaked = false;
29993
- _context33.t0 = dapp;
29994
- _context33.next = _context33.t0 === exports.Dapp.UNISWAPV3 ? 7 : _context33.t0 === exports.Dapp.RAMSESCL ? 7 : _context33.t0 === exports.Dapp.VELODROMECL ? 9 : _context33.t0 === exports.Dapp.AERODROMECL ? 9 : _context33.t0 === exports.Dapp.PANCAKECL ? 9 : _context33.t0 === exports.Dapp.ARRAKIS ? 14 : 16;
30080
+ _context34.t0 = dapp;
30081
+ _context34.next = _context34.t0 === exports.Dapp.UNISWAPV3 ? 7 : _context34.t0 === exports.Dapp.RAMSESCL ? 7 : _context34.t0 === exports.Dapp.VELODROMECL ? 9 : _context34.t0 === exports.Dapp.AERODROMECL ? 9 : _context34.t0 === exports.Dapp.PANCAKECL ? 9 : _context34.t0 === exports.Dapp.ARRAKIS ? 14 : 16;
29995
30082
  break;
29996
30083
 
29997
30084
  case 7:
29998
30085
  dappAddress = nonfungiblePositionManagerAddress[this.network][dapp];
29999
- return _context33.abrupt("break", 17);
30086
+ return _context34.abrupt("break", 17);
30000
30087
 
30001
30088
  case 9:
30002
- _context33.next = 11;
30089
+ _context34.next = 11;
30003
30090
  return getClOwner(this, dapp, tokenId);
30004
30091
 
30005
30092
  case 11:
30006
- tokenIdOwner = _context33.sent;
30093
+ tokenIdOwner = _context34.sent;
30007
30094
 
30008
30095
  if (tokenIdOwner.toLowerCase() === this.address.toLowerCase()) {
30009
30096
  dappAddress = nonfungiblePositionManagerAddress[this.network][dapp];
@@ -30013,49 +30100,49 @@ var Pool = /*#__PURE__*/function () {
30013
30100
  isStaked = true;
30014
30101
  }
30015
30102
 
30016
- return _context33.abrupt("break", 17);
30103
+ return _context34.abrupt("break", 17);
30017
30104
 
30018
30105
  case 14:
30019
30106
  dappAddress = routerAddress[this.network][dapp];
30020
- return _context33.abrupt("break", 17);
30107
+ return _context34.abrupt("break", 17);
30021
30108
 
30022
30109
  case 16:
30023
30110
  throw new Error("dapp not supported");
30024
30111
 
30025
30112
  case 17:
30026
30113
  if (!(!isStaked || dapp === exports.Dapp.PANCAKECL)) {
30027
- _context33.next = 23;
30114
+ _context34.next = 23;
30028
30115
  break;
30029
30116
  }
30030
30117
 
30031
- _context33.next = 20;
30118
+ _context34.next = 20;
30032
30119
  return getDecreaseLiquidityTxData(this, dapp, tokenId, amount, isStaked);
30033
30120
 
30034
30121
  case 20:
30035
- txData = _context33.sent;
30036
- _context33.next = 24;
30122
+ txData = _context34.sent;
30123
+ _context34.next = 24;
30037
30124
  break;
30038
30125
 
30039
30126
  case 23:
30040
30127
  throw new Error("unsupported decreaseStakedLiquidity: unstake first to decrease lp");
30041
30128
 
30042
30129
  case 24:
30043
- _context33.next = 26;
30130
+ _context34.next = 26;
30044
30131
  return getPoolTxOrGasEstimate(this, [dappAddress, txData, options], sdkOptions);
30045
30132
 
30046
30133
  case 26:
30047
- tx = _context33.sent;
30048
- return _context33.abrupt("return", tx);
30134
+ tx = _context34.sent;
30135
+ return _context34.abrupt("return", tx);
30049
30136
 
30050
30137
  case 28:
30051
30138
  case "end":
30052
- return _context33.stop();
30139
+ return _context34.stop();
30053
30140
  }
30054
30141
  }
30055
- }, _callee33, this);
30142
+ }, _callee34, this);
30056
30143
  }));
30057
30144
 
30058
- function decreaseLiquidity(_x153, _x154, _x155, _x156, _x157) {
30145
+ function decreaseLiquidity(_x156, _x157, _x158, _x159, _x160) {
30059
30146
  return _decreaseLiquidity.apply(this, arguments);
30060
30147
  }
30061
30148
 
@@ -30076,11 +30163,11 @@ var Pool = /*#__PURE__*/function () {
30076
30163
  _proto.increaseLiquidity =
30077
30164
  /*#__PURE__*/
30078
30165
  function () {
30079
- var _increaseLiquidity = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee34(dapp, tokenId, amountA, amountB, options, sdkOptions) {
30166
+ var _increaseLiquidity = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee35(dapp, tokenId, amountA, amountB, options, sdkOptions) {
30080
30167
  var dappAddress, isStaked, txData, tokenIdOwner, tx;
30081
- return runtime_1.wrap(function _callee34$(_context34) {
30168
+ return runtime_1.wrap(function _callee35$(_context35) {
30082
30169
  while (1) {
30083
- switch (_context34.prev = _context34.next) {
30170
+ switch (_context35.prev = _context35.next) {
30084
30171
  case 0:
30085
30172
  if (options === void 0) {
30086
30173
  options = null;
@@ -30093,20 +30180,20 @@ var Pool = /*#__PURE__*/function () {
30093
30180
  }
30094
30181
 
30095
30182
  isStaked = false;
30096
- _context34.t0 = dapp;
30097
- _context34.next = _context34.t0 === exports.Dapp.UNISWAPV3 ? 6 : _context34.t0 === exports.Dapp.RAMSESCL ? 6 : _context34.t0 === exports.Dapp.VELODROMECL ? 8 : _context34.t0 === exports.Dapp.AERODROMECL ? 8 : _context34.t0 === exports.Dapp.PANCAKECL ? 8 : _context34.t0 === exports.Dapp.ARRAKIS ? 13 : 15;
30183
+ _context35.t0 = dapp;
30184
+ _context35.next = _context35.t0 === exports.Dapp.UNISWAPV3 ? 6 : _context35.t0 === exports.Dapp.RAMSESCL ? 6 : _context35.t0 === exports.Dapp.VELODROMECL ? 8 : _context35.t0 === exports.Dapp.AERODROMECL ? 8 : _context35.t0 === exports.Dapp.PANCAKECL ? 8 : _context35.t0 === exports.Dapp.ARRAKIS ? 13 : 15;
30098
30185
  break;
30099
30186
 
30100
30187
  case 6:
30101
30188
  dappAddress = nonfungiblePositionManagerAddress[this.network][dapp];
30102
- return _context34.abrupt("break", 16);
30189
+ return _context35.abrupt("break", 16);
30103
30190
 
30104
30191
  case 8:
30105
- _context34.next = 10;
30192
+ _context35.next = 10;
30106
30193
  return getClOwner(this, dapp, tokenId);
30107
30194
 
30108
30195
  case 10:
30109
- tokenIdOwner = _context34.sent;
30196
+ tokenIdOwner = _context35.sent;
30110
30197
 
30111
30198
  if (tokenIdOwner.toLowerCase() === this.address.toLowerCase()) {
30112
30199
  dappAddress = nonfungiblePositionManagerAddress[this.network][dapp];
@@ -30116,49 +30203,49 @@ var Pool = /*#__PURE__*/function () {
30116
30203
  isStaked = true;
30117
30204
  }
30118
30205
 
30119
- return _context34.abrupt("break", 16);
30206
+ return _context35.abrupt("break", 16);
30120
30207
 
30121
30208
  case 13:
30122
30209
  dappAddress = routerAddress[this.network][dapp];
30123
- return _context34.abrupt("break", 16);
30210
+ return _context35.abrupt("break", 16);
30124
30211
 
30125
30212
  case 15:
30126
30213
  throw new Error("dapp not supported");
30127
30214
 
30128
30215
  case 16:
30129
30216
  if (!(!isStaked || dapp === exports.Dapp.PANCAKECL)) {
30130
- _context34.next = 22;
30217
+ _context35.next = 22;
30131
30218
  break;
30132
30219
  }
30133
30220
 
30134
- _context34.next = 19;
30221
+ _context35.next = 19;
30135
30222
  return getIncreaseLiquidityTxData(this, dapp, tokenId, amountA, amountB);
30136
30223
 
30137
30224
  case 19:
30138
- txData = _context34.sent;
30139
- _context34.next = 23;
30225
+ txData = _context35.sent;
30226
+ _context35.next = 23;
30140
30227
  break;
30141
30228
 
30142
30229
  case 22:
30143
30230
  throw new Error("unsupported increaseStakedLiquidity: unstake first to increase lp");
30144
30231
 
30145
30232
  case 23:
30146
- _context34.next = 25;
30233
+ _context35.next = 25;
30147
30234
  return getPoolTxOrGasEstimate(this, [dappAddress, txData, options], sdkOptions);
30148
30235
 
30149
30236
  case 25:
30150
- tx = _context34.sent;
30151
- return _context34.abrupt("return", tx);
30237
+ tx = _context35.sent;
30238
+ return _context35.abrupt("return", tx);
30152
30239
 
30153
30240
  case 27:
30154
30241
  case "end":
30155
- return _context34.stop();
30242
+ return _context35.stop();
30156
30243
  }
30157
30244
  }
30158
- }, _callee34, this);
30245
+ }, _callee35, this);
30159
30246
  }));
30160
30247
 
30161
- function increaseLiquidity(_x158, _x159, _x160, _x161, _x162, _x163) {
30248
+ function increaseLiquidity(_x161, _x162, _x163, _x164, _x165, _x166) {
30162
30249
  return _increaseLiquidity.apply(this, arguments);
30163
30250
  }
30164
30251
 
@@ -30177,11 +30264,11 @@ var Pool = /*#__PURE__*/function () {
30177
30264
  _proto.claimFees =
30178
30265
  /*#__PURE__*/
30179
30266
  function () {
30180
- var _claimFees = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee35(dapp, tokenId, options, sdkOptions) {
30267
+ var _claimFees = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee36(dapp, tokenId, options, sdkOptions) {
30181
30268
  var txData, contractAddress, iNonfungiblePositionManager, abi, tokenIdOwner, tx;
30182
- return runtime_1.wrap(function _callee35$(_context35) {
30269
+ return runtime_1.wrap(function _callee36$(_context36) {
30183
30270
  while (1) {
30184
- switch (_context35.prev = _context35.next) {
30271
+ switch (_context36.prev = _context36.next) {
30185
30272
  case 0:
30186
30273
  if (options === void 0) {
30187
30274
  options = null;
@@ -30194,37 +30281,37 @@ var Pool = /*#__PURE__*/function () {
30194
30281
  }
30195
30282
 
30196
30283
  iNonfungiblePositionManager = new ethers.ethers.utils.Interface(INonfungiblePositionManager.abi);
30197
- _context35.t0 = dapp;
30198
- _context35.next = _context35.t0 === exports.Dapp.UNISWAPV3 ? 6 : _context35.t0 === exports.Dapp.RAMSESCL ? 6 : _context35.t0 === exports.Dapp.ARRAKIS ? 9 : _context35.t0 === exports.Dapp.BALANCER ? 9 : _context35.t0 === exports.Dapp.VELODROME ? 13 : _context35.t0 === exports.Dapp.RAMSES ? 13 : _context35.t0 === exports.Dapp.VELODROMEV2 ? 16 : _context35.t0 === exports.Dapp.AERODROME ? 16 : _context35.t0 === exports.Dapp.VELODROMECL ? 19 : _context35.t0 === exports.Dapp.AERODROMECL ? 19 : _context35.t0 === exports.Dapp.PANCAKECL ? 19 : 24;
30284
+ _context36.t0 = dapp;
30285
+ _context36.next = _context36.t0 === exports.Dapp.UNISWAPV3 ? 6 : _context36.t0 === exports.Dapp.RAMSESCL ? 6 : _context36.t0 === exports.Dapp.ARRAKIS ? 9 : _context36.t0 === exports.Dapp.BALANCER ? 9 : _context36.t0 === exports.Dapp.VELODROME ? 13 : _context36.t0 === exports.Dapp.RAMSES ? 13 : _context36.t0 === exports.Dapp.VELODROMEV2 ? 16 : _context36.t0 === exports.Dapp.AERODROME ? 16 : _context36.t0 === exports.Dapp.VELODROMECL ? 19 : _context36.t0 === exports.Dapp.AERODROMECL ? 19 : _context36.t0 === exports.Dapp.PANCAKECL ? 19 : 24;
30199
30286
  break;
30200
30287
 
30201
30288
  case 6:
30202
30289
  contractAddress = nonfungiblePositionManagerAddress[this.network][dapp];
30203
30290
  txData = iNonfungiblePositionManager.encodeFunctionData(exports.Transaction.COLLECT, [[tokenId, this.address, MaxUint128, MaxUint128]]);
30204
- return _context35.abrupt("break", 25);
30291
+ return _context36.abrupt("break", 25);
30205
30292
 
30206
30293
  case 9:
30207
30294
  contractAddress = tokenId;
30208
30295
  abi = new ethers.ethers.utils.Interface(ILiquidityGaugeV4.abi);
30209
30296
  txData = abi.encodeFunctionData("claim_rewards()", []);
30210
- return _context35.abrupt("break", 25);
30297
+ return _context36.abrupt("break", 25);
30211
30298
 
30212
30299
  case 13:
30213
30300
  contractAddress = tokenId;
30214
30301
  txData = getVelodromeClaimTxData(this, tokenId, false);
30215
- return _context35.abrupt("break", 25);
30302
+ return _context36.abrupt("break", 25);
30216
30303
 
30217
30304
  case 16:
30218
30305
  contractAddress = tokenId;
30219
30306
  txData = getVelodromeClaimTxData(this, tokenId, true);
30220
- return _context35.abrupt("break", 25);
30307
+ return _context36.abrupt("break", 25);
30221
30308
 
30222
30309
  case 19:
30223
- _context35.next = 21;
30310
+ _context36.next = 21;
30224
30311
  return getClOwner(this, dapp, tokenId);
30225
30312
 
30226
30313
  case 21:
30227
- tokenIdOwner = _context35.sent;
30314
+ tokenIdOwner = _context36.sent;
30228
30315
 
30229
30316
  if (tokenIdOwner.toLowerCase() === this.address.toLowerCase()) {
30230
30317
  contractAddress = nonfungiblePositionManagerAddress[this.network][dapp];
@@ -30240,28 +30327,28 @@ var Pool = /*#__PURE__*/function () {
30240
30327
  }
30241
30328
  }
30242
30329
 
30243
- return _context35.abrupt("break", 25);
30330
+ return _context36.abrupt("break", 25);
30244
30331
 
30245
30332
  case 24:
30246
30333
  throw new Error("dapp not supported");
30247
30334
 
30248
30335
  case 25:
30249
- _context35.next = 27;
30336
+ _context36.next = 27;
30250
30337
  return getPoolTxOrGasEstimate(this, [contractAddress, txData, options], sdkOptions);
30251
30338
 
30252
30339
  case 27:
30253
- tx = _context35.sent;
30254
- return _context35.abrupt("return", tx);
30340
+ tx = _context36.sent;
30341
+ return _context36.abrupt("return", tx);
30255
30342
 
30256
30343
  case 29:
30257
30344
  case "end":
30258
- return _context35.stop();
30345
+ return _context36.stop();
30259
30346
  }
30260
30347
  }
30261
- }, _callee35, this);
30348
+ }, _callee36, this);
30262
30349
  }));
30263
30350
 
30264
- function claimFees(_x164, _x165, _x166, _x167) {
30351
+ function claimFees(_x167, _x168, _x169, _x170) {
30265
30352
  return _claimFees.apply(this, arguments);
30266
30353
  }
30267
30354
 
@@ -30281,11 +30368,11 @@ var Pool = /*#__PURE__*/function () {
30281
30368
  _proto.getRewards =
30282
30369
  /*#__PURE__*/
30283
30370
  function () {
30284
- var _getRewards = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee36(dapp, tokenId, rewards, options, sdkOptions) {
30371
+ var _getRewards = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee37(dapp, tokenId, rewards, options, sdkOptions) {
30285
30372
  var tx;
30286
- return runtime_1.wrap(function _callee36$(_context36) {
30373
+ return runtime_1.wrap(function _callee37$(_context37) {
30287
30374
  while (1) {
30288
- switch (_context36.prev = _context36.next) {
30375
+ switch (_context37.prev = _context37.next) {
30289
30376
  case 0:
30290
30377
  if (options === void 0) {
30291
30378
  options = null;
@@ -30297,22 +30384,22 @@ var Pool = /*#__PURE__*/function () {
30297
30384
  };
30298
30385
  }
30299
30386
 
30300
- _context36.next = 4;
30387
+ _context37.next = 4;
30301
30388
  return getPoolTxOrGasEstimate(this, [nonfungiblePositionManagerAddress[this.network][dapp], getRewardsTxDta(tokenId, rewards), options], sdkOptions);
30302
30389
 
30303
30390
  case 4:
30304
- tx = _context36.sent;
30305
- return _context36.abrupt("return", tx);
30391
+ tx = _context37.sent;
30392
+ return _context37.abrupt("return", tx);
30306
30393
 
30307
30394
  case 6:
30308
30395
  case "end":
30309
- return _context36.stop();
30396
+ return _context37.stop();
30310
30397
  }
30311
30398
  }
30312
- }, _callee36, this);
30399
+ }, _callee37, this);
30313
30400
  }));
30314
30401
 
30315
- function getRewards(_x168, _x169, _x170, _x171, _x172) {
30402
+ function getRewards(_x171, _x172, _x173, _x174, _x175) {
30316
30403
  return _getRewards.apply(this, arguments);
30317
30404
  }
30318
30405
 
@@ -30335,11 +30422,11 @@ var Pool = /*#__PURE__*/function () {
30335
30422
  _proto.tradeUniswapV3 =
30336
30423
  /*#__PURE__*/
30337
30424
  function () {
30338
- var _tradeUniswapV = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee37(assetFrom, assetTo, amountIn, feeAmount, slippage, options, sdkOptions) {
30425
+ var _tradeUniswapV = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee38(assetFrom, assetTo, amountIn, feeAmount, slippage, options, sdkOptions) {
30339
30426
  var swapxData, tx;
30340
- return runtime_1.wrap(function _callee37$(_context37) {
30427
+ return runtime_1.wrap(function _callee38$(_context38) {
30341
30428
  while (1) {
30342
- switch (_context37.prev = _context37.next) {
30429
+ switch (_context38.prev = _context38.next) {
30343
30430
  case 0:
30344
30431
  if (slippage === void 0) {
30345
30432
  slippage = 0.5;
@@ -30355,27 +30442,27 @@ var Pool = /*#__PURE__*/function () {
30355
30442
  };
30356
30443
  }
30357
30444
 
30358
- _context37.next = 5;
30445
+ _context38.next = 5;
30359
30446
  return getUniswapV3SwapTxData(this, assetFrom, assetTo, amountIn, slippage, feeAmount);
30360
30447
 
30361
30448
  case 5:
30362
- swapxData = _context37.sent;
30363
- _context37.next = 8;
30449
+ swapxData = _context38.sent;
30450
+ _context38.next = 8;
30364
30451
  return getPoolTxOrGasEstimate(this, [routerAddress[this.network][exports.Dapp.UNISWAPV3], swapxData, options], sdkOptions);
30365
30452
 
30366
30453
  case 8:
30367
- tx = _context37.sent;
30368
- return _context37.abrupt("return", tx);
30454
+ tx = _context38.sent;
30455
+ return _context38.abrupt("return", tx);
30369
30456
 
30370
30457
  case 10:
30371
30458
  case "end":
30372
- return _context37.stop();
30459
+ return _context38.stop();
30373
30460
  }
30374
30461
  }
30375
- }, _callee37, this);
30462
+ }, _callee38, this);
30376
30463
  }));
30377
30464
 
30378
- function tradeUniswapV3(_x173, _x174, _x175, _x176, _x177, _x178, _x179) {
30465
+ function tradeUniswapV3(_x176, _x177, _x178, _x179, _x180, _x181, _x182) {
30379
30466
  return _tradeUniswapV.apply(this, arguments);
30380
30467
  }
30381
30468
 
@@ -30397,11 +30484,11 @@ var Pool = /*#__PURE__*/function () {
30397
30484
  _proto.addLiquidityVelodrome =
30398
30485
  /*#__PURE__*/
30399
30486
  function () {
30400
- var _addLiquidityVelodrome = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee38(assetA, assetB, amountA, amountB, isStable, options, sdkOptions) {
30487
+ var _addLiquidityVelodrome = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee39(assetA, assetB, amountA, amountB, isStable, options, sdkOptions) {
30401
30488
  var tx;
30402
- return runtime_1.wrap(function _callee38$(_context38) {
30489
+ return runtime_1.wrap(function _callee39$(_context39) {
30403
30490
  while (1) {
30404
- switch (_context38.prev = _context38.next) {
30491
+ switch (_context39.prev = _context39.next) {
30405
30492
  case 0:
30406
30493
  if (options === void 0) {
30407
30494
  options = null;
@@ -30413,33 +30500,33 @@ var Pool = /*#__PURE__*/function () {
30413
30500
  };
30414
30501
  }
30415
30502
 
30416
- _context38.t0 = getPoolTxOrGasEstimate;
30417
- _context38.t1 = this;
30418
- _context38.t2 = routerAddress[this.network][exports.Dapp.VELODROME];
30419
- _context38.next = 7;
30503
+ _context39.t0 = getPoolTxOrGasEstimate;
30504
+ _context39.t1 = this;
30505
+ _context39.t2 = routerAddress[this.network][exports.Dapp.VELODROME];
30506
+ _context39.next = 7;
30420
30507
  return getVelodromeAddLiquidityTxData(this, assetA, assetB, amountA, amountB, isStable);
30421
30508
 
30422
30509
  case 7:
30423
- _context38.t3 = _context38.sent;
30424
- _context38.t4 = options;
30425
- _context38.t5 = [_context38.t2, _context38.t3, _context38.t4];
30426
- _context38.t6 = sdkOptions;
30427
- _context38.next = 13;
30428
- return (0, _context38.t0)(_context38.t1, _context38.t5, _context38.t6);
30510
+ _context39.t3 = _context39.sent;
30511
+ _context39.t4 = options;
30512
+ _context39.t5 = [_context39.t2, _context39.t3, _context39.t4];
30513
+ _context39.t6 = sdkOptions;
30514
+ _context39.next = 13;
30515
+ return (0, _context39.t0)(_context39.t1, _context39.t5, _context39.t6);
30429
30516
 
30430
30517
  case 13:
30431
- tx = _context38.sent;
30432
- return _context38.abrupt("return", tx);
30518
+ tx = _context39.sent;
30519
+ return _context39.abrupt("return", tx);
30433
30520
 
30434
30521
  case 15:
30435
30522
  case "end":
30436
- return _context38.stop();
30523
+ return _context39.stop();
30437
30524
  }
30438
30525
  }
30439
- }, _callee38, this);
30526
+ }, _callee39, this);
30440
30527
  }));
30441
30528
 
30442
- function addLiquidityVelodrome(_x180, _x181, _x182, _x183, _x184, _x185, _x186) {
30529
+ function addLiquidityVelodrome(_x183, _x184, _x185, _x186, _x187, _x188, _x189) {
30443
30530
  return _addLiquidityVelodrome.apply(this, arguments);
30444
30531
  }
30445
30532
 
@@ -30460,11 +30547,11 @@ var Pool = /*#__PURE__*/function () {
30460
30547
  _proto.removeLiquidityVelodrome =
30461
30548
  /*#__PURE__*/
30462
30549
  function () {
30463
- var _removeLiquidityVelodrome = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee39(assetA, assetB, amount, isStable, options, sdkOptions) {
30550
+ var _removeLiquidityVelodrome = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee40(assetA, assetB, amount, isStable, options, sdkOptions) {
30464
30551
  var tx;
30465
- return runtime_1.wrap(function _callee39$(_context39) {
30552
+ return runtime_1.wrap(function _callee40$(_context40) {
30466
30553
  while (1) {
30467
- switch (_context39.prev = _context39.next) {
30554
+ switch (_context40.prev = _context40.next) {
30468
30555
  case 0:
30469
30556
  if (options === void 0) {
30470
30557
  options = null;
@@ -30476,33 +30563,33 @@ var Pool = /*#__PURE__*/function () {
30476
30563
  };
30477
30564
  }
30478
30565
 
30479
- _context39.t0 = getPoolTxOrGasEstimate;
30480
- _context39.t1 = this;
30481
- _context39.t2 = routerAddress[this.network][exports.Dapp.VELODROME];
30482
- _context39.next = 7;
30483
- return getVelodromeRemoveLiquidityTxData(this, assetA, assetB, amount, isStable);
30566
+ _context40.t0 = getPoolTxOrGasEstimate;
30567
+ _context40.t1 = this;
30568
+ _context40.t2 = routerAddress[this.network][exports.Dapp.VELODROME];
30569
+ _context40.next = 7;
30570
+ return getVelodromeRemoveLiquidityTxData(this, assetA, assetB, amount, isStable);
30484
30571
 
30485
30572
  case 7:
30486
- _context39.t3 = _context39.sent;
30487
- _context39.t4 = options;
30488
- _context39.t5 = [_context39.t2, _context39.t3, _context39.t4];
30489
- _context39.t6 = sdkOptions;
30490
- _context39.next = 13;
30491
- return (0, _context39.t0)(_context39.t1, _context39.t5, _context39.t6);
30573
+ _context40.t3 = _context40.sent;
30574
+ _context40.t4 = options;
30575
+ _context40.t5 = [_context40.t2, _context40.t3, _context40.t4];
30576
+ _context40.t6 = sdkOptions;
30577
+ _context40.next = 13;
30578
+ return (0, _context40.t0)(_context40.t1, _context40.t5, _context40.t6);
30492
30579
 
30493
30580
  case 13:
30494
- tx = _context39.sent;
30495
- return _context39.abrupt("return", tx);
30581
+ tx = _context40.sent;
30582
+ return _context40.abrupt("return", tx);
30496
30583
 
30497
30584
  case 15:
30498
30585
  case "end":
30499
- return _context39.stop();
30586
+ return _context40.stop();
30500
30587
  }
30501
30588
  }
30502
- }, _callee39, this);
30589
+ }, _callee40, this);
30503
30590
  }));
30504
30591
 
30505
- function removeLiquidityVelodrome(_x187, _x188, _x189, _x190, _x191, _x192) {
30592
+ function removeLiquidityVelodrome(_x190, _x191, _x192, _x193, _x194, _x195) {
30506
30593
  return _removeLiquidityVelodrome.apply(this, arguments);
30507
30594
  }
30508
30595
 
@@ -30524,11 +30611,11 @@ var Pool = /*#__PURE__*/function () {
30524
30611
  _proto.addLiquidityVelodromeV2 =
30525
30612
  /*#__PURE__*/
30526
30613
  function () {
30527
- var _addLiquidityVelodromeV = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee40(assetA, assetB, amountA, amountB, isStable, options, sdkOptions) {
30614
+ var _addLiquidityVelodromeV = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee41(assetA, assetB, amountA, amountB, isStable, options, sdkOptions) {
30528
30615
  var tx;
30529
- return runtime_1.wrap(function _callee40$(_context40) {
30616
+ return runtime_1.wrap(function _callee41$(_context41) {
30530
30617
  while (1) {
30531
- switch (_context40.prev = _context40.next) {
30618
+ switch (_context41.prev = _context41.next) {
30532
30619
  case 0:
30533
30620
  if (options === void 0) {
30534
30621
  options = null;
@@ -30540,33 +30627,33 @@ var Pool = /*#__PURE__*/function () {
30540
30627
  };
30541
30628
  }
30542
30629
 
30543
- _context40.t0 = getPoolTxOrGasEstimate;
30544
- _context40.t1 = this;
30545
- _context40.t2 = routerAddress[this.network][exports.Dapp.VELODROMEV2];
30546
- _context40.next = 7;
30630
+ _context41.t0 = getPoolTxOrGasEstimate;
30631
+ _context41.t1 = this;
30632
+ _context41.t2 = routerAddress[this.network][exports.Dapp.VELODROMEV2];
30633
+ _context41.next = 7;
30547
30634
  return getVelodromeAddLiquidityTxData(this, assetA, assetB, amountA, amountB, isStable);
30548
30635
 
30549
30636
  case 7:
30550
- _context40.t3 = _context40.sent;
30551
- _context40.t4 = options;
30552
- _context40.t5 = [_context40.t2, _context40.t3, _context40.t4];
30553
- _context40.t6 = sdkOptions;
30554
- _context40.next = 13;
30555
- return (0, _context40.t0)(_context40.t1, _context40.t5, _context40.t6);
30637
+ _context41.t3 = _context41.sent;
30638
+ _context41.t4 = options;
30639
+ _context41.t5 = [_context41.t2, _context41.t3, _context41.t4];
30640
+ _context41.t6 = sdkOptions;
30641
+ _context41.next = 13;
30642
+ return (0, _context41.t0)(_context41.t1, _context41.t5, _context41.t6);
30556
30643
 
30557
30644
  case 13:
30558
- tx = _context40.sent;
30559
- return _context40.abrupt("return", tx);
30645
+ tx = _context41.sent;
30646
+ return _context41.abrupt("return", tx);
30560
30647
 
30561
30648
  case 15:
30562
30649
  case "end":
30563
- return _context40.stop();
30650
+ return _context41.stop();
30564
30651
  }
30565
30652
  }
30566
- }, _callee40, this);
30653
+ }, _callee41, this);
30567
30654
  }));
30568
30655
 
30569
- function addLiquidityVelodromeV2(_x193, _x194, _x195, _x196, _x197, _x198, _x199) {
30656
+ function addLiquidityVelodromeV2(_x196, _x197, _x198, _x199, _x200, _x201, _x202) {
30570
30657
  return _addLiquidityVelodromeV.apply(this, arguments);
30571
30658
  }
30572
30659
 
@@ -30587,11 +30674,11 @@ var Pool = /*#__PURE__*/function () {
30587
30674
  _proto.removeLiquidityVelodromeV2 =
30588
30675
  /*#__PURE__*/
30589
30676
  function () {
30590
- var _removeLiquidityVelodromeV = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee41(assetA, assetB, amount, isStable, options, sdkOptions) {
30677
+ var _removeLiquidityVelodromeV = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee42(assetA, assetB, amount, isStable, options, sdkOptions) {
30591
30678
  var tx;
30592
- return runtime_1.wrap(function _callee41$(_context41) {
30679
+ return runtime_1.wrap(function _callee42$(_context42) {
30593
30680
  while (1) {
30594
- switch (_context41.prev = _context41.next) {
30681
+ switch (_context42.prev = _context42.next) {
30595
30682
  case 0:
30596
30683
  if (options === void 0) {
30597
30684
  options = null;
@@ -30603,33 +30690,33 @@ var Pool = /*#__PURE__*/function () {
30603
30690
  };
30604
30691
  }
30605
30692
 
30606
- _context41.t0 = getPoolTxOrGasEstimate;
30607
- _context41.t1 = this;
30608
- _context41.t2 = routerAddress[this.network][exports.Dapp.VELODROMEV2];
30609
- _context41.next = 7;
30693
+ _context42.t0 = getPoolTxOrGasEstimate;
30694
+ _context42.t1 = this;
30695
+ _context42.t2 = routerAddress[this.network][exports.Dapp.VELODROMEV2];
30696
+ _context42.next = 7;
30610
30697
  return getVelodromeRemoveLiquidityTxData(this, assetA, assetB, amount, isStable);
30611
30698
 
30612
30699
  case 7:
30613
- _context41.t3 = _context41.sent;
30614
- _context41.t4 = options;
30615
- _context41.t5 = [_context41.t2, _context41.t3, _context41.t4];
30616
- _context41.t6 = sdkOptions;
30617
- _context41.next = 13;
30618
- return (0, _context41.t0)(_context41.t1, _context41.t5, _context41.t6);
30700
+ _context42.t3 = _context42.sent;
30701
+ _context42.t4 = options;
30702
+ _context42.t5 = [_context42.t2, _context42.t3, _context42.t4];
30703
+ _context42.t6 = sdkOptions;
30704
+ _context42.next = 13;
30705
+ return (0, _context42.t0)(_context42.t1, _context42.t5, _context42.t6);
30619
30706
 
30620
30707
  case 13:
30621
- tx = _context41.sent;
30622
- return _context41.abrupt("return", tx);
30708
+ tx = _context42.sent;
30709
+ return _context42.abrupt("return", tx);
30623
30710
 
30624
30711
  case 15:
30625
30712
  case "end":
30626
- return _context41.stop();
30713
+ return _context42.stop();
30627
30714
  }
30628
30715
  }
30629
- }, _callee41, this);
30716
+ }, _callee42, this);
30630
30717
  }));
30631
30718
 
30632
- function removeLiquidityVelodromeV2(_x200, _x201, _x202, _x203, _x204, _x205) {
30719
+ function removeLiquidityVelodromeV2(_x203, _x204, _x205, _x206, _x207, _x208) {
30633
30720
  return _removeLiquidityVelodromeV.apply(this, arguments);
30634
30721
  }
30635
30722
 
@@ -30652,11 +30739,11 @@ var Pool = /*#__PURE__*/function () {
30652
30739
  _proto.addLiquidityV2 =
30653
30740
  /*#__PURE__*/
30654
30741
  function () {
30655
- var _addLiquidityV = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee42(dapp, assetA, assetB, amountA, amountB, isStable, options, sdkOptions) {
30742
+ var _addLiquidityV = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee43(dapp, assetA, assetB, amountA, amountB, isStable, options, sdkOptions) {
30656
30743
  var tx;
30657
- return runtime_1.wrap(function _callee42$(_context42) {
30744
+ return runtime_1.wrap(function _callee43$(_context43) {
30658
30745
  while (1) {
30659
- switch (_context42.prev = _context42.next) {
30746
+ switch (_context43.prev = _context43.next) {
30660
30747
  case 0:
30661
30748
  if (options === void 0) {
30662
30749
  options = null;
@@ -30668,33 +30755,33 @@ var Pool = /*#__PURE__*/function () {
30668
30755
  };
30669
30756
  }
30670
30757
 
30671
- _context42.t0 = getPoolTxOrGasEstimate;
30672
- _context42.t1 = this;
30673
- _context42.t2 = routerAddress[this.network][dapp];
30674
- _context42.next = 7;
30758
+ _context43.t0 = getPoolTxOrGasEstimate;
30759
+ _context43.t1 = this;
30760
+ _context43.t2 = routerAddress[this.network][dapp];
30761
+ _context43.next = 7;
30675
30762
  return getVelodromeAddLiquidityTxData(this, assetA, assetB, amountA, amountB, isStable);
30676
30763
 
30677
30764
  case 7:
30678
- _context42.t3 = _context42.sent;
30679
- _context42.t4 = options;
30680
- _context42.t5 = [_context42.t2, _context42.t3, _context42.t4];
30681
- _context42.t6 = sdkOptions;
30682
- _context42.next = 13;
30683
- return (0, _context42.t0)(_context42.t1, _context42.t5, _context42.t6);
30765
+ _context43.t3 = _context43.sent;
30766
+ _context43.t4 = options;
30767
+ _context43.t5 = [_context43.t2, _context43.t3, _context43.t4];
30768
+ _context43.t6 = sdkOptions;
30769
+ _context43.next = 13;
30770
+ return (0, _context43.t0)(_context43.t1, _context43.t5, _context43.t6);
30684
30771
 
30685
30772
  case 13:
30686
- tx = _context42.sent;
30687
- return _context42.abrupt("return", tx);
30773
+ tx = _context43.sent;
30774
+ return _context43.abrupt("return", tx);
30688
30775
 
30689
30776
  case 15:
30690
30777
  case "end":
30691
- return _context42.stop();
30778
+ return _context43.stop();
30692
30779
  }
30693
30780
  }
30694
- }, _callee42, this);
30781
+ }, _callee43, this);
30695
30782
  }));
30696
30783
 
30697
- function addLiquidityV2(_x206, _x207, _x208, _x209, _x210, _x211, _x212, _x213) {
30784
+ function addLiquidityV2(_x209, _x210, _x211, _x212, _x213, _x214, _x215, _x216) {
30698
30785
  return _addLiquidityV.apply(this, arguments);
30699
30786
  }
30700
30787
 
@@ -30716,11 +30803,11 @@ var Pool = /*#__PURE__*/function () {
30716
30803
  _proto.removeLiquidityV2 =
30717
30804
  /*#__PURE__*/
30718
30805
  function () {
30719
- var _removeLiquidityV = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee43(dapp, assetA, assetB, amount, isStable, options, sdkOptions) {
30806
+ var _removeLiquidityV = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee44(dapp, assetA, assetB, amount, isStable, options, sdkOptions) {
30720
30807
  var tx;
30721
- return runtime_1.wrap(function _callee43$(_context43) {
30808
+ return runtime_1.wrap(function _callee44$(_context44) {
30722
30809
  while (1) {
30723
- switch (_context43.prev = _context43.next) {
30810
+ switch (_context44.prev = _context44.next) {
30724
30811
  case 0:
30725
30812
  if (options === void 0) {
30726
30813
  options = null;
@@ -30732,33 +30819,33 @@ var Pool = /*#__PURE__*/function () {
30732
30819
  };
30733
30820
  }
30734
30821
 
30735
- _context43.t0 = getPoolTxOrGasEstimate;
30736
- _context43.t1 = this;
30737
- _context43.t2 = routerAddress[this.network][dapp];
30738
- _context43.next = 7;
30822
+ _context44.t0 = getPoolTxOrGasEstimate;
30823
+ _context44.t1 = this;
30824
+ _context44.t2 = routerAddress[this.network][dapp];
30825
+ _context44.next = 7;
30739
30826
  return getVelodromeRemoveLiquidityTxData(this, assetA, assetB, amount, isStable);
30740
30827
 
30741
30828
  case 7:
30742
- _context43.t3 = _context43.sent;
30743
- _context43.t4 = options;
30744
- _context43.t5 = [_context43.t2, _context43.t3, _context43.t4];
30745
- _context43.t6 = sdkOptions;
30746
- _context43.next = 13;
30747
- return (0, _context43.t0)(_context43.t1, _context43.t5, _context43.t6);
30829
+ _context44.t3 = _context44.sent;
30830
+ _context44.t4 = options;
30831
+ _context44.t5 = [_context44.t2, _context44.t3, _context44.t4];
30832
+ _context44.t6 = sdkOptions;
30833
+ _context44.next = 13;
30834
+ return (0, _context44.t0)(_context44.t1, _context44.t5, _context44.t6);
30748
30835
 
30749
30836
  case 13:
30750
- tx = _context43.sent;
30751
- return _context43.abrupt("return", tx);
30837
+ tx = _context44.sent;
30838
+ return _context44.abrupt("return", tx);
30752
30839
 
30753
30840
  case 15:
30754
30841
  case "end":
30755
- return _context43.stop();
30842
+ return _context44.stop();
30756
30843
  }
30757
30844
  }
30758
- }, _callee43, this);
30845
+ }, _callee44, this);
30759
30846
  }));
30760
30847
 
30761
- function removeLiquidityV2(_x214, _x215, _x216, _x217, _x218, _x219, _x220) {
30848
+ function removeLiquidityV2(_x217, _x218, _x219, _x220, _x221, _x222, _x223) {
30762
30849
  return _removeLiquidityV.apply(this, arguments);
30763
30850
  }
30764
30851
 
@@ -30784,11 +30871,11 @@ var Pool = /*#__PURE__*/function () {
30784
30871
  _proto.tradeLyraOption =
30785
30872
  /*#__PURE__*/
30786
30873
  function () {
30787
- var _tradeLyraOption = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee44(market, expiry, strike, optionType, tradeType, optionAmount, assetIn, collateralChangeAmount, isCoveredCall, options, sdkOptions) {
30874
+ var _tradeLyraOption = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee45(market, expiry, strike, optionType, tradeType, optionAmount, assetIn, collateralChangeAmount, isCoveredCall, options, sdkOptions) {
30788
30875
  var swapxData, tx;
30789
- return runtime_1.wrap(function _callee44$(_context44) {
30876
+ return runtime_1.wrap(function _callee45$(_context45) {
30790
30877
  while (1) {
30791
- switch (_context44.prev = _context44.next) {
30878
+ switch (_context45.prev = _context45.next) {
30792
30879
  case 0:
30793
30880
  if (collateralChangeAmount === void 0) {
30794
30881
  collateralChangeAmount = "0";
@@ -30808,27 +30895,27 @@ var Pool = /*#__PURE__*/function () {
30808
30895
  };
30809
30896
  }
30810
30897
 
30811
- _context44.next = 6;
30898
+ _context45.next = 6;
30812
30899
  return getLyraOptionTxData(this, market, optionType, expiry, strike, tradeType, optionAmount, assetIn, ethers.BigNumber.from(collateralChangeAmount), isCoveredCall);
30813
30900
 
30814
30901
  case 6:
30815
- swapxData = _context44.sent;
30816
- _context44.next = 9;
30902
+ swapxData = _context45.sent;
30903
+ _context45.next = 9;
30817
30904
  return getPoolTxOrGasEstimate(this, [routerAddress[this.network][exports.Dapp.LYRA], swapxData, options], sdkOptions);
30818
30905
 
30819
30906
  case 9:
30820
- tx = _context44.sent;
30821
- return _context44.abrupt("return", tx);
30907
+ tx = _context45.sent;
30908
+ return _context45.abrupt("return", tx);
30822
30909
 
30823
30910
  case 11:
30824
30911
  case "end":
30825
- return _context44.stop();
30912
+ return _context45.stop();
30826
30913
  }
30827
30914
  }
30828
- }, _callee44, this);
30915
+ }, _callee45, this);
30829
30916
  }));
30830
30917
 
30831
- function tradeLyraOption(_x221, _x222, _x223, _x224, _x225, _x226, _x227, _x228, _x229, _x230, _x231) {
30918
+ function tradeLyraOption(_x224, _x225, _x226, _x227, _x228, _x229, _x230, _x231, _x232, _x233, _x234) {
30832
30919
  return _tradeLyraOption.apply(this, arguments);
30833
30920
  }
30834
30921
 
@@ -30843,26 +30930,26 @@ var Pool = /*#__PURE__*/function () {
30843
30930
  _proto.getLyraPositions =
30844
30931
  /*#__PURE__*/
30845
30932
  function () {
30846
- var _getLyraPositions = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee45(market) {
30847
- return runtime_1.wrap(function _callee45$(_context45) {
30933
+ var _getLyraPositions = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee46(market) {
30934
+ return runtime_1.wrap(function _callee46$(_context46) {
30848
30935
  while (1) {
30849
- switch (_context45.prev = _context45.next) {
30936
+ switch (_context46.prev = _context46.next) {
30850
30937
  case 0:
30851
- _context45.next = 2;
30938
+ _context46.next = 2;
30852
30939
  return getOptionPositions(this, market);
30853
30940
 
30854
30941
  case 2:
30855
- return _context45.abrupt("return", _context45.sent);
30942
+ return _context46.abrupt("return", _context46.sent);
30856
30943
 
30857
30944
  case 3:
30858
30945
  case "end":
30859
- return _context45.stop();
30946
+ return _context46.stop();
30860
30947
  }
30861
30948
  }
30862
- }, _callee45, this);
30949
+ }, _callee46, this);
30863
30950
  }));
30864
30951
 
30865
- function getLyraPositions(_x232) {
30952
+ function getLyraPositions(_x235) {
30866
30953
  return _getLyraPositions.apply(this, arguments);
30867
30954
  }
30868
30955
 
@@ -30881,11 +30968,11 @@ var Pool = /*#__PURE__*/function () {
30881
30968
  _proto.changeFuturesMargin =
30882
30969
  /*#__PURE__*/
30883
30970
  function () {
30884
- var _changeFuturesMargin = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee46(market, changeAmount, options, sdkOptions) {
30971
+ var _changeFuturesMargin = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee47(market, changeAmount, options, sdkOptions) {
30885
30972
  var tx;
30886
- return runtime_1.wrap(function _callee46$(_context46) {
30973
+ return runtime_1.wrap(function _callee47$(_context47) {
30887
30974
  while (1) {
30888
- switch (_context46.prev = _context46.next) {
30975
+ switch (_context47.prev = _context47.next) {
30889
30976
  case 0:
30890
30977
  if (options === void 0) {
30891
30978
  options = null;
@@ -30897,22 +30984,22 @@ var Pool = /*#__PURE__*/function () {
30897
30984
  };
30898
30985
  }
30899
30986
 
30900
- _context46.next = 4;
30987
+ _context47.next = 4;
30901
30988
  return getPoolTxOrGasEstimate(this, [market, getFuturesChangeMarginTxData(changeAmount), options], sdkOptions);
30902
30989
 
30903
30990
  case 4:
30904
- tx = _context46.sent;
30905
- return _context46.abrupt("return", tx);
30991
+ tx = _context47.sent;
30992
+ return _context47.abrupt("return", tx);
30906
30993
 
30907
30994
  case 6:
30908
30995
  case "end":
30909
- return _context46.stop();
30996
+ return _context47.stop();
30910
30997
  }
30911
30998
  }
30912
- }, _callee46, this);
30999
+ }, _callee47, this);
30913
31000
  }));
30914
31001
 
30915
- function changeFuturesMargin(_x233, _x234, _x235, _x236) {
31002
+ function changeFuturesMargin(_x236, _x237, _x238, _x239) {
30916
31003
  return _changeFuturesMargin.apply(this, arguments);
30917
31004
  }
30918
31005
 
@@ -30931,11 +31018,11 @@ var Pool = /*#__PURE__*/function () {
30931
31018
  _proto.changeFuturesPosition =
30932
31019
  /*#__PURE__*/
30933
31020
  function () {
30934
- var _changeFuturesPosition = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee47(market, changeAmount, options, sdkOptions) {
31021
+ var _changeFuturesPosition = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee48(market, changeAmount, options, sdkOptions) {
30935
31022
  var txData, tx;
30936
- return runtime_1.wrap(function _callee47$(_context47) {
31023
+ return runtime_1.wrap(function _callee48$(_context48) {
30937
31024
  while (1) {
30938
- switch (_context47.prev = _context47.next) {
31025
+ switch (_context48.prev = _context48.next) {
30939
31026
  case 0:
30940
31027
  if (options === void 0) {
30941
31028
  options = null;
@@ -30947,27 +31034,27 @@ var Pool = /*#__PURE__*/function () {
30947
31034
  };
30948
31035
  }
30949
31036
 
30950
- _context47.next = 4;
31037
+ _context48.next = 4;
30951
31038
  return getFuturesChangePositionTxData(changeAmount, market, this);
30952
31039
 
30953
31040
  case 4:
30954
- txData = _context47.sent;
30955
- _context47.next = 7;
31041
+ txData = _context48.sent;
31042
+ _context48.next = 7;
30956
31043
  return getPoolTxOrGasEstimate(this, [market, txData, options], sdkOptions);
30957
31044
 
30958
31045
  case 7:
30959
- tx = _context47.sent;
30960
- return _context47.abrupt("return", tx);
31046
+ tx = _context48.sent;
31047
+ return _context48.abrupt("return", tx);
30961
31048
 
30962
31049
  case 9:
30963
31050
  case "end":
30964
- return _context47.stop();
31051
+ return _context48.stop();
30965
31052
  }
30966
31053
  }
30967
- }, _callee47, this);
31054
+ }, _callee48, this);
30968
31055
  }));
30969
31056
 
30970
- function changeFuturesPosition(_x237, _x238, _x239, _x240) {
31057
+ function changeFuturesPosition(_x240, _x241, _x242, _x243) {
30971
31058
  return _changeFuturesPosition.apply(this, arguments);
30972
31059
  }
30973
31060
 
@@ -30985,11 +31072,11 @@ var Pool = /*#__PURE__*/function () {
30985
31072
  _proto.cancelFuturesOrder =
30986
31073
  /*#__PURE__*/
30987
31074
  function () {
30988
- var _cancelFuturesOrder = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee48(market, options, sdkOptions) {
31075
+ var _cancelFuturesOrder = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee49(market, options, sdkOptions) {
30989
31076
  var txData, tx;
30990
- return runtime_1.wrap(function _callee48$(_context48) {
31077
+ return runtime_1.wrap(function _callee49$(_context49) {
30991
31078
  while (1) {
30992
- switch (_context48.prev = _context48.next) {
31079
+ switch (_context49.prev = _context49.next) {
30993
31080
  case 0:
30994
31081
  if (options === void 0) {
30995
31082
  options = null;
@@ -31001,27 +31088,27 @@ var Pool = /*#__PURE__*/function () {
31001
31088
  };
31002
31089
  }
31003
31090
 
31004
- _context48.next = 4;
31091
+ _context49.next = 4;
31005
31092
  return getFuturesCancelOrderTxData(this);
31006
31093
 
31007
31094
  case 4:
31008
- txData = _context48.sent;
31009
- _context48.next = 7;
31095
+ txData = _context49.sent;
31096
+ _context49.next = 7;
31010
31097
  return getPoolTxOrGasEstimate(this, [market, txData, options], sdkOptions);
31011
31098
 
31012
31099
  case 7:
31013
- tx = _context48.sent;
31014
- return _context48.abrupt("return", tx);
31100
+ tx = _context49.sent;
31101
+ return _context49.abrupt("return", tx);
31015
31102
 
31016
31103
  case 9:
31017
31104
  case "end":
31018
- return _context48.stop();
31105
+ return _context49.stop();
31019
31106
  }
31020
31107
  }
31021
- }, _callee48, this);
31108
+ }, _callee49, this);
31022
31109
  }));
31023
31110
 
31024
- function cancelFuturesOrder(_x241, _x242, _x243) {
31111
+ function cancelFuturesOrder(_x244, _x245, _x246) {
31025
31112
  return _cancelFuturesOrder.apply(this, arguments);
31026
31113
  }
31027
31114
 
@@ -31038,11 +31125,11 @@ var Pool = /*#__PURE__*/function () {
31038
31125
  _proto.mintManagerFee =
31039
31126
  /*#__PURE__*/
31040
31127
  function () {
31041
- var _mintManagerFee = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee49(options, estimateGas) {
31128
+ var _mintManagerFee = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee50(options, estimateGas) {
31042
31129
  var tx;
31043
- return runtime_1.wrap(function _callee49$(_context49) {
31130
+ return runtime_1.wrap(function _callee50$(_context50) {
31044
31131
  while (1) {
31045
- switch (_context49.prev = _context49.next) {
31132
+ switch (_context50.prev = _context50.next) {
31046
31133
  case 0:
31047
31134
  if (options === void 0) {
31048
31135
  options = null;
@@ -31053,33 +31140,33 @@ var Pool = /*#__PURE__*/function () {
31053
31140
  }
31054
31141
 
31055
31142
  if (!estimateGas) {
31056
- _context49.next = 6;
31143
+ _context50.next = 6;
31057
31144
  break;
31058
31145
  }
31059
31146
 
31060
- _context49.next = 5;
31147
+ _context50.next = 5;
31061
31148
  return this.poolLogic.estimateGas.mintManagerFee(options);
31062
31149
 
31063
31150
  case 5:
31064
- return _context49.abrupt("return", _context49.sent);
31151
+ return _context50.abrupt("return", _context50.sent);
31065
31152
 
31066
31153
  case 6:
31067
- _context49.next = 8;
31154
+ _context50.next = 8;
31068
31155
  return this.poolLogic.mintManagerFee(options);
31069
31156
 
31070
31157
  case 8:
31071
- tx = _context49.sent;
31072
- return _context49.abrupt("return", tx);
31158
+ tx = _context50.sent;
31159
+ return _context50.abrupt("return", tx);
31073
31160
 
31074
31161
  case 10:
31075
31162
  case "end":
31076
- return _context49.stop();
31163
+ return _context50.stop();
31077
31164
  }
31078
31165
  }
31079
- }, _callee49, this);
31166
+ }, _callee50, this);
31080
31167
  }));
31081
31168
 
31082
- function mintManagerFee(_x244, _x245) {
31169
+ function mintManagerFee(_x247, _x248) {
31083
31170
  return _mintManagerFee.apply(this, arguments);
31084
31171
  }
31085
31172
 
@@ -31094,25 +31181,25 @@ var Pool = /*#__PURE__*/function () {
31094
31181
  _proto.getAvailableManagerFee =
31095
31182
  /*#__PURE__*/
31096
31183
  function () {
31097
- var _getAvailableManagerFee = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee50() {
31184
+ var _getAvailableManagerFee = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee51() {
31098
31185
  var fee;
31099
- return runtime_1.wrap(function _callee50$(_context50) {
31186
+ return runtime_1.wrap(function _callee51$(_context51) {
31100
31187
  while (1) {
31101
- switch (_context50.prev = _context50.next) {
31188
+ switch (_context51.prev = _context51.next) {
31102
31189
  case 0:
31103
- _context50.next = 2;
31190
+ _context51.next = 2;
31104
31191
  return this.poolLogic.availableManagerFee();
31105
31192
 
31106
31193
  case 2:
31107
- fee = _context50.sent;
31108
- return _context50.abrupt("return", ethers.BigNumber.from(fee));
31194
+ fee = _context51.sent;
31195
+ return _context51.abrupt("return", ethers.BigNumber.from(fee));
31109
31196
 
31110
31197
  case 4:
31111
31198
  case "end":
31112
- return _context50.stop();
31199
+ return _context51.stop();
31113
31200
  }
31114
31201
  }
31115
- }, _callee50, this);
31202
+ }, _callee51, this);
31116
31203
  }));
31117
31204
 
31118
31205
  function getAvailableManagerFee() {
@@ -31134,11 +31221,11 @@ var Pool = /*#__PURE__*/function () {
31134
31221
  _proto.vestTokens =
31135
31222
  /*#__PURE__*/
31136
31223
  function () {
31137
- var _vestTokens = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee51(tokenAddress, amount, options, sdkOptions) {
31224
+ var _vestTokens = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee52(tokenAddress, amount, options, sdkOptions) {
31138
31225
  var txData, tx;
31139
- return runtime_1.wrap(function _callee51$(_context51) {
31226
+ return runtime_1.wrap(function _callee52$(_context52) {
31140
31227
  while (1) {
31141
- switch (_context51.prev = _context51.next) {
31228
+ switch (_context52.prev = _context52.next) {
31142
31229
  case 0:
31143
31230
  if (options === void 0) {
31144
31231
  options = null;
@@ -31150,27 +31237,27 @@ var Pool = /*#__PURE__*/function () {
31150
31237
  };
31151
31238
  }
31152
31239
 
31153
- _context51.next = 4;
31240
+ _context52.next = 4;
31154
31241
  return getCreateVestTxData(amount);
31155
31242
 
31156
31243
  case 4:
31157
- txData = _context51.sent;
31158
- _context51.next = 7;
31244
+ txData = _context52.sent;
31245
+ _context52.next = 7;
31159
31246
  return getPoolTxOrGasEstimate(this, [tokenAddress, txData, options], sdkOptions);
31160
31247
 
31161
31248
  case 7:
31162
- tx = _context51.sent;
31163
- return _context51.abrupt("return", tx);
31249
+ tx = _context52.sent;
31250
+ return _context52.abrupt("return", tx);
31164
31251
 
31165
31252
  case 9:
31166
31253
  case "end":
31167
- return _context51.stop();
31254
+ return _context52.stop();
31168
31255
  }
31169
31256
  }
31170
- }, _callee51, this);
31257
+ }, _callee52, this);
31171
31258
  }));
31172
31259
 
31173
- function vestTokens(_x246, _x247, _x248, _x249) {
31260
+ function vestTokens(_x249, _x250, _x251, _x252) {
31174
31261
  return _vestTokens.apply(this, arguments);
31175
31262
  }
31176
31263
 
@@ -31189,11 +31276,11 @@ var Pool = /*#__PURE__*/function () {
31189
31276
  _proto.exitVestedToken =
31190
31277
  /*#__PURE__*/
31191
31278
  function () {
31192
- var _exitVestedToken = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee52(tokenAddress, id, options, sdkOptions) {
31279
+ var _exitVestedToken = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee53(tokenAddress, id, options, sdkOptions) {
31193
31280
  var txData, tx;
31194
- return runtime_1.wrap(function _callee52$(_context52) {
31281
+ return runtime_1.wrap(function _callee53$(_context53) {
31195
31282
  while (1) {
31196
- switch (_context52.prev = _context52.next) {
31283
+ switch (_context53.prev = _context53.next) {
31197
31284
  case 0:
31198
31285
  if (options === void 0) {
31199
31286
  options = null;
@@ -31205,27 +31292,27 @@ var Pool = /*#__PURE__*/function () {
31205
31292
  };
31206
31293
  }
31207
31294
 
31208
- _context52.next = 4;
31295
+ _context53.next = 4;
31209
31296
  return getExitVestTxData(id);
31210
31297
 
31211
31298
  case 4:
31212
- txData = _context52.sent;
31213
- _context52.next = 7;
31299
+ txData = _context53.sent;
31300
+ _context53.next = 7;
31214
31301
  return getPoolTxOrGasEstimate(this, [tokenAddress, txData, options], sdkOptions);
31215
31302
 
31216
31303
  case 7:
31217
- tx = _context52.sent;
31218
- return _context52.abrupt("return", tx);
31304
+ tx = _context53.sent;
31305
+ return _context53.abrupt("return", tx);
31219
31306
 
31220
31307
  case 9:
31221
31308
  case "end":
31222
- return _context52.stop();
31309
+ return _context53.stop();
31223
31310
  }
31224
31311
  }
31225
- }, _callee52, this);
31312
+ }, _callee53, this);
31226
31313
  }));
31227
31314
 
31228
- function exitVestedToken(_x250, _x251, _x252, _x253) {
31315
+ function exitVestedToken(_x253, _x254, _x255, _x256) {
31229
31316
  return _exitVestedToken.apply(this, arguments);
31230
31317
  }
31231
31318
 
@@ -31245,11 +31332,11 @@ var Pool = /*#__PURE__*/function () {
31245
31332
  _proto.mintUnitViaFlatMoney =
31246
31333
  /*#__PURE__*/
31247
31334
  function () {
31248
- var _mintUnitViaFlatMoney2 = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee53(depositAmount, slippage, maxKeeperFeeInUsd, options, sdkOptions) {
31335
+ var _mintUnitViaFlatMoney2 = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee54(depositAmount, slippage, maxKeeperFeeInUsd, options, sdkOptions) {
31249
31336
  var tx;
31250
- return runtime_1.wrap(function _callee53$(_context53) {
31337
+ return runtime_1.wrap(function _callee54$(_context54) {
31251
31338
  while (1) {
31252
- switch (_context53.prev = _context53.next) {
31339
+ switch (_context54.prev = _context54.next) {
31253
31340
  case 0:
31254
31341
  if (slippage === void 0) {
31255
31342
  slippage = 0.5;
@@ -31265,22 +31352,22 @@ var Pool = /*#__PURE__*/function () {
31265
31352
  };
31266
31353
  }
31267
31354
 
31268
- _context53.next = 5;
31355
+ _context54.next = 5;
31269
31356
  return mintUnitViaFlatMoney(this, depositAmount, slippage, maxKeeperFeeInUsd, options, sdkOptions);
31270
31357
 
31271
31358
  case 5:
31272
- tx = _context53.sent;
31273
- return _context53.abrupt("return", tx);
31359
+ tx = _context54.sent;
31360
+ return _context54.abrupt("return", tx);
31274
31361
 
31275
31362
  case 7:
31276
31363
  case "end":
31277
- return _context53.stop();
31364
+ return _context54.stop();
31278
31365
  }
31279
31366
  }
31280
- }, _callee53, this);
31367
+ }, _callee54, this);
31281
31368
  }));
31282
31369
 
31283
- function mintUnitViaFlatMoney$1(_x254, _x255, _x256, _x257, _x258) {
31370
+ function mintUnitViaFlatMoney$1(_x257, _x258, _x259, _x260, _x261) {
31284
31371
  return _mintUnitViaFlatMoney2.apply(this, arguments);
31285
31372
  }
31286
31373
 
@@ -31300,11 +31387,11 @@ var Pool = /*#__PURE__*/function () {
31300
31387
  _proto.redeemUnitViaFlatMoney =
31301
31388
  /*#__PURE__*/
31302
31389
  function () {
31303
- var _redeemUnitViaFlatMoney2 = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee54(withdrawAmount, slippage, maxKeeperFeeInUsd, options, sdkOptions) {
31390
+ var _redeemUnitViaFlatMoney2 = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee55(withdrawAmount, slippage, maxKeeperFeeInUsd, options, sdkOptions) {
31304
31391
  var tx;
31305
- return runtime_1.wrap(function _callee54$(_context54) {
31392
+ return runtime_1.wrap(function _callee55$(_context55) {
31306
31393
  while (1) {
31307
- switch (_context54.prev = _context54.next) {
31394
+ switch (_context55.prev = _context55.next) {
31308
31395
  case 0:
31309
31396
  if (slippage === void 0) {
31310
31397
  slippage = 0.5;
@@ -31320,22 +31407,22 @@ var Pool = /*#__PURE__*/function () {
31320
31407
  };
31321
31408
  }
31322
31409
 
31323
- _context54.next = 5;
31410
+ _context55.next = 5;
31324
31411
  return redeemUnitViaFlatMoney(this, withdrawAmount, slippage, maxKeeperFeeInUsd, options, sdkOptions);
31325
31412
 
31326
31413
  case 5:
31327
- tx = _context54.sent;
31328
- return _context54.abrupt("return", tx);
31414
+ tx = _context55.sent;
31415
+ return _context55.abrupt("return", tx);
31329
31416
 
31330
31417
  case 7:
31331
31418
  case "end":
31332
- return _context54.stop();
31419
+ return _context55.stop();
31333
31420
  }
31334
31421
  }
31335
- }, _callee54, this);
31422
+ }, _callee55, this);
31336
31423
  }));
31337
31424
 
31338
- function redeemUnitViaFlatMoney$1(_x259, _x260, _x261, _x262, _x263) {
31425
+ function redeemUnitViaFlatMoney$1(_x262, _x263, _x264, _x265, _x266) {
31339
31426
  return _redeemUnitViaFlatMoney2.apply(this, arguments);
31340
31427
  }
31341
31428
 
@@ -31343,11 +31430,11 @@ var Pool = /*#__PURE__*/function () {
31343
31430
  }();
31344
31431
 
31345
31432
  _proto.cancelOrderViaFlatMoney = /*#__PURE__*/function () {
31346
- var _cancelOrderViaFlatMoney2 = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee55(options, estimateGas) {
31433
+ var _cancelOrderViaFlatMoney2 = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee56(options, estimateGas) {
31347
31434
  var tx;
31348
- return runtime_1.wrap(function _callee55$(_context55) {
31435
+ return runtime_1.wrap(function _callee56$(_context56) {
31349
31436
  while (1) {
31350
- switch (_context55.prev = _context55.next) {
31437
+ switch (_context56.prev = _context56.next) {
31351
31438
  case 0:
31352
31439
  if (options === void 0) {
31353
31440
  options = null;
@@ -31357,22 +31444,22 @@ var Pool = /*#__PURE__*/function () {
31357
31444
  estimateGas = false;
31358
31445
  }
31359
31446
 
31360
- _context55.next = 4;
31447
+ _context56.next = 4;
31361
31448
  return cancelOrderViaFlatMoney(this, options, estimateGas);
31362
31449
 
31363
31450
  case 4:
31364
- tx = _context55.sent;
31365
- return _context55.abrupt("return", tx);
31451
+ tx = _context56.sent;
31452
+ return _context56.abrupt("return", tx);
31366
31453
 
31367
31454
  case 6:
31368
31455
  case "end":
31369
- return _context55.stop();
31456
+ return _context56.stop();
31370
31457
  }
31371
31458
  }
31372
- }, _callee55, this);
31459
+ }, _callee56, this);
31373
31460
  }));
31374
31461
 
31375
- function cancelOrderViaFlatMoney$1(_x264, _x265) {
31462
+ function cancelOrderViaFlatMoney$1(_x267, _x268) {
31376
31463
  return _cancelOrderViaFlatMoney2.apply(this, arguments);
31377
31464
  }
31378
31465
 
@@ -31391,11 +31478,11 @@ var Pool = /*#__PURE__*/function () {
31391
31478
  _proto.completeTorosWithdrawal =
31392
31479
  /*#__PURE__*/
31393
31480
  function () {
31394
- var _completeTorosWithdrawal = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee56(destinationToken, slippage, options, sdkOptions) {
31481
+ var _completeTorosWithdrawal = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee57(destinationToken, slippage, options, sdkOptions) {
31395
31482
  var txData, tx;
31396
- return runtime_1.wrap(function _callee56$(_context56) {
31483
+ return runtime_1.wrap(function _callee57$(_context57) {
31397
31484
  while (1) {
31398
- switch (_context56.prev = _context56.next) {
31485
+ switch (_context57.prev = _context57.next) {
31399
31486
  case 0:
31400
31487
  if (slippage === void 0) {
31401
31488
  slippage = 0.5;
@@ -31411,27 +31498,27 @@ var Pool = /*#__PURE__*/function () {
31411
31498
  };
31412
31499
  }
31413
31500
 
31414
- _context56.next = 5;
31501
+ _context57.next = 5;
31415
31502
  return getCompleteWithdrawalTxData(this, destinationToken, slippage * 100, false);
31416
31503
 
31417
31504
  case 5:
31418
- txData = _context56.sent;
31419
- _context56.next = 8;
31505
+ txData = _context57.sent;
31506
+ _context57.next = 8;
31420
31507
  return getPoolTxOrGasEstimate(this, [routerAddress[this.network].toros, txData, options], sdkOptions);
31421
31508
 
31422
31509
  case 8:
31423
- tx = _context56.sent;
31424
- return _context56.abrupt("return", tx);
31510
+ tx = _context57.sent;
31511
+ return _context57.abrupt("return", tx);
31425
31512
 
31426
31513
  case 10:
31427
31514
  case "end":
31428
- return _context56.stop();
31515
+ return _context57.stop();
31429
31516
  }
31430
31517
  }
31431
- }, _callee56, this);
31518
+ }, _callee57, this);
31432
31519
  }));
31433
31520
 
31434
- function completeTorosWithdrawal(_x266, _x267, _x268, _x269) {
31521
+ function completeTorosWithdrawal(_x269, _x270, _x271, _x272) {
31435
31522
  return _completeTorosWithdrawal.apply(this, arguments);
31436
31523
  }
31437
31524