Select API Reference#
- class flare.components.select.ChannelSelect(*args, **kwargs)[source]#
Bases:
_AbstractSelect
Class for a channel select menu message component.
- Parameters:
channel_types – The channel types that will appear in this select menu.
min_vales – The minimum amount of values a user must select.
max_values – The maximum amount of values a user must select.
placeholder – Placeholder text when no option is selected.
disabled – Whether the button is disabled.
cookie – An identifier to use for the select menu. A custom cookie can be supplied so a shorter one is used in serializing and deserializing.
- build(action_row: MessageActionRowBuilder) None [source]#
Build the select menu into the passed in action row.
- class flare.components.select.MentionableSelect(*args, **kwargs)[source]#
Bases:
BaseSelect
Class for a mentionable select menu message component.
- Parameters:
min_vales – The minimum amount of values a user must select.
max_values – The maximum amount of values a user must select.
placeholder – Placeholder text when no option is selected.
disabled – Whether the button is disabled.
cookie – An identifier to use for the select menu. A custom cookie can be supplied so a shorter one is used in serializing and deserializing.
- class flare.components.select.RoleSelect(*args, **kwargs)[source]#
Bases:
BaseSelect
Class for a role select menu message component.
- Parameters:
min_vales – The minimum amount of values a user must select.
max_values – The maximum amount of values a user must select.
placeholder – Placeholder text when no option is selected.
disabled – Whether the button is disabled.
cookie – An identifier to use for the select menu. A custom cookie can be supplied so a shorter one is used in serializing and deserializing.
- class flare.components.select.TextSelect(*args, **kwargs)[source]#
Bases:
_AbstractSelect
Class for a select menu message component.
- Parameters:
options – An array of options for the select menu. This must be provided when the class is created or using Select.set_options.
min_vales – The minimum amount of values a user must select.
max_values – The maximum amount of values a user must select.
placeholder – Placeholder text when no option is selected.
disabled – Whether the button is disabled.
cookie – An identifier to use for the select menu. A custom cookie can be supplied so a shorter one is used in serializing and deserializing.
- build(action_row: MessageActionRowBuilder) None [source]#
Build the select menu into the passed in action row.
- class flare.components.select.UserSelect(*args, **kwargs)[source]#
Bases:
BaseSelect
Class for a user select menu message component.
- Parameters:
min_vales – The minimum amount of values a user must select.
max_values – The maximum amount of values a user must select.
placeholder – Placeholder text when no option is selected.
disabled – Whether the button is disabled.
cookie – An identifier to use for the select menu. A custom cookie can be supplied so a shorter one is used in serializing and deserializing.
- class flare.components.select.channel_select(*, cookie: str | None = None, channel_types: Sequence[ChannelType] | None = None, min_values: int | None = None, max_values: int | None = None, placeholder: str | UndefinedType = UNDEFINED, disabled: bool | None = None)[source]#
Bases:
_AbstractSelectFunction
[ChannelSelect
]- property component_type: type[ChannelSelect]#
The component type.
- class flare.components.select.mentionable_select(*, cookie: str | None = None, min_values: int | None = None, max_values: int | None = None, placeholder: str | UndefinedType = UNDEFINED, disabled: bool | None = None)[source]#
Bases:
_AbstractSelectFunction
[MentionableSelect
]- property component_type: type[MentionableSelect]#
The component type.
- class flare.components.select.role_select(*, cookie: str | None = None, min_values: int | None = None, max_values: int | None = None, placeholder: str | UndefinedType = UNDEFINED, disabled: bool | None = None)[source]#
Bases:
_AbstractSelectFunction
[RoleSelect
]- property component_type: type[RoleSelect]#
The component type.
- class flare.components.select.text_select(*, cookie: str | None = None, options: Sequence[tuple[str, str] | str | SelectMenuOption] | None = None, min_values: int | None = None, max_values: int | None = None, placeholder: str | UndefinedType = UNDEFINED, disabled: bool | None = None)[source]#
Bases:
_AbstractSelectFunction
[TextSelect
]- property component_type: type[TextSelect]#
The component type.
- class flare.components.select.user_select(*, cookie: str | None = None, min_values: int | None = None, max_values: int | None = None, placeholder: str | UndefinedType = UNDEFINED, disabled: bool | None = None)[source]#
Bases:
_AbstractSelectFunction
[UserSelect
]- property component_type: type[UserSelect]#
The component type.