Mouse

Mira arcoiris simple

スクリプトをインストールするには、Tampermonkey, GreasemonkeyViolentmonkey のような拡張機能のインストールが必要です。

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

スクリプトをインストールするには、TampermonkeyViolentmonkey のような拡張機能のインストールが必要です。

スクリプトをインストールするには、TampermonkeyUserscripts のような拡張機能のインストールが必要です。

このスクリプトをインストールするには、Tampermonkeyなどの拡張機能をインストールする必要があります。

このスクリプトをインストールするには、ユーザースクリプト管理ツールの拡張機能をインストールする必要があります。

(ユーザースクリプト管理ツールは設定済みなのでインストール!)

このスタイルをインストールするには、Stylusなどの拡張機能をインストールする必要があります。

このスタイルをインストールするには、Stylus などの拡張機能をインストールする必要があります。

このスタイルをインストールするには、Stylus tなどの拡張機能をインストールする必要があります。

このスタイルをインストールするには、ユーザースタイル管理用の拡張機能をインストールする必要があります。

このスタイルをインストールするには、ユーザースタイル管理用の拡張機能をインストールする必要があります。

このスタイルをインストールするには、ユーザースタイル管理用の拡張機能をインストールする必要があります。

(ユーザースタイル管理ツールは設定済みなのでインストール!)

このスクリプトの質問や評価の投稿はこちら通報はこちらへお寄せください
(function() {
    'use strict';

// ==UserScript==
// @name         Mouse
// @namespace    http://tampermonkey.net/
// @version      1.0
// @description  Mira arcoiris simple
// @match        *://*/*
// @grant        none
// ==/UserScript==

(function () {

    const crosshair = document.createElement("div");

    crosshair.style.position = "fixed";
    crosshair.style.width = "24px";
    crosshair.style.height = "24px";
    crosshair.style.border = "3px solid red";
    crosshair.style.borderRadius = "50%";
    crosshair.style.pointerEvents = "none";
    crosshair.style.zIndex = "999999";
    crosshair.style.transform = "translate(-50%, -50%)";
    crosshair.style.boxShadow = "0 0 15px red";

    document.body.appendChild(crosshair);

    document.addEventListener("mousemove", function (e) {

        crosshair.style.left = e.clientX + "px";
        crosshair.style.top = e.clientY + "px";

    });

    let hue = 0;

    function animate() {

        hue += 2;

        const color = `hsl(${hue}, 100%, 50%)`;

        crosshair.style.borderColor = color;
        crosshair.style.boxShadow = `0 0 15px ${color}`;

        requestAnimationFrame(animate);

    }

    animate();

})(); // Your code here...
})();