#How can I do buttons IN embeds?

1 messages · Page 1 of 1 (latest)

grave narwhal
#

Like on photo example, can s1 show me example or api reference?

agile hearth
#

that are components v2

#

still not released, if you want to use them you need to install master branch from github

zinc linden
zinc linden
#

I am quite confused by how a embed should be constructed

#

with V2 components

#

@agile hearth

agile hearth
#

the "embed" is not really an embed, rather it's a Container

check the changelog to see all the new components included in components v2, there's also a new example

changelog: https://docs.disnake.dev/en/latest/whats_new.html#new-features
example: https://github.com/DisnakeDev/disnake/blob/master/examples/components_v2.py

GitHub

An API wrapper for Discord written in Python. Contribute to DisnakeDev/disnake development by creating an account on GitHub.

agile hearth
#

did you ping me

#

I can provide more examples but I need time

zinc linden
agile hearth
#

I need to test it but iirc you need to load the files as attachments (so pass them to the attachments keyword of inter.send) and set the media argument of MediaGalleryItem to attachment://<filename> this is actually what happens under the hood with embeds too

#

if you are wondering why it was done like this for components v2 is because we didn't had enough time to add more shortcuts and nice utilities

#

the PR just aimed to add support for components v2

zinc linden
agile hearth
#

I am not at home right now, tomorrow I will provide you some examples

novel horizon
#

the MediaGalleryItem can take a url too

#

-d disnake.MediaGalleryItem

charred pikeBOT
#

await delete(*, reason=None)```
This function is a [*coroutine*](https://docs.python.org/3/library/asyncio-task.html#coroutine).

Deletes the channel.

You must have [`Permissions.manage_channels`](https://docs.disnake.dev/en/latest/api/permissions.html#disnake.Permissions.manage_channels "disnake.Permissions.manage_channels") permission to do this.
novel horizon
#

um.

#

I assume this doesn't work with the latest branch

#

But the docs are pretty understandable

quiet shell