2016-03-10 03:23:27 +01:00
|
|
|
/* ==========================================================================
|
|
|
|
jQuery plugin settings and other scripts
|
|
|
|
========================================================================== */
|
2014-02-13 20:20:28 +01:00
|
|
|
|
2016-03-10 03:23:27 +01:00
|
|
|
/* fitvids.js */
|
2014-02-13 20:20:28 +01:00
|
|
|
|
2013-09-09 16:12:07 +02:00
|
|
|
$(function() {
|
|
|
|
$("article").fitVids();
|
|
|
|
});
|
|
|
|
|
|
|
|
|
2016-03-10 03:23:27 +01:00
|
|
|
/* add lightbox class to all image links */
|
|
|
|
|
2014-03-14 13:37:12 +01:00
|
|
|
$("a[href$='.jpg'],a[href$='.jpeg'],a[href$='.JPG'],a[href$='.png'],a[href$='.gif']").addClass("image-popup");
|
2013-09-09 16:12:07 +02:00
|
|
|
|
2016-03-10 03:23:27 +01:00
|
|
|
|
|
|
|
/* Magnific-Popup options */
|
|
|
|
|
2013-09-09 16:12:07 +02:00
|
|
|
$(document).ready(function() {
|
2016-03-10 03:23:27 +01:00
|
|
|
$(".image-popup").magnificPopup({
|
|
|
|
type: "image",
|
|
|
|
tLoading: "Loading image #%curr%...",
|
2013-09-09 16:12:07 +02:00
|
|
|
gallery: {
|
|
|
|
enabled: true,
|
|
|
|
navigateByImgClick: true,
|
2016-03-10 03:23:27 +01:00
|
|
|
preload: [0,1] // will preload 0 - before current, and 1 after the current image
|
2013-09-09 16:12:07 +02:00
|
|
|
},
|
|
|
|
image: {
|
2016-03-10 03:23:27 +01:00
|
|
|
tError: "<a href='%url%'>Image #%curr%</a> could not be loaded.",
|
2013-09-09 16:12:07 +02:00
|
|
|
},
|
2016-03-10 03:23:27 +01:00
|
|
|
removalDelay: 300, // delay in milliseconds before popup is removed
|
|
|
|
mainClass: "mfp-fade"
|
2013-09-09 16:12:07 +02:00
|
|
|
});
|
2016-03-10 03:23:27 +01:00
|
|
|
});
|