fix: reduce quests per page to 5 to stay within Discord's 40 total component limit
All checks were successful
Deploy to Production / test (push) Successful in 39s

Discord counts all nested components (buttons inside action rows)
toward the message-level 40 component cap. 7 per page exceeded this
when pagination buttons were included.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
syntaxbullet
2026-03-28 14:24:53 +01:00
parent e56e133a69
commit 3edda1d707

View File

@@ -43,8 +43,11 @@ const COLORS = {
COMPLETED: 0xf1c40f // Gold - completed
};
// Max quests per page (2 header + 1 page indicator + 7×5 components = 38, Discord max is 40 per container)
const QUESTS_PER_PAGE = 7;
// Max quests per page. Discord counts all nested components toward a 40 total limit:
// Fixed: 1 container + 2 header + 1 nav row + 2 nav buttons + 1 pagination row + 2 pagination buttons = 9
// Per quest (available): 1 separator + 3 text + 1 action row + 1 button = 6
// Budget: 9 + 6×5 = 39 <= 40
const QUESTS_PER_PAGE = 5;
/**
* Formats quest rewards object into a human-readable string