https://www.legacynewspaper.com/wp-content/themes/pepe-lite/js/pepe-lite-custom-script.js?ver=v1.0.0
1/** 2 * pepe-lite-custom-script.js 3 * author Franchi Design 4 * package pepe-lite 5 * version 1.0.0 6*/ 7 8 9/* TABLE OF CONTENT 10 11- Button pepe 12- Form Search Responsive 13- News banner 14- Back To Top 15- Open Menu Responsivo 16- Open Form login in Menu Responsivo 17- Add Class Hover Color News 18- Sticky Sidebar Block Zero 19- Sticky Sidebar Post 20 21*/ 22 23( function( $ ) { 24 25 26/* ------------------------------------------------------------------------- * 27## Button pepe */ 28/* ------------------------------------------------------------------------- */ 29 30$(function() { 31 $('.pep-6') 32 .on('mouseenter', function(e) { 33 var parentOffset = $(this).offset(), 34 relX = e.pageX - parentOffset.left, 35 relY = e.pageY - parentOffset.top; 36 $(this).find('span').css({top:relY, left:relX}) 37 }) 38 .on('mouseout', function(e) { 39 var parentOffset = $(this).offset(), 40 relX = e.pageX - parentOffset.left, 41 relY = e.pageY - parentOffset.top; 42 $(this).find('span').css({top:relY, left:relX}) 43 }); 44}); 45 46 47/* ------------------------------------------------------------------------- * 48## Form Search Responsive */ 49/* ------------------------------------------------------------------------- */ 50 51$(function () { 52 $('a[href="#search_responseve"]').on('click', function(event) { 53 event.preventDefault(); 54 $('#search_responseve,body').addClass('open pe-padding-body'); 55 $('#search_responseve > form > input[type="search"]').focus(); 56 }); 57 58 $('#search_responseve, #search_responseve button.close,body').on('click keyup', function(event) { 59 if (event.target == this || event.target.className == 'close' || event.keyCode == 27) { 60 $(this).removeClass('open pe-padding-body'); 61 } 62 }); 63 64}); 65 66/* ------------------------------------------------------------------------- * 67## Effect show image Site */ 68/* ------------------------------------------------------------------------- */ 69 70function imgFadeIn(el) { 71 72 var wh = $(window).height(); 73 74 $(el).each(function(){ 75 76 var thisPos = $(this).offset().top; 77 78 var topOfWindow = $(window).scrollTop(); 79 80 if (topOfWindow + wh - 200 > thisPos ) { 81 82 $(this).addClass('fadein'); 83 84 } 85 }); 86} 87 88$(window).on('scroll resize', function() { 89 90 imgFadeIn('.fadeimg'); 91}); 92 93/* ------------------------------------------------------------------------- * 94## News Banner */ 95/* ------------------------------------------------------------------------- */ 96 97$(function (){ 98 $('.simple-marquee-container').SimpleMarquee({ autostart: true});}); 99 100} )( jQuery ); 101 102/* ------------------------------------------------------------------------- * 103## Back To Top Right */ 104/* ------------------------------------------------------------------------- */ 105 106//Check to see if the window is top if not then display button 107var pepe_lite_back_to_top_button_right = jQuery('.btn-back-to-top-right'); 108 109jQuery(window).scroll(function(){ 110 if (jQuery(this).scrollTop() > 100 && !pepe_lite_back_to_top_button_right.hasClass('scrolled')) { 111 pepe_lite_back_to_top_button_right.addClass('scrolled'); 112 113 } else if (jQuery(this).scrollTop() < 100 && pepe_lite_back_to_top_button_right.hasClass('scrolled')) { 114 pepe_lite_back_to_top_button_right.removeClass('scrolled'); 115 116 } 117}); 118 119//click to scroll to top 120pepe_lite_back_to_top_button_right.click(function(){ 121 jQuery('html, body').animate({scrollTop : 0},800); 122 return false; 123}); 124 125/* ------------------------------------------------------------------------- * 126## Back To Top Left */ 127/* ------------------------------------------------------------------------- */ 128 129//Check to see if the window is top if not then display button 130var back_to_top_button = jQuery('.btn-back-to-top-left'); 131 132jQuery(window).scroll(function(){ 133 if (jQuery(this).scrollTop() > 100 && !back_to_top_button.hasClass('scrolled')) { 134 back_to_top_button.addClass('scrolled'); 135 136 } else if (jQuery(this).scrollTop() < 100 && back_to_top_button.hasClass('scrolled')) { 137 back_to_top_button.removeClass('scrolled'); 138 139 } 140}); 141 142//click to scroll to top 143back_to_top_button.click(function(){ 144 jQuery('html, body').animate({scrollTop : 0},800); 145 return false;
146}); 147 148/* ------------------------------------------------------------------------- * 149## Open Menu Responsivo */ 150/* ------------------------------------------------------------------------- */ 151 152/* Open */ 153function openNav() { 154 document.getElementById("pepeNavresponsive").style.width = "100%"; 155 document.body.classList.add('pe-padding-body'); 156} 157 158/* Close */ 159function closeNav() { 160 document.getElementById("pepeNavresponsive").style.width = "0%"; 161 document.body.classList.remove('pe-padding-body'); 162} 163 164/* ------------------------------------------------------------------------- * 165## Open Form login in Menu Responsivo */ 166/* ------------------------------------------------------------------------- */ 167 168/* Open */ 169function openLog() { 170 document.getElementById("pe-form-login-responsive").style.height = "100%"; 171 document.getElementById("pe-form-login-responsive").classList.add('pepe-show-form-login'); 172} 173 174/* Close */ 175function closeLog() { 176 document.getElementById("pe-form-login-responsive").style.height = "0%"; 177 document.getElementById("pe-form-login-responsive").classList.remove('pepe-show-form-login'); 178} 179 180/* ------------------------------------------------------------------------- * 181## Add Class Hover Color News */ 182/* ------------------------------------------------------------------------- */ 183 184jQuery(document).ready(function() { 185 jQuery('ul.marquee-content-items').hover(function(){ 186 jQuery('.marquee-sibling').addClass('pepe-color-news-hover'); 187 },function(){ 188 jQuery('.marquee-sibling').removeClass('pepe-color-news-hover'); 189 }); 190}); 191 192 193/* ------------------------------------------------------------------------- * 194## Sticky Sidebar Block Zero */ 195/* ------------------------------------------------------------------------- */ 196 197jQuery(document).ready(function() { 198 jQuery('.sticky-pepe-zero,.pepe-sid-zero').theiaStickySidebar({ 199 // Settings 200 additionalMarginTop: 30 201 }); 202}); 203 204/* Block One */ 205jQuery(document).ready(function() { 206 jQuery('.pepe-sid-one,.sticky-pepe-one,.pepe-sid-two').theiaStickySidebar({ 207 // Settings 208 additionalMarginTop: 30 209 }); 210}); 211 212 213/* ------------------------------------------------------------------------- * 214## Sticky Sidebar Post */ 215/* ------------------------------------------------------------------------- */ 216 217// Post 218jQuery(document).ready(function() { 219 jQuery('.content-area-single-st,.pepe-sidebar-article').theiaStickySidebar({ 220 // Settings 221 additionalMarginTop: 30 222 }); 223}); 224
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.