Advertisement
Shiny_

Untitled

Oct 30th, 2014
440
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. // ==UserScript==
  2. // @name            Wykop - Fullscreen Mikro
  3. // @description     Mikroblog na całą szerokość ekranu.
  4. // @author          Patryk "Linux__Shines" N oraz P0lip.
  5. // @version         1.0.0.0
  6. // @include         http://www.wykop.pl/tag/*
  7. // @include         http://www.wykop.pl/mikroblog/*
  8. // @include         http://www.wykop.pl/wpis/*
  9. // @include         http://www.wykop.pl/moj/*
  10. // @include         http://www.wykop.pl/ludzie/*
  11. // @include         http://www.wykop.pl/wiadomosc-prywatna/*
  12. // @updateURL       https://openuserjs.org/install/The_Shiny/Wykop_-_Fullscreen_Mikro.user.js
  13. // @grant           none
  14. // @license         BSD
  15. // ==/UserScript==
  16.  
  17. ///TODO:
  18. // * Zamienić kolory belki z "Wykopalisko", "Hity", "Mikroblog", "Mój Wykop"
  19. // * Zamienić kolory nagłówków na głównej
  20. // * Zamienić kolor przycisku "Szukaj" oraz reszty
  21. // * Zamienić kolory linków na głównej
  22.  
  23. ///* Kolory: *///
  24. var orange      = "#FF5917 !important;";
  25. var lightblue   = "#4383AF !important;";
  26. var white_un    = "#FFFFFF;";
  27. var white       = "#FFFFFF !important;";
  28. var black       = "#000000 !important;";
  29. var gray        = "#555555 !important;";
  30. var teal        = "#CFE0E8 !important;";
  31. var darkteal    = "#A2C4D4 !important;";
  32. var nav_focus   = "#DEEBF1 !important;";
  33. var navfocus_un = "#DEEBF1;";
  34.  
  35. var background  = "http://i.imgur.com/Y9zPxy7.png";
  36. var logo_normal = "http://i.imgur.com/Tyinjgx.png";
  37. var logo_hover  = "http://i.imgur.com/RhpC99v.png";
  38. var digg_button = "http://i.imgur.com/L6avdgg.png";
  39.  
  40. var style = ["<style>" +
  41. "    #site {" +
  42. "        background-color: " + white +
  43. "    }" +
  44. "" +
  45. "    #nav {" +
  46. "        background-image: url('" + background + "') !important;" +
  47. "        height: 100px !important;" +
  48. "    }" +
  49. "" +
  50. "    #nav .nav li a {" +
  51. "        color: " + white_un +
  52. "    }" +
  53. "" +
  54. "    #nav .nav li a:hover, #nav .nav li.active a {" +
  55. "        color: " + nav_focus +
  56. "    }" +
  57. "" +
  58. "    .clearfix.m-reset-position {" +
  59. "        margin-top: -50px !important;" +
  60. "    }" +
  61. "" +
  62. "    .m-reset-padding.m-reset-margin {" +
  63. "        margin-top: 50px !important;" +
  64. "    }" +
  65. "" +
  66. "    .clearfix.mainnav {" +
  67. "        height: auto !important;" +
  68. "    }" +
  69. "" +
  70. "    /* Zmiana pozycji przycisków, które są PO przycisku przekierowującym na główną stronę portalu. */" +
  71. "    .mainnav li:nth-child(2) {" +
  72. "        width: 100% !important;" +
  73. "    }" +
  74. "" +
  75. "    #openNaturalSearch[href='http://www.wykop.pl/szukaj/'], #openNaturalSearch[href='http://www.wykop.pl/szukaj/']:hover {" +
  76. "        color: " + black +
  77. "        bottom: 50px;" +
  78. "        position: absolute;" +
  79. "        right: 0 !important;" +
  80. "    }" +
  81. "" +
  82. "    /* Zmiana szerokości pola od wyszukiwarki. */" +
  83. "    input[name='nsQ'] {" +
  84. "        position: absolute;" +
  85. "        width: 134% !important;" +
  86. "    }" +
  87. "" +
  88. "    ul:not(.mainnav).clearfix > li {" +
  89. "        height: auto;" +
  90. "    }" +
  91. "" +
  92. "    .nav ul:not(.mainnav).clearfix {" +
  93. "        display: inline-flex;" +
  94. "        height: 100%;" +
  95. "        align-items: flex-end;" +
  96. "    }" +
  97. "" +
  98. "    .nav ul:not(.mainnav).clearfix:first-child {" +
  99. "        align-self: flex-start;" +
  100. "    }" +
  101. ""+
  102. "    ul.clearfix .logged-user {" +
  103. "        margin-bottom: 10px !important;" +
  104. "    } " +
  105. "" +
  106. "    #nav .nav li.active a {" +
  107. "        background-color: transparent !important;" +
  108. "    }" +
  109. "" +
  110. "    em.mark-number {" +
  111. "        background-color: transparent !important;" +
  112. "        color: #FFFFFF !important;" +
  113. "    }" +
  114. "" +
  115. "    em.mark-number:before {" +
  116. "        content: '(';" +
  117. "    }" +
  118. "" +
  119. "    em.mark-number:after {" +
  120. "        content: ')';" +
  121. "    }" +
  122. "" +
  123. "    .diggbox span:first-child {" +
  124. "        background: url('" + digg_button + "') no-repeat scroll 0 0 rgba(0, 0, 0, 0);" +
  125. "        color: #3b708a;" +
  126. "    }" +
  127. "" +
  128. "    em.mark-number {" +
  129. "        color: " + white +
  130. "    }" +
  131. "" +
  132. "    em.mark-number:hover {" +
  133. "        color: " + nav_focus +
  134. "    }" +
  135. "" +
  136. "    .clearfix.mainnav > li "+
  137. "        color: " + orange +
  138. "    }" +
  139. "" +
  140. "    .diggbox span:first-child"+
  141. "        color: " + orange +
  142. "    }" +
  143. "" +
  144. "    .clearfix a {" +
  145. "        color: " + orange +
  146. "    }" +
  147. "" +
  148. "    .diggbox span:first-child, .active > a, .lcontrast.m-reset-margin a {" +
  149. "        color: " + orange +
  150. "    }" +
  151. "" +
  152. "    i.wykop-logo, i.microblog-logo {" +
  153. "        background-image: url('" + logo_normal + "') !important;" +
  154. "    }" +
  155. "" +
  156. "    i.wykop-logo:hover, i.microblog-logo:hover {" +
  157. "        background-image: url('" + logo_hover + "') !important;" +
  158. "    }" +
  159. "" +
  160. "    .active > a {" +
  161. "        background-color: transparent !important;" +
  162. "    }" +
  163. "" +
  164. "    #footer {" +
  165. "        background-color: #FFFFFF !important;" +
  166. "        color: " + lightblue +
  167. "    }" +
  168. "" +
  169. "    #footer a {" +
  170. "        color: " + lightblue +
  171. "    }" +
  172. "" +
  173. "    #footer a:hover, #footer .width-one-fourth a:hover {" +
  174. "        color: " + orange +
  175. "        opacity: 1.0;" +
  176. "    }" +
  177. "" +
  178. "    #footer h4 {" +
  179. "        color: " + gray +
  180. "    }" +
  181. "" +
  182. "    #footer .wrapper {" +
  183. "        background-color: " + teal +
  184. "        border: 2px solid " + darkteal +
  185. "        border-radius: 20px !important;" +
  186. "        border-top-left-radius: 20px !important;" +
  187. "       padding: 20px 10px;" +
  188. "    }" +
  189. "" +
  190. "</style>"].join("\n");
  191. $("#searcher").addClass("#openNaturalSearch");
  192. document.head.insertAdjacentHTML("beforeend", style);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement