Better QuoteInline process
This commit is contained in:
parent
3f849a95d8
commit
971b7d971e
2
LICENSE
2
LICENSE
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* 4chan X - Version 1.3.1 - 2014-01-12
|
* 4chan X - Version 1.3.1 - 2014-01-13
|
||||||
*
|
*
|
||||||
* Licensed under the MIT license.
|
* Licensed under the MIT license.
|
||||||
* https://github.com/seaweedchan/4chan-x/blob/master/LICENSE
|
* https://github.com/seaweedchan/4chan-x/blob/master/LICENSE
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -90,6 +90,7 @@ div.navLinks {
|
|||||||
.reply > .file > .fileText {
|
.reply > .file > .fileText {
|
||||||
margin: 0 20px;
|
margin: 0 20px;
|
||||||
}
|
}
|
||||||
|
.inlined + .hashlink,
|
||||||
[hidden] {
|
[hidden] {
|
||||||
display: none !important;
|
display: none !important;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -2,18 +2,15 @@ QuoteInline =
|
|||||||
init: ->
|
init: ->
|
||||||
return if g.VIEW is 'catalog' or !Conf['Quote Inlining']
|
return if g.VIEW is 'catalog' or !Conf['Quote Inlining']
|
||||||
|
|
||||||
if Conf['Quote Hash Navigation']
|
@process = if Conf['Quote Hash Navigation']
|
||||||
@node = ->
|
(link, clone) ->
|
||||||
for link in @nodes.quotelinks.concat [@nodes.backlinks...]
|
$.after link, QuoteInline.qiQuote link, $.hasClass link, 'filtered' unless clone
|
||||||
$.after link, QuoteInline.qiQuote link, $.hasClass link, 'filtered' unless @isClone
|
$.on link, 'click', QuoteInline.toggle
|
||||||
$.on link, 'click', QuoteInline.toggle
|
|
||||||
return
|
|
||||||
|
|
||||||
else
|
else
|
||||||
@node = ->
|
(link) ->
|
||||||
for link in @nodes.quotelinks.concat [@nodes.backlinks...]
|
$.on link, 'click', QuoteInline.toggle
|
||||||
$.on link, 'click', QuoteInline.toggle
|
|
||||||
return
|
|
||||||
|
|
||||||
if Conf['Comment Expansion']
|
if Conf['Comment Expansion']
|
||||||
ExpandComment.callbacks.push @node
|
ExpandComment.callbacks.push @node
|
||||||
@ -22,6 +19,13 @@ QuoteInline =
|
|||||||
name: 'Quote Inlining'
|
name: 'Quote Inlining'
|
||||||
cb: @node
|
cb: @node
|
||||||
|
|
||||||
|
node: ->
|
||||||
|
{process} = QuoteInline
|
||||||
|
{isClone} = @
|
||||||
|
process link, isClone for link in @nodes.quotelinks
|
||||||
|
process link, isClone for link in @nodes.backlinks
|
||||||
|
return
|
||||||
|
|
||||||
qiQuote: (link, hidden) ->
|
qiQuote: (link, hidden) ->
|
||||||
[
|
[
|
||||||
$.tn(' ')
|
$.tn(' ')
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user