dynamic-forms-bootstrap / Function

removeArrayItemButtonFieldMapper

Mapper for remove array item button - preconfigures RemoveArrayItemEvent with array context.

Supports two modes:

  1. Inside array template: Uses ARRAY_CONTEXT to determine target array and removes item at current index
  2. Outside array: Uses arrayKey property from field definition, removes last item by default

Presentation

function removeArrayItemButtonFieldMapper(
  fieldDef: RemoveArrayItemButtonField,
): Signal<Record<string, unknown>>;

Returns

Signal<Record<string, unknown>> -

Signal containing Record of input names to values for ngComponentOutlet

Parameters

NameTypeDescription
fieldDef
RemoveArrayItemButtonField

The remove array item button field definition