A button & interactions pagination template for discord bots coded in discord.py
Project description
discord.py-paginator
Buttons pagination template for discord bots.
Useage
Download this folder and place it in your project directory. (or clone it with the following command)
git clone https://github.com/Marseel-E/discord.py-paginator
Example
import discord
from paginator import Paginator
@discord.app_commands.command()
async def command_name(interaction: discord.Interaction):
data = {...}
pages = []
page_content = ""
for i, (key, value) in enumerate(data.items()):
if (i > 0) and (i + 1 % 5 == 0):
pages.append(page_content)
page_content += f"{i+1}. {key.capitalize()} `{value}`\n")
await Paginator(interaction, pages).start()
Preview
:scroll: LICENSE
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for discord.py-paginator-0.0.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4910ba5ef1d480f1023989cdbb29c740c8f15f4ddc380322e97d3affca0d1f97 |
|
MD5 | f6350a751c4de8f2cc74cf312ddcb9a8 |
|
BLAKE2b-256 | de7fb69ac6e5f25531fe6f6e996dcc152df22f51f3ac04c51b9afc0963b78586 |
Close
Hashes for discord.py_paginator-0.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8b2769f761e1fa3e7b776e9d738c35ba0133cf2db7d7406840939e818980e293 |
|
MD5 | 2049c48f5f6dd1b02e317cc2b8f65f31 |
|
BLAKE2b-256 | 313eb6dbc7901b17502befd36c513b05f88851dbc24f5029d728a06718ad1f1f |