feat: enable Display Components V2 and add back navigation button
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "amayo",
|
||||
"version": "0.10.200",
|
||||
"version": "0.10.210",
|
||||
"description": "",
|
||||
"main": "src/main.ts",
|
||||
"scripts": {
|
||||
|
||||
@@ -116,7 +116,8 @@ export const command: CommandMessage = {
|
||||
};
|
||||
|
||||
const demoMessage = await message.reply({
|
||||
flags: 4096, // SuppressEmbeds
|
||||
// Activar Display Components V2 y mantener SuppressEmbeds
|
||||
flags: (32768 | 4096),
|
||||
components: [mainPanel, actionRow]
|
||||
});
|
||||
|
||||
|
||||
@@ -295,7 +295,17 @@ export const command: CommandMessage = {
|
||||
|
||||
await interaction.update({
|
||||
// @ts-ignore
|
||||
components: [blockSelectPanel, blockSelectRow, backRow]
|
||||
components: [blockSelectPanel, blockSelectRow, {
|
||||
type: 1,
|
||||
components: [
|
||||
{
|
||||
type: 2,
|
||||
style: ButtonStyle.Secondary,
|
||||
label: "↩️ Volver al Inicio",
|
||||
custom_id: "back_to_main"
|
||||
}
|
||||
]
|
||||
}]
|
||||
});
|
||||
}
|
||||
break;
|
||||
@@ -528,8 +538,7 @@ export const command: CommandMessage = {
|
||||
case "refresh_status":
|
||||
// Recargar datos y volver al panel principal
|
||||
const refreshedChannels = await client.prisma.allianceChannel.findMany({
|
||||
where: { guildId: message.guildId! },
|
||||
include: { blockConfig: true }
|
||||
where: { guildId: message.guildId! }
|
||||
});
|
||||
|
||||
const refreshedBlocks = await client.prisma.blockV2Config.findMany({
|
||||
|
||||
Reference in New Issue
Block a user