The only downloader you need. 下载器的集大成者。
TypeScript asyncasynciobittorentbtcross-platformdownload-managerdownloaderfluent-designftphttp3magnetpyqtpyside6pythonqtquicreactsoftwarestreaming
fix(Browser Extension): 图片面板下载无扩展名的图片时缺少扩展名
XiaoYouChR50a7c2ca3ec1
diff --git a/browser_extension/app/src/background.ts b/browser_extension/app/src/background.tsindex ef247761..e91b5945 100644--- a/browser_extension/app/src/background.ts+++ b/browser_extension/app/src/background.ts@@ -94,7 +94,7 @@ let shouldTakeUnknownSize = true;let skipExtensions: Set<string> = new Set();let skipDomains: Set<string> = new Set();-function imageFilename(url: string, alt: string): string {+function toImageFilename(url: string): string {try {const segments = new URL(url).pathname.split("/").filter(Boolean).map(decodeURIComponent);const basename = segments.pop() || "";@@ -104,8 +104,7 @@ function imageFilename(url: string, alt: string): string {return name.slice(0, 160);}} catch { /* invalid URL */ }- const safe = (alt || "image").replace(/[<>:"/\\|?*\x00-\x1f]+/g, " ").trim().slice(0, 120);- return safe || "image";+ return "";}async function injectMediaButton(tabId: number) {@@ -518,11 +517,11 @@ async function runPopupCommand(command: PopupCommand): Promise<PopupState | Commcase "popup_send_images": {let count = 0;for (const image of command.images) {- const filename = imageFilename(image.src, image.alt);+ const filename = toImageFilename(image.src);await sendTaskOrEnqueue({type: "create_task",source: "download",- title: filename,+ title: filename || image.alt.trim(),payload: {url: image.src,headers: { referer: command.pageUrl },