@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.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
- throw new Error("PrivateKeyWalletProvider does not support creating wallets from mnemonics. Use MnemonicWalletProvider instead.");
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.logoUrl || ""
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: "https://joai.ai/images/tokens/eth.svg"
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: "https://joai.ai/images/chains/base.svg",
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: "https://joai.ai/images/chains/base.svg",
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: "https://joai.ai/images/chains/base.svg",
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: "https://joai.ai/images/tokens/eth.svg"
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: {