1(function($) {"use strict"; 2 3 $(document).ready(function() { 4 5 var templateOptions = Joomla.getOptions('j51_template'); 6 7 // Add parent-hover class to hovered parent items 8 $('.hornav li').hover(function () { 9 $(this).addClass('parent-hover'); 10 }, function () { 11 $(this).removeClass('parent-hover'); 12 }); 13 14 // Smoothscroll 15 $('.menu a').click(function() { 16 if (location.pathname.replace(/^\//,'') == this.pathname.replace(/^\//,'') && location.hostname == this.hostname) { 17 var target = $(this.hash); 18 target = target.length ? target : $('[name=' + this.hash.slice(1) +']'); 19 if (target.length) { 20 $('html,body').animate({ 21 scrollTop: target.offset().top + parseInt(templateOptions.scrolltoOffset) 22 }, 800); 23 return false; 24 } 25 } 26 }); 27 28 // Bootstrap stuff 29 $(document).ready(function() 30 { 31 32 // Turn radios into btn-group 33 $('.radio.btn-group label').addClass('btn'); 34 $(".btn-group label:not(.active)").click(function() 35 { 36 var label = $(this); 37 var input = $('#' + label.attr('for')); 38 39 if (!input.prop('checked')) { 40 label.closest('.btn-group').find("label").removeClass('active btn-success btn-danger btn-primary'); 41 if (input.val() == '') { 42 label.addClass('active btn-primary'); 43 } else if (input.val() == 0) { 44 label.addClass('active btn-danger'); 45 } else { 46 label.addClass('active btn-success'); 47 } 48 input.prop('checked', true); 49 } 50 }); 51 $(".btn-group input[checked=checked]").each(function() 52 { 53 if ($(this).val() == '') { 54 $("label[for=" + $(this).attr('id') + "]").addClass('active btn-primary'); 55 } else if ($(this).val() == 0) { 56 $("label[for=" + $(this).attr('id') + "]").addClass('active btn-danger'); 57 } else { 58 $("label[for=" + $(this).attr('id') + "]").addClass('active btn-success'); 59 } 60 }); 61 }) 62 63 }); 64})(jQuery); 65 66(function() { 67 document.addEventListener('DOMContentLoaded', function() { 68 var executeThis = function() { 69 var continuousElements = document.getElementsByClassName("animate") 70 for (var i = 0; i < continuousElements.length; i++) { 71 new Waypoint({ 72 element: continuousElements[i], 73 handler: function() { 74 this.element.classList.add("animated"); 75 }, 76 offset: "85%" 77 }) 78 } 79 80 }; 81 82 var checkWaypoint = function(){ 83 if (typeof Waypoint === "undefined") { 84 setTimeout(checkWaypoint, 50); 85 } else { 86 executeThis(); 87 } 88 }; 89 checkWaypoint(); 90 91 }); 92})();
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.