audiobookshelf/client/components/modals
Claude aaf87821a3
Add YouTube download feature with yt-dlp integration
This commit implements a comprehensive YouTube download feature that allows
administrators to download audio from YouTube videos and playlists.

Backend Changes:
- Add yt-dlp-wrap npm dependency for YouTube downloading
- Create YouTubeDownloadManager to handle download queue and execution
- Create YouTubeDownloadController with API endpoints for download/queue/cancel
- Add YouTube utility functions for URL validation and metadata extraction
- Create YouTubeDownload object model for tracking download state
- Add API routes: POST /api/youtube/download, GET /api/youtube/queue, DELETE /api/youtube/download/:id
- Implement playlist support - automatically queue all videos from playlist URLs
- Download audio in MP3 format with best quality
- Organize files in subfolder structure: <Uploader>/<Video Title>/
- Extract metadata and create library items automatically
- Real-time progress updates via Socket.io

Frontend Changes:
- Create YouTubeDownloadModal component for user-friendly download interface
- Add download button to Appbar header (admin-only, visible with current library)
- Update Vuex store with modal state management
- Register modal globally in default layout
- Implement Socket.io listeners for download events (started, progress, completed, failed, queued)
- Show toast notifications for download status updates

Features:
- Admin-only access control
- Support for single videos and playlists
- Audio quality selection (best, 320kbps, 256kbps, 192kbps, 128kbps)
- Library and folder selection
- Download queue management
- Real-time progress tracking
- Automatic thumbnail download as cover image
- Automatic library item creation with metadata
- Error handling and user feedback

Technical Details:
- Uses yt-dlp for reliable YouTube downloading
- Integrates with existing task management system
- Respects library folder permissions
- Follows existing code patterns (similar to podcast downloads)
- Socket.io events for real-time updates
2025-12-31 01:32:37 +00:00
..
authors Tailwind V4 migration initial commit 2025-03-16 16:41:37 +02:00
bookmarks Fix double slash color modifer typo 2025-03-23 08:57:13 +02:00
changelog Use getServerSetting to ensure serverSettings is set before accessing 2025-07-06 17:39:03 -05:00
collections Tailwind V4 migration initial commit 2025-03-16 16:41:37 +02:00
emails Tailwind V4 migration initial commit 2025-03-16 16:41:37 +02:00
item Update providers users to fetch providers on demand 2025-10-19 18:57:27 +03:00
libraries Update providers users to fetch providers on demand 2025-10-19 18:57:27 +03:00
notification Tailwind V4 migration initial commit 2025-03-16 16:41:37 +02:00
player Fix Cover modal showing error image for items with no cover, update placeholder cover url to all come from global store 2025-03-27 17:37:25 -05:00
playlists Sort the playlist sections alphabetically. 2025-12-12 04:18:29 +00:00
podcast Add episode updated translation for podcast match #4606 2025-08-19 16:52:50 -05:00
rssfeed Tailwind V4 migration initial commit 2025-03-16 16:41:37 +02:00
AccountModal.vue Update ereaders to handle refreshing, epubjs to use custom request method, separate accessToken in store 2025-07-10 16:54:28 -05:00
AddCustomMetadataProviderModal.vue Tailwind V4 migration initial commit 2025-03-16 16:41:37 +02:00
ApiKeyCreatedModal.vue Add get all, update and delete endpoints. Add api keys config page 2025-06-30 11:32:02 -05:00
ApiKeyModal.vue Update API Keys to be tied to a user, add apikey lru-cache, handle deactivating expired keys 2025-06-30 14:53:11 -05:00
AudioFileDataModal.vue Tailwind V4 migration initial commit 2025-03-16 16:41:37 +02:00
BackupScheduleModal.vue Translation strings added (#3304) 2024-08-30 17:47:49 -05:00
BatchQuickMatchModel.vue Update providers users to fetch providers on demand 2025-10-19 18:57:27 +03:00
BookmarksModal.vue Use getServerSetting to ensure serverSettings is set before accessing 2025-07-06 17:39:03 -05:00
ChaptersModal.vue Tailwind V4 migration initial commit 2025-03-16 16:41:37 +02:00
Dialog.vue Tailwind V4 migration initial commit 2025-03-16 16:41:37 +02:00
EditSeriesInputInnerModal.vue Update edit series sequence to show error when sequence has spaces #4314 2025-05-19 17:37:11 -05:00
ListeningSessionModal.vue Update sessions modal to show username & update sessions endpoints to always return username 2025-07-16 16:56:07 -05:00
Modal.vue Update API Keys to be tied to a user, add apikey lru-cache, handle deactivating expired keys 2025-06-30 14:53:11 -05:00
PlayerSettingsModal.vue Add dropdown to player settings modal to set the playbackRateIncrementDecrement amount 2025-01-25 01:58:13 +00:00
RawCoverPreviewModal.vue Fix:Fullscreen cover image modal not updating when changing covers #2900 2024-05-02 17:48:50 -05:00
ShareModal.vue Use getServerSetting to ensure serverSettings is set before accessing 2025-07-06 17:39:03 -05:00
SleepTimerModal.vue Tailwind V4 migration initial commit 2025-03-16 16:41:37 +02:00
UploadImageModal.vue Tailwind V4 migration initial commit 2025-03-16 16:41:37 +02:00
YouTubeDownloadModal.vue Add YouTube download feature with yt-dlp integration 2025-12-31 01:32:37 +00:00