@@ -53,7 +53,7 @@ export class BaseInteraction {
5353 id ?: string ;
5454 perms ?: { bot : PermissionString [ ] , user : UserPermString [ ] } ;
5555 onInteraction ( interaction : CommandInteraction | ContextMenuInteraction , other : IOther ) : void ;
56- toJSON ( ) : MessageButton | MessageSelectMenu | undefined ;
56+ toJSON ( data : Array < string | number > ) : MessageButton | MessageSelectMenu | undefined ;
5757 publishType ?: "globalOnly" | "guildOnly" | "all" | string ;
5858 onLoad ?( client : Client ) : void ;
5959 coolDowns : Map < string , number > ;
@@ -66,7 +66,7 @@ export class BaseInteraction {
6666 defaultPermission ?: boolean ;
6767 actionType ?: ApplicationCommandType | "SELECT_MENU" | "BUTTON" ;
6868 autoDefer ?: "off" | "on" | "ephemeral" ;
69- nullError ?: undefined ;
69+ nullError ?: boolean ;
7070 calculated ?: { [ key : string | number ] : any } ;
7171 isSelectMenu ( ) : this is import ( "./SelectMenu" ) ;
7272 isButton ( ) : this is import ( "./Button" ) ;
@@ -76,12 +76,13 @@ export class BaseInteraction {
7676 constructor ( arg : TInteractionConstructor ) ;
7777}
7878
79- export type TOmittedInteraction = Omit < BaseInteraction , "_type" | "coolDowns" | "name" | "onInteraction" | "actionType" | "options" | "toJSON" | "calculated" | "nullError" > ;
79+ export type TOmittedInteraction = Omit < BaseInteraction , "_type" | "coolDowns" | "name" | "onInteraction" | "actionType" | "options" | "toJSON" | "calculated" > ;
8080export type TInteractionConstructor = TOmittedInteraction & ( ( ActionChatCommand | ActionRightClickCommand | SelectMenu | Button ) ) ;
8181type cooldownType = "user" | "member" | "channel" | "guild" | "message" | "any" ;
8282export interface IOther {
8383 setCoolDown ( durations : number , type : cooldownType ) : void ,
84- locale : import ( "./Locale" ) . Data
84+ locale : import ( "./Locale" ) . Data ,
85+ data : ( string | number ) [ ] ,
8586 [ key : string | number ] : any
8687}
8788
@@ -106,7 +107,7 @@ export interface SelectMenu {
106107 actionType : "SELECT_MENU" ;
107108 onInteraction ( interaction : SelectMenuInteraction , other : IOther ) : void ;
108109 options ?: CustomSelectMenuOptions ;
109- toJSON ( ) : MessageSelectMenu ;
110+ toJSON ( data : Array < string | number > ) : MessageSelectMenu ;
110111 nullError ?: Boolean ;
111112}
112113
@@ -115,7 +116,7 @@ export interface Button {
115116 actionType : "BUTTON" ;
116117 onInteraction ( interaction : ButtonInteraction , other : IOther ) : void ;
117118 options ?: CustomButtonOptions ;
118- toJSON ( ) : MessageButton ;
119+ toJSON ( data : Array < string | number > ) : MessageButton ;
119120 nullError ?: Boolean ;
120121}
121122
0 commit comments