Advertisement
Guest User

oh no why

a guest
Oct 27th, 2017
61
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. // ==UserScript==
  2. // @name        ZEN-Ifier
  3. // @namespace   kak-test
  4. // @description WELP
  5. // @include     http://board.kafuka.org/*
  6. // @version     3
  7. // @grant       none
  8. // ==/UserScript==
  9.  
  10.  
  11. //window.addEventListener('load', function() {
  12.  
  13.   // Disable the current CSS
  14.   var defs = document.getElementsByTagName("link");
  15.   for (var i = 0; i < defs.length; i++) {
  16.     //console.log("(" + i + ") | " + defs[i].getAttribute("href") + "<br>");
  17.     if (defs[i].getAttribute("href").substr(0, 3) == "css") {
  18.       // Found the CSS declaration
  19.       // alert("Got it at " + i + " !");
  20.       defs[i].disabled= true;
  21.       break;
  22.     }
  23.   }
  24. if (false) {
  25.   // :V :V :V (simulates Jul header and removes attn box)
  26.   defs = document.getElementsByTagName("img");
  27.   for (var i = 0; i < defs.length; i++) {
  28.     if (defs[i].getAttribute("src").substr(0, 5) == "theme") {
  29.       defs[i].src = "http://jul.rustedlogic.net/images/zen/zentitle.png";
  30.       //               IMG .A         .TD        .OTHER TD (ATTNBOX)
  31.       var attnbox = defs[i].parentNode.parentNode.nextElementSibling;
  32.       attnbox.parentNode.removeChild(attnbox); // RIP
  33.       break;
  34.     }
  35.   }
  36.  }
  37.   // Place the new one
  38.   addHeadTag("style", "" +
  39. "a { color: #BEFEBA; } " +
  40. "a:visited { color: #99c090; } " +
  41. "a:active { color: #CFFFBE; } " +
  42. "a:hover { color: #CEFECA; } " +
  43. " " +
  44. "a:link, a:visited, a:active, a:hover { " +
  45. " text-decoration: none; " +
  46. " font-weight: bold; " +
  47. "} " +
  48. " " +
  49. "body { " +
  50. " color: #DDDDDD; " +
  51. " font: 13px verdana; " +
  52. " background: #010; " +
  53. "} " +
  54. "body, table, td, .c1, .c2 { " +
  55. " font: 13px verdana; " +
  56. "} " +
  57. " " +
  58. ".c1,.c2 { " +
  59. " width: 100%; " +
  60. " border-collapse: collapse; " +
  61. " empty-cells: show; width: 100%; " +
  62. " border-top: #001100 1px solid; " +
  63. " border-left: #001100 1px solid; " +
  64. " border-spacing: 0px; " +
  65. "} " +
  66. //".b { border: 1px solid #875857;} " +
  67. ".n1,.c1 { background: #005028; } " +
  68. ".n2,.c2 { background: #104830; } " +
  69. ".h { " +
  70. " background: #007c00 url('http://jul.rustedlogic.net/images/zen/header.png') repeat-x top center; " +
  71. " text-shadow: 1px 1px 2px #000; " +
  72. " color: #AAFFCC; " +
  73. "} " +
  74. ".c { background:#005020 url('http://jul.rustedlogic.net/images/zen/t1.png') repeat-x top center; } " +
  75. ".h,.c { " +
  76. " text-align: center; " +
  77. "} " +
  78. "td.h, td.c, td.n1, td.n2, .b { " +
  79. " border-right: #001100 1px solid; " +
  80. " border-bottom: #001100 1px solid " +
  81. "} " +
  82. "textarea,input,select{ " +
  83. " border: #000000 solid 1px; " +
  84. " background:#000000; " +
  85. " color: #DDDDDD; " +
  86. " font: 10pt verdana;} " +
  87. "textarea:focus { " +
  88. " border: #000000 solid 1px; " +
  89. " background:#000000; " +
  90. " color: #DDDDDD; " +
  91. " font: 10pt verdana;} " +
  92. "input[type=radio]{ " +
  93. " border: none; " +
  94. " background:none; " +
  95. " color: #DDDDDD; " +
  96. " font: 10pt verdana;} " +
  97. "input[type=submit]{ " +
  98. " border: #000000 solid 2px; " +
  99. " font: 10pt verdana;} " +
  100. " " +
  101. ".sfont { " +
  102. " font-size: 0.8em; " +
  103. " font-family: verdana; " +
  104. "} " +
  105. " " +
  106. ".nc0x{color:#888888} .nc1x{color:#888888} .nc2x{color:#888888} " +
  107. ".nc00{color:#97ACEF} .nc10{color:#F185C9} .nc20{color:#7C60B0} " +
  108. ".nc01{color:#D8E8FE} .nc11{color:#FFB3F3} .nc21{color:#EEB9BA} " +
  109. ".nc02{color:#AFFABE} .nc12{color:#C762F2} .nc22{color:#47B53C} " +
  110. ".nc03{color:#FFEA95} .nc13{color:#C53A9E} .nc23{color:#F0C413}"
  111.   );
  112.  
  113. //}, false);
  114.  
  115.  
  116. function addHeadTag(tag, contents) {
  117.  
  118.   var e = document.createElement(tag);
  119.   var t = document.createTextNode(contents);
  120.   e.appendChild(t);
  121.   document.head.appendChild(e);
  122. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement