/** * Framework7 1.5.3 * Full featured mobile HTML framework for building iOS & Android apps * * http://framework7.io/ * * Copyright 2017, Vladimir Kharlampidi * The iDangero.us * http://www.idangero.us/ * * Licensed under MIT * * Released on: February 10, 2017 */ !function(){"use strict";window.Framework7=function(a){function t(e){var a=e.replace(/^./,function(e){return e.toUpperCase()});i["onPage"+a]=function(a,t){return i.onPage(e,a,t)}}function n(){var e,a=o(this),t=a[0].scrollTop,n=a[0].scrollHeight,r=a[0].offsetHeight,i=a[0].getAttribute("data-distance"),s=a.find(".virtual-list"),l=a.hasClass("infinite-scroll-top");if(i||(i=50),"string"==typeof i&&i.indexOf("%")>=0&&(i=parseInt(i,10)/100*r),i>r&&(i=r),l)t=n-i){if(s.length>0&&(e=s.eq(-1)[0].f7VirtualList,e&&!e.reachEnd&&!e.params.updatableScroll))return;a.trigger("infinite")}}function r(){i.device.ipad&&(document.body.scrollLeft=0,setTimeout(function(){document.body.scrollLeft=0},0))}var i=this;i.version="1.5.0",i.params={root:"body",cache:!0,cacheIgnore:[],cacheIgnoreGetParameters:!1,cacheDuration:6e5,preloadPreviousPage:!0,uniqueHistory:!1,uniqueHistoryIgnoreGetParameters:!1,dynamicPageUrl:"content-{{index}}",allowDuplicateUrls:!1,router:!0,routerRemoveTimeout:!1,routerRemoveWithTimeout:!1,pushState:!1,pushStateRoot:void 0,pushStateNoAnimation:!1,pushStateSeparator:"#!/",pushStateOnLoad:!0,fastClicks:!0,fastClicksDistanceThreshold:10,fastClicksDelayBetweenClicks:50,fastClicksExclude:"",tapHold:!1,tapHoldDelay:750,tapHoldPreventClicks:!0,activeState:!0,activeStateElements:"a, button, label, span",animateNavBackIcon:!1,swipeBackPage:!0,swipeBackPageThreshold:0,swipeBackPageActiveArea:30,swipeBackPageAnimateShadow:!0,swipeBackPageAnimateOpacity:!0,ajaxLinks:void 0,externalLinks:".external",sortable:!0,hideNavbarOnPageScroll:!1,hideToolbarOnPageScroll:!1,hideTabbarOnPageScroll:!1,showBarsOnPageScrollEnd:!0,showBarsOnPageScrollTop:!0,swipeout:!0,swipeoutActionsNoFold:!1,swipeoutNoFollow:!1,swipeoutRemoveWithTimeout:!1,smartSelectOpenIn:"page",smartSelectBackText:"Back",smartSelectPopupCloseText:"Close",smartSelectPickerCloseText:"Done",smartSelectSearchbar:!1,smartSelectBackOnSelect:!1,scrollTopOnNavbarClick:!1,scrollTopOnStatusbarClick:!1,swipePanel:!1,swipePanelActiveArea:0,swipePanelCloseOpposite:!0,swipePanelOnlyClose:!1,swipePanelNoFollow:!1,swipePanelThreshold:0,panelsCloseByOutside:!0,modalButtonOk:"OK",modalButtonCancel:"Cancel",modalUsernamePlaceholder:"Username",modalPasswordPlaceholder:"Password",modalTitle:"Framework7",modalCloseByOutside:!1,actionsCloseByOutside:!0,popupCloseByOutside:!0,modalPreloaderTitle:"Loading... ",modalStack:!0,modalsMoveToRoot:!0,imagesLazyLoadThreshold:0,imagesLazyLoadSequential:!0,viewClass:"view",viewMainClass:"view-main",viewsClass:"views",notificationCloseOnClick:!1,notificationCloseIcon:!0,notificationCloseButtonText:"Close",animatePages:!0,templates:{},template7Data:{},template7Pages:!1,precompileTemplates:!1,material:!1,materialPageLoadDelay:0,materialPreloaderSvg:'',materialPreloaderHtml:'',materialRipple:!0,materialRippleElements:".ripple, a.link, a.item-link, .button, .modal-button, .tab-link, .label-radio, .label-checkbox, .actions-modal-button, a.searchbar-clear, a.floating-button, .floating-button > a, .speed-dial-buttons a",init:!0};for(var s in a)i.params[s]=a[s];var o=e,l=Template7;i._compiledTemplates={},i.root=o(i.params.root),i.root.eq(0).addClass("framework7-root"),i.touchEvents={start:i.support.touch?"touchstart":"mousedown",move:i.support.touch?"touchmove":"mousemove",end:i.support.touch?"touchend":"mouseup"},i.ls=window.localStorage,i.rtl="rtl"===o("body").css("direction"),i.rtl&&o("html").attr("dir","rtl"),"undefined"!=typeof i.params.statusbarOverlay?i.params.statusbarOverlay?o("html").addClass("with-statusbar-overlay"):o("html").removeClass("with-statusbar-overlay"):i.device.ios&&(window.cordova||window.phonegap)&&o(document).on("resume",function(){i.device.needsStatusBar()&&o("html").addClass("with-statusbar-overlay")},!1),i.views=[];var p=function(e,a){var t,n={dynamicNavbar:!1,domCache:!1,linksView:void 0,reloadPages:!1,uniqueHistory:i.params.uniqueHistory,uniqueHistoryIgnoreGetParameters:i.params.uniqueHistoryIgnoreGetParameters,allowDuplicateUrls:i.params.allowDuplicateUrls,swipeBackPage:i.params.swipeBackPage,swipeBackPageAnimateShadow:i.params.swipeBackPageAnimateShadow,swipeBackPageAnimateOpacity:i.params.swipeBackPageAnimateOpacity,swipeBackPageActiveArea:i.params.swipeBackPageActiveArea,swipeBackPageThreshold:i.params.swipeBackPageThreshold,animatePages:i.params.animatePages,preloadPreviousPage:i.params.preloadPreviousPage};a=a||{},a.dynamicNavbar&&i.params.material&&(a.dynamicNavbar=!1);for(var r in n)"undefined"==typeof a[r]&&(a[r]=n[r]);var s=this;s.params=a,s.selector=e;var l=o(e);if(s.container=l[0],"string"!=typeof e&&(e=(l.attr("id")?"#"+l.attr("id"):"")+(l.attr("class")?"."+l.attr("class").replace(/ /g,".").replace(".active",""):""),s.selector=e),s.main=l.hasClass(i.params.viewMainClass),s.contentCache={},s.contextCache={},s.pagesCache={},s.pageElementsCache={},l[0].f7View=s,s.pagesContainer=l.find(".pages")[0],s.initialPages=[],s.initialPagesUrl=[],s.initialNavbars=[],s.params.domCache){var p=l.find(".page");for(t=0;t=0&&u.indexOf(m+"#")<0&&(u=u.split(m)[0]));var h,g;s.activePage||(h=o(s.pagesContainer).find(".page-on-center"),0===h.length&&(h=o(s.pagesContainer).find(".page:not(.cached)"),h=h.eq(h.length-1)),h.length>0&&(g=h[0].f7PageData)),s.params.domCache&&h?(s.url=l.attr("data-url")||s.params.url||"#"+h.attr("data-page"),s.pagesCache[s.url]=h.attr("data-page")):s.url=l.attr("data-url")||s.params.url||u,g&&(g.view=s,g.url=s.url,s.params.domCache&&s.params.dynamicNavbar&&!g.navbarInnerContainer&&(g.navbarInnerContainer=s.initialNavbars[s.initialPages.indexOf(g.container)]),s.activePage=g,h[0].f7PageData=g),s.url&&s.history.push(s.url);var v,b,w,C,y,x,T,k,P,S,M,I=!1,E=!1,O={},z=[],D=[],L=!0,B=[],N=[];if(s.handleTouchStart=function(e){L&&s.params.swipeBackPage&&!I&&!i.swipeoutOpenedEl&&s.allowPageChange&&(E=!1,I=!0,v=void 0,O.x="touchstart"===e.type?e.targetTouches[0].pageX:e.pageX,O.y="touchstart"===e.type?e.targetTouches[0].pageY:e.pageY,C=(new Date).getTime(),P=s.params.dynamicNavbar&&l.find(".navbar-inner").length>1)},s.handleTouchMove=function(e){if(I){var a="touchmove"===e.type?e.targetTouches[0].pageX:e.pageX,t="touchmove"===e.type?e.targetTouches[0].pageY:e.pageY;if("undefined"==typeof v&&(v=!!(v||Math.abs(t-O.y)>Math.abs(a-O.x))),v||e.f7PreventSwipeBack||i.preventSwipeBack)return void(I=!1);if(!E){var n=!1;b=l.width();var r=o(e.target),p=r.hasClass("swipeout")?r:r.parents(".swipeout");p.length>0&&(!i.rtl&&p.find(".swipeout-actions-left").length>0&&(n=!0),i.rtl&&p.find(".swipeout-actions-right").length>0&&(n=!0)),z=r.is(".page")?r:r.parents(".page"),z.hasClass("no-swipeback")&&(n=!0),D=l.find(".page-on-left:not(.cached)");var d=O.x-l.offset().left>s.params.swipeBackPageActiveArea;if(d=i.rtl?O.xs.params.swipeBackPageActiveArea,d&&(n=!0),0!==D.length&&0!==z.length||(n=!0),n)return void(I=!1);s.params.swipeBackPageAnimateShadow&&!i.device.android&&(S=z.find(".swipeback-page-shadow"),0===S.length&&(S=o('
'),z.append(S))),P&&(B=l.find(".navbar-on-center:not(.cached)"),N=l.find(".navbar-on-left:not(.cached)"),y=B.find(".left, .center, .right, .subnavbar, .fading"),x=N.find(".left, .center, .right, .subnavbar, .fading"),i.params.animateNavBackIcon&&(T=B.find(".left.sliding .back .icon"),k=N.find(".left.sliding .back .icon"))),o(".picker-modal.modal-in").length>0&&i.closeModal(o(".picker-modal.modal-in"))}e.f7PreventPanelSwipe=!0,E=!0,e.preventDefault();var c=i.rtl?-1:1;w=(a-O.x-s.params.swipeBackPageThreshold)*c,w<0&&(w=0);var u=w/b,m={percentage:u,activePage:z[0],previousPage:D[0],activeNavbar:B[0],previousNavbar:N[0]};s.params.onSwipeBackMove&&s.params.onSwipeBackMove(m),l.trigger("swipeBackMove swipeback:move",m);var f=w*c,h=(w/5-b/5)*c;if(1===i.device.pixelRatio&&(f=Math.round(f),h=Math.round(h)),z.transform("translate3d("+f+"px,0,0)"),s.params.swipeBackPageAnimateShadow&&!i.device.android&&(S[0].style.opacity=1-1*u),D.transform("translate3d("+h+"px,0,0)"),s.params.swipeBackPageAnimateOpacity&&(D[0].style.opacity=.9+.1*u),P){var g;for(g=0;g=0){var C=u*M[0].f7NavbarRightOffset;1===i.device.pixelRatio&&(C=Math.round(C)),M.transform("translate3d("+C+"px,0,0)"),i.params.animateNavBackIcon&&M[0].className.indexOf("left")>=0&&T.length>0&&T.transform("translate3d("+-C+"px,0,0)")}for(g=0;g=0){var L=M[0].f7NavbarLeftOffset*(1-u);1===i.device.pixelRatio&&(L=Math.round(L)),M.transform("translate3d("+L+"px,0,0)"),i.params.animateNavBackIcon&&M[0].className.indexOf("left")>=0&&k.length>0&&k.transform("translate3d("+-L+"px,0,0)")}}}},s.handleTouchEnd=function(e){if(!I||!E)return I=!1,void(E=!1);if(I=!1,E=!1,0===w)return o([z[0],D[0]]).transform("").css({opacity:"",boxShadow:""}),void(P&&(y.transform("").css({opacity:""}),x.transform("").css({opacity:""}),T&&T.length>0&&T.transform(""),k&&T.length>0&&k.transform("")));var a=(new Date).getTime()-C,t=!1;(a<300&&w>10||a>=300&&w>b/2)&&(z.removeClass("page-on-center").addClass("page-on-right"),D.removeClass("page-on-left").addClass("page-on-center"),P&&(B.removeClass("navbar-on-center").addClass("navbar-on-right"),N.removeClass("navbar-on-left").addClass("navbar-on-center")),t=!0),o([z[0],D[0]]).transform("").css({opacity:"",boxShadow:""}).addClass("page-transitioning"),P&&(y.css({opacity:""}).each(function(){var e=t?this.f7NavbarRightOffset:0,a=o(this);a.transform("translate3d("+e+"px,0,0)"),i.params.animateNavBackIcon&&a.hasClass("left")&&T.length>0&&T.addClass("page-transitioning").transform("translate3d("+-e+"px,0,0)")}).addClass("page-transitioning"),x.transform("").css({opacity:""}).each(function(){var e=t?0:this.f7NavbarLeftOffset,a=o(this);a.transform("translate3d("+e+"px,0,0)"),i.params.animateNavBackIcon&&a.hasClass("left")&&k.length>0&&k.addClass("page-transitioning").transform("translate3d("+-e+"px,0,0)")}).addClass("page-transitioning")),L=!1,s.allowPageChange=!1;var n={activePage:z[0],previousPage:D[0],activeNavbar:B[0],previousNavbar:N[0]};if(t){var r=s.history[s.history.length-2];s.url=r,i.pageBackCallback("before",s,{pageContainer:z[0],url:r,position:"center",newPage:D,oldPage:z,swipeBack:!0}),i.pageAnimCallback("before",s,{pageContainer:D[0],url:r,position:"left",newPage:D,oldPage:z,swipeBack:!0}),s.params.onSwipeBackBeforeChange&&s.params.onSwipeBackBeforeChange(n),l.trigger("swipeBackBeforeChange swipeback:beforechange",n)}else s.params.onSwipeBackBeforeReset&&s.params.onSwipeBackBeforeReset(n),l.trigger("swipeBackBeforeReset swipeback:beforereset",n);z.transitionEnd(function(){o([z[0],D[0]]).removeClass("page-transitioning"),P&&(y.removeClass("page-transitioning").css({opacity:""}),x.removeClass("page-transitioning").css({opacity:""}),T&&T.length>0&&T.removeClass("page-transitioning"),k&&k.length>0&&k.removeClass("page-transitioning")),L=!0,s.allowPageChange=!0,t?(i.params.pushState&&s.main&&history.back(),i.pageBackCallback("after",s,{pageContainer:z[0],url:r,position:"center",newPage:D,oldPage:z,swipeBack:!0}),i.pageAnimCallback("after",s,{pageContainer:D[0],url:r,position:"left",newPage:D,oldPage:z,swipeBack:!0}),i.router.afterBack(s,z,D),s.params.onSwipeBackAfterChange&&s.params.onSwipeBackAfterChange(n),l.trigger("swipeBackAfterChange swipeback:afterchange",n)):(s.params.onSwipeBackAfterReset&&s.params.onSwipeBackAfterReset(n),l.trigger("swipeBackAfterReset swipeback:afterreset",n)),S&&S.length>0&&S.remove()})},s.attachEvents=function(e){var a=e?"off":"on",t=!("touchstart"!==i.touchEvents.start||!i.support.passiveListener)&&{passive:!0,capture:!1};l[a](i.touchEvents.start,s.handleTouchStart,t),l[a](i.touchEvents.move,s.handleTouchMove),l[a](i.touchEvents.end,s.handleTouchEnd,t)},s.detachEvents=function(){s.attachEvents(!0)},s.params.swipeBackPage&&!i.params.material&&s.attachEvents(),s.params.name&&(s.params.name=s.params.name.replace(/[^a-zA-Z]/g,"")),i.views.push(s),s.main?(i.mainView=s,i.views.main=s):s.params.name&&(i[s.params.name+"View"]=s,i.views[s.params.name]=s),s.router={load:function(e){return i.router.load(s,e)},back:function(e){return i.router.back(s,e)},loadPage:function(e){if(e=e||{},"string"==typeof e){var a=e;e={},a&&0===a.indexOf("#")&&s.params.domCache?e.pageName=a.split("#")[1]:e.url=a}return i.router.load(s,e)},loadContent:function(e){return i.router.load(s,{content:e})},reloadPage:function(e){return i.router.load(s,{url:e,reload:!0})},reloadContent:function(e){return i.router.load(s,{content:e,reload:!0})},reloadPreviousPage:function(e){return i.router.load(s,{url:e,reloadPrevious:!0,reload:!0})},reloadPreviousContent:function(e){return i.router.load(s,{content:e,reloadPrevious:!0,reload:!0})},refreshPage:function(){var e={url:s.url,reload:!0,ignoreCache:!0};return e.url&&0===e.url.indexOf("#")&&(s.params.domCache&&s.pagesCache[e.url]?(e.pageName=s.pagesCache[e.url],e.url=void 0,delete e.url):s.contentCache[e.url]&&(e.content=s.contentCache[e.url],e.url=void 0,delete e.url)),i.router.load(s,e)},refreshPreviousPage:function(){var e={url:s.history[s.history.length-2],reload:!0,reloadPrevious:!0,ignoreCache:!0};return e.url&&0===e.url.indexOf("#")&&s.params.domCache&&s.pagesCache[e.url]&&(e.pageName=s.pagesCache[e.url],e.url=void 0,delete e.url),i.router.load(s,e)}},s.loadPage=s.router.loadPage,s.loadContent=s.router.loadContent,s.reloadPage=s.router.reloadPage,s.reloadContent=s.router.reloadContent,s.reloadPreviousPage=s.router.reloadPreviousPage,s.reloadPreviousContent=s.router.reloadPreviousContent,s.refreshPage=s.router.refreshPage,s.refreshPreviousPage=s.router.refreshPreviousPage,s.back=s.router.back,s.hideNavbar=function(e){return i.hideNavbar(l.find(".navbar"),e)},s.showNavbar=function(e){return i.showNavbar(l.find(".navbar"),e)},s.hideToolbar=function(e){return i.hideToolbar(l.find(".toolbar"),e)},s.showToolbar=function(e){return i.showToolbar(l.find(".toolbar"),e)},i.params.pushState&&i.params.pushStateOnLoad&&s.main){var H,A=c.split(m)[1];f?H=c.split(i.params.pushStateRoot+m)[1]:m&&c.indexOf(m)>=0&&c.indexOf(m+"#")<0&&(H=A);var R=!i.params.pushStateNoAnimation&&void 0,V=history.state;H?H.indexOf("#")>=0&&s.params.domCache&&V&&V.pageName&&"viewIndex"in V?i.router.load(s,{pageName:V.pageName,url:V.url,animatePages:R,pushState:!1}):H.indexOf("#")>=0&&s.params.domCache&&s.initialPagesUrl.indexOf(H)>=0?i.router.load(s,{pageName:H.replace("#",""),animatePages:R,pushState:!1}):i.router.load(s,{url:H,animatePages:R,pushState:!1}):s.params.domCache&&c.indexOf(m+"#")>=0&&(V&&V.pageName&&"viewIndex"in V?i.router.load(s,{pageName:V.pageName,url:V.url,animatePages:R,pushState:!1}):m&&0===A.indexOf("#")&&s.initialPagesUrl.indexOf(A)&&i.router.load(s,{pageName:A.replace("#",""),animatePages:R,pushState:!1}))}return s.destroy=function(){s.detachEvents(),s.main?(i.mainView=null,delete i.mainView,i.views.main=null,delete i.views.main):s.params.name&&(i[s.params.name+"View"]=null,delete i[s.params.name+"View"],i.views[s.params.name]=null,delete i.views[s.params.name]),l.removeAttr("data-page"),l[0].f7View=null,delete l[0].f7View,i.views.splice(i.views.indexOf(s),1);for(var e in s)s.hasOwnProperty(e)&&(s[e]=null,delete s[e]);s=null},i.pluginHook("addView",s),s};i.addView=function(e,a){return new p(e,a)},i.getCurrentView=function(e){var a=o(".popover.modal-in .view"),t=o(".popup.modal-in .view"),n=o(".panel.active .view"),r=o(".views"),i=r.children(".view");if(i.length>1&&i.hasClass("tab")&&(i=r.children(".view.active")),a.length>0&&a[0].f7View)return a[0].f7View;if(t.length>0&&t[0].f7View)return t[0].f7View;if(n.length>0&&n[0].f7View)return n[0].f7View;if(i.length>0){if(1===i.length&&i[0].f7View)return i[0].f7View;if(i.length>1){for(var s=[],l=0;l0&&"undefined"!=typeof e)return s[e];if(s.length>1)return s;if(1===s.length)return s[0];return}}},i.navbarInitCallback=function(e,a,t,n){if(!t&&n&&(t=o(n).parent(".navbar")[0]),n&&(!n.f7NavbarInitialized||!e||e.params.domCache)){var r={container:t,innerContainer:n},s=a&&a.f7PageData,l={page:s,navbar:r};if(n.f7NavbarInitialized&&(e&&e.params.domCache||!e&&o(t).parents(".popup, .popover, .login-screen, .modal, .actions-modal, .picker-modal").length>0))return i.reinitNavbar(t,n),i.pluginHook("navbarReinit",l),void o(n).trigger("navbarReinit navbar:reinit",l);n.f7NavbarInitialized=!0,i.pluginHook("navbarBeforeInit",r,s),o(n).trigger("navbarBeforeInit navbar:beforeinit",l),i.initNavbar(t,n),i.pluginHook("navbarInit",r,s),o(n).trigger("navbarInit navbar:init",l)}},i.navbarRemoveCallback=function(e,a,t,n){!t&&n&&(t=o(n).parent(".navbar")[0]);var r,s={container:t,innerContainer:n};a&&(r=a.f7PageData);var l={page:r,navbar:s};i.pluginHook("navbarBeforeRemove",s,r),o(n).trigger("navbarBeforeRemove navbar:beforeremove",l),s=null,r=null},i.initNavbar=function(e,a){i.initSearchbar&&i.initSearchbar(a)},i.reinitNavbar=function(e,a){},i.initNavbarWithCallback=function(e){e=o(e);var a,t=e.parents("."+i.params.viewClass);0!==t.length&&(0===e.parents(".navbar-through").length&&0===t.find(".navbar-through").length||(a=t[0].f7View||void 0,e.find(".navbar-inner").each(function(){var n,r=this;if(o(r).attr("data-page")&&(n=t.find('.page[data-page="'+o(r).attr("data-page")+'"]')[0]),!n){var s=t.find(".page");1===s.length?n=s[0]:t.find(".page").each(function(){this.f7PageData&&this.f7PageData.navbarInnerContainer===r&&(n=this)})}i.navbarInitCallback(a,n,e[0],r)})))},i.sizeNavbars=function(e){if(!i.params.material){var a=e?o(e).find(".navbar .navbar-inner:not(.cached)"):o(".navbar .navbar-inner:not(.cached)");a.each(function(){var e=o(this);if(!e.hasClass("cached")){var a,t,n=i.rtl?e.find(".right"):e.find(".left"),r=i.rtl?e.find(".left"):e.find(".right"),s=e.find(".center"),l=e.find(".subnavbar"),p=0===n.length,d=0===r.length,c=p?0:n.outerWidth(!0),u=d?0:r.outerWidth(!0),m=s.outerWidth(!0),f=e.styles(),h=e[0].offsetWidth-parseInt(f.paddingLeft,10)-parseInt(f.paddingRight,10),g=e.hasClass("navbar-on-left");d&&(a=h-m),p&&(a=0),p||d||(a=(h-u-m+c)/2);var v=(h-m)/2;h-c-u>m?(vh-u&&(v=h-u-m),t=v-a):t=0;var b=i.rtl?-1:1;if(s.hasClass("sliding")&&(s[0].f7NavbarLeftOffset=-(a+t)*b,s[0].f7NavbarRightOffset=(h-a-t-m)*b,g)){if(i.params.animateNavBackIcon){var w=e.parent().find(".navbar-on-center").find(".left.sliding .back .icon ~ span");w.length>0&&(s[0].f7NavbarLeftOffset+=w[0].offsetLeft)}s.transform("translate3d("+s[0].f7NavbarLeftOffset+"px, 0, 0)")}!p&&n.hasClass("sliding")&&(i.rtl?(n[0].f7NavbarLeftOffset=-(h-n[0].offsetWidth)/2*b,n[0].f7NavbarRightOffset=c*b):(n[0].f7NavbarLeftOffset=-c,n[0].f7NavbarRightOffset=(h-n[0].offsetWidth)/2,i.params.animateNavBackIcon&&n.find(".back .icon").length>0&&(n[0].f7NavbarRightOffset-=n.find(".back .icon")[0].offsetWidth)),g&&n.transform("translate3d("+n[0].f7NavbarLeftOffset+"px, 0, 0)")),!d&&r.hasClass("sliding")&&(i.rtl?(r[0].f7NavbarLeftOffset=-u*b,r[0].f7NavbarRightOffset=(h-r[0].offsetWidth)/2*b):(r[0].f7NavbarLeftOffset=-(h-r[0].offsetWidth)/2,r[0].f7NavbarRightOffset=u),g&&r.transform("translate3d("+r[0].f7NavbarLeftOffset+"px, 0, 0)")),l.length&&l.hasClass("sliding")&&(l[0].f7NavbarLeftOffset=i.rtl?l[0].offsetWidth:-l[0].offsetWidth,l[0].f7NavbarRightOffset=-l[0].f7NavbarLeftOffset);var C=t;i.rtl&&p&&d&&s.length>0&&(C=-C),s.css({left:C+"px"})}})}},i.hideNavbar=function(e,a){return"undefined"==typeof a&&(a=!0),o(e).addClass("navbar-hidden"+(a?"":" not-animated")),!0},i.showNavbar=function(e,a){"undefined"==typeof a&&(a=!0);var t=o(e);return a?(t.removeClass("not-animated"),t.addClass("navbar-hiding").removeClass("navbar-hidden").transitionEnd(function(){t.removeClass("navbar-hiding")})):t.removeClass("navbar-hidden navbar-hiding not-animated"),!0},i.hideToolbar=function(e,a){return"undefined"==typeof a&&(a=!0),o(e).addClass("toolbar-hidden"+(a?"":" not-animated")),!0},i.showToolbar=function(e,a){"undefined"==typeof a&&(a=!0);var t=o(e);a?(t.removeClass("not-animated"),t.addClass("toolbar-hiding").removeClass("toolbar-hidden").transitionEnd(function(){t.removeClass("toolbar-hiding"+(a?"":" not-animated"))})):t.removeClass("toolbar-hidden toolbar-hiding not-animated")};var d=function(e,a){function t(e){e.preventDefault()}var n={input:null,clearButton:null,cancelButton:null,searchList:null,searchIn:".item-title",searchBy:"",found:null,notFound:null,overlay:null,ignore:".searchbar-ignore",customSearch:!1,removeDiacritics:!1,hideDividers:!0,hideGroups:!0};a=a||{};for(var r in n)("undefined"==typeof a[r]||null===a[r]&&n.hasOwnProperty(r))&&(a[r]=n[r]);var s=this;s.material=i.params.material,s.params=a,e=o(e),s.container=e,s.active=!1,s.input=s.params.input?o(s.params.input):s.container.find('input[type="search"]'),s.clearButton=s.params.clearButton?o(s.params.clearButton):s.container.find(".searchbar-clear"),s.cancelButton=s.params.cancelButton?o(s.params.cancelButton):s.container.find(".searchbar-cancel"),s.searchList=o(s.params.searchList),s.isVirtualList=s.searchList.hasClass("virtual-list"),s.pageContainer=s.container.parents(".page").eq(0),s.params.overlay?s.overlay=o(s.params.overlay):s.overlay=s.pageContainer.length>0?s.pageContainer.find(".searchbar-overlay"):o(".searchbar-overlay"),s.params.found?s.found=o(s.params.found):s.found=s.pageContainer.length>0?s.pageContainer.find(".searchbar-found"):o(".searchbar-found"),s.params.notFound?s.notFound=o(s.params.notFound):s.notFound=s.pageContainer.length>0?s.pageContainer.find(".searchbar-not-found"):o(".searchbar-not-found");var l=i.rtl?"margin-left":"margin-right",p=!1;s.setCancelButtonMargin=function(){s.cancelButton.transition(0).show(),s.cancelButton.css(l,-s.cancelButton[0].offsetWidth+"px");s.cancelButton[0].clientLeft;s.cancelButton.transition(""),p=!0},s.triggerEvent=function(e,a,t){s.container.trigger(e,t),s.searchList.length>0&&s.searchList.trigger(e,t),a&&s.params[a]&&s.params[a](s,t)},s.enable=function(e){function a(){!s.searchList.length&&!s.params.customSearch||s.container.hasClass("searchbar-active")||s.query||s.overlay.addClass("searchbar-overlay-active"),s.container.addClass("searchbar-active"),s.cancelButton.length>0&&!s.material&&(p||s.setCancelButtonMargin(),s.cancelButton.css(l,"0px")),s.triggerEvent("enableSearch searchbar:enable","onEnable"),s.active=!0}i.device.ios&&!i.params.material&&e&&"focus"===e.type?setTimeout(function(){a()},400):a()},s.disable=function(){function e(){s.input.blur()}s.input.val("").trigger("change"),s.container.removeClass("searchbar-active searchbar-not-empty"),s.cancelButton.length>0&&!s.material&&s.cancelButton.css(l,-s.cancelButton[0].offsetWidth+"px"),(s.searchList.length||s.params.customSearch)&&s.overlay.removeClass("searchbar-overlay-active"),s.active=!1,i.device.ios?setTimeout(function(){e()},400):e(),s.triggerEvent("disableSearch searchbar:disable","onDisable")},s.clear=function(e){if(!s.query&&e&&o(e.target).hasClass("searchbar-clear"))return void s.disable();var a=s.value;s.input.val("").trigger("change").focus(),s.triggerEvent("clearSearch searchbar:clear","onClear",{previousQuery:a})},s.handleInput=function(){setTimeout(function(){var e=s.input.val().trim();(s.searchList.length>0||s.params.customSearch)&&(s.params.searchIn||s.isVirtualList)&&s.search(e,!0)},0)};var d,c="";return s.search=function(e,a){if(e.trim()!==c){if(c=e.trim(),a||(s.active||s.enable(),s.input.val(e)),s.query=s.value=e,0===e.length?(s.container.removeClass("searchbar-not-empty"),s.searchList.length&&s.container.hasClass("searchbar-active")&&s.overlay.addClass("searchbar-overlay-active")):(s.container.addClass("searchbar-not-empty"),s.searchList.length&&s.container.hasClass("searchbar-active")&&s.overlay.removeClass("searchbar-overlay-active")),s.params.customSearch)return void s.triggerEvent("search searchbar:search","onSearch",{query:e});var t,n=[];if(s.isVirtualList){if(d=s.searchList[0].f7VirtualList,""===e.trim())return d.resetFilter(),s.notFound.hide(),void s.found.show();if(t=s.params.removeDiacritics?o.removeDiacritics(e):e,d.params.searchAll)n=d.params.searchAll(t,d.items)||[];else if(d.params.searchByItem)for(var r=0;r=0&&r++;r===i.length||s.params.ignore&&a.is(s.params.ignore)?n.push(a[0]):a.addClass("hidden-by-searchbar")}),s.params.hideDividers&&s.searchList.find(".item-divider, .list-group-title").each(function(){for(var e=o(this),a=e.nextAll("li"),t=!0,n=0;ne){var n=t+a,r=i.initialBarHeight+(n-i.initialAreaHeight),s=i.params.maxHeight||i.container.parents(".view")[0].offsetHeight-88;r>s&&(r=parseInt(s,10),n=r-i.initialBarHeight+i.initialAreaHeight),i.textarea.css("height",n+"px"),i.container.css("height",r+"px");var o=i.pageContent[0].scrollTop===i.pageContent[0].scrollHeight-i.pageContent[0].offsetHeight;i.pageContent.length>0&&(i.pageContent.css("padding-bottom",r+"px"),0===i.pageContent.find(".messages-new-first").length&&o&&i.pageContent.scrollTop(i.pageContent[0].scrollHeight-i.pageContent[0].offsetHeight))}else i.pageContent.length>0&&(i.container.css({height:"",bottom:""}),i.pageContent.css({"padding-bottom":""}))},i.clear=function(){i.textarea.val("").trigger("change")},i.value=function(e){return"undefined"==typeof e?i.textarea.val():void i.textarea.val(e).trigger("change")},i.textareaTimeout=void 0,i.handleTextarea=function(e){clearTimeout(i.textareaTimeout),i.textareaTimeout=setTimeout(function(){i.sizeTextarea()},0)},i.attachEvents=function(e){var a=e?"off":"on";i.container[a]("submit",t),i.textarea[a]("change keydown keypress keyup paste cut",i.handleTextarea)},i.detachEvents=function(){i.attachEvents(!0)},i.init=function(){i.attachEvents()},i.destroy=function(){i.detachEvents(),i=null},i.init(),i.container[0].f7Messagebar=i,i};i.messagebar=function(e,a){return new c(e,a)},i.initPageMessagebar=function(e){function a(){n.destroy(),e.off("page:beforeremove",a)}e=o(e);var t=e.hasClass("messagebar")?e:e.find(".messagebar");if(0!==t.length&&t.hasClass("messagebar-init")){var n=i.messagebar(t,t.dataset());e.hasClass("page")&&e.on("page:beforeremove",a)}},i.cache=[],i.removeFromCache=function(e){for(var a=!1,t=0;t=0&&(r=e.split("?")[0]),i.params.cache&&!t&&e.indexOf("nocache")<0&&i.params.cacheIgnore.indexOf(r)<0)for(var s=0;s=200&&e.status<300||0===e.status?(i.params.cache&&(i.removeFromCache(r),i.cache.push({url:r,time:(new Date).getTime(),content:e.responseText})),n(e.responseText,!1)):n(e.responseText,!0),i.params.onAjaxComplete&&i.params.onAjaxComplete(e)},error:function(e){n(e.responseText,!0),i.params.onAjaxError&&i.params.onAjaxError(e)}}),a&&(a.xhr=i.xhr),i.xhr},i.pageCallbacks={},i.onPage=function(e,a,t){if(a&&a.split(" ").length>1){for(var n=a.split(" "),r=[],s=0;s0?o.parseUrlQuery(a.url||""):t.f7PageData&&t.f7PageData.query?t.f7PageData.query:{});var r={container:t,url:a.url,query:n,name:o(t).attr("data-page"),view:e,from:a.position,context:a.context,navbarInnerContainer:a.navbarInnerContainer,fromPage:a.fromPage};if(a.fromPage&&!a.fromPage.navbarInnerContainer&&a.oldNavbarInnerContainer&&(a.fromPage.navbarInnerContainer=a.oldNavbarInnerContainer), t.f7PageInitialized&&(e&&e.params.domCache||!e&&o(t).parents(".popup, .popover, .login-screen, .modal, .actions-modal, .picker-modal").length>0))return i.reinitPage(t),i.pluginHook("pageReinit",r),i.params.onPageReinit&&i.params.onPageReinit(i,r),i.triggerPageCallbacks("reinit",r.name,r),void o(r.container).trigger("pageReinit page:reinit",{page:r});t.f7PageInitialized=!0,t.f7PageData=r,!e||a.preloadOnly||a.reloadPrevious||(o(e.container).attr("data-page",r.name),e.activePage=r),i.pluginHook("pageBeforeInit",r),i.params.onPageBeforeInit&&i.params.onPageBeforeInit(i,r),i.triggerPageCallbacks("beforeInit",r.name,r),o(r.container).trigger("pageBeforeInit page:beforeinit",{page:r}),i.initPage(t),i.pluginHook("pageInit",r),i.params.onPageInit&&i.params.onPageInit(i,r),i.triggerPageCallbacks("init",r.name,r),o(r.container).trigger("pageInit page:init",{page:r})}},i.pageRemoveCallback=function(e,a,t){var n;if(a){a.f7PageData&&(n=a.f7PageData.context);var r={container:a,name:o(a).attr("data-page"),view:e,url:a.f7PageData&&a.f7PageData.url,query:a.f7PageData&&a.f7PageData.query,navbarInnerContainer:a.f7PageData&&a.f7PageData.navbarInnerContainer,from:t,context:n};i.pluginHook("pageBeforeRemove",r),i.params.onPageBeforeRemove&&i.params.onPageBeforeRemove(i,r),i.triggerPageCallbacks("beforeRemove",r.name,r),o(r.container).trigger("pageBeforeRemove page:beforeremove",{page:r}),r=null}},i.pageBackCallback=function(e,a,t){var n,r=t.pageContainer;if(r){r.f7PageData&&(n=r.f7PageData.context);var s={container:r,name:o(r).attr("data-page"),url:r.f7PageData&&r.f7PageData.url,query:r.f7PageData&&r.f7PageData.query,view:a,from:t.position,context:n,navbarInnerContainer:r.f7PageData&&r.f7PageData.navbarInnerContainer,swipeBack:t.swipeBack};"after"===e&&(i.pluginHook("pageAfterBack",s),i.params.onPageAfterBack&&i.params.onPageAfterBack(i,s),i.triggerPageCallbacks("afterBack",s.name,s),o(r).trigger("pageAfterBack page:afterback",{page:s})),"before"===e&&(i.pluginHook("pageBack",s),i.params.onPageBack&&i.params.onPageBack(i,s),i.triggerPageCallbacks("back",s.name,s),o(s.container).trigger("pageBack page:back",{page:s}))}},i.pageAnimCallback=function(e,a,t){var n,r=t.pageContainer;if(r){r.f7PageData&&(n=r.f7PageData.context);var s=t.query;s||(s=t.url&&t.url.indexOf("?")>0?o.parseUrlQuery(t.url||""):r.f7PageData&&r.f7PageData.query?r.f7PageData.query:{});var l={container:r,url:t.url,query:s,name:o(r).attr("data-page"),view:a,from:t.position,context:n,swipeBack:t.swipeBack,navbarInnerContainer:r.f7PageData&&r.f7PageData.navbarInnerContainer,fromPage:t.fromPage},p=t.oldPage,d=t.newPage;if(r.f7PageData=l,"after"===e&&(i.pluginHook("pageAfterAnimation",l),i.params.onPageAfterAnimation&&i.params.onPageAfterAnimation(i,l),i.triggerPageCallbacks("afterAnimation",l.name,l),o(l.container).trigger("pageAfterAnimation page:afteranimation",{page:l})),"before"===e){o(a.container).attr("data-page",l.name),a&&(a.activePage=l),d.hasClass("no-navbar")&&!p.hasClass("no-navbar")&&a.hideNavbar(),d.hasClass("no-navbar")||!p.hasClass("no-navbar")&&!p.hasClass("no-navbar-by-scroll")||a.showNavbar(),d.hasClass("no-toolbar")&&!p.hasClass("no-toolbar")&&a.hideToolbar(),d.hasClass("no-toolbar")||!p.hasClass("no-toolbar")&&!p.hasClass("no-toolbar-by-scroll")||a.showToolbar();var c;d.hasClass("no-tabbar")&&!p.hasClass("no-tabbar")&&(c=o(a.container).find(".tabbar"),0===c.length&&(c=o(a.container).parents("."+i.params.viewsClass).find(".tabbar")),i.hideToolbar(c)),d.hasClass("no-tabbar")||!p.hasClass("no-tabbar")&&!p.hasClass("no-tabbar-by-scroll")||(c=o(a.container).find(".tabbar"),0===c.length&&(c=o(a.container).parents("."+i.params.viewsClass).find(".tabbar")),i.showToolbar(c)),p.removeClass("no-navbar-by-scroll no-toolbar-by-scroll"),i.pluginHook("pageBeforeAnimation",l),i.params.onPageBeforeAnimation&&i.params.onPageBeforeAnimation(i,l),i.triggerPageCallbacks("beforeAnimation",l.name,l),o(l.container).trigger("pageBeforeAnimation page:beforeanimation",{page:l})}}},i.initPage=function(e){e=o(e),0!==e.length&&(i.sizeNavbars&&i.sizeNavbars(e.parents("."+i.params.viewClass)[0]),i.initPageMessages&&i.initPageMessages(e),i.initFormsStorage&&i.initFormsStorage(e),i.initSmartSelects&&i.initSmartSelects(e),i.initPageSwiper&&i.initPageSwiper(e),i.initPullToRefresh&&i.initPullToRefresh(e),i.initPageInfiniteScroll&&i.initPageInfiniteScroll(e),i.initSearchbar&&i.initSearchbar(e),i.initPageMessagebar&&i.initPageMessagebar(e),i.initPageScrollToolbars&&i.initPageScrollToolbars(e),i.initImagesLazyLoad&&i.initImagesLazyLoad(e),i.initPageProgressbar&&i.initPageProgressbar(e),i.initPageResizableTextarea&&i.initPageResizableTextarea(e),i.params.material&&i.initPageMaterialPreloader&&i.initPageMaterialPreloader(e),i.params.material&&i.initPageMaterialInputs&&i.initPageMaterialInputs(e),i.params.material&&i.initPageMaterialTabbar&&i.initPageMaterialTabbar(e))},i.reinitPage=function(e){e=o(e),0!==e.length&&(i.sizeNavbars&&i.sizeNavbars(e.parents("."+i.params.viewClass)[0]),i.reinitPageSwiper&&i.reinitPageSwiper(e),i.reinitLazyLoad&&i.reinitLazyLoad(e))},i.initPageWithCallback=function(e){e=o(e);var a=e.parents("."+i.params.viewClass);if(0!==a.length){var t=a[0].f7View||void 0,n=t&&t.url?t.url:void 0;a&&e.attr("data-page")&&a.attr("data-page",e.attr("data-page")),i.pageInitCallback(t,{pageContainer:e[0],url:n,position:"center"})}},i.router={_remove:function(e){i.params.routerRemoveTimeout||i.params.routerRemoveWithTimeout?setTimeout(function(){o(e).remove()},0):o(e).remove()},_modalsSelector:".popup, .modal, .popover, .actions-modal, .picker-modal, .login-screen",temporaryDom:document.createElement("div"),findElement:function(e,a,t,n){a=o(a),n&&(e+=":not(.cached)");var r=a.find(e).filter(function(e,a){return 0===o(a).parents(i.router._modalsSelector).length});return r.length>1&&("string"==typeof t.selector&&(r=a.find(t.selector+" "+e)),r.length>1&&(r=a.find("."+i.params.viewMainClass+" "+e))),1===r.length?r:(n||(r=i.router.findElement(e,a,t,!0)),r&&1===r.length?r:r&&r.length>1?o(r[0]):void 0)},animatePages:function(e,a,t){var n="page-on-center page-on-right page-on-left";"to-left"===t&&(e.removeClass(n).addClass("page-from-center-to-left"),a.removeClass(n).addClass("page-from-right-to-center")),"to-right"===t&&(e.removeClass(n).addClass("page-from-left-to-center"),a.removeClass(n).addClass("page-from-center-to-right"))},prepareNavbar:function(e,a,t){o(e).find(".sliding").each(function(){var e=o(this),a="right"===t?this.f7NavbarRightOffset:this.f7NavbarLeftOffset;i.params.animateNavBackIcon&&e.hasClass("left")&&e.find(".back .icon").length>0&&e.find(".back .icon").transform("translate3d("+-a+"px,0,0)"),e.transform("translate3d("+a+"px,0,0)")})},animateNavbars:function(e,a,t){var n="navbar-on-right navbar-on-center navbar-on-left";"to-left"===t&&(a.removeClass(n).addClass("navbar-from-right-to-center"),a.find(".sliding").each(function(){var e=o(this);e.transform("translate3d(0px,0,0)"),i.params.animateNavBackIcon&&e.hasClass("left")&&e.find(".back .icon").length>0&&e.find(".back .icon").transform("translate3d(0px,0,0)")}),e.removeClass(n).addClass("navbar-from-center-to-left"),e.find(".sliding").each(function(){var e,t=o(this);i.params.animateNavBackIcon&&(t.hasClass("center")&&a.find(".sliding.left .back .icon").length>0&&(e=a.find(".sliding.left .back span"),e.length>0&&(this.f7NavbarLeftOffset+=e[0].offsetLeft)),t.hasClass("left")&&t.find(".back .icon").length>0&&t.find(".back .icon").transform("translate3d("+-this.f7NavbarLeftOffset+"px,0,0)")),t.transform("translate3d("+this.f7NavbarLeftOffset+"px,0,0)")})),"to-right"===t&&(e.removeClass(n).addClass("navbar-from-left-to-center"),e.find(".sliding").each(function(){var e=o(this);e.transform("translate3d(0px,0,0)"),i.params.animateNavBackIcon&&e.hasClass("left")&&e.find(".back .icon").length>0&&e.find(".back .icon").transform("translate3d(0px,0,0)")}),a.removeClass(n).addClass("navbar-from-center-to-right"),a.find(".sliding").each(function(){var e=o(this);i.params.animateNavBackIcon&&e.hasClass("left")&&e.find(".back .icon").length>0&&e.find(".back .icon").transform("translate3d("+-this.f7NavbarRightOffset+"px,0,0)"),e.transform("translate3d("+this.f7NavbarRightOffset+"px,0,0)")}))},preprocess:function(e,a,t,n){i.pluginHook("routerPreprocess",e,a,t,n),a=i.pluginProcess("preprocess",a),e&&e.params&&e.params.preprocess?(a=e.params.preprocess(a,t,n),"undefined"!=typeof a&&n(a)):i.params.preprocess?(a=i.params.preprocess(a,t,n),"undefined"!=typeof a&&n(a)):n(a)},preroute:function(e,a,t){return t&&(a.isBack=!0),i.pluginHook("routerPreroute",e,a),!!(i.params.preroute&&i.params.preroute(e,a)===!1||e&&e.params.preroute&&e.params.preroute(e,a)===!1)},template7Render:function(e,a){var t,n,r=a.url,s=a.content,p=a.content,d=a.context,c=a.contextName,u=a.template;if("string"==typeof s?r?i.template7Cache[r]&&!a.ignoreCache?n=l.cache[r]:(n=l.compile(s),l.cache[r]=n):n=l.compile(s):u&&(n=u),d)t=d,d&&r&&(e.contextCache[r]=d);else{if(c)if(c.indexOf(".")>=0){for(var m=c.split("."),f=l.data[m[0]],h=1;h1)for(var P=0;P1){for(l=0;l1&&(r=r.filter(function(e,a){if(a!==k)return a})),(e.params.domCache||k)&&n.removeClass("cached"),e.params.dynamicNavbar)if(u=!0,d=b?w.find('.navbar-inner[data-page="'+b+'"]'):i.router.findElement(".navbar-inner",i.router.temporaryDom,e),d&&0!==d.length||(d=n.find(".navbar-inner"),d&&0!==d.length?d.parent(".navbar").length>0&&d.prependTo(n):u=!1),u&&n.find(".navbar").length>0&&i.router._remove(n.find(".navbar").filter(function(e,a){return 0===o(a).parents(i.router._modalsSelector).length})),c=w.children(".navbar"),a.reload)p=c.find(".navbar-inner:not(.cached):last-child");else if(p=c.find(".navbar-inner:not(.cached)"),p.length>0){for(l=0;l=0?(r.addClass("cached"),u&&p.addClass("cached")):(i.pageRemoveCallback(e,r[0],m),u&&i.navbarRemoveCallback(e,r[0],c[0],p[0]),i.router._remove(r),u&&i.router._remove(p))),i.pageInitCallback(e,{pageContainer:n[0],url:f,position:a.reload?m:"right",navbarInnerContainer:u?d&&d[0]:void 0,oldNavbarInnerContainer:u?p&&p[0]:void 0,context:g.context||a.context,query:a.query,fromPage:r&&r.length&&r[0].f7PageData,reload:a.reload,reloadPrevious:a.reloadPrevious}),u&&i.navbarInitCallback(e,n[0],c[0],d[0],f,a.reload?m:"right"),a.reload)return e.allowPageChange=!0,void(O&&e.refreshPreviousPage());u&&y&&i.router.prepareNavbar(d,p,"right");n[0].clientLeft;i.pageAnimCallback("before",e,{pageContainer:n[0],url:f,position:"right",oldPage:r,newPage:n,query:a.query,fromPage:r&&r.length&&r[0].f7PageData}),y?(i.params.material&&i.params.materialPageLoadDelay?setTimeout(function(){i.router.animatePages(r,n,"to-left",e)},i.params.materialPageLoadDelay):i.router.animatePages(r,n,"to-left",e),u&&setTimeout(function(){i.router.animateNavbars(p,d,"to-left",e)},0),n.animationEnd(function(){t()})):(u&&d.find(".sliding, .sliding .back .icon").transform(""),t())},i.router.load=function(e,a){function t(t){i.router.preprocess(e,t,n,function(t){a.content=t,i.router._load(e,a)})}if(a=a||{},i.router.preroute(e,a))return!1;var n=a.url,r=a.content,s=a.pageName,l=a.pageElement;s&&s.indexOf("?")>0&&(a.query=o.parseUrlQuery(s),a.pageName=s=s.split("?")[0]);var p=a.template;return e.params.reloadPages===!0&&(a.reload=!0),!!e.allowPageChange&&(!(n&&e.url===n&&!a.reload&&!e.params.allowDuplicateUrls)&&(e.allowPageChange=!1,i.xhr&&e.xhr&&e.xhr===i.xhr&&(i.xhr.abort(),i.xhr=!1),r||s||l?void t(r):p?void i.router._load(e,a):a.url&&"#"!==a.url?void i.get(a.url,e,a.ignoreCache,function(a,n){return n?void(e.allowPageChange=!0):void t(a)}):void(e.allowPageChange=!0)))},i.router._back=function(e,a){function t(){i.pageBackCallback("after",e,{pageContainer:l[0],url:h,position:"center",oldPage:l,newPage:p}),i.pageAnimCallback("after",e,{pageContainer:p[0],url:h,position:"left",oldPage:l,newPage:p,query:a.query,fromPage:l&&l.length&&l[0].f7PageData}),i.router.afterBack(e,l[0],p[0])}function n(){i.pageBackCallback("before",e,{pageContainer:l[0],url:h,position:"center",oldPage:l,newPage:p}),i.pageAnimCallback("before",e,{pageContainer:p[0],url:h,position:"left",oldPage:l,newPage:p,query:a.query,fromPage:l&&l.length&&l[0].f7PageData}),w?(i.router.animatePages(p,l,"to-right",e),f&&setTimeout(function(){i.router.animateNavbars(c,d,"to-right",e)},0),p.animationEnd(function(){t()})):(f&&c.find(".sliding, .sliding .back .icon").transform(""),t())}function r(){if(i.router.temporaryDom.innerHTML="","string"==typeof g||h&&"string"==typeof g)i.router.temporaryDom.innerHTML=v.content;else if("length"in g&&g.length>1)for(var a=0;a=0)t.length&&t[0]!==p[0]&&t.addClass("cached"),f&&r.length&&r[0]!==c[0]&&r.addClass("cached");else{var s=f&&r.length;t.length?(i.pageRemoveCallback(e,t[0],"right"),s&&i.navbarRemoveCallback(e,t[0],u[0],r[0]),i.router._remove(t),s&&i.router._remove(r)):s&&(i.navbarRemoveCallback(e,t[0],u[0],r[0]),i.router._remove(r))}M=S.children(".page:not(.cached)"),f&&(m=P.children(".navbar").find(".navbar-inner:not(.cached)")),e.history.indexOf(h)>=0?e.history=e.history.slice(0,e.history.indexOf(h)+2):e.history[[e.history.length-2]]?e.history[e.history.length-2]=h:e.history.unshift(h)}if(l=o(M[M.length-1]),e.params.domCache&&l[0]===p[0]&&(l=S.children(".page.page-on-center"),0===l.length&&e.activePage&&(l=o(e.activePage.container))),f&&!d&&(d=o(m[m.length-1]),e.params.domCache&&(d[0]===c[0]&&(d=u.children(".navbar-inner.navbar-on-center:not(.cached)")),0===d.length&&(d=u.children('.navbar-inner[data-page="'+l.attr("data-page")+'"]'))),0!==d.length&&c[0]!==d[0]||(f=!1)),f&&(I&&c.insertBefore(d),c[0].f7RelatedPage=p[0],p[0].f7RelatedNavbar=c[0]),I&&p.insertBefore(l),i.pageInitCallback(e,{pageContainer:p[0],url:h,position:"left",navbarInnerContainer:f?c[0]:void 0,oldNavbarInnerContainer:f?d&&d[0]:void 0,context:v.context,query:a.query,fromPage:l&&l.length&&l[0].f7PageData,preloadOnly:C}),f&&i.navbarInitCallback(e,p[0],u[0],c[0],h,"right"),f&&c.hasClass("navbar-on-left")&&w&&i.router.prepareNavbar(c,d,"left"),C)return void(e.allowPageChange=!0);e.url=h;p[0].clientLeft;n(),i.params.pushState&&e.main&&("undefined"==typeof y&&(y=!0),!C&&history.state&&y&&history.back())}a=a||{},i.pluginHook("routerBack",e,a);var l,p,d,c,u,m,f,h=a.url,g=a.content,v={content:a.content},b=a.template,w=a.animatePages,C=a.preloadOnly,y=a.pushState,x=(a.ignoreCache,a.force),T=a.pageName,k=a.pageElement,P=o(e.container),S=o(e.pagesContainer),M=S.children(".page:not(.cached)"),I=!0;return"undefined"==typeof w&&(w=e.params.animatePages),(i.params.template7Pages&&"string"==typeof g||b)&&(v=i.router.template7Render(e,a),v.content&&!g&&(g=v.content)),M.length>1&&!x?C?void(e.allowPageChange=!0):(e.url=e.history[e.history.length-2],h=e.url,p=o(M[M.length-2]),l=o(M[M.length-1]),e.params.dynamicNavbar&&(f=!0,m=P.children(".navbar").find(".navbar-inner:not(.cached)"),c=o(m[0]),d=o(m[1]),0!==c.length&&0!==d.length&&d[0]!==c[0]||(f=!1)),I=!1,void s()):x?h&&h===e.url||T&&e.activePage&&e.activePage.name===T?void(e.allowPageChange=!0):g?(r(),void s()):T&&e.params.domCache?(T&&(h="#"+T),p=o(P).find('.page[data-page="'+T+'"]'),p[0].f7PageData&&p[0].f7PageData.url&&(h=p[0].f7PageData.url),e.params.dynamicNavbar&&(c=o(P).children(".navbar").find('.navbar-inner[data-page="'+T+'"]'),0===c.length&&p[0].f7RelatedNavbar&&(c=o(p[0].f7RelatedNavbar)),0===c.length&&p[0].f7PageData&&(c=o(p[0].f7PageData.navbarInnerContainer))),void s()):k&&h?(p=o(k),e.params.dynamicNavbar&&(c=p.find(".navbar-inner").filter(function(e,a){return 0===o(a).parents(i.router._modalsSelector).length}),c.length>0&&(p.prepend(c),i.router._remove(p.find(".navbar").filter(function(e,a){return 0===o(a).parents(i.router._modalsSelector).length})))),void s()):void(e.allowPageChange=!0):(C||(e.url=e.history[e.history.length-2],h=e.url),g?(r(),void s()):T?(p=o(P).find('.page[data-page="'+T+'"]'),e.params.dynamicNavbar&&(c=o(P).children(".navbar").find('.navbar-inner[data-page="'+T+'"]'),0===c.length&&p[0].f7RelatedNavbar&&(c=o(p[0].f7RelatedNavbar)),0===c.length&&p[0].f7PageData&&(c=o(p[0].f7PageData.navbarInnerContainer))),void s()):h&&h in e.pageElementsCache?(p=e.pageElementsCache[h].page,c=e.pageElementsCache[h].navbarInner,void s()):void(e.allowPageChange=!0))},i.router.back=function(e,a){function t(t){i.router.preprocess(e,t,n,function(t){a.content=t,i.router._back(e,a)})}if(a=a||{},i.router.preroute(e,a,!0))return!1;var n=a.url,r=a.content,s=a.pageName,l=a.pageElement;s&&s.indexOf("?")>0&&(a.query=o.parseUrlQuery(s),a.pageName=s=s.split("?")[0]);var p=a.force;if(!e.allowPageChange)return!1;e.allowPageChange=!1,i.xhr&&e.xhr&&e.xhr===i.xhr&&(i.xhr.abort(),i.xhr=!1);var d=o(e.pagesContainer).find(".page:not(.cached)");if(d.length>1&&!p)return void i.router._back(e,a);if(p){if(!n&&r)return void t(r);if(!n&&s)return s&&(n="#"+s),void t();if(n&&l)return void t();if(n)return void i.get(a.url,e,a.ignoreCache,function(a,n){return n?void(e.allowPageChange=!0):void t(a)})}else{if(n=e.history[e.history.length-2]||a.url,a.url||(a.url=n),!n)return void(e.allowPageChange=!0);if(0===n.indexOf("#")&&e.contentCache[n])return void t(e.contentCache[n]);if(0===n.indexOf("#")&&e.params.domCache)return s||(a.pageName=n.split("#")[1]),void t();if(n&&n in e.pageElementsCache)t();else if(0!==n.indexOf("#"))return void i.get(a.url,e,a.ignoreCache,function(a,n){return n?void(e.allowPageChange=!0):void t(a)})}e.allowPageChange=!0},i.router.afterBack=function(e,a,t){a=o(a),t=o(t),e.params.domCache&&e.initialPages.indexOf(a[0])>=0?a.removeClass("page-from-center-to-right").addClass("cached"):(i.pageRemoveCallback(e,a[0],"right"),i.router._remove(a)),t.removeClass("page-from-left-to-center page-on-left").addClass("page-on-center"),e.allowPageChange=!0;var n,r=e.history.pop();if(e.params.dynamicNavbar){var s=o(e.container).children(".navbar").find(".navbar-inner:not(.cached)"),l=o(a[0].f7RelatedNavbar||s[1]);e.params.domCache&&e.initialNavbars.indexOf(l[0])>=0?l.removeClass("navbar-from-center-to-right").addClass("cached"):(i.navbarRemoveCallback(e,a[0],void 0,l[0]),i.router._remove(l)),n=o(s[0]).removeClass("navbar-on-left navbar-from-left-to-center").addClass("navbar-on-center")}if(e.params.domCache&&o(e.container).find(".page.cached").each(function(){var a=o(this),t=a[0].f7PageData&&a[0].f7PageData.url;t&&e.history.indexOf(t)<0&&e.initialPages.indexOf(this)<0&&(i.pageRemoveCallback(e,a[0],"right"),a[0].f7RelatedNavbar&&e.params.dynamicNavbar&&i.navbarRemoveCallback(e,a[0],void 0,a[0].f7RelatedNavbar),i.router._remove(a),a[0].f7RelatedNavbar&&e.params.dynamicNavbar&&i.router._remove(a[0].f7RelatedNavbar))}),!e.params.domCache&&r&&r.indexOf("#")>-1&&r in e.contentCache&&e.history.indexOf(r)===-1&&(e.contentCache[r]=null,delete e.contentCache[r]),r&&r in e.pageElementsCache&&e.history.indexOf(r)===-1&&(e.pageElementsCache[r]=null,delete e.pageElementsCache[r]),r&&r in e.contextCache&&e.history.indexOf(r)===-1&&(e.contextCache[r]=null,delete e.contextCache[r]),i.params.pushState&&e.main&&i.pushStateClearQueue(),e.params.preloadPreviousPage)if(e.params.domCache&&e.history.length>1){var p,d,c=e.history[e.history.length-2];c&&e.pagesCache[c]?(p=o(e.container).find('.page[data-page="'+e.pagesCache[c]+'"]'),p.next(".page")[0]!==t[0]&&p.insertBefore(t),n&&(d=o(e.container).children(".navbar").find('.navbar-inner[data-page="'+e.pagesCache[c]+'"]'),d&&0!==d.length||(d=n.prev(".navbar-inner.cached")),d.next(".navbar-inner")[0]!==n[0]&&d.insertBefore(n))):(p=t.prev(".page.cached"),n&&(d=n.prev(".navbar-inner.cached"))),p&&p.length>0&&p.removeClass("cached page-on-right page-on-center").addClass("page-on-left"),d&&d.length>0&&d.removeClass("cached navbar-on-right navbar-on-center").addClass("navbar-on-left")}else i.router.back(e,{preloadOnly:!0})};var f=document.createElement("div");i.modalStack=[],i.modalStackClearQueue=function(){i.modalStack.length&&i.modalStack.shift()()},i.modal=function(e){e=e||{};var a="";if(i.params.modalTemplate)i._compiledTemplates.modal||(i._compiledTemplates.modal=l.compile(i.params.modalTemplate)),a=i._compiledTemplates.modal(e);else{var t="";if(e.buttons&&e.buttons.length>0)for(var n=0;n'+e.buttons[n].text+"";var r=e.title?'":"",s=e.text?'":"",p=e.afterText?e.afterText:"",d=e.buttons&&0!==e.buttons.length?"":"modal-no-buttons",c=e.verticalButtons?"modal-buttons-vertical":"",u=e.buttons&&e.buttons.length>0?'":"";a='"}f.innerHTML=a;var m=o(f).children();return i.root.append(m[0]),m.find(".modal-button").each(function(a,t){o(t).on("click",function(t){e.buttons[a].close!==!1&&i.closeModal(m),e.buttons[a].onClick&&e.buttons[a].onClick(m,t),e.onClick&&e.onClick(m,a)})}),i.openModal(m),m[0]},i.alert=function(e,a,t){return"function"==typeof a&&(t=arguments[1],a=void 0),i.modal({text:e||"",title:"undefined"==typeof a?i.params.modalTitle:a,buttons:[{text:i.params.modalButtonOk,bold:!0,onClick:t}]})},i.confirm=function(e,a,t,n){return"function"==typeof a&&(n=arguments[2],t=arguments[1],a=void 0),i.modal({text:e||"",title:"undefined"==typeof a?i.params.modalTitle:a,buttons:[{text:i.params.modalButtonCancel,onClick:n},{text:i.params.modalButtonOk,bold:!0,onClick:t}]})},i.prompt=function(e,a,t,n){return"function"==typeof a&&(n=arguments[2],t=arguments[1],a=void 0),i.modal({text:e||"",title:"undefined"==typeof a?i.params.modalTitle:a,afterText:'
',buttons:[{text:i.params.modalButtonCancel},{text:i.params.modalButtonOk,bold:!0}],onClick:function(e,a){0===a&&n&&n(o(e).find(".modal-text-input").val()),1===a&&t&&t(o(e).find(".modal-text-input").val())}})},i.modalLogin=function(e,a,t,n){return"function"==typeof a&&(n=arguments[2],t=arguments[1],a=void 0),i.modal({text:e||"",title:"undefined"==typeof a?i.params.modalTitle:a,afterText:'',buttons:[{text:i.params.modalButtonCancel},{text:i.params.modalButtonOk,bold:!0}],onClick:function(e,a){var r=o(e).find('.modal-text-input[name="modal-username"]').val(),i=o(e).find('.modal-text-input[name="modal-password"]').val();0===a&&n&&n(r,i),1===a&&t&&t(r,i)}})},i.modalPassword=function(e,a,t,n){return"function"==typeof a&&(n=arguments[2],t=arguments[1],a=void 0),i.modal({text:e||"",title:"undefined"==typeof a?i.params.modalTitle:a,afterText:'
',buttons:[{text:i.params.modalButtonCancel},{text:i.params.modalButtonOk,bold:!0}],onClick:function(e,a){var r=o(e).find('.modal-text-input[name="modal-password"]').val();0===a&&n&&n(r),1===a&&t&&t(r)}})},i.showPreloader=function(e){return i.modal({title:e||i.params.modalPreloaderTitle,text:'
'+(i.params.material?i.params.materialPreloaderHtml:"")+"
",cssClass:"modal-preloader"})},i.hidePreloader=function(){i.closeModal(".modal.modal-in")},i.showIndicator=function(){o(".preloader-indicator-overlay").length>0||i.root.append('
'+(i.params.material?i.params.materialPreloaderHtml:"")+"
")},i.hideIndicator=function(){o(".preloader-indicator-overlay, .preloader-indicator-modal").remove()},i.actions=function(e,a,t){var n,r,s,p=!1;1===arguments.length||2===arguments.length&&"boolean"==typeof arguments[1]?(a=arguments[0],t=arguments[1]):i.device.ios?i.device.ipad&&(p=!0):o(window).width()>=768&&(p=!0),"undefined"==typeof t&&(t=!0),a=a||[],a.length>0&&!o.isArray(a[0])&&(a=[a]);var d;if(p){var c=i.params.modalActionsToPopoverTemplate||'
{{#each this}}
    {{#each this}}{{#if label}}
  • {{text}}
  • {{else}}
  • {{text}}
  • {{/if}}{{/each}}
{{/each}}
';i._compiledTemplates.actionsToPopover||(i._compiledTemplates.actionsToPopover=l.compile(c));var u=i._compiledTemplates.actionsToPopover(a);n=o(i.popover(u,e,!0,t)),r=".list-block ul",s=".list-button"}else{if(i.params.modalActionsTemplate)i._compiledTemplates.actions||(i._compiledTemplates.actions=l.compile(i.params.modalActionsTemplate)),d=i._compiledTemplates.actions(a);else{for(var m="",h=0;h');var v=a[h][g],b=v.label?"actions-modal-label":"actions-modal-button";v.bold&&(b+=" actions-modal-button-bold"),v.color&&(b+=" color-"+v.color),v.bg&&(b+=" bg-"+v.bg),v.disabled&&(b+=" disabled"),m+='
'+v.text+"
",g===a[h].length-1&&(m+="")}d='
'+m+"
"}f.innerHTML=d,n=o(f).children(),i.root.append(n[0]),r=".actions-modal-group",s=".actions-modal-button"}var w=n.find(r);return w.each(function(e,t){var r=e;o(t).children().each(function(e,t){var l,d=e,c=a[r][d];!p&&o(t).is(s)&&(l=o(t)),p&&o(t).find(s).length>0&&(l=o(t).find(s)),l&&l.on("click",function(e){c.close!==!1&&i.closeModal(n),c.onClick&&c.onClick(n,e)})})}),p||i.openModal(n,t),n[0]},i.popover=function(e,a,t,n){function r(){ e.css({left:"",top:""});var t,n,r,i=e.width(),s=e.height(),p=0;l?e.removeClass("popover-on-left popover-on-right popover-on-top popover-on-bottom").css({left:"",top:""}):(t=e.find(".popover-angle"),p=t.width()/2,t.removeClass("on-left on-right on-top on-bottom").css({left:"",top:""}));var d=a.outerWidth(),c=a.outerHeight(),u=a.offset(),m=a.parents(".page");m.length>0&&(u.top=u.top-m[0].scrollTop);var f=o(window).height(),h=o(window).width(),g=0,v=0,b=0,w=l?"bottom":"top";if(l){if(s=f&&(g=f-s-8),v=u.left,v+i>=h-8&&(v=u.left+d-i-8),v<8&&(v=8),"top"===w&&e.addClass("popover-on-top"),"bottom"===w&&e.addClass("popover-on-bottom"),a.hasClass("floating-button-to-popover")&&!e.hasClass("modal-in")){e.addClass("popover-floating-button");var C=v+i/2-(u.left+d/2),y=g+s/2-(u.top+c/2);a.addClass("floating-button-to-popover-in").transform("translate3d("+C+"px, "+y+"px,0)").transitionEnd(function(e){a.hasClass("floating-button-to-popover-in")&&a.addClass("floating-button-to-popover-scale").transform("translate3d("+C+"px, "+y+"px,0) scale("+i/d+", "+s/c+")")}),e.once("popover:close",function(){a.removeClass("floating-button-to-popover-in floating-button-to-popover-scale").addClass("floating-button-to-popover-out").transform("").transitionEnd(function(e){a.removeClass("floating-button-to-popover-out")})}),e.once("popover:closed",function(){e.removeClass("popover-floating-button")})}}else s+p=f&&(g=f-s-5),b-=g),"top"===w||"bottom"===w?(v=d/2+u.left-i/2,b=v,v<5&&(v=5),v+i>h&&(v=h-i-5),"top"===w&&t.addClass("on-bottom"),"bottom"===w&&t.addClass("on-top"),b-=v,n=i/2-p+b,n=Math.max(Math.min(n,i-2*p-13),13),t.css({left:n+"px"})):"middle"===w&&(v=u.left-i-p,t.addClass("on-right"),(v<5||v+i>h)&&(v<5&&(v=u.left+d+p),v+i>h&&(v=h-i-5),t.removeClass("on-right").addClass("on-left")),r=s/2-p+b,r=Math.max(Math.min(r,s-2*p-13),13),t.css({top:r+"px"}));e.css({top:g+"px",left:v+"px"})}if("undefined"==typeof t&&(t=!0),"undefined"==typeof n&&(n=!0),"string"==typeof e&&e.indexOf("<")>=0){var s=document.createElement("div");if(s.innerHTML=e.trim(),!(s.childNodes.length>0))return!1;e=s.childNodes[0],t&&e.classList.add("remove-on-close"),i.root.append(e)}if(e=o(e),a=o(a),0===e.length||0===a.length)return!1;0===e.parents("body").length&&(t&&e.addClass("remove-on-close"),i.root.append(e[0])),0!==e.find(".popover-angle").length||i.params.material||e.append('
'),e.show();var l=i.params.material;return r(),o(window).on("resize",r),e.on("popover:close",function(){o(window).off("resize",r)}),i.openModal(e,n),e[0]},i.popup=function(e,a,t){if("undefined"==typeof a&&(a=!0),"undefined"==typeof t&&(t=!0),"string"==typeof e&&e.indexOf("<")>=0){var n=document.createElement("div");if(n.innerHTML=e.trim(),!(n.childNodes.length>0))return!1;e=n.childNodes[0],a&&e.classList.add("remove-on-close"),i.root.append(e)}return e=o(e),0!==e.length&&(0===e.parents("body").length&&(a&&e.addClass("remove-on-close"),i.root.append(e[0])),e.show(),i.openModal(e,t),e[0])},i.pickerModal=function(e,a,t){if("undefined"==typeof a&&(a=!0),"undefined"==typeof t&&(t=!0),"string"==typeof e&&e.indexOf("<")>=0){if(e=o(e),!(e.length>0))return!1;a&&e.addClass("remove-on-close"),i.root.append(e[0])}return e=o(e),0!==e.length&&(0===e.parents("body").length&&(a&&e.addClass("remove-on-close"),i.root.append(e[0])),o(".picker-modal.modal-in:not(.modal-out)").length>0&&!e.hasClass("modal-in")&&i.closeModal(".picker-modal.modal-in:not(.modal-out)"),e.show(),i.openModal(e,t),e[0])},i.loginScreen=function(e,a){return e||(e=".login-screen"),"undefined"==typeof a&&(a=!0),e=o(e),0!==e.length&&(o(".login-screen.modal-in:not(.modal-out)").length>0&&!e.hasClass("modal-in")&&i.closeModal(".login-screen.modal-in:not(.modal-out)"),e.show(),i.openModal(e,a),e[0])},i.openModal=function(e,a){"undefined"==typeof a&&(a=!0),e=o(e),e[a?"removeClass":"addClass"]("not-animated");var t=e.hasClass("modal"),n=e.hasClass("popover"),r=e.hasClass("popup"),s=e.hasClass("login-screen"),l=e.hasClass("picker-modal"),p=e.hasClass("actions-modal"),d="modal";if(n&&(d="popover"),r&&(d="popup"),s&&(d="loginscreen"),l&&(d="picker"),p&&(d="actions"),o(".modal.modal-in:not(.modal-out)").length&&i.params.modalStack&&t)return void i.modalStack.push(function(){i.openModal(e)});if(!0!==e.data("f7-modal-shown")){e.data("f7-modal-shown",!0);var c=e.parent();i.params.modalsMoveToRoot&&!c.is(i.root)&&(i.root.append(e),e.once(d+":closed",function(){c.append(e)})),e.once(d+":close",function(){e.removeData("f7-modal-shown")}),t&&(e.show(),e.css({marginTop:-Math.round(e.outerHeight()/2)+"px"}));var u;s||l||(0!==o(".modal-overlay").length||r||i.root.append(''),0===o(".popup-overlay").length&&r&&i.root.append(''),u=o(r?".popup-overlay":".modal-overlay")),i.params.material&&l&&e.hasClass("picker-calendar")&&(0!==o(".picker-modal-overlay").length||r||i.root.append('
'),u=o(".picker-modal-overlay")),u&&u[a?"removeClass":"addClass"]("not-animated");e[0].clientLeft;return e.trigger("open "+d+":open"),l&&o("body").addClass("with-picker-modal"),e.find("."+i.params.viewClass).length>0&&(e.find(".page").each(function(){i.initPageWithCallback(this)}),e.find(".navbar").each(function(){i.initNavbarWithCallback(this)})),s||l||u.addClass("modal-overlay-visible"),i.params.material&&l&&u&&u.addClass("modal-overlay-visible"),a?e.removeClass("modal-out").addClass("modal-in").transitionEnd(function(a){e.hasClass("modal-out")?e.trigger("closed "+d+":closed"):e.trigger("opened "+d+":opened")}):(e.removeClass("modal-out").addClass("modal-in"),e.trigger("opened "+d+":opened")),!0}},i.closeModal=function(e,a){if("undefined"==typeof a&&(a=!0),e=o(e||".modal-in"),"undefined"==typeof e||0!==e.length){e[a?"removeClass":"addClass"]("not-animated");var t=e.hasClass("modal"),n=e.hasClass("popover"),r=e.hasClass("popup"),s=e.hasClass("login-screen"),l=e.hasClass("picker-modal"),p=e.hasClass("actions-modal"),d="modal";n&&(d="popover"),r&&(d="popup"),s&&(d="loginscreen"),l&&(d="picker"),p&&(d="actions");var c,u=e.hasClass("remove-on-close"),m=e.hasClass("keep-on-close");return r?c=o(".popup-overlay"):l&&i.params.material?c=o(".picker-modal-overlay"):l||(c=o(".modal-overlay")),r?e.length===o(".popup.modal-in").length&&c.removeClass("modal-overlay-visible"):c&&c.length>0&&c.removeClass("modal-overlay-visible"),c&&c[a?"removeClass":"addClass"]("not-animated"),e.trigger("close "+d+":close"),l&&(o("body").removeClass("with-picker-modal"),o("body").addClass("picker-modal-closing")),!n||i.params.material?(a?e.removeClass("modal-in").addClass("modal-out").transitionEnd(function(a){if(e.hasClass("modal-out"))e.trigger("closed "+d+":closed");else if(e.trigger("opened "+d+":opened"),n)return;l&&o("body").removeClass("picker-modal-closing"),r||s||l||n?(e.removeClass("modal-out").hide(),u&&e.length>0&&e.remove()):m||e.remove()}):(e.trigger("closed "+d+":closed"),e.removeClass("modal-in modal-out"),l&&o("body").removeClass("picker-modal-closing"),r||s||l||n?(e.hide(),u&&e.length>0&&e.remove()):m||e.remove()),t&&i.params.modalStack&&i.modalStackClearQueue()):(e.removeClass("modal-in modal-out not-animated").trigger("closed "+d+":closed").hide(),u&&e.remove()),!0}},i.setProgressbar=function(e,a,t){if(e=o(e||i.root),0!==e.length){a&&(a=Math.min(Math.max(a,0),100));var n;if(n=e.hasClass("progressbar")?e:e.children(".progressbar"),0!==n.length&&!n.hasClass("progressbar-infinite")){n[0].clientLeft;return n.children("span").transform("translate3d("+(-100+a)+"%,0,0)"),"undefined"!=typeof t?n.children("span").transition(t):n.children("span").transition(""),n[0]}}},i.showProgressbar=function(e,a,t){if("number"==typeof e&&(e=i.root,a=arguments[0],t=arguments[1]),a&&"string"==typeof a&&parseFloat(a)!==1*a&&(t=a,a=void 0),e=o(e||i.root),0!==e.length){var n;return e.hasClass("progressbar")?n=e:(n=e.children(".progressbar:not(.progressbar-out), .progressbar-infinite:not(.progressbar-out)"),0===n.length&&(n=o("undefined"!=typeof a?'':''),e.append(n))),a&&i.setProgressbar(e,a),n[0]}},i.hideProgressbar=function(e){if(e=o(e||i.root),0!==e.length){var a;a=e.hasClass("progressbar")?e:e.children(".progressbar, .progressbar-infinite"),0!==a.length&&a.hasClass("progressbar-in")&&!a.hasClass("progressbar-out")&&a.removeClass("progressbar-in").addClass("progressbar-out").animationEnd(function(){a.remove(),a=null})}},i.initPageProgressbar=function(e){e=o(e),e.find(".progressbar").each(function(){var e=o(this);0===e.children("span").length&&e.append(""),e.attr("data-progress")&&i.setProgressbar(e,e.attr("data-progress"))})},i.allowPanelOpen=!0,i.openPanel=function(e,a){function t(){s.transitionEnd(function(e){o(e.target).is(s)?(n.hasClass("active")?n.trigger("opened panel:opened"):n.trigger("closed panel:closed"),i.params.material&&o(".panel-overlay").css({display:""}),i.allowPanelOpen=!0):t()})}if("undefined"==typeof a&&(a=!0),!i.allowPanelOpen)return!1;var n=o(".panel-"+e);if(0===n.length||n.hasClass("active"))return!1;i.closePanel(),i.allowPanelOpen=!1;var r=n.hasClass("panel-reveal")?"reveal":"cover";n[a?"removeClass":"addClass"]("not-animated"),n.css({display:"block"}).addClass("active"),n.trigger("open panel:open"),i.params.material&&(o(".panel-overlay")[a?"removeClass":"addClass"]("not-animated"),o(".panel-overlay").show()),n.find("."+i.params.viewClass).length>0&&i.sizeNavbars&&i.sizeNavbars(n.find("."+i.params.viewClass)[0]);var s=(n[0].clientLeft,"reveal"===r?o("."+i.params.viewsClass):n);return a?t():(n.trigger("opened panel:opened"),i.params.material&&o(".panel-overlay").css({display:""}),i.allowPanelOpen=!0),o("body").addClass("with-panel-"+e+"-"+r),!0},i.closePanel=function(e){"undefined"==typeof e&&(e=!0);var a=o(".panel.active");if(0===a.length)return!1;var t=a.hasClass("panel-reveal")?"reveal":"cover",n=a.hasClass("panel-left")?"left":"right";a[e?"removeClass":"addClass"]("not-animated"),a.removeClass("active"),i.params.material&&o(".panel-overlay").removeClass("not-animated");var r="reveal"===t?o("."+i.params.viewsClass):a;a.trigger("close panel:close"),i.allowPanelOpen=!1,e?(r.transitionEnd(function(){a.hasClass("active")||(a.css({display:""}),a.trigger("closed panel:closed"),o("body").removeClass("panel-closing"),i.allowPanelOpen=!0)}),o("body").addClass("panel-closing").removeClass("with-panel-"+n+"-"+t)):(a.css({display:""}),a.trigger("closed panel:closed"),a.removeClass("not-animated"),o("body").removeClass("with-panel-"+n+"-"+t),i.allowPanelOpen=!0)},i.initSwipePanels=function(){function e(e){if(i.allowPanelOpen&&(i.params.swipePanel||i.params.swipePanelOnlyClose)&&!s&&!(o(".modal-in, .photo-browser-in").length>0)&&(i.params.swipePanelCloseOpposite||i.params.swipePanelOnlyClose||!(o(".panel.active").length>0)||n.hasClass("active"))&&!(e.target&&"input"===e.target.nodeName.toLowerCase()&&"range"===e.target.type||o(e.target).closest(".tabs-swipeable-wrap").length>0)){if(w.x="touchstart"===e.type?e.targetTouches[0].pageX:e.pageX,w.y="touchstart"===e.type?e.targetTouches[0].pageY:e.pageY,i.params.swipePanelCloseOpposite||i.params.swipePanelOnlyClose){if(o(".panel.active").length>0)r=o(".panel.active").hasClass("panel-left")?"left":"right";else{if(i.params.swipePanelOnlyClose)return;r=i.params.swipePanel}if(!r)return}if(n=o(".panel.panel-"+r),f=n.hasClass("active"),i.params.swipePanelActiveArea&&!f){if("left"===r&&w.x>i.params.swipePanelActiveArea)return;if("right"===r&&w.xMath.abs(a-w.x))),p)return void(s=!1);if(!v){if(v=a>w.x?"to-right":"to-left","both"===r){if(r=o(".panel.active").length>0?o(".panel.active").hasClass("panel-left")?"left":"right":"to-right"===v?"left":"right",i.params.swipePanelActiveArea>0){if("left"===r&&w.x>i.params.swipePanelActiveArea)return void(s=!1);if("right"===r&&w.x0&&i.sizeNavbars&&i.sizeNavbars(n.find("."+i.params.viewClass)[0])),l=!0,e.preventDefault();var x=f?0:-i.params.swipePanelThreshold;"right"===r&&(x=-x),c=a-w.x+x,"right"===r?(u=c-(f?h:0),u>0&&(u=0),u<-h&&(u=-h)):(u=c+(f?h:0),u<0&&(u=0),u>h&&(u=h)),"reveal"===g?(C.transform("translate3d("+u+"px,0,0)").transition(0),b.transform("translate3d("+u+"px,0,0)").transition(0),n.trigger("panel:swipe",{progress:Math.abs(u/h)}),i.pluginHook("swipePanelSetTransform",C[0],n[0],Math.abs(u/h))):(n.transform("translate3d("+u+"px,0,0)").transition(0),i.params.material&&(b.transition(0),m=Math.abs(u/h),b.css({opacity:m})),n.trigger("panel:swipe",{progress:Math.abs(u/h)}),i.pluginHook("swipePanelSetTransform",C[0],n[0],Math.abs(u/h)))}}function t(e){if(!s||!l)return s=!1,void(l=!1);s=!1,l=!1;var a,t=(new Date).getTime()-d,p=0===u||Math.abs(u)===h;if(a=f?u===-h?"reset":t<300&&Math.abs(u)>=0||t>=300&&Math.abs(u)<=h/2?"left"===r&&u===h?"reset":"swap":"reset":0===u?"reset":t<300&&Math.abs(u)>0||t>=300&&Math.abs(u)>=h/2?"swap":"reset","swap"===a&&(i.allowPanelOpen=!0,f?(i.closePanel(),p&&(n.css({display:""}),o("body").removeClass("panel-closing"))):i.openPanel(r),p&&(i.allowPanelOpen=!0)),"reset"===a)if(f)i.allowPanelOpen=!0,i.openPanel(r);else if(i.closePanel(),p)i.allowPanelOpen=!0,n.css({display:""});else{var c="reveal"===g?C:n;n.trigger("close panel:close"),o("body").addClass("panel-closing"),c.transitionEnd(function(){n.trigger("close panel:closed"),n.css({display:""}),o("body").removeClass("panel-closing"),i.allowPanelOpen=!0})}"reveal"===g&&(C.transition(""),C.transform("")),n.transition("").transform(""),b.css({display:""}).transform("").transition("").css("opacity","")}var n,r;if(i.params.swipePanel){if(n=o(".panel.panel-"+i.params.swipePanel),r=i.params.swipePanel,0===n.length&&"both"!==r)return}else{if(!i.params.swipePanelOnlyClose)return;if(0===o(".panel").length)return}var s,l,p,d,c,u,m,f,h,g,v,b=o(".panel-overlay"),w={},C=o("."+i.params.viewsClass),y=!("touchstart"!==i.touchEvents.start||!i.support.passiveListener)&&{passive:!0,capture:!1};o(document).on(i.touchEvents.start,e,y),o(document).on(i.touchEvents.move,a),o(document).on(i.touchEvents.end,t,y)},i.initImagesLazyLoad=function(e){function a(e){function t(){e.removeClass("lazy").addClass("lazy-loaded"),r?e.css("background-image","url("+s+")"):e.attr("src",s),i.params.imagesLazyLoadSequential&&(u=!1,c.length>0&&a(c.shift()))}function n(){e.removeClass("lazy").addClass("lazy-loaded"),r?e.css("background-image","url("+d+")"):e.attr("src",d),i.params.imagesLazyLoadSequential&&(u=!1,c.length>0&&a(c.shift()))}e=o(e);var r=e.attr("data-background"),s=r?r:e.attr("data-src");if(s){if(i.params.imagesLazyLoadSequential&&u)return void(c.indexOf(e[0])<0&&c.push(e[0]));u=!0;var l=new Image;l.onload=t,l.onerror=n,l.src=s}}function t(){l=e.find(".lazy"),l.each(function(e,t){t=o(t),t.parents(".tab:not(.active)").length>0||n(t[0])&&a(t)})}function n(e){var a=e.getBoundingClientRect(),t=i.params.imagesLazyLoadThreshold||0;return a.top>=0-t&&a.left>=0-t&&a.top<=window.innerHeight+t&&a.left<=window.innerWidth+t}function r(a){var n=a?"off":"on";l[n]("lazy",t),l.parents(".tab")[n]("show",t),e[n]("lazy",t),p[n]("lazy",t),p[n]("scroll",t),o(window)[n]("resize",t)}function s(){r(!0)}e=o(e);var l;if(e.hasClass("lazy")?(l=e,e=l.parents(".page")):l=e.find(".lazy"),0!==l.length){var p;if(e.hasClass("page-content")?(p=e,e=e.parents(".page")):p=e.find(".page-content"),0!==p.length){var d="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABAQMAAAAl21bKAAAAA1BMVEXCwsK592mkAAAACklEQVQI12NgAAAAAgAB4iG8MwAAAABJRU5ErkJggg==";"string"==typeof i.params.imagesLazyLoadPlaceholder&&(d=i.params.imagesLazyLoadPlaceholder),i.params.imagesLazyLoadPlaceholder!==!1&&l.each(function(){o(this).attr("data-src")&&o(this).attr("src",d)});var c=[],u=!1;e[0].f7DestroyImagesLazyLoad=s,r(),e.hasClass("page")&&e.once("page:beforeremove",s),t(),e.once("page:afteranimation",t)}}},i.destroyImagesLazyLoad=function(e){e=o(e),e.length>0&&e[0].f7DestroyImagesLazyLoad&&e[0].f7DestroyImagesLazyLoad()},i.reinitImagesLazyLoad=function(e){e=o(e),e.length>0&&e.trigger("lazy")},i.initPageMaterialPreloader=function(e){o(e).find(".preloader").each(function(){0===o(this).children().length&&o(this).html(i.params.materialPreloaderHtml)})};var h=function(e,a){var t={autoLayout:!0,newMessagesFirst:!1,scrollMessages:!0,scrollMessagesOnlyOnEdge:!1,messageTemplate:'{{#if day}}
{{day}} {{#if time}}, {{time}}{{/if}}
{{/if}}
{{#if name}}
{{name}}
{{/if}}
{{text}}{{#if date}}
{{date}}
{{/if}}
{{#if avatar}}
{{/if}}{{#if label}}
{{label}}
{{/if}}
'};a=a||{};for(var n in t)"undefined"!=typeof a[n]&&null!==a[n]||(a[n]=t[n]);var r=this;if(r.params=a,r.container=o(e),0!==r.container.length)return r.params.autoLayout&&r.container.addClass("messages-auto-layout"),r.params.newMessagesFirst&&r.container.addClass("messages-new-first"),r.pageContainer=r.container.parents(".page").eq(0),r.pageContent=r.pageContainer.find(".page-content"),r.template=Template7.compile(r.params.messageTemplate),r.layout=function(){r.container.hasClass("messages-auto-layout")||r.container.addClass("messages-auto-layout"),r.container.find(".message").each(function(){var e=o(this);if(e.find(".message-text img").length>0){for(var a=e.find(".message-text")[0].childNodes,t=!0,n=0;n0&&e.addClass("message-with-avatar")}),r.container.find(".message").each(function(){var e=o(this),a=e.hasClass("message-sent"),t=e.next(".message-"+(a?"sent":"received")),n=e.prev(".message-"+(a?"sent":"received"));0===t.length?e.addClass("message-last message-with-tail"):e.removeClass("message-last message-with-tail"),0===n.length?e.addClass("message-first"):e.removeClass("message-first"),n.length>0&&n.find(".message-name").length>0&&e.find(".message-name").length>0&&n.find(".message-name").text()!==e.find(".message-name").text()&&(n.addClass("message-last message-with-tail"),e.addClass("message-first"))})},r.appendMessage=function(e,a){return r.addMessage(e,"append",a)},r.prependMessage=function(e,a){return r.addMessage(e,"prepend",a)},r.addMessage=function(e,a,t){return r.addMessages([e],a,t)},r.addMessages=function(e,a,t){"undefined"==typeof t&&(t=!0),"undefined"==typeof a&&(a=r.params.newMessagesFirst?"prepend":"append");var n,i="";for(n=0;n=0,s.onlyImage===!1&&(s.hasImage=!1),t&&(s.position="append"===a?"bottom":"top"),i+=r.template(s))}var o=r.pageContent[0].scrollHeight,l=r.pageContent[0].offsetHeight,p=r.pageContent[0].scrollTop;if(r.container[a](i),r.params.autoLayout&&r.layout(),"prepend"===a&&(r.pageContent[0].scrollTop=p+(r.pageContent[0].scrollHeight-o)),r.params.scrollMessages&&"append"===a&&!r.params.newMessagesFirst||"prepend"===a&&r.params.newMessagesFirst)if(r.params.scrollMessagesOnlyOnEdge){var d=!1;r.params.newMessagesFirst?0===p&&(d=!0):p-(o-l)>=-10&&(d=!0),d&&r.scrollMessages(t?void 0:0)}else r.scrollMessages(t?void 0:0);var c=r.container.find(".message");if(1===e.length)return"append"===a?c[c.length-1]:c[0];var u=[];if("append"===a)for(n=c.length-e.length;nMath.abs(a-E.x))),l)return void(r=!1);if(!s){if(o(".list-block.sortable-opened").length>0)return;c=o(this),u=c.find(".swipeout-content"),m=c.find(".swipeout-actions-right"),f=c.find(".swipeout-actions-left"),h=g=C=y=k=T=null,M=f.hasClass("swipeout-actions-no-fold")||i.params.swipeoutActionsNoFold,I=m.hasClass("swipeout-actions-no-fold")||i.params.swipeoutActionsNoFold,f.length>0&&(h=f.outerWidth(),C=f.children("a"),T=f.find(".swipeout-overswipe")),m.length>0&&(g=m.outerWidth(),y=m.children("a"),k=m.find(".swipeout-overswipe")),b=c.hasClass("swipeout-opened"),b&&(w=c.find(".swipeout-actions-left.swipeout-actions-opened").length>0?"left":"right"),c.removeClass("transitioning"),i.params.swipeoutNoFollow||(c.find(".swipeout-actions-opened").removeClass("swipeout-actions-opened"),c.removeClass("swipeout-opened"))}if(s=!0,e.preventDefault(),d=a-E.x,v=d,b&&("right"===w?v-=g:v+=h),v>0&&0===f.length||v<0&&0===m.length){if(!b)return r=s=!1,u.transform(""),y&&y.length>0&&y.transform(""),void(C&&C.length>0&&C.transform(""));v=0}v<0?x="to-left":v>0?x="to-right":x||(x="to-left");var n,p,O;if(e.f7PreventPanelSwipe=!0,i.params.swipeoutNoFollow)return b?("right"===w&&d>0&&i.swipeoutClose(c),"left"===w&&d<0&&i.swipeoutClose(c)):(d<0&&m.length>0&&i.swipeoutOpen(c,"right"),d>0&&f.length>0&&i.swipeoutOpen(c,"left")),r=!1,void(s=!1);P=!1,S=!1;var z;if(m.length>0)for(O=v/g,v<-g&&(v=-g-Math.pow(-v-g,.8),k.length>0&&(S=!0)),n=0;n0&&z.hasClass("swipeout-overswipe")&&(z.css({left:(S?-p:0)+"px"}),S?z.addClass("swipeout-overswipe-active"):z.removeClass("swipeout-overswipe-active")),z.transform("translate3d("+(v-p*(1+Math.max(O,-1)))+"px,0,0)");if(f.length>0)for(O=v/h,v>h&&(v=h+Math.pow(v-h,.8),T.length>0&&(P=!0)),n=0;n0&&z.hasClass("swipeout-overswipe")&&(z.css({left:(P?p:0)+"px"}),P?z.addClass("swipeout-overswipe-active"):z.removeClass("swipeout-overswipe-active")),C.length>1&&z.css("z-index",C.length-n),z.transform("translate3d("+(v+p*(1-Math.min(O,1)))+"px,0,0)");u.transform("translate3d("+v+"px,0,0)")}}function n(e){if(!r||!s)return r=!1,void(s=!1);r=!1,s=!1;var a,t,n,l,w,T=(new Date).getTime()-p;if(n="to-left"===x?m:f,t="to-left"===x?g:h,a=T<300&&(d<-10&&"to-left"===x||d>10&&"to-right"===x)||T>=300&&Math.abs(v)>t/2?"open":"close",T<300&&(0===Math.abs(v)&&(a="close"),Math.abs(v)===t&&(a="open")),"open"===a){i.swipeoutOpenedEl=c,c.trigger("open swipeout:open"),c.addClass("swipeout-opened transitioning");var k="to-left"===x?-t:t;if(u.transform("translate3d("+k+"px,0,0)"),n.addClass("swipeout-actions-opened"),l="to-left"===x?y:C)for(w=0;w0&&C!==l)for(w=0;w0&&y!==l)for(w=0;w0&&y.transform(""),f.length>0&&C.transform("")))})}var r,s,l,p,d,c,u,m,f,h,g,v,b,w,C,y,x,T,k,P,S,M,I,E={};o(document).on(i.touchEvents.start,function(e){if(i.swipeoutOpenedEl){var a=o(e.target);i.swipeoutOpenedEl.is(a[0])||a.parents(".swipeout").is(i.swipeoutOpenedEl)||a.hasClass("modal-in")||a.hasClass("modal-overlay")||a.hasClass("actions-modal")||a.parents(".actions-modal.modal-in, .modal.modal-in").length>0||i.swipeoutClose(i.swipeoutOpenedEl)}}),e?(o(e).on(i.touchEvents.start,a),o(e).on(i.touchEvents.move,t),o(e).on(i.touchEvents.end,n)):(o(document).on(i.touchEvents.start,".list-block li.swipeout",a),o(document).on(i.touchEvents.move,".list-block li.swipeout",t),o(document).on(i.touchEvents.end,".list-block li.swipeout",n))},i.swipeoutOpen=function(e,a,t){if(e=o(e),2===arguments.length&&"function"==typeof arguments[1]&&(t=a),0!==e.length&&(e.length>1&&(e=o(e[0])),e.hasClass("swipeout")&&!e.hasClass("swipeout-opened"))){a||(a=e.find(".swipeout-actions-right").length>0?"right":"left");var n=e.find(".swipeout-actions-"+a);if(0!==n.length){e.trigger("open swipeout:open").addClass("swipeout-opened").removeClass("transitioning"),n.addClass("swipeout-actions-opened");var r,s=n.children("a"),l=n.outerWidth(),p="right"===a?-l:l;if(s.length>1){for(r=0;r1&&(e=o(e[0])),i.swipeoutOpenedEl=void 0,e.trigger("delete swipeout:delete"),e.css({height:e.outerHeight()+"px"});e[0].clientLeft;e.css({height:"0px"}).addClass("deleting transitioning").transitionEnd(function(){if(e.trigger("deleted swipeout:deleted"),a&&a.call(e[0]),e.parents(".virtual-list").length>0){var t=e.parents(".virtual-list")[0].f7VirtualList,n=e[0].f7VirtualListIndex;t&&"undefined"!=typeof n&&t.deleteItem(n)}else i.params.swipeoutRemoveWithTimeout?setTimeout(function(){e.remove()},0):e.remove()});var t="-100%";e.find(".swipeout-content").transform("translate3d("+t+",0,0)")}},i.sortableToggle=function(e){return e=o(e),0===e.length&&(e=o(".list-block.sortable")),e.toggleClass("sortable-opened"),e.hasClass("sortable-opened")?e.trigger("open sortable:open"):e.trigger("close sortable:close"),e},i.sortableOpen=function(e){return e=o(e),0===e.length&&(e=o(".list-block.sortable")),e.addClass("sortable-opened"),e.trigger("open sortable:open"),e},i.sortableClose=function(e){return e=o(e),0===e.length&&(e=o(".list-block.sortable")),e.removeClass("sortable-opened"),e.trigger("close sortable:close"),e},i.initSortable=function(){function e(e){r=!1,n=!0,s="touchstart"===e.type?e.targetTouches[0].pageY:e.pageY,p=o(this).parent(),v=p.index(),c=p.parent().find("li"),g=p.parents(".sortable"),e.preventDefault(),i.allowPanelOpen=i.allowSwipeout=!1}function a(e){if(n&&p){var a=("touchmove"===e.type?e.targetTouches[0].pageX:e.pageX,"touchmove"===e.type?e.targetTouches[0].pageY:e.pageY);r||(p.addClass("sorting"),g.addClass("sortable-sorting"),u=p[0].offsetTop,m=p.parent().height()-p[0].offsetTop-p.height(),d=p[0].offsetHeight),r=!0,e.preventDefault(),e.f7PreventPanelSwipe=!0,l=a-s;var t=l;t<-u&&(t=-u),t>m&&(t=m),p.transform("translate3d(0,"+t+"px,0)"),h=f=void 0,c.each(function(){var e=o(this);if(e[0]!==p[0]){var a=e[0].offsetTop,n=e.height(),r=p[0].offsetTop+t;r>=a-n/2&&p.index()e.index()?(e.transform("translate3d(0, "+d+"px,0)"),f=void 0,h||(h=e)):o(this).transform("translate3d(0, 0%,0)")}})}}function t(e){if(i.allowPanelOpen=i.allowSwipeout=!0,!n||!r)return n=!1,void(r=!1);e.preventDefault(),c.transform(""),p.removeClass("sorting"),g.removeClass("sortable-sorting");var a,t,s;f&&(p.insertAfter(f),p.trigger("sort sortable:sort",{startIndex:v,newIndex:p.index()})),h&&(p.insertBefore(h),p.trigger("sort sortable:sort",{startIndex:v,newIndex:p.index()})),(f||h)&&g.hasClass("virtual-list")&&(a=g[0].f7VirtualList,t=p[0].f7VirtualListIndex,s=h?h[0].f7VirtualListIndex:f[0].f7VirtualListIndex,a&&a.moveItem(t,s)),f=h=void 0,n=!1,r=!1}var n,r,s,l,p,d,c,u,m,f,h,g,v;o(document).on(i.touchEvents.start,".list-block.sortable .sortable-handler",e),i.support.touch?(o(document).on(i.touchEvents.move,".list-block.sortable .sortable-handler",a),o(document).on(i.touchEvents.end,".list-block.sortable .sortable-handler",t)):(o(document).on(i.touchEvents.move,a),o(document).on(i.touchEvents.end,t))},i.initSmartSelects=function(e){e=o(e);var a;a=e.is(".smart-select")?e:e.find(".smart-select"),0!==a.length&&a.each(function(){var e=o(this),a=e.find("select");if(0!==a.length){var t=a[0];if(0!==t.length){ for(var n,r=[],i=0;i'+r.join(", ")+"");else{var l=s.text();if(s.hasClass("smart-select-value"))for(i=0;i0;s&&i.smartSelectOpen(n,!0)},i.smartSelectOpen=function(e,a){function t(){var a=e.parents(".page-content");if(0!==a.length){var t,n=parseInt(a.css("padding-top"),10),r=parseInt(a.css("padding-bottom"),10),i=a[0].offsetHeight-n-ie.height(),s=a[0].scrollHeight-n-ie.height(),o=e.offset().top-n+e[0].offsetHeight;if(o>i){var l=a.scrollTop()+o-i;l+i>s&&(t=l+i-s+r,i===s&&(t=ie.height()),a.css({"padding-bottom":t+"px"})),a.scrollTop(l,300)}}}function n(a){var t=!0;(a.target===e[0]||o(a.target).parents(e[0]).length>0)&&(t=!1),o(a.target).parents(".picker-modal").length>0&&(t=!1),t&&i.closeModal(".smart-select-picker.modal-in")}function r(e){k.selectedOptions.length>=F?e.find('input[type="checkbox"]').each(function(){this.checked?o(this).parents("li").removeClass("disabled"):o(this).parents("li").addClass("disabled")}):e.find(".disabled").removeClass("disabled")}function s(a){if(a=o(a),C){var t=i.virtualList(a.find(".virtual-list"),{items:R,template:W,height:y||void 0,searchByItem:function(e,a,t){return!!(t.text&&t.text.toLowerCase().indexOf(e.trim().toLowerCase())>=0)}});a.once("popup"===c||"picker"===c?"closed":"pageBeforeRemove",function(){t&&t.destroy&&t.destroy()})}F&&r(a),g&&a.find('input[type="radio"][name="'+q+'"]:checked').parents("label").once("click",function(){"popup"===c?i.closeModal(re):"picker"===c?i.closeModal(ie):d.router.back()}),a.on("change",'input[name="'+q+'"]',function(){var t,n,s,l=this,p=l.value,u=[];if("checkbox"===l.type){for(var m=0;m0)return}else if("picker"===c){if(o(".picker-modal.modal-in").length>0&&!a){if(e[0].f7SmartSelectPicker===o(".picker-modal.modal-in:not(.modal-out)")[0])return;i.closeModal(o(".picker-modal.modal-in:not(.modal-out)"))}}else if(!d)return;var u,m=e.dataset(),f=m.pageTitle||e.find(".item-title").text(),h=m.backText||i.params.smartSelectBackText;u="picker"===c?m.pickerCloseText||m.backText||i.params.smartSelectPickerCloseText:m.popupCloseText||m.backText||i.params.smartSelectPopupCloseText;var g=void 0!==m.backOnSelect?m.backOnSelect:i.params.smartSelectBackOnSelect,v=m.formTheme||i.params.smartSelectFormTheme,b=m.navbarTheme||i.params.smartSelectNavbarTheme,w=m.toolbarTheme||i.params.smartSelectToolbarTheme,C=m.virtualList,y=m.virtualListHeight,x=i.params.material,T=m.pickerHeight||i.params.smartSelectPickerHeight,k=e.find("select")[0],P=o(k),S=P.dataset();if(!(k.disabled||e.hasClass("disabled")||P.hasClass("disabled"))){for(var M,I,E,O,z,D,L,B,N,H,A,R=[],V=(new Date).getTime(),Y=k.multiple?"checkbox":"radio",q=Y+"-"+V,F=P.attr("maxlength"),X=k.name,G=0;G{{groupLabel}}{{else}}{{/if}}'));var W=i._compiledTemplates.smartSelectItem,j="";if(!C)for(var _=0;_')),Q=i._compiledTemplates.smartSelectToolbar({pageTitle:f,closeText:u,openIn:c,toolbarTheme:w,inPicker:"picker"===c})):(i._compiledTemplates.smartSelectNavbar||(i._compiledTemplates.smartSelectNavbar=l.compile(i.params.smartSelectNavbarTemplate||'')),U=i._compiledTemplates.smartSelectNavbar({pageTitle:f,backText:h,closeText:u,openIn:c,navbarTheme:b,inPopup:"popup"===c,inPage:"page"===c,leftTemplate:"popup"===c?(i.params.smartSelectPopupCloseTemplate||(x?'
':'')).replace(/{{closeText}}/g,u):(i.params.smartSelectBackTemplate||(x?'
':'')).replace(/{{backText}}/g,h)}),"page"===c?(J="static",e.parents(".navbar-through").length>0&&(J="through"),e.parents(".navbar-fixed").length>0&&(J="fixed"),Z=e.parents(".page").hasClass("no-toolbar")?"no-toolbar":"",K=e.parents(".page").hasClass("no-navbar")?"no-navbar":"navbar-"+J,$=e.parents(".page").hasClass("no-tabbar")?"no-tabbar":""):J="fixed");var ee,ae,te="smart-select-"+q,ne="undefined"==typeof e.data("searchbar")?i.params.smartSelectSearchbar:"true"===e.data("searchbar");ne&&(ee=e.data("searchbar-placeholder")||"Search",ae=e.data("searchbar-cancel")||"Cancel");var re,ie,se='
',oe=("picker"!==c&&"through"===J?U:"")+'
'+("picker"!==c&&"fixed"===J?U:"")+(ne?se:"")+'
'+("picker"!==c&&"static"===J?U:"")+'
    '+(C?"":j)+"
";"popup"===c?(a?(re=o(".popup.smart-select-popup .view"),re.html(oe)):(re=i.popup('"),re=o(re)),i.initPage(re.find(".page")),s(re)):"picker"===c?(a?(ie=o(".picker-modal.smart-select-picker .view"),ie.html(oe)):(ie=i.pickerModal('
"+Q+'
'+oe+"
"),ie=o(ie),t(),o("html").on("click",n),ie.once("picker:close",function(){e[0].f7SmartSelectPicker=void 0,o("html").off("click",n),e.parents(".page-content").css({paddingBottom:""})}),e[0].f7SmartSelectPicker=ie[0]),i.initPage(ie.find(".page")),s(ie)):(o(document).once("page:init",".smart-select-page",p),d.router.load({content:oe,reload:!!a||void 0}))}}}};var g=function(e,a){var t={cols:1,height:i.params.material?48:44,cache:!0,dynamicHeightBufferSize:1,showFilteredItemsOnly:!1,template:'
  • {{this}}
  • '};a=a||{};for(var n in t)"undefined"==typeof a[n]&&(a[n]=t[n]);var r=this;r.listBlock=o(e),r.params=a,r.items=r.params.items,r.params.showFilteredItemsOnly&&(r.filteredItems=[]),r.params.template&&!r.params.renderItem&&("string"==typeof r.params.template?r.template=l.compile(r.params.template):"function"==typeof r.params.template&&(r.template=r.params.template)),r.pageContent=r.listBlock.parents(".page-content");var s;"undefined"!=typeof r.params.updatableScroll?s=r.params.updatableScroll:(s=!0,i.device.ios&&i.device.osVersion.split(".")[0]<8&&(s=!1),r.params.updatableScroll=s),r.ul=r.params.ul?o(r.params.ul):r.listBlock.children("ul"),0===r.ul.length&&(r.listBlock.append("
      "),r.ul=r.listBlock.children("ul")),r.domCache={},r.displayDomCache={},r.tempDomElement=document.createElement("ul"),r.lastRepaintY=null,r.fragment=document.createDocumentFragment(),r.filterItems=function(e,a){r.filteredItems=[];for(var t=(e[0],e[e.length-1],0);th||!s&&r.pageContent[0].scrollTop+p>=r.pageContent[0].scrollHeight){r.lastRepaintY=t;var n,i,o=r.filteredItems||r.items,l=0,d=0;if(g){var u,f,v=0;for(h=p,u=0;u=t-2*p*r.params.dynamicHeightBufferSize?n=u:l+=f),"undefined"==typeof i&&((v+f>=t+2*p*r.params.dynamicHeightBufferSize||u===r.heights.length-1)&&(i=u+1),d+=f),v+=f;i=Math.min(i,o.length)}else n=(parseInt(t/r.params.height)-c)*r.params.cols,n<0&&(n=0),i=Math.min(n+m*r.params.cols,o.length);var b;r.reachEnd=!1;for(var w=n;wr.items.length)return!1;var a,t=0;if(g)for(var n=0;n=0;a--)r.items.unshift(e[a]);if(r.params.cache){var t={};for(var n in r.domCache)t[parseInt(n,10)+e.length]=r.domCache[n];r.domCache=t}r.update()},r.prependItem=function(e){r.prependItems([e])},r.moveItem=function(e,a){if(e!==a){var t=r.items.splice(e,1)[0];if(a>=r.items.length?(r.items.push(t),a=r.items.length-1):r.items.splice(a,0,t),r.params.cache){var n={};for(var i in r.domCache){var s=parseInt(i,10),o=el)&&(n[s]=r.domCache[s]),s===o&&(n[l]=r.domCache[s]),s>o&&s<=l&&(n[s+p]=r.domCache[s])}r.domCache=n}r.update()}},r.insertItemBefore=function(e,a){if(0===e)return void r.prependItem(a);if(e>=r.items.length)return void r.appendItem(a);if(r.items.splice(e,0,a),r.params.cache){var t={};for(var n in r.domCache){var i=parseInt(n,10);i>=e&&(t[i+1]=r.domCache[i])}r.domCache=t}r.update()},r.deleteItems=function(e){for(var a,t=0,n=0;na&&(t=-n),i+=t,a=e[n];var s=r.items.splice(i,1)[0];if(r.filteredItems&&r.filteredItems.indexOf(s)>=0&&r.filteredItems.splice(r.filteredItems.indexOf(s),1),r.params.cache){var o={};for(var l in r.domCache){var p=parseInt(l,10);p===i?delete r.domCache[i]:parseInt(l,10)>i?o[p-1]=r.domCache[l]:o[p]=r.domCache[l]}r.domCache=o}}r.update()},r.deleteAllItems=function(){r.items=[],delete r.filteredItems,r.params.cache&&(r.domCache={}),r.update()},r.deleteItem=function(e){r.deleteItems([e])},r.clearCache=function(){r.domCache={}},r.update=function(){r.setListSize(),r.render(!0)},r.destroy=function(){r.attachEvents(!0),delete r.items,delete r.domCache},r.init(),r.listBlock[0].f7VirtualList=r,r};i.virtualList=function(e,a){return new g(e,a)},i.reinitVirtualList=function(e){var a=o(e),t=a.find(".virtual-list");if(0!==t.length)for(var n=0;n1)return}h=o(this),h.hasClass("refreshing")||(c=!1,y=!1,d=!0,u=void 0,b=void 0,"touchstart"===e.type&&(p=e.targetTouches[0].identifier),x.x="touchstart"===e.type?e.targetTouches[0].pageX:e.pageX,x.y="touchstart"===e.type?e.targetTouches[0].pageY:e.pageY,f=(new Date).getTime())}function t(e){if(d){var a,t,n;if("touchmove"===e.type){if(p&&e.touches)for(var r=0;rMath.abs(a-x.x))),!u)return void(d=!1);if(v=h[0].scrollTop,"undefined"==typeof b&&0!==v&&(b=!0),!c){if(h.removeClass("transitioning"),v>h[0].offsetHeight)return void(d=!1);C&&(w=h.attr("data-ptr-distance"),w.indexOf("%")>=0&&(w=h[0].offsetHeight*parseInt(w,10)/100)),P=h.hasClass("refreshing")?w:0,k=h[0].scrollHeight===h[0].offsetHeight||"ios"!==i.device.os}return c=!0,m=t-x.y,m>0&&v<=0||v<0?("ios"===i.device.os&&parseInt(i.device.osVersion.split(".")[0],10)>7&&0===v&&!b&&(k=!0),k&&(e.preventDefault(),g=Math.pow(m,.85)+P,h.transform("translate3d(0,"+g+"px,0)")),k&&Math.pow(m,.85)>w||!k&&m>=2*w?(T=!0,h.addClass("pull-up").removeClass("pull-down")):(T=!1,h.removeClass("pull-up").addClass("pull-down")),y||(h.trigger("pullstart ptr:pullstart"),y=!0),h.trigger("pullmove ptr:pullmove",{event:e,scrollTop:v,translate:g,touchesDiff:m}),void 0):(y=!1,h.removeClass("pull-up pull-down"),void(T=!1))}}}function n(e){if(!("touchend"===e.type&&e.changedTouches&&e.changedTouches.length>0&&p&&e.changedTouches[0].identifier!==p)){if(!d||!c)return d=!1,void(c=!1);g&&(h.addClass("transitioning"),g=0),h.transform(""),T?(h.addClass("refreshing"),h.trigger("refresh ptr:refresh",{done:function(){i.pullToRefreshDone(h)}})):h.removeClass("pull-down"),d=!1,c=!1,y&&h.trigger("pullend ptr:pullend")}}function r(){l.off(i.touchEvents.start,a),l.off(i.touchEvents.move,t),l.off(i.touchEvents.end,n)}function s(){r(),S.off("page:beforeremove",s)}var l=o(e);if(l.hasClass("pull-to-refresh-content")||(l=l.find(".pull-to-refresh-content")),l&&0!==l.length){var p,d,c,u,m,f,h,g,v,b,w,C,y,x={},T=!1,k=!1,P=0,S=l.hasClass("page")?l:l.parents(".page"),M=!1;(S.find(".navbar").length>0||S.parents(".navbar-fixed, .navbar-through").length>0||S.hasClass("navbar-fixed")||S.hasClass("navbar-through"))&&(M=!0),S.hasClass("no-navbar")&&(M=!1),M||l.addClass("pull-to-refresh-no-navbar"),h=l,h.attr("data-ptr-distance")?C=!0:w=44;var I=!("touchstart"!==i.touchEvents.start||!i.support.passiveListener)&&{passive:!0,capture:!1};l.on(i.touchEvents.start,a,I),l.on(i.touchEvents.move,t),l.on(i.touchEvents.end,n,I),0!==S.length&&(l[0].f7DestroyPullToRefresh=r,S.on("page:beforeremove",s))}},i.pullToRefreshDone=function(e){e=o(e),0===e.length&&(e=o(".pull-to-refresh-content.refreshing")),e.removeClass("refreshing").addClass("transitioning"),e.transitionEnd(function(){e.removeClass("transitioning pull-up pull-down"),e.trigger("refreshdone ptr:done")})},i.pullToRefreshTrigger=function(e){e=o(e),0===e.length&&(e=o(".pull-to-refresh-content")),e.hasClass("refreshing")||(e.addClass("transitioning refreshing"),e.trigger("refresh ptr:refresh",{done:function(){i.pullToRefreshDone(e)}}))},i.destroyPullToRefresh=function(e){e=o(e);var a=e.hasClass("pull-to-refresh-content")?e:e.find(".pull-to-refresh-content");0!==a.length&&a[0].f7DestroyPullToRefresh&&a[0].f7DestroyPullToRefresh()},i.attachInfiniteScroll=function(e){o(e).on("scroll",n)},i.detachInfiniteScroll=function(e){o(e).off("scroll",n)},i.initPageInfiniteScroll=function(e){function a(){i.detachInfiniteScroll(t),e.off("page:beforeremove",a)}e=o(e);var t=e.find(".infinite-scroll");0!==t.length&&(i.attachInfiniteScroll(t),e.on("page:beforeremove",a))},i.initPageScrollToolbars=function(e){function a(a){e.hasClass("page-on-left")||(m=t[0].scrollTop,v=t[0].scrollHeight,b=t[0].offsetHeight,w=m+b>=v-S,y=d.hasClass("navbar-hidden"),x=c.hasClass("toolbar-hidden"),T=p&&p.hasClass("toolbar-hidden"),w?i.params.showBarsOnPageScrollEnd&&(C="show"):C=u>m?i.params.showBarsOnPageScrollTop||m<=44?"show":"hide":m>44?"hide":"show","show"===C?(f&&n&&y&&(i.showNavbar(d),e.removeClass("no-navbar-by-scroll"),y=!1),h&&r&&x&&(i.showToolbar(c),e.removeClass("no-toolbar-by-scroll"),x=!1),g&&s&&T&&(i.showToolbar(p),e.removeClass("no-tabbar-by-scroll"),T=!1)):(f&&n&&!y&&(i.hideNavbar(d),e.addClass("no-navbar-by-scroll"),y=!0),h&&r&&!x&&(i.hideToolbar(c),e.addClass("no-toolbar-by-scroll"),x=!0),g&&s&&!T&&(i.hideToolbar(p),e.addClass("no-tabbar-by-scroll"),T=!0)),u=m)}e=o(e);var t=e.find(".page-content");if(0!==t.length){var n=(i.params.hideNavbarOnPageScroll||t.hasClass("hide-navbar-on-scroll")||t.hasClass("hide-bars-on-scroll"))&&!(t.hasClass("keep-navbar-on-scroll")||t.hasClass("keep-bars-on-scroll")),r=(i.params.hideToolbarOnPageScroll||t.hasClass("hide-toolbar-on-scroll")||t.hasClass("hide-bars-on-scroll"))&&!(t.hasClass("keep-toolbar-on-scroll")||t.hasClass("keep-bars-on-scroll")),s=(i.params.hideTabbarOnPageScroll||t.hasClass("hide-tabbar-on-scroll"))&&!t.hasClass("keep-tabbar-on-scroll");if(n||r||s){var l=t.parents("."+i.params.viewClass);if(0!==l.length){var p,d=l.find(".navbar"),c=l.find(".toolbar");s&&(p=l.find(".tabbar"),0===p.length&&(p=l.parents("."+i.params.viewsClass).find(".tabbar")));var u,m,f=d.length>0,h=c.length>0,g=p&&p.length>0;u=m=t[0].scrollTop;var v,b,w,C,y,x,T,k=h&&r?c[0].offsetHeight:0,P=g&&s?p[0].offsetHeight:0,S=P||k;t.on("scroll",a),t[0].f7ScrollToolbarsHandler=a}}}},i.destroyScrollToolbars=function(e){e=o(e);var a=e.find(".page-content");if(0!==a.length){var t=a[0].f7ScrollToolbarsHandler;t&&a.off("scroll",a[0].f7ScrollToolbarsHandler)}},i.materialTabbarSetHighlight=function(e,a){if(e=o(e),a=a||e.find(".tab-link.active"),a&&a.length>0){var t,n;e.hasClass("tabbar-scrollable")?(t=a[0].offsetWidth+"px",n=a[0].offsetLeft+"px"):(t=1/e.find(".tab-link").length*100+"%",n=100*(i.rtl?-a.index():a.index())+"%"),e.find(".tab-link-highlight").css({width:t}).transform("translate3d("+n+",0,0)")}},i.initPageMaterialTabbar=function(e){function a(){i.materialTabbarSetHighlight(t)}e=o(e);var t=e.find(".tabbar");0===t.length&&e.hasClass("tabbar")&&(t=e),t.length>0&&(0===t.find(".tab-link-highlight").length&&t.find(".toolbar-inner").append(''),a(),o(window).on("resize",a),e.once("page:beforeremove",function(){o(window).off("resize",a)}))},i.initMaterialTabbar=function(e){return i.initPageMaterialTabbar(e)},i.showTab=function(e,a,t,n){var r=o(e);if(2===arguments.length&&"boolean"==typeof arguments[1]&&(e=arguments[0],t=arguments[1]),3===arguments.length&&"boolean"==typeof arguments[1]&&"boolean"==typeof arguments[2]&&(e=arguments[0],t=arguments[1],n=arguments[2]),"undefined"==typeof t&&(t=!0),0===r.length)return!1;if(r.hasClass("active"))return n&&r.trigger("show tab:show"),!1;var s=r.parent(".tabs");if(0===s.length)return!1;i.allowSwipeout=!0;var l=s.parent().hasClass("tabs-animated-wrap");if(l){s.parent()[t?"removeClass":"addClass"]("not-animated");var p=100*(i.rtl?r.index():-r.index());s.transform("translate3d("+p+"%,0,0)")}var d,c=s.parent().hasClass("tabs-swipeable-wrap");c&&(d=s.parent()[0].swiper,d.activeIndex!==r.index()&&d.slideTo(r.index(),t?void 0:0,!1));var u=s.children(".tab.active").removeClass("active").trigger("hide tab:hide");if(r.addClass("active"),r.trigger("show tab:show"),!l&&!c&&r.find(".navbar").length>0){var m;m=r.hasClass(i.params.viewClass)?r[0]:r.parents("."+i.params.viewClass)[0],i.sizeNavbars(m)}if(a?a=o(a):(a=o("string"==typeof e?'.tab-link[href="'+e+'"]':'.tab-link[href="#'+r.attr("id")+'"]'),(!a||a&&0===a.length)&&o("[data-tab]").each(function(){r.is(o(this).attr("data-tab"))&&(a=o(this))})),0!==a.length){var f;if(u&&u.length>0){var h=u.attr("id");h&&(f=o('.tab-link[href="#'+h+'"]')),(!f||f&&0===f.length)&&o("[data-tab]").each(function(){u.is(o(this).attr("data-tab"))&&(f=o(this))})}if(a&&a.length>0&&(a.addClass("active"),i.params.material)){var g=a.parents(".tabbar");g.length>0&&(0===g.find(".tab-link-highlight").length&&g.find(".toolbar-inner").append(''),i.materialTabbarSetHighlight(g,a))}return f&&f.length>0&&f.removeClass("active"),!0}},i.accordionToggle=function(e){e=o(e),0!==e.length&&(e.hasClass("accordion-item-expanded")?i.accordionClose(e):i.accordionOpen(e))},i.accordionOpen=function(e){e=o(e);var a=e.parents(".accordion-list").eq(0),t=e.children(".accordion-item-content");0===t.length&&(t=e.find(".accordion-item-content"));var n=a.length>0&&e.parent().children(".accordion-item-expanded");n.length>0&&i.accordionClose(n),t.css("height",t[0].scrollHeight+"px").transitionEnd(function(){if(e.hasClass("accordion-item-expanded")){t.transition(0),t.css("height","auto");t[0].clientLeft;t.transition(""),e.trigger("opened accordion:opened")}else t.css("height",""),e.trigger("closed accordion:closed")}),e.trigger("open accordion:open"),e.addClass("accordion-item-expanded")},i.accordionClose=function(e){e=o(e);var a=e.children(".accordion-item-content");0===a.length&&(a=e.find(".accordion-item-content")),e.removeClass("accordion-item-expanded"),a.transition(0),a.css("height",a[0].scrollHeight+"px");a[0].clientLeft;a.transition(""),a.css("height","").transitionEnd(function(){if(e.hasClass("accordion-item-expanded")){a.transition(0),a.css("height","auto");a[0].clientLeft;a.transition(""),e.trigger("opened accordion:opened")}else a.css("height",""),e.trigger("closed accordion:closed")}),e.trigger("close accordion:close")},i.initFastClicks=function(){function e(e){var a,t=o(e),n=t.parents(i.params.activeStateElements);return t.is(i.params.activeStateElements)&&(a=t),n.length>0&&(a=a?a.add(n):n),a?a:t}function a(e){var a=e.parents(".page-content, .panel");return 0!==a.length&&("yes"!==a.prop("scrollHandlerSet")&&(a.on("scroll",function(){clearTimeout(R),clearTimeout(G)}),a.prop("scrollHandlerSet","yes")),!0)}function t(){A&&A.addClass("active-state")}function n(e){A&&(A.removeClass("active-state"),A=null)}function r(e){var a="input select textarea label".split(" ");return!!(e.nodeName&&a.indexOf(e.nodeName.toLowerCase())>=0)}function s(e){var a="button input textarea select".split(" ");return!(!document.activeElement||e===document.activeElement||document.activeElement===document.body)&&!(a.indexOf(e.nodeName.toLowerCase())>=0)}function l(e){var a=o(e);return("input"!==e.nodeName.toLowerCase()||"file"!==e.type&&"range"!==e.type)&&(("select"!==e.nodeName.toLowerCase()||!i.device.android)&&(!(a.hasClass("no-fastclick")||a.parents(".no-fastclick").length>0)&&(!i.params.fastClicksExclude||!a.is(i.params.fastClicksExclude))))}function p(e){if(document.activeElement===e)return!1;var a=e.nodeName.toLowerCase(),t="button checkbox file image radio submit".split(" ");return!e.disabled&&!e.readOnly&&("textarea"===a||("select"===a?!i.device.android:"input"===a&&t.indexOf(e.type)<0||void 0))}function d(e){e=o(e);var a=!0;return(e.is("label")||e.parents("label").length>0)&&(a=!i.device.android&&!(!i.device.ios||!e.is("input"))),a}function c(a){e(a.target).addClass("active-state"),"which"in a&&3===a.which&&setTimeout(function(){o(".active-state").removeClass("active-state")},0),i.params.material&&i.params.materialRipple&&(S=a.pageX,M=a.pageY,v(a.target,a.pageX,a.pageY))}function u(e){o(".active-state").removeClass("active-state"),i.params.material&&i.params.materialRipple&&b()}function m(e){o(".active-state").removeClass("active-state"),i.params.material&&i.params.materialRipple&&w()}function f(e){var a=i.params.materialRippleElements,t=o(e);if(t.is(a))return!t.hasClass("no-ripple")&&t;if(t.parents(a).length>0){var n=t.parents(a).eq(0);return!n.hasClass("no-ripple")&&n}return!1}function h(e,a,t){if(t){var n=t[0].getBoundingClientRect(),r={x:e-n.left,y:a-n.top},i=n.height,s=n.width,l=Math.max(Math.pow(Math.pow(i,2)+Math.pow(s,2),.5),48);q=o('
      '),t.prepend(q);q[0].clientLeft;X="translate3d("+(-r.x+s/2)+"px, "+(-r.y+i/2)+"px, 0) scale(1)",q.transform(X)}}function g(){if(q){var e=q,a=setTimeout(function(){e.remove()},400);q.addClass("ripple-wave-fill").transform(X.replace("scale(1)","scale(1.01)")).transitionEnd(function(){clearTimeout(a);var e=o(this).addClass("ripple-wave-out").transform(X.replace("scale(1)","scale(1.01)"));a=setTimeout(function(){e.remove()},700),setTimeout(function(){e.transitionEnd(function(){clearTimeout(a),o(this).remove()})},0)}),q=F=void 0}}function v(e,t,n){return F=f(e),F&&0!==F.length?void(a(F)?G=setTimeout(function(){h(S,M,F)},80):h(S,M,F)):void(F=void 0)}function b(){clearTimeout(G),g()}function w(){q?g():F&&!B?(clearTimeout(G),h(S,M,F),setTimeout(g,0)):g()}function C(e){var a=e.changedTouches[0],t=document.createEvent("MouseEvents"),n="click";i.device.android&&"select"===E.nodeName.toLowerCase()&&(n="mousedown"),t.initMouseEvent(n,!0,!0,window,1,a.screenX,a.screenY,a.clientX,a.clientY,!1,!1,!1,!1,0,null),t.forwardedTouchEvent=!0,E.dispatchEvent(t)}function y(r){if(B=!1,N=!1,r.targetTouches.length>1)return A&&n(),!0;if(r.touches.length>1&&A&&n(),i.params.tapHold&&(H&&clearTimeout(H),H=setTimeout(function(){r&&r.touches&&r.touches.length>1||(N=!0,r.preventDefault(),o(r.target).trigger("taphold"))},i.params.tapHoldDelay)),Y&&clearTimeout(Y),V=l(r.target),!V)return O=!1,!0;if(i.device.ios||i.device.android&&"getSelection"in window){var p=window.getSelection();if(p.rangeCount&&p.focusNode!==document.body&&(!p.isCollapsed||document.activeElement===p.focusNode))return z=!0,!0;z=!1}i.device.android&&s(r.target)&&document.activeElement.blur(),O=!0,E=r.target,I=(new Date).getTime(),S=r.targetTouches[0].pageX,M=r.targetTouches[0].pageY,i.device.ios&&(D=void 0,o(E).parents().each(function(){var e=this;e.scrollHeight>e.offsetHeight&&!D&&(D=e,D.f7ScrollTop=D.scrollTop)})),r.timeStamp-Lt||Math.abs(s-M)>t)&&(a=!0)}else a=!0;a&&(O=!1,E=null,B=!0,i.params.tapHold&&clearTimeout(H),i.params.activeState&&(clearTimeout(R),n()),i.params.material&&i.params.materialRipple&&b())}}function T(e){if(clearTimeout(R),clearTimeout(H),!O)return!z&&V&&(i.device.android&&!e.cancelable||e.preventDefault()),!0;if(document.activeElement===e.target)return i.params.activeState&&n(),i.params.material&&i.params.materialRipple&&w(),!0;if(z||e.preventDefault(),e.timeStamp-L159?(E=null,!1):(E.focus(),!1);E.focus()}return document.activeElement&&E!==document.activeElement&&document.activeElement!==document.body&&"label"!==E.nodeName.toLowerCase()&&document.activeElement.blur(),e.preventDefault(),C(e),!1}function k(e){O=!1,E=null,clearTimeout(R),clearTimeout(H),i.params.activeState&&n(),i.params.material&&i.params.materialRipple&&w()}function P(e){var a=!1;return O?(E=null,O=!1,!0):"submit"===e.target.type&&0===e.detail||"file"===e.target.type||(E||r(e.target)||(a=!0),V||(a=!0),document.activeElement===E&&(a=!0),e.forwardedTouchEvent&&(a=!0),e.cancelable||(a=!0),i.params.tapHold&&i.params.tapHoldPreventClicks&&N&&(a=!1),a||(e.stopImmediatePropagation(),e.stopPropagation(),E?(d(E)||B)&&e.preventDefault():e.preventDefault(),E=null),Y=setTimeout(function(){V=!1},i.device.ios||i.device.androidChrome?100:400),i.params.tapHold&&(H=setTimeout(function(){N=!1},i.device.ios||i.device.androidChrome?100:400)),a)}i.params.activeState&&o("html").addClass("watch-active-state"),i.device.ios&&i.device.webView&&window.addEventListener("touchstart",function(){});var S,M,I,E,O,z,D,L,B,N,H,A,R,V,Y,q,F,X,G;i.support.touch?(document.addEventListener("click",P,!0),document.addEventListener("touchstart",y),document.addEventListener("touchmove",x),document.addEventListener("touchend",T),document.addEventListener("touchcancel",k)):i.params.activeState&&(document.addEventListener("mousedown",c),document.addEventListener("mousemove",u),document.addEventListener("mouseup",m)),i.params.material&&i.params.materialRipple&&document.addEventListener("contextmenu",function(e){A&&n(),w()})},i.initClickEvents=function(){function e(e){var a=o(this),t=o(e.target),n="a"===a[0].nodeName.toLowerCase()||a.parents("a").length>0||"a"===t[0].nodeName.toLowerCase()||t.parents("a").length>0;if(!n){var r;if(i.params.scrollTopOnNavbarClick&&a.is(".navbar .center")){var s=a.parents(".navbar");r=s.parents(".page-content"),0===r.length&&(s.parents(".page").length>0&&(r=s.parents(".page").find(".page-content")),0===r.length&&s.nextAll(".pages").length>0&&(r=s.nextAll(".pages").find(".page:not(.page-on-left):not(.page-on-right):not(.cached)").find(".page-content")))}i.params.scrollTopOnStatusbarClick&&a.is(".statusbar-overlay")&&(r=o(".popup.modal-in").length>0?o(".popup.modal-in").find(".page:not(.page-on-left):not(.page-on-right):not(.cached)").find(".page-content"):o(".panel.active").length>0?o(".panel.active").find(".page:not(.page-on-left):not(.page-on-right):not(.cached)").find(".page-content"):o(".views > .view.active").length>0?o(".views > .view.active").find(".page:not(.page-on-left):not(.page-on-right):not(.cached)").find(".page-content"):o(".views").find(".page:not(.page-on-left):not(.page-on-right):not(.cached)").find(".page-content")),r&&r.length>0&&(r.hasClass("tab")&&(r=r.parent(".tabs").children(".page-content.active")),r.length>0&&r.scrollTop(0,300))}}function a(e){var a=o(this),t=a.attr("href"),n="a"===a[0].nodeName.toLowerCase();if(n&&(a.is(i.params.externalLinks)||t&&t.indexOf("javascript:")>=0))return void(t&&"_system"===a.attr("target")&&(e.preventDefault(),window.open(t,"_system")));var r=a.dataset();if(a.hasClass("smart-select")&&i.smartSelectOpen&&i.smartSelectOpen(a),a.hasClass("open-panel")&&(1===o(".panel").length?o(".panel").hasClass("panel-left")?i.openPanel("left"):i.openPanel("right"):"right"===r.panel?i.openPanel("right"):i.openPanel("left")),a.hasClass("close-panel")&&i.closePanel(),a.hasClass("panel-overlay")&&(o(".panel.active").trigger("panel:overlay-click"),i.params.panelsCloseByOutside&&i.closePanel()),a.hasClass("open-popover")){var s;s=r.popover?r.popover:".popover",i.popover(s,a)}a.hasClass("close-popover")&&i.closeModal(".popover.modal-in");var d;a.hasClass("open-popup")&&(d=r.popup?r.popup:".popup",i.popup(d)),a.hasClass("close-popup")&&(d=r.popup?r.popup:".popup.modal-in",i.closeModal(d));var c;if(a.hasClass("open-login-screen")&&(c=r.loginScreen?r.loginScreen:".login-screen",i.loginScreen(c)),a.hasClass("close-login-screen")&&i.closeModal(".login-screen.modal-in"),a.hasClass("modal-overlay")&&(o(".modal.modal-in").length>0&&i.params.modalCloseByOutside&&i.closeModal(".modal.modal-in"),o(".actions-modal.modal-in").length>0&&i.params.actionsCloseByOutside&&i.closeModal(".actions-modal.modal-in"),o(".popover.modal-in").length>0&&i.closeModal(".popover.modal-in")),a.hasClass("popup-overlay")&&o(".popup.modal-in").length>0&&i.params.popupCloseByOutside&&i.closeModal(".popup.modal-in"),a.hasClass("picker-modal-overlay")&&o(".picker-modal.modal-in").length>0&&i.closeModal(".picker-modal.modal-in"),a.hasClass("close-picker")){var u=o(".picker-modal.modal-in");u.length>0?i.closeModal(u):(u=o(".popover.modal-in .picker-modal"),u.length>0&&i.closeModal(u.parents(".popover")))}if(a.hasClass("open-picker")){var m;m=r.picker?r.picker:".picker-modal",i.pickerModal(m,a)}var f;if(a.hasClass("tab-link")&&(f=!0,i.showTab(r.tab||a.attr("href"),a)),a.hasClass("swipeout-close")&&i.swipeoutClose(a.parents(".swipeout-opened")),a.hasClass("swipeout-delete"))if(r.confirm){var h=r.confirm,g=r.confirmTitle;g?i.confirm(h,g,function(){i.swipeoutDelete(a.parents(".swipeout"))},function(){r.closeOnCancel&&i.swipeoutClose(a.parents(".swipeout"))}):i.confirm(h,function(){i.swipeoutDelete(a.parents(".swipeout"))},function(){r.closeOnCancel&&i.swipeoutClose(a.parents(".swipeout"))})}else i.swipeoutDelete(a.parents(".swipeout"));if(a.hasClass("toggle-sortable")&&i.sortableToggle(r.sortable),a.hasClass("open-sortable")&&i.sortableOpen(r.sortable),a.hasClass("close-sortable")&&i.sortableClose(r.sortable),a.hasClass("accordion-item-toggle")||a.hasClass("item-link")&&a.parent().hasClass("accordion-item")){var v=a.parent(".accordion-item");0===v.length&&(v=a.parents(".accordion-item")),0===v.length&&(v=a.parents("li")),i.accordionToggle(v)}if(a.hasClass("floating-button")&&a.parent().hasClass("speed-dial")&&a.parent().toggleClass("speed-dial-opened"),a.hasClass("close-speed-dial")&&o(".speed-dial-opened").removeClass("speed-dial-opened"),(!i.params.ajaxLinks||a.is(i.params.ajaxLinks))&&n&&i.params.router){n&&e.preventDefault();var b=t&&t.length>0&&"#"!==t&&!f,w=r.template;if(b||a.hasClass("back")||w){var C;if(r.view?C=o(r.view)[0].f7View:(C=a.parents("."+i.params.viewClass)[0]&&a.parents("."+i.params.viewClass)[0].f7View,C&&C.params.linksView&&("string"==typeof C.params.linksView?C=o(C.params.linksView)[0].f7View:C.params.linksView instanceof p&&(C=C.params.linksView))),C||i.mainView&&(C=i.mainView),!C)return;var y;if(w)t=void 0;else{if(t&&0===t.indexOf("#")&&"#"!==t){if(!C.params.domCache)return;y=t.split("#")[1]}if("#"===t&&!a.hasClass("back"))return}var x;"undefined"!=typeof r.animatePages?x=r.animatePages:(a.hasClass("with-animation")&&(x=!0),a.hasClass("no-animation")&&(x=!1));var T={animatePages:x,ignoreCache:r.ignoreCache,force:r.force,reload:r.reload,reloadPrevious:r.reloadPrevious,pageName:y,pushState:r.pushState,url:t};if(i.params.template7Pages){T.contextName=r.contextName;var k=r.context;k&&(T.context=JSON.parse(k))}w&&w in l.templates&&(T.template=l.templates[w]),a.hasClass("back")?C.router.back(T):C.router.load(T)}}}function t(e){e.preventDefault()}o(document).on("click","a, .open-panel, .close-panel, .panel-overlay, .modal-overlay, .popup-overlay, .swipeout-delete, .swipeout-close, .close-popup, .open-popup, .open-popover, .open-login-screen, .close-login-screen .smart-select, .toggle-sortable, .open-sortable, .close-sortable, .accordion-item-toggle, .close-picker, .picker-modal-overlay",a),(i.params.scrollTopOnNavbarClick||i.params.scrollTopOnStatusbarClick)&&o(document).on("click",".statusbar-overlay, .navbar .center",e),i.support.touch&&!i.device.android&&o(document).on(i.params.fastClicks?"touchstart":"touchmove",".panel-overlay, .modal-overlay, .preloader-indicator-overlay, .popup-overlay, .searchbar-overlay",t)},i.initResize=function(){o(window).on("resize",i.resize),o(window).on("orientationchange",i.orientationchange)},i.resize=function(){i.sizeNavbars&&i.sizeNavbars(),r()},i.orientationchange=function(){i.device&&i.device.minimalUi&&(90!==window.orientation&&window.orientation!==-90||(document.body.scrollTop=0)),r()},i.formsData={},i.formStoreData=function(e,a){i.formsData[e]=a,i.ls["f7form-"+e]=JSON.stringify(a)},i.formDeleteData=function(e){i.formsData[e]&&(i.formsData[e]="",delete i.formsData[e]),i.ls["f7form-"+e]&&(i.ls["f7form-"+e]="",i.ls.removeItem("f7form-"+e))},i.formGetData=function(e){return i.ls["f7form-"+e]?JSON.parse(i.ls["f7form-"+e]):i.formsData[e]?i.formsData[e]:void 0},i.formToData=function(e){if(e=o(e),1!==e.length)return!1;var a={},t=["submit","image","button","file"],n=[];return e.find("input, select, textarea").each(function(){var r=o(this),i=r.attr("name"),s=r.attr("type"),l=this.nodeName.toLowerCase();if(!(t.indexOf(s)>=0)&&!(n.indexOf(i)>=0)&&i)if("select"===l&&r.prop("multiple"))n.push(i),a[i]=[],e.find('select[name="'+i+'"] option').each(function(){this.selected&&a[i].push(this.value)});else switch(s){case"checkbox":n.push(i),a[i]=[],e.find('input[name="'+i+'"]').each(function(){this.checked&&a[i].push(this.value)});break;case"radio":n.push(i),e.find('input[name="'+i+'"]').each(function(){this.checked&&(a[i]=this.value)});break;default:a[i]=r.val()}}),e.trigger("formToJSON formToData form:todata",{formData:a}),a},i.formToJSON=i.formToData,i.formFromData=function(e,a){if(e=o(e),1!==e.length)return!1;var t=["submit","image","button","file"],n=[];e.find("input, select, textarea").each(function(){var r=o(this),i=r.attr("name"),s=r.attr("type"),l=this.nodeName.toLowerCase();if("undefined"!=typeof a[i]&&null!==a[i]&&!(t.indexOf(s)>=0)&&!(n.indexOf(i)>=0)&&i){if("select"===l&&r.prop("multiple"))n.push(i),e.find('select[name="'+i+'"] option').each(function(){a[i].indexOf(this.value)>=0?this.selected=!0:this.selected=!1});else switch(s){case"checkbox":n.push(i),e.find('input[name="'+i+'"]').each(function(){a[i].indexOf(this.value)>=0?this.checked=!0:this.checked=!1});break;case"radio":n.push(i),e.find('input[name="'+i+'"]').each(function(){a[i]===this.value?this.checked=!0:this.checked=!1});break;default:r.val(a[i])}"select"===l&&r.parents(".smart-select").length>0&&r.trigger("change")}}),e.trigger("formFromJSON formFromData form:fromdata",{formData:a})},i.formFromJSON=i.formFromData,i.initFormsStorage=function(e){function a(){var e=o(this),a=e[0].id;if(a){var t=i.formToData(e);t&&(i.formStoreData(a,t),e.trigger("store form:storedata",{data:t}))}}function t(){n.off("change submit",a),e.off("page:beforeremove",t)}e=o(e);var n=e.find("form.store-data");0!==n.length&&(n.each(function(){var e=this.getAttribute("id");if(e){var a=i.formGetData(e);a&&i.formFromData(this,a)}}),n.on("change submit",a),e.on("page:beforeremove",t))},o(document).on("submit change","form.ajax-submit, form.ajax-submit-onchange",function(e){var a=o(this);if("change"!==e.type||a.hasClass("ajax-submit-onchange")){"submit"===e.type&&e.preventDefault();var t=(a.attr("method")||"GET").toUpperCase(),n=a.prop("enctype")||a.attr("enctype"),r=a.attr("action");if(r){var s;s="POST"===t?new FormData(a[0]):o.serializeObject(i.formToJSON(a[0]));var l=o.ajax({method:t,url:r,contentType:n,data:s,beforeSend:function(e){a.trigger("beforeSubmit form:beforesend",{data:s,xhr:e})},error:function(e){a.trigger("submitError form:error",{data:s,xhr:e})},success:function(e){a.trigger("submitted form:success",{data:e,xhr:l})}})}}}),i.resizeTextarea=function(e){if(e=o(e),e.hasClass("resizable")){e.css({height:""});var a=e[0].offsetHeight,t=a-e[0].clientHeight,n=e[0].scrollHeight;if(n+t>a){var r=n+t;e.css("height",r+"px")}}},i.resizableTextarea=function(e){function a(){clearTimeout(t),t=setTimeout(function(){i.resizeTextarea(e)},0)}if(e=o(e),0!==e.length){var t;return e[0].f7DestroyResizableTextarea=function(){e.off("change keydown keypress keyup paste cut",a)},e.on("change keydown keypress keyup paste cut",a)}},i.destroyResizableTextarea=function(e){e=o(e),e.length>0&&e.is("textarea")&&e[0].f7DestroyResizableTextarea?e[0].f7DestroyResizableTextarea():e.length>0&&e.find("textarea.resiable").each(function(){var e=this;e.f7DestroyResizableTextarea&&e.f7DestroyResizableTextarea()})},i.initPageResizableTextarea=function(e){e=o(e);var a=e.find("textarea.resizable");a.each(function(){i.resizableTextarea(this)})},i.initPageMaterialInputs=function(e){e=o(e);e.find("textarea.resizable");e.find(".item-input").each(function(){var e=o(this),a=["checkbox","button","submit","range","radio","image"];e.find("input, select, textarea").each(function(){var t=o(this);a.indexOf(t.attr("type"))<0&&(e.addClass("item-input-field"),""!==t.val().trim()&&t.parents(".item-input, .input-field").add(t.parents(".item-inner")).addClass("not-empty-state"))}),e.parents(".input-item, .inputs-list").length>0||e.parents(".list-block").eq(0).addClass("inputs-list")})},i.initMaterialWatchInputs=function(){function e(e){var a=o(this),t=a.attr("type");if(!(n.indexOf(t)>=0)){var r=a.add(a.parents(".item-input, .input-field")).add(a.parents(".item-inner").eq(0));r.addClass("focus-state")}}function a(e){var a=o(this),t=a.val(),r=a.attr("type");if(!(n.indexOf(r)>=0)){var i=a.add(a.parents(".item-input, .input-field")).add(a.parents(".item-inner").eq(0));i.removeClass("focus-state"),t&&""!==t.trim()?i.addClass("not-empty-state"):i.removeClass("not-empty-state")}}function t(e){var a=o(this),t=a.val(),r=a.attr("type");if(!(n.indexOf(r)>=0)){var i=a.add(a.parents(".item-input, .input-field")).add(a.parents(".item-inner").eq(0));t&&""!==t.trim()?i.addClass("not-empty-state"):i.removeClass("not-empty-state")}}var n=["checkbox","button","submit","range","radio","image"];o(document).on("change",".item-input input, .item-input select, .item-input textarea, input, textarea, select",t,!0),o(document).on("focus",".item-input input, .item-input select, .item-input textarea, input, textarea, select",e,!0),o(document).on("blur",".item-input input, .item-input select, .item-input textarea, input, textarea, select",a,!0)},i.pushStateQueue=[],i.pushStateClearQueue=function(){if(0!==i.pushStateQueue.length){var e,a=i.pushStateQueue.pop();i.params.pushStateNoAnimation===!0&&(e=!1),"back"===a.action&&i.router.back(a.view,{animatePages:e}),"loadPage"===a.action&&i.router.load(a.view,{url:a.stateUrl,animatePages:e,pushState:!1}),"loadContent"===a.action&&i.router.load(a.view,{content:a.stateContent,animatePages:e,pushState:!1}),"loadPageName"===a.action&&i.router.load(a.view,{pageName:a.statePageName,url:a.stateUrl,animatePages:e,pushState:!1})}},i.initPushState=function(){function e(e){if(!a){var t=i.mainView;if(t){var n=e.state;if(n||(n={viewIndex:i.views.indexOf(t),url:t.history[0]}),!(n.viewIndex<0)){var r,s=i.views[n.viewIndex],o=n&&n.url||void 0,l=n&&n.content||void 0,p=n&&n.pageName||void 0;i.params.pushStateNoAnimation===!0&&(r=!1),o!==s.url&&(s.history.indexOf(o)>=0?s.allowPageChange?i.router.back(s,{url:void 0,animatePages:r,pushState:!1,preloadOnly:!1}):i.pushStateQueue.push({action:"back",view:s}):l?s.allowPageChange?i.router.load(s,{content:l,animatePages:r,pushState:!1}):i.pushStateQueue.unshift({action:"loadContent",stateContent:l,view:s}):p?s.allowPageChange?i.router.load(s,{pageName:p,url:o,animatePages:r,pushState:!1}):i.pushStateQueue.unshift({action:"loadPageName",statePageName:p,view:s}):s.allowPageChange?i.router.load(s,{url:o,animatePages:r,pushState:!1}):i.pushStateQueue.unshift({action:"loadPage",stateUrl:o,view:s}))}}}}var a=!0;o(window).on("load",function(){setTimeout(function(){a=!1},0)}),document.readyState&&"complete"===document.readyState&&(a=!1),o(window).on("popstate",e)},i.swiper=function(e,a){return new Swiper(e,a)},i.initPageSwiper=function(e){function a(a){function t(){a.destroy(),e.off("page:beforeremove",t)}e.on("page:beforeremove",t)}e=o(e);var t=e.find(".swiper-init, .tabs-swipeable-wrap");0!==t.length&&t.each(function(){var e,t,n=o(this);n.hasClass("tabs-swipeable-wrap")&&(n.addClass("swiper-container").children(".tabs").addClass("swiper-wrapper").children(".tab").addClass("swiper-slide"),e=n.children(".tabs").children(".tab.active").index()),t=n.data("swiper")?JSON.parse(n.data("swiper")):n.dataset(),"undefined"==typeof t.initialSlide&&"undefined"!=typeof e&&(t.initialSlide=e),n.hasClass("tabs-swipeable-wrap")&&(t.onSlideChangeStart=function(e){i.showTab(e.slides.eq(e.activeIndex))});var r=i.swiper(n[0],t);a(r)})},i.reinitPageSwiper=function(e){e=o(e);var a=e.find(".swiper-init, .tabs-swipeable-wrap");if(0!==a.length)for(var t=0;t',s=a.params.lazyPhotoTemplate||'
      {{#if @root.material}}{{@root.materialPreloaderHtml}}{{/if}}
      ',p=a.params.objectTemplate||'
      {{js "this.html || this"}}
      ',d=a.params.captionTemplate||'
      {{caption}}
      ',c=a.params.navbarTemplate||'',u=a.params.toolbarTemplate||'
      ',m=l.compile('
      ")(a.params);a.activeIndex=a.params.initialSlide,a.openIndex=a.activeIndex,a.opened=!1,a.open=function(e){return"undefined"==typeof e&&(e=a.activeIndex),e=parseInt(e,10),a.opened&&a.swiper?void a.swiper.slideTo(e):(a.opened=!0,a.openIndex=e,"standalone"===a.params.type&&i.root.append(m),"popup"===a.params.type&&(a.popup=i.popup('"),o(a.popup).on("popup:closed",a.onPopupClose)),"page"===a.params.type?(o(document).on("page:beforeinit",a.onPageBeforeInit),o(document).on("page:beforeremove",a.onPageBeforeRemove),a.params.view||(a.params.view=i.mainView),void a.params.view.loadContent(m)):(a.layout(a.openIndex),void(a.params.onOpen&&a.params.onOpen(a))))},a.close=function(){a.opened=!1,a.swiperContainer&&0!==a.swiperContainer.length&&(a.params.onClose&&a.params.onClose(a),a.attachEvents(!0),"standalone"===a.params.type&&a.container.removeClass("photo-browser-in").addClass("photo-browser-out").animationEnd(function(){a.container.remove()}),a.swiper.destroy(),a.swiper=a.swiperContainer=a.swiperWrapper=a.slides=void 0)},a.onPopupClose=function(e){a.close(),o(a.popup).off("page:beforeinit",a.onPopupClose)},a.onPageBeforeInit=function(e){"photo-browser-slides"===e.detail.page.name&&a.layout(a.openIndex),o(document).off("page:beforeinit",a.onPageBeforeInit)},a.onPageBeforeRemove=function(e){"photo-browser-slides"===e.detail.page.name&&a.close(),o(document).off("page:beforeremove",a.onPageBeforeRemove)},a.onSliderTransitionStart=function(e){a.activeIndex=e.activeIndex;var t=e.activeIndex+1,n=e.slides.length;if(a.params.loop&&(n-=2,t-=e.loopedSlides,t<1&&(t=n+t),t>n&&(t-=n)),a.container.find(".photo-browser-current").text(t),a.container.find(".photo-browser-total").text(n),o(".photo-browser-prev, .photo-browser-next").removeClass("photo-browser-link-inactive"),e.isBeginning&&!a.params.loop&&o(".photo-browser-prev").addClass("photo-browser-link-inactive"),e.isEnd&&!a.params.loop&&o(".photo-browser-next").addClass("photo-browser-link-inactive"),a.captions.length>0){a.captionsContainer.find(".photo-browser-caption-active").removeClass("photo-browser-caption-active");var r=a.params.loop?e.slides.eq(e.activeIndex).attr("data-swiper-slide-index"):a.activeIndex;a.captionsContainer.find('[data-caption-index="'+r+'"]').addClass("photo-browser-caption-active")}var i=e.slides.eq(e.previousIndex).find("video");i.length>0&&"pause"in i[0]&&i[0].pause(),a.params.onTransitionStart&&a.params.onTransitionStart(e)},a.onSliderTransitionEnd=function(e){a.params.onTransitionEnd&&a.params.onTransitionEnd(e)},a.layout=function(e){"page"===a.params.type?a.container=o(".photo-browser-swiper-container").parents(".view"):a.container=o(".photo-browser"),"standalone"===a.params.type&&(a.container.addClass("photo-browser-in"),i.sizeNavbars(a.container)),a.swiperContainer=a.container.find(".photo-browser-swiper-container"),a.swiperWrapper=a.container.find(".photo-browser-swiper-wrapper"),a.slides=a.container.find(".photo-browser-slide"),a.captionsContainer=a.container.find(".photo-browser-captions"),a.captions=a.container.find(".photo-browser-caption");var t={nextButton:a.params.nextButton||".photo-browser-next",prevButton:a.params.prevButton||".photo-browser-prev",indexButton:a.params.indexButton,initialSlide:e,spaceBetween:a.params.spaceBetween,speed:a.params.speed,loop:a.params.loop,lazyLoading:a.params.lazyLoading,lazyLoadingInPrevNext:a.params.lazyLoadingInPrevNext,lazyLoadingOnTransitionStart:a.params.lazyLoadingOnTransitionStart,preloadImages:!a.params.lazyLoading,zoom:a.params.zoom,zoomMax:a.params.zoomMax,zoomMin:a.params.zoomMin,onTap:function(e,t){a.params.onTap&&a.params.onTap(e,t)},onClick:function(e,t){a.params.exposition&&a.toggleExposition(),a.params.onClick&&a.params.onClick(e,t)},onDoubleTap:function(e,t){a.params.onDoubleTap&&a.params.onDoubleTap(e,t)},onTransitionStart:function(e){a.onSliderTransitionStart(e)},onTransitionEnd:function(e){a.onSliderTransitionEnd(e)},onSlideChangeStart:a.params.onSlideChangeStart,onSlideChangeEnd:a.params.onSlideChangeEnd,onLazyImageLoad:function(e,t,n){a.params.onLazyImageLoad&&a.params.onLazyImageLoad(a,t,n)},onLazyImageReady:function(e,t,n){o(t).removeClass("photo-browser-slide-lazy"),a.params.onLazyImageReady&&a.params.onLazyImageReady(a,t,n)}};a.params.swipeToClose&&"page"!==a.params.type&&(t.onTouchStart=a.swipeCloseTouchStart,t.onTouchMoveOpposite=a.swipeCloseTouchMove,t.onTouchEnd=a.swipeCloseTouchEnd),a.swiper=i.swiper(a.swiperContainer,t),0===e&&a.onSliderTransitionStart(a.swiper),a.attachEvents()},a.attachEvents=function(e){var t=e?"off":"on";a.container.find(".photo-browser-close-link")[t]("click",a.close)},a.exposed=!1,a.toggleExposition=function(){a.container&&a.container.toggleClass("photo-browser-exposed"),a.params.expositionHideCaptions&&a.captionsContainer.toggleClass("photo-browser-captions-exposed"),a.exposed=!a.exposed},a.enableExposition=function(){a.container&&a.container.addClass("photo-browser-exposed"),a.params.expositionHideCaptions&&a.captionsContainer.addClass("photo-browser-captions-exposed"),a.exposed=!0},a.disableExposition=function(){a.container&&a.container.removeClass("photo-browser-exposed"),a.params.expositionHideCaptions&&a.captionsContainer.removeClass("photo-browser-captions-exposed"),a.exposed=!1};var f,h,g,v,b,w=!1,C=!0,y=!1;return a.swipeCloseTouchStart=function(e,a){C&&(w=!0)},a.swipeCloseTouchMove=function(e,t){if(w){y||(y=!0,h="touchmove"===t.type?t.targetTouches[0].pageY:t.pageY,v=a.swiper.slides.eq(a.swiper.activeIndex),b=(new Date).getTime()),t.preventDefault(),g="touchmove"===t.type?t.targetTouches[0].pageY:t.pageY,f=h-g;var n=1-Math.abs(f)/300;v.transform("translate3d(0,"+-f+"px,0)"),a.swiper.container.css("opacity",n).transition(0)}},a.swipeCloseTouchEnd=function(e,t){if(w=!1,!y)return void(y=!1);y=!1,C=!1;var n=Math.abs(f),r=(new Date).getTime()-b;return r<300&&n>20||r>=300&&n>100?void setTimeout(function(){"standalone"===a.params.type&&a.close(),"popup"===a.params.type&&i.closeModal(a.popup),a.params.onSwipeToClose&&a.params.onSwipeToClose(a),C=!0},0):(0!==n?v.addClass("transitioning").transitionEnd(function(){C=!0,v.removeClass("transitioning")}):C=!0,a.swiper.container.css("opacity","").transition(""),void v.transform(""))},a};i.photoBrowser=function(e){return new v(e)};var b=function(e){function a(e){var a=r.input.val();r.params.source&&r.params.source(r,a,function(e){var t="",n=r.params.limit?Math.min(r.params.limit,e.length):e.length;r.items=e;var i,s;for(r.params.highlightMatches&&(a=a.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&"),s=new RegExp("("+a+")","i")),i=0;i$1"):l})}""===t&&""===a&&r.params.dropdownPlaceholderText&&(t+=r.dropdownPlaceholderTemplate({text:r.params.dropdownPlaceholderText})),r.dropdown.find("ul").html(t)})}function t(e){for(var a,t=o(this),n=0;n0||r.close()}var r=this,s={popupCloseText:"Close",backText:"Back",searchbarPlaceholderText:"Search...",searchbarCancelText:"Cancel",openIn:"page",backOnSelect:!1,notFoundText:"Nothing found",requestSourceOnOpen:!1,valueProperty:"id",textProperty:"text",highlightMatches:!0,updateInputValueOnSelect:!0,expandInput:!1,preloaderColor:!1,preloader:!1};e=e||{};for(var p in s)"undefined"==typeof e[p]&&(e[p]=s[p]);r.params=e,r.params.opener&&(r.opener=o(r.params.opener));var d=r.params.view;if(!r.params.view&&r.opener&&r.opener.length){if(d=r.opener.parents("."+i.params.viewClass),0===d.length)return;d=d[0].f7View}if(!r.params.input||(r.input=o(r.params.input),0!==r.input.length||"dropdown"!==r.params.openIn)){r.value=r.params.value||[],r.id=(new Date).getTime(),r.inputType=r.params.multiple?"checkbox":"radio",r.inputName=r.inputType+"-"+r.id;var c=i.params.material,u=r.params.backOnSelect;if("dropdown"!==r.params.openIn){r.itemTemplate=l.compile(r.params.itemTemplate||'
    • ');var m=r.params.pageTitle||"";!m&&r.opener&&r.opener.length&&(m=r.opener.find(".item-title").text());var f,h,g="autocomplete-"+r.inputName,v=r.params.navbarTheme,b=r.params.formTheme,w="",C="";r.navbarTemplate=l.compile(r.params.navbarTemplate||''),f=r.navbarTemplate({pageTitle:m,backText:r.params.backText,popupCloseText:r.params.popupCloseText,openIn:r.params.openIn,navbarTheme:v,inPopup:"popup"===r.params.openIn,inPage:"page"===r.params.openIn,material:c,preloader:r.params.preloader,preloaderColor:r.params.preloaderColor}),"page"===r.params.openIn?(h="static",r.opener?(r.opener.parents(".navbar-through").length>0&&(h="through"),r.opener.parents(".navbar-fixed").length>0&&(h="fixed"),C=r.opener.parents(".page").hasClass("no-toolbar")?"no-toolbar":"",w=r.opener.parents(".page").hasClass("no-navbar")?"no-navbar":"navbar-"+h):d.container&&((o(d.container).hasClass("navbar-through")||o(d.container).find(".navbar-through").length>0)&&(h="through"),(o(d.container).hasClass("navbar-fixed")||o(d.container).find(".navbar-fixed").length>0)&&(h="fixed"),C=o(d.activePage.container).hasClass("no-toolbar")?"no-toolbar":"",w=o(d.activePage.container).hasClass("no-navbar")?"no-navbar":"navbar-"+h)):h="fixed";var y='
      ',x=("through"===h?f:"")+'
      '+("fixed"===h?f:"")+y+'
      '+("static"===h?f:"")+'
        • '+r.params.notFoundText+'
          '}else r.dropdownItemTemplate=l.compile(r.params.dropdownItemTemplate||'
        • '), r.dropdownPlaceholderTemplate=l.compile(r.params.dropdownPlaceholderTemplate||'
        • {{text}}
        • '),r.dropdownTemplate=l.compile(r.params.dropdownTemplate||'
            {{#if preloader}}
            {{#if material}}{{materialPreloaderHtml}}{{/if}}
            {{/if}}
            ');return r.popup=void 0,r.dropdown=void 0,r.positionDropDown=function(){var e=r.input.parents(".list-block"),a=r.input.parents(".page-content"),t=(parseInt(a.css("padding-top"),10),parseInt(a.css("padding-top"),10)),n=e.length>0?e.offset().left-e.parent().offset().left:0,i=r.input.offset().left-(e.length>0?e.offset().left:0),s=r.input.offset().top-(a.offset().top-a[0].scrollTop),o=a[0].scrollHeight-t-(s+a[0].scrollTop)-r.input[0].offsetHeight;r.dropdown.css({left:(e.length>0?n:i)+"px",top:s+a[0].scrollTop+r.input[0].offsetHeight+"px",width:(e.length>0?e[0].offsetWidth:r.input[0].offsetWidth)+"px"}),r.dropdown.children(".autocomplete-dropdown-inner").css({maxHeight:o+"px",paddingLeft:e.length>0&&!r.params.expandInput?i-(c?16:15)+"px":""})},r.pageInit=function(e){function a(e){if(r.params.source){var a,t;r.params.source(r,e,function(n){var i="",o=r.params.limit?Math.min(r.params.limit,n.length):n.length;for(r.items=n,a=0;a0);if(c){if("checkbox"===r.inputType&&!l.checked){for(e=0;e0&&r.params.expandInput&&r.input.parents(".item-content").addClass("item-content-dropdown-expand"),r.positionDropDown(),r.input.parents(".page-content").append(r.dropdown),r.dropdown.addClass("autocomplete-dropdown-in"),r.input.trigger("input"),o(window).on("resize",r.positionDropDown),r.params.onOpen&&r.params.onOpen(r)}else o(document).once("pageInit",".autocomplete-page",r.pageInit),"popup"===r.params.openIn?(r.popup=i.popup('"),r.popup=o(r.popup),r.popup.once("closed",function(){r.popup=void 0,r.opened=!1,r.params.onClose&&r.params.onClose(r)})):(d.router.load({content:x}),o(document).once("pageBack",".autocomplete-page",function(){r.opened=!1,r.params.onClose&&r.params.onClose(r)}))},r.close=function(e){if(r.opened){if("dropdown"===r.params.openIn){if(e&&"blur"===e.type&&r.dropdown.find("label.active-state").length>0)return;r.dropdown.removeClass("autocomplete-dropdown-in").remove(),r.input.parents(".item-content-dropdown-expand").removeClass("item-content-dropdown-expand"),r.opened=!1,o(window).off("resize",r.positionDropDown),r.params.onClose&&r.params.onClose(r)}"popup"===r.params.openIn&&r.popup&&i.closeModal(r.popup)}},r.initEvents=function(e){var t=e?"off":"on";"dropdown"!==r.params.openIn&&r.opener&&r.opener[t]("click",r.open),"dropdown"===r.params.openIn&&r.input&&(r.input[t]("focus",r.open),r.input[t]("input",a),i.device.android?o("html")[t]("click",n):r.input[t]("blur",r.close)),e&&r.dropdown&&(r.dropdown=null)},r.init=function(){r.initEvents()},r.destroy=function(){r.initEvents(!0),r=null},r.init(),r}};i.autocomplete=function(e){return new b(e)};var w=function(e){function a(){var e=!1;return p.params.convertToPopover||p.params.onlyInPopover?(!p.inline&&p.params.input&&(p.params.onlyInPopover?e=!0:i.device.ios?e=!!i.device.ipad:o(window).width()>=768&&(e=!0)),e):e}function t(){return!!(p.opened&&p.container&&p.container.length>0&&p.container.parents(".popover").length>0)}function n(){if(p.opened)for(var e=0;es){var d=t.scrollTop()+l-s;d+s>o&&(n=d+s-o+i,s===o&&(n=p.container.height()),t.css({"padding-bottom":n+"px"})),t.scrollTop(d,300)}}}function s(e){t()||(p.input&&p.input.length>0?e.target!==p.input[0]&&0===o(e.target).parents(".picker-modal").length&&p.close():0===o(e.target).parents(".picker-modal").length&&p.close())}function l(){p.opened=!1,p.input&&p.input.length>0&&(p.input.parents(".page-content").css({"padding-bottom":""}),i.params.material&&p.input.trigger("blur")),p.params.onClose&&p.params.onClose(p),p.container.find(".picker-items-col").each(function(){p.destroyPickerCol(this)})}var p=this,d={updateValuesOnMomentum:!1,updateValuesOnTouchmove:!0,rotateEffect:!1,momentumRatio:7,freeMode:!1,closeByOutsideClick:!0,scrollToInput:!0,inputReadOnly:!0,convertToPopover:!0,onlyInPopover:!1,toolbar:!0,toolbarCloseText:"Done",toolbarTemplate:''};e=e||{};for(var c in d)"undefined"==typeof e[c]&&(e[c]=d[c]);p.params=e,p.cols=[],p.initialized=!1,p.inline=!!p.params.container;var u=i.device.ios||navigator.userAgent.toLowerCase().indexOf("safari")>=0&&navigator.userAgent.toLowerCase().indexOf("chrome")<0&&!i.device.android;return p.setValue=function(e,a){var t=0;if(0===p.cols.length)return p.value=e,void p.updateValue(e);for(var n=0;n=0||(p.value=t,p.displayValue=n,p.params.onChange&&p.params.onChange(p,p.value,p.displayValue),p.input&&p.input.length>0&&(o(p.input).val(p.params.formatValue?p.params.formatValue(p,p.value,p.displayValue):p.value.join(" ")),o(p.input).trigger("change")))},p.initPickerCol=function(e,a){function t(){w=o.requestAnimationFrame(function(){m.updateItems(void 0,void 0,0),t()})}function n(e){y||C||(e.preventDefault(),C=!0,x=T="touchstart"===e.type?e.targetTouches[0].pageY:e.pageY,k=(new Date).getTime(),D=!0,S=I=o.getTranslate(m.wrapper[0],"y"))}function r(e){if(C){e.preventDefault(),D=!1,T="touchmove"===e.type?e.targetTouches[0].pageY:e.pageY,y||(o.cancelAnimationFrame(w),y=!0,S=I=o.getTranslate(m.wrapper[0],"y"),m.wrapper.transition(0));var a=T-x;I=S+a,M=void 0,Ib&&(I=b+Math.pow(I-b,.8),M="max"),m.wrapper.transform("translate3d(0,"+I+"px,0)"),m.updateItems(void 0,I,0,p.params.updateValuesOnTouchmove),O=I-E||I,z=(new Date).getTime(),E=I}}function s(e){if(!C||!y)return void(C=y=!1);C=y=!1,m.wrapper.transition(""),M&&("min"===M?m.wrapper.transform("translate3d(0,"+v+"px,0)"):m.wrapper.transform("translate3d(0,"+b+"px,0)")),P=(new Date).getTime();var a,n;P-k>300?n=I:(a=Math.abs(O/(P-z)),n=I+O*p.params.momentumRatio),n=Math.max(Math.min(n,b),v);var r=-Math.floor((n-b)/h);p.params.freeMode||(n=-r*h+b),m.wrapper.transform("translate3d(0,"+parseInt(n,10)+"px,0)"),m.updateItems(r,n,"",!0),p.params.updateValuesOnMomentum&&(t(),m.wrapper.transitionEnd(function(){o.cancelAnimationFrame(w)})),setTimeout(function(){D=!0},100)}function l(e){if(D){o.cancelAnimationFrame(w);var a=o(this).attr("data-picker-value");m.setValue(a)}}var d=o(e),c=d.index(),m=p.cols[c];if(!m.divider){m.container=d,m.wrapper=m.container.find(".picker-items-col-wrapper"),m.items=m.wrapper.find(".picker-item");var f,h,g,v,b;m.replaceValues=function(e,a){m.destroyEvents(),m.values=e,m.displayValues=a;var t=p.columnHTML(m,!0);m.wrapper.html(t),m.items=m.wrapper.find(".picker-item"),m.calcSize(),m.setValue(m.values[0],0,!0),m.initEvents()},m.calcSize=function(){p.params.rotateEffect&&(m.container.removeClass("picker-items-col-absolute"),m.width||m.container.css({width:""}));var e,a;e=0,a=m.container[0].offsetHeight,f=m.wrapper[0].offsetHeight,h=m.items[0].offsetHeight,g=h*m.items.length,v=a/2-g+h/2,b=a/2-h/2,m.width&&(e=m.width,parseInt(e,10)===e&&(e+="px"),m.container.css({width:e})),p.params.rotateEffect&&(m.width||(m.items.each(function(){var a=o(this);a.css({width:"auto"}),e=Math.max(e,a[0].offsetWidth),a.css({width:""})}),m.container.css({width:e+2+"px"})),m.container.addClass("picker-items-col-absolute"))},m.calcSize(),m.wrapper.transform("translate3d(0,"+b+"px,0)").transition(0);var w;m.setValue=function(e,a,n){"undefined"==typeof a&&(a="");var r=m.wrapper.find('.picker-item[data-picker-value="'+e+'"]').index();if("undefined"!=typeof r&&r!==-1){var i=-r*h+b;m.wrapper.transition(a),m.wrapper.transform("translate3d(0,"+i+"px,0)"),p.params.updateValuesOnMomentum&&m.activeIndex&&m.activeIndex!==r&&(o.cancelAnimationFrame(w),m.wrapper.transitionEnd(function(){o.cancelAnimationFrame(w)}),t()),m.updateItems(r,i,a,n)}},m.updateItems=function(e,a,t,n){"undefined"==typeof a&&(a=o.getTranslate(m.wrapper[0],"y")),"undefined"==typeof e&&(e=-Math.round((a-b)/h)),e<0&&(e=0),e>=m.items.length&&(e=m.items.length-1);var r=m.activeIndex;m.activeIndex=e,m.wrapper.find(".picker-selected").removeClass("picker-selected"),m.items.transition(t);var i=m.items.eq(e).addClass("picker-selected").transform("");if(p.params.rotateEffect){(a-(Math.floor((a-b)/h)*h+b))/h;m.items.each(function(){var e=o(this),t=e.index()*h,n=b-a,r=t-n,i=r/h,s=Math.ceil(m.height/h/2)+1,l=-18*i;l>180&&(l=180),l<-180&&(l=-180),Math.abs(i)>s?e.addClass("picker-item-far"):e.removeClass("picker-item-far"),e.transform("translate3d(0, "+(-a+b)+"px, "+(u?-110:0)+"px) rotateX("+l+"deg)")})}(n||"undefined"==typeof n)&&(m.value=i.attr("data-picker-value"),m.displayValue=m.displayValues?m.displayValues[e]:m.value,r!==e&&(m.onChange&&m.onChange(p,m.value,m.displayValue),p.updateValue()))},a&&m.updateItems(0,b,0);var C,y,x,T,k,P,S,M,I,E,O,z,D=!0;m.initEvents=function(e){var a=e?"off":"on";m.container[a](i.touchEvents.start,n),m.container[a](i.touchEvents.move,r),m.container[a](i.touchEvents.end,s),m.items[a]("click",l)},m.destroyEvents=function(){m.initEvents(!0)},m.container[0].f7DestroyPickerCol=function(){m.destroyEvents()},m.initEvents()}},p.destroyPickerCol=function(e){e=o(e),"f7DestroyPickerCol"in e[0]&&e[0].f7DestroyPickerCol()},o(window).on("resize",n),p.columnHTML=function(e,a){var t="",n="";if(e.divider)n+='
            '+e.content+"
            ";else{for(var r=0;r'+(e.displayValues?e.displayValues[r]:e.values[r])+"";n+='
            '+t+"
            "}return a?t:n},p.layout=function(){var e,a="",t="";p.cols=[];var n="";for(e=0;e'+(p.params.toolbar?p.params.toolbarTemplate.replace(/{{closeText}}/g,p.params.toolbarCloseText):"")+'
            '+n+'
            ',p.pickerHTML=a},p.params.input&&(p.input=o(p.params.input),p.input.length>0&&(p.params.inputReadOnly&&p.input.prop("readOnly",!0),p.inline||p.input.on("click",r),p.params.inputReadOnly&&p.input.on("focus mousedown",function(e){e.preventDefault()}))),!p.inline&&p.params.closeByOutsideClick&&o("html").on("click",s),p.opened=!1,p.open=function(){var e=a();p.opened||(p.layout(),e?(p.pickerHTML='
            '+p.pickerHTML+"
            ",p.popover=i.popover(p.pickerHTML,p.params.input,!0),p.container=o(p.popover).find(".picker-modal"),o(p.popover).on("popover:close",function(){l()})):p.inline?(p.container=o(p.pickerHTML),p.container.addClass("picker-modal-inline"),o(p.params.container).append(p.container)):(p.container=o(i.pickerModal(p.pickerHTML)),o(p.container).on("picker:close",function(){l()})),p.container[0].f7Picker=p,p.container.find(".picker-items-col").each(function(){var e=!0;(!p.initialized&&p.params.value||p.initialized&&p.value)&&(e=!1),p.initPickerCol(this,e)}),p.initialized?p.value&&p.setValue(p.value,0):p.value?p.setValue(p.value,0):p.params.value&&p.setValue(p.params.value,0),p.input&&p.input.length>0&&i.params.material&&p.input.trigger("focus")),p.opened=!0,p.initialized=!0,p.params.onOpen&&p.params.onOpen(p)},p.close=function(){if(p.opened&&!p.inline)return t()?void i.closeModal(p.popover):void i.closeModal(p.container)},p.destroy=function(){p.close(),p.params.input&&p.input.length>0&&p.input.off("click focus",r),o("html").off("click",s),o(window).off("resize",n)},p.inline?p.open():!p.initialized&&p.params.value&&p.setValue(p.params.value),p};i.picker=function(e){return new w(e)};var C=function(e){function a(){var e=!1;return p.params.convertToPopover||p.params.onlyInPopover?(!p.inline&&p.params.input&&(p.params.onlyInPopover?e=!0:i.device.ios?e=!!i.device.ipad:o(window).width()>=768&&(e=!0)),e):e}function t(){return!!(p.opened&&p.container&&p.container.length>0&&p.container.parents(".popover").length>0)}function n(e){e=new Date(e);var a=e.getFullYear(),t=e.getMonth(),n=t+1,r=e.getDate(),i=e.getDay();return p.params.dateFormat.replace(/yyyy/g,a).replace(/yy/g,(a+"").substring(2)).replace(/mm/g,n<10?"0"+n:n).replace(/m(\W+)/g,n+"$1").replace(/MM/g,p.params.monthNames[t]).replace(/M(\W+)/g,p.params.monthNamesShort[t]+"$1").replace(/dd/g,r<10?"0"+r:r).replace(/d(\W+)/g,r+"$1").replace(/DD/g,p.params.dayNames[i]).replace(/D(\W+)/g,p.params.dayNamesShort[i]+"$1")}function r(e){if(e.preventDefault(),!p.opened&&(p.open(),p.params.scrollToInput&&!a()&&!i.params.material)){var t=p.input.parents(".page-content");if(0===t.length)return;var n,r=parseInt(t.css("padding-top"),10),s=parseInt(t.css("padding-bottom"),10),o=t[0].offsetHeight-r-p.container.height(),l=t[0].scrollHeight-r-p.container.height(),d=p.input.offset().top-r+p.input[0].offsetHeight;if(d>o){var c=t.scrollTop()+d-o;c+o>l&&(n=c+o-l+s,o===l&&(n=p.container.height()),t.css({"padding-bottom":n+"px"})),t.scrollTop(c,300)}}}function s(e){t()||(p.input&&p.input.length>0?e.target!==p.input[0]&&0===o(e.target).parents(".picker-modal").length&&p.close():0===o(e.target).parents(".picker-modal").length&&p.close())}function l(){p.opened=!1,p.input&&p.input.length>0&&(p.input.parents(".page-content").css({"padding-bottom":""}),i.params.material&&p.input.trigger("blur")),p.params.onClose&&p.params.onClose(p),p.destroyCalendarEvents()}var p=this,d={monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],monthNamesShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayNamesShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],firstDay:1,weekendDays:[0,6],multiple:!1,rangePicker:!1,dateFormat:"yyyy-mm-dd",direction:"horizontal",minDate:null,maxDate:null,disabled:null,events:null,rangesClasses:null,touchMove:!0,animate:!0,closeOnSelect:!1,monthPicker:!0,monthPickerTemplate:'
            ',yearPicker:!0,yearPickerTemplate:'
            ',weekHeader:!0,closeByOutsideClick:!0,scrollToInput:!0,inputReadOnly:!0,convertToPopover:!0,onlyInPopover:!1,toolbar:!0,toolbarCloseText:"Done",headerPlaceholder:"Select date",header:i.params.material,footer:i.params.material,toolbarTemplate:'
            {{monthPicker}}{{yearPicker}}
            ',headerTemplate:'
            {{placeholder}}
            ',footerTemplate:''};e=e||{};for(var c in d)"undefined"==typeof e[c]&&(e[c]=d[c]);p.params=e,p.initialized=!1,p.inline=!!p.params.container,p.isH="horizontal"===p.params.direction;var u=p.isH&&i.rtl?-1:1;return p.animating=!1,p.addValue=function(e){if(p.params.multiple){p.value||(p.value=[]);for(var a,t=0;t0){p.wrapper.find(".picker-calendar-day-selected").removeClass("picker-calendar-day-selected");var r;if(p.params.rangePicker&&2===p.value.length)for(a=p.value[0];a<=p.value[1];a+=864e5)r=new Date(a),p.wrapper.find('.picker-calendar-day[data-date="'+r.getFullYear()+"-"+r.getMonth()+"-"+r.getDate()+'"]').addClass("picker-calendar-day-selected");else for(a=0;a0||i.params.material&&p.params.header){if(p.params.formatValue)t=p.params.formatValue(p,p.value);else{for(t=[],a=0;a0&&p.container.find(".picker-calendar-selected-date").text(t),p.input&&p.input.length>0&&!e&&(o(p.input).val(t),o(p.input).trigger("change"))}},p.initCalendarEvents=function(){function e(e){s||r||(r=!0,l=m="touchstart"===e.type?e.targetTouches[0].pageX:e.pageX,d=m="touchstart"===e.type?e.targetTouches[0].pageY:e.pageY,f=(new Date).getTime(),C=0,T=!0,x=void 0,g=v=p.monthsTranslate)}function a(e){if(r){if(c="touchmove"===e.type?e.targetTouches[0].pageX:e.pageX,m="touchmove"===e.type?e.targetTouches[0].pageY:e.pageY,"undefined"==typeof x&&(x=!!(x||Math.abs(m-d)>Math.abs(c-l))),p.isH&&x)return void(r=!1);if(e.preventDefault(),p.animating)return void(r=!1);T=!1,s||(s=!0,b=p.wrapper[0].offsetWidth,w=p.wrapper[0].offsetHeight,p.wrapper.transition(0)),y=p.isH?c-l:m-d,C=y/(p.isH?b:w),v=100*(p.monthsTranslate*u+C),p.wrapper.transform("translate3d("+(p.isH?v:0)+"%, "+(p.isH?0:v)+"%, 0)")}}function t(e){return r&&s?(r=s=!1,h=(new Date).getTime(),h-f<300?Math.abs(y)<10?p.resetMonth():y>=10?i.rtl?p.nextMonth():p.prevMonth():i.rtl?p.prevMonth():p.nextMonth():C<=-.5?i.rtl?p.prevMonth():p.nextMonth():C>=.5?i.rtl?p.nextMonth():p.prevMonth():p.resetMonth(),void setTimeout(function(){T=!0},100)):void(r=s=!1)}function n(e){if(T){var a=o(e.target).parents(".picker-calendar-day");if(0===a.length&&o(e.target).hasClass("picker-calendar-day")&&(a=o(e.target)),0!==a.length&&!a.hasClass("picker-calendar-day-disabled")){p.params.rangePicker||(a.hasClass("picker-calendar-day-next")&&p.nextMonth(),a.hasClass("picker-calendar-day-prev")&&p.prevMonth());var t=a.attr("data-year"),n=a.attr("data-month"),r=a.attr("data-day");p.params.onDayClick&&p.params.onDayClick(p,a[0],t,n,r),(!a.hasClass("picker-calendar-day-selected")||p.params.multiple||p.params.rangePicker)&&p.addValue(new Date(t,n,r).getTime()),p.params.closeOnSelect&&(p.params.rangePicker&&2===p.value.length||!p.params.rangePicker)&&p.close()}}}var r,s,l,d,c,m,f,h,g,v,b,w,C,y,x,T=!0;p.container.find(".picker-calendar-prev-month").on("click",p.prevMonth),p.container.find(".picker-calendar-next-month").on("click",p.nextMonth),p.container.find(".picker-calendar-prev-year").on("click",p.prevYear),p.container.find(".picker-calendar-next-year").on("click",p.nextYear),p.wrapper.on("click",n);var k=!("touchstart"!==i.touchEvents.start||!i.support.passiveListener)&&{passive:!0,capture:!1};p.params.touchMove&&(p.wrapper.on(i.touchEvents.start,e,k),p.wrapper.on(i.touchEvents.move,a),p.wrapper.on(i.touchEvents.end,t,k)),p.container[0].f7DestroyCalendarEvents=function(){p.container.find(".picker-calendar-prev-month").off("click",p.prevMonth),p.container.find(".picker-calendar-next-month").off("click",p.nextMonth),p.container.find(".picker-calendar-prev-year").off("click",p.prevYear),p.container.find(".picker-calendar-next-year").off("click",p.nextYear),p.wrapper.off("click",n),p.params.touchMove&&(p.wrapper.off(i.touchEvents.start,e,k),p.wrapper.off(i.touchEvents.move,a),p.wrapper.off(i.touchEvents.end,t,k))}},p.destroyCalendarEvents=function(e){"f7DestroyCalendarEvents"in p.container[0]&&p.container[0].f7DestroyCalendarEvents()},p.dateInRange=function(e,a){var t,n=!1;if(!a)return!1;if(o.isArray(a))for(t=0;t=new Date(a[t].from).getTime()&&(n=!0):a[t].from?e>=new Date(a[t].from).getTime()&&(n=!0):a[t].to&&e<=new Date(a[t].to).getTime()&&(n=!0):e===new Date(a[t]).getTime()&&(n=!0);else a.from||a.to?a.from&&a.to?e<=new Date(a.to).getTime()&&e>=new Date(a.from).getTime()&&(n=!0):a.from?e>=new Date(a.from).getTime()&&(n=!0):a.to&&e<=new Date(a.to).getTime()&&(n=!0):"function"==typeof a&&(n=a(new Date(e)));return n},p.daysInMonth=function(e){var a=new Date(e);return new Date(a.getFullYear(),a.getMonth()+1,0).getDate()},p.monthHTML=function(e,a){e=new Date(e);var t=e.getFullYear(),n=e.getMonth();e.getDate();"next"===a&&(e=11===n?new Date(t+1,0):new Date(t,n+1,1)),"prev"===a&&(e=0===n?new Date(t-1,11):new Date(t,n-1,1)),"next"!==a&&"prev"!==a||(n=e.getMonth(),t=e.getFullYear());var r=p.daysInMonth(new Date(e.getFullYear(),e.getMonth()).getTime()-864e6),i=p.daysInMonth(e),s=new Date(e.getFullYear(),e.getMonth()).getDay();0===s&&(s=7);var o,l,d,c,u,m,f=[],h=6,g=7,v="",b=0+(p.params.firstDay-1),w=(new Date).setHours(0,0,0,0),C=p.params.minDate?new Date(p.params.minDate).getTime():null,y=p.params.maxDate?new Date(p.params.maxDate).getTime():null;if(p.value&&p.value.length)for(l=0;l6?T-1-7+p.params.firstDay:T-1+p.params.firstDay,S="";if(k<0?(k=r+k+1,S+=" picker-calendar-day-prev",o=new Date(n-1<0?t-1:t,n-1<0?11:n-1,k).getTime()):(k+=1,k>i?(k-=i,S+=" picker-calendar-day-next",o=new Date(n+1>11?t+1:t,n+1>11?0:n+1,k).getTime()):o=new Date(t,n,k).getTime()),o===w&&(S+=" picker-calendar-day-today"),p.params.rangePicker&&2===f.length?o>=f[0]&&o<=f[1]&&(S+=" picker-calendar-day-selected"):f.indexOf(o)>=0&&(S+=" picker-calendar-day-selected"),p.params.weekendDays.indexOf(P)>=0&&(S+=" picker-calendar-day-weekend"),m=!1,p.params.events&&p.dateInRange(o,p.params.events)&&(m=!0),m&&(S+=" picker-calendar-day-has-events"),p.params.rangesClasses)for(c=0;cy)&&(u=!0),p.params.disabled&&p.dateInRange(o,p.params.disabled)&&(u=!0),u&&(S+=" picker-calendar-day-disabled"),o=new Date(o);var M=o.getFullYear(),I=o.getMonth();x+='
            '+k+"
            "}v+='
            '+x+"
            "}return v='
            '+v+"
            "},p.animating=!1,p.updateCurrentMonthYear=function(e){"undefined"==typeof e?(p.currentMonth=parseInt(p.months.eq(1).attr("data-month"),10),p.currentYear=parseInt(p.months.eq(1).attr("data-year"),10)):(p.currentMonth=parseInt(p.months.eq("next"===e?p.months.length-1:0).attr("data-month"),10),p.currentYear=parseInt(p.months.eq("next"===e?p.months.length-1:0).attr("data-year"),10)),p.container.find(".current-month-value").text(p.params.monthNames[p.currentMonth]),p.container.find(".current-year-value").text(p.currentYear)},p.onMonthChangeStart=function(e){p.updateCurrentMonthYear(e),p.months.removeClass("picker-calendar-month-current picker-calendar-month-prev picker-calendar-month-next");var a="next"===e?p.months.length-1:0;p.months.eq(a).addClass("picker-calendar-month-current"),p.months.eq("next"===e?a-1:a+1).addClass("next"===e?"picker-calendar-month-prev":"picker-calendar-month-next"),p.params.onMonthYearChangeStart&&p.params.onMonthYearChangeStart(p,p.currentYear,p.currentMonth)},p.onMonthChangeEnd=function(e,a){p.animating=!1;var t,n,r;p.wrapper.find(".picker-calendar-month:not(.picker-calendar-month-prev):not(.picker-calendar-month-current):not(.picker-calendar-month-next)").remove(),"undefined"==typeof e&&(e="next",a=!0),a?(p.wrapper.find(".picker-calendar-month-next, .picker-calendar-month-prev").remove(),n=p.monthHTML(new Date(p.currentYear,p.currentMonth),"prev"),t=p.monthHTML(new Date(p.currentYear,p.currentMonth),"next")):r=p.monthHTML(new Date(p.currentYear,p.currentMonth),e),("next"===e||a)&&p.wrapper.append(r||t),("prev"===e||a)&&p.wrapper.prepend(r||n),p.months=p.wrapper.find(".picker-calendar-month"),p.setMonthsTranslate(p.monthsTranslate),p.params.onMonthAdd&&p.params.onMonthAdd(p,"next"===e?p.months.eq(p.months.length-1)[0]:p.months.eq(0)[0]),p.params.onMonthYearChangeEnd&&p.params.onMonthYearChangeEnd(p,p.currentYear,p.currentMonth)},p.setMonthsTranslate=function(e){e=e||p.monthsTranslate||0,"undefined"==typeof p.monthsTranslate&&(p.monthsTranslate=e),p.months.removeClass("picker-calendar-month-current picker-calendar-month-prev picker-calendar-month-next");var a=100*-(e+1)*u,t=100*-e*u,n=100*-(e-1)*u;p.months.eq(0).transform("translate3d("+(p.isH?a:0)+"%, "+(p.isH?0:a)+"%, 0)").addClass("picker-calendar-month-prev"),p.months.eq(1).transform("translate3d("+(p.isH?t:0)+"%, "+(p.isH?0:t)+"%, 0)").addClass("picker-calendar-month-current"),p.months.eq(2).transform("translate3d("+(p.isH?n:0)+"%, "+(p.isH?0:n)+"%, 0)").addClass("picker-calendar-month-next")},p.nextMonth=function(e){"undefined"!=typeof e&&"object"!=typeof e||(e="",p.params.animate||(e=0));var a=parseInt(p.months.eq(p.months.length-1).attr("data-month"),10),t=parseInt(p.months.eq(p.months.length-1).attr("data-year"),10),n=new Date(t,a),r=n.getTime(),i=!p.animating;if(p.params.maxDate&&r>new Date(p.params.maxDate).getTime())return p.resetMonth();if(p.monthsTranslate--,a===p.currentMonth){var s=100*-p.monthsTranslate*u,l=o(p.monthHTML(r,"next")).transform("translate3d("+(p.isH?s:0)+"%, "+(p.isH?0:s)+"%, 0)").addClass("picker-calendar-month-next");p.wrapper.append(l[0]),p.months=p.wrapper.find(".picker-calendar-month"),p.params.onMonthAdd&&p.params.onMonthAdd(p,p.months.eq(p.months.length-1)[0])}p.animating=!0,p.onMonthChangeStart("next");var d=100*p.monthsTranslate*u;p.wrapper.transition(e).transform("translate3d("+(p.isH?d:0)+"%, "+(p.isH?0:d)+"%, 0)"),i&&p.wrapper.transitionEnd(function(){p.onMonthChangeEnd("next")}),p.params.animate||p.onMonthChangeEnd("next")},p.prevMonth=function(e){"undefined"!=typeof e&&"object"!=typeof e||(e="",p.params.animate||(e=0));var a=parseInt(p.months.eq(0).attr("data-month"),10),t=parseInt(p.months.eq(0).attr("data-year"),10),n=new Date(t,a+1,(-1)),r=n.getTime(),i=!p.animating;if(p.params.minDate&&rnew Date(p.params.maxDate).getTime())return!1;if(p.params.minDate&&nr?"next":"prev",s=p.monthHTML(new Date(e,a));p.monthsTranslate=p.monthsTranslate||0;var o,l,d=p.monthsTranslate,c=!p.animating;n>r?(p.monthsTranslate--,p.animating||p.months.eq(p.months.length-1).remove(),p.wrapper.append(s),p.months=p.wrapper.find(".picker-calendar-month"),o=100*-(d-1)*u,p.months.eq(p.months.length-1).transform("translate3d("+(p.isH?o:0)+"%, "+(p.isH?0:o)+"%, 0)").addClass("picker-calendar-month-next")):(p.monthsTranslate++,p.animating||p.months.eq(0).remove(),p.wrapper.prepend(s),p.months=p.wrapper.find(".picker-calendar-month"),o=100*-(d+1)*u,p.months.eq(0).transform("translate3d("+(p.isH?o:0)+"%, "+(p.isH?0:o)+"%, 0)").addClass("picker-calendar-month-prev")),p.params.onMonthAdd&&p.params.onMonthAdd(p,"next"===i?p.months.eq(p.months.length-1)[0]:p.months.eq(0)[0]),p.animating=!0,p.onMonthChangeStart(i),l=100*p.monthsTranslate*u,p.wrapper.transition(t).transform("translate3d("+(p.isH?l:0)+"%, "+(p.isH?0:l)+"%, 0)"),c&&p.wrapper.transitionEnd(function(){p.onMonthChangeEnd(i,!0)}),p.params.animate||p.onMonthChangeEnd(i)},p.nextYear=function(){p.setYearMonth(p.currentYear+1)},p.prevYear=function(){p.setYearMonth(p.currentYear-1)},p.layout=function(){var e,a="",t="",n=p.value&&p.value.length?p.value[0]:(new Date).setHours(0,0,0,0),r=p.monthHTML(n,"prev"),i=p.monthHTML(n),s=p.monthHTML(n,"next"),o='
            '+(r+i+s)+"
            ",l="";if(p.params.weekHeader){for(e=0;e<7;e++){var d=e+p.params.firstDay>6?e-7+p.params.firstDay:e+p.params.firstDay,c=p.params.dayNamesShort[d];l+='
            '+c+"
            "}l='
            '+l+"
            "}t="picker-modal picker-calendar"+(p.params.rangePicker?" picker-calendar-range":"")+(p.params.cssClass?" "+p.params.cssClass:"");var u=p.params.toolbar?p.params.toolbarTemplate.replace(/{{closeText}}/g,p.params.toolbarCloseText):"";p.params.toolbar&&(u=p.params.toolbarTemplate.replace(/{{closeText}}/g,p.params.toolbarCloseText).replace(/{{monthPicker}}/g,p.params.monthPicker?p.params.monthPickerTemplate:"").replace(/{{yearPicker}}/g,p.params.yearPicker?p.params.yearPickerTemplate:""));var m=p.params.header?p.params.headerTemplate.replace(/{{closeText}}/g,p.params.toolbarCloseText).replace(/{{placeholder}}/g,p.params.headerPlaceholder):"",f=p.params.footer?p.params.footerTemplate.replace(/{{closeText}}/g,p.params.toolbarCloseText):"";a='
            '+m+f+u+'
            '+l+o+"
            ",p.pickerHTML=a},p.params.input&&(p.input=o(p.params.input),p.input.length>0&&(p.params.inputReadOnly&&p.input.prop("readOnly",!0),p.inline||p.input.on("click",r),p.params.inputReadOnly&&p.input.on("focus mousedown",function(e){e.preventDefault()}))),!p.inline&&p.params.closeByOutsideClick&&o("html").on("click",s),p.opened=!1,p.open=function(){var e=a(),t=!1;p.opened||(p.value||p.params.value&&(p.value=p.params.value,t=!0),p.layout(),e?(p.pickerHTML='
            '+p.pickerHTML+"
            ",p.popover=i.popover(p.pickerHTML,p.params.input,!0),p.container=o(p.popover).find(".picker-modal"),o(p.popover).on("popover:close",function(){l()})):p.inline?(p.container=o(p.pickerHTML),p.container.addClass("picker-modal-inline"),o(p.params.container).append(p.container)):(p.container=o(i.pickerModal(p.pickerHTML)),o(p.container).on("picker:close",function(){l()})),p.container[0].f7Calendar=p,p.wrapper=p.container.find(".picker-calendar-months-wrapper"),p.months=p.wrapper.find(".picker-calendar-month"),p.updateCurrentMonthYear(),p.monthsTranslate=0,p.setMonthsTranslate(),p.initCalendarEvents(),t?p.updateValue():i.params.material&&p.value&&p.updateValue(!0),p.input&&p.input.length>0&&i.params.material&&p.input.trigger("focus")),p.opened=!0,p.initialized=!0,p.params.onMonthAdd&&p.months.each(function(){p.params.onMonthAdd(p,this)}),p.params.onOpen&&p.params.onOpen(p)},p.close=function(){if(p.opened&&!p.inline)return t()?void i.closeModal(p.popover):void i.closeModal(p.container)},p.destroy=function(){p.close(),p.params.input&&p.input.length>0&&p.input.off("click focus",r),o("html").off("click",s)},p.inline?p.open():!p.initialized&&p.params.value&&p.setValue(p.params.value),p};i.calendar=function(e){return new C(e)};var y;i.addNotification=function(e){if(e){"undefined"==typeof e.media&&(e.media=i.params.notificationMedia),"undefined"==typeof e.title&&(e.title=i.params.notificationTitle),"undefined"==typeof e.subtitle&&(e.subtitle=i.params.notificationSubtitle),"undefined"==typeof e.closeIcon&&(e.closeIcon=i.params.notificationCloseIcon),"undefined"==typeof e.hold&&(e.hold=i.params.notificationHold),"undefined"==typeof e.closeOnClick&&(e.closeOnClick=i.params.notificationCloseOnClick),"undefined"==typeof e.button&&(e.button=i.params.notificationCloseButtonText&&{text:i.params.notificationCloseButtonText,close:!0}),y||(y=document.createElement("div")),e.material=i.params.material;var a=o(".notifications");0===a.length&&(i.root.append('
              '),a=o(".notifications"));var t=a.children("ul"),n=i.params.notificationTemplate||'{{#if custom}}
            • {{custom}}
            • {{else}}
            • {{#if material}}
              {{js "this.message || this.title || this.subtitle"}}
              {{#if ../button}}{{#button}}{{/button}}{{/if}}
              {{else}}{{#if media}}
              {{media}}
              {{/if}}
              {{#if title}}
              {{title}}
              {{/if}}{{#if closeIcon}}
              {{/if}}
              {{#if subtitle}}
              {{subtitle}}
              {{/if}}{{#if message}}
              {{message}}
              {{/if}}{{/if}}
            • {{/if}}';i._compiledTemplates.notification||(i._compiledTemplates.notification=l.compile(n)),y.innerHTML=i._compiledTemplates.notification(e);var r=o(y).children();r.on("click",function(a){var t=!1,n=o(a.target);e.material&&n.hasClass("button")&&e.button&&e.button.onClick&&e.button.onClick.call(n[0],a,r[0]),n.is(".close-notification")||o(a.target).parents(".close-notification").length>0?t=!0:(e.onClick&&e.onClick(a,r[0]),e.closeOnClick&&(t=!0)),t&&i.closeNotification(r[0])}),e.onClose&&r.data("f7NotificationOnClose",function(){e.onClose(r[0])}),e.additionalClass&&r.addClass(e.additionalClass),e.hold&&setTimeout(function(){r.length>0&&i.closeNotification(r[0])},e.hold),i.params.material||i.closeNotification(t.children("li.notification-item:last-child")),t.append(r[0]),a.show();var s,p=r.outerHeight();return e.material?(a.transform("translate3d(0, "+p+"px, 0)"),a.transition(0),s=r[0].clientLeft,a.transform("translate3d(0, 0, 0)"),a.transition("")):(r.transform("translate3d(0,"+-p+"px,0)"),r.transition(0),s=r[0].clientLeft,r.transition(""),r.transform("translate3d(0,0px,0)")),a.transform("translate3d(0, 0,0)"),r.removeClass("notification-hidden"),r[0]}},i.closeNotification=function(e){if(e=o(e),0!==e.length&&!e.hasClass("notification-item-removing")){var a=o(".notifications"),t=e.outerHeight();e.css("height",t+"px").transition(0).addClass("notification-item-removing");e[0].clientLeft;e.css({height:"0px",marginBottom:"0px"}).transition(""),e.data("f7NotificationOnClose")&&e.data("f7NotificationOnClose")(),0===a.find(".notification-item:not(.notification-item-removing)").length&&a.transform(""),e.addClass("notification-hidden").transitionEnd(function(){e.remove(),0===a.find(".notification-item").length&&a.hide()})}},i.initTemplate7Templates=function(){window.Template7&&(Template7.templates=Template7.templates||i.params.templates||{},Template7.data=Template7.data||i.params.template7Data||{},Template7.cache=Template7.cache||{},i.templates=Template7.templates,i.template7Data=Template7.data,i.template7Cache=Template7.cache,i.params.precompileTemplates&&o('script[type="text/template7"]').each(function(){var e=o(this).attr("id");e&&(Template7.templates[e]=Template7.compile(o(this).html()))}))};var x=[];return i.initPlugins=function(){for(var e in i.plugins){var a=i.plugins[e](i,i.params[e]);a&&x.push(a)}},i.pluginHook=function(e){for(var a=0;a=0&&o.indexOf(">")>=0){var l="div";for(0===o.indexOf(":~]/)?(t||document).querySelectorAll(a):[document.getElementById(a.split("#")[1])],r=0;r0&&a[0].nodeType)for(r=0;r=0&&(t[a.toCamelCase(i.name.split("data-")[1])]=i.value)}for(var s in t)"false"===t[s]?t[s]=!1:"true"===t[s]?t[s]=!0:parseFloat(t[s])===1*t[s]&&(t[s]=1*t[s]);return t}},val:function(e){if("undefined"!=typeof e){for(var a=0;a0?parseFloat(this.css("width")):null},outerWidth:function(e){if(this.length>0){if(e){var a=this.styles();return this[0].offsetWidth+parseFloat(a.getPropertyValue("margin-right"))+parseFloat(a.getPropertyValue("margin-left"))}return this[0].offsetWidth}return null},height:function(){return this[0]===window?window.innerHeight:this.length>0?parseFloat(this.css("height")):null},outerHeight:function(e){if(this.length>0){if(e){var a=this.styles();return this[0].offsetHeight+parseFloat(a.getPropertyValue("margin-top"))+parseFloat(a.getPropertyValue("margin-bottom"))}return this[0].offsetHeight}return null},offset:function(){if(this.length>0){var e=this[0],a=e.getBoundingClientRect(),t=document.body,n=e.clientTop||t.clientTop||0,r=e.clientLeft||t.clientLeft||0,i=window.pageYOffset||e.scrollTop,s=window.pageXOffset||e.scrollLeft;return{top:a.top+i-n,left:a.left+s-r}}return null},hide:function(){for(var e=0;en-1?new e([]):a<0?(t=n+a,new e(t<0?[]:[this[t]])):new e([this[a]])},append:function(){var a,t,n,r;for(n=0;n=0;n--)this[t].insertBefore(r.childNodes[n],this[t].childNodes[0])}else if(a instanceof e)for(n=0;n1)for(var r=0;r1)for(var r=0;r0?t?this[0].nextElementSibling&&a(this[0].nextElementSibling).is(t)?[this[0].nextElementSibling]:[]:this[0].nextElementSibling?[this[0].nextElementSibling]:[]:[])},nextAll:function(t){var n=[],r=this[0];if(!r)return new e([]);for(;r.nextElementSibling;){var i=r.nextElementSibling;t?a(i).is(t)&&n.push(i):n.push(i),r=i}return new e(n)},prev:function(t){if(this.length>0){var n=this[0];return new e(t?n.previousElementSibling&&a(n.previousElementSibling).is(t)?[n.previousElementSibling]:[]:n.previousElementSibling?[n.previousElementSibling]:[])}return new e([])},prevAll:function(t){var n=[],r=this[0];if(!r)return new e([]);for(;r.previousElementSibling;){var i=r.previousElementSibling;t?a(i).is(t)&&n.push(i):n.push(i),r=i}return new e(n)},siblings:function(e){return this.nextAll(e).add(this.prevAll(e))},parent:function(e){for(var t=[],n=0;n=0?"&":"?",l=e.method.toUpperCase();if(("GET"===l||"HEAD"===l||"OPTIONS"===l||"DELETE"===l)&&e.data){var p;p="string"==typeof e.data?e.data.indexOf("?")>=0?e.data.split("?")[1]:e.data:a.serializeObject(e.data),p.length&&(e.url+=o+p,"?"===o&&(o="&"))}if("json"===e.dataType&&e.url.indexOf("callback=")>=0){var d,c="f7jsonp_"+Date.now()+n++,u=e.url.split("callback="),m=u[0]+"callback="+c;if(u[1].indexOf("&")>=0){var f=u[1].split("&").filter(function(e){return e.indexOf("=")>0}).join("&");f.length>0&&(m+="&"+f)}var h=document.createElement("script");return h.type="text/javascript",h.onerror=function(){clearTimeout(d),r(void 0,void 0,"error",null,"scripterror"),r("ajaxComplete ajax:complete",{scripterror:!0},"complete",null,"scripterror")},h.src=m,window[c]=function(e){clearTimeout(d),r(void 0,void 0,"success",e),h.parentNode.removeChild(h),h=null,delete window[c]},document.querySelector("head").appendChild(h),void(e.timeout>0&&(d=setTimeout(function(){h.parentNode.removeChild(h),h=null,r(void 0,void 0,"error",null,"timeout")},e.timeout)))}"GET"!==l&&"HEAD"!==l&&"OPTIONS"!==l&&"DELETE"!==l||e.cache===!1&&(e.url+=o+"_nocache="+Date.now());var g=new XMLHttpRequest;g.requestUrl=e.url,g.requestParameters=e,g.open(l,e.url,e.async,e.user,e.password);var v=null;if(("POST"===l||"PUT"===l||"PATCH"===l)&&e.data)if(e.processData){var b=[ArrayBuffer,Blob,Document,FormData];if(b.indexOf(e.data.constructor)>=0)v=e.data;else{var w="---------------------------"+Date.now().toString(16);"multipart/form-data"===e.contentType?g.setRequestHeader("Content-Type","multipart/form-data; boundary="+w):g.setRequestHeader("Content-Type",e.contentType),v="";var C=a.serializeObject(e.data);if("multipart/form-data"===e.contentType){w="---------------------------"+Date.now().toString(16),C=C.split("&");for(var y=[],x=0;x=200&&g.status<300||0===g.status){var n;if("json"===e.dataType)try{n=JSON.parse(g.responseText),r("ajaxSuccess ajax:success",{xhr:g},"success",n,g.status,g)}catch(e){r("ajaxError ajax:error",{xhr:g,parseerror:!0},"error",g,"parseerror")}else n="text"===g.responseType||""===g.responseType?g.responseText:g.response,r("ajaxSuccess ajax:success",{xhr:g},"success",n,g.status,g)}else r("ajaxError ajax:error",{xhr:g},"error",g,g.status);e.statusCode&&(t.statusCode&&t.statusCode[g.status]&&t.statusCode[g.status](g),e.statusCode[g.status]&&e.statusCode[g.status](g)),r("ajaxComplete ajax:complete",{xhr:g},"complete",g,g.status)},g.onerror=function(e){T&&clearTimeout(T),r("ajaxError ajax:error",{xhr:g},"error",g,g.status),r("ajaxComplete ajax:complete",{xhr:g},"complete",g,g.status)},r("ajaxStart ajax:start",{xhr:g},"start",g),r(void 0,void 0,"beforeSend",g),e.timeout>0&&(g.onabort=function(){T&&clearTimeout(T)},T=setTimeout(function(){g.abort(),r("ajaxError ajax:error",{xhr:g,timeout:!0},"error",g,"timeout"),r("ajaxComplete ajax:complete",{xhr:g,timeout:!0},"complete",g,"timeout")},e.timeout)),g.send(v),g},function(){function e(e){a[e]=function(t,n,r,i){return a.ajax({url:t,method:"post"===e?"POST":"GET",data:"function"==typeof n?void 0:n,success:"function"==typeof n?n:r,error:"function"==typeof n?r:i,dataType:"getJSON"===e?"json":void 0})}}for(var t="get post getJSON".split(" "),n=0;n-1?e.replace(/\S*\?/,""):"",t=e.split("&"),r=t.length,a=0;a0){for(var a="",n=0;n0&&i.push(p.join(s))}else null===e[l]?i.push(n(l)+"="):"object"==typeof e[l]?(o=t.slice(),o.push(l),p=a.serializeObject(e[l],o),""!==p&&i.push(p)):"undefined"!=typeof e[l]&&""!==e[l]?i.push(n(l)+"="+r(e[l])):""===e[l]&&i.push(n(l))}return i.join(s)},a.toCamelCase=function(e){return e.toLowerCase().replace(/-(.)/g,function(e,a){return a.toUpperCase()})},a.dataset=function(e){return a(e).dataset()},a.getTranslate=function(e,a){var t,n,r,i;return"undefined"==typeof a&&(a="x"),r=window.getComputedStyle(e,null),window.WebKitCSSMatrix?(n=r.transform||r.webkitTransform,n.split(",").length>6&&(n=n.split(", ").map(function(e){return e.replace(",",".")}).join(", ")),i=new WebKitCSSMatrix("none"===n?"":n)):(i=r.transform||r.getPropertyValue("transform").replace("translate(","matrix(1, 0, 0, 1,"),t=i.toString().split(",")),"x"===a&&(n=window.WebKitCSSMatrix?i.m41:16===t.length?parseFloat(t[12]):parseFloat(t[4])),"y"===a&&(n=window.WebKitCSSMatrix?i.m42:16===t.length?parseFloat(t[13]):parseFloat(t[5])),n||0},a.requestAnimationFrame=function(e){return window.requestAnimationFrame?window.requestAnimationFrame(e):window.webkitRequestAnimationFrame?window.webkitRequestAnimationFrame(e):window.setTimeout(e,1e3/60)},a.cancelAnimationFrame=function(e){return window.cancelAnimationFrame?window.cancelAnimationFrame(e):window.webkitCancelAnimationFrame?window.webkitCancelAnimationFrame(e):window.clearTimeout(e)},a.supportTouch=!!("ontouchstart"in window||window.DocumentTouch&&document instanceof DocumentTouch);for(var r=[{base:"A",letters:"AⒶAÀÁÂẦẤẪẨÃĀĂẰẮẴẲȦǠÄǞẢÅǺǍȀȂẠẬẶḀĄȺⱯ"},{base:"AA",letters:"Ꜳ"},{base:"AE",letters:"ÆǼǢ"},{base:"AO",letters:"Ꜵ"},{base:"AU",letters:"Ꜷ"},{base:"AV",letters:"ꜸꜺ"},{base:"AY",letters:"Ꜽ"},{base:"B",letters:"BⒷBḂḄḆɃƂƁ"},{base:"C",letters:"CⒸCĆĈĊČÇḈƇȻꜾ"},{base:"D",letters:"DⒹDḊĎḌḐḒḎĐƋƊƉꝹ"},{base:"DZ",letters:"DZDŽ"},{base:"Dz",letters:"DzDž"},{base:"E",letters:"EⒺEÈÉÊỀẾỄỂẼĒḔḖĔĖËẺĚȄȆẸỆȨḜĘḘḚƐƎ"},{base:"F",letters:"FⒻFḞƑꝻ"},{base:"G",letters:"GⒼGǴĜḠĞĠǦĢǤƓꞠꝽꝾ"},{base:"H",letters:"HⒽHĤḢḦȞḤḨḪĦⱧⱵꞍ"},{base:"I",letters:"IⒾIÌÍÎĨĪĬİÏḮỈǏȈȊỊĮḬƗ"},{base:"J",letters:"JⒿJĴɈ"},{base:"K",letters:"KⓀKḰǨḲĶḴƘⱩꝀꝂꝄꞢ"},{base:"L",letters:"LⓁLĿĹĽḶḸĻḼḺŁȽⱢⱠꝈꝆꞀ"},{base:"LJ",letters:"LJ"},{base:"Lj",letters:"Lj"},{base:"M",letters:"MⓂMḾṀṂⱮƜ"},{base:"N",letters:"NⓃNǸŃÑṄŇṆŅṊṈȠƝꞐꞤ"},{base:"NJ",letters:"NJ"},{base:"Nj",letters:"Nj"},{base:"O",letters:"OⓄOÒÓÔỒỐỖỔÕṌȬṎŌṐṒŎȮȰÖȪỎŐǑȌȎƠỜỚỠỞỢỌỘǪǬØǾƆƟꝊꝌ"},{base:"OI",letters:"Ƣ"},{base:"OO",letters:"Ꝏ"},{base:"OU",letters:"Ȣ"},{base:"OE",letters:"ŒŒ"},{base:"oe",letters:"œœ"},{base:"P",letters:"PⓅPṔṖƤⱣꝐꝒꝔ"},{base:"Q",letters:"QⓆQꝖꝘɊ"},{base:"R",letters:"RⓇRŔṘŘȐȒṚṜŖṞɌⱤꝚꞦꞂ"},{base:"S",letters:"SⓈSẞŚṤŜṠŠṦṢṨȘŞⱾꞨꞄ"},{base:"T",letters:"TⓉTṪŤṬȚŢṰṮŦƬƮȾꞆ"},{base:"TZ",letters:"Ꜩ"},{base:"U",letters:"UⓊUÙÚÛŨṸŪṺŬÜǛǗǕǙỦŮŰǓȔȖƯỪỨỮỬỰỤṲŲṶṴɄ"},{base:"V",letters:"VⓋVṼṾƲꝞɅ"},{base:"VY",letters:"Ꝡ"},{base:"W",letters:"WⓌWẀẂŴẆẄẈⱲ"},{base:"X",letters:"XⓍXẊẌ"},{base:"Y",letters:"YⓎYỲÝŶỸȲẎŸỶỴƳɎỾ"},{base:"Z",letters:"ZⓏZŹẐŻŽẒẔƵȤⱿⱫꝢ"},{base:"a",letters:"aⓐaẚàáâầấẫẩãāăằắẵẳȧǡäǟảåǻǎȁȃạậặḁąⱥɐ"},{base:"aa",letters:"ꜳ"},{base:"ae",letters:"æǽǣ"},{base:"ao",letters:"ꜵ"},{base:"au",letters:"ꜷ"},{base:"av",letters:"ꜹꜻ"},{base:"ay", letters:"ꜽ"},{base:"b",letters:"bⓑbḃḅḇƀƃɓ"},{base:"c",letters:"cⓒcćĉċčçḉƈȼꜿↄ"},{base:"d",letters:"dⓓdḋďḍḑḓḏđƌɖɗꝺ"},{base:"dz",letters:"dzdž"},{base:"e",letters:"eⓔeèéêềếễểẽēḕḗĕėëẻěȅȇẹệȩḝęḙḛɇɛǝ"},{base:"f",letters:"fⓕfḟƒꝼ"},{base:"g",letters:"gⓖgǵĝḡğġǧģǥɠꞡᵹꝿ"},{base:"h",letters:"hⓗhĥḣḧȟḥḩḫẖħⱨⱶɥ"},{base:"hv",letters:"ƕ"},{base:"i",letters:"iⓘiìíîĩīĭïḯỉǐȉȋịįḭɨı"},{base:"j",letters:"jⓙjĵǰɉ"},{base:"k",letters:"kⓚkḱǩḳķḵƙⱪꝁꝃꝅꞣ"},{base:"l",letters:"lⓛlŀĺľḷḹļḽḻſłƚɫⱡꝉꞁꝇ"},{base:"lj",letters:"lj"},{base:"m",letters:"mⓜmḿṁṃɱɯ"},{base:"n",letters:"nⓝnǹńñṅňṇņṋṉƞɲʼnꞑꞥ"},{base:"nj",letters:"nj"},{base:"o",letters:"oⓞoòóôồốỗổõṍȭṏōṑṓŏȯȱöȫỏőǒȍȏơờớỡởợọộǫǭøǿɔꝋꝍɵ"},{base:"oi",letters:"ƣ"},{base:"ou",letters:"ȣ"},{base:"oo",letters:"ꝏ"},{base:"p",letters:"pⓟpṕṗƥᵽꝑꝓꝕ"},{base:"q",letters:"qⓠqɋꝗꝙ"},{base:"r",letters:"rⓡrŕṙřȑȓṛṝŗṟɍɽꝛꞧꞃ"},{base:"s",letters:"sⓢsßśṥŝṡšṧṣṩșşȿꞩꞅẛ"},{base:"t",letters:"tⓣtṫẗťṭțţṱṯŧƭʈⱦꞇ"},{base:"tz",letters:"ꜩ"},{base:"u",letters:"uⓤuùúûũṹūṻŭüǜǘǖǚủůűǔȕȗưừứữửựụṳųṷṵʉ"},{base:"v",letters:"vⓥvṽṿʋꝟʌ"},{base:"vy",letters:"ꝡ"},{base:"w",letters:"wⓦwẁẃŵẇẅẘẉⱳ"},{base:"x",letters:"xⓧxẋẍ"},{base:"y",letters:"yⓨyỳýŷỹȳẏÿỷẙỵƴɏỿ"},{base:"z",letters:"zⓩzźẑżžẓẕƶȥɀⱬꝣ"}],i={},s=0;so&&m>=c&&(h.scrollTop=c,t=!0),g&&cl&&f>=u&&(h.scrollLeft=u,t=!0),v&&u0||0===t,v=e>0||0===e;if("undefined"==typeof r&&(r="swing"),g&&(o=h.scrollTop,n||(h.scrollTop=t)),v&&(l=h.scrollLeft,n||(h.scrollLeft=e)),n){g&&(p=h.scrollHeight-h.offsetHeight,c=Math.max(Math.min(t,p),0)),v&&(d=h.scrollWidth-h.offsetWidth,u=Math.max(Math.min(e,d),0));var b=null;g&&c===o&&(g=!1),v&&u===l&&(v=!1),a.requestAnimationFrame(s)}})},a.fn.scrollTop=function(e,a,t,n){3===arguments.length&&"function"==typeof t&&(n=t,t=void 0);var r=this;return"undefined"==typeof e?r.length>0?r[0].scrollTop:null:r.scrollTo(void 0,e,a,t,n)},a.fn.scrollLeft=function(e,a,t,n){3===arguments.length&&"function"==typeof t&&(n=t,t=void 0);var r=this;return"undefined"==typeof e?r.length>0?r[0].scrollLeft:null:r.scrollTo(e,void 0,a,t,n)},a}();Framework7.$=e;var a=e;window.Dom7=e;var t=function(e,t,n){t=t||{},n=n||{};var r={duration:300,easing:"swing"};for(var i in r)"undefined"==typeof n[i]&&(n[i]=r[i]);var s=this;if(s.params=n,s.props=t,s.elements=a(e),0===s.elements.length)return s;s.easingProgress=function(e,a){return"swing"===e?.5-Math.cos(a*Math.PI)/2:"function"==typeof e?e(a):a},s.stop=function(){s.frameId&&a.cancelAnimationFrame(s.frameId),s.animating=!1,s.elements.each(function(e,a){delete a.animate7Instance}),s.que=[]},s.done=function(a){if(s.animating=!1,s.elements.each(function(e,a){delete a.animate7Instance}),a&&a(e),s.que.length>0){var t=s.que.shift();s.animate(t[0],t[1])}},s.animating=!1,s.que=[],s.animate=function(t,n){function r(){o=(new Date).getTime();var m,f,h;u||(u=!0,n.begin&&n.begin(e)),null===p&&(p=o),n.progress&&n.progress(s.elements,Math.max(Math.min((o-p)/n.duration,1),0),p+n.duration-o<0?0:p+n.duration-o,p);for(var g=0;gh[v].initialValue&&h[v].currentValue>=h[v].finalValue||h[v].finalValue=0),(i||o||s)&&(a.os="ios",a.ios=!0),o&&!s&&(a.osVersion=o[2].replace(/_/g,"."),a.iphone=!0),i&&(a.osVersion=i[2].replace(/_/g,"."),a.ipad=!0),s&&(a.osVersion=s[3]?s[3].replace(/_/g,"."):null,a.iphone=!0),a.ios&&a.osVersion&&t.indexOf("Version/")>=0&&"10"===a.osVersion.split(".")[0]&&(a.osVersion=t.toLowerCase().split("version/")[1].split(" ")[0]),a.webView=(o||i||s)&&t.match(/.*AppleWebKit(?!.*Safari)/i),a.os&&"ios"===a.os){var l=a.osVersion.split(".");a.minimalUi=!a.webView&&(s||o)&&(1*l[0]===7?1*l[1]>=1:1*l[0]>7)&&n('meta[name="viewport"]').length>0&&n('meta[name="viewport"]').attr("content").indexOf("minimal-ui")>=0}var p=n(window).width(),d=n(window).height();a.needsStatusBar=function(){return!(!a.webView||p*d!==screen.width*screen.height)},a.statusBar=a.needsStatusBar();var c=[];if(a.pixelRatio=window.devicePixelRatio||1,c.push("pixel-ratio-"+Math.floor(a.pixelRatio)),a.pixelRatio>=2&&c.push("retina"),a.os&&(c.push(a.os,a.os+"-"+a.osVersion.split(".")[0],a.os+"-"+a.osVersion.replace(/\./g,"-")),"ios"===a.os))for(var u=parseInt(a.osVersion.split(".")[0],10),m=u-1;m>=6;m--)c.push("ios-gt-"+m);return a.statusBar?c.push("with-statusbar-overlay"):n("html").removeClass("with-statusbar-overlay"),c.length>0&&n("html").addClass(c.join(" ")),a}(),Framework7.prototype.plugins={},window.Template7=function(){function e(e){return"[object Array]"===Object.prototype.toString.apply(e)}function a(e){return"function"==typeof e}function t(e){return"undefined"!=typeof window&&window.escape?window.escape(e):e.replace(/&/g,"&").replace(//g,">").replace(/"/g,""")}function n(e){var a,t,n,r=e.replace(/[{}#}]/g,"").split(" "),o=[];for(t=0;t=0){a=n,o.push(d);break}a&&(t=a)}else if(d.indexOf("=")>0){var c=d.split("="),u=c[0],m=c[1];if(l||(l=0===m.indexOf('"')?s:i,p=0===m.indexOf('"')?'"':"'"),2!==m.match(l).length){for(a=0,n=t+1;n=0){a=n;break}a&&(t=a)}var f=[u,m.replace(l,"")];o.push(f)}else o.push(d)}return o}function r(a){var t,r,i=[];if(!a)return[];var s=a.split(/({{[^{^}]*}})/);for(t=0;t=0)continue;if(o.indexOf("{#")<0&&o.indexOf(" ")<0&&o.indexOf("else")<0){i.push({type:"variable",contextName:o.replace(/[{}]/g,"")});continue}var l=n(o),p=l[0],d=">"===p,c=[],u={};for(r=1;r=0){var f,h="",g="",v=0,b=!1,w=!1,C=0;for(r=t+1;r=0&&C++,s[r].indexOf("{{/")>=0&&C--,s[r].indexOf("{{#"+p)>=0)h+=s[r],w&&(g+=s[r]),v++;else if(s[r].indexOf("{{/"+p)>=0){if(!(v>0)){f=r,b=!0;break}v--,h+=s[r],w&&(g+=s[r])}else s[r].indexOf("else")>=0&&0===C?w=!0:(w||(h+=s[r]),w&&(g+=s[r]));b&&(f&&(t=f),i.push({type:"helper",helperName:p,contextName:c,content:h,inverseContent:g,hash:u}))}else o.indexOf(" ")>0&&(d&&(p="_partial",c[0]&&(c[0]='"'+c[0].replace(/"|'/g,"")+'"')),i.push({type:"helper",helperName:p,contextName:c,hash:u}))}}return i}var i=new RegExp("'","g"),s=new RegExp('"',"g"),o=function(e,a){function t(e,a){return e.content?o(e.content,a):function(){return""}}function n(e,a){return e.inverseContent?o(e.inverseContent,a):function(){return""}}function i(e,a){var t,n,r=0;if(0===e.indexOf("../")){r=e.split("../").length-1;var i=a.split("_")[1]-r;a="ctx_"+(i>=1?i:1),n=e.split("../")[r].split(".")}else 0===e.indexOf("@global")?(a="Template7.global",n=e.split("@global.")[1].split(".")):0===e.indexOf("@root")?(a="root",n=e.split("@root.")[1].split(".")):n=e.split(".");t=a;for(var s=0;s0?t+="[(data && data."+o.replace("@","")+")]":t="(data && data."+e.replace("@","")+")":isFinite(o)?t+="["+o+"]":"this"===o||o.indexOf("this.")>=0||o.indexOf("this[")>=0||o.indexOf("this(")>=0?t=o.replace("this",a):t+="."+o}return t}function s(e,a){for(var t=[],n=0;n0)throw new Error('Template7: Missing helper: "'+u.helperName+'"');m=i(u.helperName,p),d+="if ("+m+") {",d+="if (isArray("+m+")) {",d+="r += (Template7.helpers.each).call("+p+", "+m+", {hash:"+JSON.stringify(u.hash)+", data: data || {}, fn: "+t(u,a+1)+", inverse: "+n(u,a+1)+", root: root});",d+="}else {",d+="r += (Template7.helpers.with).call("+p+", "+m+", {hash:"+JSON.stringify(u.hash)+", data: data || {}, fn: "+t(u,a+1)+", inverse: "+n(u,a+1)+", root: root});",d+="}}"}}else d+="r +='"+u.content.replace(/\r/g,"\\r").replace(/\n/g,"\\n").replace(/'/g,"\\'")+"';"}return d+="\nreturn r;})",eval.call(window,d)}var l=this;l.template=e,l.compile=function(e){return l.compiled||(l.compiled=o(e)),l.compiled}};o.prototype={options:{},partials:{},helpers:{_partial:function(e,a){var t=o.prototype.partials[e];if(!t||t&&!t.template)return"";t.compiled||(t.compiled=new o(t.template).compile());var n=this;for(var r in a.hash)n[r]=a.hash[r];return t.compiled(n,a.data,a.root)},escape:function(e,a){if("string"!=typeof e)throw new Error('Template7: Passed context to "escape" helper should be a string');return t(e)},if:function(e,t){return a(e)&&(e=e.call(this)),e?t.fn(this,t.data):t.inverse(this,t.data)},unless:function(e,t){return a(e)&&(e=e.call(this)),e?t.inverse(this,t.data):t.fn(this,t.data)},each:function(t,n){var r="",i=0;if(a(t)&&(t=t.call(this)),e(t)){for(n.hash.reverse&&(t=t.reverse()),i=0;i0?r:n.inverse(this)},with:function(e,t){return a(e)&&(e=e.call(this)),t.fn(e)},join:function(e,t){return a(e)&&(e=e.call(this)),e.join(t.hash.delimiter||t.hash.delimeter)},js:function(e,a){var t;return t=e.indexOf("return")>=0?"(function(){"+e+"})":"(function(){return ("+e+")})",eval.call(this,t).call(this)},js_compare:function(e,a){var t;t=e.indexOf("return")>=0?"(function(){"+e+"})":"(function(){return ("+e+")})";var n=eval.call(this,t).call(this);return n?a.fn(this,a.data):a.inverse(this,a.data)}}};var l=function(e,a){if(2===arguments.length){var t=new o(e),n=t.compile()(a);return t=null,n}return new o(e)};return l.registerHelper=function(e,a){o.prototype.helpers[e]=a},l.unregisterHelper=function(e){o.prototype.helpers[e]=void 0,delete o.prototype.helpers[e]},l.registerPartial=function(e,a){o.prototype.partials[e]={template:a}},l.unregisterPartial=function(e,a){o.prototype.partials[e]&&(o.prototype.partials[e]=void 0,delete o.prototype.partials[e])},l.compile=function(e,a){var t=new o(e,a);return t.compile()},l.options=o.prototype.options,l.helpers=o.prototype.helpers,l.partials=o.prototype.partials,l}(),window.Swiper=function(t,n){function r(e){return Math.floor(e)}function i(){var e=v.params.autoplay,a=v.slides.eq(v.activeIndex);a.attr("data-swiper-autoplay")&&(e=a.attr("data-swiper-autoplay")||v.params.autoplay),v.autoplayTimeoutId=setTimeout(function(){v.params.loop?(v.fixLoop(),v._slideNext(),v.emit("onAutoplay",v)):v.isEnd?n.autoplayStopOnLast?v.stopAutoplay():(v._slideTo(0),v.emit("onAutoplay",v)):(v._slideNext(),v.emit("onAutoplay",v))},e)}function s(e,t){var n=a(e.target);if(!n.is(t))if("string"==typeof t)n=n.parents(t);else if(t.nodeType){var r;return n.parents().each(function(e,a){a===t&&(r=t)}),r?t:void 0}if(0!==n.length)return n[0]}function o(e,a){a=a||{};var t=window.MutationObserver||window.WebkitMutationObserver,n=new t(function(e){e.forEach(function(e){v.onResize(!0),v.emit("onObserverUpdate",v,e)})});n.observe(e,{attributes:"undefined"==typeof a.attributes||a.attributes,childList:"undefined"==typeof a.childList||a.childList,characterData:"undefined"==typeof a.characterData||a.characterData}),v.observers.push(n)}function l(e,t){e=a(e);var n,r,i,s=v.rtl?-1:1;n=e.attr("data-swiper-parallax")||"0",r=e.attr("data-swiper-parallax-x"),i=e.attr("data-swiper-parallax-y"),r||i?(r=r||"0",i=i||"0"):v.isHorizontal()?(r=n,i="0"):(i=n,r="0"),r=r.indexOf("%")>=0?parseInt(r,10)*t*s+"%":r*t*s+"px",i=i.indexOf("%")>=0?parseInt(i,10)*t+"%":i*t+"px",e.transform("translate3d("+r+", "+i+",0px)")}function p(e){return 0!==e.indexOf("on")&&(e=e[0]!==e[0].toUpperCase()?"on"+e[0].toUpperCase()+e.substring(1):"on"+e),e}if(!(this instanceof Swiper))return new Swiper(t,n);var d={direction:"horizontal",touchEventsTarget:"container",initialSlide:0,speed:300,autoplay:!1,autoplayDisableOnInteraction:!0,autoplayStopOnLast:!1,iOSEdgeSwipeDetection:!1,iOSEdgeSwipeThreshold: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",coverflow:{rotate:50,stretch:0,depth:100,modifier:1,slideShadows:!0},flip:{slideShadows:!0,limitRotation:!0},cube:{slideShadows:!0,shadow:!0,shadowOffset:20,shadowScale:.94},fade:{crossFade:!1},parallax:!1,zoom:!1,zoomMax:3,zoomMin:1,zoomToggle:!0,scrollbar:null,scrollbarHide:!0,scrollbarDraggable:!1,scrollbarSnapOnRelease:!1,keyboardControl:!1,mousewheelControl:!1,mousewheelReleaseOnEdges:!1,mousewheelInvert:!1,mousewheelForceToAxis:!1,mousewheelSensitivity:1,mousewheelEventsTarged:"container",hashnav:!1,hashnavWatchState:!1,history:!1,replaceState:!1,breakpoints:void 0,spaceBetween:0,slidesPerView:1,slidesPerColumn:1,slidesPerColumnFill:"column",slidesPerGroup:1,centeredSlides:!1,slidesOffsetBefore:0,slidesOffsetAfter:0,roundLengths:!1,touchRatio:1,touchAngle:45,simulateTouch:!0,shortSwipes:!0,longSwipes:!0,longSwipesRatio:.5,longSwipesMs:300,followFinger:!0,onlyExternal:!1,threshold:0,touchMoveStopPropagation:!0,touchReleaseOnEdges:!1,uniqueNavElements:!0,pagination:null,paginationElement:"span",paginationClickable:!1,paginationHide:!1,paginationBulletRender:null,paginationProgressRender:null,paginationFractionRender:null,paginationCustomRender:null,paginationType:"bullets",resistance:!0,resistanceRatio:.85,nextButton:null,prevButton:null,watchSlidesProgress:!1,watchSlidesVisibility:!1,grabCursor:!1,preventClicks:!0,preventClicksPropagation:!0,slideToClickedSlide:!1,lazyLoading:!1,lazyLoadingInPrevNext:!1,lazyLoadingInPrevNextAmount:1,lazyLoadingOnTransitionStart:!1,preloadImages:!0,updateOnImagesReady:!0,loop:!1,loopAdditionalSlides:0,loopedSlides:null,control:void 0,controlInverse:!1,controlBy:"slide",normalizeSlideIndex:!0,allowSwipeToPrev:!0,allowSwipeToNext:!0,swipeHandler:null,noSwiping:!0,noSwipingClass:"swiper-no-swiping",passiveListeners:!0,containerModifierClass:"swiper-container-",slideClass:"swiper-slide",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",bulletClass:"swiper-pagination-bullet",bulletActiveClass:"swiper-pagination-bullet-active",buttonDisabledClass:"swiper-button-disabled",paginationCurrentClass:"swiper-pagination-current",paginationTotalClass:"swiper-pagination-total",paginationHiddenClass:"swiper-pagination-hidden",paginationProgressbarClass:"swiper-pagination-progressbar",paginationClickableClass:"swiper-pagination-clickable",paginationModifierClass:"swiper-pagination-",lazyLoadingClass:"swiper-lazy",lazyStatusLoadingClass:"swiper-lazy-loading",lazyStatusLoadedClass:"swiper-lazy-loaded",lazyPreloaderClass:"swiper-lazy-preloader",notificationClass:"swiper-notification",preloaderClass:"preloader",zoomContainerClass:"swiper-zoom-container",observer:!1,observeParents:!1,a11y:!1,prevSlideMessage:"Previous slide",nextSlideMessage:"Next slide",firstSlideMessage:"This is the first slide",lastSlideMessage:"This is the last slide",paginationBulletMessage:"Go to slide {{index}}",runCallbacksOnInit:!0},c=n&&n.virtualTranslate;n=n||{};var u={};for(var m in n)if("object"!=typeof n[m]||null===n[m]||(n[m].nodeType||n[m]===window||n[m]===document||"undefined"!=typeof e&&n[m]instanceof e||"undefined"!=typeof jQuery&&n[m]instanceof jQuery))u[m]=n[m];else{u[m]={};for(var f in n[m])u[m][f]=n[m][f]}for(var h in d)if("undefined"==typeof n[h])n[h]=d[h];else if("object"==typeof n[h])for(var g in d[h])"undefined"==typeof n[h][g]&&(n[h][g]=d[h][g]);var v=this;if(v.params=n,v.originalParams=u,v.classNames=[],"undefined"!=typeof a&&"undefined"!=typeof e&&(a=e),("undefined"!=typeof a||(a="undefined"==typeof e?window.Dom7||window.Zepto||window.jQuery:e))&&(v.$=a,v.currentBreakpoint=void 0,v.getActiveBreakpoint=function(){if(!v.params.breakpoints)return!1;var e,a=!1,t=[];for(e in v.params.breakpoints)v.params.breakpoints.hasOwnProperty(e)&&t.push(e);t.sort(function(e,a){return parseInt(e,10)>parseInt(a,10)});for(var n=0;n=window.innerWidth&&!a&&(a=e);return a||"max"},v.setBreakpoint=function(){var e=v.getActiveBreakpoint();if(e&&v.currentBreakpoint!==e){var a=e in v.params.breakpoints?v.params.breakpoints[e]:v.originalParams,t=v.params.loop&&a.slidesPerView!==v.params.slidesPerView;for(var n in a)v.params[n]=a[n];v.currentBreakpoint=e,t&&v.destroyLoop&&v.reLoop(!0)}},v.params.breakpoints&&v.setBreakpoint(),v.container=a(t),0!==v.container.length)){if(v.container.length>1){var b=[];return v.container.each(function(){b.push(new Swiper(this,n))}),b}v.container[0].swiper=v,v.container.data("swiper",v),v.classNames.push(v.params.containerModifierClass+v.params.direction),v.params.freeMode&&v.classNames.push(v.params.containerModifierClass+"free-mode"),v.support.flexbox||(v.classNames.push(v.params.containerModifierClass+"no-flexbox"),v.params.slidesPerColumn=1),v.params.autoHeight&&v.classNames.push(v.params.containerModifierClass+"autoheight"),(v.params.parallax||v.params.watchSlidesVisibility)&&(v.params.watchSlidesProgress=!0),v.params.touchReleaseOnEdges&&(v.params.resistanceRatio=0),["cube","coverflow","flip"].indexOf(v.params.effect)>=0&&(v.support.transforms3d?(v.params.watchSlidesProgress=!0,v.classNames.push(v.params.containerModifierClass+"3d")):v.params.effect="slide"),"slide"!==v.params.effect&&v.classNames.push(v.params.containerModifierClass+v.params.effect),"cube"===v.params.effect&&(v.params.resistanceRatio=0,v.params.slidesPerView=1,v.params.slidesPerColumn=1,v.params.slidesPerGroup=1,v.params.centeredSlides=!1,v.params.spaceBetween=0,v.params.virtualTranslate=!0,v.params.setWrapperSize=!1),"fade"!==v.params.effect&&"flip"!==v.params.effect||(v.params.slidesPerView=1,v.params.slidesPerColumn=1,v.params.slidesPerGroup=1,v.params.watchSlidesProgress=!0,v.params.spaceBetween=0,v.params.setWrapperSize=!1,"undefined"==typeof c&&(v.params.virtualTranslate=!0)),v.params.grabCursor&&v.support.touch&&(v.params.grabCursor=!1),v.wrapper=v.container.children("."+v.params.wrapperClass),v.params.pagination&&(v.paginationContainer=a(v.params.pagination),v.params.uniqueNavElements&&"string"==typeof v.params.pagination&&v.paginationContainer.length>1&&1===v.container.find(v.params.pagination).length&&(v.paginationContainer=v.container.find(v.params.pagination)),"bullets"===v.params.paginationType&&v.params.paginationClickable?v.paginationContainer.addClass(v.params.paginationModifierClass+"clickable"):v.params.paginationClickable=!1,v.paginationContainer.addClass(v.params.paginationModifierClass+v.params.paginationType)),(v.params.nextButton||v.params.prevButton)&&(v.params.nextButton&&(v.nextButton=a(v.params.nextButton),v.params.uniqueNavElements&&"string"==typeof v.params.nextButton&&v.nextButton.length>1&&1===v.container.find(v.params.nextButton).length&&(v.nextButton=v.container.find(v.params.nextButton))),v.params.prevButton&&(v.prevButton=a(v.params.prevButton),v.params.uniqueNavElements&&"string"==typeof v.params.prevButton&&v.prevButton.length>1&&1===v.container.find(v.params.prevButton).length&&(v.prevButton=v.container.find(v.params.prevButton)))),v.isHorizontal=function(){return"horizontal"===v.params.direction},v.rtl=v.isHorizontal()&&("rtl"===v.container[0].dir.toLowerCase()||"rtl"===v.container.css("direction")),v.rtl&&v.classNames.push(v.params.containerModifierClass+"rtl"),v.rtl&&(v.wrongRTL="-webkit-box"===v.wrapper.css("display")),v.params.slidesPerColumn>1&&v.classNames.push(v.params.containerModifierClass+"multirow"),v.device.android&&v.classNames.push(v.params.containerModifierClass+"android"),v.container.addClass(v.classNames.join(" ")),v.translate=0,v.progress=0,v.velocity=0,v.lockSwipeToNext=function(){v.params.allowSwipeToNext=!1,v.params.allowSwipeToPrev===!1&&v.params.grabCursor&&v.unsetGrabCursor()},v.lockSwipeToPrev=function(){v.params.allowSwipeToPrev=!1,v.params.allowSwipeToNext===!1&&v.params.grabCursor&&v.unsetGrabCursor()},v.lockSwipes=function(){v.params.allowSwipeToNext=v.params.allowSwipeToPrev=!1,v.params.grabCursor&&v.unsetGrabCursor()},v.unlockSwipeToNext=function(){v.params.allowSwipeToNext=!0,v.params.allowSwipeToPrev===!0&&v.params.grabCursor&&v.setGrabCursor()},v.unlockSwipeToPrev=function(){v.params.allowSwipeToPrev=!0,v.params.allowSwipeToNext===!0&&v.params.grabCursor&&v.setGrabCursor()},v.unlockSwipes=function(){v.params.allowSwipeToNext=v.params.allowSwipeToPrev=!0,v.params.grabCursor&&v.setGrabCursor()},v.setGrabCursor=function(e){v.container[0].style.cursor="move",v.container[0].style.cursor=e?"-webkit-grabbing":"-webkit-grab",v.container[0].style.cursor=e?"-moz-grabbin":"-moz-grab",v.container[0].style.cursor=e?"grabbing":"grab"},v.unsetGrabCursor=function(){v.container[0].style.cursor=""},v.params.grabCursor&&v.setGrabCursor(),v.imagesToLoad=[],v.imagesLoaded=0,v.loadImage=function(e,a,t,n,r,i){function s(){i&&i()}var o;e.complete&&r?s():a?(o=new window.Image,o.onload=s,o.onerror=s,n&&(o.sizes=n),t&&(o.srcset=t),a&&(o.src=a)):s()},v.preloadImages=function(){function e(){"undefined"!=typeof v&&null!==v&&v&&(void 0!==v.imagesLoaded&&v.imagesLoaded++,v.imagesLoaded===v.imagesToLoad.length&&(v.params.updateOnImagesReady&&v.update(),v.emit("onImagesReady",v)))}v.imagesToLoad=v.container.find("img");for(var a=0;a1)for(e=0;ev.slides.length)break;a.push(v.slides.eq(n)[0])}else a.push(v.slides.eq(v.activeIndex)[0]);for(e=0;et?r:t}t&&v.wrapper.css("height",t+"px")},v.updateContainerSize=function(){var e,a;e="undefined"!=typeof v.params.width?v.params.width:v.container[0].clientWidth,a="undefined"!=typeof v.params.height?v.params.height:v.container[0].clientHeight,0===e&&v.isHorizontal()||0===a&&!v.isHorizontal()||(e=e-parseInt(v.container.css("padding-left"),10)-parseInt(v.container.css("padding-right"),10),a=a-parseInt(v.container.css("padding-top"),10)-parseInt(v.container.css("padding-bottom"),10),v.width=e,v.height=a,v.size=v.isHorizontal()?v.width:v.height)},v.updateSlidesSize=function(){v.slides=v.wrapper.children("."+v.params.slideClass),v.snapGrid=[],v.slidesGrid=[],v.slidesSizesGrid=[];var e,a=v.params.spaceBetween,t=-v.params.slidesOffsetBefore,n=0,i=0;if("undefined"!=typeof v.size){"string"==typeof a&&a.indexOf("%")>=0&&(a=parseFloat(a.replace("%",""))/100*v.size),v.virtualSize=-a,v.rtl?v.slides.css({marginLeft:"",marginTop:""}):v.slides.css({marginRight:"",marginBottom:""});var s;v.params.slidesPerColumn>1&&(s=Math.floor(v.slides.length/v.params.slidesPerColumn)===v.slides.length/v.params.slidesPerColumn?v.slides.length:Math.ceil(v.slides.length/v.params.slidesPerColumn)*v.params.slidesPerColumn,"auto"!==v.params.slidesPerView&&"row"===v.params.slidesPerColumnFill&&(s=Math.max(s,v.params.slidesPerView*v.params.slidesPerColumn)));var o,l=v.params.slidesPerColumn,p=s/l,d=p-(v.params.slidesPerColumn*p-v.slides.length);for(e=0;e1){var u,m,f;"column"===v.params.slidesPerColumnFill?(m=Math.floor(e/l),f=e-m*l,(m>d||m===d&&f===l-1)&&++f>=l&&(f=0,m++),u=m+f*s/l,c.css({"-webkit-box-ordinal-group":u,"-moz-box-ordinal-group":u,"-ms-flex-order":u,"-webkit-order":u,order:u})):(f=Math.floor(e/p),m=e-f*p),c.css("margin-"+(v.isHorizontal()?"top":"left"),0!==f&&v.params.spaceBetween&&v.params.spaceBetween+"px").attr("data-swiper-column",m).attr("data-swiper-row",f)}"none"!==c.css("display")&&("auto"===v.params.slidesPerView?(o=v.isHorizontal()?c.outerWidth(!0):c.outerHeight(!0),v.params.roundLengths&&(o=r(o))):(o=(v.size-(v.params.slidesPerView-1)*a)/v.params.slidesPerView,v.params.roundLengths&&(o=r(o)),v.isHorizontal()?v.slides[e].style.width=o+"px":v.slides[e].style.height=o+"px"),v.slides[e].swiperSlideSize=o,v.slidesSizesGrid.push(o),v.params.centeredSlides?(t=t+o/2+n/2+a,0===e&&(t=t-v.size/2-a),Math.abs(t)<.001&&(t=0),i%v.params.slidesPerGroup===0&&v.snapGrid.push(t),v.slidesGrid.push(t)):(i%v.params.slidesPerGroup===0&&v.snapGrid.push(t),v.slidesGrid.push(t),t=t+o+a),v.virtualSize+=o+a,n=o,i++)}v.virtualSize=Math.max(v.virtualSize,v.size)+v.params.slidesOffsetAfter;var h;if(v.rtl&&v.wrongRTL&&("slide"===v.params.effect||"coverflow"===v.params.effect)&&v.wrapper.css({width:v.virtualSize+v.params.spaceBetween+"px"}),v.support.flexbox&&!v.params.setWrapperSize||(v.isHorizontal()?v.wrapper.css({width:v.virtualSize+v.params.spaceBetween+"px"}):v.wrapper.css({height:v.virtualSize+v.params.spaceBetween+"px"})),v.params.slidesPerColumn>1&&(v.virtualSize=(o+v.params.spaceBetween)*s,v.virtualSize=Math.ceil(v.virtualSize/v.params.slidesPerColumn)-v.params.spaceBetween,v.isHorizontal()?v.wrapper.css({width:v.virtualSize+v.params.spaceBetween+"px"}):v.wrapper.css({height:v.virtualSize+v.params.spaceBetween+"px"}),v.params.centeredSlides)){for(h=[],e=0;e1&&v.snapGrid.push(v.virtualSize-v.size)}0===v.snapGrid.length&&(v.snapGrid=[0]),0!==v.params.spaceBetween&&(v.isHorizontal()?v.rtl?v.slides.css({marginLeft:a+"px"}):v.slides.css({marginRight:a+"px"}):v.slides.css({marginBottom:a+"px"})),v.params.watchSlidesProgress&&v.updateSlidesOffset()}},v.updateSlidesOffset=function(){for(var e=0;ev.size&&(n=!0));for(a=v.activeIndex-1;a>=0;a--)v.slides[a]&&!n&&(r+=v.slides[a].swiperSlideSize,t++,r>v.size&&(n=!0))}else for(e=v.activeIndex+1;e=0&&i0&&s<=v.size||i<=0&&s>=v.size;o&&v.slides.eq(t).addClass(v.params.slideVisibleClass)}n.progress=v.rtl?-r:r}}},v.updateProgress=function(e){"undefined"==typeof e&&(e=v.translate||0);var a=v.maxTranslate()-v.minTranslate(),t=v.isBeginning,n=v.isEnd;0===a?(v.progress=0,v.isBeginning=v.isEnd=!0):(v.progress=(e-v.minTranslate())/a,v.isBeginning=v.progress<=0, v.isEnd=v.progress>=1),v.isBeginning&&!t&&v.emit("onReachBeginning",v),v.isEnd&&!n&&v.emit("onReachEnd",v),v.params.watchSlidesProgress&&v.updateSlidesProgress(e),v.emit("onProgress",v,v.progress)},v.updateActiveIndex=function(){var e,a,t,n=v.rtl?v.translate:-v.translate;for(a=0;a=v.slidesGrid[a]&&n=v.slidesGrid[a]&&n=v.slidesGrid[a]&&(e=a);v.params.normalizeSlideIndex&&(e<0||"undefined"==typeof e)&&(e=0),t=Math.floor(e/v.params.slidesPerGroup),t>=v.snapGrid.length&&(t=v.snapGrid.length-1),e!==v.activeIndex&&(v.snapIndex=t,v.previousIndex=v.activeIndex,v.activeIndex=e,v.updateClasses(),v.updateRealIndex())},v.updateRealIndex=function(){v.realIndex=parseInt(v.slides.eq(v.activeIndex).attr("data-swiper-slide-index")||v.activeIndex,10)},v.updateClasses=function(){v.slides.removeClass(v.params.slideActiveClass+" "+v.params.slideNextClass+" "+v.params.slidePrevClass+" "+v.params.slideDuplicateActiveClass+" "+v.params.slideDuplicateNextClass+" "+v.params.slideDuplicatePrevClass);var e=v.slides.eq(v.activeIndex);e.addClass(v.params.slideActiveClass),n.loop&&(e.hasClass(v.params.slideDuplicateClass)?v.wrapper.children("."+v.params.slideClass+":not(."+v.params.slideDuplicateClass+')[data-swiper-slide-index="'+v.realIndex+'"]').addClass(v.params.slideDuplicateActiveClass):v.wrapper.children("."+v.params.slideClass+"."+v.params.slideDuplicateClass+'[data-swiper-slide-index="'+v.realIndex+'"]').addClass(v.params.slideDuplicateActiveClass));var t=e.next("."+v.params.slideClass).addClass(v.params.slideNextClass);v.params.loop&&0===t.length&&(t=v.slides.eq(0),t.addClass(v.params.slideNextClass));var r=e.prev("."+v.params.slideClass).addClass(v.params.slidePrevClass);if(v.params.loop&&0===r.length&&(r=v.slides.eq(-1),r.addClass(v.params.slidePrevClass)),n.loop&&(t.hasClass(v.params.slideDuplicateClass)?v.wrapper.children("."+v.params.slideClass+":not(."+v.params.slideDuplicateClass+')[data-swiper-slide-index="'+t.attr("data-swiper-slide-index")+'"]').addClass(v.params.slideDuplicateNextClass):v.wrapper.children("."+v.params.slideClass+"."+v.params.slideDuplicateClass+'[data-swiper-slide-index="'+t.attr("data-swiper-slide-index")+'"]').addClass(v.params.slideDuplicateNextClass),r.hasClass(v.params.slideDuplicateClass)?v.wrapper.children("."+v.params.slideClass+":not(."+v.params.slideDuplicateClass+')[data-swiper-slide-index="'+r.attr("data-swiper-slide-index")+'"]').addClass(v.params.slideDuplicatePrevClass):v.wrapper.children("."+v.params.slideClass+"."+v.params.slideDuplicateClass+'[data-swiper-slide-index="'+r.attr("data-swiper-slide-index")+'"]').addClass(v.params.slideDuplicatePrevClass)),v.paginationContainer&&v.paginationContainer.length>0){var i,s=v.params.loop?Math.ceil((v.slides.length-2*v.loopedSlides)/v.params.slidesPerGroup):v.snapGrid.length;if(v.params.loop?(i=Math.ceil((v.activeIndex-v.loopedSlides)/v.params.slidesPerGroup),i>v.slides.length-1-2*v.loopedSlides&&(i-=v.slides.length-2*v.loopedSlides),i>s-1&&(i-=s),i<0&&"bullets"!==v.params.paginationType&&(i=s+i)):i="undefined"!=typeof v.snapIndex?v.snapIndex:v.activeIndex||0,"bullets"===v.params.paginationType&&v.bullets&&v.bullets.length>0&&(v.bullets.removeClass(v.params.bulletActiveClass),v.paginationContainer.length>1?v.bullets.each(function(){a(this).index()===i&&a(this).addClass(v.params.bulletActiveClass)}):v.bullets.eq(i).addClass(v.params.bulletActiveClass)),"fraction"===v.params.paginationType&&(v.paginationContainer.find("."+v.params.paginationCurrentClass).text(i+1),v.paginationContainer.find("."+v.params.paginationTotalClass).text(s)),"progress"===v.params.paginationType){var o=(i+1)/s,l=o,p=1;v.isHorizontal()||(p=o,l=1),v.paginationContainer.find("."+v.params.paginationProgressbarClass).transform("translate3d(0,0,0) scaleX("+l+") scaleY("+p+")").transition(v.params.speed)}"custom"===v.params.paginationType&&v.params.paginationCustomRender&&(v.paginationContainer.html(v.params.paginationCustomRender(v,i+1,s)),v.emit("onPaginationRendered",v,v.paginationContainer[0]))}v.params.loop||(v.params.prevButton&&v.prevButton&&v.prevButton.length>0&&(v.isBeginning?(v.prevButton.addClass(v.params.buttonDisabledClass),v.params.a11y&&v.a11y&&v.a11y.disable(v.prevButton)):(v.prevButton.removeClass(v.params.buttonDisabledClass),v.params.a11y&&v.a11y&&v.a11y.enable(v.prevButton))),v.params.nextButton&&v.nextButton&&v.nextButton.length>0&&(v.isEnd?(v.nextButton.addClass(v.params.buttonDisabledClass),v.params.a11y&&v.a11y&&v.a11y.disable(v.nextButton)):(v.nextButton.removeClass(v.params.buttonDisabledClass),v.params.a11y&&v.a11y&&v.a11y.enable(v.nextButton))))},v.updatePagination=function(){if(v.params.pagination&&v.paginationContainer&&v.paginationContainer.length>0){var e="";if("bullets"===v.params.paginationType){for(var a=v.params.loop?Math.ceil((v.slides.length-2*v.loopedSlides)/v.params.slidesPerGroup):v.snapGrid.length,t=0;t";v.paginationContainer.html(e),v.bullets=v.paginationContainer.find("."+v.params.bulletClass),v.params.paginationClickable&&v.params.a11y&&v.a11y&&v.a11y.initPagination()}"fraction"===v.params.paginationType&&(e=v.params.paginationFractionRender?v.params.paginationFractionRender(v,v.params.paginationCurrentClass,v.params.paginationTotalClass):' / ',v.paginationContainer.html(e)),"progress"===v.params.paginationType&&(e=v.params.paginationProgressRender?v.params.paginationProgressRender(v,v.params.paginationProgressbarClass):'',v.paginationContainer.html(e)),"custom"!==v.params.paginationType&&v.emit("onPaginationRendered",v,v.paginationContainer[0])}},v.update=function(e){function a(){v.rtl?-v.translate:v.translate;n=Math.min(Math.max(v.translate,v.maxTranslate()),v.minTranslate()),v.setWrapperTranslate(n),v.updateActiveIndex(),v.updateClasses()}if(v)if(v.updateContainerSize(),v.updateSlidesSize(),v.updateProgress(),v.updatePagination(),v.updateClasses(),v.params.scrollbar&&v.scrollbar&&v.scrollbar.set(),e){var t,n;v.controller&&v.controller.spline&&(v.controller.spline=void 0),v.params.freeMode?(a(),v.params.autoHeight&&v.updateAutoHeight()):(t=("auto"===v.params.slidesPerView||v.params.slidesPerView>1)&&v.isEnd&&!v.params.centeredSlides?v.slideTo(v.slides.length-1,0,!1,!0):v.slideTo(v.activeIndex,0,!1,!0),t||a())}else v.params.autoHeight&&v.updateAutoHeight()},v.onResize=function(e){v.params.breakpoints&&v.setBreakpoint();var a=v.params.allowSwipeToPrev,t=v.params.allowSwipeToNext;v.params.allowSwipeToPrev=v.params.allowSwipeToNext=!0,v.updateContainerSize(),v.updateSlidesSize(),("auto"===v.params.slidesPerView||v.params.freeMode||e)&&v.updatePagination(),v.params.scrollbar&&v.scrollbar&&v.scrollbar.set(),v.controller&&v.controller.spline&&(v.controller.spline=void 0);var n=!1;if(v.params.freeMode){var r=Math.min(Math.max(v.translate,v.maxTranslate()),v.minTranslate());v.setWrapperTranslate(r),v.updateActiveIndex(),v.updateClasses(),v.params.autoHeight&&v.updateAutoHeight()}else v.updateClasses(),n=("auto"===v.params.slidesPerView||v.params.slidesPerView>1)&&v.isEnd&&!v.params.centeredSlides?v.slideTo(v.slides.length-1,0,!1,!0):v.slideTo(v.activeIndex,0,!1,!0);v.params.lazyLoading&&!n&&v.lazy&&v.lazy.load(),v.params.allowSwipeToPrev=a,v.params.allowSwipeToNext=t},v.touchEventsDesktop={start:"mousedown",move:"mousemove",end:"mouseup"},window.navigator.pointerEnabled?v.touchEventsDesktop={start:"pointerdown",move:"pointermove",end:"pointerup"}:window.navigator.msPointerEnabled&&(v.touchEventsDesktop={start:"MSPointerDown",move:"MSPointerMove",end:"MSPointerUp"}),v.touchEvents={start:v.support.touch||!v.params.simulateTouch?"touchstart":v.touchEventsDesktop.start,move:v.support.touch||!v.params.simulateTouch?"touchmove":v.touchEventsDesktop.move,end:v.support.touch||!v.params.simulateTouch?"touchend":v.touchEventsDesktop.end},(window.navigator.pointerEnabled||window.navigator.msPointerEnabled)&&("container"===v.params.touchEventsTarget?v.container:v.wrapper).addClass("swiper-wp8-"+v.params.direction),v.initEvents=function(e){var a=e?"off":"on",t=e?"removeEventListener":"addEventListener",r="container"===v.params.touchEventsTarget?v.container[0]:v.wrapper[0],i=v.support.touch?r:document,s=!!v.params.nested;if(v.browser.ie)r[t](v.touchEvents.start,v.onTouchStart,!1),i[t](v.touchEvents.move,v.onTouchMove,s),i[t](v.touchEvents.end,v.onTouchEnd,!1);else{if(v.support.touch){var o=!("touchstart"!==v.touchEvents.start||!v.support.passiveListener||!v.params.passiveListeners)&&{passive:!0,capture:!1};r[t](v.touchEvents.start,v.onTouchStart,o),r[t](v.touchEvents.move,v.onTouchMove,s),r[t](v.touchEvents.end,v.onTouchEnd,o)}(n.simulateTouch&&!v.device.ios&&!v.device.android||n.simulateTouch&&!v.support.touch&&v.device.ios)&&(r[t]("mousedown",v.onTouchStart,!1),document[t]("mousemove",v.onTouchMove,s),document[t]("mouseup",v.onTouchEnd,!1))}window[t]("resize",v.onResize),v.params.nextButton&&v.nextButton&&v.nextButton.length>0&&(v.nextButton[a]("click",v.onClickNext),v.params.a11y&&v.a11y&&v.nextButton[a]("keydown",v.a11y.onEnterKey)),v.params.prevButton&&v.prevButton&&v.prevButton.length>0&&(v.prevButton[a]("click",v.onClickPrev),v.params.a11y&&v.a11y&&v.prevButton[a]("keydown",v.a11y.onEnterKey)),v.params.pagination&&v.params.paginationClickable&&(v.paginationContainer[a]("click","."+v.params.bulletClass,v.onClickIndex),v.params.a11y&&v.a11y&&v.paginationContainer[a]("keydown","."+v.params.bulletClass,v.a11y.onEnterKey)),(v.params.preventClicks||v.params.preventClicksPropagation)&&r[t]("click",v.preventClicks,!0)},v.attachEvents=function(){v.initEvents()},v.detachEvents=function(){v.initEvents(!0)},v.allowClick=!0,v.preventClicks=function(e){v.allowClick||(v.params.preventClicks&&e.preventDefault(),v.params.preventClicksPropagation&&v.animating&&(e.stopPropagation(),e.stopImmediatePropagation()))},v.onClickNext=function(e){e.preventDefault(),v.isEnd&&!v.params.loop||v.slideNext()},v.onClickPrev=function(e){e.preventDefault(),v.isBeginning&&!v.params.loop||v.slidePrev()},v.onClickIndex=function(e){e.preventDefault();var t=a(this).index()*v.params.slidesPerGroup;v.params.loop&&(t+=v.loopedSlides),v.slideTo(t)},v.updateClickedSlide=function(e){var t=s(e,"."+v.params.slideClass),n=!1;if(t)for(var r=0;rv.slides.length-v.loopedSlides+l/2?(v.fixLoop(),o=v.wrapper.children("."+v.params.slideClass+'[data-swiper-slide-index="'+i+'"]:not(.'+v.params.slideDuplicateClass+")").eq(0).index(),setTimeout(function(){v.slideTo(o)},0)):v.slideTo(o):o>v.slides.length-l?(v.fixLoop(),o=v.wrapper.children("."+v.params.slideClass+'[data-swiper-slide-index="'+i+'"]:not(.'+v.params.slideDuplicateClass+")").eq(0).index(),setTimeout(function(){v.slideTo(o)},0)):v.slideTo(o)}else v.slideTo(o)}};var w,C,y,x,T,k,P,S,M,I,E="input, select, textarea, button, video",O=Date.now(),z=[];v.animating=!1,v.touches={startX:0,startY:0,currentX:0,currentY:0,diff:0};var D,L;v.onTouchStart=function(e){if(e.originalEvent&&(e=e.originalEvent),D="touchstart"===e.type,D||!("which"in e)||3!==e.which){if(v.params.noSwiping&&s(e,"."+v.params.noSwipingClass))return void(v.allowClick=!0);if(!v.params.swipeHandler||s(e,v.params.swipeHandler)){var t=v.touches.currentX="touchstart"===e.type?e.targetTouches[0].pageX:e.pageX,n=v.touches.currentY="touchstart"===e.type?e.targetTouches[0].pageY:e.pageY;if(!(v.device.ios&&v.params.iOSEdgeSwipeDetection&&t<=v.params.iOSEdgeSwipeThreshold)){if(w=!0,C=!1,y=!0,T=void 0,L=void 0,v.touches.startX=t,v.touches.startY=n,x=Date.now(),v.allowClick=!0,v.updateContainerSize(),v.swipeDirection=void 0,v.params.threshold>0&&(S=!1),"touchstart"!==e.type){var r=!0;a(e.target).is(E)&&(r=!1),document.activeElement&&a(document.activeElement).is(E)&&document.activeElement.blur(),r&&e.preventDefault()}v.emit("onTouchStart",v,e)}}}},v.onTouchMove=function(e){if(e.originalEvent&&(e=e.originalEvent),!D||"mousemove"!==e.type){if(e.preventedByNestedSwiper)return v.touches.startX="touchmove"===e.type?e.targetTouches[0].pageX:e.pageX,void(v.touches.startY="touchmove"===e.type?e.targetTouches[0].pageY:e.pageY);if(v.params.onlyExternal)return v.allowClick=!1,void(w&&(v.touches.startX=v.touches.currentX="touchmove"===e.type?e.targetTouches[0].pageX:e.pageX,v.touches.startY=v.touches.currentY="touchmove"===e.type?e.targetTouches[0].pageY:e.pageY,x=Date.now()));if(D&&v.params.touchReleaseOnEdges&&!v.params.loop)if(v.isHorizontal()){if(v.touches.currentXv.touches.startX&&v.translate>=v.minTranslate())return}else if(v.touches.currentYv.touches.startY&&v.translate>=v.minTranslate())return;if(D&&document.activeElement&&e.target===document.activeElement&&a(e.target).is(E))return C=!0,void(v.allowClick=!1);if(y&&v.emit("onTouchMove",v,e),!(e.targetTouches&&e.targetTouches.length>1)){if(v.touches.currentX="touchmove"===e.type?e.targetTouches[0].pageX:e.pageX,v.touches.currentY="touchmove"===e.type?e.targetTouches[0].pageY:e.pageY,"undefined"==typeof T){var t;v.isHorizontal()&&v.touches.currentY===v.touches.startY||!v.isHorizontal()&&v.touches.currentX===v.touches.startX?T=!1:(t=180*Math.atan2(Math.abs(v.touches.currentY-v.touches.startY),Math.abs(v.touches.currentX-v.touches.startX))/Math.PI,T=v.isHorizontal()?t>v.params.touchAngle:90-t>v.params.touchAngle)}if(T&&v.emit("onTouchMoveOpposite",v,e),"undefined"==typeof L&&v.browser.ieTouch&&(v.touches.currentX===v.touches.startX&&v.touches.currentY===v.touches.startY||(L=!0)),w){if(T)return void(w=!1);if(L||!v.browser.ieTouch){v.allowClick=!1,v.emit("onSliderMove",v,e),e.preventDefault(),v.params.touchMoveStopPropagation&&!v.params.nested&&e.stopPropagation(),C||(n.loop&&v.fixLoop(),P=v.getWrapperTranslate(),v.setWrapperTransition(0),v.animating&&v.wrapper.trigger("webkitTransitionEnd transitionend oTransitionEnd MSTransitionEnd msTransitionEnd"),v.params.autoplay&&v.autoplaying&&(v.params.autoplayDisableOnInteraction?v.stopAutoplay():v.pauseAutoplay()),I=!1,!v.params.grabCursor||v.params.allowSwipeToNext!==!0&&v.params.allowSwipeToPrev!==!0||v.setGrabCursor(!0)),C=!0;var r=v.touches.diff=v.isHorizontal()?v.touches.currentX-v.touches.startX:v.touches.currentY-v.touches.startY;r*=v.params.touchRatio,v.rtl&&(r=-r),v.swipeDirection=r>0?"prev":"next",k=r+P;var i=!0;if(r>0&&k>v.minTranslate()?(i=!1,v.params.resistance&&(k=v.minTranslate()-1+Math.pow(-v.minTranslate()+P+r,v.params.resistanceRatio))):r<0&&kP&&(k=P),v.params.threshold>0){if(!(Math.abs(r)>v.params.threshold||S))return void(k=P);if(!S)return S=!0,v.touches.startX=v.touches.currentX,v.touches.startY=v.touches.currentY,k=P,void(v.touches.diff=v.isHorizontal()?v.touches.currentX-v.touches.startX:v.touches.currentY-v.touches.startY)}v.params.followFinger&&((v.params.freeMode||v.params.watchSlidesProgress)&&v.updateActiveIndex(),v.params.freeMode&&(0===z.length&&z.push({position:v.touches[v.isHorizontal()?"startX":"startY"],time:x}),z.push({position:v.touches[v.isHorizontal()?"currentX":"currentY"],time:(new window.Date).getTime()})),v.updateProgress(k),v.setWrapperTranslate(k))}}}}},v.onTouchEnd=function(e){if(e.originalEvent&&(e=e.originalEvent),y&&v.emit("onTouchEnd",v,e),y=!1,w){v.params.grabCursor&&C&&w&&(v.params.allowSwipeToNext===!0||v.params.allowSwipeToPrev===!0)&&v.setGrabCursor(!1);var t=Date.now(),n=t-x;if(v.allowClick&&(v.updateClickedSlide(e),v.emit("onTap",v,e),n<300&&t-O>300&&(M&&clearTimeout(M),M=setTimeout(function(){v&&(v.params.paginationHide&&v.paginationContainer.length>0&&!a(e.target).hasClass(v.params.bulletClass)&&v.paginationContainer.toggleClass(v.params.paginationHiddenClass),v.emit("onClick",v,e))},300)),n<300&&t-O<300&&(M&&clearTimeout(M),v.emit("onDoubleTap",v,e))),O=Date.now(),setTimeout(function(){v&&(v.allowClick=!0)},0),!w||!C||!v.swipeDirection||0===v.touches.diff||k===P)return void(w=C=!1);w=C=!1;var r;if(r=v.params.followFinger?v.rtl?v.translate:-v.translate:-k,v.params.freeMode){if(r<-v.minTranslate())return void v.slideTo(v.activeIndex);if(r>-v.maxTranslate())return void(v.slides.length1){var i=z.pop(),s=z.pop(),o=i.position-s.position,l=i.time-s.time;v.velocity=o/l,v.velocity=v.velocity/2,Math.abs(v.velocity)150||(new window.Date).getTime()-i.time>300)&&(v.velocity=0)}else v.velocity=0;v.velocity=v.velocity*v.params.freeModeMomentumVelocityRatio,z.length=0;var p=1e3*v.params.freeModeMomentumRatio,d=v.velocity*p,c=v.translate+d;v.rtl&&(c=-c);var u,m=!1,f=20*Math.abs(v.velocity)*v.params.freeModeMomentumBounceRatio;if(cv.minTranslate())v.params.freeModeMomentumBounce?(c-v.minTranslate()>f&&(c=v.minTranslate()+f),u=v.minTranslate(),m=!0,I=!0):c=v.minTranslate();else if(v.params.freeModeSticky){var h,g=0;for(g=0;g-c){h=g;break}c=Math.abs(v.snapGrid[h]-c)=v.params.longSwipesMs)&&(v.updateProgress(),v.updateActiveIndex()))}var b,T=0,S=v.slidesSizesGrid[0];for(b=0;b=v.slidesGrid[b]&&r=v.slidesGrid[b]&&(T=b,S=v.slidesGrid[v.slidesGrid.length-1]-v.slidesGrid[v.slidesGrid.length-2]);var E=(r-v.slidesGrid[T])/S;if(n>v.params.longSwipesMs){if(!v.params.longSwipes)return void v.slideTo(v.activeIndex);"next"===v.swipeDirection&&(E>=v.params.longSwipesRatio?v.slideTo(T+v.params.slidesPerGroup):v.slideTo(T)),"prev"===v.swipeDirection&&(E>1-v.params.longSwipesRatio?v.slideTo(T+v.params.slidesPerGroup):v.slideTo(T))}else{if(!v.params.shortSwipes)return void v.slideTo(v.activeIndex);"next"===v.swipeDirection&&v.slideTo(T+v.params.slidesPerGroup),"prev"===v.swipeDirection&&v.slideTo(T)}}},v._slideTo=function(e,a){return v.slideTo(e,a,!0,!0)},v.slideTo=function(e,a,t,n){"undefined"==typeof t&&(t=!0),"undefined"==typeof e&&(e=0),e<0&&(e=0),v.snapIndex=Math.floor(e/v.params.slidesPerGroup),v.snapIndex>=v.snapGrid.length&&(v.snapIndex=v.snapGrid.length-1);var r=-v.snapGrid[v.snapIndex];if(v.params.autoplay&&v.autoplaying&&(n||!v.params.autoplayDisableOnInteraction?v.pauseAutoplay(a):v.stopAutoplay()),v.updateProgress(r),v.params.normalizeSlideIndex)for(var i=0;i=Math.floor(100*v.slidesGrid[i])&&(e=i);return!(!v.params.allowSwipeToNext&&rv.translate&&r>v.maxTranslate()&&(v.activeIndex||0)!==e)&&("undefined"==typeof a&&(a=v.params.speed),v.previousIndex=v.activeIndex||0,v.activeIndex=e,v.updateRealIndex(),v.rtl&&-r===v.translate||!v.rtl&&r===v.translate?(v.params.autoHeight&&v.updateAutoHeight(),v.updateClasses(),"slide"!==v.params.effect&&v.setWrapperTranslate(r),!1):(v.updateClasses(),v.onTransitionStart(t),0===a||v.browser.lteIE9?(v.setWrapperTranslate(r),v.setWrapperTransition(0),v.onTransitionEnd(t)):(v.setWrapperTranslate(r),v.setWrapperTransition(a),v.animating||(v.animating=!0,v.wrapper.transitionEnd(function(){v&&v.onTransitionEnd(t)}))),!0)))},v.onTransitionStart=function(e){"undefined"==typeof e&&(e=!0),v.params.autoHeight&&v.updateAutoHeight(),v.lazy&&v.lazy.onTransitionStart(),e&&(v.emit("onTransitionStart",v),v.activeIndex!==v.previousIndex&&(v.emit("onSlideChangeStart",v),v.activeIndex>v.previousIndex?v.emit("onSlideNextStart",v):v.emit("onSlidePrevStart",v)))},v.onTransitionEnd=function(e){v.animating=!1,v.setWrapperTransition(0),"undefined"==typeof e&&(e=!0),v.lazy&&v.lazy.onTransitionEnd(),e&&(v.emit("onTransitionEnd",v),v.activeIndex!==v.previousIndex&&(v.emit("onSlideChangeEnd",v),v.activeIndex>v.previousIndex?v.emit("onSlideNextEnd",v):v.emit("onSlidePrevEnd",v))),v.params.history&&v.history&&v.history.setHistory(v.params.history,v.activeIndex),v.params.hashnav&&v.hashnav&&v.hashnav.setHash()},v.slideNext=function(e,a,t){if(v.params.loop){if(v.animating)return!1;v.fixLoop();v.container[0].clientLeft;return v.slideTo(v.activeIndex+v.params.slidesPerGroup,a,e,t)}return v.slideTo(v.activeIndex+v.params.slidesPerGroup,a,e,t)},v._slideNext=function(e){return v.slideNext(!0,e,!0)},v.slidePrev=function(e,a,t){if(v.params.loop){if(v.animating)return!1;v.fixLoop();v.container[0].clientLeft;return v.slideTo(v.activeIndex-1,a,e,t)}return v.slideTo(v.activeIndex-1,a,e,t)},v._slidePrev=function(e){return v.slidePrev(!0,e,!0)},v.slideReset=function(e,a,t){return v.slideTo(v.activeIndex,a,e)},v.disableTouchControl=function(){return v.params.onlyExternal=!0,!0},v.enableTouchControl=function(){return v.params.onlyExternal=!1,!0},v.setWrapperTransition=function(e,a){v.wrapper.transition(e),"slide"!==v.params.effect&&v.effects[v.params.effect]&&v.effects[v.params.effect].setTransition(e),v.params.parallax&&v.parallax&&v.parallax.setTransition(e),v.params.scrollbar&&v.scrollbar&&v.scrollbar.setTransition(e),v.params.control&&v.controller&&v.controller.setTransition(e,a),v.emit("onSetTransition",v,e)},v.setWrapperTranslate=function(e,a,t){var n=0,i=0,s=0;v.isHorizontal()?n=v.rtl?-e:e:i=e,v.params.roundLengths&&(n=r(n),i=r(i)),v.params.virtualTranslate||(v.support.transforms3d?v.wrapper.transform("translate3d("+n+"px, "+i+"px, "+s+"px)"):v.wrapper.transform("translate("+n+"px, "+i+"px)")),v.translate=v.isHorizontal()?n:i;var o,l=v.maxTranslate()-v.minTranslate();o=0===l?0:(e-v.minTranslate())/l,o!==v.progress&&v.updateProgress(e),a&&v.updateActiveIndex(),"slide"!==v.params.effect&&v.effects[v.params.effect]&&v.effects[v.params.effect].setTranslate(v.translate),v.params.parallax&&v.parallax&&v.parallax.setTranslate(v.translate),v.params.scrollbar&&v.scrollbar&&v.scrollbar.setTranslate(v.translate),v.params.control&&v.controller&&v.controller.setTranslate(v.translate,t),v.emit("onSetTranslate",v,v.translate)},v.getTranslate=function(e,a){var t,n,r,i;return"undefined"==typeof a&&(a="x"),v.params.virtualTranslate?v.rtl?-v.translate:v.translate:(r=window.getComputedStyle(e,null),window.WebKitCSSMatrix?(n=r.transform||r.webkitTransform,n.split(",").length>6&&(n=n.split(", ").map(function(e){return e.replace(",",".")}).join(", ")),i=new window.WebKitCSSMatrix("none"===n?"":n)):(i=r.MozTransform||r.OTransform||r.MsTransform||r.msTransform||r.transform||r.getPropertyValue("transform").replace("translate(","matrix(1, 0, 0, 1,"),t=i.toString().split(",")),"x"===a&&(n=window.WebKitCSSMatrix?i.m41:16===t.length?parseFloat(t[12]):parseFloat(t[4])),"y"===a&&(n=window.WebKitCSSMatrix?i.m42:16===t.length?parseFloat(t[13]):parseFloat(t[5])),v.rtl&&n&&(n=-n),n||0)},v.getWrapperTranslate=function(e){return"undefined"==typeof e&&(e=v.isHorizontal()?"x":"y"),v.getTranslate(v.wrapper[0],e)},v.observers=[],v.initObservers=function(){if(v.params.observeParents)for(var e=v.container.parents(),a=0;ae.length&&(v.loopedSlides=e.length);var t,n=[],r=[];for(e.each(function(t,i){var s=a(this);t=e.length-v.loopedSlides&&n.push(i),s.attr("data-swiper-slide-index",t)}),t=0;t=0;t--)v.wrapper.prepend(a(n[t].cloneNode(!0)).addClass(v.params.slideDuplicateClass))},v.destroyLoop=function(){v.wrapper.children("."+v.params.slideClass+"."+v.params.slideDuplicateClass).remove(),v.slides.removeAttr("data-swiper-slide-index")},v.reLoop=function(e){var a=v.activeIndex-v.loopedSlides;v.destroyLoop(),v.createLoop(),v.updateSlidesSize(),e&&v.slideTo(a+v.loopedSlides,0,!1)},v.fixLoop=function(){var e;v.activeIndex=2*v.loopedSlides||v.activeIndex>v.slides.length-2*v.params.slidesPerView)&&(e=-v.slides.length+v.activeIndex+v.loopedSlides,e+=v.loopedSlides,v.slideTo(e,0,!1,!0))},v.appendSlide=function(e){if(v.params.loop&&v.destroyLoop(),"object"==typeof e&&e.length)for(var a=0;a'),t.append(d)),0===c.length&&(c=a('
              '),t.append(c)),d.length&&(d[0].style.opacity=Math.max(-n,0)),c.length&&(c[0].style.opacity=Math.max(n,0))}t.transform("translate3d("+l+"px, "+p+"px, 0px) rotateX("+o+"deg) rotateY("+s+"deg)")}},setTransition:function(e){if(v.slides.transition(e).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(e),v.params.virtualTranslate&&0!==e){var t=!1;v.slides.eq(v.activeIndex).transitionEnd(function(){if(!t&&v&&a(this).hasClass(v.params.slideActiveClass)){t=!0,v.animating=!1;for(var e=["webkitTransitionEnd","transitionend","oTransitionEnd","MSTransitionEnd","msTransitionEnd"],n=0;n'),v.wrapper.append(e)),e.css({height:v.width+"px"})):(e=v.container.find(".swiper-cube-shadow"),0===e.length&&(e=a('
              '),v.container.append(e))));for(var n=0;n-1&&(t=90*n+90*o,v.rtl&&(t=90*-n-90*o)),r.transform(c),v.params.cube.slideShadows){var u=v.isHorizontal()?r.find(".swiper-slide-shadow-left"):r.find(".swiper-slide-shadow-top"),m=v.isHorizontal()?r.find(".swiper-slide-shadow-right"):r.find(".swiper-slide-shadow-bottom");0===u.length&&(u=a('
              '),r.append(u)),0===m.length&&(m=a('
              '),r.append(m)),u.length&&(u[0].style.opacity=Math.max(-o,0)),m.length&&(m[0].style.opacity=Math.max(o,0))}}if(v.wrapper.css({"-webkit-transform-origin":"50% 50% -"+v.size/2+"px","-moz-transform-origin":"50% 50% -"+v.size/2+"px","-ms-transform-origin":"50% 50% -"+v.size/2+"px","transform-origin":"50% 50% -"+v.size/2+"px"}),v.params.cube.shadow)if(v.isHorizontal())e.transform("translate3d(0px, "+(v.width/2+v.params.cube.shadowOffset)+"px, "+-v.width/2+"px) rotateX(90deg) rotateZ(0deg) scale("+v.params.cube.shadowScale+")");else{ var f=Math.abs(t)-90*Math.floor(Math.abs(t)/90),h=1.5-(Math.sin(2*f*Math.PI/360)/2+Math.cos(2*f*Math.PI/360)/2),g=v.params.cube.shadowScale,b=v.params.cube.shadowScale/h,w=v.params.cube.shadowOffset;e.transform("scale3d("+g+", 1, "+b+") translate3d(0px, "+(v.height/2+w)+"px, "+-v.height/2/b+"px) rotateX(-90deg)")}var C=v.isSafari||v.isUiWebView?-v.size/2:0;v.wrapper.transform("translate3d(0px,0,"+C+"px) rotateX("+(v.isHorizontal()?0:t)+"deg) rotateY("+(v.isHorizontal()?-t:0)+"deg)")},setTransition:function(e){v.slides.transition(e).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(e),v.params.cube.shadow&&!v.isHorizontal()&&v.container.find(".swiper-cube-shadow").transition(e)}},coverflow:{setTranslate:function(){for(var e=v.translate,t=v.isHorizontal()?-e+v.width/2:-e+v.height/2,n=v.isHorizontal()?v.params.coverflow.rotate:-v.params.coverflow.rotate,r=v.params.coverflow.depth,i=0,s=v.slides.length;i'),o.append(b)),0===w.length&&(w=a('
              '),o.append(w)),b.length&&(b[0].style.opacity=d>0?d:0),w.length&&(w[0].style.opacity=-d>0?-d:0)}}if(v.browser.ie){var C=v.wrapper[0].style;C.perspectiveOrigin=t+"px 50%"}},setTransition:function(e){v.slides.transition(e).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(e)}}},v.lazy={initialImageLoaded:!1,loadImageInSlide:function(e,t){if("undefined"!=typeof e&&("undefined"==typeof t&&(t=!0),0!==v.slides.length)){var n=v.slides.eq(e),r=n.find("."+v.params.lazyLoadingClass+":not(."+v.params.lazyStatusLoadedClass+"):not(."+v.params.lazyStatusLoadingClass+")");!n.hasClass(v.params.lazyLoadingClass)||n.hasClass(v.params.lazyStatusLoadedClass)||n.hasClass(v.params.lazyStatusLoadingClass)||(r=r.add(n[0])),0!==r.length&&r.each(function(){var e=a(this);e.addClass(v.params.lazyStatusLoadingClass);var r=e.attr("data-background"),i=e.attr("data-src"),s=e.attr("data-srcset"),o=e.attr("data-sizes");v.loadImage(e[0],i||r,s,o,!1,function(){if(r?(e.css("background-image",'url("'+r+'")'),e.removeAttr("data-background")):(s&&(e.attr("srcset",s),e.removeAttr("data-srcset")),o&&(e.attr("sizes",o),e.removeAttr("data-sizes")),i&&(e.attr("src",i),e.removeAttr("data-src"))),e.addClass(v.params.lazyStatusLoadedClass).removeClass(v.params.lazyStatusLoadingClass),n.find("."+v.params.lazyPreloaderClass+", ."+v.params.preloaderClass).remove(),v.params.loop&&t){var a=n.attr("data-swiper-slide-index");if(n.hasClass(v.params.slideDuplicateClass)){var l=v.wrapper.children('[data-swiper-slide-index="'+a+'"]:not(.'+v.params.slideDuplicateClass+")");v.lazy.loadImageInSlide(l.index(),!1)}else{var p=v.wrapper.children("."+v.params.slideDuplicateClass+'[data-swiper-slide-index="'+a+'"]');v.lazy.loadImageInSlide(p.index(),!1)}}v.emit("onLazyImageReady",v,n[0],e[0])}),v.emit("onLazyImageLoad",v,n[0],e[0])})}},load:function(){var e,t=v.params.slidesPerView;if("auto"===t&&(t=0),v.lazy.initialImageLoaded||(v.lazy.initialImageLoaded=!0),v.params.watchSlidesVisibility)v.wrapper.children("."+v.params.slideVisibleClass).each(function(){v.lazy.loadImageInSlide(a(this).index())});else if(t>1)for(e=v.activeIndex;e1||v.params.lazyLoadingInPrevNextAmount&&v.params.lazyLoadingInPrevNextAmount>1){var n=v.params.lazyLoadingInPrevNextAmount,r=t,i=Math.min(v.activeIndex+r+Math.max(n,r),v.slides.length),s=Math.max(v.activeIndex-Math.max(r,n),0);for(e=v.activeIndex+t;e0&&v.lazy.loadImageInSlide(o.index());var l=v.wrapper.children("."+v.params.slidePrevClass);l.length>0&&v.lazy.loadImageInSlide(l.index())}},onTransitionStart:function(){v.params.lazyLoading&&(v.params.lazyLoadingOnTransitionStart||!v.params.lazyLoadingOnTransitionStart&&!v.lazy.initialImageLoaded)&&v.lazy.load()},onTransitionEnd:function(){v.params.lazyLoading&&!v.params.lazyLoadingOnTransitionStart&&v.lazy.load()}},v.scrollbar={isTouched:!1,setDragPosition:function(e){var a=v.scrollbar,t=v.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,n=t-a.track.offset()[v.isHorizontal()?"left":"top"]-a.dragSize/2,r=-v.minTranslate()*a.moveDivider,i=-v.maxTranslate()*a.moveDivider;ni&&(n=i),n=-n/a.moveDivider,v.updateProgress(n),v.setWrapperTranslate(n,!0)},dragStart:function(e){var a=v.scrollbar;a.isTouched=!0,e.preventDefault(),e.stopPropagation(),a.setDragPosition(e),clearTimeout(a.dragTimeout),a.track.transition(0),v.params.scrollbarHide&&a.track.css("opacity",1),v.wrapper.transition(100),a.drag.transition(100),v.emit("onScrollbarDragStart",v)},dragMove:function(e){var a=v.scrollbar;a.isTouched&&(e.preventDefault?e.preventDefault():e.returnValue=!1,a.setDragPosition(e),v.wrapper.transition(0),a.track.transition(0),a.drag.transition(0),v.emit("onScrollbarDragMove",v))},dragEnd:function(e){var a=v.scrollbar;a.isTouched&&(a.isTouched=!1,v.params.scrollbarHide&&(clearTimeout(a.dragTimeout),a.dragTimeout=setTimeout(function(){a.track.css("opacity",0),a.track.transition(400)},1e3)),v.emit("onScrollbarDragEnd",v),v.params.scrollbarSnapOnRelease&&v.slideReset())},draggableEvents:function(){return v.params.simulateTouch!==!1||v.support.touch?v.touchEvents:v.touchEventsDesktop}(),enableDraggable:function(){var e=v.scrollbar,t=v.support.touch?e.track:document;a(e.track).on(e.draggableEvents.start,e.dragStart),a(t).on(e.draggableEvents.move,e.dragMove),a(t).on(e.draggableEvents.end,e.dragEnd)},disableDraggable:function(){var e=v.scrollbar,t=v.support.touch?e.track:document;a(e.track).off(e.draggableEvents.start,e.dragStart),a(t).off(e.draggableEvents.move,e.dragMove),a(t).off(e.draggableEvents.end,e.dragEnd)},set:function(){if(v.params.scrollbar){var e=v.scrollbar;e.track=a(v.params.scrollbar),v.params.uniqueNavElements&&"string"==typeof v.params.scrollbar&&e.track.length>1&&1===v.container.find(v.params.scrollbar).length&&(e.track=v.container.find(v.params.scrollbar)),e.drag=e.track.find(".swiper-scrollbar-drag"),0===e.drag.length&&(e.drag=a('
              '),e.track.append(e.drag)),e.drag[0].style.width="",e.drag[0].style.height="",e.trackSize=v.isHorizontal()?e.track[0].offsetWidth:e.track[0].offsetHeight,e.divider=v.size/v.virtualSize,e.moveDivider=e.divider*(e.trackSize/v.size),e.dragSize=e.trackSize*e.divider,v.isHorizontal()?e.drag[0].style.width=e.dragSize+"px":e.drag[0].style.height=e.dragSize+"px",e.divider>=1?e.track[0].style.display="none":e.track[0].style.display="",v.params.scrollbarHide&&(e.track[0].style.opacity=0)}},setTranslate:function(){if(v.params.scrollbar){var e,a=v.scrollbar,t=(v.translate||0,a.dragSize);e=(a.trackSize-a.dragSize)*v.progress,v.rtl&&v.isHorizontal()?(e=-e,e>0?(t=a.dragSize-e,e=0):-e+a.dragSize>a.trackSize&&(t=a.trackSize+e)):e<0?(t=a.dragSize+e,e=0):e+a.dragSize>a.trackSize&&(t=a.trackSize-e),v.isHorizontal()?(v.support.transforms3d?a.drag.transform("translate3d("+e+"px, 0, 0)"):a.drag.transform("translateX("+e+"px)"),a.drag[0].style.width=t+"px"):(v.support.transforms3d?a.drag.transform("translate3d(0px, "+e+"px, 0)"):a.drag.transform("translateY("+e+"px)"),a.drag[0].style.height=t+"px"),v.params.scrollbarHide&&(clearTimeout(a.timeout),a.track[0].style.opacity=1,a.timeout=setTimeout(function(){a.track[0].style.opacity=0,a.track.transition(400)},1e3))}},setTransition:function(e){v.params.scrollbar&&v.scrollbar.drag.transition(e)}},v.controller={LinearSpline:function(e,a){this.x=e,this.y=a,this.lastIndex=e.length-1;var t,n;this.x.length;this.interpolate=function(e){return e?(n=r(this.x,e),t=n-1,(e-this.x[t])*(this.y[n]-this.y[t])/(this.x[n]-this.x[t])+this.y[t]):0};var r=function(){var e,a,t;return function(n,r){for(a=-1,e=n.length;e-a>1;)n[t=e+a>>1]<=r?a=t:e=t;return e}}()},getInterpolateFunction:function(e){v.controller.spline||(v.controller.spline=v.params.loop?new v.controller.LinearSpline(v.slidesGrid,e.slidesGrid):new v.controller.LinearSpline(v.snapGrid,e.snapGrid))},setTranslate:function(e,a){function t(a){e=a.rtl&&"horizontal"===a.params.direction?-v.translate:v.translate,"slide"===v.params.controlBy&&(v.controller.getInterpolateFunction(a),r=-v.controller.spline.interpolate(-e)),r&&"container"!==v.params.controlBy||(n=(a.maxTranslate()-a.minTranslate())/(v.maxTranslate()-v.minTranslate()),r=(e-v.minTranslate())*n+a.minTranslate()),v.params.controlInverse&&(r=a.maxTranslate()-r),a.updateProgress(r),a.setWrapperTranslate(r,!1,v),a.updateActiveIndex()}var n,r,i=v.params.control;if(v.isArray(i))for(var s=0;sa.gesture.zoomMax&&(a.scale=a.gesture.zoomMax-1+Math.pow(a.scale-a.gesture.zoomMax+1,.5)),a.scalea.image.touchesStart.x)return void(a.image.isTouched=!1);if(!v.isHorizontal()&&Math.floor(a.image.minY)===Math.floor(a.image.startY)&&a.image.touchesCurrent.ya.image.touchesStart.y)return void(a.image.isTouched=!1)}e.preventDefault(),e.stopPropagation(),a.image.isMoved=!0,a.image.currentX=a.image.touchesCurrent.x-a.image.touchesStart.x+a.image.startX,a.image.currentY=a.image.touchesCurrent.y-a.image.touchesStart.y+a.image.startY,a.image.currentXa.image.maxX&&(a.image.currentX=a.image.maxX-1+Math.pow(a.image.currentX-a.image.maxX+1,.8)),a.image.currentYa.image.maxY&&(a.image.currentY=a.image.maxY-1+Math.pow(a.image.currentY-a.image.maxY+1,.8)),a.velocity.prevPositionX||(a.velocity.prevPositionX=a.image.touchesCurrent.x),a.velocity.prevPositionY||(a.velocity.prevPositionY=a.image.touchesCurrent.y),a.velocity.prevTime||(a.velocity.prevTime=Date.now()),a.velocity.x=(a.image.touchesCurrent.x-a.velocity.prevPositionX)/(Date.now()-a.velocity.prevTime)/2,a.velocity.y=(a.image.touchesCurrent.y-a.velocity.prevPositionY)/(Date.now()-a.velocity.prevTime)/2,Math.abs(a.image.touchesCurrent.x-a.velocity.prevPositionX)<2&&(a.velocity.x=0),Math.abs(a.image.touchesCurrent.y-a.velocity.prevPositionY)<2&&(a.velocity.y=0),a.velocity.prevPositionX=a.image.touchesCurrent.x,a.velocity.prevPositionY=a.image.touchesCurrent.y,a.velocity.prevTime=Date.now(),a.gesture.imageWrap.transform("translate3d("+a.image.currentX+"px, "+a.image.currentY+"px,0)")}}},onTouchEnd:function(e,a){var t=e.zoom;if(t.gesture.image&&0!==t.gesture.image.length){if(!t.image.isTouched||!t.image.isMoved)return t.image.isTouched=!1,void(t.image.isMoved=!1);t.image.isTouched=!1,t.image.isMoved=!1;var n=300,r=300,i=t.velocity.x*n,s=t.image.currentX+i,o=t.velocity.y*r,l=t.image.currentY+o;0!==t.velocity.x&&(n=Math.abs((s-t.image.currentX)/t.velocity.x)),0!==t.velocity.y&&(r=Math.abs((l-t.image.currentY)/t.velocity.y));var p=Math.max(n,r);t.image.currentX=s,t.image.currentY=l;var d=t.image.width*t.scale,c=t.image.height*t.scale;t.image.minX=Math.min(t.gesture.slideWidth/2-d/2,0),t.image.maxX=-t.image.minX,t.image.minY=Math.min(t.gesture.slideHeight/2-c/2,0),t.image.maxY=-t.image.minY,t.image.currentX=Math.max(Math.min(t.image.currentX,t.image.maxX),t.image.minX),t.image.currentY=Math.max(Math.min(t.image.currentY,t.image.maxY),t.image.minY),t.gesture.imageWrap.transition(p).transform("translate3d("+t.image.currentX+"px, "+t.image.currentY+"px,0)")}},onTransitionEnd:function(e){var a=e.zoom;a.gesture.slide&&e.previousIndex!==e.activeIndex&&(a.gesture.image.transform("translate3d(0,0,0) scale(1)"),a.gesture.imageWrap.transform("translate3d(0,0,0)"),a.gesture.slide=a.gesture.image=a.gesture.imageWrap=void 0,a.scale=a.currentScale=1)},toggleZoom:function(e,t){var n=e.zoom;if(n.gesture.slide||(n.gesture.slide=e.clickedSlide?a(e.clickedSlide):e.slides.eq(e.activeIndex),n.gesture.image=n.gesture.slide.find("img, svg, canvas"),n.gesture.imageWrap=n.gesture.image.parent("."+e.params.zoomContainerClass)),n.gesture.image&&0!==n.gesture.image.length){var r,i,s,o,l,p,d,c,u,m,f,h,g,v,b,w,C,y;"undefined"==typeof n.image.touchesStart.x&&t?(r="touchend"===t.type?t.changedTouches[0].pageX:t.pageX,i="touchend"===t.type?t.changedTouches[0].pageY:t.pageY):(r=n.image.touchesStart.x,i=n.image.touchesStart.y),n.scale&&1!==n.scale?(n.scale=n.currentScale=1,n.gesture.imageWrap.transition(300).transform("translate3d(0,0,0)"),n.gesture.image.transition(300).transform("translate3d(0,0,0) scale(1)"),n.gesture.slide=void 0):(n.scale=n.currentScale=n.gesture.imageWrap.attr("data-swiper-zoom")||e.params.zoomMax,t?(C=n.gesture.slide[0].offsetWidth,y=n.gesture.slide[0].offsetHeight,s=n.gesture.slide.offset().left,o=n.gesture.slide.offset().top,l=s+C/2-r,p=o+y/2-i,u=n.gesture.image[0].offsetWidth,m=n.gesture.image[0].offsetHeight,f=u*n.scale,h=m*n.scale,g=Math.min(C/2-f/2,0),v=Math.min(y/2-h/2,0),b=-g,w=-v,d=l*n.scale,c=p*n.scale,db&&(d=b),cw&&(c=w)):(d=0,c=0),n.gesture.imageWrap.transition(300).transform("translate3d("+d+"px, "+c+"px,0)"),n.gesture.image.transition(300).transform("translate3d(0,0,0) scale("+n.scale+")"))}},attachEvents:function(e){var t=e?"off":"on";if(v.params.zoom){var n=(v.slides,!("touchstart"!==v.touchEvents.start||!v.support.passiveListener||!v.params.passiveListeners)&&{passive:!0,capture:!1});v.support.gestures?(v.slides[t]("gesturestart",v.zoom.onGestureStart,n),v.slides[t]("gesturechange",v.zoom.onGestureChange,n),v.slides[t]("gestureend",v.zoom.onGestureEnd,n)):"touchstart"===v.touchEvents.start&&(v.slides[t](v.touchEvents.start,v.zoom.onGestureStart,n),v.slides[t](v.touchEvents.move,v.zoom.onGestureChange,n),v.slides[t](v.touchEvents.end,v.zoom.onGestureEnd,n)),v[t]("touchStart",v.zoom.onTouchStart),v.slides.each(function(e,n){a(n).find("."+v.params.zoomContainerClass).length>0&&a(n)[t](v.touchEvents.move,v.zoom.onTouchMove)}),v[t]("touchEnd",v.zoom.onTouchEnd),v[t]("transitionEnd",v.zoom.onTransitionEnd),v.params.zoomToggle&&v.on("doubleTap",v.zoom.toggleZoom)}},init:function(){v.zoom.attachEvents()},destroy:function(){v.zoom.attachEvents(!0)}},v._plugins=[];for(var B in v.plugins){var N=v.plugins[B](v,v.params[B]);N&&v._plugins.push(N)}return v.callPlugins=function(e){for(var a=0;a'),notify:function(e){var a=v.a11y.liveRegion;0!==a.length&&(a.html(""),a.html(e))},init:function(){v.params.nextButton&&v.nextButton&&v.nextButton.length>0&&(v.a11y.makeFocusable(v.nextButton),v.a11y.addRole(v.nextButton,"button"),v.a11y.addLabel(v.nextButton,v.params.nextSlideMessage)),v.params.prevButton&&v.prevButton&&v.prevButton.length>0&&(v.a11y.makeFocusable(v.prevButton),v.a11y.addRole(v.prevButton,"button"),v.a11y.addLabel(v.prevButton,v.params.prevSlideMessage)),a(v.container).append(v.a11y.liveRegion)},initPagination:function(){v.params.pagination&&v.params.paginationClickable&&v.bullets&&v.bullets.length&&v.bullets.each(function(){var e=a(this);v.a11y.makeFocusable(e),v.a11y.addRole(e,"button"),v.a11y.addLabel(e,v.params.paginationBulletMessage.replace(/{{index}}/,e.index()+1))})},destroy:function(){v.a11y.liveRegion&&v.a11y.liveRegion.length>0&&v.a11y.liveRegion.remove()}},v.init=function(){v.params.loop&&v.createLoop(),v.updateContainerSize(),v.updateSlidesSize(),v.updatePagination(),v.params.scrollbar&&v.scrollbar&&(v.scrollbar.set(),v.params.scrollbarDraggable&&v.scrollbar.enableDraggable()),"slide"!==v.params.effect&&v.effects[v.params.effect]&&(v.params.loop||v.updateProgress(),v.effects[v.params.effect].setTranslate()),v.params.loop?v.slideTo(v.params.initialSlide+v.loopedSlides,0,v.params.runCallbacksOnInit):(v.slideTo(v.params.initialSlide,0,v.params.runCallbacksOnInit),0===v.params.initialSlide&&(v.parallax&&v.params.parallax&&v.parallax.setTranslate(),v.lazy&&v.params.lazyLoading&&(v.lazy.load(),v.lazy.initialImageLoaded=!0))),v.attachEvents(),v.params.observer&&v.support.observer&&v.initObservers(),v.params.preloadImages&&!v.params.lazyLoading&&v.preloadImages(),v.params.zoom&&v.zoom&&v.zoom.init(),v.params.autoplay&&v.startAutoplay(),v.params.keyboardControl&&v.enableKeyboardControl&&v.enableKeyboardControl(),v.params.mousewheelControl&&v.enableMousewheelControl&&v.enableMousewheelControl(),v.params.hashnavReplaceState&&(v.params.replaceState=v.params.hashnavReplaceState),v.params.history&&v.history&&v.history.init(),v.params.hashnav&&v.hashnav&&v.hashnav.init(),v.params.a11y&&v.a11y&&v.a11y.init(),v.emit("onInit",v)},v.cleanupStyles=function(){v.container.removeClass(v.classNames.join(" ")).removeAttr("style"),v.wrapper.removeAttr("style"),v.slides&&v.slides.length&&v.slides.removeClass([v.params.slideVisibleClass,v.params.slideActiveClass,v.params.slideNextClass,v.params.slidePrevClass].join(" ")).removeAttr("style").removeAttr("data-swiper-column").removeAttr("data-swiper-row"),v.paginationContainer&&v.paginationContainer.length&&v.paginationContainer.removeClass(v.params.paginationHiddenClass),v.bullets&&v.bullets.length&&v.bullets.removeClass(v.params.bulletActiveClass),v.params.prevButton&&a(v.params.prevButton).removeClass(v.params.buttonDisabledClass),v.params.nextButton&&a(v.params.nextButton).removeClass(v.params.buttonDisabledClass),v.params.scrollbar&&v.scrollbar&&(v.scrollbar.track&&v.scrollbar.track.length&&v.scrollbar.track.removeAttr("style"),v.scrollbar.drag&&v.scrollbar.drag.length&&v.scrollbar.drag.removeAttr("style"))},v.destroy=function(e,a){v.detachEvents(),v.stopAutoplay(),v.params.scrollbar&&v.scrollbar&&v.params.scrollbarDraggable&&v.scrollbar.disableDraggable(),v.params.loop&&v.destroyLoop(),a&&v.cleanupStyles(),v.disconnectObservers(),v.params.zoom&&v.zoom&&v.zoom.destroy(),v.params.keyboardControl&&v.disableKeyboardControl&&v.disableKeyboardControl(),v.params.mousewheelControl&&v.disableMousewheelControl&&v.disableMousewheelControl(),v.params.a11y&&v.a11y&&v.a11y.destroy(),v.params.history&&!v.params.replaceState&&window.removeEventListener("popstate",v.history.setHistoryPopState),v.params.hashnav&&v.hashnav&&v.hashnav.destroy(),v.emit("onDestroy"),e!==!1&&(v=null)},v.init(),v}},Swiper.prototype={isSafari:function(){var e=window.navigator.userAgent.toLowerCase();return e.indexOf("safari")>=0&&e.indexOf("chrome")<0&&e.indexOf("android")<0}(),isUiWebView:/(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/i.test(window.navigator.userAgent),isArray:function(e){return"[object Array]"===Object.prototype.toString.apply(e)},browser:{ie:window.navigator.pointerEnabled||window.navigator.msPointerEnabled,ieTouch:window.navigator.msPointerEnabled&&window.navigator.msMaxTouchPoints>1||window.navigator.pointerEnabled&&window.navigator.maxTouchPoints>1,lteIE9:function(){var e=document.createElement("div");return e.innerHTML="",1===e.getElementsByTagName("i").length}()},device:function(){var e=window.navigator.userAgent,a=e.match(/(Android);?[\s\/]+([\d.]+)?/),t=e.match(/(iPad).*OS\s([\d_]+)/),n=e.match(/(iPod)(.*OS\s([\d_]+))?/),r=!t&&e.match(/(iPhone\sOS|iOS)\s([\d_]+)/);return{ios:t||r||n,android:a}}(),support:{touch:window.Modernizr&&Modernizr.touch===!0||function(){return!!("ontouchstart"in window||window.DocumentTouch&&document instanceof DocumentTouch)}(),transforms3d:window.Modernizr&&Modernizr.csstransforms3d===!0||function(){var e=document.createElement("div").style;return"webkitPerspective"in e||"MozPerspective"in e||"OPerspective"in e||"MsPerspective"in e||"perspective"in e}(),flexbox:function(){for(var e=document.createElement("div").style,a="alignItems webkitAlignItems webkitBoxAlign msFlexAlign mozBoxAlign webkitFlexDirection msFlexDirection mozBoxDirection mozBoxOrient webkitBoxDirection webkitBoxOrient".split(" "),t=0;t