pub struct TextareaProps {
pub class: Class,
pub color: SharedString,
pub size: SharedString,
pub state: SharedString,
pub initial_value: String,
pub on_change: Option<EventHandler<String>>,
pub on_input: Option<EventHandler<String>>,
/* private fields */
}
Expand description
The Textarea
properties struct for the configuration of the component.
Fields§
§class: Class
The class attribute for the component.
color: SharedString
The color of the input: primary
| link
| info
| success
| warning
| danger
.
size: SharedString
The size of the input: small
| normal
| medium
| large
.
state: SharedString
The state of the input: hovered
| focused
| loading
.
initial_value: String
The initial value of the textarea.
on_change: Option<EventHandler<String>>
An event handler to be called when the textarea state is changed.
on_input: Option<EventHandler<String>>
An event handler to be called when inputing.
Implementations§
Source§impl TextareaProps
impl TextareaProps
Sourcepub fn builder() -> TextareaPropsBuilder<((), (), (), (), (), (), ())>
pub fn builder() -> TextareaPropsBuilder<((), (), (), (), (), (), ())>
Create a builder for building TextareaProps
.
On the builder, call .class(...)
(optional), .color(...)
(optional), .size(...)
(optional), .state(...)
(optional), .initial_value(...)
(optional), .on_change(...)
(optional), .on_input(...)
(optional) to set the values of the fields.
Finally, call .build()
to create the instance of TextareaProps
.
Trait Implementations§
Source§impl Clone for TextareaProps
impl Clone for TextareaProps
Source§fn clone(&self) -> TextareaProps
fn clone(&self) -> TextareaProps
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more