more indexing changes
This commit is contained in:
parent
102e5de01e
commit
1182047357
@ -182,7 +182,7 @@ Build =
|
||||
''
|
||||
|
||||
if isOP and g.VIEW is 'index' and Conf['JSON Navigation']
|
||||
pageNum = Math.floor Index.liveThreadIDs.indexOf(postID) / Index.threadsNumPerPage
|
||||
pageNum = Math.floor Index.liveThreadIDs.indexOf(postID) / Index.threadsNumPerPage + 1
|
||||
pageIcon = " <span class=page-num title='This thread is on page #{pageNum} in the original index.'>[#{pageNum}]</span>"
|
||||
else
|
||||
pageIcon = ''
|
||||
|
||||
@ -671,11 +671,11 @@ vp-replace
|
||||
]
|
||||
# Board Navigation
|
||||
'Front page': [
|
||||
'0'
|
||||
'1'
|
||||
'Jump to front page.'
|
||||
]
|
||||
'Open front page': [
|
||||
'Shift+0'
|
||||
'Shift+1'
|
||||
'Open front page in a new tab.'
|
||||
]
|
||||
'Next page': [
|
||||
|
||||
@ -198,7 +198,7 @@ Navigate =
|
||||
if threadID
|
||||
view = 'thread'
|
||||
else
|
||||
pageNum = +view
|
||||
pageNum = +view or 1 # string to number, '' to 1
|
||||
view = 'index' # path is "/boardID/". See the problem?
|
||||
|
||||
if view is g.VIEW and boardID is g.BOARD.ID
|
||||
|
||||
@ -87,7 +87,7 @@ Keybinds =
|
||||
# Board Navigation
|
||||
when Conf['Front page']
|
||||
if Conf['JSON Navigation'] and g.VIEW is 'index'
|
||||
Index.userPageNav 0
|
||||
Index.userPageNav 1
|
||||
else
|
||||
window.location = "/#{g.BOARD}/"
|
||||
when Conf['Open front page']
|
||||
|
||||
@ -80,5 +80,5 @@ ThreadStats =
|
||||
for page in @response
|
||||
for thread in page.threads when thread.no is ThreadStats.thread.ID
|
||||
ThreadStats.pageCountEl.textContent = page.page
|
||||
(if page.page is @response.length - 1 then $.addClass else $.rmClass) ThreadStats.pageCountEl, 'warning'
|
||||
return
|
||||
(if page.page is @response.length then $.addClass else $.rmClass) ThreadStats.pageCountEl, 'warning'
|
||||
return
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user