diff --git a/4chan_x.js b/4chan_x.js index 898861e06..436b33026 100644 --- a/4chan_x.js +++ b/4chan_x.js @@ -1617,23 +1617,19 @@ }\ '); if (navtopr = $('#navtopr a')) { - text = navtopr.nextSibling; a = n('a', { - textContent: 'X', + textContent: '4chan X', className: 'pointer', listener: ['click', options] }); - inBefore(text, tn(' / ')); - inBefore(text, a); + replace(navtopr, a); navbotr = $('#navbotr a'); - text = navbotr.nextSibling; a = n('a', { - textContent: 'X', + textContent: '4chan X', className: 'pointer', listener: ['click', options] }); - inBefore(text, tn(' / ')); - inBefore(text, a); + replace(navbotr, a); } else if (getConfig('404 Redirect') && d.title === '4chan - 404') { redirect(); } else { diff --git a/script.coffee b/script.coffee index 61883eb6d..beb2f48c5 100644 --- a/script.coffee +++ b/script.coffee @@ -1257,21 +1257,17 @@ GM_addStyle ' ' if navtopr = $ '#navtopr a' - text = navtopr.nextSibling #css doesn't see text nodes a = n 'a', - textContent: 'X' + textContent: '4chan X' className: 'pointer' listener: ['click', options] - inBefore text, tn(' / ') - inBefore text, a + replace navtopr, a navbotr = $ '#navbotr a' - text = navbotr.nextSibling a = n 'a', - textContent: 'X' + textContent: '4chan X' className: 'pointer' listener: ['click', options] - inBefore text, tn(' / ') - inBefore text, a + replace navbotr, a else if getConfig('404 Redirect') and d.title is '4chan - 404' redirect() else