blob: f1229eb13841b0573cd0a3e82cb989ad1570e832 [file] [log] [blame]
pineafan6de4da52023-03-07 20:43:44 +00001import { ButtonInteraction, TextInputBuilder } from "discord.js";
Skyler Grey75ea9172022-08-06 10:22:23 +01002import Discord, {
3 CommandInteraction,
4 Message,
TheCodedProf21c08592022-09-13 14:14:43 -04005 ActionRowBuilder,
6 ButtonBuilder,
Skyler Grey11236ba2022-08-08 21:13:33 +01007 ModalSubmitInteraction,
PineaFan100df682023-01-02 13:26:08 +00008 ButtonStyle,
9 TextInputStyle
Skyler Grey75ea9172022-08-06 10:22:23 +010010} from "discord.js";
pineafan73a7c4a2022-07-24 10:38:04 +010011import { modalInteractionCollector } from "./dualCollector.js";
pineafan63fc5e22022-08-04 22:04:10 +010012import EmojiEmbed from "./generateEmojiEmbed.js";
pineafan8b4b17f2022-02-27 20:42:52 +000013import getEmojiByName from "./getEmojiByName.js";
pineafan4f164f32022-02-26 22:07:12 +000014
pineafan02ba0232022-07-24 22:16:15 +010015interface CustomBoolean<T> {
16 title: string;
17 disabled: boolean;
18 value: string | null;
PineaFana34d04b2023-01-03 22:05:42 +000019 notValue: string | null;
pineafan63fc5e22022-08-04 22:04:10 +010020 emoji: string | undefined;
pineafan02ba0232022-07-24 22:16:15 +010021 active: boolean;
22 onClick: () => Promise<T>;
23 response: T | null;
24}
25
pineafan4f164f32022-02-26 22:07:12 +000026class confirmationMessage {
pineafan6de4da52023-03-07 20:43:44 +000027 interaction: CommandInteraction | ButtonInteraction;
pineafan63fc5e22022-08-04 22:04:10 +010028 title = "";
29 emoji = "";
pineafan62ce1922022-08-25 20:34:45 +010030 redEmoji: string | null = null;
PineaFan1dee28f2023-01-16 22:09:07 +000031 failedMessage: string | null = null;
32 failedEmoji: string | null = null;
33 failedStatus: "Success" | "Danger" | "Warning" | null = null;
pineafan63fc5e22022-08-04 22:04:10 +010034 description = "";
Skyler Grey75ea9172022-08-06 10:22:23 +010035 color: "Danger" | "Warning" | "Success" = "Success";
36 customButtons: Record<string, CustomBoolean<unknown>> = {};
pineafan63fc5e22022-08-04 22:04:10 +010037 inverted = false;
pineafan73a7c4a2022-07-24 10:38:04 +010038 reason: string | null = null;
pineafan4f164f32022-02-26 22:07:12 +000039
pineafan1e462ab2023-03-07 21:34:06 +000040 modals: {
41 buttonText: string;
42 emoji: string;
43 customId: string;
44 modal: Discord.ModalBuilder;
TheCodedProf35e73712023-03-10 17:35:35 -050045 values: Record<string, string>;
pineafan1e462ab2023-03-07 21:34:06 +000046 }[] = [];
pineafan6de4da52023-03-07 20:43:44 +000047
48 constructor(interaction: CommandInteraction | ButtonInteraction) {
pineafan4f164f32022-02-26 22:07:12 +000049 this.interaction = interaction;
pineafan4f164f32022-02-26 22:07:12 +000050 }
51
Skyler Grey75ea9172022-08-06 10:22:23 +010052 setTitle(title: string) {
53 this.title = title;
54 return this;
55 }
PineaFan1dee28f2023-01-16 22:09:07 +000056 setEmoji(emoji: string) {
Skyler Grey75ea9172022-08-06 10:22:23 +010057 this.emoji = emoji;
58 return this;
59 }
pineafan62ce1922022-08-25 20:34:45 +010060 setDescription(description: string, timedOut?: string) {
Skyler Grey75ea9172022-08-06 10:22:23 +010061 this.description = description;
PineaFan1dee28f2023-01-16 22:09:07 +000062 if (timedOut) this.failedMessage = timedOut;
Skyler Grey75ea9172022-08-06 10:22:23 +010063 return this;
64 }
65 setColor(color: "Danger" | "Warning" | "Success") {
66 this.color = color;
67 return this;
68 }
69 setInverted(inverted: boolean) {
70 this.inverted = inverted;
71 return this;
72 }
Skyler Greyda16adf2023-03-05 10:22:12 +000073 setFailedMessage(
74 text: string,
75 failedStatus: "Success" | "Danger" | "Warning" | null,
76 failedEmoji: string | null = null
77 ) {
PineaFan1dee28f2023-01-16 22:09:07 +000078 this.failedMessage = text;
79 this.failedStatus = failedStatus;
80 this.failedEmoji = failedEmoji;
81 return this;
82 }
Skyler Grey75ea9172022-08-06 10:22:23 +010083 addCustomBoolean(
84 customId: string,
85 title: string,
86 disabled: boolean,
PineaFan100df682023-01-02 13:26:08 +000087 callback: (() => Promise<unknown>) | null = async () => null,
Skyler Grey75ea9172022-08-06 10:22:23 +010088 callbackClicked: string | null,
PineaFana34d04b2023-01-03 22:05:42 +000089 callbackNotClicked: string | null,
Skyler Grey75ea9172022-08-06 10:22:23 +010090 emoji?: string,
91 initial?: boolean
92 ) {
93 this.customButtons[customId] = {
94 title: title,
95 disabled: disabled,
96 value: callbackClicked,
PineaFana34d04b2023-01-03 22:05:42 +000097 notValue: callbackNotClicked,
Skyler Grey75ea9172022-08-06 10:22:23 +010098 emoji: emoji,
99 active: initial ?? false,
PineaFan100df682023-01-02 13:26:08 +0000100 onClick: callback ?? (async () => null),
Skyler Grey75ea9172022-08-06 10:22:23 +0100101 response: null
102 };
103 return this;
pineafan6fb3e072022-05-20 19:27:23 +0100104 }
pineafan73a7c4a2022-07-24 10:38:04 +0100105 addReasonButton(reason: string) {
106 this.reason = reason;
107 return this;
108 }
TheCodedProf35e73712023-03-10 17:35:35 -0500109 addModal(buttonText: string, emoji: string, customId: string, current: Record<string, string>, modal: Discord.ModalBuilder) {
pineafan6de4da52023-03-07 20:43:44 +0000110 modal.setCustomId(customId);
TheCodedProf35e73712023-03-10 17:35:35 -0500111 this.modals.push({ buttonText, emoji, customId, modal, values: current });
pineafan6de4da52023-03-07 20:43:44 +0000112 return this;
113 }
Skyler Grey11236ba2022-08-08 21:13:33 +0100114 async send(editOnly?: boolean): Promise<{
115 success?: boolean;
116 cancelled?: boolean;
117 components?: Record<string, CustomBoolean<unknown>>;
118 newReason?: string;
pineafan1e462ab2023-03-07 21:34:06 +0000119 modals?: {
120 buttonText: string;
121 emoji: string;
122 customId: string;
123 modal: Discord.ModalBuilder;
TheCodedProf35e73712023-03-10 17:35:35 -0500124 values: Record<string, string>;
pineafan1e462ab2023-03-07 21:34:06 +0000125 }[];
Skyler Grey11236ba2022-08-08 21:13:33 +0100126 }> {
Skyler Greya402d1c2022-08-13 23:18:16 +0100127 let cancelled = false;
128 let success: boolean | undefined = undefined;
129 let returnComponents = false;
130 let newReason = undefined;
131
132 while (!cancelled && success === undefined && !returnComponents && !newReason) {
pineafan63fc5e22022-08-04 22:04:10 +0100133 const fullComponents = [
TheCodedProf35e73712023-03-10 17:35:35 -0500134 new ButtonBuilder()
pineafan02ba0232022-07-24 22:16:15 +0100135 .setCustomId("yes")
136 .setLabel("Confirm")
TheCodedProf21c08592022-09-13 14:14:43 -0400137 .setStyle(this.inverted ? ButtonStyle.Success : ButtonStyle.Danger)
pineafan02ba0232022-07-24 22:16:15 +0100138 .setEmoji(getEmojiByName("CONTROL.TICK", "id")),
TheCodedProf35e73712023-03-10 17:35:35 -0500139 new ButtonBuilder()
pineafan02ba0232022-07-24 22:16:15 +0100140 .setCustomId("no")
141 .setLabel("Cancel")
TheCodedProf35e73712023-03-10 17:35:35 -0500142 .setStyle(ButtonStyle.Danger)
pineafan02ba0232022-07-24 22:16:15 +0100143 .setEmoji(getEmojiByName("CONTROL.CROSS", "id"))
pineafan63fc5e22022-08-04 22:04:10 +0100144 ];
pineafan02ba0232022-07-24 22:16:15 +0100145 Object.entries(this.customButtons).forEach(([k, v]) => {
TheCodedProf35e73712023-03-10 17:35:35 -0500146 const button = new ButtonBuilder()
pineafan02ba0232022-07-24 22:16:15 +0100147 .setCustomId(k)
148 .setLabel(v.title)
TheCodedProf21c08592022-09-13 14:14:43 -0400149 .setStyle(v.active ? ButtonStyle.Success : ButtonStyle.Primary)
Skyler Grey75ea9172022-08-06 10:22:23 +0100150 .setDisabled(v.disabled);
Skyler Grey11236ba2022-08-08 21:13:33 +0100151 if (v.emoji !== undefined) button.setEmoji(getEmojiByName(v.emoji, "id"));
Skyler Grey75ea9172022-08-06 10:22:23 +0100152 fullComponents.push(button);
pineafan63fc5e22022-08-04 22:04:10 +0100153 });
pineafan6de4da52023-03-07 20:43:44 +0000154 for (const modal of this.modals) {
155 fullComponents.push(
TheCodedProf35e73712023-03-10 17:35:35 -0500156 new ButtonBuilder()
pineafan6de4da52023-03-07 20:43:44 +0000157 .setCustomId(modal.customId)
158 .setLabel(modal.buttonText)
159 .setStyle(ButtonStyle.Primary)
160 .setEmoji(getEmojiByName(modal.emoji, "id"))
161 .setDisabled(false)
162 );
163 }
Skyler Grey75ea9172022-08-06 10:22:23 +0100164 if (this.reason !== null)
165 fullComponents.push(
TheCodedProf35e73712023-03-10 17:35:35 -0500166 new ButtonBuilder()
Skyler Grey75ea9172022-08-06 10:22:23 +0100167 .setCustomId("reason")
168 .setLabel("Edit Reason")
TheCodedProf21c08592022-09-13 14:14:43 -0400169 .setStyle(ButtonStyle.Primary)
Skyler Grey75ea9172022-08-06 10:22:23 +0100170 .setEmoji(getEmojiByName("ICONS.EDIT", "id"))
171 .setDisabled(false)
172 );
pineafan63fc5e22022-08-04 22:04:10 +0100173 const components = [];
pineafan02ba0232022-07-24 22:16:15 +0100174 for (let i = 0; i < fullComponents.length; i += 5) {
Skyler Greyda16adf2023-03-05 10:22:12 +0000175 components.push(
176 new ActionRowBuilder<
TheCodedProf35e73712023-03-10 17:35:35 -0500177 | ButtonBuilder
Skyler Greyda16adf2023-03-05 10:22:12 +0000178 | Discord.StringSelectMenuBuilder
179 | Discord.RoleSelectMenuBuilder
180 | Discord.UserSelectMenuBuilder
181 >().addComponents(fullComponents.slice(i, i + 5))
182 );
pineafan02ba0232022-07-24 22:16:15 +0100183 }
pineafan63fc5e22022-08-04 22:04:10 +0100184 const object = {
pineafan377794f2022-04-18 19:01:01 +0100185 embeds: [
pineafan4edb7762022-06-26 19:21:04 +0100186 new EmojiEmbed()
pineafan377794f2022-04-18 19:01:01 +0100187 .setEmoji(this.emoji)
188 .setTitle(this.title)
Skyler Grey75ea9172022-08-06 10:22:23 +0100189 .setDescription(
190 this.description +
191 "\n\n" +
192 Object.values(this.customButtons)
193 .map((v) => {
PineaFana34d04b2023-01-03 22:05:42 +0000194 if (v.active) {
195 return v.value ? `*${v.value}*\n` : "";
196 } else {
197 return v.notValue ? `*${v.notValue}*\n` : "";
198 }
Skyler Greyda16adf2023-03-05 10:22:12 +0000199 })
200 .join("")
Skyler Grey75ea9172022-08-06 10:22:23 +0100201 )
pineafan377794f2022-04-18 19:01:01 +0100202 .setStatus(this.color)
pineafan377794f2022-04-18 19:01:01 +0100203 ],
pineafan02ba0232022-07-24 22:16:15 +0100204 components: components,
pineafan377794f2022-04-18 19:01:01 +0100205 ephemeral: true,
206 fetchReply: true
pineafan63fc5e22022-08-04 22:04:10 +0100207 };
Skyler Grey75ea9172022-08-06 10:22:23 +0100208 let m: Message;
pineafan02ba0232022-07-24 22:16:15 +0100209 try {
Skyler Grey75ea9172022-08-06 10:22:23 +0100210 if (editOnly) {
PineaFan100df682023-01-02 13:26:08 +0000211 m = (await this.interaction.editReply(object)) as unknown as Message;
pineafan02ba0232022-07-24 22:16:15 +0100212 } else {
Skyler Grey11236ba2022-08-08 21:13:33 +0100213 m = (await this.interaction.reply(object)) as unknown as Message;
pineafan02ba0232022-07-24 22:16:15 +0100214 }
PineaFana34d04b2023-01-03 22:05:42 +0000215 } catch (e) {
Skyler Greya402d1c2022-08-13 23:18:16 +0100216 cancelled = true;
217 continue;
Skyler Grey75ea9172022-08-06 10:22:23 +0100218 }
pineafan377794f2022-04-18 19:01:01 +0100219 let component;
220 try {
Skyler Grey75ea9172022-08-06 10:22:23 +0100221 component = await m.awaitMessageComponent({
Skyler Greyda16adf2023-03-05 10:22:12 +0000222 filter: (i) =>
223 i.user.id === this.interaction.user.id && i.channel!.id === this.interaction.channel!.id,
Skyler Grey75ea9172022-08-06 10:22:23 +0100224 time: 300000
225 });
pineafan377794f2022-04-18 19:01:01 +0100226 } catch (e) {
pineafan1e462ab2023-03-07 21:34:06 +0000227 success = false;
TheCodedProf1c3ad3c2023-01-25 17:58:36 -0500228 break;
pineafan377794f2022-04-18 19:01:01 +0100229 }
230 if (component.customId === "yes") {
Skyler Greyf4f21c42023-03-08 14:36:29 +0000231 await component.deferUpdate();
pineafan63fc5e22022-08-04 22:04:10 +0100232 for (const v of Object.values(this.customButtons)) {
233 if (!v.active) continue;
Skyler Grey75ea9172022-08-06 10:22:23 +0100234 try {
235 v.response = await v.onClick();
236 } catch (e) {
237 console.log(e);
238 }
pineafan63fc5e22022-08-04 22:04:10 +0100239 }
Skyler Greya402d1c2022-08-13 23:18:16 +0100240 success = true;
241 returnComponents = true;
242 continue;
pineafan377794f2022-04-18 19:01:01 +0100243 } else if (component.customId === "no") {
Skyler Greyf4f21c42023-03-08 14:36:29 +0000244 await component.deferUpdate();
Skyler Greya402d1c2022-08-13 23:18:16 +0100245 success = false;
246 returnComponents = true;
247 continue;
pineafan73a7c4a2022-07-24 10:38:04 +0100248 } else if (component.customId === "reason") {
Skyler Grey75ea9172022-08-06 10:22:23 +0100249 await component.showModal(
PineaFan100df682023-01-02 13:26:08 +0000250 new Discord.ModalBuilder()
Skyler Grey75ea9172022-08-06 10:22:23 +0100251 .setCustomId("modal")
252 .setTitle("Editing reason")
253 .addComponents(
PineaFan100df682023-01-02 13:26:08 +0000254 new ActionRowBuilder<TextInputBuilder>().addComponents(
255 new TextInputBuilder()
Skyler Grey75ea9172022-08-06 10:22:23 +0100256 .setCustomId("reason")
257 .setLabel("Reason")
258 .setMaxLength(2000)
259 .setRequired(false)
PineaFan100df682023-01-02 13:26:08 +0000260 .setStyle(TextInputStyle.Paragraph)
Skyler Grey75ea9172022-08-06 10:22:23 +0100261 .setPlaceholder("Spammed in #general")
262 .setValue(this.reason ? this.reason : "")
263 )
264 )
265 );
pineafan73a7c4a2022-07-24 10:38:04 +0100266 await this.interaction.editReply({
Skyler Grey75ea9172022-08-06 10:22:23 +0100267 embeds: [
268 new EmojiEmbed()
269 .setTitle(this.title)
Skyler Grey11236ba2022-08-08 21:13:33 +0100270 .setDescription("Modal opened. If you can't see it, click back and try again.")
Skyler Grey75ea9172022-08-06 10:22:23 +0100271 .setStatus(this.color)
272 .setEmoji(this.emoji)
273 ],
274 components: [
TheCodedProf35e73712023-03-10 17:35:35 -0500275 new ActionRowBuilder<ButtonBuilder>().addComponents(
TheCodedProf21c08592022-09-13 14:14:43 -0400276 new ButtonBuilder()
Skyler Grey75ea9172022-08-06 10:22:23 +0100277 .setLabel("Back")
278 .setEmoji(getEmojiByName("CONTROL.LEFT", "id"))
TheCodedProf21c08592022-09-13 14:14:43 -0400279 .setStyle(ButtonStyle.Primary)
Skyler Grey75ea9172022-08-06 10:22:23 +0100280 .setCustomId("back")
PineaFan100df682023-01-02 13:26:08 +0000281 )
Skyler Grey75ea9172022-08-06 10:22:23 +0100282 ]
pineafan73a7c4a2022-07-24 10:38:04 +0100283 });
284 let out;
285 try {
Skyler Greyda16adf2023-03-05 10:22:12 +0000286 out = (await modalInteractionCollector(
287 m,
288 this.interaction.user
289 )) as Discord.ModalSubmitInteraction | null;
Skyler Grey75ea9172022-08-06 10:22:23 +0100290 } catch (e) {
Skyler Greya402d1c2022-08-13 23:18:16 +0100291 cancelled = true;
292 continue;
Skyler Grey75ea9172022-08-06 10:22:23 +0100293 }
Skyler Grey0d885222023-03-08 21:46:37 +0000294 if (out === null) {
Skyler Greya402d1c2022-08-13 23:18:16 +0100295 cancelled = true;
296 continue;
Skyler Grey11236ba2022-08-08 21:13:33 +0100297 }
Skyler Grey0d885222023-03-08 21:46:37 +0000298 if (out.isButton()) {
299 continue;
300 }
Skyler Grey11236ba2022-08-08 21:13:33 +0100301 if (out instanceof ModalSubmitInteraction) {
Skyler Greya402d1c2022-08-13 23:18:16 +0100302 newReason = out.fields.getTextInputValue("reason");
303 continue;
Skyler Grey75ea9172022-08-06 10:22:23 +0100304 } else {
Skyler Greya402d1c2022-08-13 23:18:16 +0100305 returnComponents = true;
306 continue;
Skyler Grey75ea9172022-08-06 10:22:23 +0100307 }
pineafan6de4da52023-03-07 20:43:44 +0000308 } else if (this.modals.map((m) => m.customId).includes(component.customId)) {
pineafan1e462ab2023-03-07 21:34:06 +0000309 const chosenModal = this.modals.find(
310 (
311 (component) => (m) =>
312 m.customId === component.customId
313 )(component)
314 );
pineafan6de4da52023-03-07 20:43:44 +0000315 await component.showModal(chosenModal!.modal);
316 await this.interaction.editReply({
317 embeds: [
318 new EmojiEmbed()
319 .setTitle(this.title)
320 .setDescription("Modal opened. If you can't see it, click back and try again.")
321 .setStatus(this.color)
322 .setEmoji(this.emoji)
323 ],
324 components: [
TheCodedProf35e73712023-03-10 17:35:35 -0500325 new ActionRowBuilder<ButtonBuilder>().addComponents(
pineafan6de4da52023-03-07 20:43:44 +0000326 new ButtonBuilder()
327 .setLabel("Back")
328 .setEmoji(getEmojiByName("CONTROL.LEFT", "id"))
329 .setStyle(ButtonStyle.Primary)
330 .setCustomId("back")
331 )
332 ]
333 });
334 let out;
335 try {
336 out = (await modalInteractionCollector(
337 m,
338 this.interaction.user
339 )) as Discord.ModalSubmitInteraction | null;
340 } catch (e) {
341 console.log(e);
342 cancelled = true;
343 continue;
344 }
Skyler Grey0d885222023-03-08 21:46:37 +0000345 if (out === null) {
346 cancelled = true;
347 continue;
348 }
349 if (out.isButton()) {
pineafan6de4da52023-03-07 20:43:44 +0000350 continue;
351 }
352 if (out instanceof ModalSubmitInteraction) {
TheCodedProf35e73712023-03-10 17:35:35 -0500353 out.fields.fields.forEach((f, k) => {
354 chosenModal!.values[k] = f.value;
355 });
pineafan6de4da52023-03-07 20:43:44 +0000356 }
357 returnComponents = true;
358 continue;
pineafan02ba0232022-07-24 22:16:15 +0100359 } else {
Skyler Greyf4f21c42023-03-08 14:36:29 +0000360 await component.deferUpdate();
Skyler Grey11236ba2022-08-08 21:13:33 +0100361 this.customButtons[component.customId]!.active = !this.customButtons[component.customId]!.active;
Skyler Greya402d1c2022-08-13 23:18:16 +0100362 returnComponents = true;
363 continue;
pineafan377794f2022-04-18 19:01:01 +0100364 }
pineafan8b4b17f2022-02-27 20:42:52 +0000365 }
Skyler Greya402d1c2022-08-13 23:18:16 +0100366 const returnValue: Awaited<ReturnType<typeof this.send>> = {};
367
pineafan62ce1922022-08-25 20:34:45 +0100368 if (cancelled) {
Skyler Greyda16adf2023-03-05 10:22:12 +0000369 await this.timeoutError();
pineafan62ce1922022-08-25 20:34:45 +0100370 returnValue.cancelled = true;
371 }
TheCodedProff86ba092023-01-27 17:10:07 -0500372 if (success === false) {
PineaFan1dee28f2023-01-16 22:09:07 +0000373 await this.interaction.editReply({
Skyler Greyda16adf2023-03-05 10:22:12 +0000374 embeds: [
375 new EmojiEmbed()
376 .setTitle(this.title)
377 .setDescription(this.failedMessage ?? "*Message timed out*")
378 .setStatus(this.failedStatus ?? "Danger")
379 .setEmoji(this.failedEmoji ?? this.redEmoji ?? this.emoji)
380 ],
381 components: []
PineaFan1dee28f2023-01-16 22:09:07 +0000382 });
pineafan6de4da52023-03-07 20:43:44 +0000383 return { success: false, cancelled: returnValue.cancelled ?? false };
PineaFan1dee28f2023-01-16 22:09:07 +0000384 }
TheCodedProf1c3ad3c2023-01-25 17:58:36 -0500385 if (returnComponents || success !== undefined) returnValue.components = this.customButtons;
386 if (success !== undefined) returnValue.success = success;
Skyler Greya402d1c2022-08-13 23:18:16 +0100387 if (newReason) returnValue.newReason = newReason;
pineafan6de4da52023-03-07 20:43:44 +0000388 returnValue.modals = this.modals;
Skyler Greya402d1c2022-08-13 23:18:16 +0100389
pineafan6de4da52023-03-07 20:43:44 +0000390 const modals = this.modals;
Skyler Greyda16adf2023-03-05 10:22:12 +0000391 const typedReturnValue = returnValue as
392 | { cancelled: true }
pineafan1e462ab2023-03-07 21:34:06 +0000393 | {
394 success: boolean;
395 components: Record<string, CustomBoolean<unknown>>;
396 modals: typeof modals;
397 newReason?: string;
398 }
pineafan6de4da52023-03-07 20:43:44 +0000399 | { newReason: string; components: Record<string, CustomBoolean<unknown>>; modals: typeof modals }
400 | { components: Record<string, CustomBoolean<unknown>>; modals: typeof modals };
PineaFan100df682023-01-02 13:26:08 +0000401
402 return typedReturnValue;
pineafan4f164f32022-02-26 22:07:12 +0000403 }
pineafan62ce1922022-08-25 20:34:45 +0100404
405 async timeoutError(): Promise<void> {
406 await this.interaction.editReply({
407 embeds: [
408 new EmojiEmbed()
409 .setTitle(this.title)
410 .setDescription("We closed this message because it was not used for a while.")
411 .setStatus("Danger")
PineaFan1dee28f2023-01-16 22:09:07 +0000412 .setEmoji("CONTROL.BLOCKCROSS")
pineafan62ce1922022-08-25 20:34:45 +0100413 ],
414 components: []
Skyler Greyda16adf2023-03-05 10:22:12 +0000415 });
pineafan62ce1922022-08-25 20:34:45 +0100416 }
pineafan4f164f32022-02-26 22:07:12 +0000417}
418
pineafan73a7c4a2022-07-24 10:38:04 +0100419export default confirmationMessage;