Giter VIP home page Giter VIP logo

discord-embeds-paginator's Introduction

banner

Discord Embeds Paginator

Discord Embeds Paginator is a customizable pagination module for Discord bots using Discord.js. It allows you to display embed pages and navigate through them using buttons.

version collaborators downloads licence

Installation

To install Discord Embeds Paginator, use npm:

npm install discord-embeds-paginator@latest

Usage

const { DiscordEmbedsPaginator } = require("discord-embeds-paginator");

// Create an instance of DiscordEmbedsPaginator
const paginator = new DiscordEmbedsPaginator([], {
  customId: "DiscordEmbedsPaginator",
  customStyle: ButtonStyle.Secondary,
  customEmojis: { previous: "◀️", next: "▶️" },
  customEmbeds: [],
  timeout: 60000,
});

// Create the paginator message
paginator.createPaginatorMessage(channel);

Sponsor Us

Do you use Discord-Embeds-Paginator and are you satisfied? You can support us with a one-time donation to help us improve our work: Donate here

API Documentation

Class: DiscordEmbedsPaginator

A class representing a Discord Embeds Paginator.

Constructor

new DiscordEmbedsPaginator(pages, (options = {}));

Creates a new instance of DiscordEmbedsPaginator.

Methods

  • createPaginatorMessage(channel): Creates the paginator message in the specified channel.
  • createPageButtons(): Creates the navigation buttons for the paginator.
  • createButtonCollector(message): Sets up the button collector to handle button interactions.
  • getPageEmbed(): Retrieves the current page embed.

Options

  • customId: The custom ID for the paginator.
  • customStyle: The custom button style for the paginator.
  • customEmojis: An object containing custom emojis for the previous and next buttons.
  • customEmbeds: An array of embeds representing the pages.
  • timeout: The timeout for the paginator in milliseconds.

Do you have any issues?

If you have any issues don't hesitate to report it via GitHub Issues.

Support

If you need help or assistance please either ask in my Discord Server.

License

This project is licensed under the MIT License.

Developed by @deemdev with ❤️

discord-embeds-paginator's People

Contributors

devdeem avatar rpdjf avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.