text: /*! dgtUIkit 3.1.7 | http://www.getuikit.com | (c) 2014 - 2019 YOOtheme | MIT License */
  
  !function(t,i){"object"==typeof exports&&"undefined"!=typeof module?module.exports=i(require("uikit-util")):"function"==typeof define&&define.amd?define("uikitslideshow",["uikit-util"],i):(t=t||self).dgtUIkitSlideshow=i(t.dgtUIkit.util)}(this,function(f){"use strict";var t={connected:function(){f.hasClass(this.$el,this.$name)||f.addClass(this.$el,this.$name)}},i={slide:{show:function(t){return[{transform:e(-100*t)},{transform:e()}]},percent:function(t){return n(t)},translate:function(t,i){return[{transform:e(-100*i*t)},{transform:e(100*i*(1-t))}]}}};function n(t){return Math.abs(f.css(t,"transform").split(",")[4]/t.offsetWidth)||0}function e(t,i){return void 0===t&&(t=0),void 0===i&&(i="%"),t+=t?i:"",f.isIE?"translateX("+t+")":"translate3d("+t+", 0, 0)"}function s(t){return"scale3d("+t+", "+t+", 1)"}function c(t,i,e){f.trigger(t,f.createEvent(i,!1,!1,e))}var r={mixins:[{mixins:[{props:{autoplay:Boolean,autoplayInterval:Number,pauseOnHover:Boolean},data:{autoplay:!1,autoplayInterval:7e3,pauseOnHover:!0},connected:function(){this.autoplay&&this.startAutoplay()},disconnected:function(){this.stopAutoplay()},update:function(){f.attr(this.slides,"tabindex","-1")},events:[{name:"visibilitychange",el:document,filter:function(){return this.autoplay},handler:function(){document.hidden?this.stopAutoplay():this.startAutoplay()}}],methods:{startAutoplay:function(){var t=this;this.stopAutoplay(),this.interval=setInterval(function(){return(!t.draggable||!f.$(":focus",t.$el))&&(!t.pauseOnHover||!f.matches(t.$el,":hover"))&&!t.stack.length&&t.show("next")},this.autoplayInterval)},stopAutoplay:function(){this.interval&&clearInterval(this.interval)}}},{props:{draggable:Boolean},data:{draggable:!0,threshold:10},created:function(){var n=this;["start","move","end"].forEach(function(t){var e=n[t];n[t]=function(t){var i=f.getEventPos(t).x*(f.isRtl?-1:1);n.prevPos=i!==n.pos?n.pos:n.prevPos,n.pos=i,e(t)}})},events:[{name:f.pointerDown,delegate:function(){return this.selSlides},handler:function(t){!this.draggable||!f.isTouch(t)&&function(t){return!t.children.length&&t.childNodes.length}(t.target)||0<t.button||this.length<2||this.start(t)}},{name:"touchmove",passive:!1,handler:"move",delegate:function(){return this.selSlides}},{name:"dragstart",handler:function(t){t.preventDefault()}}],methods:{start:function(){var t=this;this.drag=this.pos,this._transitioner?(this.percent=this._transitioner.percent(),this.drag+=this._transitioner.getDistance()*this.percent*this.dir,this._transitioner.cancel(),this._transitioner.translate(this.percent),this.dragging=!0,this.stack=[]):this.prevIndex=this.index;var i="touchmove"!==f.pointerMove?f.on(document,f.pointerMove,this.move,{passive:!1}):f.noop;this.unbindMove=function(){i(),t.unbindMove=null},f.on(window,"scroll",this.unbindMove),f.on(document,f.pointerUp,this.end,!0),f.css(this.list,"userSelect","none")},move:function(t){var i=this;if(this.unbindMove){var e=this.pos-this.drag;if(!(0==e||this.prevPos===this.pos||!this.dragging&&Math.abs(e)<this.threshold)){f.css(this.list,"pointerEvents","none"),t.cancelable&&t.preventDefault(),this.dragging=!0,this.dir=e<0?1:-1;for(var n=this.slides,s=this.prevIndex,r=Math.abs(e),o=this.getIndex(s+this.dir,s),a=this._getDistance(s,o)||n[s].offsetWidth;o!==s&&a<r;)this.drag-=a*this.dir,s=o,r-=a,o=this.getIndex(s+this.dir,s),a=this._getDistance(s,o)||n[s].offsetWidth;this.percent=r/a;var h,d=n[s],u=n[o],c=this.index!==o,l=s===o;[this.index,this.prevIndex].filter(function(t){return!f.includes([o,s],t)}).forEach(function(t){f.trigger(n[t],"itemhidden",[i]),l&&(h=!0,i.prevIndex=s)}),(this.index===s&&this.prevIndex!==s||h)&&f.trigger(n[this.index],"itemshown",[this]),c&&(this.prevIndex=s,this.index=o,l||f.trigger(d,"beforeitemhide",[this]),f.trigger(u,"beforeitemshow",[this])),this._transitioner=this._translate(Math.abs(this.percent),d,!l&&u),c&&(l||f.trigger(d,"itemhide",[this]),f.trigger(u,"itemshow",[this]))}}},end:function(){if(f.off(window,"scroll",this.unbindMove),this.unbindMove&&this.unbindMove(),f.off(document,f.pointerUp,this.end,!0),this.dragging)if(this.dragging=null,this.index===this.prevIndex)this.percent=1-this.percent,this.dir*=-1,this._show(!1,this.index,!0),this._transitioner=null;else{var t=(f.isRtl?this.dir*(f.isRtl?1:-1):this.dir)<0==this.prevPos>this.pos;this.index=t?this.index:this.prevIndex,t&&(this.percent=1-this.percent),this.show(0<this.dir&&!t||this.dir<0&&t?"next":"previous",!0)}f.css(this.list,{userSelect:"",pointerEvents:""}),this.drag=this.percent=null}}},{data:{selNav:!1},computed:{nav:function(t,i){var e=t.selNav;return f.$(e,i)},selNavItem:function(t){var i=t.attrItem;return"["+i+"],[data-"+i+"]"},navItems:function(t,i){return f.$$(this.selNavItem,i)}},update:{write:function(){var e=this;this.nav&&this.length!==this.nav.children.length&&f.html(this.nav,this.slides.map(function(t,i){return"<li "+e.attrItem+'="'+i+'"><a href="#"></a></li>'}).join("")),f.toggleClass(f.$$(this.selNavItem,this.$el).concat(this.nav),"dgt-hidden",!this.maxIndex),this.updateNav()},events:["resize"]},events:[{name:"click",delegate:function(){return this.selNavItem},handler:function(t){t.preventDefault(),this.show(f.data(t.current,this.attrItem))}},{name:"itemshow",handler:"updateNav"}],methods:{updateNav:function(){var e=this,n=this.getValidIndex();this.navItems.forEach(function(t){var i=f.data(t,e.attrItem);f.toggleClass(t,e.clsActive,f.toNumber(i)===n),f.toggleClass(t,"dgt-invisible",e.finite&&("previous"===i&&0===n||"next"===i&&n>=e.maxIndex))})}}}],props:{clsActivated:Boolean,easing:String,index:Number,finite:Boolean,velocity:Number},data:function(){return{easing:"ease",finite:!1,velocity:1,index:0,prevIndex:-1,stack:[],percent:0,clsActive:"dgt-active",clsActivated:!1,Transitioner:!1,transitionOptions:{}}},connected:function(){this.prevIndex=-1,this.index=this.getValidIndex(this.index),this.stack=[]},disconnected:function(){f.removeClass(this.slides,this.clsActive)},computed:{duration:function(t,i){var e=t.velocity;return function(t){return.5*t+300}(i.offsetWidth/e)},list:function(t,i){var e=t.selList;return f.$(e,i)},maxIndex:function(){return this.length-1},selSlides:function(t){return t.selList+" > *"},slides:{get:function(){return f.toNodes(this.list.children)},watch:function(){this.$reset()}},length:function(){return this.slides.length}},events:{itemshown:function(){this.$update(this.list)}},methods:{show:function(t,i){var e=this;if(void 0===i&&(i=!1),!this.dragging&&this.length){var n=this.stack,s=i?0:n.length,r=function(){n.splice(s,1),n.length&&e.show(n.shift(),!0)};if(n[i?"unshift":"push"](t),!i&&1<n.length)2===n.length&&this._transitioner.forward(Math.min(this.duration,200));else{var o=this.index,a=f.hasClass(this.slides,this.clsActive)&&this.slides[o],h=this.getIndex(t,this.index),d=this.slides[h];if(a!==d){if(this.dir=function(t,i){return"next"===t?1:"previous"===t?-1:t<i?-1:1}(t,o),this.prevIndex=o,this.index=h,a&&f.trigger(a,"beforeitemhide",[this]),!f.trigger(d,"beforeitemshow",[this,a]))return this.index=this.prevIndex,void r();var u=this._show(a,d,i).then(function(){return a&&f.trigger(a,"itemhidden",[e]),f.trigger(d,"itemshown",[e]),new f.Promise(function(t){f.fastdom.write(function(){n.shift(),n.length?e.show(n.shift(),!0):e._transitioner=null,t()})})});return a&&f.trigger(a,"itemhide",[this]),f.trigger(d,"itemshow",[this]),u}r()}}},getIndex:function(t,i){return void 0===t&&(t=this.index),void 0===i&&(i=this.index),f.clamp(f.getIndex(t,this.slides,i,this.finite),0,this.maxIndex)},getValidIndex:function(t,i){return void 0===t&&(t=this.index),void 0===i&&(i=this.prevIndex),this.getIndex(t,i)},_show:function(t,i,e){if(this._transitioner=this._getTransitioner(t,i,this.dir,f.assign({easing:e?i.offsetWidth<600?"cubic-bezier(0.25, 0.46, 0.45, 0.94)":"cubic-bezier(0.165, 0.84, 0.44, 1)":this.easing},this.transitionOptions)),!e&&!t)return this._transitioner.translate(1),f.Promise.resolve();var n=this.stack.length;return this._transitioner[1<n?"forward":"show"](1<n?Math.min(this.duration,75+75/(n-1)):this.duration,this.percent)},_getDistance:function(t,i){return new this._getTransitioner(t,t!==i&&i).getDistance()},_translate:function(t,i,e){void 0===i&&(i=this.prevIndex),void 0===e&&(e=this.index);var n=this._getTransitioner(i!==e&&i,e);return n.translate(t),n},_getTransitioner:function(t,i,e,n){return void 0===t&&(t=this.prevIndex),void 0===i&&(i=this.index),void 0===e&&(e=this.dir||1),void 0===n&&(n=this.transitionOptions),new this.Transitioner(f.isNumber(t)?this.slides[t]:t,f.isNumber(i)?this.slides[i]:i,e*(f.isRtl?-1:1),n)}}}],props:{animation:String},data:{animation:"slide",clsActivated:"dgt-transition-active",Animations:i,Transitioner:function(r,o,a,t){var i=t.animation,h=t.easing,e=i.percent,n=i.translate,s=i.show;void 0===s&&(s=f.noop);var d=s(a),u=new f.Deferred;return{dir:a,show:function(t,i,e){var n=this;void 0===i&&(i=0);var s=e?"linear":h;return t-=Math.round(t*f.clamp(i,-1,1)),this.translate(i),c(o,"itemin",{percent:i,duration:t,timing:s,dir:a}),c(r,"itemout",{percent:1-i,duration:t,timing:s,dir:a}),f.Promise.all([f.Transition.start(o,d[1],t,s),f.Transition.start(r,d[0],t,s)]).then(function(){n.reset(),u.resolve()},f.noop),u.promise},stop:function(){return f.Transition.stop([o,r])},cancel:function(){f.Transition.cancel([o,r])},reset:function(){for(var t in d[0])f.css([o,r],t,"")},forward:function(t,i){return void 0===i&&(i=this.percent()),f.Transition.cancel([o,r]),this.show(t,i,!0)},translate:function(t){this.reset();var i=n(t,a);f.css(o,i[1]),f.css(r,i[0]),c(o,"itemtranslatein",{percent:t,dir:a}),c(r,"itemtranslateout",{percent:1-t,dir:a})},percent:function(){return e(r||o,o,a)},getDistance:function(){return r&&r.offsetWidth}}}},computed:{animation:function(t){var i=t.animation,e=t.Animations;return f.assign(i in e?e[i]:e.slide,{name:i})},transitionOptions:function(){return{animation:this.animation}}},events:{"itemshow itemhide itemshown itemhidden":function(t){var i=t.target;this.$update(i)},beforeitemshow:function(t){var i=t.target;f.addClass(i,this.clsActive)},itemshown:function(t){var i=t.target;f.addClass(i,this.clsActivated)},itemhidden:function(t){var i=t.target;f.removeClass(i,this.clsActive,this.clsActivated)}}},o=f.assign({},i,{fade:{show:function(){return[{opacity:0,zIndex:0},{zIndex:-1}]},percent:function(t){return 1-f.css(t,"opacity")},translate:function(t){return[{opacity:1-t,zIndex:0},{zIndex:-1}]}},scale:{show:function(){return[{opacity:0,transform:s(1.5),zIndex:0},{zIndex:-1}]},percent:function(t){return 1-f.css(t,"opacity")},translate:function(t){return[{opacity:1-t,transform:s(1+.5*t),zIndex:0},{zIndex:-1}]}},pull:{show:function(t){return t<0?[{transform:e(30),zIndex:-1},{transform:e(),zIndex:0}]:[{transform:e(-100),zIndex:0},{transform:e(),zIndex:-1}]},percent:function(t,i,e){return e<0?1-n(i):n(t)},translate:function(t,i){return i<0?[{transform:e(30*t),zIndex:-1},{transform:e(-100*(1-t)),zIndex:0}]:[{transform:e(100*-t),zIndex:0},{transform:e(30*(1-t)),zIndex:-1}]}},push:{show:function(t){return t<0?[{transform:e(100),zIndex:0},{transform:e(),zIndex:-1}]:[{transform:e(-30),zIndex:-1},{transform:e(),zIndex:0}]},percent:function(t,i,e){return 0<e?1-n(i):n(t)},translate:function(t,i){return i<0?[{transform:e(100*t),zIndex:0},{transform:e(-30*(1-t)),zIndex:-1}]:[{transform:e(-30*t),zIndex:-1},{transform:e(100*(1-t)),zIndex:0}]}}}),a={mixins:[t,r,{update:{write:function(){if(!this.stack.length&&!this.dragging){var t=this.getValidIndex(this.index);~this.prevIndex&&this.index===t||this.show(t)}},events:["resize"]}}],props:{ratio:String,minHeight:Number,maxHeight:Number},data:{ratio:"16:9",minHeight:!1,maxHeight:!1,selList:".dgt-slideshow-items",attrItem:"dgt-slideshow-item",selNav:".dgt-slideshow-nav",Animations:o},update:{read:function(){var t=this.ratio.split(":").map(Number),i=t[0],e=t[1];return e=e*this.list.offsetWidth/i||0,this.minHeight&&(e=Math.max(this.minHeight,e)),this.maxHeight&&(e=Math.min(this.maxHeight,e)),{height:e-f.boxModelAdjust(this.list,"content-box")}},write:function(t){var i=t.height;f.css(this.list,"minHeight",i)},events:["resize"]}};return"undefined"!=typeof window&&window.dgtUIkit&&window.dgtUIkit.component("slideshow",a),a});