StringSelectMenuBuilder error
error:
Select menu code
data.components[0].components[1][COMPONENT_LAYOUT_WITDH_EXCEEDED]: the specified component exceeds the maximum witdhdata.components[0].components[1][COMPONENT_LAYOUT_WITDH_EXCEEDED]: the specified component exceeds the maximum witdhSelect menu code
const selectMenuOptions = pshipData.pshipTypes.map(category => (
new StringSelectMenuOptionBuilder()
.setLabel(category.categoryName)
.setValue(category.categoryName)
));
const selectMenu = new StringSelectMenuBuilder()
.setCustomId('category_select')
.setPlaceholder('Select a category')
.addOptions(...selectMenuOptions);
// a button to save and create
const button = new ButtonBuilder()
.setCustomId('save_button')
.setLabel('Save & Create')
.setStyle(ButtonStyle.Success);
// an action row with select menu and button
const row = new ActionRowBuilder()
.setComponents(selectMenu, button);const selectMenuOptions = pshipData.pshipTypes.map(category => (
new StringSelectMenuOptionBuilder()
.setLabel(category.categoryName)
.setValue(category.categoryName)
));
const selectMenu = new StringSelectMenuBuilder()
.setCustomId('category_select')
.setPlaceholder('Select a category')
.addOptions(...selectMenuOptions);
// a button to save and create
const button = new ButtonBuilder()
.setCustomId('save_button')
.setLabel('Save & Create')
.setStyle(ButtonStyle.Success);
// an action row with select menu and button
const row = new ActionRowBuilder()
.setComponents(selectMenu, button);