From: Samir Benmendil Date: Tue, 27 Jan 2015 18:38:58 +0000 (+0000) Subject: dwb: add wikipedia userstyle X-Git-Url: https://git.rmz.io/dotfiles.git/commitdiff_plain/6d93937e28fefc34082d657a4e23b686406d7d46?ds=sidebyside dwb: add wikipedia userstyle --- diff --git a/dwb/userscripts/extension_loader.js b/dwb/userscripts/extension_loader.js index f00518d..47942bd 100644 --- a/dwb/userscripts/extension_loader.js +++ b/dwb/userscripts/extension_loader.js @@ -121,6 +121,7 @@ domains : { "tardis.uni.cx" : { "user-stylesheet-uri" : "" }, "thetvdb.com" : { "user-stylesheet-uri" : "" }, "usenet-crawler.com" : { "user-stylesheet-uri" : "" }, + "wikipedia.org" : { "user-stylesheet-uri" : "file:///home/ramsi/.config/dwb/userstyles/wikipedia.org.css" }, }, //Settings applied based on the hostname hosts : { diff --git a/dwb/userstyles/wikipedia.org.css b/dwb/userstyles/wikipedia.org.css new file mode 100644 index 0000000..f50c494 --- /dev/null +++ b/dwb/userstyles/wikipedia.org.css @@ -0,0 +1,194 @@ +/* Wikipedia Dark Theme v1.0.4 (12/22/2014) + * https://github.com/StylishThemes/Wikipedia-Dark + * http://userstyles.org/styles/ + * Modified from https://userstyles.org/styles/47161/dark-wikipedia-rounded + */ + + /* transparent background */ + div, span:not(.legend-color), .MainPageBG, .navbox-list, div#mw-head, .mw-wsmfinal-content, #bodyContent, + .referencetooltip > li + li, div.vectorTabs ul li, tr[style*="background:#F5FFFA"], + th[style*="background-color: #fff"] { + background-color: transparent !important; + } + + /*** Overall ***/ + * { + color: #9a9a9a !important; + } + + a, .CategoryTreeToggle { + color: /*[[base-color]]*/ #4183C4 !important; + } + + a:visited { + color: #ccc !important; + } + + a:hover, a:hover span { + color: #fff !important; + text-decoration: underline !important; + } + + /*** Red links (non-existant pages) ***/ + a.new { + color: #980000 !important; + } + + /*** Background ***/ + html, body { + background-color: #222 !important; + background-image: /*[[bg-choice]]*/ url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGQAAABkAgMAAAANjH3HAAAACVBMVEUaGhohISElJSUh9lebAAAB20lEQVRIx4XWuZXDMAwE0C0SAQtggIIYoAAEU+aKOHhYojTrYP2+QfOW/5QIJOih/q8HwF/pb3EX+UPIveYcQGgEHiu9hI+ihEc5Jz5KBIlRRRaJ1JtoSAl5Hw96hLB1/up1tnIXOck5jZQy+3iU2hAOKSH1JvwxHsp+5TLF5MOl1/MQXsVs1miXc+KDbYydyMeUgpPQreZ7fWidbNhkXNJSeAhc6qHmHD8AYovunYyEACWEbyIhNeB9fRrH3hFi0bGPLuEW7xCNaohw1vAlS805nfsrTspclB/hVdoqusg53eH7FWot+wjYpOViX8KbFFKTwlnzvj65P9H/vD0/hibYBGhPwlPO8TmxRsaxsNnrUmUXpNhirlJMPr6Hqq9k5Xn/8iYQHYIuQsWFC6Z87IOxLxHphSY4SpuiU87xJnJr5axfeRd+lnMExXpEWPpuZ1v7qZdNBOjiHzDREHX5fs5Zz9p6X0vVKbKKchlSl5rv+3p//FJ/PYvoKryI8vs+2G9lzRmnEKkh+BU8yDk515jDj/HAswu7CCz6U/Mxb/PnC9N41ndpU4hUU7JGk/C9PmP/M2xZYdvBW2PObyf1IUiIzoHmHW9yTncliYs9A9tVNppdShfgQaTLMf+j3X723tLeHgAAAABJRU5ErkJggg==) !important; + background-clip: border-box !important; + background-origin: padding-box !important; + /*[[bg-options]]*/ + /*[[bg-options2]]*/ + } + + .mw-ui-button, .mw-ui-button * { + background-color: /*[[base-color]]*/ #4183C4 !important; + color: #fff !important; + } + + #mw-page-base, div.vectorTabs, div.vectorTabs * { + background-image: none !important; + } + + #bodyContent pre, #bodyContent code, span.plainlinks * { + background-color: #111 !important; + } + + table, input, button, select, + tr[style*="background: antiquewhite;"], #toc, td[style*="background-color"], td[style*="background:#F5FAFF"], + #mw-content-text div[style*="background: #"], .vevent td, .referencetooltip li, .suggestions, + .mw-ui-button[style*="background"], .mw-ui-button[style*="background"] * { + background-color: #222 !important; + } + + table[style*="background-color:#fff;"], .search-form fieldset, table.ambox, tr[style*="background-color: #fff;"], + .mw-ui-button[style*="background-color:#008B6D"], tr[style*="background-color: #f5faff;"] { + background-color: #282828 !important; + } + + table.wikitable > tr > th, table.wikitable > * > tr > th { + background-color: #333; /* don't include !important flag */ + } + + td[style*="background: #ececec;"], th[style*="background:#eee"], th[style*="background-color: #eee"], + tr[style*="background-color: #f7f7f7;"], th[style*="background:#F2F2F2"], #filetoc, .toccolours, + th[style*="background:#F9F9F9"], table.plainlinks, th[style*="background-color: lightgrey"], + th[style*="background:#ddd"], .infobox th[style*="background"], .infobox td[style*="background"] { + background-color: #333 !important; + } + + hr { + background-color: #555 !important; + } + + /*** Background Color Styles ***/ + /* Red */ + td[style*="background: #FDD;"] { + background: #722 !important; + } + + /* Green */ + #mp-left h2, #mp-left h2 span, td[style*="background: #99FF99;"] { + background: #244024 !important; + } + + /* Blue */ + div[style*="background"] h2, div[style*="background"] h2 *, #mp-right h2, #mp-right h2 span, .navbox th, + .navbox-title, .navbox-title *, tr[style*="background-color:tan;"], + div[style*="background: #444444;"], div[style*="background: #444444;"] *, + ol.references li:target, sup.reference:target, span.citation:target, + ol.references li:target *, sup.reference:target *, span.citation:target *, + td[style*="background:#CEDFF2"], tr[bgcolor="#CEDFF2"], table[style*="background-color:#cef2e0"] * { + background-color: #182030 !important; + } + + .navbox-abovebelow, th.navbox-group, .navbox-subgroup .navbox-title, + .navbox-abovebelow *, th.navbox-group *, .navbox-subgroup .navbox-title * { + background-color: #212C43 !important; + } + + /* Purple */ + #mp-bottom h2, #mp-bottom h2 span { + background-color: #382B4A !important; + } + + /* Brown */ + #mp-center h2, #mp-center h2 span { + background-color: #383812 !important; + } + + /*** Border ***/ + div, span, table, tr:not([style*="border-bottom"]), th, td:not([style*="border-bottom"]), + h1, h2, h3, h4, h5, h6, ul, li, input, select { + border-color: #555 !important; + } + + td[style*="border-bottom"] { + border-right-color: #555 !important; + border-left-color: #555 !important; + border-top-color: #555 !important; + } + + #content, #toc { + -moz-border-radius: 10px !important; + -webkit-border-radius: 10px !important; + border-radius: 10px !important; + } + + div.vectorTabs li:not(.selected) { + border-bottom: #555 1px solid !important; + } + + /* arrow down */ + .referencetooltip > li + li, .referencetooltip > li + li::after { + border-top-color: #555 !important; + border-right-color: transparent !important; + border-left-color: transparent !important; + } + + /* Orange */ + #centralNotice > div { + border-color: #e08b26 !important; + } + + table.ambox-content, table.ambox-style { + border-left-color: #e08b26 !important; + } + + /* add border */ + div.vectorTabs li.selected { + border-bottom: #e08b26 1px solid !important; + } + + /*** Text ***/ + .wikitable th { + color: #fff !important; + } + + .CategoryTreeEmptyBullet { + color: #ccc !important; + } + + /*** Misc ***/ + #p-cactions li.selected a, #p-cactions li a, #p-cactions li a:hover { + padding: 0 1em 0.1em !important; + } + + ul, .portlet li { + list-style-image: none !important; + } + + table[style*="border:4px ridge"] { + border: none !important; + } + + /*** invert images ***/ + img[title="Wikipedia"], .bookshelf-container .bookend, img.mwe-math-fallback-image-inline, + #mw-wsmfinal-close, img[src*="Speaker_Icon"], .infobox img[src*=".svg"], img[src*=".png"]:active { + filter: url("data:image/svg+xml;utf8, #i"); + -webkit-filter: invert(100%) !important; + background-color: transparent !important; + }