@discord-additions/components
Version:
Some helpful additions to make creating components easier.
15 lines (14 loc) • 568 B
TypeScript
import type Button from "./Button";
import type SelectMenu from "./SelectMenu";
import type TextInput from "./TextInput";
import type { MessageActionRow, ModalActionRow } from "../util/types";
export default class ActionRow {
type: 1;
private components;
addComponent(component: ActionRow["components"][number]): this;
addComponents(...components: Array<ActionRow["components"][number]>): this;
get size(): number;
getComponents(): (Button | SelectMenu | TextInput)[];
isEmpty(): boolean;
toJSON(): MessageActionRow | ModalActionRow;
}