您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Shows a user's total downloads.
当前为
// ==UserScript== // @name Greasy Fork Total Downloads // @namespace - // @version 0.2 // @description Shows a user's total downloads. // @author NotYou // @include *greasyfork.org/*/users/* // @license GPLv3 // @license-link https://www.gnu.org/licenses/gpl-3.0.txt // @require https://code.jquery.com/jquery-3.3.1.min.js // @grant none // ==/UserScript== /* ﹀ Change Log ﹀ 0.2 Version: - Added Daily Installs - Fixed bug #001 */ /* BUG #001: Count deleted script installs */ $(document).ready(function(){ let totalDownloads = 0; $('dd.script-list-total-installs span').each(function() { totalDownloads += Number($(this).text()) }); let totalDailyDownloads = 0; $('dd.script-list-daily-installs span').each(function() { totalDailyDownloads += Number($(this).text()) }); totalDownloads -= Number($('#user-deleted-script-list > li > article > .inline-script-stats > dd.script-list-daily-installs > span').text()) totalDownloads -= Number($('#user-deleted-script-list > li > article > .inline-script-stats > dd.script-list-total-installs > span').text()) console.log('[ Total Downloads: ' +totalDownloads + ' ]') console.log('[ Total Daily Downloads: ' +totalDownloads + ' ]') $('div.sidebarred-main-content h3:first').append('<span style="font-size: 15px;font-variant: normal;color: rgb(123, 23, 23);"> [' + totalDownloads + ' Total Installs]</span>'); $('div.sidebarred-main-content h3:first').append('<span style="font-size: 15px;font-variant: normal;color: rgb(185, 32, 32);"> [' + totalDailyDownloads + ' Total Daily Installs]</span>'); });