#Add buttons to Paginator.

1 messages · Page 1 of 1 (latest)

next bear
#

Sup guiys, i've managed to create paginators with as much pages i wanted but now i'm having trouble on adding buttons/select menus to interact with the current page.
Tried to look in the docs to see if i could find a solution but i might have missed something.

Would you guys have any advice?
Thx

inner wyvernBOT
#

Hey! Once your issue is solved, press the button below to close this thread!

feral bolt
#

Subclass the paginator and override it's component method

next bear
#

and thx for the hand 🙂

tame shale
#

If i may ask (if im not being annoying), whats a paginator in programming? Google isnt being very helpful xD

inner wyvernBOT
#
Tag List

This is the list of currently existing tags.

Names

1 Installing Unstable
2 403 Authentication error
3 Documentation website
4 Global vs. Guild
5 Positional arguments from command function
6 Formatting timestamp
7 Sending Python code in Discord
8 Upload images directly into embeds
9 Install git

rustic tiger
#

^this is a paginator

tame shale
#

A list?

rustic tiger
#

no, it's a feature used when you want to show a list of certain things but it's too large. Therefore you divide it into multiple embeds and you can navigate through them using menu/buttons

tame shale
#

Ohh

#

The name makes sense now

#

Thanks blobheart

next bear
#

Does the "This paginator does not belongs to you" is a Discord native thing or it's a I.py thing?

rustic tiger
#

i.py. Anyone can press buttons, but for paginators it has been decided to do it "private" (i.e only the author can switch through pages)

#

idk if i.py supports removing this, maybe it is

next bear
#

That's actually a cool feat tho

next bear
#

I'm still stuck on this. I don't know where to start tbh

odd wren
next bear
#

As i said, managed to create the pagination

#

but i'm stuck on the button part :x

rustic tiger
#

as Polls said, for that you will want to subclass the paginator class. We'll let you lookup what does that mean in Python, but basically you will need to rewrite some functionality of the paginator for that

next bear
rustic tiger
#
class CustomPaginator(i.Paginator):
...```
this is subclassing