@ant-design/web3-assets 1.10.0 → 1.10.1

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/CHANGELOG.md CHANGED
@@ -1,5 +1,14 @@
1
1
  # @ant-design/web3-assets
2
2
 
3
+ ## 1.10.1
4
+
5
+ ### Patch Changes
6
+
7
+ - 3f7d7a6: build: set targets chrome 100
8
+ - Updated dependencies [3f7d7a6]
9
+ - @ant-design/web3-common@1.12.1
10
+ - @ant-design/web3-icons@1.8.1
11
+
3
12
  ## 1.10.0
4
13
 
5
14
  ### Minor Changes
@@ -1,7 +1,7 @@
1
1
  import { ChainIds, ChainType, createGetBrowserLink } from '@ant-design/web3-common';
2
2
  import { ArbitrumCircleColorful, AvalancheCircleColorful, BSCCircleColorful, EthereumCircleColorful, EthereumColorful, EthereumFilled, EtherscanCircleColorful, HardhatColorful, OkxWalletColorful, OptimismCircleColorful, PolygonCircleColorful, ScrollColorful } from '@ant-design/web3-icons';
3
3
  import { jsx as _jsx } from "react/jsx-runtime";
4
- export var Mainnet = {
4
+ export const Mainnet = {
5
5
  id: ChainIds.Mainnet,
6
6
  name: 'Ethereum',
7
7
  type: ChainType.EVM,
@@ -21,7 +21,7 @@ export var Mainnet = {
21
21
  /**
22
22
  * @deprecated use sepolia or holesky instead
23
23
  */
24
- export var Goerli = {
24
+ export const Goerli = {
25
25
  id: ChainIds.Goerli,
26
26
  name: 'Goerli',
27
27
  type: ChainType.EVM,
@@ -36,7 +36,7 @@ export var Goerli = {
36
36
  decimals: 18
37
37
  }
38
38
  };
39
- export var Sepolia = {
39
+ export const Sepolia = {
40
40
  id: ChainIds.Sepolia,
41
41
  name: 'Sepolia',
42
42
  type: ChainType.EVM,
@@ -51,7 +51,7 @@ export var Sepolia = {
51
51
  decimals: 18
52
52
  }
53
53
  };
54
- export var Holesky = {
54
+ export const Holesky = {
55
55
  id: ChainIds.Holesky,
56
56
  name: 'Holesky',
57
57
  type: ChainType.EVM,
@@ -66,7 +66,7 @@ export var Holesky = {
66
66
  decimals: 18
67
67
  }
68
68
  };
69
- export var Polygon = {
69
+ export const Polygon = {
70
70
  id: ChainIds.Polygon,
71
71
  name: 'Polygon',
72
72
  type: ChainType.EVM,
@@ -81,7 +81,7 @@ export var Polygon = {
81
81
  decimals: 18
82
82
  }
83
83
  };
84
- export var BSC = {
84
+ export const BSC = {
85
85
  id: ChainIds.BSC,
86
86
  name: 'BNB Smart Chain',
87
87
  type: ChainType.EVM,
@@ -96,7 +96,7 @@ export var BSC = {
96
96
  symbol: 'BNB'
97
97
  }
98
98
  };
99
- export var Arbitrum = {
99
+ export const Arbitrum = {
100
100
  id: ChainIds.Arbitrum,
101
101
  name: 'Arbitrum One',
102
102
  type: ChainType.EVM,
@@ -111,7 +111,7 @@ export var Arbitrum = {
111
111
  decimals: 18
112
112
  }
113
113
  };
114
- export var Optimism = {
114
+ export const Optimism = {
115
115
  id: ChainIds.Optimism,
116
116
  name: 'OP Mainnet',
117
117
  type: ChainType.EVM,
@@ -126,7 +126,7 @@ export var Optimism = {
126
126
  decimals: 18
127
127
  }
128
128
  };
129
- export var Avalanche = {
129
+ export const Avalanche = {
130
130
  id: ChainIds.Avalanche,
131
131
  name: 'Avalanche',
132
132
  type: ChainType.EVM,
@@ -143,7 +143,7 @@ export var Avalanche = {
143
143
  };
144
144
 
145
145
  // OKX X1: https://www.okx.com/cn/x1/docs/developer/build-on-x1/quickstart
146
- export var X1Testnet = {
146
+ export const X1Testnet = {
147
147
  id: ChainIds.X1Testnet,
148
148
  name: 'X1 testnet',
149
149
  type: ChainType.EVM,
@@ -158,7 +158,7 @@ export var X1Testnet = {
158
158
  decimals: 18
159
159
  }
160
160
  };
161
- export var Scroll = {
161
+ export const Scroll = {
162
162
  id: ChainIds.Scroll,
163
163
  name: 'Scroll',
164
164
  type: ChainType.EVM,
@@ -173,7 +173,7 @@ export var Scroll = {
173
173
  decimals: 18
174
174
  }
175
175
  };
176
- export var ScrollSepolia = {
176
+ export const ScrollSepolia = {
177
177
  id: ChainIds.ScrollSepolia,
178
178
  name: 'Scroll Sepolia Testnet',
179
179
  type: ChainType.EVM,
@@ -188,7 +188,7 @@ export var ScrollSepolia = {
188
188
  decimals: 18
189
189
  }
190
190
  };
191
- export var Hardhat = {
191
+ export const Hardhat = {
192
192
  id: ChainIds.Hardhat,
193
193
  name: 'Hardhat',
194
194
  type: ChainType.EVM,
@@ -200,7 +200,7 @@ export var Hardhat = {
200
200
  decimals: 18
201
201
  }
202
202
  };
203
- export var Localhost = {
203
+ export const Localhost = {
204
204
  id: ChainIds.Localhost,
205
205
  name: 'Localhost',
206
206
  type: ChainType.EVM,
@@ -1,7 +1,7 @@
1
1
  import { createGetBrowserLink, SolanaChainIds } from '@ant-design/web3-common';
2
2
  import { SolanaColorful } from '@ant-design/web3-icons';
3
3
  import { jsx as _jsx } from "react/jsx-runtime";
4
- export var Solana = {
4
+ export const Solana = {
5
5
  id: SolanaChainIds.MainnetBeta,
6
6
  name: 'Solana',
7
7
  icon: /*#__PURE__*/_jsx(SolanaColorful, {}),
@@ -15,7 +15,7 @@ export var Solana = {
15
15
  decimals: 9
16
16
  }
17
17
  };
18
- export var SolanaDevnet = {
18
+ export const SolanaDevnet = {
19
19
  id: SolanaChainIds.Devnet,
20
20
  name: 'Solana Devnet',
21
21
  icon: /*#__PURE__*/_jsx(SolanaColorful, {}),
@@ -29,7 +29,7 @@ export var SolanaDevnet = {
29
29
  decimals: 9
30
30
  }
31
31
  };
32
- export var SolanaTestnet = {
32
+ export const SolanaTestnet = {
33
33
  id: SolanaChainIds.Testnet,
34
34
  name: 'Solana Testnet',
35
35
  icon: /*#__PURE__*/_jsx(SolanaColorful, {}),
@@ -1,7 +1,7 @@
1
1
  import { EthereumColorful } from '@ant-design/web3-icons';
2
2
  import { BSC, Mainnet } from "../chains/ethereum";
3
3
  import { jsx as _jsx } from "react/jsx-runtime";
4
- export var ETH = {
4
+ export const ETH = {
5
5
  name: 'Ethereum',
6
6
  symbol: 'ETH',
7
7
  decimal: 18,
@@ -2,7 +2,7 @@ import { UsdcColorful } from '@ant-design/web3-icons';
2
2
  import { Arbitrum, Avalanche, Mainnet, Optimism, Polygon } from "../chains/ethereum";
3
3
  import { Solana } from "../solana";
4
4
  import { jsx as _jsx } from "react/jsx-runtime";
5
- export var USDC = {
5
+ export const USDC = {
6
6
  name: 'USDC',
7
7
  symbol: 'USDC',
8
8
  decimal: 6,
@@ -1,7 +1,7 @@
1
1
  import { USDTColorful } from '@ant-design/web3-icons';
2
2
  import { Arbitrum, BSC, Mainnet, Optimism, Polygon } from "../chains/ethereum";
3
3
  import { jsx as _jsx } from "react/jsx-runtime";
4
- export var USDT = {
4
+ export const USDT = {
5
5
  name: 'Tether USD',
6
6
  symbol: 'USDT',
7
7
  decimal: 6,
@@ -1,6 +1,6 @@
1
1
  import { BackpackColorful, ChromeCircleColorful } from '@ant-design/web3-icons';
2
2
  import { jsx as _jsx } from "react/jsx-runtime";
3
- export var metadata_Backpack = {
3
+ export const metadata_Backpack = {
4
4
  icon: /*#__PURE__*/_jsx(BackpackColorful, {}),
5
5
  name: 'Backpack',
6
6
  remark: 'Backpack Wallet',
@@ -1,6 +1,6 @@
1
1
  import { ChromeCircleColorful, CoinbaseWalletCircleColorful } from '@ant-design/web3-icons';
2
2
  import { jsx as _jsx } from "react/jsx-runtime";
3
- export var metadata_CoinbaseWallet = {
3
+ export const metadata_CoinbaseWallet = {
4
4
  icon: /*#__PURE__*/_jsx(CoinbaseWalletCircleColorful, {}),
5
5
  name: 'Coinbase Wallet',
6
6
  remark: 'Coinbase Wallet',
@@ -1,24 +1,25 @@
1
1
  import { ChainType } from '@ant-design/web3-common';
2
2
  import { ImTokenColorful } from '@ant-design/web3-icons';
3
3
  import { jsx as _jsx } from "react/jsx-runtime";
4
- export var metadata_imToken = {
4
+ export const metadata_imToken = {
5
5
  icon: /*#__PURE__*/_jsx(ImTokenColorful, {}),
6
6
  name: 'imToken',
7
7
  remark: 'Connect with mobile APP',
8
8
  app: {
9
9
  link: 'https://token.im/download'
10
10
  },
11
- transferQRCodeFormatter: function transferQRCodeFormatter(params) {
12
- var toAddress = params.toAddress,
13
- chainId = params.chainId,
14
- amount = params.amount,
15
- _params$tokenAddress = params.tokenAddress,
16
- tokenAddress = _params$tokenAddress === void 0 ? '' : _params$tokenAddress,
17
- decimal = params.decimal;
11
+ transferQRCodeFormatter: params => {
12
+ const {
13
+ toAddress,
14
+ chainId,
15
+ amount,
16
+ tokenAddress = '',
17
+ decimal
18
+ } = params;
18
19
  if (tokenAddress) {
19
- return "ethereum:".concat(toAddress, "@").concat(chainId, "?contractAddress=").concat(tokenAddress, "&decimal=").concat(decimal, "&value=").concat(amount);
20
+ return `ethereum:${toAddress}@${chainId}?contractAddress=${tokenAddress}&decimal=${decimal}&value=${amount}`;
20
21
  } else {
21
- return "ethereum:".concat(toAddress, "@").concat(chainId, "?decimal=18&value=").concat(amount);
22
+ return `ethereum:${toAddress}@${chainId}?decimal=18&value=${amount}`;
22
23
  }
23
24
  },
24
25
  supportChainTypes: [ChainType.EVM]
@@ -1,7 +1,7 @@
1
1
  import { ChainType } from '@ant-design/web3-common';
2
2
  import { ChromeCircleColorful, MetaMaskColorful } from '@ant-design/web3-icons';
3
3
  import { jsx as _jsx } from "react/jsx-runtime";
4
- export var metadata_MetaMask = {
4
+ export const metadata_MetaMask = {
5
5
  icon: /*#__PURE__*/_jsx(MetaMaskColorful, {}),
6
6
  name: 'MetaMask',
7
7
  remark: 'MetaMask Wallet',
@@ -16,17 +16,18 @@ export var metadata_MetaMask = {
16
16
  description: 'Access your wallet right from your favorite web browser.'
17
17
  }],
18
18
  group: 'Popular',
19
- transferQRCodeFormatter: function transferQRCodeFormatter(params) {
20
- var toAddress = params.toAddress,
21
- chainId = params.chainId,
22
- amount = params.amount,
23
- _params$tokenAddress = params.tokenAddress,
24
- tokenAddress = _params$tokenAddress === void 0 ? '' : _params$tokenAddress,
25
- decimal = params.decimal;
19
+ transferQRCodeFormatter: params => {
20
+ const {
21
+ toAddress,
22
+ chainId,
23
+ amount,
24
+ tokenAddress = '',
25
+ decimal
26
+ } = params;
26
27
  if (tokenAddress) {
27
- return "ethereum:".concat(tokenAddress, "@").concat(chainId, "/transfer?address=").concat(toAddress, "&uint256=").concat(Number(amount) * Math.pow(10, 18 - decimal));
28
+ return `ethereum:${tokenAddress}@${chainId}/transfer?address=${toAddress}&uint256=${Number(amount) * Math.pow(10, 18 - decimal)}`;
28
29
  } else {
29
- return "ethereum:".concat(toAddress, "@").concat(chainId, "?value=").concat(amount);
30
+ return `ethereum:${toAddress}@${chainId}?value=${amount}`;
30
31
  }
31
32
  },
32
33
  supportChainTypes: [ChainType.EVM]
@@ -1,6 +1,6 @@
1
1
  import { ScanColorful } from '@ant-design/web3-icons';
2
2
  import { jsx as _jsx } from "react/jsx-runtime";
3
- export var metadata_MobileConnect = {
3
+ export const metadata_MobileConnect = {
4
4
  icon: /*#__PURE__*/_jsx(ScanColorful, {}),
5
5
  name: 'Scan QR Code',
6
6
  remark: 'Connect with mobile APP',
@@ -1,6 +1,6 @@
1
1
  import { ChromeCircleColorful, OkxWalletColorful } from '@ant-design/web3-icons';
2
2
  import { jsx as _jsx } from "react/jsx-runtime";
3
- export var metadata_OkxWallet = {
3
+ export const metadata_OkxWallet = {
4
4
  icon: /*#__PURE__*/_jsx(OkxWalletColorful, {}),
5
5
  name: 'OKX Wallet',
6
6
  remark: 'OKX Wallet',
@@ -1,6 +1,6 @@
1
1
  import { ChromeCircleColorful, PhantomColorful } from '@ant-design/web3-icons';
2
2
  import { jsx as _jsx } from "react/jsx-runtime";
3
- export var metadata_Phantom = {
3
+ export const metadata_Phantom = {
4
4
  icon: /*#__PURE__*/_jsx(PhantomColorful, {}),
5
5
  name: 'Phantom',
6
6
  remark: 'Phantom Wallet',
@@ -1,6 +1,6 @@
1
1
  import { ChromeCircleColorful, SafeheronColorful } from '@ant-design/web3-icons';
2
2
  import { jsx as _jsx } from "react/jsx-runtime";
3
- export var metadata_Safeheron = {
3
+ export const metadata_Safeheron = {
4
4
  icon: /*#__PURE__*/_jsx(SafeheronColorful, {}),
5
5
  name: 'Safeheron',
6
6
  remark: 'Safeheron Wallet',
@@ -1,7 +1,7 @@
1
1
  import { ChainType } from '@ant-design/web3-common';
2
2
  import { ChromeCircleColorful, TokenPocketColorful } from '@ant-design/web3-icons';
3
3
  import { jsx as _jsx } from "react/jsx-runtime";
4
- export var metadata_TokenPocket = {
4
+ export const metadata_TokenPocket = {
5
5
  icon: /*#__PURE__*/_jsx(TokenPocketColorful, {}),
6
6
  name: 'TokenPocket',
7
7
  remark: 'TokenPocket',
@@ -1,6 +1,6 @@
1
1
  import { ChromeCircleColorful, TrustWalletColorful } from '@ant-design/web3-icons';
2
2
  import { jsx as _jsx } from "react/jsx-runtime";
3
- export var metadata_Trust = {
3
+ export const metadata_Trust = {
4
4
  icon: /*#__PURE__*/_jsx(TrustWalletColorful, {}),
5
5
  name: 'Trust',
6
6
  remark: 'Trust Wallet',
@@ -1,6 +1,6 @@
1
1
  import { ChromeCircleColorful, UnisatColorful } from '@ant-design/web3-icons';
2
2
  import { jsx as _jsx } from "react/jsx-runtime";
3
- export var metadata_Unisat = {
3
+ export const metadata_Unisat = {
4
4
  icon: /*#__PURE__*/_jsx(UnisatColorful, {}),
5
5
  name: 'Unisat Wallet',
6
6
  remark: 'Unisat Wallet',
@@ -1,6 +1,6 @@
1
1
  import { WalletConnectColorful } from '@ant-design/web3-icons';
2
2
  import { jsx as _jsx } from "react/jsx-runtime";
3
- export var metadata_WalletConnect = {
3
+ export const metadata_WalletConnect = {
4
4
  icon: /*#__PURE__*/_jsx(WalletConnectColorful, {}),
5
5
  name: 'WalletConnect',
6
6
  remark: 'Connect with mobile APP',
@@ -1,6 +1,6 @@
1
1
  import { ChromeCircleColorful, XverseColorful } from '@ant-design/web3-icons';
2
2
  import { jsx as _jsx } from "react/jsx-runtime";
3
- export var metadata_Xverse = {
3
+ export const metadata_Xverse = {
4
4
  icon: /*#__PURE__*/_jsx(XverseColorful, {}),
5
5
  name: 'Xverse',
6
6
  remark: 'Xverse Wallet',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ant-design/web3-assets",
3
- "version": "1.10.0",
3
+ "version": "1.10.1",
4
4
  "type": "module",
5
5
  "main": "dist/esm/index.js",
6
6
  "module": "dist/esm/index.js",
@@ -64,8 +64,8 @@
64
64
  "url": "https://github.com/ant-design/ant-design-web3"
65
65
  },
66
66
  "dependencies": {
67
- "@ant-design/web3-icons": "1.8.0",
68
- "@ant-design/web3-common": "1.12.0"
67
+ "@ant-design/web3-icons": "1.8.1",
68
+ "@ant-design/web3-common": "1.12.1"
69
69
  },
70
70
  "devDependencies": {
71
71
  "@types/react": "^18.3.3",
@@ -73,7 +73,7 @@
73
73
  "father": "^4.4.4",
74
74
  "react": "^18.2.0",
75
75
  "react-dom": "^18.2.0",
76
- "typescript": "^5.5.2"
76
+ "typescript": "^5.5.4"
77
77
  },
78
78
  "peerDependencies": {
79
79
  "react": ">=17.0.0",