Skip to content

Commit

Permalink
fix: make requested changes
Browse files Browse the repository at this point in the history
  • Loading branch information
suneettipirneni committed Oct 29, 2021
1 parent 29de6db commit 17207f0
Show file tree
Hide file tree
Showing 8 changed files with 58 additions and 80 deletions.
37 changes: 13 additions & 24 deletions deno/payloads/v8/_interactions/_applicationCommands/chatInput.ts
Original file line number Diff line number Diff line change
Expand Up @@ -128,16 +128,6 @@ export interface ApplicationCommandInteractionDataOptionSubCommandGroup {
options: ApplicationCommandInteractionDataOptionSubCommand[];
}

export interface ApplicationCommandInteractionDataOptionAutocomplete {
name: string;
type:
| ApplicationCommandOptionType.String
| ApplicationCommandOptionType.Integer
| ApplicationCommandOptionType.Number;
value?: string | number;
focused?: boolean;
}

export type APIApplicationCommandInteractionDataOptionWithValues =
| ApplicationCommandInteractionDataOptionString
| ApplicationCommandInteractionDataOptionRole
Expand All @@ -146,13 +136,12 @@ export type APIApplicationCommandInteractionDataOptionWithValues =
| ApplicationCommandInteractionDataOptionMentionable
| ApplicationCommandInteractionDataOptionInteger
| ApplicationCommandInteractionDataOptionNumber
| ApplicationCommandInteractionDataOptionBoolean
| ApplicationCommandInteractionDataOptionAutocomplete;
| ApplicationCommandInteractionDataOptionBoolean;

export type ApplicationCommandInteractionDataOptionString = InteractionDataOptionBase<
ApplicationCommandOptionType.String,
string
>;
export interface ApplicationCommandInteractionDataOptionString
extends InteractionDataOptionBase<ApplicationCommandOptionType.String, string> {
focused?: boolean;
}

export type ApplicationCommandInteractionDataOptionRole = InteractionDataOptionBase<
ApplicationCommandOptionType.Role,
Expand All @@ -174,15 +163,15 @@ export type ApplicationCommandInteractionDataOptionMentionable = InteractionData
Snowflake
>;

export type ApplicationCommandInteractionDataOptionInteger = InteractionDataOptionBase<
ApplicationCommandOptionType.Integer,
number
>;
export interface ApplicationCommandInteractionDataOptionInteger
extends InteractionDataOptionBase<ApplicationCommandOptionType.Integer, number> {
focused?: boolean;
}

export type ApplicationCommandInteractionDataOptionNumber = InteractionDataOptionBase<
ApplicationCommandOptionType.Number,
number
>;
export interface ApplicationCommandInteractionDataOptionNumber
extends InteractionDataOptionBase<ApplicationCommandOptionType.Number, number> {
focused?: boolean;
}

export type ApplicationCommandInteractionDataOptionBoolean = InteractionDataOptionBase<
ApplicationCommandOptionType.Boolean,
Expand Down
4 changes: 2 additions & 2 deletions deno/payloads/v8/_interactions/responses.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,13 @@ export type APIInteractionResponse =
| APIInteractionResponseDeferredChannelMessageWithSource
| APIInteractionResponseDeferredMessageUpdate
| APIInteractionResponseUpdateMessage
| APICommandAutocompleteResponse;
| APIApplicationCommandAutocompleteResponse;

export interface APIInteractionResponsePong {
type: InteractionResponseType.Pong;
}

export interface APICommandAutocompleteResponse {
export interface APIApplicationCommandAutocompleteResponse {
type: InteractionResponseType.ApplicationCommandAutocompleteResult;
data: APICommandAutocompleteInteractionResponseCallbackData;
}
Expand Down
24 changes: 12 additions & 12 deletions deno/payloads/v9/_interactions/_applicationCommands/chatInput.ts
Original file line number Diff line number Diff line change
Expand Up @@ -149,10 +149,10 @@ export type APIApplicationCommandInteractionDataOptionWithValues =
| ApplicationCommandInteractionDataOptionBoolean
| ApplicationCommandInteractionDataOptionAutocomplete;

export type ApplicationCommandInteractionDataOptionString = InteractionDataOptionBase<
ApplicationCommandOptionType.String,
string
>;
export interface ApplicationCommandInteractionDataOptionString
extends InteractionDataOptionBase<ApplicationCommandOptionType.String, string> {
focused?: boolean;
}

export type ApplicationCommandInteractionDataOptionRole = InteractionDataOptionBase<
ApplicationCommandOptionType.Role,
Expand All @@ -174,15 +174,15 @@ export type ApplicationCommandInteractionDataOptionMentionable = InteractionData
Snowflake
>;

export type ApplicationCommandInteractionDataOptionInteger = InteractionDataOptionBase<
ApplicationCommandOptionType.Integer,
number
>;
export interface ApplicationCommandInteractionDataOptionInteger
extends InteractionDataOptionBase<ApplicationCommandOptionType.Integer, number> {
focused?: boolean;
}

export type ApplicationCommandInteractionDataOptionNumber = InteractionDataOptionBase<
ApplicationCommandOptionType.Number,
number
>;
export interface ApplicationCommandInteractionDataOptionNumber
extends InteractionDataOptionBase<ApplicationCommandOptionType.Number, number> {
focused?: boolean;
}

export type ApplicationCommandInteractionDataOptionBoolean = InteractionDataOptionBase<
ApplicationCommandOptionType.Boolean,
Expand Down
4 changes: 2 additions & 2 deletions deno/payloads/v9/_interactions/responses.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,13 @@ export type APIInteractionResponse =
| APIInteractionResponseDeferredChannelMessageWithSource
| APIInteractionResponseDeferredMessageUpdate
| APIInteractionResponseUpdateMessage
| APICommandAutocompleteResponse;
| APIApplicationCommandAutocompleteResponse;

export interface APIInteractionResponsePong {
type: InteractionResponseType.Pong;
}

export interface APICommandAutocompleteResponse {
export interface APIApplicationCommandAutocompleteResponse {
type: InteractionResponseType.ApplicationCommandAutocompleteResult;
data: APICommandAutocompleteInteractionResponseCallbackData;
}
Expand Down
37 changes: 13 additions & 24 deletions payloads/v8/_interactions/_applicationCommands/chatInput.ts
Original file line number Diff line number Diff line change
Expand Up @@ -128,16 +128,6 @@ export interface ApplicationCommandInteractionDataOptionSubCommandGroup {
options: ApplicationCommandInteractionDataOptionSubCommand[];
}

export interface ApplicationCommandInteractionDataOptionAutocomplete {
name: string;
type:
| ApplicationCommandOptionType.String
| ApplicationCommandOptionType.Integer
| ApplicationCommandOptionType.Number;
value?: string | number;
focused?: boolean;
}

export type APIApplicationCommandInteractionDataOptionWithValues =
| ApplicationCommandInteractionDataOptionString
| ApplicationCommandInteractionDataOptionRole
Expand All @@ -146,13 +136,12 @@ export type APIApplicationCommandInteractionDataOptionWithValues =
| ApplicationCommandInteractionDataOptionMentionable
| ApplicationCommandInteractionDataOptionInteger
| ApplicationCommandInteractionDataOptionNumber
| ApplicationCommandInteractionDataOptionBoolean
| ApplicationCommandInteractionDataOptionAutocomplete;
| ApplicationCommandInteractionDataOptionBoolean;

export type ApplicationCommandInteractionDataOptionString = InteractionDataOptionBase<
ApplicationCommandOptionType.String,
string
>;
export interface ApplicationCommandInteractionDataOptionString
extends InteractionDataOptionBase<ApplicationCommandOptionType.String, string> {
focused?: boolean;
}

export type ApplicationCommandInteractionDataOptionRole = InteractionDataOptionBase<
ApplicationCommandOptionType.Role,
Expand All @@ -174,15 +163,15 @@ export type ApplicationCommandInteractionDataOptionMentionable = InteractionData
Snowflake
>;

export type ApplicationCommandInteractionDataOptionInteger = InteractionDataOptionBase<
ApplicationCommandOptionType.Integer,
number
>;
export interface ApplicationCommandInteractionDataOptionInteger
extends InteractionDataOptionBase<ApplicationCommandOptionType.Integer, number> {
focused?: boolean;
}

export type ApplicationCommandInteractionDataOptionNumber = InteractionDataOptionBase<
ApplicationCommandOptionType.Number,
number
>;
export interface ApplicationCommandInteractionDataOptionNumber
extends InteractionDataOptionBase<ApplicationCommandOptionType.Number, number> {
focused?: boolean;
}

export type ApplicationCommandInteractionDataOptionBoolean = InteractionDataOptionBase<
ApplicationCommandOptionType.Boolean,
Expand Down
4 changes: 2 additions & 2 deletions payloads/v8/_interactions/responses.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,13 @@ export type APIInteractionResponse =
| APIInteractionResponseDeferredChannelMessageWithSource
| APIInteractionResponseDeferredMessageUpdate
| APIInteractionResponseUpdateMessage
| APICommandAutocompleteResponse;
| APIApplicationCommandAutocompleteResponse;

export interface APIInteractionResponsePong {
type: InteractionResponseType.Pong;
}

export interface APICommandAutocompleteResponse {
export interface APIApplicationCommandAutocompleteResponse {
type: InteractionResponseType.ApplicationCommandAutocompleteResult;
data: APICommandAutocompleteInteractionResponseCallbackData;
}
Expand Down
24 changes: 12 additions & 12 deletions payloads/v9/_interactions/_applicationCommands/chatInput.ts
Original file line number Diff line number Diff line change
Expand Up @@ -149,10 +149,10 @@ export type APIApplicationCommandInteractionDataOptionWithValues =
| ApplicationCommandInteractionDataOptionBoolean
| ApplicationCommandInteractionDataOptionAutocomplete;

export type ApplicationCommandInteractionDataOptionString = InteractionDataOptionBase<
ApplicationCommandOptionType.String,
string
>;
export interface ApplicationCommandInteractionDataOptionString
extends InteractionDataOptionBase<ApplicationCommandOptionType.String, string> {
focused?: boolean;
}

export type ApplicationCommandInteractionDataOptionRole = InteractionDataOptionBase<
ApplicationCommandOptionType.Role,
Expand All @@ -174,15 +174,15 @@ export type ApplicationCommandInteractionDataOptionMentionable = InteractionData
Snowflake
>;

export type ApplicationCommandInteractionDataOptionInteger = InteractionDataOptionBase<
ApplicationCommandOptionType.Integer,
number
>;
export interface ApplicationCommandInteractionDataOptionInteger
extends InteractionDataOptionBase<ApplicationCommandOptionType.Integer, number> {
focused?: boolean;
}

export type ApplicationCommandInteractionDataOptionNumber = InteractionDataOptionBase<
ApplicationCommandOptionType.Number,
number
>;
export interface ApplicationCommandInteractionDataOptionNumber
extends InteractionDataOptionBase<ApplicationCommandOptionType.Number, number> {
focused?: boolean;
}

export type ApplicationCommandInteractionDataOptionBoolean = InteractionDataOptionBase<
ApplicationCommandOptionType.Boolean,
Expand Down
4 changes: 2 additions & 2 deletions payloads/v9/_interactions/responses.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,13 @@ export type APIInteractionResponse =
| APIInteractionResponseDeferredChannelMessageWithSource
| APIInteractionResponseDeferredMessageUpdate
| APIInteractionResponseUpdateMessage
| APICommandAutocompleteResponse;
| APIApplicationCommandAutocompleteResponse;

export interface APIInteractionResponsePong {
type: InteractionResponseType.Pong;
}

export interface APICommandAutocompleteResponse {
export interface APIApplicationCommandAutocompleteResponse {
type: InteractionResponseType.ApplicationCommandAutocompleteResult;
data: APICommandAutocompleteInteractionResponseCallbackData;
}
Expand Down

0 comments on commit 17207f0

Please sign in to comment.