|
|
@ -37,6 +37,7 @@ from typing import ( |
|
|
|
TYPE_CHECKING, |
|
|
|
Sequence, |
|
|
|
Tuple, |
|
|
|
TypeVar, |
|
|
|
Union, |
|
|
|
overload, |
|
|
|
) |
|
|
@ -74,6 +75,7 @@ if TYPE_CHECKING: |
|
|
|
from .types.threads import ThreadArchiveDuration |
|
|
|
from .client import Client |
|
|
|
from .role import Role |
|
|
|
from .object import Object |
|
|
|
from .member import Member, VoiceState |
|
|
|
from .abc import Snowflake, SnowflakeTime, T as ConnectReturn |
|
|
|
from .message import Message, PartialMessage |
|
|
@ -98,6 +100,8 @@ if TYPE_CHECKING: |
|
|
|
|
|
|
|
from .types.snowflake import SnowflakeList |
|
|
|
|
|
|
|
OverwriteKeyT = TypeVar('OverwriteKeyT', Role, BaseUser, Object, Union[Role, Member, Object]) |
|
|
|
|
|
|
|
|
|
|
|
class ThreadWithMessage(NamedTuple): |
|
|
|
thread: Thread |
|
|
@ -289,7 +293,7 @@ class TextChannel(discord.abc.Messageable, discord.abc.GuildChannel, Hashable): |
|
|
|
slowmode_delay: int = ..., |
|
|
|
default_auto_archive_duration: ThreadArchiveDuration = ..., |
|
|
|
type: ChannelType = ..., |
|
|
|
overwrites: Mapping[Union[Role, Member, Snowflake], PermissionOverwrite] = ..., |
|
|
|
overwrites: Mapping[OverwriteKeyT, PermissionOverwrite] = ..., |
|
|
|
) -> TextChannel: |
|
|
|
... |
|
|
|
|
|
|
@ -1274,7 +1278,7 @@ class VoiceChannel(discord.abc.Messageable, VocalGuildChannel): |
|
|
|
position: int = ..., |
|
|
|
sync_permissions: int = ..., |
|
|
|
category: Optional[CategoryChannel] = ..., |
|
|
|
overwrites: Mapping[Union[Role, Member], PermissionOverwrite] = ..., |
|
|
|
overwrites: Mapping[OverwriteKeyT, PermissionOverwrite] = ..., |
|
|
|
rtc_region: Optional[str] = ..., |
|
|
|
video_quality_mode: VideoQualityMode = ..., |
|
|
|
reason: Optional[str] = ..., |
|
|
@ -1570,7 +1574,7 @@ class StageChannel(VocalGuildChannel): |
|
|
|
position: int = ..., |
|
|
|
sync_permissions: int = ..., |
|
|
|
category: Optional[CategoryChannel] = ..., |
|
|
|
overwrites: Mapping[Union[Role, Member], PermissionOverwrite] = ..., |
|
|
|
overwrites: Mapping[OverwriteKeyT, PermissionOverwrite] = ..., |
|
|
|
rtc_region: Optional[str] = ..., |
|
|
|
video_quality_mode: VideoQualityMode = ..., |
|
|
|
reason: Optional[str] = ..., |
|
|
@ -1739,7 +1743,7 @@ class CategoryChannel(discord.abc.GuildChannel, Hashable): |
|
|
|
name: str = ..., |
|
|
|
position: int = ..., |
|
|
|
nsfw: bool = ..., |
|
|
|
overwrites: Mapping[Union[Role, Member], PermissionOverwrite] = ..., |
|
|
|
overwrites: Mapping[OverwriteKeyT, PermissionOverwrite] = ..., |
|
|
|
reason: Optional[str] = ..., |
|
|
|
) -> CategoryChannel: |
|
|
|
... |
|
|
@ -2047,7 +2051,7 @@ class ForumChannel(discord.abc.GuildChannel, Hashable): |
|
|
|
slowmode_delay: int = ..., |
|
|
|
default_auto_archive_duration: ThreadArchiveDuration = ..., |
|
|
|
type: ChannelType = ..., |
|
|
|
overwrites: Mapping[Union[Role, Member, Snowflake], PermissionOverwrite] = ..., |
|
|
|
overwrites: Mapping[OverwriteKeyT, PermissionOverwrite] = ..., |
|
|
|
) -> ForumChannel: |
|
|
|
... |
|
|
|
|
|
|
|