Greasy Fork | Quick Copy/Download/Install Script Buttons

Adds Copy, Download, and Install buttons to every search result tile and script page header.

您需要先安裝使用者腳本管理器擴展,如 TampermonkeyGreasemonkeyViolentmonkey 之後才能安裝該腳本。

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

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyUserscripts 後才能安裝該腳本。

你需要先安裝一款使用者腳本管理器擴展,比如 Tampermonkey,才能安裝此腳本

您需要先安裝使用者腳本管理器擴充功能後才能安裝該腳本。

(我已經安裝了使用者腳本管理器,讓我安裝!)

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

(我已經安裝了使用者樣式管理器,讓我安裝!)

作者
piknockyou
今日安裝
0
安裝總數
1
評價
0 0 0
版本
1.2
建立日期
2025-12-27
更新日期
2025-12-27
尺寸
19.1 KB
授權條款
AGPL-3.0
腳本執行於

See screenshots at the bottom

Greasy Fork | Quick Copy/Download/Install Script

Adds Copy, Download, and Install buttons to every search result tile and script page header for instant script management without page navigation.

Why You Need This

Managing userscripts on Greasy Fork requires multiple clicks and page loads:

  • Navigation overhead: Must open individual script pages to access code.
  • Installation friction: Can't quickly install from search results.
  • No archival tools: No built-in way to download scripts for backup or offline review.

This script adds three one-click actions directly to search results and script headers.

Key Features

  • Copy Code: Instantly fetch and copy the full .user.js source to your clipboard without loading the code page.
  • Download File: Save the script locally as a .user.js file for archiving or manual review.
  • Quick Install: Trigger the standard installation prompt directly from search results.
  • Visual Feedback: Loading spinners, success checkmarks, and clear tooltips for each action.
  • Universal Support: Works on search results, user profiles, script info pages, and code view pages.
  • Theme Compatible: Seamlessly integrates with both Light and Dark modes.

How to Use

Action Result
Click Copy button Fetch and copy script source to clipboard
Click Download button Save script as .user.js file
Click Install button Navigate to userscript installation prompt

Buttons appear in the top-right corner of each search result tile and in script page headers.

Performance Notes

  • Efficient detection: Uses MutationObserver to only process newly added script tiles (no full-page rescans).
  • Debounced updates: 100ms debounce prevents excessive processing during rapid DOM changes.
  • SPA-aware: Automatically re-injects buttons after navigation to handle Greasy Fork's dynamic routing.

Installation

  1. Install Violentmonkey (recommended), Tampermonkey, or Greasemonkey.
  2. Install this script.
  3. Visit greasyfork.org.

Works immediately. Buttons appear on all script tiles and pages.

Technical Details

  • Fetch method: Uses GM_xmlhttpRequest to bypass CORS and fetch script source reliably.
  • Clipboard API: Uses GM_setClipboard with navigator clipboard fallback.
  • Styling: Color-coded buttons (Blue = Copy, Green = Download, Red = Install) with hover effects.
  • Dark mode: Automatic detection via prefers-color-scheme and Greasy Fork's native theme classes.