FacetWP – Meow Lightbox support (maybe?)

mgibbs189

{{gist file=”test.js” lang=”javascript”}}
(function($) {
$(document).on(‘facetwp-loaded’, function() {
var orientation_responsive = {}
if(mwl.settings.orientation == “auto”) {
orientation_responsive.enabled = true;
orientation_responsive.orientation = ‘landscape’;
} else {
orientation_responsive.enabled = false;
orientation_responsive.orientation = mwl.settings.orientation;
}
var settings = {
layout: mwl.settings.layout,
expanded_image: false,
selector: mwl.settings.selector,
anti_selector: mwl.settings.anti_selector,
theme: mwl.settings.theme,
allow_expand: true, // TO LINK WITH PHP OPTION
allow_fullscreen: false, // TO LINK WITH PHP OPTION, /!STILL IN BETA/!
slideshow: { // Still in dev
enable: false,
slide_duration: 3000
},
preloading: mwl.settings.preloading,
orientation_responsive: orientation_responsive,
map: mwl.settings.map,
caption_source: mwl.settings.caption_source,
low_res_placeholder: mwl.settings.low_res_placeholder,
deep_linking: mwl.settings.deep_linking,
infos_to_display: {
title: mwl.settings.exif.title,
caption: mwl.settings.exif.caption,
camera: mwl.settings.exif.camera,
lens: mwl.settings.exif.lens,
shutter_speed: mwl.settings.exif.shutter_speed,
aperture: mwl.settings.exif.aperture,
focal_length: mwl.settings.exif.focal_length,
iso: mwl.settings.exif.iso
},
download: {
enable: mwl.settings.download_link
},
right_click_protection: mwl.settings.right_click_protection
};
var mwlController = new MwlController(settings);
mwlController.init();
});
})(jQuery);
{{/gist}}