Skip to content

Instantly share code, notes, and snippets.

@hfhchan
Last active March 29, 2018 16:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hfhchan/a4834043cea950d404234835a60b43e6 to your computer and use it in GitHub Desktop.
Save hfhchan/a4834043cea950d404234835a60b43e6 to your computer and use it in GitHub Desktop.
Glyphwiki Modern Style
// ==UserScript==
// @name GlyphWiki Style
// @namespace https://github.com/hfhchan/
// @include http://en.glyphwiki.org/*
// @include http://glyphwiki.org/*
// @version 1
// @grant none
// ==/UserScript==
var style = document.createElement("style");
document.head.appendChild(style);
style.sheet.insertRule('div.right_pane ul{padding-left:32px}', 0);
style.sheet.insertRule('table{border-collapse:collapse;border-color:#999}', 0);
style.sheet.insertRule('td{border-color:#999;padding:2px 4px}', 0);
style.sheet.insertRule('body{color:#333;margin:8px}', 0);
style.sheet.insertRule('.right_body{padding:16px 20px 20px;margin-right:0}', 0);
style.sheet.insertRule('div.right_pane h2{border-color:#ccc}', 0);
style.sheet.insertRule('div.right_pane .texts{margin:1em 0}', 0);
style.sheet.insertRule('p{margin:16px 0}', 0);
style.sheet.insertRule('hr{border-color:#ccc;margin:16px 0}', 0);
style.sheet.insertRule('textarea,input{border:1px solid #999;border-radius:0;box-shadow:none;outline:none}', 0);
style.sheet.insertRule('textarea:hover,input:hover{border-color:#999}', 0);
style.sheet.insertRule('textarea:focus,input:focus,textarea:hover:focus,input:hover:focus{border-color:#09c;box-shadow:0 0 1px #09c}', 0);
style.sheet.insertRule('textarea,input[type="text"]{padding:2px 4px;background:inherit}', 0);
style.sheet.insertRule('input[type="submit"]{background:#eee;padding:2px 8px;border-radius:1px}', 0);
style.sheet.insertRule('input[type="submit"]:hover{background:#ddd}', 0);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment