ICardTextInputParameters interface

Text input component parameters.

Extends

Properties

ariaLabel

Aria label for the text field.

button

Optional button to display.

componentName

Unique component name.

defaultValue

Default value to display.

iconAfter

Properties for an optional icon, displayed in the right end of the text input.

iconBefore

Properties for an optional icon, displayed in the left end of the text input.

onChange

Text change event handler.

placeholder

Placeholder text to display.

value

Current value of the text input.

Property Details

ariaLabel

Aria label for the text field.

ariaLabel?: string;

Property Value

string

button

Optional button to display.

button?: ICardTextInputIconButton | ICardTextInputTitleButton;

Property Value

componentName

Unique component name.

componentName: 'textInput';

Property Value

'textInput'

defaultValue

Default value to display.

defaultValue?: string;

Property Value

string

Remarks

Provide this if the input should be an uncontrolled component which tracks its current state internally; otherwise, use value.

iconAfter

Properties for an optional icon, displayed in the right end of the text input.

iconAfter?: IAdaptiveCardExtensionIcon;

Property Value

iconBefore

Properties for an optional icon, displayed in the left end of the text input.

iconBefore?: IAdaptiveCardExtensionIcon;

Property Value

onChange

Text change event handler.

onChange?: (newValue?: string) => void;

Property Value

(newValue?: string) => void

placeholder

Placeholder text to display.

placeholder?: string;

Property Value

string

value

Current value of the text input.

value?: string;

Property Value

string

Remarks

Provide this if the input is a controlled component where you are maintaining its current state. Use empty string as initial value if needed.