Merge pull request #27 from Instadapp/avalanche

Avalanche Support
This commit is contained in:
Samyak Jain 2021-11-04 05:26:12 +05:30 committed by GitHub
commit a2b22db828
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
23 changed files with 474 additions and 197 deletions

View File

@ -1,168 +1,196 @@
[{
"inputs": [{
"internalType": "address",
"name": "user",
"type": "address"
}, {
"internalType": "address[]",
"name": "tokens",
"type": "address[]"
}],
[
{
"type": "function",
"stateMutability": "view",
"outputs": [
{
"type": "tuple[]",
"name": "",
"internalType": "struct AaveHelpers.AaveUserTokenData[]",
"components": [
{
"type": "uint256",
"name": "tokenPriceInEth",
"internalType": "uint256"
},
{
"type": "uint256",
"name": "tokenPriceInUsd",
"internalType": "uint256"
},
{
"type": "uint256",
"name": "supplyBalance",
"internalType": "uint256"
},
{
"type": "uint256",
"name": "stableBorrowBalance",
"internalType": "uint256"
},
{
"type": "uint256",
"name": "variableBorrowBalance",
"internalType": "uint256"
},
{
"type": "uint256",
"name": "supplyRate",
"internalType": "uint256"
},
{
"type": "uint256",
"name": "stableBorrowRate",
"internalType": "uint256"
},
{
"type": "uint256",
"name": "userStableBorrowRate",
"internalType": "uint256"
},
{
"type": "uint256",
"name": "variableBorrowRate",
"internalType": "uint256"
},
{ "type": "bool", "name": "isCollateral", "internalType": "bool" },
{
"type": "tuple",
"name": "aaveTokenData",
"internalType": "struct AaveHelpers.AaveTokenData",
"components": [
{ "type": "uint256", "name": "ltv", "internalType": "uint256" },
{
"type": "uint256",
"name": "threshold",
"internalType": "uint256"
},
{
"type": "uint256",
"name": "reserveFactor",
"internalType": "uint256"
},
{
"type": "bool",
"name": "usageAsCollEnabled",
"internalType": "bool"
},
{
"type": "bool",
"name": "borrowEnabled",
"internalType": "bool"
},
{
"type": "bool",
"name": "stableBorrowEnabled",
"internalType": "bool"
},
{ "type": "bool", "name": "isActive", "internalType": "bool" },
{ "type": "bool", "name": "isFrozen", "internalType": "bool" },
{
"type": "uint256",
"name": "totalSupply",
"internalType": "uint256"
},
{
"type": "uint256",
"name": "availableLiquidity",
"internalType": "uint256"
},
{
"type": "uint256",
"name": "totalStableDebt",
"internalType": "uint256"
},
{
"type": "uint256",
"name": "totalVariableDebt",
"internalType": "uint256"
},
{
"type": "uint256",
"name": "collateralEmission",
"internalType": "uint256"
},
{
"type": "uint256",
"name": "debtEmission",
"internalType": "uint256"
},
{
"type": "address",
"name": "aTokenAddress",
"internalType": "address"
},
{
"type": "address",
"name": "stableDebtTokenAddress",
"internalType": "address"
},
{
"type": "address",
"name": "variableDebtTokenAddress",
"internalType": "address"
}
]
}
]
},
{
"type": "tuple",
"name": "",
"internalType": "struct AaveHelpers.AaveUserData",
"components": [
{
"type": "uint256",
"name": "totalCollateralETH",
"internalType": "uint256"
},
{
"type": "uint256",
"name": "totalBorrowsETH",
"internalType": "uint256"
},
{
"type": "uint256",
"name": "availableBorrowsETH",
"internalType": "uint256"
},
{
"type": "uint256",
"name": "currentLiquidationThreshold",
"internalType": "uint256"
},
{ "type": "uint256", "name": "ltv", "internalType": "uint256" },
{
"type": "uint256",
"name": "healthFactor",
"internalType": "uint256"
},
{
"type": "uint256",
"name": "ethPriceInUsd",
"internalType": "uint256"
},
{
"type": "uint256",
"name": "pendingRewards",
"internalType": "uint256"
}
]
}
],
"name": "getPosition",
"outputs": [{
"components": [{
"internalType": "uint256",
"name": "tokenPriceInEth",
"type": "uint256"
}, {
"internalType": "uint256",
"name": "tokenPriceInUsd",
"type": "uint256"
}, {
"internalType": "uint256",
"name": "supplyBalance",
"type": "uint256"
}, {
"internalType": "uint256",
"name": "stableBorrowBalance",
"type": "uint256"
}, {
"internalType": "uint256",
"name": "variableBorrowBalance",
"type": "uint256"
}, {
"internalType": "uint256",
"name": "supplyRate",
"type": "uint256"
}, {
"internalType": "uint256",
"name": "stableBorrowRate",
"type": "uint256"
}, {
"internalType": "uint256",
"name": "userStableBorrowRate",
"type": "uint256"
}, {
"internalType": "uint256",
"name": "variableBorrowRate",
"type": "uint256"
}, {
"internalType": "bool",
"name": "isCollateral",
"type": "bool"
}, {
"components": [{
"internalType": "uint256",
"name": "ltv",
"type": "uint256"
}, {
"internalType": "uint256",
"name": "threshold",
"type": "uint256"
}, {
"internalType": "uint256",
"name": "reserveFactor",
"type": "uint256"
}, {
"internalType": "bool",
"name": "usageAsCollEnabled",
"type": "bool"
}, {
"internalType": "bool",
"name": "borrowEnabled",
"type": "bool"
}, {
"internalType": "bool",
"name": "stableBorrowEnabled",
"type": "bool"
}, {
"internalType": "bool",
"name": "isActive",
"type": "bool"
}, {
"internalType": "bool",
"name": "isFrozen",
"type": "bool"
}, {
"internalType": "uint256",
"name": "totalSupply",
"type": "uint256"
}, {
"internalType": "uint256",
"name": "availableLiquidity",
"type": "uint256"
}, {
"internalType": "uint256",
"name": "totalStableDebt",
"type": "uint256"
}, {
"internalType": "uint256",
"name": "totalVariableDebt",
"type": "uint256"
}, {
"internalType": "uint256",
"name": "collateralEmission",
"type": "uint256"
}, {
"internalType": "uint256",
"name": "debtEmission",
"type": "uint256"
}],
"internalType": "struct AaveHelpers.AaveTokenData",
"name": "aaveTokenData",
"type": "tuple"
}],
"internalType": "struct AaveHelpers.AaveUserTokenData[]",
"name": "",
"type": "tuple[]"
}, {
"components": [{
"internalType": "uint256",
"name": "totalCollateralETH",
"type": "uint256"
}, {
"internalType": "uint256",
"name": "totalBorrowsETH",
"type": "uint256"
}, {
"internalType": "uint256",
"name": "availableBorrowsETH",
"type": "uint256"
}, {
"internalType": "uint256",
"name": "currentLiquidationThreshold",
"type": "uint256"
}, {
"internalType": "uint256",
"name": "ltv",
"type": "uint256"
}, {
"internalType": "uint256",
"name": "healthFactor",
"type": "uint256"
}, {
"internalType": "uint256",
"name": "ethPriceInUsd",
"type": "uint256"
}, {
"internalType": "uint256",
"name": "pendingRewards",
"type": "uint256"
}],
"internalType": "struct AaveHelpers.AaveUserData",
"name": "",
"type": "tuple"
}],
"inputs": [
{ "type": "address", "name": "user", "internalType": "address" },
{ "type": "address[]", "name": "tokens", "internalType": "address[]" }
]
},
{
"type": "function",
"stateMutability": "view",
"type": "function"
}, {
"inputs": [],
"outputs": [{ "type": "string", "name": "", "internalType": "string" }],
"name": "name",
"outputs": [{
"internalType": "string",
"name": "",
"type": "string"
}],
"stateMutability": "view",
"type": "function"
}]
"inputs": []
}
]

