91
| <![CDATA[<script>
$(document).ready(function () {
$('#splide-grid .splide-grid--item').magnificPopup({
delegate: 'img',
type: 'image',
gallery: {
enabled: true,
tPrev: 'Anterior (seta para esquerda)',
tNext: "Próxima (seta para direita)",
tCounter: '<span class="mfp-counter">%curr% de %total%</span>'
},
image: {
titleSrc: function (item) {
return item.el.attr('title');
}
},
callbacks: {
elementParse: function (item) { item.src = item.el.attr('src'); return false; }
}
});
$('.newslist').scroll4ever({ //scope element, must NOT be body
trigger:'.container .center-align a#next-page', // link to the next page
container:'.container > div', // element where next page items are going to be added
selector:'.container > div > .news-card', // elements to be added to the page
distance:1000, // distance to the end of window to trigger page load, if avoided, it will not auto trigger
debug: false, // if you want some messages in console...
start: function(){ $('.container a#next-page').html('Carregando...'); }, // callback called when a new page load begins, good for loading messages
complete: function(){}, // callback called when a new page load ends
});
$(window).scroll(function() {
if ($(this).scrollTop() >= 600) {
$('#return-to-top').fadeIn(200);
} else {
$('#return-to-top').fadeOut(200);
}
});
$('#return-to-top').click(function() {
$('body,html').animate({
scrollTop : 0
}, 500);
});
});
</script>]]>
|