From 501e9aee954b8639f29ee7214f4cd6d6b3e132a9 Mon Sep 17 00:00:00 2001 From: Miguel Angel Rojo Fernandez Date: Fri, 22 Nov 2024 11:31:37 +0000 Subject: [PATCH 1/3] changed type --- packages/abitype/src/abi.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/abitype/src/abi.ts b/packages/abitype/src/abi.ts index 90247c54..62b59a7f 100644 --- a/packages/abitype/src/abi.ts +++ b/packages/abitype/src/abi.ts @@ -218,7 +218,7 @@ export type Abi = readonly ( // Typed Data Types export type TypedDataDomain = { - chainId?: number | undefined + chainId?: number | bigint | string | undefined name?: string | undefined salt?: ResolvedRegister['bytesType']['outputs'] | undefined verifyingContract?: Address | undefined From 661a8ddaa8000b5520b0078723e1df9c4360a61f Mon Sep 17 00:00:00 2001 From: Miguel Angel Rojo Fernandez Date: Fri, 22 Nov 2024 11:34:31 +0000 Subject: [PATCH 2/3] changed type --- packages/abitype/src/zod.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/abitype/src/zod.ts b/packages/abitype/src/zod.ts index 76a5d024..382963bf 100644 --- a/packages/abitype/src/zod.ts +++ b/packages/abitype/src/zod.ts @@ -299,7 +299,7 @@ export const Abi = z // Typed Data Types export const TypedDataDomain = z.object({ - chainId: z.number().optional(), + chainId: z.union([z.number(), z.string(), z.bigint()]).optional(), name: Identifier.optional(), salt: z.string().optional(), verifyingContract: Address.optional(), From a180279536f8d21edf80f9bf75429dd75ea7a9d6 Mon Sep 17 00:00:00 2001 From: Miguel Angel Rojo Date: Fri, 22 Nov 2024 11:46:09 +0000 Subject: [PATCH 3/3] Create shiny-kiwis-smash.md --- .changeset/shiny-kiwis-smash.md | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 .changeset/shiny-kiwis-smash.md diff --git a/.changeset/shiny-kiwis-smash.md b/.changeset/shiny-kiwis-smash.md new file mode 100644 index 00000000..fff70371 --- /dev/null +++ b/.changeset/shiny-kiwis-smash.md @@ -0,0 +1,5 @@ +--- +"abitype": patch +--- + +EIP712 - `chainId` should support `uint256` values