thaw/demo_markdown/docs/combobox/mod.md
2024-07-25 15:10:49 +08:00

38 lines
735 B
Markdown

# Combobox
```rust demo
let selected_options = RwSignal::new(None::<String>);
view! {
<Combobox selected_options>
<ComboboxOption value="cat" text="Car" />
<ComboboxOption value="dog" text="Dog" />
</Combobox>
}
```
### Clearable
```rust demo
let selected_options = RwSignal::new(vec![]);
view! {
<Combobox selected_options clearable=true>
<ComboboxOption value="cat" text="Car" />
<ComboboxOption value="dog" text="Dog" />
</Combobox>
}
```
### Multiselect
```rust demo
let selected_options = RwSignal::new(vec![]);
view! {
<Combobox selected_options>
<ComboboxOption value="cat" text="Car" />
<ComboboxOption value="dog" text="Dog" />
</Combobox>
}
```