skynet/userscripts/style-hckrnews.js

73 lines
1.1 KiB
JavaScript

// ==UserScript==
// @name Style-Hckrnews
// @namespace code.sitosis.com
// @version 1.0
// @description Style Hckrnews
// @author rudism
// @match https://hckrnews.com/*
// @grant none
// @run-at document-end
// ==/UserScript==
function injectStyle(css) {
var style = document.createElement('style');
style.innerHTML = css;
var body = document.getElementsByTagName('body');
if(body.length > 0) {
body[0].appendChild(style);
}
}
(function () {
'use strict';
injectStyle(`
body,
.form-actions {
background: #1e1e2e;
color: #cdd6f4;
}
a {
color: #a6e3a1;
}
.entries a.link {
color: #cdd6f4;
}
.entries a.link:visited,
.entries .source {
color: #a6adc8;
}
.entries .homepage {
color: #f38ba8;
}
header a,
header a:hover {
color: #89b4fa;
}
.entries a:hover {
background-color: #080808;
color: #a6e3a1;
}
.entries .tab,
.menu .nav-pills > .active > a,
.menu .nav-pills > .active > a:hover {
background-color: #cba6f7;
color: #11111b;
}
.nav > li > a:hover {
background-color: #11111b;
color: #f9e2af;
}
.entries .day {
border-color: #89b4fa;
}`);
})();