Releases: ygimenez/Pagination-Utils
Pagination Utils 4.2.1 - Some fixes
Fixed some annoying usability issues and added a method for better control over button registration.
Changelist:
- Updated JDA to 6.1.3
- Added method for adding buttons with custom
ButtonIdforButtonizeHelperandCategorizeHelper - Fixed wrong
modifyButtonsbehavior - Fixed categories not being disabled after clicking
- Fixed button IDs clashing from similar labels
Pagination Utils 4.1.5 - Dependency Upgrade
Updated dependencies to latest versions.
Changelist:
- Updated JDA to 5.6.1
- Updated Apache Commons Lang to 3.18.0
- Updated Google Protobuf to 4.31.1
Pagination Utils 4.1.4b - Hotfix Hotfix
Reverted some changes made in last update to properly solve the ID issues.
Changelist:
- Reverted ID fixes, the ID will now be split by pattern as intended.
- IDs will now have a random positive integer appended instead of a random hash.
Pagination Utils 4.1.4 - Pagination Hotfix
Fixed issue causing buttons to not be recognized when using pre-configured emotes.
Changelist:
- The ID will now be checked until the first period, since that's the only relevant part of it.
Pagination Utils 4.1.3 - Usability improvements
TextId and EmoteId now include a label property, separating the internal ID from what the user sees and allowing emote buttons to also have a display text.
Changelist:
- Added a label property to extensions of
ButtonId<T> - Fixed wrong button IDs behavior when they contained a period
- Minor grammar fixes
Pagination Utils 4.1.2 - Myriad of colors
Added style property to CategorizeHelper and ButtonizeHelper to allow specifying button styles. Helpers now also implement Cloneable, so you can reuse them for creating new instances.
Changelist:
- Added style parameter to CategorizeHelper (
addCategory) and ButtonizeHelper (addAction). - Added a clear function to all helpers for convenience.
- Helpers are now cloneable.
- Added NotNull annotation to some methods.
Pagination Utils 4.1.1 - Less static
Moved TaskScheduler and EventHandler instances to inside Paginator as final variables instead of static, this should allow hotswapping Paginators without the risk of configuration clashes.
Changelist:
- Moved TaskScheduler and EventHandler static variables to Paginator class as final instance variables.
- Added protobuf version override to avoid known vulnerability.
Pagination Utils 4.1.0 - Let there be text
Added support for buttons containing either a text or emoji label, this affects both Pages.categorize and Pages.buttonize methods.
This release also unifies the finalizer task scheduling on a single pool, which allows cancelling previous tasks mapped to the same ID (for example timeout refreshers). This change should reduce resource usage by the library.
WARNING: The methods Pages.categorize and Pages.buttonize now use Mapping for button declaration instead of a regular Map. The class' methods are the same as a map mostly, so simply renaming should work for current usages.
Changelist:
- Methods that accepted
Map<Emoji, V>now useMapping<V>instead, this is to allow Emote and String to be used simultaneously. Existing usages can be safely renamed to useMappingas it shares the same methods as aMap(but does notimplementsit). - Tasks are now managed by
TaskScheduler, preventing two concurrent tasks running for the same message. EventHandlerevent methods now accept a String instead of generating an ID from a Message, existing usages must useEventHandler.getEventIdto generate them manually.- Updated JDA version to 5.1.0.
Pagination Utils 4.0.6 - A little patch
Moved the feature onRemove (which was ran if an unknown message was found during event handling) to PaginatorBuilder. This feature was available for some versions already, but on a different class, this patch simply puts it where it was supposed to be.
Solved issues:
- Issue #49
Changelist:
- Moved
onRemovegetters and setters toPaginatorBuilder. - Fixed typos in javadocs
Pagination Utils 4.0.5b - Menus for everyone
Added support for SelectMenu value retrieval, and fixed the issue where buttons would refuse to work in ephemeral messages. To use SelectMenus with buttonization you must use ButtonizeHelper, or add the components afterwards, but remember to keep the original buttons else the library will clear the components.
It's also possible to retrieve the values from other messages, should you ever need to, this can be done through getDropdownValues() method in MessageHandler (can be found in Pages.getHandler()). To get the event's ID, use getEventId() method in the same class.
Changelist:
- Renamed
MessageHandlertoEventHandler. - Added
InteractionHookto the internal event handler, as you cannot retrieve ephemeral messages. - Added missing javadocs.