misc.wolfram: color

This commit is contained in:
Cynthia Foxwell 2021-07-23 22:16:21 -06:00
parent 3a3e4fc4ad
commit dfef61caa8

View file

@ -2,7 +2,12 @@ const Command = require("../lib/command.js");
const CATEGORY = "misc"; const CATEGORY = "misc";
const fetch = require("node-fetch"); const fetch = require("node-fetch");
const {safeString, parseHtmlEntities} = require("../lib/utils.js"); const {
getTopColor,
pastelize,
safeString,
parseHtmlEntities,
} = require("../lib/utils.js");
const yt = new Command("youtube"); const yt = new Command("youtube");
yt.addAlias("yt"); yt.addAlias("yt");
@ -98,6 +103,7 @@ wolfram.callback = async function (msg, line, verboseFlag, _query) {
if (verbose) { if (verbose) {
const embed = { const embed = {
title: `Result for: \`${safeString(query)}\``, title: `Result for: \`${safeString(query)}\``,
color: getTopColor(msg, hf.bot.user.id, pastelize(hf.bot.user.id)),
fields: [], fields: [],
footer: { footer: {
icon_url: "http://www.wolframalpha.com/share.png", icon_url: "http://www.wolframalpha.com/share.png",