PageSourceSearch

https://european-accreditation.org/wp-content/themes/thegem-elemen…/jquery.fancybox-init.js?ver=5.11.0

js european-accreditation.org collected 2026-09-24 08:52:44 UTC 1,889 bytes, 76 lines download raw bytes

1(function($) {
2
3	$.fn.initGalleryFancybox = function() {
4	    $('a.fancy-gallery', this).fancybox({
5	        backFocus: false,
6	        caption : function( instance, item ) {
7	            var slideInfo = $('.slide-info', this);
8	            if ($('> *', slideInfo).length) {
9	                return slideInfo.clone().html();
10	            }
11	        },
12	        onInit: function(instance) {
13	            instance.$refs.caption.addClass('fancybox-title');
14	            instance.$refs.caption.parent().addClass('slideinfo');
15	        }
16	    });
17	};
18
19	$.fn.initPortfolioFancybox = function() {
20		$('[data-fancybox="thegem-portfolio"]', this).fancybox();
21	};
22
23	$.fn.initBlogFancybox = function() {
24		$('a.fancy, .fancy-link-inner a', this).fancybox();
25
26		$('.blog article a.youtube, .blog article a.vimeo', this).fancybox({
27			type: 'iframe'
28		});
29	};
30
31	$.fn.initProductFancybox = function() {
32		let isTouch = window.gemSettings.isTouch;
33
34		$('a.fancy-product-gallery', this).fancybox({
35			arrows: isTouch ? false : true,
36			infobar: true,
37			clickOutside: 'close',
38			buttons: [
39				'zoom',
40				'fullScreen',
41				'thumbs',
42				'close',
43			],
44			touch: {
45				vertical: false,
46				momentum : false
47			},
48			loop : true,
49			animationDuration: 300,
50			backFocus: false,
51			mobile: {
52				fullScreen: false,
53				arrows: false,
54				animationEffect : 'fade',
55				buttons: [
56					'zoom',
57					'fullScreen',
58					'close',
59				],
60				clickContent: function(current, event) {
61					return current.type === "image" ? "zoom" : false;
62				},
63				clickSlide: function(current, event) {
64					return "close";
65				},
66			},
67		});
68	};
69
70	$(document).initGalleryFancybox();
71	$(document).initPortfolioFancybox();
72	$(document).initBlogFancybox();
73	$(document).initProductFancybox();
74
75	$('a.fancy, .fancy-link-inner a').fancybox();
76})(jQuery);

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.