From 7c531927da9edbedc3d635cb38f8a893aff3c51b Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Tue, 16 Jul 2024 15:52:42 +0100 Subject: [PATCH 01/43] chore: organized workspace alphabetically --- .../test/fixtures/forc-projects/Forc.toml | 28 +++++++++---------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/packages/fuel-gauge/test/fixtures/forc-projects/Forc.toml b/packages/fuel-gauge/test/fixtures/forc-projects/Forc.toml index e853095e252..ba40bfc30d0 100644 --- a/packages/fuel-gauge/test/fixtures/forc-projects/Forc.toml +++ b/packages/fuel-gauge/test/fixtures/forc-projects/Forc.toml @@ -1,44 +1,44 @@ [workspace] members = [ + "advanced-logging", "advanced-logging-abi", - "advanced-logging-other-contract-abi", "advanced-logging-other-contract", - "advanced-logging", + "advanced-logging-other-contract-abi", "auth_testing_abi", "auth_testing_contract", "bytecode-sway-lib", "bytes", "call-test-contract", "collision_in_fn_names", + "complex-predicate", + "complex-script", "configurable-contract", "coverage-contract", "generic-types-contract", "multi-token-contract", + "options", "payable-annotation", "predicate-address", + "predicate-assert-number", + "predicate-assert-value", "predicate-bytes", "predicate-conditional-inputs", "predicate-false", + "predicate-input-data", "predicate-main-args-struct", "predicate-main-args-vector", "predicate-multi-args", "predicate-raw-slice", - "predicate-str-slice", "predicate-std-lib-string", - "predicate-input-data", + "predicate-str-slice", + "predicate-sum", "predicate-triple-sig", "predicate-true", "predicate-u32", + "predicate-validate-transfer", "predicate-vector-types", - "predicate-assert-value", - "predicate-assert-number", - "predicate-sum", "predicate-with-configurable", - "predicate-validate-transfer", - "complex-predicate", - "complex-script", "raw-slice", - "str-slice", "reentrant-bar", "reentrant-foo", "reentrant-foobar-abi", @@ -50,20 +50,20 @@ members = [ "script-main-return-struct", "script-main-two-args", "script-raw-slice", - "script-str-slice", "script-std-lib-string", + "script-str-slice", "script-with-array", "script-with-configurable", + "script-with-vector", "script-with-vector-advanced", "script-with-vector-mixed", - "script-with-vector", "small-bytes", "std-lib-string", "storage-test-contract", + "str-slice", "token_abi", "token_contract", "vector-types-contract", "vector-types-script", "vectors", - "options", ] From a971ce79cae49a2b358894a310774f9ca5896e7f Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Tue, 16 Jul 2024 15:55:02 +0100 Subject: [PATCH 02/43] feat: added void contract --- .../fuel-gauge/test/fixtures/forc-projects/Forc.toml | 1 + .../test/fixtures/forc-projects/void/Forc.toml | 4 ++++ .../test/fixtures/forc-projects/void/src/main.sw | 11 +++++++++++ 3 files changed, 16 insertions(+) create mode 100644 packages/fuel-gauge/test/fixtures/forc-projects/void/Forc.toml create mode 100644 packages/fuel-gauge/test/fixtures/forc-projects/void/src/main.sw diff --git a/packages/fuel-gauge/test/fixtures/forc-projects/Forc.toml b/packages/fuel-gauge/test/fixtures/forc-projects/Forc.toml index ba40bfc30d0..cb5a8ccab24 100644 --- a/packages/fuel-gauge/test/fixtures/forc-projects/Forc.toml +++ b/packages/fuel-gauge/test/fixtures/forc-projects/Forc.toml @@ -66,4 +66,5 @@ members = [ "vector-types-contract", "vector-types-script", "vectors", + "void", ] diff --git a/packages/fuel-gauge/test/fixtures/forc-projects/void/Forc.toml b/packages/fuel-gauge/test/fixtures/forc-projects/void/Forc.toml new file mode 100644 index 00000000000..dea821231ae --- /dev/null +++ b/packages/fuel-gauge/test/fixtures/forc-projects/void/Forc.toml @@ -0,0 +1,4 @@ +[project] +authors = ["Fuel Labs "] +license = "Apache-2.0" +name = "void" diff --git a/packages/fuel-gauge/test/fixtures/forc-projects/void/src/main.sw b/packages/fuel-gauge/test/fixtures/forc-projects/void/src/main.sw new file mode 100644 index 00000000000..f2de822ed04 --- /dev/null +++ b/packages/fuel-gauge/test/fixtures/forc-projects/void/src/main.sw @@ -0,0 +1,11 @@ +contract; + +abi VoidContract { + fn return_void() -> Option; +} + +impl VoidContract for Contract { + fn return_void() -> Option { + Option::None + } +} \ No newline at end of file From 05828d461e91e2a134dcfa241f6a47bd59b5ca3d Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Tue, 16 Jul 2024 16:03:35 +0100 Subject: [PATCH 03/43] feat: added void test --- packages/fuel-gauge/src/void.test.ts | 29 ++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 packages/fuel-gauge/src/void.test.ts diff --git a/packages/fuel-gauge/src/void.test.ts b/packages/fuel-gauge/src/void.test.ts new file mode 100644 index 00000000000..d9699383cba --- /dev/null +++ b/packages/fuel-gauge/src/void.test.ts @@ -0,0 +1,29 @@ +import { launchTestNode } from 'fuels/test-utils'; + +import { VoidAbi__factory } from '../test/typegen'; +import VoidAbiHex from '../test/typegen/contracts/VoidAbi.hex'; + +/** + * @group node + */ +describe('Vector Tests', () => { + it('should return a void', async () => { + using launched = await launchTestNode({ + contractsConfigs: [ + { + deployer: VoidAbi__factory, + bytecode: VoidAbiHex, + }, + ], + }); + + const { + contracts: [voidContract], + } = launched; + + const { waitForResult } = await voidContract.functions.return_void().call(); + const { value } = await waitForResult(); + + expect(value).toEqual(undefined); + }); +}); From b65f4239f970d626deb3bcf3d2b98df7b4ac7361 Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Tue, 16 Jul 2024 16:20:04 +0100 Subject: [PATCH 04/43] chore: added `VOID_TYPE` --- packages/abi-coder/src/FunctionFragment.ts | 6 +++--- packages/abi-coder/src/encoding/coders/EnumCoder.ts | 4 ++-- packages/abi-coder/src/utils/constants.ts | 1 + packages/abi-coder/src/utils/json-abi.ts | 4 ++-- 4 files changed, 8 insertions(+), 7 deletions(-) diff --git a/packages/abi-coder/src/FunctionFragment.ts b/packages/abi-coder/src/FunctionFragment.ts index e8941de523d..f696c7064b3 100644 --- a/packages/abi-coder/src/FunctionFragment.ts +++ b/packages/abi-coder/src/FunctionFragment.ts @@ -17,7 +17,7 @@ import type { JsonAbiFunctionAttribute, } from './types/JsonAbi'; import type { EncodingVersion } from './utils/constants'; -import { OPTION_CODER_TYPE } from './utils/constants'; +import { OPTION_CODER_TYPE, VOID_TYPE } from './utils/constants'; import { findFunctionByName, findNonEmptyInputs, @@ -96,7 +96,7 @@ export class FunctionFragment< const inputTypes = inputs.map((input) => findTypeById(abi, input.type)); const optionalInputs = inputTypes.filter( - (x) => x.type === OPTION_CODER_TYPE || x.type === '()' + (x) => x.type === OPTION_CODER_TYPE || x.type === VOID_TYPE ); if (optionalInputs.length === inputTypes.length) { return; @@ -159,7 +159,7 @@ export class FunctionFragment< decodeOutput(data: BytesLike): [DecodedValue | undefined, number] { const outputAbiType = findTypeById(this.jsonAbi, this.jsonFn.output.type); - if (outputAbiType.type === '()') { + if (outputAbiType.type === VOID_TYPE) { return [undefined, 0]; } diff --git a/packages/abi-coder/src/encoding/coders/EnumCoder.ts b/packages/abi-coder/src/encoding/coders/EnumCoder.ts index 1638dcbcb9f..72f3b1e20ec 100644 --- a/packages/abi-coder/src/encoding/coders/EnumCoder.ts +++ b/packages/abi-coder/src/encoding/coders/EnumCoder.ts @@ -3,7 +3,7 @@ import { toNumber } from '@fuel-ts/math'; import { concat } from '@fuel-ts/utils'; import type { RequireExactlyOne } from 'type-fest'; -import { OPTION_CODER_TYPE } from '../../utils/constants'; +import { OPTION_CODER_TYPE, VOID_TYPE } from '../../utils/constants'; import { hasNestedOption } from '../../utils/utilities'; import type { TypesOfCoder } from './AbstractCoder'; @@ -45,7 +45,7 @@ export class EnumCoder> extends Coder< // We parse a native enum as an empty tuple, so we are looking for a tuple with no child coders. // The '()' is enough but the child coders is a stricter check. #isNativeEnum(coder: Coder): boolean { - if (this.type !== OPTION_CODER_TYPE && coder.type === '()') { + if (this.type !== OPTION_CODER_TYPE && coder.type === VOID_TYPE) { const tupleCoder = coder as TupleCoder<[]>; return tupleCoder.coders.length === 0; } diff --git a/packages/abi-coder/src/utils/constants.ts b/packages/abi-coder/src/utils/constants.ts index a533ddf8f51..25aab229a57 100644 --- a/packages/abi-coder/src/utils/constants.ts +++ b/packages/abi-coder/src/utils/constants.ts @@ -16,6 +16,7 @@ export const VEC_CODER_TYPE = 'struct Vec'; export const BYTES_CODER_TYPE = 'struct Bytes'; export const STD_STRING_CODER_TYPE = 'struct String'; export const STR_SLICE_CODER_TYPE = 'str'; +export const VOID_TYPE = '()'; export const stringRegEx = /str\[(?[0-9]+)\]/; export const arrayRegEx = /\[(?[\w\s\\[\]]+);\s*(?[0-9]+)\]/; export const structRegEx = /^struct (?\w+)$/; diff --git a/packages/abi-coder/src/utils/json-abi.ts b/packages/abi-coder/src/utils/json-abi.ts index 753244174a8..6bfb671d320 100644 --- a/packages/abi-coder/src/utils/json-abi.ts +++ b/packages/abi-coder/src/utils/json-abi.ts @@ -3,7 +3,7 @@ import { ErrorCode, FuelError } from '@fuel-ts/errors'; import type { ResolvedAbiType } from '../ResolvedAbiType'; import type { JsonAbi, JsonAbiArgument, JsonAbiFunction, JsonAbiType } from '../types/JsonAbi'; -import { ENCODING_V1, type EncodingVersion } from './constants'; +import { ENCODING_V1, VOID_TYPE, type EncodingVersion } from './constants'; /** * Asserts that the encoding version is supported by the ABI coder. @@ -73,7 +73,7 @@ export const findTypeById = (abi: JsonAbi, typeId: number): JsonAbiType => { export const findNonEmptyInputs = ( abi: JsonAbi, inputs: readonly JsonAbiArgument[] -): JsonAbiArgument[] => inputs.filter((input) => findTypeById(abi, input.type).type !== '()'); +): JsonAbiArgument[] => inputs.filter((input) => findTypeById(abi, input.type).type !== VOID_TYPE); /** * Find the vector buffer argument in a list of components. From fd41c5f00a5c9d34ba870b3c98c7694681905bde Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Tue, 16 Jul 2024 17:44:45 +0100 Subject: [PATCH 05/43] feat: converted `void` tests to echo based, added NativeEnums --- packages/fuel-gauge/src/void.test.ts | 44 ++++++++++++++----- .../fixtures/forc-projects/void/src/main.sw | 27 ++++++++++-- 2 files changed, 55 insertions(+), 16 deletions(-) diff --git a/packages/fuel-gauge/src/void.test.ts b/packages/fuel-gauge/src/void.test.ts index d9699383cba..ff0aa283433 100644 --- a/packages/fuel-gauge/src/void.test.ts +++ b/packages/fuel-gauge/src/void.test.ts @@ -1,29 +1,49 @@ +import type { DeployContractConfig } from 'fuels/test-utils'; import { launchTestNode } from 'fuels/test-utils'; import { VoidAbi__factory } from '../test/typegen'; +import type { NativeEnumInput } from '../test/typegen/contracts/VoidAbi'; import VoidAbiHex from '../test/typegen/contracts/VoidAbi.hex'; +import type { Option } from '../test/typegen/contracts/common'; /** * @group node */ -describe('Vector Tests', () => { - it('should return a void', async () => { - using launched = await launchTestNode({ - contractsConfigs: [ - { - deployer: VoidAbi__factory, - bytecode: VoidAbiHex, - }, - ], - }); +describe('Void Tests', () => { + const contractsConfigs: DeployContractConfig[] = [ + { + deployer: VoidAbi__factory, + bytecode: VoidAbiHex, + }, + ]; + + it('should handle Option::None', async () => { + using launched = await launchTestNode({ contractsConfigs }); + + const { + contracts: [voidContract], + } = launched; + + const optionNone: Option = undefined; + + const { waitForResult } = await voidContract.functions.echo_void(optionNone).call(); + const { value } = await waitForResult(); + + expect(value).toEqual(optionNone); + }); + + it('should handle NativeEnum', async () => { + using launched = await launchTestNode({ contractsConfigs }); const { contracts: [voidContract], } = launched; - const { waitForResult } = await voidContract.functions.return_void().call(); + const enumValue: NativeEnumInput = 'C' as NativeEnumInput; + + const { waitForResult } = await voidContract.functions.echo_native_enum(enumValue).call(); const { value } = await waitForResult(); - expect(value).toEqual(undefined); + expect(value).toEqual(enumValue); }); }); diff --git a/packages/fuel-gauge/test/fixtures/forc-projects/void/src/main.sw b/packages/fuel-gauge/test/fixtures/forc-projects/void/src/main.sw index f2de822ed04..077813958fe 100644 --- a/packages/fuel-gauge/test/fixtures/forc-projects/void/src/main.sw +++ b/packages/fuel-gauge/test/fixtures/forc-projects/void/src/main.sw @@ -1,11 +1,30 @@ contract; +enum NativeEnum { + A: (), + B: (), + C: (), +} + abi VoidContract { - fn return_void() -> Option; + fn echo_void(value: Option) -> Option; + fn echo_native_enum(value: NativeEnum) -> NativeEnum; } impl VoidContract for Contract { - fn return_void() -> Option { - Option::None + fn echo_void(value: Option) -> Option { + assert_eq(value, Option::None); + + value } -} \ No newline at end of file + + fn echo_native_enum(value: NativeEnum) -> NativeEnum { + match value { + NativeEnum::A => assert(false), + NativeEnum::B => assert(false), + NativeEnum::C => assert(true), + }; + + value + } +} From 63e69e911f25bff6d7fc8073a0b8bd85db0d2286 Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Tue, 16 Jul 2024 19:23:36 +0100 Subject: [PATCH 06/43] feat: added `VoidCoder` --- .../src/encoding/coders/VoidCoder.test.ts | 37 +++++++++++++++++++ .../src/encoding/coders/VoidCoder.ts | 17 +++++++++ .../src/encoding/strategies/getCoderV1.ts | 4 ++ 3 files changed, 58 insertions(+) create mode 100644 packages/abi-coder/src/encoding/coders/VoidCoder.test.ts create mode 100644 packages/abi-coder/src/encoding/coders/VoidCoder.ts diff --git a/packages/abi-coder/src/encoding/coders/VoidCoder.test.ts b/packages/abi-coder/src/encoding/coders/VoidCoder.test.ts new file mode 100644 index 00000000000..d9b653d798d --- /dev/null +++ b/packages/abi-coder/src/encoding/coders/VoidCoder.test.ts @@ -0,0 +1,37 @@ +import { VoidCoder } from './VoidCoder'; + +/** + * @group node + */ +describe('VoidCoder', () => { + it('should have properties', () => { + const coder = new VoidCoder(); + expect(coder.name).toEqual('void'); + expect(coder.type).toEqual('()'); + expect(coder.encodedLength).toEqual(0); + }); + + describe('encode', () => { + it('should return an empty Uint8Array', () => { + const input = undefined; + const expected = new Uint8Array([]); + + const coder = new VoidCoder(); + const value = coder.encode(input); + expect(value).toEqual(expected); + }); + }); + + describe('decode', () => { + it('should return an undefined result', () => { + const input = new Uint8Array([]); + const expected = undefined; + const expectedOffset = 0; + + const coder = new VoidCoder(); + const [value, offset] = coder.decode(input, 0); + expect(value).toEqual(expected); + expect(offset).toEqual(expectedOffset); + }); + }); +}); diff --git a/packages/abi-coder/src/encoding/coders/VoidCoder.ts b/packages/abi-coder/src/encoding/coders/VoidCoder.ts new file mode 100644 index 00000000000..d835bf5ad2c --- /dev/null +++ b/packages/abi-coder/src/encoding/coders/VoidCoder.ts @@ -0,0 +1,17 @@ +import { VOID_TYPE } from '../../utils/constants'; + +import { Coder } from './AbstractCoder'; + +export class VoidCoder extends Coder { + constructor() { + super('void', VOID_TYPE, 0); + } + + encode(_value: undefined): Uint8Array { + return new Uint8Array([]); + } + + decode(_data: Uint8Array, offset: number): [undefined, number] { + return [undefined, offset]; + } +} diff --git a/packages/abi-coder/src/encoding/strategies/getCoderV1.ts b/packages/abi-coder/src/encoding/strategies/getCoderV1.ts index 6e89b95a2d5..816fc1d3934 100644 --- a/packages/abi-coder/src/encoding/strategies/getCoderV1.ts +++ b/packages/abi-coder/src/encoding/strategies/getCoderV1.ts @@ -20,6 +20,7 @@ import { U64_CODER_TYPE, U8_CODER_TYPE, VEC_CODER_TYPE, + VOID_TYPE, arrayRegEx, enumRegEx, stringRegEx, @@ -44,6 +45,7 @@ import { StringCoder } from '../coders/StringCoder'; import { StructCoder } from '../coders/StructCoder'; import { TupleCoder } from '../coders/TupleCoder'; import { VecCoder } from '../coders/VecCoder'; +import { VoidCoder } from '../coders/VoidCoder'; import { getCoders } from './getCoders'; @@ -82,6 +84,8 @@ export const getCoder: GetCoderFn = ( return new StdStringCoder(); case STR_SLICE_CODER_TYPE: return new StrSliceCoder(); + case VOID_TYPE: + return new VoidCoder(); default: break; } From b32636969e8fe1ecff63d271b18de608d5a669f5 Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Tue, 16 Jul 2024 19:24:35 +0100 Subject: [PATCH 07/43] chore: changeset --- .changeset/tender-birds-tap.md | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 .changeset/tender-birds-tap.md diff --git a/.changeset/tender-birds-tap.md b/.changeset/tender-birds-tap.md new file mode 100644 index 00000000000..89a5a867a24 --- /dev/null +++ b/.changeset/tender-birds-tap.md @@ -0,0 +1,5 @@ +--- +"@fuel-ts/abi-coder": patch +--- + +feat: implement `VoidCoder` From c0e5d7b361c9b0cff2df1e9ae11d86ee9d672ecb Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Tue, 16 Jul 2024 19:33:45 +0100 Subject: [PATCH 08/43] chore: simplify the `EnumCoder::isNativeEnum` check --- packages/abi-coder/src/encoding/coders/EnumCoder.ts | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/packages/abi-coder/src/encoding/coders/EnumCoder.ts b/packages/abi-coder/src/encoding/coders/EnumCoder.ts index 72f3b1e20ec..0124042bfe7 100644 --- a/packages/abi-coder/src/encoding/coders/EnumCoder.ts +++ b/packages/abi-coder/src/encoding/coders/EnumCoder.ts @@ -9,7 +9,6 @@ import { hasNestedOption } from '../../utils/utilities'; import type { TypesOfCoder } from './AbstractCoder'; import { Coder } from './AbstractCoder'; import { BigNumberCoder } from './BigNumberCoder'; -import type { TupleCoder } from './TupleCoder'; export type InputValueOf> = RequireExactlyOne<{ [P in keyof TCoders]: TypesOfCoder['Input']; @@ -42,14 +41,9 @@ export class EnumCoder> extends Coder< this.#shouldValidateLength = !(this.type === OPTION_CODER_TYPE || hasNestedOption(coders)); } - // We parse a native enum as an empty tuple, so we are looking for a tuple with no child coders. - // The '()' is enough but the child coders is a stricter check. + // Checks that we're handling a native enum that is of type void. #isNativeEnum(coder: Coder): boolean { - if (this.type !== OPTION_CODER_TYPE && coder.type === VOID_TYPE) { - const tupleCoder = coder as TupleCoder<[]>; - return tupleCoder.coders.length === 0; - } - return false; + return this.type !== OPTION_CODER_TYPE && coder.type === VOID_TYPE; } #encodeNativeEnum(value: string): Uint8Array { From 5da1c610be1024df53c780a1b1306c4acaeaf302 Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Wed, 17 Jul 2024 15:35:55 +0100 Subject: [PATCH 09/43] chore: update void test --- packages/fuel-gauge/src/void.test.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/fuel-gauge/src/void.test.ts b/packages/fuel-gauge/src/void.test.ts index ff0aa283433..043d4800f81 100644 --- a/packages/fuel-gauge/src/void.test.ts +++ b/packages/fuel-gauge/src/void.test.ts @@ -10,7 +10,7 @@ import type { Option } from '../test/typegen/contracts/common'; * @group node */ describe('Void Tests', () => { - const contractsConfigs: DeployContractConfig[] = [ + const contractsConfigs = [ { deployer: VoidAbi__factory, bytecode: VoidAbiHex, From ee2e2b735dec701bdf6044b5b99aa8a5e9ae830d Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Mon, 22 Jul 2024 13:43:03 +0100 Subject: [PATCH 10/43] feat: implemented EmptyType for typegen, matched to `undefined` --- .../abi-typegen/src/abi/functions/Function.ts | 50 ++++++++----------- .../src/abi/types/EmptyType.test.ts | 4 +- .../abi-typegen/src/abi/types/EmptyType.ts | 10 ++-- .../src/utils/parseTypeArguments.test.ts | 2 +- .../test/fixtures/templates/contract/dts.hbs | 8 +-- packages/fuel-gauge/src/void.test.ts | 1 - 6 files changed, 33 insertions(+), 42 deletions(-) diff --git a/packages/abi-typegen/src/abi/functions/Function.ts b/packages/abi-typegen/src/abi/functions/Function.ts index f898e150624..4b3ab5e448c 100644 --- a/packages/abi-typegen/src/abi/functions/Function.ts +++ b/packages/abi-typegen/src/abi/functions/Function.ts @@ -3,7 +3,6 @@ import { TargetEnum } from '../../types/enums/TargetEnum'; import type { IType } from '../../types/interfaces/IType'; import { findType } from '../../utils/findType'; import { parseTypeArguments } from '../../utils/parseTypeArguments'; -import { EmptyType } from '../types/EmptyType'; export class Function implements IFunction { public name: string; @@ -27,38 +26,33 @@ export class Function implements IFunction { const { types } = this; // loop through all inputs - const inputs = this.rawAbiFunction.inputs - .filter((input) => { - const type = findType({ types, typeId: input.type }); - return type.rawAbiType.type !== EmptyType.swayType; - }) - .map((input) => { - const { name, type: typeId, typeArguments } = input; + const inputs = this.rawAbiFunction.inputs.map((input) => { + const { name, type: typeId, typeArguments } = input; - const type = findType({ types, typeId }); + const type = findType({ types, typeId }); - let typeDecl: string; + let typeDecl: string; - if (typeArguments) { - // recursively process child `typeArguments` - typeDecl = parseTypeArguments({ - types, - target: TargetEnum.INPUT, - parentTypeId: typeId, - typeArguments, - }); - } else { - // or just collect type declaration - typeDecl = type.attributes.inputLabel; - } + if (typeArguments) { + // recursively process child `typeArguments` + typeDecl = parseTypeArguments({ + types, + target: TargetEnum.INPUT, + parentTypeId: typeId, + typeArguments, + }); + } else { + // or just collect type declaration + typeDecl = type.attributes.inputLabel; + } - // assemble it in `[key: string]: ` fashion - if (shouldPrefixParams) { - return `${name}: ${typeDecl}`; - } + // assemble it in `[key: string]: ` fashion + if (shouldPrefixParams) { + return `${name}: ${typeDecl}`; + } - return typeDecl; - }); + return typeDecl; + }); return inputs.join(', '); } diff --git a/packages/abi-typegen/src/abi/types/EmptyType.test.ts b/packages/abi-typegen/src/abi/types/EmptyType.test.ts index 8b2a745d4b0..dcf80963be9 100644 --- a/packages/abi-typegen/src/abi/types/EmptyType.test.ts +++ b/packages/abi-typegen/src/abi/types/EmptyType.test.ts @@ -14,7 +14,7 @@ describe('EmptyType.ts', () => { }, }); - expect(emptyType.attributes.inputLabel).toEqual('never'); - expect(emptyType.attributes.outputLabel).toEqual('void'); + expect(emptyType.attributes.inputLabel).toEqual('undefined'); + expect(emptyType.attributes.outputLabel).toEqual('undefined'); }); }); diff --git a/packages/abi-typegen/src/abi/types/EmptyType.ts b/packages/abi-typegen/src/abi/types/EmptyType.ts index 346dde2bb84..cb0991db33d 100644 --- a/packages/abi-typegen/src/abi/types/EmptyType.ts +++ b/packages/abi-typegen/src/abi/types/EmptyType.ts @@ -10,15 +10,13 @@ export class EmptyType extends AType implements IType { static MATCH_REGEX: RegExp = /^\(\)$/m; + static TYPE_LABEL: string = 'undefined'; + constructor(params: { rawAbiType: JsonAbiType }) { super(params); this.attributes = { - /** - * The empty type is always ignored in function inputs. If it makes - * its way into a function's inputs list, it's a bug in the typegen. - */ - inputLabel: `never`, - outputLabel: `void`, + inputLabel: EmptyType.TYPE_LABEL, + outputLabel: EmptyType.TYPE_LABEL, }; } diff --git a/packages/abi-typegen/src/utils/parseTypeArguments.test.ts b/packages/abi-typegen/src/utils/parseTypeArguments.test.ts index dbb7b115f82..610dcd7e96f 100644 --- a/packages/abi-typegen/src/utils/parseTypeArguments.test.ts +++ b/packages/abi-typegen/src/utils/parseTypeArguments.test.ts @@ -114,6 +114,6 @@ describe('parseTypeArguments.ts', () => { // should fallback to void because `typeArguments.type` will be 0, and non-existent const asOutput = parseTypeArguments({ types, target: TargetEnum.OUTPUT, typeArguments }); - expect(asOutput).toEqual('void'); + expect(asOutput).toEqual('undefined'); }); }); diff --git a/packages/abi-typegen/test/fixtures/templates/contract/dts.hbs b/packages/abi-typegen/test/fixtures/templates/contract/dts.hbs index 88205949c4e..b567e1a2773 100644 --- a/packages/abi-typegen/test/fixtures/templates/contract/dts.hbs +++ b/packages/abi-typegen/test/fixtures/templates/contract/dts.hbs @@ -109,8 +109,8 @@ export class MyContractAbi extends Contract { types_b512: InvokeFunction<[x: string], string>; types_bool: InvokeFunction<[x: boolean], boolean>; types_bytes: InvokeFunction<[x: Bytes], Bytes>; - types_empty: InvokeFunction<[], void>; - types_empty_then_value: InvokeFunction<[y: BigNumberish], void>; + types_empty: InvokeFunction<[x: undefined], undefined>; + types_empty_then_value: InvokeFunction<[x: undefined, y: BigNumberish], undefined>; types_enum: InvokeFunction<[x: MyEnumInput], MyEnumOutput>; types_enum_with_vector: InvokeFunction<[x: EnumWithVectorInput], EnumWithVectorOutput>; types_evm_address: InvokeFunction<[x: EvmAddress], EvmAddress>; @@ -130,8 +130,8 @@ export class MyContractAbi extends Contract { types_u32: InvokeFunction<[x: BigNumberish], number>; types_u64: InvokeFunction<[x: BigNumberish], BN>; types_u8: InvokeFunction<[x: BigNumberish], number>; - types_value_then_empty: InvokeFunction<[x: BigNumberish], void>; - types_value_then_empty_then_value: InvokeFunction<[x: BigNumberish, z: BigNumberish], void>; + types_value_then_empty: InvokeFunction<[x: BigNumberish, y: undefined], undefined>; + types_value_then_empty_then_value: InvokeFunction<[x: BigNumberish, y: undefined, z: BigNumberish], undefined>; types_vector_geo: InvokeFunction<[x: Vec], Vec>; types_vector_option: InvokeFunction<[x: Vec], Vec>; types_vector_u8: InvokeFunction<[x: Vec], Vec>; diff --git a/packages/fuel-gauge/src/void.test.ts b/packages/fuel-gauge/src/void.test.ts index 043d4800f81..9e835f0cbad 100644 --- a/packages/fuel-gauge/src/void.test.ts +++ b/packages/fuel-gauge/src/void.test.ts @@ -1,4 +1,3 @@ -import type { DeployContractConfig } from 'fuels/test-utils'; import { launchTestNode } from 'fuels/test-utils'; import { VoidAbi__factory } from '../test/typegen'; From 2493c85f19cee64bf637aeccb8b0b180c8058d53 Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Mon, 22 Jul 2024 14:29:00 +0100 Subject: [PATCH 11/43] feat: added e2e tests around the void arguments --- packages/abi-coder/src/FunctionFragment.ts | 11 ++----- packages/fuel-gauge/src/void.test.ts | 32 +++++++++++++++++++ .../fixtures/forc-projects/void/src/main.sw | 15 +++++++++ 3 files changed, 49 insertions(+), 9 deletions(-) diff --git a/packages/abi-coder/src/FunctionFragment.ts b/packages/abi-coder/src/FunctionFragment.ts index f696c7064b3..35dd5a21ed9 100644 --- a/packages/abi-coder/src/FunctionFragment.ts +++ b/packages/abi-coder/src/FunctionFragment.ts @@ -68,20 +68,13 @@ export class FunctionFragment< encodeArguments(values: InputValue[]): Uint8Array { FunctionFragment.verifyArgsAndInputsAlign(values, this.jsonFn.inputs, this.jsonAbi); - const shallowCopyValues = values.slice(); - const nonEmptyInputs = findNonEmptyInputs(this.jsonAbi, this.jsonFn.inputs); - - if (Array.isArray(values) && nonEmptyInputs.length !== values.length) { - shallowCopyValues.length = this.jsonFn.inputs.length; - shallowCopyValues.fill(undefined as unknown as InputValue, values.length); - } - - const coders = nonEmptyInputs.map((t) => + const coders = this.jsonFn.inputs.map((t) => AbiCoder.getCoder(this.jsonAbi, t, { encoding: this.encoding, }) ); + const shallowCopyValues = values.slice(); return new TupleCoder(coders).encode(shallowCopyValues); } diff --git a/packages/fuel-gauge/src/void.test.ts b/packages/fuel-gauge/src/void.test.ts index 9e835f0cbad..945b114ac50 100644 --- a/packages/fuel-gauge/src/void.test.ts +++ b/packages/fuel-gauge/src/void.test.ts @@ -45,4 +45,36 @@ describe('Void Tests', () => { expect(value).toEqual(enumValue); }); + + it('should handle input arguments of type [42, void]', async () => { + using launched = await launchTestNode({ contractsConfigs }); + + const { + contracts: [voidContract], + } = launched; + + const voidTypeValue: undefined = undefined; + + const { waitForResult } = await voidContract.functions.type_then_void(42, voidTypeValue).call(); + const { value } = await waitForResult(); + + expect(value).toEqual(voidTypeValue); + }); + + it('should handle input arguments of type [42, void, 43]', async () => { + using launched = await launchTestNode({ contractsConfigs }); + + const { + contracts: [voidContract], + } = launched; + + const voidTypeValue: undefined = undefined; + + const { waitForResult } = await voidContract.functions + .type_then_void_then_type(42, voidTypeValue, 43) + .call(); + const { value } = await waitForResult(); + + expect(value).toEqual(voidTypeValue); + }); }); diff --git a/packages/fuel-gauge/test/fixtures/forc-projects/void/src/main.sw b/packages/fuel-gauge/test/fixtures/forc-projects/void/src/main.sw index 077813958fe..d626dc64fe5 100644 --- a/packages/fuel-gauge/test/fixtures/forc-projects/void/src/main.sw +++ b/packages/fuel-gauge/test/fixtures/forc-projects/void/src/main.sw @@ -9,6 +9,8 @@ enum NativeEnum { abi VoidContract { fn echo_void(value: Option) -> Option; fn echo_native_enum(value: NativeEnum) -> NativeEnum; + fn type_then_void(x: u8, y: ()) -> (); + fn type_then_void_then_type(x: u8, y: (), z: u8) -> (); } impl VoidContract for Contract { @@ -27,4 +29,17 @@ impl VoidContract for Contract { value } + + fn type_then_void(x: u8, y: ()) -> () { + assert_eq(x, 42); + + y + } + + fn type_then_void_then_type(x: u8, y: (), z: u8) -> () { + assert_eq(x, 42); + assert_eq(z, 43); + + y + } } From 9c9aa3cd96421d142acf1cf7b76e9106bfc15df3 Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Mon, 22 Jul 2024 19:50:35 +0100 Subject: [PATCH 12/43] chore: fixing tests --- .../src/guide/types/options.test.ts | 30 ++++++++++++------- .../fuel-gauge/src/call-test-contract.test.ts | 8 ++--- .../fuel-gauge/src/coverage-contract.test.ts | 6 ++-- packages/fuel-gauge/src/fee.test.ts | 2 +- .../predicate/predicate-input-data.test.ts | 9 ++---- 5 files changed, 31 insertions(+), 24 deletions(-) diff --git a/apps/docs-snippets/src/guide/types/options.test.ts b/apps/docs-snippets/src/guide/types/options.test.ts index 30b9120a558..61014dd71d9 100644 --- a/apps/docs-snippets/src/guide/types/options.test.ts +++ b/apps/docs-snippets/src/guide/types/options.test.ts @@ -1,19 +1,24 @@ -import type { Contract } from 'fuels'; +import { launchTestNode } from 'fuels/test-utils'; -import { DocSnippetProjectsEnum } from '../../../test/fixtures/forc-projects'; -import { createAndDeployContractFromProject } from '../../utils'; +import { SumOptionU8Abi__factory } from '../../../test/typegen'; +import bytecode from '../../../test/typegen/contracts/SumOptionU8Abi.hex'; + +function setupContract() { + return launchTestNode({ + contractsConfigs: [{ deployer: SumOptionU8Abi__factory, bytecode }], + }); +} /** * @group node */ describe(__filename, () => { - let contract: Contract; - - beforeAll(async () => { - contract = await createAndDeployContractFromProject(DocSnippetProjectsEnum.SUM_OPTION_U8); - }); - it('should successfully execute contract call to sum 2 option inputs (2 INPUTS)', async () => { + using launched = await setupContract(); + const { + contracts: [contract], + } = launched; + // #region options-1 // Sway Option // #region options-3 @@ -29,10 +34,15 @@ describe(__filename, () => { }); it('should successfully execute contract call to sum 2 option inputs (1 INPUT)', async () => { + using launched = await setupContract(); + const { + contracts: [contract], + } = launched; + // #region options-4 const input: number | undefined = 5; - const { value } = await contract.functions.sum_optional_u8(input).simulate(); + const { value } = await contract.functions.sum_optional_u8(input, undefined).simulate(); expect(value).toEqual(input); // #endregion options-4 diff --git a/packages/fuel-gauge/src/call-test-contract.test.ts b/packages/fuel-gauge/src/call-test-contract.test.ts index 87fa0f729b0..7f877070555 100644 --- a/packages/fuel-gauge/src/call-test-contract.test.ts +++ b/packages/fuel-gauge/src/call-test-contract.test.ts @@ -42,19 +42,19 @@ describe('CallTestContract', () => { it('can call a function with empty arguments', async () => { using contract = await setupContract(); - const call1 = await contract.functions.empty().call(); + const call1 = await contract.functions.empty(undefined).call(); const { value: empty } = await call1.waitForResult(); expect(empty.toHex()).toEqual(toHex(63)); - const call2 = await contract.functions.empty_then_value(35).call(); + const call2 = await contract.functions.empty_then_value(undefined, 35).call(); const { value: emptyThenValue } = await call2.waitForResult(); expect(emptyThenValue.toHex()).toEqual(toHex(63)); - const call3 = await contract.functions.value_then_empty(35).call(); + const call3 = await contract.functions.value_then_empty(35, undefined).call(); const { value: valueThenEmpty } = await call3.waitForResult(); expect(valueThenEmpty.toHex()).toEqual(toHex(63)); - const call4 = await contract.functions.value_then_empty_then_value(35, 35).call(); + const call4 = await contract.functions.value_then_empty_then_value(35, undefined, 35).call(); const { value: valueThenEmptyThenValue } = await call4.waitForResult(); expect(valueThenEmptyThenValue.toHex()).toEqual(toHex(63)); diff --git a/packages/fuel-gauge/src/coverage-contract.test.ts b/packages/fuel-gauge/src/coverage-contract.test.ts index 8478298f215..dc3f2b5d40f 100644 --- a/packages/fuel-gauge/src/coverage-contract.test.ts +++ b/packages/fuel-gauge/src/coverage-contract.test.ts @@ -361,7 +361,7 @@ describe('Coverage Contract', () => { expect(None).toStrictEqual(500); - const call2 = await contractInstance.functions.echo_option_extract_u32().call(); + const call2 = await contractInstance.functions.echo_option_extract_u32(undefined).call(); const { value: NoneVoid } = await call2.waitForResult(); @@ -392,7 +392,9 @@ describe('Coverage Contract', () => { const INPUT = 1; // adds the three values together, but only first param value is supplied - const { waitForResult } = await contractInstance.functions.echo_option_three_u8(INPUT).call(); + const { waitForResult } = await contractInstance.functions + .echo_option_three_u8(INPUT, undefined, undefined) + .call(); const { value: Some } = await waitForResult(); // we receive the result of adding whatever was passed diff --git a/packages/fuel-gauge/src/fee.test.ts b/packages/fuel-gauge/src/fee.test.ts index d597321e6ca..22fbb56c571 100644 --- a/packages/fuel-gauge/src/fee.test.ts +++ b/packages/fuel-gauge/src/fee.test.ts @@ -245,7 +245,7 @@ describe('Fee', () => { const scope = contract.multiCall([ contract.functions.sum_multparams(1, 2, 3, 4, 5), contract.functions.return_void(), - contract.functions.empty(), + contract.functions.empty(undefined), contract.functions.return_bytes(), ]); diff --git a/packages/fuel-gauge/src/predicate/predicate-input-data.test.ts b/packages/fuel-gauge/src/predicate/predicate-input-data.test.ts index 3e04ed4fb0e..dbbb192712e 100644 --- a/packages/fuel-gauge/src/predicate/predicate-input-data.test.ts +++ b/packages/fuel-gauge/src/predicate/predicate-input-data.test.ts @@ -1,4 +1,4 @@ -import { Predicate, Wallet } from 'fuels'; +import { Wallet } from 'fuels'; import { launchTestNode } from 'fuels/test-utils'; import { PredicateInputDataAbi__factory } from '../../test/typegen'; @@ -22,12 +22,7 @@ describe('Predicate', () => { const amountToPredicate = 200_000; const amountToReceiver = 50; - const predicate = new Predicate({ - bytecode: PredicateInputDataAbi__factory.bin, - abi: PredicateInputDataAbi__factory.abi, - provider, - inputData: [true], - }); + const predicate = PredicateInputDataAbi__factory.createInstance(provider); await fundPredicate(wallet, predicate, amountToPredicate); From db19ec753f5c7e320a68580af048bcfd61c6f83d Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Tue, 23 Jul 2024 09:23:14 +0100 Subject: [PATCH 13/43] feat: implemented `getMandatoryInputs` --- .../abi-typegen/src/abi/functions/Function.ts | 49 ++++++----- .../src/utils/getMandatoryInputs.test.ts | 84 +++++++++++++++++++ .../src/utils/getMandatoryInputs.ts | 22 +++++ .../fixtures/forc-projects/full/src/main.sw | 8 ++ .../test/fixtures/templates/contract/dts.hbs | 6 +- 5 files changed, 144 insertions(+), 25 deletions(-) create mode 100644 packages/abi-typegen/src/utils/getMandatoryInputs.test.ts create mode 100644 packages/abi-typegen/src/utils/getMandatoryInputs.ts diff --git a/packages/abi-typegen/src/abi/functions/Function.ts b/packages/abi-typegen/src/abi/functions/Function.ts index 4b3ab5e448c..4edaeabee71 100644 --- a/packages/abi-typegen/src/abi/functions/Function.ts +++ b/packages/abi-typegen/src/abi/functions/Function.ts @@ -2,6 +2,7 @@ import type { IFunction, JsonAbiFunction, IFunctionAttributes } from '../../inde import { TargetEnum } from '../../types/enums/TargetEnum'; import type { IType } from '../../types/interfaces/IType'; import { findType } from '../../utils/findType'; +import { getMandatoryInputs } from '../../utils/getMandatoryInputs'; import { parseTypeArguments } from '../../utils/parseTypeArguments'; export class Function implements IFunction { @@ -25,34 +26,36 @@ export class Function implements IFunction { bundleInputTypes(shouldPrefixParams: boolean = false) { const { types } = this; - // loop through all inputs - const inputs = this.rawAbiFunction.inputs.map((input) => { - const { name, type: typeId, typeArguments } = input; + // loop through all mandatory inputs + const inputs = getMandatoryInputs({ types, inputs: this.rawAbiFunction.inputs }).map( + (input) => { + const { name, type: typeId, typeArguments } = input; - const type = findType({ types, typeId }); + const type = findType({ types, typeId }); - let typeDecl: string; + let typeDecl: string; - if (typeArguments) { - // recursively process child `typeArguments` - typeDecl = parseTypeArguments({ - types, - target: TargetEnum.INPUT, - parentTypeId: typeId, - typeArguments, - }); - } else { - // or just collect type declaration - typeDecl = type.attributes.inputLabel; - } + if (typeArguments) { + // recursively process child `typeArguments` + typeDecl = parseTypeArguments({ + types, + target: TargetEnum.INPUT, + parentTypeId: typeId, + typeArguments, + }); + } else { + // or just collect type declaration + typeDecl = type.attributes.inputLabel; + } - // assemble it in `[key: string]: ` fashion - if (shouldPrefixParams) { - return `${name}: ${typeDecl}`; - } + // assemble it in `[key: string]: ` fashion + if (shouldPrefixParams) { + return `${name}: ${typeDecl}`; + } - return typeDecl; - }); + return typeDecl; + } + ); return inputs.join(', '); } diff --git a/packages/abi-typegen/src/utils/getMandatoryInputs.test.ts b/packages/abi-typegen/src/utils/getMandatoryInputs.test.ts new file mode 100644 index 00000000000..f7bfb028499 --- /dev/null +++ b/packages/abi-typegen/src/utils/getMandatoryInputs.test.ts @@ -0,0 +1,84 @@ +import type { IType } from '../types/interfaces/IType'; +import type { JsonAbiArgument, JsonAbiType } from '../types/interfaces/JsonAbi'; + +import { getMandatoryInputs } from './getMandatoryInputs'; +import { makeType } from './makeType'; + +const nonEmptyType: JsonAbiType = { + type: 'u8', + typeId: 1, + components: null, + typeParameters: null, +}; + +const emptyAbiType: JsonAbiType = { + type: '()', + typeId: 2, + components: null, + typeParameters: null, +}; + +const types: Array = [nonEmptyType, emptyAbiType].map((rawAbiType) => + makeType({ rawAbiType }) +); + +describe('getMandatoryInputs.ts', () => { + it('should handle no inputs', () => { + const inputs: Array = []; + + const result = getMandatoryInputs({ types, inputs }); + + expect(result).toEqual([]); + }); + + it('should handle all empty types', () => { + const inputs: Array = [ + { type: emptyAbiType.typeId, name: 'a', typeArguments: null }, + { type: emptyAbiType.typeId, name: 'b', typeArguments: null }, + { type: emptyAbiType.typeId, name: 'c', typeArguments: null }, + ]; + + const result = getMandatoryInputs({ types, inputs }); + + expect(result).toEqual([]); + }); + + it('should handle all non-empty types', () => { + const inputs: Array = [ + { type: nonEmptyType.typeId, name: 'a', typeArguments: null }, + { type: nonEmptyType.typeId, name: 'b', typeArguments: null }, + { type: nonEmptyType.typeId, name: 'c', typeArguments: null }, + ]; + + const result = getMandatoryInputs({ types, inputs }); + + expect(result).toEqual(inputs); + }); + + it('should handle a mix [non-empty, non-empty, empty]', () => { + const inputs: Array = [ + { type: nonEmptyType.typeId, name: 'a', typeArguments: null }, + { type: nonEmptyType.typeId, name: 'b', typeArguments: null }, + { type: emptyAbiType.typeId, name: 'c', typeArguments: null }, + ]; + + const result = getMandatoryInputs({ types, inputs }); + + expect(result).toEqual([ + { type: nonEmptyType.typeId, name: 'a', typeArguments: null }, + { type: nonEmptyType.typeId, name: 'b', typeArguments: null }, + ]); + }); + + it('should handle a mix [non-empty, empty, non-empty]', () => { + const inputs: Array = [ + { type: nonEmptyType.typeId, name: 'a', typeArguments: null }, + { type: emptyAbiType.typeId, name: 'b', typeArguments: null }, + { type: nonEmptyType.typeId, name: 'c', typeArguments: null }, + ]; + + const result = getMandatoryInputs({ types, inputs }); + + expect(result).toEqual(inputs); + }); +}); diff --git a/packages/abi-typegen/src/utils/getMandatoryInputs.ts b/packages/abi-typegen/src/utils/getMandatoryInputs.ts new file mode 100644 index 00000000000..a6dcded7491 --- /dev/null +++ b/packages/abi-typegen/src/utils/getMandatoryInputs.ts @@ -0,0 +1,22 @@ +import { EmptyType } from '../abi/types/EmptyType'; +import type { IType } from '../types/interfaces/IType'; +import type { JsonAbiArgument } from '../types/interfaces/JsonAbi'; + +import { findType } from './findType'; + +export const getMandatoryInputs = ({ + types, + inputs, +}: { + types: IType[]; + inputs: readonly JsonAbiArgument[]; +}) => { + let i = inputs.length - 1; + for (; i >= 0; i--) { + const type = findType({ types, typeId: inputs[i].type }); + if (type.rawAbiType.type !== EmptyType.swayType) { + break; + } + } + return inputs.slice(0, i + 1); +}; diff --git a/packages/abi-typegen/test/fixtures/forc-projects/full/src/main.sw b/packages/abi-typegen/test/fixtures/forc-projects/full/src/main.sw index f71ae5ec2aa..05d5656cd91 100644 --- a/packages/abi-typegen/test/fixtures/forc-projects/full/src/main.sw +++ b/packages/abi-typegen/test/fixtures/forc-projects/full/src/main.sw @@ -57,6 +57,7 @@ abi MyContract { fn types_empty_then_value(x: (), y: u8) -> (); fn types_value_then_empty(x: u8, y: ()) -> (); fn types_value_then_empty_then_value(x: u8, y: (), z: u8) -> (); + fn types_value_then_value_then_empty_then_empty(x: u8, y: u8, z: (), a: ()) -> (); fn types_u8(x: u8) -> u8; fn types_u16(x: u16) -> u16; fn types_u32(x: u32) -> u32; @@ -96,16 +97,23 @@ impl MyContract for Contract { fn types_empty(x: ()) -> () { x } + fn types_empty_then_value(x: (), y: u8) -> () { () } + fn types_value_then_empty(x: u8, y: ()) -> () { () } + fn types_value_then_empty_then_value(x: u8, y: (), z: u8) -> () { () } + fn types_value_then_value_then_empty_then_empty(x: u8, y: u8, z: (), a: ()) -> () { + () + } + fn types_u8(x: u8) -> u8 { 255 } diff --git a/packages/abi-typegen/test/fixtures/templates/contract/dts.hbs b/packages/abi-typegen/test/fixtures/templates/contract/dts.hbs index b567e1a2773..2974f056d7c 100644 --- a/packages/abi-typegen/test/fixtures/templates/contract/dts.hbs +++ b/packages/abi-typegen/test/fixtures/templates/contract/dts.hbs @@ -89,6 +89,7 @@ interface MyContractAbiInterface extends Interface { types_u8: FunctionFragment; types_value_then_empty: FunctionFragment; types_value_then_empty_then_value: FunctionFragment; + types_value_then_value_then_empty_then_empty: FunctionFragment; types_vector_geo: FunctionFragment; types_vector_option: FunctionFragment; types_vector_u8: FunctionFragment; @@ -109,7 +110,7 @@ export class MyContractAbi extends Contract { types_b512: InvokeFunction<[x: string], string>; types_bool: InvokeFunction<[x: boolean], boolean>; types_bytes: InvokeFunction<[x: Bytes], Bytes>; - types_empty: InvokeFunction<[x: undefined], undefined>; + types_empty: InvokeFunction<[], undefined>; types_empty_then_value: InvokeFunction<[x: undefined, y: BigNumberish], undefined>; types_enum: InvokeFunction<[x: MyEnumInput], MyEnumOutput>; types_enum_with_vector: InvokeFunction<[x: EnumWithVectorInput], EnumWithVectorOutput>; @@ -130,8 +131,9 @@ export class MyContractAbi extends Contract { types_u32: InvokeFunction<[x: BigNumberish], number>; types_u64: InvokeFunction<[x: BigNumberish], BN>; types_u8: InvokeFunction<[x: BigNumberish], number>; - types_value_then_empty: InvokeFunction<[x: BigNumberish, y: undefined], undefined>; + types_value_then_empty: InvokeFunction<[x: BigNumberish], undefined>; types_value_then_empty_then_value: InvokeFunction<[x: BigNumberish, y: undefined, z: BigNumberish], undefined>; + types_value_then_value_then_empty_then_empty: InvokeFunction<[x: BigNumberish, y: BigNumberish], undefined>; types_vector_geo: InvokeFunction<[x: Vec], Vec>; types_vector_option: InvokeFunction<[x: Vec], Vec>; types_vector_u8: InvokeFunction<[x: Vec], Vec>; From ba228cfb6b8f22da5210d4eae70f18aeeae96fec Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Wed, 24 Jul 2024 07:20:12 +0100 Subject: [PATCH 14/43] feat: added optional argument parsing --- .../src/utils/getMandatoryInputs.test.ts | 76 ++++++++++++------- .../src/utils/getMandatoryInputs.ts | 37 ++++++--- 2 files changed, 77 insertions(+), 36 deletions(-) diff --git a/packages/abi-typegen/src/utils/getMandatoryInputs.test.ts b/packages/abi-typegen/src/utils/getMandatoryInputs.test.ts index f7bfb028499..e7d1d990207 100644 --- a/packages/abi-typegen/src/utils/getMandatoryInputs.test.ts +++ b/packages/abi-typegen/src/utils/getMandatoryInputs.test.ts @@ -31,54 +31,78 @@ describe('getMandatoryInputs.ts', () => { expect(result).toEqual([]); }); - it('should handle all empty types', () => { - const inputs: Array = [ - { type: emptyAbiType.typeId, name: 'a', typeArguments: null }, - { type: emptyAbiType.typeId, name: 'b', typeArguments: null }, - { type: emptyAbiType.typeId, name: 'c', typeArguments: null }, - ]; + it('should handle all empty types [empty, empty, empty]', () => { + const A = { type: emptyAbiType.typeId, name: 'a', typeArguments: null }; + const B = { type: emptyAbiType.typeId, name: 'b', typeArguments: null }; + const C = { type: emptyAbiType.typeId, name: 'c', typeArguments: null }; + const inputs: Array = [A, B, C]; const result = getMandatoryInputs({ types, inputs }); - expect(result).toEqual([]); + expect(result).toEqual([ + { ...A, isOptional: true }, + { ...B, isOptional: true }, + { ...C, isOptional: true }, + ]); }); it('should handle all non-empty types', () => { - const inputs: Array = [ - { type: nonEmptyType.typeId, name: 'a', typeArguments: null }, - { type: nonEmptyType.typeId, name: 'b', typeArguments: null }, - { type: nonEmptyType.typeId, name: 'c', typeArguments: null }, - ]; + const A = { type: nonEmptyType.typeId, name: 'a', typeArguments: null }; + const B = { type: nonEmptyType.typeId, name: 'b', typeArguments: null }; + const C = { type: nonEmptyType.typeId, name: 'c', typeArguments: null }; + const inputs: Array = [A, B, C]; const result = getMandatoryInputs({ types, inputs }); - expect(result).toEqual(inputs); + expect(result).toEqual([ + { ...A, isOptional: false }, + { ...B, isOptional: false }, + { ...C, isOptional: false }, + ]); }); it('should handle a mix [non-empty, non-empty, empty]', () => { - const inputs: Array = [ - { type: nonEmptyType.typeId, name: 'a', typeArguments: null }, - { type: nonEmptyType.typeId, name: 'b', typeArguments: null }, - { type: emptyAbiType.typeId, name: 'c', typeArguments: null }, - ]; + const A = { type: nonEmptyType.typeId, name: 'a', typeArguments: null }; + const B = { type: nonEmptyType.typeId, name: 'b', typeArguments: null }; + const C = { type: emptyAbiType.typeId, name: 'c', typeArguments: null }; + const inputs: Array = [A, B, C]; + + const result = getMandatoryInputs({ types, inputs }); + + expect(result).toEqual([ + { ...A, isOptional: false }, + { ...B, isOptional: false }, + { ...C, isOptional: true }, + ]); + }); + + it('should handle a mix [empty, non-empty, non-empty]', () => { + const A = { type: emptyAbiType.typeId, name: 'a', typeArguments: null }; + const B = { type: nonEmptyType.typeId, name: 'b', typeArguments: null }; + const C = { type: nonEmptyType.typeId, name: 'c', typeArguments: null }; + const inputs: Array = [A, B, C]; const result = getMandatoryInputs({ types, inputs }); expect(result).toEqual([ - { type: nonEmptyType.typeId, name: 'a', typeArguments: null }, - { type: nonEmptyType.typeId, name: 'b', typeArguments: null }, + { ...A, isOptional: false }, + { ...B, isOptional: false }, + { ...C, isOptional: false }, ]); }); it('should handle a mix [non-empty, empty, non-empty]', () => { - const inputs: Array = [ - { type: nonEmptyType.typeId, name: 'a', typeArguments: null }, - { type: emptyAbiType.typeId, name: 'b', typeArguments: null }, - { type: nonEmptyType.typeId, name: 'c', typeArguments: null }, - ]; + const A = { type: nonEmptyType.typeId, name: 'a', typeArguments: null }; + const B = { type: emptyAbiType.typeId, name: 'b', typeArguments: null }; + const C = { type: nonEmptyType.typeId, name: 'c', typeArguments: null }; + const inputs: Array = [A, B, C]; const result = getMandatoryInputs({ types, inputs }); - expect(result).toEqual(inputs); + expect(result).toEqual([ + { ...A, isOptional: false }, + { ...B, isOptional: false }, + { ...C, isOptional: false }, + ]); }); }); diff --git a/packages/abi-typegen/src/utils/getMandatoryInputs.ts b/packages/abi-typegen/src/utils/getMandatoryInputs.ts index a6dcded7491..f06f4264ade 100644 --- a/packages/abi-typegen/src/utils/getMandatoryInputs.ts +++ b/packages/abi-typegen/src/utils/getMandatoryInputs.ts @@ -1,22 +1,39 @@ import { EmptyType } from '../abi/types/EmptyType'; +import { OptionType } from '../abi/types/OptionType'; import type { IType } from '../types/interfaces/IType'; import type { JsonAbiArgument } from '../types/interfaces/JsonAbi'; import { findType } from './findType'; +const OPTIONAL_INPUT_TYPES = [EmptyType.swayType, OptionType.swayType]; + +export type ArgumentWithMetadata = TArg & { + isOptional: boolean; +}; + export const getMandatoryInputs = ({ types, inputs, }: { types: IType[]; - inputs: readonly JsonAbiArgument[]; -}) => { - let i = inputs.length - 1; - for (; i >= 0; i--) { - const type = findType({ types, typeId: inputs[i].type }); - if (type.rawAbiType.type !== EmptyType.swayType) { - break; - } - } - return inputs.slice(0, i + 1); + inputs: JsonAbiArgument[]; +}): Array => { + let inMandatoryRegion = false; + + return inputs + .reverse() + .map((input) => { + if (inMandatoryRegion) { + return { ...input, isOptional: false }; + } + + const type = findType({ types, typeId: input.type }); + if (OPTIONAL_INPUT_TYPES.includes(type.rawAbiType.type)) { + return { ...input, isOptional: true }; + } + + inMandatoryRegion = true; + return { ...input, isOptional: false }; + }) + .reverse(); }; From 6144e9eddb5622f68045e9e95f9acfd55b5bf315 Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Wed, 24 Jul 2024 07:28:15 +0100 Subject: [PATCH 15/43] chore: added Option ABI type testing --- .../src/utils/getMandatoryInputs.test.ts | 187 ++++++++++-------- 1 file changed, 101 insertions(+), 86 deletions(-) diff --git a/packages/abi-typegen/src/utils/getMandatoryInputs.test.ts b/packages/abi-typegen/src/utils/getMandatoryInputs.test.ts index e7d1d990207..a32734b2f02 100644 --- a/packages/abi-typegen/src/utils/getMandatoryInputs.test.ts +++ b/packages/abi-typegen/src/utils/getMandatoryInputs.test.ts @@ -11,98 +11,113 @@ const nonEmptyType: JsonAbiType = { typeParameters: null, }; -const emptyAbiType: JsonAbiType = { +const voidAbiType: JsonAbiType = { type: '()', typeId: 2, components: null, typeParameters: null, }; -const types: Array = [nonEmptyType, emptyAbiType].map((rawAbiType) => +const optionAbiType: JsonAbiType = { + type: 'enum Option', + typeId: 3, + components: null, + typeParameters: null, +}; + +const EMPTY_ABI_TYPES: [string, JsonAbiType][] = [ + ['void', voidAbiType], + ['option', optionAbiType], +]; + +const types: Array = [nonEmptyType, voidAbiType, optionAbiType].map((rawAbiType) => makeType({ rawAbiType }) ); -describe('getMandatoryInputs.ts', () => { - it('should handle no inputs', () => { - const inputs: Array = []; - - const result = getMandatoryInputs({ types, inputs }); - - expect(result).toEqual([]); - }); - - it('should handle all empty types [empty, empty, empty]', () => { - const A = { type: emptyAbiType.typeId, name: 'a', typeArguments: null }; - const B = { type: emptyAbiType.typeId, name: 'b', typeArguments: null }; - const C = { type: emptyAbiType.typeId, name: 'c', typeArguments: null }; - const inputs: Array = [A, B, C]; - - const result = getMandatoryInputs({ types, inputs }); - - expect(result).toEqual([ - { ...A, isOptional: true }, - { ...B, isOptional: true }, - { ...C, isOptional: true }, - ]); - }); - - it('should handle all non-empty types', () => { - const A = { type: nonEmptyType.typeId, name: 'a', typeArguments: null }; - const B = { type: nonEmptyType.typeId, name: 'b', typeArguments: null }; - const C = { type: nonEmptyType.typeId, name: 'c', typeArguments: null }; - const inputs: Array = [A, B, C]; - - const result = getMandatoryInputs({ types, inputs }); - - expect(result).toEqual([ - { ...A, isOptional: false }, - { ...B, isOptional: false }, - { ...C, isOptional: false }, - ]); - }); - - it('should handle a mix [non-empty, non-empty, empty]', () => { - const A = { type: nonEmptyType.typeId, name: 'a', typeArguments: null }; - const B = { type: nonEmptyType.typeId, name: 'b', typeArguments: null }; - const C = { type: emptyAbiType.typeId, name: 'c', typeArguments: null }; - const inputs: Array = [A, B, C]; - - const result = getMandatoryInputs({ types, inputs }); - - expect(result).toEqual([ - { ...A, isOptional: false }, - { ...B, isOptional: false }, - { ...C, isOptional: true }, - ]); - }); - - it('should handle a mix [empty, non-empty, non-empty]', () => { - const A = { type: emptyAbiType.typeId, name: 'a', typeArguments: null }; - const B = { type: nonEmptyType.typeId, name: 'b', typeArguments: null }; - const C = { type: nonEmptyType.typeId, name: 'c', typeArguments: null }; - const inputs: Array = [A, B, C]; - - const result = getMandatoryInputs({ types, inputs }); - - expect(result).toEqual([ - { ...A, isOptional: false }, - { ...B, isOptional: false }, - { ...C, isOptional: false }, - ]); - }); - - it('should handle a mix [non-empty, empty, non-empty]', () => { - const A = { type: nonEmptyType.typeId, name: 'a', typeArguments: null }; - const B = { type: emptyAbiType.typeId, name: 'b', typeArguments: null }; - const C = { type: nonEmptyType.typeId, name: 'c', typeArguments: null }; - const inputs: Array = [A, B, C]; - - const result = getMandatoryInputs({ types, inputs }); - - expect(result).toEqual([ - { ...A, isOptional: false }, - { ...B, isOptional: false }, - { ...C, isOptional: false }, - ]); - }); -}); +describe.each(EMPTY_ABI_TYPES)( + 'getMandatoryInputs.ts [empty=%s]', + (_: string, emptyAbiType: JsonAbiType) => { + it('should handle no inputs', () => { + const inputs: Array = []; + + const result = getMandatoryInputs({ types, inputs }); + + expect(result).toEqual([]); + }); + + it('should handle all empty types [empty, empty, empty]', () => { + const A = { type: emptyAbiType.typeId, name: 'a', typeArguments: null }; + const B = { type: emptyAbiType.typeId, name: 'b', typeArguments: null }; + const C = { type: emptyAbiType.typeId, name: 'c', typeArguments: null }; + const inputs: Array = [A, B, C]; + + const result = getMandatoryInputs({ types, inputs }); + + expect(result).toEqual([ + { ...A, isOptional: true }, + { ...B, isOptional: true }, + { ...C, isOptional: true }, + ]); + }); + + it('should handle all non-empty types', () => { + const A = { type: nonEmptyType.typeId, name: 'a', typeArguments: null }; + const B = { type: nonEmptyType.typeId, name: 'b', typeArguments: null }; + const C = { type: nonEmptyType.typeId, name: 'c', typeArguments: null }; + const inputs: Array = [A, B, C]; + + const result = getMandatoryInputs({ types, inputs }); + + expect(result).toEqual([ + { ...A, isOptional: false }, + { ...B, isOptional: false }, + { ...C, isOptional: false }, + ]); + }); + + it('should handle a mix [non-empty, non-empty, empty]', () => { + const A = { type: nonEmptyType.typeId, name: 'a', typeArguments: null }; + const B = { type: nonEmptyType.typeId, name: 'b', typeArguments: null }; + const C = { type: emptyAbiType.typeId, name: 'c', typeArguments: null }; + const inputs: Array = [A, B, C]; + + const result = getMandatoryInputs({ types, inputs }); + + expect(result).toEqual([ + { ...A, isOptional: false }, + { ...B, isOptional: false }, + { ...C, isOptional: true }, + ]); + }); + + it('should handle a mix [empty, non-empty, non-empty]', () => { + const A = { type: emptyAbiType.typeId, name: 'a', typeArguments: null }; + const B = { type: nonEmptyType.typeId, name: 'b', typeArguments: null }; + const C = { type: nonEmptyType.typeId, name: 'c', typeArguments: null }; + const inputs: Array = [A, B, C]; + + const result = getMandatoryInputs({ types, inputs }); + + expect(result).toEqual([ + { ...A, isOptional: false }, + { ...B, isOptional: false }, + { ...C, isOptional: false }, + ]); + }); + + it('should handle a mix [non-empty, empty, non-empty]', () => { + const A = { type: nonEmptyType.typeId, name: 'a', typeArguments: null }; + const B = { type: emptyAbiType.typeId, name: 'b', typeArguments: null }; + const C = { type: nonEmptyType.typeId, name: 'c', typeArguments: null }; + const inputs: Array = [A, B, C]; + + const result = getMandatoryInputs({ types, inputs }); + + expect(result).toEqual([ + { ...A, isOptional: false }, + { ...B, isOptional: false }, + { ...C, isOptional: false }, + ]); + }); + } +); From 61484f57b51420298a1277af545943fd773b770b Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Wed, 24 Jul 2024 07:45:59 +0100 Subject: [PATCH 16/43] chore: added forcBuildFlag to test --- packages/abi-typegen/src/templates/contract/dts.test.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/abi-typegen/src/templates/contract/dts.test.ts b/packages/abi-typegen/src/templates/contract/dts.test.ts index 37311973429..10814b41565 100644 --- a/packages/abi-typegen/src/templates/contract/dts.test.ts +++ b/packages/abi-typegen/src/templates/contract/dts.test.ts @@ -14,7 +14,7 @@ import { renderDtsTemplate } from './dts'; * @group node */ describe('templates/dts', () => { - test.each(['debug', 'release'])('should render dts template', (build) => { + test.each(['debug', 'release'])('should render dts template [%s]', (build) => { // mocking const { restore } = mockVersions(); From d1a40a7c5044bf281fd5f5468f284716bf71e5eb Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Wed, 24 Jul 2024 08:32:16 +0100 Subject: [PATCH 17/43] feat: implemented option function parameters --- .../src/abi/functions/Function.test.ts | 2 +- .../abi-typegen/src/abi/functions/Function.ts | 5 +++-- .../src/utils/getMandatoryInputs.test.ts | 14 ++++++++++--- .../src/utils/getMandatoryInputs.ts | 21 ++++++++++--------- .../test/fixtures/templates/contract/dts.hbs | 10 ++++----- 5 files changed, 31 insertions(+), 21 deletions(-) diff --git a/packages/abi-typegen/src/abi/functions/Function.test.ts b/packages/abi-typegen/src/abi/functions/Function.test.ts index 8eaabb796c3..8270f48e981 100644 --- a/packages/abi-typegen/src/abi/functions/Function.test.ts +++ b/packages/abi-typegen/src/abi/functions/Function.test.ts @@ -63,6 +63,6 @@ describe('Function.ts', () => { expect(func.name).toEqual(rawAbiFunction.name); expect(func.attributes.inputs).toEqual('Option'); expect(func.attributes.output).toEqual('Option'); - expect(func.attributes.prefixedInputs).toEqual('x: Option'); + expect(func.attributes.prefixedInputs).toEqual('x?: Option'); }); }); diff --git a/packages/abi-typegen/src/abi/functions/Function.ts b/packages/abi-typegen/src/abi/functions/Function.ts index 4edaeabee71..613fe085472 100644 --- a/packages/abi-typegen/src/abi/functions/Function.ts +++ b/packages/abi-typegen/src/abi/functions/Function.ts @@ -28,12 +28,13 @@ export class Function implements IFunction { // loop through all mandatory inputs const inputs = getMandatoryInputs({ types, inputs: this.rawAbiFunction.inputs }).map( - (input) => { + ({ isOptional, ...input }) => { const { name, type: typeId, typeArguments } = input; const type = findType({ types, typeId }); let typeDecl: string; + const optionalSuffix = isOptional ? '?' : ''; if (typeArguments) { // recursively process child `typeArguments` @@ -50,7 +51,7 @@ export class Function implements IFunction { // assemble it in `[key: string]: ` fashion if (shouldPrefixParams) { - return `${name}: ${typeDecl}`; + return `${name}${optionalSuffix}: ${typeDecl}`; } return typeDecl; diff --git a/packages/abi-typegen/src/utils/getMandatoryInputs.test.ts b/packages/abi-typegen/src/utils/getMandatoryInputs.test.ts index a32734b2f02..f46158fb20f 100644 --- a/packages/abi-typegen/src/utils/getMandatoryInputs.test.ts +++ b/packages/abi-typegen/src/utils/getMandatoryInputs.test.ts @@ -25,13 +25,21 @@ const optionAbiType: JsonAbiType = { typeParameters: null, }; +const debugOptionAbiType: JsonAbiType = { + type: 'enum std::option::Option', + typeId: 4, + components: null, + typeParameters: null, +}; + const EMPTY_ABI_TYPES: [string, JsonAbiType][] = [ ['void', voidAbiType], - ['option', optionAbiType], + ['option (release)', optionAbiType], + ['option (debug)', debugOptionAbiType], ]; -const types: Array = [nonEmptyType, voidAbiType, optionAbiType].map((rawAbiType) => - makeType({ rawAbiType }) +const types: Array = [nonEmptyType, voidAbiType, optionAbiType, debugOptionAbiType].map( + (rawAbiType) => makeType({ rawAbiType }) ); describe.each(EMPTY_ABI_TYPES)( diff --git a/packages/abi-typegen/src/utils/getMandatoryInputs.ts b/packages/abi-typegen/src/utils/getMandatoryInputs.ts index f06f4264ade..6ba53940197 100644 --- a/packages/abi-typegen/src/utils/getMandatoryInputs.ts +++ b/packages/abi-typegen/src/utils/getMandatoryInputs.ts @@ -1,3 +1,5 @@ +import { clone } from 'ramda'; + import { EmptyType } from '../abi/types/EmptyType'; import { OptionType } from '../abi/types/OptionType'; import type { IType } from '../types/interfaces/IType'; @@ -5,30 +7,29 @@ import type { JsonAbiArgument } from '../types/interfaces/JsonAbi'; import { findType } from './findType'; -const OPTIONAL_INPUT_TYPES = [EmptyType.swayType, OptionType.swayType]; - export type ArgumentWithMetadata = TArg & { isOptional: boolean; }; -export const getMandatoryInputs = ({ - types, - inputs, -}: { +export const getMandatoryInputs = (params: { types: IType[]; - inputs: JsonAbiArgument[]; + inputs: readonly JsonAbiArgument[]; }): Array => { let inMandatoryRegion = false; + const inputs = clone(params.inputs); - return inputs + return (inputs as Array) .reverse() .map((input) => { if (inMandatoryRegion) { return { ...input, isOptional: false }; } - const type = findType({ types, typeId: input.type }); - if (OPTIONAL_INPUT_TYPES.includes(type.rawAbiType.type)) { + const type = findType({ types: params.types, typeId: input.type }); + if ( + EmptyType.isSuitableFor({ type: type.rawAbiType.type }) || + OptionType.isSuitableFor({ type: type.rawAbiType.type }) + ) { return { ...input, isOptional: true }; } diff --git a/packages/abi-typegen/test/fixtures/templates/contract/dts.hbs b/packages/abi-typegen/test/fixtures/templates/contract/dts.hbs index 2974f056d7c..920183c8c70 100644 --- a/packages/abi-typegen/test/fixtures/templates/contract/dts.hbs +++ b/packages/abi-typegen/test/fixtures/templates/contract/dts.hbs @@ -110,15 +110,15 @@ export class MyContractAbi extends Contract { types_b512: InvokeFunction<[x: string], string>; types_bool: InvokeFunction<[x: boolean], boolean>; types_bytes: InvokeFunction<[x: Bytes], Bytes>; - types_empty: InvokeFunction<[], undefined>; + types_empty: InvokeFunction<[x?: undefined], undefined>; types_empty_then_value: InvokeFunction<[x: undefined, y: BigNumberish], undefined>; types_enum: InvokeFunction<[x: MyEnumInput], MyEnumOutput>; types_enum_with_vector: InvokeFunction<[x: EnumWithVectorInput], EnumWithVectorOutput>; types_evm_address: InvokeFunction<[x: EvmAddress], EvmAddress>; types_generic_enum: InvokeFunction<[x: GenericEnumInput], GenericEnumOutput>; types_generic_struct: InvokeFunction<[x: GenericStructWithEnumInput], GenericStructWithEnumOutput>; - types_option: InvokeFunction<[x: Option], Option>; - types_option_geo: InvokeFunction<[x: Option], Option>; + types_option: InvokeFunction<[x?: Option], Option>; + types_option_geo: InvokeFunction<[x?: Option], Option>; types_raw_slice: InvokeFunction<[x: RawSlice], RawSlice>; types_result: InvokeFunction<[x: Result], Result>; types_std_string: InvokeFunction<[x: StdString], StdString>; @@ -131,9 +131,9 @@ export class MyContractAbi extends Contract { types_u32: InvokeFunction<[x: BigNumberish], number>; types_u64: InvokeFunction<[x: BigNumberish], BN>; types_u8: InvokeFunction<[x: BigNumberish], number>; - types_value_then_empty: InvokeFunction<[x: BigNumberish], undefined>; + types_value_then_empty: InvokeFunction<[x: BigNumberish, y?: undefined], undefined>; types_value_then_empty_then_value: InvokeFunction<[x: BigNumberish, y: undefined, z: BigNumberish], undefined>; - types_value_then_value_then_empty_then_empty: InvokeFunction<[x: BigNumberish, y: BigNumberish], undefined>; + types_value_then_value_then_empty_then_empty: InvokeFunction<[x: BigNumberish, y: BigNumberish, z?: undefined, a?: undefined], undefined>; types_vector_geo: InvokeFunction<[x: Vec], Vec>; types_vector_option: InvokeFunction<[x: Vec], Vec>; types_vector_u8: InvokeFunction<[x: Vec], Vec>; From beae16fbae82d8c1ad77eb20fa4cef727335e5d0 Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Wed, 24 Jul 2024 10:07:53 +0100 Subject: [PATCH 18/43] chore: removed optional arguments from tests --- apps/docs-snippets/src/guide/types/options.test.ts | 2 +- packages/fuel-gauge/src/call-test-contract.test.ts | 5 ++--- packages/fuel-gauge/src/coverage-contract.test.ts | 11 +++-------- packages/fuel-gauge/src/fee.test.ts | 2 +- 4 files changed, 7 insertions(+), 13 deletions(-) diff --git a/apps/docs-snippets/src/guide/types/options.test.ts b/apps/docs-snippets/src/guide/types/options.test.ts index 61014dd71d9..e91a66fc1d2 100644 --- a/apps/docs-snippets/src/guide/types/options.test.ts +++ b/apps/docs-snippets/src/guide/types/options.test.ts @@ -42,7 +42,7 @@ describe(__filename, () => { // #region options-4 const input: number | undefined = 5; - const { value } = await contract.functions.sum_optional_u8(input, undefined).simulate(); + const { value } = await contract.functions.sum_optional_u8(input).simulate(); expect(value).toEqual(input); // #endregion options-4 diff --git a/packages/fuel-gauge/src/call-test-contract.test.ts b/packages/fuel-gauge/src/call-test-contract.test.ts index 7f877070555..6466ae154d6 100644 --- a/packages/fuel-gauge/src/call-test-contract.test.ts +++ b/packages/fuel-gauge/src/call-test-contract.test.ts @@ -42,7 +42,7 @@ describe('CallTestContract', () => { it('can call a function with empty arguments', async () => { using contract = await setupContract(); - const call1 = await contract.functions.empty(undefined).call(); + const call1 = await contract.functions.empty().call(); const { value: empty } = await call1.waitForResult(); expect(empty.toHex()).toEqual(toHex(63)); @@ -50,12 +50,11 @@ describe('CallTestContract', () => { const { value: emptyThenValue } = await call2.waitForResult(); expect(emptyThenValue.toHex()).toEqual(toHex(63)); - const call3 = await contract.functions.value_then_empty(35, undefined).call(); + const call3 = await contract.functions.value_then_empty(35).call(); const { value: valueThenEmpty } = await call3.waitForResult(); expect(valueThenEmpty.toHex()).toEqual(toHex(63)); const call4 = await contract.functions.value_then_empty_then_value(35, undefined, 35).call(); - const { value: valueThenEmptyThenValue } = await call4.waitForResult(); expect(valueThenEmptyThenValue.toHex()).toEqual(toHex(63)); }); diff --git a/packages/fuel-gauge/src/coverage-contract.test.ts b/packages/fuel-gauge/src/coverage-contract.test.ts index 3e54ecf7412..c60ff051136 100644 --- a/packages/fuel-gauge/src/coverage-contract.test.ts +++ b/packages/fuel-gauge/src/coverage-contract.test.ts @@ -355,16 +355,13 @@ describe('Coverage Contract', () => { using contractInstance = await setupContract(); const INPUT_NONE = undefined; - const call1 = await contractInstance.functions.echo_option_extract_u32(INPUT_NONE).call(); + const call1 = await contractInstance.functions.echo_option_extract_u32(INPUT_NONE).call(); const { value: None } = await call1.waitForResult(); - expect(None).toStrictEqual(500); - const call2 = await contractInstance.functions.echo_option_extract_u32(undefined).call(); - + const call2 = await contractInstance.functions.echo_option_extract_u32().call(); const { value: NoneVoid } = await call2.waitForResult(); - expect(NoneVoid).toStrictEqual(500); }); @@ -392,9 +389,7 @@ describe('Coverage Contract', () => { const INPUT = 1; // adds the three values together, but only first param value is supplied - const { waitForResult } = await contractInstance.functions - .echo_option_three_u8(INPUT, undefined, undefined) - .call(); + const { waitForResult } = await contractInstance.functions.echo_option_three_u8(INPUT).call(); const { value: Some } = await waitForResult(); // we receive the result of adding whatever was passed diff --git a/packages/fuel-gauge/src/fee.test.ts b/packages/fuel-gauge/src/fee.test.ts index faea2d0b3b6..db875abb072 100644 --- a/packages/fuel-gauge/src/fee.test.ts +++ b/packages/fuel-gauge/src/fee.test.ts @@ -242,7 +242,7 @@ describe('Fee', () => { const scope = contract.multiCall([ contract.functions.sum_multparams(1, 2, 3, 4, 5), contract.functions.return_void(), - contract.functions.empty(undefined), + contract.functions.empty(), contract.functions.return_bytes(), ]); From b3d704821f90640105688c2888259693938bfbf0 Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Wed, 24 Jul 2024 10:14:31 +0100 Subject: [PATCH 19/43] chore: made void return type for EmptyType --- packages/abi-typegen/src/abi/types/EmptyType.test.ts | 2 +- packages/abi-typegen/src/abi/types/EmptyType.ts | 6 ++---- .../abi-typegen/src/utils/parseTypeArguments.test.ts | 2 +- .../test/fixtures/templates/contract/dts.hbs | 10 +++++----- 4 files changed, 9 insertions(+), 11 deletions(-) diff --git a/packages/abi-typegen/src/abi/types/EmptyType.test.ts b/packages/abi-typegen/src/abi/types/EmptyType.test.ts index dcf80963be9..ea2ea15c7a9 100644 --- a/packages/abi-typegen/src/abi/types/EmptyType.test.ts +++ b/packages/abi-typegen/src/abi/types/EmptyType.test.ts @@ -15,6 +15,6 @@ describe('EmptyType.ts', () => { }); expect(emptyType.attributes.inputLabel).toEqual('undefined'); - expect(emptyType.attributes.outputLabel).toEqual('undefined'); + expect(emptyType.attributes.outputLabel).toEqual('void'); }); }); diff --git a/packages/abi-typegen/src/abi/types/EmptyType.ts b/packages/abi-typegen/src/abi/types/EmptyType.ts index cb0991db33d..37e1b59899c 100644 --- a/packages/abi-typegen/src/abi/types/EmptyType.ts +++ b/packages/abi-typegen/src/abi/types/EmptyType.ts @@ -10,13 +10,11 @@ export class EmptyType extends AType implements IType { static MATCH_REGEX: RegExp = /^\(\)$/m; - static TYPE_LABEL: string = 'undefined'; - constructor(params: { rawAbiType: JsonAbiType }) { super(params); this.attributes = { - inputLabel: EmptyType.TYPE_LABEL, - outputLabel: EmptyType.TYPE_LABEL, + inputLabel: 'undefined', + outputLabel: 'void', }; } diff --git a/packages/abi-typegen/src/utils/parseTypeArguments.test.ts b/packages/abi-typegen/src/utils/parseTypeArguments.test.ts index 610dcd7e96f..dbb7b115f82 100644 --- a/packages/abi-typegen/src/utils/parseTypeArguments.test.ts +++ b/packages/abi-typegen/src/utils/parseTypeArguments.test.ts @@ -114,6 +114,6 @@ describe('parseTypeArguments.ts', () => { // should fallback to void because `typeArguments.type` will be 0, and non-existent const asOutput = parseTypeArguments({ types, target: TargetEnum.OUTPUT, typeArguments }); - expect(asOutput).toEqual('undefined'); + expect(asOutput).toEqual('void'); }); }); diff --git a/packages/abi-typegen/test/fixtures/templates/contract/dts.hbs b/packages/abi-typegen/test/fixtures/templates/contract/dts.hbs index 920183c8c70..b19d45b7bfc 100644 --- a/packages/abi-typegen/test/fixtures/templates/contract/dts.hbs +++ b/packages/abi-typegen/test/fixtures/templates/contract/dts.hbs @@ -110,8 +110,8 @@ export class MyContractAbi extends Contract { types_b512: InvokeFunction<[x: string], string>; types_bool: InvokeFunction<[x: boolean], boolean>; types_bytes: InvokeFunction<[x: Bytes], Bytes>; - types_empty: InvokeFunction<[x?: undefined], undefined>; - types_empty_then_value: InvokeFunction<[x: undefined, y: BigNumberish], undefined>; + types_empty: InvokeFunction<[x?: undefined], void>; + types_empty_then_value: InvokeFunction<[x: undefined, y: BigNumberish], void>; types_enum: InvokeFunction<[x: MyEnumInput], MyEnumOutput>; types_enum_with_vector: InvokeFunction<[x: EnumWithVectorInput], EnumWithVectorOutput>; types_evm_address: InvokeFunction<[x: EvmAddress], EvmAddress>; @@ -131,9 +131,9 @@ export class MyContractAbi extends Contract { types_u32: InvokeFunction<[x: BigNumberish], number>; types_u64: InvokeFunction<[x: BigNumberish], BN>; types_u8: InvokeFunction<[x: BigNumberish], number>; - types_value_then_empty: InvokeFunction<[x: BigNumberish, y?: undefined], undefined>; - types_value_then_empty_then_value: InvokeFunction<[x: BigNumberish, y: undefined, z: BigNumberish], undefined>; - types_value_then_value_then_empty_then_empty: InvokeFunction<[x: BigNumberish, y: BigNumberish, z?: undefined, a?: undefined], undefined>; + types_value_then_empty: InvokeFunction<[x: BigNumberish, y?: undefined], void>; + types_value_then_empty_then_value: InvokeFunction<[x: BigNumberish, y: undefined, z: BigNumberish], void>; + types_value_then_value_then_empty_then_empty: InvokeFunction<[x: BigNumberish, y: BigNumberish, z?: undefined, a?: undefined], void>; types_vector_geo: InvokeFunction<[x: Vec], Vec>; types_vector_option: InvokeFunction<[x: Vec], Vec>; types_vector_u8: InvokeFunction<[x: Vec], Vec>; From e5cd92fc954df6ae230abb2ce334cf9ed9a475a3 Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Wed, 24 Jul 2024 10:14:46 +0100 Subject: [PATCH 20/43] chore: added missing test group --- packages/abi-typegen/src/utils/getMandatoryInputs.test.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/abi-typegen/src/utils/getMandatoryInputs.test.ts b/packages/abi-typegen/src/utils/getMandatoryInputs.test.ts index f46158fb20f..0b5ca81e981 100644 --- a/packages/abi-typegen/src/utils/getMandatoryInputs.test.ts +++ b/packages/abi-typegen/src/utils/getMandatoryInputs.test.ts @@ -42,6 +42,9 @@ const types: Array = [nonEmptyType, voidAbiType, optionAbiType, debugOpti (rawAbiType) => makeType({ rawAbiType }) ); +/** + * @group node + */ describe.each(EMPTY_ABI_TYPES)( 'getMandatoryInputs.ts [empty=%s]', (_: string, emptyAbiType: JsonAbiType) => { From 8361c3845d6674c2906878f4b05458931daef5fd Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Wed, 24 Jul 2024 11:33:08 +0100 Subject: [PATCH 21/43] deps: added `ramda` to `abi-coder` --- packages/abi-coder/package.json | 4 +++ pnpm-lock.yaml | 46 +++++++++++++++------------------ 2 files changed, 25 insertions(+), 25 deletions(-) diff --git a/packages/abi-coder/package.json b/packages/abi-coder/package.json index 16c55ee903b..279a34cb3f1 100644 --- a/packages/abi-coder/package.json +++ b/packages/abi-coder/package.json @@ -33,6 +33,10 @@ "@fuel-ts/interfaces": "workspace:*", "@fuel-ts/math": "workspace:*", "@fuel-ts/utils": "workspace:*", + "ramda": "^0.29.0", "type-fest": "^3.1.0" + }, + "devDependencies": { + "@types/ramda": "^0.29.3" } } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 083601e36f4..8f3b1a31ac8 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -616,9 +616,16 @@ importers: '@fuel-ts/utils': specifier: workspace:* version: link:../utils + ramda: + specifier: ^0.29.0 + version: 0.29.0 type-fest: specifier: ^3.1.0 version: 3.1.0 + devDependencies: + '@types/ramda': + specifier: ^0.29.3 + version: 0.29.3 packages/abi-typegen: dependencies: @@ -6550,7 +6557,6 @@ packages: bun@1.1.20: resolution: {integrity: sha512-aqLmvaz0/vLUiCrOXtAsf7pCSOS/qXieYDsq8COa3+fIgMK05CjZt9m9r7DC+tjKy7hH8uKSNTapQOr/kX8gIA==} - cpu: [arm64, x64] os: [darwin, linux, win32] hasBin: true @@ -20874,7 +20880,7 @@ snapshots: '@vitest/utils': 1.6.0 magic-string: 0.30.5 sirv: 2.0.4 - vitest: 1.6.0(@types/node@20.14.11)(@vitest/browser@1.6.0)(jsdom@16.7.0(bufferutil@4.0.8)(utf-8-validate@6.0.4))(terser@5.31.3) + vitest: 1.6.0(@types/node@18.15.3)(@vitest/browser@1.6.0)(jsdom@16.7.0(bufferutil@4.0.8)(utf-8-validate@6.0.4))(terser@5.31.3) optionalDependencies: playwright: 1.45.1 webdriverio: 8.39.1(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4) @@ -24242,8 +24248,8 @@ snapshots: '@typescript-eslint/parser': 6.9.1(eslint@8.54.0)(typescript@5.2.2) eslint: 8.54.0 eslint-import-resolver-node: 0.3.9 - eslint-import-resolver-typescript: 3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1)(eslint@8.54.0) - eslint-plugin-import: 2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint@8.54.0) + eslint-import-resolver-typescript: 3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint@8.54.0))(eslint@8.54.0) + eslint-plugin-import: 2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-typescript@3.6.1)(eslint@8.54.0) eslint-plugin-jsx-a11y: 6.9.0(eslint@8.54.0) eslint-plugin-react: 7.34.4(eslint@8.54.0) eslint-plugin-react-hooks: 4.6.2(eslint@8.54.0) @@ -24310,13 +24316,13 @@ snapshots: transitivePeerDependencies: - supports-color - eslint-import-resolver-typescript@3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1)(eslint@8.54.0): + eslint-import-resolver-typescript@3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint@8.54.0))(eslint@8.54.0): dependencies: debug: 4.3.5(supports-color@5.5.0) enhanced-resolve: 5.15.0 eslint: 8.54.0 - eslint-module-utils: 2.8.0(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1)(eslint@8.54.0))(eslint@8.54.0) - eslint-plugin-import: 2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint@8.54.0) + eslint-module-utils: 2.8.0(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint@8.54.0))(eslint@8.54.0))(eslint@8.54.0) + eslint-plugin-import: 2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-typescript@3.6.1)(eslint@8.54.0) fast-glob: 3.3.2 get-tsconfig: 4.7.5 is-core-module: 2.13.1 @@ -24354,14 +24360,14 @@ snapshots: transitivePeerDependencies: - supports-color - eslint-module-utils@2.8.0(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1)(eslint@8.54.0))(eslint@8.54.0): + eslint-module-utils@2.8.0(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint@8.54.0))(eslint@8.54.0))(eslint@8.54.0): dependencies: debug: 3.2.7 optionalDependencies: '@typescript-eslint/parser': 6.9.1(eslint@8.54.0)(typescript@5.2.2) eslint: 8.54.0 eslint-import-resolver-node: 0.3.9 - eslint-import-resolver-typescript: 3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1)(eslint@8.54.0) + eslint-import-resolver-typescript: 3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint@8.54.0))(eslint@8.54.0) transitivePeerDependencies: - supports-color @@ -24376,16 +24382,6 @@ snapshots: transitivePeerDependencies: - supports-color - eslint-module-utils@2.8.0(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint-import-resolver-node@0.3.9)(eslint@8.54.0): - dependencies: - debug: 3.2.7 - optionalDependencies: - '@typescript-eslint/parser': 6.9.1(eslint@8.57.0)(typescript@5.4.5) - eslint: 8.54.0 - eslint-import-resolver-node: 0.3.9 - transitivePeerDependencies: - - supports-color - eslint-module-utils@2.8.0(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint-import-resolver-node@0.3.9)(eslint@8.57.0): dependencies: debug: 3.2.7 @@ -24433,7 +24429,7 @@ snapshots: - eslint-import-resolver-webpack - supports-color - eslint-plugin-import@2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.4.5))(eslint-import-resolver-typescript@3.6.1)(eslint@8.54.0): + eslint-plugin-import@2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-typescript@3.6.1)(eslint@8.54.0): dependencies: array-includes: 3.1.7 array.prototype.findlastindex: 1.2.3 @@ -24443,7 +24439,7 @@ snapshots: doctrine: 2.1.0 eslint: 8.54.0 eslint-import-resolver-node: 0.3.9 - eslint-module-utils: 2.8.0(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.4.5))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.4.5))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1)(eslint@8.54.0))(eslint@8.54.0) + eslint-module-utils: 2.8.0(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint@8.54.0))(eslint@8.54.0))(eslint@8.54.0) hasown: 2.0.0 is-core-module: 2.13.1 is-glob: 4.0.3 @@ -24454,13 +24450,13 @@ snapshots: semver: 6.3.1 tsconfig-paths: 3.15.0 optionalDependencies: - '@typescript-eslint/parser': 6.9.1(eslint@8.54.0)(typescript@5.4.5) + '@typescript-eslint/parser': 6.9.1(eslint@8.54.0)(typescript@5.2.2) transitivePeerDependencies: - eslint-import-resolver-typescript - eslint-import-resolver-webpack - supports-color - eslint-plugin-import@2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint@8.54.0): + eslint-plugin-import@2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.4.5))(eslint-import-resolver-typescript@3.6.1)(eslint@8.54.0): dependencies: array-includes: 3.1.7 array.prototype.findlastindex: 1.2.3 @@ -24470,7 +24466,7 @@ snapshots: doctrine: 2.1.0 eslint: 8.54.0 eslint-import-resolver-node: 0.3.9 - eslint-module-utils: 2.8.0(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint-import-resolver-node@0.3.9)(eslint@8.54.0) + eslint-module-utils: 2.8.0(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.4.5))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.4.5))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1)(eslint@8.54.0))(eslint@8.54.0) hasown: 2.0.0 is-core-module: 2.13.1 is-glob: 4.0.3 @@ -24481,7 +24477,7 @@ snapshots: semver: 6.3.1 tsconfig-paths: 3.15.0 optionalDependencies: - '@typescript-eslint/parser': 6.9.1(eslint@8.57.0)(typescript@5.4.5) + '@typescript-eslint/parser': 6.9.1(eslint@8.54.0)(typescript@5.4.5) transitivePeerDependencies: - eslint-import-resolver-typescript - eslint-import-resolver-webpack From 7893de2fafb07f0d6f0532ac3da9bc2894a80404 Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Wed, 24 Jul 2024 11:34:23 +0100 Subject: [PATCH 22/43] chore: implemented optional parameters for coder --- packages/abi-coder/src/FunctionFragment.ts | 47 ++---- packages/abi-coder/src/utils/constants.ts | 1 + .../src/utils/getMandatoryInputs.test.ts | 137 ++++++++++++++++++ .../abi-coder/src/utils/getMandatoryInputs.ts | 35 +++++ 4 files changed, 189 insertions(+), 31 deletions(-) create mode 100644 packages/abi-coder/src/utils/getMandatoryInputs.test.ts create mode 100644 packages/abi-coder/src/utils/getMandatoryInputs.ts diff --git a/packages/abi-coder/src/FunctionFragment.ts b/packages/abi-coder/src/FunctionFragment.ts index 35dd5a21ed9..296ac70d775 100644 --- a/packages/abi-coder/src/FunctionFragment.ts +++ b/packages/abi-coder/src/FunctionFragment.ts @@ -18,6 +18,7 @@ import type { } from './types/JsonAbi'; import type { EncodingVersion } from './utils/constants'; import { OPTION_CODER_TYPE, VOID_TYPE } from './utils/constants'; +import { getMandatoryInputs } from './utils/getMandatoryInputs'; import { findFunctionByName, findNonEmptyInputs, @@ -66,7 +67,21 @@ export class FunctionFragment< } encodeArguments(values: InputValue[]): Uint8Array { - FunctionFragment.verifyArgsAndInputsAlign(values, this.jsonFn.inputs, this.jsonAbi); + const inputs = getMandatoryInputs({ jsonAbi: this.jsonAbi, inputs: this.jsonFn.inputs }); + const mandatoryInputLength = inputs.filter((i) => !i.isOptional).length; + + if (values.length < mandatoryInputLength) { + throw new FuelError( + ErrorCode.ABI_TYPES_AND_VALUES_MISMATCH, + `Invalid number of arguments. Expected a minimum of ${mandatoryInputLength} arguments, received ${values.length}` + ); + } + + const shallowCopyValues = values.slice(); + if (Array.isArray(values) && this.jsonFn.inputs.length > values.length) { + shallowCopyValues.length = this.jsonFn.inputs.length; + shallowCopyValues.fill(undefined as unknown as InputValue, values.length); + } const coders = this.jsonFn.inputs.map((t) => AbiCoder.getCoder(this.jsonAbi, t, { @@ -74,39 +89,9 @@ export class FunctionFragment< }) ); - const shallowCopyValues = values.slice(); return new TupleCoder(coders).encode(shallowCopyValues); } - private static verifyArgsAndInputsAlign( - args: InputValue[], - inputs: readonly JsonAbiArgument[], - abi: JsonAbi - ) { - if (args.length === inputs.length) { - return; - } - - const inputTypes = inputs.map((input) => findTypeById(abi, input.type)); - const optionalInputs = inputTypes.filter( - (x) => x.type === OPTION_CODER_TYPE || x.type === VOID_TYPE - ); - if (optionalInputs.length === inputTypes.length) { - return; - } - if (inputTypes.length - optionalInputs.length === args.length) { - return; - } - - const errorMsg = `Mismatch between provided arguments and expected ABI inputs. Provided ${ - args.length - } arguments, but expected ${inputs.length - optionalInputs.length} (excluding ${ - optionalInputs.length - } optional inputs).`; - - throw new FuelError(ErrorCode.ABI_TYPES_AND_VALUES_MISMATCH, errorMsg); - } - decodeArguments(data: BytesLike) { const bytes = arrayify(data); const nonEmptyInputs = findNonEmptyInputs(this.jsonAbi, this.jsonFn.inputs); diff --git a/packages/abi-coder/src/utils/constants.ts b/packages/abi-coder/src/utils/constants.ts index 25aab229a57..7deac9d7785 100644 --- a/packages/abi-coder/src/utils/constants.ts +++ b/packages/abi-coder/src/utils/constants.ts @@ -17,6 +17,7 @@ export const BYTES_CODER_TYPE = 'struct Bytes'; export const STD_STRING_CODER_TYPE = 'struct String'; export const STR_SLICE_CODER_TYPE = 'str'; export const VOID_TYPE = '()'; +export const OPTION_REGEX: RegExp = /^enum (std::option::)?Option$/m; export const stringRegEx = /str\[(?[0-9]+)\]/; export const arrayRegEx = /\[(?[\w\s\\[\]]+);\s*(?[0-9]+)\]/; export const structRegEx = /^struct (?\w+)$/; diff --git a/packages/abi-coder/src/utils/getMandatoryInputs.test.ts b/packages/abi-coder/src/utils/getMandatoryInputs.test.ts new file mode 100644 index 00000000000..3e7392ab9ff --- /dev/null +++ b/packages/abi-coder/src/utils/getMandatoryInputs.test.ts @@ -0,0 +1,137 @@ +import type { JsonAbi, JsonAbiArgument, JsonAbiType } from '../types/JsonAbi'; + +import { getMandatoryInputs } from './getMandatoryInputs'; + +const nonEmptyType: JsonAbiType = { + type: 'u8', + typeId: 1, + components: null, + typeParameters: null, +}; + +const voidAbiType: JsonAbiType = { + type: '()', + typeId: 2, + components: null, + typeParameters: null, +}; + +const optionAbiType: JsonAbiType = { + type: 'enum Option', + typeId: 3, + components: null, + typeParameters: null, +}; + +const debugOptionAbiType: JsonAbiType = { + type: 'enum std::option::Option', + typeId: 4, + components: null, + typeParameters: null, +}; + +const EMPTY_ABI_TYPES: [string, JsonAbiType][] = [ + ['void', voidAbiType], + ['option (release)', optionAbiType], + ['option (debug)', debugOptionAbiType], +]; + +const jsonAbi: JsonAbi = { + encoding: '1', + types: [nonEmptyType, voidAbiType, optionAbiType, debugOptionAbiType], + functions: [], + loggedTypes: [], + messagesTypes: [], + configurables: [], +}; + +/** + * @group node + */ +describe.each(EMPTY_ABI_TYPES)( + 'getMandatoryInputs.ts [empty=%s]', + (_: string, emptyAbiType: JsonAbiType) => { + it('should handle no inputs', () => { + const inputs: Array = []; + + const result = getMandatoryInputs({ jsonAbi, inputs }); + + expect(result).toEqual([]); + }); + + it('should handle all empty types [empty, empty, empty]', () => { + const A = { type: emptyAbiType.typeId, name: 'a', typeArguments: null }; + const B = { type: emptyAbiType.typeId, name: 'b', typeArguments: null }; + const C = { type: emptyAbiType.typeId, name: 'c', typeArguments: null }; + const inputs: Array = [A, B, C]; + + const result = getMandatoryInputs({ jsonAbi, inputs }); + + expect(result).toEqual([ + { ...A, isOptional: true }, + { ...B, isOptional: true }, + { ...C, isOptional: true }, + ]); + }); + + it('should handle all non-empty types', () => { + const A = { type: nonEmptyType.typeId, name: 'a', typeArguments: null }; + const B = { type: nonEmptyType.typeId, name: 'b', typeArguments: null }; + const C = { type: nonEmptyType.typeId, name: 'c', typeArguments: null }; + const inputs: Array = [A, B, C]; + + const result = getMandatoryInputs({ jsonAbi, inputs }); + + expect(result).toEqual([ + { ...A, isOptional: false }, + { ...B, isOptional: false }, + { ...C, isOptional: false }, + ]); + }); + + it('should handle a mix [non-empty, non-empty, empty]', () => { + const A = { type: nonEmptyType.typeId, name: 'a', typeArguments: null }; + const B = { type: nonEmptyType.typeId, name: 'b', typeArguments: null }; + const C = { type: emptyAbiType.typeId, name: 'c', typeArguments: null }; + const inputs: Array = [A, B, C]; + + const result = getMandatoryInputs({ jsonAbi, inputs }); + + expect(result).toEqual([ + { ...A, isOptional: false }, + { ...B, isOptional: false }, + { ...C, isOptional: true }, + ]); + }); + + it('should handle a mix [empty, non-empty, non-empty]', () => { + const A = { type: emptyAbiType.typeId, name: 'a', typeArguments: null }; + const B = { type: nonEmptyType.typeId, name: 'b', typeArguments: null }; + const C = { type: nonEmptyType.typeId, name: 'c', typeArguments: null }; + const inputs: Array = [A, B, C]; + + const result = getMandatoryInputs({ jsonAbi, inputs }); + + expect(result).toEqual([ + { ...A, isOptional: false }, + { ...B, isOptional: false }, + { ...C, isOptional: false }, + ]); + }); + + it('should handle a mix [non-empty, empty, non-empty]', () => { + const A = { type: nonEmptyType.typeId, name: 'a', typeArguments: null }; + const B = { type: emptyAbiType.typeId, name: 'b', typeArguments: null }; + const C = { type: nonEmptyType.typeId, name: 'c', typeArguments: null }; + const inputs: Array = [A, B, C]; + + const result = getMandatoryInputs({ jsonAbi, inputs }); + + expect(result).toEqual([ + { ...A, isOptional: false }, + { ...B, isOptional: false }, + { ...C, isOptional: false }, + ]); + }); + } +); diff --git a/packages/abi-coder/src/utils/getMandatoryInputs.ts b/packages/abi-coder/src/utils/getMandatoryInputs.ts new file mode 100644 index 00000000000..a878a83a9ad --- /dev/null +++ b/packages/abi-coder/src/utils/getMandatoryInputs.ts @@ -0,0 +1,35 @@ +import { clone } from 'ramda'; + +import type { JsonAbi, JsonAbiArgument } from '../types/JsonAbi'; + +import { OPTION_REGEX, VOID_TYPE } from './constants'; +import { findTypeById } from './json-abi'; + +export type ArgumentWithMetadata = TArg & { + isOptional: boolean; +}; + +export const getMandatoryInputs = (params: { + jsonAbi: JsonAbi; + inputs: readonly JsonAbiArgument[]; +}): Array => { + let inMandatoryRegion = false; + const inputs = clone(params.inputs); + + return (inputs as Array) + .reverse() + .map((input) => { + if (inMandatoryRegion) { + return { ...input, isOptional: false }; + } + + const type = findTypeById(params.jsonAbi, input.type); + if (type.type === VOID_TYPE || type.type.match(OPTION_REGEX)) { + return { ...input, isOptional: true }; + } + + inMandatoryRegion = true; + return { ...input, isOptional: false }; + }) + .reverse(); +}; From 859c8748dc1e2afae3e3d50b1ecc1d9b904173ed Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Wed, 24 Jul 2024 11:56:11 +0100 Subject: [PATCH 23/43] chore: fixing lock file --- pnpm-lock.yaml | 38 ++++++++++++++++++++++++-------------- 1 file changed, 24 insertions(+), 14 deletions(-) diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 374db9d0a0b..97f521a24c5 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -20816,7 +20816,7 @@ snapshots: '@vitest/utils': 1.6.0 magic-string: 0.30.5 sirv: 2.0.4 - vitest: 1.6.0(@types/node@18.15.3)(@vitest/browser@1.6.0)(jsdom@16.7.0(bufferutil@4.0.8)(utf-8-validate@6.0.4))(terser@5.31.3) + vitest: 1.6.0(@types/node@20.14.11)(@vitest/browser@1.6.0)(jsdom@16.7.0(bufferutil@4.0.8)(utf-8-validate@6.0.4))(terser@5.31.3) optionalDependencies: playwright: 1.45.3 webdriverio: 8.39.1(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4) @@ -24160,8 +24160,8 @@ snapshots: '@typescript-eslint/parser': 6.9.1(eslint@8.54.0)(typescript@5.2.2) eslint: 8.54.0 eslint-import-resolver-node: 0.3.9 - eslint-import-resolver-typescript: 3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint@8.54.0))(eslint@8.54.0) - eslint-plugin-import: 2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-typescript@3.6.1)(eslint@8.54.0) + eslint-import-resolver-typescript: 3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1)(eslint@8.54.0) + eslint-plugin-import: 2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint@8.54.0) eslint-plugin-jsx-a11y: 6.9.0(eslint@8.54.0) eslint-plugin-react: 7.35.0(eslint@8.54.0) eslint-plugin-react-hooks: 4.6.2(eslint@8.54.0) @@ -24228,13 +24228,13 @@ snapshots: transitivePeerDependencies: - supports-color - eslint-import-resolver-typescript@3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint@8.54.0))(eslint@8.54.0): + eslint-import-resolver-typescript@3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1)(eslint@8.54.0): dependencies: debug: 4.3.5(supports-color@5.5.0) enhanced-resolve: 5.15.0 eslint: 8.54.0 - eslint-module-utils: 2.8.0(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint@8.54.0))(eslint@8.54.0))(eslint@8.54.0) - eslint-plugin-import: 2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-typescript@3.6.1)(eslint@8.54.0) + eslint-module-utils: 2.8.0(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1)(eslint@8.54.0))(eslint@8.54.0) + eslint-plugin-import: 2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint@8.54.0) fast-glob: 3.3.2 get-tsconfig: 4.7.5 is-core-module: 2.13.1 @@ -24272,14 +24272,14 @@ snapshots: transitivePeerDependencies: - supports-color - eslint-module-utils@2.8.0(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint@8.54.0))(eslint@8.54.0))(eslint@8.54.0): + eslint-module-utils@2.8.0(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1)(eslint@8.54.0))(eslint@8.54.0): dependencies: debug: 3.2.7 optionalDependencies: '@typescript-eslint/parser': 6.9.1(eslint@8.54.0)(typescript@5.2.2) eslint: 8.54.0 eslint-import-resolver-node: 0.3.9 - eslint-import-resolver-typescript: 3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint@8.54.0))(eslint@8.54.0) + eslint-import-resolver-typescript: 3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1)(eslint@8.54.0) transitivePeerDependencies: - supports-color @@ -24294,6 +24294,16 @@ snapshots: transitivePeerDependencies: - supports-color + eslint-module-utils@2.8.0(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint-import-resolver-node@0.3.9)(eslint@8.54.0): + dependencies: + debug: 3.2.7 + optionalDependencies: + '@typescript-eslint/parser': 6.9.1(eslint@8.57.0)(typescript@5.4.5) + eslint: 8.54.0 + eslint-import-resolver-node: 0.3.9 + transitivePeerDependencies: + - supports-color + eslint-module-utils@2.8.0(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint-import-resolver-node@0.3.9)(eslint@8.57.0): dependencies: debug: 3.2.7 @@ -24341,7 +24351,7 @@ snapshots: - eslint-import-resolver-webpack - supports-color - eslint-plugin-import@2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-typescript@3.6.1)(eslint@8.54.0): + eslint-plugin-import@2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.4.5))(eslint-import-resolver-typescript@3.6.1)(eslint@8.54.0): dependencies: array-includes: 3.1.7 array.prototype.findlastindex: 1.2.3 @@ -24351,7 +24361,7 @@ snapshots: doctrine: 2.1.0 eslint: 8.54.0 eslint-import-resolver-node: 0.3.9 - eslint-module-utils: 2.8.0(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.2.2))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint@8.54.0))(eslint@8.54.0))(eslint@8.54.0) + eslint-module-utils: 2.8.0(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.4.5))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.4.5))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1)(eslint@8.54.0))(eslint@8.54.0) hasown: 2.0.0 is-core-module: 2.13.1 is-glob: 4.0.3 @@ -24362,13 +24372,13 @@ snapshots: semver: 6.3.1 tsconfig-paths: 3.15.0 optionalDependencies: - '@typescript-eslint/parser': 6.9.1(eslint@8.54.0)(typescript@5.2.2) + '@typescript-eslint/parser': 6.9.1(eslint@8.54.0)(typescript@5.4.5) transitivePeerDependencies: - eslint-import-resolver-typescript - eslint-import-resolver-webpack - supports-color - eslint-plugin-import@2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.4.5))(eslint-import-resolver-typescript@3.6.1)(eslint@8.54.0): + eslint-plugin-import@2.29.1(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint@8.54.0): dependencies: array-includes: 3.1.7 array.prototype.findlastindex: 1.2.3 @@ -24378,7 +24388,7 @@ snapshots: doctrine: 2.1.0 eslint: 8.54.0 eslint-import-resolver-node: 0.3.9 - eslint-module-utils: 2.8.0(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.4.5))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.1(@typescript-eslint/parser@6.9.1(eslint@8.54.0)(typescript@5.4.5))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1)(eslint@8.54.0))(eslint@8.54.0) + eslint-module-utils: 2.8.0(@typescript-eslint/parser@6.9.1(eslint@8.57.0)(typescript@5.4.5))(eslint-import-resolver-node@0.3.9)(eslint@8.54.0) hasown: 2.0.0 is-core-module: 2.13.1 is-glob: 4.0.3 @@ -24389,7 +24399,7 @@ snapshots: semver: 6.3.1 tsconfig-paths: 3.15.0 optionalDependencies: - '@typescript-eslint/parser': 6.9.1(eslint@8.54.0)(typescript@5.4.5) + '@typescript-eslint/parser': 6.9.1(eslint@8.57.0)(typescript@5.4.5) transitivePeerDependencies: - eslint-import-resolver-typescript - eslint-import-resolver-webpack From 92b03c8b706cab26cf594fadde9b09d045c4c1d2 Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Wed, 24 Jul 2024 12:05:10 +0100 Subject: [PATCH 24/43] chore: lint --- packages/abi-coder/src/FunctionFragment.ts | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/packages/abi-coder/src/FunctionFragment.ts b/packages/abi-coder/src/FunctionFragment.ts index 296ac70d775..97ed29399a5 100644 --- a/packages/abi-coder/src/FunctionFragment.ts +++ b/packages/abi-coder/src/FunctionFragment.ts @@ -10,14 +10,9 @@ import { ResolvedAbiType } from './ResolvedAbiType'; import type { DecodedValue, InputValue } from './encoding/coders/AbstractCoder'; import { StdStringCoder } from './encoding/coders/StdStringCoder'; import { TupleCoder } from './encoding/coders/TupleCoder'; -import type { - JsonAbi, - JsonAbiArgument, - JsonAbiFunction, - JsonAbiFunctionAttribute, -} from './types/JsonAbi'; +import type { JsonAbi, JsonAbiFunction, JsonAbiFunctionAttribute } from './types/JsonAbi'; import type { EncodingVersion } from './utils/constants'; -import { OPTION_CODER_TYPE, VOID_TYPE } from './utils/constants'; +import { VOID_TYPE } from './utils/constants'; import { getMandatoryInputs } from './utils/getMandatoryInputs'; import { findFunctionByName, From 5324433a42ff429106d12f3fa8f58261d4100f86 Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Wed, 24 Jul 2024 16:17:47 +0100 Subject: [PATCH 25/43] chore: renamed `findNonEmptyInputs` to `findNonVoidInputs` --- packages/abi-coder/src/FunctionFragment.ts | 10 +++++----- packages/abi-coder/src/utils/json-abi.test.ts | 8 ++++---- packages/abi-coder/src/utils/json-abi.ts | 6 +++--- 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/packages/abi-coder/src/FunctionFragment.ts b/packages/abi-coder/src/FunctionFragment.ts index 97ed29399a5..f8faae3f218 100644 --- a/packages/abi-coder/src/FunctionFragment.ts +++ b/packages/abi-coder/src/FunctionFragment.ts @@ -16,7 +16,7 @@ import { VOID_TYPE } from './utils/constants'; import { getMandatoryInputs } from './utils/getMandatoryInputs'; import { findFunctionByName, - findNonEmptyInputs, + findNonVoidInputs, findTypeById, getEncodingVersion, } from './utils/json-abi'; @@ -89,9 +89,9 @@ export class FunctionFragment< decodeArguments(data: BytesLike) { const bytes = arrayify(data); - const nonEmptyInputs = findNonEmptyInputs(this.jsonAbi, this.jsonFn.inputs); + const nonVoidInputs = findNonVoidInputs(this.jsonAbi, this.jsonFn.inputs); - if (nonEmptyInputs.length === 0) { + if (nonVoidInputs.length === 0) { // The VM is current return 0x0000000000000000, but we should treat it as undefined / void if (bytes.length === 0) { return undefined; @@ -102,12 +102,12 @@ export class FunctionFragment< `Types/values length mismatch during decode. ${JSON.stringify({ count: { types: this.jsonFn.inputs.length, - nonEmptyInputs: nonEmptyInputs.length, + nonVoidInputs: nonVoidInputs.length, values: bytes.length, }, value: { args: this.jsonFn.inputs, - nonEmptyInputs, + nonVoidInputs, values: bytes, }, })}` diff --git a/packages/abi-coder/src/utils/json-abi.test.ts b/packages/abi-coder/src/utils/json-abi.test.ts index 853530c87bb..be661e335a2 100644 --- a/packages/abi-coder/src/utils/json-abi.test.ts +++ b/packages/abi-coder/src/utils/json-abi.test.ts @@ -4,7 +4,7 @@ import type { JsonAbi, JsonAbiArgument } from '../types/JsonAbi'; import { ENCODING_V1 } from './constants'; import { findFunctionByName, - findNonEmptyInputs, + findNonVoidInputs, findTypeById, findVectorBufferArgument, getEncodingVersion, @@ -98,7 +98,7 @@ describe('json-abi', () => { }); }); - describe('findNonEmptyInputs', () => { + describe('findNonVoidInputs', () => { it('should find non-empty inputs', () => { const inputs: JsonAbiArgument[] = [ { name: 'a', type: 1, typeArguments: [] }, @@ -106,7 +106,7 @@ describe('json-abi', () => { ]; const expected = [{ name: 'b', type: 2, typeArguments: [] }]; - const actual = findNonEmptyInputs(MOCK_ABI, inputs); + const actual = findNonVoidInputs(MOCK_ABI, inputs); expect(actual).toEqual(expected); }); @@ -114,7 +114,7 @@ describe('json-abi', () => { it('should throw an error if the type is not found', () => { const inputs: JsonAbiArgument[] = [{ name: 'a', type: -1, typeArguments: [] }]; - expect(() => findNonEmptyInputs(MOCK_ABI, inputs)).toThrowError( + expect(() => findNonVoidInputs(MOCK_ABI, inputs)).toThrowError( `Type with typeId '-1' doesn't exist in the ABI.` ); }); diff --git a/packages/abi-coder/src/utils/json-abi.ts b/packages/abi-coder/src/utils/json-abi.ts index 6bfb671d320..1091554c8a4 100644 --- a/packages/abi-coder/src/utils/json-abi.ts +++ b/packages/abi-coder/src/utils/json-abi.ts @@ -63,14 +63,14 @@ export const findTypeById = (abi: JsonAbi, typeId: number): JsonAbiType => { }; /** - * Find all non-empty inputs in a list of inputs. + * Find all non-void inputs in a list of inputs. * i.e. all inputs that are not of the type '()'. * * @param abi - the JsonAbi object * @param inputs - the list of inputs to filter - * @returns the list of non-empty inputs + * @returns the list of non-void inputs */ -export const findNonEmptyInputs = ( +export const findNonVoidInputs = ( abi: JsonAbi, inputs: readonly JsonAbiArgument[] ): JsonAbiArgument[] => inputs.filter((input) => findTypeById(abi, input.type).type !== VOID_TYPE); From 57c363f5558108286a74df0dcbb44515990e6fbd Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Wed, 24 Jul 2024 16:18:40 +0100 Subject: [PATCH 26/43] chore: iterate over all inputs for `decodeArguments` --- packages/abi-coder/src/FunctionFragment.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/abi-coder/src/FunctionFragment.ts b/packages/abi-coder/src/FunctionFragment.ts index f8faae3f218..323028ef8ad 100644 --- a/packages/abi-coder/src/FunctionFragment.ts +++ b/packages/abi-coder/src/FunctionFragment.ts @@ -114,7 +114,7 @@ export class FunctionFragment< ); } - const result = nonEmptyInputs.reduce( + const result = this.jsonFn.inputs.reduce( (obj: { decoded: unknown[]; offset: number }, input) => { const coder = AbiCoder.getCoder(this.jsonAbi, input, { encoding: this.encoding }); const [decodedValue, decodedValueByteSize] = coder.decode(bytes, obj.offset); From 00b589a25171a65b1d51ffe5941ef3e41ac93d4a Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Wed, 24 Jul 2024 16:23:09 +0100 Subject: [PATCH 27/43] chore: removed void check for `decodeOutput` --- packages/abi-coder/src/FunctionFragment.ts | 5 ----- 1 file changed, 5 deletions(-) diff --git a/packages/abi-coder/src/FunctionFragment.ts b/packages/abi-coder/src/FunctionFragment.ts index 323028ef8ad..aecfa6c308c 100644 --- a/packages/abi-coder/src/FunctionFragment.ts +++ b/packages/abi-coder/src/FunctionFragment.ts @@ -131,11 +131,6 @@ export class FunctionFragment< } decodeOutput(data: BytesLike): [DecodedValue | undefined, number] { - const outputAbiType = findTypeById(this.jsonAbi, this.jsonFn.output.type); - if (outputAbiType.type === VOID_TYPE) { - return [undefined, 0]; - } - const bytes = arrayify(data); const coder = AbiCoder.getCoder(this.jsonAbi, this.jsonFn.output, { encoding: this.encoding, From be0cdd5304a0370a32a1ac2a1bfb78b1ca0c213b Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Wed, 24 Jul 2024 16:34:11 +0100 Subject: [PATCH 28/43] chore: added test for optional option --- packages/fuel-gauge/src/options.test.ts | 22 +++++++++++----------- packages/fuel-gauge/src/void.test.ts | 13 ++++++++----- 2 files changed, 19 insertions(+), 16 deletions(-) diff --git a/packages/fuel-gauge/src/options.test.ts b/packages/fuel-gauge/src/options.test.ts index c1662a28e3b..3bce84a28bf 100644 --- a/packages/fuel-gauge/src/options.test.ts +++ b/packages/fuel-gauge/src/options.test.ts @@ -228,25 +228,25 @@ describe('Options Tests', () => { it('echoes option enum diff sizes', async () => { using contract = await launchOptionsContract(); - const call1 = await contract.functions.echo_enum_diff_sizes(undefined).call(); - const { value } = await call1.waitForResult(); + const call1 = await contract.functions.echo_enum_diff_sizes().call(); + const { value: value1 } = await call1.waitForResult(); + expect(value1).toStrictEqual(undefined); - expect(value).toStrictEqual(undefined); - - const call2 = await contract.functions.echo_enum_diff_sizes({ a: U8_MAX }).call(); + const call2 = await contract.functions.echo_enum_diff_sizes(undefined).call(); const { value: value2 } = await call2.waitForResult(); + expect(value2).toStrictEqual(undefined); - expect(value2).toStrictEqual({ a: U8_MAX }); + const call3 = await contract.functions.echo_enum_diff_sizes({ a: U8_MAX }).call(); + const { value: value3 } = await call3.waitForResult(); + expect(value3).toStrictEqual({ a: U8_MAX }); - const call3 = await contract.functions + const call4 = await contract.functions .echo_enum_diff_sizes({ b: '0x9ae5b658754e096e4d681c548daf46354495a437cc61492599e33fc64dcdc30c', }) .call(); - - const { value: value3 } = await call3.waitForResult(); - - expect(value3).toStrictEqual({ + const { value: value4 } = await call4.waitForResult(); + expect(value4).toStrictEqual({ b: '0x9ae5b658754e096e4d681c548daf46354495a437cc61492599e33fc64dcdc30c', }); }); diff --git a/packages/fuel-gauge/src/void.test.ts b/packages/fuel-gauge/src/void.test.ts index 945b114ac50..50efa7e967c 100644 --- a/packages/fuel-gauge/src/void.test.ts +++ b/packages/fuel-gauge/src/void.test.ts @@ -18,13 +18,11 @@ describe('Void Tests', () => { it('should handle Option::None', async () => { using launched = await launchTestNode({ contractsConfigs }); - const { contracts: [voidContract], } = launched; const optionNone: Option = undefined; - const { waitForResult } = await voidContract.functions.echo_void(optionNone).call(); const { value } = await waitForResult(); @@ -55,10 +53,15 @@ describe('Void Tests', () => { const voidTypeValue: undefined = undefined; - const { waitForResult } = await voidContract.functions.type_then_void(42, voidTypeValue).call(); - const { value } = await waitForResult(); + const { waitForResult: call1 } = await voidContract.functions.type_then_void(42).call(); + const { value: value1 } = await call1(); + expect(value1).toEqual(undefined); - expect(value).toEqual(voidTypeValue); + const { waitForResult: call2 } = await voidContract.functions + .type_then_void(42, undefined) + .call(); + const { value: value2 } = await call2(); + expect(value2).toEqual(voidTypeValue); }); it('should handle input arguments of type [42, void, 43]', async () => { From 17b961dc3407236476ee83c6e007ce2303eee884 Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Wed, 24 Jul 2024 16:38:34 +0100 Subject: [PATCH 29/43] chore: housekeeping --- packages/fuel-gauge/src/options.test.ts | 79 +++++++------------------ 1 file changed, 23 insertions(+), 56 deletions(-) diff --git a/packages/fuel-gauge/src/options.test.ts b/packages/fuel-gauge/src/options.test.ts index 3bce84a28bf..4fbecf9b65e 100644 --- a/packages/fuel-gauge/src/options.test.ts +++ b/packages/fuel-gauge/src/options.test.ts @@ -1,7 +1,10 @@ +import type { BigNumberish } from 'fuels'; import { launchTestNode } from 'fuels/test-utils'; import { OptionsAbi__factory } from '../test/typegen/contracts'; +import type { DeepStructInput } from '../test/typegen/contracts/OptionsAbi'; import OptionsAbiHex from '../test/typegen/contracts/OptionsAbi.hex'; +import type { Option } from '../test/typegen/contracts/common'; import { launchTestContract } from './utils'; @@ -16,6 +19,9 @@ function launchOptionsContract() { }); } +type DoubleTupleOptions = [Option, Option]; +type TripleTupleOptions = [Option, Option, Option]; + /** * @group node * @group browser @@ -44,35 +50,30 @@ describe('Options Tests', () => { }); it('echos u8 option', async () => { - const someInput = U8_MAX; - const noneInput = undefined; - using contract = await launchOptionsContract(); + const someInput = U8_MAX; const call1 = await contract.functions.echo_option(someInput).call(); const { value: someValue } = await call1.waitForResult(); - expect(someValue).toBe(someInput); + const noneInput = undefined; const call2 = await contract.functions.echo_option(noneInput).call(); const { value: noneValue } = await call2.waitForResult(); - expect(noneValue).toBe(noneInput); }); it('echos struct enum option', async () => { + using contract = await launchOptionsContract(); + const someInput = { one: { a: U8_MAX, }, two: U32_MAX, }; - - using contract = await launchOptionsContract(); - const call1 = await contract.functions.echo_struct_enum_option(someInput).call(); const { value: someValue } = await call1.waitForResult(); - expect(someValue).toStrictEqual(someInput); const noneInput = { @@ -81,123 +82,92 @@ describe('Options Tests', () => { }, two: undefined, }; - const call2 = await contract.functions.echo_struct_enum_option(noneInput).call(); const { value: noneValue } = await call2.waitForResult(); - expect(noneValue).toStrictEqual(noneInput); }); it('echos vec option', async () => { - const someInput = [U8_MAX, U16_MAX, U32_MAX]; - using contract = await launchOptionsContract(); + const someInput = [U8_MAX, U16_MAX, U32_MAX]; const call1 = await contract.functions.echo_vec_option(someInput).call(); - const { value: someValue } = await call1.waitForResult(); expect(someValue).toStrictEqual(someInput); const noneInput = [undefined, undefined, undefined]; - const call2 = await contract.functions.echo_vec_option(noneInput).call(); const { value: noneValue } = await call2.waitForResult(); - expect(noneValue).toStrictEqual(noneInput); const mixedInput = [U8_MAX, undefined, U32_MAX]; - const call3 = await contract.functions.echo_vec_option(mixedInput).call(); const { value: mixedValue } = await call3.waitForResult(); - expect(mixedValue).toStrictEqual(mixedInput); }); it('echos tuple option', async () => { - const someInput = [U8_MAX, U16_MAX]; - using contract = await launchOptionsContract(); + const someInput = [U8_MAX, U16_MAX] as DoubleTupleOptions; const call1 = await contract.functions.echo_tuple_option(someInput).call(); - const { value: someValue } = await call1.waitForResult(); - expect(someValue).toStrictEqual(someInput); - const noneInput = [undefined, undefined]; - + const noneInput = [undefined, undefined] as DoubleTupleOptions; const call2 = await contract.functions.echo_tuple_option(noneInput).call(); - const { value: noneValue } = await call2.waitForResult(); - expect(noneValue).toStrictEqual(noneInput); - const mixedInput = [U8_MAX, undefined]; - + const mixedInput = [U8_MAX, undefined] as DoubleTupleOptions; const call3 = await contract.functions.echo_tuple_option(mixedInput).call(); - const { value: mixedValue } = await call3.waitForResult(); - expect(mixedValue).toStrictEqual(mixedInput); }); it('echoes enum option', async () => { - const someInput = { a: U8_MAX }; - using contract = await launchOptionsContract(); + const someInput = { a: U8_MAX }; const call1 = await contract.functions.echo_enum_option(someInput).call(); - const { value: someValue } = await call1.waitForResult(); - expect(someValue).toStrictEqual(someInput); const noneInput = { b: undefined }; - const call2 = await contract.functions.echo_enum_option(noneInput).call(); - const { value: noneValue } = await call2.waitForResult(); - expect(noneValue).toStrictEqual(noneInput); }); it('echos array option', async () => { - const someInput = [U8_MAX, U16_MAX, 123]; - using contract = await launchOptionsContract(); + const someInput = [U8_MAX, U16_MAX, 123] as TripleTupleOptions; const call1 = await contract.functions.echo_array_option(someInput).call(); const { value: someValue } = await call1.waitForResult(); - expect(someValue).toStrictEqual(someInput); - const noneInput = [undefined, undefined, undefined]; - + const noneInput = [undefined, undefined, undefined] as TripleTupleOptions; const call2 = await contract.functions.echo_array_option(noneInput).call(); const { value: noneValue } = await call2.waitForResult(); - expect(noneValue).toStrictEqual(noneInput); - const mixedInput = [U8_MAX, undefined, 123]; - + const mixedInput = [U8_MAX, undefined, 123] as TripleTupleOptions; const call3 = await contract.functions.echo_array_option(mixedInput).call(); const { value: mixedValue } = await call3.waitForResult(); - expect(mixedValue).toStrictEqual(mixedInput); }); it('echoes deeply nested option', async () => { - const input = { + using contract = await launchOptionsContract(); + + const input: DeepStructInput = { DeepEnum: { a: [true, [U8_MAX, undefined, 123]], }, }; - - using contract = await launchOptionsContract(); const { waitForResult } = await contract.functions.echo_deeply_nested_option(input).call(); - const { value } = await waitForResult(); - expect(value).toStrictEqual(input); }); @@ -216,12 +186,9 @@ describe('Options Tests', () => { wallets: [wallet], } = launched; - const { waitForResult } = await contract.functions - .get_some_struct({ Address: { bits: wallet.address.toB256() } }) - .call(); - + const input = { Address: { bits: wallet.address.toB256() } }; + const { waitForResult } = await contract.functions.get_some_struct(input).call(); const { value } = await waitForResult(); - expect(value).toStrictEqual(undefined); }); From c49d247dd3634b8973def46cfcabcf7e995bba97 Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Wed, 24 Jul 2024 17:27:08 +0100 Subject: [PATCH 30/43] Add option tests --- packages/fuel-gauge/src/options.test.ts | 24 +++++++++++++++++++ .../forc-projects/options/src/main.sw | 18 ++++++++++++++ 2 files changed, 42 insertions(+) diff --git a/packages/fuel-gauge/src/options.test.ts b/packages/fuel-gauge/src/options.test.ts index 4fbecf9b65e..5169b770d7b 100644 --- a/packages/fuel-gauge/src/options.test.ts +++ b/packages/fuel-gauge/src/options.test.ts @@ -217,4 +217,28 @@ describe('Options Tests', () => { b: '0x9ae5b658754e096e4d681c548daf46354495a437cc61492599e33fc64dcdc30c', }); }); + + it('should handle Option::None', async () => { + using contract = await launchOptionsContract(); + + const optionNone: Option = undefined; + const call1 = await contract.functions.type_then_option_then_type(42, optionNone, 43).call(); + const { value: value1 } = await call1.waitForResult(); + expect(value1).toStrictEqual(optionNone); + }); + + it('should handle optional options', async () => { + using contract = await launchOptionsContract(); + + const optionNone: Option = undefined; + const call1 = await contract.functions.option_then_type_then_option(optionNone, 42).call(); + const { value: value1 } = await call1.waitForResult(); + expect(value1).toStrictEqual(optionNone); + + const call2 = await contract.functions + .option_then_type_then_option(optionNone, 42, optionNone) + .call(); + const { value: value2 } = await call2.waitForResult(); + expect(value2).toStrictEqual(optionNone); + }); }); diff --git a/packages/fuel-gauge/test/fixtures/forc-projects/options/src/main.sw b/packages/fuel-gauge/test/fixtures/forc-projects/options/src/main.sw index 95cfda5a5ae..009e5bcc54c 100644 --- a/packages/fuel-gauge/test/fixtures/forc-projects/options/src/main.sw +++ b/packages/fuel-gauge/test/fixtures/forc-projects/options/src/main.sw @@ -77,6 +77,8 @@ abi OptionContract { fn print_enum_option_array() -> GardenVector; fn echo_deeply_nested_option(arg: DeepStruct) -> DeepStruct; fn echo_enum_diff_sizes(arg: Option) -> Option; + fn type_then_option_then_type(x: u8, y: Option, z: u8) -> Option; + fn option_then_type_then_option(x: Option, y: u8, z: Option) -> Option; } impl OptionContract for Contract { @@ -120,4 +122,20 @@ impl OptionContract for Contract { fn echo_enum_diff_sizes(arg: Option) -> Option { arg } + + fn type_then_option_then_type(x: u8, y: Option, z: u8) -> Option { + assert_eq(x, 42); + assert_eq(y, Option::None); + assert_eq(z, 43); + + y + } + + fn option_then_type_then_option(x: Option, y: u8, z: Option) -> Option { + assert_eq(x, Option::None); + assert_eq(y, 42); + assert_eq(z, Option::None); + + z + } } From 96b5289dacea1a751df5d49de6e1ac1fa1b70829 Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Wed, 24 Jul 2024 17:27:17 +0100 Subject: [PATCH 31/43] Linting --- packages/abi-coder/src/FunctionFragment.ts | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/packages/abi-coder/src/FunctionFragment.ts b/packages/abi-coder/src/FunctionFragment.ts index aecfa6c308c..d5e7ebf61fc 100644 --- a/packages/abi-coder/src/FunctionFragment.ts +++ b/packages/abi-coder/src/FunctionFragment.ts @@ -12,14 +12,8 @@ import { StdStringCoder } from './encoding/coders/StdStringCoder'; import { TupleCoder } from './encoding/coders/TupleCoder'; import type { JsonAbi, JsonAbiFunction, JsonAbiFunctionAttribute } from './types/JsonAbi'; import type { EncodingVersion } from './utils/constants'; -import { VOID_TYPE } from './utils/constants'; import { getMandatoryInputs } from './utils/getMandatoryInputs'; -import { - findFunctionByName, - findNonVoidInputs, - findTypeById, - getEncodingVersion, -} from './utils/json-abi'; +import { findFunctionByName, findNonVoidInputs, getEncodingVersion } from './utils/json-abi'; export class FunctionFragment< TAbi extends JsonAbi = JsonAbi, From 00ece328cfb78c675aed356cacda4bd65afb0af5 Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Thu, 25 Jul 2024 09:49:27 +0100 Subject: [PATCH 32/43] chore: add script test with options (WIP) --- .../src/script-with-options.test.ts | 42 +++++++++++++++++++ .../test/fixtures/forc-projects/Forc.toml | 1 + .../script-with-options/Forc.toml | 6 +++ .../script-with-options/src/main.sw | 14 +++++++ 4 files changed, 63 insertions(+) create mode 100644 packages/fuel-gauge/src/script-with-options.test.ts create mode 100644 packages/fuel-gauge/test/fixtures/forc-projects/script-with-options/Forc.toml create mode 100644 packages/fuel-gauge/test/fixtures/forc-projects/script-with-options/src/main.sw diff --git a/packages/fuel-gauge/src/script-with-options.test.ts b/packages/fuel-gauge/src/script-with-options.test.ts new file mode 100644 index 00000000000..fb3aeb695c6 --- /dev/null +++ b/packages/fuel-gauge/src/script-with-options.test.ts @@ -0,0 +1,42 @@ +import { bn } from 'fuels'; +import { launchTestNode } from 'fuels/test-utils'; + +import { ScriptWithOptionsAbi__factory } from '../test/typegen'; +import type { ScriptWithOptionsAbiConfigurables } from '../test/typegen/scripts/factories/ScriptWithOptionsAbi__factory'; + +/** + * @group node + * @group browser + */ +describe('Script With Options', () => { + it('should call script with optional arguments', async () => { + using launched = await launchTestNode(); + + const { + wallets: [wallet], + } = launched; + + const scriptWithOptions = ScriptWithOptionsAbi__factory.createInstance(wallet); + const expectedValue = true; + const configurables: ScriptWithOptionsAbiConfigurables = { X: bn(1), Y: bn(2), Z: bn(3) }; + + // Script with no inputs + scriptWithOptions.setConfigurableConstants({ X: undefined, Y: undefined, Z: undefined }); + const { waitForResult: call1 } = await scriptWithOptions.functions.main().call(); + const { value: value1 } = await call1(); + expect(value1).toBe(expectedValue); + + // Script with single input + scriptWithOptions.setConfigurableConstants({ X: bn(1), Y: undefined, Z: undefined }); + const { waitForResult: call2 } = await scriptWithOptions.functions.main(bn(1)).call(); + const { value: value2 } = await call2(); + expect(value2).toBe(expectedValue); + + // Script with two inputs + const { waitForResult: call3 } = await scriptWithOptions.functions + .main(undefined, undefined) + .call(); + const { value: value3 } = await call3(); + expect(value3).toBe(expectedValue); + }); +}); diff --git a/packages/fuel-gauge/test/fixtures/forc-projects/Forc.toml b/packages/fuel-gauge/test/fixtures/forc-projects/Forc.toml index 7cc5fc2667c..225e7cb7614 100644 --- a/packages/fuel-gauge/test/fixtures/forc-projects/Forc.toml +++ b/packages/fuel-gauge/test/fixtures/forc-projects/Forc.toml @@ -55,6 +55,7 @@ members = [ "script-with-array", "script-with-configurable", "script-with-vector", + "script-with-options", "script-with-vector-advanced", "script-with-vector-mixed", "small-bytes", diff --git a/packages/fuel-gauge/test/fixtures/forc-projects/script-with-options/Forc.toml b/packages/fuel-gauge/test/fixtures/forc-projects/script-with-options/Forc.toml new file mode 100644 index 00000000000..06a9ef676ce --- /dev/null +++ b/packages/fuel-gauge/test/fixtures/forc-projects/script-with-options/Forc.toml @@ -0,0 +1,6 @@ +[project] +authors = ["Fuel Labs "] +license = "Apache-2.0" +name = "script-with-options" + +[dependencies] diff --git a/packages/fuel-gauge/test/fixtures/forc-projects/script-with-options/src/main.sw b/packages/fuel-gauge/test/fixtures/forc-projects/script-with-options/src/main.sw new file mode 100644 index 00000000000..deb6b11c4cc --- /dev/null +++ b/packages/fuel-gauge/test/fixtures/forc-projects/script-with-options/src/main.sw @@ -0,0 +1,14 @@ +script; + +configurable { + X: Option = Option::None, + Y: Option = Option::None, + Z: Option = Option::None, +} + +fn main(x: Option, y: Option, z: Option) -> bool { + assert_eq(x, X); + assert_eq(y, Y); + assert_eq(z, Z); + true +} From 09fa2eba19fbcf3844342ee621ca1b1a55d3b475 Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Mon, 29 Jul 2024 11:49:53 +0100 Subject: [PATCH 33/43] chore: added script options test --- .../src/script-with-options.test.ts | 21 ++++++++++++------- .../script-with-options/src/main.sw | 9 -------- 2 files changed, 14 insertions(+), 16 deletions(-) diff --git a/packages/fuel-gauge/src/script-with-options.test.ts b/packages/fuel-gauge/src/script-with-options.test.ts index fb3aeb695c6..a53f14e922c 100644 --- a/packages/fuel-gauge/src/script-with-options.test.ts +++ b/packages/fuel-gauge/src/script-with-options.test.ts @@ -1,8 +1,9 @@ +import type { BigNumberish } from 'fuels'; import { bn } from 'fuels'; import { launchTestNode } from 'fuels/test-utils'; import { ScriptWithOptionsAbi__factory } from '../test/typegen'; -import type { ScriptWithOptionsAbiConfigurables } from '../test/typegen/scripts/factories/ScriptWithOptionsAbi__factory'; +import type { Option } from '../test/typegen/contracts/common'; /** * @group node @@ -18,25 +19,31 @@ describe('Script With Options', () => { const scriptWithOptions = ScriptWithOptionsAbi__factory.createInstance(wallet); const expectedValue = true; - const configurables: ScriptWithOptionsAbiConfigurables = { X: bn(1), Y: bn(2), Z: bn(3) }; + const OPTION_SOME: Option = bn(1); + const OPTION_NONE: Option = undefined; // Script with no inputs - scriptWithOptions.setConfigurableConstants({ X: undefined, Y: undefined, Z: undefined }); const { waitForResult: call1 } = await scriptWithOptions.functions.main().call(); const { value: value1 } = await call1(); expect(value1).toBe(expectedValue); // Script with single input - scriptWithOptions.setConfigurableConstants({ X: bn(1), Y: undefined, Z: undefined }); - const { waitForResult: call2 } = await scriptWithOptions.functions.main(bn(1)).call(); + const { waitForResult: call2 } = await scriptWithOptions.functions.main(OPTION_SOME).call(); const { value: value2 } = await call2(); expect(value2).toBe(expectedValue); - // Script with two inputs + // Script with three input const { waitForResult: call3 } = await scriptWithOptions.functions - .main(undefined, undefined) + .main(OPTION_SOME, OPTION_SOME, OPTION_SOME) .call(); const { value: value3 } = await call3(); expect(value3).toBe(expectedValue); + + // Script with mix of optional input + const { waitForResult: call4 } = await scriptWithOptions.functions + .main(OPTION_SOME, OPTION_NONE, OPTION_NONE) + .call(); + const { value: value4 } = await call4(); + expect(value4).toBe(expectedValue); }); }); diff --git a/packages/fuel-gauge/test/fixtures/forc-projects/script-with-options/src/main.sw b/packages/fuel-gauge/test/fixtures/forc-projects/script-with-options/src/main.sw index deb6b11c4cc..b34aa4b2c8c 100644 --- a/packages/fuel-gauge/test/fixtures/forc-projects/script-with-options/src/main.sw +++ b/packages/fuel-gauge/test/fixtures/forc-projects/script-with-options/src/main.sw @@ -1,14 +1,5 @@ script; -configurable { - X: Option = Option::None, - Y: Option = Option::None, - Z: Option = Option::None, -} - fn main(x: Option, y: Option, z: Option) -> bool { - assert_eq(x, X); - assert_eq(y, Y); - assert_eq(z, Z); true } From b27050190e2a155cc104b248374b3e9fbe600fec Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Mon, 29 Jul 2024 11:52:35 +0100 Subject: [PATCH 34/43] chore: renamed `getMandatoryInputs` -> `getFunctionInputs` --- packages/abi-coder/src/FunctionFragment.ts | 4 ++-- ...yInputs.test.ts => getFunctionInputs.test.ts} | 16 ++++++++-------- ...etMandatoryInputs.ts => getFunctionInputs.ts} | 2 +- .../abi-typegen/src/abi/functions/Function.ts | 4 ++-- ...yInputs.test.ts => getFunctionInputs.test.ts} | 16 ++++++++-------- ...etMandatoryInputs.ts => getFunctionInputs.ts} | 2 +- 6 files changed, 22 insertions(+), 22 deletions(-) rename packages/abi-coder/src/utils/{getMandatoryInputs.test.ts => getFunctionInputs.test.ts} (88%) rename packages/abi-coder/src/utils/{getMandatoryInputs.ts => getFunctionInputs.ts} (95%) rename packages/abi-typegen/src/utils/{getMandatoryInputs.test.ts => getFunctionInputs.test.ts} (89%) rename packages/abi-typegen/src/utils/{getMandatoryInputs.ts => getFunctionInputs.ts} (96%) diff --git a/packages/abi-coder/src/FunctionFragment.ts b/packages/abi-coder/src/FunctionFragment.ts index d5e7ebf61fc..c90e2c39281 100644 --- a/packages/abi-coder/src/FunctionFragment.ts +++ b/packages/abi-coder/src/FunctionFragment.ts @@ -12,7 +12,7 @@ import { StdStringCoder } from './encoding/coders/StdStringCoder'; import { TupleCoder } from './encoding/coders/TupleCoder'; import type { JsonAbi, JsonAbiFunction, JsonAbiFunctionAttribute } from './types/JsonAbi'; import type { EncodingVersion } from './utils/constants'; -import { getMandatoryInputs } from './utils/getMandatoryInputs'; +import { getFunctionInputs } from './utils/getFunctionInputs'; import { findFunctionByName, findNonVoidInputs, getEncodingVersion } from './utils/json-abi'; export class FunctionFragment< @@ -56,7 +56,7 @@ export class FunctionFragment< } encodeArguments(values: InputValue[]): Uint8Array { - const inputs = getMandatoryInputs({ jsonAbi: this.jsonAbi, inputs: this.jsonFn.inputs }); + const inputs = getFunctionInputs({ jsonAbi: this.jsonAbi, inputs: this.jsonFn.inputs }); const mandatoryInputLength = inputs.filter((i) => !i.isOptional).length; if (values.length < mandatoryInputLength) { diff --git a/packages/abi-coder/src/utils/getMandatoryInputs.test.ts b/packages/abi-coder/src/utils/getFunctionInputs.test.ts similarity index 88% rename from packages/abi-coder/src/utils/getMandatoryInputs.test.ts rename to packages/abi-coder/src/utils/getFunctionInputs.test.ts index 3e7392ab9ff..538e2503cd1 100644 --- a/packages/abi-coder/src/utils/getMandatoryInputs.test.ts +++ b/packages/abi-coder/src/utils/getFunctionInputs.test.ts @@ -1,6 +1,6 @@ import type { JsonAbi, JsonAbiArgument, JsonAbiType } from '../types/JsonAbi'; -import { getMandatoryInputs } from './getMandatoryInputs'; +import { getFunctionInputs } from './getFunctionInputs'; const nonEmptyType: JsonAbiType = { type: 'u8', @@ -49,12 +49,12 @@ const jsonAbi: JsonAbi = { * @group node */ describe.each(EMPTY_ABI_TYPES)( - 'getMandatoryInputs.ts [empty=%s]', + 'getFunctionInputs.ts [empty=%s]', (_: string, emptyAbiType: JsonAbiType) => { it('should handle no inputs', () => { const inputs: Array = []; - const result = getMandatoryInputs({ jsonAbi, inputs }); + const result = getFunctionInputs({ jsonAbi, inputs }); expect(result).toEqual([]); }); @@ -65,7 +65,7 @@ describe.each(EMPTY_ABI_TYPES)( const C = { type: emptyAbiType.typeId, name: 'c', typeArguments: null }; const inputs: Array = [A, B, C]; - const result = getMandatoryInputs({ jsonAbi, inputs }); + const result = getFunctionInputs({ jsonAbi, inputs }); expect(result).toEqual([ { ...A, isOptional: true }, @@ -80,7 +80,7 @@ describe.each(EMPTY_ABI_TYPES)( const C = { type: nonEmptyType.typeId, name: 'c', typeArguments: null }; const inputs: Array = [A, B, C]; - const result = getMandatoryInputs({ jsonAbi, inputs }); + const result = getFunctionInputs({ jsonAbi, inputs }); expect(result).toEqual([ { ...A, isOptional: false }, @@ -95,7 +95,7 @@ describe.each(EMPTY_ABI_TYPES)( const C = { type: emptyAbiType.typeId, name: 'c', typeArguments: null }; const inputs: Array = [A, B, C]; - const result = getMandatoryInputs({ jsonAbi, inputs }); + const result = getFunctionInputs({ jsonAbi, inputs }); expect(result).toEqual([ { ...A, isOptional: false }, @@ -110,7 +110,7 @@ describe.each(EMPTY_ABI_TYPES)( const C = { type: nonEmptyType.typeId, name: 'c', typeArguments: null }; const inputs: Array = [A, B, C]; - const result = getMandatoryInputs({ jsonAbi, inputs }); + const result = getFunctionInputs({ jsonAbi, inputs }); expect(result).toEqual([ { ...A, isOptional: false }, @@ -125,7 +125,7 @@ describe.each(EMPTY_ABI_TYPES)( const C = { type: nonEmptyType.typeId, name: 'c', typeArguments: null }; const inputs: Array = [A, B, C]; - const result = getMandatoryInputs({ jsonAbi, inputs }); + const result = getFunctionInputs({ jsonAbi, inputs }); expect(result).toEqual([ { ...A, isOptional: false }, diff --git a/packages/abi-coder/src/utils/getMandatoryInputs.ts b/packages/abi-coder/src/utils/getFunctionInputs.ts similarity index 95% rename from packages/abi-coder/src/utils/getMandatoryInputs.ts rename to packages/abi-coder/src/utils/getFunctionInputs.ts index a878a83a9ad..1545fda6e3e 100644 --- a/packages/abi-coder/src/utils/getMandatoryInputs.ts +++ b/packages/abi-coder/src/utils/getFunctionInputs.ts @@ -9,7 +9,7 @@ export type ArgumentWithMetadata isOptional: boolean; }; -export const getMandatoryInputs = (params: { +export const getFunctionInputs = (params: { jsonAbi: JsonAbi; inputs: readonly JsonAbiArgument[]; }): Array => { diff --git a/packages/abi-typegen/src/abi/functions/Function.ts b/packages/abi-typegen/src/abi/functions/Function.ts index 613fe085472..de6fe2c45ab 100644 --- a/packages/abi-typegen/src/abi/functions/Function.ts +++ b/packages/abi-typegen/src/abi/functions/Function.ts @@ -2,7 +2,7 @@ import type { IFunction, JsonAbiFunction, IFunctionAttributes } from '../../inde import { TargetEnum } from '../../types/enums/TargetEnum'; import type { IType } from '../../types/interfaces/IType'; import { findType } from '../../utils/findType'; -import { getMandatoryInputs } from '../../utils/getMandatoryInputs'; +import { getFunctionInputs } from '../../utils/getFunctionInputs'; import { parseTypeArguments } from '../../utils/parseTypeArguments'; export class Function implements IFunction { @@ -27,7 +27,7 @@ export class Function implements IFunction { const { types } = this; // loop through all mandatory inputs - const inputs = getMandatoryInputs({ types, inputs: this.rawAbiFunction.inputs }).map( + const inputs = getFunctionInputs({ types, inputs: this.rawAbiFunction.inputs }).map( ({ isOptional, ...input }) => { const { name, type: typeId, typeArguments } = input; diff --git a/packages/abi-typegen/src/utils/getMandatoryInputs.test.ts b/packages/abi-typegen/src/utils/getFunctionInputs.test.ts similarity index 89% rename from packages/abi-typegen/src/utils/getMandatoryInputs.test.ts rename to packages/abi-typegen/src/utils/getFunctionInputs.test.ts index 0b5ca81e981..b60e394d0e5 100644 --- a/packages/abi-typegen/src/utils/getMandatoryInputs.test.ts +++ b/packages/abi-typegen/src/utils/getFunctionInputs.test.ts @@ -1,7 +1,7 @@ import type { IType } from '../types/interfaces/IType'; import type { JsonAbiArgument, JsonAbiType } from '../types/interfaces/JsonAbi'; -import { getMandatoryInputs } from './getMandatoryInputs'; +import { getFunctionInputs } from './getFunctionInputs'; import { makeType } from './makeType'; const nonEmptyType: JsonAbiType = { @@ -46,12 +46,12 @@ const types: Array = [nonEmptyType, voidAbiType, optionAbiType, debugOpti * @group node */ describe.each(EMPTY_ABI_TYPES)( - 'getMandatoryInputs.ts [empty=%s]', + 'getFunctionInputs.ts [empty=%s]', (_: string, emptyAbiType: JsonAbiType) => { it('should handle no inputs', () => { const inputs: Array = []; - const result = getMandatoryInputs({ types, inputs }); + const result = getFunctionInputs({ types, inputs }); expect(result).toEqual([]); }); @@ -62,7 +62,7 @@ describe.each(EMPTY_ABI_TYPES)( const C = { type: emptyAbiType.typeId, name: 'c', typeArguments: null }; const inputs: Array = [A, B, C]; - const result = getMandatoryInputs({ types, inputs }); + const result = getFunctionInputs({ types, inputs }); expect(result).toEqual([ { ...A, isOptional: true }, @@ -77,7 +77,7 @@ describe.each(EMPTY_ABI_TYPES)( const C = { type: nonEmptyType.typeId, name: 'c', typeArguments: null }; const inputs: Array = [A, B, C]; - const result = getMandatoryInputs({ types, inputs }); + const result = getFunctionInputs({ types, inputs }); expect(result).toEqual([ { ...A, isOptional: false }, @@ -92,7 +92,7 @@ describe.each(EMPTY_ABI_TYPES)( const C = { type: emptyAbiType.typeId, name: 'c', typeArguments: null }; const inputs: Array = [A, B, C]; - const result = getMandatoryInputs({ types, inputs }); + const result = getFunctionInputs({ types, inputs }); expect(result).toEqual([ { ...A, isOptional: false }, @@ -107,7 +107,7 @@ describe.each(EMPTY_ABI_TYPES)( const C = { type: nonEmptyType.typeId, name: 'c', typeArguments: null }; const inputs: Array = [A, B, C]; - const result = getMandatoryInputs({ types, inputs }); + const result = getFunctionInputs({ types, inputs }); expect(result).toEqual([ { ...A, isOptional: false }, @@ -122,7 +122,7 @@ describe.each(EMPTY_ABI_TYPES)( const C = { type: nonEmptyType.typeId, name: 'c', typeArguments: null }; const inputs: Array = [A, B, C]; - const result = getMandatoryInputs({ types, inputs }); + const result = getFunctionInputs({ types, inputs }); expect(result).toEqual([ { ...A, isOptional: false }, diff --git a/packages/abi-typegen/src/utils/getMandatoryInputs.ts b/packages/abi-typegen/src/utils/getFunctionInputs.ts similarity index 96% rename from packages/abi-typegen/src/utils/getMandatoryInputs.ts rename to packages/abi-typegen/src/utils/getFunctionInputs.ts index 6ba53940197..15cd38a675a 100644 --- a/packages/abi-typegen/src/utils/getMandatoryInputs.ts +++ b/packages/abi-typegen/src/utils/getFunctionInputs.ts @@ -11,7 +11,7 @@ export type ArgumentWithMetadata isOptional: boolean; }; -export const getMandatoryInputs = (params: { +export const getFunctionInputs = (params: { types: IType[]; inputs: readonly JsonAbiArgument[]; }): Array => { From 4b8bc21f4b4f0fd732679c30d7b12c33cc944c8a Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Mon, 29 Jul 2024 12:02:14 +0100 Subject: [PATCH 35/43] chore: fixed lockfile --- pnpm-lock.yaml | 23 +++++++++++++++++++++-- 1 file changed, 21 insertions(+), 2 deletions(-) diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index c84a3cbe007..827ee7f25c5 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -618,14 +618,14 @@ importers: version: link:../utils ramda: specifier: ^0.29.0 - version: 0.29.0 + version: 0.29.1 type-fest: specifier: ^3.1.0 version: 3.1.0 devDependencies: '@types/ramda': specifier: ^0.29.3 - version: 0.29.3 + version: 0.29.12 packages/abi-typegen: dependencies: @@ -5215,6 +5215,9 @@ packages: '@types/qs@6.9.7': resolution: {integrity: sha512-FGa1F62FT09qcrueBA6qYTrJPVDzah9a+493+o2PCXsesWHIn27G98TsSMs3WPNbZIEj4+VJf6saSFpvD+3Zsw==} + '@types/ramda@0.29.12': + resolution: {integrity: sha512-sgIEjpJhdQPB52gDF4aphs9nl0xe54CR22DPdWqT8gQHjZYmVApgA0R3/CpMbl0Y8az2TEZrPNL2zy0EvjbkLA==} + '@types/ramda@0.30.1': resolution: {integrity: sha512-aoyF/ADPL6N+/NXXfhPWF+Qj6w1Cql59m9wX0Gi15uyF+bpzXeLd63HPdiTDE2bmLXfNcVufsDPKmbfOrOzTBA==} @@ -11732,6 +11735,9 @@ packages: raf@3.4.1: resolution: {integrity: sha512-Sq4CW4QhwOHE8ucn6J34MqtZCeWFP2aQSmrlroYgqAV1PjStIhJXxYuTgUIfkEk7zTLjmIjLmU5q+fbD1NnOJA==} + ramda@0.29.1: + resolution: {integrity: sha512-OfxIeWzd4xdUNxlWhgFazxsA/nl3mS4/jGZI5n00uWOoSSFRhC1b6gl6xvmzUamgmqELraWp0J/qqVlXYPDPyA==} + ramda@0.30.1: resolution: {integrity: sha512-tEF5I22zJnuclswcZMc8bDIrwRHRzf+NqVEmqg50ShAZMP7MWeR/RGDthfM/p+BlqvF2fXAzpn8i+SJcYD3alw==} @@ -13328,6 +13334,9 @@ packages: peerDependencies: typescript: 4.6.x || 4.7.x || 4.8.x || 4.9.x || 5.0.x || 5.1.x || 5.2.x || 5.3.x || 5.4.x + types-ramda@0.29.10: + resolution: {integrity: sha512-5PJiW/eiTPyXXBYGZOYGezMl6qj7keBiZheRwfjJZY26QPHsNrjfJnz0mru6oeqqoTHOni893Jfd6zyUXfQRWg==} + types-ramda@0.30.1: resolution: {integrity: sha512-1HTsf5/QVRmLzcGfldPFvkVsAdi1db1BBKzi7iW3KBUlOICg/nKnFS+jGqDJS3YD8VsWbAh7JiHeBvbsw8RPxA==} @@ -20427,6 +20436,10 @@ snapshots: '@types/qs@6.9.7': {} + '@types/ramda@0.29.12': + dependencies: + types-ramda: 0.29.10 + '@types/ramda@0.30.1': dependencies: types-ramda: 0.30.1 @@ -29321,6 +29334,8 @@ snapshots: dependencies: performance-now: 2.1.0 + ramda@0.29.1: {} + ramda@0.30.1: {} randombytes@2.1.0: @@ -31377,6 +31392,10 @@ snapshots: shiki: 0.14.7 typescript: 5.4.5 + types-ramda@0.29.10: + dependencies: + ts-toolbelt: 9.6.0 + types-ramda@0.30.1: dependencies: ts-toolbelt: 9.6.0 From 2d24bcceac90579658496ce2d89395394a8e440d Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Mon, 29 Jul 2024 12:01:03 +0100 Subject: [PATCH 36/43] chore: updated changeset --- .changeset/tender-birds-tap.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.changeset/tender-birds-tap.md b/.changeset/tender-birds-tap.md index 89a5a867a24..8038e725ddc 100644 --- a/.changeset/tender-birds-tap.md +++ b/.changeset/tender-birds-tap.md @@ -1,5 +1,6 @@ --- "@fuel-ts/abi-coder": patch +"@fuel-ts/abi-typegen": patch --- -feat: implement `VoidCoder` +feat!: improve `()` and `Option` type handling From 8267d44cc2c58191a78c3f34e5ec689896150a5d Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Mon, 29 Jul 2024 13:35:40 +0100 Subject: [PATCH 37/43] chore: fix lock file --- pnpm-lock.yaml | 1519 ++++++++++++++++++++++++++---------------------- 1 file changed, 810 insertions(+), 709 deletions(-) diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index b63d0a4a367..549d1d9e6a4 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -151,7 +151,7 @@ importers: version: 0.1.1 tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.39)(ts-node@10.9.1(@types/node@20.14.11)(typescript@5.4.5))(typescript@5.4.5) + version: 6.7.0(postcss@8.4.40)(ts-node@10.9.1(@types/node@20.14.11)(typescript@5.4.5))(typescript@5.4.5) tsx: specifier: ^4.16.2 version: 4.16.2 @@ -166,10 +166,10 @@ importers: version: 5.3.5(@types/node@20.14.11)(terser@5.31.3) vite-plugin-json5: specifier: ^1.1.2 - version: 1.1.2(@rollup/pluginutils@5.1.0(rollup@4.19.0))(vite@5.3.5(@types/node@20.14.11)(terser@5.31.3)) + version: 1.1.2(@rollup/pluginutils@5.1.0(rollup@4.19.1))(vite@5.3.5(@types/node@20.14.11)(terser@5.31.3)) vite-plugin-node-polyfills: specifier: ^0.22.0 - version: 0.22.0(rollup@4.19.0)(vite@5.3.5(@types/node@20.14.11)(terser@5.31.3)) + version: 0.22.0(rollup@4.19.1)(vite@5.3.5(@types/node@20.14.11)(terser@5.31.3)) vite-plugin-plain-text: specifier: ^1.4.2 version: 1.4.2 @@ -184,7 +184,7 @@ importers: dependencies: '@fuels/connectors': specifier: ^0.8.1 - version: 0.8.1(kchncypvkqsbwvw6o5d5zxpqxa) + version: 0.8.1(oq6yvogrlhlckexnjtdkjthppq) '@fuels/react': specifier: ^0.20.0 version: 0.20.0(@tanstack/react-query@5.51.11(react@18.3.1))(@types/react-dom@18.3.0)(@types/react@18.3.3)(fuels@packages+fuels)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) @@ -377,7 +377,7 @@ importers: version: 5.59.0(eslint@8.57.0)(typescript@5.4.5) '@vitejs/plugin-react': specifier: ^4.3.1 - version: 4.3.1(vite@5.3.5(@types/node@20.14.11)(terser@5.31.3)) + version: 4.3.1(vite@5.3.5(@types/node@20.14.13)(terser@5.31.3)) eslint: specifier: ^8.57.0 version: 8.57.0 @@ -392,7 +392,7 @@ importers: version: 5.4.5 vite: specifier: ^5.3.5 - version: 5.3.5(@types/node@20.14.11)(terser@5.31.3) + version: 5.3.5(@types/node@20.14.13)(terser@5.31.3) apps/demo-typegen: dependencies: @@ -414,7 +414,7 @@ importers: dependencies: '@fuels/connectors': specifier: ^0.8.1 - version: 0.8.1(pcy7aobdmanrvrecamrxxtyms4) + version: 0.8.1(w265xd32dg4mkyoutfp3bgmoku) '@fuels/react': specifier: ^0.20.0 version: 0.20.0(@tanstack/react-query@5.51.11(react@18.3.1))(@types/react-dom@18.2.4)(@types/react@18.3.3)(fuels@packages+fuels)(react-dom@18.2.0(react@18.3.1))(react@18.3.1) @@ -497,10 +497,10 @@ importers: version: 5.1.0(typedoc@0.25.13(typescript@5.4.5)) vitepress: specifier: 1.3.1 - version: 1.3.1(@algolia/client-search@4.22.1)(@types/node@20.14.11)(@types/react@18.3.3)(change-case@4.1.2)(idb-keyval@6.2.1)(postcss@8.4.39)(qrcode@1.5.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(search-insights@2.11.0)(terser@5.31.3)(typescript@5.4.5) + version: 1.3.1(@algolia/client-search@4.22.1)(@types/node@20.14.13)(@types/react@18.3.3)(change-case@4.1.2)(idb-keyval@6.2.1)(postcss@8.4.40)(qrcode@1.5.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(search-insights@2.11.0)(terser@5.31.3)(typescript@5.4.5) vitepress-plugin-search: specifier: 1.0.4-alpha.19 - version: 1.0.4-alpha.19(flexsearch@0.7.43)(vitepress@1.3.1(@algolia/client-search@4.22.1)(@types/node@20.14.11)(@types/react@18.3.3)(change-case@4.1.2)(idb-keyval@6.2.1)(postcss@8.4.39)(qrcode@1.5.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(search-insights@2.11.0)(terser@5.31.3)(typescript@5.4.5))(vue@3.4.34(typescript@5.4.5)) + version: 1.0.4-alpha.19(flexsearch@0.7.43)(vitepress@1.3.1(@algolia/client-search@4.22.1)(@types/node@20.14.13)(@types/react@18.3.3)(change-case@4.1.2)(idb-keyval@6.2.1)(postcss@8.4.40)(qrcode@1.5.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(search-insights@2.11.0)(terser@5.31.3)(typescript@5.4.5))(vue@3.4.34(typescript@5.4.5)) vue: specifier: ^3.4.34 version: 3.4.34(typescript@5.4.5) @@ -524,7 +524,7 @@ importers: version: link:../../packages/fuels vitest: specifier: ^1.6.0 - version: 1.6.0(@types/node@20.14.11)(@vitest/browser@1.6.0)(jsdom@16.7.0(bufferutil@4.0.8)(utf-8-validate@6.0.4))(terser@5.31.3) + version: 1.6.0(@types/node@20.14.13)(@vitest/browser@1.6.0)(jsdom@16.7.0(bufferutil@4.0.8)(utf-8-validate@6.0.4))(terser@5.31.3) internal/check-imports: dependencies: @@ -738,7 +738,7 @@ importers: devDependencies: '@graphql-codegen/cli': specifier: ^5.0.2 - version: 5.0.2(@parcel/watcher@2.4.1)(@types/node@20.14.11)(bufferutil@4.0.8)(cosmiconfig-toml-loader@1.0.0)(enquirer@2.3.6)(graphql@16.9.0)(typescript@5.4.5)(utf-8-validate@6.0.4) + version: 5.0.2(@parcel/watcher@2.4.1)(@types/node@20.14.13)(bufferutil@4.0.8)(cosmiconfig-toml-loader@1.0.0)(enquirer@2.3.6)(graphql@16.9.0)(typescript@5.4.5)(utf-8-validate@6.0.4) '@graphql-codegen/typescript': specifier: ^4.0.9 version: 4.0.9(graphql@16.9.0) @@ -1000,7 +1000,7 @@ importers: version: 3.0.2 vite: specifier: ^5.3.5 - version: 5.3.5(@types/node@20.14.11)(terser@5.31.3) + version: 5.3.5(@types/node@20.14.13)(terser@5.31.3) packages/hasher: dependencies: @@ -1186,7 +1186,7 @@ importers: dependencies: '@fuels/connectors': specifier: ^0.8.1 - version: 0.8.1(kufw6iq3ny244gzkpb3pizcz2u) + version: 0.8.1(efp7nrq7ox7dlifkvza7hk62re) '@fuels/react': specifier: ^0.20.0 version: 0.20.0(@tanstack/react-query@5.51.11(react@18.3.1))(@types/react-dom@18.3.0)(@types/react@18.3.3)(fuels@packages+fuels)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) @@ -1391,8 +1391,8 @@ packages: resolution: {integrity: sha512-qJzAIcv03PyaWqxRgO4mSU3lihncDT296vnyuE2O8uA4w3UHWI4S3hgeZd1L8W1Bft40w9JxJ2b412iDUFFRhw==} engines: {node: '>=6.9.0'} - '@babel/compat-data@7.24.9': - resolution: {integrity: sha512-e701mcfApCJqMMueQI0Fb68Amflj83+dvAvHawoBpAz+GDjCIyGHzNwnefjsWJ3xiYAqqiQFoWbspGYBdb2/ng==} + '@babel/compat-data@7.25.0': + resolution: {integrity: sha512-P4fwKI2mjEb3ZU5cnMJzvRsRKGBUcs8jvxIoRmr6ufAY9Xk2Bz7JubRTTivkw55c7WQJfTECeqYVa+HZ0FzREg==} engines: {node: '>=6.9.0'} '@babel/core@7.22.5': @@ -1418,10 +1418,6 @@ packages: '@babel/core': '>=7.11.0' eslint: ^7.5.0 || ^8.0.0 - '@babel/generator@7.24.10': - resolution: {integrity: sha512-o9HBZL1G2129luEUlG1hB4N/nlYNWHnpwlND9eOMclRqqu1YDy2sSYVCFUZwl8I1Gxh+QSRrP2vD7EpUmFVXxg==} - engines: {node: '>=6.9.0'} - '@babel/generator@7.24.4': resolution: {integrity: sha512-Xd6+v6SnjWVx/nus+y0l1sxMOTOMBkyL4+BIdbALyatQnAe/SRVjANeDPSCYaX+i1iJmuGSKf3Z+E+V/va1Hvw==} engines: {node: '>=6.9.0'} @@ -1430,6 +1426,10 @@ packages: resolution: {integrity: sha512-oipXieGC3i45Y1A41t4tAqpnEZWgB/lC6Ehh6+rOviR5XWpTtMmLN+fGjz9vOiNRt0p6RtO6DtD0pdU3vpqdSA==} engines: {node: '>=6.9.0'} + '@babel/generator@7.25.0': + resolution: {integrity: sha512-3LEEcj3PVW8pW2R1SR1M89g/qrYk/m/mB/tLqn7dn4sbBUQyTqnlod+II2U4dqiGtUmkcnAmkMDralTFZttRiw==} + engines: {node: '>=6.9.0'} + '@babel/helper-annotate-as-pure@7.22.5': resolution: {integrity: sha512-LvBTxu8bQSQkcyKOU+a1btnNFQ1dMAd0R6PyW3arXes06F6QLWLIrd681bxRPIXlrMGR3XYnW9JyML7dP3qgxg==} engines: {node: '>=6.9.0'} @@ -1470,8 +1470,8 @@ packages: peerDependencies: '@babel/core': ^7.0.0 - '@babel/helper-create-class-features-plugin@7.24.8': - resolution: {integrity: sha512-4f6Oqnmyp2PP3olgUMmOwC3akxSm5aBYraQ6YDdKy7NcAMkDECHWG0DEnV6M2UAkERgIBhYt8S27rURPg7SxWA==} + '@babel/helper-create-class-features-plugin@7.25.0': + resolution: {integrity: sha512-GYM6BxeQsETc9mnct+nIIpf63SAyzvyYN7UB/IlTyd+MBg06afFGp0mIeUqGyWgS2mxad6vqbMrHVlaL3m70sQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 @@ -1482,8 +1482,8 @@ packages: peerDependencies: '@babel/core': ^7.0.0 - '@babel/helper-create-regexp-features-plugin@7.24.7': - resolution: {integrity: sha512-03TCmXy2FtXJEZfbXDTSqq1fRJArk7lX9DOFC/47VthYcxyIOx+eXQmdo6DOQvrbpIix+KfXwvuXdFDZHxt+rA==} + '@babel/helper-create-regexp-features-plugin@7.25.0': + resolution: {integrity: sha512-q0T+dknZS+L5LDazIP+02gEZITG5unzvb6yIjcmj5i0eFrs5ToBV2m2JGH4EsE/gtP8ygEGLGApBgRIZkTm7zg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 @@ -1570,8 +1570,8 @@ packages: peerDependencies: '@babel/core': ^7.0.0 - '@babel/helper-module-transforms@7.24.9': - resolution: {integrity: sha512-oYbh+rtFKj/HwBQkFlUzvcybzklmVdVV3UU+mN7n2t/q3yGHbuVdNxyFvSBO1tfvjyArpHNcWMAzsSPdyI46hw==} + '@babel/helper-module-transforms@7.25.0': + resolution: {integrity: sha512-bIkOa2ZJYn7FHnepzr5iX9Kmz8FjIz4UKzJ9zhX3dnYuVW0xul9RuR3skBfoLu+FPTQw90EHW9rJsSZhyLQ3fQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 @@ -1602,8 +1602,8 @@ packages: peerDependencies: '@babel/core': ^7.0.0 - '@babel/helper-remap-async-to-generator@7.24.7': - resolution: {integrity: sha512-9pKLcTlZ92hNZMQfGCHImUpDOlAgkkpqalWEeftW5FBya75k8Li2ilerxkM/uBEj01iBZXcCIB/bwvDYgWyibA==} + '@babel/helper-remap-async-to-generator@7.25.0': + resolution: {integrity: sha512-NhavI2eWEIz/H9dbrG0TuOicDhNexze43i5z7lEqwYm0WEZVTwnPpA0EafUTP7+6/W79HWIP2cTe3Z5NiSTVpw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 @@ -1612,8 +1612,8 @@ packages: resolution: {integrity: sha512-aLdNM5I3kdI/V9xGNyKSF3X/gTyMUBohTZ+/3QdQKAA9vxIiy12E+8E2HoOP1/DjeqU+g6as35QHJNMDDYpuCg==} engines: {node: '>=6.9.0'} - '@babel/helper-replace-supers@7.24.7': - resolution: {integrity: sha512-qTAxxBM81VEyoAY0TtLrx1oAEJc09ZK67Q9ljQToqCnA+55eNwCORaxlKyu+rNfX86o8OXRUSNUnrtsAZXM9sg==} + '@babel/helper-replace-supers@7.25.0': + resolution: {integrity: sha512-q688zIvQVYtZu+i2PsdIu/uWGRpfxzr5WESsfpShfZECkO+d2o+WROWezCi/Q6kJ0tfPa5+pUGUlfx2HhrA3Bg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 @@ -1690,8 +1690,8 @@ packages: resolution: {integrity: sha512-bYqLIBSEshYcYQyfks8ewYA8S30yaGSeRslcvKMvoUk6HHPySbxHq9YRi6ghhzEU+yhQv9bP/jXnygkStOcqZw==} engines: {node: '>=6.9.0'} - '@babel/helper-wrap-function@7.24.7': - resolution: {integrity: sha512-N9JIYk3TD+1vq/wn77YnJOqMtfWhNewNE+DJV4puD2X7Ew9J4JvrzrFDfTfyv5EgEXVy9/Wt8QiOErzEmv5Ifw==} + '@babel/helper-wrap-function@7.25.0': + resolution: {integrity: sha512-s6Q1ebqutSiZnEjaofc/UKDyC4SbzV5n5SrA2Gq8UawLycr3i04f1dX4OzoQVnexm6aOCh37SQNYlJ/8Ku+PMQ==} engines: {node: '>=6.9.0'} '@babel/helpers@7.22.5': @@ -1706,8 +1706,8 @@ packages: resolution: {integrity: sha512-NlmJJtvcw72yRJRcnCmGvSi+3jDEg8qFu3z0AFoymmzLx5ERVWyzd9kVXr7Th9/8yIJi2Zc6av4Tqz3wFs8QWg==} engines: {node: '>=6.9.0'} - '@babel/helpers@7.24.8': - resolution: {integrity: sha512-gV2265Nkcz7weJJfvDoAEVzC1e2OTDpkGbEsebse8koXUJUXPsCMi7sRo/+SPMuMZ9MtUPnGwITTnQnU5YjyaQ==} + '@babel/helpers@7.25.0': + resolution: {integrity: sha512-MjgLZ42aCm0oGjJj8CtSM3DB8NOOf8h2l7DCTePJs29u+v7yO/RBX9nShlKMgFnRks/Q4tBAe7Hxnov9VkGwLw==} engines: {node: '>=6.9.0'} '@babel/highlight@7.22.5': @@ -1741,8 +1741,8 @@ packages: engines: {node: '>=6.0.0'} hasBin: true - '@babel/parser@7.24.8': - resolution: {integrity: sha512-WzfbgXOkGzZiXXCqk43kKwZjzwx4oulxZi3nq2TYL9mOjQv6kYwul9mz6ID36njuL7Xkp6nJEfok848Zj10j/w==} + '@babel/parser@7.25.0': + resolution: {integrity: sha512-CzdIU9jdP0dg7HdyB+bHvDJGagUv+qtzZt5rYCWwW6tITNqV9odjp6Qu41gkG0ca5UfdDUWrKkiAnHHdGRnOrA==} engines: {node: '>=6.0.0'} hasBin: true @@ -2056,8 +2056,8 @@ packages: peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-block-scoping@7.24.7': - resolution: {integrity: sha512-Nd5CvgMbWc+oWzBsuaMcbwjJWAcp5qzrbg69SZdHSP7AMY0AbWFqFO0WTFCA1jxhMCwodRwvRec8k0QUbZk7RQ==} + '@babel/plugin-transform-block-scoping@7.25.0': + resolution: {integrity: sha512-yBQjYoOjXlFv9nlXb3f1casSHOZkWr29NX+zChVanLg5Nc157CrbEX9D7hxxtTpuFy7Q0YzmmWfJxzvps4kXrQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 @@ -2080,8 +2080,8 @@ packages: peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-classes@7.24.8': - resolution: {integrity: sha512-VXy91c47uujj758ud9wx+OMgheXm4qJfyhj1P18YvlrQkNOSrwsteHk+EFS3OMGfhMhpZa0A+81eE7G4QC+3CA==} + '@babel/plugin-transform-classes@7.25.0': + resolution: {integrity: sha512-xyi6qjr/fYU304fiRwFbekzkqVJZ6A7hOjWZd+89FVcBqPV3S9Wuozz82xdpLspckeaafntbzglaW4pqpzvtSw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 @@ -2170,8 +2170,8 @@ packages: peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-function-name@7.24.7': - resolution: {integrity: sha512-U9FcnA821YoILngSmYkW6FjyQe2TyZD5pHt4EVIhmcTkrJw/3KqcrRSxuOo5tFZJi7TE19iDyI1u+weTI7bn2w==} + '@babel/plugin-transform-function-name@7.25.1': + resolution: {integrity: sha512-TVVJVdW9RKMNgJJlLtHsKDTydjZAbwIsn6ySBPQaEAUU5+gVvlJt/9nRmqVbsV/IBanRjzWoaAQKLoamWVOUuA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 @@ -2476,8 +2476,8 @@ packages: peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-typescript@7.24.8': - resolution: {integrity: sha512-CgFgtN61BbdOGCP4fLaAMOPkzWUh6yQZNMr5YSt8uz2cZSSiQONCQFWqsE4NeVfOIhqDOlS9CR3WD91FzMeB2Q==} + '@babel/plugin-transform-typescript@7.25.0': + resolution: {integrity: sha512-LZicxFzHIw+Sa3pzgMgSz6gdpsdkfiMObHUzhSIrwKF0+/rP/nuR49u79pSS+zIFJ1FeGeqQD2Dq4QGFbOVvSw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 @@ -2572,6 +2572,10 @@ packages: resolution: {integrity: sha512-5F7SDGs1T72ZczbRwbGO9lQi0NLjQxzl6i4lJxLxfW9U5UluCSyEJeniWvnhl3/euNiqQVbo8zruhsDfid0esA==} engines: {node: '>=6.9.0'} + '@babel/runtime@7.25.0': + resolution: {integrity: sha512-7dRy4DwXwtzBrPbZflqxnvfxLF8kdZXPkhymtDeFoFqE6ldzjQFgYTtYIFARcLEYDrqfBfYcZt1WqFxRoyC9Rw==} + engines: {node: '>=6.9.0'} + '@babel/template@7.24.6': resolution: {integrity: sha512-3vgazJlLwNXi9jhrR1ef8qiB65L1RK90+lEQwv4OxveHnqC3BfmnHdgySwRLzf6akhlOYenT+b7AfWq+a//AHw==} engines: {node: '>=6.9.0'} @@ -2580,6 +2584,10 @@ packages: resolution: {integrity: sha512-jYqfPrU9JTF0PmPy1tLYHW4Mp4KlgxJD9l2nP9fD6yT/ICi554DmrWBAEYpIelzjHf1msDP3PxJIRt/nFNfBig==} engines: {node: '>=6.9.0'} + '@babel/template@7.25.0': + resolution: {integrity: sha512-aOOgh1/5XzKvg1jvVz7AVrx2piJ2XBi227DHmbY6y+bM9H2FlN+IfecYu4Xl0cNiiVejlsCri89LUsbj8vJD9Q==} + engines: {node: '>=6.9.0'} + '@babel/traverse@7.22.5': resolution: {integrity: sha512-7DuIjPgERaNo6r+PZwItpjCZEa5vyw4eJGufeLxrPdBXBoLcCJCIasvK6pK/9DVNrLZTLFhUGqaC6X/PA007TQ==} engines: {node: '>=6.9.0'} @@ -2592,8 +2600,8 @@ packages: resolution: {integrity: sha512-yb65Ed5S/QAcewNPh0nZczy9JdYXkkAbIsEo+P7BE7yO3txAY30Y/oPa3QkQ5It3xVG2kpKMg9MsdxZaO31uKA==} engines: {node: '>=6.9.0'} - '@babel/traverse@7.24.8': - resolution: {integrity: sha512-t0P1xxAPzEDcEPmjprAQq19NWum4K0EQPjMwZQZbHt+GiZqvjCHjj755Weq1YRPVzBI+3zSfvScfpnuIecVFJQ==} + '@babel/traverse@7.25.1': + resolution: {integrity: sha512-LrHHoWq08ZpmmFqBAzN+hUdWwy5zt7FGa/hVwMcOqW6OVtwqaoD5utfuGYU87JYxdZgLUvktAsn37j/sYR9siA==} engines: {node: '>=6.9.0'} '@babel/types@7.24.6': @@ -2604,8 +2612,8 @@ packages: resolution: {integrity: sha512-XEFXSlxiG5td2EJRe8vOmRbaXVgfcBlszKujvVmWIK/UpywWljQCfzAv3RQCGujWQ1RD4YYWEAqDXfuJiy8f5Q==} engines: {node: '>=6.9.0'} - '@babel/types@7.24.9': - resolution: {integrity: sha512-xm8XrMKz0IlUdocVbYJe0Z9xEgidU7msskG8BbhnTPK/HZ2z/7FP7ykqPgrUH+C+r414mNfNWam1f2vqOjqjYQ==} + '@babel/types@7.25.0': + resolution: {integrity: sha512-LcnxQSsd9aXOIgmmSpvZ/1yo46ra2ESYyqLcryaBZOghxy5qqOBjvCWP5JfkI8yl9rlxRgdLTTMCQQRcN2hdCg==} engines: {node: '>=6.9.0'} '@bcoe/v8-coverage@0.2.3': @@ -4631,83 +4639,83 @@ packages: rollup: optional: true - '@rollup/rollup-android-arm-eabi@4.19.0': - resolution: {integrity: sha512-JlPfZ/C7yn5S5p0yKk7uhHTTnFlvTgLetl2VxqE518QgyM7C9bSfFTYvB/Q/ftkq0RIPY4ySxTz+/wKJ/dXC0w==} + '@rollup/rollup-android-arm-eabi@4.19.1': + resolution: {integrity: sha512-XzqSg714++M+FXhHfXpS1tDnNZNpgxxuGZWlRG/jSj+VEPmZ0yg6jV4E0AL3uyBKxO8mO3xtOsP5mQ+XLfrlww==} cpu: [arm] os: [android] - '@rollup/rollup-android-arm64@4.19.0': - resolution: {integrity: sha512-RDxUSY8D1tWYfn00DDi5myxKgOk6RvWPxhmWexcICt/MEC6yEMr4HNCu1sXXYLw8iAsg0D44NuU+qNq7zVWCrw==} + '@rollup/rollup-android-arm64@4.19.1': + resolution: {integrity: sha512-thFUbkHteM20BGShD6P08aungq4irbIZKUNbG70LN8RkO7YztcGPiKTTGZS7Kw+x5h8hOXs0i4OaHwFxlpQN6A==} cpu: [arm64] os: [android] - '@rollup/rollup-darwin-arm64@4.19.0': - resolution: {integrity: sha512-emvKHL4B15x6nlNTBMtIaC9tLPRpeA5jMvRLXVbl/W9Ie7HhkrE7KQjvgS9uxgatL1HmHWDXk5TTS4IaNJxbAA==} + '@rollup/rollup-darwin-arm64@4.19.1': + resolution: {integrity: sha512-8o6eqeFZzVLia2hKPUZk4jdE3zW7LCcZr+MD18tXkgBBid3lssGVAYuox8x6YHoEPDdDa9ixTaStcmx88lio5Q==} cpu: [arm64] os: [darwin] - '@rollup/rollup-darwin-x64@4.19.0': - resolution: {integrity: sha512-fO28cWA1dC57qCd+D0rfLC4VPbh6EOJXrreBmFLWPGI9dpMlER2YwSPZzSGfq11XgcEpPukPTfEVFtw2q2nYJg==} + '@rollup/rollup-darwin-x64@4.19.1': + resolution: {integrity: sha512-4T42heKsnbjkn7ovYiAdDVRRWZLU9Kmhdt6HafZxFcUdpjlBlxj4wDrt1yFWLk7G4+E+8p2C9tcmSu0KA6auGA==} cpu: [x64] os: [darwin] - '@rollup/rollup-linux-arm-gnueabihf@4.19.0': - resolution: {integrity: sha512-2Rn36Ubxdv32NUcfm0wB1tgKqkQuft00PtM23VqLuCUR4N5jcNWDoV5iBC9jeGdgS38WK66ElncprqgMUOyomw==} + '@rollup/rollup-linux-arm-gnueabihf@4.19.1': + resolution: {integrity: sha512-MXg1xp+e5GhZ3Vit1gGEyoC+dyQUBy2JgVQ+3hUrD9wZMkUw/ywgkpK7oZgnB6kPpGrxJ41clkPPnsknuD6M2Q==} cpu: [arm] os: [linux] - '@rollup/rollup-linux-arm-musleabihf@4.19.0': - resolution: {integrity: sha512-gJuzIVdq/X1ZA2bHeCGCISe0VWqCoNT8BvkQ+BfsixXwTOndhtLUpOg0A1Fcx/+eA6ei6rMBzlOz4JzmiDw7JQ==} + '@rollup/rollup-linux-arm-musleabihf@4.19.1': + resolution: {integrity: sha512-DZNLwIY4ftPSRVkJEaxYkq7u2zel7aah57HESuNkUnz+3bZHxwkCUkrfS2IWC1sxK6F2QNIR0Qr/YXw7nkF3Pw==} cpu: [arm] os: [linux] - '@rollup/rollup-linux-arm64-gnu@4.19.0': - resolution: {integrity: sha512-0EkX2HYPkSADo9cfeGFoQ7R0/wTKb7q6DdwI4Yn/ULFE1wuRRCHybxpl2goQrx4c/yzK3I8OlgtBu4xvted0ug==} + '@rollup/rollup-linux-arm64-gnu@4.19.1': + resolution: {integrity: sha512-C7evongnjyxdngSDRRSQv5GvyfISizgtk9RM+z2biV5kY6S/NF/wta7K+DanmktC5DkuaJQgoKGf7KUDmA7RUw==} cpu: [arm64] os: [linux] - '@rollup/rollup-linux-arm64-musl@4.19.0': - resolution: {integrity: sha512-GlIQRj9px52ISomIOEUq/IojLZqzkvRpdP3cLgIE1wUWaiU5Takwlzpz002q0Nxxr1y2ZgxC2obWxjr13lvxNQ==} + '@rollup/rollup-linux-arm64-musl@4.19.1': + resolution: {integrity: sha512-89tFWqxfxLLHkAthAcrTs9etAoBFRduNfWdl2xUs/yLV+7XDrJ5yuXMHptNqf1Zw0UCA3cAutkAiAokYCkaPtw==} cpu: [arm64] os: [linux] - '@rollup/rollup-linux-powerpc64le-gnu@4.19.0': - resolution: {integrity: sha512-N6cFJzssruDLUOKfEKeovCKiHcdwVYOT1Hs6dovDQ61+Y9n3Ek4zXvtghPPelt6U0AH4aDGnDLb83uiJMkWYzQ==} + '@rollup/rollup-linux-powerpc64le-gnu@4.19.1': + resolution: {integrity: sha512-PromGeV50sq+YfaisG8W3fd+Cl6mnOOiNv2qKKqKCpiiEke2KiKVyDqG/Mb9GWKbYMHj5a01fq/qlUR28PFhCQ==} cpu: [ppc64] os: [linux] - '@rollup/rollup-linux-riscv64-gnu@4.19.0': - resolution: {integrity: sha512-2DnD3mkS2uuam/alF+I7M84koGwvn3ZVD7uG+LEWpyzo/bq8+kKnus2EVCkcvh6PlNB8QPNFOz6fWd5N8o1CYg==} + '@rollup/rollup-linux-riscv64-gnu@4.19.1': + resolution: {integrity: sha512-/1BmHYh+iz0cNCP0oHCuF8CSiNj0JOGf0jRlSo3L/FAyZyG2rGBuKpkZVH9YF+x58r1jgWxvm1aRg3DHrLDt6A==} cpu: [riscv64] os: [linux] - '@rollup/rollup-linux-s390x-gnu@4.19.0': - resolution: {integrity: sha512-D6pkaF7OpE7lzlTOFCB2m3Ngzu2ykw40Nka9WmKGUOTS3xcIieHe82slQlNq69sVB04ch73thKYIWz/Ian8DUA==} + '@rollup/rollup-linux-s390x-gnu@4.19.1': + resolution: {integrity: sha512-0cYP5rGkQWRZKy9/HtsWVStLXzCF3cCBTRI+qRL8Z+wkYlqN7zrSYm6FuY5Kd5ysS5aH0q5lVgb/WbG4jqXN1Q==} cpu: [s390x] os: [linux] - '@rollup/rollup-linux-x64-gnu@4.19.0': - resolution: {integrity: sha512-HBndjQLP8OsdJNSxpNIN0einbDmRFg9+UQeZV1eiYupIRuZsDEoeGU43NQsS34Pp166DtwQOnpcbV/zQxM+rWA==} + '@rollup/rollup-linux-x64-gnu@4.19.1': + resolution: {integrity: sha512-XUXeI9eM8rMP8aGvii/aOOiMvTs7xlCosq9xCjcqI9+5hBxtjDpD+7Abm1ZhVIFE1J2h2VIg0t2DX/gjespC2Q==} cpu: [x64] os: [linux] - '@rollup/rollup-linux-x64-musl@4.19.0': - resolution: {integrity: sha512-HxfbvfCKJe/RMYJJn0a12eiOI9OOtAUF4G6ozrFUK95BNyoJaSiBjIOHjZskTUffUrB84IPKkFG9H9nEvJGW6A==} + '@rollup/rollup-linux-x64-musl@4.19.1': + resolution: {integrity: sha512-V7cBw/cKXMfEVhpSvVZhC+iGifD6U1zJ4tbibjjN+Xi3blSXaj/rJynAkCFFQfoG6VZrAiP7uGVzL440Q6Me2Q==} cpu: [x64] os: [linux] - '@rollup/rollup-win32-arm64-msvc@4.19.0': - resolution: {integrity: sha512-HxDMKIhmcguGTiP5TsLNolwBUK3nGGUEoV/BO9ldUBoMLBssvh4J0X8pf11i1fTV7WShWItB1bKAKjX4RQeYmg==} + '@rollup/rollup-win32-arm64-msvc@4.19.1': + resolution: {integrity: sha512-88brja2vldW/76jWATlBqHEoGjJLRnP0WOEKAUbMcXaAZnemNhlAHSyj4jIwMoP2T750LE9lblvD4e2jXleZsA==} cpu: [arm64] os: [win32] - '@rollup/rollup-win32-ia32-msvc@4.19.0': - resolution: {integrity: sha512-xItlIAZZaiG/u0wooGzRsx11rokP4qyc/79LkAOdznGRAbOFc+SfEdfUOszG1odsHNgwippUJavag/+W/Etc6Q==} + '@rollup/rollup-win32-ia32-msvc@4.19.1': + resolution: {integrity: sha512-LdxxcqRVSXi6k6JUrTah1rHuaupoeuiv38du8Mt4r4IPer3kwlTo+RuvfE8KzZ/tL6BhaPlzJ3835i6CxrFIRQ==} cpu: [ia32] os: [win32] - '@rollup/rollup-win32-x64-msvc@4.19.0': - resolution: {integrity: sha512-xNo5fV5ycvCCKqiZcpB65VMR11NJB+StnxHz20jdqRAktfdfzhgjTiJ2doTDQE/7dqGaV5I7ZGqKpgph6lCIag==} + '@rollup/rollup-win32-x64-msvc@4.19.1': + resolution: {integrity: sha512-2bIrL28PcK3YCqD9anGxDxamxdiJAxA+l7fWIwM5o8UqNy1t3d1NdAweO2XhA0KTDJ5aH1FsuiT5+7VhtHliXg==} cpu: [x64] os: [win32] @@ -4723,8 +4731,8 @@ packages: '@safe-global/safe-apps-sdk@8.1.0': resolution: {integrity: sha512-XJbEPuaVc7b9n23MqlF6c+ToYIS3f7P2Sel8f3cSBQ9WORE4xrSuvhMpK9fDSFqJ7by/brc+rmJR/5HViRr0/w==} - '@safe-global/safe-gateway-typescript-sdk@3.22.0': - resolution: {integrity: sha512-QKgucFMloZ7S23X70U6OmFaRxfX2O52xBAZFIDeW9n+uiANG+JYUiJv6UC0/eVNto+CU/dOVnpqRDhr6/ElKDg==} + '@safe-global/safe-gateway-typescript-sdk@3.22.1': + resolution: {integrity: sha512-YApSpx+3h6uejrJVh8PSqXRRAwmsWz8PZERObMGJNC9NPoMhZG/Rvqb2UWmVLrjFh880rqutsB+GrTmJP351PA==} engines: {node: '>=16'} '@scure/base@1.1.6': @@ -5188,6 +5196,9 @@ packages: '@types/node@18.15.13': resolution: {integrity: sha512-N+0kuo9KgrUQ1Sn/ifDXsvg0TTleP7rIy4zOBGECxAljqvqfqpTfzx0Q1NUedOixRMBfe2Whhb056a42cWs26Q==} + '@types/node@18.19.42': + resolution: {integrity: sha512-d2ZFc/3lnK2YCYhos8iaNIYu9Vfhr92nHiyJHRltXWjXUBjEE+A4I58Tdbnw4VhggSW+2j5y5gTrLs4biNnubg==} + '@types/node@20.10.5': resolution: {integrity: sha512-nNPsNE65wjMxEKI93yOP+NPGGBJz/PoN3kZsVLee0XMiJolxSekEVD8wRwBUBqkwc7UWop0edW50yrCQW4CyRw==} @@ -5197,6 +5208,9 @@ packages: '@types/node@20.14.11': resolution: {integrity: sha512-kprQpL8MMeszbz6ojB5/tU8PLN4kesnN8Gjzw349rDlNgsSzg90lAVj3llK99Dh7JON+t9AuscPPFW6mPbTnSA==} + '@types/node@20.14.13': + resolution: {integrity: sha512-+bHoGiZb8UiQ0+WEtmph2IWQCjIqg8MDZMAV+ppRRhUZnquF5mQkP/9vpSwJClEiSM/C7fZZExPzfU0vJTyp8w==} + '@types/parse-json@4.0.0': resolution: {integrity: sha512-//oorEZjL6sbPcKUaCdIGlIUeH26mgzimjBB77G6XRgnDl/L5wOnpyBGRe/Mmf5CVW3PwEBE1NjiMZ/ssFh4wA==} @@ -6546,7 +6560,6 @@ packages: bun@1.1.21: resolution: {integrity: sha512-mvqYEvafGskIVTjlftbKvsXtyR6z/SQnhJsVw0xCU46pc56oX1sAGvaemWKOy/sy/gGMHcgLE0KUidDQQzqXWQ==} - cpu: [arm64, x64] os: [darwin, linux, win32] hasBin: true @@ -6950,8 +6963,8 @@ packages: convert-source-map@2.0.0: resolution: {integrity: sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==} - cookie-es@1.2.1: - resolution: {integrity: sha512-ilTPDuxhZX44BSzzRB58gvSY2UevZKQM9fjisn7Z+NJ92CtSU6kO1+22ZN/agbEJANFjK85EiJJbi/gQv18OXA==} + cookie-es@1.2.2: + resolution: {integrity: sha512-+W7VmiVINB+ywl1HGXJXmrqkOhpKrIiVZV6tQuV54ZyQC7MMuBt81Vc336GMLoHBq5hV/F9eXgt5Mnx0Rha5Fg==} cookie-signature@1.0.6: resolution: {integrity: sha512-QADzlaHc8icV8I7vbaJXJwod9HWYp8uCqf1xa4OfNu1T7JVxQIrUgOWtHdNDtPiywmFbiS12VjotIXLrKM3orQ==} @@ -7279,6 +7292,15 @@ packages: supports-color: optional: true + debug@4.3.6: + resolution: {integrity: sha512-O/09Bd4Z1fBrU4VzkhFqVgpPzaGbw6Sm9FEkBT1A/YBXQFGuuSxa1dN2nxgxS34JmKXqYx8CZAwEVoJFImUXIg==} + engines: {node: '>=6.0'} + peerDependencies: + supports-color: '*' + peerDependenciesMeta: + supports-color: + optional: true + decamelize@1.2.0: resolution: {integrity: sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA==} engines: {node: '>=0.10.0'} @@ -7567,8 +7589,8 @@ packages: electron-to-chromium@1.4.747: resolution: {integrity: sha512-+FnSWZIAvFHbsNVmUxhEqWiaOiPMcfum1GQzlWCg/wLigVtshOsjXHyEFfmt6cFK6+HkS3QOJBv6/3OPumbBfw==} - electron-to-chromium@1.5.0: - resolution: {integrity: sha512-Vb3xHHYnLseK8vlMJQKJYXJ++t4u1/qJ3vykuVrVjvdiOEhYyT1AuP4x03G8EnPmYvYOhe9T+dADTmthjRQMkA==} + electron-to-chromium@1.5.2: + resolution: {integrity: sha512-kc4r3U3V3WLaaZqThjYz/Y6z8tJe+7K0bbjUVo3i+LWIypVdMx5nXCkwRe6SWbY6ILqLdc1rKcKmr3HoH7wjSQ==} elliptic@6.5.4: resolution: {integrity: sha512-iLhC6ULemrljPZb+QutR5TQGB+pdW6KGD5RSegS+8sorOZT+rdQFbsQFJgvN3eRqNALqJer4oQ16YvJHlU8hzQ==} @@ -8149,8 +8171,8 @@ packages: fast-url-parser@1.1.3: resolution: {integrity: sha512-5jOCVXADYNuRkKFzNJ0dCCewsZiYo0dz8QNYljkOpFC6r2U4OBmKtvm/Tsuh4w1YYdDqDb31a8TVhBJ2OJKdqQ==} - fast-xml-parser@4.4.0: - resolution: {integrity: sha512-kLY3jFlwIYwBNDojclKsNAC12sfD6NwW74QB2CoNGPvtVxjliYehVunB3HYyNi+n4Tt1dAcgwYvmKF/Z18flqg==} + fast-xml-parser@4.4.1: + resolution: {integrity: sha512-xkjOecfnKGkSsOwtZ5Pz7Us/T6mrbPQrq0nh+aCO5V9nk5NLWmasAHumTKjiPJPWANe+kAZ84Jc8ooJkzZ88Sw==} hasBin: true fastest-stable-stringify@2.0.2: @@ -11511,15 +11533,15 @@ packages: resolution: {integrity: sha512-Kkpbhhdjw2qQs2O2DGX+8m5OVqEcbB9HRBvuYM9pgrjEFUg30A9LmXNlTAUj4S9kgtGyrMbTzVjH7E+s5Re2yg==} engines: {node: ^10 || ^12 || >=14} - postcss@8.4.39: - resolution: {integrity: sha512-0vzE+lAiG7hZl1/9I8yzKLx3aR9Xbof3fBHKunvMfOCYAtMhrsnccJY2iTURb9EZd5+pLuiNV9/c/GZJOHsgIw==} + postcss@8.4.40: + resolution: {integrity: sha512-YF2kKIUzAofPMpfH6hOi2cGnv/HrUlfucspc7pDyvv7kGdqXrfj8SCl/t8owkEgKEuu8ZcRjSOxFxVLqwChZ2Q==} engines: {node: ^10 || ^12 || >=14} preact@10.22.0: resolution: {integrity: sha512-RRurnSjJPj4rp5K6XoP45Ui33ncb7e4H7WiOHVpjbkvqvA3U+N8Z6Qbo0AE6leGYBV66n8EhEaFixvIu3SkxFw==} - preact@10.22.1: - resolution: {integrity: sha512-jRYbDDgMpIb5LHq3hkI0bbl+l/TQ9UnkdQ0ww+lp+4MMOdqaUYdFc5qeyP+IV8FAd/2Em7drVPeKdQxsiWCf/A==} + preact@10.23.1: + resolution: {integrity: sha512-O5UdRsNh4vdZaTieWe3XOgSpdMAmkIYBCT3VhQDlKrzyCm8lUYsk0fmVEvoQQifoOjFRTaHZO69ylrzTW2BH+A==} preferred-pm@3.0.3: resolution: {integrity: sha512-+wZgbxNES/KlJs9q40F/1sfOd/j7f1O9JaHcW5Dsn3aUUOZg3L2bjpVUcKV2jvtElYfoTuQiNeMfQJ4kwUAhCQ==} @@ -12183,8 +12205,8 @@ packages: engines: {node: '>=14.18.0', npm: '>=8.0.0'} hasBin: true - rollup@4.19.0: - resolution: {integrity: sha512-5r7EYSQIowHsK4eTZ0Y81qpZuJz+MUuYeqmmYmRMl1nwhdmbiYqt5jwzf6u7wyOzJgYqtCRMtVRKOtHANBz7rA==} + rollup@4.19.1: + resolution: {integrity: sha512-K5vziVlg7hTpYfFBI+91zHBEMo6jafYXpkMlqZjg7/zhIG9iHqazBf4xz9AVdjS9BruRn280ROqLI7G3OFRIlw==} engines: {node: '>=18.0.0', npm: '>=8.0.0'} hasBin: true @@ -14180,8 +14202,8 @@ packages: resolution: {integrity: sha512-2eHWfjaoXgTBC2jNM1LRef62VQa0umtvRiDSk6HSzW7RvS5YtkabJrwYLLEKWBc8a5U2PTSCs+dJjUTJdlHsWQ==} engines: {node: '>= 14'} - yaml@2.4.5: - resolution: {integrity: sha512-aBx2bnqDzVOyNKfsysjA2ms5ZlnjSAW2eG3/L5G/CSujfjLJTJsEw1bGw8kCf04KodQWk1pxlGnZ56CRxiawmg==} + yaml@2.5.0: + resolution: {integrity: sha512-2wWLbGbYDiSqqIKoPjar3MPgB94ErzCtrNE1FdqGuaO0pi2JGjmE8aW8TDZwzU7vuxcGRdL/4gPQwQ7hD5AMSw==} engines: {node: '>= 14'} hasBin: true @@ -14403,10 +14425,10 @@ snapshots: dependencies: '@babel/core': 7.24.4 '@babel/generator': 7.24.4 - '@babel/parser': 7.24.8 + '@babel/parser': 7.25.0 '@babel/runtime': 7.24.8 '@babel/traverse': 7.24.1 - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 babel-preset-fbjs: 3.4.0(@babel/core@7.24.4) chalk: 4.1.2 fb-watchman: 2.0.2 @@ -14460,7 +14482,7 @@ snapshots: '@babel/compat-data@7.24.7': {} - '@babel/compat-data@7.24.9': {} + '@babel/compat-data@7.25.0': {} '@babel/core@7.22.5': dependencies: @@ -14490,7 +14512,7 @@ snapshots: '@babel/helper-compilation-targets': 7.23.6 '@babel/helper-module-transforms': 7.23.3(@babel/core@7.24.4) '@babel/helpers': 7.24.4 - '@babel/parser': 7.24.8 + '@babel/parser': 7.25.0 '@babel/template': 7.24.6 '@babel/traverse': 7.24.1 '@babel/types': 7.24.6 @@ -14526,16 +14548,16 @@ snapshots: dependencies: '@ampproject/remapping': 2.3.0 '@babel/code-frame': 7.24.7 - '@babel/generator': 7.24.10 + '@babel/generator': 7.25.0 '@babel/helper-compilation-targets': 7.24.8 - '@babel/helper-module-transforms': 7.24.9(@babel/core@7.24.9) - '@babel/helpers': 7.24.8 - '@babel/parser': 7.24.8 - '@babel/template': 7.24.7 - '@babel/traverse': 7.24.8 - '@babel/types': 7.24.9 + '@babel/helper-module-transforms': 7.25.0(@babel/core@7.24.9) + '@babel/helpers': 7.25.0 + '@babel/parser': 7.25.0 + '@babel/template': 7.25.0 + '@babel/traverse': 7.25.1 + '@babel/types': 7.25.0 convert-source-map: 2.0.0 - debug: 4.3.5(supports-color@5.5.0) + debug: 4.3.6 gensync: 1.0.0-beta.2 json5: 2.2.3 semver: 6.3.1 @@ -14550,42 +14572,42 @@ snapshots: eslint-visitor-keys: 2.1.0 semver: 6.3.1 - '@babel/generator@7.24.10': + '@babel/generator@7.24.4': dependencies: - '@babel/types': 7.24.9 + '@babel/types': 7.24.6 '@jridgewell/gen-mapping': 0.3.5 '@jridgewell/trace-mapping': 0.3.25 jsesc: 2.5.2 - '@babel/generator@7.24.4': + '@babel/generator@7.24.7': dependencies: - '@babel/types': 7.24.6 + '@babel/types': 7.24.7 '@jridgewell/gen-mapping': 0.3.5 '@jridgewell/trace-mapping': 0.3.25 jsesc: 2.5.2 - '@babel/generator@7.24.7': + '@babel/generator@7.25.0': dependencies: - '@babel/types': 7.24.7 + '@babel/types': 7.25.0 '@jridgewell/gen-mapping': 0.3.5 '@jridgewell/trace-mapping': 0.3.25 jsesc: 2.5.2 '@babel/helper-annotate-as-pure@7.22.5': dependencies: - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/helper-annotate-as-pure@7.24.6': dependencies: - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/helper-annotate-as-pure@7.24.7': dependencies: - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/helper-builder-binary-assignment-operator-visitor@7.22.5': dependencies: - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/helper-compilation-targets@7.22.5(@babel/core@7.22.5)': dependencies: @@ -14632,7 +14654,7 @@ snapshots: '@babel/helper-compilation-targets@7.24.8': dependencies: - '@babel/compat-data': 7.24.9 + '@babel/compat-data': 7.25.0 '@babel/helper-validator-option': 7.24.8 browserslist: 4.23.2 lru-cache: 5.1.1 @@ -14683,17 +14705,15 @@ snapshots: transitivePeerDependencies: - supports-color - '@babel/helper-create-class-features-plugin@7.24.8(@babel/core@7.24.9)': + '@babel/helper-create-class-features-plugin@7.25.0(@babel/core@7.24.9)': dependencies: '@babel/core': 7.24.9 '@babel/helper-annotate-as-pure': 7.24.7 - '@babel/helper-environment-visitor': 7.24.7 - '@babel/helper-function-name': 7.24.7 '@babel/helper-member-expression-to-functions': 7.24.8 '@babel/helper-optimise-call-expression': 7.24.7 - '@babel/helper-replace-supers': 7.24.7(@babel/core@7.24.9) + '@babel/helper-replace-supers': 7.25.0(@babel/core@7.24.9) '@babel/helper-skip-transparent-expression-wrappers': 7.24.7 - '@babel/helper-split-export-declaration': 7.24.7 + '@babel/traverse': 7.25.1 semver: 6.3.1 transitivePeerDependencies: - supports-color @@ -14712,7 +14732,7 @@ snapshots: regexpu-core: 5.3.2 semver: 6.3.1 - '@babel/helper-create-regexp-features-plugin@7.24.7(@babel/core@7.24.9)': + '@babel/helper-create-regexp-features-plugin@7.25.0(@babel/core@7.24.9)': dependencies: '@babel/core': 7.24.9 '@babel/helper-annotate-as-pure': 7.24.7 @@ -14748,7 +14768,7 @@ snapshots: '@babel/core': 7.24.9 '@babel/helper-compilation-targets': 7.24.8 '@babel/helper-plugin-utils': 7.24.8 - debug: 4.3.5(supports-color@5.5.0) + debug: 4.3.6 lodash.debounce: 4.0.8 resolve: 1.22.8 transitivePeerDependencies: @@ -14762,54 +14782,54 @@ snapshots: '@babel/helper-environment-visitor@7.24.7': dependencies: - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/helper-function-name@7.22.5': dependencies: '@babel/template': 7.24.6 - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/helper-function-name@7.24.6': dependencies: '@babel/template': 7.24.6 - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/helper-function-name@7.24.7': dependencies: '@babel/template': 7.24.7 - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/helper-hoist-variables@7.22.5': dependencies: - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/helper-hoist-variables@7.24.7': dependencies: - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/helper-member-expression-to-functions@7.22.5': dependencies: - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/helper-member-expression-to-functions@7.24.8': dependencies: - '@babel/traverse': 7.24.8 - '@babel/types': 7.24.9 + '@babel/traverse': 7.25.1 + '@babel/types': 7.25.0 transitivePeerDependencies: - supports-color '@babel/helper-module-imports@7.22.15': dependencies: - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/helper-module-imports@7.22.5': dependencies: - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/helper-module-imports@7.24.7': dependencies: '@babel/traverse': 7.24.7 - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 transitivePeerDependencies: - supports-color @@ -14846,24 +14866,23 @@ snapshots: transitivePeerDependencies: - supports-color - '@babel/helper-module-transforms@7.24.9(@babel/core@7.24.9)': + '@babel/helper-module-transforms@7.25.0(@babel/core@7.24.9)': dependencies: '@babel/core': 7.24.9 - '@babel/helper-environment-visitor': 7.24.7 '@babel/helper-module-imports': 7.24.7 '@babel/helper-simple-access': 7.24.7 - '@babel/helper-split-export-declaration': 7.24.7 '@babel/helper-validator-identifier': 7.24.7 + '@babel/traverse': 7.25.1 transitivePeerDependencies: - supports-color '@babel/helper-optimise-call-expression@7.22.5': dependencies: - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/helper-optimise-call-expression@7.24.7': dependencies: - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/helper-plugin-utils@7.24.6': {} @@ -14877,7 +14896,7 @@ snapshots: '@babel/helper-annotate-as-pure': 7.22.5 '@babel/helper-environment-visitor': 7.24.6 '@babel/helper-wrap-function': 7.22.5 - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 transitivePeerDependencies: - supports-color @@ -14887,16 +14906,16 @@ snapshots: '@babel/helper-annotate-as-pure': 7.22.5 '@babel/helper-environment-visitor': 7.24.6 '@babel/helper-wrap-function': 7.22.5 - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 transitivePeerDependencies: - supports-color - '@babel/helper-remap-async-to-generator@7.24.7(@babel/core@7.24.9)': + '@babel/helper-remap-async-to-generator@7.25.0(@babel/core@7.24.9)': dependencies: '@babel/core': 7.24.9 '@babel/helper-annotate-as-pure': 7.24.7 - '@babel/helper-environment-visitor': 7.24.7 - '@babel/helper-wrap-function': 7.24.7 + '@babel/helper-wrap-function': 7.25.0 + '@babel/traverse': 7.25.1 transitivePeerDependencies: - supports-color @@ -14907,56 +14926,56 @@ snapshots: '@babel/helper-optimise-call-expression': 7.22.5 '@babel/template': 7.24.6 '@babel/traverse': 7.24.1 - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 transitivePeerDependencies: - supports-color - '@babel/helper-replace-supers@7.24.7(@babel/core@7.24.9)': + '@babel/helper-replace-supers@7.25.0(@babel/core@7.24.9)': dependencies: '@babel/core': 7.24.9 - '@babel/helper-environment-visitor': 7.24.7 '@babel/helper-member-expression-to-functions': 7.24.8 '@babel/helper-optimise-call-expression': 7.24.7 + '@babel/traverse': 7.25.1 transitivePeerDependencies: - supports-color '@babel/helper-simple-access@7.22.5': dependencies: - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/helper-simple-access@7.24.7': dependencies: '@babel/traverse': 7.24.7 - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 transitivePeerDependencies: - supports-color '@babel/helper-skip-transparent-expression-wrappers@7.22.5': dependencies: - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/helper-skip-transparent-expression-wrappers@7.24.7': dependencies: - '@babel/traverse': 7.24.8 - '@babel/types': 7.24.9 + '@babel/traverse': 7.25.1 + '@babel/types': 7.25.0 transitivePeerDependencies: - supports-color '@babel/helper-split-export-declaration@7.22.5': dependencies: - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/helper-split-export-declaration@7.22.6': dependencies: - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/helper-split-export-declaration@7.24.6': dependencies: - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/helper-split-export-declaration@7.24.7': dependencies: - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/helper-string-parser@7.24.6': {} @@ -14981,16 +15000,15 @@ snapshots: '@babel/helper-function-name': 7.24.6 '@babel/template': 7.24.6 '@babel/traverse': 7.24.1 - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 transitivePeerDependencies: - supports-color - '@babel/helper-wrap-function@7.24.7': + '@babel/helper-wrap-function@7.25.0': dependencies: - '@babel/helper-function-name': 7.24.7 - '@babel/template': 7.24.7 - '@babel/traverse': 7.24.8 - '@babel/types': 7.24.9 + '@babel/template': 7.25.0 + '@babel/traverse': 7.25.1 + '@babel/types': 7.25.0 transitivePeerDependencies: - supports-color @@ -15006,7 +15024,7 @@ snapshots: dependencies: '@babel/template': 7.24.6 '@babel/traverse': 7.24.1 - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 transitivePeerDependencies: - supports-color @@ -15015,10 +15033,10 @@ snapshots: '@babel/template': 7.24.7 '@babel/types': 7.24.7 - '@babel/helpers@7.24.8': + '@babel/helpers@7.25.0': dependencies: - '@babel/template': 7.24.7 - '@babel/types': 7.24.9 + '@babel/template': 7.25.0 + '@babel/types': 7.25.0 '@babel/highlight@7.22.5': dependencies: @@ -15059,9 +15077,9 @@ snapshots: dependencies: '@babel/types': 7.24.6 - '@babel/parser@7.24.8': + '@babel/parser@7.25.0': dependencies: - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@7.22.5(@babel/core@7.22.5)': dependencies: @@ -15092,7 +15110,7 @@ snapshots: '@babel/core': 7.24.9 '@babel/helper-environment-visitor': 7.24.7 '@babel/helper-plugin-utils': 7.24.8 - '@babel/helper-remap-async-to-generator': 7.24.7(@babel/core@7.24.9) + '@babel/helper-remap-async-to-generator': 7.25.0(@babel/core@7.24.9) '@babel/plugin-syntax-async-generators': 7.8.4(@babel/core@7.24.9) transitivePeerDependencies: - supports-color @@ -15624,7 +15642,7 @@ snapshots: '@babel/core': 7.24.9 '@babel/helper-module-imports': 7.24.7 '@babel/helper-plugin-utils': 7.24.8 - '@babel/helper-remap-async-to-generator': 7.24.7(@babel/core@7.24.9) + '@babel/helper-remap-async-to-generator': 7.25.0(@babel/core@7.24.9) transitivePeerDependencies: - supports-color @@ -15658,7 +15676,7 @@ snapshots: '@babel/core': 7.24.9 '@babel/helper-plugin-utils': 7.24.6 - '@babel/plugin-transform-block-scoping@7.24.7(@babel/core@7.24.9)': + '@babel/plugin-transform-block-scoping@7.25.0(@babel/core@7.24.9)': dependencies: '@babel/core': 7.24.9 '@babel/helper-plugin-utils': 7.24.8 @@ -15742,16 +15760,14 @@ snapshots: transitivePeerDependencies: - supports-color - '@babel/plugin-transform-classes@7.24.8(@babel/core@7.24.9)': + '@babel/plugin-transform-classes@7.25.0(@babel/core@7.24.9)': dependencies: '@babel/core': 7.24.9 '@babel/helper-annotate-as-pure': 7.24.7 '@babel/helper-compilation-targets': 7.24.8 - '@babel/helper-environment-visitor': 7.24.7 - '@babel/helper-function-name': 7.24.7 '@babel/helper-plugin-utils': 7.24.8 - '@babel/helper-replace-supers': 7.24.7(@babel/core@7.24.9) - '@babel/helper-split-export-declaration': 7.24.7 + '@babel/helper-replace-supers': 7.25.0(@babel/core@7.24.9) + '@babel/traverse': 7.25.1 globals: 11.12.0 transitivePeerDependencies: - supports-color @@ -15778,7 +15794,7 @@ snapshots: dependencies: '@babel/core': 7.24.9 '@babel/helper-plugin-utils': 7.24.8 - '@babel/template': 7.24.7 + '@babel/template': 7.25.0 '@babel/plugin-transform-destructuring@7.22.5(@babel/core@7.22.5)': dependencies: @@ -15912,12 +15928,14 @@ snapshots: '@babel/helper-function-name': 7.22.5 '@babel/helper-plugin-utils': 7.24.6 - '@babel/plugin-transform-function-name@7.24.7(@babel/core@7.24.9)': + '@babel/plugin-transform-function-name@7.25.1(@babel/core@7.24.9)': dependencies: '@babel/core': 7.24.9 '@babel/helper-compilation-targets': 7.24.8 - '@babel/helper-function-name': 7.24.7 '@babel/helper-plugin-utils': 7.24.8 + '@babel/traverse': 7.25.1 + transitivePeerDependencies: + - supports-color '@babel/plugin-transform-json-strings@7.22.5(@babel/core@7.22.5)': dependencies: @@ -16024,7 +16042,7 @@ snapshots: '@babel/plugin-transform-modules-commonjs@7.24.8(@babel/core@7.24.9)': dependencies: '@babel/core': 7.24.9 - '@babel/helper-module-transforms': 7.24.9(@babel/core@7.24.9) + '@babel/helper-module-transforms': 7.25.0(@babel/core@7.24.9) '@babel/helper-plugin-utils': 7.24.8 '@babel/helper-simple-access': 7.24.7 transitivePeerDependencies: @@ -16081,7 +16099,7 @@ snapshots: '@babel/plugin-transform-named-capturing-groups-regex@7.24.7(@babel/core@7.24.9)': dependencies: '@babel/core': 7.24.9 - '@babel/helper-create-regexp-features-plugin': 7.24.7(@babel/core@7.24.9) + '@babel/helper-create-regexp-features-plugin': 7.25.0(@babel/core@7.24.9) '@babel/helper-plugin-utils': 7.24.8 '@babel/plugin-transform-new-target@7.22.5(@babel/core@7.22.5)': @@ -16225,7 +16243,7 @@ snapshots: '@babel/plugin-transform-private-methods@7.24.7(@babel/core@7.24.9)': dependencies: '@babel/core': 7.24.9 - '@babel/helper-create-class-features-plugin': 7.24.8(@babel/core@7.24.9) + '@babel/helper-create-class-features-plugin': 7.25.0(@babel/core@7.24.9) '@babel/helper-plugin-utils': 7.24.8 transitivePeerDependencies: - supports-color @@ -16254,7 +16272,7 @@ snapshots: dependencies: '@babel/core': 7.24.9 '@babel/helper-annotate-as-pure': 7.24.7 - '@babel/helper-create-class-features-plugin': 7.24.8(@babel/core@7.24.9) + '@babel/helper-create-class-features-plugin': 7.25.0(@babel/core@7.24.9) '@babel/helper-plugin-utils': 7.24.8 '@babel/plugin-syntax-private-property-in-object': 7.14.5(@babel/core@7.24.9) transitivePeerDependencies: @@ -16327,7 +16345,7 @@ snapshots: '@babel/helper-module-imports': 7.22.5 '@babel/helper-plugin-utils': 7.24.6 '@babel/plugin-syntax-jsx': 7.22.5(@babel/core@7.22.5) - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/plugin-transform-react-jsx@7.23.4(@babel/core@7.24.4)': dependencies: @@ -16336,7 +16354,7 @@ snapshots: '@babel/helper-module-imports': 7.22.15 '@babel/helper-plugin-utils': 7.24.6 '@babel/plugin-syntax-jsx': 7.23.3(@babel/core@7.24.4) - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@babel/plugin-transform-react-jsx@7.24.7(@babel/core@7.22.5)': dependencies: @@ -16345,7 +16363,7 @@ snapshots: '@babel/helper-module-imports': 7.24.7 '@babel/helper-plugin-utils': 7.24.8 '@babel/plugin-syntax-jsx': 7.24.7(@babel/core@7.22.5) - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 transitivePeerDependencies: - supports-color @@ -16356,7 +16374,7 @@ snapshots: '@babel/helper-module-imports': 7.24.7 '@babel/helper-plugin-utils': 7.24.8 '@babel/plugin-syntax-jsx': 7.24.7(@babel/core@7.24.9) - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 transitivePeerDependencies: - supports-color @@ -16508,12 +16526,13 @@ snapshots: transitivePeerDependencies: - supports-color - '@babel/plugin-transform-typescript@7.24.8(@babel/core@7.24.9)': + '@babel/plugin-transform-typescript@7.25.0(@babel/core@7.24.9)': dependencies: '@babel/core': 7.24.9 '@babel/helper-annotate-as-pure': 7.24.7 - '@babel/helper-create-class-features-plugin': 7.24.8(@babel/core@7.24.9) + '@babel/helper-create-class-features-plugin': 7.25.0(@babel/core@7.24.9) '@babel/helper-plugin-utils': 7.24.8 + '@babel/helper-skip-transparent-expression-wrappers': 7.24.7 '@babel/plugin-syntax-typescript': 7.24.7(@babel/core@7.24.9) transitivePeerDependencies: - supports-color @@ -16555,7 +16574,7 @@ snapshots: '@babel/plugin-transform-unicode-regex@7.24.7(@babel/core@7.24.9)': dependencies: '@babel/core': 7.24.9 - '@babel/helper-create-regexp-features-plugin': 7.24.7(@babel/core@7.24.9) + '@babel/helper-create-regexp-features-plugin': 7.25.0(@babel/core@7.24.9) '@babel/helper-plugin-utils': 7.24.8 '@babel/plugin-transform-unicode-sets-regex@7.22.5(@babel/core@7.22.5)': @@ -16760,7 +16779,7 @@ snapshots: '@babel/helper-plugin-utils': 7.24.6 '@babel/plugin-proposal-unicode-property-regex': 7.18.6(@babel/core@7.22.5) '@babel/plugin-transform-dotall-regex': 7.22.5(@babel/core@7.22.5) - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 esutils: 2.0.3 '@babel/preset-modules@0.1.5(@babel/core@7.24.9)': @@ -16769,7 +16788,7 @@ snapshots: '@babel/helper-plugin-utils': 7.24.6 '@babel/plugin-proposal-unicode-property-regex': 7.18.6(@babel/core@7.24.9) '@babel/plugin-transform-dotall-regex': 7.22.5(@babel/core@7.24.9) - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 esutils: 2.0.3 '@babel/preset-react@7.22.5(@babel/core@7.22.5)': @@ -16800,7 +16819,7 @@ snapshots: '@babel/helper-validator-option': 7.24.8 '@babel/plugin-syntax-jsx': 7.24.7(@babel/core@7.24.9) '@babel/plugin-transform-modules-commonjs': 7.24.8(@babel/core@7.24.9) - '@babel/plugin-transform-typescript': 7.24.8(@babel/core@7.24.9) + '@babel/plugin-transform-typescript': 7.25.0(@babel/core@7.24.9) transitivePeerDependencies: - supports-color @@ -16828,6 +16847,10 @@ snapshots: dependencies: regenerator-runtime: 0.14.1 + '@babel/runtime@7.25.0': + dependencies: + regenerator-runtime: 0.14.1 + '@babel/template@7.24.6': dependencies: '@babel/code-frame': 7.24.6 @@ -16837,9 +16860,15 @@ snapshots: '@babel/template@7.24.7': dependencies: '@babel/code-frame': 7.24.7 - '@babel/parser': 7.24.8 + '@babel/parser': 7.25.0 '@babel/types': 7.24.7 + '@babel/template@7.25.0': + dependencies: + '@babel/code-frame': 7.24.7 + '@babel/parser': 7.25.0 + '@babel/types': 7.25.0 + '@babel/traverse@7.22.5': dependencies: '@babel/code-frame': 7.24.6 @@ -16848,7 +16877,7 @@ snapshots: '@babel/helper-function-name': 7.22.5 '@babel/helper-hoist-variables': 7.22.5 '@babel/helper-split-export-declaration': 7.22.5 - '@babel/parser': 7.24.8 + '@babel/parser': 7.25.0 '@babel/types': 7.24.6 debug: 4.3.5(supports-color@5.5.0) globals: 11.12.0 @@ -16863,8 +16892,8 @@ snapshots: '@babel/helper-function-name': 7.24.6 '@babel/helper-hoist-variables': 7.22.5 '@babel/helper-split-export-declaration': 7.24.6 - '@babel/parser': 7.24.8 - '@babel/types': 7.24.9 + '@babel/parser': 7.25.0 + '@babel/types': 7.25.0 debug: 4.3.5(supports-color@5.5.0) globals: 11.12.0 transitivePeerDependencies: @@ -16878,24 +16907,21 @@ snapshots: '@babel/helper-function-name': 7.24.7 '@babel/helper-hoist-variables': 7.24.7 '@babel/helper-split-export-declaration': 7.24.7 - '@babel/parser': 7.24.8 + '@babel/parser': 7.25.0 '@babel/types': 7.24.7 debug: 4.3.5(supports-color@5.5.0) globals: 11.12.0 transitivePeerDependencies: - supports-color - '@babel/traverse@7.24.8': + '@babel/traverse@7.25.1': dependencies: '@babel/code-frame': 7.24.7 - '@babel/generator': 7.24.10 - '@babel/helper-environment-visitor': 7.24.7 - '@babel/helper-function-name': 7.24.7 - '@babel/helper-hoist-variables': 7.24.7 - '@babel/helper-split-export-declaration': 7.24.7 - '@babel/parser': 7.24.8 - '@babel/types': 7.24.9 - debug: 4.3.5(supports-color@5.5.0) + '@babel/generator': 7.25.0 + '@babel/parser': 7.25.0 + '@babel/template': 7.25.0 + '@babel/types': 7.25.0 + debug: 4.3.6 globals: 11.12.0 transitivePeerDependencies: - supports-color @@ -16912,7 +16938,7 @@ snapshots: '@babel/helper-validator-identifier': 7.24.7 to-fast-properties: 2.0.0 - '@babel/types@7.24.9': + '@babel/types@7.25.0': dependencies: '@babel/helper-string-parser': 7.24.8 '@babel/helper-validator-identifier': 7.24.7 @@ -17092,7 +17118,7 @@ snapshots: eth-json-rpc-filters: 6.0.1 eventemitter3: 5.0.1 keccak: 3.0.4 - preact: 10.22.1 + preact: 10.23.1 sha.js: 2.4.11 transitivePeerDependencies: - supports-color @@ -17103,7 +17129,7 @@ snapshots: clsx: 1.2.1 eventemitter3: 5.0.1 keccak: 3.0.4 - preact: 10.22.1 + preact: 10.23.1 sha.js: 2.4.11 '@cspotcode/source-map-support@0.8.1': @@ -17113,79 +17139,79 @@ snapshots: '@csstools/normalize.css@12.0.0': {} - '@csstools/postcss-cascade-layers@1.1.1(postcss@8.4.39)': + '@csstools/postcss-cascade-layers@1.1.1(postcss@8.4.40)': dependencies: '@csstools/selector-specificity': 2.2.0(postcss-selector-parser@6.0.13) - postcss: 8.4.39 + postcss: 8.4.40 postcss-selector-parser: 6.0.13 - '@csstools/postcss-color-function@1.1.1(postcss@8.4.39)': + '@csstools/postcss-color-function@1.1.1(postcss@8.4.40)': dependencies: - '@csstools/postcss-progressive-custom-properties': 1.3.0(postcss@8.4.39) - postcss: 8.4.39 + '@csstools/postcss-progressive-custom-properties': 1.3.0(postcss@8.4.40) + postcss: 8.4.40 postcss-value-parser: 4.2.0 - '@csstools/postcss-font-format-keywords@1.0.1(postcss@8.4.39)': + '@csstools/postcss-font-format-keywords@1.0.1(postcss@8.4.40)': dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - '@csstools/postcss-hwb-function@1.0.2(postcss@8.4.39)': + '@csstools/postcss-hwb-function@1.0.2(postcss@8.4.40)': dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - '@csstools/postcss-ic-unit@1.0.1(postcss@8.4.39)': + '@csstools/postcss-ic-unit@1.0.1(postcss@8.4.40)': dependencies: - '@csstools/postcss-progressive-custom-properties': 1.3.0(postcss@8.4.39) - postcss: 8.4.39 + '@csstools/postcss-progressive-custom-properties': 1.3.0(postcss@8.4.40) + postcss: 8.4.40 postcss-value-parser: 4.2.0 - '@csstools/postcss-is-pseudo-class@2.0.7(postcss@8.4.39)': + '@csstools/postcss-is-pseudo-class@2.0.7(postcss@8.4.40)': dependencies: '@csstools/selector-specificity': 2.2.0(postcss-selector-parser@6.0.13) - postcss: 8.4.39 + postcss: 8.4.40 postcss-selector-parser: 6.0.13 - '@csstools/postcss-nested-calc@1.0.0(postcss@8.4.39)': + '@csstools/postcss-nested-calc@1.0.0(postcss@8.4.40)': dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - '@csstools/postcss-normalize-display-values@1.0.1(postcss@8.4.39)': + '@csstools/postcss-normalize-display-values@1.0.1(postcss@8.4.40)': dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - '@csstools/postcss-oklab-function@1.1.1(postcss@8.4.39)': + '@csstools/postcss-oklab-function@1.1.1(postcss@8.4.40)': dependencies: - '@csstools/postcss-progressive-custom-properties': 1.3.0(postcss@8.4.39) - postcss: 8.4.39 + '@csstools/postcss-progressive-custom-properties': 1.3.0(postcss@8.4.40) + postcss: 8.4.40 postcss-value-parser: 4.2.0 - '@csstools/postcss-progressive-custom-properties@1.3.0(postcss@8.4.39)': + '@csstools/postcss-progressive-custom-properties@1.3.0(postcss@8.4.40)': dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - '@csstools/postcss-stepped-value-functions@1.0.1(postcss@8.4.39)': + '@csstools/postcss-stepped-value-functions@1.0.1(postcss@8.4.40)': dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - '@csstools/postcss-text-decoration-shorthand@1.0.0(postcss@8.4.39)': + '@csstools/postcss-text-decoration-shorthand@1.0.0(postcss@8.4.40)': dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - '@csstools/postcss-trigonometric-functions@1.0.2(postcss@8.4.39)': + '@csstools/postcss-trigonometric-functions@1.0.2(postcss@8.4.40)': dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - '@csstools/postcss-unset-value@1.0.2(postcss@8.4.39)': + '@csstools/postcss-unset-value@1.0.2(postcss@8.4.40)': dependencies: - postcss: 8.4.39 + postcss: 8.4.40 '@csstools/selector-specificity@2.2.0(postcss-selector-parser@6.0.13)': dependencies: @@ -17518,15 +17544,15 @@ snapshots: '@fastify/busboy@2.1.1': {} - '@fuels/connectors@0.8.1(kchncypvkqsbwvw6o5d5zxpqxa)': + '@fuels/connectors@0.8.1(efp7nrq7ox7dlifkvza7hk62re)': dependencies: '@ethereumjs/util': 9.0.3 '@ethersproject/bytes': 5.7.0 - '@wagmi/core': 2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8) - '@web3modal/wagmi': 4.1.11(dg6i7lqnqlap2oekno7j3ffiei) + '@wagmi/core': 2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.4.5)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8) + '@web3modal/wagmi': 4.1.11(pc55kysz5yk453hbyeotq4qenm) fuels: link:packages/fuels socket.io-client: 4.7.2(bufferutil@4.0.8)(utf-8-validate@6.0.4) - viem: 2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8) + viem: 2.10.2(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4)(zod@3.23.8) transitivePeerDependencies: - '@tanstack/query-core' - '@types/react' @@ -17541,15 +17567,15 @@ snapshots: - vue - zod - '@fuels/connectors@0.8.1(kufw6iq3ny244gzkpb3pizcz2u)': + '@fuels/connectors@0.8.1(oq6yvogrlhlckexnjtdkjthppq)': dependencies: '@ethereumjs/util': 9.0.3 '@ethersproject/bytes': 5.7.0 - '@wagmi/core': 2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.4.5)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8) - '@web3modal/wagmi': 4.1.11(gpgvzu6ohjtf7uat26xocqxagy) + '@wagmi/core': 2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8) + '@web3modal/wagmi': 4.1.11(qspuvbfnxvdc4bp3go25txklxm) fuels: link:packages/fuels socket.io-client: 4.7.2(bufferutil@4.0.8)(utf-8-validate@6.0.4) - viem: 2.10.2(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4)(zod@3.23.8) + viem: 2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8) transitivePeerDependencies: - '@tanstack/query-core' - '@types/react' @@ -17564,12 +17590,12 @@ snapshots: - vue - zod - '@fuels/connectors@0.8.1(pcy7aobdmanrvrecamrxxtyms4)': + '@fuels/connectors@0.8.1(w265xd32dg4mkyoutfp3bgmoku)': dependencies: '@ethereumjs/util': 9.0.3 '@ethersproject/bytes': 5.7.0 '@wagmi/core': 2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8) - '@web3modal/wagmi': 4.1.11(cajolppu34caxr2pafyvyy52zm) + '@web3modal/wagmi': 4.1.11(qa3czionpgy4w7bmzsfh6vbxfe) fuels: link:packages/fuels socket.io-client: 4.7.2(bufferutil@4.0.8)(utf-8-validate@6.0.4) viem: 2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8) @@ -17619,7 +17645,7 @@ snapshots: graphql: 16.9.0 tslib: 2.6.3 - '@graphql-codegen/cli@5.0.2(@parcel/watcher@2.4.1)(@types/node@20.14.11)(bufferutil@4.0.8)(cosmiconfig-toml-loader@1.0.0)(enquirer@2.3.6)(graphql@16.9.0)(typescript@5.4.5)(utf-8-validate@6.0.4)': + '@graphql-codegen/cli@5.0.2(@parcel/watcher@2.4.1)(@types/node@20.14.13)(bufferutil@4.0.8)(cosmiconfig-toml-loader@1.0.0)(enquirer@2.3.6)(graphql@16.9.0)(typescript@5.4.5)(utf-8-validate@6.0.4)': dependencies: '@babel/generator': 7.24.4 '@babel/template': 7.24.6 @@ -17630,12 +17656,12 @@ snapshots: '@graphql-tools/apollo-engine-loader': 8.0.1(graphql@16.9.0) '@graphql-tools/code-file-loader': 8.1.2(graphql@16.9.0) '@graphql-tools/git-loader': 8.0.6(graphql@16.9.0) - '@graphql-tools/github-loader': 8.0.1(@types/node@20.14.11)(graphql@16.9.0) + '@graphql-tools/github-loader': 8.0.1(@types/node@20.14.13)(graphql@16.9.0) '@graphql-tools/graphql-file-loader': 8.0.1(graphql@16.9.0) '@graphql-tools/json-file-loader': 8.0.1(graphql@16.9.0) '@graphql-tools/load': 8.0.2(graphql@16.9.0) - '@graphql-tools/prisma-loader': 8.0.4(@types/node@20.14.11)(bufferutil@4.0.8)(graphql@16.9.0)(utf-8-validate@6.0.4) - '@graphql-tools/url-loader': 8.0.2(@types/node@20.14.11)(bufferutil@4.0.8)(graphql@16.9.0)(utf-8-validate@6.0.4) + '@graphql-tools/prisma-loader': 8.0.4(@types/node@20.14.13)(bufferutil@4.0.8)(graphql@16.9.0)(utf-8-validate@6.0.4) + '@graphql-tools/url-loader': 8.0.2(@types/node@20.14.13)(bufferutil@4.0.8)(graphql@16.9.0)(utf-8-validate@6.0.4) '@graphql-tools/utils': 10.2.2(graphql@16.9.0) '@whatwg-node/fetch': 0.8.8 chalk: 4.1.2 @@ -17643,7 +17669,7 @@ snapshots: debounce: 1.2.1 detect-indent: 6.1.0 graphql: 16.9.0 - graphql-config: 5.0.3(@types/node@20.14.11)(bufferutil@4.0.8)(cosmiconfig-toml-loader@1.0.0)(graphql@16.9.0)(typescript@5.4.5)(utf-8-validate@6.0.4) + graphql-config: 5.0.3(@types/node@20.14.13)(bufferutil@4.0.8)(cosmiconfig-toml-loader@1.0.0)(graphql@16.9.0)(typescript@5.4.5)(utf-8-validate@6.0.4) inquirer: 8.2.5 is-glob: 4.0.3 jiti: 1.21.0 @@ -17903,14 +17929,14 @@ snapshots: - bufferutil - utf-8-validate - '@graphql-tools/executor-http@1.0.9(@types/node@20.14.11)(graphql@16.9.0)': + '@graphql-tools/executor-http@1.0.9(@types/node@20.14.13)(graphql@16.9.0)': dependencies: '@graphql-tools/utils': 10.2.2(graphql@16.9.0) '@repeaterjs/repeater': 3.0.4 '@whatwg-node/fetch': 0.9.18 extract-files: 11.0.0 graphql: 16.9.0 - meros: 1.3.0(@types/node@20.14.11) + meros: 1.3.0(@types/node@20.14.13) tslib: 2.6.3 value-or-promise: 1.0.12 transitivePeerDependencies: @@ -17949,10 +17975,10 @@ snapshots: transitivePeerDependencies: - supports-color - '@graphql-tools/github-loader@8.0.1(@types/node@20.14.11)(graphql@16.9.0)': + '@graphql-tools/github-loader@8.0.1(@types/node@20.14.13)(graphql@16.9.0)': dependencies: '@ardatan/sync-fetch': 0.0.1 - '@graphql-tools/executor-http': 1.0.9(@types/node@20.14.11)(graphql@16.9.0) + '@graphql-tools/executor-http': 1.0.9(@types/node@20.14.13)(graphql@16.9.0) '@graphql-tools/graphql-tag-pluck': 8.3.1(graphql@16.9.0) '@graphql-tools/utils': 10.2.2(graphql@16.9.0) '@whatwg-node/fetch': 0.9.18 @@ -17976,7 +18002,7 @@ snapshots: '@graphql-tools/graphql-tag-pluck@8.3.1(graphql@16.9.0)': dependencies: '@babel/core': 7.24.4 - '@babel/parser': 7.24.8 + '@babel/parser': 7.25.0 '@babel/plugin-syntax-import-assertions': 7.22.5(@babel/core@7.24.4) '@babel/traverse': 7.24.1 '@babel/types': 7.24.6 @@ -18025,9 +18051,9 @@ snapshots: graphql: 16.9.0 tslib: 2.6.3 - '@graphql-tools/prisma-loader@8.0.4(@types/node@20.14.11)(bufferutil@4.0.8)(graphql@16.9.0)(utf-8-validate@6.0.4)': + '@graphql-tools/prisma-loader@8.0.4(@types/node@20.14.13)(bufferutil@4.0.8)(graphql@16.9.0)(utf-8-validate@6.0.4)': dependencies: - '@graphql-tools/url-loader': 8.0.2(@types/node@20.14.11)(bufferutil@4.0.8)(graphql@16.9.0)(utf-8-validate@6.0.4) + '@graphql-tools/url-loader': 8.0.2(@types/node@20.14.13)(bufferutil@4.0.8)(graphql@16.9.0)(utf-8-validate@6.0.4) '@graphql-tools/utils': 10.2.2(graphql@16.9.0) '@types/js-yaml': 4.0.5 '@whatwg-node/fetch': 0.9.18 @@ -18079,12 +18105,12 @@ snapshots: tslib: 2.6.3 value-or-promise: 1.0.12 - '@graphql-tools/url-loader@8.0.2(@types/node@20.14.11)(bufferutil@4.0.8)(graphql@16.9.0)(utf-8-validate@6.0.4)': + '@graphql-tools/url-loader@8.0.2(@types/node@20.14.13)(bufferutil@4.0.8)(graphql@16.9.0)(utf-8-validate@6.0.4)': dependencies: '@ardatan/sync-fetch': 0.0.1 '@graphql-tools/delegate': 10.0.11(graphql@16.9.0) '@graphql-tools/executor-graphql-ws': 1.1.2(bufferutil@4.0.8)(graphql@16.9.0)(utf-8-validate@6.0.4) - '@graphql-tools/executor-http': 1.0.9(@types/node@20.14.11)(graphql@16.9.0) + '@graphql-tools/executor-http': 1.0.9(@types/node@20.14.13)(graphql@16.9.0) '@graphql-tools/executor-legacy-ws': 1.0.6(bufferutil@4.0.8)(graphql@16.9.0)(utf-8-validate@6.0.4) '@graphql-tools/utils': 10.2.2(graphql@16.9.0) '@graphql-tools/wrap': 10.0.5(graphql@16.9.0) @@ -18580,7 +18606,7 @@ snapshots: bufferutil: 4.0.8 cross-fetch: 4.0.0 date-fns: 2.30.0 - debug: 4.3.5(supports-color@5.5.0) + debug: 4.3.6 eciesjs: 0.3.19 eventemitter2: 6.4.9 readable-stream: 3.6.2 @@ -18610,7 +18636,7 @@ snapshots: react-dom: 18.3.1(react@18.3.1) react-native: 0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4) - '@metamask/sdk@0.20.3(bufferutil@4.0.8)(react-dom@18.2.0(react@18.3.1))(react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.2.0(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1)(rollup@4.19.0)(utf-8-validate@6.0.4)': + '@metamask/sdk@0.20.3(bufferutil@4.0.8)(react-dom@18.2.0(react@18.3.1))(react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.2.0(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1)(rollup@4.19.1)(utf-8-validate@6.0.4)': dependencies: '@metamask/onboarding': 1.0.1 '@metamask/providers': 15.0.0 @@ -18619,7 +18645,7 @@ snapshots: '@types/dom-screen-wake-lock': 1.0.3 bowser: 2.11.0 cross-fetch: 4.0.0 - debug: 4.3.5(supports-color@5.5.0) + debug: 4.3.6 eciesjs: 0.3.19 eth-rpc-errors: 4.0.3 eventemitter2: 6.4.9 @@ -18630,7 +18656,7 @@ snapshots: qrcode-terminal-nooctal: 0.12.1 react-native-webview: 11.26.1(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1) readable-stream: 3.6.2 - rollup-plugin-visualizer: 5.12.0(rollup@4.19.0) + rollup-plugin-visualizer: 5.12.0(rollup@4.19.1) socket.io-client: 4.7.5(bufferutil@4.0.8)(utf-8-validate@6.0.4) util: 0.12.5 uuid: 8.3.2 @@ -18646,7 +18672,7 @@ snapshots: - supports-color - utf-8-validate - '@metamask/sdk@0.20.3(bufferutil@4.0.8)(react-dom@18.3.1(react@18.3.1))(react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.3.1(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1)(rollup@4.19.0)(utf-8-validate@6.0.4)': + '@metamask/sdk@0.20.3(bufferutil@4.0.8)(react-dom@18.3.1(react@18.3.1))(react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.3.1(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1)(rollup@4.19.1)(utf-8-validate@6.0.4)': dependencies: '@metamask/onboarding': 1.0.1 '@metamask/providers': 15.0.0 @@ -18655,7 +18681,7 @@ snapshots: '@types/dom-screen-wake-lock': 1.0.3 bowser: 2.11.0 cross-fetch: 4.0.0 - debug: 4.3.5(supports-color@5.5.0) + debug: 4.3.6 eciesjs: 0.3.19 eth-rpc-errors: 4.0.3 eventemitter2: 6.4.9 @@ -18666,7 +18692,7 @@ snapshots: qrcode-terminal-nooctal: 0.12.1 react-native-webview: 11.26.1(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1) readable-stream: 3.6.2 - rollup-plugin-visualizer: 5.12.0(rollup@4.19.0) + rollup-plugin-visualizer: 5.12.0(rollup@4.19.1) socket.io-client: 4.7.5(bufferutil@4.0.8)(utf-8-validate@6.0.4) util: 0.12.5 uuid: 8.3.2 @@ -18688,7 +18714,7 @@ snapshots: dependencies: '@ethereumjs/tx': 4.2.0 '@types/debug': 4.1.12 - debug: 4.3.5(supports-color@5.5.0) + debug: 4.3.6 semver: 7.6.3 superstruct: 1.0.4 transitivePeerDependencies: @@ -18701,7 +18727,7 @@ snapshots: '@noble/hashes': 1.4.0 '@scure/base': 1.1.7 '@types/debug': 4.1.12 - debug: 4.3.5(supports-color@5.5.0) + debug: 4.3.6 pony-cause: 2.1.11 semver: 7.6.3 uuid: 9.0.1 @@ -18715,7 +18741,7 @@ snapshots: '@noble/hashes': 1.4.0 '@scure/base': 1.1.7 '@types/debug': 4.1.12 - debug: 4.3.5(supports-color@5.5.0) + debug: 4.3.6 pony-cause: 2.1.11 semver: 7.6.3 uuid: 9.0.1 @@ -19382,7 +19408,7 @@ snapshots: semver: 7.6.3 strip-ansi: 5.2.0 wcwidth: 1.0.1 - yaml: 2.4.5 + yaml: 2.5.0 transitivePeerDependencies: - encoding @@ -19401,7 +19427,7 @@ snapshots: chalk: 4.1.2 execa: 5.1.1 fast-glob: 3.3.2 - fast-xml-parser: 4.4.0 + fast-xml-parser: 4.4.1 logkitty: 0.7.1 transitivePeerDependencies: - encoding @@ -19412,7 +19438,7 @@ snapshots: chalk: 4.1.2 execa: 5.1.1 fast-glob: 3.3.2 - fast-xml-parser: 4.4.0 + fast-xml-parser: 4.4.1 ora: 5.4.1 transitivePeerDependencies: - encoding @@ -19513,12 +19539,12 @@ snapshots: '@babel/plugin-syntax-optional-chaining': 7.8.3(@babel/core@7.24.9) '@babel/plugin-transform-arrow-functions': 7.24.7(@babel/core@7.24.9) '@babel/plugin-transform-async-to-generator': 7.24.7(@babel/core@7.24.9) - '@babel/plugin-transform-block-scoping': 7.24.7(@babel/core@7.24.9) - '@babel/plugin-transform-classes': 7.24.8(@babel/core@7.24.9) + '@babel/plugin-transform-block-scoping': 7.25.0(@babel/core@7.24.9) + '@babel/plugin-transform-classes': 7.25.0(@babel/core@7.24.9) '@babel/plugin-transform-computed-properties': 7.24.7(@babel/core@7.24.9) '@babel/plugin-transform-destructuring': 7.24.8(@babel/core@7.24.9) '@babel/plugin-transform-flow-strip-types': 7.24.7(@babel/core@7.24.9) - '@babel/plugin-transform-function-name': 7.24.7(@babel/core@7.24.9) + '@babel/plugin-transform-function-name': 7.25.1(@babel/core@7.24.9) '@babel/plugin-transform-literals': 7.24.7(@babel/core@7.24.9) '@babel/plugin-transform-modules-commonjs': 7.24.8(@babel/core@7.24.9) '@babel/plugin-transform-named-capturing-groups-regex': 7.24.7(@babel/core@7.24.9) @@ -19533,9 +19559,9 @@ snapshots: '@babel/plugin-transform-shorthand-properties': 7.24.7(@babel/core@7.24.9) '@babel/plugin-transform-spread': 7.24.7(@babel/core@7.24.9) '@babel/plugin-transform-sticky-regex': 7.24.7(@babel/core@7.24.9) - '@babel/plugin-transform-typescript': 7.24.8(@babel/core@7.24.9) + '@babel/plugin-transform-typescript': 7.25.0(@babel/core@7.24.9) '@babel/plugin-transform-unicode-regex': 7.24.7(@babel/core@7.24.9) - '@babel/template': 7.24.7 + '@babel/template': 7.25.0 '@react-native/babel-plugin-codegen': 0.74.83(@babel/preset-env@7.22.5(@babel/core@7.24.9)) babel-plugin-transform-flow-enums: 0.0.2(@babel/core@7.24.9) react-refresh: 0.14.2 @@ -19545,7 +19571,7 @@ snapshots: '@react-native/codegen@0.74.83(@babel/preset-env@7.22.5(@babel/core@7.24.9))': dependencies: - '@babel/parser': 7.24.8 + '@babel/parser': 7.25.0 '@babel/preset-env': 7.22.5(@babel/core@7.24.9) glob: 7.2.3 hermes-parser: 0.19.1 @@ -19630,7 +19656,7 @@ snapshots: '@rnx-kit/chromium-edge-launcher@1.0.0': dependencies: - '@types/node': 18.15.13 + '@types/node': 18.19.42 escape-string-regexp: 4.0.0 is-wsl: 2.2.0 lighthouse-logger: 1.4.2 @@ -19648,13 +19674,13 @@ snapshots: optionalDependencies: '@types/babel__core': 7.20.5 - '@rollup/plugin-inject@5.0.5(rollup@4.19.0)': + '@rollup/plugin-inject@5.0.5(rollup@4.19.1)': dependencies: - '@rollup/pluginutils': 5.1.0(rollup@4.19.0) + '@rollup/pluginutils': 5.1.0(rollup@4.19.1) estree-walker: 2.0.2 magic-string: 0.30.10 optionalDependencies: - rollup: 4.19.0 + rollup: 4.19.1 '@rollup/plugin-node-resolve@11.2.1(rollup@2.79.1)': dependencies: @@ -19679,60 +19705,60 @@ snapshots: picomatch: 2.3.1 rollup: 2.79.1 - '@rollup/pluginutils@5.1.0(rollup@4.19.0)': + '@rollup/pluginutils@5.1.0(rollup@4.19.1)': dependencies: '@types/estree': 1.0.5 estree-walker: 2.0.2 picomatch: 2.3.1 optionalDependencies: - rollup: 4.19.0 + rollup: 4.19.1 - '@rollup/rollup-android-arm-eabi@4.19.0': + '@rollup/rollup-android-arm-eabi@4.19.1': optional: true - '@rollup/rollup-android-arm64@4.19.0': + '@rollup/rollup-android-arm64@4.19.1': optional: true - '@rollup/rollup-darwin-arm64@4.19.0': + '@rollup/rollup-darwin-arm64@4.19.1': optional: true - '@rollup/rollup-darwin-x64@4.19.0': + '@rollup/rollup-darwin-x64@4.19.1': optional: true - '@rollup/rollup-linux-arm-gnueabihf@4.19.0': + '@rollup/rollup-linux-arm-gnueabihf@4.19.1': optional: true - '@rollup/rollup-linux-arm-musleabihf@4.19.0': + '@rollup/rollup-linux-arm-musleabihf@4.19.1': optional: true - '@rollup/rollup-linux-arm64-gnu@4.19.0': + '@rollup/rollup-linux-arm64-gnu@4.19.1': optional: true - '@rollup/rollup-linux-arm64-musl@4.19.0': + '@rollup/rollup-linux-arm64-musl@4.19.1': optional: true - '@rollup/rollup-linux-powerpc64le-gnu@4.19.0': + '@rollup/rollup-linux-powerpc64le-gnu@4.19.1': optional: true - '@rollup/rollup-linux-riscv64-gnu@4.19.0': + '@rollup/rollup-linux-riscv64-gnu@4.19.1': optional: true - '@rollup/rollup-linux-s390x-gnu@4.19.0': + '@rollup/rollup-linux-s390x-gnu@4.19.1': optional: true - '@rollup/rollup-linux-x64-gnu@4.19.0': + '@rollup/rollup-linux-x64-gnu@4.19.1': optional: true - '@rollup/rollup-linux-x64-musl@4.19.0': + '@rollup/rollup-linux-x64-musl@4.19.1': optional: true - '@rollup/rollup-win32-arm64-msvc@4.19.0': + '@rollup/rollup-win32-arm64-msvc@4.19.1': optional: true - '@rollup/rollup-win32-ia32-msvc@4.19.0': + '@rollup/rollup-win32-ia32-msvc@4.19.1': optional: true - '@rollup/rollup-win32-x64-msvc@4.19.0': + '@rollup/rollup-win32-x64-msvc@4.19.1': optional: true '@rushstack/eslint-patch@1.3.2': {} @@ -19761,7 +19787,7 @@ snapshots: '@safe-global/safe-apps-sdk@8.1.0(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8)': dependencies: - '@safe-global/safe-gateway-typescript-sdk': 3.22.0 + '@safe-global/safe-gateway-typescript-sdk': 3.22.1 viem: 1.21.4(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8) transitivePeerDependencies: - bufferutil @@ -19771,7 +19797,7 @@ snapshots: '@safe-global/safe-apps-sdk@8.1.0(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4)(zod@3.23.8)': dependencies: - '@safe-global/safe-gateway-typescript-sdk': 3.22.0 + '@safe-global/safe-gateway-typescript-sdk': 3.22.1 viem: 1.21.4(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4)(zod@3.23.8) transitivePeerDependencies: - bufferutil @@ -19779,7 +19805,7 @@ snapshots: - utf-8-validate - zod - '@safe-global/safe-gateway-typescript-sdk@3.22.0': {} + '@safe-global/safe-gateway-typescript-sdk@3.22.1': {} '@scure/base@1.1.6': {} @@ -19988,7 +20014,7 @@ snapshots: '@svgr/hast-util-to-babel-ast@5.5.0': dependencies: - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@svgr/plugin-jsx@5.5.0': dependencies: @@ -20039,7 +20065,7 @@ snapshots: '@testing-library/dom@8.20.1': dependencies: '@babel/code-frame': 7.24.7 - '@babel/runtime': 7.24.8 + '@babel/runtime': 7.25.0 '@types/aria-query': 5.0.4 aria-query: 5.1.3 chalk: 4.1.2 @@ -20200,7 +20226,7 @@ snapshots: '@types/babel__core@7.20.1': dependencies: - '@babel/parser': 7.24.8 + '@babel/parser': 7.25.0 '@babel/types': 7.24.6 '@types/babel__generator': 7.6.4 '@types/babel__template': 7.4.1 @@ -20220,7 +20246,7 @@ snapshots: '@types/babel__template@7.4.1': dependencies: - '@babel/parser': 7.24.8 + '@babel/parser': 7.25.0 '@babel/types': 7.24.6 '@types/babel__traverse@7.20.1': @@ -20398,6 +20424,10 @@ snapshots: '@types/node@18.15.13': {} + '@types/node@18.19.42': + dependencies: + undici-types: 5.26.5 + '@types/node@20.10.5': dependencies: undici-types: 5.26.5 @@ -20410,6 +20440,11 @@ snapshots: dependencies: undici-types: 5.26.5 + '@types/node@20.14.13': + dependencies: + undici-types: 5.26.5 + optional: true + '@types/parse-json@4.0.0': {} '@types/prettier@2.7.3': {} @@ -20797,20 +20832,20 @@ snapshots: '@ungap/structured-clone@1.2.0': {} - '@vitejs/plugin-react@4.3.1(vite@5.3.5(@types/node@20.14.11)(terser@5.31.3))': + '@vitejs/plugin-react@4.3.1(vite@5.3.5(@types/node@20.14.13)(terser@5.31.3))': dependencies: '@babel/core': 7.24.7 '@babel/plugin-transform-react-jsx-self': 7.24.7(@babel/core@7.24.7) '@babel/plugin-transform-react-jsx-source': 7.24.1(@babel/core@7.24.7) '@types/babel__core': 7.20.5 react-refresh: 0.14.2 - vite: 5.3.5(@types/node@20.14.11)(terser@5.31.3) + vite: 5.3.5(@types/node@20.14.13)(terser@5.31.3) transitivePeerDependencies: - supports-color - '@vitejs/plugin-vue@5.0.5(vite@5.3.5(@types/node@20.14.11)(terser@5.31.3))(vue@3.4.34(typescript@5.4.5))': + '@vitejs/plugin-vue@5.0.5(vite@5.3.5(@types/node@20.14.13)(terser@5.31.3))(vue@3.4.34(typescript@5.4.5))': dependencies: - vite: 5.3.5(@types/node@20.14.11)(terser@5.31.3) + vite: 5.3.5(@types/node@20.14.13)(terser@5.31.3) vue: 3.4.34(typescript@5.4.5) '@vitest/browser@1.6.0(playwright@1.45.3)(vitest@1.6.0)(webdriverio@8.39.1(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4))': @@ -20818,7 +20853,7 @@ snapshots: '@vitest/utils': 1.6.0 magic-string: 0.30.5 sirv: 2.0.4 - vitest: 1.6.0(@types/node@20.14.11)(@vitest/browser@1.6.0)(jsdom@16.7.0(bufferutil@4.0.8)(utf-8-validate@6.0.4))(terser@5.31.3) + vitest: 1.6.0(@types/node@20.14.13)(@vitest/browser@1.6.0)(jsdom@16.7.0(bufferutil@4.0.8)(utf-8-validate@6.0.4))(terser@5.31.3) optionalDependencies: playwright: 1.45.3 webdriverio: 8.39.1(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4) @@ -20869,7 +20904,7 @@ snapshots: '@vue/compiler-core@3.4.34': dependencies: - '@babel/parser': 7.24.8 + '@babel/parser': 7.25.0 '@vue/shared': 3.4.34 entities: 4.5.0 estree-walker: 2.0.2 @@ -20882,14 +20917,14 @@ snapshots: '@vue/compiler-sfc@3.4.34': dependencies: - '@babel/parser': 7.24.8 + '@babel/parser': 7.25.0 '@vue/compiler-core': 3.4.34 '@vue/compiler-dom': 3.4.34 '@vue/compiler-ssr': 3.4.34 '@vue/shared': 3.4.34 estree-walker: 2.0.2 magic-string: 0.30.10 - postcss: 8.4.39 + postcss: 8.4.40 source-map-js: 1.2.0 '@vue/compiler-ssr@3.4.34': @@ -20983,10 +21018,10 @@ snapshots: - '@vue/composition-api' - vue - '@wagmi/connectors@5.0.7(@types/react@18.3.3)(@wagmi/core@2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8))(bufferutil@4.0.8)(react-dom@18.2.0(react@18.3.1))(react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.2.0(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1)(rollup@4.19.0)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8)': + '@wagmi/connectors@5.0.7(@types/react@18.3.3)(@wagmi/core@2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8))(bufferutil@4.0.8)(react-dom@18.2.0(react@18.3.1))(react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.2.0(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1)(rollup@4.19.1)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8)': dependencies: '@coinbase/wallet-sdk': 4.0.2 - '@metamask/sdk': 0.20.3(bufferutil@4.0.8)(react-dom@18.2.0(react@18.3.1))(react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.2.0(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1)(rollup@4.19.0)(utf-8-validate@6.0.4) + '@metamask/sdk': 0.20.3(bufferutil@4.0.8)(react-dom@18.2.0(react@18.3.1))(react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.2.0(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1)(rollup@4.19.1)(utf-8-validate@6.0.4) '@safe-global/safe-apps-provider': 0.18.1(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8) '@safe-global/safe-apps-sdk': 8.1.0(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8) '@wagmi/core': 2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8) @@ -21023,10 +21058,10 @@ snapshots: - utf-8-validate - zod - '@wagmi/connectors@5.0.7(@types/react@18.3.3)(@wagmi/core@2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8))(bufferutil@4.0.8)(react-dom@18.3.1(react@18.3.1))(react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.3.1(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1)(rollup@4.19.0)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8)': + '@wagmi/connectors@5.0.7(@types/react@18.3.3)(@wagmi/core@2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8))(bufferutil@4.0.8)(react-dom@18.3.1(react@18.3.1))(react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.3.1(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1)(rollup@4.19.1)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8)': dependencies: '@coinbase/wallet-sdk': 4.0.2 - '@metamask/sdk': 0.20.3(bufferutil@4.0.8)(react-dom@18.3.1(react@18.3.1))(react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.3.1(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1)(rollup@4.19.0)(utf-8-validate@6.0.4) + '@metamask/sdk': 0.20.3(bufferutil@4.0.8)(react-dom@18.3.1(react@18.3.1))(react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.3.1(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1)(rollup@4.19.1)(utf-8-validate@6.0.4) '@safe-global/safe-apps-provider': 0.18.1(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8) '@safe-global/safe-apps-sdk': 8.1.0(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8) '@wagmi/core': 2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8) @@ -21063,10 +21098,10 @@ snapshots: - utf-8-validate - zod - '@wagmi/connectors@5.0.7(@types/react@18.3.3)(@wagmi/core@2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.4.5)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8))(bufferutil@4.0.8)(react-dom@18.3.1(react@18.3.1))(react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.3.1(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1)(rollup@4.19.0)(typescript@5.4.5)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8)': + '@wagmi/connectors@5.0.7(@types/react@18.3.3)(@wagmi/core@2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.4.5)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8))(bufferutil@4.0.8)(react-dom@18.3.1(react@18.3.1))(react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.3.1(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1)(rollup@4.19.1)(typescript@5.4.5)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8)': dependencies: '@coinbase/wallet-sdk': 4.0.2 - '@metamask/sdk': 0.20.3(bufferutil@4.0.8)(react-dom@18.3.1(react@18.3.1))(react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.3.1(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1)(rollup@4.19.0)(utf-8-validate@6.0.4) + '@metamask/sdk': 0.20.3(bufferutil@4.0.8)(react-dom@18.3.1(react@18.3.1))(react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.3.1(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1)(rollup@4.19.1)(utf-8-validate@6.0.4) '@safe-global/safe-apps-provider': 0.18.1(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4)(zod@3.23.8) '@safe-global/safe-apps-sdk': 8.1.0(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4)(zod@3.23.8) '@wagmi/core': 2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.4.5)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8) @@ -21592,57 +21627,57 @@ snapshots: lit: 3.1.0 qrcode: 1.5.3 - '@web3modal/wagmi@4.1.11(cajolppu34caxr2pafyvyy52zm)': + '@web3modal/wagmi@4.1.11(pc55kysz5yk453hbyeotq4qenm)': dependencies: - '@wagmi/connectors': 5.0.7(@types/react@18.3.3)(@wagmi/core@2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8))(bufferutil@4.0.8)(react-dom@18.2.0(react@18.3.1))(react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.2.0(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1)(rollup@4.19.0)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8) - '@wagmi/core': 2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8) + '@wagmi/connectors': 5.0.7(@types/react@18.3.3)(@wagmi/core@2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.4.5)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8))(bufferutil@4.0.8)(react-dom@18.3.1(react@18.3.1))(react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.3.1(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1)(rollup@4.19.1)(typescript@5.4.5)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8) + '@wagmi/core': 2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.4.5)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8) '@web3modal/polyfills': 4.1.11 '@web3modal/scaffold': 4.1.11(@types/react@18.3.3)(react@18.3.1) - '@web3modal/scaffold-react': 4.1.11(@types/react@18.3.3)(react-dom@18.2.0(react@18.3.1))(react@18.3.1) + '@web3modal/scaffold-react': 4.1.11(@types/react@18.3.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) '@web3modal/scaffold-utils': 4.1.11(@types/react@18.3.3)(react@18.3.1) - '@web3modal/scaffold-vue': 4.1.11(@types/react@18.3.3)(react@18.3.1)(vue@3.4.34(typescript@5.2.2)) + '@web3modal/scaffold-vue': 4.1.11(@types/react@18.3.3)(react@18.3.1)(vue@3.4.34(typescript@5.4.5)) '@web3modal/siwe': 4.1.11(@types/react@18.3.3)(react@18.3.1) - viem: 2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8) + viem: 2.10.2(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4)(zod@3.23.8) optionalDependencies: react: 18.3.1 - react-dom: 18.2.0(react@18.3.1) - vue: 3.4.34(typescript@5.2.2) + react-dom: 18.3.1(react@18.3.1) + vue: 3.4.34(typescript@5.4.5) transitivePeerDependencies: - '@types/react' - '@web3modal/wagmi@4.1.11(dg6i7lqnqlap2oekno7j3ffiei)': + '@web3modal/wagmi@4.1.11(qa3czionpgy4w7bmzsfh6vbxfe)': dependencies: - '@wagmi/connectors': 5.0.7(@types/react@18.3.3)(@wagmi/core@2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8))(bufferutil@4.0.8)(react-dom@18.3.1(react@18.3.1))(react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.3.1(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1)(rollup@4.19.0)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8) + '@wagmi/connectors': 5.0.7(@types/react@18.3.3)(@wagmi/core@2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8))(bufferutil@4.0.8)(react-dom@18.2.0(react@18.3.1))(react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.2.0(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1)(rollup@4.19.1)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8) '@wagmi/core': 2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8) '@web3modal/polyfills': 4.1.11 '@web3modal/scaffold': 4.1.11(@types/react@18.3.3)(react@18.3.1) - '@web3modal/scaffold-react': 4.1.11(@types/react@18.3.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + '@web3modal/scaffold-react': 4.1.11(@types/react@18.3.3)(react-dom@18.2.0(react@18.3.1))(react@18.3.1) '@web3modal/scaffold-utils': 4.1.11(@types/react@18.3.3)(react@18.3.1) '@web3modal/scaffold-vue': 4.1.11(@types/react@18.3.3)(react@18.3.1)(vue@3.4.34(typescript@5.2.2)) '@web3modal/siwe': 4.1.11(@types/react@18.3.3)(react@18.3.1) viem: 2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8) optionalDependencies: react: 18.3.1 - react-dom: 18.3.1(react@18.3.1) + react-dom: 18.2.0(react@18.3.1) vue: 3.4.34(typescript@5.2.2) transitivePeerDependencies: - '@types/react' - '@web3modal/wagmi@4.1.11(gpgvzu6ohjtf7uat26xocqxagy)': + '@web3modal/wagmi@4.1.11(qspuvbfnxvdc4bp3go25txklxm)': dependencies: - '@wagmi/connectors': 5.0.7(@types/react@18.3.3)(@wagmi/core@2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.4.5)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8))(bufferutil@4.0.8)(react-dom@18.3.1(react@18.3.1))(react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.3.1(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1)(rollup@4.19.0)(typescript@5.4.5)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8) - '@wagmi/core': 2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.4.5)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8) + '@wagmi/connectors': 5.0.7(@types/react@18.3.3)(@wagmi/core@2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8))(bufferutil@4.0.8)(react-dom@18.3.1(react@18.3.1))(react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.3.1(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1)(rollup@4.19.1)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8) + '@wagmi/core': 2.9.1(@tanstack/query-core@5.51.9)(@types/react@18.3.3)(bufferutil@4.0.8)(immer@9.0.21)(react@18.3.1)(typescript@5.2.2)(utf-8-validate@6.0.4)(viem@2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8))(zod@3.23.8) '@web3modal/polyfills': 4.1.11 '@web3modal/scaffold': 4.1.11(@types/react@18.3.3)(react@18.3.1) '@web3modal/scaffold-react': 4.1.11(@types/react@18.3.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) '@web3modal/scaffold-utils': 4.1.11(@types/react@18.3.3)(react@18.3.1) - '@web3modal/scaffold-vue': 4.1.11(@types/react@18.3.3)(react@18.3.1)(vue@3.4.34(typescript@5.4.5)) + '@web3modal/scaffold-vue': 4.1.11(@types/react@18.3.3)(react@18.3.1)(vue@3.4.34(typescript@5.2.2)) '@web3modal/siwe': 4.1.11(@types/react@18.3.3)(react@18.3.1) - viem: 2.10.2(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4)(zod@3.23.8) + viem: 2.10.2(bufferutil@4.0.8)(typescript@5.2.2)(utf-8-validate@6.0.4)(zod@3.23.8) optionalDependencies: react: 18.3.1 react-dom: 18.3.1(react@18.3.1) - vue: 3.4.34(typescript@5.4.5) + vue: 3.4.34(typescript@5.2.2) transitivePeerDependencies: - '@types/react' @@ -22186,14 +22221,14 @@ snapshots: postcss: 8.4.33 postcss-value-parser: 4.2.0 - autoprefixer@10.4.19(postcss@8.4.39): + autoprefixer@10.4.19(postcss@8.4.40): dependencies: browserslist: 4.23.0 caniuse-lite: 1.0.30001640 fraction.js: 4.3.7 normalize-range: 0.1.2 picocolors: 1.0.0 - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 available-typed-arrays@1.0.5: {} @@ -22268,7 +22303,7 @@ snapshots: babel-plugin-jest-hoist@27.5.1: dependencies: '@babel/template': 7.24.6 - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@types/babel__core': 7.20.1 '@types/babel__traverse': 7.20.1 @@ -22284,7 +22319,7 @@ snapshots: babel-plugin-polyfill-corejs2@0.4.11(@babel/core@7.24.9): dependencies: - '@babel/compat-data': 7.24.9 + '@babel/compat-data': 7.25.0 '@babel/core': 7.24.9 '@babel/helper-define-polyfill-provider': 0.6.2(@babel/core@7.24.9) semver: 6.3.1 @@ -22639,7 +22674,7 @@ snapshots: browserslist@4.23.2: dependencies: caniuse-lite: 1.0.30001643 - electron-to-chromium: 1.5.0 + electron-to-chromium: 1.5.2 node-releases: 2.0.18 update-browserslist-db: 1.1.0(browserslist@4.23.2) @@ -23116,7 +23151,7 @@ snapshots: convert-source-map@2.0.0: {} - cookie-es@1.2.1: {} + cookie-es@1.2.2: {} cookie-signature@1.0.6: {} @@ -23268,18 +23303,18 @@ snapshots: crypto-random-string@2.0.0: {} - css-blank-pseudo@3.0.3(postcss@8.4.39): + css-blank-pseudo@3.0.3(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-selector-parser: 6.0.13 - css-declaration-sorter@6.4.0(postcss@8.4.39): + css-declaration-sorter@6.4.0(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 - css-has-pseudo@3.0.4(postcss@8.4.39): + css-has-pseudo@3.0.4(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-selector-parser: 6.0.13 css-in-js-utils@3.1.0: @@ -23288,21 +23323,21 @@ snapshots: css-loader@6.8.1(webpack@5.88.0(esbuild@0.17.19)): dependencies: - icss-utils: 5.1.0(postcss@8.4.39) - postcss: 8.4.39 - postcss-modules-extract-imports: 3.0.0(postcss@8.4.39) - postcss-modules-local-by-default: 4.0.3(postcss@8.4.39) - postcss-modules-scope: 3.0.0(postcss@8.4.39) - postcss-modules-values: 4.0.0(postcss@8.4.39) + icss-utils: 5.1.0(postcss@8.4.40) + postcss: 8.4.40 + postcss-modules-extract-imports: 3.0.0(postcss@8.4.40) + postcss-modules-local-by-default: 4.0.3(postcss@8.4.40) + postcss-modules-scope: 3.0.0(postcss@8.4.40) + postcss-modules-values: 4.0.0(postcss@8.4.40) postcss-value-parser: 4.2.0 semver: 7.3.8 webpack: 5.88.0(esbuild@0.17.19) css-minimizer-webpack-plugin@3.4.1(esbuild@0.17.19)(webpack@5.88.0(esbuild@0.17.19)): dependencies: - cssnano: 5.1.15(postcss@8.4.39) + cssnano: 5.1.15(postcss@8.4.40) jest-worker: 27.5.1 - postcss: 8.4.39 + postcss: 8.4.40 schema-utils: 4.2.0 serialize-javascript: 6.0.1 source-map: 0.6.1 @@ -23310,9 +23345,9 @@ snapshots: optionalDependencies: esbuild: 0.17.19 - css-prefers-color-scheme@6.0.3(postcss@8.4.39): + css-prefers-color-scheme@6.0.3(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 css-select-base-adapter@0.1.1: {} @@ -23353,48 +23388,48 @@ snapshots: cssesc@3.0.0: {} - cssnano-preset-default@5.2.14(postcss@8.4.39): - dependencies: - css-declaration-sorter: 6.4.0(postcss@8.4.39) - cssnano-utils: 3.1.0(postcss@8.4.39) - postcss: 8.4.39 - postcss-calc: 8.2.4(postcss@8.4.39) - postcss-colormin: 5.3.1(postcss@8.4.39) - postcss-convert-values: 5.1.3(postcss@8.4.39) - postcss-discard-comments: 5.1.2(postcss@8.4.39) - postcss-discard-duplicates: 5.1.0(postcss@8.4.39) - postcss-discard-empty: 5.1.1(postcss@8.4.39) - postcss-discard-overridden: 5.1.0(postcss@8.4.39) - postcss-merge-longhand: 5.1.7(postcss@8.4.39) - postcss-merge-rules: 5.1.4(postcss@8.4.39) - postcss-minify-font-values: 5.1.0(postcss@8.4.39) - postcss-minify-gradients: 5.1.1(postcss@8.4.39) - postcss-minify-params: 5.1.4(postcss@8.4.39) - postcss-minify-selectors: 5.2.1(postcss@8.4.39) - postcss-normalize-charset: 5.1.0(postcss@8.4.39) - postcss-normalize-display-values: 5.1.0(postcss@8.4.39) - postcss-normalize-positions: 5.1.1(postcss@8.4.39) - postcss-normalize-repeat-style: 5.1.1(postcss@8.4.39) - postcss-normalize-string: 5.1.0(postcss@8.4.39) - postcss-normalize-timing-functions: 5.1.0(postcss@8.4.39) - postcss-normalize-unicode: 5.1.1(postcss@8.4.39) - postcss-normalize-url: 5.1.0(postcss@8.4.39) - postcss-normalize-whitespace: 5.1.1(postcss@8.4.39) - postcss-ordered-values: 5.1.3(postcss@8.4.39) - postcss-reduce-initial: 5.1.2(postcss@8.4.39) - postcss-reduce-transforms: 5.1.0(postcss@8.4.39) - postcss-svgo: 5.1.0(postcss@8.4.39) - postcss-unique-selectors: 5.1.1(postcss@8.4.39) - - cssnano-utils@3.1.0(postcss@8.4.39): - dependencies: - postcss: 8.4.39 - - cssnano@5.1.15(postcss@8.4.39): - dependencies: - cssnano-preset-default: 5.2.14(postcss@8.4.39) + cssnano-preset-default@5.2.14(postcss@8.4.40): + dependencies: + css-declaration-sorter: 6.4.0(postcss@8.4.40) + cssnano-utils: 3.1.0(postcss@8.4.40) + postcss: 8.4.40 + postcss-calc: 8.2.4(postcss@8.4.40) + postcss-colormin: 5.3.1(postcss@8.4.40) + postcss-convert-values: 5.1.3(postcss@8.4.40) + postcss-discard-comments: 5.1.2(postcss@8.4.40) + postcss-discard-duplicates: 5.1.0(postcss@8.4.40) + postcss-discard-empty: 5.1.1(postcss@8.4.40) + postcss-discard-overridden: 5.1.0(postcss@8.4.40) + postcss-merge-longhand: 5.1.7(postcss@8.4.40) + postcss-merge-rules: 5.1.4(postcss@8.4.40) + postcss-minify-font-values: 5.1.0(postcss@8.4.40) + postcss-minify-gradients: 5.1.1(postcss@8.4.40) + postcss-minify-params: 5.1.4(postcss@8.4.40) + postcss-minify-selectors: 5.2.1(postcss@8.4.40) + postcss-normalize-charset: 5.1.0(postcss@8.4.40) + postcss-normalize-display-values: 5.1.0(postcss@8.4.40) + postcss-normalize-positions: 5.1.1(postcss@8.4.40) + postcss-normalize-repeat-style: 5.1.1(postcss@8.4.40) + postcss-normalize-string: 5.1.0(postcss@8.4.40) + postcss-normalize-timing-functions: 5.1.0(postcss@8.4.40) + postcss-normalize-unicode: 5.1.1(postcss@8.4.40) + postcss-normalize-url: 5.1.0(postcss@8.4.40) + postcss-normalize-whitespace: 5.1.1(postcss@8.4.40) + postcss-ordered-values: 5.1.3(postcss@8.4.40) + postcss-reduce-initial: 5.1.2(postcss@8.4.40) + postcss-reduce-transforms: 5.1.0(postcss@8.4.40) + postcss-svgo: 5.1.0(postcss@8.4.40) + postcss-unique-selectors: 5.1.1(postcss@8.4.40) + + cssnano-utils@3.1.0(postcss@8.4.40): + dependencies: + postcss: 8.4.40 + + cssnano@5.1.15(postcss@8.4.40): + dependencies: + cssnano-preset-default: 5.2.14(postcss@8.4.40) lilconfig: 2.1.0 - postcss: 8.4.39 + postcss: 8.4.40 yaml: 1.10.2 csso@4.2.0: @@ -23447,7 +23482,7 @@ snapshots: date-fns@2.30.0: dependencies: - '@babel/runtime': 7.24.8 + '@babel/runtime': 7.25.0 dayjs@1.11.10: {} @@ -23473,6 +23508,10 @@ snapshots: optionalDependencies: supports-color: 5.5.0 + debug@4.3.6: + dependencies: + ms: 2.1.2 + decamelize@1.2.0: {} decamelize@6.0.0: {} @@ -23749,7 +23788,7 @@ snapshots: electron-to-chromium@1.4.747: {} - electron-to-chromium@1.5.0: {} + electron-to-chromium@1.5.2: {} elliptic@6.5.4: dependencies: @@ -23804,7 +23843,7 @@ snapshots: engine.io-client@6.5.4(bufferutil@4.0.8)(utf-8-validate@6.0.4): dependencies: '@socket.io/component-emitter': 3.1.2 - debug: 4.3.5(supports-color@5.5.0) + debug: 4.3.6 engine.io-parser: 5.2.3 ws: 8.17.1(bufferutil@4.0.8)(utf-8-validate@6.0.4) xmlhttprequest-ssl: 2.0.0 @@ -24963,7 +25002,7 @@ snapshots: dependencies: punycode: 1.4.1 - fast-xml-parser@4.4.0: + fast-xml-parser@4.4.1: dependencies: strnum: 1.0.5 @@ -25445,13 +25484,13 @@ snapshots: graphemer@1.4.0: {} - graphql-config@5.0.3(@types/node@20.14.11)(bufferutil@4.0.8)(cosmiconfig-toml-loader@1.0.0)(graphql@16.9.0)(typescript@5.4.5)(utf-8-validate@6.0.4): + graphql-config@5.0.3(@types/node@20.14.13)(bufferutil@4.0.8)(cosmiconfig-toml-loader@1.0.0)(graphql@16.9.0)(typescript@5.4.5)(utf-8-validate@6.0.4): dependencies: '@graphql-tools/graphql-file-loader': 8.0.1(graphql@16.9.0) '@graphql-tools/json-file-loader': 8.0.1(graphql@16.9.0) '@graphql-tools/load': 8.0.2(graphql@16.9.0) '@graphql-tools/merge': 9.0.4(graphql@16.9.0) - '@graphql-tools/url-loader': 8.0.2(@types/node@20.14.11)(bufferutil@4.0.8)(graphql@16.9.0)(utf-8-validate@6.0.4) + '@graphql-tools/url-loader': 8.0.2(@types/node@20.14.13)(bufferutil@4.0.8)(graphql@16.9.0)(utf-8-validate@6.0.4) '@graphql-tools/utils': 10.2.2(graphql@16.9.0) cosmiconfig: 8.3.6(typescript@5.4.5) graphql: 16.9.0 @@ -25507,7 +25546,7 @@ snapshots: h3@1.12.0: dependencies: - cookie-es: 1.2.1 + cookie-es: 1.2.2 crossws: 0.2.4 defu: 6.1.4 destr: 2.0.3 @@ -25761,11 +25800,11 @@ snapshots: i18next-browser-languagedetector@7.1.0: dependencies: - '@babel/runtime': 7.24.8 + '@babel/runtime': 7.25.0 i18next@22.5.1: dependencies: - '@babel/runtime': 7.24.8 + '@babel/runtime': 7.25.0 iconv-lite@0.4.24: dependencies: @@ -25775,9 +25814,9 @@ snapshots: dependencies: safer-buffer: 2.1.2 - icss-utils@5.1.0(postcss@8.4.39): + icss-utils@5.1.0(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 idb-keyval@6.2.1: {} @@ -26172,7 +26211,7 @@ snapshots: istanbul-lib-instrument@5.2.1: dependencies: '@babel/core': 7.24.4 - '@babel/parser': 7.24.8 + '@babel/parser': 7.25.0 '@istanbuljs/schema': 0.1.3 istanbul-lib-coverage: 3.2.2 semver: 6.3.1 @@ -26627,7 +26666,7 @@ snapshots: '@babel/generator': 7.24.4 '@babel/plugin-syntax-typescript': 7.22.5(@babel/core@7.24.4) '@babel/traverse': 7.24.1 - '@babel/types': 7.24.9 + '@babel/types': 7.25.0 '@jest/transform': 27.5.1 '@jest/types': 27.5.1 '@types/babel__traverse': 7.20.1 @@ -26811,7 +26850,7 @@ snapshots: jscodeshift@0.14.0(@babel/preset-env@7.22.5(@babel/core@7.24.9)): dependencies: '@babel/core': 7.24.9 - '@babel/parser': 7.24.8 + '@babel/parser': 7.25.0 '@babel/plugin-proposal-class-properties': 7.18.6(@babel/core@7.24.9) '@babel/plugin-proposal-nullish-coalescing-operator': 7.18.6(@babel/core@7.24.9) '@babel/plugin-proposal-optional-chaining': 7.21.0(@babel/core@7.24.9) @@ -27440,9 +27479,9 @@ snapshots: merge2@1.4.1: {} - meros@1.3.0(@types/node@20.14.11): + meros@1.3.0(@types/node@20.14.13): optionalDependencies: - '@types/node': 20.14.11 + '@types/node': 20.14.13 methods@1.1.2: {} @@ -27506,12 +27545,12 @@ snapshots: metro-runtime@0.80.9: dependencies: - '@babel/runtime': 7.24.8 + '@babel/runtime': 7.25.0 metro-source-map@0.80.9: dependencies: - '@babel/traverse': 7.24.8 - '@babel/types': 7.24.9 + '@babel/traverse': 7.25.1 + '@babel/types': 7.25.0 invariant: 2.2.4 metro-symbolicate: 0.80.9 nullthrows: 1.1.1 @@ -27535,9 +27574,9 @@ snapshots: metro-transform-plugins@0.80.9: dependencies: '@babel/core': 7.24.9 - '@babel/generator': 7.24.10 - '@babel/template': 7.24.7 - '@babel/traverse': 7.24.8 + '@babel/generator': 7.25.0 + '@babel/template': 7.25.0 + '@babel/traverse': 7.25.1 nullthrows: 1.1.1 transitivePeerDependencies: - supports-color @@ -27545,9 +27584,9 @@ snapshots: metro-transform-worker@0.80.9(bufferutil@4.0.8)(utf-8-validate@6.0.4): dependencies: '@babel/core': 7.24.9 - '@babel/generator': 7.24.10 - '@babel/parser': 7.24.8 - '@babel/types': 7.24.9 + '@babel/generator': 7.25.0 + '@babel/parser': 7.25.0 + '@babel/types': 7.25.0 metro: 0.80.9(bufferutil@4.0.8)(utf-8-validate@6.0.4) metro-babel-transformer: 0.80.9 metro-cache: 0.80.9 @@ -27566,11 +27605,11 @@ snapshots: dependencies: '@babel/code-frame': 7.24.7 '@babel/core': 7.24.9 - '@babel/generator': 7.24.10 - '@babel/parser': 7.24.8 - '@babel/template': 7.24.7 - '@babel/traverse': 7.24.8 - '@babel/types': 7.24.9 + '@babel/generator': 7.25.0 + '@babel/parser': 7.25.0 + '@babel/template': 7.25.0 + '@babel/traverse': 7.25.1 + '@babel/types': 7.25.0 accepts: 1.3.8 chalk: 4.1.2 ci-info: 2.0.0 @@ -28624,424 +28663,424 @@ snapshots: possible-typed-array-names@1.0.0: {} - postcss-attribute-case-insensitive@5.0.2(postcss@8.4.39): + postcss-attribute-case-insensitive@5.0.2(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-selector-parser: 6.0.13 - postcss-browser-comments@4.0.0(browserslist@4.21.9)(postcss@8.4.39): + postcss-browser-comments@4.0.0(browserslist@4.21.9)(postcss@8.4.40): dependencies: browserslist: 4.21.9 - postcss: 8.4.39 + postcss: 8.4.40 - postcss-calc@8.2.4(postcss@8.4.39): + postcss-calc@8.2.4(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-selector-parser: 6.0.13 postcss-value-parser: 4.2.0 - postcss-clamp@4.1.0(postcss@8.4.39): + postcss-clamp@4.1.0(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-color-functional-notation@4.2.4(postcss@8.4.39): + postcss-color-functional-notation@4.2.4(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-color-hex-alpha@8.0.4(postcss@8.4.39): + postcss-color-hex-alpha@8.0.4(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-color-rebeccapurple@7.1.1(postcss@8.4.39): + postcss-color-rebeccapurple@7.1.1(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-colormin@5.3.1(postcss@8.4.39): + postcss-colormin@5.3.1(postcss@8.4.40): dependencies: browserslist: 4.23.0 caniuse-api: 3.0.0 colord: 2.9.3 - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-convert-values@5.1.3(postcss@8.4.39): + postcss-convert-values@5.1.3(postcss@8.4.40): dependencies: browserslist: 4.23.0 - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-custom-media@8.0.2(postcss@8.4.39): + postcss-custom-media@8.0.2(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-custom-properties@12.1.11(postcss@8.4.39): + postcss-custom-properties@12.1.11(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-custom-selectors@6.0.3(postcss@8.4.39): + postcss-custom-selectors@6.0.3(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-selector-parser: 6.0.13 - postcss-dir-pseudo-class@6.0.5(postcss@8.4.39): + postcss-dir-pseudo-class@6.0.5(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-selector-parser: 6.0.13 - postcss-discard-comments@5.1.2(postcss@8.4.39): + postcss-discard-comments@5.1.2(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 - postcss-discard-duplicates@5.1.0(postcss@8.4.39): + postcss-discard-duplicates@5.1.0(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 - postcss-discard-empty@5.1.1(postcss@8.4.39): + postcss-discard-empty@5.1.1(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 - postcss-discard-overridden@5.1.0(postcss@8.4.39): + postcss-discard-overridden@5.1.0(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 - postcss-double-position-gradients@3.1.2(postcss@8.4.39): + postcss-double-position-gradients@3.1.2(postcss@8.4.40): dependencies: - '@csstools/postcss-progressive-custom-properties': 1.3.0(postcss@8.4.39) - postcss: 8.4.39 + '@csstools/postcss-progressive-custom-properties': 1.3.0(postcss@8.4.40) + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-env-function@4.0.6(postcss@8.4.39): + postcss-env-function@4.0.6(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-flexbugs-fixes@5.0.2(postcss@8.4.39): + postcss-flexbugs-fixes@5.0.2(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 - postcss-focus-visible@6.0.4(postcss@8.4.39): + postcss-focus-visible@6.0.4(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-selector-parser: 6.0.13 - postcss-focus-within@5.0.4(postcss@8.4.39): + postcss-focus-within@5.0.4(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-selector-parser: 6.0.13 - postcss-font-variant@5.0.0(postcss@8.4.39): + postcss-font-variant@5.0.0(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 - postcss-gap-properties@3.0.5(postcss@8.4.39): + postcss-gap-properties@3.0.5(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 - postcss-image-set-function@4.0.7(postcss@8.4.39): + postcss-image-set-function@4.0.7(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-import@15.1.0(postcss@8.4.39): + postcss-import@15.1.0(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 read-cache: 1.0.0 resolve: 1.22.8 - postcss-initial@4.0.1(postcss@8.4.39): + postcss-initial@4.0.1(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 - postcss-js@4.0.1(postcss@8.4.39): + postcss-js@4.0.1(postcss@8.4.40): dependencies: camelcase-css: 2.0.1 - postcss: 8.4.39 + postcss: 8.4.40 - postcss-lab-function@4.2.1(postcss@8.4.39): + postcss-lab-function@4.2.1(postcss@8.4.40): dependencies: - '@csstools/postcss-progressive-custom-properties': 1.3.0(postcss@8.4.39) - postcss: 8.4.39 + '@csstools/postcss-progressive-custom-properties': 1.3.0(postcss@8.4.40) + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-load-config@3.1.4(postcss@8.4.39)(ts-node@10.9.1(@types/node@20.14.11)(typescript@5.4.5)): + postcss-load-config@3.1.4(postcss@8.4.40)(ts-node@10.9.1(@types/node@20.14.11)(typescript@5.4.5)): dependencies: lilconfig: 2.1.0 yaml: 1.10.2 optionalDependencies: - postcss: 8.4.39 + postcss: 8.4.40 ts-node: 10.9.1(@types/node@20.14.11)(typescript@5.4.5) - postcss-load-config@4.0.1(postcss@8.4.39)(ts-node@10.9.1(@types/node@20.10.5)(typescript@5.4.5)): + postcss-load-config@4.0.1(postcss@8.4.40)(ts-node@10.9.1(@types/node@20.10.5)(typescript@5.4.5)): dependencies: lilconfig: 2.1.0 - yaml: 2.4.5 + yaml: 2.5.0 optionalDependencies: - postcss: 8.4.39 + postcss: 8.4.40 ts-node: 10.9.1(@types/node@20.10.5)(typescript@5.4.5) - postcss-load-config@4.0.1(postcss@8.4.39)(ts-node@10.9.1(@types/node@20.11.13)(typescript@5.2.2)): + postcss-load-config@4.0.1(postcss@8.4.40)(ts-node@10.9.1(@types/node@20.11.13)(typescript@5.2.2)): dependencies: lilconfig: 2.1.0 - yaml: 2.4.5 + yaml: 2.5.0 optionalDependencies: - postcss: 8.4.39 + postcss: 8.4.40 ts-node: 10.9.1(@types/node@20.11.13)(typescript@5.2.2) - postcss-load-config@4.0.1(postcss@8.4.39)(ts-node@10.9.1(@types/node@20.14.11)(typescript@5.4.5)): + postcss-load-config@4.0.1(postcss@8.4.40)(ts-node@10.9.1(@types/node@20.14.11)(typescript@5.4.5)): dependencies: lilconfig: 2.1.0 - yaml: 2.4.5 + yaml: 2.5.0 optionalDependencies: - postcss: 8.4.39 + postcss: 8.4.40 ts-node: 10.9.1(@types/node@20.14.11)(typescript@5.4.5) - postcss-loader@6.2.1(postcss@8.4.39)(webpack@5.88.0(esbuild@0.17.19)): + postcss-loader@6.2.1(postcss@8.4.40)(webpack@5.88.0(esbuild@0.17.19)): dependencies: cosmiconfig: 7.1.0 klona: 2.0.6 - postcss: 8.4.39 + postcss: 8.4.40 semver: 7.3.8 webpack: 5.88.0(esbuild@0.17.19) - postcss-logical@5.0.4(postcss@8.4.39): + postcss-logical@5.0.4(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 - postcss-media-minmax@5.0.0(postcss@8.4.39): + postcss-media-minmax@5.0.0(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 - postcss-merge-longhand@5.1.7(postcss@8.4.39): + postcss-merge-longhand@5.1.7(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - stylehacks: 5.1.1(postcss@8.4.39) + stylehacks: 5.1.1(postcss@8.4.40) - postcss-merge-rules@5.1.4(postcss@8.4.39): + postcss-merge-rules@5.1.4(postcss@8.4.40): dependencies: browserslist: 4.23.0 caniuse-api: 3.0.0 - cssnano-utils: 3.1.0(postcss@8.4.39) - postcss: 8.4.39 + cssnano-utils: 3.1.0(postcss@8.4.40) + postcss: 8.4.40 postcss-selector-parser: 6.0.13 - postcss-minify-font-values@5.1.0(postcss@8.4.39): + postcss-minify-font-values@5.1.0(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-minify-gradients@5.1.1(postcss@8.4.39): + postcss-minify-gradients@5.1.1(postcss@8.4.40): dependencies: colord: 2.9.3 - cssnano-utils: 3.1.0(postcss@8.4.39) - postcss: 8.4.39 + cssnano-utils: 3.1.0(postcss@8.4.40) + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-minify-params@5.1.4(postcss@8.4.39): + postcss-minify-params@5.1.4(postcss@8.4.40): dependencies: browserslist: 4.23.0 - cssnano-utils: 3.1.0(postcss@8.4.39) - postcss: 8.4.39 + cssnano-utils: 3.1.0(postcss@8.4.40) + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-minify-selectors@5.2.1(postcss@8.4.39): + postcss-minify-selectors@5.2.1(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-selector-parser: 6.0.13 - postcss-modules-extract-imports@3.0.0(postcss@8.4.39): + postcss-modules-extract-imports@3.0.0(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 - postcss-modules-local-by-default@4.0.3(postcss@8.4.39): + postcss-modules-local-by-default@4.0.3(postcss@8.4.40): dependencies: - icss-utils: 5.1.0(postcss@8.4.39) - postcss: 8.4.39 + icss-utils: 5.1.0(postcss@8.4.40) + postcss: 8.4.40 postcss-selector-parser: 6.0.13 postcss-value-parser: 4.2.0 - postcss-modules-scope@3.0.0(postcss@8.4.39): + postcss-modules-scope@3.0.0(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-selector-parser: 6.0.13 - postcss-modules-values@4.0.0(postcss@8.4.39): + postcss-modules-values@4.0.0(postcss@8.4.40): dependencies: - icss-utils: 5.1.0(postcss@8.4.39) - postcss: 8.4.39 + icss-utils: 5.1.0(postcss@8.4.40) + postcss: 8.4.40 - postcss-nested@6.0.1(postcss@8.4.39): + postcss-nested@6.0.1(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-selector-parser: 6.0.13 - postcss-nesting@10.2.0(postcss@8.4.39): + postcss-nesting@10.2.0(postcss@8.4.40): dependencies: '@csstools/selector-specificity': 2.2.0(postcss-selector-parser@6.0.13) - postcss: 8.4.39 + postcss: 8.4.40 postcss-selector-parser: 6.0.13 - postcss-normalize-charset@5.1.0(postcss@8.4.39): + postcss-normalize-charset@5.1.0(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 - postcss-normalize-display-values@5.1.0(postcss@8.4.39): + postcss-normalize-display-values@5.1.0(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-normalize-positions@5.1.1(postcss@8.4.39): + postcss-normalize-positions@5.1.1(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-normalize-repeat-style@5.1.1(postcss@8.4.39): + postcss-normalize-repeat-style@5.1.1(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-normalize-string@5.1.0(postcss@8.4.39): + postcss-normalize-string@5.1.0(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-normalize-timing-functions@5.1.0(postcss@8.4.39): + postcss-normalize-timing-functions@5.1.0(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-normalize-unicode@5.1.1(postcss@8.4.39): + postcss-normalize-unicode@5.1.1(postcss@8.4.40): dependencies: browserslist: 4.23.0 - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-normalize-url@5.1.0(postcss@8.4.39): + postcss-normalize-url@5.1.0(postcss@8.4.40): dependencies: normalize-url: 6.1.0 - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-normalize-whitespace@5.1.1(postcss@8.4.39): + postcss-normalize-whitespace@5.1.1(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-normalize@10.0.1(browserslist@4.21.9)(postcss@8.4.39): + postcss-normalize@10.0.1(browserslist@4.21.9)(postcss@8.4.40): dependencies: '@csstools/normalize.css': 12.0.0 browserslist: 4.21.9 - postcss: 8.4.39 - postcss-browser-comments: 4.0.0(browserslist@4.21.9)(postcss@8.4.39) + postcss: 8.4.40 + postcss-browser-comments: 4.0.0(browserslist@4.21.9)(postcss@8.4.40) sanitize.css: 13.0.0 - postcss-opacity-percentage@1.1.3(postcss@8.4.39): + postcss-opacity-percentage@1.1.3(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 - postcss-ordered-values@5.1.3(postcss@8.4.39): + postcss-ordered-values@5.1.3(postcss@8.4.40): dependencies: - cssnano-utils: 3.1.0(postcss@8.4.39) - postcss: 8.4.39 + cssnano-utils: 3.1.0(postcss@8.4.40) + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-overflow-shorthand@3.0.4(postcss@8.4.39): + postcss-overflow-shorthand@3.0.4(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-page-break@3.0.4(postcss@8.4.39): + postcss-page-break@3.0.4(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 - postcss-place@7.0.5(postcss@8.4.39): + postcss-place@7.0.5(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-preset-env@7.8.3(postcss@8.4.39): - dependencies: - '@csstools/postcss-cascade-layers': 1.1.1(postcss@8.4.39) - '@csstools/postcss-color-function': 1.1.1(postcss@8.4.39) - '@csstools/postcss-font-format-keywords': 1.0.1(postcss@8.4.39) - '@csstools/postcss-hwb-function': 1.0.2(postcss@8.4.39) - '@csstools/postcss-ic-unit': 1.0.1(postcss@8.4.39) - '@csstools/postcss-is-pseudo-class': 2.0.7(postcss@8.4.39) - '@csstools/postcss-nested-calc': 1.0.0(postcss@8.4.39) - '@csstools/postcss-normalize-display-values': 1.0.1(postcss@8.4.39) - '@csstools/postcss-oklab-function': 1.1.1(postcss@8.4.39) - '@csstools/postcss-progressive-custom-properties': 1.3.0(postcss@8.4.39) - '@csstools/postcss-stepped-value-functions': 1.0.1(postcss@8.4.39) - '@csstools/postcss-text-decoration-shorthand': 1.0.0(postcss@8.4.39) - '@csstools/postcss-trigonometric-functions': 1.0.2(postcss@8.4.39) - '@csstools/postcss-unset-value': 1.0.2(postcss@8.4.39) - autoprefixer: 10.4.19(postcss@8.4.39) + postcss-preset-env@7.8.3(postcss@8.4.40): + dependencies: + '@csstools/postcss-cascade-layers': 1.1.1(postcss@8.4.40) + '@csstools/postcss-color-function': 1.1.1(postcss@8.4.40) + '@csstools/postcss-font-format-keywords': 1.0.1(postcss@8.4.40) + '@csstools/postcss-hwb-function': 1.0.2(postcss@8.4.40) + '@csstools/postcss-ic-unit': 1.0.1(postcss@8.4.40) + '@csstools/postcss-is-pseudo-class': 2.0.7(postcss@8.4.40) + '@csstools/postcss-nested-calc': 1.0.0(postcss@8.4.40) + '@csstools/postcss-normalize-display-values': 1.0.1(postcss@8.4.40) + '@csstools/postcss-oklab-function': 1.1.1(postcss@8.4.40) + '@csstools/postcss-progressive-custom-properties': 1.3.0(postcss@8.4.40) + '@csstools/postcss-stepped-value-functions': 1.0.1(postcss@8.4.40) + '@csstools/postcss-text-decoration-shorthand': 1.0.0(postcss@8.4.40) + '@csstools/postcss-trigonometric-functions': 1.0.2(postcss@8.4.40) + '@csstools/postcss-unset-value': 1.0.2(postcss@8.4.40) + autoprefixer: 10.4.19(postcss@8.4.40) browserslist: 4.22.1 - css-blank-pseudo: 3.0.3(postcss@8.4.39) - css-has-pseudo: 3.0.4(postcss@8.4.39) - css-prefers-color-scheme: 6.0.3(postcss@8.4.39) + css-blank-pseudo: 3.0.3(postcss@8.4.40) + css-has-pseudo: 3.0.4(postcss@8.4.40) + css-prefers-color-scheme: 6.0.3(postcss@8.4.40) cssdb: 7.6.0 - postcss: 8.4.39 - postcss-attribute-case-insensitive: 5.0.2(postcss@8.4.39) - postcss-clamp: 4.1.0(postcss@8.4.39) - postcss-color-functional-notation: 4.2.4(postcss@8.4.39) - postcss-color-hex-alpha: 8.0.4(postcss@8.4.39) - postcss-color-rebeccapurple: 7.1.1(postcss@8.4.39) - postcss-custom-media: 8.0.2(postcss@8.4.39) - postcss-custom-properties: 12.1.11(postcss@8.4.39) - postcss-custom-selectors: 6.0.3(postcss@8.4.39) - postcss-dir-pseudo-class: 6.0.5(postcss@8.4.39) - postcss-double-position-gradients: 3.1.2(postcss@8.4.39) - postcss-env-function: 4.0.6(postcss@8.4.39) - postcss-focus-visible: 6.0.4(postcss@8.4.39) - postcss-focus-within: 5.0.4(postcss@8.4.39) - postcss-font-variant: 5.0.0(postcss@8.4.39) - postcss-gap-properties: 3.0.5(postcss@8.4.39) - postcss-image-set-function: 4.0.7(postcss@8.4.39) - postcss-initial: 4.0.1(postcss@8.4.39) - postcss-lab-function: 4.2.1(postcss@8.4.39) - postcss-logical: 5.0.4(postcss@8.4.39) - postcss-media-minmax: 5.0.0(postcss@8.4.39) - postcss-nesting: 10.2.0(postcss@8.4.39) - postcss-opacity-percentage: 1.1.3(postcss@8.4.39) - postcss-overflow-shorthand: 3.0.4(postcss@8.4.39) - postcss-page-break: 3.0.4(postcss@8.4.39) - postcss-place: 7.0.5(postcss@8.4.39) - postcss-pseudo-class-any-link: 7.1.6(postcss@8.4.39) - postcss-replace-overflow-wrap: 4.0.0(postcss@8.4.39) - postcss-selector-not: 6.0.1(postcss@8.4.39) + postcss: 8.4.40 + postcss-attribute-case-insensitive: 5.0.2(postcss@8.4.40) + postcss-clamp: 4.1.0(postcss@8.4.40) + postcss-color-functional-notation: 4.2.4(postcss@8.4.40) + postcss-color-hex-alpha: 8.0.4(postcss@8.4.40) + postcss-color-rebeccapurple: 7.1.1(postcss@8.4.40) + postcss-custom-media: 8.0.2(postcss@8.4.40) + postcss-custom-properties: 12.1.11(postcss@8.4.40) + postcss-custom-selectors: 6.0.3(postcss@8.4.40) + postcss-dir-pseudo-class: 6.0.5(postcss@8.4.40) + postcss-double-position-gradients: 3.1.2(postcss@8.4.40) + postcss-env-function: 4.0.6(postcss@8.4.40) + postcss-focus-visible: 6.0.4(postcss@8.4.40) + postcss-focus-within: 5.0.4(postcss@8.4.40) + postcss-font-variant: 5.0.0(postcss@8.4.40) + postcss-gap-properties: 3.0.5(postcss@8.4.40) + postcss-image-set-function: 4.0.7(postcss@8.4.40) + postcss-initial: 4.0.1(postcss@8.4.40) + postcss-lab-function: 4.2.1(postcss@8.4.40) + postcss-logical: 5.0.4(postcss@8.4.40) + postcss-media-minmax: 5.0.0(postcss@8.4.40) + postcss-nesting: 10.2.0(postcss@8.4.40) + postcss-opacity-percentage: 1.1.3(postcss@8.4.40) + postcss-overflow-shorthand: 3.0.4(postcss@8.4.40) + postcss-page-break: 3.0.4(postcss@8.4.40) + postcss-place: 7.0.5(postcss@8.4.40) + postcss-pseudo-class-any-link: 7.1.6(postcss@8.4.40) + postcss-replace-overflow-wrap: 4.0.0(postcss@8.4.40) + postcss-selector-not: 6.0.1(postcss@8.4.40) postcss-value-parser: 4.2.0 - postcss-pseudo-class-any-link@7.1.6(postcss@8.4.39): + postcss-pseudo-class-any-link@7.1.6(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-selector-parser: 6.0.13 - postcss-reduce-initial@5.1.2(postcss@8.4.39): + postcss-reduce-initial@5.1.2(postcss@8.4.40): dependencies: browserslist: 4.23.0 caniuse-api: 3.0.0 - postcss: 8.4.39 + postcss: 8.4.40 - postcss-reduce-transforms@5.1.0(postcss@8.4.39): + postcss-reduce-transforms@5.1.0(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 - postcss-replace-overflow-wrap@4.0.0(postcss@8.4.39): + postcss-replace-overflow-wrap@4.0.0(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 - postcss-selector-not@6.0.1(postcss@8.4.39): + postcss-selector-not@6.0.1(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-selector-parser: 6.0.13 postcss-selector-parser@6.0.13: @@ -29049,15 +29088,15 @@ snapshots: cssesc: 3.0.0 util-deprecate: 1.0.2 - postcss-svgo@5.1.0(postcss@8.4.39): + postcss-svgo@5.1.0(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-value-parser: 4.2.0 svgo: 2.8.0 - postcss-unique-selectors@5.1.1(postcss@8.4.39): + postcss-unique-selectors@5.1.1(postcss@8.4.40): dependencies: - postcss: 8.4.39 + postcss: 8.4.40 postcss-selector-parser: 6.0.13 postcss-value-parser@4.2.0: {} @@ -29085,7 +29124,7 @@ snapshots: picocolors: 1.0.0 source-map-js: 1.0.2 - postcss@8.4.39: + postcss@8.4.40: dependencies: nanoid: 3.3.7 picocolors: 1.0.1 @@ -29093,7 +29132,7 @@ snapshots: preact@10.22.0: {} - preact@10.22.1: {} + preact@10.23.1: {} preferred-pm@3.0.3: dependencies: @@ -29429,7 +29468,7 @@ snapshots: react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.2.0(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1): dependencies: - '@babel/runtime': 7.24.8 + '@babel/runtime': 7.25.0 html-parse-stringify: 3.0.1 i18next: 22.5.1 react: 18.3.1 @@ -29439,7 +29478,7 @@ snapshots: react-i18next@13.5.0(i18next@22.5.1)(react-dom@18.3.1(react@18.3.1))(react-native@0.74.1(@babel/core@7.24.9)(@babel/preset-env@7.22.5(@babel/core@7.24.9))(@types/react@18.3.3)(bufferutil@4.0.8)(react@18.3.1)(utf-8-validate@6.0.4))(react@18.3.1): dependencies: - '@babel/runtime': 7.24.8 + '@babel/runtime': 7.25.0 html-parse-stringify: 3.0.1 i18next: 22.5.1 react: 18.3.1 @@ -29563,11 +29602,11 @@ snapshots: jest-resolve: 27.5.1 jest-watch-typeahead: 1.1.0(jest@27.5.1(bufferutil@4.0.8)(ts-node@10.9.1(@types/node@20.14.11)(typescript@5.4.5))(utf-8-validate@6.0.4)) mini-css-extract-plugin: 2.7.6(webpack@5.88.0(esbuild@0.17.19)) - postcss: 8.4.39 - postcss-flexbugs-fixes: 5.0.2(postcss@8.4.39) - postcss-loader: 6.2.1(postcss@8.4.39)(webpack@5.88.0(esbuild@0.17.19)) - postcss-normalize: 10.0.1(browserslist@4.21.9)(postcss@8.4.39) - postcss-preset-env: 7.8.3(postcss@8.4.39) + postcss: 8.4.40 + postcss-flexbugs-fixes: 5.0.2(postcss@8.4.40) + postcss-loader: 6.2.1(postcss@8.4.40)(webpack@5.88.0(esbuild@0.17.19)) + postcss-normalize: 10.0.1(browserslist@4.21.9)(postcss@8.4.40) + postcss-preset-env: 7.8.3(postcss@8.4.40) prompts: 2.4.2 react: 18.3.1 react-app-polyfill: 3.0.0 @@ -29948,14 +29987,14 @@ snapshots: serialize-javascript: 4.0.0 terser: 5.18.2 - rollup-plugin-visualizer@5.12.0(rollup@4.19.0): + rollup-plugin-visualizer@5.12.0(rollup@4.19.1): dependencies: open: 8.4.2 picomatch: 2.3.1 source-map: 0.7.4 yargs: 17.7.2 optionalDependencies: - rollup: 4.19.0 + rollup: 4.19.1 rollup@2.79.1: optionalDependencies: @@ -29965,26 +30004,26 @@ snapshots: optionalDependencies: fsevents: 2.3.3 - rollup@4.19.0: + rollup@4.19.1: dependencies: '@types/estree': 1.0.5 optionalDependencies: - '@rollup/rollup-android-arm-eabi': 4.19.0 - '@rollup/rollup-android-arm64': 4.19.0 - '@rollup/rollup-darwin-arm64': 4.19.0 - '@rollup/rollup-darwin-x64': 4.19.0 - '@rollup/rollup-linux-arm-gnueabihf': 4.19.0 - '@rollup/rollup-linux-arm-musleabihf': 4.19.0 - '@rollup/rollup-linux-arm64-gnu': 4.19.0 - '@rollup/rollup-linux-arm64-musl': 4.19.0 - '@rollup/rollup-linux-powerpc64le-gnu': 4.19.0 - '@rollup/rollup-linux-riscv64-gnu': 4.19.0 - '@rollup/rollup-linux-s390x-gnu': 4.19.0 - '@rollup/rollup-linux-x64-gnu': 4.19.0 - '@rollup/rollup-linux-x64-musl': 4.19.0 - '@rollup/rollup-win32-arm64-msvc': 4.19.0 - '@rollup/rollup-win32-ia32-msvc': 4.19.0 - '@rollup/rollup-win32-x64-msvc': 4.19.0 + '@rollup/rollup-android-arm-eabi': 4.19.1 + '@rollup/rollup-android-arm64': 4.19.1 + '@rollup/rollup-darwin-arm64': 4.19.1 + '@rollup/rollup-darwin-x64': 4.19.1 + '@rollup/rollup-linux-arm-gnueabihf': 4.19.1 + '@rollup/rollup-linux-arm-musleabihf': 4.19.1 + '@rollup/rollup-linux-arm64-gnu': 4.19.1 + '@rollup/rollup-linux-arm64-musl': 4.19.1 + '@rollup/rollup-linux-powerpc64le-gnu': 4.19.1 + '@rollup/rollup-linux-riscv64-gnu': 4.19.1 + '@rollup/rollup-linux-s390x-gnu': 4.19.1 + '@rollup/rollup-linux-x64-gnu': 4.19.1 + '@rollup/rollup-linux-x64-musl': 4.19.1 + '@rollup/rollup-win32-arm64-msvc': 4.19.1 + '@rollup/rollup-win32-ia32-msvc': 4.19.1 + '@rollup/rollup-win32-x64-msvc': 4.19.1 fsevents: 2.3.3 rtl-css-js@1.16.1: @@ -30312,7 +30351,7 @@ snapshots: socket.io-client@4.7.5(bufferutil@4.0.8)(utf-8-validate@6.0.4): dependencies: '@socket.io/component-emitter': 3.1.2 - debug: 4.3.5(supports-color@5.5.0) + debug: 4.3.6 engine.io-client: 6.5.4(bufferutil@4.0.8)(utf-8-validate@6.0.4) socket.io-parser: 4.2.4 transitivePeerDependencies: @@ -30689,10 +30728,10 @@ snapshots: optionalDependencies: '@babel/core': 7.24.9 - stylehacks@5.1.1(postcss@8.4.39): + stylehacks@5.1.1(postcss@8.4.40): dependencies: browserslist: 4.23.0 - postcss: 8.4.39 + postcss: 8.4.40 postcss-selector-parser: 6.0.13 stylis@4.3.1: {} @@ -30803,11 +30842,11 @@ snapshots: normalize-path: 3.0.0 object-hash: 3.0.0 picocolors: 1.0.1 - postcss: 8.4.39 - postcss-import: 15.1.0(postcss@8.4.39) - postcss-js: 4.0.1(postcss@8.4.39) - postcss-load-config: 4.0.1(postcss@8.4.39)(ts-node@10.9.1(@types/node@20.10.5)(typescript@5.4.5)) - postcss-nested: 6.0.1(postcss@8.4.39) + postcss: 8.4.40 + postcss-import: 15.1.0(postcss@8.4.40) + postcss-js: 4.0.1(postcss@8.4.40) + postcss-load-config: 4.0.1(postcss@8.4.40)(ts-node@10.9.1(@types/node@20.10.5)(typescript@5.4.5)) + postcss-nested: 6.0.1(postcss@8.4.40) postcss-selector-parser: 6.0.13 resolve: 1.22.8 sucrase: 3.32.0 @@ -30830,11 +30869,11 @@ snapshots: normalize-path: 3.0.0 object-hash: 3.0.0 picocolors: 1.0.1 - postcss: 8.4.39 - postcss-import: 15.1.0(postcss@8.4.39) - postcss-js: 4.0.1(postcss@8.4.39) - postcss-load-config: 4.0.1(postcss@8.4.39)(ts-node@10.9.1(@types/node@20.11.13)(typescript@5.2.2)) - postcss-nested: 6.0.1(postcss@8.4.39) + postcss: 8.4.40 + postcss-import: 15.1.0(postcss@8.4.40) + postcss-js: 4.0.1(postcss@8.4.40) + postcss-load-config: 4.0.1(postcss@8.4.40)(ts-node@10.9.1(@types/node@20.11.13)(typescript@5.2.2)) + postcss-nested: 6.0.1(postcss@8.4.40) postcss-selector-parser: 6.0.13 resolve: 1.22.8 sucrase: 3.32.0 @@ -30857,11 +30896,11 @@ snapshots: normalize-path: 3.0.0 object-hash: 3.0.0 picocolors: 1.0.1 - postcss: 8.4.39 - postcss-import: 15.1.0(postcss@8.4.39) - postcss-js: 4.0.1(postcss@8.4.39) - postcss-load-config: 4.0.1(postcss@8.4.39)(ts-node@10.9.1(@types/node@20.14.11)(typescript@5.4.5)) - postcss-nested: 6.0.1(postcss@8.4.39) + postcss: 8.4.40 + postcss-import: 15.1.0(postcss@8.4.40) + postcss-js: 4.0.1(postcss@8.4.40) + postcss-load-config: 4.0.1(postcss@8.4.40)(ts-node@10.9.1(@types/node@20.14.11)(typescript@5.4.5)) + postcss-nested: 6.0.1(postcss@8.4.40) postcss-selector-parser: 6.0.13 resolve: 1.22.8 sucrase: 3.32.0 @@ -31206,7 +31245,7 @@ snapshots: tslib@2.6.3: {} - tsup@6.7.0(postcss@8.4.39)(ts-node@10.9.1(@types/node@20.14.11)(typescript@5.4.5))(typescript@5.4.5): + tsup@6.7.0(postcss@8.4.40)(ts-node@10.9.1(@types/node@20.14.11)(typescript@5.4.5))(typescript@5.4.5): dependencies: bundle-require: 4.0.1(esbuild@0.17.19) cac: 6.7.14 @@ -31216,14 +31255,14 @@ snapshots: execa: 5.1.1 globby: 11.1.0 joycon: 3.1.1 - postcss-load-config: 3.1.4(postcss@8.4.39)(ts-node@10.9.1(@types/node@20.14.11)(typescript@5.4.5)) + postcss-load-config: 3.1.4(postcss@8.4.40)(ts-node@10.9.1(@types/node@20.14.11)(typescript@5.4.5)) resolve-from: 5.0.0 rollup: 3.25.3 source-map: 0.8.0-beta.0 sucrase: 3.32.0 tree-kill: 1.2.2 optionalDependencies: - postcss: 8.4.39 + postcss: 8.4.40 typescript: 5.4.5 transitivePeerDependencies: - supports-color @@ -31788,15 +31827,32 @@ snapshots: - supports-color - terser - vite-plugin-json5@1.1.2(@rollup/pluginutils@5.1.0(rollup@4.19.0))(vite@5.3.5(@types/node@20.14.11)(terser@5.31.3)): + vite-node@1.6.0(@types/node@20.14.13)(terser@5.31.3): + dependencies: + cac: 6.7.14 + debug: 4.3.5(supports-color@5.5.0) + pathe: 1.1.2 + picocolors: 1.0.1 + vite: 5.3.5(@types/node@20.14.13)(terser@5.31.3) + transitivePeerDependencies: + - '@types/node' + - less + - lightningcss + - sass + - stylus + - sugarss + - supports-color + - terser + + vite-plugin-json5@1.1.2(@rollup/pluginutils@5.1.0(rollup@4.19.1))(vite@5.3.5(@types/node@20.14.11)(terser@5.31.3)): dependencies: - '@rollup/pluginutils': 5.1.0(rollup@4.19.0) + '@rollup/pluginutils': 5.1.0(rollup@4.19.1) json5: 2.2.3 vite: 5.3.5(@types/node@20.14.11)(terser@5.31.3) - vite-plugin-node-polyfills@0.22.0(rollup@4.19.0)(vite@5.3.5(@types/node@20.14.11)(terser@5.31.3)): + vite-plugin-node-polyfills@0.22.0(rollup@4.19.1)(vite@5.3.5(@types/node@20.14.11)(terser@5.31.3)): dependencies: - '@rollup/plugin-inject': 5.0.5(rollup@4.19.0) + '@rollup/plugin-inject': 5.0.5(rollup@4.19.1) node-stdlib-browser: 1.2.0 vite: 5.3.5(@types/node@20.14.11)(terser@5.31.3) transitivePeerDependencies: @@ -31811,8 +31867,8 @@ snapshots: vite@5.3.5(@types/node@20.10.5)(terser@5.31.3): dependencies: esbuild: 0.21.5 - postcss: 8.4.39 - rollup: 4.19.0 + postcss: 8.4.40 + rollup: 4.19.1 optionalDependencies: '@types/node': 20.10.5 fsevents: 2.3.3 @@ -31821,30 +31877,40 @@ snapshots: vite@5.3.5(@types/node@20.14.11)(terser@5.31.3): dependencies: esbuild: 0.21.5 - postcss: 8.4.39 - rollup: 4.19.0 + postcss: 8.4.40 + rollup: 4.19.1 optionalDependencies: '@types/node': 20.14.11 fsevents: 2.3.3 terser: 5.31.3 - vitepress-plugin-search@1.0.4-alpha.19(flexsearch@0.7.43)(vitepress@1.3.1(@algolia/client-search@4.22.1)(@types/node@20.14.11)(@types/react@18.3.3)(change-case@4.1.2)(idb-keyval@6.2.1)(postcss@8.4.39)(qrcode@1.5.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(search-insights@2.11.0)(terser@5.31.3)(typescript@5.4.5))(vue@3.4.34(typescript@5.4.5)): + vite@5.3.5(@types/node@20.14.13)(terser@5.31.3): + dependencies: + esbuild: 0.21.5 + postcss: 8.4.40 + rollup: 4.19.1 + optionalDependencies: + '@types/node': 20.14.13 + fsevents: 2.3.3 + terser: 5.31.3 + + vitepress-plugin-search@1.0.4-alpha.19(flexsearch@0.7.43)(vitepress@1.3.1(@algolia/client-search@4.22.1)(@types/node@20.14.13)(@types/react@18.3.3)(change-case@4.1.2)(idb-keyval@6.2.1)(postcss@8.4.40)(qrcode@1.5.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(search-insights@2.11.0)(terser@5.31.3)(typescript@5.4.5))(vue@3.4.34(typescript@5.4.5)): dependencies: '@types/flexsearch': 0.7.3 '@types/markdown-it': 12.2.3 flexsearch: 0.7.43 markdown-it: 13.0.1 - vitepress: 1.3.1(@algolia/client-search@4.22.1)(@types/node@20.14.11)(@types/react@18.3.3)(change-case@4.1.2)(idb-keyval@6.2.1)(postcss@8.4.39)(qrcode@1.5.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(search-insights@2.11.0)(terser@5.31.3)(typescript@5.4.5) + vitepress: 1.3.1(@algolia/client-search@4.22.1)(@types/node@20.14.13)(@types/react@18.3.3)(change-case@4.1.2)(idb-keyval@6.2.1)(postcss@8.4.40)(qrcode@1.5.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(search-insights@2.11.0)(terser@5.31.3)(typescript@5.4.5) vue: 3.4.34(typescript@5.4.5) - vitepress@1.3.1(@algolia/client-search@4.22.1)(@types/node@20.14.11)(@types/react@18.3.3)(change-case@4.1.2)(idb-keyval@6.2.1)(postcss@8.4.39)(qrcode@1.5.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(search-insights@2.11.0)(terser@5.31.3)(typescript@5.4.5): + vitepress@1.3.1(@algolia/client-search@4.22.1)(@types/node@20.14.13)(@types/react@18.3.3)(change-case@4.1.2)(idb-keyval@6.2.1)(postcss@8.4.40)(qrcode@1.5.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(search-insights@2.11.0)(terser@5.31.3)(typescript@5.4.5): dependencies: '@docsearch/css': 3.6.0 '@docsearch/js': 3.6.0(@algolia/client-search@4.22.1)(@types/react@18.3.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(search-insights@2.11.0) '@shikijs/core': 1.10.3 '@shikijs/transformers': 1.10.3 '@types/markdown-it': 14.1.2 - '@vitejs/plugin-vue': 5.0.5(vite@5.3.5(@types/node@20.14.11)(terser@5.31.3))(vue@3.4.34(typescript@5.4.5)) + '@vitejs/plugin-vue': 5.0.5(vite@5.3.5(@types/node@20.14.13)(terser@5.31.3))(vue@3.4.34(typescript@5.4.5)) '@vue/devtools-api': 7.3.6 '@vue/shared': 3.4.31 '@vueuse/core': 10.11.0(vue@3.4.34(typescript@5.4.5)) @@ -31853,10 +31919,10 @@ snapshots: mark.js: 8.11.1 minisearch: 7.0.0 shiki: 1.10.3 - vite: 5.3.5(@types/node@20.14.11)(terser@5.31.3) + vite: 5.3.5(@types/node@20.14.13)(terser@5.31.3) vue: 3.4.34(typescript@5.4.5) optionalDependencies: - postcss: 8.4.39 + postcss: 8.4.40 transitivePeerDependencies: - '@algolia/client-search' - '@types/node' @@ -31954,6 +32020,41 @@ snapshots: - supports-color - terser + vitest@1.6.0(@types/node@20.14.13)(@vitest/browser@1.6.0)(jsdom@16.7.0(bufferutil@4.0.8)(utf-8-validate@6.0.4))(terser@5.31.3): + dependencies: + '@vitest/expect': 1.6.0 + '@vitest/runner': 1.6.0 + '@vitest/snapshot': 1.6.0 + '@vitest/spy': 1.6.0 + '@vitest/utils': 1.6.0 + acorn-walk: 8.3.2 + chai: 4.4.1 + debug: 4.3.5(supports-color@5.5.0) + execa: 8.0.1 + local-pkg: 0.5.0 + magic-string: 0.30.10 + pathe: 1.1.2 + picocolors: 1.0.1 + std-env: 3.7.0 + strip-literal: 2.1.0 + tinybench: 2.8.0 + tinypool: 0.8.4 + vite: 5.3.5(@types/node@20.14.13)(terser@5.31.3) + vite-node: 1.6.0(@types/node@20.14.13)(terser@5.31.3) + why-is-node-running: 2.2.2 + optionalDependencies: + '@types/node': 20.14.13 + '@vitest/browser': 1.6.0(playwright@1.45.3)(vitest@1.6.0)(webdriverio@8.39.1(bufferutil@4.0.8)(typescript@5.4.5)(utf-8-validate@6.0.4)) + jsdom: 16.7.0(bufferutil@4.0.8)(utf-8-validate@6.0.4) + transitivePeerDependencies: + - less + - lightningcss + - sass + - stylus + - sugarss + - supports-color + - terser + vlq@1.0.1: {} vm-browserify@1.1.2: {} @@ -32136,7 +32237,7 @@ snapshots: sockjs: 0.3.24 spdy: 4.0.2 webpack-dev-middleware: 5.3.3(webpack@5.88.0(esbuild@0.17.19)) - ws: 8.13.0(bufferutil@4.0.8)(utf-8-validate@6.0.4) + ws: 8.17.1(bufferutil@4.0.8)(utf-8-validate@6.0.4) optionalDependencies: webpack: 5.88.0(esbuild@0.17.19) transitivePeerDependencies: @@ -32513,7 +32614,7 @@ snapshots: yaml@2.3.1: {} - yaml@2.4.5: {} + yaml@2.5.0: {} yargs-parser@18.1.3: dependencies: From f035b8c8fb8b560255c40319272bcac728dd4aa3 Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Mon, 29 Jul 2024 13:52:15 +0100 Subject: [PATCH 38/43] reinstall ramda --- packages/abi-coder/package.json | 4 ++-- pnpm-lock.yaml | 27 ++++----------------------- 2 files changed, 6 insertions(+), 25 deletions(-) diff --git a/packages/abi-coder/package.json b/packages/abi-coder/package.json index 279a34cb3f1..2919ec7b89a 100644 --- a/packages/abi-coder/package.json +++ b/packages/abi-coder/package.json @@ -33,10 +33,10 @@ "@fuel-ts/interfaces": "workspace:*", "@fuel-ts/math": "workspace:*", "@fuel-ts/utils": "workspace:*", - "ramda": "^0.29.0", + "ramda": "^0.30.1", "type-fest": "^3.1.0" }, "devDependencies": { - "@types/ramda": "^0.29.3" + "@types/ramda": "^0.30.1" } } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 549d1d9e6a4..da689ce94dd 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -617,15 +617,15 @@ importers: specifier: workspace:* version: link:../utils ramda: - specifier: ^0.29.0 - version: 0.29.1 + specifier: ^0.30.1 + version: 0.30.1 type-fest: specifier: ^3.1.0 version: 3.1.0 devDependencies: '@types/ramda': - specifier: ^0.29.3 - version: 0.29.12 + specifier: ^0.30.1 + version: 0.30.1 packages/abi-typegen: dependencies: @@ -5229,9 +5229,6 @@ packages: '@types/qs@6.9.7': resolution: {integrity: sha512-FGa1F62FT09qcrueBA6qYTrJPVDzah9a+493+o2PCXsesWHIn27G98TsSMs3WPNbZIEj4+VJf6saSFpvD+3Zsw==} - '@types/ramda@0.29.12': - resolution: {integrity: sha512-sgIEjpJhdQPB52gDF4aphs9nl0xe54CR22DPdWqT8gQHjZYmVApgA0R3/CpMbl0Y8az2TEZrPNL2zy0EvjbkLA==} - '@types/ramda@0.30.1': resolution: {integrity: sha512-aoyF/ADPL6N+/NXXfhPWF+Qj6w1Cql59m9wX0Gi15uyF+bpzXeLd63HPdiTDE2bmLXfNcVufsDPKmbfOrOzTBA==} @@ -11758,9 +11755,6 @@ packages: raf@3.4.1: resolution: {integrity: sha512-Sq4CW4QhwOHE8ucn6J34MqtZCeWFP2aQSmrlroYgqAV1PjStIhJXxYuTgUIfkEk7zTLjmIjLmU5q+fbD1NnOJA==} - ramda@0.29.1: - resolution: {integrity: sha512-OfxIeWzd4xdUNxlWhgFazxsA/nl3mS4/jGZI5n00uWOoSSFRhC1b6gl6xvmzUamgmqELraWp0J/qqVlXYPDPyA==} - ramda@0.30.1: resolution: {integrity: sha512-tEF5I22zJnuclswcZMc8bDIrwRHRzf+NqVEmqg50ShAZMP7MWeR/RGDthfM/p+BlqvF2fXAzpn8i+SJcYD3alw==} @@ -13357,9 +13351,6 @@ packages: peerDependencies: typescript: 4.6.x || 4.7.x || 4.8.x || 4.9.x || 5.0.x || 5.1.x || 5.2.x || 5.3.x || 5.4.x - types-ramda@0.29.10: - resolution: {integrity: sha512-5PJiW/eiTPyXXBYGZOYGezMl6qj7keBiZheRwfjJZY26QPHsNrjfJnz0mru6oeqqoTHOni893Jfd6zyUXfQRWg==} - types-ramda@0.30.1: resolution: {integrity: sha512-1HTsf5/QVRmLzcGfldPFvkVsAdi1db1BBKzi7iW3KBUlOICg/nKnFS+jGqDJS3YD8VsWbAh7JiHeBvbsw8RPxA==} @@ -20460,10 +20451,6 @@ snapshots: '@types/qs@6.9.7': {} - '@types/ramda@0.29.12': - dependencies: - types-ramda: 0.29.10 - '@types/ramda@0.30.1': dependencies: types-ramda: 0.30.1 @@ -29362,8 +29349,6 @@ snapshots: dependencies: performance-now: 2.1.0 - ramda@0.29.1: {} - ramda@0.30.1: {} randombytes@2.1.0: @@ -31420,10 +31405,6 @@ snapshots: shiki: 0.14.7 typescript: 5.4.5 - types-ramda@0.29.10: - dependencies: - ts-toolbelt: 9.6.0 - types-ramda@0.30.1: dependencies: ts-toolbelt: 9.6.0 From 3dd8f6b29109c20cf22ec72bfcd0b9af6aeba8d9 Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Mon, 29 Jul 2024 13:58:34 +0100 Subject: [PATCH 39/43] Removed dependency on ramda --- packages/abi-coder/package.json | 4 ---- packages/abi-coder/src/utils/getFunctionInputs.ts | 4 +--- packages/abi-typegen/src/utils/getFunctionInputs.ts | 4 +--- pnpm-lock.yaml | 8 +------- 4 files changed, 3 insertions(+), 17 deletions(-) diff --git a/packages/abi-coder/package.json b/packages/abi-coder/package.json index 2919ec7b89a..16c55ee903b 100644 --- a/packages/abi-coder/package.json +++ b/packages/abi-coder/package.json @@ -33,10 +33,6 @@ "@fuel-ts/interfaces": "workspace:*", "@fuel-ts/math": "workspace:*", "@fuel-ts/utils": "workspace:*", - "ramda": "^0.30.1", "type-fest": "^3.1.0" - }, - "devDependencies": { - "@types/ramda": "^0.30.1" } } diff --git a/packages/abi-coder/src/utils/getFunctionInputs.ts b/packages/abi-coder/src/utils/getFunctionInputs.ts index 1545fda6e3e..bae6aee5a34 100644 --- a/packages/abi-coder/src/utils/getFunctionInputs.ts +++ b/packages/abi-coder/src/utils/getFunctionInputs.ts @@ -1,5 +1,3 @@ -import { clone } from 'ramda'; - import type { JsonAbi, JsonAbiArgument } from '../types/JsonAbi'; import { OPTION_REGEX, VOID_TYPE } from './constants'; @@ -14,7 +12,7 @@ export const getFunctionInputs = (params: { inputs: readonly JsonAbiArgument[]; }): Array => { let inMandatoryRegion = false; - const inputs = clone(params.inputs); + const inputs = structuredClone(params.inputs); return (inputs as Array) .reverse() diff --git a/packages/abi-typegen/src/utils/getFunctionInputs.ts b/packages/abi-typegen/src/utils/getFunctionInputs.ts index 15cd38a675a..02614527d4b 100644 --- a/packages/abi-typegen/src/utils/getFunctionInputs.ts +++ b/packages/abi-typegen/src/utils/getFunctionInputs.ts @@ -1,5 +1,3 @@ -import { clone } from 'ramda'; - import { EmptyType } from '../abi/types/EmptyType'; import { OptionType } from '../abi/types/OptionType'; import type { IType } from '../types/interfaces/IType'; @@ -16,7 +14,7 @@ export const getFunctionInputs = (params: { inputs: readonly JsonAbiArgument[]; }): Array => { let inMandatoryRegion = false; - const inputs = clone(params.inputs); + const inputs = structuredClone(params.inputs); return (inputs as Array) .reverse() diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index da689ce94dd..b5e09164331 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -616,16 +616,9 @@ importers: '@fuel-ts/utils': specifier: workspace:* version: link:../utils - ramda: - specifier: ^0.30.1 - version: 0.30.1 type-fest: specifier: ^3.1.0 version: 3.1.0 - devDependencies: - '@types/ramda': - specifier: ^0.30.1 - version: 0.30.1 packages/abi-typegen: dependencies: @@ -6557,6 +6550,7 @@ packages: bun@1.1.21: resolution: {integrity: sha512-mvqYEvafGskIVTjlftbKvsXtyR6z/SQnhJsVw0xCU46pc56oX1sAGvaemWKOy/sy/gGMHcgLE0KUidDQQzqXWQ==} + cpu: [arm64, x64] os: [darwin, linux, win32] hasBin: true From 2f5b4bb7399a268b9d736ed73bddda15403d0fc2 Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Tue, 30 Jul 2024 06:54:18 +0100 Subject: [PATCH 40/43] Added `@group browser` tests --- apps/docs-snippets/src/guide/types/options.test.ts | 3 ++- packages/abi-coder/src/encoding/coders/VoidCoder.test.ts | 1 + packages/abi-coder/src/utils/getFunctionInputs.test.ts | 1 + packages/abi-typegen/src/utils/getFunctionInputs.test.ts | 1 + packages/fuel-gauge/src/void.test.ts | 1 + 5 files changed, 6 insertions(+), 1 deletion(-) diff --git a/apps/docs-snippets/src/guide/types/options.test.ts b/apps/docs-snippets/src/guide/types/options.test.ts index e91a66fc1d2..fb18259debd 100644 --- a/apps/docs-snippets/src/guide/types/options.test.ts +++ b/apps/docs-snippets/src/guide/types/options.test.ts @@ -11,8 +11,9 @@ function setupContract() { /** * @group node + * @group browser */ -describe(__filename, () => { +describe('options', () => { it('should successfully execute contract call to sum 2 option inputs (2 INPUTS)', async () => { using launched = await setupContract(); const { diff --git a/packages/abi-coder/src/encoding/coders/VoidCoder.test.ts b/packages/abi-coder/src/encoding/coders/VoidCoder.test.ts index d9b653d798d..de494da7fef 100644 --- a/packages/abi-coder/src/encoding/coders/VoidCoder.test.ts +++ b/packages/abi-coder/src/encoding/coders/VoidCoder.test.ts @@ -2,6 +2,7 @@ import { VoidCoder } from './VoidCoder'; /** * @group node + * @group browser */ describe('VoidCoder', () => { it('should have properties', () => { diff --git a/packages/abi-coder/src/utils/getFunctionInputs.test.ts b/packages/abi-coder/src/utils/getFunctionInputs.test.ts index 538e2503cd1..7bab5a7e85c 100644 --- a/packages/abi-coder/src/utils/getFunctionInputs.test.ts +++ b/packages/abi-coder/src/utils/getFunctionInputs.test.ts @@ -47,6 +47,7 @@ const jsonAbi: JsonAbi = { /** * @group node + * @group browser */ describe.each(EMPTY_ABI_TYPES)( 'getFunctionInputs.ts [empty=%s]', diff --git a/packages/abi-typegen/src/utils/getFunctionInputs.test.ts b/packages/abi-typegen/src/utils/getFunctionInputs.test.ts index b60e394d0e5..d993fe8dce5 100644 --- a/packages/abi-typegen/src/utils/getFunctionInputs.test.ts +++ b/packages/abi-typegen/src/utils/getFunctionInputs.test.ts @@ -44,6 +44,7 @@ const types: Array = [nonEmptyType, voidAbiType, optionAbiType, debugOpti /** * @group node + * @group browser */ describe.each(EMPTY_ABI_TYPES)( 'getFunctionInputs.ts [empty=%s]', diff --git a/packages/fuel-gauge/src/void.test.ts b/packages/fuel-gauge/src/void.test.ts index 50efa7e967c..4f5a04b6b81 100644 --- a/packages/fuel-gauge/src/void.test.ts +++ b/packages/fuel-gauge/src/void.test.ts @@ -7,6 +7,7 @@ import type { Option } from '../test/typegen/contracts/common'; /** * @group node + * @group browser */ describe('Void Tests', () => { const contractsConfigs = [ From 71a1309b87050e391251fef84fe2cd57ded1afe6 Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Tue, 30 Jul 2024 07:05:58 +0100 Subject: [PATCH 41/43] chore: implemented optimizations for `getFunctionInputs` --- .../abi-coder/src/utils/getFunctionInputs.ts | 29 +++++----------- .../src/utils/getFunctionInputs.ts | 34 +++++++------------ 2 files changed, 21 insertions(+), 42 deletions(-) diff --git a/packages/abi-coder/src/utils/getFunctionInputs.ts b/packages/abi-coder/src/utils/getFunctionInputs.ts index bae6aee5a34..784694847be 100644 --- a/packages/abi-coder/src/utils/getFunctionInputs.ts +++ b/packages/abi-coder/src/utils/getFunctionInputs.ts @@ -3,31 +3,20 @@ import type { JsonAbi, JsonAbiArgument } from '../types/JsonAbi'; import { OPTION_REGEX, VOID_TYPE } from './constants'; import { findTypeById } from './json-abi'; -export type ArgumentWithMetadata = TArg & { +export type FunctionInput = TArg & { isOptional: boolean; }; export const getFunctionInputs = (params: { jsonAbi: JsonAbi; inputs: readonly JsonAbiArgument[]; -}): Array => { - let inMandatoryRegion = false; - const inputs = structuredClone(params.inputs); +}): Array => { + const { jsonAbi, inputs } = params; + let isMandatory = false; - return (inputs as Array) - .reverse() - .map((input) => { - if (inMandatoryRegion) { - return { ...input, isOptional: false }; - } - - const type = findTypeById(params.jsonAbi, input.type); - if (type.type === VOID_TYPE || type.type.match(OPTION_REGEX)) { - return { ...input, isOptional: true }; - } - - inMandatoryRegion = true; - return { ...input, isOptional: false }; - }) - .reverse(); + return inputs.reduceRight((result, input) => { + const type = findTypeById(jsonAbi, input.type); + isMandatory = isMandatory || (type.type !== VOID_TYPE && !OPTION_REGEX.test(type.type)); + return [{ ...input, isOptional: !isMandatory }, ...result]; + }, [] as FunctionInput[]); }; diff --git a/packages/abi-typegen/src/utils/getFunctionInputs.ts b/packages/abi-typegen/src/utils/getFunctionInputs.ts index 02614527d4b..62df774ea8a 100644 --- a/packages/abi-typegen/src/utils/getFunctionInputs.ts +++ b/packages/abi-typegen/src/utils/getFunctionInputs.ts @@ -5,34 +5,24 @@ import type { JsonAbiArgument } from '../types/interfaces/JsonAbi'; import { findType } from './findType'; -export type ArgumentWithMetadata = TArg & { +export type FunctionInput = TArg & { isOptional: boolean; }; export const getFunctionInputs = (params: { types: IType[]; inputs: readonly JsonAbiArgument[]; -}): Array => { - let inMandatoryRegion = false; - const inputs = structuredClone(params.inputs); +}): Array => { + const { types, inputs } = params; + let isMandatory = false; - return (inputs as Array) - .reverse() - .map((input) => { - if (inMandatoryRegion) { - return { ...input, isOptional: false }; - } + return inputs.reduceRight((result, input) => { + const type = findType({ types, typeId: input.type }); + const isTypeMandatory = + !EmptyType.isSuitableFor({ type: type.rawAbiType.type }) && + !OptionType.isSuitableFor({ type: type.rawAbiType.type }); - const type = findType({ types: params.types, typeId: input.type }); - if ( - EmptyType.isSuitableFor({ type: type.rawAbiType.type }) || - OptionType.isSuitableFor({ type: type.rawAbiType.type }) - ) { - return { ...input, isOptional: true }; - } - - inMandatoryRegion = true; - return { ...input, isOptional: false }; - }) - .reverse(); + isMandatory = isMandatory || isTypeMandatory; + return [{ ...input, isOptional: !isMandatory }, ...result]; + }, [] as FunctionInput[]); }; From 1c32d0f385cd71145bac37ac645afd7f794ab1ea Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Tue, 30 Jul 2024 08:39:01 +0100 Subject: [PATCH 42/43] chore: implemented `padValuesWithUndefined` --- packages/abi-coder/src/FunctionFragment.ts | 11 ++--- .../src/utils/padValuesWithUndefined.test.ts | 48 +++++++++++++++++++ .../src/utils/padValuesWithUndefined.ts | 12 +++++ 3 files changed, 63 insertions(+), 8 deletions(-) create mode 100644 packages/abi-coder/src/utils/padValuesWithUndefined.test.ts create mode 100644 packages/abi-coder/src/utils/padValuesWithUndefined.ts diff --git a/packages/abi-coder/src/FunctionFragment.ts b/packages/abi-coder/src/FunctionFragment.ts index c90e2c39281..addc6eed345 100644 --- a/packages/abi-coder/src/FunctionFragment.ts +++ b/packages/abi-coder/src/FunctionFragment.ts @@ -14,6 +14,7 @@ import type { JsonAbi, JsonAbiFunction, JsonAbiFunctionAttribute } from './types import type { EncodingVersion } from './utils/constants'; import { getFunctionInputs } from './utils/getFunctionInputs'; import { findFunctionByName, findNonVoidInputs, getEncodingVersion } from './utils/json-abi'; +import { padValuesWithUndefined } from './utils/padValuesWithUndefined'; export class FunctionFragment< TAbi extends JsonAbi = JsonAbi, @@ -58,7 +59,6 @@ export class FunctionFragment< encodeArguments(values: InputValue[]): Uint8Array { const inputs = getFunctionInputs({ jsonAbi: this.jsonAbi, inputs: this.jsonFn.inputs }); const mandatoryInputLength = inputs.filter((i) => !i.isOptional).length; - if (values.length < mandatoryInputLength) { throw new FuelError( ErrorCode.ABI_TYPES_AND_VALUES_MISMATCH, @@ -66,19 +66,14 @@ export class FunctionFragment< ); } - const shallowCopyValues = values.slice(); - if (Array.isArray(values) && this.jsonFn.inputs.length > values.length) { - shallowCopyValues.length = this.jsonFn.inputs.length; - shallowCopyValues.fill(undefined as unknown as InputValue, values.length); - } - const coders = this.jsonFn.inputs.map((t) => AbiCoder.getCoder(this.jsonAbi, t, { encoding: this.encoding, }) ); - return new TupleCoder(coders).encode(shallowCopyValues); + const argumentValues = padValuesWithUndefined(values, this.jsonFn.inputs); + return new TupleCoder(coders).encode(argumentValues); } decodeArguments(data: BytesLike) { diff --git a/packages/abi-coder/src/utils/padValuesWithUndefined.test.ts b/packages/abi-coder/src/utils/padValuesWithUndefined.test.ts new file mode 100644 index 00000000000..f910ab10be9 --- /dev/null +++ b/packages/abi-coder/src/utils/padValuesWithUndefined.test.ts @@ -0,0 +1,48 @@ +import type { InputValue } from '../encoding/coders/AbstractCoder'; +import type { JsonAbiArgument } from '../types/JsonAbi'; + +import { padValuesWithUndefined } from './padValuesWithUndefined'; + +const MOCK_INPUT: JsonAbiArgument = { + name: 'test', + type: 0, + typeArguments: [], +}; + +describe('padValuesWithUndefined', () => { + it('should not pad values if they are already the same length as inputs', () => { + const values: InputValue[] = [1, 2, 3]; + const inputs: ReadonlyArray = [MOCK_INPUT, MOCK_INPUT, MOCK_INPUT]; + + const result = padValuesWithUndefined(values, inputs); + + expect(result).toEqual(values); + }); + + it('should not pad values if they are longer than inputs', () => { + const values: InputValue[] = [1, 2, 3]; + const inputs: ReadonlyArray = [MOCK_INPUT, MOCK_INPUT]; + + const result = padValuesWithUndefined(values, inputs); + + expect(result).toEqual(values); + }); + + it('should pad values with undefined if they are shorter than inputs', () => { + const values: InputValue[] = [1, 2]; + const inputs: ReadonlyArray = [MOCK_INPUT, MOCK_INPUT, MOCK_INPUT]; + + const result = padValuesWithUndefined(values, inputs); + + expect(result).toEqual([1, 2, undefined]); + }); + + it('should pad values with undefined if they are empty', () => { + const values: InputValue[] = []; + const inputs: ReadonlyArray = [MOCK_INPUT, MOCK_INPUT, MOCK_INPUT]; + + const result = padValuesWithUndefined(values, inputs); + + expect(result).toEqual([undefined, undefined, undefined]); + }); +}); diff --git a/packages/abi-coder/src/utils/padValuesWithUndefined.ts b/packages/abi-coder/src/utils/padValuesWithUndefined.ts new file mode 100644 index 00000000000..7410fa8ee45 --- /dev/null +++ b/packages/abi-coder/src/utils/padValuesWithUndefined.ts @@ -0,0 +1,12 @@ +import type { InputValue } from '../encoding/coders/AbstractCoder'; + +export const padValuesWithUndefined = (values: InputValue[], inputs: ArrayLike) => { + if (values.length >= inputs.length) { + return values; + } + + const paddedValues = values.slice(); + paddedValues.length = inputs.length; + paddedValues.fill(undefined, values.length); + return paddedValues; +}; From a38591813ef24a87498dd8586d777914ed83d443 Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Tue, 30 Jul 2024 08:56:45 +0100 Subject: [PATCH 43/43] chore: added missing test groupings --- packages/abi-coder/src/utils/padValuesWithUndefined.test.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/abi-coder/src/utils/padValuesWithUndefined.test.ts b/packages/abi-coder/src/utils/padValuesWithUndefined.test.ts index f910ab10be9..728a8b29240 100644 --- a/packages/abi-coder/src/utils/padValuesWithUndefined.test.ts +++ b/packages/abi-coder/src/utils/padValuesWithUndefined.test.ts @@ -9,6 +9,10 @@ const MOCK_INPUT: JsonAbiArgument = { typeArguments: [], }; +/** + * @group node + * @group browser + */ describe('padValuesWithUndefined', () => { it('should not pad values if they are already the same length as inputs', () => { const values: InputValue[] = [1, 2, 3];