button
fun button(label: String?, emoji: DiscordEmoji?, style: ButtonStyle = ButtonStyle.Secondary, disabled: Boolean = false, bypassDefer: Boolean = false, action: suspend Menu.() -> Unit)
A Discord button component. Exposes the menu for navigation functions.
Parameters
label
The Button text
emoji
The Button emoji
style
The Button style
disabled
Whether this button is disabled
bypass Defer
If true, do not defer interaction
action
Lambda to be executed when button is pressed