Sup!
I have a code:
class MainPageButtons(discord.ui.View):
@discord.ui.button(label="", style=discord.ButtonStyle.primary)
async def first_but(self, button, interaction):
await interaction.response.send_message("You pressed me!")
@bot.slash_command(
name="test",
description = "test"
)
async def open_shop(ctx: discord.ApplicationContext):
ShopPages = [
Page(
embeds = [discord.Embed(
title="String1",
description="String2",
color=discord.Colour.from_rgb(166, 0 , 255)
)
],
custom_view=MainPageButtons()
),
Page(
embeds = [discord.Embed(
title="String2",
description="String2",
color=discord.Colour.from_rgb(166, 0 , 255)
)
],
custom_view=MainPageButtons()
)
]
paginator = pages.Paginator(pages=ShopPages, custom_view=None)
await paginator.respond(ctx.interaction, ephemeral=False)```
I want to make action on button to move to the specific page via goto_page(). But can not understand how to handle it in this situation. I understand that i should replace wait interaction.response.send_message but no idea how to use this method correctly