AddonKindSchema
@ng-forge/dynamic-forms
Minimal JSON Schema fragment used by the MCP server to surface an addon
kind's shape to AI form generators. Covers the common subset
(type/properties/required/enum/etc.) without pulling in a full JSON
Schema dependency. Extra keys are allowed via the [key: string] index so
vendor-specific annotations (x-foo, markdownDescription) still typecheck.
Tooling-only: the runtime addon validator does NOT consult schema — it
relies on each kind's validate?(addon, fieldKey) callback for shape
enforcement. schema exists exclusively so the MCP server (and any other
AI-driven form authoring tool) can describe the kind to a model without
hand-maintaining a parallel registry.
Signature
interface AddonKindSchemaProperties
| Name | Type | Description |
|---|---|---|
$ref ? | string | undefined | - |
$schema ? | string | undefined | - |
title ? | string | undefined | - |
description ? | string | undefined | - |
type ? | "string" | "number" | "boolean" | "object" | "array" | "integer" | "null" | readonly ("string" | "number" | "boolean" | "object" | "array" | "integer" | "null")[] | undefined | - |
enum ? | readonly unknown[] | undefined | - |
const ? | unknown | - |
properties ? | Readonly<Record<string, AddonKindSchema>> | undefined | - |
required ? | readonly string[] | undefined | - |
additionalProperties ? | boolean | AddonKindSchema | undefined | - |
items ? | AddonKindSchema | readonly AddonKindSchema[] | undefined | - |
oneOf ? | readonly AddonKindSchema[] | undefined | - |
anyOf ? | readonly AddonKindSchema[] | undefined | - |
allOf ? | readonly AddonKindSchema[] | undefined | - |
not ? | AddonKindSchema | undefined | - |
default ? | unknown | - |
examples ? | readonly unknown[] | undefined | - |
minimum ? | number | undefined | - |
maximum ? | number | undefined | - |
minLength ? | number | undefined | - |
maxLength ? | number | undefined | - |
pattern ? | string | undefined | - |
format ? | string | undefined | - |
packages/dynamic-forms/src/lib/models/addon/addon-kind.ts:19