Files
web-app-launcher/src/lib/server/integrations/metube/transform.ts
T
alexei.dolgolyov 55e220bc07 feat(service-integrations): phases 9-10 — media integrations + Planka
- Emby: now playing, library stats, recently added, active streams
- Immich: library stats, recent uploads with formatted storage
- Deluge: active torrents with progress, transfer speed, disk space gauge
- MeTube: download queue progress (no auth required)
- Planka: my cards, overdue cards with red badges, board summary
- All 11 integrations registered in registry
2026-03-25 22:16:27 +03:00

18 lines
430 B
TypeScript

import type { ProgressData } from '../types.js';
import type { MetubeQueueItem } from './client.js';
export function toDownloadQueue(
queue: Record<string, MetubeQueueItem>
): ProgressData {
const entries = Object.entries(queue);
return {
items: entries.map(([id, item]) => ({
id,
label: item.title || item.filename || id,
progress: Math.round(item.percent ?? 0),
subtitle: item.status || undefined
}))
};
}