View File

@ -0,0 +1,5 @@
<svg viewBox="0 0 600 600" fill="none" xmlns="http://www.w3.org/2000/svg">
<path fill-rule="evenodd" clip-rule="evenodd"
d="M213.174 435H145.633C129.619 435 121.612 435 116.817 431.953C111.634 428.66 108.364 423.134 108.018 417.084C107.697 411.485 111.663 404.658 119.594 391.006L119.598 391.001L267.476 136.454C275.524 122.599 279.548 115.672 284.669 113.093C290.2 110.307 296.761 110.302 302.296 113.08C307.421 115.651 311.455 122.574 319.524 136.416L353.63 194.925L353.631 194.927C359.499 204.992 362.432 210.025 363.722 215.335C365.127 221.116 365.129 227.138 363.73 232.92C362.445 238.231 359.515 243.268 353.656 253.339L265.227 405.337C259.282 415.556 256.31 420.666 252.237 424.485C247.804 428.642 242.429 431.706 236.553 433.423C231.154 435 225.161 435 213.174 435ZM454.141 435H375.834C359.676 435 351.595 435 346.785 431.926C341.588 428.605 338.327 423.038 338.02 416.959C337.736 411.333 341.802 404.477 349.935 390.769L389.023 324.876C397.053 311.341 401.069 304.574 406.152 302.039C411.646 299.299 418.142 299.295 423.64 302.026C428.728 304.553 432.752 311.315 440.8 324.837L440.802 324.841L480.02 390.732C488.184 404.449 492.265 411.308 491.987 416.939C491.685 423.023 488.427 428.596 483.226 431.923C478.416 435 470.324 435 454.141 435Z"
fill="currentColor" />
</svg>

After

Width:  |  Height:  |  Size: 1.3 KiB

View File

@ -1 +1,18 @@
<svg fill="none" viewBox="0 0 600 600" xmlns="http://www.w3.org/2000/svg"><linearGradient id="a" gradientUnits="userSpaceOnUse" x1="515.48" x2="86.23" y1="91.22" y2="507.26"><stop offset="0" stop-color="#d372de"/><stop offset=".5" stop-color="#93aadd"/><stop offset="1" stop-color="#73edf9"/></linearGradient><radialGradient id="b" cx="0" cy="0" gradientTransform="rotate(54.17 -42.31 263.4) scale(497.082)" gradientUnits="userSpaceOnUse" r="1"><stop offset="0" stop-color="#fff" stop-opacity="0"/><stop offset="1" stop-color="#47186b"/></radialGradient><path d="M300 600c165.69 0 300-134.31 300-300S465.69 0 300 0 0 134.31 0 300s134.31 300 300 300z" fill="url(#a)"/><path d="M300 600c165.69 0 300-134.31 300-300S465.69 0 300 0 0 134.31 0 300s134.31 300 300 300z" fill="url(#b)" fill-opacity=".35"/><path d="M270.88 176.72a29.8 29.8 0 019.41-13.37 28.8 28.8 0 0110.25-5.12c2.53-.51 5.64-1.01 9.17-1.01 2.69 0 5.04.16 7.14.42 7.06.92 11.85 4.79 12.78 5.46 5.88 4.45 8.4 10 9.4 12.6 53.46 126.75 91.79 220.2 95.06 231.89.6 2.1 2.19 7.9-.42 13.28a16.55 16.55 0 01-10 8.57c-1.18.5-6.64 2.52-12.77.17-7.4-2.86-9.84-9.84-10.17-10.85-30.34-75.38-60.77-150.86-91.1-226.25-11.02 27.66-22.03 55.22-32.95 82.87 6.8.09 13.7.17 20.5.17 1.94.84 5.8 2.86 8.66 7.06 3.36 5.05 5.3 13.28 1.1 19.92-3.7 5.8-10.1 7.14-11.52 7.48-11.1-.08-22.27-.17-33.37-.17L206.42 423.3a20.19 20.19 0 01-9.16 6.14 19.74 19.74 0 01-11.52.08 19.94 19.94 0 01-8.9-8.9c-3.45-6.98-1.44-13.45-1.02-14.88l39.84-95.56c-7.14-.17-14.2-.25-21.35-.42a17.57 17.57 0 01-8.74-6.47c-4.62-6.64-3.95-16.4 1.35-22.27a17.42 17.42 0 018.4-5.05c11.43-.08 22.95-.17 34.38-.17 13.7-32.94 27.48-66.06 41.18-99.08z" fill="#e7e6f2"/></svg>
<svg fill="none" viewBox="0 0 600 600" xmlns="http://www.w3.org/2000/svg">
<linearGradient id="aaave" gradientUnits="userSpaceOnUse" x1="515.48" x2="86.23" y1="91.22" y2="507.26">
<stop offset="0" stop-color="#d372de" />
<stop offset=".5" stop-color="#93aadd" />
<stop offset="1" stop-color="#73edf9" />
</linearGradient>
<radialGradient id="baave" cx="0" cy="0" gradientTransform="rotate(54.17 -42.31 263.4) scale(497.082)"
gradientUnits="userSpaceOnUse" r="1">
<stop offset="0" stop-color="#fff" stop-opacity="0" />
<stop offset="1" stop-color="#47186b" />
</radialGradient>
<path d="M300 600c165.69 0 300-134.31 300-300S465.69 0 300 0 0 134.31 0 300s134.31 300 300 300z" fill="url(#aaave)" />
<path d="M300 600c165.69 0 300-134.31 300-300S465.69 0 300 0 0 134.31 0 300s134.31 300 300 300z" fill="url(#baave)"
fill-opacity=".35" />
<path
d="M270.88 176.72a29.8 29.8 0 019.41-13.37 28.8 28.8 0 0110.25-5.12c2.53-.51 5.64-1.01 9.17-1.01 2.69 0 5.04.16 7.14.42 7.06.92 11.85 4.79 12.78 5.46 5.88 4.45 8.4 10 9.4 12.6 53.46 126.75 91.79 220.2 95.06 231.89.6 2.1 2.19 7.9-.42 13.28a16.55 16.55 0 01-10 8.57c-1.18.5-6.64 2.52-12.77.17-7.4-2.86-9.84-9.84-10.17-10.85-30.34-75.38-60.77-150.86-91.1-226.25-11.02 27.66-22.03 55.22-32.95 82.87 6.8.09 13.7.17 20.5.17 1.94.84 5.8 2.86 8.66 7.06 3.36 5.05 5.3 13.28 1.1 19.92-3.7 5.8-10.1 7.14-11.52 7.48-11.1-.08-22.27-.17-33.37-.17L206.42 423.3a20.19 20.19 0 01-9.16 6.14 19.74 19.74 0 01-11.52.08 19.94 19.94 0 01-8.9-8.9c-3.45-6.98-1.44-13.45-1.02-14.88l39.84-95.56c-7.14-.17-14.2-.25-21.35-.42a17.57 17.57 0 01-8.74-6.47c-4.62-6.64-3.95-16.4 1.35-22.27a17.42 17.42 0 018.4-5.05c11.43-.08 22.95-.17 34.38-.17 13.7-32.94 27.48-66.06 41.18-99.08z"
fill="#e7e6f2" />
</svg>

