Skip to content

Commit

Permalink
Fix online list highlighting in Firefox
Browse files Browse the repository at this point in the history
This really only worked in Chrome because Chrome was being lenient.
  • Loading branch information
valitas committed Feb 26, 2018
1 parent aa9304d commit a12a6c0
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions chrome/onlinelist.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,14 +57,16 @@ function applyColor () {
table, null, XPathResult.UNORDERED_NODE_ITERATOR_TYPE, null);
while(( a = xpr.iterateNext() )) {
name = a.textContent.toLowerCase();
if( names[name] ) {
a.style.color = '#f69';
if( names[name] )
links.push( a );
}
}

// Add the "people of interest" table if there are any.
if( links.length > 0 ) {
// Highlight the links
for ( i = 0, end = links.length; i < end; i++ )
links[i].style.color = '#f69';

var container = table.parentElement;
var poitable = createNamesTable( links );
container.insertBefore( poitable, table );
Expand Down

0 comments on commit a12a6c0

Please sign in to comment.