wpcom-colors.php 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584
  1. <?php
  2. /* Custom Colors: Scratchpad */
  3. //Background
  4. add_color_rule( 'bg', '#bdcbcc', array(
  5. array( 'body', 'background-color', '#ffffff', 3 ),
  6. // Colour - contrast against background
  7. array( '#masthead .site-description,
  8. body:not(.single) .format-audio .entry-title a,
  9. body:not(.single) .format-gallery .entry-title a,
  10. body:not(.single) .format-image .entry-title a,
  11. body:not(.single) .format-quote .entry-title a,
  12. body:not(.single) .format-video .entry-title a,
  13. .post-navigation-container a,
  14. .post-navigation-container a:hover,
  15. .page-header p,
  16. .error404 .page-content > p,
  17. .search-no-results .page-content > p,
  18. body:not(.single) .format-audio.post-password-required,
  19. body:not(.single) .format-audio .post-password-form label,
  20. body:not(.single) .format-gallery.post-password-required,
  21. body:not(.single) .format-gallery .post-password-form label,
  22. body:not(.single) .format-image.post-password-required,
  23. body:not(.single) .format-image .post-password-form label,
  24. body:not(.single) .format-video.post-password-required,
  25. body:not(.single) .format-video .post-password-form label,
  26. body:not(.single) .format-audio .post-password-form input[type="submit"],
  27. body:not(.single) .format-gallery .post-password-form input[type="submit"],
  28. body:not(.single) .format-image .post-password-form input[type="submit"],
  29. body:not(.single) .format-video .post-password-form input[type="submit"],
  30. body:not(.single) .format-audio .post-password-form input[type="submit"]:hover,
  31. body:not(.single) .format-audio .post-password-form input[type="submit"]:focus,
  32. body:not(.single) .format-gallery .post-password-form input[type="submit"]:hover,
  33. body:not(.single) .format-gallery .post-password-form input[type="submit"]:focus,
  34. body:not(.single) .format-image .post-password-form input[type="submit"]:hover,
  35. body:not(.single) .format-image .post-password-form input[type="submit"]:focus,
  36. body:not(.single) .format-video .post-password-form input[type="submit"]:hover,
  37. body:not(.single) .format-video .post-password-form input[type="submit"]:focus', 'color', 'bg', 5 ),
  38. array( 'body:not(.single) .format-audio .entry-meta,
  39. body:not(.single) .format-audio .entry-meta a,
  40. body:not(.single) .format-gallery .entry-meta,
  41. body:not(.single) .format-gallery .entry-meta a,
  42. body:not(.single) .format-image .entry-meta,
  43. body:not(.single) .format-image .entry-meta a,
  44. body:not(.single) .format-quote .entry-meta,
  45. body:not(.single) .format-quote .entry-meta a,
  46. body:not(.single) .format-video .entry-meta,
  47. body:not(.single) .format-video .entry-meta a,
  48. #colophon .site-info,
  49. #colophon .site-info a,
  50. #infinite-handle span button,
  51. #infinite-handle span button:hover,
  52. #infinite-handle span button:focus,
  53. .post-navigation-container .post-navigation-header,
  54. .posts-navigation .nav-previous a,
  55. .posts-navigation .nav-next a', 'color', 'bg', 3 ),
  56. array( 'body:not(.single) .format-audio .post-password-form input[type="submit"],
  57. body:not(.single) .format-gallery .post-password-form input[type="submit"],
  58. body:not(.single) .format-image .post-password-form input[type="submit"],
  59. body:not(.single) .format-video .post-password-form input[type="submit"],
  60. body:not(.single) .format-audio .post-password-form input[type="submit"]:hover,
  61. body:not(.single) .format-audio .post-password-form input[type="submit"]:focus,
  62. body:not(.single) .format-gallery .post-password-form input[type="submit"]:hover,
  63. body:not(.single) .format-gallery .post-password-form input[type="submit"]:focus,
  64. body:not(.single) .format-image .post-password-form input[type="submit"]:hover,
  65. body:not(.single) .format-image .post-password-form input[type="submit"]:focus,
  66. body:not(.single) .format-video .post-password-form input[type="submit"]:hover,
  67. body:not(.single) .format-video .post-password-form input[type="submit"]:focus', 'border-color', 'bg', 5 ),
  68. array( '.single #primary .author-info', 'background-color', 0.1 ),
  69. // Background colour - contrast against background
  70. array( '.main-navigation ul ul a', 'background-color', 'bg', 2 ),
  71. array( '.main-navigation ul ul a:hover', 'background-color', 'bg', 3 ),
  72. array( 'body:not(.single) .format-aside,
  73. .widget:nth-of-type(4n+2)', 'background-color', 'bg', 4 ),
  74. array( '.binderclip0,
  75. .line0,
  76. .stamp1', 'fill', 'bg', 3 ),
  77. // Background - slight opacity
  78. array( '.page-links a', 'background-color', 0.2 ),
  79. array( '.page-links a:hover', 'background-color', 0.1 ),
  80. // Border - contrast against background
  81. array( '#infinite-handle span button,
  82. #infinite-handle span button:hover,
  83. #infinite-handle span button:focus,
  84. .posts-navigation .nav-previous a,
  85. .posts-navigation .nav-next a', 'border-color', 'bg', 3 ),
  86. // Border Color - contrast against white - top triangle
  87. array( '.main-navigation ul ul:before', 'border-bottom-color', 'bg', 2 ),
  88. array('.main-navigation ul ul ul:before', 'border-right-color', 'bg', 2 ),
  89. array('.rtl .main-navigation ul ul ul:before', 'border-left-color', 'bg', 2 ),
  90. // Color; already contrasts against this colour
  91. array( 'body:not(.single) .format-aside .entry-header .entry-title a,
  92. .widget:nth-of-type(4n+2),
  93. .widget:nth-of-type(4n+2) a,
  94. .widget:nth-of-type(4n+2) #flickr_badge_uber_wrapper a:hover,
  95. .widget:nth-of-type(4n+2) #flickr_badge_uber_wrapper a:link,
  96. .widget:nth-of-type(4n+2) #flickr_badge_uber_wrapper a:active,
  97. .widget:nth-of-type(4n+2) #flickr_badge_uber_wrapper a:visited,
  98. .widget:nth-of-type(4n+2).widget_goodreads div[class^="gr_custom_author"],
  99. .widget:nth-of-type(4n+2) button,
  100. .widget:nth-of-type(4n+2) input[type="button"],
  101. .widget:nth-of-type(4n+2) input[type="reset"],
  102. .widget:nth-of-type(4n+2) input[type="submit"],
  103. .widget:nth-of-type(4n+2) button:hover,
  104. .widget:nth-of-type(4n+2) input[type="button"]:hover,
  105. .widget:nth-of-type(4n+2) input[type="reset"]:hover,
  106. .widget:nth-of-type(4n+2) input[type="submit"]:hover,
  107. .widget:nth-of-type(4n+2) button:focus,
  108. .widget:nth-of-type(4n+2) input[type="button"]:focus,
  109. .widget:nth-of-type(4n+2) input[type="reset"]:focus,
  110. .widget:nth-of-type(4n+2) input[type="submit"]:focus,
  111. .widget:nth-of-type(4n+2) .wp-caption,
  112. .widget:nth-of-type(4n+2) .wp-caption-text,
  113. .widget:nth-of-type(4n+2) .widget_rss .rss-date,
  114. body:not(.single) .format-aside,
  115. body:not(.single) .format-aside a', 'color' ),
  116. array( 'body:not(.single) .format-aside .entry-content,
  117. body:not(.single) .format-aside input[type="submit"],
  118. body:not(.single) .format-aside input[type="submit"]:hover,
  119. body:not(.single) .format-aside input[type="submit"]:focus,
  120. body:not(.single) .format-aside .post-password-form label', 'color', 0.8 ),
  121. array( 'body:not(.single) .format-aside input[type="submit"],
  122. body:not(.single) .format-aside input[type="submit"]:hover,
  123. body:not(.single) .format-aside input[type="submit"]:focus', 'border-color', 0.8 ),
  124. array( 'body:not(.single) .format-aside .entry-meta,
  125. body:not(.single) .format-aside .entry-meta .entry-meta,
  126. body:not(.single) .format-aside .entry-meta a', 'color', 0.6 ),
  127. // Border Colour; bg already contrasts against this colour
  128. array('.widget:nth-of-type(4n+2).widget_archive > ul,
  129. .widget:nth-of-type(4n+2).widget_archive li,
  130. .widget:nth-of-type(4n+2).widget_categories > ul,
  131. .widget:nth-of-type(4n+2).widget_categories li,
  132. .widget:nth-of-type(4n+2).widget_jp_blogs_i_follow > ol,
  133. .widget:nth-of-type(4n+2).widget_jp_blogs_i_follow li,
  134. .widget:nth-of-type(4n+2).widget_jetpack_posts_i_like > ul,
  135. .widget:nth-of-type(4n+2).widget_jetpack_posts_i_like li,
  136. .widget:nth-of-type(4n+2).widget_links > ul,
  137. .widget:nth-of-type(4n+2).widget_links li,
  138. .widget:nth-of-type(4n+2).widget_meta > ul,
  139. .widget:nth-of-type(4n+2).widget_meta li,
  140. .widget:nth-of-type(4n+2).widget_nav_menu > ul,
  141. .widget:nth-of-type(4n+2).widget_nav_menu li,
  142. .widget:nth-of-type(4n+2).widget_pages > ul,
  143. .widget:nth-of-type(4n+2).widget_pages li,
  144. .widget:nth-of-type(4n+2).widget_recent_entries > ul,
  145. .widget:nth-of-type(4n+2).widget_recent_entries li,
  146. .widget:nth-of-type(4n+2).widget_recent_comments > ul,
  147. .widget:nth-of-type(4n+2).widget_recent_comments li,
  148. .widget:nth-of-type(4n+2).widget_rss > ul,
  149. .widget:nth-of-type(4n+2).widget_rss li,
  150. .widget:nth-of-type(4n+2).widget_rss_links > ul,
  151. .widget:nth-of-type(4n+2).widget_rss_links li,
  152. .widget:nth-of-type(4n+2).widget_top-clicks > ul,
  153. .widget:nth-of-type(4n+2).widget_top-clicks li,
  154. .widget:nth-of-type(4n+2).widget_top-posts > ul,
  155. .widget:nth-of-type(4n+2).widget_top-posts li,
  156. .widget:nth-of-type(4n+2).widget.top_rated #top_posts,
  157. .widget:nth-of-type(4n+2).widget.top_rated li,
  158. .widget:nth-of-type(4n+2) table,
  159. .widget:nth-of-type(4n+2) table td,
  160. .widget:nth-of-type(4n+2) table th,
  161. .widget:nth-of-type(4n+2).widget_goodreads div[class^="gr_custom_each_container"],
  162. .widget:nth-of-type(4n+2).widget_goodreads div[class^="gr_custom_container"],
  163. .widget:nth-of-type(4n+2) button,
  164. .widget:nth-of-type(4n+2) input[type="button"],
  165. .widget:nth-of-type(4n+2) input[type="reset"],
  166. .widget:nth-of-type(4n+2) input[type="submit"],
  167. .widget:nth-of-type(4n+2) button:hover,
  168. .widget:nth-of-type(4n+2) input[type="button"]:hover,
  169. .widget:nth-of-type(4n+2) input[type="reset"]:hover,
  170. .widget:nth-of-type(4n+2) input[type="submit"]:hover,
  171. .widget:nth-of-type(4n+2) button:focus,
  172. .widget:nth-of-type(4n+2) input[type="button"]:focus,
  173. .widget:nth-of-type(4n+2) input[type="reset"]:focus,
  174. .widget:nth-of-type(4n+2) input[type="submit"]:focus,
  175. .widget:nth-of-type(4n+2) .wp-caption,
  176. .widget:nth-of-type(4n+2) .wp-caption-text,
  177. .widget:nth-of-type(4n+2).widget_calendar tbody td a:after', 'border-color' ),
  178. // Colour - contrast against white
  179. array( 'a,
  180. a:hover,
  181. a:focus,
  182. a:active,
  183. .single #primary .author-link:hover,
  184. .page-links,
  185. .page-links span,
  186. .page-header .page-title,
  187. .page .edit-link a', 'color', '#ffffff', 5 ),
  188. array( '.main-navigation a,
  189. .single #primary article.post .tags-links a,
  190. .single #primary article.jetpack-portfolio .tags-links a,
  191. .single #primary article.attachment .tags-links a,
  192. .single #primary .author-link', 'color', '#ffffff', 3 ),
  193. // Border colour - contrast against white
  194. array( '.page-header .page-title:before,
  195. .page-header .page-title:after', 'border-color', '#ffffff', 2 ),
  196. ),
  197. __( 'Color 1' ) );
  198. // Blue
  199. add_color_rule( 'txt', '#2a44b6', array(
  200. // Colour
  201. array( 'body:not(.single) .format-status,
  202. .widget:nth-of-type(4n+1),
  203. .widget:nth-of-type(4n+1) a,
  204. .widget:nth-of-type(4n+1) #flickr_badge_uber_wrapper a:hover,
  205. .widget:nth-of-type(4n+1) #flickr_badge_uber_wrapper a:link,
  206. .widget:nth-of-type(4n+1) #flickr_badge_uber_wrapper a:active,
  207. .widget:nth-of-type(4n+1) #flickr_badge_uber_wrapper a:visited,
  208. .widget:nth-of-type(4n+1).widget_goodreads div[class^="gr_custom_author"],
  209. .widget:nth-of-type(4n+1) button,
  210. .widget:nth-of-type(4n+1) input[type="button"],
  211. .widget:nth-of-type(4n+1) input[type="reset"],
  212. .widget:nth-of-type(4n+1) input[type="submit"],
  213. .widget:nth-of-type(4n+1) button:hover,
  214. .widget:nth-of-type(4n+1) input[type="button"]:hover,
  215. .widget:nth-of-type(4n+1) input[type="reset"]:hover,
  216. .widget:nth-of-type(4n+1) input[type="submit"]:hover,
  217. .widget:nth-of-type(4n+1) button:focus,
  218. .widget:nth-of-type(4n+1) input[type="button"]:focus,
  219. .widget:nth-of-type(4n+1) input[type="reset"]:focus,
  220. .widget:nth-of-type(4n+1) input[type="submit"]:focus,
  221. .widget:nth-of-type(4n+1) .wp-caption,
  222. .widget:nth-of-type(4n+1) .wp-caption-text,
  223. .widget:nth-of-type(4n+1) .widget_rss .rss-date', 'color', '#ffffff', 4 ),
  224. array( 'body:not(.single) .format-status .entry-meta,
  225. body:not(.single) .format-status .entry-meta a', 'color', '#ffffff', 3 ),
  226. // Border Colour
  227. array( '.widget:nth-of-type(4n+1) button,
  228. .widget:nth-of-type(4n+1) input[type="button"],
  229. .widget:nth-of-type(4n+1) input[type="reset"],
  230. .widget:nth-of-type(4n+1) input[type="submit"],
  231. .widget:nth-of-type(4n+1) button:hover,
  232. .widget:nth-of-type(4n+1) input[type="button"]:hover,
  233. .widget:nth-of-type(4n+1) input[type="reset"]:hover,
  234. .widget:nth-of-type(4n+1) input[type="submit"]:hover,
  235. .widget:nth-of-type(4n+1) button:focus,
  236. .widget:nth-of-type(4n+1) input[type="button"]:focus,
  237. .widget:nth-of-type(4n+1) input[type="reset"]:focus,
  238. .widget:nth-of-type(4n+1) input[type="submit"]:focus,
  239. .widget:nth-of-type(4n+1) .wp-caption,
  240. .widget:nth-of-type(4n+1) .wp-caption-text,
  241. .widget:nth-of-type(4n+1).widget_calendar tbody td a:after', 'border-color', '#ffffff', 2 ),
  242. // Fill
  243. array( '.pen0', 'fill', '#ffffff', 3 ),
  244. ),
  245. __( 'Color 2' ) );
  246. // Orange
  247. add_color_rule( 'link', '#d16221', array(
  248. // Background colour - contrast against white
  249. array( 'article .mejs-container.mejs-audio', 'background-color', '#ffffff', 3 ),
  250. // Background color - contrast against link
  251. array( 'article .mejs-controls .mejs-time-rail .mejs-time-total,
  252. article .mejs-controls .mejs-horizontal-volume-slider .mejs-horizontal-volume-total', 'background-color', 'link', 4 ),
  253. array( 'article .mejs-audio .mejs-controls .mejs-time-rail .mejs-time-loaded,
  254. article .mejs-audio .mejs-controls .mejs-horizontal-volume-slider .mejs-horizontal-volume-current', 'background-color', 'link', 3 ),
  255. // Colour - contrast against white
  256. array( '.cat-links a,
  257. body:not(.single) .hentry .more-link:hover,
  258. body:not(.single) .format-link .entry-header a,
  259. .single #primary article.post .tags-links .tags-header,
  260. .single #primary article.jetpack-portfolio .tags-links .tags-header,
  261. .single #primary article.attachment .tags-links .tags-header,
  262. .page #primary article.page .tags-links .tags-header', 'color', '#ffffff' ),
  263. // Border colour
  264. array( '.page-header .page-title,
  265. .widget_calendar tbody td a:hover:after', 'border-color' ),
  266. array( '.page-links span:after', 'border-color', '#ffffff', 2 ),
  267. // Fill
  268. array( '.pencil0,
  269. .movie-ticket0', 'fill', '#ffffff' ),
  270. ),
  271. __( 'Color 3' ) );
  272. // Light yellow
  273. add_color_rule( 'fg1', '#efe8be', array(
  274. // Background-color
  275. array( 'body:not(.single) .format-quote .entry-content,
  276. .widget:nth-of-type(4n+3)', 'background-color' ),
  277. // Color - contrast against this colour
  278. array( 'body:not(.single) .format-quote .entry-content', 'color', 'fg1', 4 ),
  279. array( '.widget:nth-of-type(4n+3),
  280. .widget:nth-of-type(4n+3) a,
  281. .widget:nth-of-type(4n+3) #flickr_badge_uber_wrapper a:hover,
  282. .widget:nth-of-type(4n+3) #flickr_badge_uber_wrapper a:link,
  283. .widget:nth-of-type(4n+3) #flickr_badge_uber_wrapper a:active,
  284. .widget:nth-of-type(4n+3) #flickr_badge_uber_wrapper a:visited,
  285. .widget:nth-of-type(4n+3).widget_goodreads div[class^="gr_custom_author"],
  286. .widget:nth-of-type(4n+3) button,
  287. .widget:nth-of-type(4n+3) input[type="button"],
  288. .widget:nth-of-type(4n+3) input[type="reset"],
  289. .widget:nth-of-type(4n+3) input[type="submit"],
  290. .widget:nth-of-type(4n+3) button:hover,
  291. .widget:nth-of-type(4n+3) input[type="button"]:hover,
  292. .widget:nth-of-type(4n+3) input[type="reset"]:hover,
  293. .widget:nth-of-type(4n+3) input[type="submit"]:hover,
  294. .widget:nth-of-type(4n+3) button:focus,
  295. .widget:nth-of-type(4n+3) input[type="button"]:focus,
  296. .widget:nth-of-type(4n+3) input[type="reset"]:focus,
  297. .widget:nth-of-type(4n+3) input[type="submit"]:focus,
  298. .widget:nth-of-type(4n+3) .wp-caption,
  299. .widget:nth-of-type(4n+3) .wp-caption-text,
  300. .widget:nth-of-type(4n+3) .widget_rss .rss-date', 'color', 'fg1', 6 ),
  301. array( 'body:not(.single) .format-quote .entry-content .quote', 'fill', 'fg1', 2),
  302. // Border colour - contrast against this colour
  303. array( '.widget:nth-of-type(4n+3) button,
  304. .widget:nth-of-type(4n+3) input[type="button"],
  305. .widget:nth-of-type(4n+3) input[type="reset"],
  306. .widget:nth-of-type(4n+3) input[type="submit"],
  307. .widget:nth-of-type(4n+3) button:hover,
  308. .widget:nth-of-type(4n+3) input[type="button"]:hover,
  309. .widget:nth-of-type(4n+3) input[type="reset"]:hover,
  310. .widget:nth-of-type(4n+3) input[type="submit"]:hover,
  311. .widget:nth-of-type(4n+3) button:focus,
  312. .widget:nth-of-type(4n+3) input[type="button"]:focus,
  313. .widget:nth-of-type(4n+3) input[type="reset"]:focus,
  314. .widget:nth-of-type(4n+3) input[type="submit"]:focus,
  315. .widget:nth-of-type(4n+3) .wp-caption,
  316. .widget:nth-of-type(4n+3) .wp-caption-text,
  317. .widget:nth-of-type(4n+3).widget_calendar tbody td a:after', 'border-color', 'fg1', 2 ),
  318. ),
  319. __( 'Color 4' ) );
  320. // Bright Blue
  321. add_color_rule( 'fg2', '#2590ec', array(
  322. // Background color
  323. array( '.widget:nth-of-type(4n+4)', 'background-color' ),
  324. // Background color - contrast against while
  325. array( '.entry-content .jetpack-recipe-title', 'background-color', '#ffffff', 3 ),
  326. // Color - contrast against this color
  327. array( '.widget:nth-of-type(4n+4),
  328. .widget:nth-of-type(4n+4) a,
  329. .widget:nth-of-type(4n+4) #flickr_badge_uber_wrapper a:hover,
  330. .widget:nth-of-type(4n+4) #flickr_badge_uber_wrapper a:link,
  331. .widget:nth-of-type(4n+4) #flickr_badge_uber_wrapper a:active,
  332. .widget:nth-of-type(4n+4) #flickr_badge_uber_wrapper a:visited,
  333. .widget:nth-of-type(4n+4).widget_goodreads div[class^="gr_custom_author"],
  334. .widget:nth-of-type(4n+4) button,
  335. .widget:nth-of-type(4n+4) input[type="button"],
  336. .widget:nth-of-type(4n+4) input[type="reset"],
  337. .widget:nth-of-type(4n+4) input[type="submit"],
  338. .widget:nth-of-type(4n+4) button:hover,
  339. .widget:nth-of-type(4n+4) input[type="button"]:hover,
  340. .widget:nth-of-type(4n+4) input[type="reset"]:hover,
  341. .widget:nth-of-type(4n+4) input[type="submit"]:hover,
  342. .widget:nth-of-type(4n+4) button:focus,
  343. .widget:nth-of-type(4n+4) input[type="button"]:focus,
  344. .widget:nth-of-type(4n+4) input[type="reset"]:focus,
  345. .widget:nth-of-type(4n+4) input[type="submit"]:focus,
  346. .widget:nth-of-type(4n+4) .wp-caption,
  347. .widget:nth-of-type(4n+4) .wp-caption-text,
  348. .widget:nth-of-type(4n+4) .widget_rss .rss-date', 'color', 'fg2', 6 ),
  349. // Border colour - contrast against this colour
  350. array( '.widget:nth-of-type(4n+4).widget_archive > ul,
  351. .widget:nth-of-type(4n+4).widget_archive li,
  352. .widget:nth-of-type(4n+4).widget_categories > ul,
  353. .widget:nth-of-type(4n+4).widget_categories li,
  354. .widget:nth-of-type(4n+4).widget_jp_blogs_i_follow > ol,
  355. .widget:nth-of-type(4n+4).widget_jp_blogs_i_follow li,
  356. .widget:nth-of-type(4n+4).widget_jetpack_posts_i_like > ul,
  357. .widget:nth-of-type(4n+4).widget_jetpack_posts_i_like li,
  358. .widget:nth-of-type(4n+4).widget_links > ul,
  359. .widget:nth-of-type(4n+4).widget_links li,
  360. .widget:nth-of-type(4n+4).widget_meta > ul,
  361. .widget:nth-of-type(4n+4).widget_meta li,
  362. .widget:nth-of-type(4n+4).widget_nav_menu > ul,
  363. .widget:nth-of-type(4n+4).widget_nav_menu li,
  364. .widget:nth-of-type(4n+4).widget_pages > ul,
  365. .widget:nth-of-type(4n+4).widget_pages li,
  366. .widget:nth-of-type(4n+4).widget_recent_entries > ul,
  367. .widget:nth-of-type(4n+4).widget_recent_entries li,
  368. .widget:nth-of-type(4n+4).widget_recent_comments > ul,
  369. .widget:nth-of-type(4n+4).widget_recent_comments li,
  370. .widget:nth-of-type(4n+4).widget_rss > ul,
  371. .widget:nth-of-type(4n+4).widget_rss li,
  372. .widget:nth-of-type(4n+4).widget_rss_links > ul,
  373. .widget:nth-of-type(4n+4).widget_rss_links li,
  374. .widget:nth-of-type(4n+4).widget_top-clicks > ul,
  375. .widget:nth-of-type(4n+4).widget_top-clicks li,
  376. .widget:nth-of-type(4n+4).widget_top-posts > ul,
  377. .widget:nth-of-type(4n+4).widget_top-posts li,
  378. .widget:nth-of-type(4n+4).widget.top_rated #top_posts,
  379. .widget:nth-of-type(4n+4).widget.top_rated li,
  380. .widget:nth-of-type(4n+4) table,
  381. .widget:nth-of-type(4n+4) table td,
  382. .widget:nth-of-type(4n+4) table th,
  383. .widget:nth-of-type(4n+4).widget_goodreads div[class^="gr_custom_each_container"],
  384. .widget:nth-of-type(4n+4).widget_goodreads div[class^="gr_custom_container"],
  385. .widget:nth-of-type(4n+4) button,
  386. .widget:nth-of-type(4n+4) input[type="button"],
  387. .widget:nth-of-type(4n+4) input[type="reset"],
  388. .widget:nth-of-type(4n+4) input[type="submit"],
  389. .widget:nth-of-type(4n+4) button:hover,
  390. .widget:nth-of-type(4n+4) input[type="button"]:hover,
  391. .widget:nth-of-type(4n+4) input[type="reset"]:hover,
  392. .widget:nth-of-type(4n+4) input[type="submit"]:hover,
  393. .widget:nth-of-type(4n+4) button:focus,
  394. .widget:nth-of-type(4n+4) input[type="button"]:focus,
  395. .widget:nth-of-type(4n+4) input[type="reset"]:focus,
  396. .widget:nth-of-type(4n+4) input[type="submit"]:focus,
  397. .widget:nth-of-type(4n+4) .wp-caption,
  398. .widget:nth-of-type(4n+4) .wp-caption-text,
  399. .widget:nth-of-type(4n+4).widget_calendar tbody td a:after', 'border-color', 'fg2', 2 ),
  400. // Border color - contrast against white
  401. array( '.entry-content .jetpack-recipe:before,
  402. .entry-content .jetpack-recipe .jetpack-recipe-content', 'border-color', '#ffffff', 2 ),
  403. // Fill
  404. array( '.grip-pencil0,
  405. .grip-pencil2', 'fill', 'bg', 3 ),
  406. ),
  407. __( 'Color 5' ) );
  408. add_color_rule( 'extra', '#ffffff', array(
  409. // Colour - contrast against bg
  410. array( '#masthead .site-title a', 'color', 'bg', 6 ),
  411. ),
  412. '' );
  413. add_color_rule( 'extra', '#444444', array(
  414. // Fill - contrast against bg
  415. // array( '.highlighter0', 'fill', 'bg', 2 ),
  416. ),
  417. '' );
  418. /* Extra CSS */
  419. function scratchpad_extra_css() { ?>
  420. #page:before {
  421. background: -moz-radial-gradient(center, ellipse cover, rgba(255,255,255,0.35) 0%, rgba(255,255,255,0) 50%, rgba(255,255,255,0) 100%); /* FF3.6-15 */
  422. background: -webkit-radial-gradient(center, ellipse cover, rgba(255,255,255,0.35) 0%,rgba(255,255,255,0) 50%,rgba(255,255,255,0) 100%); /* Chrome10-25,Safari5.1-6 */
  423. background: radial-gradient(ellipse at center, rgba(255,255,255,0.35) 0%,rgba(255,255,255,0) 50%,rgba(255,255,255,0) 100%); /* W3C, IE10+, FF16+, Chrome26+, Opera12+, Safari7+ */
  424. filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#59ffffff', endColorstr='#00ffffff',GradientType=1 ); /* IE6-9 fallback on horizontal gradient */
  425. }
  426. /* Menu */
  427. .main-navigation ul ul a {
  428. border-color: rgba(255,255,255,0.3);
  429. }
  430. .main-navigation ul ul li:last-child a {
  431. border: 0;
  432. }
  433. /* Post background colours */
  434. body:not(.single) .format-standard,
  435. body:not(.single) .format-chat,
  436. .single #primary article.post,
  437. .single #primary article.jetpack-portfolio,
  438. .single #primary article.attachment,
  439. .page #primary article.page,
  440. .search .type-page {
  441. background-color: #fff;
  442. }
  443. /* Background patterns - grid */
  444. body:not(.single) .format-quote .entry-content,
  445. .widget:nth-of-type(4n+3) {
  446. background-image: linear-gradient(rgba(0,0,0,0.1) 1px, transparent 1px), linear-gradient(90deg, rgba(0,0,0,0.1) 1px, transparent 1px);
  447. }
  448. /* Background patterns - torn paper */
  449. body:not(.single) .format-status span.paper-top {
  450. background-image: linear-gradient(90deg, #<?php echo get_background_color(); ?> 7px, transparent 7px), radial-gradient(#<?php echo get_background_color(); ?> 8px, transparent 8px);
  451. }
  452. /* Underlines */
  453. .entry-header .entry-title a:hover,
  454. .post-navigation-container a:hover,
  455. .single #primary .author-description h2 a:hover {
  456. box-shadow: inset 0 -5px 0 0 rgba(0,0,0,0.1);;
  457. }
  458. /* Ruler */
  459. article .mejs-container.mejs-audio {
  460. background-image: linear-gradient(90deg, rgba(255,255,255,0.1) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,0.1) 1px, transparent 1px)
  461. }
  462. /* Pen */
  463. .pen1 {
  464. opacity: 0.6;
  465. }
  466. /* Stamp */
  467. .stamp2 {
  468. fill: rgba(255,255,255,0.5);
  469. }
  470. @media only screen and (max-width: 800px) {
  471. #masthead .main-navigation a,
  472. #masthead .main-navigation ul ul a {
  473. background-color: transparent;
  474. color: inherit;
  475. }
  476. #masthead .main-navigation a:hover,
  477. #masthead .main-navigation ul ul a:hover {
  478. color: #333;
  479. }
  480. }
  481. <?php
  482. }
  483. add_theme_support( 'custom_colors_extra_css', 'scratchpad_extra_css' );
  484. //Additional palettes
  485. add_color_palette( array(
  486. '#4b596c',
  487. '#e97633',
  488. '#c44d58',
  489. '#e4b3b3',
  490. '#a6b4c8',
  491. ), 'Featured 1' );
  492. add_color_palette( array(
  493. '#c44d58',
  494. '#537349',
  495. '#ced89d',
  496. '#dfba74',
  497. '#f1edd0'
  498. ), 'Featured 2' );
  499. add_color_palette( array(
  500. '#c9d1d3',
  501. '#d2411c',
  502. '#4d8da1',
  503. '#504d4d',
  504. '#f2f2f2'
  505. ), 'Featured 3' );
  506. add_color_palette( array(
  507. '#2790b0',
  508. '#4e4d4a',
  509. '#94ba65',
  510. '#98d1e6',
  511. '#dbe6ca'
  512. ), 'Featured 4' );
  513. add_color_palette( array(
  514. '#793a57',
  515. '#cf1040',
  516. '#73a99d',
  517. '#e1c479',
  518. '#98d1e6'
  519. ), 'Featured 5' );