@vleap/warps-adapter-evm 0.2.0-beta.61 → 0.2.0-beta.63
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +28 -7
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +29 -7
- package/dist/index.mjs.map +1 -1
- package/package.json +2 -2
package/dist/index.mjs
CHANGED
|
@@ -5,6 +5,7 @@ import { WarpChainName as WarpChainName7 } from "@vleap/warps";
|
|
|
5
5
|
import {
|
|
6
6
|
CacheTtl as CacheTtl2,
|
|
7
7
|
getProviderConfig,
|
|
8
|
+
getWarpChainAssetLogoUrl,
|
|
8
9
|
WarpCache as WarpCache2,
|
|
9
10
|
WarpCacheKey
|
|
10
11
|
} from "@vleap/warps";
|
|
@@ -145,7 +146,13 @@ var _PrivateKeyWalletProvider = class _PrivateKeyWalletProvider {
|
|
|
145
146
|
return this.getWallet();
|
|
146
147
|
}
|
|
147
148
|
create(mnemonic) {
|
|
148
|
-
|
|
149
|
+
const wallet = ethers.Wallet.fromPhrase(mnemonic);
|
|
150
|
+
return {
|
|
151
|
+
provider: _PrivateKeyWalletProvider.PROVIDER_NAME,
|
|
152
|
+
address: wallet.address,
|
|
153
|
+
privateKey: wallet.privateKey,
|
|
154
|
+
mnemonic: null
|
|
155
|
+
};
|
|
149
156
|
}
|
|
150
157
|
generate() {
|
|
151
158
|
const wallet = ethers.Wallet.createRandom();
|
|
@@ -688,7 +695,7 @@ var WarpEvmDataLoader = class {
|
|
|
688
695
|
name: token.name,
|
|
689
696
|
symbol: token.symbol,
|
|
690
697
|
decimals: token.decimals || 18,
|
|
691
|
-
logoUrl: token.
|
|
698
|
+
logoUrl: getWarpChainAssetLogoUrl(token, this.config) || ""
|
|
692
699
|
}));
|
|
693
700
|
}
|
|
694
701
|
async getTokenBalance(address, tokenAddress) {
|
|
@@ -1774,7 +1781,10 @@ var NativeTokenBase = {
|
|
|
1774
1781
|
name: "Ether",
|
|
1775
1782
|
symbol: "ETH",
|
|
1776
1783
|
decimals: 18,
|
|
1777
|
-
logoUrl:
|
|
1784
|
+
logoUrl: {
|
|
1785
|
+
light: "https://joai.ai/images/tokens/eth-white.svg",
|
|
1786
|
+
dark: "https://joai.ai/images/tokens/eth-black.svg"
|
|
1787
|
+
}
|
|
1778
1788
|
};
|
|
1779
1789
|
var BaseAdapter = createEvmAdapter(WarpChainName8.Base, {
|
|
1780
1790
|
mainnet: {
|
|
@@ -1784,7 +1794,10 @@ var BaseAdapter = createEvmAdapter(WarpChainName8.Base, {
|
|
|
1784
1794
|
blockTime: 2e3,
|
|
1785
1795
|
addressHrp: "0x",
|
|
1786
1796
|
defaultApiUrl: "https://mainnet.base.org",
|
|
1787
|
-
logoUrl:
|
|
1797
|
+
logoUrl: {
|
|
1798
|
+
light: "https://joai.ai/images/chains/base-white.svg",
|
|
1799
|
+
dark: "https://joai.ai/images/chains/base-black.svg"
|
|
1800
|
+
},
|
|
1788
1801
|
nativeToken: NativeTokenBase
|
|
1789
1802
|
},
|
|
1790
1803
|
testnet: {
|
|
@@ -1794,7 +1807,10 @@ var BaseAdapter = createEvmAdapter(WarpChainName8.Base, {
|
|
|
1794
1807
|
blockTime: 2e3,
|
|
1795
1808
|
addressHrp: "0x",
|
|
1796
1809
|
defaultApiUrl: "https://sepolia.base.org",
|
|
1797
|
-
logoUrl:
|
|
1810
|
+
logoUrl: {
|
|
1811
|
+
light: "https://joai.ai/images/chains/base-white.svg",
|
|
1812
|
+
dark: "https://joai.ai/images/chains/base-black.svg"
|
|
1813
|
+
},
|
|
1798
1814
|
nativeToken: NativeTokenBase
|
|
1799
1815
|
},
|
|
1800
1816
|
devnet: {
|
|
@@ -1804,7 +1820,10 @@ var BaseAdapter = createEvmAdapter(WarpChainName8.Base, {
|
|
|
1804
1820
|
blockTime: 2e3,
|
|
1805
1821
|
addressHrp: "0x",
|
|
1806
1822
|
defaultApiUrl: "https://sepolia.base.org",
|
|
1807
|
-
logoUrl:
|
|
1823
|
+
logoUrl: {
|
|
1824
|
+
light: "https://joai.ai/images/chains/base-white.svg",
|
|
1825
|
+
dark: "https://joai.ai/images/chains/base-black.svg"
|
|
1826
|
+
},
|
|
1808
1827
|
nativeToken: NativeTokenBase
|
|
1809
1828
|
}
|
|
1810
1829
|
});
|
|
@@ -1826,7 +1845,10 @@ var NativeTokenEth = {
|
|
|
1826
1845
|
symbol: "ETH",
|
|
1827
1846
|
name: "Ether",
|
|
1828
1847
|
decimals: 18,
|
|
1829
|
-
logoUrl:
|
|
1848
|
+
logoUrl: {
|
|
1849
|
+
light: "https://joai.ai/images/tokens/eth-white.svg",
|
|
1850
|
+
dark: "https://joai.ai/images/tokens/eth-black.svg"
|
|
1851
|
+
}
|
|
1830
1852
|
};
|
|
1831
1853
|
var EthereumAdapter = createEvmAdapter(WarpChainName10.Ethereum, {
|
|
1832
1854
|
mainnet: {
|