Add nodes.quote to Post object.
This commit is contained in:
parent
f388daee47
commit
512fd1f78d
@ -15,6 +15,7 @@ class Clone extends Post
|
|||||||
root: root
|
root: root
|
||||||
post: post
|
post: post
|
||||||
info: info
|
info: info
|
||||||
|
quote: $ 'a[title="Reply to this post"]', info
|
||||||
comment: $ '.postMessage', post
|
comment: $ '.postMessage', post
|
||||||
quotelinks: []
|
quotelinks: []
|
||||||
backlinks: info.getElementsByClassName 'backlink'
|
backlinks: info.getElementsByClassName 'backlink'
|
||||||
|
|||||||
@ -37,6 +37,7 @@ class Post
|
|||||||
post: post
|
post: post
|
||||||
info: info
|
info: info
|
||||||
nameBlock: $ '.nameBlock', info
|
nameBlock: $ '.nameBlock', info
|
||||||
|
quote: $ 'a[title="Reply to this post"]', info
|
||||||
comment: $ '.postMessage', post
|
comment: $ '.postMessage', post
|
||||||
links: []
|
links: []
|
||||||
quotelinks: []
|
quotelinks: []
|
||||||
|
|||||||
@ -21,10 +21,10 @@ class Thread
|
|||||||
g.threads.push @fullID, board.threads.push @, @
|
g.threads.push @fullID, board.threads.push @, @
|
||||||
|
|
||||||
setPage: (pageNum) ->
|
setPage: (pageNum) ->
|
||||||
{info} = @OP.nodes
|
{info, quote} = @OP.nodes
|
||||||
unless icon = $ '.page-num', info
|
unless icon = $ '.page-num', info
|
||||||
icon = $.el 'span', className: 'page-num'
|
icon = $.el 'span', className: 'page-num'
|
||||||
$.after $('a[title="Reply to this post"]', info), [$.tn(' '), icon]
|
$.after quote, [$.tn(' '), icon]
|
||||||
icon.title = "This thread is on page #{pageNum} in the original index."
|
icon.title = "This thread is on page #{pageNum} in the original index."
|
||||||
icon.textContent = "[#{pageNum}]"
|
icon.textContent = "[#{pageNum}]"
|
||||||
@catalogView.nodes.pageCount.textContent = pageNum if @catalogView
|
@catalogView.nodes.pageCount.textContent = pageNum if @catalogView
|
||||||
@ -60,7 +60,7 @@ class Thread
|
|||||||
root = if type isnt 'Sticky' and @isSticky
|
root = if type isnt 'Sticky' and @isSticky
|
||||||
$ '.stickyIcon', @OP.nodes.info
|
$ '.stickyIcon', @OP.nodes.info
|
||||||
else
|
else
|
||||||
$('.page-num', @OP.nodes.info) or $('[title="Reply to this post"]', @OP.nodes.info)
|
$('.page-num', @OP.nodes.info) or @OP.nodes.quote
|
||||||
$.after root, [$.tn(' '), icon]
|
$.after root, [$.tn(' '), icon]
|
||||||
|
|
||||||
return unless @catalogView
|
return unless @catalogView
|
||||||
|
|||||||
@ -93,7 +93,7 @@ QR =
|
|||||||
QR.status()
|
QR.status()
|
||||||
|
|
||||||
node: ->
|
node: ->
|
||||||
$.on $('a[title="Reply to this post"]', @nodes.info), 'click', QR.quote
|
$.on @nodes.quote, 'click', QR.quote
|
||||||
|
|
||||||
open: ->
|
open: ->
|
||||||
if QR.nodes
|
if QR.nodes
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user