Improve Telegram forum onboarding and topic safety
This commit is contained in:
parent
2b56b98697
commit
a1b7a14138
13 changed files with 1101 additions and 376 deletions
22
adapter/telegram/keyboards/forum.py
Normal file
22
adapter/telegram/keyboards/forum.py
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
from __future__ import annotations
|
||||
|
||||
from aiogram.types import KeyboardButton, KeyboardButtonRequestChat, ReplyKeyboardMarkup
|
||||
|
||||
|
||||
def forum_group_request_keyboard() -> ReplyKeyboardMarkup:
|
||||
return ReplyKeyboardMarkup(
|
||||
keyboard=[[
|
||||
KeyboardButton(
|
||||
text="Выбрать forum-группу",
|
||||
request_chat=KeyboardButtonRequestChat(
|
||||
request_id=1,
|
||||
chat_is_channel=False,
|
||||
chat_is_forum=True,
|
||||
bot_is_member=True,
|
||||
request_title=True,
|
||||
),
|
||||
)
|
||||
]],
|
||||
resize_keyboard=True,
|
||||
one_time_keyboard=True,
|
||||
)
|
||||
Loading…
Add table
Add a link
Reference in a new issue