@aeriajs/types 0.0.124 → 0.0.126

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.
@@ -11,7 +11,7 @@ export type PropertyInputType = typeof PROPERTY_INPUT_TYPES[number];
11
11
  export type PropertyInputElement = typeof PROPERTY_INPUT_ELEMENTS[number];
12
12
  export type PropertyFormat = typeof PROPERTY_FORMATS[number];
13
13
  export type PropertiesWithId<TJsonSchema extends JsonSchema> = Extract<keyof TJsonSchema['properties'], string> | '_id';
14
- export type RequiredProperties<TJsonSchema extends JsonSchema> = readonly PropertiesWithId<TJsonSchema>[] | Partial<Record<PropertiesWithId<TJsonSchema>, Condition<TJsonSchema> | boolean>>;
14
+ export type RequiredProperties<TJsonSchema extends JsonSchema = JsonSchema> = readonly PropertiesWithId<TJsonSchema>[] | Partial<Record<PropertiesWithId<TJsonSchema>, Condition<TJsonSchema> | boolean>>;
15
15
  export type JsonSchema<TJsonSchema extends JsonSchema = any> = {
16
16
  $id: string;
17
17
  type?: 'object';
package/dist/schema.d.ts CHANGED
@@ -16,6 +16,8 @@ type TestType<T> = T & Record<string, unknown>;
16
16
  export type InferProperty<T> = T extends TestType<{
17
17
  format: 'date' | 'date-time';
18
18
  }> ? Date : T extends TestType<{
19
+ format: 'objectid';
20
+ }> ? ObjectId : T extends TestType<{
19
21
  enum: ReadonlyArray<infer K>;
20
22
  }> ? K : T extends TestType<{
21
23
  type: 'string';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aeriajs/types",
3
- "version": "0.0.124",
3
+ "version": "0.0.126",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",