Open-source download manager & offline media toolbox for YouTube, music, social media, learning platforms & 1,800+ sites. Built with Tauri 2.0, Rust & Svelte.
Rust downloadmanagerguihacktoberfesthomebrewlightweightlinuxlinux-distributionlocal-firstmacosmacos-packagemedia-toolboxopen-sourcerustsveltetauritrendingtrending-repositorieswindowswindows-desktopytdlp
fix: implement getBadgeCount function to count active downloads
Tonhof7958ccb103f
diff --git a/src/lib/stores/download-store.svelte.ts b/src/lib/stores/download-store.svelte.tsindex 9a8cef86..f4413251 100644--- a/src/lib/stores/download-store.svelte.ts+++ b/src/lib/stores/download-store.svelte.ts@@ -59,6 +59,14 @@ export function getQueuedCount(): number {return count;}+export function getBadgeCount(): number {+ let count = 0;+ for (const item of downloads.values()) {+ if (item.status === "downloading" || item.status === "queued") count++;+ }+ return count;+}+export function getPausedCount(): number {let count = 0;for (const item of downloads.values()) {