feat(media): Download-Option für URL-Player; yt-dlp/ffmpeg Args für YouTube stabilisiert; UI: Checkbox 'Download speichern' + Dropdown layering fix
This commit is contained in:
parent
e401124001
commit
f9e9dc8d0b
4 changed files with 52 additions and 11 deletions
|
|
@ -88,10 +88,10 @@ export async function adminRename(from: string, to: string): Promise<string> {
|
|||
return data?.to as string;
|
||||
}
|
||||
|
||||
export async function playUrl(url: string, guildId: string, channelId: string, volume: number): Promise<void> {
|
||||
export async function playUrl(url: string, guildId: string, channelId: string, volume: number, download?: boolean): Promise<void> {
|
||||
const res = await fetch(`${API_BASE}/play-url`, {
|
||||
method: 'POST', headers: { 'Content-Type': 'application/json' },
|
||||
body: JSON.stringify({ url, guildId, channelId, volume })
|
||||
body: JSON.stringify({ url, guildId, channelId, volume, download: !!download })
|
||||
});
|
||||
if (!res.ok) {
|
||||
const data = await res.json().catch(() => ({}));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue