Greasy Fork is available in English.

Clock figuccio migliore

clock compare lora se clicchi sul menu compare la data e viceversa

// ==UserScript==
// @name           Clock figuccio migliore
// @description    clock compare lora se clicchi sul menu compare la data e viceversa
// @version        1.0
// @match          *://*/*
// @run-at         document-end
// @author         figuccio
// @grant          GM_setValue
// @grant          GM_getValue
// @grant          GM_registerMenuCommand
// @icon           data:image/gif;base64,R0lGODlhEAAQAKECABEREe7u7v///////yH5BAEKAAIALAAAAAAQABAAAAIplI+py30Bo5wB2IvzrXDvaoFcCIBeeXaeSY4tibqxSWt2RuWRw/e+UQAAOw==
// @namespace      https://greasyfork.org/users/237458
// @noframes
// @license        MIT
// ==/UserScript==
(function() {
    'use strict';

function updateClock() {
  var date = new Date();
  var datario = date.toLocaleString('it',{
  day:'2-digit',year:'numeric',month:'long',weekday:'long',
  });
  node.innerHTML = datario;
}
var node = document.createElement('div');
////////////
node.id = "a";
node.title ='data';

node.setAttribute("style","cursor:;padding:4px;background:black;color:lime;top:0;margin-left:800px;font-family:sans-serif;font-size:14px;position:fixed;text-align:center;z-index:999999;border-radius:10px;border:2px solid yellow;");
document.body.appendChild(node);
setInterval(updateClock, 1000);

//////////////
function Clock() {
  var date = new Date();
  var ore = date.toLocaleString('it',{
  hour:'2-digit',minute:'numeric',second:'numeric',
  });
  node2.innerHTML = ore;
}
var node2 = document.createElement('div');
node2.id = "b";
node2.title ='time';

node2.setAttribute("style","cursor:;padding:4px;background:black;color:lime;top:0px;margin-left:800px;font-family:sans-serif;font-size:14px;position:fixed;text-align:center;z-index:999999;border-radius:10px;border:2px solid yellow;");
document.body.appendChild(node2);

setInterval(Clock, 1000);
//////////////
  function Function144() {
  if (node.style.display === 'none') {node.style.display = 'block';node2.style.display = 'none';}
  else {node.style.display = 'none';node2.style.display = 'block';}
}
//GM_registerMenuCommand("mostra data /time",Function144);
//data e ora alternata ogni 5 secondi
setInterval(Function144, 5000);
   //al passaggio mouse
node2.addEventListener('mouseover',Function144);
node.addEventListener('mouseout', Function144);
node.style.display = 'none';
})();