mirror of
https://github.com/Rapptz/discord.py.git
synced 2025-10-22 08:23:09 +00:00
Don't recreate ItemCallbackType
This commit is contained in:
@@ -25,12 +25,12 @@ DEALINGS IN THE SOFTWARE.
|
||||
from __future__ import annotations
|
||||
|
||||
import copy
|
||||
from typing import Any, Callable, Coroutine, Literal, Optional, TYPE_CHECKING, Tuple, TypeVar, Union
|
||||
from typing import Callable, Literal, Optional, TYPE_CHECKING, Tuple, TypeVar, Union
|
||||
import inspect
|
||||
import os
|
||||
|
||||
|
||||
from .item import Item, I
|
||||
from .item import Item, ContainedItemCallbackType as ItemCallbackType
|
||||
from ..enums import ButtonStyle, ComponentType
|
||||
from ..partial_emoji import PartialEmoji, _EmojiTag
|
||||
from ..components import Button as ButtonComponent
|
||||
@@ -46,11 +46,8 @@ if TYPE_CHECKING:
|
||||
from .view import BaseView
|
||||
from .action_row import ActionRow
|
||||
from ..emoji import Emoji
|
||||
from ..interactions import Interaction
|
||||
from ..types.components import ButtonComponent as ButtonComponentPayload
|
||||
|
||||
ItemCallbackType = Callable[['S', Interaction[Any], I], Coroutine[Any, Any, Any]]
|
||||
|
||||
S = TypeVar('S', bound='Union[BaseView, ActionRow]', covariant=True)
|
||||
V = TypeVar('V', bound='BaseView', covariant=True)
|
||||
|
||||
|
Reference in New Issue
Block a user