import type { BushClient, BushCommandUtil, BushGuild, BushGuildMember, BushGuildTextBasedChannel, BushMessageReaction, BushTextBasedChannel, BushThreadChannel, BushUser } from '#lib'; import { Message, MessageActionRowComponent, type EmojiIdentifierResolvable, type If, type MessageEditOptions, type MessagePayload, type Partialize, type ReplyMessageOptions, type StartThreadOptions } from 'discord.js'; import type { RawMessageData } from 'discord.js/typings/rawDataTypes'; export type PartialBushMessage = Partialize< BushMessage, 'type' | 'system' | 'pinned' | 'tts', 'content' | 'cleanContent' | 'author' >; /** * Represents a message on Discord. */ export class BushMessage extends Message { public declare readonly client: BushClient; public declare util: BushCommandUtil>; public declare author: BushUser; public constructor(client: BushClient, data: RawMessageData) { super(client, data); } } export interface BushMessage extends Message { get guild(): If; get member(): BushGuildMember | null; get channel(): If; delete(): Promise; edit(content: string | MessageEditOptions | MessagePayload): Promise; equals(message: BushMessage, rawData: unknown): boolean; fetchReference(): Promise; crosspost(): Promise; fetch(force?: boolean): Promise; pin(): Promise; react(emoji: EmojiIdentifierResolvable): Promise; removeAttachments(): Promise; reply(options: string | MessagePayload | ReplyMessageOptions): Promise; resolveComponent(customId: string): MessageActionRowComponent | null; startThread(options: StartThreadOptions): Promise; suppressEmbeds(suppress?: boolean): Promise; unpin(): Promise; inGuild(): this is BushMessage & this; }