@ant-design/web3-assets 0.1.0 → 0.1.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,22 @@
1
1
  # @ant-design/web3-assets
2
2
 
3
+ ## 0.1.1
4
+
5
+ ### Patch Changes
6
+
7
+ - 2d7ae4f: refactor: auto config wagmi provider chains
8
+ - 0df085f: feat: Add and update circle icons
9
+ - c15bfdf: feat: BrowserLink support get url from chain in @ant-design/web3-assets
10
+ - e4535ff: feat: add new wallet CoinbaseWallet
11
+ - Updated dependencies [2d7ae4f]
12
+ - Updated dependencies [0df085f]
13
+ - Updated dependencies [9bac342]
14
+ - Updated dependencies [3fbd1eb]
15
+ - Updated dependencies [39782e4]
16
+ - Updated dependencies [c15bfdf]
17
+ - @ant-design/web3-common@0.1.1
18
+ - @ant-design/web3-icons@0.2.0
19
+
3
20
  ## 0.1.0
4
21
 
5
22
  ### Patch Changes
@@ -1 +1 @@
1
- {"version":3,"file":"chains.d.ts","sourceRoot":"","sources":["chains.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,KAAK,EAAY,MAAM,yBAAyB,CAAC;AAU/D,eAAO,MAAM,OAAO,EAAE,KAKrB,CAAC;AAEF,eAAO,MAAM,MAAM,EAAE,KAKpB,CAAC;AAEF,eAAO,MAAM,OAAO,EAAE,KAKrB,CAAC;AAEF,eAAO,MAAM,GAAG,EAAE,KAKjB,CAAC;AAEF,eAAO,MAAM,QAAQ,EAAE,KAKtB,CAAC;AAEF,eAAO,MAAM,QAAQ,EAAE,KAKtB,CAAC"}
1
+ {"version":3,"file":"chains.d.ts","sourceRoot":"","sources":["chains.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,KAAK,EAAY,MAAM,yBAAyB,CAAC;AAY/D,eAAO,MAAM,OAAO,EAAE,KAgBrB,CAAC;AAEF,eAAO,MAAM,MAAM,EAAE,KAKpB,CAAC;AAEF,eAAO,MAAM,OAAO,EAAE,KAKrB,CAAC;AAEF,eAAO,MAAM,GAAG,EAAE,KAKjB,CAAC;AAEF,eAAO,MAAM,QAAQ,EAAE,KAKtB,CAAC;AAEF,eAAO,MAAM,QAAQ,EAAE,KAKtB,CAAC"}
@@ -1,11 +1,23 @@
1
1
  import { ChainIds } from '@ant-design/web3-common';
2
- import { EthereumColorful, OptimismColorful, BSCColorful, ArbitrumColorful, PolygonColorful } from '@ant-design/web3-icons';
2
+ import { EthereumCircleColorful, OptimismCircleColorful, BSCCircleColorful, ArbitrumCircleColorful, PolygonCircleColorful, EtherscanCircleColorful, EthereumFilled } from '@ant-design/web3-icons';
3
3
  import { jsx as _jsx } from "react/jsx-runtime";
4
4
  export var Mainnet = {
5
5
  id: ChainIds.Mainnet,
6
6
  name: 'Ethereum',
7
- icon: /*#__PURE__*/_jsx(EthereumColorful, {}),
7
+ icon: /*#__PURE__*/_jsx(EthereumCircleColorful, {}),
8
+ browser: {
9
+ icon: /*#__PURE__*/_jsx(EtherscanCircleColorful, {}),
10
+ getBrowserLink: function getBrowserLink(address, type) {
11
+ if (type === 'address') {
12
+ return "https://etherscan.io/address/".concat(address);
13
+ } else if (type === 'transaction') {
14
+ return "https://etherscan.io/tx/".concat(address);
15
+ }
16
+ throw new Error("getBrowserLink unsupported type ".concat(type));
17
+ }
18
+ },
8
19
  nativeCurrency: {
20
+ icon: /*#__PURE__*/_jsx(EthereumFilled, {}),
9
21
  name: 'Ether',
10
22
  symbol: 'ETH',
11
23
  decimals: 18
@@ -14,7 +26,7 @@ export var Mainnet = {
14
26
  export var Goerli = {
15
27
  id: ChainIds.Goerli,
16
28
  name: 'Goerli',
17
- icon: /*#__PURE__*/_jsx(EthereumColorful, {}),
29
+ icon: /*#__PURE__*/_jsx(EthereumCircleColorful, {}),
18
30
  nativeCurrency: {
19
31
  name: 'Ether',
20
32
  symbol: 'ETH',
@@ -24,7 +36,7 @@ export var Goerli = {
24
36
  export var Polygon = {
25
37
  id: ChainIds.Polygon,
26
38
  name: 'Polygon',
27
- icon: /*#__PURE__*/_jsx(PolygonColorful, {}),
39
+ icon: /*#__PURE__*/_jsx(PolygonCircleColorful, {}),
28
40
  nativeCurrency: {
29
41
  name: 'MATIC',
30
42
  symbol: 'MATIC',
@@ -34,7 +46,7 @@ export var Polygon = {
34
46
  export var BSC = {
35
47
  id: ChainIds.BSC,
36
48
  name: 'BNB Smart Chain',
37
- icon: /*#__PURE__*/_jsx(BSCColorful, {}),
49
+ icon: /*#__PURE__*/_jsx(BSCCircleColorful, {}),
38
50
  nativeCurrency: {
39
51
  decimals: 18,
40
52
  name: 'BNB',
@@ -44,7 +56,7 @@ export var BSC = {
44
56
  export var Arbitrum = {
45
57
  id: ChainIds.Arbitrum,
46
58
  name: 'Arbitrum One',
47
- icon: /*#__PURE__*/_jsx(ArbitrumColorful, {}),
59
+ icon: /*#__PURE__*/_jsx(ArbitrumCircleColorful, {}),
48
60
  nativeCurrency: {
49
61
  name: 'Ether',
50
62
  symbol: 'ETH',
@@ -54,7 +66,7 @@ export var Arbitrum = {
54
66
  export var Optimism = {
55
67
  id: ChainIds.Optimism,
56
68
  name: 'OP Mainnet',
57
- icon: /*#__PURE__*/_jsx(OptimismColorful, {}),
69
+ icon: /*#__PURE__*/_jsx(OptimismCircleColorful, {}),
58
70
  nativeCurrency: {
59
71
  name: 'Ether',
60
72
  symbol: 'ETH',
@@ -0,0 +1,2 @@
1
+ import type { WalletMetadata } from '@ant-design/web3-common';
2
+ export declare const metadata_CoinbaseWallet: WalletMetadata;
@@ -0,0 +1 @@
1
+ {"version":3,"file":"coinbase-wallet.d.ts","sourceRoot":"","sources":["coinbase-wallet.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AAG9D,eAAO,MAAM,uBAAuB,EAAE,cAgBrC,CAAC"}
@@ -0,0 +1,17 @@
1
+ import { CoinbaseWalletCircleColorful, ChromeCircleColorful } from '@ant-design/web3-icons';
2
+ import { jsx as _jsx } from "react/jsx-runtime";
3
+ export var metadata_CoinbaseWallet = {
4
+ icon: /*#__PURE__*/_jsx(CoinbaseWalletCircleColorful, {}),
5
+ name: 'Coinbase Wallet',
6
+ remark: 'Coinbase Wallet',
7
+ app: {
8
+ link: 'https://www.coinbase.com/wallet'
9
+ },
10
+ extensions: [{
11
+ key: 'Chrome',
12
+ browserIcon: /*#__PURE__*/_jsx(ChromeCircleColorful, {}),
13
+ browserName: 'Chrome',
14
+ link: 'https://chromewebstore.google.com/detail/coinbase-wallet-extension/hnfanknocfeofbddgcijnmhnfnkdnaad',
15
+ description: 'Access your wallet right from your favorite web browser.'
16
+ }]
17
+ };
@@ -1,2 +1,3 @@
1
1
  export * from './meta-mask';
2
2
  export * from './wallet-connect';
3
+ export * from './coinbase-wallet';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC;AAC5B,cAAc,kBAAkB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC;AAC5B,cAAc,kBAAkB,CAAC;AACjC,cAAc,mBAAmB,CAAC"}
@@ -1,2 +1,3 @@
1
1
  export * from "./meta-mask";
2
- export * from "./wallet-connect";
2
+ export * from "./wallet-connect";
3
+ export * from "./coinbase-wallet";
@@ -1,4 +1,4 @@
1
- import { MetaMaskColorful, ChromeColorful } from '@ant-design/web3-icons';
1
+ import { MetaMaskColorful, ChromeCircleColorful } from '@ant-design/web3-icons';
2
2
  import { jsx as _jsx } from "react/jsx-runtime";
3
3
  export var metadata_MetaMask = {
4
4
  icon: /*#__PURE__*/_jsx(MetaMaskColorful, {}),
@@ -9,7 +9,7 @@ export var metadata_MetaMask = {
9
9
  },
10
10
  extensions: [{
11
11
  key: 'Chrome',
12
- browserIcon: /*#__PURE__*/_jsx(ChromeColorful, {}),
12
+ browserIcon: /*#__PURE__*/_jsx(ChromeCircleColorful, {}),
13
13
  browserName: 'Chrome',
14
14
  link: 'https://chrome.google.com/webstore/detail/metamask/nkbihfbeogaeaoehlefnkodbefgpgknn',
15
15
  description: 'Access your wallet right from your favorite web browser.'
@@ -1 +1 @@
1
- {"version":3,"file":"wallet-connect.d.ts","sourceRoot":"","sources":["wallet-connect.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AAG9D,eAAO,MAAM,sBAAsB,EAAE,cAQpC,CAAC"}
1
+ {"version":3,"file":"wallet-connect.d.ts","sourceRoot":"","sources":["wallet-connect.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AAG9D,eAAO,MAAM,sBAAsB,EAAE,cAOpC,CAAC"}
@@ -6,6 +6,5 @@ export var metadata_WalletConnect = {
6
6
  remark: 'Connect with mobile APP',
7
7
  app: {
8
8
  link: 'https://walletconnect.com/'
9
- },
10
- group: 'Popular'
9
+ }
11
10
  };
@@ -10,8 +10,20 @@ var _jsxRuntime = require("react/jsx-runtime");
10
10
  const Mainnet = {
11
11
  id: _web3Common.ChainIds.Mainnet,
12
12
  name: 'Ethereum',
13
- icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_web3Icons.EthereumColorful, {}),
13
+ icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_web3Icons.EthereumCircleColorful, {}),
14
+ browser: {
15
+ icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_web3Icons.EtherscanCircleColorful, {}),
16
+ getBrowserLink: (address, type) => {
17
+ if (type === 'address') {
18
+ return `https://etherscan.io/address/${address}`;
19
+ } else if (type === 'transaction') {
20
+ return `https://etherscan.io/tx/${address}`;
21
+ }
22
+ throw new Error(`getBrowserLink unsupported type ${type}`);
23
+ }
24
+ },
14
25
  nativeCurrency: {
26
+ icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_web3Icons.EthereumFilled, {}),
15
27
  name: 'Ether',
16
28
  symbol: 'ETH',
17
29
  decimals: 18
@@ -21,7 +33,7 @@ exports.Mainnet = Mainnet;
21
33
  const Goerli = {
22
34
  id: _web3Common.ChainIds.Goerli,
23
35
  name: 'Goerli',
24
- icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_web3Icons.EthereumColorful, {}),
36
+ icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_web3Icons.EthereumCircleColorful, {}),
25
37
  nativeCurrency: {
26
38
  name: 'Ether',
27
39
  symbol: 'ETH',
@@ -32,7 +44,7 @@ exports.Goerli = Goerli;
32
44
  const Polygon = {
33
45
  id: _web3Common.ChainIds.Polygon,
34
46
  name: 'Polygon',
35
- icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_web3Icons.PolygonColorful, {}),
47
+ icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_web3Icons.PolygonCircleColorful, {}),
36
48
  nativeCurrency: {
37
49
  name: 'MATIC',
38
50
  symbol: 'MATIC',
@@ -43,7 +55,7 @@ exports.Polygon = Polygon;
43
55
  const BSC = {
44
56
  id: _web3Common.ChainIds.BSC,
45
57
  name: 'BNB Smart Chain',
46
- icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_web3Icons.BSCColorful, {}),
58
+ icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_web3Icons.BSCCircleColorful, {}),
47
59
  nativeCurrency: {
48
60
  decimals: 18,
49
61
  name: 'BNB',
@@ -54,7 +66,7 @@ exports.BSC = BSC;
54
66
  const Arbitrum = {
55
67
  id: _web3Common.ChainIds.Arbitrum,
56
68
  name: 'Arbitrum One',
57
- icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_web3Icons.ArbitrumColorful, {}),
69
+ icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_web3Icons.ArbitrumCircleColorful, {}),
58
70
  nativeCurrency: {
59
71
  name: 'Ether',
60
72
  symbol: 'ETH',
@@ -65,7 +77,7 @@ exports.Arbitrum = Arbitrum;
65
77
  const Optimism = {
66
78
  id: _web3Common.ChainIds.Optimism,
67
79
  name: 'OP Mainnet',
68
- icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_web3Icons.OptimismColorful, {}),
80
+ icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_web3Icons.OptimismCircleColorful, {}),
69
81
  nativeCurrency: {
70
82
  name: 'Ether',
71
83
  symbol: 'ETH',
@@ -0,0 +1,2 @@
1
+ import type { WalletMetadata } from '@ant-design/web3-common';
2
+ export declare const metadata_CoinbaseWallet: WalletMetadata;
@@ -0,0 +1,24 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.metadata_CoinbaseWallet = void 0;
7
+ var _web3Icons = require("@ant-design/web3-icons");
8
+ var _jsxRuntime = require("react/jsx-runtime");
9
+ const metadata_CoinbaseWallet = {
10
+ icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_web3Icons.CoinbaseWalletCircleColorful, {}),
11
+ name: 'Coinbase Wallet',
12
+ remark: 'Coinbase Wallet',
13
+ app: {
14
+ link: 'https://www.coinbase.com/wallet'
15
+ },
16
+ extensions: [{
17
+ key: 'Chrome',
18
+ browserIcon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_web3Icons.ChromeCircleColorful, {}),
19
+ browserName: 'Chrome',
20
+ link: 'https://chromewebstore.google.com/detail/coinbase-wallet-extension/hnfanknocfeofbddgcijnmhnfnkdnaad',
21
+ description: 'Access your wallet right from your favorite web browser.'
22
+ }]
23
+ };
24
+ exports.metadata_CoinbaseWallet = metadata_CoinbaseWallet;
@@ -1,2 +1,3 @@
1
1
  export * from './meta-mask';
2
2
  export * from './wallet-connect';
3
+ export * from './coinbase-wallet';
@@ -24,4 +24,15 @@ Object.keys(_walletConnect).forEach(function (key) {
24
24
  return _walletConnect[key];
25
25
  }
26
26
  });
27
+ });
28
+ var _coinbaseWallet = require("./coinbase-wallet");
29
+ Object.keys(_coinbaseWallet).forEach(function (key) {
30
+ if (key === "default" || key === "__esModule") return;
31
+ if (key in exports && exports[key] === _coinbaseWallet[key]) return;
32
+ Object.defineProperty(exports, key, {
33
+ enumerable: true,
34
+ get: function () {
35
+ return _coinbaseWallet[key];
36
+ }
37
+ });
27
38
  });
@@ -15,7 +15,7 @@ const metadata_MetaMask = {
15
15
  },
16
16
  extensions: [{
17
17
  key: 'Chrome',
18
- browserIcon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_web3Icons.ChromeColorful, {}),
18
+ browserIcon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_web3Icons.ChromeCircleColorful, {}),
19
19
  browserName: 'Chrome',
20
20
  link: 'https://chrome.google.com/webstore/detail/metamask/nkbihfbeogaeaoehlefnkodbefgpgknn',
21
21
  description: 'Access your wallet right from your favorite web browser.'
@@ -12,7 +12,6 @@ const metadata_WalletConnect = {
12
12
  remark: 'Connect with mobile APP',
13
13
  app: {
14
14
  link: 'https://walletconnect.com/'
15
- },
16
- group: 'Popular'
15
+ }
17
16
  };
18
17
  exports.metadata_WalletConnect = metadata_WalletConnect;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ant-design/web3-assets",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "exports": {
5
5
  "import": "./dist/esm/index.js",
6
6
  "require": "./dist/lib/index.js",
@@ -12,8 +12,8 @@
12
12
  "README.md"
13
13
  ],
14
14
  "dependencies": {
15
- "@ant-design/web3-icons": "0.1.0",
16
- "@ant-design/web3-common": "0.1.0"
15
+ "@ant-design/web3-common": "0.1.1",
16
+ "@ant-design/web3-icons": "0.2.0"
17
17
  },
18
18
  "devDependencies": {
19
19
  "@types/react": "^18.2.20",