forums¶
Forum views
Discord UI views used in forums.
- class byte_bot.byte.views.forums.HelpThreadView(author: Member, bot: Bot, *args: list, **kwargs: dict)[source]¶
Bases:
View
View for the help thread.
Initialize the view.
- async interaction_check(interaction: Interaction) bool [source]¶
Check if the user is the author or an admin.
- Parameters:
interaction (Interaction) – Interaction object.
- Returns:
True if the user is the author or an admin, False otherwise.
- Return type:
- async solve_button_callback(interaction: Interaction, button: Button) None [source]¶
Mark the thread as solved.
- Parameters:
interaction – Interaction object.
button – Button object.
- async remove_button_callback(interaction: Interaction, button: Button) None [source]¶
Remove the view and embed.
- Parameters:
interaction – Interaction object.
button – Button object.