// ==UserScript== // @name Greasy Fork Install Button at search // @namespace - // @version 0.3 // @description adds install button at search and at user pages. // @author NotYou // @include *sleazyfork.org/* // @include *greasyfork.org/* // @require http://code.jquery.com/jquery-3.4.1.min.js // @grant none // @license GPL-3.0-or-later // @downloadURL none // ==/UserScript== /* ﹀ Change Log ﹀ 0.3 Version: - SleazyFork support - HTTP support 0.2 Version: - Better css styles identifying */ $(document).ready( function() { 'use strict'; var protocol = location.protocol var domain = location.host // STYLES $('head').append('') // USER SCRIPT $('#user-script-list > li > article > h2 > a, #browse-script-list > li > article > h2 > a').each(function() { let scriptId = $(this).parent().parent().parent().data('script-id') let scriptName = $(this).parent().parent().parent().data('script-name') $(this).append('Install'); }); // USER STYLE $('#user-script-list > li[data-script-language="css"] > article > h2 > a, #browse-script-list > li[data-script-language="css"] > article > h2 > a').each(function() { let scriptId = $(this).parent().parent().parent().data('script-id') let scriptName = $(this).parent().parent().parent().data('script-name') $(this).append('Install as style'); }); })();