Some custom board nav fixes.
This commit is contained in:
parent
babc2414a4
commit
8b2eab632b
@ -125,22 +125,22 @@ Header =
|
|||||||
for a in as
|
for a in as
|
||||||
if a.textContent is board
|
if a.textContent is board
|
||||||
a = a.cloneNode true
|
a = a.cloneNode true
|
||||||
if /-title/.test t
|
|
||||||
a.textContent = a.title
|
a.textContent = if /-title/.test(t) or /-replace/.test(t) and $.hasClass a, 'current'
|
||||||
else if /-replace/.test t
|
a.title
|
||||||
if $.hasClass a, 'current'
|
|
||||||
a.textContent = a.title
|
|
||||||
else if /-full/.test t
|
else if /-full/.test t
|
||||||
a.textContent = "/#{board}/ - #{a.title}"
|
"/#{board}/ - #{a.title}"
|
||||||
else if /-(index|catalog|text)/.test t
|
else if m = t.match /-text:"(.+)"/
|
||||||
if m = t.match /-(index|catalog)/
|
m[1]
|
||||||
a.setAttribute 'data-only', m[1]
|
else
|
||||||
a.href = "//boards.4chan.org/#{board}/"
|
a.textContent
|
||||||
a.href += 'catalog' if m[1] is 'catalog'
|
|
||||||
if m = t.match /-text:"(.+)"/
|
if m = t.match /-(index|catalog)/
|
||||||
a.textContent = m[1]
|
a.setAttribute 'data-only', m[1]
|
||||||
else if board is '@'
|
a.href = "//boards.4chan.org/#{board}/"
|
||||||
$.addClass a, 'navSmall'
|
a.href += 'catalog' if m[1] is 'catalog'
|
||||||
|
|
||||||
|
$.addClass a, 'navSmall' if board is '@'
|
||||||
return a
|
return a
|
||||||
$.tn t
|
$.tn t
|
||||||
$.add list, nodes
|
$.add list, nodes
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user