Python inline keyboard pagination for Telegram Bot API.
Project description
ptb-pagination
Python inline keyboard pagination for Telegram Bot API.
Provide an easy way to create number pagination with Telegram Inline Keyboards for python-telegram-bot.
This project is very based on python-telegram-bot-pagination, thanks ksinn.
The main difference it's supposed to only work with the python-telegram-bot library and provide full support to Arbitrary callback_data.
Installation
pip install ptb-pagination
Usage
from ptb_pagination import InlineKeyboardPaginator
paginator = InlineKeyboardPaginator(
page_count,
current_page=page,
data_pattern='page#{page}'
)
bot.send_message(
chat_id,
text,
reply_markup=paginator.markup,
)
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
ptb-pagination-0.0.2.tar.gz
(3.5 kB
view hashes)
Built Distribution
Close
Hashes for ptb_pagination-0.0.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1a0c20ddcdbc84800a36af471aba5a6fcf4526bc58c65c1b300a88d40824d35c |
|
MD5 | a4365a7cb415142e43df8edb4602a1c2 |
|
BLAKE2b-256 | d996d5295428191231e91820adf840eaee775fc6e91ee1b328f677ef72276721 |