viem 0.2.0-jxom-async-verify-message.20230321T000803 → 0.2.0-jxom-local-accounts.20230321T212822
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/accounts/package.json +4 -0
- package/dist/abi.d.ts +3 -3
- package/dist/abi.js +2 -2
- package/dist/abi.mjs +1 -1
- package/dist/accounts/index.d.ts +33 -0
- package/dist/accounts/index.js +89 -0
- package/dist/accounts/index.js.map +1 -0
- package/dist/accounts/index.mjs +89 -0
- package/dist/accounts/index.mjs.map +1 -0
- package/dist/{chain-b2e88e30.d.ts → chain-75b0942e.d.ts} +60 -60
- package/dist/{chain-c4f924cf.d.ts → chain-f8db473f.d.ts} +1 -1
- package/dist/chains.d.ts +3 -3
- package/dist/chains.js +63 -63
- package/dist/chains.mjs +1 -1
- package/dist/{chunk-OZCG5IO7.mjs → chunk-6UKHPIXX.mjs} +2 -2
- package/dist/chunk-FNVFGFWN.mjs +31 -0
- package/dist/chunk-FNVFGFWN.mjs.map +1 -0
- package/dist/chunk-FQM5MF6U.js +31 -0
- package/dist/chunk-FQM5MF6U.js.map +1 -0
- package/dist/{chunk-FEPL5HFW.mjs → chunk-IVRML3IK.mjs} +75 -66
- package/dist/chunk-IVRML3IK.mjs.map +1 -0
- package/dist/{chunk-2NJCP2DN.js → chunk-LYQKHD7R.js} +19 -19
- package/dist/{chunk-22BDIC7J.js → chunk-NJSAEA2H.js} +75 -66
- package/dist/chunk-NJSAEA2H.js.map +1 -0
- package/dist/contract.d.ts +9 -8
- package/dist/contract.js +2 -2
- package/dist/contract.mjs +1 -1
- package/dist/{createClient-d4f1dea1.d.ts → createClient-f87255c1.d.ts} +2 -2
- package/dist/{createPublicClient-3a714a8d.d.ts → createPublicClient-d2c37c92.d.ts} +12 -5
- package/dist/{eip1193-cd3e872a.d.ts → eip1193-ae706fd8.d.ts} +1 -1
- package/dist/{encodeFunctionResult-750c9055.d.ts → encodeFunctionResult-4792a6a3.d.ts} +1 -1
- package/dist/{encodePacked-de74201f.d.ts → encodePacked-3fcdd54b.d.ts} +1 -1
- package/dist/ens.d.ts +6 -5
- package/dist/ens.js +3 -3
- package/dist/ens.mjs +2 -2
- package/dist/ethers.d.ts +5 -4
- package/dist/ethers.js +7 -5
- package/dist/ethers.js.map +1 -1
- package/dist/ethers.mjs +7 -5
- package/dist/ethers.mjs.map +1 -1
- package/dist/{formatAbiItem-fdbdda39.d.ts → formatAbiItem-765ebc53.d.ts} +1 -1
- package/dist/{getAbiItem-9d709e3b.d.ts → getAbiItem-693e6e1b.d.ts} +1 -1
- package/dist/index.d.ts +15 -14
- package/dist/index.js +91 -91
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +4 -4
- package/dist/index.mjs.map +1 -1
- package/dist/parseAccount-2d7ea01d.d.ts +6 -0
- package/dist/{parseGwei-b138c041.d.ts → parseGwei-377678bc.d.ts} +10 -11
- package/dist/public.d.ts +6 -5
- package/dist/public.js +2 -2
- package/dist/public.mjs +1 -1
- package/dist/{test-c70126a6.d.ts → test-98c0b642.d.ts} +3 -3
- package/dist/test.d.ts +5 -5
- package/dist/test.js +2 -2
- package/dist/test.mjs +1 -1
- package/dist/{account-07d04222.d.ts → typedData-ade018d6.d.ts} +46 -27
- package/dist/utils/index.d.ts +16 -14
- package/dist/utils/index.js +2 -2
- package/dist/utils/index.mjs +3 -3
- package/dist/wallet.d.ts +6 -5
- package/dist/wallet.js +2 -2
- package/dist/wallet.mjs +1 -1
- package/dist/window.d.ts +2 -2
- package/package.json +9 -1
- package/dist/chunk-22BDIC7J.js.map +0 -1
- package/dist/chunk-FEPL5HFW.mjs.map +0 -1
- /package/dist/{chunk-OZCG5IO7.mjs.map → chunk-6UKHPIXX.mjs.map} +0 -0
- /package/dist/{chunk-2NJCP2DN.js.map → chunk-LYQKHD7R.js.map} +0 -0
package/dist/abi.d.ts
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
export { ParseAbi, ParseAbiItem, ParseAbiParameter, ParseAbiParameters, parseAbi, parseAbiItem, parseAbiParameter, parseAbiParameters } from 'abitype';
|
2
|
-
export { D as DecodeAbiParametersReturnType, E as EncodeAbiParametersReturnType, G as GetAbiItemParameters, d as decodeAbiParameters, e as encodeAbiParameters, g as getAbiItem } from './getAbiItem-
|
3
|
-
export { e as encodePacked } from './encodePacked-
|
4
|
-
import './chain-
|
2
|
+
export { D as DecodeAbiParametersReturnType, E as EncodeAbiParametersReturnType, G as GetAbiItemParameters, d as decodeAbiParameters, e as encodeAbiParameters, g as getAbiItem } from './getAbiItem-693e6e1b.js';
|
3
|
+
export { e as encodePacked } from './encodePacked-3fcdd54b.js';
|
4
|
+
import './chain-75b0942e.js';
|
5
5
|
import '@wagmi/chains';
|
package/dist/abi.js
CHANGED
@@ -7,7 +7,7 @@
|
|
7
7
|
|
8
8
|
|
9
9
|
|
10
|
-
var
|
10
|
+
var _chunkNJSAEA2Hjs = require('./chunk-NJSAEA2H.js');
|
11
11
|
|
12
12
|
|
13
13
|
|
@@ -17,5 +17,5 @@ var _chunk22BDIC7Jjs = require('./chunk-22BDIC7J.js');
|
|
17
17
|
|
18
18
|
|
19
19
|
|
20
|
-
exports.decodeAbiParameters =
|
20
|
+
exports.decodeAbiParameters = _chunkNJSAEA2Hjs.decodeAbiParameters; exports.encodeAbiParameters = _chunkNJSAEA2Hjs.encodeAbiParameters; exports.encodePacked = _chunkNJSAEA2Hjs.encodePacked; exports.getAbiItem = _chunkNJSAEA2Hjs.getAbiItem; exports.parseAbi = _chunkNJSAEA2Hjs.parseAbi; exports.parseAbiItem = _chunkNJSAEA2Hjs.parseAbiItem; exports.parseAbiParameter = _chunkNJSAEA2Hjs.parseAbiParameter; exports.parseAbiParameters = _chunkNJSAEA2Hjs.parseAbiParameters;
|
21
21
|
//# sourceMappingURL=abi.js.map
|
package/dist/abi.mjs
CHANGED
@@ -0,0 +1,33 @@
|
|
1
|
+
export { HDKey } from '@scure/bip32';
|
2
|
+
import { P as PrivateKeyAccount, a as AccountSource, J as JsonRpcAccount, C as CustomSource, L as LocalAccount, T as TypedDataDefinition } from '../typedData-ade018d6.js';
|
3
|
+
export { A as Account, a as AccountSource, C as CustomSource, H as HDAccount, b as HDOptions, J as JsonRpcAccount, L as LocalAccount, P as PrivateKeyAccount } from '../typedData-ade018d6.js';
|
4
|
+
import { H as Hex } from '../chain-75b0942e.js';
|
5
|
+
import { Address, TypedData } from 'abitype';
|
6
|
+
export { p as parseAccount } from '../parseAccount-2d7ea01d.js';
|
7
|
+
import '@wagmi/chains';
|
8
|
+
|
9
|
+
declare function privateKeyToAccount(privateKey: Hex): PrivateKeyAccount;
|
10
|
+
|
11
|
+
type GetAccountReturnType<TAccountSource extends AccountSource> = (TAccountSource extends Address ? JsonRpcAccount : never) | (TAccountSource extends CustomSource ? LocalAccount : never);
|
12
|
+
declare function toAccount<TAccountSource extends AccountSource>(source: TAccountSource): GetAccountReturnType<TAccountSource>;
|
13
|
+
|
14
|
+
declare function publicKeyToAddress(publicKey: Hex): Address;
|
15
|
+
|
16
|
+
type SignMessageParameters = {
|
17
|
+
message: string;
|
18
|
+
privateKey: Hex;
|
19
|
+
};
|
20
|
+
type SignMessageReturnType = Hex;
|
21
|
+
declare function signMessage({ message, privateKey, }: SignMessageParameters): Promise<SignMessageReturnType>;
|
22
|
+
|
23
|
+
type SignTypedDataParameters<TTypedData extends TypedData | {
|
24
|
+
[key: string]: unknown;
|
25
|
+
} = TypedData, TPrimaryType extends string = string> = TypedDataDefinition<TTypedData, TPrimaryType> & {
|
26
|
+
privateKey: Hex;
|
27
|
+
};
|
28
|
+
type SignTypedDataReturnType = Hex;
|
29
|
+
declare function signTypedData<TTypedData extends TypedData | {
|
30
|
+
[key: string]: unknown;
|
31
|
+
}, TPrimaryType extends string = string>({ privateKey, ...typedData }: SignTypedDataParameters<TTypedData, TPrimaryType>): Promise<SignTypedDataReturnType>;
|
32
|
+
|
33
|
+
export { SignMessageParameters, SignMessageReturnType, SignTypedDataParameters, SignTypedDataReturnType, privateKeyToAccount, publicKeyToAddress, signMessage, signTypedData, toAccount };
|
@@ -0,0 +1,89 @@
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
2
|
+
|
3
|
+
var _chunkFQM5MF6Ujs = require('../chunk-FQM5MF6U.js');
|
4
|
+
|
5
|
+
|
6
|
+
|
7
|
+
|
8
|
+
|
9
|
+
|
10
|
+
|
11
|
+
var _chunkNJSAEA2Hjs = require('../chunk-NJSAEA2H.js');
|
12
|
+
|
13
|
+
// src/accounts/index.ts
|
14
|
+
var _bip32 = require('@scure/bip32');
|
15
|
+
|
16
|
+
// src/accounts/privateKeyToAccount.ts
|
17
|
+
var _secp256k1 = require('@noble/secp256k1');
|
18
|
+
|
19
|
+
// src/accounts/utils/publicKeyToAddress.ts
|
20
|
+
function publicKeyToAddress(publicKey) {
|
21
|
+
const address = _chunkNJSAEA2Hjs.keccak256.call(void 0, `0x${publicKey.substring(4)}`).substring(26);
|
22
|
+
return _chunkNJSAEA2Hjs.checksumAddress.call(void 0, `0x${address}`);
|
23
|
+
}
|
24
|
+
|
25
|
+
// src/accounts/utils/sign.ts
|
26
|
+
|
27
|
+
async function sign({
|
28
|
+
hash,
|
29
|
+
privateKey
|
30
|
+
}) {
|
31
|
+
const [signature, recId] = await _secp256k1.sign.call(void 0, hash.slice(2), privateKey.slice(2), {
|
32
|
+
canonical: true,
|
33
|
+
recovered: true
|
34
|
+
});
|
35
|
+
return `0x${_secp256k1.Signature.fromHex(signature).toCompactHex()}${recId ? "1c" : "1b"}`;
|
36
|
+
}
|
37
|
+
|
38
|
+
// src/accounts/utils/signMessage.ts
|
39
|
+
async function signMessage({
|
40
|
+
message,
|
41
|
+
privateKey
|
42
|
+
}) {
|
43
|
+
return sign({ hash: _chunkNJSAEA2Hjs.hashMessage.call(void 0, message), privateKey });
|
44
|
+
}
|
45
|
+
|
46
|
+
// src/accounts/utils/signTypedData.ts
|
47
|
+
async function signTypedData({
|
48
|
+
privateKey,
|
49
|
+
...typedData
|
50
|
+
}) {
|
51
|
+
return sign({
|
52
|
+
hash: _chunkNJSAEA2Hjs.hashTypedData.call(void 0, typedData),
|
53
|
+
privateKey
|
54
|
+
});
|
55
|
+
}
|
56
|
+
|
57
|
+
// src/accounts/privateKeyToAccount.ts
|
58
|
+
function privateKeyToAccount(privateKey) {
|
59
|
+
const publicKey = _chunkNJSAEA2Hjs.toHex.call(void 0, _secp256k1.getPublicKey.call(void 0, privateKey.slice(2)));
|
60
|
+
const address = publicKeyToAddress(publicKey);
|
61
|
+
const account = _chunkFQM5MF6Ujs.toAccount.call(void 0, {
|
62
|
+
address,
|
63
|
+
async signMessage({ message }) {
|
64
|
+
return signMessage({ message, privateKey });
|
65
|
+
},
|
66
|
+
async signTransaction(_transaction) {
|
67
|
+
return "0x";
|
68
|
+
},
|
69
|
+
async signTypedData(typedData) {
|
70
|
+
return signTypedData({ ...typedData, privateKey });
|
71
|
+
}
|
72
|
+
});
|
73
|
+
return {
|
74
|
+
...account,
|
75
|
+
getPrivateKey: () => privateKey,
|
76
|
+
publicKey,
|
77
|
+
source: "privateKey"
|
78
|
+
};
|
79
|
+
}
|
80
|
+
|
81
|
+
|
82
|
+
|
83
|
+
|
84
|
+
|
85
|
+
|
86
|
+
|
87
|
+
|
88
|
+
exports.HDKey = _bip32.HDKey; exports.parseAccount = _chunkNJSAEA2Hjs.parseAccount; exports.privateKeyToAccount = privateKeyToAccount; exports.publicKeyToAddress = publicKeyToAddress; exports.signMessage = signMessage; exports.signTypedData = signTypedData; exports.toAccount = _chunkFQM5MF6Ujs.toAccount;
|
89
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../../src/accounts/index.ts","../../src/accounts/privateKeyToAccount.ts","../../src/accounts/utils/publicKeyToAddress.ts","../../src/accounts/utils/sign.ts","../../src/accounts/utils/signMessage.ts","../../src/accounts/utils/signTypedData.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,SAAS,aAAa;;;ACAtB,SAAS,oBAAoB;;;ACItB,SAAS,mBAAmB,WAAyB;AAC1D,QAAM,UAAU,UAAU,KAAK,UAAU,UAAU,CAAC,GAAG,EAAE,UAAU,EAAE;AACrE,SAAO,gBAAgB,KAAK,SAAS;AACvC;;;ACPA,SAAS,QAAQ,OAAO,iBAAiB;AAUzC,eAAsB,KAAK;AAAA,EACzB;AAAA,EACA;AACF,GAA4C;AAC1C,QAAM,CAAC,WAAW,KAAK,IAAI,MAAM,MAAM,KAAK,MAAM,CAAC,GAAG,WAAW,MAAM,CAAC,GAAG;AAAA,IACzE,WAAW;AAAA,IACX,WAAW;AAAA,EACb,CAAC;AACD,SAAO,KAAK,UAAU,QAAQ,SAAS,EAAE,aAAa,IACpD,QAAQ,OAAO;AAEnB;;;ACXA,eAAsB,YAAY;AAAA,EAChC;AAAA,EACA;AACF,GAA0D;AACxD,SAAO,KAAK,EAAE,MAAM,YAAY,OAAO,GAAG,WAAW,CAAC;AACxD;;;ACAA,eAAsB,cAGpB;AAAA,EACA;AAAA,EACA,GAAG;AACL,GAGqC;AACnC,SAAO,KAAK;AAAA,IACV,MAAM,cAAc,SAAoC;AAAA,IACxD;AAAA,EACF,CAAC;AACH;;;AJrBO,SAAS,oBAAoB,YAAoC;AACtE,QAAM,YAAY,MAAM,aAAa,WAAW,MAAM,CAAC,CAAC,CAAC;AACzD,QAAM,UAAU,mBAAmB,SAAS;AAE5C,QAAM,UAAU,UAAU;AAAA,IACxB;AAAA,IACA,MAAM,YAAY,EAAE,QAAQ,GAAG;AAC7B,aAAO,YAAY,EAAE,SAAS,WAAW,CAAC;AAAA,IAC5C;AAAA,IACA,MAAM,gBAAgB,cAAc;AAElC,aAAO;AAAA,IACT;AAAA,IACA,MAAM,cAAc,WAAW;AAC7B,aAAO,cAAc,EAAE,GAAG,WAAW,WAAW,CAAC;AAAA,IACnD;AAAA,EACF,CAAC;AAED,SAAO;AAAA,IACL,GAAG;AAAA,IACH,eAAe,MAAM;AAAA,IACrB;AAAA,IACA,QAAQ;AAAA,EACV;AACF","sourcesContent":["import { HDKey } from '@scure/bip32'\n\nexport { HDKey }\n\nexport { privateKeyToAccount } from './privateKeyToAccount'\n\nexport { toAccount } from './toAccount'\n\nexport type {\n Account,\n AccountSource,\n CustomSource,\n HDOptions,\n JsonRpcAccount,\n LocalAccount,\n HDAccount,\n PrivateKeyAccount,\n} from './types'\n\nexport type {\n SignMessageParameters,\n SignMessageReturnType,\n SignTypedDataParameters,\n SignTypedDataReturnType,\n} from './utils'\nexport {\n parseAccount,\n publicKeyToAddress,\n signMessage,\n signTypedData,\n} from './utils'\n","import { getPublicKey } from '@noble/secp256k1'\n\nimport type { Hex } from '../types'\nimport { toHex } from '../utils'\nimport { publicKeyToAddress, signMessage, signTypedData } from './utils'\nimport { toAccount } from './toAccount'\nimport type { PrivateKeyAccount } from './types'\n\nexport function privateKeyToAccount(privateKey: Hex): PrivateKeyAccount {\n const publicKey = toHex(getPublicKey(privateKey.slice(2)))\n const address = publicKeyToAddress(publicKey)\n\n const account = toAccount({\n address,\n async signMessage({ message }) {\n return signMessage({ message, privateKey })\n },\n async signTransaction(_transaction) {\n // TODO\n return '0x'\n },\n async signTypedData(typedData) {\n return signTypedData({ ...typedData, privateKey })\n },\n })\n\n return {\n ...account,\n getPrivateKey: () => privateKey,\n publicKey,\n source: 'privateKey',\n }\n}\n","import type { Address, Hex } from '../../types'\nimport { keccak256 } from '../../utils'\nimport { checksumAddress } from '../../utils/address'\n\nexport function publicKeyToAddress(publicKey: Hex): Address {\n const address = keccak256(`0x${publicKey.substring(4)}`).substring(26)\n return checksumAddress(`0x${address}`) as Address\n}\n","import { sign as sign_, Signature } from '@noble/secp256k1'\n\nimport type { Hex } from '../../types'\n\nexport type SignParameters = {\n hash: Hex\n privateKey: Hex\n}\nexport type SignReturnType = Hex\n\nexport async function sign({\n hash,\n privateKey,\n}: SignParameters): Promise<SignReturnType> {\n const [signature, recId] = await sign_(hash.slice(2), privateKey.slice(2), {\n canonical: true,\n recovered: true,\n })\n return `0x${Signature.fromHex(signature).toCompactHex()}${\n recId ? '1c' : '1b'\n }`\n}\n","import type { Hex } from '../../types'\nimport { hashMessage } from '../../utils'\nimport { sign } from './sign'\n\nexport type SignMessageParameters = {\n message: string\n privateKey: Hex\n}\nexport type SignMessageReturnType = Hex\n\nexport async function signMessage({\n message,\n privateKey,\n}: SignMessageParameters): Promise<SignMessageReturnType> {\n return sign({ hash: hashMessage(message), privateKey })\n}\n","import type { TypedData } from 'abitype'\n\nimport type { Hex, TypedDataDefinition } from '../../types'\nimport { HashTypedDataParameters, hashTypedData } from '../../utils'\nimport { sign } from './sign'\n\nexport type SignTypedDataParameters<\n TTypedData extends TypedData | { [key: string]: unknown } = TypedData,\n TPrimaryType extends string = string,\n> = TypedDataDefinition<TTypedData, TPrimaryType> & {\n privateKey: Hex\n}\n\nexport type SignTypedDataReturnType = Hex\n\nexport async function signTypedData<\n TTypedData extends TypedData | { [key: string]: unknown },\n TPrimaryType extends string = string,\n>({\n privateKey,\n ...typedData\n}: SignTypedDataParameters<\n TTypedData,\n TPrimaryType\n>): Promise<SignTypedDataReturnType> {\n return sign({\n hash: hashTypedData(typedData as HashTypedDataParameters),\n privateKey,\n })\n}\n"]}
|
@@ -0,0 +1,89 @@
|
|
1
|
+
import {
|
2
|
+
toAccount
|
3
|
+
} from "../chunk-FNVFGFWN.mjs";
|
4
|
+
import {
|
5
|
+
checksumAddress,
|
6
|
+
hashMessage,
|
7
|
+
hashTypedData,
|
8
|
+
keccak256,
|
9
|
+
parseAccount,
|
10
|
+
toHex
|
11
|
+
} from "../chunk-IVRML3IK.mjs";
|
12
|
+
|
13
|
+
// src/accounts/index.ts
|
14
|
+
import { HDKey } from "@scure/bip32";
|
15
|
+
|
16
|
+
// src/accounts/privateKeyToAccount.ts
|
17
|
+
import { getPublicKey } from "@noble/secp256k1";
|
18
|
+
|
19
|
+
// src/accounts/utils/publicKeyToAddress.ts
|
20
|
+
function publicKeyToAddress(publicKey) {
|
21
|
+
const address = keccak256(`0x${publicKey.substring(4)}`).substring(26);
|
22
|
+
return checksumAddress(`0x${address}`);
|
23
|
+
}
|
24
|
+
|
25
|
+
// src/accounts/utils/sign.ts
|
26
|
+
import { sign as sign_, Signature } from "@noble/secp256k1";
|
27
|
+
async function sign({
|
28
|
+
hash,
|
29
|
+
privateKey
|
30
|
+
}) {
|
31
|
+
const [signature, recId] = await sign_(hash.slice(2), privateKey.slice(2), {
|
32
|
+
canonical: true,
|
33
|
+
recovered: true
|
34
|
+
});
|
35
|
+
return `0x${Signature.fromHex(signature).toCompactHex()}${recId ? "1c" : "1b"}`;
|
36
|
+
}
|
37
|
+
|
38
|
+
// src/accounts/utils/signMessage.ts
|
39
|
+
async function signMessage({
|
40
|
+
message,
|
41
|
+
privateKey
|
42
|
+
}) {
|
43
|
+
return sign({ hash: hashMessage(message), privateKey });
|
44
|
+
}
|
45
|
+
|
46
|
+
// src/accounts/utils/signTypedData.ts
|
47
|
+
async function signTypedData({
|
48
|
+
privateKey,
|
49
|
+
...typedData
|
50
|
+
}) {
|
51
|
+
return sign({
|
52
|
+
hash: hashTypedData(typedData),
|
53
|
+
privateKey
|
54
|
+
});
|
55
|
+
}
|
56
|
+
|
57
|
+
// src/accounts/privateKeyToAccount.ts
|
58
|
+
function privateKeyToAccount(privateKey) {
|
59
|
+
const publicKey = toHex(getPublicKey(privateKey.slice(2)));
|
60
|
+
const address = publicKeyToAddress(publicKey);
|
61
|
+
const account = toAccount({
|
62
|
+
address,
|
63
|
+
async signMessage({ message }) {
|
64
|
+
return signMessage({ message, privateKey });
|
65
|
+
},
|
66
|
+
async signTransaction(_transaction) {
|
67
|
+
return "0x";
|
68
|
+
},
|
69
|
+
async signTypedData(typedData) {
|
70
|
+
return signTypedData({ ...typedData, privateKey });
|
71
|
+
}
|
72
|
+
});
|
73
|
+
return {
|
74
|
+
...account,
|
75
|
+
getPrivateKey: () => privateKey,
|
76
|
+
publicKey,
|
77
|
+
source: "privateKey"
|
78
|
+
};
|
79
|
+
}
|
80
|
+
export {
|
81
|
+
HDKey,
|
82
|
+
parseAccount,
|
83
|
+
privateKeyToAccount,
|
84
|
+
publicKeyToAddress,
|
85
|
+
signMessage,
|
86
|
+
signTypedData,
|
87
|
+
toAccount
|
88
|
+
};
|
89
|
+
//# sourceMappingURL=index.mjs.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../../src/accounts/index.ts","../../src/accounts/privateKeyToAccount.ts","../../src/accounts/utils/publicKeyToAddress.ts","../../src/accounts/utils/sign.ts","../../src/accounts/utils/signMessage.ts","../../src/accounts/utils/signTypedData.ts"],"sourcesContent":["import { HDKey } from '@scure/bip32'\n\nexport { HDKey }\n\nexport { privateKeyToAccount } from './privateKeyToAccount'\n\nexport { toAccount } from './toAccount'\n\nexport type {\n Account,\n AccountSource,\n CustomSource,\n HDOptions,\n JsonRpcAccount,\n LocalAccount,\n HDAccount,\n PrivateKeyAccount,\n} from './types'\n\nexport type {\n SignMessageParameters,\n SignMessageReturnType,\n SignTypedDataParameters,\n SignTypedDataReturnType,\n} from './utils'\nexport {\n parseAccount,\n publicKeyToAddress,\n signMessage,\n signTypedData,\n} from './utils'\n","import { getPublicKey } from '@noble/secp256k1'\n\nimport type { Hex } from '../types'\nimport { toHex } from '../utils'\nimport { publicKeyToAddress, signMessage, signTypedData } from './utils'\nimport { toAccount } from './toAccount'\nimport type { PrivateKeyAccount } from './types'\n\nexport function privateKeyToAccount(privateKey: Hex): PrivateKeyAccount {\n const publicKey = toHex(getPublicKey(privateKey.slice(2)))\n const address = publicKeyToAddress(publicKey)\n\n const account = toAccount({\n address,\n async signMessage({ message }) {\n return signMessage({ message, privateKey })\n },\n async signTransaction(_transaction) {\n // TODO\n return '0x'\n },\n async signTypedData(typedData) {\n return signTypedData({ ...typedData, privateKey })\n },\n })\n\n return {\n ...account,\n getPrivateKey: () => privateKey,\n publicKey,\n source: 'privateKey',\n }\n}\n","import type { Address, Hex } from '../../types'\nimport { keccak256 } from '../../utils'\nimport { checksumAddress } from '../../utils/address'\n\nexport function publicKeyToAddress(publicKey: Hex): Address {\n const address = keccak256(`0x${publicKey.substring(4)}`).substring(26)\n return checksumAddress(`0x${address}`) as Address\n}\n","import { sign as sign_, Signature } from '@noble/secp256k1'\n\nimport type { Hex } from '../../types'\n\nexport type SignParameters = {\n hash: Hex\n privateKey: Hex\n}\nexport type SignReturnType = Hex\n\nexport async function sign({\n hash,\n privateKey,\n}: SignParameters): Promise<SignReturnType> {\n const [signature, recId] = await sign_(hash.slice(2), privateKey.slice(2), {\n canonical: true,\n recovered: true,\n })\n return `0x${Signature.fromHex(signature).toCompactHex()}${\n recId ? '1c' : '1b'\n }`\n}\n","import type { Hex } from '../../types'\nimport { hashMessage } from '../../utils'\nimport { sign } from './sign'\n\nexport type SignMessageParameters = {\n message: string\n privateKey: Hex\n}\nexport type SignMessageReturnType = Hex\n\nexport async function signMessage({\n message,\n privateKey,\n}: SignMessageParameters): Promise<SignMessageReturnType> {\n return sign({ hash: hashMessage(message), privateKey })\n}\n","import type { TypedData } from 'abitype'\n\nimport type { Hex, TypedDataDefinition } from '../../types'\nimport { HashTypedDataParameters, hashTypedData } from '../../utils'\nimport { sign } from './sign'\n\nexport type SignTypedDataParameters<\n TTypedData extends TypedData | { [key: string]: unknown } = TypedData,\n TPrimaryType extends string = string,\n> = TypedDataDefinition<TTypedData, TPrimaryType> & {\n privateKey: Hex\n}\n\nexport type SignTypedDataReturnType = Hex\n\nexport async function signTypedData<\n TTypedData extends TypedData | { [key: string]: unknown },\n TPrimaryType extends string = string,\n>({\n privateKey,\n ...typedData\n}: SignTypedDataParameters<\n TTypedData,\n TPrimaryType\n>): Promise<SignTypedDataReturnType> {\n return sign({\n hash: hashTypedData(typedData as HashTypedDataParameters),\n privateKey,\n })\n}\n"],"mappings":";;;;;;;;;;;;;AAAA,SAAS,aAAa;;;ACAtB,SAAS,oBAAoB;;;ACItB,SAAS,mBAAmB,WAAyB;AAC1D,QAAM,UAAU,UAAU,KAAK,UAAU,UAAU,CAAC,GAAG,EAAE,UAAU,EAAE;AACrE,SAAO,gBAAgB,KAAK,SAAS;AACvC;;;ACPA,SAAS,QAAQ,OAAO,iBAAiB;AAUzC,eAAsB,KAAK;AAAA,EACzB;AAAA,EACA;AACF,GAA4C;AAC1C,QAAM,CAAC,WAAW,KAAK,IAAI,MAAM,MAAM,KAAK,MAAM,CAAC,GAAG,WAAW,MAAM,CAAC,GAAG;AAAA,IACzE,WAAW;AAAA,IACX,WAAW;AAAA,EACb,CAAC;AACD,SAAO,KAAK,UAAU,QAAQ,SAAS,EAAE,aAAa,IACpD,QAAQ,OAAO;AAEnB;;;ACXA,eAAsB,YAAY;AAAA,EAChC;AAAA,EACA;AACF,GAA0D;AACxD,SAAO,KAAK,EAAE,MAAM,YAAY,OAAO,GAAG,WAAW,CAAC;AACxD;;;ACAA,eAAsB,cAGpB;AAAA,EACA;AAAA,EACA,GAAG;AACL,GAGqC;AACnC,SAAO,KAAK;AAAA,IACV,MAAM,cAAc,SAAoC;AAAA,IACxD;AAAA,EACF,CAAC;AACH;;;AJrBO,SAAS,oBAAoB,YAAoC;AACtE,QAAM,YAAY,MAAM,aAAa,WAAW,MAAM,CAAC,CAAC,CAAC;AACzD,QAAM,UAAU,mBAAmB,SAAS;AAE5C,QAAM,UAAU,UAAU;AAAA,IACxB;AAAA,IACA,MAAM,YAAY,EAAE,QAAQ,GAAG;AAC7B,aAAO,YAAY,EAAE,SAAS,WAAW,CAAC;AAAA,IAC5C;AAAA,IACA,MAAM,gBAAgB,cAAc;AAElC,aAAO;AAAA,IACT;AAAA,IACA,MAAM,cAAc,WAAW;AAC7B,aAAO,cAAc,EAAE,GAAG,WAAW,WAAW,CAAC;AAAA,IACnD;AAAA,EACF,CAAC;AAED,SAAO;AAAA,IACL,GAAG;AAAA,IACH,eAAe,MAAM;AAAA,IACrB;AAAA,IACA,QAAQ;AAAA,EACV;AACF;","names":[]}
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { Chain as Chain$1 } from '@wagmi/chains';
|
2
|
-
import {
|
2
|
+
import { Abi, AbiFunction, ExtractAbiFunction, AbiParametersToPrimitiveTypes, AbiConstructor, AbiError, ExtractAbiError, AbiEvent, ExtractAbiEvent, ExtractAbiErrorNames, ExtractAbiEventNames, AbiStateMutability, ExtractAbiFunctionNames, Narrow, Address, AbiParameter, AbiParameterToPrimitiveType } from 'abitype';
|
3
3
|
|
4
4
|
type ByteArray = Uint8Array;
|
5
5
|
type Hex = `0x${string}`;
|
@@ -58,65 +58,6 @@ declare const defineTransaction: <TFormat extends Formatter<Partial<RpcTransacti
|
|
58
58
|
[key: string]: unknown;
|
59
59
|
}) => Transaction<bigint, number> & ReturnType<TFormat> & { [K in TExclude[number]]: never; };
|
60
60
|
|
61
|
-
type Block<TQuantity = bigint, TTransaction = Transaction> = {
|
62
|
-
/** Base fee per gas */
|
63
|
-
baseFeePerGas: TQuantity | null;
|
64
|
-
/** Difficulty for this block */
|
65
|
-
difficulty: TQuantity;
|
66
|
-
/** "Extra data" field of this block */
|
67
|
-
extraData: Hex;
|
68
|
-
/** Maximum gas allowed in this block */
|
69
|
-
gasLimit: TQuantity;
|
70
|
-
/** Total used gas by all transactions in this block */
|
71
|
-
gasUsed: TQuantity;
|
72
|
-
/** Block hash or `null` if pending */
|
73
|
-
hash: Hash | null;
|
74
|
-
/** Logs bloom filter or `null` if pending */
|
75
|
-
logsBloom: Hex | null;
|
76
|
-
/** Address that received this block’s mining rewards */
|
77
|
-
miner: Address;
|
78
|
-
/** Unique identifier for the block. */
|
79
|
-
mixHash: Hash;
|
80
|
-
/** Proof-of-work hash or `null` if pending */
|
81
|
-
nonce: Hex | null;
|
82
|
-
/** Block number or `null` if pending */
|
83
|
-
number: TQuantity | null;
|
84
|
-
/** Parent block hash */
|
85
|
-
parentHash: Hash;
|
86
|
-
/** Root of the this block’s receipts trie */
|
87
|
-
receiptsRoot: Hex;
|
88
|
-
sealFields: Hex[];
|
89
|
-
/** SHA3 of the uncles data in this block */
|
90
|
-
sha3Uncles: Hash;
|
91
|
-
/** Size of this block in bytes */
|
92
|
-
size: TQuantity;
|
93
|
-
/** Root of this block’s final state trie */
|
94
|
-
stateRoot: Hash;
|
95
|
-
/** Unix timestamp of when this block was collated */
|
96
|
-
timestamp: TQuantity;
|
97
|
-
/** Total difficulty of the chain until this block */
|
98
|
-
totalDifficulty: TQuantity | null;
|
99
|
-
/** List of transaction objects or hashes */
|
100
|
-
transactions: Hash[] | TTransaction[];
|
101
|
-
/** Root of this block’s transaction trie */
|
102
|
-
transactionsRoot: Hash;
|
103
|
-
/** List of uncle hashes */
|
104
|
-
uncles: Hash[];
|
105
|
-
};
|
106
|
-
type BlockIdentifier<TQuantity = bigint> = {
|
107
|
-
/** Whether or not to throw an error if the block is not in the canonical chain as described below. Only allowed in conjunction with the blockHash tag. Defaults to false. */
|
108
|
-
requireCanonical?: boolean;
|
109
|
-
} & ({
|
110
|
-
/** The block in the canonical chain with this number */
|
111
|
-
blockNumber: BlockNumber<TQuantity>;
|
112
|
-
} | {
|
113
|
-
/** The block uniquely identified by this hash. The `blockNumber` and `blockHash` properties are mutually exclusive; exactly one of them must be set. */
|
114
|
-
blockHash: Hash;
|
115
|
-
});
|
116
|
-
type BlockNumber<TQuantity = bigint> = TQuantity;
|
117
|
-
type BlockTag = 'latest' | 'earliest' | 'pending' | 'safe' | 'finalized';
|
118
|
-
type Uncle<TQuantity = bigint, TTransaction = Transaction> = Block<TQuantity, TTransaction>;
|
119
|
-
|
120
61
|
type FeeHistory<TQuantity = bigint> = {
|
121
62
|
/**
|
122
63
|
* An array of block base fees per gas (in wei). This includes the next block after
|
@@ -512,6 +453,65 @@ type TransactionRequestEIP1559<TQuantity = bigint, TIndex = number> = Transactio
|
|
512
453
|
};
|
513
454
|
type TransactionRequest<TQuantity = bigint, TIndex = number> = TransactionRequestLegacy<TQuantity, TIndex> | TransactionRequestEIP2930<TQuantity, TIndex> | TransactionRequestEIP1559<TQuantity, TIndex>;
|
514
455
|
|
456
|
+
type Block<TQuantity = bigint, TTransaction = Transaction> = {
|
457
|
+
/** Base fee per gas */
|
458
|
+
baseFeePerGas: TQuantity | null;
|
459
|
+
/** Difficulty for this block */
|
460
|
+
difficulty: TQuantity;
|
461
|
+
/** "Extra data" field of this block */
|
462
|
+
extraData: Hex;
|
463
|
+
/** Maximum gas allowed in this block */
|
464
|
+
gasLimit: TQuantity;
|
465
|
+
/** Total used gas by all transactions in this block */
|
466
|
+
gasUsed: TQuantity;
|
467
|
+
/** Block hash or `null` if pending */
|
468
|
+
hash: Hash | null;
|
469
|
+
/** Logs bloom filter or `null` if pending */
|
470
|
+
logsBloom: Hex | null;
|
471
|
+
/** Address that received this block’s mining rewards */
|
472
|
+
miner: Address;
|
473
|
+
/** Unique identifier for the block. */
|
474
|
+
mixHash: Hash;
|
475
|
+
/** Proof-of-work hash or `null` if pending */
|
476
|
+
nonce: Hex | null;
|
477
|
+
/** Block number or `null` if pending */
|
478
|
+
number: TQuantity | null;
|
479
|
+
/** Parent block hash */
|
480
|
+
parentHash: Hash;
|
481
|
+
/** Root of the this block’s receipts trie */
|
482
|
+
receiptsRoot: Hex;
|
483
|
+
sealFields: Hex[];
|
484
|
+
/** SHA3 of the uncles data in this block */
|
485
|
+
sha3Uncles: Hash;
|
486
|
+
/** Size of this block in bytes */
|
487
|
+
size: TQuantity;
|
488
|
+
/** Root of this block’s final state trie */
|
489
|
+
stateRoot: Hash;
|
490
|
+
/** Unix timestamp of when this block was collated */
|
491
|
+
timestamp: TQuantity;
|
492
|
+
/** Total difficulty of the chain until this block */
|
493
|
+
totalDifficulty: TQuantity | null;
|
494
|
+
/** List of transaction objects or hashes */
|
495
|
+
transactions: Hash[] | TTransaction[];
|
496
|
+
/** Root of this block’s transaction trie */
|
497
|
+
transactionsRoot: Hash;
|
498
|
+
/** List of uncle hashes */
|
499
|
+
uncles: Hash[];
|
500
|
+
};
|
501
|
+
type BlockIdentifier<TQuantity = bigint> = {
|
502
|
+
/** Whether or not to throw an error if the block is not in the canonical chain as described below. Only allowed in conjunction with the blockHash tag. Defaults to false. */
|
503
|
+
requireCanonical?: boolean;
|
504
|
+
} & ({
|
505
|
+
/** The block in the canonical chain with this number */
|
506
|
+
blockNumber: BlockNumber<TQuantity>;
|
507
|
+
} | {
|
508
|
+
/** The block uniquely identified by this hash. The `blockNumber` and `blockHash` properties are mutually exclusive; exactly one of them must be set. */
|
509
|
+
blockHash: Hash;
|
510
|
+
});
|
511
|
+
type BlockNumber<TQuantity = bigint> = TQuantity;
|
512
|
+
type BlockTag = 'latest' | 'earliest' | 'pending' | 'safe' | 'finalized';
|
513
|
+
type Uncle<TQuantity = bigint, TTransaction = Transaction> = Block<TQuantity, TTransaction>;
|
514
|
+
|
515
515
|
type Formatter<TSource = any, TTarget = any> = (value: TSource & {
|
516
516
|
[key: string]: unknown;
|
517
517
|
}) => TTarget;
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import { a1 as Formatters, C as Chain } from './chain-
|
1
|
+
import { a1 as Formatters, C as Chain } from './chain-75b0942e.js';
|
2
2
|
|
3
3
|
declare function defineChain<TFormatters extends Formatters = Formatters, TChain extends Chain<TFormatters> = Chain<TFormatters>>(chain: TChain): TChain;
|
4
4
|
declare function getChainContractAddress({ blockNumber, chain, contract: name, }: {
|
package/dist/chains.d.ts
CHANGED
@@ -1,7 +1,7 @@
|
|
1
|
-
import { R as RpcBlock, c as Block, O as Transaction, H as Hex, y as RpcTransaction, z as RpcTransactionReceipt, T as TransactionReceipt, a3 as TransactionType, I as TransactionRequest, D as RpcTransactionRequest } from './chain-
|
2
|
-
export { C as Chain } from './chain-
|
1
|
+
import { R as RpcBlock, c as Block, O as Transaction, H as Hex, y as RpcTransaction, z as RpcTransactionReceipt, T as TransactionReceipt, a3 as TransactionType, I as TransactionRequest, D as RpcTransactionRequest } from './chain-75b0942e.js';
|
2
|
+
export { C as Chain } from './chain-75b0942e.js';
|
3
3
|
import * as chains from '@wagmi/chains';
|
4
|
-
export { d as defineChain } from './chain-
|
4
|
+
export { d as defineChain } from './chain-f8db473f.js';
|
5
5
|
import 'abitype';
|
6
6
|
|
7
7
|
declare const arbitrum: {
|
package/dist/chains.js
CHANGED
@@ -4,32 +4,32 @@
|
|
4
4
|
|
5
5
|
|
6
6
|
|
7
|
-
var
|
7
|
+
var _chunkNJSAEA2Hjs = require('./chunk-NJSAEA2H.js');
|
8
8
|
|
9
9
|
// src/chains.ts
|
10
10
|
var _chains = require('@wagmi/chains'); var chains = _interopRequireWildcard(_chains);
|
11
11
|
var celoFormatters = {
|
12
|
-
block:
|
12
|
+
block: _chunkNJSAEA2Hjs.defineBlock.call(void 0, {
|
13
13
|
exclude: ["difficulty", "gasLimit", "mixHash", "nonce", "uncles"],
|
14
14
|
format: (block) => ({
|
15
15
|
randomness: block.randomness
|
16
16
|
})
|
17
17
|
}),
|
18
|
-
transaction:
|
18
|
+
transaction: _chunkNJSAEA2Hjs.defineTransaction.call(void 0, {
|
19
19
|
format: (transaction) => ({
|
20
20
|
feeCurrency: transaction.feeCurrency,
|
21
21
|
gatewayFee: transaction.gatewayFee ? BigInt(transaction.gatewayFee) : null,
|
22
22
|
gatewayFeeRecipient: transaction.gatewayFeeRecipient
|
23
23
|
})
|
24
24
|
}),
|
25
|
-
transactionReceipt:
|
25
|
+
transactionReceipt: _chunkNJSAEA2Hjs.defineTransactionReceipt.call(void 0, {
|
26
26
|
format: (transaction) => ({
|
27
27
|
feeCurrency: transaction.feeCurrency,
|
28
28
|
gatewayFee: transaction.gatewayFee ? BigInt(transaction.gatewayFee) : null,
|
29
29
|
gatewayFeeRecipient: transaction.gatewayFeeRecipient
|
30
30
|
})
|
31
31
|
}),
|
32
|
-
transactionRequest:
|
32
|
+
transactionRequest: _chunkNJSAEA2Hjs.defineTransactionRequest.call(void 0, {
|
33
33
|
format: (transactionRequest) => ({
|
34
34
|
feeCurrency: transactionRequest.feeCurrency,
|
35
35
|
gatewayFee: transactionRequest.gatewayFee,
|
@@ -37,69 +37,69 @@ var celoFormatters = {
|
|
37
37
|
})
|
38
38
|
})
|
39
39
|
};
|
40
|
-
var arbitrum2 =
|
41
|
-
var arbitrumGoerli2 =
|
42
|
-
var aurora2 =
|
43
|
-
var auroraGoerli =
|
44
|
-
var avalanche2 =
|
45
|
-
var avalancheFuji2 =
|
46
|
-
var baseGoerli2 =
|
47
|
-
var boba2 =
|
48
|
-
var bronos2 =
|
49
|
-
var bronosTestnet2 =
|
50
|
-
var bsc2 =
|
51
|
-
var bscTestnet2 =
|
52
|
-
var canto2 =
|
53
|
-
var celo2 =
|
40
|
+
var arbitrum2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.arbitrum);
|
41
|
+
var arbitrumGoerli2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.arbitrumGoerli);
|
42
|
+
var aurora2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.aurora);
|
43
|
+
var auroraGoerli = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.auroraTestnet);
|
44
|
+
var avalanche2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.avalanche);
|
45
|
+
var avalancheFuji2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.avalancheFuji);
|
46
|
+
var baseGoerli2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.baseGoerli);
|
47
|
+
var boba2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.boba);
|
48
|
+
var bronos2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.bronos);
|
49
|
+
var bronosTestnet2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.bronosTestnet);
|
50
|
+
var bsc2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.bsc);
|
51
|
+
var bscTestnet2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.bscTestnet);
|
52
|
+
var canto2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.canto);
|
53
|
+
var celo2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, {
|
54
54
|
...chains.celo,
|
55
55
|
formatters: celoFormatters
|
56
56
|
});
|
57
|
-
var celoAlfajores2 =
|
57
|
+
var celoAlfajores2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, {
|
58
58
|
...chains.celoAlfajores,
|
59
59
|
formatters: celoFormatters
|
60
60
|
});
|
61
|
-
var crossbell2 =
|
62
|
-
var evmos2 =
|
63
|
-
var evmosTestnet2 =
|
64
|
-
var fantom2 =
|
65
|
-
var fantomTestnet2 =
|
66
|
-
var filecoin2 =
|
67
|
-
var filecoinCalibration2 =
|
68
|
-
var filecoinHyperspace2 =
|
69
|
-
var flare2 =
|
70
|
-
var flareTestnet2 =
|
71
|
-
var foundry2 =
|
72
|
-
var goerli2 =
|
73
|
-
var gnosis2 =
|
74
|
-
var gnosisChiado2 =
|
75
|
-
var hardhat2 =
|
76
|
-
var harmonyOne2 =
|
77
|
-
var iotex2 =
|
78
|
-
var iotexTestnet2 =
|
79
|
-
var localhost2 =
|
80
|
-
var mainnet2 =
|
81
|
-
var metis2 =
|
82
|
-
var metisGoerli2 =
|
83
|
-
var moonbaseAlpha2 =
|
84
|
-
var moonbeam2 =
|
85
|
-
var moonriver2 =
|
86
|
-
var okc2 =
|
87
|
-
var optimism2 =
|
88
|
-
var optimismGoerli2 =
|
89
|
-
var polygon2 =
|
90
|
-
var polygonMumbai2 =
|
91
|
-
var polygonZkEvmTestnet2 =
|
92
|
-
var sepolia2 =
|
93
|
-
var shardeumSphinx2 =
|
94
|
-
var songbird2 =
|
95
|
-
var songbirdTestnet2 =
|
96
|
-
var taraxa2 =
|
97
|
-
var taraxaTestnet2 =
|
98
|
-
var telos2 =
|
99
|
-
var telosTestnet2 =
|
100
|
-
var zhejiang2 =
|
101
|
-
var zkSync2 =
|
102
|
-
var zkSyncTestnet2 =
|
61
|
+
var crossbell2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.crossbell);
|
62
|
+
var evmos2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.evmos);
|
63
|
+
var evmosTestnet2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.evmosTestnet);
|
64
|
+
var fantom2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.fantom);
|
65
|
+
var fantomTestnet2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.fantomTestnet);
|
66
|
+
var filecoin2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.filecoin);
|
67
|
+
var filecoinCalibration2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.filecoinCalibration);
|
68
|
+
var filecoinHyperspace2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.filecoinHyperspace);
|
69
|
+
var flare2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.flare);
|
70
|
+
var flareTestnet2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.flareTestnet);
|
71
|
+
var foundry2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.foundry);
|
72
|
+
var goerli2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.goerli);
|
73
|
+
var gnosis2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.gnosis);
|
74
|
+
var gnosisChiado2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.gnosisChiado);
|
75
|
+
var hardhat2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.hardhat);
|
76
|
+
var harmonyOne2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.harmonyOne);
|
77
|
+
var iotex2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.iotex);
|
78
|
+
var iotexTestnet2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.iotexTestnet);
|
79
|
+
var localhost2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.localhost);
|
80
|
+
var mainnet2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.mainnet);
|
81
|
+
var metis2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.metis);
|
82
|
+
var metisGoerli2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.metisGoerli);
|
83
|
+
var moonbaseAlpha2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.moonbaseAlpha);
|
84
|
+
var moonbeam2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.moonbeam);
|
85
|
+
var moonriver2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.moonriver);
|
86
|
+
var okc2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.okc);
|
87
|
+
var optimism2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.optimism);
|
88
|
+
var optimismGoerli2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.optimismGoerli);
|
89
|
+
var polygon2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.polygon);
|
90
|
+
var polygonMumbai2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.polygonMumbai);
|
91
|
+
var polygonZkEvmTestnet2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.polygonZkEvmTestnet);
|
92
|
+
var sepolia2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.sepolia);
|
93
|
+
var shardeumSphinx2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.shardeumSphinx);
|
94
|
+
var songbird2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.songbird);
|
95
|
+
var songbirdTestnet2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.songbirdTestnet);
|
96
|
+
var taraxa2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.taraxa);
|
97
|
+
var taraxaTestnet2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.taraxaTestnet);
|
98
|
+
var telos2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.telos);
|
99
|
+
var telosTestnet2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.telosTestnet);
|
100
|
+
var zhejiang2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.zhejiang);
|
101
|
+
var zkSync2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.zkSync);
|
102
|
+
var zkSyncTestnet2 = _chunkNJSAEA2Hjs.defineChain.call(void 0, chains.zkSyncTestnet);
|
103
103
|
|
104
104
|
|
105
105
|
|
@@ -159,5 +159,5 @@ var zkSyncTestnet2 = _chunk22BDIC7Jjs.defineChain.call(void 0, chains.zkSyncTest
|
|
159
159
|
|
160
160
|
|
161
161
|
|
162
|
-
exports.arbitrum = arbitrum2; exports.arbitrumGoerli = arbitrumGoerli2; exports.aurora = aurora2; exports.auroraGoerli = auroraGoerli; exports.avalanche = avalanche2; exports.avalancheFuji = avalancheFuji2; exports.baseGoerli = baseGoerli2; exports.boba = boba2; exports.bronos = bronos2; exports.bronosTestnet = bronosTestnet2; exports.bsc = bsc2; exports.bscTestnet = bscTestnet2; exports.canto = canto2; exports.celo = celo2; exports.celoAlfajores = celoAlfajores2; exports.crossbell = crossbell2; exports.defineChain =
|
162
|
+
exports.arbitrum = arbitrum2; exports.arbitrumGoerli = arbitrumGoerli2; exports.aurora = aurora2; exports.auroraGoerli = auroraGoerli; exports.avalanche = avalanche2; exports.avalancheFuji = avalancheFuji2; exports.baseGoerli = baseGoerli2; exports.boba = boba2; exports.bronos = bronos2; exports.bronosTestnet = bronosTestnet2; exports.bsc = bsc2; exports.bscTestnet = bscTestnet2; exports.canto = canto2; exports.celo = celo2; exports.celoAlfajores = celoAlfajores2; exports.crossbell = crossbell2; exports.defineChain = _chunkNJSAEA2Hjs.defineChain; exports.evmos = evmos2; exports.evmosTestnet = evmosTestnet2; exports.fantom = fantom2; exports.fantomTestnet = fantomTestnet2; exports.filecoin = filecoin2; exports.filecoinCalibration = filecoinCalibration2; exports.filecoinHyperspace = filecoinHyperspace2; exports.flare = flare2; exports.flareTestnet = flareTestnet2; exports.foundry = foundry2; exports.gnosis = gnosis2; exports.gnosisChiado = gnosisChiado2; exports.goerli = goerli2; exports.hardhat = hardhat2; exports.harmonyOne = harmonyOne2; exports.iotex = iotex2; exports.iotexTestnet = iotexTestnet2; exports.localhost = localhost2; exports.mainnet = mainnet2; exports.metis = metis2; exports.metisGoerli = metisGoerli2; exports.moonbaseAlpha = moonbaseAlpha2; exports.moonbeam = moonbeam2; exports.moonriver = moonriver2; exports.okc = okc2; exports.optimism = optimism2; exports.optimismGoerli = optimismGoerli2; exports.polygon = polygon2; exports.polygonMumbai = polygonMumbai2; exports.polygonZkEvmTestnet = polygonZkEvmTestnet2; exports.sepolia = sepolia2; exports.shardeumSphinx = shardeumSphinx2; exports.songbird = songbird2; exports.songbirdTestnet = songbirdTestnet2; exports.taraxa = taraxa2; exports.taraxaTestnet = taraxaTestnet2; exports.telos = telos2; exports.telosTestnet = telosTestnet2; exports.zhejiang = zhejiang2; exports.zkSync = zkSync2; exports.zkSyncTestnet = zkSyncTestnet2;
|
163
163
|
//# sourceMappingURL=chains.js.map
|
package/dist/chains.mjs
CHANGED
@@ -11,7 +11,7 @@ import {
|
|
11
11
|
stringToBytes,
|
12
12
|
toBytes,
|
13
13
|
toHex
|
14
|
-
} from "./chunk-
|
14
|
+
} from "./chunk-IVRML3IK.mjs";
|
15
15
|
|
16
16
|
// src/utils/ens/labelhash.ts
|
17
17
|
function labelhash(label) {
|
@@ -183,4 +183,4 @@ export {
|
|
183
183
|
getEnsAddress,
|
184
184
|
getEnsName
|
185
185
|
};
|
186
|
-
//# sourceMappingURL=chunk-
|
186
|
+
//# sourceMappingURL=chunk-6UKHPIXX.mjs.map
|