(
description: string | undefined,
options: { min?: number; max?: number },
)
| 527 | } |
| 528 | |
| 529 | function integerSchemaWithBounds( |
| 530 | description: string | undefined, |
| 531 | options: { min?: number; max?: number }, |
| 532 | ): JsonSchema { |
| 533 | return { |
| 534 | ...integerSchema(description), |
| 535 | ...(options.min === undefined ? {} : { minimum: options.min }), |
| 536 | ...(options.max === undefined ? {} : { maximum: options.max }), |
| 537 | }; |
| 538 | } |
| 539 | |
| 540 | function fieldProperties(fields: CommandFieldMap): Record<string, JsonSchema> { |
| 541 | return Object.fromEntries(Object.entries(fields).map(([key, field]) => [key, field.schema])); |
no test coverage detected