Scratch Stats Links

Quick links on profiles to ScratchStats.com and my Scratch Stats. (Deprecated: Use Scratch Addons instead.)

คุณจะต้องติดตั้งส่วนขยาย เช่น Tampermonkey, Greasemonkey หรือ Violentmonkey เพื่อติดตั้งสคริปต์นี้

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

คุณจะต้องติดตั้งส่วนขยาย เช่น Tampermonkey หรือ Violentmonkey เพื่อติดตั้งสคริปต์นี้

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

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

You will need to install a user script manager extension to install this script.

(I already have a user script manager, let me install it!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(I already have a user style manager, let me install it!)

// ==UserScript==
// @name         Scratch Stats Links
// @namespace    Hans5958
// @version      1
// @description  Quick links on profiles to ScratchStats.com and my Scratch Stats. (Deprecated: Use Scratch Addons instead.)
// @author       Hans5958
// @license      MIT
// @match        https://scratch.mit.edu/users/*
// @grant        none
// @homepageURL  https://github.com/Hans5958/userscripts
// @supportURL   https://github.com/Hans5958/userscripts/issues
// ==/UserScript==

var css = ".header-text .profile-details .group{border-right:1px solid #ccc;margin:0 5px;padding:0}"
if("undefined"!=typeof GM_addStyle)GM_addStyle(css);else if("undefined"!=typeof PRO_addStyle)PRO_addStyle(css);else if("undefined"!=typeof addStyle)addStyle(css);else{var node=document.createElement("style");node.type="text/css",node.appendChild(document.createTextNode(css));var heads=document.getElementsByTagName("head");0<heads.length?heads[0].appendChild(node):document.documentElement.appendChild(node)}

var x = $(".profile-details")
var y = x.children()
var a = y[0].innerHTML.match(/\w+/g)[0]
var b = y[1].outerHTML
var c = y[2].innerHTML
var d = $("h2").html()
x.html(a + "<span class=\"group\"><\/span>Joined " + b + " ago<span class=\"group\"><\/span>" + c + "<br><a href=\"https:\/\/scratchstats.com#" + d + "\">ScratchStats.com<\/a><span class=\"group\"><\/span><a href=\"https:\/\/hans5958.github.io\/mini-htmls\/scratch-stats#" + d + "\">My Scratch Stats<\/a>")