types: Add defaultValues to respective select menu components data (#10265)

* Update index.d.ts

Added 'defaultValues' typings for ChannelSelectMenuComponentData, RoleSelectMenuComponentData, and UserSelectMenuComponentData.

* Update index.d.ts

Adding 'defaultValues' typing to MentionableSelectMenuComponentData

* style: prettier

---------

Co-authored-by: Jiralite <33201955+Jiralite@users.noreply.github.com>
This commit is contained in:
Frank 2024-05-13 14:29:16 +01:00 committed by GitHub
parent 616208ba77
commit c2432d5704
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -178,6 +178,8 @@ import {
APIPoll,
PollLayoutType,
APIPollAnswer,
APISelectMenuDefaultValue,
SelectMenuDefaultValueType,
} from 'discord-api-types/v10';
import { ChildProcess } from 'node:child_process';
import { EventEmitter } from 'node:events';
@ -6367,19 +6369,25 @@ export interface StringSelectMenuComponentData extends BaseSelectMenuComponentDa
export interface UserSelectMenuComponentData extends BaseSelectMenuComponentData {
type: ComponentType.UserSelect;
defaultValues?: readonly APISelectMenuDefaultValue<SelectMenuDefaultValueType.User>[];
}
export interface RoleSelectMenuComponentData extends BaseSelectMenuComponentData {
type: ComponentType.RoleSelect;
defaultValues?: readonly APISelectMenuDefaultValue<SelectMenuDefaultValueType.Role>[];
}
export interface MentionableSelectMenuComponentData extends BaseSelectMenuComponentData {
type: ComponentType.MentionableSelect;
defaultValues?: readonly APISelectMenuDefaultValue<
SelectMenuDefaultValueType.Role | SelectMenuDefaultValueType.User
>[];
}
export interface ChannelSelectMenuComponentData extends BaseSelectMenuComponentData {
type: ComponentType.ChannelSelect;
channelTypes?: readonly ChannelType[];
defaultValues?: readonly APISelectMenuDefaultValue<SelectMenuDefaultValueType.Channel>[];
}
export interface MessageSelectOption {