Removes the unnecessary display of manual command input in the book menu
All checks were successful
EpicKnarvik97/Books-Without-Borders/pipeline/head This commit looks good

This commit is contained in:
2025-08-02 06:52:23 +02:00
parent a5be6bb72c
commit b9bd686ae9

View File

@@ -179,8 +179,7 @@ public final class BookFileHelper {
String fullCommand = "/" + command + " page" + (page - 1); String fullCommand = "/" + command + " page" + (page - 1);
HoverEvent prevPagePreview = new HoverEvent(HoverEvent.Action.SHOW_TEXT, new Text("To page " + (page - 1))); HoverEvent prevPagePreview = new HoverEvent(HoverEvent.Action.SHOW_TEXT, new Text("To page " + (page - 1)));
ClickEvent prevPageClick = new ClickEvent(ClickEvent.Action.RUN_COMMAND, fullCommand); ClickEvent prevPageClick = new ClickEvent(ClickEvent.Action.RUN_COMMAND, fullCommand);
previousComponent.append("Previous [<]").event(prevPagePreview).event(prevPageClick).append(" " + previousComponent.append("Previous [<]").event(prevPagePreview).event(prevPageClick);
ChatColor.DARK_GRAY + fullCommand, ComponentBuilder.FormatRetention.NONE);
} else { } else {
previousComponent.append("Previous [<]").color(ChatColor.GRAY); previousComponent.append("Previous [<]").color(ChatColor.GRAY);
} }
@@ -212,8 +211,7 @@ public final class BookFileHelper {
String fullCommand = "/" + command + " page" + (page + 1); String fullCommand = "/" + command + " page" + (page + 1);
HoverEvent nextPagePreview = new HoverEvent(HoverEvent.Action.SHOW_TEXT, new Text("To page " + (page + 1))); HoverEvent nextPagePreview = new HoverEvent(HoverEvent.Action.SHOW_TEXT, new Text("To page " + (page + 1)));
ClickEvent nextPageClick = new ClickEvent(ClickEvent.Action.RUN_COMMAND, fullCommand); ClickEvent nextPageClick = new ClickEvent(ClickEvent.Action.RUN_COMMAND, fullCommand);
nextComponent.append("Next [>]").event(nextPagePreview).event(nextPageClick).append(" " + nextComponent.append("Next [>]").event(nextPagePreview).event(nextPageClick);
ChatColor.DARK_GRAY + fullCommand, ComponentBuilder.FormatRetention.NONE);
} else { } else {
nextComponent.append("Next [>]").color(ChatColor.GRAY); nextComponent.append("Next [>]").color(ChatColor.GRAY);
} }