Fix msg component typings

This commit is contained in:
TomatoCake
2024-07-28 20:50:11 +10:00
committed by Madeline
parent f047f93b77
commit a887608d30
5 changed files with 104285 additions and 2538 deletions
+2 -2
View File
@@ -16,7 +16,7 @@
along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
import { Embed, MessageComponent, PollAnswer, PollMedia } from "@spacebar/util";
import { ActionRowComponent, Embed, PollAnswer, PollMedia } from "@spacebar/util";
type Attachment = {
id: string;
@@ -54,7 +54,7 @@ export interface MessageCreateSchema {
**/
attachments?: Attachment[];
sticker_ids?: string[];
components?: MessageComponent[];
components?: ActionRowComponent[];
// TODO: Fix TypeScript errors in src\api\util\handlers\Message.ts once this is enabled
poll?: PollCreationSchema;
enforce_nonce?: boolean; // For Discord compatibility, it's the default behavior here
@@ -17,9 +17,9 @@
*/
import {
ActionRowComponent,
Attachment,
Embed,
MessageComponent,
MessageType,
Poll,
PublicUser,
@@ -42,7 +42,7 @@ export interface GuildMessagesSearchMessage {
timestamp: string;
edited_timestamp: string | null;
flags: number;
components: MessageComponent[];
components: ActionRowComponent[];
poll: Poll;
hit: true;
}