Eval functions

XML Detected Guest 5 Views Size: 9.73 KB Posted on: Mar 13, 26 @ 12:17 PM
  1. @@@@@Coord
  2. (()=>{var d=document,x,div=d.body.appendChild(d.createElement("div"));div.id="Coor";yy=(s)=>{if(s.shiftKey){if(!d.querySelector('#coor_')){x=d.body.appendChild(div.cloneNode(true));x.id='coor_';x.className="mydiv_class"}else x.remove()}};function zz(e){div.innerHTML=`<style>#Coor,#coor_{position:fixed;background:#fff;z-index:2147483647;padding:4px 8px;border:1px solid black;top:${e.clientY}px;left:${e.clientX}px</style>${e.clientX},${e.clientY}<hr>${e.pageX},${e.pageY}`;if(e.ctrlKey){div.remove();x?.remove();d.removeEventListener("mousemove",zz,!0);d.removeEventListener("keydown",yy)}}d.addEventListener("mousemove",zz,!0);d.addEventListener("keydown",yy)
  3. })()
  4. @@@@@Vremya
  5. (()=> {
  6. var dc = document;
  7.  dc.body.insertAdjacentHTML('beforeend', `
  8.       <div id="my_vr">
  9.           <style>#my_vr{padding:3px 10px;border:6px groove;position:fixed;top:250px; right:3px;background:azure; color:#000;
  10.               z-index:2147483647; text-align:center}  #my_vr #clock1{font-size:22px}
  11.               #my_vr #clock2{font-size:30px;font-weight:700}
  12.           </style>
  13.           <span id="clock1"></span><br><span id="clock2"></span></div>
  14.     ` )
  15.  var div = dc.getElementById('my_vr'), clk1 = dc.getElementById('clock1'),
  16.       clk2 = dc.getElementById('clock2');  getVremya();
  17.  function getVremya(){
  18.      var dt = new Date(),
  19.            x=dt.toLocaleString('ru', {
  20.                year: 'numeric',
  21.                month: 'long',
  22.                day: 'numeric'
  23.            }),
  24.      weekday= [ "Воскресенье", "Понедельник", "Вторник", "Среда", "Четверг", "Пятница", "Суббота" ] [ dt.getDay() ],
  25.      time=dt.toString().split(' ')[4];
  26.      clk1.innerHTML = weekday +'  '+ x;
  27.      clk2.innerHTML = time
  28.   }      
  29.   var int = setInterval(()=>{
  30.       if(!dc.getElementById('my_vr'))  {
  31.           clearInterval(int) ; int = null
  32.       } else  getVremya();
  33.   }, 500);
  34.   dc.body.addEventListener('mousedown', function mnn(e) {
  35.             if (!div.contains(e.target)) {
  36.                 div.remove();  e.currentTarget.removeEventListener('mousedown', mnn);  clearInterval(int); int = null
  37.   } } )
  38. })()
  39. @@@@@Remove Sticky
  40. (()=> {
  41.     var els = document.querySelectorAll('*'), fl = 0;
  42.     document.body.addEventListener('click', remSt)
  43.     setTimeout(()=>{
  44.       document.body.removeEventListener('click', remSt)
  45.     }, 1800)
  46.     for(var i=0; i<els.length; i++) {
  47.      if(getComputedStyle(els[i]).position=='fixed')
  48.        els[i].style.setProperty('display', 'none', 'important');
  49.      if(els[i].nodeName=='NAV') els[i].remove();
  50.      if (els[i].shadowRoot)
  51.        els[i].shadowRoot.innerHTML+='<style>:host{display:none !important}</style>'
  52.     }
  53.     function remSt(e){
  54.       if(e.button!=0) return;
  55.       for(var i=0; i<els.length; i++)
  56.        if(getComputedStyle(els[i], null).position=='sticky')
  57.          els[i].remove();
  58.      document.body.removeEventListener('click', remSt)
  59.  }
  60. })()
  61. @@@@@Local List
  62. (()=> {
  63.     var dv = document.createElement('div'); dv.id = 'bookm'; dv.className = 'mydi_class mydrg';
  64.     document.body.append(dv);
  65.     dv.innerHTML = `
  66. <a>&bull; Universal decoder</a><br>
  67. <a>&bull; HTML entity</a><br>
  68. <a>&bull; keyboard-events</a><br>
  69. <a>&bull; rgb-to-hex converter</a><br>
  70. <a>&bull; Hebrew Keyboard</a><br>
  71. <a>&bull; Калькулятор</a><br>
  72. <a>&bull; Base64 encoder/decoder</a><br>
  73. <a>&bull; Типы GM_xmlhttpRequest</a><br>
  74. <div id="betw">&nbsp;</div>
  75. <div id="right" style="display:none">
  76. <a>&bull; Bookmarks</a>
  77. <br>
  78. <a>&bull; Plugins</a>
  79. <br>
  80. <a>&bull; Collapse</a>
  81. <br>
  82. <a onclick="javascript:childs=document.querySelectorAll('li[class*=&quot;b-leaf-actions-expandchilds&quot;],[class*=&quot;2mdspost-comment-actions__item--expand&quot;]');for(i=0;i<40;i++)childs[i]?.children[0].click();void 0">&bull; Collapse new design</a>
  83. <br>
  84. <a>&bull; Change font</a>
  85.  </div>
  86. <div id="zakr">закрыть</div>
  87. <style>#bookm {position:fixed; top:20px; left:650px; background:snow; z-index:20000}
  88.        #bookm a { color: #000; cursor: pointer; margin-right: 1rem }
  89.        #bookm  a:hover {color: #0000CD}
  90.        #bookm {border: 5px oldlace groove; padding: 0 10px; z-index: 20000; line-height: 1.45; text-align: left}
  91.        #bookm #betw {position: absolute; display:inline-block; top:0; right:0; height:40%; width: 19px; background-color: #000}
  92.        #bookm #right {
  93.            position: absolute; background-color: snow; white-space: nowrap; padding: 0 8px 6px;
  94.            border:1px solid; top:10px
  95.        }
  96.         #bookm #right  a {margin: 0}
  97.        #bookm #zakr {text-align: center; background: red; color: white; cursor: default; margin-top:10px}
  98. </style>`;
  99. setTimeout(()=>{
  100.   setMover();
  101.   document.querySelector('#bookm #zakr').onclick=()=>document.querySelector('#bookm').remove();
  102.   ln = document.querySelectorAll('#bookm a')
  103.   ln[0].onclick=()=>GM_openInTab('http://moemesto.ru/dazy/file/15255589/Universal%20decoder.html');
  104.   ln[1].onclick=()=>GM_openInTab('http://moemesto.ru/dazy/file/15255636/HTML_entity_Good.html');
  105.   ln[2].onclick=()=>GM_openInTab('http://moemesto.ru/dazy/file/15255592/keyboard-events.htm');
  106.   ln[3].onclick=()=>GM_openInTab('http://moemesto.ru/dazy/file/15255593/rgb-to-hex_color_converter.html');
  107.   ln[4].onclick=()=>GM_openInTab('http://moemesto.ru/dazy/file/15255594/Hebrew%20Keyboard_85.htm');
  108.   ln[5].onclick=()=>GM_openInTab('http://moemesto.ru/dazy/file/15255595/Calculator.html');
  109.   ln[6].onclick=()=>GM_openInTab('http://moemesto.ru/dazy/file/15255601/Base64_encoder_decoder_mothereff.html');
  110.   ln[7].onclick=()=>GM_openInTab('https://wiki.greasespot.net/GM.xmlHttpRequest#Bare_Minimum');
  111.   ln[8].onclick=()=>GM_openInTab('http://moemesto.ru/dazy/file/15255604/display/Bookm..html');
  112.   ln[9].addEventListener('click', function() {
  113.     function R(w) {
  114.       try {
  115.         var d = w.document,j, i, t, T, N, b, r = 1,C;
  116.         for (j = 0; t = ["object", "embed", "applet", "iframe","video"][j]; ++j) {
  117.           T = d.getElementsByTagName(t);
  118.           for (i = T.length - 1; (i + 1) && (N = T[i]); --i)
  119.             if (j != 3 || !R((C = N.contentWindow) ? C : N.contentDocument.defaultView)) {
  120.               b = d.createElement("div");
  121.               b.style.width = N.width;
  122.               b.style.height = N.height;
  123.               b.innerHTML = "<del>" + (j == 3 ? "third-party " + t : t) + "</del>";
  124.               N.parentNode.replaceChild(b, N);
  125.             }
  126.          }
  127.       } catch (E) {r = 0}
  128.       return r
  129.    }
  130.    R(self);
  131.    var i, x;
  132.    for (i = 0; x = frames[i]; ++i) R(x)
  133.   })
  134.   ln[10].addEventListener('click', function() {
  135.     var commentboxes = document.querySelectorAll('a[onclick^="ExpanderEx.make"]');
  136.     for (var z = 0; z < commentboxes.length; z++) {
  137.      if (commentboxes[z].getAttribute('onclick') && ~commentboxes[z].getAttribute('onclick').indexOf('ExpanderEx.make') || ~commentboxes[z].textContent.indexOf('Expand'))
  138.         setTimeout((function(box) {
  139.           return function() {
  140.             box.click()
  141.           }
  142.        })(commentboxes[z]), 500)
  143.    }
  144.  })
  145.  ln[12].addEventListener('click', ()=> {
  146.      var d=document,els=d.querySelectorAll('p,li,td,article,a div, a span,h1,h2,h3,h4,h5,h6');d.body.insertAdjacentHTML('beforeend',`<table id="myTB"class="mydiv_class"><style>#myTB{position:fixed;top:15px;max-width:fit-content;left:15px;z-index:99999;background:azure;outline:ridge 8px}#myTB td{padding:5px 25px;cursor:default;text-align:center;border:1px solid}#myTB td:hover{background:#D13BFB}</style><tr><td>verdana</td><td>arial</td><td>open sans</td><td>ms reference sans serif</td><td>reset</td><td style="background:red">Close</td></tr></table>`);v=p=>{for(var w of els)w.style.setProperty('font-family',p,'important')};td=[...d.querySelectorAll('#myTB td')];td.forEach(function(it){it.onclick=function(){v(this.innerHTML)}});td.at(-2).onclick=()=>v('');td.at(-1).onclick=()=>document.querySelector('#myTB').remove(); document.querySelector('#bookm').remove()
  147.   })
  148. }, 1000);
  149.   function setMover() {
  150.     var d = document.querySelector('#bookm'),
  151.         el = d.querySelector('#right'), betw = d.querySelector('#betw'), tm1, tm2;
  152.     el.style.left = d.offsetWidth - betw.offsetWidth + 'px';
  153.     betw.onmouseover=n=>{
  154.         tm1=setTimeout(()=>{
  155.           el.style.display=='none' ? el.style.display='inline-block' : "";
  156.           if (el.getBoundingClientRect().right>1235) {
  157.              d.style.left = parseInt(d.style.left) - (el.getBoundingClientRect().right-1235) +'px';
  158.              d.style.transition = "all 0.3s";  setTimeout(()=>d.style.transition = "", 500)
  159.        } }, 300)
  160.     }
  161.     betw.onmouseleave=()=>clearTimeout(tm1);
  162.     el.onmouseleave=g=>tm2=setTimeout(()=> {el.style.display='none'}, 300) ;
  163.     el.onmouseover=()=>clearTimeout(tm2);
  164.   }
  165. })()
  166. @@@@@Google Translate
  167. (()=> {
  168. var ac = document.activeElement,
  169. sel = String(getSelection()) || ac.value?.substring(ac.selectionStart, ac.selectionEnd);
  170. setTimeout(()=>{
  171.    var lang = 'auto'; if(e.ctrlKey) lang='de'; if(e.shiftKey) lang='fr';  if(e.ctrlKey && e.shiftKey) lang='es';
  172.    var url = 'https://translate.googleapis.com/translate_a/single?client=gtx&sl=' +lang+ '&tl=ru&hl=ru&eotf=0&dt=bd&dt=t&q=' +encodeURIComponent(sel);
  173.    fetch (url)
  174.      .then(resp => resp.json())
  175.      .then(ip => {
  176.          var arr=[], dict=[], perev2;
  177.          if (ip[1]) {
  178.             for(i=0; i<ip[1].length; i++)
  179.               dict.push('\n\u25CF ' +(ip[1][i][1]).join(', '));
  180.         } else dict = '';
  181.  
  182.         for(i=0; i<ip[0].length; i++){
  183.            arr.push(ip[0][i][0])
  184.         }
  185.        var langu = ip[2].toUpperCase();
  186.        if(ip[1] && ip[1][1])  perev2 = '\u25CF ' +ip[1][1][1].join(', ');
  187.        else perev2='';
  188.        alert ( '[ ' + langu + ' ]\n\n' + arr.join('') + '||' +dict + '\n' +perev2) ;
  189.   }) ;
  190. }, 50)
  191. })()
  192. @@@@@

Raw Paste

Comments 0
Login to post a comment.
  • No comments yet. Be the first.
Login to post a comment. Login or Register
We use cookies. To comply with GDPR in the EU and the UK we have to show you these.

We use cookies and similar technologies to keep this website functional (including spam protection via Google reCAPTCHA or Cloudflare Turnstile), and — with your consent — to measure usage and show ads. See Privacy.