Before

Width:  |  Height:  |  Size: 1.6 KiB

After

Width:  |  Height:  |  Size: 1.8 KiB

View File

@ -0,0 +1,10 @@
<svg viewBox="0 0 600 600" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M300 600C465.685 600 600 465.685 600 300C600 134.315 465.685 0 300 0C134.315 0 0 134.315 0 300C0 465.685 134.315 600 300 600Z" fill="url(#paint0_radialavax)"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M213.174 435H145.633C129.619 435 121.612 435 116.817 431.953C111.634 428.66 108.364 423.134 108.018 417.084C107.697 411.485 111.663 404.658 119.594 391.006L119.598 391.001L267.476 136.454C275.524 122.599 279.548 115.672 284.669 113.093C290.2 110.307 296.761 110.302 302.296 113.08C307.421 115.651 311.455 122.574 319.524 136.416L353.63 194.925L353.631 194.927C359.499 204.992 362.432 210.025 363.722 215.335C365.127 221.116 365.129 227.138 363.73 232.92C362.445 238.231 359.515 243.268 353.656 253.339L265.227 405.337C259.282 415.556 256.31 420.666 252.237 424.485C247.804 428.642 242.429 431.706 236.553 433.423C231.154 435 225.161 435 213.174 435ZM454.141 435H375.834C359.676 435 351.595 435 346.785 431.926C341.588 428.605 338.327 423.038 338.02 416.959C337.736 411.333 341.802 404.477 349.935 390.769L389.023 324.876C397.053 311.341 401.069 304.574 406.152 302.039C411.646 299.299 418.142 299.295 423.64 302.026C428.728 304.553 432.752 311.315 440.8 324.837L440.802 324.841L480.02 390.732C488.184 404.449 492.265 411.308 491.987 416.939C491.685 423.023 488.427 428.596 483.226 431.923C478.416 435 470.324 435 454.141 435Z" fill="white"/>
<defs>
<radialGradient id="paint0_radialavax" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(196 143.5) rotate(54.1675) scale(497.082)">
<stop stop-color="#FF6A6B"/>
<stop offset="1" stop-color="#C20C0D"/>
</radialGradient>
</defs>
</svg>

After

Width:  |  Height:  |  Size: 1.7 KiB

View File

@ -1 +1,18 @@
<svg fill="none" viewBox="0 0 600 600" xmlns="http://www.w3.org/2000/svg"><radialGradient id="a" cx="0" cy="0" gradientTransform="rotate(54.17 -42.31 263.4) scale(497.082)" gradientUnits="userSpaceOnUse" r="1"><stop offset="0" stop-color="#e5e8ff"/><stop offset="1" stop-color="#7887d8"/></radialGradient><path d="M300 600c165.69 0 300-134.31 300-300S465.69 0 300 0 0 134.31 0 300s134.31 300 300 300z" fill="#c5cae9"/><path d="M300 600c165.69 0 300-134.31 300-300S465.69 0 300 0 0 134.31 0 300s134.31 300 300 300z" fill="url(#a)" fill-opacity=".35"/><g fill="#5c6cc0"><path d="M185.42 297.21l114.14 67.52V107.87zm114.14-189.34v256.86l114.03-67.52zM185.42 318.93L299.56 479.7v-93.34zm114.14 67.42v93.34L413.7 318.93z"/><path d="M299.56 245.37L185.42 297.2l114.14 67.52 114.03-67.52z"/><path d="M185.42 297.21l114.14 67.52V107.87zm114.14-189.34v256.86l114.03-67.52zM185.42 318.93L299.56 479.7v-93.34zm114.14 67.42v93.34L413.7 318.93z"/><path d="M299.56 245.37L185.42 297.2l114.14 67.52 114.03-67.52z"/></g></svg>
<svg fill="none" viewBox="0 0 600 600" xmlns="http://www.w3.org/2000/svg">
<radialGradient id="aeth" cx="0" cy="0" gradientTransform="rotate(54.17 -42.31 263.4) scale(497.082)"
gradientUnits="userSpaceOnUse" r="1">
<stop offset="0" stop-color="#e5e8ff" />
<stop offset="1" stop-color="#7887d8" />
</radialGradient>
<path d="M300 600c165.69 0 300-134.31 300-300S465.69 0 300 0 0 134.31 0 300s134.31 300 300 300z" fill="#c5cae9" />
<path d="M300 600c165.69 0 300-134.31 300-300S465.69 0 300 0 0 134.31 0 300s134.31 300 300 300z" fill="url(#aeth)"
fill-opacity=".35" />
<g fill="#5c6cc0">
<path
d="M185.42 297.21l114.14 67.52V107.87zm114.14-189.34v256.86l114.03-67.52zM185.42 318.93L299.56 479.7v-93.34zm114.14 67.42v93.34L413.7 318.93z" />
<path d="M299.56 245.37L185.42 297.2l114.14 67.52 114.03-67.52z" />
<path
d="M185.42 297.21l114.14 67.52V107.87zm114.14-189.34v256.86l114.03-67.52zM185.42 318.93L299.56 479.7v-93.34zm114.14 67.42v93.34L413.7 318.93z" />
<path d="M299.56 245.37L185.42 297.2l114.14 67.52 114.03-67.52z" />
</g>
</svg>

Before

Width:  |  Height:  |  Size: 1010 B

After

Width:  |  Height:  |  Size: 1.1 KiB

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 13 KiB

View File

@ -1 +1,12 @@
<svg fill="none" viewBox="0 0 600 600" xmlns="http://www.w3.org/2000/svg"><radialGradient id="a" cx="0" cy="0" gradientTransform="rotate(54.2 -42.3 263.4) scale(497.082)" gradientUnits="userSpaceOnUse" r="1"><stop offset="0" stop-color="#d6edff"/><stop offset="1" stop-color="#2775c9"/></radialGradient><path d="M300 600a300.2 300.2 0 00294.2-358.5A299.8 299.8 0 0050.6 133.3 300.2 300.2 0 00300 600z" fill="#bcddf8"/><path d="M300 600a300 300 0 100-600 300 300 0 000 600z" fill="url(#a)" fill-opacity=".3"/><path d="M378.1 341.6c0-40.8-24.8-54.5-72.8-61.2-35.5-5-42.3-13.5-42.3-30 0-16.6 12-26.8 35-26.8 20.9 0 33 7.3 37.9 24a8.4 8.4 0 003.2 4.7 8.8 8.8 0 005.3 1.8h18.3c1.3 0 2.4-.1 3.5-.7a8.1 8.1 0 004.7-8.7C365 218 347 202 318.9 197v-28a8.7 8.7 0 00-8.7-8.8h-17.5a8.7 8.7 0 00-8.7 8.7V196c-35 4.9-57 28-57 57.6 0 38.3 23.2 53.2 72 59.8 33.2 5.4 42.6 12.6 42.6 31.4s-16 31.5-38.6 31.5c-30.5 0-40.8-13.3-44.3-30.6a9 9 0 00-3-5 8.6 8.6 0 00-5.5-2h-20c-1.1 0-2.4.2-3.4.6-1.1.6-2 1.3-2.9 2.2a8.1 8.1 0 00-1.8 6.6c5 29.1 23.7 50.5 61.9 55.6v27.6a8.7 8.7 0 008.7 8.8h17.5a8.7 8.7 0 008.7-8.8v-27.8c36.2-5.6 59.2-30.6 59.2-61.9zM241.4 464.4a175 175 0 01-83.3-264.5 174.5 174.5 0 0183.3-64 12.9 12.9 0 007.5-11v-16.4c.2-1.4 0-2.9-.7-4.2a7.6 7.6 0 00-2.7-3.3 8.1 8.1 0 00-8.2-.8 209.8 209.8 0 00-105.7 324c26.3 35.8 63.3 62.5 105.7 76a8.1 8.1 0 008.2-.8 9 9 0 002.7-3.2c.6-1.4.9-2.8.7-4.3v-16.3c0-2.4-.9-4.7-2.2-6.6-1.2-2.2-3-3.7-5.3-4.6zM365.6 100a8.1 8.1 0 00-8.2.8c-1.2 1-2.2 2-2.8 3.3a7.7 7.7 0 00-.7 4.2v16.4a12.6 12.6 0 007.5 11 175 175 0 0183.4 264.5 174.5 174.5 0 01-83.4 64 12 12 0 00-5.5 4.3 12 12 0 00-2 6.7v16.4c-.2 1.4.1 2.9.7 4.2a7.6 7.6 0 002.8 3.3 8.1 8.1 0 008.2.8 209.8 209.8 0 000-399.9z" fill="#2775c9"/></svg>
<svg fill="none" viewBox="0 0 600 600" xmlns="http://www.w3.org/2000/svg">
<radialGradient id="ausdc" cx="0" cy="0" gradientTransform="rotate(54.2 -42.3 263.4) scale(497.082)"
gradientUnits="userSpaceOnUse" r="1">
<stop offset="0" stop-color="#d6edff" />
<stop offset="1" stop-color="#2775c9" />
</radialGradient>
<path d="M300 600a300.2 300.2 0 00294.2-358.5A299.8 299.8 0 0050.6 133.3 300.2 300.2 0 00300 600z" fill="#bcddf8" />
<path d="M300 600a300 300 0 100-600 300 300 0 000 600z" fill="url(#ausdc)" fill-opacity=".3" />
<path
d="M378.1 341.6c0-40.8-24.8-54.5-72.8-61.2-35.5-5-42.3-13.5-42.3-30 0-16.6 12-26.8 35-26.8 20.9 0 33 7.3 37.9 24a8.4 8.4 0 003.2 4.7 8.8 8.8 0 005.3 1.8h18.3c1.3 0 2.4-.1 3.5-.7a8.1 8.1 0 004.7-8.7C365 218 347 202 318.9 197v-28a8.7 8.7 0 00-8.7-8.8h-17.5a8.7 8.7 0 00-8.7 8.7V196c-35 4.9-57 28-57 57.6 0 38.3 23.2 53.2 72 59.8 33.2 5.4 42.6 12.6 42.6 31.4s-16 31.5-38.6 31.5c-30.5 0-40.8-13.3-44.3-30.6a9 9 0 00-3-5 8.6 8.6 0 00-5.5-2h-20c-1.1 0-2.4.2-3.4.6-1.1.6-2 1.3-2.9 2.2a8.1 8.1 0 00-1.8 6.6c5 29.1 23.7 50.5 61.9 55.6v27.6a8.7 8.7 0 008.7 8.8h17.5a8.7 8.7 0 008.7-8.8v-27.8c36.2-5.6 59.2-30.6 59.2-61.9zM241.4 464.4a175 175 0 01-83.3-264.5 174.5 174.5 0 0183.3-64 12.9 12.9 0 007.5-11v-16.4c.2-1.4 0-2.9-.7-4.2a7.6 7.6 0 00-2.7-3.3 8.1 8.1 0 00-8.2-.8 209.8 209.8 0 00-105.7 324c26.3 35.8 63.3 62.5 105.7 76a8.1 8.1 0 008.2-.8 9 9 0 002.7-3.2c.6-1.4.9-2.8.7-4.3v-16.3c0-2.4-.9-4.7-2.2-6.6-1.2-2.2-3-3.7-5.3-4.6zM365.6 100a8.1 8.1 0 00-8.2.8c-1.2 1-2.2 2-2.8 3.3a7.7 7.7 0 00-.7 4.2v16.4a12.6 12.6 0 007.5 11 175 175 0 0183.4 264.5 174.5 174.5 0 01-83.4 64 12 12 0 00-5.5 4.3 12 12 0 00-2 6.7v16.4c-.2 1.4.1 2.9.7 4.2a7.6 7.6 0 002.8 3.3 8.1 8.1 0 008.2.8 209.8 209.8 0 000-399.9z"
fill="#2775c9" />
</svg>

Before

Width:  |  Height:  |  Size: 1.7 KiB

After

Width:  |  Height:  |  Size: 1.8 KiB

View File

@ -0,0 +1,4 @@
<svg viewBox="0 0 1503 1504" fill="none" xmlns="http://www.w3.org/2000/svg">
<rect x="287" y="258" width="928" height="844" fill="white"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M1502.5 752C1502.5 1166.77 1166.27 1503 751.5 1503C336.734 1503 0.5 1166.77 0.5 752C0.5 337.234 336.734 1 751.5 1C1166.27 1 1502.5 337.234 1502.5 752ZM538.688 1050.86H392.94C362.314 1050.86 347.186 1050.86 337.962 1044.96C327.999 1038.5 321.911 1027.8 321.173 1015.99C320.619 1005.11 328.184 991.822 343.312 965.255L703.182 330.935C718.495 303.999 726.243 290.531 736.021 285.55C746.537 280.2 759.083 280.2 769.599 285.55C779.377 290.531 787.126 303.999 802.438 330.935L876.42 460.079L876.797 460.738C893.336 489.635 901.723 504.289 905.385 519.669C909.443 536.458 909.443 554.169 905.385 570.958C901.695 586.455 893.393 601.215 876.604 630.549L687.573 964.702L687.084 965.558C670.436 994.693 661.999 1009.46 650.306 1020.6C637.576 1032.78 622.263 1041.63 605.474 1046.62C590.161 1050.86 573.004 1050.86 538.688 1050.86ZM906.75 1050.86H1115.59C1146.4 1050.86 1161.9 1050.86 1171.13 1044.78C1181.09 1038.32 1187.36 1027.43 1187.92 1015.63C1188.45 1005.1 1181.05 992.33 1166.55 967.307C1166.05 966.455 1165.55 965.588 1165.04 964.706L1060.43 785.75L1059.24 783.735C1044.54 758.877 1037.12 746.324 1027.59 741.472C1017.08 736.121 1004.71 736.121 994.199 741.472C984.605 746.453 976.857 759.552 961.544 785.934L857.306 964.891L856.949 965.507C841.69 991.847 834.064 1005.01 834.614 1015.81C835.352 1027.62 841.44 1038.5 851.402 1044.96C860.443 1050.86 875.94 1050.86 906.75 1050.86Z" fill="#E84142"/>
</svg>

After

Width:  |  Height:  |  Size: 1.6 KiB

View File

@ -3,7 +3,7 @@
<div
class="inline-flex items-center justify-center dark:opacity-90"
:class="{
'h-10 w-10': !noHeight,
'h-10 w-10': !noHeight
}"
>
<SVG1inch v-if="currency === '1inch'" class="h-full" />
@ -77,6 +77,8 @@
<SVGyfi v-else-if="currency === 'yfi'" class="h-full" />
<SVGzil v-else-if="currency === 'zil'" class="h-full" />
<SVGzrx v-else-if="currency === 'zrx'" class="h-full" />
<SVGavax v-else-if="currency === 'avax'" class="h-full" />
<SVGwavax v-else-if="currency === 'wavax'" class="h-full" />
<div
v-else
@ -161,7 +163,8 @@ import SVGzrx from '@/assets/icons/currencies/zrx.svg?inline'
import SVGCustom from '@/assets/icons/currencies/custom.svg?inline'
import SVGlqty from '@/assets/icons/currencies/lqty.svg?inline'
import SVGlusd from '@/assets/icons/currencies/lusd.svg?inline'
import SVGavax from '@/assets/icons/currencies/avax.svg?inline'
import SVGwavax from '@/assets/icons/currencies/wavax.svg?inline'
export default defineComponent({
props: {
currency: { type: String, default: '' },
@ -240,6 +243,8 @@ export default defineComponent({
SVGlqty,
SVGlusd,
SVGCustom,
SVGavax,
SVGwavax,
},
})
</script>

View File

@ -13,6 +13,7 @@ import { usePosition } from "~/composables/usePosition";
import { useToken } from "~/composables/useToken";
import { useSorting } from "~/composables/useSorting";
import useEventBus from "../useEventBus";
import addresses from "~/constant/addresses";
const {
times,
@ -70,13 +71,13 @@ export function useAaveV2Position(
const { activeNetworkId } = useNetwork();
const { activeAccount } = useDSA();
const { getTokenByKey, allATokensV2 } = useToken();
const { byMaxSupplyOrBorrowDesc } = useSorting()
const { onEvent } = useEventBus()
const resolver = computed(() =>
chainId.value === 1
? "0xFb3a1D56eD56F046721B9aCa749895100754578b"
: "0xD6E0803d0eB34af8Ea135835512D7E77960b28F1"
const { byMaxSupplyOrBorrowDesc } = useSorting();
const { onEvent } = useEventBus();
const resolver = computed(
() =>
// @ts-ignore
addresses[activeNetworkId.value]?.resolver?.aave_v2
);
const fetchPosition = async () => {
@ -97,6 +98,8 @@ export function useAaveV2Position(
a => tokens[activeNetworkId.value].getTokenByKey(a.root).address
);
console.log(activeAccount.value.address, aaveTokensArr);
const aaveRawData = await aaveResolverInstance.methods
.getPosition(activeAccount.value.address, aaveTokensArr)
.call();
@ -393,7 +396,10 @@ function calculateAavePosition(res: any[], network: Network = Network.Mainnet) {
totalStableDebt,
totalVariableDebt,
collateralEmission,
debtEmission
debtEmission,
aTokenAddress,
stableDebtTokenAddress,
variableDebtTokenAddress
] = AaveTokenData;
/* eslint-enable no-unused-vars */
@ -473,6 +479,9 @@ function calculateAavePosition(res: any[], network: Network = Network.Mainnet) {
dataPos.push({
key: root,
aTokenAddr: key,
aTokenAddress,
stableDebtTokenAddress,
variableDebtTokenAddress,
aTokenBal: supplyBalanceInWei,
aTokenKey: atoken.key,
aDecimals: atoken.decimals.toString(),

View File

@ -23,19 +23,22 @@ const balances = reactive({
user: {
mainnet: {},
polygon: {},
arbitrum: {}
arbitrum: {},
avalanche: {}
},
dsa: {
mainnet: {},
polygon: {},
arbitrum: {}
arbitrum: {},
avalanche: {}
}
});
const prices = reactive({
mainnet: {},
polygon: {},
arbitrum: {}
arbitrum: {},
avalanche: {}
});
export function useBalances() {
@ -55,6 +58,9 @@ export function useBalances() {
prices.arbitrum = await $axios.$get(
"https://api.instadapp.io/defi/arbitrum/prices"
);
prices.avalanche = await $axios.$get(
"https://api.instadapp.io/defi/avalanche/prices"
);
});
const fetchBalances = async (refresh = false) => {
if (!balances.user || refresh) {
@ -71,6 +77,10 @@ export function useBalances() {
arbitrum:
activeNetworkId.value === Network.Arbitrum
? await getBalances(account.value, Network.Arbitrum, library.value)
: {},
avalanche:
activeNetworkId.value === Network.Avalanche
? await getBalances(account.value, Network.Avalanche, library.value)
: {}
};
}
@ -102,6 +112,10 @@ export function useBalances() {
Network.Arbitrum,
library.value
)
: {},
avalanche:
activeNetworkId.value === Network.Avalanche
? await getBalances(account.value, Network.Avalanche, library.value)
: {}
};
}

View File

@ -8,10 +8,15 @@ export function useLink() {
if (activeNetworkId.value === "polygon") {
return "https://polygonscan.com/address";
}
if (activeNetworkId.value === "arbitrum") {
return "https://arbiscan.io/address";
}
if (activeNetworkId.value === "avalanche") {
return "https://cchain.explorer.avax.network/address";
}
return "https://etherscan.io/address";
});
@ -26,5 +31,7 @@ export const getPolygonLink = transactionHash =>
`https://polygonscan.com/tx/${transactionHash}`;
export const getArbitrumLink = transactionHash =>
`https://arbiscan.io/tx/${transactionHash}`;
export const getAvalancheLink = transactionHash =>
`https://cchain.explorer.avax.network/tx/${transactionHash}`;
export const getTenderlyLink = simulationId =>
`https://dashboard.tenderly.co/public/InstaDApp/dsa-simulations/fork-simulation/${simulationId}?hideSidebar=true`;

View File

@ -3,6 +3,7 @@ import { computed, watchEffect, ref, watch } from "@nuxtjs/composition-api";
import MainnetSVG from "~/assets/icons/mainnet.svg?inline";
import PolygonSVG from "~/assets/icons/polygon.svg?inline";
import ArbitrumSVG from "~/assets/icons/arbitrum.svg?inline";
import AvalancheSVG from "~/assets/icons/avalanche.svg?inline";
import { useModal } from "./useModal";
import { useNotification } from "./useNotification";
@ -12,13 +13,15 @@ import { useCookies } from "./useCookies";
export enum Network {
Mainnet = "mainnet",
Polygon = "polygon",
Arbitrum = "arbitrum"
Arbitrum = "arbitrum",
Avalanche = "avalanche"
}
export const networks = [
{ id: "mainnet", chainId: 1, name: "Mainnet", icon: MainnetSVG },
{ id: "polygon", chainId: 137, name: "Polygon", icon: PolygonSVG },
{ id: "arbitrum", chainId: 42161, name: "Arbitrum", icon: ArbitrumSVG }
{ id: "arbitrum", chainId: 42161, name: "Arbitrum", icon: ArbitrumSVG },
{ id: "avalanche", chainId: 43114, name: "Avalanche", icon: AvalancheSVG },
];
export const activeNetworkId = ref<Network>();
@ -135,12 +138,52 @@ export function useNetwork() {
}
}
async function switchToAvalanche() {
if (window.ethereum) {
const chainId = '0xa86a'
try {
await window.ethereum.request({
method: 'wallet_switchEthereumChain',
params: [{ chainId }],
})
} catch (switchError) {
// 4902 error code indicates that the chain has not been added to MetaMask.
if (switchError.code === 4902) {
try {
const chainData = {
chainId,
chainName: 'Avalanche Network',
nativeCurrency: {
name: 'Avalanche',
symbol: 'AVAX',
decimals: 18,
},
rpcUrls: ['https://api.avax.network/ext/bc/C/rpc'],
blockExplorerUrls: ['https://cchain.explorer.avax.network/'],
}
await window.ethereum.request({
method: 'wallet_addEthereumChain',
params: [chainData, account.value],
})
} catch (addError) {
return Promise.reject(addError)
}
} else {
return Promise.reject(switchError)
}
}
}
}
async function switchNetwork() {
try {
if (activeNetworkId.value === "mainnet") {
await switchToMainnet();
} else if (activeNetworkId.value === "arbitrum") {
await switchToArbitrum();
} else if (activeNetworkId.value === "avalanche") {
await switchToAvalanche();
} else {
await switchToPolygon();
}

View File

@ -1,6 +1,7 @@
import { ref } from "@nuxtjs/composition-api";
import { useFormatting } from "@/composables/useFormatting";
import {
getAvalancheLink,
getArbitrumLink,
getEtherscanLink,
getMaticLink,
@ -99,6 +100,8 @@ export function useNotification() {
href = getMaticLink(transactionHash);
}else if (network === Network.Arbitrum) {
href = getArbitrumLink(transactionHash);
}else if (network === Network.Avalanche) {
href = getAvalancheLink(transactionHash);
} else {
href = getEtherscanLink(transactionHash);
}
@ -122,6 +125,8 @@ export function useNotification() {
href = getMaticLink(transactionHash);
} else if (network === Network.Arbitrum) {
href = getArbitrumLink(transactionHash);
} else if (network === Network.Avalanche) {
href = getAvalancheLink(transactionHash);
} else {
href = getEtherscanLink(transactionHash);
}

View File

@ -14,16 +14,17 @@ import { SafeAppConnector } from "@gnosis.pm/safe-apps-web3-react/dist/connector
setWeb3LibraryCallback(provider => new Web3(provider));
export const injected = new InjectedConnector({
supportedChainIds: [1, 137, 42161]
supportedChainIds: [1, 137, 42161, 43114]
});
export const walletconnect = new WalletConnectConnector({
rpc: {
1: `https://mainnet.infura.io/v3/${process.env.INFURA_ID}`,
137: "https://rpc-mainnet.maticvigil.com",
42161: "https://arb1.arbitrum.io/rpc"
42161: "https://arb1.arbitrum.io/rpc",
43114: "https://api.avax.network/ext/bc/C/rpc"
},
supportedChainIds: [1, 137, 42161]
supportedChainIds: [1, 137, 42161, 43114]
});
// mainnet only
@ -42,7 +43,7 @@ let gnosisSafe = null;
if (process.client) {
gnosisSafe = new SafeAppConnector({
supportedChainIds: [1, 137, 42161]
supportedChainIds: [1, 137, 42161, 43114]
});
}

View File

@ -4,7 +4,7 @@ const addresses = {
bprotocolBamm: "0x0d3AbAA7E088C2c82f54B2f47613DA438ea8C598",
resolver: {
aave: "0xA6Dc31dC10f8071c02099B05B76Ba15dfcD2B04c",
aave_v2: "0xFb3a1D56eD56F046721B9aCa749895100754578b",
aave_v2: "0xF0317C5Bc206F2291dd2f3eE9C4cDB5Bbb25418d",
accounts: "0x621AD080ad3B839e7b19e040C77F05213AB71524",
balance: "0xea426ed5d09d22e46e5d93176c6c7531638f15c1",
compound: "0xcCAa4b1b3931749b8b6EF19C6b0B2c496703321b",
@ -23,7 +23,7 @@ const addresses = {
instaConnectorsV2: "0x2A00684bFAb9717C21271E0751BCcb7d2D763c88"
},
resolver: {
aave_v2: "0xD6E0803d0eB34af8Ea135835512D7E77960b28F1",
aave_v2: "0x1f5e200493adB54FEB4a7D734E48649143ecE2CA",
accounts: "0xdF19Da523DA64bBE82eE0E4DFf00d676A8386474",
balance: "0x04F8a41be023f839E709eeEaA0725FD766139A4d",
merkleResolver: {
@ -46,6 +46,17 @@ const addresses = {
},
uniswapV3Staker: '0x1f98407aaB862CdDeF78Ed252D6f557aA5b0f00d',
},
avalanche: {
core: {
instaIndex: '0x6CE3e607C808b4f4C26B7F6aDAeB619e49CAbb25',
instaConnectorsV2: '0x127d8cD0E2b2E0366D522DeA53A787bfE9002C14'
},
resolver: {
aave_v2: '0x43c51C24b49f7cF389D043e93533E5179870Eea3',
accounts: '0x746e318e179CB0A359C1FeE8331A3F9bE309b3CE',
balance: '0xE6F92a3eCAa618FC5D4Bf2a14090787715C115F0',
},
},
};
export default addresses;

View File

@ -35,5 +35,15 @@ export default {
{ key: "awbtc", "type": "atoken", "symbol": "AWBTC", "name": "Aave WBTC", "address": "0x5c2ed810328349100A66B82b78a1791B101C9D61", "decimals": 8, "factor": 0.7, "root": "wbtc" },
{ key: "aaave", "type": "atoken", "symbol": "AAAVE", "name": "Aave AAVE", "address": "0x1d2a0E5EC8E5bBDCA5CB219e649B565d8e5c3360", "decimals": 18, "factor": 0.5, "root": "aave" },
{ key: "awmatic", "type": "atoken", "symbol": "AWMATIC", "name": "Aave WMATIC", "address": "0x8dF3aad3a84da6b69A4DA8aeC3eA40d9091B2Ac4", "decimals": 18, "factor": 0.5, "root": "matic" },
]),
avalanche : createTokenUtils([
{ key: "avweth", "type": "atoken", "symbol": "avWETH", "name": "Aave ETH", "address": "0x53f7c5869a859F0AeC3D334ee8B4Cf01E3492f21", "decimals": 18, "factor": 0.8, "root": "eth" },
{ key: "avdai", "type": "atoken", "symbol": "avDAI", "name": "Aave DAI", "address": "0x47AFa96Cdc9fAb46904A55a6ad4bf6660B53c38a", "decimals": 18, "factor": 0, "root": "dai" },
{ key: "avusdc", "type": "atoken", "symbol": "avUSDC", "name": "Aave USDC", "address": "0x46A51127C3ce23fb7AB1DE06226147F446e4a857", "decimals": 6, "factor": 0.8, "root": "usdc" },
{ key: "avusdt", "type": "atoken", "symbol": "avUSDT", "name": "Aave USDT", "address": "0x532E6537FEA298397212F09A61e03311686f548e", "decimals": 6, "factor": 0, "root": "usdt" },
{ key: "avwbtc", "type": "atoken", "symbol": "avWBTC", "name": "Aave WBTC", "address": "0x686bEF2417b6Dc32C50a3cBfbCC3bb60E1e9a15D", "decimals": 8, "factor": 0.6, "root": "wbtc" },
{ key: "avaave", "type": "atoken", "symbol": "avAAVE", "name": "Aave AAVE", "address": "0xD45B7c061016102f9FA220502908f2c0f1add1D7", "decimals": 18, "factor": 0, "root": "aave" },
{ key: "avwavax", "type": "atoken", "symbol": "avWAVAX", "name": "Aave WAVAX", "address": "0xDFE521292EcE2A4f44242efBcD66Bc594CA9714B", "decimals": 8, "factor": 0, "root": "avax" },
])
}
}

View File

@ -38,5 +38,15 @@ export default {
{ key: "awbtc", "type": "atoken", "symbol": "AWBTC", "name": "Aave WBTC", "address": "0x5c2ed810328349100A66B82b78a1791B101C9D61", "decimals": 8, "factor": 0.7, "root": "wbtc" },
{ key: "aaave", "type": "atoken", "symbol": "AAAVE", "name": "Aave AAVE", "address": "0x1d2a0E5EC8E5bBDCA5CB219e649B565d8e5c3360", "decimals": 18, "factor": 0.5, "root": "aave" },
{ key: "awmatic", "type": "atoken", "symbol": "AWMATIC", "name": "Aave WMATIC", "address": "0x8dF3aad3a84da6b69A4DA8aeC3eA40d9091B2Ac4", "decimals": 8, "factor": 0.7, "root": "matic" },
]),
avalanche: createTokenUtils([
{ key: "avweth", "type": "atoken", "symbol": "avWETH", "name": "Aave ETH", "address": "0x53f7c5869a859F0AeC3D334ee8B4Cf01E3492f21", "decimals": 18, "factor": 0.8, "root": "eth" },
{ key: "avdai", "type": "atoken", "symbol": "avDAI", "name": "Aave DAI", "address": "0x47AFa96Cdc9fAb46904A55a6ad4bf6660B53c38a", "decimals": 18, "factor": 0, "root": "dai" },
{ key: "avusdc", "type": "atoken", "symbol": "avUSDC", "name": "Aave USDC", "address": "0x46A51127C3ce23fb7AB1DE06226147F446e4a857", "decimals": 6, "factor": 0.8, "root": "usdc" },
{ key: "avusdt", "type": "atoken", "symbol": "avUSDT", "name": "Aave USDT", "address": "0x532E6537FEA298397212F09A61e03311686f548e", "decimals": 6, "factor": 0, "root": "usdt" },
{ key: "avwbtc", "type": "atoken", "symbol": "avWBTC", "name": "Aave WBTC", "address": "0x686bEF2417b6Dc32C50a3cBfbCC3bb60E1e9a15D", "decimals": 8, "factor": 0.6, "root": "wbtc" },
{ key: "avaave", "type": "atoken", "symbol": "avAAVE", "name": "Aave AAVE", "address": "0xD45B7c061016102f9FA220502908f2c0f1add1D7", "decimals": 18, "factor": 0, "root": "aave" },
{ key: "avwavax", "type": "atoken", "symbol": "avWAVAX", "name": "Aave WAVAX", "address": "0xDFE521292EcE2A4f44242efBcD66Bc594CA9714B", "decimals": 8, "factor": 0, "root": "avax" },
])
}

View File

@ -69,5 +69,15 @@ export default {
{ key: 'link', type: 'token', symbol: 'LINK', name: 'ChainLink Token', address: '0xf97f4df75117a78c1A5a0DBb814Af92458539FB4', decimals: 18, isStableCoin: false },
{ key: 'uni', type: 'token', symbol: 'UNI', name: 'Uniswap Token', address: '0xFa7F8980b0f1E64A2062791cc3b0871572f1F7f0', decimals: 18, isStableCoin: false },
{ key: 'wbtc', type: 'token', symbol: 'WBTC', name: 'Wrapped BTC', address: '0x2f2a2543B76A4166549F7aaB2e75Bef0aefC5B0f', decimals: 8, isStableCoin: false },
]),
avalanche: createTokenUtils([
{ key: 'avax', type: 'token', symbol: 'AVAX', name: 'Avalanche', address: '0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE', decimals: 18, isStableCoin: false },
{ key: 'wavax', type: 'token', symbol: 'WAVAX', name: 'Wrapped AVAX', address: '0xB31f66AA3C1e785363F0875A1B74E27b85FD66c7', decimals: 18, isStableCoin: false },
{ key: 'eth', type: 'token', symbol: 'ETH', name: 'Ethereum', address: '0x49D5c2BdFfac6CE2BFdB6640F4F80f226bc10bAB', decimals: 18, isStableCoin: false },
{ key: 'usdt', type: 'token', symbol: 'USDT', name: 'Tether USD Coin', address: '0xc7198437980c041c805A1EDcbA50c1Ce5db95118', decimals: 6, isStableCoin: true },
{ key: 'aave', type: 'token', symbol: 'AAVE', name: 'Aave Token', address: '0x63a72806098Bd3D9520cC43356dD78afe5D386D9', decimals: 18, isStableCoin: false },
{ key: 'usdc', type: 'token', symbol: 'USDC', name: 'USD Coin', address: '0xA7D7079b0FEaD91F3e65f86E8915Cb59c1a4C664', decimals: 6, isStableCoin: true },
{ key: 'wbtc', type: 'token', symbol: 'WBTC', name: 'Wrapped BTC', address: '0x50b7545627a5162F82A992c33b87aDc75187B218', decimals: 8, isStableCoin: false },
{ key: 'dai', type: 'token', symbol: 'DAI', name: 'DAI Stable', address: '0xd586E7F844cEa2F87f50152665BCbc2C279D8d70', decimals: 18, isStableCoin: true },
])
}

View File

@ -145,14 +145,14 @@ export default defineComponent({
return;
}
if (route.value.path.includes(['mainnet', 'polygon', "arbitrum"]) && route.value.path.includes(activeNetwork.value.id)) {
if (route.value.path.includes(['mainnet', 'polygon', "arbitrum", "avalanche"]) && route.value.path.includes(activeNetwork.value.id)) {
redirect('/')
}
}, { immediate: true })
watch(chainId, (val) => {
if (val) {
if ([1, 137, 42161].includes(val)) {
if ([1, 137, 42161, 43114].includes(val)) {
checkForNetworkMismatch()
} else {
showNetworksMismatchDialog();

View File

@ -30,7 +30,7 @@
"bignumber.js": "^9.0.1",
"core-js": "^3.15.1",
"css-color-function": "^1.3.3",
"dsa-connect": "^0.5.0",
"dsa-connect": "^0.5.1",
"nuxt": "^2.15.7",
"qrcode": "^1.4.4",
"slugify": "^1.6.0",

View File

@ -124,6 +124,15 @@ const appsPerNetwork = {
url: "/1inch",
description: "DEX Aggregator"
}
],
avalanche: [
{
id: "aave-v2",
icon: AaveIcon,
name: "Aave v2",
url: "/aave-v2",
description: "Lend and borrow straight from your Gnosis Safe"
}
]
};

View File

@ -6472,10 +6472,10 @@ drbg.js@^1.0.1:
create-hash "^1.1.2"
create-hmac "^1.1.4"
dsa-connect@^0.5.0:
version "0.5.0"
resolved "https://registry.yarnpkg.com/dsa-connect/-/dsa-connect-0.5.0.tgz#33a1d9ab1095f66724a209d85f335e2e7c89cc5d"
integrity sha512-n3X5oD980CBG/rj2AbgcHFA1jZwEEvnIeY+qB7/3mOsgRqVFplguYZjAPKpP8da9WkCDHKkt8FvfQfYbTuvuOw==
dsa-connect@^0.5.1:
version "0.5.1"
resolved "https://registry.yarnpkg.com/dsa-connect/-/dsa-connect-0.5.1.tgz#a8be7c18ecc0857bf956000bf83e6b5aa57b2ab9"
integrity sha512-DK+kD+rcyQ6Y+01nvaSvR2TJP+guuHNRYeB8FiJvOGzt1LznhNVoKa5bZJ8c2qAxBBdjW36l6crqnE+YmMT1Rw==
duplexer3@^0.1.4:
version "0.1.4"