Class MentionableMenuProperties
public class MentionableMenuProperties : EntityMenuProperties
- Inheritance
-
MentionableMenuProperties
- Inherited Members
Constructors
MentionableMenuProperties(string)
public MentionableMenuProperties(string customId)
Parameters
customId
string
Properties
ComponentType
Type of the component.
public override ComponentType ComponentType { get; }
Property Value
DefaultValues
Default values for auto-populated select menu components.
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
[JsonPropertyName("default_values")]
public IEnumerable<MentionableValueProperties>? DefaultValues { get; set; }
Property Value
Methods
AddDefaultValues(params MentionableValueProperties[])
Default values for auto-populated select menu components.
public MentionableMenuProperties AddDefaultValues(params MentionableValueProperties[] defaultValues)
Parameters
defaultValues
MentionableValueProperties[]
Returns
AddDefaultValues(IEnumerable<MentionableValueProperties>)
Default values for auto-populated select menu components.
public MentionableMenuProperties AddDefaultValues(IEnumerable<MentionableValueProperties> defaultValues)
Parameters
defaultValues
IEnumerable<MentionableValueProperties>
Returns
WithCustomId(string)
ID for the menu (max 100 characters).
public MentionableMenuProperties WithCustomId(string customId)
Parameters
customId
string
Returns
WithDefaultValues(IEnumerable<MentionableValueProperties>?)
Default values for auto-populated select menu components.
public MentionableMenuProperties WithDefaultValues(IEnumerable<MentionableValueProperties>? defaultValues)
Parameters
defaultValues
IEnumerable<MentionableValueProperties>
Returns
WithDisabled(bool)
Whether the menu is disabled.
public MentionableMenuProperties WithDisabled(bool disabled = true)
Parameters
disabled
bool
Returns
WithMaxValues(int?)
Maximum number of items that can be chosen, default 1 (max 25).
public MentionableMenuProperties WithMaxValues(int? maxValues)
Parameters
maxValues
int?
Returns
WithMinValues(int?)
Minimum number of items that must be chosen, default 1 (0-25).
public MentionableMenuProperties WithMinValues(int? minValues)
Parameters
minValues
int?
Returns
WithPlaceholder(string?)
Placeholder text if nothing is selected (max 150 characters).
public MentionableMenuProperties WithPlaceholder(string? placeholder)
Parameters
placeholder
string