FIX: Allow links to `name` attributes
This commit is contained in:
parent
5667cfe6cb
commit
65297533fa
|
@ -78,6 +78,9 @@ Discourse.URL = Em.Object.createWithMixins({
|
|||
jumpScheduled = true;
|
||||
Em.run.schedule('afterRender', function() {
|
||||
var $elem = $(id);
|
||||
if ($elem.length === 0) {
|
||||
$elem = $("[name=" + id.replace('#', ''));
|
||||
}
|
||||
if ($elem.length > 0) {
|
||||
$('html,body').scrollTop($elem.offset().top - $('header').height() - 15);
|
||||
jumpScheduled = false;
|
||||
|
|
Loading…
Reference in New Issue