rewrite: Refactor ui utils, add pagers.

This commit is contained in:
2022-11-30 16:57:26 +02:00
parent dd8609fac0
commit 5bd05a84a9
9 changed files with 1282 additions and 526 deletions

20
bot/utils/ui/__init__.py Normal file
View File

@@ -0,0 +1,20 @@
import asyncio
import logging
from .. import util_babel
logger = logging.getLogger(__name__)
from .hooked import *
from .leo import *
from .micros import *
from .pagers import *
from .transformed import *
# def create_task_in(coro, context: Context):
# """
# Transitional.
# Since py3.10 asyncio does not support context instantiation,
# this helper method runs `asyncio.create_task(coro)` inside the given context.
# """
# return context.run(asyncio.create_task, coro)