import { LoadingEmbed } from "./../utils/defaultEmbeds.js";
import { SelectMenuOption } from "@discordjs/builders";
import Discord, { MessageActionRow, MessageButton } from "discord.js";
import EmojiEmbed from "../utils/generateEmojiEmbed.js";
import getEmojiByName from "../utils/getEmojiByName.js";
import createPageIndicator from "../utils/createPageIndicator.js";

class Embed {
    embed: Discord.MessageEmbed;
    title: string;
    description = "";
    pageId = 0;
    setEmbed(embed: Discord.MessageEmbed) {
        this.embed = embed;
        return this;
    }
    setTitle(title: string) {
        this.title = title;
        return this;
    }
    setDescription(description: string) {
        this.description = description;
        return this;
    }
    setPageId(pageId: number) {
        this.pageId = pageId;
        return this;
    }
}

export default async (guild, interaction?) => {
    let c = guild.publicUpdatesChannel
        ? guild.publicUpdatesChannel
        : guild.systemChannel;
    c = c
        ? c
        : guild.channels.cache.find(
              (ch) =>
                  ch.type === "GUILD_TEXT" &&
                  ch
                      .permissionsFor(guild.roles.everyone)
                      .has("SEND_MESSAGES") &&
                  ch.permissionsFor(guild.me).has("EMBED_LINKS")
          );
    const pages = [
        new Embed()
            .setEmbed(
                new EmojiEmbed()
                    .setTitle("Welcome to Nucleus")
                    .setDescription(
                        "Thanks for adding Nucleus to your server\n\n" +
                            "On the next few pages you can find instructions on getting started, and commands you may want to set up\n\n" +
                            "If you need support, have questions or want features, you can let us know in [Clicks](https://discord.gg/bPaNnxe)"
                    )
                    .setEmoji("NUCLEUS.LOGO")
                    .setStatus("Danger")
            )
            .setTitle("Welcome")
            .setDescription("About Nucleus")
            .setPageId(0),
        new Embed()
            .setEmbed(
                new EmojiEmbed()
                    .setTitle("Logging")
                    .setDescription(
                        "Nucleus can log server events and keep you informed with what content is being posted to your server.\n" +
                            "We have 2 different types of logs, which each can be configured to send to a channel of your choice:\n" +
                            "**General Logs:** These are events like kicks and channel changes etc.\n" +
                            "**Warning Logs:** Warnings like NSFW avatars and spam etc. that may require action by a server staff member. " +
                            "These go to to a separate staff notifications channel.\n\n" +
                            "A general log channel can be set with `/settings log`\n" +
                            "A warning log channel can be set with `/settings warnings channel`"
                    )
                    .setEmoji("ICONS.LOGGING")
                    .setStatus("Danger")
            )
            .setTitle("Logging")
            .setDescription("Logging, staff warning logs etc.")
            .setPageId(1),
        new Embed()
            .setEmbed(
                new EmojiEmbed()
                    .setTitle("Moderation")
                    .setDescription(
                        "Nucleus has a number of commands that can be used to moderate your server.\n" +
                            "These commands are all found under `/mod`, and they include:\n" +
                            `**${getEmojiByName(
                                "PUNISH.WARN.YELLOW"
                            )} Warn:** The user is warned (via DM) that they violated server rules.\n` +
                            `**${getEmojiByName(
                                "PUNISH.CLEARHISTORY"
                            )} Clear:** Some messages from a user are deleted in a channel.\n` +
                            `**${getEmojiByName(
                                "PUNISH.MUTE.YELLOW"
                            )} Mute:** The user is unable to send messages or join voice chats.\n` +
                            `**${getEmojiByName(
                                "PUNISH.MUTE.GREEN"
                            )} Unmute:** The user is able to send messages in the server.\n` +
                            `**${getEmojiByName(
                                "PUNISH.KICK.RED"
                            )} Kick:** The user is removed from the server.\n` +
                            `**${getEmojiByName(
                                "PUNISH.SOFTBAN"
                            )} Softban:** Kicks the user, deleting their messages from every channel.\n` +
                            `**${getEmojiByName(
                                "PUNISH.BAN.RED"
                            )} Ban:** The user is removed from the server, and they are unable to rejoin.\n` +
                            `**${getEmojiByName(
                                "PUNISH.BAN.GREEN"
                            )} Unban:** The user is able to rejoin the server.`
                    )
                    .setEmoji("PUNISH.BAN.RED")
                    .setStatus("Danger")
            )
            .setTitle("Moderation")
            .setDescription("Basic moderation commands")
            .setPageId(2),
        new Embed()
            .setEmbed(
                new EmojiEmbed()
                    .setTitle("Verify")
                    .setDescription(
                        "Nucleus has a verification system that allows users to prove they aren't bots.\n" +
                            "This is done by running `/verify` which sends a message only the user can see, giving them a link to a CAPTCHA to verify.\n" +
                            "After the user complete's the CAPTCHA, they are given a role and can use the permissions accordingly.\n" +
                            "You can set the role given with `/settings verify`"
                    )
                    .setEmoji("CONTROL.REDTICK")
                    .setStatus("Danger")
            )
            .setTitle("Verify")
            .setDescription("Captcha verification system")
            .setPageId(3),
        new Embed()
            .setEmbed(
                new EmojiEmbed()
                    .setTitle("Content Scanning")
                    .setDescription(
                        "Nucleus has a content scanning system that automatically scans links and images sent by users.\n" +
                            "Nucleus can detect, delete, and punish users for sending NSFW content, or links to scam or adult sites.\n" +
                            "You can set the threshold for this in `/settings automation`" // TODO
                    )
                    .setEmoji("MOD.IMAGES.TOOSMALL")
                    .setStatus("Danger")
            )
            .setTitle("Content Scanning")
            .setDescription("Content (NSFW, malware, scams) scanning")
            .setPageId(4),
        new Embed()
            .setEmbed(
                new EmojiEmbed()
                    .setTitle("Tickets")
                    .setDescription(
                        "Nucleus has a ticket system that allows users to create tickets and have a support team respond to them.\n" +
                            "Tickets can be created with `/ticket create` and a channel is created, pinging the user and support role.\n" +
                            "When the ticket is resolved, anyone can run `/ticket close` (or click the button) to close it.\n" +
                            "Running `/ticket close` again will delete the ticket."
                    )
                    .setEmoji("GUILD.TICKET.CLOSE")
                    .setStatus("Danger")
            )
            .setTitle("Tickets")
            .setDescription("Ticket system")
            .setPageId(5),
        new Embed()
            .setEmbed(
                new EmojiEmbed()
                    .setTitle("Tags")
                    .setDescription(
                        "Add a tag system to your server with the `/tag` and `/tags` commands.\n" +
                            "To create a tag, type `/tags create <tag name> <tag content>`.\n" +
                            "Tag names and content can be edited with `/tags edit`.\n" +
                            "To delete a tag, type `/tags delete <tag name>`.\n" +
                            "To view all tags, type `/tags list`.\n"
                    )
                    .setEmoji("PUNISH.NICKNAME.RED")
                    .setStatus("Danger")
            )
            .setTitle("Tags")
            .setDescription("Tag system")
            .setPageId(6),
        new Embed()
            .setEmbed(
                new EmojiEmbed()
                    .setTitle("Premium")
                    .setDescription(
                        "In the near future, we will be releasing extra premium only features.\n" +
                            "These features will include:\n\n" +
                            "**Attachment logs**\n> When a message with attachments is edited or deleted, the logs will also include the images sent.\n" +
                            "\nPremium is not yet available. Check `/nucleus premium` for updates on features and pricing"
                    )
                    .setEmoji("NUCLEUS.COMMANDS.LOCK")
                    .setStatus("Danger")
            )
            .setTitle("Premium")
            .setDescription("Premium features")
            .setPageId(7)
    ];
    let m;
    if (interaction) {
        m = await interaction.reply({
            embeds: LoadingEmbed,
            fetchReply: true,
            ephemeral: true
        });
    } else {
        m = await c.send({ embeds: LoadingEmbed });
    }
    let page = 0;

    const f = async (component) => {
        return (component.member as Discord.GuildMember).permissions.has(
            "MANAGE_GUILD"
        );
    };

    let selectPaneOpen = false;

    while (true) {
        let selectPane = [];

        if (selectPaneOpen) {
            const options = [];
            pages.forEach((embed) => {
                options.push(
                    new SelectMenuOption({
                        label: embed.title,
                        value: embed.pageId.toString(),
                        description: embed.description || ""
                    })
                );
            });
            selectPane = [
                new MessageActionRow().addComponents([
                    new Discord.MessageSelectMenu()
                        .addOptions(options)
                        .setCustomId("page")
                        .setMaxValues(1)
                        .setPlaceholder("Choose a page...")
                ])
            ];
        }
        const components = selectPane.concat([
            new MessageActionRow().addComponents([
                new MessageButton()
                    .setCustomId("left")
                    .setEmoji(getEmojiByName("CONTROL.LEFT", "id"))
                    .setStyle("SECONDARY")
                    .setDisabled(page === 0),
                new MessageButton()
                    .setCustomId("select")
                    .setEmoji(getEmojiByName("CONTROL.MENU", "id"))
                    .setStyle(selectPaneOpen ? "PRIMARY" : "SECONDARY")
                    .setDisabled(false),
                new MessageButton()
                    .setCustomId("right")
                    .setEmoji(getEmojiByName("CONTROL.RIGHT", "id"))
                    .setStyle("SECONDARY")
                    .setDisabled(page === pages.length - 1)
            ])
        ]);
        if (interaction) {
            const em = new Discord.MessageEmbed(pages[page].embed);
            em.setDescription(
                em.description +
                    "\n\n" +
                    createPageIndicator(pages.length, page)
            );
            await interaction.editReply({
                embeds: [em],
                components: components
            });
        } else {
            const em = new Discord.MessageEmbed(pages[page].embed);
            em.setDescription(
                em.description +
                    "\n\n" +
                    createPageIndicator(pages.length, page)
            );
            await m.edit({
                embeds: [em],
                components: components,
                fetchReply: true
            });
        }
        let i;
        try {
            i = await m.awaitMessageComponent({
                filter: interaction
                    ? () => {
                          return true;
                      }
                    : f,
                time: 300000
            });
        } catch (e) {
            break;
        }
        i.deferUpdate();
        if (i.component.customId === "left") {
            if (page > 0) page--;
            selectPaneOpen = false;
        } else if (i.component.customId === "right") {
            if (page < pages.length - 1) page++;
            selectPaneOpen = false;
        } else if (i.component.customId === "select") {
            selectPaneOpen = !selectPaneOpen;
        } else if (i.component.customId === "page") {
            page = parseInt(i.values[0]);
            selectPaneOpen = false;
        } else {
            if (interaction) {
                const em = new Discord.MessageEmbed(pages[page].embed);
                em.setDescription(
                    em.description +
                        "\n\n" +
                        createPageIndicator(pages.length, page)
                );
                em.setFooter({ text: "Message closed" });
                interaction.editReply({
                    embeds: [em],
                    components: [
                        new MessageActionRow().addComponents([
                            new MessageButton()
                                .setCustomId("left")
                                .setEmoji(getEmojiByName("CONTROL.LEFT", "id"))
                                .setStyle("SECONDARY")
                                .setDisabled(true),
                            new MessageButton()
                                .setCustomId("select")
                                .setEmoji(getEmojiByName("CONTROL.MENU", "id"))
                                .setStyle(
                                    selectPaneOpen ? "PRIMARY" : "SECONDARY"
                                )
                                .setDisabled(true),
                            new MessageButton()
                                .setCustomId("right")
                                .setEmoji(getEmojiByName("CONTROL.RIGHT", "id"))
                                .setStyle("SECONDARY")
                                .setDisabled(true)
                        ])
                    ]
                });
            } else {
                m.delete();
            }
            return;
        }
    }
    if (interaction) {
        const em = new Discord.MessageEmbed(pages[page].embed);
        em.setDescription(
            em.description + "\n\n" + createPageIndicator(pages.length, page)
        ).setFooter({ text: "Message timed out" });
        await interaction.editReply({
            embeds: [em],
            components: [
                new MessageActionRow().addComponents([
                    new MessageButton()
                        .setCustomId("left")
                        .setEmoji(getEmojiByName("CONTROL.LEFT", "id"))
                        .setStyle("SECONDARY")
                        .setDisabled(true),
                    new MessageButton()
                        .setCustomId("select")
                        .setEmoji(getEmojiByName("CONTROL.MENU", "id"))
                        .setStyle("SECONDARY")
                        .setDisabled(true),
                    new MessageButton()
                        .setCustomId("right")
                        .setEmoji(getEmojiByName("CONTROL.RIGHT", "id"))
                        .setStyle("SECONDARY")
                        .setDisabled(true)
                ])
            ]
        });
    } else {
        const em = new Discord.MessageEmbed(pages[page].embed);
        em.setDescription(
            em.description + "\n\n" + createPageIndicator(pages.length, page)
        ).setFooter({ text: "Message timed out" });
        await m.edit({
            embeds: [em],
            components: [
                new MessageActionRow().addComponents([
                    new MessageButton()
                        .setCustomId("left")
                        .setEmoji(getEmojiByName("CONTROL.LEFT", "id"))
                        .setStyle("SECONDARY")
                        .setDisabled(true),
                    new MessageButton()
                        .setCustomId("select")
                        .setEmoji(getEmojiByName("CONTROL.MENU", "id"))
                        .setStyle("SECONDARY")
                        .setDisabled(true),
                    new MessageButton()
                        .setCustomId("right")
                        .setEmoji(getEmojiByName("CONTROL.RIGHT", "id"))
                        .setStyle("SECONDARY")
                        .setDisabled(true)
                ])
            ]
        });
    }
};
