From cee63892fe16139a6d93ba7ba40f16475b51c037 Mon Sep 17 00:00:00 2001 From: MapleLeaf <19603573+itsMapleLeaf@users.noreply.github.com> Date: Sun, 26 Dec 2021 11:56:03 -0600 Subject: [PATCH] more comprehensive message types --- src/message.ts | 32 +++++++++++++++----------------- 1 file changed, 15 insertions(+), 17 deletions(-) diff --git a/src/message.ts b/src/message.ts index 4303e3b..e6d4a70 100644 --- a/src/message.ts +++ b/src/message.ts @@ -3,23 +3,21 @@ import type { EmbedOptions } from "./embed/embed-options" export type MessageOptions = { content: string embeds: EmbedOptions[] - actionRows: Array< - Array< - | { - type: "button" - customId: string - label?: string - style?: "primary" | "secondary" | "success" | "danger" - disabled?: boolean - emoji?: string - } - | { - type: "select" - customId: string - // todo - } - > - > + actionRows: Array> +} + +export type MessageButtonOptions = { + type: "button" + customId: string + label?: string + style?: "primary" | "secondary" | "success" | "danger" + disabled?: boolean + emoji?: string +} + +export type MessageSelectOptions = { + type: "select" + customId: string } export type Message = {