Commits

Kevin Wetzels committed 9fcdac4

Fix idiotic Pictos font for pure text on HBVL.be

Comments (0)

Files changed (2)

 // @include       http://www.hbvl.be/*
 // ==/UserScript==
 document.body.style.fontFamily="'Helvetica Neue', Arial, sans-serif";
+GM_addStyle('#ajaxComments, #ajaxComments ul {font-family:Arial}');

hn.user.js

-// ==UserScript==
-// @name          HN clean-up
-// @namespace     http://roam.be/greasemonkey
-// @description   Make HN a bit more... better
-// @include       http://news.ycombinator.com/*
-// ==/UserScript==
-/*
-function getNewsItem(contentTable, i) {
-    var o = (i * 3) + 1;
-    return {
-        'title': contentTable.querySelector('tr:nth-child(' + o + ')'),
-        'subtext': contentTable.querySelector('tr:nth-child(' + (o + 1) + ')'),
-        'spacer': contentTable.querySelector('tr:nth-child(' + (o + 2) + ')'),
-    };
-};*/
-
-var body = document.body,
-    css = '',
-    style = document.createElement('style'),
-    layoutTable = body.getElementsByTagName('table')[0],
-    headerCell = layoutTable.querySelector('td'),
-    mainRows = layoutTable.getElementsByTagName('tbody')[0].childNodes,
-    headerRow = mainRows[0],
-    bodyWrapper = mainRows[2].querySelector('td'),
-    contentTable = bodyWrapper.querySelectorAll('table')[0],
-    contentBody = contentTable.childNodes[0];
-headerRow.setAttribute('class', 'hn-header-row');
-bodyWrapper.setAttribute('class', 'hn-body-wrapper');
-contentTable.setAttribute('class', 'hn-content-table');
-
-var rows = contentBody.childNodes,
-    i = 0,
-    len = rows.length;
-for (; i < len - 2; i += 3) {
-    if (i == 2) {alert('hi');};
-    rows[i].setAttribute('class', 'hn-news-item-title');
-    rows[i + 1].setAttribute('class', 'hn-news-item-meta');
-    rows[i + 2].setAttribute('class', 'hn-news-item-spacer');
-}
-
-style.type = 'text/css';
-css += 'body {background:#e0e4e8;padding:20px 0}';
-css += 'td.hn-header {padding: 20px;color:#fff} td.hn-header a, td.hn-header a:link, td.hn-header a:visited, td.hn-header .pagetop {color:#fff}';
-css += "table, td, th, input, .default, .comment, .title, body, .comhead, .subtext, .pagetop, .yclinks {font-family:'Helvetica Neue', Arial, sans-serif}";
-css += ".hn-news-item-title td.title:first-child {width:0px;overflow:hidden;text-indent:-9999px}";
-css += ".hn-news-item-title td:nth-child(2) {vertical-align: middle;padding: 10px 5px 0 20px;}";
-css += ".hn-news-item-title td.title:last-child {padding: 10px 5px 0 0;font-size:14px;color:#404448;line-height:14px}";
-style.innerHTML = css;
-layoutTable.setAttribute('bgcolor', '#fff');
-headerCell.setAttribute('bgcolor', '#303438');
-headerCell.setAttribute('class', 'hn-header');
-document.getElementsByTagName('head')[0].appendChild(style);