import { t as ClientOptions } from "./http-C6GUCiWI.mjs"; //#region src/torrent.d.ts interface ParsedTorrent { name: string; multiFile: boolean; files: Array<{ name: string; encryptedLength: number; }>; pieceLength: number; numPieces: number; } //#endregion //#region src/download-client.d.ts interface DownloadOptions { /** Called with bytes downloaded so far and total encrypted size */ onProgress?: (downloaded: number, total: number) => void; /** Called when torrent metadata is parsed, before download starts */ onInfo?: (torrent: ParsedTorrent) => void; /** AbortSignal to cancel the entire download */ signal?: AbortSignal; } interface DownloadResult { /** Torrent name (directory name for multi-file transfers) */ name: string; /** Decrypted files with their names and raw data */ files: Array<{ name: string; data: Uint8Array; }>; } interface DownloadClient { download(url: string, options?: DownloadOptions): Promise; } declare function parseWormholeUrl(url: string): { roomId: string; masterKey: Uint8Array; }; declare function createDownloadClient(options?: ClientOptions): DownloadClient; //#endregion export { parseWormholeUrl as a, createDownloadClient as i, DownloadOptions as n, ParsedTorrent as o, DownloadResult as r, DownloadClient as t };