aboutsummaryrefslogtreecommitdiffstats
path: root/bot
diff options
context:
space:
mode:
authorGravatar brad90four <[email protected]>2021-09-07 07:48:07 -0400
committerGravatar Chris Lovering <[email protected]>2021-10-05 16:41:43 +0100
commit0862f56c56ebf2be46b2eb2ee66af52f5c12d70c (patch)
tree46f0f29a0e3e5229af9cb2d9f72b32ffc62e8d30 /bot
parentFixing flake8 errors, code style (diff)
Add embed fields for Hex and RGB
Diffstat (limited to 'bot')
-rw-r--r--bot/exts/utilities/color.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/bot/exts/utilities/color.py b/bot/exts/utilities/color.py
index b1a77b28..b1b423e7 100644
--- a/bot/exts/utilities/color.py
+++ b/bot/exts/utilities/color.py
@@ -73,6 +73,16 @@ class Color(commands.Cog):
file = await self._create_thumbnail_attachment(rgb_color)
main_embed.set_thumbnail(url="attachment://color.png")
+ main_embed.add_field(
+ name="Hex",
+ value=f">>Hex #{hex_color}",
+ inline=False,
+ )
+ main_embed.add_field(
+ name="RGB",
+ value=f">>RGB {rgb_color}",
+ inline=False,
+ )
await ctx.send(file=file, embed=main_embed)
async def _create_thumbnail_attachment(self, color: str) -> File: