Struct twilight_model::channel::message::component::SelectMenu
source · pub struct SelectMenu {
pub custom_id: String,
pub disabled: bool,
pub max_values: Option<u8>,
pub min_values: Option<u8>,
pub options: Vec<SelectMenuOption>,
pub placeholder: Option<String>,
}
Expand description
Dropdown-style Component
that renders belew messages.
Fields§
§custom_id: String
Developer defined identifier.
disabled: bool
Whether the select menu is disabled.
Defaults to false
.
max_values: Option<u8>
Maximum number of options that may be chosen.
min_values: Option<u8>
Minimum number of options that must be chosen.
options: Vec<SelectMenuOption>
List of available choices.
placeholder: Option<String>
Custom placeholder text if no option is selected.
Trait Implementations§
source§impl Clone for SelectMenu
impl Clone for SelectMenu
source§fn clone(&self) -> SelectMenu
fn clone(&self) -> SelectMenu
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for SelectMenu
impl Debug for SelectMenu
source§impl From<SelectMenu> for Component
impl From<SelectMenu> for Component
source§fn from(select_menu: SelectMenu) -> Self
fn from(select_menu: SelectMenu) -> Self
Converts to this type from the input type.
source§impl Hash for SelectMenu
impl Hash for SelectMenu
source§impl PartialEq<SelectMenu> for SelectMenu
impl PartialEq<SelectMenu> for SelectMenu
source§fn eq(&self, other: &SelectMenu) -> bool
fn eq(&self, other: &SelectMenu) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.