InputRowArray#

class ansys.solutions.dash_super_components.InputRowArray(items: list[dict[str, Any]], enable_multiple_rows: bool = False, aio_id: str | None = None, full_width: bool = False)#

Bases: Div

A Dash component to create an array of inputs.

InputRowArray is based on the Dash All-in-One (AIO) component pattern. It renders a set of input fields as a single row, and optionally allows users to add or remove additional rows dynamically.

Each field is defined by a dict with the following keys:

  • "type" (required): "TextInput", "NumberInput", or "Select".

  • "id" (required): unique string identifier for the field.

  • "properties" (required): dict of dash mantine component properties.

Parameters:
itemslist of dict

A list of dictionaries defining each input field in a row. Each dict must contain "type", "id", and "properties" keys. Supported types: "TextInput", "NumberInput", "Select".

enable_multiple_rowsbool, optional

If True, add and delete buttons are displayed so that users can create or remove extra rows at runtime. Default is False.

aio_idstr, optional

The unique identifier for the component. A UUID is generated if not provided.

full_widthbool, optional

If True, the input row container expands to 100% of the available parent width so fields can spread across the row. If False, the container keeps its base inline-block width behavior. Default is False.

IDs

class ansys.solutions.dash_super_components.InputRowArray.InputRowArrayIds#

Bases: AIOIds

Provides IDs for the subcomponents of InputRowArray.

classmethod add_button(aio_id: str | Wildcard) → dict[str, Any]#

Return the ID for the add button component.

Parameters:
aio_idstr or _Wildcard

The component’s unique identifier.

Returns:
dict[str, Any]

The unique ID dictionary for the add button subcomponent.

classmethod delete_button(aio_id: str | Wildcard) → dict[str, Any]#

Return the ID for the delete button component.

Parameters:
aio_idstr or _Wildcard

The component’s unique identifier.

Returns:
dict[str, Any]

The unique ID dictionary for the delete button subcomponent.

classmethod input(aio_id: str | Wildcard, item_id: str | Wildcard, row_index: int | None | Wildcard = None) → dict[str, Any]#

Return the ID for an input item.

Parameters:
aio_idstr or _Wildcard

The component’s unique identifier.

item_idstr or _Wildcard

The unique identifier of the input item (item[“id”]).

row_indexint, None, or _Wildcard, default: None

The unique row index. If None, defaults to 0.

Returns:
dict[str, Any]

The unique ID dictionary for an input item subcomponent.

classmethod rows(aio_id: str | Wildcard) → dict[str, Any]#

Return the ID for the rows component.

Parameters:
aio_idstr or _Wildcard

The component’s unique identifier.

Returns:
dict[str, Any]

The unique ID dictionary for the rows subcomponent.