Prettier formatting

This commit is contained in:
Luke Hagar
2025-10-01 19:33:18 +00:00
parent 9aca409a38
commit 5685fc2796
166 changed files with 35810 additions and 49685 deletions

View File

@@ -88,147 +88,147 @@ import type { XML } from "../xml";
* ```
*/
export interface ObjectSchema extends Extension {
/**
* The type identifier for object schemas.
* Must be "object".
*/
type: "object";
/**
* The type identifier for object schemas.
* Must be "object".
*/
type: "object";
/**
* A map of property names to their schemas.
* Each property in the object must conform to its corresponding schema.
*
* Example: `{ name: { type: "string" }, age: { type: "number" } }`
*/
properties?: Record<string, unknown>;
/**
* A map of property names to their schemas.
* Each property in the object must conform to its corresponding schema.
*
* Example: `{ name: { type: "string" }, age: { type: "number" } }`
*/
properties?: Record<string, unknown>;
/**
* An array of required property names.
* These properties must be present in the object.
*
* Example: `["name", "email"]`
*/
required?: string[];
/**
* An array of required property names.
* These properties must be present in the object.
*
* Example: `["name", "email"]`
*/
required?: string[];
/**
* The schema for additional properties not defined in properties.
* If false, no additional properties are allowed.
* If true, any additional properties are allowed.
* If a schema, additional properties must conform to this schema.
*
* Example: `{ type: "string" }` or `false` or `true`
*/
additionalProperties?: unknown | boolean;
/**
* The schema for additional properties not defined in properties.
* If false, no additional properties are allowed.
* If true, any additional properties are allowed.
* If a schema, additional properties must conform to this schema.
*
* Example: `{ type: "string" }` or `false` or `true`
*/
additionalProperties?: unknown | boolean;
/**
* A map of regex patterns to schemas.
* Properties whose names match a pattern must conform to the corresponding schema.
*
* Example: `{ "^S_": { type: "string" } }`
*/
patternProperties?: Record<string, unknown>;
/**
* A map of regex patterns to schemas.
* Properties whose names match a pattern must conform to the corresponding schema.
*
* Example: `{ "^S_": { type: "string" } }`
*/
patternProperties?: Record<string, unknown>;
/**
* The schema for property names.
* All property names in the object must conform to this schema.
*
* Example: `{ type: "string", pattern: "^[A-Za-z][A-Za-z0-9]*$" }`
*/
propertyNames?: unknown;
/**
* The schema for property names.
* All property names in the object must conform to this schema.
*
* Example: `{ type: "string", pattern: "^[A-Za-z][A-Za-z0-9]*$" }`
*/
propertyNames?: unknown;
/**
* The minimum number of properties in the object.
* Must be a non-negative integer.
*
* Example: `1`
*/
minProperties?: number;
/**
* The minimum number of properties in the object.
* Must be a non-negative integer.
*
* Example: `1`
*/
minProperties?: number;
/**
* The maximum number of properties in the object.
* Must be a non-negative integer.
*
* Example: `10`
*/
maxProperties?: number;
/**
* The maximum number of properties in the object.
* Must be a non-negative integer.
*
* Example: `10`
*/
maxProperties?: number;
/**
* A map of property names to arrays of required properties.
* If a property is present, the properties in its array must also be present.
*
* Example: `{ credit_card: ["billing_address"] }`
*/
dependentRequired?: Record<string, string[]>;
/**
* A map of property names to arrays of required properties.
* If a property is present, the properties in its array must also be present.
*
* Example: `{ credit_card: ["billing_address"] }`
*/
dependentRequired?: Record<string, string[]>;
/**
* A map of property names to schemas.
* If a property is present, the object must conform to the corresponding schema.
*
* Example: `{ credit_card: { type: "object", properties: { number: { type: "string" } } } }`
*/
dependentSchemas?: Record<string, unknown>;
/**
* A map of property names to schemas.
* If a property is present, the object must conform to the corresponding schema.
*
* Example: `{ credit_card: { type: "object", properties: { number: { type: "string" } } } }`
*/
dependentSchemas?: Record<string, unknown>;
/**
* An array of allowed values for the object.
* The value must be one of the values in this array.
*
* Example: `[{ name: "John" }, { name: "Jane" }]`
*/
enum?: Record<string, unknown>[];
/**
* An array of allowed values for the object.
* The value must be one of the values in this array.
*
* Example: `[{ name: "John" }, { name: "Jane" }]`
*/
enum?: Record<string, unknown>[];
/**
* A single allowed value for the object.
* The value must be exactly this value.
*
* Example: `{ name: "John" }`
*/
const?: Record<string, unknown>;
/**
* A single allowed value for the object.
* The value must be exactly this value.
*
* Example: `{ name: "John" }`
*/
const?: Record<string, unknown>;
/**
* An example value for the object.
* This is for documentation purposes only.
*
* Example: `{ name: "John" }`
*/
example?: Record<string, unknown>;
/**
* An example value for the object.
* This is for documentation purposes only.
*
* Example: `{ name: "John" }`
*/
example?: Record<string, unknown>;
/**
* An array of example values for the object.
* These are for documentation purposes only.
*
* Example: `[{ name: "John", age: 30 }]`
*/
examples?: Record<string, unknown>[];
/**
* An array of example values for the object.
* These are for documentation purposes only.
*
* Example: `[{ name: "John", age: 30 }]`
*/
examples?: Record<string, unknown>[];
/**
* The default value for the object.
* This value will be used if no value is provided.
*
* Example: `{}`
*/
default?: Record<string, unknown>;
/**
* The default value for the object.
* This value will be used if no value is provided.
*
* Example: `{}`
*/
default?: Record<string, unknown>;
/**
* A short title for the schema.
* This is for documentation purposes only.
*
* Example: `"User"`
*/
title?: string;
/**
* A short title for the schema.
* This is for documentation purposes only.
*
* Example: `"User"`
*/
title?: string;
/**
* A description of the schema.
* CommonMark syntax MAY be used for rich text representation.
*
* Example: `"A user object"`
*/
description?: string;
/**
* A description of the schema.
* CommonMark syntax MAY be used for rich text representation.
*
* Example: `"A user object"`
*/
description?: string;
/**
* XML representation metadata for the schema.
* Allows for fine-tuned XML model definitions.
*
* Example: `{ name: "user", attribute: false }`
*/
xml?: XML;
/**
* XML representation metadata for the schema.
* Allows for fine-tuned XML model definitions.
*
* Example: `{ name: "user", attribute: false }`
*/
xml?: XML;
}