feat: terminal-native torrent discovery TUI

Curated, multi-source torrent search and download from the terminal:
concurrent search across built-in sources with streamed, source-tagged
results; a download-only webtorrent engine with true pause/resume and
restart recovery; magnet paste; and a calm Ink + React TUI. No indexer
server, no setup.
This commit is contained in:
bairon.dev
2026-06-27 02:03:19 -04:00
commit 60d7a9a755
71 changed files with 11293 additions and 0 deletions
+10
View File
@@ -0,0 +1,10 @@
export function wrapStep(current: number, delta: number, length: number): number {
if (length <= 0) return 0;
return (((current + delta) % length) + length) % length;
}
export function windowStart(cursor: number, total: number, height: number): number {
if (total <= height) return 0;
const half = Math.floor(height / 2);
return Math.max(0, Math.min(cursor - half, total - height));
}