fix github rendering in old firefox releases with greasemonkey

11 Feb 2015

When the new firefox interface (aurora) was announced I knew I would never install it, since then I’ve been looking for alternatives, in the meantime I’ve been using an old firefox release (27.0), it’s been great so far, however some days ago started looking funny. Paniiiic 😱!

I contacted support but they told me they didn’t support such old releases (and think it’s barely 1 year old, pff, progress…) so I went ahead and hacked a quick greasemonkey script.

function addGlobalStyle(css) {
    var head, style;
    head = document.getElementsByTagName('head')[0];
    if (!head) { return; }
    style = document.createElement('style');
    style.type = 'text/css';
    style.innerHTML = css;

addGlobalStyle('.one-fourth {width: 20%}');
addGlobalStyle('.one-half {width: 47%}');
addGlobalStyle('img.avatar {max-width: 200px; max-height: 200px;}');

addGlobalStyle('.two-thirds {width: 63%}');
addGlobalStyle('.site-search input[type="text"] {width: 90%}');

That’s it, happy collaborating 😋