typebox 1.3.14 → 1.3.15

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.
@@ -0,0 +1,5 @@
1
+ import type { XSchema } from '../types/schema.mjs';
2
+ import type { XStaticSchema } from './schema.mjs';
3
+ export type XStaticPropertyNames<Stack extends string[], Root extends XSchema, Schema extends XSchema, StaticKey extends unknown = XStaticSchema<Stack, Root, Schema>, Result extends Record<string, unknown> = [StaticKey] extends [PropertyKey] ? {
4
+ [Key in StaticKey]?: unknown;
5
+ } : {}> = Result;
@@ -0,0 +1,3 @@
1
+ // deno-lint-ignore-file ban-types
2
+ // deno-fmt-ignore-file
3
+ export {};
@@ -9,6 +9,7 @@ import type { XOneOf } from '../types/oneOf.mjs';
9
9
  import type { XPatternProperties } from '../types/patternProperties.mjs';
10
10
  import type { XPrefixItems } from '../types/prefixItems.mjs';
11
11
  import type { XProperties } from '../types/properties.mjs';
12
+ import type { XPropertyNames } from '../types/propertyNames.mjs';
12
13
  import type { XRef } from '../types/ref.mjs';
13
14
  import type { XRequired } from '../types/required.mjs';
14
15
  import type { XSchema } from '../types/schema.mjs';
@@ -25,6 +26,7 @@ import type { XStaticOneOf } from './oneOf.mjs';
25
26
  import type { XStaticPatternProperties } from './patternProperties.mjs';
26
27
  import type { XStaticPrefixItems } from './prefixItems.mjs';
27
28
  import type { XStaticProperties } from './properties.mjs';
29
+ import type { XStaticPropertyNames } from './propertyNames.mjs';
28
30
  import type { XStaticRef } from './ref.mjs';
29
31
  import type { XStaticRequired } from './required.mjs';
30
32
  import type { XStaticType } from './type.mjs';
@@ -41,6 +43,7 @@ type XFromKeywords<Stack extends string[], Root extends XSchema, Schema extends
41
43
  Schema extends XPatternProperties<infer Properties extends Record<PropertyKey, XSchema>> ? XStaticPatternProperties<Stack, Root, Properties> : unknown,
42
44
  Schema extends XPrefixItems<infer Types extends XSchema[]> ? XStaticPrefixItems<Stack, Root, Schema, Types> : unknown,
43
45
  Schema extends XProperties<infer Properties extends Record<PropertyKey, XSchema>> ? XStaticProperties<Stack, Root, Schema, Properties> : unknown,
46
+ Schema extends XPropertyNames<infer Type extends XSchema> ? XStaticPropertyNames<Stack, Root, Type> : unknown,
44
47
  Schema extends XRef<infer Ref extends string> ? XStaticRef<Stack, Root, Ref> : unknown,
45
48
  Schema extends XRequired<infer Keys extends string[]> ? XStaticRequired<Stack, Root, Schema, Keys> : unknown,
46
49
  Schema extends XType<infer TypeName extends string[] | string> ? XStaticType<TypeName> : unknown,
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "typebox",
3
3
  "description": "Json Schema Type Builder with Static Type Resolution for TypeScript",
4
- "version": "1.3.14",
4
+ "version": "1.3.15",
5
5
  "keywords": [
6
6
  "typescript",
7
7
  "jsonschema"