From 7d341000d44b762a2fe0434a6b518f7d63539d34 Mon Sep 17 00:00:00 2001 From: anandre <38661761+anandre@users.noreply.github.com> Date: Fri, 21 Apr 2023 03:17:44 -0500 Subject: [PATCH] docs(InteractionResponses): showModal docs change (#9434) * Update InteractionResponses.js Update the parameters for the showModal method * Update APITypes.js Add APIModalInteractionResponseCallbackData link for docs link for showModal method * Update InteractionResponses.js Change the order of parameters so the ModalBuilder is listed first * Update APITypes.js Disable the ESline line length rule for the APITypes file * Update InteractionResponses.js Add ModalComponentData to the JSDoc, it was omitted before. --- .../src/structures/interfaces/InteractionResponses.js | 2 +- packages/discord.js/src/util/APITypes.js | 7 +++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/packages/discord.js/src/structures/interfaces/InteractionResponses.js b/packages/discord.js/src/structures/interfaces/InteractionResponses.js index 636f7310e..d846ac716 100644 --- a/packages/discord.js/src/structures/interfaces/InteractionResponses.js +++ b/packages/discord.js/src/structures/interfaces/InteractionResponses.js @@ -245,7 +245,7 @@ class InteractionResponses { /** * Shows a modal component - * @param {APIModal|ModalData|Modal} modal The modal to show + * @param {ModalBuilder|ModalComponentData|APIModalInteractionResponseCallbackData} modal The modal to show * @returns {Promise} */ async showModal(modal) { diff --git a/packages/discord.js/src/util/APITypes.js b/packages/discord.js/src/util/APITypes.js index 3a4878e2d..080df5161 100644 --- a/packages/discord.js/src/util/APITypes.js +++ b/packages/discord.js/src/util/APITypes.js @@ -1,3 +1,5 @@ +/* eslint-disable max-len */ + /** * @external ActivityFlags * @see {@link https://discord-api-types.dev/api/discord-api-types-v10/enum/ActivityFlags} @@ -133,6 +135,11 @@ * @see {@link https://discord-api-types.dev/api/discord-api-types-v10/interface/APIModalInteractionResponse} */ +/** + * @external APIModalInteractionResponseCallbackData + * @see {@link https://discord-api-types.dev/api/discord-api-types-v10/interface/APIModalInteractionResponseCallbackData} + */ + /** * @external APIModalComponent * @see {@link https://discord-api-types.dev/api/discord-api-types-v10#APIModalComponent}