@defisaver/sdk 1.0.23 → 1.0.24
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/esm/src/Action.js +1 -2
- package/esm/src/actions/curveusd/CurveUsdBorrowAction.d.ts +15 -0
- package/esm/src/actions/curveusd/CurveUsdBorrowAction.js +22 -0
- package/esm/src/actions/curveusd/CurveUsdCreateAction.d.ts +22 -0
- package/esm/src/actions/curveusd/CurveUsdCreateAction.js +46 -0
- package/esm/src/actions/curveusd/CurveUsdPaybackAction.d.ts +22 -0
- package/esm/src/actions/curveusd/CurveUsdPaybackAction.js +43 -0
- package/esm/src/actions/curveusd/CurveUsdSupplyAction.d.ts +20 -0
- package/esm/src/actions/curveusd/CurveUsdSupplyAction.js +42 -0
- package/esm/src/actions/curveusd/CurveUsdWithdrawAction.d.ts +15 -0
- package/esm/src/actions/curveusd/CurveUsdWithdrawAction.js +22 -0
- package/esm/src/actions/curveusd/index.d.ts +5 -0
- package/esm/src/actions/curveusd/index.js +5 -0
- package/esm/src/actions/index.d.ts +2 -1
- package/esm/src/actions/index.js +2 -1
- package/esm/src/actions/morpho/index.d.ts +0 -4
- package/esm/src/actions/morpho/index.js +0 -4
- package/esm/src/addresses.d.ts +0 -12
- package/esm/src/addresses.js +0 -5
- package/esm/src/index.d.ts +0 -48
- package/esm/src/types.d.ts +2 -1
- package/esm/src/utils/curveusd-utils.d.ts +10 -0
- package/esm/src/utils/curveusd-utils.js +6 -0
- package/esm/src/utils/index.d.ts +2 -1
- package/esm/src/utils/index.js +2 -1
- package/package.json +1 -1
- package/src/Action.ts +1 -2
- package/src/actions/curveusd/CurveUsdBorrowAction.ts +34 -0
- package/src/actions/curveusd/CurveUsdCreateAction.ts +53 -0
- package/src/actions/curveusd/CurveUsdPaybackAction.ts +48 -0
- package/src/actions/curveusd/CurveUsdSupplyAction.ts +48 -0
- package/src/actions/curveusd/CurveUsdWithdrawAction.ts +34 -0
- package/src/actions/curveusd/index.ts +5 -0
- package/src/actions/index.ts +2 -0
- package/src/actions/morpho/index.ts +0 -4
- package/src/addresses.ts +0 -6
- package/src/types.ts +2 -1
- package/src/utils/curveusd-utils.ts +8 -0
- package/src/utils/index.ts +2 -0
- package/umd/index.js +316 -200
- package/yarn-error.log +3976 -0
- package/esm/src/actions/morpho/aaveV3/MorphoAaveV3BorrowAction.d.ts +0 -18
- package/esm/src/actions/morpho/aaveV3/MorphoAaveV3BorrowAction.js +0 -27
- package/esm/src/actions/morpho/aaveV3/MorphoAaveV3PaybackAction.d.ts +0 -21
- package/esm/src/actions/morpho/aaveV3/MorphoAaveV3PaybackAction.js +0 -44
- package/esm/src/actions/morpho/aaveV3/MorphoAaveV3SupplyAction.d.ts +0 -23
- package/esm/src/actions/morpho/aaveV3/MorphoAaveV3SupplyAction.js +0 -47
- package/esm/src/actions/morpho/aaveV3/MorphoAaveV3WithdrawAction.d.ts +0 -19
- package/esm/src/actions/morpho/aaveV3/MorphoAaveV3WithdrawAction.js +0 -29
- package/src/actions/morpho/aaveV3/MorphoAaveV3BorrowAction.ts +0 -42
- package/src/actions/morpho/aaveV3/MorphoAaveV3PaybackAction.ts +0 -47
- package/src/actions/morpho/aaveV3/MorphoAaveV3SupplyAction.ts +0 -52
- package/src/actions/morpho/aaveV3/MorphoAaveV3WithdrawAction.ts +0 -45
package/umd/index.js
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
exports["defisaver-sdk"] = factory(require("web3-eth-abi"), require("web3-utils"), require("decimal.js"), require("@defisaver/tokens"), require("@ethersproject/solidity"), require("@ethersproject/address"), require("axios"));
|
|
8
8
|
else
|
|
9
9
|
root["defisaver-sdk"] = factory(root["web3-eth-abi"], root["web3-utils"], root["decimal.js"], root["@defisaver/tokens"], root["@ethersproject/solidity"], root["@ethersproject/address"], root["axios"]);
|
|
10
|
-
})(this, (__WEBPACK_EXTERNAL_MODULE__2__, __WEBPACK_EXTERNAL_MODULE__3__, __WEBPACK_EXTERNAL_MODULE__5__, __WEBPACK_EXTERNAL_MODULE__6__, __WEBPACK_EXTERNAL_MODULE__105__, __WEBPACK_EXTERNAL_MODULE__106__,
|
|
10
|
+
})(this, (__WEBPACK_EXTERNAL_MODULE__2__, __WEBPACK_EXTERNAL_MODULE__3__, __WEBPACK_EXTERNAL_MODULE__5__, __WEBPACK_EXTERNAL_MODULE__6__, __WEBPACK_EXTERNAL_MODULE__105__, __WEBPACK_EXTERNAL_MODULE__106__, __WEBPACK_EXTERNAL_MODULE__247__) => {
|
|
11
11
|
return /******/ (() => { // webpackBootstrap
|
|
12
12
|
/******/ "use strict";
|
|
13
13
|
/******/ var __webpack_modules__ = ([
|
|
@@ -143,13 +143,7 @@ class Action {
|
|
|
143
143
|
return [web3_eth_abi__WEBPACK_IMPORTED_MODULE_0___default().encodeParameter(_paramType, _arg)];
|
|
144
144
|
}
|
|
145
145
|
encodeForL2DsProxyCall() {
|
|
146
|
-
|
|
147
|
-
var {
|
|
148
|
-
name
|
|
149
|
-
} = _ref;
|
|
150
|
-
return name === 'executeActionDirect';
|
|
151
|
-
});
|
|
152
|
-
return web3_eth_abi__WEBPACK_IMPORTED_MODULE_0___default().encodeFunctionCall(executeActionDirectAbi, this._encodeForCall());
|
|
146
|
+
return this._encodeForCall()[0];
|
|
153
147
|
}
|
|
154
148
|
encodeForL2Recipe() {
|
|
155
149
|
return this._encodeForCall()[0];
|
|
@@ -161,10 +155,10 @@ class Action {
|
|
|
161
155
|
*/
|
|
162
156
|
encodeForDsProxyCall() {
|
|
163
157
|
if (_config__WEBPACK_IMPORTED_MODULE_2__.CONFIG.chainId === 1) {
|
|
164
|
-
var executeActionDirectAbi = _abis_Action_json__WEBPACK_IMPORTED_MODULE_3__.find(
|
|
158
|
+
var executeActionDirectAbi = _abis_Action_json__WEBPACK_IMPORTED_MODULE_3__.find(_ref => {
|
|
165
159
|
var {
|
|
166
160
|
name
|
|
167
|
-
} =
|
|
161
|
+
} = _ref;
|
|
168
162
|
return name === 'executeActionDirect';
|
|
169
163
|
});
|
|
170
164
|
return [this.contractAddress, web3_eth_abi__WEBPACK_IMPORTED_MODULE_0___default().encodeFunctionCall(executeActionDirectAbi, this._encodeForCall())];
|
|
@@ -216,8 +210,8 @@ class Action {
|
|
|
216
210
|
*/
|
|
217
211
|
getAccessList(chainId) {
|
|
218
212
|
if (chainId !== 1) return [];
|
|
219
|
-
return [[this.contractAddress, []], ...(_AccessLists__WEBPACK_IMPORTED_MODULE_4__.AccessLists[this.name] || [])].map(
|
|
220
|
-
var [address, storageKeys] =
|
|
213
|
+
return [[this.contractAddress, []], ...(_AccessLists__WEBPACK_IMPORTED_MODULE_4__.AccessLists[this.name] || [])].map(_ref2 => {
|
|
214
|
+
var [address, storageKeys] = _ref2;
|
|
221
215
|
return {
|
|
222
216
|
address,
|
|
223
217
|
storageKeys: storageKeys.map(num => (0,web3_utils__WEBPACK_IMPORTED_MODULE_1__.padLeft)((0,web3_utils__WEBPACK_IMPORTED_MODULE_1__.toHex)(num), 64))
|
|
@@ -1306,11 +1300,6 @@ var actionAddresses = {
|
|
|
1306
1300
|
MorphoAaveV2Supply: '0x60ED1Cf5Da785AA4FD4A4fF3f8cFc0682d60E0F3',
|
|
1307
1301
|
MorphoAaveV2Withdraw: '0x29a8b5a8889f465c85b778edccf984e44ad70f12',
|
|
1308
1302
|
MorphoClaim: '0xa269C841E26EA8Ee1F0350a2E5905F71446998dC',
|
|
1309
|
-
// morpho aave v3
|
|
1310
|
-
MorphoAaveV3Borrow: '0x487719C57b88477F19423aB0652b3E26b96baA7F',
|
|
1311
|
-
MorphoAaveV3Payback: '0x36b8b968c81D97cBfAa642e206b634A6f378d287',
|
|
1312
|
-
MorphoAaveV3Supply: '0x51fA8FBc6F0aDEfe2FBA06104FCA39f5beD69291',
|
|
1313
|
-
MorphoAaveV3Withdraw: '0xdc3e74C4cD577275296ceFE36A3D082223AfF206',
|
|
1314
1303
|
// compound
|
|
1315
1304
|
CompBorrow: '0x8495579BF6Ae848f7E59686536F834f1d2CCd79C',
|
|
1316
1305
|
CompClaim: '0x81F488cF7A0128A9DB5e7207042cCAB1CB0ac902',
|
|
@@ -1805,6 +1794,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
1805
1794
|
/* harmony export */ "compoundV3": () => (/* reexport module object */ _compoundV3__WEBPACK_IMPORTED_MODULE_22__),
|
|
1806
1795
|
/* harmony export */ "convex": () => (/* reexport module object */ _convex__WEBPACK_IMPORTED_MODULE_20__),
|
|
1807
1796
|
/* harmony export */ "curve": () => (/* reexport module object */ _curve__WEBPACK_IMPORTED_MODULE_15__),
|
|
1797
|
+
/* harmony export */ "curveusd": () => (/* reexport module object */ _curveusd__WEBPACK_IMPORTED_MODULE_25__),
|
|
1808
1798
|
/* harmony export */ "dydx": () => (/* reexport module object */ _dydx__WEBPACK_IMPORTED_MODULE_7__),
|
|
1809
1799
|
/* harmony export */ "flashloan": () => (/* reexport module object */ _flashloan__WEBPACK_IMPORTED_MODULE_4__),
|
|
1810
1800
|
/* harmony export */ "guni": () => (/* reexport module object */ _guni__WEBPACK_IMPORTED_MODULE_16__),
|
|
@@ -1844,7 +1834,9 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
1844
1834
|
/* harmony import */ var _chickenBonds__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(198);
|
|
1845
1835
|
/* harmony import */ var _compoundV3__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(206);
|
|
1846
1836
|
/* harmony import */ var _morpho__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(214);
|
|
1847
|
-
/* harmony import */ var _bprotocol__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(
|
|
1837
|
+
/* harmony import */ var _bprotocol__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(220);
|
|
1838
|
+
/* harmony import */ var _curveusd__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(223);
|
|
1839
|
+
|
|
1848
1840
|
|
|
1849
1841
|
|
|
1850
1842
|
|
|
@@ -8609,10 +8601,6 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
8609
8601
|
/* harmony export */ "MorphoAaveV2PaybackAction": () => (/* reexport safe */ _MorphoAaveV2PaybackAction__WEBPACK_IMPORTED_MODULE_3__.MorphoAaveV2PaybackAction),
|
|
8610
8602
|
/* harmony export */ "MorphoAaveV2SupplyAction": () => (/* reexport safe */ _MorphoAaveV2SupplyAction__WEBPACK_IMPORTED_MODULE_0__.MorphoAaveV2SupplyAction),
|
|
8611
8603
|
/* harmony export */ "MorphoAaveV2WithdrawAction": () => (/* reexport safe */ _MorphoAaveV2WithdrawAction__WEBPACK_IMPORTED_MODULE_1__.MorphoAaveV2WithdrawAction),
|
|
8612
|
-
/* harmony export */ "MorphoAaveV3BorrowAction": () => (/* reexport safe */ _aaveV3_MorphoAaveV3BorrowAction__WEBPACK_IMPORTED_MODULE_7__.MorphoAaveV3BorrowAction),
|
|
8613
|
-
/* harmony export */ "MorphoAaveV3PaybackAction": () => (/* reexport safe */ _aaveV3_MorphoAaveV3PaybackAction__WEBPACK_IMPORTED_MODULE_8__.MorphoAaveV3PaybackAction),
|
|
8614
|
-
/* harmony export */ "MorphoAaveV3SupplyAction": () => (/* reexport safe */ _aaveV3_MorphoAaveV3SupplyAction__WEBPACK_IMPORTED_MODULE_5__.MorphoAaveV3SupplyAction),
|
|
8615
|
-
/* harmony export */ "MorphoAaveV3WithdrawAction": () => (/* reexport safe */ _aaveV3_MorphoAaveV3WithdrawAction__WEBPACK_IMPORTED_MODULE_6__.MorphoAaveV3WithdrawAction),
|
|
8616
8604
|
/* harmony export */ "MorphoClaimAction": () => (/* reexport safe */ _MorphoClaimAction__WEBPACK_IMPORTED_MODULE_4__.MorphoClaimAction)
|
|
8617
8605
|
/* harmony export */ });
|
|
8618
8606
|
/* harmony import */ var _MorphoAaveV2SupplyAction__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(215);
|
|
@@ -8620,14 +8608,6 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
8620
8608
|
/* harmony import */ var _MorphoAaveV2BorrowAction__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(217);
|
|
8621
8609
|
/* harmony import */ var _MorphoAaveV2PaybackAction__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(218);
|
|
8622
8610
|
/* harmony import */ var _MorphoClaimAction__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(219);
|
|
8623
|
-
/* harmony import */ var _aaveV3_MorphoAaveV3SupplyAction__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(220);
|
|
8624
|
-
/* harmony import */ var _aaveV3_MorphoAaveV3WithdrawAction__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(221);
|
|
8625
|
-
/* harmony import */ var _aaveV3_MorphoAaveV3BorrowAction__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(222);
|
|
8626
|
-
/* harmony import */ var _aaveV3_MorphoAaveV3PaybackAction__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(223);
|
|
8627
|
-
|
|
8628
|
-
|
|
8629
|
-
|
|
8630
|
-
|
|
8631
8611
|
|
|
8632
8612
|
|
|
8633
8613
|
|
|
@@ -8825,7 +8805,21 @@ class MorphoClaimAction extends _Action__WEBPACK_IMPORTED_MODULE_0__.Action {
|
|
|
8825
8805
|
|
|
8826
8806
|
__webpack_require__.r(__webpack_exports__);
|
|
8827
8807
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
8828
|
-
/* harmony export */ "
|
|
8808
|
+
/* harmony export */ "BprotocolLiquitySPDepositAction": () => (/* reexport safe */ _BprotocolLiquitySPDepositAction__WEBPACK_IMPORTED_MODULE_0__.BprotocolLiquitySPDepositAction),
|
|
8809
|
+
/* harmony export */ "BprotocolLiquitySPWithdrawAction": () => (/* reexport safe */ _BprotocolLiquitySPWithdrawAction__WEBPACK_IMPORTED_MODULE_1__.BprotocolLiquitySPWithdrawAction)
|
|
8810
|
+
/* harmony export */ });
|
|
8811
|
+
/* harmony import */ var _BprotocolLiquitySPDepositAction__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(221);
|
|
8812
|
+
/* harmony import */ var _BprotocolLiquitySPWithdrawAction__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(222);
|
|
8813
|
+
|
|
8814
|
+
|
|
8815
|
+
|
|
8816
|
+
/***/ }),
|
|
8817
|
+
/* 221 */
|
|
8818
|
+
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
8819
|
+
|
|
8820
|
+
__webpack_require__.r(__webpack_exports__);
|
|
8821
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
8822
|
+
/* harmony export */ "BprotocolLiquitySPDepositAction": () => (/* binding */ BprotocolLiquitySPDepositAction)
|
|
8829
8823
|
/* harmony export */ });
|
|
8830
8824
|
/* harmony import */ var _defisaver_tokens__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6);
|
|
8831
8825
|
/* harmony import */ var _defisaver_tokens__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_defisaver_tokens__WEBPACK_IMPORTED_MODULE_0__);
|
|
@@ -8837,250 +8831,369 @@ function _asyncToGenerator(fn) { return function () { var self = this, args = ar
|
|
|
8837
8831
|
|
|
8838
8832
|
|
|
8839
8833
|
/**
|
|
8840
|
-
*
|
|
8841
|
-
*
|
|
8842
|
-
* @
|
|
8834
|
+
* BprotocolLiquitySPDeposit - Action that deposits LUSD into Bprotocol
|
|
8835
|
+
* @dev LQTY rewards accrue over time and are paid out each time the user interacts with the protocol
|
|
8836
|
+
* @dev Deposit amount must be greater than zero, for LQTY only claim use BprotocolLiquitySPWithdraw
|
|
8837
|
+
* @category Bprotocol
|
|
8843
8838
|
*/
|
|
8844
|
-
class
|
|
8839
|
+
class BprotocolLiquitySPDepositAction extends _Action__WEBPACK_IMPORTED_MODULE_1__.Action {
|
|
8845
8840
|
/**
|
|
8846
|
-
* @param
|
|
8847
|
-
* @param
|
|
8848
|
-
* @param
|
|
8849
|
-
* @param from - Tokens will be sent from this address
|
|
8850
|
-
* @param onBehalf - For what user we are paying back the debt, defaults to proxy
|
|
8851
|
-
* @param supplyAsColl Whether to supplyAsCollateral or regular supply
|
|
8852
|
-
* @param maxIterations Max number of iterations for p2p matching, 0 will use default num of iterations
|
|
8841
|
+
* @param lusdAmount Amount of LUSD to deposit into Bprotocol
|
|
8842
|
+
* @param from Address from where the LUSD is being pulled
|
|
8843
|
+
* @param lqtyTo Address that will recieve LQTY rewards
|
|
8853
8844
|
*/
|
|
8854
|
-
constructor(
|
|
8855
|
-
|
|
8856
|
-
|
|
8857
|
-
var maxIterations = arguments.length > 6 && arguments[6] !== undefined ? arguments[6] : '4';
|
|
8858
|
-
super('MorphoAaveV3Supply', (0,_addresses__WEBPACK_IMPORTED_MODULE_2__.getAddr)('MorphoAaveV3Supply'), ['uint256', 'address', 'uint256', 'address', 'address', 'bool', 'uint256'], [emodeId, tokenAddr, amount, from, onBehalf, supplyAsColl, maxIterations]);
|
|
8859
|
-
this.mappableArgs = [this.args[0], this.args[1], this.args[2], this.args[3], this.args[4], this.args[5]];
|
|
8845
|
+
constructor(lusdAmount, from, lqtyTo) {
|
|
8846
|
+
super('BprotocolLiquitySPDeposit', (0,_addresses__WEBPACK_IMPORTED_MODULE_2__.getAddr)('BprotocolLiquitySPDeposit'), ['uint256', 'address', 'address'], [lusdAmount, from, lqtyTo]);
|
|
8847
|
+
this.mappableArgs = [this.args[0], this.args[1], this.args[2]];
|
|
8860
8848
|
}
|
|
8861
8849
|
getAssetsToApprove() {
|
|
8862
8850
|
var _this = this;
|
|
8863
8851
|
return _asyncToGenerator(function* () {
|
|
8864
|
-
var asset = (0,_defisaver_tokens__WEBPACK_IMPORTED_MODULE_0__.
|
|
8865
|
-
|
|
8866
|
-
asset
|
|
8867
|
-
owner: _this.args[
|
|
8852
|
+
var asset = (0,_defisaver_tokens__WEBPACK_IMPORTED_MODULE_0__.getAssetInfo)('LUSD').address;
|
|
8853
|
+
return [{
|
|
8854
|
+
asset,
|
|
8855
|
+
owner: _this.args[1]
|
|
8868
8856
|
}];
|
|
8869
|
-
return [];
|
|
8870
8857
|
})();
|
|
8871
8858
|
}
|
|
8872
8859
|
}
|
|
8873
8860
|
|
|
8874
8861
|
/***/ }),
|
|
8875
|
-
/*
|
|
8862
|
+
/* 222 */
|
|
8876
8863
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
8877
8864
|
|
|
8878
8865
|
__webpack_require__.r(__webpack_exports__);
|
|
8879
8866
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
8880
|
-
/* harmony export */ "
|
|
8867
|
+
/* harmony export */ "BprotocolLiquitySPWithdrawAction": () => (/* binding */ BprotocolLiquitySPWithdrawAction)
|
|
8881
8868
|
/* harmony export */ });
|
|
8882
8869
|
/* harmony import */ var _Action__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1);
|
|
8883
8870
|
/* harmony import */ var _addresses__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(27);
|
|
8884
8871
|
|
|
8885
8872
|
|
|
8886
8873
|
/**
|
|
8887
|
-
*
|
|
8888
|
-
*
|
|
8889
|
-
* @
|
|
8874
|
+
* BprotocolLiquitySPWithdraw - Action that withdraws LUSD from Bprotocol
|
|
8875
|
+
* @dev LQTY rewards accrue over time and are paid out each time the user interacts with the protocol
|
|
8876
|
+
* @dev Idealy the WETH returned amount will be zero (shares paid out in LUSD in full) but depends on the protocol usage
|
|
8877
|
+
* @dev Withdraw amount can be set to zero, only LQTY reward will be claimed
|
|
8878
|
+
* @category Bprotocol
|
|
8890
8879
|
*/
|
|
8891
|
-
class
|
|
8880
|
+
class BprotocolLiquitySPWithdrawAction extends _Action__WEBPACK_IMPORTED_MODULE_0__.Action {
|
|
8892
8881
|
/**
|
|
8893
|
-
|
|
8894
|
-
|
|
8895
|
-
|
|
8896
|
-
|
|
8897
|
-
|
|
8898
|
-
|
|
8899
|
-
|
|
8900
|
-
*/
|
|
8901
|
-
constructor(emodeId, tokenAddr, amount, to) {
|
|
8902
|
-
var onBehalf = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : (0,_addresses__WEBPACK_IMPORTED_MODULE_1__.getAddr)('Empty');
|
|
8903
|
-
var withdrawAsColl = arguments.length > 5 && arguments[5] !== undefined ? arguments[5] : true;
|
|
8904
|
-
var maxIterations = arguments.length > 6 && arguments[6] !== undefined ? arguments[6] : '4';
|
|
8905
|
-
super('MorphoAaveV3Withdraw', (0,_addresses__WEBPACK_IMPORTED_MODULE_1__.getAddr)('MorphoAaveV3Withdraw'), ['uint256', 'address', 'uint256', 'address', 'address', 'bool', 'uint256'], [emodeId, tokenAddr, amount, to, onBehalf, withdrawAsColl, maxIterations]);
|
|
8906
|
-
this.mappableArgs = [this.args[0], this.args[1], this.args[2], this.args[3], this.args[4], this.args[5]];
|
|
8882
|
+
* @param shareAmount Amount of shares to burn
|
|
8883
|
+
* @param to Address that will recieve the LUSD and WETH withdrawn
|
|
8884
|
+
* @param lqtyTo Address that will recieve LQTY rewards
|
|
8885
|
+
*/
|
|
8886
|
+
constructor(shareAmount, to, lqtyTo) {
|
|
8887
|
+
super('BprotocolLiquitySPWithdraw', (0,_addresses__WEBPACK_IMPORTED_MODULE_1__.getAddr)('BprotocolLiquitySPWithdraw'), ['uint256', 'address', 'address'], [shareAmount, to, lqtyTo]);
|
|
8888
|
+
this.mappableArgs = [this.args[0], this.args[1], this.args[2]];
|
|
8907
8889
|
}
|
|
8908
8890
|
}
|
|
8909
8891
|
|
|
8910
8892
|
/***/ }),
|
|
8911
|
-
/*
|
|
8893
|
+
/* 223 */
|
|
8912
8894
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
8913
8895
|
|
|
8914
8896
|
__webpack_require__.r(__webpack_exports__);
|
|
8915
8897
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
8916
|
-
/* harmony export */ "
|
|
8898
|
+
/* harmony export */ "CurveUsdBorrowAction": () => (/* reexport safe */ _CurveUsdBorrowAction__WEBPACK_IMPORTED_MODULE_3__.CurveUsdBorrowAction),
|
|
8899
|
+
/* harmony export */ "CurveUsdCreateAction": () => (/* reexport safe */ _CurveUsdCreateAction__WEBPACK_IMPORTED_MODULE_0__.CurveUsdCreateAction),
|
|
8900
|
+
/* harmony export */ "CurveUsdPaybackAction": () => (/* reexport safe */ _CurveUsdPaybackAction__WEBPACK_IMPORTED_MODULE_4__.CurveUsdPaybackAction),
|
|
8901
|
+
/* harmony export */ "CurveUsdSupplyAction": () => (/* reexport safe */ _CurveUsdSupplyAction__WEBPACK_IMPORTED_MODULE_1__.CurveUsdSupplyAction),
|
|
8902
|
+
/* harmony export */ "CurveUsdWithdrawAction": () => (/* reexport safe */ _CurveUsdWithdrawAction__WEBPACK_IMPORTED_MODULE_2__.CurveUsdWithdrawAction)
|
|
8917
8903
|
/* harmony export */ });
|
|
8918
|
-
/* harmony import */ var
|
|
8919
|
-
/* harmony import */ var
|
|
8904
|
+
/* harmony import */ var _CurveUsdCreateAction__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(224);
|
|
8905
|
+
/* harmony import */ var _CurveUsdSupplyAction__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(227);
|
|
8906
|
+
/* harmony import */ var _CurveUsdWithdrawAction__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(228);
|
|
8907
|
+
/* harmony import */ var _CurveUsdBorrowAction__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(229);
|
|
8908
|
+
/* harmony import */ var _CurveUsdPaybackAction__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(230);
|
|
8909
|
+
|
|
8910
|
+
|
|
8911
|
+
|
|
8920
8912
|
|
|
8921
8913
|
|
|
8922
|
-
/**
|
|
8923
|
-
* MorphoAaveV3BorrowAction - Borrow token from Morpho AaveV3
|
|
8924
|
-
*
|
|
8925
|
-
* @category Morpho
|
|
8926
|
-
*/
|
|
8927
|
-
class MorphoAaveV3BorrowAction extends _Action__WEBPACK_IMPORTED_MODULE_0__.Action {
|
|
8928
|
-
/**
|
|
8929
|
-
* @param emodeId Type of emode we are entering in, each one is different deployment on Morpho
|
|
8930
|
-
* @param tokenAddr - Address of tokenAddr (underlying)
|
|
8931
|
-
* @param amount - Token amount
|
|
8932
|
-
* @param to - The address we are sending the borrowed tokens to
|
|
8933
|
-
* @param onBehalf - For what user we are borrowing the tokens, defaults to proxy
|
|
8934
|
-
* @param maxIterations - Max number of iterations for p2p matching, 0 will use default num of iterations
|
|
8935
|
-
*/
|
|
8936
|
-
constructor(emodeId, tokenAddr, amount, to) {
|
|
8937
|
-
var onBehalf = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : (0,_addresses__WEBPACK_IMPORTED_MODULE_1__.getAddr)('Empty');
|
|
8938
|
-
var maxIterations = arguments.length > 5 && arguments[5] !== undefined ? arguments[5] : '4';
|
|
8939
|
-
super('MorphoAaveV3Borrow', (0,_addresses__WEBPACK_IMPORTED_MODULE_1__.getAddr)('MorphoAaveV3Borrow'), ['uint256', 'address', 'uint256', 'address', 'address', 'uint256'], [emodeId, tokenAddr, amount, to, onBehalf, maxIterations]);
|
|
8940
|
-
this.mappableArgs = [this.args[0], this.args[1], this.args[2], this.args[3], this.args[4]];
|
|
8941
|
-
}
|
|
8942
|
-
}
|
|
8943
8914
|
|
|
8944
8915
|
/***/ }),
|
|
8945
|
-
/*
|
|
8916
|
+
/* 224 */
|
|
8946
8917
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
8947
8918
|
|
|
8948
8919
|
__webpack_require__.r(__webpack_exports__);
|
|
8949
8920
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
8950
|
-
/* harmony export */ "
|
|
8921
|
+
/* harmony export */ "CurveUsdCreateAction": () => (/* binding */ CurveUsdCreateAction)
|
|
8951
8922
|
/* harmony export */ });
|
|
8952
|
-
/* harmony import */ var
|
|
8953
|
-
/* harmony import */ var
|
|
8954
|
-
/* harmony import */ var
|
|
8955
|
-
/* harmony import */ var
|
|
8923
|
+
/* harmony import */ var _defisaver_tokens_esm_utils__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(225);
|
|
8924
|
+
/* harmony import */ var _defisaver_tokens__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6);
|
|
8925
|
+
/* harmony import */ var _defisaver_tokens__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_defisaver_tokens__WEBPACK_IMPORTED_MODULE_1__);
|
|
8926
|
+
/* harmony import */ var _Action__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1);
|
|
8927
|
+
/* harmony import */ var _utils_general__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(39);
|
|
8928
|
+
/* harmony import */ var _addresses__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(27);
|
|
8929
|
+
/* harmony import */ var _utils_curveusd_utils__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(226);
|
|
8956
8930
|
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
|
|
8957
8931
|
function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
|
|
8958
8932
|
|
|
8959
8933
|
|
|
8960
8934
|
|
|
8935
|
+
|
|
8936
|
+
|
|
8937
|
+
|
|
8938
|
+
|
|
8961
8939
|
/**
|
|
8962
|
-
*
|
|
8940
|
+
* CurveUsdCreateAction - Action that creates a curveusd position on behalf of proxy
|
|
8963
8941
|
*
|
|
8964
|
-
* @category
|
|
8942
|
+
* @category CurveUsd
|
|
8965
8943
|
*/
|
|
8966
|
-
class
|
|
8944
|
+
class CurveUsdCreateAction extends _Action__WEBPACK_IMPORTED_MODULE_2__.Action {
|
|
8967
8945
|
/**
|
|
8968
|
-
|
|
8969
|
-
|
|
8970
|
-
|
|
8971
|
-
|
|
8972
|
-
|
|
8973
|
-
|
|
8974
|
-
|
|
8975
|
-
|
|
8976
|
-
|
|
8977
|
-
|
|
8946
|
+
* address controllerAddress - Address of the curveusd market controller
|
|
8947
|
+
* address from - Address from which to pull collateral asset, will default to proxy
|
|
8948
|
+
* address to - Address that will receive the borrowed crvUSD, will default to proxy
|
|
8949
|
+
* uint256 collateralAmount - Amount of collateral asset to supply
|
|
8950
|
+
* uint256 debtAmount - Amount of crvUSD to borrow
|
|
8951
|
+
* uint256 nBands - Number of bands in which the collateral will be supplied
|
|
8952
|
+
*/
|
|
8953
|
+
/// @dev both collateralAmount and debtAmount must be non-zero and can be maxUint
|
|
8954
|
+
constructor(controllerAddress, from, to, collateralAmount, debtAmount, nBands) {
|
|
8955
|
+
(0,_utils_general__WEBPACK_IMPORTED_MODULE_3__.requireAddress)(to);
|
|
8956
|
+
super('CurveUsdCreate', (0,_addresses__WEBPACK_IMPORTED_MODULE_4__.getAddr)('CurveUsdCreate'), ['address', 'address', 'address', 'uint256', 'uint256', 'uint256'], [controllerAddress, from, to, collateralAmount, debtAmount, nBands]);
|
|
8957
|
+
this.mappableArgs = [...this.args];
|
|
8978
8958
|
}
|
|
8979
8959
|
getAssetsToApprove() {
|
|
8980
8960
|
var _this = this;
|
|
8981
8961
|
return _asyncToGenerator(function* () {
|
|
8982
|
-
|
|
8983
|
-
|
|
8984
|
-
asset:
|
|
8985
|
-
|
|
8962
|
+
return [{
|
|
8963
|
+
owner: _this.args[1],
|
|
8964
|
+
asset: (0,_defisaver_tokens__WEBPACK_IMPORTED_MODULE_1__.getAssetInfo)(Object.entries(_utils_curveusd_utils__WEBPACK_IMPORTED_MODULE_5__.curveusdMarkets).filter(_ref => {
|
|
8965
|
+
var [, {
|
|
8966
|
+
controllerAddress
|
|
8967
|
+
}] = _ref;
|
|
8968
|
+
return (0,_defisaver_tokens_esm_utils__WEBPACK_IMPORTED_MODULE_0__.compare)(controllerAddress, _this.args[0]);
|
|
8969
|
+
})[0][0]).address
|
|
8986
8970
|
}];
|
|
8987
|
-
return [];
|
|
8988
8971
|
})();
|
|
8989
8972
|
}
|
|
8990
8973
|
}
|
|
8991
8974
|
|
|
8992
8975
|
/***/ }),
|
|
8993
|
-
/*
|
|
8976
|
+
/* 225 */
|
|
8994
8977
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
8995
8978
|
|
|
8996
8979
|
__webpack_require__.r(__webpack_exports__);
|
|
8997
8980
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
8998
|
-
/* harmony export */ "
|
|
8999
|
-
/* harmony export */ "
|
|
8981
|
+
/* harmony export */ "bytesToString": () => (/* binding */ bytesToString),
|
|
8982
|
+
/* harmony export */ "compare": () => (/* binding */ compare),
|
|
8983
|
+
/* harmony export */ "stringToBytes": () => (/* binding */ stringToBytes)
|
|
9000
8984
|
/* harmony export */ });
|
|
9001
|
-
|
|
9002
|
-
|
|
8985
|
+
/**
|
|
8986
|
+
* @param hex {string}
|
|
8987
|
+
* @returns {string}
|
|
8988
|
+
*/
|
|
8989
|
+
function bytesToString(hex) {
|
|
8990
|
+
return Buffer.from(hex.replace(/^0x/, ''), 'hex')
|
|
8991
|
+
.toString()
|
|
8992
|
+
.replace(/\x00/g, '');
|
|
8993
|
+
}
|
|
8994
|
+
/**
|
|
8995
|
+
* @param str {string}
|
|
8996
|
+
* @return {string} input encoded to hex, padded to 32 bytes
|
|
8997
|
+
*/
|
|
8998
|
+
function stringToBytes(str) {
|
|
8999
|
+
let n = Buffer.from(str).toString('hex');
|
|
9000
|
+
while (n.length < 64)
|
|
9001
|
+
n = `${n}0`;
|
|
9002
|
+
return `0x${n}`;
|
|
9003
|
+
}
|
|
9004
|
+
function compare(a = '', b = '') {
|
|
9005
|
+
return a.toLowerCase() === b.toLowerCase();
|
|
9006
|
+
}
|
|
9007
|
+
|
|
9003
9008
|
|
|
9009
|
+
/***/ }),
|
|
9010
|
+
/* 226 */
|
|
9011
|
+
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9004
9012
|
|
|
9013
|
+
__webpack_require__.r(__webpack_exports__);
|
|
9014
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
9015
|
+
/* harmony export */ "controllerFactoryAddress": () => (/* binding */ controllerFactoryAddress),
|
|
9016
|
+
/* harmony export */ "curveusdMarkets": () => (/* binding */ curveusdMarkets)
|
|
9017
|
+
/* harmony export */ });
|
|
9018
|
+
/// @dev debtAvailableBlock is only used in v3-contracts repo
|
|
9019
|
+
var curveusdMarkets = {
|
|
9020
|
+
sfrxETH: {
|
|
9021
|
+
controllerAddress: '0x8472a9a7632b173c8cf3a86d3afec50c35548e76',
|
|
9022
|
+
debtAvailableBlock: 17425859
|
|
9023
|
+
},
|
|
9024
|
+
wstETH: {
|
|
9025
|
+
controllerAddress: '0x100dAa78fC509Db39Ef7D04DE0c1ABD299f4C6CE'
|
|
9026
|
+
}
|
|
9027
|
+
};
|
|
9028
|
+
var controllerFactoryAddress = '0xC9332fdCB1C491Dcc683bAe86Fe3cb70360738BC';
|
|
9005
9029
|
|
|
9006
9030
|
/***/ }),
|
|
9007
|
-
/*
|
|
9031
|
+
/* 227 */
|
|
9008
9032
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9009
9033
|
|
|
9010
9034
|
__webpack_require__.r(__webpack_exports__);
|
|
9011
9035
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
9012
|
-
/* harmony export */ "
|
|
9036
|
+
/* harmony export */ "CurveUsdSupplyAction": () => (/* binding */ CurveUsdSupplyAction)
|
|
9013
9037
|
/* harmony export */ });
|
|
9014
|
-
/* harmony import */ var
|
|
9015
|
-
/* harmony import */ var
|
|
9016
|
-
/* harmony import */ var
|
|
9017
|
-
/* harmony import */ var
|
|
9038
|
+
/* harmony import */ var _defisaver_tokens_esm_utils__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(225);
|
|
9039
|
+
/* harmony import */ var _defisaver_tokens__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6);
|
|
9040
|
+
/* harmony import */ var _defisaver_tokens__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_defisaver_tokens__WEBPACK_IMPORTED_MODULE_1__);
|
|
9041
|
+
/* harmony import */ var _Action__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1);
|
|
9042
|
+
/* harmony import */ var _addresses__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(27);
|
|
9043
|
+
/* harmony import */ var _utils_curveusd_utils__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(226);
|
|
9018
9044
|
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
|
|
9019
9045
|
function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
|
|
9020
9046
|
|
|
9021
9047
|
|
|
9022
9048
|
|
|
9049
|
+
|
|
9050
|
+
|
|
9051
|
+
|
|
9023
9052
|
/**
|
|
9024
|
-
*
|
|
9025
|
-
*
|
|
9026
|
-
* @
|
|
9027
|
-
* @category Bprotocol
|
|
9053
|
+
* CurveUsdSupplyAction - Action that supplies collateral to a curveusd position
|
|
9054
|
+
*
|
|
9055
|
+
* @category CurveUsd
|
|
9028
9056
|
*/
|
|
9029
|
-
class
|
|
9057
|
+
class CurveUsdSupplyAction extends _Action__WEBPACK_IMPORTED_MODULE_2__.Action {
|
|
9030
9058
|
/**
|
|
9031
|
-
*
|
|
9032
|
-
*
|
|
9033
|
-
*
|
|
9059
|
+
* address controllerAddress - Address of the curveusd market controller
|
|
9060
|
+
* address from - Address from which to pull collateral asset, will default to proxy
|
|
9061
|
+
* address onBehalfOf - Address for which we are supplying, will default to proxy
|
|
9062
|
+
* uint256 collateralAmount - Amount of collateral asset to supply
|
|
9034
9063
|
*/
|
|
9035
|
-
|
|
9036
|
-
|
|
9037
|
-
|
|
9064
|
+
/// @dev collateralAmount must be non-zero, can be maxUint
|
|
9065
|
+
constructor(controllerAddress, from, onBehalfOf, collateralAmount) {
|
|
9066
|
+
super('CurveUsdSupply', (0,_addresses__WEBPACK_IMPORTED_MODULE_3__.getAddr)('CurveUsdSupply'), ['address', 'address', 'address', 'uint256'], [controllerAddress, from, onBehalfOf, collateralAmount]);
|
|
9067
|
+
this.mappableArgs = [...this.args];
|
|
9038
9068
|
}
|
|
9039
9069
|
getAssetsToApprove() {
|
|
9040
9070
|
var _this = this;
|
|
9041
9071
|
return _asyncToGenerator(function* () {
|
|
9042
|
-
var asset = (0,_defisaver_tokens__WEBPACK_IMPORTED_MODULE_0__.getAssetInfo)('LUSD').address;
|
|
9043
9072
|
return [{
|
|
9044
|
-
|
|
9045
|
-
|
|
9073
|
+
owner: _this.args[1],
|
|
9074
|
+
asset: (0,_defisaver_tokens__WEBPACK_IMPORTED_MODULE_1__.getAssetInfo)(Object.entries(_utils_curveusd_utils__WEBPACK_IMPORTED_MODULE_4__.curveusdMarkets).filter(_ref => {
|
|
9075
|
+
var [, {
|
|
9076
|
+
controllerAddress
|
|
9077
|
+
}] = _ref;
|
|
9078
|
+
return (0,_defisaver_tokens_esm_utils__WEBPACK_IMPORTED_MODULE_0__.compare)(controllerAddress, _this.args[0]);
|
|
9079
|
+
})[0][0]).address
|
|
9046
9080
|
}];
|
|
9047
9081
|
})();
|
|
9048
9082
|
}
|
|
9049
9083
|
}
|
|
9050
9084
|
|
|
9051
9085
|
/***/ }),
|
|
9052
|
-
/*
|
|
9086
|
+
/* 228 */
|
|
9053
9087
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9054
9088
|
|
|
9055
9089
|
__webpack_require__.r(__webpack_exports__);
|
|
9056
9090
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
9057
|
-
/* harmony export */ "
|
|
9091
|
+
/* harmony export */ "CurveUsdWithdrawAction": () => (/* binding */ CurveUsdWithdrawAction)
|
|
9058
9092
|
/* harmony export */ });
|
|
9059
9093
|
/* harmony import */ var _Action__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1);
|
|
9060
9094
|
/* harmony import */ var _addresses__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(27);
|
|
9061
9095
|
|
|
9062
9096
|
|
|
9063
9097
|
/**
|
|
9064
|
-
*
|
|
9065
|
-
*
|
|
9066
|
-
* @
|
|
9067
|
-
* @dev Withdraw amount can be set to zero, only LQTY reward will be claimed
|
|
9068
|
-
* @category Bprotocol
|
|
9098
|
+
* CurveUsdWithdrawAction - Action that withdraws collateral from proxy curveusd position
|
|
9099
|
+
*
|
|
9100
|
+
* @category CurveUsd
|
|
9069
9101
|
*/
|
|
9070
|
-
class
|
|
9102
|
+
class CurveUsdWithdrawAction extends _Action__WEBPACK_IMPORTED_MODULE_0__.Action {
|
|
9071
9103
|
/**
|
|
9072
|
-
*
|
|
9073
|
-
*
|
|
9074
|
-
*
|
|
9104
|
+
* address controllerAddress - Address of the curveusd market controller
|
|
9105
|
+
* address to - Address that will receive the withdrawn collateral, will default to proxy
|
|
9106
|
+
* uint256 collateralAmount - Amount of collateral to withdraw
|
|
9075
9107
|
*/
|
|
9076
|
-
|
|
9077
|
-
|
|
9078
|
-
|
|
9108
|
+
/// @dev collateralAmount must be non-zero
|
|
9109
|
+
/// @dev if collateralAmount == uintMax will withdraw as much as the debt will allow
|
|
9110
|
+
constructor(controllerAddress, to, collateralAmount) {
|
|
9111
|
+
super('CurveUsdSupply', (0,_addresses__WEBPACK_IMPORTED_MODULE_1__.getAddr)('CurveUsdSupply'), ['address', 'address', 'uint256'], [controllerAddress, to, collateralAmount]);
|
|
9112
|
+
this.mappableArgs = [...this.args];
|
|
9079
9113
|
}
|
|
9080
9114
|
}
|
|
9081
9115
|
|
|
9082
9116
|
/***/ }),
|
|
9083
|
-
/*
|
|
9117
|
+
/* 229 */
|
|
9118
|
+
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9119
|
+
|
|
9120
|
+
__webpack_require__.r(__webpack_exports__);
|
|
9121
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
9122
|
+
/* harmony export */ "CurveUsdBorrowAction": () => (/* binding */ CurveUsdBorrowAction)
|
|
9123
|
+
/* harmony export */ });
|
|
9124
|
+
/* harmony import */ var _Action__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1);
|
|
9125
|
+
/* harmony import */ var _addresses__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(27);
|
|
9126
|
+
|
|
9127
|
+
|
|
9128
|
+
/**
|
|
9129
|
+
* CurveUsdBorrowAction - Action that borrows crvUSD from proxy curveusd position
|
|
9130
|
+
*
|
|
9131
|
+
* @category CurveUsd
|
|
9132
|
+
*/
|
|
9133
|
+
class CurveUsdBorrowAction extends _Action__WEBPACK_IMPORTED_MODULE_0__.Action {
|
|
9134
|
+
/**
|
|
9135
|
+
* address controllerAddress - Address of the curveusd market controller
|
|
9136
|
+
* address to - Address that will receive the borrowed crvUSD, will default to proxy
|
|
9137
|
+
* uint256 debtAmount - Amount of crvUSD to borrow
|
|
9138
|
+
*/
|
|
9139
|
+
/// @dev debtAmount must be non-zero
|
|
9140
|
+
/// @dev if debtAmount == uintMax will borrow as much as the collateral will support
|
|
9141
|
+
constructor(controllerAddress, to, debtAmount) {
|
|
9142
|
+
super('CurveUsdBorrow', (0,_addresses__WEBPACK_IMPORTED_MODULE_1__.getAddr)('CurveUsdBorrow'), ['address', 'address', 'uint256'], [controllerAddress, to, debtAmount]);
|
|
9143
|
+
this.mappableArgs = [...this.args];
|
|
9144
|
+
}
|
|
9145
|
+
}
|
|
9146
|
+
|
|
9147
|
+
/***/ }),
|
|
9148
|
+
/* 230 */
|
|
9149
|
+
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9150
|
+
|
|
9151
|
+
__webpack_require__.r(__webpack_exports__);
|
|
9152
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
9153
|
+
/* harmony export */ "CurveUsdPaybackAction": () => (/* binding */ CurveUsdPaybackAction)
|
|
9154
|
+
/* harmony export */ });
|
|
9155
|
+
/* harmony import */ var _defisaver_tokens__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6);
|
|
9156
|
+
/* harmony import */ var _defisaver_tokens__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_defisaver_tokens__WEBPACK_IMPORTED_MODULE_0__);
|
|
9157
|
+
/* harmony import */ var _Action__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1);
|
|
9158
|
+
/* harmony import */ var _addresses__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(27);
|
|
9159
|
+
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
|
|
9160
|
+
function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
|
|
9161
|
+
|
|
9162
|
+
|
|
9163
|
+
|
|
9164
|
+
/**
|
|
9165
|
+
* CurveUsdPaybackAction - Action that pays back crvUSD to a curveusd position
|
|
9166
|
+
*
|
|
9167
|
+
* @category CurveUsd
|
|
9168
|
+
*/
|
|
9169
|
+
class CurveUsdPaybackAction extends _Action__WEBPACK_IMPORTED_MODULE_1__.Action {
|
|
9170
|
+
/**
|
|
9171
|
+
* address controllerAddress - Address of the curveusd market controller
|
|
9172
|
+
* address from - Address from which to pull crvUSD, will default to proxy
|
|
9173
|
+
* address onBehalfOf - Address for which we are paying back debt, will default to proxy
|
|
9174
|
+
* address to - Address that will receive the crvUSD and collateral asset if close, will default to proxy
|
|
9175
|
+
* uint256 debtAmount - Amount of crvUSD to payback
|
|
9176
|
+
* int256 maxActiveBand - Don't allow active band to be higher than this (to prevent front-running the repay)
|
|
9177
|
+
*/
|
|
9178
|
+
/// @dev debtAmount must be non-zero
|
|
9179
|
+
/// @dev if debtAmount >= debt will repay whole debt and close the position, transfering collateral
|
|
9180
|
+
constructor(controllerAddress, from, onBehalfOf, to, debtAmount, maxActiveBand) {
|
|
9181
|
+
super('CurveUsdBorrow', (0,_addresses__WEBPACK_IMPORTED_MODULE_2__.getAddr)('CurveUsdBorrow'), ['address', 'address', 'address', 'address', 'uint256', 'int256'], [controllerAddress, from, onBehalfOf, to, debtAmount, maxActiveBand]);
|
|
9182
|
+
this.mappableArgs = [...this.args];
|
|
9183
|
+
}
|
|
9184
|
+
getAssetsToApprove() {
|
|
9185
|
+
var _this = this;
|
|
9186
|
+
return _asyncToGenerator(function* () {
|
|
9187
|
+
return [{
|
|
9188
|
+
owner: _this.args[1],
|
|
9189
|
+
asset: (0,_defisaver_tokens__WEBPACK_IMPORTED_MODULE_0__.getAssetInfo)('crvUSD').address
|
|
9190
|
+
}];
|
|
9191
|
+
})();
|
|
9192
|
+
}
|
|
9193
|
+
}
|
|
9194
|
+
|
|
9195
|
+
/***/ }),
|
|
9196
|
+
/* 231 */
|
|
9084
9197
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9085
9198
|
|
|
9086
9199
|
__webpack_require__.r(__webpack_exports__);
|
|
@@ -9099,19 +9212,19 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
9099
9212
|
/* harmony export */ "TrailingStopTrigger": () => (/* reexport safe */ _TrailingStopTrigger__WEBPACK_IMPORTED_MODULE_10__.TrailingStopTrigger),
|
|
9100
9213
|
/* harmony export */ "UniV3CurrentTickTrigger": () => (/* reexport safe */ _UniV3CurrentTickTrigger__WEBPACK_IMPORTED_MODULE_2__.UniV3CurrentTickTrigger)
|
|
9101
9214
|
/* harmony export */ });
|
|
9102
|
-
/* harmony import */ var _MakerRatioTrigger__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
|
|
9103
|
-
/* harmony import */ var _ChainLinkPriceTrigger__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
|
|
9104
|
-
/* harmony import */ var _UniV3CurrentTickTrigger__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
|
|
9105
|
-
/* harmony import */ var _TimestampTrigger__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
|
|
9106
|
-
/* harmony import */ var _GasPriceTrigger__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
|
|
9107
|
-
/* harmony import */ var _CompoundRatioTrigger__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(
|
|
9108
|
-
/* harmony import */ var _ReflexerRatioTrigger__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(
|
|
9109
|
-
/* harmony import */ var _LiquityRatioTrigger__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(
|
|
9110
|
-
/* harmony import */ var _AaveV3RatioTrigger__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(
|
|
9111
|
-
/* harmony import */ var _CompV3RatioTrigger__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(
|
|
9112
|
-
/* harmony import */ var _TrailingStopTrigger__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(
|
|
9113
|
-
/* harmony import */ var _CBRebondTrigger__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(
|
|
9114
|
-
/* harmony import */ var _AaveV3QuotePriceTrigger__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(
|
|
9215
|
+
/* harmony import */ var _MakerRatioTrigger__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(232);
|
|
9216
|
+
/* harmony import */ var _ChainLinkPriceTrigger__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(233);
|
|
9217
|
+
/* harmony import */ var _UniV3CurrentTickTrigger__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(234);
|
|
9218
|
+
/* harmony import */ var _TimestampTrigger__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(235);
|
|
9219
|
+
/* harmony import */ var _GasPriceTrigger__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(236);
|
|
9220
|
+
/* harmony import */ var _CompoundRatioTrigger__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(237);
|
|
9221
|
+
/* harmony import */ var _ReflexerRatioTrigger__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(238);
|
|
9222
|
+
/* harmony import */ var _LiquityRatioTrigger__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(239);
|
|
9223
|
+
/* harmony import */ var _AaveV3RatioTrigger__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(240);
|
|
9224
|
+
/* harmony import */ var _CompV3RatioTrigger__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(241);
|
|
9225
|
+
/* harmony import */ var _TrailingStopTrigger__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(242);
|
|
9226
|
+
/* harmony import */ var _CBRebondTrigger__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(243);
|
|
9227
|
+
/* harmony import */ var _AaveV3QuotePriceTrigger__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(244);
|
|
9115
9228
|
|
|
9116
9229
|
|
|
9117
9230
|
|
|
@@ -9127,7 +9240,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
9127
9240
|
|
|
9128
9241
|
|
|
9129
9242
|
/***/ }),
|
|
9130
|
-
/*
|
|
9243
|
+
/* 232 */
|
|
9131
9244
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9132
9245
|
|
|
9133
9246
|
__webpack_require__.r(__webpack_exports__);
|
|
@@ -9150,7 +9263,7 @@ class MakerRatioTrigger extends _Action__WEBPACK_IMPORTED_MODULE_0__.Action {
|
|
|
9150
9263
|
}
|
|
9151
9264
|
|
|
9152
9265
|
/***/ }),
|
|
9153
|
-
/*
|
|
9266
|
+
/* 233 */
|
|
9154
9267
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9155
9268
|
|
|
9156
9269
|
__webpack_require__.r(__webpack_exports__);
|
|
@@ -9173,7 +9286,7 @@ class ChainLinkPriceTrigger extends _Action__WEBPACK_IMPORTED_MODULE_0__.Action
|
|
|
9173
9286
|
}
|
|
9174
9287
|
|
|
9175
9288
|
/***/ }),
|
|
9176
|
-
/*
|
|
9289
|
+
/* 234 */
|
|
9177
9290
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9178
9291
|
|
|
9179
9292
|
__webpack_require__.r(__webpack_exports__);
|
|
@@ -9196,7 +9309,7 @@ class UniV3CurrentTickTrigger extends _Action__WEBPACK_IMPORTED_MODULE_0__.Actio
|
|
|
9196
9309
|
}
|
|
9197
9310
|
|
|
9198
9311
|
/***/ }),
|
|
9199
|
-
/*
|
|
9312
|
+
/* 235 */
|
|
9200
9313
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9201
9314
|
|
|
9202
9315
|
__webpack_require__.r(__webpack_exports__);
|
|
@@ -9219,7 +9332,7 @@ class TimestampTrigger extends _Action__WEBPACK_IMPORTED_MODULE_0__.Action {
|
|
|
9219
9332
|
}
|
|
9220
9333
|
|
|
9221
9334
|
/***/ }),
|
|
9222
|
-
/*
|
|
9335
|
+
/* 236 */
|
|
9223
9336
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9224
9337
|
|
|
9225
9338
|
__webpack_require__.r(__webpack_exports__);
|
|
@@ -9242,7 +9355,7 @@ class GasPriceTrigger extends _Action__WEBPACK_IMPORTED_MODULE_0__.Action {
|
|
|
9242
9355
|
}
|
|
9243
9356
|
|
|
9244
9357
|
/***/ }),
|
|
9245
|
-
/*
|
|
9358
|
+
/* 237 */
|
|
9246
9359
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9247
9360
|
|
|
9248
9361
|
__webpack_require__.r(__webpack_exports__);
|
|
@@ -9265,7 +9378,7 @@ class CompoundRatioTrigger extends _Action__WEBPACK_IMPORTED_MODULE_0__.Action {
|
|
|
9265
9378
|
}
|
|
9266
9379
|
|
|
9267
9380
|
/***/ }),
|
|
9268
|
-
/*
|
|
9381
|
+
/* 238 */
|
|
9269
9382
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9270
9383
|
|
|
9271
9384
|
__webpack_require__.r(__webpack_exports__);
|
|
@@ -9288,7 +9401,7 @@ class ReflexerRatioTrigger extends _Action__WEBPACK_IMPORTED_MODULE_0__.Action {
|
|
|
9288
9401
|
}
|
|
9289
9402
|
|
|
9290
9403
|
/***/ }),
|
|
9291
|
-
/*
|
|
9404
|
+
/* 239 */
|
|
9292
9405
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9293
9406
|
|
|
9294
9407
|
__webpack_require__.r(__webpack_exports__);
|
|
@@ -9311,7 +9424,7 @@ class LiquityRatioTrigger extends _Action__WEBPACK_IMPORTED_MODULE_0__.Action {
|
|
|
9311
9424
|
}
|
|
9312
9425
|
|
|
9313
9426
|
/***/ }),
|
|
9314
|
-
/*
|
|
9427
|
+
/* 240 */
|
|
9315
9428
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9316
9429
|
|
|
9317
9430
|
__webpack_require__.r(__webpack_exports__);
|
|
@@ -9334,7 +9447,7 @@ class AaveV3RatioTrigger extends _Action__WEBPACK_IMPORTED_MODULE_0__.Action {
|
|
|
9334
9447
|
}
|
|
9335
9448
|
|
|
9336
9449
|
/***/ }),
|
|
9337
|
-
/*
|
|
9450
|
+
/* 241 */
|
|
9338
9451
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9339
9452
|
|
|
9340
9453
|
__webpack_require__.r(__webpack_exports__);
|
|
@@ -9357,7 +9470,7 @@ class CompV3RatioTrigger extends _Action__WEBPACK_IMPORTED_MODULE_0__.Action {
|
|
|
9357
9470
|
}
|
|
9358
9471
|
|
|
9359
9472
|
/***/ }),
|
|
9360
|
-
/*
|
|
9473
|
+
/* 242 */
|
|
9361
9474
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9362
9475
|
|
|
9363
9476
|
__webpack_require__.r(__webpack_exports__);
|
|
@@ -9380,7 +9493,7 @@ class TrailingStopTrigger extends _Action__WEBPACK_IMPORTED_MODULE_0__.Action {
|
|
|
9380
9493
|
}
|
|
9381
9494
|
|
|
9382
9495
|
/***/ }),
|
|
9383
|
-
/*
|
|
9496
|
+
/* 243 */
|
|
9384
9497
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9385
9498
|
|
|
9386
9499
|
__webpack_require__.r(__webpack_exports__);
|
|
@@ -9403,7 +9516,7 @@ class CBRebondTrigger extends _Action__WEBPACK_IMPORTED_MODULE_0__.Action {
|
|
|
9403
9516
|
}
|
|
9404
9517
|
|
|
9405
9518
|
/***/ }),
|
|
9406
|
-
/*
|
|
9519
|
+
/* 244 */
|
|
9407
9520
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9408
9521
|
|
|
9409
9522
|
__webpack_require__.r(__webpack_exports__);
|
|
@@ -9426,24 +9539,27 @@ class AaveV3QuotePriceTrigger extends _Action__WEBPACK_IMPORTED_MODULE_0__.Actio
|
|
|
9426
9539
|
}
|
|
9427
9540
|
|
|
9428
9541
|
/***/ }),
|
|
9429
|
-
/*
|
|
9542
|
+
/* 245 */
|
|
9430
9543
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9431
9544
|
|
|
9432
9545
|
__webpack_require__.r(__webpack_exports__);
|
|
9433
9546
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
9434
9547
|
/* harmony export */ "convexUtils": () => (/* reexport module object */ _convex_utils__WEBPACK_IMPORTED_MODULE_3__),
|
|
9435
9548
|
/* harmony export */ "curveUtils": () => (/* reexport module object */ _curve_utils__WEBPACK_IMPORTED_MODULE_5__),
|
|
9549
|
+
/* harmony export */ "curveusdUtils": () => (/* reexport module object */ _curveusd_utils__WEBPACK_IMPORTED_MODULE_6__),
|
|
9436
9550
|
/* harmony export */ "mstableAssetPairs": () => (/* reexport safe */ _mstableAssetPairs__WEBPACK_IMPORTED_MODULE_4__["default"]),
|
|
9437
9551
|
/* harmony export */ "uniswapLP": () => (/* reexport module object */ _uniswapLP__WEBPACK_IMPORTED_MODULE_1__),
|
|
9438
9552
|
/* harmony export */ "uniswapV3LP": () => (/* reexport module object */ _uniswapV3LP__WEBPACK_IMPORTED_MODULE_2__),
|
|
9439
9553
|
/* harmony export */ "zeroExExchange": () => (/* reexport module object */ _zeroExExchange__WEBPACK_IMPORTED_MODULE_0__)
|
|
9440
9554
|
/* harmony export */ });
|
|
9441
|
-
/* harmony import */ var _zeroExExchange__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
|
|
9555
|
+
/* harmony import */ var _zeroExExchange__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(246);
|
|
9442
9556
|
/* harmony import */ var _uniswapLP__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(104);
|
|
9443
|
-
/* harmony import */ var _uniswapV3LP__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
|
|
9557
|
+
/* harmony import */ var _uniswapV3LP__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(248);
|
|
9444
9558
|
/* harmony import */ var _convex_utils__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(194);
|
|
9445
9559
|
/* harmony import */ var _mstableAssetPairs__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(176);
|
|
9446
9560
|
/* harmony import */ var _curve_utils__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(162);
|
|
9561
|
+
/* harmony import */ var _curveusd_utils__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(226);
|
|
9562
|
+
|
|
9447
9563
|
|
|
9448
9564
|
|
|
9449
9565
|
|
|
@@ -9453,7 +9569,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
9453
9569
|
|
|
9454
9570
|
|
|
9455
9571
|
/***/ }),
|
|
9456
|
-
/*
|
|
9572
|
+
/* 246 */
|
|
9457
9573
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9458
9574
|
|
|
9459
9575
|
__webpack_require__.r(__webpack_exports__);
|
|
@@ -9464,7 +9580,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
9464
9580
|
/* harmony export */ });
|
|
9465
9581
|
/* harmony import */ var decimal_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5);
|
|
9466
9582
|
/* harmony import */ var decimal_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(decimal_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
9467
|
-
/* harmony import */ var axios__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
|
|
9583
|
+
/* harmony import */ var axios__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(247);
|
|
9468
9584
|
/* harmony import */ var axios__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(axios__WEBPACK_IMPORTED_MODULE_1__);
|
|
9469
9585
|
/* harmony import */ var _defisaver_tokens__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6);
|
|
9470
9586
|
/* harmony import */ var _defisaver_tokens__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_defisaver_tokens__WEBPACK_IMPORTED_MODULE_2__);
|
|
@@ -9667,20 +9783,20 @@ var createSellAction = /*#__PURE__*/function () {
|
|
|
9667
9783
|
}();
|
|
9668
9784
|
|
|
9669
9785
|
/***/ }),
|
|
9670
|
-
/*
|
|
9786
|
+
/* 247 */
|
|
9671
9787
|
/***/ ((module) => {
|
|
9672
9788
|
|
|
9673
|
-
module.exports =
|
|
9789
|
+
module.exports = __WEBPACK_EXTERNAL_MODULE__247__;
|
|
9674
9790
|
|
|
9675
9791
|
/***/ }),
|
|
9676
|
-
/*
|
|
9792
|
+
/* 248 */
|
|
9677
9793
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9678
9794
|
|
|
9679
9795
|
__webpack_require__.r(__webpack_exports__);
|
|
9680
9796
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
9681
9797
|
/* harmony export */ "getAssetAddrByTokenId": () => (/* binding */ getAssetAddrByTokenId)
|
|
9682
9798
|
/* harmony export */ });
|
|
9683
|
-
/* harmony import */ var _abis_UniV3PositionManager_json__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
|
|
9799
|
+
/* harmony import */ var _abis_UniV3PositionManager_json__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(249);
|
|
9684
9800
|
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
|
|
9685
9801
|
function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
|
|
9686
9802
|
/**
|
|
@@ -9705,7 +9821,7 @@ var getAssetAddrByTokenId = /*#__PURE__*/function () {
|
|
|
9705
9821
|
}();
|
|
9706
9822
|
|
|
9707
9823
|
/***/ }),
|
|
9708
|
-
/*
|
|
9824
|
+
/* 249 */
|
|
9709
9825
|
/***/ ((module) => {
|
|
9710
9826
|
|
|
9711
9827
|
module.exports = JSON.parse('[{"constant":false,"inputs":[{"name":"tokenId","type":"uint256"}],"name":"positions","outputs":[{"name":"nonce","type":"uint96"},{"name":"operator","type":"address"},{"name":"token0","type":"address"},{"name":"token1","type":"address"},{"name":"fee","type":"uint24"},{"name":"tickLower","type":"int24"},{"name":"tickUpper","type":"int24"},{"name":"liquidity","type":"uint128"},{"name":"feeGrowthInside0LastX128","type":"uint256"},{"name":"feeGrowthInside1LastX128","type":"uint256"},{"name":"tokensOwed0","type":"uint128"},{"name":"tokensOwed1","type":"uint128"}],"payable":false,"stateMutability":"view","type":"function"}]');
|
|
@@ -9809,8 +9925,8 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
9809
9925
|
/* harmony import */ var _Strategy__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(29);
|
|
9810
9926
|
/* harmony import */ var _DfsWeb3__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(30);
|
|
9811
9927
|
/* harmony import */ var _actions__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(35);
|
|
9812
|
-
/* harmony import */ var _triggers__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(
|
|
9813
|
-
/* harmony import */ var _utils__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(
|
|
9928
|
+
/* harmony import */ var _triggers__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(231);
|
|
9929
|
+
/* harmony import */ var _utils__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(245);
|
|
9814
9930
|
/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(4);
|
|
9815
9931
|
/* harmony import */ var _addresses__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(27);
|
|
9816
9932
|
/* Export types here */
|