This commit is contained in:
DjDeveloperr 2021-04-24 14:33:15 +05:30
parent 9d88c5d113
commit 67d81c1bf0
2 changed files with 10 additions and 3 deletions

View File

@ -3,11 +3,10 @@ import type { SlashCommandHandler } from './slashClient.ts'
export class SlashModule {
name: string = ''
commands: SlashCommandHandler[] = []
_decoratedSlash?: SlashCommandHandler[]
constructor() {
if (this._decoratedSlash !== undefined) {
this.commands = this._decoratedSlash
if ((this as any)._decoratedSlash !== undefined) {
;(this as any).commands = (this as any)._decoratedSlash
}
}

View File

@ -11,6 +11,12 @@ export enum ButtonStyle {
Link = 5
}
export interface MessageComponentEmoji {
id?: string
name?: string
animated?: boolean
}
export interface MessageComponentPayload {
type: MessageComponentType
components?: MessageComponentPayload[]
@ -18,6 +24,7 @@ export interface MessageComponentPayload {
style?: ButtonStyle
url?: string
custom_id?: string
emoji?: MessageComponentEmoji
}
export interface MessageComponentData {
@ -27,6 +34,7 @@ export interface MessageComponentData {
style?: ButtonStyle
url?: string
customID?: string
emoji?: MessageComponentEmoji
}
export interface InteractionMessageComponentData {