Socket
Socket
Sign inDemoInstall

blueimp-gallery

Package Overview
Dependencies
0
Maintainers
1
Versions
91
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 2.44.0 to 3.0.0

img/loading.svg

4

js/blueimp-gallery-fullscreen.js

@@ -30,3 +30,3 @@ /*

// Defines if the gallery should open in fullscreen mode:
fullScreen: false
fullscreen: false
})

@@ -73,3 +73,3 @@

initialize.call(this)
if (this.options.fullScreen && !this.getFullScreenElement()) {
if (this.options.fullscreen && !this.getFullScreenElement()) {
this.requestFullScreen(this.container[0])

@@ -76,0 +76,0 @@ }

@@ -71,2 +71,3 @@ /*

}
indicator.setAttribute('role', 'link')
return indicator

@@ -134,5 +135,5 @@ },

handleSlide: function (index) {
handleSlide.call(this, index)
this.setActiveIndicator(index)
handleSlide: function (oldIndex, newIndex) {
handleSlide.call(this, oldIndex, newIndex)
this.setActiveIndicator(newIndex)
},

@@ -139,0 +140,0 @@

@@ -35,6 +35,14 @@ /*

videoPlayingClass: 'video-playing',
// The class for video content displayed in an iframe:
videoIframeClass: 'video-iframe',
// The class for the video cover element:
videoCoverClass: 'video-cover',
// The class for the video play control:
videoPlayClass: 'video-play',
// Play videos inline by default:
videoPlaysInline: true,
// The list object property (or data attribute) for video preload:
videoPreloadProperty: 'preload',
// The list object property (or data attribute) for the video poster URL:
videoPosterProperty: 'poster',
// The list object property (or data attribute) for the video sources array:
videoSourcesProperty: 'sources'
videoPosterProperty: 'poster'
})

@@ -45,7 +53,9 @@

$.extend(galleryPrototype, {
handleSlide: function (index) {
handleSlide.call(this, index)
if (this.playingVideo) {
this.playingVideo.pause()
}
handleSlide: function (oldIndex, newIndex) {
handleSlide.call(this, oldIndex, newIndex)
this.setTimeout(function () {
if (this.activeVideo) {
this.activeVideo.pause()
}
})
},

@@ -65,50 +75,50 @@

var video = videoInterface || document.createElement('video')
var coverElement = this.elementPrototype.cloneNode(false)
var playElement = document.createElement('a')
var url = this.getItemProperty(obj, options.urlProperty)
var type = this.getItemProperty(obj, options.typeProperty)
var sources = this.getItemProperty(obj, options.sourcesProperty)
var title = this.getItemProperty(obj, options.titleProperty)
var altText =
this.getItemProperty(obj, this.options.altTextProperty) || title
var posterUrl = this.getItemProperty(obj, options.videoPosterProperty)
var posterImage
var sources = this.getItemProperty(obj, options.videoSourcesProperty)
var source
var playMediaControl
var playControls = [playElement]
var hasGalleryControls
var isLoading
var hasControls
var i
videoContainer.addClass(options.videoContentClass)
$(playElement).addClass(options.videoPlayClass)
if (
!$(coverElement)
.addClass(options.videoCoverClass)
.hasClass(options.toggleClass)
) {
playControls.push(coverElement)
}
coverElement.draggable = false
if (title) {
videoContainerNode.title = title
playElement.setAttribute('aria-label', title)
}
if (video.canPlayType) {
if (url && type && video.canPlayType(type)) {
video.src = url
} else if (sources) {
while (sources.length) {
source = sources.shift()
url = this.getItemProperty(source, options.urlProperty)
type = this.getItemProperty(source, options.typeProperty)
if (url && type && video.canPlayType(type)) {
video.src = url
break
}
}
}
}
if (posterUrl) {
video.poster = posterUrl
posterImage = this.imagePrototype.cloneNode(false)
$(posterImage).addClass(options.toggleClass)
posterImage.src = posterUrl
posterImage.draggable = false
posterImage.alt = altText
videoContainerNode.appendChild(posterImage)
// Set as background image instead of as poster video element property:
// - Is accessible for browsers that do not support the video element
// - Is accessible for both video element and iframe video players
// - Avoids visual artifacts in IE with the poster property set
coverElement.style.backgroundImage = 'url("' + posterUrl + '")'
}
playMediaControl = document.createElement('a')
playMediaControl.setAttribute('target', '_blank')
if (!videoInterface) {
playMediaControl.setAttribute('download', title)
if (video.setAttribute) {
if (options.videoPlaysInline) video.setAttribute('playsinline', '')
} else {
videoContainer.addClass(options.videoIframeClass)
}
playMediaControl.href = url
if (video.src) {
video.controls = true
video.preload =
this.getItemProperty(obj, options.videoPreloadProperty) || 'none'
if (this.support.source && sources) {
for (i = 0; i < sources.length; i += 1) {
video.appendChild(
$.extend(this.sourcePrototype.cloneNode(false), sources[i])
)
}
}
if (url) video.src = url
playElement.href = url || (sources && sources.length && sources[0].src)
if (video.play && video.pause) {
;(videoInterface || $(video))

@@ -124,7 +134,9 @@ .on('error', function () {

.removeClass(that.options.videoPlayingClass)
if (hasControls) {
if (hasGalleryControls) {
that.container.addClass(that.options.controlsClass)
}
delete that.playingVideo
video.controls = false
if (video === that.activeVideo) delete that.activeVideo
if (that.interval) {
// Continue slideshow interval
that.play()

@@ -135,20 +147,24 @@ }

isLoading = false
coverElement.removeAttribute('style')
videoContainer
.removeClass(that.options.videoLoadingClass)
.addClass(that.options.videoPlayingClass)
if (that.container.hasClass(that.options.controlsClass)) {
hasControls = true
that.container.removeClass(that.options.controlsClass)
} else {
hasControls = false
}
})
.on('play', function () {
// Clear slideshow timeout:
window.clearTimeout(that.timeout)
isLoading = true
videoContainer.addClass(that.options.videoLoadingClass)
that.playingVideo = video
if (that.container.hasClass(that.options.controlsClass)) {
hasGalleryControls = true
that.container.removeClass(that.options.controlsClass)
} else {
hasGalleryControls = false
}
video.controls = true
that.activeVideo = video
})
$(playMediaControl).on('click', function (event) {
$(playControls).on('click', function (event) {
that.preventDefault(event)
that.activeVideo = video
if (isLoading) {

@@ -164,3 +180,4 @@ video.pause()

}
videoContainerNode.appendChild(playMediaControl)
videoContainerNode.appendChild(coverElement)
videoContainerNode.appendChild(playElement)
this.setTimeout(callback, [

@@ -167,0 +184,0 @@ {

@@ -42,3 +42,3 @@ /*

// Require a click on the native Vimeo player for the initial playback:
vimeoClickToPlay: true
vimeoClickToPlay: false
})

@@ -59,6 +59,2 @@

$.extend(VimeoPlayer.prototype, {
canPlayType: function () {
return true
},
on: function (type, func) {

@@ -65,0 +61,0 @@ this.listeners[type] = func

@@ -41,3 +41,3 @@ /*

// Require a click on the native YouTube player for the initial playback:
youTubeClickToPlay: true
youTubeClickToPlay: false
})

@@ -56,6 +56,2 @@

$.extend(YouTubePlayer.prototype, {
canPlayType: function () {
return true
},
on: function (type, func) {

@@ -107,17 +103,8 @@ this.listeners[type] = func

onPause: function () {
galleryPrototype.setTimeout.call(this, this.checkSeek, null, 2000)
this.listeners.pause()
delete this.playStatus
},
checkSeek: function () {
if (
this.stateChange === YT.PlayerState.PAUSED ||
this.stateChange === YT.PlayerState.ENDED
) {
// check if current state change is actually paused
this.listeners.pause()
delete this.playStatus
}
},
onStateChange: function (event) {
window.clearTimeout(this.pauseTimeout)
switch (event.data) {

@@ -128,3 +115,16 @@ case YT.PlayerState.PLAYING:

break
case YT.PlayerState.UNSTARTED:
case YT.PlayerState.PAUSED:
// YouTube sends an unstarted event if pause is triggered before the
// video has started.
// YouTube sends a pause event when seeking.
// In both cases, we initiate a pause in a timeout that gets cleared
// if followed by another event within the timeout window.
this.pauseTimeout = galleryPrototype.setTimeout.call(
this,
this.onPause,
null,
500
)
break
case YT.PlayerState.ENDED:

@@ -134,4 +134,2 @@ this.onPause()

}
// Save most recent state change to this.stateChange
this.stateChange = event.data
},

@@ -138,0 +136,0 @@

@@ -83,4 +83,14 @@ /*

playingClass: 'blueimp-gallery-playing',
// The class to add when the browser supports SVG as img (or background):
svgasimgClass: 'blueimp-gallery-svgasimg',
// The class to add when the browser supports SMIL (animated SVGs):
smilClass: 'blueimp-gallery-smil',
// The class for all slides:
slideClass: 'slide',
// The slide class for the active (current index) slide:
slideActiveClass: 'slide-active',
// The slide class for the previous (before current index) slide:
slidePrevClass: 'slide-prev',
// The slide class for the next (after current index) slide:
slideNextClass: 'slide-next',
// The slide class for loading elements:

@@ -110,4 +120,8 @@ slideLoadingClass: 'slide-loading',

urlProperty: 'href',
// The list object property (or data attribute) with the object srcset URL(s):
srcsetProperty: 'urlset',
// The list object property (or data attribute) with the object srcset:
srcsetProperty: 'srcset',
// The list object property (or data attribute) with the object sizes:
sizesProperty: 'sizes',
// The list object property (or data attribute) with the object sources:
sourcesProperty: 'sources',
// The gallery listens for transitionend events before triggering the

@@ -119,10 +133,4 @@ // opened and closed events, unless the following option is set to false:

clearSlides: true,
// Defines if images should be stretched to fill the available space,
// while maintaining their aspect ratio (will only be enabled for browsers
// supporting background-size="contain", which excludes IE < 9).
// Set to "cover", to make images cover all available space (requires
// support for background-size="cover", which excludes IE < 9):
stretchImages: false,
// Toggle the controls on pressing the Return key:
toggleControlsOnReturn: true,
// Toggle the controls on pressing the Enter key:
toggleControlsOnEnter: true,
// Toggle the controls on slide click:

@@ -132,5 +140,5 @@ toggleControlsOnSlideClick: true,

toggleSlideshowOnSpace: true,
// Navigate the gallery by pressing left and right on the keyboard:
// Navigate the gallery by pressing the ArrowLeft and ArrowRight keys:
enableKeyboardNavigation: true,
// Close the gallery on pressing the Esc key:
// Close the gallery on pressing the Escape key:
closeOnEscape: true,

@@ -141,3 +149,3 @@ // Close the gallery when clicking on an empty slide area:

closeOnSwipeUpOrDown: true,
// Close the gallery when URL changes:
// Close the gallery when the URL hash changes:
closeOnHashChange: true,

@@ -209,3 +217,3 @@ // Emulate touch events on mouse-pointer devices such as desktop browsers:

hidePageScrollbars: false,
toggleControlsOnReturn: false,
toggleControlsOnEnter: false,
toggleSlideshowOnSpace: false,

@@ -216,2 +224,3 @@ enableKeyboardNavigation: false,

closeOnSwipeUpOrDown: false,
closeOnHashChange: false,
disableScroll: false,

@@ -229,2 +238,15 @@ startSlideshow: true

var support = {
source: !!window.HTMLSourceElement,
picture: !!window.HTMLPictureElement,
svgasimg: document.implementation.hasFeature(
'http://www.w3.org/TR/SVG11/feature#Image',
'1.1'
),
smil:
!!document.createElementNS &&
/SVGAnimate/.test(
document
.createElementNS('http://www.w3.org/2000/svg', 'animate')
.toString()
),
touch:

@@ -286,15 +308,2 @@ window.ontouchstart !== undefined ||

}
if (element.style.backgroundSize !== undefined) {
support.backgroundSize = {}
element.style.backgroundSize = 'contain'
support.backgroundSize.contain =
window
.getComputedStyle(element)
.getPropertyValue('background-size') === 'contain'
element.style.backgroundSize = 'cover'
support.backgroundSize.cover =
window
.getComputedStyle(element)
.getPropertyValue('background-size') === 'cover'
}
document.body.removeChild(element)

@@ -436,2 +445,6 @@ }

this.container.addClass(this.options.playingClass)
this.slidesContainer[0].setAttribute('aria-live', 'off')
if (this.playPauseElement.length) {
this.playPauseElement[0].setAttribute('aria-pressed', 'true')
}
},

@@ -447,2 +460,6 @@

this.container.removeClass(this.options.playingClass)
this.slidesContainer[0].setAttribute('aria-live', 'polite')
if (this.playPauseElement.length) {
this.playPauseElement[0].setAttribute('aria-pressed', 'false')
}
},

@@ -874,4 +891,4 @@

switch (event.which || event.keyCode) {
case 13: // Return
if (this.options.toggleControlsOnReturn) {
case 13: // Enter
if (this.options.toggleControlsOnEnter) {
this.preventDefault(event)

@@ -881,6 +898,6 @@ this.toggleControls()

break
case 27: // Esc
case 27: // Escape
if (this.options.closeOnEscape) {
this.close()
// prevent Esc from closing other things
// prevent Escape from closing other things
event.stopImmediatePropagation()

@@ -895,3 +912,3 @@ }

break
case 37: // Left
case 37: // ArrowLeft
if (this.options.enableKeyboardNavigation) {

@@ -902,3 +919,3 @@ this.preventDefault(event)

break
case 39: // Right
case 39: // ArrowRight
if (this.options.enableKeyboardNavigation) {

@@ -991,16 +1008,49 @@ this.preventDefault(event)

handleSlide: function (index) {
updateActiveSlide: function (oldIndex, newIndex) {
var slides = this.slides
var options = this.options
var list = [
{
index: newIndex,
method: 'addClass',
hidden: false
},
{
index: oldIndex,
method: 'removeClass',
hidden: true
}
]
var item, index
while (list.length) {
item = list.pop()
$(slides[item.index])[item.method](options.slideActiveClass)
index = this.circle(item.index - 1)
if (options.continuous || index < item.index) {
$(slides[index])[item.method](options.slidePrevClass)
}
index = this.circle(item.index + 1)
if (options.continuous || index > item.index) {
$(slides[index])[item.method](options.slideNextClass)
}
}
this.slides[oldIndex].setAttribute('aria-hidden', 'true')
this.slides[newIndex].removeAttribute('aria-hidden')
},
handleSlide: function (oldIndex, newIndex) {
if (!this.options.continuous) {
this.updateEdgeClasses(index)
this.updateEdgeClasses(newIndex)
}
this.loadElements(index)
this.updateActiveSlide(oldIndex, newIndex)
this.loadElements(newIndex)
if (this.options.unloadElements) {
this.unloadElements(index)
this.unloadElements(oldIndex, newIndex)
}
this.setTitle(index)
this.setTitle(newIndex)
},
onslide: function (index) {
this.handleSlide(this.index, index)
this.index = index
this.handleSlide(index)
this.setTimeout(this.options.onslide, [index, this.slides[index]])

@@ -1032,10 +1082,14 @@ },

imageFactory: function (obj, callback) {
var options = this.options
var that = this
var url = obj
var img = this.imagePrototype.cloneNode(false)
var url = obj
var backgroundSize = this.options.stretchImages
var picture
var called
var element
var sources
var srcset
var sizes
var title
var altText
var i
/**

@@ -1051,6 +1105,6 @@ * Wraps the callback function for the load/error event

type: event.type,
target: element
target: picture || img
}
if (!element.parentNode) {
// Fix for IE7 firing the load event for
if (!event.target.parentNode) {
// Fix for browsers (e.g. IE7) firing the load event for
// cached images before the element could

@@ -1062,8 +1116,2 @@ // be added to the DOM:

$(img).off('load error', callbackWrapper)
if (backgroundSize) {
if (event.type === 'load') {
element.style.background = 'url("' + url + '") center no-repeat'
element.style.backgroundSize = backgroundSize
}
}
callback(event)

@@ -1073,29 +1121,39 @@ }

if (typeof url !== 'string') {
url = this.getItemProperty(obj, this.options.urlProperty)
title = this.getItemProperty(obj, this.options.titleProperty)
altText =
this.getItemProperty(obj, this.options.altTextProperty) || title
url = this.getItemProperty(obj, options.urlProperty)
sources =
this.support.picture &&
this.support.source &&
this.getItemProperty(obj, options.sourcesProperty)
srcset = this.getItemProperty(obj, options.srcsetProperty)
sizes = this.getItemProperty(obj, options.sizesProperty)
title = this.getItemProperty(obj, options.titleProperty)
altText = this.getItemProperty(obj, options.altTextProperty) || title
}
if (backgroundSize === true) {
backgroundSize = 'contain'
}
backgroundSize =
this.support.backgroundSize &&
this.support.backgroundSize[backgroundSize] &&
backgroundSize
if (backgroundSize) {
element = this.elementPrototype.cloneNode(false)
} else {
element = img
img.draggable = false
}
img.draggable = false
if (title) {
element.title = title
img.title = title
}
if (altText) {
element.alt = altText
img.alt = altText
}
$(img).on('load error', callbackWrapper)
if (sources && sources.length) {
picture = this.picturePrototype.cloneNode(false)
for (i = 0; i < sources.length; i += 1) {
picture.appendChild(
$.extend(this.sourcePrototype.cloneNode(false), sources[i])
)
}
picture.appendChild(img)
$(picture).addClass(options.toggleClass)
}
if (srcset) {
if (sizes) {
img.sizes = sizes
}
img.srcset = srcset
}
img.src = url
return element
if (picture) return picture
return img
},

@@ -1108,3 +1166,2 @@

var element = obj && factory.call(this, obj, callback)
var srcset = this.getItemProperty(obj, this.options.srcsetProperty)
if (!element) {

@@ -1119,5 +1176,2 @@ element = this.elementPrototype.cloneNode(false)

}
if (srcset) {
element.setAttribute('srcset', srcset)
}
$(element).addClass(this.options.slideContentClass)

@@ -1127,2 +1181,25 @@ return element

iteratePreloadRange: function (index, func) {
var num = this.num
var options = this.options
var limit = Math.min(num, options.preloadRange * 2 + 1)
var j = index
var i
for (i = 0; i < limit; i += 1) {
// First iterate to the current index (0),
// then the next one (+1),
// then the previous one (-1),
// then the next after next (+2),
// then the one before the previous one (-2), etc.:
j += i * (i % 2 === 0 ? -1 : 1)
if (j < 0 || j >= num) {
if (!options.continuous) continue
// Connect the ends of the list to load slide elements for
// continuous iteration:
j = this.circle(j)
}
func.call(this, j)
}
},
loadElement: function (index) {

@@ -1147,32 +1224,14 @@ if (!this.elements[index]) {

loadElements: function (index) {
var limit = Math.min(this.num, this.options.preloadRange * 2 + 1)
var j = index
var i
for (i = 0; i < limit; i += 1) {
// First load the current slide element (0),
// then the next one (+1),
// then the previous one (-2),
// then the next after next (+2), etc.:
j += i * (i % 2 === 0 ? -1 : 1)
// Connect the ends of the list to load slide elements for
// continuous navigation:
j = this.circle(j)
this.loadElement(j)
}
this.iteratePreloadRange(index, this.loadElement)
},
unloadElements: function (index) {
var i, diff
for (i in this.elements) {
if (Object.prototype.hasOwnProperty.call(this.elements, i)) {
diff = Math.abs(index - i)
if (
diff > this.options.preloadRange &&
diff + this.options.preloadRange < this.num
) {
this.unloadSlide(i)
delete this.elements[i]
}
unloadElements: function (oldIndex, newIndex) {
var preloadRange = this.options.preloadRange
this.iteratePreloadRange(oldIndex, function (i) {
var diff = Math.abs(i - newIndex)
if (diff > preloadRange && diff + preloadRange < this.num) {
this.unloadSlide(i)
delete this.elements[i]
}
}
})
},

@@ -1183,2 +1242,3 @@

slide.setAttribute('data-index', index)
slide.setAttribute('aria-hidden', 'true')
this.slidesContainer[0].appendChild(slide)

@@ -1211,5 +1271,9 @@ this.slides.push(slide)

this.elements = {}
this.picturePrototype =
this.support.picture && document.createElement('picture')
this.sourcePrototype =
this.support.source && document.createElement('source')
this.imagePrototype = document.createElement('img')
this.elementPrototype = document.createElement('div')
this.slidePrototype = document.createElement('div')
this.slidePrototype = this.elementPrototype.cloneNode(false)
$(this.slidePrototype).addClass(this.options.slideClass)

@@ -1456,5 +1520,14 @@ this.slides = this.slidesContainer[0].children

this.titleElement = this.container.find(this.options.titleElement).first()
this.playPauseElement = this.container
.find('.' + this.options.playPauseClass)
.first()
if (this.num === 1) {
this.container.addClass(this.options.singleClass)
}
if (this.support.svgasimg) {
this.container.addClass(this.options.svgasimgClass)
}
if (this.support.smil) {
this.container.addClass(this.options.smilClass)
}
if (this.options.onopen) {

@@ -1461,0 +1534,0 @@ this.options.onopen.call(this)

@@ -1,2 +0,2 @@

!function(){"use strict";function t(t,e){var i;for(i in e)Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t}function i(t){if(!this||this.find!==i.prototype.find)return new i(t);if(this.length=0,t)if("string"==typeof t&&(t=this.find(t)),t.nodeType||t===t.window)this.length=1,this[0]=t;else{var e=t.length;for(this.length=e;e;)this[--e]=t[e]}}i.extend=t,i.contains=function(t,e){do{if((e=e.parentNode)===t)return!0}while(e);return!1},i.parseJSON=function(t){return window.JSON&&JSON.parse(t)},t(i.prototype,{find:function(t){var e=this[0]||document;return"string"==typeof t&&(t=e.querySelectorAll?e.querySelectorAll(t):"#"===t.charAt(0)?e.getElementById(t.slice(1)):e.getElementsByTagName(t)),new i(t)},hasClass:function(t){return!!this[0]&&new RegExp("(^|\\s+)"+t+"(\\s+|$)").test(this[0].className)},addClass:function(t){for(var e,i=this.length;i;){if(!(e=this[--i]).className)return e.className=t,this;if(this.hasClass(t))return this;e.className+=" "+t}return this},removeClass:function(t){for(var e,i=new RegExp("(^|\\s+)"+t+"(\\s+|$)"),s=this.length;s;)(e=this[--s]).className=e.className.replace(i," ");return this},on:function(t,e){for(var i,s,n=t.split(/\s+/);n.length;)for(t=n.shift(),i=this.length;i;)(s=this[--i]).addEventListener?s.addEventListener(t,e,!1):s.attachEvent&&s.attachEvent("on"+t,e);return this},off:function(t,e){for(var i,s,n=t.split(/\s+/);n.length;)for(t=n.shift(),i=this.length;i;)(s=this[--i]).removeEventListener?s.removeEventListener(t,e,!1):s.detachEvent&&s.detachEvent("on"+t,e);return this},empty:function(){for(var t,e=this.length;e;)for(t=this[--e];t.hasChildNodes();)t.removeChild(t.lastChild);return this},first:function(){return new i(this[0])}}),"function"==typeof define&&define.amd?define(function(){return i}):(window.blueimp=window.blueimp||{},window.blueimp.helper=i)}(),function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper"],t):(window.blueimp=window.blueimp||{},window.blueimp.Gallery=t(window.blueimp.helper||window.jQuery))}(function(c){"use strict";function i(t,e){return document.body.style.maxHeight===undefined?null:this&&this.options===i.prototype.options?void(t&&t.length?(this.list=t,this.num=t.length,this.initOptions(e),this.initialize()):this.console.log("blueimp Gallery: No or empty list provided as first argument.",t)):new i(t,e)}return c.extend(i.prototype,{options:{container:"#blueimp-gallery",slidesContainer:"div",titleElement:"h3",displayClass:"blueimp-gallery-display",controlsClass:"blueimp-gallery-controls",singleClass:"blueimp-gallery-single",leftEdgeClass:"blueimp-gallery-left",rightEdgeClass:"blueimp-gallery-right",playingClass:"blueimp-gallery-playing",slideClass:"slide",slideLoadingClass:"slide-loading",slideErrorClass:"slide-error",slideContentClass:"slide-content",toggleClass:"toggle",prevClass:"prev",nextClass:"next",closeClass:"close",playPauseClass:"play-pause",typeProperty:"type",titleProperty:"title",altTextProperty:"alt",urlProperty:"href",srcsetProperty:"urlset",displayTransition:!0,clearSlides:!0,stretchImages:!1,toggleControlsOnReturn:!0,toggleControlsOnSlideClick:!0,toggleSlideshowOnSpace:!0,enableKeyboardNavigation:!0,closeOnEscape:!0,closeOnSlideClick:!0,closeOnSwipeUpOrDown:!0,closeOnHashChange:!0,emulateTouchEvents:!0,stopTouchEventsPropagation:!1,hidePageScrollbars:!0,disableScroll:!0,carousel:!1,continuous:!0,unloadElements:!0,startSlideshow:!1,slideshowInterval:5e3,slideshowDirection:"ltr",index:0,preloadRange:2,transitionDuration:300,slideshowTransitionDuration:500,event:undefined,onopen:undefined,onopened:undefined,onslide:undefined,onslideend:undefined,onslidecomplete:undefined,onclose:undefined,onclosed:undefined},carouselOptions:{hidePageScrollbars:!1,toggleControlsOnReturn:!1,toggleSlideshowOnSpace:!1,enableKeyboardNavigation:!1,closeOnEscape:!1,closeOnSlideClick:!1,closeOnSwipeUpOrDown:!1,disableScroll:!1,startSlideshow:!0},console:window.console&&"function"==typeof window.console.log?window.console:{log:function(){}},support:function(s){var t,n={touch:window.ontouchstart!==undefined||window.DocumentTouch&&document instanceof DocumentTouch},e={webkitTransition:{end:"webkitTransitionEnd",prefix:"-webkit-"},MozTransition:{end:"transitionend",prefix:"-moz-"},OTransition:{end:"otransitionend",prefix:"-o-"},transition:{end:"transitionend",prefix:""}};for(t in e)if(Object.prototype.hasOwnProperty.call(e,t)&&s.style[t]!==undefined){n.transition=e[t],n.transition.name=t;break}function i(){var t,e,i=n.transition;document.body.appendChild(s),i&&(t=i.name.slice(0,-9)+"ransform",s.style[t]!==undefined&&(s.style[t]="translateZ(0)",e=window.getComputedStyle(s).getPropertyValue(i.prefix+"transform"),n.transform={prefix:i.prefix,name:t,translate:!0,translateZ:!!e&&"none"!==e})),s.style.backgroundSize!==undefined&&(n.backgroundSize={},s.style.backgroundSize="contain",n.backgroundSize.contain="contain"===window.getComputedStyle(s).getPropertyValue("background-size"),s.style.backgroundSize="cover",n.backgroundSize.cover="cover"===window.getComputedStyle(s).getPropertyValue("background-size")),document.body.removeChild(s)}return document.body?i():c(document).on("DOMContentLoaded",i),n}(document.createElement("div")),requestAnimationFrame:window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame,cancelAnimationFrame:window.cancelAnimationFrame||window.webkitCancelRequestAnimationFrame||window.webkitCancelAnimationFrame||window.mozCancelAnimationFrame,initialize:function(){if(this.initStartIndex(),!1===this.initWidget())return!1;this.initEventListeners(),this.onslide(this.index),this.ontransitionend(),this.options.startSlideshow&&this.play()},slide:function(t,e){window.clearTimeout(this.timeout);var i,s,n,o=this.index;if(o!==t&&1!==this.num){if(e=e||this.options.transitionDuration,this.support.transform){for(this.options.continuous||(t=this.circle(t)),i=Math.abs(o-t)/(o-t),this.options.continuous&&(s=i,(i=-this.positions[this.circle(t)]/this.slideWidth)!==s&&(t=-i*this.num+t)),n=Math.abs(o-t)-1;n;)--n,this.move(this.circle((o<t?t:o)-n-1),this.slideWidth*i,0);t=this.circle(t),this.move(o,this.slideWidth*i,e),this.move(t,0,e),this.options.continuous&&this.move(this.circle(t-i),-this.slideWidth*i,0)}else t=this.circle(t),this.animate(o*-this.slideWidth,t*-this.slideWidth,e);this.onslide(t)}},getIndex:function(){return this.index},getNumber:function(){return this.num},prev:function(){(this.options.continuous||this.index)&&this.slide(this.index-1)},next:function(){(this.options.continuous||this.index<this.num-1)&&this.slide(this.index+1)},play:function(t){var i=this,e=this.index+("rtl"===this.options.slideshowDirection?-1:1);window.clearTimeout(this.timeout),this.interval=t||this.options.slideshowInterval,1<this.elements[this.index]&&(this.timeout=this.setTimeout(!this.requestAnimationFrame&&this.slide||function(t,e){i.animationFrameId=i.requestAnimationFrame.call(window,function(){i.slide(t,e)})},[e,this.options.slideshowTransitionDuration],this.interval)),this.container.addClass(this.options.playingClass)},pause:function(){window.clearTimeout(this.timeout),this.interval=null,this.cancelAnimationFrame&&(this.cancelAnimationFrame.call(window,this.animationFrameId),this.animationFrameId=null),this.container.removeClass(this.options.playingClass)},add:function(t){var e;for(t.concat||(t=Array.prototype.slice.call(t)),this.list.concat||(this.list=Array.prototype.slice.call(this.list)),this.list=this.list.concat(t),this.num=this.list.length,2<this.num&&null===this.options.continuous&&(this.options.continuous=!0,this.container.removeClass(this.options.leftEdgeClass)),this.container.removeClass(this.options.rightEdgeClass).removeClass(this.options.singleClass),e=this.num-t.length;e<this.num;e+=1)this.addSlide(e),this.positionSlide(e);this.positions.length=this.num,this.initSlides(!0)},resetSlides:function(){this.slidesContainer.empty(),this.unloadAllSlides(),this.slides=[]},handleClose:function(){var t=this.options;this.destroyEventListeners(),this.pause(),this.container[0].style.display="none",this.container.removeClass(t.displayClass).removeClass(t.singleClass).removeClass(t.leftEdgeClass).removeClass(t.rightEdgeClass),t.hidePageScrollbars&&(document.body.style.overflow=this.bodyOverflowStyle),this.options.clearSlides&&this.resetSlides(),this.options.onclosed&&this.options.onclosed.call(this)},close:function(){var e=this;this.options.onclose&&this.options.onclose.call(this),this.support.transition&&this.options.displayTransition?(this.container.on(this.support.transition.end,function i(t){t.target===e.container[0]&&(e.container.off(e.support.transition.end,i),e.handleClose())}),this.container.removeClass(this.options.displayClass)):this.handleClose()},circle:function(t){return(this.num+t%this.num)%this.num},move:function(t,e,i){this.translateX(t,e,i),this.positions[t]=e},translate:function(t,e,i,s){var n,o,a;this.slides[t]&&(n=this.slides[t].style,o=this.support.transition,a=this.support.transform,n[o.name+"Duration"]=s+"ms",n[a.name]="translate("+e+"px, "+i+"px)"+(a.translateZ?" translateZ(0)":""))},translateX:function(t,e,i){this.translate(t,e,0,i)},translateY:function(t,e,i){this.translate(t,0,e,i)},animate:function(e,i,s){var n,o,a;s?(n=this,o=(new Date).getTime(),a=window.setInterval(function(){var t=(new Date).getTime()-o;if(s<t)return n.slidesContainer[0].style.left=i+"px",n.ontransitionend(),void window.clearInterval(a);n.slidesContainer[0].style.left=(i-e)*(Math.floor(t/s*100)/100)+e+"px"},4)):this.slidesContainer[0].style.left=i+"px"},preventDefault:function(t){t.preventDefault?t.preventDefault():t.returnValue=!1},stopPropagation:function(t){t.stopPropagation?t.stopPropagation():t.cancelBubble=!0},onresize:function(){this.initSlides(!0)},onhashchange:function(){this.options.closeOnHashChange&&this.close()},onmousedown:function(t){t.which&&1===t.which&&"VIDEO"!==t.target.nodeName&&"AUDIO"!==t.target.nodeName&&(t.preventDefault(),(t.originalEvent||t).touches=[{pageX:t.pageX,pageY:t.pageY}],this.ontouchstart(t))},onmousemove:function(t){this.touchStart&&((t.originalEvent||t).touches=[{pageX:t.pageX,pageY:t.pageY}],this.ontouchmove(t))},onmouseup:function(t){this.touchStart&&(this.ontouchend(t),delete this.touchStart)},onmouseout:function(t){var e,i;this.touchStart&&(e=t.target,(i=t.relatedTarget)&&(i===e||c.contains(e,i))||this.onmouseup(t))},ontouchstart:function(t){this.options.stopTouchEventsPropagation&&this.stopPropagation(t);var e=(t.originalEvent||t).touches[0];this.touchStart={x:e.pageX,y:e.pageY,time:Date.now()},this.isScrolling=undefined,this.touchDelta={}},ontouchmove:function(t){this.options.stopTouchEventsPropagation&&this.stopPropagation(t);var e,i,s=(t.originalEvent||t).touches,n=s[0],o=(t.originalEvent||t).scale,a=this.index;if(!(1<s.length||o&&1!==o))if(this.options.disableScroll&&t.preventDefault(),this.touchDelta={x:n.pageX-this.touchStart.x,y:n.pageY-this.touchStart.y},e=this.touchDelta.x,this.isScrolling===undefined&&(this.isScrolling=this.isScrolling||Math.abs(e)<Math.abs(this.touchDelta.y)),this.isScrolling)this.options.carousel||this.translateY(a,this.touchDelta.y+this.positions[a],0);else for(t.preventDefault(),window.clearTimeout(this.timeout),this.options.continuous?i=[this.circle(a+1),a,this.circle(a-1)]:(this.touchDelta.x=e/=!a&&0<e||a===this.num-1&&e<0?Math.abs(e)/this.slideWidth+1:1,i=[a],a&&i.push(a-1),a<this.num-1&&i.unshift(a+1));i.length;)a=i.pop(),this.translateX(a,e+this.positions[a],0)},ontouchend:function(t){this.options.stopTouchEventsPropagation&&this.stopPropagation(t);var e,i,s,n,o,a=this.index,l=Math.abs(this.touchDelta.x),r=this.slideWidth,h=Math.ceil(this.options.transitionDuration*(1-l/r)/2),d=20<l,c=!a&&0<this.touchDelta.x||a===this.num-1&&this.touchDelta.x<0,u=!d&&this.options.closeOnSwipeUpOrDown&&20<Math.abs(this.touchDelta.y);this.options.continuous&&(c=!1),e=this.touchDelta.x<0?-1:1,this.isScrolling?u?this.close():this.translateY(a,0,h):d&&!c?(i=a+e,s=a-e,n=r*e,o=-r*e,this.options.continuous?(this.move(this.circle(i),n,0),this.move(this.circle(a-2*e),o,0)):0<=i&&i<this.num&&this.move(i,n,0),this.move(a,this.positions[a]+n,h),this.move(this.circle(s),this.positions[this.circle(s)]+n,h),a=this.circle(s),this.onslide(a)):this.options.continuous?(this.move(this.circle(a-1),-r,h),this.move(a,0,h),this.move(this.circle(a+1),r,h)):(a&&this.move(a-1,-r,h),this.move(a,0,h),a<this.num-1&&this.move(a+1,r,h))},ontouchcancel:function(t){this.touchStart&&(this.ontouchend(t),delete this.touchStart)},ontransitionend:function(t){var e=this.slides[this.index];t&&e!==t.target||(this.interval&&this.play(),this.setTimeout(this.options.onslideend,[this.index,e]))},oncomplete:function(t){var e,i=t.target||t.srcElement,s=i&&i.parentNode;i&&s&&(e=this.getNodeIndex(s),c(s).removeClass(this.options.slideLoadingClass),"error"===t.type?(c(s).addClass(this.options.slideErrorClass),this.elements[e]=3):this.elements[e]=2,i.clientHeight>this.container[0].clientHeight&&(i.style.maxHeight=this.container[0].clientHeight),this.interval&&this.slides[this.index]===s&&this.play(),this.setTimeout(this.options.onslidecomplete,[e,s]))},onload:function(t){this.oncomplete(t)},onerror:function(t){this.oncomplete(t)},onkeydown:function(t){switch(t.which||t.keyCode){case 13:this.options.toggleControlsOnReturn&&(this.preventDefault(t),this.toggleControls());break;case 27:this.options.closeOnEscape&&(this.close(),t.stopImmediatePropagation());break;case 32:this.options.toggleSlideshowOnSpace&&(this.preventDefault(t),this.toggleSlideshow());break;case 37:this.options.enableKeyboardNavigation&&(this.preventDefault(t),this.prev());break;case 39:this.options.enableKeyboardNavigation&&(this.preventDefault(t),this.next())}},handleClick:function(t){var e=this.options,i=t.target||t.srcElement,s=i.parentNode;function n(t){return c(i).hasClass(t)||c(s).hasClass(t)}n(e.toggleClass)?(this.preventDefault(t),this.toggleControls()):n(e.prevClass)?(this.preventDefault(t),this.prev()):n(e.nextClass)?(this.preventDefault(t),this.next()):n(e.closeClass)?(this.preventDefault(t),this.close()):n(e.playPauseClass)?(this.preventDefault(t),this.toggleSlideshow()):s===this.slidesContainer[0]?e.closeOnSlideClick?(this.preventDefault(t),this.close()):e.toggleControlsOnSlideClick&&(this.preventDefault(t),this.toggleControls()):s.parentNode&&s.parentNode===this.slidesContainer[0]&&e.toggleControlsOnSlideClick&&(this.preventDefault(t),this.toggleControls())},onclick:function(t){if(!(this.options.emulateTouchEvents&&this.touchDelta&&(20<Math.abs(this.touchDelta.x)||20<Math.abs(this.touchDelta.y))))return this.handleClick(t);delete this.touchDelta},updateEdgeClasses:function(t){t?this.container.removeClass(this.options.leftEdgeClass):this.container.addClass(this.options.leftEdgeClass),t===this.num-1?this.container.addClass(this.options.rightEdgeClass):this.container.removeClass(this.options.rightEdgeClass)},handleSlide:function(t){this.options.continuous||this.updateEdgeClasses(t),this.loadElements(t),this.options.unloadElements&&this.unloadElements(t),this.setTitle(t)},onslide:function(t){this.index=t,this.handleSlide(t),this.setTimeout(this.options.onslide,[t,this.slides[t]])},setTitle:function(t){var e=this.slides[t].firstChild,i=e.title||e.alt,s=this.titleElement;s.length&&(this.titleElement.empty(),i&&s[0].appendChild(document.createTextNode(i)))},setTimeout:function(t,e,i){var s=this;return t&&window.setTimeout(function(){t.apply(s,e||[])},i||0)},imageFactory:function(t,e){var i,s,n,o,a=this,l=this.imagePrototype.cloneNode(!1),r=t,h=this.options.stretchImages;return"string"!=typeof r&&(r=this.getItemProperty(t,this.options.urlProperty),n=this.getItemProperty(t,this.options.titleProperty),o=this.getItemProperty(t,this.options.altTextProperty)||n),!0===h&&(h="contain"),(h=this.support.backgroundSize&&this.support.backgroundSize[h]&&h)?s=this.elementPrototype.cloneNode(!1):(s=l).draggable=!1,n&&(s.title=n),o&&(s.alt=o),c(l).on("load error",function d(t){if(!i){if(t={type:t.type,target:s},!s.parentNode)return a.setTimeout(d,[t]);i=!0,c(l).off("load error",d),h&&"load"===t.type&&(s.style.background='url("'+r+'") center no-repeat',s.style.backgroundSize=h),e(t)}}),l.src=r,s},createElement:function(t,e){var i=t&&this.getItemProperty(t,this.options.typeProperty),s=i&&this[i.split("/")[0]+"Factory"]||this.imageFactory,n=t&&s.call(this,t,e),o=this.getItemProperty(t,this.options.srcsetProperty);return n||(n=this.elementPrototype.cloneNode(!1),this.setTimeout(e,[{type:"error",target:n}])),o&&n.setAttribute("srcset",o),c(n).addClass(this.options.slideContentClass),n},loadElement:function(t){this.elements[t]||(this.slides[t].firstChild?this.elements[t]=c(this.slides[t]).hasClass(this.options.slideErrorClass)?3:2:(this.elements[t]=1,c(this.slides[t]).addClass(this.options.slideLoadingClass),this.slides[t].appendChild(this.createElement(this.list[t],this.proxyListener))))},loadElements:function(t){for(var e=Math.min(this.num,2*this.options.preloadRange+1),i=t,s=0;s<e;s+=1)i+=s*(s%2==0?-1:1),i=this.circle(i),this.loadElement(i)},unloadElements:function(t){var e,i;for(e in this.elements)Object.prototype.hasOwnProperty.call(this.elements,e)&&(i=Math.abs(t-e))>this.options.preloadRange&&i+this.options.preloadRange<this.num&&(this.unloadSlide(e),delete this.elements[e])},addSlide:function(t){var e=this.slidePrototype.cloneNode(!1);e.setAttribute("data-index",t),this.slidesContainer[0].appendChild(e),this.slides.push(e)},positionSlide:function(t){var e=this.slides[t];e.style.width=this.slideWidth+"px",this.support.transform&&(e.style.left=t*-this.slideWidth+"px",this.move(t,this.index>t?-this.slideWidth:this.index<t?this.slideWidth:0,0))},initSlides:function(t){var e,i;for(t||(this.positions=[],this.positions.length=this.num,this.elements={},this.imagePrototype=document.createElement("img"),this.elementPrototype=document.createElement("div"),this.slidePrototype=document.createElement("div"),c(this.slidePrototype).addClass(this.options.slideClass),this.slides=this.slidesContainer[0].children,e=this.options.clearSlides||this.slides.length!==this.num),this.slideWidth=this.container[0].clientWidth,this.slideHeight=this.container[0].clientHeight,this.slidesContainer[0].style.width=this.num*this.slideWidth+"px",e&&this.resetSlides(),i=0;i<this.num;i+=1)e&&this.addSlide(i),this.positionSlide(i);this.options.continuous&&this.support.transform&&(this.move(this.circle(this.index-1),-this.slideWidth,0),this.move(this.circle(this.index+1),this.slideWidth,0)),this.support.transform||(this.slidesContainer[0].style.left=this.index*-this.slideWidth+"px")},unloadSlide:function(t){var e=this.slides[t],i=e.firstChild;null!==i&&e.removeChild(i)},unloadAllSlides:function(){for(var t=0,e=this.slides.length;t<e;t++)this.unloadSlide(t)},toggleControls:function(){var t=this.options.controlsClass;this.container.hasClass(t)?this.container.removeClass(t):this.container.addClass(t)},toggleSlideshow:function(){this.interval?this.pause():this.play()},getNodeIndex:function(t){return parseInt(t.getAttribute("data-index"),10)},getNestedProperty:function(a,t){return t.replace(/\[(?:'([^']+)'|"([^"]+)"|(\d+))\]|(?:(?:^|\.)([^\.\[]+))/g,function(t,e,i,s,n){var o=n||e||i||s&&parseInt(s,10);t&&a&&(a=a[o])}),a},getDataProperty:function(t,e){var i,s;if(t.dataset?(i=e.replace(/-([a-z])/g,function(t,e){return e.toUpperCase()}),s=t.dataset[i]):t.getAttribute&&(s=t.getAttribute("data-"+e.replace(/([A-Z])/g,"-$1").toLowerCase())),"string"==typeof s){if(/^(true|false|null|-?\d+(\.\d+)?|\{[\s\S]*\}|\[[\s\S]*\])$/.test(s))try{return c.parseJSON(s)}catch(n){}return s}},getItemProperty:function(t,e){var i=this.getDataProperty(t,e);return i===undefined&&(i=t[e]),i===undefined&&(i=this.getNestedProperty(t,e)),i},initStartIndex:function(){var t,e=this.options.index,i=this.options.urlProperty;if(e&&"number"!=typeof e)for(t=0;t<this.num;t+=1)if(this.list[t]===e||this.getItemProperty(this.list[t],i)===this.getItemProperty(e,i)){e=t;break}this.index=this.circle(parseInt(e,10)||0)},initEventListeners:function(){var i=this,t=this.slidesContainer;function e(t){var e=i.support.transition&&i.support.transition.end===t.type?"transitionend":t.type;i["on"+e](t)}c(window).on("resize",e),c(window).on("hashchange",e),c(document.body).on("keydown",e),this.container.on("click",e),this.support.touch?t.on("touchstart touchmove touchend touchcancel",e):this.options.emulateTouchEvents&&this.support.transition&&t.on("mousedown mousemove mouseup mouseout",e),this.support.transition&&t.on(this.support.transition.end,e),this.proxyListener=e},destroyEventListeners:function(){var t=this.slidesContainer,e=this.proxyListener;c(window).off("resize",e),c(document.body).off("keydown",e),this.container.off("click",e),this.support.touch?t.off("touchstart touchmove touchend touchcancel",e):this.options.emulateTouchEvents&&this.support.transition&&t.off("mousedown mousemove mouseup mouseout",e),this.support.transition&&t.off(this.support.transition.end,e)},handleOpen:function(){this.options.onopened&&this.options.onopened.call(this)},initWidget:function(){var e=this;return this.container=c(this.options.container),this.container.length?(this.slidesContainer=this.container.find(this.options.slidesContainer).first(),this.slidesContainer.length?(this.titleElement=this.container.find(this.options.titleElement).first(),1===this.num&&this.container.addClass(this.options.singleClass),this.options.onopen&&this.options.onopen.call(this),this.support.transition&&this.options.displayTransition?this.container.on(this.support.transition.end,function i(t){t.target===e.container[0]&&(e.container.off(e.support.transition.end,i),e.handleOpen())}):this.handleOpen(),this.options.hidePageScrollbars&&(this.bodyOverflowStyle=document.body.style.overflow,document.body.style.overflow="hidden"),this.container[0].style.display="block",this.initSlides(),void this.container.addClass(this.options.displayClass)):(this.console.log("blueimp Gallery: Slides container not found.",this.options.slidesContainer),!1)):(this.console.log("blueimp Gallery: Widget container not found.",this.options.container),!1)},initOptions:function(t){this.options=c.extend({},this.options),(t&&t.carousel||this.options.carousel&&(!t||!1!==t.carousel))&&c.extend(this.options,this.carouselOptions),c.extend(this.options,t),this.num<3&&(this.options.continuous=!!this.options.continuous&&null),this.support.transition||(this.options.emulateTouchEvents=!1),this.options.event&&this.preventDefault(this.options.event)}}),i}),function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper","./blueimp-gallery"],t):t(window.blueimp.helper||window.jQuery,window.blueimp.Gallery)}(function(t,e){"use strict";var i=e.prototype;t.extend(i.options,{fullScreen:!1});var s=i.initialize,n=i.close;return t.extend(i,{getFullScreenElement:function(){return document.fullscreenElement||document.webkitFullscreenElement||document.mozFullScreenElement||document.msFullscreenElement},requestFullScreen:function(t){t.requestFullscreen?t.requestFullscreen():t.webkitRequestFullscreen?t.webkitRequestFullscreen():t.mozRequestFullScreen?t.mozRequestFullScreen():t.msRequestFullscreen&&t.msRequestFullscreen()},exitFullScreen:function(){document.exitFullscreen?document.exitFullscreen():document.webkitCancelFullScreen?document.webkitCancelFullScreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.msExitFullscreen&&document.msExitFullscreen()},initialize:function(){s.call(this),this.options.fullScreen&&!this.getFullScreenElement()&&this.requestFullScreen(this.container[0])},close:function(){this.getFullScreenElement()===this.container[0]&&this.exitFullScreen(),n.call(this)}}),e}),function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper","./blueimp-gallery"],t):t(window.blueimp.helper||window.jQuery,window.blueimp.Gallery)}(function(a,t){"use strict";var e=t.prototype;a.extend(e.options,{indicatorContainer:"ol",activeIndicatorClass:"active",thumbnailProperty:"thumbnail",thumbnailIndicators:!0});var i=e.initSlides,s=e.addSlide,n=e.resetSlides,o=e.handleClick,l=e.handleSlide,r=e.handleClose;return a.extend(e,{createIndicator:function(t){var e,i,s=this.indicatorPrototype.cloneNode(!1),n=this.getItemProperty(t,this.options.titleProperty),o=this.options.thumbnailProperty;return this.options.thumbnailIndicators&&(o&&(e=this.getItemProperty(t,o)),e===undefined&&(i=t.getElementsByTagName&&a(t).find("img")[0])&&(e=i.src),e&&(s.style.backgroundImage='url("'+e+'")')),n&&(s.title=n),s},addIndicator:function(t){var e;this.indicatorContainer.length&&((e=this.createIndicator(this.list[t])).setAttribute("data-index",t),this.indicatorContainer[0].appendChild(e),this.indicators.push(e))},setActiveIndicator:function(t){this.indicators&&(this.activeIndicator&&this.activeIndicator.removeClass(this.options.activeIndicatorClass),this.activeIndicator=a(this.indicators[t]),this.activeIndicator.addClass(this.options.activeIndicatorClass))},initSlides:function(t){t||(this.indicatorContainer=this.container.find(this.options.indicatorContainer),this.indicatorContainer.length&&(this.indicatorPrototype=document.createElement("li"),this.indicators=this.indicatorContainer[0].children)),i.call(this,t)},addSlide:function(t){s.call(this,t),this.addIndicator(t)},resetSlides:function(){n.call(this),this.indicatorContainer.empty(),this.indicators=[]},handleClick:function(t){var e=t.target||t.srcElement,i=e.parentNode;if(i===this.indicatorContainer[0])this.preventDefault(t),this.slide(this.getNodeIndex(e));else{if(i.parentNode!==this.indicatorContainer[0])return o.call(this,t);this.preventDefault(t),this.slide(this.getNodeIndex(i))}},handleSlide:function(t){l.call(this,t),this.setActiveIndicator(t)},handleClose:function(){this.activeIndicator&&this.activeIndicator.removeClass(this.options.activeIndicatorClass),r.call(this)}}),t}),function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper","./blueimp-gallery"],t):t(window.blueimp.helper||window.jQuery,window.blueimp.Gallery)}(function(w,t){"use strict";var e=t.prototype;w.extend(e.options,{videoContentClass:"video-content",videoLoadingClass:"video-loading",videoPlayingClass:"video-playing",videoPosterProperty:"poster",videoSourcesProperty:"sources"});var i=e.handleSlide;return w.extend(e,{handleSlide:function(t){i.call(this,t),this.playingVideo&&this.playingVideo.pause()},videoFactory:function(t,e,i){var s,n,o,a,l,r=this,h=this.options,d=this.elementPrototype.cloneNode(!1),c=w(d),u=[{type:"error",target:d}],p=i||document.createElement("video"),m=this.getItemProperty(t,h.urlProperty),y=this.getItemProperty(t,h.typeProperty),f=this.getItemProperty(t,h.titleProperty),g=this.getItemProperty(t,this.options.altTextProperty)||f,v=this.getItemProperty(t,h.videoPosterProperty),C=this.getItemProperty(t,h.videoSourcesProperty);if(c.addClass(h.videoContentClass),f&&(d.title=f),p.canPlayType)if(m&&y&&p.canPlayType(y))p.src=m;else if(C)for(;C.length;)if(n=C.shift(),m=this.getItemProperty(n,h.urlProperty),y=this.getItemProperty(n,h.typeProperty),m&&y&&p.canPlayType(y)){p.src=m;break}return v&&(p.poster=v,s=this.imagePrototype.cloneNode(!1),w(s).addClass(h.toggleClass),s.src=v,s.draggable=!1,s.alt=g,d.appendChild(s)),(o=document.createElement("a")).setAttribute("target","_blank"),i||o.setAttribute("download",f),o.href=m,p.src&&(p.controls=!0,(i||w(p)).on("error",function(){r.setTimeout(e,u)}).on("pause",function(){p.seeking||(a=!1,c.removeClass(r.options.videoLoadingClass).removeClass(r.options.videoPlayingClass),l&&r.container.addClass(r.options.controlsClass),delete r.playingVideo,r.interval&&r.play())}).on("playing",function(){a=!1,c.removeClass(r.options.videoLoadingClass).addClass(r.options.videoPlayingClass),r.container.hasClass(r.options.controlsClass)?(l=!0,r.container.removeClass(r.options.controlsClass)):l=!1}).on("play",function(){window.clearTimeout(r.timeout),a=!0,c.addClass(r.options.videoLoadingClass),r.playingVideo=p}),w(o).on("click",function(t){r.preventDefault(t),a?p.pause():p.play()}),d.appendChild(i&&i.element||p)),d.appendChild(o),this.setTimeout(e,[{type:"load",target:d}]),d}}),t}),function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper","./blueimp-gallery-video"],t):t(window.blueimp.helper||window.jQuery,window.blueimp.Gallery)}(function(l,t){"use strict";if(!window.postMessage)return t;var e=t.prototype;l.extend(e.options,{vimeoVideoIdProperty:"vimeo",vimeoPlayerUrl:"//player.vimeo.com/video/VIDEO_ID?api=1&player_id=PLAYER_ID",vimeoPlayerIdPrefix:"vimeo-player-",vimeoClickToPlay:!0});var n=e.textFactory||e.imageFactory,o=function(t,e,i,s){this.url=t,this.videoId=e,this.playerId=i,this.clickToPlay=s,this.element=document.createElement("div"),this.listeners={}},a=0;return l.extend(o.prototype,{canPlayType:function(){return!0},on:function(t,e){return this.listeners[t]=e,this},loadAPI:function(){var t,e,i=this,s="//f.vimeocdn.com/js/froogaloop2.min.js",n=document.getElementsByTagName("script"),o=n.length;function a(){!e&&i.playOnReady&&i.play(),e=!0}for(;o;)if(n[--o].src===s){t=n[o];break}t||((t=document.createElement("script")).src=s),l(t).on("load",a),n[0].parentNode.insertBefore(t,n[0]),/loaded|complete/.test(t.readyState)&&a()},onReady:function(){var t=this;this.ready=!0,this.player.addEvent("play",function(){t.hasPlayed=!0,t.onPlaying()}),this.player.addEvent("pause",function(){t.onPause()}),this.player.addEvent("finish",function(){t.onPause()}),this.playOnReady&&this.play()},onPlaying:function(){this.playStatus<2&&(this.listeners.playing(),this.playStatus=2)},onPause:function(){this.listeners.pause(),delete this.playStatus},insertIframe:function(){var t=document.createElement("iframe");t.src=this.url.replace("VIDEO_ID",this.videoId).replace("PLAYER_ID",this.playerId),t.id=this.playerId,this.element.parentNode.replaceChild(t,this.element),this.element=t},play:function(){var t=this;this.playStatus||(this.listeners.play(),this.playStatus=1),this.ready?!this.hasPlayed&&(this.clickToPlay||window.navigator&&/iP(hone|od|ad)/.test(window.navigator.platform))?this.onPlaying():this.player.api("play"):(this.playOnReady=!0,window.$f?this.player||(this.insertIframe(),this.player=$f(this.element),this.player.addEvent("ready",function(){t.onReady()})):this.loadAPI())},pause:function(){this.ready?this.player.api("pause"):this.playStatus&&(delete this.playOnReady,this.listeners.pause(),delete this.playStatus)}}),l.extend(e,{VimeoPlayer:o,textFactory:function(t,e){var i=this.options,s=this.getItemProperty(t,i.vimeoVideoIdProperty);return s?(this.getItemProperty(t,i.urlProperty)===undefined&&(t[i.urlProperty]="//vimeo.com/"+s),a+=1,this.videoFactory(t,e,new o(i.vimeoPlayerUrl,s,i.vimeoPlayerIdPrefix+a,i.vimeoClickToPlay))):n.call(this,t,e)}}),t}),function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper","./blueimp-gallery-video"],t):t(window.blueimp.helper||window.jQuery,window.blueimp.Gallery)}(function(t,e){"use strict";if(!window.postMessage)return e;var i=e.prototype;t.extend(i.options,{youTubeVideoIdProperty:"youtube",youTubePlayerVars:{wmode:"transparent"},youTubeClickToPlay:!0});var n=i.textFactory||i.imageFactory,o=function(t,e,i){this.videoId=t,this.playerVars=e,this.clickToPlay=i,this.element=document.createElement("div"),this.listeners={}};return t.extend(o.prototype,{canPlayType:function(){return!0},on:function(t,e){return this.listeners[t]=e,this},loadAPI:function(){var t,e=this,i=window.onYouTubeIframeAPIReady,s="//www.youtube.com/iframe_api",n=document.getElementsByTagName("script"),o=n.length;for(window.onYouTubeIframeAPIReady=function(){i&&i.apply(this),e.playOnReady&&e.play()};o;)if(n[--o].src===s)return;(t=document.createElement("script")).src=s,n[0].parentNode.insertBefore(t,n[0])},onReady:function(){this.ready=!0,this.playOnReady&&this.play()},onPlaying:function(){this.playStatus<2&&(this.listeners.playing(),this.playStatus=2)},onPause:function(){i.setTimeout.call(this,this.checkSeek,null,2e3)},checkSeek:function(){this.stateChange!==YT.PlayerState.PAUSED&&this.stateChange!==YT.PlayerState.ENDED||(this.listeners.pause(),delete this.playStatus)},onStateChange:function(t){switch(t.data){case YT.PlayerState.PLAYING:this.hasPlayed=!0,this.onPlaying();break;case YT.PlayerState.PAUSED:case YT.PlayerState.ENDED:this.onPause()}this.stateChange=t.data},onError:function(t){this.listeners.error(t)},play:function(){var e=this;this.playStatus||(this.listeners.play(),this.playStatus=1),this.ready?!this.hasPlayed&&(this.clickToPlay||window.navigator&&/iP(hone|od|ad)/.test(window.navigator.platform))?this.onPlaying():this.player.playVideo():(this.playOnReady=!0,window.YT&&YT.Player?this.player||(this.player=new YT.Player(this.element,{videoId:this.videoId,playerVars:this.playerVars,events:{onReady:function(){e.onReady()},onStateChange:function(t){e.onStateChange(t)},onError:function(t){e.onError(t)}}})):this.loadAPI())},pause:function(){this.ready?this.player.pauseVideo():this.playStatus&&(delete this.playOnReady,this.listeners.pause(),delete this.playStatus)}}),t.extend(i,{YouTubePlayer:o,textFactory:function(t,e){var i=this.options,s=this.getItemProperty(t,i.youTubeVideoIdProperty);return s?(this.getItemProperty(t,i.urlProperty)===undefined&&(t[i.urlProperty]="//www.youtube.com/watch?v="+s),this.getItemProperty(t,i.videoPosterProperty)===undefined&&(t[i.videoPosterProperty]="//img.youtube.com/vi/"+s+"/maxresdefault.jpg"),this.videoFactory(t,e,new o(s,i.youTubePlayerVars,i.youTubeClickToPlay))):n.call(this,t,e)}}),e});
!function(){"use strict";function t(t,e){var i;for(i in e)Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t}function i(t){if(!this||this.find!==i.prototype.find)return new i(t);if(this.length=0,t)if("string"==typeof t&&(t=this.find(t)),t.nodeType||t===t.window)this.length=1,this[0]=t;else{var e=t.length;for(this.length=e;e;)this[--e]=t[e]}}i.extend=t,i.contains=function(t,e){do{if((e=e.parentNode)===t)return!0}while(e);return!1},i.parseJSON=function(t){return JSON.parse(t)},t(i.prototype,{find:function(t){var e=this[0]||document;return"string"==typeof t&&(t=e.querySelectorAll?e.querySelectorAll(t):"#"===t.charAt(0)?e.getElementById(t.slice(1)):e.getElementsByTagName(t)),new i(t)},hasClass:function(t){return!!this[0]&&new RegExp("(?:^|\\s+)"+t+"(?:\\s+|$)").test(this[0].className)},addClass:function(t){for(var e,i,s,n=this.length;n;)if((i=this[--n]).className)for(e=e||t.split(/\s+/),s=0;s<e.length;s+=1)this.hasClass(e[s])||(i.className+=" "+e[s]);else i.className=t;return this},removeClass:function(t){for(var e,i=new RegExp("^(?:"+t.split(/\s+/).join("|")+")$"),s=/(\S+)(?:\s+|$)/g,n=function(t,e){return i.test(e)?"":t},o=/\s+$/,a=this.length;a;)(e=this[--a]).className=e.className.replace(s,n).replace(o,"");return this},on:function(t,e){for(var i,s,n=t.split(/\s+/);n.length;)for(t=n.shift(),i=this.length;i;)(s=this[--i]).addEventListener?s.addEventListener(t,e,!1):s.attachEvent&&s.attachEvent("on"+t,e);return this},off:function(t,e){for(var i,s,n=t.split(/\s+/);n.length;)for(t=n.shift(),i=this.length;i;)(s=this[--i]).removeEventListener?s.removeEventListener(t,e,!1):s.detachEvent&&s.detachEvent("on"+t,e);return this},empty:function(){for(var t,e=this.length;e;)for(t=this[--e];t.hasChildNodes();)t.removeChild(t.lastChild);return this},first:function(){return new i(this[0])}}),"function"==typeof define&&define.amd?define(function(){return i}):(window.blueimp=window.blueimp||{},window.blueimp.helper=i)}(),function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper"],t):(window.blueimp=window.blueimp||{},window.blueimp.Gallery=t(window.blueimp.helper||window.jQuery))}(function(f){"use strict";function i(t,e){return document.body.style.maxHeight===undefined?null:this&&this.options===i.prototype.options?void(t&&t.length?(this.list=t,this.num=t.length,this.initOptions(e),this.initialize()):this.console.log("blueimp Gallery: No or empty list provided as first argument.",t)):new i(t,e)}return f.extend(i.prototype,{options:{container:"#blueimp-gallery",slidesContainer:"div",titleElement:"h3",displayClass:"blueimp-gallery-display",controlsClass:"blueimp-gallery-controls",singleClass:"blueimp-gallery-single",leftEdgeClass:"blueimp-gallery-left",rightEdgeClass:"blueimp-gallery-right",playingClass:"blueimp-gallery-playing",svgasimgClass:"blueimp-gallery-svgasimg",smilClass:"blueimp-gallery-smil",slideClass:"slide",slideActiveClass:"slide-active",slidePrevClass:"slide-prev",slideNextClass:"slide-next",slideLoadingClass:"slide-loading",slideErrorClass:"slide-error",slideContentClass:"slide-content",toggleClass:"toggle",prevClass:"prev",nextClass:"next",closeClass:"close",playPauseClass:"play-pause",typeProperty:"type",titleProperty:"title",altTextProperty:"alt",urlProperty:"href",srcsetProperty:"srcset",sizesProperty:"sizes",sourcesProperty:"sources",displayTransition:!0,clearSlides:!0,toggleControlsOnEnter:!0,toggleControlsOnSlideClick:!0,toggleSlideshowOnSpace:!0,enableKeyboardNavigation:!0,closeOnEscape:!0,closeOnSlideClick:!0,closeOnSwipeUpOrDown:!0,closeOnHashChange:!0,emulateTouchEvents:!0,stopTouchEventsPropagation:!1,hidePageScrollbars:!0,disableScroll:!0,carousel:!1,continuous:!0,unloadElements:!0,startSlideshow:!1,slideshowInterval:5e3,slideshowDirection:"ltr",index:0,preloadRange:2,transitionDuration:300,slideshowTransitionDuration:500,event:undefined,onopen:undefined,onopened:undefined,onslide:undefined,onslideend:undefined,onslidecomplete:undefined,onclose:undefined,onclosed:undefined},carouselOptions:{hidePageScrollbars:!1,toggleControlsOnEnter:!1,toggleSlideshowOnSpace:!1,enableKeyboardNavigation:!1,closeOnEscape:!1,closeOnSlideClick:!1,closeOnSwipeUpOrDown:!1,closeOnHashChange:!1,disableScroll:!1,startSlideshow:!0},console:window.console&&"function"==typeof window.console.log?window.console:{log:function(){}},support:function(s){var t,n={source:!!window.HTMLSourceElement,picture:!!window.HTMLPictureElement,svgasimg:document.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#Image","1.1"),smil:!!document.createElementNS&&/SVGAnimate/.test(document.createElementNS("http://www.w3.org/2000/svg","animate").toString()),touch:window.ontouchstart!==undefined||window.DocumentTouch&&document instanceof DocumentTouch},e={webkitTransition:{end:"webkitTransitionEnd",prefix:"-webkit-"},MozTransition:{end:"transitionend",prefix:"-moz-"},OTransition:{end:"otransitionend",prefix:"-o-"},transition:{end:"transitionend",prefix:""}};for(t in e)if(Object.prototype.hasOwnProperty.call(e,t)&&s.style[t]!==undefined){n.transition=e[t],n.transition.name=t;break}function i(){var t,e,i=n.transition;document.body.appendChild(s),i&&(t=i.name.slice(0,-9)+"ransform",s.style[t]!==undefined&&(s.style[t]="translateZ(0)",e=window.getComputedStyle(s).getPropertyValue(i.prefix+"transform"),n.transform={prefix:i.prefix,name:t,translate:!0,translateZ:!!e&&"none"!==e})),document.body.removeChild(s)}return document.body?i():f(document).on("DOMContentLoaded",i),n}(document.createElement("div")),requestAnimationFrame:window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame,cancelAnimationFrame:window.cancelAnimationFrame||window.webkitCancelRequestAnimationFrame||window.webkitCancelAnimationFrame||window.mozCancelAnimationFrame,initialize:function(){if(this.initStartIndex(),!1===this.initWidget())return!1;this.initEventListeners(),this.onslide(this.index),this.ontransitionend(),this.options.startSlideshow&&this.play()},slide:function(t,e){window.clearTimeout(this.timeout);var i,s,n,o=this.index;if(o!==t&&1!==this.num){if(e=e||this.options.transitionDuration,this.support.transform){for(this.options.continuous||(t=this.circle(t)),i=Math.abs(o-t)/(o-t),this.options.continuous&&(s=i,(i=-this.positions[this.circle(t)]/this.slideWidth)!==s&&(t=-i*this.num+t)),n=Math.abs(o-t)-1;n;)--n,this.move(this.circle((o<t?t:o)-n-1),this.slideWidth*i,0);t=this.circle(t),this.move(o,this.slideWidth*i,e),this.move(t,0,e),this.options.continuous&&this.move(this.circle(t-i),-this.slideWidth*i,0)}else t=this.circle(t),this.animate(o*-this.slideWidth,t*-this.slideWidth,e);this.onslide(t)}},getIndex:function(){return this.index},getNumber:function(){return this.num},prev:function(){(this.options.continuous||this.index)&&this.slide(this.index-1)},next:function(){(this.options.continuous||this.index<this.num-1)&&this.slide(this.index+1)},play:function(t){var i=this,e=this.index+("rtl"===this.options.slideshowDirection?-1:1);window.clearTimeout(this.timeout),this.interval=t||this.options.slideshowInterval,1<this.elements[this.index]&&(this.timeout=this.setTimeout(!this.requestAnimationFrame&&this.slide||function(t,e){i.animationFrameId=i.requestAnimationFrame.call(window,function(){i.slide(t,e)})},[e,this.options.slideshowTransitionDuration],this.interval)),this.container.addClass(this.options.playingClass),this.slidesContainer[0].setAttribute("aria-live","off"),this.playPauseElement.length&&this.playPauseElement[0].setAttribute("aria-pressed","true")},pause:function(){window.clearTimeout(this.timeout),this.interval=null,this.cancelAnimationFrame&&(this.cancelAnimationFrame.call(window,this.animationFrameId),this.animationFrameId=null),this.container.removeClass(this.options.playingClass),this.slidesContainer[0].setAttribute("aria-live","polite"),this.playPauseElement.length&&this.playPauseElement[0].setAttribute("aria-pressed","false")},add:function(t){var e;for(t.concat||(t=Array.prototype.slice.call(t)),this.list.concat||(this.list=Array.prototype.slice.call(this.list)),this.list=this.list.concat(t),this.num=this.list.length,2<this.num&&null===this.options.continuous&&(this.options.continuous=!0,this.container.removeClass(this.options.leftEdgeClass)),this.container.removeClass(this.options.rightEdgeClass).removeClass(this.options.singleClass),e=this.num-t.length;e<this.num;e+=1)this.addSlide(e),this.positionSlide(e);this.positions.length=this.num,this.initSlides(!0)},resetSlides:function(){this.slidesContainer.empty(),this.unloadAllSlides(),this.slides=[]},handleClose:function(){var t=this.options;this.destroyEventListeners(),this.pause(),this.container[0].style.display="none",this.container.removeClass(t.displayClass).removeClass(t.singleClass).removeClass(t.leftEdgeClass).removeClass(t.rightEdgeClass),t.hidePageScrollbars&&(document.body.style.overflow=this.bodyOverflowStyle),this.options.clearSlides&&this.resetSlides(),this.options.onclosed&&this.options.onclosed.call(this)},close:function(){var e=this;this.options.onclose&&this.options.onclose.call(this),this.support.transition&&this.options.displayTransition?(this.container.on(this.support.transition.end,function i(t){t.target===e.container[0]&&(e.container.off(e.support.transition.end,i),e.handleClose())}),this.container.removeClass(this.options.displayClass)):this.handleClose()},circle:function(t){return(this.num+t%this.num)%this.num},move:function(t,e,i){this.translateX(t,e,i),this.positions[t]=e},translate:function(t,e,i,s){var n,o,a;this.slides[t]&&(n=this.slides[t].style,o=this.support.transition,a=this.support.transform,n[o.name+"Duration"]=s+"ms",n[a.name]="translate("+e+"px, "+i+"px)"+(a.translateZ?" translateZ(0)":""))},translateX:function(t,e,i){this.translate(t,e,0,i)},translateY:function(t,e,i){this.translate(t,0,e,i)},animate:function(e,i,s){var n,o,a;s?(n=this,o=(new Date).getTime(),a=window.setInterval(function(){var t=(new Date).getTime()-o;if(s<t)return n.slidesContainer[0].style.left=i+"px",n.ontransitionend(),void window.clearInterval(a);n.slidesContainer[0].style.left=(i-e)*(Math.floor(t/s*100)/100)+e+"px"},4)):this.slidesContainer[0].style.left=i+"px"},preventDefault:function(t){t.preventDefault?t.preventDefault():t.returnValue=!1},stopPropagation:function(t){t.stopPropagation?t.stopPropagation():t.cancelBubble=!0},onresize:function(){this.initSlides(!0)},onhashchange:function(){this.options.closeOnHashChange&&this.close()},onmousedown:function(t){t.which&&1===t.which&&"VIDEO"!==t.target.nodeName&&"AUDIO"!==t.target.nodeName&&(t.preventDefault(),(t.originalEvent||t).touches=[{pageX:t.pageX,pageY:t.pageY}],this.ontouchstart(t))},onmousemove:function(t){this.touchStart&&((t.originalEvent||t).touches=[{pageX:t.pageX,pageY:t.pageY}],this.ontouchmove(t))},onmouseup:function(t){this.touchStart&&(this.ontouchend(t),delete this.touchStart)},onmouseout:function(t){var e,i;this.touchStart&&(e=t.target,(i=t.relatedTarget)&&(i===e||f.contains(e,i))||this.onmouseup(t))},ontouchstart:function(t){this.options.stopTouchEventsPropagation&&this.stopPropagation(t);var e=(t.originalEvent||t).touches[0];this.touchStart={x:e.pageX,y:e.pageY,time:Date.now()},this.isScrolling=undefined,this.touchDelta={}},ontouchmove:function(t){this.options.stopTouchEventsPropagation&&this.stopPropagation(t);var e,i,s=(t.originalEvent||t).touches,n=s[0],o=(t.originalEvent||t).scale,a=this.index;if(!(1<s.length||o&&1!==o))if(this.options.disableScroll&&t.preventDefault(),this.touchDelta={x:n.pageX-this.touchStart.x,y:n.pageY-this.touchStart.y},e=this.touchDelta.x,this.isScrolling===undefined&&(this.isScrolling=this.isScrolling||Math.abs(e)<Math.abs(this.touchDelta.y)),this.isScrolling)this.options.carousel||this.translateY(a,this.touchDelta.y+this.positions[a],0);else for(t.preventDefault(),window.clearTimeout(this.timeout),this.options.continuous?i=[this.circle(a+1),a,this.circle(a-1)]:(this.touchDelta.x=e/=!a&&0<e||a===this.num-1&&e<0?Math.abs(e)/this.slideWidth+1:1,i=[a],a&&i.push(a-1),a<this.num-1&&i.unshift(a+1));i.length;)a=i.pop(),this.translateX(a,e+this.positions[a],0)},ontouchend:function(t){this.options.stopTouchEventsPropagation&&this.stopPropagation(t);var e,i,s,n,o,a=this.index,l=Math.abs(this.touchDelta.x),r=this.slideWidth,h=Math.ceil(this.options.transitionDuration*(1-l/r)/2),d=20<l,c=!a&&0<this.touchDelta.x||a===this.num-1&&this.touchDelta.x<0,u=!d&&this.options.closeOnSwipeUpOrDown&&20<Math.abs(this.touchDelta.y);this.options.continuous&&(c=!1),e=this.touchDelta.x<0?-1:1,this.isScrolling?u?this.close():this.translateY(a,0,h):d&&!c?(i=a+e,s=a-e,n=r*e,o=-r*e,this.options.continuous?(this.move(this.circle(i),n,0),this.move(this.circle(a-2*e),o,0)):0<=i&&i<this.num&&this.move(i,n,0),this.move(a,this.positions[a]+n,h),this.move(this.circle(s),this.positions[this.circle(s)]+n,h),a=this.circle(s),this.onslide(a)):this.options.continuous?(this.move(this.circle(a-1),-r,h),this.move(a,0,h),this.move(this.circle(a+1),r,h)):(a&&this.move(a-1,-r,h),this.move(a,0,h),a<this.num-1&&this.move(a+1,r,h))},ontouchcancel:function(t){this.touchStart&&(this.ontouchend(t),delete this.touchStart)},ontransitionend:function(t){var e=this.slides[this.index];t&&e!==t.target||(this.interval&&this.play(),this.setTimeout(this.options.onslideend,[this.index,e]))},oncomplete:function(t){var e,i=t.target||t.srcElement,s=i&&i.parentNode;i&&s&&(e=this.getNodeIndex(s),f(s).removeClass(this.options.slideLoadingClass),"error"===t.type?(f(s).addClass(this.options.slideErrorClass),this.elements[e]=3):this.elements[e]=2,i.clientHeight>this.container[0].clientHeight&&(i.style.maxHeight=this.container[0].clientHeight),this.interval&&this.slides[this.index]===s&&this.play(),this.setTimeout(this.options.onslidecomplete,[e,s]))},onload:function(t){this.oncomplete(t)},onerror:function(t){this.oncomplete(t)},onkeydown:function(t){switch(t.which||t.keyCode){case 13:this.options.toggleControlsOnEnter&&(this.preventDefault(t),this.toggleControls());break;case 27:this.options.closeOnEscape&&(this.close(),t.stopImmediatePropagation());break;case 32:this.options.toggleSlideshowOnSpace&&(this.preventDefault(t),this.toggleSlideshow());break;case 37:this.options.enableKeyboardNavigation&&(this.preventDefault(t),this.prev());break;case 39:this.options.enableKeyboardNavigation&&(this.preventDefault(t),this.next())}},handleClick:function(t){var e=this.options,i=t.target||t.srcElement,s=i.parentNode;function n(t){return f(i).hasClass(t)||f(s).hasClass(t)}n(e.toggleClass)?(this.preventDefault(t),this.toggleControls()):n(e.prevClass)?(this.preventDefault(t),this.prev()):n(e.nextClass)?(this.preventDefault(t),this.next()):n(e.closeClass)?(this.preventDefault(t),this.close()):n(e.playPauseClass)?(this.preventDefault(t),this.toggleSlideshow()):s===this.slidesContainer[0]?e.closeOnSlideClick?(this.preventDefault(t),this.close()):e.toggleControlsOnSlideClick&&(this.preventDefault(t),this.toggleControls()):s.parentNode&&s.parentNode===this.slidesContainer[0]&&e.toggleControlsOnSlideClick&&(this.preventDefault(t),this.toggleControls())},onclick:function(t){if(!(this.options.emulateTouchEvents&&this.touchDelta&&(20<Math.abs(this.touchDelta.x)||20<Math.abs(this.touchDelta.y))))return this.handleClick(t);delete this.touchDelta},updateEdgeClasses:function(t){t?this.container.removeClass(this.options.leftEdgeClass):this.container.addClass(this.options.leftEdgeClass),t===this.num-1?this.container.addClass(this.options.rightEdgeClass):this.container.removeClass(this.options.rightEdgeClass)},updateActiveSlide:function(t,e){for(var i,s,n=this.slides,o=this.options,a=[{index:e,method:"addClass",hidden:!1},{index:t,method:"removeClass",hidden:!0}];a.length;)i=a.pop(),f(n[i.index])[i.method](o.slideActiveClass),s=this.circle(i.index-1),(o.continuous||s<i.index)&&f(n[s])[i.method](o.slidePrevClass),s=this.circle(i.index+1),(o.continuous||s>i.index)&&f(n[s])[i.method](o.slideNextClass);this.slides[t].setAttribute("aria-hidden","true"),this.slides[e].removeAttribute("aria-hidden")},handleSlide:function(t,e){this.options.continuous||this.updateEdgeClasses(e),this.updateActiveSlide(t,e),this.loadElements(e),this.options.unloadElements&&this.unloadElements(t,e),this.setTitle(e)},onslide:function(t){this.handleSlide(this.index,t),this.index=t,this.setTimeout(this.options.onslide,[t,this.slides[t]])},setTitle:function(t){var e=this.slides[t].firstChild,i=e.title||e.alt,s=this.titleElement;s.length&&(this.titleElement.empty(),i&&s[0].appendChild(document.createTextNode(i)))},setTimeout:function(t,e,i){var s=this;return t&&window.setTimeout(function(){t.apply(s,e||[])},i||0)},imageFactory:function(t,e){var i,s,n,o,a,l,r,h,d=this.options,c=this,u=t,p=this.imagePrototype.cloneNode(!1);if("string"!=typeof u&&(u=this.getItemProperty(t,d.urlProperty),n=this.support.picture&&this.support.source&&this.getItemProperty(t,d.sourcesProperty),o=this.getItemProperty(t,d.srcsetProperty),a=this.getItemProperty(t,d.sizesProperty),l=this.getItemProperty(t,d.titleProperty),r=this.getItemProperty(t,d.altTextProperty)||l),p.draggable=!1,l&&(p.title=l),r&&(p.alt=r),f(p).on("load error",function m(t){if(!s){if(!(t={type:t.type,target:i||p}).target.parentNode)return c.setTimeout(m,[t]);s=!0,f(p).off("load error",m),e(t)}}),n&&n.length){for(i=this.picturePrototype.cloneNode(!1),h=0;h<n.length;h+=1)i.appendChild(f.extend(this.sourcePrototype.cloneNode(!1),n[h]));i.appendChild(p),f(i).addClass(d.toggleClass)}return o&&(a&&(p.sizes=a),p.srcset=o),p.src=u,i||p},createElement:function(t,e){var i=t&&this.getItemProperty(t,this.options.typeProperty),s=i&&this[i.split("/")[0]+"Factory"]||this.imageFactory,n=t&&s.call(this,t,e);return n||(n=this.elementPrototype.cloneNode(!1),this.setTimeout(e,[{type:"error",target:n}])),f(n).addClass(this.options.slideContentClass),n},iteratePreloadRange:function(t,e){for(var i=this.num,s=this.options,n=Math.min(i,2*s.preloadRange+1),o=t,a=0;a<n;a+=1){if((o+=a*(a%2==0?-1:1))<0||i<=o){if(!s.continuous)continue;o=this.circle(o)}e.call(this,o)}},loadElement:function(t){this.elements[t]||(this.slides[t].firstChild?this.elements[t]=f(this.slides[t]).hasClass(this.options.slideErrorClass)?3:2:(this.elements[t]=1,f(this.slides[t]).addClass(this.options.slideLoadingClass),this.slides[t].appendChild(this.createElement(this.list[t],this.proxyListener))))},loadElements:function(t){this.iteratePreloadRange(t,this.loadElement)},unloadElements:function(t,i){var s=this.options.preloadRange;this.iteratePreloadRange(t,function(t){var e=Math.abs(t-i);s<e&&e+s<this.num&&(this.unloadSlide(t),delete this.elements[t])})},addSlide:function(t){var e=this.slidePrototype.cloneNode(!1);e.setAttribute("data-index",t),e.setAttribute("aria-hidden","true"),this.slidesContainer[0].appendChild(e),this.slides.push(e)},positionSlide:function(t){var e=this.slides[t];e.style.width=this.slideWidth+"px",this.support.transform&&(e.style.left=t*-this.slideWidth+"px",this.move(t,this.index>t?-this.slideWidth:this.index<t?this.slideWidth:0,0))},initSlides:function(t){var e,i;for(t||(this.positions=[],this.positions.length=this.num,this.elements={},this.picturePrototype=this.support.picture&&document.createElement("picture"),this.sourcePrototype=this.support.source&&document.createElement("source"),this.imagePrototype=document.createElement("img"),this.elementPrototype=document.createElement("div"),this.slidePrototype=this.elementPrototype.cloneNode(!1),f(this.slidePrototype).addClass(this.options.slideClass),this.slides=this.slidesContainer[0].children,e=this.options.clearSlides||this.slides.length!==this.num),this.slideWidth=this.container[0].clientWidth,this.slideHeight=this.container[0].clientHeight,this.slidesContainer[0].style.width=this.num*this.slideWidth+"px",e&&this.resetSlides(),i=0;i<this.num;i+=1)e&&this.addSlide(i),this.positionSlide(i);this.options.continuous&&this.support.transform&&(this.move(this.circle(this.index-1),-this.slideWidth,0),this.move(this.circle(this.index+1),this.slideWidth,0)),this.support.transform||(this.slidesContainer[0].style.left=this.index*-this.slideWidth+"px")},unloadSlide:function(t){var e=this.slides[t],i=e.firstChild;null!==i&&e.removeChild(i)},unloadAllSlides:function(){for(var t=0,e=this.slides.length;t<e;t++)this.unloadSlide(t)},toggleControls:function(){var t=this.options.controlsClass;this.container.hasClass(t)?this.container.removeClass(t):this.container.addClass(t)},toggleSlideshow:function(){this.interval?this.pause():this.play()},getNodeIndex:function(t){return parseInt(t.getAttribute("data-index"),10)},getNestedProperty:function(a,t){return t.replace(/\[(?:'([^']+)'|"([^"]+)"|(\d+))\]|(?:(?:^|\.)([^\.\[]+))/g,function(t,e,i,s,n){var o=n||e||i||s&&parseInt(s,10);t&&a&&(a=a[o])}),a},getDataProperty:function(t,e){var i,s;if(t.dataset?(i=e.replace(/-([a-z])/g,function(t,e){return e.toUpperCase()}),s=t.dataset[i]):t.getAttribute&&(s=t.getAttribute("data-"+e.replace(/([A-Z])/g,"-$1").toLowerCase())),"string"==typeof s){if(/^(true|false|null|-?\d+(\.\d+)?|\{[\s\S]*\}|\[[\s\S]*\])$/.test(s))try{return f.parseJSON(s)}catch(n){}return s}},getItemProperty:function(t,e){var i=this.getDataProperty(t,e);return i===undefined&&(i=t[e]),i===undefined&&(i=this.getNestedProperty(t,e)),i},initStartIndex:function(){var t,e=this.options.index,i=this.options.urlProperty;if(e&&"number"!=typeof e)for(t=0;t<this.num;t+=1)if(this.list[t]===e||this.getItemProperty(this.list[t],i)===this.getItemProperty(e,i)){e=t;break}this.index=this.circle(parseInt(e,10)||0)},initEventListeners:function(){var i=this,t=this.slidesContainer;function e(t){var e=i.support.transition&&i.support.transition.end===t.type?"transitionend":t.type;i["on"+e](t)}f(window).on("resize",e),f(window).on("hashchange",e),f(document.body).on("keydown",e),this.container.on("click",e),this.support.touch?t.on("touchstart touchmove touchend touchcancel",e):this.options.emulateTouchEvents&&this.support.transition&&t.on("mousedown mousemove mouseup mouseout",e),this.support.transition&&t.on(this.support.transition.end,e),this.proxyListener=e},destroyEventListeners:function(){var t=this.slidesContainer,e=this.proxyListener;f(window).off("resize",e),f(document.body).off("keydown",e),this.container.off("click",e),this.support.touch?t.off("touchstart touchmove touchend touchcancel",e):this.options.emulateTouchEvents&&this.support.transition&&t.off("mousedown mousemove mouseup mouseout",e),this.support.transition&&t.off(this.support.transition.end,e)},handleOpen:function(){this.options.onopened&&this.options.onopened.call(this)},initWidget:function(){var e=this;return this.container=f(this.options.container),this.container.length?(this.slidesContainer=this.container.find(this.options.slidesContainer).first(),this.slidesContainer.length?(this.titleElement=this.container.find(this.options.titleElement).first(),this.playPauseElement=this.container.find("."+this.options.playPauseClass).first(),1===this.num&&this.container.addClass(this.options.singleClass),this.support.svgasimg&&this.container.addClass(this.options.svgasimgClass),this.support.smil&&this.container.addClass(this.options.smilClass),this.options.onopen&&this.options.onopen.call(this),this.support.transition&&this.options.displayTransition?this.container.on(this.support.transition.end,function i(t){t.target===e.container[0]&&(e.container.off(e.support.transition.end,i),e.handleOpen())}):this.handleOpen(),this.options.hidePageScrollbars&&(this.bodyOverflowStyle=document.body.style.overflow,document.body.style.overflow="hidden"),this.container[0].style.display="block",this.initSlides(),void this.container.addClass(this.options.displayClass)):(this.console.log("blueimp Gallery: Slides container not found.",this.options.slidesContainer),!1)):(this.console.log("blueimp Gallery: Widget container not found.",this.options.container),!1)},initOptions:function(t){this.options=f.extend({},this.options),(t&&t.carousel||this.options.carousel&&(!t||!1!==t.carousel))&&f.extend(this.options,this.carouselOptions),f.extend(this.options,t),this.num<3&&(this.options.continuous=!!this.options.continuous&&null),this.support.transition||(this.options.emulateTouchEvents=!1),this.options.event&&this.preventDefault(this.options.event)}}),i}),function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper","./blueimp-gallery"],t):t(window.blueimp.helper||window.jQuery,window.blueimp.Gallery)}(function(t,e){"use strict";var i=e.prototype;t.extend(i.options,{fullscreen:!1});var s=i.initialize,n=i.close;return t.extend(i,{getFullScreenElement:function(){return document.fullscreenElement||document.webkitFullscreenElement||document.mozFullScreenElement||document.msFullscreenElement},requestFullScreen:function(t){t.requestFullscreen?t.requestFullscreen():t.webkitRequestFullscreen?t.webkitRequestFullscreen():t.mozRequestFullScreen?t.mozRequestFullScreen():t.msRequestFullscreen&&t.msRequestFullscreen()},exitFullScreen:function(){document.exitFullscreen?document.exitFullscreen():document.webkitCancelFullScreen?document.webkitCancelFullScreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.msExitFullscreen&&document.msExitFullscreen()},initialize:function(){s.call(this),this.options.fullscreen&&!this.getFullScreenElement()&&this.requestFullScreen(this.container[0])},close:function(){this.getFullScreenElement()===this.container[0]&&this.exitFullScreen(),n.call(this)}}),e}),function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper","./blueimp-gallery"],t):t(window.blueimp.helper||window.jQuery,window.blueimp.Gallery)}(function(a,t){"use strict";var e=t.prototype;a.extend(e.options,{indicatorContainer:"ol",activeIndicatorClass:"active",thumbnailProperty:"thumbnail",thumbnailIndicators:!0});var i=e.initSlides,s=e.addSlide,n=e.resetSlides,o=e.handleClick,l=e.handleSlide,r=e.handleClose;return a.extend(e,{createIndicator:function(t){var e,i,s=this.indicatorPrototype.cloneNode(!1),n=this.getItemProperty(t,this.options.titleProperty),o=this.options.thumbnailProperty;return this.options.thumbnailIndicators&&(o&&(e=this.getItemProperty(t,o)),e===undefined&&(i=t.getElementsByTagName&&a(t).find("img")[0])&&(e=i.src),e&&(s.style.backgroundImage='url("'+e+'")')),n&&(s.title=n),s.setAttribute("role","link"),s},addIndicator:function(t){var e;this.indicatorContainer.length&&((e=this.createIndicator(this.list[t])).setAttribute("data-index",t),this.indicatorContainer[0].appendChild(e),this.indicators.push(e))},setActiveIndicator:function(t){this.indicators&&(this.activeIndicator&&this.activeIndicator.removeClass(this.options.activeIndicatorClass),this.activeIndicator=a(this.indicators[t]),this.activeIndicator.addClass(this.options.activeIndicatorClass))},initSlides:function(t){t||(this.indicatorContainer=this.container.find(this.options.indicatorContainer),this.indicatorContainer.length&&(this.indicatorPrototype=document.createElement("li"),this.indicators=this.indicatorContainer[0].children)),i.call(this,t)},addSlide:function(t){s.call(this,t),this.addIndicator(t)},resetSlides:function(){n.call(this),this.indicatorContainer.empty(),this.indicators=[]},handleClick:function(t){var e=t.target||t.srcElement,i=e.parentNode;if(i===this.indicatorContainer[0])this.preventDefault(t),this.slide(this.getNodeIndex(e));else{if(i.parentNode!==this.indicatorContainer[0])return o.call(this,t);this.preventDefault(t),this.slide(this.getNodeIndex(i))}},handleSlide:function(t,e){l.call(this,t,e),this.setActiveIndicator(e)},handleClose:function(){this.activeIndicator&&this.activeIndicator.removeClass(this.options.activeIndicatorClass),r.call(this)}}),t}),function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper","./blueimp-gallery"],t):t(window.blueimp.helper||window.jQuery,window.blueimp.Gallery)}(function(C,t){"use strict";var e=t.prototype;C.extend(e.options,{videoContentClass:"video-content",videoLoadingClass:"video-loading",videoPlayingClass:"video-playing",videoIframeClass:"video-iframe",videoCoverClass:"video-cover",videoPlayClass:"video-play",videoPlaysInline:!0,videoPreloadProperty:"preload",videoPosterProperty:"poster"});var i=e.handleSlide;return C.extend(e,{handleSlide:function(t,e){i.call(this,t,e),this.setTimeout(function(){this.activeVideo&&this.activeVideo.pause()})},videoFactory:function(t,e,i){var s,n,o,a=this,l=this.options,r=this.elementPrototype.cloneNode(!1),h=C(r),d=[{type:"error",target:r}],c=i||document.createElement("video"),u=this.elementPrototype.cloneNode(!1),p=document.createElement("a"),m=this.getItemProperty(t,l.urlProperty),f=this.getItemProperty(t,l.sourcesProperty),y=this.getItemProperty(t,l.titleProperty),g=this.getItemProperty(t,l.videoPosterProperty),v=[p];if(h.addClass(l.videoContentClass),C(p).addClass(l.videoPlayClass),C(u).addClass(l.videoCoverClass).hasClass(l.toggleClass)||v.push(u),u.draggable=!1,y&&(r.title=y,p.setAttribute("aria-label",y)),g&&(u.style.backgroundImage='url("'+g+'")'),c.setAttribute?l.videoPlaysInline&&c.setAttribute("playsinline",""):h.addClass(l.videoIframeClass),c.preload=this.getItemProperty(t,l.videoPreloadProperty)||"none",this.support.source&&f)for(o=0;o<f.length;o+=1)c.appendChild(C.extend(this.sourcePrototype.cloneNode(!1),f[o]));return m&&(c.src=m),p.href=m||f&&f.length&&f[0].src,c.play&&c.pause&&((i||C(c)).on("error",function(){a.setTimeout(e,d)}).on("pause",function(){c.seeking||(n=!1,h.removeClass(a.options.videoLoadingClass).removeClass(a.options.videoPlayingClass),s&&a.container.addClass(a.options.controlsClass),c.controls=!1,c===a.activeVideo&&delete a.activeVideo,a.interval&&a.play())}).on("playing",function(){n=!1,u.removeAttribute("style"),h.removeClass(a.options.videoLoadingClass).addClass(a.options.videoPlayingClass)}).on("play",function(){window.clearTimeout(a.timeout),n=!0,h.addClass(a.options.videoLoadingClass),a.container.hasClass(a.options.controlsClass)?(s=!0,a.container.removeClass(a.options.controlsClass)):s=!1,c.controls=!0,a.activeVideo=c}),C(v).on("click",function(t){a.preventDefault(t),a.activeVideo=c,n?c.pause():c.play()}),r.appendChild(i&&i.element||c)),r.appendChild(u),r.appendChild(p),this.setTimeout(e,[{type:"load",target:r}]),r}}),t}),function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper","./blueimp-gallery-video"],t):t(window.blueimp.helper||window.jQuery,window.blueimp.Gallery)}(function(l,t){"use strict";if(!window.postMessage)return t;var e=t.prototype;l.extend(e.options,{vimeoVideoIdProperty:"vimeo",vimeoPlayerUrl:"//player.vimeo.com/video/VIDEO_ID?api=1&player_id=PLAYER_ID",vimeoPlayerIdPrefix:"vimeo-player-",vimeoClickToPlay:!1});var n=e.textFactory||e.imageFactory,o=function(t,e,i,s){this.url=t,this.videoId=e,this.playerId=i,this.clickToPlay=s,this.element=document.createElement("div"),this.listeners={}},a=0;return l.extend(o.prototype,{on:function(t,e){return this.listeners[t]=e,this},loadAPI:function(){var t,e,i=this,s="//f.vimeocdn.com/js/froogaloop2.min.js",n=document.getElementsByTagName("script"),o=n.length;function a(){!e&&i.playOnReady&&i.play(),e=!0}for(;o;)if(n[--o].src===s){t=n[o];break}t||((t=document.createElement("script")).src=s),l(t).on("load",a),n[0].parentNode.insertBefore(t,n[0]),/loaded|complete/.test(t.readyState)&&a()},onReady:function(){var t=this;this.ready=!0,this.player.addEvent("play",function(){t.hasPlayed=!0,t.onPlaying()}),this.player.addEvent("pause",function(){t.onPause()}),this.player.addEvent("finish",function(){t.onPause()}),this.playOnReady&&this.play()},onPlaying:function(){this.playStatus<2&&(this.listeners.playing(),this.playStatus=2)},onPause:function(){this.listeners.pause(),delete this.playStatus},insertIframe:function(){var t=document.createElement("iframe");t.src=this.url.replace("VIDEO_ID",this.videoId).replace("PLAYER_ID",this.playerId),t.id=this.playerId,this.element.parentNode.replaceChild(t,this.element),this.element=t},play:function(){var t=this;this.playStatus||(this.listeners.play(),this.playStatus=1),this.ready?!this.hasPlayed&&(this.clickToPlay||window.navigator&&/iP(hone|od|ad)/.test(window.navigator.platform))?this.onPlaying():this.player.api("play"):(this.playOnReady=!0,window.$f?this.player||(this.insertIframe(),this.player=$f(this.element),this.player.addEvent("ready",function(){t.onReady()})):this.loadAPI())},pause:function(){this.ready?this.player.api("pause"):this.playStatus&&(delete this.playOnReady,this.listeners.pause(),delete this.playStatus)}}),l.extend(e,{VimeoPlayer:o,textFactory:function(t,e){var i=this.options,s=this.getItemProperty(t,i.vimeoVideoIdProperty);return s?(this.getItemProperty(t,i.urlProperty)===undefined&&(t[i.urlProperty]="//vimeo.com/"+s),a+=1,this.videoFactory(t,e,new o(i.vimeoPlayerUrl,s,i.vimeoPlayerIdPrefix+a,i.vimeoClickToPlay))):n.call(this,t,e)}}),t}),function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper","./blueimp-gallery-video"],t):t(window.blueimp.helper||window.jQuery,window.blueimp.Gallery)}(function(t,e){"use strict";if(!window.postMessage)return e;var i=e.prototype;t.extend(i.options,{youTubeVideoIdProperty:"youtube",youTubePlayerVars:{wmode:"transparent"},youTubeClickToPlay:!1});var n=i.textFactory||i.imageFactory,o=function(t,e,i){this.videoId=t,this.playerVars=e,this.clickToPlay=i,this.element=document.createElement("div"),this.listeners={}};return t.extend(o.prototype,{on:function(t,e){return this.listeners[t]=e,this},loadAPI:function(){var t,e=this,i=window.onYouTubeIframeAPIReady,s="//www.youtube.com/iframe_api",n=document.getElementsByTagName("script"),o=n.length;for(window.onYouTubeIframeAPIReady=function(){i&&i.apply(this),e.playOnReady&&e.play()};o;)if(n[--o].src===s)return;(t=document.createElement("script")).src=s,n[0].parentNode.insertBefore(t,n[0])},onReady:function(){this.ready=!0,this.playOnReady&&this.play()},onPlaying:function(){this.playStatus<2&&(this.listeners.playing(),this.playStatus=2)},onPause:function(){this.listeners.pause(),delete this.playStatus},onStateChange:function(t){switch(window.clearTimeout(this.pauseTimeout),t.data){case YT.PlayerState.PLAYING:this.hasPlayed=!0,this.onPlaying();break;case YT.PlayerState.UNSTARTED:case YT.PlayerState.PAUSED:this.pauseTimeout=i.setTimeout.call(this,this.onPause,null,500);break;case YT.PlayerState.ENDED:this.onPause()}},onError:function(t){this.listeners.error(t)},play:function(){var e=this;this.playStatus||(this.listeners.play(),this.playStatus=1),this.ready?!this.hasPlayed&&(this.clickToPlay||window.navigator&&/iP(hone|od|ad)/.test(window.navigator.platform))?this.onPlaying():this.player.playVideo():(this.playOnReady=!0,window.YT&&YT.Player?this.player||(this.player=new YT.Player(this.element,{videoId:this.videoId,playerVars:this.playerVars,events:{onReady:function(){e.onReady()},onStateChange:function(t){e.onStateChange(t)},onError:function(t){e.onError(t)}}})):this.loadAPI())},pause:function(){this.ready?this.player.pauseVideo():this.playStatus&&(delete this.playOnReady,this.listeners.pause(),delete this.playStatus)}}),t.extend(i,{YouTubePlayer:o,textFactory:function(t,e){var i=this.options,s=this.getItemProperty(t,i.youTubeVideoIdProperty);return s?(this.getItemProperty(t,i.urlProperty)===undefined&&(t[i.urlProperty]="//www.youtube.com/watch?v="+s),this.getItemProperty(t,i.videoPosterProperty)===undefined&&(t[i.videoPosterProperty]="//img.youtube.com/vi/"+s+"/maxresdefault.jpg"),this.videoFactory(t,e,new o(s,i.youTubePlayerVars,i.youTubeClickToPlay))):n.call(this,t,e)}}),e});
//# sourceMappingURL=blueimp-gallery.min.js.map

@@ -81,3 +81,3 @@ /*

Helper.parseJSON = function (string) {
return window.JSON && JSON.parse(string)
return JSON.parse(string)
}

@@ -101,6 +101,4 @@

hasClass: function (className) {
if (!this[0]) {
return false
}
return new RegExp('(^|\\s+)' + className + '(\\s+|$)').test(
if (!this[0]) return false
return new RegExp('(?:^|\\s+)' + className + '(?:\\s+|$)').test(
this[0].className

@@ -112,3 +110,5 @@ )

var i = this.length
var classNames
var element
var j
while (i) {

@@ -119,8 +119,11 @@ i -= 1

element.className = className
return this
continue
}
if (this.hasClass(className)) {
return this
if (!classNames) classNames = className.split(/\s+/)
for (j = 0; j < classNames.length; j += 1) {
if (this.hasClass(classNames[j])) {
continue
}
element.className += ' ' + classNames[j]
}
element.className += ' ' + className
}

@@ -131,3 +134,11 @@ return this

removeClass: function (className) {
var regexp = new RegExp('(^|\\s+)' + className + '(\\s+|$)')
// Match any of the given class names
var regexp = new RegExp('^(?:' + className.split(/\s+/).join('|') + ')$')
// Match any class names and their trailing whitespace
var matcher = /(\S+)(?:\s+|$)/g
var replacer = function (match, className) {
// Replace class names that match the given ones
return regexp.test(className) ? '' : match
}
var trimEnd = /\s+$/
var i = this.length

@@ -138,3 +149,5 @@ var element

element = this[i]
element.className = element.className.replace(regexp, ' ')
element.className = element.className
.replace(matcher, replacer)
.replace(trimEnd, '')
}

@@ -141,0 +154,0 @@ return this

@@ -1,2 +0,2 @@

!function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper"],t):(window.blueimp=window.blueimp||{},window.blueimp.Gallery=t(window.blueimp.helper||window.jQuery))}(function(c){"use strict";function i(t,e){return document.body.style.maxHeight===undefined?null:this&&this.options===i.prototype.options?void(t&&t.length?(this.list=t,this.num=t.length,this.initOptions(e),this.initialize()):this.console.log("blueimp Gallery: No or empty list provided as first argument.",t)):new i(t,e)}return c.extend(i.prototype,{options:{container:"#blueimp-gallery",slidesContainer:"div",titleElement:"h3",displayClass:"blueimp-gallery-display",controlsClass:"blueimp-gallery-controls",singleClass:"blueimp-gallery-single",leftEdgeClass:"blueimp-gallery-left",rightEdgeClass:"blueimp-gallery-right",playingClass:"blueimp-gallery-playing",slideClass:"slide",slideLoadingClass:"slide-loading",slideErrorClass:"slide-error",slideContentClass:"slide-content",toggleClass:"toggle",prevClass:"prev",nextClass:"next",closeClass:"close",playPauseClass:"play-pause",typeProperty:"type",titleProperty:"title",altTextProperty:"alt",urlProperty:"href",srcsetProperty:"urlset",displayTransition:!0,clearSlides:!0,stretchImages:!1,toggleControlsOnReturn:!0,toggleControlsOnSlideClick:!0,toggleSlideshowOnSpace:!0,enableKeyboardNavigation:!0,closeOnEscape:!0,closeOnSlideClick:!0,closeOnSwipeUpOrDown:!0,closeOnHashChange:!0,emulateTouchEvents:!0,stopTouchEventsPropagation:!1,hidePageScrollbars:!0,disableScroll:!0,carousel:!1,continuous:!0,unloadElements:!0,startSlideshow:!1,slideshowInterval:5e3,slideshowDirection:"ltr",index:0,preloadRange:2,transitionDuration:300,slideshowTransitionDuration:500,event:undefined,onopen:undefined,onopened:undefined,onslide:undefined,onslideend:undefined,onslidecomplete:undefined,onclose:undefined,onclosed:undefined},carouselOptions:{hidePageScrollbars:!1,toggleControlsOnReturn:!1,toggleSlideshowOnSpace:!1,enableKeyboardNavigation:!1,closeOnEscape:!1,closeOnSlideClick:!1,closeOnSwipeUpOrDown:!1,disableScroll:!1,startSlideshow:!0},console:window.console&&"function"==typeof window.console.log?window.console:{log:function(){}},support:function(s){var t,n={touch:window.ontouchstart!==undefined||window.DocumentTouch&&document instanceof DocumentTouch},e={webkitTransition:{end:"webkitTransitionEnd",prefix:"-webkit-"},MozTransition:{end:"transitionend",prefix:"-moz-"},OTransition:{end:"otransitionend",prefix:"-o-"},transition:{end:"transitionend",prefix:""}};for(t in e)if(Object.prototype.hasOwnProperty.call(e,t)&&s.style[t]!==undefined){n.transition=e[t],n.transition.name=t;break}function i(){var t,e,i=n.transition;document.body.appendChild(s),i&&(t=i.name.slice(0,-9)+"ransform",s.style[t]!==undefined&&(s.style[t]="translateZ(0)",e=window.getComputedStyle(s).getPropertyValue(i.prefix+"transform"),n.transform={prefix:i.prefix,name:t,translate:!0,translateZ:!!e&&"none"!==e})),s.style.backgroundSize!==undefined&&(n.backgroundSize={},s.style.backgroundSize="contain",n.backgroundSize.contain="contain"===window.getComputedStyle(s).getPropertyValue("background-size"),s.style.backgroundSize="cover",n.backgroundSize.cover="cover"===window.getComputedStyle(s).getPropertyValue("background-size")),document.body.removeChild(s)}return document.body?i():c(document).on("DOMContentLoaded",i),n}(document.createElement("div")),requestAnimationFrame:window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame,cancelAnimationFrame:window.cancelAnimationFrame||window.webkitCancelRequestAnimationFrame||window.webkitCancelAnimationFrame||window.mozCancelAnimationFrame,initialize:function(){if(this.initStartIndex(),!1===this.initWidget())return!1;this.initEventListeners(),this.onslide(this.index),this.ontransitionend(),this.options.startSlideshow&&this.play()},slide:function(t,e){window.clearTimeout(this.timeout);var i,s,n,o=this.index;if(o!==t&&1!==this.num){if(e=e||this.options.transitionDuration,this.support.transform){for(this.options.continuous||(t=this.circle(t)),i=Math.abs(o-t)/(o-t),this.options.continuous&&(s=i,(i=-this.positions[this.circle(t)]/this.slideWidth)!==s&&(t=-i*this.num+t)),n=Math.abs(o-t)-1;n;)--n,this.move(this.circle((o<t?t:o)-n-1),this.slideWidth*i,0);t=this.circle(t),this.move(o,this.slideWidth*i,e),this.move(t,0,e),this.options.continuous&&this.move(this.circle(t-i),-this.slideWidth*i,0)}else t=this.circle(t),this.animate(o*-this.slideWidth,t*-this.slideWidth,e);this.onslide(t)}},getIndex:function(){return this.index},getNumber:function(){return this.num},prev:function(){(this.options.continuous||this.index)&&this.slide(this.index-1)},next:function(){(this.options.continuous||this.index<this.num-1)&&this.slide(this.index+1)},play:function(t){var i=this,e=this.index+("rtl"===this.options.slideshowDirection?-1:1);window.clearTimeout(this.timeout),this.interval=t||this.options.slideshowInterval,1<this.elements[this.index]&&(this.timeout=this.setTimeout(!this.requestAnimationFrame&&this.slide||function(t,e){i.animationFrameId=i.requestAnimationFrame.call(window,function(){i.slide(t,e)})},[e,this.options.slideshowTransitionDuration],this.interval)),this.container.addClass(this.options.playingClass)},pause:function(){window.clearTimeout(this.timeout),this.interval=null,this.cancelAnimationFrame&&(this.cancelAnimationFrame.call(window,this.animationFrameId),this.animationFrameId=null),this.container.removeClass(this.options.playingClass)},add:function(t){var e;for(t.concat||(t=Array.prototype.slice.call(t)),this.list.concat||(this.list=Array.prototype.slice.call(this.list)),this.list=this.list.concat(t),this.num=this.list.length,2<this.num&&null===this.options.continuous&&(this.options.continuous=!0,this.container.removeClass(this.options.leftEdgeClass)),this.container.removeClass(this.options.rightEdgeClass).removeClass(this.options.singleClass),e=this.num-t.length;e<this.num;e+=1)this.addSlide(e),this.positionSlide(e);this.positions.length=this.num,this.initSlides(!0)},resetSlides:function(){this.slidesContainer.empty(),this.unloadAllSlides(),this.slides=[]},handleClose:function(){var t=this.options;this.destroyEventListeners(),this.pause(),this.container[0].style.display="none",this.container.removeClass(t.displayClass).removeClass(t.singleClass).removeClass(t.leftEdgeClass).removeClass(t.rightEdgeClass),t.hidePageScrollbars&&(document.body.style.overflow=this.bodyOverflowStyle),this.options.clearSlides&&this.resetSlides(),this.options.onclosed&&this.options.onclosed.call(this)},close:function(){var e=this;this.options.onclose&&this.options.onclose.call(this),this.support.transition&&this.options.displayTransition?(this.container.on(this.support.transition.end,function i(t){t.target===e.container[0]&&(e.container.off(e.support.transition.end,i),e.handleClose())}),this.container.removeClass(this.options.displayClass)):this.handleClose()},circle:function(t){return(this.num+t%this.num)%this.num},move:function(t,e,i){this.translateX(t,e,i),this.positions[t]=e},translate:function(t,e,i,s){var n,o,a;this.slides[t]&&(n=this.slides[t].style,o=this.support.transition,a=this.support.transform,n[o.name+"Duration"]=s+"ms",n[a.name]="translate("+e+"px, "+i+"px)"+(a.translateZ?" translateZ(0)":""))},translateX:function(t,e,i){this.translate(t,e,0,i)},translateY:function(t,e,i){this.translate(t,0,e,i)},animate:function(e,i,s){var n,o,a;s?(n=this,o=(new Date).getTime(),a=window.setInterval(function(){var t=(new Date).getTime()-o;if(s<t)return n.slidesContainer[0].style.left=i+"px",n.ontransitionend(),void window.clearInterval(a);n.slidesContainer[0].style.left=(i-e)*(Math.floor(t/s*100)/100)+e+"px"},4)):this.slidesContainer[0].style.left=i+"px"},preventDefault:function(t){t.preventDefault?t.preventDefault():t.returnValue=!1},stopPropagation:function(t){t.stopPropagation?t.stopPropagation():t.cancelBubble=!0},onresize:function(){this.initSlides(!0)},onhashchange:function(){this.options.closeOnHashChange&&this.close()},onmousedown:function(t){t.which&&1===t.which&&"VIDEO"!==t.target.nodeName&&"AUDIO"!==t.target.nodeName&&(t.preventDefault(),(t.originalEvent||t).touches=[{pageX:t.pageX,pageY:t.pageY}],this.ontouchstart(t))},onmousemove:function(t){this.touchStart&&((t.originalEvent||t).touches=[{pageX:t.pageX,pageY:t.pageY}],this.ontouchmove(t))},onmouseup:function(t){this.touchStart&&(this.ontouchend(t),delete this.touchStart)},onmouseout:function(t){var e,i;this.touchStart&&(e=t.target,(i=t.relatedTarget)&&(i===e||c.contains(e,i))||this.onmouseup(t))},ontouchstart:function(t){this.options.stopTouchEventsPropagation&&this.stopPropagation(t);var e=(t.originalEvent||t).touches[0];this.touchStart={x:e.pageX,y:e.pageY,time:Date.now()},this.isScrolling=undefined,this.touchDelta={}},ontouchmove:function(t){this.options.stopTouchEventsPropagation&&this.stopPropagation(t);var e,i,s=(t.originalEvent||t).touches,n=s[0],o=(t.originalEvent||t).scale,a=this.index;if(!(1<s.length||o&&1!==o))if(this.options.disableScroll&&t.preventDefault(),this.touchDelta={x:n.pageX-this.touchStart.x,y:n.pageY-this.touchStart.y},e=this.touchDelta.x,this.isScrolling===undefined&&(this.isScrolling=this.isScrolling||Math.abs(e)<Math.abs(this.touchDelta.y)),this.isScrolling)this.options.carousel||this.translateY(a,this.touchDelta.y+this.positions[a],0);else for(t.preventDefault(),window.clearTimeout(this.timeout),this.options.continuous?i=[this.circle(a+1),a,this.circle(a-1)]:(this.touchDelta.x=e/=!a&&0<e||a===this.num-1&&e<0?Math.abs(e)/this.slideWidth+1:1,i=[a],a&&i.push(a-1),a<this.num-1&&i.unshift(a+1));i.length;)a=i.pop(),this.translateX(a,e+this.positions[a],0)},ontouchend:function(t){this.options.stopTouchEventsPropagation&&this.stopPropagation(t);var e,i,s,n,o,a=this.index,l=Math.abs(this.touchDelta.x),r=this.slideWidth,h=Math.ceil(this.options.transitionDuration*(1-l/r)/2),d=20<l,c=!a&&0<this.touchDelta.x||a===this.num-1&&this.touchDelta.x<0,u=!d&&this.options.closeOnSwipeUpOrDown&&20<Math.abs(this.touchDelta.y);this.options.continuous&&(c=!1),e=this.touchDelta.x<0?-1:1,this.isScrolling?u?this.close():this.translateY(a,0,h):d&&!c?(i=a+e,s=a-e,n=r*e,o=-r*e,this.options.continuous?(this.move(this.circle(i),n,0),this.move(this.circle(a-2*e),o,0)):0<=i&&i<this.num&&this.move(i,n,0),this.move(a,this.positions[a]+n,h),this.move(this.circle(s),this.positions[this.circle(s)]+n,h),a=this.circle(s),this.onslide(a)):this.options.continuous?(this.move(this.circle(a-1),-r,h),this.move(a,0,h),this.move(this.circle(a+1),r,h)):(a&&this.move(a-1,-r,h),this.move(a,0,h),a<this.num-1&&this.move(a+1,r,h))},ontouchcancel:function(t){this.touchStart&&(this.ontouchend(t),delete this.touchStart)},ontransitionend:function(t){var e=this.slides[this.index];t&&e!==t.target||(this.interval&&this.play(),this.setTimeout(this.options.onslideend,[this.index,e]))},oncomplete:function(t){var e,i=t.target||t.srcElement,s=i&&i.parentNode;i&&s&&(e=this.getNodeIndex(s),c(s).removeClass(this.options.slideLoadingClass),"error"===t.type?(c(s).addClass(this.options.slideErrorClass),this.elements[e]=3):this.elements[e]=2,i.clientHeight>this.container[0].clientHeight&&(i.style.maxHeight=this.container[0].clientHeight),this.interval&&this.slides[this.index]===s&&this.play(),this.setTimeout(this.options.onslidecomplete,[e,s]))},onload:function(t){this.oncomplete(t)},onerror:function(t){this.oncomplete(t)},onkeydown:function(t){switch(t.which||t.keyCode){case 13:this.options.toggleControlsOnReturn&&(this.preventDefault(t),this.toggleControls());break;case 27:this.options.closeOnEscape&&(this.close(),t.stopImmediatePropagation());break;case 32:this.options.toggleSlideshowOnSpace&&(this.preventDefault(t),this.toggleSlideshow());break;case 37:this.options.enableKeyboardNavigation&&(this.preventDefault(t),this.prev());break;case 39:this.options.enableKeyboardNavigation&&(this.preventDefault(t),this.next())}},handleClick:function(t){var e=this.options,i=t.target||t.srcElement,s=i.parentNode;function n(t){return c(i).hasClass(t)||c(s).hasClass(t)}n(e.toggleClass)?(this.preventDefault(t),this.toggleControls()):n(e.prevClass)?(this.preventDefault(t),this.prev()):n(e.nextClass)?(this.preventDefault(t),this.next()):n(e.closeClass)?(this.preventDefault(t),this.close()):n(e.playPauseClass)?(this.preventDefault(t),this.toggleSlideshow()):s===this.slidesContainer[0]?e.closeOnSlideClick?(this.preventDefault(t),this.close()):e.toggleControlsOnSlideClick&&(this.preventDefault(t),this.toggleControls()):s.parentNode&&s.parentNode===this.slidesContainer[0]&&e.toggleControlsOnSlideClick&&(this.preventDefault(t),this.toggleControls())},onclick:function(t){if(!(this.options.emulateTouchEvents&&this.touchDelta&&(20<Math.abs(this.touchDelta.x)||20<Math.abs(this.touchDelta.y))))return this.handleClick(t);delete this.touchDelta},updateEdgeClasses:function(t){t?this.container.removeClass(this.options.leftEdgeClass):this.container.addClass(this.options.leftEdgeClass),t===this.num-1?this.container.addClass(this.options.rightEdgeClass):this.container.removeClass(this.options.rightEdgeClass)},handleSlide:function(t){this.options.continuous||this.updateEdgeClasses(t),this.loadElements(t),this.options.unloadElements&&this.unloadElements(t),this.setTitle(t)},onslide:function(t){this.index=t,this.handleSlide(t),this.setTimeout(this.options.onslide,[t,this.slides[t]])},setTitle:function(t){var e=this.slides[t].firstChild,i=e.title||e.alt,s=this.titleElement;s.length&&(this.titleElement.empty(),i&&s[0].appendChild(document.createTextNode(i)))},setTimeout:function(t,e,i){var s=this;return t&&window.setTimeout(function(){t.apply(s,e||[])},i||0)},imageFactory:function(t,e){var i,s,n,o,a=this,l=this.imagePrototype.cloneNode(!1),r=t,h=this.options.stretchImages;return"string"!=typeof r&&(r=this.getItemProperty(t,this.options.urlProperty),n=this.getItemProperty(t,this.options.titleProperty),o=this.getItemProperty(t,this.options.altTextProperty)||n),!0===h&&(h="contain"),(h=this.support.backgroundSize&&this.support.backgroundSize[h]&&h)?s=this.elementPrototype.cloneNode(!1):(s=l).draggable=!1,n&&(s.title=n),o&&(s.alt=o),c(l).on("load error",function d(t){if(!i){if(t={type:t.type,target:s},!s.parentNode)return a.setTimeout(d,[t]);i=!0,c(l).off("load error",d),h&&"load"===t.type&&(s.style.background='url("'+r+'") center no-repeat',s.style.backgroundSize=h),e(t)}}),l.src=r,s},createElement:function(t,e){var i=t&&this.getItemProperty(t,this.options.typeProperty),s=i&&this[i.split("/")[0]+"Factory"]||this.imageFactory,n=t&&s.call(this,t,e),o=this.getItemProperty(t,this.options.srcsetProperty);return n||(n=this.elementPrototype.cloneNode(!1),this.setTimeout(e,[{type:"error",target:n}])),o&&n.setAttribute("srcset",o),c(n).addClass(this.options.slideContentClass),n},loadElement:function(t){this.elements[t]||(this.slides[t].firstChild?this.elements[t]=c(this.slides[t]).hasClass(this.options.slideErrorClass)?3:2:(this.elements[t]=1,c(this.slides[t]).addClass(this.options.slideLoadingClass),this.slides[t].appendChild(this.createElement(this.list[t],this.proxyListener))))},loadElements:function(t){for(var e=Math.min(this.num,2*this.options.preloadRange+1),i=t,s=0;s<e;s+=1)i+=s*(s%2==0?-1:1),i=this.circle(i),this.loadElement(i)},unloadElements:function(t){var e,i;for(e in this.elements)Object.prototype.hasOwnProperty.call(this.elements,e)&&(i=Math.abs(t-e))>this.options.preloadRange&&i+this.options.preloadRange<this.num&&(this.unloadSlide(e),delete this.elements[e])},addSlide:function(t){var e=this.slidePrototype.cloneNode(!1);e.setAttribute("data-index",t),this.slidesContainer[0].appendChild(e),this.slides.push(e)},positionSlide:function(t){var e=this.slides[t];e.style.width=this.slideWidth+"px",this.support.transform&&(e.style.left=t*-this.slideWidth+"px",this.move(t,this.index>t?-this.slideWidth:this.index<t?this.slideWidth:0,0))},initSlides:function(t){var e,i;for(t||(this.positions=[],this.positions.length=this.num,this.elements={},this.imagePrototype=document.createElement("img"),this.elementPrototype=document.createElement("div"),this.slidePrototype=document.createElement("div"),c(this.slidePrototype).addClass(this.options.slideClass),this.slides=this.slidesContainer[0].children,e=this.options.clearSlides||this.slides.length!==this.num),this.slideWidth=this.container[0].clientWidth,this.slideHeight=this.container[0].clientHeight,this.slidesContainer[0].style.width=this.num*this.slideWidth+"px",e&&this.resetSlides(),i=0;i<this.num;i+=1)e&&this.addSlide(i),this.positionSlide(i);this.options.continuous&&this.support.transform&&(this.move(this.circle(this.index-1),-this.slideWidth,0),this.move(this.circle(this.index+1),this.slideWidth,0)),this.support.transform||(this.slidesContainer[0].style.left=this.index*-this.slideWidth+"px")},unloadSlide:function(t){var e=this.slides[t],i=e.firstChild;null!==i&&e.removeChild(i)},unloadAllSlides:function(){for(var t=0,e=this.slides.length;t<e;t++)this.unloadSlide(t)},toggleControls:function(){var t=this.options.controlsClass;this.container.hasClass(t)?this.container.removeClass(t):this.container.addClass(t)},toggleSlideshow:function(){this.interval?this.pause():this.play()},getNodeIndex:function(t){return parseInt(t.getAttribute("data-index"),10)},getNestedProperty:function(a,t){return t.replace(/\[(?:'([^']+)'|"([^"]+)"|(\d+))\]|(?:(?:^|\.)([^\.\[]+))/g,function(t,e,i,s,n){var o=n||e||i||s&&parseInt(s,10);t&&a&&(a=a[o])}),a},getDataProperty:function(t,e){var i,s;if(t.dataset?(i=e.replace(/-([a-z])/g,function(t,e){return e.toUpperCase()}),s=t.dataset[i]):t.getAttribute&&(s=t.getAttribute("data-"+e.replace(/([A-Z])/g,"-$1").toLowerCase())),"string"==typeof s){if(/^(true|false|null|-?\d+(\.\d+)?|\{[\s\S]*\}|\[[\s\S]*\])$/.test(s))try{return c.parseJSON(s)}catch(n){}return s}},getItemProperty:function(t,e){var i=this.getDataProperty(t,e);return i===undefined&&(i=t[e]),i===undefined&&(i=this.getNestedProperty(t,e)),i},initStartIndex:function(){var t,e=this.options.index,i=this.options.urlProperty;if(e&&"number"!=typeof e)for(t=0;t<this.num;t+=1)if(this.list[t]===e||this.getItemProperty(this.list[t],i)===this.getItemProperty(e,i)){e=t;break}this.index=this.circle(parseInt(e,10)||0)},initEventListeners:function(){var i=this,t=this.slidesContainer;function e(t){var e=i.support.transition&&i.support.transition.end===t.type?"transitionend":t.type;i["on"+e](t)}c(window).on("resize",e),c(window).on("hashchange",e),c(document.body).on("keydown",e),this.container.on("click",e),this.support.touch?t.on("touchstart touchmove touchend touchcancel",e):this.options.emulateTouchEvents&&this.support.transition&&t.on("mousedown mousemove mouseup mouseout",e),this.support.transition&&t.on(this.support.transition.end,e),this.proxyListener=e},destroyEventListeners:function(){var t=this.slidesContainer,e=this.proxyListener;c(window).off("resize",e),c(document.body).off("keydown",e),this.container.off("click",e),this.support.touch?t.off("touchstart touchmove touchend touchcancel",e):this.options.emulateTouchEvents&&this.support.transition&&t.off("mousedown mousemove mouseup mouseout",e),this.support.transition&&t.off(this.support.transition.end,e)},handleOpen:function(){this.options.onopened&&this.options.onopened.call(this)},initWidget:function(){var e=this;return this.container=c(this.options.container),this.container.length?(this.slidesContainer=this.container.find(this.options.slidesContainer).first(),this.slidesContainer.length?(this.titleElement=this.container.find(this.options.titleElement).first(),1===this.num&&this.container.addClass(this.options.singleClass),this.options.onopen&&this.options.onopen.call(this),this.support.transition&&this.options.displayTransition?this.container.on(this.support.transition.end,function i(t){t.target===e.container[0]&&(e.container.off(e.support.transition.end,i),e.handleOpen())}):this.handleOpen(),this.options.hidePageScrollbars&&(this.bodyOverflowStyle=document.body.style.overflow,document.body.style.overflow="hidden"),this.container[0].style.display="block",this.initSlides(),void this.container.addClass(this.options.displayClass)):(this.console.log("blueimp Gallery: Slides container not found.",this.options.slidesContainer),!1)):(this.console.log("blueimp Gallery: Widget container not found.",this.options.container),!1)},initOptions:function(t){this.options=c.extend({},this.options),(t&&t.carousel||this.options.carousel&&(!t||!1!==t.carousel))&&c.extend(this.options,this.carouselOptions),c.extend(this.options,t),this.num<3&&(this.options.continuous=!!this.options.continuous&&null),this.support.transition||(this.options.emulateTouchEvents=!1),this.options.event&&this.preventDefault(this.options.event)}}),i}),function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper","./blueimp-gallery"],t):t(window.blueimp.helper||window.jQuery,window.blueimp.Gallery)}(function(t,e){"use strict";var i=e.prototype;t.extend(i.options,{fullScreen:!1});var s=i.initialize,n=i.close;return t.extend(i,{getFullScreenElement:function(){return document.fullscreenElement||document.webkitFullscreenElement||document.mozFullScreenElement||document.msFullscreenElement},requestFullScreen:function(t){t.requestFullscreen?t.requestFullscreen():t.webkitRequestFullscreen?t.webkitRequestFullscreen():t.mozRequestFullScreen?t.mozRequestFullScreen():t.msRequestFullscreen&&t.msRequestFullscreen()},exitFullScreen:function(){document.exitFullscreen?document.exitFullscreen():document.webkitCancelFullScreen?document.webkitCancelFullScreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.msExitFullscreen&&document.msExitFullscreen()},initialize:function(){s.call(this),this.options.fullScreen&&!this.getFullScreenElement()&&this.requestFullScreen(this.container[0])},close:function(){this.getFullScreenElement()===this.container[0]&&this.exitFullScreen(),n.call(this)}}),e}),function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper","./blueimp-gallery"],t):t(window.blueimp.helper||window.jQuery,window.blueimp.Gallery)}(function(a,t){"use strict";var e=t.prototype;a.extend(e.options,{indicatorContainer:"ol",activeIndicatorClass:"active",thumbnailProperty:"thumbnail",thumbnailIndicators:!0});var i=e.initSlides,s=e.addSlide,n=e.resetSlides,o=e.handleClick,l=e.handleSlide,r=e.handleClose;return a.extend(e,{createIndicator:function(t){var e,i,s=this.indicatorPrototype.cloneNode(!1),n=this.getItemProperty(t,this.options.titleProperty),o=this.options.thumbnailProperty;return this.options.thumbnailIndicators&&(o&&(e=this.getItemProperty(t,o)),e===undefined&&(i=t.getElementsByTagName&&a(t).find("img")[0])&&(e=i.src),e&&(s.style.backgroundImage='url("'+e+'")')),n&&(s.title=n),s},addIndicator:function(t){var e;this.indicatorContainer.length&&((e=this.createIndicator(this.list[t])).setAttribute("data-index",t),this.indicatorContainer[0].appendChild(e),this.indicators.push(e))},setActiveIndicator:function(t){this.indicators&&(this.activeIndicator&&this.activeIndicator.removeClass(this.options.activeIndicatorClass),this.activeIndicator=a(this.indicators[t]),this.activeIndicator.addClass(this.options.activeIndicatorClass))},initSlides:function(t){t||(this.indicatorContainer=this.container.find(this.options.indicatorContainer),this.indicatorContainer.length&&(this.indicatorPrototype=document.createElement("li"),this.indicators=this.indicatorContainer[0].children)),i.call(this,t)},addSlide:function(t){s.call(this,t),this.addIndicator(t)},resetSlides:function(){n.call(this),this.indicatorContainer.empty(),this.indicators=[]},handleClick:function(t){var e=t.target||t.srcElement,i=e.parentNode;if(i===this.indicatorContainer[0])this.preventDefault(t),this.slide(this.getNodeIndex(e));else{if(i.parentNode!==this.indicatorContainer[0])return o.call(this,t);this.preventDefault(t),this.slide(this.getNodeIndex(i))}},handleSlide:function(t){l.call(this,t),this.setActiveIndicator(t)},handleClose:function(){this.activeIndicator&&this.activeIndicator.removeClass(this.options.activeIndicatorClass),r.call(this)}}),t}),function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper","./blueimp-gallery"],t):t(window.blueimp.helper||window.jQuery,window.blueimp.Gallery)}(function(w,t){"use strict";var e=t.prototype;w.extend(e.options,{videoContentClass:"video-content",videoLoadingClass:"video-loading",videoPlayingClass:"video-playing",videoPosterProperty:"poster",videoSourcesProperty:"sources"});var i=e.handleSlide;return w.extend(e,{handleSlide:function(t){i.call(this,t),this.playingVideo&&this.playingVideo.pause()},videoFactory:function(t,e,i){var s,n,o,a,l,r=this,h=this.options,d=this.elementPrototype.cloneNode(!1),c=w(d),u=[{type:"error",target:d}],p=i||document.createElement("video"),m=this.getItemProperty(t,h.urlProperty),y=this.getItemProperty(t,h.typeProperty),f=this.getItemProperty(t,h.titleProperty),g=this.getItemProperty(t,this.options.altTextProperty)||f,v=this.getItemProperty(t,h.videoPosterProperty),C=this.getItemProperty(t,h.videoSourcesProperty);if(c.addClass(h.videoContentClass),f&&(d.title=f),p.canPlayType)if(m&&y&&p.canPlayType(y))p.src=m;else if(C)for(;C.length;)if(n=C.shift(),m=this.getItemProperty(n,h.urlProperty),y=this.getItemProperty(n,h.typeProperty),m&&y&&p.canPlayType(y)){p.src=m;break}return v&&(p.poster=v,s=this.imagePrototype.cloneNode(!1),w(s).addClass(h.toggleClass),s.src=v,s.draggable=!1,s.alt=g,d.appendChild(s)),(o=document.createElement("a")).setAttribute("target","_blank"),i||o.setAttribute("download",f),o.href=m,p.src&&(p.controls=!0,(i||w(p)).on("error",function(){r.setTimeout(e,u)}).on("pause",function(){p.seeking||(a=!1,c.removeClass(r.options.videoLoadingClass).removeClass(r.options.videoPlayingClass),l&&r.container.addClass(r.options.controlsClass),delete r.playingVideo,r.interval&&r.play())}).on("playing",function(){a=!1,c.removeClass(r.options.videoLoadingClass).addClass(r.options.videoPlayingClass),r.container.hasClass(r.options.controlsClass)?(l=!0,r.container.removeClass(r.options.controlsClass)):l=!1}).on("play",function(){window.clearTimeout(r.timeout),a=!0,c.addClass(r.options.videoLoadingClass),r.playingVideo=p}),w(o).on("click",function(t){r.preventDefault(t),a?p.pause():p.play()}),d.appendChild(i&&i.element||p)),d.appendChild(o),this.setTimeout(e,[{type:"load",target:d}]),d}}),t}),function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper","./blueimp-gallery-video"],t):t(window.blueimp.helper||window.jQuery,window.blueimp.Gallery)}(function(l,t){"use strict";if(!window.postMessage)return t;var e=t.prototype;l.extend(e.options,{vimeoVideoIdProperty:"vimeo",vimeoPlayerUrl:"//player.vimeo.com/video/VIDEO_ID?api=1&player_id=PLAYER_ID",vimeoPlayerIdPrefix:"vimeo-player-",vimeoClickToPlay:!0});var n=e.textFactory||e.imageFactory,o=function(t,e,i,s){this.url=t,this.videoId=e,this.playerId=i,this.clickToPlay=s,this.element=document.createElement("div"),this.listeners={}},a=0;return l.extend(o.prototype,{canPlayType:function(){return!0},on:function(t,e){return this.listeners[t]=e,this},loadAPI:function(){var t,e,i=this,s="//f.vimeocdn.com/js/froogaloop2.min.js",n=document.getElementsByTagName("script"),o=n.length;function a(){!e&&i.playOnReady&&i.play(),e=!0}for(;o;)if(n[--o].src===s){t=n[o];break}t||((t=document.createElement("script")).src=s),l(t).on("load",a),n[0].parentNode.insertBefore(t,n[0]),/loaded|complete/.test(t.readyState)&&a()},onReady:function(){var t=this;this.ready=!0,this.player.addEvent("play",function(){t.hasPlayed=!0,t.onPlaying()}),this.player.addEvent("pause",function(){t.onPause()}),this.player.addEvent("finish",function(){t.onPause()}),this.playOnReady&&this.play()},onPlaying:function(){this.playStatus<2&&(this.listeners.playing(),this.playStatus=2)},onPause:function(){this.listeners.pause(),delete this.playStatus},insertIframe:function(){var t=document.createElement("iframe");t.src=this.url.replace("VIDEO_ID",this.videoId).replace("PLAYER_ID",this.playerId),t.id=this.playerId,this.element.parentNode.replaceChild(t,this.element),this.element=t},play:function(){var t=this;this.playStatus||(this.listeners.play(),this.playStatus=1),this.ready?!this.hasPlayed&&(this.clickToPlay||window.navigator&&/iP(hone|od|ad)/.test(window.navigator.platform))?this.onPlaying():this.player.api("play"):(this.playOnReady=!0,window.$f?this.player||(this.insertIframe(),this.player=$f(this.element),this.player.addEvent("ready",function(){t.onReady()})):this.loadAPI())},pause:function(){this.ready?this.player.api("pause"):this.playStatus&&(delete this.playOnReady,this.listeners.pause(),delete this.playStatus)}}),l.extend(e,{VimeoPlayer:o,textFactory:function(t,e){var i=this.options,s=this.getItemProperty(t,i.vimeoVideoIdProperty);return s?(this.getItemProperty(t,i.urlProperty)===undefined&&(t[i.urlProperty]="//vimeo.com/"+s),a+=1,this.videoFactory(t,e,new o(i.vimeoPlayerUrl,s,i.vimeoPlayerIdPrefix+a,i.vimeoClickToPlay))):n.call(this,t,e)}}),t}),function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper","./blueimp-gallery-video"],t):t(window.blueimp.helper||window.jQuery,window.blueimp.Gallery)}(function(t,e){"use strict";if(!window.postMessage)return e;var i=e.prototype;t.extend(i.options,{youTubeVideoIdProperty:"youtube",youTubePlayerVars:{wmode:"transparent"},youTubeClickToPlay:!0});var n=i.textFactory||i.imageFactory,o=function(t,e,i){this.videoId=t,this.playerVars=e,this.clickToPlay=i,this.element=document.createElement("div"),this.listeners={}};return t.extend(o.prototype,{canPlayType:function(){return!0},on:function(t,e){return this.listeners[t]=e,this},loadAPI:function(){var t,e=this,i=window.onYouTubeIframeAPIReady,s="//www.youtube.com/iframe_api",n=document.getElementsByTagName("script"),o=n.length;for(window.onYouTubeIframeAPIReady=function(){i&&i.apply(this),e.playOnReady&&e.play()};o;)if(n[--o].src===s)return;(t=document.createElement("script")).src=s,n[0].parentNode.insertBefore(t,n[0])},onReady:function(){this.ready=!0,this.playOnReady&&this.play()},onPlaying:function(){this.playStatus<2&&(this.listeners.playing(),this.playStatus=2)},onPause:function(){i.setTimeout.call(this,this.checkSeek,null,2e3)},checkSeek:function(){this.stateChange!==YT.PlayerState.PAUSED&&this.stateChange!==YT.PlayerState.ENDED||(this.listeners.pause(),delete this.playStatus)},onStateChange:function(t){switch(t.data){case YT.PlayerState.PLAYING:this.hasPlayed=!0,this.onPlaying();break;case YT.PlayerState.PAUSED:case YT.PlayerState.ENDED:this.onPause()}this.stateChange=t.data},onError:function(t){this.listeners.error(t)},play:function(){var e=this;this.playStatus||(this.listeners.play(),this.playStatus=1),this.ready?!this.hasPlayed&&(this.clickToPlay||window.navigator&&/iP(hone|od|ad)/.test(window.navigator.platform))?this.onPlaying():this.player.playVideo():(this.playOnReady=!0,window.YT&&YT.Player?this.player||(this.player=new YT.Player(this.element,{videoId:this.videoId,playerVars:this.playerVars,events:{onReady:function(){e.onReady()},onStateChange:function(t){e.onStateChange(t)},onError:function(t){e.onError(t)}}})):this.loadAPI())},pause:function(){this.ready?this.player.pauseVideo():this.playStatus&&(delete this.playOnReady,this.listeners.pause(),delete this.playStatus)}}),t.extend(i,{YouTubePlayer:o,textFactory:function(t,e){var i=this.options,s=this.getItemProperty(t,i.youTubeVideoIdProperty);return s?(this.getItemProperty(t,i.urlProperty)===undefined&&(t[i.urlProperty]="//www.youtube.com/watch?v="+s),this.getItemProperty(t,i.videoPosterProperty)===undefined&&(t[i.videoPosterProperty]="//img.youtube.com/vi/"+s+"/maxresdefault.jpg"),this.videoFactory(t,e,new o(s,i.youTubePlayerVars,i.youTubeClickToPlay))):n.call(this,t,e)}}),e}),function(t){"use strict";"function"==typeof define&&define.amd?define(["jquery","./blueimp-gallery"],t):t(window.jQuery,window.blueimp.Gallery)}(function(l,r){"use strict";l(document).on("click","[data-gallery]",function(t){var e=l(this).data("gallery"),i=l(e),s=i.length&&i||l(r.prototype.options.container),n={onopen:function(){s.data("gallery",this).trigger("open")},onopened:function(){s.trigger("opened")},onslide:function(){s.trigger("slide",arguments)},onslideend:function(){s.trigger("slideend",arguments)},onslidecomplete:function(){s.trigger("slidecomplete",arguments)},onclose:function(){s.trigger("close")},onclosed:function(){s.trigger("closed").removeData("gallery")}},o=l.extend(s.data(),{container:s[0],index:this,event:t},n),a=l(this).closest("[data-gallery-group], body").find('[data-gallery="'+e+'"]');return o.filter&&(a=a.filter(o.filter)),new r(a,o)})});
!function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper"],t):(window.blueimp=window.blueimp||{},window.blueimp.Gallery=t(window.blueimp.helper||window.jQuery))}(function(y){"use strict";function i(t,e){return document.body.style.maxHeight===undefined?null:this&&this.options===i.prototype.options?void(t&&t.length?(this.list=t,this.num=t.length,this.initOptions(e),this.initialize()):this.console.log("blueimp Gallery: No or empty list provided as first argument.",t)):new i(t,e)}return y.extend(i.prototype,{options:{container:"#blueimp-gallery",slidesContainer:"div",titleElement:"h3",displayClass:"blueimp-gallery-display",controlsClass:"blueimp-gallery-controls",singleClass:"blueimp-gallery-single",leftEdgeClass:"blueimp-gallery-left",rightEdgeClass:"blueimp-gallery-right",playingClass:"blueimp-gallery-playing",svgasimgClass:"blueimp-gallery-svgasimg",smilClass:"blueimp-gallery-smil",slideClass:"slide",slideActiveClass:"slide-active",slidePrevClass:"slide-prev",slideNextClass:"slide-next",slideLoadingClass:"slide-loading",slideErrorClass:"slide-error",slideContentClass:"slide-content",toggleClass:"toggle",prevClass:"prev",nextClass:"next",closeClass:"close",playPauseClass:"play-pause",typeProperty:"type",titleProperty:"title",altTextProperty:"alt",urlProperty:"href",srcsetProperty:"srcset",sizesProperty:"sizes",sourcesProperty:"sources",displayTransition:!0,clearSlides:!0,toggleControlsOnEnter:!0,toggleControlsOnSlideClick:!0,toggleSlideshowOnSpace:!0,enableKeyboardNavigation:!0,closeOnEscape:!0,closeOnSlideClick:!0,closeOnSwipeUpOrDown:!0,closeOnHashChange:!0,emulateTouchEvents:!0,stopTouchEventsPropagation:!1,hidePageScrollbars:!0,disableScroll:!0,carousel:!1,continuous:!0,unloadElements:!0,startSlideshow:!1,slideshowInterval:5e3,slideshowDirection:"ltr",index:0,preloadRange:2,transitionDuration:300,slideshowTransitionDuration:500,event:undefined,onopen:undefined,onopened:undefined,onslide:undefined,onslideend:undefined,onslidecomplete:undefined,onclose:undefined,onclosed:undefined},carouselOptions:{hidePageScrollbars:!1,toggleControlsOnEnter:!1,toggleSlideshowOnSpace:!1,enableKeyboardNavigation:!1,closeOnEscape:!1,closeOnSlideClick:!1,closeOnSwipeUpOrDown:!1,closeOnHashChange:!1,disableScroll:!1,startSlideshow:!0},console:window.console&&"function"==typeof window.console.log?window.console:{log:function(){}},support:function(s){var t,n={source:!!window.HTMLSourceElement,picture:!!window.HTMLPictureElement,svgasimg:document.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#Image","1.1"),smil:!!document.createElementNS&&/SVGAnimate/.test(document.createElementNS("http://www.w3.org/2000/svg","animate").toString()),touch:window.ontouchstart!==undefined||window.DocumentTouch&&document instanceof DocumentTouch},e={webkitTransition:{end:"webkitTransitionEnd",prefix:"-webkit-"},MozTransition:{end:"transitionend",prefix:"-moz-"},OTransition:{end:"otransitionend",prefix:"-o-"},transition:{end:"transitionend",prefix:""}};for(t in e)if(Object.prototype.hasOwnProperty.call(e,t)&&s.style[t]!==undefined){n.transition=e[t],n.transition.name=t;break}function i(){var t,e,i=n.transition;document.body.appendChild(s),i&&(t=i.name.slice(0,-9)+"ransform",s.style[t]!==undefined&&(s.style[t]="translateZ(0)",e=window.getComputedStyle(s).getPropertyValue(i.prefix+"transform"),n.transform={prefix:i.prefix,name:t,translate:!0,translateZ:!!e&&"none"!==e})),document.body.removeChild(s)}return document.body?i():y(document).on("DOMContentLoaded",i),n}(document.createElement("div")),requestAnimationFrame:window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame,cancelAnimationFrame:window.cancelAnimationFrame||window.webkitCancelRequestAnimationFrame||window.webkitCancelAnimationFrame||window.mozCancelAnimationFrame,initialize:function(){if(this.initStartIndex(),!1===this.initWidget())return!1;this.initEventListeners(),this.onslide(this.index),this.ontransitionend(),this.options.startSlideshow&&this.play()},slide:function(t,e){window.clearTimeout(this.timeout);var i,s,n,o=this.index;if(o!==t&&1!==this.num){if(e=e||this.options.transitionDuration,this.support.transform){for(this.options.continuous||(t=this.circle(t)),i=Math.abs(o-t)/(o-t),this.options.continuous&&(s=i,(i=-this.positions[this.circle(t)]/this.slideWidth)!==s&&(t=-i*this.num+t)),n=Math.abs(o-t)-1;n;)--n,this.move(this.circle((o<t?t:o)-n-1),this.slideWidth*i,0);t=this.circle(t),this.move(o,this.slideWidth*i,e),this.move(t,0,e),this.options.continuous&&this.move(this.circle(t-i),-this.slideWidth*i,0)}else t=this.circle(t),this.animate(o*-this.slideWidth,t*-this.slideWidth,e);this.onslide(t)}},getIndex:function(){return this.index},getNumber:function(){return this.num},prev:function(){(this.options.continuous||this.index)&&this.slide(this.index-1)},next:function(){(this.options.continuous||this.index<this.num-1)&&this.slide(this.index+1)},play:function(t){var i=this,e=this.index+("rtl"===this.options.slideshowDirection?-1:1);window.clearTimeout(this.timeout),this.interval=t||this.options.slideshowInterval,1<this.elements[this.index]&&(this.timeout=this.setTimeout(!this.requestAnimationFrame&&this.slide||function(t,e){i.animationFrameId=i.requestAnimationFrame.call(window,function(){i.slide(t,e)})},[e,this.options.slideshowTransitionDuration],this.interval)),this.container.addClass(this.options.playingClass),this.slidesContainer[0].setAttribute("aria-live","off"),this.playPauseElement.length&&this.playPauseElement[0].setAttribute("aria-pressed","true")},pause:function(){window.clearTimeout(this.timeout),this.interval=null,this.cancelAnimationFrame&&(this.cancelAnimationFrame.call(window,this.animationFrameId),this.animationFrameId=null),this.container.removeClass(this.options.playingClass),this.slidesContainer[0].setAttribute("aria-live","polite"),this.playPauseElement.length&&this.playPauseElement[0].setAttribute("aria-pressed","false")},add:function(t){var e;for(t.concat||(t=Array.prototype.slice.call(t)),this.list.concat||(this.list=Array.prototype.slice.call(this.list)),this.list=this.list.concat(t),this.num=this.list.length,2<this.num&&null===this.options.continuous&&(this.options.continuous=!0,this.container.removeClass(this.options.leftEdgeClass)),this.container.removeClass(this.options.rightEdgeClass).removeClass(this.options.singleClass),e=this.num-t.length;e<this.num;e+=1)this.addSlide(e),this.positionSlide(e);this.positions.length=this.num,this.initSlides(!0)},resetSlides:function(){this.slidesContainer.empty(),this.unloadAllSlides(),this.slides=[]},handleClose:function(){var t=this.options;this.destroyEventListeners(),this.pause(),this.container[0].style.display="none",this.container.removeClass(t.displayClass).removeClass(t.singleClass).removeClass(t.leftEdgeClass).removeClass(t.rightEdgeClass),t.hidePageScrollbars&&(document.body.style.overflow=this.bodyOverflowStyle),this.options.clearSlides&&this.resetSlides(),this.options.onclosed&&this.options.onclosed.call(this)},close:function(){var e=this;this.options.onclose&&this.options.onclose.call(this),this.support.transition&&this.options.displayTransition?(this.container.on(this.support.transition.end,function i(t){t.target===e.container[0]&&(e.container.off(e.support.transition.end,i),e.handleClose())}),this.container.removeClass(this.options.displayClass)):this.handleClose()},circle:function(t){return(this.num+t%this.num)%this.num},move:function(t,e,i){this.translateX(t,e,i),this.positions[t]=e},translate:function(t,e,i,s){var n,o,a;this.slides[t]&&(n=this.slides[t].style,o=this.support.transition,a=this.support.transform,n[o.name+"Duration"]=s+"ms",n[a.name]="translate("+e+"px, "+i+"px)"+(a.translateZ?" translateZ(0)":""))},translateX:function(t,e,i){this.translate(t,e,0,i)},translateY:function(t,e,i){this.translate(t,0,e,i)},animate:function(e,i,s){var n,o,a;s?(n=this,o=(new Date).getTime(),a=window.setInterval(function(){var t=(new Date).getTime()-o;if(s<t)return n.slidesContainer[0].style.left=i+"px",n.ontransitionend(),void window.clearInterval(a);n.slidesContainer[0].style.left=(i-e)*(Math.floor(t/s*100)/100)+e+"px"},4)):this.slidesContainer[0].style.left=i+"px"},preventDefault:function(t){t.preventDefault?t.preventDefault():t.returnValue=!1},stopPropagation:function(t){t.stopPropagation?t.stopPropagation():t.cancelBubble=!0},onresize:function(){this.initSlides(!0)},onhashchange:function(){this.options.closeOnHashChange&&this.close()},onmousedown:function(t){t.which&&1===t.which&&"VIDEO"!==t.target.nodeName&&"AUDIO"!==t.target.nodeName&&(t.preventDefault(),(t.originalEvent||t).touches=[{pageX:t.pageX,pageY:t.pageY}],this.ontouchstart(t))},onmousemove:function(t){this.touchStart&&((t.originalEvent||t).touches=[{pageX:t.pageX,pageY:t.pageY}],this.ontouchmove(t))},onmouseup:function(t){this.touchStart&&(this.ontouchend(t),delete this.touchStart)},onmouseout:function(t){var e,i;this.touchStart&&(e=t.target,(i=t.relatedTarget)&&(i===e||y.contains(e,i))||this.onmouseup(t))},ontouchstart:function(t){this.options.stopTouchEventsPropagation&&this.stopPropagation(t);var e=(t.originalEvent||t).touches[0];this.touchStart={x:e.pageX,y:e.pageY,time:Date.now()},this.isScrolling=undefined,this.touchDelta={}},ontouchmove:function(t){this.options.stopTouchEventsPropagation&&this.stopPropagation(t);var e,i,s=(t.originalEvent||t).touches,n=s[0],o=(t.originalEvent||t).scale,a=this.index;if(!(1<s.length||o&&1!==o))if(this.options.disableScroll&&t.preventDefault(),this.touchDelta={x:n.pageX-this.touchStart.x,y:n.pageY-this.touchStart.y},e=this.touchDelta.x,this.isScrolling===undefined&&(this.isScrolling=this.isScrolling||Math.abs(e)<Math.abs(this.touchDelta.y)),this.isScrolling)this.options.carousel||this.translateY(a,this.touchDelta.y+this.positions[a],0);else for(t.preventDefault(),window.clearTimeout(this.timeout),this.options.continuous?i=[this.circle(a+1),a,this.circle(a-1)]:(this.touchDelta.x=e/=!a&&0<e||a===this.num-1&&e<0?Math.abs(e)/this.slideWidth+1:1,i=[a],a&&i.push(a-1),a<this.num-1&&i.unshift(a+1));i.length;)a=i.pop(),this.translateX(a,e+this.positions[a],0)},ontouchend:function(t){this.options.stopTouchEventsPropagation&&this.stopPropagation(t);var e,i,s,n,o,a=this.index,l=Math.abs(this.touchDelta.x),r=this.slideWidth,h=Math.ceil(this.options.transitionDuration*(1-l/r)/2),d=20<l,c=!a&&0<this.touchDelta.x||a===this.num-1&&this.touchDelta.x<0,u=!d&&this.options.closeOnSwipeUpOrDown&&20<Math.abs(this.touchDelta.y);this.options.continuous&&(c=!1),e=this.touchDelta.x<0?-1:1,this.isScrolling?u?this.close():this.translateY(a,0,h):d&&!c?(i=a+e,s=a-e,n=r*e,o=-r*e,this.options.continuous?(this.move(this.circle(i),n,0),this.move(this.circle(a-2*e),o,0)):0<=i&&i<this.num&&this.move(i,n,0),this.move(a,this.positions[a]+n,h),this.move(this.circle(s),this.positions[this.circle(s)]+n,h),a=this.circle(s),this.onslide(a)):this.options.continuous?(this.move(this.circle(a-1),-r,h),this.move(a,0,h),this.move(this.circle(a+1),r,h)):(a&&this.move(a-1,-r,h),this.move(a,0,h),a<this.num-1&&this.move(a+1,r,h))},ontouchcancel:function(t){this.touchStart&&(this.ontouchend(t),delete this.touchStart)},ontransitionend:function(t){var e=this.slides[this.index];t&&e!==t.target||(this.interval&&this.play(),this.setTimeout(this.options.onslideend,[this.index,e]))},oncomplete:function(t){var e,i=t.target||t.srcElement,s=i&&i.parentNode;i&&s&&(e=this.getNodeIndex(s),y(s).removeClass(this.options.slideLoadingClass),"error"===t.type?(y(s).addClass(this.options.slideErrorClass),this.elements[e]=3):this.elements[e]=2,i.clientHeight>this.container[0].clientHeight&&(i.style.maxHeight=this.container[0].clientHeight),this.interval&&this.slides[this.index]===s&&this.play(),this.setTimeout(this.options.onslidecomplete,[e,s]))},onload:function(t){this.oncomplete(t)},onerror:function(t){this.oncomplete(t)},onkeydown:function(t){switch(t.which||t.keyCode){case 13:this.options.toggleControlsOnEnter&&(this.preventDefault(t),this.toggleControls());break;case 27:this.options.closeOnEscape&&(this.close(),t.stopImmediatePropagation());break;case 32:this.options.toggleSlideshowOnSpace&&(this.preventDefault(t),this.toggleSlideshow());break;case 37:this.options.enableKeyboardNavigation&&(this.preventDefault(t),this.prev());break;case 39:this.options.enableKeyboardNavigation&&(this.preventDefault(t),this.next())}},handleClick:function(t){var e=this.options,i=t.target||t.srcElement,s=i.parentNode;function n(t){return y(i).hasClass(t)||y(s).hasClass(t)}n(e.toggleClass)?(this.preventDefault(t),this.toggleControls()):n(e.prevClass)?(this.preventDefault(t),this.prev()):n(e.nextClass)?(this.preventDefault(t),this.next()):n(e.closeClass)?(this.preventDefault(t),this.close()):n(e.playPauseClass)?(this.preventDefault(t),this.toggleSlideshow()):s===this.slidesContainer[0]?e.closeOnSlideClick?(this.preventDefault(t),this.close()):e.toggleControlsOnSlideClick&&(this.preventDefault(t),this.toggleControls()):s.parentNode&&s.parentNode===this.slidesContainer[0]&&e.toggleControlsOnSlideClick&&(this.preventDefault(t),this.toggleControls())},onclick:function(t){if(!(this.options.emulateTouchEvents&&this.touchDelta&&(20<Math.abs(this.touchDelta.x)||20<Math.abs(this.touchDelta.y))))return this.handleClick(t);delete this.touchDelta},updateEdgeClasses:function(t){t?this.container.removeClass(this.options.leftEdgeClass):this.container.addClass(this.options.leftEdgeClass),t===this.num-1?this.container.addClass(this.options.rightEdgeClass):this.container.removeClass(this.options.rightEdgeClass)},updateActiveSlide:function(t,e){for(var i,s,n=this.slides,o=this.options,a=[{index:e,method:"addClass",hidden:!1},{index:t,method:"removeClass",hidden:!0}];a.length;)i=a.pop(),y(n[i.index])[i.method](o.slideActiveClass),s=this.circle(i.index-1),(o.continuous||s<i.index)&&y(n[s])[i.method](o.slidePrevClass),s=this.circle(i.index+1),(o.continuous||s>i.index)&&y(n[s])[i.method](o.slideNextClass);this.slides[t].setAttribute("aria-hidden","true"),this.slides[e].removeAttribute("aria-hidden")},handleSlide:function(t,e){this.options.continuous||this.updateEdgeClasses(e),this.updateActiveSlide(t,e),this.loadElements(e),this.options.unloadElements&&this.unloadElements(t,e),this.setTitle(e)},onslide:function(t){this.handleSlide(this.index,t),this.index=t,this.setTimeout(this.options.onslide,[t,this.slides[t]])},setTitle:function(t){var e=this.slides[t].firstChild,i=e.title||e.alt,s=this.titleElement;s.length&&(this.titleElement.empty(),i&&s[0].appendChild(document.createTextNode(i)))},setTimeout:function(t,e,i){var s=this;return t&&window.setTimeout(function(){t.apply(s,e||[])},i||0)},imageFactory:function(t,e){var i,s,n,o,a,l,r,h,d=this.options,c=this,u=t,p=this.imagePrototype.cloneNode(!1);if("string"!=typeof u&&(u=this.getItemProperty(t,d.urlProperty),n=this.support.picture&&this.support.source&&this.getItemProperty(t,d.sourcesProperty),o=this.getItemProperty(t,d.srcsetProperty),a=this.getItemProperty(t,d.sizesProperty),l=this.getItemProperty(t,d.titleProperty),r=this.getItemProperty(t,d.altTextProperty)||l),p.draggable=!1,l&&(p.title=l),r&&(p.alt=r),y(p).on("load error",function m(t){if(!s){if(!(t={type:t.type,target:i||p}).target.parentNode)return c.setTimeout(m,[t]);s=!0,y(p).off("load error",m),e(t)}}),n&&n.length){for(i=this.picturePrototype.cloneNode(!1),h=0;h<n.length;h+=1)i.appendChild(y.extend(this.sourcePrototype.cloneNode(!1),n[h]));i.appendChild(p),y(i).addClass(d.toggleClass)}return o&&(a&&(p.sizes=a),p.srcset=o),p.src=u,i||p},createElement:function(t,e){var i=t&&this.getItemProperty(t,this.options.typeProperty),s=i&&this[i.split("/")[0]+"Factory"]||this.imageFactory,n=t&&s.call(this,t,e);return n||(n=this.elementPrototype.cloneNode(!1),this.setTimeout(e,[{type:"error",target:n}])),y(n).addClass(this.options.slideContentClass),n},iteratePreloadRange:function(t,e){for(var i=this.num,s=this.options,n=Math.min(i,2*s.preloadRange+1),o=t,a=0;a<n;a+=1){if((o+=a*(a%2==0?-1:1))<0||i<=o){if(!s.continuous)continue;o=this.circle(o)}e.call(this,o)}},loadElement:function(t){this.elements[t]||(this.slides[t].firstChild?this.elements[t]=y(this.slides[t]).hasClass(this.options.slideErrorClass)?3:2:(this.elements[t]=1,y(this.slides[t]).addClass(this.options.slideLoadingClass),this.slides[t].appendChild(this.createElement(this.list[t],this.proxyListener))))},loadElements:function(t){this.iteratePreloadRange(t,this.loadElement)},unloadElements:function(t,i){var s=this.options.preloadRange;this.iteratePreloadRange(t,function(t){var e=Math.abs(t-i);s<e&&e+s<this.num&&(this.unloadSlide(t),delete this.elements[t])})},addSlide:function(t){var e=this.slidePrototype.cloneNode(!1);e.setAttribute("data-index",t),e.setAttribute("aria-hidden","true"),this.slidesContainer[0].appendChild(e),this.slides.push(e)},positionSlide:function(t){var e=this.slides[t];e.style.width=this.slideWidth+"px",this.support.transform&&(e.style.left=t*-this.slideWidth+"px",this.move(t,this.index>t?-this.slideWidth:this.index<t?this.slideWidth:0,0))},initSlides:function(t){var e,i;for(t||(this.positions=[],this.positions.length=this.num,this.elements={},this.picturePrototype=this.support.picture&&document.createElement("picture"),this.sourcePrototype=this.support.source&&document.createElement("source"),this.imagePrototype=document.createElement("img"),this.elementPrototype=document.createElement("div"),this.slidePrototype=this.elementPrototype.cloneNode(!1),y(this.slidePrototype).addClass(this.options.slideClass),this.slides=this.slidesContainer[0].children,e=this.options.clearSlides||this.slides.length!==this.num),this.slideWidth=this.container[0].clientWidth,this.slideHeight=this.container[0].clientHeight,this.slidesContainer[0].style.width=this.num*this.slideWidth+"px",e&&this.resetSlides(),i=0;i<this.num;i+=1)e&&this.addSlide(i),this.positionSlide(i);this.options.continuous&&this.support.transform&&(this.move(this.circle(this.index-1),-this.slideWidth,0),this.move(this.circle(this.index+1),this.slideWidth,0)),this.support.transform||(this.slidesContainer[0].style.left=this.index*-this.slideWidth+"px")},unloadSlide:function(t){var e=this.slides[t],i=e.firstChild;null!==i&&e.removeChild(i)},unloadAllSlides:function(){for(var t=0,e=this.slides.length;t<e;t++)this.unloadSlide(t)},toggleControls:function(){var t=this.options.controlsClass;this.container.hasClass(t)?this.container.removeClass(t):this.container.addClass(t)},toggleSlideshow:function(){this.interval?this.pause():this.play()},getNodeIndex:function(t){return parseInt(t.getAttribute("data-index"),10)},getNestedProperty:function(a,t){return t.replace(/\[(?:'([^']+)'|"([^"]+)"|(\d+))\]|(?:(?:^|\.)([^\.\[]+))/g,function(t,e,i,s,n){var o=n||e||i||s&&parseInt(s,10);t&&a&&(a=a[o])}),a},getDataProperty:function(t,e){var i,s;if(t.dataset?(i=e.replace(/-([a-z])/g,function(t,e){return e.toUpperCase()}),s=t.dataset[i]):t.getAttribute&&(s=t.getAttribute("data-"+e.replace(/([A-Z])/g,"-$1").toLowerCase())),"string"==typeof s){if(/^(true|false|null|-?\d+(\.\d+)?|\{[\s\S]*\}|\[[\s\S]*\])$/.test(s))try{return y.parseJSON(s)}catch(n){}return s}},getItemProperty:function(t,e){var i=this.getDataProperty(t,e);return i===undefined&&(i=t[e]),i===undefined&&(i=this.getNestedProperty(t,e)),i},initStartIndex:function(){var t,e=this.options.index,i=this.options.urlProperty;if(e&&"number"!=typeof e)for(t=0;t<this.num;t+=1)if(this.list[t]===e||this.getItemProperty(this.list[t],i)===this.getItemProperty(e,i)){e=t;break}this.index=this.circle(parseInt(e,10)||0)},initEventListeners:function(){var i=this,t=this.slidesContainer;function e(t){var e=i.support.transition&&i.support.transition.end===t.type?"transitionend":t.type;i["on"+e](t)}y(window).on("resize",e),y(window).on("hashchange",e),y(document.body).on("keydown",e),this.container.on("click",e),this.support.touch?t.on("touchstart touchmove touchend touchcancel",e):this.options.emulateTouchEvents&&this.support.transition&&t.on("mousedown mousemove mouseup mouseout",e),this.support.transition&&t.on(this.support.transition.end,e),this.proxyListener=e},destroyEventListeners:function(){var t=this.slidesContainer,e=this.proxyListener;y(window).off("resize",e),y(document.body).off("keydown",e),this.container.off("click",e),this.support.touch?t.off("touchstart touchmove touchend touchcancel",e):this.options.emulateTouchEvents&&this.support.transition&&t.off("mousedown mousemove mouseup mouseout",e),this.support.transition&&t.off(this.support.transition.end,e)},handleOpen:function(){this.options.onopened&&this.options.onopened.call(this)},initWidget:function(){var e=this;return this.container=y(this.options.container),this.container.length?(this.slidesContainer=this.container.find(this.options.slidesContainer).first(),this.slidesContainer.length?(this.titleElement=this.container.find(this.options.titleElement).first(),this.playPauseElement=this.container.find("."+this.options.playPauseClass).first(),1===this.num&&this.container.addClass(this.options.singleClass),this.support.svgasimg&&this.container.addClass(this.options.svgasimgClass),this.support.smil&&this.container.addClass(this.options.smilClass),this.options.onopen&&this.options.onopen.call(this),this.support.transition&&this.options.displayTransition?this.container.on(this.support.transition.end,function i(t){t.target===e.container[0]&&(e.container.off(e.support.transition.end,i),e.handleOpen())}):this.handleOpen(),this.options.hidePageScrollbars&&(this.bodyOverflowStyle=document.body.style.overflow,document.body.style.overflow="hidden"),this.container[0].style.display="block",this.initSlides(),void this.container.addClass(this.options.displayClass)):(this.console.log("blueimp Gallery: Slides container not found.",this.options.slidesContainer),!1)):(this.console.log("blueimp Gallery: Widget container not found.",this.options.container),!1)},initOptions:function(t){this.options=y.extend({},this.options),(t&&t.carousel||this.options.carousel&&(!t||!1!==t.carousel))&&y.extend(this.options,this.carouselOptions),y.extend(this.options,t),this.num<3&&(this.options.continuous=!!this.options.continuous&&null),this.support.transition||(this.options.emulateTouchEvents=!1),this.options.event&&this.preventDefault(this.options.event)}}),i}),function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper","./blueimp-gallery"],t):t(window.blueimp.helper||window.jQuery,window.blueimp.Gallery)}(function(t,e){"use strict";var i=e.prototype;t.extend(i.options,{fullscreen:!1});var s=i.initialize,n=i.close;return t.extend(i,{getFullScreenElement:function(){return document.fullscreenElement||document.webkitFullscreenElement||document.mozFullScreenElement||document.msFullscreenElement},requestFullScreen:function(t){t.requestFullscreen?t.requestFullscreen():t.webkitRequestFullscreen?t.webkitRequestFullscreen():t.mozRequestFullScreen?t.mozRequestFullScreen():t.msRequestFullscreen&&t.msRequestFullscreen()},exitFullScreen:function(){document.exitFullscreen?document.exitFullscreen():document.webkitCancelFullScreen?document.webkitCancelFullScreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.msExitFullscreen&&document.msExitFullscreen()},initialize:function(){s.call(this),this.options.fullscreen&&!this.getFullScreenElement()&&this.requestFullScreen(this.container[0])},close:function(){this.getFullScreenElement()===this.container[0]&&this.exitFullScreen(),n.call(this)}}),e}),function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper","./blueimp-gallery"],t):t(window.blueimp.helper||window.jQuery,window.blueimp.Gallery)}(function(a,t){"use strict";var e=t.prototype;a.extend(e.options,{indicatorContainer:"ol",activeIndicatorClass:"active",thumbnailProperty:"thumbnail",thumbnailIndicators:!0});var i=e.initSlides,s=e.addSlide,n=e.resetSlides,o=e.handleClick,l=e.handleSlide,r=e.handleClose;return a.extend(e,{createIndicator:function(t){var e,i,s=this.indicatorPrototype.cloneNode(!1),n=this.getItemProperty(t,this.options.titleProperty),o=this.options.thumbnailProperty;return this.options.thumbnailIndicators&&(o&&(e=this.getItemProperty(t,o)),e===undefined&&(i=t.getElementsByTagName&&a(t).find("img")[0])&&(e=i.src),e&&(s.style.backgroundImage='url("'+e+'")')),n&&(s.title=n),s.setAttribute("role","link"),s},addIndicator:function(t){var e;this.indicatorContainer.length&&((e=this.createIndicator(this.list[t])).setAttribute("data-index",t),this.indicatorContainer[0].appendChild(e),this.indicators.push(e))},setActiveIndicator:function(t){this.indicators&&(this.activeIndicator&&this.activeIndicator.removeClass(this.options.activeIndicatorClass),this.activeIndicator=a(this.indicators[t]),this.activeIndicator.addClass(this.options.activeIndicatorClass))},initSlides:function(t){t||(this.indicatorContainer=this.container.find(this.options.indicatorContainer),this.indicatorContainer.length&&(this.indicatorPrototype=document.createElement("li"),this.indicators=this.indicatorContainer[0].children)),i.call(this,t)},addSlide:function(t){s.call(this,t),this.addIndicator(t)},resetSlides:function(){n.call(this),this.indicatorContainer.empty(),this.indicators=[]},handleClick:function(t){var e=t.target||t.srcElement,i=e.parentNode;if(i===this.indicatorContainer[0])this.preventDefault(t),this.slide(this.getNodeIndex(e));else{if(i.parentNode!==this.indicatorContainer[0])return o.call(this,t);this.preventDefault(t),this.slide(this.getNodeIndex(i))}},handleSlide:function(t,e){l.call(this,t,e),this.setActiveIndicator(e)},handleClose:function(){this.activeIndicator&&this.activeIndicator.removeClass(this.options.activeIndicatorClass),r.call(this)}}),t}),function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper","./blueimp-gallery"],t):t(window.blueimp.helper||window.jQuery,window.blueimp.Gallery)}(function(C,t){"use strict";var e=t.prototype;C.extend(e.options,{videoContentClass:"video-content",videoLoadingClass:"video-loading",videoPlayingClass:"video-playing",videoIframeClass:"video-iframe",videoCoverClass:"video-cover",videoPlayClass:"video-play",videoPlaysInline:!0,videoPreloadProperty:"preload",videoPosterProperty:"poster"});var i=e.handleSlide;return C.extend(e,{handleSlide:function(t,e){i.call(this,t,e),this.setTimeout(function(){this.activeVideo&&this.activeVideo.pause()})},videoFactory:function(t,e,i){var s,n,o,a=this,l=this.options,r=this.elementPrototype.cloneNode(!1),h=C(r),d=[{type:"error",target:r}],c=i||document.createElement("video"),u=this.elementPrototype.cloneNode(!1),p=document.createElement("a"),m=this.getItemProperty(t,l.urlProperty),y=this.getItemProperty(t,l.sourcesProperty),f=this.getItemProperty(t,l.titleProperty),g=this.getItemProperty(t,l.videoPosterProperty),v=[p];if(h.addClass(l.videoContentClass),C(p).addClass(l.videoPlayClass),C(u).addClass(l.videoCoverClass).hasClass(l.toggleClass)||v.push(u),u.draggable=!1,f&&(r.title=f,p.setAttribute("aria-label",f)),g&&(u.style.backgroundImage='url("'+g+'")'),c.setAttribute?l.videoPlaysInline&&c.setAttribute("playsinline",""):h.addClass(l.videoIframeClass),c.preload=this.getItemProperty(t,l.videoPreloadProperty)||"none",this.support.source&&y)for(o=0;o<y.length;o+=1)c.appendChild(C.extend(this.sourcePrototype.cloneNode(!1),y[o]));return m&&(c.src=m),p.href=m||y&&y.length&&y[0].src,c.play&&c.pause&&((i||C(c)).on("error",function(){a.setTimeout(e,d)}).on("pause",function(){c.seeking||(n=!1,h.removeClass(a.options.videoLoadingClass).removeClass(a.options.videoPlayingClass),s&&a.container.addClass(a.options.controlsClass),c.controls=!1,c===a.activeVideo&&delete a.activeVideo,a.interval&&a.play())}).on("playing",function(){n=!1,u.removeAttribute("style"),h.removeClass(a.options.videoLoadingClass).addClass(a.options.videoPlayingClass)}).on("play",function(){window.clearTimeout(a.timeout),n=!0,h.addClass(a.options.videoLoadingClass),a.container.hasClass(a.options.controlsClass)?(s=!0,a.container.removeClass(a.options.controlsClass)):s=!1,c.controls=!0,a.activeVideo=c}),C(v).on("click",function(t){a.preventDefault(t),a.activeVideo=c,n?c.pause():c.play()}),r.appendChild(i&&i.element||c)),r.appendChild(u),r.appendChild(p),this.setTimeout(e,[{type:"load",target:r}]),r}}),t}),function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper","./blueimp-gallery-video"],t):t(window.blueimp.helper||window.jQuery,window.blueimp.Gallery)}(function(l,t){"use strict";if(!window.postMessage)return t;var e=t.prototype;l.extend(e.options,{vimeoVideoIdProperty:"vimeo",vimeoPlayerUrl:"//player.vimeo.com/video/VIDEO_ID?api=1&player_id=PLAYER_ID",vimeoPlayerIdPrefix:"vimeo-player-",vimeoClickToPlay:!1});var n=e.textFactory||e.imageFactory,o=function(t,e,i,s){this.url=t,this.videoId=e,this.playerId=i,this.clickToPlay=s,this.element=document.createElement("div"),this.listeners={}},a=0;return l.extend(o.prototype,{on:function(t,e){return this.listeners[t]=e,this},loadAPI:function(){var t,e,i=this,s="//f.vimeocdn.com/js/froogaloop2.min.js",n=document.getElementsByTagName("script"),o=n.length;function a(){!e&&i.playOnReady&&i.play(),e=!0}for(;o;)if(n[--o].src===s){t=n[o];break}t||((t=document.createElement("script")).src=s),l(t).on("load",a),n[0].parentNode.insertBefore(t,n[0]),/loaded|complete/.test(t.readyState)&&a()},onReady:function(){var t=this;this.ready=!0,this.player.addEvent("play",function(){t.hasPlayed=!0,t.onPlaying()}),this.player.addEvent("pause",function(){t.onPause()}),this.player.addEvent("finish",function(){t.onPause()}),this.playOnReady&&this.play()},onPlaying:function(){this.playStatus<2&&(this.listeners.playing(),this.playStatus=2)},onPause:function(){this.listeners.pause(),delete this.playStatus},insertIframe:function(){var t=document.createElement("iframe");t.src=this.url.replace("VIDEO_ID",this.videoId).replace("PLAYER_ID",this.playerId),t.id=this.playerId,this.element.parentNode.replaceChild(t,this.element),this.element=t},play:function(){var t=this;this.playStatus||(this.listeners.play(),this.playStatus=1),this.ready?!this.hasPlayed&&(this.clickToPlay||window.navigator&&/iP(hone|od|ad)/.test(window.navigator.platform))?this.onPlaying():this.player.api("play"):(this.playOnReady=!0,window.$f?this.player||(this.insertIframe(),this.player=$f(this.element),this.player.addEvent("ready",function(){t.onReady()})):this.loadAPI())},pause:function(){this.ready?this.player.api("pause"):this.playStatus&&(delete this.playOnReady,this.listeners.pause(),delete this.playStatus)}}),l.extend(e,{VimeoPlayer:o,textFactory:function(t,e){var i=this.options,s=this.getItemProperty(t,i.vimeoVideoIdProperty);return s?(this.getItemProperty(t,i.urlProperty)===undefined&&(t[i.urlProperty]="//vimeo.com/"+s),a+=1,this.videoFactory(t,e,new o(i.vimeoPlayerUrl,s,i.vimeoPlayerIdPrefix+a,i.vimeoClickToPlay))):n.call(this,t,e)}}),t}),function(t){"use strict";"function"==typeof define&&define.amd?define(["./blueimp-helper","./blueimp-gallery-video"],t):t(window.blueimp.helper||window.jQuery,window.blueimp.Gallery)}(function(t,e){"use strict";if(!window.postMessage)return e;var i=e.prototype;t.extend(i.options,{youTubeVideoIdProperty:"youtube",youTubePlayerVars:{wmode:"transparent"},youTubeClickToPlay:!1});var n=i.textFactory||i.imageFactory,o=function(t,e,i){this.videoId=t,this.playerVars=e,this.clickToPlay=i,this.element=document.createElement("div"),this.listeners={}};return t.extend(o.prototype,{on:function(t,e){return this.listeners[t]=e,this},loadAPI:function(){var t,e=this,i=window.onYouTubeIframeAPIReady,s="//www.youtube.com/iframe_api",n=document.getElementsByTagName("script"),o=n.length;for(window.onYouTubeIframeAPIReady=function(){i&&i.apply(this),e.playOnReady&&e.play()};o;)if(n[--o].src===s)return;(t=document.createElement("script")).src=s,n[0].parentNode.insertBefore(t,n[0])},onReady:function(){this.ready=!0,this.playOnReady&&this.play()},onPlaying:function(){this.playStatus<2&&(this.listeners.playing(),this.playStatus=2)},onPause:function(){this.listeners.pause(),delete this.playStatus},onStateChange:function(t){switch(window.clearTimeout(this.pauseTimeout),t.data){case YT.PlayerState.PLAYING:this.hasPlayed=!0,this.onPlaying();break;case YT.PlayerState.UNSTARTED:case YT.PlayerState.PAUSED:this.pauseTimeout=i.setTimeout.call(this,this.onPause,null,500);break;case YT.PlayerState.ENDED:this.onPause()}},onError:function(t){this.listeners.error(t)},play:function(){var e=this;this.playStatus||(this.listeners.play(),this.playStatus=1),this.ready?!this.hasPlayed&&(this.clickToPlay||window.navigator&&/iP(hone|od|ad)/.test(window.navigator.platform))?this.onPlaying():this.player.playVideo():(this.playOnReady=!0,window.YT&&YT.Player?this.player||(this.player=new YT.Player(this.element,{videoId:this.videoId,playerVars:this.playerVars,events:{onReady:function(){e.onReady()},onStateChange:function(t){e.onStateChange(t)},onError:function(t){e.onError(t)}}})):this.loadAPI())},pause:function(){this.ready?this.player.pauseVideo():this.playStatus&&(delete this.playOnReady,this.listeners.pause(),delete this.playStatus)}}),t.extend(i,{YouTubePlayer:o,textFactory:function(t,e){var i=this.options,s=this.getItemProperty(t,i.youTubeVideoIdProperty);return s?(this.getItemProperty(t,i.urlProperty)===undefined&&(t[i.urlProperty]="//www.youtube.com/watch?v="+s),this.getItemProperty(t,i.videoPosterProperty)===undefined&&(t[i.videoPosterProperty]="//img.youtube.com/vi/"+s+"/maxresdefault.jpg"),this.videoFactory(t,e,new o(s,i.youTubePlayerVars,i.youTubeClickToPlay))):n.call(this,t,e)}}),e}),function(t){"use strict";"function"==typeof define&&define.amd?define(["jquery","./blueimp-gallery"],t):t(window.jQuery,window.blueimp.Gallery)}(function(l,r){"use strict";l(document).on("click","[data-gallery]",function(t){var e=l(this).data("gallery"),i=l(e),s=i.length&&i||l(r.prototype.options.container),n={onopen:function(){s.data("gallery",this).trigger("open")},onopened:function(){s.trigger("opened")},onslide:function(){s.trigger("slide",arguments)},onslideend:function(){s.trigger("slideend",arguments)},onslidecomplete:function(){s.trigger("slidecomplete",arguments)},onclose:function(){s.trigger("close")},onclosed:function(){s.trigger("closed").removeData("gallery")}},o=l.extend(s.data(),{container:s[0],index:this,event:t},n),a=l(this).closest("[data-gallery-group], body").find('[data-gallery="'+e+'"]');return o.filter&&(a=a.filter(o.filter)),new r(a,o)})});
//# sourceMappingURL=jquery.blueimp-gallery.min.js.map
{
"name": "blueimp-gallery",
"version": "2.44.0",
"version": "3.0.0",
"title": "blueimp Gallery",

@@ -5,0 +5,0 @@ "description": "blueimp Gallery is a touch-enabled, responsive and customizable image and video gallery, carousel and lightbox, optimized for both mobile and desktop web browsers. It features swipe, mouse and keyboard navigation, transition effects, slideshow functionality, fullscreen support and on-demand content loading and can be extended to display additional content types.",

@@ -10,3 +10,5 @@ # blueimp Gallery

- [Controls](#controls)
- [Contain](#contain)
- [Carousel setup](#carousel-setup)
- [Responsive images](#responsive-images)
- [Keyboard shortcuts](#keyboard-shortcuts)

@@ -30,2 +32,5 @@ - [Options](#options)

- [HTML5 video player](#html5-video-player)
- [Video controls](#video-controls)
- [Video preloading](#video-preloading)
- [Fullscreen video](#fullscreen-video)
- [Multiple video sources](#multiple-video-sources)

@@ -44,8 +49,5 @@ - [YouTube](#youtube)

- [Requirements](#requirements)
- [Browsers](#browsers)
- [Desktop browsers](#desktop-browsers)
- [Mobile browsers](#mobile-browsers)
- [Browser support](#browser-support)
- [License](#license)
- [Credits](#credits)
- [Notable forks](#notable-forks)

@@ -64,3 +66,3 @@ ## Description

Install the **blueimp-gallery** package with [NPM](https://www.npmjs.org/):
Install the `blueimp-gallery` package with [NPM](https://www.npmjs.org/):

@@ -73,3 +75,3 @@ ```sh

Copy the **css**, **img** and **js** directories to your website.
Copy the `css`, `img` and `js` directories to your website.

@@ -87,9 +89,40 @@ Include the Gallery stylesheet in the head section of your webpage:

<!-- The Gallery as lightbox dialog, should be a document body child element -->
<div id="blueimp-gallery" class="blueimp-gallery">
<div class="slides"></div>
<div
id="blueimp-gallery"
class="blueimp-gallery"
aria-label="image gallery"
aria-modal="true"
role="dialog"
>
<div class="slides" aria-live="polite"></div>
<h3 class="title"></h3>
<a class="prev">‹</a>
<a class="next">›</a>
<a class="close">×</a>
<a class="play-pause"></a>
<a
class="prev"
aria-controls="blueimp-gallery"
aria-label="previous slide"
aria-keyshortcuts="ArrowLeft"
>‹</a
>
<a
class="next"
aria-controls="blueimp-gallery"
aria-label="next slide"
aria-keyshortcuts="ArrowRight"
>›</a
>
<a
class="close"
aria-controls="blueimp-gallery"
aria-label="close"
aria-keyshortcuts="Escape"
>×</a
>
<a
class="play-pause"
aria-controls="blueimp-gallery"
aria-label="play slideshow"
aria-keyshortcuts="Space"
aria-pressed="false"
role="button"
></a>
<ol class="indicator"></ol>

@@ -99,2 +132,5 @@ </div>

Please note that each `aria-controls` attribute should have the same value as
the `id` attribute of the Gallery widget.
Include the Gallery script at the bottom of the body of your webpage:

@@ -124,3 +160,3 @@

Add the following JavaScript code after including the Gallery script, to display
the images in the Gallery lightbox on click of the links:
the images in the Gallery lightbox on click of one of those links:

@@ -131,6 +167,6 @@ ```html

event = event || window.event
var target = event.target || event.srcElement,
link = target.src ? target.parentNode : target,
options = { index: link, event: event },
links = this.getElementsByTagName('a')
var target = event.target || event.srcElement
var link = target.src ? target.parentNode : target
var options = { index: link, event: event }
var links = this.getElementsByTagName('a')
blueimp.Gallery(links, options)

@@ -143,17 +179,39 @@ }

To initialize the Gallery with visible controls, add the CSS class
**blueimp-gallery-controls** to the Gallery widget:
To initialize the Gallery with visible controls (previous slide, next slide,
etc.), add the CSS class `blueimp-gallery-controls` to the Gallery widget:
```html
<div id="blueimp-gallery" class="blueimp-gallery blueimp-gallery-controls">
<div class="slides"></div>
<h3 class="title"></h3>
<a class="prev">‹</a>
<a class="next">›</a>
<a class="close">×</a>
<a class="play-pause"></a>
<ol class="indicator"></ol>
<div
id="blueimp-gallery"
class="blueimp-gallery blueimp-gallery-controls"
aria-label="image gallery"
aria-modal="true"
role="dialog"
>
<!-- ... -->
</div>
```
Please also note that by default, a click on an image slide or any Gallery
widget element with the `toggle` class will toggle the display of the Gallery
controls.
### Contain
To stretch smaller images to the dimensions of the Gallery container while
keeping their aspect ratio, add the CSS class `blueimp-gallery-contain` to the
Gallery widget:
```html
<div
id="blueimp-gallery"
class="blueimp-gallery blueimp-gallery-contain"
aria-label="image gallery"
aria-modal="true"
role="dialog"
>
<!-- ... -->
</div>
```
### Carousel setup

@@ -163,4 +221,4 @@

[lightbox setup](#lightbox-setup) and add the CSS class
**blueimp-gallery-carousel** to the Gallery widget and remove the child element
with the **close** class, or add a new Gallery widget with a different **id** to
`blueimp-gallery-carousel` to the Gallery widget and remove the child element
with the `close` class, or add a new Gallery widget with a different `id` to
your webpage:

@@ -173,8 +231,25 @@

class="blueimp-gallery blueimp-gallery-carousel"
aria-label="image carousel"
>
<div class="slides"></div>
<div class="slides" aria-live="off"></div>
<h3 class="title"></h3>
<a class="prev">‹</a>
<a class="next">›</a>
<a class="play-pause"></a>
<a
class="prev"
aria-controls="blueimp-gallery-carousel"
aria-label="previous slide"
>‹</a
>
<a
class="next"
aria-controls="blueimp-gallery-carousel"
aria-label="next slide"
>›</a
>
<a
class="play-pause"
aria-controls="blueimp-gallery-carousel"
aria-label="play slideshow"
aria-pressed="true"
role="button"
></a>
<ol class="indicator"></ol>

@@ -196,2 +271,75 @@ </div>

### Responsive images
The Gallery supports the concept of
[responsive images](https://developer.mozilla.org/en-US/docs/Learn/HTML/Multimedia_and_embedding/Responsive_images)
with the `srcset`, `sizes` and `sources` object properties, e.g. using the
[API](#api):
```js
var gallery = blueimp.Gallery([
{
title: 'Banana',
href: 'https://example.org/images/banana-1024w.jpg',
srcset:
'https://example.org/images/banana-800w.jpg 800w,' +
'https://example.org/images/banana-1024w.jpg 1024w,' +
'https://example.org/images/banana-1600w.jpg 1600w',
sizes: '(min-width: 990px) 990px, 100vw',
thumbnail: 'https://example.org/images/banana-75.jpg'
},
{
title: 'Apple',
href: 'https://example.org/images/apple.png',
sources: [
{
type: 'image/svg+xml',
srcset: 'https://example.org/images/apple.svg'
},
{
type: 'image/webp',
srcset: 'https://example.org/images/apple.webp'
}
]
}
])
```
With link elements, those same properties can be defined via `data-srcset`,
`data-sizes` and `data-sources` attributes:
```html
<div id="links">
<a
title="Banana"
href="images/banana-1024w.jpg"
data-srcset="images/banana-800w.jpg 800w,
images/banana-1024w.jpg 1024w,
images/banana-1600w.jpg 1600w"
data-sizes="(min-width: 990px) 990px, 100vw"
>
<img src="images/banana-75.jpg" alt="Banana" />
</a>
<a
title="Apple"
href="images/apple.png"
data-sources='[
{
"type": "image/svg+xml",
"srcset": "images/apple.svg"
},
{
"type": "image/webp",
"srcset": "images/apple.webp"
}
]'
>Apple</a
>
</div>
```
Please note that `data-sources` must be a valid
[JSON](https://developer.mozilla.org/en-US/docs/Glossary/JSON) `string` listing
the sources array.
## Keyboard shortcuts

@@ -201,10 +349,10 @@

- **Return**: Toggle controls visibility.
- **Esc**: Close the Gallery lightbox.
- **Space**: Toggle the slideshow (play/pause).
- **Left**: Move to the previous slide.
- **Right**: Move to the next slide.
- `Enter`: Toggle controls visibility.
- `Escape`: Close the Gallery lightbox.
- `Space`: Toggle the slideshow (play/pause).
- `ArrowLeft`: Move to the previous slide.
- `ArrowRight`: Move to the next slide.
Please note that setting the **carousel** option to **true** disables the
keyboard shortcuts by default.
Please note that setting the `carousel` option to `true` disables the keyboard
shortcuts by default.

@@ -237,4 +385,14 @@ ## Options

playingClass: 'blueimp-gallery-playing',
// The class to add when the browser supports SVG as img (or background):
svgasimgClass: 'blueimp-gallery-svgasimg',
// The class to add when the browser supports SMIL (animated SVGs):
smilClass: 'blueimp-gallery-smil',
// The class for all slides:
slideClass: 'slide',
// The slide class for the active (current index) slide:
slideActiveClass: 'slide-active',
// The slide class for the previous (before current index) slide:
slidePrevClass: 'slide-prev',
// The slide class for the next (after current index) slide:
slideNextClass: 'slide-next',
// The slide class for loading elements:

@@ -264,4 +422,8 @@ slideLoadingClass: 'slide-loading',

urlProperty: 'href',
// The list object property (or data attribute) with the object srcset URL(s):
srcsetProperty: 'urlset',
// The list object property (or data attribute) with the object srcset:
srcsetProperty: 'srcset',
// The list object property (or data attribute) with the object sizes:
sizesProperty: 'sizes',
// The list object property (or data attribute) with the object sources:
sourcesProperty: 'sources',
// The gallery listens for transitionend events before triggering the

@@ -273,10 +435,4 @@ // opened and closed events, unless the following option is set to false:

clearSlides: true,
// Defines if images should be stretched to fill the available space,
// while maintaining their aspect ratio (will only be enabled for browsers
// supporting background-size="contain", which excludes IE < 9).
// Set to "cover", to make images cover all available space (requires
// support for background-size="cover", which excludes IE < 9):
stretchImages: false,
// Toggle the controls on pressing the Return key:
toggleControlsOnReturn: true,
// Toggle the controls on pressing the Enter key:
toggleControlsOnEnter: true,
// Toggle the controls on slide click:

@@ -286,5 +442,5 @@ toggleControlsOnSlideClick: true,

toggleSlideshowOnSpace: true,
// Navigate the gallery by pressing left and right on the keyboard:
// Navigate the gallery by pressing the ArrowLeft and ArrowRight keys:
enableKeyboardNavigation: true,
// Close the gallery on pressing the ESC key:
// Close the gallery on pressing the Escape key:
closeOnEscape: true,

@@ -295,2 +451,4 @@ // Close the gallery when clicking on an empty slide area:

closeOnSwipeUpOrDown: true,
// Close the gallery when the URL hash changes:
closeOnHashChange: true,
// Emulate touch events on mouse-pointer devices such as desktop browsers:

@@ -395,4 +553,4 @@ emulateTouchEvents: true,

If the **carousel** option is **true**, the following options are set to
different default values:
If the `carousel` option is `true`, the following options are set to different
default values:

@@ -402,3 +560,3 @@ ```js

hidePageScrollbars: false,
toggleControlsOnReturn: false,
toggleControlsOnEnter: false,
toggleSlideshowOnSpace: false,

@@ -409,2 +567,3 @@ enableKeyboardNavigation: false,

closeOnSwipeUpOrDown: false,
closeOnHashChange: false,
disableScroll: false,

@@ -416,3 +575,3 @@ startSlideshow: true

The options object passed to the Gallery function extends the default options
and also those options set via **carousel** mode.
and also those options set via `carousel` mode.

@@ -445,3 +604,3 @@ ### Indicator options

// Defines if the gallery should open in fullscreen mode:
fullScreen: false
fullscreen: false
}

@@ -464,6 +623,14 @@ ```

videoPlayingClass: 'video-playing',
// The class for video content displayed in an iframe:
videoIframeClass: 'video-iframe',
// The class for the video cover element:
videoCoverClass: 'video-cover',
// The class for the video play control:
videoPlayClass: 'video-play',
// Play videos inline by default:
videoPlaysInline: true,
// The list object property (or data attribute) for video preload:
videoPreloadProperty: 'preload',
// The list object property (or data attribute) for the video poster URL:
videoPosterProperty: 'poster',
// The list object property (or data attribute) for the video sources array:
videoSourcesProperty: 'sources'
videoPosterProperty: 'poster'
}

@@ -508,4 +675,6 @@ ```

The widget **container** option can be set as id string (with "#" as prefix) or
element node, so the following are equivalent:
The widget `container`, `slidesContainer`, `titleElement` and
`indicatorContainer` options can be set as
[CSS selector](https://developer.mozilla.org/en-US/docs/Glossary/CSS_Selector)
or `HTMLElement` node, so the following are equivalent:

@@ -524,19 +693,10 @@ ```js

The **slidesContainer**, **titleElement** and **indicatorContainer** options can
also be defined using a tag name, which selects the first tag of this kind found
inside of the widget container:
CSS selectors are passed as argument to
[querySelectorAll](https://developer.mozilla.org/en-US/docs/Web/API/Document/querySelectorAll),
which is supported by IE8+ and all modern web browsers and queried with
[getElementById](https://developer.mozilla.org/en-US/docs/Web/API/Document/getElementById)
or
[getElementsByTagName](https://developer.mozilla.org/en-US/docs/Web/API/Element/getElementsByTagName)
in older browsers.
```js
var options = {
slidesContainer: 'div',
titleElement: 'h3',
indicatorContainer: 'ol'
}
```
It is also possible to define the container and element options with a more
complex
[querySelector](https://developer.mozilla.org/en-US/docs/Web/API/document.querySelector),
which is supported by IE8+ and all modern web browsers.
If the helper script is replaced with [jQuery](https://jquery.com/), the

@@ -549,4 +709,4 @@ container and element options can be any valid jQuery selector.

element are accessed.
For example, the **urlProperty** is by default set to **href**. This allows to
define link elements with **href** or **data-href** attributes:
For example, the `urlProperty` is by default set to `href`. This allows to
define link elements with `href` or `data-href` attributes:

@@ -560,3 +720,3 @@ ```html

If the links are passed as JavaScript array, it is also possible to define
If the links are provided as JavaScript array, it is also possible to define
nested property names, by using the native JavaScript accessor syntax for the

@@ -608,4 +768,4 @@ property string:

title: 'Banana',
type: 'image/jpeg',
href: 'https://example.org/images/banana.jpg',
type: 'image/jpeg',
thumbnail: 'https://example.org/thumbnails/banana.jpg'

@@ -615,4 +775,4 @@ },

title: 'Apple',
type: 'image/jpeg',
href: 'https://example.org/images/apple.jpg',
type: 'image/jpeg',
thumbnail: 'https://example.org/thumbnails/apple.jpg'

@@ -624,15 +784,15 @@ }

The URL property name defined by each list object can be configured via the
**urlProperty** option. By default, it is set to **href**, which allows to pass
a list of HTML link elements as first argument.
`urlProperty` option. By default, it is set to `href`, which allows to pass a
list of HTML link elements as first argument.
For images, the **thumbnail** property defines the URL of the image thumbnail,
For images, the `thumbnail` property defines the URL of the image thumbnail,
which is used for the indicator navigation displayed at the bottom of the
Gallery, if the controls are visible.
The object returned by executing the Gallery function (the **gallery** variable
in the example code above) is a new instance of the Gallery and allows to access
The object returned by executing the Gallery function (the `gallery` variable in
the example code above) is a new instance of the Gallery and allows to access
the public [API methods](#api-methods) provided by the Gallery.
The Gallery initialization function returns **false** if the given list was
empty, the Gallery widget is missing, or the browser doesn't pass the
functionality test.
The Gallery initialization function returns `false` if the given list was empty,
the Gallery widget is missing, or the browser doesn't pass the functionality
test.

@@ -660,3 +820,3 @@ ### API methods

// Start an automatic slideshow with the interval in milliseconds (optional):
// Start an automatic slideshow with the (optional) interval in milliseconds:
gallery.play(interval)

@@ -685,4 +845,4 @@

title: 'Fruits',
type: 'video/mp4',
href: 'https://example.org/videos/fruits.mp4',
type: 'video/mp4',
poster: 'https://example.org/images/fruits.jpg'

@@ -692,4 +852,4 @@ },

title: 'Banana',
type: 'image/jpeg',
href: 'https://example.org/images/banana.jpg',
type: 'image/jpeg',
thumbnail: 'https://example.org/thumbnails/banana.jpg'

@@ -700,5 +860,5 @@ }

The Gallery uses the **type** property to determine the content type of the
object to display.
If the type property is empty or doesn't exist, the default type **image** is
The Gallery uses the `type` property to determine the content type of the object
to display.
If the type property is empty or doesn't exist, the default type `image` is
assumed.

@@ -709,11 +869,91 @@ Objects with a video type will be displayed in a

For videos, the **poster** property defines the URL of the poster image to
For videos, the `poster` property defines the URL of the poster image to
display, before the video is started.
#### Video controls
To start video playback, you can either click on the video play icon or on the
video slide itself.
Starting the video playback enables the native HTML5 video
[controls](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/video#attr-controls).
To toggle the Gallery controls (previous slide, next slide, etc.) instead of
starting video playback on click of a video slide, add the `toggle` class to the
video cover element using the `videoCoverClass` Gallery option:
```js
blueimp.Gallery(
[
{
title: 'Fruits',
type: 'video/mp4',
href: 'https://example.org/videos/fruits.mp4',
poster: 'https://example.org/images/fruits.jpg'
}
],
{
videoCoverClass: 'video-cover toggle'
}
)
```
#### Video preloading
You can set the `preload` property of a Gallery video object to a valid value
defined by the HTML5 video
[preload](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/video#attr-preload)
attribute:
- `none`: Indicates that the video should not be preloaded.
- `metadata`: Indicates that only video metadata (e.g. length) is fetched.
- `auto`: Indicates that the whole video file can be preloaded.
```js
blueimp.Gallery([
{
title: 'Fruits',
type: 'video/mp4',
href: 'https://example.org/videos/fruits.mp4',
preload: 'auto'
}
])
```
By default, `preload` is set to `none` to save on network bandwidth consumption.
#### Fullscreen video
By default, videos are displayed with the HTML5 video
[playsinline](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/video#attr-playsinline)
attribute set, which indicates that the video is to be played inline.
To disable this behavior, you can set the Gallery option `videoPlaysInline` to
`false`:
```js
blueimp.Gallery(
[
{
title: 'Fruits',
type: 'video/mp4',
href: 'https://example.org/videos/fruits.mp4',
poster: 'https://example.org/images/fruits.jpg'
}
],
{
videoPlaysInline: false
}
)
```
Please note that this attribute only has an effect on some mobile browsers, e.g.
Safari on iOS 10 and later.
However, all browsers provide video controls to switch between fullscreen and
inline mode on user request.
#### Multiple video sources
To provide multiple video formats, the **sources** property of a list object can
be set to an array of objects with **href** and **type** properties for each
video source. The first video format in the list that the browser can play will
be displayed:
To provide multiple video formats, the `sources` property of a list object can
be set to an array of objects with `type` and `src` properties for each video
source. The first video format in the list that the browser can play will be
displayed:

@@ -724,14 +964,14 @@ ```js

title: 'Fruits',
type: 'video/*',
poster: 'https://example.org/images/fruits.jpg',
type: 'video',
sources: [
{
href: 'https://example.org/videos/fruits.mp4',
type: 'video/mp4'
type: 'video/mp4',
src: 'https://example.org/videos/fruits.mp4'
},
{
href: 'https://example.org/videos/fruits.ogg',
type: 'video/ogg'
type: 'video/ogg',
src: 'https://example.org/videos/fruits.ogv'
}
]
],
poster: 'https://example.org/images/fruits.jpg'
}

@@ -741,4 +981,5 @@ ])

It is also possible to define the video sources as data-attribute on a link
element in [JSON](https://developer.mozilla.org/en-US/docs/JSON) array format:
It is also possible to define the video sources as `data-sources` attribute as a
[JSON](https://developer.mozilla.org/en-US/docs/Glossary/JSON) `string` listing
the sources array:

@@ -748,7 +989,16 @@ ```html

<a
href="https://example.org/videos/fruits.mp4"
title="Fruits"
type="video/mp4"
href="https://example.org/videos/fruits.mp4"
data-sources='[
{
"type": "video/mp4",
"src": "videos/fruits.mp4"
},
{
"type": "video/ogg",
"src": "videos/fruits.ogv"
}
]'
data-poster="https://example.org/images/fruits.jpg"
data-sources='[{"href": "https://example.org/videos/fruits.mp4", "type": "video/mp4"}, {"href": "https://example.org/videos/fruits.ogg", "type": "video/ogg"}]'
>Fruits</a

@@ -762,4 +1012,4 @@ >

The Gallery can display [YouTube](https://www.youtube.com/) videos for Gallery
items with a **type** of **text/html** and a **youtube** property (configurable
via [YouTube options](#youtube-options)) with the YouTube video-ID:
items with a `type` of `text/html` and a `youtube` property (configurable via
[YouTube options](#youtube-options)) with the YouTube video-ID:

@@ -770,12 +1020,6 @@ ```js

title: 'A YouYube video',
type: 'text/html',
href: 'https://www.youtube.com/watch?v=VIDEO_ID',
type: 'text/html',
youtube: 'VIDEO_ID',
poster: 'https://img.youtube.com/vi/VIDEO_ID/maxresdefault.jpg'
},
{
title: 'Banana',
href: 'https://example.org/images/banana.jpg',
type: 'image/jpeg',
thumbnail: 'https://example.org/thumbnails/banana.jpg'
}

@@ -789,3 +1033,3 @@ ])

Please note that the Gallery YouTube integration requires a browser with
[postMessage](https://developer.mozilla.org/en-US/docs/Web/API/window.postMessage)
[postMessage](https://developer.mozilla.org/en-US/docs/Web/API/Window/postMessage)
support, which excludes IE7.

@@ -796,3 +1040,3 @@

The Gallery can display [Vimeo](https://vimeo.com/) videos for Gallery items
with a **type** of **text/html** and a **vimeo** property (configurable via
with a `type` of `text/html` and a `vimeo` property (configurable via
[Vimeo options](#vimeo-options)) with the Vimeo video-ID:

@@ -804,12 +1048,6 @@

title: 'A Vimeo video',
type: 'text/html',
href: 'https://vimeo.com/VIDEO_ID',
type: 'text/html',
vimeo: 'VIDEO_ID',
poster: 'https://secure-b.vimeocdn.com/ts/POSTER_ID.jpg'
},
{
title: 'Banana',
href: 'https://example.org/images/banana.jpg',
type: 'image/jpeg',
thumbnail: 'https://example.org/thumbnails/banana.jpg'
}

@@ -823,3 +1061,3 @@ ])

Please note that the Gallery Vimeo integration requires a browser with
[postMessage](https://developer.mozilla.org/en-US/docs/Web/API/window.postMessage)
[postMessage](https://developer.mozilla.org/en-US/docs/Web/API/Window/postMessage)
support, which excludes IE7.

@@ -835,11 +1073,42 @@

```html
<div id="blueimp-gallery" class="blueimp-gallery">
<div class="slides"></div>
<div
id="blueimp-gallery"
class="blueimp-gallery"
aria-label="image gallery"
aria-modal="true"
role="dialog"
>
<div class="slides" aria-live="polite"></div>
<h3 class="title"></h3>
<!-- The placeholder for the description label: -->
<p class="description"></p>
<a class="prev">‹</a>
<a class="next">›</a>
<a class="close">×</a>
<a class="play-pause"></a>
<a
class="prev"
aria-controls="blueimp-gallery"
aria-label="previous slide"
aria-keyshortcuts="ArrowLeft"
>‹</a
>
<a
class="next"
aria-controls="blueimp-gallery"
aria-label="next slide"
aria-keyshortcuts="ArrowRight"
>›</a
>
<a
class="close"
aria-controls="blueimp-gallery"
aria-label="close"
aria-keyshortcuts="Escape"
>×</a
>
<a
class="play-pause"
aria-controls="blueimp-gallery"
aria-label="play slideshow"
aria-keyshortcuts="Space"
aria-pressed="false"
role="button"
></a>
<ol class="indicator"></ol>

@@ -880,3 +1149,3 @@ </div>

Finally, initialize the Gallery with an onslide callback option, to set the
Finally, initialize the Gallery with an `onslide` callback option, to set the
element content based on the information from the current link:

@@ -900,15 +1169,14 @@

By extending the Gallery prototype with new factory methods, additional content
types can be displayed. By default, blueimp Gallery provides the
**imageFactory** and **videoFactory** methods for **image** and **video**
content types respectively.
types can be displayed. By default, blueimp Gallery provides the `imageFactory`
and `videoFactory` methods for `image` and `video` content types respectively.
The Gallery uses the **type** property of each content object to determine which
factory method to use. The **type** defines the
The Gallery uses the `type` property of each content object to determine which
factory method to use. The `type` defines the
[Internet media type](https://en.wikipedia.org/wiki/Internet_media_type) of the
content object and is composed of two or more parts: A type, a subtype, and zero
or more optional parameters, e.g. **text/html; charset=UTF-8** for an HTML
or more optional parameters, e.g. `text/html; charset=UTF-8` for an HTML
document with UTF-8 encoding.
The main type (the string in front of the slash, **text** in the example above)
is concatenated with the string **Factory** to create the factory method name,
e.g. **textFactory**.
The main type (the string in front of the slash, `text` in the example above) is
concatenated with the string `Factory` to create the factory method name, e.g.
`textFactory`.

@@ -925,3 +1193,3 @@ #### Example HTML text factory implementation

Extend the Gallery prototype with the **textFactory** method:
Extend the Gallery prototype with the `textFactory` method:

@@ -949,3 +1217,3 @@ ```js

Next, add the **text-content** class to the Gallery CSS:
Next, add the `text-content` class to the Gallery CSS:

@@ -969,9 +1237,9 @@ ```css

title: 'Noodle soup',
href: 'https://example.org/text/noodle-soup.html',
type: 'text/html'
type: 'text/html',
href: 'https://example.org/text/noodle-soup.html'
},
{
title: 'Tomato salad',
href: 'https://example.org/text/tomato-salad.html',
type: 'text/html'
type: 'text/html',
href: 'https://example.org/text/tomato-salad.html'
}

@@ -986,3 +1254,3 @@ ])

The blueimp Gallery jQuery plugin registers a global click handler to open links
with **data-gallery** attribute in the Gallery lightbox.
with `data-gallery` attribute in the Gallery lightbox.

@@ -994,7 +1262,11 @@ To use it, follow the [lightbox setup](#lightbox-setup) guide, but replace the

```html
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<script
src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"
integrity="sha384-nvAa0+6Qg9clwYCGGPpDQLVpLNn0fRaROjHqs13t4Ggj3Ez50XnGQqc/r8MhnRDZ"
crossorigin="anonymous"
></script>
<script src="js/jquery.blueimp-gallery.min.js"></script>
```
Next, add the attribute **data-gallery** to your Gallery links:
Next, add the attribute `data-gallery` to your Gallery links:

@@ -1015,3 +1287,3 @@ ```html

The onclick handler from the [lightbox setup](#lightbox-setup) guide is not
The `onclick` handler from the [lightbox setup](#lightbox-setup) guide is not
required and can be removed.

@@ -1025,3 +1297,3 @@

The jQuery plugin also introduces the additional **filter** option, which is
The jQuery plugin also introduces the additional `filter` option, which is
applied to the Gallery links via

@@ -1035,11 +1307,39 @@ [jQuery's filter method](https://api.jquery.com/filter/) and allows to remove

class="blueimp-gallery"
aria-label="image gallery"
aria-modal="true"
role="dialog"
data-start-slideshow="true"
data-filter=":even"
>
<div class="slides"></div>
<div class="slides" aria-live="off"></div>
<h3 class="title"></h3>
<a class="prev">‹</a>
<a class="next">›</a>
<a class="close">×</a>
<a class="play-pause"></a>
<a
class="prev"
aria-controls="blueimp-gallery"
aria-label="previous slide"
aria-keyshortcuts="ArrowLeft"
>‹</a
>
<a
class="next"
aria-controls="blueimp-gallery"
aria-label="next slide"
aria-keyshortcuts="ArrowRight"
>›</a
>
<a
class="close"
aria-controls="blueimp-gallery"
aria-label="close"
aria-keyshortcuts="Escape"
>×</a
>
<a
class="play-pause"
aria-controls="blueimp-gallery"
aria-label="play slideshow"
aria-keyshortcuts="Space"
aria-pressed="true"
role="button"
></a>
<ol class="indicator"></ol>

@@ -1049,4 +1349,4 @@ </div>

This will initialize the Gallery with the option **startSlideshow** set to
**true**.
This will initialize the Gallery with the option `startSlideshow` set to
`true`.
It will also filter the Gallery links so that only links with an even index

@@ -1057,5 +1357,5 @@ number will be included.

If the **data-gallery** attribute value is a valid id string (e.g.
If the `data-gallery` attribute value is a valid id string (e.g.
"#blueimp-gallery"), it is used as container option.
Setting **data-gallery** to a non-empty string also allows to group links into
Setting `data-gallery` to a non-empty string also allows to group links into
different sets of Gallery images:

@@ -1098,7 +1398,7 @@

This will open the links with the **data-gallery** attribute
**#blueimp-gallery-fruits** in the Gallery widget with the id
**blueimp-gallery-fruits**, and the links with the **data-gallery** attribute
**#blueimp-gallery-vegetables** in the Gallery widget with the id
**blueimp-gallery-vegetables**.
This will open the links with the `data-gallery` attribute
`#blueimp-gallery-fruits` in the Gallery widget with the id
`blueimp-gallery-fruits`, and the links with the `data-gallery` attribute
`#blueimp-gallery-vegetables` in the Gallery widget with the id
`blueimp-gallery-vegetables`.

@@ -1171,3 +1471,3 @@ #### Gallery object

The helper script can be replaced by [jQuery](https://jquery.com/) v. 1.7+.
The fullscreen, indicator, video, youtube and vimeo source files are optional if
The fullscreen, indicator, video, YouTube and Vimeo source files are optional if
their functionality is not required.

@@ -1177,6 +1477,10 @@

1.7+ and the basic Gallery script, while the fullscreen, indicator, video,
youtube and vimeo source files are also optional:
YouTube and Vimeo source files are also optional:
```html
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<script
src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"
integrity="sha384-nvAa0+6Qg9clwYCGGPpDQLVpLNn0fRaROjHqs13t4Ggj3Ez50XnGQqc/r8MhnRDZ"
crossorigin="anonymous"
></script>
<script src="js/blueimp-gallery.js"></script>

@@ -1194,28 +1498,17 @@ <script src="js/blueimp-gallery-fullscreen.js"></script>

## Browsers
## Browser support
blueimp Gallery has been tested with and supports the following browsers:
### Desktop browsers
- Google Chrome 14.0+
- Apple Safari 4.0+
- Mozilla Firefox 4.0+
- Chrome 14.0+
- Safari 4.0+
- Firefox 4.0+
- Opera 10.0+
- Microsoft Internet Explorer 7.0+
- Microsoft Edge 41.0+
_Please note:_
Microsoft Edge version 40 has a query selector bug which prevents the Gallery
lightbox demo from opening the image view. This has been fixed in Microsoft Edge
version 41 and later.
Thanks to Kenneth G. Chin for the information.
### Mobile browsers
- Apple Safari on iOS 6.0+
- Google Chrome on iOS 6.0+
- Google Chrome on Android 4.0+
- Mobile Safari 6.0+
- Mobile Chrome 30.0+
- Default Browser on Android 2.3+
- Opera Mobile 12.0+
- Edge 74+
- Edge Legacy 41.0+
- Internet Explorer 7.0+

@@ -1230,5 +1523,1 @@ ## License

[Swipe](https://github.com/thebird/swipe/) library.
## Notable Forks
- [Rollup bundled version by Khoa Nguyen](https://github.com/khoanguyen96/Gallery/tree/rewrite-js)

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc