Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

types(ApplicationCommandOption): add ApplicationCommandBooleanOption #8434

Merged
merged 2 commits into from
Aug 10, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
11 changes: 11 additions & 0 deletions packages/discord.js/typings/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3833,6 +3833,10 @@ export interface ApplicationCommandStringOptionData extends ApplicationCommandCh
max_length?: number;
}

export interface ApplicationCommandBooleanOptionData extends BaseApplicationCommandOptionsData {
type: ApplicationCommandOptionType.Boolean;
}

export interface ApplicationCommandNumericOption extends ApplicationCommandChoicesOption {
type: CommandOptionNumericResolvableType;
minValue?: number;
Expand All @@ -3845,6 +3849,10 @@ export interface ApplicationCommandStringOption extends ApplicationCommandChoice
maxLength?: number;
}

export interface ApplicationCommandBooleanOption extends BaseApplicationCommandOptionsData {
type: ApplicationCommandOptionType.Boolean;
}

export interface ApplicationCommandSubGroupData extends Omit<BaseApplicationCommandOptionsData, 'required'> {
type: ApplicationCommandOptionType.SubcommandGroup;
options?: ApplicationCommandSubCommandData[];
Expand All @@ -3864,6 +3872,7 @@ export interface ApplicationCommandSubCommandData extends Omit<BaseApplicationCo
| ApplicationCommandAutocompleteOption
| ApplicationCommandNumericOptionData
| ApplicationCommandStringOptionData
| ApplicationCommandBooleanOption
)[];
}

Expand All @@ -3888,6 +3897,7 @@ export type ApplicationCommandOptionData =
| ApplicationCommandAutocompleteOption
| ApplicationCommandNumericOptionData
| ApplicationCommandStringOptionData
| ApplicationCommandBooleanOptionData
| ApplicationCommandSubCommandData;

export type ApplicationCommandOption =
Expand All @@ -3897,6 +3907,7 @@ export type ApplicationCommandOption =
| ApplicationCommandChoicesOption
| ApplicationCommandNumericOption
| ApplicationCommandStringOption
| ApplicationCommandBooleanOption
| ApplicationCommandAttachmentOption
| ApplicationCommandSubCommand;

Expand Down