ox 1.0.0-beta.7 → 1.0.0-beta.8
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/core/Log.d.ts +1 -1
- package/dist/core/Log.d.ts.map +1 -1
- package/dist/zod/Log.d.ts +3 -3
- package/dist/zod/Log.js +1 -1
- package/dist/zod/Log.js.map +1 -1
- package/dist/zod/RpcSchema.d.ts +6 -6
- package/dist/zod/TransactionReceipt.d.ts +2 -2
- package/dist/zod/internal/rpcSchemas/Eth.d.ts +6 -6
- package/dist/zod/internal/rpcSchemas/Wallet.d.ts +1 -1
- package/dist/zod/tempo/RpcSchemaTempo.d.ts +2 -2
- package/dist/zod/tempo/TransactionReceipt.d.ts +2 -2
- package/package.json +1 -1
- package/src/core/Log.ts +1 -1
- package/src/version.ts +1 -1
- package/src/zod/Log.ts +1 -1
- package/src/zod/_test/Log.test.ts +16 -0
- package/src/zod/_test/TransactionReceipt.test.ts +1 -1
package/dist/core/Log.d.ts
CHANGED
|
@@ -17,7 +17,7 @@ export type Log<pending extends boolean = false, bigintType = bigint, numberType
|
|
|
17
17
|
/** Index of this log within its block or `null` if pending */
|
|
18
18
|
logIndex: pending extends true ? null : numberType;
|
|
19
19
|
/** List of topics associated with this log */
|
|
20
|
-
topics:
|
|
20
|
+
topics: Hex.Hex[];
|
|
21
21
|
/** Hash of the transaction that created this log or `null` if pending */
|
|
22
22
|
transactionHash: pending extends true ? null : Hex.Hex;
|
|
23
23
|
/** Index of the transaction that created this log or `null` if pending */
|
package/dist/core/Log.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Log.d.ts","sourceRoot":"","sources":["../../src/core/Log.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,OAAO,MAAM,cAAc,CAAA;AAC5C,OAAO,KAAK,KAAK,MAAM,MAAM,aAAa,CAAA;AAC1C,OAAO,KAAK,KAAK,GAAG,MAAM,UAAU,CAAA;A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ed;AAED,MAAM,CAAC,OAAO,WAAW,OAAO,CAAC;IAC/B,KAAK,OAAO,CAAC,OAAO,SAAS,OAAO,GAAG,KAAK,IAAI;QAC9C,OAAO,CAAC,EAAE,OAAO,GAAG,OAAO,GAAG,SAAS,CAAA;KACxC,CAAA;IAED,KAAK,SAAS,GAAG,MAAM,CAAC,eAAe,CAAA;CACxC;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8CG;AACH,wBAAgB,KAAK,CACnB,KAAK,CAAC,GAAG,SAAS,KAAK,CAAC,KAAK,EAC7B,OAAO,SAAS,OAAO,GAAG,KAAK,EAC/B,GAAG,EAAE,GAAG,EAAE,QAAQ,GAAE,KAAK,CAAC,OAAO,CAAC,OAAO,CAAM,GAAG,GAAG,CAAC,OAAO,CAAC,CAqB/D;AAED,MAAM,CAAC,OAAO,WAAW,KAAK,CAAC;IAC7B,mEAAmE;IACnE,KAAK,KAAK,GAAG,GAAG,CAAC,OAAO,EAAE,GAAG,CAAC,GAAG,GAAG,MAAM,GAAG,MAAM,EAAE,GAAG,CAAC,GAAG,GAAG,MAAM,CAAC,CAAA;IAEtE,KAAK,OAAO,CAAC,OAAO,SAAS,OAAO,GAAG,KAAK,IAAI;QAC9C,OAAO,CAAC,EAAE,OAAO,GAAG,OAAO,GAAG,SAAS,CAAA;KACxC,CAAA;IAED,KAAK,SAAS,GAAG,MAAM,CAAC,eAAe,CAAA;CACxC"}
|
package/dist/zod/Log.d.ts
CHANGED
|
@@ -7,7 +7,7 @@ export declare const Log: z.ZodMiniObject<{
|
|
|
7
7
|
blockTimestamp: z.ZodMiniOptional<z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniBigInt<bigint>>>;
|
|
8
8
|
data: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
9
9
|
logIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
10
|
-
topics: z.
|
|
10
|
+
topics: z.ZodMiniArray<z.ZodMiniTemplateLiteral<`0x${string}`>>;
|
|
11
11
|
transactionHash: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
12
12
|
transactionIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
13
13
|
removed: z.ZodMiniBoolean<boolean>;
|
|
@@ -20,7 +20,7 @@ export declare const LogToRpc: z.ZodMiniObject<{
|
|
|
20
20
|
blockTimestamp: z.ZodMiniOptional<z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniUnion<readonly [z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniBigInt<bigint>, z.ZodMiniNumberFormat]>>>;
|
|
21
21
|
data: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
22
22
|
logIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniUnion<readonly [z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat]>>;
|
|
23
|
-
topics: z.
|
|
23
|
+
topics: z.ZodMiniArray<z.ZodMiniTemplateLiteral<`0x${string}`>>;
|
|
24
24
|
transactionHash: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
25
25
|
transactionIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniUnion<readonly [z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat]>>;
|
|
26
26
|
removed: z.ZodMiniBoolean<boolean>;
|
|
@@ -33,7 +33,7 @@ export declare const Pending: z.ZodMiniObject<{
|
|
|
33
33
|
blockTimestamp: z.ZodMiniOptional<z.ZodMiniNull>;
|
|
34
34
|
data: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
35
35
|
logIndex: z.ZodMiniNull;
|
|
36
|
-
topics: z.
|
|
36
|
+
topics: z.ZodMiniArray<z.ZodMiniTemplateLiteral<`0x${string}`>>;
|
|
37
37
|
transactionHash: z.ZodMiniNull;
|
|
38
38
|
transactionIndex: z.ZodMiniNull;
|
|
39
39
|
removed: z.ZodMiniBoolean<boolean>;
|
package/dist/zod/Log.js
CHANGED
|
@@ -4,7 +4,7 @@ import * as z_Hex from './Hex.js';
|
|
|
4
4
|
import * as z_Number from './Number.js';
|
|
5
5
|
import * as z_Uint from './Uint.js';
|
|
6
6
|
import * as z from 'zod/mini';
|
|
7
|
-
const topics = z.
|
|
7
|
+
const topics = z.array(z_Hex.Hex);
|
|
8
8
|
/** Log schema. */
|
|
9
9
|
export const Log = z.object(fields(z_Uint.Uint, z_Number.Number));
|
|
10
10
|
/** Encode-only log schema accepting numberish `toRpc` inputs. */
|
package/dist/zod/Log.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Log.js","sourceRoot":"","sources":["../../src/zod/Log.ts"],"names":[],"mappings":"AAAA,mGAAmG;AACnG,OAAO,KAAK,SAAS,MAAM,cAAc,CAAA;AACzC,OAAO,KAAK,KAAK,MAAM,UAAU,CAAA;AACjC,OAAO,KAAK,QAAQ,MAAM,aAAa,CAAA;AACvC,OAAO,KAAK,MAAM,MAAM,WAAW,CAAA;AACnC,OAAO,KAAK,CAAC,MAAM,UAAU,CAAA;AAE7B,MAAM,MAAM,GAAG,CAAC,CAAC,KAAK,CAAC,
|
|
1
|
+
{"version":3,"file":"Log.js","sourceRoot":"","sources":["../../src/zod/Log.ts"],"names":[],"mappings":"AAAA,mGAAmG;AACnG,OAAO,KAAK,SAAS,MAAM,cAAc,CAAA;AACzC,OAAO,KAAK,KAAK,MAAM,UAAU,CAAA;AACjC,OAAO,KAAK,QAAQ,MAAM,aAAa,CAAA;AACvC,OAAO,KAAK,MAAM,MAAM,WAAW,CAAA;AACnC,OAAO,KAAK,CAAC,MAAM,UAAU,CAAA;AAE7B,MAAM,MAAM,GAAG,CAAC,CAAC,KAAK,CAAC,KAAK,CAAC,GAAG,CAAC,CAAA;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ema.d.ts
CHANGED
|
@@ -96,7 +96,7 @@ export declare const Default: {
|
|
|
96
96
|
blockTimestamp: z.ZodMiniOptional<z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniBigInt<bigint>>>;
|
|
97
97
|
data: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
98
98
|
logIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
99
|
-
topics: z.
|
|
99
|
+
topics: z.ZodMiniArray<z.ZodMiniTemplateLiteral<`0x${string}`>>;
|
|
100
100
|
transactionHash: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
101
101
|
transactionIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
102
102
|
removed: z.ZodMiniBoolean<boolean>;
|
|
@@ -1590,7 +1590,7 @@ export declare const Default: {
|
|
|
1590
1590
|
blockTimestamp: z.ZodMiniOptional<z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniBigInt<bigint>>>;
|
|
1591
1591
|
data: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
1592
1592
|
logIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
1593
|
-
topics: z.
|
|
1593
|
+
topics: z.ZodMiniArray<z.ZodMiniTemplateLiteral<`0x${string}`>>;
|
|
1594
1594
|
transactionHash: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
1595
1595
|
transactionIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
1596
1596
|
removed: z.ZodMiniBoolean<boolean>;
|
|
@@ -1602,7 +1602,7 @@ export declare const Default: {
|
|
|
1602
1602
|
blockTimestamp: z.ZodMiniOptional<z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniBigInt<bigint>>>;
|
|
1603
1603
|
data: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
1604
1604
|
logIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
1605
|
-
topics: z.
|
|
1605
|
+
topics: z.ZodMiniArray<z.ZodMiniTemplateLiteral<`0x${string}`>>;
|
|
1606
1606
|
transactionHash: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
1607
1607
|
transactionIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
1608
1608
|
removed: z.ZodMiniBoolean<boolean>;
|
|
@@ -1626,7 +1626,7 @@ export declare const Default: {
|
|
|
1626
1626
|
blockTimestamp: z.ZodMiniOptional<z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniBigInt<bigint>>>;
|
|
1627
1627
|
data: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
1628
1628
|
logIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
1629
|
-
topics: z.
|
|
1629
|
+
topics: z.ZodMiniArray<z.ZodMiniTemplateLiteral<`0x${string}`>>;
|
|
1630
1630
|
transactionHash: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
1631
1631
|
transactionIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
1632
1632
|
removed: z.ZodMiniBoolean<boolean>;
|
|
@@ -2584,7 +2584,7 @@ export declare const Default: {
|
|
|
2584
2584
|
blockTimestamp: z.ZodMiniOptional<z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniBigInt<bigint>>>;
|
|
2585
2585
|
data: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
2586
2586
|
logIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
2587
|
-
topics: z.
|
|
2587
|
+
topics: z.ZodMiniArray<z.ZodMiniTemplateLiteral<`0x${string}`>>;
|
|
2588
2588
|
transactionHash: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
2589
2589
|
transactionIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
2590
2590
|
removed: z.ZodMiniBoolean<boolean>;
|
|
@@ -3137,7 +3137,7 @@ export declare const Default: {
|
|
|
3137
3137
|
blockTimestamp: z.ZodMiniOptional<z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniBigInt<bigint>>>;
|
|
3138
3138
|
data: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
3139
3139
|
logIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
3140
|
-
topics: z.
|
|
3140
|
+
topics: z.ZodMiniArray<z.ZodMiniTemplateLiteral<`0x${string}`>>;
|
|
3141
3141
|
transactionHash: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
3142
3142
|
transactionIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
3143
3143
|
removed: z.ZodMiniBoolean<boolean>;
|
|
@@ -21,7 +21,7 @@ export declare const TransactionReceipt: z.ZodMiniObject<{
|
|
|
21
21
|
blockTimestamp: z.ZodMiniOptional<z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniBigInt<bigint>>>;
|
|
22
22
|
data: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
23
23
|
logIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
24
|
-
topics: z.
|
|
24
|
+
topics: z.ZodMiniArray<z.ZodMiniTemplateLiteral<`0x${string}`>>;
|
|
25
25
|
transactionHash: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
26
26
|
transactionIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
27
27
|
removed: z.ZodMiniBoolean<boolean>;
|
|
@@ -52,7 +52,7 @@ export declare const TransactionReceiptToRpc: z.ZodMiniObject<{
|
|
|
52
52
|
blockTimestamp: z.ZodMiniOptional<z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniUnion<readonly [z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniBigInt<bigint>, z.ZodMiniNumberFormat]>>>;
|
|
53
53
|
data: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
54
54
|
logIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniUnion<readonly [z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat]>>;
|
|
55
|
-
topics: z.
|
|
55
|
+
topics: z.ZodMiniArray<z.ZodMiniTemplateLiteral<`0x${string}`>>;
|
|
56
56
|
transactionHash: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
57
57
|
transactionIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniUnion<readonly [z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat]>>;
|
|
58
58
|
removed: z.ZodMiniBoolean<boolean>;
|
|
@@ -1290,7 +1290,7 @@ export declare const eth_getFilterChanges: import("./from.js").Item<"eth_getFilt
|
|
|
1290
1290
|
blockTimestamp: z.ZodMiniOptional<z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniBigInt<bigint>>>;
|
|
1291
1291
|
data: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
1292
1292
|
logIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
1293
|
-
topics: z.
|
|
1293
|
+
topics: z.ZodMiniArray<z.ZodMiniTemplateLiteral<`0x${string}`>>;
|
|
1294
1294
|
transactionHash: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
1295
1295
|
transactionIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
1296
1296
|
removed: z.ZodMiniBoolean<boolean>;
|
|
@@ -1302,7 +1302,7 @@ export declare const eth_getFilterLogs: import("./from.js").Item<"eth_getFilterL
|
|
|
1302
1302
|
blockTimestamp: z.ZodMiniOptional<z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniBigInt<bigint>>>;
|
|
1303
1303
|
data: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
1304
1304
|
logIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
1305
|
-
topics: z.
|
|
1305
|
+
topics: z.ZodMiniArray<z.ZodMiniTemplateLiteral<`0x${string}`>>;
|
|
1306
1306
|
transactionHash: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
1307
1307
|
transactionIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
1308
1308
|
removed: z.ZodMiniBoolean<boolean>;
|
|
@@ -1326,7 +1326,7 @@ export declare const eth_getLogs: import("./from.js").Item<"eth_getLogs", z.ZodM
|
|
|
1326
1326
|
blockTimestamp: z.ZodMiniOptional<z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniBigInt<bigint>>>;
|
|
1327
1327
|
data: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
1328
1328
|
logIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
1329
|
-
topics: z.
|
|
1329
|
+
topics: z.ZodMiniArray<z.ZodMiniTemplateLiteral<`0x${string}`>>;
|
|
1330
1330
|
transactionHash: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
1331
1331
|
transactionIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
1332
1332
|
removed: z.ZodMiniBoolean<boolean>;
|
|
@@ -2284,7 +2284,7 @@ export declare const eth_getTransactionReceipt: import("./from.js").Item<"eth_ge
|
|
|
2284
2284
|
blockTimestamp: z.ZodMiniOptional<z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniBigInt<bigint>>>;
|
|
2285
2285
|
data: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
2286
2286
|
logIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
2287
|
-
topics: z.
|
|
2287
|
+
topics: z.ZodMiniArray<z.ZodMiniTemplateLiteral<`0x${string}`>>;
|
|
2288
2288
|
transactionHash: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
2289
2289
|
transactionIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
2290
2290
|
removed: z.ZodMiniBoolean<boolean>;
|
|
@@ -2335,7 +2335,7 @@ export declare const eth_sendRawTransactionSync: import("./from.js").Item<"eth_s
|
|
|
2335
2335
|
blockTimestamp: z.ZodMiniOptional<z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniBigInt<bigint>>>;
|
|
2336
2336
|
data: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
2337
2337
|
logIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
2338
|
-
topics: z.
|
|
2338
|
+
topics: z.ZodMiniArray<z.ZodMiniTemplateLiteral<`0x${string}`>>;
|
|
2339
2339
|
transactionHash: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
2340
2340
|
transactionIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
2341
2341
|
removed: z.ZodMiniBoolean<boolean>;
|
|
@@ -2902,7 +2902,7 @@ export declare const eth_simulateV1: import("./from.js").Item<"eth_simulateV1",
|
|
|
2902
2902
|
blockTimestamp: z.ZodMiniOptional<z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniBigInt<bigint>>>;
|
|
2903
2903
|
data: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
2904
2904
|
logIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
2905
|
-
topics: z.
|
|
2905
|
+
topics: z.ZodMiniArray<z.ZodMiniTemplateLiteral<`0x${string}`>>;
|
|
2906
2906
|
transactionHash: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
2907
2907
|
transactionIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
2908
2908
|
removed: z.ZodMiniBoolean<boolean>;
|
|
@@ -18,7 +18,7 @@ export declare const eth_sendRawTransactionSync: import("./from.js").Item<"eth_s
|
|
|
18
18
|
blockTimestamp: z.ZodMiniOptional<z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniBigInt<bigint>>>;
|
|
19
19
|
data: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
20
20
|
logIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
21
|
-
topics: z.
|
|
21
|
+
topics: z.ZodMiniArray<z.ZodMiniTemplateLiteral<`0x${string}`>>;
|
|
22
22
|
transactionHash: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
23
23
|
transactionIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
24
24
|
removed: z.ZodMiniBoolean<boolean>;
|
|
@@ -901,7 +901,7 @@ export declare const tempo_simulateV1: import("../internal/rpcSchemas/from.js").
|
|
|
901
901
|
blockTimestamp: z.ZodMiniOptional<z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniBigInt<bigint>>>;
|
|
902
902
|
data: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
903
903
|
logIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
904
|
-
topics: z.
|
|
904
|
+
topics: z.ZodMiniArray<z.ZodMiniTemplateLiteral<`0x${string}`>>;
|
|
905
905
|
transactionHash: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
906
906
|
transactionIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
907
907
|
removed: z.ZodMiniBoolean<boolean>;
|
|
@@ -1819,7 +1819,7 @@ export declare const Tempo: {
|
|
|
1819
1819
|
blockTimestamp: z.ZodMiniOptional<z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniBigInt<bigint>>>;
|
|
1820
1820
|
data: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
1821
1821
|
logIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
1822
|
-
topics: z.
|
|
1822
|
+
topics: z.ZodMiniArray<z.ZodMiniTemplateLiteral<`0x${string}`>>;
|
|
1823
1823
|
transactionHash: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
1824
1824
|
transactionIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
1825
1825
|
removed: z.ZodMiniBoolean<boolean>;
|
|
@@ -23,7 +23,7 @@ export declare const TransactionReceipt: z.ZodMiniObject<{
|
|
|
23
23
|
blockTimestamp: z.ZodMiniOptional<z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniBigInt<bigint>>>;
|
|
24
24
|
data: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
25
25
|
logIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
26
|
-
topics: z.
|
|
26
|
+
topics: z.ZodMiniArray<z.ZodMiniTemplateLiteral<`0x${string}`>>;
|
|
27
27
|
transactionHash: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
28
28
|
transactionIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat>;
|
|
29
29
|
removed: z.ZodMiniBoolean<boolean>;
|
|
@@ -56,7 +56,7 @@ export declare const TransactionReceiptToRpc: z.ZodMiniObject<{
|
|
|
56
56
|
blockTimestamp: z.ZodMiniOptional<z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniUnion<readonly [z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniBigInt<bigint>, z.ZodMiniNumberFormat]>>>;
|
|
57
57
|
data: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
58
58
|
logIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniUnion<readonly [z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat]>>;
|
|
59
|
-
topics: z.
|
|
59
|
+
topics: z.ZodMiniArray<z.ZodMiniTemplateLiteral<`0x${string}`>>;
|
|
60
60
|
transactionHash: z.ZodMiniTemplateLiteral<`0x${string}`>;
|
|
61
61
|
transactionIndex: z.ZodMiniCodec<z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniUnion<readonly [z.ZodMiniTemplateLiteral<`0x${string}`>, z.ZodMiniNumberFormat]>>;
|
|
62
62
|
removed: z.ZodMiniBoolean<boolean>;
|
package/package.json
CHANGED
package/src/core/Log.ts
CHANGED
|
@@ -23,7 +23,7 @@ export type Log<
|
|
|
23
23
|
/** Index of this log within its block or `null` if pending */
|
|
24
24
|
logIndex: pending extends true ? null : numberType
|
|
25
25
|
/** List of topics associated with this log */
|
|
26
|
-
topics:
|
|
26
|
+
topics: Hex.Hex[]
|
|
27
27
|
/** Hash of the transaction that created this log or `null` if pending */
|
|
28
28
|
transactionHash: pending extends true ? null : Hex.Hex
|
|
29
29
|
/** Index of the transaction that created this log or `null` if pending */
|
package/src/version.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/** @internal */
|
|
2
|
-
export const version = '1.0.0-beta.
|
|
2
|
+
export const version = '1.0.0-beta.8'
|
package/src/zod/Log.ts
CHANGED
|
@@ -5,7 +5,7 @@ import * as z_Number from './Number.js'
|
|
|
5
5
|
import * as z_Uint from './Uint.js'
|
|
6
6
|
import * as z from 'zod/mini'
|
|
7
7
|
|
|
8
|
-
const topics = z.
|
|
8
|
+
const topics = z.array(z_Hex.Hex)
|
|
9
9
|
|
|
10
10
|
/** Log schema. */
|
|
11
11
|
export const Log = z.object(fields(z_Uint.Uint, z_Number.Number))
|
|
@@ -134,6 +134,22 @@ describe('Log', () => {
|
|
|
134
134
|
).toEqual(expected)
|
|
135
135
|
})
|
|
136
136
|
|
|
137
|
+
test('decodes logs with no topics', () => {
|
|
138
|
+
expect(
|
|
139
|
+
z.decode(z_Log.Log, {
|
|
140
|
+
address,
|
|
141
|
+
blockHash,
|
|
142
|
+
blockNumber: '0x12d846c',
|
|
143
|
+
data: '0xdeadbeef',
|
|
144
|
+
logIndex: '0x10f',
|
|
145
|
+
topics: [],
|
|
146
|
+
transactionHash,
|
|
147
|
+
transactionIndex: '0x91',
|
|
148
|
+
removed: false,
|
|
149
|
+
}).topics,
|
|
150
|
+
).toEqual([])
|
|
151
|
+
})
|
|
152
|
+
|
|
137
153
|
test('rejects invalid topics and quantities', () => {
|
|
138
154
|
expect(
|
|
139
155
|
z.safeDecode(z_Log.Log, {
|