/** * Galleria - v1.6.1 2019-10-17 * * * Copyright (c) 2010 - 2019 worse is better UG * Licensed under the MIT License. */ !function(a,b){"function"==typeof define&&define.amd?define(["../galleria","jquery"],function(c,d){return b(a,c,d)}):"object"==typeof module&&module.exports?module.exports=b(a,require("galleria"),require("jquery")):b(a,a.Galleria,a.jQuery)}(window,function(a,b,c){return b.addTheme({name:"azur",version:1.6,author:"Galleria",css:"galleria.azur.css",defaults:{transition:"fade",transitionSpeed:500,imageCrop:!0,thumbCrop:"height",idleMode:"hover",idleSpeed:500,fullscreenTransition:!1,_locale:{show_captions:"Show captions",hide_captions:"Hide captions",play:"Play slideshow",pause:"Pause slideshow",enter_fullscreen:"Enter fullscreen",exit_fullscreen:"Exit fullscreen",next:"Next image",prev:"Previous image",showing_image:"Showing image %s of %s"},_toggleCaption:!0,_showCaption:!0,_showTooltip:!0},init:function(d){b.requires(1.6,"This version of Azur theme requires Galleria version 1.6 or later"),this.addElement("bar","fullscreen","play","progress").append({stage:"progress",container:"bar",bar:["fullscreen","play","thumbnails-container"]}).prependChild("stage","info").appendChild("container","tooltip");var e=this,f=a.document,g=d._locale,h="getContext"in f.createElement("canvas");!function(){if(!h){e.addElement("progressbar").appendChild("progress","progressbar"),e.$("progress").addClass("nocanvas");var a=e.$("progress").width();return void e.bind("progress",function(b){e.$("progressbar").width(b.percent/100*a)})}var b=f.createElement("canvas"),d=b.getContext("2d"),g=function(a){return a*(Math.PI/180)},i=function(a,b){d.strokeStyle=b||"#000",d.lineWidth=3,d.clearRect(0,0,24,24),d.beginPath(),d.arc(12,12,10,g(-90),g(a-90),!1),d.stroke(),d.closePath()};b.width=24,b.height=24,c(b).css({zIndex:1e4,position:"absolute",right:10,top:10}).appendTo(e.get("container")),e.bind("progress",function(a){c(b).fadeIn(200),i(3.6*a.percent,"rgba(255,255,255,.7)")}),e.bind("pause",function(){c(b).fadeOut(200,function(){d.clearRect(0,0,24,24)})})}(),function(){var b=function(){var b="RequestAnimationFrame";return a.requestAnimationFrame||a["webkit"+b]||a["moz"+b]||a["o"+b]||a["ms"+b]||function(b){a.setTimeout(b,1e3/60)}}();if(!h)return void e.$("loader").addClass("nocanvas");var d=f.createElement("canvas"),g=d.getContext("2d"),i=Math,j=function(a,b,c){var d=c?-2:2;a.translate(b/d,b/d)},k=28;c(d).hide().appendTo(e.get("loader")).fadeIn(500);var l=function(a,b){var c;a.clearRect(0,0,48,48),a.lineWidth=1.5;for(var d=0;d<28;d++)c=d+b>=28?d-28+b:d+b,a.strokeStyle="rgba(255,255,255,"+i.max(0,c/28)+")",a.lineWidth=1,a.beginPath(),a.moveTo(24,8),a.lineTo(24,0),a.stroke(),j(a,48,!1),a.rotate(360/28*i.PI/180),j(a,48,!0);a.save(),j(a,48,!1),a.rotate(360/28/8*-1*i.PI/180),j(a,48,!0)};!function a(){b(a),l(g,k),k=0===k?28:k-1}()}();var i=b.IE<9?{bottom:-100}:{bottom:-50,opacity:0},j=b.IE<9?{top:-20}:{opacity:0,top:-20};this.bind("play",function(){this.$("play").addClass("pause"),h||this.$("progress").show()}).bind("pause",function(){this.$("play").removeClass("pause"),h||this.$("progress").hide()}).bind("loadstart",function(a){a.cached||this.$("loader").show()}).bind("loadfinish",function(a){h?this.$("loader").fadeOut(100):this.$("loader").hide()}),this.addIdleState(this.get("info"),i,b.IE<9?{}:{opacity:1},!0).addIdleState(this.get("image-nav-left"),{opacity:0,left:0},{opacity:1},!0).addIdleState(this.get("image-nav-right"),{opacity:0,right:0},{opacity:1},!0).addIdleState(this.get("counter"),j,b.IE<9?{}:{opacity:.9},!0),this.$("fullscreen").on("click:fast",function(a){a.preventDefault(),e.toggleFullscreen()}),this.$("play").on("click:fast",function(a){a.preventDefault(),e.playToggle()}),d._toggleCaption&&(this.$("info").addClass("toggler"),this.addElement("captionopen").appendChild("stage","captionopen"),this.addElement("captionclose").appendChild("info","captionclose"),this.$("captionopen").on("click:fast",function(){e.$("info").addClass("open"),c(this).hide()}).html(g.show_captions),this.bind("loadstart",function(){this.$("captionopen").toggle(!e.$("info").hasClass("open")&&this.hasInfo())}),this.$("captionclose").on("click:fast",function(){e.$("info").removeClass("open"),e.hasInfo()&&e.$("captionopen").show()}).html("×"),d._showCaption&&this.$("captionopen").trigger("click:fast")),d._showTooltip&&this.bindTooltip({fullscreen:function(){return e.isFullscreen()?g.exit_fullscreen:g.enter_fullscreen},play:function(){return e.isPlaying()?g.pause:g.play},captionclose:g.hide_captions,"image-nav-right":g.next,"image-nav-left":g.prev,counter:function(){return g.showing_image.replace(/\%s/,e.getIndex()+1).replace(/\%s/,e.getDataLength())}})}}),b});