feat(ui): upgrade queue, search, lyrics, and radio embeds

- Transform %queue / %list with Now Playing thumbnail, ranked item cards, and localized footer
- Enhance %search with provider icons, artist metadata, and localized cancel options
- Polish %lyrics with album thumbnail, Synced badge, and structured header
- Redesign %radio directory with command pills and localized pagination controls
- Standardize brand color 0xe9196c across all player commands
- Add complete translations across all 6 locales (en, ar-SA, ckb, tr, de-DE, pt-BR)
This commit is contained in:
NoLogicAlan committed 2026-10-25 03:11:24 +03:00
1 parent b7f20fcb02
commit 2494bf79d6
11 files changed
+156 -69

No files matched your search

+34 -14
View File
@@ -39,9 +39,12 @@ export async function run(message, data) {
const current = p.queue.getCurrent(); const current = p.queue.getCurrent();
const totalTracks = p.queue.size(); const totalTracks = p.queue.size();
const prefix = this.handler.getPrefix(message.message?.guildId ?? message.channel?.guildId) || "%";
if (!current && totalTracks === 0) { if (!current && totalTracks === 0) {
const embed = new EmbedBuilder().setColor(getGlobalColor()).setDescription(this.t(message, "responses.list.empty", { prefix: this.handler.getPrefix(message.message?.guildId ?? message.channel?.guildId) })); const embed = new EmbedBuilder()
.setColor(0xe9196c)
.setDescription(this.t(message, "responses.list.empty", { prefix }));
return message.reply({ embeds: [embed] }); return message.reply({ embeds: [embed] });
} }
@@ -54,23 +57,31 @@ export async function run(message, data) {
const buildEmbed = (page) => { const buildEmbed = (page) => {
const safePage = (isNaN(page) || page < 1) ? 1 : Math.min(Math.floor(page), totalPages); const safePage = (isNaN(page) || page < 1) ? 1 : Math.min(Math.floor(page), totalPages);
const loopState = p.queue.songLoop ? "🔂 Song" : p.queue.loop ? "🔁 Queue" : "🛑 Off"; const loopState = p.queue.songLoop
? `🔂 ${this.t(message, "responses.play.loopSongLabel")}`
: p.queue.loop
? `🔄 ${this.t(message, "responses.play.loopQueueLabel")}`
: this.t(message, "responses.play.loopOffLabel");
let desc = ""; let desc = "";
const remaining = p.getQueueRemainingTime(); const remaining = p.getQueueRemainingTime();
desc += `📋 **${totalTracks} track${totalTracks !== 1 ? "s" : ""} in queue** • ⏱️ \`${remaining}\`\n`; const pluralStr = totalTracks === 1 ? this.t(message, "responses.play.trackSingle") : this.t(message, "responses.play.trackPlural");
const headerStr = this.t(message, "responses.list.tracksCount", { count: totalTracks, plural: pluralStr });
desc += `📋 **${headerStr}** • ⏱️ ` + "`" + remaining + "`" + "\n";
if (current) { if (current) {
const elapsed = p.getCurrentElapsedDuration(); const elapsed = p.getCurrentElapsedDuration();
const total = p.getCurrentDuration(); const total = p.getCurrentDuration();
const link = current.spotifyUrl || current.url || ""; const link = current.spotifyUrl || current.url || "";
let title = current.title ?? "Unknown"; let title = current.title ?? this.t(message, "responses.play.unknownTrack");
if (title.length > 50) title = title.slice(0, 47) + "..."; if (title.length > 50) title = title.slice(0, 47) + "...";
const titleFmt = link ? `[${title}](${link})` : title; const titleFmt = link ? `[${title}](${link})` : title;
const rawAuthor = current.artist || (typeof current.author === "object" ? current.author?.name : current.author);
const authorStr = rawAuthor ? ` • ${rawAuthor}` : "";
desc += "\n" + this.t(message, "responses.list.nowPlaying") + "\n"; desc += `\n▶️ **${this.t(message, "responses.list.nowPlayingHeader")}:**\n`;
desc += `${titleFmt} • \`${elapsed} / ${total}\`\n`; desc += `${titleFmt}${authorStr} • ` + "`" + elapsed + " / " + total + "`" + "\n";
} }
desc += `\n`; desc += `\n`;
@@ -78,26 +89,35 @@ export async function run(message, data) {
if (totalTracks === 0) { if (totalTracks === 0) {
desc += this.t(message, "responses.list.emptyInline"); desc += this.t(message, "responses.list.emptyInline");
} else { } else {
desc += `**${this.t(message, "responses.list.upNextHeader")}:**\n`;
const { items, start } = p.queue.getPage(safePage, PAGE_SIZE); const { items, start } = p.queue.getPage(safePage, PAGE_SIZE);
items.forEach((vid, i) => { items.forEach((vid, i) => {
const index = String(start + i + 1).padStart(2, " "); const index = start + i + 1;
const dur = vid.duration ? p.getDuration(vid.duration) : "?:??"; const dur = vid.duration ? p.getDuration(vid.duration) : "?:??";
const link = vid.spotifyUrl || vid.url || ""; const link = vid.spotifyUrl || vid.url || "";
let title = vid.title ?? "Unknown"; let title = vid.title ?? this.t(message, "responses.play.unknownTrack");
if (title.length > 45) title = title.slice(0, 42) + "..."; if (title.length > 45) title = title.slice(0, 42) + "...";
title = link ? `[${title}](${link})` : title; title = link ? `[${title}](${link})` : title;
const upNext = (start + i === 0) ? " ▶" : ""; const rawAuthor = vid.artist || (typeof vid.author === "object" ? vid.author?.name : vid.author);
desc += `\`${index}.\` ${title}${upNext} • \`${dur}\`\n`; const authorStr = rawAuthor ? ` • ${rawAuthor}` : "";
desc += "`#" + index + "` " + `**${title}**${authorStr} • ` + "`" + dur + "`" + "\n";
}); });
} }
return new EmbedBuilder() const footerText = `${this.t(message, "responses.list.pageFooter", { page: safePage, totalPages, loopState })} • ${this.t(message, "responses.play.controlsHint", { prefix })}`;
.setColor(getGlobalColor())
const builder = new EmbedBuilder()
.setColor(0xe9196c)
.setAuthor({ name: this.t(message, "responses.list.queueTitle") }) .setAuthor({ name: this.t(message, "responses.list.queueTitle") })
.setDescription(desc.trim()) .setDescription(desc.trim())
.setFooter({ text: `Page ${safePage}/${totalPages} • ${loopState}` }) .setFooter({ text: footerText });
;
if (current?.thumbnail) {
builder.setThumbnail(current.thumbnail);
}
return builder;
}; };
new QueuePaginator(message, this.messages, this.client) new QueuePaginator(message, this.messages, this.client)
+16 -14
View File
@@ -143,7 +143,7 @@ export async function run(message, data) {
} else { } else {
current = p?.queue?.getCurrent() ?? null; current = p?.queue?.getCurrent() ?? null;
if (!current) { if (!current) {
const embed = new EmbedBuilder().setColor(getGlobalColor()).setDescription(this.t(message, "responses.lyrics.nothingPlaying")); const embed = new EmbedBuilder().setColor(0xe9196c).setDescription(this.t(message, "responses.lyrics.nothingPlaying"));
return message.reply({ embeds: [embed] }); return message.reply({ embeds: [embed] });
} }
searchTitle = current.title; searchTitle = current.title;
@@ -152,14 +152,14 @@ export async function run(message, data) {
let frame = 0; let frame = 0;
const loadingMsg = await message.reply({ embeds: [ const loadingMsg = await message.reply({ embeds: [
new EmbedBuilder().setColor(getGlobalColor()) new EmbedBuilder().setColor(0xe9196c)
.setDescription(`${LOADING_FRAMES[0]} ` + this.t(message, "responses.lyrics.searching", { title: Utils.truncate(searchTitle, 40) })) .setDescription(`${LOADING_FRAMES[0]} ` + this.t(message, "responses.lyrics.searching", { title: Utils.truncate(searchTitle, 40) }))
] }); ] });
const loadingInterval = setInterval(() => { const loadingInterval = setInterval(() => {
frame = (frame + 1) % LOADING_FRAMES.length; frame = (frame + 1) % LOADING_FRAMES.length;
loadingMsg.edit({ embeds: [ loadingMsg.edit({ embeds: [
new EmbedBuilder().setColor(getGlobalColor()) new EmbedBuilder().setColor(0xe9196c)
.setDescription(`${LOADING_FRAMES[frame]} ` + this.t(message, "responses.lyrics.searching", { title: Utils.truncate(searchTitle, 40) })) .setDescription(`${LOADING_FRAMES[frame]} ` + this.t(message, "responses.lyrics.searching", { title: Utils.truncate(searchTitle, 40) }))
] }).catch(() => {}); ] }).catch(() => {});
}, 800); }, 800);
@@ -176,7 +176,7 @@ export async function run(message, data) {
if (!result || !result.text) { if (!result || !result.text) {
return loadingMsg.edit({ embeds: [ return loadingMsg.edit({ embeds: [
new EmbedBuilder().setColor(getGlobalColor()) new EmbedBuilder().setColor(0xe9196c)
.setDescription( .setDescription(
this.t(message, "responses.lyrics.noLyrics", { title: Utils.truncate(searchTitle, 40) }) this.t(message, "responses.lyrics.noLyrics", { title: Utils.truncate(searchTitle, 40) })
) )
@@ -229,16 +229,17 @@ export async function run(message, data) {
} }
if (totalPages === 1) { if (totalPages === 1) {
const headerLine = `by *${artist}*${syncIndicator}`; const headerLine = `by **${artist}**${syncIndicator ? " • " + syncIndicator : ""}`;
const descBody = pages[0]; const descBody = pages[0];
const singleDesc = [headerLine, "", "```", descBody, "```"].join("\n"); const singleDesc = [headerLine, "", "```", descBody, "```"].join("\n");
const singleEmbed = new EmbedBuilder() const singleEmbed = new EmbedBuilder()
.setColor(getGlobalColor()) .setColor(0xe9196c)
.setTitle(`🎵 ${Utils.truncate(displayTitle, 50)}`) .setAuthor({ name: "🎤 Lyrics" })
.setTitle(Utils.truncate(displayTitle, 50))
.setDescription(singleDesc.slice(0, MAX_DESC)) .setDescription(singleDesc.slice(0, MAX_DESC))
.setFooter({ text: this.t(message, "responses.lyrics.sourceFooter", { source: result.source, lines: totalLines }) }); .setFooter({ text: this.t(message, "responses.lyrics.sourceFooter", { source: result.source, lines: totalLines }) });
if (current.thumbnail) singleEmbed.setThumbnail(current.thumbnail); if (current?.thumbnail) singleEmbed.setThumbnail(current.thumbnail);
return message.reply({ embeds: [singleEmbed] }); return message.reply({ embeds: [singleEmbed] });
} }
@@ -253,18 +254,19 @@ export async function run(message, data) {
* @returns {object} Embed payload for message reply/edit. * @returns {object} Embed payload for message reply/edit.
*/ */
const buildContent = (pageIdx, expired = false) => { const buildContent = (pageIdx, expired = false) => {
const headerLine = `by *${artist}*${syncIndicator} • Page ${pageIdx + 1}/${totalPages}`; const headerLine = `by **${artist}**${syncIndicator ? " • " + syncIndicator : ""} • Page ${pageIdx + 1}/${totalPages}`;
const descBody = pages[pageIdx]; const descBody = pages[pageIdx];
const desc = [headerLine, "", "```", descBody, "```"].join("\n"); const desc = [headerLine, "", "```", descBody, "```"].join("\n");
const b = new EmbedBuilder() const b = new EmbedBuilder()
.setColor(getGlobalColor()) .setColor(0xe9196c)
.setTitle(`🎵 ${Utils.truncate(displayTitle, 50)}`) .setAuthor({ name: "🎤 Lyrics" })
.setTitle(Utils.truncate(displayTitle, 50))
.setDescription(desc.slice(0, MAX_DESC)) .setDescription(desc.slice(0, MAX_DESC))
.setFooter({ text: expired .setFooter({ text: expired
? this.t(message, "responses.lyrics.controlsExpired", { lines: totalLines }) ? this.t(message, "responses.lyrics.controlsExpired", { lines: totalLines })
: this.t(message, "responses.lyrics.sourceFooter", { source: result.source, lines: totalLines }) }); : this.t(message, "responses.lyrics.sourceFooter", { source: result.source, lines: totalLines }) });
if (current.thumbnail) b.setThumbnail(current.thumbnail); if (current?.thumbnail) b.setThumbnail(current.thumbnail);
return { embeds: [b] }; return { embeds: [b] };
}; };
@@ -322,7 +324,7 @@ export async function run(message, data) {
const closedHeader = `by *${artist}*${syncIndicator} • Page ${currentPage + 1}/${totalPages}`; const closedHeader = `by *${artist}*${syncIndicator} • Page ${currentPage + 1}/${totalPages}`;
const closedDesc = [closedHeader, "", "```", pages[currentPage], "```"].join("\n"); const closedDesc = [closedHeader, "", "```", pages[currentPage], "```"].join("\n");
const closedEmbed = new EmbedBuilder() const closedEmbed = new EmbedBuilder()
.setColor(getGlobalColor()) .setColor(0xe9196c)
.setTitle(`🎵 ${Utils.truncate(displayTitle, 50)}`) .setTitle(`🎵 ${Utils.truncate(displayTitle, 50)}`)
.setDescription(closedDesc.slice(0, MAX_DESC)) .setDescription(closedDesc.slice(0, MAX_DESC))
.setFooter({ text: this.t(message, "responses.lyrics.sessionClosed", { lines: totalLines }) }); .setFooter({ text: this.t(message, "responses.lyrics.sessionClosed", { lines: totalLines }) });
@@ -332,6 +334,6 @@ export async function run(message, data) {
} catch (err) { } catch (err) {
clearInterval(loadingInterval); clearInterval(loadingInterval);
logger.error("[Lyrics Command] Error:", err); logger.error("[Lyrics Command] Error:", err);
loadingMsg.edit({ embeds: [new EmbedBuilder().setColor(getGlobalColor()).setDescription(this.t(message, "responses.lyrics.error", { error: Utils.truncate(err.message, 100) }))] }).catch(() => {}); loadingMsg.edit({ embeds: [new EmbedBuilder().setColor(0xe9196c).setDescription(this.t(message, "responses.lyrics.error", { error: Utils.truncate(err.message, 100) }))] }).catch(() => {});
} }
} }
+4 -4
View File
@@ -53,9 +53,9 @@ export function buildPlayerEmbed(bot, msg, player, timeout, state = {}) {
let filterStatus = bot.t(msg, "responses.player.filterOff"); let filterStatus = bot.t(msg, "responses.player.filterOff");
if (player.activeFilter) { if (player.activeFilter) {
if (player.activeFilter.label.includes("+")) { if (player.activeFilter.label.includes("+")) {
filterStatus = `🔥 **${player.activeFilter.label}**`; filterStatus = bot.t(msg, "responses.player.filterStacked", { label: player.activeFilter.label });
} else { } else {
filterStatus = `${player.activeFilter.emoji ?? "🎛️"} **${player.activeFilter.label}**`; filterStatus = bot.t(msg, "responses.player.filterActive", { emoji: player.activeFilter.emoji ?? "🎛️", label: player.activeFilter.label });
} }
} }
@@ -71,7 +71,7 @@ export function buildPlayerEmbed(bot, msg, player, timeout, state = {}) {
`${timeDisplay}`, `${timeDisplay}`,
``, ``,
bot.t(msg, "responses.player.volumeLabel", { volume: volPercent }) + " " + volumeBar, bot.t(msg, "responses.player.volumeLabel", { volume: volPercent }) + " " + volumeBar,
`${bot.t(msg, "responses.player.queueLabel", { count: queueSize })} | Loop: ${loopStatus} | Filter: ${filterStatus}`, `${bot.t(msg, "responses.player.queueLabel", { count: queueSize })} • ${loopStatus} • ${filterStatus}`,
``, ``,
state.message ? `💬 *${state.message}*` : `💡 *${bot.t(msg, "responses.player.reactHint")}*`, state.message ? `💬 *${state.message}*` : `💡 *${bot.t(msg, "responses.player.reactHint")}*`,
``, ``,
@@ -83,7 +83,7 @@ export function buildPlayerEmbed(bot, msg, player, timeout, state = {}) {
: msg.author?.avatarURL ?? null; : msg.author?.avatarURL ?? null;
const builder = new EmbedBuilder() const builder = new EmbedBuilder()
.setColor(getGlobalColor()) .setColor(0xe9196c)
.setTitle(bot.t(msg, "responses.player.title")) .setTitle(bot.t(msg, "responses.player.title"))
.setDescription(description) .setDescription(description)
.setFooter({ .setFooter({
+20 -7
View File
@@ -50,17 +50,29 @@ export async function run(msg, data) {
const buildPage = () => { const buildPage = () => {
const start = page * perPage; const start = page * perPage;
const pickable = radios.slice(start, start + perPage); const pickable = radios.slice(start, start + perPage);
const prefix = this.handler.getPrefix(msg.message?.guildId ?? msg.channel?.guildId) || "%";
let desc = `📻 **Radio Stations (Page ${page + 1}/${totalPages})**\n\n`; let desc = "";
pickable.forEach((r, i) => { pickable.forEach((r, i) => {
const displayName = r.detailedName ?? r.name ?? "Station"; const displayName = r.detailedName ?? r.name ?? "Station";
const stationDesc = String(r.description ?? "").replaceAll("\n", "\n "); const stationDesc = String(r.description ?? "").replaceAll("\n", "\n ");
desc += `${NUMBER_EMOJIS[i]} **${displayName}** (\`${r.name ?? "station"}\`)\n`; desc += `${NUMBER_EMOJIS[i]} **${displayName}** (\`${prefix}radio ${r.name ?? "station"}\`)\n`;
desc += ` ${stationDesc}\n\n`; if (stationDesc) desc += ` ${stationDesc}\n\n`;
else desc += "\n";
}); });
desc += `⬅️ Previous ➡️ Next ❌ Cancel`;
return { payload: { embeds: [new EmbedBuilder().setColor(getGlobalColor()).setDescription(desc)] }, pickable }; const authorName = this.t(msg, "responses.radio.stationsAuthor") || "24/7 Radio Station Directory";
const titleName = this.t(msg, "responses.radio.stationsTitle", { page: page + 1, total: totalPages });
const footerText = this.t(msg, "responses.radio.prevNext");
const embed = new EmbedBuilder()
.setColor(0xe9196c)
.setAuthor({ name: authorName })
.setTitle(titleName)
.setDescription(desc.trim())
.setFooter({ text: footerText });
return { payload: { embeds: [embed] }, pickable };
}; };
let { payload, pickable } = buildPage(); let { payload, pickable } = buildPage();
@@ -165,13 +177,14 @@ async function playStation(ctx, msg, radio, editTarget = null) {
const stationLine = stationUrl const stationLine = stationUrl
? `**[${stationName}](${stationUrl})**\n\n` ? `**[${stationName}](${stationUrl})**\n\n`
: `**${stationName}**\n\n`; : `**${stationName}**\n\n`;
const skipHint = ctx.t(msg, "responses.radio.skipHint", { prefix }) || `_Use \`${prefix}skip\` to stop the radio, or \`${prefix}radio list\` to switch stations._`;
const embed = new EmbedBuilder() const embed = new EmbedBuilder()
.setColor(getGlobalColor()) .setColor(0xe9196c)
.setTitle(`📻 ${stationName}`) .setTitle(`📻 ${stationName}`)
.setDescription( .setDescription(
stationLine + stationLine +
`${stationDesc}\n\n` + `${stationDesc}\n\n` +
`_Use \`${prefix}skip\` to stop the radio, or \`${prefix}radio list\` to switch stations._` skipHint
) )
; ;
+28 -12
View File
@@ -8,6 +8,7 @@ import { Message, getGlobalColor } from "../src/ui/index.mjs";
import { EmbedBuilder } from "@fluxerjs/core"; import { EmbedBuilder } from "@fluxerjs/core";
import { PROVIDER_CHOICES, PROVIDER_NAMES, parseInlineProvider } from "../src/music/providers.mjs"; import { PROVIDER_CHOICES, PROVIDER_NAMES, parseInlineProvider } from "../src/music/providers.mjs";
import { NUMBER_EMOJIS, CANCEL_EMOJI } from "../src/utils/UI.mjs"; import { NUMBER_EMOJIS, CANCEL_EMOJI } from "../src/utils/UI.mjs";
import { Utils } from "../src/utils/Utils.mjs";
import { logger } from "../src/core/Logger.mjs"; import { logger } from "../src/core/Logger.mjs";
/** @type {CommandBuilder} @description Command definition for the search command. */ /** @type {CommandBuilder} @description Command definition for the search command. */
@@ -61,26 +62,35 @@ export async function run(msg, data) {
const channel = msg.channel?.channel ?? msg.message?.channel; const channel = msg.channel?.channel ?? msg.message?.channel;
if (!channel?.send) return; if (!channel?.send) return;
let providerIcon = "🔍";
if (provider === "sp" || provider === "spotify") providerIcon = "🟢";
else if (provider === "sc" || provider === "soundcloud") providerIcon = "🟠";
else if (provider === "yt" || provider === "ytm" || provider === "youtube") providerIcon = "▶️";
const authorTitle = `${providerIcon} ${this.t(msg, "responses.search.resultsTitle", { provider: name })}`;
/** /**
* @private * @private
* Build a search result embed. * Build a search result embed.
* @param {string} description - The embed description text. * @param {string} description - The embed description text.
* @param {string|null} footerText - Optional footer text. * @param {string|null} footerText - Optional footer text.
* @param {string} [authorLabel=name] - The author field label (provider name). * @param {string} [authorLabel=authorTitle] - The author field label.
* @param {string|null} [thumbnail=null] - Optional thumbnail URL.
* @returns {EmbedBuilder} The constructed embed. * @returns {EmbedBuilder} The constructed embed.
*/ */
const makeEmbed = (description, footerText, authorLabel = name) => { const makeEmbed = (description, footerText, authorLabel = authorTitle, thumbnail = null) => {
const b = new EmbedBuilder() const b = new EmbedBuilder()
.setColor(getGlobalColor()) .setColor(0xe9196c)
.setAuthor({ name: authorLabel }) .setAuthor({ name: authorLabel })
.setDescription(description); .setDescription(description);
if (thumbnail) b.setThumbnail(thumbnail);
if (footerText) b.setFooter({ text: footerText }); if (footerText) b.setFooter({ text: footerText });
return b; return b;
}; };
const nativeMsg = msg.message ?? msg; const nativeMsg = msg.message ?? msg;
const rawMsg = await nativeMsg.reply( const rawMsg = await nativeMsg.reply(
{ embeds: [makeEmbed(this.t(msg, "responses.search.loadingResults"), this.t(msg, "responses.play.searchingProvider", { provider: name }), this.t(msg, "responses.search.resultsTitle", { provider: name }))]}, { embeds: [makeEmbed(this.t(msg, "responses.search.loadingResults"), this.t(msg, "responses.play.searchingProvider", { provider: name }), authorTitle)]},
{ ping: false } { ping: false }
).catch(() => null); ).catch(() => null);
if (!rawMsg) return; if (!rawMsg) return;
@@ -94,20 +104,25 @@ export async function run(msg, data) {
const results = p.searches.get(msg.authorId) ?? []; const results = p.searches.get(msg.authorId) ?? [];
const reactions = NUMBER_EMOJIS.slice(0, res.count); const reactions = NUMBER_EMOJIS.slice(0, res.count);
const cancelText = this.t(msg, "responses.search.cancelOption") || "Cancel";
let desc = ""; let desc = "";
results.forEach((v, i) => { results.forEach((v, i) => {
const dur = v.duration ? p.getDuration(v.duration) : "?:??"; const dur = v.duration ? p.getDuration(v.duration) : "?:??";
const title = v.title || "Unknown"; const rawAuthor = v.artist || (typeof v.author === "object" ? v.author?.name : v.author);
const authorStr = rawAuthor ? ` • ${Utils.truncate(rawAuthor, 30)}` : "";
const title = Utils.truncate(v.title || this.t(msg, "responses.play.unknownTrack"), 50);
const url = v.url || ""; const url = v.url || "";
desc += `${NUMBER_EMOJIS[i]} [${title}](${url}) — \`${dur}\`\n`; const titleFmt = url ? `[${title}](${url})` : title;
desc += `${NUMBER_EMOJIS[i]} **${titleFmt}**${authorStr} • \`${dur}\`\n\n`;
}); });
desc += `\n${CANCEL_EMOJI} Cancel`; desc += `${CANCEL_EMOJI} ${cancelText}`;
await rawMsg.edit({ await rawMsg.edit({
embeds: [makeEmbed( embeds: [makeEmbed(
desc, desc.trim(),
this.t(msg, "responses.search.reactHint"), this.t(msg, "responses.search.reactHint"),
this.t(msg, "responses.search.resultsTitle", { provider: name }) authorTitle,
results[0]?.thumbnail || null
)] )]
}).catch(() => {}); }).catch(() => {});
@@ -145,7 +160,7 @@ export async function run(msg, data) {
if (e.emoji_id === CANCEL_EMOJI) { if (e.emoji_id === CANCEL_EMOJI) {
p.searches.delete(msg.authorId); p.searches.delete(msg.authorId);
rawMsg.edit({ rawMsg.edit({
embeds: [makeEmbed(this.t(msg, "responses.search.cancelled"), null, this.t(msg, "responses.search.resultsTitle", { provider: name }))] embeds: [makeEmbed(this.t(msg, "responses.search.cancelled"), null, authorTitle)]
}).catch(() => {}); }).catch(() => {});
return; return;
} }
@@ -160,7 +175,8 @@ export async function run(msg, data) {
embeds: [makeEmbed( embeds: [makeEmbed(
this.t(msg, "responses.search.added", { title: v.title, url: v.url }), this.t(msg, "responses.search.added", { title: v.title, url: v.url }),
null, null,
this.t(msg, "responses.search.resultsTitle", { provider: name }) authorTitle,
v.thumbnail || null
)] )]
}).catch(() => {}); }).catch(() => {});
}); });
@@ -171,7 +187,7 @@ export async function run(msg, data) {
p.searches.delete(msg.authorId); p.searches.delete(msg.authorId);
clearReactions().catch(() => {}); clearReactions().catch(() => {});
rawMsg.edit({ rawMsg.edit({
embeds: [makeEmbed(this.t(msg, "responses.search.timedOut"), this.t(msg, "responses.search.sessionClosed"), this.t(msg, "responses.search.resultsTitle", { provider: name }))] embeds: [makeEmbed(this.t(msg, "responses.search.timedOut"), this.t(msg, "responses.search.sessionClosed"), authorTitle)]
}).catch(() => {}); }).catch(() => {});
}, SESSION_MS); }, SESSION_MS);
} }
+9 -3
View File
@@ -327,7 +327,11 @@
"nowPlaying": "🎵 **يعمل حالياً**", "nowPlaying": "🎵 **يعمل حالياً**",
"header": "📋 **{{count}} مقطع في قائمة الانتظار** • ⏱️ `{{time}}`", "header": "📋 **{{count}} مقطع في قائمة الانتظار** • ⏱️ `{{time}}`",
"upNext": " ▶", "upNext": " ▶",
"queueTitle": "🎧 قائمة الانتظار" "queueTitle": "🎧 قائمة الانتظار",
"tracksCount": "{{count}} {{plural}} في قائمة الانتظار",
"nowPlayingHeader": "يتم تشغيله الآن",
"upNextHeader": "التالي",
"pageFooter": "صفحة {{page}}/{{totalPages}} • التكرار: {{loopState}}"
}, },
"queue": { "queue": {
"empty": "قائمة الانتظار فارغة.", "empty": "قائمة الانتظار فارغة.",
@@ -500,7 +504,8 @@
"unknownStation": "❌ محطة غير معروفة `{{station}}`. المتاحة: {{stations}}\n\nاستخدم `$prefixradio list` للتصفح.", "unknownStation": "❌ محطة غير معروفة `{{station}}`. المتاحة: {{stations}}\n\nاستخدم `$prefixradio list` للتصفح.",
"nowPlaying": "📻 بث مباشر _{{title}}_ لـ [{{author}}]({{url}}) في <#{{channel}}>", "nowPlaying": "📻 بث مباشر _{{title}}_ لـ [{{author}}]({{url}}) في <#{{channel}}>",
"skipHint": "_استخدم `$prefixskip` لإيقاف الإذاعة، أو `$prefixradio list` لتبديل المحطات._", "skipHint": "_استخدم `$prefixskip` لإيقاف الإذاعة، أو `$prefixradio list` لتبديل المحطات._",
"prevNext": "⬅️ السابق ➡️ التالي ❌ إلغاء" "prevNext": "⬅️ السابق ➡️ التالي ❌ إلغاء",
"stationsAuthor": "دليل محطات الراديو 24/7"
}, },
"reload": { "reload": {
"indexNoReload": "❌ لا يمكن إعادة تحميل `index.mjs` — قم بإعادة تشغيل كاملة.", "indexNoReload": "❌ لا يمكن إعادة تحميل `index.mjs` — قم بإعادة تشغيل كاملة.",
@@ -533,7 +538,8 @@
"cancelled": "❌ تم الإلغاء.", "cancelled": "❌ تم الإلغاء.",
"added": "✅ تمت إضافة [{{title}}]({{url}}) إلى قائمة الانتظار!", "added": "✅ تمت إضافة [{{title}}]({{url}}) إلى قائمة الانتظار!",
"timedOut": "⏰ انتهت مهلة البحث.", "timedOut": "⏰ انتهت مهلة البحث.",
"sessionClosed": "تم إغلاق الجلسة" "sessionClosed": "تم إغلاق الجلسة",
"cancelOption": "إلغاء"
}, },
"servers": { "servers": {
"noServers": "_لم يتم العثور على خوادم._", "noServers": "_لم يتم العثور على خوادم._",
+9 -3
View File
@@ -327,7 +327,11 @@
"nowPlaying": "🎵 **ئێستا پەخش دەکرێت**", "nowPlaying": "🎵 **ئێستا پەخش دەکرێت**",
"header": "📋 **{{count}} تراک لە ڕیزبەندییەکەدا** • ⏱️ `{{time}}`", "header": "📋 **{{count}} تراک لە ڕیزبەندییەکەدا** • ⏱️ `{{time}}`",
"upNext": " ▶", "upNext": " ▶",
"queueTitle": "🎧 ڕیزبەندی" "queueTitle": "🎧 ڕیزبەندی",
"tracksCount": "{{count}} {{plural}} لە ڕیزبەندی",
"nowPlayingHeader": "ئێستا لێدەدرێت",
"upNextHeader": "دواتر",
"pageFooter": "پەڕە {{page}}/{{totalPages}} • دووبارەکردنەوە: {{loopState}}"
}, },
"queue": { "queue": {
"empty": "ڕیزبەندییەکە بەتاڵە.", "empty": "ڕیزبەندییەکە بەتاڵە.",
@@ -500,7 +504,8 @@
"unknownStation": "❌ ستەیشنی نەناسراو `{{station}}`. بەردەستەکان: {{stations}}\n\n`$prefixradio list` بەکاربهێنە بۆ بینین.", "unknownStation": "❌ ستەیشنی نەناسراو `{{station}}`. بەردەستەکان: {{stations}}\n\n`$prefixradio list` بەکاربهێنە بۆ بینین.",
"nowPlaying": "📻 پەخشی ڕاستەوخۆ _{{title}}_ لەلایەن [{{author}}]({{url}}) لە <#{{channel}}>", "nowPlaying": "📻 پەخشی ڕاستەوخۆ _{{title}}_ لەلایەن [{{author}}]({{url}}) لە <#{{channel}}>",
"skipHint": "_`$prefixskip` بەکاربهێنە بۆ وەستاندنی ڕادیۆ، یان `$prefixradio list` بۆ گۆڕینی ستەیشنەکان._", "skipHint": "_`$prefixskip` بەکاربهێنە بۆ وەستاندنی ڕادیۆ، یان `$prefixradio list` بۆ گۆڕینی ستەیشنەکان._",
"prevNext": "⬅️ پێشوو ➡️ دواتر ❌ پاشگەزبوونەوە" "prevNext": "⬅️ پێشوو ➡️ دواتر ❌ پاشگەزبوونەوە",
"stationsAuthor": "ڕێبەری وێستگەکانی ڕادیۆ ٢٤/٧"
}, },
"reload": { "reload": {
"indexNoReload": "❌ `index.mjs` ناتوانرێت بارکردنەوەی خێرا بکات — سەرەتا دەستپێکردنەوەی تەواو بکە.", "indexNoReload": "❌ `index.mjs` ناتوانرێت بارکردنەوەی خێرا بکات — سەرەتا دەستپێکردنەوەی تەواو بکە.",
@@ -533,7 +538,8 @@
"cancelled": "❌ هەڵوەشایەوە.", "cancelled": "❌ هەڵوەشایەوە.",
"added": "✅ [{{title}}]({{url}}) **زیادکرا بۆ ڕیزبەندییەکە!**", "added": "✅ [{{title}}]({{url}}) **زیادکرا بۆ ڕیزبەندییەکە!**",
"timedOut": "⏰ کاتی گەڕان تەواو بوو.", "timedOut": "⏰ کاتی گەڕان تەواو بوو.",
"sessionClosed": "دانیشتن داخرا" "sessionClosed": "دانیشتن داخرا",
"cancelOption": "هەڵوەشاندنەوە"
}, },
"servers": { "servers": {
"noServers": "_هیچ سێرڤەرێک نەدۆزرایەوە._", "noServers": "_هیچ سێرڤەرێک نەدۆزرایەوە._",
+9 -3
View File
@@ -327,7 +327,11 @@
"nowPlaying": "🎵 **Spielt gerade**", "nowPlaying": "🎵 **Spielt gerade**",
"header": "📋 **{{count}} Tracks in der Warteschlange** • ⏱️ `{{time}}`", "header": "📋 **{{count}} Tracks in der Warteschlange** • ⏱️ `{{time}}`",
"upNext": " ▶", "upNext": " ▶",
"queueTitle": "🎧 Warteschlange" "queueTitle": "🎧 Warteschlange",
"tracksCount": "{{count}} {{plural}} in der Warteschlange",
"nowPlayingHeader": "Aktuelle Wiedergabe",
"upNextHeader": "Als Nächstes",
"pageFooter": "Seite {{page}}/{{totalPages}} • Schleife: {{loopState}}"
}, },
"queue": { "queue": {
"empty": "Die Warteschlange ist leer.", "empty": "Die Warteschlange ist leer.",
@@ -500,7 +504,8 @@
"unknownStation": "❌ Unbekannter Sender `{{station}}`. Verfügbar: {{stations}}\n\nNutze `$prefixradio list` zum Durchsuchen.", "unknownStation": "❌ Unbekannter Sender `{{station}}`. Verfügbar: {{stations}}\n\nNutze `$prefixradio list` zum Durchsuchen.",
"nowPlaying": "📻 Streamt jetzt _{{title}}_ von [{{author}}]({{url}}) in <#{{channel}}>", "nowPlaying": "📻 Streamt jetzt _{{title}}_ von [{{author}}]({{url}}) in <#{{channel}}>",
"skipHint": "_Nutze `$prefixskip`, um das Radio zu stoppen, oder `$prefixradio list`, um Sender zu wechseln._", "skipHint": "_Nutze `$prefixskip`, um das Radio zu stoppen, oder `$prefixradio list`, um Sender zu wechseln._",
"prevNext": "⬅️ Zurück ➡️ Weiter ❌ Abbrechen" "prevNext": "⬅️ Zurück ➡️ Weiter ❌ Abbrechen",
"stationsAuthor": "24/7 Radiosender-Verzeichnis"
}, },
"reload": { "reload": {
"indexNoReload": "❌ `index.mjs` kann nicht neu geladen werden — führe einen vollständigen Neustart durch.", "indexNoReload": "❌ `index.mjs` kann nicht neu geladen werden — führe einen vollständigen Neustart durch.",
@@ -533,7 +538,8 @@
"cancelled": "❌ Abgebrochen.", "cancelled": "❌ Abgebrochen.",
"added": "✅ [{{title}}]({{url}}) zur Warteschlange hinzugefügt!", "added": "✅ [{{title}}]({{url}}) zur Warteschlange hinzugefügt!",
"timedOut": "⏰ Suche abgelaufen.", "timedOut": "⏰ Suche abgelaufen.",
"sessionClosed": "Sitzung geschlossen" "sessionClosed": "Sitzung geschlossen",
"cancelOption": "Abbrechen"
}, },
"servers": { "servers": {
"noServers": "_Keine Server gefunden._", "noServers": "_Keine Server gefunden._",
+9 -3
View File
@@ -436,7 +436,11 @@
"nowPlaying": "🎵 **Now Playing**", "nowPlaying": "🎵 **Now Playing**",
"header": "📋 **{{count}} tracks in queue** • ⏱️ `{{time}}`", "header": "📋 **{{count}} tracks in queue** • ⏱️ `{{time}}`",
"upNext": " ▶", "upNext": " ▶",
"queueTitle": "🎧 Queue" "queueTitle": "🎧 Queue",
"tracksCount": "{{count}} {{plural}} in queue",
"nowPlayingHeader": "Now Playing",
"upNextHeader": "Up Next",
"pageFooter": "Page {{page}}/{{totalPages}} • Loop: {{loopState}}"
}, },
"loop": { "loop": {
"invalidChoice": "'{{choice}}' is not valid. Use `song` or `queue`", "invalidChoice": "'{{choice}}' is not valid. Use `song` or `queue`",
@@ -617,7 +621,8 @@
"unknownStation": "❌ Unknown station `{{station}}`. Available: {{stations}}\n\nUse `$prefixradio list` to browse.", "unknownStation": "❌ Unknown station `{{station}}`. Available: {{stations}}\n\nUse `$prefixradio list` to browse.",
"nowPlaying": "📻 Now streaming _{{title}}_ by [{{author}}]({{url}}) in <#{{channel}}>", "nowPlaying": "📻 Now streaming _{{title}}_ by [{{author}}]({{url}}) in <#{{channel}}>",
"skipHint": "_Use `$prefixskip` to stop the radio, or `$prefixradio list` to switch stations._", "skipHint": "_Use `$prefixskip` to stop the radio, or `$prefixradio list` to switch stations._",
"prevNext": "⬅️ Previous ➡️ Next ❌ Cancel" "prevNext": "⬅️ Previous ➡️ Next ❌ Cancel",
"stationsAuthor": "24/7 Radio Station Directory"
}, },
"reload": { "reload": {
"indexNoReload": "❌ `index.mjs` cannot be hot-reloaded — do a full restart.", "indexNoReload": "❌ `index.mjs` cannot be hot-reloaded — do a full restart.",
@@ -650,7 +655,8 @@
"cancelled": "❌ Cancelled.", "cancelled": "❌ Cancelled.",
"added": "✅ Added [{{title}}]({{url}}) to the queue!", "added": "✅ Added [{{title}}]({{url}}) to the queue!",
"timedOut": "⏰ Search timed out.", "timedOut": "⏰ Search timed out.",
"sessionClosed": "Session closed" "sessionClosed": "Session closed",
"cancelOption": "Cancel"
}, },
"servers": { "servers": {
"noServers": "_No servers found._", "noServers": "_No servers found._",
+9 -3
View File
@@ -327,7 +327,11 @@
"nowPlaying": "🎵 **Tocando Agora**", "nowPlaying": "🎵 **Tocando Agora**",
"header": "📋 **{{count}} faixas na fila** • ⏱️ `{{time}}`", "header": "📋 **{{count}} faixas na fila** • ⏱️ `{{time}}`",
"upNext": " ▶", "upNext": " ▶",
"queueTitle": "🎧 Fila" "queueTitle": "🎧 Fila",
"tracksCount": "{{count}} {{plural}} na fila",
"nowPlayingHeader": "Tocando Agora",
"upNextHeader": "A Seguir",
"pageFooter": "Página {{page}}/{{totalPages}} • Repetição: {{loopState}}"
}, },
"queue": { "queue": {
"empty": "A fila está vazia.", "empty": "A fila está vazia.",
@@ -500,7 +504,8 @@
"unknownStation": "❌ Estação desconhecida `{{station}}`. Disponíveis: {{stations}}\n\nUse `$prefixradio list` para navegar.", "unknownStation": "❌ Estação desconhecida `{{station}}`. Disponíveis: {{stations}}\n\nUse `$prefixradio list` para navegar.",
"nowPlaying": "📻 Transmitindo agora _{{title}}_ por [{{author}}]({{url}}) em <#{{channel}}>", "nowPlaying": "📻 Transmitindo agora _{{title}}_ por [{{author}}]({{url}}) em <#{{channel}}>",
"skipHint": "_Use `$prefixskip` para parar o rádio ou `$prefixradio list` para trocar de estação._", "skipHint": "_Use `$prefixskip` para parar o rádio ou `$prefixradio list` para trocar de estação._",
"prevNext": "⬅️ Anterior ➡️ Próximo ❌ Cancelar" "prevNext": "⬅️ Anterior ➡️ Próximo ❌ Cancelar",
"stationsAuthor": "Diretório de Rádios 24/7"
}, },
"reload": { "reload": {
"indexNoReload": "❌ `index.mjs` não pode ser recarregado — faça uma reinicialização completa.", "indexNoReload": "❌ `index.mjs` não pode ser recarregado — faça uma reinicialização completa.",
@@ -533,7 +538,8 @@
"cancelled": "❌ Cancelado.", "cancelled": "❌ Cancelado.",
"added": "✅ [{{title}}]({{url}}) adicionado à fila!", "added": "✅ [{{title}}]({{url}}) adicionado à fila!",
"timedOut": "⏰ Tempo de busca esgotado.", "timedOut": "⏰ Tempo de busca esgotado.",
"sessionClosed": "Sessão encerrada" "sessionClosed": "Sessão encerrada",
"cancelOption": "Cancelar"
}, },
"servers": { "servers": {
"noServers": "_Nenhum servidor encontrado._", "noServers": "_Nenhum servidor encontrado._",
+9 -3
View File
@@ -433,7 +433,11 @@
"nowPlaying": "🎵 **Şu An Çalıyor**", "nowPlaying": "🎵 **Şu An Çalıyor**",
"header": "📋 **Kuyrukta {{count}} parça** • ⏱️ `{{time}}`", "header": "📋 **Kuyrukta {{count}} parça** • ⏱️ `{{time}}`",
"upNext": " ▶", "upNext": " ▶",
"queueTitle": "🎧 Kuyruk" "queueTitle": "🎧 Kuyruk",
"tracksCount": "Sırada {{count}} {{plural}}",
"nowPlayingHeader": "Şu An Çalıyor",
"upNextHeader": "Sıradaki",
"pageFooter": "Sayfa {{page}}/{{totalPages}} • Döngü: {{loopState}}"
}, },
"loop": { "loop": {
"invalidChoice": "'{{choice}}' geçerli değil. `song` veya `queue` kullanın", "invalidChoice": "'{{choice}}' geçerli değil. `song` veya `queue` kullanın",
@@ -606,7 +610,8 @@
"unknownStation": "❌ Bilinmeyen istasyon `{{station}}`. Kullanılabilir: {{stations}}\n\nGörüntülemek için `$prefixradio list` kullanın.", "unknownStation": "❌ Bilinmeyen istasyon `{{station}}`. Kullanılabilir: {{stations}}\n\nGörüntülemek için `$prefixradio list` kullanın.",
"nowPlaying": "📻 <#{{channel}}> kanalında [{{author}}]({{url}}) tarafından _{{title}}_ yayınlanıyor", "nowPlaying": "📻 <#{{channel}}> kanalında [{{author}}]({{url}}) tarafından _{{title}}_ yayınlanıyor",
"skipHint": "_Radyoyu durdurmak için `$prefixskip` veya istasyon değiştirmek için `$prefixradio list` kullanın._", "skipHint": "_Radyoyu durdurmak için `$prefixskip` veya istasyon değiştirmek için `$prefixradio list` kullanın._",
"prevNext": "⬅️ Önceki ➡️ Sonraki ❌ İptal" "prevNext": "⬅️ Önceki ➡️ Sonraki ❌ İptal",
"stationsAuthor": "7/24 Radyo İstasyonu Dizini"
}, },
"reload": { "reload": {
"indexNoReload": "❌ `index.mjs` sıcak yeniden yüklenemez — tam yeniden başlatma yapın.", "indexNoReload": "❌ `index.mjs` sıcak yeniden yüklenemez — tam yeniden başlatma yapın.",
@@ -639,7 +644,8 @@
"cancelled": "❌ İptal edildi.", "cancelled": "❌ İptal edildi.",
"added": "✅ [{{title}}]({{url}}) kuyruğa eklendi!", "added": "✅ [{{title}}]({{url}}) kuyruğa eklendi!",
"timedOut": "⏰ Arama zaman aşımına uğradı.", "timedOut": "⏰ Arama zaman aşımına uğradı.",
"sessionClosed": "Oturum kapatıldı" "sessionClosed": "Oturum kapatıldı",
"cancelOption": "İptal"
}, },
"servers": { "servers": {
"noServers": "_Sunucu bulunamadı._", "noServers": "_Sunucu bulunamadı._",