GreasyFork Scroll to Bottom Button

Adds a modern dark button to scroll to bottom of the page on GreasyFork

이 스크립트를 설치하려면 Tampermonkey, Greasemonkey 또는 Violentmonkey와 같은 확장 프로그램이 필요합니다.

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

이 스크립트를 설치하려면 Tampermonkey 또는 Violentmonkey와 같은 확장 프로그램이 필요합니다.

이 스크립트를 설치하려면 Tampermonkey 또는 Userscripts와 같은 확장 프로그램이 필요합니다.

이 스크립트를 설치하려면 Tampermonkey와 같은 확장 프로그램이 필요합니다.

이 스크립트를 설치하려면 유저 스크립트 관리자 확장 프로그램이 필요합니다.

(이미 유저 스크립트 관리자가 설치되어 있습니다. 설치를 진행합니다!)

이 스타일을 설치하려면 Stylus와 같은 확장 프로그램이 필요합니다.

이 스타일을 설치하려면 Stylus와 같은 확장 프로그램이 필요합니다.

이 스타일을 설치하려면 Stylus와 같은 확장 프로그램이 필요합니다.

이 스타일을 설치하려면 유저 스타일 관리자 확장 프로그램이 필요합니다.

이 스타일을 설치하려면 유저 스타일 관리자 확장 프로그램이 필요합니다.

이 스타일을 설치하려면 유저 스타일 관리자 확장 프로그램이 필요합니다.

(이미 유저 스타일 관리자가 설치되어 있습니다. 설치를 진행합니다!)

// ==UserScript==
// @name         GreasyFork Scroll to Bottom Button
// @namespace    https://emree.scroll.button
// @version      1.0
// @description  Adds a modern dark button to scroll to bottom of the page on GreasyFork
// @author       Emree.el on ig
// @match        https://greasyfork.org/*
// @grant        none
// @license   MIT
// ==/UserScript==

(function() {
    'use strict';

    // create button
    const btn = document.createElement('div');
    btn.innerHTML = '↓';
    btn.id = 'scrollToBottomBtn';
    document.body.appendChild(btn);

    // style button
    const style = document.createElement('style');
    style.textContent = `
        #scrollToBottomBtn {
            position: fixed;
            bottom: 20px;
            left: 20px;
            width: 45px;
            height: 45px;
            background: #111;
            color: #fff;
            font-size: 22px;
            font-weight: bold;
            border-radius: 12px;
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            box-shadow: 0 0 12px rgba(0,0,0,0.4);
            transition: all 0.2s ease;
            z-index: 9999;
            user-select: none;
        }

        #scrollToBottomBtn:hover {
            background: #222;
            transform: scale(1.08);
        }
    `;
    document.head.appendChild(style);

    // click event
    btn.addEventListener('click', () => {
        window.scrollTo({
            top: document.body.scrollHeight,
            behavior: 'smooth'
        });
    });
})();