🎉 欢迎访问GreasyFork.Org 镜像站!本镜像站由公众号【爱吃馍】搭建,用于分享脚本。联系邮箱📮

Greasy fork 爱吃馍镜像

『小助手』腾讯微云 - 离线下载

One click offline download, no need to click 2 steps.

您需要先安装一个扩展,例如 篡改猴Greasemonkey暴力猴,之后才能安装此脚本。

You will need to install an extension such as Tampermonkey to install this script.

您需要先安装一个扩展,例如 篡改猴暴力猴,之后才能安装此脚本。

您需要先安装一个扩展,例如 篡改猴Userscripts ,之后才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。

您需要先安装用户脚本管理器扩展后才能安装此脚本。

(我已经安装了用户脚本管理器,让我安装!)

🚀 安装遇到问题?关注公众号获取帮助

公众号二维码

扫码关注【爱吃馍】

回复【脚本】获取最新教程和防失联地址

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

(我已经安装了用户样式管理器,让我安装!)

🚀 安装遇到问题?关注公众号获取帮助

公众号二维码

扫码关注【爱吃馍】

回复【脚本】获取最新教程和防失联地址

// ==UserScript==
// @name               『小助手』腾讯微云 - 离线下载
// @name:zh-CN         『小助手』腾讯微云 - 离线下载
// @namespace          ttps://github.com/Hunlongyu
// @version            0.0.2
// @author             Hunlongyu
// @description        One click offline download, no need to click 2 steps.
// @description:zh-CN  一键离线下载,不需要点2步。
// @license            MIT
// @copyright          Copyright (c) [2024] [hunlongyu]
// @icon               https://i.loli.net/2019/04/22/5cbd720718fdb.png
// @homepage           https://github.com/Hunlongyu/userscript
// @supportURL         https://github.com/Hunlongyu/userscript/issues
// @match              *://www.weiyun.com/*
// @run-at             document-end
// ==/UserScript==

(function () {
  'use strict';

  const btButton = document.createElement("div");
  btButton.innerHTML = `
<div class="action-item">
  <div class="action-item-con">
    <span class="act-txt">BT下载</span>
  </div>
</div>
`;
  btButton.setAttribute("class", "mod-action-wrap clearfix");
  btButton.addEventListener("click", () => {
    document.querySelectorAll("li.menu-item")[5].click();
    setTimeout(function() {
      document.querySelectorAll(".tab-nav-item")[0].click();
    }, 10);
  });
  const mgnetButton = document.createElement("div");
  mgnetButton.innerHTML = `
<div class="action-item">
  <div class="action-item-con">
    <span class="act-txt">链接下载</span>
  </div>
</div>
`;
  mgnetButton.setAttribute("class", "mod-action-wrap clearfix");
  mgnetButton.addEventListener("click", () => {
    document.querySelectorAll("li.menu-item")[5].click();
    setTimeout(function() {
      document.querySelectorAll(".tab-nav-item")[1].click();
    }, 10);
    setTimeout(function() {
      document.querySelector(".input-block").focus();
    }, 20);
  });
  window.onload = () => {
    const nav = document.querySelector(".mod-nav");
    nav.appendChild(btButton);
    nav.appendChild(mgnetButton);
  };

})();