pub struct MultiSelectProps {Show 14 fields
pub label: Element,
pub legend: Element,
pub name: String,
pub options: Vec<MultiOption>,
pub values: Option<ReadSignal<Vec<String>>>,
pub default_values: Vec<String>,
pub onchange: Option<EventHandler<Vec<String>>>,
pub filter_label: Option<String>,
pub filter_placeholder: Option<String>,
pub open: bool,
pub summary: Option<Callback<usize, String>>,
pub fc_id: Option<Id>,
pub class: Option<String>,
pub attributes: Vec<Attribute>,
}Expand description
Properties for the MultiSelect component.
Fields§
§label: ElementWhat is being chosen, shown in the summary, e.g. “Project members”.
legend: ElementThe fieldset’s legend.
name: StringShared name for form submission.
options: Vec<MultiOption>§values: Option<ReadSignal<Vec<String>>>§default_values: Vec<String>§onchange: Option<EventHandler<Vec<String>>>§filter_label: Option<String>Label for the filter field; no filter when omitted.
filter_placeholder: Option<String>§open: bool§summary: Option<Callback<usize, String>>Summary text for a count; default_summary when omitted.
fc_id: Option<Id>Mirror the selection count into the data-fc-* contract under this id.
class: Option<String>§attributes: Vec<Attribute>Implementations§
Source§impl MultiSelectProps
impl MultiSelectProps
Sourcepub fn builder() -> MultiSelectPropsBuilder<((), (), (), (), (), (), (), (), (), (), (), (), (), ())>
pub fn builder() -> MultiSelectPropsBuilder<((), (), (), (), (), (), (), (), (), (), (), (), (), ())>
Create a builder for building MultiSelectProps.
On the builder, call .label(...), .legend(...), .name(...), .options(...), .values(...)(optional), .default_values(...)(optional), .onchange(...)(optional), .filter_label(...)(optional), .filter_placeholder(...)(optional), .open(...)(optional), .summary(...)(optional), .fc_id(...)(optional), .class(...)(optional), .attributes(...)(optional) to set the values of the fields.
Finally, call .build() to create the instance of MultiSelectProps.