Skip to content

feat: Menu Pagination #49

@onerandomusername

Description

@onerandomusername

What is this feature?

We'd like to make a custom paginator for paginating menus, and it should use discord's new button interactions.
As we're on the master branch of discord.py, there is button support, and the docs from discord themselves may be of use as well.

Describe how you'd like this to be implemented

  • There should be 5 buttons. Jump to first, back, forward, jump to last, and stop.
  • If there is only one page to paginate, all buttons except the stop button should be disabled.
  • If there are two pages, then the jump to first and jump to last buttons should be disabled.
  • The paginator should be self cleaning, making sure that buttons are removed after a default time.
  • This should handle all interactions, and not let any fail, by default.
    • If a user does not have permission to use these pagination buttons, an ephermal message should be sent, rather than letting the interaction fail.
    • There may be cases where it would make more sense to let the interaction fail, so this behavior should have an override.
  • If the paginator times out or is stopped, the message should be edited to remove the buttons.
  • If an interaction is received that the bot can't handle anymore, the message should be edited to remove the buttons, in order to make sure that the bot won't be spammed by interactions on messages that can't be used anymore.

Metadata

Metadata

Labels

p: normalNormal Prioritys: approvedThe issue has received a maintainer's approvalt: featureRelating to the functionality of the application.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions