aboutsummaryrefslogtreecommitdiff
path: root/src/lib/extensions/discord.js/BushCommandInteraction.ts
blob: 56cdb751f98e418e73ae6017dbb470a1f5f2579d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
import { APIInteractionGuildMember } from 'discord-api-types/v9';
import { CommandInteraction, Invite, Snowflake } from 'discord.js';
import { RawCommandInteractionData } from 'discord.js/typings/rawDataTypes';
import { BushClient, BushTextBasedChannels } from '../discord-akairo/BushClient';
import { BushApplicationCommand } from './BushApplicationCommand';
import { BushGuild } from './BushGuild';
import { BushGuildChannel } from './BushGuildChannel';
import { BushGuildEmoji } from './BushGuildEmoji';
import { BushGuildMember } from './BushGuildMember';
import { BushRole } from './BushRole';
import { BushUser } from './BushUser';

export type BushGuildResolvable =
	| BushGuild
	| BushGuildChannel
	| BushGuildMember
	| BushGuildEmoji
	| Invite
	| BushRole
	| Snowflake;

export class BushCommandInteraction extends CommandInteraction {
	public constructor(client: BushClient, data: RawCommandInteractionData) {
		super(client, data);
	}
	public declare readonly client: BushClient;
	public declare readonly command: BushApplicationCommand | BushApplicationCommand<{ guild: BushGuildResolvable }> | null;
	public declare readonly channel: BushTextBasedChannels | null;
	public declare readonly guild: BushGuild | null;
	public declare member: BushGuildMember | APIInteractionGuildMember | null;
	public declare user: BushUser;
}