Kasi-time

不可能を可能にする

Du musst eine Erweiterung wie Tampermonkey, Greasemonkey oder Violentmonkey installieren, um dieses Skript zu installieren.

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

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

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.

Sie müssten eine Skript Manager Erweiterung installieren damit sie dieses Skript installieren können

(Ich habe schon ein Skript Manager, Lass mich es installieren!)

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        Kasi-time
// @namespace   https://twitter.com/akameco
// @description 不可能を可能にする
// @include     http://www.kasi-time.com/*
// @version     1.01
// @grant       none
// ==/UserScript==

setTimeout(function() { 
  function selectText() {
    let el  = document.getElementById("lyrics");
    let rng = document.createRange();
    rng.selectNodeContents(el);
    window.getSelection().addRange(rng);
  }

  $('body').css('-moz-user-select','text');
  $('body').off('copy contextmenu selectstart');

  let button = $('<button>');
  button.text('選択').css({
    'margin': '10px 10px 0 0',
    'borderTop': '1px solid #ccc',
    'borderRight': '1px solid #999',
    'borderBottom': '1px solid #999',
    'borderLeft': '1px solid #ccc',
    'padding': '3px 12px',
    'cursor': 'pointer',
    'color': '#666'
  }).click(function () {
    selectText();
  });

  $('.lyrics_menu').append(button);
}, 10);