1$(document).ready(function(){ 2 var list = $('.single-view-comment-list li'), 3 limit = Number($('#show-more').attr('data-limit')), 4 button = $('#show-more'), 5 listLength = list.length; 6 let currentUrl = document.URL.split('#'), 7 url = currentUrl[1], 8 detailsSelector = $("details"), 9 elementFocus = document.getElementsByClassName('errormessage'), 10 successFocus = document.getElementsByClassName('comment-success'); 11 12 if(elementFocus.length > 0) 13 { 14 $('html,body').animate( 15 { 16 scrollTop: detailsSelector.offset().top 17 }, 18 'slow' 19 ); 20 $('#single-view-1-comment-button').trigger("click"); 21 } 22 23 if(successFocus.length > 0) 24 { 25 $('html,body').animate( 26 { 27 scrollTop: $(".comment-success").offset().top - 150 28 }, 29 'slow' 30 ); 31 } 32 33 $('#single-view-1-comment-button').on('click', function() { 34 if (!(detailsSelector.attr('open'))) 35 { 36 detailsSelector.attr('open'); 37 $('html,body').animate( 38 { 39 scrollTop: $(".news-comment-filter").offset().top - 50 40 }, 41 'slow' 42 ); 43 } 44 }); 45 list.hide(); 46 if (!url || url === 'single-view-1-comment-section') 47 { 48 list.slice(0, limit).show(); 49 if(listLength > limit) 50 { 51 button.show(); 52 } 53 else 54 { 55 button.remove(); 56 } 57 } 58 else 59 { 60 var bookmark = $('.single-comment').index($('#'+url)); 61 list.slice(0, bookmark + 1).show(); 62 if( list.filter(':visible').length >= listLength) 63 { 64 button.remove(); 65 } 66 } 67 68 69 button.on('click', function() 70 { 71 var visible = list.filter(':visible').length; 72 73 list.slice(visible - 1 , visible + limit).fadeIn(); 74 if( list.filter(':visible').length >= listLength) 75 { 76 button.remove(); 77 } 78 }); 79}); 80 81function copyToClipboard(element) { 82 var $temp = $("<input>"), 83 $link = document.URL.split('#'), 84 $copyLink = $link[0] + '#' + element; 85 let elementId = 'li#' + element; 86 $("body").append($temp); 87 $temp.val($copyLink).select(); 88 document.execCommand("copy"); 89 $(elementId).find('.confirmed-copy-link').removeClass('hidden'); 90 $(elementId).find(".confirmed-copy-link").fadeOut(2800, function() { 91 $(this).addClass('hidden').removeAttr('style'); 92 93 }); 94 $temp.remove(); 95}
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.