replace once
This commit is contained in:
parent
baac2a1bcd
commit
226665a16f
@ -2117,6 +2117,9 @@
|
||||
};
|
||||
quoteBacklink = {
|
||||
init: function() {
|
||||
var format;
|
||||
format = conf['backlink'].replace(/%id/, "' + id + '");
|
||||
quoteBacklink.funk = Function('id', "return'" + format + "'");
|
||||
return g.callbacks.push(function(root) {
|
||||
var container, el, id, link, qid, quote, quotes, _i, _len, _ref, _results;
|
||||
if (/inline/.test(root.className)) {
|
||||
@ -2143,7 +2146,7 @@
|
||||
link = $.el('a', {
|
||||
href: "#" + id,
|
||||
className: 'backlink',
|
||||
textContent: conf['backlink'].replace(/%id/, id)
|
||||
textContent: quoteBacklink.funk(id)
|
||||
});
|
||||
if (conf['Quote Preview']) {
|
||||
$.bind(link, 'mouseover', quotePreview.mouseover);
|
||||
|
||||
@ -2,6 +2,7 @@ master
|
||||
- mayhem
|
||||
fix updater refreshing 404'd threads
|
||||
distinguishable unread favicons on white backgrounds
|
||||
backlink formatting
|
||||
|
||||
2.18.3
|
||||
- mayhem
|
||||
|
||||
@ -1678,6 +1678,8 @@ titlePost =
|
||||
|
||||
quoteBacklink =
|
||||
init: ->
|
||||
format = conf['backlink'].replace /%id/, "' + id + '"
|
||||
quoteBacklink.funk = Function 'id', "return'#{format}'"
|
||||
g.callbacks.push (root) ->
|
||||
return if /inline/.test root.className
|
||||
# op or reply
|
||||
@ -1695,7 +1697,7 @@ quoteBacklink =
|
||||
link = $.el 'a',
|
||||
href: "##{id}"
|
||||
className: 'backlink'
|
||||
textContent: conf['backlink'].replace /%id/, id
|
||||
textContent: quoteBacklink.funk id
|
||||
if conf['Quote Preview']
|
||||
$.bind link, 'mouseover', quotePreview.mouseover
|
||||
$.bind link, 'mousemove', ui.hover
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user