wip embeds

This commit is contained in:
MapleLeaf
2021-12-16 10:10:47 -06:00
parent b7a3be73ee
commit 803252290d
8 changed files with 88 additions and 18 deletions

19
src/components/embed.tsx Normal file
View File

@@ -0,0 +1,19 @@
import type { ColorResolvable } from "discord.js"
import type { ReactNode } from "react"
import * as React from "react"
export type EmbedProps = {
color?: ColorResolvable
children?: ReactNode
}
export function Embed(props: EmbedProps) {
return (
<reacord-element
modifyOptions={(options) => {
options.embeds ??= []
options.embeds.push({ color: props.color })
}}
/>
)
}