Skip to main content

discord.py-pagination

discord.py-pagination is a Python library to easily create embed paginators.

WARNING IMAGE NOT FOUND

Installation

Use the package manager pip to install the library.

pip install discord.py-pagination

Usage

Quickstart

import Paginator

# Create a list of embeds to paginate.
embeds = [discord.Embed(title="First embed"),
          discord.Embed(title="Second embed"),
          discord.Embed(title="Third embed")]

... # Inside a command.
await Paginator.Simple().start(ctx, pages=embeds)

Advanced

To use custom buttons, pass in the corresponding argument when you initiate the paginator.
# These arguments override the default ones.

PreviousButton = discord.ui.Button(...)
NextButton = discord.ui.Button(...)
PageCounterStyle = discord.ButtonStyle(...) # Only accepts ButtonStyle instead of Button
InitialPage = 0 # Page to start the paginator on.
timeout = 42069 # Seconds to timeout. Default is 60

await Paginator.Simple(
    PreviousButton=PreviousButton,
    NextButton=NextButton,
    PageCounterStyle=PageCounterStyle,
    InitialPage=InitialPage,
    timeout=timeout).start(ctx, pages=embeds)

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

License

MIT

Metadata

Release files for discord.py-pagination 0.0.5

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for discord.py-pagination 0.0.5
File Size Uploaded
discord.py-pagination-0.0.5.tar.gz 3.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for discord.py-pagination 0.0.5
File Interpreter ABI Platform
discord.py_pagination-0.0.5-py3-none-any.whl Python 3 none any Details

Total release size: 8.0 kB

Release files / discord.py-pagination-0.0.5.tar.gz

Download URL discord.py-pagination-0.0.5.tar.gz
Size 3.8 kB
Tags Source
SHA-256 checksum
How to use checksums
94db6f36f9663d37b8bd721aa98984c4207b0cf49211cdea2751300bfd2ad252
BLAKE2b-256 checksum
How to use checksums
187c57786561631da3ae9d1a7b84abacba198e47010b14d89ca029b0b12fb27d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.12

Release files / discord.py_pagination-0.0.5-py3-none-any.whl

Download URL discord.py_pagination-0.0.5-py3-none-any.whl
Size 4.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
da28b8ecb0827eb991da701e0223f2cd9e0c12de0c0a0913f621430289b4bd1b
BLAKE2b-256 checksum
How to use checksums
e21fb71bd07c1ba9d2d714d80640fe93eae530441038c8670f6cb1a917dc9bb9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.12

Release history Release notifications | RSS feed

This release

0.0.5 This release

2 release files

0.0.4

1 release file

0.0.3

3 release files

0.0.2

3 release files

0.0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page