API Reference
Browse the public API surface of ng-forge packages
Core @ng-forge/dynamic-forms
Components 4
Renderer for the universal `component` addon type. @codeOnly The `component` loader is a function; this kind is dropped...
Renders a form from a {@link FormConfig}. Attribute component on a native `<form>` element (selector `form[dynamic-form]...
Renderer for the universal `template` addon type.
Renderer for the universal `text` addon type.
Classes 16
Event dispatched to append a new item at the END of an array field.
Console-based logger implementation.
Base error class for all Dynamic Forms errors.
Event dispatched when the form should be cleared.
Event dispatched when the form should be reset to its default values.
Event dispatched to submit the form (the action behind a `submit` button).
Event dispatched to insert a new item at a SPECIFIC INDEX in an array field.
Event dispatched to move an existing item from one index to another within an array field.
Event dispatched to advance a paged form to the next page.
No-operation logger implementation. All methods are no-ops - used in production by default.
Event emitted when the active page of a paged form changes.
Event dispatched to remove the LAST item from an array field.
Event dispatched to prepend a new item at the BEGINNING of an array field.
Event dispatched to return a paged form to the previous page.
Event dispatched to remove an item at a SPECIFIC INDEX from an array field.
Event dispatched to remove the FIRST item from an array field.
Interfaces 63
Per-type registration metadata.
Configuration for auto-generated add/remove buttons in simplified array fields.
Array field interface for creating dynamic field collections that map to array values.
Context object for array item operations (add/remove) Provides the necessary information to resolve tokens in array item...
Async custom validator configuration using Angular's resource-based API
Base shape every addon type extends.
Base configuration shared by all validators
Built-in validator configuration (required, email, min, max, etc.)
Renders an arbitrary Angular component as the addon body. @codeOnly The `component` loader is a function and cannot sur...
Container field interface for wrapping child fields with UI chrome.
Configuration for the built-in 'css' wrapper type.
Signal forms adapter configuration for advanced form behavior.
Custom validator configuration using Angular's public FieldContext API. Returns ValidationError | ValidationError[] | nu...
Declarative HTTP validator configuration — fully JSON-serializable, no function registration required.
Module-augmentable registry of user-defined named action handlers.
Module-augmentable registry of adapter-specific preset names.
Module-augmentable registry of addon types.
Module-augmentable registry of adapter-specific addon slot names.
Global interface for dynamic form field definitions with categorization This interface combines containers and leaves fr...
Field-bound variant — the addon is attached to a real field and has a working value-writer. The common case for `pi-butt...
Base interface for all dynamic form field definitions.
Base interface for native HTML attributes that can be passed to form field elements.
Container fields registry - augment this interface to add custom container fields
Leaf fields registry - augment this interface to add custom leaf fields
Wrapper type registry for module augmentation.
Contract that wrapper components must satisfy. @Component({ template: ` <dbx-section [header]="header() ?? ''"> ...
Configuration interface for defining dynamic form structure and behavior.
Base interface for all form events in the dynamic form system.
Result of form mode detection with validation details
Global form configuration options.
Group field interface for creating logical field groupings that map to object values Groups create nested form structure...
Hidden field definition for storing values without rendering UI.
Condition that evaluates based on an HTTP response from a remote server.
HTTP-based validator configuration for Angular's validateHttp API
Configuration for an HTTP request used by declarative HTTP validators, derivations, and conditions.
Mapping configuration for interpreting HTTP responses as validation results.
Interface for dynamic forms logger implementations. Allows custom logging integrations (Sentry, DataDog, etc.)
Options for controlling next page button disabled behavior.
Orphan variant — the addon is rendered outside any field component (rare; happens when consumers compose `<df-addon-slot...
Page field interface for creating top-level page layouts This is a special field type that contains other field definiti...
Row field interface for creating horizontal layouts. A row is a synthetic field type that resolves to a Container at run...
Result of a `sanitizeFormConfig` call.
Options accepted by {@link sanitizeFormConfig}.
Configuration for applying predefined schemas
Reusable schema definition that can be referenced by name
Simplified array field interface for common use cases.
Configuration for form submission handling.
Options for controlling submit button disabled behavior.
Renders a named `<ng-template>` projected into the host `<df-dynamic-form>`.
Renders text content inline.
Text field definition for displaying translatable text content
Context for token resolution in event args
Configuration for when validation runs based on a field's reactive state.
Configuration for excluding field values from form submission output based on their reactive state (hidden, disabled, re...
User-facing wrapper registration shape used with `createWrappers(...)`.
Branded bundle returned by `createWrappers(...)`.
Configuration interface for registering wrapper types.
Types 57
Context handed to inline addon actions and registered handler functions.
Union of every preset name an addon may reference — universal presets plus any contributed via {@link DynamicFormAddonAc...
Typed feature returned by {@link withAddonActions}. Carries the registered handler keys as a phantom type so consumers c...
Union of every valid addon slot — universal slots plus any registered via {@link DynamicFormAddonSlotRegistry} module au...
Reason an addon was dropped during validation.
Union of every registered addon shape.
Fields that are allowed as children of Array fields Arrays can contain: rows, groups, and leaf fields (but NOT pages or ...
Template type for array items used in events. Canonical definition lives in {@link ArrayItemDefinition} — this alias pre...
An array item template is an array of allowed children that defines one OBJECT array item's fields. Used for object arra...
Condition that resolves asynchronously via a custom function.
Async function for conditions — returns boolean.
Async function for derivations — returns any value.
Async custom validator configuration using Angular's `validateAsync` API. Returns Observable<ValidationError | Validatio...
Extract field types that are available in the registry
Built-in preset actions shared across adapters.
Universal addon slot names supported by every adapter.
Discriminated union of all conditional expression types.
Fields that are allowed as children of Container fields. Containers are pure layout primitives that flatten their childr...
Union type of all registered container field definitions
Custom function signature for conditional expressions
Custom validator function signature using Angular's public FieldContext API
Generic reactive value — a static value, an Angular Signal, or an RxJS Observable.
Extract a specific field type from RegisteredFieldTypes based on the `type` discriminant. This enables proper type narro...
Extract FieldDef types from provider result
Extract form value type from provider result
Type utility for extracting component input properties from field definitions. @Component({...}) export class MyFieldCo...
Type helper for accessing nested field paths safely This allows accessing child paths while maintaining some type safety
Constructor type for form event classes.
Form mode enumeration distinguishing between paged and non-paged forms
Special form-state conditions for button disabled logic.
Fields that are allowed as children of Group fields Groups can contain: rows, arrays, and leaf fields (but NOT pages or ...
Scalar types supported by hidden fields. These are the primitive value types that can be stored.
All value types supported by hidden fields. Supports both scalar values and arrays of scalars for storing multiple IDs o...
Infer form value type from fields array or FormConfig. Recursively processes nested structures and merges the results. L...
Derive the `FieldRegistryWrappers` augmentation shape from a wrapper bundle.
Union type of all registered leaf field definitions
Union type for all logic configurations.
Narrow a field definition based on its `type` property. Use this to get proper type inference when working with field un...
Narrow each field in an array based on its `type` property. Use with `satisfies` to get proper type inference for field ...
Type constraints for field nesting rules These ensure that container fields can only contain valid child field types Fi...
Typed string handle to a registered action handler. The empty registry resolves to `never`; augmenting `DynamicFormActio...
Union type of all registered field definitions
Fully resolved validation execution config — every property defined.
Fully resolved exclusion config with all properties required. Produced by the 3-tier resolution: `field ?? form ?? globa...
Row is a synthetic field type that resolves to a Container at runtime, so it accepts the same children as a Container.
Configuration for conditional field state logic.
The result type for submission actions. Can be either a Promise or an Observable.
Text element type for rendering different HTML text elements
Properties for text field configuration
Re-export Angular's ValidationError for consistency This replaces our custom ValidationError interface
Configuration for signal forms validator functions that can be serialized from API. Discriminated union type for type-sa...
Supported primitive value types for form fields. This type represents all possible value types that can be used in form ...
Resolves a wrapper type name to its registered config interface.
Functions 28
Builder for array manipulation events.
Bundle wrapper registrations into a single object that can be passed to `provideDynamicForm(...)`.
Type guard to check if a form event has a form value attached.
Type guard for ArrayField with proper type narrowing. Validates that the field is an array type with a fields property t...
Type guard to check if a field is a container field (page, row, group, or array) Container fields have a 'fields' proper...
Type guard to check if a field is excluded from form values (display-only field) Currently this includes text fields and...
Type guard narrowing {@link AddonActionContext} to its field-bound variant.
Type guard to check if a condition is a FormStateCondition.
Type guard for GroupField with proper type narrowing
Type guard to check if a field is a hidden field.
Type guard to check if a field is a leaf field (value or display field) Leaf fields don't have children and either contr...
Type guard for PageField with proper type narrowing
Type guard for RowField with proper type narrowing
Type guard for SimplifiedArrayField. Checks for `type: 'array'` with a `template` property (discriminant from full Array...
Type guard to check if a field has a value property (value-bearing field) These fields contribute to the form value outp...
Type guard for a `WrappersBundle`.
Type guard for WrapperTypeDefinition.
Provider function to configure the dynamic form system with field types and options.
Normalises a {@link DynamicValue} into a `Signal<T>`.
Walk a `FormConfig`, validate every field's addons against the active `FIELD_REGISTRY` and `ADDON_TYPE_REGISTRY`, and re...
Register named action handlers reachable via JSON-driven addon configs.
Register a custom addon type with the form.
Enables automatic form value attachment to all events dispatched through the EventBus.
Opt into Angular Signal Forms' legacy `.ng-touched` / `.ng-invalid` / `.ng-dirty` / `.ng-pristine` / `.ng-untouched` / `...
Configure logging for dynamic forms.
Configures global validation execution defaults — when validators should run relative to a field's reactive state.
Configures global value exclusion defaults for form submission output.
Zero-cost type carrier used in wrapper registrations.
Constants 3
Material @ng-forge/dynamic-forms-material
Components 12
Renderer for the `mat-button` addon type.
Renderer for the `mat-icon` addon type.
Interfaces 13
Module-augmentable seam for adding custom addon types to `mat-input` at the type level. Pair with `withCustomAddon(...)`...
Configuration options for Material Design form fields.
Decorative icon addon for Material fields.
Types 25
Add array item button field - dispatches AppendArrayItemEvent
Union of all Material-shipped addon types.
Interactive button addon for Material fields.
Material-specific FormConfig with type-safe defaultProps.
Material-specific props that can be set at form level and cascade to all fields.
Addon types accepted by `mat-input`.
Insert array item button field - dispatches InsertArrayItemEvent (adds at specific index)
Next page button field - with preconfigured NextPageEvent
Pop array item button field - dispatches PopArrayItemEvent (removes last item)
Prepend array item button field - dispatches PrependArrayItemEvent (adds at beginning)
Previous page button field - with preconfigured PreviousPageEvent
Remove array item button field - dispatches RemoveAtIndexEvent or PopArrayItemEvent
Shift array item button field - dispatches ShiftArrayItemEvent (removes first item)
Specific button field types with preconfigured events Submit button field - automatically disabled when form is invalid
Functions 2
Constants 4
Per-field writable signal that overrides the input's `type` attribute. @Component({ providers: [{ provide: MAT_INPUT_...
Injection token for Material Design form configuration. Use this to provide global configuration for Material form field...
Material Design field type definitions Follows the FieldTypeDefinition interface for proper registry integration
Material Design field type constants Based on available field components in the /fields folder