feat(soundboard): extend URL download to support YouTube & Instagram
yt-dlp extracts audio as MP3 from YouTube and Instagram links. Direct MP3 links continue to work as before. URL input field now shows a type indicator (YT/IG/MP3) and validates all three formats. Backend: downloadWithYtDlp() spawns yt-dlp with --extract-audio, saves to SOUNDS_DIR, normalizes if enabled. New /download-url route for save-only without auto-play. play-url route extended for all types. Frontend: isSupportedUrl() validates YouTube/Instagram/MP3, dynamic icon changes per URL type, disabled state when URL is unsupported. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
06326de465
commit
200f03c1f8
3 changed files with 243 additions and 28 deletions
|
|
@ -592,6 +592,24 @@
|
|||
pointer-events: none;
|
||||
}
|
||||
|
||||
.url-import-tag {
|
||||
flex-shrink: 0;
|
||||
padding: 1px 6px;
|
||||
border-radius: 8px;
|
||||
font-size: 10px;
|
||||
font-weight: 800;
|
||||
letter-spacing: .5px;
|
||||
text-transform: uppercase;
|
||||
}
|
||||
.url-import-tag.valid {
|
||||
background: rgba(46, 204, 113, .18);
|
||||
color: #2ecc71;
|
||||
}
|
||||
.url-import-tag.invalid {
|
||||
background: rgba(231, 76, 60, .18);
|
||||
color: #e74c3c;
|
||||
}
|
||||
|
||||
/* ── Toolbar Buttons ── */
|
||||
.tb-btn {
|
||||
display: flex;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue