docs: add new typedef to properly doc InteractionReplyOptions (#5632)

This commit is contained in:
Shubham Parihar
2021-05-26 16:39:25 +05:30
committed by GitHub
parent ed593c91fb
commit 3589e0f442
4 changed files with 15 additions and 25 deletions

View File

@@ -51,18 +51,24 @@ class TextBasedChannel {
}
/**
* Options provided when sending or editing a message.
* @typedef {Object} MessageOptions
* Base options provided when sending.
* @typedef {Object} BaseMessageOptions
* @property {boolean} [tts=false] Whether or not the message should be spoken aloud
* @property {string} [nonce=''] The nonce for the message
* @property {string} [content=''] The content for the message
* @property {MessageEmbed|Object} [embed] An embed for the message
* (see [here](https://discord.com/developers/docs/resources/channel#embed-object) for more details)
* @property {MessageMentionOptions} [allowedMentions] Which mentions should be parsed from the message content
* @property {FileOptions[]|BufferResolvable[]} [files] Files to send with the message
* (see [here](https://discord.com/developers/docs/resources/channel#allowed-mentions-object) for more details)
* @property {FileOptions[]|BufferResolvable[]|MessageAttachment[]} [files] Files to send with the message
* @property {string|boolean} [code] Language for optional codeblock formatting to apply
* @property {boolean|SplitOptions} [split=false] Whether or not the message should be split into multiple messages if
* it exceeds the character limit. If an object is provided, these are the options for splitting the message
*/
/**
* Options provided when sending or editing a message.
* @typedef {BaseMessageOptions} MessageOptions
* @property {MessageEmbed|Object} [embed] An embed for the message
* (see [here](https://discord.com/developers/docs/resources/channel#embed-object) for more details)
* @property {ReplyOptions} [reply] The options for replying to a message
*/