From 840cca672d681c36f980a06fb79a4e2c01bd69ac Mon Sep 17 00:00:00 2001 From: IRONM00N <64110067+IRONM00N@users.noreply.github.com> Date: Tue, 25 Jan 2022 23:47:40 -0500 Subject: I love breaking changes!!!! --- src/commands/info/color.ts | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'src/commands/info/color.ts') diff --git a/src/commands/info/color.ts b/src/commands/info/color.ts index d385c53..0e1be81 100644 --- a/src/commands/info/color.ts +++ b/src/commands/info/color.ts @@ -9,7 +9,7 @@ import { type BushSlashMessage } from '#lib'; import assert from 'assert'; -import { ApplicationCommandOptionType, MessageEmbed, Permissions, Role } from 'discord.js'; +import { ApplicationCommandOptionType, Embed, Permissions, Role } from 'discord.js'; import tinycolor from 'tinycolor2'; assert(tinycolor); @@ -74,12 +74,12 @@ export default class ColorCommand extends BushCommand { }); } - const embed = new MessageEmbed() - .addField('» Hexadecimal', color.toHexString()) - .addField('» Decimal', `${parseInt(color.toHex(), 16)}`) - .addField('» HSL', this.removePrefixAndParenthesis(color.toHslString())) - .addField('» RGB', this.removePrefixAndParenthesis(color.toRgbString())) - .setColor(color.toHex() as `#${string}`); + const embed = new Embed() + .addField({ name: '» Hexadecimal', value: color.toHexString() }) + .addField({ name: '» Decimal', value: `${parseInt(color.toHex(), 16)}` }) + .addField({ name: '» HSL', value: this.removePrefixAndParenthesis(color.toHslString()) }) + .addField({ name: '» RGB', value: this.removePrefixAndParenthesis(color.toRgbString()) }) + .setColor(parseInt(color.toHex(), 16)); return await message.util.reply({ embeds: [embed] }); } -- cgit