(window.webpackJsonp=window.webpackJsonp||[]).push([[1],{23:function(e,t,i){"use strict";var n="undefined"==typeof document?{body:{},addEventListener:function(){},removeEventListener:function(){},activeElement:{blur:function(){},nodeName:""},querySelector:function(){return null},querySelectorAll:function(){return[]},getElementById:function(){return null},createEvent:function(){return{initEvent:function(){}}},createElement:function(){return{children:[],childNodes:[],style:{},setAttribute:function(){},getElementsByTagName:function(){return[]}}},location:{hash:""}}:document,o="undefined"==typeof window?{document:n,navigator:{userAgent:""},location:{},history:{},CustomEvent:function(){return this},addEventListener:function(){},removeEventListener:function(){},getComputedStyle:function(){return{getPropertyValue:function(){return""}}},Image:function(){},Date:function(){},screen:{},setTimeout:function(){},clearTimeout:function(){}}:window;var s=function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e);for(var i=0;i=0&&c.indexOf(">")>=0){var d="div";for(0===c.indexOf(":~]/)?(t||n).querySelectorAll(e.trim()):[n.getElementById(e.trim().split("#")[1])],a=0;a0&&e[0].nodeType)for(a=0;a=0;p-=1){var f=h[p];s&&f.listener===s?(u.removeEventListener(c,f.proxyListener,a),h.splice(p,1)):s&&f.listener&&f.listener.dom7proxy&&f.listener.dom7proxy===s?(u.removeEventListener(c,f.proxyListener,a),h.splice(p,1)):s||(u.removeEventListener(c,f.proxyListener,a),h.splice(p,1))}}return this},trigger:function(){for(var e=arguments.length,t=new Array(e),i=0;i0}),d.dispatchEvent(u),d.dom7EventData=[],delete d.dom7EventData}return this},transitionEnd:function(e){var t,i=["webkitTransitionEnd","transitionend"],n=this;function o(s){if(s.target===this)for(e.call(this,s),t=0;t0){if(e){var t=this.styles();return this[0].offsetWidth+parseFloat(t.getPropertyValue("margin-right"))+parseFloat(t.getPropertyValue("margin-left"))}return this[0].offsetWidth}return null},outerHeight:function(e){if(this.length>0){if(e){var t=this.styles();return this[0].offsetHeight+parseFloat(t.getPropertyValue("margin-top"))+parseFloat(t.getPropertyValue("margin-bottom"))}return this[0].offsetHeight}return null},offset:function(){if(this.length>0){var e=this[0],t=e.getBoundingClientRect(),i=n.body,s=e.clientTop||i.clientTop||0,a=e.clientLeft||i.clientLeft||0,r=e===o?o.scrollY:e.scrollTop,l=e===o?o.scrollX:e.scrollLeft;return{top:t.top+r-s,left:t.left+l-a}}return null},css:function(e,t){var i;if(1===arguments.length){if("string"!=typeof e){for(i=0;ii-1?[]:e<0?(t=i+e)<0?[]:[this[t]]:[this[e]])},append:function(){for(var e,t=0;t=0;i-=1)this[t].insertBefore(o.childNodes[i],this[t].childNodes[0])}else if(e instanceof s)for(i=0;i0?e?this[0].nextElementSibling&&a(this[0].nextElementSibling).is(e)?new s([this[0].nextElementSibling]):new s([]):this[0].nextElementSibling?new s([this[0].nextElementSibling]):new s([]):new s([])},nextAll:function(e){var t=[],i=this[0];if(!i)return new s([]);for(;i.nextElementSibling;){var n=i.nextElementSibling;e?a(n).is(e)&&t.push(n):t.push(n),i=n}return new s(t)},prev:function(e){if(this.length>0){var t=this[0];return e?t.previousElementSibling&&a(t.previousElementSibling).is(e)?new s([t.previousElementSibling]):new s([]):t.previousElementSibling?new s([t.previousElementSibling]):new s([])}return new s([])},prevAll:function(e){var t=[],i=this[0];if(!i)return new s([]);for(;i.previousElementSibling;){var n=i.previousElementSibling;e?a(n).is(e)&&t.push(n):t.push(n),i=n}return new s(t)},parent:function(e){for(var t=[],i=0;i1&&void 0!==arguments[1]?arguments[1]:0;return setTimeout(e,t)},now:function(){return Date.now()},getTranslate:function(e){var t,i,n,s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"x",a=o.getComputedStyle(e,null);return o.WebKitCSSMatrix?((i=a.transform||a.webkitTransform).split(",").length>6&&(i=i.split(", ").map(function(e){return e.replace(",",".")}).join(", ")),n=new o.WebKitCSSMatrix("none"===i?"":i)):t=(n=a.MozTransform||a.OTransform||a.MsTransform||a.msTransform||a.transform||a.getPropertyValue("transform").replace("translate(","matrix(1, 0, 0, 1,")).toString().split(","),"x"===s&&(i=o.WebKitCSSMatrix?n.m41:16===t.length?parseFloat(t[12]):parseFloat(t[4])),"y"===s&&(i=o.WebKitCSSMatrix?n.m42:16===t.length?parseFloat(t[13]):parseFloat(t[5])),i||0},parseUrlQuery:function(e){var t,i,n,s,a={},r=e||o.location.href;if("string"==typeof r&&r.length)for(s=(i=(r=r.indexOf("?")>-1?r.replace(/\S*\?/,""):"").split("&").filter(function(e){return""!==e})).length,t=0;t0||"ontouchstart"in o||o.DocumentTouch&&n instanceof o.DocumentTouch),pointerEvents:!!(o.navigator.pointerEnabled||o.PointerEvent||"maxTouchPoints"in o.navigator&&o.navigator.maxTouchPoints>0),prefixedPointerEvents:!!o.navigator.msPointerEnabled,transition:(v=b.style,"transition"in v||"webkitTransition"in v||"MozTransition"in v),transforms3d:o.Modernizr&&!0===o.Modernizr.csstransforms3d||function(){var e=b.style;return"webkitPerspective"in e||"MozPerspective"in e||"OPerspective"in e||"MsPerspective"in e||"perspective"in e}(),flexbox:function(){for(var e=b.style,t="alignItems webkitAlignItems webkitBoxAlign msFlexAlign mozBoxAlign webkitFlexDirection msFlexDirection mozBoxDirection mozBoxOrient webkitBoxDirection webkitBoxOrient".split(" "),i=0;i=0&&e.indexOf("chrome")<0&&e.indexOf("android")<0),isUiWebView:/(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/i.test(o.navigator.userAgent)};var e}(),C=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};h(this,e);var i=this;i.params=t,i.eventsListeners={},i.params&&i.params.on&&Object.keys(i.params.on).forEach(function(e){i.on(e,i.params.on[e])})}return f(e,[{key:"on",value:function(e,t,i){var n=this;if("function"!=typeof t)return n;var o=i?"unshift":"push";return e.split(" ").forEach(function(e){n.eventsListeners[e]||(n.eventsListeners[e]=[]),n.eventsListeners[e][o](t)}),n}},{key:"once",value:function(e,t,i){var n=this;if("function"!=typeof t)return n;function o(){for(var i=arguments.length,s=new Array(i),a=0;a0&&void 0!==arguments[0]?arguments[0]:{},t=this;t.modules&&Object.keys(t.modules).forEach(function(i){var n=t.modules[i],o=e[i]||{};n.instance&&Object.keys(n.instance).forEach(function(e){var i=n.instance[e];t[e]="function"==typeof i?i.bind(t):i}),n.on&&t.on&&Object.keys(n.on).forEach(function(e){t.on(e,n.on[e])}),n.create&&n.create.bind(t)(o)})}}],[{key:"installModule",value:function(e){var t=this;t.prototype.modules||(t.prototype.modules={});var i=e.name||"".concat(Object.keys(t.prototype.modules).length,"_").concat(y.now());if(t.prototype.modules[i]=e,e.proto&&Object.keys(e.proto).forEach(function(i){t.prototype[i]=e.proto[i]}),e.static&&Object.keys(e.static).forEach(function(i){t[i]=e.static[i]}),e.install){for(var n=arguments.length,o=new Array(n>1?n-1:0),s=1;s1?i-1:0),o=1;o=0&&(v=parseFloat(v.replace("%",""))/100*i),this.virtualSize=-v,n?l.css({marginLeft:"",marginTop:""}):l.css({marginRight:"",marginBottom:""}),e.slidesPerColumn>1&&(E=Math.floor(c/e.slidesPerColumn)===c/this.params.slidesPerColumn?c:Math.ceil(c/e.slidesPerColumn)*e.slidesPerColumn,"auto"!==e.slidesPerView&&"row"===e.slidesPerColumnFill&&(E=Math.max(E,e.slidesPerView*e.slidesPerColumn)));for(var S,k=e.slidesPerColumn,M=E/k,_=Math.floor(c/e.slidesPerColumn),D=0;D1){var L=void 0,P=void 0,A=void 0;"column"===e.slidesPerColumnFill?(A=D-(P=Math.floor(D/k))*k,(P>_||P===_&&A===k-1)&&(A+=1)>=k&&(A=0,P+=1),L=P+A*E/k,R.css({"-webkit-box-ordinal-group":L,"-moz-box-ordinal-group":L,"-ms-flex-order":L,"-webkit-order":L,order:L})):P=D-(A=Math.floor(D/M))*M,R.css("margin-".concat(this.isHorizontal()?"top":"left"),0!==A&&e.spaceBetween&&"".concat(e.spaceBetween,"px")).attr("data-swiper-column",P).attr("data-swiper-row",A)}if("none"!==R.css("display")){if("auto"===e.slidesPerView){var $=o.getComputedStyle(R[0],null),I=R[0].style.transform,z=R[0].style.webkitTransform;if(I&&(R[0].style.transform="none"),z&&(R[0].style.webkitTransform="none"),e.roundLengths)T=this.isHorizontal()?R.outerWidth(!0):R.outerHeight(!0);else if(this.isHorizontal()){var F=parseFloat($.getPropertyValue("width")),H=parseFloat($.getPropertyValue("padding-left")),O=parseFloat($.getPropertyValue("padding-right")),N=parseFloat($.getPropertyValue("margin-left")),B=parseFloat($.getPropertyValue("margin-right")),j=$.getPropertyValue("box-sizing");T=j&&"border-box"===j?F+N+B:F+H+O+N+B}else{var V=parseFloat($.getPropertyValue("height")),q=parseFloat($.getPropertyValue("padding-top")),W=parseFloat($.getPropertyValue("padding-bottom")),G=parseFloat($.getPropertyValue("margin-top")),Y=parseFloat($.getPropertyValue("margin-bottom")),X=$.getPropertyValue("box-sizing");T=X&&"border-box"===X?V+G+Y:V+q+W+G+Y}I&&(R[0].style.transform=I),z&&(R[0].style.webkitTransform=z),e.roundLengths&&(T=Math.floor(T))}else T=(i-(e.slidesPerView-1)*v)/e.slidesPerView,e.roundLengths&&(T=Math.floor(T)),l[D]&&(this.isHorizontal()?l[D].style.width="".concat(T,"px"):l[D].style.height="".concat(T,"px"));l[D]&&(l[D].swiperSlideSize=T),h.push(T),e.centeredSlides?(b=b+T/2+x/2+v,0===x&&0!==D&&(b=b-i/2-v),0===D&&(b=b-i/2-v),Math.abs(b)<.001&&(b=0),e.roundLengths&&(b=Math.floor(b)),C%e.slidesPerGroup==0&&d.push(b),u.push(b)):(e.roundLengths&&(b=Math.floor(b)),C%e.slidesPerGroup==0&&d.push(b),u.push(b),b=b+T+v),this.virtualSize+=T+v,x=T,C+=1}}if(this.virtualSize=Math.max(this.virtualSize,i)+f,n&&s&&("slide"===e.effect||"coverflow"===e.effect)&&t.css({width:"".concat(this.virtualSize+e.spaceBetween,"px")}),w.flexbox&&!e.setWrapperSize||(this.isHorizontal()?t.css({width:"".concat(this.virtualSize+e.spaceBetween,"px")}):t.css({height:"".concat(this.virtualSize+e.spaceBetween,"px")})),e.slidesPerColumn>1&&(this.virtualSize=(T+e.spaceBetween)*E,this.virtualSize=Math.ceil(this.virtualSize/e.slidesPerColumn)-e.spaceBetween,this.isHorizontal()?t.css({width:"".concat(this.virtualSize+e.spaceBetween,"px")}):t.css({height:"".concat(this.virtualSize+e.spaceBetween,"px")}),e.centeredSlides)){S=[];for(var U=0;U1&&d.push(this.virtualSize-i)}if(0===d.length&&(d=[0]),0!==e.spaceBetween&&(this.isHorizontal()?n?l.css({marginLeft:"".concat(v,"px")}):l.css({marginRight:"".concat(v,"px")}):l.css({marginBottom:"".concat(v,"px")})),e.centerInsufficientSlides){var Z=0;if(h.forEach(function(t){Z+=t+(e.spaceBetween?e.spaceBetween:0)}),(Z-=e.spaceBetween)1)for(t=0;tthis.slides.length)break;i.push(this.slides.eq(o)[0])}else i.push(this.slides.eq(this.activeIndex)[0]);for(t=0;tn?s:n}n&&this.$wrapperEl.css("height","".concat(n,"px"))},updateSlidesOffset:function(){for(var e=this.slides,t=0;t0&&void 0!==arguments[0]?arguments[0]:this&&this.translate||0,t=this.params,i=this.slides,n=this.rtlTranslate;if(0!==i.length){void 0===i[0].swiperSlideOffset&&this.updateSlidesOffset();var o=-e;n&&(o=e),i.removeClass(t.slideVisibleClass),this.visibleSlidesIndexes=[],this.visibleSlides=[];for(var s=0;s=0&&c0&&d<=this.size||c<=0&&d>=this.size)&&(this.visibleSlides.push(r),this.visibleSlidesIndexes.push(s),i.eq(s).addClass(t.slideVisibleClass))}r.progress=n?-l:l}this.visibleSlides=a(this.visibleSlides)}},updateProgress:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this&&this.translate||0,t=this.params,i=this.maxTranslate()-this.minTranslate(),n=this.progress,o=this.isBeginning,s=this.isEnd,a=o,r=s;0===i?(n=0,o=!0,s=!0):(o=(n=(e-this.minTranslate())/i)<=0,s=n>=1),y.extend(this,{progress:n,isBeginning:o,isEnd:s}),(t.watchSlidesProgress||t.watchSlidesVisibility)&&this.updateSlidesProgress(e),o&&!a&&this.emit("reachBeginning toEdge"),s&&!r&&this.emit("reachEnd toEdge"),(a&&!o||r&&!s)&&this.emit("fromEdge"),this.emit("progress",n)},updateSlidesClasses:function(){var e,t=this.slides,i=this.params,n=this.$wrapperEl,o=this.activeIndex,s=this.realIndex,a=this.virtual&&i.virtual.enabled;t.removeClass("".concat(i.slideActiveClass," ").concat(i.slideNextClass," ").concat(i.slidePrevClass," ").concat(i.slideDuplicateActiveClass," ").concat(i.slideDuplicateNextClass," ").concat(i.slideDuplicatePrevClass)),(e=a?this.$wrapperEl.find(".".concat(i.slideClass,'[data-swiper-slide-index="').concat(o,'"]')):t.eq(o)).addClass(i.slideActiveClass),i.loop&&(e.hasClass(i.slideDuplicateClass)?n.children(".".concat(i.slideClass,":not(.").concat(i.slideDuplicateClass,')[data-swiper-slide-index="').concat(s,'"]')).addClass(i.slideDuplicateActiveClass):n.children(".".concat(i.slideClass,".").concat(i.slideDuplicateClass,'[data-swiper-slide-index="').concat(s,'"]')).addClass(i.slideDuplicateActiveClass));var r=e.nextAll(".".concat(i.slideClass)).eq(0).addClass(i.slideNextClass);i.loop&&0===r.length&&(r=t.eq(0)).addClass(i.slideNextClass);var l=e.prevAll(".".concat(i.slideClass)).eq(0).addClass(i.slidePrevClass);i.loop&&0===l.length&&(l=t.eq(-1)).addClass(i.slidePrevClass),i.loop&&(r.hasClass(i.slideDuplicateClass)?n.children(".".concat(i.slideClass,":not(.").concat(i.slideDuplicateClass,')[data-swiper-slide-index="').concat(r.attr("data-swiper-slide-index"),'"]')).addClass(i.slideDuplicateNextClass):n.children(".".concat(i.slideClass,".").concat(i.slideDuplicateClass,'[data-swiper-slide-index="').concat(r.attr("data-swiper-slide-index"),'"]')).addClass(i.slideDuplicateNextClass),l.hasClass(i.slideDuplicateClass)?n.children(".".concat(i.slideClass,":not(.").concat(i.slideDuplicateClass,')[data-swiper-slide-index="').concat(l.attr("data-swiper-slide-index"),'"]')).addClass(i.slideDuplicatePrevClass):n.children(".".concat(i.slideClass,".").concat(i.slideDuplicateClass,'[data-swiper-slide-index="').concat(l.attr("data-swiper-slide-index"),'"]')).addClass(i.slideDuplicatePrevClass))},updateActiveIndex:function(e){var t,i=this.rtlTranslate?this.translate:-this.translate,n=this.slidesGrid,o=this.snapGrid,s=this.params,a=this.activeIndex,r=this.realIndex,l=this.snapIndex,c=e;if(void 0===c){for(var d=0;d=n[d]&&i=n[d]&&i=n[d]&&(c=d);s.normalizeSlideIndex&&(c<0||void 0===c)&&(c=0)}if((t=o.indexOf(i)>=0?o.indexOf(i):Math.floor(c/s.slidesPerGroup))>=o.length&&(t=o.length-1),c!==a){var u=parseInt(this.slides.eq(c).attr("data-swiper-slide-index")||c,10);y.extend(this,{snapIndex:t,realIndex:u,previousIndex:a,activeIndex:c}),this.emit("activeIndexChange"),this.emit("snapIndexChange"),r!==u&&this.emit("realIndexChange"),this.emit("slideChange")}else t!==l&&(this.snapIndex=t,this.emit("snapIndexChange"))},updateClickedSlide:function(e){var t=this.params,i=a(e.target).closest(".".concat(t.slideClass))[0],n=!1;if(i)for(var o=0;o0&&void 0!==arguments[0]?arguments[0]:this.isHorizontal()?"x":"y",t=this.params,i=this.rtlTranslate,n=this.translate,o=this.$wrapperEl;if(t.virtualTranslate)return i?-n:n;var s=y.getTranslate(o[0],e);return i&&(s=-s),s||0},setTranslate:function(e,t){var i=this.rtlTranslate,n=this.params,o=this.$wrapperEl,s=this.progress,a=0,r=0;this.isHorizontal()?a=i?-e:e:r=e,n.roundLengths&&(a=Math.floor(a),r=Math.floor(r)),n.virtualTranslate||(w.transforms3d?o.transform("translate3d(".concat(a,"px, ").concat(r,"px, ").concat(0,"px)")):o.transform("translate(".concat(a,"px, ").concat(r,"px)"))),this.previousTranslate=this.translate,this.translate=this.isHorizontal()?a:r;var l=this.maxTranslate()-this.minTranslate();(0===l?0:(e-this.minTranslate())/l)!==s&&this.updateProgress(e),this.emit("setTranslate",this.translate,t)},minTranslate:function(){return-this.snapGrid[0]},maxTranslate:function(){return-this.snapGrid[this.snapGrid.length-1]}};var S={setTransition:function(e,t){this.$wrapperEl.transition(e),this.emit("setTransition",e,t)},transitionStart:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],t=arguments.length>1?arguments[1]:void 0,i=this.activeIndex,n=this.params,o=this.previousIndex;n.autoHeight&&this.updateAutoHeight();var s=t;if(s||(s=i>o?"next":i0&&void 0!==arguments[0])||arguments[0],t=arguments.length>1?arguments[1]:void 0,i=this.activeIndex,n=this.previousIndex;this.animating=!1,this.setTransition(0);var o=t;if(o||(o=i>n?"next":i0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.params.speed,i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],n=arguments.length>3?arguments[3]:void 0,o=this,s=e;s<0&&(s=0);var a=o.params,r=o.snapGrid,l=o.slidesGrid,c=o.previousIndex,d=o.activeIndex,u=o.rtlTranslate;if(o.animating&&a.preventInteractionOnTransition)return!1;var h=Math.floor(s/a.slidesPerGroup);h>=r.length&&(h=r.length-1),(d||a.initialSlide||0)===(c||0)&&i&&o.emit("beforeSlideChangeStart");var p,f=-r[h];if(o.updateProgress(f),a.normalizeSlideIndex)for(var m=0;m=Math.floor(100*l[m])&&(s=m);if(o.initialized&&s!==d){if(!o.allowSlideNext&&fo.translate&&f>o.maxTranslate()&&(d||0)!==s)return!1}return p=s>d?"next":s0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.params.speed,i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],n=arguments.length>3?arguments[3]:void 0,o=e;return this.params.loop&&(o+=this.loopedSlides),this.slideTo(o,t,i,n)},slideNext:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.params.speed,t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=arguments.length>2?arguments[2]:void 0,n=this.params,o=this.animating;return n.loop?!o&&(this.loopFix(),this._clientLeft=this.$wrapperEl[0].clientLeft,this.slideTo(this.activeIndex+n.slidesPerGroup,e,t,i)):this.slideTo(this.activeIndex+n.slidesPerGroup,e,t,i)},slidePrev:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.params.speed,t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=arguments.length>2?arguments[2]:void 0,n=this.params,o=this.animating,s=this.snapGrid,a=this.slidesGrid,r=this.rtlTranslate;if(n.loop){if(o)return!1;this.loopFix(),this._clientLeft=this.$wrapperEl[0].clientLeft}function l(e){return e<0?-Math.floor(Math.abs(e)):Math.floor(e)}var c,d=l(r?this.translate:-this.translate),u=s.map(function(e){return l(e)}),h=(a.map(function(e){return l(e)}),s[u.indexOf(d)],s[u.indexOf(d)-1]);return void 0!==h&&(c=a.indexOf(h))<0&&(c=this.activeIndex-1),this.slideTo(c,e,t,i)},slideReset:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.params.speed,t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=arguments.length>2?arguments[2]:void 0;return this.slideTo(this.activeIndex,e,t,i)},slideToClosest:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.params.speed,t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=arguments.length>2?arguments[2]:void 0,n=this.activeIndex,o=Math.floor(n/this.params.slidesPerGroup);if(o(this.snapGrid[o+1]-a)/2&&(n=this.params.slidesPerGroup)}return this.slideTo(n,e,t,i)},slideToClickedSlide:function(){var e,t=this,i=t.params,n=t.$wrapperEl,o="auto"===i.slidesPerView?t.slidesPerViewDynamic():i.slidesPerView,s=t.clickedIndex;if(i.loop){if(t.animating)return;e=parseInt(a(t.clickedSlide).attr("data-swiper-slide-index"),10),i.centeredSlides?st.slides.length-t.loopedSlides+o/2?(t.loopFix(),s=n.children(".".concat(i.slideClass,'[data-swiper-slide-index="').concat(e,'"]:not(.').concat(i.slideDuplicateClass,")")).eq(0).index(),y.nextTick(function(){t.slideTo(s)})):t.slideTo(s):s>t.slides.length-o?(t.loopFix(),s=n.children(".".concat(i.slideClass,'[data-swiper-slide-index="').concat(e,'"]:not(.').concat(i.slideDuplicateClass,")")).eq(0).index(),y.nextTick(function(){t.slideTo(s)})):t.slideTo(s)}else t.slideTo(s)}};var M={loopCreate:function(){var e=this,t=e.params,i=e.$wrapperEl;i.children(".".concat(t.slideClass,".").concat(t.slideDuplicateClass)).remove();var o=i.children(".".concat(t.slideClass));if(t.loopFillGroupWithBlank){var s=t.slidesPerGroup-o.length%t.slidesPerGroup;if(s!==t.slidesPerGroup){for(var r=0;ro.length&&(e.loopedSlides=o.length);var c=[],d=[];o.each(function(t,i){var n=a(i);t=o.length-e.loopedSlides&&c.push(i),n.attr("data-swiper-slide-index",t)});for(var u=0;u=0;h-=1)i.prepend(a(c[h].cloneNode(!0)).addClass(t.slideDuplicateClass))},loopFix:function(){var e,t=this.params,i=this.activeIndex,n=this.slides,o=this.loopedSlides,s=this.allowSlidePrev,a=this.allowSlideNext,r=this.snapGrid,l=this.rtlTranslate;this.allowSlidePrev=!0,this.allowSlideNext=!0;var c=-r[i]-this.getTranslate();i=2*o||i>=n.length-o)&&(e=-n.length+i+o,e+=o,this.slideTo(e,0,!1,!0)&&0!==c&&this.setTranslate((l?-this.translate:this.translate)-c));this.allowSlidePrev=s,this.allowSlideNext=a},loopDestroy:function(){var e=this.$wrapperEl,t=this.params,i=this.slides;e.children(".".concat(t.slideClass,".").concat(t.slideDuplicateClass,",.").concat(t.slideClass,".").concat(t.slideBlankClass)).remove(),i.removeAttr("data-swiper-slide-index")}};var _={setGrabCursor:function(e){if(!(w.touch||!this.params.simulateTouch||this.params.watchOverflow&&this.isLocked)){var t=this.el;t.style.cursor="move",t.style.cursor=e?"-webkit-grabbing":"-webkit-grab",t.style.cursor=e?"-moz-grabbin":"-moz-grab",t.style.cursor=e?"grabbing":"grab"}},unsetGrabCursor:function(){w.touch||this.params.watchOverflow&&this.isLocked||(this.el.style.cursor="")}};var D={appendSlide:function(e){var t=this.$wrapperEl,i=this.params;if(i.loop&&this.loopDestroy(),"object"===m(e)&&"length"in e)for(var n=0;n=s)this.appendSlide(t);else{for(var a=o>e?o+1:o,r=[],l=s-1;l>=e;l-=1){var c=this.slides.eq(l);c.remove(),r.unshift(c)}if("object"===m(t)&&"length"in t){for(var d=0;de?o+t.length:o}else i.append(t);for(var u=0;u=0),(a||l||r)&&(t.os="ios",t.ios=!0),l&&!r&&(t.osVersion=l[2].replace(/_/g,"."),t.iphone=!0),a&&(t.osVersion=a[2].replace(/_/g,"."),t.ipad=!0),r&&(t.osVersion=r[3]?r[3].replace(/_/g,"."):null,t.iphone=!0),t.ios&&t.osVersion&&e.indexOf("Version/")>=0&&"10"===t.osVersion.split(".")[0]&&(t.osVersion=e.toLowerCase().split("version/")[1].split(" ")[0]),t.desktop=!(t.os||t.android||t.webView),t.webView=(l||a||r)&&e.match(/.*AppleWebKit(?!.*Safari)/i),t.os&&"ios"===t.os){var c=t.osVersion.split("."),d=n.querySelector('meta[name="viewport"]');t.minimalUi=!t.webView&&(r||l)&&(1*c[0]==7?1*c[1]>=1:1*c[0]>7)&&d&&d.getAttribute("content").indexOf("minimal-ui")>=0}return t.pixelRatio=o.devicePixelRatio||1,t}();function L(){var e=this.params,t=this.el;if(!t||0!==t.offsetWidth){e.breakpoints&&this.setBreakpoint();var i=this.allowSlideNext,n=this.allowSlidePrev,o=this.snapGrid;if(this.allowSlideNext=!0,this.allowSlidePrev=!0,this.updateSize(),this.updateSlides(),e.freeMode){var s=Math.min(Math.max(this.translate,this.maxTranslate()),this.minTranslate());this.setTranslate(s),this.updateActiveIndex(),this.updateSlidesClasses(),e.autoHeight&&this.updateAutoHeight()}else this.updateSlidesClasses(),("auto"===e.slidesPerView||e.slidesPerView>1)&&this.isEnd&&!this.params.centeredSlides?this.slideTo(this.slides.length-1,0,!1,!0):this.slideTo(this.activeIndex,0,!1,!0);this.allowSlidePrev=n,this.allowSlideNext=i,this.params.watchOverflow&&o!==this.snapGrid&&this.checkOverflow()}}var P={init:!0,direction:"horizontal",touchEventsTarget:"container",initialSlide:0,speed:300,preventInteractionOnTransition:!1,edgeSwipeDetection:!1,edgeSwipeThreshold:20,freeMode:!1,freeModeMomentum:!0,freeModeMomentumRatio:1,freeModeMomentumBounce:!0,freeModeMomentumBounceRatio:1,freeModeMomentumVelocityRatio:1,freeModeSticky:!1,freeModeMinimumVelocity:.02,autoHeight:!1,setWrapperSize:!1,virtualTranslate:!1,effect:"slide",breakpoints:void 0,breakpointsInverse:!1,spaceBetween:0,slidesPerView:1,slidesPerColumn:1,slidesPerColumnFill:"column",slidesPerGroup:1,centeredSlides:!1,slidesOffsetBefore:0,slidesOffsetAfter:0,normalizeSlideIndex:!0,centerInsufficientSlides:!1,watchOverflow:!1,roundLengths:!1,touchRatio:1,touchAngle:45,simulateTouch:!0,shortSwipes:!0,longSwipes:!0,longSwipesRatio:.5,longSwipesMs:300,followFinger:!0,allowTouchMove:!0,threshold:0,touchMoveStopPropagation:!0,touchStartPreventDefault:!0,touchStartForcePreventDefault:!1,touchReleaseOnEdges:!1,uniqueNavElements:!0,resistance:!0,resistanceRatio:.85,watchSlidesProgress:!1,watchSlidesVisibility:!1,grabCursor:!1,preventClicks:!0,preventClicksPropagation:!0,slideToClickedSlide:!1,preloadImages:!0,updateOnImagesReady:!0,loop:!1,loopAdditionalSlides:0,loopedSlides:null,loopFillGroupWithBlank:!1,allowSlidePrev:!0,allowSlideNext:!0,swipeHandler:null,noSwiping:!0,noSwipingClass:"swiper-no-swiping",noSwipingSelector:null,passiveListeners:!0,containerModifierClass:"swiper-container-",slideClass:"swiper-slide",slideBlankClass:"swiper-slide-invisible-blank",slideActiveClass:"swiper-slide-active",slideDuplicateActiveClass:"swiper-slide-duplicate-active",slideVisibleClass:"swiper-slide-visible",slideDuplicateClass:"swiper-slide-duplicate",slideNextClass:"swiper-slide-next",slideDuplicateNextClass:"swiper-slide-duplicate-next",slidePrevClass:"swiper-slide-prev",slideDuplicatePrevClass:"swiper-slide-duplicate-prev",wrapperClass:"swiper-wrapper",runCallbacksOnInit:!0},A={update:E,translate:T,transition:S,slide:k,loop:M,grabCursor:_,manipulation:D,events:{attachEvents:function(){var e=this.params,t=this.touchEvents,i=this.el,s=this.wrapperEl;this.onTouchStart=function(e){var t=this.touchEventsData,i=this.params,s=this.touches;if(!this.animating||!i.preventInteractionOnTransition){var r=e;if(r.originalEvent&&(r=r.originalEvent),t.isTouchEvent="touchstart"===r.type,(t.isTouchEvent||!("which"in r)||3!==r.which)&&!(!t.isTouchEvent&&"button"in r&&r.button>0||t.isTouched&&t.isMoved))if(i.noSwiping&&a(r.target).closest(i.noSwipingSelector?i.noSwipingSelector:".".concat(i.noSwipingClass))[0])this.allowClick=!0;else if(!i.swipeHandler||a(r).closest(i.swipeHandler)[0]){s.currentX="touchstart"===r.type?r.targetTouches[0].pageX:r.pageX,s.currentY="touchstart"===r.type?r.targetTouches[0].pageY:r.pageY;var l=s.currentX,c=s.currentY,d=i.edgeSwipeDetection||i.iOSEdgeSwipeDetection,u=i.edgeSwipeThreshold||i.iOSEdgeSwipeThreshold;if(!d||!(l<=u||l>=o.screen.width-u)){if(y.extend(t,{isTouched:!0,isMoved:!1,allowTouchCallbacks:!0,isScrolling:void 0,startMoving:void 0}),s.startX=l,s.startY=c,t.touchStartTime=y.now(),this.allowClick=!0,this.updateSize(),this.swipeDirection=void 0,i.threshold>0&&(t.allowThresholdMove=!1),"touchstart"!==r.type){var h=!0;a(r.target).is(t.formElements)&&(h=!1),n.activeElement&&a(n.activeElement).is(t.formElements)&&n.activeElement!==r.target&&n.activeElement.blur();var p=h&&this.allowTouchMove&&i.touchStartPreventDefault;(i.touchStartForcePreventDefault||p)&&r.preventDefault()}this.emit("touchStart",r)}}}}.bind(this),this.onTouchMove=function(e){var t=this.touchEventsData,i=this.params,o=this.touches,s=this.rtlTranslate,r=e;if(r.originalEvent&&(r=r.originalEvent),t.isTouched){if(!t.isTouchEvent||"mousemove"!==r.type){var l="touchmove"===r.type?r.targetTouches[0].pageX:r.pageX,c="touchmove"===r.type?r.targetTouches[0].pageY:r.pageY;if(r.preventedByNestedSwiper)return o.startX=l,void(o.startY=c);if(!this.allowTouchMove)return this.allowClick=!1,void(t.isTouched&&(y.extend(o,{startX:l,startY:c,currentX:l,currentY:c}),t.touchStartTime=y.now()));if(t.isTouchEvent&&i.touchReleaseOnEdges&&!i.loop)if(this.isVertical()){if(co.startY&&this.translate>=this.minTranslate())return t.isTouched=!1,void(t.isMoved=!1)}else if(lo.startX&&this.translate>=this.minTranslate())return;if(t.isTouchEvent&&n.activeElement&&r.target===n.activeElement&&a(r.target).is(t.formElements))return t.isMoved=!0,void(this.allowClick=!1);if(t.allowTouchCallbacks&&this.emit("touchMove",r),!(r.targetTouches&&r.targetTouches.length>1)){o.currentX=l,o.currentY=c;var d,u=o.currentX-o.startX,h=o.currentY-o.startY;if(!(this.params.threshold&&Math.sqrt(Math.pow(u,2)+Math.pow(h,2))=25&&(d=180*Math.atan2(Math.abs(h),Math.abs(u))/Math.PI,t.isScrolling=this.isHorizontal()?d>i.touchAngle:90-d>i.touchAngle)),t.isScrolling&&this.emit("touchMoveOpposite",r),void 0===t.startMoving&&(o.currentX===o.startX&&o.currentY===o.startY||(t.startMoving=!0)),t.isScrolling)t.isTouched=!1;else if(t.startMoving){this.allowClick=!1,r.preventDefault(),i.touchMoveStopPropagation&&!i.nested&&r.stopPropagation(),t.isMoved||(i.loop&&this.loopFix(),t.startTranslate=this.getTranslate(),this.setTransition(0),this.animating&&this.$wrapperEl.trigger("webkitTransitionEnd transitionend"),t.allowMomentumBounce=!1,!i.grabCursor||!0!==this.allowSlideNext&&!0!==this.allowSlidePrev||this.setGrabCursor(!0),this.emit("sliderFirstMove",r)),this.emit("sliderMove",r),t.isMoved=!0;var p=this.isHorizontal()?u:h;o.diff=p,p*=i.touchRatio,s&&(p=-p),this.swipeDirection=p>0?"prev":"next",t.currentTranslate=p+t.startTranslate;var f=!0,m=i.resistanceRatio;if(i.touchReleaseOnEdges&&(m=0),p>0&&t.currentTranslate>this.minTranslate()?(f=!1,i.resistance&&(t.currentTranslate=this.minTranslate()-1+Math.pow(-this.minTranslate()+t.startTranslate+p,m))):p<0&&t.currentTranslatet.startTranslate&&(t.currentTranslate=t.startTranslate),i.threshold>0){if(!(Math.abs(p)>i.threshold||t.allowThresholdMove))return void(t.currentTranslate=t.startTranslate);if(!t.allowThresholdMove)return t.allowThresholdMove=!0,o.startX=o.currentX,o.startY=o.currentY,t.currentTranslate=t.startTranslate,void(o.diff=this.isHorizontal()?o.currentX-o.startX:o.currentY-o.startY)}i.followFinger&&((i.freeMode||i.watchSlidesProgress||i.watchSlidesVisibility)&&(this.updateActiveIndex(),this.updateSlidesClasses()),i.freeMode&&(0===t.velocities.length&&t.velocities.push({position:o[this.isHorizontal()?"startX":"startY"],time:t.touchStartTime}),t.velocities.push({position:o[this.isHorizontal()?"currentX":"currentY"],time:y.now()})),this.updateProgress(t.currentTranslate),this.setTranslate(t.currentTranslate))}}}}else t.startMoving&&t.isScrolling&&this.emit("touchMoveOpposite",r)}.bind(this),this.onTouchEnd=function(e){var t=this,i=t.touchEventsData,n=t.params,o=t.touches,s=t.rtlTranslate,a=t.$wrapperEl,r=t.slidesGrid,l=t.snapGrid,c=e;if(c.originalEvent&&(c=c.originalEvent),i.allowTouchCallbacks&&t.emit("touchEnd",c),i.allowTouchCallbacks=!1,!i.isTouched)return i.isMoved&&n.grabCursor&&t.setGrabCursor(!1),i.isMoved=!1,void(i.startMoving=!1);n.grabCursor&&i.isMoved&&i.isTouched&&(!0===t.allowSlideNext||!0===t.allowSlidePrev)&&t.setGrabCursor(!1);var d,u=y.now(),h=u-i.touchStartTime;if(t.allowClick&&(t.updateClickedSlide(c),t.emit("tap",c),h<300&&u-i.lastClickTime>300&&(i.clickTimeout&&clearTimeout(i.clickTimeout),i.clickTimeout=y.nextTick(function(){t&&!t.destroyed&&t.emit("click",c)},300)),h<300&&u-i.lastClickTime<300&&(i.clickTimeout&&clearTimeout(i.clickTimeout),t.emit("doubleTap",c))),i.lastClickTime=y.now(),y.nextTick(function(){t.destroyed||(t.allowClick=!0)}),!i.isTouched||!i.isMoved||!t.swipeDirection||0===o.diff||i.currentTranslate===i.startTranslate)return i.isTouched=!1,i.isMoved=!1,void(i.startMoving=!1);if(i.isTouched=!1,i.isMoved=!1,i.startMoving=!1,d=n.followFinger?s?t.translate:-t.translate:-i.currentTranslate,n.freeMode){if(d<-t.minTranslate())return void t.slideTo(t.activeIndex);if(d>-t.maxTranslate())return void(t.slides.length1){var p=i.velocities.pop(),f=i.velocities.pop(),m=p.position-f.position,g=p.time-f.time;t.velocity=m/g,t.velocity/=2,Math.abs(t.velocity)150||y.now()-p.time>300)&&(t.velocity=0)}else t.velocity=0;t.velocity*=n.freeModeMomentumVelocityRatio,i.velocities.length=0;var v=1e3*n.freeModeMomentumRatio,b=t.velocity*v,w=t.translate+b;s&&(w=-w);var x,C,E=!1,T=20*Math.abs(t.velocity)*n.freeModeMomentumBounceRatio;if(wt.minTranslate())n.freeModeMomentumBounce?(w-t.minTranslate()>T&&(w=t.minTranslate()+T),x=t.minTranslate(),E=!0,i.allowMomentumBounce=!0):w=t.minTranslate(),n.loop&&n.centeredSlides&&(C=!0);else if(n.freeModeSticky){for(var S,k=0;k-w){S=k;break}w=-(w=Math.abs(l[S]-w)=n.longSwipesMs)&&(t.updateProgress(),t.updateActiveIndex(),t.updateSlidesClasses())}else{for(var M=0,_=t.slidesSizesGrid[0],D=0;D=r[D]&&d=r[D]&&(M=D,_=r[r.length-1]-r[r.length-2]);var R=(d-r[M])/_;if(h>n.longSwipesMs){if(!n.longSwipes)return void t.slideTo(t.activeIndex);"next"===t.swipeDirection&&(R>=n.longSwipesRatio?t.slideTo(M+n.slidesPerGroup):t.slideTo(M)),"prev"===t.swipeDirection&&(R>1-n.longSwipesRatio?t.slideTo(M+n.slidesPerGroup):t.slideTo(M))}else{if(!n.shortSwipes)return void t.slideTo(t.activeIndex);"next"===t.swipeDirection&&t.slideTo(M+n.slidesPerGroup),"prev"===t.swipeDirection&&t.slideTo(M)}}}.bind(this),this.onClick=function(e){this.allowClick||(this.params.preventClicks&&e.preventDefault(),this.params.preventClicksPropagation&&this.animating&&(e.stopPropagation(),e.stopImmediatePropagation()))}.bind(this);var r="container"===e.touchEventsTarget?i:s,l=!!e.nested;if(w.touch||!w.pointerEvents&&!w.prefixedPointerEvents){if(w.touch){var c=!("touchstart"!==t.start||!w.passiveListener||!e.passiveListeners)&&{passive:!0,capture:!1};r.addEventListener(t.start,this.onTouchStart,c),r.addEventListener(t.move,this.onTouchMove,w.passiveListener?{passive:!1,capture:l}:l),r.addEventListener(t.end,this.onTouchEnd,c)}(e.simulateTouch&&!R.ios&&!R.android||e.simulateTouch&&!w.touch&&R.ios)&&(r.addEventListener("mousedown",this.onTouchStart,!1),n.addEventListener("mousemove",this.onTouchMove,l),n.addEventListener("mouseup",this.onTouchEnd,!1))}else r.addEventListener(t.start,this.onTouchStart,!1),n.addEventListener(t.move,this.onTouchMove,l),n.addEventListener(t.end,this.onTouchEnd,!1);(e.preventClicks||e.preventClicksPropagation)&&r.addEventListener("click",this.onClick,!0),this.on(R.ios||R.android?"resize orientationchange observerUpdate":"resize observerUpdate",L,!0)},detachEvents:function(){var e=this.params,t=this.touchEvents,i=this.el,o=this.wrapperEl,s="container"===e.touchEventsTarget?i:o,a=!!e.nested;if(w.touch||!w.pointerEvents&&!w.prefixedPointerEvents){if(w.touch){var r=!("onTouchStart"!==t.start||!w.passiveListener||!e.passiveListeners)&&{passive:!0,capture:!1};s.removeEventListener(t.start,this.onTouchStart,r),s.removeEventListener(t.move,this.onTouchMove,a),s.removeEventListener(t.end,this.onTouchEnd,r)}(e.simulateTouch&&!R.ios&&!R.android||e.simulateTouch&&!w.touch&&R.ios)&&(s.removeEventListener("mousedown",this.onTouchStart,!1),n.removeEventListener("mousemove",this.onTouchMove,a),n.removeEventListener("mouseup",this.onTouchEnd,!1))}else s.removeEventListener(t.start,this.onTouchStart,!1),n.removeEventListener(t.move,this.onTouchMove,a),n.removeEventListener(t.end,this.onTouchEnd,!1);(e.preventClicks||e.preventClicksPropagation)&&s.removeEventListener("click",this.onClick,!0),this.off(R.ios||R.android?"resize orientationchange observerUpdate":"resize observerUpdate",L)}},breakpoints:{setBreakpoint:function(){var e=this.activeIndex,t=this.initialized,i=this.loopedSlides,n=void 0===i?0:i,o=this.params,s=o.breakpoints;if(s&&(!s||0!==Object.keys(s).length)){var a=this.getBreakpoint(s);if(a&&this.currentBreakpoint!==a){var r=a in s?s[a]:void 0;r&&["slidesPerView","spaceBetween","slidesPerGroup"].forEach(function(e){var t=r[e];void 0!==t&&(r[e]="slidesPerView"!==e||"AUTO"!==t&&"auto"!==t?"slidesPerView"===e?parseFloat(t):parseInt(t,10):"auto")});var l=r||this.originalParams,c=l.direction&&l.direction!==o.direction,d=o.loop&&(l.slidesPerView!==o.slidesPerView||c);c&&t&&this.changeDirection(),y.extend(this.params,l),y.extend(this,{allowTouchMove:this.params.allowTouchMove,allowSlideNext:this.params.allowSlideNext,allowSlidePrev:this.params.allowSlidePrev}),this.currentBreakpoint=a,d&&t&&(this.loopDestroy(),this.loopCreate(),this.updateSlides(),this.slideTo(e-n+this.loopedSlides,0,!1)),this.emit("breakpoint",l)}}},getBreakpoint:function(e){if(e){var t=!1,i=[];Object.keys(e).forEach(function(e){i.push(e)}),i.sort(function(e,t){return parseInt(e,10)-parseInt(t,10)});for(var n=0;n=o.innerWidth&&!t&&(t=s)}return t||"max"}}},checkOverflow:{checkOverflow:function(){var e=this.isLocked;this.isLocked=1===this.snapGrid.length,this.allowSlideNext=!this.isLocked,this.allowSlidePrev=!this.isLocked,e!==this.isLocked&&this.emit(this.isLocked?"lock":"unlock"),e&&e!==this.isLocked&&(this.isEnd=!1,this.navigation.update())}},classes:{addClasses:function(){var e=this.classNames,t=this.params,i=this.rtl,n=this.$el,o=[];o.push("initialized"),o.push(t.direction),t.freeMode&&o.push("free-mode"),w.flexbox||o.push("no-flexbox"),t.autoHeight&&o.push("autoheight"),i&&o.push("rtl"),t.slidesPerColumn>1&&o.push("multirow"),R.android&&o.push("android"),R.ios&&o.push("ios"),(x.isIE||x.isEdge)&&(w.pointerEvents||w.prefixedPointerEvents)&&o.push("wp8-".concat(t.direction)),o.forEach(function(i){e.push(t.containerModifierClass+i)}),n.addClass(e.join(" "))},removeClasses:function(){var e=this.$el,t=this.classNames;e.removeClass(t.join(" "))}},images:{loadImage:function(e,t,i,n,s,a){var r;function l(){a&&a()}e.complete&&s?l():t?((r=new o.Image).onload=l,r.onerror=l,n&&(r.sizes=n),i&&(r.srcset=i),t&&(r.src=t)):l()},preloadImages:function(){var e=this;function t(){null!=e&&e&&!e.destroyed&&(void 0!==e.imagesLoaded&&(e.imagesLoaded+=1),e.imagesLoaded===e.imagesToLoad.length&&(e.params.updateOnImagesReady&&e.update(),e.emit("imagesReady")))}e.imagesToLoad=e.$el.find("img");for(var i=0;i1){var g=[];return f.each(function(e,i){var o=y.extend({},n,{el:i});g.push(new t(o))}),l(e,g)}i.swiper=u,f.data("swiper",u);var v,b,x=f.children(".".concat(u.params.wrapperClass));return y.extend(u,{$el:f,el:i,$wrapperEl:x,wrapperEl:x[0],classNames:[],slides:a(),slidesGrid:[],snapGrid:[],slidesSizesGrid:[],isHorizontal:function(){return"horizontal"===u.params.direction},isVertical:function(){return"vertical"===u.params.direction},rtl:"rtl"===i.dir.toLowerCase()||"rtl"===f.css("direction"),rtlTranslate:"horizontal"===u.params.direction&&("rtl"===i.dir.toLowerCase()||"rtl"===f.css("direction")),wrongRTL:"-webkit-box"===x.css("display"),activeIndex:0,realIndex:0,isBeginning:!0,isEnd:!1,translate:0,previousTranslate:0,progress:0,velocity:0,animating:!1,allowSlideNext:u.params.allowSlideNext,allowSlidePrev:u.params.allowSlidePrev,touchEvents:(v=["touchstart","touchmove","touchend"],b=["mousedown","mousemove","mouseup"],w.pointerEvents?b=["pointerdown","pointermove","pointerup"]:w.prefixedPointerEvents&&(b=["MSPointerDown","MSPointerMove","MSPointerUp"]),u.touchEventsTouch={start:v[0],move:v[1],end:v[2]},u.touchEventsDesktop={start:b[0],move:b[1],end:b[2]},w.touch||!u.params.simulateTouch?u.touchEventsTouch:u.touchEventsDesktop),touchEventsData:{isTouched:void 0,isMoved:void 0,allowTouchCallbacks:void 0,touchStartTime:void 0,isScrolling:void 0,currentTranslate:void 0,startTranslate:void 0,allowThresholdMove:void 0,formElements:"input, select, option, textarea, button, video",lastClickTime:y.now(),clickTimeout:void 0,velocities:[],allowMomentumBounce:void 0,isTouchEvent:void 0,startMoving:void 0},allowClick:!0,allowTouchMove:u.params.allowTouchMove,touches:{startX:0,startY:0,currentX:0,currentY:0,diff:0},imagesToLoad:[],imagesLoaded:0}),u.useModules(),u.params.init&&u.init(),l(e,u)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&u(e,t)}(t,C),f(t,[{key:"slidesPerViewDynamic",value:function(){var e=this.params,t=this.slides,i=this.slidesGrid,n=this.size,o=this.activeIndex,s=1;if(e.centeredSlides){for(var a,r=t[o].swiperSlideSize,l=o+1;ln&&(a=!0));for(var c=o-1;c>=0;c-=1)t[c]&&!a&&(s+=1,(r+=t[c].swiperSlideSize)>n&&(a=!0))}else for(var d=o+1;d1)&&e.isEnd&&!e.params.centeredSlides?e.slideTo(e.slides.length-1,0,!1,!0):e.slideTo(e.activeIndex,0,!1,!0))||n(),i.watchOverflow&&t!==e.snapGrid&&e.checkOverflow(),e.emit("update")}function n(){var t=e.rtlTranslate?-1*e.translate:e.translate,i=Math.min(Math.max(t,e.maxTranslate()),e.minTranslate());e.setTranslate(i),e.updateActiveIndex(),e.updateSlidesClasses()}}},{key:"changeDirection",value:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=this.params.direction;return e||(e="horizontal"===i?"vertical":"horizontal"),e===i||"horizontal"!==e&&"vertical"!==e?this:("vertical"===i&&(this.$el.removeClass("".concat(this.params.containerModifierClass,"vertical wp8-vertical")).addClass("".concat(this.params.containerModifierClass).concat(e)),(x.isIE||x.isEdge)&&(w.pointerEvents||w.prefixedPointerEvents)&&this.$el.addClass("".concat(this.params.containerModifierClass,"wp8-").concat(e))),"horizontal"===i&&(this.$el.removeClass("".concat(this.params.containerModifierClass,"horizontal wp8-horizontal")).addClass("".concat(this.params.containerModifierClass).concat(e)),(x.isIE||x.isEdge)&&(w.pointerEvents||w.prefixedPointerEvents)&&this.$el.addClass("".concat(this.params.containerModifierClass,"wp8-").concat(e))),this.params.direction=e,this.slides.each(function(t,i){"vertical"===e?i.style.width="":i.style.height=""}),this.emit("changeDirection"),t&&this.update(),this)}},{key:"init",value:function(){this.initialized||(this.emit("beforeInit"),this.params.breakpoints&&this.setBreakpoint(),this.addClasses(),this.params.loop&&this.loopCreate(),this.updateSize(),this.updateSlides(),this.params.watchOverflow&&this.checkOverflow(),this.params.grabCursor&&this.setGrabCursor(),this.params.preloadImages&&this.preloadImages(),this.params.loop?this.slideTo(this.params.initialSlide+this.loopedSlides,0,this.params.runCallbacksOnInit):this.slideTo(this.params.initialSlide,0,this.params.runCallbacksOnInit),this.attachEvents(),this.initialized=!0,this.emit("init"))}},{key:"destroy",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=this,n=i.params,o=i.$el,s=i.$wrapperEl,a=i.slides;return void 0===i.params||i.destroyed?null:(i.emit("beforeDestroy"),i.initialized=!1,i.detachEvents(),n.loop&&i.loopDestroy(),t&&(i.removeClasses(),o.removeAttr("style"),s.removeAttr("style"),a&&a.length&&a.removeClass([n.slideVisibleClass,n.slideActiveClass,n.slideNextClass,n.slidePrevClass].join(" ")).removeAttr("style").removeAttr("data-swiper-slide-index").removeAttr("data-swiper-column").removeAttr("data-swiper-row")),i.emit("destroy"),Object.keys(i.eventsListeners).forEach(function(e){i.off(e)}),!1!==e&&(i.$el[0].swiper=null,i.$el.data("swiper",null),y.deleteProps(i)),i.destroyed=!0,null)}}],[{key:"extendDefaults",value:function(e){y.extend($,e)}},{key:"extendedDefaults",get:function(){return $}},{key:"defaults",get:function(){return P}},{key:"Class",get:function(){return C}},{key:"$",get:function(){return a}}]),t}(),z={name:"device",proto:{device:R},static:{device:R}},F={name:"support",proto:{support:w},static:{support:w}},H={name:"browser",proto:{browser:x},static:{browser:x}},O={name:"resize",create:function(){var e=this;y.extend(e,{resize:{resizeHandler:function(){e&&!e.destroyed&&e.initialized&&(e.emit("beforeResize"),e.emit("resize"))},orientationChangeHandler:function(){e&&!e.destroyed&&e.initialized&&e.emit("orientationchange")}}})},on:{init:function(){o.addEventListener("resize",this.resize.resizeHandler),o.addEventListener("orientationchange",this.resize.orientationChangeHandler)},destroy:function(){o.removeEventListener("resize",this.resize.resizeHandler),o.removeEventListener("orientationchange",this.resize.orientationChangeHandler)}}},N={func:o.MutationObserver||o.WebkitMutationObserver,attach:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=this,n=new(0,N.func)(function(e){if(1!==e.length){var t=function(){i.emit("observerUpdate",e[0])};o.requestAnimationFrame?o.requestAnimationFrame(t):o.setTimeout(t,0)}else i.emit("observerUpdate",e[0])});n.observe(e,{attributes:void 0===t.attributes||t.attributes,childList:void 0===t.childList||t.childList,characterData:void 0===t.characterData||t.characterData}),i.observer.observers.push(n)},init:function(){if(w.observer&&this.params.observer){if(this.params.observeParents)for(var e=this.$el.parents(),t=0;tC)&&t.$wrapperEl.find(".".concat(t.params.slideClass,'[data-swiper-slide-index="').concat(M,'"]')).remove();for(var _=0;_=x&&_<=C&&(void 0===u||e?k.push(_):(_>u&&k.push(_),_').concat(e,""));return n.attr("data-swiper-slide-index")||n.attr("data-swiper-slide-index",t),i.cache&&(this.virtual.cache[t]=n),n},appendSlide:function(e){if("object"===m(e)&&"length"in e)for(var t=0;t=0;i-=1)this.virtual.slides.splice(e[i],1),this.params.virtual.cache&&delete this.virtual.cache[e[i]],e[i]0&&0===this.$el.parents(".".concat(this.params.slideActiveClass)).length)return;var r=o.innerWidth,l=o.innerHeight,c=this.$el.offset();t&&(c.left-=this.$el[0].scrollLeft);for(var d=[[c.left,c.top],[c.left+this.width,c.top],[c.left,c.top+this.height],[c.left+this.width,c.top+this.height]],u=0;u=0&&h[0]<=r&&h[1]>=0&&h[1]<=l&&(a=!0)}if(!a)return}this.isHorizontal()?(37!==s&&39!==s||(i.preventDefault?i.preventDefault():i.returnValue=!1),(39===s&&!t||37===s&&t)&&this.slideNext(),(37===s&&!t||39===s&&t)&&this.slidePrev()):(38!==s&&40!==s||(i.preventDefault?i.preventDefault():i.returnValue=!1),40===s&&this.slideNext(),38===s&&this.slidePrev()),this.emit("keyPress",s)}},enable:function(){this.keyboard.enabled||(a(n).on("keydown",this.keyboard.handle),this.keyboard.enabled=!0)},disable:function(){this.keyboard.enabled&&(a(n).off("keydown",this.keyboard.handle),this.keyboard.enabled=!1)}},W={name:"keyboard",params:{keyboard:{enabled:!1,onlyInViewport:!0}},create:function(){y.extend(this,{keyboard:{enabled:!1,enable:q.enable.bind(this),disable:q.disable.bind(this),handle:q.handle.bind(this)}})},on:{init:function(){this.params.keyboard.enabled&&this.keyboard.enable()},destroy:function(){this.keyboard.enabled&&this.keyboard.disable()}}};var G={lastScrollTime:y.now(),event:o.navigator.userAgent.indexOf("firefox")>-1?"DOMMouseScroll":function(){var e="onwheel"in n;if(!e){var t=n.createElement("div");t.setAttribute("onwheel","return;"),e="function"==typeof t.onwheel}return!e&&n.implementation&&n.implementation.hasFeature&&!0!==n.implementation.hasFeature("","")&&(e=n.implementation.hasFeature("Events.wheel","3.0")),e}()?"wheel":"mousewheel",normalize:function(e){var t=0,i=0,n=0,o=0;return"detail"in e&&(i=e.detail),"wheelDelta"in e&&(i=-e.wheelDelta/120),"wheelDeltaY"in e&&(i=-e.wheelDeltaY/120),"wheelDeltaX"in e&&(t=-e.wheelDeltaX/120),"axis"in e&&e.axis===e.HORIZONTAL_AXIS&&(t=i,i=0),n=10*t,o=10*i,"deltaY"in e&&(o=e.deltaY),"deltaX"in e&&(n=e.deltaX),(n||o)&&e.deltaMode&&(1===e.deltaMode?(n*=40,o*=40):(n*=800,o*=800)),n&&!t&&(t=n<1?-1:1),o&&!i&&(i=o<1?-1:1),{spinX:t,spinY:i,pixelX:n,pixelY:o}},handleMouseEnter:function(){this.mouseEntered=!0},handleMouseLeave:function(){this.mouseEntered=!1},handle:function(e){var t=e,i=this,n=i.params.mousewheel;if(!i.mouseEntered&&!n.releaseOnEdges)return!0;t.originalEvent&&(t=t.originalEvent);var s=0,a=i.rtlTranslate?-1:1,r=G.normalize(t);if(n.forceToAxis)if(i.isHorizontal()){if(!(Math.abs(r.pixelX)>Math.abs(r.pixelY)))return!0;s=r.pixelX*a}else{if(!(Math.abs(r.pixelY)>Math.abs(r.pixelX)))return!0;s=r.pixelY}else s=Math.abs(r.pixelX)>Math.abs(r.pixelY)?-r.pixelX*a:-r.pixelY;if(0===s)return!0;if(n.invert&&(s=-s),i.params.freeMode){i.params.loop&&i.loopFix();var l=i.getTranslate()+s*n.sensitivity,c=i.isBeginning,d=i.isEnd;if(l>=i.minTranslate()&&(l=i.minTranslate()),l<=i.maxTranslate()&&(l=i.maxTranslate()),i.setTransition(0),i.setTranslate(l),i.updateProgress(),i.updateActiveIndex(),i.updateSlidesClasses(),(!c&&i.isBeginning||!d&&i.isEnd)&&i.updateSlidesClasses(),i.params.freeModeSticky&&(clearTimeout(i.mousewheel.timeout),i.mousewheel.timeout=y.nextTick(function(){i.slideToClosest()},300)),i.emit("scroll",t),i.params.autoplay&&i.params.autoplayDisableOnInteraction&&i.autoplay.stop(),l===i.minTranslate()||l===i.maxTranslate())return!0}else{if(y.now()-i.mousewheel.lastScrollTime>60)if(s<0)if(i.isEnd&&!i.params.loop||i.animating){if(n.releaseOnEdges)return!0}else i.slideNext(),i.emit("scroll",t);else if(i.isBeginning&&!i.params.loop||i.animating){if(n.releaseOnEdges)return!0}else i.slidePrev(),i.emit("scroll",t);i.mousewheel.lastScrollTime=(new o.Date).getTime()}return t.preventDefault?t.preventDefault():t.returnValue=!1,!1},enable:function(){if(!G.event)return!1;if(this.mousewheel.enabled)return!1;var e=this.$el;return"container"!==this.params.mousewheel.eventsTarged&&(e=a(this.params.mousewheel.eventsTarged)),e.on("mouseenter",this.mousewheel.handleMouseEnter),e.on("mouseleave",this.mousewheel.handleMouseLeave),e.on(G.event,this.mousewheel.handle),this.mousewheel.enabled=!0,!0},disable:function(){if(!G.event)return!1;if(!this.mousewheel.enabled)return!1;var e=this.$el;return"container"!==this.params.mousewheel.eventsTarged&&(e=a(this.params.mousewheel.eventsTarged)),e.off(G.event,this.mousewheel.handle),this.mousewheel.enabled=!1,!0}},Y={update:function(){var e=this.params.navigation;if(!this.params.loop){var t=this.navigation,i=t.$nextEl,n=t.$prevEl;n&&n.length>0&&(this.isBeginning?n.addClass(e.disabledClass):n.removeClass(e.disabledClass),n[this.params.watchOverflow&&this.isLocked?"addClass":"removeClass"](e.lockClass)),i&&i.length>0&&(this.isEnd?i.addClass(e.disabledClass):i.removeClass(e.disabledClass),i[this.params.watchOverflow&&this.isLocked?"addClass":"removeClass"](e.lockClass))}},onPrevClick:function(e){e.preventDefault(),this.isBeginning&&!this.params.loop||this.slidePrev()},onNextClick:function(e){e.preventDefault(),this.isEnd&&!this.params.loop||this.slideNext()},init:function(){var e,t,i=this.params.navigation;(i.nextEl||i.prevEl)&&(i.nextEl&&(e=a(i.nextEl),this.params.uniqueNavElements&&"string"==typeof i.nextEl&&e.length>1&&1===this.$el.find(i.nextEl).length&&(e=this.$el.find(i.nextEl))),i.prevEl&&(t=a(i.prevEl),this.params.uniqueNavElements&&"string"==typeof i.prevEl&&t.length>1&&1===this.$el.find(i.prevEl).length&&(t=this.$el.find(i.prevEl))),e&&e.length>0&&e.on("click",this.navigation.onNextClick),t&&t.length>0&&t.on("click",this.navigation.onPrevClick),y.extend(this.navigation,{$nextEl:e,nextEl:e&&e[0],$prevEl:t,prevEl:t&&t[0]}))},destroy:function(){var e=this.navigation,t=e.$nextEl,i=e.$prevEl;t&&t.length&&(t.off("click",this.navigation.onNextClick),t.removeClass(this.params.navigation.disabledClass)),i&&i.length&&(i.off("click",this.navigation.onPrevClick),i.removeClass(this.params.navigation.disabledClass))}},X={update:function(){var e=this.rtl,t=this.params.pagination;if(t.el&&this.pagination.el&&this.pagination.$el&&0!==this.pagination.$el.length){var i,n=this.virtual&&this.params.virtual.enabled?this.virtual.slides.length:this.slides.length,o=this.pagination.$el,s=this.params.loop?Math.ceil((n-2*this.loopedSlides)/this.params.slidesPerGroup):this.snapGrid.length;if(this.params.loop?((i=Math.ceil((this.activeIndex-this.loopedSlides)/this.params.slidesPerGroup))>n-1-2*this.loopedSlides&&(i-=n-2*this.loopedSlides),i>s-1&&(i-=s),i<0&&"bullets"!==this.params.paginationType&&(i=s+i)):i=void 0!==this.snapIndex?this.snapIndex:this.activeIndex||0,"bullets"===t.type&&this.pagination.bullets&&this.pagination.bullets.length>0){var r,l,c,d=this.pagination.bullets;if(t.dynamicBullets&&(this.pagination.bulletSize=d.eq(0)[this.isHorizontal()?"outerWidth":"outerHeight"](!0),o.css(this.isHorizontal()?"width":"height","".concat(this.pagination.bulletSize*(t.dynamicMainBullets+4),"px")),t.dynamicMainBullets>1&&void 0!==this.previousIndex&&(this.pagination.dynamicBulletIndex+=i-this.previousIndex,this.pagination.dynamicBulletIndex>t.dynamicMainBullets-1?this.pagination.dynamicBulletIndex=t.dynamicMainBullets-1:this.pagination.dynamicBulletIndex<0&&(this.pagination.dynamicBulletIndex=0)),r=i-this.pagination.dynamicBulletIndex,c=((l=r+(Math.min(d.length,t.dynamicMainBullets)-1))+r)/2),d.removeClass("".concat(t.bulletActiveClass," ").concat(t.bulletActiveClass,"-next ").concat(t.bulletActiveClass,"-next-next ").concat(t.bulletActiveClass,"-prev ").concat(t.bulletActiveClass,"-prev-prev ").concat(t.bulletActiveClass,"-main")),o.length>1)d.each(function(e,n){var o=a(n),s=o.index();s===i&&o.addClass(t.bulletActiveClass),t.dynamicBullets&&(s>=r&&s<=l&&o.addClass("".concat(t.bulletActiveClass,"-main")),s===r&&o.prev().addClass("".concat(t.bulletActiveClass,"-prev")).prev().addClass("".concat(t.bulletActiveClass,"-prev-prev")),s===l&&o.next().addClass("".concat(t.bulletActiveClass,"-next")).next().addClass("".concat(t.bulletActiveClass,"-next-next")))});else if(d.eq(i).addClass(t.bulletActiveClass),t.dynamicBullets){for(var u=d.eq(r),h=d.eq(l),p=r;p<=l;p+=1)d.eq(p).addClass("".concat(t.bulletActiveClass,"-main"));u.prev().addClass("".concat(t.bulletActiveClass,"-prev")).prev().addClass("".concat(t.bulletActiveClass,"-prev-prev")),h.next().addClass("".concat(t.bulletActiveClass,"-next")).next().addClass("".concat(t.bulletActiveClass,"-next-next"))}if(t.dynamicBullets){var f=Math.min(d.length,t.dynamicMainBullets+4),m=(this.pagination.bulletSize*f-this.pagination.bulletSize)/2-c*this.pagination.bulletSize,g=e?"right":"left";d.css(this.isHorizontal()?g:"top","".concat(m,"px"))}}if("fraction"===t.type&&(o.find(".".concat(t.currentClass)).text(t.formatFractionCurrent(i+1)),o.find(".".concat(t.totalClass)).text(t.formatFractionTotal(s))),"progressbar"===t.type){var v;v=t.progressbarOpposite?this.isHorizontal()?"vertical":"horizontal":this.isHorizontal()?"horizontal":"vertical";var b=(i+1)/s,y=1,w=1;"horizontal"===v?y=b:w=b,o.find(".".concat(t.progressbarFillClass)).transform("translate3d(0,0,0) scaleX(".concat(y,") scaleY(").concat(w,")")).transition(this.params.speed)}"custom"===t.type&&t.renderCustom?(o.html(t.renderCustom(this,i+1,s)),this.emit("paginationRender",this,o[0])):this.emit("paginationUpdate",this,o[0]),o[this.params.watchOverflow&&this.isLocked?"addClass":"removeClass"](t.lockClass)}},render:function(){var e=this.params.pagination;if(e.el&&this.pagination.el&&this.pagination.$el&&0!==this.pagination.$el.length){var t=this.virtual&&this.params.virtual.enabled?this.virtual.slides.length:this.slides.length,i=this.pagination.$el,n="";if("bullets"===e.type){for(var o=this.params.loop?Math.ceil((t-2*this.loopedSlides)/this.params.slidesPerGroup):this.snapGrid.length,s=0;s");i.html(n),this.pagination.bullets=i.find(".".concat(e.bulletClass))}"fraction"===e.type&&(n=e.renderFraction?e.renderFraction.call(this,e.currentClass,e.totalClass):'')+" / "+''),i.html(n)),"progressbar"===e.type&&(n=e.renderProgressbar?e.renderProgressbar.call(this,e.progressbarFillClass):''),i.html(n)),"custom"!==e.type&&this.emit("paginationRender",this.pagination.$el[0])}},init:function(){var e=this,t=e.params.pagination;if(t.el){var i=a(t.el);0!==i.length&&(e.params.uniqueNavElements&&"string"==typeof t.el&&i.length>1&&1===e.$el.find(t.el).length&&(i=e.$el.find(t.el)),"bullets"===t.type&&t.clickable&&i.addClass(t.clickableClass),i.addClass(t.modifierClass+t.type),"bullets"===t.type&&t.dynamicBullets&&(i.addClass("".concat(t.modifierClass).concat(t.type,"-dynamic")),e.pagination.dynamicBulletIndex=0,t.dynamicMainBullets<1&&(t.dynamicMainBullets=1)),"progressbar"===t.type&&t.progressbarOpposite&&i.addClass(t.progressbarOppositeClass),t.clickable&&i.on("click",".".concat(t.bulletClass),function(t){t.preventDefault();var i=a(this).index()*e.params.slidesPerGroup;e.params.loop&&(i+=e.loopedSlides),e.slideTo(i)}),y.extend(e.pagination,{$el:i,el:i[0]}))}},destroy:function(){var e=this.params.pagination;if(e.el&&this.pagination.el&&this.pagination.$el&&0!==this.pagination.$el.length){var t=this.pagination.$el;t.removeClass(e.hiddenClass),t.removeClass(e.modifierClass+e.type),this.pagination.bullets&&this.pagination.bullets.removeClass(e.bulletActiveClass),e.clickable&&t.off("click",".".concat(e.bulletClass))}}},U={setTranslate:function(){if(this.params.scrollbar.el&&this.scrollbar.el){var e=this.scrollbar,t=this.rtlTranslate,i=this.progress,n=e.dragSize,o=e.trackSize,s=e.$dragEl,a=e.$el,r=this.params.scrollbar,l=n,c=(o-n)*i;t?(c=-c)>0?(l=n-c,c=0):-c+n>o&&(l=o+c):c<0?(l=n+c,c=0):c+n>o&&(l=o-c),this.isHorizontal()?(w.transforms3d?s.transform("translate3d(".concat(c,"px, 0, 0)")):s.transform("translateX(".concat(c,"px)")),s[0].style.width="".concat(l,"px")):(w.transforms3d?s.transform("translate3d(0px, ".concat(c,"px, 0)")):s.transform("translateY(".concat(c,"px)")),s[0].style.height="".concat(l,"px")),r.hide&&(clearTimeout(this.scrollbar.timeout),a[0].style.opacity=1,this.scrollbar.timeout=setTimeout(function(){a[0].style.opacity=0,a.transition(400)},1e3))}},setTransition:function(e){this.params.scrollbar.el&&this.scrollbar.el&&this.scrollbar.$dragEl.transition(e)},updateSize:function(){if(this.params.scrollbar.el&&this.scrollbar.el){var e=this.scrollbar,t=e.$dragEl,i=e.$el;t[0].style.width="",t[0].style.height="";var n,o=this.isHorizontal()?i[0].offsetWidth:i[0].offsetHeight,s=this.size/this.virtualSize,a=s*(o/this.size);n="auto"===this.params.scrollbar.dragSize?o*s:parseInt(this.params.scrollbar.dragSize,10),this.isHorizontal()?t[0].style.width="".concat(n,"px"):t[0].style.height="".concat(n,"px"),i[0].style.display=s>=1?"none":"",this.params.scrollbar.hide&&(i[0].style.opacity=0),y.extend(e,{trackSize:o,divider:s,moveDivider:a,dragSize:n}),e.$el[this.params.watchOverflow&&this.isLocked?"addClass":"removeClass"](this.params.scrollbar.lockClass)}},setDragPosition:function(e){var t,i=this.scrollbar,n=this.rtlTranslate,o=i.$el,s=i.dragSize,a=i.trackSize;t=((this.isHorizontal()?"touchstart"===e.type||"touchmove"===e.type?e.targetTouches[0].pageX:e.pageX||e.clientX:"touchstart"===e.type||"touchmove"===e.type?e.targetTouches[0].pageY:e.pageY||e.clientY)-o.offset()[this.isHorizontal()?"left":"top"]-s/2)/(a-s),t=Math.max(Math.min(t,1),0),n&&(t=1-t);var r=this.minTranslate()+(this.maxTranslate()-this.minTranslate())*t;this.updateProgress(r),this.setTranslate(r),this.updateActiveIndex(),this.updateSlidesClasses()},onDragStart:function(e){var t=this.params.scrollbar,i=this.scrollbar,n=this.$wrapperEl,o=i.$el,s=i.$dragEl;this.scrollbar.isTouched=!0,e.preventDefault(),e.stopPropagation(),n.transition(100),s.transition(100),i.setDragPosition(e),clearTimeout(this.scrollbar.dragTimeout),o.transition(0),t.hide&&o.css("opacity",1),this.emit("scrollbarDragStart",e)},onDragMove:function(e){var t=this.scrollbar,i=this.$wrapperEl,n=t.$el,o=t.$dragEl;this.scrollbar.isTouched&&(e.preventDefault?e.preventDefault():e.returnValue=!1,t.setDragPosition(e),i.transition(0),n.transition(0),o.transition(0),this.emit("scrollbarDragMove",e))},onDragEnd:function(e){var t=this.params.scrollbar,i=this.scrollbar.$el;this.scrollbar.isTouched&&(this.scrollbar.isTouched=!1,t.hide&&(clearTimeout(this.scrollbar.dragTimeout),this.scrollbar.dragTimeout=y.nextTick(function(){i.css("opacity",0),i.transition(400)},1e3)),this.emit("scrollbarDragEnd",e),t.snapOnRelease&&this.slideToClosest())},enableDraggable:function(){if(this.params.scrollbar.el){var e=this.scrollbar,t=this.touchEventsTouch,i=this.touchEventsDesktop,o=this.params,s=e.$el[0],a=!(!w.passiveListener||!o.passiveListeners)&&{passive:!1,capture:!1},r=!(!w.passiveListener||!o.passiveListeners)&&{passive:!0,capture:!1};w.touch?(s.addEventListener(t.start,this.scrollbar.onDragStart,a),s.addEventListener(t.move,this.scrollbar.onDragMove,a),s.addEventListener(t.end,this.scrollbar.onDragEnd,r)):(s.addEventListener(i.start,this.scrollbar.onDragStart,a),n.addEventListener(i.move,this.scrollbar.onDragMove,a),n.addEventListener(i.end,this.scrollbar.onDragEnd,r))}},disableDraggable:function(){if(this.params.scrollbar.el){var e=this.scrollbar,t=this.touchEventsTouch,i=this.touchEventsDesktop,o=this.params,s=e.$el[0],a=!(!w.passiveListener||!o.passiveListeners)&&{passive:!1,capture:!1},r=!(!w.passiveListener||!o.passiveListeners)&&{passive:!0,capture:!1};w.touch?(s.removeEventListener(t.start,this.scrollbar.onDragStart,a),s.removeEventListener(t.move,this.scrollbar.onDragMove,a),s.removeEventListener(t.end,this.scrollbar.onDragEnd,r)):(s.removeEventListener(i.start,this.scrollbar.onDragStart,a),n.removeEventListener(i.move,this.scrollbar.onDragMove,a),n.removeEventListener(i.end,this.scrollbar.onDragEnd,r))}},init:function(){if(this.params.scrollbar.el){var e=this.scrollbar,t=this.$el,i=this.params.scrollbar,n=a(i.el);this.params.uniqueNavElements&&"string"==typeof i.el&&n.length>1&&1===t.find(i.el).length&&(n=t.find(i.el));var o=n.find(".".concat(this.params.scrollbar.dragClass));0===o.length&&(o=a('
')),n.append(o)),y.extend(e,{$el:n,el:n[0],$dragEl:o,dragEl:o[0]}),i.draggable&&e.enableDraggable()}},destroy:function(){this.scrollbar.disableDraggable()}},K={setTransform:function(e,t){var i=this.rtl,n=a(e),o=i?-1:1,s=n.attr("data-swiper-parallax")||"0",r=n.attr("data-swiper-parallax-x"),l=n.attr("data-swiper-parallax-y"),c=n.attr("data-swiper-parallax-scale"),d=n.attr("data-swiper-parallax-opacity");if(r||l?(r=r||"0",l=l||"0"):this.isHorizontal()?(r=s,l="0"):(l=s,r="0"),r=r.indexOf("%")>=0?"".concat(parseInt(r,10)*t*o,"%"):"".concat(r*t*o,"px"),l=l.indexOf("%")>=0?"".concat(parseInt(l,10)*t,"%"):"".concat(l*t,"px"),null!=d){var u=d-(d-1)*(1-Math.abs(t));n[0].style.opacity=u}if(null==c)n.transform("translate3d(".concat(r,", ").concat(l,", 0px)"));else{var h=c-(c-1)*(1-Math.abs(t));n.transform("translate3d(".concat(r,", ").concat(l,", 0px) scale(").concat(h,")"))}},setTranslate:function(){var e=this,t=e.$el,i=e.slides,n=e.progress,o=e.snapGrid;t.children("[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y]").each(function(t,i){e.parallax.setTransform(i,n)}),i.each(function(t,i){var s=i.progress;e.params.slidesPerGroup>1&&"auto"!==e.params.slidesPerView&&(s+=Math.ceil(t/2)-n*(o.length-1)),s=Math.min(Math.max(s,-1),1),a(i).find("[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y]").each(function(t,i){e.parallax.setTransform(i,s)})})},setTransition:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.params.speed;this.$el.find("[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y]").each(function(t,i){var n=a(i),o=parseInt(n.attr("data-swiper-parallax-duration"),10)||e;0===e&&(o=0),n.transition(o)})}},J={getDistanceBetweenTouches:function(e){if(e.targetTouches.length<2)return 1;var t=e.targetTouches[0].pageX,i=e.targetTouches[0].pageY,n=e.targetTouches[1].pageX,o=e.targetTouches[1].pageY;return Math.sqrt(Math.pow(n-t,2)+Math.pow(o-i,2))},onGestureStart:function(e){var t=this.params.zoom,i=this.zoom,n=i.gesture;if(i.fakeGestureTouched=!1,i.fakeGestureMoved=!1,!w.gestures){if("touchstart"!==e.type||"touchstart"===e.type&&e.targetTouches.length<2)return;i.fakeGestureTouched=!0,n.scaleStart=J.getDistanceBetweenTouches(e)}n.$slideEl&&n.$slideEl.length||(n.$slideEl=a(e.target).closest(".swiper-slide"),0===n.$slideEl.length&&(n.$slideEl=this.slides.eq(this.activeIndex)),n.$imageEl=n.$slideEl.find("img, svg, canvas"),n.$imageWrapEl=n.$imageEl.parent(".".concat(t.containerClass)),n.maxRatio=n.$imageWrapEl.attr("data-swiper-zoom")||t.maxRatio,0!==n.$imageWrapEl.length)?(n.$imageEl.transition(0),this.zoom.isScaling=!0):n.$imageEl=void 0},onGestureChange:function(e){var t=this.params.zoom,i=this.zoom,n=i.gesture;if(!w.gestures){if("touchmove"!==e.type||"touchmove"===e.type&&e.targetTouches.length<2)return;i.fakeGestureMoved=!0,n.scaleMove=J.getDistanceBetweenTouches(e)}n.$imageEl&&0!==n.$imageEl.length&&(w.gestures?i.scale=e.scale*i.currentScale:i.scale=n.scaleMove/n.scaleStart*i.currentScale,i.scale>n.maxRatio&&(i.scale=n.maxRatio-1+Math.pow(i.scale-n.maxRatio+1,.5)),i.scalen.touchesStart.x))return void(n.isTouched=!1);if(!this.isHorizontal()&&(Math.floor(n.minY)===Math.floor(n.startY)&&n.touchesCurrent.yn.touchesStart.y))return void(n.isTouched=!1)}e.preventDefault(),e.stopPropagation(),n.isMoved=!0,n.currentX=n.touchesCurrent.x-n.touchesStart.x+n.startX,n.currentY=n.touchesCurrent.y-n.touchesStart.y+n.startY,n.currentXn.maxX&&(n.currentX=n.maxX-1+Math.pow(n.currentX-n.maxX+1,.8)),n.currentYn.maxY&&(n.currentY=n.maxY-1+Math.pow(n.currentY-n.maxY+1,.8)),o.prevPositionX||(o.prevPositionX=n.touchesCurrent.x),o.prevPositionY||(o.prevPositionY=n.touchesCurrent.y),o.prevTime||(o.prevTime=Date.now()),o.x=(n.touchesCurrent.x-o.prevPositionX)/(Date.now()-o.prevTime)/2,o.y=(n.touchesCurrent.y-o.prevPositionY)/(Date.now()-o.prevTime)/2,Math.abs(n.touchesCurrent.x-o.prevPositionX)<2&&(o.x=0),Math.abs(n.touchesCurrent.y-o.prevPositionY)<2&&(o.y=0),o.prevPositionX=n.touchesCurrent.x,o.prevPositionY=n.touchesCurrent.y,o.prevTime=Date.now(),i.$imageWrapEl.transform("translate3d(".concat(n.currentX,"px, ").concat(n.currentY,"px,0)"))}}},onTouchEnd:function(){var e=this.zoom,t=e.gesture,i=e.image,n=e.velocity;if(t.$imageEl&&0!==t.$imageEl.length){if(!i.isTouched||!i.isMoved)return i.isTouched=!1,void(i.isMoved=!1);i.isTouched=!1,i.isMoved=!1;var o=300,s=300,a=n.x*o,r=i.currentX+a,l=n.y*s,c=i.currentY+l;0!==n.x&&(o=Math.abs((r-i.currentX)/n.x)),0!==n.y&&(s=Math.abs((c-i.currentY)/n.y));var d=Math.max(o,s);i.currentX=r,i.currentY=c;var u=i.width*e.scale,h=i.height*e.scale;i.minX=Math.min(t.slideWidth/2-u/2,0),i.maxX=-i.minX,i.minY=Math.min(t.slideHeight/2-h/2,0),i.maxY=-i.minY,i.currentX=Math.max(Math.min(i.currentX,i.maxX),i.minX),i.currentY=Math.max(Math.min(i.currentY,i.maxY),i.minY),t.$imageWrapEl.transition(d).transform("translate3d(".concat(i.currentX,"px, ").concat(i.currentY,"px,0)"))}},onTransitionEnd:function(){var e=this.zoom,t=e.gesture;t.$slideEl&&this.previousIndex!==this.activeIndex&&(t.$imageEl.transform("translate3d(0,0,0) scale(1)"),t.$imageWrapEl.transform("translate3d(0,0,0)"),e.scale=1,e.currentScale=1,t.$slideEl=void 0,t.$imageEl=void 0,t.$imageWrapEl=void 0)},toggle:function(e){var t=this.zoom;t.scale&&1!==t.scale?t.out():t.in(e)},in:function(e){var t,i,n,o,s,r,l,c,d,u,h,p,f,m,g,v,b=this.zoom,y=this.params.zoom,w=b.gesture,x=b.image;(w.$slideEl||(w.$slideEl=this.clickedSlide?a(this.clickedSlide):this.slides.eq(this.activeIndex),w.$imageEl=w.$slideEl.find("img, svg, canvas"),w.$imageWrapEl=w.$imageEl.parent(".".concat(y.containerClass))),w.$imageEl&&0!==w.$imageEl.length)&&(w.$slideEl.addClass("".concat(y.zoomedSlideClass)),void 0===x.touchesStart.x&&e?(t="touchend"===e.type?e.changedTouches[0].pageX:e.pageX,i="touchend"===e.type?e.changedTouches[0].pageY:e.pageY):(t=x.touchesStart.x,i=x.touchesStart.y),b.scale=w.$imageWrapEl.attr("data-swiper-zoom")||y.maxRatio,b.currentScale=w.$imageWrapEl.attr("data-swiper-zoom")||y.maxRatio,e?(g=w.$slideEl[0].offsetWidth,v=w.$slideEl[0].offsetHeight,n=w.$slideEl.offset().left+g/2-t,o=w.$slideEl.offset().top+v/2-i,l=w.$imageEl[0].offsetWidth,c=w.$imageEl[0].offsetHeight,d=l*b.scale,u=c*b.scale,f=-(h=Math.min(g/2-d/2,0)),m=-(p=Math.min(v/2-u/2,0)),(s=n*b.scale)f&&(s=f),(r=o*b.scale)m&&(r=m)):(s=0,r=0),w.$imageWrapEl.transition(300).transform("translate3d(".concat(s,"px, ").concat(r,"px,0)")),w.$imageEl.transition(300).transform("translate3d(0,0,0) scale(".concat(b.scale,")")))},out:function(){var e=this.zoom,t=this.params.zoom,i=e.gesture;i.$slideEl||(i.$slideEl=this.clickedSlide?a(this.clickedSlide):this.slides.eq(this.activeIndex),i.$imageEl=i.$slideEl.find("img, svg, canvas"),i.$imageWrapEl=i.$imageEl.parent(".".concat(t.containerClass))),i.$imageEl&&0!==i.$imageEl.length&&(e.scale=1,e.currentScale=1,i.$imageWrapEl.transition(300).transform("translate3d(0,0,0)"),i.$imageEl.transition(300).transform("translate3d(0,0,0) scale(1)"),i.$slideEl.removeClass("".concat(t.zoomedSlideClass)),i.$slideEl=void 0)},enable:function(){var e=this.zoom;if(!e.enabled){e.enabled=!0;var t=!("touchstart"!==this.touchEvents.start||!w.passiveListener||!this.params.passiveListeners)&&{passive:!0,capture:!1};w.gestures?(this.$wrapperEl.on("gesturestart",".swiper-slide",e.onGestureStart,t),this.$wrapperEl.on("gesturechange",".swiper-slide",e.onGestureChange,t),this.$wrapperEl.on("gestureend",".swiper-slide",e.onGestureEnd,t)):"touchstart"===this.touchEvents.start&&(this.$wrapperEl.on(this.touchEvents.start,".swiper-slide",e.onGestureStart,t),this.$wrapperEl.on(this.touchEvents.move,".swiper-slide",e.onGestureChange,t),this.$wrapperEl.on(this.touchEvents.end,".swiper-slide",e.onGestureEnd,t)),this.$wrapperEl.on(this.touchEvents.move,".".concat(this.params.zoom.containerClass),e.onTouchMove)}},disable:function(){var e=this.zoom;if(e.enabled){this.zoom.enabled=!1;var t=!("touchstart"!==this.touchEvents.start||!w.passiveListener||!this.params.passiveListeners)&&{passive:!0,capture:!1};w.gestures?(this.$wrapperEl.off("gesturestart",".swiper-slide",e.onGestureStart,t),this.$wrapperEl.off("gesturechange",".swiper-slide",e.onGestureChange,t),this.$wrapperEl.off("gestureend",".swiper-slide",e.onGestureEnd,t)):"touchstart"===this.touchEvents.start&&(this.$wrapperEl.off(this.touchEvents.start,".swiper-slide",e.onGestureStart,t),this.$wrapperEl.off(this.touchEvents.move,".swiper-slide",e.onGestureChange,t),this.$wrapperEl.off(this.touchEvents.end,".swiper-slide",e.onGestureEnd,t)),this.$wrapperEl.off(this.touchEvents.move,".".concat(this.params.zoom.containerClass),e.onTouchMove)}}},Q={loadInSlide:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=this,n=i.params.lazy;if(void 0!==e&&0!==i.slides.length){var o=i.virtual&&i.params.virtual.enabled?i.$wrapperEl.children(".".concat(i.params.slideClass,'[data-swiper-slide-index="').concat(e,'"]')):i.slides.eq(e),s=o.find(".".concat(n.elementClass,":not(.").concat(n.loadedClass,"):not(.").concat(n.loadingClass,")"));!o.hasClass(n.elementClass)||o.hasClass(n.loadedClass)||o.hasClass(n.loadingClass)||(s=s.add(o[0])),0!==s.length&&s.each(function(e,s){var r=a(s);r.addClass(n.loadingClass);var l=r.attr("data-background"),c=r.attr("data-src"),d=r.attr("data-srcset"),u=r.attr("data-sizes");i.loadImage(r[0],c||l,d,u,!1,function(){if(null!=i&&i&&(!i||i.params)&&!i.destroyed){if(l?(r.css("background-image",'url("'.concat(l,'")')),r.removeAttr("data-background")):(d&&(r.attr("srcset",d),r.removeAttr("data-srcset")),u&&(r.attr("sizes",u),r.removeAttr("data-sizes")),c&&(r.attr("src",c),r.removeAttr("data-src"))),r.addClass(n.loadedClass).removeClass(n.loadingClass),o.find(".".concat(n.preloaderClass)).remove(),i.params.loop&&t){var e=o.attr("data-swiper-slide-index");if(o.hasClass(i.params.slideDuplicateClass)){var s=i.$wrapperEl.children('[data-swiper-slide-index="'.concat(e,'"]:not(.').concat(i.params.slideDuplicateClass,")"));i.lazy.loadInSlide(s.index(),!1)}else{var a=i.$wrapperEl.children(".".concat(i.params.slideDuplicateClass,'[data-swiper-slide-index="').concat(e,'"]'));i.lazy.loadInSlide(a.index(),!1)}}i.emit("lazyImageReady",o[0],r[0])}}),i.emit("lazyImageLoad",o[0],r[0])})}},load:function(){var e=this,t=e.$wrapperEl,i=e.params,n=e.slides,o=e.activeIndex,s=e.virtual&&i.virtual.enabled,r=i.lazy,l=i.slidesPerView;function c(e){if(s){if(t.children(".".concat(i.slideClass,'[data-swiper-slide-index="').concat(e,'"]')).length)return!0}else if(n[e])return!0;return!1}function d(e){return s?a(e).attr("data-swiper-slide-index"):a(e).index()}if("auto"===l&&(l=0),e.lazy.initialImageLoaded||(e.lazy.initialImageLoaded=!0),e.params.watchSlidesVisibility)t.children(".".concat(i.slideVisibleClass)).each(function(t,i){var n=s?a(i).attr("data-swiper-slide-index"):a(i).index();e.lazy.loadInSlide(n)});else if(l>1)for(var u=o;u1||r.loadPrevNextAmount&&r.loadPrevNextAmount>1){for(var h=r.loadPrevNextAmount,p=l,f=Math.min(o+p+Math.max(h,p),n.length),m=Math.max(o-Math.max(p,h),0),g=o+l;g0&&e.lazy.loadInSlide(d(b));var y=t.children(".".concat(i.slidePrevClass));y.length>0&&e.lazy.loadInSlide(d(y))}}},Z={LinearSpline:function(e,t){var i,n,o,s,a,r=function(e,t){for(n=-1,i=e.length;i-n>1;)e[o=i+n>>1]<=t?n=o:i=o;return i};return this.x=e,this.y=t,this.lastIndex=e.length-1,this.interpolate=function(e){return e?(a=r(this.x,e),s=a-1,(e-this.x[s])*(this.y[a]-this.y[s])/(this.x[a]-this.x[s])+this.y[s]):0},this},getInterpolateFunction:function(e){this.controller.spline||(this.controller.spline=this.params.loop?new Z.LinearSpline(this.slidesGrid,e.slidesGrid):new Z.LinearSpline(this.snapGrid,e.snapGrid))},setTranslate:function(e,t){var i,n,o=this,s=o.controller.control;function a(e){var t=o.rtlTranslate?-o.translate:o.translate;"slide"===o.params.controller.by&&(o.controller.getInterpolateFunction(e),n=-o.controller.spline.interpolate(-t)),n&&"container"!==o.params.controller.by||(i=(e.maxTranslate()-e.minTranslate())/(o.maxTranslate()-o.minTranslate()),n=(t-o.minTranslate())*i+e.minTranslate()),o.params.controller.inverse&&(n=e.maxTranslate()-n),e.updateProgress(n),e.setTranslate(n,o),e.updateActiveIndex(),e.updateSlidesClasses()}if(Array.isArray(s))for(var r=0;r0&&(this.isBeginning?this.a11y.disableEl(i):this.a11y.enableEl(i)),t&&t.length>0&&(this.isEnd?this.a11y.disableEl(t):this.a11y.enableEl(t))}},updatePagination:function(){var e=this,t=e.params.a11y;e.pagination&&e.params.pagination.clickable&&e.pagination.bullets&&e.pagination.bullets.length&&e.pagination.bullets.each(function(i,n){var o=a(n);e.a11y.makeElFocusable(o),e.a11y.addElRole(o,"button"),e.a11y.addElLabel(o,t.paginationBulletMessage.replace(/{{index}}/,o.index()+1))})},init:function(){this.$el.append(this.a11y.liveRegion);var e,t,i=this.params.a11y;this.navigation&&this.navigation.$nextEl&&(e=this.navigation.$nextEl),this.navigation&&this.navigation.$prevEl&&(t=this.navigation.$prevEl),e&&(this.a11y.makeElFocusable(e),this.a11y.addElRole(e,"button"),this.a11y.addElLabel(e,i.nextSlideMessage),e.on("keydown",this.a11y.onEnterKey)),t&&(this.a11y.makeElFocusable(t),this.a11y.addElRole(t,"button"),this.a11y.addElLabel(t,i.prevSlideMessage),t.on("keydown",this.a11y.onEnterKey)),this.pagination&&this.params.pagination.clickable&&this.pagination.bullets&&this.pagination.bullets.length&&this.pagination.$el.on("keydown",".".concat(this.params.pagination.bulletClass),this.a11y.onEnterKey)},destroy:function(){var e,t;this.a11y.liveRegion&&this.a11y.liveRegion.length>0&&this.a11y.liveRegion.remove(),this.navigation&&this.navigation.$nextEl&&(e=this.navigation.$nextEl),this.navigation&&this.navigation.$prevEl&&(t=this.navigation.$prevEl),e&&e.off("keydown",this.a11y.onEnterKey),t&&t.off("keydown",this.a11y.onEnterKey),this.pagination&&this.params.pagination.clickable&&this.pagination.bullets&&this.pagination.bullets.length&&this.pagination.$el.off("keydown",".".concat(this.params.pagination.bulletClass),this.a11y.onEnterKey)}},te={init:function(){if(this.params.history){if(!o.history||!o.history.pushState)return this.params.history.enabled=!1,void(this.params.hashNavigation.enabled=!0);var e=this.history;e.initialized=!0,e.paths=te.getPathValues(),(e.paths.key||e.paths.value)&&(e.scrollToSlide(0,e.paths.value,this.params.runCallbacksOnInit),this.params.history.replaceState||o.addEventListener("popstate",this.history.setHistoryPopState))}},destroy:function(){this.params.history.replaceState||o.removeEventListener("popstate",this.history.setHistoryPopState)},setHistoryPopState:function(){this.history.paths=te.getPathValues(),this.history.scrollToSlide(this.params.speed,this.history.paths.value,!1)},getPathValues:function(){var e=o.location.pathname.slice(1).split("/").filter(function(e){return""!==e}),t=e.length;return{key:e[t-2],value:e[t-1]}},setHistory:function(e,t){if(this.history.initialized&&this.params.history.enabled){var i=this.slides.eq(t),n=te.slugify(i.attr("data-history"));o.location.pathname.includes(e)||(n="".concat(e,"/").concat(n));var s=o.history.state;s&&s.value===n||(this.params.history.replaceState?o.history.replaceState({value:n},null,n):o.history.pushState({value:n},null,n))}},slugify:function(e){return e.toString().replace(/\s+/g,"-").replace(/[^\w-]+/g,"").replace(/--+/g,"-").replace(/^-+/,"").replace(/-+$/,"")},scrollToSlide:function(e,t,i){if(t)for(var n=0,o=this.slides.length;n'),i.append(e)),e.css({height:"".concat(o,"px")})):0===(e=t.find(".swiper-cube-shadow")).length&&(e=a('
'),t.append(e)));for(var p=0;p-1&&(h=90*m+90*b,r&&(h=90*-m-90*b)),f.transform(E),c.slideShadows){var T=d?f.find(".swiper-slide-shadow-left"):f.find(".swiper-slide-shadow-top"),S=d?f.find(".swiper-slide-shadow-right"):f.find(".swiper-slide-shadow-bottom");0===T.length&&(T=a('
')),f.append(T)),0===S.length&&(S=a('
')),f.append(S)),T.length&&(T[0].style.opacity=Math.max(-b,0)),S.length&&(S[0].style.opacity=Math.max(b,0))}}if(i.css({"-webkit-transform-origin":"50% 50% -".concat(l/2,"px"),"-moz-transform-origin":"50% 50% -".concat(l/2,"px"),"-ms-transform-origin":"50% 50% -".concat(l/2,"px"),"transform-origin":"50% 50% -".concat(l/2,"px")}),c.shadow)if(d)e.transform("translate3d(0px, ".concat(o/2+c.shadowOffset,"px, ").concat(-o/2,"px) rotateX(90deg) rotateZ(0deg) scale(").concat(c.shadowScale,")"));else{var k=Math.abs(h)-90*Math.floor(Math.abs(h)/90),M=1.5-(Math.sin(2*k*Math.PI/360)/2+Math.cos(2*k*Math.PI/360)/2),_=c.shadowScale,D=c.shadowScale/M,R=c.shadowOffset;e.transform("scale3d(".concat(_,", 1, ").concat(D,") translate3d(0px, ").concat(s/2+R,"px, ").concat(-s/2/D,"px) rotateX(-90deg)"))}var L=x.isSafari||x.isUiWebView?-l/2:0;i.transform("translate3d(0px,0,".concat(L,"px) rotateX(").concat(this.isHorizontal()?0:h,"deg) rotateY(").concat(this.isHorizontal()?-h:0,"deg)"))},setTransition:function(e){var t=this.$el;this.slides.transition(e).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(e),this.params.cubeEffect.shadow&&!this.isHorizontal()&&t.find(".swiper-cube-shadow").transition(e)}},ae={setTranslate:function(){for(var e=this.slides,t=this.rtlTranslate,i=0;i')),n.append(d)),0===u.length&&(u=a('
')),n.append(u)),d.length&&(d[0].style.opacity=Math.max(-o,0)),u.length&&(u[0].style.opacity=Math.max(o,0))}n.transform("translate3d(".concat(l,"px, ").concat(c,"px, 0px) rotateX(").concat(r,"deg) rotateY(").concat(s,"deg)"))}},setTransition:function(e){var t=this,i=t.slides,n=t.activeIndex,o=t.$wrapperEl;if(i.transition(e).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(e),t.params.virtualTranslate&&0!==e){var s=!1;i.eq(n).transitionEnd(function(){if(!s&&t&&!t.destroyed){s=!0,t.animating=!1;for(var e=["webkitTransitionEnd","transitionend"],i=0;i')),f.append(T)),0===S.length&&(S=a('
')),f.append(S)),T.length&&(T[0].style.opacity=g>0?g:0),S.length&&(S[0].style.opacity=-g>0?-g:0)}}(w.pointerEvents||w.prefixedPointerEvents)&&(n[0].style.perspectiveOrigin="".concat(c,"px 50%"))},setTransition:function(e){this.slides.transition(e).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(e)}},le={init:function(){var e=this.params.thumbs,t=this.constructor;e.swiper instanceof t?(this.thumbs.swiper=e.swiper,y.extend(this.thumbs.swiper.originalParams,{watchSlidesProgress:!0,slideToClickedSlide:!1}),y.extend(this.thumbs.swiper.params,{watchSlidesProgress:!0,slideToClickedSlide:!1})):y.isObject(e.swiper)&&(this.thumbs.swiper=new t(y.extend({},e.swiper,{watchSlidesVisibility:!0,watchSlidesProgress:!0,slideToClickedSlide:!1})),this.thumbs.swiperCreated=!0),this.thumbs.swiper.$el.addClass(this.params.thumbs.thumbsContainerClass),this.thumbs.swiper.on("tap",this.thumbs.onThumbClick)},onThumbClick:function(){var e=this.thumbs.swiper;if(e){var t=e.clickedIndex,i=e.clickedSlide;if(!(i&&a(i).hasClass(this.params.thumbs.slideThumbActiveClass)||null==t)){var n;if(n=e.params.loop?parseInt(a(e.clickedSlide).attr("data-swiper-slide-index"),10):t,this.params.loop){var o=this.activeIndex;this.slides.eq(o).hasClass(this.params.slideDuplicateClass)&&(this.loopFix(),this._clientLeft=this.$wrapperEl[0].clientLeft,o=this.activeIndex);var s=this.slides.eq(o).prevAll('[data-swiper-slide-index="'.concat(n,'"]')).eq(0).index(),r=this.slides.eq(o).nextAll('[data-swiper-slide-index="'.concat(n,'"]')).eq(0).index();n=void 0===s?r:void 0===r?s:r-oo?n-Math.floor(i/2)+1:n+Math.floor(i/2)-1:n>o&&(n=n-i+1),t.slideTo(n,e?0:void 0))}var r=1,l=this.params.thumbs.slideThumbActiveClass;if(this.params.slidesPerView>1&&!this.params.centeredSlides&&(r=this.params.slidesPerView),t.slides.removeClass(l),t.params.loop)for(var c=0;c0&&!a(e.target).hasClass(this.params.pagination.bulletClass)&&(!0===this.pagination.$el.hasClass(this.params.pagination.hiddenClass)?this.emit("paginationShow",this):this.emit("paginationHide",this),this.pagination.$el.toggleClass(this.params.pagination.hiddenClass))}}},{name:"scrollbar",params:{scrollbar:{el:null,dragSize:"auto",hide:!1,draggable:!1,snapOnRelease:!0,lockClass:"swiper-scrollbar-lock",dragClass:"swiper-scrollbar-drag"}},create:function(){y.extend(this,{scrollbar:{init:U.init.bind(this),destroy:U.destroy.bind(this),updateSize:U.updateSize.bind(this),setTranslate:U.setTranslate.bind(this),setTransition:U.setTransition.bind(this),enableDraggable:U.enableDraggable.bind(this),disableDraggable:U.disableDraggable.bind(this),setDragPosition:U.setDragPosition.bind(this),onDragStart:U.onDragStart.bind(this),onDragMove:U.onDragMove.bind(this),onDragEnd:U.onDragEnd.bind(this),isTouched:!1,timeout:null,dragTimeout:null}})},on:{init:function(){this.scrollbar.init(),this.scrollbar.updateSize(),this.scrollbar.setTranslate()},update:function(){this.scrollbar.updateSize()},resize:function(){this.scrollbar.updateSize()},observerUpdate:function(){this.scrollbar.updateSize()},setTranslate:function(){this.scrollbar.setTranslate()},setTransition:function(e){this.scrollbar.setTransition(e)},destroy:function(){this.scrollbar.destroy()}}},{name:"parallax",params:{parallax:{enabled:!1}},create:function(){y.extend(this,{parallax:{setTransform:K.setTransform.bind(this),setTranslate:K.setTranslate.bind(this),setTransition:K.setTransition.bind(this)}})},on:{beforeInit:function(){this.params.parallax.enabled&&(this.params.watchSlidesProgress=!0,this.originalParams.watchSlidesProgress=!0)},init:function(){this.params.parallax.enabled&&this.parallax.setTranslate()},setTranslate:function(){this.params.parallax.enabled&&this.parallax.setTranslate()},setTransition:function(e){this.params.parallax.enabled&&this.parallax.setTransition(e)}}},{name:"zoom",params:{zoom:{enabled:!1,maxRatio:3,minRatio:1,toggle:!0,containerClass:"swiper-zoom-container",zoomedSlideClass:"swiper-slide-zoomed"}},create:function(){var e=this,t={enabled:!1,scale:1,currentScale:1,isScaling:!1,gesture:{$slideEl:void 0,slideWidth:void 0,slideHeight:void 0,$imageEl:void 0,$imageWrapEl:void 0,maxRatio:3},image:{isTouched:void 0,isMoved:void 0,currentX:void 0,currentY:void 0,minX:void 0,minY:void 0,maxX:void 0,maxY:void 0,width:void 0,height:void 0,startX:void 0,startY:void 0,touchesStart:{},touchesCurrent:{}},velocity:{x:void 0,y:void 0,prevPositionX:void 0,prevPositionY:void 0,prevTime:void 0}};"onGestureStart onGestureChange onGestureEnd onTouchStart onTouchMove onTouchEnd onTransitionEnd toggle enable disable in out".split(" ").forEach(function(i){t[i]=J[i].bind(e)}),y.extend(e,{zoom:t});var i=1;Object.defineProperty(e.zoom,"scale",{get:function(){return i},set:function(t){if(i!==t){var n=e.zoom.gesture.$imageEl?e.zoom.gesture.$imageEl[0]:void 0,o=e.zoom.gesture.$slideEl?e.zoom.gesture.$slideEl[0]:void 0;e.emit("zoomChange",t,n,o)}i=t}})},on:{init:function(){this.params.zoom.enabled&&this.zoom.enable()},destroy:function(){this.zoom.disable()},touchStart:function(e){this.zoom.enabled&&this.zoom.onTouchStart(e)},touchEnd:function(e){this.zoom.enabled&&this.zoom.onTouchEnd(e)},doubleTap:function(e){this.params.zoom.enabled&&this.zoom.enabled&&this.params.zoom.toggle&&this.zoom.toggle(e)},transitionEnd:function(){this.zoom.enabled&&this.params.zoom.enabled&&this.zoom.onTransitionEnd()}}},{name:"lazy",params:{lazy:{enabled:!1,loadPrevNext:!1,loadPrevNextAmount:1,loadOnTransitionStart:!1,elementClass:"swiper-lazy",loadingClass:"swiper-lazy-loading",loadedClass:"swiper-lazy-loaded",preloaderClass:"swiper-lazy-preloader"}},create:function(){y.extend(this,{lazy:{initialImageLoaded:!1,load:Q.load.bind(this),loadInSlide:Q.loadInSlide.bind(this)}})},on:{beforeInit:function(){this.params.lazy.enabled&&this.params.preloadImages&&(this.params.preloadImages=!1)},init:function(){this.params.lazy.enabled&&!this.params.loop&&0===this.params.initialSlide&&this.lazy.load()},scroll:function(){this.params.freeMode&&!this.params.freeModeSticky&&this.lazy.load()},resize:function(){this.params.lazy.enabled&&this.lazy.load()},scrollbarDragMove:function(){this.params.lazy.enabled&&this.lazy.load()},transitionStart:function(){this.params.lazy.enabled&&(this.params.lazy.loadOnTransitionStart||!this.params.lazy.loadOnTransitionStart&&!this.lazy.initialImageLoaded)&&this.lazy.load()},transitionEnd:function(){this.params.lazy.enabled&&!this.params.lazy.loadOnTransitionStart&&this.lazy.load()}}},{name:"controller",params:{controller:{control:void 0,inverse:!1,by:"slide"}},create:function(){y.extend(this,{controller:{control:this.params.controller.control,getInterpolateFunction:Z.getInterpolateFunction.bind(this),setTranslate:Z.setTranslate.bind(this),setTransition:Z.setTransition.bind(this)}})},on:{update:function(){this.controller.control&&this.controller.spline&&(this.controller.spline=void 0,delete this.controller.spline)},resize:function(){this.controller.control&&this.controller.spline&&(this.controller.spline=void 0,delete this.controller.spline)},observerUpdate:function(){this.controller.control&&this.controller.spline&&(this.controller.spline=void 0,delete this.controller.spline)},setTranslate:function(e,t){this.controller.control&&this.controller.setTranslate(e,t)},setTransition:function(e,t){this.controller.control&&this.controller.setTransition(e,t)}}},{name:"a11y",params:{a11y:{enabled:!0,notificationClass:"swiper-notification",prevSlideMessage:"Previous slide",nextSlideMessage:"Next slide",firstSlideMessage:"This is the first slide",lastSlideMessage:"This is the last slide",paginationBulletMessage:"Go to slide {{index}}"}},create:function(){var e=this;y.extend(e,{a11y:{liveRegion:a(''))}}),Object.keys(ee).forEach(function(t){e.a11y[t]=ee[t].bind(e)})},on:{init:function(){this.params.a11y.enabled&&(this.a11y.init(),this.a11y.updateNavigation())},toEdge:function(){this.params.a11y.enabled&&this.a11y.updateNavigation()},fromEdge:function(){this.params.a11y.enabled&&this.a11y.updateNavigation()},paginationUpdate:function(){this.params.a11y.enabled&&this.a11y.updatePagination()},destroy:function(){this.params.a11y.enabled&&this.a11y.destroy()}}},{name:"history",params:{history:{enabled:!1,replaceState:!1,key:"slides"}},create:function(){y.extend(this,{history:{init:te.init.bind(this),setHistory:te.setHistory.bind(this),setHistoryPopState:te.setHistoryPopState.bind(this),scrollToSlide:te.scrollToSlide.bind(this),destroy:te.destroy.bind(this)}})},on:{init:function(){this.params.history.enabled&&this.history.init()},destroy:function(){this.params.history.enabled&&this.history.destroy()},transitionEnd:function(){this.history.initialized&&this.history.setHistory(this.params.history.key,this.activeIndex)}}},{name:"hash-navigation",params:{hashNavigation:{enabled:!1,replaceState:!1,watchState:!1}},create:function(){y.extend(this,{hashNavigation:{initialized:!1,init:ie.init.bind(this),destroy:ie.destroy.bind(this),setHash:ie.setHash.bind(this),onHashCange:ie.onHashCange.bind(this)}})},on:{init:function(){this.params.hashNavigation.enabled&&this.hashNavigation.init()},destroy:function(){this.params.hashNavigation.enabled&&this.hashNavigation.destroy()},transitionEnd:function(){this.hashNavigation.initialized&&this.hashNavigation.setHash()}}},{name:"autoplay",params:{autoplay:{enabled:!1,delay:3e3,waitForTransition:!0,disableOnInteraction:!0,stopOnLastSlide:!1,reverseDirection:!1}},create:function(){var e=this;y.extend(e,{autoplay:{running:!1,paused:!1,run:ne.run.bind(e),start:ne.start.bind(e),stop:ne.stop.bind(e),pause:ne.pause.bind(e),onTransitionEnd:function(t){e&&!e.destroyed&&e.$wrapperEl&&t.target===this&&(e.$wrapperEl[0].removeEventListener("transitionend",e.autoplay.onTransitionEnd),e.$wrapperEl[0].removeEventListener("webkitTransitionEnd",e.autoplay.onTransitionEnd),e.autoplay.paused=!1,e.autoplay.running?e.autoplay.run():e.autoplay.stop())}}})},on:{init:function(){this.params.autoplay.enabled&&this.autoplay.start()},beforeTransitionStart:function(e,t){this.autoplay.running&&(t||!this.params.autoplay.disableOnInteraction?this.autoplay.pause(e):this.autoplay.stop())},sliderFirstMove:function(){this.autoplay.running&&(this.params.autoplay.disableOnInteraction?this.autoplay.stop():this.autoplay.pause())},destroy:function(){this.autoplay.running&&this.autoplay.stop()}}},{name:"effect-fade",params:{fadeEffect:{crossFade:!1}},create:function(){y.extend(this,{fadeEffect:{setTranslate:oe.setTranslate.bind(this),setTransition:oe.setTransition.bind(this)}})},on:{beforeInit:function(){if("fade"===this.params.effect){this.classNames.push("".concat(this.params.containerModifierClass,"fade"));var e={slidesPerView:1,slidesPerColumn:1,slidesPerGroup:1,watchSlidesProgress:!0,spaceBetween:0,virtualTranslate:!0};y.extend(this.params,e),y.extend(this.originalParams,e)}},setTranslate:function(){"fade"===this.params.effect&&this.fadeEffect.setTranslate()},setTransition:function(e){"fade"===this.params.effect&&this.fadeEffect.setTransition(e)}}},{name:"effect-cube",params:{cubeEffect:{slideShadows:!0,shadow:!0,shadowOffset:20,shadowScale:.94}},create:function(){y.extend(this,{cubeEffect:{setTranslate:se.setTranslate.bind(this),setTransition:se.setTransition.bind(this)}})},on:{beforeInit:function(){if("cube"===this.params.effect){this.classNames.push("".concat(this.params.containerModifierClass,"cube")),this.classNames.push("".concat(this.params.containerModifierClass,"3d"));var e={slidesPerView:1,slidesPerColumn:1,slidesPerGroup:1,watchSlidesProgress:!0,resistanceRatio:0,spaceBetween:0,centeredSlides:!1,virtualTranslate:!0};y.extend(this.params,e),y.extend(this.originalParams,e)}},setTranslate:function(){"cube"===this.params.effect&&this.cubeEffect.setTranslate()},setTransition:function(e){"cube"===this.params.effect&&this.cubeEffect.setTransition(e)}}},{name:"effect-flip",params:{flipEffect:{slideShadows:!0,limitRotation:!0}},create:function(){y.extend(this,{flipEffect:{setTranslate:ae.setTranslate.bind(this),setTransition:ae.setTransition.bind(this)}})},on:{beforeInit:function(){if("flip"===this.params.effect){this.classNames.push("".concat(this.params.containerModifierClass,"flip")),this.classNames.push("".concat(this.params.containerModifierClass,"3d"));var e={slidesPerView:1,slidesPerColumn:1,slidesPerGroup:1,watchSlidesProgress:!0,spaceBetween:0,virtualTranslate:!0};y.extend(this.params,e),y.extend(this.originalParams,e)}},setTranslate:function(){"flip"===this.params.effect&&this.flipEffect.setTranslate()},setTransition:function(e){"flip"===this.params.effect&&this.flipEffect.setTransition(e)}}},{name:"effect-coverflow",params:{coverflowEffect:{rotate:50,stretch:0,depth:100,modifier:1,slideShadows:!0}},create:function(){y.extend(this,{coverflowEffect:{setTranslate:re.setTranslate.bind(this),setTransition:re.setTransition.bind(this)}})},on:{beforeInit:function(){"coverflow"===this.params.effect&&(this.classNames.push("".concat(this.params.containerModifierClass,"coverflow")),this.classNames.push("".concat(this.params.containerModifierClass,"3d")),this.params.watchSlidesProgress=!0,this.originalParams.watchSlidesProgress=!0)},setTranslate:function(){"coverflow"===this.params.effect&&this.coverflowEffect.setTranslate()},setTransition:function(e){"coverflow"===this.params.effect&&this.coverflowEffect.setTransition(e)}}},{name:"thumbs",params:{thumbs:{swiper:null,slideThumbActiveClass:"swiper-slide-thumb-active",thumbsContainerClass:"swiper-container-thumbs"}},create:function(){y.extend(this,{thumbs:{swiper:null,init:le.init.bind(this),update:le.update.bind(this),onThumbClick:le.onThumbClick.bind(this)}})},on:{beforeInit:function(){var e=this.params.thumbs;e&&e.swiper&&(this.thumbs.init(),this.thumbs.update(!0))},slideChange:function(){this.thumbs.swiper&&this.thumbs.update()},update:function(){this.thumbs.swiper&&this.thumbs.update()},resize:function(){this.thumbs.swiper&&this.thumbs.update()},observerUpdate:function(){this.thumbs.swiper&&this.thumbs.update()},setTransition:function(e){var t=this.thumbs.swiper;t&&t.setTransition(e)},beforeDestroy:function(){var e=this.thumbs.swiper;e&&this.thumbs.swiperCreated&&e&&e.destroy()}}}];void 0===I.use&&(I.use=I.Class.use,I.installModule=I.Class.installModule),I.use(ce);t.a=I},231:function(e,t){},233:function(e,t){},235:function(e,t){},237:function(e,t){},239:function(e,t){},241:function(e,t){},243:function(e,t){},27:function(e,t){function i(e){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(e){"object"===("undefined"==typeof window?"undefined":i(window))&&(n=window)}e.exports=n},28:function(e,t,i){"use strict";t.a=function(e){var t=this.constructor;return this.then(function(i){return t.resolve(e()).then(function(){return i})},function(i){return t.resolve(e()).then(function(){return t.reject(i)})})}},33:function(e,t,i){(function(t){e.exports=t.jQuery=i(54)}).call(this,i(27))},34:function(e,t){!function(e,t,i,n){"use strict";if(e.console=e.console||{info:function(e){}},i)if(i.fn.fancybox)console.info("fancyBox already initialized");else{var o,s,a={closeExisting:!1,loop:!1,gutter:50,keyboard:!0,preventCaptionOverlap:!0,arrows:!0,infobar:!0,smallBtn:"auto",toolbar:"auto",buttons:["zoom","slideShow","thumbs","close"],idleTime:3,protect:!1,modal:!1,image:{preload:!1},ajax:{settings:{data:{fancybox:!0}}},iframe:{tpl:'',preload:!0,css:{},attr:{scrolling:"auto"}},video:{tpl:'',format:"",autoStart:!0},defaultType:"image",animationEffect:"zoom",animationDuration:366,zoomOpacity:"auto",transitionEffect:"fade",transitionDuration:366,slideClass:"",baseClass:"",baseTpl:'',spinnerTpl:'
',errorTpl:'

{{ERROR}}

',btnTpl:{download:'',zoom:'',close:'',arrowLeft:'',arrowRight:'',smallBtn:''},parentEl:"body",hideScrollbar:!0,autoFocus:!0,backFocus:!0,trapFocus:!0,fullScreen:{autoStart:!1},touch:{vertical:!0,momentum:!0},hash:null,media:{},slideShow:{autoStart:!1,speed:3e3},thumbs:{autoStart:!1,hideOnClose:!0,parentEl:".fancybox-container",axis:"y"},wheel:"auto",onInit:i.noop,beforeLoad:i.noop,afterLoad:i.noop,beforeShow:i.noop,afterShow:i.noop,beforeClose:i.noop,afterClose:i.noop,onActivate:i.noop,onDeactivate:i.noop,clickContent:function(e,t){return"image"===e.type&&"zoom"},clickSlide:"close",clickOutside:"close",dblclickContent:!1,dblclickSlide:!1,dblclickOutside:!1,mobile:{preventCaptionOverlap:!1,idleTime:!1,clickContent:function(e,t){return"image"===e.type&&"toggleControls"},clickSlide:function(e,t){return"image"===e.type?"toggleControls":"close"},dblclickContent:function(e,t){return"image"===e.type&&"zoom"},dblclickSlide:function(e,t){return"image"===e.type&&"zoom"}},lang:"en",i18n:{en:{CLOSE:"Close",NEXT:"Next",PREV:"Previous",ERROR:"The requested content cannot be loaded.
Please try again later.",PLAY_START:"Start slideshow",PLAY_STOP:"Pause slideshow",FULL_SCREEN:"Full screen",THUMBS:"Thumbnails",DOWNLOAD:"Download",SHARE:"Share",ZOOM:"Zoom"},de:{CLOSE:"Schließen",NEXT:"Weiter",PREV:"Zurück",ERROR:"Die angeforderten Daten konnten nicht geladen werden.
Bitte versuchen Sie es später nochmal.",PLAY_START:"Diaschau starten",PLAY_STOP:"Diaschau beenden",FULL_SCREEN:"Vollbild",THUMBS:"Vorschaubilder",DOWNLOAD:"Herunterladen",SHARE:"Teilen",ZOOM:"Vergrößern"}}},r=i(e),l=i(t),c=0,d=e.requestAnimationFrame||e.webkitRequestAnimationFrame||e.mozRequestAnimationFrame||e.oRequestAnimationFrame||function(t){return e.setTimeout(t,1e3/60)},u=e.cancelAnimationFrame||e.webkitCancelAnimationFrame||e.mozCancelAnimationFrame||e.oCancelAnimationFrame||function(t){e.clearTimeout(t)},h=function(){var e,i=t.createElement("fakeelement"),n={transition:"transitionend",OTransition:"oTransitionEnd",MozTransition:"transitionend",WebkitTransition:"webkitTransitionEnd"};for(e in n)if(void 0!==i.style[e])return n[e];return"transitionend"}(),p=function(e){return e&&e.length&&e[0].offsetHeight},f=function(e,t){var n=i.extend(!0,{},e,t);return i.each(t,function(e,t){i.isArray(t)&&(n[e]=t)}),n},m=function(e,t,n){this.opts=f({index:n},i.fancybox.defaults),i.isPlainObject(t)&&(this.opts=f(this.opts,t)),i.fancybox.isMobile&&(this.opts=f(this.opts,this.opts.mobile)),this.id=this.opts.id||++c,this.currIndex=parseInt(this.opts.index,10)||0,this.prevIndex=null,this.prevPos=null,this.currPos=0,this.firstRun=!0,this.group=[],this.slides={},this.addContent(e),this.group.length&&this.init()};i.extend(m.prototype,{init:function(){var n,o,s=this,a=s.group[s.currIndex].opts;a.closeExisting&&i.fancybox.close(!0),i("body").addClass("fancybox-active"),!i.fancybox.getInstance()&&!1!==a.hideScrollbar&&!i.fancybox.isMobile&&t.body.scrollHeight>e.innerHeight&&(i("head").append('"),i("body").addClass("compensate-for-scrollbar")),o="",i.each(a.buttons,function(e,t){o+=a.btnTpl[t]||""}),n=i(s.translate(s,a.baseTpl.replace("{{buttons}}",o).replace("{{arrows}}",a.btnTpl.arrowLeft+a.btnTpl.arrowRight))).attr("id","fancybox-container-"+s.id).addClass(a.baseClass).data("FancyBox",s).appendTo(a.parentEl),s.$refs={container:n},["bg","inner","infobar","toolbar","stage","caption","navigation"].forEach(function(e){s.$refs[e]=n.find(".fancybox-"+e)}),s.trigger("onInit"),s.activate(),s.jumpTo(s.currIndex)},translate:function(e,t){var i=e.opts.i18n[e.opts.lang]||e.opts.i18n.en;return t.replace(/\{\{(\w+)\}\}/g,function(e,t){return void 0===i[t]?e:i[t]})},addContent:function(e){var t,n=this,o=i.makeArray(e);i.each(o,function(e,t){var o,s,a,r,l,c={},d={};i.isPlainObject(t)?(c=t,d=t.opts||t):"object"===i.type(t)&&i(t).length?(d=(o=i(t)).data()||{},(d=i.extend(!0,{},d,d.options)).$orig=o,c.src=n.opts.src||d.src||o.attr("href"),c.type||c.src||(c.type="inline",c.src=t)):c={type:"html",src:t+""},c.opts=i.extend(!0,{},n.opts,d),i.isArray(d.buttons)&&(c.opts.buttons=d.buttons),i.fancybox.isMobile&&c.opts.mobile&&(c.opts=f(c.opts,c.opts.mobile)),s=c.type||c.opts.type,r=c.src||"",!s&&r&&((a=r.match(/\.(mp4|mov|ogv|webm)((\?|#).*)?$/i))?(s="video",c.opts.video.format||(c.opts.video.format="video/"+("ogv"===a[1]?"ogg":a[1]))):r.match(/(^data:image\/[a-z0-9+\/=]*,)|(\.(jp(e|g|eg)|gif|png|bmp|webp|svg|ico)((\?|#).*)?$)/i)?s="image":r.match(/\.(pdf)((\?|#).*)?$/i)?(s="iframe",c=i.extend(!0,c,{contentType:"pdf",opts:{iframe:{preload:!1}}})):"#"===r.charAt(0)&&(s="inline")),s?c.type=s:n.trigger("objectNeedsType",c),c.contentType||(c.contentType=i.inArray(c.type,["html","inline","ajax"])>-1?"html":c.type),c.index=n.group.length,"auto"==c.opts.smallBtn&&(c.opts.smallBtn=i.inArray(c.type,["html","inline","ajax"])>-1),"auto"===c.opts.toolbar&&(c.opts.toolbar=!c.opts.smallBtn),c.$thumb=c.opts.$thumb||null,c.opts.$trigger&&c.index===n.opts.index&&(c.$thumb=c.opts.$trigger.find("img:first"),c.$thumb.length&&(c.opts.$orig=c.opts.$trigger)),c.$thumb&&c.$thumb.length||!c.opts.$orig||(c.$thumb=c.opts.$orig.find("img:first")),c.$thumb&&!c.$thumb.length&&(c.$thumb=null),c.thumb=c.opts.thumb||(c.$thumb?c.$thumb[0].src:null),"function"===i.type(c.opts.caption)&&(c.opts.caption=c.opts.caption.apply(t,[n,c])),"function"===i.type(n.opts.caption)&&(c.opts.caption=n.opts.caption.apply(t,[n,c])),c.opts.caption instanceof i||(c.opts.caption=void 0===c.opts.caption?"":c.opts.caption+""),"ajax"===c.type&&(l=r.split(/\s+/,2)).length>1&&(c.src=l.shift(),c.opts.filter=l.shift()),c.opts.modal&&(c.opts=i.extend(!0,c.opts,{trapFocus:!0,infobar:0,toolbar:0,smallBtn:0,keyboard:0,slideShow:0,fullScreen:0,thumbs:0,touch:0,clickContent:!1,clickSlide:!1,clickOutside:!1,dblclickContent:!1,dblclickSlide:!1,dblclickOutside:!1})),n.group.push(c)}),Object.keys(n.slides).length&&(n.updateControls(),(t=n.Thumbs)&&t.isActive&&(t.create(),t.focus()))},addEvents:function(){var t=this;t.removeEvents(),t.$refs.container.on("click.fb-close","[data-fancybox-close]",function(e){e.stopPropagation(),e.preventDefault(),t.close(e)}).on("touchstart.fb-prev click.fb-prev","[data-fancybox-prev]",function(e){e.stopPropagation(),e.preventDefault(),t.previous()}).on("touchstart.fb-next click.fb-next","[data-fancybox-next]",function(e){e.stopPropagation(),e.preventDefault(),t.next()}).on("click.fb","[data-fancybox-zoom]",function(e){t[t.isScaledDown()?"scaleToActual":"scaleToFit"]()}),r.on("orientationchange.fb resize.fb",function(e){e&&e.originalEvent&&"resize"===e.originalEvent.type?(t.requestId&&u(t.requestId),t.requestId=d(function(){t.update(e)})):(t.current&&"iframe"===t.current.type&&t.$refs.stage.hide(),setTimeout(function(){t.$refs.stage.show(),t.update(e)},i.fancybox.isMobile?600:250))}),l.on("keydown.fb",function(e){var n=(i.fancybox?i.fancybox.getInstance():null).current,o=e.keyCode||e.which;if(9!=o){if(!(!n.opts.keyboard||e.ctrlKey||e.altKey||e.shiftKey||i(e.target).is("input,textarea,video,audio")))return 8===o||27===o?(e.preventDefault(),void t.close(e)):37===o||38===o?(e.preventDefault(),void t.previous()):39===o||40===o?(e.preventDefault(),void t.next()):void t.trigger("afterKeydown",e,o)}else n.opts.trapFocus&&t.focus(e)}),t.group[t.currIndex].opts.idleTime&&(t.idleSecondsCounter=0,l.on("mousemove.fb-idle mouseleave.fb-idle mousedown.fb-idle touchstart.fb-idle touchmove.fb-idle scroll.fb-idle keydown.fb-idle",function(e){t.idleSecondsCounter=0,t.isIdle&&t.showControls(),t.isIdle=!1}),t.idleInterval=e.setInterval(function(){t.idleSecondsCounter++,t.idleSecondsCounter>=t.group[t.currIndex].opts.idleTime&&!t.isDragging&&(t.isIdle=!0,t.idleSecondsCounter=0,t.hideControls())},1e3))},removeEvents:function(){r.off("orientationchange.fb resize.fb"),l.off("keydown.fb .fb-idle"),this.$refs.container.off(".fb-close .fb-prev .fb-next"),this.idleInterval&&(e.clearInterval(this.idleInterval),this.idleInterval=null)},previous:function(e){return this.jumpTo(this.currPos-1,e)},next:function(e){return this.jumpTo(this.currPos+1,e)},jumpTo:function(e,t){var n,o,s,a,r,l,c,d,u,h=this,f=h.group.length;if(!(h.isDragging||h.isClosing||h.isAnimating&&h.firstRun)){if(e=parseInt(e,10),!(s=h.current?h.current.opts.loop:h.opts.loop)&&(e<0||e>=f))return!1;if(n=h.firstRun=!Object.keys(h.slides).length,r=h.current,h.prevIndex=h.currIndex,h.prevPos=h.currPos,a=h.createSlide(e),f>1&&((s||a.index0)&&h.createSlide(e-1)),h.current=a,h.currIndex=a.index,h.currPos=a.pos,h.trigger("beforeShow",n),h.updateControls(),a.forcedDuration=void 0,i.isNumeric(t)?a.forcedDuration=t:t=a.opts[n?"animationDuration":"transitionDuration"],t=parseInt(t,10),o=h.isMoved(a),a.$slide.addClass("fancybox-slide--current"),n)return a.opts.animationEffect&&t&&h.$refs.container.css("transition-duration",t+"ms"),h.$refs.container.addClass("fancybox-is-open").trigger("focus"),h.loadSlide(a),void h.preload("image");l=i.fancybox.getTranslate(r.$slide),c=i.fancybox.getTranslate(h.$refs.stage),i.each(h.slides,function(e,t){i.fancybox.stop(t.$slide,!0)}),r.pos!==a.pos&&(r.isComplete=!1),r.$slide.removeClass("fancybox-slide--complete fancybox-slide--current"),o?(u=l.left-(r.pos*l.width+r.pos*r.opts.gutter),i.each(h.slides,function(e,n){n.$slide.removeClass("fancybox-animated").removeClass(function(e,t){return(t.match(/(^|\s)fancybox-fx-\S+/g)||[]).join(" ")});var o=n.pos*l.width+n.pos*n.opts.gutter;i.fancybox.setTranslate(n.$slide,{top:0,left:o-c.left+u}),n.pos!==a.pos&&n.$slide.addClass("fancybox-slide--"+(n.pos>a.pos?"next":"previous")),p(n.$slide),i.fancybox.animate(n.$slide,{top:0,left:(n.pos-a.pos)*l.width+(n.pos-a.pos)*n.opts.gutter},t,function(){n.$slide.css({transform:"",opacity:""}).removeClass("fancybox-slide--next fancybox-slide--previous"),n.pos===h.currPos&&h.complete()})})):t&&a.opts.transitionEffect&&(d="fancybox-animated fancybox-fx-"+a.opts.transitionEffect,r.$slide.addClass("fancybox-slide--"+(r.pos>a.pos?"next":"previous")),i.fancybox.animate(r.$slide,d,t,function(){r.$slide.removeClass(d).removeClass("fancybox-slide--next fancybox-slide--previous")},!1)),a.isLoaded?h.revealContent(a):h.loadSlide(a),h.preload("image")}},createSlide:function(e){var t,n;return n=(n=e%this.group.length)<0?this.group.length+n:n,!this.slides[e]&&this.group[n]&&(t=i('
').appendTo(this.$refs.stage),this.slides[e]=i.extend(!0,{},this.group[n],{pos:e,$slide:t,isLoaded:!1}),this.updateSlide(this.slides[e])),this.slides[e]},scaleToActual:function(e,t,n){var o,s,a,r,l,c=this,d=c.current,u=d.$content,h=i.fancybox.getTranslate(d.$slide).width,p=i.fancybox.getTranslate(d.$slide).height,f=d.width,m=d.height;c.isAnimating||c.isMoved()||!u||"image"!=d.type||!d.isLoaded||d.hasError||(c.isAnimating=!0,i.fancybox.stop(u),e=void 0===e?.5*h:e,t=void 0===t?.5*p:t,(o=i.fancybox.getTranslate(u)).top-=i.fancybox.getTranslate(d.$slide).top,o.left-=i.fancybox.getTranslate(d.$slide).left,r=f/o.width,l=m/o.height,s=.5*h-.5*f,a=.5*p-.5*m,f>h&&((s=o.left*r-(e*r-e))>0&&(s=0),sp&&((a=o.top*l-(t*l-t))>0&&(a=0),at-.5&&(l=t),(c*=o)>n-.5&&(c=n),"image"===e.type?(d.top=Math.floor(.5*(n-c))+parseFloat(r.css("paddingTop")),d.left=Math.floor(.5*(t-l))+parseFloat(r.css("paddingLeft"))):"video"===e.contentType&&(c>l/(s=e.opts.width&&e.opts.height?l/c:e.opts.ratio||16/9)?c=l/s:l>c*s&&(l=c*s)),d.width=l,d.height=c,d)},update:function(e){var t=this;i.each(t.slides,function(i,n){t.updateSlide(n,e)})},updateSlide:function(e,t){var n=e&&e.$content,o=e.width||e.opts.width,s=e.height||e.opts.height,a=e.$slide;this.adjustCaption(e),n&&(o||s||"video"===e.contentType)&&!e.hasError&&(i.fancybox.stop(n),i.fancybox.setTranslate(n,this.getFitPos(e)),e.pos===this.currPos&&(this.isAnimating=!1,this.updateCursor())),this.adjustLayout(e),a.length&&(a.trigger("refresh"),e.pos===this.currPos&&this.$refs.toolbar.add(this.$refs.navigation.find(".fancybox-button--arrow_right")).toggleClass("compensate-for-scrollbar",a.get(0).scrollHeight>a.get(0).clientHeight)),this.trigger("onUpdate",e,t)},centerSlide:function(e){var t=this,n=t.current,o=n.$slide;!t.isClosing&&n&&(o.siblings().css({transform:"",opacity:""}),o.parent().children().removeClass("fancybox-slide--previous fancybox-slide--next"),i.fancybox.animate(o,{top:0,left:0,opacity:1},void 0===e?0:e,function(){o.css({transform:"",opacity:""}),n.isComplete||t.complete()},!1))},isMoved:function(e){var t,n,o=e||this.current;return!!o&&(n=i.fancybox.getTranslate(this.$refs.stage),t=i.fancybox.getTranslate(o.$slide),!o.$slide.hasClass("fancybox-animated")&&(Math.abs(t.top-n.top)>.5||Math.abs(t.left-n.left)>.5))},updateCursor:function(e,t){var n,o,s=this.current,a=this.$refs.container;s&&!this.isClosing&&this.Guestures&&(a.removeClass("fancybox-is-zoomable fancybox-can-zoomIn fancybox-can-zoomOut fancybox-can-swipe fancybox-can-pan"),o=!!(n=this.canPan(e,t))||this.isZoomable(),a.toggleClass("fancybox-is-zoomable",o),i("[data-fancybox-zoom]").prop("disabled",!o),n?a.addClass("fancybox-can-pan"):o&&("zoom"===s.opts.clickContent||i.isFunction(s.opts.clickContent)&&"zoom"==s.opts.clickContent(s))?a.addClass("fancybox-can-zoomIn"):s.opts.touch&&(s.opts.touch.vertical||this.group.length>1)&&"video"!==s.contentType&&a.addClass("fancybox-can-swipe"))},isZoomable:function(){var e,t=this.current;if(t&&!this.isClosing&&"image"===t.type&&!t.hasError){if(!t.isLoaded)return!0;if((e=this.getFitPos(t))&&(t.width>e.width||t.height>e.height))return!0}return!1},isScaledDown:function(e,t){var n=!1,o=this.current,s=o.$content;return void 0!==e&&void 0!==t?n=e1.5||Math.abs(o.height-s.height)>1.5)),s},loadSlide:function(e){var t,n,o,s=this;if(!e.isLoading&&!e.isLoaded){if(e.isLoading=!0,!1===s.trigger("beforeLoad",e))return e.isLoading=!1,!1;switch(t=e.type,(n=e.$slide).off("refresh").trigger("onReset").addClass(e.opts.slideClass),t){case"image":s.setImage(e);break;case"iframe":s.setIframe(e);break;case"html":s.setContent(e,e.src||e.content);break;case"video":s.setContent(e,e.opts.video.tpl.replace(/\{\{src\}\}/gi,e.src).replace("{{format}}",e.opts.videoFormat||e.opts.video.format||"").replace("{{poster}}",e.thumb||""));break;case"inline":i(e.src).length?s.setContent(e,i(e.src)):s.setError(e);break;case"ajax":s.showLoading(e),o=i.ajax(i.extend({},e.opts.ajax.settings,{url:e.src,success:function(t,i){"success"===i&&s.setContent(e,t)},error:function(t,i){t&&"abort"!==i&&s.setError(e)}})),n.one("onReset",function(){o.abort()});break;default:s.setError(e)}return!0}},setImage:function(e){var n,o=this;setTimeout(function(){var t=e.$image;o.isClosing||!e.isLoading||t&&t.length&&t[0].complete||e.hasError||o.showLoading(e)},50),o.checkSrcset(e),e.$content=i('
').addClass("fancybox-is-hidden").appendTo(e.$slide.addClass("fancybox-slide--image")),!1!==e.opts.preload&&e.opts.width&&e.opts.height&&e.thumb&&(e.width=e.opts.width,e.height=e.opts.height,(n=t.createElement("img")).onerror=function(){i(this).remove(),e.$ghost=null},n.onload=function(){o.afterLoad(e)},e.$ghost=i(n).addClass("fancybox-image").appendTo(e.$content).attr("src",e.thumb)),o.setBigImage(e)},checkSrcset:function(t){var i,n,o,s,a=t.opts.srcset||t.opts.image.srcset;if(a){o=e.devicePixelRatio||1,s=e.innerWidth*o,(n=a.split(",").map(function(e){var t={};return e.trim().split(/\s+/).forEach(function(e,i){var n=parseInt(e.substring(0,e.length-1),10);if(0===i)return t.url=e;n&&(t.value=n,t.postfix=e[e.length-1])}),t})).sort(function(e,t){return e.value-t.value});for(var r=0;r=s||"x"===l.postfix&&l.value>=o){i=l;break}}!i&&n.length&&(i=n[n.length-1]),i&&(t.src=i.url,t.width&&t.height&&"w"==i.postfix&&(t.height=t.width/t.height*i.value,t.width=i.value),t.opts.srcset=a)}},setBigImage:function(e){var n=this,o=t.createElement("img"),s=i(o);e.$image=s.one("error",function(){n.setError(e)}).one("load",function(){var t;e.$ghost||(n.resolveImageSlideSize(e,this.naturalWidth,this.naturalHeight),n.afterLoad(e)),n.isClosing||(e.opts.srcset&&((t=e.opts.sizes)&&"auto"!==t||(t=(e.width/e.height>1&&r.width()/r.height()>1?"100":Math.round(e.width/e.height*100))+"vw"),s.attr("sizes",t).attr("srcset",e.opts.srcset)),e.$ghost&&setTimeout(function(){e.$ghost&&!n.isClosing&&e.$ghost.hide()},Math.min(300,Math.max(1e3,e.height/1600))),n.hideLoading(e))}).addClass("fancybox-image").attr("src",e.src).appendTo(e.$content),(o.complete||"complete"==o.readyState)&&s.naturalWidth&&s.naturalHeight?s.trigger("load"):o.error&&s.trigger("error")},resolveImageSlideSize:function(e,t,i){var n=parseInt(e.opts.width,10),o=parseInt(e.opts.height,10);e.width=t,e.height=i,n>0&&(e.width=n,e.height=Math.floor(n*i/t)),o>0&&(e.width=Math.floor(o*t/i),e.height=o)},setIframe:function(e){var t,n=this,o=e.opts.iframe,s=e.$slide;e.$content=i('
').css(o.css).appendTo(s),s.addClass("fancybox-slide--"+e.contentType),e.$iframe=t=i(o.tpl.replace(/\{rnd\}/g,(new Date).getTime())).attr(o.attr).appendTo(e.$content),o.preload?(n.showLoading(e),t.on("load.fb error.fb",function(t){this.isReady=1,e.$slide.trigger("refresh"),n.afterLoad(e)}),s.on("refresh.fb",function(){var i,n=e.$content,a=o.css.width,r=o.css.height;if(1===t[0].isReady){try{i=t.contents().find("body")}catch(e){}i&&i.length&&i.children().length&&(s.css("overflow","visible"),n.css({width:"100%","max-width":"100%",height:"9999px"}),void 0===a&&(a=Math.ceil(Math.max(i[0].clientWidth,i.outerWidth(!0)))),n.css("width",a||"").css("max-width",""),void 0===r&&(r=Math.ceil(Math.max(i[0].clientHeight,i.outerHeight(!0)))),n.css("height",r||""),s.css("overflow","auto")),n.removeClass("fancybox-is-hidden")}})):n.afterLoad(e),t.attr("src",e.src),s.one("onReset",function(){try{i(this).find("iframe").hide().unbind().attr("src","//about:blank")}catch(e){}i(this).off("refresh.fb").empty(),e.isLoaded=!1,e.isRevealed=!1})},setContent:function(e,t){var n;this.isClosing||(this.hideLoading(e),e.$content&&i.fancybox.stop(e.$content),e.$slide.empty(),(n=t)&&n.hasOwnProperty&&n instanceof i&&t.parent().length?((t.hasClass("fancybox-content")||t.parent().hasClass("fancybox-content"))&&t.parents(".fancybox-slide").trigger("onReset"),e.$placeholder=i("
").hide().insertAfter(t),t.css("display","inline-block")):e.hasError||("string"===i.type(t)&&(t=i("
").append(i.trim(t)).contents()),e.opts.filter&&(t=i("
").html(t).find(e.opts.filter))),e.$slide.one("onReset",function(){i(this).find("video,audio").trigger("pause"),e.$placeholder&&(e.$placeholder.after(t.removeClass("fancybox-content").hide()).remove(),e.$placeholder=null),e.$smallBtn&&(e.$smallBtn.remove(),e.$smallBtn=null),e.hasError||(i(this).empty(),e.isLoaded=!1,e.isRevealed=!1)}),i(t).appendTo(e.$slide),i(t).is("video,audio")&&(i(t).addClass("fancybox-video"),i(t).wrap("
"),e.contentType="video",e.opts.width=e.opts.width||i(t).attr("width"),e.opts.height=e.opts.height||i(t).attr("height")),e.$content=e.$slide.children().filter("div,form,main,video,audio,article,.fancybox-content").first(),e.$content.siblings().hide(),e.$content.length||(e.$content=e.$slide.wrapInner("
").children().first()),e.$content.addClass("fancybox-content"),e.$slide.addClass("fancybox-slide--"+e.contentType),this.afterLoad(e))},setError:function(e){e.hasError=!0,e.$slide.trigger("onReset").removeClass("fancybox-slide--"+e.contentType).addClass("fancybox-slide--error"),e.contentType="html",this.setContent(e,this.translate(e,e.opts.errorTpl)),e.pos===this.currPos&&(this.isAnimating=!1)},showLoading:function(e){(e=e||this.current)&&!e.$spinner&&(e.$spinner=i(this.translate(this,this.opts.spinnerTpl)).appendTo(e.$slide).hide().fadeIn("fast"))},hideLoading:function(e){(e=e||this.current)&&e.$spinner&&(e.$spinner.stop().remove(),delete e.$spinner)},afterLoad:function(e){this.isClosing||(e.isLoading=!1,e.isLoaded=!0,this.trigger("afterLoad",e),this.hideLoading(e),!e.opts.smallBtn||e.$smallBtn&&e.$smallBtn.length||(e.$smallBtn=i(this.translate(e,e.opts.btnTpl.smallBtn)).appendTo(e.$content)),e.opts.protect&&e.$content&&!e.hasError&&(e.$content.on("contextmenu.fb",function(e){return 2==e.button&&e.preventDefault(),!0}),"image"===e.type&&i('
').appendTo(e.$content)),this.adjustCaption(e),this.adjustLayout(e),e.pos===this.currPos&&this.updateCursor(),this.revealContent(e))},adjustCaption:function(e){var t,i=e||this.current,n=i.opts.caption,o=i.opts.preventCaptionOverlap,s=this.$refs.caption,a=!1;s.toggleClass("fancybox-caption--separate",o),o&&n&&n.length&&(i.pos!==this.currPos?((t=s.clone().appendTo(s.parent())).children().eq(0).empty().html(n),a=t.outerHeight(!0),t.empty().remove()):this.$caption&&(a=this.$caption.outerHeight(!0)),i.$slide.css("padding-bottom",a||""))},adjustLayout:function(e){var t,i,n,o,s=e||this.current;s.isLoaded&&!0!==s.opts.disableLayoutFix&&(s.$content.css("margin-bottom",""),s.$content.outerHeight()>s.$slide.height()+.5&&(n=s.$slide[0].style["padding-bottom"],o=s.$slide.css("padding-bottom"),parseFloat(o)>0&&(t=s.$slide[0].scrollHeight,s.$slide.css("padding-bottom",0),Math.abs(t-s.$slide[0].scrollHeight)<1&&(i=o),s.$slide.css("padding-bottom",n))),s.$content.css("margin-bottom",i))},revealContent:function(e){var t,n,o,s,a=this,r=e.$slide,l=!1,c=!1,d=a.isMoved(e),u=e.isRevealed;return e.isRevealed=!0,t=e.opts[a.firstRun?"animationEffect":"transitionEffect"],o=e.opts[a.firstRun?"animationDuration":"transitionDuration"],o=parseInt(void 0===e.forcedDuration?o:e.forcedDuration,10),!d&&e.pos===a.currPos&&o||(t=!1),"zoom"===t&&(e.pos===a.currPos&&o&&"image"===e.type&&!e.hasError&&(c=a.getThumbPos(e))?l=a.getFitPos(e):t="fade"),"zoom"===t?(a.isAnimating=!0,l.scaleX=l.width/c.width,l.scaleY=l.height/c.height,"auto"==(s=e.opts.zoomOpacity)&&(s=Math.abs(e.width/e.height-c.width/c.height)>.1),s&&(c.opacity=.1,l.opacity=1),i.fancybox.setTranslate(e.$content.removeClass("fancybox-is-hidden"),c),p(e.$content),void i.fancybox.animate(e.$content,l,o,function(){a.isAnimating=!1,a.complete()})):(a.updateSlide(e),t?(i.fancybox.stop(r),n="fancybox-slide--"+(e.pos>=a.prevPos?"next":"previous")+" fancybox-animated fancybox-fx-"+t,r.addClass(n).removeClass("fancybox-slide--current"),e.$content.removeClass("fancybox-is-hidden"),p(r),"image"!==e.type&&e.$content.hide().show(0),void i.fancybox.animate(r,"fancybox-slide--current",o,function(){r.removeClass(n).css({transform:"",opacity:""}),e.pos===a.currPos&&a.complete()},!0)):(e.$content.removeClass("fancybox-is-hidden"),u||!d||"image"!==e.type||e.hasError||e.$content.hide().fadeIn("fast"),void(e.pos===a.currPos&&a.complete())))},getThumbPos:function(e){var n,o,s,a,r,l,c=e.$thumb;return!(!c||!function(e){var n,o;return!(!e||e.ownerDocument!==t)&&(i(".fancybox-container").css("pointer-events","none"),n={x:e.getBoundingClientRect().left+e.offsetWidth/2,y:e.getBoundingClientRect().top+e.offsetHeight/2},o=t.elementFromPoint(n.x,n.y)===e,i(".fancybox-container").css("pointer-events",""),o)}(c[0]))&&(o=i.fancybox.getTranslate(c),s=parseFloat(c.css("border-top-width")||0),a=parseFloat(c.css("border-right-width")||0),r=parseFloat(c.css("border-bottom-width")||0),l=parseFloat(c.css("border-left-width")||0),n={top:o.top+s,left:o.left+l,width:o.width-a-l,height:o.height-s-r,scaleX:1,scaleY:1},o.width>0&&o.height>0&&n)},complete:function(){var e,t=this,n=t.current,o={};!t.isMoved()&&n.isLoaded&&(n.isComplete||(n.isComplete=!0,n.$slide.siblings().trigger("onReset"),t.preload("inline"),p(n.$slide),n.$slide.addClass("fancybox-slide--complete"),i.each(t.slides,function(e,n){n.pos>=t.currPos-1&&n.pos<=t.currPos+1?o[n.pos]=n:n&&(i.fancybox.stop(n.$slide),n.$slide.off().remove())}),t.slides=o),t.isAnimating=!1,t.updateCursor(),t.trigger("afterShow"),n.opts.video.autoStart&&n.$slide.find("video,audio").filter(":visible:first").trigger("play").one("ended",function(){this.webkitExitFullscreen&&this.webkitExitFullscreen(),t.next()}),n.opts.autoFocus&&"html"===n.contentType&&((e=n.$content.find("input[autofocus]:enabled:visible:first")).length?e.trigger("focus"):t.focus(null,!0)),n.$slide.scrollTop(0).scrollLeft(0))},preload:function(e){var t,i;this.group.length<2||(i=this.slides[this.currPos+1],(t=this.slides[this.currPos-1])&&t.type===e&&this.loadSlide(t),i&&i.type===e&&this.loadSlide(i))},focus:function(e,n){var o,s,a=["a[href]","area[href]",'input:not([disabled]):not([type="hidden"]):not([aria-hidden])',"select:not([disabled]):not([aria-hidden])","textarea:not([disabled]):not([aria-hidden])","button:not([disabled]):not([aria-hidden])","iframe","object","embed","video","audio","[contenteditable]",'[tabindex]:not([tabindex^="-"])'].join(",");this.isClosing||((o=(o=!e&&this.current&&this.current.isComplete?this.current.$slide.find("*:visible"+(n?":not(.fancybox-close-small)":"")):this.$refs.container.find("*:visible")).filter(a).filter(function(){return"hidden"!==i(this).css("visibility")&&!i(this).hasClass("disabled")})).length?(s=o.index(t.activeElement),e&&e.shiftKey?(s<0||0==s)&&(e.preventDefault(),o.eq(o.length-1).trigger("focus")):(s<0||s==o.length-1)&&(e&&e.preventDefault(),o.eq(0).trigger("focus"))):this.$refs.container.trigger("focus"))},activate:function(){var e=this;i(".fancybox-container").each(function(){var t=i(this).data("FancyBox");t&&t.id!==e.id&&!t.isClosing&&(t.trigger("onDeactivate"),t.removeEvents(),t.isVisible=!1)}),e.isVisible=!0,(e.current||e.isIdle)&&(e.update(),e.updateControls()),e.trigger("onActivate"),e.addEvents()},close:function(e,t){var n,o,s,a,r,l,c,u=this,h=u.current,f=function(){u.cleanUp(e)};return!u.isClosing&&(u.isClosing=!0,!1===u.trigger("beforeClose",e)?(u.isClosing=!1,d(function(){u.update()}),!1):(u.removeEvents(),s=h.$content,n=h.opts.animationEffect,o=i.isNumeric(t)?t:n?h.opts.animationDuration:0,h.$slide.removeClass("fancybox-slide--complete fancybox-slide--next fancybox-slide--previous fancybox-animated"),!0!==e?i.fancybox.stop(h.$slide):n=!1,h.$slide.siblings().trigger("onReset").remove(),o&&u.$refs.container.removeClass("fancybox-is-open").addClass("fancybox-is-closing").css("transition-duration",o+"ms"),u.hideLoading(h),u.hideControls(!0),u.updateCursor(),"zoom"!==n||s&&o&&"image"===h.type&&!u.isMoved()&&!h.hasError&&(c=u.getThumbPos(h))||(n="fade"),"zoom"===n?(i.fancybox.stop(s),l={top:(a=i.fancybox.getTranslate(s)).top,left:a.left,scaleX:a.width/c.width,scaleY:a.height/c.height,width:c.width,height:c.height},"auto"==(r=h.opts.zoomOpacity)&&(r=Math.abs(h.width/h.height-c.width/c.height)>.1),r&&(c.opacity=0),i.fancybox.setTranslate(s,l),p(s),i.fancybox.animate(s,c,o,f),!0):(n&&o?i.fancybox.animate(h.$slide.addClass("fancybox-slide--previous").removeClass("fancybox-slide--current"),"fancybox-animated fancybox-fx-"+n,o,f):!0===e?setTimeout(f,o):f(),!0)))},cleanUp:function(t){var n,o,s,a=this.current.opts.$orig;this.current.$slide.trigger("onReset"),this.$refs.container.empty().remove(),this.trigger("afterClose",t),this.current.opts.backFocus&&(a&&a.length&&a.is(":visible")||(a=this.$trigger),a&&a.length&&(o=e.scrollX,s=e.scrollY,a.trigger("focus"),i("html, body").scrollTop(s).scrollLeft(o))),this.current=null,(n=i.fancybox.getInstance())?n.activate():(i("body").removeClass("fancybox-active compensate-for-scrollbar"),i("#fancybox-style-noscroll").remove())},trigger:function(e,t){var n,o=Array.prototype.slice.call(arguments,1),s=t&&t.opts?t:this.current;if(s?o.unshift(s):s=this,o.unshift(this),i.isFunction(s.opts[e])&&(n=s.opts[e].apply(s,o)),!1===n)return n;"afterClose"!==e&&this.$refs?this.$refs.container.trigger(e+".fb",o):l.trigger(e+".fb",o)},updateControls:function(){var e=this.current,n=e.index,o=this.$refs.container,s=this.$refs.caption,a=e.opts.caption;e.$slide.trigger("refresh"),a&&a.length?(this.$caption=s,s.children().eq(0).html(a)):this.$caption=null,this.hasHiddenControls||this.isIdle||this.showControls(),o.find("[data-fancybox-count]").html(this.group.length),o.find("[data-fancybox-index]").html(n+1),o.find("[data-fancybox-prev]").prop("disabled",!e.opts.loop&&n<=0),o.find("[data-fancybox-next]").prop("disabled",!e.opts.loop&&n>=this.group.length-1),"image"===e.type?o.find("[data-fancybox-zoom]").show().end().find("[data-fancybox-download]").attr("href",e.opts.image.src||e.src).show():e.opts.toolbar&&o.find("[data-fancybox-download],[data-fancybox-zoom]").hide(),i(t.activeElement).is(":hidden,[disabled]")&&this.$refs.container.trigger("focus")},hideControls:function(e){var t=["infobar","toolbar","nav"];!e&&this.current.opts.preventCaptionOverlap||t.push("caption"),this.$refs.container.removeClass(t.map(function(e){return"fancybox-show-"+e}).join(" ")),this.hasHiddenControls=!0},showControls:function(){var e=this.current?this.current.opts:this.opts,t=this.$refs.container;this.hasHiddenControls=!1,this.idleSecondsCounter=0,t.toggleClass("fancybox-show-toolbar",!(!e.toolbar||!e.buttons)).toggleClass("fancybox-show-infobar",!!(e.infobar&&this.group.length>1)).toggleClass("fancybox-show-caption",!!this.$caption).toggleClass("fancybox-show-nav",!!(e.arrows&&this.group.length>1)).toggleClass("fancybox-is-modal",!!e.modal)},toggleControls:function(){this.hasHiddenControls?this.showControls():this.hideControls()}}),i.fancybox={version:"3.5.6",defaults:a,getInstance:function(e){var t=i('.fancybox-container:not(".fancybox-is-closing"):last').data("FancyBox"),n=Array.prototype.slice.call(arguments,1);return t instanceof m&&("string"===i.type(e)?t[e].apply(t,n):"function"===i.type(e)&&e.apply(t,n),t)},open:function(e,t,i){return new m(e,t,i)},close:function(e){var t=this.getInstance();t&&(t.close(),!0===e&&this.close(e))},destroy:function(){this.close(!0),l.add("body").off("click.fb-start","**")},isMobile:/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent),use3d:(o=t.createElement("div"),e.getComputedStyle&&e.getComputedStyle(o)&&e.getComputedStyle(o).getPropertyValue("transform")&&!(t.documentMode&&t.documentMode<11)),getTranslate:function(e){var t;return!(!e||!e.length)&&{top:(t=e[0].getBoundingClientRect()).top||0,left:t.left||0,width:t.width,height:t.height,opacity:parseFloat(e.css("opacity"))}},setTranslate:function(e,t){var i="",n={};if(e&&t)return void 0===t.left&&void 0===t.top||(i=(void 0===t.left?e.position().left:t.left)+"px, "+(void 0===t.top?e.position().top:t.top)+"px",i=this.use3d?"translate3d("+i+", 0px)":"translate("+i+")"),void 0!==t.scaleX&&void 0!==t.scaleY?i+=" scale("+t.scaleX+", "+t.scaleY+")":void 0!==t.scaleX&&(i+=" scaleX("+t.scaleX+")"),i.length&&(n.transform=i),void 0!==t.opacity&&(n.opacity=t.opacity),void 0!==t.width&&(n.width=t.width),void 0!==t.height&&(n.height=t.height),e.css(n)},animate:function(e,t,n,o,s){var a,r=this;i.isFunction(n)&&(o=n,n=null),r.stop(e),a=r.getTranslate(e),e.on(h,function(l){(!l||!l.originalEvent||e.is(l.originalEvent.target)&&"z-index"!=l.originalEvent.propertyName)&&(r.stop(e),i.isNumeric(n)&&e.css("transition-duration",""),i.isPlainObject(t)?void 0!==t.scaleX&&void 0!==t.scaleY&&r.setTranslate(e,{top:t.top,left:t.left,width:a.width*t.scaleX,height:a.height*t.scaleY,scaleX:1,scaleY:1}):!0!==s&&e.removeClass(t),i.isFunction(o)&&o(l))}),i.isNumeric(n)&&e.css("transition-duration",n+"ms"),i.isPlainObject(t)?(void 0!==t.scaleX&&void 0!==t.scaleY&&(delete t.width,delete t.height,e.parent().hasClass("fancybox-slide--image")&&e.parent().addClass("fancybox-is-scaling")),i.fancybox.setTranslate(e,t)):e.addClass(t),e.data("timer",setTimeout(function(){e.trigger(h)},n+33))},stop:function(e,t){e&&e.length&&(clearTimeout(e.data("timer")),t&&e.trigger(h),e.off(h).css("transition-duration",""),e.parent().removeClass("fancybox-is-scaling"))}},i.fn.fancybox=function(e){var t;return(t=(e=e||{}).selector||!1)?i("body").off("click.fb-start",t).on("click.fb-start",t,{options:e},g):this.off("click.fb-start").on("click.fb-start",{items:this,options:e},g),this},l.on("click.fb-start","[data-fancybox]",g),l.on("click.fb-start","[data-fancybox-trigger]",function(e){i('[data-fancybox="'+i(this).attr("data-fancybox-trigger")+'"]').eq(i(this).attr("data-fancybox-index")||0).trigger("click.fb-start",{$trigger:i(this)})}),s=null,l.on("mousedown mouseup focus blur",".fancybox-button",function(e){switch(e.type){case"mousedown":s=i(this);break;case"mouseup":s=null;break;case"focusin":i(".fancybox-button").removeClass("fancybox-focus"),i(this).is(s)||i(this).is("[disabled]")||i(this).addClass("fancybox-focus");break;case"focusout":i(".fancybox-button").removeClass("fancybox-focus")}})}function g(e,t){var n,o,s,a=[],r=0;e&&e.isDefaultPrevented()||(e.preventDefault(),t=t||{},e&&e.data&&(t=f(e.data.options,t)),n=t.$target||i(e.currentTarget).trigger("blur"),(s=i.fancybox.getInstance())&&s.$trigger&&s.$trigger.is(n)||(a=t.selector?i(t.selector):(o=n.attr("data-fancybox")||"")?(a=e.data?e.data.items:[]).length?a.filter('[data-fancybox="'+o+'"]'):i('[data-fancybox="'+o+'"]'):[n],(r=i(a).index(n))<0&&(r=0),(s=i.fancybox.open(a,t,r)).$trigger=n))}}(window,document,jQuery),function(e){"use strict";var t={youtube:{matcher:/(youtube\.com|youtu\.be|youtube\-nocookie\.com)\/(watch\?(.*&)?v=|v\/|u\/|embed\/?)?(videoseries\?list=(.*)|[\w-]{11}|\?listType=(.*)&list=(.*))(.*)/i,params:{autoplay:1,autohide:1,fs:1,rel:0,hd:1,wmode:"transparent",enablejsapi:1,html5:1},paramPlace:8,type:"iframe",url:"https://www.youtube-nocookie.com/embed/$4",thumb:"https://img.youtube.com/vi/$4/hqdefault.jpg"},vimeo:{matcher:/^.+vimeo.com\/(.*\/)?([\d]+)(.*)?/,params:{autoplay:1,hd:1,show_title:1,show_byline:1,show_portrait:0,fullscreen:1},paramPlace:3,type:"iframe",url:"//player.vimeo.com/video/$2"},instagram:{matcher:/(instagr\.am|instagram\.com)\/p\/([a-zA-Z0-9_\-]+)\/?/i,type:"image",url:"//$1/p/$2/media/?size=l"},gmap_place:{matcher:/(maps\.)?google\.([a-z]{2,3}(\.[a-z]{2})?)\/(((maps\/(place\/(.*)\/)?\@(.*),(\d+.?\d+?)z))|(\?ll=))(.*)?/i,type:"iframe",url:function(e){return"//maps.google."+e[2]+"/?ll="+(e[9]?e[9]+"&z="+Math.floor(e[10])+(e[12]?e[12].replace(/^\//,"&"):""):e[12]+"").replace(/\?/,"&")+"&output="+(e[12]&&e[12].indexOf("layer=c")>0?"svembed":"embed")}},gmap_search:{matcher:/(maps\.)?google\.([a-z]{2,3}(\.[a-z]{2})?)\/(maps\/search\/)(.*)/i,type:"iframe",url:function(e){return"//maps.google."+e[2]+"/maps?q="+e[5].replace("query=","q=").replace("api=1","")+"&output=embed"}}},i=function(t,i,n){if(t)return n=n||"","object"===e.type(n)&&(n=e.param(n,!0)),e.each(i,function(e,i){t=t.replace("$"+e,i||"")}),n.length&&(t+=(t.indexOf("?")>0?"&":"?")+n),t};e(document).on("objectNeedsType.fb",function(n,o,s){var a,r,l,c,d,u,h,p=s.src||"",f=!1;a=e.extend(!0,{},t,s.opts.media),e.each(a,function(t,n){if(l=p.match(n.matcher)){if(f=n.type,h=t,u={},n.paramPlace&&l[n.paramPlace]){"?"==(d=l[n.paramPlace])[0]&&(d=d.substring(1)),d=d.split("&");for(var o=0;o1&&("youtube"===i.contentSource||"vimeo"===i.contentSource)&&n.load(i.contentSource)}})}(jQuery),function(e,t,i){"use strict";var n=e.requestAnimationFrame||e.webkitRequestAnimationFrame||e.mozRequestAnimationFrame||e.oRequestAnimationFrame||function(t){return e.setTimeout(t,1e3/60)},o=e.cancelAnimationFrame||e.webkitCancelAnimationFrame||e.mozCancelAnimationFrame||e.oCancelAnimationFrame||function(t){e.clearTimeout(t)},s=function(t){var i=[];for(var n in t=(t=t.originalEvent||t||e.e).touches&&t.touches.length?t.touches:t.changedTouches&&t.changedTouches.length?t.changedTouches:[t])t[n].pageX?i.push({x:t[n].pageX,y:t[n].pageY}):t[n].clientX&&i.push({x:t[n].clientX,y:t[n].clientY});return i},a=function(e,t,i){return t&&e?"x"===i?e.x-t.x:"y"===i?e.y-t.y:Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2)):0},r=function(e){if(e.is('a,area,button,[role="button"],input,label,select,summary,textarea,video,audio,iframe')||i.isFunction(e.get(0).onclick)||e.data("selectable"))return!0;for(var t=0,n=e[0].attributes,o=n.length;ti.clientHeight,a=("scroll"===o||"auto"===o)&&i.scrollWidth>i.clientWidth,!(r=s||a)&&(t=t.parent()).length&&!t.hasClass("fancybox-stage")&&!t.is("body"););return r},c=function(e){this.instance=e,this.$bg=e.$refs.bg,this.$stage=e.$refs.stage,this.$container=e.$refs.container,this.destroy(),this.$container.on("touchstart.fb.touch mousedown.fb.touch",i.proxy(this,"ontouchstart"))};c.prototype.destroy=function(){this.$container.off(".fb.touch"),i(t).off(".fb.touch"),this.requestId&&(o(this.requestId),this.requestId=null),this.tapped&&(clearTimeout(this.tapped),this.tapped=null)},c.prototype.ontouchstart=function(n){var o=i(n.target),c=this.instance,d=c.current,u=d.$slide,h=d.$content,p="touchstart"==n.type;if(p&&this.$container.off("mousedown.fb.touch"),(!n.originalEvent||2!=n.originalEvent.button)&&u.length&&o.length&&!r(o)&&!r(o.parent())&&(o.is("img")||!(n.originalEvent.clientX>o[0].clientWidth+o.offset().left))){if(!d||c.isAnimating||d.$slide.hasClass("fancybox-animated"))return n.stopPropagation(),void n.preventDefault();this.realPoints=this.startPoints=s(n),this.startPoints.length&&(d.touch&&n.stopPropagation(),this.startEvent=n,this.canTap=!0,this.$target=o,this.$content=h,this.opts=d.opts.touch,this.isPanning=!1,this.isSwiping=!1,this.isZooming=!1,this.isScrolling=!1,this.canPan=c.canPan(),this.startTime=(new Date).getTime(),this.distanceX=this.distanceY=this.distance=0,this.canvasWidth=Math.round(u[0].clientWidth),this.canvasHeight=Math.round(u[0].clientHeight),this.contentLastPos=null,this.contentStartPos=i.fancybox.getTranslate(this.$content)||{top:0,left:0},this.sliderStartPos=i.fancybox.getTranslate(u),this.stagePos=i.fancybox.getTranslate(c.$refs.stage),this.sliderStartPos.top-=this.stagePos.top,this.sliderStartPos.left-=this.stagePos.left,this.contentStartPos.top-=this.stagePos.top,this.contentStartPos.left-=this.stagePos.left,i(t).off(".fb.touch").on(p?"touchend.fb.touch touchcancel.fb.touch":"mouseup.fb.touch mouseleave.fb.touch",i.proxy(this,"ontouchend")).on(p?"touchmove.fb.touch":"mousemove.fb.touch",i.proxy(this,"ontouchmove")),i.fancybox.isMobile&&t.addEventListener("scroll",this.onscroll,!0),((this.opts||this.canPan)&&(o.is(this.$stage)||this.$stage.find(o).length)||(o.is(".fancybox-image")&&n.preventDefault(),i.fancybox.isMobile&&o.parents(".fancybox-caption").length))&&(this.isScrollable=l(o)||l(o.parent()),i.fancybox.isMobile&&this.isScrollable||n.preventDefault(),(1===this.startPoints.length||d.hasError)&&(this.canPan?(i.fancybox.stop(this.$content),this.isPanning=!0):this.isSwiping=!0,this.$container.addClass("fancybox-is-grabbing")),2===this.startPoints.length&&"image"===d.type&&(d.isLoaded||d.$ghost)&&(this.canTap=!1,this.isSwiping=!1,this.isPanning=!1,this.isZooming=!0,i.fancybox.stop(this.$content),this.centerPointStartX=.5*(this.startPoints[0].x+this.startPoints[1].x)-i(e).scrollLeft(),this.centerPointStartY=.5*(this.startPoints[0].y+this.startPoints[1].y)-i(e).scrollTop(),this.percentageOfImageAtPinchPointX=(this.centerPointStartX-this.contentStartPos.left)/this.contentStartPos.width,this.percentageOfImageAtPinchPointY=(this.centerPointStartY-this.contentStartPos.top)/this.contentStartPos.height,this.startDistanceBetweenFingers=a(this.startPoints[0],this.startPoints[1]))))}},c.prototype.onscroll=function(e){this.isScrolling=!0,t.removeEventListener("scroll",this.onscroll,!0)},c.prototype.ontouchmove=function(e){void 0===e.originalEvent.buttons||0!==e.originalEvent.buttons?this.isScrolling?this.canTap=!1:(this.newPoints=s(e),(this.opts||this.canPan)&&this.newPoints.length&&this.newPoints.length&&(this.isSwiping&&!0===this.isSwiping||e.preventDefault(),this.distanceX=a(this.newPoints[0],this.startPoints[0],"x"),this.distanceY=a(this.newPoints[0],this.startPoints[0],"y"),this.distance=a(this.newPoints[0],this.startPoints[0]),this.distance>0&&(this.isSwiping?this.onSwipe(e):this.isPanning?this.onPan():this.isZooming&&this.onZoom()))):this.ontouchend(e)},c.prototype.onSwipe=function(t){var s,a=this,r=a.instance,l=a.isSwiping,c=a.sliderStartPos.left||0;if(!0!==l)"x"==l&&(a.distanceX>0&&(a.instance.group.length<2||0===a.instance.current.index&&!a.instance.current.opts.loop)?c+=Math.pow(a.distanceX,.8):a.distanceX<0&&(a.instance.group.length<2||a.instance.current.index===a.instance.group.length-1&&!a.instance.current.opts.loop)?c-=Math.pow(-a.distanceX,.8):c+=a.distanceX),a.sliderLastPos={top:"x"==l?0:a.sliderStartPos.top+a.distanceY,left:c},a.requestId&&(o(a.requestId),a.requestId=null),a.requestId=n(function(){a.sliderLastPos&&(i.each(a.instance.slides,function(e,t){var n=t.pos-a.instance.currPos;i.fancybox.setTranslate(t.$slide,{top:a.sliderLastPos.top,left:a.sliderLastPos.left+n*a.canvasWidth+n*t.opts.gutter})}),a.$container.addClass("fancybox-is-sliding"))});else if(Math.abs(a.distance)>10){if(a.canTap=!1,r.group.length<2&&a.opts.vertical?a.isSwiping="y":r.isDragging||!1===a.opts.vertical||"auto"===a.opts.vertical&&i(e).width()>800?a.isSwiping="x":(s=Math.abs(180*Math.atan2(a.distanceY,a.distanceX)/Math.PI),a.isSwiping=s>45&&s<135?"y":"x"),"y"===a.isSwiping&&i.fancybox.isMobile&&a.isScrollable)return void(a.isScrolling=!0);r.isDragging=a.isSwiping,a.startPoints=a.newPoints,i.each(r.slides,function(e,t){var n,o;i.fancybox.stop(t.$slide),n=i.fancybox.getTranslate(t.$slide),o=i.fancybox.getTranslate(r.$refs.stage),t.$slide.css({transform:"",opacity:"","transition-duration":""}).removeClass("fancybox-animated").removeClass(function(e,t){return(t.match(/(^|\s)fancybox-fx-\S+/g)||[]).join(" ")}),t.pos===r.current.pos&&(a.sliderStartPos.top=n.top-o.top,a.sliderStartPos.left=n.left-o.left),i.fancybox.setTranslate(t.$slide,{top:n.top-o.top,left:n.left-o.left})}),r.SlideShow&&r.SlideShow.isActive&&r.SlideShow.stop()}},c.prototype.onPan=function(){var e=this;a(e.newPoints[0],e.realPoints[0])<(i.fancybox.isMobile?10:5)?e.startPoints=e.newPoints:(e.canTap=!1,e.contentLastPos=e.limitMovement(),e.requestId&&o(e.requestId),e.requestId=n(function(){i.fancybox.setTranslate(e.$content,e.contentLastPos)}))},c.prototype.limitMovement=function(){var e,t,i,n,o,s,a=this.canvasWidth,r=this.canvasHeight,l=this.distanceX,c=this.distanceY,d=this.contentStartPos,u=d.left,h=d.top,p=d.width,f=d.height;return o=p>a?u+l:u,s=h+c,e=Math.max(0,.5*a-.5*p),t=Math.max(0,.5*r-.5*f),i=Math.min(a-p,.5*a-.5*p),n=Math.min(r-f,.5*r-.5*f),l>0&&o>e&&(o=e-1+Math.pow(-e+u+l,.8)||0),l<0&&o0&&s>t&&(s=t-1+Math.pow(-t+h+c,.8)||0),c<0&&so?(e=e>0?0:e)s?(t=t>0?0:t)1&&(this.dMs>130&&s>10||s>50);this.sliderLastPos=null,"y"==e&&!t&&Math.abs(this.distanceY)>50?(i.fancybox.animate(this.instance.current.$slide,{top:this.sliderStartPos.top+this.distanceY+150*this.velocityY,opacity:0},200),n=this.instance.close(!0,250)):a&&this.distanceX>0?n=this.instance.previous(300):a&&this.distanceX<0&&(n=this.instance.next(300)),!1!==n||"x"!=e&&"y"!=e||this.instance.centerSlide(200),this.$container.removeClass("fancybox-is-sliding")},c.prototype.endPanning=function(){var e,t,n;this.contentLastPos&&(!1===this.opts.momentum||this.dMs>350?(e=this.contentLastPos.left,t=this.contentLastPos.top):(e=this.contentLastPos.left+500*this.velocityX,t=this.contentLastPos.top+500*this.velocityY),(n=this.limitPosition(e,t,this.contentStartPos.width,this.contentStartPos.height)).width=this.contentStartPos.width,n.height=this.contentStartPos.height,i.fancybox.animate(this.$content,n,366))},c.prototype.endZooming=function(){var e,t,n,o,s=this.instance.current,a=this.newWidth,r=this.newHeight;this.contentLastPos&&(e=this.contentLastPos.left,o={top:t=this.contentLastPos.top,left:e,width:a,height:r,scaleX:1,scaleY:1},i.fancybox.setTranslate(this.$content,o),as.width||r>s.height?this.instance.scaleToActual(this.centerPointStartX,this.centerPointStartY,150):(n=this.limitPosition(e,t,a,r),i.fancybox.animate(this.$content,n,150)))},c.prototype.onTap=function(t){var n,o=this,a=i(t.target),r=o.instance,l=r.current,c=t&&s(t)||o.startPoints,d=c[0]?c[0].x-i(e).scrollLeft()-o.stagePos.left:0,u=c[0]?c[0].y-i(e).scrollTop()-o.stagePos.top:0,h=function(e){var n=l.opts[e];if(i.isFunction(n)&&(n=n.apply(r,[l,t])),n)switch(n){case"close":r.close(o.startEvent);break;case"toggleControls":r.toggleControls();break;case"next":r.next();break;case"nextOrClose":r.group.length>1?r.next():r.close(o.startEvent);break;case"zoom":"image"==l.type&&(l.isLoaded||l.$ghost)&&(r.canPan()?r.scaleToFit():r.isScaledDown()?r.scaleToActual(d,u):r.group.length<2&&r.close(o.startEvent))}};if((!t.originalEvent||2!=t.originalEvent.button)&&(a.is("img")||!(d>a[0].clientWidth+a.offset().left))){if(a.is(".fancybox-bg,.fancybox-inner,.fancybox-outer,.fancybox-container"))n="Outside";else if(a.is(".fancybox-slide"))n="Slide";else{if(!r.current.$content||!r.current.$content.find(a).addBack().filter(a).length)return;n="Content"}if(o.tapped){if(clearTimeout(o.tapped),o.tapped=null,Math.abs(d-o.tapX)>50||Math.abs(u-o.tapY)>50)return this;h("dblclick"+n)}else o.tapX=d,o.tapY=u,l.opts["dblclick"+n]&&l.opts["dblclick"+n]!==l.opts["click"+n]?o.tapped=setTimeout(function(){o.tapped=null,r.isAnimating||h("click"+n)},500):h("click"+n);return this}},i(t).on("onActivate.fb",function(e,t){t&&!t.Guestures&&(t.Guestures=new c(t))}).on("beforeClose.fb",function(e,t){t&&t.Guestures&&t.Guestures.destroy()})}(window,document,jQuery),function(e,t){"use strict";t.extend(!0,t.fancybox.defaults,{btnTpl:{slideShow:''},slideShow:{autoStart:!1,speed:3e3,progress:!0}});var i=function(e){this.instance=e,this.init()};t.extend(i.prototype,{timer:null,isActive:!1,$button:null,init:function(){var e=this,i=e.instance,n=i.group[i.currIndex].opts.slideShow;e.$button=i.$refs.toolbar.find("[data-fancybox-play]").on("click",function(){e.toggle()}),i.group.length<2||!n?e.$button.hide():n.progress&&(e.$progress=t('
').appendTo(i.$refs.inner))},set:function(e){var i=this.instance,n=i.current;n&&(!0===e||n.opts.loop||i.currIndex'},fullScreen:{autoStart:!1}}),t(e).on(i.fullscreenchange,function(){var e=n.isFullscreen(),i=t.fancybox.getInstance();i&&(i.current&&"image"===i.current.type&&i.isAnimating&&(i.isAnimating=!1,i.update(!0,!0,0),i.isComplete||i.complete()),i.trigger("onFullscreenChange",e),i.$refs.container.toggleClass("fancybox-is-fullscreen",e),i.$refs.toolbar.find("[data-fancybox-fullscreen]").toggleClass("fancybox-button--fsenter",!e).toggleClass("fancybox-button--fsexit",e))})}t(e).on({"onInit.fb":function(e,t){i?t&&t.group[t.currIndex].opts.fullScreen?(t.$refs.container.on("click.fb-fullscreen","[data-fancybox-fullscreen]",function(e){e.stopPropagation(),e.preventDefault(),n.toggle()}),t.opts.fullScreen&&!0===t.opts.fullScreen.autoStart&&n.request(),t.FullScreen=n):t&&t.$refs.toolbar.find("[data-fancybox-fullscreen]").hide():t.$refs.toolbar.find("[data-fancybox-fullscreen]").remove()},"afterKeydown.fb":function(e,t,i,n,o){t&&t.FullScreen&&70===o&&(n.preventDefault(),t.FullScreen.toggle())},"beforeClose.fb":function(e,t){t&&t.FullScreen&&t.$refs.container.hasClass("fancybox-is-fullscreen")&&n.exit()}})}(document,jQuery),function(e,t){"use strict";var i="fancybox-thumbs";t.fancybox.defaults=t.extend(!0,{btnTpl:{thumbs:''},thumbs:{autoStart:!1,hideOnClose:!0,parentEl:".fancybox-container",axis:"y"}},t.fancybox.defaults);var n=function(e){this.init(e)};t.extend(n.prototype,{$button:null,$grid:null,$list:null,isVisible:!1,isActive:!1,init:function(e){var t=this,i=e.group,n=0;t.instance=e,t.opts=i[e.currIndex].opts.thumbs,e.Thumbs=t,t.$button=e.$refs.toolbar.find("[data-fancybox-thumbs]");for(var o=0,s=i.length;o1));o++);n>1&&t.opts?(t.$button.removeAttr("style").on("click",function(){t.toggle()}),t.isActive=!0):t.$button.hide()},create:function(){var e,n=this.instance,o=this.opts.parentEl,s=[];this.$grid||(this.$grid=t('
').appendTo(n.$refs.container.find(o).addBack().filter(o)),this.$grid.on("click","a",function(){n.jumpTo(t(this).attr("data-index"))})),this.$list||(this.$list=t('
').appendTo(this.$grid)),t.each(n.group,function(t,i){(e=i.thumb)||"image"!==i.type||(e=i.src),s.push('")}),this.$list[0].innerHTML=s.join(""),"x"===this.opts.axis&&this.$list.width(parseInt(this.$grid.css("padding-right"),10)+n.group.length*this.$list.children().eq(0).outerWidth(!0))},focus:function(e){var t,i,n=this.$list,o=this.$grid;this.instance.current&&(i=(t=n.children().removeClass("fancybox-thumbs-active").filter('[data-index="'+this.instance.current.index+'"]').addClass("fancybox-thumbs-active")).position(),"y"===this.opts.axis&&(i.top<0||i.top>n.height()-t.outerHeight())?n.stop().animate({scrollTop:n.scrollTop()+i.top},e):"x"===this.opts.axis&&(i.lefto.scrollLeft()+(o.width()-t.outerWidth()))&&n.parent().stop().animate({scrollLeft:i.left},e))},update:function(){this.instance.$refs.container.toggleClass("fancybox-show-thumbs",this.isVisible),this.isVisible?(this.$grid||this.create(),this.instance.trigger("onThumbsShow"),this.focus(0)):this.$grid&&this.instance.trigger("onThumbsHide"),this.instance.update()},hide:function(){this.isVisible=!1,this.update()},show:function(){this.isVisible=!0,this.update()},toggle:function(){this.isVisible=!this.isVisible,this.update()}}),t(e).on({"onInit.fb":function(e,t){var i;t&&!t.Thumbs&&(i=new n(t)).isActive&&!0===i.opts.autoStart&&i.show()},"beforeShow.fb":function(e,t,i,n){var o=t&&t.Thumbs;o&&o.isVisible&&o.focus(n?0:250)},"afterKeydown.fb":function(e,t,i,n,o){var s=t&&t.Thumbs;s&&s.isActive&&71===o&&(n.preventDefault(),s.toggle())},"beforeClose.fb":function(e,t){var i=t&&t.Thumbs;i&&i.isVisible&&!1!==i.opts.hideOnClose&&i.$grid.hide()}})}(document,jQuery),function(e,t){"use strict";t.extend(!0,t.fancybox.defaults,{btnTpl:{share:''},share:{url:function(e,t){return!e.currentHash&&"inline"!==t.type&&"html"!==t.type&&(t.origSrc||t.src)||window.location},tpl:''}}),t(e).on("click","[data-fancybox-share]",function(){var e,i,n,o,s=t.fancybox.getInstance(),a=s.current||null;a&&("function"===t.type(a.opts.share.url)&&(e=a.opts.share.url.apply(a,[s,a])),i=a.opts.share.tpl.replace(/\{\{media\}\}/g,"image"===a.type?encodeURIComponent(a.src):"").replace(/\{\{url\}\}/g,encodeURIComponent(e)).replace(/\{\{url_raw\}\}/g,(n=e,o={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/","`":"`","=":"="},String(n).replace(/[&<>"'`=\/]/g,function(e){return o[e]}))).replace(/\{\{descr\}\}/g,s.$caption?encodeURIComponent(s.$caption.text()):""),t.fancybox.open({src:s.translate(s,i),type:"html",opts:{touch:!1,animationEffect:!1,afterLoad:function(e,t){s.$refs.container.one("beforeClose.fb",function(){e.close(null,0)}),t.$content.find(".fancybox-share__button").click(function(){return window.open(this.href,"Share","width=550, height=450"),!1})},mobile:{autoFocus:!1}}}))})}(document,jQuery),function(e,t,i){"use strict";function n(){var t=e.location.hash.substr(1),i=t.split("-"),n=i.length>1&&/^\+?\d+$/.test(i[i.length-1])&&parseInt(i.pop(-1),10)||1;return{hash:t,index:n<1?1:n,gallery:i.join("-")}}function o(e){""!==e.gallery&&i("[data-fancybox='"+i.escapeSelector(e.gallery)+"']").eq(e.index-1).focus().trigger("click.fb-start")}function s(e){var t,i;return!!e&&(""!==(i=(t=e.current?e.current.opts:e.opts).hash||(t.$orig?t.$orig.data("fancybox")||t.$orig.data("fancybox-trigger"):""))&&i)}i.escapeSelector||(i.escapeSelector=function(e){return(e+"").replace(/([\0-\x1f\x7f]|^-?\d)|^-$|[^\x80-\uFFFF\w-]/g,function(e,t){return t?"\0"===e?"�":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e})}),i(function(){!1!==i.fancybox.defaults.hash&&(i(t).on({"onInit.fb":function(e,t){var i,o;!1!==t.group[t.currIndex].opts.hash&&(i=n(),(o=s(t))&&i.gallery&&o==i.gallery&&(t.currIndex=i.index-1))},"beforeShow.fb":function(i,n,o,a){var r;o&&!1!==o.opts.hash&&(r=s(n))&&(n.currentHash=r+(n.group.length>1?"-"+(o.index+1):""),e.location.hash!=="#"+n.currentHash&&(a&&!n.origHash&&(n.origHash=e.location.hash),n.hashTimer&&clearTimeout(n.hashTimer),n.hashTimer=setTimeout(function(){"replaceState"in e.history?(e.history[a?"pushState":"replaceState"]({},t.title,e.location.pathname+e.location.search+"#"+n.currentHash),a&&(n.hasCreatedHistory=!0)):e.location.hash=n.currentHash,n.hashTimer=null},300)))},"beforeClose.fb":function(i,n,o){o&&!1!==o.opts.hash&&(clearTimeout(n.hashTimer),n.currentHash&&n.hasCreatedHistory?e.history.back():n.currentHash&&("replaceState"in e.history?e.history.replaceState({},t.title,e.location.pathname+e.location.search+(n.origHash||"")):e.location.hash=n.origHash),n.currentHash=null)}}),i(e).on("hashchange.fb",function(){var e=n(),t=null;i.each(i(".fancybox-container").get().reverse(),function(e,n){var o=i(n).data("FancyBox");if(o&&o.currentHash)return t=o,!1}),t?t.currentHash===e.gallery+"-"+e.index||1===e.index&&t.currentHash==e.gallery||(t.currentHash=null,t.close()):""!==e.gallery&&o(e)}),setTimeout(function(){i.fancybox.getInstance()||o(n())},50))})}(window,document,jQuery),function(e,t){"use strict";var i=(new Date).getTime();t(e).on({"onInit.fb":function(e,t,n){t.$refs.stage.on("mousewheel DOMMouseScroll wheel MozMousePixelScroll",function(e){var n=t.current,o=(new Date).getTime();t.group.length<2||!1===n.opts.wheel||"auto"===n.opts.wheel&&"image"!==n.type||(e.preventDefault(),e.stopPropagation(),n.$slide.hasClass("fancybox-animated")||(e=e.originalEvent||e,o-i<250||(i=o,t[(-e.deltaY||-e.deltaX||e.wheelDelta||-e.detail)<0?"next":"previous"]())))})}})}(document,jQuery)},36:function(e,t,i){"use strict";(function(e){var n=i(28);function o(e){return(o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var s=setTimeout;function a(){}function r(e){if(!(this instanceof r))throw new TypeError("Promises must be constructed via new");if("function"!=typeof e)throw new TypeError("not a function");this._state=0,this._handled=!1,this._value=void 0,this._deferreds=[],p(e,this)}function l(e,t){for(;3===e._state;)e=e._value;0!==e._state?(e._handled=!0,r._immediateFn(function(){var i=1===e._state?t.onFulfilled:t.onRejected;if(null!==i){var n;try{n=i(e._value)}catch(e){return void d(t.promise,e)}c(t.promise,n)}else(1===e._state?c:d)(t.promise,e._value)})):e._deferreds.push(t)}function c(e,t){try{if(t===e)throw new TypeError("A promise cannot be resolved with itself.");if(t&&("object"===o(t)||"function"==typeof t)){var i=t.then;if(t instanceof r)return e._state=3,e._value=t,void u(e);if("function"==typeof i)return void p((n=i,s=t,function(){n.apply(s,arguments)}),e)}e._state=1,e._value=t,u(e)}catch(t){d(e,t)}var n,s}function d(e,t){e._state=2,e._value=t,u(e)}function u(e){2===e._state&&0===e._deferreds.length&&r._immediateFn(function(){e._handled||r._unhandledRejectionFn(e._value)});for(var t=0,i=e._deferreds.length;t-1}function E(e){return!(!e||!b(e,"isVirtual"))||e instanceof Element}function T(e,t){return"function"==typeof e?e.apply(null,t):e}function S(e,t){e.filter(function(e){return"flip"===e.name})[0].enabled=t}function k(){return document.createElement("div")}function M(e,t){e.innerHTML=t instanceof Element?t.innerHTML:t}function _(e,t){t.content instanceof Element?(M(e,""),e.appendChild(t.content)):e[t.allowHTML?"innerHTML":"textContent"]=t.content}function D(e){return{tooltip:e.querySelector(h.TOOLTIP),backdrop:e.querySelector(h.BACKDROP),content:e.querySelector(h.CONTENT),arrow:e.querySelector(h.ARROW)||e.querySelector(h.ROUND_ARROW)}}function R(e){e.setAttribute("data-inertia","")}function L(e){var t=k();return"round"===e?(t.className="tippy-roundarrow",M(t,'')):t.className="tippy-arrow",t}function P(){var e=k();return e.className="tippy-backdrop",e.setAttribute("data-state","hidden"),e}function A(e,t){e.setAttribute("tabindex","-1"),t.setAttribute("data-interactive","")}function $(e,t){e.forEach(function(e){e&&(e.style.transitionDuration="".concat(t,"ms"))})}function I(e,t,i){var n=l&&void 0!==document.body.style.webkitTransition?"webkitTransitionEnd":"transitionend";e[t+"EventListener"](n,i)}function z(e){var t=e.getAttribute("x-placement");return t?t.split("-")[0]:""}function F(e,t){e.forEach(function(e){e&&e.setAttribute("data-state",t)})}function H(e,t,i){i.split(" ").forEach(function(i){e.classList[t](i+"-theme")})}function O(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.checkHideOnClick,i=e.exclude,n=e.duration;m(document.querySelectorAll(h.POPPER)).forEach(function(e){var o=e._tippy;!o||t&&!0!==o.props.hideOnClick||i&&e===i.popper||o.hide(n)})}var N={passive:!0},B=4,j=!1;function V(){j||(j=!0,c&&document.body.classList.add("tippy-iOS"),window.performance&&document.addEventListener("mousemove",W))}var q=0;function W(){var e=performance.now();e-q<20&&(j=!1,document.removeEventListener("mousemove",W),c||document.body.classList.remove("tippy-iOS")),q=e}function G(e){var t=e.target;if(!(t instanceof Element))return O();var i=g(t,h.POPPER);if(!(i&&i._tippy&&i._tippy.props.interactive)){var n=v(t,function(e){return e._tippy&&e._tippy.reference===e});if(n){var o=n._tippy,s=C(o.props.trigger,"click");if(j||s)return O({exclude:o,checkHideOnClick:!0});if(!0!==o.props.hideOnClick||s)return;o.clearDelayTimeouts()}O({checkHideOnClick:!0})}}function Y(){var e=document.activeElement;e&&e.blur&&e._tippy&&e.blur()}var X=Object.keys(d);function U(e,t){var i=o({},t,{content:T(t.content,[e])},t.ignoreAttributes?{}:function(e){return X.reduce(function(t,i){var n=(e.getAttribute("data-tippy-".concat(i))||"").trim();if(!n)return t;if("content"===i)t[i]=n;else try{t[i]=JSON.parse(n)}catch(e){t[i]=n}return t},{})}(e));return(i.arrow||l)&&(i.animateFill=!1),i}function K(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;Object.keys(e).forEach(function(e){if(!b(t,e))throw new Error("[tippy]: `".concat(e,"` is not a valid option"))})}var J=1;function Q(e,t){var i=U(e,t);if(!i.multiple&&e._tippy)return null;var s={},a=null,l=0,c=0,p=!1,E=function(){},M=[],O=i.interactiveDebounce>0?w(oe,i.interactiveDebounce):oe,V=null,q=J++,W=function(e,t){var i=k();i.className="tippy-popper",i.id="tippy-".concat(e),i.style.zIndex=t.zIndex,t.role&&i.setAttribute("role",t.role);var n=k();n.className="tippy-tooltip",n.style.maxWidth=t.maxWidth+("number"==typeof t.maxWidth?"px":""),n.setAttribute("data-size",t.size),n.setAttribute("data-animation",t.animation),n.setAttribute("data-state","hidden"),H(n,"add",t.theme);var o=k();return o.className="tippy-content",o.setAttribute("data-state","hidden"),t.interactive&&A(i,n),t.arrow&&n.appendChild(L(t.arrowType)),t.animateFill&&(n.appendChild(P()),n.setAttribute("data-animatefill","")),t.inertia&&R(n),_(o,t),n.appendChild(o),i.appendChild(n),i}(q,i);W.addEventListener("mouseenter",function(e){Y.props.interactive&&Y.state.isVisible&&"mouseenter"===s.type&&Z(e)}),W.addEventListener("mouseleave",function(){Y.props.interactive&&"mouseenter"===s.type&&document.addEventListener("mousemove",O)});var G,Y={id:q,reference:e,popper:W,popperChildren:D(W),popperInstance:null,props:i,state:{isEnabled:!0,isVisible:!1,isDestroyed:!1,isMounted:!1,isShown:!1},clearDelayTimeouts:ve,set:be,setContent:function(e){be({content:e})},show:ye,hide:we,enable:function(){Y.state.isEnabled=!0},disable:function(){Y.state.isEnabled=!1},destroy:xe};return fe(),i.lazy||(de(),Y.popperInstance.disableEventListeners()),i.showOnInit&&Z(),i.a11y&&!i.target&&((G=e)instanceof Element&&(!f.call(G,"a[href],area[href],button,details,input,textarea,select,iframe,[tabindex]")||G.hasAttribute("disabled")))&&e.setAttribute("tabindex","0"),e._tippy=Y,W._tippy=Y,Y;function X(e){var t=a=e,i=t.clientX,n=t.clientY;if(Y.popperInstance){var o=z(Y.popper),s=Y.props.arrow?B+("round"===Y.props.arrowType?18:16):B,r=C(["top","bottom"],o),l=C(["left","right"],o),c=r?Math.max(s,i):i,d=l?Math.max(s,n):n;r&&c>s&&(c=Math.min(i,window.innerWidth-s)),l&&d>s&&(d=Math.min(n,window.innerHeight-s));var u=Y.reference.getBoundingClientRect(),h=Y.props.followCursor,p="horizontal"===h,f="vertical"===h;Y.popperInstance.reference={getBoundingClientRect:function(){return{width:0,height:0,top:p?u.top:d,bottom:p?u.bottom:d,left:f?u.left:c,right:f?u.right:c}},clientWidth:0,clientHeight:0},Y.popperInstance.scheduleUpdate(),"initial"===h&&Y.state.isVisible&&te()}}function Z(e){if(ve(),!Y.state.isVisible){if(Y.props.target)return function(e){var i=g(e.target,Y.props.target);i&&!i._tippy&&(Q(i,o({},Y.props,{content:T(t.content,[i]),appendTo:t.appendTo,target:"",showOnInit:!0})),Z(e))}(e);if(p=!0,Y.props.wait)return Y.props.wait(Y,e);ue()&&!Y.state.isMounted&&document.addEventListener("mousemove",X);var i=y(Y.props.delay,0,d.delay);i?l=setTimeout(function(){ye()},i):ye()}}function ee(){if(ve(),!Y.state.isVisible)return te();p=!1;var e=y(Y.props.delay,1,d.delay);e?c=setTimeout(function(){Y.state.isVisible&&we()},e):we()}function te(){document.removeEventListener("mousemove",X)}function ie(){document.body.removeEventListener("mouseleave",ee),document.removeEventListener("mousemove",O)}function ne(e){Y.state.isEnabled&&!ce(e)&&(Y.state.isVisible||(s=e,e instanceof MouseEvent&&(a=e)),"click"===e.type&&!1!==Y.props.hideOnClick&&Y.state.isVisible?ee():Z(e))}function oe(e){var t=v(e.target,function(e){return e._tippy}),i=g(e.target,h.POPPER)===Y.popper,n=t===Y.reference;i||n||function(e,t,i,n){if(!e)return!0;var o=i.clientX,s=i.clientY,a=n.interactiveBorder,r=n.distance,l=t.top-s>("top"===e?a+r:a),c=s-t.bottom>("bottom"===e?a+r:a),d=t.left-o>("left"===e?a+r:a),u=o-t.right>("right"===e?a+r:a);return l||c||d||u}(z(Y.popper),Y.popper.getBoundingClientRect(),e,Y.props)&&(ie(),ee())}function se(e){if(!ce(e))return Y.props.interactive?(document.body.addEventListener("mouseleave",ee),void document.addEventListener("mousemove",O)):void ee()}function ae(e){e.target===Y.reference&&(Y.props.interactive&&e.relatedTarget&&Y.popper.contains(e.relatedTarget)||ee())}function re(e){g(e.target,Y.props.target)&&Z(e)}function le(e){g(e.target,Y.props.target)&&ee()}function ce(e){var t="ontouchstart"in window,i=C(e.type,"touch"),n=Y.props.touchHold;return t&&j&&n&&!i||j&&!n&&i}function de(){var e=Y.props.popperOptions,t=Y.popperChildren,i=t.tooltip,s=t.arrow;Y.popperInstance=new n.a(Y.reference,Y.popper,o({placement:Y.props.placement},e,{modifiers:o({},e?e.modifiers:{},{preventOverflow:o({boundariesElement:Y.props.boundary,padding:B},x(e,"preventOverflow")),arrow:o({element:s,enabled:!!s},x(e,"arrow")),flip:o({enabled:Y.props.flip,padding:Y.props.distance+B,behavior:Y.props.flipBehavior},x(e,"flip")),offset:o({offset:Y.props.offset},x(e,"offset"))}),onUpdate:function(t){Y.props.flip&&!Y.props.flipOnUpdate&&(t.flipped&&(Y.popperInstance.options.placement=t.placement),S(Y.popperInstance.modifiers,!1));var n=z(Y.popper),o=i.style;o.top="",o.bottom="",o.left="",o.right="",o[n]=-(Y.props.distance-10)+"px";var s={top:B,bottom:B,left:B,right:B};s[n]=B+Y.props.distance,Y.popperInstance.modifiers.filter(function(e){return"preventOverflow"===e.name})[0].padding=s,e&&e.onUpdate&&e.onUpdate(t)}}))}function ue(){return Y.props.followCursor&&!j&&"focus"!==s.type}function he(e,t){function i(e){e.target===n&&(I(n,"remove",i),t())}if(0===e)return t();var n=Y.popperChildren.tooltip;I(n,"remove",E),I(n,"add",i),E=i}function pe(e,t){var i=arguments.length>2&&void 0!==arguments[2]&&arguments[2];Y.reference.addEventListener(e,t,i),M.push({eventType:e,handler:t,options:i})}function fe(){Y.props.touchHold&&!Y.props.target&&(pe("touchstart",ne,N),pe("touchend",se,N)),Y.props.trigger.trim().split(" ").forEach(function(e){if("manual"!==e)if(Y.props.target)switch(e){case"mouseenter":pe("mouseover",re),pe("mouseout",le);break;case"focus":pe("focusin",re),pe("focusout",le);break;case"click":pe(e,re)}else switch(pe(e,ne),e){case"mouseenter":pe("mouseleave",se);break;case"focus":pe(r?"focusout":"blur",ae)}})}function me(){M.forEach(function(e){var t=e.eventType,i=e.handler,n=e.options;Y.reference.removeEventListener(t,i,n)}),M=[]}function ge(){return[Y.popperChildren.tooltip,Y.popperChildren.backdrop,Y.popperChildren.content]}function ve(){clearTimeout(l),clearTimeout(c)}function be(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};K(e,d);var t=Y.props,i=U(Y.reference,o({},Y.props,e,{ignoreAttributes:!0}));i.ignoreAttributes=b(e,"ignoreAttributes")?e.ignoreAttributes:t.ignoreAttributes,Y.props=i,(b(e,"trigger")||b(e,"touchHold"))&&(me(),fe()),b(e,"interactiveDebounce")&&(ie(),O=w(oe,e.interactiveDebounce)),function(e,t,i){var n=D(e),o=n.tooltip,s=n.content,a=n.backdrop,r=n.arrow;e.style.zIndex=i.zIndex,o.setAttribute("data-size",i.size),o.setAttribute("data-animation",i.animation),o.style.maxWidth=i.maxWidth+("number"==typeof i.maxWidth?"px":""),i.role?e.setAttribute("role",i.role):e.removeAttribute("role"),t.content!==i.content&&_(s,i),!t.animateFill&&i.animateFill?(o.appendChild(P()),o.setAttribute("data-animatefill","")):t.animateFill&&!i.animateFill&&(o.removeChild(a),o.removeAttribute("data-animatefill")),!t.arrow&&i.arrow?o.appendChild(L(i.arrowType)):t.arrow&&!i.arrow&&o.removeChild(r),t.arrow&&i.arrow&&t.arrowType!==i.arrowType&&o.replaceChild(L(i.arrowType),r),!t.interactive&&i.interactive?A(e,o):t.interactive&&!i.interactive&&function(e,t){e.removeAttribute("tabindex"),t.removeAttribute("data-interactive")}(e,o),!t.inertia&&i.inertia?R(o):t.inertia&&!i.inertia&&function(e){e.removeAttribute("data-inertia")}(o),t.theme!==i.theme&&(H(o,"remove",t.theme),H(o,"add",i.theme))}(Y.popper,t,i),Y.popperChildren=D(Y.popper),Y.popperInstance&&(Y.popperInstance.update(),u.some(function(t){return b(e,t)})&&(Y.popperInstance.destroy(),de(),Y.state.isVisible||Y.popperInstance.disableEventListeners(),Y.props.followCursor&&a&&X(a)))}function ye(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:y(Y.props.duration,0,d.duration[0]);if(!Y.state.isDestroyed&&Y.state.isEnabled&&(!j||Y.props.touch))return b(Y.reference,"isVirtual")||document.documentElement.contains(Y.reference)?void(Y.reference.hasAttribute("disabled")||!1!==Y.props.onShow(Y)&&(Y.popper.style.visibility="visible",Y.state.isVisible=!0,Y.props.interactive&&Y.reference.classList.add("tippy-active"),$([Y.popper,Y.popperChildren.tooltip,Y.popperChildren.backdrop],0),function(e){var t=!(ue()||"initial"===Y.props.followCursor&&j);Y.popperInstance?(ue()||(Y.popperInstance.scheduleUpdate(),t&&Y.popperInstance.enableEventListeners()),S(Y.popperInstance.modifiers,Y.props.flip)):(de(),t||Y.popperInstance.disableEventListeners()),Y.popperInstance.reference=Y.reference;var i=Y.popperChildren.arrow;if(ue()){i&&(i.style.margin="0");var n=y(Y.props.delay,0,d.delay);s.type&&X(n&&a?a:s)}else i&&(i.style.margin="");j&&a&&"initial"===Y.props.followCursor&&(X(a),i&&(i.style.margin="0")),function(e,t){var i=e.popper,n=e.options,o=n.onCreate,s=n.onUpdate;n.onCreate=n.onUpdate=function(e){!function(e){e.offsetHeight}(i),t(),s(e),n.onCreate=o,n.onUpdate=s}}(Y.popperInstance,e);var o=Y.props.appendTo;(V="parent"===o?Y.reference.parentNode:T(o,[Y.reference])).contains(Y.popper)||(V.appendChild(Y.popper),Y.props.onMount(Y),Y.state.isMounted=!0)}(function(){Y.state.isVisible&&(ue()||Y.popperInstance.update(),$([Y.popper],i.updateDuration),$(ge(),e),Y.popperChildren.backdrop&&(Y.popperChildren.content.style.transitionDelay=Math.round(e/12)+"ms"),Y.props.sticky&&($([Y.popper],r?0:Y.props.updateDuration),function e(){Y.popperInstance&&Y.popperInstance.scheduleUpdate(),Y.state.isMounted?requestAnimationFrame(e):$([Y.popper],0)}()),F(ge(),"visible"),function(e,t){he(e,t)}(e,function(){Y.popperChildren.tooltip.classList.add("tippy-notransition"),Y.props.aria&&Y.reference.setAttribute("aria-".concat(Y.props.aria),Y.popper.id),Y.props.onShown(Y),Y.state.isShown=!0}))}))):xe()}function we(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:y(Y.props.duration,1,d.duration[1]);!Y.state.isDestroyed&&Y.state.isEnabled&&!1!==Y.props.onHide(Y)&&(Y.popperChildren.tooltip.classList.remove("tippy-notransition"),Y.props.interactive&&Y.reference.classList.remove("tippy-active"),Y.popper.style.visibility="hidden",Y.state.isVisible=!1,Y.state.isShown=!1,$(ge(),e),F(ge(),"hidden"),function(e,t){he(e,function(){!Y.state.isVisible&&V&&V.contains(Y.popper)&&t()})}(e,function(){p||te(),Y.props.aria&&Y.reference.removeAttribute("aria-".concat(Y.props.aria)),Y.popperInstance.disableEventListeners(),Y.popperInstance.options.placement=Y.props.placement,V.removeChild(Y.popper),Y.props.onHidden(Y),Y.state.isMounted=!1}))}function xe(e){Y.state.isDestroyed||(Y.state.isMounted&&we(0),me(),delete Y.reference._tippy,Y.props.target&&e&&m(Y.reference.querySelectorAll(Y.props.target)).forEach(function(e){e._tippy&&e._tippy.destroy()}),Y.popperInstance&&Y.popperInstance.destroy(),Y.state.isDestroyed=!0)}}var Z=!1;function ee(e,t){K(t,d),Z||(document.addEventListener("click",G,!0),document.addEventListener("touchstart",V,N),window.addEventListener("blur",Y),Z=!0);var i,n=o({},d,t);i=e,"[object Object]"!=={}.toString.call(i)||i.addEventListener||function(e){var t={isVirtual:!0,attributes:e.attributes||{},setAttribute:function(t,i){e.attributes[t]=i},getAttribute:function(t){return e.attributes[t]},removeAttribute:function(t){delete e.attributes[t]},hasAttribute:function(t){return t in e.attributes},addEventListener:function(){},removeEventListener:function(){},classList:{classNames:{},add:function(t){e.classList.classNames[t]=!0},remove:function(t){delete e.classList.classNames[t]},contains:function(t){return t in e.classList.classNames}}};for(var i in t)e[i]=t[i]}(e);var s=function(e){if(E(e))return[e];if(e instanceof NodeList)return m(e);if(Array.isArray(e))return e;try{return m(document.querySelectorAll(e))}catch(e){return[]}}(e).reduce(function(e,t){var i=t&&Q(t,n);return i&&e.push(i),e},[]);return E(e)?s[0]:s}ee.version="4.0.4",ee.defaults=d,ee.setDefaults=function(e){Object.keys(e).forEach(function(t){d[t]=e[t]})},ee.hideAll=O,ee.group=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=t.delay,n=void 0===i?e[0].props.delay:i,o=t.duration,s=void 0===o?0:o,a=!1;function r(e){a=e,u()}function l(t){t._originalProps.onShow(t),e.forEach(function(e){e.set({duration:s}),e.hide()}),r(!0)}function c(e){e._originalProps.onHide(e),r(!1)}function d(e){e._originalProps.onShown(e),e.set({duration:e._originalProps.duration})}function u(){e.forEach(function(e){e.set({onShow:l,onShown:d,onHide:c,delay:a?[0,Array.isArray(n)?n[1]:n]:n,duration:a?s:e._originalProps.duration})})}e.forEach(function(e){e._originalProps={duration:e.props.duration,onHide:e.props.onHide,onShow:e.props.onShow,onShown:e.props.onShown}}),u()},s&&setTimeout(function(){m(document.querySelectorAll("[data-tippy]")).forEach(function(e){var t=e.getAttribute("data-tippy");t&&ee(e,{content:t})})}),function(e){if(s){var t=document.createElement("style");t.type="text/css",t.textContent=e;var i=document.head,n=i.firstChild;n?i.insertBefore(t,n):i.appendChild(t)}}('.tippy-iOS{cursor:pointer!important}.tippy-notransition{transition:none}.tippy-popper{transition-timing-function:cubic-bezier(.165,.84,.44,1);max-width:calc(100% - 8px);pointer-events:none;outline:0}.tippy-popper[x-placement^=top] .tippy-backdrop{border-radius:40% 40% 0 0}.tippy-popper[x-placement^=top] .tippy-roundarrow{bottom:-7px;bottom:-6.5px;-webkit-transform-origin:50% 0;transform-origin:50% 0;margin:0 3px}.tippy-popper[x-placement^=top] .tippy-roundarrow svg{position:absolute;left:0;-webkit-transform:rotate(180deg);transform:rotate(180deg)}.tippy-popper[x-placement^=top] .tippy-arrow{border-top:8px solid #333;border-right:8px solid transparent;border-left:8px solid transparent;bottom:-7px;margin:0 3px;-webkit-transform-origin:50% 0;transform-origin:50% 0}.tippy-popper[x-placement^=top] .tippy-backdrop{-webkit-transform-origin:0 25%;transform-origin:0 25%}.tippy-popper[x-placement^=top] .tippy-backdrop[data-state=visible]{-webkit-transform:scale(1) translate(-50%,-55%);transform:scale(1) translate(-50%,-55%)}.tippy-popper[x-placement^=top] .tippy-backdrop[data-state=hidden]{-webkit-transform:scale(.2) translate(-50%,-45%);transform:scale(.2) translate(-50%,-45%);opacity:0}.tippy-popper[x-placement^=top] [data-animation=shift-toward][data-state=visible]{-webkit-transform:translateY(-10px);transform:translateY(-10px)}.tippy-popper[x-placement^=top] [data-animation=shift-toward][data-state=hidden]{opacity:0;-webkit-transform:translateY(-20px);transform:translateY(-20px)}.tippy-popper[x-placement^=top] [data-animation=perspective]{-webkit-transform-origin:bottom;transform-origin:bottom}.tippy-popper[x-placement^=top] [data-animation=perspective][data-state=visible]{-webkit-transform:perspective(700px) translateY(-10px) rotateX(0);transform:perspective(700px) translateY(-10px) rotateX(0)}.tippy-popper[x-placement^=top] [data-animation=perspective][data-state=hidden]{opacity:0;-webkit-transform:perspective(700px) translateY(0) rotateX(60deg);transform:perspective(700px) translateY(0) rotateX(60deg)}.tippy-popper[x-placement^=top] [data-animation=fade][data-state=visible]{-webkit-transform:translateY(-10px);transform:translateY(-10px)}.tippy-popper[x-placement^=top] [data-animation=fade][data-state=hidden]{opacity:0;-webkit-transform:translateY(-10px);transform:translateY(-10px)}.tippy-popper[x-placement^=top] [data-animation=shift-away][data-state=visible]{-webkit-transform:translateY(-10px);transform:translateY(-10px)}.tippy-popper[x-placement^=top] [data-animation=shift-away][data-state=hidden]{opacity:0;-webkit-transform:translateY(0);transform:translateY(0)}.tippy-popper[x-placement^=top] [data-animation=scale]{-webkit-transform-origin:bottom;transform-origin:bottom}.tippy-popper[x-placement^=top] [data-animation=scale][data-state=visible]{-webkit-transform:translateY(-10px) scale(1);transform:translateY(-10px) scale(1)}.tippy-popper[x-placement^=top] [data-animation=scale][data-state=hidden]{opacity:0;-webkit-transform:translateY(-10px) scale(.5);transform:translateY(-10px) scale(.5)}.tippy-popper[x-placement^=bottom] .tippy-backdrop{border-radius:0 0 30% 30%}.tippy-popper[x-placement^=bottom] .tippy-roundarrow{top:-7px;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;margin:0 3px}.tippy-popper[x-placement^=bottom] .tippy-roundarrow svg{position:absolute;left:0;-webkit-transform:rotate(0);transform:rotate(0)}.tippy-popper[x-placement^=bottom] .tippy-arrow{border-bottom:8px solid #333;border-right:8px solid transparent;border-left:8px solid transparent;top:-7px;margin:0 3px;-webkit-transform-origin:50% 100%;transform-origin:50% 100%}.tippy-popper[x-placement^=bottom] .tippy-backdrop{-webkit-transform-origin:0 -50%;transform-origin:0 -50%}.tippy-popper[x-placement^=bottom] .tippy-backdrop[data-state=visible]{-webkit-transform:scale(1) translate(-50%,-45%);transform:scale(1) translate(-50%,-45%)}.tippy-popper[x-placement^=bottom] .tippy-backdrop[data-state=hidden]{-webkit-transform:scale(.2) translate(-50%);transform:scale(.2) translate(-50%);opacity:0}.tippy-popper[x-placement^=bottom] [data-animation=shift-toward][data-state=visible]{-webkit-transform:translateY(10px);transform:translateY(10px)}.tippy-popper[x-placement^=bottom] [data-animation=shift-toward][data-state=hidden]{opacity:0;-webkit-transform:translateY(20px);transform:translateY(20px)}.tippy-popper[x-placement^=bottom] [data-animation=perspective]{-webkit-transform-origin:top;transform-origin:top}.tippy-popper[x-placement^=bottom] [data-animation=perspective][data-state=visible]{-webkit-transform:perspective(700px) translateY(10px) rotateX(0);transform:perspective(700px) translateY(10px) rotateX(0)}.tippy-popper[x-placement^=bottom] [data-animation=perspective][data-state=hidden]{opacity:0;-webkit-transform:perspective(700px) translateY(0) rotateX(-60deg);transform:perspective(700px) translateY(0) rotateX(-60deg)}.tippy-popper[x-placement^=bottom] [data-animation=fade][data-state=visible]{-webkit-transform:translateY(10px);transform:translateY(10px)}.tippy-popper[x-placement^=bottom] [data-animation=fade][data-state=hidden]{opacity:0;-webkit-transform:translateY(10px);transform:translateY(10px)}.tippy-popper[x-placement^=bottom] [data-animation=shift-away][data-state=visible]{-webkit-transform:translateY(10px);transform:translateY(10px)}.tippy-popper[x-placement^=bottom] [data-animation=shift-away][data-state=hidden]{opacity:0;-webkit-transform:translateY(0);transform:translateY(0)}.tippy-popper[x-placement^=bottom] [data-animation=scale]{-webkit-transform-origin:top;transform-origin:top}.tippy-popper[x-placement^=bottom] [data-animation=scale][data-state=visible]{-webkit-transform:translateY(10px) scale(1);transform:translateY(10px) scale(1)}.tippy-popper[x-placement^=bottom] [data-animation=scale][data-state=hidden]{opacity:0;-webkit-transform:translateY(10px) scale(.5);transform:translateY(10px) scale(.5)}.tippy-popper[x-placement^=left] .tippy-backdrop{border-radius:50% 0 0 50%}.tippy-popper[x-placement^=left] .tippy-roundarrow{right:-12px;-webkit-transform-origin:33.33333333% 50%;transform-origin:33.33333333% 50%;margin:3px 0}.tippy-popper[x-placement^=left] .tippy-roundarrow svg{position:absolute;left:0;-webkit-transform:rotate(90deg);transform:rotate(90deg)}.tippy-popper[x-placement^=left] .tippy-arrow{border-left:8px solid #333;border-top:8px solid transparent;border-bottom:8px solid transparent;right:-7px;margin:3px 0;-webkit-transform-origin:0 50%;transform-origin:0 50%}.tippy-popper[x-placement^=left] .tippy-backdrop{-webkit-transform-origin:50% 0;transform-origin:50% 0}.tippy-popper[x-placement^=left] .tippy-backdrop[data-state=visible]{-webkit-transform:scale(1) translate(-50%,-50%);transform:scale(1) translate(-50%,-50%)}.tippy-popper[x-placement^=left] .tippy-backdrop[data-state=hidden]{-webkit-transform:scale(.2) translate(-75%,-50%);transform:scale(.2) translate(-75%,-50%);opacity:0}.tippy-popper[x-placement^=left] [data-animation=shift-toward][data-state=visible]{-webkit-transform:translateX(-10px);transform:translateX(-10px)}.tippy-popper[x-placement^=left] [data-animation=shift-toward][data-state=hidden]{opacity:0;-webkit-transform:translateX(-20px);transform:translateX(-20px)}.tippy-popper[x-placement^=left] [data-animation=perspective]{-webkit-transform-origin:right;transform-origin:right}.tippy-popper[x-placement^=left] [data-animation=perspective][data-state=visible]{-webkit-transform:perspective(700px) translateX(-10px) rotateY(0);transform:perspective(700px) translateX(-10px) rotateY(0)}.tippy-popper[x-placement^=left] [data-animation=perspective][data-state=hidden]{opacity:0;-webkit-transform:perspective(700px) translateX(0) rotateY(-60deg);transform:perspective(700px) translateX(0) rotateY(-60deg)}.tippy-popper[x-placement^=left] [data-animation=fade][data-state=visible]{-webkit-transform:translateX(-10px);transform:translateX(-10px)}.tippy-popper[x-placement^=left] [data-animation=fade][data-state=hidden]{opacity:0;-webkit-transform:translateX(-10px);transform:translateX(-10px)}.tippy-popper[x-placement^=left] [data-animation=shift-away][data-state=visible]{-webkit-transform:translateX(-10px);transform:translateX(-10px)}.tippy-popper[x-placement^=left] [data-animation=shift-away][data-state=hidden]{opacity:0;-webkit-transform:translateX(0);transform:translateX(0)}.tippy-popper[x-placement^=left] [data-animation=scale]{-webkit-transform-origin:right;transform-origin:right}.tippy-popper[x-placement^=left] [data-animation=scale][data-state=visible]{-webkit-transform:translateX(-10px) scale(1);transform:translateX(-10px) scale(1)}.tippy-popper[x-placement^=left] [data-animation=scale][data-state=hidden]{opacity:0;-webkit-transform:translateX(-10px) scale(.5);transform:translateX(-10px) scale(.5)}.tippy-popper[x-placement^=right] .tippy-backdrop{border-radius:0 50% 50% 0}.tippy-popper[x-placement^=right] .tippy-roundarrow{left:-12px;-webkit-transform-origin:66.66666666% 50%;transform-origin:66.66666666% 50%;margin:3px 0}.tippy-popper[x-placement^=right] .tippy-roundarrow svg{position:absolute;left:0;-webkit-transform:rotate(-90deg);transform:rotate(-90deg)}.tippy-popper[x-placement^=right] .tippy-arrow{border-right:8px solid #333;border-top:8px solid transparent;border-bottom:8px solid transparent;left:-7px;margin:3px 0;-webkit-transform-origin:100% 50%;transform-origin:100% 50%}.tippy-popper[x-placement^=right] .tippy-backdrop{-webkit-transform-origin:-50% 0;transform-origin:-50% 0}.tippy-popper[x-placement^=right] .tippy-backdrop[data-state=visible]{-webkit-transform:scale(1) translate(-50%,-50%);transform:scale(1) translate(-50%,-50%)}.tippy-popper[x-placement^=right] .tippy-backdrop[data-state=hidden]{-webkit-transform:scale(.2) translate(-25%,-50%);transform:scale(.2) translate(-25%,-50%);opacity:0}.tippy-popper[x-placement^=right] [data-animation=shift-toward][data-state=visible]{-webkit-transform:translateX(10px);transform:translateX(10px)}.tippy-popper[x-placement^=right] [data-animation=shift-toward][data-state=hidden]{opacity:0;-webkit-transform:translateX(20px);transform:translateX(20px)}.tippy-popper[x-placement^=right] [data-animation=perspective]{-webkit-transform-origin:left;transform-origin:left}.tippy-popper[x-placement^=right] [data-animation=perspective][data-state=visible]{-webkit-transform:perspective(700px) translateX(10px) rotateY(0);transform:perspective(700px) translateX(10px) rotateY(0)}.tippy-popper[x-placement^=right] [data-animation=perspective][data-state=hidden]{opacity:0;-webkit-transform:perspective(700px) translateX(0) rotateY(60deg);transform:perspective(700px) translateX(0) rotateY(60deg)}.tippy-popper[x-placement^=right] [data-animation=fade][data-state=visible]{-webkit-transform:translateX(10px);transform:translateX(10px)}.tippy-popper[x-placement^=right] [data-animation=fade][data-state=hidden]{opacity:0;-webkit-transform:translateX(10px);transform:translateX(10px)}.tippy-popper[x-placement^=right] [data-animation=shift-away][data-state=visible]{-webkit-transform:translateX(10px);transform:translateX(10px)}.tippy-popper[x-placement^=right] [data-animation=shift-away][data-state=hidden]{opacity:0;-webkit-transform:translateX(0);transform:translateX(0)}.tippy-popper[x-placement^=right] [data-animation=scale]{-webkit-transform-origin:left;transform-origin:left}.tippy-popper[x-placement^=right] [data-animation=scale][data-state=visible]{-webkit-transform:translateX(10px) scale(1);transform:translateX(10px) scale(1)}.tippy-popper[x-placement^=right] [data-animation=scale][data-state=hidden]{opacity:0;-webkit-transform:translateX(10px) scale(.5);transform:translateX(10px) scale(.5)}.tippy-tooltip{position:relative;color:#fff;border-radius:.25rem;font-size:.875rem;padding:.3125rem .5625rem;line-height:1.4;text-align:center;will-change:transform;background-color:#333}.tippy-tooltip[data-size=small]{padding:.1875rem .375rem;font-size:.75rem}.tippy-tooltip[data-size=large]{padding:.375rem .75rem;font-size:1rem}.tippy-tooltip[data-animatefill]{overflow:hidden;background-color:transparent}.tippy-tooltip[data-interactive],.tippy-tooltip[data-interactive] path{pointer-events:auto}.tippy-tooltip[data-inertia][data-state=visible]{transition-timing-function:cubic-bezier(.54,1.5,.38,1.11)}.tippy-tooltip[data-inertia][data-state=hidden]{transition-timing-function:ease}.tippy-arrow,.tippy-roundarrow{position:absolute;width:0;height:0}.tippy-roundarrow{width:18px;height:7px;fill:#333;pointer-events:none}.tippy-backdrop{position:absolute;will-change:transform;background-color:#333;border-radius:50%;width:calc(110% + 2rem);left:50%;top:50%;z-index:-1;transition:all cubic-bezier(.46,.1,.52,.98);-webkit-backface-visibility:hidden;backface-visibility:hidden}.tippy-backdrop:after{content:"";float:left;padding-top:100%}.tippy-backdrop+.tippy-content{transition-property:opacity;will-change:opacity}.tippy-backdrop+.tippy-content[data-state=visible]{opacity:1}.tippy-backdrop+.tippy-content[data-state=hidden]{opacity:0}'),t.a=ee},38:function(e,t,i){"use strict";(function(e){for( /**! * @fileOverview Kickass library to create and place poppers near their reference elements. * @version 1.14.7 * @license * Copyright (c) 2016 Federico Zivolo and contributors * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal * in the Software without restriction, including without limitation the rights * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell * copies of the Software, and to permit persons to whom the Software is * furnished to do so, subject to the following conditions: * * The above copyright notice and this permission notice shall be included in all * copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ var i="undefined"!=typeof window&&"undefined"!=typeof document,n=["Edge","Trident","Firefox"],o=0,s=0;s=0){o=1;break}var a=i&&window.Promise?function(e){var t=!1;return function(){t||(t=!0,window.Promise.resolve().then(function(){t=!1,e()}))}}:function(e){var t=!1;return function(){t||(t=!0,setTimeout(function(){t=!1,e()},o))}};function r(e){return e&&"[object Function]"==={}.toString.call(e)}function l(e,t){if(1!==e.nodeType)return[];var i=e.ownerDocument.defaultView.getComputedStyle(e,null);return t?i[t]:i}function c(e){return"HTML"===e.nodeName?e:e.parentNode||e.host}function d(e){if(!e)return document.body;switch(e.nodeName){case"HTML":case"BODY":return e.ownerDocument.body;case"#document":return e.body}var t=l(e),i=t.overflow,n=t.overflowX,o=t.overflowY;return/(auto|scroll|overlay)/.test(i+o+n)?e:d(c(e))}var u=i&&!(!window.MSInputMethodContext||!document.documentMode),h=i&&/MSIE 10/.test(navigator.userAgent);function p(e){return 11===e?u:10===e?h:u||h}function f(e){if(!e)return document.documentElement;for(var t=p(10)?document.body:null,i=e.offsetParent||null;i===t&&e.nextElementSibling;)i=(e=e.nextElementSibling).offsetParent;var n=i&&i.nodeName;return n&&"BODY"!==n&&"HTML"!==n?-1!==["TH","TD","TABLE"].indexOf(i.nodeName)&&"static"===l(i,"position")?f(i):i:e?e.ownerDocument.documentElement:document.documentElement}function m(e){return null!==e.parentNode?m(e.parentNode):e}function g(e,t){if(!(e&&e.nodeType&&t&&t.nodeType))return document.documentElement;var i=e.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_FOLLOWING,n=i?e:t,o=i?t:e,s=document.createRange();s.setStart(n,0),s.setEnd(o,0);var a,r,l=s.commonAncestorContainer;if(e!==l&&t!==l||n.contains(o))return"BODY"===(r=(a=l).nodeName)||"HTML"!==r&&f(a.firstElementChild)!==a?f(l):l;var c=m(e);return c.host?g(c.host,t):g(e,m(t).host)}function v(e){var t="top"===(arguments.length>1&&void 0!==arguments[1]?arguments[1]:"top")?"scrollTop":"scrollLeft",i=e.nodeName;if("BODY"===i||"HTML"===i){var n=e.ownerDocument.documentElement;return(e.ownerDocument.scrollingElement||n)[t]}return e[t]}function b(e,t){var i="x"===t?"Left":"Top",n="Left"===i?"Right":"Bottom";return parseFloat(e["border"+i+"Width"],10)+parseFloat(e["border"+n+"Width"],10)}function y(e,t,i,n){return Math.max(t["offset"+e],t["scroll"+e],i["client"+e],i["offset"+e],i["scroll"+e],p(10)?parseInt(i["offset"+e])+parseInt(n["margin"+("Height"===e?"Top":"Left")])+parseInt(n["margin"+("Height"===e?"Bottom":"Right")]):0)}function w(e){var t=e.body,i=e.documentElement,n=p(10)&&getComputedStyle(i);return{height:y("Height",t,i,n),width:y("Width",t,i,n)}}var x=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},C=function(){function e(e,t){for(var i=0;i2&&void 0!==arguments[2]&&arguments[2],n=p(10),o="HTML"===t.nodeName,s=k(e),a=k(t),r=d(e),c=l(t),u=parseFloat(c.borderTopWidth,10),h=parseFloat(c.borderLeftWidth,10);i&&o&&(a.top=Math.max(a.top,0),a.left=Math.max(a.left,0));var f=S({top:s.top-a.top-u,left:s.left-a.left-h,width:s.width,height:s.height});if(f.marginTop=0,f.marginLeft=0,!n&&o){var m=parseFloat(c.marginTop,10),g=parseFloat(c.marginLeft,10);f.top-=u-m,f.bottom-=u-m,f.left-=h-g,f.right-=h-g,f.marginTop=m,f.marginLeft=g}return(n&&!i?t.contains(r):t===r&&"BODY"!==r.nodeName)&&(f=function(e,t){var i=arguments.length>2&&void 0!==arguments[2]&&arguments[2],n=v(t,"top"),o=v(t,"left"),s=i?-1:1;return e.top+=n*s,e.bottom+=n*s,e.left+=o*s,e.right+=o*s,e}(f,t)),f}function _(e){if(!e||!e.parentElement||p())return document.documentElement;for(var t=e.parentElement;t&&"none"===l(t,"transform");)t=t.parentElement;return t||document.documentElement}function D(e,t,i,n){var o=arguments.length>4&&void 0!==arguments[4]&&arguments[4],s={top:0,left:0},a=o?_(e):g(e,t);if("viewport"===n)s=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],i=e.ownerDocument.documentElement,n=M(e,i),o=Math.max(i.clientWidth,window.innerWidth||0),s=Math.max(i.clientHeight,window.innerHeight||0),a=t?0:v(i),r=t?0:v(i,"left");return S({top:a-n.top+n.marginTop,left:r-n.left+n.marginLeft,width:o,height:s})}(a,o);else{var r=void 0;"scrollParent"===n?"BODY"===(r=d(c(t))).nodeName&&(r=e.ownerDocument.documentElement):r="window"===n?e.ownerDocument.documentElement:n;var u=M(r,a,o);if("HTML"!==r.nodeName||function e(t){var i=t.nodeName;if("BODY"===i||"HTML"===i)return!1;if("fixed"===l(t,"position"))return!0;var n=c(t);return!!n&&e(n)}(a))s=u;else{var h=w(e.ownerDocument),p=h.height,f=h.width;s.top+=u.top-u.marginTop,s.bottom=p+u.top,s.left+=u.left-u.marginLeft,s.right=f+u.left}}var m="number"==typeof(i=i||0);return s.left+=m?i:i.left||0,s.top+=m?i:i.top||0,s.right-=m?i:i.right||0,s.bottom-=m?i:i.bottom||0,s}function R(e,t,i,n,o){var s=arguments.length>5&&void 0!==arguments[5]?arguments[5]:0;if(-1===e.indexOf("auto"))return e;var a=D(i,n,s,o),r={top:{width:a.width,height:t.top-a.top},right:{width:a.right-t.right,height:a.height},bottom:{width:a.width,height:a.bottom-t.bottom},left:{width:t.left-a.left,height:a.height}},l=Object.keys(r).map(function(e){return T({key:e},r[e],{area:(t=r[e],t.width*t.height)});var t}).sort(function(e,t){return t.area-e.area}),c=l.filter(function(e){var t=e.width,n=e.height;return t>=i.clientWidth&&n>=i.clientHeight}),d=c.length>0?c[0].key:l[0].key,u=e.split("-")[1];return d+(u?"-"+u:"")}function L(e,t,i){var n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;return M(i,n?_(t):g(t,i),n)}function P(e){var t=e.ownerDocument.defaultView.getComputedStyle(e),i=parseFloat(t.marginTop||0)+parseFloat(t.marginBottom||0),n=parseFloat(t.marginLeft||0)+parseFloat(t.marginRight||0);return{width:e.offsetWidth+n,height:e.offsetHeight+i}}function A(e){var t={left:"right",right:"left",bottom:"top",top:"bottom"};return e.replace(/left|right|bottom|top/g,function(e){return t[e]})}function $(e,t,i){i=i.split("-")[0];var n=P(e),o={width:n.width,height:n.height},s=-1!==["right","left"].indexOf(i),a=s?"top":"left",r=s?"left":"top",l=s?"height":"width",c=s?"width":"height";return o[a]=t[a]+t[l]/2-n[l]/2,o[r]=i===r?t[r]-n[c]:t[A(r)],o}function I(e,t){return Array.prototype.find?e.find(t):e.filter(t)[0]}function z(e,t,i){return(void 0===i?e:e.slice(0,function(e,t,i){if(Array.prototype.findIndex)return e.findIndex(function(e){return e[t]===i});var n=I(e,function(e){return e[t]===i});return e.indexOf(n)}(e,"name",i))).forEach(function(e){e.function&&console.warn("`modifier.function` is deprecated, use `modifier.fn`!");var i=e.function||e.fn;e.enabled&&r(i)&&(t.offsets.popper=S(t.offsets.popper),t.offsets.reference=S(t.offsets.reference),t=i(t,e))}),t}function F(e,t){return e.some(function(e){var i=e.name;return e.enabled&&i===t})}function H(e){for(var t=[!1,"ms","Webkit","Moz","O"],i=e.charAt(0).toUpperCase()+e.slice(1),n=0;n1&&void 0!==arguments[1]&&arguments[1],i=Y.indexOf(e),n=Y.slice(i+1).concat(Y.slice(0,i));return t?n.reverse():n}var U={FLIP:"flip",CLOCKWISE:"clockwise",COUNTERCLOCKWISE:"counterclockwise"};function K(e,t,i,n){var o=[0,0],s=-1!==["right","left"].indexOf(n),a=e.split(/(\+|\-)/).map(function(e){return e.trim()}),r=a.indexOf(I(a,function(e){return-1!==e.search(/,|\s/)}));a[r]&&-1===a[r].indexOf(",")&&console.warn("Offsets separated by white space(s) are deprecated, use a comma (,) instead.");var l=/\s*,\s*|\s+/,c=-1!==r?[a.slice(0,r).concat([a[r].split(l)[0]]),[a[r].split(l)[1]].concat(a.slice(r+1))]:[a];return(c=c.map(function(e,n){var o=(1===n?!s:s)?"height":"width",a=!1;return e.reduce(function(e,t){return""===e[e.length-1]&&-1!==["+","-"].indexOf(t)?(e[e.length-1]=t,a=!0,e):a?(e[e.length-1]+=t,a=!1,e):e.concat(t)},[]).map(function(e){return function(e,t,i,n){var o=e.match(/((?:\-|\+)?\d*\.?\d*)(.*)/),s=+o[1],a=o[2];if(!s)return e;if(0===a.indexOf("%")){var r=void 0;switch(a){case"%p":r=i;break;case"%":case"%r":default:r=n}return S(r)[t]/100*s}if("vh"===a||"vw"===a)return("vh"===a?Math.max(document.documentElement.clientHeight,window.innerHeight||0):Math.max(document.documentElement.clientWidth,window.innerWidth||0))/100*s;return s}(e,o,t,i)})})).forEach(function(e,t){e.forEach(function(i,n){j(i)&&(o[t]+=i*("-"===e[n-1]?-1:1))})}),o}var J={placement:"bottom",positionFixed:!1,eventsEnabled:!0,removeOnDestroy:!1,onCreate:function(){},onUpdate:function(){},modifiers:{shift:{order:100,enabled:!0,fn:function(e){var t=e.placement,i=t.split("-")[0],n=t.split("-")[1];if(n){var o=e.offsets,s=o.reference,a=o.popper,r=-1!==["bottom","top"].indexOf(i),l=r?"left":"top",c=r?"width":"height",d={start:E({},l,s[l]),end:E({},l,s[l]+s[c]-a[c])};e.offsets.popper=T({},a,d[n])}return e}},offset:{order:200,enabled:!0,fn:function(e,t){var i=t.offset,n=e.placement,o=e.offsets,s=o.popper,a=o.reference,r=n.split("-")[0],l=void 0;return l=j(+i)?[+i,0]:K(i,s,a,r),"left"===r?(s.top+=l[0],s.left-=l[1]):"right"===r?(s.top+=l[0],s.left+=l[1]):"top"===r?(s.left+=l[0],s.top-=l[1]):"bottom"===r&&(s.left+=l[0],s.top+=l[1]),e.popper=s,e},offset:0},preventOverflow:{order:300,enabled:!0,fn:function(e,t){var i=t.boundariesElement||f(e.instance.popper);e.instance.reference===i&&(i=f(i));var n=H("transform"),o=e.instance.popper.style,s=o.top,a=o.left,r=o[n];o.top="",o.left="",o[n]="";var l=D(e.instance.popper,e.instance.reference,t.padding,i,e.positionFixed);o.top=s,o.left=a,o[n]=r,t.boundaries=l;var c=t.priority,d=e.offsets.popper,u={primary:function(e){var i=d[e];return d[e]l[e]&&!t.escapeWithReference&&(n=Math.min(d[i],l[e]-("right"===e?d.width:d.height))),E({},i,n)}};return c.forEach(function(e){var t=-1!==["left","top"].indexOf(e)?"primary":"secondary";d=T({},d,u[t](e))}),e.offsets.popper=d,e},priority:["left","right","top","bottom"],padding:5,boundariesElement:"scrollParent"},keepTogether:{order:400,enabled:!0,fn:function(e){var t=e.offsets,i=t.popper,n=t.reference,o=e.placement.split("-")[0],s=Math.floor,a=-1!==["top","bottom"].indexOf(o),r=a?"right":"bottom",l=a?"left":"top",c=a?"width":"height";return i[r]s(n[r])&&(e.offsets.popper[l]=s(n[r])),e}},arrow:{order:500,enabled:!0,fn:function(e,t){var i;if(!W(e.instance.modifiers,"arrow","keepTogether"))return e;var n=t.element;if("string"==typeof n){if(!(n=e.instance.popper.querySelector(n)))return e}else if(!e.instance.popper.contains(n))return console.warn("WARNING: `arrow.element` must be child of its popper element!"),e;var o=e.placement.split("-")[0],s=e.offsets,a=s.popper,r=s.reference,c=-1!==["left","right"].indexOf(o),d=c?"height":"width",u=c?"Top":"Left",h=u.toLowerCase(),p=c?"left":"top",f=c?"bottom":"right",m=P(n)[d];r[f]-ma[f]&&(e.offsets.popper[h]+=r[h]+m-a[f]),e.offsets.popper=S(e.offsets.popper);var g=r[h]+r[d]/2-m/2,v=l(e.instance.popper),b=parseFloat(v["margin"+u],10),y=parseFloat(v["border"+u+"Width"],10),w=g-e.offsets.popper[h]-b-y;return w=Math.max(Math.min(a[d]-m,w),0),e.arrowElement=n,e.offsets.arrow=(E(i={},h,Math.round(w)),E(i,p,""),i),e},element:"[x-arrow]"},flip:{order:600,enabled:!0,fn:function(e,t){if(F(e.instance.modifiers,"inner"))return e;if(e.flipped&&e.placement===e.originalPlacement)return e;var i=D(e.instance.popper,e.instance.reference,t.padding,t.boundariesElement,e.positionFixed),n=e.placement.split("-")[0],o=A(n),s=e.placement.split("-")[1]||"",a=[];switch(t.behavior){case U.FLIP:a=[n,o];break;case U.CLOCKWISE:a=X(n);break;case U.COUNTERCLOCKWISE:a=X(n,!0);break;default:a=t.behavior}return a.forEach(function(r,l){if(n!==r||a.length===l+1)return e;n=e.placement.split("-")[0],o=A(n);var c=e.offsets.popper,d=e.offsets.reference,u=Math.floor,h="left"===n&&u(c.right)>u(d.left)||"right"===n&&u(c.left)u(d.top)||"bottom"===n&&u(c.top)u(i.right),m=u(c.top)u(i.bottom),v="left"===n&&p||"right"===n&&f||"top"===n&&m||"bottom"===n&&g,b=-1!==["top","bottom"].indexOf(n),y=!!t.flipVariations&&(b&&"start"===s&&p||b&&"end"===s&&f||!b&&"start"===s&&m||!b&&"end"===s&&g);(h||v||y)&&(e.flipped=!0,(h||v)&&(n=a[l+1]),y&&(s=function(e){return"end"===e?"start":"start"===e?"end":e}(s)),e.placement=n+(s?"-"+s:""),e.offsets.popper=T({},e.offsets.popper,$(e.instance.popper,e.offsets.reference,e.placement)),e=z(e.instance.modifiers,e,"flip"))}),e},behavior:"flip",padding:5,boundariesElement:"viewport"},inner:{order:700,enabled:!1,fn:function(e){var t=e.placement,i=t.split("-")[0],n=e.offsets,o=n.popper,s=n.reference,a=-1!==["left","right"].indexOf(i),r=-1===["top","left"].indexOf(i);return o[a?"left":"top"]=s[i]-(r?o[a?"width":"height"]:0),e.placement=A(t),e.offsets.popper=S(o),e}},hide:{order:800,enabled:!0,fn:function(e){if(!W(e.instance.modifiers,"hide","preventOverflow"))return e;var t=e.offsets.reference,i=I(e.instance.modifiers,function(e){return"preventOverflow"===e.name}).boundaries;if(t.bottomi.right||t.top>i.bottom||t.right2&&void 0!==arguments[2]?arguments[2]:{};x(this,e),this.scheduleUpdate=function(){return requestAnimationFrame(n.update)},this.update=a(this.update.bind(this)),this.options=T({},e.Defaults,o),this.state={isDestroyed:!1,isCreated:!1,scrollParents:[]},this.reference=t&&t.jquery?t[0]:t,this.popper=i&&i.jquery?i[0]:i,this.options.modifiers={},Object.keys(T({},e.Defaults.modifiers,o.modifiers)).forEach(function(t){n.options.modifiers[t]=T({},e.Defaults.modifiers[t]||{},o.modifiers?o.modifiers[t]:{})}),this.modifiers=Object.keys(this.options.modifiers).map(function(e){return T({name:e},n.options.modifiers[e])}).sort(function(e,t){return e.order-t.order}),this.modifiers.forEach(function(e){e.enabled&&r(e.onLoad)&&e.onLoad(n.reference,n.popper,n.options,e,n.state)}),this.update();var s=this.options.eventsEnabled;s&&this.enableEventListeners(),this.state.eventsEnabled=s}return C(e,[{key:"update",value:function(){return function(){if(!this.state.isDestroyed){var e={instance:this,styles:{},arrowStyles:{},attributes:{},flipped:!1,offsets:{}};e.offsets.reference=L(this.state,this.popper,this.reference,this.options.positionFixed),e.placement=R(this.options.placement,e.offsets.reference,this.popper,this.reference,this.options.modifiers.flip.boundariesElement,this.options.modifiers.flip.padding),e.originalPlacement=e.placement,e.positionFixed=this.options.positionFixed,e.offsets.popper=$(this.popper,e.offsets.reference,e.placement),e.offsets.popper.position=this.options.positionFixed?"fixed":"absolute",e=z(this.modifiers,e),this.state.isCreated?this.options.onUpdate(e):(this.state.isCreated=!0,this.options.onCreate(e))}}.call(this)}},{key:"destroy",value:function(){return function(){return this.state.isDestroyed=!0,F(this.modifiers,"applyStyle")&&(this.popper.removeAttribute("x-placement"),this.popper.style.position="",this.popper.style.top="",this.popper.style.left="",this.popper.style.right="",this.popper.style.bottom="",this.popper.style.willChange="",this.popper.style[H("transform")]=""),this.disableEventListeners(),this.options.removeOnDestroy&&this.popper.parentNode.removeChild(this.popper),this}.call(this)}},{key:"enableEventListeners",value:function(){return function(){this.state.eventsEnabled||(this.state=N(this.reference,this.options,this.state,this.scheduleUpdate))}.call(this)}},{key:"disableEventListeners",value:function(){return B.call(this)}}]),e}();Q.Utils=("undefined"!=typeof window?window:e).PopperUtils,Q.placements=G,Q.Defaults=J,t.a=Q}).call(this,i(27))},39:function(t,n,o){var s,a;function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var l,c="function"==typeof Symbol&&"symbol"===r(Symbol.iterator)?function(e){return r(e)}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":r(e)};l=function(){"use strict";Array.prototype.findIndex||Object.defineProperty(Array.prototype,"findIndex",{value:function(e){if(null==this)throw new TypeError('"this" is null or not defined');var t=Object(this),i=t.length>>>0;if("function"!=typeof e)throw new TypeError("predicate must be a function");for(var n=arguments[1],o=0;o>>0;if("function"!=typeof e)throw new TypeError("predicate must be a function");for(var n=arguments[1],o=0;on?(i=e-n,this.element.style.marginLeft=-i+"px"):this.element.style.marginLeft=0,this.scrollLeft=e,this.table.modExists("frozenColumns")&&this.table.modules.frozenColumns.layout()},t.prototype.generateColumnsFromRowData=function(e){var t,i,n=[];if(e&&e.length){for(var o in t=e[0]){var s={field:o,title:o},a=t[o];switch(void 0===a?"undefined":c(a)){case"undefined":i="string";break;case"boolean":i="boolean";break;case"object":i=Array.isArray(a)?"array":"string";break;default:i=isNaN(a)||""===a?a.match(/((^[0-9]+[a-z]+)|(^[a-z]+[0-9]+))+$/i)?"alphanum":"string":"number"}s.sorter=i,n.push(s)}this.table.options.columns=n,this.setColumns(this.table.options.columns)}},t.prototype.setColumns=function(e,t){for(var i=this;i.headersElement.firstChild;)i.headersElement.removeChild(i.headersElement.firstChild);i.columns=[],i.columnsByIndex=[],i.columnsByField={},i.table.modExists("frozenColumns")&&i.table.modules.frozenColumns.reset(),e.forEach(function(e,t){i._addColumn(e)}),i._reIndexColumns(),i.table.options.responsiveLayout&&i.table.modExists("responsiveLayout",!0)&&i.table.modules.responsiveLayout.initialize(),i.redraw(!0)},t.prototype._addColumn=function(e,t,i){var n=new o(e,this),s=n.getElement(),a=i?this.findColumnIndex(i):i;if(i&&a>-1){var r=this.columns.indexOf(i.getTopColumn()),l=i.getElement();t?(this.columns.splice(r,0,n),l.parentNode.insertBefore(s,l)):(this.columns.splice(r+1,0,n),l.parentNode.insertBefore(s,l.nextSibling))}else t?(this.columns.unshift(n),this.headersElement.insertBefore(n.getElement(),this.headersElement.firstChild)):(this.columns.push(n),this.headersElement.appendChild(n.getElement()));return n},t.prototype.registerColumnField=function(e){e.definition.field&&(this.columnsByField[e.definition.field]=e)},t.prototype.registerColumnPosition=function(e){this.columnsByIndex.push(e)},t.prototype._reIndexColumns=function(){this.columnsByIndex=[],this.columns.forEach(function(e){e.reRegisterPosition()})},t.prototype._verticalAlignHeaders=function(){var e=this,t=0;e.columns.forEach(function(e){var i;e.clearVerticalAlign(),(i=e.getHeight())>t&&(t=i)}),e.columns.forEach(function(i){i.verticalAlign(e.table.options.columnVertAlign,t)}),e.rowManager.adjustTableSize()},t.prototype.findColumn=function(e){return"object"!=(void 0===e?"undefined":c(e))?this.columnsByField[e]||!1:e instanceof o?e:e instanceof n?e._getSelf()||!1:e instanceof HTMLElement&&this.columns.find(function(t){return t.element===e})||!1},t.prototype.getColumnByField=function(e){return this.columnsByField[e]},t.prototype.getColumnByIndex=function(e){return this.columnsByIndex[e]},t.prototype.getFirstVisibileColumn=function(e){return(e=this.columnsByIndex.findIndex(function(e){return e.visible}))>-1&&this.columnsByIndex[e]},t.prototype.getColumns=function(){return this.columns},t.prototype.findColumnIndex=function(e){return this.columnsByIndex.findIndex(function(t){return e===t})},t.prototype.getRealColumns=function(){return this.columnsByIndex},t.prototype.traverse=function(e){this.columnsByIndex.forEach(function(t,i){e(t,i)})},t.prototype.getDefinitions=function(e){var t=[];return this.columnsByIndex.forEach(function(i){(!e||e&&i.visible)&&t.push(i.getDefinition())}),t},t.prototype.getDefinitionTree=function(){var e=[];return this.columns.forEach(function(t){e.push(t.getDefinition(!0))}),e},t.prototype.getComponents=function(e){var t=[];return(e?this.columns:this.columnsByIndex).forEach(function(e){t.push(e.getComponent())}),t},t.prototype.getWidth=function(){var e=0;return this.columnsByIndex.forEach(function(t){t.visible&&(e+=t.getWidth())}),e},t.prototype.moveColumn=function(e,t,i){this._moveColumnInArray(this.columns,e,t,i),this._moveColumnInArray(this.columnsByIndex,e,t,i,!0),this.table.options.responsiveLayout&&this.table.modExists("responsiveLayout",!0)&&this.table.modules.responsiveLayout.initialize(),this.table.options.columnMoved&&this.table.options.columnMoved.call(this.table,e.getComponent(),this.table.columnManager.getComponents()),this.table.options.persistentLayout&&this.table.modExists("persistence",!0)&&this.table.modules.persistence.save("columns")},t.prototype._moveColumnInArray=function(e,t,i,n,o){var s,a=e.indexOf(t);a>-1&&(e.splice(a,1),(s=e.indexOf(i))>-1?n&&(s+=1):s=a,e.splice(s,0,t),o&&this.table.rowManager.rows.forEach(function(e){if(e.cells.length){var t=e.cells.splice(a,1)[0];e.cells.splice(s,0,t)}}))},t.prototype.scrollToColumn=function(e,t,i){var n=this,o=0,s=0,a=0,r=e.getElement();return new Promise(function(l,c){if(void 0===t&&(t=n.table.options.scrollToColumnPosition),void 0===i&&(i=n.table.options.scrollToColumnIfVisible),e.visible){switch(t){case"middle":case"center":a=-n.element.clientWidth/2;break;case"right":a=r.clientWidth-n.headersElement.clientWidth}if(!i&&(s=r.offsetLeft)>0&&s+r.offsetWidthe.rowManager.element.clientHeight&&(t-=e.rowManager.element.offsetWidth-e.rowManager.element.clientWidth),this.columnsByIndex.forEach(function(n){var o,s,a;n.visible&&(o=n.definition.width||0,s=void 0===n.minWidth?e.table.options.columnMinWidth:parseInt(n.minWidth),a="string"==typeof o?o.indexOf("%")>-1?t/100*parseInt(o):parseInt(o):o,i+=a>s?a:s)}),i},t.prototype.addColumn=function(e,t,i){var n=this._addColumn(e,t,i);this._reIndexColumns(),this.table.options.responsiveLayout&&this.table.modExists("responsiveLayout",!0)&&this.table.modules.responsiveLayout.initialize(),this.table.modExists("columnCalcs")&&this.table.modules.columnCalcs.recalc(this.table.rowManager.activeRows),this.redraw(),"fitColumns"!=this.table.modules.layout.getMode()&&n.reinitializeWidth(),this._verticalAlignHeaders(),this.table.rowManager.reinitialize()},t.prototype.deregisterColumn=function(e){var t,i=e.getField();i&&delete this.columnsByField[i],(t=this.columnsByIndex.indexOf(e))>-1&&this.columnsByIndex.splice(t,1),(t=this.columns.indexOf(e))>-1&&this.columns.splice(t,1),this.table.options.responsiveLayout&&this.table.modExists("responsiveLayout",!0)&&this.table.modules.responsiveLayout.initialize(),this.redraw()},t.prototype.redraw=function(e){e&&(h.prototype.helpers.elVisible(this.element)&&this._verticalAlignHeaders(),this.table.rowManager.resetScroll(),this.table.rowManager.reinitialize()),"fitColumns"==this.table.modules.layout.getMode()?this.table.modules.layout.layout():e?this.table.modules.layout.layout():this.table.options.responsiveLayout&&this.table.modExists("responsiveLayout",!0)&&this.table.modules.responsiveLayout.update(),this.table.modExists("frozenColumns")&&this.table.modules.frozenColumns.layout(),this.table.modExists("columnCalcs")&&this.table.modules.columnCalcs.recalc(this.table.rowManager.activeRows),e&&(this.table.options.persistentLayout&&this.table.modExists("persistence",!0)&&this.table.modules.persistence.save("columns"),this.table.modExists("columnCalcs")&&this.table.modules.columnCalcs.redraw()),this.table.footerManager.redraw()};var n=function(e){this._column=e,this.type="ColumnComponent"};n.prototype.getElement=function(){return this._column.getElement()},n.prototype.getDefinition=function(){return this._column.getDefinition()},n.prototype.getField=function(){return this._column.getField()},n.prototype.getCells=function(){var e=[];return this._column.cells.forEach(function(t){e.push(t.getComponent())}),e},n.prototype.getVisibility=function(){return this._column.visible},n.prototype.show=function(){this._column.isGroup?this._column.columns.forEach(function(e){e.show()}):this._column.show()},n.prototype.hide=function(){this._column.isGroup?this._column.columns.forEach(function(e){e.hide()}):this._column.hide()},n.prototype.toggle=function(){this._column.visible?this.hide():this.show()},n.prototype.delete=function(){this._column.delete()},n.prototype.getSubColumns=function(){var e=[];return this._column.columns.length&&this._column.columns.forEach(function(t){e.push(t.getComponent())}),e},n.prototype.getParentColumn=function(){return this._column.parent instanceof o&&this._column.parent.getComponent()},n.prototype._getSelf=function(){return this._column},n.prototype.scrollTo=function(){return this._column.table.columnManager.scrollToColumn(this._column)},n.prototype.getTable=function(){return this._column.table},n.prototype.headerFilterFocus=function(){this._column.table.modExists("filter",!0)&&this._column.table.modules.filter.setHeaderFilterFocus(this._column)},n.prototype.reloadHeaderFilter=function(){this._column.table.modExists("filter",!0)&&this._column.table.modules.filter.reloadHeaderFilter(this._column)},n.prototype.setHeaderFilterValue=function(e){this._column.table.modExists("filter",!0)&&this._column.table.modules.filter.setHeaderFilterValue(this._column,e)},n.prototype.getNextColumn=function(){return this._column.nextColumn().getComponent()},n.prototype.getPrevColumn=function(){return this._column.prevColumn().getComponent()};var o=function e(t,i){var n=this;this.table=i.table,this.definition=t,this.parent=i,this.type="column",this.columns=[],this.cells=[],this.element=this.createElement(),this.contentElement=!1,this.groupElement=this.createGroupElement(),this.isGroup=!1,this.tooltip=!1,this.hozAlign="",this.field="",this.fieldStructure="",this.getFieldValue="",this.setFieldValue="",this.setField(this.definition.field),this.modules={},this.cellEvents={cellClick:!1,cellDblClick:!1,cellContext:!1,cellTap:!1,cellDblTap:!1,cellTapHold:!1,cellMouseEnter:!1,cellMouseLeave:!1,cellMouseOver:!1,cellMouseOut:!1,cellMouseMove:!1},this.width=null,this.widthStyled="",this.minWidth=null,this.minWidthStyled="",this.widthFixed=!1,this.visible=!0,t.columns?(this.isGroup=!0,t.columns.forEach(function(t,i){var o=new e(t,n);n.attachColumn(o)}),n.checkColumnVisibility()):i.registerColumnField(this),t.rowHandle&&!1!==this.table.options.movableRows&&this.table.modExists("moveRow")&&this.table.modules.moveRow.setHandle(!0),this._buildHeader()};o.prototype.createElement=function(){var e=document.createElement("div");return e.classList.add("tabulator-col"),e.setAttribute("role","columnheader"),e.setAttribute("aria-sort","none"),e},o.prototype.createGroupElement=function(){var e=document.createElement("div");return e.classList.add("tabulator-col-group-cols"),e},o.prototype.setField=function(e){this.field=e,this.fieldStructure=e?this.table.options.nestedFieldSeparator?e.split(this.table.options.nestedFieldSeparator):[e]:[],this.getFieldValue=this.fieldStructure.length>1?this._getNestedData:this._getFlatData,this.setFieldValue=this.fieldStructure.length>1?this._setNesteData:this._setFlatData},o.prototype.registerColumnPosition=function(e){this.parent.registerColumnPosition(e)},o.prototype.registerColumnField=function(e){this.parent.registerColumnField(e)},o.prototype.reRegisterPosition=function(){this.isGroup?this.columns.forEach(function(e){e.reRegisterPosition()}):this.registerColumnPosition(this)},o.prototype.setTooltip=function(){var e=this,t=e.definition,i=t.headerTooltip||!1===t.tooltip?t.headerTooltip:e.table.options.tooltipsHeader;i?!0===i?t.field?e.table.modules.localize.bind("columns|"+t.field,function(i){e.element.setAttribute("title",i||t.title)}):e.element.setAttribute("title",t.title):("function"==typeof i&&!1===(i=i(e.getComponent()))&&(i=""),e.element.setAttribute("title",i)):e.element.setAttribute("title","")},o.prototype._buildHeader=function(){for(var e=this,t=e.definition;e.element.firstChild;)e.element.removeChild(e.element.firstChild);t.headerVertical&&(e.element.classList.add("tabulator-col-vertical"),"flip"===t.headerVertical&&e.element.classList.add("tabulator-col-vertical-flip")),e.contentElement=e._bindEvents(),e.contentElement=e._buildColumnHeaderContent(),e.element.appendChild(e.contentElement),e.isGroup?e._buildGroupHeader():e._buildColumnHeader(),e.setTooltip(),e.table.options.resizableColumns&&e.table.modExists("resizeColumns")&&e.table.modules.resizeColumns.initializeColumn("header",e,e.element),t.headerFilter&&e.table.modExists("filter")&&e.table.modExists("edit")&&(void 0!==t.headerFilterPlaceholder&&t.field&&e.table.modules.localize.setHeaderFilterColumnPlaceholder(t.field,t.headerFilterPlaceholder),e.table.modules.filter.initializeColumn(e)),e.table.modExists("frozenColumns")&&e.table.modules.frozenColumns.initializeColumn(e),e.table.options.movableColumns&&!e.isGroup&&e.table.modExists("moveColumn")&&e.table.modules.moveColumn.initializeColumn(e),(t.topCalc||t.bottomCalc)&&e.table.modExists("columnCalcs")&&e.table.modules.columnCalcs.initializeColumn(e),e.element.addEventListener("mouseenter",function(t){e.setTooltip()})},o.prototype._bindEvents=function(){var e,t,i,n=this,o=n.definition;"function"==typeof o.headerClick&&n.element.addEventListener("click",function(e){o.headerClick(e,n.getComponent())}),"function"==typeof o.headerDblClick&&n.element.addEventListener("dblclick",function(e){o.headerDblClick(e,n.getComponent())}),"function"==typeof o.headerContext&&n.element.addEventListener("contextmenu",function(e){o.headerContext(e,n.getComponent())}),"function"==typeof o.headerTap&&(i=!1,n.element.addEventListener("touchstart",function(e){i=!0}),n.element.addEventListener("touchend",function(e){i&&o.headerTap(e,n.getComponent()),i=!1})),"function"==typeof o.headerDblTap&&(e=null,n.element.addEventListener("touchend",function(t){e?(clearTimeout(e),e=null,o.headerDblTap(t,n.getComponent())):e=setTimeout(function(){clearTimeout(e),e=null},300)})),"function"==typeof o.headerTapHold&&(t=null,n.element.addEventListener("touchstart",function(e){clearTimeout(t),t=setTimeout(function(){clearTimeout(t),t=null,i=!1,o.headerTapHold(e,n.getComponent())},1e3)}),n.element.addEventListener("touchend",function(e){clearTimeout(t),t=null})),"function"==typeof o.cellClick&&(n.cellEvents.cellClick=o.cellClick),"function"==typeof o.cellDblClick&&(n.cellEvents.cellDblClick=o.cellDblClick),"function"==typeof o.cellContext&&(n.cellEvents.cellContext=o.cellContext),"function"==typeof o.cellMouseEnter&&(n.cellEvents.cellMouseEnter=o.cellMouseEnter),"function"==typeof o.cellMouseLeave&&(n.cellEvents.cellMouseLeave=o.cellMouseLeave),"function"==typeof o.cellMouseOver&&(n.cellEvents.cellMouseOver=o.cellMouseOver),"function"==typeof o.cellMouseOut&&(n.cellEvents.cellMouseOut=o.cellMouseOut),"function"==typeof o.cellMouseMove&&(n.cellEvents.cellMouseMove=o.cellMouseMove),"function"==typeof o.cellTap&&(n.cellEvents.cellTap=o.cellTap),"function"==typeof o.cellDblTap&&(n.cellEvents.cellDblTap=o.cellDblTap),"function"==typeof o.cellTapHold&&(n.cellEvents.cellTapHold=o.cellTapHold),"function"==typeof o.cellEdited&&(n.cellEvents.cellEdited=o.cellEdited),"function"==typeof o.cellEditing&&(n.cellEvents.cellEditing=o.cellEditing),"function"==typeof o.cellEditCancelled&&(n.cellEvents.cellEditCancelled=o.cellEditCancelled)},o.prototype._buildColumnHeader=function(){var e=this,t=e.definition,i=e.table;(i.modExists("sort")&&i.modules.sort.initializeColumn(e,e.contentElement),i.modExists("format")&&i.modules.format.initializeColumn(e),void 0!==t.editor&&i.modExists("edit")&&i.modules.edit.initializeColumn(e),void 0!==t.validator&&i.modExists("validate")&&i.modules.validate.initializeColumn(e),i.modExists("mutator")&&i.modules.mutator.initializeColumn(e),i.modExists("accessor")&&i.modules.accessor.initializeColumn(e),c(i.options.responsiveLayout)&&i.modExists("responsiveLayout")&&i.modules.responsiveLayout.initializeColumn(e),void 0!==t.visible&&(t.visible?e.show(!0):e.hide(!0)),t.cssClass)&&t.cssClass.split(" ").forEach(function(t){e.element.classList.add(t)});t.field&&this.element.setAttribute("tabulator-field",t.field),e.setMinWidth(void 0===t.minWidth?e.table.options.columnMinWidth:parseInt(t.minWidth)),e.reinitializeWidth(),e.tooltip=e.definition.tooltip||!1===e.definition.tooltip?e.definition.tooltip:e.table.options.tooltips,e.hozAlign=void 0===e.definition.align?"":e.definition.align},o.prototype._buildColumnHeaderContent=function(){this.definition,this.table;var e=document.createElement("div");return e.classList.add("tabulator-col-content"),e.appendChild(this._buildColumnHeaderTitle()),e},o.prototype._buildColumnHeaderTitle=function(){var e=this,t=e.definition,i=e.table,n=document.createElement("div");if(n.classList.add("tabulator-col-title"),t.editableTitle){var o=document.createElement("input");o.classList.add("tabulator-title-editor"),o.addEventListener("click",function(e){e.stopPropagation(),o.focus()}),o.addEventListener("change",function(){t.title=o.value,i.options.columnTitleChanged.call(e.table,e.getComponent())}),n.appendChild(o),t.field?i.modules.localize.bind("columns|"+t.field,function(e){o.value=e||t.title||" "}):o.value=t.title||" "}else t.field?i.modules.localize.bind("columns|"+t.field,function(i){e._formatColumnHeaderTitle(n,i||t.title||" ")}):e._formatColumnHeaderTitle(n,t.title||" ");return n},o.prototype._formatColumnHeaderTitle=function(e,t){var i,n,o,s;if(this.definition.titleFormatter&&this.table.modExists("format"))switch(i=this.table.modules.format.getFormatter(this.definition.titleFormatter),s={getValue:function(){return t},getElement:function(){return e}},o="function"==typeof(o=this.definition.titleFormatterParams||{})?o():o,void 0===(n=i.call(this.table.modules.format,s,o))?"undefined":c(n)){case"object":n instanceof Node?this.element.appendChild(n):(this.element.innerHTML="",console.warn("Format Error - Title formatter has returned a type of object, the only valid formatter object return is an instance of Node, the formatter returned:",n));break;case"undefined":case"null":this.element.innerHTML="";break;default:this.element.innerHTML=n}else e.innerHTML=t},o.prototype._buildGroupHeader=function(){this.element.classList.add("tabulator-col-group"),this.element.setAttribute("role","columngroup"),this.element.setAttribute("aria-title",this.definition.title),this.element.appendChild(this.groupElement)},o.prototype._getFlatData=function(e){return e[this.field]},o.prototype._getNestedData=function(e){for(var t,i=e,n=this.fieldStructure,o=n.length,s=0;s-1&&this.table.columnManager.getColumnByIndex(e+1)},o.prototype.prevColumn=function(){var e=this.table.columnManager.findColumnIndex(this);return e>-1&&this.table.columnManager.getColumnByIndex(e-1)},o.prototype.reinitializeWidth=function(e){this.widthFixed=!1,void 0===this.definition.width||e||this.setWidth(this.definition.width),this.table.modExists("filter")&&this.table.modules.filter.hideHeaderFilterElements(),this.fitToData(),this.table.modExists("filter")&&this.table.modules.filter.showHeaderFilterElements()},o.prototype.fitToData=function(){this.widthFixed||(this.element.style.width="",this.cells.forEach(function(e){e.clearWidth()}));var e=this.element.offsetWidth;this.width&&this.widthFixed||(this.cells.forEach(function(t){var i=t.getWidth();i>e&&(e=i)}),e&&this.setWidthActual(e+1))},o.prototype.deleteCell=function(e){var t=this.cells.indexOf(e);t>-1&&this.cells.splice(t,1)},o.prototype.defaultOptionList=["title","field","visible","align","width","minWidth","widthGrow","widthShrink","resizable","frozen","responsive","tooltip","cssClass","rowHandle","hideInHtml","sorter","sorterParams","formatter","formatterParams","variableHeight","editable","editor","editorParams","validator","mutator","mutatorParams","mutatorData","mutatorDataParams","mutatorEdit","mutatorEditParams","mutatorClipboard","mutatorClipboardParams","accessor","accessorParams","accessorData","accessorDataParams","accessorDownload","accessorDownloadParams","accessorClipboard","accessorClipboardParams","download","downloadTitle","topCalc","topCalcParams","topCalcFormatter","topCalcFormatterParams","bottomCalc","bottomCalcParams","bottomCalcFormatter","bottomCalcFormatterParams","cellClick","cellDblClick","cellContext","cellTap","cellDblTap","cellTapHold","cellMouseEnter","cellMouseLeave","cellMouseOver","cellMouseOut","cellMouseMove","cellEditing","cellEdited","cellEditCancelled","headerSort","headerSortStartingDir","headerSortTristate","headerClick","headerDblClick","headerContext","headerTap","headerDblTap","headerTapHold","headerTooltip","headerVertical","editableTitle","titleFormatter","titleFormatterParams","headerFilter","headerFilterPlaceholder","headerFilterParams","headerFilterEmptyCheck","headerFilterFunc","headerFilterFuncParams","headerFilterLiveFilter"],o.prototype.getComponent=function(){return new n(this)};var s=function(e){this.table=e,this.element=this.createHolderElement(),this.tableElement=this.createTableElement(),this.columnManager=null,this.height=0,this.firstRender=!1,this.renderMode="classic",this.rows=[],this.activeRows=[],this.activeRowsCount=0,this.displayRows=[],this.displayRowsCount=0,this.scrollTop=0,this.scrollLeft=0,this.vDomRowHeight=20,this.vDomTop=0,this.vDomBottom=0,this.vDomScrollPosTop=0,this.vDomScrollPosBottom=0,this.vDomTopPad=0,this.vDomBottomPad=0,this.vDomMaxRenderChain=90,this.vDomWindowBuffer=0,this.vDomWindowMinTotalRows=20,this.vDomWindowMinMarginRows=5,this.vDomTopNewRows=[],this.vDomBottomNewRows=[]};s.prototype.createHolderElement=function(){var e=document.createElement("div");return e.classList.add("tabulator-tableHolder"),e.setAttribute("tabindex",0),e},s.prototype.createTableElement=function(){var e=document.createElement("div");return e.classList.add("tabulator-table"),e},s.prototype.getElement=function(){return this.element},s.prototype.getTableElement=function(){return this.tableElement},s.prototype.getRowPosition=function(e,t){return t?this.activeRows.indexOf(e):this.rows.indexOf(e)},s.prototype.setColumnManager=function(e){this.columnManager=e},s.prototype.initialize=function(){var e=this;e.setRenderMode(),e.element.appendChild(e.tableElement),e.firstRender=!0,e.element.addEventListener("scroll",function(){var t=e.element.scrollLeft;e.scrollLeft!=t&&(e.columnManager.scrollHorizontal(t),e.table.options.groupBy&&e.table.modules.groupRows.scrollHeaders(t),e.table.modExists("columnCalcs")&&e.table.modules.columnCalcs.scrollHorizontal(t)),e.scrollLeft=t}),"virtual"===this.renderMode&&e.element.addEventListener("scroll",function(){var t=e.element.scrollTop,i=e.scrollTop>t;e.scrollTop!=t?(e.scrollTop=t,e.scrollVertical(i),"scroll"==e.table.options.ajaxProgressiveLoad&&e.table.modules.ajax.nextPage(e.element.scrollHeight-e.element.clientHeight-t)):e.scrollTop=t})},s.prototype.findRow=function(e){var t=this;return"object"!=(void 0===e?"undefined":c(e))?null!=e&&(t.rows.find(function(i){return i.data[t.table.options.index]==e})||!1):e instanceof r?e:e instanceof a?e._getSelf()||!1:e instanceof HTMLElement&&t.rows.find(function(t){return t.element===e})||!1},s.prototype.getRowFromDataObject=function(e){return this.rows.find(function(t){return t.data===e})||!1},s.prototype.getRowFromPosition=function(e,t){return t?this.activeRows[e]:this.rows[e]},s.prototype.scrollToRow=function(e,t,i){var n,o=this,s=this.getDisplayRows().indexOf(e),a=e.getElement(),r=0;return new Promise(function(e,l){if(s>-1){if(void 0===t&&(t=o.table.options.scrollToRowPosition),void 0===i&&(i=o.table.options.scrollToRowIfVisible),"nearest"===t)switch(o.renderMode){case"classic":n=h.prototype.helpers.elOffset(a).top,t=Math.abs(o.element.scrollTop-n)>Math.abs(o.element.scrollTop+o.element.clientHeight-n)?"bottom":"top";break;case"virtual":t=Math.abs(o.vDomTop-s)>Math.abs(o.vDomBottom-s)?"bottom":"top"}if(!i&&h.prototype.helpers.elVisible(a)&&(r=h.prototype.helpers.elOffset(a).top-h.prototype.helpers.elOffset(o.element).top)>0&&r-1&&this.activeRows.splice(n,1),i>-1&&this.rows.splice(i,1),this.setActiveRows(this.activeRows),this.displayRowIterator(function(t){var i=t.indexOf(e);i>-1&&t.splice(i,1)}),t||this.reRenderInPosition(),this.table.options.rowDeleted.call(this.table,e.getComponent()),this.table.options.dataEdited.call(this.table,this.getData()),this.table.options.groupBy&&this.table.modExists("groupRows")?this.table.modules.groupRows.updateGroupRows(!0):this.table.options.pagination&&this.table.modExists("page")?this.refreshActiveData(!1,!1,!0):this.table.options.pagination&&this.table.modExists("page")&&this.refreshActiveData("page")},s.prototype.addRow=function(e,t,i,n){var o=this.addRowActual(e,t,i,n);return this.table.options.history&&this.table.modExists("history")&&this.table.modules.history.action("rowAdd",o,{data:e,pos:t,index:i}),o},s.prototype.addRows=function(e,t,i){var n=this,o=this,s=[];return new Promise(function(a,r){t=n.findAddRowPos(t),Array.isArray(e)||(e=[e]),e.length-1,(void 0===i&&t||void 0!==i&&!t)&&e.reverse(),e.forEach(function(e,n){var a=o.addRow(e,t,i,!0);s.push(a)}),n.table.options.groupBy&&n.table.modExists("groupRows")?n.table.modules.groupRows.updateGroupRows(!0):n.table.options.pagination&&n.table.modExists("page")?n.refreshActiveData(!1,!1,!0):n.reRenderInPosition(),n.table.modExists("columnCalcs")&&n.table.modules.columnCalcs.recalc(n.table.rowManager.activeRows),a(s)})},s.prototype.findAddRowPos=function(e){return void 0===e&&(e=this.table.options.addRowPos),"pos"===e&&(e=!0),"bottom"===e&&(e=!1),e},s.prototype.addRowActual=function(e,t,i,n){var o,s=e instanceof r?e:new r(e||{},this),a=this.findAddRowPos(t);if(!i&&this.table.options.pagination&&"page"==this.table.options.paginationAddRow&&(o=this.getDisplayRows(),a?o.length?i=o[0]:this.activeRows.length&&(i=this.activeRows[this.activeRows.length-1],a=!1):o.length&&(i=o[o.length-1],a=!(o.length1&&(!i||i&&-1==l.indexOf(i)?a?l[0]!==s&&(i=l[0],this._moveRowInArray(s.getGroup().rows,s,i,a)):l[l.length-1]!==s&&(i=l[l.length-1],this._moveRowInArray(s.getGroup().rows,s,i,a)):this._moveRowInArray(s.getGroup().rows,s,i,a))}if(i){var c=this.rows.indexOf(i),d=this.activeRows.indexOf(i);this.displayRowIterator(function(e){var t=e.indexOf(i);t>-1&&e.splice(a?t:t+1,0,s)}),d>-1&&this.activeRows.splice(a?d:d+1,0,s),c>-1&&this.rows.splice(a?c:c+1,0,s)}else a?(this.displayRowIterator(function(e){e.unshift(s)}),this.activeRows.unshift(s),this.rows.unshift(s)):(this.displayRowIterator(function(e){e.push(s)}),this.activeRows.push(s),this.rows.push(s));return this.setActiveRows(this.activeRows),this.table.options.rowAdded.call(this.table,s.getComponent()),this.table.options.dataEdited.call(this.table,this.getData()),n||this.reRenderInPosition(),s},s.prototype.moveRow=function(e,t,i){this.table.options.history&&this.table.modExists("history")&&this.table.modules.history.action("rowMove",e,{pos:this.getRowPosition(e),to:t,after:i}),this.moveRowActual(e,t,i),this.table.options.rowMoved.call(this.table,e.getComponent())},s.prototype.moveRowActual=function(e,t,i){var n=this;if(this._moveRowInArray(this.rows,e,t,i),this._moveRowInArray(this.activeRows,e,t,i),this.displayRowIterator(function(o){n._moveRowInArray(o,e,t,i)}),this.table.options.groupBy&&this.table.modExists("groupRows")){var o=t.getGroup(),s=e.getGroup();o===s?this._moveRowInArray(o.rows,e,t,i):(s&&s.removeRow(e),o.insertRow(e,t,i))}},s.prototype._moveRowInArray=function(e,t,i,n){var o,s,a;if(t!==i&&((o=e.indexOf(t))>-1&&(e.splice(o,1),(s=e.indexOf(i))>-1?n?e.splice(s+1,0,t):e.splice(s,0,t):e.splice(o,0,t)),e===this.getDisplayRows())){a=s>o?s:o+1;for(var r=o-1&&t},s.prototype.nextDisplayRow=function(e,t){var i=this.getDisplayRowIndex(e),n=!1;return!1!==i&&i-1)&&i},s.prototype.getData=function(e,t){var i=[];return(e?this.activeRows:this.rows).forEach(function(e){i.push(e.getData(t||"data"))}),i},s.prototype.getHtml=function(e){var t=this.getData(e),i=[],n="",o="";return this.table.columnManager.getColumns().forEach(function(e){var t=e.getDefinition();e.visible&&!t.hideInHtml&&(n+=""+(t.title||"")+"",i.push(e))}),t.forEach(function(e){var t="";i.forEach(function(i){var n=i.getFieldValue(e);null==n&&(n=":"),t+=""+n+""}),o+=""+t+""}),"\n\n\t\t\t\n\n\t\t\t"+n+"\n\n\t\t\t\n\n\t\t\t"+o+"\n\n\t\t\t
"},s.prototype.getComponents=function(e){var t=[];return(e?this.activeRows:this.rows).forEach(function(e){t.push(e.getComponent())}),t},s.prototype.getDataCount=function(e){return e?this.rows.length:this.activeRows.length},s.prototype._genRemoteRequest=function(){var e=this,t=e.table,i=t.options,n={};if(t.modExists("page")){if(i.ajaxSorting){var o=e.table.modules.sort.getSort();o.forEach(function(e){delete e.column}),n[e.table.modules.page.paginationDataSentNames.sorters]=o}if(i.ajaxFiltering){var s=e.table.modules.filter.getFilters(!0,!0);n[e.table.modules.page.paginationDataSentNames.filters]=s}e.table.modules.ajax.setParams(n,!0)}t.modules.ajax.sendRequest().then(function(t){e.setData(t)}).catch(function(e){})},s.prototype.filterRefresh=function(){var e=this.table,t=e.options,i=this.scrollLeft;t.ajaxFiltering?"remote"==t.pagination&&e.modExists("page")?(e.modules.page.reset(!0),e.modules.page.setPage(1).then(function(){}).catch(function(){})):t.ajaxProgressiveLoad?e.modules.ajax.loadData().then(function(){}).catch(function(){}):this._genRemoteRequest():this.refreshActiveData("filter"),this.scrollHorizontal(i)},s.prototype.sorterRefresh=function(e){var t=this.table,i=this.table.options,n=this.scrollLeft;i.ajaxSorting?("remote"==i.pagination||i.progressiveLoad)&&t.modExists("page")?(t.modules.page.reset(!0),t.modules.page.setPage(1).then(function(){}).catch(function(){})):i.ajaxProgressiveLoad?t.modules.ajax.loadData().then(function(){}).catch(function(){}):this._genRemoteRequest():this.refreshActiveData(e?"filter":"sort"),this.scrollHorizontal(n)},s.prototype.scrollHorizontal=function(e){this.scrollLeft=e,this.element.scrollLeft=e,this.table.options.groupBy&&this.table.modules.groupRows.scrollHeaders(e),this.table.modExists("columnCalcs")&&this.table.modules.columnCalcs.scrollHorizontal(e)},s.prototype.refreshActiveData=function(e,t,i){var n,o=this.table;switch(this.table.modExists("edit")&&this.table.modules.edit.cancelEdit(),e||(e="all"),o.options.selectable&&!o.options.selectablePersistence&&o.modExists("selectRow")&&o.modules.selectRow.deselectRows(),e){case"all":case"filter":t?t=!1:o.modExists("filter")?this.setActiveRows(o.modules.filter.filter(this.rows)):this.setActiveRows(this.rows.slice(0));case"sort":t?t=!1:o.modExists("sort")&&o.modules.sort.sort(this.activeRows);case"display":this.resetDisplayRows();case"freeze":t?t=!1:this.table.modExists("frozenRows")&&o.modules.frozenRows.isFrozen()&&(o.modules.frozenRows.getDisplayIndex()||o.modules.frozenRows.setDisplayIndex(this.getNextDisplayIndex()),n=o.modules.frozenRows.getDisplayIndex(),!0!==(n=this.setDisplayRows(o.modules.frozenRows.getRows(this.getDisplayRows(n-1)),n))&&o.modules.frozenRows.setDisplayIndex(n));case"group":t?t=!1:o.options.groupBy&&o.modExists("groupRows")&&(o.modules.groupRows.getDisplayIndex()||o.modules.groupRows.setDisplayIndex(this.getNextDisplayIndex()),n=o.modules.groupRows.getDisplayIndex(),!0!==(n=this.setDisplayRows(o.modules.groupRows.getRows(this.getDisplayRows(n-1)),n))&&o.modules.groupRows.setDisplayIndex(n));case"tree":t?t=!1:o.options.dataTree&&o.modExists("dataTree")&&(o.modules.dataTree.getDisplayIndex()||o.modules.dataTree.setDisplayIndex(this.getNextDisplayIndex()),n=o.modules.dataTree.getDisplayIndex(),!0!==(n=this.setDisplayRows(o.modules.dataTree.getRows(this.getDisplayRows(n-1)),n))&&o.modules.dataTree.setDisplayIndex(n)),o.options.pagination&&o.modExists("page")&&!i&&"local"==o.modules.page.getMode()&&o.modules.page.reset();case"page":t?t=!1:o.options.pagination&&o.modExists("page")&&(o.modules.page.getDisplayIndex()||o.modules.page.setDisplayIndex(this.getNextDisplayIndex()),n=o.modules.page.getDisplayIndex(),"local"==o.modules.page.getMode()&&o.modules.page.setMaxRows(this.getDisplayRows(n-1).length),!0!==(n=this.setDisplayRows(o.modules.page.getRows(this.getDisplayRows(n-1)),n))&&o.modules.page.setDisplayIndex(n))}h.prototype.helpers.elVisible(this.element)&&(i?this.reRenderInPosition():(this.renderTable(),o.options.layoutColumnsOnNewData&&this.table.columnManager.redraw(!0))),o.modExists("columnCalcs")&&o.modules.columnCalcs.recalc(this.activeRows)},s.prototype.setActiveRows=function(e){this.activeRows=e,this.activeRowsCount=this.activeRows.length},s.prototype.resetDisplayRows=function(){this.displayRows=[],this.displayRows.push(this.activeRows.slice(0)),this.displayRowsCount=this.displayRows[0].length,this.table.modExists("frozenRows")&&this.table.modules.frozenRows.setDisplayIndex(0),this.table.options.groupBy&&this.table.modExists("groupRows")&&this.table.modules.groupRows.setDisplayIndex(0),this.table.options.pagination&&this.table.modExists("page")&&this.table.modules.page.setDisplayIndex(0)},s.prototype.getNextDisplayIndex=function(){return this.displayRows.length},s.prototype.setDisplayRows=function(e,t){var i=!0;return t&&void 0!==this.displayRows[t]?(this.displayRows[t]=e,i=!0):(this.displayRows.push(e),i=t=this.displayRows.length-1),t==this.displayRows.length-1&&(this.displayRowsCount=this.displayRows[this.displayRows.length-1].length),i},s.prototype.getDisplayRows=function(e){return void 0===e?this.displayRows.length?this.displayRows[this.displayRows.length-1]:[]:this.displayRows[e]||[]},s.prototype.displayRowIterator=function(e){this.displayRows.forEach(e),this.displayRowsCount=this.displayRows[this.displayRows.length-1].length},s.prototype.getRows=function(){return this.rows},s.prototype.reRenderInPosition=function(e){if("virtual"==this.getRenderMode()){for(var t=this.element.scrollTop,i=!1,n=!1,o=this.scrollLeft,s=this.getDisplayRows(),a=this.vDomTop;a<=this.vDomBottom;a++)if(s[a]){var r=t-s[a].getElement().offsetTop;if(!(!1===n||Math.abs(r)this.vDomWindowBuffer&&(this.vDomWindowBuffer=2*p),"group"!==m.type&&(c=!1),this.vDomBottom++,l++}e?(this.vDomTopPad=t?this.vDomRowHeight*this.vDomTop+i:this.scrollTop-r,this.vDomBottomPad=this.vDomBottom==this.displayRowsCount-1?0:Math.max(this.vDomScrollHeight-this.vDomTopPad-a-r,0)):(this.vDomTopPad=0,this.vDomRowHeight=Math.floor((a+r)/l),this.vDomBottomPad=this.vDomRowHeight*(this.displayRowsCount-this.vDomBottom-1),this.vDomScrollHeight=r+a+this.vDomBottomPad-this.height),n.style.paddingTop=this.vDomTopPad+"px",n.style.paddingBottom=this.vDomBottomPad+"px",t&&(this.scrollTop=this.vDomTopPad+r+i-(this.element.scrollWidth>this.element.clientWidth?this.element.offsetHeight-this.element.clientHeight:0)),this.scrollTop=Math.min(this.scrollTop,this.element.scrollHeight-this.height),this.element.scrollWidth>this.element.offsetWidth&&t&&(this.scrollTop+=this.element.offsetHeight-this.element.clientHeight),this.vDomScrollPosTop=this.scrollTop,this.vDomScrollPosBottom=this.scrollTop,o.scrollTop=this.scrollTop,n.style.minWidth=c?this.table.columnManager.getWidth()+"px":"",this.table.options.groupBy&&"fitDataFill"!=this.table.modules.layout.getMode()&&this.displayRowsCount==this.table.modules.groupRows.countGroups()&&(this.tableElement.style.minWidth=this.table.columnManager.getWidth())}else this.renderEmptyScroll()},s.prototype.scrollVertical=function(e){var t=this.scrollTop-this.vDomScrollPosTop,i=this.scrollTop-this.vDomScrollPosBottom,n=2*this.vDomWindowBuffer;if(-t>n||i>n){var o=this.scrollLeft;this._virtualRenderFill(Math.floor(this.element.scrollTop/this.element.scrollHeight*this.displayRowsCount)),this.scrollHorizontal(o)}else e?(t<0&&this._addTopRow(-t),i<0&&this.vDomScrollHeight-this.scrollTop>this.vDomWindowBuffer&&this._removeBottomRow(-i)):(t>=0&&this.scrollTop>this.vDomWindowBuffer&&this._removeTopRow(t),i>=0&&this._addBottomRow(i))},s.prototype._addTopRow=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=this.tableElement,n=this.getDisplayRows();if(this.vDomTop){var o=this.vDomTop-1,s=n[o],a=s.getHeight()||this.vDomRowHeight;e>=a&&(this.styleRow(s,o),i.insertBefore(s.getElement(),i.firstChild),s.initialized&&s.heightInitialized||(this.vDomTopNewRows.push(s),s.heightInitialized||s.clearCellHeight()),s.initialize(),this.vDomTopPad-=a,this.vDomTopPad<0&&(this.vDomTopPad=o*this.vDomRowHeight),o||(this.vDomTopPad=0),i.style.paddingTop=this.vDomTopPad+"px",this.vDomScrollPosTop-=a,this.vDomTop--),e=-(this.scrollTop-this.vDomScrollPosTop),s.getHeight()>this.vDomWindowBuffer&&(this.vDomWindowBuffer=2*s.getHeight()),t=(n[this.vDomTop-1].getHeight()||this.vDomRowHeight)?this._addTopRow(e,t+1):this._quickNormalizeRowHeight(this.vDomTopNewRows)}},s.prototype._removeTopRow=function(e){var t=this.tableElement,i=this.getDisplayRows()[this.vDomTop],n=i.getHeight()||this.vDomRowHeight;if(e>=n){var o=i.getElement();o.parentNode.removeChild(o),this.vDomTopPad+=n,t.style.paddingTop=this.vDomTopPad+"px",this.vDomScrollPosTop+=this.vDomTop?n:n+this.vDomWindowBuffer,this.vDomTop++,e=this.scrollTop-this.vDomScrollPosTop,this._removeTopRow(e)}},s.prototype._addBottomRow=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=this.tableElement,n=this.getDisplayRows();if(this.vDomBottom=a&&(this.styleRow(s,o),i.appendChild(s.getElement()),s.initialized&&s.heightInitialized||(this.vDomBottomNewRows.push(s),s.heightInitialized||s.clearCellHeight()),s.initialize(),this.vDomBottomPad-=a,(this.vDomBottomPad<0||o==this.displayRowsCount-1)&&(this.vDomBottomPad=0),i.style.paddingBottom=this.vDomBottomPad+"px",this.vDomScrollPosBottom+=a,this.vDomBottom++),e=this.scrollTop-this.vDomScrollPosBottom,s.getHeight()>this.vDomWindowBuffer&&(this.vDomWindowBuffer=2*s.getHeight()),t=(n[this.vDomBottom+1].getHeight()||this.vDomRowHeight)?this._addBottomRow(e,t+1):this._quickNormalizeRowHeight(this.vDomBottomNewRows)}},s.prototype._removeBottomRow=function(e){var t=this.tableElement,i=this.getDisplayRows()[this.vDomBottom],n=i.getHeight()||this.vDomRowHeight;if(e>=n){var o=i.getElement();o.parentNode&&o.parentNode.removeChild(o),this.vDomBottomPad+=n,this.vDomBottomPad<0&&(this.vDomBottomPad=0),t.style.paddingBottom=this.vDomBottomPad+"px",this.vDomScrollPosBottom-=n,this.vDomBottom--,e=-(this.scrollTop-this.vDomScrollPosBottom),this._removeBottomRow(e)}},s.prototype._quickNormalizeRowHeight=function(e){e.forEach(function(e){e.calcHeight()}),e.forEach(function(e){e.setCellHeight()}),e.length=0},s.prototype.normalizeHeight=function(){this.activeRows.forEach(function(e){e.normalizeHeight()})},s.prototype.adjustTableSize=function(){if("virtual"===this.renderMode){this.height=this.element.clientHeight,this.vDomWindowBuffer=this.table.options.virtualDomBuffer||this.height;var e=this.columnManager.getElement().offsetHeight+(this.table.footerManager&&!this.table.footerManager.external?this.table.footerManager.getElement().offsetHeight:0);this.element.style.minHeight="calc(100% - "+e+"px)",this.element.style.height="calc(100% - "+e+"px)",this.element.style.maxHeight="calc(100% - "+e+"px)"}},s.prototype.reinitialize=function(){this.rows.forEach(function(e){e.reinitialize()})},s.prototype.redraw=function(e){var t=this.scrollLeft;this.adjustTableSize(),e?this.renderTable():("classic"==self.renderMode?self.table.options.groupBy?self.refreshActiveData("group",!1,!1):this._simpleRender():(this.reRenderInPosition(),this.scrollHorizontal(t)),this.displayRowsCount||this.table.options.placeholder&&this.getElement().appendChild(this.table.options.placeholder))},s.prototype.resetScroll=function(){if(this.element.scrollLeft=0,this.element.scrollTop=0,"ie"===this.table.browser){var e=document.createEvent("Event");e.initEvent("scroll",!1,!0),this.element.dispatchEvent(e)}else this.element.dispatchEvent(new Event("scroll"))};var a=function(e){this._row=e};a.prototype.getData=function(e){return this._row.getData(e)},a.prototype.getElement=function(){return this._row.getElement()},a.prototype.getCells=function(){var e=[];return this._row.getCells().forEach(function(t){e.push(t.getComponent())}),e},a.prototype.getCell=function(e){var t=this._row.getCell(e);return!!t&&t.getComponent()},a.prototype.getIndex=function(){return this._row.getData("data")[this._row.table.options.index]},a.prototype.getPosition=function(e){return this._row.table.rowManager.getRowPosition(this._row,e)},a.prototype.delete=function(){return this._row.delete()},a.prototype.scrollTo=function(){return this._row.table.rowManager.scrollToRow(this._row)},a.prototype.pageTo=function(){if(this._row.table.modExists("page",!0))return this._row.table.modules.page.setPageToRow(this._row)},a.prototype.move=function(e,t){this._row.moveToRow(e,t)},a.prototype.update=function(e){return this._row.updateData(e)},a.prototype.normalizeHeight=function(){this._row.normalizeHeight(!0)},a.prototype.select=function(){this._row.table.modules.selectRow.selectRows(this._row)},a.prototype.deselect=function(){this._row.table.modules.selectRow.deselectRows(this._row)},a.prototype.toggleSelect=function(){this._row.table.modules.selectRow.toggleRow(this._row)},a.prototype.isSelected=function(){return this._row.table.modules.selectRow.isRowSelected(this._row)},a.prototype._getSelf=function(){return this._row},a.prototype.freeze=function(){this._row.table.modExists("frozenRows",!0)&&this._row.table.modules.frozenRows.freezeRow(this._row)},a.prototype.unfreeze=function(){this._row.table.modExists("frozenRows",!0)&&this._row.table.modules.frozenRows.unfreezeRow(this._row)},a.prototype.treeCollapse=function(){this._row.table.modExists("dataTree",!0)&&this._row.table.modules.dataTree.collapseRow(this._row)},a.prototype.treeExpand=function(){this._row.table.modExists("dataTree",!0)&&this._row.table.modules.dataTree.expandRow(this._row)},a.prototype.treeToggle=function(){this._row.table.modExists("dataTree",!0)&&this._row.table.modules.dataTree.toggleRow(this._row)},a.prototype.getTreeParent=function(){return!!this._row.table.modExists("dataTree",!0)&&this._row.table.modules.dataTree.getTreeParent(this._row)},a.prototype.getTreeChildren=function(){return!!this._row.table.modExists("dataTree",!0)&&this._row.table.modules.dataTree.getTreeChildren(this._row)},a.prototype.reformat=function(){return this._row.reinitialize()},a.prototype.getGroup=function(){return this._row.getGroup().getComponent()},a.prototype.getTable=function(){return this._row.table},a.prototype.getNextRow=function(){var e=this._row.nextRow();return e?e.getComponent():e},a.prototype.getPrevRow=function(){var e=this._row.prevRow();return e?e.getComponent():e};var r=function(e,t){this.table=t.table,this.parent=t,this.data={},this.type="row",this.element=this.createElement(),this.modules={},this.cells=[],this.height=0,this.heightStyled="",this.manualHeight=!1,this.outerHeight=0,this.initialized=!1,this.heightInitialized=!1,this.setData(e),this.generateElement()};r.prototype.createElement=function(){var e=document.createElement("div");return e.classList.add("tabulator-row"),e.setAttribute("role","row"),e},r.prototype.getElement=function(){return this.element},r.prototype.detachElement=function(){this.element&&this.element.parentNode&&this.element.parentNode.removeChild(this.element)},r.prototype.generateElement=function(){var e,t,i,n=this;!1!==n.table.options.selectable&&n.table.modExists("selectRow")&&n.table.modules.selectRow.initializeRow(this),!1!==n.table.options.movableRows&&n.table.modExists("moveRow")&&n.table.modules.moveRow.initializeRow(this),!1!==n.table.options.dataTree&&n.table.modExists("dataTree")&&n.table.modules.dataTree.initializeRow(this),n.table.options.rowClick&&n.element.addEventListener("click",function(e){n.table.options.rowClick(e,n.getComponent())}),n.table.options.rowDblClick&&n.element.addEventListener("dblclick",function(e){n.table.options.rowDblClick(e,n.getComponent())}),n.table.options.rowContext&&n.element.addEventListener("contextmenu",function(e){n.table.options.rowContext(e,n.getComponent())}),n.table.options.rowMouseEnter&&n.element.addEventListener("mouseenter",function(e){n.table.options.rowMouseEnter(e,n.getComponent())}),n.table.options.rowMouseLeave&&n.element.addEventListener("mouseleave",function(e){n.table.options.rowMouseLeave(e,n.getComponent())}),n.table.options.rowMouseOver&&n.element.addEventListener("mouseover",function(e){n.table.options.rowMouseOver(e,n.getComponent())}),n.table.options.rowMouseOut&&n.element.addEventListener("mouseout",function(e){n.table.options.rowMouseOut(e,n.getComponent())}),n.table.options.rowMouseMove&&n.element.addEventListener("mousemove",function(e){n.table.options.rowMouseMove(e,n.getComponent())}),n.table.options.rowTap&&(i=!1,n.element.addEventListener("touchstart",function(e){i=!0}),n.element.addEventListener("touchend",function(e){i&&n.table.options.rowTap(e,n.getComponent()),i=!1})),n.table.options.rowDblTap&&(e=null,n.element.addEventListener("touchend",function(t){e?(clearTimeout(e),e=null,n.table.options.rowDblTap(t,n.getComponent())):e=setTimeout(function(){clearTimeout(e),e=null},300)})),n.table.options.rowTapHold&&(t=null,n.element.addEventListener("touchstart",function(e){clearTimeout(t),t=setTimeout(function(){clearTimeout(t),t=null,i=!1,n.table.options.rowTapHold(e,n.getComponent())},1e3)}),n.element.addEventListener("touchend",function(e){clearTimeout(t),t=null}))},r.prototype.generateCells=function(){this.cells=this.table.columnManager.generateCells(this)},r.prototype.initialize=function(e){var t=this;if(!t.initialized||e){for(t.deleteCells();t.element.firstChild;)t.element.removeChild(t.element.firstChild);this.table.modExists("frozenColumns")&&this.table.modules.frozenColumns.layoutRow(this),this.generateCells(),t.cells.forEach(function(e){t.element.appendChild(e.getElement()),e.cellRendered()}),e&&t.normalizeHeight(),t.table.options.dataTree&&t.table.modExists("dataTree")&&t.table.modules.dataTree.layoutRow(this),"collapse"===t.table.options.responsiveLayout&&t.table.modExists("responsiveLayout")&&t.table.modules.responsiveLayout.layoutRow(this),t.table.options.rowFormatter&&t.table.options.rowFormatter(t.getComponent()),t.table.options.resizableRows&&t.table.modExists("resizeRows")&&t.table.modules.resizeRows.initializeRow(t),t.initialized=!0}},r.prototype.reinitializeHeight=function(){this.heightInitialized=!1,null!==this.element.offsetParent&&this.normalizeHeight(!0)},r.prototype.reinitialize=function(){this.initialized=!1,this.heightInitialized=!1,this.manualHeight||(this.height=0,this.heightStyled=""),null!==this.element.offsetParent&&this.initialize(!0)},r.prototype.calcHeight=function(e){var t=0,i=this.table.options.resizableRows?this.element.clientHeight:0;this.cells.forEach(function(e){var i=e.getHeight();i>t&&(t=i)}),this.height=e?Math.max(t,i):this.manualHeight?this.height:Math.max(t,i),this.heightStyled=this.height?this.height+"px":"",this.outerHeight=this.element.offsetHeight},r.prototype.setCellHeight=function(){this.cells.forEach(function(e){e.setHeight()}),this.heightInitialized=!0},r.prototype.clearCellHeight=function(){this.cells.forEach(function(e){e.clearHeight()})},r.prototype.normalizeHeight=function(e){e&&this.clearCellHeight(),this.calcHeight(e),this.setCellHeight()},r.prototype.setHeight=function(e,t){(this.height!=e||t)&&(this.manualHeight=!0,this.height=e,this.heightStyled=e?e+"px":"",this.setCellHeight(),this.outerHeight=this.element.offsetHeight)},r.prototype.getHeight=function(){return this.outerHeight},r.prototype.getWidth=function(){return this.element.offsetWidth},r.prototype.deleteCell=function(e){var t=this.cells.indexOf(e);t>-1&&this.cells.splice(t,1)},r.prototype.setData=function(e){this.table.modExists("mutator")&&(e=this.table.modules.mutator.transformRow(e,"data")),this.data=e,this.table.options.reactiveData&&this.table.modExists("reactiveData",!0)&&this.table.modules.reactiveData.watchRow(this)},r.prototype.updateData=function(e){var t=this,i=this,n=h.prototype.helpers.elVisible(this.element);return new Promise(function(o,s){for(var a in"string"==typeof e&&(e=JSON.parse(e)),t.table.options.reactiveData&&t.table.modExists("reactiveData",!0)&&t.table.modules.reactiveData.block(),i.table.modExists("mutator")&&(e=i.table.modules.mutator.transformRow(e,"data",!0)),e)i.data[a]=e[a];for(var a in t.table.options.reactiveData&&t.table.modExists("reactiveData",!0)&&t.table.modules.reactiveData.unblock(),e){var r=t.getCell(a);r&&r.getValue()!=e[a]&&(r.setValueProcessData(e[a]),n&&r.cellRendered())}n?(i.normalizeHeight(),i.table.options.rowFormatter&&i.table.options.rowFormatter(i.getComponent())):(t.initialized=!1,t.height=0,t.heightStyled=""),!1!==i.table.options.dataTree&&i.table.modExists("dataTree")&&void 0!==e[t.table.modules.dataTree.getChildField()]&&(t.table.modules.dataTree.initializeRow(t),t.table.rowManager.refreshActiveData("tree",!1,!0)),i.table.options.rowUpdated.call(t.table,i.getComponent()),o()})},r.prototype.getData=function(e){return e?this.table.modExists("accessor")?this.table.modules.accessor.transformRow(this.data,e):void 0:this.data},r.prototype.getCell=function(e){return e=this.table.columnManager.findColumn(e),this.cells.find(function(t){return t.column===e})},r.prototype.getCellIndex=function(e){return this.cells.findIndex(function(t){return t===e})},r.prototype.findNextEditableCell=function(e){var t=!1;if(e0)for(var i=e-1;i>=0;i--){var n=this.cells[i],o=!0;if(n.column.modules.edit&&h.prototype.helpers.elVisible(n.getElement())&&("function"==typeof n.column.modules.edit.check&&(o=n.column.modules.edit.check(n.getComponent())),o)){t=n;break}}return t},r.prototype.getCells=function(){return this.cells},r.prototype.nextRow=function(){return this.table.rowManager.nextDisplayRow(this,!0)||!1},r.prototype.prevRow=function(){return this.table.rowManager.prevDisplayRow(this,!0)||!1},r.prototype.moveToRow=function(e,t){var i=this.table.rowManager.findRow(e);i?(this.table.rowManager.moveRowActual(this,i,!t),this.table.rowManager.refreshActiveData("display",!1,!0)):console.warn("Move Error - No matching row found:",e)},r.prototype.delete=function(){var e=this;return new Promise(function(t,i){var n=e.table.rowManager.getRowIndex(e);e.deleteActual(),e.table.options.history&&e.table.modExists("history")&&(n&&(n=e.table.rowManager.rows[n-1]),e.table.modules.history.action("rowDelete",e,{data:e.getData(),pos:!n,index:n})),t()})},r.prototype.deleteActual=function(e){this.table.rowManager.getRowIndex(this);this.table.modExists("selectRow")&&this.table.modules.selectRow._deselectRow(this,!0),this.table.options.reactiveData&&this.table.modExists("reactiveData",!0)&&this.table.modules.reactiveData.unwatchRow(this),this.table.rowManager.deleteRow(this,e),this.deleteCells(),this.initialized=!1,this.heightInitialized=!1,this.modules.group&&this.modules.group.removeRow(this),this.table.modExists("columnCalcs")&&(this.table.options.groupBy&&this.table.modExists("groupRows")?this.table.modules.columnCalcs.recalcRowGroup(this):this.table.modules.columnCalcs.recalc(this.table.rowManager.activeRows))},r.prototype.deleteCells=function(){for(var e=this.cells.length,t=0;t-1?(this.browser="ie",this.browserSlow=!0):e.indexOf("Edge")>-1?(this.browser="edge",this.browserSlow=!0):e.indexOf("Firefox")>-1?(this.browser="firefox",this.browserSlow=!1):(this.browser="other",this.browserSlow=!1)},h.prototype.setDataFromLocalFile=function(e){var t=this;return new Promise(function(i,n){var o=document.createElement("input");o.type="file",o.accept=e||".json,application/json",o.addEventListener("change",function(e){var s,a=o.files[0],r=new FileReader;r.readAsText(a),r.onload=function(e){try{s=JSON.parse(r.result)}catch(e){return console.warn("File Load Error - File contents is invalid JSON",e),void n(e)}t._setData(s).then(function(e){i(e)}).catch(function(e){i(e)})},r.onerror=function(e){console.warn("File Load Error - Unable to read file"),n()}}),o.click()})},h.prototype.setData=function(e,t,i){return this.modExists("ajax")&&this.modules.ajax.blockActiveRequest(),this._setData(e,t,i)},h.prototype._setData=function(e,t,i,n){return"string"!=typeof e?e?this.rowManager.setData(e,n):this.modExists("ajax")&&(this.modules.ajax.getUrl||this.options.ajaxURLGenerator)?"remote"==this.options.pagination&&this.modExists("page",!0)?(this.modules.page.reset(!0),this.modules.page.setPage(1)):this.modules.ajax.loadData(n):this.rowManager.setData([],n):0==e.indexOf("{")||0==e.indexOf("[")?this.rowManager.setData(JSON.parse(e),n):this.modExists("ajax",!0)?(t&&this.modules.ajax.setParams(t),i&&this.modules.ajax.setConfig(i),this.modules.ajax.setUrl(e),"remote"==this.options.pagination&&this.modExists("page",!0)?(this.modules.page.reset(!0),this.modules.page.setPage(1)):this.modules.ajax.loadData(n)):void 0},h.prototype.clearData=function(){this.modExists("ajax")&&this.modules.ajax.blockActiveRequest(),this.rowManager.clearData()},h.prototype.getData=function(e){return this.rowManager.getData(e)},h.prototype.getDataCount=function(e){return this.rowManager.getDataCount(e)},h.prototype.searchRows=function(e,t,i){if(this.modExists("filter",!0))return this.modules.filter.search("rows",e,t,i)},h.prototype.searchData=function(e,t,i){if(this.modExists("filter",!0))return this.modules.filter.search("data",e,t,i)},h.prototype.getHtml=function(e){return this.rowManager.getHtml(e)},h.prototype.getAjaxUrl=function(){if(this.modExists("ajax",!0))return this.modules.ajax.getUrl()},h.prototype.replaceData=function(e,t,i){return this.modExists("ajax")&&this.modules.ajax.blockActiveRequest(),this._setData(e,t,i,!0)},h.prototype.updateData=function(e){var t=this,i=this,n=0;return new Promise(function(o,s){t.modExists("ajax")&&t.modules.ajax.blockActiveRequest(),"string"==typeof e&&(e=JSON.parse(e)),e?e.forEach(function(e){var t=i.rowManager.findRow(e[i.options.index]);t&&(n++,t.updateData(e).then(function(){--n||o()}))}):(console.warn("Update Error - No data provided"),s("Update Error - No data provided"))})},h.prototype.addData=function(e,t,i){var n=this;return new Promise(function(o,s){n.modExists("ajax")&&n.modules.ajax.blockActiveRequest(),"string"==typeof e&&(e=JSON.parse(e)),e?n.rowManager.addRows(e,t,i).then(function(e){var t=[];e.forEach(function(e){t.push(e.getComponent())}),o(t)}):(console.warn("Update Error - No data provided"),s("Update Error - No data provided"))})},h.prototype.updateOrAddData=function(e){var t=this,i=this,n=[],o=0;return new Promise(function(s,a){t.modExists("ajax")&&t.modules.ajax.blockActiveRequest(),"string"==typeof e&&(e=JSON.parse(e)),e?e.forEach(function(e){var t=i.rowManager.findRow(e[i.options.index]);o++,t?t.updateData(e).then(function(){o--,n.push(t.getComponent()),o||s(n)}):i.rowManager.addRows(e).then(function(e){o--,n.push(e[0].getComponent()),o||s(n)})}):(console.warn("Update Error - No data provided"),a("Update Error - No data provided"))})},h.prototype.getRow=function(e){var t=this.rowManager.findRow(e);return t?t.getComponent():(console.warn("Find Error - No matching row found:",e),!1)},h.prototype.getRowFromPosition=function(e,t){var i=this.rowManager.getRowFromPosition(e,t);return i?i.getComponent():(console.warn("Find Error - No matching row found:",e),!1)},h.prototype.deleteRow=function(e){var t=this;return new Promise(function(i,n){var o=t.rowManager.findRow(e);o?o.delete().then(function(){i()}).catch(function(e){n(e)}):(console.warn("Delete Error - No matching row found:",e),n("Delete Error - No matching row found"))})},h.prototype.addRow=function(e,t,i){var n=this;return new Promise(function(o,s){"string"==typeof e&&(e=JSON.parse(e)),n.rowManager.addRows(e,t,i).then(function(e){n.modExists("columnCalcs")&&n.modules.columnCalcs.recalc(n.rowManager.activeRows),o(e[0].getComponent())})})},h.prototype.updateOrAddRow=function(e,t){var i=this;return new Promise(function(n,o){var s=i.rowManager.findRow(e);"string"==typeof t&&(t=JSON.parse(t)),s?s.updateData(t).then(function(){i.modExists("columnCalcs")&&i.modules.columnCalcs.recalc(i.rowManager.activeRows),n(s.getComponent())}).catch(function(e){o(e)}):s=i.rowManager.addRows(t).then(function(e){i.modExists("columnCalcs")&&i.modules.columnCalcs.recalc(i.rowManager.activeRows),n(e[0].getComponent())}).catch(function(e){o(e)})})},h.prototype.updateRow=function(e,t){var i=this;return new Promise(function(n,o){var s=i.rowManager.findRow(e);"string"==typeof t&&(t=JSON.parse(t)),s?s.updateData(t).then(function(){n(s.getComponent())}).catch(function(e){o(e)}):(console.warn("Update Error - No matching row found:",e),o("Update Error - No matching row found"))})},h.prototype.scrollToRow=function(e,t,i){var n=this;return new Promise(function(o,s){var a=n.rowManager.findRow(e);a?n.rowManager.scrollToRow(a,t,i).then(function(){o()}).catch(function(e){s(e)}):(console.warn("Scroll Error - No matching row found:",e),s("Scroll Error - No matching row found"))})},h.prototype.moveRow=function(e,t,i){var n=this.rowManager.findRow(e);n?n.moveToRow(t,i):console.warn("Move Error - No matching row found:",e)},h.prototype.getRows=function(e){return this.rowManager.getComponents(e)},h.prototype.getRowPosition=function(e,t){var i=this.rowManager.findRow(e);return i?this.rowManager.getRowPosition(i,t):(console.warn("Position Error - No matching row found:",e),!1)},h.prototype.copyToClipboard=function(e,t,i,n){this.modExists("clipboard",!0)&&this.modules.clipboard.copy(e,t,i,n)},h.prototype.setColumns=function(e){this.columnManager.setColumns(e)},h.prototype.getColumns=function(e){return this.columnManager.getComponents(e)},h.prototype.getColumn=function(e){var t=this.columnManager.findColumn(e);return t?t.getComponent():(console.warn("Find Error - No matching column found:",e),!1)},h.prototype.getColumnDefinitions=function(){return this.columnManager.getDefinitionTree()},h.prototype.getColumnLayout=function(){if(this.modExists("persistence",!0))return this.modules.persistence.parseColumns(this.columnManager.getColumns())},h.prototype.setColumnLayout=function(e){return!!this.modExists("persistence",!0)&&(this.columnManager.setColumns(this.modules.persistence.mergeDefinition(this.options.columns,e)),!0)},h.prototype.showColumn=function(e){var t=this.columnManager.findColumn(e);if(!t)return console.warn("Column Show Error - No matching column found:",e),!1;t.show(),this.options.responsiveLayout&&this.modExists("responsiveLayout",!0)&&this.modules.responsiveLayout.update()},h.prototype.hideColumn=function(e){var t=this.columnManager.findColumn(e);if(!t)return console.warn("Column Hide Error - No matching column found:",e),!1;t.hide(),this.options.responsiveLayout&&this.modExists("responsiveLayout",!0)&&this.modules.responsiveLayout.update()},h.prototype.toggleColumn=function(e){var t=this.columnManager.findColumn(e);if(!t)return console.warn("Column Visibility Toggle Error - No matching column found:",e),!1;t.visible?t.hide():t.show()},h.prototype.addColumn=function(e,t,i){var n=this.columnManager.findColumn(i);this.columnManager.addColumn(e,t,n)},h.prototype.deleteColumn=function(e){var t=this.columnManager.findColumn(e);if(!t)return console.warn("Column Delete Error - No matching column found:",e),!1;t.delete()},h.prototype.scrollToColumn=function(e,t,i){var n=this;return new Promise(function(o,s){var a=n.columnManager.findColumn(e);a?n.columnManager.scrollToColumn(a,t,i).then(function(){o()}).catch(function(e){s(e)}):(console.warn("Scroll Error - No matching column found:",e),s("Scroll Error - No matching column found"))})},h.prototype.setLocale=function(e){this.modules.localize.setLocale(e)},h.prototype.getLocale=function(){return this.modules.localize.getLocale()},h.prototype.getLang=function(e){return this.modules.localize.getLang(e)},h.prototype.redraw=function(e){this.columnManager.redraw(e),this.rowManager.redraw(e)},h.prototype.setHeight=function(e){this.options.height=isNaN(e)?e:e+"px",this.element.style.height=this.options.height,this.rowManager.redraw()},h.prototype.setSort=function(e,t){this.modExists("sort",!0)&&(this.modules.sort.setSort(e,t),this.rowManager.sorterRefresh())},h.prototype.getSorters=function(){if(this.modExists("sort",!0))return this.modules.sort.getSort()},h.prototype.clearSort=function(){this.modExists("sort",!0)&&(this.modules.sort.clear(),this.rowManager.sorterRefresh())},h.prototype.setFilter=function(e,t,i){this.modExists("filter",!0)&&(this.modules.filter.setFilter(e,t,i),this.rowManager.filterRefresh())},h.prototype.addFilter=function(e,t,i){this.modExists("filter",!0)&&(this.modules.filter.addFilter(e,t,i),this.rowManager.filterRefresh())},h.prototype.getFilters=function(e){if(this.modExists("filter",!0))return this.modules.filter.getFilters(e)},h.prototype.setHeaderFilterFocus=function(e){if(this.modExists("filter",!0)){var t=this.columnManager.findColumn(e);if(!t)return console.warn("Column Filter Focus Error - No matching column found:",e),!1;this.modules.filter.setHeaderFilterFocus(t)}},h.prototype.setHeaderFilterValue=function(e,t){if(this.modExists("filter",!0)){var i=this.columnManager.findColumn(e);if(!i)return console.warn("Column Filter Error - No matching column found:",e),!1;this.modules.filter.setHeaderFilterValue(i,t)}},h.prototype.getHeaderFilters=function(){if(this.modExists("filter",!0))return this.modules.filter.getHeaderFilters()},h.prototype.removeFilter=function(e,t,i){this.modExists("filter",!0)&&(this.modules.filter.removeFilter(e,t,i),this.rowManager.filterRefresh())},h.prototype.clearFilter=function(e){this.modExists("filter",!0)&&(this.modules.filter.clearFilter(e),this.rowManager.filterRefresh())},h.prototype.clearHeaderFilter=function(){this.modExists("filter",!0)&&(this.modules.filter.clearHeaderFilter(),this.rowManager.filterRefresh())},h.prototype.selectRow=function(e){this.modExists("selectRow",!0)&&this.modules.selectRow.selectRows(e)},h.prototype.deselectRow=function(e){this.modExists("selectRow",!0)&&this.modules.selectRow.deselectRows(e)},h.prototype.toggleSelectRow=function(e){this.modExists("selectRow",!0)&&this.modules.selectRow.toggleRow(e)},h.prototype.getSelectedRows=function(){if(this.modExists("selectRow",!0))return this.modules.selectRow.getSelectedRows()},h.prototype.getSelectedData=function(){if(this.modExists("selectRow",!0))return this.modules.selectRow.getSelectedData()},h.prototype.setMaxPage=function(e){if(!this.options.pagination||!this.modExists("page"))return!1;this.modules.page.setMaxPage(e)},h.prototype.setPage=function(e){return this.options.pagination&&this.modExists("page")?this.modules.page.setPage(e):new Promise(function(e,t){t()})},h.prototype.setPageToRow=function(e){var t=this;return new Promise(function(i,n){t.options.pagination&&t.modExists("page")&&(e=t.rowManager.findRow(e))?t.modules.page.setPageToRow(e).then(function(){i()}).catch(function(){n()}):n()})},h.prototype.setPageSize=function(e){if(!this.options.pagination||!this.modExists("page"))return!1;this.modules.page.setPageSize(e),this.modules.page.setPage(1).then(function(){}).catch(function(){})},h.prototype.getPageSize=function(){if(this.options.pagination&&this.modExists("page",!0))return this.modules.page.getPageSize()},h.prototype.previousPage=function(){if(!this.options.pagination||!this.modExists("page"))return!1;this.modules.page.previousPage()},h.prototype.nextPage=function(){if(!this.options.pagination||!this.modExists("page"))return!1;this.modules.page.nextPage()},h.prototype.getPage=function(){return!(!this.options.pagination||!this.modExists("page"))&&this.modules.page.getPage()},h.prototype.getPageMax=function(){return!(!this.options.pagination||!this.modExists("page"))&&this.modules.page.getPageMax()},h.prototype.setGroupBy=function(e){if(!this.modExists("groupRows",!0))return!1;this.options.groupBy=e,this.modules.groupRows.initialize(),this.rowManager.refreshActiveData("display")},h.prototype.setGroupStartOpen=function(e){if(!this.modExists("groupRows",!0))return!1;this.options.groupStartOpen=e,this.modules.groupRows.initialize(),this.options.groupBy?this.rowManager.refreshActiveData("group"):console.warn("Grouping Update - cant refresh view, no groups have been set")},h.prototype.setGroupHeader=function(e){if(!this.modExists("groupRows",!0))return!1;this.options.groupHeader=e,this.modules.groupRows.initialize(),this.options.groupBy?this.rowManager.refreshActiveData("group"):console.warn("Grouping Update - cant refresh view, no groups have been set")},h.prototype.getGroups=function(e){return!!this.modExists("groupRows",!0)&&this.modules.groupRows.getGroups(!0)},h.prototype.getGroupedData=function(){if(this.modExists("groupRows",!0))return this.options.groupBy?this.modules.groupRows.getGroupedData():this.getData()},h.prototype.getCalcResults=function(){return!!this.modExists("columnCalcs",!0)&&this.modules.columnCalcs.getResults()},h.prototype.navigatePrev=function(){var e=!1;return!(!this.modExists("edit",!0)||!(e=this.modules.edit.currentCell))&&e.nav().prev()},h.prototype.navigateNext=function(){var e=!1;return!(!this.modExists("edit",!0)||!(e=this.modules.edit.currentCell))&&e.nav().next()},h.prototype.navigateLeft=function(){var t=!1;return!(!this.modExists("edit",!0)||!(t=this.modules.edit.currentCell))&&(e.preventDefault(),t.nav().left())},h.prototype.navigateRight=function(){var t=!1;return!(!this.modExists("edit",!0)||!(t=this.modules.edit.currentCell))&&(e.preventDefault(),t.nav().right())},h.prototype.navigateUp=function(){var t=!1;return!(!this.modExists("edit",!0)||!(t=this.modules.edit.currentCell))&&(e.preventDefault(),t.nav().up())},h.prototype.navigateDown=function(){var t=!1;return!(!this.modExists("edit",!0)||!(t=this.modules.edit.currentCell))&&(e.preventDefault(),t.nav().dpwn())},h.prototype.undo=function(){return!(!this.options.history||!this.modExists("history",!0))&&this.modules.history.undo()},h.prototype.redo=function(){return!(!this.options.history||!this.modExists("history",!0))&&this.modules.history.redo()},h.prototype.getHistoryUndoSize=function(){return!(!this.options.history||!this.modExists("history",!0))&&this.modules.history.getHistoryUndoSize()},h.prototype.getHistoryRedoSize=function(){return!(!this.options.history||!this.modExists("history",!0))&&this.modules.history.getHistoryRedoSize()},h.prototype.download=function(e,t,i){this.modExists("download",!0)&&this.modules.download.download(e,t,i)},h.prototype.downloadToTab=function(e,t,i){this.modExists("download",!0)&&this.modules.download.download(e,t,i,!0)},h.prototype.tableComms=function(e,t,i,n){this.modules.comms.receive(e,t,i,n)},h.prototype.moduleBindings={},h.prototype.extendModule=function(e,t,i){if(h.prototype.moduleBindings[e]){var n=h.prototype.moduleBindings[e].prototype[t];if(n)if("object"==(void 0===i?"undefined":c(i)))for(var o in i)n[o]=i[o];else console.warn("Module Error - Invalid value type, it must be an object");else console.warn("Module Error - property does not exist:",t)}else console.warn("Module Error - module does not exist:",e)},h.prototype.registerModule=function(e,t){h.prototype.moduleBindings[e]=t},h.prototype.bindModules=function(){for(var e in this.modules={},h.prototype.moduleBindings)this.modules[e]=new h.prototype.moduleBindings[e](this)},h.prototype.modExists=function(e,t){return!!this.modules[e]||(t&&console.error("Tabulator Module Not Installed: "+e),!1)},h.prototype.helpers={elVisible:function(e){return!(e.offsetWidth<=0&&e.offsetHeight<=0)},elOffset:function(e){var t=e.getBoundingClientRect();return{top:t.top+window.pageYOffset-document.documentElement.clientTop,left:t.left+window.pageXOffset-document.documentElement.clientLeft}},deepClone:function(e){var t=Array.isArray(e)?[]:{};for(var i in e)null!=e[i]&&"object"===c(e[i])?e[i]instanceof Date?t[i]=new Date(e[i]):t[i]=this.deepClone(e[i]):t[i]=e[i];return t}},h.prototype.comms={tables:[],register:function(e){h.prototype.comms.tables.push(e)},deregister:function(e){var t=h.prototype.comms.tables.indexOf(e);t>-1&&h.prototype.comms.tables.splice(t,1)},lookupTable:function(e){var t,i,n=[];if("string"==typeof e){if((t=document.querySelectorAll(e)).length)for(var o=0;o-1?n/100*parseInt(e):parseInt(e):e}function h(e,t,i,n){var o=[],s=0,a=0,r=0,l=0,c=0,d=[];function p(e){return i*(e.column.definition.widthGrow||1)}function f(e){return u(e.width)-i*(e.column.definition.widthShrink||0)}return e.forEach(function(e,t){var i=n?f(e):p(e);e.column.minWidth>=i?o.push(e):(d.push(e),c+=n?e.column.definition.widthShrink||1:e.column.definition.widthGrow||1)}),o.length?(o.forEach(function(e){s+=n?e.width-e.column.minWidth:e.column.minWidth,e.width=e.column.minWidth}),l=(a=t-s)-(r=c?Math.floor(a/c):a)*c,l+=h(d,a,r,n)):(l=c?t-Math.floor(t/c)*c:t,d.forEach(function(e){e.width=n?f(e):p(e)})),l}this.table.options.responsiveLayout&&this.table.modExists("responsiveLayout",!0)&&this.table.modules.responsiveLayout.update(),this.table.rowManager.element.scrollHeight>this.table.rowManager.element.clientHeight&&(n-=this.table.rowManager.element.offsetWidth-this.table.rowManager.element.clientWidth),e.forEach(function(e){var t,i,n;e.visible&&(t=e.definition.width,i=parseInt(e.minWidth),t?(n=u(t),o+=n>i?n:i,e.definition.widthShrink&&(l.push({column:e,width:n>i?n:i}),c+=e.definition.widthShrink)):(r.push({column:e,width:0}),a+=e.definition.widthGrow||1))}),s=n-o,t=Math.floor(s/a);d=h(r,s,t,!1);r.length&&d>0&&(r[r.length-1].width+=+d),r.forEach(function(e){s-=e.width}),(i=Math.abs(d)+s)>0&&c&&(d=h(l,i,Math.floor(i/c),!0)),l.length&&(l[l.length-1].width-=d),r.forEach(function(e){e.column.setWidth(e.width)}),l.forEach(function(e){e.column.setWidth(e.width)})}},h.prototype.registerModule("layout",p);var f=function(e){this.table=e,this.locale="default",this.lang=!1,this.bindings={}};f.prototype.setHeaderFilterPlaceholder=function(e){this.langs.default.headerFilters.default=e},f.prototype.setHeaderFilterColumnPlaceholder=function(e,t){this.langs.default.headerFilters.columns[e]=t,this.lang&&!this.lang.headerFilters.columns[e]&&(this.lang.headerFilters.columns[e]=t)},f.prototype.installLang=function(e,t){this.langs[e]?this._setLangProp(this.langs[e],t):this.langs[e]=t},f.prototype._setLangProp=function(e,t){for(var i in t)e[i]&&"object"==c(e[i])?this._setLangProp(e[i],t[i]):e[i]=t[i]},f.prototype.setLocale=function(e){if(!0===(e=e||"default")&&navigator.language&&(e=navigator.language.toLowerCase()),e&&!this.langs[e]){var t=e.split("-")[0];this.langs[t]?(console.warn("Localization Error - Exact matching locale not found, using closest match: ",e,t),e=t):(console.warn("Localization Error - Matching locale not found, using default: ",e),e="default")}this.locale=e,this.lang=h.prototype.helpers.deepClone(this.langs.default||{}),"default"!=e&&function e(t,i){for(var n in t)"object"==c(t[n])?(i[n]||(i[n]={}),e(t[n],i[n])):i[n]=t[n]}(this.langs[e],this.lang),this.table.options.localized.call(this.table,this.locale,this.lang),this._executeBindings()},f.prototype.getLocale=function(e){return self.locale},f.prototype.getLang=function(e){return e?this.langs[e]:this.lang},f.prototype.getText=function(e,t){var i=(e=t?e+"|"+t:e).split("|");return this._getLangElement(i,this.locale)||""},f.prototype._getLangElement=function(e,t){var i=this.lang;return e.forEach(function(e){var t;i&&(t=i[e],i=void 0!==t&&t)}),i},f.prototype.bind=function(e,t){this.bindings[e]||(this.bindings[e]=[]),this.bindings[e].push(t),t(this.getText(e),this.lang)},f.prototype._executeBindings=function(){var e=this,t=function(t){e.bindings[t].forEach(function(i){i(e.getText(t),e.lang)})};for(var i in e.bindings)t(i)},f.prototype.langs={default:{groups:{item:"item",items:"items"},columns:{},ajax:{loading:"Loading",error:"Error"},pagination:{page_size:"Page Size",first:"First",first_title:"First Page",last:"Last",last_title:"Last Page",prev:"Prev",prev_title:"Prev Page",next:"Next",next_title:"Next Page"},headerFilters:{default:"filter column...",columns:{}}}},h.prototype.registerModule("localize",f);var m=function(e){this.table=e};m.prototype.getConnections=function(e){var t=this,i=[];return h.prototype.comms.lookupTable(e).forEach(function(e){t.table!==e&&i.push(e)}),i},m.prototype.send=function(e,t,i,n){var o=this,s=this.getConnections(e);s.forEach(function(e){e.tableComms(o.table.element,t,i,n)}),!s.length&&e&&console.warn("Table Connection Error - No tables matching selector found",e)},m.prototype.receive=function(e,t,i,n){if(this.table.modExists(t))return this.table.modules[t].commsReceived(e,i,n);console.warn("Inter-table Comms Error - no such module:",t)},h.prototype.registerModule("comms",m);var g=function(e){this.table=e,this.allowedTypes=["","data","download","clipboard"]};g.prototype.initializeColumn=function(e){var t=this,i=!1,n={};this.allowedTypes.forEach(function(o){var s,a="accessor"+(o.charAt(0).toUpperCase()+o.slice(1));e.definition[a]&&(s=t.lookupAccessor(e.definition[a]))&&(i=!0,n[a]={accessor:s,params:e.definition[a+"Params"]||{}})}),i&&(e.modules.accessor=n)},g.prototype.lookupAccessor=function(e){var t=!1;switch(void 0===e?"undefined":c(e)){case"string":this.accessors[e]?t=this.accessors[e]:console.warn("Accessor Error - No such accessor found, ignoring: ",e);break;case"function":t=e}return t},g.prototype.transformRow=function(e,t){var i="accessor"+(t.charAt(0).toUpperCase()+t.slice(1)),n=h.prototype.helpers.deepClone(e||{});return this.table.columnManager.traverse(function(e){var o,s,a,r;e.modules.accessor&&(s=e.modules.accessor[i]||e.modules.accessor.accessor||!1)&&"undefined"!=(o=e.getFieldValue(n))&&(r=e.getComponent(),a="function"==typeof s.params?s.params(o,n,t,r):s.params,e.setFieldValue(n,s.accessor(o,n,t,a,r)))}),n},g.prototype.accessors={},h.prototype.registerModule("accessor",g);var v=function(e){this.table=e,this.config=!1,this.url="",this.urlGenerator=!1,this.params=!1,this.loaderElement=this.createLoaderElement(),this.msgElement=this.createMsgElement(),this.loadingElement=!1,this.errorElement=!1,this.loaderPromise=!1,this.progressiveLoad=!1,this.loading=!1,this.requestOrder=0};v.prototype.initialize=function(){var e;this.loaderElement.appendChild(this.msgElement),this.table.options.ajaxLoaderLoading&&("string"==typeof this.table.options.ajaxLoaderLoading?((e=document.createElement("template")).innerHTML=this.table.options.ajaxLoaderLoading.trim(),this.loadingElement=e.content.firstChild):this.loadingElement=this.table.options.ajaxLoaderLoading),this.loaderPromise=this.table.options.ajaxRequestFunc||this.defaultLoaderPromise,this.urlGenerator=this.table.options.ajaxURLGenerator||this.defaultURLGenerator,this.table.options.ajaxLoaderError&&(this.errorElement=this.table.options.ajaxLoaderError),this.table.options.ajaxParams&&this.setParams(this.table.options.ajaxParams),this.table.options.ajaxConfig&&this.setConfig(this.table.options.ajaxConfig),this.table.options.ajaxURL&&this.setUrl(this.table.options.ajaxURL),this.table.options.ajaxProgressiveLoad&&(this.table.options.pagination?(this.progressiveLoad=!1,console.error("Progressive Load Error - Pagination and progressive load cannot be used at the same time")):this.table.modExists("page")?(this.progressiveLoad=this.table.options.ajaxProgressiveLoad,this.table.modules.page.initializeProgressive(this.progressiveLoad)):console.error("Pagination plugin is required for progressive ajax loading"))},v.prototype.createLoaderElement=function(){var e=document.createElement("div");return e.classList.add("tabulator-loader"),e},v.prototype.createMsgElement=function(){var e=document.createElement("div");return e.classList.add("tabulator-loader-msg"),e.setAttribute("role","alert"),e},v.prototype.setParams=function(e,t){if(t)for(var i in this.params=this.params||{},e)this.params[i]=e[i];else this.params=e},v.prototype.getParams=function(){return this.params||{}},v.prototype.setConfig=function(e){if(this._loadDefaultConfig(),"string"==typeof e)this.config.method=e;else for(var t in e)this.config[t]=e[t]},v.prototype._loadDefaultConfig=function(e){if(!this.config||e)for(var t in this.config={},this.defaultConfig)this.config[t]=this.defaultConfig[t]},v.prototype.setUrl=function(e){this.url=e},v.prototype.getUrl=function(){return this.url},v.prototype.loadData=function(e){return this.progressiveLoad?this._loadDataProgressive():this._loadDataStandard(e)},v.prototype.nextPage=function(e){this.loading||e<(this.table.options.ajaxProgressiveLoadScrollMargin||2*this.table.rowManager.getElement().clientHeight)&&this.table.modules.page.nextPage().then(function(){}).catch(function(){})},v.prototype.blockActiveRequest=function(){this.requestOrder++},v.prototype._loadDataProgressive=function(){return this.table.rowManager.setData([]),this.table.modules.page.setPage(1)},v.prototype._loadDataStandard=function(e){var t=this;return new Promise(function(i,n){t.sendRequest(e).then(function(o){t.table.rowManager.setData(o,e).then(function(){i()}).catch(function(e){n(e)})}).catch(function(e){n(e)})})},v.prototype.generateParamsList=function(e,t){var i=this,n=[];if(t=t||"",Array.isArray(e))e.forEach(function(e,o){n=n.concat(i.generateParamsList(e,t?t+"["+o+"]":o))});else if("object"===(void 0===e?"undefined":c(e)))for(var o in e)n=n.concat(i.generateParamsList(e[o],t?t+"["+o+"]":o));else n.push({key:t,value:e});return n},v.prototype.serializeParams=function(e){var t=this.generateParamsList(e),i=[];return t.forEach(function(e){i.push(encodeURIComponent(e.key)+"="+encodeURIComponent(e.value))}),i.join("&")},v.prototype.sendRequest=function(e){var t,i=this,n=this,o=n.url;return n.requestOrder++,t=n.requestOrder,n._loadDefaultConfig(),new Promise(function(s,a){!1!==n.table.options.ajaxRequesting.call(i.table,n.url,n.params)?(n.loading=!0,e||n.showLoader(),i.loaderPromise(o,n.config,n.params).then(function(e){t===n.requestOrder?(n.table.options.ajaxResponse&&(e=n.table.options.ajaxResponse.call(n.table,n.url,n.params,e)),s(e)):console.warn("Ajax Response Blocked - An active ajax request was blocked by an attempt to change table data while the request was being made"),n.hideLoader(),n.loading=!1}).catch(function(e){console.error("Ajax Load Error: ",e),n.table.options.ajaxError.call(n.table,e),n.showError(),setTimeout(function(){n.hideLoader()},3e3),n.loading=!1,a()})):a()})},v.prototype.showLoader=function(){if("function"==typeof this.table.options.ajaxLoader?this.table.options.ajaxLoader():this.table.options.ajaxLoader){for(this.hideLoader();this.msgElement.firstChild;)this.msgElement.removeChild(this.msgElement.firstChild);this.msgElement.classList.remove("tabulator-error"),this.msgElement.classList.add("tabulator-loading"),this.loadingElement?this.msgElement.appendChild(this.loadingElement):this.msgElement.innerHTML=this.table.modules.localize.getText("ajax|loading"),this.table.element.appendChild(this.loaderElement)}},v.prototype.showError=function(){for(this.hideLoader();this.msgElement.firstChild;)this.msgElement.removeChild(this.msgElement.firstChild);this.msgElement.classList.remove("tabulator-loading"),this.msgElement.classList.add("tabulator-error"),this.errorElement?this.msgElement.appendChild(this.errorElement):this.msgElement.innerHTML=this.table.modules.localize.getText("ajax|error"),this.table.element.appendChild(this.loaderElement)},v.prototype.hideLoader=function(){this.loaderElement.parentNode&&this.loaderElement.parentNode.removeChild(this.loaderElement)},v.prototype.defaultConfig={method:"GET"},v.prototype.defaultURLGenerator=function(e,t,i){return e&&i&&Object.keys(i).length&&(t.method&&"get"!=t.method.toLowerCase()||(t.method="get",e+="?"+this.serializeParams(i))),e},v.prototype.defaultLoaderPromise=function(e,t,i){var n,o=this;return new Promise(function(s,a){if(e=o.urlGenerator(e,t,i),"GET"!=t.method.toUpperCase())if(n="object"===c(o.table.options.ajaxContentType)?o.table.options.ajaxContentType:o.contentTypeFormatters[o.table.options.ajaxContentType]){for(var r in n.headers)t.headers||(t.headers={}),void 0===t.headers[r]&&(t.headers[r]=n.headers[r]);t.body=n.body.call(o,e,t,i)}else console.warn("Ajax Error - Invalid ajaxContentType value:",o.table.options.ajaxContentType);e?(void 0===t.headers&&(t.headers={}),void 0===t.headers.Accept&&(t.headers.Accept="application/json"),void 0===t.headers["X-Requested-With"]&&(t.headers["X-Requested-With"]="XMLHttpRequest"),void 0===t.mode&&(t.mode="cors"),"cors"==t.mode?(void 0===t.headers["Access-Control-Allow-Origin"]&&(t.headers["Access-Control-Allow-Origin"]=window.location.origin),void 0===t.credentials&&(t.credentials="same-origin")):void 0===t.credentials&&(t.credentials="include"),fetch(e,t).then(function(e){e.ok?e.json().then(function(e){s(e)}).catch(function(e){a(e),console.warn("Ajax Load Error - Invalid JSON returned",e)}):(console.error("Ajax Load Error - Connection Error: "+e.status,e.statusText),a(e))}).catch(function(e){console.error("Ajax Load Error - Connection Error: ",e),a(e)})):(console.warn("Ajax Load Error - No URL Set"),s([]))})},v.prototype.contentTypeFormatters={json:{headers:{"Content-Type":"application/json"},body:function(e,t,i){return JSON.stringify(i)}},form:{headers:{},body:function(e,t,i){var n=this.generateParamsList(i),o=new FormData;return n.forEach(function(e){o.append(e.key,e.value)}),o}}},h.prototype.registerModule("ajax",v);var b=function(e){this.table=e,this.topCalcs=[],this.botCalcs=[],this.genColumn=!1,this.topElement=this.createElement(),this.botElement=this.createElement(),this.topRow=!1,this.botRow=!1,this.topInitialized=!1,this.botInitialized=!1,this.initialize()};b.prototype.createElement=function(){var e=document.createElement("div");return e.classList.add("tabulator-calcs-holder"),e},b.prototype.initialize=function(){this.genColumn=new o({field:"value"},this)},b.prototype.registerColumnField=function(){},b.prototype.initializeColumn=function(e){var t=e.definition,i={topCalcParams:t.topCalcParams||{},botCalcParams:t.bottomCalcParams||{}};if(t.topCalc){switch(c(t.topCalc)){case"string":this.calculations[t.topCalc]?i.topCalc=this.calculations[t.topCalc]:console.warn("Column Calc Error - No such calculation found, ignoring: ",t.topCalc);break;case"function":i.topCalc=t.topCalc}i.topCalc&&(e.modules.columnCalcs=i,this.topCalcs.push(e),"group"!=this.table.options.columnCalcs&&this.initializeTopRow())}if(t.bottomCalc){switch(c(t.bottomCalc)){case"string":this.calculations[t.bottomCalc]?i.botCalc=this.calculations[t.bottomCalc]:console.warn("Column Calc Error - No such calculation found, ignoring: ",t.bottomCalc);break;case"function":i.botCalc=t.bottomCalc}i.botCalc&&(e.modules.columnCalcs=i,this.botCalcs.push(e),"group"!=this.table.options.columnCalcs&&this.initializeBottomRow())}},b.prototype.removeCalcs=function(){var e=!1;this.topInitialized&&(this.topInitialized=!1,this.topElement.parentNode.removeChild(this.topElement),e=!0),this.botInitialized&&(this.botInitialized=!1,this.table.footerManager.remove(this.botElement),e=!0),e&&this.table.rowManager.adjustTableSize()},b.prototype.initializeTopRow=function(){this.topInitialized||(this.table.columnManager.getElement().insertBefore(this.topElement,this.table.columnManager.headersElement.nextSibling),this.topInitialized=!0)},b.prototype.initializeBottomRow=function(){this.botInitialized||(this.table.footerManager.prepend(this.botElement),this.botInitialized=!0)},b.prototype.scrollHorizontal=function(e){this.table.columnManager.getElement().scrollWidth,this.table.element.clientWidth;this.botInitialized&&(this.botRow.getElement().style.marginLeft=-e+"px")},b.prototype.recalc=function(e){var t;if(this.topInitialized||this.botInitialized){if(this.rowsToData(e),this.topInitialized){for(t=this.generateRow("top",this.rowsToData(e)),this.topRow=t;this.topElement.firstChild;)this.topElement.removeChild(this.topElement.firstChild);this.topElement.appendChild(t.getElement()),t.initialize(!0)}if(this.botInitialized){for(t=this.generateRow("bottom",this.rowsToData(e)),this.botRow=t;this.botElement.firstChild;)this.botElement.removeChild(this.botElement.firstChild);this.botElement.appendChild(t.getElement()),t.initialize(!0)}this.table.rowManager.adjustTableSize(),this.table.modExists("frozenColumns")&&this.table.modules.frozenColumns.layout()}},b.prototype.recalcRowGroup=function(e){this.recalcGroup(this.table.modules.groupRows.getRowGroup(e))},b.prototype.recalcGroup=function(e){var t,i;e&&e.calcs&&(e.calcs.bottom&&(t=this.rowsToData(e.rows),i=this.generateRowData("bottom",t),e.calcs.bottom.updateData(i),e.calcs.bottom.reinitialize()),e.calcs.top&&(t=this.rowsToData(e.rows),i=this.generateRowData("top",t),e.calcs.top.updateData(i),e.calcs.top.reinitialize()))},b.prototype.generateTopRow=function(e){return this.generateRow("top",this.rowsToData(e))},b.prototype.generateBottomRow=function(e){return this.generateRow("bottom",this.rowsToData(e))},b.prototype.rowsToData=function(e){var t=[];return e.forEach(function(e){t.push(e.getData())}),t},b.prototype.generateRow=function(e,t){var i,n=this,o=this.generateRowData(e,t);return n.table.modExists("mutator")&&n.table.modules.mutator.disable(),i=new r(o,this),n.table.modExists("mutator")&&n.table.modules.mutator.enable(),i.getElement().classList.add("tabulator-calcs","tabulator-calcs-"+e),i.type="calc",i.generateCells=function(){var t=[];n.table.columnManager.columnsByIndex.forEach(function(o){if(o.visible){n.genColumn.setField(o.getField()),n.genColumn.hozAlign=o.hozAlign,o.definition[e+"CalcFormatter"]&&n.table.modExists("format")?n.genColumn.modules.format={formatter:n.table.modules.format.getFormatter(o.definition[e+"CalcFormatter"]),params:o.definition[e+"CalcFormatterParams"]}:n.genColumn.modules.format={formatter:n.table.modules.format.getFormatter("plaintext"),params:{}},n.genColumn.definition.cssClass=o.definition.cssClass;var s=new d(n.genColumn,i);s.column=o,s.setWidth(),o.cells.push(s),t.push(s)}}),this.cells=t},i},b.prototype.generateRowData=function(e,t){var i,n,o={},s="top"==e?this.topCalcs:this.botCalcs,a="top"==e?"topCalc":"botCalc";return s.forEach(function(e){var s=[];e.modules.columnCalcs&&e.modules.columnCalcs[a]&&(t.forEach(function(t){s.push(e.getFieldValue(t))}),n=a+"Params",i="function"==typeof e.modules.columnCalcs[n]?e.modules.columnCalcs[n](value,t):e.modules.columnCalcs[n],e.setFieldValue(o,e.modules.columnCalcs[a](s,t,i)))}),o},b.prototype.hasTopCalcs=function(){return!!this.topCalcs.length},b.prototype.hasBottomCalcs=function(){return!!this.botCalcs.length},b.prototype.redraw=function(){this.topRow&&this.topRow.normalizeHeight(!0),this.botRow&&this.botRow.normalizeHeight(!0)},b.prototype.getResults=function(){var e=this,t={};return this.table.options.groupBy&&this.table.modExists("groupRows")?this.table.modules.groupRows.getGroups(!0).forEach(function(i){t[i.getKey()]=e.getGroupResults(i)}):t={top:this.topRow?this.topRow.getData():{},bottom:this.botRow?this.botRow.getData():{}},t},b.prototype.getGroupResults=function(e){var t=this,i=e._getSelf(),n=e.getSubGroups(),o={};return n.forEach(function(e){o[e.getKey()]=t.getGroupResults(e)}),{top:i.calcs.top?i.calcs.top.getData():{},bottom:i.calcs.bottom?i.calcs.bottom.getData():{},groups:o}},b.prototype.calculations={avg:function(e,t,i){var n=0,o=void 0!==i.precision?i.precision:2;return e.length&&(n=e.reduce(function(e,t){return e+(t=Number(t))}),n/=e.length,n=!1!==o?n.toFixed(o):n),parseFloat(n).toString()},max:function(e,t,i){var n=null,o=void 0!==i.precision&&i.precision;return e.forEach(function(e){((e=Number(e))>n||null===n)&&(n=e)}),null!==n?!1!==o?n.toFixed(o):n:""},min:function(e,t,i){var n=null,o=void 0!==i.precision&&i.precision;return e.forEach(function(e){((e=Number(e))o&&(o=t)}),t.forEach(function(e){var t=e.length;if(t1&&(t.colSpan=e.width),e.height>1&&(t.rowSpan=e.height),t.innerHTML=e.title,g.mapElementStyles(e.element,t,["border-top","border-left","border-right","border-bottom","background-color","color","font-weight","font-family","font-size"]),i.appendChild(t)}),g.mapElementStyles(g.table.columnManager.getHeadersElement(),i,["border-top","border-left","border-right","border-bottom","background-color","color","font-weight","font-family","font-size"]),t.appendChild(i)}),g.htmlElement.appendChild(t)}(v)):(m=document.createElement("tr"),t.forEach(function(e){var t=document.createElement("th");t.innerHTML=e.definition.title,g.mapElementStyles(e.getElement(),t,["border-top","border-left","border-right","border-bottom","background-color","color","font-weight","font-family","font-size"]),m.appendChild(t)}),g.mapElementStyles(g.table.columnManager.getHeadersElement(),m,["border-top","border-left","border-right","border-bottom","background-color","color","font-weight","font-family","font-size"]),g.htmlElement.appendChild(document.createElement("thead").appendChild(m)))),t=this.table.columnManager.columnsByIndex,s=document.createElement("tbody"),window.getComputedStyle&&(r=this.table.element.querySelector(".tabulator-row-odd:not(.tabulator-group):not(.tabulator-calcs)"),l=this.table.element.querySelector(".tabulator-row-even:not(.tabulator-group):not(.tabulator-calcs)"),d=this.table.element.querySelector(".tabulator-row.tabulator-calcs"),u=this.table.element.querySelector(".tabulator-row:not(.tabulator-group):not(.tabulator-calcs)"),p=this.table.element.getElementsByClassName("tabulator-group")[0],u&&(f=u.getElementsByClassName("tabulator-cell"),h=f[0],f[f.length-1])),n.rowGroups?e.forEach(function(e){!function e(i,o){var a=document.createElement("tr"),r=document.createElement("td");r.colSpan=t.length,r.innerHTML=i.key,a.appendChild(r),s.appendChild(a),g.mapElementStyles(p,a,["border-top","border-left","border-right","border-bottom","color","font-weight","font-family","font-size","background-color"]),i.subGroups?i.subGroups.forEach(function(t){e(t,o[i.key]&&o[i.key].groups||{})}):(n.columnCalcs&&b(o,i.key,"top"),y(i.rows),n.columnCalcs&&b(o,i.key,"bottom"))}(e,i||{})}):(n.columnCalcs&&b(i,"top"),y(e),n.columnCalcs&&b(i,"bottom")),this.htmlElement.appendChild(s)},y.prototype.mapElementStyles=function(e,t,i){var n={"background-color":"backgroundColor",color:"fontColor","font-weight":"fontWeight","font-family":"fontFamily","font-size":"fontSize","border-top":"borderTop","border-left":"borderLeft","border-right":"borderRight","border-bottom":"borderBottom"};if(window.getComputedStyle){var o=window.getComputedStyle(e);i.forEach(function(e){t.style[n[e]]=o.getPropertyValue(e)})}},y.prototype.copySelectors={userSelection:function(e,t){return t},selected:function(e,t){var i=[];return this.table.modExists("selectRow",!0)&&(i=this.table.modules.selectRow.getSelectedRows()),e.rowGroups&&console.warn("Clipboard Warning - select coptSelector does not support row groups"),this.buildOutput(i,e,t)},table:function(e,t){return e.rowGroups&&console.warn("Clipboard Warning - table coptSelector does not support row groups"),this.buildOutput(this.table.rowManager.getComponents(),e,t)},active:function(e,t){var i;return i=e.rowGroups?this.buildComplexRows(e):this.table.rowManager.getComponents(!0),this.buildOutput(i,e,t)}},y.prototype.copyFormatters={raw:function(e,t){return e},table:function(e,t){var i=[];return e.forEach(function(e){e.forEach(function(e){void 0===e&&(e=""),(e=null==e?"":e.toString()).match(/\r|\n/)&&(e='"'+(e=e.split('"').join('""'))+'"')}),i.push(e.join("\t"))}),i.join("\n")}},y.prototype.pasteParsers={table:function(e){var t=[],i=!0,n=this.table.columnManager.columns,o=[],s=[];return(e=e.split("\n")).forEach(function(e){t.push(e.split("\t"))}),!(!t.length||1===t.length&&t[0].length<2)&&(!0,t[0].forEach(function(e){var t=n.find(function(t){return e&&t.definition.title&&e.trim()&&t.definition.title.trim()===e.trim()});t?o.push(t):i=!1}),i||(i=!0,o=[],t[0].forEach(function(e){var t=n.find(function(t){return e&&t.field&&e.trim()&&t.field.trim()===e.trim()});t?o.push(t):i=!1}),i||(o=this.table.columnManager.columnsByIndex)),i&&t.shift(),t.forEach(function(e){var t={};e.forEach(function(e,i){o[i]&&(t[o[i].field]=e)}),s.push(t)}),s)}},y.prototype.pasteActions={replace:function(e){return this.table.setData(e)},update:function(e){return this.table.updateOrAddData(e)},insert:function(e){return this.table.addData(e)}},h.prototype.registerModule("clipboard",y);var w=function(e){this.table=e,this.indent=10,this.field="",this.collapseEl=null,this.expandEl=null,this.branchEl=null,this.elementField=!1,this.startOpen=function(){},this.displayIndex=0};w.prototype.initialize=function(){var e=null,t=this.table.columnManager.getFirstVisibileColumn(),i=this.table.options;switch(this.field=i.dataTreeChildField,this.indent=i.dataTreeChildIndent,this.elementField=i.dataTreeElementColumn||!!t&&t.field,i.dataTreeBranchElement&&(!0===i.dataTreeBranchElement?(this.branchEl=document.createElement("div"),this.branchEl.classList.add("tabulator-data-tree-branch")):"string"==typeof i.dataTreeBranchElement?((e=document.createElement("div")).innerHTML=i.dataTreeBranchElement,this.branchEl=e.firstChild):this.branchEl=i.dataTreeBranchElement),i.dataTreeCollapseElement?"string"==typeof i.dataTreeCollapseElement?((e=document.createElement("div")).innerHTML=i.dataTreeCollapseElement,this.collapseEl=e.firstChild):this.collapseEl=i.dataTreeCollapseElement:(this.collapseEl=document.createElement("div"),this.collapseEl.classList.add("tabulator-data-tree-control"),this.collapseEl.innerHTML="
"),i.dataTreeExpandElement?"string"==typeof i.dataTreeExpandElement?((e=document.createElement("div")).innerHTML=i.dataTreeExpandElement,this.expandEl=e.firstChild):this.expandEl=i.dataTreeExpandElement:(this.expandEl=document.createElement("div"),this.expandEl.classList.add("tabulator-data-tree-control"),this.expandEl.innerHTML="
"),c(i.dataTreeStartExpanded)){case"boolean":this.startOpen=function(e,t){return i.dataTreeStartExpanded};break;case"function":this.startOpen=i.dataTreeStartExpanded;break;default:this.startOpen=function(e,t){return i.dataTreeStartExpanded[t]}}},w.prototype.initializeRow=function(e){var t=e.getData()[this.field],i=Array.isArray(t),n=i||!i&&"object"===(void 0===t?"undefined":c(t))&&null!==t;e.modules.dataTree={index:0,open:!!n&&this.startOpen(e.getComponent(),0),controlEl:!1,branchEl:!1,parent:!1,children:n}},w.prototype.layoutRow=function(e){var t=(this.elementField?e.getCell(this.elementField):e.getCells()[0]).getElement(),i=e.modules.dataTree;i.branchEl&&i.branchEl.parentNode.removeChild(i.branchEl),this.generateControlElement(e,t),i.index&&(this.branchEl?(i.branchEl=this.branchEl.cloneNode(!0),t.insertBefore(i.branchEl,t.firstChild),i.branchEl.style.marginLeft=(i.branchEl.offsetWidth+i.branchEl.style.marginRight)*(i.index-1)+i.index*this.indent+"px"):t.style.paddingLeft=parseInt(window.getComputedStyle(t,null).getPropertyValue("padding-left"))+i.index*this.indent+"px")},w.prototype.generateControlElement=function(e,t){var i=this,n=e.modules.dataTree,o=(t=t||e.getCells()[0].getElement(),n.controlEl);!1!==n.children&&(n.open?(n.controlEl=this.collapseEl.cloneNode(!0),n.controlEl.addEventListener("click",function(t){t.stopPropagation(),i.collapseRow(e)})):(n.controlEl=this.expandEl.cloneNode(!0),n.controlEl.addEventListener("click",function(t){t.stopPropagation(),i.expandRow(e)})),n.controlEl.addEventListener("mousedown",function(e){e.stopPropagation()}),o&&o.parentNode===t?o.parentNode.replaceChild(n.controlEl,o):t.insertBefore(n.controlEl,t.firstChild))},w.prototype.setDisplayIndex=function(e){this.displayIndex=e},w.prototype.getDisplayIndex=function(){return this.displayIndex},w.prototype.getRows=function(e){var t=this,i=[];return e.forEach(function(e,n){var o;i.push(e),e instanceof r&&((o=e.modules.dataTree.children).index||!1===o.children||t.getChildren(e).forEach(function(e){i.push(e)}))}),i},w.prototype.getChildren=function(e){var t=this,i=e.modules.dataTree,n=[],o=[];return!1!==i.children&&i.open&&(Array.isArray(i.children)||(i.children=this.generateChildren(e)),n=this.table.modExists("filter")?this.table.modules.filter.filter(i.children):i.children,this.table.modExists("sort")&&this.table.modules.sort.sort(n),n.forEach(function(e){o.push(e),t.getChildren(e).forEach(function(e){o.push(e)})})),o},w.prototype.generateChildren=function(e){var t=this,i=[],n=e.getData()[this.field];return Array.isArray(n)||(n=[n]),n.forEach(function(n){var o=new r(n||{},t.table.rowManager);o.modules.dataTree.index=e.modules.dataTree.index+1,o.modules.dataTree.parent=e,o.modules.dataTree.children&&(o.modules.dataTree.open=t.startOpen(o.getComponent(),o.modules.dataTree.index)),i.push(o)}),i},w.prototype.expandRow=function(e,t){var i=e.modules.dataTree;!1!==i.children&&(i.open=!0,e.reinitialize(),this.table.rowManager.refreshActiveData("tree",!1,!0),this.table.options.dataTreeRowExpanded(e.getComponent(),e.modules.dataTree.index))},w.prototype.collapseRow=function(e){var t=e.modules.dataTree;!1!==t.children&&(t.open=!1,e.reinitialize(),this.table.rowManager.refreshActiveData("tree",!1,!0),this.table.options.dataTreeRowCollapsed(e.getComponent(),e.modules.dataTree.index))},w.prototype.toggleRow=function(e){var t=e.modules.dataTree;!1!==t.children&&(t.open?this.collapseRow(e):this.expandRow(e))},w.prototype.getTreeParent=function(e){return!!e.modules.dataTree.parent&&e.modules.dataTree.parent.getComponent()},w.prototype.getTreeChildren=function(e){var t=e.modules.dataTree,i=[];return t.children&&(Array.isArray(t.children)||(t.children=this.generateChildren(e)),t.children.forEach(function(e){e instanceof r&&i.push(e.getComponent())})),i},w.prototype.checkForRestyle=function(e){e.row.cells.indexOf(e)||!1!==e.row.modules.dataTree.children&&e.row.reinitialize()},w.prototype.getChildField=function(){return this.field},h.prototype.registerModule("dataTree",w);var x=function(e){this.table=e,this.fields={},this.columnsByIndex=[],this.columnsByField={},this.config={}};x.prototype.download=function(e,t,i,n){var o=this,s=!1;this.processConfig(),"function"==typeof e?s=e:o.downloaders[e]?s=o.downloaders[e]:console.warn("Download Error - No such download type found: ",e),this.processColumns(),s&&s.call(this,o.processDefinitions(),o.processData(),i||{},function(i,s){n?!0===n?o.triggerDownload(i,s,e,t,!0):n(i):o.triggerDownload(i,s,e,t)},this.config)},x.prototype.processConfig=function(){var e={columnGroups:!0,rowGroups:!0,columnCalcs:!0};if(this.table.options.downloadConfig)for(var t in this.table.options.downloadConfig)e[t]=this.table.options.downloadConfig[t];e.rowGroups&&this.table.options.groupBy&&this.table.modExists("groupRows")&&(this.config.rowGroups=!0),e.columnGroups&&this.table.columnManager.columns.length!=this.table.columnManager.columnsByIndex.length&&(this.config.columnGroups=!0),e.columnCalcs&&this.table.modExists("columnCalcs")&&(this.config.columnCalcs=!0)},x.prototype.processColumns=function(){var e=this;e.columnsByIndex=[],e.columnsByField={},e.table.columnManager.columnsByIndex.forEach(function(t){t.field&&!1!==t.definition.download&&(t.visible||!t.visible&&t.definition.download)&&(e.columnsByIndex.push(t),e.columnsByField[t.field]=t)})},x.prototype.processDefinitions=function(){var e=this,t=[];return this.config.columnGroups?e.table.columnManager.columns.forEach(function(i){var n=e.processColumnGroup(i);n&&t.push(n)}):e.columnsByIndex.forEach(function(i){!1!==i.download&&t.push(e.processDefinition(i))}),t},x.prototype.processColumnGroup=function(e){var t=this,i=e.columns,n=0,o={type:"group",title:e.definition.title,depth:1};if(i.length){if(o.subGroups=[],o.width=0,i.forEach(function(e){var i=t.processColumnGroup(e);i.depth>n&&(n=i.depth),i&&(o.width+=i.width,o.subGroups.push(i))}),o.depth+=n,!o.width)return!1}else{if(!e.field||!1===e.definition.download||!(e.visible||!e.visible&&e.definition.download))return!1;o.width=1,o.definition=this.processDefinition(e)}return o},x.prototype.processDefinition=function(e){var t={};for(var i in e.definition)t[i]=e.definition[i];return void 0!==e.definition.downloadTitle&&(t.title=e.definition.downloadTitle),t},x.prototype.processData=function(){var e=this,t=[],i={};return this.config.rowGroups?this.table.modules.groupRows.getGroups().forEach(function(i){t.push(e.processGroupData(i))}):t=this.table.rowManager.getData(!0,"download"),this.config.columnCalcs&&(i=this.table.getCalcResults(),t={calcs:i,data:t}),"function"==typeof this.table.options.downloadDataFormatter&&(t=this.table.options.downloadDataFormatter(t)),t},x.prototype.processGroupData=function(e){var t=this,i=e.getSubGroups(),n={type:"group",key:e.key};return i.length?(n.subGroups=[],i.forEach(function(e){n.subGroups.push(t.processGroupData(e))})):n.rows=e.getData(!0,"download"),n},x.prototype.triggerDownload=function(e,t,i,n,o){var s=document.createElement("a"),a=new Blob([e],{type:t});n=n||"Tabulator."+("function"==typeof i?"txt":i);(a=this.table.options.downloadReady.call(this.table,e,a))&&(o?window.open(window.URL.createObjectURL(a)):navigator.msSaveOrOpenBlob?navigator.msSaveOrOpenBlob(a,n):(s.setAttribute("href",window.URL.createObjectURL(a)),s.setAttribute("download",n),s.style.display="none",document.body.appendChild(s),s.click(),document.body.removeChild(s)),this.table.options.downloadComplete&&this.table.options.downloadComplete())},x.prototype.getFieldValue=function(e,t){var i=this.columnsByField[e];return!!i&&i.getFieldValue(t)},x.prototype.commsReceived=function(e,t,i){switch(t){case"intercept":this.download(i.type,"",i.options,i.intercept)}},x.prototype.downloaders={csv:function(e,t,i,n,o){var s,a,r=this,l=[],d=[],u=i&&i.delimiter?i.delimiter:",";function h(e){e.forEach(function(e){var t=[];d.forEach(function(i){var n=r.getFieldValue(i,e);switch(void 0===n?"undefined":c(n)){case"object":n=JSON.stringify(n);break;case"undefined":case"null":n="";break;default:n=n}t.push('"'+String(n).split('"').join('""')+'"')}),s.push(t.join(u))})}o.columnGroups?(console.warn("Download Warning - CSV downloader cannot process column groups"),e.forEach(function(e){!function e(t,i){t.subGroups?t.subGroups.forEach(function(t){e(t,i+1)}):(l.push('"'+String(t.title).split('"').join('""')+'"'),d.push(t.definition.field))}(e,0)})):e.forEach(function(e){l.push('"'+String(e.title).split('"').join('""')+'"'),d.push(e.field)}),s=[l.join(u)],o.columnCalcs&&(console.warn("Download Warning - CSV downloader cannot process column calculations"),t=t.data),o.rowGroups?(console.warn("Download Warning - CSV downloader cannot process row groups"),t.forEach(function(e){!function e(t){t.subGroups?t.subGroups.forEach(function(t){e(t)}):h(t.rows)}(e)})):h(t),a=s.join("\n"),i.bom&&(a="\ufeff"+a),n(a,"text/csv")},json:function(e,t,i,n,o){o.columnCalcs&&(console.warn("Download Warning - CSV downloader cannot process column calculations"),t=t.data),n(JSON.stringify(t,null,"\t"),"application/json")},pdf:function(e,t,i,n,o){var s=this,a=[],r=[],l=[],d={},u=1,h={},p=i.rowGroupStyles||{fontStyle:"bold",fontSize:12,cellPadding:6,fillColor:220},f=i.rowCalcStyles||{fontStyle:"bold",fontSize:10,cellPadding:4,fillColor:232},m=i.jsPDF||{},g=i&&i.title?i.title:"";if(o.columnCalcs&&(d=t.calcs,t=t.data),m.orientation||(m.orientation=i.orientation||"landscape"),m.unit||(m.unit="pt"),o.columnGroups){e.forEach(function(e){e.depth>u&&(u=e.depth)});for(var v=0;v1)for(var l=i+1;l1&&h[t].push({type:"hoz",start:n[t].length,end:n[t].length+e.width-1}),n[t].push(e.title),e.subGroups?e.subGroups.forEach(function(e){l(e,t+1)}):(o.push(e.definition.field),o.length,i=0,n.forEach(function(e){var t=e.length;t>i&&(i=t)}),n.forEach(function(e){var t=e.length;if(t0&&b(u[t-1]);break;case 40:e.stopImmediatePropagation(),e.stopPropagation(),(t=u.indexOf(f))-1||String(t.title).toLowerCase().indexOf(String(e).toLowerCase())>-1)&&i.push(t)}),u=i,function(e){var t=!1;for(;c.firstChild;)c.removeChild(c.firstChild);u.forEach(function(i){var n=i.element;n||((n=document.createElement("div")).classList.add("tabulator-edit-select-list-item"),n.tabIndex=0,n.innerHTML=i.title,n.addEventListener("click",function(){v(i),b()}),n.addEventListener("mousedown",function(){m=!1,setTimeout(function(){m=!0},10)}),i.element=n,e&&i.value==r&&(l.value=i.title,i.element.classList.add("active"),t=!0),i===f&&(i.element.classList.add("active"),t=!0)),c.appendChild(n)}),t||v(!1)}(t)}function v(e,t){f&&f.element&&f.element.classList.remove("active"),f=e,e&&e.element&&e.element.classList.add("active")}function b(){w(),f?r!==f.value?(r=f.value,l.value=f.value,i(l.value)):n():o.freetext?(r=l.value,i(l.value)):o.allowEmpty&&""===l.value?(r=l.value,i(l.value)):n()}function y(){if(!c.parentNode){for(;c.firstChild;)c.removeChild(c.firstChild);!0===o.values?(i={},n=e.getColumn()._getSelf(),s.table.getData().forEach(function(e){var t=n.getFieldValue(e);null!=t&&""!==t&&(i[t]=!0)}),p=i=o.sortValuesList?"asc"==o.sortValuesList?Object.keys(i).sort():Object.keys(i).sort().reverse():Object.keys(i)):p=o.values||[],function(e,t){var i=[];if(Array.isArray(e))e.forEach(function(e){var n={title:o.listItemFormatter?o.listItemFormatter(e,e):e,value:e,element:!1};n.value!==t&&(isNaN(parseFloat(n.value))||isNaN(parseFloat(n.value))||parseFloat(n.value)!==parseFloat(t))||v(n),i.push(n)});else for(var n in e){var s={title:o.listItemFormatter?o.listItemFormatter(n,e[n]):e[n],value:n,element:!1};s.value!==t&&(isNaN(parseFloat(s.value))||isNaN(parseFloat(s.value))||parseFloat(s.value)!==parseFloat(t))||v(s),i.push(s)}d=i}(p,r);var t=h.prototype.helpers.elOffset(a);c.style.minWidth=a.offsetWidth+"px",c.style.top=t.top+a.offsetHeight+"px",c.style.left=t.left+"px",document.body.appendChild(c)}var i,n}function w(){c.parentNode&&c.parentNode.removeChild(c)}return l.setAttribute("type","search"),l.style.padding="4px",l.style.width="100%",l.style.boxSizing="border-box",l.addEventListener("keydown",function(e){var t;switch(e.keyCode){case 38:e.stopImmediatePropagation(),e.stopPropagation(),v((t=u.indexOf(f))>0&&u[t-1]);break;case 40:e.stopImmediatePropagation(),e.stopPropagation(),(t=u.indexOf(f))'):("ie"==s.table.browser?t.setAttribute("class","tabulator-star-inactive"):t.classList.replace("tabulator-star-active","tabulator-star-inactive"),t.innerHTML='')})}function f(e){var t=document.createElement("span"),n=h.cloneNode(!0);d.push(n),t.addEventListener("mouseenter",function(t){t.stopPropagation(),t.stopImmediatePropagation(),p(e)}),t.addEventListener("mousemove",function(e){e.stopPropagation(),e.stopImmediatePropagation()}),t.addEventListener("click",function(t){t.stopPropagation(),t.stopImmediatePropagation(),i(e)}),t.appendChild(n),u.appendChild(t)}function m(e){r=e,p(e)}a.style.whiteSpace="nowrap",a.style.overflow="hidden",a.style.textOverflow="ellipsis",u.style.verticalAlign="middle",u.style.display="inline-block",u.style.padding="4px",h.setAttribute("width",c),h.setAttribute("height",c),h.setAttribute("viewBox","0 0 512 512"),h.setAttribute("xml:space","preserve"),h.style.padding="0 1px";for(var g=1;g<=l;g++)f(g);return p(r=Math.min(parseInt(r),l)),u.addEventListener("mousemove",function(e){p(0)}),u.addEventListener("click",function(e){i(0)}),a.addEventListener("blur",function(e){n()}),a.addEventListener("keydown",function(e){switch(e.keyCode){case 39:m(r+1);break;case 37:m(r-1);break;case 13:i(r);break;case 27:n()}}),u},progress:function(e,t,i,n,o){var s,a,r=e.getElement(),l=void 0===o.max?r.getElementsByTagName("div")[0].getAttribute("max")||100:o.max,c=void 0===o.min?r.getElementsByTagName("div")[0].getAttribute("min")||0:o.min,d=(l-c)/100,u=e.getValue()||0,h=document.createElement("div"),p=document.createElement("div");function f(){var e=d*Math.round(p.offsetWidth/(r.clientWidth/100))+c;i(e),r.setAttribute("aria-valuenow",e),r.setAttribute("aria-label",u)}return h.style.position="absolute",h.style.right="0",h.style.top="0",h.style.bottom="0",h.style.width="5px",h.classList.add("tabulator-progress-handle"),p.style.display="inline-block",p.style.position="relative",p.style.height="100%",p.style.backgroundColor="#488CE9",p.style.maxWidth="100%",p.style.minWidth="0%",r.style.padding="4px 4px",u=Math.min(parseFloat(u),l),u=Math.max(parseFloat(u),c),u=Math.round((u-c)/d),p.style.width=u+"%",r.setAttribute("aria-valuemin",c),r.setAttribute("aria-valuemax",l),p.appendChild(h),h.addEventListener("mousedown",function(e){s=e.screenX,a=p.offsetWidth}),h.addEventListener("mouseover",function(){h.style.cursor="ew-resize"}),r.addEventListener("mousemove",function(e){s&&(p.style.width=a+e.screenX-s+"px")}),r.addEventListener("mouseup",function(e){s&&(e.stopPropagation(),e.stopImmediatePropagation(),s=!1,a=!1,f())}),r.addEventListener("keydown",function(e){switch(e.keyCode){case 39:p.style.width=p.clientWidth+r.clientWidth/100+"px";break;case 37:p.style.width=p.clientWidth-r.clientWidth/100+"px";break;case 13:f();break;case 27:n()}}),r.addEventListener("blur",function(){n()}),p},tickCross:function(e,t,i,n,o){var s=e.getValue(),a=document.createElement("input"),r=o.tristate,l=void 0===o.indeterminateValue?null:o.indeterminateValue,c=!1;function d(e){return r?e?c?l:a.checked:a.checked&&!c?(a.checked=!1,a.indeterminate=!0,c=!0,l):(c=!1,a.checked):a.checked}return a.setAttribute("type","checkbox"),a.style.marginTop="5px",a.style.boxSizing="border-box",a.value=s,!r||void 0!==s&&s!==l&&""!==s||(c=!0,a.indeterminate=!0),"firefox"!=this.table.browser&&t(function(){a.focus()}),a.checked=!0===s||"true"===s||"True"===s||1===s,a.addEventListener("change",function(e){i(d())}),a.addEventListener("blur",function(e){i(d(!0))}),a.addEventListener("keydown",function(e){13==e.keyCode&&i(d()),27==e.keyCode&&n()}),a}},h.prototype.registerModule("edit",C);var E=function(e){this.table=e,this.filterList=[],this.headerFilters={},this.headerFilterElements=[],this.headerFilterColumns=[],this.changed=!1};E.prototype.initializeColumn=function(e,t){var i,n=this,o=e.getField();e.modules.filter={success:function(t){var s,a="input"==e.modules.filter.tagType&&"text"==e.modules.filter.attrType||"textarea"==e.modules.filter.tagType?"partial":"match",r="";if(void 0===i||i!==t){if(i=t,e.modules.filter.emptyFunc(t))delete n.headerFilters[o];else{switch(e.modules.filter.value=t,c(e.definition.headerFilterFunc)){case"string":n.filters[e.definition.headerFilterFunc]?(r=e.definition.headerFilterFunc,s=function(i){var o=e.definition.headerFilterFuncParams||{},s=e.getFieldValue(i);return o="function"==typeof o?o(t,s,i):o,n.filters[e.definition.headerFilterFunc](t,s,i,o)}):console.warn("Header Filter Error - Matching filter function not found: ",e.definition.headerFilterFunc);break;case"function":r=s=function(i){var n=e.definition.headerFilterFuncParams||{},o=e.getFieldValue(i);return n="function"==typeof n?n(t,o,i):n,e.definition.headerFilterFunc(t,o,i,n)}}if(!s)switch(a){case"partial":s=function(i){return String(e.getFieldValue(i)).toLowerCase().indexOf(String(t).toLowerCase())>-1},r="like";break;default:s=function(i){return e.getFieldValue(i)==t},r="="}n.headerFilters[o]={value:t,func:s,type:r}}n.changed=!0,n.table.rowManager.filterRefresh()}},attrType:!1,tagType:!1,emptyFunc:!1},this.generateHeaderFilterElement(e)},E.prototype.generateHeaderFilterElement=function(e,t){var i,n,o,s,a,r,l,d=this,u=e.modules.filter.success,h=e.getField();if(e.modules.filter.headerElement&&e.modules.filter.headerElement.parentNode){var p=e.modules.filter.headerElement.parentNode,f=d.headerFilterElements.indexOf(p);f>=0&&d.headerFilterElements.splice(f,1);var m=d.headerFilterColumns.indexOf(m);m>=0&&d.headerFilterColumns.splice(m,1),e.contentElement.removeChild(p)}if(h){switch(e.modules.filter.emptyFunc=e.definition.headerFilterEmptyCheck||function(e){return!e&&"0"!==e},(i=document.createElement("div")).classList.add("tabulator-header-filter"),c(e.definition.headerFilter)){case"string":d.table.modules.edit.editors[e.definition.headerFilter]?(n=d.table.modules.edit.editors[e.definition.headerFilter],"tick"!==e.definition.headerFilter&&"tickCross"!==e.definition.headerFilter||e.definition.headerFilterEmptyCheck||(e.modules.filter.emptyFunc=function(e){return!0!==e&&!1!==e})):console.warn("Filter Error - Cannot build header filter, No such editor found: ",e.definition.editor);break;case"function":n=e.definition.headerFilter;break;case"boolean":e.modules.edit&&e.modules.edit.editor?n=e.modules.edit.editor:e.definition.formatter&&d.table.modules.edit.editors[e.definition.formatter]?(n=d.table.modules.edit.editors[e.definition.formatter],"tick"!==e.definition.formatter&&"tickCross"!==e.definition.formatter||e.definition.headerFilterEmptyCheck||(e.modules.filter.emptyFunc=function(e){return!0!==e&&!1!==e})):n=d.table.modules.edit.editors.input}if(n){if(s={getValue:function(){return void 0!==t?t:""},getField:function(){return e.definition.field},getElement:function(){return i},getColumn:function(){return e.getComponent()},getRow:function(){return{normalizeHeight:function(){}}}},l="function"==typeof(l=e.definition.headerFilterParams||{})?l.call(d.table):l,!(o=n.call(this.table.modules.edit,s,function(){},u,function(){},l)))return void console.warn("Filter Error - Cannot add filter to "+h+" column, editor returned a value of false");if(!(o instanceof Node))return void console.warn("Filter Error - Cannot add filter to "+h+" column, editor should return an instance of Node, the editor returned:",o);h?d.table.modules.localize.bind("headerFilters|columns|"+e.definition.field,function(e){o.setAttribute("placeholder",void 0!==e&&e?e:d.table.modules.localize.getText("headerFilters|default"))}):d.table.modules.localize.bind("headerFilters|default",function(e){o.setAttribute("placeholder",void 0!==d.column.definition.headerFilterPlaceholder&&d.column.definition.headerFilterPlaceholder?d.column.definition.headerFilterPlaceholder:e)}),o.addEventListener("click",function(e){e.stopPropagation(),o.focus()}),a=!1,r=function(e){a&&clearTimeout(a),a=setTimeout(function(){u(o.value)},300)},e.modules.filter.headerElement=o,e.modules.filter.attrType=o.hasAttribute("type")?o.getAttribute("type").toLowerCase():"",e.modules.filter.tagType=o.tagName.toLowerCase(),!1!==e.definition.headerFilterLiveFilter&&("autocomplete"===e.definition.headerFilter||"autocomplete"===e.definition.editor&&!0===e.definition.headerFilter||(o.addEventListener("keyup",r),o.addEventListener("search",r),"number"==e.modules.filter.attrType&&o.addEventListener("change",function(e){u(o.value)}),"text"==e.modules.filter.attrType&&"ie"!==this.table.browser&&o.setAttribute("type","search")),"input"!=e.modules.filter.tagType&&"select"!=e.modules.filter.tagType&&"textarea"!=e.modules.filter.tagType||o.addEventListener("mousedown",function(e){e.stopPropagation()})),i.appendChild(o),e.contentElement.appendChild(i),d.headerFilterElements.push(o),d.headerFilterColumns.push(e)}}else console.warn("Filter Error - Cannot add header filter, column has no field set:",e.definition.title)},E.prototype.hideHeaderFilterElements=function(){this.headerFilterElements.forEach(function(e){e.style.display="none"})},E.prototype.showHeaderFilterElements=function(){this.headerFilterElements.forEach(function(e){e.style.display=""})},E.prototype.setHeaderFilterFocus=function(e){e.modules.filter&&e.modules.filter.headerElement?e.modules.filter.headerElement.focus():console.warn("Column Filter Focus Error - No header filter set on column:",e.getField())},E.prototype.setHeaderFilterValue=function(e,t){e&&(e.modules.filter&&e.modules.filter.headerElement?(this.generateHeaderFilterElement(e,t),e.modules.filter.success(t)):console.warn("Column Filter Error - No header filter set on column:",e.getField()))},E.prototype.reloadHeaderFilter=function(e){e&&(e.modules.filter&&e.modules.filter.headerElement?this.generateHeaderFilterElement(e,e.modules.filter.value):console.warn("Column Filter Error - No header filter set on column:",e.getField()))},E.prototype.hasChanged=function(){var e=this.changed;return this.changed=!1,e},E.prototype.setFilter=function(e,t,i){this.filterList=[],Array.isArray(e)||(e=[{field:e,type:t,value:i}]),this.addFilter(e)},E.prototype.addFilter=function(e,t,i){var n=this;Array.isArray(e)||(e=[{field:e,type:t,value:i}]),e.forEach(function(e){(e=n.findFilter(e))&&(n.filterList.push(e),n.changed=!0)}),this.table.options.persistentFilter&&this.table.modExists("persistence",!0)&&this.table.modules.persistence.save("filter")},E.prototype.findFilter=function(e){var t,i=this;if(Array.isArray(e))return this.findSubFilters(e);var n=!1;return"function"==typeof e.field?n=function(t){return e.field(t,e.type||{})}:i.filters[e.type]?n=(t=i.table.columnManager.getColumnByField(e.field))?function(n){return i.filters[e.type](e.value,t.getFieldValue(n))}:function(t){return i.filters[e.type](e.value,t[e.field])}:console.warn("Filter Error - No such filter type found, ignoring: ",e.type),e.func=n,!!e.func&&e},E.prototype.findSubFilters=function(e){var t=this,i=[];return e.forEach(function(e){(e=t.findFilter(e))&&i.push(e)}),!!i.length&&i},E.prototype.getFilters=function(e,t){var i=[];return e&&(i=this.getHeaderFilters()),this.filterList.forEach(function(e){i.push({field:e.field,type:e.type,value:e.value})}),t&&i.forEach(function(e){"function"==typeof e.type&&(e.type="function")}),i},E.prototype.getHeaderFilters=function(){var e=[];for(var t in this.headerFilters)e.push({field:t,type:this.headerFilters[t].type,value:this.headerFilters[t].value});return e},E.prototype.removeFilter=function(e,t,i){var n=this;Array.isArray(e)||(e=[{field:e,type:t,value:i}]),e.forEach(function(e){var t=-1;(t="object"==c(e.field)?n.filterList.findIndex(function(t){return e===t}):n.filterList.findIndex(function(t){return e.field===t.field&&e.type===t.type&&e.value===t.value}))>-1?(n.filterList.splice(t,1),n.changed=!0):console.warn("Filter Error - No matching filter type found, ignoring: ",e.type)}),this.table.options.persistentFilter&&this.table.modExists("persistence",!0)&&this.table.modules.persistence.save("filter")},E.prototype.clearFilter=function(e){this.filterList=[],e&&this.clearHeaderFilter(),this.changed=!0,this.table.options.persistentFilter&&this.table.modExists("persistence",!0)&&this.table.modules.persistence.save("filter")},E.prototype.clearHeaderFilter=function(){var e=this;this.headerFilters={},this.headerFilterColumns.forEach(function(t){t.modules.filter.value=null,e.reloadHeaderFilter(t)}),this.changed=!0},E.prototype.search=function(e,t,i,n){var o=this,s=[],a=[];return Array.isArray(t)||(t=[{field:t,type:i,value:n}]),t.forEach(function(e){(e=o.findFilter(e))&&a.push(e)}),this.table.rowManager.rows.forEach(function(t){var i=!0;a.forEach(function(e){o.filterRecurse(e,t.getData())||(i=!1)}),i&&s.push("data"===e?t.getData("data"):t.getComponent())}),s},E.prototype.filter=function(e,t){var i=this,n=[],o=[];return i.table.options.dataFiltering&&i.table.options.dataFiltering.call(i.table,i.getFilters()),i.table.options.ajaxFiltering||!i.filterList.length&&!Object.keys(i.headerFilters).length?n=e.slice(0):e.forEach(function(e){i.filterRow(e)&&n.push(e)}),i.table.options.dataFiltered&&(n.forEach(function(e){o.push(e.getComponent())}),i.table.options.dataFiltered.call(i.table,i.getFilters(),o)),n},E.prototype.filterRow=function(e,t){var i=this,n=!0,o=e.getData();for(var s in i.filterList.forEach(function(e){i.filterRecurse(e,o)||(n=!1)}),i.headerFilters)i.headerFilters[s].func(o)||(n=!1);return n},E.prototype.filterRecurse=function(e,t){var i=this,n=!1;return Array.isArray(e)?e.forEach(function(e){i.filterRecurse(e,t)&&(n=!0)}):n=e.func(t),n},E.prototype.filters={"=":function(e,t,i,n){return t==e},"<":function(e,t,i,n){return t":function(e,t,i,n){return t>e},">=":function(e,t,i,n){return t>=e},"!=":function(e,t,i,n){return t!=e},regex:function(e,t,i,n){return"string"==typeof e&&(e=new RegExp(e)),e.test(t)},like:function(e,t,i,n){return null==e?t===e:null!=t&&String(t).toLowerCase().indexOf(e.toLowerCase())>-1},in:function(e,t,i,n){return Array.isArray(e)?e.indexOf(t)>-1:(console.warn("Filter Error - filter value is not an array:",e),!1)}},h.prototype.registerModule("filter",E);var T=function(e){this.table=e};T.prototype.initializeColumn=function(e){var t={params:e.definition.formatterParams||{}};switch(c(e.definition.formatter)){case"string":"tick"===e.definition.formatter&&(e.definition.formatter="tickCross",void 0===t.params.crossElement&&(t.params.crossElement=!1),console.warn("DEPRECATION WANRING - the tick formatter has been depricated, please use the tickCross formatter with the crossElement param set to false")),this.formatters[e.definition.formatter]?t.formatter=this.formatters[e.definition.formatter]:(console.warn("Formatter Error - No such formatter found: ",e.definition.formatter),t.formatter=this.formatters.plaintext);break;case"function":t.formatter=e.definition.formatter;break;default:t.formatter=this.formatters.plaintext}e.modules.format=t},T.prototype.cellRendered=function(e){e.column.modules.format.renderedCallback&&e.column.modules.format.renderedCallback()},T.prototype.formatValue=function(e){var t=e.getComponent(),i="function"==typeof e.column.modules.format.params?e.column.modules.format.params(t):e.column.modules.format.params;return e.column.modules.format.formatter.call(this,t,i,function(t){e.column.modules.format.renderedCallback=t})},T.prototype.sanitizeHTML=function(e){if(e){var t={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/","`":"`","=":"="};return String(e).replace(/[&<>"'`=\/]/g,function(e){return t[e]})}return e},T.prototype.emptyToSpace=function(e){return null==e?" ":e},T.prototype.getFormatter=function(e){switch(void 0===e?"undefined":c(e)){case"string":this.formatters[e]?e=this.formatters[e]:(console.warn("Formatter Error - No such formatter found: ",e),e=this.formatters.plaintext);break;case"function":e=e;break;default:e=this.formatters.plaintext}return e},T.prototype.formatters={plaintext:function(e,t,i){return this.emptyToSpace(this.sanitizeHTML(e.getValue()))},html:function(e,t,i){return e.getValue()},textarea:function(e,t,i){return e.getElement().style.whiteSpace="pre-wrap",this.emptyToSpace(this.sanitizeHTML(e.getValue()))},money:function(e,t,i){var n,o,s,a,r=parseFloat(e.getValue()),l=t.decimal||".",c=t.thousand||",",d=t.symbol||"",u=!!t.symbolAfter,h=void 0!==t.precision?t.precision:2;if(isNaN(r))return this.emptyToSpace(this.sanitizeHTML(e.getValue()));for(n=!1!==h?r.toFixed(h):r,o=(n=String(n).split("."))[0],s=n.length>1?l+n[1]:"",a=/(\d+)(\d{3})/;a.test(o);)o=o.replace(a,"$1"+c+"$2");return u?o+s+d:d+o+s},link:function(e,t,i){var n=e.getValue(),o=t.urlPrefix||"",s=this.emptyToSpace(n),a=document.createElement("a");if(t.labelField&&(s=e.getData()[t.labelField]),t.label)switch(c(t.label)){case"string":s=t.label;break;case"function":s=t.label(e)}if(t.urlField&&(n=e.getData()[t.urlField]),t.url)switch(c(t.url)){case"string":n=t.url;break;case"function":n=t.url(e)}return a.setAttribute("href",o+n),t.target&&a.setAttribute("target",t.target),a.innerHTML=this.emptyToSpace(this.sanitizeHTML(s)),a},image:function(e,t,i){var n=document.createElement("img");switch(n.setAttribute("src",e.getValue()),c(t.height)){case"number":n.style.height=t.height+"px";break;case"string":n.style.height=t.height}switch(c(t.width)){case"number":n.style.width=t.width+"px";break;case"string":n.style.width=t.width}return n.addEventListener("load",function(){e.getRow().normalizeHeight()}),n},tickCross:function(e,t,i){var n=e.getValue(),o=e.getElement(),s=t.allowEmpty,a=t.allowTruthy,r=void 0!==t.tickElement?t.tickElement:'',l=void 0!==t.crossElement?t.crossElement:'';return a&&n||!0===n||"true"===n||"True"===n||1===n||"1"===n?(o.setAttribute("aria-checked",!0),r||""):!s||"null"!==n&&""!==n&&null!=n?(o.setAttribute("aria-checked",!1),l||""):(o.setAttribute("aria-checked","mixed"),"")},datetime:function(e,t,i){var n=t.inputFormat||"YYYY-MM-DD hh:mm:ss",o=t.outputFormat||"DD/MM/YYYY hh:mm:ss",s=void 0!==t.invalidPlaceholder?t.invalidPlaceholder:"",a=e.getValue(),r=moment(a,n);return r.isValid()?r.format(o):!0===s?a:"function"==typeof s?s(a):s},datetimediff:function(e,t,i){var n=t.inputFormat||"YYYY-MM-DD hh:mm:ss",o=void 0!==t.invalidPlaceholder?t.invalidPlaceholder:"",s=void 0!==t.suffix&&t.suffix,a=void 0!==t.unit?t.unit:void 0,r=void 0!==t.humanize&&t.humanize,l=void 0!==t.date?t.date:moment(),c=e.getValue(),d=moment(c,n);return d.isValid()?r?moment.duration(d.diff(l)).humanize(s):d.diff(l,a)+(s?" "+s:""):!0===o?c:"function"==typeof o?o(c):o},lookup:function(e,t,i){var n=e.getValue();return void 0===t[n]?(console.warn("Missing display value for "+n),n):t[n]},star:function(e,t,i){var n=e.getValue(),o=e.getElement(),s=t&&t.stars?t.stars:5,a=document.createElement("span"),r=document.createElementNS("http://www.w3.org/2000/svg","svg");a.style.verticalAlign="middle",r.setAttribute("width","14"),r.setAttribute("height","14"),r.setAttribute("viewBox","0 0 512 512"),r.setAttribute("xml:space","preserve"),r.style.padding="0 1px",n=parseInt(n)':'',a.appendChild(c)}return o.style.whiteSpace="nowrap",o.style.overflow="hidden",o.style.textOverflow="ellipsis",o.setAttribute("aria-label",n),a},traffic:function(e,t,i){var n,o,s=this.sanitizeHTML(e.getValue())||0,a=document.createElement("span"),r=t&&t.max?t.max:100,l=t&&t.min?t.min:0,d=t&&void 0!==t.color?t.color:["red","orange","green"],u="#666666";if(!isNaN(s)&&void 0!==e.getValue()){switch(a.classList.add("tabulator-traffic-light"),o=parseFloat(s)<=r?parseFloat(s):r,o=parseFloat(o)>=l?parseFloat(o):l,n=(r-l)/100,o=Math.round((o-l)/n),void 0===d?"undefined":c(d)){case"string":u=d;break;case"function":u=d(s);break;case"object":if(Array.isArray(d)){var h=100/d.length,p=Math.floor(o/h);p=Math.min(p,d.length-1),u=d[p=Math.max(p,0)];break}}return a.style.backgroundColor=u,a}},progress:function(e,t,i){var n,o,s,a,r,l=this.sanitizeHTML(e.getValue())||0,d=e.getElement(),u=t&&t.max?t.max:100,h=t&&t.min?t.min:0,p=t&&t.legendAlign?t.legendAlign:"center";switch(o=parseFloat(l)<=u?parseFloat(l):u,o=parseFloat(o)>=h?parseFloat(o):h,n=(u-h)/100,o=Math.round((o-h)/n),c(t.color)){case"string":s=t.color;break;case"function":s=t.color(l);break;case"object":if(Array.isArray(t.color)){var f=100/t.color.length,m=Math.floor(o/f);m=Math.min(m,t.color.length-1),m=Math.max(m,0),s=t.color[m];break}default:s="#2DC214"}switch(c(t.legend)){case"string":a=t.legend;break;case"function":a=t.legend(l);break;case"boolean":a=l;break;default:a=!1}switch(c(t.legendColor)){case"string":r=t.legendColor;break;case"function":r=t.legendColor(l);break;case"object":if(Array.isArray(t.legendColor)){f=100/t.legendColor.length,m=Math.floor(o/f);m=Math.min(m,t.legendColor.length-1),m=Math.max(m,0),r=t.legendColor[m]}break;default:r="#000"}return d.style.minWidth="30px",d.style.position="relative",d.setAttribute("aria-label",o),"
"+(a?"
"+a+"
":"")},color:function(e,t,i){return e.getElement().style.backgroundColor=this.sanitizeHTML(e.getValue()),""},buttonTick:function(e,t,i){return''},buttonCross:function(e,t,i){return''},rownum:function(e,t,i){return this.table.rowManager.activeRows.indexOf(e.getRow()._getSelf())+1},handle:function(e,t,i){return e.getElement().classList.add("tabulator-row-handle"),"
"},responsiveCollapse:function(e,t,i){var n=!1,o=document.createElement("div");function s(t){var i=e.getRow().getElement().getElementsByClassName("tabulator-responsive-collapse")[0];(n=t)?(o.classList.add("open"),i&&(i.style.display="")):(o.classList.remove("open"),i&&(i.style.display="none"))}return o.classList.add("tabulator-responsive-collapse-toggle"),o.innerHTML="+-",e.getElement().classList.add("tabulator-row-handle"),this.table.options.responsiveLayoutCollapseStartOpen&&(n=!0),o.addEventListener("click",function(e){e.stopImmediatePropagation(),s(!n)}),s(n),o}},h.prototype.registerModule("format",T);var S=function(e){this.table=e,this.leftColumns=[],this.rightColumns=[],this.leftMargin=0,this.rightMargin=0,this.initializationMode="left",this.active=!1};S.prototype.reset=function(){this.initializationMode="left",this.leftColumns=[],this.rightColumns=[],this.active=!1},S.prototype.initializeColumn=function(e){var t={margin:0,edge:!1};e.definition.frozen?e.parent.isGroup?console.warn("Frozen Column Error - Grouped columns cannot be frozen"):e.isGroup?console.warn("Frozen Column Error - Column Groups cannot be frozen"):(t.position=this.initializationMode,"left"==this.initializationMode?this.leftColumns.push(e):this.rightColumns.unshift(e),this.active=!0,e.modules.frozen=t):this.initializationMode="right"},S.prototype.layout=function(){var e=this,t=(this.table.rowManager.element,0);e.active&&(e.leftMargin=e._calcSpace(e.leftColumns,e.leftColumns.length),e.table.columnManager.headersElement.style.marginLeft=e.leftMargin+"px",e.rightMargin=e._calcSpace(e.rightColumns,e.rightColumns.length),e.table.columnManager.element.style.paddingRight=e.rightMargin+"px",e.table.rowManager.activeRows.forEach(function(t){e.layoutRow(t)}),e.table.options.dataTree&&e.table.rowManager.getDisplayRows().forEach(function(t){e.layoutRow(t)}),e.table.modExists("columnCalcs")&&(e.table.modules.columnCalcs.topInitialized&&e.table.modules.columnCalcs.topRow&&e.layoutRow(e.table.modules.columnCalcs.topRow),e.table.modules.columnCalcs.botInitialized&&e.table.modules.columnCalcs.botRow&&e.layoutRow(e.table.modules.columnCalcs.botRow)),e.leftColumns.forEach(function(t,i){t.modules.frozen.margin=e._calcSpace(e.leftColumns,i)+e.table.columnManager.scrollLeft,i==e.leftColumns.length-1?t.modules.frozen.edge=!0:t.modules.frozen.edge=!1,e.layoutColumn(t)}),t=e.table.rowManager.element.clientWidth+e.table.columnManager.scrollLeft,e.rightColumns.forEach(function(i,n){i.modules.frozen.margin=t-e._calcSpace(e.rightColumns,n+1),n==e.rightColumns.length-1?i.modules.frozen.edge=!0:i.modules.frozen.edge=!1,e.layoutColumn(i)}),this.table.rowManager.tableElement.style.marginRight=this.rightMargin+"px")},S.prototype.layoutColumn=function(e){var t=this;t.layoutElement(e.getElement(),e),e.cells.forEach(function(i){t.layoutElement(i.getElement(),e)})},S.prototype.layoutRow=function(e){e.getElement().style.paddingLeft=this.leftMargin+"px"},S.prototype.layoutElement=function(e,t){t.modules.frozen&&(e.style.position="absolute",e.style.left=t.modules.frozen.margin+"px",e.classList.add("tabulator-frozen"),t.modules.frozen.edge&&e.classList.add("tabulator-frozen-"+t.modules.frozen.position))},S.prototype._calcSpace=function(e,t){for(var i=0,n=0;n-1&&t.splice(i,1)}),t},k.prototype.freezeRow=function(e){e.modules.frozen?console.warn("Freeze Error - Row is already frozen"):(e.modules.frozen=!0,this.topElement.appendChild(e.getElement()),e.initialize(),e.normalizeHeight(),this.table.rowManager.adjustTableSize(),this.rows.push(e),this.table.rowManager.refreshActiveData("display"),this.styleRows())},k.prototype.unfreezeRow=function(e){var t=this.rows.indexOf(e);if(e.modules.frozen){e.modules.frozen=!1;var i=e.getElement();i.parentNode.removeChild(i),this.table.rowManager.adjustTableSize(),this.rows.splice(t,1),this.table.rowManager.refreshActiveData("display"),this.rows.length&&this.styleRows()}else console.warn("Freeze Error - Row is already unfrozen")},k.prototype.styleRows=function(e){var t=this;this.rows.forEach(function(e,i){t.table.rowManager.styleRow(e,i)})},h.prototype.registerModule("frozenRows",k);var M=function(e){this._group=e,this.type="GroupComponent"};M.prototype.getKey=function(){return this._group.key},M.prototype.getElement=function(){return this._group.element},M.prototype.getRows=function(){return this._group.getRows(!0)},M.prototype.getSubGroups=function(){return this._group.getSubGroups(!0)},M.prototype.getParentGroup=function(){return!!this._group.parent&&this._group.parent.getComponent()},M.prototype.getVisibility=function(){return this._group.visible},M.prototype.show=function(){this._group.show()},M.prototype.hide=function(){this._group.hide()},M.prototype.toggle=function(){this._group.toggleVisibility()},M.prototype._getSelf=function(){return this._group},M.prototype.getTable=function(){return this._group.groupManager.table};var _=function(e,t,i,n,o,s,a){this.groupManager=e,this.parent=t,this.key=n,this.level=i,this.field=o,this.hasSubGroups=i-1?i?this.rows.splice(o+1,0,e):this.rows.splice(o,0,e):i?this.rows.push(e):this.rows.unshift(e),e.modules.group=this,this.generateGroupHeaderContents(),this.groupManager.table.modExists("columnCalcs")&&"table"!=this.groupManager.table.options.columnCalcs&&this.groupManager.table.modules.columnCalcs.recalcGroup(this)},_.prototype.scrollHeader=function(e){this.arrowElement.style.marginLeft=e,this.groupList.forEach(function(t){t.scrollHeader(e)})},_.prototype.getRowIndex=function(e){},_.prototype.conformRowData=function(e){return this.field?e[this.field]=this.key:console.warn("Data Conforming Error - Cannot conform row data to match new group as groupBy is a function"),this.parent&&(e=this.parent.conformRowData(e)),e},_.prototype.removeRow=function(e){var t=this.rows.indexOf(e);t>-1&&this.rows.splice(t,1),this.groupManager.table.options.groupValues||this.rows.length?(this.generateGroupHeaderContents(),this.groupManager.table.modExists("columnCalcs")&&"table"!=this.groupManager.table.options.columnCalcs&&this.groupManager.table.modules.columnCalcs.recalcGroup(this)):(this.parent?this.parent.removeGroup(this):this.groupManager.removeGroup(this),this.groupManager.updateGroupRows(!0))},_.prototype.removeGroup=function(e){var t,i=e.level+"_"+e.key;this.groups[i]&&(delete this.groups[i],(t=this.groupList.indexOf(e))>-1&&this.groupList.splice(t,1),this.groupList.length||(this.parent?this.parent.removeGroup(this):this.groupManager.removeGroup(this)))},_.prototype.getHeadersAndRows=function(e){var t=[];return t.push(this),this._visSet(),this.visible?this.groupList.length?this.groupList.forEach(function(i){t=t.concat(i.getHeadersAndRows(e))}):(!e&&"table"!=this.groupManager.table.options.columnCalcs&&this.groupManager.table.modExists("columnCalcs")&&this.groupManager.table.modules.columnCalcs.hasTopCalcs()&&(this.calcs.top&&this.calcs.top.detachElement(),this.calcs.top=this.groupManager.table.modules.columnCalcs.generateTopRow(this.rows),t.push(this.calcs.top)),t=t.concat(this.rows),!e&&"table"!=this.groupManager.table.options.columnCalcs&&this.groupManager.table.modExists("columnCalcs")&&this.groupManager.table.modules.columnCalcs.hasBottomCalcs()&&(this.calcs.bottom&&this.calcs.bottom.detachElement(),this.calcs.bottom=this.groupManager.table.modules.columnCalcs.generateBottomRow(this.rows),t.push(this.calcs.bottom))):!this.groupList.length&&"table"!=this.groupManager.table.options.columnCalcs&&this.groupManager.table.options.groupClosedShowCalcs&&this.groupManager.table.modExists("columnCalcs")&&(!e&&this.groupManager.table.modules.columnCalcs.hasTopCalcs()&&(this.calcs.top&&this.calcs.top.detachElement(),this.calcs.top=this.groupManager.table.modules.columnCalcs.generateTopRow(this.rows),t.push(this.calcs.top)),!e&&this.groupManager.table.modules.columnCalcs.hasBottomCalcs()&&(this.calcs.bottom&&this.calcs.bottom.detachElement(),this.calcs.bottom=this.groupManager.table.modules.columnCalcs.generateBottomRow(this.rows),t.push(this.calcs.bottom))),t},_.prototype.getData=function(e,t){var i=[];return this._visSet(),(!e||e&&this.visible)&&this.rows.forEach(function(e){i.push(e.getData(t||"data"))}),i},_.prototype.getRowCount=function(){var e=0;return this.groupList.length?this.groupList.forEach(function(t){e+=t.getRowCount()}):e=this.rows.length,e},_.prototype.toggleVisibility=function(){this.visible?this.hide():this.show()},_.prototype.hide=function(){this.visible=!1,"classic"!=this.groupManager.table.rowManager.getRenderMode()||this.groupManager.table.options.pagination?this.groupManager.updateGroupRows(!0):(this.element.classList.remove("tabulator-group-visible"),this.groupList.length?this.groupList.forEach(function(e){e.getHeadersAndRows().forEach(function(e){e.detachElement()})}):this.rows.forEach(function(e){var t=e.getElement();t.parentNode.removeChild(t)}),this.groupManager.table.rowManager.setDisplayRows(this.groupManager.updateGroupRows(),this.groupManager.getDisplayIndex()),this.groupManager.table.rowManager.checkClassicModeGroupHeaderWidth()),this.groupManager.table.options.groupVisibilityChanged.call(this.table,this.getComponent(),!1)},_.prototype.show=function(){if(this.visible=!0,"classic"!=this.groupManager.table.rowManager.getRenderMode()||this.groupManager.table.options.pagination)this.groupManager.updateGroupRows(!0);else{this.element.classList.add("tabulator-group-visible");var e=this.getElement();this.groupList.length?this.groupList.forEach(function(t){t.getHeadersAndRows().forEach(function(t){var i=t.getElement();e.parentNode.insertBefore(i,e.nextSibling),t.initialize(),e=i})}):this.rows.forEach(function(t){var i=t.getElement();e.parentNode.insertBefore(i,e.nextSibling),t.initialize(),e=i}),this.groupManager.table.rowManager.setDisplayRows(this.groupManager.updateGroupRows(),this.groupManager.getDisplayIndex()),this.groupManager.table.rowManager.checkClassicModeGroupHeaderWidth()}this.groupManager.table.options.groupVisibilityChanged.call(this.table,this.getComponent(),!0)},_.prototype._visSet=function(){var e=[];"function"==typeof this.visible&&(this.rows.forEach(function(t){e.push(t.getData())}),this.visible=this.visible(this.key,this.getRowCount(),e,this.getComponent()))},_.prototype.getRowGroup=function(e){var t=!1;return this.groupList.length?this.groupList.forEach(function(i){var n=i.getRowGroup(e);n&&(t=n)}):this.rows.find(function(t){return t===e})&&(t=this),t},_.prototype.getSubGroups=function(e){var t=[];return this.groupList.forEach(function(i){t.push(e?i.getComponent():i)}),t},_.prototype.getRows=function(e){var t=[];return this.rows.forEach(function(i){t.push(e?i.getComponent():i)}),t},_.prototype.generateGroupHeaderContents=function(){var e=[];for(this.rows.forEach(function(t){e.push(t.getData())}),this.elementContents=this.generator(this.key,this.getRowCount(),e,this.getComponent());this.element.firstChild;)this.element.removeChild(this.element.firstChild);"string"==typeof this.elementContents?this.element.innerHTML=this.elementContents:this.element.appendChild(this.elementContents),this.element.insertBefore(this.arrowElement,this.element.firstChild)},_.prototype.getElement=function(){this.addBindingsd=!1,this._visSet(),this.visible?this.element.classList.add("tabulator-group-visible"):this.element.classList.remove("tabulator-group-visible");for(var e=0;e("+n+" "+(1===n?t:i.groups.items)+")"}}),this.groupIDLookups=[],Array.isArray(t)||t)?this.table.modExists("columnCalcs")&&"table"!=this.table.options.columnCalcs&&"both"!=this.table.options.columnCalcs&&this.table.modules.columnCalcs.removeCalcs():this.table.modExists("columnCalcs")&&"group"!=this.table.options.columnCalcs&&this.table.columnManager.getRealColumns().forEach(function(t){t.definition.topCalc&&e.table.modules.columnCalcs.initializeTopRow(),t.definition.bottomCalc&&e.table.modules.columnCalcs.initializeBottomRow()});Array.isArray(t)||(t=[t]),t.forEach(function(t,i){var n,o;n="function"==typeof t?t:(o=e.table.columnManager.getColumnByField(t))?function(e){return o.getFieldValue(e)}:function(e){return e[t]},e.groupIDLookups.push({field:"function"!=typeof t&&t,func:n,values:!!e.allowedValues&&e.allowedValues[i]})}),i&&(Array.isArray(i)||(i=[i]),i.forEach(function(e){e="function"==typeof e?e:function(){return!0}}),e.startOpen=i),n&&(e.headerGenerator=Array.isArray(n)?n:[n]),this.initialized=!0},D.prototype.setDisplayIndex=function(e){this.displayIndex=e},D.prototype.getDisplayIndex=function(){return this.displayIndex},D.prototype.getRows=function(e){return this.groupIDLookups.length?(this.table.options.dataGrouping.call(this.table),this.generateGroups(e),this.table.options.dataGrouped&&this.table.options.dataGrouped.call(this.table,this.getGroups(!0)),this.updateGroupRows()):e.slice(0)},D.prototype.getGroups=function(e){var t=[];return this.groupList.forEach(function(i){t.push(e?i.getComponent():i)}),t},D.prototype.pullGroupListData=function(e){var t=this,i=[];return e.forEach(function(e){var n={level:0,rowCount:0,headerContent:""},o=[];e.hasSubGroups?(o=t.pullGroupListData(e.groupList),n.level=e.level,n.rowCount=o.length-e.groupList.length,n.headerContent=e.generator(e.key,n.rowCount,e.rows,e),i.push(n),i=i.concat(o)):(n.level=e.level,n.headerContent=e.generator(e.key,e.rows.length,e.rows,e),n.rowCount=e.getRows().length,i.push(n),e.getRows().forEach(function(e){i.push(e.getData("data"))}))}),i},D.prototype.getGroupedData=function(){return this.pullGroupListData(this.groupList)},D.prototype.getRowGroup=function(e){var t=!1;return this.groupList.forEach(function(i){var n=i.getRowGroup(e);n&&(t=n)}),t},D.prototype.countGroups=function(){return this.groupList.length},D.prototype.generateGroups=function(e){var t=this,i=t.groups;t.groups={},t.groupList=[],this.allowedValues&&this.allowedValues[0]?(this.allowedValues[0].forEach(function(e){t.createGroup(e,0,i)}),e.forEach(function(e){t.assignRowToExistingGroup(e,i)})):e.forEach(function(e){t.assignRowToGroup(e,i)})},D.prototype.createGroup=function(e,t,i){var n,o=t+"_"+e;i=i||[],n=new _(this,!1,t,e,this.groupIDLookups[0].field,this.headerGenerator[0],i[o]),this.groups[o]=n,this.groupList.push(n)},D.prototype.assignRowToGroup=function(e,t){var i=this.groupIDLookups[0].func(e.getData()),n="0_"+i;this.groups[n]||this.createGroup(i,0,t),this.groups[n].addRow(e)},D.prototype.assignRowToExistingGroup=function(e,t){var i="0_"+this.groupIDLookups[0].func(e.getData());this.groups[i]&&this.groups[i].addRow(e)},D.prototype.assignRowToGroup=function(e,t){var i=this.groupIDLookups[0].func(e.getData()),n=!this.groups["0_"+i];return n&&this.createGroup(i,0,t),this.groups["0_"+i].addRow(e),!n},D.prototype.updateGroupRows=function(e){var t=[];if(this.groupList.forEach(function(e){t=t.concat(e.getHeadersAndRows())}),e){var i=this.table.rowManager.setDisplayRows(t,this.getDisplayIndex());!0!==i&&this.setDisplayIndex(i),this.table.rowManager.refreshActiveData("group",!0,!0)}return t},D.prototype.scrollHeaders=function(e){e+="px",this.groupList.forEach(function(t){t.scrollHeader(e)})},D.prototype.removeGroup=function(e){var t,i=e.level+"_"+e.key;this.groups[i]&&(delete this.groups[i],(t=this.groupList.indexOf(e))>-1&&this.groupList.splice(t,1))},h.prototype.registerModule("groupRows",D);var R=function(e){this.table=e,this.history=[],this.index=-1};R.prototype.clear=function(){this.history=[],this.index=-1},R.prototype.action=function(e,t,i){this.history=this.history.slice(0,this.index+1),this.history.push({type:e,component:t,data:i}),this.index++},R.prototype.getHistoryUndoSize=function(){return this.index+1},R.prototype.getHistoryRedoSize=function(){return this.history.length-(this.index+1)},R.prototype.undo=function(){if(this.index>-1){var e=this.history[this.index];return this.undoers[e.type].call(this,e),this.index--,this.table.options.historyUndo.call(this.table,e.type,e.component.getComponent(),e.data),!0}return console.warn("History Undo Error - No more history to undo"),!1},R.prototype.redo=function(){if(this.history.length-1>this.index){this.index++;var e=this.history[this.index];return this.redoers[e.type].call(this,e),this.table.options.historyRedo.call(this.table,e.type,e.component.getComponent(),e.data),!0}return console.warn("History Redo Error - No more history to redo"),!1},R.prototype.undoers={cellEdit:function(e){e.component.setValueProcessData(e.data.oldValue)},rowAdd:function(e){e.component.deleteActual()},rowDelete:function(e){var t=this.table.rowManager.addRowActual(e.data.data,e.data.pos,e.data.index);this._rebindRow(e.component,t)},rowMove:function(e){this.table.rowManager.moveRowActual(e.component,this.table.rowManager.rows[e.data.pos],!1),this.table.rowManager.redraw()}},R.prototype.redoers={cellEdit:function(e){e.component.setValueProcessData(e.data.newValue)},rowAdd:function(e){var t=this.table.rowManager.addRowActual(e.data.data,e.data.pos,e.data.index);this._rebindRow(e.component,t)},rowDelete:function(e){e.component.deleteActual()},rowMove:function(e){this.table.rowManager.moveRowActual(e.component,this.table.rowManager.rows[e.data.pos],!1),this.table.rowManager.redraw()}},R.prototype._rebindRow=function(e,t){this.history.forEach(function(i){if(i.component instanceof r)i.component===e&&(i.component=t);else if(i.component instanceof d&&i.component.row===e){var n=i.component.column.getField();n&&(i.component=t.getCell(n))}})},h.prototype.registerModule("history",R);var L=function(e){this.table=e,this.fieldIndex=[],this.hasIndex=!1};L.prototype.parseTable=function(){var e=this.table.element,t=this.table.options,i=(t.columns,e.getElementsByTagName("th")),n=e.getElementsByTagName("tbody")[0],o=[];this.hasIndex=!1,this.table.options.htmlImporting.call(this.table),n=n?n.getElementsByTagName("tr"):[],this._extractOptions(e,t),i.length?this._extractHeaders(i,n):this._generateBlankHeaders(i,n);for(var s=0;s-1&&e.pressedKeys.splice(n,1)}},this.table.element.addEventListener("keydown",this.keyupBinding),this.table.element.addEventListener("keyup",this.keydownBinding)},P.prototype.clearBindings=function(){this.keyupBinding&&this.table.element.removeEventListener("keydown",this.keyupBinding),this.keydownBinding&&this.table.element.removeEventListener("keyup",this.keydownBinding)},P.prototype.checkBinding=function(e,t){var i=this,n=!0;return e.ctrlKey==t.ctrl&&e.shiftKey==t.shift&&(t.keys.forEach(function(e){-1==i.pressedKeys.indexOf(e)&&(n=!1)}),n&&t.action.call(i,e),!0)},P.prototype.bindings={navPrev:"shift + 9",navNext:9,navUp:38,navDown:40,scrollPageUp:33,scrollPageDown:34,scrollToStart:36,scrollToEnd:35,undo:"ctrl + 90",redo:"ctrl + 89",copyToClipboard:"ctrl + 67"},P.prototype.actions={keyBlock:function(e){e.stopPropagation(),e.preventDefault()},scrollPageUp:function(e){var t=this.table.rowManager,i=t.scrollTop-t.height;t.element.scrollHeight;e.preventDefault(),t.displayRowsCount&&(i>=0?t.element.scrollTop=i:t.scrollToRow(t.getDisplayRows()[0])),this.table.element.focus()},scrollPageDown:function(e){var t=this.table.rowManager,i=t.scrollTop+t.height,n=t.element.scrollHeight;e.preventDefault(),t.displayRowsCount&&(i<=n?t.element.scrollTop=i:t.scrollToRow(t.getDisplayRows()[t.displayRowsCount-1])),this.table.element.focus()},scrollToStart:function(e){var t=this.table.rowManager;e.preventDefault(),t.displayRowsCount&&t.scrollToRow(t.getDisplayRows()[0]),this.table.element.focus()},scrollToEnd:function(e){var t=this.table.rowManager;e.preventDefault(),t.displayRowsCount&&t.scrollToRow(t.getDisplayRows()[t.displayRowsCount-1]),this.table.element.focus()},navPrev:function(e){var t=!1;this.table.modExists("edit")&&(t=this.table.modules.edit.currentCell)&&(e.preventDefault(),t.nav().prev())},navNext:function(e){var t=!1;this.table.modExists("edit")&&(t=this.table.modules.edit.currentCell)&&(e.preventDefault(),t.nav().next())},navLeft:function(e){var t=!1;this.table.modExists("edit")&&(t=this.table.modules.edit.currentCell)&&(e.preventDefault(),t.nav().left())},navRight:function(e){var t=!1;this.table.modExists("edit")&&(t=this.table.modules.edit.currentCell)&&(e.preventDefault(),t.nav().right())},navUp:function(e){var t=!1;this.table.modExists("edit")&&(t=this.table.modules.edit.currentCell)&&(e.preventDefault(),t.nav().up())},navDown:function(e){var t=!1;this.table.modExists("edit")&&(t=this.table.modules.edit.currentCell)&&(e.preventDefault(),t.nav().down())},undo:function(e){this.table.options.history&&this.table.modExists("history")&&this.table.modExists("edit")&&(this.table.modules.edit.currentCell||(e.preventDefault(),this.table.modules.history.undo()))},redo:function(e){this.table.options.history&&this.table.modExists("history")&&this.table.modExists("edit")&&(this.table.modules.edit.currentCell||(e.preventDefault(),this.table.modules.history.redo()))},copyToClipboard:function(e){this.table.modules.edit.currentCell||this.table.modExists("clipboard",!0)&&this.table.modules.clipboard.copy(this.table.options.selectable&&"highlight"!=this.table.options.selectable?"selected":"active",null,null,null,!0)}},h.prototype.registerModule("keybindings",P);var A=function(e){this.table=e,this.placeholderElement=this.createPlaceholderElement(),this.hoverElement=!1,this.checkTimeout=!1,this.checkPeriod=250,this.moving=!1,this.toCol=!1,this.toColAfter=!1,this.startX=0,this.autoScrollMargin=40,this.autoScrollStep=5,this.autoScrollTimeout=!1,this.touchMove=!1,this.moveHover=this.moveHover.bind(this),this.endMove=this.endMove.bind(this)};A.prototype.createPlaceholderElement=function(){var e=document.createElement("div");return e.classList.add("tabulator-col"),e.classList.add("tabulator-col-placeholder"),e},A.prototype.initializeColumn=function(e){var t,i=this,n={};e.modules.frozen||(t=e.getElement(),n.mousemove=function(n){e.parent===i.moving.parent&&((i.touchMove?n.touches[0].pageX:n.pageX)-h.prototype.helpers.elOffset(t).left+i.table.columnManager.element.scrollLeft>e.getWidth()/2?i.toCol===e&&i.toColAfter||(t.parentNode.insertBefore(i.placeholderElement,t.nextSibling),i.moveColumn(e,!0)):(i.toCol!==e||i.toColAfter)&&(t.parentNode.insertBefore(i.placeholderElement,t),i.moveColumn(e,!1)))}.bind(i),t.addEventListener("mousedown",function(t){i.touchMove=!1,1===t.which&&(i.checkTimeout=setTimeout(function(){i.startMove(t,e)},i.checkPeriod))}),t.addEventListener("mouseup",function(e){1===e.which&&i.checkTimeout&&clearTimeout(i.checkTimeout)}),i.bindTouchEvents(e)),e.modules.moveColumn=n},A.prototype.bindTouchEvents=function(e){var t,i,n,o,s,a,r=this,l=e.getElement(),c=!1;l.addEventListener("touchstart",function(l){r.checkTimeout=setTimeout(function(){r.touchMove=!0,e,t=e.nextColumn(),n=t?t.getWidth()/2:0,i=e.prevColumn(),o=i?i.getWidth()/2:0,s=0,a=0,c=!1,r.startMove(l,e)},r.checkPeriod)}),l.addEventListener("touchmove",function(l){var d,u;r.moving&&(r.moveHover(l),c||(c=l.touches[0].pageX),(d=l.touches[0].pageX-c)>0?t&&d-s>n&&(u=t)!==e&&(c=l.touches[0].pageX,u.getElement().parentNode.insertBefore(r.placeholderElement,u.getElement().nextSibling),r.moveColumn(u,!0)):i&&-d-a>o&&(u=i)!==e&&(c=l.touches[0].pageX,u.getElement().parentNode.insertBefore(r.placeholderElement,u.getElement()),r.moveColumn(u,!1)),u&&(u,t=u.nextColumn(),s=n,n=t?t.getWidth()/2:0,i=u.prevColumn(),a=o,o=i?i.getWidth()/2:0))}),l.addEventListener("touchend",function(e){r.checkTimeout&&clearTimeout(r.checkTimeout),r.moving&&r.endMove(e)})},A.prototype.startMove=function(e,t){var i=t.getElement();this.moving=t,this.startX=(this.touchMove?e.touches[0].pageX:e.pageX)-h.prototype.helpers.elOffset(i).left,this.table.element.classList.add("tabulator-block-select"),this.placeholderElement.style.width=t.getWidth()+"px",this.placeholderElement.style.height=t.getHeight()+"px",i.parentNode.insertBefore(this.placeholderElement,i),i.parentNode.removeChild(i),this.hoverElement=i.cloneNode(!0),this.hoverElement.classList.add("tabulator-moving"),this.table.columnManager.getElement().appendChild(this.hoverElement),this.hoverElement.style.left="0",this.hoverElement.style.bottom="0",this.touchMove||(this._bindMouseMove(),document.body.addEventListener("mousemove",this.moveHover),document.body.addEventListener("mouseup",this.endMove)),this.moveHover(e)},A.prototype._bindMouseMove=function(){this.table.columnManager.columnsByIndex.forEach(function(e){e.modules.moveColumn.mousemove&&e.getElement().addEventListener("mousemove",e.modules.moveColumn.mousemove)})},A.prototype._unbindMouseMove=function(){this.table.columnManager.columnsByIndex.forEach(function(e){e.modules.moveColumn.mousemove&&e.getElement().removeEventListener("mousemove",e.modules.moveColumn.mousemove)})},A.prototype.moveColumn=function(e,t){var i=this.moving.getCells();this.toCol=e,this.toColAfter=t,t?e.getCells().forEach(function(e,t){var n=e.getElement();n.parentNode.insertBefore(i[t].getElement(),n.nextSibling)}):e.getCells().forEach(function(e,t){var n=e.getElement();n.parentNode.insertBefore(i[t].getElement(),n)})},A.prototype.endMove=function(e){(1===e.which||this.touchMove)&&(this._unbindMouseMove(),this.placeholderElement.parentNode.insertBefore(this.moving.getElement(),this.placeholderElement.nextSibling),this.placeholderElement.parentNode.removeChild(this.placeholderElement),this.hoverElement.parentNode.removeChild(this.hoverElement),this.table.element.classList.remove("tabulator-block-select"),this.toCol&&this.table.columnManager.moveColumn(this.moving,this.toCol,this.toColAfter),this.moving=!1,this.toCol=!1,this.toColAfter=!1,this.touchMove||(document.body.removeEventListener("mousemove",this.moveHover),document.body.removeEventListener("mouseup",this.endMove)))},A.prototype.moveHover=function(e){var t,i=this,n=i.table.columnManager.getElement(),o=n.scrollLeft,s=(i.touchMove?e.touches[0].pageX:e.pageX)-h.prototype.helpers.elOffset(n).left+o;i.hoverElement.style.left=s-i.startX+"px",s-oe.getHeight()/2?t.toRow===e&&t.toRowAfter||((n=e.getElement()).parentNode.insertBefore(t.placeholderElement,n.nextSibling),t.moveRow(e,!0)):(t.toRow!==e||t.toRowAfter)&&(n=e.getElement()).previousSibling&&(n.parentNode.insertBefore(t.placeholderElement,n),t.moveRow(e,!1))}.bind(t),e.modules.moveRow=i},$.prototype.initializeRow=function(e){var t,i=this,n={};n.mouseup=function(t){i.tableRowDrop(t,e)}.bind(i),n.mousemove=function(t){var n;t.pageY-h.prototype.helpers.elOffset(e.element).top+i.table.rowManager.element.scrollTop>e.getHeight()/2?i.toRow===e&&i.toRowAfter||((n=e.getElement()).parentNode.insertBefore(i.placeholderElement,n.nextSibling),i.moveRow(e,!0)):(i.toRow!==e||i.toRowAfter)&&((n=e.getElement()).parentNode.insertBefore(i.placeholderElement,n),i.moveRow(e,!1))}.bind(i),this.hasHandle||((t=e.getElement()).addEventListener("mousedown",function(t){1===t.which&&(i.checkTimeout=setTimeout(function(){i.startMove(t,e)},i.checkPeriod))}),t.addEventListener("mouseup",function(e){1===e.which&&i.checkTimeout&&clearTimeout(i.checkTimeout)}),this.bindTouchEvents(e,e.getElement())),e.modules.moveRow=n},$.prototype.initializeCell=function(e){var t=this,i=e.getElement();i.addEventListener("mousedown",function(i){1===i.which&&(t.checkTimeout=setTimeout(function(){t.startMove(i,e.row)},t.checkPeriod))}),i.addEventListener("mouseup",function(e){1===e.which&&t.checkTimeout&&clearTimeout(t.checkTimeout)}),this.bindTouchEvents(e.row,e.getElement())},$.prototype.bindTouchEvents=function(e,t){var i,n,o,s,a,r,l=this,c=!1;t.addEventListener("touchstart",function(t){l.checkTimeout=setTimeout(function(){l.touchMove=!0,e,i=e.nextRow(),o=i?i.getHeight()/2:0,n=e.prevRow(),s=n?n.getHeight()/2:0,a=0,r=0,c=!1,l.startMove(t,e)},l.checkPeriod)}),this.moving,this.toRow,this.toRowAfter,t.addEventListener("touchmove",function(t){var d,u;l.moving&&(t.preventDefault(),l.moveHover(t),c||(c=t.touches[0].pageY),(d=t.touches[0].pageY-c)>0?i&&d-a>o&&(u=i)!==e&&(c=t.touches[0].pageY,u.getElement().parentNode.insertBefore(l.placeholderElement,u.getElement().nextSibling),l.moveRow(u,!0)):n&&-d-r>s&&(u=n)!==e&&(c=t.touches[0].pageY,u.getElement().parentNode.insertBefore(l.placeholderElement,u.getElement()),l.moveRow(u,!1)),u&&(u,i=u.nextRow(),a=o,o=i?i.getHeight()/2:0,n=u.prevRow(),r=s,s=n?n.getHeight()/2:0))}),t.addEventListener("touchend",function(e){l.checkTimeout&&clearTimeout(l.checkTimeout),l.moving&&(l.endMove(e),l.touchMove=!1)})},$.prototype._bindMouseMove=function(){this.table.rowManager.getDisplayRows().forEach(function(e){"row"!==e.type&&"group"!==e.type||!e.modules.moveRow.mousemove||e.getElement().addEventListener("mousemove",e.modules.moveRow.mousemove)})},$.prototype._unbindMouseMove=function(){this.table.rowManager.getDisplayRows().forEach(function(e){"row"!==e.type&&"group"!==e.type||!e.modules.moveRow.mousemove||e.getElement().removeEventListener("mousemove",e.modules.moveRow.mousemove)})},$.prototype.startMove=function(e,t){var i=t.getElement();this.setStartPosition(e,t),this.moving=t,this.table.element.classList.add("tabulator-block-select"),this.placeholderElement.style.width=t.getWidth()+"px",this.placeholderElement.style.height=t.getHeight()+"px",this.connection?(this.table.element.classList.add("tabulator-movingrow-sending"),this.connectToTables(t)):(i.parentNode.insertBefore(this.placeholderElement,i),i.parentNode.removeChild(i)),this.hoverElement=i.cloneNode(!0),this.hoverElement.classList.add("tabulator-moving"),this.connection?(document.body.appendChild(this.hoverElement),this.hoverElement.style.left="0",this.hoverElement.style.top="0",this.hoverElement.style.width=this.table.element.clientWidth+"px",this.hoverElement.style.whiteSpace="nowrap",this.hoverElement.style.overflow="hidden",this.hoverElement.style.pointerEvents="none"):(this.table.rowManager.getTableElement().appendChild(this.hoverElement),this.hoverElement.style.left="0",this.hoverElement.style.top="0",this._bindMouseMove()),document.body.addEventListener("mousemove",this.moveHover),document.body.addEventListener("mouseup",this.endMove),this.moveHover(e)},$.prototype.setStartPosition=function(e,t){var i,n,o=this.touchMove?e.touches[0].pageX:e.pageX,s=this.touchMove?e.touches[0].pageY:e.pageY;i=t.getElement(),this.connection?(n=i.getBoundingClientRect(),this.startX=n.left-o+window.scrollX,this.startY=n.top-s+window.scrollY):this.startY=s-i.getBoundingClientRect().top},$.prototype.endMove=function(e){e&&1!==e.which&&!this.touchMove||(this._unbindMouseMove(),this.connection||(this.placeholderElement.parentNode.insertBefore(this.moving.getElement(),this.placeholderElement.nextSibling),this.placeholderElement.parentNode.removeChild(this.placeholderElement)),this.hoverElement.parentNode.removeChild(this.hoverElement),this.table.element.classList.remove("tabulator-block-select"),this.toRow&&this.table.rowManager.moveRow(this.moving,this.toRow,this.toRowAfter),this.moving=!1,this.toRow=!1,this.toRowAfter=!1,document.body.removeEventListener("mousemove",this.moveHover),document.body.removeEventListener("mouseup",this.endMove),this.connection&&(this.table.element.classList.remove("tabulator-movingrow-sending"),this.disconnectFromTables()))},$.prototype.moveRow=function(e,t){this.toRow=e,this.toRowAfter=t},$.prototype.moveHover=function(e){this.connection?this.moveHoverConnections.call(this,e):this.moveHoverTable.call(this,e)},$.prototype.moveHoverTable=function(e){var t=this.table.rowManager.getElement(),i=t.scrollTop,n=(this.touchMove?e.touches[0].pageY:e.pageY)-t.getBoundingClientRect().top+i;this.hoverElement.style.top=n-this.startY+"px"},$.prototype.moveHoverConnections=function(e){this.hoverElement.style.left=this.startX+(this.touchMove?e.touches[0].pageX:e.pageX)+"px",this.hoverElement.style.top=this.startY+(this.touchMove?e.touches[0].pageY:e.pageY)+"px"},$.prototype.connectToTables=function(e){var t=this.table.modules.comms.getConnections(this.connection);this.table.options.movableRowsSendingStart.call(this.table,t),this.table.modules.comms.send(this.connection,"moveRow","connect",{row:e})},$.prototype.disconnectFromTables=function(){var e=this.table.modules.comms.getConnections(this.connection);this.table.options.movableRowsSendingStop.call(this.table,e),this.table.modules.comms.send(this.connection,"moveRow","disconnect")},$.prototype.connect=function(e,t){return this.connectedTable?(console.warn("Move Row Error - Table cannot accept connection, already connected to table:",this.connectedTable),!1):(this.connectedTable=e,this.connectedRow=t,this.table.element.classList.add("tabulator-movingrow-receiving"),this.table.rowManager.getDisplayRows().forEach(function(e){"row"===e.type&&e.modules.moveRow&&e.modules.moveRow.mouseup&&e.getElement().addEventListener("mouseup",e.modules.moveRow.mouseup)}),this.tableRowDropEvent=this.tableRowDrop.bind(this),this.table.element.addEventListener("mouseup",this.tableRowDropEvent),this.table.options.movableRowsReceivingStart.call(this.table,t,e),!0)},$.prototype.disconnect=function(e){e===this.connectedTable?(this.connectedTable=!1,this.connectedRow=!1,this.table.element.classList.remove("tabulator-movingrow-receiving"),this.table.rowManager.getDisplayRows().forEach(function(e){"row"===e.type&&e.modules.moveRow&&e.modules.moveRow.mouseup&&e.getElement().removeEventListener("mouseup",e.modules.moveRow.mouseup)}),this.table.element.removeEventListener("mouseup",this.tableRowDropEvent),this.table.options.movableRowsReceivingStop.call(this.table,e)):console.warn("Move Row Error - trying to disconnect from non connected table")},$.prototype.dropComplete=function(e,t,i){var n=!1;if(i){switch(c(this.table.options.movableRowsSender)){case"string":n=this.senders[this.table.options.movableRowsSender];break;case"function":n=this.table.options.movableRowsSender}n?n.call(this,this.moving.getComponent(),t?t.getComponent():void 0,e):this.table.options.movableRowsSender&&console.warn("Mover Row Error - no matching sender found:",this.table.options.movableRowsSender),this.table.options.movableRowsSent.call(this.table,this.moving.getComponent(),t?t.getComponent():void 0,e)}else this.table.options.movableRowsSentFailed.call(this.table,this.moving.getComponent(),t?t.getComponent():void 0,e);this.endMove()},$.prototype.tableRowDrop=function(e,t){var i=!1,n=!1;switch(e.stopImmediatePropagation(),c(this.table.options.movableRowsReceiver)){case"string":i=this.receivers[this.table.options.movableRowsReceiver];break;case"function":i=this.table.options.movableRowsReceiver}i?n=i.call(this,this.connectedRow.getComponent(),t?t.getComponent():void 0,this.connectedTable):console.warn("Mover Row Error - no matching receiver found:",this.table.options.movableRowsReceiver),n?this.table.options.movableRowsReceived.call(this.table,this.connectedRow.getComponent(),t?t.getComponent():void 0,this.connectedTable):this.table.options.movableRowsReceivedFailed.call(this.table,this.connectedRow.getComponent(),t?t.getComponent():void 0,this.connectedTable),this.table.modules.comms.send(this.connectedTable,"moveRow","dropcomplete",{row:t,success:n})},$.prototype.receivers={insert:function(e,t,i){return this.table.addRow(e.getData(),void 0,t),!0},add:function(e,t,i){return this.table.addRow(e.getData()),!0},update:function(e,t,i){return!!t&&(t.update(e.getData()),!0)},replace:function(e,t,i){return!!t&&(this.table.addRow(e.getData(),void 0,t),t.delete(),!0)}},$.prototype.senders={delete:function(e,t,i){e.delete()}},$.prototype.commsReceived=function(e,t,i){switch(t){case"connect":return this.connect(e,i.row);case"disconnect":return this.disconnect(e);case"dropcomplete":return this.dropComplete(e,i.row,i.success)}},h.prototype.registerModule("moveRow",$);var I=function(e){this.table=e,this.allowedTypes=["","data","edit","clipboard"],this.enabled=!0};I.prototype.initializeColumn=function(e){var t=this,i=!1,n={};this.allowedTypes.forEach(function(o){var s,a="mutator"+(o.charAt(0).toUpperCase()+o.slice(1));e.definition[a]&&(s=t.lookupMutator(e.definition[a]))&&(i=!0,n[a]={mutator:s,params:e.definition[a+"Params"]||{}})}),i&&(e.modules.mutate=n)},I.prototype.lookupMutator=function(e){var t=!1;switch(void 0===e?"undefined":c(e)){case"string":this.mutators[e]?t=this.mutators[e]:console.warn("Mutator Error - No such mutator found, ignoring: ",e);break;case"function":t=e}return t},I.prototype.transformRow=function(e,t,i){var n,o="mutator"+(t.charAt(0).toUpperCase()+t.slice(1));return this.enabled&&this.table.columnManager.traverse(function(s){var a,r,l;s.modules.mutate&&(a=s.modules.mutate[o]||s.modules.mutate.mutator||!1)&&(n=s.getFieldValue(e),(!i||i&&void 0!==n)&&(l=s.getComponent(),r="function"==typeof a.params?a.params(n,e,t,l):a.params,s.setFieldValue(e,a.mutator(n,e,t,r,l))))}),e},I.prototype.transformCell=function(e,t){var i=e.column.modules.mutate.mutatorEdit||e.column.modules.mutate.mutator||!1;return i?i.mutator(t,e.row.getData(),"edit",i.params,e.getComponent()):t},I.prototype.enable=function(){this.enabled=!0},I.prototype.disable=function(){this.enabled=!1},I.prototype.mutators={},h.prototype.registerModule("mutator",I);var z=function(e){this.table=e,this.mode="local",this.progressiveLoad=!1,this.size=0,this.page=1,this.count=5,this.max=1,this.displayIndex=0,this.pageSizes=[],this.createElements()};z.prototype.createElements=function(){var e;this.element=document.createElement("span"),this.element.classList.add("tabulator-paginator"),this.pagesElement=document.createElement("span"),this.pagesElement.classList.add("tabulator-pages"),(e=document.createElement("button")).classList.add("tabulator-page"),e.setAttribute("type","button"),e.setAttribute("role","button"),e.setAttribute("aria-label",""),e.setAttribute("title",""),this.firstBut=e.cloneNode(!0),this.firstBut.setAttribute("data-page","first"),this.prevBut=e.cloneNode(!0),this.prevBut.setAttribute("data-page","prev"),this.nextBut=e.cloneNode(!0),this.nextBut.setAttribute("data-page","next"),this.lastBut=e.cloneNode(!0),this.lastBut.setAttribute("data-page","last"),this.table.options.paginationSizeSelector&&(this.pageSizeSelect=document.createElement("select"),this.pageSizeSelect.classList.add("tabulator-page-size"))},z.prototype.generatePageSizeSelectList=function(){var e=this,t=[];if(this.pageSizeSelect){if(Array.isArray(this.table.options.paginationSizeSelector))t=this.table.options.paginationSizeSelector,this.pageSizes=t,-1==this.pageSizes.indexOf(this.size)&&t.unshift(this.size);else if(-1==this.pageSizes.indexOf(this.size)){t=[];for(var i=1;i<5;i++)t.push(this.size*i);this.pageSizes=t}else t=this.pageSizes;for(;this.pageSizeSelect.firstChild;)this.pageSizeSelect.removeChild(this.pageSizeSelect.firstChild);t.forEach(function(t){var i=document.createElement("option");i.value=t,i.innerHTML=t,e.pageSizeSelect.appendChild(i)}),this.pageSizeSelect.value=this.size}},z.prototype.initialize=function(e){var t,i=this;for(var n in i.table.options.paginationDataSent)i.paginationDataSentNames[n]=i.table.options.paginationDataSent[n];for(var o in i.table.options.paginationDataReceived)i.paginationDataReceivedNames[o]=i.table.options.paginationDataReceived[o];i.table.modules.localize.bind("pagination|first",function(e){i.firstBut.innerHTML=e}),i.table.modules.localize.bind("pagination|first_title",function(e){i.firstBut.setAttribute("aria-label",e),i.firstBut.setAttribute("title",e)}),i.table.modules.localize.bind("pagination|prev",function(e){i.prevBut.innerHTML=e}),i.table.modules.localize.bind("pagination|prev_title",function(e){i.prevBut.setAttribute("aria-label",e),i.prevBut.setAttribute("title",e)}),i.table.modules.localize.bind("pagination|next",function(e){i.nextBut.innerHTML=e}),i.table.modules.localize.bind("pagination|next_title",function(e){i.nextBut.setAttribute("aria-label",e),i.nextBut.setAttribute("title",e)}),i.table.modules.localize.bind("pagination|last",function(e){i.lastBut.innerHTML=e}),i.table.modules.localize.bind("pagination|last_title",function(e){i.lastBut.setAttribute("aria-label",e),i.lastBut.setAttribute("title",e)}),i.firstBut.addEventListener("click",function(){i.setPage(1)}),i.prevBut.addEventListener("click",function(){i.previousPage()}),i.nextBut.addEventListener("click",function(){i.nextPage().then(function(){}).catch(function(){})}),i.lastBut.addEventListener("click",function(){i.setPage(i.max)}),i.table.options.paginationElement&&(i.element=i.table.options.paginationElement),this.pageSizeSelect&&(t=document.createElement("label"),i.table.modules.localize.bind("pagination|page_size",function(e){i.pageSizeSelect.setAttribute("aria-label",e),i.pageSizeSelect.setAttribute("title",e),t.innerHTML=e}),i.element.appendChild(t),i.element.appendChild(i.pageSizeSelect),i.pageSizeSelect.addEventListener("change",function(e){i.setPageSize(i.pageSizeSelect.value),i.setPage(1).then(function(){}).catch(function(){})})),i.element.appendChild(i.firstBut),i.element.appendChild(i.prevBut),i.element.appendChild(i.pagesElement),i.element.appendChild(i.nextBut),i.element.appendChild(i.lastBut),i.table.options.paginationElement||e||i.table.footerManager.append(i.element,i),i.mode=i.table.options.pagination,i.size=i.table.options.paginationSize||Math.floor(i.table.rowManager.getElement().clientHeight/24),i.count=i.table.options.paginationButtonCount,i.generatePageSizeSelectList()},z.prototype.initializeProgressive=function(e){this.initialize(!0),this.mode="progressive_"+e,this.progressiveLoad=!0},z.prototype.setDisplayIndex=function(e){this.displayIndex=e},z.prototype.getDisplayIndex=function(){return this.displayIndex},z.prototype.setMaxRows=function(e){this.max=e?Math.ceil(e/this.size):1,this.page>this.max&&(this.page=this.max)},z.prototype.reset=function(e){return("local"==this.mode||e)&&(this.page=1),!0},z.prototype.setMaxPage=function(e){e=parseInt(e),this.max=e||1,this.page>this.max&&(this.page=this.max,this.trigger())},z.prototype.setPage=function(e){var t=this;return new Promise(function(i,n){(e=parseInt(e))>0&&e<=t.max?(t.page=e,t.trigger().then(function(){i()}).catch(function(){n()})):(console.warn("Pagination Error - Requested page is out of range of 1 - "+t.max+":",e),n())})},z.prototype.setPageToRow=function(e){var t=this;return new Promise(function(i,n){var o=t.table.rowManager.getDisplayRows(t.displayIndex-1).indexOf(e);if(o>-1){var s=Math.ceil((o+1)/t.size);t.setPage(s).then(function(){i()}).catch(function(){n()})}else console.warn("Pagination Error - Requested row is not visible"),n()})},z.prototype.setPageSize=function(e){(e=parseInt(e))>0&&(this.size=e),this.pageSizeSelect&&this.generatePageSizeSelectList()},z.prototype._setPageButtons=function(){for(var e=Math.floor((this.count-1)/2),t=Math.ceil((this.count-1)/2),i=this.max-this.page+e+10&&o<=this.max&&this.pagesElement.appendChild(this._generatePageButton(o));this.footerRedraw()},z.prototype._generatePageButton=function(e){var t=this,i=document.createElement("button");return i.classList.add("tabulator-page"),e==t.page&&i.classList.add("active"),i.setAttribute("type","button"),i.setAttribute("role","button"),i.setAttribute("aria-label","Show Page "+e),i.setAttribute("title","Show Page "+e),i.setAttribute("data-page",e),i.textContent=e,i.addEventListener("click",function(i){t.setPage(e)}),i},z.prototype.previousPage=function(){var e=this;return new Promise(function(t,i){e.page>1?(e.page--,e.trigger().then(function(){t()}).catch(function(){i()})):(console.warn("Pagination Error - Previous page would be less than page 1:",0),i())})},z.prototype.nextPage=function(){var e=this;return new Promise(function(t,i){e.page-1&&((s=(n=n.substr(o)).indexOf(";"))>-1&&(n=n.substr(0,s)),t=n.replace(i+"=",""));break;default:console.warn("Persistance Load Error - invalid mode selected",this.mode)}return!!t&&JSON.parse(t)},F.prototype.mergeDefinition=function(e,t){var i=this,n=[];return(t=t||[]).forEach(function(t,o){var s=i._findColumn(e,t);s&&(s.width=t.width,s.visible=t.visible,s.columns&&(s.columns=i.mergeDefinition(s.columns,t.columns)),n.push(s))}),e.forEach(function(e,o){i._findColumn(t,e)||(n.length>o?n.splice(o,0,e):n.push(e))}),n},F.prototype._findColumn=function(e,t){var i=t.columns?"group":t.field?"field":"object";return e.find(function(e){switch(i){case"group":return e.title===t.title&&e.columns.length===t.columns.length;case"field":return e.field===t.field;case"object":return e===t}})},F.prototype.save=function(e){var t={};switch(e){case"columns":t=this.parseColumns(this.table.columnManager.getColumns());break;case"filter":t=this.table.modules.filter.getFilters();break;case"sort":t=this.validateSorters(this.table.modules.sort.getSort())}var i=this.id+("columns"===e?"":"-"+e);this.saveData(i,t)},F.prototype.validateSorters=function(e){return e.forEach(function(e){e.column=e.field,delete e.field}),e},F.prototype.saveData=function(e,t){switch(t=JSON.stringify(t),this.mode){case"local":localStorage.setItem(e,t);break;case"cookie":var i=new Date;i.setDate(i.getDate()+1e4),document.cookie=e+"="+t+"; expires="+i.toUTCString();break;default:console.warn("Persistance Save Error - invalid mode selected",this.mode)}},F.prototype.parseColumns=function(e){var t=this,i=[];return e.forEach(function(e){var n={};e.isGroup?(n.title=e.getDefinition().title,n.columns=t.parseColumns(e.getColumns())):(n.title=e.getDefinition().title,n.field=e.getField(),n.width=e.getWidth(),n.visible=e.visible),i.push(n)}),i},h.prototype.registerModule("persistence",F);var H=function(e){this.table=e,this.data=!1,this.blocked=!1,this.origFuncs={},this.currentVersion=0};H.prototype.watchData=function(e){var t,i=this;this.currentVersion++,t=this.currentVersion,i.unwatchData(),i.data=e,i.origFuncs.push=e.push,Object.defineProperty(i.data,"push",{enumerable:!1,configurable:!0,value:function(){var n=Array.from(arguments);return i.blocked||t!==i.currentVersion||n.forEach(function(e){i.table.rowManager.addRowActual(e,!1)}),i.origFuncs.push.apply(e,arguments)}}),i.origFuncs.unshift=e.unshift,Object.defineProperty(i.data,"unshift",{enumerable:!1,configurable:!0,value:function(){var n=Array.from(arguments);return i.blocked||t!==i.currentVersion||n.forEach(function(e){i.table.rowManager.addRowActual(e,!0)}),i.origFuncs.unshift.apply(e,arguments)}}),i.origFuncs.shift=e.shift,Object.defineProperty(i.data,"shift",{enumerable:!1,configurable:!0,value:function(){var n;return i.blocked||t!==i.currentVersion||i.data.length&&(n=i.table.rowManager.getRowFromDataObject(i.data[0]))&&n.deleteActual(),i.origFuncs.shift.call(e)}}),i.origFuncs.pop=e.pop,Object.defineProperty(i.data,"pop",{enumerable:!1,configurable:!0,value:function(){var n;return i.blocked||t!==i.currentVersion||i.data.length&&(n=i.table.rowManager.getRowFromDataObject(i.data[i.data.length-1]))&&n.deleteActual(),i.origFuncs.pop.call(e)}}),i.origFuncs.splice=e.splice,Object.defineProperty(i.data,"splice",{enumerable:!1,configurable:!0,value:function(){var n,o=Array.from(arguments),s=o[0]<0?e.length+o[0]:o[0],a=o[1],r=!!o[2]&&o.slice(2);if(!i.blocked&&t===i.currentVersion){if(r&&((n=!!e[s]&&i.table.rowManager.getRowFromDataObject(e[s]))?r.forEach(function(e){i.table.rowManager.addRowActual(e,!0,n,!0)}):(r=r.slice().reverse()).forEach(function(e){i.table.rowManager.addRowActual(e,!0,!1,!0)})),0!==a)e.slice(s,void 0===o[1]?o[1]:s+a).forEach(function(e){var t=i.table.rowManager.getRowFromDataObject(e);t&&t.deleteActual(!0)});(r||0!==a)&&i.table.rowManager.reRenderInPosition()}return i.origFuncs.splice.apply(e,arguments)}})},H.prototype.unwatchData=function(){if(!1!==this.data)for(var e in this.origFuncs)Object.defineProperty(this.data,e,{enumerable:!1,value:this.origFuncs.key})},H.prototype.watchRow=function(e){var t=e.getData();for(var i in this.blocked=!0,t)this.watchKey(e,t,i);this.blocked=!1},H.prototype.watchKey=function(e,t,i){var n=this,o=Object.getOwnPropertyDescriptor(t,i),s=t[i],a=this.currentVersion;Object.defineProperty(t,i,{set:function(t){if(s=t,!n.blocked&&a===n.currentVersion){var r={};r[i]=t,e.updateData(r)}o.set&&o.set(t)},get:function(){return o.get&&o.get(),s}})},H.prototype.unwatchRow=function(e){var t=e.getData();for(var i in t)Object.defineProperty(t,i,{value:t[i]})},H.prototype.block=function(){this.blocked=!0},H.prototype.unblock=function(){this.blocked=!1},h.prototype.registerModule("reactiveData",H);var O=function(e){this.table=e,this.startColumn=!1,this.startX=!1,this.startWidth=!1,this.handle=null,this.prevHandle=null};O.prototype.initializeColumn=function(e,t,i){var n=this,o=!1,s=this.table.options.resizableColumns;if("header"===e&&(o="textarea"==t.definition.formatter||t.definition.variableHeight,t.modules.resize={variableHeight:o}),!0===s||s==e){var a=document.createElement("div");a.className="tabulator-col-resize-handle";var r=document.createElement("div");r.className="tabulator-col-resize-handle prev",a.addEventListener("click",function(e){e.stopPropagation()});var l=function(e){var i=t.getLastColumn();i&&n._checkResizability(i)&&(n.startColumn=t,n._mouseDown(e,i,a))};a.addEventListener("mousedown",l),a.addEventListener("touchstart",l),a.addEventListener("dblclick",function(e){n._checkResizability(t)&&t.reinitializeWidth(!0)}),r.addEventListener("click",function(e){e.stopPropagation()});var c=function(e){var i,o,s;(i=t.getFirstColumn())&&(s=(o=n.table.columnManager.findColumnIndex(i))>0&&n.table.columnManager.getColumnByIndex(o-1))&&n._checkResizability(s)&&(n.startColumn=t,n._mouseDown(e,s,r))};r.addEventListener("mousedown",c),r.addEventListener("touchstart",c),r.addEventListener("dblclick",function(e){var i,o,s;(i=t.getFirstColumn())&&(s=(o=n.table.columnManager.findColumnIndex(i))>0&&n.table.columnManager.getColumnByIndex(o-1))&&n._checkResizability(s)&&s.reinitializeWidth(!0)}),i.appendChild(a),i.appendChild(r)}},O.prototype._checkResizability=function(e){return void 0!==e.definition.resizable?e.definition.resizable:this.table.options.resizableColumns},O.prototype._mouseDown=function(e,t,i){var n=this;function o(e){t.setWidth(n.startWidth+((void 0===e.screenX?e.touches[0].screenX:e.screenX)-n.startX)),!n.table.browserSlow&&t.modules.resize&&t.modules.resize.variableHeight&&t.checkCellHeights()}function s(e){n.startColumn.modules.edit&&(n.startColumn.modules.edit.blocked=!1),n.table.browserSlow&&t.modules.resize&&t.modules.resize.variableHeight&&t.checkCellHeights(),document.body.removeEventListener("mouseup",s),document.body.removeEventListener("mousemove",o),i.removeEventListener("touchmove",o),i.removeEventListener("touchend",s),n.table.element.classList.remove("tabulator-block-select"),n.table.options.persistentLayout&&n.table.modExists("persistence",!0)&&n.table.modules.persistence.save("columns"),n.table.options.columnResized.call(n.table,t.getComponent())}n.table.element.classList.add("tabulator-block-select"),e.stopPropagation(),n.startColumn.modules.edit&&(n.startColumn.modules.edit.blocked=!0),n.startX=void 0===e.screenX?e.touches[0].screenX:e.screenX,n.startWidth=t.getWidth(),document.body.addEventListener("mousemove",o),document.body.addEventListener("mouseup",s),i.addEventListener("touchmove",o),i.addEventListener("touchend",s)},h.prototype.registerModule("resizeColumns",O);var N=function(e){this.table=e,this.startColumn=!1,this.startY=!1,this.startHeight=!1,this.handle=null,this.prevHandle=null};N.prototype.initializeRow=function(e){var t=this,i=e.getElement(),n=document.createElement("div");n.className="tabulator-row-resize-handle";var o=document.createElement("div");o.className="tabulator-row-resize-handle prev",n.addEventListener("click",function(e){e.stopPropagation()});var s=function(i){t.startRow=e,t._mouseDown(i,e,n)};n.addEventListener("mousedown",s),n.addEventListener("touchstart",s),o.addEventListener("click",function(e){e.stopPropagation()});var a=function(i){var n=t.table.rowManager.prevDisplayRow(e);n&&(t.startRow=n,t._mouseDown(i,n,o))};o.addEventListener("mousedown",a),o.addEventListener("touchstart",a),i.appendChild(n),i.appendChild(o)},N.prototype._mouseDown=function(e,t,i){var n=this;function o(e){t.setHeight(n.startHeight+((void 0===e.screenY?e.touches[0].screenY:e.screenY)-n.startY))}function s(e){document.body.removeEventListener("mouseup",o),document.body.removeEventListener("mousemove",o),i.removeEventListener("touchmove",o),i.removeEventListener("touchend",s),n.table.element.classList.remove("tabulator-block-select"),n.table.options.rowResized.call(this.table,t.getComponent())}n.table.element.classList.add("tabulator-block-select"),e.stopPropagation(),n.startY=void 0===e.screenY?e.touches[0].screenY:e.screenY,n.startHeight=t.getHeight(),document.body.addEventListener("mousemove",o),document.body.addEventListener("mouseup",s),i.addEventListener("touchmove",o),i.addEventListener("touchend",s)},h.prototype.registerModule("resizeRows",N);var B=function(e){this.table=e,this.binding=!1,this.observer=!1};B.prototype.initialize=function(e){var t=this.table;"undefined"!=typeof ResizeObserver&&"virtual"===t.rowManager.getRenderMode()?(this.observer=new ResizeObserver(function(e){t.redraw()}),this.observer.observe(t.element)):(this.binding=function(){t.redraw()},window.addEventListener("resize",this.binding))},B.prototype.clearBindings=function(e){this.binding&&window.removeEventListener("resize",this.binding),this.observer&&this.observer.unobserve(this.table.element)},h.prototype.registerModule("resizeTable",B);var j=function(e){this.table=e,this.columns=[],this.hiddenColumns=[],this.mode="",this.index=0,this.collapseFormatter=[],this.collapseStartOpen=!0};j.prototype.initialize=function(){var e=this,t=[];this.mode=this.table.options.responsiveLayout,this.collapseFormatter=this.table.options.responsiveLayoutCollapseFormatter||this.formatCollapsedData,this.collapseStartOpen=this.table.options.responsiveLayoutCollapseStartOpen,this.hiddenColumns=[],this.table.columnManager.columnsByIndex.forEach(function(i,n){i.modules.responsive&&i.modules.responsive.order&&i.modules.responsive.visible&&(i.modules.responsive.index=n,t.push(i),i.visible||"collapse"!==e.mode||e.hiddenColumns.push(i))}),t=(t=t.reverse()).sort(function(e,t){return t.modules.responsive.order-e.modules.responsive.order||t.modules.responsive.index-e.modules.responsive.index}),this.columns=t,"collapse"===this.mode&&this.generateCollapsedContent()},j.prototype.initializeColumn=function(e){var t=e.getDefinition();e.modules.responsive={order:void 0===t.responsive?1:t.responsive,visible:!1!==t.visible}},j.prototype.layoutRow=function(e){var t=e.getElement(),i=document.createElement("div");i.classList.add("tabulator-responsive-collapse"),t.classList.contains("tabulator-calcs")||(e.modules.responsiveLayout={element:i},this.collapseStartOpen||(i.style.display="none"),t.appendChild(i),this.generateCollapsedRowContent(e))},j.prototype.updateColumnVisibility=function(e,t){e.modules.responsive&&(e.modules.responsive.visible=t,this.initialize())},j.prototype.hideColumn=function(e){e.hide(!1,!0),"collapse"===this.mode&&(this.hiddenColumns.unshift(e),this.generateCollapsedContent())},j.prototype.showColumn=function(e){var t;e.show(!1,!0),e.setWidth(e.getWidth()),"collapse"===this.mode&&((t=this.hiddenColumns.indexOf(e))>-1&&this.hiddenColumns.splice(t,1),this.generateCollapsedContent())},j.prototype.update=function(){for(var e=!0;e;){var t="fitColumns"==this.table.modules.layout.getMode()?this.table.columnManager.getFlexBaseWidth():this.table.columnManager.getWidth(),i=this.table.columnManager.element.clientWidth-t;if(i<0){var n=this.columns[this.index];n?(this.hideColumn(n),this.index++):e=!1}else{var o=this.columns[this.index-1];o&&i>0&&i>=o.getWidth()?(this.showColumn(o),this.index--):e=!1}this.table.rowManager.activeRowsCount||this.table.rowManager.renderEmptyScroll()}},j.prototype.generateCollapsedContent=function(){var e=this;this.table.rowManager.getDisplayRows().forEach(function(t){e.generateCollapsedRowContent(t)})},j.prototype.generateCollapsedRowContent=function(e){var t,i;if(e.modules.responsiveLayout){for(t=e.modules.responsiveLayout.element;t.firstChild;)t.removeChild(t.firstChild);(i=this.collapseFormatter(this.generateCollapsedRowData(e)))&&t.appendChild(i)}},j.prototype.generateCollapsedRowData=function(e){var t,i=this,n=e.getData(),o={};return this.hiddenColumns.forEach(function(s){var a=s.getFieldValue(n);s.definition.title&&s.field&&(s.modules.format&&i.table.options.responsiveLayoutCollapseUseFormatters?(t={value:!1,data:{},getValue:function(){return a},getData:function(){return n},getElement:function(){return document.createElement("div")},getRow:function(){return e.getComponent()},getColumn:function(){return s.getComponent()}},o[s.definition.title]=s.modules.format.formatter.call(i.table.modules.format,t,s.modules.format.params)):o[s.definition.title]=a)}),o},j.prototype.formatCollapsedData=function(e){var t=document.createElement("table"),i="";for(var n in e)i+=""+n+""+e[n]+"";return t.innerHTML=i,Object.keys(e).length?t:""},h.prototype.registerModule("responsiveLayout",j);var V=function(e){this.table=e,this.selecting=!1,this.lastClickedRow=!1,this.selectPrev=[],this.selectedRows=[]};V.prototype.clearSelectionData=function(e){this.selecting=!1,this.lastClickedRow=!1,this.selectPrev=[],this.selectedRows=[],e||this._rowSelectionChanged()},V.prototype.initializeRow=function(e){var t=this,i=e.getElement(),n=function e(){setTimeout(function(){t.selecting=!1},50),document.body.removeEventListener("mouseup",e)};e.modules.select={selected:!1},t.table.options.selectableCheck.call(this.table,e.getComponent())?(i.classList.add("tabulator-selectable"),i.classList.remove("tabulator-unselectable"),t.table.options.selectable&&"highlight"!=t.table.options.selectable&&(t.table.options.selectableRangeMode&&"click"===t.table.options.selectableRangeMode?i.addEventListener("click",function(i){if(i.shiftKey){t.lastClickedRow=t.lastClickedRow||e;var n=t.table.rowManager.getDisplayRowIndex(t.lastClickedRow),o=t.table.rowManager.getDisplayRowIndex(e),s=n<=o?n:o,a=n>=o?n:o,r=t.table.rowManager.getDisplayRows().slice(0).splice(s,a-s+1);i.ctrlKey?(r.forEach(function(e){e!==t.lastClickedRow&&t.toggleRow(e)}),t.lastClickedRow=e):(t.deselectRows(),t.selectRows(r))}else i.ctrlKey?(t.toggleRow(e),t.lastClickedRow=e):(t.deselectRows(),t.selectRows(e),t.lastClickedRow=e)}):(i.addEventListener("click",function(i){t.selecting||t.toggleRow(e)}),i.addEventListener("mousedown",function(i){if(i.shiftKey)return t.selecting=!0,t.selectPrev=[],document.body.addEventListener("mouseup",n),document.body.addEventListener("keyup",n),t.toggleRow(e),!1}),i.addEventListener("mouseenter",function(i){t.selecting&&(t.toggleRow(e),t.selectPrev[1]==e&&t.toggleRow(t.selectPrev[0]))}),i.addEventListener("mouseout",function(i){t.selecting&&t.selectPrev.unshift(e)})))):(i.classList.add("tabulator-unselectable"),i.classList.remove("tabulator-selectable"))},V.prototype.toggleRow=function(e){this.table.options.selectableCheck.call(this.table,e.getComponent())&&(e.modules.select&&e.modules.select.selected?this._deselectRow(e):this._selectRow(e))},V.prototype.selectRows=function(e){var t=this;switch(void 0===e?"undefined":c(e)){case"undefined":t.table.rowManager.rows.forEach(function(e){t._selectRow(e,!0,!0)}),t._rowSelectionChanged();break;case"boolean":!0===e&&(t.table.rowManager.activeRows.forEach(function(e){t._selectRow(e,!0,!0)}),t._rowSelectionChanged());break;default:Array.isArray(e)?(e.forEach(function(e){t._selectRow(e,!0,!0)}),t._rowSelectionChanged()):t._selectRow(e,!1,!0)}},V.prototype._selectRow=function(e,t,i){if(!isNaN(this.table.options.selectable)&&!0!==this.table.options.selectable&&!i&&this.selectedRows.length>=this.table.options.selectable){if(!this.table.options.selectableRollingSelection)return!1;this._deselectRow(this.selectedRows[0])}var n=this.table.rowManager.findRow(e);n?-1==this.selectedRows.indexOf(n)&&(n.modules.select||(n.modules.select={}),n.modules.select.selected=!0,n.getElement().classList.add("tabulator-selected"),this.selectedRows.push(n),t||(this.table.options.rowSelected.call(this.table,n.getComponent()),this._rowSelectionChanged())):t||console.warn("Selection Error - No such row found, ignoring selection:"+e)},V.prototype.isRowSelected=function(e){return-1!==this.selectedRows.indexOf(e)},V.prototype.deselectRows=function(e){var t,i=this;if(void 0===e){t=i.selectedRows.length;for(var n=0;n-1&&(n.modules.select||(n.modules.select={}),n.modules.select.selected=!1,n.getElement().classList.remove("tabulator-selected"),this.selectedRows.splice(i,1),t||(this.table.options.rowDeselected.call(this.table,n.getComponent()),this._rowSelectionChanged())):t||console.warn("Deselection Error - No such row found, ignoring selection:"+e)},V.prototype.getSelectedData=function(){var e=[];return this.selectedRows.forEach(function(t){e.push(t.getData())}),e},V.prototype.getSelectedRows=function(){var e=[];return this.selectedRows.forEach(function(t){e.push(t.getComponent())}),e},V.prototype._rowSelectionChanged=function(){this.table.options.rowSelectionChanged.call(this.table,this.getSelectedData(),this.getSelectedRows())},h.prototype.registerModule("selectRow",V);var q=function(e){this.table=e,this.sortList=[],this.changed=!1};q.prototype.initializeColumn=function(e,t){var i,n,o=this,s=!1;switch(c(e.definition.sorter)){case"string":o.sorters[e.definition.sorter]?s=o.sorters[e.definition.sorter]:console.warn("Sort Error - No such sorter found: ",e.definition.sorter);break;case"function":s=e.definition.sorter}e.modules.sort={sorter:s,dir:"none",params:e.definition.sorterParams||{},startingDir:e.definition.headerSortStartingDir||"asc",tristate:e.definition.headerSortTristate},!1!==e.definition.headerSort&&((i=e.getElement()).classList.add("tabulator-sortable"),(n=document.createElement("div")).classList.add("tabulator-arrow"),t.appendChild(n),i.addEventListener("click",function(t){var i="",n=[],s=!1;if(e.modules.sort){if(e.modules.sort.tristate)i="none"==e.modules.sort.dir?e.modules.sort.startingDir:e.modules.sort.dir==e.modules.sort.startingDir?"asc"==e.modules.sort.dir?"desc":"asc":"none";else switch(e.modules.sort.dir){case"asc":i="desc";break;case"desc":i="asc";break;default:i=e.modules.sort.startingDir}o.table.options.columnHeaderSortMulti&&(t.shiftKey||t.ctrlKey)?((s=(n=o.getSort()).findIndex(function(t){return t.field===e.getField()}))>-1?(n[s].dir=i,s!=n.length-1&&(s=n.splice(s,1)[0],"none"!=i&&n.push(s))):"none"!=i&&n.push({column:e,dir:i}),o.setSort(n)):"none"==i?o.clear():o.setSort(e,i),o.table.rowManager.sorterRefresh(!o.sortList.length)}}))},q.prototype.hasChanged=function(){var e=this.changed;return this.changed=!1,e},q.prototype.getSort=function(){var e=[];return this.sortList.forEach(function(t){t.column&&e.push({column:t.column.getComponent(),field:t.column.getField(),dir:t.dir})}),e},q.prototype.setSort=function(e,t){var i=this,n=[];Array.isArray(e)||(e=[{column:e,dir:t}]),e.forEach(function(e){var t;(t=i.table.columnManager.findColumn(e.column))?(e.column=t,n.push(e),i.changed=!0):console.warn("Sort Warning - Sort field does not exist and is being ignored: ",e.column)}),i.sortList=n,this.table.options.persistentSort&&this.table.modExists("persistence",!0)&&this.table.modules.persistence.save("sort")},q.prototype.clear=function(){this.setSort([])},q.prototype.findSorter=function(e){var t,i=this.table.rowManager.activeRows[0],n="string";if(i&&(i=i.getData(),e.getField()))switch(void 0===(t=e.getFieldValue(i))?"undefined":c(t)){case"undefined":n="string";break;case"boolean":n="boolean";break;default:isNaN(t)||""===t?t.match(/((^[0-9]+[a-z]+)|(^[a-z]+[0-9]+))+$/i)&&(n="alphanum"):n="number"}return this.sorters[n]},q.prototype.sort=function(e){var t,i=this;t=this.table.options.sortOrderReverse?i.sortList.slice().reverse():i.sortList,i.table.options.dataSorting&&i.table.options.dataSorting.call(i.table,i.getSort()),i.clearColumnHeaders(),i.table.options.ajaxSorting?t.forEach(function(e,t){i.setColumnHeader(e.column,e.dir)}):t.forEach(function(n,o){n.column&&n.column.modules.sort&&(n.column.modules.sort.sorter||(n.column.modules.sort.sorter=i.findSorter(n.column)),i._sortItem(e,n.column,n.dir,t,o)),i.setColumnHeader(n.column,n.dir)}),i.table.options.dataSorted&&i.table.options.dataSorted.call(i.table,i.getSort(),i.table.rowManager.getComponents(!0))},q.prototype.clearColumnHeaders=function(){this.table.columnManager.getRealColumns().forEach(function(e){e.modules.sort&&(e.modules.sort.dir="none",e.getElement().setAttribute("aria-sort","none"))})},q.prototype.setColumnHeader=function(e,t){e.modules.sort.dir=t,e.getElement().setAttribute("aria-sort",t)},q.prototype._sortItem=function(e,t,i,n,o){var s=this,a="function"==typeof t.modules.sort.params?t.modules.sort.params(t.getComponent(),i):t.modules.sort.params;e.sort(function(e,r){var l=s._sortRow(e,r,t,i,a);if(0===l&&o)for(var c=o-1;c>=0&&0===(l=s._sortRow(e,r,n[c].column,n[c].dir,a));c--);return l})},q.prototype._sortRow=function(e,t,i,n,o){var s,a,r="asc"==n?e:t,l="asc"==n?t:e;return e=void 0!==(e=i.getFieldValue(r.getData()))?e:"",t=void 0!==(t=i.getFieldValue(l.getData()))?t:"",s=r.getComponent(),a=l.getComponent(),i.modules.sort.sorter.call(this,e,t,s,a,i.getComponent(),n,o)},q.prototype.sorters={number:function(e,t,i,n,o,s,a){var r=a.alignEmptyValues,l=a.decimalSeparator||".",c=a.thousandSeparator||",",d=0;if(e=parseFloat(String(e).split(c).join("").split(l).join(".")),t=parseFloat(String(t).split(c).join("").split(l).join(".")),isNaN(e))d=isNaN(t)?0:-1;else{if(!isNaN(t))return e-t;d=1}return("top"===r&&"desc"===s||"bottom"===r&&"asc"===s)&&(d*=-1),d},string:function(e,t,i,n,o,s,a){var r,l=a.alignEmptyValues,d=0;if(e){if(t){switch(c(a.locale)){case"boolean":a.locale&&(r=this.table.modules.localize.getLocale());break;case"string":r=a.locale}return String(e).toLowerCase().localeCompare(String(t).toLowerCase(),r)}d=1}else d=t?-1:0;return("top"===l&&"desc"===s||"bottom"===l&&"asc"===s)&&(d*=-1),d},date:function(e,t,i,n,o,s,a){return a.format||(a.format="DD/MM/YYYY"),this.sorters.datetime.call(this,e,t,i,n,o,s,a)},time:function(e,t,i,n,o,s,a){return a.format||(a.format="hh:mm"),this.sorters.datetime.call(this,e,t,i,n,o,s,a)},datetime:function(e,t,i,n,o,s,a){var r=a.format||"DD/MM/YYYY hh:mm:ss",l=a.alignEmptyValues,c=0;if("undefined"!=typeof moment){if(e=moment(e,r),t=moment(t,r),e.isValid()){if(t.isValid())return e-t;c=1}else c=t.isValid()?-1:0;return("top"===l&&"desc"===s||"bottom"===l&&"asc"===s)&&(c*=-1),c}console.error("Sort Error - 'datetime' sorter is dependant on moment.js")},boolean:function(e,t,i,n,o,s,a){return(!0===e||"true"===e||"True"===e||1===e?1:0)-(!0===t||"true"===t||"True"===t||1===t?1:0)},array:function(e,t,i,n,o,s,a){var r=a.type||"length",l=a.alignEmptyValues,c=0;function d(e){switch(r){case"length":return e.length;case"sum":return e.reduce(function(e,t){return e+t});case"max":return Math.max.apply(null,e);case"min":return Math.min.apply(null,e);case"avg":return e.reduce(function(e,t){return e+t})/e.length}}if(Array.isArray(e)){if(Array.isArray(t))return(e?d(e):0)-(t?d(t):0);l=1}else l=Array.isArray(t)?-1:0;return("top"===l&&"desc"===s||"bottom"===l&&"asc"===s)&&(c*=-1),c},exists:function(e,t,i,n,o,s,a){return(void 0===e?0:1)-(void 0===t?0:1)},alphanum:function(e,t,i,n,o,s,a){var r,l,c,d,u,h=0,p=/(\d+)|(\D+)/g,f=/\d/,m=a.alignEmptyValues,g=0;if(e||0===e){if(t||0===t){if(isFinite(e)&&isFinite(t))return e-t;if((r=String(e).toLowerCase())===(l=String(t).toLowerCase()))return 0;if(!f.test(r)||!f.test(l))return r>l?1:-1;for(r=r.match(p),l=l.match(p),u=r.length>l.length?l.length:r.length;hd?1:-1;return r.length>l.length}g=1}else g=t||0===t?-1:0;return("top"===m&&"desc"===s||"bottom"===m&&"asc"===s)&&(g*=-1),g}},h.prototype.registerModule("sort",q);var W=function(e){this.table=e};return W.prototype.initializeColumn=function(e){var t,i=this,n=[];e.definition.validator&&(Array.isArray(e.definition.validator)?e.definition.validator.forEach(function(e){(t=i._extractValidator(e))&&n.push(t)}):(t=this._extractValidator(e.definition.validator))&&n.push(t),e.modules.validate=!!n.length&&n)},W.prototype._extractValidator=function(e){var t,i,n;switch(void 0===e?"undefined":c(e)){case"string":return i=(t=e.split(":",2)).shift(),n=t[0],this._buildValidator(i,n);case"function":return this._buildValidator(e);case"object":return this._buildValidator(e.type,e.parameters)}},W.prototype._buildValidator=function(e,t){var i="function"==typeof e?e:this.validators[e];return i?{type:"function"==typeof e?"function":e,func:i,params:t}:(console.warn("Validator Setup Error - No matching validator found:",e),!1)},W.prototype.validate=function(e,t,i){var n=this,o=[];return e&&e.forEach(function(e){e.func.call(n,t,i,e.params)||o.push({type:e.type,parameters:e.params})}),!o.length||o},W.prototype.validators={integer:function(e,t,i){return""===t||null==t||"number"==typeof(t=Number(t))&&isFinite(t)&&Math.floor(t)===t},float:function(e,t,i){return""===t||null==t||"number"==typeof(t=Number(t))&&isFinite(t)&&t%1!=0},numeric:function(e,t,i){return""===t||null==t||!isNaN(t)},string:function(e,t,i){return""===t||null==t||isNaN(t)},max:function(e,t,i){return""===t||null==t||parseFloat(t)<=i},min:function(e,t,i){return""===t||null==t||parseFloat(t)>=i},minLength:function(e,t,i){return""===t||null==t||String(t).length>=i},maxLength:function(e,t,i){return""===t||null==t||String(t).length<=i},in:function(e,t,i){return""===t||null==t||("string"==typeof i&&(i=i.split("|")),""===t||i.indexOf(t)>-1)},regex:function(e,t,i){return""===t||null==t||new RegExp(i).test(t)},unique:function(e,t,i){if(""===t||null==t)return!0;var n=!0,o=e.getData(),s=e.getColumn()._getSelf();return this.table.rowManager.rows.forEach(function(e){var i=e.getData();i!==o&&t==s.getFieldValue(i)&&(n=!1)}),n},required:function(e,t,i){return""!==t&null!==t&&void 0!==t}},h.prototype.registerModule("validate",W),h},"object"===c(n)&&void 0!==t?t.exports=l():void 0===(a="function"==typeof(s=l)?s.call(n,o,n,t):s)||(t.exports=a)},49:function(e,t,i){"use strict";(function(e){var t=i(36),n=i(28),o=function(){if("undefined"!=typeof self)return self;if("undefined"!=typeof window)return window;if(void 0!==e)return e;throw new Error("unable to locate global object")}();"Promise"in o?o.Promise.prototype.finally||(o.Promise.prototype.finally=n.a):o.Promise=t.a}).call(this,i(27))},50:function(e,t,i){(function(e){var n=void 0!==e&&e||"undefined"!=typeof self&&self||window,o=Function.prototype.apply;function s(e,t){this._id=e,this._clearFn=t}t.setTimeout=function(){return new s(o.call(setTimeout,n,arguments),clearTimeout)},t.setInterval=function(){return new s(o.call(setInterval,n,arguments),clearInterval)},t.clearTimeout=t.clearInterval=function(e){e&&e.close()},s.prototype.unref=s.prototype.ref=function(){},s.prototype.close=function(){this._clearFn.call(n,this._id)},t.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},t.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},t._unrefActive=t.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},i(51),t.setImmediate="undefined"!=typeof self&&self.setImmediate||void 0!==e&&e.setImmediate||this&&this.setImmediate,t.clearImmediate="undefined"!=typeof self&&self.clearImmediate||void 0!==e&&e.clearImmediate||this&&this.clearImmediate}).call(this,i(27))},51:function(e,t,i){(function(e,t){!function(e,i){"use strict";if(!e.setImmediate){var n,o,s,a,r,l=1,c={},d=!1,u=e.document,h=Object.getPrototypeOf&&Object.getPrototypeOf(e);h=h&&h.setTimeout?h:e,"[object process]"==={}.toString.call(e.process)?n=function(e){t.nextTick(function(){f(e)})}:!function(){if(e.postMessage&&!e.importScripts){var t=!0,i=e.onmessage;return e.onmessage=function(){t=!1},e.postMessage("","*"),e.onmessage=i,t}}()?e.MessageChannel?((s=new MessageChannel).port1.onmessage=function(e){f(e.data)},n=function(e){s.port2.postMessage(e)}):u&&"onreadystatechange"in u.createElement("script")?(o=u.documentElement,n=function(e){var t=u.createElement("script");t.onreadystatechange=function(){f(e),t.onreadystatechange=null,o.removeChild(t),t=null},o.appendChild(t)}):n=function(e){setTimeout(f,0,e)}:(a="setImmediate$"+Math.random()+"$",r=function(t){t.source===e&&"string"==typeof t.data&&0===t.data.indexOf(a)&&f(+t.data.slice(a.length))},e.addEventListener?e.addEventListener("message",r,!1):e.attachEvent("onmessage",r),n=function(t){e.postMessage(a+t,"*")}),h.setImmediate=function(e){"function"!=typeof e&&(e=new Function(""+e));for(var t=new Array(arguments.length-1),i=0;i1)for(var i=1;i"7.3.2"||(t[l]=function(e,t,i){return this.$menu=e,this._api=["bind","getInstance","initPanels","openPanel","closePanel","closeAllPanels","setSelected"],this.opts=t,this.conf=i,this.vars={},this.cbck={},this.mtch={},"function"==typeof this.___deprecated&&this.___deprecated(),this._initWrappers(),this._initAddons(),this._initExtensions(),this._initHooks(),this._initMenu(),this._initPanels(),this._initOpened(),this._initAnchors(),this._initMatchMedia(),"function"==typeof this.___debug&&this.___debug(),this},t[l].version="7.3.2",t[l].uniqueId=0,t[l].wrappers={},t[l].addons={},t[l].defaults={hooks:{},extensions:[],wrappers:[],navbar:{add:!0,title:"Menu",titleLink:"parent"},onClick:{setSelected:!0},slidingSubmenus:!0},t[l].configuration={classNames:{divider:"Divider",inset:"Inset",nolistview:"NoListview",nopanel:"NoPanel",panel:"Panel",selected:"Selected",spacer:"Spacer",vertical:"Vertical"},clone:!1,language:null,openingInterval:25,panelNodetype:"ul, ol, div",transitionDuration:400},t[l].prototype={getInstance:function(){return this},initPanels:function(e){this._initPanels(e)},openPanel:function(e,i){if(this.trigger("openPanel:before",e),e&&e.length&&(e.is("."+n.panel)||(e=e.closest("."+n.panel)),e.is("."+n.panel))){var s=this;if("boolean"!=typeof i&&(i=!0),e.parent("."+n.listitem+"_vertical").length)e.parents("."+n.listitem+"_vertical").addClass(n.listitem+"_opened").children("."+n.panel).removeClass(n.hidden),this.openPanel(e.parents("."+n.panel).not(function(){return t(this).parent("."+n.listitem+"_vertical").length}).first()),this.trigger("openPanel:start",e),this.trigger("openPanel:finish",e);else{if(e.hasClass(n.panel+"_opened"))return;var a=this.$pnls.children("."+n.panel),r=this.$pnls.children("."+n.panel+"_opened");if(!t[l].support.csstransitions)return r.addClass(n.hidden).removeClass(n.panel+"_opened"),e.removeClass(n.hidden).addClass(n.panel+"_opened"),this.trigger("openPanel:start",e),void this.trigger("openPanel:finish",e);a.not(e).removeClass(n.panel+"_opened-parent");for(var c=e.data(o.parent);c;)(c=c.closest("."+n.panel)).parent("."+n.listitem+"_vertical").length||c.addClass(n.panel+"_opened-parent"),c=c.data(o.parent);a.removeClass(n.panel+"_highest").not(r).not(e).addClass(n.hidden),e.removeClass(n.hidden);var d=function(){r.removeClass(n.panel+"_opened"),e.addClass(n.panel+"_opened"),e.hasClass(n.panel+"_opened-parent")?(r.addClass(n.panel+"_highest"),e.removeClass(n.panel+"_opened-parent")):(r.addClass(n.panel+"_opened-parent"),e.addClass(n.panel+"_highest")),s.trigger("openPanel:start",e)},u=function(){r.removeClass(n.panel+"_highest").addClass(n.hidden),e.removeClass(n.panel+"_highest"),s.trigger("openPanel:finish",e)};i&&!e.hasClass(n.panel+"_noanimation")?setTimeout(function(){s.__transitionend(e,function(){u()},s.conf.transitionDuration),d()},s.conf.openingInterval):(d(),u())}this.trigger("openPanel:after",e)}},closePanel:function(e){this.trigger("closePanel:before",e);var t=e.parent();t.hasClass(n.listitem+"_vertical")&&(t.removeClass(n.listitem+"_opened"),e.addClass(n.hidden),this.trigger("closePanel",e)),this.trigger("closePanel:after",e)},closeAllPanels:function(e){this.trigger("closeAllPanels:before"),this.$pnls.find("."+n.listview).children().removeClass(n.listitem+"_selected").filter("."+n.listitem+"_vertical").removeClass(n.listitem+"_opened");var t=this.$pnls.children("."+n.panel),i=e&&e.length?e:t.first();this.$pnls.children("."+n.panel).not(i).removeClass(n.panel+"_opened").removeClass(n.panel+"_opened-parent").removeClass(n.panel+"_highest").addClass(n.hidden),this.openPanel(i,!1),this.trigger("closeAllPanels:after")},togglePanel:function(e){var t=e.parent();t.hasClass(n.listitem+"_vertical")&&this[t.hasClass(n.listitem+"_opened")?"closePanel":"openPanel"](e)},setSelected:function(e){this.trigger("setSelected:before",e),this.$menu.find("."+n.listitem+"_selected").removeClass(n.listitem+"_selected"),e.addClass(n.listitem+"_selected"),this.trigger("setSelected:after",e)},bind:function(e,t){this.cbck[e]=this.cbck[e]||[],this.cbck[e].push(t)},trigger:function(){var e=Array.prototype.slice.call(arguments),t=e.shift();if(this.cbck[t])for(var i=0,n=this.cbck[t].length;i').append(this.$menu.children(this.conf.panelNodetype)).prependTo(this.$menu),this.$menu.addClass(n.menu).parent().addClass(n.wrapper),this.trigger("initMenu:after")},_initPanels:function(e){this.trigger("initPanels:before",e),e=e||this.$pnls.children(this.conf.panelNodetype);var i=t(),o=this;(function e(s){s.filter(o.conf.panelNodetype).each(function(s){var a=o._initPanel(t(this));if(a){o._initNavbar(a),o._initListview(a),i=i.add(a);var r=a.children("."+n.listview).children("li").children(o.conf.panelNodetype).add(a.children("."+o.conf.classNames.panel));r.length&&e(r)}})})(e),this.trigger("initPanels:after",i)},_initPanel:function(e){if(this.trigger("initPanel:before",e),e.hasClass(n.panel))return e;if(this.__refactorClass(e,this.conf.classNames.panel,n.panel),this.__refactorClass(e,this.conf.classNames.nopanel,n.nopanel),this.__refactorClass(e,this.conf.classNames.inset,n.listview+"_inset"),e.filter("."+n.listview+"_inset").addClass(n.nopanel),e.hasClass(n.nopanel))return!1;var t=e.hasClass(this.conf.classNames.vertical)||!this.opts.slidingSubmenus;e.removeClass(this.conf.classNames.vertical);var i=e.attr("id")||this.__getUniqueId();e.is("ul, ol")&&(e.removeAttr("id"),e.wrap("
"),e=e.parent()),e.attr("id",i),e.addClass(n.panel+" "+n.hidden);var s=e.parent("li");return t?s.addClass(n.listitem+"_vertical"):e.appendTo(this.$pnls),s.length&&(s.data(o.child,e),e.data(o.parent,s)),this.trigger("initPanel:after",e),e},_initNavbar:function(e){if(this.trigger("initNavbar:before",e),!e.children("."+n.navbar).length){var i=e.data(o.parent),s=t('
'),a=this.__getPanelTitle(e,this.opts.navbar.title),r="";if(i&&i.length){if(i.hasClass(n.listitem+"_vertical"))return;if(i.parent().is("."+n.listview))var l=i.children("a, span").not("."+n.btn+"_next");else l=i.closest("."+n.panel).find('a[href="#'+e.attr("id")+'"]');var c=(i=(l=l.first()).closest("."+n.panel)).attr("id");switch(a=this.__getPanelTitle(e,t(""+l.text()+"").text()),this.opts.navbar.titleLink){case"anchor":r=l.attr("href")||"";break;case"parent":r="#"+c}s.append('')}else if(!this.opts.navbar.title)return;this.opts.navbar.add&&e.addClass(n.panel+"_has-navbar"),s.append('"+a+"").prependTo(e),this.trigger("initNavbar:after",e)}},_initListview:function(e){this.trigger("initListview:before",e);var i=this.__childAddBack(e,"ul, ol");this.__refactorClass(i,this.conf.classNames.nolistview,n.nolistview);var s=i.not("."+n.nolistview).addClass(n.listview).children().addClass(n.listitem);this.__refactorClass(s,this.conf.classNames.selected,n.listitem+"_selected"),this.__refactorClass(s,this.conf.classNames.divider,n.listitem+"_divider"),this.__refactorClass(s,this.conf.classNames.spacer,n.listitem+"_spacer"),s.children("a, span").not("."+n.btn).addClass(n.listitem+"__text");var a=e.data(o.parent);if(a&&a.is("."+n.listitem)&&!a.children("."+n.btn).length){var r=a.children("a, span").first(),l=t('');l.insertAfter(r),r.is("span")&&(l.addClass(n.listitem+"__text").html(r.html()),r.remove())}this.trigger("initListview:after",e)},_initOpened:function(){this.trigger("initOpened:before");var e=this.$pnls.find("."+n.listitem+"_selected").removeClass(n.listitem+"_selected").last().addClass(n.listitem+"_selected"),t=e.length?e.closest("."+n.panel):this.$pnls.children("."+n.panel).first();this.openPanel(t,!1),this.trigger("initOpened:after")},_initAnchors:function(){this.trigger("initAnchors:before");var e=this;r.$body.on(s.click+"-oncanvas","a[href]",function(i){var o=t(this),s=o.attr("href"),r=e.$menu.find(o).length,c=o.is("."+n.listitem+" > a"),d=o.is('[rel="external"]')||o.is('[target="_blank"]');if(r&&s.length>1&&"#"==s.slice(0,1))try{var u=e.$menu.find(s);if(u.is("."+n.panel))return e[o.parent().hasClass(n.listitem+"_vertical")?"togglePanel":"openPanel"](u),void i.preventDefault()}catch(e){}var h={close:null,setSelected:null,preventDefault:"#"==s.slice(0,1)};for(var p in t[l].addons){var f=t[l].addons[p].clickAnchor.call(e,o,r,c,d);if(f){if("boolean"==typeof f)return void i.preventDefault();"object"==a(f)&&(h=t.extend({},h,f))}}r&&c&&!d&&(e.__valueOrFn(o,e.opts.onClick.setSelected,h.setSelected)&&e.setSelected(t(i.target).parent()),e.__valueOrFn(o,e.opts.onClick.preventDefault,h.preventDefault)&&i.preventDefault(),e.__valueOrFn(o,e.opts.onClick.close,h.close)&&e.opts.offCanvas&&"function"==typeof e.close&&e.close())}),this.trigger("initAnchors:after")},_initMatchMedia:function(){var e=this;for(var t in this.mtch)!function(){var i=t,n=window.matchMedia(i);e._fireMatchMedia(i,n),n.addListener(function(t){e._fireMatchMedia(i,t)})}()},_fireMatchMedia:function(e,t){for(var i=t.matches?"yes":"no",n=0;n1&&a.page.wrapIfNeeded&&(i=i.wrapAll("<"+this.conf[s].page.nodetype+" />").parent())),i.addClass(t.page+" "+t.slideout).each(function(){e(this).attr("id",e(this).attr("id")||n.__getUniqueId())}),o.$page=i,this.trigger("setPage:after",i)},e.mmenu.prototype._initWindow_offCanvas=function(){o.$wndw.off(n.keydown+"-"+s).on(n.keydown+"-"+s,function(e){if(o.$html.hasClass(t.wrapper+"_opened")&&9==e.keyCode)return e.preventDefault(),!1});var e=0;o.$wndw.off(n.resize+"-"+s).on(n.resize+"-"+s,function(i,n){if(1==o.$page.length&&(n||o.$html.hasClass(t.wrapper+"_opened"))){var s=o.$wndw.height();(n||s!=e)&&(e=s,o.$page.css("minHeight",s))}})},e.mmenu.prototype._initBlocker=function(){var i=this,a=this.opts[s],r=this.conf[s];this.trigger("initBlocker:before"),a.blockUI&&(o.$blck||(o.$blck=e('
').append("")),o.$blck.appendTo(r.menu.insertSelector).off(n.touchstart+"-"+s+" "+n.touchmove+"-"+s).on(n.touchstart+"-"+s+" "+n.touchmove+"-"+s,function(e){e.preventDefault(),e.stopPropagation(),o.$blck.trigger(n.mousedown+"-"+s)}).off(n.mousedown+"-"+s).on(n.mousedown+"-"+s,function(e){e.preventDefault(),o.$html.hasClass(t.wrapper+"_modal")||(i.closeAllOthers(),i.close())}),this.trigger("initBlocker:after"))}}(e),function(e){var t,i,n="screenReader";e.mmenu.addons[n]={setup:function(){var o=this,s=this.opts[n],r=this.conf[n];e.mmenu.glbl,"boolean"==typeof s&&(s={aria:s,text:s}),"object"!=a(s)&&(s={}),(s=this.opts[n]=e.extend(!0,{},e.mmenu.defaults[n],s)).aria&&(this.bind("initAddons:after",function(){this.bind("initMenu:after",function(){this.trigger("initMenu:after:sr-aria")}),this.bind("initNavbar:after",function(){this.trigger("initNavbar:after:sr-aria",arguments[0])}),this.bind("openPanel:start",function(){this.trigger("openPanel:start:sr-aria",arguments[0])}),this.bind("close:start",function(){this.trigger("close:start:sr-aria")}),this.bind("close:finish",function(){this.trigger("close:finish:sr-aria")}),this.bind("open:start",function(){this.trigger("open:start:sr-aria")}),this.bind("initOpened:after",function(){this.trigger("initOpened:after:sr-aria")})}),this.bind("updateListview",function(){this.$pnls.find("."+t.listview).children().each(function(){o.__sr_aria(e(this),"hidden",e(this).is("."+t.hidden))})}),this.bind("openPanel:start",function(e){var i=this.$menu.find("."+t.panel).not(e).not(e.parents("."+t.panel)),n=e.add(e.find("."+t.listitem+"_vertical ."+t.listitem+"_opened").children("."+t.panel));this.__sr_aria(i,"hidden",!0),this.__sr_aria(n,"hidden",!1)}),this.bind("closePanel",function(e){this.__sr_aria(e,"hidden",!0)}),this.bind("initPanels:after",function(i){var n=i.find("."+t.btn).each(function(){o.__sr_aria(e(this),"owns",e(this).attr("href").replace("#",""))});this.__sr_aria(n,"haspopup",!0)}),this.bind("initNavbar:after",function(e){var i=e.children("."+t.navbar);this.__sr_aria(i,"hidden",!e.hasClass(t.panel+"_has-navbar"))}),s.text&&"parent"==this.opts.navbar.titleLink&&this.bind("initNavbar:after",function(e){var i=e.children("."+t.navbar),n=!!i.children("."+t.btn+"_prev").length;this.__sr_aria(i.children("."+t.title),"hidden",n)})),s.text&&(this.bind("initAddons:after",function(){this.bind("setPage:after",function(){this.trigger("setPage:after:sr-text",arguments[0])}),this.bind("initBlocker:after",function(){this.trigger("initBlocker:after:sr-text")})}),this.bind("initNavbar:after",function(e){var i=e.children("."+t.navbar),n=this.i18n(r.text.closeSubmenu);i.children("."+t.btn+"_prev").html(this.__sr_text(n))}),this.bind("initListview:after",function(e){var n=e.data(i.parent);if(n&&n.length){var s=n.children("."+t.btn+"_next"),a=this.i18n(r.text[s.parent().is("."+t.listitem+"_vertical")?"toggleSubmenu":"openSubmenu"]);s.append(o.__sr_text(a))}}))},add:function(){t=e.mmenu._c,i=e.mmenu._d,e.mmenu._e,t.add("sronly")},clickAnchor:function(e,t){}},e.mmenu.defaults[n]={aria:!0,text:!0},e.mmenu.configuration[n]={text:{closeMenu:"Close menu",closeSubmenu:"Close submenu",openSubmenu:"Open submenu",toggleSubmenu:"Toggle submenu"}},e.mmenu.prototype.__sr_aria=function(e,t,i){e.prop("aria-"+t,i)[i?"attr":"removeAttr"]("aria-"+t,i)},e.mmenu.prototype.__sr_role=function(e,t){e.prop("role",t)[t?"attr":"removeAttr"]("role",t)},e.mmenu.prototype.__sr_text=function(e){return''+e+""}}(e),function(e){var t,i,n,o="scrollBugFix";e.mmenu.addons[o]={setup:function(){var i=this.opts[o];this.conf[o],n=e.mmenu.glbl,e.mmenu.support.touch&&this.opts.offCanvas&&this.opts.offCanvas.blockUI&&("boolean"==typeof i&&(i={fix:i}),"object"!=a(i)&&(i={}),(i=this.opts[o]=e.extend(!0,{},e.mmenu.defaults[o],i)).fix&&(this.bind("open:start",function(){this.$pnls.children("."+t.panel+"_opened").scrollTop(0)}),this.bind("initMenu:after",function(){this["_initWindow_"+o]()})))},add:function(){t=e.mmenu._c,e.mmenu._d,i=e.mmenu._e},clickAnchor:function(e,t){}},e.mmenu.defaults[o]={fix:!0},e.mmenu.prototype["_initWindow_"+o]=function(){var s=this;e(document).off(i.touchmove+"-"+o).on(i.touchmove+"-"+o,function(e){n.$html.hasClass(t.wrapper+"_opened")&&e.preventDefault()});var a=!1;n.$body.off(i.touchstart+"-"+o).on(i.touchstart+"-"+o,"."+t.panels+"> ."+t.panel,function(e){n.$html.hasClass(t.wrapper+"_opened")&&(a||(a=!0,0===e.currentTarget.scrollTop?e.currentTarget.scrollTop=1:e.currentTarget.scrollHeight===e.currentTarget.scrollTop+e.currentTarget.offsetHeight&&(e.currentTarget.scrollTop-=1),a=!1))}).off(i.touchmove+"-"+o).on(i.touchmove+"-"+o,"."+t.panels+"> ."+t.panel,function(i){n.$html.hasClass(t.wrapper+"_opened")&&e(this)[0].scrollHeight>e(this).innerHeight()&&i.stopPropagation()}),n.$wndw.off(i.orientationchange+"-"+o).on(i.orientationchange+"-"+o,function(){s.$pnls.children("."+t.panel+"_opened").scrollTop(0).css({"-webkit-overflow-scrolling":"auto"}).css({"-webkit-overflow-scrolling":"touch"})})}}(e),function(e){var t,i="autoHeight";e.mmenu.addons[i]={setup:function(){var n=this.opts[i];if(this.conf[i],e.mmenu.glbl,"boolean"==typeof n&&n&&(n={height:"auto"}),"string"==typeof n&&(n={height:n}),"object"!=a(n)&&(n={}),"auto"==(n=this.opts[i]=e.extend(!0,{},e.mmenu.defaults[i],n)).height||"highest"==n.height){this.bind("initMenu:after",function(){this.$menu.addClass(t.menu+"_autoheight")});var o=function(i){if(!this.opts.offCanvas||this.vars.opened){var o=Math.max(parseInt(this.$pnls.css("top"),10),0)||0,s=Math.max(parseInt(this.$pnls.css("bottom"),10),0)||0,a=0;this.$menu.addClass(t.menu+"_autoheight-measuring"),"auto"==n.height?((i=i||this.$pnls.children("."+t.panel+"_opened")).parent("."+t.listitem+"_vertical").length&&(i=i.parents("."+t.panel).not(function(){return e(this).parent("."+t.listitem+"_vertical").length})),i.length||(i=this.$pnls.children("."+t.panel)),a=i.first().outerHeight()):"highest"==n.height&&this.$pnls.children("."+t.panel).each(function(){var i=e(this);i.parent("."+t.listitem+"_vertical").length&&(i=i.parents("."+t.panel).not(function(){return e(this).parent("."+t.listitem+"_vertical").length})),a=Math.max(a,i.first().outerHeight())}),this.$menu.height(a+o+s).removeClass(t.menu+"_autoheight-measuring")}};this.opts.offCanvas&&this.bind("open:start",o),"highest"==n.height&&this.bind("initPanels:after",o),"auto"==n.height&&(this.bind("updateListview",o),this.bind("openPanel:start",o),this.bind("closePanel",o))}},add:function(){t=e.mmenu._c,e.mmenu._d,e.mmenu._e.add("resize")},clickAnchor:function(e,t){}},e.mmenu.defaults[i]={height:"default"}}(e),function(e){var t,i="backButton";e.mmenu.addons[i]={setup:function(){if(this.opts.offCanvas){var n=this,o=this.opts[i];this.conf[i],e.mmenu.glbl,"boolean"==typeof o&&(o={close:o}),"object"!=a(o)&&(o={}),o=e.extend(!0,{},e.mmenu.defaults[i],o);var s="#"+this.$menu.attr("id");if(o.close){var r=function(){l=[s],this.$pnls.children("."+t.panel+"_opened-parent").add(n.$pnls.children("."+t.panel+"_opened")).each(function(){l.push("#"+e(this).attr("id"))})},l=[];this.bind("open:finish",function(){history.pushState(null,document.title,s)}),this.bind("open:finish",r),this.bind("openPanel:finish",r),this.bind("close:finish",function(){l=[],history.back(),history.pushState(null,document.title,location.pathname+location.search)}),e(window).on("popstate",function(t){if(n.vars.opened&&l.length){var i=(l=l.slice(0,-1))[l.length-1];i==s?n.close():(n.openPanel(e(i)),history.pushState(null,document.title,s))}})}o.open&&e(window).on("popstate",function(e){n.vars.opened||location.hash!=s||n.open()})}},add:function(){window.history&&window.history.pushState?(t=e.mmenu._c,e.mmenu._d,e.mmenu._e):e.mmenu.addons[i].setup=function(){}},clickAnchor:function(e,t){}},e.mmenu.defaults[i]={close:!1,open:!1}}(e),function(e){var t,i;e.mmenu.addons.columns={setup:function(){var n=this.opts.columns;if(this.conf.columns,e.mmenu.glbl,"boolean"==typeof n&&(n={add:n}),"number"==typeof n&&(n={add:!0,visible:n}),"object"!=a(n)&&(n={}),"number"==typeof n.visible&&(n.visible={min:n.visible,max:n.visible}),(n=this.opts.columns=e.extend(!0,{},e.mmenu.defaults.columns,n)).add){n.visible.min=Math.max(1,Math.min(6,n.visible.min)),n.visible.max=Math.max(n.visible.min,Math.min(6,n.visible.max));for(var o="",s="",r=0;r<=n.visible.max;r++)o+=" "+t.menu+"_columns-"+r,s+=" "+t.panel+"_columns-"+r;o.length&&(o=o.slice(1),s=s.slice(1));var l=s+" "+t.panel+"_opened "+t.panel+"_opened-parent "+t.panel+"_highest";this.bind("openPanel:before",function(e){var n=e.data(i.parent);if(n&&(n=n.closest("."+t.panel)).length){var o=n.attr("class");if(o&&(o=o.split(t.panel+"_columns-")[1]))for(o=parseInt(o.split(" ")[0],10)+1;o>0;){var s=this.$pnls.children("."+t.panel+"_columns-"+o);if(!s.length){o=-1;break}o++,s.removeClass(l).addClass(t.hidden)}}}),this.bind("openPanel:start",function(i){var a=this.$pnls.children("."+t.panel+"_opened-parent").length;i.hasClass(t.panel+"_opened-parent")||a++,a=Math.min(n.visible.max,Math.max(n.visible.min,a)),this.$menu.removeClass(o).addClass(t.menu+"_columns-"+a),this.$pnls.children("."+t.panel).removeClass(s).filter("."+t.panel+"_opened-parent").add(i).slice(-n.visible.max).each(function(i){e(this).addClass(t.panel+"_columns-"+i)})})}},add:function(){t=e.mmenu._c,i=e.mmenu._d,e.mmenu._e},clickAnchor:function(e,t){}},e.mmenu.defaults.columns={add:!1,visible:{min:1,max:3}}}(e),function(e){var t,i;e.mmenu.addons.counters={setup:function(){var n=this,o=this.opts.counters;if(this.conf.counters,e.mmenu.glbl,"boolean"==typeof o&&(o={add:o,update:o}),"object"!=a(o)&&(o={}),o=this.opts.counters=e.extend(!0,{},e.mmenu.defaults.counters,o),this.bind("initListview:after",function(e){var i=this.conf.classNames.counters.counter;this.__refactorClass(e.find("."+i),i,t.counter)}),o.add&&this.bind("initListview:after",function(n){var s;switch(o.addTo){case"panels":s=n;break;default:s=n.filter(o.addTo)}s.each(function(){var n=e(this).data(i.parent);n&&(n.find("."+t.counter).length||n.children("."+t.btn).prepend(e('')))})}),o.update){var s=function(o){(o=o||this.$pnls.children("."+t.panel)).each(function(){var o=e(this),s=o.data(i.parent);if(s){var a=s.find("."+t.counter);a.length&&(o=o.children("."+t.listview)).length&&a.html(n.__filterListItems(o.children()).length)}})};this.bind("initListview:after",s),this.bind("updateListview",s)}},add:function(){t=e.mmenu._c,i=e.mmenu._d,e.mmenu._e,t.add("counter")},clickAnchor:function(e,t){}},e.mmenu.defaults.counters={add:!1,addTo:"panels",count:!1},e.mmenu.configuration.classNames.counters={counter:"Counter"}}(e),function(e){var t,i,n="dividers";e.mmenu.addons.dividers={setup:function(){var o=this,s=this.opts.dividers;if(this.conf.dividers,e.mmenu.glbl,"boolean"==typeof s&&(s={add:s,fixed:s}),"object"!=a(s)&&(s={}),(s=this.opts.dividers=e.extend(!0,{},e.mmenu.defaults.dividers,s)).type&&this.bind("initMenu:after",function(){this.$menu.addClass(t.menu+"_"+n+"-"+s.type)}),s.add&&this.bind("initListview:after",function(i){var n;switch(s.addTo){case"panels":n=i;break;default:n=i.filter(s.addTo)}n.length&&(n.children("."+t.listitem+"_divider").remove(),n.find("."+t.listview).each(function(){var i="";o.__filterListItems(e(this).children()).each(function(){var n=e.trim(e(this).children("a, span").text()).slice(0,1).toLowerCase();n!=i&&n.length&&(i=n,e('
  • '+n+"
  • ").insertBefore(this))})}))}),s.fixed){this.bind("initPanels:before",function(){void 0===this.$fixeddivider&&(this.$fixeddivider=e('
    ').appendTo(this.$pnls).children())});var r=function(i){if(!(i=i||this.$pnls.children("."+t.panel+"_opened")).is(":hidden")){var n=i.find("."+t.listitem+"_divider").not("."+t.hidden),o=i.scrollTop()||0,s="";n.each(function(){e(this).position().top+oi&&(e=i),e}e.mmenu.addons[o]={setup:function(){if(this.opts.offCanvas){var r=this.opts[o],l=this.conf[o];n=e.mmenu.glbl,"boolean"==typeof r&&(r={menu:r,panels:r}),"object"!=a(r)&&(r={}),"boolean"==typeof r.menu&&(r.menu={open:r.menu}),"object"!=a(r.menu)&&(r.menu={}),"boolean"==typeof r.panels&&(r.panels={close:r.panels}),"object"!=a(r.panels)&&(r.panels={}),(r=this.opts[o]=e.extend(!0,{},e.mmenu.defaults[o],r)).menu.open&&this.bind("setPage:after",function(){(function(i,n,a){var r,l,c,d,u=this,h={events:"panleft panright",typeLower:"x",typeUpper:"X",open_dir:"right",close_dir:"left",negative:!1},p="width",f=h.open_dir,m=function(e){e<=i.maxStartPos&&(v=1)},g=function(){return e("."+t.slideout)},v=0,b=0,y=0,w=this.opts.extensions.all,x=void 0===w?"left":w.indexOf(t.menu+"_position-right")>-1?"right":w.indexOf(t.menu+"_position-top")>-1?"top":w.indexOf(t.menu+"_position-bottom")>-1?"bottom":"left",C=void 0===w?"back":w.indexOf(t.menu+"_position-top")>-1||w.indexOf(t.menu+"_position-bottom")>-1||w.indexOf(t.menu+"_position-front")>-1?"front":"back";switch(x){case"top":case"bottom":h.events="panup pandown",h.typeLower="y",h.typeUpper="Y",p="height"}switch(x){case"right":case"bottom":h.negative=!0,m=function(e){e>=a.$wndw[p]()-i.maxStartPos&&(v=1)}}switch(x){case"right":h.open_dir="left",h.close_dir="right";break;case"top":h.open_dir="down",h.close_dir="up";break;case"bottom":h.open_dir="up",h.close_dir="down"}switch(C){case"front":g=function(){return u.$menu}}var E=this.__valueOrFn(this.$menu,i.node,a.$page);"string"==typeof E&&(E=e(E));var T=new Hammer(E[0],this.opts[o].vendors.hammer);T.on("panstart",function(e){m(e.center[h.typeLower]),d=g(),f=h.open_dir}),T.on(h.events+" panend",function(e){v>0&&e.preventDefault()}),T.on(h.events,function(e){if(r=e["delta"+h.typeUpper],h.negative&&(r=-r),r!=b&&(f=r>=b?h.open_dir:h.close_dir),(b=r)>i.threshold&&1==v){if(a.$html.hasClass(t.wrapper+"_opened"))return;v=2,u._openSetup(),u.trigger("open:start"),a.$html.addClass(t.dragging),y=s(a.$wndw[p]()*n[p].perc,n[p].min,n[p].max)}2==v&&(l=s(b,10,y)-("front"==C?y:0),h.negative&&(l=-l),c="translate"+h.typeUpper+"("+l+"px )",d.css({"-webkit-transform":"-webkit-"+c,transform:c}))}),T.on("panend",function(e){2==v&&(a.$html.removeClass(t.dragging),d.css("transform",""),u[f==h.open_dir?"_openFinish":"close"]()),v=0})}).call(this,r.menu,l.menu,n)}),r.panels.close&&this.bind("initPanel:after",function(e){(function(e,n,s,a){var r=this,l=e.data(i.parent);if(l){l=l.closest("."+t.panel);var c=new Hammer(e[0],r.opts[o].vendors.hammer),d=null;c.on("panright",function(e){d||(r.openPanel(l),d=setTimeout(function(){clearTimeout(d),d=null},r.conf.openingInterval+r.conf.transitionDuration))})}}).call(this,e,r.panels,l.panels,n)})}},add:function(){if("function"!=typeof Hammer||Hammer.VERSION<2)return e.mmenu.addons[o].add=function(){},void(e.mmenu.addons[o].setup=function(){});t=e.mmenu._c,i=e.mmenu._d,e.mmenu._e,t.add("dragging")},clickAnchor:function(e,t){}},e.mmenu.defaults[o]={menu:{open:!1,maxStartPos:100,threshold:50},panels:{close:!1},vendors:{hammer:{}}},e.mmenu.configuration[o]={menu:{width:{perc:.8,min:140,max:440},height:{perc:.8,min:140,max:880}},panels:{}}}(e),function(e){var t,i,n,o,s="dropdown";e.mmenu.addons.dropdown={setup:function(){if(this.opts.offCanvas){var r=this,l=this.opts.dropdown,c=this.conf.dropdown;if(o=e.mmenu.glbl,"boolean"==typeof l&&l&&(l={drop:l}),"object"!=a(l)&&(l={}),"string"==typeof l.position&&(l.position={of:l.position}),(l=this.opts.dropdown=e.extend(!0,{},e.mmenu.defaults.dropdown,l)).drop){var d;this.bind("initMenu:after",function(){if(this.$menu.addClass(t.menu+"_"+s),"string"!=typeof l.position.of){var i=this._getOriginalMenuId();i&&i.length&&(l.position.of='[href="#'+i+'"]')}"string"==typeof l.position.of&&(d=e(l.position.of),l.event=l.event.split(" "),1==l.event.length&&(l.event[1]=l.event[0]),"hover"==l.event[0]&&d.on(n.mouseenter+"-"+s,function(){r.open()}),"hover"==l.event[1]&&this.$menu.on(n.mouseleave+"-"+s,function(){r.close()}))}),this.bind("open:start",function(){this.$menu.data(i.style,this.$menu.attr("style")||""),o.$html.addClass(t.wrapper+"_dropdown")}),this.bind("close:finish",function(){this.$menu.attr("style",this.$menu.data(i.style)),o.$html.removeClass(t.wrapper+"_dropdown")});var u=function(e,i){var n,s,a=i[0],r=i[1],u="x"==e?"scrollLeft":"scrollTop",h="x"==e?"outerWidth":"outerHeight",p="x"==e?"left":"top",f="x"==e?"right":"bottom",m="x"==e?"width":"height",g="x"==e?"maxWidth":"maxHeight",v=null,b=o.$wndw[u](),y=d.offset()[p]-=b,w=y+d[h](),x=o.$wndw[m](),C=c.offset.button[e]+c.offset.viewport[e];if(l.position[e])switch(l.position[e]){case"left":case"bottom":v="after";break;case"right":case"top":v="before"}return null===v&&(v=y+(w-y)/2'),l=0,c=o.length;l')),a.append(r))}),a&&(this.bind("initMenu:after",function(){var e=t.menu+"_iconbar";s.size&&(e+=" "+t.menu+"_iconbar-"+s.size),this.$menu.addClass(e).prepend(a)}),"tabs"==s.type)){a.addClass(t.iconbar+"_tabs");var r=a.find("a");r.on(n.click+"-iconbar",function(i){var n=e(this);if(n.hasClass(t.iconbar+"__tab_selected"))i.stopImmediatePropagation();else try{var s=e(n.attr("href"));s.hasClass(t.panel)&&(i.preventDefault(),i.stopImmediatePropagation(),o.openPanel(s,!1))}catch(e){}}),this.bind("openPanel:start",function e(n){r.removeClass(t.iconbar+"__tab_selected");var o=r.filter('[href="#'+n.attr("id")+'"]');if(o.length)o.addClass(t.iconbar+"__tab_selected");else{var s=n.data(i.parent);s&&s.length&&e(s.closest("."+t.panel))}})}}},add:function(){t=e.mmenu._c,i=e.mmenu._d,n=e.mmenu._e,t.add("iconbar")},clickAnchor:function(e,t){}},e.mmenu.defaults.iconbar={add:!1,top:[],bottom:[]},e.mmenu.configuration.iconbar={}}(e),function(e){var t,i="iconPanels";e.mmenu.addons[i]={setup:function(){var n=this,o=this.opts[i],s=(this.conf[i],!1);e.mmenu.glbl,"boolean"==typeof o&&(o={add:o}),"number"!=typeof o&&"string"!=typeof o||(o={add:!0,visible:o}),"object"!=a(o)&&(o={}),"first"==o.visible&&(s=!0,o.visible=1),(o=this.opts[i]=e.extend(!0,{},e.mmenu.defaults[i],o)).visible=Math.min(3,Math.max(1,o.visible)),o.visible++;var r="";if(!s){for(var l=0;l<=o.visible;l++)r+=" "+t.panel+"_iconpanel-"+l;r.length&&(r=r.slice(1))}if(o.add){var c=function(i){if(!i.parent("."+t.listitem+"_vertical").length){var a=n.$pnls.children("."+t.panel);s?a.removeClass(t.panel+"_iconpanel-first").first().addClass(t.panel+"_iconpanel-first"):a.removeClass(r).filter("."+t.panel+"_opened-parent").removeClass(t.hidden).not(function(){return e(this).parent("."+t.listitem+"_vertical").length}).add(i).slice(-o.visible).each(function(i){e(this).addClass(t.panel+"_iconpanel-"+i)})}};this.bind("initMenu:after",function(){var e=[t.menu+"_iconpanel"];o.size&&e.push(t.menu+"_iconpanel-"+o.size),o.hideNavbar&&e.push(t.menu+"_hidenavbar"),o.hideDivider&&e.push(t.menu+"_hidedivider"),this.$menu.addClass(e.join(" "))}),this.bind("openPanel:start",c),this.bind("initPanels:after",function(e){c.call(n,n.$pnls.children("."+t.panel+"_opened"))}),this.bind("initListview:after",function(e){!o.blockPanel||e.parent("."+t.listitem+"_vertical").length||e.children("."+t.panel+"__blocker").length||e.prepend('
    ')})}},add:function(){t=e.mmenu._c,e.mmenu._d,e.mmenu._e},clickAnchor:function(e,t){}},e.mmenu.defaults[i]={add:!1,blockPanel:!0,hideDivider:!1,hideNavbar:!0,visible:3}}(e),function(e){var t,i,n,o,s="keyboardNavigation";e.mmenu.addons[s]={setup:function(){if(!e.mmenu.support.touch){var i=this.opts[s];if(this.conf[s],o=e.mmenu.glbl,"boolean"!=typeof i&&"string"!=typeof i||(i={enable:i}),"object"!=a(i)&&(i={}),(i=this.opts[s]=e.extend(!0,{},e.mmenu.defaults[s],i)).enable){var n=e('