Input class
Class for an input with optional fields.
Signature:
export declare class Input
Constructors
Constructor | Modifiers | Description |
|---|---|---|
Constructs a new instance of the |
Properties
Property | Modifiers | Type | Description |
|---|---|---|---|
Alignment of input's fields (left, right or centre). | |||
Connection | null | |||
Field[] | |||
string | |||
|
Methods
Method | Modifiers | Description |
|---|---|---|
Add a field (or label from string), and all prefix and suffix fields, to the end of the input's field row. | ||
Sever all links to this input. | ||
Returns the string from the custom ARIA label provider set, or null if the default label (from the field row) should be used. See setAriaLabelProvider for more context. | ||
Returns the XML representation of the connection's shadow block. | ||
Get the source block for this input. | ||
Initialize the fields on this input. | ||
Inserts a field (or label from string), and all prefix and suffix fields, at the location of the input's field row. | ||
Gets whether this input is visible or not. | ||
| Constructs a connection based on the type of this input's source block. Properly handles constructing headless connections for headless blocks and rendered connections for rendered blocks. | |
Remove a field from this input. | ||
Change the alignment of the connection's field(s). | ||
Sets a custom ARIA label provider for this input, or null if it should be reset to use the default method. Inputs do not compute ARIA contexts directly, so the set provider will be used in select cases when the Input needs to be represented (such as for parts of a block label or for connections). Note that overriding this provider will not recompute any already constructed ARIA labels, and it cannot be assumed that the provider will be called any particular number of times during label recomputation. As such, implementations should make sure to provide a deterministic and idempotent ARIA representation each time the provider is called for a given input. It's also fine to reuse providers across multiple Input implementations. | ||
Change a connection's compatibility. | ||
Changes the connection's shadow block. |