typebox 1.1.27 → 1.1.28
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/type/action/awaited.d.mts +2 -2
- package/build/type/action/awaited.mjs +2 -3
- package/build/type/action/capitalize.d.mts +2 -2
- package/build/type/action/capitalize.mjs +2 -3
- package/build/type/action/conditional.d.mts +4 -2
- package/build/type/action/conditional.mjs +2 -2
- package/build/type/action/constructor-parameters.d.mts +2 -2
- package/build/type/action/constructor-parameters.mjs +2 -3
- package/build/type/action/evaluate.d.mts +2 -2
- package/build/type/action/evaluate.mjs +2 -3
- package/build/type/action/exclude.d.mts +2 -2
- package/build/type/action/exclude.mjs +2 -3
- package/build/type/action/extract.d.mts +2 -2
- package/build/type/action/extract.mjs +2 -3
- package/build/type/action/index.d.mts +1 -1
- package/build/type/action/index.mjs +1 -1
- package/build/type/action/indexed.d.mts +2 -2
- package/build/type/action/indexed.mjs +2 -3
- package/build/type/action/instance-type.d.mts +2 -2
- package/build/type/action/instance-type.mjs +2 -3
- package/build/type/action/interface.d.mts +2 -2
- package/build/type/action/interface.mjs +5 -3
- package/build/type/action/keyof.d.mts +2 -2
- package/build/type/action/keyof.mjs +2 -3
- package/build/type/action/lowercase.d.mts +2 -2
- package/build/type/action/lowercase.mjs +2 -3
- package/build/type/action/mapped.d.mts +4 -2
- package/build/type/action/mapped.mjs +2 -2
- package/build/type/action/non-nullable.d.mts +2 -2
- package/build/type/action/non-nullable.mjs +2 -3
- package/build/type/action/omit.d.mts +2 -2
- package/build/type/action/omit.mjs +2 -3
- package/build/type/action/options.d.mts +4 -5
- package/build/type/action/options.mjs +3 -4
- package/build/type/action/parameters.d.mts +2 -2
- package/build/type/action/parameters.mjs +2 -3
- package/build/type/action/partial.d.mts +3 -3
- package/build/type/action/partial.mjs +2 -3
- package/build/type/action/pick.d.mts +2 -2
- package/build/type/action/pick.mjs +2 -3
- package/build/type/action/readonly-object.d.mts +16 -0
- package/build/type/action/readonly-object.mjs +16 -0
- package/build/type/action/required.d.mts +2 -2
- package/build/type/action/required.mjs +2 -3
- package/build/type/action/return-type.d.mts +2 -2
- package/build/type/action/return-type.mjs +2 -3
- package/build/type/action/uncapitalize.d.mts +2 -2
- package/build/type/action/uncapitalize.mjs +2 -3
- package/build/type/action/uppercase.d.mts +2 -2
- package/build/type/action/uppercase.mjs +2 -3
- package/build/type/engine/awaited/instantiate.d.mts +4 -3
- package/build/type/engine/awaited/instantiate.mjs +9 -8
- package/build/type/engine/conditional/instantiate.d.mts +4 -2
- package/build/type/engine/conditional/instantiate.mjs +13 -9
- package/build/type/engine/constructor-parameters/instantiate.d.mts +6 -5
- package/build/type/engine/constructor-parameters/instantiate.mjs +13 -11
- package/build/type/engine/evaluate/instantiate.d.mts +3 -3
- package/build/type/engine/evaluate/instantiate.mjs +5 -10
- package/build/type/engine/exclude/instantiate.d.mts +4 -11
- package/build/type/engine/exclude/instantiate.mjs +7 -28
- package/build/type/engine/exclude/operation.d.mts +11 -0
- package/build/type/engine/exclude/operation.mjs +24 -0
- package/build/type/engine/extract/instantiate.d.mts +4 -11
- package/build/type/engine/extract/instantiate.mjs +7 -28
- package/build/type/engine/extract/operation.d.mts +11 -0
- package/build/type/engine/extract/operation.mjs +24 -0
- package/build/type/engine/index.d.mts +1 -1
- package/build/type/engine/index.mjs +1 -1
- package/build/type/engine/indexed/from-type.d.mts +11 -0
- package/build/type/engine/indexed/from-type.mjs +14 -0
- package/build/type/engine/indexed/instantiate.d.mts +5 -11
- package/build/type/engine/indexed/instantiate.mjs +8 -20
- package/build/type/engine/instance-type/instantiate.d.mts +4 -4
- package/build/type/engine/instance-type/instantiate.mjs +9 -8
- package/build/type/engine/instantiate.d.mts +4 -6
- package/build/type/engine/instantiate.mjs +9 -18
- package/build/type/engine/interface/instantiate.d.mts +6 -4
- package/build/type/engine/interface/instantiate.mjs +12 -8
- package/build/type/engine/intrinsics/instantiate.d.mts +12 -8
- package/build/type/engine/intrinsics/instantiate.mjs +28 -24
- package/build/type/engine/keyof/from-type.d.mts +15 -0
- package/build/type/engine/keyof/from-type.mjs +23 -0
- package/build/type/engine/keyof/instantiate.d.mts +4 -16
- package/build/type/engine/keyof/instantiate.mjs +8 -28
- package/build/type/engine/mapped/instantiate.d.mts +4 -19
- package/build/type/engine/mapped/instantiate.mjs +7 -42
- package/build/type/engine/mapped/mapped-operation.d.mts +22 -0
- package/build/type/engine/mapped/mapped-operation.mjs +42 -0
- package/build/type/engine/non-nullable/instantiate.d.mts +5 -6
- package/build/type/engine/non-nullable/instantiate.mjs +10 -10
- package/build/type/engine/omit/from-type.d.mts +12 -0
- package/build/type/engine/omit/from-type.mjs +18 -0
- package/build/type/engine/omit/instantiate.d.mts +4 -11
- package/build/type/engine/omit/instantiate.mjs +7 -22
- package/build/type/engine/options/instantiate.d.mts +4 -4
- package/build/type/engine/options/instantiate.mjs +8 -7
- package/build/type/engine/parameters/instantiate.d.mts +6 -5
- package/build/type/engine/parameters/instantiate.mjs +13 -11
- package/build/type/engine/partial/instantiate.d.mts +3 -3
- package/build/type/engine/partial/instantiate.mjs +7 -6
- package/build/type/engine/pick/from-type.d.mts +13 -0
- package/build/type/engine/pick/from-type.mjs +20 -0
- package/build/type/engine/pick/instantiate.d.mts +4 -12
- package/build/type/engine/pick/instantiate.mjs +7 -23
- package/build/type/engine/readonly-object/instantiate.d.mts +9 -0
- package/build/type/engine/readonly-object/instantiate.mjs +15 -0
- package/build/type/engine/record/instantiate.d.mts +3 -3
- package/build/type/engine/record/instantiate.mjs +8 -7
- package/build/type/engine/required/instantiate.d.mts +3 -3
- package/build/type/engine/required/instantiate.mjs +7 -6
- package/build/type/engine/return-type/instantiate.d.mts +5 -4
- package/build/type/engine/return-type/instantiate.mjs +12 -9
- package/build/type/engine/template-literal/encode.d.mts +4 -2
- package/build/type/engine/template-literal/encode.mjs +10 -3
- package/build/type/engine/template-literal/instantiate.d.mts +3 -3
- package/build/type/engine/template-literal/instantiate.mjs +7 -6
- package/build/type/script/mapping.d.mts +1 -1
- package/build/type/script/mapping.mjs +1 -1
- package/build/type/types/promise.d.mts +2 -1
- package/build/type/types/promise.mjs +2 -1
- package/build/type/types/record.d.mts +5 -5
- package/build/type/types/record.mjs +11 -6
- package/build/type/types/template-literal.d.mts +5 -3
- package/build/type/types/template-literal.mjs +10 -4
- package/build/typebox.d.mts +3 -3
- package/build/typebox.mjs +2 -2
- package/package.json +1 -1
- package/build/type/action/readonly-type.d.mts +0 -11
- package/build/type/action/readonly-type.mjs +0 -12
- package/build/type/engine/readonly-type/instantiate.d.mts +0 -9
- package/build/type/engine/readonly-type/instantiate.mjs +0 -14
- /package/build/type/engine/{readonly-type → readonly-object}/from-array.d.mts +0 -0
- /package/build/type/engine/{readonly-type → readonly-object}/from-array.mjs +0 -0
- /package/build/type/engine/{readonly-type → readonly-object}/from-cyclic.d.mts +0 -0
- /package/build/type/engine/{readonly-type → readonly-object}/from-cyclic.mjs +0 -0
- /package/build/type/engine/{readonly-type → readonly-object}/from-intersect.d.mts +0 -0
- /package/build/type/engine/{readonly-type → readonly-object}/from-intersect.mjs +0 -0
- /package/build/type/engine/{readonly-type → readonly-object}/from-object.d.mts +0 -0
- /package/build/type/engine/{readonly-type → readonly-object}/from-object.mjs +0 -0
- /package/build/type/engine/{readonly-type → readonly-object}/from-tuple.d.mts +0 -0
- /package/build/type/engine/{readonly-type → readonly-object}/from-tuple.mjs +0 -0
- /package/build/type/engine/{readonly-type → readonly-object}/from-type.d.mts +0 -0
- /package/build/type/engine/{readonly-type → readonly-object}/from-type.mjs +0 -0
- /package/build/type/engine/{readonly-type → readonly-object}/from-union.d.mts +0 -0
- /package/build/type/engine/{readonly-type → readonly-object}/from-union.mjs +0 -0
- /package/build/type/engine/{readonly-type → readonly-object}/index.d.mts +0 -0
- /package/build/type/engine/{readonly-type → readonly-object}/index.mjs +0 -0
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { type TSchema, type TSchemaOptions } from '../types/schema.mjs';
|
|
2
2
|
import { type TDeferred } from '../types/deferred.mjs';
|
|
3
|
-
import { type
|
|
3
|
+
import { type TAwaitedAction } from '../engine/awaited/instantiate.mjs';
|
|
4
4
|
/** Creates a deferred Awaited action. */
|
|
5
5
|
export type TAwaitedDeferred<Type extends TSchema> = (TDeferred<'Awaited', [Type]>);
|
|
6
6
|
/** Creates a deferred Awaited action. */
|
|
7
7
|
export declare function AwaitedDeferred<Type extends TSchema>(type: Type, options?: TSchemaOptions): TAwaitedDeferred<Type>;
|
|
8
8
|
/** Applies an Awaited action to a type. */
|
|
9
|
-
export type TAwaited<Type extends TSchema> = (
|
|
9
|
+
export type TAwaited<Type extends TSchema> = (TAwaitedAction<Type>);
|
|
10
10
|
/** Applies an Awaited action to a type. */
|
|
11
11
|
export declare function Awaited<Type extends TSchema>(type: Type, options?: TSchemaOptions): TAwaited<Type>;
|
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
// deno-lint-ignore-file ban-types
|
|
2
1
|
// deno-fmt-ignore-file
|
|
3
2
|
import { Deferred } from '../types/deferred.mjs';
|
|
4
|
-
import {
|
|
3
|
+
import { AwaitedAction } from '../engine/awaited/instantiate.mjs';
|
|
5
4
|
/** Creates a deferred Awaited action. */
|
|
6
5
|
export function AwaitedDeferred(type, options = {}) {
|
|
7
6
|
return Deferred('Awaited', [type], options);
|
|
8
7
|
}
|
|
9
8
|
/** Applies an Awaited action to a type. */
|
|
10
9
|
export function Awaited(type, options = {}) {
|
|
11
|
-
return
|
|
10
|
+
return AwaitedAction(type, options);
|
|
12
11
|
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { type TSchema, type TSchemaOptions } from '../types/schema.mjs';
|
|
2
2
|
import { type TDeferred } from '../types/deferred.mjs';
|
|
3
|
-
import { type
|
|
3
|
+
import { type TCapitalizeAction } from '../engine/intrinsics/instantiate.mjs';
|
|
4
4
|
/** Creates a deferred Capitalize action. */
|
|
5
5
|
export type TCapitalizeDeferred<Type extends TSchema> = (TDeferred<'Capitalize', [Type]>);
|
|
6
6
|
/** Creates a deferred Capitalize action. */
|
|
7
7
|
export declare function CapitalizeDeferred<Type extends TSchema>(type: Type, options?: TSchemaOptions): TCapitalizeDeferred<Type>;
|
|
8
8
|
/** Applies a Capitalize action to the given type. */
|
|
9
|
-
export type TCapitalize<Type extends TSchema> = (
|
|
9
|
+
export type TCapitalize<Type extends TSchema> = (TCapitalizeAction<Type>);
|
|
10
10
|
/** Applies a Capitalize action to the given type. */
|
|
11
11
|
export declare function Capitalize<Type extends TSchema>(type: Type, options?: TSchemaOptions): TCapitalize<Type>;
|
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
// deno-lint-ignore-file ban-types
|
|
2
1
|
// deno-fmt-ignore-file
|
|
3
2
|
import { Deferred } from '../types/deferred.mjs';
|
|
4
|
-
import {
|
|
3
|
+
import { CapitalizeAction } from '../engine/intrinsics/instantiate.mjs';
|
|
5
4
|
/** Creates a deferred Capitalize action. */
|
|
6
5
|
export function CapitalizeDeferred(type, options = {}) {
|
|
7
6
|
return Deferred('Capitalize', [type], options);
|
|
8
7
|
}
|
|
9
8
|
/** Applies a Capitalize action to the given type. */
|
|
10
9
|
export function Capitalize(type, options = {}) {
|
|
11
|
-
return
|
|
10
|
+
return CapitalizeAction(type, options);
|
|
12
11
|
}
|
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
import { type TSchema, type TSchemaOptions } from '../types/schema.mjs';
|
|
2
2
|
import { type TDeferred } from '../types/deferred.mjs';
|
|
3
|
-
import { type
|
|
3
|
+
import { type TConditionalAction } from '../engine/conditional/instantiate.mjs';
|
|
4
4
|
/** Creates a deferred Conditional action. */
|
|
5
5
|
export type TConditionalDeferred<Left extends TSchema, Right extends TSchema, True extends TSchema, False extends TSchema> = (TDeferred<'Conditional', [Left, Right, True, False]>);
|
|
6
6
|
/** Creates a deferred Conditional action. */
|
|
7
7
|
export declare function ConditionalDeferred<Left extends TSchema, Right extends TSchema, True extends TSchema, False extends TSchema>(left: Left, right: Right, true_: True, false_: False, options?: TSchemaOptions): TConditionalDeferred<Left, Right, True, False>;
|
|
8
8
|
/** Applies a Conditional action to the given types. */
|
|
9
|
-
export type TConditional<Left extends TSchema, Right extends TSchema, True extends TSchema, False extends TSchema> = (
|
|
9
|
+
export type TConditional<Left extends TSchema, Right extends TSchema, True extends TSchema, False extends TSchema> = (TConditionalAction<{}, {
|
|
10
|
+
callstack: [];
|
|
11
|
+
}, Left, Right, True, False>);
|
|
10
12
|
/** Applies a Conditional action to the given types. */
|
|
11
13
|
export declare function Conditional<Left extends TSchema, Right extends TSchema, True extends TSchema, False extends TSchema>(left: Left, right: Right, true_: True, false_: False, options?: TSchemaOptions): TConditional<Left, Right, True, False>;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
// deno-lint-ignore-file ban-types
|
|
2
2
|
// deno-fmt-ignore-file
|
|
3
3
|
import { Deferred } from '../types/deferred.mjs';
|
|
4
|
-
import {
|
|
4
|
+
import { ConditionalAction } from '../engine/conditional/instantiate.mjs';
|
|
5
5
|
/** Creates a deferred Conditional action. */
|
|
6
6
|
export function ConditionalDeferred(left, right, true_, false_, options = {}) {
|
|
7
7
|
return Deferred('Conditional', [left, right, true_, false_], options);
|
|
8
8
|
}
|
|
9
9
|
/** Applies a Conditional action to the given types. */
|
|
10
10
|
export function Conditional(left, right, true_, false_, options = {}) {
|
|
11
|
-
return
|
|
11
|
+
return ConditionalAction({}, { callstack: [] }, left, right, true_, false_, options);
|
|
12
12
|
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { type TSchema, type TSchemaOptions } from '../types/schema.mjs';
|
|
2
2
|
import { type TDeferred } from '../types/deferred.mjs';
|
|
3
|
-
import { type
|
|
3
|
+
import { type TConstructorParametersAction } from '../engine/constructor-parameters/instantiate.mjs';
|
|
4
4
|
/** Creates a deferred ConstructorParameters action. */
|
|
5
5
|
export type TConstructorParametersDeferred<Type extends TSchema> = (TDeferred<'ConstructorParameters', [Type]>);
|
|
6
6
|
/** Creates a deferred ConstructorParameters action. */
|
|
7
7
|
export declare function ConstructorParametersDeferred<Type extends TSchema>(type: Type, options?: TSchemaOptions): TConstructorParametersDeferred<Type>;
|
|
8
8
|
/** Applies a ConstructorParameters action to a type. */
|
|
9
|
-
export type TConstructorParameters<Type extends TSchema> = (
|
|
9
|
+
export type TConstructorParameters<Type extends TSchema> = (TConstructorParametersAction<Type>);
|
|
10
10
|
/** Applies a ConstructorParameters action to a type. */
|
|
11
11
|
export declare function ConstructorParameters<Type extends TSchema>(type: Type, options?: TSchemaOptions): TConstructorParameters<Type>;
|
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
// deno-lint-ignore-file ban-types
|
|
2
1
|
// deno-fmt-ignore-file
|
|
3
2
|
import { Deferred } from '../types/deferred.mjs';
|
|
4
|
-
import {
|
|
3
|
+
import { ConstructorParametersAction } from '../engine/constructor-parameters/instantiate.mjs';
|
|
5
4
|
/** Creates a deferred ConstructorParameters action. */
|
|
6
5
|
export function ConstructorParametersDeferred(type, options = {}) {
|
|
7
6
|
return Deferred('ConstructorParameters', [type], options);
|
|
8
7
|
}
|
|
9
8
|
/** Applies a ConstructorParameters action to a type. */
|
|
10
9
|
export function ConstructorParameters(type, options = {}) {
|
|
11
|
-
return
|
|
10
|
+
return ConstructorParametersAction(type, options);
|
|
12
11
|
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { type TSchema, type TSchemaOptions } from '../types/schema.mjs';
|
|
2
2
|
import { type TDeferred } from '../types/deferred.mjs';
|
|
3
|
-
import { type
|
|
3
|
+
import { type TEvaluateAction } from '../engine/evaluate/instantiate.mjs';
|
|
4
4
|
/** Creates a deferred Evaluate action. */
|
|
5
5
|
export type TEvaluateDeferred<Type extends TSchema> = (TDeferred<'Evaluate', [Type]>);
|
|
6
6
|
/** Creates a deferred Evaluate action. */
|
|
7
7
|
export declare function EvaluateDeferred<Type extends TSchema>(type: Type, options?: TSchemaOptions): TEvaluateDeferred<Type>;
|
|
8
8
|
/** Applies an Evaluate action to a type. */
|
|
9
|
-
export type TEvaluate<Type extends TSchema> = (
|
|
9
|
+
export type TEvaluate<Type extends TSchema> = (TEvaluateAction<Type>);
|
|
10
10
|
/** Applies an Evaluate action to a type. */
|
|
11
11
|
export declare function Evaluate<Type extends TSchema>(type: Type, options?: TSchemaOptions): TEvaluate<Type>;
|
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
// deno-lint-ignore-file ban-types
|
|
2
1
|
// deno-fmt-ignore-file
|
|
3
2
|
import { Deferred } from '../types/deferred.mjs';
|
|
4
|
-
import {
|
|
3
|
+
import { EvaluateAction } from '../engine/evaluate/instantiate.mjs';
|
|
5
4
|
/** Creates a deferred Evaluate action. */
|
|
6
5
|
export function EvaluateDeferred(type, options = {}) {
|
|
7
6
|
return Deferred('Evaluate', [type], options);
|
|
8
7
|
}
|
|
9
8
|
/** Applies an Evaluate action to a type. */
|
|
10
9
|
export function Evaluate(type, options = {}) {
|
|
11
|
-
return
|
|
10
|
+
return EvaluateAction(type, options);
|
|
12
11
|
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { type TSchema, type TSchemaOptions } from '../types/schema.mjs';
|
|
2
2
|
import { type TDeferred } from '../types/deferred.mjs';
|
|
3
|
-
import { type
|
|
3
|
+
import { type TExcludeAction } from '../engine/exclude/instantiate.mjs';
|
|
4
4
|
/** Creates a deferred Exclude action. */
|
|
5
5
|
export type TExcludeDeferred<Left extends TSchema, Right extends TSchema> = (TDeferred<'Exclude', [Left, Right]>);
|
|
6
6
|
/** Creates a deferred Exclude action. */
|
|
7
7
|
export declare function ExcludeDeferred<Left extends TSchema, Right extends TSchema>(left: Left, right: Right, options?: TSchemaOptions): TExcludeDeferred<Left, Right>;
|
|
8
8
|
/** Applies a Exclude action using the given types */
|
|
9
|
-
export type TExclude<Left extends TSchema, Right extends TSchema> = (
|
|
9
|
+
export type TExclude<Left extends TSchema, Right extends TSchema> = (TExcludeAction<Left, Right>);
|
|
10
10
|
/** Applies a Exclude action using the given types */
|
|
11
11
|
export declare function Exclude<Left extends TSchema, Right extends TSchema>(left: Left, right: Right, options?: TSchemaOptions): TExclude<Left, Right>;
|
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
// deno-lint-ignore-file ban-types
|
|
2
1
|
// deno-fmt-ignore-file
|
|
3
2
|
import { Deferred } from '../types/deferred.mjs';
|
|
4
|
-
import {
|
|
3
|
+
import { ExcludeAction } from '../engine/exclude/instantiate.mjs';
|
|
5
4
|
/** Creates a deferred Exclude action. */
|
|
6
5
|
export function ExcludeDeferred(left, right, options = {}) {
|
|
7
6
|
return Deferred('Exclude', [left, right], options);
|
|
8
7
|
}
|
|
9
8
|
/** Applies a Exclude action using the given types */
|
|
10
9
|
export function Exclude(left, right, options = {}) {
|
|
11
|
-
return
|
|
10
|
+
return ExcludeAction(left, right, options);
|
|
12
11
|
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { type TSchema, type TSchemaOptions } from '../types/schema.mjs';
|
|
2
2
|
import { type TDeferred } from '../types/deferred.mjs';
|
|
3
|
-
import { type
|
|
3
|
+
import { type TExtractAction } from '../engine/extract/instantiate.mjs';
|
|
4
4
|
/** Creates a deferred Extract action. */
|
|
5
5
|
export type TExtractDeferred<Left extends TSchema, Right extends TSchema> = (TDeferred<'Extract', [Left, Right]>);
|
|
6
6
|
/** Creates a deferred Extract action. */
|
|
7
7
|
export declare function ExtractDeferred<Left extends TSchema, Right extends TSchema>(left: Left, right: Right, options?: TSchemaOptions): TExtractDeferred<Left, Right>;
|
|
8
8
|
/** Applies an Extract action using the given types. */
|
|
9
|
-
export type TExtract<Left extends TSchema, Right extends TSchema> = (
|
|
9
|
+
export type TExtract<Left extends TSchema, Right extends TSchema> = (TExtractAction<Left, Right>);
|
|
10
10
|
/** Applies an Extract action using the given types. */
|
|
11
11
|
export declare function Extract<Left extends TSchema, Right extends TSchema>(left: Left, right: Right, options?: TSchemaOptions): TExtract<Left, Right>;
|
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
// deno-lint-ignore-file ban-types
|
|
2
1
|
// deno-fmt-ignore-file
|
|
3
2
|
import { Deferred } from '../types/deferred.mjs';
|
|
4
|
-
import {
|
|
3
|
+
import { ExtractAction } from '../engine/extract/instantiate.mjs';
|
|
5
4
|
/** Creates a deferred Extract action. */
|
|
6
5
|
export function ExtractDeferred(left, right, options = {}) {
|
|
7
6
|
return Deferred('Extract', [left, right], options);
|
|
8
7
|
}
|
|
9
8
|
/** Applies an Extract action using the given types. */
|
|
10
9
|
export function Extract(left, right, options = {}) {
|
|
11
|
-
return
|
|
10
|
+
return ExtractAction(left, right, options);
|
|
12
11
|
}
|
|
@@ -20,7 +20,7 @@ export * from './options.mjs';
|
|
|
20
20
|
export * from './parameters.mjs';
|
|
21
21
|
export * from './partial.mjs';
|
|
22
22
|
export * from './pick.mjs';
|
|
23
|
-
export * from './readonly-
|
|
23
|
+
export * from './readonly-object.mjs';
|
|
24
24
|
export * from './required.mjs';
|
|
25
25
|
export * from './return-type.mjs';
|
|
26
26
|
export * from './uncapitalize.mjs';
|
|
@@ -20,7 +20,7 @@ export * from './options.mjs';
|
|
|
20
20
|
export * from './parameters.mjs';
|
|
21
21
|
export * from './partial.mjs';
|
|
22
22
|
export * from './pick.mjs';
|
|
23
|
-
export * from './readonly-
|
|
23
|
+
export * from './readonly-object.mjs';
|
|
24
24
|
export * from './required.mjs';
|
|
25
25
|
export * from './return-type.mjs';
|
|
26
26
|
export * from './uncapitalize.mjs';
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { type TSchema, type TSchemaOptions } from '../types/schema.mjs';
|
|
2
2
|
import { type TDeferred } from '../types/deferred.mjs';
|
|
3
3
|
import { type TKeysToIndexer } from '../engine/helpers/keys-to-indexer.mjs';
|
|
4
|
-
import { type
|
|
4
|
+
import { type TIndexAction } from '../engine/indexed/instantiate.mjs';
|
|
5
5
|
/** Creates a deferred Index action. */
|
|
6
6
|
export type TIndexDeferred<Type extends TSchema, Indexer extends TSchema> = (TDeferred<'Index', [Type, Indexer]>);
|
|
7
7
|
/** Creates a deferred Index action. */
|
|
8
8
|
export declare function IndexDeferred<Type extends TSchema, Indexer extends TSchema>(type: Type, indexer: Indexer, options?: TSchemaOptions): TIndexDeferred<Type, Indexer>;
|
|
9
9
|
/** Applies a Index action using the given types. */
|
|
10
|
-
export type TIndex<Type extends TSchema, Indexer extends TSchema> = (
|
|
10
|
+
export type TIndex<Type extends TSchema, Indexer extends TSchema> = (TIndexAction<Type, Indexer>);
|
|
11
11
|
/** Applies a Index action using the given types. */
|
|
12
12
|
export declare function Index<Type extends TSchema, Indexer extends PropertyKey[]>(type: Type, indexer: readonly [...Indexer], options?: TSchemaOptions): TIndex<Type, TKeysToIndexer<Indexer>>;
|
|
13
13
|
/** Applies a Index action using the given types. */
|
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
// deno-lint-ignore-file ban-types
|
|
2
1
|
// deno-fmt-ignore-file
|
|
3
2
|
import { Guard } from '../../guard/index.mjs';
|
|
4
3
|
import { Deferred } from '../types/deferred.mjs';
|
|
5
4
|
import { KeysToIndexer } from '../engine/helpers/keys-to-indexer.mjs';
|
|
6
|
-
import {
|
|
5
|
+
import { IndexAction } from '../engine/indexed/instantiate.mjs';
|
|
7
6
|
/** Creates a deferred Index action. */
|
|
8
7
|
export function IndexDeferred(type, indexer, options = {}) {
|
|
9
8
|
return Deferred('Index', [type, indexer], options);
|
|
@@ -11,5 +10,5 @@ export function IndexDeferred(type, indexer, options = {}) {
|
|
|
11
10
|
/** Applies a Index action using the given types. */
|
|
12
11
|
export function Index(type, indexer_or_keys, options = {}) {
|
|
13
12
|
const indexer = Guard.IsArray(indexer_or_keys) ? KeysToIndexer(indexer_or_keys) : indexer_or_keys;
|
|
14
|
-
return
|
|
13
|
+
return IndexAction(type, indexer, options);
|
|
15
14
|
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { type TSchema, type TSchemaOptions } from '../types/schema.mjs';
|
|
2
2
|
import { type TDeferred } from '../types/deferred.mjs';
|
|
3
|
-
import { type
|
|
3
|
+
import { type TInstanceTypeAction } from '../engine/instance-type/instantiate.mjs';
|
|
4
4
|
/** Creates a deferred InstanceType action. */
|
|
5
5
|
export type TInstanceTypeDeferred<Type extends TSchema> = (TDeferred<'InstanceType', [Type]>);
|
|
6
6
|
/** Creates a deferred InstanceType action. */
|
|
7
7
|
export declare function InstanceTypeDeferred<Type extends TSchema>(type: Type, options?: TSchemaOptions): TInstanceTypeDeferred<Type>;
|
|
8
8
|
/** Applies a InstanceType action to the given type. */
|
|
9
|
-
export type TInstanceType<Type extends TSchema> = (
|
|
9
|
+
export type TInstanceType<Type extends TSchema> = (TInstanceTypeAction<Type>);
|
|
10
10
|
/** Applies a InstanceType action to the given type. */
|
|
11
11
|
export declare function InstanceType<Type extends TSchema>(type: Type, options?: TSchemaOptions): TInstanceType<Type>;
|
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
// deno-lint-ignore-file ban-types
|
|
2
1
|
// deno-fmt-ignore-file
|
|
3
2
|
import { Deferred } from '../types/deferred.mjs';
|
|
4
|
-
import {
|
|
3
|
+
import { InstanceTypeAction } from '../engine/instance-type/instantiate.mjs';
|
|
5
4
|
/** Creates a deferred InstanceType action. */
|
|
6
5
|
export function InstanceTypeDeferred(type, options = {}) {
|
|
7
6
|
return Deferred('InstanceType', [type], options);
|
|
8
7
|
}
|
|
9
8
|
/** Applies a InstanceType action to the given type. */
|
|
10
9
|
export function InstanceType(type, options = {}) {
|
|
11
|
-
return
|
|
10
|
+
return InstanceTypeAction(type, options);
|
|
12
11
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type TSchema, type TSchemaOptions } from '../types/schema.mjs';
|
|
2
2
|
import { type TProperties } from '../types/properties.mjs';
|
|
3
3
|
import { type TDeferred } from '../types/deferred.mjs';
|
|
4
|
-
import { type
|
|
4
|
+
import { type TInterfaceAction } from '../engine/interface/instantiate.mjs';
|
|
5
5
|
/** Creates a deferred Interface action. */
|
|
6
6
|
export type TInterfaceDeferred<Heritage extends TSchema[] = TSchema[], Properties extends TProperties = TProperties> = (TDeferred<'Interface', [Heritage, Properties]>);
|
|
7
7
|
/** Creates a deferred Interface action. */
|
|
@@ -9,6 +9,6 @@ export declare function InterfaceDeferred<Heritage extends TSchema[], Properties
|
|
|
9
9
|
/** Returns true if this value is a deferred Interface action. */
|
|
10
10
|
export declare function IsInterfaceDeferred(value: unknown): value is TInterfaceDeferred;
|
|
11
11
|
/** Creates an Interface using the given heritage and properties. */
|
|
12
|
-
export type TInterface<Heritage extends TSchema[], Properties extends TProperties> = (
|
|
12
|
+
export type TInterface<Heritage extends TSchema[], Properties extends TProperties> = (TInterfaceAction<Heritage, Properties>);
|
|
13
13
|
/** Creates an Interface using the given heritage and properties. */
|
|
14
14
|
export declare function Interface<Heritage extends TSchema[], Properties extends TProperties>(heritage: [...Heritage], properties: Properties, options?: TSchemaOptions): TInterface<Heritage, Properties>;
|
|
@@ -1,13 +1,15 @@
|
|
|
1
|
-
// deno-lint-ignore-file ban-types
|
|
2
1
|
// deno-fmt-ignore-file
|
|
3
2
|
import { Guard } from '../../guard/index.mjs';
|
|
4
3
|
import { IsSchema } from '../types/schema.mjs';
|
|
5
4
|
import { Deferred } from '../types/deferred.mjs';
|
|
6
|
-
import {
|
|
5
|
+
import { InterfaceAction } from '../engine/interface/instantiate.mjs';
|
|
7
6
|
/** Creates a deferred Interface action. */
|
|
8
7
|
export function InterfaceDeferred(heritage, properties, options = {}) {
|
|
9
8
|
return Deferred('Interface', [heritage, properties], options);
|
|
10
9
|
}
|
|
10
|
+
// ------------------------------------------------------------------
|
|
11
|
+
// Guard
|
|
12
|
+
// ------------------------------------------------------------------
|
|
11
13
|
/** Returns true if this value is a deferred Interface action. */
|
|
12
14
|
export function IsInterfaceDeferred(value) {
|
|
13
15
|
return IsSchema(value)
|
|
@@ -16,5 +18,5 @@ export function IsInterfaceDeferred(value) {
|
|
|
16
18
|
}
|
|
17
19
|
/** Creates an Interface using the given heritage and properties. */
|
|
18
20
|
export function Interface(heritage, properties, options = {}) {
|
|
19
|
-
return
|
|
21
|
+
return InterfaceAction(heritage, properties, options);
|
|
20
22
|
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { type TSchema, type TSchemaOptions } from '../types/schema.mjs';
|
|
2
2
|
import { type TDeferred } from '../types/deferred.mjs';
|
|
3
|
-
import { type
|
|
3
|
+
import { type TKeyOfAction } from '../engine/keyof/instantiate.mjs';
|
|
4
4
|
/** Creates a deferred KeyOf action. */
|
|
5
5
|
export type TKeyOfDeferred<Type extends TSchema> = (TDeferred<'KeyOf', [Type]>);
|
|
6
6
|
/** Creates a deferred KeyOf action. */
|
|
7
7
|
export declare function KeyOfDeferred<Type extends TSchema>(type: Type, options?: TSchemaOptions): TKeyOfDeferred<Type>;
|
|
8
8
|
/** Applies a KeyOf action to the given type. */
|
|
9
|
-
export type TKeyOf<Type extends TSchema> = (
|
|
9
|
+
export type TKeyOf<Type extends TSchema> = (TKeyOfAction<Type>);
|
|
10
10
|
/** Applies a KeyOf action to the given type. */
|
|
11
11
|
export declare function KeyOf<Type extends TSchema>(type: Type, options?: TSchemaOptions): TKeyOf<Type>;
|
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
// deno-lint-ignore-file ban-types
|
|
2
1
|
// deno-fmt-ignore-file
|
|
3
2
|
import { Deferred } from '../types/deferred.mjs';
|
|
4
|
-
import {
|
|
3
|
+
import { KeyOfAction } from '../engine/keyof/instantiate.mjs';
|
|
5
4
|
/** Creates a deferred KeyOf action. */
|
|
6
5
|
export function KeyOfDeferred(type, options = {}) {
|
|
7
6
|
return Deferred('KeyOf', [type], options);
|
|
8
7
|
}
|
|
9
8
|
/** Applies a KeyOf action to the given type. */
|
|
10
9
|
export function KeyOf(type, options = {}) {
|
|
11
|
-
return
|
|
10
|
+
return KeyOfAction(type, options);
|
|
12
11
|
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { type TSchema, type TSchemaOptions } from '../types/schema.mjs';
|
|
2
2
|
import { type TDeferred } from '../types/deferred.mjs';
|
|
3
|
-
import { type
|
|
3
|
+
import { type TLowercaseAction } from '../engine/intrinsics/instantiate.mjs';
|
|
4
4
|
/** Creates a deferred Lowercase action. */
|
|
5
5
|
export type TLowercaseDeferred<Type extends TSchema> = (TDeferred<'Lowercase', [Type]>);
|
|
6
6
|
/** Creates a deferred Lowercase action. */
|
|
7
7
|
export declare function LowercaseDeferred<Type extends TSchema>(type: Type, options?: TSchemaOptions): TLowercaseDeferred<Type>;
|
|
8
8
|
/** Applies a Lowercase action to the given type. */
|
|
9
|
-
export type TLowercase<Type extends TSchema> = (
|
|
9
|
+
export type TLowercase<Type extends TSchema> = (TLowercaseAction<Type>);
|
|
10
10
|
/** Applies a Lowercase action to the given type. */
|
|
11
11
|
export declare function Lowercase<Type extends TSchema>(type: Type, options?: TSchemaOptions): TLowercase<Type>;
|
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
// deno-lint-ignore-file ban-types
|
|
2
1
|
// deno-fmt-ignore-file
|
|
3
2
|
import { Deferred } from '../types/deferred.mjs';
|
|
4
|
-
import {
|
|
3
|
+
import { LowercaseAction } from '../engine/intrinsics/instantiate.mjs';
|
|
5
4
|
/** Creates a deferred Lowercase action. */
|
|
6
5
|
export function LowercaseDeferred(type, options = {}) {
|
|
7
6
|
return Deferred('Lowercase', [type], options);
|
|
8
7
|
}
|
|
9
8
|
/** Applies a Lowercase action to the given type. */
|
|
10
9
|
export function Lowercase(type, options = {}) {
|
|
11
|
-
return
|
|
10
|
+
return LowercaseAction(type, options);
|
|
12
11
|
}
|
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
import { type TSchema, type TSchemaOptions } from '../types/schema.mjs';
|
|
2
2
|
import { type TIdentifier } from '../types/identifier.mjs';
|
|
3
3
|
import { type TDeferred } from '../types/deferred.mjs';
|
|
4
|
-
import { type
|
|
4
|
+
import { type TMappedAction } from '../engine/mapped/instantiate.mjs';
|
|
5
5
|
/** Creates a deferred Mapped action. */
|
|
6
6
|
export type TMappedDeferred<Identifier extends TIdentifier, Type extends TSchema, As extends TSchema, Property extends TSchema> = (TDeferred<'Mapped', [Identifier, Type, As, Property]>);
|
|
7
7
|
/** Creates a deferred Mapped action. */
|
|
8
8
|
export declare function MappedDeferred<Identifier extends TIdentifier, Type extends TSchema, As extends TSchema, Property extends TSchema>(identifier: Identifier, type: Type, as: As, property: Property, options?: TSchemaOptions): TMappedDeferred<Identifier, Type, As, Property>;
|
|
9
9
|
/** Applies a Mapped action using the given types. */
|
|
10
|
-
export type TMapped<Identifier extends TIdentifier, Type extends TSchema, As extends TSchema, Property extends TSchema> = (
|
|
10
|
+
export type TMapped<Identifier extends TIdentifier, Type extends TSchema, As extends TSchema, Property extends TSchema> = (TMappedAction<{}, {
|
|
11
|
+
callstack: [];
|
|
12
|
+
}, Identifier, Type, As, Property>);
|
|
11
13
|
/** Applies a Mapped action using the given types. */
|
|
12
14
|
export declare function Mapped<Identifier extends TIdentifier, Type extends TSchema, As extends TSchema, Property extends TSchema>(identifier: Identifier, type: Type, as: As, property: Property, options?: TSchemaOptions): TMapped<Identifier, Type, As, Property>;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
// deno-lint-ignore-file ban-types
|
|
2
2
|
// deno-fmt-ignore-file
|
|
3
3
|
import { Deferred } from '../types/deferred.mjs';
|
|
4
|
-
import {
|
|
4
|
+
import { MappedAction } from '../engine/mapped/instantiate.mjs';
|
|
5
5
|
/** Creates a deferred Mapped action. */
|
|
6
6
|
export function MappedDeferred(identifier, type, as, property, options = {}) {
|
|
7
7
|
return Deferred('Mapped', [identifier, type, as, property], options);
|
|
8
8
|
}
|
|
9
9
|
/** Applies a Mapped action using the given types. */
|
|
10
10
|
export function Mapped(identifier, type, as, property, options = {}) {
|
|
11
|
-
return
|
|
11
|
+
return MappedAction({}, { callstack: [] }, identifier, type, as, property, options);
|
|
12
12
|
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { type TSchema, type TSchemaOptions } from '../types/schema.mjs';
|
|
2
2
|
import { type TDeferred } from '../types/deferred.mjs';
|
|
3
|
-
import { type
|
|
3
|
+
import { type TNonNullableAction } from '../engine/non-nullable/instantiate.mjs';
|
|
4
4
|
/** Creates a deferred NonNullable action. */
|
|
5
5
|
export type TNonNullableDeferred<Type extends TSchema> = (TDeferred<'NonNullable', [Type]>);
|
|
6
6
|
/** Creates a deferred NonNullable action. */
|
|
7
7
|
export declare function NonNullableDeferred<Type extends TSchema>(type: Type, options?: TSchemaOptions): TNonNullableDeferred<Type>;
|
|
8
8
|
/** Applies a NonNullable action to the given type. */
|
|
9
|
-
export type TNonNullable<Type extends TSchema> = (
|
|
9
|
+
export type TNonNullable<Type extends TSchema> = (TNonNullableAction<Type>);
|
|
10
10
|
/** Applies a NonNullable action to the given type. */
|
|
11
11
|
export declare function NonNullable<Type extends TSchema>(type: Type, options?: TSchemaOptions): TNonNullable<Type>;
|
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
// deno-lint-ignore-file ban-types
|
|
2
1
|
// deno-fmt-ignore-file
|
|
3
2
|
import { Deferred } from '../types/deferred.mjs';
|
|
4
|
-
import {
|
|
3
|
+
import { NonNullableAction } from '../engine/non-nullable/instantiate.mjs';
|
|
5
4
|
/** Creates a deferred NonNullable action. */
|
|
6
5
|
export function NonNullableDeferred(type, options = {}) {
|
|
7
6
|
return Deferred('NonNullable', [type], options);
|
|
8
7
|
}
|
|
9
8
|
/** Applies a NonNullable action to the given type. */
|
|
10
9
|
export function NonNullable(type, options = {}) {
|
|
11
|
-
return
|
|
10
|
+
return NonNullableAction(type, options);
|
|
12
11
|
}
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { type TSchema, type TSchemaOptions } from '../types/schema.mjs';
|
|
2
2
|
import { type TDeferred } from '../types/deferred.mjs';
|
|
3
3
|
import { type TKeysToIndexer } from '../engine/helpers/keys-to-indexer.mjs';
|
|
4
|
-
import { type
|
|
4
|
+
import { type TOmitAction } from '../engine/omit/instantiate.mjs';
|
|
5
5
|
/** Creates a deferred Omit action. */
|
|
6
6
|
export type TOmitDeferred<Type extends TSchema, Indexer extends TSchema> = (TDeferred<'Omit', [Type, Indexer]>);
|
|
7
7
|
/** Creates a deferred Omit action. */
|
|
8
8
|
export declare function OmitDeferred<Type extends TSchema, Indexer extends TSchema>(type: Type, indexer: Indexer, options?: TSchemaOptions): TOmitDeferred<Type, Indexer>;
|
|
9
9
|
/** Applies a Omit action using the given types. */
|
|
10
|
-
export type TOmit<Type extends TSchema, Indexer extends TSchema> = (
|
|
10
|
+
export type TOmit<Type extends TSchema, Indexer extends TSchema> = (TOmitAction<Type, Indexer>);
|
|
11
11
|
/** Applies a Omit action using the given types. */
|
|
12
12
|
export declare function Omit<Type extends TSchema, Indexer extends PropertyKey[]>(type: Type, indexer: readonly [...Indexer], options?: TSchemaOptions): TOmit<Type, TKeysToIndexer<Indexer>>;
|
|
13
13
|
/** Applies a Omit action using the given types. */
|
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
// deno-lint-ignore-file ban-types
|
|
2
1
|
// deno-fmt-ignore-file
|
|
3
2
|
import { Guard } from '../../guard/index.mjs';
|
|
4
3
|
import { Deferred } from '../types/deferred.mjs';
|
|
5
4
|
import { KeysToIndexer } from '../engine/helpers/keys-to-indexer.mjs';
|
|
6
|
-
import {
|
|
5
|
+
import { OmitAction } from '../engine/omit/instantiate.mjs';
|
|
7
6
|
/** Creates a deferred Omit action. */
|
|
8
7
|
export function OmitDeferred(type, indexer, options = {}) {
|
|
9
8
|
return Deferred('Omit', [type, indexer], options);
|
|
@@ -11,5 +10,5 @@ export function OmitDeferred(type, indexer, options = {}) {
|
|
|
11
10
|
/** Applies a Omit action using the given types. */
|
|
12
11
|
export function Omit(type, indexer_or_keys, options = {}) {
|
|
13
12
|
const indexer = Guard.IsArray(indexer_or_keys) ? KeysToIndexer(indexer_or_keys) : indexer_or_keys;
|
|
14
|
-
return
|
|
13
|
+
return OmitAction(type, indexer, options);
|
|
15
14
|
}
|
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
import { type TSchema } from '../types/schema.mjs';
|
|
2
2
|
import { type TDeferred } from '../types/deferred.mjs';
|
|
3
|
-
import { type
|
|
3
|
+
import { type TOptionsAction } from '../engine/options/instantiate.mjs';
|
|
4
4
|
/** Creates a deferred Options action. */
|
|
5
5
|
export type TOptionsDeferred<Type extends TSchema, Options extends TSchema> = (TDeferred<'Options', [Type, Options]>);
|
|
6
6
|
/** Creates a deferred Options action. */
|
|
7
7
|
export declare function OptionsDeferred<Type extends TSchema, Options extends TSchema>(type: Type, options: Options): TOptionsDeferred<Type, Options>;
|
|
8
|
-
|
|
9
|
-
/** Applies an Options action to the given type. */
|
|
8
|
+
/** Applies an immediate Options action to the given type. */
|
|
10
9
|
export type TOptions<Type extends TSchema, Options extends TSchema> = (Type & Options);
|
|
11
|
-
/** Applies an Options action to the given type. */
|
|
12
|
-
export declare function Options<Type extends TSchema, Options extends TSchema>(type: Type, options: Options):
|
|
10
|
+
/** Applies an immediate Options action to the given type. */
|
|
11
|
+
export declare function Options<Type extends TSchema, const Options extends TSchema>(type: Type, options: Options): TOptionsAction<Type, Options>;
|
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
// deno-lint-ignore-file ban-types
|
|
2
1
|
// deno-fmt-ignore-file
|
|
3
2
|
import { Deferred } from '../types/deferred.mjs';
|
|
4
|
-
import {
|
|
3
|
+
import { OptionsAction } from '../engine/options/instantiate.mjs';
|
|
5
4
|
/** Creates a deferred Options action. */
|
|
6
5
|
export function OptionsDeferred(type, options) {
|
|
7
6
|
return Deferred('Options', [type, options], {});
|
|
8
7
|
}
|
|
9
|
-
/** Applies an Options action to the given type. */
|
|
8
|
+
/** Applies an immediate Options action to the given type. */
|
|
10
9
|
export function Options(type, options) {
|
|
11
|
-
return
|
|
10
|
+
return OptionsAction(type, options);
|
|
12
11
|
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { type TSchema, type TSchemaOptions } from '../types/schema.mjs';
|
|
2
2
|
import { type TDeferred } from '../types/deferred.mjs';
|
|
3
|
-
import { type
|
|
3
|
+
import { type TParametersAction } from '../engine/parameters/instantiate.mjs';
|
|
4
4
|
/** Creates a deferred Parameters action. */
|
|
5
5
|
export type TParametersDeferred<Type extends TSchema> = (TDeferred<'Parameters', [Type]>);
|
|
6
6
|
/** Creates a deferred Parameters action. */
|
|
7
7
|
export declare function ParametersDeferred<Type extends TSchema>(type: Type, options?: TSchemaOptions): TParametersDeferred<Type>;
|
|
8
8
|
/** Applies a Parameters action to the given type. */
|
|
9
|
-
export type TParameters<Type extends TSchema> = (
|
|
9
|
+
export type TParameters<Type extends TSchema> = (TParametersAction<Type>);
|
|
10
10
|
/** Applies a Parameters action to the given type. */
|
|
11
11
|
export declare function Parameters<Type extends TSchema>(type: Type, options?: TSchemaOptions): TParameters<Type>;
|
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
// deno-lint-ignore-file ban-types
|
|
2
1
|
// deno-fmt-ignore-file
|
|
3
2
|
import { Deferred } from '../types/deferred.mjs';
|
|
4
|
-
import {
|
|
3
|
+
import { ParametersAction } from '../engine/parameters/instantiate.mjs';
|
|
5
4
|
/** Creates a deferred Parameters action. */
|
|
6
5
|
export function ParametersDeferred(type, options = {}) {
|
|
7
6
|
return Deferred('Parameters', [type], options);
|
|
8
7
|
}
|
|
9
8
|
/** Applies a Parameters action to the given type. */
|
|
10
9
|
export function Parameters(type, options = {}) {
|
|
11
|
-
return
|
|
10
|
+
return ParametersAction(type, options);
|
|
12
11
|
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { type TSchema, type TSchemaOptions } from '../types/schema.mjs';
|
|
2
2
|
import { type TDeferred } from '../types/deferred.mjs';
|
|
3
|
-
import { type
|
|
3
|
+
import { type TPartialAction } from '../engine/partial/instantiate.mjs';
|
|
4
4
|
/** Creates a deferred Partial action. */
|
|
5
5
|
export type TPartialDeferred<Type extends TSchema> = (TDeferred<'Partial', [Type]>);
|
|
6
6
|
/** Creates a deferred Partial action. */
|
|
7
|
-
export declare function PartialDeferred<Type extends TSchema>(type: Type, options?: TSchemaOptions):
|
|
7
|
+
export declare function PartialDeferred<Type extends TSchema>(type: Type, options?: TSchemaOptions): TPartialDeferred<Type>;
|
|
8
8
|
/** Applies a Partial action to the given type. */
|
|
9
|
-
export type TPartial<Type extends TSchema> = (
|
|
9
|
+
export type TPartial<Type extends TSchema> = (TPartialAction<Type>);
|
|
10
10
|
/** Applies a Partial action to the given type. */
|
|
11
11
|
export declare function Partial<Type extends TSchema>(type: Type, options?: TSchemaOptions): TPartial<Type>;
|