From 18b58b194bf5fc40dfaa789af78f89998663c82d Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Sat, 9 Sep 2023 05:03:07 -0700 Subject: [PATCH 01/37] chore: first pass --- packages/form-core/package.json | 3 ++ packages/form-core/src/FieldApi.ts | 27 ++++++++--- .../form-core/src/tests/FieldApi.test-d.ts | 46 +++++++++++++++++++ packages/form-core/src/zod-validator.ts | 36 +++++++++++++++ pnpm-lock.yaml | 5 +- 5 files changed, 110 insertions(+), 7 deletions(-) create mode 100644 packages/form-core/src/zod-validator.ts diff --git a/packages/form-core/package.json b/packages/form-core/package.json index 71c1e610a..571c748f0 100644 --- a/packages/form-core/package.json +++ b/packages/form-core/package.json @@ -52,5 +52,8 @@ }, "dependencies": { "@tanstack/store": "0.1.3" + }, + "devDependencies": { + "zod": "^3.21.4" } } diff --git a/packages/form-core/src/FieldApi.ts b/packages/form-core/src/FieldApi.ts index 2ed5547cf..9ebedd906 100644 --- a/packages/form-core/src/FieldApi.ts +++ b/packages/form-core/src/FieldApi.ts @@ -1,13 +1,24 @@ import { type DeepKeys, type DeepValue, type Updater } from './utils' import type { FormApi, ValidationError, ValidationErrorMap } from './FormApi' import { Store } from '@tanstack/store' +import { Validator } from './zod-validator' export type ValidationCause = 'change' | 'blur' | 'submit' | 'mount' -type ValidateFn = ( - value: TData, - fieldApi: FieldApi, -) => ValidationError +type ValidateFn< + TData, + TFormData, + ValidatorType extends Validator | undefined = + | Validator + | undefined, +> = unknown extends ValidatorType + ? (value: TData, fieldApi: FieldApi) => ValidationError + : ReturnType>['validate'] extends ( + value: infer _TData, + fn: infer ValidateFn, + ) => ValidationError + ? ValidateFn + : never type ValidateAsyncFn = ( value: TData, @@ -26,6 +37,9 @@ export interface FieldOptions< * If TData is unknown, we can use the TName generic to determine the type */ TData = unknown extends _TData ? DeepValue : _TData, + ValidatorType extends Validator | undefined = + | Validator + | undefined, > { name: TName index?: TData extends any[] ? number : never @@ -33,14 +47,15 @@ export interface FieldOptions< asyncDebounceMs?: number asyncAlways?: boolean onMount?: (formApi: FieldApi) => void - onChange?: ValidateFn + onChange?: ValidateFn onChangeAsync?: ValidateAsyncFn onChangeAsyncDebounceMs?: number - onBlur?: ValidateFn + onBlur?: ValidateFn onBlurAsync?: ValidateAsyncFn onBlurAsyncDebounceMs?: number onSubmitAsync?: ValidateAsyncFn defaultMeta?: Partial + validator?: ValidatorType } export interface FieldApiOptions< diff --git a/packages/form-core/src/tests/FieldApi.test-d.ts b/packages/form-core/src/tests/FieldApi.test-d.ts index 959b0a2be..c63dd04f5 100644 --- a/packages/form-core/src/tests/FieldApi.test-d.ts +++ b/packages/form-core/src/tests/FieldApi.test-d.ts @@ -1,6 +1,8 @@ import { assertType } from 'vitest' import { FormApi } from '../FormApi' import { FieldApi } from '../FieldApi' +import { zodValidator } from '../zod-validator' +import z from 'zod' it('should type a subfield properly', () => { const form = new FormApi({ @@ -39,3 +41,47 @@ it('should type onChange properly', () => { }, }) }) + +it('should allow a Zod validator to be passed in', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + } as const) + + const field = new FieldApi({ + form, + name: 'name', + validator: zodValidator, + }) +}) + +it('should allow a Zod validator to handle the correct Zod type', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + }) + + const field = new FieldApi({ + form, + name: 'name', + validator: zodValidator, + onChange: z.string(), + }) +}) + +it('should allow not a Zod validator with the wrong Zod type', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + }) + + const field = new FieldApi({ + form, + name: 'name', + validator: zodValidator, + onChange: z.object({}), + }) +}) diff --git a/packages/form-core/src/zod-validator.ts b/packages/form-core/src/zod-validator.ts new file mode 100644 index 000000000..dfbcc5f40 --- /dev/null +++ b/packages/form-core/src/zod-validator.ts @@ -0,0 +1,36 @@ +import { ValidationError } from '@tanstack/form-core' +import type { ZodError, ZodType, ZodTypeAny } from 'zod' + +export type Validator = < + InferedType extends PassedType = PassedType, + Fn extends PassedFnType = PassedFnType, +>() => { + // If/when TypeScript supports higher-kinded types, this should not be `unknown` anymore + validate(value: InferedType, fn: Fn): ValidationError + validateAsync(value: InferedType, fn: Fn): Promise +} + +export const zodValidator = ( = ZodType>() => { + return { + validate(value: T, fn: Fn): ValidationError { + // Call Zod on the value here and return the error message + try { + fn.parse(value) + return + } catch (_e) { + const e = _e as ZodError + return e.toString() + } + }, + async validateAsync(value: T, fn: Fn): Promise { + // Call Zod on the value here and return the error message + try { + await fn.parseAsync(value) + return + } catch (_e) { + const e = _e as ZodError + return e.toString() + } + }, + } +}) satisfies Validator> diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 0d67ee286..deadb3fc3 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -287,6 +287,10 @@ importers: '@tanstack/store': specifier: 0.1.3 version: 0.1.3 + devDependencies: + zod: + specifier: ^3.21.4 + version: 3.21.4 packages/react-form: dependencies: @@ -10194,4 +10198,3 @@ packages: /zod@3.21.4: resolution: {integrity: sha512-m46AKbrzKVzOzs/DZgVnG5H55N1sv1M8qZU3A8RIKbs3mrACDNeIOeilDymVb2HdmP8uwshOCF4uJ8uM9rCqJw==} - dev: false From f7effb86c0cbaecad8296769a121e75723afbc8a Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Sat, 9 Sep 2023 05:24:53 -0700 Subject: [PATCH 02/37] chore: onto something I think --- packages/form-core/src/FieldApi.ts | 10 ++++------ packages/form-core/src/tests/FieldApi.test-d.ts | 2 +- packages/form-core/src/zod-validator.ts | 9 +++------ 3 files changed, 8 insertions(+), 13 deletions(-) diff --git a/packages/form-core/src/FieldApi.ts b/packages/form-core/src/FieldApi.ts index 9ebedd906..74dd1a046 100644 --- a/packages/form-core/src/FieldApi.ts +++ b/packages/form-core/src/FieldApi.ts @@ -8,10 +8,8 @@ export type ValidationCause = 'change' | 'blur' | 'submit' | 'mount' type ValidateFn< TData, TFormData, - ValidatorType extends Validator | undefined = - | Validator - | undefined, -> = unknown extends ValidatorType + ValidatorType extends Validator | undefined = undefined, +> = ValidatorType extends undefined ? (value: TData, fieldApi: FieldApi) => ValidationError : ReturnType>['validate'] extends ( value: infer _TData, @@ -37,8 +35,8 @@ export interface FieldOptions< * If TData is unknown, we can use the TName generic to determine the type */ TData = unknown extends _TData ? DeepValue : _TData, - ValidatorType extends Validator | undefined = - | Validator + ValidatorType extends Validator | undefined = + | Validator | undefined, > { name: TName diff --git a/packages/form-core/src/tests/FieldApi.test-d.ts b/packages/form-core/src/tests/FieldApi.test-d.ts index c63dd04f5..352a44570 100644 --- a/packages/form-core/src/tests/FieldApi.test-d.ts +++ b/packages/form-core/src/tests/FieldApi.test-d.ts @@ -83,5 +83,5 @@ it('should allow not a Zod validator with the wrong Zod type', () => { name: 'name', validator: zodValidator, onChange: z.object({}), - }) + } as const) }) diff --git a/packages/form-core/src/zod-validator.ts b/packages/form-core/src/zod-validator.ts index dfbcc5f40..01f9ea3fb 100644 --- a/packages/form-core/src/zod-validator.ts +++ b/packages/form-core/src/zod-validator.ts @@ -1,16 +1,13 @@ import { ValidationError } from '@tanstack/form-core' import type { ZodError, ZodType, ZodTypeAny } from 'zod' -export type Validator = < - InferedType extends PassedType = PassedType, - Fn extends PassedFnType = PassedFnType, ->() => { +export type Validator = () => { // If/when TypeScript supports higher-kinded types, this should not be `unknown` anymore validate(value: InferedType, fn: Fn): ValidationError validateAsync(value: InferedType, fn: Fn): Promise } -export const zodValidator = ( = ZodType>() => { +export const zodValidator = (>() => { return { validate(value: T, fn: Fn): ValidationError { // Call Zod on the value here and return the error message @@ -33,4 +30,4 @@ export const zodValidator = ( = ZodType>() => { } }, } -}) satisfies Validator> +}) satisfies Validator From b3d8dc20c23a24101e595dc242e35abde6b1cefc Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Sat, 9 Sep 2023 05:28:02 -0700 Subject: [PATCH 03/37] chore: closer but no cigar --- packages/form-core/src/FieldApi.ts | 6 +++--- .../form-core/src/tests/FieldApi.test-d.ts | 4 ++-- packages/form-core/src/zod-validator.ts | 18 +++++++++--------- 3 files changed, 14 insertions(+), 14 deletions(-) diff --git a/packages/form-core/src/FieldApi.ts b/packages/form-core/src/FieldApi.ts index 74dd1a046..d79c99eb0 100644 --- a/packages/form-core/src/FieldApi.ts +++ b/packages/form-core/src/FieldApi.ts @@ -8,7 +8,7 @@ export type ValidationCause = 'change' | 'blur' | 'submit' | 'mount' type ValidateFn< TData, TFormData, - ValidatorType extends Validator | undefined = undefined, + ValidatorType extends Validator | undefined = undefined, > = ValidatorType extends undefined ? (value: TData, fieldApi: FieldApi) => ValidationError : ReturnType>['validate'] extends ( @@ -35,8 +35,8 @@ export interface FieldOptions< * If TData is unknown, we can use the TName generic to determine the type */ TData = unknown extends _TData ? DeepValue : _TData, - ValidatorType extends Validator | undefined = - | Validator + ValidatorType extends Validator | undefined = + | Validator | undefined, > { name: TName diff --git a/packages/form-core/src/tests/FieldApi.test-d.ts b/packages/form-core/src/tests/FieldApi.test-d.ts index 352a44570..6907aae77 100644 --- a/packages/form-core/src/tests/FieldApi.test-d.ts +++ b/packages/form-core/src/tests/FieldApi.test-d.ts @@ -53,7 +53,7 @@ it('should allow a Zod validator to be passed in', () => { form, name: 'name', validator: zodValidator, - }) + } as const) }) it('should allow a Zod validator to handle the correct Zod type', () => { @@ -68,7 +68,7 @@ it('should allow a Zod validator to handle the correct Zod type', () => { name: 'name', validator: zodValidator, onChange: z.string(), - }) + } as const) }) it('should allow not a Zod validator with the wrong Zod type', () => { diff --git a/packages/form-core/src/zod-validator.ts b/packages/form-core/src/zod-validator.ts index 01f9ea3fb..fde70ba1f 100644 --- a/packages/form-core/src/zod-validator.ts +++ b/packages/form-core/src/zod-validator.ts @@ -1,28 +1,28 @@ import { ValidationError } from '@tanstack/form-core' import type { ZodError, ZodType, ZodTypeAny } from 'zod' -export type Validator = () => { +export type Validator = () => { // If/when TypeScript supports higher-kinded types, this should not be `unknown` anymore - validate(value: InferedType, fn: Fn): ValidationError - validateAsync(value: InferedType, fn: Fn): Promise + validate(value: Type, fn: Fn): ValidationError + validateAsync(value: Type, fn: Fn): Promise } -export const zodValidator = (>() => { +export const zodValidator = (>() => { return { - validate(value: T, fn: Fn): ValidationError { + validate(value: unknown, fn: Fn): ValidationError { // Call Zod on the value here and return the error message try { - fn.parse(value) + ;(fn as ZodTypeAny).parse(value) return } catch (_e) { const e = _e as ZodError return e.toString() } }, - async validateAsync(value: T, fn: Fn): Promise { + async validateAsync(value: unknown, fn: Fn): Promise { // Call Zod on the value here and return the error message try { - await fn.parseAsync(value) + await (fn as ZodTypeAny).parseAsync(value) return } catch (_e) { const e = _e as ZodError @@ -30,4 +30,4 @@ export const zodValidator = (>() => { } }, } -}) satisfies Validator +}) satisfies Validator From 564764361252326f7672c5ac9529642068a7d092 Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Sat, 9 Sep 2023 06:28:32 -0700 Subject: [PATCH 04/37] chore: infer validator --- packages/form-core/src/FieldApi.ts | 66 ++++++++++--------- .../form-core/src/tests/FieldApi.test-d.ts | 32 ++++++++- 2 files changed, 66 insertions(+), 32 deletions(-) diff --git a/packages/form-core/src/FieldApi.ts b/packages/form-core/src/FieldApi.ts index d79c99eb0..38ac992b4 100644 --- a/packages/form-core/src/FieldApi.ts +++ b/packages/form-core/src/FieldApi.ts @@ -2,30 +2,32 @@ import { type DeepKeys, type DeepValue, type Updater } from './utils' import type { FormApi, ValidationError, ValidationErrorMap } from './FormApi' import { Store } from '@tanstack/store' import { Validator } from './zod-validator' +import { NoInfer } from 'solid-js' export type ValidationCause = 'change' | 'blur' | 'submit' | 'mount' -type ValidateFn< - TData, - TFormData, - ValidatorType extends Validator | undefined = undefined, -> = ValidatorType extends undefined - ? (value: TData, fieldApi: FieldApi) => ValidationError - : ReturnType>['validate'] extends ( - value: infer _TData, - fn: infer ValidateFn, - ) => ValidationError - ? ValidateFn - : never - -type ValidateAsyncFn = ( +type ValidateFn = + ValidatorType extends Validator + ? ReturnType>['validate'] extends ( + value: infer _TData, + fn: infer ValidateFn, + ) => ValidationError + ? ValidateFn + : never + : ( + value: TData, + fieldApi: FieldApi, + ) => ValidationError + +type ValidateAsyncFn = ( value: TData, - fieldApi: FieldApi, + fieldApi: FieldApi, ) => ValidationError | Promise export interface FieldOptions< _TData, TFormData, + ValidatorType, /** * This allows us to restrict the name to only be a valid field name while * also assigning it to a generic @@ -35,30 +37,28 @@ export interface FieldOptions< * If TData is unknown, we can use the TName generic to determine the type */ TData = unknown extends _TData ? DeepValue : _TData, - ValidatorType extends Validator | undefined = - | Validator - | undefined, > { name: TName index?: TData extends any[] ? number : never defaultValue?: TData asyncDebounceMs?: number asyncAlways?: boolean - onMount?: (formApi: FieldApi) => void + validator?: ValidatorType + onMount?: (fieldApi: FieldApi) => void onChange?: ValidateFn - onChangeAsync?: ValidateAsyncFn + onChangeAsync?: ValidateAsyncFn onChangeAsyncDebounceMs?: number onBlur?: ValidateFn - onBlurAsync?: ValidateAsyncFn + onBlurAsync?: ValidateAsyncFn onBlurAsyncDebounceMs?: number - onSubmitAsync?: ValidateAsyncFn + onSubmitAsync?: ValidateAsyncFn defaultMeta?: Partial - validator?: ValidatorType } export interface FieldApiOptions< _TData, TFormData, + ValidatorType, /** * This allows us to restrict the name to only be a valid field name while * also assigning it to a generic @@ -68,7 +68,7 @@ export interface FieldApiOptions< * If TData is unknown, we can use the TName generic to determine the type */ TData = unknown extends _TData ? DeepValue : _TData, -> extends FieldOptions<_TData, TFormData, TName, TData> { +> extends FieldOptions<_TData, TFormData, ValidatorType, TName, TData> { form: FormApi } @@ -90,7 +90,8 @@ export type FieldState = { type GetTData< TData, TFormData, - Opts extends FieldApiOptions, + Validator, + Opts extends FieldApiOptions, > = Opts extends FieldApiOptions< infer _TData, infer _TFormData, @@ -103,13 +104,16 @@ type GetTData< export class FieldApi< _TData, TFormData, - Opts extends FieldApiOptions<_TData, TFormData> = FieldApiOptions< + Validator, + Opts extends FieldApiOptions<_TData, TFormData, Validator> = FieldApiOptions< _TData, - TFormData + TFormData, + Validator >, - TData extends GetTData<_TData, TFormData, Opts> = GetTData< + TData extends GetTData<_TData, TFormData, Validator, Opts> = GetTData< _TData, TFormData, + Validator, Opts >, > { @@ -122,7 +126,7 @@ export class FieldApi< prevState!: FieldState constructor( - opts: Opts & { + opts: FieldApiOptions<_TData, TFormData, Validator> & { form: FormApi }, ) { @@ -203,7 +207,7 @@ export class FieldApi< } } - update = (opts: FieldApiOptions) => { + update = (opts: FieldApiOptions) => { // Default Value // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition if (this.state.value === undefined) { @@ -268,7 +272,7 @@ export class FieldApi< this.form.swapFieldValues(this.name, aIndex, bIndex) getSubField = >(name: TName) => - new FieldApi, TFormData>({ + new FieldApi, TFormData, Validator>({ name: `${this.name}.${name}` as never, form: this.form, }) diff --git a/packages/form-core/src/tests/FieldApi.test-d.ts b/packages/form-core/src/tests/FieldApi.test-d.ts index 6907aae77..39a2d9330 100644 --- a/packages/form-core/src/tests/FieldApi.test-d.ts +++ b/packages/form-core/src/tests/FieldApi.test-d.ts @@ -71,7 +71,37 @@ it('should allow a Zod validator to handle the correct Zod type', () => { } as const) }) -it('should allow not a Zod validator with the wrong Zod type', () => { +it('should not allow a functional onChange to be passed when using a validator', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + }) + + const field = new FieldApi({ + form, + name: 'name', + validator: zodValidator, + onChange: (val) => null, + } as const) +}) + +it('should not allow a validator onChange to be passed when not using a validator', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + }) + + const field = new FieldApi({ + form, + name: 'name', + onChange: z.string(), + } as const) +}) + +// This is not possible without higher-kinded types AFAIK +it.skip('should allow not a Zod validator with the wrong Zod type', () => { const form = new FormApi({ defaultValues: { name: 'test', From 8b69f2a2291461838a41e882850a767933044c4f Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Sat, 9 Sep 2023 06:28:40 -0700 Subject: [PATCH 05/37] chore: infer zod --- packages/form-core/src/FieldApi.ts | 15 +++---------- .../form-core/src/tests/FieldApi.test-d.ts | 22 ++----------------- packages/form-core/src/zod-validator.ts | 8 +++---- 3 files changed, 9 insertions(+), 36 deletions(-) diff --git a/packages/form-core/src/FieldApi.ts b/packages/form-core/src/FieldApi.ts index 38ac992b4..f6bedbbc0 100644 --- a/packages/form-core/src/FieldApi.ts +++ b/packages/form-core/src/FieldApi.ts @@ -7,13 +7,8 @@ import { NoInfer } from 'solid-js' export type ValidationCause = 'change' | 'blur' | 'submit' | 'mount' type ValidateFn = - ValidatorType extends Validator - ? ReturnType>['validate'] extends ( - value: infer _TData, - fn: infer ValidateFn, - ) => ValidationError - ? ValidateFn - : never + ValidatorType extends Validator + ? Parameters['validate']>[1] : ( value: TData, fieldApi: FieldApi, @@ -125,11 +120,7 @@ export class FieldApi< state!: FieldState prevState!: FieldState - constructor( - opts: FieldApiOptions<_TData, TFormData, Validator> & { - form: FormApi - }, - ) { + constructor(opts: FieldApiOptions<_TData, TFormData, Validator>) { this.form = opts.form this.uid = uid++ // Support field prefixing from FieldScope diff --git a/packages/form-core/src/tests/FieldApi.test-d.ts b/packages/form-core/src/tests/FieldApi.test-d.ts index 39a2d9330..a8c8e6e16 100644 --- a/packages/form-core/src/tests/FieldApi.test-d.ts +++ b/packages/form-core/src/tests/FieldApi.test-d.ts @@ -4,26 +4,6 @@ import { FieldApi } from '../FieldApi' import { zodValidator } from '../zod-validator' import z from 'zod' -it('should type a subfield properly', () => { - const form = new FormApi({ - defaultValues: { - names: { - first: 'one', - second: 'two', - }, - } as const, - }) - - const field = new FieldApi({ - form, - name: 'names', - }) - - const subfield = field.getSubField('first') - - assertType<'one'>(subfield.getValue()) -}) - it('should type onChange properly', () => { const form = new FormApi({ defaultValues: { @@ -82,6 +62,7 @@ it('should not allow a functional onChange to be passed when using a validator', form, name: 'name', validator: zodValidator, + // @ts-expect-error Is not of type validator onChange: (val) => null, } as const) }) @@ -96,6 +77,7 @@ it('should not allow a validator onChange to be passed when not using a validato const field = new FieldApi({ form, name: 'name', + // @ts-expect-error Requires a validator onChange: z.string(), } as const) }) diff --git a/packages/form-core/src/zod-validator.ts b/packages/form-core/src/zod-validator.ts index fde70ba1f..b3e73f46c 100644 --- a/packages/form-core/src/zod-validator.ts +++ b/packages/form-core/src/zod-validator.ts @@ -1,13 +1,13 @@ import { ValidationError } from '@tanstack/form-core' import type { ZodError, ZodType, ZodTypeAny } from 'zod' -export type Validator = () => { +export type Validator = () => { // If/when TypeScript supports higher-kinded types, this should not be `unknown` anymore validate(value: Type, fn: Fn): ValidationError validateAsync(value: Type, fn: Fn): Promise } -export const zodValidator = (>() => { +export const zodValidator = ( = ZodType>() => { return { validate(value: unknown, fn: Fn): ValidationError { // Call Zod on the value here and return the error message @@ -15,7 +15,7 @@ export const zodValidator = (>() => { ;(fn as ZodTypeAny).parse(value) return } catch (_e) { - const e = _e as ZodError + const e = _e as ZodError return e.toString() } }, @@ -25,7 +25,7 @@ export const zodValidator = (>() => { await (fn as ZodTypeAny).parseAsync(value) return } catch (_e) { - const e = _e as ZodError + const e = _e as ZodError return e.toString() } }, From a352f290227959c3af017facf7bb17ad86498afd Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Sat, 9 Sep 2023 07:03:56 -0700 Subject: [PATCH 06/37] feat: add validation transformer logic --- packages/form-core/src/FieldApi.ts | 137 ++++++++++++++---------- packages/form-core/src/FormApi.ts | 2 +- packages/form-core/src/zod-validator.ts | 61 ++++++----- 3 files changed, 117 insertions(+), 83 deletions(-) diff --git a/packages/form-core/src/FieldApi.ts b/packages/form-core/src/FieldApi.ts index f6bedbbc0..1ed2a5e03 100644 --- a/packages/form-core/src/FieldApi.ts +++ b/packages/form-core/src/FieldApi.ts @@ -1,18 +1,19 @@ import { type DeepKeys, type DeepValue, type Updater } from './utils' import type { FormApi, ValidationError, ValidationErrorMap } from './FormApi' import { Store } from '@tanstack/store' -import { Validator } from './zod-validator' -import { NoInfer } from 'solid-js' +import type { Validator } from './zod-validator' export type ValidationCause = 'change' | 'blur' | 'submit' | 'mount' -type ValidateFn = +type ValidateFn = ( + value: TData, + fieldApi: FieldApi, +) => ValidationError + +type ValidateOrFn = ValidatorType extends Validator ? Parameters['validate']>[1] - : ( - value: TData, - fieldApi: FieldApi, - ) => ValidationError + : ValidateFn type ValidateAsyncFn = ( value: TData, @@ -40,10 +41,10 @@ export interface FieldOptions< asyncAlways?: boolean validator?: ValidatorType onMount?: (fieldApi: FieldApi) => void - onChange?: ValidateFn + onChange?: ValidateOrFn onChangeAsync?: ValidateAsyncFn onChangeAsyncDebounceMs?: number - onBlur?: ValidateFn + onBlur?: ValidateOrFn onBlurAsync?: ValidateAsyncFn onBlurAsyncDebounceMs?: number onSubmitAsync?: ValidateAsyncFn @@ -82,46 +83,36 @@ export type FieldState = { meta: FieldMeta } -type GetTData< - TData, - TFormData, - Validator, - Opts extends FieldApiOptions, -> = Opts extends FieldApiOptions< +type GetTData = Opts extends FieldApiOptions< infer _TData, infer _TFormData, + infer _Validator, infer _TName, infer RealTData > ? RealTData : never -export class FieldApi< - _TData, - TFormData, - Validator, - Opts extends FieldApiOptions<_TData, TFormData, Validator> = FieldApiOptions< - _TData, - TFormData, - Validator - >, - TData extends GetTData<_TData, TFormData, Validator, Opts> = GetTData< - _TData, - TFormData, - Validator, - Opts - >, -> { +export class FieldApi { + /** + * This is a hack that allows us to use `GetTData` without calling it everywhere + * + * Unfortunately this hack appears to be needed alongside the `TName` hack + * further up in this file. This properly types all of the internal methods, + * while the `TName` hack types the options properly + */ + _tdata!: GetTData uid: number - form: Opts['form'] + form: (typeof this.options)['form'] name!: DeepKeys - options: Opts = {} as any - store!: Store> - state!: FieldState - prevState!: FieldState - - constructor(opts: FieldApiOptions<_TData, TFormData, Validator>) { - this.form = opts.form + store!: Store> + state!: FieldState + prevState!: FieldState + + constructor( + public options: FieldApiOptions, + ) { + this.form = options.form this.uid = uid++ // Support field prefixing from FieldScope // let fieldPrefix = '' @@ -129,9 +120,9 @@ export class FieldApi< // fieldPrefix = `${this.form.fieldName}.` // } - this.name = opts.name as any + this.name = options.name as never - this.store = new Store>( + this.store = new Store>( { value: this.getValue(), // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition @@ -141,7 +132,7 @@ export class FieldApi< touchedErrors: [], errors: [], errorMap: {}, - ...opts.defaultMeta, + ...options.defaultMeta, }, }, { @@ -164,7 +155,6 @@ export class FieldApi< this.state = this.store.state this.prevState = this.state - this.options = opts as never } mount = () => { @@ -193,12 +183,14 @@ export class FieldApi< unsubscribe() delete info.instances[this.uid] if (!Object.keys(info.instances).length) { - delete this.form.fieldInfo[this.name] + delete this.form.fieldInfo[this.name as never] } } } - update = (opts: FieldApiOptions) => { + update = ( + opts: FieldApiOptions, + ) => { // Default Value // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition if (this.state.value === undefined) { @@ -220,12 +212,12 @@ export class FieldApi< this.options = opts as never } - getValue = (): TData => { + getValue = (): typeof this._tdata => { return this.form.getFieldValue(this.name) } setValue = ( - updater: Updater, + updater: Updater, options?: { touch?: boolean; notify?: boolean }, ) => { this.form.setFieldValue(this.name, updater as never, options) @@ -249,12 +241,17 @@ export class FieldApi< getInfo = () => this.form.getFieldInfo(this.name) - pushValue = (value: TData extends any[] ? TData[number] : never) => - this.form.pushFieldValue(this.name, value as any) + pushValue = ( + value: typeof this._tdata extends any[] + ? (typeof this._tdata)[number] + : never, + ) => this.form.pushFieldValue(this.name, value as any) insertValue = ( index: number, - value: TData extends any[] ? TData[number] : never, + value: typeof this._tdata extends any[] + ? (typeof this._tdata)[number] + : never, ) => this.form.insertFieldValue(this.name, index, value as any) removeValue = (index: number) => this.form.removeFieldValue(this.name, index) @@ -262,23 +259,53 @@ export class FieldApi< swapValues = (aIndex: number, bIndex: number) => this.form.swapFieldValues(this.name, aIndex, bIndex) - getSubField = >(name: TName) => - new FieldApi, TFormData, Validator>({ + getSubField = >(name: TName) => + new FieldApi< + DeepValue, + TFormData, + ValidatorType + >({ name: `${this.name}.${name}` as never, form: this.form, }) + getValidateTransformer = () => { + const isValidator = ( + item: unknown, + ): item is Validator< + typeof this._tdata, + typeof this.options.onBlur | typeof this.options.onChange + > => + !!item && typeof item === 'function' && (item as any).isValidator === true + + return isValidator(this.options.validator) ? this.options.validator() : null + } + validateSync = (value = this.state.value, cause: ValidationCause) => { const { onChange, onBlur } = this.options const validate = cause === 'submit' ? undefined : cause === 'change' ? onChange : onBlur + + const validateTransformer = this.getValidateTransformer() + if (!validate) return // Use the validationCount for all field instances to // track freshness of the validation const validationCount = (this.getInfo().validationCount || 0) + 1 this.getInfo().validationCount = validationCount - const error = normalizeError(validate(value as never, this as never)) + + const doValidate = () => { + if (validateTransformer) { + return validateTransformer.validate(value, validate) + } + + return ( + validate as ValidateFn + )(value, this as never) + } + + const error = normalizeError(doValidate()) const errorMapKey = getErrorMapKey(cause) if (this.state.meta.errorMap[errorMapKey] !== error) { this.setMeta((prev) => ({ @@ -395,7 +422,7 @@ export class FieldApi< validate = ( cause: ValidationCause, - value?: TData, + value?: typeof this._tdata, ): ValidationError[] | Promise => { // If the field is pristine and validatePristine is false, do not validate if (!this.state.meta.isTouched) return [] @@ -413,7 +440,7 @@ export class FieldApi< return this.validateAsync(value, cause) } - handleChange = (updater: Updater) => { + handleChange = (updater: Updater) => { this.setValue(updater, { touch: true }) } diff --git a/packages/form-core/src/FormApi.ts b/packages/form-core/src/FormApi.ts index 4e48d57bf..f1ff8f9f6 100644 --- a/packages/form-core/src/FormApi.ts +++ b/packages/form-core/src/FormApi.ts @@ -31,7 +31,7 @@ export type FormOptions = { } export type FieldInfo = { - instances: Record> + instances: Record> } & ValidationMeta export type ValidationMeta = { diff --git a/packages/form-core/src/zod-validator.ts b/packages/form-core/src/zod-validator.ts index b3e73f46c..13edc7316 100644 --- a/packages/form-core/src/zod-validator.ts +++ b/packages/form-core/src/zod-validator.ts @@ -1,33 +1,40 @@ -import { ValidationError } from '@tanstack/form-core' import type { ZodError, ZodType, ZodTypeAny } from 'zod' +import type { ValidationError } from './FormApi' -export type Validator = () => { +export type Validator = { // If/when TypeScript supports higher-kinded types, this should not be `unknown` anymore - validate(value: Type, fn: Fn): ValidationError - validateAsync(value: Type, fn: Fn): Promise + (): { + validate(value: Type, fn: Fn): ValidationError + validateAsync(value: Type, fn: Fn): Promise + } + isValidator: boolean } -export const zodValidator = ( = ZodType>() => { - return { - validate(value: unknown, fn: Fn): ValidationError { - // Call Zod on the value here and return the error message - try { - ;(fn as ZodTypeAny).parse(value) - return - } catch (_e) { - const e = _e as ZodError - return e.toString() - } - }, - async validateAsync(value: unknown, fn: Fn): Promise { - // Call Zod on the value here and return the error message - try { - await (fn as ZodTypeAny).parseAsync(value) - return - } catch (_e) { - const e = _e as ZodError - return e.toString() - } - }, +export const zodValidator = (() => { + const fn = = ZodType>() => { + return { + validate(value: unknown, fn: Fn): ValidationError { + // Call Zod on the value here and return the error message + try { + ;(fn as ZodTypeAny).parse(value) + return + } catch (_e) { + const e = _e as ZodError + return e.toString() + } + }, + async validateAsync(value: unknown, fn: Fn): Promise { + // Call Zod on the value here and return the error message + try { + await (fn as ZodTypeAny).parseAsync(value) + return + } catch (_e) { + const e = _e as ZodError + return e.toString() + } + }, + } } -}) satisfies Validator + fn.isValidator = true + return fn +})() satisfies Validator From 0b6339f966029b9efba721f8187ef9b5c78197a8 Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Sat, 9 Sep 2023 07:35:08 -0700 Subject: [PATCH 07/37] chore: fix typings for react adapter --- packages/react-form/src/types.ts | 3 +- packages/react-form/src/useField.tsx | 57 ++++++++++++++++------------ 2 files changed, 35 insertions(+), 25 deletions(-) diff --git a/packages/react-form/src/types.ts b/packages/react-form/src/types.ts index c8eb121d6..fc3f96205 100644 --- a/packages/react-form/src/types.ts +++ b/packages/react-form/src/types.ts @@ -3,7 +3,8 @@ import type { FieldOptions, DeepKeys } from '@tanstack/form-core' export type UseFieldOptions< TData, TFormData, + ValidatorType, TName = unknown extends TFormData ? string : DeepKeys, -> = FieldOptions & { +> = FieldOptions & { mode?: 'value' | 'array' } diff --git a/packages/react-form/src/useField.tsx b/packages/react-form/src/useField.tsx index 5e28e18c2..6032a9cf6 100644 --- a/packages/react-form/src/useField.tsx +++ b/packages/react-form/src/useField.tsx @@ -6,42 +6,39 @@ import type { FieldApiOptions, Narrow, } from '@tanstack/form-core' -import { FieldApi, type FormApi, functionalUpdate } from '@tanstack/form-core' +import { FieldApi, functionalUpdate } from '@tanstack/form-core' import { useFormContext, formContext } from './formContext' import useIsomorphicLayoutEffect from 'use-isomorphic-layout-effect' import type { UseFieldOptions } from './types' declare module '@tanstack/form-core' { // eslint-disable-next-line no-shadow - interface FieldApi<_TData, TFormData, Opts, TData> { + interface FieldApi { Field: FieldComponent } } -export type UseField = >( +export type UseField = < + TField extends DeepKeys, + ValidatorType, +>( opts?: { name: Narrow } & UseFieldOptions< DeepValue, - TFormData + TFormData, + ValidatorType >, -) => FieldApi, TFormData> +) => FieldApi, TFormData, ValidatorType> export function useField< TData, TFormData, + ValidatorType, TName extends unknown extends TFormData ? string : DeepKeys = unknown extends TFormData ? string : DeepKeys, ->( - opts: UseFieldOptions, -): FieldApi< - TData, - TFormData, - Omit & { - form: FormApi - } -> { +>(opts: UseFieldOptions) { // Get the form API either manually or from context const { formApi, parentFieldName } = useFormContext() @@ -57,8 +54,8 @@ export function useField< const api = new FieldApi({ ...opts, form: formApi, - name: name, - } as never) + name: name as TName, + }) api.Field = Field as never @@ -76,7 +73,7 @@ export function useField< useStore( fieldApi.store, opts.mode === 'array' - ? (state: any) => { + ? (state) => { return [state.meta, Object.keys(state.value || []).length] } : undefined, @@ -84,20 +81,22 @@ export function useField< // Instantiates field meta and removes it when unrendered useIsomorphicLayoutEffect(() => fieldApi.mount(), [fieldApi]) - return fieldApi as never + return fieldApi } type FieldComponentProps< TParentData, TFormData, TField, + ValidatorType, TName extends unknown extends TFormData ? string : DeepKeys, > = { + validator?: ValidatorType children: ( fieldApi: FieldApi< TField, TFormData, - FieldApiOptions + FieldApiOptions >, ) => any } & (TParentData extends any[] @@ -109,24 +108,34 @@ type FieldComponentProps< name: TName index?: never }) & - Omit, 'name' | 'index'> + Omit< + UseFieldOptions, + 'name' | 'index' | 'validator' + > export type FieldComponent = < // Type of the field TField, // Name of the field TName extends unknown extends TFormData ? string : DeepKeys, + ValidatorType, >({ children, ...fieldOptions -}: FieldComponentProps) => any +}: FieldComponentProps< + TParentData, + TFormData, + TField, + ValidatorType, + TName +>) => any -export function Field({ +export function Field({ children, ...fieldOptions }: { - children: (fieldApi: FieldApi) => any -} & UseFieldOptions) { + children: (fieldApi: FieldApi) => any +} & UseFieldOptions) { const fieldApi = useField(fieldOptions as any) return ( From f6c6ce72685db8eb06b0d3264f55038f22ac610f Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Sun, 10 Sep 2023 07:44:06 -0700 Subject: [PATCH 08/37] chore: fix issue with `this` not being defined properly --- package.json | 5 +- packages/form-core/src/FieldApi.ts | 6 +- patches/tsup@7.2.0.patch | 14 + pnpm-lock.yaml | 2617 +++++++++++++--------------- 4 files changed, 1220 insertions(+), 1422 deletions(-) create mode 100644 patches/tsup@7.2.0.patch diff --git a/package.json b/package.json index 51566c98f..64f31a7be 100644 --- a/package.json +++ b/package.json @@ -93,7 +93,7 @@ "solid-js": "^1.6.13", "stream-to-array": "^2.3.0", "ts-node": "^10.9.1", - "tsup": "^7.2.0", + "tsup": "7.2.0", "type-fest": "^3.11.0", "typescript": "^5.2.2", "vitest": "^0.34.3", @@ -108,7 +108,8 @@ }, "pnpm": { "patchedDependencies": { - "@types/testing-library__jest-dom@5.14.5": "patches/@types__testing-library__jest-dom@5.14.5.patch" + "@types/testing-library__jest-dom@5.14.5": "patches/@types__testing-library__jest-dom@5.14.5.patch", + "tsup@7.2.0": "patches/tsup@7.2.0.patch" }, "overrides": { "@tanstack/form-core": "workspace:*", diff --git a/packages/form-core/src/FieldApi.ts b/packages/form-core/src/FieldApi.ts index 1ed2a5e03..8ae26e101 100644 --- a/packages/form-core/src/FieldApi.ts +++ b/packages/form-core/src/FieldApi.ts @@ -323,7 +323,7 @@ export class FieldApi { } } - #leaseValidateAsync = () => { + __leaseValidateAsync = () => { const count = (this.getInfo().validationAsyncCount || 0) + 1 this.getInfo().validationAsyncCount = count return count @@ -331,7 +331,7 @@ export class FieldApi { cancelValidateAsync = () => { // Lease a new validation count to ignore any pending validations - this.#leaseValidateAsync() + this.__leaseValidateAsync() // Cancel any pending validation state this.setMeta((prev) => ({ ...prev, @@ -370,7 +370,7 @@ export class FieldApi { // Use the validationCount for all field instances to // track freshness of the validation - const validationAsyncCount = this.#leaseValidateAsync() + const validationAsyncCount = this.__leaseValidateAsync() const checkLatest = () => validationAsyncCount === this.getInfo().validationAsyncCount diff --git a/patches/tsup@7.2.0.patch b/patches/tsup@7.2.0.patch new file mode 100644 index 000000000..f9663b086 --- /dev/null +++ b/patches/tsup@7.2.0.patch @@ -0,0 +1,14 @@ +diff --git a/dist/rollup.js b/dist/rollup.js +index 0f6400eedfad49091ca952ee5863bd027e3b8417..f08abd327e031cd8d18729e955b5f3b45f6f3f92 100644 +--- a/dist/rollup.js ++++ b/dist/rollup.js +@@ -6805,6 +6805,9 @@ export { ${[...exportedNames].join(", ")} }; + } + } + } ++ // https://github.com/Swatinem/rollup-plugin-dts/pull/287 ++ // `this` is a reserved keyword that retrains meaning in certain Type-only contexts, including classes ++ if (name === "this") return; + const { ident, expr } = createReference(id); + this.declaration.params.push(expr); + this.returnExpr.elements.push(ident); diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index deadb3fc3..0154d2048 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -13,6 +13,9 @@ patchedDependencies: '@types/testing-library__jest-dom@5.14.5': hash: d573maxasnl5kxwdyzebcnmhpm path: patches/@types__testing-library__jest-dom@5.14.5.patch + tsup@7.2.0: + hash: gwbgl3s5ycyzg75lofcbklamcy + path: patches/tsup@7.2.0.patch importers: @@ -20,40 +23,40 @@ importers: devDependencies: '@babel/core': specifier: ^7.21.8 - version: 7.22.10 + version: 7.22.17 '@babel/preset-env': specifier: ^7.21.5 - version: 7.21.5(@babel/core@7.22.10) + version: 7.22.15(@babel/core@7.22.17) '@babel/preset-react': specifier: ^7.18.6 - version: 7.18.6(@babel/core@7.22.10) + version: 7.22.15(@babel/core@7.22.17) '@babel/preset-typescript': specifier: ^7.21.5 - version: 7.21.5(@babel/core@7.22.10) + version: 7.22.15(@babel/core@7.22.17) '@commitlint/parse': specifier: ^17.6.5 - version: 17.6.5 + version: 17.7.0 '@rollup/plugin-babel': specifier: ^6.0.3 - version: 6.0.3(@babel/core@7.22.10) + version: 6.0.3(@babel/core@7.22.17) '@rollup/plugin-commonjs': specifier: ^25.0.0 - version: 25.0.0 + version: 25.0.4 '@rollup/plugin-node-resolve': specifier: ^15.0.2 - version: 15.0.2 + version: 15.2.1 '@rollup/plugin-replace': specifier: ^5.0.2 version: 5.0.2 '@testing-library/jest-dom': specifier: ^5.16.5 - version: 5.16.5 + version: 5.17.0 '@testing-library/react': specifier: ^14.0.0 version: 14.0.0(react-dom@18.2.0)(react@18.2.0) '@testing-library/react-hooks': specifier: ^8.0.1 - version: 8.0.1(@types/react@18.0.15)(react-dom@18.2.0)(react@18.2.0) + version: 8.0.1(@types/react@18.2.21)(react-dom@18.2.0)(react@18.2.0) '@testing-library/user-event': specifier: ^14.4.3 version: 14.4.3(@testing-library/dom@9.3.1) @@ -71,19 +74,19 @@ importers: version: 6.1.1 '@types/luxon': specifier: ^2.3.1 - version: 2.3.2 + version: 2.4.0 '@types/node': specifier: ^17.0.25 version: 17.0.45 '@types/react': specifier: ^18.0.14 - version: 18.0.15 + version: 18.2.21 '@types/react-dom': specifier: ^18.0.5 - version: 18.0.6 + version: 18.2.7 '@types/semver': specifier: ^7.3.13 - version: 7.3.13 + version: 7.5.1 '@types/stream-to-array': specifier: ^2.3.1 version: 2.3.1 @@ -92,25 +95,25 @@ importers: version: 5.14.5(patch_hash=d573maxasnl5kxwdyzebcnmhpm) '@typescript-eslint/eslint-plugin': specifier: ^6.4.1 - version: 6.4.1(@typescript-eslint/parser@6.4.1)(eslint@8.48.0)(typescript@5.2.2) + version: 6.6.0(@typescript-eslint/parser@6.6.0)(eslint@8.49.0)(typescript@5.2.2) '@typescript-eslint/parser': specifier: ^6.4.1 - version: 6.4.1(eslint@8.48.0)(typescript@5.2.2) + version: 6.6.0(eslint@8.49.0)(typescript@5.2.2) '@vitest/coverage-istanbul': specifier: ^0.34.3 - version: 0.34.3(vitest@0.34.3) + version: 0.34.4(vitest@0.34.4) axios: specifier: ^0.26.1 version: 0.26.1 babel-eslint: specifier: ^10.1.0 - version: 10.1.0(eslint@8.48.0) + version: 10.1.0(eslint@8.49.0) babel-jest: specifier: ^27.5.1 - version: 27.5.1(@babel/core@7.22.10) + version: 27.5.1(@babel/core@7.22.17) babel-preset-solid: specifier: ^1.5.4 - version: 1.5.4(@babel/core@7.22.10) + version: 1.7.7(@babel/core@7.22.17) bundlewatch: specifier: ^0.3.2 version: 0.3.3 @@ -134,25 +137,25 @@ importers: version: 1.0.0 eslint: specifier: ^8.48.0 - version: 8.48.0 + version: 8.49.0 eslint-config-prettier: specifier: ^9.0.0 - version: 9.0.0(eslint@8.48.0) + version: 9.0.0(eslint@8.49.0) eslint-import-resolver-typescript: specifier: ^3.6.0 - version: 3.6.0(@typescript-eslint/parser@6.4.1)(eslint-plugin-import@2.28.1)(eslint@8.48.0) + version: 3.6.0(@typescript-eslint/parser@6.6.0)(eslint-plugin-import@2.28.1)(eslint@8.49.0) eslint-plugin-compat: specifier: ^4.1.4 - version: 4.1.4(eslint@8.48.0) + version: 4.2.0(eslint@8.49.0) eslint-plugin-import: specifier: ^2.28.1 - version: 2.28.1(@typescript-eslint/parser@6.4.1)(eslint-import-resolver-typescript@3.6.0)(eslint@8.48.0) + version: 2.28.1(@typescript-eslint/parser@6.6.0)(eslint-import-resolver-typescript@3.6.0)(eslint@8.49.0) eslint-plugin-react: specifier: ^7.33.2 - version: 7.33.2(eslint@8.48.0) + version: 7.33.2(eslint@8.49.0) eslint-plugin-react-hooks: specifier: ^4.6.0 - version: 4.6.0(eslint@8.48.0) + version: 4.6.0(eslint@8.49.0) fs-extra: specifier: ^11.1.1 version: 11.1.1 @@ -161,25 +164,25 @@ importers: version: 1.2.0 jsdom: specifier: ^22.0.0 - version: 22.0.0 + version: 22.1.0 jsonfile: specifier: ^6.1.0 version: 6.1.0 luxon: specifier: ^3.3.0 - version: 3.3.0 + version: 3.4.3 nx: specifier: ^16.7.4 - version: 16.7.4 + version: 16.8.1 nx-cloud: specifier: ^16.0.5 - version: 16.3.0 + version: 16.4.0 prettier: specifier: ^3.0.2 - version: 3.0.2 + version: 3.0.3 publint: specifier: ^0.1.15 - version: 0.1.15 + version: 0.1.16 react: specifier: ^18.2.0 version: 18.2.0 @@ -197,10 +200,10 @@ importers: version: 5.0.1 semver: specifier: ^7.3.8 - version: 7.3.8 + version: 7.5.4 solid-js: specifier: ^1.6.13 - version: 1.6.13 + version: 1.7.11 stream-to-array: specifier: ^2.3.0 version: 2.3.0 @@ -208,17 +211,17 @@ importers: specifier: ^10.9.1 version: 10.9.1(@types/node@17.0.45)(typescript@5.2.2) tsup: - specifier: ^7.2.0 - version: 7.2.0(ts-node@10.9.1)(typescript@5.2.2) + specifier: 7.2.0 + version: 7.2.0(patch_hash=gwbgl3s5ycyzg75lofcbklamcy)(ts-node@10.9.1)(typescript@5.2.2) type-fest: specifier: ^3.11.0 - version: 3.11.0 + version: 3.13.1 typescript: specifier: ^5.2.2 version: 5.2.2 vitest: specifier: ^0.34.3 - version: 0.34.3(jsdom@22.0.0) + version: 0.34.4(jsdom@22.1.0) vue: specifier: ^3.3.4 version: 3.3.4 @@ -245,7 +248,7 @@ importers: version: 18.2.0(react@18.2.0) zod: specifier: ^3.21.4 - version: 3.21.4 + version: 3.22.2 devDependencies: '@vitejs/plugin-react': specifier: ^4.0.4 @@ -290,7 +293,7 @@ importers: devDependencies: zod: specifier: ^3.21.4 - version: 3.21.4 + version: 3.22.2 packages/react-form: dependencies: @@ -305,20 +308,20 @@ importers: version: 0.1.3 react-native: specifier: '*' - version: 0.72.4(@babel/core@7.22.10)(@babel/preset-env@7.21.5)(react@18.2.0) + version: 0.72.4(@babel/core@7.22.17)(@babel/preset-env@7.22.15)(react@18.2.0) use-isomorphic-layout-effect: specifier: ^1.1.2 - version: 1.1.2(@types/react@18.0.15)(react@18.2.0) + version: 1.1.2(@types/react@18.2.21)(react@18.2.0) devDependencies: '@types/jscodeshift': specifier: ^0.11.3 - version: 0.11.5 + version: 0.11.6 '@types/react': specifier: ^18.0.14 - version: 18.0.15 + version: 18.2.21 '@types/react-dom': specifier: ^18.0.5 - version: 18.0.6 + version: 18.2.7 '@types/use-sync-external-store': specifier: ^0.0.3 version: 0.0.3 @@ -367,8 +370,8 @@ packages: engines: {node: '>=0.10.0'} dev: true - /@adobe/css-tools@4.3.0: - resolution: {integrity: sha512-+RNNcQvw2V1bmnBTPAtOLfW/9mhH2vC67+rUSi5T8EtEWt6lEnGNY2GuhZ1/YwbgikT1TkhvidCDmN5Q5YCo/w==} + /@adobe/css-tools@4.3.1: + resolution: {integrity: sha512-/62yikz7NLScCGAAST5SHdnjaDJQBDq0M2muyRTpf2VQhw6StBg2ALiu73zSJQ4fMVLA+0uBhBHAle7Wg+2kSg==} dev: true /@ampproject/remapping@2.2.1: @@ -378,20 +381,6 @@ packages: '@jridgewell/gen-mapping': 0.3.3 '@jridgewell/trace-mapping': 0.3.19 - /@babel/code-frame@7.18.6: - resolution: {integrity: sha512-TDCmlK5eOvH+eH7cdAFlNXeVJqWIQ7gW9tY1GJIpUtFb6CmjVyq2VM3u71bOyR8CRihcCgMUYoDNyLXao3+70Q==} - engines: {node: '>=6.9.0'} - dependencies: - '@babel/highlight': 7.22.13 - dev: true - - /@babel/code-frame@7.22.10: - resolution: {integrity: sha512-/KKIMG4UEL35WmI9OlvMhurwtytjvXoFcGNrOvyG9zIzA8YmPjVtIZUf7b05+TPO7G7/GEmLHDaoCgACHl9hhA==} - engines: {node: '>=6.9.0'} - dependencies: - '@babel/highlight': 7.22.13 - chalk: 2.4.2 - /@babel/code-frame@7.22.13: resolution: {integrity: sha512-XktuhWlJ5g+3TJXc5upd9Ks1HutSArik6jf2eAjYFyIOf4ej3RN+184cZbzDvbPnuTJIUhPKKJE3cIsYTiAT3w==} engines: {node: '>=6.9.0'} @@ -403,20 +392,20 @@ packages: resolution: {integrity: sha512-5UamI7xkUcJ3i9qVDS+KFDEK8/7oJ55/sJMB1Ge7IEapr7KfdfV/HErR+koZwOfd+SgtFKOKRhRakdg++DcJpQ==} engines: {node: '>=6.9.0'} - /@babel/core@7.22.10: - resolution: {integrity: sha512-fTmqbbUBAwCcre6zPzNngvsI0aNrPZe77AeqvDxWM9Nm+04RrJ3CAmGHA9f7lJQY6ZMhRztNemy4uslDxTX4Qw==} + /@babel/core@7.22.17: + resolution: {integrity: sha512-2EENLmhpwplDux5PSsZnSbnSkB3tZ6QTksgO25xwEL7pIDcNOMhF5v/s6RzwjMZzZzw9Ofc30gHv5ChCC8pifQ==} engines: {node: '>=6.9.0'} dependencies: '@ampproject/remapping': 2.2.1 - '@babel/code-frame': 7.22.10 - '@babel/generator': 7.22.10 - '@babel/helper-compilation-targets': 7.22.10 - '@babel/helper-module-transforms': 7.22.9(@babel/core@7.22.10) - '@babel/helpers': 7.22.10 - '@babel/parser': 7.22.13 - '@babel/template': 7.22.5 - '@babel/traverse': 7.22.10 - '@babel/types': 7.22.11 + '@babel/code-frame': 7.22.13 + '@babel/generator': 7.22.15 + '@babel/helper-compilation-targets': 7.22.15 + '@babel/helper-module-transforms': 7.22.17(@babel/core@7.22.17) + '@babel/helpers': 7.22.15 + '@babel/parser': 7.22.16 + '@babel/template': 7.22.15 + '@babel/traverse': 7.22.17 + '@babel/types': 7.22.17 convert-source-map: 1.9.0 debug: 4.3.4 gensync: 1.0.0-beta.2 @@ -425,11 +414,11 @@ packages: transitivePeerDependencies: - supports-color - /@babel/generator@7.22.10: - resolution: {integrity: sha512-79KIf7YiWjjdZ81JnLujDRApWtl7BxTqWD88+FFdQEIOG8LJ0etDOM7CXuIgGJa55sGOwZVwuEsaLEm0PJ5/+A==} + /@babel/generator@7.22.15: + resolution: {integrity: sha512-Zu9oWARBqeVOW0dZOjXc3JObrzuqothQ3y/n1kUtrjCoCPLkXUwMvOo/F/TCfoHMbWIFlWwpZtkZVb9ga4U2pA==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.11 + '@babel/types': 7.22.17 '@jridgewell/gen-mapping': 0.3.3 '@jridgewell/trace-mapping': 0.3.19 jsesc: 2.5.2 @@ -438,81 +427,65 @@ packages: resolution: {integrity: sha512-LvBTxu8bQSQkcyKOU+a1btnNFQ1dMAd0R6PyW3arXes06F6QLWLIrd681bxRPIXlrMGR3XYnW9JyML7dP3qgxg==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.15 + '@babel/types': 7.22.17 - /@babel/helper-builder-binary-assignment-operator-visitor@7.22.10: - resolution: {integrity: sha512-Av0qubwDQxC56DoUReVDeLfMEjYYSN1nZrTUrWkXd7hpU73ymRANkbuDm3yni9npkn+RXy9nNbEJZEzXr7xrfQ==} + /@babel/helper-builder-binary-assignment-operator-visitor@7.22.15: + resolution: {integrity: sha512-QkBXwGgaoC2GtGZRoma6kv7Szfv06khvhFav67ZExau2RaXzy8MpHSMO2PNoP2XtmQphJQRHFfg77Bq731Yizw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.15 + '@babel/types': 7.22.17 - /@babel/helper-compilation-targets@7.22.10: - resolution: {integrity: sha512-JMSwHD4J7SLod0idLq5PKgI+6g/hLD/iuWBq08ZX49xE14VpVEojJ5rHWptpirV2j020MvypRLAXAO50igCJ5Q==} + /@babel/helper-compilation-targets@7.22.15: + resolution: {integrity: sha512-y6EEzULok0Qvz8yyLkCvVX+02ic+By2UdOhylwUOvOn9dvYc9mKICJuuU1n1XBI02YWsNsnrY1kc6DVbjcXbtw==} engines: {node: '>=6.9.0'} dependencies: '@babel/compat-data': 7.22.9 - '@babel/helper-validator-option': 7.22.5 + '@babel/helper-validator-option': 7.22.15 browserslist: 4.21.10 lru-cache: 5.1.1 semver: 6.3.1 - /@babel/helper-create-class-features-plugin@7.22.10(@babel/core@7.22.10): - resolution: {integrity: sha512-5IBb77txKYQPpOEdUdIhBx8VrZyDCQ+H82H0+5dX1TmuscP5vJKEE3cKurjtIw/vFwzbVH48VweE78kVDBrqjA==} + /@babel/helper-create-class-features-plugin@7.22.15(@babel/core@7.22.17): + resolution: {integrity: sha512-jKkwA59IXcvSaiK2UN45kKwSC9o+KuoXsBDvHvU/7BecYIp8GQ2UwrVvFgJASUT+hBnwJx6MhvMCuMzwZZ7jlg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-annotate-as-pure': 7.22.5 '@babel/helper-environment-visitor': 7.22.5 '@babel/helper-function-name': 7.22.5 - '@babel/helper-member-expression-to-functions': 7.22.5 + '@babel/helper-member-expression-to-functions': 7.22.15 '@babel/helper-optimise-call-expression': 7.22.5 - '@babel/helper-replace-supers': 7.22.9(@babel/core@7.22.10) + '@babel/helper-replace-supers': 7.22.9(@babel/core@7.22.17) '@babel/helper-skip-transparent-expression-wrappers': 7.22.5 '@babel/helper-split-export-declaration': 7.22.6 semver: 6.3.1 - /@babel/helper-create-regexp-features-plugin@7.22.9(@babel/core@7.22.10): - resolution: {integrity: sha512-+svjVa/tFwsNSG4NEy1h85+HQ5imbT92Q5/bgtS7P0GTQlP8WuFdqsiABmQouhiFGyV66oGxZFpeYHza1rNsKw==} + /@babel/helper-create-regexp-features-plugin@7.22.15(@babel/core@7.22.17): + resolution: {integrity: sha512-29FkPLFjn4TPEa3RE7GpW+qbE8tlsu3jntNYNfcGsc49LphF1PQIiD+vMZ1z1xVOKt+93khA9tc2JBs3kBjA7w==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-annotate-as-pure': 7.22.5 regexpu-core: 5.3.2 semver: 6.3.1 - /@babel/helper-define-polyfill-provider@0.3.3(@babel/core@7.22.10): - resolution: {integrity: sha512-z5aQKU4IzbqCC1XH0nAqfsFLMVSo22SBKUc0BxGrLkolTdPTructy0ToNnlO2zA4j9Q/7pjMZf0DSY+DSTYzww==} - peerDependencies: - '@babel/core': ^7.4.0-0 - dependencies: - '@babel/core': 7.22.10 - '@babel/helper-compilation-targets': 7.22.10 - '@babel/helper-plugin-utils': 7.22.5 - debug: 4.3.4 - lodash.debounce: 4.0.8 - resolve: 1.22.4 - semver: 6.3.1 - transitivePeerDependencies: - - supports-color - - /@babel/helper-define-polyfill-provider@0.4.2(@babel/core@7.22.10): + /@babel/helper-define-polyfill-provider@0.4.2(@babel/core@7.22.17): resolution: {integrity: sha512-k0qnnOqHn5dK9pZpfD5XXZ9SojAITdCKRn2Lp6rnDGzIbaP0rHyMPk/4wsSxVBVz4RfN0q6VpXWP2pDGIoQ7hw==} peerDependencies: '@babel/core': ^7.4.0 || ^8.0.0-0 <8.0.0 dependencies: - '@babel/core': 7.22.10 - '@babel/helper-compilation-targets': 7.22.10 + '@babel/core': 7.22.17 + '@babel/helper-compilation-targets': 7.22.15 '@babel/helper-plugin-utils': 7.22.5 debug: 4.3.4 lodash.debounce: 4.0.8 resolve: 1.22.4 transitivePeerDependencies: - supports-color - dev: false /@babel/helper-environment-visitor@7.22.5: resolution: {integrity: sha512-XGmhECfVA/5sAt+H+xpSg0mfrHq6FzNr9Oxh7PSEBBRUb/mL7Kz3NICXb194rCqAEdxkhPT1a88teizAFyvk8Q==} @@ -522,50 +495,43 @@ packages: resolution: {integrity: sha512-wtHSq6jMRE3uF2otvfuD3DIvVhOsSNshQl0Qrd7qC9oQJzHvOL4qQXlQn2916+CXGywIjpGuIkoyZRRxHPiNQQ==} engines: {node: '>=6.9.0'} dependencies: - '@babel/template': 7.22.5 - '@babel/types': 7.22.15 + '@babel/template': 7.22.15 + '@babel/types': 7.22.17 /@babel/helper-hoist-variables@7.22.5: resolution: {integrity: sha512-wGjk9QZVzvknA6yKIUURb8zY3grXCcOZt+/7Wcy8O2uctxhplmUPkOdlgoNhmdVee2c92JXbf1xpMtVNbfoxRw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.15 + '@babel/types': 7.22.17 - /@babel/helper-member-expression-to-functions@7.22.5: - resolution: {integrity: sha512-aBiH1NKMG0H2cGZqspNvsaBe6wNGjbJjuLy29aU+eDZjSbbN53BaxlpB02xm9v34pLTZ1nIQPFYn2qMZoa5BQQ==} + /@babel/helper-member-expression-to-functions@7.22.15: + resolution: {integrity: sha512-qLNsZbgrNh0fDQBCPocSL8guki1hcPvltGDv/NxvUoABwFq7GkKSu1nRXeJkVZc+wJvne2E0RKQz+2SQrz6eAA==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.15 + '@babel/types': 7.22.17 - /@babel/helper-module-imports@7.16.0: - resolution: {integrity: sha512-kkH7sWzKPq0xt3H1n+ghb4xEMP8k0U7XV3kkB+ZGy69kDk2ySFW1qPi06sjKzFY3t1j6XbJSqr4mF9L7CYVyhg==} + /@babel/helper-module-imports@7.18.6: + resolution: {integrity: sha512-0NFvs3VkuSYbFi1x2Vd6tKrywq+z/cLeYC/RJNFrIX/30Bf5aiGYbtvGXolEktzJH8o5E5KJ3tT+nkxuuZFVlA==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.15 + '@babel/types': 7.22.17 dev: true /@babel/helper-module-imports@7.22.15: resolution: {integrity: sha512-0pYVBnDKZO2fnSPCrgM/6WMc7eS20Fbok+0r88fp+YtWVLZrp4CkafFGIp+W0VKw4a22sgebPT99y+FDNMdP4w==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.15 - dev: false - - /@babel/helper-module-imports@7.22.5: - resolution: {integrity: sha512-8Dl6+HD/cKifutF5qGd/8ZJi84QeAKh+CEe1sBzz8UayBBGg1dAIJrdHOcOM5b2MpzWL2yuotJTtGjETq0qjXg==} - engines: {node: '>=6.9.0'} - dependencies: - '@babel/types': 7.22.15 + '@babel/types': 7.22.17 - /@babel/helper-module-transforms@7.22.9(@babel/core@7.22.10): - resolution: {integrity: sha512-t+WA2Xn5K+rTeGtC8jCsdAH52bjggG5TKRuRrAGNM/mjIbO4GxvlLMFOEz9wXY5I2XQ60PMFsAG2WIcG82dQMQ==} + /@babel/helper-module-transforms@7.22.17(@babel/core@7.22.17): + resolution: {integrity: sha512-XouDDhQESrLHTpnBtCKExJdyY4gJCdrvH2Pyv8r8kovX2U8G0dRUOT45T9XlbLtuu9CLXP15eusnkprhoPV5iQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-environment-visitor': 7.22.5 - '@babel/helper-module-imports': 7.22.5 + '@babel/helper-module-imports': 7.22.15 '@babel/helper-simple-access': 7.22.5 '@babel/helper-split-export-declaration': 7.22.6 '@babel/helper-validator-identifier': 7.22.15 @@ -574,51 +540,51 @@ packages: resolution: {integrity: sha512-HBwaojN0xFRx4yIvpwGqxiV2tUfl7401jlok564NgB9EHS1y6QT17FmKWm4ztqjeVdXLuC4fSvHc5ePpQjoTbw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.15 + '@babel/types': 7.22.17 /@babel/helper-plugin-utils@7.22.5: resolution: {integrity: sha512-uLls06UVKgFG9QD4OeFYLEGteMIAa5kpTPcFL28yuCIIzsf6ZyKZMllKVOCZFhiZ5ptnwX4mtKdWCBE/uT4amg==} engines: {node: '>=6.9.0'} - /@babel/helper-remap-async-to-generator@7.22.9(@babel/core@7.22.10): - resolution: {integrity: sha512-8WWC4oR4Px+tr+Fp0X3RHDVfINGpF3ad1HIbrc8A77epiR6eMMc6jsgozkzT2uDiOOdoS9cLIQ+XD2XvI2WSmQ==} + /@babel/helper-remap-async-to-generator@7.22.17(@babel/core@7.22.17): + resolution: {integrity: sha512-bxH77R5gjH3Nkde6/LuncQoLaP16THYPscurp1S8z7S9ZgezCyV3G8Hc+TZiCmY8pz4fp8CvKSgtJMW0FkLAxA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-annotate-as-pure': 7.22.5 '@babel/helper-environment-visitor': 7.22.5 - '@babel/helper-wrap-function': 7.22.10 + '@babel/helper-wrap-function': 7.22.17 - /@babel/helper-replace-supers@7.22.9(@babel/core@7.22.10): + /@babel/helper-replace-supers@7.22.9(@babel/core@7.22.17): resolution: {integrity: sha512-LJIKvvpgPOPUThdYqcX6IXRuIcTkcAub0IaDRGCZH0p5GPUp7PhRU9QVgFcDDd51BaPkk77ZjqFwh6DZTAEmGg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-environment-visitor': 7.22.5 - '@babel/helper-member-expression-to-functions': 7.22.5 + '@babel/helper-member-expression-to-functions': 7.22.15 '@babel/helper-optimise-call-expression': 7.22.5 /@babel/helper-simple-access@7.22.5: resolution: {integrity: sha512-n0H99E/K+Bika3++WNL17POvo4rKWZ7lZEp1Q+fStVbUi8nxPQEBOlTmCOxW/0JsS56SKKQ+ojAe2pHKJHN35w==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.15 + '@babel/types': 7.22.17 /@babel/helper-skip-transparent-expression-wrappers@7.22.5: resolution: {integrity: sha512-tK14r66JZKiC43p8Ki33yLBVJKlQDFoA8GYN67lWCDCqoL6EMMSuM9b+Iff2jHaM/RRFYl7K+iiru7hbRqNx8Q==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.15 + '@babel/types': 7.22.17 /@babel/helper-split-export-declaration@7.22.6: resolution: {integrity: sha512-AsUnxuLhRYsisFiaJwvp1QF+I3KjD5FOxut14q/GzovUe6orHLesW2C7d754kRm53h5gqrz6sFl6sxc4BVtE/g==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.15 + '@babel/types': 7.22.17 /@babel/helper-string-parser@7.22.5: resolution: {integrity: sha512-mM4COjgZox8U+JcXQwPijIZLElkgEpO5rsERVDJTc2qfCDfERyob6k5WegS14SX18IIjv+XD+GrqNumY5JRCDw==} @@ -631,1018 +597,1099 @@ packages: /@babel/helper-validator-option@7.22.15: resolution: {integrity: sha512-bMn7RmyFjY/mdECUbgn9eoSY4vqvacUnS9i9vGAGttgFWesO6B4CYWA7XlpbWgBt71iv/hfbPlynohStqnu5hA==} engines: {node: '>=6.9.0'} - dev: false - /@babel/helper-validator-option@7.22.5: - resolution: {integrity: sha512-R3oB6xlIVKUnxNUxbmgq7pKjxpru24zlimpE8WK47fACIlM0II/Hm1RS8IaOI7NgCr6LNS+jl5l75m20npAziw==} - engines: {node: '>=6.9.0'} - - /@babel/helper-wrap-function@7.22.10: - resolution: {integrity: sha512-OnMhjWjuGYtdoO3FmsEFWvBStBAe2QOgwOLsLNDjN+aaiMD8InJk1/O3HSD8lkqTjCgg5YI34Tz15KNNA3p+nQ==} + /@babel/helper-wrap-function@7.22.17: + resolution: {integrity: sha512-nAhoheCMlrqU41tAojw9GpVEKDlTS8r3lzFmF0lP52LwblCPbuFSO7nGIZoIcoU5NIm1ABrna0cJExE4Ay6l2Q==} engines: {node: '>=6.9.0'} dependencies: '@babel/helper-function-name': 7.22.5 - '@babel/template': 7.22.5 - '@babel/types': 7.22.15 + '@babel/template': 7.22.15 + '@babel/types': 7.22.17 - /@babel/helpers@7.22.10: - resolution: {integrity: sha512-a41J4NW8HyZa1I1vAndrraTlPZ/eZoga2ZgS7fEr0tZJGVU4xqdE80CEm0CcNjha5EZ8fTBYLKHF0kqDUuAwQw==} + /@babel/helpers@7.22.15: + resolution: {integrity: sha512-7pAjK0aSdxOwR+CcYAqgWOGy5dcfvzsTIfFTb2odQqW47MDfv14UaJDY6eng8ylM2EaeKXdxaSWESbkmaQHTmw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/template': 7.22.5 - '@babel/traverse': 7.22.10 - '@babel/types': 7.22.11 + '@babel/template': 7.22.15 + '@babel/traverse': 7.22.17 + '@babel/types': 7.22.17 transitivePeerDependencies: - supports-color /@babel/highlight@7.22.13: resolution: {integrity: sha512-C/BaXcnnvBCmHTpz/VGZ8jgtE2aYlW4hxDhseJAWZb7gqGM/qtCK6iZUb0TyKFf7BOUsBH7Q7fkRsDRhg1XklQ==} engines: {node: '>=6.9.0'} - requiresBuild: true dependencies: '@babel/helper-validator-identifier': 7.22.15 chalk: 2.4.2 js-tokens: 4.0.0 - /@babel/parser@7.19.1: - resolution: {integrity: sha512-h7RCSorm1DdTVGJf3P2Mhj3kdnkmF/EiysUkzS2TdgAYqyjFdMQJbVuXOBej2SBJaXan/lIVtT6KkGbyyq753A==} + /@babel/parser@7.22.16: + resolution: {integrity: sha512-+gPfKv8UWeKKeJTUxe59+OobVcrYHETCsORl61EmSkmgymguYk/X5bp7GuUIXaFsc6y++v8ZxPsLSSuujqDphA==} engines: {node: '>=6.0.0'} hasBin: true dependencies: - '@babel/types': 7.22.15 - dev: true + '@babel/types': 7.22.17 - /@babel/parser@7.22.13: - resolution: {integrity: sha512-3l6+4YOvc9wx7VlCSw4yQfcBo01ECA8TicQfbnCPuCEpRQrf+gTUyGdxNw+pyTUyywp6JRD1w0YQs9TpBXYlkw==} - engines: {node: '>=6.0.0'} - hasBin: true - dependencies: - '@babel/types': 7.22.15 - - /@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@7.18.6(@babel/core@7.22.10): - resolution: {integrity: sha512-Dgxsyg54Fx1d4Nge8UnvTrED63vrwOdPmyvPzlNN/boaliRP54pm3pGzZD1SJUwrBA+Cs/xdG8kXX6Mn/RfISQ==} + /@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@7.22.15(@babel/core@7.22.17): + resolution: {integrity: sha512-FB9iYlz7rURmRJyXRKEnalYPPdn87H5no108cyuQQyMwlpJ2SJtpIUBI27kdTin956pz+LPypkPVPUTlxOmrsg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining@7.22.5(@babel/core@7.22.10): - resolution: {integrity: sha512-31Bb65aZaUwqCbWMnZPduIZxCBngHFlzyN6Dq6KAJjtx+lx6ohKHubc61OomYi7XwVD4Ol0XCVz4h+pYFR048g==} + /@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining@7.22.15(@babel/core@7.22.17): + resolution: {integrity: sha512-Hyph9LseGvAeeXzikV88bczhsrLrIZqDPxO+sSmAunMPaGrBGhfMWzCPYTtiW9t+HzSE2wtV8e5cc5P6r1xMDQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.13.0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 '@babel/helper-skip-transparent-expression-wrappers': 7.22.5 - '@babel/plugin-transform-optional-chaining': 7.22.10(@babel/core@7.22.10) + '@babel/plugin-transform-optional-chaining': 7.22.15(@babel/core@7.22.17) - /@babel/plugin-proposal-async-generator-functions@7.20.7(@babel/core@7.22.10): + /@babel/plugin-proposal-async-generator-functions@7.20.7(@babel/core@7.22.17): resolution: {integrity: sha512-xMbiLsn/8RK7Wq7VeVytytS2L6qE69bXPB10YCmMdDZbKF4okCqY74pI/jJQ/8U0b/F6NrT2+14b8/P9/3AMGA==} engines: {node: '>=6.9.0'} + deprecated: This proposal has been merged to the ECMAScript standard and thus this plugin is no longer maintained. Please use @babel/plugin-transform-async-generator-functions instead. peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-environment-visitor': 7.22.5 '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-remap-async-to-generator': 7.22.9(@babel/core@7.22.10) - '@babel/plugin-syntax-async-generators': 7.8.4(@babel/core@7.22.10) + '@babel/helper-remap-async-to-generator': 7.22.17(@babel/core@7.22.17) + '@babel/plugin-syntax-async-generators': 7.8.4(@babel/core@7.22.17) + dev: false - /@babel/plugin-proposal-class-properties@7.18.6(@babel/core@7.22.10): + /@babel/plugin-proposal-class-properties@7.18.6(@babel/core@7.22.17): resolution: {integrity: sha512-cumfXOF0+nzZrrN8Rf0t7M+tF6sZc7vhQwYQck9q1/5w2OExlD+b4v4RpMJFaV1Z7WcDRgO6FqvxqxGlwo+RHQ==} engines: {node: '>=6.9.0'} + deprecated: This proposal has been merged to the ECMAScript standard and thus this plugin is no longer maintained. Please use @babel/plugin-transform-class-properties instead. peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 - '@babel/helper-create-class-features-plugin': 7.22.10(@babel/core@7.22.10) - '@babel/helper-plugin-utils': 7.22.5 - - /@babel/plugin-proposal-class-static-block@7.21.0(@babel/core@7.22.10): - resolution: {integrity: sha512-XP5G9MWNUskFuP30IfFSEFB0Z6HzLIUcjYM4bYOPHXl7eiJ9HFv8tWj6TXTN5QODiEhDZAeI4hLok2iHFFV4hw==} - engines: {node: '>=6.9.0'} - peerDependencies: - '@babel/core': ^7.12.0 - dependencies: - '@babel/core': 7.22.10 - '@babel/helper-create-class-features-plugin': 7.22.10(@babel/core@7.22.10) - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-class-static-block': 7.14.5(@babel/core@7.22.10) - - /@babel/plugin-proposal-dynamic-import@7.18.6(@babel/core@7.22.10): - resolution: {integrity: sha512-1auuwmK+Rz13SJj36R+jqFPMJWyKEDd7lLSdOj4oJK0UTgGueSAtkrCvz9ewmgyU/P941Rv2fQwZJN8s6QruXw==} - engines: {node: '>=6.9.0'} - peerDependencies: - '@babel/core': ^7.0.0-0 - dependencies: - '@babel/core': 7.22.10 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-dynamic-import': 7.8.3(@babel/core@7.22.10) - - /@babel/plugin-proposal-export-default-from@7.22.5(@babel/core@7.22.10): - resolution: {integrity: sha512-UCe1X/hplyv6A5g2WnQ90tnHRvYL29dabCWww92lO7VdfMVTVReBTRrhiMrKQejHD9oVkdnRdwYuzUZkBVQisg==} - engines: {node: '>=6.9.0'} - peerDependencies: - '@babel/core': ^7.0.0-0 - dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 + '@babel/helper-create-class-features-plugin': 7.22.15(@babel/core@7.22.17) '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-export-default-from': 7.22.5(@babel/core@7.22.10) dev: false - /@babel/plugin-proposal-export-namespace-from@7.18.9(@babel/core@7.22.10): - resolution: {integrity: sha512-k1NtHyOMvlDDFeb9G5PhUXuGj8m/wiwojgQVEhJ/fsVsMCpLyOP4h0uGEjYJKrRI+EVPlb5Jk+Gt9P97lOGwtA==} - engines: {node: '>=6.9.0'} - peerDependencies: - '@babel/core': ^7.0.0-0 - dependencies: - '@babel/core': 7.22.10 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-export-namespace-from': 7.8.3(@babel/core@7.22.10) - - /@babel/plugin-proposal-json-strings@7.18.6(@babel/core@7.22.10): - resolution: {integrity: sha512-lr1peyn9kOdbYc0xr0OdHTZ5FMqS6Di+H0Fz2I/JwMzGmzJETNeOFq2pBySw6X/KFL5EWDjlJuMsUGRFb8fQgQ==} - engines: {node: '>=6.9.0'} - peerDependencies: - '@babel/core': ^7.0.0-0 - dependencies: - '@babel/core': 7.22.10 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-json-strings': 7.8.3(@babel/core@7.22.10) - - /@babel/plugin-proposal-logical-assignment-operators@7.20.7(@babel/core@7.22.10): - resolution: {integrity: sha512-y7C7cZgpMIjWlKE5T7eJwp+tnRYM89HmRvWM5EQuB5BoHEONjmQ8lSNmBUwOyy/GFRsohJED51YBF79hE1djug==} + /@babel/plugin-proposal-export-default-from@7.22.17(@babel/core@7.22.17): + resolution: {integrity: sha512-cop/3quQBVvdz6X5SJC6AhUv3C9DrVTM06LUEXimEdWAhCSyOJIr9NiZDU9leHZ0/aiG0Sh7Zmvaku5TWYNgbA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-logical-assignment-operators': 7.10.4(@babel/core@7.22.10) + '@babel/plugin-syntax-export-default-from': 7.22.5(@babel/core@7.22.17) + dev: false - /@babel/plugin-proposal-nullish-coalescing-operator@7.18.6(@babel/core@7.22.10): + /@babel/plugin-proposal-nullish-coalescing-operator@7.18.6(@babel/core@7.22.17): resolution: {integrity: sha512-wQxQzxYeJqHcfppzBDnm1yAY0jSRkUXR2z8RePZYrKwMKgMlE8+Z6LUno+bd6LvbGh8Gltvy74+9pIYkr+XkKA==} engines: {node: '>=6.9.0'} + deprecated: This proposal has been merged to the ECMAScript standard and thus this plugin is no longer maintained. Please use @babel/plugin-transform-nullish-coalescing-operator instead. peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3(@babel/core@7.22.10) + '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3(@babel/core@7.22.17) + dev: false - /@babel/plugin-proposal-numeric-separator@7.18.6(@babel/core@7.22.10): + /@babel/plugin-proposal-numeric-separator@7.18.6(@babel/core@7.22.17): resolution: {integrity: sha512-ozlZFogPqoLm8WBr5Z8UckIoE4YQ5KESVcNudyXOR8uqIkliTEgJ3RoketfG6pmzLdeZF0H/wjE9/cCEitBl7Q==} engines: {node: '>=6.9.0'} deprecated: This proposal has been merged to the ECMAScript standard and thus this plugin is no longer maintained. Please use @babel/plugin-transform-numeric-separator instead. peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-numeric-separator': 7.10.4(@babel/core@7.22.10) + '@babel/plugin-syntax-numeric-separator': 7.10.4(@babel/core@7.22.17) + dev: false - /@babel/plugin-proposal-object-rest-spread@7.20.7(@babel/core@7.22.10): + /@babel/plugin-proposal-object-rest-spread@7.20.7(@babel/core@7.22.17): resolution: {integrity: sha512-d2S98yCiLxDVmBmE8UjGcfPvNEUbA1U5q5WxaWFUGRzJSVAZqm5W6MbPct0jxnegUZ0niLeNX+IOzEs7wYg9Dg==} engines: {node: '>=6.9.0'} + deprecated: This proposal has been merged to the ECMAScript standard and thus this plugin is no longer maintained. Please use @babel/plugin-transform-object-rest-spread instead. peerDependencies: '@babel/core': ^7.0.0-0 dependencies: '@babel/compat-data': 7.22.9 - '@babel/core': 7.22.10 - '@babel/helper-compilation-targets': 7.22.10 + '@babel/core': 7.22.17 + '@babel/helper-compilation-targets': 7.22.15 '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-object-rest-spread': 7.8.3(@babel/core@7.22.10) - '@babel/plugin-transform-parameters': 7.22.5(@babel/core@7.22.10) + '@babel/plugin-syntax-object-rest-spread': 7.8.3(@babel/core@7.22.17) + '@babel/plugin-transform-parameters': 7.22.15(@babel/core@7.22.17) + dev: false - /@babel/plugin-proposal-optional-catch-binding@7.18.6(@babel/core@7.22.10): + /@babel/plugin-proposal-optional-catch-binding@7.18.6(@babel/core@7.22.17): resolution: {integrity: sha512-Q40HEhs9DJQyaZfUjjn6vE8Cv4GmMHCYuMGIWUnlxH6400VGxOuwWsPt4FxXxJkC/5eOzgn0z21M9gMT4MOhbw==} engines: {node: '>=6.9.0'} + deprecated: This proposal has been merged to the ECMAScript standard and thus this plugin is no longer maintained. Please use @babel/plugin-transform-optional-catch-binding instead. peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-optional-catch-binding': 7.8.3(@babel/core@7.22.10) + '@babel/plugin-syntax-optional-catch-binding': 7.8.3(@babel/core@7.22.17) + dev: false - /@babel/plugin-proposal-optional-chaining@7.21.0(@babel/core@7.22.10): + /@babel/plugin-proposal-optional-chaining@7.21.0(@babel/core@7.22.17): resolution: {integrity: sha512-p4zeefM72gpmEe2fkUr/OnOXpWEf8nAgk7ZYVqqfFiyIG7oFfVZcCrU64hWn5xp4tQ9LkV4bTIa5rD0KANpKNA==} engines: {node: '>=6.9.0'} + deprecated: This proposal has been merged to the ECMAScript standard and thus this plugin is no longer maintained. Please use @babel/plugin-transform-optional-chaining instead. peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 '@babel/helper-skip-transparent-expression-wrappers': 7.22.5 - '@babel/plugin-syntax-optional-chaining': 7.8.3(@babel/core@7.22.10) - - /@babel/plugin-proposal-private-methods@7.18.6(@babel/core@7.22.10): - resolution: {integrity: sha512-nutsvktDItsNn4rpGItSNV2sz1XwS+nfU0Rg8aCx3W3NOKVzdMjJRu0O5OkgDp3ZGICSTbgRpxZoWsxoKRvbeA==} - engines: {node: '>=6.9.0'} - peerDependencies: - '@babel/core': ^7.0.0-0 - dependencies: - '@babel/core': 7.22.10 - '@babel/helper-create-class-features-plugin': 7.22.10(@babel/core@7.22.10) - '@babel/helper-plugin-utils': 7.22.5 + '@babel/plugin-syntax-optional-chaining': 7.8.3(@babel/core@7.22.17) + dev: false - /@babel/plugin-proposal-private-property-in-object@7.21.11(@babel/core@7.22.10): - resolution: {integrity: sha512-0QZ8qP/3RLDVBwBFoWAwCtgcDZJVwA5LUJRZU8x2YFfKNuFq161wK3cuGrALu5yiPu+vzwTAg/sMWVNeWeNyaw==} + /@babel/plugin-proposal-private-property-in-object@7.21.0-placeholder-for-preset-env.2(@babel/core@7.22.17): + resolution: {integrity: sha512-SOSkfJDddaM7mak6cPEpswyTRnuRltl429hMraQEglW+OkovnCzsiszTmsrlY//qLFjCpQDFRvjdm2wA5pPm9w==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 - '@babel/helper-annotate-as-pure': 7.22.5 - '@babel/helper-create-class-features-plugin': 7.22.10(@babel/core@7.22.10) - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-private-property-in-object': 7.14.5(@babel/core@7.22.10) + '@babel/core': 7.22.17 - /@babel/plugin-proposal-unicode-property-regex@7.18.6(@babel/core@7.22.10): - resolution: {integrity: sha512-2BShG/d5yoZyXZfVePH91urL5wTG6ASZU9M4o03lKK8u8UW1y08OMttBSOADTcJrnPMpvDXRG3G8fyLh4ovs8w==} - engines: {node: '>=4'} - peerDependencies: - '@babel/core': ^7.0.0-0 - dependencies: - '@babel/core': 7.22.10 - '@babel/helper-create-regexp-features-plugin': 7.22.9(@babel/core@7.22.10) - '@babel/helper-plugin-utils': 7.22.5 - - /@babel/plugin-syntax-async-generators@7.8.4(@babel/core@7.22.10): + /@babel/plugin-syntax-async-generators@7.8.4(@babel/core@7.22.17): resolution: {integrity: sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-syntax-bigint@7.8.3(@babel/core@7.22.10): + /@babel/plugin-syntax-bigint@7.8.3(@babel/core@7.22.17): resolution: {integrity: sha512-wnTnFlG+YxQm3vDxpGE57Pj0srRU4sHE/mDkt1qv2YJJSeUAec2ma4WLUnUPeKjyrfntVwe/N6dCXpU+zL3Npg==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 dev: true - /@babel/plugin-syntax-class-properties@7.12.13(@babel/core@7.22.10): + /@babel/plugin-syntax-class-properties@7.12.13(@babel/core@7.22.17): resolution: {integrity: sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-syntax-class-static-block@7.14.5(@babel/core@7.22.10): + /@babel/plugin-syntax-class-static-block@7.14.5(@babel/core@7.22.17): resolution: {integrity: sha512-b+YyPmr6ldyNnM6sqYeMWE+bgJcJpO6yS4QD7ymxgH34GBPNDM/THBh8iunyvKIZztiwLH4CJZ0RxTk9emgpjw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-syntax-dynamic-import@7.8.3(@babel/core@7.22.10): + /@babel/plugin-syntax-dynamic-import@7.8.3(@babel/core@7.22.17): resolution: {integrity: sha512-5gdGbFon+PszYzqs83S3E5mpi7/y/8M9eC90MRTZfduQOYW76ig6SOSPNe41IG5LoP3FGBn2N0RjVDSQiS94kQ==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-syntax-export-default-from@7.22.5(@babel/core@7.22.10): + /@babel/plugin-syntax-export-default-from@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-ODAqWWXB/yReh/jVQDag/3/tl6lgBueQkk/TcfW/59Oykm4c8a55XloX0CTk2k2VJiFWMgHby9xNX29IbCv9dQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 dev: false - /@babel/plugin-syntax-export-namespace-from@7.8.3(@babel/core@7.22.10): + /@babel/plugin-syntax-export-namespace-from@7.8.3(@babel/core@7.22.17): resolution: {integrity: sha512-MXf5laXo6c1IbEbegDmzGPwGNTsHZmEy6QGznu5Sh2UCWvueywb2ee+CCE4zQiZstxU9BMoQO9i6zUFSY0Kj0Q==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-syntax-flow@7.22.5(@babel/core@7.22.10): + /@babel/plugin-syntax-flow@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-9RdCl0i+q0QExayk2nOS7853w08yLucnnPML6EN9S8fgMPVtdLDCdx/cOQ/i44Lb9UeQX9A35yaqBBOMMZxPxQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 dev: false - /@babel/plugin-syntax-import-assertions@7.22.5(@babel/core@7.22.10): + /@babel/plugin-syntax-import-assertions@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-rdV97N7KqsRzeNGoWUOK6yUsWarLjE5Su/Snk9IYPU9CwkWHs4t+rTGOvffTR8XGkJMTAdLfO0xVnXm8wugIJg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 + '@babel/helper-plugin-utils': 7.22.5 + + /@babel/plugin-syntax-import-attributes@7.22.5(@babel/core@7.22.17): + resolution: {integrity: sha512-KwvoWDeNKPETmozyFE0P2rOLqh39EoQHNjqizrI5B8Vt0ZNS7M56s7dAiAqbYfiAYOuIzIh96z3iR2ktgu3tEg==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-syntax-import-meta@7.10.4(@babel/core@7.22.10): + /@babel/plugin-syntax-import-meta@7.10.4(@babel/core@7.22.17): resolution: {integrity: sha512-Yqfm+XDx0+Prh3VSeEQCPU81yC+JWZ2pDPFSS4ZdpfZhp4MkFMaDC1UqseovEKwSUpnIL7+vK+Clp7bfh0iD7g==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-syntax-json-strings@7.8.3(@babel/core@7.22.10): + /@babel/plugin-syntax-json-strings@7.8.3(@babel/core@7.22.17): resolution: {integrity: sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-syntax-jsx@7.22.5(@babel/core@7.22.10): + /@babel/plugin-syntax-jsx@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-gvyP4hZrgrs/wWMaocvxZ44Hw0b3W8Pe+cMxc8V1ULQ07oh8VNbIRaoD1LRZVTvD+0nieDKjfgKg89sD7rrKrg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-syntax-logical-assignment-operators@7.10.4(@babel/core@7.22.10): + /@babel/plugin-syntax-logical-assignment-operators@7.10.4(@babel/core@7.22.17): resolution: {integrity: sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-syntax-nullish-coalescing-operator@7.8.3(@babel/core@7.22.10): + /@babel/plugin-syntax-nullish-coalescing-operator@7.8.3(@babel/core@7.22.17): resolution: {integrity: sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-syntax-numeric-separator@7.10.4(@babel/core@7.22.10): + /@babel/plugin-syntax-numeric-separator@7.10.4(@babel/core@7.22.17): resolution: {integrity: sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-syntax-object-rest-spread@7.8.3(@babel/core@7.22.10): + /@babel/plugin-syntax-object-rest-spread@7.8.3(@babel/core@7.22.17): resolution: {integrity: sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-syntax-optional-catch-binding@7.8.3(@babel/core@7.22.10): + /@babel/plugin-syntax-optional-catch-binding@7.8.3(@babel/core@7.22.17): resolution: {integrity: sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-syntax-optional-chaining@7.8.3(@babel/core@7.22.10): + /@babel/plugin-syntax-optional-chaining@7.8.3(@babel/core@7.22.17): resolution: {integrity: sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-syntax-private-property-in-object@7.14.5(@babel/core@7.22.10): + /@babel/plugin-syntax-private-property-in-object@7.14.5(@babel/core@7.22.17): resolution: {integrity: sha512-0wVnp9dxJ72ZUJDV27ZfbSj6iHLoytYZmh3rFcxNnvsJF3ktkzLDZPy/mA17HGsaQT3/DQsWYX1f1QGWkCoVUg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-syntax-top-level-await@7.14.5(@babel/core@7.22.10): + /@babel/plugin-syntax-top-level-await@7.14.5(@babel/core@7.22.17): resolution: {integrity: sha512-hx++upLv5U1rgYfwe1xBQUhRmU41NEvpUvrp8jkrSCdvGSnM5/qdRMtylJ6PG5OFkBaHkbTAKTnd3/YyESRHFw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-syntax-typescript@7.22.5(@babel/core@7.22.10): + /@babel/plugin-syntax-typescript@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-1mS2o03i7t1c6VzH6fdQ3OA8tcEIxwG18zIPRp+UY1Ihv6W+XZzBCVxExF9upussPXJ0xE9XRHwMoNs1ep/nRQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-transform-arrow-functions@7.22.5(@babel/core@7.22.10): + /@babel/plugin-syntax-unicode-sets-regex@7.18.6(@babel/core@7.22.17): + resolution: {integrity: sha512-727YkEAPwSIQTv5im8QHz3upqp92JTWhidIC81Tdx4VJYIte/VndKf1qKrfnnhPLiPghStWfvC/iFaMCQu7Nqg==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0 + dependencies: + '@babel/core': 7.22.17 + '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.22.17) + '@babel/helper-plugin-utils': 7.22.5 + + /@babel/plugin-transform-arrow-functions@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-26lTNXoVRdAnsaDXPpvCNUq+OVWEVC6bx7Vvz9rC53F2bagUWW4u4ii2+h8Fejfh7RYqPxn+libeFBBck9muEw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 + '@babel/helper-plugin-utils': 7.22.5 + + /@babel/plugin-transform-async-generator-functions@7.22.15(@babel/core@7.22.17): + resolution: {integrity: sha512-jBm1Es25Y+tVoTi5rfd5t1KLmL8ogLKpXszboWOTTtGFGz2RKnQe2yn7HbZ+kb/B8N0FVSGQo874NSlOU1T4+w==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.22.17 + '@babel/helper-environment-visitor': 7.22.5 '@babel/helper-plugin-utils': 7.22.5 + '@babel/helper-remap-async-to-generator': 7.22.17(@babel/core@7.22.17) + '@babel/plugin-syntax-async-generators': 7.8.4(@babel/core@7.22.17) - /@babel/plugin-transform-async-to-generator@7.22.5(@babel/core@7.22.10): + /@babel/plugin-transform-async-to-generator@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-b1A8D8ZzE/VhNDoV1MSJTnpKkCG5bJo+19R4o4oy03zM7ws8yEMK755j61Dc3EyvdysbqH5BOOTquJ7ZX9C6vQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 - '@babel/helper-module-imports': 7.22.5 + '@babel/core': 7.22.17 + '@babel/helper-module-imports': 7.22.15 '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-remap-async-to-generator': 7.22.9(@babel/core@7.22.10) + '@babel/helper-remap-async-to-generator': 7.22.17(@babel/core@7.22.17) - /@babel/plugin-transform-block-scoped-functions@7.22.5(@babel/core@7.22.10): + /@babel/plugin-transform-block-scoped-functions@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-tdXZ2UdknEKQWKJP1KMNmuF5Lx3MymtMN/pvA+p/VEkhK8jVcQ1fzSy8KM9qRYhAf2/lV33hoMPKI/xaI9sADA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-transform-block-scoping@7.22.10(@babel/core@7.22.10): - resolution: {integrity: sha512-1+kVpGAOOI1Albt6Vse7c8pHzcZQdQKW+wJH+g8mCaszOdDVwRXa/slHPqIw+oJAJANTKDMuM2cBdV0Dg618Vg==} + /@babel/plugin-transform-block-scoping@7.22.15(@babel/core@7.22.17): + resolution: {integrity: sha512-G1czpdJBZCtngoK1sJgloLiOHUnkb/bLZwqVZD8kXmq0ZnVfTTWUcs9OWtp0mBtYJ+4LQY1fllqBkOIPhXmFmw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 + '@babel/helper-plugin-utils': 7.22.5 + + /@babel/plugin-transform-class-properties@7.22.5(@babel/core@7.22.17): + resolution: {integrity: sha512-nDkQ0NfkOhPTq8YCLiWNxp1+f9fCobEjCb0n8WdbNUBc4IB5V7P1QnX9IjpSoquKrXF5SKojHleVNs2vGeHCHQ==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.22.17 + '@babel/helper-create-class-features-plugin': 7.22.15(@babel/core@7.22.17) + '@babel/helper-plugin-utils': 7.22.5 + + /@babel/plugin-transform-class-static-block@7.22.11(@babel/core@7.22.17): + resolution: {integrity: sha512-GMM8gGmqI7guS/llMFk1bJDkKfn3v3C4KHK9Yg1ey5qcHcOlKb0QvcMrgzvxo+T03/4szNh5lghY+fEC98Kq9g==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.12.0 + dependencies: + '@babel/core': 7.22.17 + '@babel/helper-create-class-features-plugin': 7.22.15(@babel/core@7.22.17) '@babel/helper-plugin-utils': 7.22.5 + '@babel/plugin-syntax-class-static-block': 7.14.5(@babel/core@7.22.17) - /@babel/plugin-transform-classes@7.22.6(@babel/core@7.22.10): - resolution: {integrity: sha512-58EgM6nuPNG6Py4Z3zSuu0xWu2VfodiMi72Jt5Kj2FECmaYk1RrTXA45z6KBFsu9tRgwQDwIiY4FXTt+YsSFAQ==} + /@babel/plugin-transform-classes@7.22.15(@babel/core@7.22.17): + resolution: {integrity: sha512-VbbC3PGjBdE0wAWDdHM9G8Gm977pnYI0XpqMd6LrKISj8/DJXEsWqgRuTYaNE9Bv0JGhTZUzHDlMk18IpOuoqw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-annotate-as-pure': 7.22.5 - '@babel/helper-compilation-targets': 7.22.10 + '@babel/helper-compilation-targets': 7.22.15 '@babel/helper-environment-visitor': 7.22.5 '@babel/helper-function-name': 7.22.5 '@babel/helper-optimise-call-expression': 7.22.5 '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-replace-supers': 7.22.9(@babel/core@7.22.10) + '@babel/helper-replace-supers': 7.22.9(@babel/core@7.22.17) '@babel/helper-split-export-declaration': 7.22.6 globals: 11.12.0 - /@babel/plugin-transform-computed-properties@7.22.5(@babel/core@7.22.10): + /@babel/plugin-transform-computed-properties@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-4GHWBgRf0krxPX+AaPtgBAlTgTeZmqDynokHOX7aqqAB4tHs3U2Y02zH6ETFdLZGcg9UQSD1WCmkVrE9ErHeOg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - '@babel/template': 7.22.5 + '@babel/template': 7.22.15 - /@babel/plugin-transform-destructuring@7.22.10(@babel/core@7.22.10): - resolution: {integrity: sha512-dPJrL0VOyxqLM9sritNbMSGx/teueHF/htMKrPT7DNxccXxRDPYqlgPFFdr8u+F+qUZOkZoXue/6rL5O5GduEw==} + /@babel/plugin-transform-destructuring@7.22.15(@babel/core@7.22.17): + resolution: {integrity: sha512-HzG8sFl1ZVGTme74Nw+X01XsUTqERVQ6/RLHo3XjGRzm7XD6QTtfS3NJotVgCGy8BzkDqRjRBD8dAyJn5TuvSQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-transform-dotall-regex@7.18.6(@babel/core@7.22.10): - resolution: {integrity: sha512-6S3jpun1eEbAxq7TdjLotAsl4WpQI9DxfkycRcKrjhQYzU87qpXdknpBg/e+TdcMehqGnLFi7tnFUBR02Vq6wg==} + /@babel/plugin-transform-dotall-regex@7.22.5(@babel/core@7.22.17): + resolution: {integrity: sha512-5/Yk9QxCQCl+sOIB1WelKnVRxTJDSAIxtJLL2/pqL14ZVlbH0fUQUZa/T5/UnQtBNgghR7mfB8ERBKyKPCi7Vw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 - '@babel/helper-create-regexp-features-plugin': 7.22.9(@babel/core@7.22.10) + '@babel/core': 7.22.17 + '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.22.17) '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-transform-duplicate-keys@7.22.5(@babel/core@7.22.10): + /@babel/plugin-transform-duplicate-keys@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-dEnYD+9BBgld5VBXHnF/DbYGp3fqGMsyxKbtD1mDyIA7AkTSpKXFhCVuj/oQVOoALfBs77DudA0BE4d5mcpmqw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-transform-exponentiation-operator@7.22.5(@babel/core@7.22.10): + /@babel/plugin-transform-dynamic-import@7.22.11(@babel/core@7.22.17): + resolution: {integrity: sha512-g/21plo58sfteWjaO0ZNVb+uEOkJNjAaHhbejrnBmu011l/eNDScmkbjCC3l4FKb10ViaGU4aOkFznSu2zRHgA==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.22.17 + '@babel/helper-plugin-utils': 7.22.5 + '@babel/plugin-syntax-dynamic-import': 7.8.3(@babel/core@7.22.17) + + /@babel/plugin-transform-exponentiation-operator@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-vIpJFNM/FjZ4rh1myqIya9jXwrwwgFRHPjT3DkUA9ZLHuzox8jiXkOLvwm1H+PQIP3CqfC++WPKeuDi0Sjdj1g==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 - '@babel/helper-builder-binary-assignment-operator-visitor': 7.22.10 + '@babel/core': 7.22.17 + '@babel/helper-builder-binary-assignment-operator-visitor': 7.22.15 + '@babel/helper-plugin-utils': 7.22.5 + + /@babel/plugin-transform-export-namespace-from@7.22.11(@babel/core@7.22.17): + resolution: {integrity: sha512-xa7aad7q7OiT8oNZ1mU7NrISjlSkVdMbNxn9IuLZyL9AJEhs1Apba3I+u5riX1dIkdptP5EKDG5XDPByWxtehw==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 + '@babel/plugin-syntax-export-namespace-from': 7.8.3(@babel/core@7.22.17) - /@babel/plugin-transform-flow-strip-types@7.22.5(@babel/core@7.22.10): + /@babel/plugin-transform-flow-strip-types@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-tujNbZdxdG0/54g/oua8ISToaXTFBf8EnSb5PgQSciIXWOWKX3S4+JR7ZE9ol8FZwf9kxitzkGQ+QWeov/mCiA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-flow': 7.22.5(@babel/core@7.22.10) + '@babel/plugin-syntax-flow': 7.22.5(@babel/core@7.22.17) dev: false - /@babel/plugin-transform-for-of@7.22.5(@babel/core@7.22.10): - resolution: {integrity: sha512-3kxQjX1dU9uudwSshyLeEipvrLjBCVthCgeTp6CzE/9JYrlAIaeekVxRpCWsDDfYTfRZRoCeZatCQvwo+wvK8A==} + /@babel/plugin-transform-for-of@7.22.15(@babel/core@7.22.17): + resolution: {integrity: sha512-me6VGeHsx30+xh9fbDLLPi0J1HzmeIIyenoOQHuw2D4m2SAU3NrspX5XxJLBpqn5yrLzrlw2Iy3RA//Bx27iOA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-transform-function-name@7.22.5(@babel/core@7.22.10): + /@babel/plugin-transform-function-name@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-UIzQNMS0p0HHiQm3oelztj+ECwFnj+ZRV4KnguvlsD2of1whUeM6o7wGNj6oLwcDoAXQ8gEqfgC24D+VdIcevg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 - '@babel/helper-compilation-targets': 7.22.10 + '@babel/core': 7.22.17 + '@babel/helper-compilation-targets': 7.22.15 '@babel/helper-function-name': 7.22.5 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-transform-literals@7.22.5(@babel/core@7.22.10): + /@babel/plugin-transform-json-strings@7.22.11(@babel/core@7.22.17): + resolution: {integrity: sha512-CxT5tCqpA9/jXFlme9xIBCc5RPtdDq3JpkkhgHQqtDdiTnTI0jtZ0QzXhr5DILeYifDPp2wvY2ad+7+hLMW5Pw==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.22.17 + '@babel/helper-plugin-utils': 7.22.5 + '@babel/plugin-syntax-json-strings': 7.8.3(@babel/core@7.22.17) + + /@babel/plugin-transform-literals@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-fTLj4D79M+mepcw3dgFBTIDYpbcB9Sm0bpm4ppXPaO+U+PKFFyV9MGRvS0gvGw62sd10kT5lRMKXAADb9pWy8g==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 + '@babel/helper-plugin-utils': 7.22.5 + + /@babel/plugin-transform-logical-assignment-operators@7.22.11(@babel/core@7.22.17): + resolution: {integrity: sha512-qQwRTP4+6xFCDV5k7gZBF3C31K34ut0tbEcTKxlX/0KXxm9GLcO14p570aWxFvVzx6QAfPgq7gaeIHXJC8LswQ==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 + '@babel/plugin-syntax-logical-assignment-operators': 7.10.4(@babel/core@7.22.17) - /@babel/plugin-transform-member-expression-literals@7.22.5(@babel/core@7.22.10): + /@babel/plugin-transform-member-expression-literals@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-RZEdkNtzzYCFl9SE9ATaUMTj2hqMb4StarOJLrZRbqqU4HSBE7UlBw9WBWQiDzrJZJdUWiMTVDI6Gv/8DPvfew==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-transform-modules-amd@7.22.5(@babel/core@7.22.10): + /@babel/plugin-transform-modules-amd@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-R+PTfLTcYEmb1+kK7FNkhQ1gP4KgjpSO6HfH9+f8/yfp2Nt3ggBjiVpRwmwTlfqZLafYKJACy36yDXlEmI9HjQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 - '@babel/helper-module-transforms': 7.22.9(@babel/core@7.22.10) + '@babel/core': 7.22.17 + '@babel/helper-module-transforms': 7.22.17(@babel/core@7.22.17) '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-transform-modules-commonjs@7.22.5(@babel/core@7.22.10): - resolution: {integrity: sha512-B4pzOXj+ONRmuaQTg05b3y/4DuFz3WcCNAXPLb2Q0GT0TrGKGxNKV4jwsXts+StaM0LQczZbOpj8o1DLPDJIiA==} + /@babel/plugin-transform-modules-commonjs@7.22.15(@babel/core@7.22.17): + resolution: {integrity: sha512-jWL4eh90w0HQOTKP2MoXXUpVxilxsB2Vl4ji69rSjS3EcZ/v4sBmn+A3NpepuJzBhOaEBbR7udonlHHn5DWidg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 - '@babel/helper-module-transforms': 7.22.9(@babel/core@7.22.10) + '@babel/core': 7.22.17 + '@babel/helper-module-transforms': 7.22.17(@babel/core@7.22.17) '@babel/helper-plugin-utils': 7.22.5 '@babel/helper-simple-access': 7.22.5 - /@babel/plugin-transform-modules-systemjs@7.22.5(@babel/core@7.22.10): - resolution: {integrity: sha512-emtEpoaTMsOs6Tzz+nbmcePl6AKVtS1yC4YNAeMun9U8YCsgadPNxnOPQ8GhHFB2qdx+LZu9LgoC0Lthuu05DQ==} + /@babel/plugin-transform-modules-systemjs@7.22.11(@babel/core@7.22.17): + resolution: {integrity: sha512-rIqHmHoMEOhI3VkVf5jQ15l539KrwhzqcBO6wdCNWPWc/JWt9ILNYNUssbRpeq0qWns8svuw8LnMNCvWBIJ8wA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-hoist-variables': 7.22.5 - '@babel/helper-module-transforms': 7.22.9(@babel/core@7.22.10) + '@babel/helper-module-transforms': 7.22.17(@babel/core@7.22.17) '@babel/helper-plugin-utils': 7.22.5 '@babel/helper-validator-identifier': 7.22.15 - /@babel/plugin-transform-modules-umd@7.18.6(@babel/core@7.22.10): - resolution: {integrity: sha512-dcegErExVeXcRqNtkRU/z8WlBLnvD4MRnHgNs3MytRO1Mn1sHRyhbcpYbVMGclAqOjdW+9cfkdZno9dFdfKLfQ==} + /@babel/plugin-transform-modules-umd@7.22.5(@babel/core@7.22.17): + resolution: {integrity: sha512-+S6kzefN/E1vkSsKx8kmQuqeQsvCKCd1fraCM7zXm4SFoggI099Tr4G8U81+5gtMdUeMQ4ipdQffbKLX0/7dBQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 - '@babel/helper-module-transforms': 7.22.9(@babel/core@7.22.10) + '@babel/core': 7.22.17 + '@babel/helper-module-transforms': 7.22.17(@babel/core@7.22.17) '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-transform-named-capturing-groups-regex@7.22.5(@babel/core@7.22.10): + /@babel/plugin-transform-named-capturing-groups-regex@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-YgLLKmS3aUBhHaxp5hi1WJTgOUb/NCuDHzGT9z9WTt3YG+CPRhJs6nprbStx6DnWM4dh6gt7SU3sZodbZ08adQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.22.10 - '@babel/helper-create-regexp-features-plugin': 7.22.9(@babel/core@7.22.10) + '@babel/core': 7.22.17 + '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.22.17) + '@babel/helper-plugin-utils': 7.22.5 + + /@babel/plugin-transform-new-target@7.22.5(@babel/core@7.22.17): + resolution: {integrity: sha512-AsF7K0Fx/cNKVyk3a+DW0JLo+Ua598/NxMRvxDnkpCIGFh43+h/v2xyhRUYf6oD8gE4QtL83C7zZVghMjHd+iw==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.22.17 + '@babel/helper-plugin-utils': 7.22.5 + + /@babel/plugin-transform-nullish-coalescing-operator@7.22.11(@babel/core@7.22.17): + resolution: {integrity: sha512-YZWOw4HxXrotb5xsjMJUDlLgcDXSfO9eCmdl1bgW4+/lAGdkjaEvOnQ4p5WKKdUgSzO39dgPl0pTnfxm0OAXcg==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 + '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3(@babel/core@7.22.17) - /@babel/plugin-transform-new-target@7.18.6(@babel/core@7.22.10): - resolution: {integrity: sha512-DjwFA/9Iu3Z+vrAn+8pBUGcjhxKguSMlsFqeCKbhb9BAV756v0krzVK04CRDi/4aqmk8BsHb4a/gFcaA5joXRw==} + /@babel/plugin-transform-numeric-separator@7.22.11(@babel/core@7.22.17): + resolution: {integrity: sha512-3dzU4QGPsILdJbASKhF/V2TVP+gJya1PsueQCxIPCEcerqF21oEcrob4mzjsp2Py/1nLfF5m+xYNMDpmA8vffg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 + '@babel/plugin-syntax-numeric-separator': 7.10.4(@babel/core@7.22.17) - /@babel/plugin-transform-object-super@7.22.5(@babel/core@7.22.10): + /@babel/plugin-transform-object-rest-spread@7.22.15(@babel/core@7.22.17): + resolution: {integrity: sha512-fEB+I1+gAmfAyxZcX1+ZUwLeAuuf8VIg67CTznZE0MqVFumWkh8xWtn58I4dxdVf080wn7gzWoF8vndOViJe9Q==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/compat-data': 7.22.9 + '@babel/core': 7.22.17 + '@babel/helper-compilation-targets': 7.22.15 + '@babel/helper-plugin-utils': 7.22.5 + '@babel/plugin-syntax-object-rest-spread': 7.8.3(@babel/core@7.22.17) + '@babel/plugin-transform-parameters': 7.22.15(@babel/core@7.22.17) + + /@babel/plugin-transform-object-super@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-klXqyaT9trSjIUrcsYIfETAzmOEZL3cBYqOYLJxBHfMFFggmXOv+NYSX/Jbs9mzMVESw/WycLFPRx8ba/b2Ipw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-replace-supers': 7.22.9(@babel/core@7.22.10) + '@babel/helper-replace-supers': 7.22.9(@babel/core@7.22.17) - /@babel/plugin-transform-optional-chaining@7.22.10(@babel/core@7.22.10): - resolution: {integrity: sha512-MMkQqZAZ+MGj+jGTG3OTuhKeBpNcO+0oCEbrGNEaOmiEn+1MzRyQlYsruGiU8RTK3zV6XwrVJTmwiDOyYK6J9g==} + /@babel/plugin-transform-optional-catch-binding@7.22.11(@babel/core@7.22.17): + resolution: {integrity: sha512-rli0WxesXUeCJnMYhzAglEjLWVDF6ahb45HuprcmQuLidBJFWjNnOzssk2kuc6e33FlLaiZhG/kUIzUMWdBKaQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-skip-transparent-expression-wrappers': 7.22.5 - '@babel/plugin-syntax-optional-chaining': 7.8.3(@babel/core@7.22.10) + '@babel/plugin-syntax-optional-catch-binding': 7.8.3(@babel/core@7.22.17) - /@babel/plugin-transform-parameters@7.22.5(@babel/core@7.22.10): - resolution: {integrity: sha512-AVkFUBurORBREOmHRKo06FjHYgjrabpdqRSwq6+C7R5iTCZOsM4QbcB27St0a4U6fffyAOqh3s/qEfybAhfivg==} + /@babel/plugin-transform-optional-chaining@7.22.15(@babel/core@7.22.17): + resolution: {integrity: sha512-ngQ2tBhq5vvSJw2Q2Z9i7ealNkpDMU0rGWnHPKqRZO0tzZ5tlaoz4hDvhXioOoaE0X2vfNss1djwg0DXlfu30A==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 + '@babel/helper-skip-transparent-expression-wrappers': 7.22.5 + '@babel/plugin-syntax-optional-chaining': 7.8.3(@babel/core@7.22.17) - /@babel/plugin-transform-property-literals@7.22.5(@babel/core@7.22.10): - resolution: {integrity: sha512-TiOArgddK3mK/x1Qwf5hay2pxI6wCZnvQqrFSqbtg1GLl2JcNMitVH/YnqjP+M31pLUeTfzY1HAXFDnUBV30rQ==} + /@babel/plugin-transform-parameters@7.22.15(@babel/core@7.22.17): + resolution: {integrity: sha512-hjk7qKIqhyzhhUvRT683TYQOFa/4cQKwQy7ALvTpODswN40MljzNDa0YldevS6tGbxwaEKVn502JmY0dP7qEtQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-transform-react-display-name@7.22.5(@babel/core@7.22.10): - resolution: {integrity: sha512-PVk3WPYudRF5z4GKMEYUrLjPl38fJSKNaEOkFuoprioowGuWN6w2RKznuFNSlJx7pzzXXStPUnNSOEO0jL5EVw==} + /@babel/plugin-transform-private-methods@7.22.5(@babel/core@7.22.17): + resolution: {integrity: sha512-PPjh4gyrQnGe97JTalgRGMuU4icsZFnWkzicB/fUtzlKUqvsWBKEpPPfr5a2JiyirZkHxnAqkQMO5Z5B2kK3fA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 + '@babel/helper-create-class-features-plugin': 7.22.15(@babel/core@7.22.17) '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-transform-react-jsx-development@7.18.6(@babel/core@7.22.10): - resolution: {integrity: sha512-SA6HEjwYFKF7WDjWcMcMGUimmw/nhNRDWxr+KaLSCrkD/LMDBvWRmHAYgE1HDeF8KUuI8OAu+RT6EOtKxSW2qA==} + /@babel/plugin-transform-private-property-in-object@7.22.11(@babel/core@7.22.17): + resolution: {integrity: sha512-sSCbqZDBKHetvjSwpyWzhuHkmW5RummxJBVbYLkGkaiTOWGxml7SXt0iWa03bzxFIx7wOj3g/ILRd0RcJKBeSQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 - '@babel/plugin-transform-react-jsx': 7.22.5(@babel/core@7.22.10) - dev: true + '@babel/core': 7.22.17 + '@babel/helper-annotate-as-pure': 7.22.5 + '@babel/helper-create-class-features-plugin': 7.22.15(@babel/core@7.22.17) + '@babel/helper-plugin-utils': 7.22.5 + '@babel/plugin-syntax-private-property-in-object': 7.14.5(@babel/core@7.22.17) - /@babel/plugin-transform-react-jsx-self@7.18.6(@babel/core@7.22.10): - resolution: {integrity: sha512-A0LQGx4+4Jv7u/tWzoJF7alZwnBDQd6cGLh9P+Ttk4dpiL+J5p7NSNv/9tlEFFJDq3kjxOavWmbm6t0Gk+A3Ig==} + /@babel/plugin-transform-property-literals@7.22.5(@babel/core@7.22.17): + resolution: {integrity: sha512-TiOArgddK3mK/x1Qwf5hay2pxI6wCZnvQqrFSqbtg1GLl2JcNMitVH/YnqjP+M31pLUeTfzY1HAXFDnUBV30rQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - dev: false - /@babel/plugin-transform-react-jsx-self@7.22.5(@babel/core@7.22.10): - resolution: {integrity: sha512-nTh2ogNUtxbiSbxaT4Ds6aXnXEipHweN9YRgOX/oNXdf0cCrGn/+2LozFa3lnPV5D90MkjhgckCPBrsoSc1a7g==} + /@babel/plugin-transform-react-display-name@7.22.5(@babel/core@7.22.17): + resolution: {integrity: sha512-PVk3WPYudRF5z4GKMEYUrLjPl38fJSKNaEOkFuoprioowGuWN6w2RKznuFNSlJx7pzzXXStPUnNSOEO0jL5EVw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 + + /@babel/plugin-transform-react-jsx-development@7.22.5(@babel/core@7.22.17): + resolution: {integrity: sha512-bDhuzwWMuInwCYeDeMzyi7TaBgRQei6DqxhbyniL7/VG4RSS7HtSL2QbY4eESy1KJqlWt8g3xeEBGPuo+XqC8A==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.22.17 + '@babel/plugin-transform-react-jsx': 7.22.15(@babel/core@7.22.17) dev: true - /@babel/plugin-transform-react-jsx-source@7.18.6(@babel/core@7.22.10): - resolution: {integrity: sha512-utZmlASneDfdaMh0m/WausbjUjEdGrQJz0vFK93d7wD3xf5wBtX219+q6IlCNZeguIcxS2f/CvLZrlLSvSHQXw==} + /@babel/plugin-transform-react-jsx-self@7.22.5(@babel/core@7.22.17): + resolution: {integrity: sha512-nTh2ogNUtxbiSbxaT4Ds6aXnXEipHweN9YRgOX/oNXdf0cCrGn/+2LozFa3lnPV5D90MkjhgckCPBrsoSc1a7g==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - dev: false - /@babel/plugin-transform-react-jsx-source@7.22.5(@babel/core@7.22.10): + /@babel/plugin-transform-react-jsx-source@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-yIiRO6yobeEIaI0RTbIr8iAK9FcBHLtZq0S89ZPjDLQXBA4xvghaKqI0etp/tF3htTM0sazJKKLz9oEiGRtu7w==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - dev: true - /@babel/plugin-transform-react-jsx@7.22.5(@babel/core@7.22.10): - resolution: {integrity: sha512-rog5gZaVbUip5iWDMTYbVM15XQq+RkUKhET/IHR6oizR+JEoN6CAfTTuHcK4vwUyzca30qqHqEpzBOnaRMWYMA==} + /@babel/plugin-transform-react-jsx@7.22.15(@babel/core@7.22.17): + resolution: {integrity: sha512-oKckg2eZFa8771O/5vi7XeTvmM6+O9cxZu+kanTU7tD4sin5nO/G8jGJhq8Hvt2Z0kUoEDRayuZLaUlYl8QuGA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-annotate-as-pure': 7.22.5 - '@babel/helper-module-imports': 7.22.5 + '@babel/helper-module-imports': 7.22.15 '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-jsx': 7.22.5(@babel/core@7.22.10) - '@babel/types': 7.22.15 + '@babel/plugin-syntax-jsx': 7.22.5(@babel/core@7.22.17) + '@babel/types': 7.22.17 - /@babel/plugin-transform-react-pure-annotations@7.18.6(@babel/core@7.22.10): - resolution: {integrity: sha512-I8VfEPg9r2TRDdvnHgPepTKvuRomzA8+u+nhY7qSI1fR2hRNebasZEETLyM5mAUr0Ku56OkXJ0I7NHJnO6cJiQ==} + /@babel/plugin-transform-react-pure-annotations@7.22.5(@babel/core@7.22.17): + resolution: {integrity: sha512-gP4k85wx09q+brArVinTXhWiyzLl9UpmGva0+mWyKxk6JZequ05x3eUcIUE+FyttPKJFRRVtAvQaJ6YF9h1ZpA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-annotate-as-pure': 7.22.5 '@babel/helper-plugin-utils': 7.22.5 dev: true - /@babel/plugin-transform-regenerator@7.22.10(@babel/core@7.22.10): + /@babel/plugin-transform-regenerator@7.22.10(@babel/core@7.22.17): resolution: {integrity: sha512-F28b1mDt8KcT5bUyJc/U9nwzw6cV+UmTeRlXYIl2TNqMMJif0Jeey9/RQ3C4NOd2zp0/TRsDns9ttj2L523rsw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 regenerator-transform: 0.15.2 - /@babel/plugin-transform-reserved-words@7.18.6(@babel/core@7.22.10): - resolution: {integrity: sha512-oX/4MyMoypzHjFrT1CdivfKZ+XvIPMFXwwxHp/r0Ddy2Vuomt4HDFGmft1TAY2yiTKiNSsh3kjBAzcM8kSdsjA==} + /@babel/plugin-transform-reserved-words@7.22.5(@babel/core@7.22.17): + resolution: {integrity: sha512-DTtGKFRQUDm8svigJzZHzb/2xatPc6TzNvAIJ5GqOKDsGFYgAskjRulbR/vGsPKq3OPqtexnz327qYpP57RFyA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-transform-runtime@7.22.15(@babel/core@7.22.10): + /@babel/plugin-transform-runtime@7.22.15(@babel/core@7.22.17): resolution: {integrity: sha512-tEVLhk8NRZSmwQ0DJtxxhTrCht1HVo8VaMzYT4w6lwyKBuHsgoioAUA7/6eT2fRfc5/23fuGdlwIxXhRVgWr4g==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-module-imports': 7.22.15 '@babel/helper-plugin-utils': 7.22.5 - babel-plugin-polyfill-corejs2: 0.4.5(@babel/core@7.22.10) - babel-plugin-polyfill-corejs3: 0.8.3(@babel/core@7.22.10) - babel-plugin-polyfill-regenerator: 0.5.2(@babel/core@7.22.10) + babel-plugin-polyfill-corejs2: 0.4.5(@babel/core@7.22.17) + babel-plugin-polyfill-corejs3: 0.8.3(@babel/core@7.22.17) + babel-plugin-polyfill-regenerator: 0.5.2(@babel/core@7.22.17) semver: 6.3.1 transitivePeerDependencies: - supports-color dev: false - /@babel/plugin-transform-shorthand-properties@7.22.5(@babel/core@7.22.10): + /@babel/plugin-transform-shorthand-properties@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-vM4fq9IXHscXVKzDv5itkO1X52SmdFBFcMIBZ2FRn2nqVYqw6dBexUgMvAjHW+KXpPPViD/Yo3GrDEBaRC0QYA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-transform-spread@7.22.5(@babel/core@7.22.10): + /@babel/plugin-transform-spread@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-5ZzDQIGyvN4w8+dMmpohL6MBo+l2G7tfC/O2Dg7/hjpgeWvUx8FzfeOKxGog9IimPa4YekaQ9PlDqTLOljkcxg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 '@babel/helper-skip-transparent-expression-wrappers': 7.22.5 - /@babel/plugin-transform-sticky-regex@7.22.5(@babel/core@7.22.10): + /@babel/plugin-transform-sticky-regex@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-zf7LuNpHG0iEeiyCNwX4j3gDg1jgt1k3ZdXBKbZSoA3BbGQGvMiSvfbZRR3Dr3aeJe3ooWFZxOOG3IRStYp2Bw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-transform-template-literals@7.22.5(@babel/core@7.22.10): + /@babel/plugin-transform-template-literals@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-5ciOehRNf+EyUeewo8NkbQiUs4d6ZxiHo6BcBcnFlgiJfu16q0bQUw9Jvo0b0gBKFG1SMhDSjeKXSYuJLeFSMA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-transform-typeof-symbol@7.22.5(@babel/core@7.22.10): + /@babel/plugin-transform-typeof-symbol@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-bYkI5lMzL4kPii4HHEEChkD0rkc+nvnlR6+o/qdqR6zrm0Sv/nodmyLhlq2DO0YKLUNd2VePmPRjJXSBh9OIdA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-transform-typescript@7.22.10(@babel/core@7.22.10): - resolution: {integrity: sha512-7++c8I/ymsDo4QQBAgbraXLzIM6jmfao11KgIBEYZRReWzNWH9NtNgJcyrZiXsOPh523FQm6LfpLyy/U5fn46A==} + /@babel/plugin-transform-typescript@7.22.15(@babel/core@7.22.17): + resolution: {integrity: sha512-1uirS0TnijxvQLnlv5wQBwOX3E1wCFX7ITv+9pBV2wKEk4K+M5tqDaoNXnTH8tjEIYHLO98MwiTWO04Ggz4XuA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-annotate-as-pure': 7.22.5 - '@babel/helper-create-class-features-plugin': 7.22.10(@babel/core@7.22.10) + '@babel/helper-create-class-features-plugin': 7.22.15(@babel/core@7.22.17) '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-typescript': 7.22.5(@babel/core@7.22.10) + '@babel/plugin-syntax-typescript': 7.22.5(@babel/core@7.22.17) - /@babel/plugin-transform-unicode-escapes@7.22.10(@babel/core@7.22.10): + /@babel/plugin-transform-unicode-escapes@7.22.10(@babel/core@7.22.17): resolution: {integrity: sha512-lRfaRKGZCBqDlRU3UIFovdp9c9mEvlylmpod0/OatICsSfuQ9YFthRo1tpTkGsklEefZdqlEFdY4A2dwTb6ohg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 + '@babel/helper-plugin-utils': 7.22.5 + + /@babel/plugin-transform-unicode-property-regex@7.22.5(@babel/core@7.22.17): + resolution: {integrity: sha512-HCCIb+CbJIAE6sXn5CjFQXMwkCClcOfPCzTlilJ8cUatfzwHlWQkbtV0zD338u9dZskwvuOYTuuaMaA8J5EI5A==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.22.17 + '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.22.17) '@babel/helper-plugin-utils': 7.22.5 - /@babel/plugin-transform-unicode-regex@7.22.5(@babel/core@7.22.10): + /@babel/plugin-transform-unicode-regex@7.22.5(@babel/core@7.22.17): resolution: {integrity: sha512-028laaOKptN5vHJf9/Arr/HiJekMd41hOEZYvNsrsXqJ7YPYuX2bQxh31fkZzGmq3YqHRJzYFFAVYvKfMPKqyg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 - '@babel/helper-create-regexp-features-plugin': 7.22.9(@babel/core@7.22.10) + '@babel/core': 7.22.17 + '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.22.17) + '@babel/helper-plugin-utils': 7.22.5 + + /@babel/plugin-transform-unicode-sets-regex@7.22.5(@babel/core@7.22.17): + resolution: {integrity: sha512-lhMfi4FC15j13eKrh3DnYHjpGj6UKQHtNKTbtc1igvAhRy4+kLhV07OpLcsN0VgDEw/MjAvJO4BdMJsHwMhzCg==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0 + dependencies: + '@babel/core': 7.22.17 + '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.22.17) '@babel/helper-plugin-utils': 7.22.5 - /@babel/preset-env@7.21.5(@babel/core@7.22.10): - resolution: {integrity: sha512-wH00QnTTldTbf/IefEVyChtRdw5RJvODT/Vb4Vcxq1AZvtXj6T0YeX0cAcXhI6/BdGuiP3GcNIL4OQbI2DVNxg==} + /@babel/preset-env@7.22.15(@babel/core@7.22.17): + resolution: {integrity: sha512-tZFHr54GBkHk6hQuVA8w4Fmq+MSPsfvMG0vPnOYyTnJpyfMqybL8/MbNCPRT9zc2KBO2pe4tq15g6Uno4Jpoag==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: '@babel/compat-data': 7.22.9 - '@babel/core': 7.22.10 - '@babel/helper-compilation-targets': 7.22.10 + '@babel/core': 7.22.17 + '@babel/helper-compilation-targets': 7.22.15 '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-validator-option': 7.22.5 - '@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-proposal-async-generator-functions': 7.20.7(@babel/core@7.22.10) - '@babel/plugin-proposal-class-properties': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-proposal-class-static-block': 7.21.0(@babel/core@7.22.10) - '@babel/plugin-proposal-dynamic-import': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-proposal-export-namespace-from': 7.18.9(@babel/core@7.22.10) - '@babel/plugin-proposal-json-strings': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-proposal-logical-assignment-operators': 7.20.7(@babel/core@7.22.10) - '@babel/plugin-proposal-nullish-coalescing-operator': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-proposal-numeric-separator': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-proposal-object-rest-spread': 7.20.7(@babel/core@7.22.10) - '@babel/plugin-proposal-optional-catch-binding': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-proposal-optional-chaining': 7.21.0(@babel/core@7.22.10) - '@babel/plugin-proposal-private-methods': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-proposal-private-property-in-object': 7.21.11(@babel/core@7.22.10) - '@babel/plugin-proposal-unicode-property-regex': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-syntax-async-generators': 7.8.4(@babel/core@7.22.10) - '@babel/plugin-syntax-class-properties': 7.12.13(@babel/core@7.22.10) - '@babel/plugin-syntax-class-static-block': 7.14.5(@babel/core@7.22.10) - '@babel/plugin-syntax-dynamic-import': 7.8.3(@babel/core@7.22.10) - '@babel/plugin-syntax-export-namespace-from': 7.8.3(@babel/core@7.22.10) - '@babel/plugin-syntax-import-assertions': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-syntax-import-meta': 7.10.4(@babel/core@7.22.10) - '@babel/plugin-syntax-json-strings': 7.8.3(@babel/core@7.22.10) - '@babel/plugin-syntax-logical-assignment-operators': 7.10.4(@babel/core@7.22.10) - '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3(@babel/core@7.22.10) - '@babel/plugin-syntax-numeric-separator': 7.10.4(@babel/core@7.22.10) - '@babel/plugin-syntax-object-rest-spread': 7.8.3(@babel/core@7.22.10) - '@babel/plugin-syntax-optional-catch-binding': 7.8.3(@babel/core@7.22.10) - '@babel/plugin-syntax-optional-chaining': 7.8.3(@babel/core@7.22.10) - '@babel/plugin-syntax-private-property-in-object': 7.14.5(@babel/core@7.22.10) - '@babel/plugin-syntax-top-level-await': 7.14.5(@babel/core@7.22.10) - '@babel/plugin-transform-arrow-functions': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-async-to-generator': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-block-scoped-functions': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-block-scoping': 7.22.10(@babel/core@7.22.10) - '@babel/plugin-transform-classes': 7.22.6(@babel/core@7.22.10) - '@babel/plugin-transform-computed-properties': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-destructuring': 7.22.10(@babel/core@7.22.10) - '@babel/plugin-transform-dotall-regex': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-transform-duplicate-keys': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-exponentiation-operator': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-for-of': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-function-name': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-literals': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-member-expression-literals': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-modules-amd': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-modules-commonjs': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-modules-systemjs': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-modules-umd': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-transform-named-capturing-groups-regex': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-new-target': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-transform-object-super': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-parameters': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-property-literals': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-regenerator': 7.22.10(@babel/core@7.22.10) - '@babel/plugin-transform-reserved-words': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-transform-shorthand-properties': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-spread': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-sticky-regex': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-template-literals': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-typeof-symbol': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-unicode-escapes': 7.22.10(@babel/core@7.22.10) - '@babel/plugin-transform-unicode-regex': 7.22.5(@babel/core@7.22.10) - '@babel/preset-modules': 0.1.5(@babel/core@7.22.10) - '@babel/types': 7.22.10 - babel-plugin-polyfill-corejs2: 0.3.3(@babel/core@7.22.10) - babel-plugin-polyfill-corejs3: 0.6.0(@babel/core@7.22.10) - babel-plugin-polyfill-regenerator: 0.4.1(@babel/core@7.22.10) - core-js-compat: 3.32.0 + '@babel/helper-validator-option': 7.22.15 + '@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-proposal-private-property-in-object': 7.21.0-placeholder-for-preset-env.2(@babel/core@7.22.17) + '@babel/plugin-syntax-async-generators': 7.8.4(@babel/core@7.22.17) + '@babel/plugin-syntax-class-properties': 7.12.13(@babel/core@7.22.17) + '@babel/plugin-syntax-class-static-block': 7.14.5(@babel/core@7.22.17) + '@babel/plugin-syntax-dynamic-import': 7.8.3(@babel/core@7.22.17) + '@babel/plugin-syntax-export-namespace-from': 7.8.3(@babel/core@7.22.17) + '@babel/plugin-syntax-import-assertions': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-syntax-import-attributes': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-syntax-import-meta': 7.10.4(@babel/core@7.22.17) + '@babel/plugin-syntax-json-strings': 7.8.3(@babel/core@7.22.17) + '@babel/plugin-syntax-logical-assignment-operators': 7.10.4(@babel/core@7.22.17) + '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3(@babel/core@7.22.17) + '@babel/plugin-syntax-numeric-separator': 7.10.4(@babel/core@7.22.17) + '@babel/plugin-syntax-object-rest-spread': 7.8.3(@babel/core@7.22.17) + '@babel/plugin-syntax-optional-catch-binding': 7.8.3(@babel/core@7.22.17) + '@babel/plugin-syntax-optional-chaining': 7.8.3(@babel/core@7.22.17) + '@babel/plugin-syntax-private-property-in-object': 7.14.5(@babel/core@7.22.17) + '@babel/plugin-syntax-top-level-await': 7.14.5(@babel/core@7.22.17) + '@babel/plugin-syntax-unicode-sets-regex': 7.18.6(@babel/core@7.22.17) + '@babel/plugin-transform-arrow-functions': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-async-generator-functions': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-async-to-generator': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-block-scoped-functions': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-block-scoping': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-class-properties': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-class-static-block': 7.22.11(@babel/core@7.22.17) + '@babel/plugin-transform-classes': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-computed-properties': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-destructuring': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-dotall-regex': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-duplicate-keys': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-dynamic-import': 7.22.11(@babel/core@7.22.17) + '@babel/plugin-transform-exponentiation-operator': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-export-namespace-from': 7.22.11(@babel/core@7.22.17) + '@babel/plugin-transform-for-of': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-function-name': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-json-strings': 7.22.11(@babel/core@7.22.17) + '@babel/plugin-transform-literals': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-logical-assignment-operators': 7.22.11(@babel/core@7.22.17) + '@babel/plugin-transform-member-expression-literals': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-modules-amd': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-modules-commonjs': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-modules-systemjs': 7.22.11(@babel/core@7.22.17) + '@babel/plugin-transform-modules-umd': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-named-capturing-groups-regex': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-new-target': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-nullish-coalescing-operator': 7.22.11(@babel/core@7.22.17) + '@babel/plugin-transform-numeric-separator': 7.22.11(@babel/core@7.22.17) + '@babel/plugin-transform-object-rest-spread': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-object-super': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-optional-catch-binding': 7.22.11(@babel/core@7.22.17) + '@babel/plugin-transform-optional-chaining': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-parameters': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-private-methods': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-private-property-in-object': 7.22.11(@babel/core@7.22.17) + '@babel/plugin-transform-property-literals': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-regenerator': 7.22.10(@babel/core@7.22.17) + '@babel/plugin-transform-reserved-words': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-shorthand-properties': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-spread': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-sticky-regex': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-template-literals': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-typeof-symbol': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-unicode-escapes': 7.22.10(@babel/core@7.22.17) + '@babel/plugin-transform-unicode-property-regex': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-unicode-regex': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-unicode-sets-regex': 7.22.5(@babel/core@7.22.17) + '@babel/preset-modules': 0.1.6-no-external-plugins(@babel/core@7.22.17) + '@babel/types': 7.22.17 + babel-plugin-polyfill-corejs2: 0.4.5(@babel/core@7.22.17) + babel-plugin-polyfill-corejs3: 0.8.3(@babel/core@7.22.17) + babel-plugin-polyfill-regenerator: 0.5.2(@babel/core@7.22.17) + core-js-compat: 3.32.2 semver: 6.3.1 transitivePeerDependencies: - supports-color - /@babel/preset-flow@7.22.15(@babel/core@7.22.10): + /@babel/preset-flow@7.22.15(@babel/core@7.22.17): resolution: {integrity: sha512-dB5aIMqpkgbTfN5vDdTRPzjqtWiZcRESNR88QYnoPR+bmdYoluOzMX9tQerTv0XzSgZYctPfO1oc0N5zdog1ew==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 '@babel/helper-validator-option': 7.22.15 - '@babel/plugin-transform-flow-strip-types': 7.22.5(@babel/core@7.22.10) + '@babel/plugin-transform-flow-strip-types': 7.22.5(@babel/core@7.22.17) dev: false - /@babel/preset-modules@0.1.5(@babel/core@7.22.10): - resolution: {integrity: sha512-A57th6YRG7oR3cq/yt/Y84MvGgE0eJG2F1JLhKuyG+jFxEgrd/HAMJatiFtmOiZurz+0DkrvbheCLaV5f2JfjA==} + /@babel/preset-modules@0.1.6-no-external-plugins(@babel/core@7.22.17): + resolution: {integrity: sha512-HrcgcIESLm9aIR842yhJ5RWan/gebQUJ6E/E5+rf0y9o6oj7w0Br+sWuL6kEQ/o/AdfvR1Je9jG18/gnpwjEyA==} peerDependencies: - '@babel/core': ^7.0.0-0 + '@babel/core': ^7.0.0-0 || ^8.0.0-0 <8.0.0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-proposal-unicode-property-regex': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-transform-dotall-regex': 7.18.6(@babel/core@7.22.10) - '@babel/types': 7.22.11 + '@babel/types': 7.22.17 esutils: 2.0.3 - /@babel/preset-react@7.18.6(@babel/core@7.22.10): - resolution: {integrity: sha512-zXr6atUmyYdiWRVLOZahakYmOBHtWc2WGCkP8PYTgZi0iJXDY2CN180TdrIW4OGOAdLc7TifzDIvtx6izaRIzg==} + /@babel/preset-react@7.22.15(@babel/core@7.22.17): + resolution: {integrity: sha512-Csy1IJ2uEh/PecCBXXoZGAZBeCATTuePzCSB7dLYWS0vOEj6CNpjxIhW4duWwZodBNueH7QO14WbGn8YyeuN9w==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-validator-option': 7.22.5 - '@babel/plugin-transform-react-display-name': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-react-jsx': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-react-jsx-development': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-transform-react-pure-annotations': 7.18.6(@babel/core@7.22.10) + '@babel/helper-validator-option': 7.22.15 + '@babel/plugin-transform-react-display-name': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-react-jsx': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-react-jsx-development': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-react-pure-annotations': 7.22.5(@babel/core@7.22.17) dev: true - /@babel/preset-typescript@7.21.5(@babel/core@7.22.10): - resolution: {integrity: sha512-iqe3sETat5EOrORXiQ6rWfoOg2y68Cs75B9wNxdPW4kixJxh7aXQE1KPdWLDniC24T/6dSnguF33W9j/ZZQcmA==} + /@babel/preset-typescript@7.22.15(@babel/core@7.22.17): + resolution: {integrity: sha512-HblhNmh6yM+cU4VwbBRpxFhxsTdfS1zsvH9W+gEjD0ARV9+8B4sNfpI6GuhePti84nuvhiwKS539jKPFHskA9A==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-validator-option': 7.22.5 - '@babel/plugin-syntax-jsx': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-modules-commonjs': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-typescript': 7.22.10(@babel/core@7.22.10) + '@babel/helper-validator-option': 7.22.15 + '@babel/plugin-syntax-jsx': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-modules-commonjs': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-typescript': 7.22.15(@babel/core@7.22.17) - /@babel/register@7.22.15(@babel/core@7.22.10): + /@babel/register@7.22.15(@babel/core@7.22.17): resolution: {integrity: sha512-V3Q3EqoQdn65RCgTLwauZaTfd1ShhwPmbBv+1dkZV/HpCGMKVyn6oFcRlI7RaKqiDQjX2Qd3AuoEguBgdjIKlg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 clone-deep: 4.0.1 find-cache-dir: 2.1.0 make-dir: 2.1.0 @@ -1653,109 +1700,52 @@ packages: /@babel/regjsgen@0.8.0: resolution: {integrity: sha512-x/rqGMdzj+fWZvCOYForTghzbtqPDZ5gPwaoNGHdgDfF2QA/XZbCBp4Moo5scrkAMPhB7z26XM/AaHuIJdgauA==} - /@babel/runtime@7.19.0: - resolution: {integrity: sha512-eR8Lo9hnDS7tqkO7NsV+mKvCmv5boaXFSZ70DnfhcgiEne8hv9oCEd36Klw74EtizEqLsy4YnW8UWwpBVolHZA==} - engines: {node: '>=6.9.0'} - dependencies: - regenerator-runtime: 0.13.11 - dev: true - - /@babel/runtime@7.22.10: - resolution: {integrity: sha512-21t/fkKLMZI4pqP2wlmsQAWnYW1PDyKyyUV4vCi+B25ydmdaYTKXPwCj0BzSUnZf4seIiYvSA3jcZ3gdsMFkLQ==} - engines: {node: '>=6.9.0'} - dependencies: - regenerator-runtime: 0.14.0 - dev: true - - /@babel/runtime@7.22.11: - resolution: {integrity: sha512-ee7jVNlWN09+KftVOu9n7S8gQzD/Z6hN/I8VBRXW4P1+Xe7kJGXMwu8vds4aGIMHZnNbdpSWCfZZtinytpcAvA==} + /@babel/runtime@7.22.15: + resolution: {integrity: sha512-T0O+aa+4w0u06iNmapipJXMV4HoUir03hpx3/YqXXhu9xim3w+dVphjFWl1OH8NbZHw5Lbm9k45drDkgq2VNNA==} engines: {node: '>=6.9.0'} dependencies: regenerator-runtime: 0.14.0 - /@babel/template@7.22.5: - resolution: {integrity: sha512-X7yV7eiwAxdj9k94NEylvbVHLiVG1nvzCV2EAowhxLTwODV1jl9UzZ48leOC0sH7OnuHrIkllaBgneUykIcZaw==} + /@babel/template@7.22.15: + resolution: {integrity: sha512-QPErUVm4uyJa60rkI73qneDacvdvzxshT3kksGqlGWYdOTIUOwJ7RDUL8sGqslY1uXWSL6xMFKEXDS3ox2uF0w==} engines: {node: '>=6.9.0'} dependencies: '@babel/code-frame': 7.22.13 - '@babel/parser': 7.22.13 - '@babel/types': 7.22.11 - - /@babel/traverse@7.19.1: - resolution: {integrity: sha512-0j/ZfZMxKukDaag2PtOPDbwuELqIar6lLskVPPJDjXMXjfLb1Obo/1yjxIGqqAJrmfaTIY3z2wFLAQ7qSkLsuA==} - engines: {node: '>=6.9.0'} - dependencies: - '@babel/code-frame': 7.22.13 - '@babel/generator': 7.22.10 - '@babel/helper-environment-visitor': 7.22.5 - '@babel/helper-function-name': 7.22.5 - '@babel/helper-hoist-variables': 7.22.5 - '@babel/helper-split-export-declaration': 7.22.6 - '@babel/parser': 7.22.13 - '@babel/types': 7.22.15 - debug: 4.3.4 - globals: 11.12.0 - transitivePeerDependencies: - - supports-color - dev: true + '@babel/parser': 7.22.16 + '@babel/types': 7.22.17 - /@babel/traverse@7.22.10: - resolution: {integrity: sha512-Q/urqV4pRByiNNpb/f5OSv28ZlGJiFiiTh+GAHktbIrkPhPbl90+uW6SmpoLyZqutrg9AEaEf3Q/ZBRHBXgxig==} + /@babel/traverse@7.22.17: + resolution: {integrity: sha512-xK4Uwm0JnAMvxYZxOVecss85WxTEIbTa7bnGyf/+EgCL5Zt3U7htUpEOWv9detPlamGKuRzCqw74xVglDWpPdg==} engines: {node: '>=6.9.0'} dependencies: '@babel/code-frame': 7.22.13 - '@babel/generator': 7.22.10 + '@babel/generator': 7.22.15 '@babel/helper-environment-visitor': 7.22.5 '@babel/helper-function-name': 7.22.5 '@babel/helper-hoist-variables': 7.22.5 '@babel/helper-split-export-declaration': 7.22.6 - '@babel/parser': 7.22.13 - '@babel/types': 7.22.15 + '@babel/parser': 7.22.16 + '@babel/types': 7.22.17 debug: 4.3.4 globals: 11.12.0 transitivePeerDependencies: - supports-color - /@babel/types@7.19.0: - resolution: {integrity: sha512-YuGopBq3ke25BVSiS6fgF49Ul9gH1x70Bcr6bqRLjWCkcX8Hre1/5+z+IiWOIerRMSSEfGZVB9z9kyq7wVs9YA==} - engines: {node: '>=6.9.0'} - dependencies: - '@babel/helper-string-parser': 7.22.5 - '@babel/helper-validator-identifier': 7.22.15 - to-fast-properties: 2.0.0 - dev: true - - /@babel/types@7.22.10: - resolution: {integrity: sha512-obaoigiLrlDZ7TUQln/8m4mSqIW2QFeOrCQc9r+xsaHGNoplVNYlRVpsfE8Vj35GEm2ZH4ZhrNYogs/3fj85kg==} - engines: {node: '>=6.9.0'} - dependencies: - '@babel/helper-string-parser': 7.22.5 - '@babel/helper-validator-identifier': 7.22.15 - to-fast-properties: 2.0.0 - - /@babel/types@7.22.11: - resolution: {integrity: sha512-siazHiGuZRz9aB9NpHy9GOs9xiQPKnMzgdr493iI1M67vRXpnEq8ZOOKzezC5q7zwuQ6sDhdSp4SD9ixKSqKZg==} - engines: {node: '>=6.9.0'} - dependencies: - '@babel/helper-string-parser': 7.22.5 - '@babel/helper-validator-identifier': 7.22.15 - to-fast-properties: 2.0.0 - - /@babel/types@7.22.15: - resolution: {integrity: sha512-X+NLXr0N8XXmN5ZsaQdm9U2SSC3UbIYq/doL++sueHOTisgZHoKaQtZxGuV2cUPQHMfjKEfg/g6oy7Hm6SKFtA==} + /@babel/types@7.22.17: + resolution: {integrity: sha512-YSQPHLFtQNE5xN9tHuZnzu8vPr61wVTBZdfv1meex1NBosa4iT05k/Jw06ddJugi4bk7The/oSwQGFcksmEJQg==} engines: {node: '>=6.9.0'} dependencies: '@babel/helper-string-parser': 7.22.5 '@babel/helper-validator-identifier': 7.22.15 to-fast-properties: 2.0.0 - /@commitlint/parse@17.6.5: - resolution: {integrity: sha512-0zle3bcn1Hevw5Jqpz/FzEWNo2KIzUbc1XyGg6WrWEoa6GH3A1pbqNF6MvE6rjuy6OY23c8stWnb4ETRZyN+Yw==} + /@commitlint/parse@17.7.0: + resolution: {integrity: sha512-dIvFNUMCUHqq5Abv80mIEjLVfw8QNuA4DS7OWip4pcK/3h5wggmjVnlwGCDvDChkw2TjK1K6O+tAEV78oxjxag==} engines: {node: '>=v14'} dependencies: '@commitlint/types': 17.4.4 - conventional-changelog-angular: 5.0.13 - conventional-commits-parser: 3.2.4 + conventional-changelog-angular: 6.0.0 + conventional-commits-parser: 4.0.0 dev: true /@commitlint/types@17.4.4: @@ -1970,13 +1960,13 @@ packages: dev: true optional: true - /@eslint-community/eslint-utils@4.4.0(eslint@8.48.0): + /@eslint-community/eslint-utils@4.4.0(eslint@8.49.0): resolution: {integrity: sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: eslint: ^6.0.0 || ^7.0.0 || >=8.0.0 dependencies: - eslint: 8.48.0 + eslint: 8.49.0 eslint-visitor-keys: 3.4.3 dev: true @@ -2002,8 +1992,8 @@ packages: - supports-color dev: true - /@eslint/js@8.48.0: - resolution: {integrity: sha512-ZSjtmelB7IJfWD2Fvb7+Z+ChTIKWq6kjda95fLcQKNS5aheVHn4IkfgRQE3sIIzTcSLwLcLZUD9UBt+V7+h+Pw==} + /@eslint/js@8.49.0: + resolution: {integrity: sha512-1S8uAY/MTJqVx0SC4epBq+N2yhuwtNwLbJYNZyhL2pO1ZVKn5HFXav5T41Ryzy9K9V7ZId2JB2oy/W4aCd9/2w==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dev: true @@ -2017,8 +2007,8 @@ packages: '@hapi/hoek': 9.3.0 dev: false - /@humanwhocodes/config-array@0.11.10: - resolution: {integrity: sha512-KVVjQmNUepDVGXNuoRRdmmEjruj0KfiGSbS8LVc12LMsWDQzRXJ0qdhN8L8uUigKpfEHRhlaQFY0ib1tnUbNeQ==} + /@humanwhocodes/config-array@0.11.11: + resolution: {integrity: sha512-N2brEuAadi0CcdeMXUkhbZB84eskAc8MEX1By6qEchoVywSgXPIjou4rYsl0V3Hj0ZnuGycGCjdNgockbzeWNA==} engines: {node: '>=10.10.0'} dependencies: '@humanwhocodes/object-schema': 1.2.1 @@ -2104,7 +2094,7 @@ packages: resolution: {integrity: sha512-ipON6WtYgl/1329g5AIJVbUuEh0wZVbdpGwC99Jw4LwuoBNS95MVphU6zOeD9pDkon+LLbFL7lOQRapbB8SCHw==} engines: {node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0} dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@jest/types': 27.5.1 babel-plugin-istanbul: 6.1.1 chalk: 4.1.2 @@ -2194,8 +2184,8 @@ packages: '@jridgewell/sourcemap-codec': 1.4.15 dev: true - /@mdn/browser-compat-data@5.3.9: - resolution: {integrity: sha512-J7lLtHMEizYbI5T0Xlqpg1JXCz9JegZBeb7y3v/Nm8ScRw8TL9v3n+I3g1TFm+bLrRtwA33FKwX5znDwz+WzAQ==} + /@mdn/browser-compat-data@5.3.15: + resolution: {integrity: sha512-h/luqw9oAmMF1C/GuUY/PAgZlF4wx71q2bdH+ct8vmjcvseCY32au8XmYy7xZ8l5VJiY/3ltFpr5YiO55v0mzg==} dev: true /@nodelib/fs.scandir@2.1.5: @@ -2219,19 +2209,19 @@ packages: fastq: 1.15.0 dev: true - /@nrwl/nx-cloud@16.3.0: - resolution: {integrity: sha512-nJrGsVufhY74KcP7kM7BqFOGAoO5OEF6+wfiM295DgmEG9c1yW+x5QiQaC42K9SWYn/eKQa1X7466ZA5lynXoQ==} + /@nrwl/nx-cloud@16.4.0: + resolution: {integrity: sha512-QitrYK6z9ceagetBlgLMZnC0T85k2JTk+oK0MxZ5p/woclqeYN7SiGNZgMzDq8TjJwt8Fm/MDnsSo3xtufmLBg==} dependencies: - nx-cloud: 16.3.0 + nx-cloud: 16.4.0 transitivePeerDependencies: - debug dev: true - /@nrwl/tao@16.7.4: - resolution: {integrity: sha512-hH03oF+yVmaf19UZfyLDSuVEh0KasU5YfYezuNsdRkXNdTU/WmpDrk4qoo0j6fVoMPrqbbPOn1YMRtulP2WyYA==} + /@nrwl/tao@16.8.1: + resolution: {integrity: sha512-hgGFLyEgONSofxnJsXN9NlUx4J8/YSLUkfZKdR8Qa97+JGZT8FEuk7NLFJOWdYYqROoCzXLHK0d+twFFNPS5BQ==} hasBin: true dependencies: - nx: 16.7.4 + nx: 16.8.1 tslib: 2.6.2 transitivePeerDependencies: - '@swc-node/register' @@ -2239,8 +2229,8 @@ packages: - debug dev: true - /@nx/nx-darwin-arm64@16.7.4: - resolution: {integrity: sha512-pRNjxn6KlcR6iGkU1j/1pzcogwXFv97pYiZaibpF7UV0vfdEUA3EETpDcs+hbNAcKMvVtn/TgN857/5LQ/lGUg==} + /@nx/nx-darwin-arm64@16.8.1: + resolution: {integrity: sha512-xOflqyIVcyLPzdJOZcucI+5ClwnTgK8zIvpjbxHokrO9McJJglhfUyP0bbTHpEpWqzA+GaPA/6/Qdu0ATzqQBQ==} engines: {node: '>= 10'} cpu: [arm64] os: [darwin] @@ -2248,8 +2238,8 @@ packages: dev: true optional: true - /@nx/nx-darwin-x64@16.7.4: - resolution: {integrity: sha512-GANXeabAAWRoF85WDla2ZPxtr8vnqvXjwyCIhRCda8hlKiVCpM98GemucN25z97G5H6MgyV9Dd9t9jrr2Fn0Og==} + /@nx/nx-darwin-x64@16.8.1: + resolution: {integrity: sha512-JJGrlOvEpDMWnM6YKaA1WOnzHgiw5vRKEowX9ba+jxhmCvtdjbLSxi228kv92JtQPPQ91zvtsNM+BFY0EbPOlA==} engines: {node: '>= 10'} cpu: [x64] os: [darwin] @@ -2257,8 +2247,8 @@ packages: dev: true optional: true - /@nx/nx-freebsd-x64@16.7.4: - resolution: {integrity: sha512-zmBBDYjPaHhIHx1YASUJJIy+oz7mCrj5f0f3kOzfMraQOjkQZ0xYgNNUzBqmnYu1855yiphu94MkAMYJnbk0jw==} + /@nx/nx-freebsd-x64@16.8.1: + resolution: {integrity: sha512-aZdJQ7cIQfXOmfk4vRXvVYxuV68xz8YyhNZ0IvBfJ16uZQ+YNl4BpklRLEIdaloSbwz9M1NNewmL+AgklEBxlA==} engines: {node: '>= 10'} cpu: [x64] os: [freebsd] @@ -2266,8 +2256,8 @@ packages: dev: true optional: true - /@nx/nx-linux-arm-gnueabihf@16.7.4: - resolution: {integrity: sha512-d3Cmz/vdtoSasTUANoh4ZYLJESNA3+PCP/HnXNqmrr6AEHo+T8DcI+qsamO3rmYUSFxTMAeMyoihZMU8OKGZ1A==} + /@nx/nx-linux-arm-gnueabihf@16.8.1: + resolution: {integrity: sha512-JzjrTf7FFgikoVUbRs0hKvwHRR6SyqT4yIdk/YyiCt2mWY9w4m5DWtHM/9kJzhckkH9MY66m+X/zG6+NKsEMvg==} engines: {node: '>= 10'} cpu: [arm] os: [linux] @@ -2275,8 +2265,8 @@ packages: dev: true optional: true - /@nx/nx-linux-arm64-gnu@16.7.4: - resolution: {integrity: sha512-W1u4O78lTHCwvUP0vakeKWFXeSZ13nYzbd6FARICnImY2my8vz41rLm6aU9TYWaiOGEGL2xKpHKSgiNwbLjhFw==} + /@nx/nx-linux-arm64-gnu@16.8.1: + resolution: {integrity: sha512-CF0s981myBWusW7iW2+fKPa7ceYYe+NO5EdKe9l27fpHDkcA71KZU3q7U823QpO/7tYvVdBevJp3CCn2/GBURQ==} engines: {node: '>= 10'} cpu: [arm64] os: [linux] @@ -2284,8 +2274,8 @@ packages: dev: true optional: true - /@nx/nx-linux-arm64-musl@16.7.4: - resolution: {integrity: sha512-Dc8IQFvhfH/Z3GmhBBNNxGd2Ehw6Y5SePEgJj1c2JyPdoVtc2OjGzkUaZkT4z5z77VKtju6Yi10T6Enps+y+kw==} + /@nx/nx-linux-arm64-musl@16.8.1: + resolution: {integrity: sha512-X4TobxRt1dALvoeKC3/t1CqZCMUqtEhGG+KQLT/51sG54HdxmTAWRFlvj8PvLH0QSBk4e+uRZAo45qpt3iSnBg==} engines: {node: '>= 10'} cpu: [arm64] os: [linux] @@ -2293,8 +2283,8 @@ packages: dev: true optional: true - /@nx/nx-linux-x64-gnu@16.7.4: - resolution: {integrity: sha512-4B58C/pXeuovSznBOeicsxNieBApbGMoi2du8jR6Is1gYFPv4l8fFHQHHGAa1l5XJC5JuGJqFywS4elInWprNw==} + /@nx/nx-linux-x64-gnu@16.8.1: + resolution: {integrity: sha512-lHvv2FD14Lpxh7muMLStH2tC1opQOaepO4nXwb1LaaoIpMym7kBgCK8AQuI98/oNQiMDXMNDKWQZCjxnJGDIPw==} engines: {node: '>= 10'} cpu: [x64] os: [linux] @@ -2302,8 +2292,8 @@ packages: dev: true optional: true - /@nx/nx-linux-x64-musl@16.7.4: - resolution: {integrity: sha512-spqqvEdGSSeV2ByJHkex5m8MRQfM6lQlnon25XgVBdPR47lKMWSikUsaWCiE7bVAFU9BFyWY2L4HfZ4+LiNY7A==} + /@nx/nx-linux-x64-musl@16.8.1: + resolution: {integrity: sha512-c4gQvNgIjggD1A5sYhftQEC1PtAhV3sEnv60X00v9wmjl57Wj4Ty0TgyzpYglLysVRiko/B58S8NYS0jKvMmeA==} engines: {node: '>= 10'} cpu: [x64] os: [linux] @@ -2311,8 +2301,8 @@ packages: dev: true optional: true - /@nx/nx-win32-arm64-msvc@16.7.4: - resolution: {integrity: sha512-etNnbuCcSqAYOeDcS6si6qw0WR/IS87ovTzLS17ETKpdHcHN5nM4l02CQyupKiD58ShxrXHxXmvgBfbXxoN5Ew==} + /@nx/nx-win32-arm64-msvc@16.8.1: + resolution: {integrity: sha512-GKHPy/MyGFoV9cdKgcWLZZK2vDdxt5bQ53ss0k+BDKRP+YwLKm7tJl23eeM7JdB4GLCBntEQPC+dBqxOA8Ze/w==} engines: {node: '>= 10'} cpu: [arm64] os: [win32] @@ -2320,8 +2310,8 @@ packages: dev: true optional: true - /@nx/nx-win32-x64-msvc@16.7.4: - resolution: {integrity: sha512-y6pugK6ino1wvo2FbgtXG2cVbEm3LzJwOSBKBRBXSWhUgjP7T92uGfOt6KVQKpaqDvS9lA9TO/2DcygcLHXh7A==} + /@nx/nx-win32-x64-msvc@16.8.1: + resolution: {integrity: sha512-yHZ5FAcx54rVc31R0yIpniepkHMPwaxG23l8E/ZYbL1iPwE/Wc1HeUzUvxUuSXtguRp7ihcRhaUEPkcSl2EAVw==} engines: {node: '>= 10'} cpu: [x64] os: [win32] @@ -2401,7 +2391,7 @@ packages: strip-ansi: 5.2.0 sudo-prompt: 9.2.1 wcwidth: 1.0.1 - yaml: 2.3.1 + yaml: 2.3.2 transitivePeerDependencies: - encoding dev: false @@ -2443,7 +2433,7 @@ packages: - encoding dev: false - /@react-native-community/cli-plugin-metro@11.3.6(@babel/core@7.22.10): + /@react-native-community/cli-plugin-metro@11.3.6(@babel/core@7.22.17): resolution: {integrity: sha512-D97racrPX3069ibyabJNKw9aJpVcaZrkYiEzsEnx50uauQtPDoQ1ELb/5c6CtMhAEGKoZ0B5MS23BbsSZcLs2g==} dependencies: '@react-native-community/cli-server-api': 11.3.6 @@ -2453,7 +2443,7 @@ packages: metro: 0.76.7 metro-config: 0.76.7 metro-core: 0.76.7 - metro-react-native-babel-transformer: 0.76.7(@babel/core@7.22.10) + metro-react-native-babel-transformer: 0.76.7(@babel/core@7.22.17) metro-resolver: 0.76.7 metro-runtime: 0.76.7 readline: 1.3.0 @@ -2506,7 +2496,7 @@ packages: joi: 17.10.1 dev: false - /@react-native-community/cli@11.3.6(@babel/core@7.22.10): + /@react-native-community/cli@11.3.6(@babel/core@7.22.17): resolution: {integrity: sha512-bdwOIYTBVQ9VK34dsf6t3u6vOUU5lfdhKaAxiAVArjsr7Je88Bgs4sAbsOYsNK3tkE8G77U6wLpekknXcanlww==} engines: {node: '>=16'} hasBin: true @@ -2516,7 +2506,7 @@ packages: '@react-native-community/cli-debugger-ui': 11.3.6 '@react-native-community/cli-doctor': 11.3.6 '@react-native-community/cli-hermes': 11.3.6 - '@react-native-community/cli-plugin-metro': 11.3.6(@babel/core@7.22.10) + '@react-native-community/cli-plugin-metro': 11.3.6(@babel/core@7.22.17) '@react-native-community/cli-server-api': 11.3.6 '@react-native-community/cli-tools': 11.3.6 '@react-native-community/cli-types': 11.3.6 @@ -2540,15 +2530,15 @@ packages: resolution: {integrity: sha512-Im93xRJuHHxb1wniGhBMsxLwcfzdYreSZVQGDoMJgkd6+Iky61LInGEHnQCTN0fKNYF1Dvcofb4uMmE1RQHXHQ==} dev: false - /@react-native/codegen@0.72.6(@babel/preset-env@7.21.5): + /@react-native/codegen@0.72.6(@babel/preset-env@7.22.15): resolution: {integrity: sha512-idTVI1es/oopN0jJT/0jB6nKdvTUKE3757zA5+NPXZTeB46CIRbmmos4XBiAec8ufu9/DigLPbHTYAaMNZJ6Ig==} peerDependencies: '@babel/preset-env': ^7.1.6 dependencies: - '@babel/parser': 7.22.13 - '@babel/preset-env': 7.21.5(@babel/core@7.22.10) + '@babel/parser': 7.22.16 + '@babel/preset-env': 7.22.15(@babel/core@7.22.17) flow-parser: 0.206.0 - jscodeshift: 0.14.0(@babel/preset-env@7.21.5) + jscodeshift: 0.14.0(@babel/preset-env@7.22.15) nullthrows: 1.1.1 transitivePeerDependencies: - supports-color @@ -2573,10 +2563,10 @@ packages: dependencies: invariant: 2.2.4 nullthrows: 1.1.1 - react-native: 0.72.4(@babel/core@7.22.10)(@babel/preset-env@7.21.5)(react@18.2.0) + react-native: 0.72.4(@babel/core@7.22.17)(@babel/preset-env@7.22.15)(react@18.2.0) dev: false - /@rollup/plugin-babel@6.0.3(@babel/core@7.22.10): + /@rollup/plugin-babel@6.0.3(@babel/core@7.22.17): resolution: {integrity: sha512-fKImZKppa1A/gX73eg4JGo+8kQr/q1HBQaCGKECZ0v4YBBv3lFqi14+7xyApECzvkLTHCifx+7ntcrvtBIRcpg==} engines: {node: '>=14.0.0'} peerDependencies: @@ -2589,13 +2579,13 @@ packages: rollup: optional: true dependencies: - '@babel/core': 7.22.10 - '@babel/helper-module-imports': 7.22.5 - '@rollup/pluginutils': 5.0.3 + '@babel/core': 7.22.17 + '@babel/helper-module-imports': 7.22.15 + '@rollup/pluginutils': 5.0.4 dev: true - /@rollup/plugin-commonjs@25.0.0: - resolution: {integrity: sha512-hoho2Kay9TZrLu0bnDsTTCaj4Npa+THk9snajP/XDNb9a9mmjTjh52EQM9sKl3HD1LsnihX7js+eA2sd2uKAhw==} + /@rollup/plugin-commonjs@25.0.4: + resolution: {integrity: sha512-L92Vz9WUZXDnlQQl3EwbypJR4+DM2EbsO+/KOcEkP4Mc6Ct453EeDB2uH9lgRwj4w5yflgNpq9pHOiY8aoUXBQ==} engines: {node: '>=14.0.0'} peerDependencies: rollup: ^2.68.0||^3.0.0 @@ -2603,7 +2593,7 @@ packages: rollup: optional: true dependencies: - '@rollup/pluginutils': 5.0.3 + '@rollup/pluginutils': 5.0.4 commondir: 1.0.1 estree-walker: 2.0.2 glob: 8.1.0 @@ -2611,8 +2601,8 @@ packages: magic-string: 0.27.0 dev: true - /@rollup/plugin-node-resolve@15.0.2: - resolution: {integrity: sha512-Y35fRGUjC3FaurG722uhUuG8YHOJRJQbI6/CkbRkdPotSpDj9NtIN85z1zrcyDcCQIW4qp5mgG72U+gJ0TAFEg==} + /@rollup/plugin-node-resolve@15.2.1: + resolution: {integrity: sha512-nsbUg588+GDSu8/NS8T4UAshO6xeaOfINNuXeVHcKV02LJtoRaM1SiOacClw4kws1SFiNhdLGxlbMY9ga/zs/w==} engines: {node: '>=14.0.0'} peerDependencies: rollup: ^2.78.0||^3.0.0 @@ -2620,7 +2610,7 @@ packages: rollup: optional: true dependencies: - '@rollup/pluginutils': 5.0.3 + '@rollup/pluginutils': 5.0.4 '@types/resolve': 1.20.2 deepmerge: 4.3.1 is-builtin-module: 3.2.1 @@ -2637,12 +2627,12 @@ packages: rollup: optional: true dependencies: - '@rollup/pluginutils': 5.0.3 + '@rollup/pluginutils': 5.0.4 magic-string: 0.27.0 dev: true - /@rollup/pluginutils@5.0.3: - resolution: {integrity: sha512-hfllNN4a80rwNQ9QCxhxuHCGHMAvabXqxNdaChUSSadMre7t4iEUI6fFAhBOn/eIYTgYVhBv7vCLsAJ4u3lf3g==} + /@rollup/pluginutils@5.0.4: + resolution: {integrity: sha512-0KJnIoRI8A+a1dqOYLxH8vBf8bphDmty5QvIm2hqm7oFCFYKCAZWWd2hXgMibaPsNDhI0AtpYfQZJG47pt/k4g==} engines: {node: '>=14.0.0'} peerDependencies: rollup: ^1.20.0||^2.0.0||^3.0.0 @@ -2720,7 +2710,7 @@ packages: engines: {node: '>=14'} dependencies: '@babel/code-frame': 7.22.13 - '@babel/runtime': 7.22.11 + '@babel/runtime': 7.22.15 '@types/aria-query': 5.0.1 aria-query: 5.1.3 chalk: 4.1.2 @@ -2729,12 +2719,12 @@ packages: pretty-format: 27.5.1 dev: true - /@testing-library/jest-dom@5.16.5: - resolution: {integrity: sha512-N5ixQ2qKpi5OLYfwQmUb/5mSV9LneAcaUfp32pn4yCnpb8r/Yz0pXFPck21dIicKmi+ta5WRAknkZCfA8refMA==} + /@testing-library/jest-dom@5.17.0: + resolution: {integrity: sha512-ynmNeT7asXyH3aSVv4vvX4Rb+0qjOhdNHnO/3vuZNqPmhDpV/+rCSGwQ7bLcmU2cJ4dvoheIO85LQj0IbJHEtg==} engines: {node: '>=8', npm: '>=6', yarn: '>=1'} dependencies: - '@adobe/css-tools': 4.3.0 - '@babel/runtime': 7.22.10 + '@adobe/css-tools': 4.3.1 + '@babel/runtime': 7.22.15 '@types/testing-library__jest-dom': 5.14.5(patch_hash=d573maxasnl5kxwdyzebcnmhpm) aria-query: 5.3.0 chalk: 3.0.0 @@ -2744,7 +2734,7 @@ packages: redent: 3.0.0 dev: true - /@testing-library/react-hooks@8.0.1(@types/react@18.0.15)(react-dom@18.2.0)(react@18.2.0): + /@testing-library/react-hooks@8.0.1(@types/react@18.2.21)(react-dom@18.2.0)(react@18.2.0): resolution: {integrity: sha512-Aqhl2IVmLt8IovEVarNDFuJDVWVvhnr9/GCU6UUnrYXwgDFF9h2L2o2P9KBni1AST5sT6riAyoukFLyjQUgD/g==} engines: {node: '>=12'} peerDependencies: @@ -2760,8 +2750,8 @@ packages: react-test-renderer: optional: true dependencies: - '@babel/runtime': 7.22.10 - '@types/react': 18.0.15 + '@babel/runtime': 7.22.15 + '@types/react': 18.2.21 react: 18.2.0 react-dom: 18.2.0(react@18.2.0) react-error-boundary: 3.1.4(react@18.2.0) @@ -2774,9 +2764,9 @@ packages: react: ^18.0.0 react-dom: ^18.0.0 dependencies: - '@babel/runtime': 7.22.10 + '@babel/runtime': 7.22.15 '@testing-library/dom': 9.3.1 - '@types/react-dom': 18.0.6 + '@types/react-dom': 18.2.7 react: 18.2.0 react-dom: 18.2.0(react@18.2.0) dev: true @@ -2797,7 +2787,7 @@ packages: '@vue/compiler-sfc': '>= 3' vue: '>= 3' dependencies: - '@babel/runtime': 7.22.11 + '@babel/runtime': 7.22.15 '@testing-library/dom': 9.3.1 '@vue/compiler-sfc': 3.3.4 '@vue/test-utils': 2.4.1(vue@3.3.4) @@ -2831,43 +2821,43 @@ packages: resolution: {integrity: sha512-XTIieEY+gvJ39ChLcB4If5zHtPxt3Syj5rgZR+e1ctpmK8NjPf0zFqsz4JpLJT0xla9GFDKjy8Cpu331nrmE1Q==} dev: true - /@types/babel__core@7.1.19: - resolution: {integrity: sha512-WEOTgRsbYkvA/KCsDwVEGkd7WAr1e3g31VHQ8zy5gul/V1qKullU/BU5I68X5v7V3GnB9eotmom4v5a5gjxorw==} + /@types/babel__core@7.20.1: + resolution: {integrity: sha512-aACu/U/omhdk15O4Nfb+fHgH/z3QsfQzpnvRZhYhThms83ZnAOZz7zZAWO7mn2yyNQaA4xTO8GLK3uqFU4bYYw==} dependencies: - '@babel/parser': 7.22.13 - '@babel/types': 7.22.15 + '@babel/parser': 7.22.16 + '@babel/types': 7.22.17 '@types/babel__generator': 7.6.4 '@types/babel__template': 7.4.1 - '@types/babel__traverse': 7.17.1 + '@types/babel__traverse': 7.20.1 dev: true /@types/babel__generator@7.6.4: resolution: {integrity: sha512-tFkciB9j2K755yrTALxD44McOrk+gfpIpvC3sxHjRawj6PfnQxrse4Clq5y/Rq+G3mrBurMax/lG8Qn2t9mSsg==} dependencies: - '@babel/types': 7.22.15 + '@babel/types': 7.22.17 dev: true /@types/babel__template@7.4.1: resolution: {integrity: sha512-azBFKemX6kMg5Io+/rdGT0dkGreboUVR0Cdm3fz9QJWpaQGJRQXl7C+6hOTCZcMll7KFyEQpgbYI2lHdsS4U7g==} dependencies: - '@babel/parser': 7.22.13 - '@babel/types': 7.22.15 + '@babel/parser': 7.22.16 + '@babel/types': 7.22.17 dev: true - /@types/babel__traverse@7.17.1: - resolution: {integrity: sha512-kVzjari1s2YVi77D3w1yuvohV2idweYXMCDzqBiVNN63TcDWrIlTVOYpqVrvbbyOE/IyzBoTKF0fdnLPEORFxA==} + /@types/babel__traverse@7.20.1: + resolution: {integrity: sha512-MitHFXnhtgwsGZWtT68URpOvLN4EREih1u3QtQiN4VdAxWKRVvGCSvw/Qth0M0Qq3pJpnGOu5JaM/ydK7OGbqg==} dependencies: - '@babel/types': 7.22.15 + '@babel/types': 7.22.17 dev: true /@types/chai-subset@1.3.3: resolution: {integrity: sha512-frBecisrNGz+F4T6bcc+NLeolfiojh5FxW2klu669+8BARtyQv2C/GkNW6FUodVe4BroGMP/wER/YDGc7rEllw==} dependencies: - '@types/chai': 4.3.5 + '@types/chai': 4.3.6 dev: true - /@types/chai@4.3.5: - resolution: {integrity: sha512-mEo1sAde+UCE6b2hxn332f1g1E8WfYRu6p5SvTKr2ZKC1f7gFJXk4h5PyGP9Dt6gCaG8y8XhwnXWC6Iy2cmBng==} + /@types/chai@4.3.6: + resolution: {integrity: sha512-VOVRLM1mBxIRxydiViqPcKn6MIxZytrbMpd6RJLIWKxUNr3zux8no0Oc7kJx0WAPIitgZ0gkrDS+btlqQpubpw==} dev: true /@types/current-git-branch@1.1.4: @@ -2904,8 +2894,8 @@ packages: pretty-format: 26.6.2 dev: true - /@types/jscodeshift@0.11.5: - resolution: {integrity: sha512-7JV0qdblTeWFigevmwFUgROXX395F+MQx6v0YqPn8Bx0B4Sng6alEejz9PENzgLYpG+zL0O4tGdBzc4gKZH8XA==} + /@types/jscodeshift@0.11.6: + resolution: {integrity: sha512-3lJ4DajWkk4MZ1F7q+1C7jE0z0xOtbu0VU/Kg3wdPq2DUvJjySSlu3B5Q/bICrTxugLhONBO7inRUWsymOID/A==} dependencies: ast-types: 0.14.2 recast: 0.20.5 @@ -2925,8 +2915,8 @@ packages: '@types/node': 17.0.45 dev: true - /@types/luxon@2.3.2: - resolution: {integrity: sha512-WOehptuhKIXukSUUkRgGbj2c997Uv/iUgYgII8U7XLJqq9W2oF0kQ6frEznRQbdurioz+L/cdaIm4GutTQfgmA==} + /@types/luxon@2.4.0: + resolution: {integrity: sha512-oCavjEjRXuR6URJEtQm0eBdfsBiEcGBZbq21of8iGkeKxU1+1xgKuFPClaBZl2KB8ZZBSWlgk61tH6Mf+nvZVw==} dev: true /@types/minimist@1.2.2: @@ -2943,32 +2933,28 @@ packages: /@types/prop-types@15.7.5: resolution: {integrity: sha512-JCB8C6SnDoQf0cNycqd/35A7MjcnK+ZTqE7judS6o7utxUCg6imJg3QK2qzHKszlTjcj2cn+NwMB2i96ubpj7w==} - /@types/react-dom@18.0.6: - resolution: {integrity: sha512-/5OFZgfIPSwy+YuIBP/FgJnQnsxhZhjjrnxudMddeblOouIodEQ75X14Rr4wGSG/bknL+Omy9iWlLo1u/9GzAA==} + /@types/react-dom@18.2.7: + resolution: {integrity: sha512-GRaAEriuT4zp9N4p1i8BDBYmEyfo+xQ3yHjJU4eiK5NDa1RmUZG+unZABUTK4/Ox/M+GaHwb6Ow8rUITrtjszA==} dependencies: - '@types/react': 18.0.15 + '@types/react': 18.2.21 dev: true - /@types/react@18.0.15: - resolution: {integrity: sha512-iz3BtLuIYH1uWdsv6wXYdhozhqj20oD4/Hk2DNXIn1kFsmp9x8d9QB6FnPhfkbhd2PgEONt9Q1x/ebkwjfFLow==} + /@types/react@18.2.21: + resolution: {integrity: sha512-neFKG/sBAwGxHgXiIxnbm3/AAVQ/cMRS93hvBpg8xYRbeQSPVABp9U2bRnPf0iI4+Ucdv3plSxKK+3CW2ENJxA==} dependencies: '@types/prop-types': 15.7.5 - '@types/scheduler': 0.16.2 - csstype: 3.1.0 + '@types/scheduler': 0.16.3 + csstype: 3.1.2 /@types/resolve@1.20.2: resolution: {integrity: sha512-60BCwRFOZCQhDncwQdxxeOEEkbc5dIMccYLwbxsS4TUNeVECQ/pBJ0j09mrHOl/JJvpRPGwO9SvE4nR2Nb/a4Q==} dev: true - /@types/scheduler@0.16.2: - resolution: {integrity: sha512-hppQEBDmlwhFAXKJX2KnWLYu5yMfi91yazPb2l+lbJiwW+wdo1gNeRA+3RgNSO39WYX2euey41KEwnqesU2Jew==} - - /@types/semver@7.3.13: - resolution: {integrity: sha512-21cFJr9z3g5dW8B0CVI9g2O9beqaThGQ6ZFBqHfwhzLDKUxaqTIy3vnfah/UPkfOiF2pLq+tGz+W8RyCskuslw==} - dev: true + /@types/scheduler@0.16.3: + resolution: {integrity: sha512-5cJ8CB4yAx7BH1oMvdU0Jh9lrEXyPkar6F9G/ERswkCuvP4KQZfZkSjcMbAICCpQTN4OuZn8tz0HiKv9TGZgrQ==} - /@types/semver@7.5.0: - resolution: {integrity: sha512-G8hZ6XJiHnuhQKR7ZmysCeJWE08o8T0AXtk5darsCaTVsYZhhgUrq53jizaR2FvsoeCwJhlmwTjkXBY5Pn/ZHw==} + /@types/semver@7.5.1: + resolution: {integrity: sha512-cJRQXpObxfNKkFAZbJl2yjWtJCqELQIdShsogr1d2MilP8dKD9TE/nEKHkJgUNHdGKCQaf9HbIynuV2csLGVLg==} dev: true /@types/stack-utils@2.0.1: @@ -3011,8 +2997,8 @@ packages: '@types/yargs-parser': 21.0.0 dev: false - /@typescript-eslint/eslint-plugin@6.4.1(@typescript-eslint/parser@6.4.1)(eslint@8.48.0)(typescript@5.2.2): - resolution: {integrity: sha512-3F5PtBzUW0dYlq77Lcqo13fv+58KDwUib3BddilE8ajPJT+faGgxmI9Sw+I8ZS22BYwoir9ZhNXcLi+S+I2bkw==} + /@typescript-eslint/eslint-plugin@6.6.0(@typescript-eslint/parser@6.6.0)(eslint@8.49.0)(typescript@5.2.2): + resolution: {integrity: sha512-CW9YDGTQnNYMIo5lMeuiIG08p4E0cXrXTbcZ2saT/ETE7dWUrNxlijsQeU04qAAKkILiLzdQz+cGFxCJjaZUmA==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: '@typescript-eslint/parser': ^6.0.0 || ^6.0.0-alpha @@ -3023,25 +3009,25 @@ packages: optional: true dependencies: '@eslint-community/regexpp': 4.8.0 - '@typescript-eslint/parser': 6.4.1(eslint@8.48.0)(typescript@5.2.2) - '@typescript-eslint/scope-manager': 6.4.1 - '@typescript-eslint/type-utils': 6.4.1(eslint@8.48.0)(typescript@5.2.2) - '@typescript-eslint/utils': 6.4.1(eslint@8.48.0)(typescript@5.2.2) - '@typescript-eslint/visitor-keys': 6.4.1 + '@typescript-eslint/parser': 6.6.0(eslint@8.49.0)(typescript@5.2.2) + '@typescript-eslint/scope-manager': 6.6.0 + '@typescript-eslint/type-utils': 6.6.0(eslint@8.49.0)(typescript@5.2.2) + '@typescript-eslint/utils': 6.6.0(eslint@8.49.0)(typescript@5.2.2) + '@typescript-eslint/visitor-keys': 6.6.0 debug: 4.3.4 - eslint: 8.48.0 + eslint: 8.49.0 graphemer: 1.4.0 ignore: 5.2.4 natural-compare: 1.4.0 semver: 7.5.4 - ts-api-utils: 1.0.2(typescript@5.2.2) + ts-api-utils: 1.0.3(typescript@5.2.2) typescript: 5.2.2 transitivePeerDependencies: - supports-color dev: true - /@typescript-eslint/parser@6.4.1(eslint@8.48.0)(typescript@5.2.2): - resolution: {integrity: sha512-610G6KHymg9V7EqOaNBMtD1GgpAmGROsmfHJPXNLCU9bfIuLrkdOygltK784F6Crboyd5tBFayPB7Sf0McrQwg==} + /@typescript-eslint/parser@6.6.0(eslint@8.49.0)(typescript@5.2.2): + resolution: {integrity: sha512-setq5aJgUwtzGrhW177/i+DMLqBaJbdwGj2CPIVFFLE0NCliy5ujIdLHd2D1ysmlmsjdL2GWW+hR85neEfc12w==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: eslint: ^7.0.0 || ^8.0.0 @@ -3050,27 +3036,27 @@ packages: typescript: optional: true dependencies: - '@typescript-eslint/scope-manager': 6.4.1 - '@typescript-eslint/types': 6.4.1 - '@typescript-eslint/typescript-estree': 6.4.1(typescript@5.2.2) - '@typescript-eslint/visitor-keys': 6.4.1 + '@typescript-eslint/scope-manager': 6.6.0 + '@typescript-eslint/types': 6.6.0 + '@typescript-eslint/typescript-estree': 6.6.0(typescript@5.2.2) + '@typescript-eslint/visitor-keys': 6.6.0 debug: 4.3.4 - eslint: 8.48.0 + eslint: 8.49.0 typescript: 5.2.2 transitivePeerDependencies: - supports-color dev: true - /@typescript-eslint/scope-manager@6.4.1: - resolution: {integrity: sha512-p/OavqOQfm4/Hdrr7kvacOSFjwQ2rrDVJRPxt/o0TOWdFnjJptnjnZ+sYDR7fi4OimvIuKp+2LCkc+rt9fIW+A==} + /@typescript-eslint/scope-manager@6.6.0: + resolution: {integrity: sha512-pT08u5W/GT4KjPUmEtc2kSYvrH8x89cVzkA0Sy2aaOUIw6YxOIjA8ilwLr/1fLjOedX1QAuBpG9XggWqIIfERw==} engines: {node: ^16.0.0 || >=18.0.0} dependencies: - '@typescript-eslint/types': 6.4.1 - '@typescript-eslint/visitor-keys': 6.4.1 + '@typescript-eslint/types': 6.6.0 + '@typescript-eslint/visitor-keys': 6.6.0 dev: true - /@typescript-eslint/type-utils@6.4.1(eslint@8.48.0)(typescript@5.2.2): - resolution: {integrity: sha512-7ON8M8NXh73SGZ5XvIqWHjgX2f+vvaOarNliGhjrJnv1vdjG0LVIz+ToYfPirOoBi56jxAKLfsLm40+RvxVVXA==} + /@typescript-eslint/type-utils@6.6.0(eslint@8.49.0)(typescript@5.2.2): + resolution: {integrity: sha512-8m16fwAcEnQc69IpeDyokNO+D5spo0w1jepWWY2Q6y5ZKNuj5EhVQXjtVAeDDqvW6Yg7dhclbsz6rTtOvcwpHg==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: eslint: ^7.0.0 || ^8.0.0 @@ -3079,23 +3065,23 @@ packages: typescript: optional: true dependencies: - '@typescript-eslint/typescript-estree': 6.4.1(typescript@5.2.2) - '@typescript-eslint/utils': 6.4.1(eslint@8.48.0)(typescript@5.2.2) + '@typescript-eslint/typescript-estree': 6.6.0(typescript@5.2.2) + '@typescript-eslint/utils': 6.6.0(eslint@8.49.0)(typescript@5.2.2) debug: 4.3.4 - eslint: 8.48.0 - ts-api-utils: 1.0.2(typescript@5.2.2) + eslint: 8.49.0 + ts-api-utils: 1.0.3(typescript@5.2.2) typescript: 5.2.2 transitivePeerDependencies: - supports-color dev: true - /@typescript-eslint/types@6.4.1: - resolution: {integrity: sha512-zAAopbNuYu++ijY1GV2ylCsQsi3B8QvfPHVqhGdDcbx/NK5lkqMnCGU53amAjccSpk+LfeONxwzUhDzArSfZJg==} + /@typescript-eslint/types@6.6.0: + resolution: {integrity: sha512-CB6QpJQ6BAHlJXdwUmiaXDBmTqIE2bzGTDLADgvqtHWuhfNP3rAOK7kAgRMAET5rDRr9Utt+qAzRBdu3AhR3sg==} engines: {node: ^16.0.0 || >=18.0.0} dev: true - /@typescript-eslint/typescript-estree@6.4.1(typescript@5.2.2): - resolution: {integrity: sha512-xF6Y7SatVE/OyV93h1xGgfOkHr2iXuo8ip0gbfzaKeGGuKiAnzS+HtVhSPx8Www243bwlW8IF7X0/B62SzFftg==} + /@typescript-eslint/typescript-estree@6.6.0(typescript@5.2.2): + resolution: {integrity: sha512-hMcTQ6Al8MP2E6JKBAaSxSVw5bDhdmbCEhGW/V8QXkb9oNsFkA4SBuOMYVPxD3jbtQ4R/vSODBsr76R6fP3tbA==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: typescript: '*' @@ -3103,42 +3089,42 @@ packages: typescript: optional: true dependencies: - '@typescript-eslint/types': 6.4.1 - '@typescript-eslint/visitor-keys': 6.4.1 + '@typescript-eslint/types': 6.6.0 + '@typescript-eslint/visitor-keys': 6.6.0 debug: 4.3.4 globby: 11.1.0 is-glob: 4.0.3 semver: 7.5.4 - ts-api-utils: 1.0.2(typescript@5.2.2) + ts-api-utils: 1.0.3(typescript@5.2.2) typescript: 5.2.2 transitivePeerDependencies: - supports-color dev: true - /@typescript-eslint/utils@6.4.1(eslint@8.48.0)(typescript@5.2.2): - resolution: {integrity: sha512-F/6r2RieNeorU0zhqZNv89s9bDZSovv3bZQpUNOmmQK1L80/cV4KEu95YUJWi75u5PhboFoKUJBnZ4FQcoqhDw==} + /@typescript-eslint/utils@6.6.0(eslint@8.49.0)(typescript@5.2.2): + resolution: {integrity: sha512-mPHFoNa2bPIWWglWYdR0QfY9GN0CfvvXX1Sv6DlSTive3jlMTUy+an67//Gysc+0Me9pjitrq0LJp0nGtLgftw==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: eslint: ^7.0.0 || ^8.0.0 dependencies: - '@eslint-community/eslint-utils': 4.4.0(eslint@8.48.0) + '@eslint-community/eslint-utils': 4.4.0(eslint@8.49.0) '@types/json-schema': 7.0.12 - '@types/semver': 7.5.0 - '@typescript-eslint/scope-manager': 6.4.1 - '@typescript-eslint/types': 6.4.1 - '@typescript-eslint/typescript-estree': 6.4.1(typescript@5.2.2) - eslint: 8.48.0 + '@types/semver': 7.5.1 + '@typescript-eslint/scope-manager': 6.6.0 + '@typescript-eslint/types': 6.6.0 + '@typescript-eslint/typescript-estree': 6.6.0(typescript@5.2.2) + eslint: 8.49.0 semver: 7.5.4 transitivePeerDependencies: - supports-color - typescript dev: true - /@typescript-eslint/visitor-keys@6.4.1: - resolution: {integrity: sha512-y/TyRJsbZPkJIZQXrHfdnxVnxyKegnpEvnRGNam7s3TRR2ykGefEWOhaef00/UUN3IZxizS7BTO3svd3lCOJRQ==} + /@typescript-eslint/visitor-keys@6.6.0: + resolution: {integrity: sha512-L61uJT26cMOfFQ+lMZKoJNbAEckLe539VhTxiGHrWl5XSKQgA0RTBZJW2HFPy5T0ZvPVSD93QsrTKDkfNwJGyQ==} engines: {node: ^16.0.0 || >=18.0.0} dependencies: - '@typescript-eslint/types': 6.4.1 + '@typescript-eslint/types': 6.6.0 eslint-visitor-keys: 3.4.3 dev: true @@ -3148,9 +3134,9 @@ packages: peerDependencies: vite: ^4.2.0 dependencies: - '@babel/core': 7.22.10 - '@babel/plugin-transform-react-jsx-self': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-react-jsx-source': 7.22.5(@babel/core@7.22.10) + '@babel/core': 7.22.17 + '@babel/plugin-transform-react-jsx-self': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-react-jsx-source': 7.22.5(@babel/core@7.22.17) react-refresh: 0.14.0 vite: 4.4.9(@types/node@17.0.45) transitivePeerDependencies: @@ -3168,8 +3154,8 @@ packages: vue: 3.3.4 dev: true - /@vitest/coverage-istanbul@0.34.3(vitest@0.34.3): - resolution: {integrity: sha512-RdEGzydbbalyDLmmJ5Qm+T3Lrubw/U9iCnhzM2B1V57t4cVa1t6uyfIHdv68d1au4PRzkLhY7Xouwuhb7BeG+Q==} + /@vitest/coverage-istanbul@0.34.4(vitest@0.34.4): + resolution: {integrity: sha512-jJiN+U5drYrv1fU39T8jOVWc3RklYkNeTR7UyiVD8fa+Tbav9pAxq02pti93OPZIDoXwwg+RhFAuRuAz///rkQ==} peerDependencies: vitest: '>=0.32.0 <1' dependencies: @@ -3178,44 +3164,45 @@ packages: istanbul-lib-report: 3.0.1 istanbul-lib-source-maps: 4.0.1 istanbul-reports: 3.1.6 + picocolors: 1.0.0 test-exclude: 6.0.0 - vitest: 0.34.3(jsdom@22.0.0) + vitest: 0.34.4(jsdom@22.1.0) transitivePeerDependencies: - supports-color dev: true - /@vitest/expect@0.34.3: - resolution: {integrity: sha512-F8MTXZUYRBVsYL1uoIft1HHWhwDbSzwAU9Zgh8S6WFC3YgVb4AnFV2GXO3P5Em8FjEYaZtTnQYoNwwBrlOMXgg==} + /@vitest/expect@0.34.4: + resolution: {integrity: sha512-XlMKX8HyYUqB8dsY8Xxrc64J2Qs9pKMt2Z8vFTL4mBWXJsg4yoALHzJfDWi8h5nkO4Zua4zjqtapQ/IluVkSnA==} dependencies: - '@vitest/spy': 0.34.3 - '@vitest/utils': 0.34.3 + '@vitest/spy': 0.34.4 + '@vitest/utils': 0.34.4 chai: 4.3.8 dev: true - /@vitest/runner@0.34.3: - resolution: {integrity: sha512-lYNq7N3vR57VMKMPLVvmJoiN4bqwzZ1euTW+XXYH5kzr3W/+xQG3b41xJn9ChJ3AhYOSoweu974S1V3qDcFESA==} + /@vitest/runner@0.34.4: + resolution: {integrity: sha512-hwwdB1StERqUls8oV8YcpmTIpVeJMe4WgYuDongVzixl5hlYLT2G8afhcdADeDeqCaAmZcSgLTLtqkjPQF7x+w==} dependencies: - '@vitest/utils': 0.34.3 + '@vitest/utils': 0.34.4 p-limit: 4.0.0 pathe: 1.1.1 dev: true - /@vitest/snapshot@0.34.3: - resolution: {integrity: sha512-QyPaE15DQwbnIBp/yNJ8lbvXTZxS00kRly0kfFgAD5EYmCbYcA+1EEyRalc93M0gosL/xHeg3lKAClIXYpmUiQ==} + /@vitest/snapshot@0.34.4: + resolution: {integrity: sha512-GCsh4coc3YUSL/o+BPUo7lHQbzpdttTxL6f4q0jRx2qVGoYz/cyTRDJHbnwks6TILi6560bVWoBpYC10PuTLHw==} dependencies: magic-string: 0.30.3 pathe: 1.1.1 pretty-format: 29.6.3 dev: true - /@vitest/spy@0.34.3: - resolution: {integrity: sha512-N1V0RFQ6AI7CPgzBq9kzjRdPIgThC340DGjdKdPSE8r86aUSmeliTUgkTqLSgtEwWWsGfBQ+UetZWhK0BgJmkQ==} + /@vitest/spy@0.34.4: + resolution: {integrity: sha512-PNU+fd7DUPgA3Ya924b1qKuQkonAW6hL7YUjkON3wmBwSTIlhOSpy04SJ0NrRsEbrXgMMj6Morh04BMf8k+w0g==} dependencies: tinyspy: 2.1.1 dev: true - /@vitest/utils@0.34.3: - resolution: {integrity: sha512-kiSnzLG6m/tiT0XEl4U2H8JDBjFtwVlaE8I3QfGiMFR0QvnRDfYfdP3YvTBWM/6iJDAyaPY6yVQiCTUc7ZzTHA==} + /@vitest/utils@0.34.4: + resolution: {integrity: sha512-yR2+5CHhp/K4ySY0Qtd+CAL9f5Yh1aXrKfAT42bq6CtlGPh92jIDDDSg7ydlRow1CP+dys4TrOrbELOyNInHSg==} dependencies: diff-sequences: 29.6.3 loupe: 2.3.6 @@ -3243,7 +3230,7 @@ packages: /@vue/compiler-core@3.3.4: resolution: {integrity: sha512-cquyDNvZ6jTbf/+x+AgM2Arrp6G4Dzbb0R64jiG804HRMfRiFXWI6kqUVqZ6ZR0bQhIoQjB4+2bhNtVwndW15g==} dependencies: - '@babel/parser': 7.22.13 + '@babel/parser': 7.22.16 '@vue/shared': 3.3.4 estree-walker: 2.0.2 source-map-js: 1.0.2 @@ -3257,15 +3244,15 @@ packages: /@vue/compiler-sfc@2.7.14: resolution: {integrity: sha512-aNmNHyLPsw+sVvlQFQ2/8sjNuLtK54TC6cuKnVzAY93ks4ZBrvwQSnkkIh7bsbNhum5hJBS00wSDipQ937f5DA==} dependencies: - '@babel/parser': 7.22.13 - postcss: 8.4.28 + '@babel/parser': 7.22.16 + postcss: 8.4.29 source-map: 0.6.1 dev: true /@vue/compiler-sfc@3.3.4: resolution: {integrity: sha512-6y/d8uw+5TkCuzBkgLS0v3lSM3hJDntFEiUORM11pQ/hKvkhSKZrXW6i69UyXlJQisJxuUEJKAWEqWbWsLeNKQ==} dependencies: - '@babel/parser': 7.22.13 + '@babel/parser': 7.22.16 '@vue/compiler-core': 3.3.4 '@vue/compiler-dom': 3.3.4 '@vue/compiler-ssr': 3.3.4 @@ -3273,7 +3260,7 @@ packages: '@vue/shared': 3.3.4 estree-walker: 2.0.2 magic-string: 0.30.3 - postcss: 8.4.28 + postcss: 8.4.29 source-map-js: 1.0.2 /@vue/compiler-ssr@3.3.4: @@ -3311,7 +3298,7 @@ packages: /@vue/reactivity-transform@3.3.4: resolution: {integrity: sha512-MXgwjako4nu5WFLAjpBnCj/ieqcjE2aJBINUNQzkZQfzIZA4xn+0fV1tIYBJvvva3N3OvKGofRLvQIwEQPpaXw==} dependencies: - '@babel/parser': 7.22.13 + '@babel/parser': 7.22.16 '@vue/compiler-core': 3.3.4 '@vue/shared': 3.3.4 estree-walker: 2.0.2 @@ -3571,8 +3558,8 @@ packages: resolution: {integrity: sha512-c5AMf34bKdvPhQ7tBGhqkgKNUzMr4WUs+WDtC2ZUGOUncbxKMTvqxYctiseW3+L4bA8ec+GcZ6/A/FW4m8ukng==} dev: true - /array-includes@3.1.6: - resolution: {integrity: sha512-sgTbLvL6cNnw24FnbaDyjmvddQ2ML8arZsgaJhoABMoplz/4QRhtrYS+alr1BUM1Bwp6dhx8vVCBSLG+StwOFw==} + /array-includes@3.1.7: + resolution: {integrity: sha512-dlcsNBIiWhPkHdOEEKnehA+RNUWDc4UqFtnIXU4uuYDPtA4LDkr7qip2p0VvFAEXNDr0yWZ9PJyIRiGjRLQzwQ==} engines: {node: '>= 0.4'} dependencies: call-bind: 1.0.2 @@ -3587,8 +3574,8 @@ packages: engines: {node: '>=8'} dev: true - /array.prototype.findlastindex@1.2.2: - resolution: {integrity: sha512-tb5thFFlUcp7NdNF6/MpDk/1r/4awWG1FIz3YqDf+/zJSTezBb+/5WViH41obXULHVpDzoiCLpJ/ZO9YbJMsdw==} + /array.prototype.findlastindex@1.2.3: + resolution: {integrity: sha512-LzLoiOMAxvy+Gd3BAq3B7VeIgPdo+Q8hthvKtXybMvRV0jrXfJM/t8mw7nNlpEcVlVUnCnM2KSX4XU5HmpodOA==} engines: {node: '>= 0.4'} dependencies: call-bind: 1.0.2 @@ -3598,8 +3585,8 @@ packages: get-intrinsic: 1.2.1 dev: true - /array.prototype.flat@1.3.1: - resolution: {integrity: sha512-roTU0KWIOmJ4DRLmwKd19Otg0/mT3qPNt0Qb3GWW8iObuZXxrjB/pzn0R3hqpRSWg4HCwqx+0vwOnWnvlOyeIA==} + /array.prototype.flat@1.3.2: + resolution: {integrity: sha512-djYB+Zx2vLewY8RWlNCUdHjDXs2XOgm602S9E7P/UpHgfeHL00cRiIF+IN/G/aUJ7kGPb6yO/ErDI5V2s8iycA==} engines: {node: '>= 0.4'} dependencies: call-bind: 1.0.2 @@ -3608,8 +3595,8 @@ packages: es-shim-unscopables: 1.0.0 dev: true - /array.prototype.flatmap@1.3.1: - resolution: {integrity: sha512-8UGn9O1FDVvMNB0UlLv4voxRMze7+FpHyF5mSMRjWHUMlpoDViniy05870VlxhfgTnLbpuwTzvD76MTtWxB/mQ==} + /array.prototype.flatmap@1.3.2: + resolution: {integrity: sha512-Ewyx0c9PmpcsByhSW4r+9zDU7sGjFc86qf/kKtuSCRdhfbk0SNLLkaT5qvcHnRGgc5NP/ly/y+qkXkqONX54CQ==} engines: {node: '>= 0.4'} dependencies: call-bind: 1.0.2 @@ -3618,8 +3605,8 @@ packages: es-shim-unscopables: 1.0.0 dev: true - /array.prototype.tosorted@1.1.1: - resolution: {integrity: sha512-pZYPXPRl2PqWcsUs6LOMn+1f1532nEoPTYowBtqLwAW+W8vSVhkIGnmOX1t/UQjD6YGI0vcD2B1U7ZFGQH9jnQ==} + /array.prototype.tosorted@1.1.2: + resolution: {integrity: sha512-HuQCHOlk1Weat5jzStICBCd83NxiIMwqDg/dHEsoefabn/hJRj5pVdWcPUSpRrwhwxZOsQassMpgN/xRYFBMIg==} dependencies: call-bind: 1.0.2 define-properties: 1.2.0 @@ -3628,13 +3615,14 @@ packages: get-intrinsic: 1.2.1 dev: true - /arraybuffer.prototype.slice@1.0.1: - resolution: {integrity: sha512-09x0ZWFEjj4WD8PDbykUwo3t9arLn8NIzmmYEJFpYekOAQjpkGSyrQhNoRTcwwcFRu+ycWF78QZ63oWTqSjBcw==} + /arraybuffer.prototype.slice@1.0.2: + resolution: {integrity: sha512-yMBKppFur/fbHu9/6USUe03bZ4knMYiwFBcyiaXB8Go0qNehwX6inYPzK9U0NeQvGxKthcmHcaR8P5MStSRBAw==} engines: {node: '>= 0.4'} dependencies: array-buffer-byte-length: 1.0.0 call-bind: 1.0.2 define-properties: 1.2.0 + es-abstract: 1.22.1 get-intrinsic: 1.2.1 is-array-buffer: 3.0.2 is-shared-array-buffer: 1.0.2 @@ -3661,7 +3649,7 @@ packages: /ast-metadata-inferer@0.8.0: resolution: {integrity: sha512-jOMKcHht9LxYIEQu+RVd22vtgrPaVCtDRQ/16IGmurdzxvYbDd5ynxjnyrzLnieG96eTcAyaoj/wN/4/1FyyeA==} dependencies: - '@mdn/browser-compat-data': 5.3.9 + '@mdn/browser-compat-data': 5.3.15 dev: true /ast-types@0.14.2: @@ -3717,7 +3705,7 @@ packages: /axios@0.26.1: resolution: {integrity: sha512-fPwcX4EvnSHuInCMItEhAGnaSEXRBjtzh9fOtsE6E1G6p7vl7edEeZe11QHf18+6+9gR5PbKV/sGKNaD8YaMeA==} dependencies: - follow-redirects: 1.15.1 + follow-redirects: 1.15.2 transitivePeerDependencies: - debug @@ -3741,46 +3729,46 @@ packages: - debug dev: true - /babel-core@7.0.0-bridge.0(@babel/core@7.22.10): + /babel-core@7.0.0-bridge.0(@babel/core@7.22.17): resolution: {integrity: sha512-poPX9mZH/5CSanm50Q+1toVci6pv5KSRv/5TWCwtzQS5XEwn40BcCrgIeMFWP9CKKIniKXNxoIOnOq4VVlGXhg==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 dev: false - /babel-eslint@10.1.0(eslint@8.48.0): + /babel-eslint@10.1.0(eslint@8.49.0): resolution: {integrity: sha512-ifWaTHQ0ce+448CYop8AdrQiBsGrnC+bMgfyKFdi6EsPLTAWG+QfyDeM6OH+FmWnKvEq5NnBMLvlBUPKQZoDSg==} engines: {node: '>=6'} deprecated: babel-eslint is now @babel/eslint-parser. This package will no longer receive updates. peerDependencies: eslint: '>= 4.12.1' dependencies: - '@babel/code-frame': 7.18.6 - '@babel/parser': 7.19.1 - '@babel/traverse': 7.19.1 - '@babel/types': 7.19.0 - eslint: 8.48.0 + '@babel/code-frame': 7.22.13 + '@babel/parser': 7.22.16 + '@babel/traverse': 7.22.17 + '@babel/types': 7.22.17 + eslint: 8.49.0 eslint-visitor-keys: 1.3.0 - resolve: 1.22.1 + resolve: 1.22.4 transitivePeerDependencies: - supports-color dev: true - /babel-jest@27.5.1(@babel/core@7.22.10): + /babel-jest@27.5.1(@babel/core@7.22.17): resolution: {integrity: sha512-cdQ5dXjGRd0IBRATiQ4mZGlGlRE8kJpjPOixdNRdT+m3UcNqmYWN6rK6nvtXYfY3D76cb8s/O1Ss8ea24PIwcg==} engines: {node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0} peerDependencies: '@babel/core': ^7.8.0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 '@jest/transform': 27.5.1 '@jest/types': 27.5.1 - '@types/babel__core': 7.1.19 + '@types/babel__core': 7.20.1 babel-plugin-istanbul: 6.1.1 - babel-preset-jest: 27.5.1(@babel/core@7.22.10) + babel-preset-jest: 27.5.1(@babel/core@7.22.17) chalk: 4.1.2 - graceful-fs: 4.2.10 + graceful-fs: 4.2.11 slash: 3.0.0 transitivePeerDependencies: - supports-color @@ -3807,178 +3795,143 @@ packages: resolution: {integrity: sha512-50wCwD5EMNW4aRpOwtqzyZHIewTYNxLA4nhB+09d8BIssfNfzBRhkBIHiaPv1Si226TQSvp8gxAJm2iY2qs2hQ==} engines: {node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0} dependencies: - '@babel/template': 7.22.5 - '@babel/types': 7.22.15 - '@types/babel__core': 7.1.19 - '@types/babel__traverse': 7.17.1 + '@babel/template': 7.22.15 + '@babel/types': 7.22.17 + '@types/babel__core': 7.20.1 + '@types/babel__traverse': 7.20.1 dev: true - /babel-plugin-jsx-dom-expressions@0.34.7(@babel/core@7.22.10): - resolution: {integrity: sha512-jTxBhu/MQscWdOcLfqKAY8lIiRsv1ivrMQShlePoa4G8S2cFNb93HTWN4FFdp3SpILaibygFXWU3H+aHpoGH/w==} + /babel-plugin-jsx-dom-expressions@0.36.10(@babel/core@7.22.17): + resolution: {integrity: sha512-QA2k/14WGw+RgcGGnEuLWwnu4em6CGhjeXtjvgOYyFHYS2a+CzPeaVQHDOlfuiBcjq/3hWMspHMIMnPEOIzdBg==} peerDependencies: - '@babel/core': ^7.0.0 + '@babel/core': ^7.20.12 dependencies: - '@babel/core': 7.22.10 - '@babel/helper-module-imports': 7.16.0 - '@babel/plugin-syntax-jsx': 7.22.5(@babel/core@7.22.10) - '@babel/types': 7.22.15 - html-entities: 2.3.2 + '@babel/core': 7.22.17 + '@babel/helper-module-imports': 7.18.6 + '@babel/plugin-syntax-jsx': 7.22.5(@babel/core@7.22.17) + '@babel/types': 7.22.17 + html-entities: 2.3.3 + validate-html-nesting: 1.2.2 dev: true - /babel-plugin-polyfill-corejs2@0.3.3(@babel/core@7.22.10): - resolution: {integrity: sha512-8hOdmFYFSZhqg2C/JgLUQ+t52o5nirNwaWM2B9LWteozwIvM14VSwdsCAUET10qT+kmySAlseadmfeeSWFCy+Q==} - peerDependencies: - '@babel/core': ^7.0.0-0 - dependencies: - '@babel/compat-data': 7.22.9 - '@babel/core': 7.22.10 - '@babel/helper-define-polyfill-provider': 0.3.3(@babel/core@7.22.10) - semver: 6.3.1 - transitivePeerDependencies: - - supports-color - - /babel-plugin-polyfill-corejs2@0.4.5(@babel/core@7.22.10): + /babel-plugin-polyfill-corejs2@0.4.5(@babel/core@7.22.17): resolution: {integrity: sha512-19hwUH5FKl49JEsvyTcoHakh6BE0wgXLLptIyKZ3PijHc/Ci521wygORCUCCred+E/twuqRyAkE02BAWPmsHOg==} peerDependencies: '@babel/core': ^7.4.0 || ^8.0.0-0 <8.0.0 dependencies: '@babel/compat-data': 7.22.9 - '@babel/core': 7.22.10 - '@babel/helper-define-polyfill-provider': 0.4.2(@babel/core@7.22.10) + '@babel/core': 7.22.17 + '@babel/helper-define-polyfill-provider': 0.4.2(@babel/core@7.22.17) semver: 6.3.1 transitivePeerDependencies: - supports-color - dev: false - - /babel-plugin-polyfill-corejs3@0.6.0(@babel/core@7.22.10): - resolution: {integrity: sha512-+eHqR6OPcBhJOGgsIar7xoAB1GcSwVUA3XjAd7HJNzOXT4wv6/H7KIdA/Nc60cvUlDbKApmqNvD1B1bzOt4nyA==} - peerDependencies: - '@babel/core': ^7.0.0-0 - dependencies: - '@babel/core': 7.22.10 - '@babel/helper-define-polyfill-provider': 0.3.3(@babel/core@7.22.10) - core-js-compat: 3.32.0 - transitivePeerDependencies: - - supports-color - /babel-plugin-polyfill-corejs3@0.8.3(@babel/core@7.22.10): + /babel-plugin-polyfill-corejs3@0.8.3(@babel/core@7.22.17): resolution: {integrity: sha512-z41XaniZL26WLrvjy7soabMXrfPWARN25PZoriDEiLMxAp50AUW3t35BGQUMg5xK3UrpVTtagIDklxYa+MhiNA==} peerDependencies: '@babel/core': ^7.4.0 || ^8.0.0-0 <8.0.0 dependencies: - '@babel/core': 7.22.10 - '@babel/helper-define-polyfill-provider': 0.4.2(@babel/core@7.22.10) - core-js-compat: 3.32.0 - transitivePeerDependencies: - - supports-color - dev: false - - /babel-plugin-polyfill-regenerator@0.4.1(@babel/core@7.22.10): - resolution: {integrity: sha512-NtQGmyQDXjQqQ+IzRkBVwEOz9lQ4zxAQZgoAYEtU9dJjnl1Oc98qnN7jcp+bE7O7aYzVpavXE3/VKXNzUbh7aw==} - peerDependencies: - '@babel/core': ^7.0.0-0 - dependencies: - '@babel/core': 7.22.10 - '@babel/helper-define-polyfill-provider': 0.3.3(@babel/core@7.22.10) + '@babel/core': 7.22.17 + '@babel/helper-define-polyfill-provider': 0.4.2(@babel/core@7.22.17) + core-js-compat: 3.32.2 transitivePeerDependencies: - supports-color - /babel-plugin-polyfill-regenerator@0.5.2(@babel/core@7.22.10): + /babel-plugin-polyfill-regenerator@0.5.2(@babel/core@7.22.17): resolution: {integrity: sha512-tAlOptU0Xj34V1Y2PNTL4Y0FOJMDB6bZmoW39FeCQIhigGLkqu3Fj6uiXpxIf6Ij274ENdYx64y6Au+ZKlb1IA==} peerDependencies: '@babel/core': ^7.4.0 || ^8.0.0-0 <8.0.0 dependencies: - '@babel/core': 7.22.10 - '@babel/helper-define-polyfill-provider': 0.4.2(@babel/core@7.22.10) + '@babel/core': 7.22.17 + '@babel/helper-define-polyfill-provider': 0.4.2(@babel/core@7.22.17) transitivePeerDependencies: - supports-color - dev: false /babel-plugin-syntax-trailing-function-commas@7.0.0-beta.0: resolution: {integrity: sha512-Xj9XuRuz3nTSbaTXWv3itLOcxyF4oPD8douBBmj7U9BBC6nEBYfyOJYQMf/8PJAFotC62UY5dFfIGEPr7WswzQ==} dev: false - /babel-plugin-transform-flow-enums@0.0.2(@babel/core@7.22.10): + /babel-plugin-transform-flow-enums@0.0.2(@babel/core@7.22.17): resolution: {integrity: sha512-g4aaCrDDOsWjbm0PUUeVnkcVd6AKJsVc/MbnPhEotEpkeJQP6b8nzewohQi7+QS8UyPehOhGWn0nOwjvWpmMvQ==} dependencies: - '@babel/plugin-syntax-flow': 7.22.5(@babel/core@7.22.10) + '@babel/plugin-syntax-flow': 7.22.5(@babel/core@7.22.17) transitivePeerDependencies: - '@babel/core' dev: false - /babel-preset-current-node-syntax@1.0.1(@babel/core@7.22.10): + /babel-preset-current-node-syntax@1.0.1(@babel/core@7.22.17): resolution: {integrity: sha512-M7LQ0bxarkxQoN+vz5aJPsLBn77n8QgTFmo8WK0/44auK2xlCXrYcUxHFxgU7qW5Yzw/CjmLRK2uJzaCd7LvqQ==} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.22.10 - '@babel/plugin-syntax-async-generators': 7.8.4(@babel/core@7.22.10) - '@babel/plugin-syntax-bigint': 7.8.3(@babel/core@7.22.10) - '@babel/plugin-syntax-class-properties': 7.12.13(@babel/core@7.22.10) - '@babel/plugin-syntax-import-meta': 7.10.4(@babel/core@7.22.10) - '@babel/plugin-syntax-json-strings': 7.8.3(@babel/core@7.22.10) - '@babel/plugin-syntax-logical-assignment-operators': 7.10.4(@babel/core@7.22.10) - '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3(@babel/core@7.22.10) - '@babel/plugin-syntax-numeric-separator': 7.10.4(@babel/core@7.22.10) - '@babel/plugin-syntax-object-rest-spread': 7.8.3(@babel/core@7.22.10) - '@babel/plugin-syntax-optional-catch-binding': 7.8.3(@babel/core@7.22.10) - '@babel/plugin-syntax-optional-chaining': 7.8.3(@babel/core@7.22.10) - '@babel/plugin-syntax-top-level-await': 7.14.5(@babel/core@7.22.10) - dev: true - - /babel-preset-fbjs@3.4.0(@babel/core@7.22.10): + '@babel/core': 7.22.17 + '@babel/plugin-syntax-async-generators': 7.8.4(@babel/core@7.22.17) + '@babel/plugin-syntax-bigint': 7.8.3(@babel/core@7.22.17) + '@babel/plugin-syntax-class-properties': 7.12.13(@babel/core@7.22.17) + '@babel/plugin-syntax-import-meta': 7.10.4(@babel/core@7.22.17) + '@babel/plugin-syntax-json-strings': 7.8.3(@babel/core@7.22.17) + '@babel/plugin-syntax-logical-assignment-operators': 7.10.4(@babel/core@7.22.17) + '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3(@babel/core@7.22.17) + '@babel/plugin-syntax-numeric-separator': 7.10.4(@babel/core@7.22.17) + '@babel/plugin-syntax-object-rest-spread': 7.8.3(@babel/core@7.22.17) + '@babel/plugin-syntax-optional-catch-binding': 7.8.3(@babel/core@7.22.17) + '@babel/plugin-syntax-optional-chaining': 7.8.3(@babel/core@7.22.17) + '@babel/plugin-syntax-top-level-await': 7.14.5(@babel/core@7.22.17) + dev: true + + /babel-preset-fbjs@3.4.0(@babel/core@7.22.17): resolution: {integrity: sha512-9ywCsCvo1ojrw0b+XYk7aFvTH6D9064t0RIL1rtMf3nsa02Xw41MS7sZw216Im35xj/UY0PDBQsa1brUDDF1Ow==} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.22.10 - '@babel/plugin-proposal-class-properties': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-proposal-object-rest-spread': 7.20.7(@babel/core@7.22.10) - '@babel/plugin-syntax-class-properties': 7.12.13(@babel/core@7.22.10) - '@babel/plugin-syntax-flow': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-syntax-jsx': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-syntax-object-rest-spread': 7.8.3(@babel/core@7.22.10) - '@babel/plugin-transform-arrow-functions': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-block-scoped-functions': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-block-scoping': 7.22.10(@babel/core@7.22.10) - '@babel/plugin-transform-classes': 7.22.6(@babel/core@7.22.10) - '@babel/plugin-transform-computed-properties': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-destructuring': 7.22.10(@babel/core@7.22.10) - '@babel/plugin-transform-flow-strip-types': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-for-of': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-function-name': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-literals': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-member-expression-literals': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-modules-commonjs': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-object-super': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-parameters': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-property-literals': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-react-display-name': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-react-jsx': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-shorthand-properties': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-spread': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-template-literals': 7.22.5(@babel/core@7.22.10) + '@babel/core': 7.22.17 + '@babel/plugin-proposal-class-properties': 7.18.6(@babel/core@7.22.17) + '@babel/plugin-proposal-object-rest-spread': 7.20.7(@babel/core@7.22.17) + '@babel/plugin-syntax-class-properties': 7.12.13(@babel/core@7.22.17) + '@babel/plugin-syntax-flow': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-syntax-jsx': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-syntax-object-rest-spread': 7.8.3(@babel/core@7.22.17) + '@babel/plugin-transform-arrow-functions': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-block-scoped-functions': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-block-scoping': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-classes': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-computed-properties': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-destructuring': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-flow-strip-types': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-for-of': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-function-name': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-literals': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-member-expression-literals': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-modules-commonjs': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-object-super': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-parameters': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-property-literals': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-react-display-name': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-react-jsx': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-shorthand-properties': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-spread': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-template-literals': 7.22.5(@babel/core@7.22.17) babel-plugin-syntax-trailing-function-commas: 7.0.0-beta.0 dev: false - /babel-preset-jest@27.5.1(@babel/core@7.22.10): + /babel-preset-jest@27.5.1(@babel/core@7.22.17): resolution: {integrity: sha512-Nptf2FzlPCWYuJg41HBqXVT8ym6bXOevuCTbhxlUpjwtysGaIWFvDEjp4y+G7fl13FgOdjs7P/DmErqH7da0Ag==} engines: {node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 babel-plugin-jest-hoist: 27.5.1 - babel-preset-current-node-syntax: 1.0.1(@babel/core@7.22.10) + babel-preset-current-node-syntax: 1.0.1(@babel/core@7.22.17) dev: true - /babel-preset-solid@1.5.4(@babel/core@7.22.10): - resolution: {integrity: sha512-pangM+KhBx8J6gRHiaRO4yD/J5gK3sydX+TIoC1TaYjxtVV78GIHRtg/HHtCAfg/iRQCJyiGR9TrN0brG8eDZA==} + /babel-preset-solid@1.7.7(@babel/core@7.22.17): + resolution: {integrity: sha512-tdxVzx3kgcIjNXAOmGRbzIhFBPeJjSakiN9yM+IYdL/+LtXNnbGqb0Va5tJb8Sjbk+QVEriovCyuzB5T7jeTvg==} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.22.10 - babel-plugin-jsx-dom-expressions: 0.34.7(@babel/core@7.22.10) + '@babel/core': 7.22.17 + babel-plugin-jsx-dom-expressions: 0.36.10(@babel/core@7.22.17) dev: true /balanced-match@1.0.2: @@ -4022,8 +3975,8 @@ packages: engines: {node: ^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7} hasBin: true dependencies: - caniuse-lite: 1.0.30001520 - electron-to-chromium: 1.4.492 + caniuse-lite: 1.0.30001532 + electron-to-chromium: 1.4.513 node-releases: 2.0.13 update-browserslist-db: 1.0.11(browserslist@4.21.10) @@ -4131,16 +4084,6 @@ packages: quick-lru: 4.0.1 dev: true - /camelcase-keys@8.0.2: - resolution: {integrity: sha512-qMKdlOfsjlezMqxkUGGMaWWs17i2HoL15tM+wtx8ld4nLrUwU58TFdvyGOz/piNP842KeO8yXvggVQSdQ828NA==} - engines: {node: '>=14.16'} - dependencies: - camelcase: 7.0.1 - map-obj: 4.3.0 - quick-lru: 6.1.1 - type-fest: 2.19.0 - dev: true - /camelcase@5.3.1: resolution: {integrity: sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==} engines: {node: '>=6'} @@ -4150,13 +4093,8 @@ packages: engines: {node: '>=10'} dev: false - /camelcase@7.0.1: - resolution: {integrity: sha512-xlx1yCK2Oc1APsPXDL2LdlNP6+uu8OCDdhOBSVT279M/S+y75O30C2VuD8T2ogdePBBl7PfPF4504tnLgX3zfw==} - engines: {node: '>=14.16'} - dev: true - - /caniuse-lite@1.0.30001520: - resolution: {integrity: sha512-tahF5O9EiiTzwTUqAeFjIZbn4Dnqxzz7ktrgGlMYNLH43Ul26IgTMH/zvL3DG0lZxBYnlT04axvInszUsZULdA==} + /caniuse-lite@1.0.30001532: + resolution: {integrity: sha512-FbDFnNat3nMnrROzqrsg314zhqN5LGQ1kyyMk2opcrwGbVGpHRhgCWtAgD5YJUqNAiQ+dklreil/c3Qf1dfCTw==} /chai@4.3.8: resolution: {integrity: sha512-vX4YvVVtxlfSZ2VecZgFUTU5qPCYsobVI2O9FmwEXBhDigYGQA6jRXCycIs1yJnnWbZ6/+a2zNIF5DfVCcJBFQ==} @@ -4246,6 +4184,12 @@ packages: /cli-spinners@2.6.1: resolution: {integrity: sha512-x/5fWmGMnbKQAaNwN+UZlV79qBLM9JFnJuJ03gIi5whrob0xV0ofNVHy9DhwGdsMJQc2OKv0oGmLzvaqvAVv+g==} engines: {node: '>=6'} + dev: true + + /cli-spinners@2.9.0: + resolution: {integrity: sha512-4/aL9X3Wh0yiMQlE+eeRhWP6vclO3QRtw1JHKIT0FFUs5FjpFmESqtMvYZ0+lbzBw900b95mS0hohy+qn2VK/g==} + engines: {node: '>=6'} + dev: false /cliui@6.0.0: resolution: {integrity: sha512-t6wbgtoCXvAzst7QgXxJYqPt0usEfbgQdftEPbLL/cvv6HPE5VgvqCuAIDR0NgU52ds6rFwqrgakNLrHEjCbrQ==} @@ -4415,32 +4359,29 @@ packages: - supports-color dev: false - /conventional-changelog-angular@5.0.13: - resolution: {integrity: sha512-i/gipMxs7s8L/QeuavPF2hLnJgH6pEZAttySB6aiQLWcX3puWDL3ACVmvBhJGxnAy52Qc15ua26BufY6KpmrVA==} - engines: {node: '>=10'} + /conventional-changelog-angular@6.0.0: + resolution: {integrity: sha512-6qLgrBF4gueoC7AFVHu51nHL9pF9FRjXrH+ceVf7WmAfH3gs+gEYOkvxhjMPjZu57I4AGUGoNTY8V7Hrgf1uqg==} + engines: {node: '>=14'} dependencies: compare-func: 2.0.0 - q: 1.5.1 dev: true - /conventional-commits-parser@3.2.4: - resolution: {integrity: sha512-nK7sAtfi+QXbxHCYfhpZsfRtaitZLIA6889kFIouLvz6repszQDgxBu7wf2WbU+Dco7sAnNCJYERCwt54WPC2Q==} - engines: {node: '>=10'} + /conventional-commits-parser@4.0.0: + resolution: {integrity: sha512-WRv5j1FsVM5FISJkoYMR6tPk07fkKT0UodruX4je86V4owk451yjXAKzKAPOs9l7y59E2viHUS9eQ+dfUA9NSg==} + engines: {node: '>=14'} hasBin: true dependencies: JSONStream: 1.3.5 is-text-path: 1.0.1 - lodash: 4.17.21 meow: 8.1.2 split2: 3.2.2 - through2: 4.0.2 dev: true /convert-source-map@1.9.0: resolution: {integrity: sha512-ASFBup0Mz1uyiIjANan1jzLQami9z1PoYSZCiiYW2FczPbenXc45FZdBZLzOT+r6+iciuEModtmCti+hjaAk0A==} - /core-js-compat@3.32.0: - resolution: {integrity: sha512-7a9a3D1k4UCVKnLhrgALyFcP7YCsLOQIxPd0dKjf/6GuPcgyiGP70ewWdCGrSK7evyhymi0qO4EqCmSJofDeYw==} + /core-js-compat@3.32.2: + resolution: {integrity: sha512-+GjlguTDINOijtVRUxrQOv3kfu9rl+qPNdX2LTbJ/ZyVTuxK+ksVSAGX1nHstu4hrv1En/uPTtWgq2gI5wt4AQ==} dependencies: browserslist: 4.21.10 @@ -4472,7 +4413,7 @@ packages: hasBin: true dependencies: cpy: 10.1.0 - meow: 12.0.1 + meow: 12.1.1 dev: true /cpy@10.1.0: @@ -4520,9 +4461,6 @@ packages: rrweb-cssom: 0.6.0 dev: true - /csstype@3.1.0: - resolution: {integrity: sha512-uX1KG+x9h5hIJsaKR9xHUeUraxf8IODOwq9JLNPq6BwB04a/xgpq3rcx47l5BZu5zBPlgD342tdke3Hom/nJRA==} - /csstype@3.1.2: resolution: {integrity: sha512-I7K1Uu0MBPzaFKg4nI5Q7Vs2t+3gWWW648spaF+Rg7pI9ds18Ugn+lvg4SHczUdKlHI5LWBXyqfS8+DufyBsgQ==} @@ -4547,7 +4485,7 @@ packages: resolution: {integrity: sha512-fnULvOpxnC5/Vg3NCiWelDsLiUc9bRwAPs/+LfTLNvetFCtCTN+yQz15C/fs4AwX1R9K5GLtLfn8QW+dWisaAw==} engines: {node: '>=0.11'} dependencies: - '@babel/runtime': 7.22.11 + '@babel/runtime': 7.22.15 dev: true /dayjs@1.11.9: @@ -4591,33 +4529,18 @@ packages: dependencies: ms: 2.1.2 - /decamelize-keys@1.1.0: - resolution: {integrity: sha512-ocLWuYzRPoS9bfiSdDd3cxvrzovVMZnRDVEzAs+hWIVXGDbHxWMECij2OBuyB/An0FFW/nLuq6Kv1i/YC5Qfzg==} + /decamelize-keys@1.1.1: + resolution: {integrity: sha512-WiPxgEirIV0/eIOMcnFBA3/IJZAZqKnwAwWyvvdi4lsr1WCN22nhdf/3db3DoZcUjTV2SqfzIwNyp6y2xs3nmg==} engines: {node: '>=0.10.0'} dependencies: decamelize: 1.2.0 map-obj: 1.0.1 dev: true - /decamelize-keys@2.0.1: - resolution: {integrity: sha512-nrNeSCtU2gV3Apcmn/EZ+aR20zKDuNDStV67jPiupokD3sOAFeMzslLMCFdKv1sPqzwoe5ZUhsSW9IAVgKSL/Q==} - engines: {node: '>=14.16'} - dependencies: - decamelize: 6.0.0 - map-obj: 4.3.0 - quick-lru: 6.1.1 - type-fest: 3.11.0 - dev: true - /decamelize@1.2.0: resolution: {integrity: sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA==} engines: {node: '>=0.10.0'} - /decamelize@6.0.0: - resolution: {integrity: sha512-Fv96DCsdOgB6mdGl67MT5JaTNKRzrzill5OH5s8bjYJXVlcXyPYGyPsUkWyGV5p1TXI5esYIYMMeDJL0hEIwaA==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - dev: true - /decimal.js@10.4.3: resolution: {integrity: sha512-VBBaLc1MgL5XpzgIP7ny5Z6Nx3UrRkIViUkPUdtl9aya5amy3De1gsUUSB1g3+3sExYNjCAsAznmukyxCb1GRA==} dev: true @@ -4765,6 +4688,11 @@ packages: is-obj: 2.0.0 dev: true + /dotenv-expand@10.0.0: + resolution: {integrity: sha512-GopVGCpVS1UKH75VKHGuQFqS1Gusej0z4FyQkPdwjil2gNIv+LNsqBlboOzpJFZKVT95GkCyWJbBSdFEFUWI2A==} + engines: {node: '>=12'} + dev: true + /dotenv@10.0.0: resolution: {integrity: sha512-rlBi9d8jpv9Sf1klPjNfFAuWDjKLwTIJJ/VxtoTwIR6hnZxcEOQCZg2oIL3MWBYw5GpUDKOEnND7LXTbIpQ03Q==} engines: {node: '>=10'} @@ -4804,8 +4732,8 @@ packages: resolution: {integrity: sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==} dev: false - /electron-to-chromium@1.4.492: - resolution: {integrity: sha512-36K9b/6skMVwAIEsC7GiQ8I8N3soCALVSHqWHzNDtGemAcI9Xu8hP02cywWM0A794rTHm0b0zHPeLJHtgFVamQ==} + /electron-to-chromium@1.4.513: + resolution: {integrity: sha512-cOB0xcInjm+E5qIssHeXJ29BaUyWpMyFKT5RB3bsLENDheCja0wMkHJyiPl0NBE/VzDI7JDuNEQWhe6RitEUcw==} /emoji-regex@8.0.0: resolution: {integrity: sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==} @@ -4875,12 +4803,12 @@ packages: engines: {node: '>= 0.4'} dependencies: array-buffer-byte-length: 1.0.0 - arraybuffer.prototype.slice: 1.0.1 + arraybuffer.prototype.slice: 1.0.2 available-typed-arrays: 1.0.5 call-bind: 1.0.2 es-set-tostringtag: 2.0.1 es-to-primitive: 1.2.1 - function.prototype.name: 1.1.5 + function.prototype.name: 1.1.6 get-intrinsic: 1.2.1 get-symbol-description: 1.0.0 globalthis: 1.0.3 @@ -4902,11 +4830,11 @@ packages: object-keys: 1.1.1 object.assign: 4.1.4 regexp.prototype.flags: 1.5.0 - safe-array-concat: 1.0.0 + safe-array-concat: 1.0.1 safe-regex-test: 1.0.0 - string.prototype.trim: 1.2.7 - string.prototype.trimend: 1.0.6 - string.prototype.trimstart: 1.0.6 + string.prototype.trim: 1.2.8 + string.prototype.trimend: 1.0.7 + string.prototype.trimstart: 1.0.7 typed-array-buffer: 1.0.0 typed-array-byte-length: 1.0.0 typed-array-byte-offset: 1.0.0 @@ -4944,8 +4872,8 @@ packages: has-proto: 1.0.1 has-symbols: 1.0.3 internal-slot: 1.0.5 - iterator.prototype: 1.1.0 - safe-array-concat: 1.0.0 + iterator.prototype: 1.1.1 + safe-array-concat: 1.0.1 dev: true /es-set-tostringtag@2.0.1: @@ -5034,13 +4962,13 @@ packages: engines: {node: '>=12'} dev: true - /eslint-config-prettier@9.0.0(eslint@8.48.0): + /eslint-config-prettier@9.0.0(eslint@8.49.0): resolution: {integrity: sha512-IcJsTkJae2S35pRsRAwoCE+925rJJStOdkKnLVgtE+tEpqU0EVVM7OqrwxqgptKdX29NUwC82I5pXsGFIgSevw==} hasBin: true peerDependencies: eslint: '>=7.0.0' dependencies: - eslint: 8.48.0 + eslint: 8.49.0 dev: true /eslint-import-resolver-node@0.3.9: @@ -5053,7 +4981,7 @@ packages: - supports-color dev: true - /eslint-import-resolver-typescript@3.6.0(@typescript-eslint/parser@6.4.1)(eslint-plugin-import@2.28.1)(eslint@8.48.0): + /eslint-import-resolver-typescript@3.6.0(@typescript-eslint/parser@6.6.0)(eslint-plugin-import@2.28.1)(eslint@8.49.0): resolution: {integrity: sha512-QTHR9ddNnn35RTxlaEnx2gCxqFlF2SEN0SE2d17SqwyM7YOSI2GHWRYp5BiRkObTUNYPupC/3Fq2a0PpT+EKpg==} engines: {node: ^14.18.0 || >=16.0.0} peerDependencies: @@ -5062,9 +4990,9 @@ packages: dependencies: debug: 4.3.4 enhanced-resolve: 5.15.0 - eslint: 8.48.0 - eslint-module-utils: 2.8.0(@typescript-eslint/parser@6.4.1)(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.0)(eslint@8.48.0) - eslint-plugin-import: 2.28.1(@typescript-eslint/parser@6.4.1)(eslint-import-resolver-typescript@3.6.0)(eslint@8.48.0) + eslint: 8.49.0 + eslint-module-utils: 2.8.0(@typescript-eslint/parser@6.6.0)(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.0)(eslint@8.49.0) + eslint-plugin-import: 2.28.1(@typescript-eslint/parser@6.6.0)(eslint-import-resolver-typescript@3.6.0)(eslint@8.49.0) fast-glob: 3.3.1 get-tsconfig: 4.7.0 is-core-module: 2.13.0 @@ -5076,7 +5004,7 @@ packages: - supports-color dev: true - /eslint-module-utils@2.8.0(@typescript-eslint/parser@6.4.1)(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.0)(eslint@8.48.0): + /eslint-module-utils@2.8.0(@typescript-eslint/parser@6.6.0)(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.0)(eslint@8.49.0): resolution: {integrity: sha512-aWajIYfsqCKRDgUfjEXNN/JlrzauMuSEy5sbd7WXbtW3EH6A6MpwEh42c7qD+MqQo9QMJ6fWLAeIJynx0g6OAw==} engines: {node: '>=4'} peerDependencies: @@ -5097,33 +5025,32 @@ packages: eslint-import-resolver-webpack: optional: true dependencies: - '@typescript-eslint/parser': 6.4.1(eslint@8.48.0)(typescript@5.2.2) + '@typescript-eslint/parser': 6.6.0(eslint@8.49.0)(typescript@5.2.2) debug: 3.2.7 - eslint: 8.48.0 + eslint: 8.49.0 eslint-import-resolver-node: 0.3.9 - eslint-import-resolver-typescript: 3.6.0(@typescript-eslint/parser@6.4.1)(eslint-plugin-import@2.28.1)(eslint@8.48.0) + eslint-import-resolver-typescript: 3.6.0(@typescript-eslint/parser@6.6.0)(eslint-plugin-import@2.28.1)(eslint@8.49.0) transitivePeerDependencies: - supports-color dev: true - /eslint-plugin-compat@4.1.4(eslint@8.48.0): - resolution: {integrity: sha512-RxySWBmzfIROLFKgeJBJue2BU/6vM2KJWXWAUq+oW4QtrsZXRxbjgxmO1OfF3sHcRuuIenTS/wgo3GyUWZF24w==} + /eslint-plugin-compat@4.2.0(eslint@8.49.0): + resolution: {integrity: sha512-RDKSYD0maWy5r7zb5cWQS+uSPc26mgOzdORJ8hxILmWM7S/Ncwky7BcAtXVY5iRbKjBdHsWU8Yg7hfoZjtkv7w==} engines: {node: '>=14.x'} peerDependencies: eslint: ^4.0.0 || ^5.0.0 || ^6.0.0 || ^7.0.0 || ^8.0.0 dependencies: - '@mdn/browser-compat-data': 5.3.9 - '@tsconfig/node14': 1.0.3 + '@mdn/browser-compat-data': 5.3.15 ast-metadata-inferer: 0.8.0 browserslist: 4.21.10 - caniuse-lite: 1.0.30001520 - eslint: 8.48.0 + caniuse-lite: 1.0.30001532 + eslint: 8.49.0 find-up: 5.0.0 lodash.memoize: 4.1.2 - semver: 7.3.8 + semver: 7.5.4 dev: true - /eslint-plugin-import@2.28.1(@typescript-eslint/parser@6.4.1)(eslint-import-resolver-typescript@3.6.0)(eslint@8.48.0): + /eslint-plugin-import@2.28.1(@typescript-eslint/parser@6.6.0)(eslint-import-resolver-typescript@3.6.0)(eslint@8.49.0): resolution: {integrity: sha512-9I9hFlITvOV55alzoKBI+K9q74kv0iKMeY6av5+umsNwayt59fz692daGyjR+oStBQgx6nwR9rXldDev3Clw+A==} engines: {node: '>=4'} peerDependencies: @@ -5133,22 +5060,22 @@ packages: '@typescript-eslint/parser': optional: true dependencies: - '@typescript-eslint/parser': 6.4.1(eslint@8.48.0)(typescript@5.2.2) - array-includes: 3.1.6 - array.prototype.findlastindex: 1.2.2 - array.prototype.flat: 1.3.1 - array.prototype.flatmap: 1.3.1 + '@typescript-eslint/parser': 6.6.0(eslint@8.49.0)(typescript@5.2.2) + array-includes: 3.1.7 + array.prototype.findlastindex: 1.2.3 + array.prototype.flat: 1.3.2 + array.prototype.flatmap: 1.3.2 debug: 3.2.7 doctrine: 2.1.0 - eslint: 8.48.0 + eslint: 8.49.0 eslint-import-resolver-node: 0.3.9 - eslint-module-utils: 2.8.0(@typescript-eslint/parser@6.4.1)(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.0)(eslint@8.48.0) + eslint-module-utils: 2.8.0(@typescript-eslint/parser@6.6.0)(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.0)(eslint@8.49.0) has: 1.0.3 is-core-module: 2.13.0 is-glob: 4.0.3 minimatch: 3.1.2 - object.fromentries: 2.0.6 - object.groupby: 1.0.0 + object.fromentries: 2.0.7 + object.groupby: 1.0.1 object.values: 1.1.7 semver: 6.3.1 tsconfig-paths: 3.14.2 @@ -5158,38 +5085,38 @@ packages: - supports-color dev: true - /eslint-plugin-react-hooks@4.6.0(eslint@8.48.0): + /eslint-plugin-react-hooks@4.6.0(eslint@8.49.0): resolution: {integrity: sha512-oFc7Itz9Qxh2x4gNHStv3BqJq54ExXmfC+a1NjAta66IAN87Wu0R/QArgIS9qKzX3dXKPI9H5crl9QchNMY9+g==} engines: {node: '>=10'} peerDependencies: eslint: ^3.0.0 || ^4.0.0 || ^5.0.0 || ^6.0.0 || ^7.0.0 || ^8.0.0-0 dependencies: - eslint: 8.48.0 + eslint: 8.49.0 dev: true - /eslint-plugin-react@7.33.2(eslint@8.48.0): + /eslint-plugin-react@7.33.2(eslint@8.49.0): resolution: {integrity: sha512-73QQMKALArI8/7xGLNI/3LylrEYrlKZSb5C9+q3OtOewTnMQi5cT+aE9E41sLCmli3I9PGGmD1yiZydyo4FEPw==} engines: {node: '>=4'} peerDependencies: eslint: ^3 || ^4 || ^5 || ^6 || ^7 || ^8 dependencies: - array-includes: 3.1.6 - array.prototype.flatmap: 1.3.1 - array.prototype.tosorted: 1.1.1 + array-includes: 3.1.7 + array.prototype.flatmap: 1.3.2 + array.prototype.tosorted: 1.1.2 doctrine: 2.1.0 es-iterator-helpers: 1.0.14 - eslint: 8.48.0 + eslint: 8.49.0 estraverse: 5.3.0 jsx-ast-utils: 3.3.5 minimatch: 3.1.2 object.entries: 1.1.7 - object.fromentries: 2.0.6 - object.hasown: 1.1.2 + object.fromentries: 2.0.7 + object.hasown: 1.1.3 object.values: 1.1.7 prop-types: 15.8.1 resolve: 2.0.0-next.4 semver: 6.3.1 - string.prototype.matchall: 4.0.8 + string.prototype.matchall: 4.0.9 dev: true /eslint-scope@7.2.2: @@ -5210,16 +5137,16 @@ packages: engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dev: true - /eslint@8.48.0: - resolution: {integrity: sha512-sb6DLeIuRXxeM1YljSe1KEx9/YYeZFQWcV8Rq9HfigmdDEugjLEVEa1ozDjL6YDjBpQHPJxJzze+alxi4T3OLg==} + /eslint@8.49.0: + resolution: {integrity: sha512-jw03ENfm6VJI0jA9U+8H5zfl5b+FvuU3YYvZRdZHOlU2ggJkxrlkJH4HcDrZpj6YwD8kuYqvQM8LyesoazrSOQ==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} hasBin: true dependencies: - '@eslint-community/eslint-utils': 4.4.0(eslint@8.48.0) + '@eslint-community/eslint-utils': 4.4.0(eslint@8.49.0) '@eslint-community/regexpp': 4.8.0 '@eslint/eslintrc': 2.1.2 - '@eslint/js': 8.48.0 - '@humanwhocodes/config-array': 0.11.10 + '@eslint/js': 8.49.0 + '@humanwhocodes/config-array': 0.11.11 '@humanwhocodes/module-importer': 1.0.1 '@nodelib/fs.walk': 1.2.8 ajv: 6.12.6 @@ -5450,14 +5377,6 @@ packages: locate-path: 6.0.0 path-exists: 4.0.0 - /find-up@6.3.0: - resolution: {integrity: sha512-v2ZsoEuVHYy8ZIlYqwPe/39Cy+cFDzp4dXPaxNvkEuouymu+2Jbz0PxpKarJHYJTmv2HWT3O382qY8l4jMWthw==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - dependencies: - locate-path: 7.2.0 - path-exists: 5.0.0 - dev: true - /flat-cache@3.1.0: resolution: {integrity: sha512-OHx4Qwrrt0E4jEIcI5/Xb+f+QmJYNj2rrK8wiIdQOIrB9WrrJL8cjZvXdXuBTkkEwEqLycb5BeZDV1o2i9bTew==} engines: {node: '>=12.0.0'} @@ -5485,15 +5404,6 @@ packages: engines: {node: '>=0.4.0'} dev: false - /follow-redirects@1.15.1: - resolution: {integrity: sha512-yLAMQs+k0b2m7cVxpS1VKJVvoz7SS9Td1zss3XRwXj+ZDH00RJgnuLx7E44wx02kQLrdM3aOOy+FpzS7+8OizA==} - engines: {node: '>=4.0'} - peerDependencies: - debug: '*' - peerDependenciesMeta: - debug: - optional: true - /follow-redirects@1.15.2: resolution: {integrity: sha512-VQLG33o04KaQ8uYi2tVNbdrWp1QWxNNea+nmIB4EVM28v0hmP17z7aG1+wAkNzVq4KeXTq3221ye5qTJP91JwA==} engines: {node: '>=4.0'} @@ -5502,7 +5412,6 @@ packages: peerDependenciesMeta: debug: optional: true - dev: true /for-each@0.3.3: resolution: {integrity: sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==} @@ -5540,7 +5449,7 @@ packages: resolution: {integrity: sha512-MGIE4HOvQCeUCzmlHs0vXpih4ysz4wg9qiSAu6cd42lVwPbTM1TjV7RusoyQqMmk/95gdQZX72u+YW+c3eEpFQ==} engines: {node: '>=14.14'} dependencies: - graceful-fs: 4.2.10 + graceful-fs: 4.2.11 jsonfile: 6.1.0 universalify: 2.0.0 dev: true @@ -5574,8 +5483,8 @@ packages: /function-bind@1.1.1: resolution: {integrity: sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==} - /function.prototype.name@1.1.5: - resolution: {integrity: sha512-uN7m/BzVKQnCUF/iW8jYea67v++2u7m5UgENbHRtdDVclOUP+FMPlCNdmk0h/ysGyo2tavMJEDqJAkJdRa1vMA==} + /function.prototype.name@1.1.6: + resolution: {integrity: sha512-Z5kx79swU5P27WEayXM1tBi5Ze/lbIyiNgU3qyXUOf9b2rgXYyF9Dy9Cx+IQv/Lc8WCG6L82zwUPpSS9hGehIg==} engines: {node: '>= 0.4'} dependencies: call-bind: 1.0.2 @@ -5645,7 +5554,7 @@ packages: split2: 1.0.0 stream-combiner2: 1.1.1 through2: 2.0.5 - traverse: 0.6.6 + traverse: 0.6.7 dev: true /glob-parent@5.1.2: @@ -5662,13 +5571,13 @@ packages: is-glob: 4.0.3 dev: true - /glob@10.3.3: - resolution: {integrity: sha512-92vPiMb/iqpmEgsOoIDvTjc50wf9CCCvMzsi6W0JLPeUKE8TWP1a73PgqSrqy7iAZxaSD1YdzU7QZR5LF51MJw==} + /glob@10.3.4: + resolution: {integrity: sha512-6LFElP3A+i/Q8XQKEvZjkEWEOTgAIALR9AO2rwT8bgPhDd1anmqDJDZ6lLddI4ehxxxR1S5RIqKe1uapMQfYaQ==} engines: {node: '>=16 || 14 >=14.17'} hasBin: true dependencies: foreground-child: 3.1.1 - jackspeak: 2.2.3 + jackspeak: 2.3.3 minimatch: 9.0.3 minipass: 7.0.3 path-scurry: 1.10.1 @@ -5680,10 +5589,9 @@ packages: fs.realpath: 1.0.0 inflight: 1.0.6 inherits: 2.0.4 - minimatch: 3.1.2 + minimatch: 3.0.5 once: 1.4.0 path-is-absolute: 1.0.1 - dev: true /glob@7.1.6: resolution: {integrity: sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==} @@ -5764,13 +5672,8 @@ packages: get-intrinsic: 1.2.1 dev: true - /graceful-fs@4.2.10: - resolution: {integrity: sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA==} - dev: true - /graceful-fs@4.2.11: resolution: {integrity: sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==} - requiresBuild: true /graphemer@1.4.0: resolution: {integrity: sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag==} @@ -5862,13 +5765,6 @@ packages: lru-cache: 6.0.0 dev: true - /hosted-git-info@6.1.1: - resolution: {integrity: sha512-r0EI+HBMcXadMrugk0GCQ+6BQV39PiWAZVfq7oIckeGiN7sjRGyQxPdft3nQekFTCQbYxLBH+/axZMeH8UX6+w==} - engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} - dependencies: - lru-cache: 7.18.3 - dev: true - /html-encoding-sniffer@3.0.0: resolution: {integrity: sha512-oWv4T4yJ52iKrufjnyZPkrN0CH3QnrUqdB6In1g5Fe1mia8GmF36gnfNySxoZtxD5+NmYw1EElVXiBk93UeskA==} engines: {node: '>=12'} @@ -5876,8 +5772,8 @@ packages: whatwg-encoding: 2.0.0 dev: true - /html-entities@2.3.2: - resolution: {integrity: sha512-c3Ab/url5ksaT0WyleslpBEthOzWhrjQbg75y7XUsfSzi3Dgzt0l8w5e7DylRn15MTlMMD58dTfzddNS2kcAjQ==} + /html-entities@2.3.3: + resolution: {integrity: sha512-DV5Ln36z34NNTDgnz0EWGBLZENelNAtkiFA4kyNOG2tDI6Mz1uSWiq1wAKdyjnJwyDiDO7Fa2SO1CTxPXL8VxA==} dev: true /html-escaper@2.0.2: @@ -6313,8 +6209,8 @@ packages: resolution: {integrity: sha512-pzqtp31nLv/XFOzXGuvhCb8qhjmTVo5vjVk19XE4CRlSWz0KoeJ3bw9XsA7nOp9YBf4qHjwBxkDzKcME/J29Yg==} engines: {node: '>=8'} dependencies: - '@babel/core': 7.22.10 - '@babel/parser': 7.22.13 + '@babel/core': 7.22.17 + '@babel/parser': 7.22.16 '@istanbuljs/schema': 0.1.3 istanbul-lib-coverage: 3.2.0 semver: 6.3.1 @@ -6326,8 +6222,8 @@ packages: resolution: {integrity: sha512-x58orMzEVfzPUKqlbLd1hXCnySCxKdDKa6Rjg97CwuLLRI4g3FHTdnExu1OqffVFay6zeMW+T6/DowFLndWnIw==} engines: {node: '>=10'} dependencies: - '@babel/core': 7.22.10 - '@babel/parser': 7.22.13 + '@babel/core': 7.22.17 + '@babel/parser': 7.22.16 '@istanbuljs/schema': 0.1.3 istanbul-lib-coverage: 3.2.0 semver: 7.5.4 @@ -6363,18 +6259,17 @@ packages: istanbul-lib-report: 3.0.1 dev: true - /iterator.prototype@1.1.0: - resolution: {integrity: sha512-rjuhAk1AJ1fssphHD0IFV6TWL40CwRZ53FrztKx43yk2v6rguBYsY4Bj1VU4HmoMmKwZUlx7mfnhDf9cOp4YTw==} + /iterator.prototype@1.1.1: + resolution: {integrity: sha512-9E+nePc8C9cnQldmNl6bgpTY6zI4OPRZd97fhJ/iVZ1GifIUDVV5F6x1nEDqpe8KaMEZGT4xgrwKQDxXnjOIZQ==} dependencies: define-properties: 1.2.0 get-intrinsic: 1.2.1 has-symbols: 1.0.3 - has-tostringtag: 1.0.0 - reflect.getprototypeof: 1.0.3 + reflect.getprototypeof: 1.0.4 dev: true - /jackspeak@2.2.3: - resolution: {integrity: sha512-pF0kfjmg8DJLxDrizHoCZGUFz4P4czQ3HyfW4BU0ffebYkzAVlBywp5zaxW/TM+r0sGbmrQdi8EQQVTJFxnGsQ==} + /jackspeak@2.3.3: + resolution: {integrity: sha512-R2bUw+kVZFS/h1AZqBKrSgDmdmjApzgY0AlCPumopFiAlbUxE2gf+SCuBzQ0cP5hHmUmFYF5yw55T97Th5Kstg==} engines: {node: '>=14'} dependencies: '@isaacs/cliui': 8.0.2 @@ -6564,23 +6459,23 @@ packages: resolution: {integrity: sha512-0wM3YBWtYePOjfyXQH5MWQ8H7sdk5EXSwZvmSLKk2RboVQ2Bu239jycHDz5J/8Blf3K0Qnoy2b6xD+z10MFB+Q==} dev: false - /jscodeshift@0.14.0(@babel/preset-env@7.21.5): + /jscodeshift@0.14.0(@babel/preset-env@7.22.15): resolution: {integrity: sha512-7eCC1knD7bLUPuSCwXsMZUH51O8jIcoVyKtI6P0XM0IVzlGjckPy3FIwQlorzbN0Sg79oK+RlohN32Mqf/lrYA==} hasBin: true peerDependencies: '@babel/preset-env': ^7.1.6 dependencies: - '@babel/core': 7.22.10 - '@babel/parser': 7.22.13 - '@babel/plugin-proposal-class-properties': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-proposal-nullish-coalescing-operator': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-proposal-optional-chaining': 7.21.0(@babel/core@7.22.10) - '@babel/plugin-transform-modules-commonjs': 7.22.5(@babel/core@7.22.10) - '@babel/preset-env': 7.21.5(@babel/core@7.22.10) - '@babel/preset-flow': 7.22.15(@babel/core@7.22.10) - '@babel/preset-typescript': 7.21.5(@babel/core@7.22.10) - '@babel/register': 7.22.15(@babel/core@7.22.10) - babel-core: 7.0.0-bridge.0(@babel/core@7.22.10) + '@babel/core': 7.22.17 + '@babel/parser': 7.22.16 + '@babel/plugin-proposal-class-properties': 7.18.6(@babel/core@7.22.17) + '@babel/plugin-proposal-nullish-coalescing-operator': 7.18.6(@babel/core@7.22.17) + '@babel/plugin-proposal-optional-chaining': 7.21.0(@babel/core@7.22.17) + '@babel/plugin-transform-modules-commonjs': 7.22.15(@babel/core@7.22.17) + '@babel/preset-env': 7.22.15(@babel/core@7.22.17) + '@babel/preset-flow': 7.22.15(@babel/core@7.22.17) + '@babel/preset-typescript': 7.22.15(@babel/core@7.22.17) + '@babel/register': 7.22.15(@babel/core@7.22.17) + babel-core: 7.0.0-bridge.0(@babel/core@7.22.17) chalk: 4.1.2 flow-parser: 0.206.0 graceful-fs: 4.2.11 @@ -6594,8 +6489,8 @@ packages: - supports-color dev: false - /jsdom@22.0.0: - resolution: {integrity: sha512-p5ZTEb5h+O+iU02t0GfEjAnkdYPrQSkfuTSMkMYyIoMvUNEHsbG0bHHbfXIcfTqD2UfvjQX7mmgiFsyRwGscVw==} + /jsdom@22.1.0: + resolution: {integrity: sha512-/9AVW7xNbsBv6GfWho4TTNjEo9fe6Zhf9O7s0Fhhr3u+awPwAJMKwAMXnkk5vBxflqLW9hTHX/0cs+P3gW+cQw==} engines: {node: '>=16'} peerDependencies: canvas: ^2.5.0 @@ -6618,13 +6513,13 @@ packages: rrweb-cssom: 0.6.0 saxes: 6.0.0 symbol-tree: 3.2.4 - tough-cookie: 4.1.2 + tough-cookie: 4.1.3 w3c-xmlserializer: 4.0.0 webidl-conversions: 7.0.0 whatwg-encoding: 2.0.0 whatwg-mimetype: 3.0.0 whatwg-url: 12.0.1 - ws: 8.13.0 + ws: 8.14.1 xml-name-validator: 4.0.0 transitivePeerDependencies: - bufferutil @@ -6704,8 +6599,8 @@ packages: resolution: {integrity: sha512-ZZow9HBI5O6EPgSJLUb8n2NKgmVWTwCvHGwFuJlMjvLFqlGG6pjirPhtdsseaLZjSibD8eegzmYpUZwoIlj2cQ==} engines: {node: '>=4.0'} dependencies: - array-includes: 3.1.6 - array.prototype.flat: 1.3.1 + array-includes: 3.1.7 + array.prototype.flat: 1.3.2 object.assign: 4.1.4 object.values: 1.1.7 dev: true @@ -6787,13 +6682,6 @@ packages: dependencies: p-locate: 5.0.0 - /locate-path@7.2.0: - resolution: {integrity: sha512-gvVijfZvn7R+2qyPX8mAuKcFGDf6Nc61GdvGafQsHL0sBIxfKzA+usWn4GFC/bk+QdwPUD4kWFJLhElipq+0VA==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - dependencies: - p-locate: 6.0.0 - dev: true - /lodash.debounce@4.0.8: resolution: {integrity: sha512-FT1yDzDYEoYWhnSGnpE/4Kj1fLZkDFyqRb7fNt6FdYOSxlUWAtp42Eh6Wb0rGIv/m9Bgo7x4GhQbm5Ys4SG5ow==} @@ -6869,13 +6757,8 @@ packages: dependencies: yallist: 4.0.0 - /lru-cache@7.18.3: - resolution: {integrity: sha512-jumlc0BIUrS3qJGgIkWZsyfAM7NCWiBcCDhnd+3NNM5KbBmLTgHVfWBcg6W+rLUsIpzpERPsvwUP7CckAQSOoA==} - engines: {node: '>=12'} - dev: true - - /luxon@3.3.0: - resolution: {integrity: sha512-An0UCfG/rSiqtAIiBPO0Y9/zAnHUZxAMiCpTd5h2smgsj7GGmcenvrvww2cqNA8/4A5ZrD1gJpHN2mIHZQF+Mg==} + /luxon@3.4.3: + resolution: {integrity: sha512-tFWBiv3h7z+T/tDaoxA8rqTxy1CHV6gHS//QdaH4pulbq/JuBSGgQspQQqcgnwdAx6pNI7cmvz5Sv/addzHmUg==} engines: {node: '>=12'} dev: true @@ -6935,22 +6818,9 @@ packages: resolution: {integrity: sha512-zYiwtZUcYyXKo/np96AGZAckk+FWWsUdJ3cHGGmld7+AhvcWmQyGCYUh1hc4Q/pkOhb65dQR/pqCyK0cOaHz4Q==} dev: false - /meow@12.0.1: - resolution: {integrity: sha512-/QOqMALNoKQcJAOOdIXjNLtfcCdLXbMFyB1fOOPdm6RzfBTlsuodOCTBDjVbeUSmgDQb8UI2oONqYGtq1PKKKA==} + /meow@12.1.1: + resolution: {integrity: sha512-BhXM0Au22RwUneMPwSCnyhTOizdWoIEPU9sp0Aqa1PnDMR5Wv2FGXYDjuzJEIX+Eo2Rb8xuYe5jrnm5QowQFkw==} engines: {node: '>=16.10'} - dependencies: - '@types/minimist': 1.2.2 - camelcase-keys: 8.0.2 - decamelize: 6.0.0 - decamelize-keys: 2.0.1 - hard-rejection: 2.1.0 - minimist-options: 4.1.0 - normalize-package-data: 5.0.0 - read-pkg-up: 9.1.0 - redent: 4.0.0 - trim-newlines: 5.0.0 - type-fest: 3.11.0 - yargs-parser: 21.1.1 dev: true /meow@8.1.2: @@ -6959,7 +6829,7 @@ packages: dependencies: '@types/minimist': 1.2.2 camelcase-keys: 6.2.2 - decamelize-keys: 1.1.0 + decamelize-keys: 1.1.1 hard-rejection: 2.1.0 minimist-options: 4.1.0 normalize-package-data: 3.0.3 @@ -6982,7 +6852,7 @@ packages: resolution: {integrity: sha512-bgr2OFn0J4r0qoZcHrwEvccF7g9k3wdgTOgk6gmGHrtlZ1Jn3oCpklW/DfZ9PzHfjY2mQammKTc19g/EFGyOJw==} engines: {node: '>=16'} dependencies: - '@babel/core': 7.22.10 + '@babel/core': 7.22.17 hermes-parser: 0.12.0 nullthrows: 1.1.1 transitivePeerDependencies: @@ -7081,65 +6951,65 @@ packages: uglify-es: 3.3.9 dev: false - /metro-react-native-babel-preset@0.76.7(@babel/core@7.22.10): + /metro-react-native-babel-preset@0.76.7(@babel/core@7.22.17): resolution: {integrity: sha512-R25wq+VOSorAK3hc07NW0SmN8z9S/IR0Us0oGAsBcMZnsgkbOxu77Mduqf+f4is/wnWHc5+9bfiqdLnaMngiVw==} engines: {node: '>=16'} peerDependencies: '@babel/core': '*' dependencies: - '@babel/core': 7.22.10 - '@babel/plugin-proposal-async-generator-functions': 7.20.7(@babel/core@7.22.10) - '@babel/plugin-proposal-class-properties': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-proposal-export-default-from': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-proposal-nullish-coalescing-operator': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-proposal-numeric-separator': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-proposal-object-rest-spread': 7.20.7(@babel/core@7.22.10) - '@babel/plugin-proposal-optional-catch-binding': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-proposal-optional-chaining': 7.21.0(@babel/core@7.22.10) - '@babel/plugin-syntax-dynamic-import': 7.8.3(@babel/core@7.22.10) - '@babel/plugin-syntax-export-default-from': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-syntax-flow': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3(@babel/core@7.22.10) - '@babel/plugin-syntax-optional-chaining': 7.8.3(@babel/core@7.22.10) - '@babel/plugin-transform-arrow-functions': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-async-to-generator': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-block-scoping': 7.22.10(@babel/core@7.22.10) - '@babel/plugin-transform-classes': 7.22.6(@babel/core@7.22.10) - '@babel/plugin-transform-computed-properties': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-destructuring': 7.22.10(@babel/core@7.22.10) - '@babel/plugin-transform-flow-strip-types': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-function-name': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-literals': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-modules-commonjs': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-named-capturing-groups-regex': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-parameters': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-react-display-name': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-react-jsx': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-react-jsx-self': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-transform-react-jsx-source': 7.18.6(@babel/core@7.22.10) - '@babel/plugin-transform-runtime': 7.22.15(@babel/core@7.22.10) - '@babel/plugin-transform-shorthand-properties': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-spread': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-sticky-regex': 7.22.5(@babel/core@7.22.10) - '@babel/plugin-transform-typescript': 7.22.10(@babel/core@7.22.10) - '@babel/plugin-transform-unicode-regex': 7.22.5(@babel/core@7.22.10) - '@babel/template': 7.22.5 - babel-plugin-transform-flow-enums: 0.0.2(@babel/core@7.22.10) + '@babel/core': 7.22.17 + '@babel/plugin-proposal-async-generator-functions': 7.20.7(@babel/core@7.22.17) + '@babel/plugin-proposal-class-properties': 7.18.6(@babel/core@7.22.17) + '@babel/plugin-proposal-export-default-from': 7.22.17(@babel/core@7.22.17) + '@babel/plugin-proposal-nullish-coalescing-operator': 7.18.6(@babel/core@7.22.17) + '@babel/plugin-proposal-numeric-separator': 7.18.6(@babel/core@7.22.17) + '@babel/plugin-proposal-object-rest-spread': 7.20.7(@babel/core@7.22.17) + '@babel/plugin-proposal-optional-catch-binding': 7.18.6(@babel/core@7.22.17) + '@babel/plugin-proposal-optional-chaining': 7.21.0(@babel/core@7.22.17) + '@babel/plugin-syntax-dynamic-import': 7.8.3(@babel/core@7.22.17) + '@babel/plugin-syntax-export-default-from': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-syntax-flow': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3(@babel/core@7.22.17) + '@babel/plugin-syntax-optional-chaining': 7.8.3(@babel/core@7.22.17) + '@babel/plugin-transform-arrow-functions': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-async-to-generator': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-block-scoping': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-classes': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-computed-properties': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-destructuring': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-flow-strip-types': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-function-name': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-literals': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-modules-commonjs': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-named-capturing-groups-regex': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-parameters': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-react-display-name': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-react-jsx': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-react-jsx-self': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-react-jsx-source': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-runtime': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-shorthand-properties': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-spread': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-sticky-regex': 7.22.5(@babel/core@7.22.17) + '@babel/plugin-transform-typescript': 7.22.15(@babel/core@7.22.17) + '@babel/plugin-transform-unicode-regex': 7.22.5(@babel/core@7.22.17) + '@babel/template': 7.22.15 + babel-plugin-transform-flow-enums: 0.0.2(@babel/core@7.22.17) react-refresh: 0.4.3 transitivePeerDependencies: - supports-color dev: false - /metro-react-native-babel-transformer@0.76.7(@babel/core@7.22.10): + /metro-react-native-babel-transformer@0.76.7(@babel/core@7.22.17): resolution: {integrity: sha512-W6lW3J7y/05ph3c2p3KKJNhH0IdyxdOCbQ5it7aM2MAl0SM4wgKjaV6EYv9b3rHklpV6K3qMH37UKVcjMooWiA==} engines: {node: '>=16'} peerDependencies: '@babel/core': '*' dependencies: - '@babel/core': 7.22.10 - babel-preset-fbjs: 3.4.0(@babel/core@7.22.10) + '@babel/core': 7.22.17 + babel-preset-fbjs: 3.4.0(@babel/core@7.22.17) hermes-parser: 0.12.0 - metro-react-native-babel-preset: 0.76.7(@babel/core@7.22.10) + metro-react-native-babel-preset: 0.76.7(@babel/core@7.22.17) nullthrows: 1.1.1 transitivePeerDependencies: - supports-color @@ -7154,7 +7024,7 @@ packages: resolution: {integrity: sha512-MuWHubQHymUWBpZLwuKZQgA/qbb35WnDAKPo83rk7JRLIFPvzXSvFaC18voPuzJBt1V98lKQIonh6MiC9gd8Ug==} engines: {node: '>=16'} dependencies: - '@babel/runtime': 7.22.11 + '@babel/runtime': 7.22.15 react-refresh: 0.4.3 dev: false @@ -7162,7 +7032,7 @@ packages: resolution: {integrity: sha512-XKahvB+iuYJSCr3QqCpROli4B4zASAYpkK+j3a0CJmokxCDNbgyI4Fp88uIL6rNaZfN0Mv35S0b99SdFXIfHjg==} engines: {node: '>=16'} dependencies: - '@babel/runtime': 7.22.11 + '@babel/runtime': 7.22.15 react-refresh: 0.4.3 dev: false @@ -7170,8 +7040,8 @@ packages: resolution: {integrity: sha512-Prhx7PeRV1LuogT0Kn5VjCuFu9fVD68eefntdWabrksmNY6mXK8pRqzvNJOhTojh6nek+RxBzZeD6MIOOyXS6w==} engines: {node: '>=16'} dependencies: - '@babel/traverse': 7.22.10 - '@babel/types': 7.22.15 + '@babel/traverse': 7.22.17 + '@babel/types': 7.22.17 invariant: 2.2.4 metro-symbolicate: 0.76.7 nullthrows: 1.1.1 @@ -7186,8 +7056,8 @@ packages: resolution: {integrity: sha512-Hh0ncPsHPVf6wXQSqJqB3K9Zbudht4aUtNpNXYXSxH+pteWqGAXnjtPsRAnCsCWl38wL0jYF0rJDdMajUI3BDw==} engines: {node: '>=16'} dependencies: - '@babel/traverse': 7.22.10 - '@babel/types': 7.22.15 + '@babel/traverse': 7.22.17 + '@babel/types': 7.22.17 invariant: 2.2.4 metro-symbolicate: 0.76.8 nullthrows: 1.1.1 @@ -7232,10 +7102,10 @@ packages: resolution: {integrity: sha512-iSmnjVApbdivjuzb88Orb0JHvcEt5veVyFAzxiS5h0QB+zV79w6JCSqZlHCrbNOkOKBED//LqtKbFVakxllnNg==} engines: {node: '>=16'} dependencies: - '@babel/core': 7.22.10 - '@babel/generator': 7.22.10 - '@babel/template': 7.22.5 - '@babel/traverse': 7.22.10 + '@babel/core': 7.22.17 + '@babel/generator': 7.22.15 + '@babel/template': 7.22.15 + '@babel/traverse': 7.22.17 nullthrows: 1.1.1 transitivePeerDependencies: - supports-color @@ -7245,11 +7115,11 @@ packages: resolution: {integrity: sha512-cGvELqFMVk9XTC15CMVzrCzcO6sO1lURfcbgjuuPdzaWuD11eEyocvkTX0DPiRjsvgAmicz4XYxVzgYl3MykDw==} engines: {node: '>=16'} dependencies: - '@babel/core': 7.22.10 - '@babel/generator': 7.22.10 - '@babel/parser': 7.22.13 - '@babel/types': 7.22.15 - babel-preset-fbjs: 3.4.0(@babel/core@7.22.10) + '@babel/core': 7.22.17 + '@babel/generator': 7.22.15 + '@babel/parser': 7.22.16 + '@babel/types': 7.22.17 + babel-preset-fbjs: 3.4.0(@babel/core@7.22.17) metro: 0.76.7 metro-babel-transformer: 0.76.7 metro-cache: 0.76.7 @@ -7270,12 +7140,12 @@ packages: hasBin: true dependencies: '@babel/code-frame': 7.22.13 - '@babel/core': 7.22.10 - '@babel/generator': 7.22.10 - '@babel/parser': 7.22.13 - '@babel/template': 7.22.5 - '@babel/traverse': 7.22.10 - '@babel/types': 7.22.15 + '@babel/core': 7.22.17 + '@babel/generator': 7.22.15 + '@babel/parser': 7.22.16 + '@babel/template': 7.22.15 + '@babel/traverse': 7.22.17 + '@babel/types': 7.22.17 accepts: 1.3.8 async: 3.2.4 chalk: 4.1.2 @@ -7300,7 +7170,7 @@ packages: metro-inspector-proxy: 0.76.7 metro-minify-terser: 0.76.7 metro-minify-uglify: 0.76.7 - metro-react-native-babel-preset: 0.76.7(@babel/core@7.22.10) + metro-react-native-babel-preset: 0.76.7(@babel/core@7.22.17) metro-resolver: 0.76.7 metro-runtime: 0.76.7 metro-source-map: 0.76.7 @@ -7366,7 +7236,6 @@ packages: resolution: {integrity: sha512-tUpxzX0VAzJHjLu0xUfFv1gwVp9ba3IOuRAVH2EGuRW8a5emA2FlACLqiT/lDVtS1W+TGNwqz3sWaNyLgDJWuw==} dependencies: brace-expansion: 1.1.11 - dev: true /minimatch@3.1.2: resolution: {integrity: sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==} @@ -7439,8 +7308,8 @@ packages: hasBin: true dev: true - /mlly@1.4.1: - resolution: {integrity: sha512-SCDs78Q2o09jiZiE2WziwVBEqXQ02XkGdUy45cbJf+BpYRIjArXRJ1Wbowxkb+NaM9DWvS3UC9GiO/6eqvQ/pg==} + /mlly@1.4.2: + resolution: {integrity: sha512-i/Ykufi2t1EZ6NaPLdfnZk2AX8cs0d+mTzVKuPfqPKPatxLApaBoxJQ9x1/uckXtrS/U5oisPMDkNs0yQTaBRg==} dependencies: acorn: 8.10.0 pathe: 1.1.1 @@ -7576,16 +7445,6 @@ packages: validate-npm-package-license: 3.0.4 dev: true - /normalize-package-data@5.0.0: - resolution: {integrity: sha512-h9iPVIfrVZ9wVYQnxFgtw1ugSvGEMOlyPWWtm8BMJhnwyEL/FLbYbTY3V3PpjI/BUK67n9PEWDu6eHzu1fB15Q==} - engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} - dependencies: - hosted-git-info: 6.1.1 - is-core-module: 2.13.0 - semver: 7.5.4 - validate-npm-package-license: 3.0.4 - dev: true - /normalize-path@3.0.0: resolution: {integrity: sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==} engines: {node: '>=0.10.0'} @@ -7634,11 +7493,11 @@ packages: resolution: {integrity: sha512-ub5E4+FBPKwAZx0UwIQOjYWGHTEq5sPqHQNRN8Z9e4A7u3Tj1weLJsL59yH9vmvqEtBHaOmT6cYQKIZOxp35FQ==} dev: true - /nx-cloud@16.3.0: - resolution: {integrity: sha512-hmNgpeLO4v4WDSWa8YhwX+q+9ohIyY8iqxlWyIKixWzQH2XfRgYFjOLH4IDLGOlKa3hg7MB6+4+75cK9CfSmKw==} + /nx-cloud@16.4.0: + resolution: {integrity: sha512-jbq4hWvDwRlJVpxgMgbmNSkue+6XZSn53R6Vo6qmCAWODJ9KY1BZdZ/9VRL8IX/BRKebVFiXp3SapFB1qPhH8A==} hasBin: true dependencies: - '@nrwl/nx-cloud': 16.3.0 + '@nrwl/nx-cloud': 16.4.0 axios: 1.1.3 chalk: 4.1.2 dotenv: 10.0.0 @@ -7652,8 +7511,8 @@ packages: - debug dev: true - /nx@16.7.4: - resolution: {integrity: sha512-L0Cbikk5kO+IBH0UQ2BOAut5ndeHXBlACKzjOPOCluY8WYh2sxWYt9/N/juFBN3XXRX7ionTr1PhWUzNE0Mzqw==} + /nx@16.8.1: + resolution: {integrity: sha512-K5KrwNdPz0eEe6SY5wrnhZcigjfIJkttPrIJRXNBQTE50NGcOfz1TjMXPdTWBxBCCua5PAealO3OrE8jpv+QnQ==} hasBin: true requiresBuild: true peerDependencies: @@ -7665,7 +7524,7 @@ packages: '@swc/core': optional: true dependencies: - '@nrwl/tao': 16.7.4 + '@nrwl/tao': 16.8.1 '@parcel/watcher': 2.0.4 '@yarnpkg/lockfile': 1.1.0 '@yarnpkg/parsers': 3.0.0-rc.46 @@ -7676,6 +7535,7 @@ packages: cli-spinners: 2.6.1 cliui: 7.0.4 dotenv: 16.3.1 + dotenv-expand: 10.0.0 enquirer: 2.3.6 fast-glob: 3.2.7 figures: 3.2.0 @@ -7701,16 +7561,16 @@ packages: yargs: 17.7.2 yargs-parser: 21.1.1 optionalDependencies: - '@nx/nx-darwin-arm64': 16.7.4 - '@nx/nx-darwin-x64': 16.7.4 - '@nx/nx-freebsd-x64': 16.7.4 - '@nx/nx-linux-arm-gnueabihf': 16.7.4 - '@nx/nx-linux-arm64-gnu': 16.7.4 - '@nx/nx-linux-arm64-musl': 16.7.4 - '@nx/nx-linux-x64-gnu': 16.7.4 - '@nx/nx-linux-x64-musl': 16.7.4 - '@nx/nx-win32-arm64-msvc': 16.7.4 - '@nx/nx-win32-x64-msvc': 16.7.4 + '@nx/nx-darwin-arm64': 16.8.1 + '@nx/nx-darwin-x64': 16.8.1 + '@nx/nx-freebsd-x64': 16.8.1 + '@nx/nx-linux-arm-gnueabihf': 16.8.1 + '@nx/nx-linux-arm64-gnu': 16.8.1 + '@nx/nx-linux-arm64-musl': 16.8.1 + '@nx/nx-linux-x64-gnu': 16.8.1 + '@nx/nx-linux-x64-musl': 16.8.1 + '@nx/nx-win32-arm64-msvc': 16.8.1 + '@nx/nx-win32-x64-msvc': 16.8.1 transitivePeerDependencies: - debug dev: true @@ -7765,8 +7625,8 @@ packages: es-abstract: 1.22.1 dev: true - /object.fromentries@2.0.6: - resolution: {integrity: sha512-VciD13dswC4j1Xt5394WR4MzmAQmlgN72phd/riNp9vtD7tp4QQWJ0R4wvclXcafgcYK8veHRed2W6XeGBvcfg==} + /object.fromentries@2.0.7: + resolution: {integrity: sha512-UPbPHML6sL8PI/mOqPwsH4G6iyXcCGzLin8KvEPenOZN5lpCNBZZQ+V62vdjB1mQHrmqGQt5/OJzemUA+KJmEA==} engines: {node: '>= 0.4'} dependencies: call-bind: 1.0.2 @@ -7774,8 +7634,8 @@ packages: es-abstract: 1.22.1 dev: true - /object.groupby@1.0.0: - resolution: {integrity: sha512-70MWG6NfRH9GnbZOikuhPPYzpUpof9iW2J9E4dW7FXTqPNb6rllE6u39SKwwiNh8lCwX3DDb5OgcKGiEBrTTyw==} + /object.groupby@1.0.1: + resolution: {integrity: sha512-HqaQtqLnp/8Bn4GL16cj+CUYbnpe1bh0TtEaWvybszDG4tgxCJuRpV8VGuvNaI1fAnI4lUJzDG55MXcOH4JZcQ==} dependencies: call-bind: 1.0.2 define-properties: 1.2.0 @@ -7783,8 +7643,8 @@ packages: get-intrinsic: 1.2.1 dev: true - /object.hasown@1.1.2: - resolution: {integrity: sha512-B5UIT3J1W+WuWIU55h0mjlwaqxiE5vYENJXIXZ4VFe05pNYrkKuK0U/6aFcb0pKywYJh7IhfoqUfKVmrJJHZHw==} + /object.hasown@1.1.3: + resolution: {integrity: sha512-fFI4VcYpRHvSLXxP7yiZOMAd331cPfd2p7PFDVbgUsYOfCT3tICVqXWngbjr4m49OvsBwUBQ6O2uQoJvy3RexA==} dependencies: define-properties: 1.2.0 es-abstract: 1.22.1 @@ -7864,7 +7724,7 @@ packages: bl: 4.1.0 chalk: 4.1.2 cli-cursor: 3.1.0 - cli-spinners: 2.6.1 + cli-spinners: 2.9.0 is-interactive: 1.0.0 is-unicode-supported: 0.1.0 log-symbols: 4.1.0 @@ -7929,13 +7789,6 @@ packages: dependencies: p-limit: 3.1.0 - /p-locate@6.0.0: - resolution: {integrity: sha512-wPrq66Llhl7/4AGC6I+cqxT07LhXvWL08LNXz1fENOw0Ap4sRZZ/gZpTTJ5jpurzzzfS2W/Ge9BY3LgLjCShcw==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - dependencies: - p-limit: 4.0.0 - dev: true - /p-map@5.5.0: resolution: {integrity: sha512-VFqfGDHlx87K66yZrNdI4YGtD70IRyd+zSvgks6mzHPRNkoKy+9EKP4SFC77/vTTQYmRmti7dvqC+m5jBrBAcg==} engines: {node: '>=12'} @@ -8002,11 +7855,6 @@ packages: resolution: {integrity: sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==} engines: {node: '>=8'} - /path-exists@5.0.0: - resolution: {integrity: sha512-RjhtfwJOxzcFmNOi6ltcbcu4Iu+FL3zEj83dk4kAS+fVpTxXLO1b38RvJgT/0QwvV/L3aY9TAnyv0EOqW4GoMQ==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - dev: true - /path-is-absolute@1.0.1: resolution: {integrity: sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==} engines: {node: '>=0.10.0'} @@ -8071,7 +7919,7 @@ packages: resolution: {integrity: sha512-nN7pYi0AQqJnoLPC9eHFQ8AcyaixBUOwvqc5TDnIKCMEE6I0y8P7OKA7fPexsXGCGxQDl/cmrLAp26LhcwxZ4A==} dependencies: jsonc-parser: 3.2.0 - mlly: 1.4.1 + mlly: 1.4.2 pathe: 1.1.1 dev: true @@ -8089,11 +7937,11 @@ packages: dependencies: lilconfig: 2.1.0 ts-node: 10.9.1(@types/node@17.0.45)(typescript@5.2.2) - yaml: 2.3.1 + yaml: 2.3.2 dev: true - /postcss@8.4.28: - resolution: {integrity: sha512-Z7V5j0cq8oEKyejIKfpD8b4eBy9cwW2JWPk0+fB1HOAMsfHbnAXLLS+PfVWlzMSLQaWttKDt607I0XHmpE67Vw==} + /postcss@8.4.29: + resolution: {integrity: sha512-cbI+jaqIeu/VGqXEarWkRCCffhjgXc0qjBtXpqJhTBohMUjUQnbBr0xqX3vEKudc4iviTewcJo5ajcec5+wdJw==} engines: {node: ^10 || ^12 || >=14} dependencies: nanoid: 3.3.6 @@ -8105,8 +7953,8 @@ packages: engines: {node: '>= 0.8.0'} dev: true - /prettier@3.0.2: - resolution: {integrity: sha512-o2YR9qtniXvwEZlOKbveKfDQVyqxbEIWn48Z8m3ZJjBjcCmUy3xZGIv+7AkaeuaTr6yPXJjwv07ZWlsWbEy1rQ==} + /prettier@3.0.3: + resolution: {integrity: sha512-L/4pUDMxcNa8R/EthV08Zt42WBO4h1rarVtK0K+QJG0X187OLo7l699jWw0GKuwzkPQ//jMFA/8Xm6Fh3J/DAg==} engines: {node: '>=14'} hasBin: true dev: true @@ -8177,8 +8025,8 @@ packages: resolution: {integrity: sha512-E/ZsdU4HLs/68gYzgGTkMicWTLPdAftJLfJFlLUAAKZGkStNU72sZjT66SnMDVOfOWY/YAoiD7Jxa9iHvngcag==} dev: true - /publint@0.1.15: - resolution: {integrity: sha512-LyoUm/J1oSOik9EYftHSyUEwJATToqFyO1wad8i2m2KvaNcBmV5rbD3ZvPqQAHzVs47MLa2Rsd8nw9NmV/Ep0w==} + /publint@0.1.16: + resolution: {integrity: sha512-wJgk7HnXDT5Ap0DjFYbGz78kPkN44iQvDiaq8P63IEEyNU9mYXvaMd2cAyIM6OgqXM/IA3CK6XWIsRq+wjNpgw==} engines: {node: '>=16'} hasBin: true dependencies: @@ -8192,11 +8040,6 @@ packages: engines: {node: '>=6'} dev: true - /q@1.5.1: - resolution: {integrity: sha512-kV/CThkXo6xyFEZUugw/+pIOywXcDbFYgSct5cT3gqlbkBE1SJdwy6UQoZvodiWF/ckQLZyDE/Bu1M6gVu5lVw==} - engines: {node: '>=0.6.0', teleport: '>=0.2.0'} - dev: true - /querystringify@2.2.0: resolution: {integrity: sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ==} dev: true @@ -8216,11 +8059,6 @@ packages: engines: {node: '>=8'} dev: true - /quick-lru@6.1.1: - resolution: {integrity: sha512-S27GBT+F0NTRiehtbrgaSE1idUAJ5bX8dPAQTdylEyNlrdcH5X4Lz7Edz3DYzecbsCluD5zO8ZNEe04z3D3u6Q==} - engines: {node: '>=12'} - dev: true - /range-parser@1.2.1: resolution: {integrity: sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg==} engines: {node: '>= 0.6'} @@ -8262,7 +8100,7 @@ packages: peerDependencies: react: '>=16.13.1' dependencies: - '@babel/runtime': 7.19.0 + '@babel/runtime': 7.22.15 react: 18.2.0 dev: true @@ -8275,7 +8113,7 @@ packages: /react-is@18.2.0: resolution: {integrity: sha512-xWGDIW6x921xtzPkhiULtthJHoJvBbF3q26fzloPCK0hsvxtPVelvftw3zjbHWSkR2km9Z+4uxbDDK/6Zw9B8w==} - /react-native@0.72.4(@babel/core@7.22.10)(@babel/preset-env@7.21.5)(react@18.2.0): + /react-native@0.72.4(@babel/core@7.22.17)(@babel/preset-env@7.22.15)(react@18.2.0): resolution: {integrity: sha512-+vrObi0wZR+NeqL09KihAAdVlQ9IdplwznJWtYrjnQ4UbCW6rkzZJebRsugwUneSOKNFaHFEo1uKU89HsgtYBg==} engines: {node: '>=16'} hasBin: true @@ -8283,11 +8121,11 @@ packages: react: 18.2.0 dependencies: '@jest/create-cache-key-function': 29.6.3 - '@react-native-community/cli': 11.3.6(@babel/core@7.22.10) + '@react-native-community/cli': 11.3.6(@babel/core@7.22.17) '@react-native-community/cli-platform-android': 11.3.6 '@react-native-community/cli-platform-ios': 11.3.6 '@react-native/assets-registry': 0.72.0 - '@react-native/codegen': 0.72.6(@babel/preset-env@7.21.5) + '@react-native/codegen': 0.72.6(@babel/preset-env@7.22.15) '@react-native/gradle-plugin': 0.72.11 '@react-native/js-polyfills': 0.72.1 '@react-native/normalize-colors': 0.72.0 @@ -8371,15 +8209,6 @@ packages: type-fest: 0.8.1 dev: true - /read-pkg-up@9.1.0: - resolution: {integrity: sha512-vaMRR1AC1nrd5CQM0PhlRsO5oc2AAigqr7cCrZ/MW/Rsaflz4RlgzkpL4qoU/z1F6wrbd85iFv1OQj/y5RdGvg==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - dependencies: - find-up: 6.3.0 - read-pkg: 7.1.0 - type-fest: 2.19.0 - dev: true - /read-pkg@5.2.0: resolution: {integrity: sha512-Ug69mNOpfvKDAc2Q8DRpMjjzdtrnv9HcSMX+4VsZxD1aZ6ZzrIE7rlzXBtWTyhULSMKg076AW6WR5iZpD0JiOg==} engines: {node: '>=8'} @@ -8390,16 +8219,6 @@ packages: type-fest: 0.6.0 dev: true - /read-pkg@7.1.0: - resolution: {integrity: sha512-5iOehe+WF75IccPc30bWTbpdDQLOCc3Uu8bi3Dte3Eueij81yx1Mrufk8qBx/YAbR4uL1FdUr+7BKXDwEtisXg==} - engines: {node: '>=12.20'} - dependencies: - '@types/normalize-package-data': 2.4.1 - normalize-package-data: 3.0.3 - parse-json: 5.2.0 - type-fest: 2.19.0 - dev: true - /readable-stream@2.3.8: resolution: {integrity: sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==} dependencies: @@ -8458,16 +8277,8 @@ packages: strip-indent: 3.0.0 dev: true - /redent@4.0.0: - resolution: {integrity: sha512-tYkDkVVtYkSVhuQ4zBgfvciymHaeuel+zFKXShfDnFP5SyVEP7qo70Rf1jTOTCx3vGNAbnEi/xFkcfQVMIBWag==} - engines: {node: '>=12'} - dependencies: - indent-string: 5.0.0 - strip-indent: 4.0.0 - dev: true - - /reflect.getprototypeof@1.0.3: - resolution: {integrity: sha512-TTAOZpkJ2YLxl7mVHWrNo3iDMEkYlva/kgFcXndqMgbo/AZUmmavEkdXV+hXtE4P8xdyEKRzalaFqZVuwIk/Nw==} + /reflect.getprototypeof@1.0.4: + resolution: {integrity: sha512-ECkTw8TmJwW60lOTR+ZkODISW6RQ8+2CL3COqtiJKLd6MmB45hN51HprHFziKLGkAuTGQhBb91V8cy+KHlaCjw==} engines: {node: '>= 0.4'} dependencies: call-bind: 1.0.2 @@ -8489,6 +8300,7 @@ packages: /regenerator-runtime@0.13.11: resolution: {integrity: sha512-kY1AZVr2Ra+t+piVaJ4gxaFaReZVH40AKNo7UCX6W+dEwBo/2oZJzqfuN1qLq1oL45o56cPaTXELwrTh8Fpggg==} + dev: false /regenerator-runtime@0.14.0: resolution: {integrity: sha512-srw17NI0TUWHuGa5CFGGmhfNIeja30WMBfbslPNhf6JrqQlLN5gcrvig1oqPxiVaXb0oW0XRKtH6Nngs5lKCIA==} @@ -8496,7 +8308,7 @@ packages: /regenerator-transform@0.15.2: resolution: {integrity: sha512-hfMp2BoF0qOk3uc5V20ALGDS2ddjQaLrdl7xrGXvAIow7qeWRM2VA2HuCHkUKk9slq3VwEwLNK3DFBqDfPGYtg==} dependencies: - '@babel/runtime': 7.22.11 + '@babel/runtime': 7.22.15 /regexp.prototype.flags@1.5.0: resolution: {integrity: sha512-0SutC3pNudRKgquxGoRGIz946MZVHqbNfPjBdxeOhBrdgDKlRoXmYLQN9xRbrR09ZXWeGAdPuif7egofn6v5LA==} @@ -8555,15 +8367,6 @@ packages: resolution: {integrity: sha512-seS2Tj26TBVOC2NIc2rOe2y2ZO7efxITtLZcGSOnHHNOQ7CkiUBfw0Iw2ck6xkIhPwLhKNLS8BO+hEpngQlqzw==} dev: true - /resolve@1.22.1: - resolution: {integrity: sha512-nBpuuYuY5jFsli/JIs1oldw6fOQCBioohqWZg/2hiaOybXOft4lonv85uDOKXdf8rhyK159cxU5cDcK/NKk8zw==} - hasBin: true - dependencies: - is-core-module: 2.13.0 - path-parse: 1.0.7 - supports-preserve-symlinks-flag: 1.0.0 - dev: true - /resolve@1.22.4: resolution: {integrity: sha512-PXNdCiPqDqeUou+w1C2eTQbNfxKSuMxqTCuvlmmMsk1NWHL5fRrhY6Pl0qEYYc6+QqGClco1Qj8XnjPego4wfg==} hasBin: true @@ -8604,18 +8407,18 @@ packages: resolution: {integrity: sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==} hasBin: true dependencies: - glob: 7.2.3 + glob: 7.1.4 /rimraf@5.0.1: resolution: {integrity: sha512-OfFZdwtd3lZ+XZzYP/6gTACubwFcHdLRqS9UX3UwpU2dnGQYkPFISRwvM3w9IiB2w7bW5qGo/uAwE4SmXXSKvg==} engines: {node: '>=14'} hasBin: true dependencies: - glob: 10.3.3 + glob: 10.3.4 dev: true - /rollup@3.28.1: - resolution: {integrity: sha512-R9OMQmIHJm9znrU3m3cpE8uhN0fGdXiawME7aZIpQqvpS/85+Vt1Hq1/yVIcYfOmaQiHjvXkQAoJukvLpau6Yw==} + /rollup@3.29.1: + resolution: {integrity: sha512-c+ebvQz0VIH4KhhCpDsI+Bik0eT8ZFEVZEYw0cGMVqIP8zc+gnwl7iXCamTw7vzv2MeuZFZfdx5JJIq+ehzDlg==} engines: {node: '>=14.18.0', npm: '>=8.0.0'} hasBin: true optionalDependencies: @@ -8645,8 +8448,8 @@ packages: mri: 1.2.0 dev: true - /safe-array-concat@1.0.0: - resolution: {integrity: sha512-9dVEFruWIsnie89yym+xWTAYASdpw3CJV7Li/6zBewGf9z2i1j31rP6jnY0pHEO4QZh6N0K11bFjWmdR8UGdPQ==} + /safe-array-concat@1.0.1: + resolution: {integrity: sha512-6XbUAseYE2KtOuGueyeobCySj9L4+66Tn6KQMOPQJrAJEowYKW/YR/MGJZl7FdydUdaFu4LYyDZjxf4/Nmo23Q==} engines: {node: '>=0.4'} dependencies: call-bind: 1.0.2 @@ -8706,14 +8509,6 @@ packages: resolution: {integrity: sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==} hasBin: true - /semver@7.3.8: - resolution: {integrity: sha512-NB1ctGL5rlHrPJtFDVIVzTyQylMLu9N9VICA6HSFJo8MCGVTMW6gfpicwKmmK/dAjTOrqu5l63JJOpDSrAis3A==} - engines: {node: '>=10'} - hasBin: true - dependencies: - lru-cache: 6.0.0 - dev: true - /semver@7.5.3: resolution: {integrity: sha512-QBlUtyVk/5EeHbi7X0fw6liDZc7BBmEaSYn01fMU1OUYbf6GPsbTtd8WmnqbI20SeycoHSeiybkE/q1Q+qlThQ==} engines: {node: '>=10'} @@ -8755,6 +8550,11 @@ packages: engines: {node: '>=0.10.0'} dev: false + /seroval@0.5.1: + resolution: {integrity: sha512-ZfhQVB59hmIauJG5Ydynupy8KHyr5imGNtdDhbZG68Ufh1Ynkv9KOYOAABf71oVbQxJ8VkWnMHAjEHE7fWkH5g==} + engines: {node: '>=10'} + dev: true + /serve-static@1.15.0: resolution: {integrity: sha512-XGuRDNjXUijsUL0vl6nSD7cwURuzEgglbOaFuZM9g3kwDXOWVTck0jLzjPzGD+TazWbboZYu52/9/XPdUgne9g==} engines: {node: '>= 0.8.0'} @@ -8849,10 +8649,11 @@ packages: is-fullwidth-code-point: 2.0.0 dev: false - /solid-js@1.6.13: - resolution: {integrity: sha512-/zcyeect3QnmcD58754IpOU/SzX3s9N19RlRVoKRz3tNpzvel7QKO4FX/PpIFQH6n/pxWq6rSh6b9fwe20XUvw==} + /solid-js@1.7.11: + resolution: {integrity: sha512-JkuvsHt8jqy7USsy9xJtT18aF9r2pFO+GB8JQ2XGTvtF49rGTObB46iebD25sE3qVNvIbwglXOXdALnJq9IHtQ==} dependencies: - csstype: 3.1.0 + csstype: 3.1.2 + seroval: 0.5.1 dev: true /source-map-js@1.0.2: @@ -8895,11 +8696,11 @@ packages: resolution: {integrity: sha512-gRjMgK5uFjbCvdibeGJuy3I5OYz6VLoVdsOJdA6wV0WlfQVLFueoqMxwwYD9RODdgb6oUIvlRlsyFSiQkMKu0g==} dev: true - /spdx-correct@3.1.1: - resolution: {integrity: sha512-cOYcUWwhCuHCXi49RhFRCyJEK3iPj1Ziz9DpViV3tbZOwXD49QzIN3MpOLJNxh2qwq2lJJZaKMVw9qNi4jTC0w==} + /spdx-correct@3.2.0: + resolution: {integrity: sha512-kN9dJbvnySHULIluDHy32WHRUu3Og7B9sbY7tsFLctQkIqnMh3hErYgdMjTYuqmcXX+lK5T1lnUt3G7zNswmZA==} dependencies: spdx-expression-parse: 3.0.1 - spdx-license-ids: 3.0.11 + spdx-license-ids: 3.0.13 dev: true /spdx-exceptions@2.3.0: @@ -8910,11 +8711,11 @@ packages: resolution: {integrity: sha512-cbqHunsQWnJNE6KhVSMsMeH5H/L9EpymbzqTQ3uLwNCLZ1Q481oWaofqH7nO6V07xlXwY6PhQdQ2IedWx/ZK4Q==} dependencies: spdx-exceptions: 2.3.0 - spdx-license-ids: 3.0.11 + spdx-license-ids: 3.0.13 dev: true - /spdx-license-ids@3.0.11: - resolution: {integrity: sha512-Ctl2BrFiM0X3MANYgj3CkygxhRmr9mi6xhejbdO960nF6EDJApTYpn0BQnDKlnNBULKiCN1n3w9EBkHK8ZWg+g==} + /spdx-license-ids@3.0.13: + resolution: {integrity: sha512-XkD+zwiqXHikFZm4AX/7JSCXA98U5Db4AFd5XUg/+9UNtnH75+Z9KxtpYiJZx36mUDVOwH83pl7yvCer6ewM3w==} dev: true /split2@1.0.0: @@ -9005,8 +8806,8 @@ packages: strip-ansi: 7.1.0 dev: true - /string.prototype.matchall@4.0.8: - resolution: {integrity: sha512-6zOCOcJ+RJAQshcTvXPHoxoQGONa3e/Lqx90wUA+wEzX78sg5Bo+1tQo4N0pohS0erG9qtCqJDjNCQBjeWVxyg==} + /string.prototype.matchall@4.0.9: + resolution: {integrity: sha512-6i5hL3MqG/K2G43mWXWgP+qizFW/QH/7kCNN13JrJS5q48FN5IKksLDscexKP3dnmB6cdm9jlNgAsWNLpSykmA==} dependencies: call-bind: 1.0.2 define-properties: 1.2.0 @@ -9018,8 +8819,8 @@ packages: side-channel: 1.0.4 dev: true - /string.prototype.trim@1.2.7: - resolution: {integrity: sha512-p6TmeT1T3411M8Cgg9wBTMRtY2q9+PNy9EV1i2lIXUN/btt763oIfxwN3RR8VU6wHX8j/1CFy0L+YuThm6bgOg==} + /string.prototype.trim@1.2.8: + resolution: {integrity: sha512-lfjY4HcixfQXOfaqCvcBuOIapyaroTXhbkfJN3gcB1OtyupngWK4sEET9Knd0cXd28kTUqu/kHoV4HKSJdnjiQ==} engines: {node: '>= 0.4'} dependencies: call-bind: 1.0.2 @@ -9027,16 +8828,16 @@ packages: es-abstract: 1.22.1 dev: true - /string.prototype.trimend@1.0.6: - resolution: {integrity: sha512-JySq+4mrPf9EsDBEDYMOb/lM7XQLulwg5R/m1r0PXEFqrV0qHvl58sdTilSXtKOflCsK2E8jxf+GKC0T07RWwQ==} + /string.prototype.trimend@1.0.7: + resolution: {integrity: sha512-Ni79DqeB72ZFq1uH/L6zJ+DKZTkOtPIHovb3YZHQViE+HDouuU4mBrLOLDn5Dde3RF8qw5qVETEjhu9locMLvA==} dependencies: call-bind: 1.0.2 define-properties: 1.2.0 es-abstract: 1.22.1 dev: true - /string.prototype.trimstart@1.0.6: - resolution: {integrity: sha512-omqjMDaY92pbn5HOX7f9IccLA+U1tA9GvtU4JrodiXFfYB7jPzzHpRzpglLAjtUV6bB557zwClJezTqnAiYnQA==} + /string.prototype.trimstart@1.0.7: + resolution: {integrity: sha512-NGhtDFu3jCEm7B4Fy0DpLewdJQOZcQ0rGbwQ/+stjnrp2i+rlKeCvos9hOIeCmqwratM47OBxY7uFZzjxHXmrg==} dependencies: call-bind: 1.0.2 define-properties: 1.2.0 @@ -9094,13 +8895,6 @@ packages: min-indent: 1.0.1 dev: true - /strip-indent@4.0.0: - resolution: {integrity: sha512-mnVSV2l+Zv6BLpSD/8V87CW/y9EmmbYzGCIavsnsI6/nwn26DwffM/yztm30Z/I2DY9wdS3vXVCMnHDgZaVNoA==} - engines: {node: '>=12'} - dependencies: - min-indent: 1.0.1 - dev: true - /strip-json-comments@3.1.1: resolution: {integrity: sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==} engines: {node: '>=8'} @@ -9257,12 +9051,6 @@ packages: readable-stream: 2.3.8 xtend: 4.0.2 - /through2@4.0.2: - resolution: {integrity: sha512-iOqSav00cVxEEICeD7TjLB1sueEL+81Wpzp2bY17uZjZN0pWZPuo4suZ/61VujxmqSGFfgOcNuTZ85QJwNZQpw==} - dependencies: - readable-stream: 3.6.2 - dev: true - /through@2.3.8: resolution: {integrity: sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==} dev: true @@ -9306,8 +9094,8 @@ packages: engines: {node: '>=0.6'} dev: false - /tough-cookie@4.1.2: - resolution: {integrity: sha512-G9fqXWoYFZgTc2z8Q5zaHy/vJMjm+WV0AkAeHxVCQiEB1b+dGvWzFW6QV07cY5jQ5gRkeid2qIkzkxUnmoQZUQ==} + /tough-cookie@4.1.3: + resolution: {integrity: sha512-aX/y5pVRkfRnfmuX+OdbSdXvPe6ieKX/G2s7e98f4poJHnqH3281gDPm/metm6E/WRamfx7WC4HUqkWHfQHprw==} engines: {node: '>=6'} dependencies: psl: 1.9.0 @@ -9333,8 +9121,8 @@ packages: punycode: 2.3.0 dev: true - /traverse@0.6.6: - resolution: {integrity: sha512-kdf4JKs8lbARxWdp7RKdNzoJBhGUcIalSYibuGyHJbmk40pOysQ0+QPvlkCOICOivDWU2IJo2rkrxyTK2AH4fw==} + /traverse@0.6.7: + resolution: {integrity: sha512-/y956gpUo9ZNCb99YjxG7OaslxZWHfCHAUUfshwqOXmxUIvqLjVO581BT+gM59+QV9tFe6/CGG53tsA1Y7RSdg==} dev: true /tree-kill@1.2.2: @@ -9347,13 +9135,8 @@ packages: engines: {node: '>=8'} dev: true - /trim-newlines@5.0.0: - resolution: {integrity: sha512-kstfs+hgwmdsOadN3KgA+C68wPJwnZq4DN6WMDCvZapDWEF34W2TyPKN2v2+BJnZgIz5QOfxFeldLyYvdgRAwg==} - engines: {node: '>=14.16'} - dev: true - - /ts-api-utils@1.0.2(typescript@5.2.2): - resolution: {integrity: sha512-Cbu4nIqnEdd+THNEsBdkolnOXhg0I8XteoHaEKgvsxpsbWda4IsUut2c187HxywQCvveojow0Dgw/amxtSKVkQ==} + /ts-api-utils@1.0.3(typescript@5.2.2): + resolution: {integrity: sha512-wNMeqtMz5NtwpT/UZGY5alT+VoKdSsOOP/kqHFcUW1P/VRhH2wJ48+DN2WwUliNbQ976ETwDL0Ifd2VVvgonvg==} engines: {node: '>=16.13.0'} peerDependencies: typescript: '>=4.2.0' @@ -9417,7 +9200,7 @@ packages: /tslib@2.6.2: resolution: {integrity: sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q==} - /tsup@7.2.0(ts-node@10.9.1)(typescript@5.2.2): + /tsup@7.2.0(patch_hash=gwbgl3s5ycyzg75lofcbklamcy)(ts-node@10.9.1)(typescript@5.2.2): resolution: {integrity: sha512-vDHlczXbgUvY3rWvqFEbSqmC1L7woozbzngMqTtL2PGBODTtWlRwGDDawhvWzr5c1QjKe4OAKqJGfE1xeXUvtQ==} engines: {node: '>=16.14'} hasBin: true @@ -9443,7 +9226,7 @@ packages: joycon: 3.1.1 postcss-load-config: 4.0.1(ts-node@10.9.1) resolve-from: 5.0.0 - rollup: 3.28.1 + rollup: 3.29.1 source-map: 0.8.0-beta.0 sucrase: 3.34.0 tree-kill: 1.2.2 @@ -9452,6 +9235,7 @@ packages: - supports-color - ts-node dev: true + patched: true /type-check@0.4.0: resolution: {integrity: sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==} @@ -9489,13 +9273,8 @@ packages: engines: {node: '>=8'} dev: true - /type-fest@2.19.0: - resolution: {integrity: sha512-RAH822pAdBgcNMAfWnCBU3CFZcfZ/i1eZjwFU/dsLKumyuuP3niueg2UAukXYF0E2AAoc82ZSSf9J0WQBinzHA==} - engines: {node: '>=12.20'} - dev: true - - /type-fest@3.11.0: - resolution: {integrity: sha512-JaPw5U9ixP0XcpUbQoVSbxSDcK/K4nww20C3kjm9yE6cDRRhptU28AH60VWf9ltXmCrIfIbtt9J+2OUk2Uqiaw==} + /type-fest@3.13.1: + resolution: {integrity: sha512-tLq3bSNx+xSpwvAJnzrK0Ep5CLNWjvFTOp71URMaAEWBfRb9nnJiBoUe0tF8bI4ZFO3omgBR6NvnbzVUT3Ly4g==} engines: {node: '>=14.16'} dev: true @@ -9634,7 +9413,7 @@ packages: requires-port: 1.0.0 dev: true - /use-isomorphic-layout-effect@1.1.2(@types/react@18.0.15)(react@18.2.0): + /use-isomorphic-layout-effect@1.1.2(@types/react@18.2.21)(react@18.2.0): resolution: {integrity: sha512-49L8yCO3iGT/ZF9QttjwLF/ZD9Iwto5LnH5LmEdk/6cFmXddqi2ulF0edxTwjj+7mqvpVVGQWvbXZdn32wRSHA==} peerDependencies: '@types/react': '*' @@ -9643,7 +9422,7 @@ packages: '@types/react': optional: true dependencies: - '@types/react': 18.0.15 + '@types/react': 18.2.21 react: 18.2.0 dev: false @@ -9671,10 +9450,14 @@ packages: resolution: {integrity: sha512-l8lCEmLcLYZh4nbunNZvQCJc5pv7+RCwa8q/LdUx8u7lsWvPDKmpodJAJNwkAhJC//dFY48KuIEmjtd4RViDrA==} dev: true + /validate-html-nesting@1.2.2: + resolution: {integrity: sha512-hGdgQozCsQJMyfK5urgFcWEqsSSrK63Awe0t/IMR0bZ0QMtnuaiHzThW81guu3qx9abLi99NEuiaN6P9gVYsNg==} + dev: true + /validate-npm-package-license@3.0.4: resolution: {integrity: sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew==} dependencies: - spdx-correct: 3.1.1 + spdx-correct: 3.2.0 spdx-expression-parse: 3.0.1 dev: true @@ -9683,14 +9466,14 @@ packages: engines: {node: '>= 0.8'} dev: false - /vite-node@0.34.3(@types/node@17.0.45): - resolution: {integrity: sha512-+0TzJf1g0tYXj6tR2vEyiA42OPq68QkRZCu/ERSo2PtsDJfBpDyEfuKbRvLmZqi/CgC7SCBtyC+WjTGNMRIaig==} + /vite-node@0.34.4(@types/node@17.0.45): + resolution: {integrity: sha512-ho8HtiLc+nsmbwZMw8SlghESEE3KxJNp04F/jPUCLVvaURwt0d+r9LxEqCX5hvrrOQ0GSyxbYr5ZfRYhQ0yVKQ==} engines: {node: '>=v14.18.0'} hasBin: true dependencies: cac: 6.7.14 debug: 4.3.4 - mlly: 1.4.1 + mlly: 1.4.2 pathe: 1.1.1 picocolors: 1.0.0 vite: 4.4.9(@types/node@17.0.45) @@ -9735,14 +9518,14 @@ packages: dependencies: '@types/node': 17.0.45 esbuild: 0.18.20 - postcss: 8.4.28 - rollup: 3.28.1 + postcss: 8.4.29 + rollup: 3.29.1 optionalDependencies: fsevents: 2.3.3 dev: true - /vitest@0.34.3(jsdom@22.0.0): - resolution: {integrity: sha512-7+VA5Iw4S3USYk+qwPxHl8plCMhA5rtfwMjgoQXMT7rO5ldWcdsdo3U1QD289JgglGK4WeOzgoLTsGFu6VISyQ==} + /vitest@0.34.4(jsdom@22.1.0): + resolution: {integrity: sha512-SE/laOsB6995QlbSE6BtkpXDeVNLJc1u2LHRG/OpnN4RsRzM3GQm4nm3PQCK5OBtrsUqnhzLdnT7se3aeNGdlw==} engines: {node: '>=v14.18.0'} hasBin: true peerDependencies: @@ -9772,20 +9555,20 @@ packages: webdriverio: optional: true dependencies: - '@types/chai': 4.3.5 + '@types/chai': 4.3.6 '@types/chai-subset': 1.3.3 '@types/node': 17.0.45 - '@vitest/expect': 0.34.3 - '@vitest/runner': 0.34.3 - '@vitest/snapshot': 0.34.3 - '@vitest/spy': 0.34.3 - '@vitest/utils': 0.34.3 + '@vitest/expect': 0.34.4 + '@vitest/runner': 0.34.4 + '@vitest/snapshot': 0.34.4 + '@vitest/spy': 0.34.4 + '@vitest/utils': 0.34.4 acorn: 8.10.0 acorn-walk: 8.2.0 cac: 6.7.14 chai: 4.3.8 debug: 4.3.4 - jsdom: 22.0.0 + jsdom: 22.1.0 local-pkg: 0.4.3 magic-string: 0.30.3 pathe: 1.1.1 @@ -9795,7 +9578,7 @@ packages: tinybench: 2.5.0 tinypool: 0.7.0 vite: 4.4.9(@types/node@17.0.45) - vite-node: 0.34.3(@types/node@17.0.45) + vite-node: 0.34.4(@types/node@17.0.45) why-is-node-running: 2.2.2 transitivePeerDependencies: - less @@ -9954,7 +9737,7 @@ packages: resolution: {integrity: sha512-YmjsSMDBYsM1CaFiayOVT06+KJeXf0o5M/CAd4o1lTadFAtacTUM49zoYxr/oroopFDfhvN6iEcBxUyc3gvKmw==} engines: {node: '>= 0.4'} dependencies: - function.prototype.name: 1.1.5 + function.prototype.name: 1.1.6 has-tostringtag: 1.0.0 is-async-function: 2.0.0 is-date-object: 1.0.5 @@ -10088,8 +9871,8 @@ packages: optional: true dev: false - /ws@8.13.0: - resolution: {integrity: sha512-x9vcZYTrFPC7aSIbj7sRCYo7L/Xb8Iy+pW0ng0wt2vCJv7M9HOMy0UoN3rr+IFC7hb7vXoqS+P9ktyLLLhO+LA==} + /ws@8.14.1: + resolution: {integrity: sha512-4OOseMUq8AzRBI/7SLMUwO+FEDnguetSk7KMb1sHwvF2w2Wv5Hoj0nlifx8vtGsftE/jWHojPy8sMMzYLJ2G/A==} engines: {node: '>=10.0.0'} peerDependencies: bufferutil: ^4.0.1 @@ -10132,8 +9915,8 @@ packages: /yallist@4.0.0: resolution: {integrity: sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==} - /yaml@2.3.1: - resolution: {integrity: sha512-2eHWfjaoXgTBC2jNM1LRef62VQa0umtvRiDSk6HSzW7RvS5YtkabJrwYLLEKWBc8a5U2PTSCs+dJjUTJdlHsWQ==} + /yaml@2.3.2: + resolution: {integrity: sha512-N/lyzTPaJasoDmfV7YTrYCI0G/3ivm/9wdG0aHuheKowWQwGTsK0Eoiw6utmzAnI6pkJa0DUVygvp3spqqEKXg==} engines: {node: '>= 14'} /yargs-parser@18.1.3: @@ -10196,5 +9979,5 @@ packages: engines: {node: '>=12.20'} dev: true - /zod@3.21.4: - resolution: {integrity: sha512-m46AKbrzKVzOzs/DZgVnG5H55N1sv1M8qZU3A8RIKbs3mrACDNeIOeilDymVb2HdmP8uwshOCF4uJ8uM9rCqJw==} + /zod@3.22.2: + resolution: {integrity: sha512-wvWkphh5WQsJbVk1tbx1l1Ly4yg+XecD+Mq280uBGt9wa5BKSWf4Mhp6GmrkPixhMxmabYY7RbzlwVP32pbGCg==} From 8130e8b893f1f6a2cc25ce935bb5b996f738870a Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Sun, 10 Sep 2023 08:04:21 -0700 Subject: [PATCH 09/37] chore: mostly update FieldInfo types from Vue --- examples/vue/simple/src/FieldInfo.vue | 2 +- packages/vue-form/src/tests/useField.test.tsx | 10 +-- packages/vue-form/src/tests/useForm.test.tsx | 6 +- packages/vue-form/src/types.ts | 3 +- packages/vue-form/src/useField.tsx | 76 +++++++++++-------- 5 files changed, 54 insertions(+), 43 deletions(-) diff --git a/examples/vue/simple/src/FieldInfo.vue b/examples/vue/simple/src/FieldInfo.vue index a0f754139..a5e5aaf92 100644 --- a/examples/vue/simple/src/FieldInfo.vue +++ b/examples/vue/simple/src/FieldInfo.vue @@ -2,7 +2,7 @@ import { FieldApi } from '@tanstack/vue-form' const props = defineProps<{ - state: FieldApi['state'] + state: FieldApi['state'] }>() diff --git a/packages/vue-form/src/tests/useField.test.tsx b/packages/vue-form/src/tests/useField.test.tsx index 797690046..5a3fb7072 100644 --- a/packages/vue-form/src/tests/useField.test.tsx +++ b/packages/vue-form/src/tests/useField.test.tsx @@ -30,7 +30,7 @@ describe('useField', () => { return () => ( - {({ field }: { field: FieldApi }) => ( + {({ field }: { field: FieldApi }) => ( { name="firstName" onChange={(value) => (value === 'other' ? error : undefined)} > - {({ field }: { field: FieldApi }) => ( + {({ field }: { field: FieldApi }) => (
{ name="firstName" onChange={(value) => (value === 'other' ? error : undefined)} > - {({ field }: { field: FieldApi }) => ( + {({ field }: { field: FieldApi }) => (
{ return error }} > - {({ field }: { field: FieldApi }) => ( + {({ field }: { field: FieldApi }) => (
{ return error }} > - {({ field }: { field: FieldApi }) => ( + {({ field }: { field: FieldApi }) => (
{ return () => ( - {({ field }: { field: FieldApi }) => ( + {({ field }: { field: FieldApi }) => ( { return () => ( - {({ field }: { field: FieldApi }) => ( + {({ field }: { field: FieldApi }) => (

{field.state.value}

)}
@@ -101,7 +101,7 @@ describe('useForm', () => { {({ field, }: { - field: FieldApi + field: FieldApi }) => { return ( , -> = FieldOptions & { +> = FieldOptions & { mode?: 'value' | 'array' } diff --git a/packages/vue-form/src/useField.tsx b/packages/vue-form/src/useField.tsx index 1e08e1fa3..0e2ce588e 100644 --- a/packages/vue-form/src/useField.tsx +++ b/packages/vue-form/src/useField.tsx @@ -12,57 +12,54 @@ import type { UseFieldOptions } from './types' declare module '@tanstack/form-core' { // eslint-disable-next-line no-shadow - interface FieldApi<_TData, TFormData, Opts, TData> { + interface FieldApi { Field: FieldComponent } } -export type UseField = >( +export type UseField = < + TField extends DeepKeys, + ValidatorType, +>( opts?: { name: Narrow } & UseFieldOptions< DeepValue, - TFormData + TFormData, + ValidatorType >, -) => FieldApi, TFormData> +) => FieldApi, TFormData, ValidatorType> export function useField< TData, TFormData, + ValidatorType, TName extends unknown extends TFormData ? string : DeepKeys = unknown extends TFormData ? string : DeepKeys, >( - opts: UseFieldOptions, + opts: UseFieldOptions, ): { - api: FieldApi< - TData, - TFormData, - Omit & { - form: FormApi - } - > - state: Readonly< - Ref< - FieldApi< - TData, - TFormData, - Omit & { - form: FormApi - } - >['state'] - > - > + api: FieldApi + state: Readonly['state']>> } { // Get the form API either manually or from context const { formApi, parentFieldName } = useFormContext() const fieldApi = (() => { + const name = ( + typeof opts.index === 'number' + ? [parentFieldName, opts.index, opts.name] + : [parentFieldName, opts.name] + ) + .filter((d) => d !== undefined) + .join('.') + const api = new FieldApi({ ...opts, form: formApi, - name: opts.name, - } as never) + name: name as TName, + }) api.Field = Field as never @@ -88,7 +85,7 @@ export function useField< }, ) - return { api: fieldApi, state: fieldState } as never + return { api: fieldApi, state: fieldState } } export type FieldValue = TFormData extends any[] @@ -101,8 +98,11 @@ type FieldComponentProps< TParentData, TFormData, TField, + ValidatorType, TName extends unknown extends TFormData ? string : DeepKeys, -> = (TParentData extends any[] +> = { + validator?: ValidatorType +} & (TParentData extends any[] ? { name?: TName index: number @@ -111,15 +111,25 @@ type FieldComponentProps< name: TName index?: never }) & - Omit, 'name' | 'index'> + Omit< + UseFieldOptions, + 'name' | 'index' | 'validator' + > export type FieldComponent = < // Type of the field TField, // Name of the field TName extends unknown extends TFormData ? string : DeepKeys, + ValidatorType, >( - fieldOptions: FieldComponentProps, + fieldOptions: FieldComponentProps< + TParentData, + TFormData, + TField, + ValidatorType, + TName + >, context: SetupContext< {}, SlotsType<{ @@ -127,12 +137,12 @@ export type FieldComponent = < field: FieldApi< TField, TFormData, - FieldApiOptions + FieldApiOptions > state: FieldApi< TField, TFormData, - FieldApiOptions + FieldApiOptions >['state'] } }> @@ -140,8 +150,8 @@ export type FieldComponent = < ) => any export const Field = defineComponent( - ( - fieldOptions: UseFieldOptions, + ( + fieldOptions: UseFieldOptions, context: SetupContext, ) => { const fieldApi = useField({ ...fieldOptions, ...context.attrs }) From e917c8c83107198561ffaf9d2d983aa311589530 Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Mon, 11 Sep 2023 11:32:53 -0700 Subject: [PATCH 10/37] chore: work on fixing type inferencing --- packages/form-core/src/FieldApi.ts | 147 ++++++++---------- .../form-core/src/tests/FieldApi.test-d.ts | 16 ++ 2 files changed, 79 insertions(+), 84 deletions(-) diff --git a/packages/form-core/src/FieldApi.ts b/packages/form-core/src/FieldApi.ts index 8ae26e101..662d3e84b 100644 --- a/packages/form-core/src/FieldApi.ts +++ b/packages/form-core/src/FieldApi.ts @@ -5,66 +5,53 @@ import type { Validator } from './zod-validator' export type ValidationCause = 'change' | 'blur' | 'submit' | 'mount' -type ValidateFn = ( +type ValidateFn<_TData, TFormData, ValidatorType, TName, TData> = ( value: TData, - fieldApi: FieldApi, + fieldApi: FieldApi<_TData, TFormData, ValidatorType, TName, TData>, ) => ValidationError -type ValidateOrFn = +type ValidateOrFn<_TData, TFormData, ValidatorType, TName, TData> = ValidatorType extends Validator ? Parameters['validate']>[1] - : ValidateFn + : ValidateFn<_TData, TFormData, ValidatorType, TName, TData> -type ValidateAsyncFn = ( +type ValidateAsyncFn<_TData, TFormData, Validator, TName, TData> = ( value: TData, - fieldApi: FieldApi, + fieldApi: FieldApi<_TData, TFormData, Validator, TName, TData>, ) => ValidationError | Promise -export interface FieldOptions< - _TData, - TFormData, - ValidatorType, - /** - * This allows us to restrict the name to only be a valid field name while - * also assigning it to a generic - */ - TName = unknown extends TFormData ? string : DeepKeys, - /** - * If TData is unknown, we can use the TName generic to determine the type - */ - TData = unknown extends _TData ? DeepValue : _TData, -> { +export interface FieldOptions<_TData, TFormData, ValidatorType, TName, TData> { name: TName - index?: TData extends any[] ? number : never - defaultValue?: TData + index?: _TData extends any[] ? number : never + defaultValue?: _TData asyncDebounceMs?: number asyncAlways?: boolean validator?: ValidatorType onMount?: (fieldApi: FieldApi) => void - onChange?: ValidateOrFn - onChangeAsync?: ValidateAsyncFn + onChange?: ValidateOrFn<_TData, TFormData, ValidatorType, TName, TData> + onChangeAsync?: ValidateAsyncFn< + _TData, + TFormData, + ValidatorType, + TName, + TData + > onChangeAsyncDebounceMs?: number - onBlur?: ValidateOrFn - onBlurAsync?: ValidateAsyncFn + onBlur?: ValidateOrFn<_TData, TFormData, ValidatorType, TName, TData> + onBlurAsync?: ValidateAsyncFn<_TData, TFormData, ValidatorType, TName, TData> onBlurAsyncDebounceMs?: number - onSubmitAsync?: ValidateAsyncFn + onSubmitAsync?: ValidateAsyncFn< + _TData, + TFormData, + ValidatorType, + TName, + TData + > defaultMeta?: Partial } -export interface FieldApiOptions< - _TData, - TFormData, - ValidatorType, - /** - * This allows us to restrict the name to only be a valid field name while - * also assigning it to a generic - */ - TName = unknown extends TFormData ? string : DeepKeys, - /** - * If TData is unknown, we can use the TName generic to determine the type - */ - TData = unknown extends _TData ? DeepValue : _TData, -> extends FieldOptions<_TData, TFormData, ValidatorType, TName, TData> { +export interface FieldApiOptions<_TData, TFormData, ValidatorType, TName, TData> + extends FieldOptions<_TData, TFormData, ValidatorType, TName, TData> { form: FormApi } @@ -83,34 +70,35 @@ export type FieldState = { meta: FieldMeta } -type GetTData = Opts extends FieldApiOptions< - infer _TData, - infer _TFormData, - infer _Validator, - infer _TName, - infer RealTData -> - ? RealTData - : never - -export class FieldApi { +export class FieldApi< + _TData, + TFormData, + ValidatorType, /** - * This is a hack that allows us to use `GetTData` without calling it everywhere - * - * Unfortunately this hack appears to be needed alongside the `TName` hack - * further up in this file. This properly types all of the internal methods, - * while the `TName` hack types the options properly + * This allows us to restrict the name to only be a valid field name while + * also assigning it to a generic + */ + TName extends unknown extends TFormData ? string : DeepKeys, + /** + * If TData is unknown, we can use the TName generic to determine the type */ - _tdata!: GetTData + TData = unknown extends _TData ? DeepValue : _TData, +> { uid: number form: (typeof this.options)['form'] name!: DeepKeys - store!: Store> - state!: FieldState - prevState!: FieldState + store!: Store> + state!: FieldState + prevState!: FieldState constructor( - public options: FieldApiOptions, + public options: FieldApiOptions< + _TData, + TFormData, + ValidatorType, + TName, + TData + >, ) { this.form = options.form this.uid = uid++ @@ -122,7 +110,7 @@ export class FieldApi { this.name = options.name as never - this.store = new Store>( + this.store = new Store>( { value: this.getValue(), // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition @@ -189,7 +177,7 @@ export class FieldApi { } update = ( - opts: FieldApiOptions, + opts: FieldApiOptions<_TData, TFormData, ValidatorType, TName, TData>, ) => { // Default Value // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition @@ -212,12 +200,12 @@ export class FieldApi { this.options = opts as never } - getValue = (): typeof this._tdata => { + getValue = (): TData => { return this.form.getFieldValue(this.name) } setValue = ( - updater: Updater, + updater: Updater, options?: { touch?: boolean; notify?: boolean }, ) => { this.form.setFieldValue(this.name, updater as never, options) @@ -241,17 +229,12 @@ export class FieldApi { getInfo = () => this.form.getFieldInfo(this.name) - pushValue = ( - value: typeof this._tdata extends any[] - ? (typeof this._tdata)[number] - : never, - ) => this.form.pushFieldValue(this.name, value as any) + pushValue = (value: TData extends any[] ? TData[number] : never) => + this.form.pushFieldValue(this.name, value as any) insertValue = ( index: number, - value: typeof this._tdata extends any[] - ? (typeof this._tdata)[number] - : never, + value: TData extends any[] ? TData[number] : never, ) => this.form.insertFieldValue(this.name, index, value as any) removeValue = (index: number) => this.form.removeFieldValue(this.name, index) @@ -259,12 +242,8 @@ export class FieldApi { swapValues = (aIndex: number, bIndex: number) => this.form.swapFieldValues(this.name, aIndex, bIndex) - getSubField = >(name: TName) => - new FieldApi< - DeepValue, - TFormData, - ValidatorType - >({ + getSubField = >(name: TName) => + new FieldApi, TFormData, ValidatorType>({ name: `${this.name}.${name}` as never, form: this.form, }) @@ -273,7 +252,7 @@ export class FieldApi { const isValidator = ( item: unknown, ): item is Validator< - typeof this._tdata, + TData, typeof this.options.onBlur | typeof this.options.onChange > => !!item && typeof item === 'function' && (item as any).isValidator === true @@ -301,7 +280,7 @@ export class FieldApi { } return ( - validate as ValidateFn + validate as ValidateFn<_TData, TFormData, ValidatorType, TName, TData> )(value, this as never) } @@ -422,7 +401,7 @@ export class FieldApi { validate = ( cause: ValidationCause, - value?: typeof this._tdata, + value?: TData, ): ValidationError[] | Promise => { // If the field is pristine and validatePristine is false, do not validate if (!this.state.meta.isTouched) return [] @@ -440,7 +419,7 @@ export class FieldApi { return this.validateAsync(value, cause) } - handleChange = (updater: Updater) => { + handleChange = (updater: Updater) => { this.setValue(updater, { touch: true }) } diff --git a/packages/form-core/src/tests/FieldApi.test-d.ts b/packages/form-core/src/tests/FieldApi.test-d.ts index a8c8e6e16..ceb2e420d 100644 --- a/packages/form-core/src/tests/FieldApi.test-d.ts +++ b/packages/form-core/src/tests/FieldApi.test-d.ts @@ -4,6 +4,22 @@ import { FieldApi } from '../FieldApi' import { zodValidator } from '../zod-validator' import z from 'zod' +it('should type value properly', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + } as const) + + const field = new FieldApi({ + form, + name: 'name', + }) + + assertType<'name'>(field.options.name) + assertType<'test'>(field.getValue()) +}) + it('should type onChange properly', () => { const form = new FormApi({ defaultValues: { From 2f6ce800260f543c8309633885b57813e0c8300b Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Mon, 11 Sep 2023 11:33:20 -0700 Subject: [PATCH 11/37] fix: make ValidatorType optional --- packages/form-core/src/FieldApi.ts | 54 +++++++++++++++---- .../form-core/src/tests/FieldApi.test-d.ts | 1 + 2 files changed, 44 insertions(+), 11 deletions(-) diff --git a/packages/form-core/src/FieldApi.ts b/packages/form-core/src/FieldApi.ts index 662d3e84b..f73d81ae2 100644 --- a/packages/form-core/src/FieldApi.ts +++ b/packages/form-core/src/FieldApi.ts @@ -5,22 +5,45 @@ import type { Validator } from './zod-validator' export type ValidationCause = 'change' | 'blur' | 'submit' | 'mount' -type ValidateFn<_TData, TFormData, ValidatorType, TName, TData> = ( +type ValidateFn< + _TData, + TFormData, + ValidatorType, + TName extends unknown extends TFormData ? string : DeepKeys, + TData, +> = ( value: TData, fieldApi: FieldApi<_TData, TFormData, ValidatorType, TName, TData>, ) => ValidationError -type ValidateOrFn<_TData, TFormData, ValidatorType, TName, TData> = - ValidatorType extends Validator - ? Parameters['validate']>[1] - : ValidateFn<_TData, TFormData, ValidatorType, TName, TData> +type ValidateOrFn< + _TData, + TFormData, + ValidatorType, + TName extends unknown extends TFormData ? string : DeepKeys, + TData, +> = ValidatorType extends Validator + ? Parameters['validate']>[1] + : ValidateFn<_TData, TFormData, ValidatorType, TName, TData> -type ValidateAsyncFn<_TData, TFormData, Validator, TName, TData> = ( +type ValidateAsyncFn< + _TData, + TFormData, + Validator, + TName extends unknown extends TFormData ? string : DeepKeys, + TData, +> = ( value: TData, fieldApi: FieldApi<_TData, TFormData, Validator, TName, TData>, ) => ValidationError | Promise -export interface FieldOptions<_TData, TFormData, ValidatorType, TName, TData> { +export interface FieldOptions< + _TData, + TFormData, + ValidatorType, + TName extends unknown extends TFormData ? string : DeepKeys, + TData, +> { name: TName index?: _TData extends any[] ? number : never defaultValue?: _TData @@ -50,8 +73,13 @@ export interface FieldOptions<_TData, TFormData, ValidatorType, TName, TData> { defaultMeta?: Partial } -export interface FieldApiOptions<_TData, TFormData, ValidatorType, TName, TData> - extends FieldOptions<_TData, TFormData, ValidatorType, TName, TData> { +export interface FieldApiOptions< + _TData, + TFormData, + ValidatorType, + TName extends unknown extends TFormData ? string : DeepKeys, + TData, +> extends FieldOptions<_TData, TFormData, ValidatorType, TName, TData> { form: FormApi } @@ -73,12 +101,16 @@ export type FieldState = { export class FieldApi< _TData, TFormData, - ValidatorType, + ValidatorType = unknown, /** * This allows us to restrict the name to only be a valid field name while * also assigning it to a generic */ - TName extends unknown extends TFormData ? string : DeepKeys, + TName extends unknown extends TFormData + ? string + : DeepKeys = unknown extends TFormData + ? string + : DeepKeys, /** * If TData is unknown, we can use the TName generic to determine the type */ diff --git a/packages/form-core/src/tests/FieldApi.test-d.ts b/packages/form-core/src/tests/FieldApi.test-d.ts index ceb2e420d..0d4b1c850 100644 --- a/packages/form-core/src/tests/FieldApi.test-d.ts +++ b/packages/form-core/src/tests/FieldApi.test-d.ts @@ -16,6 +16,7 @@ it('should type value properly', () => { name: 'name', }) + assertType<'test'>(field.state.value) assertType<'name'>(field.options.name) assertType<'test'>(field.getValue()) }) From 5536f97515a7dbbdd33ee29d901460320ecd0e4c Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Mon, 11 Sep 2023 11:35:16 -0700 Subject: [PATCH 12/37] chore: make TName restriction easier to grok --- packages/form-core/src/FieldApi.ts | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/packages/form-core/src/FieldApi.ts b/packages/form-core/src/FieldApi.ts index f73d81ae2..0972b729d 100644 --- a/packages/form-core/src/FieldApi.ts +++ b/packages/form-core/src/FieldApi.ts @@ -5,11 +5,15 @@ import type { Validator } from './zod-validator' export type ValidationCause = 'change' | 'blur' | 'submit' | 'mount' +type RestrictTName = unknown extends TFormData + ? string + : DeepKeys + type ValidateFn< _TData, TFormData, ValidatorType, - TName extends unknown extends TFormData ? string : DeepKeys, + TName extends RestrictTName, TData, > = ( value: TData, @@ -20,7 +24,7 @@ type ValidateOrFn< _TData, TFormData, ValidatorType, - TName extends unknown extends TFormData ? string : DeepKeys, + TName extends RestrictTName, TData, > = ValidatorType extends Validator ? Parameters['validate']>[1] @@ -30,7 +34,7 @@ type ValidateAsyncFn< _TData, TFormData, Validator, - TName extends unknown extends TFormData ? string : DeepKeys, + TName extends RestrictTName, TData, > = ( value: TData, @@ -41,7 +45,7 @@ export interface FieldOptions< _TData, TFormData, ValidatorType, - TName extends unknown extends TFormData ? string : DeepKeys, + TName extends RestrictTName, TData, > { name: TName @@ -77,7 +81,7 @@ export interface FieldApiOptions< _TData, TFormData, ValidatorType, - TName extends unknown extends TFormData ? string : DeepKeys, + TName extends RestrictTName, TData, > extends FieldOptions<_TData, TFormData, ValidatorType, TName, TData> { form: FormApi @@ -106,11 +110,7 @@ export class FieldApi< * This allows us to restrict the name to only be a valid field name while * also assigning it to a generic */ - TName extends unknown extends TFormData - ? string - : DeepKeys = unknown extends TFormData - ? string - : DeepKeys, + TName extends RestrictTName = RestrictTName, /** * If TData is unknown, we can use the TName generic to determine the type */ From 3d4ddb16ac34482371608aeef7520f0794363b76 Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Mon, 11 Sep 2023 11:50:23 -0700 Subject: [PATCH 13/37] chore: fix React types --- packages/form-core/src/FieldApi.ts | 2 +- packages/react-form/src/types.ts | 9 +++-- packages/react-form/src/useField.tsx | 57 ++++++++++++++-------------- 3 files changed, 35 insertions(+), 33 deletions(-) diff --git a/packages/form-core/src/FieldApi.ts b/packages/form-core/src/FieldApi.ts index 0972b729d..f15b7f3fe 100644 --- a/packages/form-core/src/FieldApi.ts +++ b/packages/form-core/src/FieldApi.ts @@ -5,7 +5,7 @@ import type { Validator } from './zod-validator' export type ValidationCause = 'change' | 'blur' | 'submit' | 'mount' -type RestrictTName = unknown extends TFormData +export type RestrictTName = unknown extends TFormData ? string : DeepKeys diff --git a/packages/react-form/src/types.ts b/packages/react-form/src/types.ts index fc3f96205..6528ad996 100644 --- a/packages/react-form/src/types.ts +++ b/packages/react-form/src/types.ts @@ -1,10 +1,11 @@ -import type { FieldOptions, DeepKeys } from '@tanstack/form-core' +import type { FieldOptions, RestrictTName } from '@tanstack/form-core' export type UseFieldOptions< - TData, + _TData, TFormData, ValidatorType, - TName = unknown extends TFormData ? string : DeepKeys, -> = FieldOptions & { + TName extends RestrictTName, + TData, +> = FieldOptions<_TData, TFormData, ValidatorType, TName, TData> & { mode?: 'value' | 'array' } diff --git a/packages/react-form/src/useField.tsx b/packages/react-form/src/useField.tsx index 6032a9cf6..07495eef2 100644 --- a/packages/react-form/src/useField.tsx +++ b/packages/react-form/src/useField.tsx @@ -4,7 +4,7 @@ import type { DeepKeys, DeepValue, FieldApiOptions, - Narrow, + RestrictTName, } from '@tanstack/form-core' import { FieldApi, functionalUpdate } from '@tanstack/form-core' import { useFormContext, formContext } from './formContext' @@ -13,32 +13,27 @@ import type { UseFieldOptions } from './types' declare module '@tanstack/form-core' { // eslint-disable-next-line no-shadow - interface FieldApi { + interface FieldApi<_TData, TFormData, ValidatorType, TName, TData> { Field: FieldComponent } } export type UseField = < - TField extends DeepKeys, + _TData extends DeepKeys, ValidatorType, + TName extends RestrictTName, + TData = unknown extends _TData ? DeepValue : _TData, >( - opts?: { name: Narrow } & UseFieldOptions< - DeepValue, - TFormData, - ValidatorType - >, -) => FieldApi, TFormData, ValidatorType> + opts?: UseFieldOptions<_TData, TFormData, ValidatorType, TName, TData>, +) => FieldApi<_TData, TFormData, ValidatorType, TName, TData> export function useField< - TData, + _TData, TFormData, ValidatorType, - TName extends unknown extends TFormData - ? string - : DeepKeys = unknown extends TFormData - ? string - : DeepKeys, ->(opts: UseFieldOptions) { + TName extends RestrictTName, + TData = unknown extends _TData ? DeepValue : _TData, +>(opts: UseFieldOptions<_TData, TFormData, ValidatorType, TName, TData>) { // Get the form API either manually or from context const { formApi, parentFieldName } = useFormContext() @@ -54,7 +49,8 @@ export function useField< const api = new FieldApi({ ...opts, form: formApi, - name: name as TName, + // TODO: Fix typings to include `index` and `parentFieldName`, if present + name: name as typeof opts.name, }) api.Field = Field as never @@ -87,17 +83,14 @@ export function useField< type FieldComponentProps< TParentData, TFormData, - TField, + _TData, ValidatorType, - TName extends unknown extends TFormData ? string : DeepKeys, + TName extends RestrictTName, + TData = unknown extends _TData ? DeepValue : _TData, > = { validator?: ValidatorType children: ( - fieldApi: FieldApi< - TField, - TFormData, - FieldApiOptions - >, + fieldApi: FieldApi<_TData, TFormData, ValidatorType, TName, TData>, ) => any } & (TParentData extends any[] ? { @@ -109,7 +102,7 @@ type FieldComponentProps< index?: never }) & Omit< - UseFieldOptions, + UseFieldOptions<_TData, TFormData, ValidatorType, TName, TData>, 'name' | 'index' | 'validator' > @@ -130,12 +123,20 @@ export type FieldComponent = < TName >) => any -export function Field({ +export function Field< + _TData, + TFormData, + ValidatorType, + TName extends RestrictTName, + TData = unknown extends _TData ? DeepValue : _TData, +>({ children, ...fieldOptions }: { - children: (fieldApi: FieldApi) => any -} & UseFieldOptions) { + children: ( + fieldApi: FieldApi<_TData, TFormData, ValidatorType, TName, TData>, + ) => any +} & UseFieldOptions<_TData, TFormData, ValidatorType, TName, TData>) { const fieldApi = useField(fieldOptions as any) return ( From 1a1521e6faed37818cfd5fa38f7ee812bab5ddf7 Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Mon, 11 Sep 2023 12:01:42 -0700 Subject: [PATCH 14/37] chore: fix Vue types --- packages/react-form/src/useField.tsx | 15 +-- packages/vue-form/src/tests/useField.test.tsx | 10 +- packages/vue-form/src/tests/useForm.test.tsx | 6 +- packages/vue-form/src/types.ts | 9 +- packages/vue-form/src/useField.tsx | 94 +++++++++---------- 5 files changed, 67 insertions(+), 67 deletions(-) diff --git a/packages/react-form/src/useField.tsx b/packages/react-form/src/useField.tsx index 07495eef2..9133e20a6 100644 --- a/packages/react-form/src/useField.tsx +++ b/packages/react-form/src/useField.tsx @@ -88,7 +88,6 @@ type FieldComponentProps< TName extends RestrictTName, TData = unknown extends _TData ? DeepValue : _TData, > = { - validator?: ValidatorType children: ( fieldApi: FieldApi<_TData, TFormData, ValidatorType, TName, TData>, ) => any @@ -103,24 +102,26 @@ type FieldComponentProps< }) & Omit< UseFieldOptions<_TData, TFormData, ValidatorType, TName, TData>, - 'name' | 'index' | 'validator' + 'name' | 'index' > export type FieldComponent = < // Type of the field - TField, - // Name of the field - TName extends unknown extends TFormData ? string : DeepKeys, + _TData, ValidatorType, + // Name of the field + TName extends RestrictTName, + TData = unknown extends _TData ? DeepValue : _TData, >({ children, ...fieldOptions }: FieldComponentProps< TParentData, TFormData, - TField, + _TData, ValidatorType, - TName + TName, + TData >) => any export function Field< diff --git a/packages/vue-form/src/tests/useField.test.tsx b/packages/vue-form/src/tests/useField.test.tsx index 5a3fb7072..797690046 100644 --- a/packages/vue-form/src/tests/useField.test.tsx +++ b/packages/vue-form/src/tests/useField.test.tsx @@ -30,7 +30,7 @@ describe('useField', () => { return () => ( - {({ field }: { field: FieldApi }) => ( + {({ field }: { field: FieldApi }) => ( { name="firstName" onChange={(value) => (value === 'other' ? error : undefined)} > - {({ field }: { field: FieldApi }) => ( + {({ field }: { field: FieldApi }) => (
{ name="firstName" onChange={(value) => (value === 'other' ? error : undefined)} > - {({ field }: { field: FieldApi }) => ( + {({ field }: { field: FieldApi }) => (
{ return error }} > - {({ field }: { field: FieldApi }) => ( + {({ field }: { field: FieldApi }) => (
{ return error }} > - {({ field }: { field: FieldApi }) => ( + {({ field }: { field: FieldApi }) => (
{ return () => ( - {({ field }: { field: FieldApi }) => ( + {({ field }: { field: FieldApi }) => ( { return () => ( - {({ field }: { field: FieldApi }) => ( + {({ field }: { field: FieldApi }) => (

{field.state.value}

)}
@@ -101,7 +101,7 @@ describe('useForm', () => { {({ field, }: { - field: FieldApi + field: FieldApi }) => { return ( , -> = FieldOptions & { + TName extends RestrictTName, + TData, +> = FieldOptions<_TData, TFormData, ValidatorType, TName, TData> & { mode?: 'value' | 'array' } diff --git a/packages/vue-form/src/useField.tsx b/packages/vue-form/src/useField.tsx index 0e2ce588e..e308bc512 100644 --- a/packages/vue-form/src/useField.tsx +++ b/packages/vue-form/src/useField.tsx @@ -2,6 +2,7 @@ import { FieldApi, type FieldApiOptions, type FormApi, + RestrictTName, } from '@tanstack/form-core' import type { DeepKeys, DeepValue, Narrow } from '@tanstack/form-core' import { useStore } from '@tanstack/vue-store' @@ -12,36 +13,33 @@ import type { UseFieldOptions } from './types' declare module '@tanstack/form-core' { // eslint-disable-next-line no-shadow - interface FieldApi { + interface FieldApi<_TData, TFormData, ValidatorType, TName, TData> { Field: FieldComponent } } export type UseField = < - TField extends DeepKeys, + _TData extends DeepKeys, ValidatorType, + TName extends RestrictTName, + TData = unknown extends _TData ? DeepValue : _TData, >( - opts?: { name: Narrow } & UseFieldOptions< - DeepValue, - TFormData, - ValidatorType - >, -) => FieldApi, TFormData, ValidatorType> + opts?: UseFieldOptions<_TData, TFormData, ValidatorType, TName, TData>, +) => FieldApi<_TData, TFormData, ValidatorType, TName, TData> export function useField< - TData, + _TData, TFormData, ValidatorType, - TName extends unknown extends TFormData - ? string - : DeepKeys = unknown extends TFormData - ? string - : DeepKeys, + TName extends RestrictTName, + TData = unknown extends _TData ? DeepValue : _TData, >( - opts: UseFieldOptions, + opts: UseFieldOptions<_TData, TFormData, ValidatorType, TName, TData>, ): { - api: FieldApi - state: Readonly['state']>> + api: FieldApi<_TData, TFormData, ValidatorType, TName, TData> + state: Readonly< + Ref['state']> + > } { // Get the form API either manually or from context const { formApi, parentFieldName } = useFormContext() @@ -58,7 +56,8 @@ export function useField< const api = new FieldApi({ ...opts, form: formApi, - name: name as TName, + // TODO: Fix typings to include `index` and `parentFieldName`, if present + name: name as typeof opts.name, }) api.Field = Field as never @@ -88,21 +87,14 @@ export function useField< return { api: fieldApi, state: fieldState } } -export type FieldValue = TFormData extends any[] - ? unknown extends TField - ? TFormData[number] - : DeepValue - : DeepValue - type FieldComponentProps< TParentData, TFormData, - TField, + _TData, ValidatorType, - TName extends unknown extends TFormData ? string : DeepKeys, -> = { - validator?: ValidatorType -} & (TParentData extends any[] + TName extends RestrictTName, + TData = unknown extends _TData ? DeepValue : _TData, +> = (TParentData extends any[] ? { name?: TName index: number @@ -112,46 +104,52 @@ type FieldComponentProps< index?: never }) & Omit< - UseFieldOptions, - 'name' | 'index' | 'validator' + UseFieldOptions<_TData, TFormData, ValidatorType, TName, TData>, + 'name' | 'index' > export type FieldComponent = < // Type of the field - TField, - // Name of the field - TName extends unknown extends TFormData ? string : DeepKeys, + _TData, ValidatorType, + // Name of the field + TName extends RestrictTName, + TData = unknown extends _TData ? DeepValue : _TData, >( fieldOptions: FieldComponentProps< TParentData, TFormData, - TField, + _TData, ValidatorType, - TName + TName, + TData >, context: SetupContext< {}, SlotsType<{ default: { - field: FieldApi< - TField, - TFormData, - FieldApiOptions - > - state: FieldApi< - TField, - TFormData, - FieldApiOptions - >['state'] + field: FieldApi<_TData, TFormData, ValidatorType, TName, TData> + state: FieldApi<_TData, TFormData, ValidatorType, TName, TData>['state'] } }> >, ) => any export const Field = defineComponent( - ( - fieldOptions: UseFieldOptions, + < + _TData, + TFormData, + ValidatorType, + TName extends RestrictTName, + TData = unknown extends _TData ? DeepValue : _TData, + >( + fieldOptions: UseFieldOptions< + _TData, + TFormData, + ValidatorType, + TName, + TData + >, context: SetupContext, ) => { const fieldApi = useField({ ...fieldOptions, ...context.attrs }) From b2c4b412ebe8a3bc63b36ee257d4949ead0ddc32 Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Mon, 11 Sep 2023 12:21:54 -0700 Subject: [PATCH 15/37] chore: fix typing issues --- examples/vue/simple/src/App.vue | 2 +- packages/form-core/src/FormApi.ts | 8 ++++++-- packages/vue-form/src/useField.tsx | 2 +- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/examples/vue/simple/src/App.vue b/examples/vue/simple/src/App.vue index c2ab63609..10415e513 100644 --- a/examples/vue/simple/src/App.vue +++ b/examples/vue/simple/src/App.vue @@ -34,7 +34,7 @@ async function onChangeFirstName(value: string) {
!value ? `A first name is required` diff --git a/packages/form-core/src/FormApi.ts b/packages/form-core/src/FormApi.ts index f1ff8f9f6..30540bf0f 100644 --- a/packages/form-core/src/FormApi.ts +++ b/packages/form-core/src/FormApi.ts @@ -336,7 +336,9 @@ export class FormApi { pushFieldValue = >( field: TField, - value: DeepValue[number], + value: DeepValue extends any[] + ? DeepValue[number] + : never, opts?: { touch?: boolean }, ) => { return this.setFieldValue( @@ -349,7 +351,9 @@ export class FormApi { insertFieldValue = >( field: TField, index: number, - value: DeepValue[number], + value: DeepValue extends any[] + ? DeepValue[number] + : never, opts?: { touch?: boolean }, ) => { this.setFieldValue( diff --git a/packages/vue-form/src/useField.tsx b/packages/vue-form/src/useField.tsx index e308bc512..a5743fc30 100644 --- a/packages/vue-form/src/useField.tsx +++ b/packages/vue-form/src/useField.tsx @@ -140,7 +140,7 @@ export const Field = defineComponent( _TData, TFormData, ValidatorType, - TName extends RestrictTName, + TName extends RestrictTName = RestrictTName, TData = unknown extends _TData ? DeepValue : _TData, >( fieldOptions: UseFieldOptions< From 5a4db83f6a8b823cf9d1cac5dd7d5dd362377370 Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Mon, 11 Sep 2023 12:38:59 -0700 Subject: [PATCH 16/37] chore: fix various linting items --- packages/form-core/src/FieldApi.ts | 8 ++++---- packages/form-core/src/tests/FieldApi.test-d.ts | 2 +- packages/form-core/src/tests/FormApi.spec.ts | 2 +- packages/vue-form/src/useField.tsx | 9 ++------- 4 files changed, 8 insertions(+), 13 deletions(-) diff --git a/packages/form-core/src/FieldApi.ts b/packages/form-core/src/FieldApi.ts index f15b7f3fe..982e4573d 100644 --- a/packages/form-core/src/FieldApi.ts +++ b/packages/form-core/src/FieldApi.ts @@ -33,12 +33,12 @@ type ValidateOrFn< type ValidateAsyncFn< _TData, TFormData, - Validator, + ValidatorType, TName extends RestrictTName, TData, > = ( value: TData, - fieldApi: FieldApi<_TData, TFormData, Validator, TName, TData>, + fieldApi: FieldApi<_TData, TFormData, ValidatorType, TName, TData>, ) => ValidationError | Promise export interface FieldOptions< @@ -274,8 +274,8 @@ export class FieldApi< swapValues = (aIndex: number, bIndex: number) => this.form.swapFieldValues(this.name, aIndex, bIndex) - getSubField = >(name: TName) => - new FieldApi, TFormData, ValidatorType>({ + getSubField = >(name: SubTName) => + new FieldApi, TFormData, ValidatorType>({ name: `${this.name}.${name}` as never, form: this.form, }) diff --git a/packages/form-core/src/tests/FieldApi.test-d.ts b/packages/form-core/src/tests/FieldApi.test-d.ts index 0d4b1c850..be9e037f1 100644 --- a/packages/form-core/src/tests/FieldApi.test-d.ts +++ b/packages/form-core/src/tests/FieldApi.test-d.ts @@ -2,7 +2,7 @@ import { assertType } from 'vitest' import { FormApi } from '../FormApi' import { FieldApi } from '../FieldApi' import { zodValidator } from '../zod-validator' -import z from 'zod' +import { z } from 'zod' it('should type value properly', () => { const form = new FormApi({ diff --git a/packages/form-core/src/tests/FormApi.spec.ts b/packages/form-core/src/tests/FormApi.spec.ts index 7e15ea399..9d8fdaf4f 100644 --- a/packages/form-core/src/tests/FormApi.spec.ts +++ b/packages/form-core/src/tests/FormApi.spec.ts @@ -119,7 +119,7 @@ describe('form api', () => { }, }) - form.pushFieldValue('name', 'other') + form.setFieldValue('name', 'other') form.state.submissionAttempts = 300 form.reset() diff --git a/packages/vue-form/src/useField.tsx b/packages/vue-form/src/useField.tsx index a5743fc30..bf6bbd455 100644 --- a/packages/vue-form/src/useField.tsx +++ b/packages/vue-form/src/useField.tsx @@ -1,10 +1,5 @@ -import { - FieldApi, - type FieldApiOptions, - type FormApi, - RestrictTName, -} from '@tanstack/form-core' -import type { DeepKeys, DeepValue, Narrow } from '@tanstack/form-core' +import { FieldApi, type RestrictTName } from '@tanstack/form-core' +import type { DeepKeys, DeepValue } from '@tanstack/form-core' import { useStore } from '@tanstack/vue-store' import { defineComponent, onMounted, onUnmounted, watch } from 'vue-demi' import type { SlotsType, SetupContext, Ref } from 'vue-demi' From 402d0e950a9393959ae5386c372a4913861cd407 Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Mon, 11 Sep 2023 12:56:25 -0700 Subject: [PATCH 17/37] chore: fix ESlint and validation logic --- packages/form-core/src/FieldApi.ts | 21 ++------- packages/form-core/src/zod-validator.ts | 61 +++++++++++-------------- 2 files changed, 32 insertions(+), 50 deletions(-) diff --git a/packages/form-core/src/FieldApi.ts b/packages/form-core/src/FieldApi.ts index 982e4573d..161f0db4d 100644 --- a/packages/form-core/src/FieldApi.ts +++ b/packages/form-core/src/FieldApi.ts @@ -280,25 +280,11 @@ export class FieldApi< form: this.form, }) - getValidateTransformer = () => { - const isValidator = ( - item: unknown, - ): item is Validator< - TData, - typeof this.options.onBlur | typeof this.options.onChange - > => - !!item && typeof item === 'function' && (item as any).isValidator === true - - return isValidator(this.options.validator) ? this.options.validator() : null - } - validateSync = (value = this.state.value, cause: ValidationCause) => { const { onChange, onBlur } = this.options const validate = cause === 'submit' ? undefined : cause === 'change' ? onChange : onBlur - const validateTransformer = this.getValidateTransformer() - if (!validate) return // Use the validationCount for all field instances to @@ -307,8 +293,11 @@ export class FieldApi< this.getInfo().validationCount = validationCount const doValidate = () => { - if (validateTransformer) { - return validateTransformer.validate(value, validate) + if (this.options.validator) { + return (this.options.validator as Validator)().validate( + value, + validate, + ) } return ( diff --git a/packages/form-core/src/zod-validator.ts b/packages/form-core/src/zod-validator.ts index 13edc7316..514bee503 100644 --- a/packages/form-core/src/zod-validator.ts +++ b/packages/form-core/src/zod-validator.ts @@ -1,40 +1,33 @@ import type { ZodError, ZodType, ZodTypeAny } from 'zod' import type { ValidationError } from './FormApi' -export type Validator = { - // If/when TypeScript supports higher-kinded types, this should not be `unknown` anymore - (): { - validate(value: Type, fn: Fn): ValidationError - validateAsync(value: Type, fn: Fn): Promise - } - isValidator: boolean +// If/when TypeScript supports higher-kinded types, this should not be `unknown` anymore +export type Validator = () => { + validate(value: Type, fn: Fn): ValidationError + validateAsync(value: Type, fn: Fn): Promise } -export const zodValidator = (() => { - const fn = = ZodType>() => { - return { - validate(value: unknown, fn: Fn): ValidationError { - // Call Zod on the value here and return the error message - try { - ;(fn as ZodTypeAny).parse(value) - return - } catch (_e) { - const e = _e as ZodError - return e.toString() - } - }, - async validateAsync(value: unknown, fn: Fn): Promise { - // Call Zod on the value here and return the error message - try { - await (fn as ZodTypeAny).parseAsync(value) - return - } catch (_e) { - const e = _e as ZodError - return e.toString() - } - }, - } +export const zodValidator = ( = ZodType>() => { + return { + validate(value: unknown, fn: Fn): ValidationError { + // Call Zod on the value here and return the error message + try { + ;(fn as ZodTypeAny).parse(value) + return + } catch (_e) { + const e = _e as ZodError + return e.toString() + } + }, + async validateAsync(value: unknown, fn: Fn): Promise { + // Call Zod on the value here and return the error message + try { + await (fn as ZodTypeAny).parseAsync(value) + return + } catch (_e) { + const e = _e as ZodError + return e.toString() + } + }, } - fn.isValidator = true - return fn -})() satisfies Validator +}) satisfies Validator From 9c3fb94badbf27aeef5ac5d7250f19202d7072f6 Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Tue, 17 Oct 2023 02:11:40 -0700 Subject: [PATCH 18/37] chore: fix inferencing from formdata --- packages/form-core/src/FieldApi.ts | 52 ++++++++-- packages/form-core/src/FormApi.ts | 97 +++++++++++-------- .../form-core/src/tests/FormApi.test-d.ts | 76 +++++++++++++++ 3 files changed, 175 insertions(+), 50 deletions(-) create mode 100644 packages/form-core/src/tests/FormApi.test-d.ts diff --git a/packages/form-core/src/FieldApi.ts b/packages/form-core/src/FieldApi.ts index 6c8dfccea..0be6abeb1 100644 --- a/packages/form-core/src/FieldApi.ts +++ b/packages/form-core/src/FieldApi.ts @@ -19,15 +19,19 @@ type ValidateOrFn< TParentData, TName extends DeepKeys, ValidatorType, + FormValidator, TData, > = ValidatorType extends Validator ? Parameters['validate']>[1] + : FormValidator extends Validator + ? Parameters['validate']>[1] : ValidateFn type ValidateAsyncFn< TParentData, TName extends DeepKeys, ValidatorType, + FormValidator, TData, > = ( value: TData, @@ -38,9 +42,10 @@ export interface FieldOptions< TParentData, TName extends DeepKeys, ValidatorType, + FormValidator, TData = DeepValue, > { - name: DeepKeys + name: TName index?: TData extends any[] ? number : never defaultValue?: TData asyncDebounceMs?: number @@ -49,13 +54,37 @@ export interface FieldOptions< onMount?: ( formApi: FieldApi, ) => void - onChange?: ValidateOrFn - onChangeAsync?: ValidateAsyncFn + onChange?: ValidateOrFn< + TParentData, + TName, + ValidatorType, + FormValidator, + TData + > + onChangeAsync?: ValidateAsyncFn< + TParentData, + TName, + ValidatorType, + FormValidator, + TData + > onChangeAsyncDebounceMs?: number - onBlur?: ValidateOrFn - onBlurAsync?: ValidateAsyncFn + onBlur?: ValidateOrFn + onBlurAsync?: ValidateAsyncFn< + TParentData, + TName, + ValidatorType, + FormValidator, + TData + > onBlurAsyncDebounceMs?: number - onSubmitAsync?: ValidateAsyncFn + onSubmitAsync?: ValidateAsyncFn< + TParentData, + TName, + ValidatorType, + FormValidator, + TData + > defaultMeta?: Partial } @@ -63,9 +92,16 @@ export interface FieldApiOptions< TParentData, TName extends DeepKeys, ValidatorType, + FormValidator, TData = DeepValue, -> extends FieldOptions { - form: FormApi +> extends FieldOptions< + TParentData, + TName, + ValidatorType, + FormValidator, + TData + > { + form: FormApi } export type FieldMeta = { diff --git a/packages/form-core/src/FormApi.ts b/packages/form-core/src/FormApi.ts index 030e0024d..466176453 100644 --- a/packages/form-core/src/FormApi.ts +++ b/packages/form-core/src/FormApi.ts @@ -1,37 +1,49 @@ import { Store } from '@tanstack/store' -// import type { DeepKeys, DeepValue, Updater } from './utils' import { functionalUpdate, getBy, isNonEmptyArray, setBy } from './utils' import type { FieldApi, FieldMeta, ValidationCause } from './FieldApi' +import { Validator } from './zod-validator' -export type FormOptions = { +type ValidateFn = ( + values: TData, + formApi: FormApi, +) => ValidationError + +type ValidateOrFn = ValidatorType extends Validator + ? Parameters['validate']>[1] + : ValidateFn + +type ValidateAsyncFn = ( + value: TData, + fieldApi: FormApi, +) => ValidationError | Promise + +export type FormOptions = { defaultValues?: TData defaultState?: Partial> asyncDebounceMs?: number - onMount?: (values: TData, formApi: FormApi) => ValidationError - onMountAsync?: ( - values: TData, - formApi: FormApi, - ) => ValidationError | Promise + validator?: ValidatorType + onMount?: ValidateOrFn + onMountAsync?: ValidateAsyncFn onMountAsyncDebounceMs?: number - onChange?: (values: TData, formApi: FormApi) => ValidationError - onChangeAsync?: ( - values: TData, - formApi: FormApi, - ) => ValidationError | Promise + onChange?: ValidateOrFn + onChangeAsync?: ValidateAsyncFn onChangeAsyncDebounceMs?: number - onBlur?: (values: TData, formApi: FormApi) => ValidationError - onBlurAsync?: ( - values: TData, - formApi: FormApi, - ) => ValidationError | Promise + onBlur?: ValidateOrFn + onBlurAsync?: ValidateAsyncFn onBlurAsyncDebounceMs?: number - onSubmit?: (values: TData, formApi: FormApi) => any | Promise - onSubmitInvalid?: (values: TData, formApi: FormApi) => void + onSubmit?: ( + values: TData, + formApi: FormApi, + ) => any | Promise + onSubmitInvalid?: ( + values: TData, + formApi: FormApi, + ) => void } -export type FieldInfo = { - instances: Record> +export type FieldInfo = { + instances: Record> } & ValidationMeta export type ValidationMeta = { @@ -92,18 +104,19 @@ function getDefaultFormState( } } -export class FormApi { +export class FormApi { // // This carries the context for nested fields - options: FormOptions = {} + options: FormOptions = {} store!: Store> // Do not use __state directly, as it is not reactive. // Please use form.useStore() utility to subscribe to state state!: FormState - fieldInfo: Record, FieldInfo> = {} as any + fieldInfo: Record, FieldInfo> = + {} as any fieldName?: string validationMeta: ValidationMeta = {} - constructor(opts?: FormOptions) { + constructor(opts?: FormOptions) { this.store = new Store>( getDefaultFormState({ ...(opts?.defaultState as any), @@ -157,7 +170,7 @@ export class FormApi { this.update(opts || {}) } - update = (options?: FormOptions) => { + update = (options?: FormOptions) => { if (!options) return this.store.batch(() => { @@ -202,21 +215,21 @@ export class FormApi { validateAllFields = async (cause: ValidationCause) => { const fieldValidationPromises: Promise[] = [] as any this.store.batch(() => { - void (Object.values(this.fieldInfo) as FieldInfo[]).forEach( - (field) => { - Object.values(field.instances).forEach((instance) => { - // If any fields are not touched - if (!instance.state.meta.isTouched) { - // Mark them as touched - instance.setMeta((prev) => ({ ...prev, isTouched: true })) - // Validate the field - fieldValidationPromises.push( - Promise.resolve().then(() => instance.validate(cause)), - ) - } - }) - }, - ) + void ( + Object.values(this.fieldInfo) as FieldInfo[] + ).forEach((field) => { + Object.values(field.instances).forEach((instance) => { + // If any fields are not touched + if (!instance.state.meta.isTouched) { + // Mark them as touched + instance.setMeta((prev) => ({ ...prev, isTouched: true })) + // Validate the field + fieldValidationPromises.push( + Promise.resolve().then(() => instance.validate(cause)), + ) + } + }) + }) }) return Promise.all(fieldValidationPromises) @@ -290,7 +303,7 @@ export class FormApi { getFieldInfo = >( field: TField, - ): FieldInfo => { + ): FieldInfo => { // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition return (this.fieldInfo[field] ||= { instances: {}, diff --git a/packages/form-core/src/tests/FormApi.test-d.ts b/packages/form-core/src/tests/FormApi.test-d.ts new file mode 100644 index 000000000..39365492b --- /dev/null +++ b/packages/form-core/src/tests/FormApi.test-d.ts @@ -0,0 +1,76 @@ +import { assertType } from 'vitest' +import { FormApi } from '../FormApi' +import { FieldApi } from '../FieldApi' +import { zodValidator } from '../zod-validator' +import { z } from 'zod' + +it('should allow a Zod validator to be passed in', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + validator: zodValidator, + } as const) +}) + +it('should allow a Zod validator to handle the correct Zod type', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + validator: zodValidator, + }) + + const field = new FieldApi({ + form, + name: 'name', + onChange: z.string(), + } as const) +}) + +it('should not allow a functional onChange to be passed when using a validator', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + validator: zodValidator, + }) + + const field = new FieldApi({ + form, + name: 'name', + // @ts-expect-error Is not of type validator + onChange: (val) => null, + } as const) +}) + +it('should not allow a validator onChange to be passed when not using a validator', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + }) + + const field = new FieldApi({ + form, + name: 'name', + // @ts-expect-error Requires a validator + onChange: z.string(), + } as const) +}) + +// This is not possible without higher-kinded types AFAIK +it.skip('should allow not a Zod validator with the wrong Zod type', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + }) + + const field = new FieldApi({ + form, + name: 'name', + validator: zodValidator, + onChange: z.object({}), + } as const) +}) From 47737ec84b68198a3fe4715982da87b60dcd2d77 Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Tue, 17 Oct 2023 02:18:41 -0700 Subject: [PATCH 19/37] chore: fix form inferencing --- packages/form-core/src/FieldApi.ts | 19 ++++++++++--------- packages/form-core/src/FormApi.ts | 4 ++-- packages/form-core/src/tests/FieldApi.spec.ts | 2 +- 3 files changed, 13 insertions(+), 12 deletions(-) diff --git a/packages/form-core/src/FieldApi.ts b/packages/form-core/src/FieldApi.ts index 0be6abeb1..89b6b3a05 100644 --- a/packages/form-core/src/FieldApi.ts +++ b/packages/form-core/src/FieldApi.ts @@ -9,7 +9,7 @@ type ValidateFn< TParentData, TName extends DeepKeys, ValidatorType, - TData, + TData extends DeepValue = DeepValue, > = ( value: TData, fieldApi: FieldApi, @@ -20,7 +20,7 @@ type ValidateOrFn< TName extends DeepKeys, ValidatorType, FormValidator, - TData, + TData extends DeepValue = DeepValue, > = ValidatorType extends Validator ? Parameters['validate']>[1] : FormValidator extends Validator @@ -32,7 +32,7 @@ type ValidateAsyncFn< TName extends DeepKeys, ValidatorType, FormValidator, - TData, + TData extends DeepValue = DeepValue, > = ( value: TData, fieldApi: FieldApi, @@ -43,7 +43,7 @@ export interface FieldOptions< TName extends DeepKeys, ValidatorType, FormValidator, - TData = DeepValue, + TData extends DeepValue = DeepValue, > { name: TName index?: TData extends any[] ? number : never @@ -93,7 +93,7 @@ export interface FieldApiOptions< TName extends DeepKeys, ValidatorType, FormValidator, - TData = DeepValue, + TData extends DeepValue = DeepValue, > extends FieldOptions< TParentData, TName, @@ -127,7 +127,8 @@ export class FieldApi< TParentData, TName extends DeepKeys, ValidatorType, - TData = DeepValue, + FormValidator, + TData extends DeepValue = DeepValue, > { uid: number form: FieldApiOptions['form'] @@ -137,8 +138,8 @@ export class FieldApi< state!: FieldState prevState!: FieldState - constructor(opts: FieldApiOptions) { - this.form = opts.form + constructor(opts: FieldApiOptions) { + this.form = opts.form as never this.uid = uid++ // Support field prefixing from FieldScope // let fieldPrefix = '' @@ -282,7 +283,7 @@ export class FieldApi< getSubField = < TSubName extends DeepKeys, - TSubData = DeepValue, + TSubData extends DeepValue = DeepValue, >( name: TSubName, ): FieldApi => diff --git a/packages/form-core/src/FormApi.ts b/packages/form-core/src/FormApi.ts index 466176453..8e4df0c9f 100644 --- a/packages/form-core/src/FormApi.ts +++ b/packages/form-core/src/FormApi.ts @@ -2,7 +2,7 @@ import { Store } from '@tanstack/store' import type { DeepKeys, DeepValue, Updater } from './utils' import { functionalUpdate, getBy, isNonEmptyArray, setBy } from './utils' import type { FieldApi, FieldMeta, ValidationCause } from './FieldApi' -import { Validator } from './zod-validator' +import type { Validator } from './zod-validator' type ValidateFn = ( values: TData, @@ -43,7 +43,7 @@ export type FormOptions = { } export type FieldInfo = { - instances: Record> + instances: Record> } & ValidationMeta export type ValidationMeta = { diff --git a/packages/form-core/src/tests/FieldApi.spec.ts b/packages/form-core/src/tests/FieldApi.spec.ts index c961ef2ac..533798d09 100644 --- a/packages/form-core/src/tests/FieldApi.spec.ts +++ b/packages/form-core/src/tests/FieldApi.spec.ts @@ -535,7 +535,7 @@ describe('field api', () => { interface Form { name: string } - const form = new FormApi
() + const form = new FormApi() const field = new FieldApi({ form, From b51e6bdde1a304eef19b4cf198744cc4ea2c364b Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Tue, 17 Oct 2023 02:30:25 -0700 Subject: [PATCH 20/37] chore: fix React TS types to match form validator logic --- packages/react-form/src/createFormFactory.ts | 16 ++--- packages/react-form/src/formContext.ts | 2 +- .../src/tests/createFormFactory.test.tsx | 2 +- .../react-form/src/tests/useField.test.tsx | 14 ++--- .../react-form/src/tests/useForm.test.tsx | 4 +- packages/react-form/src/types.ts | 5 +- packages/react-form/src/useField.tsx | 60 ++++++++++++++----- packages/react-form/src/useForm.tsx | 8 ++- 8 files changed, 73 insertions(+), 38 deletions(-) diff --git a/packages/react-form/src/createFormFactory.ts b/packages/react-form/src/createFormFactory.ts index 44113cce0..3003574fc 100644 --- a/packages/react-form/src/createFormFactory.ts +++ b/packages/react-form/src/createFormFactory.ts @@ -3,19 +3,21 @@ import type { FormApi, FormOptions } from '@tanstack/form-core' import { type UseField, type FieldComponent, Field, useField } from './useField' import { useForm } from './useForm' -export type FormFactory = { - useForm: (opts?: FormOptions) => FormApi +export type FormFactory = { + useForm: ( + opts?: FormOptions, + ) => FormApi useField: UseField - Field: FieldComponent + Field: FieldComponent } -export function createFormFactory( - defaultOpts?: FormOptions, -): FormFactory { +export function createFormFactory( + defaultOpts?: FormOptions, +): FormFactory { return { useForm: (opts) => { const formOptions = Object.assign({}, defaultOpts, opts) - return useForm(formOptions) + return useForm(formOptions) }, useField: useField as any, Field: Field as any, diff --git a/packages/react-form/src/formContext.ts b/packages/react-form/src/formContext.ts index a60abb456..c2403b326 100644 --- a/packages/react-form/src/formContext.ts +++ b/packages/react-form/src/formContext.ts @@ -2,7 +2,7 @@ import type { FormApi } from '@tanstack/form-core' import * as React from 'react' export const formContext = React.createContext<{ - formApi: FormApi + formApi: FormApi parentFieldName?: string } | null>(null!) diff --git a/packages/react-form/src/tests/createFormFactory.test.tsx b/packages/react-form/src/tests/createFormFactory.test.tsx index d8648cd21..752d6a715 100644 --- a/packages/react-form/src/tests/createFormFactory.test.tsx +++ b/packages/react-form/src/tests/createFormFactory.test.tsx @@ -11,7 +11,7 @@ describe('createFormFactory', () => { lastName: string } - const formFactory = createFormFactory({ + const formFactory = createFormFactory({ defaultValues: { firstName: 'FirstName', lastName: 'LastName', diff --git a/packages/react-form/src/tests/useField.test.tsx b/packages/react-form/src/tests/useField.test.tsx index 4e77ba83c..6adebcbf8 100644 --- a/packages/react-form/src/tests/useField.test.tsx +++ b/packages/react-form/src/tests/useField.test.tsx @@ -15,7 +15,7 @@ describe('useField', () => { lastName: string } - const formFactory = createFormFactory() + const formFactory = createFormFactory() function Comp() { const form = formFactory.useForm() @@ -52,7 +52,7 @@ describe('useField', () => { } const error = 'Please enter a different value' - const formFactory = createFormFactory() + const formFactory = createFormFactory() function Comp() { const form = formFactory.useForm() @@ -92,7 +92,7 @@ describe('useField', () => { } const error = 'Please enter a different value' - const formFactory = createFormFactory() + const formFactory = createFormFactory() function Comp() { const form = formFactory.useForm() @@ -135,7 +135,7 @@ describe('useField', () => { const onChangeError = 'Please enter a different value (onChangeError)' const onBlurError = 'Please enter a different value (onBlurError)' - const formFactory = createFormFactory() + const formFactory = createFormFactory() function Comp() { const form = formFactory.useForm() @@ -184,7 +184,7 @@ describe('useField', () => { } const error = 'Please enter a different value' - const formFactory = createFormFactory() + const formFactory = createFormFactory() function Comp() { const form = formFactory.useForm() @@ -231,7 +231,7 @@ describe('useField', () => { const onChangeError = 'Please enter a different value (onChangeError)' const onBlurError = 'Please enter a different value (onBlurError)' - const formFactory = createFormFactory() + const formFactory = createFormFactory() function Comp() { const form = formFactory.useForm() @@ -287,7 +287,7 @@ describe('useField', () => { } const mockFn = vi.fn() const error = 'Please enter a different value' - const formFactory = createFormFactory() + const formFactory = createFormFactory() function Comp() { const form = formFactory.useForm() diff --git a/packages/react-form/src/tests/useForm.test.tsx b/packages/react-form/src/tests/useForm.test.tsx index 8ba5efe97..8318b35ba 100644 --- a/packages/react-form/src/tests/useForm.test.tsx +++ b/packages/react-form/src/tests/useForm.test.tsx @@ -14,7 +14,7 @@ describe('useForm', () => { lastName: string } - const formFactory = createFormFactory() + const formFactory = createFormFactory() function Comp() { const form = formFactory.useForm() @@ -52,7 +52,7 @@ describe('useForm', () => { lastName: string } - const formFactory = createFormFactory() + const formFactory = createFormFactory() function Comp() { const form = formFactory.useForm({ diff --git a/packages/react-form/src/types.ts b/packages/react-form/src/types.ts index 956255df9..81dbe6fdd 100644 --- a/packages/react-form/src/types.ts +++ b/packages/react-form/src/types.ts @@ -4,7 +4,8 @@ export type UseFieldOptions< TParentData, TName extends DeepKeys, ValidatorType, - TData = DeepValue, -> = FieldOptions & { + FormValidator, + TData extends DeepValue = DeepValue, +> = FieldOptions & { mode?: 'value' | 'array' } diff --git a/packages/react-form/src/useField.tsx b/packages/react-form/src/useField.tsx index 3dafb3a2c..08a37f36a 100644 --- a/packages/react-form/src/useField.tsx +++ b/packages/react-form/src/useField.tsx @@ -12,33 +12,44 @@ declare module '@tanstack/form-core' { TParentData, TName extends DeepKeys, ValidatorType, - TData = DeepValue, + FormValidator, + TData extends DeepValue = DeepValue, > { - Field: FieldComponent + Field: FieldComponent } } export type UseField = < TName extends DeepKeys, ValidatorType, + FormValidator, >( opts?: { name: Narrow } & UseFieldOptions< TParentData, TName, - ValidatorType + ValidatorType, + FormValidator >, -) => FieldApi> +) => FieldApi< + TParentData, + TName, + ValidatorType, + FormValidator, + DeepValue +> export function useField< TParentData, TName extends DeepKeys, ValidatorType, + FormValidator, >( - opts: UseFieldOptions, + opts: UseFieldOptions, ): FieldApi< TParentData, TName, - ValidatorType + ValidatorType, + FormValidator // Omit & { // form: FormApi // } @@ -93,9 +104,12 @@ type FieldComponentProps< TParentData, TName extends DeepKeys, ValidatorType, - TData = DeepValue, + FormValidator, + TData extends DeepValue = DeepValue, > = { - children: (fieldApi: FieldApi) => any + children: ( + fieldApi: FieldApi, + ) => any } & (TParentData extends any[] ? { name?: TName @@ -105,31 +119,47 @@ type FieldComponentProps< name: TName index?: never }) & - Omit, 'name' | 'index'> + Omit< + UseFieldOptions, + 'name' | 'index' + > -export type FieldComponent = < +export type FieldComponent = < TName extends DeepKeys, - TData = DeepValue, + ValidatorType, + TData extends DeepValue = DeepValue, >({ children, ...fieldOptions -}: FieldComponentProps) => any +}: FieldComponentProps< + TParentData, + TName, + ValidatorType, + FormValidator, + TData +>) => any export function Field< TParentData, TName extends DeepKeys, ValidatorType, + FormValidator, >({ children, ...fieldOptions }: { - children: (fieldApi: FieldApi) => any -} & UseFieldOptions) { + children: ( + fieldApi: FieldApi, + ) => any +} & UseFieldOptions) { const fieldApi = useField(fieldOptions as any) return ( ) diff --git a/packages/react-form/src/useForm.tsx b/packages/react-form/src/useForm.tsx index b64c8b7d8..be10562a9 100644 --- a/packages/react-form/src/useForm.tsx +++ b/packages/react-form/src/useForm.tsx @@ -9,9 +9,9 @@ import useIsomorphicLayoutEffect from 'use-isomorphic-layout-effect' declare module '@tanstack/form-core' { // eslint-disable-next-line no-shadow - interface FormApi { + interface FormApi { Provider: (props: { children: any }) => any - Field: FieldComponent + Field: FieldComponent useField: UseField useStore: >>( selector?: (state: NoInfer>) => TSelected, @@ -23,7 +23,9 @@ declare module '@tanstack/form-core' { } } -export function useForm(opts?: FormOptions): FormApi { +export function useForm( + opts?: FormOptions, +): FormApi { const [formApi] = useState(() => { // @ts-ignore const api = new FormApi(opts) From 065c56743849ff3d15542ee01bd045b03f83d60a Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Tue, 17 Oct 2023 02:39:40 -0700 Subject: [PATCH 21/37] chore: fix Vue types --- examples/vue/simple/src/FieldInfo.vue | 2 +- packages/vue-form/src/createFormFactory.ts | 18 +++-- packages/vue-form/src/formContext.ts | 2 +- packages/vue-form/src/tests/useField.test.tsx | 20 ++--- packages/vue-form/src/tests/useForm.test.tsx | 20 +++-- packages/vue-form/src/types.ts | 5 +- packages/vue-form/src/useField.tsx | 76 +++++++++++++++---- packages/vue-form/src/useForm.tsx | 16 ++-- 8 files changed, 109 insertions(+), 50 deletions(-) diff --git a/examples/vue/simple/src/FieldInfo.vue b/examples/vue/simple/src/FieldInfo.vue index a5e5aaf92..997fd5ba6 100644 --- a/examples/vue/simple/src/FieldInfo.vue +++ b/examples/vue/simple/src/FieldInfo.vue @@ -2,7 +2,7 @@ import { FieldApi } from '@tanstack/vue-form' const props = defineProps<{ - state: FieldApi['state'] + state: FieldApi['state'] }>() diff --git a/packages/vue-form/src/createFormFactory.ts b/packages/vue-form/src/createFormFactory.ts index 44113cce0..f0c351c9c 100644 --- a/packages/vue-form/src/createFormFactory.ts +++ b/packages/vue-form/src/createFormFactory.ts @@ -3,19 +3,21 @@ import type { FormApi, FormOptions } from '@tanstack/form-core' import { type UseField, type FieldComponent, Field, useField } from './useField' import { useForm } from './useForm' -export type FormFactory = { - useForm: (opts?: FormOptions) => FormApi - useField: UseField - Field: FieldComponent +export type FormFactory = { + useForm: ( + opts?: FormOptions, + ) => FormApi + useField: UseField + Field: FieldComponent } -export function createFormFactory( - defaultOpts?: FormOptions, -): FormFactory { +export function createFormFactory( + defaultOpts?: FormOptions, +): FormFactory { return { useForm: (opts) => { const formOptions = Object.assign({}, defaultOpts, opts) - return useForm(formOptions) + return useForm(formOptions) }, useField: useField as any, Field: Field as any, diff --git a/packages/vue-form/src/formContext.ts b/packages/vue-form/src/formContext.ts index 69167068b..74044807b 100644 --- a/packages/vue-form/src/formContext.ts +++ b/packages/vue-form/src/formContext.ts @@ -2,7 +2,7 @@ import type { FormApi } from '@tanstack/form-core' import { inject, provide } from 'vue-demi' export type FormContext = { - formApi: FormApi + formApi: FormApi parentFieldName?: string } | null diff --git a/packages/vue-form/src/tests/useField.test.tsx b/packages/vue-form/src/tests/useField.test.tsx index 1a22b6081..90899dc92 100644 --- a/packages/vue-form/src/tests/useField.test.tsx +++ b/packages/vue-form/src/tests/useField.test.tsx @@ -21,7 +21,7 @@ describe('useField', () => { lastName: string } - const formFactory = createFormFactory() + const formFactory = createFormFactory() const Comp = defineComponent(() => { const form = formFactory.useForm() @@ -30,7 +30,7 @@ describe('useField', () => { return () => ( - {({ field }: { field: FieldApi }) => ( + {({ field }: { field: FieldApi }) => ( { } const error = 'Please enter a different value' - const formFactory = createFormFactory() + const formFactory = createFormFactory() const Comp = defineComponent(() => { const form = formFactory.useForm() @@ -68,7 +68,7 @@ describe('useField', () => { name="firstName" onChange={(value) => (value === 'other' ? error : undefined)} > - {({ field }: { field: FieldApi }) => ( + {({ field }: { field: FieldApi }) => (
{ } const error = 'Please enter a different value' - const formFactory = createFormFactory() + const formFactory = createFormFactory() const Comp = defineComponent(() => { const form = formFactory.useForm() @@ -111,7 +111,7 @@ describe('useField', () => { name="firstName" onChange={(value) => (value === 'other' ? error : undefined)} > - {({ field }: { field: FieldApi }) => ( + {({ field }: { field: FieldApi }) => (
{ } const error = 'Please enter a different value' - const formFactory = createFormFactory() + const formFactory = createFormFactory() const Comp = defineComponent(() => { const form = formFactory.useForm() @@ -159,7 +159,7 @@ describe('useField', () => { return error }} > - {({ field }: { field: FieldApi }) => ( + {({ field }: { field: FieldApi }) => (
{ const mockFn = vi.fn() const error = 'Please enter a different value' - const formFactory = createFormFactory() + const formFactory = createFormFactory() const Comp = defineComponent(() => { const form = formFactory.useForm() @@ -211,7 +211,7 @@ describe('useField', () => { return error }} > - {({ field }: { field: FieldApi }) => ( + {({ field }: { field: FieldApi }) => (
{ lastName: string } - const formFactory = createFormFactory() + const formFactory = createFormFactory() const Comp = defineComponent(() => { const form = formFactory.useForm() @@ -29,7 +29,11 @@ describe('useForm', () => { return () => ( - {({ field }: { field: FieldApi }) => ( + {({ + field, + }: { + field: FieldApi + }) => ( { lastName: string } - const formFactory = createFormFactory() + const formFactory = createFormFactory() const Comp = defineComponent(() => { const form = formFactory.useForm({ @@ -69,9 +73,11 @@ describe('useForm', () => { return () => ( - {({ field }: { field: FieldApi }) => ( -

{field.state.value}

- )} + {({ + field, + }: { + field: FieldApi + }) =>

{field.state.value}

}
) }) @@ -101,7 +107,7 @@ describe('useForm', () => { {({ field, }: { - field: FieldApi<{ firstName: string }, 'firstName', never> + field: FieldApi<{ firstName: string }, 'firstName', never, never> }) => { return ( , ValidatorType, - TData = DeepValue, -> = FieldOptions & { + FormValidator, + TData extends DeepValue = DeepValue, +> = FieldOptions & { mode?: 'value' | 'array' } diff --git a/packages/vue-form/src/useField.tsx b/packages/vue-form/src/useField.tsx index 534135692..ee49b3d27 100644 --- a/packages/vue-form/src/useField.tsx +++ b/packages/vue-form/src/useField.tsx @@ -12,32 +12,53 @@ declare module '@tanstack/form-core' { TParentData, TName extends DeepKeys, ValidatorType, + FormValidator, TData = DeepValue, > { - Field: FieldComponent + Field: FieldComponent } } -export type UseField = >( +export type UseField = < + TName extends DeepKeys, + ValidatorType, +>( opts?: { name: Narrow } & UseFieldOptions< TParentData, TName, + ValidatorType, + FormValidator, DeepValue >, -) => FieldApi> +) => FieldApi< + TParentData, + TName, + ValidatorType, + FormValidator, + DeepValue +> export function useField< TParentData, TName extends DeepKeys, ValidatorType, - TData = DeepValue, + FormValidator, + TData extends DeepValue = DeepValue, >( - opts: UseFieldOptions, + opts: UseFieldOptions< + TParentData, + TName, + ValidatorType, + FormValidator, + TData + >, ): { api: FieldApi< TParentData, TName, - ValidatorType + ValidatorType, + FormValidator, + TData // Omit & { // form: FormApi // } @@ -47,6 +68,8 @@ export function useField< FieldApi< TParentData, TName, + ValidatorType, + FormValidator, TData // Omit & { // form: FormApi @@ -102,6 +125,7 @@ type FieldComponentProps< TParentData, TName extends DeepKeys, ValidatorType, + FormValidator, > = (TParentData extends any[] ? { name?: TName @@ -111,28 +135,52 @@ type FieldComponentProps< name: TName index?: never }) & - Omit, 'name' | 'index'> + Omit< + UseFieldOptions, + 'name' | 'index' + > -export type FieldComponent = < +export type FieldComponent = < TName extends DeepKeys, ValidatorType, - TData = DeepValue, + TData extends DeepValue = DeepValue, >( - fieldOptions: FieldComponentProps, + fieldOptions: FieldComponentProps< + TParentData, + TName, + ValidatorType, + FormValidator + >, context: SetupContext< {}, SlotsType<{ default: { - field: FieldApi - state: FieldApi['state'] + field: FieldApi + state: FieldApi< + TParentData, + TName, + ValidatorType, + FormValidator, + TData + >['state'] } }> >, ) => any export const Field = defineComponent( - , ValidatorType>( - fieldOptions: UseFieldOptions, + < + TParentData, + TName extends DeepKeys, + ValidatorType, + FormValidator, + >( + fieldOptions: UseFieldOptions< + TParentData, + TName, + ValidatorType, + FormValidator + >, context: SetupContext, ) => { const fieldApi = useField({ ...fieldOptions, ...context.attrs } as any) diff --git a/packages/vue-form/src/useForm.tsx b/packages/vue-form/src/useForm.tsx index af713fbf6..359f04615 100644 --- a/packages/vue-form/src/useForm.tsx +++ b/packages/vue-form/src/useForm.tsx @@ -11,11 +11,11 @@ import { declare module '@tanstack/form-core' { // eslint-disable-next-line no-shadow - interface FormApi { + interface FormApi { Provider: (props: Record & {}) => any provideFormContext: () => void - Field: FieldComponent - useField: UseField + Field: FieldComponent + useField: UseField useStore: >>( selector?: (state: NoInfer>) => TSelected, ) => TSelected @@ -31,19 +31,21 @@ declare module '@tanstack/form-core' { } } -export function useForm(opts?: FormOptions): FormApi { +export function useForm( + opts?: FormOptions, +): FormApi { const formApi = (() => { - const api = new FormApi(opts) + const api = new FormApi(opts) api.Provider = defineComponent( (_, context) => { - provideFormContext({ formApi }) + provideFormContext({ formApi: formApi as never }) return () => context.slots.default!() }, { name: 'Provider' }, ) api.provideFormContext = () => { - provideFormContext({ formApi }) + provideFormContext({ formApi: formApi as never }) } api.Field = Field as never api.useField = useField as never From 7833b9d5ea8e6831f46579e243f7b9e4dd969d48 Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Tue, 17 Oct 2023 03:06:28 -0700 Subject: [PATCH 22/37] chore: migrate zod validation to dedicated package --- packages/form-core/package.json | 3 - packages/form-core/src/FieldApi.ts | 14 +++- packages/form-core/src/FormApi.ts | 4 +- packages/form-core/src/index.ts | 1 + .../form-core/src/tests/FieldApi.test-d.ts | 78 ------------------ packages/form-core/src/types.ts | 7 ++ packages/form-zod-adapter/.eslintrc.cjs | 11 +++ packages/form-zod-adapter/package.json | 62 +++++++++++++++ packages/form-zod-adapter/src/index.ts | 1 + .../src/tests/FieldApi.test-d.ts | 79 +++++++++++++++++++ .../src/tests/FormApi.test-d.ts | 6 +- .../src/validator.ts} | 8 +- .../form-zod-adapter/tsconfig.eslint.json | 7 ++ packages/form-zod-adapter/tsconfig.json | 9 +++ packages/form-zod-adapter/tsup.config.js | 9 +++ packages/form-zod-adapter/vitest.config.ts | 12 +++ pnpm-lock.yaml | 23 ++++-- 17 files changed, 230 insertions(+), 104 deletions(-) create mode 100644 packages/form-core/src/types.ts create mode 100644 packages/form-zod-adapter/.eslintrc.cjs create mode 100644 packages/form-zod-adapter/package.json create mode 100644 packages/form-zod-adapter/src/index.ts create mode 100644 packages/form-zod-adapter/src/tests/FieldApi.test-d.ts rename packages/{form-core => form-zod-adapter}/src/tests/FormApi.test-d.ts (90%) rename packages/{form-core/src/zod-validator.ts => form-zod-adapter/src/validator.ts} (71%) create mode 100644 packages/form-zod-adapter/tsconfig.eslint.json create mode 100644 packages/form-zod-adapter/tsconfig.json create mode 100644 packages/form-zod-adapter/tsup.config.js create mode 100644 packages/form-zod-adapter/vitest.config.ts diff --git a/packages/form-core/package.json b/packages/form-core/package.json index 676de78d6..3a4a01409 100644 --- a/packages/form-core/package.json +++ b/packages/form-core/package.json @@ -52,8 +52,5 @@ }, "dependencies": { "@tanstack/store": "0.1.3" - }, - "devDependencies": { - "zod": "^3.21.4" } } diff --git a/packages/form-core/src/FieldApi.ts b/packages/form-core/src/FieldApi.ts index 89b6b3a05..dc7f6ebf5 100644 --- a/packages/form-core/src/FieldApi.ts +++ b/packages/form-core/src/FieldApi.ts @@ -1,7 +1,7 @@ import { type DeepKeys, type DeepValue, type Updater } from './utils' -import type { FormApi, ValidationError, ValidationErrorMap } from './FormApi' +import type { FormApi, ValidationErrorMap } from './FormApi' import { Store } from '@tanstack/store' -import type { Validator } from './zod-validator' +import type { Validator, ValidationError } from './types' export type ValidationCause = 'change' | 'blur' | 'submit' | 'mount' @@ -138,7 +138,15 @@ export class FieldApi< state!: FieldState prevState!: FieldState - constructor(opts: FieldApiOptions) { + constructor( + opts: FieldApiOptions< + TParentData, + TName, + ValidatorType, + FormValidator, + TData + >, + ) { this.form = opts.form as never this.uid = uid++ // Support field prefixing from FieldScope diff --git a/packages/form-core/src/FormApi.ts b/packages/form-core/src/FormApi.ts index 8e4df0c9f..862e2fa2b 100644 --- a/packages/form-core/src/FormApi.ts +++ b/packages/form-core/src/FormApi.ts @@ -2,7 +2,7 @@ import { Store } from '@tanstack/store' import type { DeepKeys, DeepValue, Updater } from './utils' import { functionalUpdate, getBy, isNonEmptyArray, setBy } from './utils' import type { FieldApi, FieldMeta, ValidationCause } from './FieldApi' -import type { Validator } from './zod-validator' +import type { ValidationError, Validator } from './types' type ValidateFn = ( values: TData, @@ -54,8 +54,6 @@ export type ValidationMeta = { validationReject?: (errors: unknown) => void } -export type ValidationError = undefined | false | null | string - export type ValidationErrorMapKeys = `on${Capitalize}` export type ValidationErrorMap = { diff --git a/packages/form-core/src/index.ts b/packages/form-core/src/index.ts index 5d993d752..a061a5893 100644 --- a/packages/form-core/src/index.ts +++ b/packages/form-core/src/index.ts @@ -1,3 +1,4 @@ export * from './FormApi' export * from './FieldApi' export * from './utils' +export * from './types' diff --git a/packages/form-core/src/tests/FieldApi.test-d.ts b/packages/form-core/src/tests/FieldApi.test-d.ts index be9e037f1..8fbe1ca07 100644 --- a/packages/form-core/src/tests/FieldApi.test-d.ts +++ b/packages/form-core/src/tests/FieldApi.test-d.ts @@ -1,8 +1,6 @@ import { assertType } from 'vitest' import { FormApi } from '../FormApi' import { FieldApi } from '../FieldApi' -import { zodValidator } from '../zod-validator' -import { z } from 'zod' it('should type value properly', () => { const form = new FormApi({ @@ -38,79 +36,3 @@ it('should type onChange properly', () => { }, }) }) - -it('should allow a Zod validator to be passed in', () => { - const form = new FormApi({ - defaultValues: { - name: 'test', - }, - } as const) - - const field = new FieldApi({ - form, - name: 'name', - validator: zodValidator, - } as const) -}) - -it('should allow a Zod validator to handle the correct Zod type', () => { - const form = new FormApi({ - defaultValues: { - name: 'test', - }, - }) - - const field = new FieldApi({ - form, - name: 'name', - validator: zodValidator, - onChange: z.string(), - } as const) -}) - -it('should not allow a functional onChange to be passed when using a validator', () => { - const form = new FormApi({ - defaultValues: { - name: 'test', - }, - }) - - const field = new FieldApi({ - form, - name: 'name', - validator: zodValidator, - // @ts-expect-error Is not of type validator - onChange: (val) => null, - } as const) -}) - -it('should not allow a validator onChange to be passed when not using a validator', () => { - const form = new FormApi({ - defaultValues: { - name: 'test', - }, - }) - - const field = new FieldApi({ - form, - name: 'name', - // @ts-expect-error Requires a validator - onChange: z.string(), - } as const) -}) - -// This is not possible without higher-kinded types AFAIK -it.skip('should allow not a Zod validator with the wrong Zod type', () => { - const form = new FormApi({ - defaultValues: { - name: 'test', - }, - }) - - const field = new FieldApi({ - form, - name: 'name', - validator: zodValidator, - onChange: z.object({}), - } as const) -}) diff --git a/packages/form-core/src/types.ts b/packages/form-core/src/types.ts new file mode 100644 index 000000000..54bae7324 --- /dev/null +++ b/packages/form-core/src/types.ts @@ -0,0 +1,7 @@ +export type ValidationError = undefined | false | null | string + +// If/when TypeScript supports higher-kinded types, this should not be `unknown` anymore +export type Validator = () => { + validate(value: Type, fn: Fn): ValidationError + validateAsync(value: Type, fn: Fn): Promise +} diff --git a/packages/form-zod-adapter/.eslintrc.cjs b/packages/form-zod-adapter/.eslintrc.cjs new file mode 100644 index 000000000..52b44816b --- /dev/null +++ b/packages/form-zod-adapter/.eslintrc.cjs @@ -0,0 +1,11 @@ +// @ts-check + +/** @type {import('eslint').Linter.Config} */ +const config = { + parserOptions: { + tsconfigRootDir: __dirname, + project: './tsconfig.eslint.json', + }, +} + +module.exports = config diff --git a/packages/form-zod-adapter/package.json b/packages/form-zod-adapter/package.json new file mode 100644 index 000000000..8b2798691 --- /dev/null +++ b/packages/form-zod-adapter/package.json @@ -0,0 +1,62 @@ +{ + "name": "@tanstack/form-zod-adapter", + "version": "0.3.6", + "description": "The Zod adapter for TanStack Form.", + "author": "tannerlinsley", + "license": "MIT", + "repository": "tanstack/form", + "homepage": "https://tanstack.com/form", + "funding": { + "type": "github", + "url": "https://github.com/sponsors/tannerlinsley" + }, + "type": "module", + "types": "build/legacy/index.d.ts", + "main": "build/legacy/index.cjs", + "module": "build/legacy/index.js", + "exports": { + ".": { + "import": { + "types": "./build/modern/index.d.ts", + "default": "./build/modern/index.js" + }, + "require": { + "types": "./build/modern/index.d.cts", + "default": "./build/modern/index.cjs" + } + }, + "./package.json": "./package.json" + }, + "sideEffects": false, + "files": [ + "build", + "src" + ], + "nx": { + "targets": { + "test:build": { + "dependsOn": [ + "build" + ] + } + } + }, + "scripts": { + "clean": "rimraf ./build && rimraf ./coverage", + "test:eslint": "eslint --ext .ts,.tsx ./src", + "test:types": "tsc --noEmit && vitest typecheck", + "test:lib": "vitest run --coverage", + "test:lib:dev": "pnpm run test:lib --watch", + "test:build": "publint --strict", + "build": "tsup" + }, + "dependencies": { + "@tanstack/form-core": "workspace:*" + }, + "peerDependencies": { + "zod": "^3.x" + }, + "devDependencies": { + "zod": "^3.22.4" + } +} diff --git a/packages/form-zod-adapter/src/index.ts b/packages/form-zod-adapter/src/index.ts new file mode 100644 index 000000000..26e40beb9 --- /dev/null +++ b/packages/form-zod-adapter/src/index.ts @@ -0,0 +1 @@ +export * from './validator' diff --git a/packages/form-zod-adapter/src/tests/FieldApi.test-d.ts b/packages/form-zod-adapter/src/tests/FieldApi.test-d.ts new file mode 100644 index 000000000..aea4cc5d7 --- /dev/null +++ b/packages/form-zod-adapter/src/tests/FieldApi.test-d.ts @@ -0,0 +1,79 @@ +import { zodValidator } from '../validator' +import { z } from 'zod' +import { FieldApi, FormApi } from '@tanstack/form-core' + +it('should allow a Zod validator to be passed in', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + } as const) + + const field = new FieldApi({ + form, + name: 'name', + validator: zodValidator, + } as const) +}) + +it('should allow a Zod validator to handle the correct Zod type', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + }) + + const field = new FieldApi({ + form, + name: 'name', + validator: zodValidator, + onChange: z.string(), + } as const) +}) + +it('should not allow a functional onChange to be passed when using a validator', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + }) + + const field = new FieldApi({ + form, + name: 'name', + validator: zodValidator, + // @ts-expect-error Is not of type validator + onChange: (val) => null, + } as const) +}) + +it('should not allow a validator onChange to be passed when not using a validator', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + }) + + const field = new FieldApi({ + form, + name: 'name', + // @ts-expect-error Requires a validator + onChange: z.string(), + } as const) +}) + +// This is not possible without higher-kinded types AFAIK +it.skip('should allow not a Zod validator with the wrong Zod type', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + }) + + const field = new FieldApi({ + form, + name: 'name', + validator: zodValidator, + onChange: z.object({}), + } as const) +}) diff --git a/packages/form-core/src/tests/FormApi.test-d.ts b/packages/form-zod-adapter/src/tests/FormApi.test-d.ts similarity index 90% rename from packages/form-core/src/tests/FormApi.test-d.ts rename to packages/form-zod-adapter/src/tests/FormApi.test-d.ts index 39365492b..75f34b21a 100644 --- a/packages/form-core/src/tests/FormApi.test-d.ts +++ b/packages/form-zod-adapter/src/tests/FormApi.test-d.ts @@ -1,8 +1,6 @@ -import { assertType } from 'vitest' -import { FormApi } from '../FormApi' -import { FieldApi } from '../FieldApi' -import { zodValidator } from '../zod-validator' import { z } from 'zod' +import { zodValidator } from '../validator' +import { FieldApi, FormApi } from '@tanstack/form-core' it('should allow a Zod validator to be passed in', () => { const form = new FormApi({ diff --git a/packages/form-core/src/zod-validator.ts b/packages/form-zod-adapter/src/validator.ts similarity index 71% rename from packages/form-core/src/zod-validator.ts rename to packages/form-zod-adapter/src/validator.ts index 514bee503..c57d41754 100644 --- a/packages/form-core/src/zod-validator.ts +++ b/packages/form-zod-adapter/src/validator.ts @@ -1,11 +1,5 @@ import type { ZodError, ZodType, ZodTypeAny } from 'zod' -import type { ValidationError } from './FormApi' - -// If/when TypeScript supports higher-kinded types, this should not be `unknown` anymore -export type Validator = () => { - validate(value: Type, fn: Fn): ValidationError - validateAsync(value: Type, fn: Fn): Promise -} +import type { ValidationError, Validator } from "@tanstack/form-core"; export const zodValidator = ( = ZodType>() => { return { diff --git a/packages/form-zod-adapter/tsconfig.eslint.json b/packages/form-zod-adapter/tsconfig.eslint.json new file mode 100644 index 000000000..e3d796435 --- /dev/null +++ b/packages/form-zod-adapter/tsconfig.eslint.json @@ -0,0 +1,7 @@ +{ + "extends": "./tsconfig.json", + "compilerOptions": { + "noEmit": true + }, + "include": ["**/*.ts", "**/*.tsx", ".eslintrc.cjs", "tsup.config.js"] +} diff --git a/packages/form-zod-adapter/tsconfig.json b/packages/form-zod-adapter/tsconfig.json new file mode 100644 index 000000000..8cb149f1d --- /dev/null +++ b/packages/form-zod-adapter/tsconfig.json @@ -0,0 +1,9 @@ +{ + "composite": true, + "extends": "../../tsconfig.base.json", + "compilerOptions": { + "outDir": "./build/lib", + "types": ["vitest/globals"] + }, + "include": ["src"] +} diff --git a/packages/form-zod-adapter/tsup.config.js b/packages/form-zod-adapter/tsup.config.js new file mode 100644 index 000000000..7b19f5f87 --- /dev/null +++ b/packages/form-zod-adapter/tsup.config.js @@ -0,0 +1,9 @@ +// @ts-check + +import { defineConfig } from 'tsup' +import { legacyConfig, modernConfig } from '../../getTsupConfig.js' + +export default defineConfig([ + modernConfig({ entry: ['src/*.ts'] }), + legacyConfig({ entry: ['src/*.ts'] }), +]) diff --git a/packages/form-zod-adapter/vitest.config.ts b/packages/form-zod-adapter/vitest.config.ts new file mode 100644 index 000000000..89a7a5a63 --- /dev/null +++ b/packages/form-zod-adapter/vitest.config.ts @@ -0,0 +1,12 @@ +import { defineConfig } from 'vitest/config' + +export default defineConfig({ + test: { + name: 'form-core', + dir: './src', + watch: false, + environment: 'jsdom', + globals: true, + coverage: { provider: 'istanbul' }, + }, +}) diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 0154d2048..26cd194f8 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -1,9 +1,5 @@ lockfileVersion: '6.0' -settings: - autoInstallPeers: true - excludeLinksFromLockfile: false - overrides: '@tanstack/form-core': workspace:* '@tanstack/react-form': workspace:* @@ -290,10 +286,16 @@ importers: '@tanstack/store': specifier: 0.1.3 version: 0.1.3 + + packages/form-zod-adapter: + dependencies: + '@tanstack/form-core': + specifier: workspace:* + version: link:../form-core devDependencies: zod: - specifier: ^3.21.4 - version: 3.22.2 + specifier: ^3.22.4 + version: 3.22.4 packages/react-form: dependencies: @@ -9981,3 +9983,12 @@ packages: /zod@3.22.2: resolution: {integrity: sha512-wvWkphh5WQsJbVk1tbx1l1Ly4yg+XecD+Mq280uBGt9wa5BKSWf4Mhp6GmrkPixhMxmabYY7RbzlwVP32pbGCg==} + dev: false + + /zod@3.22.4: + resolution: {integrity: sha512-iC+8Io04lddc+mVqQ9AZ7OQ2MrUKGN+oIQyq1vemgt46jwCwLfhq7/pwnBnNXXXZb8VTVLKwp9EDkx+ryxIWmg==} + dev: true + +settings: + autoInstallPeers: true + excludeLinksFromLockfile: false From 426edfa27e1568eee8403563a89fa4ff2d8ad2ea Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Tue, 17 Oct 2023 03:38:24 -0700 Subject: [PATCH 23/37] chore: add first integration test for zod adapter --- packages/form-core/src/FieldApi.ts | 1 + .../src/tests/FieldApi.spec.ts | 31 +++++++++++++++++++ packages/form-zod-adapter/src/validator.ts | 19 ++++++------ 3 files changed, 42 insertions(+), 9 deletions(-) create mode 100644 packages/form-zod-adapter/src/tests/FieldApi.spec.ts diff --git a/packages/form-core/src/FieldApi.ts b/packages/form-core/src/FieldApi.ts index dc7f6ebf5..f7b79958d 100644 --- a/packages/form-core/src/FieldApi.ts +++ b/packages/form-core/src/FieldApi.ts @@ -190,6 +190,7 @@ export class FieldApi< this.state = this.store.state this.prevState = this.state + this.options = opts as never } mount = () => { diff --git a/packages/form-zod-adapter/src/tests/FieldApi.spec.ts b/packages/form-zod-adapter/src/tests/FieldApi.spec.ts new file mode 100644 index 000000000..d37b7f8d9 --- /dev/null +++ b/packages/form-zod-adapter/src/tests/FieldApi.spec.ts @@ -0,0 +1,31 @@ +import { expect } from 'vitest' + +import { FormApi, FieldApi } from '@tanstack/form-core' +import { zodValidator } from '../validator' +import { z } from 'zod' + +describe('zod field api', () => { + it('should run an onChange with z.string validation', () => { + const form = new FormApi({ + defaultValues: { + name: '', + }, + }) + + const field = new FieldApi({ + form, + validator: zodValidator, + name: 'name', + onChange: z.string().min(3, 'You must have a length of at least 3'), + }) + + field.mount(); + + expect(field.getMeta().errors).toEqual([]) + debugger + field.setValue('a', { touch: true }) + expect(field.getMeta().errors).toEqual(['You must have a length of at least 3']) + field.setValue('asdf', { touch: true }) + expect(field.getMeta().errors).toEqual([]) + }) +}) diff --git a/packages/form-zod-adapter/src/validator.ts b/packages/form-zod-adapter/src/validator.ts index c57d41754..1404f9478 100644 --- a/packages/form-zod-adapter/src/validator.ts +++ b/packages/form-zod-adapter/src/validator.ts @@ -1,27 +1,28 @@ import type { ZodError, ZodType, ZodTypeAny } from 'zod' -import type { ValidationError, Validator } from "@tanstack/form-core"; +import type { ValidationError, Validator } from '@tanstack/form-core' export const zodValidator = ( = ZodType>() => { return { validate(value: unknown, fn: Fn): ValidationError { // Call Zod on the value here and return the error message try { - ;(fn as ZodTypeAny).parse(value) + const result = (fn as ZodTypeAny).safeParse(value) + if (!result.success) { + return result.error.issues.map((issue) => issue.message).join(', ') + } return } catch (_e) { const e = _e as ZodError - return e.toString() + return e.message } }, async validateAsync(value: unknown, fn: Fn): Promise { // Call Zod on the value here and return the error message - try { - await (fn as ZodTypeAny).parseAsync(value) - return - } catch (_e) { - const e = _e as ZodError - return e.toString() + const result = await (fn as ZodTypeAny).safeParseAsync(value) + if (!result.success) { + return result.error.issues.map((issue) => issue.message).join(', ') } + return }, } }) satisfies Validator From dded09d2e4a972d50f67f82cda8ebb30bef83267 Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Tue, 17 Oct 2023 03:52:17 -0700 Subject: [PATCH 24/37] chore: enable non-validator types to be passed to validator --- packages/form-core/src/FieldApi.ts | 10 +++++-- .../src/tests/FieldApi.spec.ts | 29 +++++++++++++++++-- .../src/tests/FieldApi.test-d.ts | 9 ++++-- .../src/tests/FormApi.test-d.ts | 9 ++++-- packages/form-zod-adapter/src/validator.ts | 13 +++------ 5 files changed, 50 insertions(+), 20 deletions(-) diff --git a/packages/form-core/src/FieldApi.ts b/packages/form-core/src/FieldApi.ts index f7b79958d..79f7bb0ad 100644 --- a/packages/form-core/src/FieldApi.ts +++ b/packages/form-core/src/FieldApi.ts @@ -22,9 +22,13 @@ type ValidateOrFn< FormValidator, TData extends DeepValue = DeepValue, > = ValidatorType extends Validator - ? Parameters['validate']>[1] + ? + | Parameters['validate']>[1] + | ValidateFn : FormValidator extends Validator - ? Parameters['validate']>[1] + ? + | Parameters['validate']>[1] + | ValidateFn : ValidateFn type ValidateAsyncFn< @@ -314,7 +318,7 @@ export class FieldApi< this.getInfo().validationCount = validationCount const doValidate = () => { - if (this.options.validator) { + if (this.options.validator && typeof validate !== 'function') { return (this.options.validator as Validator)().validate( value, validate, diff --git a/packages/form-zod-adapter/src/tests/FieldApi.spec.ts b/packages/form-zod-adapter/src/tests/FieldApi.spec.ts index d37b7f8d9..2a82a3ca3 100644 --- a/packages/form-zod-adapter/src/tests/FieldApi.spec.ts +++ b/packages/form-zod-adapter/src/tests/FieldApi.spec.ts @@ -19,12 +19,37 @@ describe('zod field api', () => { onChange: z.string().min(3, 'You must have a length of at least 3'), }) - field.mount(); + field.mount() + + expect(field.getMeta().errors).toEqual([]) + field.setValue('a', { touch: true }) + expect(field.getMeta().errors).toEqual([ + 'You must have a length of at least 3', + ]) + field.setValue('asdf', { touch: true }) + expect(field.getMeta().errors).toEqual([]) + }) + + it('should run an onChange fn with zod validation option enabled', () => { + const form = new FormApi({ + defaultValues: { + name: '', + }, + }) + + const field = new FieldApi({ + form, + validator: zodValidator, + name: 'name', + onChange: (val) => (val === 'a' ? 'Test' : undefined), + }) + + field.mount() expect(field.getMeta().errors).toEqual([]) debugger field.setValue('a', { touch: true }) - expect(field.getMeta().errors).toEqual(['You must have a length of at least 3']) + expect(field.getMeta().errors).toEqual(['Test']) field.setValue('asdf', { touch: true }) expect(field.getMeta().errors).toEqual([]) }) diff --git a/packages/form-zod-adapter/src/tests/FieldApi.test-d.ts b/packages/form-zod-adapter/src/tests/FieldApi.test-d.ts index aea4cc5d7..3937648f5 100644 --- a/packages/form-zod-adapter/src/tests/FieldApi.test-d.ts +++ b/packages/form-zod-adapter/src/tests/FieldApi.test-d.ts @@ -1,6 +1,7 @@ import { zodValidator } from '../validator' import { z } from 'zod' import { FieldApi, FormApi } from '@tanstack/form-core' +import { assertType } from 'vitest' it('should allow a Zod validator to be passed in', () => { const form = new FormApi({ @@ -31,7 +32,7 @@ it('should allow a Zod validator to handle the correct Zod type', () => { } as const) }) -it('should not allow a functional onChange to be passed when using a validator', () => { +it('should allow a functional onChange to be passed when using a validator', () => { const form = new FormApi({ defaultValues: { name: 'test', @@ -42,8 +43,10 @@ it('should not allow a functional onChange to be passed when using a validator', form, name: 'name', validator: zodValidator, - // @ts-expect-error Is not of type validator - onChange: (val) => null, + onChange: (val) => { + assertType<'test'>(val) + return undefined + }, } as const) }) diff --git a/packages/form-zod-adapter/src/tests/FormApi.test-d.ts b/packages/form-zod-adapter/src/tests/FormApi.test-d.ts index 75f34b21a..7d4282eff 100644 --- a/packages/form-zod-adapter/src/tests/FormApi.test-d.ts +++ b/packages/form-zod-adapter/src/tests/FormApi.test-d.ts @@ -1,6 +1,7 @@ import { z } from 'zod' import { zodValidator } from '../validator' import { FieldApi, FormApi } from '@tanstack/form-core' +import { assertType } from 'vitest' it('should allow a Zod validator to be passed in', () => { const form = new FormApi({ @@ -26,7 +27,7 @@ it('should allow a Zod validator to handle the correct Zod type', () => { } as const) }) -it('should not allow a functional onChange to be passed when using a validator', () => { +it('should allow a functional onChange to be passed when using a validator', () => { const form = new FormApi({ defaultValues: { name: 'test', @@ -37,8 +38,10 @@ it('should not allow a functional onChange to be passed when using a validator', const field = new FieldApi({ form, name: 'name', - // @ts-expect-error Is not of type validator - onChange: (val) => null, + onChange: (val) => { + assertType<'test'>(val) + return undefined + }, } as const) }) diff --git a/packages/form-zod-adapter/src/validator.ts b/packages/form-zod-adapter/src/validator.ts index 1404f9478..48b25c94d 100644 --- a/packages/form-zod-adapter/src/validator.ts +++ b/packages/form-zod-adapter/src/validator.ts @@ -5,16 +5,11 @@ export const zodValidator = ( = ZodType>() => { return { validate(value: unknown, fn: Fn): ValidationError { // Call Zod on the value here and return the error message - try { - const result = (fn as ZodTypeAny).safeParse(value) - if (!result.success) { - return result.error.issues.map((issue) => issue.message).join(', ') - } - return - } catch (_e) { - const e = _e as ZodError - return e.message + const result = (fn as ZodTypeAny).safeParse(value) + if (!result.success) { + return result.error.issues.map((issue) => issue.message).join(', ') } + return }, async validateAsync(value: unknown, fn: Fn): Promise { // Call Zod on the value here and return the error message From f023dcd4245f9f1077484b8da99c66bc174c31df Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Tue, 17 Oct 2023 04:21:04 -0700 Subject: [PATCH 25/37] feat: add yup 1.x adapter --- packages/form-yup-adapter/.eslintrc.cjs | 11 +++ packages/form-yup-adapter/package.json | 62 ++++++++++++++ packages/form-yup-adapter/src/index.ts | 1 + .../src/tests/FieldApi.spec.ts | 56 +++++++++++++ .../src/tests/FieldApi.test-d.ts | 82 +++++++++++++++++++ .../src/tests/FormApi.test-d.ts | 77 +++++++++++++++++ packages/form-yup-adapter/src/validator.ts | 25 ++++++ .../form-yup-adapter/tsconfig.eslint.json | 7 ++ packages/form-yup-adapter/tsconfig.json | 9 ++ packages/form-yup-adapter/tsup.config.js | 9 ++ packages/form-yup-adapter/vitest.config.ts | 12 +++ packages/form-zod-adapter/src/validator.ts | 4 +- pnpm-lock.yaml | 36 ++++++++ 13 files changed, 389 insertions(+), 2 deletions(-) create mode 100644 packages/form-yup-adapter/.eslintrc.cjs create mode 100644 packages/form-yup-adapter/package.json create mode 100644 packages/form-yup-adapter/src/index.ts create mode 100644 packages/form-yup-adapter/src/tests/FieldApi.spec.ts create mode 100644 packages/form-yup-adapter/src/tests/FieldApi.test-d.ts create mode 100644 packages/form-yup-adapter/src/tests/FormApi.test-d.ts create mode 100644 packages/form-yup-adapter/src/validator.ts create mode 100644 packages/form-yup-adapter/tsconfig.eslint.json create mode 100644 packages/form-yup-adapter/tsconfig.json create mode 100644 packages/form-yup-adapter/tsup.config.js create mode 100644 packages/form-yup-adapter/vitest.config.ts diff --git a/packages/form-yup-adapter/.eslintrc.cjs b/packages/form-yup-adapter/.eslintrc.cjs new file mode 100644 index 000000000..52b44816b --- /dev/null +++ b/packages/form-yup-adapter/.eslintrc.cjs @@ -0,0 +1,11 @@ +// @ts-check + +/** @type {import('eslint').Linter.Config} */ +const config = { + parserOptions: { + tsconfigRootDir: __dirname, + project: './tsconfig.eslint.json', + }, +} + +module.exports = config diff --git a/packages/form-yup-adapter/package.json b/packages/form-yup-adapter/package.json new file mode 100644 index 000000000..4407ff92d --- /dev/null +++ b/packages/form-yup-adapter/package.json @@ -0,0 +1,62 @@ +{ + "name": "@tanstack/form-yup-adapter", + "version": "0.3.6", + "description": "The Yup adapter for TanStack Form.", + "author": "tannerlinsley", + "license": "MIT", + "repository": "tanstack/form", + "homepage": "https://tanstack.com/form", + "funding": { + "type": "github", + "url": "https://github.com/sponsors/tannerlinsley" + }, + "type": "module", + "types": "build/legacy/index.d.ts", + "main": "build/legacy/index.cjs", + "module": "build/legacy/index.js", + "exports": { + ".": { + "import": { + "types": "./build/modern/index.d.ts", + "default": "./build/modern/index.js" + }, + "require": { + "types": "./build/modern/index.d.cts", + "default": "./build/modern/index.cjs" + } + }, + "./package.json": "./package.json" + }, + "sideEffects": false, + "files": [ + "build", + "src" + ], + "nx": { + "targets": { + "test:build": { + "dependsOn": [ + "build" + ] + } + } + }, + "scripts": { + "clean": "rimraf ./build && rimraf ./coverage", + "test:eslint": "eslint --ext .ts,.tsx ./src", + "test:types": "tsc --noEmit && vitest typecheck", + "test:lib": "vitest run --coverage", + "test:lib:dev": "pnpm run test:lib --watch", + "test:build": "publint --strict", + "build": "tsup" + }, + "dependencies": { + "@tanstack/form-core": "workspace:*" + }, + "peerDependencies": { + "yup": "^1.x" + }, + "devDependencies": { + "yup": "^1.3.2" + } +} diff --git a/packages/form-yup-adapter/src/index.ts b/packages/form-yup-adapter/src/index.ts new file mode 100644 index 000000000..26e40beb9 --- /dev/null +++ b/packages/form-yup-adapter/src/index.ts @@ -0,0 +1 @@ +export * from './validator' diff --git a/packages/form-yup-adapter/src/tests/FieldApi.spec.ts b/packages/form-yup-adapter/src/tests/FieldApi.spec.ts new file mode 100644 index 000000000..e0aa9b681 --- /dev/null +++ b/packages/form-yup-adapter/src/tests/FieldApi.spec.ts @@ -0,0 +1,56 @@ +import { expect } from 'vitest' + +import { FormApi, FieldApi } from '@tanstack/form-core' +import { yupValidator } from '../validator' +import yup from 'yup' + +describe('yup field api', () => { + it('should run an onChange with yup.string validation', () => { + const form = new FormApi({ + defaultValues: { + name: '', + }, + }) + + const field = new FieldApi({ + form, + validator: yupValidator, + name: 'name', + onChange: yup.string().min(3, 'You must have a length of at least 3'), + }) + + field.mount() + + expect(field.getMeta().errors).toEqual([]) + field.setValue('a', { touch: true }) + expect(field.getMeta().errors).toEqual([ + 'You must have a length of at least 3', + ]) + field.setValue('asdf', { touch: true }) + expect(field.getMeta().errors).toEqual([]) + }) + + it('should run an onChange fn with yup validation option enabled', () => { + const form = new FormApi({ + defaultValues: { + name: '', + }, + }) + + const field = new FieldApi({ + form, + validator: yupValidator, + name: 'name', + onChange: (val) => (val === 'a' ? 'Test' : undefined), + }) + + field.mount() + + expect(field.getMeta().errors).toEqual([]) + debugger + field.setValue('a', { touch: true }) + expect(field.getMeta().errors).toEqual(['Test']) + field.setValue('asdf', { touch: true }) + expect(field.getMeta().errors).toEqual([]) + }) +}) diff --git a/packages/form-yup-adapter/src/tests/FieldApi.test-d.ts b/packages/form-yup-adapter/src/tests/FieldApi.test-d.ts new file mode 100644 index 000000000..62f8ca8df --- /dev/null +++ b/packages/form-yup-adapter/src/tests/FieldApi.test-d.ts @@ -0,0 +1,82 @@ +import { yupValidator } from '../validator' +import yup from 'yup' +import { FieldApi, FormApi } from '@tanstack/form-core' +import { assertType } from 'vitest' + +it('should allow a Zod validator to be passed in', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + } as const) + + const field = new FieldApi({ + form, + name: 'name', + validator: yupValidator, + } as const) +}) + +it('should allow a Zod validator to handle the correct Zod type', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + }) + + const field = new FieldApi({ + form, + name: 'name', + validator: yupValidator, + onChange: yup.string(), + } as const) +}) + +it('should allow a functional onChange to be passed when using a validator', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + }) + + const field = new FieldApi({ + form, + name: 'name', + validator: yupValidator, + onChange: (val) => { + assertType<'test'>(val) + return undefined + }, + } as const) +}) + +it('should not allow a validator onChange to be passed when not using a validator', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + }) + + const field = new FieldApi({ + form, + name: 'name', + // @ts-expect-error Requires a validator + onChange: z.string(), + } as const) +}) + +// This is not possible without higher-kinded types AFAIK +it.skip('should allow not a Zod validator with the wrong Zod type', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + }) + + const field = new FieldApi({ + form, + name: 'name', + validator: yupValidator, + onChange: yup.object({}), + } as const) +}) diff --git a/packages/form-yup-adapter/src/tests/FormApi.test-d.ts b/packages/form-yup-adapter/src/tests/FormApi.test-d.ts new file mode 100644 index 000000000..366b354a3 --- /dev/null +++ b/packages/form-yup-adapter/src/tests/FormApi.test-d.ts @@ -0,0 +1,77 @@ +import yup from 'yup' +import { yupValidator } from '../validator' +import { FieldApi, FormApi } from '@tanstack/form-core' +import { assertType } from 'vitest' + +it('should allow a Zod validator to be passed in', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + validator: yupValidator, + } as const) +}) + +it('should allow a Zod validator to handle the correct Zod type', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + validator: yupValidator, + }) + + const field = new FieldApi({ + form, + name: 'name', + onChange: yup.string(), + } as const) +}) + +it('should allow a functional onChange to be passed when using a validator', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + validator: yupValidator, + }) + + const field = new FieldApi({ + form, + name: 'name', + onChange: (val) => { + assertType<'test'>(val) + return undefined + }, + } as const) +}) + +it('should not allow a validator onChange to be passed when not using a validator', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + }) + + const field = new FieldApi({ + form, + name: 'name', + // @ts-expect-error Requires a validator + onChange: yup.string(), + } as const) +}) + +// This is not possible without higher-kinded types AFAIK +it.skip('should allow not a Zod validator with the wrong Zod type', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + }) + + const field = new FieldApi({ + form, + name: 'name', + validator: yupValidator, + onChange: yup.object({}), + } as const) +}) diff --git a/packages/form-yup-adapter/src/validator.ts b/packages/form-yup-adapter/src/validator.ts new file mode 100644 index 000000000..d7865de44 --- /dev/null +++ b/packages/form-yup-adapter/src/validator.ts @@ -0,0 +1,25 @@ +import type { ValidationError as YupError, AnySchema } from 'yup' +import type { ValidationError, Validator } from '@tanstack/form-core' + +export const yupValidator = (() => { + return { + validate(value: unknown, fn: Fn): ValidationError { + try { + fn.validateSync(value) + return + } catch (_e) { + const e = _e as YupError + return e.errors.join(', ') + } + }, + async validateAsync(value: unknown, fn: Fn): Promise { + try { + await fn.validate(value) + return + } catch (_e) { + const e = _e as YupError + return e.errors.join(', ') + } + }, + } +}) satisfies Validator diff --git a/packages/form-yup-adapter/tsconfig.eslint.json b/packages/form-yup-adapter/tsconfig.eslint.json new file mode 100644 index 000000000..e3d796435 --- /dev/null +++ b/packages/form-yup-adapter/tsconfig.eslint.json @@ -0,0 +1,7 @@ +{ + "extends": "./tsconfig.json", + "compilerOptions": { + "noEmit": true + }, + "include": ["**/*.ts", "**/*.tsx", ".eslintrc.cjs", "tsup.config.js"] +} diff --git a/packages/form-yup-adapter/tsconfig.json b/packages/form-yup-adapter/tsconfig.json new file mode 100644 index 000000000..8cb149f1d --- /dev/null +++ b/packages/form-yup-adapter/tsconfig.json @@ -0,0 +1,9 @@ +{ + "composite": true, + "extends": "../../tsconfig.base.json", + "compilerOptions": { + "outDir": "./build/lib", + "types": ["vitest/globals"] + }, + "include": ["src"] +} diff --git a/packages/form-yup-adapter/tsup.config.js b/packages/form-yup-adapter/tsup.config.js new file mode 100644 index 000000000..7b19f5f87 --- /dev/null +++ b/packages/form-yup-adapter/tsup.config.js @@ -0,0 +1,9 @@ +// @ts-check + +import { defineConfig } from 'tsup' +import { legacyConfig, modernConfig } from '../../getTsupConfig.js' + +export default defineConfig([ + modernConfig({ entry: ['src/*.ts'] }), + legacyConfig({ entry: ['src/*.ts'] }), +]) diff --git a/packages/form-yup-adapter/vitest.config.ts b/packages/form-yup-adapter/vitest.config.ts new file mode 100644 index 000000000..89a7a5a63 --- /dev/null +++ b/packages/form-yup-adapter/vitest.config.ts @@ -0,0 +1,12 @@ +import { defineConfig } from 'vitest/config' + +export default defineConfig({ + test: { + name: 'form-core', + dir: './src', + watch: false, + environment: 'jsdom', + globals: true, + coverage: { provider: 'istanbul' }, + }, +}) diff --git a/packages/form-zod-adapter/src/validator.ts b/packages/form-zod-adapter/src/validator.ts index 48b25c94d..7c04e272c 100644 --- a/packages/form-zod-adapter/src/validator.ts +++ b/packages/form-zod-adapter/src/validator.ts @@ -1,7 +1,7 @@ -import type { ZodError, ZodType, ZodTypeAny } from 'zod' +import type { ZodType, ZodTypeAny } from 'zod' import type { ValidationError, Validator } from '@tanstack/form-core' -export const zodValidator = ( = ZodType>() => { +export const zodValidator = (() => { return { validate(value: unknown, fn: Fn): ValidationError { // Call Zod on the value here and return the error message diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 26cd194f8..719f2c532 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -287,6 +287,16 @@ importers: specifier: 0.1.3 version: 0.1.3 + packages/form-yup-adapter: + dependencies: + '@tanstack/form-core': + specifier: workspace:* + version: link:../form-core + devDependencies: + yup: + specifier: ^1.3.2 + version: 1.3.2 + packages/form-zod-adapter: dependencies: '@tanstack/form-core': @@ -8011,6 +8021,10 @@ packages: object-assign: 4.1.1 react-is: 16.13.1 + /property-expr@2.0.6: + resolution: {integrity: sha512-SVtmxhRE/CGkn3eZY1T6pC8Nln6Fr/lu1mKSgRud0eC73whjGfoAogbn78LkD8aFL0zz3bAFerKSnOl7NlErBA==} + dev: true + /proto-list@1.2.4: resolution: {integrity: sha512-vtK/94akxsTMhe0/cbfpR+syPuszcuwhqVjJq26CuNDgFGj682oRBXOP5MJpv2r7JtE8MsiepGIqvvOTBwn2vA==} dev: true @@ -9057,6 +9071,10 @@ packages: resolution: {integrity: sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==} dev: true + /tiny-case@1.0.3: + resolution: {integrity: sha512-Eet/eeMhkO6TX8mnUteS9zgPbUMQa4I6Kkp5ORiBD5476/m+PIRiumP5tmh5ioJpH7k51Kehawy2UDfsnxxY8Q==} + dev: true + /tinybench@2.5.0: resolution: {integrity: sha512-kRwSG8Zx4tjF9ZiyH4bhaebu+EDz1BOx9hOigYHlUW4xxI/wKIUQUqo018UlU4ar6ATPBsaMrdbKZ+tmPdohFA==} dev: true @@ -9096,6 +9114,10 @@ packages: engines: {node: '>=0.6'} dev: false + /toposort@2.0.2: + resolution: {integrity: sha512-0a5EOkAUp8D4moMi2W8ZF8jcga7BgZd91O/yabJCFY8az+XSzeGyTKs0Aoo897iV1Nj6guFq8orWDS96z91oGg==} + dev: true + /tough-cookie@4.1.3: resolution: {integrity: sha512-aX/y5pVRkfRnfmuX+OdbSdXvPe6ieKX/G2s7e98f4poJHnqH3281gDPm/metm6E/WRamfx7WC4HUqkWHfQHprw==} engines: {node: '>=6'} @@ -9275,6 +9297,11 @@ packages: engines: {node: '>=8'} dev: true + /type-fest@2.19.0: + resolution: {integrity: sha512-RAH822pAdBgcNMAfWnCBU3CFZcfZ/i1eZjwFU/dsLKumyuuP3niueg2UAukXYF0E2AAoc82ZSSf9J0WQBinzHA==} + engines: {node: '>=12.20'} + dev: true + /type-fest@3.13.1: resolution: {integrity: sha512-tLq3bSNx+xSpwvAJnzrK0Ep5CLNWjvFTOp71URMaAEWBfRb9nnJiBoUe0tF8bI4ZFO3omgBR6NvnbzVUT3Ly4g==} engines: {node: '>=14.16'} @@ -9981,6 +10008,15 @@ packages: engines: {node: '>=12.20'} dev: true + /yup@1.3.2: + resolution: {integrity: sha512-6KCM971iQtJ+/KUaHdrhVr2LDkfhBtFPRnsG1P8F4q3uUVQ2RfEM9xekpha9aA4GXWJevjM10eDcPQ1FfWlmaQ==} + dependencies: + property-expr: 2.0.6 + tiny-case: 1.0.3 + toposort: 2.0.2 + type-fest: 2.19.0 + dev: true + /zod@3.22.2: resolution: {integrity: sha512-wvWkphh5WQsJbVk1tbx1l1Ly4yg+XecD+Mq280uBGt9wa5BKSWf4Mhp6GmrkPixhMxmabYY7RbzlwVP32pbGCg==} dev: false From f6e843e8399ce349c65048461aa84bee5ece9bd3 Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Tue, 17 Oct 2023 05:39:30 -0700 Subject: [PATCH 26/37] chore: add functionality and tests for form-wide validators --- packages/form-core/src/FieldApi.ts | 7 +++ .../src/tests/FieldApi.spec.ts | 1 - .../src/tests/FormApi.spec.ts | 55 +++++++++++++++++++ .../src/tests/FieldApi.spec.ts | 1 - .../src/tests/FormApi.spec.ts | 55 +++++++++++++++++++ 5 files changed, 117 insertions(+), 2 deletions(-) create mode 100644 packages/form-yup-adapter/src/tests/FormApi.spec.ts create mode 100644 packages/form-zod-adapter/src/tests/FormApi.spec.ts diff --git a/packages/form-core/src/FieldApi.ts b/packages/form-core/src/FieldApi.ts index 79f7bb0ad..b523382a7 100644 --- a/packages/form-core/src/FieldApi.ts +++ b/packages/form-core/src/FieldApi.ts @@ -325,6 +325,13 @@ export class FieldApi< ) } + if (this.form.options.validator && typeof validate !== 'function') { + return (this.form.options.validator as Validator)().validate( + value, + validate, + ) + } + return (validate as ValidateFn)( value, this as never, diff --git a/packages/form-yup-adapter/src/tests/FieldApi.spec.ts b/packages/form-yup-adapter/src/tests/FieldApi.spec.ts index e0aa9b681..fb809fb58 100644 --- a/packages/form-yup-adapter/src/tests/FieldApi.spec.ts +++ b/packages/form-yup-adapter/src/tests/FieldApi.spec.ts @@ -47,7 +47,6 @@ describe('yup field api', () => { field.mount() expect(field.getMeta().errors).toEqual([]) - debugger field.setValue('a', { touch: true }) expect(field.getMeta().errors).toEqual(['Test']) field.setValue('asdf', { touch: true }) diff --git a/packages/form-yup-adapter/src/tests/FormApi.spec.ts b/packages/form-yup-adapter/src/tests/FormApi.spec.ts new file mode 100644 index 000000000..d77842873 --- /dev/null +++ b/packages/form-yup-adapter/src/tests/FormApi.spec.ts @@ -0,0 +1,55 @@ +import { expect } from 'vitest' + +import { FormApi, FieldApi } from '@tanstack/form-core' +import { yupValidator } from '../validator' +import yup from 'yup' + +describe('yup form api', () => { + it('should run an onChange with z.string validation', () => { + const form = new FormApi({ + defaultValues: { + name: '', + }, + validator: yupValidator, + }) + + const field = new FieldApi({ + form, + name: 'name', + onChange: yup.string().min(3, 'You must have a length of at least 3'), + }) + + field.mount() + + expect(field.getMeta().errors).toEqual([]) + field.setValue('a', { touch: true }) + expect(field.getMeta().errors).toEqual([ + 'You must have a length of at least 3', + ]) + field.setValue('asdf', { touch: true }) + expect(field.getMeta().errors).toEqual([]) + }) + + it('should run an onChange fn with zod validation option enabled', () => { + const form = new FormApi({ + defaultValues: { + name: '', + }, + validator: yupValidator, + }) + + const field = new FieldApi({ + form, + name: 'name', + onChange: (val) => (val === 'a' ? 'Test' : undefined), + }) + + field.mount() + + expect(field.getMeta().errors).toEqual([]) + field.setValue('a', { touch: true }) + expect(field.getMeta().errors).toEqual(['Test']) + field.setValue('asdf', { touch: true }) + expect(field.getMeta().errors).toEqual([]) + }) +}) diff --git a/packages/form-zod-adapter/src/tests/FieldApi.spec.ts b/packages/form-zod-adapter/src/tests/FieldApi.spec.ts index 2a82a3ca3..7ea732462 100644 --- a/packages/form-zod-adapter/src/tests/FieldApi.spec.ts +++ b/packages/form-zod-adapter/src/tests/FieldApi.spec.ts @@ -47,7 +47,6 @@ describe('zod field api', () => { field.mount() expect(field.getMeta().errors).toEqual([]) - debugger field.setValue('a', { touch: true }) expect(field.getMeta().errors).toEqual(['Test']) field.setValue('asdf', { touch: true }) diff --git a/packages/form-zod-adapter/src/tests/FormApi.spec.ts b/packages/form-zod-adapter/src/tests/FormApi.spec.ts new file mode 100644 index 000000000..973f7ed94 --- /dev/null +++ b/packages/form-zod-adapter/src/tests/FormApi.spec.ts @@ -0,0 +1,55 @@ +import { expect } from 'vitest' + +import { FormApi, FieldApi } from '@tanstack/form-core' +import { zodValidator } from '../validator' +import { z } from 'zod' + +describe('zod form api', () => { + it('should run an onChange with z.string validation', () => { + const form = new FormApi({ + defaultValues: { + name: '', + }, + validator: zodValidator + }) + + const field = new FieldApi({ + form, + name: 'name', + onChange: z.string().min(3, 'You must have a length of at least 3'), + }) + + field.mount() + + expect(field.getMeta().errors).toEqual([]) + field.setValue('a', { touch: true }) + expect(field.getMeta().errors).toEqual([ + 'You must have a length of at least 3', + ]) + field.setValue('asdf', { touch: true }) + expect(field.getMeta().errors).toEqual([]) + }) + + it('should run an onChange fn with zod validation option enabled', () => { + const form = new FormApi({ + defaultValues: { + name: '', + }, + validator: zodValidator + }) + + const field = new FieldApi({ + form, + name: 'name', + onChange: (val) => (val === 'a' ? 'Test' : undefined), + }) + + field.mount() + + expect(field.getMeta().errors).toEqual([]) + field.setValue('a', { touch: true }) + expect(field.getMeta().errors).toEqual(['Test']) + field.setValue('asdf', { touch: true }) + expect(field.getMeta().errors).toEqual([]) + }) +}) From 2a8ec5635ab6e8cd7d4fca59e582ad41ab7f81b7 Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Tue, 17 Oct 2023 06:15:39 -0700 Subject: [PATCH 27/37] chore: fix typings of async validation types --- packages/form-core/src/FieldApi.ts | 23 +++++++++++++++---- .../form-core/src/tests/FieldApi.test-d.ts | 18 +++++++++++++++ .../src/tests/FieldApi.test-d.ts | 15 ++++++++++++ .../src/tests/FormApi.test-d.ts | 15 ++++++++++++ 4 files changed, 67 insertions(+), 4 deletions(-) diff --git a/packages/form-core/src/FieldApi.ts b/packages/form-core/src/FieldApi.ts index b523382a7..6263a1735 100644 --- a/packages/form-core/src/FieldApi.ts +++ b/packages/form-core/src/FieldApi.ts @@ -35,13 +35,28 @@ type ValidateAsyncFn< TParentData, TName extends DeepKeys, ValidatorType, - FormValidator, TData extends DeepValue = DeepValue, > = ( value: TData, fieldApi: FieldApi, ) => ValidationError | Promise +type AsyncValidateOrFn< + TParentData, + TName extends DeepKeys, + ValidatorType, + FormValidator, + TData extends DeepValue = DeepValue, +> = ValidatorType extends Validator + ? + | Parameters['validate']>[1] + | ValidateAsyncFn + : FormValidator extends Validator + ? + | Parameters['validate']>[1] + | ValidateAsyncFn + : ValidateAsyncFn + export interface FieldOptions< TParentData, TName extends DeepKeys, @@ -65,7 +80,7 @@ export interface FieldOptions< FormValidator, TData > - onChangeAsync?: ValidateAsyncFn< + onChangeAsync?: AsyncValidateOrFn< TParentData, TName, ValidatorType, @@ -74,7 +89,7 @@ export interface FieldOptions< > onChangeAsyncDebounceMs?: number onBlur?: ValidateOrFn - onBlurAsync?: ValidateAsyncFn< + onBlurAsync?: AsyncValidateOrFn< TParentData, TName, ValidatorType, @@ -82,7 +97,7 @@ export interface FieldOptions< TData > onBlurAsyncDebounceMs?: number - onSubmitAsync?: ValidateAsyncFn< + onSubmitAsync?: AsyncValidateOrFn< TParentData, TName, ValidatorType, diff --git a/packages/form-core/src/tests/FieldApi.test-d.ts b/packages/form-core/src/tests/FieldApi.test-d.ts index 8fbe1ca07..32ac0d780 100644 --- a/packages/form-core/src/tests/FieldApi.test-d.ts +++ b/packages/form-core/src/tests/FieldApi.test-d.ts @@ -36,3 +36,21 @@ it('should type onChange properly', () => { }, }) }) + +it('should type onChangeAsync properly', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + } as const) + + const field = new FieldApi({ + form, + name: 'name', + onChangeAsync: async (value) => { + assertType<'test'>(value) + + return undefined + }, + }) +}) diff --git a/packages/form-zod-adapter/src/tests/FieldApi.test-d.ts b/packages/form-zod-adapter/src/tests/FieldApi.test-d.ts index 3937648f5..08e59d1de 100644 --- a/packages/form-zod-adapter/src/tests/FieldApi.test-d.ts +++ b/packages/form-zod-adapter/src/tests/FieldApi.test-d.ts @@ -32,6 +32,21 @@ it('should allow a Zod validator to handle the correct Zod type', () => { } as const) }) +it('should allow a Zod validator to handle the correct Zod type for an async method', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + }) + + const field = new FieldApi({ + form, + name: 'name', + validator: zodValidator, + onChangeAsync: z.string(), + } as const) +}) + it('should allow a functional onChange to be passed when using a validator', () => { const form = new FormApi({ defaultValues: { diff --git a/packages/form-zod-adapter/src/tests/FormApi.test-d.ts b/packages/form-zod-adapter/src/tests/FormApi.test-d.ts index 7d4282eff..2373f7f7e 100644 --- a/packages/form-zod-adapter/src/tests/FormApi.test-d.ts +++ b/packages/form-zod-adapter/src/tests/FormApi.test-d.ts @@ -27,6 +27,21 @@ it('should allow a Zod validator to handle the correct Zod type', () => { } as const) }) +it('should allow a Zod validator to handle the correct Zod type on async methods', () => { + const form = new FormApi({ + defaultValues: { + name: 'test', + }, + validator: zodValidator, + }) + + const field = new FieldApi({ + form, + name: 'name', + onChangeAsync: z.string(), + } as const) +}) + it('should allow a functional onChange to be passed when using a validator', () => { const form = new FormApi({ defaultValues: { From 037dee6081375da35f5a12cdb6f6c82c1ab3369b Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Tue, 17 Oct 2023 06:27:38 -0700 Subject: [PATCH 28/37] fix: async validation should now run as-expected more often --- packages/form-core/src/FieldApi.ts | 37 +++++++++++-- .../src/tests/FieldApi.spec.ts | 55 +++++++++++++++++++ packages/form-zod-adapter/src/tests/utils.ts | 5 ++ 3 files changed, 92 insertions(+), 5 deletions(-) create mode 100644 packages/form-zod-adapter/src/tests/utils.ts diff --git a/packages/form-core/src/FieldApi.ts b/packages/form-core/src/FieldApi.ts index 6263a1735..123a121a0 100644 --- a/packages/form-core/src/FieldApi.ts +++ b/packages/form-core/src/FieldApi.ts @@ -413,8 +413,9 @@ export class FieldApi< asyncDebounceMs ?? 0 - if (this.state.meta.isValidating !== true) + if (this.state.meta.isValidating !== true) { this.setMeta((prev) => ({ ...prev, isValidating: true })) + } // Use the validationCount for all field instances to // track freshness of the validation @@ -434,11 +435,31 @@ export class FieldApi< await new Promise((r) => setTimeout(r, debounceMs)) } + const doValidate = () => { + if (this.options.validator && typeof validate !== 'function') { + return (this.options.validator as Validator)().validateAsync( + value, + validate, + ) + } + + if (this.form.options.validator && typeof validate !== 'function') { + return ( + this.form.options.validator as Validator + )().validateAsync(value, validate) + } + + return (validate as ValidateFn)( + value, + this as never, + ) + } + // Only kick off validation if this validation is the latest attempt if (checkLatest()) { const prevErrors = this.getMeta().errors try { - const rawError = await validate(value as never, this as never) + const rawError = await doValidate() if (checkLatest()) { const error = normalizeError(rawError) this.setMeta((prev) => ({ @@ -474,12 +495,18 @@ export class FieldApi< ): ValidationError[] | Promise => { // If the field is pristine and validatePristine is false, do not validate if (!this.state.meta.isTouched) return [] + + // Store the previous error for the errorMapKey (eg. onChange, onBlur, onSubmit) + const errorMapKey = getErrorMapKey(cause) + const prevError = this.getMeta().errorMap[errorMapKey] + // Attempt to sync validate first this.validateSync(value, cause) - const errorMapKey = getErrorMapKey(cause) - // If there is an error mapped to the errorMapKey (eg. onChange, onBlur, onSubmit), return the errors array, do not attempt async validation - if (this.getMeta().errorMap[errorMapKey]) { + // If there is a new error mapped to the errorMapKey (eg. onChange, onBlur, onSubmit), return the errors array, do not attempt async validation + const newError = this.getMeta().errorMap[errorMapKey] + + if (prevError !== newError) { if (!this.options.asyncAlways) { return this.state.meta.errors } diff --git a/packages/form-zod-adapter/src/tests/FieldApi.spec.ts b/packages/form-zod-adapter/src/tests/FieldApi.spec.ts index 7ea732462..ff75073a5 100644 --- a/packages/form-zod-adapter/src/tests/FieldApi.spec.ts +++ b/packages/form-zod-adapter/src/tests/FieldApi.spec.ts @@ -3,6 +3,7 @@ import { expect } from 'vitest' import { FormApi, FieldApi } from '@tanstack/form-core' import { zodValidator } from '../validator' import { z } from 'zod' +import { sleep } from './utils' describe('zod field api', () => { it('should run an onChange with z.string validation', () => { @@ -52,4 +53,58 @@ describe('zod field api', () => { field.setValue('asdf', { touch: true }) expect(field.getMeta().errors).toEqual([]) }) + + it('should run an onChangeAsync with z.string validation', async () => { + const form = new FormApi({ + defaultValues: { + name: '', + }, + }) + + const field = new FieldApi({ + form, + validator: zodValidator, + name: 'name', + onChangeAsync: z.string().refine(async (val) => val.length > 3, { + message: 'Testing 123', + }), + onChangeAsyncDebounceMs: 0 + }) + + field.mount() + + expect(field.getMeta().errors).toEqual([]) + field.setValue('a', { touch: true }) + await sleep(10) + expect(field.getMeta().errors).toEqual(['Testing 123']) + field.setValue('asdf', { touch: true }) + await sleep(10) + expect(field.getMeta().errors).toEqual([]) + }) + + it('should run an onChange fn with zod validation option enabled', async () => { + const form = new FormApi({ + defaultValues: { + name: '', + }, + }) + + const field = new FieldApi({ + form, + validator: zodValidator, + name: 'name', + onChangeAsync: async (val) => (val === 'a' ? 'Test' : undefined), + onChangeAsyncDebounceMs: 0 + }) + + field.mount() + + expect(field.getMeta().errors).toEqual([]) + field.setValue('a', { touch: true }) + await sleep(10) + expect(field.getMeta().errors).toEqual(['Test']) + field.setValue('asdf', { touch: true }) + await sleep(10) + expect(field.getMeta().errors).toEqual([]) + }) }) diff --git a/packages/form-zod-adapter/src/tests/utils.ts b/packages/form-zod-adapter/src/tests/utils.ts new file mode 100644 index 000000000..1a3a619a2 --- /dev/null +++ b/packages/form-zod-adapter/src/tests/utils.ts @@ -0,0 +1,5 @@ +export function sleep(timeout: number): Promise { + return new Promise((resolve, _reject) => { + setTimeout(resolve, timeout) + }) +} From c77299780e48e568cd27f4d20bd0e2c4f3e519b4 Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Tue, 17 Oct 2023 08:00:41 -0700 Subject: [PATCH 29/37] chore: add async tests for Yup validator --- .../src/tests/FieldApi.spec.ts | 57 +++++++++++++++++++ packages/form-yup-adapter/src/tests/utils.ts | 5 ++ .../src/tests/FieldApi.spec.ts | 2 +- 3 files changed, 63 insertions(+), 1 deletion(-) create mode 100644 packages/form-yup-adapter/src/tests/utils.ts diff --git a/packages/form-yup-adapter/src/tests/FieldApi.spec.ts b/packages/form-yup-adapter/src/tests/FieldApi.spec.ts index fb809fb58..470f618f9 100644 --- a/packages/form-yup-adapter/src/tests/FieldApi.spec.ts +++ b/packages/form-yup-adapter/src/tests/FieldApi.spec.ts @@ -3,6 +3,7 @@ import { expect } from 'vitest' import { FormApi, FieldApi } from '@tanstack/form-core' import { yupValidator } from '../validator' import yup from 'yup' +import { sleep } from './utils' describe('yup field api', () => { it('should run an onChange with yup.string validation', () => { @@ -52,4 +53,60 @@ describe('yup field api', () => { field.setValue('asdf', { touch: true }) expect(field.getMeta().errors).toEqual([]) }) + + it('should run an onChangeAsync with z.string validation', async () => { + const form = new FormApi({ + defaultValues: { + name: '', + }, + }) + + const field = new FieldApi({ + form, + validator: yupValidator, + name: 'name', + onChangeAsync: yup + .string() + .test('Testing 123', 'Testing 123', async (val) => + typeof val === 'string' ? val.length > 3 : false, + ), + onChangeAsyncDebounceMs: 0, + }) + + field.mount() + + expect(field.getMeta().errors).toEqual([]) + field.setValue('a', { touch: true }) + await sleep(10) + expect(field.getMeta().errors).toEqual(['Testing 123']) + field.setValue('asdf', { touch: true }) + await sleep(10) + expect(field.getMeta().errors).toEqual([]) + }) + + it('should run an onChangeAsyc fn with zod validation option enabled', async () => { + const form = new FormApi({ + defaultValues: { + name: '', + }, + }) + + const field = new FieldApi({ + form, + validator: yupValidator, + name: 'name', + onChangeAsync: async (val) => (val === 'a' ? 'Test' : undefined), + onChangeAsyncDebounceMs: 0, + }) + + field.mount() + + expect(field.getMeta().errors).toEqual([]) + field.setValue('a', { touch: true }) + await sleep(10) + expect(field.getMeta().errors).toEqual(['Test']) + field.setValue('asdf', { touch: true }) + await sleep(10) + expect(field.getMeta().errors).toEqual([]) + }) }) diff --git a/packages/form-yup-adapter/src/tests/utils.ts b/packages/form-yup-adapter/src/tests/utils.ts new file mode 100644 index 000000000..1a3a619a2 --- /dev/null +++ b/packages/form-yup-adapter/src/tests/utils.ts @@ -0,0 +1,5 @@ +export function sleep(timeout: number): Promise { + return new Promise((resolve, _reject) => { + setTimeout(resolve, timeout) + }) +} diff --git a/packages/form-zod-adapter/src/tests/FieldApi.spec.ts b/packages/form-zod-adapter/src/tests/FieldApi.spec.ts index ff75073a5..74c729972 100644 --- a/packages/form-zod-adapter/src/tests/FieldApi.spec.ts +++ b/packages/form-zod-adapter/src/tests/FieldApi.spec.ts @@ -82,7 +82,7 @@ describe('zod field api', () => { expect(field.getMeta().errors).toEqual([]) }) - it('should run an onChange fn with zod validation option enabled', async () => { + it('should run an onChangeAsyc fn with zod validation option enabled', async () => { const form = new FormApi({ defaultValues: { name: '', From 347ef36fe7094025646dc75aee1932878f9a0a60 Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Tue, 17 Oct 2023 09:45:44 -0700 Subject: [PATCH 30/37] chore: rename packages to match naming schema better --- packages/{form-yup-adapter => yup-form-adapter}/.eslintrc.cjs | 0 packages/{form-yup-adapter => yup-form-adapter}/package.json | 2 +- packages/{form-yup-adapter => yup-form-adapter}/src/index.ts | 0 .../src/tests/FieldApi.spec.ts | 0 .../src/tests/FieldApi.test-d.ts | 0 .../src/tests/FormApi.spec.ts | 0 .../src/tests/FormApi.test-d.ts | 0 .../{form-yup-adapter => yup-form-adapter}/src/tests/utils.ts | 0 .../{form-yup-adapter => yup-form-adapter}/src/validator.ts | 0 .../{form-yup-adapter => yup-form-adapter}/tsconfig.eslint.json | 0 packages/{form-yup-adapter => yup-form-adapter}/tsconfig.json | 0 packages/{form-yup-adapter => yup-form-adapter}/tsup.config.js | 0 .../{form-yup-adapter => yup-form-adapter}/vitest.config.ts | 0 packages/{form-zod-adapter => zod-form-adapter}/.eslintrc.cjs | 0 packages/{form-zod-adapter => zod-form-adapter}/package.json | 2 +- packages/{form-zod-adapter => zod-form-adapter}/src/index.ts | 0 .../src/tests/FieldApi.spec.ts | 0 .../src/tests/FieldApi.test-d.ts | 0 .../src/tests/FormApi.spec.ts | 0 .../src/tests/FormApi.test-d.ts | 0 .../{form-zod-adapter => zod-form-adapter}/src/tests/utils.ts | 0 .../{form-zod-adapter => zod-form-adapter}/src/validator.ts | 0 .../{form-zod-adapter => zod-form-adapter}/tsconfig.eslint.json | 0 packages/{form-zod-adapter => zod-form-adapter}/tsconfig.json | 0 packages/{form-zod-adapter => zod-form-adapter}/tsup.config.js | 0 .../{form-zod-adapter => zod-form-adapter}/vitest.config.ts | 0 26 files changed, 2 insertions(+), 2 deletions(-) rename packages/{form-yup-adapter => yup-form-adapter}/.eslintrc.cjs (100%) rename packages/{form-yup-adapter => yup-form-adapter}/package.json (97%) rename packages/{form-yup-adapter => yup-form-adapter}/src/index.ts (100%) rename packages/{form-yup-adapter => yup-form-adapter}/src/tests/FieldApi.spec.ts (100%) rename packages/{form-yup-adapter => yup-form-adapter}/src/tests/FieldApi.test-d.ts (100%) rename packages/{form-yup-adapter => yup-form-adapter}/src/tests/FormApi.spec.ts (100%) rename packages/{form-yup-adapter => yup-form-adapter}/src/tests/FormApi.test-d.ts (100%) rename packages/{form-yup-adapter => yup-form-adapter}/src/tests/utils.ts (100%) rename packages/{form-yup-adapter => yup-form-adapter}/src/validator.ts (100%) rename packages/{form-yup-adapter => yup-form-adapter}/tsconfig.eslint.json (100%) rename packages/{form-yup-adapter => yup-form-adapter}/tsconfig.json (100%) rename packages/{form-yup-adapter => yup-form-adapter}/tsup.config.js (100%) rename packages/{form-yup-adapter => yup-form-adapter}/vitest.config.ts (100%) rename packages/{form-zod-adapter => zod-form-adapter}/.eslintrc.cjs (100%) rename packages/{form-zod-adapter => zod-form-adapter}/package.json (97%) rename packages/{form-zod-adapter => zod-form-adapter}/src/index.ts (100%) rename packages/{form-zod-adapter => zod-form-adapter}/src/tests/FieldApi.spec.ts (100%) rename packages/{form-zod-adapter => zod-form-adapter}/src/tests/FieldApi.test-d.ts (100%) rename packages/{form-zod-adapter => zod-form-adapter}/src/tests/FormApi.spec.ts (100%) rename packages/{form-zod-adapter => zod-form-adapter}/src/tests/FormApi.test-d.ts (100%) rename packages/{form-zod-adapter => zod-form-adapter}/src/tests/utils.ts (100%) rename packages/{form-zod-adapter => zod-form-adapter}/src/validator.ts (100%) rename packages/{form-zod-adapter => zod-form-adapter}/tsconfig.eslint.json (100%) rename packages/{form-zod-adapter => zod-form-adapter}/tsconfig.json (100%) rename packages/{form-zod-adapter => zod-form-adapter}/tsup.config.js (100%) rename packages/{form-zod-adapter => zod-form-adapter}/vitest.config.ts (100%) diff --git a/packages/form-yup-adapter/.eslintrc.cjs b/packages/yup-form-adapter/.eslintrc.cjs similarity index 100% rename from packages/form-yup-adapter/.eslintrc.cjs rename to packages/yup-form-adapter/.eslintrc.cjs diff --git a/packages/form-yup-adapter/package.json b/packages/yup-form-adapter/package.json similarity index 97% rename from packages/form-yup-adapter/package.json rename to packages/yup-form-adapter/package.json index 4407ff92d..b7bd9894b 100644 --- a/packages/form-yup-adapter/package.json +++ b/packages/yup-form-adapter/package.json @@ -1,5 +1,5 @@ { - "name": "@tanstack/form-yup-adapter", + "name": "@tanstack/yup-form-adapter", "version": "0.3.6", "description": "The Yup adapter for TanStack Form.", "author": "tannerlinsley", diff --git a/packages/form-yup-adapter/src/index.ts b/packages/yup-form-adapter/src/index.ts similarity index 100% rename from packages/form-yup-adapter/src/index.ts rename to packages/yup-form-adapter/src/index.ts diff --git a/packages/form-yup-adapter/src/tests/FieldApi.spec.ts b/packages/yup-form-adapter/src/tests/FieldApi.spec.ts similarity index 100% rename from packages/form-yup-adapter/src/tests/FieldApi.spec.ts rename to packages/yup-form-adapter/src/tests/FieldApi.spec.ts diff --git a/packages/form-yup-adapter/src/tests/FieldApi.test-d.ts b/packages/yup-form-adapter/src/tests/FieldApi.test-d.ts similarity index 100% rename from packages/form-yup-adapter/src/tests/FieldApi.test-d.ts rename to packages/yup-form-adapter/src/tests/FieldApi.test-d.ts diff --git a/packages/form-yup-adapter/src/tests/FormApi.spec.ts b/packages/yup-form-adapter/src/tests/FormApi.spec.ts similarity index 100% rename from packages/form-yup-adapter/src/tests/FormApi.spec.ts rename to packages/yup-form-adapter/src/tests/FormApi.spec.ts diff --git a/packages/form-yup-adapter/src/tests/FormApi.test-d.ts b/packages/yup-form-adapter/src/tests/FormApi.test-d.ts similarity index 100% rename from packages/form-yup-adapter/src/tests/FormApi.test-d.ts rename to packages/yup-form-adapter/src/tests/FormApi.test-d.ts diff --git a/packages/form-yup-adapter/src/tests/utils.ts b/packages/yup-form-adapter/src/tests/utils.ts similarity index 100% rename from packages/form-yup-adapter/src/tests/utils.ts rename to packages/yup-form-adapter/src/tests/utils.ts diff --git a/packages/form-yup-adapter/src/validator.ts b/packages/yup-form-adapter/src/validator.ts similarity index 100% rename from packages/form-yup-adapter/src/validator.ts rename to packages/yup-form-adapter/src/validator.ts diff --git a/packages/form-yup-adapter/tsconfig.eslint.json b/packages/yup-form-adapter/tsconfig.eslint.json similarity index 100% rename from packages/form-yup-adapter/tsconfig.eslint.json rename to packages/yup-form-adapter/tsconfig.eslint.json diff --git a/packages/form-yup-adapter/tsconfig.json b/packages/yup-form-adapter/tsconfig.json similarity index 100% rename from packages/form-yup-adapter/tsconfig.json rename to packages/yup-form-adapter/tsconfig.json diff --git a/packages/form-yup-adapter/tsup.config.js b/packages/yup-form-adapter/tsup.config.js similarity index 100% rename from packages/form-yup-adapter/tsup.config.js rename to packages/yup-form-adapter/tsup.config.js diff --git a/packages/form-yup-adapter/vitest.config.ts b/packages/yup-form-adapter/vitest.config.ts similarity index 100% rename from packages/form-yup-adapter/vitest.config.ts rename to packages/yup-form-adapter/vitest.config.ts diff --git a/packages/form-zod-adapter/.eslintrc.cjs b/packages/zod-form-adapter/.eslintrc.cjs similarity index 100% rename from packages/form-zod-adapter/.eslintrc.cjs rename to packages/zod-form-adapter/.eslintrc.cjs diff --git a/packages/form-zod-adapter/package.json b/packages/zod-form-adapter/package.json similarity index 97% rename from packages/form-zod-adapter/package.json rename to packages/zod-form-adapter/package.json index 8b2798691..9bcb29c42 100644 --- a/packages/form-zod-adapter/package.json +++ b/packages/zod-form-adapter/package.json @@ -1,5 +1,5 @@ { - "name": "@tanstack/form-zod-adapter", + "name": "@tanstack/zod-form-adapter", "version": "0.3.6", "description": "The Zod adapter for TanStack Form.", "author": "tannerlinsley", diff --git a/packages/form-zod-adapter/src/index.ts b/packages/zod-form-adapter/src/index.ts similarity index 100% rename from packages/form-zod-adapter/src/index.ts rename to packages/zod-form-adapter/src/index.ts diff --git a/packages/form-zod-adapter/src/tests/FieldApi.spec.ts b/packages/zod-form-adapter/src/tests/FieldApi.spec.ts similarity index 100% rename from packages/form-zod-adapter/src/tests/FieldApi.spec.ts rename to packages/zod-form-adapter/src/tests/FieldApi.spec.ts diff --git a/packages/form-zod-adapter/src/tests/FieldApi.test-d.ts b/packages/zod-form-adapter/src/tests/FieldApi.test-d.ts similarity index 100% rename from packages/form-zod-adapter/src/tests/FieldApi.test-d.ts rename to packages/zod-form-adapter/src/tests/FieldApi.test-d.ts diff --git a/packages/form-zod-adapter/src/tests/FormApi.spec.ts b/packages/zod-form-adapter/src/tests/FormApi.spec.ts similarity index 100% rename from packages/form-zod-adapter/src/tests/FormApi.spec.ts rename to packages/zod-form-adapter/src/tests/FormApi.spec.ts diff --git a/packages/form-zod-adapter/src/tests/FormApi.test-d.ts b/packages/zod-form-adapter/src/tests/FormApi.test-d.ts similarity index 100% rename from packages/form-zod-adapter/src/tests/FormApi.test-d.ts rename to packages/zod-form-adapter/src/tests/FormApi.test-d.ts diff --git a/packages/form-zod-adapter/src/tests/utils.ts b/packages/zod-form-adapter/src/tests/utils.ts similarity index 100% rename from packages/form-zod-adapter/src/tests/utils.ts rename to packages/zod-form-adapter/src/tests/utils.ts diff --git a/packages/form-zod-adapter/src/validator.ts b/packages/zod-form-adapter/src/validator.ts similarity index 100% rename from packages/form-zod-adapter/src/validator.ts rename to packages/zod-form-adapter/src/validator.ts diff --git a/packages/form-zod-adapter/tsconfig.eslint.json b/packages/zod-form-adapter/tsconfig.eslint.json similarity index 100% rename from packages/form-zod-adapter/tsconfig.eslint.json rename to packages/zod-form-adapter/tsconfig.eslint.json diff --git a/packages/form-zod-adapter/tsconfig.json b/packages/zod-form-adapter/tsconfig.json similarity index 100% rename from packages/form-zod-adapter/tsconfig.json rename to packages/zod-form-adapter/tsconfig.json diff --git a/packages/form-zod-adapter/tsup.config.js b/packages/zod-form-adapter/tsup.config.js similarity index 100% rename from packages/form-zod-adapter/tsup.config.js rename to packages/zod-form-adapter/tsup.config.js diff --git a/packages/form-zod-adapter/vitest.config.ts b/packages/zod-form-adapter/vitest.config.ts similarity index 100% rename from packages/form-zod-adapter/vitest.config.ts rename to packages/zod-form-adapter/vitest.config.ts From 04c0d4ab8943352ebbf78bb1f03e5a8e40e2692c Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Tue, 17 Oct 2023 10:27:03 -0700 Subject: [PATCH 31/37] chore: add Zod examples for React and Vue --- examples/react/simple/package.json | 4 +- examples/react/simple/src/index.tsx | 2 +- examples/react/zod/.eslintrc.cjs | 15 +++ examples/react/zod/.gitignore | 27 +++++ examples/react/zod/.prettierrc | 1 + examples/react/zod/README.md | 6 ++ examples/react/zod/index.html | 16 +++ examples/react/zod/package.json | 49 +++++++++ examples/react/zod/public/emblem-light.svg | 13 +++ examples/react/zod/src/index.tsx | 113 ++++++++++++++++++++ examples/react/zod/tsconfig.json | 7 ++ examples/vue/zod/.gitignore | 9 ++ examples/vue/zod/README.md | 6 ++ examples/vue/zod/index.html | 12 +++ examples/vue/zod/package.json | 38 +++++++ examples/vue/zod/src/App.vue | 88 ++++++++++++++++ examples/vue/zod/src/FieldInfo.vue | 12 +++ examples/vue/zod/src/main.ts | 5 + examples/vue/zod/src/shims-vue.d.ts | 5 + examples/vue/zod/src/types.d.ts | 6 ++ examples/vue/zod/tsconfig.json | 15 +++ examples/vue/zod/vite.config.ts | 10 ++ package.json | 4 +- pnpm-lock.yaml | 117 ++++++++++++++++----- 24 files changed, 546 insertions(+), 34 deletions(-) create mode 100644 examples/react/zod/.eslintrc.cjs create mode 100644 examples/react/zod/.gitignore create mode 100644 examples/react/zod/.prettierrc create mode 100644 examples/react/zod/README.md create mode 100644 examples/react/zod/index.html create mode 100644 examples/react/zod/package.json create mode 100644 examples/react/zod/public/emblem-light.svg create mode 100644 examples/react/zod/src/index.tsx create mode 100644 examples/react/zod/tsconfig.json create mode 100644 examples/vue/zod/.gitignore create mode 100644 examples/vue/zod/README.md create mode 100644 examples/vue/zod/index.html create mode 100644 examples/vue/zod/package.json create mode 100644 examples/vue/zod/src/App.vue create mode 100644 examples/vue/zod/src/FieldInfo.vue create mode 100644 examples/vue/zod/src/main.ts create mode 100644 examples/vue/zod/src/shims-vue.d.ts create mode 100644 examples/vue/zod/src/types.d.ts create mode 100644 examples/vue/zod/tsconfig.json create mode 100644 examples/vue/zod/vite.config.ts diff --git a/examples/react/simple/package.json b/examples/react/simple/package.json index 4848925f9..8f19f777b 100644 --- a/examples/react/simple/package.json +++ b/examples/react/simple/package.json @@ -12,9 +12,7 @@ "axios": "^0.26.1", "react": "^18.0.0", "react-dom": "^18.0.0", - "zod": "^3.21.4", - "@tanstack/form-core": "0.3.7", - "@tanstack/vue-form": "0.3.7" + "@tanstack/form-core": "0.3.7" }, "devDependencies": { "@vitejs/plugin-react": "^4.0.4", diff --git a/examples/react/simple/src/index.tsx b/examples/react/simple/src/index.tsx index 920f9cfb1..295009d16 100644 --- a/examples/react/simple/src/index.tsx +++ b/examples/react/simple/src/index.tsx @@ -3,7 +3,7 @@ import { createRoot } from "react-dom/client"; import { useForm } from "@tanstack/react-form"; import type { FieldApi } from "@tanstack/react-form"; -function FieldInfo({ field }: { field: FieldApi }) { +function FieldInfo({ field }: { field: FieldApi }) { return ( <> {field.state.meta.touchedErrors ? ( diff --git a/examples/react/zod/.eslintrc.cjs b/examples/react/zod/.eslintrc.cjs new file mode 100644 index 000000000..201e65392 --- /dev/null +++ b/examples/react/zod/.eslintrc.cjs @@ -0,0 +1,15 @@ +// @ts-check + +/** @type {import('eslint').Linter.Config} */ +const config = { + extends: ["plugin:react/recommended", "plugin:react-hooks/recommended"], + parserOptions: { + tsconfigRootDir: __dirname, + project: "./tsconfig.json", + }, + rules: { + "react/no-children-prop": "off", + }, +}; + +module.exports = config; diff --git a/examples/react/zod/.gitignore b/examples/react/zod/.gitignore new file mode 100644 index 000000000..4673b022e --- /dev/null +++ b/examples/react/zod/.gitignore @@ -0,0 +1,27 @@ +# See https://help.github.com/articles/ignoring-files/ for more about ignoring files. + +# dependencies +/node_modules +/.pnp +.pnp.js + +# testing +/coverage + +# production +/build + +pnpm-lock.yaml +yarn.lock +package-lock.json + +# misc +.DS_Store +.env.local +.env.development.local +.env.test.local +.env.production.local + +npm-debug.log* +yarn-debug.log* +yarn-error.log* diff --git a/examples/react/zod/.prettierrc b/examples/react/zod/.prettierrc new file mode 100644 index 000000000..0967ef424 --- /dev/null +++ b/examples/react/zod/.prettierrc @@ -0,0 +1 @@ +{} diff --git a/examples/react/zod/README.md b/examples/react/zod/README.md new file mode 100644 index 000000000..1cf889265 --- /dev/null +++ b/examples/react/zod/README.md @@ -0,0 +1,6 @@ +# Example + +To run this example: + +- `npm install` +- `npm run dev` diff --git a/examples/react/zod/index.html b/examples/react/zod/index.html new file mode 100644 index 000000000..c6a75da4b --- /dev/null +++ b/examples/react/zod/index.html @@ -0,0 +1,16 @@ + + + + + + + + + TanStack Form React Simple Example App + + + +
+ + + diff --git a/examples/react/zod/package.json b/examples/react/zod/package.json new file mode 100644 index 000000000..6b8369213 --- /dev/null +++ b/examples/react/zod/package.json @@ -0,0 +1,49 @@ +{ + "name": "@tanstack/form-example-react-simple", + "version": "0.0.1", + "main": "src/index.jsx", + "scripts": { + "dev": "vite --port=3001", + "build": "vite build", + "preview": "vite preview" + }, + "dependencies": { + "@tanstack/react-form": "0.3.7", + "axios": "^0.26.1", + "react": "^18.0.0", + "react-dom": "^18.0.0", + "zod": "^3.21.4", + "@tanstack/form-core": "0.3.7", + "@tanstack/zod-form-adapter": "0.3.7" + }, + "devDependencies": { + "@vitejs/plugin-react": "^4.0.4", + "vite": "^4.4.9" + }, + "browserslist": { + "production": [ + ">0.2%", + "not dead", + "not op_mini all" + ], + "development": [ + "last 1 chrome version", + "last 1 firefox version", + "last 1 safari version" + ] + }, + "nx": { + "implicitDependencies": [ + "@tanstack/form-core", + "@tanstack/react-form", + "@tanstack/zod-form-adapter" + ], + "targets": { + "test:types": { + "dependsOn": [ + "build" + ] + } + } + } +} diff --git a/examples/react/zod/public/emblem-light.svg b/examples/react/zod/public/emblem-light.svg new file mode 100644 index 000000000..a58e69ad5 --- /dev/null +++ b/examples/react/zod/public/emblem-light.svg @@ -0,0 +1,13 @@ + + + + emblem-light + Created with Sketch. + + + + + + + + \ No newline at end of file diff --git a/examples/react/zod/src/index.tsx b/examples/react/zod/src/index.tsx new file mode 100644 index 000000000..cdddba424 --- /dev/null +++ b/examples/react/zod/src/index.tsx @@ -0,0 +1,113 @@ +import * as React from "react"; +import { createRoot } from "react-dom/client"; +import { useForm } from "@tanstack/react-form"; +import { zodValidator } from "@tanstack/zod-form-adapter"; +import { z } from "zod"; +import type { FieldApi } from "@tanstack/react-form"; + +function FieldInfo({ field }: { field: FieldApi }) { + return ( + <> + {field.state.meta.touchedErrors ? ( + {field.state.meta.touchedErrors} + ) : null} + {field.state.meta.isValidating ? "Validating..." : null} + + ); +} + +export default function App() { + const form = useForm({ + // Memoize your default values to prevent re-renders + defaultValues: { + firstName: "", + lastName: "", + }, + onSubmit: async (values) => { + // Do something with form data + console.log(values); + }, + // Add a validator to support Zod usage in Form and Field + validator: zodValidator, + }); + + return ( +
+

Simple Form Example

+ {/* A pre-bound form component */} + + { + e.preventDefault(); + e.stopPropagation(); + void form.handleSubmit(); + }} + > +
+ {/* A type-safe and pre-bound field component*/} + { + await new Promise((resolve) => setTimeout(resolve, 1000)); + return !value.includes("error"); + }, + { + message: "No 'error' allowed in first name", + }, + )} + children={(field) => { + // Avoid hasty abstractions. Render props are great! + return ( + <> + + field.handleChange(e.target.value)} + /> + + + ); + }} + /> +
+
+ ( + <> + + field.handleChange(e.target.value)} + /> + + + )} + /> +
+ [state.canSubmit, state.isSubmitting]} + children={([canSubmit, isSubmitting]) => ( + + )} + /> + +
+
+ ); +} + +const rootElement = document.getElementById("root")!; + +createRoot(rootElement).render(); diff --git a/examples/react/zod/tsconfig.json b/examples/react/zod/tsconfig.json new file mode 100644 index 000000000..a306172a7 --- /dev/null +++ b/examples/react/zod/tsconfig.json @@ -0,0 +1,7 @@ +{ + "compilerOptions": { + "jsx": "react", + "noEmit": true, + "lib": ["DOM", "DOM.Iterable", "ES2020"] + } +} diff --git a/examples/vue/zod/.gitignore b/examples/vue/zod/.gitignore new file mode 100644 index 000000000..449e8098b --- /dev/null +++ b/examples/vue/zod/.gitignore @@ -0,0 +1,9 @@ +node_modules +.DS_Store +dist +dist-ssr +*.local + +package-lock.json +yarn.lock +pnpm-lock.yaml diff --git a/examples/vue/zod/README.md b/examples/vue/zod/README.md new file mode 100644 index 000000000..28462a4ad --- /dev/null +++ b/examples/vue/zod/README.md @@ -0,0 +1,6 @@ +# Basic example + +To run this example: + +- `npm install` or `yarn` or `pnpm i` +- `npm run dev` or `yarn dev` or `pnpm dev` diff --git a/examples/vue/zod/index.html b/examples/vue/zod/index.html new file mode 100644 index 000000000..37e0b73a7 --- /dev/null +++ b/examples/vue/zod/index.html @@ -0,0 +1,12 @@ + + + + + + Vue Form Example + + +
+ + + diff --git a/examples/vue/zod/package.json b/examples/vue/zod/package.json new file mode 100644 index 000000000..d58522d5e --- /dev/null +++ b/examples/vue/zod/package.json @@ -0,0 +1,38 @@ +{ + "name": "@tanstack/form-example-vue-simple", + "private": true, + "scripts": { + "dev": "vite", + "build": "vite build", + "build:dev": "vite build -m development", + "test:types": "vue-tsc --noEmit", + "serve": "vite preview" + }, + "dependencies": { + "@tanstack/form-core": "0.3.7", + "@tanstack/vue-form": "0.3.7", + "@tanstack/react-form": "0.3.7", + "@tanstack/zod-form-adapter": "0.3.7", + "vue": "^3.3.4", + "zod": "^3.21.4" + }, + "devDependencies": { + "@vitejs/plugin-vue": "^4.3.4", + "typescript": "^5.0.4", + "vite": "^4.4.9", + "vue-tsc": "^1.8.10" + }, + "nx": { + "implicitDependencies": [ + "@tanstack/form-core", + "@tanstack/vue-form" + ], + "targets": { + "test:types": { + "dependsOn": [ + "build" + ] + } + } + } +} diff --git a/examples/vue/zod/src/App.vue b/examples/vue/zod/src/App.vue new file mode 100644 index 000000000..ae9cd3b35 --- /dev/null +++ b/examples/vue/zod/src/App.vue @@ -0,0 +1,88 @@ + + + diff --git a/examples/vue/zod/src/FieldInfo.vue b/examples/vue/zod/src/FieldInfo.vue new file mode 100644 index 000000000..997fd5ba6 --- /dev/null +++ b/examples/vue/zod/src/FieldInfo.vue @@ -0,0 +1,12 @@ + + + diff --git a/examples/vue/zod/src/main.ts b/examples/vue/zod/src/main.ts new file mode 100644 index 000000000..912d54f8d --- /dev/null +++ b/examples/vue/zod/src/main.ts @@ -0,0 +1,5 @@ +import { createApp } from 'vue' + +import App from './App.vue' + +createApp(App).mount('#app') diff --git a/examples/vue/zod/src/shims-vue.d.ts b/examples/vue/zod/src/shims-vue.d.ts new file mode 100644 index 000000000..ac1ded792 --- /dev/null +++ b/examples/vue/zod/src/shims-vue.d.ts @@ -0,0 +1,5 @@ +declare module '*.vue' { + import { DefineComponent } from 'vue' + const component: DefineComponent<{}, {}, any> + export default component +} diff --git a/examples/vue/zod/src/types.d.ts b/examples/vue/zod/src/types.d.ts new file mode 100644 index 000000000..4851e8102 --- /dev/null +++ b/examples/vue/zod/src/types.d.ts @@ -0,0 +1,6 @@ +export interface Post { + userId: number + id: number + title: string + body: string +} diff --git a/examples/vue/zod/tsconfig.json b/examples/vue/zod/tsconfig.json new file mode 100644 index 000000000..7ca59bce5 --- /dev/null +++ b/examples/vue/zod/tsconfig.json @@ -0,0 +1,15 @@ +{ + "compilerOptions": { + "target": "esnext", + "module": "esnext", + "moduleResolution": "node", + "strict": true, + "jsx": "preserve", + "sourceMap": true, + "resolveJsonModule": true, + "esModuleInterop": true, + "lib": ["esnext", "dom"], + "types": ["vite/client"] + }, + "include": ["src/**/*.ts", "src/**/*.d.ts", "src/**/*.vue"] +} diff --git a/examples/vue/zod/vite.config.ts b/examples/vue/zod/vite.config.ts new file mode 100644 index 000000000..e2529e6f2 --- /dev/null +++ b/examples/vue/zod/vite.config.ts @@ -0,0 +1,10 @@ +import { defineConfig } from 'vite' +import createVuePlugin from '@vitejs/plugin-vue' + +// https://vitejs.dev/config/ +export default defineConfig({ + plugins: [createVuePlugin()], + optimizeDeps: { + exclude: ['@tanstack/vue-query', 'vue-demi'], + }, +}) diff --git a/package.json b/package.json index 64f31a7be..50a423681 100644 --- a/package.json +++ b/package.json @@ -114,7 +114,9 @@ "overrides": { "@tanstack/form-core": "workspace:*", "@tanstack/react-form": "workspace:*", - "@tanstack/vue-form": "workspace:*" + "@tanstack/vue-form": "workspace:*", + "@tanstack/yup-form-adapter": "workspace:*", + "@tanstack/zod-form-adapter": "workspace:*" } } } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 719f2c532..b96567915 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -1,9 +1,15 @@ lockfileVersion: '6.0' +settings: + autoInstallPeers: true + excludeLinksFromLockfile: false + overrides: '@tanstack/form-core': workspace:* '@tanstack/react-form': workspace:* '@tanstack/vue-form': workspace:* + '@tanstack/yup-form-adapter': workspace:* + '@tanstack/zod-form-adapter': workspace:* patchedDependencies: '@types/testing-library__jest-dom@5.14.5': @@ -242,9 +248,37 @@ importers: react-dom: specifier: ^18.0.0 version: 18.2.0(react@18.2.0) + devDependencies: + '@vitejs/plugin-react': + specifier: ^4.0.4 + version: 4.0.4(vite@4.4.9) + vite: + specifier: ^4.4.9 + version: 4.4.9(@types/node@17.0.45) + + examples/react/zod: + dependencies: + '@tanstack/form-core': + specifier: workspace:* + version: link:../../../packages/form-core + '@tanstack/react-form': + specifier: workspace:* + version: link:../../../packages/react-form + '@tanstack/zod-form-adapter': + specifier: workspace:* + version: link:../../../packages/zod-form-adapter + axios: + specifier: ^0.26.1 + version: 0.26.1 + react: + specifier: ^18.0.0 + version: 18.2.0 + react-dom: + specifier: ^18.0.0 + version: 18.2.0(react@18.2.0) zod: specifier: ^3.21.4 - version: 3.22.2 + version: 3.22.4 devDependencies: '@vitejs/plugin-react': specifier: ^4.0.4 @@ -281,31 +315,45 @@ importers: specifier: ^1.8.10 version: 1.8.10(typescript@5.2.2) - packages/form-core: - dependencies: - '@tanstack/store': - specifier: 0.1.3 - version: 0.1.3 - - packages/form-yup-adapter: + examples/vue/zod: dependencies: '@tanstack/form-core': specifier: workspace:* - version: link:../form-core - devDependencies: - yup: - specifier: ^1.3.2 - version: 1.3.2 - - packages/form-zod-adapter: - dependencies: - '@tanstack/form-core': + version: link:../../../packages/form-core + '@tanstack/react-form': specifier: workspace:* - version: link:../form-core - devDependencies: + version: link:../../../packages/react-form + '@tanstack/vue-form': + specifier: workspace:* + version: link:../../../packages/vue-form + '@tanstack/zod-form-adapter': + specifier: workspace:* + version: link:../../../packages/zod-form-adapter + vue: + specifier: ^3.3.4 + version: 3.3.4 zod: - specifier: ^3.22.4 + specifier: ^3.21.4 version: 3.22.4 + devDependencies: + '@vitejs/plugin-vue': + specifier: ^4.3.4 + version: 4.3.4(vite@4.4.9)(vue@3.3.4) + typescript: + specifier: ^5.0.4 + version: 5.2.2 + vite: + specifier: ^4.4.9 + version: 4.4.9(@types/node@17.0.45) + vue-tsc: + specifier: ^1.8.10 + version: 1.8.10(typescript@5.2.2) + + packages/form-core: + dependencies: + '@tanstack/store': + specifier: 0.1.3 + version: 0.1.3 packages/react-form: dependencies: @@ -375,6 +423,26 @@ importers: specifier: npm:vue@2.7 version: /vue@2.7.14 + packages/yup-form-adapter: + dependencies: + '@tanstack/form-core': + specifier: workspace:* + version: link:../form-core + devDependencies: + yup: + specifier: ^1.3.2 + version: 1.3.2 + + packages/zod-form-adapter: + dependencies: + '@tanstack/form-core': + specifier: workspace:* + version: link:../form-core + devDependencies: + zod: + specifier: ^3.22.4 + version: 3.22.4 + packages: /@aashutoshrathi/word-wrap@1.2.6: @@ -10017,14 +10085,5 @@ packages: type-fest: 2.19.0 dev: true - /zod@3.22.2: - resolution: {integrity: sha512-wvWkphh5WQsJbVk1tbx1l1Ly4yg+XecD+Mq280uBGt9wa5BKSWf4Mhp6GmrkPixhMxmabYY7RbzlwVP32pbGCg==} - dev: false - /zod@3.22.4: resolution: {integrity: sha512-iC+8Io04lddc+mVqQ9AZ7OQ2MrUKGN+oIQyq1vemgt46jwCwLfhq7/pwnBnNXXXZb8VTVLKwp9EDkx+ryxIWmg==} - dev: true - -settings: - autoInstallPeers: true - excludeLinksFromLockfile: false From f1432542b0f8c0ecd249eb64c149b30eebbfb322 Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Tue, 17 Oct 2023 10:37:49 -0700 Subject: [PATCH 32/37] chore: add React and Vue Yup support --- examples/react/yup/.eslintrc.cjs | 15 +++ examples/react/yup/.gitignore | 27 +++++ examples/react/yup/.prettierrc | 1 + examples/react/yup/README.md | 6 ++ examples/react/yup/index.html | 16 +++ examples/react/yup/package.json | 49 +++++++++ examples/react/yup/public/emblem-light.svg | 13 +++ examples/react/yup/src/index.tsx | 114 +++++++++++++++++++++ examples/react/yup/tsconfig.json | 7 ++ examples/react/zod/index.html | 2 +- examples/react/zod/package.json | 2 +- examples/vue/simple/index.html | 2 +- examples/vue/simple/package.json | 3 +- examples/vue/yup/.gitignore | 9 ++ examples/vue/yup/README.md | 6 ++ examples/vue/yup/index.html | 12 +++ examples/vue/yup/package.json | 38 +++++++ examples/vue/yup/src/App.vue | 87 ++++++++++++++++ examples/vue/yup/src/FieldInfo.vue | 12 +++ examples/vue/yup/src/main.ts | 5 + examples/vue/yup/src/shims-vue.d.ts | 5 + examples/vue/yup/src/types.d.ts | 6 ++ examples/vue/yup/tsconfig.json | 15 +++ examples/vue/yup/vite.config.ts | 10 ++ examples/vue/zod/index.html | 2 +- examples/vue/zod/package.json | 6 +- pnpm-lock.yaml | 75 +++++++++++--- 27 files changed, 523 insertions(+), 22 deletions(-) create mode 100644 examples/react/yup/.eslintrc.cjs create mode 100644 examples/react/yup/.gitignore create mode 100644 examples/react/yup/.prettierrc create mode 100644 examples/react/yup/README.md create mode 100644 examples/react/yup/index.html create mode 100644 examples/react/yup/package.json create mode 100644 examples/react/yup/public/emblem-light.svg create mode 100644 examples/react/yup/src/index.tsx create mode 100644 examples/react/yup/tsconfig.json create mode 100644 examples/vue/yup/.gitignore create mode 100644 examples/vue/yup/README.md create mode 100644 examples/vue/yup/index.html create mode 100644 examples/vue/yup/package.json create mode 100644 examples/vue/yup/src/App.vue create mode 100644 examples/vue/yup/src/FieldInfo.vue create mode 100644 examples/vue/yup/src/main.ts create mode 100644 examples/vue/yup/src/shims-vue.d.ts create mode 100644 examples/vue/yup/src/types.d.ts create mode 100644 examples/vue/yup/tsconfig.json create mode 100644 examples/vue/yup/vite.config.ts diff --git a/examples/react/yup/.eslintrc.cjs b/examples/react/yup/.eslintrc.cjs new file mode 100644 index 000000000..201e65392 --- /dev/null +++ b/examples/react/yup/.eslintrc.cjs @@ -0,0 +1,15 @@ +// @ts-check + +/** @type {import('eslint').Linter.Config} */ +const config = { + extends: ["plugin:react/recommended", "plugin:react-hooks/recommended"], + parserOptions: { + tsconfigRootDir: __dirname, + project: "./tsconfig.json", + }, + rules: { + "react/no-children-prop": "off", + }, +}; + +module.exports = config; diff --git a/examples/react/yup/.gitignore b/examples/react/yup/.gitignore new file mode 100644 index 000000000..4673b022e --- /dev/null +++ b/examples/react/yup/.gitignore @@ -0,0 +1,27 @@ +# See https://help.github.com/articles/ignoring-files/ for more about ignoring files. + +# dependencies +/node_modules +/.pnp +.pnp.js + +# testing +/coverage + +# production +/build + +pnpm-lock.yaml +yarn.lock +package-lock.json + +# misc +.DS_Store +.env.local +.env.development.local +.env.test.local +.env.production.local + +npm-debug.log* +yarn-debug.log* +yarn-error.log* diff --git a/examples/react/yup/.prettierrc b/examples/react/yup/.prettierrc new file mode 100644 index 000000000..0967ef424 --- /dev/null +++ b/examples/react/yup/.prettierrc @@ -0,0 +1 @@ +{} diff --git a/examples/react/yup/README.md b/examples/react/yup/README.md new file mode 100644 index 000000000..1cf889265 --- /dev/null +++ b/examples/react/yup/README.md @@ -0,0 +1,6 @@ +# Example + +To run this example: + +- `npm install` +- `npm run dev` diff --git a/examples/react/yup/index.html b/examples/react/yup/index.html new file mode 100644 index 000000000..d717e9d86 --- /dev/null +++ b/examples/react/yup/index.html @@ -0,0 +1,16 @@ + + + + + + + + + TanStack Form React Yup Example App + + + +
+ + + diff --git a/examples/react/yup/package.json b/examples/react/yup/package.json new file mode 100644 index 000000000..82662790e --- /dev/null +++ b/examples/react/yup/package.json @@ -0,0 +1,49 @@ +{ + "name": "@tanstack/form-example-react-yup", + "version": "0.0.1", + "main": "src/index.jsx", + "scripts": { + "dev": "vite --port=3001", + "build": "vite build", + "preview": "vite preview" + }, + "dependencies": { + "@tanstack/react-form": "0.3.7", + "axios": "^0.26.1", + "react": "^18.0.0", + "react-dom": "^18.0.0", + "yup": "^1.3.2", + "@tanstack/form-core": "0.3.7", + "@tanstack/yup-form-adapter": "0.3.7" + }, + "devDependencies": { + "@vitejs/plugin-react": "^4.0.4", + "vite": "^4.4.9" + }, + "browserslist": { + "production": [ + ">0.2%", + "not dead", + "not op_mini all" + ], + "development": [ + "last 1 chrome version", + "last 1 firefox version", + "last 1 safari version" + ] + }, + "nx": { + "implicitDependencies": [ + "@tanstack/form-core", + "@tanstack/react-form", + "@tanstack/yup-form-adapter" + ], + "targets": { + "test:types": { + "dependsOn": [ + "build" + ] + } + } + } +} diff --git a/examples/react/yup/public/emblem-light.svg b/examples/react/yup/public/emblem-light.svg new file mode 100644 index 000000000..a58e69ad5 --- /dev/null +++ b/examples/react/yup/public/emblem-light.svg @@ -0,0 +1,13 @@ + + + + emblem-light + Created with Sketch. + + + + + + + + \ No newline at end of file diff --git a/examples/react/yup/src/index.tsx b/examples/react/yup/src/index.tsx new file mode 100644 index 000000000..38d15e79f --- /dev/null +++ b/examples/react/yup/src/index.tsx @@ -0,0 +1,114 @@ +import * as React from "react"; +import { createRoot } from "react-dom/client"; +import { useForm } from "@tanstack/react-form"; +import { yupValidator } from "@tanstack/yup-form-adapter"; +import * as yup from "yup"; +import type { FieldApi } from "@tanstack/react-form"; + +function FieldInfo({ field }: { field: FieldApi }) { + return ( + <> + {field.state.meta.touchedErrors ? ( + {field.state.meta.touchedErrors} + ) : null} + {field.state.meta.isValidating ? "Validating..." : null} + + ); +} + +export default function App() { + const form = useForm({ + // Memoize your default values to prevent re-renders + defaultValues: { + firstName: "", + lastName: "", + }, + onSubmit: async (values) => { + // Do something with form data + console.log(values); + }, + // Add a validator to support Yup usage in Form and Field + validator: yupValidator, + }); + + return ( +
+

Simple Form Example

+ {/* A pre-bound form component */} + +
{ + e.preventDefault(); + e.stopPropagation(); + void form.handleSubmit(); + }} + > +
+ {/* A type-safe and pre-bound field component*/} + { + await new Promise((resolve) => setTimeout(resolve, 1000)); + return !value.includes("error"); + }, + )} + children={(field) => { + // Avoid hasty abstractions. Render props are great! + return ( + <> + + field.handleChange(e.target.value)} + /> + + + ); + }} + /> +
+
+ ( + <> + + field.handleChange(e.target.value)} + /> + + + )} + /> +
+ [state.canSubmit, state.isSubmitting]} + children={([canSubmit, isSubmitting]) => ( + + )} + /> + +
+
+ ); +} + +const rootElement = document.getElementById("root")!; + +createRoot(rootElement).render(); diff --git a/examples/react/yup/tsconfig.json b/examples/react/yup/tsconfig.json new file mode 100644 index 000000000..a306172a7 --- /dev/null +++ b/examples/react/yup/tsconfig.json @@ -0,0 +1,7 @@ +{ + "compilerOptions": { + "jsx": "react", + "noEmit": true, + "lib": ["DOM", "DOM.Iterable", "ES2020"] + } +} diff --git a/examples/react/zod/index.html b/examples/react/zod/index.html index c6a75da4b..d8b732d0c 100644 --- a/examples/react/zod/index.html +++ b/examples/react/zod/index.html @@ -6,7 +6,7 @@ - TanStack Form React Simple Example App + TanStack Form React Zod Example App diff --git a/examples/react/zod/package.json b/examples/react/zod/package.json index 6b8369213..da33dc61c 100644 --- a/examples/react/zod/package.json +++ b/examples/react/zod/package.json @@ -1,5 +1,5 @@ { - "name": "@tanstack/form-example-react-simple", + "name": "@tanstack/form-example-react-zod", "version": "0.0.1", "main": "src/index.jsx", "scripts": { diff --git a/examples/vue/simple/index.html b/examples/vue/simple/index.html index 37e0b73a7..6d49c196c 100644 --- a/examples/vue/simple/index.html +++ b/examples/vue/simple/index.html @@ -3,7 +3,7 @@ - Vue Form Example + TanStack Form Vue Simple Example App
diff --git a/examples/vue/simple/package.json b/examples/vue/simple/package.json index f680a3c68..4834987a0 100644 --- a/examples/vue/simple/package.json +++ b/examples/vue/simple/package.json @@ -11,8 +11,7 @@ "dependencies": { "@tanstack/form-core": "0.3.7", "@tanstack/vue-form": "0.3.7", - "vue": "^3.3.4", - "@tanstack/react-form": "0.3.7" + "vue": "^3.3.4" }, "devDependencies": { "@vitejs/plugin-vue": "^4.3.4", diff --git a/examples/vue/yup/.gitignore b/examples/vue/yup/.gitignore new file mode 100644 index 000000000..449e8098b --- /dev/null +++ b/examples/vue/yup/.gitignore @@ -0,0 +1,9 @@ +node_modules +.DS_Store +dist +dist-ssr +*.local + +package-lock.json +yarn.lock +pnpm-lock.yaml diff --git a/examples/vue/yup/README.md b/examples/vue/yup/README.md new file mode 100644 index 000000000..28462a4ad --- /dev/null +++ b/examples/vue/yup/README.md @@ -0,0 +1,6 @@ +# Basic example + +To run this example: + +- `npm install` or `yarn` or `pnpm i` +- `npm run dev` or `yarn dev` or `pnpm dev` diff --git a/examples/vue/yup/index.html b/examples/vue/yup/index.html new file mode 100644 index 000000000..22909ec82 --- /dev/null +++ b/examples/vue/yup/index.html @@ -0,0 +1,12 @@ + + + + + + TanStack Form Vue Yup Example App + + +
+ + + diff --git a/examples/vue/yup/package.json b/examples/vue/yup/package.json new file mode 100644 index 000000000..109810748 --- /dev/null +++ b/examples/vue/yup/package.json @@ -0,0 +1,38 @@ +{ + "name": "@tanstack/form-example-vue-yup", + "private": true, + "scripts": { + "dev": "vite", + "build": "vite build", + "build:dev": "vite build -m development", + "test:types": "vue-tsc --noEmit", + "serve": "vite preview" + }, + "dependencies": { + "@tanstack/form-core": "0.3.7", + "@tanstack/vue-form": "0.3.7", + "@tanstack/yup-form-adapter": "0.3.7", + "vue": "^3.3.4", + "yup": "^1.3.2" + }, + "devDependencies": { + "@vitejs/plugin-vue": "^4.3.4", + "typescript": "^5.0.4", + "vite": "^4.4.9", + "vue-tsc": "^1.8.10" + }, + "nx": { + "implicitDependencies": [ + "@tanstack/form-core", + "@tanstack/vue-form", + "@tanstack/yup-form-adapter" + ], + "targets": { + "test:types": { + "dependsOn": [ + "build" + ] + } + } + } +} diff --git a/examples/vue/yup/src/App.vue b/examples/vue/yup/src/App.vue new file mode 100644 index 000000000..4050e4cdf --- /dev/null +++ b/examples/vue/yup/src/App.vue @@ -0,0 +1,87 @@ + + + diff --git a/examples/vue/yup/src/FieldInfo.vue b/examples/vue/yup/src/FieldInfo.vue new file mode 100644 index 000000000..997fd5ba6 --- /dev/null +++ b/examples/vue/yup/src/FieldInfo.vue @@ -0,0 +1,12 @@ + + + diff --git a/examples/vue/yup/src/main.ts b/examples/vue/yup/src/main.ts new file mode 100644 index 000000000..912d54f8d --- /dev/null +++ b/examples/vue/yup/src/main.ts @@ -0,0 +1,5 @@ +import { createApp } from 'vue' + +import App from './App.vue' + +createApp(App).mount('#app') diff --git a/examples/vue/yup/src/shims-vue.d.ts b/examples/vue/yup/src/shims-vue.d.ts new file mode 100644 index 000000000..ac1ded792 --- /dev/null +++ b/examples/vue/yup/src/shims-vue.d.ts @@ -0,0 +1,5 @@ +declare module '*.vue' { + import { DefineComponent } from 'vue' + const component: DefineComponent<{}, {}, any> + export default component +} diff --git a/examples/vue/yup/src/types.d.ts b/examples/vue/yup/src/types.d.ts new file mode 100644 index 000000000..4851e8102 --- /dev/null +++ b/examples/vue/yup/src/types.d.ts @@ -0,0 +1,6 @@ +export interface Post { + userId: number + id: number + title: string + body: string +} diff --git a/examples/vue/yup/tsconfig.json b/examples/vue/yup/tsconfig.json new file mode 100644 index 000000000..7ca59bce5 --- /dev/null +++ b/examples/vue/yup/tsconfig.json @@ -0,0 +1,15 @@ +{ + "compilerOptions": { + "target": "esnext", + "module": "esnext", + "moduleResolution": "node", + "strict": true, + "jsx": "preserve", + "sourceMap": true, + "resolveJsonModule": true, + "esModuleInterop": true, + "lib": ["esnext", "dom"], + "types": ["vite/client"] + }, + "include": ["src/**/*.ts", "src/**/*.d.ts", "src/**/*.vue"] +} diff --git a/examples/vue/yup/vite.config.ts b/examples/vue/yup/vite.config.ts new file mode 100644 index 000000000..e2529e6f2 --- /dev/null +++ b/examples/vue/yup/vite.config.ts @@ -0,0 +1,10 @@ +import { defineConfig } from 'vite' +import createVuePlugin from '@vitejs/plugin-vue' + +// https://vitejs.dev/config/ +export default defineConfig({ + plugins: [createVuePlugin()], + optimizeDeps: { + exclude: ['@tanstack/vue-query', 'vue-demi'], + }, +}) diff --git a/examples/vue/zod/index.html b/examples/vue/zod/index.html index 37e0b73a7..0fd1027b6 100644 --- a/examples/vue/zod/index.html +++ b/examples/vue/zod/index.html @@ -3,7 +3,7 @@ - Vue Form Example + TanStack Form Vue Zod Example App
diff --git a/examples/vue/zod/package.json b/examples/vue/zod/package.json index d58522d5e..a17507491 100644 --- a/examples/vue/zod/package.json +++ b/examples/vue/zod/package.json @@ -1,5 +1,5 @@ { - "name": "@tanstack/form-example-vue-simple", + "name": "@tanstack/form-example-vue-zod", "private": true, "scripts": { "dev": "vite", @@ -11,7 +11,6 @@ "dependencies": { "@tanstack/form-core": "0.3.7", "@tanstack/vue-form": "0.3.7", - "@tanstack/react-form": "0.3.7", "@tanstack/zod-form-adapter": "0.3.7", "vue": "^3.3.4", "zod": "^3.21.4" @@ -25,7 +24,8 @@ "nx": { "implicitDependencies": [ "@tanstack/form-core", - "@tanstack/vue-form" + "@tanstack/vue-form", + "@tanstack/zod-form-adapter" ], "targets": { "test:types": { diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index b96567915..ff5574652 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -236,9 +236,34 @@ importers: '@tanstack/react-form': specifier: workspace:* version: link:../../../packages/react-form - '@tanstack/vue-form': + axios: + specifier: ^0.26.1 + version: 0.26.1 + react: + specifier: ^18.0.0 + version: 18.2.0 + react-dom: + specifier: ^18.0.0 + version: 18.2.0(react@18.2.0) + devDependencies: + '@vitejs/plugin-react': + specifier: ^4.0.4 + version: 4.0.4(vite@4.4.9) + vite: + specifier: ^4.4.9 + version: 4.4.9(@types/node@17.0.45) + + examples/react/yup: + dependencies: + '@tanstack/form-core': specifier: workspace:* - version: link:../../../packages/vue-form + version: link:../../../packages/form-core + '@tanstack/react-form': + specifier: workspace:* + version: link:../../../packages/react-form + '@tanstack/yup-form-adapter': + specifier: workspace:* + version: link:../../../packages/yup-form-adapter axios: specifier: ^0.26.1 version: 0.26.1 @@ -248,6 +273,9 @@ importers: react-dom: specifier: ^18.0.0 version: 18.2.0(react@18.2.0) + yup: + specifier: ^1.3.2 + version: 1.3.2 devDependencies: '@vitejs/plugin-react': specifier: ^4.0.4 @@ -292,15 +320,43 @@ importers: '@tanstack/form-core': specifier: workspace:* version: link:../../../packages/form-core - '@tanstack/react-form': + '@tanstack/vue-form': specifier: workspace:* - version: link:../../../packages/react-form + version: link:../../../packages/vue-form + vue: + specifier: ^3.3.4 + version: 3.3.4 + devDependencies: + '@vitejs/plugin-vue': + specifier: ^4.3.4 + version: 4.3.4(vite@4.4.9)(vue@3.3.4) + typescript: + specifier: ^5.0.4 + version: 5.2.2 + vite: + specifier: ^4.4.9 + version: 4.4.9(@types/node@17.0.45) + vue-tsc: + specifier: ^1.8.10 + version: 1.8.10(typescript@5.2.2) + + examples/vue/yup: + dependencies: + '@tanstack/form-core': + specifier: workspace:* + version: link:../../../packages/form-core '@tanstack/vue-form': specifier: workspace:* version: link:../../../packages/vue-form + '@tanstack/yup-form-adapter': + specifier: workspace:* + version: link:../../../packages/yup-form-adapter vue: specifier: ^3.3.4 version: 3.3.4 + yup: + specifier: ^1.3.2 + version: 1.3.2 devDependencies: '@vitejs/plugin-vue': specifier: ^4.3.4 @@ -320,9 +376,6 @@ importers: '@tanstack/form-core': specifier: workspace:* version: link:../../../packages/form-core - '@tanstack/react-form': - specifier: workspace:* - version: link:../../../packages/react-form '@tanstack/vue-form': specifier: workspace:* version: link:../../../packages/vue-form @@ -5669,7 +5722,7 @@ packages: fs.realpath: 1.0.0 inflight: 1.0.6 inherits: 2.0.4 - minimatch: 3.0.5 + minimatch: 3.1.2 once: 1.4.0 path-is-absolute: 1.0.1 @@ -7316,6 +7369,7 @@ packages: resolution: {integrity: sha512-tUpxzX0VAzJHjLu0xUfFv1gwVp9ba3IOuRAVH2EGuRW8a5emA2FlACLqiT/lDVtS1W+TGNwqz3sWaNyLgDJWuw==} dependencies: brace-expansion: 1.1.11 + dev: true /minimatch@3.1.2: resolution: {integrity: sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==} @@ -8091,7 +8145,6 @@ packages: /property-expr@2.0.6: resolution: {integrity: sha512-SVtmxhRE/CGkn3eZY1T6pC8Nln6Fr/lu1mKSgRud0eC73whjGfoAogbn78LkD8aFL0zz3bAFerKSnOl7NlErBA==} - dev: true /proto-list@1.2.4: resolution: {integrity: sha512-vtK/94akxsTMhe0/cbfpR+syPuszcuwhqVjJq26CuNDgFGj682oRBXOP5MJpv2r7JtE8MsiepGIqvvOTBwn2vA==} @@ -9141,7 +9194,6 @@ packages: /tiny-case@1.0.3: resolution: {integrity: sha512-Eet/eeMhkO6TX8mnUteS9zgPbUMQa4I6Kkp5ORiBD5476/m+PIRiumP5tmh5ioJpH7k51Kehawy2UDfsnxxY8Q==} - dev: true /tinybench@2.5.0: resolution: {integrity: sha512-kRwSG8Zx4tjF9ZiyH4bhaebu+EDz1BOx9hOigYHlUW4xxI/wKIUQUqo018UlU4ar6ATPBsaMrdbKZ+tmPdohFA==} @@ -9184,7 +9236,6 @@ packages: /toposort@2.0.2: resolution: {integrity: sha512-0a5EOkAUp8D4moMi2W8ZF8jcga7BgZd91O/yabJCFY8az+XSzeGyTKs0Aoo897iV1Nj6guFq8orWDS96z91oGg==} - dev: true /tough-cookie@4.1.3: resolution: {integrity: sha512-aX/y5pVRkfRnfmuX+OdbSdXvPe6ieKX/G2s7e98f4poJHnqH3281gDPm/metm6E/WRamfx7WC4HUqkWHfQHprw==} @@ -9368,7 +9419,6 @@ packages: /type-fest@2.19.0: resolution: {integrity: sha512-RAH822pAdBgcNMAfWnCBU3CFZcfZ/i1eZjwFU/dsLKumyuuP3niueg2UAukXYF0E2AAoc82ZSSf9J0WQBinzHA==} engines: {node: '>=12.20'} - dev: true /type-fest@3.13.1: resolution: {integrity: sha512-tLq3bSNx+xSpwvAJnzrK0Ep5CLNWjvFTOp71URMaAEWBfRb9nnJiBoUe0tF8bI4ZFO3omgBR6NvnbzVUT3Ly4g==} @@ -10083,7 +10133,6 @@ packages: tiny-case: 1.0.3 toposort: 2.0.2 type-fest: 2.19.0 - dev: true /zod@3.22.4: resolution: {integrity: sha512-iC+8Io04lddc+mVqQ9AZ7OQ2MrUKGN+oIQyq1vemgt46jwCwLfhq7/pwnBnNXXXZb8VTVLKwp9EDkx+ryxIWmg==} From b7452eaa28f77090ad224fd2fb380c7066ce743c Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Tue, 17 Oct 2023 10:39:13 -0700 Subject: [PATCH 33/37] chore: fix formatting --- examples/vue/zod/src/App.vue | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/examples/vue/zod/src/App.vue b/examples/vue/zod/src/App.vue index ae9cd3b35..30d59b31f 100644 --- a/examples/vue/zod/src/App.vue +++ b/examples/vue/zod/src/App.vue @@ -43,7 +43,9 @@ const onChangeFirstName = z.string().refine(
From a5ce5e3a79db4bc0e8febaa09c537b660d0371d5 Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Tue, 17 Oct 2023 11:04:41 -0700 Subject: [PATCH 34/37] chore: fix CI types --- examples/vue/yup/src/App.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/vue/yup/src/App.vue b/examples/vue/yup/src/App.vue index 4050e4cdf..44b30fb00 100644 --- a/examples/vue/yup/src/App.vue +++ b/examples/vue/yup/src/App.vue @@ -23,7 +23,7 @@ const onChangeFirstName = yup .string() .test('no-error', "No 'error' allowed in first name", async (value) => { await new Promise((resolve) => setTimeout(resolve, 1000)) - return !value.includes('error') + return !value?.includes('error') }) From 7b0e6b011462799f1e03a7779ac2745224a6fa3c Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Tue, 17 Oct 2023 23:16:37 -0700 Subject: [PATCH 35/37] chore: initial work to drastically improve docs --- docs/installation.md | 13 +++- docs/reference/fieldApi.md | 134 +++++++++++++++---------------------- 2 files changed, 65 insertions(+), 82 deletions(-) diff --git a/docs/installation.md b/docs/installation.md index b2c090b6b..ec50d39d1 100644 --- a/docs/installation.md +++ b/docs/installation.md @@ -3,11 +3,20 @@ id: installation title: Installation --- -While the core of TanStack Form is framework-agnostic and will be compatible with various front-end frameworks in the future, we only support React today. -To use TanStack Form with React, install the adapter via NPM +TanStack Form is compatible with various front-end frameworks, including React and Vue. To use TanStack Form with your desired framework, install the corresponding adapter via NPM: ```bash $ npm i @tanstack/react-form +# or +$ pnpm add @tanstack/vue-form ``` > Depending on your environment, you might need to add polyfills. If you want to support older browsers, you need to transpile the library from `node_modules` yourselves. + +In addition, we support both Zod and Yup as validators through official validator packages: + +```bash +$ yarn add @tanstack/zod-form-adapter zod +# or +$ npm i @tanstack/yup-form-adapter yup +``` diff --git a/docs/reference/fieldApi.md b/docs/reference/fieldApi.md index 9934fa464..78ca18524 100644 --- a/docs/reference/fieldApi.md +++ b/docs/reference/fieldApi.md @@ -11,24 +11,44 @@ Normally, you will not need to create a new `FieldApi` instance directly. Instea const fieldApi: FieldApi = new FieldApi(formOptions: Field Options) ``` -### `FieldOptions` +### `FieldOptions` An object type representing the options for a field in a form. - ```tsx - name + name: TName ``` - - The field name. If `TParentData` is `unknown`, the type will be `string`. Otherwise, it will be `DeepKeys`. + - The field name. The type will be `DeepKeys` to ensure your name is a deep key of the parent dataset. + - ```tsx defaultValue?: TData ``` - An optional default value for the field. + - ```tsx defaultMeta?: Partial ``` - An optional object with default metadata for the field. +- ```tsx + asyncDebounceMs?: number + ``` + + - The default time to debounce async validation if there is not a more specific debounce time passed. + +- ```tsx + asyncAlways?: boolean + ``` + + - If `true`, always run async validation, even if there are errors emitted during synchronous validation. + +- ```typescript + validator?: ValidatorType + ``` + + - A validator provided by an extension, like `yupValidator` from `@tanstack/yup-form-adapter` + - ```tsx onMount?: (formApi: FieldApi) => void ``` @@ -36,35 +56,35 @@ An object type representing the options for a field in a form. - An optional function that takes a param of `formApi` which is a generic type of `TData` and `TParentData` - ```tsx - onChange?: ValidateFn + onChange?: ValidateFn ``` - - An optional property that takes a `ValidateFn` which is a generic of `TData` and `TParentData` + - An optional property that takes a `ValidateFn` which is a generic of `TData` and `TParentData`. If `validator` is passed, this may also accept a property from the respective validator (IE: `z.string().min(1)` if `zodAdapter` is passed) - ```tsx - onChangeAsync?: ValidateAsyncFn + onChangeAsync?: ValidateAsyncFn ``` - - An optional property similar to `onChange` but async validation + - An optional property similar to `onChange` but async validation. If `validator` is passed, this may also accept a property from the respective validator (IE: `z.string().refine(async (val) => val.length > 3, { message: 'Testing 123' })` if `zodAdapter` is passed) - ```tsx - onChangeAsyncDebounceMs?: number + onChangeAsyncDebounceMs?: number ``` - An optional number to represent how long the `onChangeAsync` should wait before running - If set to a number larger than 0, will debounce the async validation event by this length of time in milliseconds - ```tsx - onBlur?: ValidateFn + onBlur?: ValidateFn ``` - - An optional function, when that run when subscribing to blur event of input + - An optional function, when that run when subscribing to blur event of input. If `validator` is passed, this may also accept a property from the respective validator (IE: `z.string().min(1)` if `zodAdapter` is passed) - ```tsx - onBlurAsync?: ValidateAsyncFn + onBlurAsync?: ValidateAsyncFn ``` - - An optional function that takes a `ValidateFn` which is a generic of `TData` and `TParentData` happens async + - An optional function that takes a `ValidateFn` which is a generic of `TData` and `TParentData` happens async. If `validator` is passed, this may also accept a property from the respective validator (IE: `z.string().refine(async (val) => val.length > 3, { message: 'Testing 123' })` if `zodAdapter` is passed) ```tsx onBlurAsyncDebounceMs?: number @@ -77,13 +97,15 @@ An object type representing the options for a field in a form. onSubmitAsync?: number ``` - - If set to a number larger than 0, will debounce the async validation event by this length of time in milliseconds + - If set to a number larger than 0, will debounce the async validation event by this length of time in milliseconds. If `validator` is passed, this may also accept a property from the respective validator (IE: `z.string().refine(async (val) => val.length > 3, { message: 'Testing 123' })` if `zodAdapter` is passed) ### `ValidationCause` A type representing the cause of a validation event. -- 'change' | 'blur' | 'submit' | 'mount' +- ```tsx + 'change' | 'blur' | 'submit' | 'mount' + ``` ### `FieldMeta` @@ -127,7 +149,7 @@ A class representing the API for managing a form field. ``` - A unique identifier for the field instance. - ```tsx - form: FormApi + form: FormApi ``` - A reference to the form API instance. - ```tsx @@ -153,66 +175,77 @@ A class representing the API for managing a form field. constructor(opts: FieldApiOptions) ``` - Initializes a new `FieldApi` instance. + - ```tsx mount(): () => void ``` - Mounts the field instance to the form. -- ```tsx - updateStore(): void - ``` - - Updates the field store with the latest form state. + - ```tsx update(opts: FieldApiOptions): void ``` - Updates the field instance with new options. + - ```tsx getValue(): TData ``` - Gets the current field value. + - ```tsx setValue(updater: Updater, options?: { touch?: boolean; notify?: boolean }): void ``` - - Sets the field value. + - Sets the field value and run the `change` validator. + - ```tsx getMeta(): FieldMeta ``` - Gets the current field metadata. + - ```tsx setMeta(updater: Updater): void ``` - Sets the field metadata. + - ```tsx getInfo(): any ``` - Gets the field information object. + - ```tsx pushValue(value: TData): void ``` - Pushes a new value to the field. + - ```tsx insertValue(index: number, value: TData): void ``` - Inserts a value at the specified index. + - ```tsx removeValue(index: number): void ``` - Removes a value at the specified index. + - ```tsx swapValues(aIndex: number, bIndex: number): void ``` - Swaps the values at the specified indices. + - ```tsx - getSubField>(name: TName): FieldApi, TParentData> + getSubField(name: TName): FieldApi ``` - Gets a subfield instance. + - ```tsx validate(): Promise ``` - Validates the field value. + - ```tsx handleBlur(): void; ``` - Handles the blur event. + - ```tsx handleChange(value: TData): void ``` @@ -231,62 +264,3 @@ An object type representing the state of a field. ``` - The current metadata of the field. -### `UserChangeProps` - -An object type representing the change and blur event handlers for a field. - -- ```tsx - onChange?: (value: TData) => void - ``` - - An optional function to further handle the change event. -- ```tsx - onBlur?: (event: any) => void - ``` - - An optional function to further handle the blur event. - -### `UserInputProps` - -An object type representing the input event handlers for a field. - -- ```tsx - onChange?: (event: any) => void - ``` - - An optional function to further handle the change event. -- ```tsx - onBlur?: (event: any) => void - ``` - - An optional function to further handle the blur event. - -### `ChangeProps` - -An object type representing the change and blur event handlers for a field. - -- ```tsx - value: TData - ``` - - The current value of the field. -- ```tsx - onChange: (value: TData) => void - ``` - - A function to handle the change event. -- ```tsx - onBlur: (event: any) => void - ``` - - A function to handle the blur event. - -### `InputProps` - -An object type representing the input event handlers for a field. - -- ```tsx - value: string - ``` - - The current value of the field, coerced to a string. -- ```tsx - onChange: (event: any) => void - ``` - - A function to handle the change event. -- ```tsx - onBlur: (event: any) => void - ``` - - A function to handle the blur event. From fa8480959bf25df0b4288e6b3d956ddc5b0d7f28 Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Wed, 18 Oct 2023 02:04:00 -0700 Subject: [PATCH 36/37] docs: improve docs for validation --- docs/config.json | 24 +++- docs/guides/basic-concepts.md | 38 ++++-- docs/guides/important-defaults.md | 21 --- docs/guides/validation.md | 211 ++++++++++++++++++++++++++++++ docs/reference/formApi.md | 14 +- 5 files changed, 269 insertions(+), 39 deletions(-) delete mode 100644 docs/guides/important-defaults.md create mode 100644 docs/guides/validation.md diff --git a/docs/config.json b/docs/config.json index e5d319959..37a38b04b 100644 --- a/docs/config.json +++ b/docs/config.json @@ -30,8 +30,12 @@ "label": "Guides", "children": [ { - "label": "Important Defaults", - "to": "guides/important-defaults" + "label": "Basic Concepts", + "to": "guides/basic-concepts" + }, + { + "label": "Form Validation", + "to": "guides/validation" } ] }, @@ -89,6 +93,14 @@ { "label": "Simple", "to": "framework/react/examples/simple" + }, + { + "label": "Yup", + "to": "framework/react/examples/yup" + }, + { + "label": "Zod", + "to": "framework/react/examples/zod" } ] } @@ -133,6 +145,14 @@ { "label": "Simple", "to": "framework/vue/examples/simple" + }, + { + "label": "Yup", + "to": "framework/vue/examples/yup" + }, + { + "label": "Zod", + "to": "framework/vue/examples/zod" } ] } diff --git a/docs/guides/basic-concepts.md b/docs/guides/basic-concepts.md index ed891eab0..d8492051e 100644 --- a/docs/guides/basic-concepts.md +++ b/docs/guides/basic-concepts.md @@ -5,9 +5,7 @@ title: Basic Concepts and Terminology # Basic Concepts and Terminology -> Some of these docs may be inaccurate due to an API shift in `0.11.0`. If you're interested in helping us fix these issues, please [join our Discord](https://tlinz.com/discord) and reach out in the `#form` channel. - -This page introduces the basic concepts and terminology used in the @tanstack/react-form library. Familiarizing yourself with these concepts will help you better understand and work with the library. +This page introduces the basic concepts and terminology used in the `@tanstack/react-form` library. Familiarizing yourself with these concepts will help you better understand and work with the library. ## Form Factory @@ -86,7 +84,7 @@ Example: ## Validation -@tanstack/react-form provides both synchronous and asynchronous validation out of the box. Validation functions can be passed to the form.Field component using the validate and validateAsync props. +`@tanstack/react-form` provides both synchronous and asynchronous validation out of the box. Validation functions can be passed to the form.Field component using the validate and validateAsync props. Example: @@ -111,9 +109,34 @@ Example: /> ``` +## Validation Adapters + +In addition to hand-rolled validation options, we also provide adapters like `@tanstack/zod-form-adapter` and `@tanstack/yup-form-adapter` to enable usage with common schema validation tools like [Yup](https://github.com/jquense/yup) and [Zod](https://zod.dev/). + +Example: + +```tsx + { + await new Promise((resolve) => setTimeout(resolve, 1000)); + return !value.includes("error"); + }, + { + message: "No 'error' allowed in first name", + }, + )} +/> +``` + ## Reactivity -@tanstack/react-form offers various ways to subscribe to form and field state changes, such as the form.useStore hook, the form.Subscribe component, and the form.useField hook. These methods allow you to optimize your form's rendering performance by only updating components when necessary. +`@tanstack/react-form` offers various ways to subscribe to form and field state changes, such as the `form.useStore` hook, the `form.Subscribe` component, and the `form.useField` hook. These methods allow you to optimize your form's rendering performance by only updating components when necessary. Example: @@ -240,8 +263,5 @@ Example: /> ``` -These are the basic concepts and terminology used in the @tanstack/react-form library. Understanding these concepts will help you work more effectively with the library and create complex forms with ease. +These are the basic concepts and terminology used in the `@tanstack/react-form` library. Understanding these concepts will help you work more effectively with the library and create complex forms with ease. -``` - -``` diff --git a/docs/guides/important-defaults.md b/docs/guides/important-defaults.md deleted file mode 100644 index d958531f4..000000000 --- a/docs/guides/important-defaults.md +++ /dev/null @@ -1,21 +0,0 @@ ---- -id: important-defaults -title: Important Defaults ---- - -> Some of these docs may be inaccurate due to an API shift in `0.11.0`. If you're interested in helping us fix these issues, please [join our Discord](https://tlinz.com/discord) and reach out in the `#form` channel. - -Out of the box, TanStack Form is configured with **aggressive but sane** defaults. **Sometimes these defaults can catch new users off guard or make learning/debugging difficult if they are unknown by the user.** Keep them in mind as you continue to learn and use TanStack Form: - -- Core - - Validation - - By default, only touched, dirty fields are validated on blur and submit. This means that if you have a field that is required, it will not show an error until the user has blurred the field (focused and unfocused) or submitted the form. You can change this to include field `change` events or only the `submit` event with a form default or on a per field basis with the `defaultValidateOn` and `validateOn` options. `validatePristine` can also be used to validate pristine fields. - - By default, TanStack async validation will only run if synchronous validation succeeds. This is to prevent unnecessary async validation which usually are powered by network requests. - - By default, TanStack Form will not validate fields that are not registered. This is to prevent unnecessary validation of fields that are not in the DOM. This can be changed with the `validateUnregistered` option. -- React - - Reactivity - - The `useForm` hook and `form.Form` component are not reactive, which means that as _any_ form state changes, they will not rerender. If they did, you would likely run into performance problems very quickly. Instead, use: - - `form.useStore` to subscribe and rerender when form state changes. Selectors are supported. - - `form.Subscribe` to render a specific sub-tree of UI that is subscribed to the form state. Selectors are supported. - - `form.useField` to subscribe to a specific field's state changes. - - `form.Field` **is reactive** to all state changes that happen within a field. This means that as a field's value, error, touched, etc. changes, the component you use it in will rerender. This is a good thing because it means you don't have to worry about manually subscribing to a field's state changes. diff --git a/docs/guides/validation.md b/docs/guides/validation.md new file mode 100644 index 000000000..345c4cd59 --- /dev/null +++ b/docs/guides/validation.md @@ -0,0 +1,211 @@ +--- +id: form-validation +title: Form and Field Validation +--- + +# Form and Field Validation + +At the core of TanStack Form's functionalities is the concept of validation. We currently support three mechanisms of validation: + +- Synchronous functional validation +- Asynchronous functional validation +- Adapter-based validation + +Let's take a look at each and see how they're built. + +## Synchronous Functional Validation + +With Form, you can pass a function to a field and, if it returns a string, said string will be used as the error: + +```tsx + val < 13 ? "You must be 13 to make an account" : undefined} + children={(field) => { + return ( + <> + + field.handleChange(e.target.valueAsNumber)} + /> + {field.state.meta.touchedErrors ? ( + {field.state.meta.touchedErrors} + ) : null} + + ); + }} +/> +``` + +### Displaying Errors + +Once you have your validation in place, you can map the errors from an array to be displayed in your UI: + +```tsx + val < 13 ? "You must be 13 to make an account" : undefined} + children={(field) => { + return ( + <> + {/* ... */} + {field.state.meta.errors ? ( + {field.state.meta.errors} + ) : null} + + ); + }} +/> +``` + +Or use the `errorMap` property to access the specific error you're looking for: + +```tsx + val < 13 ? "You must be 13 to make an account" : undefined} + children={(field) => { + return ( + <> + {/* ... */} + {field.state.meta.errorMap['onChange'] ? ( + {field.state.meta.errorMap['onChange']} + ) : null} + + ); + }} +/> +``` + +### Using Alternative Validation Steps + +One of the great benefits of using TanStack Form is that you're not locked into a specific method of validation. For example, if you want to validate a specific field on blur rather than on text change, you can change `onChange` to `onBlur`: + +```tsx + val < 13 ? "You must be 13 to make an account" : undefined} + children={(field) => { + return ( + <> + {/* ... */} + + ); + }} +/> +``` + +## Asynchronous Functional Validation + +While we suspect most validations will be synchronous, there's many instances where a network call or some other async operation would be useful to validate against. + +To do this, we have dedicated `onChangeAsync`, `onBlurAsync`, and other methods that can be used to validate against: + +```tsx + { + await new Promise((resolve) => setTimeout(resolve, 1000)); + return ( + value.includes("error") && 'No "error" allowed in first name' + ); + }} + children={(field) => { + return ( + <> + + field.handleChange(e.target.value)} + /> + + + ); + }} +/> +``` + +This can be combined with the respective synchronous properties as well: + +``` tsx + + !value + ? "A first name is required" + : value.length < 3 + ? "First name must be at least 3 characters" + : undefined + } + onChangeAsync={async (value) => { + await new Promise((resolve) => setTimeout(resolve, 1000)); + return ( + value.includes("error") && 'No "error" allowed in first name' + ); + }} + children={(field) => { + return ( + <> + {/* ... */} + + ); + }} +/> +``` + +### Built-in Debouncing + +While async calls are the way to go when validating against the database, running a network request on every keystroke is a good way to DDOS your database. + +Instead, we enable an easy method for debouncing your `async` calls by adding a single property: + +```tsx + { + // ... + }} + children={(field) => { + return ( + <> + {/* ... */} + + ); + }} +/> +``` + +This will debounce every async call with a 500ms delay. You can even override this property on a per-validation property: + +```tsx + { + // ... + }} + onBlurAsync={async (value) => { + // ... + }} + children={(field) => { + return ( + <> + {/* ... */} + + ); + }} +/> +``` + +> This will run `onChangeAsync` every 1500ms while `onBlurAsync` will run every 500ms. + + +## Adapter-Based Validation \ No newline at end of file diff --git a/docs/reference/formApi.md b/docs/reference/formApi.md index e6cbc6207..84b5bcd8a 100644 --- a/docs/reference/formApi.md +++ b/docs/reference/formApi.md @@ -13,14 +13,14 @@ Normally, you will not need to create a new `FormApi` instance directly. Instead const formApi: FormApi = new FormApi(formOptions: FormOptions) ``` -### `FormOptions` +### `FormOptions` An object representing the options for a form. - ```tsx defaultValues?: TData ``` - - Set initial values for you form. + - Set initial values for yonu form. - ```tsx defaultState?: Partial> ``` @@ -32,7 +32,7 @@ An object representing the options for a form. - Optional time in milliseconds if you want to introduce a delay before firing off an async action. - ```tsx - onMount?: (values: TData, formApi: FormApi) => ValidationError + onMount?: (values: TData, formApi: FormApi) => ValidationError ``` - Optional function that fires as soon as the component mounts. - ```tsx @@ -75,7 +75,7 @@ An object representing the options for a form. - The default time in milliseconds that if set to a number larger than 0, will debounce the async validation event by this length of time in milliseconds. - ```tsx - onSubmit?: (values: TData, formApi: FormApi) => any | Promise + onSubmit?: (values: TData, formApi: FormApi) => any | Promise ``` - A function to be called when the form is submitted, what should happen once the user submits a valid form returns `any` or a promise `Promise` @@ -85,7 +85,7 @@ An object representing the options for a form. - Specify an action for scenarios where the user tries to submit an invalid form. -### `FormApi` +### `FormApi` A class representing the Form API. It handles the logic and interactions with the form state. @@ -136,9 +136,9 @@ A class representing the Form API. It handles the logic and interactions with th - Validates all fields in the form. - ```tsx - handleSubmit(e: FormSubmitEvent) + handleSubmit() ``` - - Handles the form submission event, performs validation, and calls the appropriate onSubmit or onInvalidSubmit callbacks. + - Handles the form submission, performs validation, and calls the appropriate onSubmit or onInvalidSubmit callbacks. - ```tsx getFieldValue>(field: TField) ``` From 96aaa8f102b703abe8bd77baa8c138d292630b5e Mon Sep 17 00:00:00 2001 From: Corbin Crutchley Date: Wed, 18 Oct 2023 02:19:50 -0700 Subject: [PATCH 37/37] docs: add adapter validation docs --- docs/guides/validation.md | 71 ++++++++++++++++++++++++++++++++++++++- 1 file changed, 70 insertions(+), 1 deletion(-) diff --git a/docs/guides/validation.md b/docs/guides/validation.md index 345c4cd59..6abd8297b 100644 --- a/docs/guides/validation.md +++ b/docs/guides/validation.md @@ -208,4 +208,73 @@ This will debounce every async call with a 500ms delay. You can even override th > This will run `onChangeAsync` every 1500ms while `onBlurAsync` will run every 500ms. -## Adapter-Based Validation \ No newline at end of file +## Adapter-Based Validation + +While functions provide more flexibility and customization over your validation, they can be a bit verbose. To help solve this, there are libraries like [Yup](https://github.com/jquense/yup) and [Zod](https://zod.dev/) that provide schema-based validation to make shorthand and type-strict validation substantially easier. + +Luckily, we support both of these libraries through official adapters: + +```bash +$ npm install @tanstack/zod-form-adapter zod +# or +$ npm install @tanstack/yup-form-adapter yup +``` + +Once done, we can add the adapter to the `validator` property on the form or field: + +```tsx +import { zodValidator } from "@tanstack/zod-form-adapter"; +import { z } from "zod"; + +// ... + +const form = useForm({ + // Either add the validator here or on `Field` + validator: zodValidator, + // ... +}); + + { + return ( + <> + {/* ... */} + + ); + }} +/> +``` + +These adapters also support async operations using the proper property names: + +```tsx + { + await new Promise((resolve) => setTimeout(resolve, 1000)); + return !value.includes("error"); + }, + { + message: "No 'error' allowed in first name", + }, + )} + children={(field) => { + return ( + <> + {/* ... */} + + ); + }} +/> +``` +