Package org.patternfly.component.form
Class TextInput
java.lang.Object
org.patternfly.component.BaseComponent<E,B>
org.patternfly.component.form.FormControl<elemental2.dom.HTMLElement,TextInput>
org.patternfly.component.form.TextInput
- All Implemented Interfaces:
Container<elemental2.dom.HTMLElement,,TextInput> Finder<elemental2.dom.HTMLElement>,HasElement<elemental2.dom.HTMLElement,,TextInput> HasHTMLElement<elemental2.dom.HTMLElement,,TextInput> IsElement<elemental2.dom.HTMLElement>,TypedBuilder<elemental2.dom.HTMLElement,,TextInput> Component,HasValue<String>,WithIcon<elemental2.dom.HTMLElement,,TextInput> WithText<elemental2.dom.HTMLElement,,TextInput> Modifiers.Disabled<elemental2.dom.HTMLElement,,TextInput> Modifiers.Plain<elemental2.dom.HTMLElement,,TextInput> Modifiers.Readonly<elemental2.dom.HTMLElement,,TextInput> Modifiers.Required<elemental2.dom.HTMLElement,TextInput>
public class TextInput
extends FormControl<elemental2.dom.HTMLElement,TextInput>
implements HasValue<String>, Modifiers.Plain<elemental2.dom.HTMLElement,TextInput>, Modifiers.Readonly<elemental2.dom.HTMLElement,TextInput>, WithIcon<elemental2.dom.HTMLElement,TextInput>, WithText<elemental2.dom.HTMLElement,TextInput>
A text input is used to gather free-form text from a user.
-
Method Summary
Modifier and TypeMethodDescriptionapplyTo(Consumer<InputElementBuilder<elemental2.dom.HTMLInputElement>> consumer) Provides access to the underlying input element using a fluent API styleexpanded()Same as expanded(true)expanded(boolean expanded) Adds/removes modifier(expanded)icon(elemental2.dom.Element icon) InputElementBuilder<elemental2.dom.HTMLInputElement>Returns the underlying input elementonChange(ChangeHandler<TextInput, String> changeHandler) Defines a change handler that is called when thevalue()of this text area changes.onKeyup(ChangeHandler<TextInput, String> changeHandler) Defines a change handler that is called when thevalue()of this text area changes.placeholder(String placeholder) plain(boolean plain) readonly(boolean readonly) required(boolean required) text()Same asvalue(String)static TextInputstatic TextInputstatic TextInputtextInput(TextInputType type, String id) static TextInputtextInput(TextInputType type, String id, String value) that()value()Same as value(value, false)Methods inherited from class org.patternfly.component.form.FormControl
disabled, resetValidation, validatedMethods inherited from class org.patternfly.component.BaseComponent
componentType, elementMethods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.jboss.elemento.Container
add, add, add, addAll, addAll, addAll, addAll, addAll, addAllMethods inherited from interface org.jboss.elemento.HasElement
add, apply, aria, aria, aria, attr, attr, attr, classList, classList, css, id, innerHtml, on, on, on, run, textContent, textNode, toggle, toggle, toggle, uniqueIdMethods inherited from interface org.jboss.elemento.HasHTMLElement
data, hidden, style, style, style, style, style, style, titleMethods inherited from interface org.patternfly.style.Modifiers.Disabled
disabled, isDisabledMethods inherited from interface org.patternfly.style.Modifiers.Plain
plainMethods inherited from interface org.patternfly.style.Modifiers.Readonly
readonlyMethods inherited from interface org.patternfly.style.Modifiers.Required
required
-
Method Details
-
textInput
-
textInput
-
textInput
-
textInput
-
readonly
- Specified by:
readonlyin interfaceModifiers.Readonly<elemental2.dom.HTMLElement,TextInput>
-
expanded
Same as expanded(true) -
expanded
Adds/removes modifier(expanded) -
plain
- Specified by:
plainin interfaceModifiers.Plain<elemental2.dom.HTMLElement,TextInput>
-
required
- Specified by:
requiredin interfaceModifiers.Required<elemental2.dom.HTMLElement,TextInput>
-
text
Same asvalue(String) -
value
Same as value(value, false) -
value
-
placeholder
-
applyTo
Provides access to the underlying input element using a fluent API style -
icon
-
removeIcon
- Specified by:
removeIconin interfaceWithIcon<elemental2.dom.HTMLElement,TextInput>
-
that
- Specified by:
thatin interfaceTypedBuilder<elemental2.dom.HTMLElement,TextInput>
-
onKeyup
Defines a change handler that is called when thevalue()of this text area changes. Changes are detected by adding an event listener for theEventType.keyupevent to the text input element. -
onChange
Defines a change handler that is called when thevalue()of this text area changes. Changes are detected by adding an event listener for theEventType.changeevent to the text input element. -
value
-
inputElement
Returns the underlying input element -
text
-